@qitqode/qitqode-android-arm64 0.1.34 → 0.1.36
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/bundle/{chunk-7311jry1.js → chunk-00sr2gwz.js} +2 -2
- package/bundle/{chunk-azhw650z.js → chunk-02xcb52z.js} +2 -2
- package/bundle/{chunk-gws1rn1v.js → chunk-08q55ya0.js} +1 -1
- package/bundle/chunk-092bx2yw.js +2 -0
- package/bundle/{chunk-xgr6jnd6.js → chunk-0g25z230.js} +1 -1
- package/bundle/chunk-0j6dhrew.js +2 -0
- package/bundle/chunk-0jrgk6vk.js +2 -0
- package/bundle/chunk-0qn52zsd.js +2 -0
- package/bundle/chunk-10accb7b.js +2 -0
- package/bundle/{chunk-rjy5mqwz.js → chunk-132tcp2j.js} +2 -2
- package/bundle/chunk-13kpdfr7.js +2 -0
- package/bundle/chunk-15s8zwgf.js +2 -0
- package/bundle/{chunk-nj4d554m.js → chunk-1bx2sjn6.js} +1 -1
- package/bundle/chunk-1kgyfja6.js +2 -0
- package/bundle/{chunk-bv29k2pf.js → chunk-1mcsf4yb.js} +2 -2
- package/bundle/{chunk-kwx9ewe0.js → chunk-1wpjmwnh.js} +1 -1
- package/bundle/chunk-1yv5h8k4.js +2 -0
- package/bundle/chunk-24rw1br0.js +3 -0
- package/bundle/{chunk-snr44en9.js → chunk-25bp7pcm.js} +2 -2
- package/bundle/{chunk-kmcsz8yv.js → chunk-2dkrfc1s.js} +1 -1
- package/bundle/chunk-364ccew0.js +3 -0
- package/bundle/{chunk-ppkqr9cn.js → chunk-37dvnent.js} +2 -2
- package/bundle/chunk-3bkdbqjj.js +2 -0
- package/bundle/chunk-3bnqw3xp.js +3 -0
- package/bundle/{chunk-08m0hkdz.js → chunk-3dr4469n.js} +1 -1
- package/bundle/{chunk-2fkfbdcy.js → chunk-3gw6r3hf.js} +179 -179
- package/bundle/{chunk-n96tvjgj.js → chunk-3mepk08v.js} +2 -2
- package/bundle/chunk-3sz6gw10.js +3 -0
- package/bundle/chunk-41x11r2s.js +3 -0
- package/bundle/{chunk-xqdrr7xg.js → chunk-45mjcxqk.js} +1 -1
- package/bundle/{chunk-qrtc3etn.js → chunk-4fa390yr.js} +2 -2
- package/bundle/chunk-4gs87ghj.js +3 -0
- package/bundle/chunk-4kqdzdv5.js +3 -0
- package/bundle/{chunk-3k2b05fv.js → chunk-4sazy0nq.js} +1 -1
- package/bundle/chunk-4tbqsrsn.js +2 -0
- package/bundle/{chunk-ngccf7ga.js → chunk-52b1v7mn.js} +1 -1
- package/bundle/chunk-53kns5wy.js +2 -0
- package/bundle/{chunk-11v7vz3y.js → chunk-549ptbaj.js} +1 -1
- package/bundle/chunk-559ek1ym.js +2 -0
- package/bundle/{chunk-34p46th6.js → chunk-5bate758.js} +1 -1
- package/bundle/{chunk-kdcnder5.js → chunk-5kmfnkzv.js} +1 -1
- package/bundle/{chunk-9msnx26q.js → chunk-5pkg052s.js} +2 -2
- package/bundle/chunk-5yfzzmv0.js +2 -0
- package/bundle/{chunk-rsszcqxd.js → chunk-60qyqqxx.js} +1 -1
- package/bundle/{chunk-94pcpztx.js → chunk-64s7vfj7.js} +2 -2
- package/bundle/{chunk-bzgj60w4.js → chunk-6sfhbckv.js} +1 -1
- package/bundle/{chunk-8762ty72.js → chunk-70pb4kcm.js} +2 -2
- package/bundle/{chunk-04hvaaje.js → chunk-72zxassf.js} +1 -1
- package/bundle/{chunk-yz6898wy.js → chunk-73ckx171.js} +1 -1
- package/bundle/chunk-7cbj28fp.js +2 -0
- package/bundle/chunk-7dep7g7c.js +2 -0
- package/bundle/{chunk-gj0wt0cy.js → chunk-7fawtcnn.js} +1 -1
- package/bundle/{chunk-zfn0z4sh.js → chunk-7gbytqkn.js} +2 -2
- package/bundle/{chunk-x66ycpfs.js → chunk-7jhrxzjx.js} +2 -2
- package/bundle/{chunk-09pkckr1.js → chunk-7vftsy04.js} +1 -1
- package/bundle/{chunk-zfd70p01.js → chunk-8dxdeksr.js} +1 -1
- package/bundle/{chunk-6styp5dn.js → chunk-8fgamz4y.js} +1 -1
- package/bundle/{chunk-9qdr9t8c.js → chunk-8q6z6emx.js} +1 -1
- package/bundle/{chunk-4ttf9rjd.js → chunk-8r3410c2.js} +1 -1
- package/bundle/{chunk-3mzcr3fw.js → chunk-8tp4whyw.js} +1 -1
- package/bundle/chunk-8yn64y27.js +2 -0
- package/bundle/{chunk-41v0x1jk.js → chunk-8yr682pv.js} +2 -2
- package/bundle/chunk-8ywa7az5.js +2 -0
- package/bundle/chunk-8ywdddts.js +2 -0
- package/bundle/chunk-8zmreqxx.js +2 -0
- package/bundle/chunk-92zjark4.js +2 -0
- package/bundle/chunk-983rqajz.js +7 -0
- package/bundle/{chunk-kjyw00jp.js → chunk-9cw4cnz0.js} +1 -1
- package/bundle/{chunk-2swch6mx.js → chunk-9dh9bc9d.js} +1 -1
- package/bundle/{chunk-y437vyza.js → chunk-9fkmhmh6.js} +1 -1
- package/bundle/{chunk-7vd91wsd.js → chunk-9nk0ts0s.js} +1 -1
- package/bundle/{chunk-p9cnzxb8.js → chunk-9s4whpg1.js} +2 -2
- package/bundle/{chunk-yajd975f.js → chunk-9xvctnjr.js} +1 -1
- package/bundle/chunk-9yakc5yv.js +28 -0
- package/bundle/{chunk-4wxxyrxn.js → chunk-9zre5e54.js} +1 -1
- package/bundle/chunk-a42q5mx4.js +3 -0
- package/bundle/{chunk-yt3f3j35.js → chunk-a9y27zd2.js} +1 -1
- package/bundle/{chunk-mex0fe9s.js → chunk-acyj91wq.js} +1 -1
- package/bundle/chunk-aq28ejhv.js +2 -0
- package/bundle/{chunk-pkc4ddw1.js → chunk-atpzz901.js} +1 -1
- package/bundle/chunk-ax1y4699.js +2 -0
- package/bundle/{chunk-dctj3c22.js → chunk-b0jh0rby.js} +2 -2
- package/bundle/chunk-b0x888w9.js +2 -0
- package/bundle/chunk-b10px5g4.js +2 -0
- package/bundle/chunk-b1qhpxee.js +2 -0
- package/bundle/chunk-b4ysd5b4.js +9 -0
- package/bundle/chunk-bcs2gvmp.js +2 -0
- package/bundle/{chunk-7mxt5b0h.js → chunk-bjcb9kt0.js} +1 -1
- package/bundle/{chunk-67d5d8mr.js → chunk-bnz0mxak.js} +1 -1
- package/bundle/{chunk-wwgd4rzx.js → chunk-brh35yt5.js} +2 -2
- package/bundle/chunk-bs020a3x.js +2 -0
- package/bundle/{chunk-7eexey82.js → chunk-c72jajx9.js} +1 -1
- package/bundle/{chunk-81trveht.js → chunk-cagk1sjd.js} +1 -1
- package/bundle/{chunk-1byd3wma.js → chunk-cdh26622.js} +2 -2
- package/bundle/chunk-cjxcnhmq.js +14 -0
- package/bundle/{chunk-ygjtwjnk.js → chunk-cx0j6mpq.js} +1 -1
- package/bundle/{chunk-zh3fny3z.js → chunk-cx7p4ezk.js} +2 -2
- package/bundle/chunk-d0xs3j5h.js +2 -0
- package/bundle/{chunk-pxmhe36r.js → chunk-d1rn44wz.js} +1 -1
- package/bundle/chunk-d72rty3t.js +2 -0
- package/bundle/{chunk-0c6ep9mc.js → chunk-d93z6hrn.js} +1 -1
- package/bundle/{chunk-seghf5fc.js → chunk-dgx4rq86.js} +1 -1
- package/bundle/{chunk-qzj6027k.js → chunk-dh1h513y.js} +1 -1
- package/bundle/chunk-dj951pms.js +2 -0
- package/bundle/chunk-dp6zktka.js +2 -0
- package/bundle/{chunk-ba3h1pzs.js → chunk-dshnn54c.js} +1 -1
- package/bundle/{chunk-73myw3bj.js → chunk-dt899wbf.js} +2 -2
- package/bundle/chunk-dvqdtdza.js +2 -0
- package/bundle/{chunk-6ynxf3q7.js → chunk-dvxk6mr6.js} +2 -2
- package/bundle/chunk-dx7h5r8j.js +2 -0
- package/bundle/{chunk-bnss5dkk.js → chunk-dykqn0nj.js} +2 -2
- package/bundle/chunk-e03tgfpb.js +8 -0
- package/bundle/chunk-e07dbha4.js +2 -0
- package/bundle/chunk-e88wd9ex.js +2 -0
- package/bundle/{chunk-y9zstzed.js → chunk-eaqfnwdj.js} +1 -1
- package/bundle/chunk-ebabnv33.js +3 -0
- package/bundle/chunk-ebdpg3cn.js +2 -0
- package/bundle/{chunk-w9nzsd3w.js → chunk-ebkztnpf.js} +180 -178
- package/bundle/chunk-ec7pznsp.js +2 -0
- package/bundle/chunk-et7kz7kx.js +2 -0
- package/bundle/{chunk-kfmz2p27.js → chunk-ev3a2sxv.js} +2 -2
- package/bundle/{chunk-d00c1k9w.js → chunk-ewpzqnj4.js} +1 -1
- package/bundle/chunk-eyc6tb5h.js +2 -0
- package/bundle/chunk-eywryd3k.js +2 -0
- package/bundle/chunk-eze57bty.js +2 -0
- package/bundle/{chunk-qddt2gcs.js → chunk-ezrskm25.js} +1 -1
- package/bundle/chunk-f36ctnbp.js +3 -0
- package/bundle/{chunk-q5fygrnr.js → chunk-f77nxt23.js} +2 -2
- package/bundle/chunk-fa47vzfc.js +2 -0
- package/bundle/chunk-fe397ph0.js +2 -0
- package/bundle/chunk-fjm9kstr.js +5 -0
- package/bundle/{chunk-5xq3h51b.js → chunk-fmxm4kaj.js} +2 -2
- package/bundle/chunk-fr75ytdr.js +2 -0
- package/bundle/chunk-fw2tnbt6.js +2 -0
- package/bundle/chunk-fwr2qgqb.js +2 -0
- package/bundle/chunk-g204pt98.js +2 -0
- package/bundle/chunk-g5prcvq2.js +14 -0
- package/bundle/{chunk-ggydr1ze.js → chunk-g794ey6w.js} +1 -1
- package/bundle/chunk-gcgmwqhh.js +2 -0
- package/bundle/{chunk-rmve21dh.js → chunk-gg7bg3ek.js} +1 -1
- package/bundle/{chunk-9x25d115.js → chunk-gkj4a27z.js} +1 -1
- package/bundle/chunk-gvtjxg0d.js +2 -0
- package/bundle/chunk-gw36mrg4.js +2 -0
- package/bundle/{chunk-z8gdmvgg.js → chunk-gwfx7tx7.js} +2 -2
- package/bundle/{chunk-q8hd01j7.js → chunk-gxmxx8jb.js} +1 -1
- package/bundle/{chunk-tge53d52.js → chunk-h1kg35mn.js} +1 -1
- package/bundle/chunk-h36qec67.js +2 -0
- package/bundle/{chunk-0msqaywp.js → chunk-h7w35n7w.js} +1 -1
- package/bundle/chunk-h9gtymfm.js +2 -0
- package/bundle/chunk-h9qn35pn.js +2 -0
- package/bundle/{chunk-mr8j7rc6.js → chunk-hb9mc5f9.js} +1 -1
- package/bundle/{chunk-5a7fs1hg.js → chunk-hbh2034m.js} +1 -1
- package/bundle/{chunk-df2aswz3.js → chunk-hcy77w6t.js} +1 -1
- package/bundle/{chunk-6a7c7wnf.js → chunk-hgsykghj.js} +2 -2
- package/bundle/chunk-hhjkezfz.js +2 -0
- package/bundle/chunk-hnz570f9.js +3 -0
- package/bundle/{chunk-0csy9x1n.js → chunk-htkwc2se.js} +2 -2
- package/bundle/chunk-j21dnncc.js +4 -0
- package/bundle/{chunk-1yt5rsew.js → chunk-j63fkt6n.js} +1 -1
- package/bundle/chunk-ja18tvc7.js +2 -0
- package/bundle/{chunk-03xppy47.js → chunk-jcjaw7tk.js} +2 -2
- package/bundle/{chunk-jkh6eg7d.js → chunk-jf6ry79j.js} +4 -4
- package/bundle/{chunk-ke7n9t5p.js → chunk-jgz1a29w.js} +3 -3
- package/bundle/{chunk-ebcdxmdd.js → chunk-jngchw38.js} +1 -1
- package/bundle/{chunk-j5ymkhry.js → chunk-jqn27885.js} +1 -1
- package/bundle/chunk-jr2q5295.js +3 -0
- package/bundle/{chunk-hj3ddt53.js → chunk-jts0dma5.js} +2 -2
- package/bundle/chunk-jw16f6t0.js +4 -0
- package/bundle/chunk-jxg15t11.js +2 -0
- package/bundle/{chunk-7hm0c2yg.js → chunk-kqhh2pm9.js} +1 -1
- package/bundle/{chunk-0h8wdch6.js → chunk-kt0ej3nq.js} +1 -1
- package/bundle/chunk-kwzawx7r.js +2 -0
- package/bundle/{chunk-n6msxne8.js → chunk-kx2dp8ch.js} +1 -1
- package/bundle/chunk-m0mek3es.js +2 -0
- package/bundle/chunk-m31d2n6h.js +2 -0
- package/bundle/{chunk-egn55fa2.js → chunk-mcc5ynma.js} +3 -3
- package/bundle/{chunk-md8161zd.js → chunk-mdzzcrf9.js} +2 -2
- package/bundle/{chunk-knpyt206.js → chunk-mqtqcc10.js} +2 -2
- package/bundle/{chunk-ynwkr3yh.js → chunk-mvnxwwe7.js} +2 -2
- package/bundle/{chunk-xkv3yta0.js → chunk-mvsrzvc4.js} +4 -4
- package/bundle/{chunk-b4knxpqh.js → chunk-mw2hr4pd.js} +1 -1
- package/bundle/{chunk-vszbqv24.js → chunk-mzbr0m2v.js} +1 -1
- package/bundle/{chunk-bj00xk8k.js → chunk-n0trgp1c.js} +2 -2
- package/bundle/chunk-n14qktbg.js +2 -0
- package/bundle/{chunk-yjk6zv2z.js → chunk-n2ygpy76.js} +1 -1
- package/bundle/{chunk-4ntbxet5.js → chunk-n7xgfm5x.js} +2 -2
- package/bundle/{chunk-06k6egt2.js → chunk-neqy8j4n.js} +1 -1
- package/bundle/{chunk-nj61v4n7.js → chunk-njkserae.js} +1 -1
- package/bundle/{chunk-n6gtdx5h.js → chunk-nq495be3.js} +1 -1
- package/bundle/chunk-nr4q9fv7.js +2 -0
- package/bundle/{chunk-p3qkexpk.js → chunk-nsjp44fp.js} +1 -1
- package/bundle/chunk-nzzsj54n.js +2 -0
- package/bundle/chunk-p19qfw59.js +2 -0
- package/bundle/chunk-p2yxj9s4.js +2 -0
- package/bundle/{chunk-1dtzxt2w.js → chunk-p3rp99na.js} +1 -1
- package/bundle/chunk-p8czsxp0.js +3 -0
- package/bundle/chunk-p8k48st6.js +5 -0
- package/bundle/{chunk-79agp7v3.js → chunk-p8kpqyxb.js} +2 -2
- package/bundle/{chunk-9fxkh84w.js → chunk-p9zrk16q.js} +1 -1
- package/bundle/{chunk-xhkd9yf3.js → chunk-pmv8yr8c.js} +2 -2
- package/bundle/{chunk-ee23d2nz.js → chunk-pnq1h5az.js} +2 -2
- package/bundle/chunk-pq3qwxa8.js +2 -0
- package/bundle/{chunk-wfd5h6ax.js → chunk-pqnbdygz.js} +2 -2
- package/bundle/chunk-ps9p14y6.js +2 -0
- package/bundle/{chunk-zfcp509b.js → chunk-pxx2hz0g.js} +2 -2
- package/bundle/{chunk-zpf31kxb.js → chunk-q7rt76qw.js} +1 -1
- package/bundle/{chunk-rq4w0by4.js → chunk-q81m4m9z.js} +1 -1
- package/bundle/chunk-qagc6v17.js +2 -0
- package/bundle/{chunk-mq6jn47r.js → chunk-qb35hqm4.js} +1 -1
- package/bundle/chunk-qc0zhbhm.js +2 -0
- package/bundle/{chunk-keveg5gx.js → chunk-qdcf1ay5.js} +2 -2
- package/bundle/chunk-qp9y0g73.js +3 -0
- package/bundle/chunk-qpd0gab8.js +2 -0
- package/bundle/{chunk-6b196wjz.js → chunk-qqne79vp.js} +2 -2
- package/bundle/{chunk-g4gjz7sq.js → chunk-qs4wef8c.js} +1 -1
- package/bundle/chunk-r0ewmh6f.js +2 -0
- package/bundle/chunk-r3df289z.js +2 -0
- package/bundle/{chunk-by855es0.js → chunk-r58gzg6m.js} +1 -1
- package/bundle/{chunk-fmq0m4k5.js → chunk-r6ndvzd0.js} +1 -1
- package/bundle/chunk-r78kfhvz.js +2 -0
- package/bundle/{chunk-dyv2hqvc.js → chunk-rcyhqkv5.js} +1 -1
- package/bundle/{chunk-h2m8fdqm.js → chunk-rd4x4tsv.js} +1 -1
- package/bundle/chunk-rebsz3bj.js +2 -0
- package/bundle/{chunk-yp5bypsp.js → chunk-rexdr63q.js} +2 -2
- package/bundle/{chunk-1me21qdc.js → chunk-rgxy4ngt.js} +1 -1
- package/bundle/chunk-rph5xswc.js +2 -0
- package/bundle/{chunk-dcndy4sr.js → chunk-rph9zj24.js} +1 -1
- package/bundle/chunk-rqmvj7f4.js +3 -0
- package/bundle/{chunk-ryfqwsft.js → chunk-rrd0jf5m.js} +1 -1
- package/bundle/{chunk-mpygdb5a.js → chunk-s8mghr5a.js} +2 -2
- package/bundle/chunk-schtpyjs.js +2 -0
- package/bundle/{chunk-nmehsm3w.js → chunk-shwjjrj8.js} +1 -1
- package/bundle/{chunk-08f4khsw.js → chunk-snt1kefv.js} +3 -3
- package/bundle/{chunk-s8hq6trz.js → chunk-srxx88nb.js} +1 -1
- package/bundle/{chunk-gy0wm7e1.js → chunk-std2bgv7.js} +2 -2
- package/bundle/{chunk-dffhkd30.js → chunk-swcgsrbj.js} +1 -1
- package/bundle/chunk-sy3n0qhc.js +800 -0
- package/bundle/{chunk-wgk7ynt3.js → chunk-t01bhw5h.js} +3 -3
- package/bundle/chunk-t0jjes17.js +2 -0
- package/bundle/{chunk-y370dqf3.js → chunk-t5tfppwv.js} +2 -2
- package/bundle/chunk-t8rke5fr.js +8 -0
- package/bundle/chunk-tabcpx7t.js +4 -0
- package/bundle/{chunk-gmzrvxnv.js → chunk-tdmn21z0.js} +2 -2
- package/bundle/{chunk-71zw0qhf.js → chunk-tdxbm1nd.js} +1 -1
- package/bundle/{chunk-p825vsjy.js → chunk-te5tfq79.js} +1 -1
- package/bundle/chunk-tf4xwqz7.js +2 -0
- package/bundle/{chunk-fg35hwa0.js → chunk-tgd5ctnt.js} +2 -2
- package/bundle/chunk-tqazneg6.js +2 -0
- package/bundle/{chunk-qa2j0qmy.js → chunk-txqc7543.js} +2 -2
- package/bundle/chunk-tzg4z74d.js +2 -0
- package/bundle/{chunk-a3a1trap.js → chunk-v3x5nrc4.js} +2 -2
- package/bundle/chunk-v8dd6tyn.js +2 -0
- package/bundle/chunk-v8ksjgc3.js +2 -0
- package/bundle/chunk-v8vcwx23.js +2 -0
- package/bundle/chunk-vc4e6xc4.js +10 -0
- package/bundle/chunk-vcrakhgy.js +3 -0
- package/bundle/{chunk-za63b5mc.js → chunk-vdpd4akk.js} +2 -2
- package/bundle/{chunk-6p7yg5sr.js → chunk-vftqwdpg.js} +1 -1
- package/bundle/chunk-vg41rtdy.js +2 -0
- package/bundle/{chunk-r0k21apr.js → chunk-vgaxv70x.js} +2 -2
- package/bundle/{chunk-nkk4fyqf.js → chunk-vgnddhdj.js} +1 -1
- package/bundle/{chunk-xd3xc1vv.js → chunk-vm58fkrv.js} +1 -1
- package/bundle/{chunk-qg2vk5fw.js → chunk-vsys768k.js} +1 -1
- package/bundle/{chunk-s4qtphwx.js → chunk-w03fdrxe.js} +1 -1
- package/bundle/chunk-w1ypf53m.js +3 -0
- package/bundle/chunk-w24660y4.js +3 -0
- package/bundle/{chunk-z1ay3qd0.js → chunk-w3bmf3zz.js} +1 -1
- package/bundle/{chunk-28cm7m3t.js → chunk-w57j3pgz.js} +82 -82
- package/bundle/{chunk-vsr8mnj6.js → chunk-w5940jxm.js} +1 -1
- package/bundle/chunk-w6rf2knb.js +2 -0
- package/bundle/chunk-w9pdvcf9.js +3 -0
- package/bundle/{chunk-yk97q51d.js → chunk-wev34grp.js} +2 -2
- package/bundle/chunk-wh7r96t3.js +2 -0
- package/bundle/{chunk-1pg6pv0m.js → chunk-wm77svwm.js} +1 -1
- package/bundle/chunk-wnjqaxze.js +2 -0
- package/bundle/{chunk-qkjdr337.js → chunk-x6rr6ss1.js} +1 -1
- package/bundle/{chunk-bbzztav6.js → chunk-xdacgfba.js} +1 -1
- package/bundle/{chunk-6p94fpbn.js → chunk-xdjwapwy.js} +2 -2
- package/bundle/chunk-xfz698bh.js +2 -0
- package/bundle/{chunk-zwnhf4z1.js → chunk-xhbb8b5g.js} +1 -1
- package/bundle/chunk-xqwvx3qq.js +2 -0
- package/bundle/chunk-xxj3sgd5.js +2 -0
- package/bundle/chunk-xyjehgzm.js +3 -0
- package/bundle/{chunk-cs38g1bx.js → chunk-y0ydzdfc.js} +1 -1
- package/bundle/{chunk-wvf5q2hz.js → chunk-y1b2h15z.js} +1 -1
- package/bundle/{chunk-1gf116rg.js → chunk-yacccwf6.js} +1 -1
- package/bundle/chunk-ydc6ypjt.js +77 -0
- package/bundle/{chunk-dhqaqeq6.js → chunk-yeq7b87a.js} +1 -1
- package/bundle/chunk-yfp9y71y.js +2 -0
- package/bundle/chunk-yg9c1v8v.js +2 -0
- package/bundle/{chunk-e6xnynaz.js → chunk-yha554nm.js} +2 -2
- package/bundle/{chunk-rv1stdvb.js → chunk-yj6rbe9p.js} +2 -2
- package/bundle/chunk-yjjh339w.js +2 -0
- package/bundle/{chunk-j8q252w3.js → chunk-yjp0btmq.js} +3 -3
- package/bundle/{chunk-c5pb87yf.js → chunk-ymtcm4xd.js} +1 -1
- package/bundle/chunk-yt6vd7a5.js +2 -0
- package/bundle/{chunk-ssk8tkwd.js → chunk-yw9pfqxt.js} +1 -1
- package/bundle/{chunk-g6cyhxwg.js → chunk-yykjvt7f.js} +2 -2
- package/bundle/{chunk-sfes6pp1.js → chunk-yzh4rmrt.js} +1 -1
- package/bundle/chunk-yzq3c3dq.js +2 -0
- package/bundle/{chunk-prh3c44x.js → chunk-yzwgvjzd.js} +1 -1
- package/bundle/chunk-z1j25911.js +2 -0
- package/bundle/{chunk-rkwrjphh.js → chunk-z1rshv6g.js} +1 -1
- package/bundle/chunk-z29ahthm.js +2 -0
- package/bundle/{chunk-jgjnz82k.js → chunk-zaan8jk6.js} +1 -1
- package/bundle/{chunk-6gb65bv1.js → chunk-zbqzm65q.js} +1 -1
- package/bundle/{chunk-bk4phk66.js → chunk-zesbm9k1.js} +1 -1
- package/bundle/{chunk-c6vfwjg4.js → chunk-zfcfyagt.js} +1 -1
- package/bundle/{chunk-ywkvq7zb.js → chunk-zfnbk5gy.js} +1 -1
- package/bundle/chunk-zgre4gc2.js +2 -0
- package/bundle/{chunk-z7430qxg.js → chunk-zrmx397j.js} +1 -1
- package/bundle/chunk-zthkjx33.js +2 -0
- package/bundle/chunk-zxddasg8.js +2 -0
- package/bundle/index.js +3 -3
- package/bundle/parser.worker.js +2 -2
- package/bundle/worker.js +1 -1
- package/package.json +1 -1
- package/bundle/chunk-0x5jn813.js +0 -2
- package/bundle/chunk-1hmq2fpt.js +0 -14
- package/bundle/chunk-28t9akfn.js +0 -2
- package/bundle/chunk-2h1fcqvf.js +0 -2
- package/bundle/chunk-2scyp9ns.js +0 -2
- package/bundle/chunk-2tw58kwb.js +0 -2
- package/bundle/chunk-2vxx0tax.js +0 -2
- package/bundle/chunk-2ybt3p5z.js +0 -2
- package/bundle/chunk-2zpkw3ge.js +0 -2
- package/bundle/chunk-397be2x0.js +0 -2
- package/bundle/chunk-3c78nkgn.js +0 -2
- package/bundle/chunk-3vnnxq40.js +0 -2
- package/bundle/chunk-425mq6k8.js +0 -2
- package/bundle/chunk-43yv7tz1.js +0 -2
- package/bundle/chunk-499gp5g5.js +0 -2
- package/bundle/chunk-4sw6frjt.js +0 -2
- package/bundle/chunk-4xw14sed.js +0 -2
- package/bundle/chunk-536naqqv.js +0 -2
- package/bundle/chunk-57najm15.js +0 -2
- package/bundle/chunk-5he3d7cy.js +0 -2
- package/bundle/chunk-5vzrn6za.js +0 -3
- package/bundle/chunk-696z96a6.js +0 -2
- package/bundle/chunk-6hybp2mt.js +0 -2
- package/bundle/chunk-6v9nbb4c.js +0 -3
- package/bundle/chunk-6y423jax.js +0 -3
- package/bundle/chunk-72ghkgcn.js +0 -2
- package/bundle/chunk-741teh8k.js +0 -2
- package/bundle/chunk-7b3wx6kn.js +0 -2
- package/bundle/chunk-7bwe0ayr.js +0 -3
- package/bundle/chunk-7hh0654f.js +0 -3
- package/bundle/chunk-891yevv2.js +0 -2
- package/bundle/chunk-8d5k45yj.js +0 -2
- package/bundle/chunk-8eje5baf.js +0 -8
- package/bundle/chunk-8ktgy41r.js +0 -2
- package/bundle/chunk-8q73cjyj.js +0 -2
- package/bundle/chunk-8y623qdx.js +0 -2
- package/bundle/chunk-921vn745.js +0 -2
- package/bundle/chunk-9y97bzht.js +0 -8
- package/bundle/chunk-a0rp7gh4.js +0 -77
- package/bundle/chunk-a48t0g95.js +0 -3
- package/bundle/chunk-a8119c3a.js +0 -2
- package/bundle/chunk-akk84fnc.js +0 -2
- package/bundle/chunk-aw7j7brm.js +0 -2
- package/bundle/chunk-b34t8v7x.js +0 -2
- package/bundle/chunk-b8hmj4jq.js +0 -2
- package/bundle/chunk-bja8q0ke.js +0 -3
- package/bundle/chunk-c5fa8cb1.js +0 -2
- package/bundle/chunk-cfw9pyt7.js +0 -2
- package/bundle/chunk-ckbwdrm3.js +0 -2
- package/bundle/chunk-cz3h5n1v.js +0 -3
- package/bundle/chunk-d80hk5x9.js +0 -3
- package/bundle/chunk-d8dk05kd.js +0 -2
- package/bundle/chunk-dwajajaq.js +0 -2
- package/bundle/chunk-dxcrggvq.js +0 -2
- package/bundle/chunk-e7ah0e61.js +0 -2
- package/bundle/chunk-e7v9trve.js +0 -11
- package/bundle/chunk-efndtzby.js +0 -2
- package/bundle/chunk-eq2pepce.js +0 -2
- package/bundle/chunk-esp6jv63.js +0 -7
- package/bundle/chunk-f693s9vn.js +0 -2
- package/bundle/chunk-f9v5n0t6.js +0 -2
- package/bundle/chunk-fdadk5tw.js +0 -2
- package/bundle/chunk-ftepqwyq.js +0 -2
- package/bundle/chunk-g4nq9swr.js +0 -3
- package/bundle/chunk-gdb67zmn.js +0 -14
- package/bundle/chunk-gk28ffhg.js +0 -2
- package/bundle/chunk-gpfc4z4v.js +0 -2
- package/bundle/chunk-gqvg02zp.js +0 -2
- package/bundle/chunk-h3k1dk9m.js +0 -2
- package/bundle/chunk-h8c3dcqt.js +0 -2
- package/bundle/chunk-hfq11w4h.js +0 -2
- package/bundle/chunk-hg0etbkx.js +0 -3
- package/bundle/chunk-hw5qyht3.js +0 -3
- package/bundle/chunk-hwf58w1k.js +0 -2
- package/bundle/chunk-j0jdkqf5.js +0 -5
- package/bundle/chunk-jm722vy1.js +0 -4
- package/bundle/chunk-kdvs4871.js +0 -2
- package/bundle/chunk-kk3ve911.js +0 -2
- package/bundle/chunk-kv72hxkp.js +0 -3
- package/bundle/chunk-m4j7jyrd.js +0 -3
- package/bundle/chunk-mdts0641.js +0 -2
- package/bundle/chunk-mf3sm0pk.js +0 -2
- package/bundle/chunk-mkng9ykt.js +0 -2
- package/bundle/chunk-npv80mcx.js +0 -2
- package/bundle/chunk-ny9hnvzy.js +0 -2
- package/bundle/chunk-p15sv2dg.js +0 -3
- package/bundle/chunk-pe98rznj.js +0 -2
- package/bundle/chunk-q1czj6be.js +0 -2
- package/bundle/chunk-q6wm9yt0.js +0 -2
- package/bundle/chunk-qbx70v64.js +0 -2
- package/bundle/chunk-qc3ce3vc.js +0 -3
- package/bundle/chunk-qek6a75r.js +0 -2
- package/bundle/chunk-qkk1as5n.js +0 -2
- package/bundle/chunk-qsm9xw87.js +0 -2
- package/bundle/chunk-qyzze0dv.js +0 -2
- package/bundle/chunk-r2w3gr8d.js +0 -2
- package/bundle/chunk-r5bqcpkz.js +0 -2
- package/bundle/chunk-r67c858b.js +0 -2
- package/bundle/chunk-r9fvfkee.js +0 -2
- package/bundle/chunk-rq47pn3r.js +0 -2
- package/bundle/chunk-rvt1tdy8.js +0 -2
- package/bundle/chunk-ry7q8xn6.js +0 -2
- package/bundle/chunk-s27xvrft.js +0 -2
- package/bundle/chunk-s2vasbwj.js +0 -2
- package/bundle/chunk-scy39p6q.js +0 -2
- package/bundle/chunk-shenqgrx.js +0 -2
- package/bundle/chunk-sz0gkx88.js +0 -5
- package/bundle/chunk-t5qamf96.js +0 -2
- package/bundle/chunk-t9mz17gb.js +0 -3
- package/bundle/chunk-tt8jke90.js +0 -2
- package/bundle/chunk-ttevj0pj.js +0 -2
- package/bundle/chunk-v6tgn668.js +0 -2
- package/bundle/chunk-v7c54cyj.js +0 -2
- package/bundle/chunk-vgefaens.js +0 -2
- package/bundle/chunk-vkq0faj8.js +0 -2
- package/bundle/chunk-vkqzmzpw.js +0 -2
- package/bundle/chunk-vv59b4re.js +0 -2
- package/bundle/chunk-vwqy7n3g.js +0 -2
- package/bundle/chunk-w5kg2yz0.js +0 -3
- package/bundle/chunk-wbzs30fk.js +0 -28
- package/bundle/chunk-wet3bnwn.js +0 -2
- package/bundle/chunk-wfegee41.js +0 -2
- package/bundle/chunk-wmaz57f6.js +0 -800
- package/bundle/chunk-wn076jwj.js +0 -2
- package/bundle/chunk-x0m1qye9.js +0 -2
- package/bundle/chunk-x9s90xd1.js +0 -3
- package/bundle/chunk-xy5cjach.js +0 -2
- package/bundle/chunk-y70aachh.js +0 -2
- package/bundle/chunk-ya8g02hv.js +0 -9
- package/bundle/chunk-yqk58hf6.js +0 -3
- package/bundle/chunk-ysgxt83y.js +0 -2
- package/bundle/chunk-zm5dfk2b.js +0 -3
- package/bundle/chunk-zph1c2q1.js +0 -3
- package/bundle/chunk-zwdnh860.js +0 -2
|
@@ -1,45 +1,45 @@
|
|
|
1
1
|
// @bun
|
|
2
|
-
import{$
|
|
2
|
+
import{$j as F0,Ak as M8,Bk as c7,Ck as yZ,Dk as TZ,Ek as MX,Fk as wX,Gk as RX,Hk as LX,Ik as NX,Jk as uV,Kk as vV,Lj as P$,Mj as r8,Mk as E$,Nk as jB,Ok as UB,Qk as yJ,Rk as xX,Sk as bX,Tj as Hq,Tk as vX,Uj as WV,Vj as _7,Vk as Z4,Zj as J1,Zk as WX,_k as hX,ak as IJ,bk as f2,bl as L1,dl as z2,ek as b0,el as HB,fk as z8,gl as H1,ik as xK,il as E0,jk as bK,kk as R1,lk as bV,nk as I6,ok as GB,pl as cX,qk as XB,ql as lX,rk as WB,rl as Y1,sl as R$,tk as zZ,uk as CZ,vk as oG,yk as NZ,zk as Q1}from"./chunk-sy3n0qhc.js";import{tl as f9}from"./chunk-364ccew0.js";import{Gl as SG,Hl as mB,Kl as V0,Ll as e$,Ml as $1,Nl as JJ,Sl as z$,Tl as HJ,Wl as U2,am as B$,bm as i,dm as O1}from"./chunk-vdpd4akk.js";import{fm as M9,gm as u6,hm as S1,im as XJ,mm as Z0}from"./chunk-yjp0btmq.js";import{An as JZ,Gn as f7,Tn as m1,Un as O8,Vm as f1,pn as t0,qn as i$,rn as e0,sn as b2,tn as BX,um as UX,vn as G$,xn as _0,yn as NJ}from"./chunk-1bx2sjn6.js";import{cp as m6}from"./chunk-t5tfppwv.js";import{Ap as U1,wp as YZ,xp as gV,yp as KZ}from"./chunk-qdcf1ay5.js";import{Bp as T2}from"./chunk-45mjcxqk.js";import{Cp as x$}from"./chunk-qqne79vp.js";import{sq as e}from"./chunk-e03tgfpb.js";import{cs as VB}from"./chunk-w9pdvcf9.js";import{ns as HZ}from"./chunk-brh35yt5.js";import{Fs as G2,Gs as ZV,Ms as v1,Ns as X2}from"./chunk-xdjwapwy.js";import{lt as jZ,ut as D0}from"./chunk-7dep7g7c.js";import{vt as SB,zt as _9}from"./chunk-tabcpx7t.js";import{Ot as o9}from"./chunk-3sz6gw10.js";import{Qt as zB}from"./chunk-xqwvx3qq.js";import{$t as F9,Rt as E2,Ut as p9,Vt as YB,Yt as KB,Zt as QB,pu as BK}from"./chunk-qp9y0g73.js";import{qu as zG}from"./chunk-xyjehgzm.js";import{Bu as k$,Ku as O$}from"./chunk-j21dnncc.js";import{Nu as g9,Qu as y2,Ru as $$,Vu as O0,Zu as B8,_u as f$}from"./chunk-vc4e6xc4.js";import{$u as F}from"./chunk-hnz570f9.js";import{$C as p1,DL as BJ,HP as F$,LL as l$,MG as fB,NF as B0,UI as G,XL as JV,YC as ZB,aK as Z8,bG as UJ,mL as wU,nD as D$,nL as vG,oE as h2,qL as RU,rG as f,sL as qZ,uK as b1,wK as bG,yG as gB,zF as n0}from"./chunk-ydc6ypjt.js";import{aQ as x3}from"./chunk-ev3a2sxv.js";import{gQ as S9,hQ as p,iQ as o$,kQ as u0,lQ as w9,mQ as R9}from"./chunk-4sazy0nq.js";var LK=p((sS,I9)=>{function CK($){return Array.isArray($)?$:[$]}var T_=void 0,c6="",FK=" ",p6="\\",k_=/^\s+$/,E_=/(?:[^\\]|^)\\$/,x_=/^\\!/,b_=/^\\#/,v_=/\r?\n/g,h_=/^\.{0,2}\/|^\.{1,2}$/,g_=/\/$/,WJ="/",MK="node-ignore";if(typeof Symbol<"u")MK=Symbol.for("node-ignore");var DK=MK,jJ=($,J,Z)=>{return Object.defineProperty($,J,{value:Z}),Z},f_=/([0-z])-([0-z])/g,PK=()=>!1,m_=($)=>$.replace(f_,(J,Z,Y)=>Z.charCodeAt(0)<=Y.charCodeAt(0)?J:c6),u_=($)=>{let{length:J}=$;return $.slice(0,J-J%2)},d_=[[/^\uFEFF/,()=>c6],[/((?:\\\\)*?)(\\?\s+)$/,($,J,Z)=>J+(Z.indexOf("\\")===0?FK:c6)],[/(\\+?)\s/g,($,J)=>{let{length:Z}=J;return J.slice(0,Z-Z%2)+FK}],[/[\\$.|*+(){^]/g,($)=>`\\${$}`],[/(?!\\)\?/g,()=>"[^/]"],[/^\//,()=>"^"],[/\//g,()=>"\\/"],[/^\^*\\\*\\\*\\\//,()=>"^(?:.*\\/)?"],[/^(?=[^^])/,function(){return!/\/(?!$)/.test(this)?"(?:^|\\/)":"^"}],[/\\\/\\\*\\\*(?=\\\/|$)/g,($,J,Z)=>J+6<Z.length?"(?:\\/[^\\/]+)*":"\\/.+"],[/(^|[^\\]+)(\\\*)+(?=.+)/g,($,J,Z)=>{let Y=Z.replace(/\\\*/g,"[^\\/]*");return J+Y}],[/\\\\\\(?=[$.|*+(){^])/g,()=>p6],[/\\\\/g,()=>p6],[/(\\)?\[([^\]/]*?)(\\*)($|\])/g,($,J,Z,Y,K)=>J===p6?`\\[${Z}${u_(Y)}${K}`:K==="]"?Y.length%2===0?`[${m_(Z)}${Y}]`:"[]":"[]"],[/(?:[^*])$/,($)=>/\/$/.test($)?`${$}$`:`${$}(?=$|\\/$)`]],p_=/(^|\\\/)?\\\*$/,Y8="regex",D9="checkRegex",zK="_",c_={[Y8]($,J){return`${J?`${J}[^/]+`:"[^/]*"}(?=$|\\/$)`},[D9]($,J){return`${J?`${J}[^/]*`:"[^/]*"}(?=$|\\/$)`}},l_=($)=>d_.reduce((J,[Z,Y])=>J.replace(Z,Y.bind($)),$),P9=($)=>typeof $==="string",o_=($)=>$&&P9($)&&!k_.test($)&&!E_.test($)&&$.indexOf("#")!==0,r_=($)=>$.split(v_).filter(Boolean);class IK{constructor($,J,Z,Y,K,Q){this.pattern=$,this.mark=J,this.negative=K,jJ(this,"body",Z),jJ(this,"ignoreCase",Y),jJ(this,"regexPrefix",Q)}get regex(){let $=zK+Y8;if(this[$])return this[$];return this._make(Y8,$)}get checkRegex(){let $=zK+D9;if(this[$])return this[$];return this._make(D9,$)}_make($,J){let Z=this.regexPrefix.replace(p_,c_[$]),Y=this.ignoreCase?new RegExp(Z,"i"):new RegExp(Z);return jJ(this,J,Y)}}var i_=({pattern:$,mark:J},Z)=>{let Y=!1,K=$;if(K.indexOf("!")===0)Y=!0,K=K.substr(1);K=K.replace(x_,"!").replace(b_,"#");let Q=l_(K);return new IK($,J,K,Z,Y,Q)};class AK{constructor($){this._ignoreCase=$,this._rules=[]}_add($){if($&&$[DK]){this._rules=this._rules.concat($._rules._rules),this._added=!0;return}if(P9($))$={pattern:$};if(o_($.pattern)){let J=i_($,this._ignoreCase);this._added=!0,this._rules.push(J)}}add($){return this._added=!1,CK(P9($)?r_($):$).forEach(this._add,this),this._added}test($,J,Z){let Y=!1,K=!1,Q;this._rules.forEach((X)=>{let{negative:W}=X;if(K===W&&Y!==K||W&&!Y&&!K&&!J)return;if(!X[Z].test($))return;Y=!W,K=W,Q=W?T_:X});let V={ignored:Y,unignored:K};if(Q)V.rule=Q;return V}}var s_=($,J)=>{throw new J($)},h1=($,J,Z)=>{if(!P9($))return Z(`path must be a string, but got \`${J}\``,TypeError);if(!$)return Z("path must not be empty",TypeError);if(h1.isNotRelative($))return Z(`path should be a \`path.relative()\`d string, but got "${J}"`,RangeError);return!0},SK=($)=>h_.test($);h1.isNotRelative=SK;h1.convert=($)=>$;class wK{constructor({ignorecase:$=!0,ignoreCase:J=$,allowRelativePaths:Z=!1}={}){jJ(this,DK,!0),this._rules=new AK(J),this._strictPathCheck=!Z,this._initCache()}_initCache(){this._ignoreCache=Object.create(null),this._testCache=Object.create(null)}add($){if(this._rules.add($))this._initCache();return this}addPattern($){return this.add($)}_test($,J,Z,Y){let K=$&&h1.convert($);return h1(K,$,this._strictPathCheck?s_:PK),this._t(K,J,Z,Y)}checkIgnore($){if(!g_.test($))return this.test($);let J=$.split(WJ).filter(Boolean);if(J.pop(),J.length){let Z=this._t(J.join(WJ)+WJ,this._testCache,!0,J);if(Z.ignored)return Z}return this._rules.test($,!1,D9)}_t($,J,Z,Y){if($ in J)return J[$];if(!Y)Y=$.split(WJ).filter(Boolean);if(Y.pop(),!Y.length)return J[$]=this._rules.test($,Z,Y8);let K=this._t(Y.join(WJ)+WJ,J,Z,Y);return J[$]=K.ignored?K:this._rules.test($,Z,Y8)}ignores($){return this._test($,this._ignoreCache,!1).ignored}createFilter(){return($)=>!this.ignores($)}filter($){return CK($).filter(this.createFilter())}test($){return this._test($,this._testCache,!0)}}var l6=($)=>new wK($),n_=($)=>h1($&&h1.convert($),$,PK),RK=()=>{let $=(Z)=>/^\\\\\?\\/.test(Z)||/["<>|\u0000-\u001F]+/u.test(Z)?Z:Z.replace(/\\/g,"/");h1.convert=$;let J=/^[a-z]:\//i;h1.isNotRelative=(Z)=>J.test(Z)||SK(Z)};if(typeof process<"u"&&process.platform==="win32")RK();I9.exports=l6;l6.default=l6;I9.exports.isPathValid=n_;jJ(I9.exports,Symbol.for("setupWindows"),RK)});var L9=p((D4)=>{D4.isInteger=($)=>{if(typeof $==="number")return Number.isInteger($);if(typeof $==="string"&&$.trim()!=="")return Number.isInteger(Number($));return!1};D4.find=($,J)=>$.nodes.find((Z)=>Z.type===J);D4.exceedsLimit=($,J,Z=1,Y)=>{if(Y===!1)return!1;if(!D4.isInteger($)||!D4.isInteger(J))return!1;return(Number(J)-Number($))/Number(Z)>=Y};D4.escapeNode=($,J=0,Z)=>{let Y=$.nodes[J];if(!Y)return;if(Z&&Y.type===Z||Y.type==="open"||Y.type==="close"){if(Y.escaped!==!0)Y.value="\\"+Y.value,Y.escaped=!0}};D4.encloseBrace=($)=>{if($.type!=="brace")return!1;if($.commas>>0+$.ranges>>0===0)return $.invalid=!0,!0;return!1};D4.isInvalidBrace=($)=>{if($.type!=="brace")return!1;if($.invalid===!0||$.dollar)return!0;if($.commas>>0+$.ranges>>0===0)return $.invalid=!0,!0;if($.open!==!0||$.close!==!0)return $.invalid=!0,!0;return!1};D4.isOpenOrClose=($)=>{if($.type==="open"||$.type==="close")return!0;return $.open===!0||$.close===!0};D4.reduce=($)=>$.reduce((J,Z)=>{if(Z.type==="text")J.push(Z.value);if(Z.type==="range")Z.type="text";return J},[]);D4.flatten=(...$)=>{let J=[],Z=(Y)=>{for(let K=0;K<Y.length;K++){let Q=Y[K];if(Array.isArray(Q)){Z(Q);continue}if(Q!==void 0)J.push(Q)}return J};return Z($),J}});var N9=p((Hw,mK)=>{var fK=L9();mK.exports=($,J={})=>{let Z=(Y,K={})=>{let Q=J.escapeInvalid&&fK.isInvalidBrace(K),V=Y.invalid===!0&&J.escapeInvalid===!0,X="";if(Y.value){if((Q||V)&&fK.isOpenOrClose(Y))return"\\"+Y.value;return Y.value}if(Y.value)return Y.value;if(Y.nodes)for(let W of Y.nodes)X+=Z(W);return X};return Z($)}});var dK=p((_w,uK)=>{/*!
|
|
3
3
|
* is-number <https://github.com/jonschlinkert/is-number>
|
|
4
4
|
*
|
|
5
5
|
* Copyright (c) 2014-present, Jon Schlinkert.
|
|
6
6
|
* Released under the MIT License.
|
|
7
|
-
*/
|
|
7
|
+
*/uK.exports=function($){if(typeof $==="number")return $-$===0;if(typeof $==="string"&&$.trim()!=="")return Number.isFinite?Number.isFinite(+$):isFinite(+$);return!1}});var aK=p((Ow,nK)=>{/*!
|
|
8
8
|
* to-regex-range <https://github.com/micromatch/to-regex-range>
|
|
9
9
|
*
|
|
10
10
|
* Copyright (c) 2015-present, Jon Schlinkert.
|
|
11
11
|
* Released under the MIT License.
|
|
12
|
-
*/var
|
|
12
|
+
*/var pK=dK(),R2=($,J,Z)=>{if(pK($)===!1)throw TypeError("toRegexRange: expected the first argument to be a number");if(J===void 0||$===J)return String($);if(pK(J)===!1)throw TypeError("toRegexRange: expected the second argument to be a number.");let Y={relaxZeros:!0,...Z};if(typeof Y.strictZeros==="boolean")Y.relaxZeros=Y.strictZeros===!1;let K=String(Y.relaxZeros),Q=String(Y.shorthand),V=String(Y.capture),X=String(Y.wrap),W=$+":"+J+"="+K+Q+V+X;if(R2.cache.hasOwnProperty(W))return R2.cache[W].result;let _=Math.min($,J),j=Math.max($,J);if(Math.abs(_-j)===1){let M=$+"|"+J;if(Y.capture)return`(${M})`;if(Y.wrap===!1)return M;return`(?:${M})`}let H=sK($)||sK(J),q={min:$,max:J,a:_,b:j},U=[],z=[];if(H)q.isPadded=H,q.maxLen=String(q.max).length;if(_<0){let M=j<0?Math.abs(j):1;z=cK(M,Math.abs(_),q,Y),_=q.a=0}if(j>=0)U=cK(_,j,q,Y);if(q.negatives=z,q.positives=U,q.result=y4(z,U,Y),Y.capture===!0)q.result=`(${q.result})`;else if(Y.wrap!==!1&&U.length+z.length>1)q.result=`(?:${q.result})`;return R2.cache[W]=q,q.result};function y4($,J,Z){let Y=s6($,J,"-",!1,Z)||[],K=s6(J,$,"",!1,Z)||[],Q=s6($,J,"-?",!0,Z)||[];return Y.concat(Q).concat(K).join("|")}function T4($,J){let Z=1,Y=1,K=oK($,Z),Q=new Set([J]);while($<=K&&K<=J)Q.add(K),Z+=1,K=oK($,Z);K=rK(J+1,Y)-1;while($<K&&K<=J)Q.add(K),Y+=1,K=rK(J+1,Y)-1;return Q=[...Q],Q.sort(x4),Q}function k4($,J,Z){if($===J)return{pattern:$,count:[],digits:0};let Y=E4($,J),K=Y.length,Q="",V=0;for(let X=0;X<K;X++){let[W,_]=Y[X];if(W===_)Q+=W;else if(W!=="0"||_!=="9")Q+=b4(W,_,Z);else V++}if(V)Q+=Z.shorthand===!0?"\\d":"[0-9]";return{pattern:Q,count:[V],digits:K}}function cK($,J,Z,Y){let K=T4($,J),Q=[],V=$,X;for(let W=0;W<K.length;W++){let _=K[W],j=k4(String(V),String(_),Y),H="";if(!Z.isPadded&&X&&X.pattern===j.pattern){if(X.count.length>1)X.count.pop();X.count.push(j.count[0]),X.string=X.pattern+iK(X.count),V=_+1;continue}if(Z.isPadded)H=v4(_,Z,Y);j.string=H+j.pattern+iK(j.count),Q.push(j),V=_+1,X=j}return Q}function s6($,J,Z,Y,K){let Q=[];for(let V of $){let{string:X}=V;if(!Y&&!lK(J,"string",X))Q.push(Z+X);if(Y&&lK(J,"string",X))Q.push(Z+X)}return Q}function E4($,J){let Z=[];for(let Y=0;Y<$.length;Y++)Z.push([$[Y],J[Y]]);return Z}function x4($,J){return $>J?1:J>$?-1:0}function lK($,J,Z){return $.some((Y)=>Y[J]===Z)}function oK($,J){return Number(String($).slice(0,-J)+"9".repeat(J))}function rK($,J){return $-$%Math.pow(10,J)}function iK($){let[J=0,Z=""]=$;if(Z||J>1)return`{${J+(Z?","+Z:"")}}`;return""}function b4($,J,Z){return`[${$}${J-$===1?"":"-"}${J}]`}function sK($){return/^-?(0+)\d/.test($)}function v4($,J,Z){if(!J.isPadded)return $;let Y=Math.abs(J.maxLen-String($).length),K=Z.relaxZeros!==!1;switch(Y){case 0:return"";case 1:return K?"0?":"0";case 2:return K?"0{0,2}":"00";default:return K?`0{0,${Y}}`:`0{${Y}}`}}R2.cache={};R2.clearCache=()=>R2.cache={};nK.exports=R2});var t6=p((qw,KQ)=>{/*!
|
|
13
13
|
* fill-range <https://github.com/jonschlinkert/fill-range>
|
|
14
14
|
*
|
|
15
15
|
* Copyright (c) 2014-present, Jon Schlinkert.
|
|
16
16
|
* Licensed under the MIT License.
|
|
17
|
-
*/var
|
|
18
|
-
`,CHAR_NO_BREAK_SPACE:"\xA0",CHAR_PERCENT:"%",CHAR_PLUS:"+",CHAR_QUESTION_MARK:"?",CHAR_RIGHT_ANGLE_BRACKET:">",CHAR_RIGHT_CURLY_BRACE:"}",CHAR_RIGHT_SQUARE_BRACKET:"]",CHAR_SEMICOLON:";",CHAR_SINGLE_QUOTE:"'",CHAR_SPACE:" ",CHAR_TAB:"\t",CHAR_UNDERSCORE:"_",CHAR_VERTICAL_LINE:"|",CHAR_ZERO_WIDTH_NOBREAK_SPACE:"\uFEFF"}});var OQ=p((_w,_Q)=>{var c4=L9(),{MAX_LENGTH:UQ,CHAR_BACKSLASH:a6,CHAR_BACKTICK:l4,CHAR_COMMA:o4,CHAR_DOT:r4,CHAR_LEFT_PARENTHESES:i4,CHAR_RIGHT_PARENTHESES:s4,CHAR_LEFT_CURLY_BRACE:n4,CHAR_RIGHT_CURLY_BRACE:a4,CHAR_LEFT_SQUARE_BRACKET:HQ,CHAR_RIGHT_SQUARE_BRACKET:BQ,CHAR_DOUBLE_QUOTE:t4,CHAR_SINGLE_QUOTE:e4,CHAR_NO_BREAK_SPACE:$O,CHAR_ZERO_WIDTH_NOBREAK_SPACE:JO}=jQ(),ZO=($,J={})=>{if(typeof $!=="string")throw TypeError("Expected a string");let Z=J||{},Y=typeof Z.maxLength==="number"?Math.min(UQ,Z.maxLength):UQ;if($.length>Y)throw SyntaxError(`Input length (${$.length}), exceeds max characters (${Y})`);let K={type:"root",input:$,nodes:[]},Q=[K],V=K,X=K,W=0,B=$.length,j=0,_=0,q,H=()=>$[j++],C=(M)=>{if(M.type==="text"&&X.type==="dot")X.type="text";if(X&&X.type==="text"&&M.type==="text"){X.value+=M.value;return}return V.nodes.push(M),M.parent=V,M.prev=X,X=M,M};C({type:"bos"});while(j<B){if(V=Q[Q.length-1],q=H(),q===JO||q===$O)continue;if(q===a6){C({type:"text",value:(J.keepEscaping?q:"")+H()});continue}if(q===BQ){C({type:"text",value:"\\"+q});continue}if(q===HQ){W++;let M;while(j<B&&(M=H())){if(q+=M,M===HQ){W++;continue}if(M===a6){q+=H();continue}if(M===BQ){if(W--,W===0)break}}C({type:"text",value:q});continue}if(q===i4){V=C({type:"paren",nodes:[]}),Q.push(V),C({type:"text",value:q});continue}if(q===s4){if(V.type!=="paren"){C({type:"text",value:q});continue}V=Q.pop(),C({type:"text",value:q}),V=Q[Q.length-1];continue}if(q===t4||q===e4||q===l4){let M=q,I;if(J.keepQuotes!==!0)q="";while(j<B&&(I=H())){if(I===a6){q+=I+H();continue}if(I===M){if(J.keepQuotes===!0)q+=I;break}q+=I}C({type:"text",value:q});continue}if(q===n4){_++;let I={type:"brace",open:!0,close:!1,dollar:X.value&&X.value.slice(-1)==="$"||V.dollar===!0,depth:_,commas:0,ranges:0,nodes:[]};V=C(I),Q.push(V),C({type:"open",value:q});continue}if(q===a4){if(V.type!=="brace"){C({type:"text",value:q});continue}let M="close";V=Q.pop(),V.close=!0,C({type:M,value:q}),_--,V=Q[Q.length-1];continue}if(q===o4&&_>0){if(V.ranges>0){V.ranges=0;let M=V.nodes.shift();V.nodes=[M,{type:"text",value:c4(V)}]}C({type:"comma",value:q}),V.commas++;continue}if(q===r4&&_>0&&V.commas===0){let M=V.nodes;if(_===0||M.length===0){C({type:"text",value:q});continue}if(X.type==="dot"){if(V.range=[],X.value+=q,X.type="range",V.nodes.length!==3&&V.nodes.length!==5){V.invalid=!0,V.ranges=0,X.type="text";continue}V.ranges++,V.args=[];continue}if(X.type==="range"){M.pop();let I=M[M.length-1];I.value+=X.value+q,X=I,V.ranges--;continue}C({type:"dot",value:q});continue}C({type:"text",value:q})}do if(V=Q.pop(),V.type!=="root"){V.nodes.forEach((z)=>{if(!z.nodes){if(z.type==="open")z.isOpen=!0;if(z.type==="close")z.isClose=!0;if(!z.nodes)z.type="text";z.invalid=!0}});let M=Q[Q.length-1],I=M.nodes.indexOf(V);M.nodes.splice(I,1,...V.nodes)}while(Q.length>0);return C({type:"eos"}),K};_Q.exports=ZO});var zQ=p((Ow,FQ)=>{var qQ=L9(),YO=QQ(),KO=XQ(),QO=OQ(),d0=($,J={})=>{let Z=[];if(Array.isArray($))for(let Y of $){let K=d0.create(Y,J);if(Array.isArray(K))Z.push(...K);else Z.push(K)}else Z=[].concat(d0.create($,J));if(J&&J.expand===!0&&J.nodupes===!0)Z=[...new Set(Z)];return Z};d0.parse=($,J={})=>QO($,J);d0.stringify=($,J={})=>{if(typeof $==="string")return qQ(d0.parse($,J),J);return qQ($,J)};d0.compile=($,J={})=>{if(typeof $==="string")$=d0.parse($,J);return YO($,J)};d0.expand=($,J={})=>{if(typeof $==="string")$=d0.parse($,J);let Z=KO($,J);if(J.noempty===!0)Z=Z.filter(Boolean);if(J.nodupes===!0)Z=[...new Set(Z)];return Z};d0.create=($,J={})=>{if($===""||$.length<3)return[$];return J.expand!==!0?d0.compile($,J):d0.expand($,J)};FQ.exports=d0});var G8=p((qw,MQ)=>{var VO=u0("path"),CQ={DOT_LITERAL:"\\.",PLUS_LITERAL:"\\+",QMARK_LITERAL:"\\?",SLASH_LITERAL:"\\/",ONE_CHAR:"(?=.)",QMARK:"[^/]",END_ANCHOR:"(?:\\/|$)",DOTS_SLASH:"\\.{1,2}(?:\\/|$)",NO_DOT:"(?!\\.)",NO_DOTS:"(?!(?:^|\\/)\\.{1,2}(?:\\/|$))",NO_DOT_SLASH:"(?!\\.{0,1}(?:\\/|$))",NO_DOTS_SLASH:"(?!\\.{1,2}(?:\\/|$))",QMARK_NO_DOT:"[^.\\/]",STAR:"[^/]*?",START_ANCHOR:"(?:^|\\/)"},GO={...CQ,SLASH_LITERAL:"[\\\\/]",QMARK:"[^\\\\/]",STAR:"[^\\\\/]*?",DOTS_SLASH:"\\.{1,2}(?:[\\\\/]|$)",NO_DOT:"(?!\\.)",NO_DOTS:"(?!(?:^|[\\\\/])\\.{1,2}(?:[\\\\/]|$))",NO_DOT_SLASH:"(?!\\.{0,1}(?:[\\\\/]|$))",NO_DOTS_SLASH:"(?!\\.{1,2}(?:[\\\\/]|$))",QMARK_NO_DOT:"[^.\\\\/]",START_ANCHOR:"(?:^|[\\\\/])",END_ANCHOR:"(?:[\\\\/]|$)"},XO={__proto__:null,alnum:"a-zA-Z0-9",alpha:"a-zA-Z",ascii:"\\x00-\\x7F",blank:" \\t",cntrl:"\\x00-\\x1F\\x7F",digit:"0-9",graph:"\\x21-\\x7E",lower:"a-z",print:"\\x20-\\x7E ",punct:"\\-!\"#$%&'()\\*+,./:;<=>?@[\\]^_`{|}~",space:" \\t\\r\\n\\v\\f",upper:"A-Z",word:"A-Za-z0-9_",xdigit:"A-Fa-f0-9"};MQ.exports={DEFAULT_MAX_EXTGLOB_RECURSION:0,MAX_LENGTH:65536,POSIX_REGEX_SOURCE:XO,REGEX_BACKSLASH:/\\(?![*+?^${}(|)[\]])/g,REGEX_NON_SPECIAL_CHARS:/^[^@![\].,$*+?^{}()|\\/]+/,REGEX_SPECIAL_CHARS:/[-*+?.^${}(|)[\]]/,REGEX_SPECIAL_CHARS_BACKREF:/(\\?)((\W)(\3*))/g,REGEX_SPECIAL_CHARS_GLOBAL:/([-*+?.^${}(|)[\]])/g,REGEX_REMOVE_BACKSLASH:/(?:\[.*?[^\\]\]|\\(?=.))/g,REPLACEMENTS:{__proto__:null,"***":"*","**/**":"**","**/**/**":"**"},CHAR_0:48,CHAR_9:57,CHAR_UPPERCASE_A:65,CHAR_LOWERCASE_A:97,CHAR_UPPERCASE_Z:90,CHAR_LOWERCASE_Z:122,CHAR_LEFT_PARENTHESES:40,CHAR_RIGHT_PARENTHESES:41,CHAR_ASTERISK:42,CHAR_AMPERSAND:38,CHAR_AT:64,CHAR_BACKWARD_SLASH:92,CHAR_CARRIAGE_RETURN:13,CHAR_CIRCUMFLEX_ACCENT:94,CHAR_COLON:58,CHAR_COMMA:44,CHAR_DOT:46,CHAR_DOUBLE_QUOTE:34,CHAR_EQUAL:61,CHAR_EXCLAMATION_MARK:33,CHAR_FORM_FEED:12,CHAR_FORWARD_SLASH:47,CHAR_GRAVE_ACCENT:96,CHAR_HASH:35,CHAR_HYPHEN_MINUS:45,CHAR_LEFT_ANGLE_BRACKET:60,CHAR_LEFT_CURLY_BRACE:123,CHAR_LEFT_SQUARE_BRACKET:91,CHAR_LINE_FEED:10,CHAR_NO_BREAK_SPACE:160,CHAR_PERCENT:37,CHAR_PLUS:43,CHAR_QUESTION_MARK:63,CHAR_RIGHT_ANGLE_BRACKET:62,CHAR_RIGHT_CURLY_BRACE:125,CHAR_RIGHT_SQUARE_BRACKET:93,CHAR_SEMICOLON:59,CHAR_SINGLE_QUOTE:39,CHAR_SPACE:32,CHAR_TAB:9,CHAR_UNDERSCORE:95,CHAR_VERTICAL_LINE:124,CHAR_ZERO_WIDTH_NOBREAK_SPACE:65279,SEP:VO.sep,extglobChars($){return{"!":{type:"negate",open:"(?:(?!(?:",close:`))${$.STAR})`},"?":{type:"qmark",open:"(?:",close:")?"},"+":{type:"plus",open:"(?:",close:")+"},"*":{type:"star",open:"(?:",close:")*"},"@":{type:"at",open:"(?:",close:")"}}},globChars($){return $===!0?GO:CQ}}});var X8=p((OO)=>{var WO=u0("path"),jO=process.platform==="win32",{REGEX_BACKSLASH:UO,REGEX_REMOVE_BACKSLASH:HO,REGEX_SPECIAL_CHARS:BO,REGEX_SPECIAL_CHARS_GLOBAL:_O}=G8();OO.isObject=($)=>$!==null&&typeof $==="object"&&!Array.isArray($);OO.hasRegexChars=($)=>BO.test($);OO.isRegexChar=($)=>$.length===1&&OO.hasRegexChars($);OO.escapeRegex=($)=>$.replace(_O,"\\$1");OO.toPosixSlashes=($)=>$.replace(UO,"/");OO.removeBackslashes=($)=>{return $.replace(HO,(J)=>{return J==="\\"?"":J})};OO.supportsLookbehinds=()=>{let $=process.version.slice(1).split(".").map(Number);if($.length===3&&$[0]>=9||$[0]===8&&$[1]>=10)return!0;return!1};OO.isWindows=($)=>{if($&&typeof $.windows==="boolean")return $.windows;return jO===!0||WO.sep==="\\"};OO.escapeLast=($,J,Z)=>{let Y=$.lastIndexOf(J,Z);if(Y===-1)return $;if($[Y-1]==="\\")return OO.escapeLast($,J,Y-1);return`${$.slice(0,Y)}\\${$.slice(Y)}`};OO.removePrefix=($,J={})=>{let Z=$;if(Z.startsWith("./"))Z=Z.slice(2),J.prefix="./";return Z};OO.wrapOutput=($,J={},Z={})=>{let Y=Z.contains?"":"^",K=Z.contains?"":"$",Q=`${Y}(?:${$})${K}`;if(J.negated===!0)Q=`(?:^(?!${Q}).*$)`;return Q}});var yQ=p((zw,NQ)=>{var IQ=X8(),{CHAR_ASTERISK:t6,CHAR_AT:SO,CHAR_BACKWARD_SLASH:W8,CHAR_COMMA:wO,CHAR_DOT:e6,CHAR_EXCLAMATION_MARK:$7,CHAR_FORWARD_SLASH:LQ,CHAR_LEFT_CURLY_BRACE:J7,CHAR_LEFT_PARENTHESES:Z7,CHAR_LEFT_SQUARE_BRACKET:RO,CHAR_PLUS:LO,CHAR_QUESTION_MARK:AQ,CHAR_RIGHT_CURLY_BRACE:NO,CHAR_RIGHT_PARENTHESES:SQ,CHAR_RIGHT_SQUARE_BRACKET:yO}=G8(),wQ=($)=>{return $===LQ||$===W8},RQ=($)=>{if($.isPrefix!==!0)$.depth=$.isGlobstar?1/0:1},TO=($,J)=>{let Z=J||{},Y=$.length-1,K=Z.parts===!0||Z.scanToEnd===!0,Q=[],V=[],X=[],W=$,B=-1,j=0,_=0,q=!1,H=!1,C=!1,M=!1,I=!1,z=!1,P=!1,D=!1,L=!1,R=!1,N=0,x,b,v={value:"",depth:0,isGlob:!1},m=()=>B>=Y,A=()=>W.charCodeAt(B+1),u=()=>{return x=b,W.charCodeAt(++B)};while(B<Y){b=u();let A$;if(b===W8){if(P=v.backslashes=!0,b=u(),b===J7)z=!0;continue}if(z===!0||b===J7){N++;while(m()!==!0&&(b=u())){if(b===W8){P=v.backslashes=!0,u();continue}if(b===J7){N++;continue}if(z!==!0&&b===e6&&(b=u())===e6){if(q=v.isBrace=!0,C=v.isGlob=!0,R=!0,K===!0)continue;break}if(z!==!0&&b===wO){if(q=v.isBrace=!0,C=v.isGlob=!0,R=!0,K===!0)continue;break}if(b===NO){if(N--,N===0){z=!1,q=v.isBrace=!0,R=!0;break}}}if(K===!0)continue;break}if(b===LQ){if(Q.push(B),V.push(v),v={value:"",depth:0,isGlob:!1},R===!0)continue;if(x===e6&&B===j+1){j+=2;continue}_=B+1;continue}if(Z.noext!==!0){if((b===LO||b===SO||b===t6||b===AQ||b===$7)===!0&&A()===Z7){if(C=v.isGlob=!0,M=v.isExtglob=!0,R=!0,b===$7&&B===j)L=!0;if(K===!0){while(m()!==!0&&(b=u())){if(b===W8){P=v.backslashes=!0,b=u();continue}if(b===SQ){C=v.isGlob=!0,R=!0;break}}continue}break}}if(b===t6){if(x===t6)I=v.isGlobstar=!0;if(C=v.isGlob=!0,R=!0,K===!0)continue;break}if(b===AQ){if(C=v.isGlob=!0,R=!0,K===!0)continue;break}if(b===RO){while(m()!==!0&&(A$=u())){if(A$===W8){P=v.backslashes=!0,u();continue}if(A$===yO){H=v.isBracket=!0,C=v.isGlob=!0,R=!0;break}}if(K===!0)continue;break}if(Z.nonegate!==!0&&b===$7&&B===j){D=v.negated=!0,j++;continue}if(Z.noparen!==!0&&b===Z7){if(C=v.isGlob=!0,K===!0){while(m()!==!0&&(b=u())){if(b===Z7){P=v.backslashes=!0,b=u();continue}if(b===SQ){R=!0;break}}continue}break}if(C===!0){if(R=!0,K===!0)continue;break}}if(Z.noext===!0)M=!1,C=!1;let r=W,S="",T="";if(j>0)S=W.slice(0,j),W=W.slice(j),_-=j;if(r&&C===!0&&_>0)r=W.slice(0,_),T=W.slice(_);else if(C===!0)r="",T=W;else r=W;if(r&&r!==""&&r!=="/"&&r!==W){if(wQ(r.charCodeAt(r.length-1)))r=r.slice(0,-1)}if(Z.unescape===!0){if(T)T=IQ.removeBackslashes(T);if(r&&P===!0)r=IQ.removeBackslashes(r)}let k={prefix:S,input:$,start:j,base:r,glob:T,isBrace:q,isBracket:H,isGlob:C,isExtglob:M,isGlobstar:I,negated:D,negatedExtglob:L};if(Z.tokens===!0){if(k.maxDepth=0,!wQ(b))V.push(v);k.tokens=V}if(Z.parts===!0||Z.tokens===!0){let A$;for(let s=0;s<Q.length;s++){let J$=A$?A$+1:j,Z$=Q[s],W$=$.slice(J$,Z$);if(Z.tokens){if(s===0&&j!==0)V[s].isPrefix=!0,V[s].value=S;else V[s].value=W$;RQ(V[s]),k.maxDepth+=V[s].depth}if(s!==0||W$!=="")X.push(W$);A$=Z$}if(A$&&A$+1<$.length){let s=$.slice(A$+1);if(X.push(s),Z.tokens)V[V.length-1].value=s,RQ(V[V.length-1]),k.maxDepth+=V[V.length-1].depth}k.slashes=Q,k.parts=X}return k};NQ.exports=TO});var bQ=p((Cw,xQ)=>{var j8=G8(),S0=X8(),{MAX_LENGTH:T9,POSIX_REGEX_SOURCE:kO,REGEX_NON_SPECIAL_CHARS:EO,REGEX_SPECIAL_CHARS_BACKREF:xO,REPLACEMENTS:TQ}=j8,bO=($,J)=>{if(typeof J.expandRange==="function")return J.expandRange(...$,J);$.sort();let Z=`[${$.join("-")}]`;try{new RegExp(Z)}catch(Y){return $.map((K)=>S0.escapeRegex(K)).join("..")}return Z},OJ=($,J)=>{return`Missing ${$}: "${J}" - use "\\\\${J}" to match literal characters`},kQ=($)=>{let J=[],Z=0,Y=0,K=0,Q="",V=!1;for(let X of $){if(V===!0){Q+=X,V=!1;continue}if(X==="\\"){Q+=X,V=!0;continue}if(X==='"'){K=K===1?0:1,Q+=X;continue}if(K===0){if(X==="[")Z++;else if(X==="]"&&Z>0)Z--;else if(Z===0){if(X==="(")Y++;else if(X===")"&&Y>0)Y--;else if(X==="|"&&Y===0){J.push(Q),Q="";continue}}}Q+=X}return J.push(Q),J},vO=($)=>{let J=!1;for(let Z of $){if(J===!0){J=!1;continue}if(Z==="\\"){J=!0;continue}if(/[?*+@!()[\]{}]/.test(Z))return!1}return!0},EQ=($)=>{let J=$.trim(),Z=!0;while(Z===!0)if(Z=!1,/^@\([^\\()[\]{}|]+\)$/.test(J))J=J.slice(2,-1),Z=!0;if(!vO(J))return;return J.replace(/\\(.)/g,"$1")},hO=($)=>{let J=$.map(EQ).filter(Boolean);for(let Z=0;Z<J.length;Z++)for(let Y=Z+1;Y<J.length;Y++){let K=J[Z],Q=J[Y],V=K[0];if(!V||K!==V.repeat(K.length)||Q!==V.repeat(Q.length))continue;if(K===Q||K.startsWith(Q)||Q.startsWith(K))return!0}return!1},Y7=($,J=!0)=>{if($[0]!=="+"&&$[0]!=="*"||$[1]!=="(")return;let Z=0,Y=0,K=0,Q=!1;for(let V=1;V<$.length;V++){let X=$[V];if(Q===!0){Q=!1;continue}if(X==="\\"){Q=!0;continue}if(X==='"'){K=K===1?0:1;continue}if(K===1)continue;if(X==="["){Z++;continue}if(X==="]"&&Z>0){Z--;continue}if(Z>0)continue;if(X==="("){Y++;continue}if(X===")"){if(Y--,Y===0){if(J===!0&&V!==$.length-1)return;return{type:$[0],body:$.slice(2,V),end:V}}}}},gO=($)=>{let J=0,Z=[];while(J<$.length){let K=Y7($.slice(J),!1);if(!K||K.type!=="*")return;let Q=kQ(K.body).map((X)=>X.trim());if(Q.length!==1)return;let V=EQ(Q[0]);if(!V||V.length!==1)return;Z.push(V),J+=K.end+1}if(Z.length<1)return;return`${Z.length===1?S0.escapeRegex(Z[0]):`[${Z.map((K)=>S0.escapeRegex(K)).join("")}]`}*`},fO=($)=>{let J=0,Z=$.trim(),Y=Y7(Z);while(Y)J++,Z=Y.body.trim(),Y=Y7(Z);return J},mO=($,J)=>{if(J.maxExtglobRecursion===!1)return{risky:!1};let Z=typeof J.maxExtglobRecursion==="number"?J.maxExtglobRecursion:j8.DEFAULT_MAX_EXTGLOB_RECURSION,Y=kQ($).map((K)=>K.trim());if(Y.length>1){if(Y.some((K)=>K==="")||Y.some((K)=>/^[*?]+$/.test(K))||hO(Y))return{risky:!0}}for(let K of Y){let Q=gO(K);if(Q)return{risky:!0,safeOutput:Q};if(fO(K)>Z)return{risky:!0}}return{risky:!1}},K7=($,J)=>{if(typeof $!=="string")throw TypeError("Expected a string");$=TQ[$]||$;let Z={...J},Y=typeof Z.maxLength==="number"?Math.min(T9,Z.maxLength):T9,K=$.length;if(K>Y)throw SyntaxError(`Input length: ${K}, exceeds maximum allowed length: ${Y}`);let Q={type:"bos",value:"",output:Z.prepend||""},V=[Q],X=Z.capture?"":"?:",W=S0.isWindows(J),B=j8.globChars(W),j=j8.extglobChars(B),{DOT_LITERAL:_,PLUS_LITERAL:q,SLASH_LITERAL:H,ONE_CHAR:C,DOTS_SLASH:M,NO_DOT:I,NO_DOT_SLASH:z,NO_DOTS_SLASH:P,QMARK:D,QMARK_NO_DOT:L,STAR:R,START_ANCHOR:N}=B,x=(d)=>{return`(${X}(?:(?!${N}${d.dot?M:_}).)*?)`},b=Z.dot?"":I,v=Z.dot?D:L,m=Z.bash===!0?x(Z):R;if(Z.capture)m=`(${m})`;if(typeof Z.noext==="boolean")Z.noextglob=Z.noext;let A={input:$,index:-1,start:0,dot:Z.dot===!0,consumed:"",output:"",prefix:"",backtrack:!1,negated:!1,brackets:0,braces:0,parens:0,quotes:0,globstar:!1,tokens:V};$=S0.removePrefix($,A),K=$.length;let u=[],r=[],S=[],T=Q,k,A$=()=>A.index===K-1,s=A.peek=(d=1)=>$[A.index+d],J$=A.advance=()=>$[++A.index]||"",Z$=()=>$.slice(A.index+1),W$=(d="",Y$=0)=>{A.consumed+=d,A.index+=Y$},y$=(d)=>{A.output+=d.output!=null?d.output:d.value,W$(d.value)},Q$=()=>{let d=1;while(s()==="!"&&(s(2)!=="("||s(3)==="?"))J$(),A.start++,d++;if(d%2===0)return!1;return A.negated=!0,A.start++,!0},y=(d)=>{A[d]++,S.push(d)},n=(d)=>{A[d]--,S.pop()},a=(d)=>{if(T.type==="globstar"){let Y$=A.braces>0&&(d.type==="comma"||d.type==="brace"),g=d.extglob===!0||u.length&&(d.type==="pipe"||d.type==="paren");if(d.type!=="slash"&&d.type!=="paren"&&!Y$&&!g)A.output=A.output.slice(0,-T.output.length),T.type="star",T.value="*",T.output=m,A.output+=T.output}if(u.length&&d.type!=="paren")u[u.length-1].inner+=d.value;if(d.value||d.output)y$(d);if(T&&T.type==="text"&&d.type==="text"){T.value+=d.value,T.output=(T.output||"")+d.value;return}d.prev=T,V.push(d),T=d},c$=(d,Y$)=>{let g={...j[Y$],conditions:1,inner:""};g.prev=T,g.parens=A.parens,g.output=A.output,g.startIndex=A.index,g.tokensIndex=V.length;let t=(Z.capture?"(":"")+g.open;y("parens"),a({type:d,value:Y$,output:A.output?"":C}),a({type:"paren",extglob:!0,value:J$(),output:t}),u.push(g)},l=(d)=>{let Y$=$.slice(d.startIndex,A.index+1),g=$.slice(d.startIndex+2,A.index),t=mO(g,Z);if((d.type==="plus"||d.type==="star")&&t.risky){let M$=t.safeOutput?(d.output?"":C)+(Z.capture?`(${t.safeOutput})`:t.safeOutput):void 0,r$=V[d.tokensIndex];r$.type="text",r$.value=Y$,r$.output=M$||S0.escapeRegex(Y$);for(let K0=d.tokensIndex+1;K0<V.length;K0++)V[K0].value="",V[K0].output="",delete V[K0].suffix;A.output=d.output+r$.output,A.backtrack=!0,a({type:"paren",extglob:!0,value:k,output:""}),n("parens");return}let C$=d.close+(Z.capture?")":""),T$;if(d.type==="negate"){let M$=m;if(d.inner&&d.inner.length>1&&d.inner.includes("/"))M$=x(Z);if(M$!==m||A$()||/^\)+$/.test(Z$()))C$=d.close=`)$))${M$}`;if(d.inner.includes("*")&&(T$=Z$())&&/^\.[^\\/.]+$/.test(T$)){let r$=K7(T$,{...J,fastpaths:!1}).output;C$=d.close=`)${r$})${M$})`}if(d.prev.type==="bos")A.negatedExtglob=!0}a({type:"paren",extglob:!0,value:k,output:C$}),n("parens")};if(Z.fastpaths!==!1&&!/(^[*!]|[/()[\]{}"])/.test($)){let d=!1,Y$=$.replace(xO,(g,t,C$,T$,M$,r$)=>{if(T$==="\\")return d=!0,g;if(T$==="?"){if(t)return t+T$+(M$?D.repeat(M$.length):"");if(r$===0)return v+(M$?D.repeat(M$.length):"");return D.repeat(C$.length)}if(T$===".")return _.repeat(C$.length);if(T$==="*"){if(t)return t+T$+(M$?m:"");return m}return t?g:`\\${g}`});if(d===!0)if(Z.unescape===!0)Y$=Y$.replace(/\\/g,"");else Y$=Y$.replace(/\\+/g,(g)=>{return g.length%2===0?"\\\\":g?"\\":""});if(Y$===$&&Z.contains===!0)return A.output=$,A;return A.output=S0.wrapOutput(Y$,A,J),A}while(!A$()){if(k=J$(),k==="\x00")continue;if(k==="\\"){let g=s();if(g==="/"&&Z.bash!==!0)continue;if(g==="."||g===";")continue;if(!g){k+="\\",a({type:"text",value:k});continue}let t=/^\\+/.exec(Z$()),C$=0;if(t&&t[0].length>2){if(C$=t[0].length,A.index+=C$,C$%2!==0)k+="\\"}if(Z.unescape===!0)k=J$();else k+=J$();if(A.brackets===0){a({type:"text",value:k});continue}}if(A.brackets>0&&(k!=="]"||T.value==="["||T.value==="[^")){if(Z.posix!==!1&&k===":"){let g=T.value.slice(1);if(g.includes("[")){if(T.posix=!0,g.includes(":")){let t=T.value.lastIndexOf("["),C$=T.value.slice(0,t),T$=T.value.slice(t+2),M$=kO[T$];if(M$){if(T.value=C$+M$,A.backtrack=!0,J$(),!Q.output&&V.indexOf(T)===1)Q.output=C;continue}}}}if(k==="["&&s()!==":"||k==="-"&&s()==="]")k=`\\${k}`;if(k==="]"&&(T.value==="["||T.value==="[^"))k=`\\${k}`;if(Z.posix===!0&&k==="!"&&T.value==="[")k="^";T.value+=k,y$({value:k});continue}if(A.quotes===1&&k!=='"'){k=S0.escapeRegex(k),T.value+=k,y$({value:k});continue}if(k==='"'){if(A.quotes=A.quotes===1?0:1,Z.keepQuotes===!0)a({type:"text",value:k});continue}if(k==="("){y("parens"),a({type:"paren",value:k});continue}if(k===")"){if(A.parens===0&&Z.strictBrackets===!0)throw SyntaxError(OJ("opening","("));let g=u[u.length-1];if(g&&A.parens===g.parens+1){l(u.pop());continue}a({type:"paren",value:k,output:A.parens?")":"\\)"}),n("parens");continue}if(k==="["){if(Z.nobracket===!0||!Z$().includes("]")){if(Z.nobracket!==!0&&Z.strictBrackets===!0)throw SyntaxError(OJ("closing","]"));k=`\\${k}`}else y("brackets");a({type:"bracket",value:k});continue}if(k==="]"){if(Z.nobracket===!0||T&&T.type==="bracket"&&T.value.length===1){a({type:"text",value:k,output:`\\${k}`});continue}if(A.brackets===0){if(Z.strictBrackets===!0)throw SyntaxError(OJ("opening","["));a({type:"text",value:k,output:`\\${k}`});continue}n("brackets");let g=T.value.slice(1);if(T.posix!==!0&&g[0]==="^"&&!g.includes("/"))k=`/${k}`;if(T.value+=k,y$({value:k}),Z.literalBrackets===!1||S0.hasRegexChars(g))continue;let t=S0.escapeRegex(T.value);if(A.output=A.output.slice(0,-T.value.length),Z.literalBrackets===!0){A.output+=t,T.value=t;continue}T.value=`(${X}${t}|${T.value})`,A.output+=T.value;continue}if(k==="{"&&Z.nobrace!==!0){y("braces");let g={type:"brace",value:k,output:"(",outputIndex:A.output.length,tokensIndex:A.tokens.length};r.push(g),a(g);continue}if(k==="}"){let g=r[r.length-1];if(Z.nobrace===!0||!g){a({type:"text",value:k,output:k});continue}let t=")";if(g.dots===!0){let C$=V.slice(),T$=[];for(let M$=C$.length-1;M$>=0;M$--){if(V.pop(),C$[M$].type==="brace")break;if(C$[M$].type!=="dots")T$.unshift(C$[M$].value)}t=bO(T$,Z),A.backtrack=!0}if(g.comma!==!0&&g.dots!==!0){let C$=A.output.slice(0,g.outputIndex),T$=A.tokens.slice(g.tokensIndex);g.value=g.output="\\{",k=t="\\}",A.output=C$;for(let M$ of T$)A.output+=M$.output||M$.value}a({type:"brace",value:k,output:t}),n("braces"),r.pop();continue}if(k==="|"){if(u.length>0)u[u.length-1].conditions++;a({type:"text",value:k});continue}if(k===","){let g=k,t=r[r.length-1];if(t&&S[S.length-1]==="braces")t.comma=!0,g="|";a({type:"comma",value:k,output:g});continue}if(k==="/"){if(T.type==="dot"&&A.index===A.start+1){A.start=A.index+1,A.consumed="",A.output="",V.pop(),T=Q;continue}a({type:"slash",value:k,output:H});continue}if(k==="."){if(A.braces>0&&T.type==="dot"){if(T.value===".")T.output=_;let g=r[r.length-1];T.type="dots",T.output+=k,T.value+=k,g.dots=!0;continue}if(A.braces+A.parens===0&&T.type!=="bos"&&T.type!=="slash"){a({type:"text",value:k,output:_});continue}a({type:"dot",value:k,output:_});continue}if(k==="?"){if(!(T&&T.value==="(")&&Z.noextglob!==!0&&s()==="("&&s(2)!=="?"){c$("qmark",k);continue}if(T&&T.type==="paren"){let t=s(),C$=k;if(t==="<"&&!S0.supportsLookbehinds())throw Error("Node.js v10 or higher is required for regex lookbehinds");if(T.value==="("&&!/[!=<:]/.test(t)||t==="<"&&!/<([!=]|\w+>)/.test(Z$()))C$=`\\${k}`;a({type:"text",value:k,output:C$});continue}if(Z.dot!==!0&&(T.type==="slash"||T.type==="bos")){a({type:"qmark",value:k,output:L});continue}a({type:"qmark",value:k,output:D});continue}if(k==="!"){if(Z.noextglob!==!0&&s()==="("){if(s(2)!=="?"||!/[!=<:]/.test(s(3))){c$("negate",k);continue}}if(Z.nonegate!==!0&&A.index===0){Q$();continue}}if(k==="+"){if(Z.noextglob!==!0&&s()==="("&&s(2)!=="?"){c$("plus",k);continue}if(T&&T.value==="("||Z.regex===!1){a({type:"plus",value:k,output:q});continue}if(T&&(T.type==="bracket"||T.type==="paren"||T.type==="brace")||A.parens>0){a({type:"plus",value:k});continue}a({type:"plus",value:q});continue}if(k==="@"){if(Z.noextglob!==!0&&s()==="("&&s(2)!=="?"){a({type:"at",extglob:!0,value:k,output:""});continue}a({type:"text",value:k});continue}if(k!=="*"){if(k==="$"||k==="^")k=`\\${k}`;let g=EO.exec(Z$());if(g)k+=g[0],A.index+=g[0].length;a({type:"text",value:k});continue}if(T&&(T.type==="globstar"||T.star===!0)){T.type="star",T.star=!0,T.value+=k,T.output=m,A.backtrack=!0,A.globstar=!0,W$(k);continue}let d=Z$();if(Z.noextglob!==!0&&/^\([^?]/.test(d)){c$("star",k);continue}if(T.type==="star"){if(Z.noglobstar===!0){W$(k);continue}let g=T.prev,t=g.prev,C$=g.type==="slash"||g.type==="bos",T$=t&&(t.type==="star"||t.type==="globstar");if(Z.bash===!0&&(!C$||d[0]&&d[0]!=="/")){a({type:"star",value:k,output:""});continue}let M$=A.braces>0&&(g.type==="comma"||g.type==="brace"),r$=u.length&&(g.type==="pipe"||g.type==="paren");if(!C$&&g.type!=="paren"&&!M$&&!r$){a({type:"star",value:k,output:""});continue}while(d.slice(0,3)==="/**"){let K0=$[A.index+4];if(K0&&K0!=="/")break;d=d.slice(3),W$("/**",3)}if(g.type==="bos"&&A$()){T.type="globstar",T.value+=k,T.output=x(Z),A.output=T.output,A.globstar=!0,W$(k);continue}if(g.type==="slash"&&g.prev.type!=="bos"&&!T$&&A$()){A.output=A.output.slice(0,-(g.output+T.output).length),g.output=`(?:${g.output}`,T.type="globstar",T.output=x(Z)+(Z.strictSlashes?")":"|$)"),T.value+=k,A.globstar=!0,A.output+=g.output+T.output,W$(k);continue}if(g.type==="slash"&&g.prev.type!=="bos"&&d[0]==="/"){let K0=d[1]!==void 0?"|$":"";A.output=A.output.slice(0,-(g.output+T.output).length),g.output=`(?:${g.output}`,T.type="globstar",T.output=`${x(Z)}${H}|${H}${K0})`,T.value+=k,A.output+=g.output+T.output,A.globstar=!0,W$(k+J$()),a({type:"slash",value:"/",output:""});continue}if(g.type==="bos"&&d[0]==="/"){T.type="globstar",T.value+=k,T.output=`(?:^|${H}|${x(Z)}${H})`,A.output=T.output,A.globstar=!0,W$(k+J$()),a({type:"slash",value:"/",output:""});continue}A.output=A.output.slice(0,-T.output.length),T.type="globstar",T.output=x(Z),T.value+=k,A.output+=T.output,A.globstar=!0,W$(k);continue}let Y$={type:"star",value:k,output:m};if(Z.bash===!0){if(Y$.output=".*?",T.type==="bos"||T.type==="slash")Y$.output=b+Y$.output;a(Y$);continue}if(T&&(T.type==="bracket"||T.type==="paren")&&Z.regex===!0){Y$.output=k,a(Y$);continue}if(A.index===A.start||T.type==="slash"||T.type==="dot"){if(T.type==="dot")A.output+=z,T.output+=z;else if(Z.dot===!0)A.output+=P,T.output+=P;else A.output+=b,T.output+=b;if(s()!=="*")A.output+=C,T.output+=C}a(Y$)}while(A.brackets>0){if(Z.strictBrackets===!0)throw SyntaxError(OJ("closing","]"));A.output=S0.escapeLast(A.output,"["),n("brackets")}while(A.parens>0){if(Z.strictBrackets===!0)throw SyntaxError(OJ("closing",")"));A.output=S0.escapeLast(A.output,"("),n("parens")}while(A.braces>0){if(Z.strictBrackets===!0)throw SyntaxError(OJ("closing","}"));A.output=S0.escapeLast(A.output,"{"),n("braces")}if(Z.strictSlashes!==!0&&(T.type==="star"||T.type==="bracket"))a({type:"maybe_slash",value:"",output:`${H}?`});if(A.backtrack===!0){A.output="";for(let d of A.tokens)if(A.output+=d.output!=null?d.output:d.value,d.suffix)A.output+=d.suffix}return A};K7.fastpaths=($,J)=>{let Z={...J},Y=typeof Z.maxLength==="number"?Math.min(T9,Z.maxLength):T9,K=$.length;if(K>Y)throw SyntaxError(`Input length: ${K}, exceeds maximum allowed length: ${Y}`);$=TQ[$]||$;let Q=S0.isWindows(J),{DOT_LITERAL:V,SLASH_LITERAL:X,ONE_CHAR:W,DOTS_SLASH:B,NO_DOT:j,NO_DOTS:_,NO_DOTS_SLASH:q,STAR:H,START_ANCHOR:C}=j8.globChars(Q),M=Z.dot?_:j,I=Z.dot?q:j,z=Z.capture?"":"?:",P={negated:!1,prefix:""},D=Z.bash===!0?".*?":H;if(Z.capture)D=`(${D})`;let L=(b)=>{if(b.noglobstar===!0)return D;return`(${z}(?:(?!${C}${b.dot?B:V}).)*?)`},R=(b)=>{switch(b){case"*":return`${M}${W}${D}`;case".*":return`${V}${W}${D}`;case"*.*":return`${M}${D}${V}${W}${D}`;case"*/*":return`${M}${D}${X}${W}${I}${D}`;case"**":return M+L(Z);case"**/*":return`(?:${M}${L(Z)}${X})?${I}${W}${D}`;case"**/*.*":return`(?:${M}${L(Z)}${X})?${I}${D}${V}${W}${D}`;case"**/.*":return`(?:${M}${L(Z)}${X})?${V}${W}${D}`;default:{let v=/^(.*?)\.(\w+)$/.exec(b);if(!v)return;let m=R(v[1]);if(!m)return;return m+V+v[2]}}},N=S0.removePrefix($,P),x=R(N);if(x&&Z.strictSlashes!==!0)x+=`${X}?`;return x};xQ.exports=K7});var hQ=p((Mw,vQ)=>{var uO=u0("path"),dO=yQ(),Q7=bQ(),V7=X8(),pO=G8(),cO=($)=>$&&typeof $==="object"&&!Array.isArray($),U0=($,J,Z=!1)=>{if(Array.isArray($)){let j=$.map((q)=>U0(q,J,Z));return(q)=>{for(let H of j){let C=H(q);if(C)return C}return!1}}let Y=cO($)&&$.tokens&&$.input;if($===""||typeof $!=="string"&&!Y)throw TypeError("Expected pattern to be a non-empty string");let K=J||{},Q=V7.isWindows(J),V=Y?U0.compileRe($,J):U0.makeRe($,J,!1,!0),X=V.state;delete V.state;let W=()=>!1;if(K.ignore){let j={...J,ignore:null,onMatch:null,onResult:null};W=U0(K.ignore,j,Z)}let B=(j,_=!1)=>{let{isMatch:q,match:H,output:C}=U0.test(j,V,J,{glob:$,posix:Q}),M={glob:$,state:X,regex:V,posix:Q,input:j,output:C,match:H,isMatch:q};if(typeof K.onResult==="function")K.onResult(M);if(q===!1)return M.isMatch=!1,_?M:!1;if(W(j)){if(typeof K.onIgnore==="function")K.onIgnore(M);return M.isMatch=!1,_?M:!1}if(typeof K.onMatch==="function")K.onMatch(M);return _?M:!0};if(Z)B.state=X;return B};U0.test=($,J,Z,{glob:Y,posix:K}={})=>{if(typeof $!=="string")throw TypeError("Expected input to be a string");if($==="")return{isMatch:!1,output:""};let Q=Z||{},V=Q.format||(K?V7.toPosixSlashes:null),X=$===Y,W=X&&V?V($):$;if(X===!1)W=V?V($):$,X=W===Y;if(X===!1||Q.capture===!0)if(Q.matchBase===!0||Q.basename===!0)X=U0.matchBase($,J,Z,K);else X=J.exec(W);return{isMatch:Boolean(X),match:X,output:W}};U0.matchBase=($,J,Z,Y=V7.isWindows(Z))=>{return(J instanceof RegExp?J:U0.makeRe(J,Z)).test(uO.basename($))};U0.isMatch=($,J,Z)=>U0(J,Z)($);U0.parse=($,J)=>{if(Array.isArray($))return $.map((Z)=>U0.parse(Z,J));return Q7($,{...J,fastpaths:!1})};U0.scan=($,J)=>dO($,J);U0.compileRe=($,J,Z=!1,Y=!1)=>{if(Z===!0)return $.output;let K=J||{},Q=K.contains?"":"^",V=K.contains?"":"$",X=`${Q}(?:${$.output})${V}`;if($&&$.negated===!0)X=`^(?!${X}).*$`;let W=U0.toRegex(X,J);if(Y===!0)W.state=$;return W};U0.makeRe=($,J={},Z=!1,Y=!1)=>{if(!$||typeof $!=="string")throw TypeError("Expected a non-empty string");let K={negated:!1,fastpaths:!0};if(J.fastpaths!==!1&&($[0]==="."||$[0]==="*"))K.output=Q7.fastpaths($,J);if(!K.output)K=Q7($,J);return U0.compileRe(K,J,Z,Y)};U0.toRegex=($,J)=>{try{let Z=J||{};return new RegExp($,Z.flags||(Z.nocase?"i":""))}catch(Z){if(J&&J.debug===!0)throw Z;return/$^/}};U0.constants=pO;vQ.exports=U0});var pQ=p((Dw,dQ)=>{var fQ=u0("util"),mQ=zQ(),w1=hQ(),G7=X8(),gQ=($)=>$===""||$==="./",uQ=($)=>{let J=$.indexOf("{");return J>-1&&$.indexOf("}",J)>-1},a$=($,J,Z)=>{J=[].concat(J),$=[].concat($);let Y=new Set,K=new Set,Q=new Set,V=0,X=(j)=>{if(Q.add(j.output),Z&&Z.onResult)Z.onResult(j)};for(let j=0;j<J.length;j++){let _=w1(String(J[j]),{...Z,onResult:X},!0),q=_.state.negated||_.state.negatedExtglob;if(q)V++;for(let H of $){let C=_(H,!0);if(!(q?!C.isMatch:C.isMatch))continue;if(q)Y.add(C.output);else Y.delete(C.output),K.add(C.output)}}let B=(V===J.length?[...Q]:[...K]).filter((j)=>!Y.has(j));if(Z&&B.length===0){if(Z.failglob===!0)throw Error(`No matches found for "${J.join(", ")}"`);if(Z.nonull===!0||Z.nullglob===!0)return Z.unescape?J.map((j)=>j.replace(/\\/g,"")):J}return B};a$.match=a$;a$.matcher=($,J)=>w1($,J);a$.isMatch=($,J,Z)=>w1(J,Z)($);a$.any=a$.isMatch;a$.not=($,J,Z={})=>{J=[].concat(J).map(String);let Y=new Set,K=[],V=new Set(a$($,J,{...Z,onResult:(X)=>{if(Z.onResult)Z.onResult(X);K.push(X.output)}}));for(let X of K)if(!V.has(X))Y.add(X);return[...Y]};a$.contains=($,J,Z)=>{if(typeof $!=="string")throw TypeError(`Expected a string: "${fQ.inspect($)}"`);if(Array.isArray(J))return J.some((Y)=>a$.contains($,Y,Z));if(typeof J==="string"){if(gQ($)||gQ(J))return!1;if($.includes(J)||$.startsWith("./")&&$.slice(2).includes(J))return!0}return a$.isMatch($,J,{...Z,contains:!0})};a$.matchKeys=($,J,Z)=>{if(!G7.isObject($))throw TypeError("Expected the first argument to be an object");let Y=a$(Object.keys($),J,Z),K={};for(let Q of Y)K[Q]=$[Q];return K};a$.some=($,J,Z)=>{let Y=[].concat($);for(let K of[].concat(J)){let Q=w1(String(K),Z);if(Y.some((V)=>Q(V)))return!0}return!1};a$.every=($,J,Z)=>{let Y=[].concat($);for(let K of[].concat(J)){let Q=w1(String(K),Z);if(!Y.every((V)=>Q(V)))return!1}return!0};a$.all=($,J,Z)=>{if(typeof $!=="string")throw TypeError(`Expected a string: "${fQ.inspect($)}"`);return[].concat(J).every((Y)=>w1(Y,Z)($))};a$.capture=($,J,Z)=>{let Y=G7.isWindows(Z),Q=w1.makeRe(String($),{...Z,capture:!0}).exec(Y?G7.toPosixSlashes(J):J);if(Q)return Q.slice(1).map((V)=>V===void 0?"":V)};a$.makeRe=(...$)=>w1.makeRe(...$);a$.scan=(...$)=>w1.scan(...$);a$.parse=($,J)=>{let Z=[];for(let Y of[].concat($||[]))for(let K of mQ(String(Y),J))Z.push(w1.parse(K,J));return Z};a$.braces=($,J)=>{if(typeof $!=="string")throw TypeError("Expected a string");if(J&&J.nobrace===!0||!uQ($))return[$];return mQ($,J)};a$.braceExpand=($,J)=>{if(typeof $!=="string")throw TypeError("Expected a string");return a$.braces($,{...J,expand:!0})};a$.hasBraces=uQ;dQ.exports=a$});var lQ=p((Pw,cQ)=>{/*!
|
|
17
|
+
*/var h4=u0("util"),eK=aK(),tK=($)=>$!==null&&typeof $==="object"&&!Array.isArray($),g4=($)=>{return(J)=>$===!0?Number(J):String(J)},n6=($)=>{return typeof $==="number"||typeof $==="string"&&$!==""},V8=($)=>Number.isInteger(+$),a6=($)=>{let J=`${$}`,Z=-1;if(J[0]==="-")J=J.slice(1);if(J==="0")return!1;while(J[++Z]==="0");return Z>0},f4=($,J,Z)=>{if(typeof $==="string"||typeof J==="string")return!0;return Z.stringify===!0},m4=($,J,Z)=>{if(J>0){let Y=$[0]==="-"?"-":"";if(Y)$=$.slice(1);$=Y+$.padStart(Y?J-1:J,"0")}if(Z===!1)return String($);return $},T9=($,J)=>{let Z=$[0]==="-"?"-":"";if(Z)$=$.slice(1),J--;while($.length<J)$="0"+$;return Z?"-"+$:$},u4=($,J,Z)=>{$.negatives.sort((X,W)=>X<W?-1:X>W?1:0),$.positives.sort((X,W)=>X<W?-1:X>W?1:0);let Y=J.capture?"":"?:",K="",Q="",V;if($.positives.length)K=$.positives.map((X)=>T9(String(X),Z)).join("|");if($.negatives.length)Q=`-(${Y}${$.negatives.map((X)=>T9(String(X),Z)).join("|")})`;if(K&&Q)V=`${K}|${Q}`;else V=K||Q;if(J.wrap)return`(${Y}${V})`;return V},$Q=($,J,Z,Y)=>{if(Z)return eK($,J,{wrap:!1,...Y});let K=String.fromCharCode($);if($===J)return K;let Q=String.fromCharCode(J);return`[${K}-${Q}]`},JQ=($,J,Z)=>{if(Array.isArray($)){let Y=Z.wrap===!0,K=Z.capture?"":"?:";return Y?`(${K}${$.join("|")})`:$.join("|")}return eK($,J,Z)},ZQ=(...$)=>{return RangeError("Invalid range arguments: "+h4.inspect(...$))},YQ=($,J,Z)=>{if(Z.strictRanges===!0)throw ZQ([$,J]);return[]},d4=($,J)=>{if(J.strictRanges===!0)throw TypeError(`Expected step "${$}" to be a number`);return[]},p4=($,J,Z=1,Y={})=>{let K=Number($),Q=Number(J);if(!Number.isInteger(K)||!Number.isInteger(Q)){if(Y.strictRanges===!0)throw ZQ([$,J]);return[]}if(K===0)K=0;if(Q===0)Q=0;let V=K>Q,X=String($),W=String(J),_=String(Z);Z=Math.max(Math.abs(Z),1);let j=a6(X)||a6(W)||a6(_),H=j?Math.max(X.length,W.length,_.length):0,q=j===!1&&f4($,J,Y)===!1,U=Y.transform||g4(q);if(Y.toRegex&&Z===1)return $Q(T9($,H),T9(J,H),!0,Y);let z={negatives:[],positives:[]},M=(P)=>z[P<0?"negatives":"positives"].push(Math.abs(P)),I=[],C=0;while(V?K>=Q:K<=Q){if(Y.toRegex===!0&&Z>1)M(K);else I.push(m4(U(K,C),H,q));K=V?K-Z:K+Z,C++}if(Y.toRegex===!0)return Z>1?u4(z,Y,H):JQ(I,null,{wrap:!1,...Y});return I},c4=($,J,Z=1,Y={})=>{if(!V8($)&&$.length>1||!V8(J)&&J.length>1)return YQ($,J,Y);let K=Y.transform||((q)=>String.fromCharCode(q)),Q=`${$}`.charCodeAt(0),V=`${J}`.charCodeAt(0),X=Q>V,W=Math.min(Q,V),_=Math.max(Q,V);if(Y.toRegex&&Z===1)return $Q(W,_,!1,Y);let j=[],H=0;while(X?Q>=V:Q<=V)j.push(K(Q,H)),Q=X?Q-Z:Q+Z,H++;if(Y.toRegex===!0)return JQ(j,null,{wrap:!1,options:Y});return j},y9=($,J,Z,Y={})=>{if(J==null&&n6($))return[$];if(!n6($)||!n6(J))return YQ($,J,Y);if(typeof Z==="function")return y9($,J,1,{transform:Z});if(tK(Z))return y9($,J,0,Z);let K={...Y};if(K.capture===!0)K.wrap=!0;if(Z=Z||K.step||1,!V8(Z)){if(Z!=null&&!tK(Z))return d4(Z,K);return y9($,J,1,Z)}if(V8($)&&V8(J))return p4($,J,Z,K);return c4($,J,Math.max(Math.abs(Z),1),K)};KQ.exports=y9});var GQ=p((Fw,VQ)=>{var l4=t6(),QQ=L9(),o4=($,J={})=>{let Z=(Y,K={})=>{let Q=QQ.isInvalidBrace(K),V=Y.invalid===!0&&J.escapeInvalid===!0,X=Q===!0||V===!0,W=J.escapeInvalid===!0?"\\":"",_="";if(Y.isOpen===!0)return W+Y.value;if(Y.isClose===!0)return console.log("node.isClose",W,Y.value),W+Y.value;if(Y.type==="open")return X?W+Y.value:"(";if(Y.type==="close")return X?W+Y.value:")";if(Y.type==="comma")return Y.prev.type==="comma"?"":X?Y.value:"|";if(Y.value)return Y.value;if(Y.nodes&&Y.ranges>0){let j=QQ.reduce(Y.nodes),H=l4(...j,{...J,wrap:!1,toRegex:!0,strictZeros:!0});if(H.length!==0)return j.length>1&&H.length>1?`(${H})`:H}if(Y.nodes)for(let j of Y.nodes)_+=Z(j,Y);return _};return Z($)};VQ.exports=o4});var jQ=p((zw,WQ)=>{var r4=t6(),XQ=N9(),_J=L9(),L2=($="",J="",Z=!1)=>{let Y=[];if($=[].concat($),J=[].concat(J),!J.length)return $;if(!$.length)return Z?_J.flatten(J).map((K)=>`{${K}}`):J;for(let K of $)if(Array.isArray(K))for(let Q of K)Y.push(L2(Q,J,Z));else for(let Q of J){if(Z===!0&&typeof Q==="string")Q=`{${Q}}`;Y.push(Array.isArray(Q)?L2(K,Q,Z):K+Q)}return _J.flatten(Y)},i4=($,J={})=>{let Z=J.rangeLimit===void 0?1000:J.rangeLimit,Y=(K,Q={})=>{K.queue=[];let V=Q,X=Q.queue;while(V.type!=="brace"&&V.type!=="root"&&V.parent)V=V.parent,X=V.queue;if(K.invalid||K.dollar){X.push(L2(X.pop(),XQ(K,J)));return}if(K.type==="brace"&&K.invalid!==!0&&K.nodes.length===2){X.push(L2(X.pop(),["{}"]));return}if(K.nodes&&K.ranges>0){let H=_J.reduce(K.nodes);if(_J.exceedsLimit(...H,J.step,Z))throw RangeError("expanded array length exceeds range limit. Use options.rangeLimit to increase or disable the limit.");let q=r4(...H,J);if(q.length===0)q=XQ(K,J);X.push(L2(X.pop(),q)),K.nodes=[];return}let W=_J.encloseBrace(K),_=K.queue,j=K;while(j.type!=="brace"&&j.type!=="root"&&j.parent)j=j.parent,_=j.queue;for(let H=0;H<K.nodes.length;H++){let q=K.nodes[H];if(q.type==="comma"&&K.type==="brace"){if(H===1)_.push("");_.push("");continue}if(q.type==="close"){X.push(L2(X.pop(),_,W));continue}if(q.value&&q.type!=="open"){_.push(L2(_.pop(),q.value));continue}if(q.nodes)Y(q,K)}return _};return _J.flatten(Y($))};WQ.exports=i4});var BQ=p((Cw,UQ)=>{UQ.exports={MAX_LENGTH:1e4,CHAR_0:"0",CHAR_9:"9",CHAR_UPPERCASE_A:"A",CHAR_LOWERCASE_A:"a",CHAR_UPPERCASE_Z:"Z",CHAR_LOWERCASE_Z:"z",CHAR_LEFT_PARENTHESES:"(",CHAR_RIGHT_PARENTHESES:")",CHAR_ASTERISK:"*",CHAR_AMPERSAND:"&",CHAR_AT:"@",CHAR_BACKSLASH:"\\",CHAR_BACKTICK:"`",CHAR_CARRIAGE_RETURN:"\r",CHAR_CIRCUMFLEX_ACCENT:"^",CHAR_COLON:":",CHAR_COMMA:",",CHAR_DOLLAR:"$",CHAR_DOT:".",CHAR_DOUBLE_QUOTE:'"',CHAR_EQUAL:"=",CHAR_EXCLAMATION_MARK:"!",CHAR_FORM_FEED:"\f",CHAR_FORWARD_SLASH:"/",CHAR_HASH:"#",CHAR_HYPHEN_MINUS:"-",CHAR_LEFT_ANGLE_BRACKET:"<",CHAR_LEFT_CURLY_BRACE:"{",CHAR_LEFT_SQUARE_BRACKET:"[",CHAR_LINE_FEED:`
|
|
18
|
+
`,CHAR_NO_BREAK_SPACE:"\xA0",CHAR_PERCENT:"%",CHAR_PLUS:"+",CHAR_QUESTION_MARK:"?",CHAR_RIGHT_ANGLE_BRACKET:">",CHAR_RIGHT_CURLY_BRACE:"}",CHAR_RIGHT_SQUARE_BRACKET:"]",CHAR_SEMICOLON:";",CHAR_SINGLE_QUOTE:"'",CHAR_SPACE:" ",CHAR_TAB:"\t",CHAR_UNDERSCORE:"_",CHAR_VERTICAL_LINE:"|",CHAR_ZERO_WIDTH_NOBREAK_SPACE:"\uFEFF"}});var FQ=p((Mw,qQ)=>{var s4=N9(),{MAX_LENGTH:HQ,CHAR_BACKSLASH:e6,CHAR_BACKTICK:n4,CHAR_COMMA:a4,CHAR_DOT:t4,CHAR_LEFT_PARENTHESES:e4,CHAR_RIGHT_PARENTHESES:$O,CHAR_LEFT_CURLY_BRACE:JO,CHAR_RIGHT_CURLY_BRACE:ZO,CHAR_LEFT_SQUARE_BRACKET:_Q,CHAR_RIGHT_SQUARE_BRACKET:OQ,CHAR_DOUBLE_QUOTE:YO,CHAR_SINGLE_QUOTE:KO,CHAR_NO_BREAK_SPACE:QO,CHAR_ZERO_WIDTH_NOBREAK_SPACE:VO}=BQ(),GO=($,J={})=>{if(typeof $!=="string")throw TypeError("Expected a string");let Z=J||{},Y=typeof Z.maxLength==="number"?Math.min(HQ,Z.maxLength):HQ;if($.length>Y)throw SyntaxError(`Input length (${$.length}), exceeds max characters (${Y})`);let K={type:"root",input:$,nodes:[]},Q=[K],V=K,X=K,W=0,_=$.length,j=0,H=0,q,U=()=>$[j++],z=(M)=>{if(M.type==="text"&&X.type==="dot")X.type="text";if(X&&X.type==="text"&&M.type==="text"){X.value+=M.value;return}return V.nodes.push(M),M.parent=V,M.prev=X,X=M,M};z({type:"bos"});while(j<_){if(V=Q[Q.length-1],q=U(),q===VO||q===QO)continue;if(q===e6){z({type:"text",value:(J.keepEscaping?q:"")+U()});continue}if(q===OQ){z({type:"text",value:"\\"+q});continue}if(q===_Q){W++;let M;while(j<_&&(M=U())){if(q+=M,M===_Q){W++;continue}if(M===e6){q+=U();continue}if(M===OQ){if(W--,W===0)break}}z({type:"text",value:q});continue}if(q===e4){V=z({type:"paren",nodes:[]}),Q.push(V),z({type:"text",value:q});continue}if(q===$O){if(V.type!=="paren"){z({type:"text",value:q});continue}V=Q.pop(),z({type:"text",value:q}),V=Q[Q.length-1];continue}if(q===YO||q===KO||q===n4){let M=q,I;if(J.keepQuotes!==!0)q="";while(j<_&&(I=U())){if(I===e6){q+=I+U();continue}if(I===M){if(J.keepQuotes===!0)q+=I;break}q+=I}z({type:"text",value:q});continue}if(q===JO){H++;let I={type:"brace",open:!0,close:!1,dollar:X.value&&X.value.slice(-1)==="$"||V.dollar===!0,depth:H,commas:0,ranges:0,nodes:[]};V=z(I),Q.push(V),z({type:"open",value:q});continue}if(q===ZO){if(V.type!=="brace"){z({type:"text",value:q});continue}let M="close";V=Q.pop(),V.close=!0,z({type:M,value:q}),H--,V=Q[Q.length-1];continue}if(q===a4&&H>0){if(V.ranges>0){V.ranges=0;let M=V.nodes.shift();V.nodes=[M,{type:"text",value:s4(V)}]}z({type:"comma",value:q}),V.commas++;continue}if(q===t4&&H>0&&V.commas===0){let M=V.nodes;if(H===0||M.length===0){z({type:"text",value:q});continue}if(X.type==="dot"){if(V.range=[],X.value+=q,X.type="range",V.nodes.length!==3&&V.nodes.length!==5){V.invalid=!0,V.ranges=0,X.type="text";continue}V.ranges++,V.args=[];continue}if(X.type==="range"){M.pop();let I=M[M.length-1];I.value+=X.value+q,X=I,V.ranges--;continue}z({type:"dot",value:q});continue}z({type:"text",value:q})}do if(V=Q.pop(),V.type!=="root"){V.nodes.forEach((C)=>{if(!C.nodes){if(C.type==="open")C.isOpen=!0;if(C.type==="close")C.isClose=!0;if(!C.nodes)C.type="text";C.invalid=!0}});let M=Q[Q.length-1],I=M.nodes.indexOf(V);M.nodes.splice(I,1,...V.nodes)}while(Q.length>0);return z({type:"eos"}),K};qQ.exports=GO});var MQ=p((Dw,CQ)=>{var zQ=N9(),XO=GQ(),WO=jQ(),jO=FQ(),d0=($,J={})=>{let Z=[];if(Array.isArray($))for(let Y of $){let K=d0.create(Y,J);if(Array.isArray(K))Z.push(...K);else Z.push(K)}else Z=[].concat(d0.create($,J));if(J&&J.expand===!0&&J.nodupes===!0)Z=[...new Set(Z)];return Z};d0.parse=($,J={})=>jO($,J);d0.stringify=($,J={})=>{if(typeof $==="string")return zQ(d0.parse($,J),J);return zQ($,J)};d0.compile=($,J={})=>{if(typeof $==="string")$=d0.parse($,J);return XO($,J)};d0.expand=($,J={})=>{if(typeof $==="string")$=d0.parse($,J);let Z=WO($,J);if(J.noempty===!0)Z=Z.filter(Boolean);if(J.nodupes===!0)Z=[...new Set(Z)];return Z};d0.create=($,J={})=>{if($===""||$.length<3)return[$];return J.expand!==!0?d0.compile($,J):d0.expand($,J)};CQ.exports=d0});var G8=p((Pw,PQ)=>{var UO=u0("path"),DQ={DOT_LITERAL:"\\.",PLUS_LITERAL:"\\+",QMARK_LITERAL:"\\?",SLASH_LITERAL:"\\/",ONE_CHAR:"(?=.)",QMARK:"[^/]",END_ANCHOR:"(?:\\/|$)",DOTS_SLASH:"\\.{1,2}(?:\\/|$)",NO_DOT:"(?!\\.)",NO_DOTS:"(?!(?:^|\\/)\\.{1,2}(?:\\/|$))",NO_DOT_SLASH:"(?!\\.{0,1}(?:\\/|$))",NO_DOTS_SLASH:"(?!\\.{1,2}(?:\\/|$))",QMARK_NO_DOT:"[^.\\/]",STAR:"[^/]*?",START_ANCHOR:"(?:^|\\/)"},BO={...DQ,SLASH_LITERAL:"[\\\\/]",QMARK:"[^\\\\/]",STAR:"[^\\\\/]*?",DOTS_SLASH:"\\.{1,2}(?:[\\\\/]|$)",NO_DOT:"(?!\\.)",NO_DOTS:"(?!(?:^|[\\\\/])\\.{1,2}(?:[\\\\/]|$))",NO_DOT_SLASH:"(?!\\.{0,1}(?:[\\\\/]|$))",NO_DOTS_SLASH:"(?!\\.{1,2}(?:[\\\\/]|$))",QMARK_NO_DOT:"[^.\\\\/]",START_ANCHOR:"(?:^|[\\\\/])",END_ANCHOR:"(?:[\\\\/]|$)"},HO={__proto__:null,alnum:"a-zA-Z0-9",alpha:"a-zA-Z",ascii:"\\x00-\\x7F",blank:" \\t",cntrl:"\\x00-\\x1F\\x7F",digit:"0-9",graph:"\\x21-\\x7E",lower:"a-z",print:"\\x20-\\x7E ",punct:"\\-!\"#$%&'()\\*+,./:;<=>?@[\\]^_`{|}~",space:" \\t\\r\\n\\v\\f",upper:"A-Z",word:"A-Za-z0-9_",xdigit:"A-Fa-f0-9"};PQ.exports={DEFAULT_MAX_EXTGLOB_RECURSION:0,MAX_LENGTH:65536,POSIX_REGEX_SOURCE:HO,REGEX_BACKSLASH:/\\(?![*+?^${}(|)[\]])/g,REGEX_NON_SPECIAL_CHARS:/^[^@![\].,$*+?^{}()|\\/]+/,REGEX_SPECIAL_CHARS:/[-*+?.^${}(|)[\]]/,REGEX_SPECIAL_CHARS_BACKREF:/(\\?)((\W)(\3*))/g,REGEX_SPECIAL_CHARS_GLOBAL:/([-*+?.^${}(|)[\]])/g,REGEX_REMOVE_BACKSLASH:/(?:\[.*?[^\\]\]|\\(?=.))/g,REPLACEMENTS:{__proto__:null,"***":"*","**/**":"**","**/**/**":"**"},CHAR_0:48,CHAR_9:57,CHAR_UPPERCASE_A:65,CHAR_LOWERCASE_A:97,CHAR_UPPERCASE_Z:90,CHAR_LOWERCASE_Z:122,CHAR_LEFT_PARENTHESES:40,CHAR_RIGHT_PARENTHESES:41,CHAR_ASTERISK:42,CHAR_AMPERSAND:38,CHAR_AT:64,CHAR_BACKWARD_SLASH:92,CHAR_CARRIAGE_RETURN:13,CHAR_CIRCUMFLEX_ACCENT:94,CHAR_COLON:58,CHAR_COMMA:44,CHAR_DOT:46,CHAR_DOUBLE_QUOTE:34,CHAR_EQUAL:61,CHAR_EXCLAMATION_MARK:33,CHAR_FORM_FEED:12,CHAR_FORWARD_SLASH:47,CHAR_GRAVE_ACCENT:96,CHAR_HASH:35,CHAR_HYPHEN_MINUS:45,CHAR_LEFT_ANGLE_BRACKET:60,CHAR_LEFT_CURLY_BRACE:123,CHAR_LEFT_SQUARE_BRACKET:91,CHAR_LINE_FEED:10,CHAR_NO_BREAK_SPACE:160,CHAR_PERCENT:37,CHAR_PLUS:43,CHAR_QUESTION_MARK:63,CHAR_RIGHT_ANGLE_BRACKET:62,CHAR_RIGHT_CURLY_BRACE:125,CHAR_RIGHT_SQUARE_BRACKET:93,CHAR_SEMICOLON:59,CHAR_SINGLE_QUOTE:39,CHAR_SPACE:32,CHAR_TAB:9,CHAR_UNDERSCORE:95,CHAR_VERTICAL_LINE:124,CHAR_ZERO_WIDTH_NOBREAK_SPACE:65279,SEP:UO.sep,extglobChars($){return{"!":{type:"negate",open:"(?:(?!(?:",close:`))${$.STAR})`},"?":{type:"qmark",open:"(?:",close:")?"},"+":{type:"plus",open:"(?:",close:")+"},"*":{type:"star",open:"(?:",close:")*"},"@":{type:"at",open:"(?:",close:")"}}},globChars($){return $===!0?BO:DQ}}});var X8=p((MO)=>{var _O=u0("path"),OO=process.platform==="win32",{REGEX_BACKSLASH:qO,REGEX_REMOVE_BACKSLASH:FO,REGEX_SPECIAL_CHARS:zO,REGEX_SPECIAL_CHARS_GLOBAL:CO}=G8();MO.isObject=($)=>$!==null&&typeof $==="object"&&!Array.isArray($);MO.hasRegexChars=($)=>zO.test($);MO.isRegexChar=($)=>$.length===1&&MO.hasRegexChars($);MO.escapeRegex=($)=>$.replace(CO,"\\$1");MO.toPosixSlashes=($)=>$.replace(qO,"/");MO.removeBackslashes=($)=>{return $.replace(FO,(J)=>{return J==="\\"?"":J})};MO.supportsLookbehinds=()=>{let $=process.version.slice(1).split(".").map(Number);if($.length===3&&$[0]>=9||$[0]===8&&$[1]>=10)return!0;return!1};MO.isWindows=($)=>{if($&&typeof $.windows==="boolean")return $.windows;return OO===!0||_O.sep==="\\"};MO.escapeLast=($,J,Z)=>{let Y=$.lastIndexOf(J,Z);if(Y===-1)return $;if($[Y-1]==="\\")return MO.escapeLast($,J,Y-1);return`${$.slice(0,Y)}\\${$.slice(Y)}`};MO.removePrefix=($,J={})=>{let Z=$;if(Z.startsWith("./"))Z=Z.slice(2),J.prefix="./";return Z};MO.wrapOutput=($,J={},Z={})=>{let Y=Z.contains?"":"^",K=Z.contains?"":"$",Q=`${Y}(?:${$})${K}`;if(J.negated===!0)Q=`(?:^(?!${Q}).*$)`;return Q}});var kQ=p((Aw,TQ)=>{var SQ=X8(),{CHAR_ASTERISK:$7,CHAR_AT:yO,CHAR_BACKWARD_SLASH:W8,CHAR_COMMA:TO,CHAR_DOT:J7,CHAR_EXCLAMATION_MARK:Z7,CHAR_FORWARD_SLASH:yQ,CHAR_LEFT_CURLY_BRACE:Y7,CHAR_LEFT_PARENTHESES:K7,CHAR_LEFT_SQUARE_BRACKET:kO,CHAR_PLUS:EO,CHAR_QUESTION_MARK:wQ,CHAR_RIGHT_CURLY_BRACE:xO,CHAR_RIGHT_PARENTHESES:RQ,CHAR_RIGHT_SQUARE_BRACKET:bO}=G8(),LQ=($)=>{return $===yQ||$===W8},NQ=($)=>{if($.isPrefix!==!0)$.depth=$.isGlobstar?1/0:1},vO=($,J)=>{let Z=J||{},Y=$.length-1,K=Z.parts===!0||Z.scanToEnd===!0,Q=[],V=[],X=[],W=$,_=-1,j=0,H=0,q=!1,U=!1,z=!1,M=!1,I=!1,C=!1,P=!1,D=!1,L=!1,R=!1,N=0,x,b,v={value:"",depth:0,isGlob:!1},m=()=>_>=Y,A=()=>W.charCodeAt(_+1),u=()=>{return x=b,W.charCodeAt(++_)};while(_<Y){b=u();let A$;if(b===W8){if(P=v.backslashes=!0,b=u(),b===Y7)C=!0;continue}if(C===!0||b===Y7){N++;while(m()!==!0&&(b=u())){if(b===W8){P=v.backslashes=!0,u();continue}if(b===Y7){N++;continue}if(C!==!0&&b===J7&&(b=u())===J7){if(q=v.isBrace=!0,z=v.isGlob=!0,R=!0,K===!0)continue;break}if(C!==!0&&b===TO){if(q=v.isBrace=!0,z=v.isGlob=!0,R=!0,K===!0)continue;break}if(b===xO){if(N--,N===0){C=!1,q=v.isBrace=!0,R=!0;break}}}if(K===!0)continue;break}if(b===yQ){if(Q.push(_),V.push(v),v={value:"",depth:0,isGlob:!1},R===!0)continue;if(x===J7&&_===j+1){j+=2;continue}H=_+1;continue}if(Z.noext!==!0){if((b===EO||b===yO||b===$7||b===wQ||b===Z7)===!0&&A()===K7){if(z=v.isGlob=!0,M=v.isExtglob=!0,R=!0,b===Z7&&_===j)L=!0;if(K===!0){while(m()!==!0&&(b=u())){if(b===W8){P=v.backslashes=!0,b=u();continue}if(b===RQ){z=v.isGlob=!0,R=!0;break}}continue}break}}if(b===$7){if(x===$7)I=v.isGlobstar=!0;if(z=v.isGlob=!0,R=!0,K===!0)continue;break}if(b===wQ){if(z=v.isGlob=!0,R=!0,K===!0)continue;break}if(b===kO){while(m()!==!0&&(A$=u())){if(A$===W8){P=v.backslashes=!0,u();continue}if(A$===bO){U=v.isBracket=!0,z=v.isGlob=!0,R=!0;break}}if(K===!0)continue;break}if(Z.nonegate!==!0&&b===Z7&&_===j){D=v.negated=!0,j++;continue}if(Z.noparen!==!0&&b===K7){if(z=v.isGlob=!0,K===!0){while(m()!==!0&&(b=u())){if(b===K7){P=v.backslashes=!0,b=u();continue}if(b===RQ){R=!0;break}}continue}break}if(z===!0){if(R=!0,K===!0)continue;break}}if(Z.noext===!0)M=!1,z=!1;let r=W,S="",T="";if(j>0)S=W.slice(0,j),W=W.slice(j),H-=j;if(r&&z===!0&&H>0)r=W.slice(0,H),T=W.slice(H);else if(z===!0)r="",T=W;else r=W;if(r&&r!==""&&r!=="/"&&r!==W){if(LQ(r.charCodeAt(r.length-1)))r=r.slice(0,-1)}if(Z.unescape===!0){if(T)T=SQ.removeBackslashes(T);if(r&&P===!0)r=SQ.removeBackslashes(r)}let k={prefix:S,input:$,start:j,base:r,glob:T,isBrace:q,isBracket:U,isGlob:z,isExtglob:M,isGlobstar:I,negated:D,negatedExtglob:L};if(Z.tokens===!0){if(k.maxDepth=0,!LQ(b))V.push(v);k.tokens=V}if(Z.parts===!0||Z.tokens===!0){let A$;for(let s=0;s<Q.length;s++){let J$=A$?A$+1:j,Z$=Q[s],W$=$.slice(J$,Z$);if(Z.tokens){if(s===0&&j!==0)V[s].isPrefix=!0,V[s].value=S;else V[s].value=W$;NQ(V[s]),k.maxDepth+=V[s].depth}if(s!==0||W$!=="")X.push(W$);A$=Z$}if(A$&&A$+1<$.length){let s=$.slice(A$+1);if(X.push(s),Z.tokens)V[V.length-1].value=s,NQ(V[V.length-1]),k.maxDepth+=V[V.length-1].depth}k.slashes=Q,k.parts=X}return k};TQ.exports=vO});var hQ=p((Sw,vQ)=>{var j8=G8(),S0=X8(),{MAX_LENGTH:k9,POSIX_REGEX_SOURCE:hO,REGEX_NON_SPECIAL_CHARS:gO,REGEX_SPECIAL_CHARS_BACKREF:fO,REPLACEMENTS:EQ}=j8,mO=($,J)=>{if(typeof J.expandRange==="function")return J.expandRange(...$,J);$.sort();let Z=`[${$.join("-")}]`;try{new RegExp(Z)}catch(Y){return $.map((K)=>S0.escapeRegex(K)).join("..")}return Z},OJ=($,J)=>{return`Missing ${$}: "${J}" - use "\\\\${J}" to match literal characters`},xQ=($)=>{let J=[],Z=0,Y=0,K=0,Q="",V=!1;for(let X of $){if(V===!0){Q+=X,V=!1;continue}if(X==="\\"){Q+=X,V=!0;continue}if(X==='"'){K=K===1?0:1,Q+=X;continue}if(K===0){if(X==="[")Z++;else if(X==="]"&&Z>0)Z--;else if(Z===0){if(X==="(")Y++;else if(X===")"&&Y>0)Y--;else if(X==="|"&&Y===0){J.push(Q),Q="";continue}}}Q+=X}return J.push(Q),J},uO=($)=>{let J=!1;for(let Z of $){if(J===!0){J=!1;continue}if(Z==="\\"){J=!0;continue}if(/[?*+@!()[\]{}]/.test(Z))return!1}return!0},bQ=($)=>{let J=$.trim(),Z=!0;while(Z===!0)if(Z=!1,/^@\([^\\()[\]{}|]+\)$/.test(J))J=J.slice(2,-1),Z=!0;if(!uO(J))return;return J.replace(/\\(.)/g,"$1")},dO=($)=>{let J=$.map(bQ).filter(Boolean);for(let Z=0;Z<J.length;Z++)for(let Y=Z+1;Y<J.length;Y++){let K=J[Z],Q=J[Y],V=K[0];if(!V||K!==V.repeat(K.length)||Q!==V.repeat(Q.length))continue;if(K===Q||K.startsWith(Q)||Q.startsWith(K))return!0}return!1},Q7=($,J=!0)=>{if($[0]!=="+"&&$[0]!=="*"||$[1]!=="(")return;let Z=0,Y=0,K=0,Q=!1;for(let V=1;V<$.length;V++){let X=$[V];if(Q===!0){Q=!1;continue}if(X==="\\"){Q=!0;continue}if(X==='"'){K=K===1?0:1;continue}if(K===1)continue;if(X==="["){Z++;continue}if(X==="]"&&Z>0){Z--;continue}if(Z>0)continue;if(X==="("){Y++;continue}if(X===")"){if(Y--,Y===0){if(J===!0&&V!==$.length-1)return;return{type:$[0],body:$.slice(2,V),end:V}}}}},pO=($)=>{let J=0,Z=[];while(J<$.length){let K=Q7($.slice(J),!1);if(!K||K.type!=="*")return;let Q=xQ(K.body).map((X)=>X.trim());if(Q.length!==1)return;let V=bQ(Q[0]);if(!V||V.length!==1)return;Z.push(V),J+=K.end+1}if(Z.length<1)return;return`${Z.length===1?S0.escapeRegex(Z[0]):`[${Z.map((K)=>S0.escapeRegex(K)).join("")}]`}*`},cO=($)=>{let J=0,Z=$.trim(),Y=Q7(Z);while(Y)J++,Z=Y.body.trim(),Y=Q7(Z);return J},lO=($,J)=>{if(J.maxExtglobRecursion===!1)return{risky:!1};let Z=typeof J.maxExtglobRecursion==="number"?J.maxExtglobRecursion:j8.DEFAULT_MAX_EXTGLOB_RECURSION,Y=xQ($).map((K)=>K.trim());if(Y.length>1){if(Y.some((K)=>K==="")||Y.some((K)=>/^[*?]+$/.test(K))||dO(Y))return{risky:!0}}for(let K of Y){let Q=pO(K);if(Q)return{risky:!0,safeOutput:Q};if(cO(K)>Z)return{risky:!0}}return{risky:!1}},V7=($,J)=>{if(typeof $!=="string")throw TypeError("Expected a string");$=EQ[$]||$;let Z={...J},Y=typeof Z.maxLength==="number"?Math.min(k9,Z.maxLength):k9,K=$.length;if(K>Y)throw SyntaxError(`Input length: ${K}, exceeds maximum allowed length: ${Y}`);let Q={type:"bos",value:"",output:Z.prepend||""},V=[Q],X=Z.capture?"":"?:",W=S0.isWindows(J),_=j8.globChars(W),j=j8.extglobChars(_),{DOT_LITERAL:H,PLUS_LITERAL:q,SLASH_LITERAL:U,ONE_CHAR:z,DOTS_SLASH:M,NO_DOT:I,NO_DOT_SLASH:C,NO_DOTS_SLASH:P,QMARK:D,QMARK_NO_DOT:L,STAR:R,START_ANCHOR:N}=_,x=(d)=>{return`(${X}(?:(?!${N}${d.dot?M:H}).)*?)`},b=Z.dot?"":I,v=Z.dot?D:L,m=Z.bash===!0?x(Z):R;if(Z.capture)m=`(${m})`;if(typeof Z.noext==="boolean")Z.noextglob=Z.noext;let A={input:$,index:-1,start:0,dot:Z.dot===!0,consumed:"",output:"",prefix:"",backtrack:!1,negated:!1,brackets:0,braces:0,parens:0,quotes:0,globstar:!1,tokens:V};$=S0.removePrefix($,A),K=$.length;let u=[],r=[],S=[],T=Q,k,A$=()=>A.index===K-1,s=A.peek=(d=1)=>$[A.index+d],J$=A.advance=()=>$[++A.index]||"",Z$=()=>$.slice(A.index+1),W$=(d="",Y$=0)=>{A.consumed+=d,A.index+=Y$},y$=(d)=>{A.output+=d.output!=null?d.output:d.value,W$(d.value)},Q$=()=>{let d=1;while(s()==="!"&&(s(2)!=="("||s(3)==="?"))J$(),A.start++,d++;if(d%2===0)return!1;return A.negated=!0,A.start++,!0},y=(d)=>{A[d]++,S.push(d)},n=(d)=>{A[d]--,S.pop()},a=(d)=>{if(T.type==="globstar"){let Y$=A.braces>0&&(d.type==="comma"||d.type==="brace"),g=d.extglob===!0||u.length&&(d.type==="pipe"||d.type==="paren");if(d.type!=="slash"&&d.type!=="paren"&&!Y$&&!g)A.output=A.output.slice(0,-T.output.length),T.type="star",T.value="*",T.output=m,A.output+=T.output}if(u.length&&d.type!=="paren")u[u.length-1].inner+=d.value;if(d.value||d.output)y$(d);if(T&&T.type==="text"&&d.type==="text"){T.value+=d.value,T.output=(T.output||"")+d.value;return}d.prev=T,V.push(d),T=d},c$=(d,Y$)=>{let g={...j[Y$],conditions:1,inner:""};g.prev=T,g.parens=A.parens,g.output=A.output,g.startIndex=A.index,g.tokensIndex=V.length;let t=(Z.capture?"(":"")+g.open;y("parens"),a({type:d,value:Y$,output:A.output?"":z}),a({type:"paren",extglob:!0,value:J$(),output:t}),u.push(g)},l=(d)=>{let Y$=$.slice(d.startIndex,A.index+1),g=$.slice(d.startIndex+2,A.index),t=lO(g,Z);if((d.type==="plus"||d.type==="star")&&t.risky){let M$=t.safeOutput?(d.output?"":z)+(Z.capture?`(${t.safeOutput})`:t.safeOutput):void 0,r$=V[d.tokensIndex];r$.type="text",r$.value=Y$,r$.output=M$||S0.escapeRegex(Y$);for(let K0=d.tokensIndex+1;K0<V.length;K0++)V[K0].value="",V[K0].output="",delete V[K0].suffix;A.output=d.output+r$.output,A.backtrack=!0,a({type:"paren",extglob:!0,value:k,output:""}),n("parens");return}let C$=d.close+(Z.capture?")":""),T$;if(d.type==="negate"){let M$=m;if(d.inner&&d.inner.length>1&&d.inner.includes("/"))M$=x(Z);if(M$!==m||A$()||/^\)+$/.test(Z$()))C$=d.close=`)$))${M$}`;if(d.inner.includes("*")&&(T$=Z$())&&/^\.[^\\/.]+$/.test(T$)){let r$=V7(T$,{...J,fastpaths:!1}).output;C$=d.close=`)${r$})${M$})`}if(d.prev.type==="bos")A.negatedExtglob=!0}a({type:"paren",extglob:!0,value:k,output:C$}),n("parens")};if(Z.fastpaths!==!1&&!/(^[*!]|[/()[\]{}"])/.test($)){let d=!1,Y$=$.replace(fO,(g,t,C$,T$,M$,r$)=>{if(T$==="\\")return d=!0,g;if(T$==="?"){if(t)return t+T$+(M$?D.repeat(M$.length):"");if(r$===0)return v+(M$?D.repeat(M$.length):"");return D.repeat(C$.length)}if(T$===".")return H.repeat(C$.length);if(T$==="*"){if(t)return t+T$+(M$?m:"");return m}return t?g:`\\${g}`});if(d===!0)if(Z.unescape===!0)Y$=Y$.replace(/\\/g,"");else Y$=Y$.replace(/\\+/g,(g)=>{return g.length%2===0?"\\\\":g?"\\":""});if(Y$===$&&Z.contains===!0)return A.output=$,A;return A.output=S0.wrapOutput(Y$,A,J),A}while(!A$()){if(k=J$(),k==="\x00")continue;if(k==="\\"){let g=s();if(g==="/"&&Z.bash!==!0)continue;if(g==="."||g===";")continue;if(!g){k+="\\",a({type:"text",value:k});continue}let t=/^\\+/.exec(Z$()),C$=0;if(t&&t[0].length>2){if(C$=t[0].length,A.index+=C$,C$%2!==0)k+="\\"}if(Z.unescape===!0)k=J$();else k+=J$();if(A.brackets===0){a({type:"text",value:k});continue}}if(A.brackets>0&&(k!=="]"||T.value==="["||T.value==="[^")){if(Z.posix!==!1&&k===":"){let g=T.value.slice(1);if(g.includes("[")){if(T.posix=!0,g.includes(":")){let t=T.value.lastIndexOf("["),C$=T.value.slice(0,t),T$=T.value.slice(t+2),M$=hO[T$];if(M$){if(T.value=C$+M$,A.backtrack=!0,J$(),!Q.output&&V.indexOf(T)===1)Q.output=z;continue}}}}if(k==="["&&s()!==":"||k==="-"&&s()==="]")k=`\\${k}`;if(k==="]"&&(T.value==="["||T.value==="[^"))k=`\\${k}`;if(Z.posix===!0&&k==="!"&&T.value==="[")k="^";T.value+=k,y$({value:k});continue}if(A.quotes===1&&k!=='"'){k=S0.escapeRegex(k),T.value+=k,y$({value:k});continue}if(k==='"'){if(A.quotes=A.quotes===1?0:1,Z.keepQuotes===!0)a({type:"text",value:k});continue}if(k==="("){y("parens"),a({type:"paren",value:k});continue}if(k===")"){if(A.parens===0&&Z.strictBrackets===!0)throw SyntaxError(OJ("opening","("));let g=u[u.length-1];if(g&&A.parens===g.parens+1){l(u.pop());continue}a({type:"paren",value:k,output:A.parens?")":"\\)"}),n("parens");continue}if(k==="["){if(Z.nobracket===!0||!Z$().includes("]")){if(Z.nobracket!==!0&&Z.strictBrackets===!0)throw SyntaxError(OJ("closing","]"));k=`\\${k}`}else y("brackets");a({type:"bracket",value:k});continue}if(k==="]"){if(Z.nobracket===!0||T&&T.type==="bracket"&&T.value.length===1){a({type:"text",value:k,output:`\\${k}`});continue}if(A.brackets===0){if(Z.strictBrackets===!0)throw SyntaxError(OJ("opening","["));a({type:"text",value:k,output:`\\${k}`});continue}n("brackets");let g=T.value.slice(1);if(T.posix!==!0&&g[0]==="^"&&!g.includes("/"))k=`/${k}`;if(T.value+=k,y$({value:k}),Z.literalBrackets===!1||S0.hasRegexChars(g))continue;let t=S0.escapeRegex(T.value);if(A.output=A.output.slice(0,-T.value.length),Z.literalBrackets===!0){A.output+=t,T.value=t;continue}T.value=`(${X}${t}|${T.value})`,A.output+=T.value;continue}if(k==="{"&&Z.nobrace!==!0){y("braces");let g={type:"brace",value:k,output:"(",outputIndex:A.output.length,tokensIndex:A.tokens.length};r.push(g),a(g);continue}if(k==="}"){let g=r[r.length-1];if(Z.nobrace===!0||!g){a({type:"text",value:k,output:k});continue}let t=")";if(g.dots===!0){let C$=V.slice(),T$=[];for(let M$=C$.length-1;M$>=0;M$--){if(V.pop(),C$[M$].type==="brace")break;if(C$[M$].type!=="dots")T$.unshift(C$[M$].value)}t=mO(T$,Z),A.backtrack=!0}if(g.comma!==!0&&g.dots!==!0){let C$=A.output.slice(0,g.outputIndex),T$=A.tokens.slice(g.tokensIndex);g.value=g.output="\\{",k=t="\\}",A.output=C$;for(let M$ of T$)A.output+=M$.output||M$.value}a({type:"brace",value:k,output:t}),n("braces"),r.pop();continue}if(k==="|"){if(u.length>0)u[u.length-1].conditions++;a({type:"text",value:k});continue}if(k===","){let g=k,t=r[r.length-1];if(t&&S[S.length-1]==="braces")t.comma=!0,g="|";a({type:"comma",value:k,output:g});continue}if(k==="/"){if(T.type==="dot"&&A.index===A.start+1){A.start=A.index+1,A.consumed="",A.output="",V.pop(),T=Q;continue}a({type:"slash",value:k,output:U});continue}if(k==="."){if(A.braces>0&&T.type==="dot"){if(T.value===".")T.output=H;let g=r[r.length-1];T.type="dots",T.output+=k,T.value+=k,g.dots=!0;continue}if(A.braces+A.parens===0&&T.type!=="bos"&&T.type!=="slash"){a({type:"text",value:k,output:H});continue}a({type:"dot",value:k,output:H});continue}if(k==="?"){if(!(T&&T.value==="(")&&Z.noextglob!==!0&&s()==="("&&s(2)!=="?"){c$("qmark",k);continue}if(T&&T.type==="paren"){let t=s(),C$=k;if(t==="<"&&!S0.supportsLookbehinds())throw Error("Node.js v10 or higher is required for regex lookbehinds");if(T.value==="("&&!/[!=<:]/.test(t)||t==="<"&&!/<([!=]|\w+>)/.test(Z$()))C$=`\\${k}`;a({type:"text",value:k,output:C$});continue}if(Z.dot!==!0&&(T.type==="slash"||T.type==="bos")){a({type:"qmark",value:k,output:L});continue}a({type:"qmark",value:k,output:D});continue}if(k==="!"){if(Z.noextglob!==!0&&s()==="("){if(s(2)!=="?"||!/[!=<:]/.test(s(3))){c$("negate",k);continue}}if(Z.nonegate!==!0&&A.index===0){Q$();continue}}if(k==="+"){if(Z.noextglob!==!0&&s()==="("&&s(2)!=="?"){c$("plus",k);continue}if(T&&T.value==="("||Z.regex===!1){a({type:"plus",value:k,output:q});continue}if(T&&(T.type==="bracket"||T.type==="paren"||T.type==="brace")||A.parens>0){a({type:"plus",value:k});continue}a({type:"plus",value:q});continue}if(k==="@"){if(Z.noextglob!==!0&&s()==="("&&s(2)!=="?"){a({type:"at",extglob:!0,value:k,output:""});continue}a({type:"text",value:k});continue}if(k!=="*"){if(k==="$"||k==="^")k=`\\${k}`;let g=gO.exec(Z$());if(g)k+=g[0],A.index+=g[0].length;a({type:"text",value:k});continue}if(T&&(T.type==="globstar"||T.star===!0)){T.type="star",T.star=!0,T.value+=k,T.output=m,A.backtrack=!0,A.globstar=!0,W$(k);continue}let d=Z$();if(Z.noextglob!==!0&&/^\([^?]/.test(d)){c$("star",k);continue}if(T.type==="star"){if(Z.noglobstar===!0){W$(k);continue}let g=T.prev,t=g.prev,C$=g.type==="slash"||g.type==="bos",T$=t&&(t.type==="star"||t.type==="globstar");if(Z.bash===!0&&(!C$||d[0]&&d[0]!=="/")){a({type:"star",value:k,output:""});continue}let M$=A.braces>0&&(g.type==="comma"||g.type==="brace"),r$=u.length&&(g.type==="pipe"||g.type==="paren");if(!C$&&g.type!=="paren"&&!M$&&!r$){a({type:"star",value:k,output:""});continue}while(d.slice(0,3)==="/**"){let K0=$[A.index+4];if(K0&&K0!=="/")break;d=d.slice(3),W$("/**",3)}if(g.type==="bos"&&A$()){T.type="globstar",T.value+=k,T.output=x(Z),A.output=T.output,A.globstar=!0,W$(k);continue}if(g.type==="slash"&&g.prev.type!=="bos"&&!T$&&A$()){A.output=A.output.slice(0,-(g.output+T.output).length),g.output=`(?:${g.output}`,T.type="globstar",T.output=x(Z)+(Z.strictSlashes?")":"|$)"),T.value+=k,A.globstar=!0,A.output+=g.output+T.output,W$(k);continue}if(g.type==="slash"&&g.prev.type!=="bos"&&d[0]==="/"){let K0=d[1]!==void 0?"|$":"";A.output=A.output.slice(0,-(g.output+T.output).length),g.output=`(?:${g.output}`,T.type="globstar",T.output=`${x(Z)}${U}|${U}${K0})`,T.value+=k,A.output+=g.output+T.output,A.globstar=!0,W$(k+J$()),a({type:"slash",value:"/",output:""});continue}if(g.type==="bos"&&d[0]==="/"){T.type="globstar",T.value+=k,T.output=`(?:^|${U}|${x(Z)}${U})`,A.output=T.output,A.globstar=!0,W$(k+J$()),a({type:"slash",value:"/",output:""});continue}A.output=A.output.slice(0,-T.output.length),T.type="globstar",T.output=x(Z),T.value+=k,A.output+=T.output,A.globstar=!0,W$(k);continue}let Y$={type:"star",value:k,output:m};if(Z.bash===!0){if(Y$.output=".*?",T.type==="bos"||T.type==="slash")Y$.output=b+Y$.output;a(Y$);continue}if(T&&(T.type==="bracket"||T.type==="paren")&&Z.regex===!0){Y$.output=k,a(Y$);continue}if(A.index===A.start||T.type==="slash"||T.type==="dot"){if(T.type==="dot")A.output+=C,T.output+=C;else if(Z.dot===!0)A.output+=P,T.output+=P;else A.output+=b,T.output+=b;if(s()!=="*")A.output+=z,T.output+=z}a(Y$)}while(A.brackets>0){if(Z.strictBrackets===!0)throw SyntaxError(OJ("closing","]"));A.output=S0.escapeLast(A.output,"["),n("brackets")}while(A.parens>0){if(Z.strictBrackets===!0)throw SyntaxError(OJ("closing",")"));A.output=S0.escapeLast(A.output,"("),n("parens")}while(A.braces>0){if(Z.strictBrackets===!0)throw SyntaxError(OJ("closing","}"));A.output=S0.escapeLast(A.output,"{"),n("braces")}if(Z.strictSlashes!==!0&&(T.type==="star"||T.type==="bracket"))a({type:"maybe_slash",value:"",output:`${U}?`});if(A.backtrack===!0){A.output="";for(let d of A.tokens)if(A.output+=d.output!=null?d.output:d.value,d.suffix)A.output+=d.suffix}return A};V7.fastpaths=($,J)=>{let Z={...J},Y=typeof Z.maxLength==="number"?Math.min(k9,Z.maxLength):k9,K=$.length;if(K>Y)throw SyntaxError(`Input length: ${K}, exceeds maximum allowed length: ${Y}`);$=EQ[$]||$;let Q=S0.isWindows(J),{DOT_LITERAL:V,SLASH_LITERAL:X,ONE_CHAR:W,DOTS_SLASH:_,NO_DOT:j,NO_DOTS:H,NO_DOTS_SLASH:q,STAR:U,START_ANCHOR:z}=j8.globChars(Q),M=Z.dot?H:j,I=Z.dot?q:j,C=Z.capture?"":"?:",P={negated:!1,prefix:""},D=Z.bash===!0?".*?":U;if(Z.capture)D=`(${D})`;let L=(b)=>{if(b.noglobstar===!0)return D;return`(${C}(?:(?!${z}${b.dot?_:V}).)*?)`},R=(b)=>{switch(b){case"*":return`${M}${W}${D}`;case".*":return`${V}${W}${D}`;case"*.*":return`${M}${D}${V}${W}${D}`;case"*/*":return`${M}${D}${X}${W}${I}${D}`;case"**":return M+L(Z);case"**/*":return`(?:${M}${L(Z)}${X})?${I}${W}${D}`;case"**/*.*":return`(?:${M}${L(Z)}${X})?${I}${D}${V}${W}${D}`;case"**/.*":return`(?:${M}${L(Z)}${X})?${V}${W}${D}`;default:{let v=/^(.*?)\.(\w+)$/.exec(b);if(!v)return;let m=R(v[1]);if(!m)return;return m+V+v[2]}}},N=S0.removePrefix($,P),x=R(N);if(x&&Z.strictSlashes!==!0)x+=`${X}?`;return x};vQ.exports=V7});var fQ=p((ww,gQ)=>{var oO=u0("path"),rO=kQ(),G7=hQ(),X7=X8(),iO=G8(),sO=($)=>$&&typeof $==="object"&&!Array.isArray($),U0=($,J,Z=!1)=>{if(Array.isArray($)){let j=$.map((q)=>U0(q,J,Z));return(q)=>{for(let U of j){let z=U(q);if(z)return z}return!1}}let Y=sO($)&&$.tokens&&$.input;if($===""||typeof $!=="string"&&!Y)throw TypeError("Expected pattern to be a non-empty string");let K=J||{},Q=X7.isWindows(J),V=Y?U0.compileRe($,J):U0.makeRe($,J,!1,!0),X=V.state;delete V.state;let W=()=>!1;if(K.ignore){let j={...J,ignore:null,onMatch:null,onResult:null};W=U0(K.ignore,j,Z)}let _=(j,H=!1)=>{let{isMatch:q,match:U,output:z}=U0.test(j,V,J,{glob:$,posix:Q}),M={glob:$,state:X,regex:V,posix:Q,input:j,output:z,match:U,isMatch:q};if(typeof K.onResult==="function")K.onResult(M);if(q===!1)return M.isMatch=!1,H?M:!1;if(W(j)){if(typeof K.onIgnore==="function")K.onIgnore(M);return M.isMatch=!1,H?M:!1}if(typeof K.onMatch==="function")K.onMatch(M);return H?M:!0};if(Z)_.state=X;return _};U0.test=($,J,Z,{glob:Y,posix:K}={})=>{if(typeof $!=="string")throw TypeError("Expected input to be a string");if($==="")return{isMatch:!1,output:""};let Q=Z||{},V=Q.format||(K?X7.toPosixSlashes:null),X=$===Y,W=X&&V?V($):$;if(X===!1)W=V?V($):$,X=W===Y;if(X===!1||Q.capture===!0)if(Q.matchBase===!0||Q.basename===!0)X=U0.matchBase($,J,Z,K);else X=J.exec(W);return{isMatch:Boolean(X),match:X,output:W}};U0.matchBase=($,J,Z,Y=X7.isWindows(Z))=>{return(J instanceof RegExp?J:U0.makeRe(J,Z)).test(oO.basename($))};U0.isMatch=($,J,Z)=>U0(J,Z)($);U0.parse=($,J)=>{if(Array.isArray($))return $.map((Z)=>U0.parse(Z,J));return G7($,{...J,fastpaths:!1})};U0.scan=($,J)=>rO($,J);U0.compileRe=($,J,Z=!1,Y=!1)=>{if(Z===!0)return $.output;let K=J||{},Q=K.contains?"":"^",V=K.contains?"":"$",X=`${Q}(?:${$.output})${V}`;if($&&$.negated===!0)X=`^(?!${X}).*$`;let W=U0.toRegex(X,J);if(Y===!0)W.state=$;return W};U0.makeRe=($,J={},Z=!1,Y=!1)=>{if(!$||typeof $!=="string")throw TypeError("Expected a non-empty string");let K={negated:!1,fastpaths:!0};if(J.fastpaths!==!1&&($[0]==="."||$[0]==="*"))K.output=G7.fastpaths($,J);if(!K.output)K=G7($,J);return U0.compileRe(K,J,Z,Y)};U0.toRegex=($,J)=>{try{let Z=J||{};return new RegExp($,Z.flags||(Z.nocase?"i":""))}catch(Z){if(J&&J.debug===!0)throw Z;return/$^/}};U0.constants=iO;gQ.exports=U0});var lQ=p((Rw,cQ)=>{var uQ=u0("util"),dQ=MQ(),w1=fQ(),W7=X8(),mQ=($)=>$===""||$==="./",pQ=($)=>{let J=$.indexOf("{");return J>-1&&$.indexOf("}",J)>-1},a$=($,J,Z)=>{J=[].concat(J),$=[].concat($);let Y=new Set,K=new Set,Q=new Set,V=0,X=(j)=>{if(Q.add(j.output),Z&&Z.onResult)Z.onResult(j)};for(let j=0;j<J.length;j++){let H=w1(String(J[j]),{...Z,onResult:X},!0),q=H.state.negated||H.state.negatedExtglob;if(q)V++;for(let U of $){let z=H(U,!0);if(!(q?!z.isMatch:z.isMatch))continue;if(q)Y.add(z.output);else Y.delete(z.output),K.add(z.output)}}let _=(V===J.length?[...Q]:[...K]).filter((j)=>!Y.has(j));if(Z&&_.length===0){if(Z.failglob===!0)throw Error(`No matches found for "${J.join(", ")}"`);if(Z.nonull===!0||Z.nullglob===!0)return Z.unescape?J.map((j)=>j.replace(/\\/g,"")):J}return _};a$.match=a$;a$.matcher=($,J)=>w1($,J);a$.isMatch=($,J,Z)=>w1(J,Z)($);a$.any=a$.isMatch;a$.not=($,J,Z={})=>{J=[].concat(J).map(String);let Y=new Set,K=[],V=new Set(a$($,J,{...Z,onResult:(X)=>{if(Z.onResult)Z.onResult(X);K.push(X.output)}}));for(let X of K)if(!V.has(X))Y.add(X);return[...Y]};a$.contains=($,J,Z)=>{if(typeof $!=="string")throw TypeError(`Expected a string: "${uQ.inspect($)}"`);if(Array.isArray(J))return J.some((Y)=>a$.contains($,Y,Z));if(typeof J==="string"){if(mQ($)||mQ(J))return!1;if($.includes(J)||$.startsWith("./")&&$.slice(2).includes(J))return!0}return a$.isMatch($,J,{...Z,contains:!0})};a$.matchKeys=($,J,Z)=>{if(!W7.isObject($))throw TypeError("Expected the first argument to be an object");let Y=a$(Object.keys($),J,Z),K={};for(let Q of Y)K[Q]=$[Q];return K};a$.some=($,J,Z)=>{let Y=[].concat($);for(let K of[].concat(J)){let Q=w1(String(K),Z);if(Y.some((V)=>Q(V)))return!0}return!1};a$.every=($,J,Z)=>{let Y=[].concat($);for(let K of[].concat(J)){let Q=w1(String(K),Z);if(!Y.every((V)=>Q(V)))return!1}return!0};a$.all=($,J,Z)=>{if(typeof $!=="string")throw TypeError(`Expected a string: "${uQ.inspect($)}"`);return[].concat(J).every((Y)=>w1(Y,Z)($))};a$.capture=($,J,Z)=>{let Y=W7.isWindows(Z),Q=w1.makeRe(String($),{...Z,capture:!0}).exec(Y?W7.toPosixSlashes(J):J);if(Q)return Q.slice(1).map((V)=>V===void 0?"":V)};a$.makeRe=(...$)=>w1.makeRe(...$);a$.scan=(...$)=>w1.scan(...$);a$.parse=($,J)=>{let Z=[];for(let Y of[].concat($||[]))for(let K of dQ(String(Y),J))Z.push(w1.parse(K,J));return Z};a$.braces=($,J)=>{if(typeof $!=="string")throw TypeError("Expected a string");if(J&&J.nobrace===!0||!pQ($))return[$];return dQ($,J)};a$.braceExpand=($,J)=>{if(typeof $!=="string")throw TypeError("Expected a string");return a$.braces($,{...J,expand:!0})};a$.hasBraces=pQ;cQ.exports=a$});var rQ=p((Lw,oQ)=>{/*!
|
|
19
19
|
* is-extglob <https://github.com/jonschlinkert/is-extglob>
|
|
20
20
|
*
|
|
21
21
|
* Copyright (c) 2014-2016, Jon Schlinkert.
|
|
22
22
|
* Licensed under the MIT License.
|
|
23
|
-
*/
|
|
23
|
+
*/oQ.exports=function(J){if(typeof J!=="string"||J==="")return!1;var Z;while(Z=/(\\).|([@?!+*]\(.*\))/g.exec(J)){if(Z[2])return!0;J=J.slice(Z.index+Z[0].length)}return!1}});var nQ=p((Nw,sQ)=>{/*!
|
|
24
24
|
* is-glob <https://github.com/jonschlinkert/is-glob>
|
|
25
25
|
*
|
|
26
26
|
* Copyright (c) 2014-2017, Jon Schlinkert.
|
|
27
27
|
* Released under the MIT License.
|
|
28
|
-
*/var lO=lQ(),oQ={"{":"}","(":")","[":"]"},oO=function($){if($[0]==="!")return!0;var J=0,Z=-2,Y=-2,K=-2,Q=-2,V=-2;while(J<$.length){if($[J]==="*")return!0;if($[J+1]==="?"&&/[\].+)]/.test($[J]))return!0;if(Y!==-1&&$[J]==="["&&$[J+1]!=="]"){if(Y<J)Y=$.indexOf("]",J);if(Y>J){if(V===-1||V>Y)return!0;if(V=$.indexOf("\\",J),V===-1||V>Y)return!0}}if(K!==-1&&$[J]==="{"&&$[J+1]!=="}"){if(K=$.indexOf("}",J),K>J){if(V=$.indexOf("\\",J),V===-1||V>K)return!0}}if(Q!==-1&&$[J]==="("&&$[J+1]==="?"&&/[:!=]/.test($[J+2])&&$[J+3]!==")"){if(Q=$.indexOf(")",J),Q>J){if(V=$.indexOf("\\",J),V===-1||V>Q)return!0}}if(Z!==-1&&$[J]==="("&&$[J+1]!=="|"){if(Z<J)Z=$.indexOf("|",J);if(Z!==-1&&$[Z+1]!==")"){if(Q=$.indexOf(")",Z),Q>Z){if(V=$.indexOf("\\",Z),V===-1||V>Q)return!0}}}if($[J]==="\\"){var X=$[J+1];J+=2;var W=oQ[X];if(W){var B=$.indexOf(W,J);if(B!==-1)J=B+1}if($[J]==="!")return!0}else J++}return!1},rO=function($){if($[0]==="!")return!0;var J=0;while(J<$.length){if(/[*?{}()[\]]/.test($[J]))return!0;if($[J]==="\\"){var Z=$[J+1];J+=2;var Y=oQ[Z];if(Y){var K=$.indexOf(Y,J);if(K!==-1)J=K+1}if($[J]==="!")return!0}else J++}return!1};rQ.exports=function(J,Z){if(typeof J!=="string"||J==="")return!1;if(lO(J))return!0;var Y=oO;if(Z&&Z.strict===!1)Y=rO;return Y(J)}});var iG=p((Qk,rG)=>{var _z=["||","&&",";;","|&","<(","<<<",">>",">&","<&","&",";","(",")","|","<",">"],oG=/[\n\r\u2028\u2029]/,Oz=/[\s#!"$&'():;<=>@\\^`|]/g;rG.exports=function(J){return J.map(function(Z){if(Z==="")return"''";if(Z&&typeof Z==="object"){if(Z.op==="glob"){if(typeof Z.pattern!=="string")throw TypeError("glob token requires a string `pattern`");if(oG.test(Z.pattern))throw TypeError("glob `pattern` must not contain line terminators");return Z.pattern.replace(Oz,"\\$&")}if(typeof Z.op==="string"){if(_z.indexOf(Z.op)<0)throw TypeError("invalid `op` value: "+JSON.stringify(Z.op));return Z.op.replace(/[\s\S]/g,"\\$&")}if(typeof Z.comment==="string"){if(oG.test(Z.comment))throw TypeError("`comment` must not contain line terminators");return"#"+Z.comment}throw TypeError("unrecognized object token shape")}if(/["\s\\]/.test(Z)&&!/'/.test(Z))return"'"+Z.replace(/(['])/g,"\\$1")+"'";if(/["'\s]/.test(Z))return'"'+Z.replace(/(["\\$`!])/g,"\\$1")+'"';return String(Z).replace(/([A-Za-z]:)?([#!"$&'()*,:;<=>?@[\\\]^`{|}])/g,"$1\\$2")}).join(" ")}});var JX=p((Vk,$X)=>{var eG="(?:"+["\\|\\|","\\&\\&",";;","\\|\\&","\\<\\(","\\<\\<\\<",">>",">\\&","<\\&","[&;()|<>]"].join("|")+")",sG=new RegExp("^"+eG+"$"),nG="|&;()<> \\t",qz='"((\\\\"|[^"])*?)"',Fz="'((\\\\'|[^'])*?)'",zz=/^#$/,aG="'",tG='"',k7="$",p2="",Cz=4294967296;for(zZ=0;zZ<4;zZ++)p2+=(Cz*Math.random()).toString(16);var zZ,Mz=new RegExp("^"+p2);function Dz($,J){var Z=J.lastIndex,Y=[],K;while(K=J.exec($))if(Y.push(K),J.lastIndex===K.index)J.lastIndex+=1;return J.lastIndex=Z,Y}function Pz($,J,Z){var Y=typeof $==="function"?$(Z):$[Z];if(typeof Y>"u"&&Z!="")Y="";else if(typeof Y>"u")Y="$";if(typeof Y==="object")return J+p2+JSON.stringify(Y)+p2;return J+Y}function Iz($,J,Z){if(!Z)Z={};var Y=Z.escape||"\\",K="(\\"+Y+`['"`+nG+`]|[^\\s'"`+nG+"])+",Q=new RegExp(["("+eG+")","("+K+"|"+qz+"|"+Fz+")+"].join("|"),"g"),V=Dz($,Q);if(V.length===0)return[];if(!J)J={};var X=!1;return V.map(function(W){var B=W[0];if(!B||X)return;if(sG.test(B))return{op:B};var j=!1,_=!1,q="",H=!1,C;function M(){C+=1;var P,D,L=B.charAt(C);if(L==="{"){if(C+=1,B.charAt(C)==="}")throw Error("Bad substitution: "+B.slice(C-2,C+1));if(P=B.indexOf("}",C),P<0)throw Error("Bad substitution: "+B.slice(C));D=B.slice(C,P),C=P}else if(/[*@#?$!_-]/.test(L))D=L,C+=1;else{var R=B.slice(C);if(P=R.match(/[^\w\d_]/),!P)D=R,C=B.length;else D=R.slice(0,P.index),C+=P.index-1}return Pz(J,"",D)}for(C=0;C<B.length;C++){var I=B.charAt(C);if(H=H||!j&&(I==="*"||I==="?"),_)q+=I,_=!1;else if(j)if(I===j)j=!1;else if(j==aG)q+=I;else if(I===Y)if(C+=1,I=B.charAt(C),I===tG||I===Y||I===k7)q+=I;else q+=Y+I;else if(I===k7)q+=M();else q+=I;else if(I===tG||I===aG)j=I;else if(sG.test(I))return{op:B};else if(zz.test(I)){X=!0;var z={comment:$.slice(W.index+C+1)};if(q.length)return[q,z];return[z]}else if(I===Y)_=!0;else if(I===k7)q+=M();else q+=I}if(H)return{op:"glob",pattern:q};return q}).reduce(function(W,B){return typeof B>"u"?W:W.concat(B)},[])}$X.exports=function(J,Z,Y){var K=Iz(J,Z,Y);if(typeof Z!=="function")return K;return K.reduce(function(Q,V){if(typeof V==="object")return Q.concat(V);var X=V.split(RegExp("("+p2+".*?"+p2+")","g"));if(X.length===1)return Q.concat(X[0]);return Q.concat(X.filter(Boolean).map(function(W){if(Mz.test(W))return JSON.parse(W.split(p2)[1]);return W}))},[])}});var ZX=p((Az)=>{Az.quote=iG();Az.parse=JX()});var TJ=p((Vb,nX)=>{nX.exports=r2;r2.CAPTURING_PHASE=1;r2.AT_TARGET=2;r2.BUBBLING_PHASE=3;function r2($,J){if(this.type="",this.target=null,this.currentTarget=null,this.eventPhase=r2.AT_TARGET,this.bubbles=!1,this.cancelable=!1,this.isTrusted=!1,this.defaultPrevented=!1,this.timeStamp=Date.now(),this._propagationStopped=!1,this._immediatePropagationStopped=!1,this._initialized=!0,this._dispatching=!1,$)this.type=$;if(J)for(var Z in J)this[Z]=J[Z]}r2.prototype=Object.create(Object.prototype,{constructor:{value:r2},stopPropagation:{value:function(){this._propagationStopped=!0}},stopImmediatePropagation:{value:function(){this._propagationStopped=!0,this._immediatePropagationStopped=!0}},preventDefault:{value:function(){if(this.cancelable)this.defaultPrevented=!0}},initEvent:{value:function(J,Z,Y){if(this._initialized=!0,this._dispatching)return;this._propagationStopped=!1,this._immediatePropagationStopped=!1,this.defaultPrevented=!1,this.isTrusted=!1,this.target=null,this.type=J,this.bubbles=Z,this.cancelable=Y}}})});var s7=p((Gb,tX)=>{var aX=TJ();tX.exports=i7;function i7(){aX.call(this),this.view=null,this.detail=0}i7.prototype=Object.create(aX.prototype,{constructor:{value:i7},initUIEvent:{value:function($,J,Z,Y,K){this.initEvent($,J,Z),this.view=Y,this.detail=K}}})});var a7=p((Xb,$W)=>{var eX=s7();$W.exports=n7;function n7(){eX.call(this),this.screenX=this.screenY=this.clientX=this.clientY=0,this.ctrlKey=this.altKey=this.shiftKey=this.metaKey=!1,this.button=0,this.buttons=1,this.relatedTarget=null}n7.prototype=Object.create(eX.prototype,{constructor:{value:n7},initMouseEvent:{value:function($,J,Z,Y,K,Q,V,X,W,B,j,_,q,H,C){switch(this.initEvent($,J,Z,Y,K),this.screenX=Q,this.screenY=V,this.clientX=X,this.clientY=W,this.ctrlKey=B,this.altKey=j,this.shiftKey=_,this.metaKey=q,this.button=H,H){case 0:this.buttons=1;break;case 1:this.buttons=4;break;case 2:this.buttons=2;break;default:this.buttons=0;break}this.relatedTarget=C}},getModifierState:{value:function($){switch($){case"Alt":return this.altKey;case"Control":return this.ctrlKey;case"Shift":return this.shiftKey;case"Meta":return this.metaKey;default:return!1}}}})});var xZ=p((Wb,ZW)=>{ZW.exports=EZ;var kC=1,EC=3,xC=4,bC=5,vC=7,hC=8,gC=9,fC=11,mC=12,uC=13,dC=14,pC=15,cC=17,lC=18,oC=19,rC=20,iC=21,sC=22,nC=23,aC=24,tC=25,eC=[null,"INDEX_SIZE_ERR",null,"HIERARCHY_REQUEST_ERR","WRONG_DOCUMENT_ERR","INVALID_CHARACTER_ERR",null,"NO_MODIFICATION_ALLOWED_ERR","NOT_FOUND_ERR","NOT_SUPPORTED_ERR","INUSE_ATTRIBUTE_ERR","INVALID_STATE_ERR","SYNTAX_ERR","INVALID_MODIFICATION_ERR","NAMESPACE_ERR","INVALID_ACCESS_ERR",null,"TYPE_MISMATCH_ERR","SECURITY_ERR","NETWORK_ERR","ABORT_ERR","URL_MISMATCH_ERR","QUOTA_EXCEEDED_ERR","TIMEOUT_ERR","INVALID_NODE_TYPE_ERR","DATA_CLONE_ERR"],$M=[null,"INDEX_SIZE_ERR (1): the index is not in the allowed range",null,"HIERARCHY_REQUEST_ERR (3): the operation would yield an incorrect nodes model","WRONG_DOCUMENT_ERR (4): the object is in the wrong Document, a call to importNode is required","INVALID_CHARACTER_ERR (5): the string contains invalid characters",null,"NO_MODIFICATION_ALLOWED_ERR (7): the object can not be modified","NOT_FOUND_ERR (8): the object can not be found here","NOT_SUPPORTED_ERR (9): this operation is not supported","INUSE_ATTRIBUTE_ERR (10): setAttributeNode called on owned Attribute","INVALID_STATE_ERR (11): the object is in an invalid state","SYNTAX_ERR (12): the string did not match the expected pattern","INVALID_MODIFICATION_ERR (13): the object can not be modified in this way","NAMESPACE_ERR (14): the operation is not allowed by Namespaces in XML","INVALID_ACCESS_ERR (15): the object does not support the operation or argument",null,"TYPE_MISMATCH_ERR (17): the type of the object does not match the expected type","SECURITY_ERR (18): the operation is insecure","NETWORK_ERR (19): a network error occurred","ABORT_ERR (20): the user aborted an operation","URL_MISMATCH_ERR (21): the given URL does not match another URL","QUOTA_EXCEEDED_ERR (22): the quota has been exceeded","TIMEOUT_ERR (23): a timeout occurred","INVALID_NODE_TYPE_ERR (24): the supplied node is invalid or has an invalid ancestor for this operation","DATA_CLONE_ERR (25): the object can not be cloned."],JW={INDEX_SIZE_ERR:kC,DOMSTRING_SIZE_ERR:2,HIERARCHY_REQUEST_ERR:EC,WRONG_DOCUMENT_ERR:xC,INVALID_CHARACTER_ERR:bC,NO_DATA_ALLOWED_ERR:6,NO_MODIFICATION_ALLOWED_ERR:vC,NOT_FOUND_ERR:hC,NOT_SUPPORTED_ERR:gC,INUSE_ATTRIBUTE_ERR:10,INVALID_STATE_ERR:fC,SYNTAX_ERR:mC,INVALID_MODIFICATION_ERR:uC,NAMESPACE_ERR:dC,INVALID_ACCESS_ERR:pC,VALIDATION_ERR:16,TYPE_MISMATCH_ERR:cC,SECURITY_ERR:lC,NETWORK_ERR:oC,ABORT_ERR:rC,URL_MISMATCH_ERR:iC,QUOTA_EXCEEDED_ERR:sC,TIMEOUT_ERR:nC,INVALID_NODE_TYPE_ERR:aC,DATA_CLONE_ERR:tC};function EZ($){Error.call(this),Error.captureStackTrace(this,this.constructor),this.code=$,this.message=$M[$],this.name=eC[$]}EZ.prototype.__proto__=Error.prototype;for(I8 in JW)kZ={value:JW[I8]},Object.defineProperty(EZ,I8,kZ),Object.defineProperty(EZ.prototype,I8,kZ);var kZ,I8});var bZ=p((JM)=>{JM.isApiWritable=!globalThis.__domino_frozen__});var X0=p((KM)=>{var G0=xZ(),B0=G0,YM=bZ().isApiWritable;KM.NAMESPACE={HTML:"http://www.w3.org/1999/xhtml",XML:"http://www.w3.org/XML/1998/namespace",XMLNS:"http://www.w3.org/2000/xmlns/",MATHML:"http://www.w3.org/1998/Math/MathML",SVG:"http://www.w3.org/2000/svg",XLINK:"http://www.w3.org/1999/xlink"};KM.IndexSizeError=function(){throw new G0(B0.INDEX_SIZE_ERR)};KM.HierarchyRequestError=function(){throw new G0(B0.HIERARCHY_REQUEST_ERR)};KM.WrongDocumentError=function(){throw new G0(B0.WRONG_DOCUMENT_ERR)};KM.InvalidCharacterError=function(){throw new G0(B0.INVALID_CHARACTER_ERR)};KM.NoModificationAllowedError=function(){throw new G0(B0.NO_MODIFICATION_ALLOWED_ERR)};KM.NotFoundError=function(){throw new G0(B0.NOT_FOUND_ERR)};KM.NotSupportedError=function(){throw new G0(B0.NOT_SUPPORTED_ERR)};KM.InvalidStateError=function(){throw new G0(B0.INVALID_STATE_ERR)};KM.SyntaxError=function(){throw new G0(B0.SYNTAX_ERR)};KM.InvalidModificationError=function(){throw new G0(B0.INVALID_MODIFICATION_ERR)};KM.NamespaceError=function(){throw new G0(B0.NAMESPACE_ERR)};KM.InvalidAccessError=function(){throw new G0(B0.INVALID_ACCESS_ERR)};KM.TypeMismatchError=function(){throw new G0(B0.TYPE_MISMATCH_ERR)};KM.SecurityError=function(){throw new G0(B0.SECURITY_ERR)};KM.NetworkError=function(){throw new G0(B0.NETWORK_ERR)};KM.AbortError=function(){throw new G0(B0.ABORT_ERR)};KM.UrlMismatchError=function(){throw new G0(B0.URL_MISMATCH_ERR)};KM.QuotaExceededError=function(){throw new G0(B0.QUOTA_EXCEEDED_ERR)};KM.TimeoutError=function(){throw new G0(B0.TIMEOUT_ERR)};KM.InvalidNodeTypeError=function(){throw new G0(B0.INVALID_NODE_TYPE_ERR)};KM.DataCloneError=function(){throw new G0(B0.DATA_CLONE_ERR)};KM.nyi=function(){throw Error("NotYetImplemented")};KM.shouldOverride=function(){throw Error("Abstract function; should be overriding in subclass.")};KM.assert=function($,J){if(!$)throw Error("Assertion failed: "+(J||"")+`
|
|
29
|
-
`+Error().stack)};
|
|
28
|
+
*/var nO=rQ(),iQ={"{":"}","(":")","[":"]"},aO=function($){if($[0]==="!")return!0;var J=0,Z=-2,Y=-2,K=-2,Q=-2,V=-2;while(J<$.length){if($[J]==="*")return!0;if($[J+1]==="?"&&/[\].+)]/.test($[J]))return!0;if(Y!==-1&&$[J]==="["&&$[J+1]!=="]"){if(Y<J)Y=$.indexOf("]",J);if(Y>J){if(V===-1||V>Y)return!0;if(V=$.indexOf("\\",J),V===-1||V>Y)return!0}}if(K!==-1&&$[J]==="{"&&$[J+1]!=="}"){if(K=$.indexOf("}",J),K>J){if(V=$.indexOf("\\",J),V===-1||V>K)return!0}}if(Q!==-1&&$[J]==="("&&$[J+1]==="?"&&/[:!=]/.test($[J+2])&&$[J+3]!==")"){if(Q=$.indexOf(")",J),Q>J){if(V=$.indexOf("\\",J),V===-1||V>Q)return!0}}if(Z!==-1&&$[J]==="("&&$[J+1]!=="|"){if(Z<J)Z=$.indexOf("|",J);if(Z!==-1&&$[Z+1]!==")"){if(Q=$.indexOf(")",Z),Q>Z){if(V=$.indexOf("\\",Z),V===-1||V>Q)return!0}}}if($[J]==="\\"){var X=$[J+1];J+=2;var W=iQ[X];if(W){var _=$.indexOf(W,J);if(_!==-1)J=_+1}if($[J]==="!")return!0}else J++}return!1},tO=function($){if($[0]==="!")return!0;var J=0;while(J<$.length){if(/[*?{}()[\]]/.test($[J]))return!0;if($[J]==="\\"){var Z=$[J+1];J+=2;var Y=iQ[Z];if(Y){var K=$.indexOf(Y,J);if(K!==-1)J=K+1}if($[J]==="!")return!0}else J++}return!1};sQ.exports=function(J,Z){if(typeof J!=="string"||J==="")return!1;if(nO(J))return!0;var Y=aO;if(Z&&Z.strict===!1)Y=tO;return Y(J)}});var aG=p((Bk,nG)=>{var Cz=["||","&&",";;","|&","<(","<<<",">>",">&","<&","&",";","(",")","|","<",">"],sG=/[\n\r\u2028\u2029]/,Mz=/[\s#!"$&'():;<=>@\\^`|]/g;nG.exports=function(J){return J.map(function(Z){if(Z==="")return"''";if(Z&&typeof Z==="object"){if(Z.op==="glob"){if(typeof Z.pattern!=="string")throw TypeError("glob token requires a string `pattern`");if(sG.test(Z.pattern))throw TypeError("glob `pattern` must not contain line terminators");return Z.pattern.replace(Mz,"\\$&")}if(typeof Z.op==="string"){if(Cz.indexOf(Z.op)<0)throw TypeError("invalid `op` value: "+JSON.stringify(Z.op));return Z.op.replace(/[\s\S]/g,"\\$&")}if(typeof Z.comment==="string"){if(sG.test(Z.comment))throw TypeError("`comment` must not contain line terminators");return"#"+Z.comment}throw TypeError("unrecognized object token shape")}if(/["\s\\]/.test(Z)&&!/'/.test(Z))return"'"+Z.replace(/(['])/g,"\\$1")+"'";if(/["'\s]/.test(Z))return'"'+Z.replace(/(["\\$`!])/g,"\\$1")+'"';return String(Z).replace(/([A-Za-z]:)?([#!"$&'()*,:;<=>?@[\\\]^`{|}])/g,"$1\\$2")}).join(" ")}});var KX=p((Hk,YX)=>{var ZX="(?:"+["\\|\\|","\\&\\&",";;","\\|\\&","\\<\\(","\\<\\<\\<",">>",">\\&","<\\&","[&;()|<>]"].join("|")+")",tG=new RegExp("^"+ZX+"$"),eG="|&;()<> \\t",Dz='"((\\\\"|[^"])*?)"',Pz="'((\\\\'|[^'])*?)'",Iz=/^#$/,$X="'",JX='"',x7="$",p2="",Az=4294967296;for(MZ=0;MZ<4;MZ++)p2+=(Az*Math.random()).toString(16);var MZ,Sz=new RegExp("^"+p2);function wz($,J){var Z=J.lastIndex,Y=[],K;while(K=J.exec($))if(Y.push(K),J.lastIndex===K.index)J.lastIndex+=1;return J.lastIndex=Z,Y}function Rz($,J,Z){var Y=typeof $==="function"?$(Z):$[Z];if(typeof Y>"u"&&Z!="")Y="";else if(typeof Y>"u")Y="$";if(typeof Y==="object")return J+p2+JSON.stringify(Y)+p2;return J+Y}function Lz($,J,Z){if(!Z)Z={};var Y=Z.escape||"\\",K="(\\"+Y+`['"`+eG+`]|[^\\s'"`+eG+"])+",Q=new RegExp(["("+ZX+")","("+K+"|"+Dz+"|"+Pz+")+"].join("|"),"g"),V=wz($,Q);if(V.length===0)return[];if(!J)J={};var X=!1;return V.map(function(W){var _=W[0];if(!_||X)return;if(tG.test(_))return{op:_};var j=!1,H=!1,q="",U=!1,z;function M(){z+=1;var P,D,L=_.charAt(z);if(L==="{"){if(z+=1,_.charAt(z)==="}")throw Error("Bad substitution: "+_.slice(z-2,z+1));if(P=_.indexOf("}",z),P<0)throw Error("Bad substitution: "+_.slice(z));D=_.slice(z,P),z=P}else if(/[*@#?$!_-]/.test(L))D=L,z+=1;else{var R=_.slice(z);if(P=R.match(/[^\w\d_]/),!P)D=R,z=_.length;else D=R.slice(0,P.index),z+=P.index-1}return Rz(J,"",D)}for(z=0;z<_.length;z++){var I=_.charAt(z);if(U=U||!j&&(I==="*"||I==="?"),H)q+=I,H=!1;else if(j)if(I===j)j=!1;else if(j==$X)q+=I;else if(I===Y)if(z+=1,I=_.charAt(z),I===JX||I===Y||I===x7)q+=I;else q+=Y+I;else if(I===x7)q+=M();else q+=I;else if(I===JX||I===$X)j=I;else if(tG.test(I))return{op:_};else if(Iz.test(I)){X=!0;var C={comment:$.slice(W.index+z+1)};if(q.length)return[q,C];return[C]}else if(I===Y)H=!0;else if(I===x7)q+=M();else q+=I}if(U)return{op:"glob",pattern:q};return q}).reduce(function(W,_){return typeof _>"u"?W:W.concat(_)},[])}YX.exports=function(J,Z,Y){var K=Lz(J,Z,Y);if(typeof Z!=="function")return K;return K.reduce(function(Q,V){if(typeof V==="object")return Q.concat(V);var X=V.split(RegExp("("+p2+".*?"+p2+")","g"));if(X.length===1)return Q.concat(X[0]);return Q.concat(X.filter(Boolean).map(function(W){if(Sz.test(W))return JSON.parse(W.split(p2)[1]);return W}))},[])}});var QX=p((Nz)=>{Nz.quote=aG();Nz.parse=KX()});var TJ=p((Hb,eX)=>{eX.exports=r2;r2.CAPTURING_PHASE=1;r2.AT_TARGET=2;r2.BUBBLING_PHASE=3;function r2($,J){if(this.type="",this.target=null,this.currentTarget=null,this.eventPhase=r2.AT_TARGET,this.bubbles=!1,this.cancelable=!1,this.isTrusted=!1,this.defaultPrevented=!1,this.timeStamp=Date.now(),this._propagationStopped=!1,this._immediatePropagationStopped=!1,this._initialized=!0,this._dispatching=!1,$)this.type=$;if(J)for(var Z in J)this[Z]=J[Z]}r2.prototype=Object.create(Object.prototype,{constructor:{value:r2},stopPropagation:{value:function(){this._propagationStopped=!0}},stopImmediatePropagation:{value:function(){this._propagationStopped=!0,this._immediatePropagationStopped=!0}},preventDefault:{value:function(){if(this.cancelable)this.defaultPrevented=!0}},initEvent:{value:function(J,Z,Y){if(this._initialized=!0,this._dispatching)return;this._propagationStopped=!1,this._immediatePropagationStopped=!1,this.defaultPrevented=!1,this.isTrusted=!1,this.target=null,this.type=J,this.bubbles=Z,this.cancelable=Y}}})});var a7=p((_b,JW)=>{var $W=TJ();JW.exports=n7;function n7(){$W.call(this),this.view=null,this.detail=0}n7.prototype=Object.create($W.prototype,{constructor:{value:n7},initUIEvent:{value:function($,J,Z,Y,K){this.initEvent($,J,Z),this.view=Y,this.detail=K}}})});var e7=p((Ob,YW)=>{var ZW=a7();YW.exports=t7;function t7(){ZW.call(this),this.screenX=this.screenY=this.clientX=this.clientY=0,this.ctrlKey=this.altKey=this.shiftKey=this.metaKey=!1,this.button=0,this.buttons=1,this.relatedTarget=null}t7.prototype=Object.create(ZW.prototype,{constructor:{value:t7},initMouseEvent:{value:function($,J,Z,Y,K,Q,V,X,W,_,j,H,q,U,z){switch(this.initEvent($,J,Z,Y,K),this.screenX=Q,this.screenY=V,this.clientX=X,this.clientY=W,this.ctrlKey=_,this.altKey=j,this.shiftKey=H,this.metaKey=q,this.button=U,U){case 0:this.buttons=1;break;case 1:this.buttons=4;break;case 2:this.buttons=2;break;default:this.buttons=0;break}this.relatedTarget=z}},getModifierState:{value:function($){switch($){case"Alt":return this.altKey;case"Control":return this.ctrlKey;case"Shift":return this.shiftKey;case"Meta":return this.metaKey;default:return!1}}}})});var vZ=p((qb,QW)=>{QW.exports=bZ;var hC=1,gC=3,fC=4,mC=5,uC=7,dC=8,pC=9,cC=11,lC=12,oC=13,rC=14,iC=15,sC=17,nC=18,aC=19,tC=20,eC=21,$M=22,JM=23,ZM=24,YM=25,KM=[null,"INDEX_SIZE_ERR",null,"HIERARCHY_REQUEST_ERR","WRONG_DOCUMENT_ERR","INVALID_CHARACTER_ERR",null,"NO_MODIFICATION_ALLOWED_ERR","NOT_FOUND_ERR","NOT_SUPPORTED_ERR","INUSE_ATTRIBUTE_ERR","INVALID_STATE_ERR","SYNTAX_ERR","INVALID_MODIFICATION_ERR","NAMESPACE_ERR","INVALID_ACCESS_ERR",null,"TYPE_MISMATCH_ERR","SECURITY_ERR","NETWORK_ERR","ABORT_ERR","URL_MISMATCH_ERR","QUOTA_EXCEEDED_ERR","TIMEOUT_ERR","INVALID_NODE_TYPE_ERR","DATA_CLONE_ERR"],QM=[null,"INDEX_SIZE_ERR (1): the index is not in the allowed range",null,"HIERARCHY_REQUEST_ERR (3): the operation would yield an incorrect nodes model","WRONG_DOCUMENT_ERR (4): the object is in the wrong Document, a call to importNode is required","INVALID_CHARACTER_ERR (5): the string contains invalid characters",null,"NO_MODIFICATION_ALLOWED_ERR (7): the object can not be modified","NOT_FOUND_ERR (8): the object can not be found here","NOT_SUPPORTED_ERR (9): this operation is not supported","INUSE_ATTRIBUTE_ERR (10): setAttributeNode called on owned Attribute","INVALID_STATE_ERR (11): the object is in an invalid state","SYNTAX_ERR (12): the string did not match the expected pattern","INVALID_MODIFICATION_ERR (13): the object can not be modified in this way","NAMESPACE_ERR (14): the operation is not allowed by Namespaces in XML","INVALID_ACCESS_ERR (15): the object does not support the operation or argument",null,"TYPE_MISMATCH_ERR (17): the type of the object does not match the expected type","SECURITY_ERR (18): the operation is insecure","NETWORK_ERR (19): a network error occurred","ABORT_ERR (20): the user aborted an operation","URL_MISMATCH_ERR (21): the given URL does not match another URL","QUOTA_EXCEEDED_ERR (22): the quota has been exceeded","TIMEOUT_ERR (23): a timeout occurred","INVALID_NODE_TYPE_ERR (24): the supplied node is invalid or has an invalid ancestor for this operation","DATA_CLONE_ERR (25): the object can not be cloned."],KW={INDEX_SIZE_ERR:hC,DOMSTRING_SIZE_ERR:2,HIERARCHY_REQUEST_ERR:gC,WRONG_DOCUMENT_ERR:fC,INVALID_CHARACTER_ERR:mC,NO_DATA_ALLOWED_ERR:6,NO_MODIFICATION_ALLOWED_ERR:uC,NOT_FOUND_ERR:dC,NOT_SUPPORTED_ERR:pC,INUSE_ATTRIBUTE_ERR:10,INVALID_STATE_ERR:cC,SYNTAX_ERR:lC,INVALID_MODIFICATION_ERR:oC,NAMESPACE_ERR:rC,INVALID_ACCESS_ERR:iC,VALIDATION_ERR:16,TYPE_MISMATCH_ERR:sC,SECURITY_ERR:nC,NETWORK_ERR:aC,ABORT_ERR:tC,URL_MISMATCH_ERR:eC,QUOTA_EXCEEDED_ERR:$M,TIMEOUT_ERR:JM,INVALID_NODE_TYPE_ERR:ZM,DATA_CLONE_ERR:YM};function bZ($){Error.call(this),Error.captureStackTrace(this,this.constructor),this.code=$,this.message=QM[$],this.name=KM[$]}bZ.prototype.__proto__=Error.prototype;for(I8 in KW)xZ={value:KW[I8]},Object.defineProperty(bZ,I8,xZ),Object.defineProperty(bZ.prototype,I8,xZ);var xZ,I8});var hZ=p((VM)=>{VM.isApiWritable=!globalThis.__domino_frozen__});var X0=p((WM)=>{var G0=vZ(),H0=G0,XM=hZ().isApiWritable;WM.NAMESPACE={HTML:"http://www.w3.org/1999/xhtml",XML:"http://www.w3.org/XML/1998/namespace",XMLNS:"http://www.w3.org/2000/xmlns/",MATHML:"http://www.w3.org/1998/Math/MathML",SVG:"http://www.w3.org/2000/svg",XLINK:"http://www.w3.org/1999/xlink"};WM.IndexSizeError=function(){throw new G0(H0.INDEX_SIZE_ERR)};WM.HierarchyRequestError=function(){throw new G0(H0.HIERARCHY_REQUEST_ERR)};WM.WrongDocumentError=function(){throw new G0(H0.WRONG_DOCUMENT_ERR)};WM.InvalidCharacterError=function(){throw new G0(H0.INVALID_CHARACTER_ERR)};WM.NoModificationAllowedError=function(){throw new G0(H0.NO_MODIFICATION_ALLOWED_ERR)};WM.NotFoundError=function(){throw new G0(H0.NOT_FOUND_ERR)};WM.NotSupportedError=function(){throw new G0(H0.NOT_SUPPORTED_ERR)};WM.InvalidStateError=function(){throw new G0(H0.INVALID_STATE_ERR)};WM.SyntaxError=function(){throw new G0(H0.SYNTAX_ERR)};WM.InvalidModificationError=function(){throw new G0(H0.INVALID_MODIFICATION_ERR)};WM.NamespaceError=function(){throw new G0(H0.NAMESPACE_ERR)};WM.InvalidAccessError=function(){throw new G0(H0.INVALID_ACCESS_ERR)};WM.TypeMismatchError=function(){throw new G0(H0.TYPE_MISMATCH_ERR)};WM.SecurityError=function(){throw new G0(H0.SECURITY_ERR)};WM.NetworkError=function(){throw new G0(H0.NETWORK_ERR)};WM.AbortError=function(){throw new G0(H0.ABORT_ERR)};WM.UrlMismatchError=function(){throw new G0(H0.URL_MISMATCH_ERR)};WM.QuotaExceededError=function(){throw new G0(H0.QUOTA_EXCEEDED_ERR)};WM.TimeoutError=function(){throw new G0(H0.TIMEOUT_ERR)};WM.InvalidNodeTypeError=function(){throw new G0(H0.INVALID_NODE_TYPE_ERR)};WM.DataCloneError=function(){throw new G0(H0.DATA_CLONE_ERR)};WM.nyi=function(){throw Error("NotYetImplemented")};WM.shouldOverride=function(){throw Error("Abstract function; should be overriding in subclass.")};WM.assert=function($,J){if(!$)throw Error("Assertion failed: "+(J||"")+`
|
|
29
|
+
`+Error().stack)};WM.expose=function($,J){for(var Z in $)Object.defineProperty(J.prototype,Z,{value:$[Z],writable:XM})};WM.merge=function($,J){for(var Z in J)$[Z]=J[Z]};WM.documentOrder=function($,J){return 3-($.compareDocumentPosition(J)&6)};WM.toASCIILowerCase=function($){return $.replace(/[A-Z]+/g,function(J){return J.toLowerCase()})};WM.toASCIIUpperCase=function($){return $.replace(/[a-z]+/g,function(J){return J.toUpperCase()})}});var $Y=p((Cb,GW)=>{var i2=TJ(),mM=e7(),uM=X0();GW.exports=VW;function VW(){}VW.prototype={addEventListener:function(J,Z,Y){if(!Z)return;if(Y===void 0)Y=!1;if(!this._listeners)this._listeners=Object.create(null);if(!this._listeners[J])this._listeners[J]=[];var K=this._listeners[J];for(var Q=0,V=K.length;Q<V;Q++){var X=K[Q];if(X.listener===Z&&X.capture===Y)return}var W={listener:Z,capture:Y};if(typeof Z==="function")W.f=Z;K.push(W)},removeEventListener:function(J,Z,Y){if(Y===void 0)Y=!1;if(this._listeners){var K=this._listeners[J];if(K)for(var Q=0,V=K.length;Q<V;Q++){var X=K[Q];if(X.listener===Z&&X.capture===Y){if(K.length===1)this._listeners[J]=void 0;else K.splice(Q,1);return}}}},dispatchEvent:function(J){return this._dispatchEvent(J,!1)},_dispatchEvent:function(J,Z){if(typeof Z!=="boolean")Z=!1;function Y(_,j){var{type:H,eventPhase:q}=j;if(j.currentTarget=_,q!==i2.CAPTURING_PHASE&&_._handlers&&_._handlers[H]){var U=_._handlers[H],z;if(typeof U==="function")z=U.call(j.currentTarget,j);else{var M=U.handleEvent;if(typeof M!=="function")throw TypeError("handleEvent property of event handler object isnot a function.");z=M.call(U,j)}switch(j.type){case"mouseover":if(z===!0)j.preventDefault();break;case"beforeunload":default:if(z===!1)j.preventDefault();break}}var I=_._listeners&&_._listeners[H];if(!I)return;I=I.slice();for(var C=0,P=I.length;C<P;C++){if(j._immediatePropagationStopped)return;var D=I[C];if(q===i2.CAPTURING_PHASE&&!D.capture||q===i2.BUBBLING_PHASE&&D.capture)continue;if(D.f)D.f.call(j.currentTarget,j);else{var L=D.listener.handleEvent;if(typeof L!=="function")throw TypeError("handleEvent property of event listener object is not a function.");L.call(D.listener,j)}}}if(!J._initialized||J._dispatching)uM.InvalidStateError();J.isTrusted=Z,J._dispatching=!0,J.target=this;var K=[];for(var Q=this.parentNode;Q;Q=Q.parentNode)K.push(Q);J.eventPhase=i2.CAPTURING_PHASE;for(var V=K.length-1;V>=0;V--)if(Y(K[V],J),J._propagationStopped)break;if(!J._propagationStopped)J.eventPhase=i2.AT_TARGET,Y(this,J);if(J.bubbles&&!J._propagationStopped){J.eventPhase=i2.BUBBLING_PHASE;for(var X=0,W=K.length;X<W;X++)if(Y(K[X],J),J._propagationStopped)break}if(J._dispatching=!1,J.eventPhase=i2.AT_TARGET,J.currentTarget=null,Z&&!J.defaultPrevented&&J instanceof mM)switch(J.type){case"mousedown":this._armed={x:J.clientX,y:J.clientY,t:J.timeStamp};break;case"mouseout":case"mouseover":this._armed=null;break;case"mouseup":if(this._isClick(J))this._doClick(J);this._armed=null;break}return!J.defaultPrevented},_isClick:function($){return this._armed!==null&&$.type==="mouseup"&&$.isTrusted&&$.button===0&&$.timeStamp-this._armed.t<1000&&Math.abs($.clientX-this._armed.x)<10&&Math.abs($.clientY-this._armed.Y)<10},_doClick:function($){if(this._click_in_progress)return;this._click_in_progress=!0;var J=this;while(J&&!J._post_click_activation_steps)J=J.parentNode;if(J&&J._pre_click_activation_steps)J._pre_click_activation_steps();var Z=this.ownerDocument.createEvent("MouseEvent");Z.initMouseEvent("click",!0,!0,this.ownerDocument.defaultView,1,$.screenX,$.screenY,$.clientX,$.clientY,$.ctrlKey,$.altKey,$.shiftKey,$.metaKey,$.button,null);var Y=this._dispatchEvent(Z,!0);if(J){if(Y){if(J._post_click_activation_steps)J._post_click_activation_steps(Z)}else if(J._cancelled_activation_steps)J._cancelled_activation_steps()}},_setEventHandler:function(J,Z){if(!this._handlers)this._handlers=Object.create(null);this._handlers[J]=Z},_getEventHandler:function(J){return this._handlers&&this._handlers[J]||null}}});var JY=p((Mb,XW)=>{var r1=X0(),V1=XW.exports={valid:function($){return r1.assert($,"list falsy"),r1.assert($._previousSibling,"previous falsy"),r1.assert($._nextSibling,"next falsy"),!0},insertBefore:function($,J){r1.assert(V1.valid($)&&V1.valid(J));var Z=$,Y=$._previousSibling,K=J,Q=J._previousSibling;Z._previousSibling=Q,Y._nextSibling=K,Q._nextSibling=Z,K._previousSibling=Y,r1.assert(V1.valid($)&&V1.valid(J))},replace:function($,J){if(r1.assert(V1.valid($)&&(J===null||V1.valid(J))),J!==null)V1.insertBefore(J,$);V1.remove($),r1.assert(V1.valid($)&&(J===null||V1.valid(J)))},remove:function($){r1.assert(V1.valid($));var J=$._previousSibling;if(J===$)return;var Z=$._nextSibling;J._nextSibling=Z,Z._previousSibling=J,$._previousSibling=$._nextSibling=$,r1.assert(V1.valid($))}}});var ZY=p((Db,qW)=>{qW.exports={serializeOne:iM,\u{275}escapeMatchingClosingTag:HW,\u{275}escapeClosingCommentTag:_W,\u{275}escapeProcessingInstructionContent:OW};var BW=X0(),s2=BW.NAMESPACE,WW={STYLE:!0,SCRIPT:!0,XMP:!0,IFRAME:!0,NOEMBED:!0,NOFRAMES:!0,PLAINTEXT:!0},dM={area:!0,base:!0,basefont:!0,bgsound:!0,br:!0,col:!0,embed:!0,frame:!0,hr:!0,img:!0,input:!0,keygen:!0,link:!0,meta:!0,param:!0,source:!0,track:!0,wbr:!0},pM={},jW=/[&<>\u00A0]/g,UW=/[&"<>\u00A0]/g;function cM($){if(!jW.test($))return $;return $.replace(jW,(J)=>{switch(J){case"&":return"&";case"<":return"<";case">":return">";case"\xA0":return" "}})}function lM($){if(!UW.test($))return $;return $.replace(UW,(J)=>{switch(J){case"<":return"<";case">":return">";case"&":return"&";case'"':return""";case"\xA0":return" "}})}function oM($){var J=$.namespaceURI;if(!J)return $.localName;if(J===s2.XML)return"xml:"+$.localName;if(J===s2.XLINK)return"xlink:"+$.localName;if(J===s2.XMLNS)if($.localName==="xmlns")return"xmlns";else return"xmlns:"+$.localName;return $.name}function HW($,J){let Z="</"+J;if(!$.toLowerCase().includes(Z))return $;let Y=[...$],K=$.matchAll(new RegExp(Z,"ig"));for(let Q of K)Y[Q.index]="<";return Y.join("")}var rM=/--!?>/;function _W($){if(!rM.test($))return $;return $.replace(/(--\!?)>/g,"$1>")}function OW($){return $.includes(">")?$.replaceAll(">",">"):$}function iM($,J){var Z="";switch($.nodeType){case 1:var Y=$.namespaceURI,K=Y===s2.HTML,Q=K||Y===s2.SVG||Y===s2.MATHML?$.localName:$.tagName;Z+="<"+Q;for(var V=0,X=$._numattrs;V<X;V++){var W=$._attr(V);if(Z+=" "+oM(W),W.value!==void 0)Z+='="'+lM(W.value)+'"'}if(Z+=">",!(K&&dM[Q])){var _=$.serialize();if(WW[Q.toUpperCase()])_=HW(_,Q);if(K&&pM[Q]&&_.charAt(0)===`
|
|
30
30
|
`)Z+=`
|
|
31
|
-
`;Z+=B,Z+="</"+Q+">"}break;case 3:case 4:var j;if(J.nodeType===1&&J.namespaceURI===s2.HTML)j=J.tagName;else j="";if(VW[j]||j==="NOSCRIPT"&&J.ownerDocument._scripting_enabled)Z+=$.data;else Z+=fM($.data);break;case 8:Z+="<!--"+UW($.data)+"-->";break;case 7:let _=HW($.data);Z+="<?"+$.target+" "+_+"?>";break;case 10:Z+="<!DOCTYPE "+$.name,Z+=">";break;default:WW.InvalidStateError()}return Z}});var P0=p((Ob,CW)=>{CW.exports=$0;var zW=t7(),vZ=e7(),_W=$Y(),m$=X0();function $0(){zW.call(this),this.parentNode=null,this._nextSibling=this._previousSibling=this,this._index=void 0}var f0=$0.ELEMENT_NODE=1,JY=$0.ATTRIBUTE_NODE=2,hZ=$0.TEXT_NODE=3,cM=$0.CDATA_SECTION_NODE=4,lM=$0.ENTITY_REFERENCE_NODE=5,ZY=$0.ENTITY_NODE=6,OW=$0.PROCESSING_INSTRUCTION_NODE=7,qW=$0.COMMENT_NODE=8,A8=$0.DOCUMENT_NODE=9,G1=$0.DOCUMENT_TYPE_NODE=10,B2=$0.DOCUMENT_FRAGMENT_NODE=11,YY=$0.NOTATION_NODE=12,KY=$0.DOCUMENT_POSITION_DISCONNECTED=1,QY=$0.DOCUMENT_POSITION_PRECEDING=2,VY=$0.DOCUMENT_POSITION_FOLLOWING=4,FW=$0.DOCUMENT_POSITION_CONTAINS=8,GY=$0.DOCUMENT_POSITION_CONTAINED_BY=16,XY=$0.DOCUMENT_POSITION_IMPLEMENTATION_SPECIFIC=32;$0.prototype=Object.create(zW.prototype,{baseURI:{get:m$.nyi},parentElement:{get:function(){return this.parentNode&&this.parentNode.nodeType===f0?this.parentNode:null}},hasChildNodes:{value:m$.shouldOverride},firstChild:{get:m$.shouldOverride},lastChild:{get:m$.shouldOverride},isConnected:{get:function(){let $=this;while($!=null){if($.nodeType===$0.DOCUMENT_NODE)return!0;if($=$.parentNode,$!=null&&$.nodeType===$0.DOCUMENT_FRAGMENT_NODE)$=$.host}return!1}},previousSibling:{get:function(){var $=this.parentNode;if(!$)return null;if(this===$.firstChild)return null;return this._previousSibling}},nextSibling:{get:function(){var $=this.parentNode,J=this._nextSibling;if(!$)return null;if(J===$.firstChild)return null;return J}},textContent:{get:function(){return null},set:function($){}},innerText:{get:function(){return null},set:function($){}},_countChildrenOfType:{value:function($){var J=0;for(var Z=this.firstChild;Z!==null;Z=Z.nextSibling)if(Z.nodeType===$)J++;return J}},_ensureInsertValid:{value:function(J,Z,Y){var K=this,Q,V;if(!J.nodeType)throw TypeError("not a node");switch(K.nodeType){case A8:case B2:case f0:break;default:m$.HierarchyRequestError()}if(J.isAncestor(K))m$.HierarchyRequestError();if(Z!==null||!Y){if(Z.parentNode!==K)m$.NotFoundError()}switch(J.nodeType){case B2:case G1:case f0:case hZ:case OW:case qW:break;default:m$.HierarchyRequestError()}if(K.nodeType===A8)switch(J.nodeType){case hZ:m$.HierarchyRequestError();break;case B2:if(J._countChildrenOfType(hZ)>0)m$.HierarchyRequestError();switch(J._countChildrenOfType(f0)){case 0:break;case 1:if(Z!==null){if(Y&&Z.nodeType===G1)m$.HierarchyRequestError();for(V=Z.nextSibling;V!==null;V=V.nextSibling)if(V.nodeType===G1)m$.HierarchyRequestError()}if(Q=K._countChildrenOfType(f0),Y){if(Q>0)m$.HierarchyRequestError()}else if(Q>1||Q===1&&Z.nodeType!==f0)m$.HierarchyRequestError();break;default:m$.HierarchyRequestError()}break;case f0:if(Z!==null){if(Y&&Z.nodeType===G1)m$.HierarchyRequestError();for(V=Z.nextSibling;V!==null;V=V.nextSibling)if(V.nodeType===G1)m$.HierarchyRequestError()}if(Q=K._countChildrenOfType(f0),Y){if(Q>0)m$.HierarchyRequestError()}else if(Q>1||Q===1&&Z.nodeType!==f0)m$.HierarchyRequestError();break;case G1:if(Z===null){if(K._countChildrenOfType(f0))m$.HierarchyRequestError()}else for(V=K.firstChild;V!==null;V=V.nextSibling){if(V===Z)break;if(V.nodeType===f0)m$.HierarchyRequestError()}if(Q=K._countChildrenOfType(G1),Y){if(Q>0)m$.HierarchyRequestError()}else if(Q>1||Q===1&&Z.nodeType!==G1)m$.HierarchyRequestError();break}else if(J.nodeType===G1)m$.HierarchyRequestError()}},insertBefore:{value:function(J,Z){var Y=this;Y._ensureInsertValid(J,Z,!0);var K=Z;if(K===J)K=J.nextSibling;return Y.doc.adoptNode(J),J._insertOrReplace(Y,K,!1),J}},appendChild:{value:function($){return this.insertBefore($,null)}},_appendChild:{value:function($){$._insertOrReplace(this,null,!1)}},removeChild:{value:function(J){var Z=this;if(!J.nodeType)throw TypeError("not a node");if(J.parentNode!==Z)m$.NotFoundError();return J.remove(),J}},replaceChild:{value:function(J,Z){var Y=this;if(Y._ensureInsertValid(J,Z,!1),J.doc!==Y.doc)Y.doc.adoptNode(J);return J._insertOrReplace(Y,Z,!0),Z}},contains:{value:function(J){if(J===null)return!1;if(this===J)return!0;return(this.compareDocumentPosition(J)&GY)!==0}},compareDocumentPosition:{value:function(J){if(this===J)return 0;if(this.doc!==J.doc||this.rooted!==J.rooted)return KY+XY;var Z=[],Y=[];for(var K=this;K!==null;K=K.parentNode)Z.push(K);for(K=J;K!==null;K=K.parentNode)Y.push(K);if(Z.reverse(),Y.reverse(),Z[0]!==Y[0])return KY+XY;K=Math.min(Z.length,Y.length);for(var Q=1;Q<K;Q++)if(Z[Q]!==Y[Q])if(Z[Q].index<Y[Q].index)return VY;else return QY;if(Z.length<Y.length)return VY+GY;else return QY+FW}},isSameNode:{value:function(J){return this===J}},isEqualNode:{value:function(J){if(!J)return!1;if(J.nodeType!==this.nodeType)return!1;if(!this.isEqual(J))return!1;for(var Z=this.firstChild,Y=J.firstChild;Z&&Y;Z=Z.nextSibling,Y=Y.nextSibling)if(!Z.isEqualNode(Y))return!1;return Z===null&&Y===null}},cloneNode:{value:function($){var J=this.clone();if($)for(var Z=this.firstChild;Z!==null;Z=Z.nextSibling)J._appendChild(Z.cloneNode(!0));return J}},lookupPrefix:{value:function(J){var Z;if(J===""||J===null||J===void 0)return null;switch(this.nodeType){case f0:return this._lookupNamespacePrefix(J,this);case A8:return Z=this.documentElement,Z?Z.lookupPrefix(J):null;case ZY:case YY:case B2:case G1:return null;case JY:return Z=this.ownerElement,Z?Z.lookupPrefix(J):null;default:return Z=this.parentElement,Z?Z.lookupPrefix(J):null}}},lookupNamespaceURI:{value:function(J){if(J===""||J===void 0)J=null;var Z;switch(this.nodeType){case f0:return m$.shouldOverride();case A8:return Z=this.documentElement,Z?Z.lookupNamespaceURI(J):null;case ZY:case YY:case G1:case B2:return null;case JY:return Z=this.ownerElement,Z?Z.lookupNamespaceURI(J):null;default:return Z=this.parentElement,Z?Z.lookupNamespaceURI(J):null}}},isDefaultNamespace:{value:function(J){if(J===""||J===void 0)J=null;var Z=this.lookupNamespaceURI(null);return Z===J}},index:{get:function(){var $=this.parentNode;if(this===$.firstChild)return 0;var J=$.childNodes;if(this._index===void 0||J[this._index]!==this){for(var Z=0;Z<J.length;Z++)J[Z]._index=Z;m$.assert(J[this._index]===this)}return this._index}},isAncestor:{value:function($){if(this.doc!==$.doc)return!1;if(this.rooted!==$.rooted)return!1;for(var J=$;J;J=J.parentNode)if(J===this)return!0;return!1}},ensureSameDoc:{value:function($){if($.ownerDocument===null)$.ownerDocument=this.doc;else if($.ownerDocument!==this.doc)m$.WrongDocumentError()}},removeChildren:{value:m$.shouldOverride},_insertOrReplace:{value:function(J,Z,Y){var K=this,Q,V;if(K.nodeType===B2&&K.rooted)m$.HierarchyRequestError();if(J._childNodes){if(Q=Z===null?J._childNodes.length:Z.index,K.parentNode===J){var X=K.index;if(X<Q)Q--}}if(Y){if(Z.rooted)Z.doc.mutateRemove(Z);Z.parentNode=null}var W=Z;if(W===null)W=J.firstChild;var B=K.rooted&&J.rooted;if(K.nodeType===B2){var j=[0,Y?1:0],_;for(var q=K.firstChild;q!==null;q=_)_=q.nextSibling,j.push(q),q.parentNode=J;var H=j.length;if(Y)vZ.replace(W,H>2?j[2]:null);else if(H>2&&W!==null)vZ.insertBefore(j[2],W);if(J._childNodes){j[0]=Z===null?J._childNodes.length:Z._index,J._childNodes.splice.apply(J._childNodes,j);for(V=2;V<H;V++)j[V]._index=j[0]+(V-2)}else if(J._firstChild===Z){if(H>2)J._firstChild=j[2];else if(Y)J._firstChild=null}if(K._childNodes)K._childNodes.length=0;else K._firstChild=null;if(J.rooted){J.modify();for(V=2;V<H;V++)J.doc.mutateInsert(j[V])}}else{if(Z===K)return;if(B)K._remove();else if(K.parentNode)K.remove();if(K.parentNode=J,Y){if(vZ.replace(W,K),J._childNodes)K._index=Q,J._childNodes[Q]=K;else if(J._firstChild===Z)J._firstChild=K}else{if(W!==null)vZ.insertBefore(K,W);if(J._childNodes)K._index=Q,J._childNodes.splice(Q,0,K);else if(J._firstChild===Z)J._firstChild=K}if(B)J.modify(),J.doc.mutateMove(K);else if(J.rooted)J.modify(),J.doc.mutateInsert(K)}}},lastModTime:{get:function(){if(!this._lastModTime)this._lastModTime=this.doc.modclock;return this._lastModTime}},modify:{value:function(){if(this.doc.modclock){var $=++this.doc.modclock;for(var J=this;J;J=J.parentElement)if(J._lastModTime)J._lastModTime=$}}},doc:{get:function(){return this.ownerDocument||this}},rooted:{get:function(){return!!this._nid}},normalize:{value:function(){var $;for(var J=this.firstChild;J!==null;J=$){if($=J.nextSibling,J.normalize)J.normalize();if(J.nodeType!==$0.TEXT_NODE)continue;if(J.nodeValue===""){this.removeChild(J);continue}var Z=J.previousSibling;if(Z===null)continue;else if(Z.nodeType===$0.TEXT_NODE)Z.appendData(J.nodeValue),this.removeChild(J)}}},serialize:{value:function(){if(this._innerHTML)return this._innerHTML;var $="";for(var J=this.firstChild;J!==null;J=J.nextSibling)$+=_W.serializeOne(J,this);return $}},outerHTML:{get:function(){return _W.serializeOne(this,{nodeType:0})},set:m$.nyi},ELEMENT_NODE:{value:f0},ATTRIBUTE_NODE:{value:JY},TEXT_NODE:{value:hZ},CDATA_SECTION_NODE:{value:cM},ENTITY_REFERENCE_NODE:{value:lM},ENTITY_NODE:{value:ZY},PROCESSING_INSTRUCTION_NODE:{value:OW},COMMENT_NODE:{value:qW},DOCUMENT_NODE:{value:A8},DOCUMENT_TYPE_NODE:{value:G1},DOCUMENT_FRAGMENT_NODE:{value:B2},NOTATION_NODE:{value:YY},DOCUMENT_POSITION_DISCONNECTED:{value:KY},DOCUMENT_POSITION_PRECEDING:{value:QY},DOCUMENT_POSITION_FOLLOWING:{value:VY},DOCUMENT_POSITION_CONTAINS:{value:FW},DOCUMENT_POSITION_CONTAINED_BY:{value:GY},DOCUMENT_POSITION_IMPLEMENTATION_SPECIFIC:{value:XY}})});var DW=p((qb,MW)=>{MW.exports=class extends Array{constructor(J){super(J&&J.length||0);if(J)for(var Z in J)this[Z]=J[Z]}item(J){return this[J]||null}}});var IW=p((Fb,PW)=>{function oM($){return this[$]||null}function rM($){if(!$)$=[];return $.item=oM,$}PW.exports=rM});var n2=p((zb,AW)=>{var WY;try{WY=DW()}catch($){WY=IW()}AW.exports=WY});var gZ=p((Cb,RW)=>{RW.exports=wW;var SW=P0(),iM=n2();function wW(){SW.call(this),this._firstChild=this._childNodes=null}wW.prototype=Object.create(SW.prototype,{hasChildNodes:{value:function(){if(this._childNodes)return this._childNodes.length>0;return this._firstChild!==null}},childNodes:{get:function(){return this._ensureChildNodes(),this._childNodes}},firstChild:{get:function(){if(this._childNodes)return this._childNodes.length===0?null:this._childNodes[0];return this._firstChild}},lastChild:{get:function(){var $=this._childNodes,J;if($)return $.length===0?null:$[$.length-1];if(J=this._firstChild,J===null)return null;return J._previousSibling}},_ensureChildNodes:{value:function(){if(this._childNodes)return;var $=this._firstChild,J=$,Z=this._childNodes=new iM;if($)do Z.push(J),J=J._nextSibling;while(J!==$);this._firstChild=null}},removeChildren:{value:function(){var J=this.rooted?this.ownerDocument:null,Z=this.firstChild,Y;while(Z!==null){if(Y=Z,Z=Y.nextSibling,J)J.mutateRemove(Y);Y.parentNode=null}if(this._childNodes)this._childNodes.length=0;else this._firstChild=null;this.modify()}}})});var fZ=p((YD)=>{YD.isValidName=JD;YD.isValidQName=ZD;var sM=/^[_:A-Za-z][-.:\w]+$/,nM=/^([_A-Za-z][-.\w]+|[_A-Za-z][-.\w]+:[_A-Za-z][-.\w]+)$/,S8="_A-Za-z\xC0-\xD6\xD8-\xF6\xF8-\u02FF\u0370-\u037D\u037F-\u1FFF\u200C-\u200D\u2070-\u218F\u2C00-\u2FEF\u3001-\uD7FF\uF900-\uFDCF\uFDF0-\uFFFD",w8="-._A-Za-z0-9\xB7\xC0-\xD6\xD8-\xF6\xF8-\u02FF\u0300-\u037D\u037F-\u1FFF\u200C\u200D\u203F\u2040\u2070-\u218F\u2C00-\u2FEF\u3001-\uD7FF\uF900-\uFDCF\uFDF0-\uFFFD",a2="["+S8+"]["+w8+"]*",jY=S8+":",UY=w8+":",aM=new RegExp("^["+jY+"]["+UY+"]*$"),tM=new RegExp("^("+a2+"|"+a2+":"+a2+")$"),LW=/[\uD800-\uDB7F\uDC00-\uDFFF]/,NW=/[\uD800-\uDB7F\uDC00-\uDFFF]/g,yW=/[\uD800-\uDB7F][\uDC00-\uDFFF]/g;S8+="\uD800-\uDB7F\uDC00-\uDFFF";w8+="\uD800-\uDB7F\uDC00-\uDFFF";a2="["+S8+"]["+w8+"]*";jY=S8+":";UY=w8+":";var eM=new RegExp("^["+jY+"]["+UY+"]*$"),$D=new RegExp("^("+a2+"|"+a2+":"+a2+")$");function JD($){if(sM.test($))return!0;if(aM.test($))return!0;if(!LW.test($))return!1;if(!eM.test($))return!1;var J=$.match(NW),Z=$.match(yW);return Z!==null&&2*Z.length===J.length}function ZD($){if(nM.test($))return!0;if(tM.test($))return!0;if(!LW.test($))return!1;if(!$D.test($))return!1;var J=$.match(NW),Z=$.match(yW);return Z!==null&&2*Z.length===J.length}});var HY=p((GD)=>{var TW=X0();GD.property=function($){if(Array.isArray($.type)){var J=Object.create(null);$.type.forEach(function(K){J[K.value||K]=K.alias||K});var Z=$.missing;if(Z===void 0)Z=null;var Y=$.invalid;if(Y===void 0)Y=Z;return{get:function(){var K=this._getattr($.name);if(K===null)return Z;if(K=J[K.toLowerCase()],K!==void 0)return K;if(Y!==null)return Y;return K},set:function(K){this._setattr($.name,K)}}}else if($.type===Boolean)return{get:function(){return this.hasAttribute($.name)},set:function(K){if(K)this._setattr($.name,"");else this.removeAttribute($.name)}};else if($.type===Number||$.type==="long"||$.type==="unsigned long"||$.type==="limited unsigned long with fallback")return VD($);else if(!$.type||$.type===String)return{get:function(){return this._getattr($.name)||""},set:function(K){if($.treatNullAsEmptyString&&K===null)K="";this._setattr($.name,K)}};else if(typeof $.type==="function")return $.type($.name,$);throw Error("Invalid attribute definition")};function VD($){var J;if(typeof $.default==="function")J=$.default;else if(typeof $.default==="number")J=function(){return $.default};else J=function(){TW.assert(!1,typeof $.default)};var Z=$.type==="unsigned long",Y=$.type==="long",K=$.type==="limited unsigned long with fallback",Q=$.min,V=$.max,X=$.setmin;if(Q===void 0){if(Z)Q=0;if(Y)Q=-2147483648;if(K)Q=1}if(V===void 0){if(Z||Y||K)V=2147483647}return{get:function(){var W=this._getattr($.name),B=$.float?parseFloat(W):parseInt(W,10);if(W===null||!isFinite(B)||Q!==void 0&&B<Q||V!==void 0&&B>V)return J.call(this);if(Z||Y||K){if(!/^[ \t\n\f\r]*[-+]?[0-9]/.test(W))return J.call(this);B=B|0}return B},set:function(W){if(!$.float)W=Math.floor(W);if(X!==void 0&&W<X)TW.IndexSizeError($.name+" set to "+W);if(Z)W=W<0||W>2147483647?J.call(this):W|0;else if(K)W=W<1||W>2147483647?J.call(this):W|0;else if(Y)W=W<-2147483648||W>2147483647?J.call(this):W|0;this._setattr($.name,String(W))}}}GD.registerChangeHandler=function($,J,Z){var Y=$.prototype;if(!Object.prototype.hasOwnProperty.call(Y,"_attributeChangeHandlers"))Y._attributeChangeHandlers=Object.create(Y._attributeChangeHandlers||null);Y._attributeChangeHandlers[J]=Z}});var xW=p((Pb,EW)=>{EW.exports=kW;var jD=P0();function kW($,J){this.root=$,this.filter=J,this.lastModTime=$.lastModTime,this.done=!1,this.cache=[],this.traverse()}kW.prototype=Object.create(Object.prototype,{length:{get:function(){if(this.checkcache(),!this.done)this.traverse();return this.cache.length}},item:{value:function($){if(this.checkcache(),!this.done&&$>=this.cache.length)this.traverse();return this.cache[$]}},checkcache:{value:function(){if(this.lastModTime!==this.root.lastModTime){for(var $=this.cache.length-1;$>=0;$--)this[$]=void 0;this.cache.length=0,this.done=!1,this.lastModTime=this.root.lastModTime}}},traverse:{value:function($){if($!==void 0)$++;var J;while((J=this.next())!==null)if(this[this.cache.length]=J,this.cache.push(J),$&&this.cache.length===$)return;this.done=!0}},next:{value:function(){var $=this.cache.length===0?this.root:this.cache[this.cache.length-1],J;if($.nodeType===jD.DOCUMENT_NODE)J=$.documentElement;else J=$.nextElement(this.root);while(J){if(this.filter(J))return J;J=J.nextElement(this.root)}return null}}})});var _Y=p((Ib,hW)=>{var BY=X0();hW.exports=vW;function vW($,J){this._getString=$,this._setString=J,this._length=0,this._lastStringValue="",this._update()}Object.defineProperties(vW.prototype,{length:{get:function(){return this._length}},item:{value:function($){var J=kJ(this);if($<0||$>=J.length)return null;return J[$]}},contains:{value:function($){$=String($);var J=kJ(this);return J.indexOf($)>-1}},add:{value:function(){var $=kJ(this);for(var J=0,Z=arguments.length;J<Z;J++){var Y=R8(arguments[J]);if($.indexOf(Y)<0)$.push(Y)}this._update($)}},remove:{value:function(){var $=kJ(this);for(var J=0,Z=arguments.length;J<Z;J++){var Y=R8(arguments[J]),K=$.indexOf(Y);if(K>-1)$.splice(K,1)}this._update($)}},toggle:{value:function(J,Z){if(J=R8(J),this.contains(J)){if(Z===void 0||Z===!1)return this.remove(J),!1;return!0}else{if(Z===void 0||Z===!0)return this.add(J),!0;return!1}}},replace:{value:function(J,Z){if(String(Z)==="")BY.SyntaxError();J=R8(J),Z=R8(Z);var Y=kJ(this),K=Y.indexOf(J);if(K<0)return!1;var Q=Y.indexOf(Z);if(Q<0)Y[K]=Z;else if(K<Q)Y[K]=Z,Y.splice(Q,1);else Y.splice(K,1);return this._update(Y),!0}},toString:{value:function(){return this._getString()}},value:{get:function(){return this._getString()},set:function($){this._setString($),this._update()}},_update:{value:function($){if($)bW(this,$),this._setString($.join(" ").trim());else bW(this,kJ(this));this._lastStringValue=this._getString()}}});function bW($,J){var Z=$._length,Y;$._length=J.length;for(Y=0;Y<J.length;Y++)$[Y]=J[Y];for(;Y<Z;Y++)$[Y]=void 0}function R8($){if($=String($),$==="")BY.SyntaxError();if(/[ \t\r\n\f]/.test($))BY.InvalidCharacterError();return $}function UD($){var J=$._length,Z=Array(J);for(var Y=0;Y<J;Y++)Z[Y]=$[Y];return Z}function kJ($){var J=$._getString();if(J===$._lastStringValue)return UD($);var Z=J.replace(/(^[ \t\r\n\f]+)|([ \t\r\n\f]+$)/g,"");if(Z==="")return[];else{var Y=Object.create(null);return Z.split(/[ \t\r\n\f]+/g).filter(function(K){var Q="$"+K;if(Y[Q])return!1;return Y[Q]=!0,!0})}}});var pZ=p((bJ,pW)=>{var mZ=Object.create(null,{location:{get:function(){throw Error("window.location is not supported.")}}}),HD=function($,J){return $.compareDocumentPosition(J)},BD=function($,J){return HD($,J)&2?1:-1},dZ=function($){while(($=$.nextSibling)&&$.nodeType!==1);return $},xJ=function($){while(($=$.previousSibling)&&$.nodeType!==1);return $},_D=function($){if($=$.firstChild)while($.nodeType!==1&&($=$.nextSibling));return $},OD=function($){if($=$.lastChild)while($.nodeType!==1&&($=$.previousSibling));return $},EJ=function($){if(!$.parentNode)return!1;var J=$.parentNode.nodeType;return J===1||J===9},gW=function($){if(!$)return $;var J=$[0];if(J==='"'||J==="'"){if($[$.length-1]===J)$=$.slice(1,-1);else $=$.slice(1);return $.replace(_$.str_escape,function(Z){var Y=/^\\(?:([0-9A-Fa-f]+)|([\r\n\f]+))/.exec(Z);if(!Y)return Z.slice(1);if(Y[2])return"";var K=parseInt(Y[1],16);return String.fromCodePoint?String.fromCodePoint(K):String.fromCharCode(K)})}else if(_$.ident.test($))return _2($);else return $},_2=function($){return $.replace(_$.escape,function(J){var Z=/^\\([0-9A-Fa-f]+)/.exec(J);if(!Z)return J[1];var Y=parseInt(Z[1],16);return String.fromCodePoint?String.fromCodePoint(Y):String.fromCharCode(Y)})},qD=function(){if(Array.prototype.indexOf)return Array.prototype.indexOf;return function($,J){var Z=this.length;while(Z--)if(this[Z]===J)return Z;return-1}}(),mW=function($,J){var Z=_$.inside.source.replace(/</g,$).replace(/>/g,J);return new RegExp(Z)},m0=function($,J,Z){return $=$.source,$=$.replace(J,Z.source||Z),new RegExp($)},fW=function($,J){return $.replace(/^(?:\w+:\/\/|\/+)/,"").replace(/(?:\/+|\/*#.*?)$/,"").split("/",J).join("/")},FD=function($,J){var Z=$.replace(/\s+/g,""),Y;if(Z==="even")Z="2n+0";else if(Z==="odd")Z="2n+1";else if(Z.indexOf("n")===-1)Z="0n"+Z;return Y=/^([+-])?(\d+)?n([+-])?(\d+)?$/.exec(Z),{group:Y[1]==="-"?-(Y[2]||1):+(Y[2]||1),offset:Y[4]?Y[3]==="-"?-Y[4]:+Y[4]:0}},OY=function($,J,Z){var Y=FD($),K=Y.group,Q=Y.offset,V=!Z?_D:OD,X=!Z?dZ:xJ;return function(W){if(!EJ(W))return;var B=V(W.parentNode),j=0;while(B){if(J(B,W))j++;if(B===W)return j-=Q,K&&j?j%K===0&&j<0===K<0:!j;B=X(B)}}},z0={"*":function(){return function(){return!0}}(),type:function($){return $=$.toLowerCase(),function(J){return J.nodeName.toLowerCase()===$}},attr:function($,J,Z,Y){return J=uW[J],function(K){var Q;switch($){case"for":Q=K.htmlFor;break;case"class":if(Q=K.className,Q===""&&K.getAttribute("class")==null)Q=null;break;case"href":case"src":Q=K.getAttribute($,2);break;case"title":Q=K.getAttribute("title")||null;break;case"id":case"lang":case"dir":case"accessKey":case"hidden":case"tabIndex":case"style":if(K.getAttribute){Q=K.getAttribute($);break}default:if(K.hasAttribute&&!K.hasAttribute($))break;Q=K[$]!=null?K[$]:K.getAttribute&&K.getAttribute($);break}if(Q==null)return;if(Q=Q+"",Y)Q=Q.toLowerCase(),Z=Z.toLowerCase();return J(Q,Z)}},":first-child":function($){return!xJ($)&&EJ($)},":last-child":function($){return!dZ($)&&EJ($)},":only-child":function($){return!xJ($)&&!dZ($)&&EJ($)},":nth-child":function($,J){return OY($,function(){return!0},J)},":nth-last-child":function($){return z0[":nth-child"]($,!0)},":root":function($){return $.ownerDocument.documentElement===$},":empty":function($){return!$.firstChild},":not":function($){var J=FY($);return function(Z){return!J(Z)}},":first-of-type":function($){if(!EJ($))return;var J=$.nodeName;while($=xJ($))if($.nodeName===J)return;return!0},":last-of-type":function($){if(!EJ($))return;var J=$.nodeName;while($=dZ($))if($.nodeName===J)return;return!0},":only-of-type":function($){return z0[":first-of-type"]($)&&z0[":last-of-type"]($)},":nth-of-type":function($,J){return OY($,function(Z,Y){return Z.nodeName===Y.nodeName},J)},":nth-last-of-type":function($){return z0[":nth-of-type"]($,!0)},":checked":function($){return!!($.checked||$.selected)},":indeterminate":function($){return!z0[":checked"]($)},":enabled":function($){return!$.disabled&&$.type!=="hidden"},":disabled":function($){return!!$.disabled},":target":function($){return $.id===mZ.location.hash.substring(1)},":focus":function($){return $===$.ownerDocument.activeElement},":is":function($){return FY($)},":matches":function($){return z0[":is"]($)},":nth-match":function($,J){var Z=$.split(/\s*,\s*/),Y=Z.shift(),K=FY(Z.join(","));return OY(Y,K,J)},":nth-last-match":function($){return z0[":nth-match"]($,!0)},":links-here":function($){return $+""===mZ.location+""},":lang":function($){return function(J){while(J){if(J.lang)return J.lang.indexOf($)===0;J=J.parentNode}}},":dir":function($){return function(J){while(J){if(J.dir)return J.dir===$;J=J.parentNode}}},":scope":function($,J){var Z=J||$.ownerDocument;if(Z.nodeType===9)return $===Z.documentElement;return $===Z},":any-link":function($){return typeof $.href==="string"},":local-link":function($){if($.nodeName)return $.href&&$.host===mZ.location.host;var J=+$+1;return function(Z){if(!Z.href)return;var Y=mZ.location+"",K=Z+"";return fW(Y,J)===fW(K,J)}},":default":function($){return!!$.defaultSelected},":valid":function($){return $.willValidate||$.validity&&$.validity.valid},":invalid":function($){return!z0[":valid"]($)},":in-range":function($){return $.value>$.min&&$.value<=$.max},":out-of-range":function($){return!z0[":in-range"]($)},":required":function($){return!!$.required},":optional":function($){return!$.required},":read-only":function($){if($.readOnly)return!0;var J=$.getAttribute("contenteditable"),Z=$.contentEditable,Y=$.nodeName.toLowerCase();return Y=Y!=="input"&&Y!=="textarea",(Y||$.disabled)&&J==null&&Z!=="true"},":read-write":function($){return!z0[":read-only"]($)},":hover":function(){throw Error(":hover is not supported.")},":active":function(){throw Error(":active is not supported.")},":link":function(){throw Error(":link is not supported.")},":visited":function(){throw Error(":visited is not supported.")},":column":function(){throw Error(":column is not supported.")},":nth-column":function(){throw Error(":nth-column is not supported.")},":nth-last-column":function(){throw Error(":nth-last-column is not supported.")},":current":function(){throw Error(":current is not supported.")},":past":function(){throw Error(":past is not supported.")},":future":function(){throw Error(":future is not supported.")},":contains":function($){return function(J){var Z=J.innerText||J.textContent||J.value||"";return Z.indexOf($)!==-1}},":has":function($){return function(J){return dW($,J).length>0}}},uW={"-":function(){return!0},"=":function($,J){return $===J},"*=":function($,J){return $.indexOf(J)!==-1},"~=":function($,J){var Z,Y,K,Q;for(Y=0;;Y=Z+1){if(Z=$.indexOf(J,Y),Z===-1)return!1;if(K=$[Z-1],Q=$[Z+J.length],(!K||K===" ")&&(!Q||Q===" "))return!0}},"|=":function($,J){var Z=$.indexOf(J),Y;if(Z!==0)return;return Y=$[Z+J.length],Y==="-"||!Y},"^=":function($,J){return $.indexOf(J)===0},"$=":function($,J){var Z=$.lastIndexOf(J);return Z!==-1&&Z+J.length===$.length},"!=":function($,J){return $!==J}},L8={" ":function($){return function(J){while(J=J.parentNode)if($(J))return J}},">":function($){return function(J){if(J=J.parentNode)return $(J)&&J}},"+":function($){return function(J){if(J=xJ(J))return $(J)&&J}},"~":function($){return function(J){while(J=xJ(J))if($(J))return J}},noop:function($){return function(J){return $(J)&&J}},ref:function($,J){var Z;function Y(K){var Q=K.ownerDocument,V=Q.getElementsByTagName("*"),X=V.length;while(X--)if(Z=V[X],Y.test(K))return Z=null,!0;Z=null}return Y.combinator=function(K){if(!Z||!Z.getAttribute)return;var Q=Z.getAttribute(J)||"";if(Q[0]==="#")Q=Q.substring(1);if(Q===K.id&&$(Z))return Z},Y}},_$={escape:/\\(?:[^0-9A-Fa-f\r\n]|[0-9A-Fa-f]{1,6}[\r\n\t ]?)/g,str_escape:/(escape)|\\(\n|\r\n?|\f)/g,nonascii:/[\u00A0-\uFFFF]/,cssid:/(?:(?!-?[0-9])(?:escape|nonascii|[-_a-zA-Z0-9])+)/,qname:/^ *(cssid|\*)/,simple:/^(?:([.#]cssid)|pseudo|attr)/,ref:/^ *\/(cssid)\/ */,combinator:/^(?: +([^ \w*.#\\]) +|( )+|([^ \w*.#\\]))(?! *$)/,attr:/^\[(cssid)(?:([^\w]?=)(inside))?\]/,pseudo:/^(:cssid)(?:\((inside)\))?/,inside:/(?:"(?:\\"|[^"])*"|'(?:\\'|[^'])*'|<[^"'>]*>|\\["'>]|[^"'>])*/,ident:/^(cssid)$/};_$.cssid=m0(_$.cssid,"nonascii",_$.nonascii);_$.cssid=m0(_$.cssid,"escape",_$.escape);_$.qname=m0(_$.qname,"cssid",_$.cssid);_$.simple=m0(_$.simple,"cssid",_$.cssid);_$.ref=m0(_$.ref,"cssid",_$.cssid);_$.attr=m0(_$.attr,"cssid",_$.cssid);_$.pseudo=m0(_$.pseudo,"cssid",_$.cssid);_$.inside=m0(_$.inside,`[^"'>]*`,_$.inside);_$.attr=m0(_$.attr,"inside",mW("\\[","\\]"));_$.pseudo=m0(_$.pseudo,"inside",mW("\\(","\\)"));_$.simple=m0(_$.simple,"pseudo",_$.pseudo);_$.simple=m0(_$.simple,"attr",_$.attr);_$.ident=m0(_$.ident,"cssid",_$.cssid);_$.str_escape=m0(_$.str_escape,"escape",_$.escape);var N8=function($){var J=$.replace(/^\s+|\s+$/g,""),Z,Y=[],K=[],Q,V,X,W,B;while(J){if(X=_$.qname.exec(J))J=J.substring(X[0].length),V=_2(X[1]),K.push(uZ(V,!0));else if(X=_$.simple.exec(J))J=J.substring(X[0].length),V="*",K.push(uZ(V,!0)),K.push(uZ(X));else throw SyntaxError("Invalid selector.");while(X=_$.simple.exec(J))J=J.substring(X[0].length),K.push(uZ(X));if(J[0]==="!")J=J.substring(1),Q=CD(),Q.qname=V,K.push(Q.simple);if(X=_$.ref.exec(J)){J=J.substring(X[0].length),B=L8.ref(qY(K),_2(X[1])),Y.push(B.combinator),K=[];continue}if(X=_$.combinator.exec(J)){if(J=J.substring(X[0].length),W=X[1]||X[2]||X[3],W===","){Y.push(L8.noop(qY(K)));break}}else W="noop";if(!L8[W])throw SyntaxError("Bad combinator.");Y.push(L8[W](qY(K))),K=[]}if(Z=zD(Y),Z.qname=V,Z.sel=J,Q)Q.lname=Z.qname,Q.test=Z,Q.qname=Q.qname,Q.sel=Z.sel,Z=Q;if(B)B.test=Z,B.qname=Z.qname,B.sel=Z.sel,Z=B;return Z},uZ=function($,J){if(J)return $==="*"?z0["*"]:z0.type($);if($[1])return $[1][0]==="."?z0.attr("class","~=",_2($[1].substring(1)),!1):z0.attr("id","=",_2($[1].substring(1)),!1);if($[2])return $[3]?z0[_2($[2])](gW($[3])):z0[_2($[2])];if($[4]){var Z=$[6],Y=/["'\s]\s*I$/i.test(Z);if(Y)Z=Z.replace(/\s*I$/i,"");return z0.attr(_2($[4]),$[5]||"-",gW(Z),Y)}throw SyntaxError("Unknown Selector.")},qY=function($){var J=$.length,Z;if(J<2)return $[0];return function(Y){if(!Y)return;for(Z=0;Z<J;Z++)if(!$[Z](Y))return;return!0}},zD=function($){if($.length<2)return function(J){return!!$[0](J)};return function(J){var Z=$.length;while(Z--)if(!(J=$[Z](J)))return;return!0}},CD=function(){var $;function J(Z){var Y=Z.ownerDocument,K=Y.getElementsByTagName(J.lname),Q=K.length;while(Q--)if(J.test(K[Q])&&$===Z)return $=null,!0;$=null}return J.simple=function(Z){return $=Z,!0},J},FY=function($){var J=N8($),Z=[J];while(J.sel)J=N8(J.sel),Z.push(J);if(Z.length<2)return J;return function(Y){var K=Z.length,Q=0;for(;Q<K;Q++)if(Z[Q](Y))return!0}},dW=function($,J){var Z=[],Y=N8($),K=J.getElementsByTagName(Y.qname),Q=0,V;while(V=K[Q++])if(Y(V))Z.push(V);if(Y.sel){while(Y.sel){Y=N8(Y.sel),K=J.getElementsByTagName(Y.qname),Q=0;while(V=K[Q++])if(Y(V)&&qD.call(Z,V)===-1)Z.push(V)}Z.sort(BD)}return Z};pW.exports=bJ=function($,J){var Z,Y;if(J.nodeType!==11&&$.indexOf(" ")===-1){if($[0]==="#"&&J.rooted&&/^#[A-Z_][-A-Z0-9_]*$/i.test($)){if(J.doc._hasMultipleElementsWithId){if(Z=$.substring(1),!J.doc._hasMultipleElementsWithId(Z))return Y=J.doc.getElementById(Z),Y?[Y]:[]}}if($[0]==="."&&/^\.\w+$/.test($))return J.getElementsByClassName($.substring(1));if(/^\w+$/.test($))return J.getElementsByTagName($)}return dW($,J)};bJ.selectors=z0;bJ.operators=uW;bJ.combinators=L8;bJ.matches=function($,J){var Z={sel:J};do if(Z=N8(Z.sel),Z($))return!0;while(Z.sel);return!1}});var cZ=p((Ab,cW)=>{var MD=P0(),DD=e7(),zY=function($,J){var Z=$.createDocumentFragment();for(var Y=0;Y<J.length;Y++){var K=J[Y],Q=K instanceof MD;Z.appendChild(Q?K:$.createTextNode(String(K)))}return Z},PD={after:{value:function(){var J=Array.prototype.slice.call(arguments),Z=this.parentNode,Y=this.nextSibling;if(Z===null)return;while(Y&&J.some(function(Q){return Q===Y}))Y=Y.nextSibling;var K=zY(this.doc,J);Z.insertBefore(K,Y)}},before:{value:function(){var J=Array.prototype.slice.call(arguments),Z=this.parentNode,Y=this.previousSibling;if(Z===null)return;while(Y&&J.some(function(V){return V===Y}))Y=Y.previousSibling;var K=zY(this.doc,J),Q=Y?Y.nextSibling:Z.firstChild;Z.insertBefore(K,Q)}},remove:{value:function(){if(this.parentNode===null)return;if(this.doc){if(this.doc._preremoveNodeIterators(this),this.rooted)this.doc.mutateRemove(this)}this._remove(),this.parentNode=null}},_remove:{value:function(){var J=this.parentNode;if(J===null)return;if(J._childNodes)J._childNodes.splice(this.index,1);else if(J._firstChild===this)if(this._nextSibling===this)J._firstChild=null;else J._firstChild=this._nextSibling;DD.remove(this),J.modify()}},replaceWith:{value:function(){var J=Array.prototype.slice.call(arguments),Z=this.parentNode,Y=this.nextSibling;if(Z===null)return;while(Y&&J.some(function(Q){return Q===Y}))Y=Y.nextSibling;var K=zY(this.doc,J);if(this.parentNode===Z)Z.replaceChild(K,this);else Z.insertBefore(K,Y)}}};cW.exports=PD});var CY=p((Sb,oW)=>{var lW=P0(),ID={nextElementSibling:{get:function(){if(this.parentNode){for(var $=this.nextSibling;$!==null;$=$.nextSibling)if($.nodeType===lW.ELEMENT_NODE)return $}return null}},previousElementSibling:{get:function(){if(this.parentNode){for(var $=this.previousSibling;$!==null;$=$.previousSibling)if($.nodeType===lW.ELEMENT_NODE)return $}return null}}};oW.exports=ID});var MY=p((wb,iW)=>{iW.exports=rW;var vJ=X0();function rW($){this.element=$}Object.defineProperties(rW.prototype,{length:{get:vJ.shouldOverride},item:{value:vJ.shouldOverride},getNamedItem:{value:function(J){return this.element.getAttributeNode(J)}},getNamedItemNS:{value:function(J,Z){return this.element.getAttributeNodeNS(J,Z)}},setNamedItem:{value:vJ.nyi},setNamedItemNS:{value:vJ.nyi},removeNamedItem:{value:function(J){var Z=this.element.getAttributeNode(J);if(Z)return this.element.removeAttribute(J),Z;vJ.NotFoundError()}},removeNamedItemNS:{value:function(J,Z){var Y=this.element.getAttributeNodeNS(J,Z);if(Y)return this.element.removeAttributeNS(J,Z),Y;vJ.NotFoundError()}}})});var gJ=p((Rb,eW)=>{eW.exports=O2;var DY=fZ(),Y0=X0(),N1=Y0.NAMESPACE,oZ=HY(),q1=P0(),PY=n2(),AD=$Y(),lZ=xW(),hJ=xZ(),SD=_Y(),IY=pZ(),nW=gZ(),wD=cZ(),RD=CY(),aW=MY(),sW=Object.create(null);function O2($,J,Z,Y){nW.call(this),this.nodeType=q1.ELEMENT_NODE,this.ownerDocument=$,this.localName=J,this.namespaceURI=Z,this.prefix=Y,this._tagName=void 0,this._attrsByQName=Object.create(null),this._attrsByLName=Object.create(null),this._attrKeys=[]}function AY($,J){if($.nodeType===q1.TEXT_NODE)J.push($._data);else for(var Z=0,Y=$.childNodes.length;Z<Y;Z++)AY($.childNodes[Z],J)}O2.prototype=Object.create(nW.prototype,{isHTML:{get:function(){return this.namespaceURI===N1.HTML&&this.ownerDocument.isHTML}},tagName:{get:function(){if(this._tagName===void 0){var J;if(this.prefix===null)J=this.localName;else J=this.prefix+":"+this.localName;if(this.isHTML){var Z=sW[J];if(!Z)sW[J]=Z=Y0.toASCIIUpperCase(J);J=Z}this._tagName=J}return this._tagName}},nodeName:{get:function(){return this.tagName}},nodeValue:{get:function(){return null},set:function(){}},textContent:{get:function(){var $=[];return AY(this,$),$.join("")},set:function($){if(this.removeChildren(),$!==null&&$!==void 0&&$!=="")this._appendChild(this.ownerDocument.createTextNode($))}},innerText:{get:function(){var $=[];return AY(this,$),$.join("").replace(/[ \t\n\f\r]+/g," ").trim()},set:function($){if(this.removeChildren(),$!==null&&$!==void 0&&$!=="")this._appendChild(this.ownerDocument.createTextNode($))}},innerHTML:{get:function(){return this.serialize()},set:Y0.nyi},outerHTML:{get:function(){return AD.serializeOne(this,{nodeType:0})},set:function($){var J=this.ownerDocument,Z=this.parentNode;if(Z===null)return;if(Z.nodeType===q1.DOCUMENT_NODE)Y0.NoModificationAllowedError();if(Z.nodeType===q1.DOCUMENT_FRAGMENT_NODE)Z=Z.ownerDocument.createElement("body");var Y=J.implementation.mozHTMLParser(J._address,Z);Y.parse($===null?"":String($),!0),this.replaceWith(Y._asDocumentFragment())}},_insertAdjacent:{value:function(J,Z){var Y=!1;switch(J){case"beforebegin":Y=!0;case"afterend":var K=this.parentNode;if(K===null)return null;return K.insertBefore(Z,Y?this:this.nextSibling);case"afterbegin":Y=!0;case"beforeend":return this.insertBefore(Z,Y?this.firstChild:null);default:return Y0.SyntaxError()}}},insertAdjacentElement:{value:function(J,Z){if(Z.nodeType!==q1.ELEMENT_NODE)throw TypeError("not an element");return J=Y0.toASCIILowerCase(String(J)),this._insertAdjacent(J,Z)}},insertAdjacentText:{value:function(J,Z){var Y=this.ownerDocument.createTextNode(Z);J=Y0.toASCIILowerCase(String(J)),this._insertAdjacent(J,Y)}},insertAdjacentHTML:{value:function(J,Z){J=Y0.toASCIILowerCase(String(J)),Z=String(Z);var Y;switch(J){case"beforebegin":case"afterend":if(Y=this.parentNode,Y===null||Y.nodeType===q1.DOCUMENT_NODE)Y0.NoModificationAllowedError();break;case"afterbegin":case"beforeend":Y=this;break;default:Y0.SyntaxError()}if(!(Y instanceof O2)||Y.ownerDocument.isHTML&&Y.localName==="html"&&Y.namespaceURI===N1.HTML)Y=Y.ownerDocument.createElementNS(N1.HTML,"body");var K=this.ownerDocument.implementation.mozHTMLParser(this.ownerDocument._address,Y);K.parse(Z,!0),this._insertAdjacent(J,K._asDocumentFragment())}},children:{get:function(){if(!this._children)this._children=new tW(this);return this._children}},attributes:{get:function(){if(!this._attributes)this._attributes=new wY(this);return this._attributes}},firstElementChild:{get:function(){for(var $=this.firstChild;$!==null;$=$.nextSibling)if($.nodeType===q1.ELEMENT_NODE)return $;return null}},lastElementChild:{get:function(){for(var $=this.lastChild;$!==null;$=$.previousSibling)if($.nodeType===q1.ELEMENT_NODE)return $;return null}},childElementCount:{get:function(){return this.children.length}},nextElement:{value:function($){if(!$)$=this.ownerDocument.documentElement;var J=this.firstElementChild;if(!J){if(this===$)return null;J=this.nextElementSibling}if(J)return J;for(var Z=this.parentElement;Z&&Z!==$;Z=Z.parentElement)if(J=Z.nextElementSibling,J)return J;return null}},getElementsByTagName:{value:function(J){var Z;if(!J)return new PY;if(J==="*")Z=function(){return!0};else if(this.isHTML)Z=LD(J);else Z=SY(J);return new lZ(this,Z)}},getElementsByTagNameNS:{value:function(J,Z){var Y;if(J==="*"&&Z==="*")Y=function(){return!0};else if(J==="*")Y=SY(Z);else if(Z==="*")Y=ND(J);else Y=yD(J,Z);return new lZ(this,Y)}},getElementsByClassName:{value:function(J){if(J=String(J).trim(),J===""){var Z=new PY;return Z}return J=J.split(/[ \t\r\n\f]+/),new lZ(this,TD(J))}},getElementsByName:{value:function(J){return new lZ(this,kD(String(J)))}},clone:{value:function(){var J;if(this.namespaceURI!==N1.HTML||this.prefix||!this.ownerDocument.isHTML)J=this.ownerDocument.createElementNS(this.namespaceURI,this.prefix!==null?this.prefix+":"+this.localName:this.localName);else J=this.ownerDocument.createElement(this.localName);for(var Z=0,Y=this._attrKeys.length;Z<Y;Z++){var K=this._attrKeys[Z],Q=this._attrsByLName[K],V=Q.cloneNode();V._setOwnerElement(J),J._attrsByLName[K]=V,J._addQName(V)}return J._attrKeys=this._attrKeys.concat(),J}},isEqual:{value:function(J){if(this.localName!==J.localName||this.namespaceURI!==J.namespaceURI||this.prefix!==J.prefix||this._numattrs!==J._numattrs)return!1;for(var Z=0,Y=this._numattrs;Z<Y;Z++){var K=this._attr(Z);if(!J.hasAttributeNS(K.namespaceURI,K.localName))return!1;if(J.getAttributeNS(K.namespaceURI,K.localName)!==K.value)return!1}return!0}},_lookupNamespacePrefix:{value:function(J,Z){if(this.namespaceURI&&this.namespaceURI===J&&this.prefix!==null&&Z.lookupNamespaceURI(this.prefix)===J)return this.prefix;for(var Y=0,K=this._numattrs;Y<K;Y++){var Q=this._attr(Y);if(Q.prefix==="xmlns"&&Q.value===J&&Z.lookupNamespaceURI(Q.localName)===J)return Q.localName}var V=this.parentElement;return V?V._lookupNamespacePrefix(J,Z):null}},lookupNamespaceURI:{value:function(J){if(J===""||J===void 0)J=null;if(this.namespaceURI!==null&&this.prefix===J)return this.namespaceURI;for(var Z=0,Y=this._numattrs;Z<Y;Z++){var K=this._attr(Z);if(K.namespaceURI===N1.XMLNS){if(K.prefix==="xmlns"&&K.localName===J||J===null&&K.prefix===null&&K.localName==="xmlns")return K.value||null}}var Q=this.parentElement;return Q?Q.lookupNamespaceURI(J):null}},getAttribute:{value:function(J){var Z=this.getAttributeNode(J);return Z?Z.value:null}},getAttributeNS:{value:function(J,Z){var Y=this.getAttributeNodeNS(J,Z);return Y?Y.value:null}},getAttributeNode:{value:function(J){if(J=String(J),/[A-Z]/.test(J)&&this.isHTML)J=Y0.toASCIILowerCase(J);var Z=this._attrsByQName[J];if(!Z)return null;if(Array.isArray(Z))Z=Z[0];return Z}},getAttributeNodeNS:{value:function(J,Z){J=J===void 0||J===null?"":String(J),Z=String(Z);var Y=this._attrsByLName[J+"|"+Z];return Y?Y:null}},hasAttribute:{value:function(J){if(J=String(J),/[A-Z]/.test(J)&&this.isHTML)J=Y0.toASCIILowerCase(J);return this._attrsByQName[J]!==void 0}},hasAttributeNS:{value:function(J,Z){J=J===void 0||J===null?"":String(J),Z=String(Z);var Y=J+"|"+Z;return this._attrsByLName[Y]!==void 0}},hasAttributes:{value:function(){return this._numattrs>0}},toggleAttribute:{value:function(J,Z){if(J=String(J),!DY.isValidName(J))Y0.InvalidCharacterError();if(/[A-Z]/.test(J)&&this.isHTML)J=Y0.toASCIILowerCase(J);var Y=this._attrsByQName[J];if(Y===void 0){if(Z===void 0||Z===!0)return this._setAttribute(J,""),!0;return!1}else{if(Z===void 0||Z===!1)return this.removeAttribute(J),!1;return!0}}},_setAttribute:{value:function(J,Z){var Y=this._attrsByQName[J],K;if(!Y)Y=this._newattr(J),K=!0;else if(Array.isArray(Y))Y=Y[0];if(Y.value=Z,this._attributes)this._attributes[J]=Y;if(K&&this._newattrhook)this._newattrhook(J,Z)}},setAttribute:{value:function(J,Z){if(J=String(J),!DY.isValidName(J))Y0.InvalidCharacterError();if(/[A-Z]/.test(J)&&this.isHTML)J=Y0.toASCIILowerCase(J);this._setAttribute(J,String(Z))}},_setAttributeNS:{value:function(J,Z,Y){var K=Z.indexOf(":"),Q,V;if(K<0)Q=null,V=Z;else Q=Z.substring(0,K),V=Z.substring(K+1);if(J===""||J===void 0)J=null;var X=(J===null?"":J)+"|"+V,W=this._attrsByLName[X],B;if(!W){if(W=new y8(this,V,Q,J),B=!0,this._attrsByLName[X]=W,this._attributes)this._attributes[this._attrKeys.length]=W;this._attrKeys.push(X),this._addQName(W)}if(W.value=Y,B&&this._newattrhook)this._newattrhook(Z,Y)}},setAttributeNS:{value:function(J,Z,Y){if(J=J===null||J===void 0||J===""?null:String(J),Z=String(Z),!DY.isValidQName(Z))Y0.InvalidCharacterError();var K=Z.indexOf(":"),Q=K<0?null:Z.substring(0,K);if(Q!==null&&J===null||Q==="xml"&&J!==N1.XML||(Z==="xmlns"||Q==="xmlns")&&J!==N1.XMLNS||J===N1.XMLNS&&!(Z==="xmlns"||Q==="xmlns"))Y0.NamespaceError();this._setAttributeNS(J,Z,String(Y))}},setAttributeNode:{value:function(J){if(J.ownerElement!==null&&J.ownerElement!==this)throw new hJ(hJ.INUSE_ATTRIBUTE_ERR);var Z=null,Y=this._attrsByQName[J.name];if(Y){if(!Array.isArray(Y))Y=[Y];if(Y.some(function(K){return K===J}))return J;else if(J.ownerElement!==null)throw new hJ(hJ.INUSE_ATTRIBUTE_ERR);Y.forEach(function(K){this.removeAttributeNode(K)},this),Z=Y[0]}return this.setAttributeNodeNS(J),Z}},setAttributeNodeNS:{value:function(J){if(J.ownerElement!==null)throw new hJ(hJ.INUSE_ATTRIBUTE_ERR);var Z=J.namespaceURI,Y=(Z===null?"":Z)+"|"+J.localName,K=this._attrsByLName[Y];if(K)this.removeAttributeNode(K);if(J._setOwnerElement(this),this._attrsByLName[Y]=J,this._attributes)this._attributes[this._attrKeys.length]=J;if(this._attrKeys.push(Y),this._addQName(J),this._newattrhook)this._newattrhook(J.name,J.value);return K||null}},removeAttribute:{value:function(J){if(J=String(J),/[A-Z]/.test(J)&&this.isHTML)J=Y0.toASCIILowerCase(J);var Z=this._attrsByQName[J];if(!Z)return;if(Array.isArray(Z))if(Z.length>2)Z=Z.shift();else this._attrsByQName[J]=Z[1],Z=Z[0];else this._attrsByQName[J]=void 0;var Y=Z.namespaceURI,K=(Y===null?"":Y)+"|"+Z.localName;this._attrsByLName[K]=void 0;var Q=this._attrKeys.indexOf(K);if(this._attributes)Array.prototype.splice.call(this._attributes,Q,1),this._attributes[J]=void 0;this._attrKeys.splice(Q,1);var V=Z.onchange;if(Z._setOwnerElement(null),V)V.call(Z,this,Z.localName,Z.value,null);if(this.rooted)this.ownerDocument.mutateRemoveAttr(Z)}},removeAttributeNS:{value:function(J,Z){J=J===void 0||J===null?"":String(J),Z=String(Z);var Y=J+"|"+Z,K=this._attrsByLName[Y];if(!K)return;this._attrsByLName[Y]=void 0;var Q=this._attrKeys.indexOf(Y);if(this._attributes)Array.prototype.splice.call(this._attributes,Q,1);this._attrKeys.splice(Q,1),this._removeQName(K);var V=K.onchange;if(K._setOwnerElement(null),V)V.call(K,this,K.localName,K.value,null);if(this.rooted)this.ownerDocument.mutateRemoveAttr(K)}},removeAttributeNode:{value:function(J){var Z=J.namespaceURI,Y=(Z===null?"":Z)+"|"+J.localName;if(this._attrsByLName[Y]!==J)Y0.NotFoundError();return this.removeAttributeNS(Z,J.localName),J}},getAttributeNames:{value:function(){var J=this;return this._attrKeys.map(function(Z){return J._attrsByLName[Z].name})}},_getattr:{value:function(J){var Z=this._attrsByQName[J];return Z?Z.value:null}},_setattr:{value:function(J,Z){var Y=this._attrsByQName[J],K;if(!Y)Y=this._newattr(J),K=!0;if(Y.value=String(Z),this._attributes)this._attributes[J]=Y;if(K&&this._newattrhook)this._newattrhook(J,Z)}},_newattr:{value:function(J){var Z=new y8(this,J,null,null),Y="|"+J;if(this._attrsByQName[J]=Z,this._attrsByLName[Y]=Z,this._attributes)this._attributes[this._attrKeys.length]=Z;return this._attrKeys.push(Y),Z}},_addQName:{value:function($){var J=$.name,Z=this._attrsByQName[J];if(!Z)this._attrsByQName[J]=$;else if(Array.isArray(Z))Z.push($);else this._attrsByQName[J]=[Z,$];if(this._attributes)this._attributes[J]=$}},_removeQName:{value:function($){var J=$.name,Z=this._attrsByQName[J];if(Array.isArray(Z)){var Y=Z.indexOf($);if(Y0.assert(Y!==-1),Z.length===2){if(this._attrsByQName[J]=Z[1-Y],this._attributes)this._attributes[J]=this._attrsByQName[J]}else if(Z.splice(Y,1),this._attributes&&this._attributes[J]===$)this._attributes[J]=Z[0]}else if(Y0.assert(Z===$),this._attrsByQName[J]=void 0,this._attributes)this._attributes[J]=void 0}},_numattrs:{get:function(){return this._attrKeys.length}},_attr:{value:function($){return this._attrsByLName[this._attrKeys[$]]}},id:oZ.property({name:"id"}),className:oZ.property({name:"class"}),classList:{get:function(){var $=this;if(this._classList)return this._classList;var J=new SD(function(){return $.className||""},function(Z){$.className=Z});return this._classList=J,J},set:function($){this.className=$}},matches:{value:function($){return IY.matches(this,$)}},closest:{value:function($){var J=this;do{if(J.matches&&J.matches($))return J;J=J.parentElement||J.parentNode}while(J!==null&&J.nodeType===q1.ELEMENT_NODE);return null}},querySelector:{value:function($){return IY($,this)[0]}},querySelectorAll:{value:function($){var J=IY($,this);return J.item?J:new PY(J)}}});Object.defineProperties(O2.prototype,wD);Object.defineProperties(O2.prototype,RD);oZ.registerChangeHandler(O2,"id",function($,J,Z,Y){if($.rooted){if(Z)$.ownerDocument.delId(Z,$);if(Y)$.ownerDocument.addId(Y,$)}});oZ.registerChangeHandler(O2,"class",function($,J,Z,Y){if($._classList)$._classList._update()});function y8($,J,Z,Y,K){this.localName=J,this.prefix=Z===null||Z===""?null:""+Z,this.namespaceURI=Y===null||Y===""?null:""+Y,this.data=K,this._setOwnerElement($)}y8.prototype=Object.create(Object.prototype,{ownerElement:{get:function(){return this._ownerElement}},_setOwnerElement:{value:function(J){if(this._ownerElement=J,this.prefix===null&&this.namespaceURI===null&&J)this.onchange=J._attributeChangeHandlers[this.localName];else this.onchange=null}},name:{get:function(){return this.prefix?this.prefix+":"+this.localName:this.localName}},specified:{get:function(){return!0}},value:{get:function(){return this.data},set:function($){var J=this.data;if($=$===void 0?"":$+"",$===J)return;if(this.data=$,this.ownerElement){if(this.onchange)this.onchange(this.ownerElement,this.localName,J,$);if(this.ownerElement.rooted)this.ownerElement.ownerDocument.mutateAttr(this,J)}}},cloneNode:{value:function(J){return new y8(null,this.localName,this.prefix,this.namespaceURI,this.data)}},nodeType:{get:function(){return q1.ATTRIBUTE_NODE}},nodeName:{get:function(){return this.name}},nodeValue:{get:function(){return this.value},set:function($){this.value=$}},textContent:{get:function(){return this.value},set:function($){if($===null||$===void 0)$="";this.value=$}},innerText:{get:function(){return this.value},set:function($){if($===null||$===void 0)$="";this.value=$}}});O2._Attr=y8;function wY($){aW.call(this,$);for(var J in $._attrsByQName)this[J]=$._attrsByQName[J];for(var Z=0;Z<$._attrKeys.length;Z++)this[Z]=$._attrsByLName[$._attrKeys[Z]]}wY.prototype=Object.create(aW.prototype,{length:{get:function(){return this.element._attrKeys.length},set:function(){}},item:{value:function($){if($=$>>>0,$>=this.length)return null;return this.element._attrsByLName[this.element._attrKeys[$]]}}});if(globalThis.Symbol?.iterator)wY.prototype[globalThis.Symbol.iterator]=function(){var $=0,J=this.length,Z=this;return{next:function(){if($<J)return{value:Z.item($++)};return{done:!0}}}};function tW($){this.element=$,this.updateCache()}tW.prototype=Object.create(Object.prototype,{length:{get:function(){return this.updateCache(),this.childrenByNumber.length}},item:{value:function(J){return this.updateCache(),this.childrenByNumber[J]||null}},namedItem:{value:function(J){return this.updateCache(),this.childrenByName[J]||null}},namedItems:{get:function(){return this.updateCache(),this.childrenByName}},updateCache:{value:function(){var J=/^(a|applet|area|embed|form|frame|frameset|iframe|img|object)$/;if(this.lastModTime!==this.element.lastModTime){this.lastModTime=this.element.lastModTime;var Z=this.childrenByNumber&&this.childrenByNumber.length||0;for(var Y=0;Y<Z;Y++)this[Y]=void 0;this.childrenByNumber=[],this.childrenByName=Object.create(null);for(var K=this.element.firstChild;K!==null;K=K.nextSibling)if(K.nodeType===q1.ELEMENT_NODE){this[this.childrenByNumber.length]=K,this.childrenByNumber.push(K);var Q=K.getAttribute("id");if(Q&&!this.childrenByName[Q])this.childrenByName[Q]=K;var V=K.getAttribute("name");if(V&&this.element.namespaceURI===N1.HTML&&J.test(this.element.localName)&&!this.childrenByName[V])this.childrenByName[Q]=K}}}}});function SY($){return function(J){return J.localName===$}}function LD($){var J=Y0.toASCIILowerCase($);if(J===$)return SY($);return function(Z){return Z.isHTML?Z.localName===J:Z.localName===$}}function ND($){return function(J){return J.namespaceURI===$}}function yD($,J){return function(Z){return Z.namespaceURI===$&&Z.localName===J}}function TD($){return function(J){return $.every(function(Z){return J.classList.contains(Z)})}}function kD($){return function(J){if(J.namespaceURI!==N1.HTML)return!1;return J.getAttribute("name")===$}}});var RY=p((Lb,K5)=>{K5.exports=Y5;var J5=P0(),ED=n2(),Z5=X0(),$5=Z5.HierarchyRequestError,xD=Z5.NotFoundError;function Y5(){J5.call(this)}Y5.prototype=Object.create(J5.prototype,{hasChildNodes:{value:function(){return!1}},firstChild:{value:null},lastChild:{value:null},insertBefore:{value:function($,J){if(!$.nodeType)throw TypeError("not a node");$5()}},replaceChild:{value:function($,J){if(!$.nodeType)throw TypeError("not a node");$5()}},removeChild:{value:function($){if(!$.nodeType)throw TypeError("not a node");xD()}},removeChildren:{value:function(){}},childNodes:{get:function(){if(!this._childNodes)this._childNodes=new ED;return this._childNodes}}})});var T8=p((Nb,G5)=>{G5.exports=rZ;var V5=RY(),Q5=X0(),bD=cZ(),vD=CY();function rZ(){V5.call(this)}rZ.prototype=Object.create(V5.prototype,{substringData:{value:function(J,Z){if(arguments.length<2)throw TypeError("Not enough arguments");if(J=J>>>0,Z=Z>>>0,J>this.data.length||J<0||Z<0)Q5.IndexSizeError();return this.data.substring(J,J+Z)}},appendData:{value:function(J){if(arguments.length<1)throw TypeError("Not enough arguments");this.data+=String(J)}},insertData:{value:function(J,Z){return this.replaceData(J,0,Z)}},deleteData:{value:function(J,Z){return this.replaceData(J,Z,"")}},replaceData:{value:function(J,Z,Y){var K=this.data,Q=K.length;if(J=J>>>0,Z=Z>>>0,Y=String(Y),J>Q||J<0)Q5.IndexSizeError();if(J+Z>Q)Z=Q-J;var V=K.substring(0,J),X=K.substring(J+Z);this.data=V+Y+X}},isEqual:{value:function(J){return this._data===J._data}},length:{get:function(){return this.data.length}}});Object.defineProperties(rZ.prototype,bD);Object.defineProperties(rZ.prototype,vD)});var NY=p((yb,U5)=>{U5.exports=LY;var X5=X0(),W5=P0(),j5=T8();function LY($,J){j5.call(this),this.nodeType=W5.TEXT_NODE,this.ownerDocument=$,this._data=J,this._index=void 0}var k8={get:function(){return this._data},set:function($){if($===null||$===void 0)$="";else $=String($);if($===this._data)return;if(this._data=$,this.rooted)this.ownerDocument.mutateValue(this);if(this.parentNode&&this.parentNode._textchangehook)this.parentNode._textchangehook(this)}};LY.prototype=Object.create(j5.prototype,{nodeName:{value:"#text"},nodeValue:k8,textContent:k8,innerText:k8,data:{get:k8.get,set:function($){k8.set.call(this,$===null?"":String($))}},splitText:{value:function(J){if(J>this._data.length||J<0)X5.IndexSizeError();var Z=this._data.substring(J),Y=this.ownerDocument.createTextNode(Z);this.data=this.data.substring(0,J);var K=this.parentNode;if(K!==null)K.insertBefore(Y,this.nextSibling);return Y}},wholeText:{get:function(){var J=this.textContent;for(var Z=this.nextSibling;Z;Z=Z.nextSibling){if(Z.nodeType!==W5.TEXT_NODE)break;J+=Z.textContent}return J}},replaceWholeText:{value:X5.nyi},clone:{value:function(){return new LY(this.ownerDocument,this._data)}}})});var TY=p((Tb,B5)=>{B5.exports=yY;var hD=P0(),H5=T8();function yY($,J){H5.call(this),this.nodeType=hD.COMMENT_NODE,this.ownerDocument=$,this._data=J}var E8={get:function(){return this._data},set:function($){if($===null||$===void 0)$="";else $=String($);if(this._data=$,this.rooted)this.ownerDocument.mutateValue(this)}};yY.prototype=Object.create(H5.prototype,{nodeName:{value:"#comment"},nodeValue:E8,textContent:E8,innerText:E8,data:{get:E8.get,set:function($){E8.set.call(this,$===null?"":String($))}},clone:{value:function(){return new yY(this.ownerDocument,this._data)}}})});var EY=p((kb,q5)=>{q5.exports=kY;var gD=P0(),fD=n2(),O5=gZ(),iZ=gJ(),mD=pZ(),_5=X0();function kY($){O5.call(this),this.nodeType=gD.DOCUMENT_FRAGMENT_NODE,this.ownerDocument=$}kY.prototype=Object.create(O5.prototype,{nodeName:{value:"#document-fragment"},nodeValue:{get:function(){return null},set:function(){}},textContent:Object.getOwnPropertyDescriptor(iZ.prototype,"textContent"),innerText:Object.getOwnPropertyDescriptor(iZ.prototype,"innerText"),querySelector:{value:function($){var J=this.querySelectorAll($);return J.length?J[0]:null}},querySelectorAll:{value:function($){var J=Object.create(this);J.isHTML=!0,J.getElementsByTagName=iZ.prototype.getElementsByTagName,J.nextElement=Object.getOwnPropertyDescriptor(iZ.prototype,"firstElementChild").get;var Z=mD($,J);return Z.item?Z:new fD(Z)}},clone:{value:function(){return new kY(this.ownerDocument)}},isEqual:{value:function(J){return!0}},innerHTML:{get:function(){return this.serialize()},set:_5.nyi},outerHTML:{get:function(){return this.serialize()},set:_5.nyi}})});var bY=p((Eb,z5)=>{z5.exports=xY;var uD=P0(),F5=T8();function xY($,J,Z){F5.call(this),this.nodeType=uD.PROCESSING_INSTRUCTION_NODE,this.ownerDocument=$,this.target=J,this._data=Z}var x8={get:function(){return this._data},set:function($){if($===null||$===void 0)$="";else $=String($);if(this._data=$,this.rooted)this.ownerDocument.mutateValue(this)}};xY.prototype=Object.create(F5.prototype,{nodeName:{get:function(){return this.target}},nodeValue:x8,textContent:x8,innerText:x8,data:{get:x8.get,set:function($){x8.set.call(this,$===null?"":String($))}},clone:{value:function(){return new xY(this.ownerDocument,this.target,this._data)}},isEqual:{value:function(J){return this.target===J.target&&this._data===J._data}}})});var b8=p((xb,C5)=>{var vY={FILTER_ACCEPT:1,FILTER_REJECT:2,FILTER_SKIP:3,SHOW_ALL:4294967295,SHOW_ELEMENT:1,SHOW_ATTRIBUTE:2,SHOW_TEXT:4,SHOW_CDATA_SECTION:8,SHOW_ENTITY_REFERENCE:16,SHOW_ENTITY:32,SHOW_PROCESSING_INSTRUCTION:64,SHOW_COMMENT:128,SHOW_DOCUMENT:256,SHOW_DOCUMENT_TYPE:512,SHOW_DOCUMENT_FRAGMENT:1024,SHOW_NOTATION:2048};C5.exports=vY.constructor=vY.prototype=vY});var gY=p((vb,D5)=>{var bb=D5.exports={nextSkippingChildren:dD,nextAncestorSibling:hY,next:pD,previous:cD,deepLastChild:M5};function dD($,J){if($===J)return null;if($.nextSibling!==null)return $.nextSibling;return hY($,J)}function hY($,J){for($=$.parentNode;$!==null;$=$.parentNode){if($===J)return null;if($.nextSibling!==null)return $.nextSibling}return null}function pD($,J){var Z=$.firstChild;if(Z!==null)return Z;if($===J)return null;if(Z=$.nextSibling,Z!==null)return Z;return hY($,J)}function M5($){while($.lastChild)$=$.lastChild;return $}function cD($,J){var Z=$.previousSibling;if(Z!==null)return M5(Z);if(Z=$.parentNode,Z===J)return null;return Z}});var L5=p((hb,R5)=>{R5.exports=w5;var lD=P0(),I0=b8(),P5=gY(),S5=X0(),fY={first:"firstChild",last:"lastChild",next:"firstChild",previous:"lastChild"},mY={first:"nextSibling",last:"previousSibling",next:"nextSibling",previous:"previousSibling"};function I5($,J){var Z,Y,K,Q,V;Y=$._currentNode[fY[J]];while(Y!==null){if(Q=$._internalFilter(Y),Q===I0.FILTER_ACCEPT)return $._currentNode=Y,Y;if(Q===I0.FILTER_SKIP){if(Z=Y[fY[J]],Z!==null){Y=Z;continue}}while(Y!==null){if(V=Y[mY[J]],V!==null){Y=V;break}if(K=Y.parentNode,K===null||K===$.root||K===$._currentNode)return null;else Y=K}}return null}function A5($,J){var Z,Y,K;if(Z=$._currentNode,Z===$.root)return null;while(!0){K=Z[mY[J]];while(K!==null){if(Z=K,Y=$._internalFilter(Z),Y===I0.FILTER_ACCEPT)return $._currentNode=Z,Z;if(K=Z[fY[J]],Y===I0.FILTER_REJECT||K===null)K=Z[mY[J]]}if(Z=Z.parentNode,Z===null||Z===$.root)return null;if($._internalFilter(Z)===I0.FILTER_ACCEPT)return null}}function w5($,J,Z){if(!$||!$.nodeType)S5.NotSupportedError();this._root=$,this._whatToShow=Number(J)||0,this._filter=Z||null,this._active=!1,this._currentNode=$}Object.defineProperties(w5.prototype,{root:{get:function(){return this._root}},whatToShow:{get:function(){return this._whatToShow}},filter:{get:function(){return this._filter}},currentNode:{get:function(){return this._currentNode},set:function(J){if(!(J instanceof lD))throw TypeError("Not a Node");this._currentNode=J}},_internalFilter:{value:function(J){var Z,Y;if(this._active)S5.InvalidStateError();if(!(1<<J.nodeType-1&this._whatToShow))return I0.FILTER_SKIP;if(Y=this._filter,Y===null)Z=I0.FILTER_ACCEPT;else{this._active=!0;try{if(typeof Y==="function")Z=Y(J);else Z=Y.acceptNode(J)}finally{this._active=!1}}return+Z}},parentNode:{value:function(){var J=this._currentNode;while(J!==this.root){if(J=J.parentNode,J===null)return null;if(this._internalFilter(J)===I0.FILTER_ACCEPT)return this._currentNode=J,J}return null}},firstChild:{value:function(){return I5(this,"first")}},lastChild:{value:function(){return I5(this,"last")}},previousSibling:{value:function(){return A5(this,"previous")}},nextSibling:{value:function(){return A5(this,"next")}},previousNode:{value:function(){var J,Z,Y,K;J=this._currentNode;while(J!==this._root){for(Y=J.previousSibling;Y;Y=J.previousSibling){if(J=Y,Z=this._internalFilter(J),Z===I0.FILTER_REJECT)continue;for(K=J.lastChild;K;K=J.lastChild)if(J=K,Z=this._internalFilter(J),Z===I0.FILTER_REJECT)break;if(Z===I0.FILTER_ACCEPT)return this._currentNode=J,J}if(J===this.root||J.parentNode===null)return null;if(J=J.parentNode,this._internalFilter(J)===I0.FILTER_ACCEPT)return this._currentNode=J,J}return null}},nextNode:{value:function(){var J,Z,Y,K;J=this._currentNode,Z=I0.FILTER_ACCEPT;$:while(!0){for(Y=J.firstChild;Y;Y=J.firstChild)if(J=Y,Z=this._internalFilter(J),Z===I0.FILTER_ACCEPT)return this._currentNode=J,J;else if(Z===I0.FILTER_REJECT)break;for(K=P5.nextSkippingChildren(J,this.root);K;K=P5.nextSkippingChildren(J,this.root))if(J=K,Z=this._internalFilter(J),Z===I0.FILTER_ACCEPT)return this._currentNode=J,J;else if(Z===I0.FILTER_SKIP)continue $;return null}}},toString:{value:function(){return"[object TreeWalker]"}}})});var x5=p((gb,E5)=>{E5.exports=k5;var uY=b8(),dY=gY(),T5=X0();function oD($,J,Z){if(Z)return dY.next($,J);else{if($===J)return null;return dY.previous($,null)}}function N5($,J){for(;J;J=J.parentNode)if($===J)return!0;return!1}function y5($,J){var Z,Y;Z=$._referenceNode,Y=$._pointerBeforeReferenceNode;while(!0){if(Y===J)Y=!Y;else if(Z=oD(Z,$._root,J),Z===null)return null;var K=$._internalFilter(Z);if(K===uY.FILTER_ACCEPT)break}return $._referenceNode=Z,$._pointerBeforeReferenceNode=Y,Z}function k5($,J,Z){if(!$||!$.nodeType)T5.NotSupportedError();this._root=$,this._referenceNode=$,this._pointerBeforeReferenceNode=!0,this._whatToShow=Number(J)||0,this._filter=Z||null,this._active=!1,$.doc._attachNodeIterator(this)}Object.defineProperties(k5.prototype,{root:{get:function(){return this._root}},referenceNode:{get:function(){return this._referenceNode}},pointerBeforeReferenceNode:{get:function(){return this._pointerBeforeReferenceNode}},whatToShow:{get:function(){return this._whatToShow}},filter:{get:function(){return this._filter}},_internalFilter:{value:function(J){var Z,Y;if(this._active)T5.InvalidStateError();if(!(1<<J.nodeType-1&this._whatToShow))return uY.FILTER_SKIP;if(Y=this._filter,Y===null)Z=uY.FILTER_ACCEPT;else{this._active=!0;try{if(typeof Y==="function")Z=Y(J);else Z=Y.acceptNode(J)}finally{this._active=!1}}return+Z}},_preremove:{value:function(J){if(N5(J,this._root))return;if(!N5(J,this._referenceNode))return;if(this._pointerBeforeReferenceNode){var Z=J;while(Z.lastChild)Z=Z.lastChild;if(Z=dY.next(Z,this.root),Z){this._referenceNode=Z;return}this._pointerBeforeReferenceNode=!1}if(J.previousSibling===null)this._referenceNode=J.parentNode;else{this._referenceNode=J.previousSibling;var Y;for(Y=this._referenceNode.lastChild;Y;Y=this._referenceNode.lastChild)this._referenceNode=Y}}},nextNode:{value:function(){return y5(this,!0)}},previousNode:{value:function(){return y5(this,!1)}},detach:{value:function(){}},toString:{value:function(){return"[object NodeIterator]"}}})});var sZ=p((fb,b5)=>{b5.exports=A0;function A0($){if(!$)return Object.create(A0.prototype);this.url=$.replace(/^[ \t\n\r\f]+|[ \t\n\r\f]+$/g,"");var J=A0.pattern.exec(this.url);if(J){if(J[2])this.scheme=J[2];if(J[4]){var Z=J[4].match(A0.userinfoPattern);if(Z)this.username=Z[1],this.password=Z[3],J[4]=J[4].substring(Z[0].length);if(J[4].match(A0.portPattern)){var Y=J[4].lastIndexOf(":");this.host=J[4].substring(0,Y),this.port=J[4].substring(Y+1)}else this.host=J[4]}if(J[5])this.path=J[5];if(J[6])this.query=J[7];if(J[8])this.fragment=J[9]}}A0.pattern=/^(([^:\/?#]+):)?(\/\/([^\/?#]*))?([^?#]*)(\?([^#]*))?(#(.*))?$/;A0.userinfoPattern=/^([^@:]*)(:([^@]*))?@/;A0.portPattern=/:\d+$/;A0.authorityPattern=/^[^:\/?#]+:\/\//;A0.hierarchyPattern=/^[^:\/?#]+:\//;A0.percentEncode=function(J){var Z=J.charCodeAt(0);if(Z<256)return"%"+Z.toString(16);else throw Error("can't percent-encode codepoints > 255 yet")};A0.prototype={constructor:A0,isAbsolute:function(){return!!this.scheme},isAuthorityBased:function(){return A0.authorityPattern.test(this.url)},isHierarchical:function(){return A0.hierarchyPattern.test(this.url)},toString:function(){var $="";if(this.scheme!==void 0)$+=this.scheme+":";if(this.isAbsolute()){if($+="//",this.username||this.password){if($+=this.username||"",this.password)$+=":"+this.password;$+="@"}if(this.host)$+=this.host}if(this.port!==void 0)$+=":"+this.port;if(this.path!==void 0)$+=this.path;if(this.query!==void 0)$+="?"+this.query;if(this.fragment!==void 0)$+="#"+this.fragment;return $},resolve:function($){var J=this,Z=new A0($),Y=new A0;if(Z.scheme!==void 0)Y.scheme=Z.scheme,Y.username=Z.username,Y.password=Z.password,Y.host=Z.host,Y.port=Z.port,Y.path=Q(Z.path),Y.query=Z.query;else if(Y.scheme=J.scheme,Z.host!==void 0)Y.username=Z.username,Y.password=Z.password,Y.host=Z.host,Y.port=Z.port,Y.path=Q(Z.path),Y.query=Z.query;else if(Y.username=J.username,Y.password=J.password,Y.host=J.host,Y.port=J.port,!Z.path)if(Y.path=J.path,Z.query!==void 0)Y.query=Z.query;else Y.query=J.query;else{if(Z.path.charAt(0)==="/")Y.path=Q(Z.path);else Y.path=K(J.path,Z.path),Y.path=Q(Y.path);Y.query=Z.query}return Y.fragment=Z.fragment,Y.toString();function K(V,X){if(J.host!==void 0&&!J.path)return"/"+X;var W=V.lastIndexOf("/");if(W===-1)return X;else return V.substring(0,W+1)+X}function Q(V){if(!V)return V;var X="";while(V.length>0){if(V==="."||V===".."){V="";break}var W=V.substring(0,2),B=V.substring(0,3),j=V.substring(0,4);if(B==="../")V=V.substring(3);else if(W==="./")V=V.substring(2);else if(B==="/./")V="/"+V.substring(3);else if(W==="/."&&V.length===2)V="/";else if(j==="/../"||B==="/.."&&V.length===3)V="/"+V.substring(4),X=X.replace(/\/?[^\/]*$/,"");else{var _=V.match(/(\/?([^\/]*))/)[0];X+=_,V=V.substring(_.length)}}return X}}}});var g5=p((mb,h5)=>{h5.exports=pY;var v5=TJ();function pY($,J){v5.call(this,$,J)}pY.prototype=Object.create(v5.prototype,{constructor:{value:pY}})});var cY=p((ub,f5)=>{f5.exports={Event:TJ(),UIEvent:s7(),MouseEvent:a7(),CustomEvent:g5()}});var p5=p((u5)=>{Object.defineProperty(u5,"__esModule",{value:!0});u5.hyphenate=u5.parse=void 0;function rD($){let J=[],Z=0,Y=0,K=0,Q=0,V=0,X=null;while(Z<$.length)switch($.charCodeAt(Z++)){case 40:Y++;break;case 41:Y--;break;case 39:if(K===0)K=39;else if(K===39&&$.charCodeAt(Z-1)!==92)K=0;break;case 34:if(K===0)K=34;else if(K===34&&$.charCodeAt(Z-1)!==92)K=0;break;case 58:if(!X&&Y===0&&K===0)X=m5($.substring(V,Z-1).trim()),Q=Z;break;case 59:if(X&&Q>0&&Y===0&&K===0){let B=$.substring(Q,Z-1).trim();J.push(X,B),V=Z,Q=0,X=null}break}if(X&&Q){let W=$.slice(Q).trim();J.push(X,W)}return J}u5.parse=rD;function m5($){return $.replace(/[a-z][A-Z]/g,(J)=>{return J.charAt(0)+"-"+J.charAt(1)}).toLowerCase()}u5.hyphenate=m5});var nZ=p((pb,i5)=>{var{parse:sD}=p5();i5.exports=function($){let J=new r5($);return new Proxy(J,{get:function(Y,K){return K in Y?Y[K]:Y.getPropertyValue(c5(K))},has:function(Y,K){return!0},set:function(Y,K,Q){if(K in Y)Y[K]=Q;else Y.setProperty(c5(K),Q??void 0);return!0}})};function c5($){return $.replace(/([a-z])([A-Z])/g,"$1-$2").toLowerCase()}function r5($){this._element=$}var l5="!important";function o5($){let J={property:{},priority:{}};if(!$)return J;let Z=sD($);if(Z.length<2)return J;for(let Y=0;Y<Z.length;Y+=2){let K=Z[Y],Q=Z[Y+1];if(Q.endsWith(l5))J.priority[K]="important",Q=Q.slice(0,-l5.length).trim();J.property[K]=Q}return J}var fJ={};r5.prototype=Object.create(Object.prototype,{_parsed:{get:function(){if(!this._parsedStyles||this.cssText!==this._lastParsedText){var $=this.cssText;this._parsedStyles=o5($),this._lastParsedText=$,delete this._names}return this._parsedStyles}},_serialize:{value:function(){var $=this._parsed,J="";for(var Z in $.property){if(J)J+=" ";if(J+=Z+": "+$.property[Z],$.priority[Z])J+=" !"+$.priority[Z];J+=";"}this.cssText=J,this._lastParsedText=J,delete this._names}},cssText:{get:function(){return this._element.getAttribute("style")},set:function($){this._element.setAttribute("style",$)}},length:{get:function(){if(!this._names)this._names=Object.getOwnPropertyNames(this._parsed.property);return this._names.length}},item:{value:function($){if(!this._names)this._names=Object.getOwnPropertyNames(this._parsed.property);return this._names[$]}},getPropertyValue:{value:function($){return $=$.toLowerCase(),this._parsed.property[$]||""}},getPropertyPriority:{value:function($){return $=$.toLowerCase(),this._parsed.priority[$]||""}},setProperty:{value:function($,J,Z){if($=$.toLowerCase(),J===null||J===void 0)J="";if(Z===null||Z===void 0)Z="";if(J!==fJ)J=""+J;if(J=J.trim(),J===""){this.removeProperty($);return}if(Z!==""&&Z!==fJ&&!/^important$/i.test(Z))return;var Y=this._parsed;if(J===fJ){if(!Y.property[$])return;if(Z!=="")Y.priority[$]="important";else delete Y.priority[$]}else{if(J.indexOf(";")!==-1)return;var K=o5($+":"+J);if(Object.getOwnPropertyNames(K.property).length===0)return;if(Object.getOwnPropertyNames(K.priority).length!==0)return;for(var Q in K.property)if(Y.property[Q]=K.property[Q],Z===fJ)continue;else if(Z!=="")Y.priority[Q]="important";else if(Y.priority[Q])delete Y.priority[Q]}this._serialize()}},setPropertyValue:{value:function($,J){return this.setProperty($,J,fJ)}},setPropertyPriority:{value:function($,J){return this.setProperty($,fJ,J)}},removeProperty:{value:function($){$=$.toLowerCase();var J=this._parsed;if($ in J.property)delete J.property[$],delete J.priority[$],this._serialize()}}})});var lY=p((cb,s5)=>{var C0=sZ();s5.exports=v8;function v8(){}v8.prototype=Object.create(Object.prototype,{_url:{get:function(){return new C0(this.href)}},protocol:{get:function(){var $=this._url;if($&&$.scheme)return $.scheme+":";else return":"},set:function($){var J=this.href,Z=new C0(J);if(Z.isAbsolute()){if($=$.replace(/:+$/,""),$=$.replace(/[^-+\.a-zA-Z0-9]/g,C0.percentEncode),$.length>0)Z.scheme=$,J=Z.toString()}this.href=J}},host:{get:function(){var $=this._url;if($.isAbsolute()&&$.isAuthorityBased())return $.host+($.port?":"+$.port:"");else return""},set:function($){var J=this.href,Z=new C0(J);if(Z.isAbsolute()&&Z.isAuthorityBased()){if($=$.replace(/[^-+\._~!$&'()*,;:=a-zA-Z0-9]/g,C0.percentEncode),$.length>0)Z.host=$,delete Z.port,J=Z.toString()}this.href=J}},hostname:{get:function(){var $=this._url;if($.isAbsolute()&&$.isAuthorityBased())return $.host;else return""},set:function($){var J=this.href,Z=new C0(J);if(Z.isAbsolute()&&Z.isAuthorityBased()){if($=$.replace(/^\/+/,""),$=$.replace(/[^-+\._~!$&'()*,;:=a-zA-Z0-9]/g,C0.percentEncode),$.length>0)Z.host=$,J=Z.toString()}this.href=J}},port:{get:function(){var $=this._url;if($.isAbsolute()&&$.isAuthorityBased()&&$.port!==void 0)return $.port;else return""},set:function($){var J=this.href,Z=new C0(J);if(Z.isAbsolute()&&Z.isAuthorityBased()){if($=""+$,$=$.replace(/[^0-9].*$/,""),$=$.replace(/^0+/,""),$.length===0)$="0";if(parseInt($,10)<=65535)Z.port=$,J=Z.toString()}this.href=J}},pathname:{get:function(){var $=this._url;if($.isAbsolute()&&$.isHierarchical())return $.path;else return""},set:function($){var J=this.href,Z=new C0(J);if(Z.isAbsolute()&&Z.isHierarchical()){if($.charAt(0)!=="/")$="/"+$;$=$.replace(/[^-+\._~!$&'()*,;:=@\/a-zA-Z0-9]/g,C0.percentEncode),Z.path=$,J=Z.toString()}this.href=J}},search:{get:function(){var $=this._url;if($.isAbsolute()&&$.isHierarchical()&&$.query!==void 0)return"?"+$.query;else return""},set:function($){var J=this.href,Z=new C0(J);if(Z.isAbsolute()&&Z.isHierarchical()){if($.charAt(0)==="?")$=$.substring(1);$=$.replace(/[^-+\._~!$&'()*,;:=@\/?a-zA-Z0-9]/g,C0.percentEncode),Z.query=$,J=Z.toString()}this.href=J}},hash:{get:function(){var $=this._url;if($==null||$.fragment==null||$.fragment==="")return"";else return"#"+$.fragment},set:function($){var J=this.href,Z=new C0(J);if($.charAt(0)==="#")$=$.substring(1);$=$.replace(/[^-+\._~!$&'()*,;:=@\/?a-zA-Z0-9]/g,C0.percentEncode),Z.fragment=$,J=Z.toString(),this.href=J}},username:{get:function(){var $=this._url;return $.username||""},set:function($){var J=this.href,Z=new C0(J);if(Z.isAbsolute())$=$.replace(/[\x00-\x1F\x7F-\uFFFF "#<>?`\/@\\:]/g,C0.percentEncode),Z.username=$,J=Z.toString();this.href=J}},password:{get:function(){var $=this._url;return $.password||""},set:function($){var J=this.href,Z=new C0(J);if(Z.isAbsolute()){if($==="")Z.password=null;else $=$.replace(/[\x00-\x1F\x7F-\uFFFF "#<>?`\/@\\]/g,C0.percentEncode),Z.password=$;J=Z.toString()}this.href=J}},origin:{get:function(){var $=this._url;if($==null)return"";var J=function(Z){var Y=[$.scheme,$.host,+$.port||Z];return Y[0]+"://"+Y[1]+(Y[2]===Z?"":":"+Y[2])};switch($.scheme){case"ftp":return J(21);case"gopher":return J(70);case"http":case"ws":return J(80);case"https":case"wss":return J(443);default:return $.scheme+"://"}}}});v8._inherit=function($){Object.getOwnPropertyNames(v8.prototype).forEach(function(J){if(J==="constructor"||J==="href")return;var Z=Object.getOwnPropertyDescriptor(v8.prototype,J);Object.defineProperty($,J,Z)})}});var oY=p((lb,t5)=>{var n5=HY(),nD=bZ().isApiWritable;t5.exports=function($,J,Z,Y){var K=$.ctor;if(K){var Q=$.props||{};if($.attributes)for(var V in $.attributes){var X=$.attributes[V];if(typeof X!=="object"||Array.isArray(X))X={type:X};if(!X.name)X.name=V.toLowerCase();Q[V]=n5.property(X)}if(Q.constructor={value:K,writable:nD},K.prototype=Object.create(($.superclass||J).prototype,Q),$.events)tD(K,$.events);Z[$.name]=K}else K=J;return($.tags||$.tag&&[$.tag]||[]).forEach(function(W){Y[W]=K}),K};function a5($,J,Z,Y){this.body=$,this.document=J,this.form=Z,this.element=Y}a5.prototype.build=function(){return()=>{}};function aD($,J,Z,Y){var K=$.ownerDocument||Object.create(null),Q=$.form||Object.create(null);$[J]=new a5(Y,K,Q,$).build()}function tD($,J){var Z=$.prototype;J.forEach(function(Y){Object.defineProperty(Z,"on"+Y,{get:function(){return this._getEventHandler(Y)},set:function(K){this._setEventHandler(Y,K)}}),n5.registerChangeHandler($,"on"+Y,aD)})}});var tZ=p((YP)=>{var rY=P0(),e5=gJ(),eD=nZ(),c0=X0(),$j=lY(),$P=oY(),i1=YP.elements={},h8=Object.create(null);YP.createElement=function($,J,Z){var Y=h8[J]||ZP;return new Y($,J,Z)};function o($){return $P($,K$,i1,h8)}function W0($){return{get:function(){var J=this._getattr($);if(J===null)return"";var Z=this.doc._resolve(J);return Z===null?J:Z},set:function(J){this._setattr($,J)}}}function aZ($){return{get:function(){var J=this._getattr($);if(J===null)return null;if(J.toLowerCase()==="use-credentials")return"use-credentials";return"anonymous"},set:function(J){if(J===null||J===void 0)this.removeAttribute($);else this._setattr($,J)}}}var mJ={type:["","no-referrer","no-referrer-when-downgrade","same-origin","origin","strict-origin","origin-when-cross-origin","strict-origin-when-cross-origin","unsafe-url"],missing:""},JP={A:!0,LINK:!0,BUTTON:!0,INPUT:!0,SELECT:!0,TEXTAREA:!0,COMMAND:!0},F1=function($,J,Z){K$.call(this,$,J,Z),this._form=null},K$=YP.HTMLElement=o({superclass:e5,name:"HTMLElement",ctor:function(J,Z,Y){e5.call(this,J,Z,c0.NAMESPACE.HTML,Y)},props:{dangerouslySetInnerHTML:{set:function($){this._innerHTML=$}},innerHTML:{get:function(){return this.serialize()},set:function($){var J=this.ownerDocument.implementation.mozHTMLParser(this.ownerDocument._address,this);J.parse($===null?"":String($),!0);var Z=this instanceof h8.template?this.content:this;while(Z.hasChildNodes())Z.removeChild(Z.firstChild);Z.appendChild(J._asDocumentFragment())}},style:{get:function(){if(!this._style)this._style=new eD(this);return this._style},set:function($){if($===null||$===void 0)$="";this._setattr("style",String($))}},blur:{value:function(){}},focus:{value:function(){}},forceSpellCheck:{value:function(){}},click:{value:function(){if(this._click_in_progress)return;this._click_in_progress=!0;try{if(this._pre_click_activation_steps)this._pre_click_activation_steps();var $=this.ownerDocument.createEvent("MouseEvent");$.initMouseEvent("click",!0,!0,this.ownerDocument.defaultView,1,0,0,0,0,!1,!1,!1,!1,0,null);var J=this.dispatchEvent($);if(J){if(this._post_click_activation_steps)this._post_click_activation_steps($)}else if(this._cancelled_activation_steps)this._cancelled_activation_steps()}finally{this._click_in_progress=!1}}},submit:{value:c0.nyi}},attributes:{title:String,lang:String,dir:{type:["ltr","rtl","auto"],missing:""},draggable:{type:["true","false"],treatNullAsEmptyString:!0},spellcheck:{type:["true","false"],missing:""},enterKeyHint:{type:["enter","done","go","next","previous","search","send"],missing:""},autoCapitalize:{type:["off","on","none","sentences","words","characters"],missing:""},autoFocus:Boolean,accessKey:String,nonce:String,hidden:Boolean,translate:{type:["no","yes"],missing:""},tabIndex:{type:"long",default:function(){if(this.tagName in JP||this.contentEditable)return 0;else return-1}}},events:["abort","canplay","canplaythrough","change","click","contextmenu","cuechange","dblclick","drag","dragend","dragenter","dragleave","dragover","dragstart","drop","durationchange","emptied","ended","input","invalid","keydown","keypress","keyup","loadeddata","loadedmetadata","loadstart","mousedown","mousemove","mouseout","mouseover","mouseup","mousewheel","pause","play","playing","progress","ratechange","readystatechange","reset","seeked","seeking","select","show","stalled","submit","suspend","timeupdate","volumechange","waiting","blur","error","focus","load","scroll"]}),ZP=o({name:"HTMLUnknownElement",ctor:function(J,Z,Y){K$.call(this,J,Z,Y)}}),z1={form:{get:function(){return this._form}}};o({tag:"a",name:"HTMLAnchorElement",ctor:function(J,Z,Y){K$.call(this,J,Z,Y)},props:{_post_click_activation_steps:{value:function($){if(this.href)this.ownerDocument.defaultView.location=this.href}}},attributes:{href:W0,ping:String,download:String,target:String,rel:String,media:String,hreflang:String,type:String,referrerPolicy:mJ,coords:String,charset:String,name:String,rev:String,shape:String}});$j._inherit(h8.a.prototype);o({tag:"area",name:"HTMLAreaElement",ctor:function(J,Z,Y){K$.call(this,J,Z,Y)},attributes:{alt:String,target:String,download:String,rel:String,media:String,href:W0,hreflang:String,type:String,shape:String,coords:String,ping:String,referrerPolicy:mJ,noHref:Boolean}});$j._inherit(h8.area.prototype);o({tag:"br",name:"HTMLBRElement",ctor:function(J,Z,Y){K$.call(this,J,Z,Y)},attributes:{clear:String}});o({tag:"base",name:"HTMLBaseElement",ctor:function(J,Z,Y){K$.call(this,J,Z,Y)},attributes:{target:String}});o({tag:"body",name:"HTMLBodyElement",ctor:function(J,Z,Y){K$.call(this,J,Z,Y)},events:["afterprint","beforeprint","beforeunload","blur","error","focus","hashchange","load","message","offline","online","pagehide","pageshow","popstate","resize","scroll","storage","unload"],attributes:{text:{type:String,treatNullAsEmptyString:!0},link:{type:String,treatNullAsEmptyString:!0},vLink:{type:String,treatNullAsEmptyString:!0},aLink:{type:String,treatNullAsEmptyString:!0},bgColor:{type:String,treatNullAsEmptyString:!0},background:String}});o({tag:"button",name:"HTMLButtonElement",ctor:function(J,Z,Y){F1.call(this,J,Z,Y)},props:z1,attributes:{name:String,value:String,disabled:Boolean,autofocus:Boolean,type:{type:["submit","reset","button","menu"],missing:"submit"},formTarget:String,formAction:W0,formNoValidate:Boolean,formMethod:{type:["get","post","dialog"],invalid:"get",missing:""},formEnctype:{type:["application/x-www-form-urlencoded","multipart/form-data","text/plain"],invalid:"application/x-www-form-urlencoded",missing:""}}});o({tag:"dl",name:"HTMLDListElement",ctor:function(J,Z,Y){K$.call(this,J,Z,Y)},attributes:{compact:Boolean}});o({tag:"data",name:"HTMLDataElement",ctor:function(J,Z,Y){K$.call(this,J,Z,Y)},attributes:{value:String}});o({tag:"datalist",name:"HTMLDataListElement",ctor:function(J,Z,Y){K$.call(this,J,Z,Y)}});o({tag:"details",name:"HTMLDetailsElement",ctor:function(J,Z,Y){K$.call(this,J,Z,Y)},attributes:{open:Boolean}});o({tag:"div",name:"HTMLDivElement",ctor:function(J,Z,Y){K$.call(this,J,Z,Y)},attributes:{align:String}});o({tag:"embed",name:"HTMLEmbedElement",ctor:function(J,Z,Y){K$.call(this,J,Z,Y)},attributes:{src:W0,type:String,width:String,height:String,align:String,name:String}});o({tag:"fieldset",name:"HTMLFieldSetElement",ctor:function(J,Z,Y){F1.call(this,J,Z,Y)},props:z1,attributes:{disabled:Boolean,name:String}});o({tag:"form",name:"HTMLFormElement",ctor:function(J,Z,Y){K$.call(this,J,Z,Y)},attributes:{action:String,autocomplete:{type:["on","off"],missing:"on"},name:String,acceptCharset:{name:"accept-charset"},target:String,noValidate:Boolean,method:{type:["get","post","dialog"],invalid:"get",missing:"get"},enctype:{type:["application/x-www-form-urlencoded","multipart/form-data","text/plain"],invalid:"application/x-www-form-urlencoded",missing:"application/x-www-form-urlencoded"},encoding:{name:"enctype",type:["application/x-www-form-urlencoded","multipart/form-data","text/plain"],invalid:"application/x-www-form-urlencoded",missing:"application/x-www-form-urlencoded"}}});o({tag:"hr",name:"HTMLHRElement",ctor:function(J,Z,Y){K$.call(this,J,Z,Y)},attributes:{align:String,color:String,noShade:Boolean,size:String,width:String}});o({tag:"head",name:"HTMLHeadElement",ctor:function(J,Z,Y){K$.call(this,J,Z,Y)}});o({tags:["h1","h2","h3","h4","h5","h6"],name:"HTMLHeadingElement",ctor:function(J,Z,Y){K$.call(this,J,Z,Y)},attributes:{align:String}});o({tag:"html",name:"HTMLHtmlElement",ctor:function(J,Z,Y){K$.call(this,J,Z,Y)},attributes:{xmlns:W0,version:String}});o({tag:"iframe",name:"HTMLIFrameElement",ctor:function(J,Z,Y){K$.call(this,J,Z,Y)},attributes:{src:W0,srcdoc:String,name:String,width:String,height:String,seamless:Boolean,allow:Boolean,allowFullscreen:Boolean,allowUserMedia:Boolean,allowPaymentRequest:Boolean,referrerPolicy:mJ,loading:{type:["eager","lazy"],treatNullAsEmptyString:!0},align:String,scrolling:String,frameBorder:String,longDesc:W0,marginHeight:{type:String,treatNullAsEmptyString:!0},marginWidth:{type:String,treatNullAsEmptyString:!0}}});o({tag:"img",name:"HTMLImageElement",ctor:function(J,Z,Y){K$.call(this,J,Z,Y)},attributes:{alt:String,src:W0,srcset:String,crossOrigin:aZ,useMap:String,isMap:Boolean,sizes:String,height:{type:"unsigned long",default:0},width:{type:"unsigned long",default:0},referrerPolicy:mJ,loading:{type:["eager","lazy"],missing:""},name:String,lowsrc:W0,align:String,hspace:{type:"unsigned long",default:0},vspace:{type:"unsigned long",default:0},longDesc:W0,border:{type:String,treatNullAsEmptyString:!0}}});o({tag:"input",name:"HTMLInputElement",ctor:function(J,Z,Y){F1.call(this,J,Z,Y)},props:{form:z1.form,_post_click_activation_steps:{value:function($){if(this.type==="checkbox")this.checked=!this.checked;else if(this.type==="radio"){var J=this.form.getElementsByName(this.name);for(var Z=J.length-1;Z>=0;Z--){var Y=J[Z];Y.checked=Y===this}}}}},attributes:{name:String,disabled:Boolean,autofocus:Boolean,accept:String,alt:String,max:String,min:String,pattern:String,placeholder:String,step:String,dirName:String,defaultValue:{name:"value"},multiple:Boolean,required:Boolean,readOnly:Boolean,checked:Boolean,value:String,src:W0,defaultChecked:{name:"checked",type:Boolean},size:{type:"unsigned long",default:20,min:1,setmin:1},width:{type:"unsigned long",min:0,setmin:0,default:0},height:{type:"unsigned long",min:0,setmin:0,default:0},minLength:{type:"unsigned long",min:0,setmin:0,default:-1},maxLength:{type:"unsigned long",min:0,setmin:0,default:-1},autocomplete:String,type:{type:["text","hidden","search","tel","url","email","password","datetime","date","month","week","time","datetime-local","number","range","color","checkbox","radio","file","submit","image","reset","button"],missing:"text"},formTarget:String,formNoValidate:Boolean,formMethod:{type:["get","post"],invalid:"get",missing:""},formEnctype:{type:["application/x-www-form-urlencoded","multipart/form-data","text/plain"],invalid:"application/x-www-form-urlencoded",missing:""},inputMode:{type:["verbatim","latin","latin-name","latin-prose","full-width-latin","kana","kana-name","katakana","numeric","tel","email","url"],missing:""},align:String,useMap:String}});o({tag:"keygen",name:"HTMLKeygenElement",ctor:function(J,Z,Y){F1.call(this,J,Z,Y)},props:z1,attributes:{name:String,disabled:Boolean,autofocus:Boolean,challenge:String,keytype:{type:["rsa"],missing:""}}});o({tag:"li",name:"HTMLLIElement",ctor:function(J,Z,Y){K$.call(this,J,Z,Y)},attributes:{value:{type:"long",default:0},type:String}});o({tag:"label",name:"HTMLLabelElement",ctor:function(J,Z,Y){F1.call(this,J,Z,Y)},props:z1,attributes:{htmlFor:{name:"for",type:String}}});o({tag:"legend",name:"HTMLLegendElement",ctor:function(J,Z,Y){K$.call(this,J,Z,Y)},attributes:{align:String}});o({tag:"link",name:"HTMLLinkElement",ctor:function(J,Z,Y){K$.call(this,J,Z,Y)},attributes:{href:W0,rel:String,media:String,hreflang:String,type:String,crossOrigin:aZ,nonce:String,integrity:String,referrerPolicy:mJ,imageSizes:String,imageSrcset:String,charset:String,rev:String,target:String}});o({tag:"map",name:"HTMLMapElement",ctor:function(J,Z,Y){K$.call(this,J,Z,Y)},attributes:{name:String}});o({tag:"menu",name:"HTMLMenuElement",ctor:function(J,Z,Y){K$.call(this,J,Z,Y)},attributes:{type:{type:["context","popup","toolbar"],missing:"toolbar"},label:String,compact:Boolean}});o({tag:"meta",name:"HTMLMetaElement",ctor:function(J,Z,Y){K$.call(this,J,Z,Y)},attributes:{name:String,content:String,httpEquiv:{name:"http-equiv",type:String},scheme:String}});o({tag:"meter",name:"HTMLMeterElement",ctor:function(J,Z,Y){F1.call(this,J,Z,Y)},props:z1});o({tags:["ins","del"],name:"HTMLModElement",ctor:function(J,Z,Y){K$.call(this,J,Z,Y)},attributes:{cite:W0,dateTime:String}});o({tag:"ol",name:"HTMLOListElement",ctor:function(J,Z,Y){K$.call(this,J,Z,Y)},props:{_numitems:{get:function(){var $=0;return this.childNodes.forEach(function(J){if(J.nodeType===rY.ELEMENT_NODE&&J.tagName==="LI")$++}),$}}},attributes:{type:String,reversed:Boolean,start:{type:"long",default:function(){if(this.reversed)return this._numitems;else return 1}},compact:Boolean}});o({tag:"object",name:"HTMLObjectElement",ctor:function(J,Z,Y){F1.call(this,J,Z,Y)},props:z1,attributes:{data:W0,type:String,name:String,useMap:String,typeMustMatch:Boolean,width:String,height:String,align:String,archive:String,code:String,declare:Boolean,hspace:{type:"unsigned long",default:0},standby:String,vspace:{type:"unsigned long",default:0},codeBase:W0,codeType:String,border:{type:String,treatNullAsEmptyString:!0}}});o({tag:"optgroup",name:"HTMLOptGroupElement",ctor:function(J,Z,Y){K$.call(this,J,Z,Y)},attributes:{disabled:Boolean,label:String}});o({tag:"option",name:"HTMLOptionElement",ctor:function(J,Z,Y){K$.call(this,J,Z,Y)},props:{form:{get:function(){var $=this.parentNode;while($&&$.nodeType===rY.ELEMENT_NODE){if($.localName==="select")return $.form;$=$.parentNode}}},value:{get:function(){return this._getattr("value")||this.text},set:function($){this._setattr("value",$)}},text:{get:function(){return this.textContent.replace(/[ \t\n\f\r]+/g," ").trim()},set:function($){this.textContent=$}}},attributes:{disabled:Boolean,defaultSelected:{name:"selected",type:Boolean},label:String}});o({tag:"output",name:"HTMLOutputElement",ctor:function(J,Z,Y){F1.call(this,J,Z,Y)},props:z1,attributes:{name:String}});o({tag:"p",name:"HTMLParagraphElement",ctor:function(J,Z,Y){K$.call(this,J,Z,Y)},attributes:{align:String}});o({tag:"param",name:"HTMLParamElement",ctor:function(J,Z,Y){K$.call(this,J,Z,Y)},attributes:{name:String,value:String,type:String,valueType:String}});o({tags:["pre","listing","xmp"],name:"HTMLPreElement",ctor:function(J,Z,Y){K$.call(this,J,Z,Y)},attributes:{width:{type:"long",default:0}}});o({tag:"progress",name:"HTMLProgressElement",ctor:function(J,Z,Y){F1.call(this,J,Z,Y)},props:z1,attributes:{max:{type:Number,float:!0,default:1,min:0}}});o({tags:["q","blockquote"],name:"HTMLQuoteElement",ctor:function(J,Z,Y){K$.call(this,J,Z,Y)},attributes:{cite:W0}});o({tag:"script",name:"HTMLScriptElement",ctor:function(J,Z,Y){K$.call(this,J,Z,Y)},props:{text:{get:function(){var $="";for(var J=0,Z=this.childNodes.length;J<Z;J++){var Y=this.childNodes[J];if(Y.nodeType===rY.TEXT_NODE)$+=Y._data}return $},set:function($){if(this.removeChildren(),$!==null&&$!=="")this.appendChild(this.ownerDocument.createTextNode($))}}},attributes:{src:W0,type:String,charset:String,referrerPolicy:mJ,defer:Boolean,async:Boolean,nomodule:Boolean,crossOrigin:aZ,nonce:String,integrity:String}});o({tag:"select",name:"HTMLSelectElement",ctor:function(J,Z,Y){F1.call(this,J,Z,Y)},props:{form:z1.form,options:{get:function(){return this.getElementsByTagName("option")}}},attributes:{autocomplete:String,name:String,disabled:Boolean,autofocus:Boolean,multiple:Boolean,required:Boolean,size:{type:"unsigned long",default:0}}});o({tag:"span",name:"HTMLSpanElement",ctor:function(J,Z,Y){K$.call(this,J,Z,Y)}});o({tag:"style",name:"HTMLStyleElement",ctor:function(J,Z,Y){K$.call(this,J,Z,Y)},attributes:{media:String,type:String,scoped:Boolean}});o({tag:"caption",name:"HTMLTableCaptionElement",ctor:function(J,Z,Y){K$.call(this,J,Z,Y)},attributes:{align:String}});o({name:"HTMLTableCellElement",ctor:function(J,Z,Y){K$.call(this,J,Z,Y)},attributes:{colSpan:{type:"unsigned long",default:1},rowSpan:{type:"unsigned long",default:1},scope:{type:["row","col","rowgroup","colgroup"],missing:""},abbr:String,align:String,axis:String,height:String,width:String,ch:{name:"char",type:String},chOff:{name:"charoff",type:String},noWrap:Boolean,vAlign:String,bgColor:{type:String,treatNullAsEmptyString:!0}}});o({tags:["col","colgroup"],name:"HTMLTableColElement",ctor:function(J,Z,Y){K$.call(this,J,Z,Y)},attributes:{span:{type:"limited unsigned long with fallback",default:1,min:1},align:String,ch:{name:"char",type:String},chOff:{name:"charoff",type:String},vAlign:String,width:String}});o({tag:"table",name:"HTMLTableElement",ctor:function(J,Z,Y){K$.call(this,J,Z,Y)},props:{rows:{get:function(){return this.getElementsByTagName("tr")}}},attributes:{align:String,border:String,frame:String,rules:String,summary:String,width:String,bgColor:{type:String,treatNullAsEmptyString:!0},cellPadding:{type:String,treatNullAsEmptyString:!0},cellSpacing:{type:String,treatNullAsEmptyString:!0}}});o({tag:"template",name:"HTMLTemplateElement",ctor:function(J,Z,Y){K$.call(this,J,Z,Y),this._contentFragment=J._templateDoc.createDocumentFragment()},props:{content:{get:function(){return this._contentFragment}},serialize:{value:function(){return this.content.serialize()}}}});o({tag:"tr",name:"HTMLTableRowElement",ctor:function(J,Z,Y){K$.call(this,J,Z,Y)},props:{cells:{get:function(){return this.querySelectorAll("td,th")}}},attributes:{align:String,ch:{name:"char",type:String},chOff:{name:"charoff",type:String},vAlign:String,bgColor:{type:String,treatNullAsEmptyString:!0}}});o({tags:["thead","tfoot","tbody"],name:"HTMLTableSectionElement",ctor:function(J,Z,Y){K$.call(this,J,Z,Y)},props:{rows:{get:function(){return this.getElementsByTagName("tr")}}},attributes:{align:String,ch:{name:"char",type:String},chOff:{name:"charoff",type:String},vAlign:String}});o({tag:"textarea",name:"HTMLTextAreaElement",ctor:function(J,Z,Y){F1.call(this,J,Z,Y)},props:{form:z1.form,type:{get:function(){return"textarea"}},defaultValue:{get:function(){return this.textContent},set:function($){this.textContent=$}},value:{get:function(){return this.defaultValue},set:function($){this.defaultValue=$}},textLength:{get:function(){return this.value.length}}},attributes:{autocomplete:String,name:String,disabled:Boolean,autofocus:Boolean,placeholder:String,wrap:String,dirName:String,required:Boolean,readOnly:Boolean,rows:{type:"limited unsigned long with fallback",default:2},cols:{type:"limited unsigned long with fallback",default:20},maxLength:{type:"unsigned long",min:0,setmin:0,default:-1},minLength:{type:"unsigned long",min:0,setmin:0,default:-1},inputMode:{type:["verbatim","latin","latin-name","latin-prose","full-width-latin","kana","kana-name","katakana","numeric","tel","email","url"],missing:""}}});o({tag:"time",name:"HTMLTimeElement",ctor:function(J,Z,Y){K$.call(this,J,Z,Y)},attributes:{dateTime:String,pubDate:Boolean}});o({tag:"title",name:"HTMLTitleElement",ctor:function(J,Z,Y){K$.call(this,J,Z,Y)},props:{text:{get:function(){return this.textContent}}}});o({tag:"ul",name:"HTMLUListElement",ctor:function(J,Z,Y){K$.call(this,J,Z,Y)},attributes:{type:String,compact:Boolean}});o({name:"HTMLMediaElement",ctor:function(J,Z,Y){K$.call(this,J,Z,Y)},attributes:{src:W0,crossOrigin:aZ,preload:{type:["metadata","none","auto",{value:"",alias:"auto"}],missing:"auto"},loop:Boolean,autoplay:Boolean,mediaGroup:String,controls:Boolean,defaultMuted:{name:"muted",type:Boolean}}});o({name:"HTMLAudioElement",tag:"audio",superclass:i1.HTMLMediaElement,ctor:function(J,Z,Y){i1.HTMLMediaElement.call(this,J,Z,Y)}});o({name:"HTMLVideoElement",tag:"video",superclass:i1.HTMLMediaElement,ctor:function(J,Z,Y){i1.HTMLMediaElement.call(this,J,Z,Y)},attributes:{poster:W0,width:{type:"unsigned long",min:0,default:0},height:{type:"unsigned long",min:0,default:0}}});o({tag:"td",name:"HTMLTableDataCellElement",superclass:i1.HTMLTableCellElement,ctor:function(J,Z,Y){i1.HTMLTableCellElement.call(this,J,Z,Y)}});o({tag:"th",name:"HTMLTableHeaderCellElement",superclass:i1.HTMLTableCellElement,ctor:function(J,Z,Y){i1.HTMLTableCellElement.call(this,J,Z,Y)}});o({tag:"frameset",name:"HTMLFrameSetElement",ctor:function(J,Z,Y){K$.call(this,J,Z,Y)}});o({tag:"frame",name:"HTMLFrameElement",ctor:function(J,Z,Y){K$.call(this,J,Z,Y)}});o({tag:"canvas",name:"HTMLCanvasElement",ctor:function(J,Z,Y){K$.call(this,J,Z,Y)},props:{getContext:{value:c0.nyi},probablySupportsContext:{value:c0.nyi},setContext:{value:c0.nyi},transferControlToProxy:{value:c0.nyi},toDataURL:{value:c0.nyi},toBlob:{value:c0.nyi}},attributes:{width:{type:"unsigned long",default:300},height:{type:"unsigned long",default:150}}});o({tag:"dialog",name:"HTMLDialogElement",ctor:function(J,Z,Y){K$.call(this,J,Z,Y)},props:{show:{value:c0.nyi},showModal:{value:c0.nyi},close:{value:c0.nyi}},attributes:{open:Boolean,returnValue:String}});o({tag:"menuitem",name:"HTMLMenuItemElement",ctor:function(J,Z,Y){K$.call(this,J,Z,Y)},props:{_label:{get:function(){var $=this._getattr("label");if($!==null&&$!=="")return $;return $=this.textContent,$.replace(/[ \t\n\f\r]+/g," ").trim()}},label:{get:function(){var $=this._getattr("label");if($!==null)return $;return this._label},set:function($){this._setattr("label",$)}}},attributes:{type:{type:["command","checkbox","radio"],missing:"command"},icon:W0,disabled:Boolean,checked:Boolean,radiogroup:String,default:Boolean}});o({tag:"source",name:"HTMLSourceElement",ctor:function(J,Z,Y){K$.call(this,J,Z,Y)},attributes:{srcset:String,sizes:String,media:String,src:W0,type:String,width:String,height:String}});o({tag:"track",name:"HTMLTrackElement",ctor:function(J,Z,Y){K$.call(this,J,Z,Y)},attributes:{src:W0,srclang:String,label:String,default:Boolean,kind:{type:["subtitles","captions","descriptions","chapters","metadata"],missing:"subtitles",invalid:"metadata"}},props:{NONE:{get:function(){return 0}},LOADING:{get:function(){return 1}},LOADED:{get:function(){return 2}},ERROR:{get:function(){return 3}},readyState:{get:c0.nyi},track:{get:c0.nyi}}});o({tag:"font",name:"HTMLFontElement",ctor:function(J,Z,Y){K$.call(this,J,Z,Y)},attributes:{color:{type:String,treatNullAsEmptyString:!0},face:{type:String},size:{type:String}}});o({tag:"dir",name:"HTMLDirectoryElement",ctor:function(J,Z,Y){K$.call(this,J,Z,Y)},attributes:{compact:Boolean}});o({tags:["abbr","address","article","aside","b","bdi","bdo","cite","content","code","dd","dfn","dt","em","figcaption","figure","footer","header","hgroup","i","kbd","main","mark","nav","noscript","rb","rp","rt","rtc","ruby","s","samp","section","small","strong","sub","summary","sup","u","var","wbr","acronym","basefont","big","center","nobr","noembed","noframes","plaintext","strike","tt"]})});var nY=p((WP)=>{var Jj=gJ(),QP=oY(),VP=X0(),GP=nZ(),XP=WP.elements={},Zj=Object.create(null);WP.createElement=function($,J,Z){var Y=Zj[J]||sY;return new Y($,J,Z)};function iY($){return QP($,sY,XP,Zj)}var sY=iY({superclass:Jj,name:"SVGElement",ctor:function(J,Z,Y){Jj.call(this,J,Z,VP.NAMESPACE.SVG,Y)},props:{style:{get:function(){if(!this._style)this._style=new GP(this);return this._style}}}});iY({name:"SVGSVGElement",ctor:function(J,Z,Y){sY.call(this,J,Z,Y)},tag:"svg",props:{createSVGRect:{value:function(){return WP.createElement(this.ownerDocument,"rect",null)}}}});iY({tags:["a","altGlyph","altGlyphDef","altGlyphItem","animate","animateColor","animateMotion","animateTransform","circle","clipPath","color-profile","cursor","defs","desc","ellipse","feBlend","feColorMatrix","feComponentTransfer","feComposite","feConvolveMatrix","feDiffuseLighting","feDisplacementMap","feDistantLight","feFlood","feFuncA","feFuncB","feFuncG","feFuncR","feGaussianBlur","feImage","feMerge","feMergeNode","feMorphology","feOffset","fePointLight","feSpecularLighting","feSpotLight","feTile","feTurbulence","filter","font","font-face","font-face-format","font-face-name","font-face-src","font-face-uri","foreignObject","g","glyph","glyphRef","hkern","image","line","linearGradient","marker","mask","metadata","missing-glyph","mpath","path","pattern","polygon","polyline","radialGradient","rect","script","set","stop","style","switch","symbol","text","textPath","title","tref","tspan","use","view","vkern"]})});var Qj=p((ab,Kj)=>{Kj.exports={VALUE:1,ATTR:2,REMOVE_ATTR:3,REMOVE:4,MOVE:5,INSERT:6}});var $6=p((tb,Oj)=>{Oj.exports=f8;var w0=P0(),jP=n2(),Uj=gZ(),q2=gJ(),UP=NY(),HP=TY(),g8=TJ(),BP=EY(),_P=bY(),OP=m8(),qP=L5(),FP=x5(),Vj=b8(),Gj=sZ(),Xj=pZ(),zP=cY(),eZ=fZ(),aY=tZ(),CP=nY(),v$=X0(),uJ=Qj(),pJ=v$.NAMESPACE,tY=bZ().isApiWritable;function f8($,J){Uj.call(this),this.nodeType=w0.DOCUMENT_NODE,this.isHTML=$,this._address=J||"about:blank",this.readyState="loading",this.implementation=new OP(this),this.ownerDocument=null,this._contentType=$?"text/html":"application/xml",this.doctype=null,this.documentElement=null,this._templateDocCache=null,this._nodeIterators=null,this._nid=1,this._nextnid=2,this._nodes=[null,this],this.byId=Object.create(null),this.modclock=0}var MP={event:"Event",customevent:"CustomEvent",uievent:"UIEvent",mouseevent:"MouseEvent"},DP={events:"event",htmlevents:"event",mouseevents:"mouseevent",mutationevents:"mutationevent",uievents:"uievent"},dJ=function($,J,Z){return{get:function(){var Y=$.call(this);if(Y)return Y[J];return Z},set:function(Y){var K=$.call(this);if(K)K[J]=Y}}};function Wj($,J){var Z,Y,K;if($==="")$=null;if(!eZ.isValidQName(J))v$.InvalidCharacterError();if(Z=null,Y=J,K=J.indexOf(":"),K>=0)Z=J.substring(0,K),Y=J.substring(K+1);if(Z!==null&&$===null)v$.NamespaceError();if(Z==="xml"&&$!==pJ.XML)v$.NamespaceError();if((Z==="xmlns"||J==="xmlns")&&$!==pJ.XMLNS)v$.NamespaceError();if($===pJ.XMLNS&&!(Z==="xmlns"||J==="xmlns"))v$.NamespaceError();return{namespace:$,prefix:Z,localName:Y}}f8.prototype=Object.create(Uj.prototype,{_setMutationHandler:{value:function($){this.mutationHandler=$}},_dispatchRendererEvent:{value:function($,J,Z){var Y=this._nodes[$];if(!Y)return;Y._dispatchEvent(new g8(J,Z),!0)}},nodeName:{value:"#document"},nodeValue:{get:function(){return null},set:function(){}},documentURI:{get:function(){return this._address},set:v$.nyi},compatMode:{get:function(){return this._quirks?"BackCompat":"CSS1Compat"}},createTextNode:{value:function($){return new UP(this,String($))}},createComment:{value:function($){return new HP(this,$)}},createDocumentFragment:{value:function(){return new BP(this)}},createProcessingInstruction:{value:function($,J){if(!eZ.isValidName($)||J.indexOf("?>")!==-1)v$.InvalidCharacterError();return new _P(this,$,J)}},createAttribute:{value:function($){if($=String($),!eZ.isValidName($))v$.InvalidCharacterError();if(this.isHTML)$=v$.toASCIILowerCase($);return new q2._Attr(null,$,null,null,"")}},createAttributeNS:{value:function($,J){$=$===null||$===void 0||$===""?null:String($),J=String(J);var Z=Wj($,J);return new q2._Attr(null,Z.localName,Z.prefix,Z.namespace,"")}},createElement:{value:function($){if($=String($),!eZ.isValidName($))v$.InvalidCharacterError();if(this.isHTML){if(/[A-Z]/.test($))$=v$.toASCIILowerCase($);return aY.createElement(this,$,null)}else if(this.contentType==="application/xhtml+xml")return aY.createElement(this,$,null);else return new q2(this,$,null,null)},writable:tY},createElementNS:{value:function($,J){$=$===null||$===void 0||$===""?null:String($),J=String(J);var Z=Wj($,J);return this._createElementNS(Z.localName,Z.namespace,Z.prefix)},writable:tY},_createElementNS:{value:function($,J,Z){if(J===pJ.HTML)return aY.createElement(this,$,Z);else if(J===pJ.SVG)return CP.createElement(this,$,Z);return new q2(this,$,J,Z)}},createEvent:{value:function(J){J=J.toLowerCase();var Z=DP[J]||J,Y=zP[MP[Z]];if(Y){var K=new Y;return K._initialized=!1,K}else v$.NotSupportedError()}},createTreeWalker:{value:function($,J,Z){if(!$)throw TypeError("root argument is required");if(!($ instanceof w0))throw TypeError("root not a node");return J=J===void 0?Vj.SHOW_ALL:+J,Z=Z===void 0?null:Z,new qP($,J,Z)}},createNodeIterator:{value:function($,J,Z){if(!$)throw TypeError("root argument is required");if(!($ instanceof w0))throw TypeError("root not a node");return J=J===void 0?Vj.SHOW_ALL:+J,Z=Z===void 0?null:Z,new FP($,J,Z)}},_attachNodeIterator:{value:function($){if(!this._nodeIterators)this._nodeIterators=[];this._nodeIterators.push($)}},_detachNodeIterator:{value:function($){var J=this._nodeIterators.indexOf($);this._nodeIterators.splice(J,1)}},_preremoveNodeIterators:{value:function($){if(this._nodeIterators)this._nodeIterators.forEach(function(J){J._preremove($)})}},_updateDocTypeElement:{value:function(){this.doctype=this.documentElement=null;for(var J=this.firstChild;J!==null;J=J.nextSibling)if(J.nodeType===w0.DOCUMENT_TYPE_NODE)this.doctype=J;else if(J.nodeType===w0.ELEMENT_NODE)this.documentElement=J}},insertBefore:{value:function(J,Z){return w0.prototype.insertBefore.call(this,J,Z),this._updateDocTypeElement(),J}},replaceChild:{value:function(J,Z){return w0.prototype.replaceChild.call(this,J,Z),this._updateDocTypeElement(),Z}},removeChild:{value:function(J){return w0.prototype.removeChild.call(this,J),this._updateDocTypeElement(),J}},getElementById:{value:function($){var J=this.byId[$];if(!J)return null;if(J instanceof s1)return J.getFirst();return J}},_hasMultipleElementsWithId:{value:function($){return this.byId[$]instanceof s1}},getElementsByName:{value:q2.prototype.getElementsByName},getElementsByTagName:{value:q2.prototype.getElementsByTagName},getElementsByTagNameNS:{value:q2.prototype.getElementsByTagNameNS},getElementsByClassName:{value:q2.prototype.getElementsByClassName},adoptNode:{value:function(J){if(J.nodeType===w0.DOCUMENT_NODE)v$.NotSupportedError();if(J.nodeType===w0.ATTRIBUTE_NODE)return J;if(J.parentNode)J.parentNode.removeChild(J);if(J.ownerDocument!==this)_j(J,this);return J}},importNode:{value:function(J,Z){return this.adoptNode(J.cloneNode(Z))},writable:tY},origin:{get:function(){return null}},characterSet:{get:function(){return"UTF-8"}},contentType:{get:function(){return this._contentType}},URL:{get:function(){return this._address}},domain:{get:v$.nyi,set:v$.nyi},referrer:{get:v$.nyi},cookie:{get:v$.nyi,set:v$.nyi},lastModified:{get:v$.nyi},location:{get:function(){return this.defaultView?this.defaultView.location:null},set:v$.nyi},_titleElement:{get:function(){return this.getElementsByTagName("title").item(0)||null}},title:{get:function(){var $=this._titleElement,J=$?$.textContent:"";return J.replace(/[ \t\n\r\f]+/g," ").replace(/(^ )|( $)/g,"")},set:function($){var J=this._titleElement,Z=this.head;if(!J&&!Z)return;if(!J)J=this.createElement("title"),Z.appendChild(J);J.textContent=$}},dir:dJ(function(){var $=this.documentElement;if($&&$.tagName==="HTML")return $},"dir",""),fgColor:dJ(function(){return this.body},"text",""),linkColor:dJ(function(){return this.body},"link",""),vlinkColor:dJ(function(){return this.body},"vLink",""),alinkColor:dJ(function(){return this.body},"aLink",""),bgColor:dJ(function(){return this.body},"bgColor",""),charset:{get:function(){return this.characterSet}},inputEncoding:{get:function(){return this.characterSet}},scrollingElement:{get:function(){return this._quirks?this.body:this.documentElement}},body:{get:function(){return jj(this.documentElement,"body")},set:v$.nyi},head:{get:function(){return jj(this.documentElement,"head")}},images:{get:v$.nyi},embeds:{get:v$.nyi},plugins:{get:v$.nyi},links:{get:v$.nyi},forms:{get:v$.nyi},scripts:{get:v$.nyi},applets:{get:function(){return[]}},activeElement:{get:function(){return null}},innerHTML:{get:function(){return this.serialize()},set:v$.nyi},outerHTML:{get:function(){return this.serialize()},set:v$.nyi},write:{value:function($){if(!this.isHTML)v$.InvalidStateError();if(!this._parser)return;if(!this._parser);var J=arguments.join("");this._parser.parse(J)}},writeln:{value:function(J){this.write(Array.prototype.join.call(arguments,"")+`
|
|
32
|
-
`)}},open:{value:function(){this.documentElement=null}},close:{value:function(){if(this.readyState="interactive",this._dispatchEvent(new g8("readystatechange"),!0),this._dispatchEvent(new g8("DOMContentLoaded"),!0),this.readyState="complete",this._dispatchEvent(new g8("readystatechange"),!0),this.defaultView)this.defaultView._dispatchEvent(new g8("load"),!0)}},clone:{value:function(){var J=new f8(this.isHTML,this._address);return J._quirks=this._quirks,J._contentType=this._contentType,J}},cloneNode:{value:function(J){var Z=w0.prototype.cloneNode.call(this,!1);if(J)for(var Y=this.firstChild;Y!==null;Y=Y.nextSibling)Z._appendChild(Z.importNode(Y,!0));return Z._updateDocTypeElement(),Z}},isEqual:{value:function(J){return!0}},mutateValue:{value:function($){if(this.mutationHandler)this.mutationHandler({type:uJ.VALUE,target:$,data:$.data})}},mutateAttr:{value:function($,J){if(this.mutationHandler)this.mutationHandler({type:uJ.ATTR,target:$.ownerElement,attr:$})}},mutateRemoveAttr:{value:function($){if(this.mutationHandler)this.mutationHandler({type:uJ.REMOVE_ATTR,target:$.ownerElement,attr:$})}},mutateRemove:{value:function($){if(this.mutationHandler)this.mutationHandler({type:uJ.REMOVE,target:$.parentNode,node:$});Bj($)}},mutateInsert:{value:function($){if(Hj($),this.mutationHandler)this.mutationHandler({type:uJ.INSERT,target:$.parentNode,node:$})}},mutateMove:{value:function($){if(this.mutationHandler)this.mutationHandler({type:uJ.MOVE,target:$})}},addId:{value:function(J,Z){var Y=this.byId[J];if(!Y)this.byId[J]=Z;else{if(!(Y instanceof s1))Y=new s1(Y),this.byId[J]=Y;Y.add(Z)}}},delId:{value:function(J,Z){var Y=this.byId[J];if(v$.assert(Y),Y instanceof s1){if(Y.del(Z),Y.length===1)this.byId[J]=Y.downgrade()}else this.byId[J]=void 0}},_resolve:{value:function($){return new Gj(this._documentBaseURL).resolve($)}},_documentBaseURL:{get:function(){var $=this._address;if($==="about:blank")$="/";var J=this.querySelector("base[href]");if(J)return new Gj($).resolve(J.getAttribute("href"));return $}},_templateDoc:{get:function(){if(!this._templateDocCache){var $=new f8(this.isHTML,this._address);this._templateDocCache=$._templateDocCache=$}return this._templateDocCache}},querySelector:{value:function($){return Xj($,this)[0]}},querySelectorAll:{value:function($){var J=Xj($,this);return J.item?J:new jP(J)}}});var PP=["abort","canplay","canplaythrough","change","click","contextmenu","cuechange","dblclick","drag","dragend","dragenter","dragleave","dragover","dragstart","drop","durationchange","emptied","ended","input","invalid","keydown","keypress","keyup","loadeddata","loadedmetadata","loadstart","mousedown","mousemove","mouseout","mouseover","mouseup","mousewheel","pause","play","playing","progress","ratechange","readystatechange","reset","seeked","seeking","select","show","stalled","submit","suspend","timeupdate","volumechange","waiting","blur","error","focus","load","scroll"];PP.forEach(function($){Object.defineProperty(f8.prototype,"on"+$,{get:function(){return this._getEventHandler($)},set:function(J){this._setEventHandler($,J)}})});function jj($,J){if($&&$.isHTML){for(var Z=$.firstChild;Z!==null;Z=Z.nextSibling)if(Z.nodeType===w0.ELEMENT_NODE&&Z.localName===J&&Z.namespaceURI===pJ.HTML)return Z}return null}function IP($){if($._nid=$.ownerDocument._nextnid++,$.ownerDocument._nodes[$._nid]=$,$.nodeType===w0.ELEMENT_NODE){var J=$.getAttribute("id");if(J)$.ownerDocument.addId(J,$);if($._roothook)$._roothook()}}function AP($){if($.nodeType===w0.ELEMENT_NODE){var J=$.getAttribute("id");if(J)$.ownerDocument.delId(J,$)}$.ownerDocument._nodes[$._nid]=void 0,$._nid=void 0}function Hj($){if(IP($),$.nodeType===w0.ELEMENT_NODE)for(var J=$.firstChild;J!==null;J=J.nextSibling)Hj(J)}function Bj($){AP($);for(var J=$.firstChild;J!==null;J=J.nextSibling)Bj(J)}function _j($,J){if($.ownerDocument=J,$._lastModTime=void 0,Object.prototype.hasOwnProperty.call($,"_tagName"))$._tagName=void 0;for(var Z=$.firstChild;Z!==null;Z=Z.nextSibling)_j(Z,J)}function s1($){this.nodes=Object.create(null),this.nodes[$._nid]=$,this.length=1,this.firstNode=void 0}s1.prototype.add=function($){if(!this.nodes[$._nid])this.nodes[$._nid]=$,this.length++,this.firstNode=void 0};s1.prototype.del=function($){if(this.nodes[$._nid])delete this.nodes[$._nid],this.length--,this.firstNode=void 0};s1.prototype.getFirst=function(){if(!this.firstNode){var $;for($ in this.nodes)if(this.firstNode===void 0||this.firstNode.compareDocumentPosition(this.nodes[$])&w0.DOCUMENT_POSITION_PRECEDING)this.firstNode=this.nodes[$]}return this.firstNode};s1.prototype.downgrade=function(){if(this.length===1){var $;for($ in this.nodes)return this.nodes[$]}return this}});var Z6=p((eb,Fj)=>{Fj.exports=J6;var SP=P0(),qj=RY(),wP=cZ();function J6($,J,Z,Y){qj.call(this),this.nodeType=SP.DOCUMENT_TYPE_NODE,this.ownerDocument=$||null,this.name=J,this.publicId=Z||"",this.systemId=Y||""}J6.prototype=Object.create(qj.prototype,{nodeName:{get:function(){return this.name}},nodeValue:{get:function(){return null},set:function(){}},clone:{value:function(){return new J6(this.ownerDocument,this.name,this.publicId,this.systemId)}},isEqual:{value:function(J){return this.name===J.name&&this.publicId===J.publicId&&this.systemId===J.systemId}}});Object.defineProperties(J6.prototype,wP)});var W6=p(($v,mj)=>{mj.exports=b$;var RP=$6(),LP=Z6(),eY=P0(),X$=X0().NAMESPACE,kj=tZ(),u$=kj.elements,t2=Function.prototype.apply.bind(Array.prototype.push),Y6=-1,cJ=1,R0=2,N$=3,y1=4,NP=5,yP=[],TP=/^HTML$|^-\/\/W3O\/\/DTD W3 HTML Strict 3\.0\/\/EN\/\/$|^-\/W3C\/DTD HTML 4\.0 Transitional\/EN$|^\+\/\/Silmaril\/\/dtd html Pro v0r11 19970101\/\/|^-\/\/AdvaSoft Ltd\/\/DTD HTML 3\.0 asWedit \+ extensions\/\/|^-\/\/AS\/\/DTD HTML 3\.0 asWedit \+ extensions\/\/|^-\/\/IETF\/\/DTD HTML 2\.0 Level 1\/\/|^-\/\/IETF\/\/DTD HTML 2\.0 Level 2\/\/|^-\/\/IETF\/\/DTD HTML 2\.0 Strict Level 1\/\/|^-\/\/IETF\/\/DTD HTML 2\.0 Strict Level 2\/\/|^-\/\/IETF\/\/DTD HTML 2\.0 Strict\/\/|^-\/\/IETF\/\/DTD HTML 2\.0\/\/|^-\/\/IETF\/\/DTD HTML 2\.1E\/\/|^-\/\/IETF\/\/DTD HTML 3\.0\/\/|^-\/\/IETF\/\/DTD HTML 3\.2 Final\/\/|^-\/\/IETF\/\/DTD HTML 3\.2\/\/|^-\/\/IETF\/\/DTD HTML 3\/\/|^-\/\/IETF\/\/DTD HTML Level 0\/\/|^-\/\/IETF\/\/DTD HTML Level 1\/\/|^-\/\/IETF\/\/DTD HTML Level 2\/\/|^-\/\/IETF\/\/DTD HTML Level 3\/\/|^-\/\/IETF\/\/DTD HTML Strict Level 0\/\/|^-\/\/IETF\/\/DTD HTML Strict Level 1\/\/|^-\/\/IETF\/\/DTD HTML Strict Level 2\/\/|^-\/\/IETF\/\/DTD HTML Strict Level 3\/\/|^-\/\/IETF\/\/DTD HTML Strict\/\/|^-\/\/IETF\/\/DTD HTML\/\/|^-\/\/Metrius\/\/DTD Metrius Presentational\/\/|^-\/\/Microsoft\/\/DTD Internet Explorer 2\.0 HTML Strict\/\/|^-\/\/Microsoft\/\/DTD Internet Explorer 2\.0 HTML\/\/|^-\/\/Microsoft\/\/DTD Internet Explorer 2\.0 Tables\/\/|^-\/\/Microsoft\/\/DTD Internet Explorer 3\.0 HTML Strict\/\/|^-\/\/Microsoft\/\/DTD Internet Explorer 3\.0 HTML\/\/|^-\/\/Microsoft\/\/DTD Internet Explorer 3\.0 Tables\/\/|^-\/\/Netscape Comm\. Corp\.\/\/DTD HTML\/\/|^-\/\/Netscape Comm\. Corp\.\/\/DTD Strict HTML\/\/|^-\/\/O'Reilly and Associates\/\/DTD HTML 2\.0\/\/|^-\/\/O'Reilly and Associates\/\/DTD HTML Extended 1\.0\/\/|^-\/\/O'Reilly and Associates\/\/DTD HTML Extended Relaxed 1\.0\/\/|^-\/\/SoftQuad Software\/\/DTD HoTMetaL PRO 6\.0::19990601::extensions to HTML 4\.0\/\/|^-\/\/SoftQuad\/\/DTD HoTMetaL PRO 4\.0::19971010::extensions to HTML 4\.0\/\/|^-\/\/Spyglass\/\/DTD HTML 2\.0 Extended\/\/|^-\/\/SQ\/\/DTD HTML 2\.0 HoTMetaL \+ extensions\/\/|^-\/\/Sun Microsystems Corp\.\/\/DTD HotJava HTML\/\/|^-\/\/Sun Microsystems Corp\.\/\/DTD HotJava Strict HTML\/\/|^-\/\/W3C\/\/DTD HTML 3 1995-03-24\/\/|^-\/\/W3C\/\/DTD HTML 3\.2 Draft\/\/|^-\/\/W3C\/\/DTD HTML 3\.2 Final\/\/|^-\/\/W3C\/\/DTD HTML 3\.2\/\/|^-\/\/W3C\/\/DTD HTML 3\.2S Draft\/\/|^-\/\/W3C\/\/DTD HTML 4\.0 Frameset\/\/|^-\/\/W3C\/\/DTD HTML 4\.0 Transitional\/\/|^-\/\/W3C\/\/DTD HTML Experimental 19960712\/\/|^-\/\/W3C\/\/DTD HTML Experimental 970421\/\/|^-\/\/W3C\/\/DTD W3 HTML\/\/|^-\/\/W3O\/\/DTD W3 HTML 3\.0\/\/|^-\/\/WebTechs\/\/DTD Mozilla HTML 2\.0\/\/|^-\/\/WebTechs\/\/DTD Mozilla HTML\/\//i,kP="http://www.ibm.com/data/dtd/v11/ibmxhtml1-transitional.dtd",zj=/^-\/\/W3C\/\/DTD HTML 4\.01 Frameset\/\/|^-\/\/W3C\/\/DTD HTML 4\.01 Transitional\/\//i,EP=/^-\/\/W3C\/\/DTD XHTML 1\.0 Frameset\/\/|^-\/\/W3C\/\/DTD XHTML 1\.0 Transitional\/\//i,$J=Object.create(null);$J[X$.HTML]={__proto__:null,address:!0,applet:!0,area:!0,article:!0,aside:!0,base:!0,basefont:!0,bgsound:!0,blockquote:!0,body:!0,br:!0,button:!0,caption:!0,center:!0,col:!0,colgroup:!0,dd:!0,details:!0,dir:!0,div:!0,dl:!0,dt:!0,embed:!0,fieldset:!0,figcaption:!0,figure:!0,footer:!0,form:!0,frame:!0,frameset:!0,h1:!0,h2:!0,h3:!0,h4:!0,h5:!0,h6:!0,head:!0,header:!0,hgroup:!0,hr:!0,html:!0,iframe:!0,img:!0,input:!0,li:!0,link:!0,listing:!0,main:!0,marquee:!0,menu:!0,meta:!0,nav:!0,noembed:!0,noframes:!0,noscript:!0,object:!0,ol:!0,p:!0,param:!0,plaintext:!0,pre:!0,script:!0,section:!0,select:!0,source:!0,style:!0,summary:!0,table:!0,tbody:!0,td:!0,template:!0,textarea:!0,tfoot:!0,th:!0,thead:!0,title:!0,tr:!0,track:!0,ul:!0,wbr:!0,xmp:!0};$J[X$.SVG]={__proto__:null,foreignObject:!0,desc:!0,title:!0};$J[X$.MATHML]={__proto__:null,mi:!0,mo:!0,mn:!0,ms:!0,mtext:!0,"annotation-xml":!0};var Z3=Object.create(null);Z3[X$.HTML]={__proto__:null,address:!0,div:!0,p:!0};var Ej=Object.create(null);Ej[X$.HTML]={__proto__:null,dd:!0,dt:!0};var lJ=Object.create(null);lJ[X$.HTML]={__proto__:null,table:!0,thead:!0,tbody:!0,tfoot:!0,tr:!0};var xj=Object.create(null);xj[X$.HTML]={__proto__:null,dd:!0,dt:!0,li:!0,menuitem:!0,optgroup:!0,option:!0,p:!0,rb:!0,rp:!0,rt:!0,rtc:!0};var bj=Object.create(null);bj[X$.HTML]={__proto__:null,caption:!0,colgroup:!0,dd:!0,dt:!0,li:!0,optgroup:!0,option:!0,p:!0,rb:!0,rp:!0,rt:!0,rtc:!0,tbody:!0,td:!0,tfoot:!0,th:!0,thead:!0,tr:!0};var V6=Object.create(null);V6[X$.HTML]={__proto__:null,table:!0,template:!0,html:!0};var G6=Object.create(null);G6[X$.HTML]={__proto__:null,tbody:!0,tfoot:!0,thead:!0,template:!0,html:!0};var Y3=Object.create(null);Y3[X$.HTML]={__proto__:null,tr:!0,template:!0,html:!0};var vj=Object.create(null);vj[X$.HTML]={__proto__:null,button:!0,fieldset:!0,input:!0,keygen:!0,object:!0,output:!0,select:!0,textarea:!0,img:!0};var T1=Object.create(null);T1[X$.HTML]={__proto__:null,applet:!0,caption:!0,html:!0,table:!0,td:!0,th:!0,marquee:!0,object:!0,template:!0};T1[X$.MATHML]={__proto__:null,mi:!0,mo:!0,mn:!0,ms:!0,mtext:!0,"annotation-xml":!0};T1[X$.SVG]={__proto__:null,foreignObject:!0,desc:!0,title:!0};var X6=Object.create(T1);X6[X$.HTML]=Object.create(T1[X$.HTML]);X6[X$.HTML].ol=!0;X6[X$.HTML].ul=!0;var K3=Object.create(T1);K3[X$.HTML]=Object.create(T1[X$.HTML]);K3[X$.HTML].button=!0;var hj=Object.create(null);hj[X$.HTML]={__proto__:null,html:!0,table:!0,template:!0};var xP=Object.create(null);xP[X$.HTML]={__proto__:null,optgroup:!0,option:!0};var gj=Object.create(null);gj[X$.MATHML]={__proto__:null,mi:!0,mo:!0,mn:!0,ms:!0,mtext:!0};var fj=Object.create(null);fj[X$.SVG]={__proto__:null,foreignObject:!0,desc:!0,title:!0};var Cj={__proto__:null,"xlink:actuate":X$.XLINK,"xlink:arcrole":X$.XLINK,"xlink:href":X$.XLINK,"xlink:role":X$.XLINK,"xlink:show":X$.XLINK,"xlink:title":X$.XLINK,"xlink:type":X$.XLINK,"xml:base":X$.XML,"xml:lang":X$.XML,"xml:space":X$.XML,xmlns:X$.XMLNS,"xmlns:xlink":X$.XMLNS},Mj={__proto__:null,attributename:"attributeName",attributetype:"attributeType",basefrequency:"baseFrequency",baseprofile:"baseProfile",calcmode:"calcMode",clippathunits:"clipPathUnits",diffuseconstant:"diffuseConstant",edgemode:"edgeMode",filterunits:"filterUnits",glyphref:"glyphRef",gradienttransform:"gradientTransform",gradientunits:"gradientUnits",kernelmatrix:"kernelMatrix",kernelunitlength:"kernelUnitLength",keypoints:"keyPoints",keysplines:"keySplines",keytimes:"keyTimes",lengthadjust:"lengthAdjust",limitingconeangle:"limitingConeAngle",markerheight:"markerHeight",markerunits:"markerUnits",markerwidth:"markerWidth",maskcontentunits:"maskContentUnits",maskunits:"maskUnits",numoctaves:"numOctaves",pathlength:"pathLength",patterncontentunits:"patternContentUnits",patterntransform:"patternTransform",patternunits:"patternUnits",pointsatx:"pointsAtX",pointsaty:"pointsAtY",pointsatz:"pointsAtZ",preservealpha:"preserveAlpha",preserveaspectratio:"preserveAspectRatio",primitiveunits:"primitiveUnits",refx:"refX",refy:"refY",repeatcount:"repeatCount",repeatdur:"repeatDur",requiredextensions:"requiredExtensions",requiredfeatures:"requiredFeatures",specularconstant:"specularConstant",specularexponent:"specularExponent",spreadmethod:"spreadMethod",startoffset:"startOffset",stddeviation:"stdDeviation",stitchtiles:"stitchTiles",surfacescale:"surfaceScale",systemlanguage:"systemLanguage",tablevalues:"tableValues",targetx:"targetX",targety:"targetY",textlength:"textLength",viewbox:"viewBox",viewtarget:"viewTarget",xchannelselector:"xChannelSelector",ychannelselector:"yChannelSelector",zoomandpan:"zoomAndPan"},Dj={__proto__:null,altglyph:"altGlyph",altglyphdef:"altGlyphDef",altglyphitem:"altGlyphItem",animatecolor:"animateColor",animatemotion:"animateMotion",animatetransform:"animateTransform",clippath:"clipPath",feblend:"feBlend",fecolormatrix:"feColorMatrix",fecomponenttransfer:"feComponentTransfer",fecomposite:"feComposite",feconvolvematrix:"feConvolveMatrix",fediffuselighting:"feDiffuseLighting",fedisplacementmap:"feDisplacementMap",fedistantlight:"feDistantLight",feflood:"feFlood",fefunca:"feFuncA",fefuncb:"feFuncB",fefuncg:"feFuncG",fefuncr:"feFuncR",fegaussianblur:"feGaussianBlur",feimage:"feImage",femerge:"feMerge",femergenode:"feMergeNode",femorphology:"feMorphology",feoffset:"feOffset",fepointlight:"fePointLight",fespecularlighting:"feSpecularLighting",fespotlight:"feSpotLight",fetile:"feTile",feturbulence:"feTurbulence",foreignobject:"foreignObject",glyphref:"glyphRef",lineargradient:"linearGradient",radialgradient:"radialGradient",textpath:"textPath"},Pj={__proto__:null,0:65533,128:8364,130:8218,131:402,132:8222,133:8230,134:8224,135:8225,136:710,137:8240,138:352,139:8249,140:338,142:381,145:8216,146:8217,147:8220,148:8221,149:8226,150:8211,151:8212,152:732,153:8482,154:353,155:8250,156:339,158:382,159:376},bP={__proto__:null,AElig:198,"AElig;":198,AMP:38,"AMP;":38,Aacute:193,"Aacute;":193,"Abreve;":258,Acirc:194,"Acirc;":194,"Acy;":1040,"Afr;":[55349,56580],Agrave:192,"Agrave;":192,"Alpha;":913,"Amacr;":256,"And;":10835,"Aogon;":260,"Aopf;":[55349,56632],"ApplyFunction;":8289,Aring:197,"Aring;":197,"Ascr;":[55349,56476],"Assign;":8788,Atilde:195,"Atilde;":195,Auml:196,"Auml;":196,"Backslash;":8726,"Barv;":10983,"Barwed;":8966,"Bcy;":1041,"Because;":8757,"Bernoullis;":8492,"Beta;":914,"Bfr;":[55349,56581],"Bopf;":[55349,56633],"Breve;":728,"Bscr;":8492,"Bumpeq;":8782,"CHcy;":1063,COPY:169,"COPY;":169,"Cacute;":262,"Cap;":8914,"CapitalDifferentialD;":8517,"Cayleys;":8493,"Ccaron;":268,Ccedil:199,"Ccedil;":199,"Ccirc;":264,"Cconint;":8752,"Cdot;":266,"Cedilla;":184,"CenterDot;":183,"Cfr;":8493,"Chi;":935,"CircleDot;":8857,"CircleMinus;":8854,"CirclePlus;":8853,"CircleTimes;":8855,"ClockwiseContourIntegral;":8754,"CloseCurlyDoubleQuote;":8221,"CloseCurlyQuote;":8217,"Colon;":8759,"Colone;":10868,"Congruent;":8801,"Conint;":8751,"ContourIntegral;":8750,"Copf;":8450,"Coproduct;":8720,"CounterClockwiseContourIntegral;":8755,"Cross;":10799,"Cscr;":[55349,56478],"Cup;":8915,"CupCap;":8781,"DD;":8517,"DDotrahd;":10513,"DJcy;":1026,"DScy;":1029,"DZcy;":1039,"Dagger;":8225,"Darr;":8609,"Dashv;":10980,"Dcaron;":270,"Dcy;":1044,"Del;":8711,"Delta;":916,"Dfr;":[55349,56583],"DiacriticalAcute;":180,"DiacriticalDot;":729,"DiacriticalDoubleAcute;":733,"DiacriticalGrave;":96,"DiacriticalTilde;":732,"Diamond;":8900,"DifferentialD;":8518,"Dopf;":[55349,56635],"Dot;":168,"DotDot;":8412,"DotEqual;":8784,"DoubleContourIntegral;":8751,"DoubleDot;":168,"DoubleDownArrow;":8659,"DoubleLeftArrow;":8656,"DoubleLeftRightArrow;":8660,"DoubleLeftTee;":10980,"DoubleLongLeftArrow;":10232,"DoubleLongLeftRightArrow;":10234,"DoubleLongRightArrow;":10233,"DoubleRightArrow;":8658,"DoubleRightTee;":8872,"DoubleUpArrow;":8657,"DoubleUpDownArrow;":8661,"DoubleVerticalBar;":8741,"DownArrow;":8595,"DownArrowBar;":10515,"DownArrowUpArrow;":8693,"DownBreve;":785,"DownLeftRightVector;":10576,"DownLeftTeeVector;":10590,"DownLeftVector;":8637,"DownLeftVectorBar;":10582,"DownRightTeeVector;":10591,"DownRightVector;":8641,"DownRightVectorBar;":10583,"DownTee;":8868,"DownTeeArrow;":8615,"Downarrow;":8659,"Dscr;":[55349,56479],"Dstrok;":272,"ENG;":330,ETH:208,"ETH;":208,Eacute:201,"Eacute;":201,"Ecaron;":282,Ecirc:202,"Ecirc;":202,"Ecy;":1069,"Edot;":278,"Efr;":[55349,56584],Egrave:200,"Egrave;":200,"Element;":8712,"Emacr;":274,"EmptySmallSquare;":9723,"EmptyVerySmallSquare;":9643,"Eogon;":280,"Eopf;":[55349,56636],"Epsilon;":917,"Equal;":10869,"EqualTilde;":8770,"Equilibrium;":8652,"Escr;":8496,"Esim;":10867,"Eta;":919,Euml:203,"Euml;":203,"Exists;":8707,"ExponentialE;":8519,"Fcy;":1060,"Ffr;":[55349,56585],"FilledSmallSquare;":9724,"FilledVerySmallSquare;":9642,"Fopf;":[55349,56637],"ForAll;":8704,"Fouriertrf;":8497,"Fscr;":8497,"GJcy;":1027,GT:62,"GT;":62,"Gamma;":915,"Gammad;":988,"Gbreve;":286,"Gcedil;":290,"Gcirc;":284,"Gcy;":1043,"Gdot;":288,"Gfr;":[55349,56586],"Gg;":8921,"Gopf;":[55349,56638],"GreaterEqual;":8805,"GreaterEqualLess;":8923,"GreaterFullEqual;":8807,"GreaterGreater;":10914,"GreaterLess;":8823,"GreaterSlantEqual;":10878,"GreaterTilde;":8819,"Gscr;":[55349,56482],"Gt;":8811,"HARDcy;":1066,"Hacek;":711,"Hat;":94,"Hcirc;":292,"Hfr;":8460,"HilbertSpace;":8459,"Hopf;":8461,"HorizontalLine;":9472,"Hscr;":8459,"Hstrok;":294,"HumpDownHump;":8782,"HumpEqual;":8783,"IEcy;":1045,"IJlig;":306,"IOcy;":1025,Iacute:205,"Iacute;":205,Icirc:206,"Icirc;":206,"Icy;":1048,"Idot;":304,"Ifr;":8465,Igrave:204,"Igrave;":204,"Im;":8465,"Imacr;":298,"ImaginaryI;":8520,"Implies;":8658,"Int;":8748,"Integral;":8747,"Intersection;":8898,"InvisibleComma;":8291,"InvisibleTimes;":8290,"Iogon;":302,"Iopf;":[55349,56640],"Iota;":921,"Iscr;":8464,"Itilde;":296,"Iukcy;":1030,Iuml:207,"Iuml;":207,"Jcirc;":308,"Jcy;":1049,"Jfr;":[55349,56589],"Jopf;":[55349,56641],"Jscr;":[55349,56485],"Jsercy;":1032,"Jukcy;":1028,"KHcy;":1061,"KJcy;":1036,"Kappa;":922,"Kcedil;":310,"Kcy;":1050,"Kfr;":[55349,56590],"Kopf;":[55349,56642],"Kscr;":[55349,56486],"LJcy;":1033,LT:60,"LT;":60,"Lacute;":313,"Lambda;":923,"Lang;":10218,"Laplacetrf;":8466,"Larr;":8606,"Lcaron;":317,"Lcedil;":315,"Lcy;":1051,"LeftAngleBracket;":10216,"LeftArrow;":8592,"LeftArrowBar;":8676,"LeftArrowRightArrow;":8646,"LeftCeiling;":8968,"LeftDoubleBracket;":10214,"LeftDownTeeVector;":10593,"LeftDownVector;":8643,"LeftDownVectorBar;":10585,"LeftFloor;":8970,"LeftRightArrow;":8596,"LeftRightVector;":10574,"LeftTee;":8867,"LeftTeeArrow;":8612,"LeftTeeVector;":10586,"LeftTriangle;":8882,"LeftTriangleBar;":10703,"LeftTriangleEqual;":8884,"LeftUpDownVector;":10577,"LeftUpTeeVector;":10592,"LeftUpVector;":8639,"LeftUpVectorBar;":10584,"LeftVector;":8636,"LeftVectorBar;":10578,"Leftarrow;":8656,"Leftrightarrow;":8660,"LessEqualGreater;":8922,"LessFullEqual;":8806,"LessGreater;":8822,"LessLess;":10913,"LessSlantEqual;":10877,"LessTilde;":8818,"Lfr;":[55349,56591],"Ll;":8920,"Lleftarrow;":8666,"Lmidot;":319,"LongLeftArrow;":10229,"LongLeftRightArrow;":10231,"LongRightArrow;":10230,"Longleftarrow;":10232,"Longleftrightarrow;":10234,"Longrightarrow;":10233,"Lopf;":[55349,56643],"LowerLeftArrow;":8601,"LowerRightArrow;":8600,"Lscr;":8466,"Lsh;":8624,"Lstrok;":321,"Lt;":8810,"Map;":10501,"Mcy;":1052,"MediumSpace;":8287,"Mellintrf;":8499,"Mfr;":[55349,56592],"MinusPlus;":8723,"Mopf;":[55349,56644],"Mscr;":8499,"Mu;":924,"NJcy;":1034,"Nacute;":323,"Ncaron;":327,"Ncedil;":325,"Ncy;":1053,"NegativeMediumSpace;":8203,"NegativeThickSpace;":8203,"NegativeThinSpace;":8203,"NegativeVeryThinSpace;":8203,"NestedGreaterGreater;":8811,"NestedLessLess;":8810,"NewLine;":10,"Nfr;":[55349,56593],"NoBreak;":8288,"NonBreakingSpace;":160,"Nopf;":8469,"Not;":10988,"NotCongruent;":8802,"NotCupCap;":8813,"NotDoubleVerticalBar;":8742,"NotElement;":8713,"NotEqual;":8800,"NotEqualTilde;":[8770,824],"NotExists;":8708,"NotGreater;":8815,"NotGreaterEqual;":8817,"NotGreaterFullEqual;":[8807,824],"NotGreaterGreater;":[8811,824],"NotGreaterLess;":8825,"NotGreaterSlantEqual;":[10878,824],"NotGreaterTilde;":8821,"NotHumpDownHump;":[8782,824],"NotHumpEqual;":[8783,824],"NotLeftTriangle;":8938,"NotLeftTriangleBar;":[10703,824],"NotLeftTriangleEqual;":8940,"NotLess;":8814,"NotLessEqual;":8816,"NotLessGreater;":8824,"NotLessLess;":[8810,824],"NotLessSlantEqual;":[10877,824],"NotLessTilde;":8820,"NotNestedGreaterGreater;":[10914,824],"NotNestedLessLess;":[10913,824],"NotPrecedes;":8832,"NotPrecedesEqual;":[10927,824],"NotPrecedesSlantEqual;":8928,"NotReverseElement;":8716,"NotRightTriangle;":8939,"NotRightTriangleBar;":[10704,824],"NotRightTriangleEqual;":8941,"NotSquareSubset;":[8847,824],"NotSquareSubsetEqual;":8930,"NotSquareSuperset;":[8848,824],"NotSquareSupersetEqual;":8931,"NotSubset;":[8834,8402],"NotSubsetEqual;":8840,"NotSucceeds;":8833,"NotSucceedsEqual;":[10928,824],"NotSucceedsSlantEqual;":8929,"NotSucceedsTilde;":[8831,824],"NotSuperset;":[8835,8402],"NotSupersetEqual;":8841,"NotTilde;":8769,"NotTildeEqual;":8772,"NotTildeFullEqual;":8775,"NotTildeTilde;":8777,"NotVerticalBar;":8740,"Nscr;":[55349,56489],Ntilde:209,"Ntilde;":209,"Nu;":925,"OElig;":338,Oacute:211,"Oacute;":211,Ocirc:212,"Ocirc;":212,"Ocy;":1054,"Odblac;":336,"Ofr;":[55349,56594],Ograve:210,"Ograve;":210,"Omacr;":332,"Omega;":937,"Omicron;":927,"Oopf;":[55349,56646],"OpenCurlyDoubleQuote;":8220,"OpenCurlyQuote;":8216,"Or;":10836,"Oscr;":[55349,56490],Oslash:216,"Oslash;":216,Otilde:213,"Otilde;":213,"Otimes;":10807,Ouml:214,"Ouml;":214,"OverBar;":8254,"OverBrace;":9182,"OverBracket;":9140,"OverParenthesis;":9180,"PartialD;":8706,"Pcy;":1055,"Pfr;":[55349,56595],"Phi;":934,"Pi;":928,"PlusMinus;":177,"Poincareplane;":8460,"Popf;":8473,"Pr;":10939,"Precedes;":8826,"PrecedesEqual;":10927,"PrecedesSlantEqual;":8828,"PrecedesTilde;":8830,"Prime;":8243,"Product;":8719,"Proportion;":8759,"Proportional;":8733,"Pscr;":[55349,56491],"Psi;":936,QUOT:34,"QUOT;":34,"Qfr;":[55349,56596],"Qopf;":8474,"Qscr;":[55349,56492],"RBarr;":10512,REG:174,"REG;":174,"Racute;":340,"Rang;":10219,"Rarr;":8608,"Rarrtl;":10518,"Rcaron;":344,"Rcedil;":342,"Rcy;":1056,"Re;":8476,"ReverseElement;":8715,"ReverseEquilibrium;":8651,"ReverseUpEquilibrium;":10607,"Rfr;":8476,"Rho;":929,"RightAngleBracket;":10217,"RightArrow;":8594,"RightArrowBar;":8677,"RightArrowLeftArrow;":8644,"RightCeiling;":8969,"RightDoubleBracket;":10215,"RightDownTeeVector;":10589,"RightDownVector;":8642,"RightDownVectorBar;":10581,"RightFloor;":8971,"RightTee;":8866,"RightTeeArrow;":8614,"RightTeeVector;":10587,"RightTriangle;":8883,"RightTriangleBar;":10704,"RightTriangleEqual;":8885,"RightUpDownVector;":10575,"RightUpTeeVector;":10588,"RightUpVector;":8638,"RightUpVectorBar;":10580,"RightVector;":8640,"RightVectorBar;":10579,"Rightarrow;":8658,"Ropf;":8477,"RoundImplies;":10608,"Rrightarrow;":8667,"Rscr;":8475,"Rsh;":8625,"RuleDelayed;":10740,"SHCHcy;":1065,"SHcy;":1064,"SOFTcy;":1068,"Sacute;":346,"Sc;":10940,"Scaron;":352,"Scedil;":350,"Scirc;":348,"Scy;":1057,"Sfr;":[55349,56598],"ShortDownArrow;":8595,"ShortLeftArrow;":8592,"ShortRightArrow;":8594,"ShortUpArrow;":8593,"Sigma;":931,"SmallCircle;":8728,"Sopf;":[55349,56650],"Sqrt;":8730,"Square;":9633,"SquareIntersection;":8851,"SquareSubset;":8847,"SquareSubsetEqual;":8849,"SquareSuperset;":8848,"SquareSupersetEqual;":8850,"SquareUnion;":8852,"Sscr;":[55349,56494],"Star;":8902,"Sub;":8912,"Subset;":8912,"SubsetEqual;":8838,"Succeeds;":8827,"SucceedsEqual;":10928,"SucceedsSlantEqual;":8829,"SucceedsTilde;":8831,"SuchThat;":8715,"Sum;":8721,"Sup;":8913,"Superset;":8835,"SupersetEqual;":8839,"Supset;":8913,THORN:222,"THORN;":222,"TRADE;":8482,"TSHcy;":1035,"TScy;":1062,"Tab;":9,"Tau;":932,"Tcaron;":356,"Tcedil;":354,"Tcy;":1058,"Tfr;":[55349,56599],"Therefore;":8756,"Theta;":920,"ThickSpace;":[8287,8202],"ThinSpace;":8201,"Tilde;":8764,"TildeEqual;":8771,"TildeFullEqual;":8773,"TildeTilde;":8776,"Topf;":[55349,56651],"TripleDot;":8411,"Tscr;":[55349,56495],"Tstrok;":358,Uacute:218,"Uacute;":218,"Uarr;":8607,"Uarrocir;":10569,"Ubrcy;":1038,"Ubreve;":364,Ucirc:219,"Ucirc;":219,"Ucy;":1059,"Udblac;":368,"Ufr;":[55349,56600],Ugrave:217,"Ugrave;":217,"Umacr;":362,"UnderBar;":95,"UnderBrace;":9183,"UnderBracket;":9141,"UnderParenthesis;":9181,"Union;":8899,"UnionPlus;":8846,"Uogon;":370,"Uopf;":[55349,56652],"UpArrow;":8593,"UpArrowBar;":10514,"UpArrowDownArrow;":8645,"UpDownArrow;":8597,"UpEquilibrium;":10606,"UpTee;":8869,"UpTeeArrow;":8613,"Uparrow;":8657,"Updownarrow;":8661,"UpperLeftArrow;":8598,"UpperRightArrow;":8599,"Upsi;":978,"Upsilon;":933,"Uring;":366,"Uscr;":[55349,56496],"Utilde;":360,Uuml:220,"Uuml;":220,"VDash;":8875,"Vbar;":10987,"Vcy;":1042,"Vdash;":8873,"Vdashl;":10982,"Vee;":8897,"Verbar;":8214,"Vert;":8214,"VerticalBar;":8739,"VerticalLine;":124,"VerticalSeparator;":10072,"VerticalTilde;":8768,"VeryThinSpace;":8202,"Vfr;":[55349,56601],"Vopf;":[55349,56653],"Vscr;":[55349,56497],"Vvdash;":8874,"Wcirc;":372,"Wedge;":8896,"Wfr;":[55349,56602],"Wopf;":[55349,56654],"Wscr;":[55349,56498],"Xfr;":[55349,56603],"Xi;":926,"Xopf;":[55349,56655],"Xscr;":[55349,56499],"YAcy;":1071,"YIcy;":1031,"YUcy;":1070,Yacute:221,"Yacute;":221,"Ycirc;":374,"Ycy;":1067,"Yfr;":[55349,56604],"Yopf;":[55349,56656],"Yscr;":[55349,56500],"Yuml;":376,"ZHcy;":1046,"Zacute;":377,"Zcaron;":381,"Zcy;":1047,"Zdot;":379,"ZeroWidthSpace;":8203,"Zeta;":918,"Zfr;":8488,"Zopf;":8484,"Zscr;":[55349,56501],aacute:225,"aacute;":225,"abreve;":259,"ac;":8766,"acE;":[8766,819],"acd;":8767,acirc:226,"acirc;":226,acute:180,"acute;":180,"acy;":1072,aelig:230,"aelig;":230,"af;":8289,"afr;":[55349,56606],agrave:224,"agrave;":224,"alefsym;":8501,"aleph;":8501,"alpha;":945,"amacr;":257,"amalg;":10815,amp:38,"amp;":38,"and;":8743,"andand;":10837,"andd;":10844,"andslope;":10840,"andv;":10842,"ang;":8736,"ange;":10660,"angle;":8736,"angmsd;":8737,"angmsdaa;":10664,"angmsdab;":10665,"angmsdac;":10666,"angmsdad;":10667,"angmsdae;":10668,"angmsdaf;":10669,"angmsdag;":10670,"angmsdah;":10671,"angrt;":8735,"angrtvb;":8894,"angrtvbd;":10653,"angsph;":8738,"angst;":197,"angzarr;":9084,"aogon;":261,"aopf;":[55349,56658],"ap;":8776,"apE;":10864,"apacir;":10863,"ape;":8778,"apid;":8779,"apos;":39,"approx;":8776,"approxeq;":8778,aring:229,"aring;":229,"ascr;":[55349,56502],"ast;":42,"asymp;":8776,"asympeq;":8781,atilde:227,"atilde;":227,auml:228,"auml;":228,"awconint;":8755,"awint;":10769,"bNot;":10989,"backcong;":8780,"backepsilon;":1014,"backprime;":8245,"backsim;":8765,"backsimeq;":8909,"barvee;":8893,"barwed;":8965,"barwedge;":8965,"bbrk;":9141,"bbrktbrk;":9142,"bcong;":8780,"bcy;":1073,"bdquo;":8222,"becaus;":8757,"because;":8757,"bemptyv;":10672,"bepsi;":1014,"bernou;":8492,"beta;":946,"beth;":8502,"between;":8812,"bfr;":[55349,56607],"bigcap;":8898,"bigcirc;":9711,"bigcup;":8899,"bigodot;":10752,"bigoplus;":10753,"bigotimes;":10754,"bigsqcup;":10758,"bigstar;":9733,"bigtriangledown;":9661,"bigtriangleup;":9651,"biguplus;":10756,"bigvee;":8897,"bigwedge;":8896,"bkarow;":10509,"blacklozenge;":10731,"blacksquare;":9642,"blacktriangle;":9652,"blacktriangledown;":9662,"blacktriangleleft;":9666,"blacktriangleright;":9656,"blank;":9251,"blk12;":9618,"blk14;":9617,"blk34;":9619,"block;":9608,"bne;":[61,8421],"bnequiv;":[8801,8421],"bnot;":8976,"bopf;":[55349,56659],"bot;":8869,"bottom;":8869,"bowtie;":8904,"boxDL;":9559,"boxDR;":9556,"boxDl;":9558,"boxDr;":9555,"boxH;":9552,"boxHD;":9574,"boxHU;":9577,"boxHd;":9572,"boxHu;":9575,"boxUL;":9565,"boxUR;":9562,"boxUl;":9564,"boxUr;":9561,"boxV;":9553,"boxVH;":9580,"boxVL;":9571,"boxVR;":9568,"boxVh;":9579,"boxVl;":9570,"boxVr;":9567,"boxbox;":10697,"boxdL;":9557,"boxdR;":9554,"boxdl;":9488,"boxdr;":9484,"boxh;":9472,"boxhD;":9573,"boxhU;":9576,"boxhd;":9516,"boxhu;":9524,"boxminus;":8863,"boxplus;":8862,"boxtimes;":8864,"boxuL;":9563,"boxuR;":9560,"boxul;":9496,"boxur;":9492,"boxv;":9474,"boxvH;":9578,"boxvL;":9569,"boxvR;":9566,"boxvh;":9532,"boxvl;":9508,"boxvr;":9500,"bprime;":8245,"breve;":728,brvbar:166,"brvbar;":166,"bscr;":[55349,56503],"bsemi;":8271,"bsim;":8765,"bsime;":8909,"bsol;":92,"bsolb;":10693,"bsolhsub;":10184,"bull;":8226,"bullet;":8226,"bump;":8782,"bumpE;":10926,"bumpe;":8783,"bumpeq;":8783,"cacute;":263,"cap;":8745,"capand;":10820,"capbrcup;":10825,"capcap;":10827,"capcup;":10823,"capdot;":10816,"caps;":[8745,65024],"caret;":8257,"caron;":711,"ccaps;":10829,"ccaron;":269,ccedil:231,"ccedil;":231,"ccirc;":265,"ccups;":10828,"ccupssm;":10832,"cdot;":267,cedil:184,"cedil;":184,"cemptyv;":10674,cent:162,"cent;":162,"centerdot;":183,"cfr;":[55349,56608],"chcy;":1095,"check;":10003,"checkmark;":10003,"chi;":967,"cir;":9675,"cirE;":10691,"circ;":710,"circeq;":8791,"circlearrowleft;":8634,"circlearrowright;":8635,"circledR;":174,"circledS;":9416,"circledast;":8859,"circledcirc;":8858,"circleddash;":8861,"cire;":8791,"cirfnint;":10768,"cirmid;":10991,"cirscir;":10690,"clubs;":9827,"clubsuit;":9827,"colon;":58,"colone;":8788,"coloneq;":8788,"comma;":44,"commat;":64,"comp;":8705,"compfn;":8728,"complement;":8705,"complexes;":8450,"cong;":8773,"congdot;":10861,"conint;":8750,"copf;":[55349,56660],"coprod;":8720,copy:169,"copy;":169,"copysr;":8471,"crarr;":8629,"cross;":10007,"cscr;":[55349,56504],"csub;":10959,"csube;":10961,"csup;":10960,"csupe;":10962,"ctdot;":8943,"cudarrl;":10552,"cudarrr;":10549,"cuepr;":8926,"cuesc;":8927,"cularr;":8630,"cularrp;":10557,"cup;":8746,"cupbrcap;":10824,"cupcap;":10822,"cupcup;":10826,"cupdot;":8845,"cupor;":10821,"cups;":[8746,65024],"curarr;":8631,"curarrm;":10556,"curlyeqprec;":8926,"curlyeqsucc;":8927,"curlyvee;":8910,"curlywedge;":8911,curren:164,"curren;":164,"curvearrowleft;":8630,"curvearrowright;":8631,"cuvee;":8910,"cuwed;":8911,"cwconint;":8754,"cwint;":8753,"cylcty;":9005,"dArr;":8659,"dHar;":10597,"dagger;":8224,"daleth;":8504,"darr;":8595,"dash;":8208,"dashv;":8867,"dbkarow;":10511,"dblac;":733,"dcaron;":271,"dcy;":1076,"dd;":8518,"ddagger;":8225,"ddarr;":8650,"ddotseq;":10871,deg:176,"deg;":176,"delta;":948,"demptyv;":10673,"dfisht;":10623,"dfr;":[55349,56609],"dharl;":8643,"dharr;":8642,"diam;":8900,"diamond;":8900,"diamondsuit;":9830,"diams;":9830,"die;":168,"digamma;":989,"disin;":8946,"div;":247,divide:247,"divide;":247,"divideontimes;":8903,"divonx;":8903,"djcy;":1106,"dlcorn;":8990,"dlcrop;":8973,"dollar;":36,"dopf;":[55349,56661],"dot;":729,"doteq;":8784,"doteqdot;":8785,"dotminus;":8760,"dotplus;":8724,"dotsquare;":8865,"doublebarwedge;":8966,"downarrow;":8595,"downdownarrows;":8650,"downharpoonleft;":8643,"downharpoonright;":8642,"drbkarow;":10512,"drcorn;":8991,"drcrop;":8972,"dscr;":[55349,56505],"dscy;":1109,"dsol;":10742,"dstrok;":273,"dtdot;":8945,"dtri;":9663,"dtrif;":9662,"duarr;":8693,"duhar;":10607,"dwangle;":10662,"dzcy;":1119,"dzigrarr;":10239,"eDDot;":10871,"eDot;":8785,eacute:233,"eacute;":233,"easter;":10862,"ecaron;":283,"ecir;":8790,ecirc:234,"ecirc;":234,"ecolon;":8789,"ecy;":1101,"edot;":279,"ee;":8519,"efDot;":8786,"efr;":[55349,56610],"eg;":10906,egrave:232,"egrave;":232,"egs;":10902,"egsdot;":10904,"el;":10905,"elinters;":9191,"ell;":8467,"els;":10901,"elsdot;":10903,"emacr;":275,"empty;":8709,"emptyset;":8709,"emptyv;":8709,"emsp13;":8196,"emsp14;":8197,"emsp;":8195,"eng;":331,"ensp;":8194,"eogon;":281,"eopf;":[55349,56662],"epar;":8917,"eparsl;":10723,"eplus;":10865,"epsi;":949,"epsilon;":949,"epsiv;":1013,"eqcirc;":8790,"eqcolon;":8789,"eqsim;":8770,"eqslantgtr;":10902,"eqslantless;":10901,"equals;":61,"equest;":8799,"equiv;":8801,"equivDD;":10872,"eqvparsl;":10725,"erDot;":8787,"erarr;":10609,"escr;":8495,"esdot;":8784,"esim;":8770,"eta;":951,eth:240,"eth;":240,euml:235,"euml;":235,"euro;":8364,"excl;":33,"exist;":8707,"expectation;":8496,"exponentiale;":8519,"fallingdotseq;":8786,"fcy;":1092,"female;":9792,"ffilig;":64259,"fflig;":64256,"ffllig;":64260,"ffr;":[55349,56611],"filig;":64257,"fjlig;":[102,106],"flat;":9837,"fllig;":64258,"fltns;":9649,"fnof;":402,"fopf;":[55349,56663],"forall;":8704,"fork;":8916,"forkv;":10969,"fpartint;":10765,frac12:189,"frac12;":189,"frac13;":8531,frac14:188,"frac14;":188,"frac15;":8533,"frac16;":8537,"frac18;":8539,"frac23;":8532,"frac25;":8534,frac34:190,"frac34;":190,"frac35;":8535,"frac38;":8540,"frac45;":8536,"frac56;":8538,"frac58;":8541,"frac78;":8542,"frasl;":8260,"frown;":8994,"fscr;":[55349,56507],"gE;":8807,"gEl;":10892,"gacute;":501,"gamma;":947,"gammad;":989,"gap;":10886,"gbreve;":287,"gcirc;":285,"gcy;":1075,"gdot;":289,"ge;":8805,"gel;":8923,"geq;":8805,"geqq;":8807,"geqslant;":10878,"ges;":10878,"gescc;":10921,"gesdot;":10880,"gesdoto;":10882,"gesdotol;":10884,"gesl;":[8923,65024],"gesles;":10900,"gfr;":[55349,56612],"gg;":8811,"ggg;":8921,"gimel;":8503,"gjcy;":1107,"gl;":8823,"glE;":10898,"gla;":10917,"glj;":10916,"gnE;":8809,"gnap;":10890,"gnapprox;":10890,"gne;":10888,"gneq;":10888,"gneqq;":8809,"gnsim;":8935,"gopf;":[55349,56664],"grave;":96,"gscr;":8458,"gsim;":8819,"gsime;":10894,"gsiml;":10896,gt:62,"gt;":62,"gtcc;":10919,"gtcir;":10874,"gtdot;":8919,"gtlPar;":10645,"gtquest;":10876,"gtrapprox;":10886,"gtrarr;":10616,"gtrdot;":8919,"gtreqless;":8923,"gtreqqless;":10892,"gtrless;":8823,"gtrsim;":8819,"gvertneqq;":[8809,65024],"gvnE;":[8809,65024],"hArr;":8660,"hairsp;":8202,"half;":189,"hamilt;":8459,"hardcy;":1098,"harr;":8596,"harrcir;":10568,"harrw;":8621,"hbar;":8463,"hcirc;":293,"hearts;":9829,"heartsuit;":9829,"hellip;":8230,"hercon;":8889,"hfr;":[55349,56613],"hksearow;":10533,"hkswarow;":10534,"hoarr;":8703,"homtht;":8763,"hookleftarrow;":8617,"hookrightarrow;":8618,"hopf;":[55349,56665],"horbar;":8213,"hscr;":[55349,56509],"hslash;":8463,"hstrok;":295,"hybull;":8259,"hyphen;":8208,iacute:237,"iacute;":237,"ic;":8291,icirc:238,"icirc;":238,"icy;":1080,"iecy;":1077,iexcl:161,"iexcl;":161,"iff;":8660,"ifr;":[55349,56614],igrave:236,"igrave;":236,"ii;":8520,"iiiint;":10764,"iiint;":8749,"iinfin;":10716,"iiota;":8489,"ijlig;":307,"imacr;":299,"image;":8465,"imagline;":8464,"imagpart;":8465,"imath;":305,"imof;":8887,"imped;":437,"in;":8712,"incare;":8453,"infin;":8734,"infintie;":10717,"inodot;":305,"int;":8747,"intcal;":8890,"integers;":8484,"intercal;":8890,"intlarhk;":10775,"intprod;":10812,"iocy;":1105,"iogon;":303,"iopf;":[55349,56666],"iota;":953,"iprod;":10812,iquest:191,"iquest;":191,"iscr;":[55349,56510],"isin;":8712,"isinE;":8953,"isindot;":8949,"isins;":8948,"isinsv;":8947,"isinv;":8712,"it;":8290,"itilde;":297,"iukcy;":1110,iuml:239,"iuml;":239,"jcirc;":309,"jcy;":1081,"jfr;":[55349,56615],"jmath;":567,"jopf;":[55349,56667],"jscr;":[55349,56511],"jsercy;":1112,"jukcy;":1108,"kappa;":954,"kappav;":1008,"kcedil;":311,"kcy;":1082,"kfr;":[55349,56616],"kgreen;":312,"khcy;":1093,"kjcy;":1116,"kopf;":[55349,56668],"kscr;":[55349,56512],"lAarr;":8666,"lArr;":8656,"lAtail;":10523,"lBarr;":10510,"lE;":8806,"lEg;":10891,"lHar;":10594,"lacute;":314,"laemptyv;":10676,"lagran;":8466,"lambda;":955,"lang;":10216,"langd;":10641,"langle;":10216,"lap;":10885,laquo:171,"laquo;":171,"larr;":8592,"larrb;":8676,"larrbfs;":10527,"larrfs;":10525,"larrhk;":8617,"larrlp;":8619,"larrpl;":10553,"larrsim;":10611,"larrtl;":8610,"lat;":10923,"latail;":10521,"late;":10925,"lates;":[10925,65024],"lbarr;":10508,"lbbrk;":10098,"lbrace;":123,"lbrack;":91,"lbrke;":10635,"lbrksld;":10639,"lbrkslu;":10637,"lcaron;":318,"lcedil;":316,"lceil;":8968,"lcub;":123,"lcy;":1083,"ldca;":10550,"ldquo;":8220,"ldquor;":8222,"ldrdhar;":10599,"ldrushar;":10571,"ldsh;":8626,"le;":8804,"leftarrow;":8592,"leftarrowtail;":8610,"leftharpoondown;":8637,"leftharpoonup;":8636,"leftleftarrows;":8647,"leftrightarrow;":8596,"leftrightarrows;":8646,"leftrightharpoons;":8651,"leftrightsquigarrow;":8621,"leftthreetimes;":8907,"leg;":8922,"leq;":8804,"leqq;":8806,"leqslant;":10877,"les;":10877,"lescc;":10920,"lesdot;":10879,"lesdoto;":10881,"lesdotor;":10883,"lesg;":[8922,65024],"lesges;":10899,"lessapprox;":10885,"lessdot;":8918,"lesseqgtr;":8922,"lesseqqgtr;":10891,"lessgtr;":8822,"lesssim;":8818,"lfisht;":10620,"lfloor;":8970,"lfr;":[55349,56617],"lg;":8822,"lgE;":10897,"lhard;":8637,"lharu;":8636,"lharul;":10602,"lhblk;":9604,"ljcy;":1113,"ll;":8810,"llarr;":8647,"llcorner;":8990,"llhard;":10603,"lltri;":9722,"lmidot;":320,"lmoust;":9136,"lmoustache;":9136,"lnE;":8808,"lnap;":10889,"lnapprox;":10889,"lne;":10887,"lneq;":10887,"lneqq;":8808,"lnsim;":8934,"loang;":10220,"loarr;":8701,"lobrk;":10214,"longleftarrow;":10229,"longleftrightarrow;":10231,"longmapsto;":10236,"longrightarrow;":10230,"looparrowleft;":8619,"looparrowright;":8620,"lopar;":10629,"lopf;":[55349,56669],"loplus;":10797,"lotimes;":10804,"lowast;":8727,"lowbar;":95,"loz;":9674,"lozenge;":9674,"lozf;":10731,"lpar;":40,"lparlt;":10643,"lrarr;":8646,"lrcorner;":8991,"lrhar;":8651,"lrhard;":10605,"lrm;":8206,"lrtri;":8895,"lsaquo;":8249,"lscr;":[55349,56513],"lsh;":8624,"lsim;":8818,"lsime;":10893,"lsimg;":10895,"lsqb;":91,"lsquo;":8216,"lsquor;":8218,"lstrok;":322,lt:60,"lt;":60,"ltcc;":10918,"ltcir;":10873,"ltdot;":8918,"lthree;":8907,"ltimes;":8905,"ltlarr;":10614,"ltquest;":10875,"ltrPar;":10646,"ltri;":9667,"ltrie;":8884,"ltrif;":9666,"lurdshar;":10570,"luruhar;":10598,"lvertneqq;":[8808,65024],"lvnE;":[8808,65024],"mDDot;":8762,macr:175,"macr;":175,"male;":9794,"malt;":10016,"maltese;":10016,"map;":8614,"mapsto;":8614,"mapstodown;":8615,"mapstoleft;":8612,"mapstoup;":8613,"marker;":9646,"mcomma;":10793,"mcy;":1084,"mdash;":8212,"measuredangle;":8737,"mfr;":[55349,56618],"mho;":8487,micro:181,"micro;":181,"mid;":8739,"midast;":42,"midcir;":10992,middot:183,"middot;":183,"minus;":8722,"minusb;":8863,"minusd;":8760,"minusdu;":10794,"mlcp;":10971,"mldr;":8230,"mnplus;":8723,"models;":8871,"mopf;":[55349,56670],"mp;":8723,"mscr;":[55349,56514],"mstpos;":8766,"mu;":956,"multimap;":8888,"mumap;":8888,"nGg;":[8921,824],"nGt;":[8811,8402],"nGtv;":[8811,824],"nLeftarrow;":8653,"nLeftrightarrow;":8654,"nLl;":[8920,824],"nLt;":[8810,8402],"nLtv;":[8810,824],"nRightarrow;":8655,"nVDash;":8879,"nVdash;":8878,"nabla;":8711,"nacute;":324,"nang;":[8736,8402],"nap;":8777,"napE;":[10864,824],"napid;":[8779,824],"napos;":329,"napprox;":8777,"natur;":9838,"natural;":9838,"naturals;":8469,nbsp:160,"nbsp;":160,"nbump;":[8782,824],"nbumpe;":[8783,824],"ncap;":10819,"ncaron;":328,"ncedil;":326,"ncong;":8775,"ncongdot;":[10861,824],"ncup;":10818,"ncy;":1085,"ndash;":8211,"ne;":8800,"neArr;":8663,"nearhk;":10532,"nearr;":8599,"nearrow;":8599,"nedot;":[8784,824],"nequiv;":8802,"nesear;":10536,"nesim;":[8770,824],"nexist;":8708,"nexists;":8708,"nfr;":[55349,56619],"ngE;":[8807,824],"nge;":8817,"ngeq;":8817,"ngeqq;":[8807,824],"ngeqslant;":[10878,824],"nges;":[10878,824],"ngsim;":8821,"ngt;":8815,"ngtr;":8815,"nhArr;":8654,"nharr;":8622,"nhpar;":10994,"ni;":8715,"nis;":8956,"nisd;":8954,"niv;":8715,"njcy;":1114,"nlArr;":8653,"nlE;":[8806,824],"nlarr;":8602,"nldr;":8229,"nle;":8816,"nleftarrow;":8602,"nleftrightarrow;":8622,"nleq;":8816,"nleqq;":[8806,824],"nleqslant;":[10877,824],"nles;":[10877,824],"nless;":8814,"nlsim;":8820,"nlt;":8814,"nltri;":8938,"nltrie;":8940,"nmid;":8740,"nopf;":[55349,56671],not:172,"not;":172,"notin;":8713,"notinE;":[8953,824],"notindot;":[8949,824],"notinva;":8713,"notinvb;":8951,"notinvc;":8950,"notni;":8716,"notniva;":8716,"notnivb;":8958,"notnivc;":8957,"npar;":8742,"nparallel;":8742,"nparsl;":[11005,8421],"npart;":[8706,824],"npolint;":10772,"npr;":8832,"nprcue;":8928,"npre;":[10927,824],"nprec;":8832,"npreceq;":[10927,824],"nrArr;":8655,"nrarr;":8603,"nrarrc;":[10547,824],"nrarrw;":[8605,824],"nrightarrow;":8603,"nrtri;":8939,"nrtrie;":8941,"nsc;":8833,"nsccue;":8929,"nsce;":[10928,824],"nscr;":[55349,56515],"nshortmid;":8740,"nshortparallel;":8742,"nsim;":8769,"nsime;":8772,"nsimeq;":8772,"nsmid;":8740,"nspar;":8742,"nsqsube;":8930,"nsqsupe;":8931,"nsub;":8836,"nsubE;":[10949,824],"nsube;":8840,"nsubset;":[8834,8402],"nsubseteq;":8840,"nsubseteqq;":[10949,824],"nsucc;":8833,"nsucceq;":[10928,824],"nsup;":8837,"nsupE;":[10950,824],"nsupe;":8841,"nsupset;":[8835,8402],"nsupseteq;":8841,"nsupseteqq;":[10950,824],"ntgl;":8825,ntilde:241,"ntilde;":241,"ntlg;":8824,"ntriangleleft;":8938,"ntrianglelefteq;":8940,"ntriangleright;":8939,"ntrianglerighteq;":8941,"nu;":957,"num;":35,"numero;":8470,"numsp;":8199,"nvDash;":8877,"nvHarr;":10500,"nvap;":[8781,8402],"nvdash;":8876,"nvge;":[8805,8402],"nvgt;":[62,8402],"nvinfin;":10718,"nvlArr;":10498,"nvle;":[8804,8402],"nvlt;":[60,8402],"nvltrie;":[8884,8402],"nvrArr;":10499,"nvrtrie;":[8885,8402],"nvsim;":[8764,8402],"nwArr;":8662,"nwarhk;":10531,"nwarr;":8598,"nwarrow;":8598,"nwnear;":10535,"oS;":9416,oacute:243,"oacute;":243,"oast;":8859,"ocir;":8858,ocirc:244,"ocirc;":244,"ocy;":1086,"odash;":8861,"odblac;":337,"odiv;":10808,"odot;":8857,"odsold;":10684,"oelig;":339,"ofcir;":10687,"ofr;":[55349,56620],"ogon;":731,ograve:242,"ograve;":242,"ogt;":10689,"ohbar;":10677,"ohm;":937,"oint;":8750,"olarr;":8634,"olcir;":10686,"olcross;":10683,"oline;":8254,"olt;":10688,"omacr;":333,"omega;":969,"omicron;":959,"omid;":10678,"ominus;":8854,"oopf;":[55349,56672],"opar;":10679,"operp;":10681,"oplus;":8853,"or;":8744,"orarr;":8635,"ord;":10845,"order;":8500,"orderof;":8500,ordf:170,"ordf;":170,ordm:186,"ordm;":186,"origof;":8886,"oror;":10838,"orslope;":10839,"orv;":10843,"oscr;":8500,oslash:248,"oslash;":248,"osol;":8856,otilde:245,"otilde;":245,"otimes;":8855,"otimesas;":10806,ouml:246,"ouml;":246,"ovbar;":9021,"par;":8741,para:182,"para;":182,"parallel;":8741,"parsim;":10995,"parsl;":11005,"part;":8706,"pcy;":1087,"percnt;":37,"period;":46,"permil;":8240,"perp;":8869,"pertenk;":8241,"pfr;":[55349,56621],"phi;":966,"phiv;":981,"phmmat;":8499,"phone;":9742,"pi;":960,"pitchfork;":8916,"piv;":982,"planck;":8463,"planckh;":8462,"plankv;":8463,"plus;":43,"plusacir;":10787,"plusb;":8862,"pluscir;":10786,"plusdo;":8724,"plusdu;":10789,"pluse;":10866,plusmn:177,"plusmn;":177,"plussim;":10790,"plustwo;":10791,"pm;":177,"pointint;":10773,"popf;":[55349,56673],pound:163,"pound;":163,"pr;":8826,"prE;":10931,"prap;":10935,"prcue;":8828,"pre;":10927,"prec;":8826,"precapprox;":10935,"preccurlyeq;":8828,"preceq;":10927,"precnapprox;":10937,"precneqq;":10933,"precnsim;":8936,"precsim;":8830,"prime;":8242,"primes;":8473,"prnE;":10933,"prnap;":10937,"prnsim;":8936,"prod;":8719,"profalar;":9006,"profline;":8978,"profsurf;":8979,"prop;":8733,"propto;":8733,"prsim;":8830,"prurel;":8880,"pscr;":[55349,56517],"psi;":968,"puncsp;":8200,"qfr;":[55349,56622],"qint;":10764,"qopf;":[55349,56674],"qprime;":8279,"qscr;":[55349,56518],"quaternions;":8461,"quatint;":10774,"quest;":63,"questeq;":8799,quot:34,"quot;":34,"rAarr;":8667,"rArr;":8658,"rAtail;":10524,"rBarr;":10511,"rHar;":10596,"race;":[8765,817],"racute;":341,"radic;":8730,"raemptyv;":10675,"rang;":10217,"rangd;":10642,"range;":10661,"rangle;":10217,raquo:187,"raquo;":187,"rarr;":8594,"rarrap;":10613,"rarrb;":8677,"rarrbfs;":10528,"rarrc;":10547,"rarrfs;":10526,"rarrhk;":8618,"rarrlp;":8620,"rarrpl;":10565,"rarrsim;":10612,"rarrtl;":8611,"rarrw;":8605,"ratail;":10522,"ratio;":8758,"rationals;":8474,"rbarr;":10509,"rbbrk;":10099,"rbrace;":125,"rbrack;":93,"rbrke;":10636,"rbrksld;":10638,"rbrkslu;":10640,"rcaron;":345,"rcedil;":343,"rceil;":8969,"rcub;":125,"rcy;":1088,"rdca;":10551,"rdldhar;":10601,"rdquo;":8221,"rdquor;":8221,"rdsh;":8627,"real;":8476,"realine;":8475,"realpart;":8476,"reals;":8477,"rect;":9645,reg:174,"reg;":174,"rfisht;":10621,"rfloor;":8971,"rfr;":[55349,56623],"rhard;":8641,"rharu;":8640,"rharul;":10604,"rho;":961,"rhov;":1009,"rightarrow;":8594,"rightarrowtail;":8611,"rightharpoondown;":8641,"rightharpoonup;":8640,"rightleftarrows;":8644,"rightleftharpoons;":8652,"rightrightarrows;":8649,"rightsquigarrow;":8605,"rightthreetimes;":8908,"ring;":730,"risingdotseq;":8787,"rlarr;":8644,"rlhar;":8652,"rlm;":8207,"rmoust;":9137,"rmoustache;":9137,"rnmid;":10990,"roang;":10221,"roarr;":8702,"robrk;":10215,"ropar;":10630,"ropf;":[55349,56675],"roplus;":10798,"rotimes;":10805,"rpar;":41,"rpargt;":10644,"rppolint;":10770,"rrarr;":8649,"rsaquo;":8250,"rscr;":[55349,56519],"rsh;":8625,"rsqb;":93,"rsquo;":8217,"rsquor;":8217,"rthree;":8908,"rtimes;":8906,"rtri;":9657,"rtrie;":8885,"rtrif;":9656,"rtriltri;":10702,"ruluhar;":10600,"rx;":8478,"sacute;":347,"sbquo;":8218,"sc;":8827,"scE;":10932,"scap;":10936,"scaron;":353,"sccue;":8829,"sce;":10928,"scedil;":351,"scirc;":349,"scnE;":10934,"scnap;":10938,"scnsim;":8937,"scpolint;":10771,"scsim;":8831,"scy;":1089,"sdot;":8901,"sdotb;":8865,"sdote;":10854,"seArr;":8664,"searhk;":10533,"searr;":8600,"searrow;":8600,sect:167,"sect;":167,"semi;":59,"seswar;":10537,"setminus;":8726,"setmn;":8726,"sext;":10038,"sfr;":[55349,56624],"sfrown;":8994,"sharp;":9839,"shchcy;":1097,"shcy;":1096,"shortmid;":8739,"shortparallel;":8741,shy:173,"shy;":173,"sigma;":963,"sigmaf;":962,"sigmav;":962,"sim;":8764,"simdot;":10858,"sime;":8771,"simeq;":8771,"simg;":10910,"simgE;":10912,"siml;":10909,"simlE;":10911,"simne;":8774,"simplus;":10788,"simrarr;":10610,"slarr;":8592,"smallsetminus;":8726,"smashp;":10803,"smeparsl;":10724,"smid;":8739,"smile;":8995,"smt;":10922,"smte;":10924,"smtes;":[10924,65024],"softcy;":1100,"sol;":47,"solb;":10692,"solbar;":9023,"sopf;":[55349,56676],"spades;":9824,"spadesuit;":9824,"spar;":8741,"sqcap;":8851,"sqcaps;":[8851,65024],"sqcup;":8852,"sqcups;":[8852,65024],"sqsub;":8847,"sqsube;":8849,"sqsubset;":8847,"sqsubseteq;":8849,"sqsup;":8848,"sqsupe;":8850,"sqsupset;":8848,"sqsupseteq;":8850,"squ;":9633,"square;":9633,"squarf;":9642,"squf;":9642,"srarr;":8594,"sscr;":[55349,56520],"ssetmn;":8726,"ssmile;":8995,"sstarf;":8902,"star;":9734,"starf;":9733,"straightepsilon;":1013,"straightphi;":981,"strns;":175,"sub;":8834,"subE;":10949,"subdot;":10941,"sube;":8838,"subedot;":10947,"submult;":10945,"subnE;":10955,"subne;":8842,"subplus;":10943,"subrarr;":10617,"subset;":8834,"subseteq;":8838,"subseteqq;":10949,"subsetneq;":8842,"subsetneqq;":10955,"subsim;":10951,"subsub;":10965,"subsup;":10963,"succ;":8827,"succapprox;":10936,"succcurlyeq;":8829,"succeq;":10928,"succnapprox;":10938,"succneqq;":10934,"succnsim;":8937,"succsim;":8831,"sum;":8721,"sung;":9834,sup1:185,"sup1;":185,sup2:178,"sup2;":178,sup3:179,"sup3;":179,"sup;":8835,"supE;":10950,"supdot;":10942,"supdsub;":10968,"supe;":8839,"supedot;":10948,"suphsol;":10185,"suphsub;":10967,"suplarr;":10619,"supmult;":10946,"supnE;":10956,"supne;":8843,"supplus;":10944,"supset;":8835,"supseteq;":8839,"supseteqq;":10950,"supsetneq;":8843,"supsetneqq;":10956,"supsim;":10952,"supsub;":10964,"supsup;":10966,"swArr;":8665,"swarhk;":10534,"swarr;":8601,"swarrow;":8601,"swnwar;":10538,szlig:223,"szlig;":223,"target;":8982,"tau;":964,"tbrk;":9140,"tcaron;":357,"tcedil;":355,"tcy;":1090,"tdot;":8411,"telrec;":8981,"tfr;":[55349,56625],"there4;":8756,"therefore;":8756,"theta;":952,"thetasym;":977,"thetav;":977,"thickapprox;":8776,"thicksim;":8764,"thinsp;":8201,"thkap;":8776,"thksim;":8764,thorn:254,"thorn;":254,"tilde;":732,times:215,"times;":215,"timesb;":8864,"timesbar;":10801,"timesd;":10800,"tint;":8749,"toea;":10536,"top;":8868,"topbot;":9014,"topcir;":10993,"topf;":[55349,56677],"topfork;":10970,"tosa;":10537,"tprime;":8244,"trade;":8482,"triangle;":9653,"triangledown;":9663,"triangleleft;":9667,"trianglelefteq;":8884,"triangleq;":8796,"triangleright;":9657,"trianglerighteq;":8885,"tridot;":9708,"trie;":8796,"triminus;":10810,"triplus;":10809,"trisb;":10701,"tritime;":10811,"trpezium;":9186,"tscr;":[55349,56521],"tscy;":1094,"tshcy;":1115,"tstrok;":359,"twixt;":8812,"twoheadleftarrow;":8606,"twoheadrightarrow;":8608,"uArr;":8657,"uHar;":10595,uacute:250,"uacute;":250,"uarr;":8593,"ubrcy;":1118,"ubreve;":365,ucirc:251,"ucirc;":251,"ucy;":1091,"udarr;":8645,"udblac;":369,"udhar;":10606,"ufisht;":10622,"ufr;":[55349,56626],ugrave:249,"ugrave;":249,"uharl;":8639,"uharr;":8638,"uhblk;":9600,"ulcorn;":8988,"ulcorner;":8988,"ulcrop;":8975,"ultri;":9720,"umacr;":363,uml:168,"uml;":168,"uogon;":371,"uopf;":[55349,56678],"uparrow;":8593,"updownarrow;":8597,"upharpoonleft;":8639,"upharpoonright;":8638,"uplus;":8846,"upsi;":965,"upsih;":978,"upsilon;":965,"upuparrows;":8648,"urcorn;":8989,"urcorner;":8989,"urcrop;":8974,"uring;":367,"urtri;":9721,"uscr;":[55349,56522],"utdot;":8944,"utilde;":361,"utri;":9653,"utrif;":9652,"uuarr;":8648,uuml:252,"uuml;":252,"uwangle;":10663,"vArr;":8661,"vBar;":10984,"vBarv;":10985,"vDash;":8872,"vangrt;":10652,"varepsilon;":1013,"varkappa;":1008,"varnothing;":8709,"varphi;":981,"varpi;":982,"varpropto;":8733,"varr;":8597,"varrho;":1009,"varsigma;":962,"varsubsetneq;":[8842,65024],"varsubsetneqq;":[10955,65024],"varsupsetneq;":[8843,65024],"varsupsetneqq;":[10956,65024],"vartheta;":977,"vartriangleleft;":8882,"vartriangleright;":8883,"vcy;":1074,"vdash;":8866,"vee;":8744,"veebar;":8891,"veeeq;":8794,"vellip;":8942,"verbar;":124,"vert;":124,"vfr;":[55349,56627],"vltri;":8882,"vnsub;":[8834,8402],"vnsup;":[8835,8402],"vopf;":[55349,56679],"vprop;":8733,"vrtri;":8883,"vscr;":[55349,56523],"vsubnE;":[10955,65024],"vsubne;":[8842,65024],"vsupnE;":[10956,65024],"vsupne;":[8843,65024],"vzigzag;":10650,"wcirc;":373,"wedbar;":10847,"wedge;":8743,"wedgeq;":8793,"weierp;":8472,"wfr;":[55349,56628],"wopf;":[55349,56680],"wp;":8472,"wr;":8768,"wreath;":8768,"wscr;":[55349,56524],"xcap;":8898,"xcirc;":9711,"xcup;":8899,"xdtri;":9661,"xfr;":[55349,56629],"xhArr;":10234,"xharr;":10231,"xi;":958,"xlArr;":10232,"xlarr;":10229,"xmap;":10236,"xnis;":8955,"xodot;":10752,"xopf;":[55349,56681],"xoplus;":10753,"xotime;":10754,"xrArr;":10233,"xrarr;":10230,"xscr;":[55349,56525],"xsqcup;":10758,"xuplus;":10756,"xutri;":9651,"xvee;":8897,"xwedge;":8896,yacute:253,"yacute;":253,"yacy;":1103,"ycirc;":375,"ycy;":1099,yen:165,"yen;":165,"yfr;":[55349,56630],"yicy;":1111,"yopf;":[55349,56682],"yscr;":[55349,56526],"yucy;":1102,yuml:255,"yuml;":255,"zacute;":378,"zcaron;":382,"zcy;":1079,"zdot;":380,"zeetrf;":8488,"zeta;":950,"zfr;":[55349,56631],"zhcy;":1078,"zigrarr;":8669,"zopf;":[55349,56683],"zscr;":[55349,56527],"zwj;":8205,"zwnj;":8204},Ij=/(A(?:Elig;?|MP;?|acute;?|breve;|c(?:irc;?|y;)|fr;|grave;?|lpha;|macr;|nd;|o(?:gon;|pf;)|pplyFunction;|ring;?|s(?:cr;|sign;)|tilde;?|uml;?)|B(?:a(?:ckslash;|r(?:v;|wed;))|cy;|e(?:cause;|rnoullis;|ta;)|fr;|opf;|reve;|scr;|umpeq;)|C(?:Hcy;|OPY;?|a(?:cute;|p(?:;|italDifferentialD;)|yleys;)|c(?:aron;|edil;?|irc;|onint;)|dot;|e(?:dilla;|nterDot;)|fr;|hi;|ircle(?:Dot;|Minus;|Plus;|Times;)|lo(?:ckwiseContourIntegral;|seCurly(?:DoubleQuote;|Quote;))|o(?:lon(?:;|e;)|n(?:gruent;|int;|tourIntegral;)|p(?:f;|roduct;)|unterClockwiseContourIntegral;)|ross;|scr;|up(?:;|Cap;))|D(?:D(?:;|otrahd;)|Jcy;|Scy;|Zcy;|a(?:gger;|rr;|shv;)|c(?:aron;|y;)|el(?:;|ta;)|fr;|i(?:a(?:critical(?:Acute;|Do(?:t;|ubleAcute;)|Grave;|Tilde;)|mond;)|fferentialD;)|o(?:pf;|t(?:;|Dot;|Equal;)|uble(?:ContourIntegral;|Do(?:t;|wnArrow;)|L(?:eft(?:Arrow;|RightArrow;|Tee;)|ong(?:Left(?:Arrow;|RightArrow;)|RightArrow;))|Right(?:Arrow;|Tee;)|Up(?:Arrow;|DownArrow;)|VerticalBar;)|wn(?:Arrow(?:;|Bar;|UpArrow;)|Breve;|Left(?:RightVector;|TeeVector;|Vector(?:;|Bar;))|Right(?:TeeVector;|Vector(?:;|Bar;))|Tee(?:;|Arrow;)|arrow;))|s(?:cr;|trok;))|E(?:NG;|TH;?|acute;?|c(?:aron;|irc;?|y;)|dot;|fr;|grave;?|lement;|m(?:acr;|pty(?:SmallSquare;|VerySmallSquare;))|o(?:gon;|pf;)|psilon;|qu(?:al(?:;|Tilde;)|ilibrium;)|s(?:cr;|im;)|ta;|uml;?|x(?:ists;|ponentialE;))|F(?:cy;|fr;|illed(?:SmallSquare;|VerySmallSquare;)|o(?:pf;|rAll;|uriertrf;)|scr;)|G(?:Jcy;|T;?|amma(?:;|d;)|breve;|c(?:edil;|irc;|y;)|dot;|fr;|g;|opf;|reater(?:Equal(?:;|Less;)|FullEqual;|Greater;|Less;|SlantEqual;|Tilde;)|scr;|t;)|H(?:ARDcy;|a(?:cek;|t;)|circ;|fr;|ilbertSpace;|o(?:pf;|rizontalLine;)|s(?:cr;|trok;)|ump(?:DownHump;|Equal;))|I(?:Ecy;|Jlig;|Ocy;|acute;?|c(?:irc;?|y;)|dot;|fr;|grave;?|m(?:;|a(?:cr;|ginaryI;)|plies;)|n(?:t(?:;|e(?:gral;|rsection;))|visible(?:Comma;|Times;))|o(?:gon;|pf;|ta;)|scr;|tilde;|u(?:kcy;|ml;?))|J(?:c(?:irc;|y;)|fr;|opf;|s(?:cr;|ercy;)|ukcy;)|K(?:Hcy;|Jcy;|appa;|c(?:edil;|y;)|fr;|opf;|scr;)|L(?:Jcy;|T;?|a(?:cute;|mbda;|ng;|placetrf;|rr;)|c(?:aron;|edil;|y;)|e(?:ft(?:A(?:ngleBracket;|rrow(?:;|Bar;|RightArrow;))|Ceiling;|Do(?:ubleBracket;|wn(?:TeeVector;|Vector(?:;|Bar;)))|Floor;|Right(?:Arrow;|Vector;)|T(?:ee(?:;|Arrow;|Vector;)|riangle(?:;|Bar;|Equal;))|Up(?:DownVector;|TeeVector;|Vector(?:;|Bar;))|Vector(?:;|Bar;)|arrow;|rightarrow;)|ss(?:EqualGreater;|FullEqual;|Greater;|Less;|SlantEqual;|Tilde;))|fr;|l(?:;|eftarrow;)|midot;|o(?:ng(?:Left(?:Arrow;|RightArrow;)|RightArrow;|left(?:arrow;|rightarrow;)|rightarrow;)|pf;|wer(?:LeftArrow;|RightArrow;))|s(?:cr;|h;|trok;)|t;)|M(?:ap;|cy;|e(?:diumSpace;|llintrf;)|fr;|inusPlus;|opf;|scr;|u;)|N(?:Jcy;|acute;|c(?:aron;|edil;|y;)|e(?:gative(?:MediumSpace;|Thi(?:ckSpace;|nSpace;)|VeryThinSpace;)|sted(?:GreaterGreater;|LessLess;)|wLine;)|fr;|o(?:Break;|nBreakingSpace;|pf;|t(?:;|C(?:ongruent;|upCap;)|DoubleVerticalBar;|E(?:lement;|qual(?:;|Tilde;)|xists;)|Greater(?:;|Equal;|FullEqual;|Greater;|Less;|SlantEqual;|Tilde;)|Hump(?:DownHump;|Equal;)|Le(?:ftTriangle(?:;|Bar;|Equal;)|ss(?:;|Equal;|Greater;|Less;|SlantEqual;|Tilde;))|Nested(?:GreaterGreater;|LessLess;)|Precedes(?:;|Equal;|SlantEqual;)|R(?:everseElement;|ightTriangle(?:;|Bar;|Equal;))|S(?:quareSu(?:bset(?:;|Equal;)|perset(?:;|Equal;))|u(?:bset(?:;|Equal;)|cceeds(?:;|Equal;|SlantEqual;|Tilde;)|perset(?:;|Equal;)))|Tilde(?:;|Equal;|FullEqual;|Tilde;)|VerticalBar;))|scr;|tilde;?|u;)|O(?:Elig;|acute;?|c(?:irc;?|y;)|dblac;|fr;|grave;?|m(?:acr;|ega;|icron;)|opf;|penCurly(?:DoubleQuote;|Quote;)|r;|s(?:cr;|lash;?)|ti(?:lde;?|mes;)|uml;?|ver(?:B(?:ar;|rac(?:e;|ket;))|Parenthesis;))|P(?:artialD;|cy;|fr;|hi;|i;|lusMinus;|o(?:incareplane;|pf;)|r(?:;|ecedes(?:;|Equal;|SlantEqual;|Tilde;)|ime;|o(?:duct;|portion(?:;|al;)))|s(?:cr;|i;))|Q(?:UOT;?|fr;|opf;|scr;)|R(?:Barr;|EG;?|a(?:cute;|ng;|rr(?:;|tl;))|c(?:aron;|edil;|y;)|e(?:;|verse(?:E(?:lement;|quilibrium;)|UpEquilibrium;))|fr;|ho;|ight(?:A(?:ngleBracket;|rrow(?:;|Bar;|LeftArrow;))|Ceiling;|Do(?:ubleBracket;|wn(?:TeeVector;|Vector(?:;|Bar;)))|Floor;|T(?:ee(?:;|Arrow;|Vector;)|riangle(?:;|Bar;|Equal;))|Up(?:DownVector;|TeeVector;|Vector(?:;|Bar;))|Vector(?:;|Bar;)|arrow;)|o(?:pf;|undImplies;)|rightarrow;|s(?:cr;|h;)|uleDelayed;)|S(?:H(?:CHcy;|cy;)|OFTcy;|acute;|c(?:;|aron;|edil;|irc;|y;)|fr;|hort(?:DownArrow;|LeftArrow;|RightArrow;|UpArrow;)|igma;|mallCircle;|opf;|q(?:rt;|uare(?:;|Intersection;|Su(?:bset(?:;|Equal;)|perset(?:;|Equal;))|Union;))|scr;|tar;|u(?:b(?:;|set(?:;|Equal;))|c(?:ceeds(?:;|Equal;|SlantEqual;|Tilde;)|hThat;)|m;|p(?:;|erset(?:;|Equal;)|set;)))|T(?:HORN;?|RADE;|S(?:Hcy;|cy;)|a(?:b;|u;)|c(?:aron;|edil;|y;)|fr;|h(?:e(?:refore;|ta;)|i(?:ckSpace;|nSpace;))|ilde(?:;|Equal;|FullEqual;|Tilde;)|opf;|ripleDot;|s(?:cr;|trok;))|U(?:a(?:cute;?|rr(?:;|ocir;))|br(?:cy;|eve;)|c(?:irc;?|y;)|dblac;|fr;|grave;?|macr;|n(?:der(?:B(?:ar;|rac(?:e;|ket;))|Parenthesis;)|ion(?:;|Plus;))|o(?:gon;|pf;)|p(?:Arrow(?:;|Bar;|DownArrow;)|DownArrow;|Equilibrium;|Tee(?:;|Arrow;)|arrow;|downarrow;|per(?:LeftArrow;|RightArrow;)|si(?:;|lon;))|ring;|scr;|tilde;|uml;?)|V(?:Dash;|bar;|cy;|dash(?:;|l;)|e(?:e;|r(?:bar;|t(?:;|ical(?:Bar;|Line;|Separator;|Tilde;))|yThinSpace;))|fr;|opf;|scr;|vdash;)|W(?:circ;|edge;|fr;|opf;|scr;)|X(?:fr;|i;|opf;|scr;)|Y(?:Acy;|Icy;|Ucy;|acute;?|c(?:irc;|y;)|fr;|opf;|scr;|uml;)|Z(?:Hcy;|acute;|c(?:aron;|y;)|dot;|e(?:roWidthSpace;|ta;)|fr;|opf;|scr;)|a(?:acute;?|breve;|c(?:;|E;|d;|irc;?|ute;?|y;)|elig;?|f(?:;|r;)|grave;?|l(?:e(?:fsym;|ph;)|pha;)|m(?:a(?:cr;|lg;)|p;?)|n(?:d(?:;|and;|d;|slope;|v;)|g(?:;|e;|le;|msd(?:;|a(?:a;|b;|c;|d;|e;|f;|g;|h;))|rt(?:;|vb(?:;|d;))|s(?:ph;|t;)|zarr;))|o(?:gon;|pf;)|p(?:;|E;|acir;|e;|id;|os;|prox(?:;|eq;))|ring;?|s(?:cr;|t;|ymp(?:;|eq;))|tilde;?|uml;?|w(?:conint;|int;))|b(?:Not;|a(?:ck(?:cong;|epsilon;|prime;|sim(?:;|eq;))|r(?:vee;|wed(?:;|ge;)))|brk(?:;|tbrk;)|c(?:ong;|y;)|dquo;|e(?:caus(?:;|e;)|mptyv;|psi;|rnou;|t(?:a;|h;|ween;))|fr;|ig(?:c(?:ap;|irc;|up;)|o(?:dot;|plus;|times;)|s(?:qcup;|tar;)|triangle(?:down;|up;)|uplus;|vee;|wedge;)|karow;|l(?:a(?:ck(?:lozenge;|square;|triangle(?:;|down;|left;|right;))|nk;)|k(?:1(?:2;|4;)|34;)|ock;)|n(?:e(?:;|quiv;)|ot;)|o(?:pf;|t(?:;|tom;)|wtie;|x(?:D(?:L;|R;|l;|r;)|H(?:;|D;|U;|d;|u;)|U(?:L;|R;|l;|r;)|V(?:;|H;|L;|R;|h;|l;|r;)|box;|d(?:L;|R;|l;|r;)|h(?:;|D;|U;|d;|u;)|minus;|plus;|times;|u(?:L;|R;|l;|r;)|v(?:;|H;|L;|R;|h;|l;|r;)))|prime;|r(?:eve;|vbar;?)|s(?:cr;|emi;|im(?:;|e;)|ol(?:;|b;|hsub;))|u(?:ll(?:;|et;)|mp(?:;|E;|e(?:;|q;))))|c(?:a(?:cute;|p(?:;|and;|brcup;|c(?:ap;|up;)|dot;|s;)|r(?:et;|on;))|c(?:a(?:ps;|ron;)|edil;?|irc;|ups(?:;|sm;))|dot;|e(?:dil;?|mptyv;|nt(?:;|erdot;|))|fr;|h(?:cy;|eck(?:;|mark;)|i;)|ir(?:;|E;|c(?:;|eq;|le(?:arrow(?:left;|right;)|d(?:R;|S;|ast;|circ;|dash;)))|e;|fnint;|mid;|scir;)|lubs(?:;|uit;)|o(?:lon(?:;|e(?:;|q;))|m(?:ma(?:;|t;)|p(?:;|fn;|le(?:ment;|xes;)))|n(?:g(?:;|dot;)|int;)|p(?:f;|rod;|y(?:;|sr;|)))|r(?:arr;|oss;)|s(?:cr;|u(?:b(?:;|e;)|p(?:;|e;)))|tdot;|u(?:darr(?:l;|r;)|e(?:pr;|sc;)|larr(?:;|p;)|p(?:;|brcap;|c(?:ap;|up;)|dot;|or;|s;)|r(?:arr(?:;|m;)|ly(?:eq(?:prec;|succ;)|vee;|wedge;)|ren;?|vearrow(?:left;|right;))|vee;|wed;)|w(?:conint;|int;)|ylcty;)|d(?:Arr;|Har;|a(?:gger;|leth;|rr;|sh(?:;|v;))|b(?:karow;|lac;)|c(?:aron;|y;)|d(?:;|a(?:gger;|rr;)|otseq;)|e(?:g;?|lta;|mptyv;)|f(?:isht;|r;)|har(?:l;|r;)|i(?:am(?:;|ond(?:;|suit;)|s;)|e;|gamma;|sin;|v(?:;|ide(?:;|ontimes;|)|onx;))|jcy;|lc(?:orn;|rop;)|o(?:llar;|pf;|t(?:;|eq(?:;|dot;)|minus;|plus;|square;)|ublebarwedge;|wn(?:arrow;|downarrows;|harpoon(?:left;|right;)))|r(?:bkarow;|c(?:orn;|rop;))|s(?:c(?:r;|y;)|ol;|trok;)|t(?:dot;|ri(?:;|f;))|u(?:arr;|har;)|wangle;|z(?:cy;|igrarr;))|e(?:D(?:Dot;|ot;)|a(?:cute;?|ster;)|c(?:aron;|ir(?:;|c;?)|olon;|y;)|dot;|e;|f(?:Dot;|r;)|g(?:;|rave;?|s(?:;|dot;))|l(?:;|inters;|l;|s(?:;|dot;))|m(?:acr;|pty(?:;|set;|v;)|sp(?:1(?:3;|4;)|;))|n(?:g;|sp;)|o(?:gon;|pf;)|p(?:ar(?:;|sl;)|lus;|si(?:;|lon;|v;))|q(?:c(?:irc;|olon;)|s(?:im;|lant(?:gtr;|less;))|u(?:als;|est;|iv(?:;|DD;))|vparsl;)|r(?:Dot;|arr;)|s(?:cr;|dot;|im;)|t(?:a;|h;?)|u(?:ml;?|ro;)|x(?:cl;|ist;|p(?:ectation;|onentiale;)))|f(?:allingdotseq;|cy;|emale;|f(?:ilig;|l(?:ig;|lig;)|r;)|ilig;|jlig;|l(?:at;|lig;|tns;)|nof;|o(?:pf;|r(?:all;|k(?:;|v;)))|partint;|r(?:a(?:c(?:1(?:2;?|3;|4;?|5;|6;|8;)|2(?:3;|5;)|3(?:4;?|5;|8;)|45;|5(?:6;|8;)|78;)|sl;)|own;)|scr;)|g(?:E(?:;|l;)|a(?:cute;|mma(?:;|d;)|p;)|breve;|c(?:irc;|y;)|dot;|e(?:;|l;|q(?:;|q;|slant;)|s(?:;|cc;|dot(?:;|o(?:;|l;))|l(?:;|es;)))|fr;|g(?:;|g;)|imel;|jcy;|l(?:;|E;|a;|j;)|n(?:E;|ap(?:;|prox;)|e(?:;|q(?:;|q;))|sim;)|opf;|rave;|s(?:cr;|im(?:;|e;|l;))|t(?:;|c(?:c;|ir;)|dot;|lPar;|quest;|r(?:a(?:pprox;|rr;)|dot;|eq(?:less;|qless;)|less;|sim;)|)|v(?:ertneqq;|nE;))|h(?:Arr;|a(?:irsp;|lf;|milt;|r(?:dcy;|r(?:;|cir;|w;)))|bar;|circ;|e(?:arts(?:;|uit;)|llip;|rcon;)|fr;|ks(?:earow;|warow;)|o(?:arr;|mtht;|ok(?:leftarrow;|rightarrow;)|pf;|rbar;)|s(?:cr;|lash;|trok;)|y(?:bull;|phen;))|i(?:acute;?|c(?:;|irc;?|y;)|e(?:cy;|xcl;?)|f(?:f;|r;)|grave;?|i(?:;|i(?:int;|nt;)|nfin;|ota;)|jlig;|m(?:a(?:cr;|g(?:e;|line;|part;)|th;)|of;|ped;)|n(?:;|care;|fin(?:;|tie;)|odot;|t(?:;|cal;|e(?:gers;|rcal;)|larhk;|prod;))|o(?:cy;|gon;|pf;|ta;)|prod;|quest;?|s(?:cr;|in(?:;|E;|dot;|s(?:;|v;)|v;))|t(?:;|ilde;)|u(?:kcy;|ml;?))|j(?:c(?:irc;|y;)|fr;|math;|opf;|s(?:cr;|ercy;)|ukcy;)|k(?:appa(?:;|v;)|c(?:edil;|y;)|fr;|green;|hcy;|jcy;|opf;|scr;)|l(?:A(?:arr;|rr;|tail;)|Barr;|E(?:;|g;)|Har;|a(?:cute;|emptyv;|gran;|mbda;|ng(?:;|d;|le;)|p;|quo;?|rr(?:;|b(?:;|fs;)|fs;|hk;|lp;|pl;|sim;|tl;)|t(?:;|ail;|e(?:;|s;)))|b(?:arr;|brk;|r(?:ac(?:e;|k;)|k(?:e;|sl(?:d;|u;))))|c(?:aron;|e(?:dil;|il;)|ub;|y;)|d(?:ca;|quo(?:;|r;)|r(?:dhar;|ushar;)|sh;)|e(?:;|ft(?:arrow(?:;|tail;)|harpoon(?:down;|up;)|leftarrows;|right(?:arrow(?:;|s;)|harpoons;|squigarrow;)|threetimes;)|g;|q(?:;|q;|slant;)|s(?:;|cc;|dot(?:;|o(?:;|r;))|g(?:;|es;)|s(?:approx;|dot;|eq(?:gtr;|qgtr;)|gtr;|sim;)))|f(?:isht;|loor;|r;)|g(?:;|E;)|h(?:ar(?:d;|u(?:;|l;))|blk;)|jcy;|l(?:;|arr;|corner;|hard;|tri;)|m(?:idot;|oust(?:;|ache;))|n(?:E;|ap(?:;|prox;)|e(?:;|q(?:;|q;))|sim;)|o(?:a(?:ng;|rr;)|brk;|ng(?:left(?:arrow;|rightarrow;)|mapsto;|rightarrow;)|oparrow(?:left;|right;)|p(?:ar;|f;|lus;)|times;|w(?:ast;|bar;)|z(?:;|enge;|f;))|par(?:;|lt;)|r(?:arr;|corner;|har(?:;|d;)|m;|tri;)|s(?:aquo;|cr;|h;|im(?:;|e;|g;)|q(?:b;|uo(?:;|r;))|trok;)|t(?:;|c(?:c;|ir;)|dot;|hree;|imes;|larr;|quest;|r(?:Par;|i(?:;|e;|f;))|)|ur(?:dshar;|uhar;)|v(?:ertneqq;|nE;))|m(?:DDot;|a(?:cr;?|l(?:e;|t(?:;|ese;))|p(?:;|sto(?:;|down;|left;|up;))|rker;)|c(?:omma;|y;)|dash;|easuredangle;|fr;|ho;|i(?:cro;?|d(?:;|ast;|cir;|dot;?)|nus(?:;|b;|d(?:;|u;)))|l(?:cp;|dr;)|nplus;|o(?:dels;|pf;)|p;|s(?:cr;|tpos;)|u(?:;|ltimap;|map;))|n(?:G(?:g;|t(?:;|v;))|L(?:eft(?:arrow;|rightarrow;)|l;|t(?:;|v;))|Rightarrow;|V(?:Dash;|dash;)|a(?:bla;|cute;|ng;|p(?:;|E;|id;|os;|prox;)|tur(?:;|al(?:;|s;)))|b(?:sp;?|ump(?:;|e;))|c(?:a(?:p;|ron;)|edil;|ong(?:;|dot;)|up;|y;)|dash;|e(?:;|Arr;|ar(?:hk;|r(?:;|ow;))|dot;|quiv;|s(?:ear;|im;)|xist(?:;|s;))|fr;|g(?:E;|e(?:;|q(?:;|q;|slant;)|s;)|sim;|t(?:;|r;))|h(?:Arr;|arr;|par;)|i(?:;|s(?:;|d;)|v;)|jcy;|l(?:Arr;|E;|arr;|dr;|e(?:;|ft(?:arrow;|rightarrow;)|q(?:;|q;|slant;)|s(?:;|s;))|sim;|t(?:;|ri(?:;|e;)))|mid;|o(?:pf;|t(?:;|in(?:;|E;|dot;|v(?:a;|b;|c;))|ni(?:;|v(?:a;|b;|c;))|))|p(?:ar(?:;|allel;|sl;|t;)|olint;|r(?:;|cue;|e(?:;|c(?:;|eq;))))|r(?:Arr;|arr(?:;|c;|w;)|ightarrow;|tri(?:;|e;))|s(?:c(?:;|cue;|e;|r;)|hort(?:mid;|parallel;)|im(?:;|e(?:;|q;))|mid;|par;|qsu(?:be;|pe;)|u(?:b(?:;|E;|e;|set(?:;|eq(?:;|q;)))|cc(?:;|eq;)|p(?:;|E;|e;|set(?:;|eq(?:;|q;)))))|t(?:gl;|ilde;?|lg;|riangle(?:left(?:;|eq;)|right(?:;|eq;)))|u(?:;|m(?:;|ero;|sp;))|v(?:Dash;|Harr;|ap;|dash;|g(?:e;|t;)|infin;|l(?:Arr;|e;|t(?:;|rie;))|r(?:Arr;|trie;)|sim;)|w(?:Arr;|ar(?:hk;|r(?:;|ow;))|near;))|o(?:S;|a(?:cute;?|st;)|c(?:ir(?:;|c;?)|y;)|d(?:ash;|blac;|iv;|ot;|sold;)|elig;|f(?:cir;|r;)|g(?:on;|rave;?|t;)|h(?:bar;|m;)|int;|l(?:arr;|c(?:ir;|ross;)|ine;|t;)|m(?:acr;|ega;|i(?:cron;|d;|nus;))|opf;|p(?:ar;|erp;|lus;)|r(?:;|arr;|d(?:;|er(?:;|of;)|f;?|m;?)|igof;|or;|slope;|v;)|s(?:cr;|lash;?|ol;)|ti(?:lde;?|mes(?:;|as;))|uml;?|vbar;)|p(?:ar(?:;|a(?:;|llel;|)|s(?:im;|l;)|t;)|cy;|er(?:cnt;|iod;|mil;|p;|tenk;)|fr;|h(?:i(?:;|v;)|mmat;|one;)|i(?:;|tchfork;|v;)|l(?:an(?:ck(?:;|h;)|kv;)|us(?:;|acir;|b;|cir;|d(?:o;|u;)|e;|mn;?|sim;|two;))|m;|o(?:intint;|pf;|und;?)|r(?:;|E;|ap;|cue;|e(?:;|c(?:;|approx;|curlyeq;|eq;|n(?:approx;|eqq;|sim;)|sim;))|ime(?:;|s;)|n(?:E;|ap;|sim;)|o(?:d;|f(?:alar;|line;|surf;)|p(?:;|to;))|sim;|urel;)|s(?:cr;|i;)|uncsp;)|q(?:fr;|int;|opf;|prime;|scr;|u(?:at(?:ernions;|int;)|est(?:;|eq;)|ot;?))|r(?:A(?:arr;|rr;|tail;)|Barr;|Har;|a(?:c(?:e;|ute;)|dic;|emptyv;|ng(?:;|d;|e;|le;)|quo;?|rr(?:;|ap;|b(?:;|fs;)|c;|fs;|hk;|lp;|pl;|sim;|tl;|w;)|t(?:ail;|io(?:;|nals;)))|b(?:arr;|brk;|r(?:ac(?:e;|k;)|k(?:e;|sl(?:d;|u;))))|c(?:aron;|e(?:dil;|il;)|ub;|y;)|d(?:ca;|ldhar;|quo(?:;|r;)|sh;)|e(?:al(?:;|ine;|part;|s;)|ct;|g;?)|f(?:isht;|loor;|r;)|h(?:ar(?:d;|u(?:;|l;))|o(?:;|v;))|i(?:ght(?:arrow(?:;|tail;)|harpoon(?:down;|up;)|left(?:arrows;|harpoons;)|rightarrows;|squigarrow;|threetimes;)|ng;|singdotseq;)|l(?:arr;|har;|m;)|moust(?:;|ache;)|nmid;|o(?:a(?:ng;|rr;)|brk;|p(?:ar;|f;|lus;)|times;)|p(?:ar(?:;|gt;)|polint;)|rarr;|s(?:aquo;|cr;|h;|q(?:b;|uo(?:;|r;)))|t(?:hree;|imes;|ri(?:;|e;|f;|ltri;))|uluhar;|x;)|s(?:acute;|bquo;|c(?:;|E;|a(?:p;|ron;)|cue;|e(?:;|dil;)|irc;|n(?:E;|ap;|sim;)|polint;|sim;|y;)|dot(?:;|b;|e;)|e(?:Arr;|ar(?:hk;|r(?:;|ow;))|ct;?|mi;|swar;|tm(?:inus;|n;)|xt;)|fr(?:;|own;)|h(?:arp;|c(?:hcy;|y;)|ort(?:mid;|parallel;)|y;?)|i(?:gma(?:;|f;|v;)|m(?:;|dot;|e(?:;|q;)|g(?:;|E;)|l(?:;|E;)|ne;|plus;|rarr;))|larr;|m(?:a(?:llsetminus;|shp;)|eparsl;|i(?:d;|le;)|t(?:;|e(?:;|s;)))|o(?:ftcy;|l(?:;|b(?:;|ar;))|pf;)|pa(?:des(?:;|uit;)|r;)|q(?:c(?:ap(?:;|s;)|up(?:;|s;))|su(?:b(?:;|e;|set(?:;|eq;))|p(?:;|e;|set(?:;|eq;)))|u(?:;|ar(?:e;|f;)|f;))|rarr;|s(?:cr;|etmn;|mile;|tarf;)|t(?:ar(?:;|f;)|r(?:aight(?:epsilon;|phi;)|ns;))|u(?:b(?:;|E;|dot;|e(?:;|dot;)|mult;|n(?:E;|e;)|plus;|rarr;|s(?:et(?:;|eq(?:;|q;)|neq(?:;|q;))|im;|u(?:b;|p;)))|cc(?:;|approx;|curlyeq;|eq;|n(?:approx;|eqq;|sim;)|sim;)|m;|ng;|p(?:1;?|2;?|3;?|;|E;|d(?:ot;|sub;)|e(?:;|dot;)|hs(?:ol;|ub;)|larr;|mult;|n(?:E;|e;)|plus;|s(?:et(?:;|eq(?:;|q;)|neq(?:;|q;))|im;|u(?:b;|p;))))|w(?:Arr;|ar(?:hk;|r(?:;|ow;))|nwar;)|zlig;?)|t(?:a(?:rget;|u;)|brk;|c(?:aron;|edil;|y;)|dot;|elrec;|fr;|h(?:e(?:re(?:4;|fore;)|ta(?:;|sym;|v;))|i(?:ck(?:approx;|sim;)|nsp;)|k(?:ap;|sim;)|orn;?)|i(?:lde;|mes(?:;|b(?:;|ar;)|d;|)|nt;)|o(?:ea;|p(?:;|bot;|cir;|f(?:;|ork;))|sa;)|prime;|r(?:ade;|i(?:angle(?:;|down;|left(?:;|eq;)|q;|right(?:;|eq;))|dot;|e;|minus;|plus;|sb;|time;)|pezium;)|s(?:c(?:r;|y;)|hcy;|trok;)|w(?:ixt;|ohead(?:leftarrow;|rightarrow;)))|u(?:Arr;|Har;|a(?:cute;?|rr;)|br(?:cy;|eve;)|c(?:irc;?|y;)|d(?:arr;|blac;|har;)|f(?:isht;|r;)|grave;?|h(?:ar(?:l;|r;)|blk;)|l(?:c(?:orn(?:;|er;)|rop;)|tri;)|m(?:acr;|l;?)|o(?:gon;|pf;)|p(?:arrow;|downarrow;|harpoon(?:left;|right;)|lus;|si(?:;|h;|lon;)|uparrows;)|r(?:c(?:orn(?:;|er;)|rop;)|ing;|tri;)|scr;|t(?:dot;|ilde;|ri(?:;|f;))|u(?:arr;|ml;?)|wangle;)|v(?:Arr;|Bar(?:;|v;)|Dash;|a(?:ngrt;|r(?:epsilon;|kappa;|nothing;|p(?:hi;|i;|ropto;)|r(?:;|ho;)|s(?:igma;|u(?:bsetneq(?:;|q;)|psetneq(?:;|q;)))|t(?:heta;|riangle(?:left;|right;))))|cy;|dash;|e(?:e(?:;|bar;|eq;)|llip;|r(?:bar;|t;))|fr;|ltri;|nsu(?:b;|p;)|opf;|prop;|rtri;|s(?:cr;|u(?:bn(?:E;|e;)|pn(?:E;|e;)))|zigzag;)|w(?:circ;|e(?:d(?:bar;|ge(?:;|q;))|ierp;)|fr;|opf;|p;|r(?:;|eath;)|scr;)|x(?:c(?:ap;|irc;|up;)|dtri;|fr;|h(?:Arr;|arr;)|i;|l(?:Arr;|arr;)|map;|nis;|o(?:dot;|p(?:f;|lus;)|time;)|r(?:Arr;|arr;)|s(?:cr;|qcup;)|u(?:plus;|tri;)|vee;|wedge;)|y(?:ac(?:ute;?|y;)|c(?:irc;|y;)|en;?|fr;|icy;|opf;|scr;|u(?:cy;|ml;?))|z(?:acute;|c(?:aron;|y;)|dot;|e(?:etrf;|ta;)|fr;|hcy;|igrarr;|opf;|scr;|w(?:j;|nj;)))|[\s\S]/g,vP=32,hP=/[^\r"&\u0000]+/g,gP=/[^\r'&\u0000]+/g,fP=/[^\r\t\n\f &>\u0000]+/g,mP=/[^\r\t\n\f \/>A-Z\u0000]+/g,uP=/[^\r\t\n\f \/=>A-Z\u0000]+/g,dP=/[^\]\r\u0000\uffff]*/g,pP=/[^&<\r\u0000\uffff]*/g,Aj=/[^<\r\u0000\uffff]*/g,cP=/[^\r\u0000\uffff]*/g,Sj=/(?:(\/)?([a-z]+)>)|[\s\S]/g,wj=/(?:([-a-z]+)[ \t\n\f]*=[ \t\n\f]*('[^'&\r\u0000]*'|"[^"&\r\u0000]*"|[^\t\n\r\f "&'\u0000>][^&> \t\n\r\f\u0000]*[ \t\n\f]))|[\s\S]/g,K6=/[^\x09\x0A\x0C\x0D\x20]/,$3=/[^\x09\x0A\x0C\x0D\x20]/g,lP=/[^\x00\x09\x0A\x0C\x0D\x20]/,e2=/^[\x09\x0A\x0C\x0D\x20]+/,Q6=/\x00/g;function L0($){var J=16384;if($.length<J)return String.fromCharCode.apply(String,$);var Z="";for(var Y=0;Y<$.length;Y+=J)Z+=String.fromCharCode.apply(String,$.slice(Y,Y+J));return Z}function oP($){var J=[];for(var Z=0;Z<$.length;Z++)J[Z]=$.charCodeAt(Z);return J}function d$($,J){if(typeof J==="string")return $.namespaceURI===X$.HTML&&$.localName===J;var Z=J[$.namespaceURI];return Z&&Z[$.localName]}function Rj($){return d$($,gj)}function Lj($){if(d$($,fj))return!0;if($.namespaceURI===X$.MATHML&&$.localName==="annotation-xml"){var J=$.getAttribute("encoding");if(J)J=J.toLowerCase();if(J==="text/html"||J==="application/xhtml+xml")return!0}return!1}function rP($){if($ in Dj)return Dj[$];else return $}function Nj($){for(var J=0,Z=$.length;J<Z;J++)if($[J][0]in Mj)$[J][0]=Mj[$[J][0]]}function yj($){for(var J=0,Z=$.length;J<Z;J++)if($[J][0]==="definitionurl"){$[J][0]="definitionURL";break}}function J3($){for(var J=0,Z=$.length;J<Z;J++)if($[J][0]in Cj)$[J].push(Cj[$[J][0]])}function Tj($,J){for(var Z=0,Y=$.length;Z<Y;Z++){var K=$[Z][0],Q=$[Z][1];if(J.hasAttribute(K))continue;J._setAttribute(K,Q)}}b$.ElementStack=function(){this.elements=[],this.top=null};b$.ElementStack.prototype.push=function($){this.elements.push($),this.top=$};b$.ElementStack.prototype.pop=function($){this.elements.pop(),this.top=this.elements[this.elements.length-1]};b$.ElementStack.prototype.popTag=function($){for(var J=this.elements.length-1;J>0;J--){var Z=this.elements[J];if(d$(Z,$))break}this.elements.length=J,this.top=this.elements[J-1]};b$.ElementStack.prototype.popElementType=function($){for(var J=this.elements.length-1;J>0;J--)if(this.elements[J]instanceof $)break;this.elements.length=J,this.top=this.elements[J-1]};b$.ElementStack.prototype.popElement=function($){for(var J=this.elements.length-1;J>0;J--)if(this.elements[J]===$)break;this.elements.length=J,this.top=this.elements[J-1]};b$.ElementStack.prototype.removeElement=function($){if(this.top===$)this.pop();else{var J=this.elements.lastIndexOf($);if(J!==-1)this.elements.splice(J,1)}};b$.ElementStack.prototype.clearToContext=function($){for(var J=this.elements.length-1;J>0;J--)if(d$(this.elements[J],$))break;this.elements.length=J+1,this.top=this.elements[J]};b$.ElementStack.prototype.contains=function($){return this.inSpecificScope($,Object.create(null))};b$.ElementStack.prototype.inSpecificScope=function($,J){for(var Z=this.elements.length-1;Z>=0;Z--){var Y=this.elements[Z];if(d$(Y,$))return!0;if(d$(Y,J))return!1}return!1};b$.ElementStack.prototype.elementInSpecificScope=function($,J){for(var Z=this.elements.length-1;Z>=0;Z--){var Y=this.elements[Z];if(Y===$)return!0;if(d$(Y,J))return!1}return!1};b$.ElementStack.prototype.elementTypeInSpecificScope=function($,J){for(var Z=this.elements.length-1;Z>=0;Z--){var Y=this.elements[Z];if(Y instanceof $)return!0;if(d$(Y,J))return!1}return!1};b$.ElementStack.prototype.inScope=function($){return this.inSpecificScope($,T1)};b$.ElementStack.prototype.elementInScope=function($){return this.elementInSpecificScope($,T1)};b$.ElementStack.prototype.elementTypeInScope=function($){return this.elementTypeInSpecificScope($,T1)};b$.ElementStack.prototype.inButtonScope=function($){return this.inSpecificScope($,K3)};b$.ElementStack.prototype.inListItemScope=function($){return this.inSpecificScope($,X6)};b$.ElementStack.prototype.inTableScope=function($){return this.inSpecificScope($,hj)};b$.ElementStack.prototype.inSelectScope=function($){for(var J=this.elements.length-1;J>=0;J--){var Z=this.elements[J];if(Z.namespaceURI!==X$.HTML)return!1;var Y=Z.localName;if(Y===$)return!0;if(Y!=="optgroup"&&Y!=="option")return!1}return!1};b$.ElementStack.prototype.generateImpliedEndTags=function($,J){var Z=J?bj:xj;for(var Y=this.elements.length-1;Y>=0;Y--){var K=this.elements[Y];if($&&d$(K,$))break;if(!d$(this.elements[Y],Z))break}this.elements.length=Y+1,this.top=this.elements[Y]};b$.ActiveFormattingElements=function(){this.list=[],this.attrs=[]};b$.ActiveFormattingElements.prototype.MARKER={localName:"|"};b$.ActiveFormattingElements.prototype.insertMarker=function(){this.list.push(this.MARKER),this.attrs.push(this.MARKER)};b$.ActiveFormattingElements.prototype.push=function($,J){var Z=0;for(var Y=this.list.length-1;Y>=0;Y--){if(this.list[Y]===this.MARKER)break;if(V($,this.list[Y],this.attrs[Y])){if(Z++,Z===3){this.list.splice(Y,1),this.attrs.splice(Y,1);break}}}this.list.push($);var K=[];for(var Q=0;Q<J.length;Q++)K[Q]=J[Q];this.attrs.push(K);function V(X,W,B){if(X.localName!==W.localName)return!1;if(X._numattrs!==B.length)return!1;for(var j=0,_=B.length;j<_;j++){var q=B[j][0],H=B[j][1];if(!X.hasAttribute(q))return!1;if(X.getAttribute(q)!==H)return!1}return!0}};b$.ActiveFormattingElements.prototype.clearToMarker=function(){for(var $=this.list.length-1;$>=0;$--)if(this.list[$]===this.MARKER)break;if($<0)$=0;this.list.length=$,this.attrs.length=$};b$.ActiveFormattingElements.prototype.findElementByTag=function($){for(var J=this.list.length-1;J>=0;J--){var Z=this.list[J];if(Z===this.MARKER)break;if(Z.localName===$)return Z}return null};b$.ActiveFormattingElements.prototype.indexOf=function($){return this.list.lastIndexOf($)};b$.ActiveFormattingElements.prototype.remove=function($){var J=this.list.lastIndexOf($);if(J!==-1)this.list.splice(J,1),this.attrs.splice(J,1)};b$.ActiveFormattingElements.prototype.replace=function($,J,Z){var Y=this.list.lastIndexOf($);if(Y!==-1)this.list[Y]=J,this.attrs[Y]=Z};b$.ActiveFormattingElements.prototype.insertAfter=function($,J){var Z=this.list.lastIndexOf($);if(Z!==-1)this.list.splice(Z,0,J),this.attrs.splice(Z,0,J)};function b$($,J,Z){var Y=null,K=0,Q=0,V=!1,X=!1,W=0,B=[],j="",_=!0,q=0,H=S$,C,M,I="",z="",P=[],D="",L="",R=[],N=[],x=[],b=[],v=[],m=!1,A=xB,u=null,r=[],S=new b$.ElementStack,T=new b$.ActiveFormattingElements,k=J!==void 0,A$=null,s=null,J$=!0;if(J)J$=J.ownerDocument._scripting_enabled;if(Z&&Z.scripting_enabled===!1)J$=!1;var Z$=!0,W$=!1,y$,Q$,y=[],n=!1,a=!1,c$={document:function(){return l},_asDocumentFragment:function(){var U=l.createDocumentFragment(),O=l.firstChild;while(O.hasChildNodes())U.appendChild(O.firstChild);return U},pause:function(){q++},resume:function(){q--,this.parse("")},parse:function(U,O,w){var E;if(q>0)return j+=U,!0;if(W===0){if(j)U=j+U,j="";if(O)U+="\uFFFF",V=!0;if(Y=U,K=U.length,Q=0,_){if(_=!1,Y.charCodeAt(0)===65279)Q=1}W++,E=g(w),j=Y.substring(Q,K),W--}else{if(W++,B.push(Y,K,Q),Y=U,K=U.length,Q=0,g(),E=!1,j=Y.substring(Q,K),Q=B.pop(),K=B.pop(),Y=B.pop(),j)Y=j+Y.substring(Q),K=Y.length,Q=0,j="";W--}return E}},l=new RP(!0,$);if(l._parser=c$,l._scripting_enabled=J$,J){if(J.ownerDocument._quirks)l._quirks=!0;if(J.ownerDocument._limitedQuirks)l._limitedQuirks=!0;if(J.namespaceURI===X$.HTML)switch(J.localName){case"title":case"textarea":H=J2;break;case"style":case"xmp":case"iframe":case"noembed":case"noframes":case"script":case"plaintext":H=w6;break}var d=l.createElement("html");if(l._appendChild(d),S.push(d),J instanceof u$.HTMLTemplateElement)r.push(v6);nJ();for(var Y$=J;Y$!==null;Y$=Y$.parentElement)if(Y$ instanceof u$.HTMLFormElement){s=Y$;break}}function g(U){var O,w,E,h;while(Q<K){if(q>0||U&&U())return!0;switch(typeof H.lookahead){case"undefined":if(O=Y.charCodeAt(Q++),X){if(X=!1,O===10){Q++;continue}}switch(O){case 13:if(Q<K){if(Y.charCodeAt(Q)===10)Q++}else X=!0;H(10);break;case 65535:if(V&&Q===K){H(Y6);break}default:H(O);break}break;case"number":O=Y.charCodeAt(Q);var c=H.lookahead,U$=!0;if(c<0)U$=!1,c=-c;if(c<K-Q)w=U$?Y.substring(Q,Q+c):null,h=!1;else if(V){if(w=U$?Y.substring(Q,K):null,h=!0,O===65535&&Q===K-1)O=Y6}else return!0;H(O,w,h);break;case"string":O=Y.charCodeAt(Q),E=H.lookahead;var w$=Y.indexOf(E,Q);if(w$!==-1)w=Y.substring(Q,w$+E.length),h=!1;else{if(!V)return!0;if(w=Y.substring(Q,K),O===65535&&Q===K-1)O=Y6;h=!0}H(O,w,h);break}}return!1}function t(U,O){for(var w=0;w<v.length;w++)if(v[w][0]===U)return;if(O!==void 0)v.push([U,O]);else v.push([U])}function C$(){wj.lastIndex=Q-1;var U=wj.exec(Y);if(!U)throw Error("should never happen");var O=U[1];if(!O)return!1;var w=U[2],E=w.length;switch(w[0]){case'"':case"'":w=w.substring(1,E-1),Q+=U[0].length-1,H=y6;break;default:H=A1,Q+=U[0].length-1,w=w.substring(0,E-1);break}for(var h=0;h<v.length;h++)if(v[h][0]===O)return!0;return v.push([O,w]),!0}function T$(){m=!1,I="",v.length=0}function M$(){m=!0,I="",v.length=0}function r$(){P.length=0}function K0(){D=""}function t1(){L=""}function n8(){R.length=0}function e1(){N.length=0,x=null,b=null}function C1(){x=[]}function M1(){b=[]}function h$(){W$=!0}function mH(){return S.top&&S.top.namespaceURI!=="http://www.w3.org/1999/xhtml"}function r0(U){return z===U}function VJ(){if(y.length>0){var U=L0(y);if(y.length=0,a){if(a=!1,U[0]===`
|
|
33
|
-
`)
|
|
34
|
-
`)U=U.substring(1);if(U.length===0)return}j0(cJ,U)}function k1(){if(m)j0(N$,I);else{var U=I;I="",z=U,j0(R0,U,v)}}function dH(){if(Q===K)return!1;Sj.lastIndex=Q;var U=Sj.exec(Y);if(!U)throw Error("should never happen");var O=U[2];if(!O)return!1;var w=U[1];if(w)Q+=O.length+2,j0(N$,O);else Q+=O.length+1,z=O,j0(R0,O,yP);return!0}function pH(){if(m)j0(N$,I,null,!0);else j0(R0,I,v,!0)}function g$(){j0(NP,L0(N),x?L0(x):void 0,b?L0(b):void 0)}function I$(){VJ(),A(Y6),l.modclock=1}var j0=c$.insertToken=function(O,w,E,h){VJ();var c=S.top;if(!c||c.namespaceURI===X$.HTML)A(O,w,E,h);else if(O!==R0&&O!==cJ)$K(O,w,E,h);else if(Rj(c)&&(O===cJ||O===R0&&w!=="mglyph"&&w!=="malignmark")||O===R0&&w==="svg"&&c.namespaceURI===X$.MATHML&&c.localName==="annotation-xml"||Lj(c))Q$=!0,A(O,w,E,h),Q$=!1;else $K(O,w,E,h)};function D1(U){var O=S.top;if($2&&d$(O,lJ))t8(function(w){return w.createComment(U)});else{if(O instanceof u$.HTMLTemplateElement)O=O.content;O._appendChild(O.ownerDocument.createComment(U))}}function P1(U){var O=S.top;if($2&&d$(O,lJ))t8(function(E){return E.createTextNode(U)});else{if(O instanceof u$.HTMLTemplateElement)O=O.content;var w=O.lastChild;if(w&&w.nodeType===eY.TEXT_NODE)w.appendData(U);else O._appendChild(O.ownerDocument.createTextNode(U))}}function sJ(U,O,w){var E=kj.createElement(U,O,null);if(w)for(var h=0,c=w.length;h<c;h++)E._setAttribute(w[h][0],w[h][1]);return E}var $2=!1;function q$(U,O){var w=a8(function(E){return sJ(E,U,O)});if(d$(w,vj))w._form=s;return w}function a8(U){var O;if($2&&d$(S.top,lJ))O=t8(U);else if(S.top instanceof u$.HTMLTemplateElement)O=U(S.top.content.ownerDocument),S.top.content._appendChild(O);else O=U(S.top.ownerDocument),S.top._appendChild(O);return S.push(O),O}function A6(U,O,w){return a8(function(E){var h=E._createElementNS(U,w,null);if(O)for(var c=0,U$=O.length;c<U$;c++){var w$=O[c];if(w$.length===2)h._setAttribute(w$[0],w$[1]);else h._setAttributeNS(w$[2],w$[0],w$[1])}return h})}function f3(U){for(var O=S.elements.length-1;O>=0;O--)if(S.elements[O]instanceof U)return O;return-1}function t8(U){var O,w,E=-1,h=-1,c;if(E=f3(u$.HTMLTableElement),h=f3(u$.HTMLTemplateElement),h>=0&&(E<0||h>E))O=S.elements[h];else if(E>=0)if(O=S.elements[E].parentNode,O)w=S.elements[E];else O=S.elements[E-1];if(!O)O=S.elements[0];if(O instanceof u$.HTMLTemplateElement)O=O.content;if(c=U(O.ownerDocument),c.nodeType===eY.TEXT_NODE){var U$;if(w)U$=w.previousSibling;else U$=O.lastChild;if(U$&&U$.nodeType===eY.TEXT_NODE)return U$.appendData(c.data),c}if(w)O.insertBefore(c,w);else O._appendChild(c);return c}function nJ(){var U=!1;for(var O=S.elements.length-1;O>=0;O--){var w=S.elements[O];if(O===0){if(U=!0,k)w=J}if(w.namespaceURI===X$.HTML){var E=w.localName;switch(E){case"select":for(var h=O;h>0;){var c=S.elements[--h];if(c instanceof u$.HTMLTemplateElement)break;else if(c instanceof u$.HTMLTableElement){A=H9;return}}A=E1;return;case"tr":A=eJ;return;case"tbody":case"tfoot":case"thead":A=I2;return;case"caption":A=b6;return;case"colgroup":A=U9;return;case"table":A=i0;return;case"template":A=r[r.length-1];return;case"body":A=j$;return;case"frameset":A=h6;return;case"html":if(A$===null)A=W9;else A=x6;return;default:if(!U){if(E==="head"){A=Q0;return}if(E==="td"||E==="th"){A=GJ;return}}}}if(U){A=j$;return}}}function e8(U,O){q$(U,O),H=aJ,u=A,A=j9}function cH(U,O){q$(U,O),H=J2,u=A,A=j9}function S6(U,O){return{elt:sJ(U,T.list[O].localName,T.attrs[O]),attrs:T.attrs[O]}}function y0(){if(T.list.length===0)return;var U=T.list[T.list.length-1];if(U===T.MARKER)return;if(S.elements.lastIndexOf(U)!==-1)return;for(var O=T.list.length-2;O>=0;O--){if(U=T.list[O],U===T.MARKER)break;if(S.elements.lastIndexOf(U)!==-1)break}for(O=O+1;O<T.list.length;O++){var w=a8(function(E){return S6(E,O).elt});T.list[O]=w}}var $9={localName:"BM"};function lH(U){if(d$(S.top,U)&&T.indexOf(S.top)===-1)return S.pop(),!0;var O=0;while(O<8){O++;var w=T.findElementByTag(U);if(!w)return!1;var E=S.elements.lastIndexOf(w);if(E===-1)return T.remove(w),!0;if(!S.elementInScope(w))return!0;var h=null,c;for(var U$=E+1;U$<S.elements.length;U$++)if(d$(S.elements[U$],$J)){h=S.elements[U$],c=U$;break}if(!h)return S.popElement(w),T.remove(w),!0;else{var w$=S.elements[E-1];T.insertAfter(w,$9);var J0=h,M0=h,s0=c,X1,A2=0;while(!0){if(A2++,J0=S.elements[--s0],J0===w)break;if(X1=T.indexOf(J0),A2>3&&X1!==-1)T.remove(J0),X1=-1;if(X1===-1){S.removeElement(J0);continue}var V2=S6(w$.ownerDocument,X1);if(T.replace(J0,V2.elt,V2.attrs),S.elements[s0]=V2.elt,J0=V2.elt,M0===h)T.remove($9),T.insertAfter(V2.elt,$9);J0._appendChild(M0),M0=J0}if($2&&d$(w$,lJ))t8(function(){return M0});else if(w$ instanceof u$.HTMLTemplateElement)w$.content._appendChild(M0);else w$._appendChild(M0);var $8=S6(h.ownerDocument,T.indexOf(w));while(h.hasChildNodes())$8.elt._appendChild(h.firstChild);h._appendChild($8.elt),T.remove(w),T.replace($9,$8.elt,$8.attrs),S.removeElement(w);var fB=S.elements.lastIndexOf(h);S.elements.splice(fB+1,0,$8.elt)}}return!0}function oH(){S.pop(),A=u;return}function M2(){if(delete l._parser,S.elements.length=0,l.defaultView)l.defaultView.dispatchEvent(new u$.Event("load",{}))}function V$(U,O){H=O,Q--}function S$(U){switch(U){case 38:C=S$,H=tJ;break;case 60:if(dH())break;H=rH;break;case 0:y.push(U),n=!0;break;case-1:I$();break;default:iJ(pP)||y.push(U);break}}function J2(U){switch(U){case 38:C=J2,H=tJ;break;case 60:H=sH;break;case 0:y.push(65533),n=!0;break;case-1:I$();break;default:y.push(U);break}}function aJ(U){switch(U){case 60:H=tH;break;case 0:y.push(65533);break;case-1:I$();break;default:iJ(Aj)||y.push(U);break}}function Z2(U){switch(U){case 60:H=JB;break;case 0:y.push(65533);break;case-1:I$();break;default:iJ(Aj)||y.push(U);break}}function w6(U){switch(U){case 0:y.push(65533);break;case-1:I$();break;default:iJ(cP)||y.push(U);break}}function rH(U){switch(U){case 33:H=p3;break;case 47:H=iH;break;case 65:case 66:case 67:case 68:case 69:case 70:case 71:case 72:case 73:case 74:case 75:case 76:case 77:case 78:case 79:case 80:case 81:case 82:case 83:case 84:case 85:case 86:case 87:case 88:case 89:case 90:case 97:case 98:case 99:case 100:case 101:case 102:case 103:case 104:case 105:case 106:case 107:case 108:case 109:case 110:case 111:case 112:case 113:case 114:case 115:case 116:case 117:case 118:case 119:case 120:case 121:case 122:T$(),V$(U,m3);break;case 63:V$(U,K9);break;default:y.push(60),V$(U,S$);break}}function iH(U){switch(U){case 65:case 66:case 67:case 68:case 69:case 70:case 71:case 72:case 73:case 74:case 75:case 76:case 77:case 78:case 79:case 80:case 81:case 82:case 83:case 84:case 85:case 86:case 87:case 88:case 89:case 90:case 97:case 98:case 99:case 100:case 101:case 102:case 103:case 104:case 105:case 106:case 107:case 108:case 109:case 110:case 111:case 112:case 113:case 114:case 115:case 116:case 117:case 118:case 119:case 120:case 121:case 122:M$(),V$(U,m3);break;case 62:H=S$;break;case-1:y.push(60),y.push(47),I$();break;default:V$(U,K9);break}}function m3(U){switch(U){case 9:case 10:case 12:case 32:H=A1;break;case 47:H=K2;break;case 62:H=S$,k1();break;case 65:case 66:case 67:case 68:case 69:case 70:case 71:case 72:case 73:case 74:case 75:case 76:case 77:case 78:case 79:case 80:case 81:case 82:case 83:case 84:case 85:case 86:case 87:case 88:case 89:case 90:I+=String.fromCharCode(U+32);break;case 0:I+=String.fromCharCode(65533);break;case-1:I$();break;default:I+=rJ(mP);break}}function sH(U){if(U===47)r$(),H=nH;else y.push(60),V$(U,J2)}function nH(U){switch(U){case 65:case 66:case 67:case 68:case 69:case 70:case 71:case 72:case 73:case 74:case 75:case 76:case 77:case 78:case 79:case 80:case 81:case 82:case 83:case 84:case 85:case 86:case 87:case 88:case 89:case 90:case 97:case 98:case 99:case 100:case 101:case 102:case 103:case 104:case 105:case 106:case 107:case 108:case 109:case 110:case 111:case 112:case 113:case 114:case 115:case 116:case 117:case 118:case 119:case 120:case 121:case 122:M$(),V$(U,aH);break;default:y.push(60),y.push(47),V$(U,J2);break}}function aH(U){switch(U){case 9:case 10:case 12:case 32:if(r0(I)){H=A1;return}break;case 47:if(r0(I)){H=K2;return}break;case 62:if(r0(I)){H=S$,k1();return}break;case 65:case 66:case 67:case 68:case 69:case 70:case 71:case 72:case 73:case 74:case 75:case 76:case 77:case 78:case 79:case 80:case 81:case 82:case 83:case 84:case 85:case 86:case 87:case 88:case 89:case 90:I+=String.fromCharCode(U+32),P.push(U);return;case 97:case 98:case 99:case 100:case 101:case 102:case 103:case 104:case 105:case 106:case 107:case 108:case 109:case 110:case 111:case 112:case 113:case 114:case 115:case 116:case 117:case 118:case 119:case 120:case 121:case 122:I+=String.fromCharCode(U),P.push(U);return;default:break}y.push(60),y.push(47),t2(y,P),V$(U,J2)}function tH(U){if(U===47)r$(),H=eH;else y.push(60),V$(U,aJ)}function eH(U){switch(U){case 65:case 66:case 67:case 68:case 69:case 70:case 71:case 72:case 73:case 74:case 75:case 76:case 77:case 78:case 79:case 80:case 81:case 82:case 83:case 84:case 85:case 86:case 87:case 88:case 89:case 90:case 97:case 98:case 99:case 100:case 101:case 102:case 103:case 104:case 105:case 106:case 107:case 108:case 109:case 110:case 111:case 112:case 113:case 114:case 115:case 116:case 117:case 118:case 119:case 120:case 121:case 122:M$(),V$(U,$B);break;default:y.push(60),y.push(47),V$(U,aJ);break}}function $B(U){switch(U){case 9:case 10:case 12:case 32:if(r0(I)){H=A1;return}break;case 47:if(r0(I)){H=K2;return}break;case 62:if(r0(I)){H=S$,k1();return}break;case 65:case 66:case 67:case 68:case 69:case 70:case 71:case 72:case 73:case 74:case 75:case 76:case 77:case 78:case 79:case 80:case 81:case 82:case 83:case 84:case 85:case 86:case 87:case 88:case 89:case 90:I+=String.fromCharCode(U+32),P.push(U);return;case 97:case 98:case 99:case 100:case 101:case 102:case 103:case 104:case 105:case 106:case 107:case 108:case 109:case 110:case 111:case 112:case 113:case 114:case 115:case 116:case 117:case 118:case 119:case 120:case 121:case 122:I+=String.fromCharCode(U),P.push(U);return;default:break}y.push(60),y.push(47),t2(y,P),V$(U,aJ)}function JB(U){switch(U){case 47:r$(),H=ZB;break;case 33:H=KB,y.push(60),y.push(33);break;default:y.push(60),V$(U,Z2);break}}function ZB(U){switch(U){case 65:case 66:case 67:case 68:case 69:case 70:case 71:case 72:case 73:case 74:case 75:case 76:case 77:case 78:case 79:case 80:case 81:case 82:case 83:case 84:case 85:case 86:case 87:case 88:case 89:case 90:case 97:case 98:case 99:case 100:case 101:case 102:case 103:case 104:case 105:case 106:case 107:case 108:case 109:case 110:case 111:case 112:case 113:case 114:case 115:case 116:case 117:case 118:case 119:case 120:case 121:case 122:M$(),V$(U,YB);break;default:y.push(60),y.push(47),V$(U,Z2);break}}function YB(U){switch(U){case 9:case 10:case 12:case 32:if(r0(I)){H=A1;return}break;case 47:if(r0(I)){H=K2;return}break;case 62:if(r0(I)){H=S$,k1();return}break;case 65:case 66:case 67:case 68:case 69:case 70:case 71:case 72:case 73:case 74:case 75:case 76:case 77:case 78:case 79:case 80:case 81:case 82:case 83:case 84:case 85:case 86:case 87:case 88:case 89:case 90:I+=String.fromCharCode(U+32),P.push(U);return;case 97:case 98:case 99:case 100:case 101:case 102:case 103:case 104:case 105:case 106:case 107:case 108:case 109:case 110:case 111:case 112:case 113:case 114:case 115:case 116:case 117:case 118:case 119:case 120:case 121:case 122:I+=String.fromCharCode(U),P.push(U);return;default:break}y.push(60),y.push(47),t2(y,P),V$(U,Z2)}function KB(U){if(U===45)H=QB,y.push(45);else V$(U,Z2)}function QB(U){if(U===45)H=u3,y.push(45);else V$(U,Z2)}function I1(U){switch(U){case 45:H=VB,y.push(45);break;case 60:H=R6;break;case 0:y.push(65533);break;case-1:I$();break;default:y.push(U);break}}function VB(U){switch(U){case 45:H=u3,y.push(45);break;case 60:H=R6;break;case 0:H=I1,y.push(65533);break;case-1:I$();break;default:H=I1,y.push(U);break}}function u3(U){switch(U){case 45:y.push(45);break;case 60:H=R6;break;case 62:H=Z2,y.push(62);break;case 0:H=I1,y.push(65533);break;case-1:I$();break;default:H=I1,y.push(U);break}}function R6(U){switch(U){case 47:r$(),H=GB;break;case 65:case 66:case 67:case 68:case 69:case 70:case 71:case 72:case 73:case 74:case 75:case 76:case 77:case 78:case 79:case 80:case 81:case 82:case 83:case 84:case 85:case 86:case 87:case 88:case 89:case 90:case 97:case 98:case 99:case 100:case 101:case 102:case 103:case 104:case 105:case 106:case 107:case 108:case 109:case 110:case 111:case 112:case 113:case 114:case 115:case 116:case 117:case 118:case 119:case 120:case 121:case 122:r$(),y.push(60),V$(U,WB);break;default:y.push(60),V$(U,I1);break}}function GB(U){switch(U){case 65:case 66:case 67:case 68:case 69:case 70:case 71:case 72:case 73:case 74:case 75:case 76:case 77:case 78:case 79:case 80:case 81:case 82:case 83:case 84:case 85:case 86:case 87:case 88:case 89:case 90:case 97:case 98:case 99:case 100:case 101:case 102:case 103:case 104:case 105:case 106:case 107:case 108:case 109:case 110:case 111:case 112:case 113:case 114:case 115:case 116:case 117:case 118:case 119:case 120:case 121:case 122:M$(),V$(U,XB);break;default:y.push(60),y.push(47),V$(U,I1);break}}function XB(U){switch(U){case 9:case 10:case 12:case 32:if(r0(I)){H=A1;return}break;case 47:if(r0(I)){H=K2;return}break;case 62:if(r0(I)){H=S$,k1();return}break;case 65:case 66:case 67:case 68:case 69:case 70:case 71:case 72:case 73:case 74:case 75:case 76:case 77:case 78:case 79:case 80:case 81:case 82:case 83:case 84:case 85:case 86:case 87:case 88:case 89:case 90:I+=String.fromCharCode(U+32),P.push(U);return;case 97:case 98:case 99:case 100:case 101:case 102:case 103:case 104:case 105:case 106:case 107:case 108:case 109:case 110:case 111:case 112:case 113:case 114:case 115:case 116:case 117:case 118:case 119:case 120:case 121:case 122:I+=String.fromCharCode(U),P.push(U);return;default:break}y.push(60),y.push(47),t2(y,P),V$(U,I1)}function WB(U){switch(U){case 9:case 10:case 12:case 32:case 47:case 62:if(L0(P)==="script")H=Y2;else H=I1;y.push(U);break;case 65:case 66:case 67:case 68:case 69:case 70:case 71:case 72:case 73:case 74:case 75:case 76:case 77:case 78:case 79:case 80:case 81:case 82:case 83:case 84:case 85:case 86:case 87:case 88:case 89:case 90:P.push(U+32),y.push(U);break;case 97:case 98:case 99:case 100:case 101:case 102:case 103:case 104:case 105:case 106:case 107:case 108:case 109:case 110:case 111:case 112:case 113:case 114:case 115:case 116:case 117:case 118:case 119:case 120:case 121:case 122:P.push(U),y.push(U);break;default:V$(U,I1);break}}function Y2(U){switch(U){case 45:H=jB,y.push(45);break;case 60:H=L6,y.push(60);break;case 0:y.push(65533);break;case-1:I$();break;default:y.push(U);break}}function jB(U){switch(U){case 45:H=UB,y.push(45);break;case 60:H=L6,y.push(60);break;case 0:H=Y2,y.push(65533);break;case-1:I$();break;default:H=Y2,y.push(U);break}}function UB(U){switch(U){case 45:y.push(45);break;case 60:H=L6,y.push(60);break;case 62:H=Z2,y.push(62);break;case 0:H=Y2,y.push(65533);break;case-1:I$();break;default:H=Y2,y.push(U);break}}function L6(U){if(U===47)r$(),H=HB,y.push(47);else V$(U,Y2)}function HB(U){switch(U){case 9:case 10:case 12:case 32:case 47:case 62:if(L0(P)==="script")H=I1;else H=Y2;y.push(U);break;case 65:case 66:case 67:case 68:case 69:case 70:case 71:case 72:case 73:case 74:case 75:case 76:case 77:case 78:case 79:case 80:case 81:case 82:case 83:case 84:case 85:case 86:case 87:case 88:case 89:case 90:P.push(U+32),y.push(U);break;case 97:case 98:case 99:case 100:case 101:case 102:case 103:case 104:case 105:case 106:case 107:case 108:case 109:case 110:case 111:case 112:case 113:case 114:case 115:case 116:case 117:case 118:case 119:case 120:case 121:case 122:P.push(U),y.push(U);break;default:V$(U,Y2);break}}function A1(U){switch(U){case 9:case 10:case 12:case 32:break;case 47:H=K2;break;case 62:H=S$,k1();break;case-1:I$();break;case 61:K0(),D+=String.fromCharCode(U),H=N6;break;default:if(C$())break;K0(),V$(U,N6);break}}function N6(U){switch(U){case 9:case 10:case 12:case 32:case 47:case 62:case-1:V$(U,BB);break;case 61:H=d3;break;case 65:case 66:case 67:case 68:case 69:case 70:case 71:case 72:case 73:case 74:case 75:case 76:case 77:case 78:case 79:case 80:case 81:case 82:case 83:case 84:case 85:case 86:case 87:case 88:case 89:case 90:D+=String.fromCharCode(U+32);break;case 0:D+=String.fromCharCode(65533);break;case 34:case 39:case 60:default:D+=rJ(uP);break}}function BB(U){switch(U){case 9:case 10:case 12:case 32:break;case 47:t(D),H=K2;break;case 61:H=d3;break;case 62:H=S$,t(D),k1();break;case-1:t(D),I$();break;default:t(D),K0(),V$(U,N6);break}}function d3(U){switch(U){case 9:case 10:case 12:case 32:break;case 34:t1(),H=J9;break;case 39:t1(),H=Z9;break;case 62:default:t1(),V$(U,Y9);break}}function J9(U){switch(U){case 34:t(D,L),H=y6;break;case 38:C=J9,H=tJ;break;case 0:L+=String.fromCharCode(65533);break;case-1:I$();break;case 10:L+=String.fromCharCode(U);break;default:L+=rJ(hP);break}}function Z9(U){switch(U){case 39:t(D,L),H=y6;break;case 38:C=Z9,H=tJ;break;case 0:L+=String.fromCharCode(65533);break;case-1:I$();break;case 10:L+=String.fromCharCode(U);break;default:L+=rJ(gP);break}}function Y9(U){switch(U){case 9:case 10:case 12:case 32:t(D,L),H=A1;break;case 38:C=Y9,H=tJ;break;case 62:t(D,L),H=S$,k1();break;case 0:L+=String.fromCharCode(65533);break;case-1:Q--,H=S$;break;case 34:case 39:case 60:case 61:case 96:default:L+=rJ(fP);break}}function y6(U){switch(U){case 9:case 10:case 12:case 32:H=A1;break;case 47:H=K2;break;case 62:H=S$,k1();break;case-1:I$();break;default:V$(U,A1);break}}function K2(U){switch(U){case 62:H=S$,pH(!0);break;case-1:I$();break;default:V$(U,A1);break}}function K9(U,O,w){var E=O.length;if(w)Q+=E-1;else Q+=E;var h=O.substring(0,E-1);h=h.replace(/\u0000/g,"\uFFFD"),h=h.replace(/\u000D\u000A/g,`
|
|
31
|
+
`;Z+=_,Z+="</"+Q+">"}break;case 3:case 4:var j;if(J.nodeType===1&&J.namespaceURI===s2.HTML)j=J.tagName;else j="";if(WW[j]||j==="NOSCRIPT"&&J.ownerDocument._scripting_enabled)Z+=$.data;else Z+=cM($.data);break;case 8:Z+="<!--"+_W($.data)+"-->";break;case 7:let H=OW($.data);Z+="<?"+$.target+" "+H+"?>";break;case 10:Z+="<!DOCTYPE "+$.name,Z+=">";break;default:BW.InvalidStateError()}return Z}});var P0=p((Pb,PW)=>{PW.exports=$0;var DW=$Y(),gZ=JY(),FW=ZY(),m$=X0();function $0(){DW.call(this),this.parentNode=null,this._nextSibling=this._previousSibling=this,this._index=void 0}var f0=$0.ELEMENT_NODE=1,YY=$0.ATTRIBUTE_NODE=2,fZ=$0.TEXT_NODE=3,sM=$0.CDATA_SECTION_NODE=4,nM=$0.ENTITY_REFERENCE_NODE=5,KY=$0.ENTITY_NODE=6,zW=$0.PROCESSING_INSTRUCTION_NODE=7,CW=$0.COMMENT_NODE=8,A8=$0.DOCUMENT_NODE=9,G1=$0.DOCUMENT_TYPE_NODE=10,H2=$0.DOCUMENT_FRAGMENT_NODE=11,QY=$0.NOTATION_NODE=12,VY=$0.DOCUMENT_POSITION_DISCONNECTED=1,GY=$0.DOCUMENT_POSITION_PRECEDING=2,XY=$0.DOCUMENT_POSITION_FOLLOWING=4,MW=$0.DOCUMENT_POSITION_CONTAINS=8,WY=$0.DOCUMENT_POSITION_CONTAINED_BY=16,jY=$0.DOCUMENT_POSITION_IMPLEMENTATION_SPECIFIC=32;$0.prototype=Object.create(DW.prototype,{baseURI:{get:m$.nyi},parentElement:{get:function(){return this.parentNode&&this.parentNode.nodeType===f0?this.parentNode:null}},hasChildNodes:{value:m$.shouldOverride},firstChild:{get:m$.shouldOverride},lastChild:{get:m$.shouldOverride},isConnected:{get:function(){let $=this;while($!=null){if($.nodeType===$0.DOCUMENT_NODE)return!0;if($=$.parentNode,$!=null&&$.nodeType===$0.DOCUMENT_FRAGMENT_NODE)$=$.host}return!1}},previousSibling:{get:function(){var $=this.parentNode;if(!$)return null;if(this===$.firstChild)return null;return this._previousSibling}},nextSibling:{get:function(){var $=this.parentNode,J=this._nextSibling;if(!$)return null;if(J===$.firstChild)return null;return J}},textContent:{get:function(){return null},set:function($){}},innerText:{get:function(){return null},set:function($){}},_countChildrenOfType:{value:function($){var J=0;for(var Z=this.firstChild;Z!==null;Z=Z.nextSibling)if(Z.nodeType===$)J++;return J}},_ensureInsertValid:{value:function(J,Z,Y){var K=this,Q,V;if(!J.nodeType)throw TypeError("not a node");switch(K.nodeType){case A8:case H2:case f0:break;default:m$.HierarchyRequestError()}if(J.isAncestor(K))m$.HierarchyRequestError();if(Z!==null||!Y){if(Z.parentNode!==K)m$.NotFoundError()}switch(J.nodeType){case H2:case G1:case f0:case fZ:case zW:case CW:break;default:m$.HierarchyRequestError()}if(K.nodeType===A8)switch(J.nodeType){case fZ:m$.HierarchyRequestError();break;case H2:if(J._countChildrenOfType(fZ)>0)m$.HierarchyRequestError();switch(J._countChildrenOfType(f0)){case 0:break;case 1:if(Z!==null){if(Y&&Z.nodeType===G1)m$.HierarchyRequestError();for(V=Z.nextSibling;V!==null;V=V.nextSibling)if(V.nodeType===G1)m$.HierarchyRequestError()}if(Q=K._countChildrenOfType(f0),Y){if(Q>0)m$.HierarchyRequestError()}else if(Q>1||Q===1&&Z.nodeType!==f0)m$.HierarchyRequestError();break;default:m$.HierarchyRequestError()}break;case f0:if(Z!==null){if(Y&&Z.nodeType===G1)m$.HierarchyRequestError();for(V=Z.nextSibling;V!==null;V=V.nextSibling)if(V.nodeType===G1)m$.HierarchyRequestError()}if(Q=K._countChildrenOfType(f0),Y){if(Q>0)m$.HierarchyRequestError()}else if(Q>1||Q===1&&Z.nodeType!==f0)m$.HierarchyRequestError();break;case G1:if(Z===null){if(K._countChildrenOfType(f0))m$.HierarchyRequestError()}else for(V=K.firstChild;V!==null;V=V.nextSibling){if(V===Z)break;if(V.nodeType===f0)m$.HierarchyRequestError()}if(Q=K._countChildrenOfType(G1),Y){if(Q>0)m$.HierarchyRequestError()}else if(Q>1||Q===1&&Z.nodeType!==G1)m$.HierarchyRequestError();break}else if(J.nodeType===G1)m$.HierarchyRequestError()}},insertBefore:{value:function(J,Z){var Y=this;Y._ensureInsertValid(J,Z,!0);var K=Z;if(K===J)K=J.nextSibling;return Y.doc.adoptNode(J),J._insertOrReplace(Y,K,!1),J}},appendChild:{value:function($){return this.insertBefore($,null)}},_appendChild:{value:function($){$._insertOrReplace(this,null,!1)}},removeChild:{value:function(J){var Z=this;if(!J.nodeType)throw TypeError("not a node");if(J.parentNode!==Z)m$.NotFoundError();return J.remove(),J}},replaceChild:{value:function(J,Z){var Y=this;if(Y._ensureInsertValid(J,Z,!1),J.doc!==Y.doc)Y.doc.adoptNode(J);return J._insertOrReplace(Y,Z,!0),Z}},contains:{value:function(J){if(J===null)return!1;if(this===J)return!0;return(this.compareDocumentPosition(J)&WY)!==0}},compareDocumentPosition:{value:function(J){if(this===J)return 0;if(this.doc!==J.doc||this.rooted!==J.rooted)return VY+jY;var Z=[],Y=[];for(var K=this;K!==null;K=K.parentNode)Z.push(K);for(K=J;K!==null;K=K.parentNode)Y.push(K);if(Z.reverse(),Y.reverse(),Z[0]!==Y[0])return VY+jY;K=Math.min(Z.length,Y.length);for(var Q=1;Q<K;Q++)if(Z[Q]!==Y[Q])if(Z[Q].index<Y[Q].index)return XY;else return GY;if(Z.length<Y.length)return XY+WY;else return GY+MW}},isSameNode:{value:function(J){return this===J}},isEqualNode:{value:function(J){if(!J)return!1;if(J.nodeType!==this.nodeType)return!1;if(!this.isEqual(J))return!1;for(var Z=this.firstChild,Y=J.firstChild;Z&&Y;Z=Z.nextSibling,Y=Y.nextSibling)if(!Z.isEqualNode(Y))return!1;return Z===null&&Y===null}},cloneNode:{value:function($){var J=this.clone();if($)for(var Z=this.firstChild;Z!==null;Z=Z.nextSibling)J._appendChild(Z.cloneNode(!0));return J}},lookupPrefix:{value:function(J){var Z;if(J===""||J===null||J===void 0)return null;switch(this.nodeType){case f0:return this._lookupNamespacePrefix(J,this);case A8:return Z=this.documentElement,Z?Z.lookupPrefix(J):null;case KY:case QY:case H2:case G1:return null;case YY:return Z=this.ownerElement,Z?Z.lookupPrefix(J):null;default:return Z=this.parentElement,Z?Z.lookupPrefix(J):null}}},lookupNamespaceURI:{value:function(J){if(J===""||J===void 0)J=null;var Z;switch(this.nodeType){case f0:return m$.shouldOverride();case A8:return Z=this.documentElement,Z?Z.lookupNamespaceURI(J):null;case KY:case QY:case G1:case H2:return null;case YY:return Z=this.ownerElement,Z?Z.lookupNamespaceURI(J):null;default:return Z=this.parentElement,Z?Z.lookupNamespaceURI(J):null}}},isDefaultNamespace:{value:function(J){if(J===""||J===void 0)J=null;var Z=this.lookupNamespaceURI(null);return Z===J}},index:{get:function(){var $=this.parentNode;if(this===$.firstChild)return 0;var J=$.childNodes;if(this._index===void 0||J[this._index]!==this){for(var Z=0;Z<J.length;Z++)J[Z]._index=Z;m$.assert(J[this._index]===this)}return this._index}},isAncestor:{value:function($){if(this.doc!==$.doc)return!1;if(this.rooted!==$.rooted)return!1;for(var J=$;J;J=J.parentNode)if(J===this)return!0;return!1}},ensureSameDoc:{value:function($){if($.ownerDocument===null)$.ownerDocument=this.doc;else if($.ownerDocument!==this.doc)m$.WrongDocumentError()}},removeChildren:{value:m$.shouldOverride},_insertOrReplace:{value:function(J,Z,Y){var K=this,Q,V;if(K.nodeType===H2&&K.rooted)m$.HierarchyRequestError();if(J._childNodes){if(Q=Z===null?J._childNodes.length:Z.index,K.parentNode===J){var X=K.index;if(X<Q)Q--}}if(Y){if(Z.rooted)Z.doc.mutateRemove(Z);Z.parentNode=null}var W=Z;if(W===null)W=J.firstChild;var _=K.rooted&&J.rooted;if(K.nodeType===H2){var j=[0,Y?1:0],H;for(var q=K.firstChild;q!==null;q=H)H=q.nextSibling,j.push(q),q.parentNode=J;var U=j.length;if(Y)gZ.replace(W,U>2?j[2]:null);else if(U>2&&W!==null)gZ.insertBefore(j[2],W);if(J._childNodes){j[0]=Z===null?J._childNodes.length:Z._index,J._childNodes.splice.apply(J._childNodes,j);for(V=2;V<U;V++)j[V]._index=j[0]+(V-2)}else if(J._firstChild===Z){if(U>2)J._firstChild=j[2];else if(Y)J._firstChild=null}if(K._childNodes)K._childNodes.length=0;else K._firstChild=null;if(J.rooted){J.modify();for(V=2;V<U;V++)J.doc.mutateInsert(j[V])}}else{if(Z===K)return;if(_)K._remove();else if(K.parentNode)K.remove();if(K.parentNode=J,Y){if(gZ.replace(W,K),J._childNodes)K._index=Q,J._childNodes[Q]=K;else if(J._firstChild===Z)J._firstChild=K}else{if(W!==null)gZ.insertBefore(K,W);if(J._childNodes)K._index=Q,J._childNodes.splice(Q,0,K);else if(J._firstChild===Z)J._firstChild=K}if(_)J.modify(),J.doc.mutateMove(K);else if(J.rooted)J.modify(),J.doc.mutateInsert(K)}}},lastModTime:{get:function(){if(!this._lastModTime)this._lastModTime=this.doc.modclock;return this._lastModTime}},modify:{value:function(){if(this.doc.modclock){var $=++this.doc.modclock;for(var J=this;J;J=J.parentElement)if(J._lastModTime)J._lastModTime=$}}},doc:{get:function(){return this.ownerDocument||this}},rooted:{get:function(){return!!this._nid}},normalize:{value:function(){var $;for(var J=this.firstChild;J!==null;J=$){if($=J.nextSibling,J.normalize)J.normalize();if(J.nodeType!==$0.TEXT_NODE)continue;if(J.nodeValue===""){this.removeChild(J);continue}var Z=J.previousSibling;if(Z===null)continue;else if(Z.nodeType===$0.TEXT_NODE)Z.appendData(J.nodeValue),this.removeChild(J)}}},serialize:{value:function(){if(this._innerHTML)return this._innerHTML;var $="";for(var J=this.firstChild;J!==null;J=J.nextSibling)$+=FW.serializeOne(J,this);return $}},outerHTML:{get:function(){return FW.serializeOne(this,{nodeType:0})},set:m$.nyi},ELEMENT_NODE:{value:f0},ATTRIBUTE_NODE:{value:YY},TEXT_NODE:{value:fZ},CDATA_SECTION_NODE:{value:sM},ENTITY_REFERENCE_NODE:{value:nM},ENTITY_NODE:{value:KY},PROCESSING_INSTRUCTION_NODE:{value:zW},COMMENT_NODE:{value:CW},DOCUMENT_NODE:{value:A8},DOCUMENT_TYPE_NODE:{value:G1},DOCUMENT_FRAGMENT_NODE:{value:H2},NOTATION_NODE:{value:QY},DOCUMENT_POSITION_DISCONNECTED:{value:VY},DOCUMENT_POSITION_PRECEDING:{value:GY},DOCUMENT_POSITION_FOLLOWING:{value:XY},DOCUMENT_POSITION_CONTAINS:{value:MW},DOCUMENT_POSITION_CONTAINED_BY:{value:WY},DOCUMENT_POSITION_IMPLEMENTATION_SPECIFIC:{value:jY}})});var AW=p((Ib,IW)=>{IW.exports=class extends Array{constructor(J){super(J&&J.length||0);if(J)for(var Z in J)this[Z]=J[Z]}item(J){return this[J]||null}}});var wW=p((Ab,SW)=>{function aM($){return this[$]||null}function tM($){if(!$)$=[];return $.item=aM,$}SW.exports=tM});var n2=p((Sb,RW)=>{var UY;try{UY=AW()}catch($){UY=wW()}RW.exports=UY});var mZ=p((wb,yW)=>{yW.exports=NW;var LW=P0(),eM=n2();function NW(){LW.call(this),this._firstChild=this._childNodes=null}NW.prototype=Object.create(LW.prototype,{hasChildNodes:{value:function(){if(this._childNodes)return this._childNodes.length>0;return this._firstChild!==null}},childNodes:{get:function(){return this._ensureChildNodes(),this._childNodes}},firstChild:{get:function(){if(this._childNodes)return this._childNodes.length===0?null:this._childNodes[0];return this._firstChild}},lastChild:{get:function(){var $=this._childNodes,J;if($)return $.length===0?null:$[$.length-1];if(J=this._firstChild,J===null)return null;return J._previousSibling}},_ensureChildNodes:{value:function(){if(this._childNodes)return;var $=this._firstChild,J=$,Z=this._childNodes=new eM;if($)do Z.push(J),J=J._nextSibling;while(J!==$);this._firstChild=null}},removeChildren:{value:function(){var J=this.rooted?this.ownerDocument:null,Z=this.firstChild,Y;while(Z!==null){if(Y=Z,Z=Y.nextSibling,J)J.mutateRemove(Y);Y.parentNode=null}if(this._childNodes)this._childNodes.length=0;else this._firstChild=null;this.modify()}}})});var uZ=p((XD)=>{XD.isValidName=VD;XD.isValidQName=GD;var $D=/^[_:A-Za-z][-.:\w]+$/,JD=/^([_A-Za-z][-.\w]+|[_A-Za-z][-.\w]+:[_A-Za-z][-.\w]+)$/,S8="_A-Za-z\xC0-\xD6\xD8-\xF6\xF8-\u02FF\u0370-\u037D\u037F-\u1FFF\u200C-\u200D\u2070-\u218F\u2C00-\u2FEF\u3001-\uD7FF\uF900-\uFDCF\uFDF0-\uFFFD",w8="-._A-Za-z0-9\xB7\xC0-\xD6\xD8-\xF6\xF8-\u02FF\u0300-\u037D\u037F-\u1FFF\u200C\u200D\u203F\u2040\u2070-\u218F\u2C00-\u2FEF\u3001-\uD7FF\uF900-\uFDCF\uFDF0-\uFFFD",a2="["+S8+"]["+w8+"]*",BY=S8+":",HY=w8+":",ZD=new RegExp("^["+BY+"]["+HY+"]*$"),YD=new RegExp("^("+a2+"|"+a2+":"+a2+")$"),TW=/[\uD800-\uDB7F\uDC00-\uDFFF]/,kW=/[\uD800-\uDB7F\uDC00-\uDFFF]/g,EW=/[\uD800-\uDB7F][\uDC00-\uDFFF]/g;S8+="\uD800-\uDB7F\uDC00-\uDFFF";w8+="\uD800-\uDB7F\uDC00-\uDFFF";a2="["+S8+"]["+w8+"]*";BY=S8+":";HY=w8+":";var KD=new RegExp("^["+BY+"]["+HY+"]*$"),QD=new RegExp("^("+a2+"|"+a2+":"+a2+")$");function VD($){if($D.test($))return!0;if(ZD.test($))return!0;if(!TW.test($))return!1;if(!KD.test($))return!1;var J=$.match(kW),Z=$.match(EW);return Z!==null&&2*Z.length===J.length}function GD($){if(JD.test($))return!0;if(YD.test($))return!0;if(!TW.test($))return!1;if(!QD.test($))return!1;var J=$.match(kW),Z=$.match(EW);return Z!==null&&2*Z.length===J.length}});var _Y=p((BD)=>{var xW=X0();BD.property=function($){if(Array.isArray($.type)){var J=Object.create(null);$.type.forEach(function(K){J[K.value||K]=K.alias||K});var Z=$.missing;if(Z===void 0)Z=null;var Y=$.invalid;if(Y===void 0)Y=Z;return{get:function(){var K=this._getattr($.name);if(K===null)return Z;if(K=J[K.toLowerCase()],K!==void 0)return K;if(Y!==null)return Y;return K},set:function(K){this._setattr($.name,K)}}}else if($.type===Boolean)return{get:function(){return this.hasAttribute($.name)},set:function(K){if(K)this._setattr($.name,"");else this.removeAttribute($.name)}};else if($.type===Number||$.type==="long"||$.type==="unsigned long"||$.type==="limited unsigned long with fallback")return UD($);else if(!$.type||$.type===String)return{get:function(){return this._getattr($.name)||""},set:function(K){if($.treatNullAsEmptyString&&K===null)K="";this._setattr($.name,K)}};else if(typeof $.type==="function")return $.type($.name,$);throw Error("Invalid attribute definition")};function UD($){var J;if(typeof $.default==="function")J=$.default;else if(typeof $.default==="number")J=function(){return $.default};else J=function(){xW.assert(!1,typeof $.default)};var Z=$.type==="unsigned long",Y=$.type==="long",K=$.type==="limited unsigned long with fallback",Q=$.min,V=$.max,X=$.setmin;if(Q===void 0){if(Z)Q=0;if(Y)Q=-2147483648;if(K)Q=1}if(V===void 0){if(Z||Y||K)V=2147483647}return{get:function(){var W=this._getattr($.name),_=$.float?parseFloat(W):parseInt(W,10);if(W===null||!isFinite(_)||Q!==void 0&&_<Q||V!==void 0&&_>V)return J.call(this);if(Z||Y||K){if(!/^[ \t\n\f\r]*[-+]?[0-9]/.test(W))return J.call(this);_=_|0}return _},set:function(W){if(!$.float)W=Math.floor(W);if(X!==void 0&&W<X)xW.IndexSizeError($.name+" set to "+W);if(Z)W=W<0||W>2147483647?J.call(this):W|0;else if(K)W=W<1||W>2147483647?J.call(this):W|0;else if(Y)W=W<-2147483648||W>2147483647?J.call(this):W|0;this._setattr($.name,String(W))}}}BD.registerChangeHandler=function($,J,Z){var Y=$.prototype;if(!Object.prototype.hasOwnProperty.call(Y,"_attributeChangeHandlers"))Y._attributeChangeHandlers=Object.create(Y._attributeChangeHandlers||null);Y._attributeChangeHandlers[J]=Z}});var hW=p((Nb,vW)=>{vW.exports=bW;var OD=P0();function bW($,J){this.root=$,this.filter=J,this.lastModTime=$.lastModTime,this.done=!1,this.cache=[],this.traverse()}bW.prototype=Object.create(Object.prototype,{length:{get:function(){if(this.checkcache(),!this.done)this.traverse();return this.cache.length}},item:{value:function($){if(this.checkcache(),!this.done&&$>=this.cache.length)this.traverse();return this.cache[$]}},checkcache:{value:function(){if(this.lastModTime!==this.root.lastModTime){for(var $=this.cache.length-1;$>=0;$--)this[$]=void 0;this.cache.length=0,this.done=!1,this.lastModTime=this.root.lastModTime}}},traverse:{value:function($){if($!==void 0)$++;var J;while((J=this.next())!==null)if(this[this.cache.length]=J,this.cache.push(J),$&&this.cache.length===$)return;this.done=!0}},next:{value:function(){var $=this.cache.length===0?this.root:this.cache[this.cache.length-1],J;if($.nodeType===OD.DOCUMENT_NODE)J=$.documentElement;else J=$.nextElement(this.root);while(J){if(this.filter(J))return J;J=J.nextElement(this.root)}return null}}})});var qY=p((yb,mW)=>{var OY=X0();mW.exports=fW;function fW($,J){this._getString=$,this._setString=J,this._length=0,this._lastStringValue="",this._update()}Object.defineProperties(fW.prototype,{length:{get:function(){return this._length}},item:{value:function($){var J=kJ(this);if($<0||$>=J.length)return null;return J[$]}},contains:{value:function($){$=String($);var J=kJ(this);return J.indexOf($)>-1}},add:{value:function(){var $=kJ(this);for(var J=0,Z=arguments.length;J<Z;J++){var Y=R8(arguments[J]);if($.indexOf(Y)<0)$.push(Y)}this._update($)}},remove:{value:function(){var $=kJ(this);for(var J=0,Z=arguments.length;J<Z;J++){var Y=R8(arguments[J]),K=$.indexOf(Y);if(K>-1)$.splice(K,1)}this._update($)}},toggle:{value:function(J,Z){if(J=R8(J),this.contains(J)){if(Z===void 0||Z===!1)return this.remove(J),!1;return!0}else{if(Z===void 0||Z===!0)return this.add(J),!0;return!1}}},replace:{value:function(J,Z){if(String(Z)==="")OY.SyntaxError();J=R8(J),Z=R8(Z);var Y=kJ(this),K=Y.indexOf(J);if(K<0)return!1;var Q=Y.indexOf(Z);if(Q<0)Y[K]=Z;else if(K<Q)Y[K]=Z,Y.splice(Q,1);else Y.splice(K,1);return this._update(Y),!0}},toString:{value:function(){return this._getString()}},value:{get:function(){return this._getString()},set:function($){this._setString($),this._update()}},_update:{value:function($){if($)gW(this,$),this._setString($.join(" ").trim());else gW(this,kJ(this));this._lastStringValue=this._getString()}}});function gW($,J){var Z=$._length,Y;$._length=J.length;for(Y=0;Y<J.length;Y++)$[Y]=J[Y];for(;Y<Z;Y++)$[Y]=void 0}function R8($){if($=String($),$==="")OY.SyntaxError();if(/[ \t\r\n\f]/.test($))OY.InvalidCharacterError();return $}function qD($){var J=$._length,Z=Array(J);for(var Y=0;Y<J;Y++)Z[Y]=$[Y];return Z}function kJ($){var J=$._getString();if(J===$._lastStringValue)return qD($);var Z=J.replace(/(^[ \t\r\n\f]+)|([ \t\r\n\f]+$)/g,"");if(Z==="")return[];else{var Y=Object.create(null);return Z.split(/[ \t\r\n\f]+/g).filter(function(K){var Q="$"+K;if(Y[Q])return!1;return Y[Q]=!0,!0})}}});var lZ=p((bJ,oW)=>{var dZ=Object.create(null,{location:{get:function(){throw Error("window.location is not supported.")}}}),FD=function($,J){return $.compareDocumentPosition(J)},zD=function($,J){return FD($,J)&2?1:-1},cZ=function($){while(($=$.nextSibling)&&$.nodeType!==1);return $},xJ=function($){while(($=$.previousSibling)&&$.nodeType!==1);return $},CD=function($){if($=$.firstChild)while($.nodeType!==1&&($=$.nextSibling));return $},MD=function($){if($=$.lastChild)while($.nodeType!==1&&($=$.previousSibling));return $},EJ=function($){if(!$.parentNode)return!1;var J=$.parentNode.nodeType;return J===1||J===9},uW=function($){if(!$)return $;var J=$[0];if(J==='"'||J==="'"){if($[$.length-1]===J)$=$.slice(1,-1);else $=$.slice(1);return $.replace(_$.str_escape,function(Z){var Y=/^\\(?:([0-9A-Fa-f]+)|([\r\n\f]+))/.exec(Z);if(!Y)return Z.slice(1);if(Y[2])return"";var K=parseInt(Y[1],16);return String.fromCodePoint?String.fromCodePoint(K):String.fromCharCode(K)})}else if(_$.ident.test($))return _2($);else return $},_2=function($){return $.replace(_$.escape,function(J){var Z=/^\\([0-9A-Fa-f]+)/.exec(J);if(!Z)return J[1];var Y=parseInt(Z[1],16);return String.fromCodePoint?String.fromCodePoint(Y):String.fromCharCode(Y)})},DD=function(){if(Array.prototype.indexOf)return Array.prototype.indexOf;return function($,J){var Z=this.length;while(Z--)if(this[Z]===J)return Z;return-1}}(),pW=function($,J){var Z=_$.inside.source.replace(/</g,$).replace(/>/g,J);return new RegExp(Z)},m0=function($,J,Z){return $=$.source,$=$.replace(J,Z.source||Z),new RegExp($)},dW=function($,J){return $.replace(/^(?:\w+:\/\/|\/+)/,"").replace(/(?:\/+|\/*#.*?)$/,"").split("/",J).join("/")},PD=function($,J){var Z=$.replace(/\s+/g,""),Y;if(Z==="even")Z="2n+0";else if(Z==="odd")Z="2n+1";else if(Z.indexOf("n")===-1)Z="0n"+Z;return Y=/^([+-])?(\d+)?n([+-])?(\d+)?$/.exec(Z),{group:Y[1]==="-"?-(Y[2]||1):+(Y[2]||1),offset:Y[4]?Y[3]==="-"?-Y[4]:+Y[4]:0}},FY=function($,J,Z){var Y=PD($),K=Y.group,Q=Y.offset,V=!Z?CD:MD,X=!Z?cZ:xJ;return function(W){if(!EJ(W))return;var _=V(W.parentNode),j=0;while(_){if(J(_,W))j++;if(_===W)return j-=Q,K&&j?j%K===0&&j<0===K<0:!j;_=X(_)}}},z0={"*":function(){return function(){return!0}}(),type:function($){return $=$.toLowerCase(),function(J){return J.nodeName.toLowerCase()===$}},attr:function($,J,Z,Y){return J=cW[J],function(K){var Q;switch($){case"for":Q=K.htmlFor;break;case"class":if(Q=K.className,Q===""&&K.getAttribute("class")==null)Q=null;break;case"href":case"src":Q=K.getAttribute($,2);break;case"title":Q=K.getAttribute("title")||null;break;case"id":case"lang":case"dir":case"accessKey":case"hidden":case"tabIndex":case"style":if(K.getAttribute){Q=K.getAttribute($);break}default:if(K.hasAttribute&&!K.hasAttribute($))break;Q=K[$]!=null?K[$]:K.getAttribute&&K.getAttribute($);break}if(Q==null)return;if(Q=Q+"",Y)Q=Q.toLowerCase(),Z=Z.toLowerCase();return J(Q,Z)}},":first-child":function($){return!xJ($)&&EJ($)},":last-child":function($){return!cZ($)&&EJ($)},":only-child":function($){return!xJ($)&&!cZ($)&&EJ($)},":nth-child":function($,J){return FY($,function(){return!0},J)},":nth-last-child":function($){return z0[":nth-child"]($,!0)},":root":function($){return $.ownerDocument.documentElement===$},":empty":function($){return!$.firstChild},":not":function($){var J=CY($);return function(Z){return!J(Z)}},":first-of-type":function($){if(!EJ($))return;var J=$.nodeName;while($=xJ($))if($.nodeName===J)return;return!0},":last-of-type":function($){if(!EJ($))return;var J=$.nodeName;while($=cZ($))if($.nodeName===J)return;return!0},":only-of-type":function($){return z0[":first-of-type"]($)&&z0[":last-of-type"]($)},":nth-of-type":function($,J){return FY($,function(Z,Y){return Z.nodeName===Y.nodeName},J)},":nth-last-of-type":function($){return z0[":nth-of-type"]($,!0)},":checked":function($){return!!($.checked||$.selected)},":indeterminate":function($){return!z0[":checked"]($)},":enabled":function($){return!$.disabled&&$.type!=="hidden"},":disabled":function($){return!!$.disabled},":target":function($){return $.id===dZ.location.hash.substring(1)},":focus":function($){return $===$.ownerDocument.activeElement},":is":function($){return CY($)},":matches":function($){return z0[":is"]($)},":nth-match":function($,J){var Z=$.split(/\s*,\s*/),Y=Z.shift(),K=CY(Z.join(","));return FY(Y,K,J)},":nth-last-match":function($){return z0[":nth-match"]($,!0)},":links-here":function($){return $+""===dZ.location+""},":lang":function($){return function(J){while(J){if(J.lang)return J.lang.indexOf($)===0;J=J.parentNode}}},":dir":function($){return function(J){while(J){if(J.dir)return J.dir===$;J=J.parentNode}}},":scope":function($,J){var Z=J||$.ownerDocument;if(Z.nodeType===9)return $===Z.documentElement;return $===Z},":any-link":function($){return typeof $.href==="string"},":local-link":function($){if($.nodeName)return $.href&&$.host===dZ.location.host;var J=+$+1;return function(Z){if(!Z.href)return;var Y=dZ.location+"",K=Z+"";return dW(Y,J)===dW(K,J)}},":default":function($){return!!$.defaultSelected},":valid":function($){return $.willValidate||$.validity&&$.validity.valid},":invalid":function($){return!z0[":valid"]($)},":in-range":function($){return $.value>$.min&&$.value<=$.max},":out-of-range":function($){return!z0[":in-range"]($)},":required":function($){return!!$.required},":optional":function($){return!$.required},":read-only":function($){if($.readOnly)return!0;var J=$.getAttribute("contenteditable"),Z=$.contentEditable,Y=$.nodeName.toLowerCase();return Y=Y!=="input"&&Y!=="textarea",(Y||$.disabled)&&J==null&&Z!=="true"},":read-write":function($){return!z0[":read-only"]($)},":hover":function(){throw Error(":hover is not supported.")},":active":function(){throw Error(":active is not supported.")},":link":function(){throw Error(":link is not supported.")},":visited":function(){throw Error(":visited is not supported.")},":column":function(){throw Error(":column is not supported.")},":nth-column":function(){throw Error(":nth-column is not supported.")},":nth-last-column":function(){throw Error(":nth-last-column is not supported.")},":current":function(){throw Error(":current is not supported.")},":past":function(){throw Error(":past is not supported.")},":future":function(){throw Error(":future is not supported.")},":contains":function($){return function(J){var Z=J.innerText||J.textContent||J.value||"";return Z.indexOf($)!==-1}},":has":function($){return function(J){return lW($,J).length>0}}},cW={"-":function(){return!0},"=":function($,J){return $===J},"*=":function($,J){return $.indexOf(J)!==-1},"~=":function($,J){var Z,Y,K,Q;for(Y=0;;Y=Z+1){if(Z=$.indexOf(J,Y),Z===-1)return!1;if(K=$[Z-1],Q=$[Z+J.length],(!K||K===" ")&&(!Q||Q===" "))return!0}},"|=":function($,J){var Z=$.indexOf(J),Y;if(Z!==0)return;return Y=$[Z+J.length],Y==="-"||!Y},"^=":function($,J){return $.indexOf(J)===0},"$=":function($,J){var Z=$.lastIndexOf(J);return Z!==-1&&Z+J.length===$.length},"!=":function($,J){return $!==J}},L8={" ":function($){return function(J){while(J=J.parentNode)if($(J))return J}},">":function($){return function(J){if(J=J.parentNode)return $(J)&&J}},"+":function($){return function(J){if(J=xJ(J))return $(J)&&J}},"~":function($){return function(J){while(J=xJ(J))if($(J))return J}},noop:function($){return function(J){return $(J)&&J}},ref:function($,J){var Z;function Y(K){var Q=K.ownerDocument,V=Q.getElementsByTagName("*"),X=V.length;while(X--)if(Z=V[X],Y.test(K))return Z=null,!0;Z=null}return Y.combinator=function(K){if(!Z||!Z.getAttribute)return;var Q=Z.getAttribute(J)||"";if(Q[0]==="#")Q=Q.substring(1);if(Q===K.id&&$(Z))return Z},Y}},_$={escape:/\\(?:[^0-9A-Fa-f\r\n]|[0-9A-Fa-f]{1,6}[\r\n\t ]?)/g,str_escape:/(escape)|\\(\n|\r\n?|\f)/g,nonascii:/[\u00A0-\uFFFF]/,cssid:/(?:(?!-?[0-9])(?:escape|nonascii|[-_a-zA-Z0-9])+)/,qname:/^ *(cssid|\*)/,simple:/^(?:([.#]cssid)|pseudo|attr)/,ref:/^ *\/(cssid)\/ */,combinator:/^(?: +([^ \w*.#\\]) +|( )+|([^ \w*.#\\]))(?! *$)/,attr:/^\[(cssid)(?:([^\w]?=)(inside))?\]/,pseudo:/^(:cssid)(?:\((inside)\))?/,inside:/(?:"(?:\\"|[^"])*"|'(?:\\'|[^'])*'|<[^"'>]*>|\\["'>]|[^"'>])*/,ident:/^(cssid)$/};_$.cssid=m0(_$.cssid,"nonascii",_$.nonascii);_$.cssid=m0(_$.cssid,"escape",_$.escape);_$.qname=m0(_$.qname,"cssid",_$.cssid);_$.simple=m0(_$.simple,"cssid",_$.cssid);_$.ref=m0(_$.ref,"cssid",_$.cssid);_$.attr=m0(_$.attr,"cssid",_$.cssid);_$.pseudo=m0(_$.pseudo,"cssid",_$.cssid);_$.inside=m0(_$.inside,`[^"'>]*`,_$.inside);_$.attr=m0(_$.attr,"inside",pW("\\[","\\]"));_$.pseudo=m0(_$.pseudo,"inside",pW("\\(","\\)"));_$.simple=m0(_$.simple,"pseudo",_$.pseudo);_$.simple=m0(_$.simple,"attr",_$.attr);_$.ident=m0(_$.ident,"cssid",_$.cssid);_$.str_escape=m0(_$.str_escape,"escape",_$.escape);var N8=function($){var J=$.replace(/^\s+|\s+$/g,""),Z,Y=[],K=[],Q,V,X,W,_;while(J){if(X=_$.qname.exec(J))J=J.substring(X[0].length),V=_2(X[1]),K.push(pZ(V,!0));else if(X=_$.simple.exec(J))J=J.substring(X[0].length),V="*",K.push(pZ(V,!0)),K.push(pZ(X));else throw SyntaxError("Invalid selector.");while(X=_$.simple.exec(J))J=J.substring(X[0].length),K.push(pZ(X));if(J[0]==="!")J=J.substring(1),Q=AD(),Q.qname=V,K.push(Q.simple);if(X=_$.ref.exec(J)){J=J.substring(X[0].length),_=L8.ref(zY(K),_2(X[1])),Y.push(_.combinator),K=[];continue}if(X=_$.combinator.exec(J)){if(J=J.substring(X[0].length),W=X[1]||X[2]||X[3],W===","){Y.push(L8.noop(zY(K)));break}}else W="noop";if(!L8[W])throw SyntaxError("Bad combinator.");Y.push(L8[W](zY(K))),K=[]}if(Z=ID(Y),Z.qname=V,Z.sel=J,Q)Q.lname=Z.qname,Q.test=Z,Q.qname=Q.qname,Q.sel=Z.sel,Z=Q;if(_)_.test=Z,_.qname=Z.qname,_.sel=Z.sel,Z=_;return Z},pZ=function($,J){if(J)return $==="*"?z0["*"]:z0.type($);if($[1])return $[1][0]==="."?z0.attr("class","~=",_2($[1].substring(1)),!1):z0.attr("id","=",_2($[1].substring(1)),!1);if($[2])return $[3]?z0[_2($[2])](uW($[3])):z0[_2($[2])];if($[4]){var Z=$[6],Y=/["'\s]\s*I$/i.test(Z);if(Y)Z=Z.replace(/\s*I$/i,"");return z0.attr(_2($[4]),$[5]||"-",uW(Z),Y)}throw SyntaxError("Unknown Selector.")},zY=function($){var J=$.length,Z;if(J<2)return $[0];return function(Y){if(!Y)return;for(Z=0;Z<J;Z++)if(!$[Z](Y))return;return!0}},ID=function($){if($.length<2)return function(J){return!!$[0](J)};return function(J){var Z=$.length;while(Z--)if(!(J=$[Z](J)))return;return!0}},AD=function(){var $;function J(Z){var Y=Z.ownerDocument,K=Y.getElementsByTagName(J.lname),Q=K.length;while(Q--)if(J.test(K[Q])&&$===Z)return $=null,!0;$=null}return J.simple=function(Z){return $=Z,!0},J},CY=function($){var J=N8($),Z=[J];while(J.sel)J=N8(J.sel),Z.push(J);if(Z.length<2)return J;return function(Y){var K=Z.length,Q=0;for(;Q<K;Q++)if(Z[Q](Y))return!0}},lW=function($,J){var Z=[],Y=N8($),K=J.getElementsByTagName(Y.qname),Q=0,V;while(V=K[Q++])if(Y(V))Z.push(V);if(Y.sel){while(Y.sel){Y=N8(Y.sel),K=J.getElementsByTagName(Y.qname),Q=0;while(V=K[Q++])if(Y(V)&&DD.call(Z,V)===-1)Z.push(V)}Z.sort(zD)}return Z};oW.exports=bJ=function($,J){var Z,Y;if(J.nodeType!==11&&$.indexOf(" ")===-1){if($[0]==="#"&&J.rooted&&/^#[A-Z_][-A-Z0-9_]*$/i.test($)){if(J.doc._hasMultipleElementsWithId){if(Z=$.substring(1),!J.doc._hasMultipleElementsWithId(Z))return Y=J.doc.getElementById(Z),Y?[Y]:[]}}if($[0]==="."&&/^\.\w+$/.test($))return J.getElementsByClassName($.substring(1));if(/^\w+$/.test($))return J.getElementsByTagName($)}return lW($,J)};bJ.selectors=z0;bJ.operators=cW;bJ.combinators=L8;bJ.matches=function($,J){var Z={sel:J};do if(Z=N8(Z.sel),Z($))return!0;while(Z.sel);return!1}});var oZ=p((Tb,rW)=>{var SD=P0(),wD=JY(),MY=function($,J){var Z=$.createDocumentFragment();for(var Y=0;Y<J.length;Y++){var K=J[Y],Q=K instanceof SD;Z.appendChild(Q?K:$.createTextNode(String(K)))}return Z},RD={after:{value:function(){var J=Array.prototype.slice.call(arguments),Z=this.parentNode,Y=this.nextSibling;if(Z===null)return;while(Y&&J.some(function(Q){return Q===Y}))Y=Y.nextSibling;var K=MY(this.doc,J);Z.insertBefore(K,Y)}},before:{value:function(){var J=Array.prototype.slice.call(arguments),Z=this.parentNode,Y=this.previousSibling;if(Z===null)return;while(Y&&J.some(function(V){return V===Y}))Y=Y.previousSibling;var K=MY(this.doc,J),Q=Y?Y.nextSibling:Z.firstChild;Z.insertBefore(K,Q)}},remove:{value:function(){if(this.parentNode===null)return;if(this.doc){if(this.doc._preremoveNodeIterators(this),this.rooted)this.doc.mutateRemove(this)}this._remove(),this.parentNode=null}},_remove:{value:function(){var J=this.parentNode;if(J===null)return;if(J._childNodes)J._childNodes.splice(this.index,1);else if(J._firstChild===this)if(this._nextSibling===this)J._firstChild=null;else J._firstChild=this._nextSibling;wD.remove(this),J.modify()}},replaceWith:{value:function(){var J=Array.prototype.slice.call(arguments),Z=this.parentNode,Y=this.nextSibling;if(Z===null)return;while(Y&&J.some(function(Q){return Q===Y}))Y=Y.nextSibling;var K=MY(this.doc,J);if(this.parentNode===Z)Z.replaceChild(K,this);else Z.insertBefore(K,Y)}}};rW.exports=RD});var DY=p((kb,sW)=>{var iW=P0(),LD={nextElementSibling:{get:function(){if(this.parentNode){for(var $=this.nextSibling;$!==null;$=$.nextSibling)if($.nodeType===iW.ELEMENT_NODE)return $}return null}},previousElementSibling:{get:function(){if(this.parentNode){for(var $=this.previousSibling;$!==null;$=$.previousSibling)if($.nodeType===iW.ELEMENT_NODE)return $}return null}}};sW.exports=LD});var PY=p((Eb,aW)=>{aW.exports=nW;var vJ=X0();function nW($){this.element=$}Object.defineProperties(nW.prototype,{length:{get:vJ.shouldOverride},item:{value:vJ.shouldOverride},getNamedItem:{value:function(J){return this.element.getAttributeNode(J)}},getNamedItemNS:{value:function(J,Z){return this.element.getAttributeNodeNS(J,Z)}},setNamedItem:{value:vJ.nyi},setNamedItemNS:{value:vJ.nyi},removeNamedItem:{value:function(J){var Z=this.element.getAttributeNode(J);if(Z)return this.element.removeAttribute(J),Z;vJ.NotFoundError()}},removeNamedItemNS:{value:function(J,Z){var Y=this.element.getAttributeNodeNS(J,Z);if(Y)return this.element.removeAttributeNS(J,Z),Y;vJ.NotFoundError()}}})});var gJ=p((xb,Z5)=>{Z5.exports=O2;var IY=uZ(),Y0=X0(),N1=Y0.NAMESPACE,iZ=_Y(),q1=P0(),AY=n2(),ND=ZY(),rZ=hW(),hJ=vZ(),yD=qY(),SY=lZ(),eW=mZ(),TD=oZ(),kD=DY(),$5=PY(),tW=Object.create(null);function O2($,J,Z,Y){eW.call(this),this.nodeType=q1.ELEMENT_NODE,this.ownerDocument=$,this.localName=J,this.namespaceURI=Z,this.prefix=Y,this._tagName=void 0,this._attrsByQName=Object.create(null),this._attrsByLName=Object.create(null),this._attrKeys=[]}function wY($,J){if($.nodeType===q1.TEXT_NODE)J.push($._data);else for(var Z=0,Y=$.childNodes.length;Z<Y;Z++)wY($.childNodes[Z],J)}O2.prototype=Object.create(eW.prototype,{isHTML:{get:function(){return this.namespaceURI===N1.HTML&&this.ownerDocument.isHTML}},tagName:{get:function(){if(this._tagName===void 0){var J;if(this.prefix===null)J=this.localName;else J=this.prefix+":"+this.localName;if(this.isHTML){var Z=tW[J];if(!Z)tW[J]=Z=Y0.toASCIIUpperCase(J);J=Z}this._tagName=J}return this._tagName}},nodeName:{get:function(){return this.tagName}},nodeValue:{get:function(){return null},set:function(){}},textContent:{get:function(){var $=[];return wY(this,$),$.join("")},set:function($){if(this.removeChildren(),$!==null&&$!==void 0&&$!=="")this._appendChild(this.ownerDocument.createTextNode($))}},innerText:{get:function(){var $=[];return wY(this,$),$.join("").replace(/[ \t\n\f\r]+/g," ").trim()},set:function($){if(this.removeChildren(),$!==null&&$!==void 0&&$!=="")this._appendChild(this.ownerDocument.createTextNode($))}},innerHTML:{get:function(){return this.serialize()},set:Y0.nyi},outerHTML:{get:function(){return ND.serializeOne(this,{nodeType:0})},set:function($){var J=this.ownerDocument,Z=this.parentNode;if(Z===null)return;if(Z.nodeType===q1.DOCUMENT_NODE)Y0.NoModificationAllowedError();if(Z.nodeType===q1.DOCUMENT_FRAGMENT_NODE)Z=Z.ownerDocument.createElement("body");var Y=J.implementation.mozHTMLParser(J._address,Z);Y.parse($===null?"":String($),!0),this.replaceWith(Y._asDocumentFragment())}},_insertAdjacent:{value:function(J,Z){var Y=!1;switch(J){case"beforebegin":Y=!0;case"afterend":var K=this.parentNode;if(K===null)return null;return K.insertBefore(Z,Y?this:this.nextSibling);case"afterbegin":Y=!0;case"beforeend":return this.insertBefore(Z,Y?this.firstChild:null);default:return Y0.SyntaxError()}}},insertAdjacentElement:{value:function(J,Z){if(Z.nodeType!==q1.ELEMENT_NODE)throw TypeError("not an element");return J=Y0.toASCIILowerCase(String(J)),this._insertAdjacent(J,Z)}},insertAdjacentText:{value:function(J,Z){var Y=this.ownerDocument.createTextNode(Z);J=Y0.toASCIILowerCase(String(J)),this._insertAdjacent(J,Y)}},insertAdjacentHTML:{value:function(J,Z){J=Y0.toASCIILowerCase(String(J)),Z=String(Z);var Y;switch(J){case"beforebegin":case"afterend":if(Y=this.parentNode,Y===null||Y.nodeType===q1.DOCUMENT_NODE)Y0.NoModificationAllowedError();break;case"afterbegin":case"beforeend":Y=this;break;default:Y0.SyntaxError()}if(!(Y instanceof O2)||Y.ownerDocument.isHTML&&Y.localName==="html"&&Y.namespaceURI===N1.HTML)Y=Y.ownerDocument.createElementNS(N1.HTML,"body");var K=this.ownerDocument.implementation.mozHTMLParser(this.ownerDocument._address,Y);K.parse(Z,!0),this._insertAdjacent(J,K._asDocumentFragment())}},children:{get:function(){if(!this._children)this._children=new J5(this);return this._children}},attributes:{get:function(){if(!this._attributes)this._attributes=new LY(this);return this._attributes}},firstElementChild:{get:function(){for(var $=this.firstChild;$!==null;$=$.nextSibling)if($.nodeType===q1.ELEMENT_NODE)return $;return null}},lastElementChild:{get:function(){for(var $=this.lastChild;$!==null;$=$.previousSibling)if($.nodeType===q1.ELEMENT_NODE)return $;return null}},childElementCount:{get:function(){return this.children.length}},nextElement:{value:function($){if(!$)$=this.ownerDocument.documentElement;var J=this.firstElementChild;if(!J){if(this===$)return null;J=this.nextElementSibling}if(J)return J;for(var Z=this.parentElement;Z&&Z!==$;Z=Z.parentElement)if(J=Z.nextElementSibling,J)return J;return null}},getElementsByTagName:{value:function(J){var Z;if(!J)return new AY;if(J==="*")Z=function(){return!0};else if(this.isHTML)Z=ED(J);else Z=RY(J);return new rZ(this,Z)}},getElementsByTagNameNS:{value:function(J,Z){var Y;if(J==="*"&&Z==="*")Y=function(){return!0};else if(J==="*")Y=RY(Z);else if(Z==="*")Y=xD(J);else Y=bD(J,Z);return new rZ(this,Y)}},getElementsByClassName:{value:function(J){if(J=String(J).trim(),J===""){var Z=new AY;return Z}return J=J.split(/[ \t\r\n\f]+/),new rZ(this,vD(J))}},getElementsByName:{value:function(J){return new rZ(this,hD(String(J)))}},clone:{value:function(){var J;if(this.namespaceURI!==N1.HTML||this.prefix||!this.ownerDocument.isHTML)J=this.ownerDocument.createElementNS(this.namespaceURI,this.prefix!==null?this.prefix+":"+this.localName:this.localName);else J=this.ownerDocument.createElement(this.localName);for(var Z=0,Y=this._attrKeys.length;Z<Y;Z++){var K=this._attrKeys[Z],Q=this._attrsByLName[K],V=Q.cloneNode();V._setOwnerElement(J),J._attrsByLName[K]=V,J._addQName(V)}return J._attrKeys=this._attrKeys.concat(),J}},isEqual:{value:function(J){if(this.localName!==J.localName||this.namespaceURI!==J.namespaceURI||this.prefix!==J.prefix||this._numattrs!==J._numattrs)return!1;for(var Z=0,Y=this._numattrs;Z<Y;Z++){var K=this._attr(Z);if(!J.hasAttributeNS(K.namespaceURI,K.localName))return!1;if(J.getAttributeNS(K.namespaceURI,K.localName)!==K.value)return!1}return!0}},_lookupNamespacePrefix:{value:function(J,Z){if(this.namespaceURI&&this.namespaceURI===J&&this.prefix!==null&&Z.lookupNamespaceURI(this.prefix)===J)return this.prefix;for(var Y=0,K=this._numattrs;Y<K;Y++){var Q=this._attr(Y);if(Q.prefix==="xmlns"&&Q.value===J&&Z.lookupNamespaceURI(Q.localName)===J)return Q.localName}var V=this.parentElement;return V?V._lookupNamespacePrefix(J,Z):null}},lookupNamespaceURI:{value:function(J){if(J===""||J===void 0)J=null;if(this.namespaceURI!==null&&this.prefix===J)return this.namespaceURI;for(var Z=0,Y=this._numattrs;Z<Y;Z++){var K=this._attr(Z);if(K.namespaceURI===N1.XMLNS){if(K.prefix==="xmlns"&&K.localName===J||J===null&&K.prefix===null&&K.localName==="xmlns")return K.value||null}}var Q=this.parentElement;return Q?Q.lookupNamespaceURI(J):null}},getAttribute:{value:function(J){var Z=this.getAttributeNode(J);return Z?Z.value:null}},getAttributeNS:{value:function(J,Z){var Y=this.getAttributeNodeNS(J,Z);return Y?Y.value:null}},getAttributeNode:{value:function(J){if(J=String(J),/[A-Z]/.test(J)&&this.isHTML)J=Y0.toASCIILowerCase(J);var Z=this._attrsByQName[J];if(!Z)return null;if(Array.isArray(Z))Z=Z[0];return Z}},getAttributeNodeNS:{value:function(J,Z){J=J===void 0||J===null?"":String(J),Z=String(Z);var Y=this._attrsByLName[J+"|"+Z];return Y?Y:null}},hasAttribute:{value:function(J){if(J=String(J),/[A-Z]/.test(J)&&this.isHTML)J=Y0.toASCIILowerCase(J);return this._attrsByQName[J]!==void 0}},hasAttributeNS:{value:function(J,Z){J=J===void 0||J===null?"":String(J),Z=String(Z);var Y=J+"|"+Z;return this._attrsByLName[Y]!==void 0}},hasAttributes:{value:function(){return this._numattrs>0}},toggleAttribute:{value:function(J,Z){if(J=String(J),!IY.isValidName(J))Y0.InvalidCharacterError();if(/[A-Z]/.test(J)&&this.isHTML)J=Y0.toASCIILowerCase(J);var Y=this._attrsByQName[J];if(Y===void 0){if(Z===void 0||Z===!0)return this._setAttribute(J,""),!0;return!1}else{if(Z===void 0||Z===!1)return this.removeAttribute(J),!1;return!0}}},_setAttribute:{value:function(J,Z){var Y=this._attrsByQName[J],K;if(!Y)Y=this._newattr(J),K=!0;else if(Array.isArray(Y))Y=Y[0];if(Y.value=Z,this._attributes)this._attributes[J]=Y;if(K&&this._newattrhook)this._newattrhook(J,Z)}},setAttribute:{value:function(J,Z){if(J=String(J),!IY.isValidName(J))Y0.InvalidCharacterError();if(/[A-Z]/.test(J)&&this.isHTML)J=Y0.toASCIILowerCase(J);this._setAttribute(J,String(Z))}},_setAttributeNS:{value:function(J,Z,Y){var K=Z.indexOf(":"),Q,V;if(K<0)Q=null,V=Z;else Q=Z.substring(0,K),V=Z.substring(K+1);if(J===""||J===void 0)J=null;var X=(J===null?"":J)+"|"+V,W=this._attrsByLName[X],_;if(!W){if(W=new y8(this,V,Q,J),_=!0,this._attrsByLName[X]=W,this._attributes)this._attributes[this._attrKeys.length]=W;this._attrKeys.push(X),this._addQName(W)}if(W.value=Y,_&&this._newattrhook)this._newattrhook(Z,Y)}},setAttributeNS:{value:function(J,Z,Y){if(J=J===null||J===void 0||J===""?null:String(J),Z=String(Z),!IY.isValidQName(Z))Y0.InvalidCharacterError();var K=Z.indexOf(":"),Q=K<0?null:Z.substring(0,K);if(Q!==null&&J===null||Q==="xml"&&J!==N1.XML||(Z==="xmlns"||Q==="xmlns")&&J!==N1.XMLNS||J===N1.XMLNS&&!(Z==="xmlns"||Q==="xmlns"))Y0.NamespaceError();this._setAttributeNS(J,Z,String(Y))}},setAttributeNode:{value:function(J){if(J.ownerElement!==null&&J.ownerElement!==this)throw new hJ(hJ.INUSE_ATTRIBUTE_ERR);var Z=null,Y=this._attrsByQName[J.name];if(Y){if(!Array.isArray(Y))Y=[Y];if(Y.some(function(K){return K===J}))return J;else if(J.ownerElement!==null)throw new hJ(hJ.INUSE_ATTRIBUTE_ERR);Y.forEach(function(K){this.removeAttributeNode(K)},this),Z=Y[0]}return this.setAttributeNodeNS(J),Z}},setAttributeNodeNS:{value:function(J){if(J.ownerElement!==null)throw new hJ(hJ.INUSE_ATTRIBUTE_ERR);var Z=J.namespaceURI,Y=(Z===null?"":Z)+"|"+J.localName,K=this._attrsByLName[Y];if(K)this.removeAttributeNode(K);if(J._setOwnerElement(this),this._attrsByLName[Y]=J,this._attributes)this._attributes[this._attrKeys.length]=J;if(this._attrKeys.push(Y),this._addQName(J),this._newattrhook)this._newattrhook(J.name,J.value);return K||null}},removeAttribute:{value:function(J){if(J=String(J),/[A-Z]/.test(J)&&this.isHTML)J=Y0.toASCIILowerCase(J);var Z=this._attrsByQName[J];if(!Z)return;if(Array.isArray(Z))if(Z.length>2)Z=Z.shift();else this._attrsByQName[J]=Z[1],Z=Z[0];else this._attrsByQName[J]=void 0;var Y=Z.namespaceURI,K=(Y===null?"":Y)+"|"+Z.localName;this._attrsByLName[K]=void 0;var Q=this._attrKeys.indexOf(K);if(this._attributes)Array.prototype.splice.call(this._attributes,Q,1),this._attributes[J]=void 0;this._attrKeys.splice(Q,1);var V=Z.onchange;if(Z._setOwnerElement(null),V)V.call(Z,this,Z.localName,Z.value,null);if(this.rooted)this.ownerDocument.mutateRemoveAttr(Z)}},removeAttributeNS:{value:function(J,Z){J=J===void 0||J===null?"":String(J),Z=String(Z);var Y=J+"|"+Z,K=this._attrsByLName[Y];if(!K)return;this._attrsByLName[Y]=void 0;var Q=this._attrKeys.indexOf(Y);if(this._attributes)Array.prototype.splice.call(this._attributes,Q,1);this._attrKeys.splice(Q,1),this._removeQName(K);var V=K.onchange;if(K._setOwnerElement(null),V)V.call(K,this,K.localName,K.value,null);if(this.rooted)this.ownerDocument.mutateRemoveAttr(K)}},removeAttributeNode:{value:function(J){var Z=J.namespaceURI,Y=(Z===null?"":Z)+"|"+J.localName;if(this._attrsByLName[Y]!==J)Y0.NotFoundError();return this.removeAttributeNS(Z,J.localName),J}},getAttributeNames:{value:function(){var J=this;return this._attrKeys.map(function(Z){return J._attrsByLName[Z].name})}},_getattr:{value:function(J){var Z=this._attrsByQName[J];return Z?Z.value:null}},_setattr:{value:function(J,Z){var Y=this._attrsByQName[J],K;if(!Y)Y=this._newattr(J),K=!0;if(Y.value=String(Z),this._attributes)this._attributes[J]=Y;if(K&&this._newattrhook)this._newattrhook(J,Z)}},_newattr:{value:function(J){var Z=new y8(this,J,null,null),Y="|"+J;if(this._attrsByQName[J]=Z,this._attrsByLName[Y]=Z,this._attributes)this._attributes[this._attrKeys.length]=Z;return this._attrKeys.push(Y),Z}},_addQName:{value:function($){var J=$.name,Z=this._attrsByQName[J];if(!Z)this._attrsByQName[J]=$;else if(Array.isArray(Z))Z.push($);else this._attrsByQName[J]=[Z,$];if(this._attributes)this._attributes[J]=$}},_removeQName:{value:function($){var J=$.name,Z=this._attrsByQName[J];if(Array.isArray(Z)){var Y=Z.indexOf($);if(Y0.assert(Y!==-1),Z.length===2){if(this._attrsByQName[J]=Z[1-Y],this._attributes)this._attributes[J]=this._attrsByQName[J]}else if(Z.splice(Y,1),this._attributes&&this._attributes[J]===$)this._attributes[J]=Z[0]}else if(Y0.assert(Z===$),this._attrsByQName[J]=void 0,this._attributes)this._attributes[J]=void 0}},_numattrs:{get:function(){return this._attrKeys.length}},_attr:{value:function($){return this._attrsByLName[this._attrKeys[$]]}},id:iZ.property({name:"id"}),className:iZ.property({name:"class"}),classList:{get:function(){var $=this;if(this._classList)return this._classList;var J=new yD(function(){return $.className||""},function(Z){$.className=Z});return this._classList=J,J},set:function($){this.className=$}},matches:{value:function($){return SY.matches(this,$)}},closest:{value:function($){var J=this;do{if(J.matches&&J.matches($))return J;J=J.parentElement||J.parentNode}while(J!==null&&J.nodeType===q1.ELEMENT_NODE);return null}},querySelector:{value:function($){return SY($,this)[0]}},querySelectorAll:{value:function($){var J=SY($,this);return J.item?J:new AY(J)}}});Object.defineProperties(O2.prototype,TD);Object.defineProperties(O2.prototype,kD);iZ.registerChangeHandler(O2,"id",function($,J,Z,Y){if($.rooted){if(Z)$.ownerDocument.delId(Z,$);if(Y)$.ownerDocument.addId(Y,$)}});iZ.registerChangeHandler(O2,"class",function($,J,Z,Y){if($._classList)$._classList._update()});function y8($,J,Z,Y,K){this.localName=J,this.prefix=Z===null||Z===""?null:""+Z,this.namespaceURI=Y===null||Y===""?null:""+Y,this.data=K,this._setOwnerElement($)}y8.prototype=Object.create(Object.prototype,{ownerElement:{get:function(){return this._ownerElement}},_setOwnerElement:{value:function(J){if(this._ownerElement=J,this.prefix===null&&this.namespaceURI===null&&J)this.onchange=J._attributeChangeHandlers[this.localName];else this.onchange=null}},name:{get:function(){return this.prefix?this.prefix+":"+this.localName:this.localName}},specified:{get:function(){return!0}},value:{get:function(){return this.data},set:function($){var J=this.data;if($=$===void 0?"":$+"",$===J)return;if(this.data=$,this.ownerElement){if(this.onchange)this.onchange(this.ownerElement,this.localName,J,$);if(this.ownerElement.rooted)this.ownerElement.ownerDocument.mutateAttr(this,J)}}},cloneNode:{value:function(J){return new y8(null,this.localName,this.prefix,this.namespaceURI,this.data)}},nodeType:{get:function(){return q1.ATTRIBUTE_NODE}},nodeName:{get:function(){return this.name}},nodeValue:{get:function(){return this.value},set:function($){this.value=$}},textContent:{get:function(){return this.value},set:function($){if($===null||$===void 0)$="";this.value=$}},innerText:{get:function(){return this.value},set:function($){if($===null||$===void 0)$="";this.value=$}}});O2._Attr=y8;function LY($){$5.call(this,$);for(var J in $._attrsByQName)this[J]=$._attrsByQName[J];for(var Z=0;Z<$._attrKeys.length;Z++)this[Z]=$._attrsByLName[$._attrKeys[Z]]}LY.prototype=Object.create($5.prototype,{length:{get:function(){return this.element._attrKeys.length},set:function(){}},item:{value:function($){if($=$>>>0,$>=this.length)return null;return this.element._attrsByLName[this.element._attrKeys[$]]}}});if(globalThis.Symbol?.iterator)LY.prototype[globalThis.Symbol.iterator]=function(){var $=0,J=this.length,Z=this;return{next:function(){if($<J)return{value:Z.item($++)};return{done:!0}}}};function J5($){this.element=$,this.updateCache()}J5.prototype=Object.create(Object.prototype,{length:{get:function(){return this.updateCache(),this.childrenByNumber.length}},item:{value:function(J){return this.updateCache(),this.childrenByNumber[J]||null}},namedItem:{value:function(J){return this.updateCache(),this.childrenByName[J]||null}},namedItems:{get:function(){return this.updateCache(),this.childrenByName}},updateCache:{value:function(){var J=/^(a|applet|area|embed|form|frame|frameset|iframe|img|object)$/;if(this.lastModTime!==this.element.lastModTime){this.lastModTime=this.element.lastModTime;var Z=this.childrenByNumber&&this.childrenByNumber.length||0;for(var Y=0;Y<Z;Y++)this[Y]=void 0;this.childrenByNumber=[],this.childrenByName=Object.create(null);for(var K=this.element.firstChild;K!==null;K=K.nextSibling)if(K.nodeType===q1.ELEMENT_NODE){this[this.childrenByNumber.length]=K,this.childrenByNumber.push(K);var Q=K.getAttribute("id");if(Q&&!this.childrenByName[Q])this.childrenByName[Q]=K;var V=K.getAttribute("name");if(V&&this.element.namespaceURI===N1.HTML&&J.test(this.element.localName)&&!this.childrenByName[V])this.childrenByName[Q]=K}}}}});function RY($){return function(J){return J.localName===$}}function ED($){var J=Y0.toASCIILowerCase($);if(J===$)return RY($);return function(Z){return Z.isHTML?Z.localName===J:Z.localName===$}}function xD($){return function(J){return J.namespaceURI===$}}function bD($,J){return function(Z){return Z.namespaceURI===$&&Z.localName===J}}function vD($){return function(J){return $.every(function(Z){return J.classList.contains(Z)})}}function hD($){return function(J){if(J.namespaceURI!==N1.HTML)return!1;return J.getAttribute("name")===$}}});var NY=p((bb,G5)=>{G5.exports=V5;var K5=P0(),gD=n2(),Q5=X0(),Y5=Q5.HierarchyRequestError,fD=Q5.NotFoundError;function V5(){K5.call(this)}V5.prototype=Object.create(K5.prototype,{hasChildNodes:{value:function(){return!1}},firstChild:{value:null},lastChild:{value:null},insertBefore:{value:function($,J){if(!$.nodeType)throw TypeError("not a node");Y5()}},replaceChild:{value:function($,J){if(!$.nodeType)throw TypeError("not a node");Y5()}},removeChild:{value:function($){if(!$.nodeType)throw TypeError("not a node");fD()}},removeChildren:{value:function(){}},childNodes:{get:function(){if(!this._childNodes)this._childNodes=new gD;return this._childNodes}}})});var T8=p((vb,j5)=>{j5.exports=sZ;var W5=NY(),X5=X0(),mD=oZ(),uD=DY();function sZ(){W5.call(this)}sZ.prototype=Object.create(W5.prototype,{substringData:{value:function(J,Z){if(arguments.length<2)throw TypeError("Not enough arguments");if(J=J>>>0,Z=Z>>>0,J>this.data.length||J<0||Z<0)X5.IndexSizeError();return this.data.substring(J,J+Z)}},appendData:{value:function(J){if(arguments.length<1)throw TypeError("Not enough arguments");this.data+=String(J)}},insertData:{value:function(J,Z){return this.replaceData(J,0,Z)}},deleteData:{value:function(J,Z){return this.replaceData(J,Z,"")}},replaceData:{value:function(J,Z,Y){var K=this.data,Q=K.length;if(J=J>>>0,Z=Z>>>0,Y=String(Y),J>Q||J<0)X5.IndexSizeError();if(J+Z>Q)Z=Q-J;var V=K.substring(0,J),X=K.substring(J+Z);this.data=V+Y+X}},isEqual:{value:function(J){return this._data===J._data}},length:{get:function(){return this.data.length}}});Object.defineProperties(sZ.prototype,mD);Object.defineProperties(sZ.prototype,uD)});var TY=p((hb,_5)=>{_5.exports=yY;var U5=X0(),B5=P0(),H5=T8();function yY($,J){H5.call(this),this.nodeType=B5.TEXT_NODE,this.ownerDocument=$,this._data=J,this._index=void 0}var k8={get:function(){return this._data},set:function($){if($===null||$===void 0)$="";else $=String($);if($===this._data)return;if(this._data=$,this.rooted)this.ownerDocument.mutateValue(this);if(this.parentNode&&this.parentNode._textchangehook)this.parentNode._textchangehook(this)}};yY.prototype=Object.create(H5.prototype,{nodeName:{value:"#text"},nodeValue:k8,textContent:k8,innerText:k8,data:{get:k8.get,set:function($){k8.set.call(this,$===null?"":String($))}},splitText:{value:function(J){if(J>this._data.length||J<0)U5.IndexSizeError();var Z=this._data.substring(J),Y=this.ownerDocument.createTextNode(Z);this.data=this.data.substring(0,J);var K=this.parentNode;if(K!==null)K.insertBefore(Y,this.nextSibling);return Y}},wholeText:{get:function(){var J=this.textContent;for(var Z=this.nextSibling;Z;Z=Z.nextSibling){if(Z.nodeType!==B5.TEXT_NODE)break;J+=Z.textContent}return J}},replaceWholeText:{value:U5.nyi},clone:{value:function(){return new yY(this.ownerDocument,this._data)}}})});var EY=p((gb,q5)=>{q5.exports=kY;var dD=P0(),O5=T8();function kY($,J){O5.call(this),this.nodeType=dD.COMMENT_NODE,this.ownerDocument=$,this._data=J}var E8={get:function(){return this._data},set:function($){if($===null||$===void 0)$="";else $=String($);if(this._data=$,this.rooted)this.ownerDocument.mutateValue(this)}};kY.prototype=Object.create(O5.prototype,{nodeName:{value:"#comment"},nodeValue:E8,textContent:E8,innerText:E8,data:{get:E8.get,set:function($){E8.set.call(this,$===null?"":String($))}},clone:{value:function(){return new kY(this.ownerDocument,this._data)}}})});var bY=p((fb,C5)=>{C5.exports=xY;var pD=P0(),cD=n2(),z5=mZ(),nZ=gJ(),lD=lZ(),F5=X0();function xY($){z5.call(this),this.nodeType=pD.DOCUMENT_FRAGMENT_NODE,this.ownerDocument=$}xY.prototype=Object.create(z5.prototype,{nodeName:{value:"#document-fragment"},nodeValue:{get:function(){return null},set:function(){}},textContent:Object.getOwnPropertyDescriptor(nZ.prototype,"textContent"),innerText:Object.getOwnPropertyDescriptor(nZ.prototype,"innerText"),querySelector:{value:function($){var J=this.querySelectorAll($);return J.length?J[0]:null}},querySelectorAll:{value:function($){var J=Object.create(this);J.isHTML=!0,J.getElementsByTagName=nZ.prototype.getElementsByTagName,J.nextElement=Object.getOwnPropertyDescriptor(nZ.prototype,"firstElementChild").get;var Z=lD($,J);return Z.item?Z:new cD(Z)}},clone:{value:function(){return new xY(this.ownerDocument)}},isEqual:{value:function(J){return!0}},innerHTML:{get:function(){return this.serialize()},set:F5.nyi},outerHTML:{get:function(){return this.serialize()},set:F5.nyi}})});var hY=p((mb,D5)=>{D5.exports=vY;var oD=P0(),M5=T8();function vY($,J,Z){M5.call(this),this.nodeType=oD.PROCESSING_INSTRUCTION_NODE,this.ownerDocument=$,this.target=J,this._data=Z}var x8={get:function(){return this._data},set:function($){if($===null||$===void 0)$="";else $=String($);if(this._data=$,this.rooted)this.ownerDocument.mutateValue(this)}};vY.prototype=Object.create(M5.prototype,{nodeName:{get:function(){return this.target}},nodeValue:x8,textContent:x8,innerText:x8,data:{get:x8.get,set:function($){x8.set.call(this,$===null?"":String($))}},clone:{value:function(){return new vY(this.ownerDocument,this.target,this._data)}},isEqual:{value:function(J){return this.target===J.target&&this._data===J._data}}})});var b8=p((ub,P5)=>{var gY={FILTER_ACCEPT:1,FILTER_REJECT:2,FILTER_SKIP:3,SHOW_ALL:4294967295,SHOW_ELEMENT:1,SHOW_ATTRIBUTE:2,SHOW_TEXT:4,SHOW_CDATA_SECTION:8,SHOW_ENTITY_REFERENCE:16,SHOW_ENTITY:32,SHOW_PROCESSING_INSTRUCTION:64,SHOW_COMMENT:128,SHOW_DOCUMENT:256,SHOW_DOCUMENT_TYPE:512,SHOW_DOCUMENT_FRAGMENT:1024,SHOW_NOTATION:2048};P5.exports=gY.constructor=gY.prototype=gY});var mY=p((pb,A5)=>{var db=A5.exports={nextSkippingChildren:rD,nextAncestorSibling:fY,next:iD,previous:sD,deepLastChild:I5};function rD($,J){if($===J)return null;if($.nextSibling!==null)return $.nextSibling;return fY($,J)}function fY($,J){for($=$.parentNode;$!==null;$=$.parentNode){if($===J)return null;if($.nextSibling!==null)return $.nextSibling}return null}function iD($,J){var Z=$.firstChild;if(Z!==null)return Z;if($===J)return null;if(Z=$.nextSibling,Z!==null)return Z;return fY($,J)}function I5($){while($.lastChild)$=$.lastChild;return $}function sD($,J){var Z=$.previousSibling;if(Z!==null)return I5(Z);if(Z=$.parentNode,Z===J)return null;return Z}});var T5=p((cb,y5)=>{y5.exports=N5;var nD=P0(),I0=b8(),S5=mY(),L5=X0(),uY={first:"firstChild",last:"lastChild",next:"firstChild",previous:"lastChild"},dY={first:"nextSibling",last:"previousSibling",next:"nextSibling",previous:"previousSibling"};function w5($,J){var Z,Y,K,Q,V;Y=$._currentNode[uY[J]];while(Y!==null){if(Q=$._internalFilter(Y),Q===I0.FILTER_ACCEPT)return $._currentNode=Y,Y;if(Q===I0.FILTER_SKIP){if(Z=Y[uY[J]],Z!==null){Y=Z;continue}}while(Y!==null){if(V=Y[dY[J]],V!==null){Y=V;break}if(K=Y.parentNode,K===null||K===$.root||K===$._currentNode)return null;else Y=K}}return null}function R5($,J){var Z,Y,K;if(Z=$._currentNode,Z===$.root)return null;while(!0){K=Z[dY[J]];while(K!==null){if(Z=K,Y=$._internalFilter(Z),Y===I0.FILTER_ACCEPT)return $._currentNode=Z,Z;if(K=Z[uY[J]],Y===I0.FILTER_REJECT||K===null)K=Z[dY[J]]}if(Z=Z.parentNode,Z===null||Z===$.root)return null;if($._internalFilter(Z)===I0.FILTER_ACCEPT)return null}}function N5($,J,Z){if(!$||!$.nodeType)L5.NotSupportedError();this._root=$,this._whatToShow=Number(J)||0,this._filter=Z||null,this._active=!1,this._currentNode=$}Object.defineProperties(N5.prototype,{root:{get:function(){return this._root}},whatToShow:{get:function(){return this._whatToShow}},filter:{get:function(){return this._filter}},currentNode:{get:function(){return this._currentNode},set:function(J){if(!(J instanceof nD))throw TypeError("Not a Node");this._currentNode=J}},_internalFilter:{value:function(J){var Z,Y;if(this._active)L5.InvalidStateError();if(!(1<<J.nodeType-1&this._whatToShow))return I0.FILTER_SKIP;if(Y=this._filter,Y===null)Z=I0.FILTER_ACCEPT;else{this._active=!0;try{if(typeof Y==="function")Z=Y(J);else Z=Y.acceptNode(J)}finally{this._active=!1}}return+Z}},parentNode:{value:function(){var J=this._currentNode;while(J!==this.root){if(J=J.parentNode,J===null)return null;if(this._internalFilter(J)===I0.FILTER_ACCEPT)return this._currentNode=J,J}return null}},firstChild:{value:function(){return w5(this,"first")}},lastChild:{value:function(){return w5(this,"last")}},previousSibling:{value:function(){return R5(this,"previous")}},nextSibling:{value:function(){return R5(this,"next")}},previousNode:{value:function(){var J,Z,Y,K;J=this._currentNode;while(J!==this._root){for(Y=J.previousSibling;Y;Y=J.previousSibling){if(J=Y,Z=this._internalFilter(J),Z===I0.FILTER_REJECT)continue;for(K=J.lastChild;K;K=J.lastChild)if(J=K,Z=this._internalFilter(J),Z===I0.FILTER_REJECT)break;if(Z===I0.FILTER_ACCEPT)return this._currentNode=J,J}if(J===this.root||J.parentNode===null)return null;if(J=J.parentNode,this._internalFilter(J)===I0.FILTER_ACCEPT)return this._currentNode=J,J}return null}},nextNode:{value:function(){var J,Z,Y,K;J=this._currentNode,Z=I0.FILTER_ACCEPT;$:while(!0){for(Y=J.firstChild;Y;Y=J.firstChild)if(J=Y,Z=this._internalFilter(J),Z===I0.FILTER_ACCEPT)return this._currentNode=J,J;else if(Z===I0.FILTER_REJECT)break;for(K=S5.nextSkippingChildren(J,this.root);K;K=S5.nextSkippingChildren(J,this.root))if(J=K,Z=this._internalFilter(J),Z===I0.FILTER_ACCEPT)return this._currentNode=J,J;else if(Z===I0.FILTER_SKIP)continue $;return null}}},toString:{value:function(){return"[object TreeWalker]"}}})});var h5=p((lb,v5)=>{v5.exports=b5;var pY=b8(),cY=mY(),x5=X0();function aD($,J,Z){if(Z)return cY.next($,J);else{if($===J)return null;return cY.previous($,null)}}function k5($,J){for(;J;J=J.parentNode)if($===J)return!0;return!1}function E5($,J){var Z,Y;Z=$._referenceNode,Y=$._pointerBeforeReferenceNode;while(!0){if(Y===J)Y=!Y;else if(Z=aD(Z,$._root,J),Z===null)return null;var K=$._internalFilter(Z);if(K===pY.FILTER_ACCEPT)break}return $._referenceNode=Z,$._pointerBeforeReferenceNode=Y,Z}function b5($,J,Z){if(!$||!$.nodeType)x5.NotSupportedError();this._root=$,this._referenceNode=$,this._pointerBeforeReferenceNode=!0,this._whatToShow=Number(J)||0,this._filter=Z||null,this._active=!1,$.doc._attachNodeIterator(this)}Object.defineProperties(b5.prototype,{root:{get:function(){return this._root}},referenceNode:{get:function(){return this._referenceNode}},pointerBeforeReferenceNode:{get:function(){return this._pointerBeforeReferenceNode}},whatToShow:{get:function(){return this._whatToShow}},filter:{get:function(){return this._filter}},_internalFilter:{value:function(J){var Z,Y;if(this._active)x5.InvalidStateError();if(!(1<<J.nodeType-1&this._whatToShow))return pY.FILTER_SKIP;if(Y=this._filter,Y===null)Z=pY.FILTER_ACCEPT;else{this._active=!0;try{if(typeof Y==="function")Z=Y(J);else Z=Y.acceptNode(J)}finally{this._active=!1}}return+Z}},_preremove:{value:function(J){if(k5(J,this._root))return;if(!k5(J,this._referenceNode))return;if(this._pointerBeforeReferenceNode){var Z=J;while(Z.lastChild)Z=Z.lastChild;if(Z=cY.next(Z,this.root),Z){this._referenceNode=Z;return}this._pointerBeforeReferenceNode=!1}if(J.previousSibling===null)this._referenceNode=J.parentNode;else{this._referenceNode=J.previousSibling;var Y;for(Y=this._referenceNode.lastChild;Y;Y=this._referenceNode.lastChild)this._referenceNode=Y}}},nextNode:{value:function(){return E5(this,!0)}},previousNode:{value:function(){return E5(this,!1)}},detach:{value:function(){}},toString:{value:function(){return"[object NodeIterator]"}}})});var aZ=p((ob,g5)=>{g5.exports=A0;function A0($){if(!$)return Object.create(A0.prototype);this.url=$.replace(/^[ \t\n\r\f]+|[ \t\n\r\f]+$/g,"");var J=A0.pattern.exec(this.url);if(J){if(J[2])this.scheme=J[2];if(J[4]){var Z=J[4].match(A0.userinfoPattern);if(Z)this.username=Z[1],this.password=Z[3],J[4]=J[4].substring(Z[0].length);if(J[4].match(A0.portPattern)){var Y=J[4].lastIndexOf(":");this.host=J[4].substring(0,Y),this.port=J[4].substring(Y+1)}else this.host=J[4]}if(J[5])this.path=J[5];if(J[6])this.query=J[7];if(J[8])this.fragment=J[9]}}A0.pattern=/^(([^:\/?#]+):)?(\/\/([^\/?#]*))?([^?#]*)(\?([^#]*))?(#(.*))?$/;A0.userinfoPattern=/^([^@:]*)(:([^@]*))?@/;A0.portPattern=/:\d+$/;A0.authorityPattern=/^[^:\/?#]+:\/\//;A0.hierarchyPattern=/^[^:\/?#]+:\//;A0.percentEncode=function(J){var Z=J.charCodeAt(0);if(Z<256)return"%"+Z.toString(16);else throw Error("can't percent-encode codepoints > 255 yet")};A0.prototype={constructor:A0,isAbsolute:function(){return!!this.scheme},isAuthorityBased:function(){return A0.authorityPattern.test(this.url)},isHierarchical:function(){return A0.hierarchyPattern.test(this.url)},toString:function(){var $="";if(this.scheme!==void 0)$+=this.scheme+":";if(this.isAbsolute()){if($+="//",this.username||this.password){if($+=this.username||"",this.password)$+=":"+this.password;$+="@"}if(this.host)$+=this.host}if(this.port!==void 0)$+=":"+this.port;if(this.path!==void 0)$+=this.path;if(this.query!==void 0)$+="?"+this.query;if(this.fragment!==void 0)$+="#"+this.fragment;return $},resolve:function($){var J=this,Z=new A0($),Y=new A0;if(Z.scheme!==void 0)Y.scheme=Z.scheme,Y.username=Z.username,Y.password=Z.password,Y.host=Z.host,Y.port=Z.port,Y.path=Q(Z.path),Y.query=Z.query;else if(Y.scheme=J.scheme,Z.host!==void 0)Y.username=Z.username,Y.password=Z.password,Y.host=Z.host,Y.port=Z.port,Y.path=Q(Z.path),Y.query=Z.query;else if(Y.username=J.username,Y.password=J.password,Y.host=J.host,Y.port=J.port,!Z.path)if(Y.path=J.path,Z.query!==void 0)Y.query=Z.query;else Y.query=J.query;else{if(Z.path.charAt(0)==="/")Y.path=Q(Z.path);else Y.path=K(J.path,Z.path),Y.path=Q(Y.path);Y.query=Z.query}return Y.fragment=Z.fragment,Y.toString();function K(V,X){if(J.host!==void 0&&!J.path)return"/"+X;var W=V.lastIndexOf("/");if(W===-1)return X;else return V.substring(0,W+1)+X}function Q(V){if(!V)return V;var X="";while(V.length>0){if(V==="."||V===".."){V="";break}var W=V.substring(0,2),_=V.substring(0,3),j=V.substring(0,4);if(_==="../")V=V.substring(3);else if(W==="./")V=V.substring(2);else if(_==="/./")V="/"+V.substring(3);else if(W==="/."&&V.length===2)V="/";else if(j==="/../"||_==="/.."&&V.length===3)V="/"+V.substring(4),X=X.replace(/\/?[^\/]*$/,"");else{var H=V.match(/(\/?([^\/]*))/)[0];X+=H,V=V.substring(H.length)}}return X}}}});var u5=p((rb,m5)=>{m5.exports=lY;var f5=TJ();function lY($,J){f5.call(this,$,J)}lY.prototype=Object.create(f5.prototype,{constructor:{value:lY}})});var oY=p((ib,d5)=>{d5.exports={Event:TJ(),UIEvent:a7(),MouseEvent:e7(),CustomEvent:u5()}});var o5=p((c5)=>{Object.defineProperty(c5,"__esModule",{value:!0});c5.hyphenate=c5.parse=void 0;function tD($){let J=[],Z=0,Y=0,K=0,Q=0,V=0,X=null;while(Z<$.length)switch($.charCodeAt(Z++)){case 40:Y++;break;case 41:Y--;break;case 39:if(K===0)K=39;else if(K===39&&$.charCodeAt(Z-1)!==92)K=0;break;case 34:if(K===0)K=34;else if(K===34&&$.charCodeAt(Z-1)!==92)K=0;break;case 58:if(!X&&Y===0&&K===0)X=p5($.substring(V,Z-1).trim()),Q=Z;break;case 59:if(X&&Q>0&&Y===0&&K===0){let _=$.substring(Q,Z-1).trim();J.push(X,_),V=Z,Q=0,X=null}break}if(X&&Q){let W=$.slice(Q).trim();J.push(X,W)}return J}c5.parse=tD;function p5($){return $.replace(/[a-z][A-Z]/g,(J)=>{return J.charAt(0)+"-"+J.charAt(1)}).toLowerCase()}c5.hyphenate=p5});var tZ=p((nb,a5)=>{var{parse:$P}=o5();a5.exports=function($){let J=new n5($);return new Proxy(J,{get:function(Y,K){return K in Y?Y[K]:Y.getPropertyValue(r5(K))},has:function(Y,K){return!0},set:function(Y,K,Q){if(K in Y)Y[K]=Q;else Y.setProperty(r5(K),Q??void 0);return!0}})};function r5($){return $.replace(/([a-z])([A-Z])/g,"$1-$2").toLowerCase()}function n5($){this._element=$}var i5="!important";function s5($){let J={property:{},priority:{}};if(!$)return J;let Z=$P($);if(Z.length<2)return J;for(let Y=0;Y<Z.length;Y+=2){let K=Z[Y],Q=Z[Y+1];if(Q.endsWith(i5))J.priority[K]="important",Q=Q.slice(0,-i5.length).trim();J.property[K]=Q}return J}var fJ={};n5.prototype=Object.create(Object.prototype,{_parsed:{get:function(){if(!this._parsedStyles||this.cssText!==this._lastParsedText){var $=this.cssText;this._parsedStyles=s5($),this._lastParsedText=$,delete this._names}return this._parsedStyles}},_serialize:{value:function(){var $=this._parsed,J="";for(var Z in $.property){if(J)J+=" ";if(J+=Z+": "+$.property[Z],$.priority[Z])J+=" !"+$.priority[Z];J+=";"}this.cssText=J,this._lastParsedText=J,delete this._names}},cssText:{get:function(){return this._element.getAttribute("style")},set:function($){this._element.setAttribute("style",$)}},length:{get:function(){if(!this._names)this._names=Object.getOwnPropertyNames(this._parsed.property);return this._names.length}},item:{value:function($){if(!this._names)this._names=Object.getOwnPropertyNames(this._parsed.property);return this._names[$]}},getPropertyValue:{value:function($){return $=$.toLowerCase(),this._parsed.property[$]||""}},getPropertyPriority:{value:function($){return $=$.toLowerCase(),this._parsed.priority[$]||""}},setProperty:{value:function($,J,Z){if($=$.toLowerCase(),J===null||J===void 0)J="";if(Z===null||Z===void 0)Z="";if(J!==fJ)J=""+J;if(J=J.trim(),J===""){this.removeProperty($);return}if(Z!==""&&Z!==fJ&&!/^important$/i.test(Z))return;var Y=this._parsed;if(J===fJ){if(!Y.property[$])return;if(Z!=="")Y.priority[$]="important";else delete Y.priority[$]}else{if(J.indexOf(";")!==-1)return;var K=s5($+":"+J);if(Object.getOwnPropertyNames(K.property).length===0)return;if(Object.getOwnPropertyNames(K.priority).length!==0)return;for(var Q in K.property)if(Y.property[Q]=K.property[Q],Z===fJ)continue;else if(Z!=="")Y.priority[Q]="important";else if(Y.priority[Q])delete Y.priority[Q]}this._serialize()}},setPropertyValue:{value:function($,J){return this.setProperty($,J,fJ)}},setPropertyPriority:{value:function($,J){return this.setProperty($,fJ,J)}},removeProperty:{value:function($){$=$.toLowerCase();var J=this._parsed;if($ in J.property)delete J.property[$],delete J.priority[$],this._serialize()}}})});var rY=p((ab,t5)=>{var C0=aZ();t5.exports=v8;function v8(){}v8.prototype=Object.create(Object.prototype,{_url:{get:function(){return new C0(this.href)}},protocol:{get:function(){var $=this._url;if($&&$.scheme)return $.scheme+":";else return":"},set:function($){var J=this.href,Z=new C0(J);if(Z.isAbsolute()){if($=$.replace(/:+$/,""),$=$.replace(/[^-+\.a-zA-Z0-9]/g,C0.percentEncode),$.length>0)Z.scheme=$,J=Z.toString()}this.href=J}},host:{get:function(){var $=this._url;if($.isAbsolute()&&$.isAuthorityBased())return $.host+($.port?":"+$.port:"");else return""},set:function($){var J=this.href,Z=new C0(J);if(Z.isAbsolute()&&Z.isAuthorityBased()){if($=$.replace(/[^-+\._~!$&'()*,;:=a-zA-Z0-9]/g,C0.percentEncode),$.length>0)Z.host=$,delete Z.port,J=Z.toString()}this.href=J}},hostname:{get:function(){var $=this._url;if($.isAbsolute()&&$.isAuthorityBased())return $.host;else return""},set:function($){var J=this.href,Z=new C0(J);if(Z.isAbsolute()&&Z.isAuthorityBased()){if($=$.replace(/^\/+/,""),$=$.replace(/[^-+\._~!$&'()*,;:=a-zA-Z0-9]/g,C0.percentEncode),$.length>0)Z.host=$,J=Z.toString()}this.href=J}},port:{get:function(){var $=this._url;if($.isAbsolute()&&$.isAuthorityBased()&&$.port!==void 0)return $.port;else return""},set:function($){var J=this.href,Z=new C0(J);if(Z.isAbsolute()&&Z.isAuthorityBased()){if($=""+$,$=$.replace(/[^0-9].*$/,""),$=$.replace(/^0+/,""),$.length===0)$="0";if(parseInt($,10)<=65535)Z.port=$,J=Z.toString()}this.href=J}},pathname:{get:function(){var $=this._url;if($.isAbsolute()&&$.isHierarchical())return $.path;else return""},set:function($){var J=this.href,Z=new C0(J);if(Z.isAbsolute()&&Z.isHierarchical()){if($.charAt(0)!=="/")$="/"+$;$=$.replace(/[^-+\._~!$&'()*,;:=@\/a-zA-Z0-9]/g,C0.percentEncode),Z.path=$,J=Z.toString()}this.href=J}},search:{get:function(){var $=this._url;if($.isAbsolute()&&$.isHierarchical()&&$.query!==void 0)return"?"+$.query;else return""},set:function($){var J=this.href,Z=new C0(J);if(Z.isAbsolute()&&Z.isHierarchical()){if($.charAt(0)==="?")$=$.substring(1);$=$.replace(/[^-+\._~!$&'()*,;:=@\/?a-zA-Z0-9]/g,C0.percentEncode),Z.query=$,J=Z.toString()}this.href=J}},hash:{get:function(){var $=this._url;if($==null||$.fragment==null||$.fragment==="")return"";else return"#"+$.fragment},set:function($){var J=this.href,Z=new C0(J);if($.charAt(0)==="#")$=$.substring(1);$=$.replace(/[^-+\._~!$&'()*,;:=@\/?a-zA-Z0-9]/g,C0.percentEncode),Z.fragment=$,J=Z.toString(),this.href=J}},username:{get:function(){var $=this._url;return $.username||""},set:function($){var J=this.href,Z=new C0(J);if(Z.isAbsolute())$=$.replace(/[\x00-\x1F\x7F-\uFFFF "#<>?`\/@\\:]/g,C0.percentEncode),Z.username=$,J=Z.toString();this.href=J}},password:{get:function(){var $=this._url;return $.password||""},set:function($){var J=this.href,Z=new C0(J);if(Z.isAbsolute()){if($==="")Z.password=null;else $=$.replace(/[\x00-\x1F\x7F-\uFFFF "#<>?`\/@\\]/g,C0.percentEncode),Z.password=$;J=Z.toString()}this.href=J}},origin:{get:function(){var $=this._url;if($==null)return"";var J=function(Z){var Y=[$.scheme,$.host,+$.port||Z];return Y[0]+"://"+Y[1]+(Y[2]===Z?"":":"+Y[2])};switch($.scheme){case"ftp":return J(21);case"gopher":return J(70);case"http":case"ws":return J(80);case"https":case"wss":return J(443);default:return $.scheme+"://"}}}});v8._inherit=function($){Object.getOwnPropertyNames(v8.prototype).forEach(function(J){if(J==="constructor"||J==="href")return;var Z=Object.getOwnPropertyDescriptor(v8.prototype,J);Object.defineProperty($,J,Z)})}});var iY=p((tb,Jj)=>{var e5=_Y(),JP=hZ().isApiWritable;Jj.exports=function($,J,Z,Y){var K=$.ctor;if(K){var Q=$.props||{};if($.attributes)for(var V in $.attributes){var X=$.attributes[V];if(typeof X!=="object"||Array.isArray(X))X={type:X};if(!X.name)X.name=V.toLowerCase();Q[V]=e5.property(X)}if(Q.constructor={value:K,writable:JP},K.prototype=Object.create(($.superclass||J).prototype,Q),$.events)YP(K,$.events);Z[$.name]=K}else K=J;return($.tags||$.tag&&[$.tag]||[]).forEach(function(W){Y[W]=K}),K};function $j($,J,Z,Y){this.body=$,this.document=J,this.form=Z,this.element=Y}$j.prototype.build=function(){return()=>{}};function ZP($,J,Z,Y){var K=$.ownerDocument||Object.create(null),Q=$.form||Object.create(null);$[J]=new $j(Y,K,Q,$).build()}function YP($,J){var Z=$.prototype;J.forEach(function(Y){Object.defineProperty(Z,"on"+Y,{get:function(){return this._getEventHandler(Y)},set:function(K){this._setEventHandler(Y,K)}}),e5.registerChangeHandler($,"on"+Y,ZP)})}});var $6=p((XP)=>{var sY=P0(),Zj=gJ(),KP=tZ(),c0=X0(),Yj=rY(),QP=iY(),i1=XP.elements={},h8=Object.create(null);XP.createElement=function($,J,Z){var Y=h8[J]||GP;return new Y($,J,Z)};function o($){return QP($,K$,i1,h8)}function W0($){return{get:function(){var J=this._getattr($);if(J===null)return"";var Z=this.doc._resolve(J);return Z===null?J:Z},set:function(J){this._setattr($,J)}}}function eZ($){return{get:function(){var J=this._getattr($);if(J===null)return null;if(J.toLowerCase()==="use-credentials")return"use-credentials";return"anonymous"},set:function(J){if(J===null||J===void 0)this.removeAttribute($);else this._setattr($,J)}}}var mJ={type:["","no-referrer","no-referrer-when-downgrade","same-origin","origin","strict-origin","origin-when-cross-origin","strict-origin-when-cross-origin","unsafe-url"],missing:""},VP={A:!0,LINK:!0,BUTTON:!0,INPUT:!0,SELECT:!0,TEXTAREA:!0,COMMAND:!0},F1=function($,J,Z){K$.call(this,$,J,Z),this._form=null},K$=XP.HTMLElement=o({superclass:Zj,name:"HTMLElement",ctor:function(J,Z,Y){Zj.call(this,J,Z,c0.NAMESPACE.HTML,Y)},props:{dangerouslySetInnerHTML:{set:function($){this._innerHTML=$}},innerHTML:{get:function(){return this.serialize()},set:function($){var J=this.ownerDocument.implementation.mozHTMLParser(this.ownerDocument._address,this);J.parse($===null?"":String($),!0);var Z=this instanceof h8.template?this.content:this;while(Z.hasChildNodes())Z.removeChild(Z.firstChild);Z.appendChild(J._asDocumentFragment())}},style:{get:function(){if(!this._style)this._style=new KP(this);return this._style},set:function($){if($===null||$===void 0)$="";this._setattr("style",String($))}},blur:{value:function(){}},focus:{value:function(){}},forceSpellCheck:{value:function(){}},click:{value:function(){if(this._click_in_progress)return;this._click_in_progress=!0;try{if(this._pre_click_activation_steps)this._pre_click_activation_steps();var $=this.ownerDocument.createEvent("MouseEvent");$.initMouseEvent("click",!0,!0,this.ownerDocument.defaultView,1,0,0,0,0,!1,!1,!1,!1,0,null);var J=this.dispatchEvent($);if(J){if(this._post_click_activation_steps)this._post_click_activation_steps($)}else if(this._cancelled_activation_steps)this._cancelled_activation_steps()}finally{this._click_in_progress=!1}}},submit:{value:c0.nyi}},attributes:{title:String,lang:String,dir:{type:["ltr","rtl","auto"],missing:""},draggable:{type:["true","false"],treatNullAsEmptyString:!0},spellcheck:{type:["true","false"],missing:""},enterKeyHint:{type:["enter","done","go","next","previous","search","send"],missing:""},autoCapitalize:{type:["off","on","none","sentences","words","characters"],missing:""},autoFocus:Boolean,accessKey:String,nonce:String,hidden:Boolean,translate:{type:["no","yes"],missing:""},tabIndex:{type:"long",default:function(){if(this.tagName in VP||this.contentEditable)return 0;else return-1}}},events:["abort","canplay","canplaythrough","change","click","contextmenu","cuechange","dblclick","drag","dragend","dragenter","dragleave","dragover","dragstart","drop","durationchange","emptied","ended","input","invalid","keydown","keypress","keyup","loadeddata","loadedmetadata","loadstart","mousedown","mousemove","mouseout","mouseover","mouseup","mousewheel","pause","play","playing","progress","ratechange","readystatechange","reset","seeked","seeking","select","show","stalled","submit","suspend","timeupdate","volumechange","waiting","blur","error","focus","load","scroll"]}),GP=o({name:"HTMLUnknownElement",ctor:function(J,Z,Y){K$.call(this,J,Z,Y)}}),z1={form:{get:function(){return this._form}}};o({tag:"a",name:"HTMLAnchorElement",ctor:function(J,Z,Y){K$.call(this,J,Z,Y)},props:{_post_click_activation_steps:{value:function($){if(this.href)this.ownerDocument.defaultView.location=this.href}}},attributes:{href:W0,ping:String,download:String,target:String,rel:String,media:String,hreflang:String,type:String,referrerPolicy:mJ,coords:String,charset:String,name:String,rev:String,shape:String}});Yj._inherit(h8.a.prototype);o({tag:"area",name:"HTMLAreaElement",ctor:function(J,Z,Y){K$.call(this,J,Z,Y)},attributes:{alt:String,target:String,download:String,rel:String,media:String,href:W0,hreflang:String,type:String,shape:String,coords:String,ping:String,referrerPolicy:mJ,noHref:Boolean}});Yj._inherit(h8.area.prototype);o({tag:"br",name:"HTMLBRElement",ctor:function(J,Z,Y){K$.call(this,J,Z,Y)},attributes:{clear:String}});o({tag:"base",name:"HTMLBaseElement",ctor:function(J,Z,Y){K$.call(this,J,Z,Y)},attributes:{target:String}});o({tag:"body",name:"HTMLBodyElement",ctor:function(J,Z,Y){K$.call(this,J,Z,Y)},events:["afterprint","beforeprint","beforeunload","blur","error","focus","hashchange","load","message","offline","online","pagehide","pageshow","popstate","resize","scroll","storage","unload"],attributes:{text:{type:String,treatNullAsEmptyString:!0},link:{type:String,treatNullAsEmptyString:!0},vLink:{type:String,treatNullAsEmptyString:!0},aLink:{type:String,treatNullAsEmptyString:!0},bgColor:{type:String,treatNullAsEmptyString:!0},background:String}});o({tag:"button",name:"HTMLButtonElement",ctor:function(J,Z,Y){F1.call(this,J,Z,Y)},props:z1,attributes:{name:String,value:String,disabled:Boolean,autofocus:Boolean,type:{type:["submit","reset","button","menu"],missing:"submit"},formTarget:String,formAction:W0,formNoValidate:Boolean,formMethod:{type:["get","post","dialog"],invalid:"get",missing:""},formEnctype:{type:["application/x-www-form-urlencoded","multipart/form-data","text/plain"],invalid:"application/x-www-form-urlencoded",missing:""}}});o({tag:"dl",name:"HTMLDListElement",ctor:function(J,Z,Y){K$.call(this,J,Z,Y)},attributes:{compact:Boolean}});o({tag:"data",name:"HTMLDataElement",ctor:function(J,Z,Y){K$.call(this,J,Z,Y)},attributes:{value:String}});o({tag:"datalist",name:"HTMLDataListElement",ctor:function(J,Z,Y){K$.call(this,J,Z,Y)}});o({tag:"details",name:"HTMLDetailsElement",ctor:function(J,Z,Y){K$.call(this,J,Z,Y)},attributes:{open:Boolean}});o({tag:"div",name:"HTMLDivElement",ctor:function(J,Z,Y){K$.call(this,J,Z,Y)},attributes:{align:String}});o({tag:"embed",name:"HTMLEmbedElement",ctor:function(J,Z,Y){K$.call(this,J,Z,Y)},attributes:{src:W0,type:String,width:String,height:String,align:String,name:String}});o({tag:"fieldset",name:"HTMLFieldSetElement",ctor:function(J,Z,Y){F1.call(this,J,Z,Y)},props:z1,attributes:{disabled:Boolean,name:String}});o({tag:"form",name:"HTMLFormElement",ctor:function(J,Z,Y){K$.call(this,J,Z,Y)},attributes:{action:String,autocomplete:{type:["on","off"],missing:"on"},name:String,acceptCharset:{name:"accept-charset"},target:String,noValidate:Boolean,method:{type:["get","post","dialog"],invalid:"get",missing:"get"},enctype:{type:["application/x-www-form-urlencoded","multipart/form-data","text/plain"],invalid:"application/x-www-form-urlencoded",missing:"application/x-www-form-urlencoded"},encoding:{name:"enctype",type:["application/x-www-form-urlencoded","multipart/form-data","text/plain"],invalid:"application/x-www-form-urlencoded",missing:"application/x-www-form-urlencoded"}}});o({tag:"hr",name:"HTMLHRElement",ctor:function(J,Z,Y){K$.call(this,J,Z,Y)},attributes:{align:String,color:String,noShade:Boolean,size:String,width:String}});o({tag:"head",name:"HTMLHeadElement",ctor:function(J,Z,Y){K$.call(this,J,Z,Y)}});o({tags:["h1","h2","h3","h4","h5","h6"],name:"HTMLHeadingElement",ctor:function(J,Z,Y){K$.call(this,J,Z,Y)},attributes:{align:String}});o({tag:"html",name:"HTMLHtmlElement",ctor:function(J,Z,Y){K$.call(this,J,Z,Y)},attributes:{xmlns:W0,version:String}});o({tag:"iframe",name:"HTMLIFrameElement",ctor:function(J,Z,Y){K$.call(this,J,Z,Y)},attributes:{src:W0,srcdoc:String,name:String,width:String,height:String,seamless:Boolean,allow:Boolean,allowFullscreen:Boolean,allowUserMedia:Boolean,allowPaymentRequest:Boolean,referrerPolicy:mJ,loading:{type:["eager","lazy"],treatNullAsEmptyString:!0},align:String,scrolling:String,frameBorder:String,longDesc:W0,marginHeight:{type:String,treatNullAsEmptyString:!0},marginWidth:{type:String,treatNullAsEmptyString:!0}}});o({tag:"img",name:"HTMLImageElement",ctor:function(J,Z,Y){K$.call(this,J,Z,Y)},attributes:{alt:String,src:W0,srcset:String,crossOrigin:eZ,useMap:String,isMap:Boolean,sizes:String,height:{type:"unsigned long",default:0},width:{type:"unsigned long",default:0},referrerPolicy:mJ,loading:{type:["eager","lazy"],missing:""},name:String,lowsrc:W0,align:String,hspace:{type:"unsigned long",default:0},vspace:{type:"unsigned long",default:0},longDesc:W0,border:{type:String,treatNullAsEmptyString:!0}}});o({tag:"input",name:"HTMLInputElement",ctor:function(J,Z,Y){F1.call(this,J,Z,Y)},props:{form:z1.form,_post_click_activation_steps:{value:function($){if(this.type==="checkbox")this.checked=!this.checked;else if(this.type==="radio"){var J=this.form.getElementsByName(this.name);for(var Z=J.length-1;Z>=0;Z--){var Y=J[Z];Y.checked=Y===this}}}}},attributes:{name:String,disabled:Boolean,autofocus:Boolean,accept:String,alt:String,max:String,min:String,pattern:String,placeholder:String,step:String,dirName:String,defaultValue:{name:"value"},multiple:Boolean,required:Boolean,readOnly:Boolean,checked:Boolean,value:String,src:W0,defaultChecked:{name:"checked",type:Boolean},size:{type:"unsigned long",default:20,min:1,setmin:1},width:{type:"unsigned long",min:0,setmin:0,default:0},height:{type:"unsigned long",min:0,setmin:0,default:0},minLength:{type:"unsigned long",min:0,setmin:0,default:-1},maxLength:{type:"unsigned long",min:0,setmin:0,default:-1},autocomplete:String,type:{type:["text","hidden","search","tel","url","email","password","datetime","date","month","week","time","datetime-local","number","range","color","checkbox","radio","file","submit","image","reset","button"],missing:"text"},formTarget:String,formNoValidate:Boolean,formMethod:{type:["get","post"],invalid:"get",missing:""},formEnctype:{type:["application/x-www-form-urlencoded","multipart/form-data","text/plain"],invalid:"application/x-www-form-urlencoded",missing:""},inputMode:{type:["verbatim","latin","latin-name","latin-prose","full-width-latin","kana","kana-name","katakana","numeric","tel","email","url"],missing:""},align:String,useMap:String}});o({tag:"keygen",name:"HTMLKeygenElement",ctor:function(J,Z,Y){F1.call(this,J,Z,Y)},props:z1,attributes:{name:String,disabled:Boolean,autofocus:Boolean,challenge:String,keytype:{type:["rsa"],missing:""}}});o({tag:"li",name:"HTMLLIElement",ctor:function(J,Z,Y){K$.call(this,J,Z,Y)},attributes:{value:{type:"long",default:0},type:String}});o({tag:"label",name:"HTMLLabelElement",ctor:function(J,Z,Y){F1.call(this,J,Z,Y)},props:z1,attributes:{htmlFor:{name:"for",type:String}}});o({tag:"legend",name:"HTMLLegendElement",ctor:function(J,Z,Y){K$.call(this,J,Z,Y)},attributes:{align:String}});o({tag:"link",name:"HTMLLinkElement",ctor:function(J,Z,Y){K$.call(this,J,Z,Y)},attributes:{href:W0,rel:String,media:String,hreflang:String,type:String,crossOrigin:eZ,nonce:String,integrity:String,referrerPolicy:mJ,imageSizes:String,imageSrcset:String,charset:String,rev:String,target:String}});o({tag:"map",name:"HTMLMapElement",ctor:function(J,Z,Y){K$.call(this,J,Z,Y)},attributes:{name:String}});o({tag:"menu",name:"HTMLMenuElement",ctor:function(J,Z,Y){K$.call(this,J,Z,Y)},attributes:{type:{type:["context","popup","toolbar"],missing:"toolbar"},label:String,compact:Boolean}});o({tag:"meta",name:"HTMLMetaElement",ctor:function(J,Z,Y){K$.call(this,J,Z,Y)},attributes:{name:String,content:String,httpEquiv:{name:"http-equiv",type:String},scheme:String}});o({tag:"meter",name:"HTMLMeterElement",ctor:function(J,Z,Y){F1.call(this,J,Z,Y)},props:z1});o({tags:["ins","del"],name:"HTMLModElement",ctor:function(J,Z,Y){K$.call(this,J,Z,Y)},attributes:{cite:W0,dateTime:String}});o({tag:"ol",name:"HTMLOListElement",ctor:function(J,Z,Y){K$.call(this,J,Z,Y)},props:{_numitems:{get:function(){var $=0;return this.childNodes.forEach(function(J){if(J.nodeType===sY.ELEMENT_NODE&&J.tagName==="LI")$++}),$}}},attributes:{type:String,reversed:Boolean,start:{type:"long",default:function(){if(this.reversed)return this._numitems;else return 1}},compact:Boolean}});o({tag:"object",name:"HTMLObjectElement",ctor:function(J,Z,Y){F1.call(this,J,Z,Y)},props:z1,attributes:{data:W0,type:String,name:String,useMap:String,typeMustMatch:Boolean,width:String,height:String,align:String,archive:String,code:String,declare:Boolean,hspace:{type:"unsigned long",default:0},standby:String,vspace:{type:"unsigned long",default:0},codeBase:W0,codeType:String,border:{type:String,treatNullAsEmptyString:!0}}});o({tag:"optgroup",name:"HTMLOptGroupElement",ctor:function(J,Z,Y){K$.call(this,J,Z,Y)},attributes:{disabled:Boolean,label:String}});o({tag:"option",name:"HTMLOptionElement",ctor:function(J,Z,Y){K$.call(this,J,Z,Y)},props:{form:{get:function(){var $=this.parentNode;while($&&$.nodeType===sY.ELEMENT_NODE){if($.localName==="select")return $.form;$=$.parentNode}}},value:{get:function(){return this._getattr("value")||this.text},set:function($){this._setattr("value",$)}},text:{get:function(){return this.textContent.replace(/[ \t\n\f\r]+/g," ").trim()},set:function($){this.textContent=$}}},attributes:{disabled:Boolean,defaultSelected:{name:"selected",type:Boolean},label:String}});o({tag:"output",name:"HTMLOutputElement",ctor:function(J,Z,Y){F1.call(this,J,Z,Y)},props:z1,attributes:{name:String}});o({tag:"p",name:"HTMLParagraphElement",ctor:function(J,Z,Y){K$.call(this,J,Z,Y)},attributes:{align:String}});o({tag:"param",name:"HTMLParamElement",ctor:function(J,Z,Y){K$.call(this,J,Z,Y)},attributes:{name:String,value:String,type:String,valueType:String}});o({tags:["pre","listing","xmp"],name:"HTMLPreElement",ctor:function(J,Z,Y){K$.call(this,J,Z,Y)},attributes:{width:{type:"long",default:0}}});o({tag:"progress",name:"HTMLProgressElement",ctor:function(J,Z,Y){F1.call(this,J,Z,Y)},props:z1,attributes:{max:{type:Number,float:!0,default:1,min:0}}});o({tags:["q","blockquote"],name:"HTMLQuoteElement",ctor:function(J,Z,Y){K$.call(this,J,Z,Y)},attributes:{cite:W0}});o({tag:"script",name:"HTMLScriptElement",ctor:function(J,Z,Y){K$.call(this,J,Z,Y)},props:{text:{get:function(){var $="";for(var J=0,Z=this.childNodes.length;J<Z;J++){var Y=this.childNodes[J];if(Y.nodeType===sY.TEXT_NODE)$+=Y._data}return $},set:function($){if(this.removeChildren(),$!==null&&$!=="")this.appendChild(this.ownerDocument.createTextNode($))}}},attributes:{src:W0,type:String,charset:String,referrerPolicy:mJ,defer:Boolean,async:Boolean,nomodule:Boolean,crossOrigin:eZ,nonce:String,integrity:String}});o({tag:"select",name:"HTMLSelectElement",ctor:function(J,Z,Y){F1.call(this,J,Z,Y)},props:{form:z1.form,options:{get:function(){return this.getElementsByTagName("option")}}},attributes:{autocomplete:String,name:String,disabled:Boolean,autofocus:Boolean,multiple:Boolean,required:Boolean,size:{type:"unsigned long",default:0}}});o({tag:"span",name:"HTMLSpanElement",ctor:function(J,Z,Y){K$.call(this,J,Z,Y)}});o({tag:"style",name:"HTMLStyleElement",ctor:function(J,Z,Y){K$.call(this,J,Z,Y)},attributes:{media:String,type:String,scoped:Boolean}});o({tag:"caption",name:"HTMLTableCaptionElement",ctor:function(J,Z,Y){K$.call(this,J,Z,Y)},attributes:{align:String}});o({name:"HTMLTableCellElement",ctor:function(J,Z,Y){K$.call(this,J,Z,Y)},attributes:{colSpan:{type:"unsigned long",default:1},rowSpan:{type:"unsigned long",default:1},scope:{type:["row","col","rowgroup","colgroup"],missing:""},abbr:String,align:String,axis:String,height:String,width:String,ch:{name:"char",type:String},chOff:{name:"charoff",type:String},noWrap:Boolean,vAlign:String,bgColor:{type:String,treatNullAsEmptyString:!0}}});o({tags:["col","colgroup"],name:"HTMLTableColElement",ctor:function(J,Z,Y){K$.call(this,J,Z,Y)},attributes:{span:{type:"limited unsigned long with fallback",default:1,min:1},align:String,ch:{name:"char",type:String},chOff:{name:"charoff",type:String},vAlign:String,width:String}});o({tag:"table",name:"HTMLTableElement",ctor:function(J,Z,Y){K$.call(this,J,Z,Y)},props:{rows:{get:function(){return this.getElementsByTagName("tr")}}},attributes:{align:String,border:String,frame:String,rules:String,summary:String,width:String,bgColor:{type:String,treatNullAsEmptyString:!0},cellPadding:{type:String,treatNullAsEmptyString:!0},cellSpacing:{type:String,treatNullAsEmptyString:!0}}});o({tag:"template",name:"HTMLTemplateElement",ctor:function(J,Z,Y){K$.call(this,J,Z,Y),this._contentFragment=J._templateDoc.createDocumentFragment()},props:{content:{get:function(){return this._contentFragment}},serialize:{value:function(){return this.content.serialize()}}}});o({tag:"tr",name:"HTMLTableRowElement",ctor:function(J,Z,Y){K$.call(this,J,Z,Y)},props:{cells:{get:function(){return this.querySelectorAll("td,th")}}},attributes:{align:String,ch:{name:"char",type:String},chOff:{name:"charoff",type:String},vAlign:String,bgColor:{type:String,treatNullAsEmptyString:!0}}});o({tags:["thead","tfoot","tbody"],name:"HTMLTableSectionElement",ctor:function(J,Z,Y){K$.call(this,J,Z,Y)},props:{rows:{get:function(){return this.getElementsByTagName("tr")}}},attributes:{align:String,ch:{name:"char",type:String},chOff:{name:"charoff",type:String},vAlign:String}});o({tag:"textarea",name:"HTMLTextAreaElement",ctor:function(J,Z,Y){F1.call(this,J,Z,Y)},props:{form:z1.form,type:{get:function(){return"textarea"}},defaultValue:{get:function(){return this.textContent},set:function($){this.textContent=$}},value:{get:function(){return this.defaultValue},set:function($){this.defaultValue=$}},textLength:{get:function(){return this.value.length}}},attributes:{autocomplete:String,name:String,disabled:Boolean,autofocus:Boolean,placeholder:String,wrap:String,dirName:String,required:Boolean,readOnly:Boolean,rows:{type:"limited unsigned long with fallback",default:2},cols:{type:"limited unsigned long with fallback",default:20},maxLength:{type:"unsigned long",min:0,setmin:0,default:-1},minLength:{type:"unsigned long",min:0,setmin:0,default:-1},inputMode:{type:["verbatim","latin","latin-name","latin-prose","full-width-latin","kana","kana-name","katakana","numeric","tel","email","url"],missing:""}}});o({tag:"time",name:"HTMLTimeElement",ctor:function(J,Z,Y){K$.call(this,J,Z,Y)},attributes:{dateTime:String,pubDate:Boolean}});o({tag:"title",name:"HTMLTitleElement",ctor:function(J,Z,Y){K$.call(this,J,Z,Y)},props:{text:{get:function(){return this.textContent}}}});o({tag:"ul",name:"HTMLUListElement",ctor:function(J,Z,Y){K$.call(this,J,Z,Y)},attributes:{type:String,compact:Boolean}});o({name:"HTMLMediaElement",ctor:function(J,Z,Y){K$.call(this,J,Z,Y)},attributes:{src:W0,crossOrigin:eZ,preload:{type:["metadata","none","auto",{value:"",alias:"auto"}],missing:"auto"},loop:Boolean,autoplay:Boolean,mediaGroup:String,controls:Boolean,defaultMuted:{name:"muted",type:Boolean}}});o({name:"HTMLAudioElement",tag:"audio",superclass:i1.HTMLMediaElement,ctor:function(J,Z,Y){i1.HTMLMediaElement.call(this,J,Z,Y)}});o({name:"HTMLVideoElement",tag:"video",superclass:i1.HTMLMediaElement,ctor:function(J,Z,Y){i1.HTMLMediaElement.call(this,J,Z,Y)},attributes:{poster:W0,width:{type:"unsigned long",min:0,default:0},height:{type:"unsigned long",min:0,default:0}}});o({tag:"td",name:"HTMLTableDataCellElement",superclass:i1.HTMLTableCellElement,ctor:function(J,Z,Y){i1.HTMLTableCellElement.call(this,J,Z,Y)}});o({tag:"th",name:"HTMLTableHeaderCellElement",superclass:i1.HTMLTableCellElement,ctor:function(J,Z,Y){i1.HTMLTableCellElement.call(this,J,Z,Y)}});o({tag:"frameset",name:"HTMLFrameSetElement",ctor:function(J,Z,Y){K$.call(this,J,Z,Y)}});o({tag:"frame",name:"HTMLFrameElement",ctor:function(J,Z,Y){K$.call(this,J,Z,Y)}});o({tag:"canvas",name:"HTMLCanvasElement",ctor:function(J,Z,Y){K$.call(this,J,Z,Y)},props:{getContext:{value:c0.nyi},probablySupportsContext:{value:c0.nyi},setContext:{value:c0.nyi},transferControlToProxy:{value:c0.nyi},toDataURL:{value:c0.nyi},toBlob:{value:c0.nyi}},attributes:{width:{type:"unsigned long",default:300},height:{type:"unsigned long",default:150}}});o({tag:"dialog",name:"HTMLDialogElement",ctor:function(J,Z,Y){K$.call(this,J,Z,Y)},props:{show:{value:c0.nyi},showModal:{value:c0.nyi},close:{value:c0.nyi}},attributes:{open:Boolean,returnValue:String}});o({tag:"menuitem",name:"HTMLMenuItemElement",ctor:function(J,Z,Y){K$.call(this,J,Z,Y)},props:{_label:{get:function(){var $=this._getattr("label");if($!==null&&$!=="")return $;return $=this.textContent,$.replace(/[ \t\n\f\r]+/g," ").trim()}},label:{get:function(){var $=this._getattr("label");if($!==null)return $;return this._label},set:function($){this._setattr("label",$)}}},attributes:{type:{type:["command","checkbox","radio"],missing:"command"},icon:W0,disabled:Boolean,checked:Boolean,radiogroup:String,default:Boolean}});o({tag:"source",name:"HTMLSourceElement",ctor:function(J,Z,Y){K$.call(this,J,Z,Y)},attributes:{srcset:String,sizes:String,media:String,src:W0,type:String,width:String,height:String}});o({tag:"track",name:"HTMLTrackElement",ctor:function(J,Z,Y){K$.call(this,J,Z,Y)},attributes:{src:W0,srclang:String,label:String,default:Boolean,kind:{type:["subtitles","captions","descriptions","chapters","metadata"],missing:"subtitles",invalid:"metadata"}},props:{NONE:{get:function(){return 0}},LOADING:{get:function(){return 1}},LOADED:{get:function(){return 2}},ERROR:{get:function(){return 3}},readyState:{get:c0.nyi},track:{get:c0.nyi}}});o({tag:"font",name:"HTMLFontElement",ctor:function(J,Z,Y){K$.call(this,J,Z,Y)},attributes:{color:{type:String,treatNullAsEmptyString:!0},face:{type:String},size:{type:String}}});o({tag:"dir",name:"HTMLDirectoryElement",ctor:function(J,Z,Y){K$.call(this,J,Z,Y)},attributes:{compact:Boolean}});o({tags:["abbr","address","article","aside","b","bdi","bdo","cite","content","code","dd","dfn","dt","em","figcaption","figure","footer","header","hgroup","i","kbd","main","mark","nav","noscript","rb","rp","rt","rtc","ruby","s","samp","section","small","strong","sub","summary","sup","u","var","wbr","acronym","basefont","big","center","nobr","noembed","noframes","plaintext","strike","tt"]})});var tY=p((_P)=>{var Kj=gJ(),jP=iY(),UP=X0(),BP=tZ(),HP=_P.elements={},Qj=Object.create(null);_P.createElement=function($,J,Z){var Y=Qj[J]||aY;return new Y($,J,Z)};function nY($){return jP($,aY,HP,Qj)}var aY=nY({superclass:Kj,name:"SVGElement",ctor:function(J,Z,Y){Kj.call(this,J,Z,UP.NAMESPACE.SVG,Y)},props:{style:{get:function(){if(!this._style)this._style=new BP(this);return this._style}}}});nY({name:"SVGSVGElement",ctor:function(J,Z,Y){aY.call(this,J,Z,Y)},tag:"svg",props:{createSVGRect:{value:function(){return _P.createElement(this.ownerDocument,"rect",null)}}}});nY({tags:["a","altGlyph","altGlyphDef","altGlyphItem","animate","animateColor","animateMotion","animateTransform","circle","clipPath","color-profile","cursor","defs","desc","ellipse","feBlend","feColorMatrix","feComponentTransfer","feComposite","feConvolveMatrix","feDiffuseLighting","feDisplacementMap","feDistantLight","feFlood","feFuncA","feFuncB","feFuncG","feFuncR","feGaussianBlur","feImage","feMerge","feMergeNode","feMorphology","feOffset","fePointLight","feSpecularLighting","feSpotLight","feTile","feTurbulence","filter","font","font-face","font-face-format","font-face-name","font-face-src","font-face-uri","foreignObject","g","glyph","glyphRef","hkern","image","line","linearGradient","marker","mask","metadata","missing-glyph","mpath","path","pattern","polygon","polyline","radialGradient","rect","script","set","stop","style","switch","symbol","text","textPath","title","tref","tspan","use","view","vkern"]})});var Xj=p((Kv,Gj)=>{Gj.exports={VALUE:1,ATTR:2,REMOVE_ATTR:3,REMOVE:4,MOVE:5,INSERT:6}});var Z6=p((Qv,zj)=>{zj.exports=f8;var R0=P0(),OP=n2(),_j=mZ(),q2=gJ(),qP=TY(),FP=EY(),g8=TJ(),zP=bY(),CP=hY(),MP=m8(),DP=T5(),PP=h5(),Wj=b8(),jj=aZ(),Uj=lZ(),IP=oY(),J6=uZ(),eY=$6(),AP=tY(),v$=X0(),uJ=Xj(),pJ=v$.NAMESPACE,$3=hZ().isApiWritable;function f8($,J){_j.call(this),this.nodeType=R0.DOCUMENT_NODE,this.isHTML=$,this._address=J||"about:blank",this.readyState="loading",this.implementation=new MP(this),this.ownerDocument=null,this._contentType=$?"text/html":"application/xml",this.doctype=null,this.documentElement=null,this._templateDocCache=null,this._nodeIterators=null,this._nid=1,this._nextnid=2,this._nodes=[null,this],this.byId=Object.create(null),this.modclock=0}var SP={event:"Event",customevent:"CustomEvent",uievent:"UIEvent",mouseevent:"MouseEvent"},wP={events:"event",htmlevents:"event",mouseevents:"mouseevent",mutationevents:"mutationevent",uievents:"uievent"},dJ=function($,J,Z){return{get:function(){var Y=$.call(this);if(Y)return Y[J];return Z},set:function(Y){var K=$.call(this);if(K)K[J]=Y}}};function Bj($,J){var Z,Y,K;if($==="")$=null;if(!J6.isValidQName(J))v$.InvalidCharacterError();if(Z=null,Y=J,K=J.indexOf(":"),K>=0)Z=J.substring(0,K),Y=J.substring(K+1);if(Z!==null&&$===null)v$.NamespaceError();if(Z==="xml"&&$!==pJ.XML)v$.NamespaceError();if((Z==="xmlns"||J==="xmlns")&&$!==pJ.XMLNS)v$.NamespaceError();if($===pJ.XMLNS&&!(Z==="xmlns"||J==="xmlns"))v$.NamespaceError();return{namespace:$,prefix:Z,localName:Y}}f8.prototype=Object.create(_j.prototype,{_setMutationHandler:{value:function($){this.mutationHandler=$}},_dispatchRendererEvent:{value:function($,J,Z){var Y=this._nodes[$];if(!Y)return;Y._dispatchEvent(new g8(J,Z),!0)}},nodeName:{value:"#document"},nodeValue:{get:function(){return null},set:function(){}},documentURI:{get:function(){return this._address},set:v$.nyi},compatMode:{get:function(){return this._quirks?"BackCompat":"CSS1Compat"}},createTextNode:{value:function($){return new qP(this,String($))}},createComment:{value:function($){return new FP(this,$)}},createDocumentFragment:{value:function(){return new zP(this)}},createProcessingInstruction:{value:function($,J){if(!J6.isValidName($)||J.indexOf("?>")!==-1)v$.InvalidCharacterError();return new CP(this,$,J)}},createAttribute:{value:function($){if($=String($),!J6.isValidName($))v$.InvalidCharacterError();if(this.isHTML)$=v$.toASCIILowerCase($);return new q2._Attr(null,$,null,null,"")}},createAttributeNS:{value:function($,J){$=$===null||$===void 0||$===""?null:String($),J=String(J);var Z=Bj($,J);return new q2._Attr(null,Z.localName,Z.prefix,Z.namespace,"")}},createElement:{value:function($){if($=String($),!J6.isValidName($))v$.InvalidCharacterError();if(this.isHTML){if(/[A-Z]/.test($))$=v$.toASCIILowerCase($);return eY.createElement(this,$,null)}else if(this.contentType==="application/xhtml+xml")return eY.createElement(this,$,null);else return new q2(this,$,null,null)},writable:$3},createElementNS:{value:function($,J){$=$===null||$===void 0||$===""?null:String($),J=String(J);var Z=Bj($,J);return this._createElementNS(Z.localName,Z.namespace,Z.prefix)},writable:$3},_createElementNS:{value:function($,J,Z){if(J===pJ.HTML)return eY.createElement(this,$,Z);else if(J===pJ.SVG)return AP.createElement(this,$,Z);return new q2(this,$,J,Z)}},createEvent:{value:function(J){J=J.toLowerCase();var Z=wP[J]||J,Y=IP[SP[Z]];if(Y){var K=new Y;return K._initialized=!1,K}else v$.NotSupportedError()}},createTreeWalker:{value:function($,J,Z){if(!$)throw TypeError("root argument is required");if(!($ instanceof R0))throw TypeError("root not a node");return J=J===void 0?Wj.SHOW_ALL:+J,Z=Z===void 0?null:Z,new DP($,J,Z)}},createNodeIterator:{value:function($,J,Z){if(!$)throw TypeError("root argument is required");if(!($ instanceof R0))throw TypeError("root not a node");return J=J===void 0?Wj.SHOW_ALL:+J,Z=Z===void 0?null:Z,new PP($,J,Z)}},_attachNodeIterator:{value:function($){if(!this._nodeIterators)this._nodeIterators=[];this._nodeIterators.push($)}},_detachNodeIterator:{value:function($){var J=this._nodeIterators.indexOf($);this._nodeIterators.splice(J,1)}},_preremoveNodeIterators:{value:function($){if(this._nodeIterators)this._nodeIterators.forEach(function(J){J._preremove($)})}},_updateDocTypeElement:{value:function(){this.doctype=this.documentElement=null;for(var J=this.firstChild;J!==null;J=J.nextSibling)if(J.nodeType===R0.DOCUMENT_TYPE_NODE)this.doctype=J;else if(J.nodeType===R0.ELEMENT_NODE)this.documentElement=J}},insertBefore:{value:function(J,Z){return R0.prototype.insertBefore.call(this,J,Z),this._updateDocTypeElement(),J}},replaceChild:{value:function(J,Z){return R0.prototype.replaceChild.call(this,J,Z),this._updateDocTypeElement(),Z}},removeChild:{value:function(J){return R0.prototype.removeChild.call(this,J),this._updateDocTypeElement(),J}},getElementById:{value:function($){var J=this.byId[$];if(!J)return null;if(J instanceof s1)return J.getFirst();return J}},_hasMultipleElementsWithId:{value:function($){return this.byId[$]instanceof s1}},getElementsByName:{value:q2.prototype.getElementsByName},getElementsByTagName:{value:q2.prototype.getElementsByTagName},getElementsByTagNameNS:{value:q2.prototype.getElementsByTagNameNS},getElementsByClassName:{value:q2.prototype.getElementsByClassName},adoptNode:{value:function(J){if(J.nodeType===R0.DOCUMENT_NODE)v$.NotSupportedError();if(J.nodeType===R0.ATTRIBUTE_NODE)return J;if(J.parentNode)J.parentNode.removeChild(J);if(J.ownerDocument!==this)Fj(J,this);return J}},importNode:{value:function(J,Z){return this.adoptNode(J.cloneNode(Z))},writable:$3},origin:{get:function(){return null}},characterSet:{get:function(){return"UTF-8"}},contentType:{get:function(){return this._contentType}},URL:{get:function(){return this._address}},domain:{get:v$.nyi,set:v$.nyi},referrer:{get:v$.nyi},cookie:{get:v$.nyi,set:v$.nyi},lastModified:{get:v$.nyi},location:{get:function(){return this.defaultView?this.defaultView.location:null},set:v$.nyi},_titleElement:{get:function(){return this.getElementsByTagName("title").item(0)||null}},title:{get:function(){var $=this._titleElement,J=$?$.textContent:"";return J.replace(/[ \t\n\r\f]+/g," ").replace(/(^ )|( $)/g,"")},set:function($){var J=this._titleElement,Z=this.head;if(!J&&!Z)return;if(!J)J=this.createElement("title"),Z.appendChild(J);J.textContent=$}},dir:dJ(function(){var $=this.documentElement;if($&&$.tagName==="HTML")return $},"dir",""),fgColor:dJ(function(){return this.body},"text",""),linkColor:dJ(function(){return this.body},"link",""),vlinkColor:dJ(function(){return this.body},"vLink",""),alinkColor:dJ(function(){return this.body},"aLink",""),bgColor:dJ(function(){return this.body},"bgColor",""),charset:{get:function(){return this.characterSet}},inputEncoding:{get:function(){return this.characterSet}},scrollingElement:{get:function(){return this._quirks?this.body:this.documentElement}},body:{get:function(){return Hj(this.documentElement,"body")},set:v$.nyi},head:{get:function(){return Hj(this.documentElement,"head")}},images:{get:v$.nyi},embeds:{get:v$.nyi},plugins:{get:v$.nyi},links:{get:v$.nyi},forms:{get:v$.nyi},scripts:{get:v$.nyi},applets:{get:function(){return[]}},activeElement:{get:function(){return null}},innerHTML:{get:function(){return this.serialize()},set:v$.nyi},outerHTML:{get:function(){return this.serialize()},set:v$.nyi},write:{value:function($){if(!this.isHTML)v$.InvalidStateError();if(!this._parser)return;if(!this._parser);var J=arguments.join("");this._parser.parse(J)}},writeln:{value:function(J){this.write(Array.prototype.join.call(arguments,"")+`
|
|
32
|
+
`)}},open:{value:function(){this.documentElement=null}},close:{value:function(){if(this.readyState="interactive",this._dispatchEvent(new g8("readystatechange"),!0),this._dispatchEvent(new g8("DOMContentLoaded"),!0),this.readyState="complete",this._dispatchEvent(new g8("readystatechange"),!0),this.defaultView)this.defaultView._dispatchEvent(new g8("load"),!0)}},clone:{value:function(){var J=new f8(this.isHTML,this._address);return J._quirks=this._quirks,J._contentType=this._contentType,J}},cloneNode:{value:function(J){var Z=R0.prototype.cloneNode.call(this,!1);if(J)for(var Y=this.firstChild;Y!==null;Y=Y.nextSibling)Z._appendChild(Z.importNode(Y,!0));return Z._updateDocTypeElement(),Z}},isEqual:{value:function(J){return!0}},mutateValue:{value:function($){if(this.mutationHandler)this.mutationHandler({type:uJ.VALUE,target:$,data:$.data})}},mutateAttr:{value:function($,J){if(this.mutationHandler)this.mutationHandler({type:uJ.ATTR,target:$.ownerElement,attr:$})}},mutateRemoveAttr:{value:function($){if(this.mutationHandler)this.mutationHandler({type:uJ.REMOVE_ATTR,target:$.ownerElement,attr:$})}},mutateRemove:{value:function($){if(this.mutationHandler)this.mutationHandler({type:uJ.REMOVE,target:$.parentNode,node:$});qj($)}},mutateInsert:{value:function($){if(Oj($),this.mutationHandler)this.mutationHandler({type:uJ.INSERT,target:$.parentNode,node:$})}},mutateMove:{value:function($){if(this.mutationHandler)this.mutationHandler({type:uJ.MOVE,target:$})}},addId:{value:function(J,Z){var Y=this.byId[J];if(!Y)this.byId[J]=Z;else{if(!(Y instanceof s1))Y=new s1(Y),this.byId[J]=Y;Y.add(Z)}}},delId:{value:function(J,Z){var Y=this.byId[J];if(v$.assert(Y),Y instanceof s1){if(Y.del(Z),Y.length===1)this.byId[J]=Y.downgrade()}else this.byId[J]=void 0}},_resolve:{value:function($){return new jj(this._documentBaseURL).resolve($)}},_documentBaseURL:{get:function(){var $=this._address;if($==="about:blank")$="/";var J=this.querySelector("base[href]");if(J)return new jj($).resolve(J.getAttribute("href"));return $}},_templateDoc:{get:function(){if(!this._templateDocCache){var $=new f8(this.isHTML,this._address);this._templateDocCache=$._templateDocCache=$}return this._templateDocCache}},querySelector:{value:function($){return Uj($,this)[0]}},querySelectorAll:{value:function($){var J=Uj($,this);return J.item?J:new OP(J)}}});var RP=["abort","canplay","canplaythrough","change","click","contextmenu","cuechange","dblclick","drag","dragend","dragenter","dragleave","dragover","dragstart","drop","durationchange","emptied","ended","input","invalid","keydown","keypress","keyup","loadeddata","loadedmetadata","loadstart","mousedown","mousemove","mouseout","mouseover","mouseup","mousewheel","pause","play","playing","progress","ratechange","readystatechange","reset","seeked","seeking","select","show","stalled","submit","suspend","timeupdate","volumechange","waiting","blur","error","focus","load","scroll"];RP.forEach(function($){Object.defineProperty(f8.prototype,"on"+$,{get:function(){return this._getEventHandler($)},set:function(J){this._setEventHandler($,J)}})});function Hj($,J){if($&&$.isHTML){for(var Z=$.firstChild;Z!==null;Z=Z.nextSibling)if(Z.nodeType===R0.ELEMENT_NODE&&Z.localName===J&&Z.namespaceURI===pJ.HTML)return Z}return null}function LP($){if($._nid=$.ownerDocument._nextnid++,$.ownerDocument._nodes[$._nid]=$,$.nodeType===R0.ELEMENT_NODE){var J=$.getAttribute("id");if(J)$.ownerDocument.addId(J,$);if($._roothook)$._roothook()}}function NP($){if($.nodeType===R0.ELEMENT_NODE){var J=$.getAttribute("id");if(J)$.ownerDocument.delId(J,$)}$.ownerDocument._nodes[$._nid]=void 0,$._nid=void 0}function Oj($){if(LP($),$.nodeType===R0.ELEMENT_NODE)for(var J=$.firstChild;J!==null;J=J.nextSibling)Oj(J)}function qj($){NP($);for(var J=$.firstChild;J!==null;J=J.nextSibling)qj(J)}function Fj($,J){if($.ownerDocument=J,$._lastModTime=void 0,Object.prototype.hasOwnProperty.call($,"_tagName"))$._tagName=void 0;for(var Z=$.firstChild;Z!==null;Z=Z.nextSibling)Fj(Z,J)}function s1($){this.nodes=Object.create(null),this.nodes[$._nid]=$,this.length=1,this.firstNode=void 0}s1.prototype.add=function($){if(!this.nodes[$._nid])this.nodes[$._nid]=$,this.length++,this.firstNode=void 0};s1.prototype.del=function($){if(this.nodes[$._nid])delete this.nodes[$._nid],this.length--,this.firstNode=void 0};s1.prototype.getFirst=function(){if(!this.firstNode){var $;for($ in this.nodes)if(this.firstNode===void 0||this.firstNode.compareDocumentPosition(this.nodes[$])&R0.DOCUMENT_POSITION_PRECEDING)this.firstNode=this.nodes[$]}return this.firstNode};s1.prototype.downgrade=function(){if(this.length===1){var $;for($ in this.nodes)return this.nodes[$]}return this}});var K6=p((Vv,Mj)=>{Mj.exports=Y6;var yP=P0(),Cj=NY(),TP=oZ();function Y6($,J,Z,Y){Cj.call(this),this.nodeType=yP.DOCUMENT_TYPE_NODE,this.ownerDocument=$||null,this.name=J,this.publicId=Z||"",this.systemId=Y||""}Y6.prototype=Object.create(Cj.prototype,{nodeName:{get:function(){return this.name}},nodeValue:{get:function(){return null},set:function(){}},clone:{value:function(){return new Y6(this.ownerDocument,this.name,this.publicId,this.systemId)}},isEqual:{value:function(J){return this.name===J.name&&this.publicId===J.publicId&&this.systemId===J.systemId}}});Object.defineProperties(Y6.prototype,TP)});var U6=p((Gv,pj)=>{pj.exports=b$;var kP=Z6(),EP=K6(),J3=P0(),X$=X0().NAMESPACE,bj=$6(),u$=bj.elements,t2=Function.prototype.apply.bind(Array.prototype.push),Q6=-1,cJ=1,L0=2,N$=3,y1=4,xP=5,bP=[],vP=/^HTML$|^-\/\/W3O\/\/DTD W3 HTML Strict 3\.0\/\/EN\/\/$|^-\/W3C\/DTD HTML 4\.0 Transitional\/EN$|^\+\/\/Silmaril\/\/dtd html Pro v0r11 19970101\/\/|^-\/\/AdvaSoft Ltd\/\/DTD HTML 3\.0 asWedit \+ extensions\/\/|^-\/\/AS\/\/DTD HTML 3\.0 asWedit \+ extensions\/\/|^-\/\/IETF\/\/DTD HTML 2\.0 Level 1\/\/|^-\/\/IETF\/\/DTD HTML 2\.0 Level 2\/\/|^-\/\/IETF\/\/DTD HTML 2\.0 Strict Level 1\/\/|^-\/\/IETF\/\/DTD HTML 2\.0 Strict Level 2\/\/|^-\/\/IETF\/\/DTD HTML 2\.0 Strict\/\/|^-\/\/IETF\/\/DTD HTML 2\.0\/\/|^-\/\/IETF\/\/DTD HTML 2\.1E\/\/|^-\/\/IETF\/\/DTD HTML 3\.0\/\/|^-\/\/IETF\/\/DTD HTML 3\.2 Final\/\/|^-\/\/IETF\/\/DTD HTML 3\.2\/\/|^-\/\/IETF\/\/DTD HTML 3\/\/|^-\/\/IETF\/\/DTD HTML Level 0\/\/|^-\/\/IETF\/\/DTD HTML Level 1\/\/|^-\/\/IETF\/\/DTD HTML Level 2\/\/|^-\/\/IETF\/\/DTD HTML Level 3\/\/|^-\/\/IETF\/\/DTD HTML Strict Level 0\/\/|^-\/\/IETF\/\/DTD HTML Strict Level 1\/\/|^-\/\/IETF\/\/DTD HTML Strict Level 2\/\/|^-\/\/IETF\/\/DTD HTML Strict Level 3\/\/|^-\/\/IETF\/\/DTD HTML Strict\/\/|^-\/\/IETF\/\/DTD HTML\/\/|^-\/\/Metrius\/\/DTD Metrius Presentational\/\/|^-\/\/Microsoft\/\/DTD Internet Explorer 2\.0 HTML Strict\/\/|^-\/\/Microsoft\/\/DTD Internet Explorer 2\.0 HTML\/\/|^-\/\/Microsoft\/\/DTD Internet Explorer 2\.0 Tables\/\/|^-\/\/Microsoft\/\/DTD Internet Explorer 3\.0 HTML Strict\/\/|^-\/\/Microsoft\/\/DTD Internet Explorer 3\.0 HTML\/\/|^-\/\/Microsoft\/\/DTD Internet Explorer 3\.0 Tables\/\/|^-\/\/Netscape Comm\. Corp\.\/\/DTD HTML\/\/|^-\/\/Netscape Comm\. Corp\.\/\/DTD Strict HTML\/\/|^-\/\/O'Reilly and Associates\/\/DTD HTML 2\.0\/\/|^-\/\/O'Reilly and Associates\/\/DTD HTML Extended 1\.0\/\/|^-\/\/O'Reilly and Associates\/\/DTD HTML Extended Relaxed 1\.0\/\/|^-\/\/SoftQuad Software\/\/DTD HoTMetaL PRO 6\.0::19990601::extensions to HTML 4\.0\/\/|^-\/\/SoftQuad\/\/DTD HoTMetaL PRO 4\.0::19971010::extensions to HTML 4\.0\/\/|^-\/\/Spyglass\/\/DTD HTML 2\.0 Extended\/\/|^-\/\/SQ\/\/DTD HTML 2\.0 HoTMetaL \+ extensions\/\/|^-\/\/Sun Microsystems Corp\.\/\/DTD HotJava HTML\/\/|^-\/\/Sun Microsystems Corp\.\/\/DTD HotJava Strict HTML\/\/|^-\/\/W3C\/\/DTD HTML 3 1995-03-24\/\/|^-\/\/W3C\/\/DTD HTML 3\.2 Draft\/\/|^-\/\/W3C\/\/DTD HTML 3\.2 Final\/\/|^-\/\/W3C\/\/DTD HTML 3\.2\/\/|^-\/\/W3C\/\/DTD HTML 3\.2S Draft\/\/|^-\/\/W3C\/\/DTD HTML 4\.0 Frameset\/\/|^-\/\/W3C\/\/DTD HTML 4\.0 Transitional\/\/|^-\/\/W3C\/\/DTD HTML Experimental 19960712\/\/|^-\/\/W3C\/\/DTD HTML Experimental 970421\/\/|^-\/\/W3C\/\/DTD W3 HTML\/\/|^-\/\/W3O\/\/DTD W3 HTML 3\.0\/\/|^-\/\/WebTechs\/\/DTD Mozilla HTML 2\.0\/\/|^-\/\/WebTechs\/\/DTD Mozilla HTML\/\//i,hP="http://www.ibm.com/data/dtd/v11/ibmxhtml1-transitional.dtd",Dj=/^-\/\/W3C\/\/DTD HTML 4\.01 Frameset\/\/|^-\/\/W3C\/\/DTD HTML 4\.01 Transitional\/\//i,gP=/^-\/\/W3C\/\/DTD XHTML 1\.0 Frameset\/\/|^-\/\/W3C\/\/DTD XHTML 1\.0 Transitional\/\//i,$J=Object.create(null);$J[X$.HTML]={__proto__:null,address:!0,applet:!0,area:!0,article:!0,aside:!0,base:!0,basefont:!0,bgsound:!0,blockquote:!0,body:!0,br:!0,button:!0,caption:!0,center:!0,col:!0,colgroup:!0,dd:!0,details:!0,dir:!0,div:!0,dl:!0,dt:!0,embed:!0,fieldset:!0,figcaption:!0,figure:!0,footer:!0,form:!0,frame:!0,frameset:!0,h1:!0,h2:!0,h3:!0,h4:!0,h5:!0,h6:!0,head:!0,header:!0,hgroup:!0,hr:!0,html:!0,iframe:!0,img:!0,input:!0,li:!0,link:!0,listing:!0,main:!0,marquee:!0,menu:!0,meta:!0,nav:!0,noembed:!0,noframes:!0,noscript:!0,object:!0,ol:!0,p:!0,param:!0,plaintext:!0,pre:!0,script:!0,section:!0,select:!0,source:!0,style:!0,summary:!0,table:!0,tbody:!0,td:!0,template:!0,textarea:!0,tfoot:!0,th:!0,thead:!0,title:!0,tr:!0,track:!0,ul:!0,wbr:!0,xmp:!0};$J[X$.SVG]={__proto__:null,foreignObject:!0,desc:!0,title:!0};$J[X$.MATHML]={__proto__:null,mi:!0,mo:!0,mn:!0,ms:!0,mtext:!0,"annotation-xml":!0};var K3=Object.create(null);K3[X$.HTML]={__proto__:null,address:!0,div:!0,p:!0};var vj=Object.create(null);vj[X$.HTML]={__proto__:null,dd:!0,dt:!0};var lJ=Object.create(null);lJ[X$.HTML]={__proto__:null,table:!0,thead:!0,tbody:!0,tfoot:!0,tr:!0};var hj=Object.create(null);hj[X$.HTML]={__proto__:null,dd:!0,dt:!0,li:!0,menuitem:!0,optgroup:!0,option:!0,p:!0,rb:!0,rp:!0,rt:!0,rtc:!0};var gj=Object.create(null);gj[X$.HTML]={__proto__:null,caption:!0,colgroup:!0,dd:!0,dt:!0,li:!0,optgroup:!0,option:!0,p:!0,rb:!0,rp:!0,rt:!0,rtc:!0,tbody:!0,td:!0,tfoot:!0,th:!0,thead:!0,tr:!0};var X6=Object.create(null);X6[X$.HTML]={__proto__:null,table:!0,template:!0,html:!0};var W6=Object.create(null);W6[X$.HTML]={__proto__:null,tbody:!0,tfoot:!0,thead:!0,template:!0,html:!0};var Q3=Object.create(null);Q3[X$.HTML]={__proto__:null,tr:!0,template:!0,html:!0};var fj=Object.create(null);fj[X$.HTML]={__proto__:null,button:!0,fieldset:!0,input:!0,keygen:!0,object:!0,output:!0,select:!0,textarea:!0,img:!0};var T1=Object.create(null);T1[X$.HTML]={__proto__:null,applet:!0,caption:!0,html:!0,table:!0,td:!0,th:!0,marquee:!0,object:!0,template:!0};T1[X$.MATHML]={__proto__:null,mi:!0,mo:!0,mn:!0,ms:!0,mtext:!0,"annotation-xml":!0};T1[X$.SVG]={__proto__:null,foreignObject:!0,desc:!0,title:!0};var j6=Object.create(T1);j6[X$.HTML]=Object.create(T1[X$.HTML]);j6[X$.HTML].ol=!0;j6[X$.HTML].ul=!0;var V3=Object.create(T1);V3[X$.HTML]=Object.create(T1[X$.HTML]);V3[X$.HTML].button=!0;var mj=Object.create(null);mj[X$.HTML]={__proto__:null,html:!0,table:!0,template:!0};var fP=Object.create(null);fP[X$.HTML]={__proto__:null,optgroup:!0,option:!0};var uj=Object.create(null);uj[X$.MATHML]={__proto__:null,mi:!0,mo:!0,mn:!0,ms:!0,mtext:!0};var dj=Object.create(null);dj[X$.SVG]={__proto__:null,foreignObject:!0,desc:!0,title:!0};var Pj={__proto__:null,"xlink:actuate":X$.XLINK,"xlink:arcrole":X$.XLINK,"xlink:href":X$.XLINK,"xlink:role":X$.XLINK,"xlink:show":X$.XLINK,"xlink:title":X$.XLINK,"xlink:type":X$.XLINK,"xml:base":X$.XML,"xml:lang":X$.XML,"xml:space":X$.XML,xmlns:X$.XMLNS,"xmlns:xlink":X$.XMLNS},Ij={__proto__:null,attributename:"attributeName",attributetype:"attributeType",basefrequency:"baseFrequency",baseprofile:"baseProfile",calcmode:"calcMode",clippathunits:"clipPathUnits",diffuseconstant:"diffuseConstant",edgemode:"edgeMode",filterunits:"filterUnits",glyphref:"glyphRef",gradienttransform:"gradientTransform",gradientunits:"gradientUnits",kernelmatrix:"kernelMatrix",kernelunitlength:"kernelUnitLength",keypoints:"keyPoints",keysplines:"keySplines",keytimes:"keyTimes",lengthadjust:"lengthAdjust",limitingconeangle:"limitingConeAngle",markerheight:"markerHeight",markerunits:"markerUnits",markerwidth:"markerWidth",maskcontentunits:"maskContentUnits",maskunits:"maskUnits",numoctaves:"numOctaves",pathlength:"pathLength",patterncontentunits:"patternContentUnits",patterntransform:"patternTransform",patternunits:"patternUnits",pointsatx:"pointsAtX",pointsaty:"pointsAtY",pointsatz:"pointsAtZ",preservealpha:"preserveAlpha",preserveaspectratio:"preserveAspectRatio",primitiveunits:"primitiveUnits",refx:"refX",refy:"refY",repeatcount:"repeatCount",repeatdur:"repeatDur",requiredextensions:"requiredExtensions",requiredfeatures:"requiredFeatures",specularconstant:"specularConstant",specularexponent:"specularExponent",spreadmethod:"spreadMethod",startoffset:"startOffset",stddeviation:"stdDeviation",stitchtiles:"stitchTiles",surfacescale:"surfaceScale",systemlanguage:"systemLanguage",tablevalues:"tableValues",targetx:"targetX",targety:"targetY",textlength:"textLength",viewbox:"viewBox",viewtarget:"viewTarget",xchannelselector:"xChannelSelector",ychannelselector:"yChannelSelector",zoomandpan:"zoomAndPan"},Aj={__proto__:null,altglyph:"altGlyph",altglyphdef:"altGlyphDef",altglyphitem:"altGlyphItem",animatecolor:"animateColor",animatemotion:"animateMotion",animatetransform:"animateTransform",clippath:"clipPath",feblend:"feBlend",fecolormatrix:"feColorMatrix",fecomponenttransfer:"feComponentTransfer",fecomposite:"feComposite",feconvolvematrix:"feConvolveMatrix",fediffuselighting:"feDiffuseLighting",fedisplacementmap:"feDisplacementMap",fedistantlight:"feDistantLight",feflood:"feFlood",fefunca:"feFuncA",fefuncb:"feFuncB",fefuncg:"feFuncG",fefuncr:"feFuncR",fegaussianblur:"feGaussianBlur",feimage:"feImage",femerge:"feMerge",femergenode:"feMergeNode",femorphology:"feMorphology",feoffset:"feOffset",fepointlight:"fePointLight",fespecularlighting:"feSpecularLighting",fespotlight:"feSpotLight",fetile:"feTile",feturbulence:"feTurbulence",foreignobject:"foreignObject",glyphref:"glyphRef",lineargradient:"linearGradient",radialgradient:"radialGradient",textpath:"textPath"},Sj={__proto__:null,0:65533,128:8364,130:8218,131:402,132:8222,133:8230,134:8224,135:8225,136:710,137:8240,138:352,139:8249,140:338,142:381,145:8216,146:8217,147:8220,148:8221,149:8226,150:8211,151:8212,152:732,153:8482,154:353,155:8250,156:339,158:382,159:376},mP={__proto__:null,AElig:198,"AElig;":198,AMP:38,"AMP;":38,Aacute:193,"Aacute;":193,"Abreve;":258,Acirc:194,"Acirc;":194,"Acy;":1040,"Afr;":[55349,56580],Agrave:192,"Agrave;":192,"Alpha;":913,"Amacr;":256,"And;":10835,"Aogon;":260,"Aopf;":[55349,56632],"ApplyFunction;":8289,Aring:197,"Aring;":197,"Ascr;":[55349,56476],"Assign;":8788,Atilde:195,"Atilde;":195,Auml:196,"Auml;":196,"Backslash;":8726,"Barv;":10983,"Barwed;":8966,"Bcy;":1041,"Because;":8757,"Bernoullis;":8492,"Beta;":914,"Bfr;":[55349,56581],"Bopf;":[55349,56633],"Breve;":728,"Bscr;":8492,"Bumpeq;":8782,"CHcy;":1063,COPY:169,"COPY;":169,"Cacute;":262,"Cap;":8914,"CapitalDifferentialD;":8517,"Cayleys;":8493,"Ccaron;":268,Ccedil:199,"Ccedil;":199,"Ccirc;":264,"Cconint;":8752,"Cdot;":266,"Cedilla;":184,"CenterDot;":183,"Cfr;":8493,"Chi;":935,"CircleDot;":8857,"CircleMinus;":8854,"CirclePlus;":8853,"CircleTimes;":8855,"ClockwiseContourIntegral;":8754,"CloseCurlyDoubleQuote;":8221,"CloseCurlyQuote;":8217,"Colon;":8759,"Colone;":10868,"Congruent;":8801,"Conint;":8751,"ContourIntegral;":8750,"Copf;":8450,"Coproduct;":8720,"CounterClockwiseContourIntegral;":8755,"Cross;":10799,"Cscr;":[55349,56478],"Cup;":8915,"CupCap;":8781,"DD;":8517,"DDotrahd;":10513,"DJcy;":1026,"DScy;":1029,"DZcy;":1039,"Dagger;":8225,"Darr;":8609,"Dashv;":10980,"Dcaron;":270,"Dcy;":1044,"Del;":8711,"Delta;":916,"Dfr;":[55349,56583],"DiacriticalAcute;":180,"DiacriticalDot;":729,"DiacriticalDoubleAcute;":733,"DiacriticalGrave;":96,"DiacriticalTilde;":732,"Diamond;":8900,"DifferentialD;":8518,"Dopf;":[55349,56635],"Dot;":168,"DotDot;":8412,"DotEqual;":8784,"DoubleContourIntegral;":8751,"DoubleDot;":168,"DoubleDownArrow;":8659,"DoubleLeftArrow;":8656,"DoubleLeftRightArrow;":8660,"DoubleLeftTee;":10980,"DoubleLongLeftArrow;":10232,"DoubleLongLeftRightArrow;":10234,"DoubleLongRightArrow;":10233,"DoubleRightArrow;":8658,"DoubleRightTee;":8872,"DoubleUpArrow;":8657,"DoubleUpDownArrow;":8661,"DoubleVerticalBar;":8741,"DownArrow;":8595,"DownArrowBar;":10515,"DownArrowUpArrow;":8693,"DownBreve;":785,"DownLeftRightVector;":10576,"DownLeftTeeVector;":10590,"DownLeftVector;":8637,"DownLeftVectorBar;":10582,"DownRightTeeVector;":10591,"DownRightVector;":8641,"DownRightVectorBar;":10583,"DownTee;":8868,"DownTeeArrow;":8615,"Downarrow;":8659,"Dscr;":[55349,56479],"Dstrok;":272,"ENG;":330,ETH:208,"ETH;":208,Eacute:201,"Eacute;":201,"Ecaron;":282,Ecirc:202,"Ecirc;":202,"Ecy;":1069,"Edot;":278,"Efr;":[55349,56584],Egrave:200,"Egrave;":200,"Element;":8712,"Emacr;":274,"EmptySmallSquare;":9723,"EmptyVerySmallSquare;":9643,"Eogon;":280,"Eopf;":[55349,56636],"Epsilon;":917,"Equal;":10869,"EqualTilde;":8770,"Equilibrium;":8652,"Escr;":8496,"Esim;":10867,"Eta;":919,Euml:203,"Euml;":203,"Exists;":8707,"ExponentialE;":8519,"Fcy;":1060,"Ffr;":[55349,56585],"FilledSmallSquare;":9724,"FilledVerySmallSquare;":9642,"Fopf;":[55349,56637],"ForAll;":8704,"Fouriertrf;":8497,"Fscr;":8497,"GJcy;":1027,GT:62,"GT;":62,"Gamma;":915,"Gammad;":988,"Gbreve;":286,"Gcedil;":290,"Gcirc;":284,"Gcy;":1043,"Gdot;":288,"Gfr;":[55349,56586],"Gg;":8921,"Gopf;":[55349,56638],"GreaterEqual;":8805,"GreaterEqualLess;":8923,"GreaterFullEqual;":8807,"GreaterGreater;":10914,"GreaterLess;":8823,"GreaterSlantEqual;":10878,"GreaterTilde;":8819,"Gscr;":[55349,56482],"Gt;":8811,"HARDcy;":1066,"Hacek;":711,"Hat;":94,"Hcirc;":292,"Hfr;":8460,"HilbertSpace;":8459,"Hopf;":8461,"HorizontalLine;":9472,"Hscr;":8459,"Hstrok;":294,"HumpDownHump;":8782,"HumpEqual;":8783,"IEcy;":1045,"IJlig;":306,"IOcy;":1025,Iacute:205,"Iacute;":205,Icirc:206,"Icirc;":206,"Icy;":1048,"Idot;":304,"Ifr;":8465,Igrave:204,"Igrave;":204,"Im;":8465,"Imacr;":298,"ImaginaryI;":8520,"Implies;":8658,"Int;":8748,"Integral;":8747,"Intersection;":8898,"InvisibleComma;":8291,"InvisibleTimes;":8290,"Iogon;":302,"Iopf;":[55349,56640],"Iota;":921,"Iscr;":8464,"Itilde;":296,"Iukcy;":1030,Iuml:207,"Iuml;":207,"Jcirc;":308,"Jcy;":1049,"Jfr;":[55349,56589],"Jopf;":[55349,56641],"Jscr;":[55349,56485],"Jsercy;":1032,"Jukcy;":1028,"KHcy;":1061,"KJcy;":1036,"Kappa;":922,"Kcedil;":310,"Kcy;":1050,"Kfr;":[55349,56590],"Kopf;":[55349,56642],"Kscr;":[55349,56486],"LJcy;":1033,LT:60,"LT;":60,"Lacute;":313,"Lambda;":923,"Lang;":10218,"Laplacetrf;":8466,"Larr;":8606,"Lcaron;":317,"Lcedil;":315,"Lcy;":1051,"LeftAngleBracket;":10216,"LeftArrow;":8592,"LeftArrowBar;":8676,"LeftArrowRightArrow;":8646,"LeftCeiling;":8968,"LeftDoubleBracket;":10214,"LeftDownTeeVector;":10593,"LeftDownVector;":8643,"LeftDownVectorBar;":10585,"LeftFloor;":8970,"LeftRightArrow;":8596,"LeftRightVector;":10574,"LeftTee;":8867,"LeftTeeArrow;":8612,"LeftTeeVector;":10586,"LeftTriangle;":8882,"LeftTriangleBar;":10703,"LeftTriangleEqual;":8884,"LeftUpDownVector;":10577,"LeftUpTeeVector;":10592,"LeftUpVector;":8639,"LeftUpVectorBar;":10584,"LeftVector;":8636,"LeftVectorBar;":10578,"Leftarrow;":8656,"Leftrightarrow;":8660,"LessEqualGreater;":8922,"LessFullEqual;":8806,"LessGreater;":8822,"LessLess;":10913,"LessSlantEqual;":10877,"LessTilde;":8818,"Lfr;":[55349,56591],"Ll;":8920,"Lleftarrow;":8666,"Lmidot;":319,"LongLeftArrow;":10229,"LongLeftRightArrow;":10231,"LongRightArrow;":10230,"Longleftarrow;":10232,"Longleftrightarrow;":10234,"Longrightarrow;":10233,"Lopf;":[55349,56643],"LowerLeftArrow;":8601,"LowerRightArrow;":8600,"Lscr;":8466,"Lsh;":8624,"Lstrok;":321,"Lt;":8810,"Map;":10501,"Mcy;":1052,"MediumSpace;":8287,"Mellintrf;":8499,"Mfr;":[55349,56592],"MinusPlus;":8723,"Mopf;":[55349,56644],"Mscr;":8499,"Mu;":924,"NJcy;":1034,"Nacute;":323,"Ncaron;":327,"Ncedil;":325,"Ncy;":1053,"NegativeMediumSpace;":8203,"NegativeThickSpace;":8203,"NegativeThinSpace;":8203,"NegativeVeryThinSpace;":8203,"NestedGreaterGreater;":8811,"NestedLessLess;":8810,"NewLine;":10,"Nfr;":[55349,56593],"NoBreak;":8288,"NonBreakingSpace;":160,"Nopf;":8469,"Not;":10988,"NotCongruent;":8802,"NotCupCap;":8813,"NotDoubleVerticalBar;":8742,"NotElement;":8713,"NotEqual;":8800,"NotEqualTilde;":[8770,824],"NotExists;":8708,"NotGreater;":8815,"NotGreaterEqual;":8817,"NotGreaterFullEqual;":[8807,824],"NotGreaterGreater;":[8811,824],"NotGreaterLess;":8825,"NotGreaterSlantEqual;":[10878,824],"NotGreaterTilde;":8821,"NotHumpDownHump;":[8782,824],"NotHumpEqual;":[8783,824],"NotLeftTriangle;":8938,"NotLeftTriangleBar;":[10703,824],"NotLeftTriangleEqual;":8940,"NotLess;":8814,"NotLessEqual;":8816,"NotLessGreater;":8824,"NotLessLess;":[8810,824],"NotLessSlantEqual;":[10877,824],"NotLessTilde;":8820,"NotNestedGreaterGreater;":[10914,824],"NotNestedLessLess;":[10913,824],"NotPrecedes;":8832,"NotPrecedesEqual;":[10927,824],"NotPrecedesSlantEqual;":8928,"NotReverseElement;":8716,"NotRightTriangle;":8939,"NotRightTriangleBar;":[10704,824],"NotRightTriangleEqual;":8941,"NotSquareSubset;":[8847,824],"NotSquareSubsetEqual;":8930,"NotSquareSuperset;":[8848,824],"NotSquareSupersetEqual;":8931,"NotSubset;":[8834,8402],"NotSubsetEqual;":8840,"NotSucceeds;":8833,"NotSucceedsEqual;":[10928,824],"NotSucceedsSlantEqual;":8929,"NotSucceedsTilde;":[8831,824],"NotSuperset;":[8835,8402],"NotSupersetEqual;":8841,"NotTilde;":8769,"NotTildeEqual;":8772,"NotTildeFullEqual;":8775,"NotTildeTilde;":8777,"NotVerticalBar;":8740,"Nscr;":[55349,56489],Ntilde:209,"Ntilde;":209,"Nu;":925,"OElig;":338,Oacute:211,"Oacute;":211,Ocirc:212,"Ocirc;":212,"Ocy;":1054,"Odblac;":336,"Ofr;":[55349,56594],Ograve:210,"Ograve;":210,"Omacr;":332,"Omega;":937,"Omicron;":927,"Oopf;":[55349,56646],"OpenCurlyDoubleQuote;":8220,"OpenCurlyQuote;":8216,"Or;":10836,"Oscr;":[55349,56490],Oslash:216,"Oslash;":216,Otilde:213,"Otilde;":213,"Otimes;":10807,Ouml:214,"Ouml;":214,"OverBar;":8254,"OverBrace;":9182,"OverBracket;":9140,"OverParenthesis;":9180,"PartialD;":8706,"Pcy;":1055,"Pfr;":[55349,56595],"Phi;":934,"Pi;":928,"PlusMinus;":177,"Poincareplane;":8460,"Popf;":8473,"Pr;":10939,"Precedes;":8826,"PrecedesEqual;":10927,"PrecedesSlantEqual;":8828,"PrecedesTilde;":8830,"Prime;":8243,"Product;":8719,"Proportion;":8759,"Proportional;":8733,"Pscr;":[55349,56491],"Psi;":936,QUOT:34,"QUOT;":34,"Qfr;":[55349,56596],"Qopf;":8474,"Qscr;":[55349,56492],"RBarr;":10512,REG:174,"REG;":174,"Racute;":340,"Rang;":10219,"Rarr;":8608,"Rarrtl;":10518,"Rcaron;":344,"Rcedil;":342,"Rcy;":1056,"Re;":8476,"ReverseElement;":8715,"ReverseEquilibrium;":8651,"ReverseUpEquilibrium;":10607,"Rfr;":8476,"Rho;":929,"RightAngleBracket;":10217,"RightArrow;":8594,"RightArrowBar;":8677,"RightArrowLeftArrow;":8644,"RightCeiling;":8969,"RightDoubleBracket;":10215,"RightDownTeeVector;":10589,"RightDownVector;":8642,"RightDownVectorBar;":10581,"RightFloor;":8971,"RightTee;":8866,"RightTeeArrow;":8614,"RightTeeVector;":10587,"RightTriangle;":8883,"RightTriangleBar;":10704,"RightTriangleEqual;":8885,"RightUpDownVector;":10575,"RightUpTeeVector;":10588,"RightUpVector;":8638,"RightUpVectorBar;":10580,"RightVector;":8640,"RightVectorBar;":10579,"Rightarrow;":8658,"Ropf;":8477,"RoundImplies;":10608,"Rrightarrow;":8667,"Rscr;":8475,"Rsh;":8625,"RuleDelayed;":10740,"SHCHcy;":1065,"SHcy;":1064,"SOFTcy;":1068,"Sacute;":346,"Sc;":10940,"Scaron;":352,"Scedil;":350,"Scirc;":348,"Scy;":1057,"Sfr;":[55349,56598],"ShortDownArrow;":8595,"ShortLeftArrow;":8592,"ShortRightArrow;":8594,"ShortUpArrow;":8593,"Sigma;":931,"SmallCircle;":8728,"Sopf;":[55349,56650],"Sqrt;":8730,"Square;":9633,"SquareIntersection;":8851,"SquareSubset;":8847,"SquareSubsetEqual;":8849,"SquareSuperset;":8848,"SquareSupersetEqual;":8850,"SquareUnion;":8852,"Sscr;":[55349,56494],"Star;":8902,"Sub;":8912,"Subset;":8912,"SubsetEqual;":8838,"Succeeds;":8827,"SucceedsEqual;":10928,"SucceedsSlantEqual;":8829,"SucceedsTilde;":8831,"SuchThat;":8715,"Sum;":8721,"Sup;":8913,"Superset;":8835,"SupersetEqual;":8839,"Supset;":8913,THORN:222,"THORN;":222,"TRADE;":8482,"TSHcy;":1035,"TScy;":1062,"Tab;":9,"Tau;":932,"Tcaron;":356,"Tcedil;":354,"Tcy;":1058,"Tfr;":[55349,56599],"Therefore;":8756,"Theta;":920,"ThickSpace;":[8287,8202],"ThinSpace;":8201,"Tilde;":8764,"TildeEqual;":8771,"TildeFullEqual;":8773,"TildeTilde;":8776,"Topf;":[55349,56651],"TripleDot;":8411,"Tscr;":[55349,56495],"Tstrok;":358,Uacute:218,"Uacute;":218,"Uarr;":8607,"Uarrocir;":10569,"Ubrcy;":1038,"Ubreve;":364,Ucirc:219,"Ucirc;":219,"Ucy;":1059,"Udblac;":368,"Ufr;":[55349,56600],Ugrave:217,"Ugrave;":217,"Umacr;":362,"UnderBar;":95,"UnderBrace;":9183,"UnderBracket;":9141,"UnderParenthesis;":9181,"Union;":8899,"UnionPlus;":8846,"Uogon;":370,"Uopf;":[55349,56652],"UpArrow;":8593,"UpArrowBar;":10514,"UpArrowDownArrow;":8645,"UpDownArrow;":8597,"UpEquilibrium;":10606,"UpTee;":8869,"UpTeeArrow;":8613,"Uparrow;":8657,"Updownarrow;":8661,"UpperLeftArrow;":8598,"UpperRightArrow;":8599,"Upsi;":978,"Upsilon;":933,"Uring;":366,"Uscr;":[55349,56496],"Utilde;":360,Uuml:220,"Uuml;":220,"VDash;":8875,"Vbar;":10987,"Vcy;":1042,"Vdash;":8873,"Vdashl;":10982,"Vee;":8897,"Verbar;":8214,"Vert;":8214,"VerticalBar;":8739,"VerticalLine;":124,"VerticalSeparator;":10072,"VerticalTilde;":8768,"VeryThinSpace;":8202,"Vfr;":[55349,56601],"Vopf;":[55349,56653],"Vscr;":[55349,56497],"Vvdash;":8874,"Wcirc;":372,"Wedge;":8896,"Wfr;":[55349,56602],"Wopf;":[55349,56654],"Wscr;":[55349,56498],"Xfr;":[55349,56603],"Xi;":926,"Xopf;":[55349,56655],"Xscr;":[55349,56499],"YAcy;":1071,"YIcy;":1031,"YUcy;":1070,Yacute:221,"Yacute;":221,"Ycirc;":374,"Ycy;":1067,"Yfr;":[55349,56604],"Yopf;":[55349,56656],"Yscr;":[55349,56500],"Yuml;":376,"ZHcy;":1046,"Zacute;":377,"Zcaron;":381,"Zcy;":1047,"Zdot;":379,"ZeroWidthSpace;":8203,"Zeta;":918,"Zfr;":8488,"Zopf;":8484,"Zscr;":[55349,56501],aacute:225,"aacute;":225,"abreve;":259,"ac;":8766,"acE;":[8766,819],"acd;":8767,acirc:226,"acirc;":226,acute:180,"acute;":180,"acy;":1072,aelig:230,"aelig;":230,"af;":8289,"afr;":[55349,56606],agrave:224,"agrave;":224,"alefsym;":8501,"aleph;":8501,"alpha;":945,"amacr;":257,"amalg;":10815,amp:38,"amp;":38,"and;":8743,"andand;":10837,"andd;":10844,"andslope;":10840,"andv;":10842,"ang;":8736,"ange;":10660,"angle;":8736,"angmsd;":8737,"angmsdaa;":10664,"angmsdab;":10665,"angmsdac;":10666,"angmsdad;":10667,"angmsdae;":10668,"angmsdaf;":10669,"angmsdag;":10670,"angmsdah;":10671,"angrt;":8735,"angrtvb;":8894,"angrtvbd;":10653,"angsph;":8738,"angst;":197,"angzarr;":9084,"aogon;":261,"aopf;":[55349,56658],"ap;":8776,"apE;":10864,"apacir;":10863,"ape;":8778,"apid;":8779,"apos;":39,"approx;":8776,"approxeq;":8778,aring:229,"aring;":229,"ascr;":[55349,56502],"ast;":42,"asymp;":8776,"asympeq;":8781,atilde:227,"atilde;":227,auml:228,"auml;":228,"awconint;":8755,"awint;":10769,"bNot;":10989,"backcong;":8780,"backepsilon;":1014,"backprime;":8245,"backsim;":8765,"backsimeq;":8909,"barvee;":8893,"barwed;":8965,"barwedge;":8965,"bbrk;":9141,"bbrktbrk;":9142,"bcong;":8780,"bcy;":1073,"bdquo;":8222,"becaus;":8757,"because;":8757,"bemptyv;":10672,"bepsi;":1014,"bernou;":8492,"beta;":946,"beth;":8502,"between;":8812,"bfr;":[55349,56607],"bigcap;":8898,"bigcirc;":9711,"bigcup;":8899,"bigodot;":10752,"bigoplus;":10753,"bigotimes;":10754,"bigsqcup;":10758,"bigstar;":9733,"bigtriangledown;":9661,"bigtriangleup;":9651,"biguplus;":10756,"bigvee;":8897,"bigwedge;":8896,"bkarow;":10509,"blacklozenge;":10731,"blacksquare;":9642,"blacktriangle;":9652,"blacktriangledown;":9662,"blacktriangleleft;":9666,"blacktriangleright;":9656,"blank;":9251,"blk12;":9618,"blk14;":9617,"blk34;":9619,"block;":9608,"bne;":[61,8421],"bnequiv;":[8801,8421],"bnot;":8976,"bopf;":[55349,56659],"bot;":8869,"bottom;":8869,"bowtie;":8904,"boxDL;":9559,"boxDR;":9556,"boxDl;":9558,"boxDr;":9555,"boxH;":9552,"boxHD;":9574,"boxHU;":9577,"boxHd;":9572,"boxHu;":9575,"boxUL;":9565,"boxUR;":9562,"boxUl;":9564,"boxUr;":9561,"boxV;":9553,"boxVH;":9580,"boxVL;":9571,"boxVR;":9568,"boxVh;":9579,"boxVl;":9570,"boxVr;":9567,"boxbox;":10697,"boxdL;":9557,"boxdR;":9554,"boxdl;":9488,"boxdr;":9484,"boxh;":9472,"boxhD;":9573,"boxhU;":9576,"boxhd;":9516,"boxhu;":9524,"boxminus;":8863,"boxplus;":8862,"boxtimes;":8864,"boxuL;":9563,"boxuR;":9560,"boxul;":9496,"boxur;":9492,"boxv;":9474,"boxvH;":9578,"boxvL;":9569,"boxvR;":9566,"boxvh;":9532,"boxvl;":9508,"boxvr;":9500,"bprime;":8245,"breve;":728,brvbar:166,"brvbar;":166,"bscr;":[55349,56503],"bsemi;":8271,"bsim;":8765,"bsime;":8909,"bsol;":92,"bsolb;":10693,"bsolhsub;":10184,"bull;":8226,"bullet;":8226,"bump;":8782,"bumpE;":10926,"bumpe;":8783,"bumpeq;":8783,"cacute;":263,"cap;":8745,"capand;":10820,"capbrcup;":10825,"capcap;":10827,"capcup;":10823,"capdot;":10816,"caps;":[8745,65024],"caret;":8257,"caron;":711,"ccaps;":10829,"ccaron;":269,ccedil:231,"ccedil;":231,"ccirc;":265,"ccups;":10828,"ccupssm;":10832,"cdot;":267,cedil:184,"cedil;":184,"cemptyv;":10674,cent:162,"cent;":162,"centerdot;":183,"cfr;":[55349,56608],"chcy;":1095,"check;":10003,"checkmark;":10003,"chi;":967,"cir;":9675,"cirE;":10691,"circ;":710,"circeq;":8791,"circlearrowleft;":8634,"circlearrowright;":8635,"circledR;":174,"circledS;":9416,"circledast;":8859,"circledcirc;":8858,"circleddash;":8861,"cire;":8791,"cirfnint;":10768,"cirmid;":10991,"cirscir;":10690,"clubs;":9827,"clubsuit;":9827,"colon;":58,"colone;":8788,"coloneq;":8788,"comma;":44,"commat;":64,"comp;":8705,"compfn;":8728,"complement;":8705,"complexes;":8450,"cong;":8773,"congdot;":10861,"conint;":8750,"copf;":[55349,56660],"coprod;":8720,copy:169,"copy;":169,"copysr;":8471,"crarr;":8629,"cross;":10007,"cscr;":[55349,56504],"csub;":10959,"csube;":10961,"csup;":10960,"csupe;":10962,"ctdot;":8943,"cudarrl;":10552,"cudarrr;":10549,"cuepr;":8926,"cuesc;":8927,"cularr;":8630,"cularrp;":10557,"cup;":8746,"cupbrcap;":10824,"cupcap;":10822,"cupcup;":10826,"cupdot;":8845,"cupor;":10821,"cups;":[8746,65024],"curarr;":8631,"curarrm;":10556,"curlyeqprec;":8926,"curlyeqsucc;":8927,"curlyvee;":8910,"curlywedge;":8911,curren:164,"curren;":164,"curvearrowleft;":8630,"curvearrowright;":8631,"cuvee;":8910,"cuwed;":8911,"cwconint;":8754,"cwint;":8753,"cylcty;":9005,"dArr;":8659,"dHar;":10597,"dagger;":8224,"daleth;":8504,"darr;":8595,"dash;":8208,"dashv;":8867,"dbkarow;":10511,"dblac;":733,"dcaron;":271,"dcy;":1076,"dd;":8518,"ddagger;":8225,"ddarr;":8650,"ddotseq;":10871,deg:176,"deg;":176,"delta;":948,"demptyv;":10673,"dfisht;":10623,"dfr;":[55349,56609],"dharl;":8643,"dharr;":8642,"diam;":8900,"diamond;":8900,"diamondsuit;":9830,"diams;":9830,"die;":168,"digamma;":989,"disin;":8946,"div;":247,divide:247,"divide;":247,"divideontimes;":8903,"divonx;":8903,"djcy;":1106,"dlcorn;":8990,"dlcrop;":8973,"dollar;":36,"dopf;":[55349,56661],"dot;":729,"doteq;":8784,"doteqdot;":8785,"dotminus;":8760,"dotplus;":8724,"dotsquare;":8865,"doublebarwedge;":8966,"downarrow;":8595,"downdownarrows;":8650,"downharpoonleft;":8643,"downharpoonright;":8642,"drbkarow;":10512,"drcorn;":8991,"drcrop;":8972,"dscr;":[55349,56505],"dscy;":1109,"dsol;":10742,"dstrok;":273,"dtdot;":8945,"dtri;":9663,"dtrif;":9662,"duarr;":8693,"duhar;":10607,"dwangle;":10662,"dzcy;":1119,"dzigrarr;":10239,"eDDot;":10871,"eDot;":8785,eacute:233,"eacute;":233,"easter;":10862,"ecaron;":283,"ecir;":8790,ecirc:234,"ecirc;":234,"ecolon;":8789,"ecy;":1101,"edot;":279,"ee;":8519,"efDot;":8786,"efr;":[55349,56610],"eg;":10906,egrave:232,"egrave;":232,"egs;":10902,"egsdot;":10904,"el;":10905,"elinters;":9191,"ell;":8467,"els;":10901,"elsdot;":10903,"emacr;":275,"empty;":8709,"emptyset;":8709,"emptyv;":8709,"emsp13;":8196,"emsp14;":8197,"emsp;":8195,"eng;":331,"ensp;":8194,"eogon;":281,"eopf;":[55349,56662],"epar;":8917,"eparsl;":10723,"eplus;":10865,"epsi;":949,"epsilon;":949,"epsiv;":1013,"eqcirc;":8790,"eqcolon;":8789,"eqsim;":8770,"eqslantgtr;":10902,"eqslantless;":10901,"equals;":61,"equest;":8799,"equiv;":8801,"equivDD;":10872,"eqvparsl;":10725,"erDot;":8787,"erarr;":10609,"escr;":8495,"esdot;":8784,"esim;":8770,"eta;":951,eth:240,"eth;":240,euml:235,"euml;":235,"euro;":8364,"excl;":33,"exist;":8707,"expectation;":8496,"exponentiale;":8519,"fallingdotseq;":8786,"fcy;":1092,"female;":9792,"ffilig;":64259,"fflig;":64256,"ffllig;":64260,"ffr;":[55349,56611],"filig;":64257,"fjlig;":[102,106],"flat;":9837,"fllig;":64258,"fltns;":9649,"fnof;":402,"fopf;":[55349,56663],"forall;":8704,"fork;":8916,"forkv;":10969,"fpartint;":10765,frac12:189,"frac12;":189,"frac13;":8531,frac14:188,"frac14;":188,"frac15;":8533,"frac16;":8537,"frac18;":8539,"frac23;":8532,"frac25;":8534,frac34:190,"frac34;":190,"frac35;":8535,"frac38;":8540,"frac45;":8536,"frac56;":8538,"frac58;":8541,"frac78;":8542,"frasl;":8260,"frown;":8994,"fscr;":[55349,56507],"gE;":8807,"gEl;":10892,"gacute;":501,"gamma;":947,"gammad;":989,"gap;":10886,"gbreve;":287,"gcirc;":285,"gcy;":1075,"gdot;":289,"ge;":8805,"gel;":8923,"geq;":8805,"geqq;":8807,"geqslant;":10878,"ges;":10878,"gescc;":10921,"gesdot;":10880,"gesdoto;":10882,"gesdotol;":10884,"gesl;":[8923,65024],"gesles;":10900,"gfr;":[55349,56612],"gg;":8811,"ggg;":8921,"gimel;":8503,"gjcy;":1107,"gl;":8823,"glE;":10898,"gla;":10917,"glj;":10916,"gnE;":8809,"gnap;":10890,"gnapprox;":10890,"gne;":10888,"gneq;":10888,"gneqq;":8809,"gnsim;":8935,"gopf;":[55349,56664],"grave;":96,"gscr;":8458,"gsim;":8819,"gsime;":10894,"gsiml;":10896,gt:62,"gt;":62,"gtcc;":10919,"gtcir;":10874,"gtdot;":8919,"gtlPar;":10645,"gtquest;":10876,"gtrapprox;":10886,"gtrarr;":10616,"gtrdot;":8919,"gtreqless;":8923,"gtreqqless;":10892,"gtrless;":8823,"gtrsim;":8819,"gvertneqq;":[8809,65024],"gvnE;":[8809,65024],"hArr;":8660,"hairsp;":8202,"half;":189,"hamilt;":8459,"hardcy;":1098,"harr;":8596,"harrcir;":10568,"harrw;":8621,"hbar;":8463,"hcirc;":293,"hearts;":9829,"heartsuit;":9829,"hellip;":8230,"hercon;":8889,"hfr;":[55349,56613],"hksearow;":10533,"hkswarow;":10534,"hoarr;":8703,"homtht;":8763,"hookleftarrow;":8617,"hookrightarrow;":8618,"hopf;":[55349,56665],"horbar;":8213,"hscr;":[55349,56509],"hslash;":8463,"hstrok;":295,"hybull;":8259,"hyphen;":8208,iacute:237,"iacute;":237,"ic;":8291,icirc:238,"icirc;":238,"icy;":1080,"iecy;":1077,iexcl:161,"iexcl;":161,"iff;":8660,"ifr;":[55349,56614],igrave:236,"igrave;":236,"ii;":8520,"iiiint;":10764,"iiint;":8749,"iinfin;":10716,"iiota;":8489,"ijlig;":307,"imacr;":299,"image;":8465,"imagline;":8464,"imagpart;":8465,"imath;":305,"imof;":8887,"imped;":437,"in;":8712,"incare;":8453,"infin;":8734,"infintie;":10717,"inodot;":305,"int;":8747,"intcal;":8890,"integers;":8484,"intercal;":8890,"intlarhk;":10775,"intprod;":10812,"iocy;":1105,"iogon;":303,"iopf;":[55349,56666],"iota;":953,"iprod;":10812,iquest:191,"iquest;":191,"iscr;":[55349,56510],"isin;":8712,"isinE;":8953,"isindot;":8949,"isins;":8948,"isinsv;":8947,"isinv;":8712,"it;":8290,"itilde;":297,"iukcy;":1110,iuml:239,"iuml;":239,"jcirc;":309,"jcy;":1081,"jfr;":[55349,56615],"jmath;":567,"jopf;":[55349,56667],"jscr;":[55349,56511],"jsercy;":1112,"jukcy;":1108,"kappa;":954,"kappav;":1008,"kcedil;":311,"kcy;":1082,"kfr;":[55349,56616],"kgreen;":312,"khcy;":1093,"kjcy;":1116,"kopf;":[55349,56668],"kscr;":[55349,56512],"lAarr;":8666,"lArr;":8656,"lAtail;":10523,"lBarr;":10510,"lE;":8806,"lEg;":10891,"lHar;":10594,"lacute;":314,"laemptyv;":10676,"lagran;":8466,"lambda;":955,"lang;":10216,"langd;":10641,"langle;":10216,"lap;":10885,laquo:171,"laquo;":171,"larr;":8592,"larrb;":8676,"larrbfs;":10527,"larrfs;":10525,"larrhk;":8617,"larrlp;":8619,"larrpl;":10553,"larrsim;":10611,"larrtl;":8610,"lat;":10923,"latail;":10521,"late;":10925,"lates;":[10925,65024],"lbarr;":10508,"lbbrk;":10098,"lbrace;":123,"lbrack;":91,"lbrke;":10635,"lbrksld;":10639,"lbrkslu;":10637,"lcaron;":318,"lcedil;":316,"lceil;":8968,"lcub;":123,"lcy;":1083,"ldca;":10550,"ldquo;":8220,"ldquor;":8222,"ldrdhar;":10599,"ldrushar;":10571,"ldsh;":8626,"le;":8804,"leftarrow;":8592,"leftarrowtail;":8610,"leftharpoondown;":8637,"leftharpoonup;":8636,"leftleftarrows;":8647,"leftrightarrow;":8596,"leftrightarrows;":8646,"leftrightharpoons;":8651,"leftrightsquigarrow;":8621,"leftthreetimes;":8907,"leg;":8922,"leq;":8804,"leqq;":8806,"leqslant;":10877,"les;":10877,"lescc;":10920,"lesdot;":10879,"lesdoto;":10881,"lesdotor;":10883,"lesg;":[8922,65024],"lesges;":10899,"lessapprox;":10885,"lessdot;":8918,"lesseqgtr;":8922,"lesseqqgtr;":10891,"lessgtr;":8822,"lesssim;":8818,"lfisht;":10620,"lfloor;":8970,"lfr;":[55349,56617],"lg;":8822,"lgE;":10897,"lhard;":8637,"lharu;":8636,"lharul;":10602,"lhblk;":9604,"ljcy;":1113,"ll;":8810,"llarr;":8647,"llcorner;":8990,"llhard;":10603,"lltri;":9722,"lmidot;":320,"lmoust;":9136,"lmoustache;":9136,"lnE;":8808,"lnap;":10889,"lnapprox;":10889,"lne;":10887,"lneq;":10887,"lneqq;":8808,"lnsim;":8934,"loang;":10220,"loarr;":8701,"lobrk;":10214,"longleftarrow;":10229,"longleftrightarrow;":10231,"longmapsto;":10236,"longrightarrow;":10230,"looparrowleft;":8619,"looparrowright;":8620,"lopar;":10629,"lopf;":[55349,56669],"loplus;":10797,"lotimes;":10804,"lowast;":8727,"lowbar;":95,"loz;":9674,"lozenge;":9674,"lozf;":10731,"lpar;":40,"lparlt;":10643,"lrarr;":8646,"lrcorner;":8991,"lrhar;":8651,"lrhard;":10605,"lrm;":8206,"lrtri;":8895,"lsaquo;":8249,"lscr;":[55349,56513],"lsh;":8624,"lsim;":8818,"lsime;":10893,"lsimg;":10895,"lsqb;":91,"lsquo;":8216,"lsquor;":8218,"lstrok;":322,lt:60,"lt;":60,"ltcc;":10918,"ltcir;":10873,"ltdot;":8918,"lthree;":8907,"ltimes;":8905,"ltlarr;":10614,"ltquest;":10875,"ltrPar;":10646,"ltri;":9667,"ltrie;":8884,"ltrif;":9666,"lurdshar;":10570,"luruhar;":10598,"lvertneqq;":[8808,65024],"lvnE;":[8808,65024],"mDDot;":8762,macr:175,"macr;":175,"male;":9794,"malt;":10016,"maltese;":10016,"map;":8614,"mapsto;":8614,"mapstodown;":8615,"mapstoleft;":8612,"mapstoup;":8613,"marker;":9646,"mcomma;":10793,"mcy;":1084,"mdash;":8212,"measuredangle;":8737,"mfr;":[55349,56618],"mho;":8487,micro:181,"micro;":181,"mid;":8739,"midast;":42,"midcir;":10992,middot:183,"middot;":183,"minus;":8722,"minusb;":8863,"minusd;":8760,"minusdu;":10794,"mlcp;":10971,"mldr;":8230,"mnplus;":8723,"models;":8871,"mopf;":[55349,56670],"mp;":8723,"mscr;":[55349,56514],"mstpos;":8766,"mu;":956,"multimap;":8888,"mumap;":8888,"nGg;":[8921,824],"nGt;":[8811,8402],"nGtv;":[8811,824],"nLeftarrow;":8653,"nLeftrightarrow;":8654,"nLl;":[8920,824],"nLt;":[8810,8402],"nLtv;":[8810,824],"nRightarrow;":8655,"nVDash;":8879,"nVdash;":8878,"nabla;":8711,"nacute;":324,"nang;":[8736,8402],"nap;":8777,"napE;":[10864,824],"napid;":[8779,824],"napos;":329,"napprox;":8777,"natur;":9838,"natural;":9838,"naturals;":8469,nbsp:160,"nbsp;":160,"nbump;":[8782,824],"nbumpe;":[8783,824],"ncap;":10819,"ncaron;":328,"ncedil;":326,"ncong;":8775,"ncongdot;":[10861,824],"ncup;":10818,"ncy;":1085,"ndash;":8211,"ne;":8800,"neArr;":8663,"nearhk;":10532,"nearr;":8599,"nearrow;":8599,"nedot;":[8784,824],"nequiv;":8802,"nesear;":10536,"nesim;":[8770,824],"nexist;":8708,"nexists;":8708,"nfr;":[55349,56619],"ngE;":[8807,824],"nge;":8817,"ngeq;":8817,"ngeqq;":[8807,824],"ngeqslant;":[10878,824],"nges;":[10878,824],"ngsim;":8821,"ngt;":8815,"ngtr;":8815,"nhArr;":8654,"nharr;":8622,"nhpar;":10994,"ni;":8715,"nis;":8956,"nisd;":8954,"niv;":8715,"njcy;":1114,"nlArr;":8653,"nlE;":[8806,824],"nlarr;":8602,"nldr;":8229,"nle;":8816,"nleftarrow;":8602,"nleftrightarrow;":8622,"nleq;":8816,"nleqq;":[8806,824],"nleqslant;":[10877,824],"nles;":[10877,824],"nless;":8814,"nlsim;":8820,"nlt;":8814,"nltri;":8938,"nltrie;":8940,"nmid;":8740,"nopf;":[55349,56671],not:172,"not;":172,"notin;":8713,"notinE;":[8953,824],"notindot;":[8949,824],"notinva;":8713,"notinvb;":8951,"notinvc;":8950,"notni;":8716,"notniva;":8716,"notnivb;":8958,"notnivc;":8957,"npar;":8742,"nparallel;":8742,"nparsl;":[11005,8421],"npart;":[8706,824],"npolint;":10772,"npr;":8832,"nprcue;":8928,"npre;":[10927,824],"nprec;":8832,"npreceq;":[10927,824],"nrArr;":8655,"nrarr;":8603,"nrarrc;":[10547,824],"nrarrw;":[8605,824],"nrightarrow;":8603,"nrtri;":8939,"nrtrie;":8941,"nsc;":8833,"nsccue;":8929,"nsce;":[10928,824],"nscr;":[55349,56515],"nshortmid;":8740,"nshortparallel;":8742,"nsim;":8769,"nsime;":8772,"nsimeq;":8772,"nsmid;":8740,"nspar;":8742,"nsqsube;":8930,"nsqsupe;":8931,"nsub;":8836,"nsubE;":[10949,824],"nsube;":8840,"nsubset;":[8834,8402],"nsubseteq;":8840,"nsubseteqq;":[10949,824],"nsucc;":8833,"nsucceq;":[10928,824],"nsup;":8837,"nsupE;":[10950,824],"nsupe;":8841,"nsupset;":[8835,8402],"nsupseteq;":8841,"nsupseteqq;":[10950,824],"ntgl;":8825,ntilde:241,"ntilde;":241,"ntlg;":8824,"ntriangleleft;":8938,"ntrianglelefteq;":8940,"ntriangleright;":8939,"ntrianglerighteq;":8941,"nu;":957,"num;":35,"numero;":8470,"numsp;":8199,"nvDash;":8877,"nvHarr;":10500,"nvap;":[8781,8402],"nvdash;":8876,"nvge;":[8805,8402],"nvgt;":[62,8402],"nvinfin;":10718,"nvlArr;":10498,"nvle;":[8804,8402],"nvlt;":[60,8402],"nvltrie;":[8884,8402],"nvrArr;":10499,"nvrtrie;":[8885,8402],"nvsim;":[8764,8402],"nwArr;":8662,"nwarhk;":10531,"nwarr;":8598,"nwarrow;":8598,"nwnear;":10535,"oS;":9416,oacute:243,"oacute;":243,"oast;":8859,"ocir;":8858,ocirc:244,"ocirc;":244,"ocy;":1086,"odash;":8861,"odblac;":337,"odiv;":10808,"odot;":8857,"odsold;":10684,"oelig;":339,"ofcir;":10687,"ofr;":[55349,56620],"ogon;":731,ograve:242,"ograve;":242,"ogt;":10689,"ohbar;":10677,"ohm;":937,"oint;":8750,"olarr;":8634,"olcir;":10686,"olcross;":10683,"oline;":8254,"olt;":10688,"omacr;":333,"omega;":969,"omicron;":959,"omid;":10678,"ominus;":8854,"oopf;":[55349,56672],"opar;":10679,"operp;":10681,"oplus;":8853,"or;":8744,"orarr;":8635,"ord;":10845,"order;":8500,"orderof;":8500,ordf:170,"ordf;":170,ordm:186,"ordm;":186,"origof;":8886,"oror;":10838,"orslope;":10839,"orv;":10843,"oscr;":8500,oslash:248,"oslash;":248,"osol;":8856,otilde:245,"otilde;":245,"otimes;":8855,"otimesas;":10806,ouml:246,"ouml;":246,"ovbar;":9021,"par;":8741,para:182,"para;":182,"parallel;":8741,"parsim;":10995,"parsl;":11005,"part;":8706,"pcy;":1087,"percnt;":37,"period;":46,"permil;":8240,"perp;":8869,"pertenk;":8241,"pfr;":[55349,56621],"phi;":966,"phiv;":981,"phmmat;":8499,"phone;":9742,"pi;":960,"pitchfork;":8916,"piv;":982,"planck;":8463,"planckh;":8462,"plankv;":8463,"plus;":43,"plusacir;":10787,"plusb;":8862,"pluscir;":10786,"plusdo;":8724,"plusdu;":10789,"pluse;":10866,plusmn:177,"plusmn;":177,"plussim;":10790,"plustwo;":10791,"pm;":177,"pointint;":10773,"popf;":[55349,56673],pound:163,"pound;":163,"pr;":8826,"prE;":10931,"prap;":10935,"prcue;":8828,"pre;":10927,"prec;":8826,"precapprox;":10935,"preccurlyeq;":8828,"preceq;":10927,"precnapprox;":10937,"precneqq;":10933,"precnsim;":8936,"precsim;":8830,"prime;":8242,"primes;":8473,"prnE;":10933,"prnap;":10937,"prnsim;":8936,"prod;":8719,"profalar;":9006,"profline;":8978,"profsurf;":8979,"prop;":8733,"propto;":8733,"prsim;":8830,"prurel;":8880,"pscr;":[55349,56517],"psi;":968,"puncsp;":8200,"qfr;":[55349,56622],"qint;":10764,"qopf;":[55349,56674],"qprime;":8279,"qscr;":[55349,56518],"quaternions;":8461,"quatint;":10774,"quest;":63,"questeq;":8799,quot:34,"quot;":34,"rAarr;":8667,"rArr;":8658,"rAtail;":10524,"rBarr;":10511,"rHar;":10596,"race;":[8765,817],"racute;":341,"radic;":8730,"raemptyv;":10675,"rang;":10217,"rangd;":10642,"range;":10661,"rangle;":10217,raquo:187,"raquo;":187,"rarr;":8594,"rarrap;":10613,"rarrb;":8677,"rarrbfs;":10528,"rarrc;":10547,"rarrfs;":10526,"rarrhk;":8618,"rarrlp;":8620,"rarrpl;":10565,"rarrsim;":10612,"rarrtl;":8611,"rarrw;":8605,"ratail;":10522,"ratio;":8758,"rationals;":8474,"rbarr;":10509,"rbbrk;":10099,"rbrace;":125,"rbrack;":93,"rbrke;":10636,"rbrksld;":10638,"rbrkslu;":10640,"rcaron;":345,"rcedil;":343,"rceil;":8969,"rcub;":125,"rcy;":1088,"rdca;":10551,"rdldhar;":10601,"rdquo;":8221,"rdquor;":8221,"rdsh;":8627,"real;":8476,"realine;":8475,"realpart;":8476,"reals;":8477,"rect;":9645,reg:174,"reg;":174,"rfisht;":10621,"rfloor;":8971,"rfr;":[55349,56623],"rhard;":8641,"rharu;":8640,"rharul;":10604,"rho;":961,"rhov;":1009,"rightarrow;":8594,"rightarrowtail;":8611,"rightharpoondown;":8641,"rightharpoonup;":8640,"rightleftarrows;":8644,"rightleftharpoons;":8652,"rightrightarrows;":8649,"rightsquigarrow;":8605,"rightthreetimes;":8908,"ring;":730,"risingdotseq;":8787,"rlarr;":8644,"rlhar;":8652,"rlm;":8207,"rmoust;":9137,"rmoustache;":9137,"rnmid;":10990,"roang;":10221,"roarr;":8702,"robrk;":10215,"ropar;":10630,"ropf;":[55349,56675],"roplus;":10798,"rotimes;":10805,"rpar;":41,"rpargt;":10644,"rppolint;":10770,"rrarr;":8649,"rsaquo;":8250,"rscr;":[55349,56519],"rsh;":8625,"rsqb;":93,"rsquo;":8217,"rsquor;":8217,"rthree;":8908,"rtimes;":8906,"rtri;":9657,"rtrie;":8885,"rtrif;":9656,"rtriltri;":10702,"ruluhar;":10600,"rx;":8478,"sacute;":347,"sbquo;":8218,"sc;":8827,"scE;":10932,"scap;":10936,"scaron;":353,"sccue;":8829,"sce;":10928,"scedil;":351,"scirc;":349,"scnE;":10934,"scnap;":10938,"scnsim;":8937,"scpolint;":10771,"scsim;":8831,"scy;":1089,"sdot;":8901,"sdotb;":8865,"sdote;":10854,"seArr;":8664,"searhk;":10533,"searr;":8600,"searrow;":8600,sect:167,"sect;":167,"semi;":59,"seswar;":10537,"setminus;":8726,"setmn;":8726,"sext;":10038,"sfr;":[55349,56624],"sfrown;":8994,"sharp;":9839,"shchcy;":1097,"shcy;":1096,"shortmid;":8739,"shortparallel;":8741,shy:173,"shy;":173,"sigma;":963,"sigmaf;":962,"sigmav;":962,"sim;":8764,"simdot;":10858,"sime;":8771,"simeq;":8771,"simg;":10910,"simgE;":10912,"siml;":10909,"simlE;":10911,"simne;":8774,"simplus;":10788,"simrarr;":10610,"slarr;":8592,"smallsetminus;":8726,"smashp;":10803,"smeparsl;":10724,"smid;":8739,"smile;":8995,"smt;":10922,"smte;":10924,"smtes;":[10924,65024],"softcy;":1100,"sol;":47,"solb;":10692,"solbar;":9023,"sopf;":[55349,56676],"spades;":9824,"spadesuit;":9824,"spar;":8741,"sqcap;":8851,"sqcaps;":[8851,65024],"sqcup;":8852,"sqcups;":[8852,65024],"sqsub;":8847,"sqsube;":8849,"sqsubset;":8847,"sqsubseteq;":8849,"sqsup;":8848,"sqsupe;":8850,"sqsupset;":8848,"sqsupseteq;":8850,"squ;":9633,"square;":9633,"squarf;":9642,"squf;":9642,"srarr;":8594,"sscr;":[55349,56520],"ssetmn;":8726,"ssmile;":8995,"sstarf;":8902,"star;":9734,"starf;":9733,"straightepsilon;":1013,"straightphi;":981,"strns;":175,"sub;":8834,"subE;":10949,"subdot;":10941,"sube;":8838,"subedot;":10947,"submult;":10945,"subnE;":10955,"subne;":8842,"subplus;":10943,"subrarr;":10617,"subset;":8834,"subseteq;":8838,"subseteqq;":10949,"subsetneq;":8842,"subsetneqq;":10955,"subsim;":10951,"subsub;":10965,"subsup;":10963,"succ;":8827,"succapprox;":10936,"succcurlyeq;":8829,"succeq;":10928,"succnapprox;":10938,"succneqq;":10934,"succnsim;":8937,"succsim;":8831,"sum;":8721,"sung;":9834,sup1:185,"sup1;":185,sup2:178,"sup2;":178,sup3:179,"sup3;":179,"sup;":8835,"supE;":10950,"supdot;":10942,"supdsub;":10968,"supe;":8839,"supedot;":10948,"suphsol;":10185,"suphsub;":10967,"suplarr;":10619,"supmult;":10946,"supnE;":10956,"supne;":8843,"supplus;":10944,"supset;":8835,"supseteq;":8839,"supseteqq;":10950,"supsetneq;":8843,"supsetneqq;":10956,"supsim;":10952,"supsub;":10964,"supsup;":10966,"swArr;":8665,"swarhk;":10534,"swarr;":8601,"swarrow;":8601,"swnwar;":10538,szlig:223,"szlig;":223,"target;":8982,"tau;":964,"tbrk;":9140,"tcaron;":357,"tcedil;":355,"tcy;":1090,"tdot;":8411,"telrec;":8981,"tfr;":[55349,56625],"there4;":8756,"therefore;":8756,"theta;":952,"thetasym;":977,"thetav;":977,"thickapprox;":8776,"thicksim;":8764,"thinsp;":8201,"thkap;":8776,"thksim;":8764,thorn:254,"thorn;":254,"tilde;":732,times:215,"times;":215,"timesb;":8864,"timesbar;":10801,"timesd;":10800,"tint;":8749,"toea;":10536,"top;":8868,"topbot;":9014,"topcir;":10993,"topf;":[55349,56677],"topfork;":10970,"tosa;":10537,"tprime;":8244,"trade;":8482,"triangle;":9653,"triangledown;":9663,"triangleleft;":9667,"trianglelefteq;":8884,"triangleq;":8796,"triangleright;":9657,"trianglerighteq;":8885,"tridot;":9708,"trie;":8796,"triminus;":10810,"triplus;":10809,"trisb;":10701,"tritime;":10811,"trpezium;":9186,"tscr;":[55349,56521],"tscy;":1094,"tshcy;":1115,"tstrok;":359,"twixt;":8812,"twoheadleftarrow;":8606,"twoheadrightarrow;":8608,"uArr;":8657,"uHar;":10595,uacute:250,"uacute;":250,"uarr;":8593,"ubrcy;":1118,"ubreve;":365,ucirc:251,"ucirc;":251,"ucy;":1091,"udarr;":8645,"udblac;":369,"udhar;":10606,"ufisht;":10622,"ufr;":[55349,56626],ugrave:249,"ugrave;":249,"uharl;":8639,"uharr;":8638,"uhblk;":9600,"ulcorn;":8988,"ulcorner;":8988,"ulcrop;":8975,"ultri;":9720,"umacr;":363,uml:168,"uml;":168,"uogon;":371,"uopf;":[55349,56678],"uparrow;":8593,"updownarrow;":8597,"upharpoonleft;":8639,"upharpoonright;":8638,"uplus;":8846,"upsi;":965,"upsih;":978,"upsilon;":965,"upuparrows;":8648,"urcorn;":8989,"urcorner;":8989,"urcrop;":8974,"uring;":367,"urtri;":9721,"uscr;":[55349,56522],"utdot;":8944,"utilde;":361,"utri;":9653,"utrif;":9652,"uuarr;":8648,uuml:252,"uuml;":252,"uwangle;":10663,"vArr;":8661,"vBar;":10984,"vBarv;":10985,"vDash;":8872,"vangrt;":10652,"varepsilon;":1013,"varkappa;":1008,"varnothing;":8709,"varphi;":981,"varpi;":982,"varpropto;":8733,"varr;":8597,"varrho;":1009,"varsigma;":962,"varsubsetneq;":[8842,65024],"varsubsetneqq;":[10955,65024],"varsupsetneq;":[8843,65024],"varsupsetneqq;":[10956,65024],"vartheta;":977,"vartriangleleft;":8882,"vartriangleright;":8883,"vcy;":1074,"vdash;":8866,"vee;":8744,"veebar;":8891,"veeeq;":8794,"vellip;":8942,"verbar;":124,"vert;":124,"vfr;":[55349,56627],"vltri;":8882,"vnsub;":[8834,8402],"vnsup;":[8835,8402],"vopf;":[55349,56679],"vprop;":8733,"vrtri;":8883,"vscr;":[55349,56523],"vsubnE;":[10955,65024],"vsubne;":[8842,65024],"vsupnE;":[10956,65024],"vsupne;":[8843,65024],"vzigzag;":10650,"wcirc;":373,"wedbar;":10847,"wedge;":8743,"wedgeq;":8793,"weierp;":8472,"wfr;":[55349,56628],"wopf;":[55349,56680],"wp;":8472,"wr;":8768,"wreath;":8768,"wscr;":[55349,56524],"xcap;":8898,"xcirc;":9711,"xcup;":8899,"xdtri;":9661,"xfr;":[55349,56629],"xhArr;":10234,"xharr;":10231,"xi;":958,"xlArr;":10232,"xlarr;":10229,"xmap;":10236,"xnis;":8955,"xodot;":10752,"xopf;":[55349,56681],"xoplus;":10753,"xotime;":10754,"xrArr;":10233,"xrarr;":10230,"xscr;":[55349,56525],"xsqcup;":10758,"xuplus;":10756,"xutri;":9651,"xvee;":8897,"xwedge;":8896,yacute:253,"yacute;":253,"yacy;":1103,"ycirc;":375,"ycy;":1099,yen:165,"yen;":165,"yfr;":[55349,56630],"yicy;":1111,"yopf;":[55349,56682],"yscr;":[55349,56526],"yucy;":1102,yuml:255,"yuml;":255,"zacute;":378,"zcaron;":382,"zcy;":1079,"zdot;":380,"zeetrf;":8488,"zeta;":950,"zfr;":[55349,56631],"zhcy;":1078,"zigrarr;":8669,"zopf;":[55349,56683],"zscr;":[55349,56527],"zwj;":8205,"zwnj;":8204},wj=/(A(?:Elig;?|MP;?|acute;?|breve;|c(?:irc;?|y;)|fr;|grave;?|lpha;|macr;|nd;|o(?:gon;|pf;)|pplyFunction;|ring;?|s(?:cr;|sign;)|tilde;?|uml;?)|B(?:a(?:ckslash;|r(?:v;|wed;))|cy;|e(?:cause;|rnoullis;|ta;)|fr;|opf;|reve;|scr;|umpeq;)|C(?:Hcy;|OPY;?|a(?:cute;|p(?:;|italDifferentialD;)|yleys;)|c(?:aron;|edil;?|irc;|onint;)|dot;|e(?:dilla;|nterDot;)|fr;|hi;|ircle(?:Dot;|Minus;|Plus;|Times;)|lo(?:ckwiseContourIntegral;|seCurly(?:DoubleQuote;|Quote;))|o(?:lon(?:;|e;)|n(?:gruent;|int;|tourIntegral;)|p(?:f;|roduct;)|unterClockwiseContourIntegral;)|ross;|scr;|up(?:;|Cap;))|D(?:D(?:;|otrahd;)|Jcy;|Scy;|Zcy;|a(?:gger;|rr;|shv;)|c(?:aron;|y;)|el(?:;|ta;)|fr;|i(?:a(?:critical(?:Acute;|Do(?:t;|ubleAcute;)|Grave;|Tilde;)|mond;)|fferentialD;)|o(?:pf;|t(?:;|Dot;|Equal;)|uble(?:ContourIntegral;|Do(?:t;|wnArrow;)|L(?:eft(?:Arrow;|RightArrow;|Tee;)|ong(?:Left(?:Arrow;|RightArrow;)|RightArrow;))|Right(?:Arrow;|Tee;)|Up(?:Arrow;|DownArrow;)|VerticalBar;)|wn(?:Arrow(?:;|Bar;|UpArrow;)|Breve;|Left(?:RightVector;|TeeVector;|Vector(?:;|Bar;))|Right(?:TeeVector;|Vector(?:;|Bar;))|Tee(?:;|Arrow;)|arrow;))|s(?:cr;|trok;))|E(?:NG;|TH;?|acute;?|c(?:aron;|irc;?|y;)|dot;|fr;|grave;?|lement;|m(?:acr;|pty(?:SmallSquare;|VerySmallSquare;))|o(?:gon;|pf;)|psilon;|qu(?:al(?:;|Tilde;)|ilibrium;)|s(?:cr;|im;)|ta;|uml;?|x(?:ists;|ponentialE;))|F(?:cy;|fr;|illed(?:SmallSquare;|VerySmallSquare;)|o(?:pf;|rAll;|uriertrf;)|scr;)|G(?:Jcy;|T;?|amma(?:;|d;)|breve;|c(?:edil;|irc;|y;)|dot;|fr;|g;|opf;|reater(?:Equal(?:;|Less;)|FullEqual;|Greater;|Less;|SlantEqual;|Tilde;)|scr;|t;)|H(?:ARDcy;|a(?:cek;|t;)|circ;|fr;|ilbertSpace;|o(?:pf;|rizontalLine;)|s(?:cr;|trok;)|ump(?:DownHump;|Equal;))|I(?:Ecy;|Jlig;|Ocy;|acute;?|c(?:irc;?|y;)|dot;|fr;|grave;?|m(?:;|a(?:cr;|ginaryI;)|plies;)|n(?:t(?:;|e(?:gral;|rsection;))|visible(?:Comma;|Times;))|o(?:gon;|pf;|ta;)|scr;|tilde;|u(?:kcy;|ml;?))|J(?:c(?:irc;|y;)|fr;|opf;|s(?:cr;|ercy;)|ukcy;)|K(?:Hcy;|Jcy;|appa;|c(?:edil;|y;)|fr;|opf;|scr;)|L(?:Jcy;|T;?|a(?:cute;|mbda;|ng;|placetrf;|rr;)|c(?:aron;|edil;|y;)|e(?:ft(?:A(?:ngleBracket;|rrow(?:;|Bar;|RightArrow;))|Ceiling;|Do(?:ubleBracket;|wn(?:TeeVector;|Vector(?:;|Bar;)))|Floor;|Right(?:Arrow;|Vector;)|T(?:ee(?:;|Arrow;|Vector;)|riangle(?:;|Bar;|Equal;))|Up(?:DownVector;|TeeVector;|Vector(?:;|Bar;))|Vector(?:;|Bar;)|arrow;|rightarrow;)|ss(?:EqualGreater;|FullEqual;|Greater;|Less;|SlantEqual;|Tilde;))|fr;|l(?:;|eftarrow;)|midot;|o(?:ng(?:Left(?:Arrow;|RightArrow;)|RightArrow;|left(?:arrow;|rightarrow;)|rightarrow;)|pf;|wer(?:LeftArrow;|RightArrow;))|s(?:cr;|h;|trok;)|t;)|M(?:ap;|cy;|e(?:diumSpace;|llintrf;)|fr;|inusPlus;|opf;|scr;|u;)|N(?:Jcy;|acute;|c(?:aron;|edil;|y;)|e(?:gative(?:MediumSpace;|Thi(?:ckSpace;|nSpace;)|VeryThinSpace;)|sted(?:GreaterGreater;|LessLess;)|wLine;)|fr;|o(?:Break;|nBreakingSpace;|pf;|t(?:;|C(?:ongruent;|upCap;)|DoubleVerticalBar;|E(?:lement;|qual(?:;|Tilde;)|xists;)|Greater(?:;|Equal;|FullEqual;|Greater;|Less;|SlantEqual;|Tilde;)|Hump(?:DownHump;|Equal;)|Le(?:ftTriangle(?:;|Bar;|Equal;)|ss(?:;|Equal;|Greater;|Less;|SlantEqual;|Tilde;))|Nested(?:GreaterGreater;|LessLess;)|Precedes(?:;|Equal;|SlantEqual;)|R(?:everseElement;|ightTriangle(?:;|Bar;|Equal;))|S(?:quareSu(?:bset(?:;|Equal;)|perset(?:;|Equal;))|u(?:bset(?:;|Equal;)|cceeds(?:;|Equal;|SlantEqual;|Tilde;)|perset(?:;|Equal;)))|Tilde(?:;|Equal;|FullEqual;|Tilde;)|VerticalBar;))|scr;|tilde;?|u;)|O(?:Elig;|acute;?|c(?:irc;?|y;)|dblac;|fr;|grave;?|m(?:acr;|ega;|icron;)|opf;|penCurly(?:DoubleQuote;|Quote;)|r;|s(?:cr;|lash;?)|ti(?:lde;?|mes;)|uml;?|ver(?:B(?:ar;|rac(?:e;|ket;))|Parenthesis;))|P(?:artialD;|cy;|fr;|hi;|i;|lusMinus;|o(?:incareplane;|pf;)|r(?:;|ecedes(?:;|Equal;|SlantEqual;|Tilde;)|ime;|o(?:duct;|portion(?:;|al;)))|s(?:cr;|i;))|Q(?:UOT;?|fr;|opf;|scr;)|R(?:Barr;|EG;?|a(?:cute;|ng;|rr(?:;|tl;))|c(?:aron;|edil;|y;)|e(?:;|verse(?:E(?:lement;|quilibrium;)|UpEquilibrium;))|fr;|ho;|ight(?:A(?:ngleBracket;|rrow(?:;|Bar;|LeftArrow;))|Ceiling;|Do(?:ubleBracket;|wn(?:TeeVector;|Vector(?:;|Bar;)))|Floor;|T(?:ee(?:;|Arrow;|Vector;)|riangle(?:;|Bar;|Equal;))|Up(?:DownVector;|TeeVector;|Vector(?:;|Bar;))|Vector(?:;|Bar;)|arrow;)|o(?:pf;|undImplies;)|rightarrow;|s(?:cr;|h;)|uleDelayed;)|S(?:H(?:CHcy;|cy;)|OFTcy;|acute;|c(?:;|aron;|edil;|irc;|y;)|fr;|hort(?:DownArrow;|LeftArrow;|RightArrow;|UpArrow;)|igma;|mallCircle;|opf;|q(?:rt;|uare(?:;|Intersection;|Su(?:bset(?:;|Equal;)|perset(?:;|Equal;))|Union;))|scr;|tar;|u(?:b(?:;|set(?:;|Equal;))|c(?:ceeds(?:;|Equal;|SlantEqual;|Tilde;)|hThat;)|m;|p(?:;|erset(?:;|Equal;)|set;)))|T(?:HORN;?|RADE;|S(?:Hcy;|cy;)|a(?:b;|u;)|c(?:aron;|edil;|y;)|fr;|h(?:e(?:refore;|ta;)|i(?:ckSpace;|nSpace;))|ilde(?:;|Equal;|FullEqual;|Tilde;)|opf;|ripleDot;|s(?:cr;|trok;))|U(?:a(?:cute;?|rr(?:;|ocir;))|br(?:cy;|eve;)|c(?:irc;?|y;)|dblac;|fr;|grave;?|macr;|n(?:der(?:B(?:ar;|rac(?:e;|ket;))|Parenthesis;)|ion(?:;|Plus;))|o(?:gon;|pf;)|p(?:Arrow(?:;|Bar;|DownArrow;)|DownArrow;|Equilibrium;|Tee(?:;|Arrow;)|arrow;|downarrow;|per(?:LeftArrow;|RightArrow;)|si(?:;|lon;))|ring;|scr;|tilde;|uml;?)|V(?:Dash;|bar;|cy;|dash(?:;|l;)|e(?:e;|r(?:bar;|t(?:;|ical(?:Bar;|Line;|Separator;|Tilde;))|yThinSpace;))|fr;|opf;|scr;|vdash;)|W(?:circ;|edge;|fr;|opf;|scr;)|X(?:fr;|i;|opf;|scr;)|Y(?:Acy;|Icy;|Ucy;|acute;?|c(?:irc;|y;)|fr;|opf;|scr;|uml;)|Z(?:Hcy;|acute;|c(?:aron;|y;)|dot;|e(?:roWidthSpace;|ta;)|fr;|opf;|scr;)|a(?:acute;?|breve;|c(?:;|E;|d;|irc;?|ute;?|y;)|elig;?|f(?:;|r;)|grave;?|l(?:e(?:fsym;|ph;)|pha;)|m(?:a(?:cr;|lg;)|p;?)|n(?:d(?:;|and;|d;|slope;|v;)|g(?:;|e;|le;|msd(?:;|a(?:a;|b;|c;|d;|e;|f;|g;|h;))|rt(?:;|vb(?:;|d;))|s(?:ph;|t;)|zarr;))|o(?:gon;|pf;)|p(?:;|E;|acir;|e;|id;|os;|prox(?:;|eq;))|ring;?|s(?:cr;|t;|ymp(?:;|eq;))|tilde;?|uml;?|w(?:conint;|int;))|b(?:Not;|a(?:ck(?:cong;|epsilon;|prime;|sim(?:;|eq;))|r(?:vee;|wed(?:;|ge;)))|brk(?:;|tbrk;)|c(?:ong;|y;)|dquo;|e(?:caus(?:;|e;)|mptyv;|psi;|rnou;|t(?:a;|h;|ween;))|fr;|ig(?:c(?:ap;|irc;|up;)|o(?:dot;|plus;|times;)|s(?:qcup;|tar;)|triangle(?:down;|up;)|uplus;|vee;|wedge;)|karow;|l(?:a(?:ck(?:lozenge;|square;|triangle(?:;|down;|left;|right;))|nk;)|k(?:1(?:2;|4;)|34;)|ock;)|n(?:e(?:;|quiv;)|ot;)|o(?:pf;|t(?:;|tom;)|wtie;|x(?:D(?:L;|R;|l;|r;)|H(?:;|D;|U;|d;|u;)|U(?:L;|R;|l;|r;)|V(?:;|H;|L;|R;|h;|l;|r;)|box;|d(?:L;|R;|l;|r;)|h(?:;|D;|U;|d;|u;)|minus;|plus;|times;|u(?:L;|R;|l;|r;)|v(?:;|H;|L;|R;|h;|l;|r;)))|prime;|r(?:eve;|vbar;?)|s(?:cr;|emi;|im(?:;|e;)|ol(?:;|b;|hsub;))|u(?:ll(?:;|et;)|mp(?:;|E;|e(?:;|q;))))|c(?:a(?:cute;|p(?:;|and;|brcup;|c(?:ap;|up;)|dot;|s;)|r(?:et;|on;))|c(?:a(?:ps;|ron;)|edil;?|irc;|ups(?:;|sm;))|dot;|e(?:dil;?|mptyv;|nt(?:;|erdot;|))|fr;|h(?:cy;|eck(?:;|mark;)|i;)|ir(?:;|E;|c(?:;|eq;|le(?:arrow(?:left;|right;)|d(?:R;|S;|ast;|circ;|dash;)))|e;|fnint;|mid;|scir;)|lubs(?:;|uit;)|o(?:lon(?:;|e(?:;|q;))|m(?:ma(?:;|t;)|p(?:;|fn;|le(?:ment;|xes;)))|n(?:g(?:;|dot;)|int;)|p(?:f;|rod;|y(?:;|sr;|)))|r(?:arr;|oss;)|s(?:cr;|u(?:b(?:;|e;)|p(?:;|e;)))|tdot;|u(?:darr(?:l;|r;)|e(?:pr;|sc;)|larr(?:;|p;)|p(?:;|brcap;|c(?:ap;|up;)|dot;|or;|s;)|r(?:arr(?:;|m;)|ly(?:eq(?:prec;|succ;)|vee;|wedge;)|ren;?|vearrow(?:left;|right;))|vee;|wed;)|w(?:conint;|int;)|ylcty;)|d(?:Arr;|Har;|a(?:gger;|leth;|rr;|sh(?:;|v;))|b(?:karow;|lac;)|c(?:aron;|y;)|d(?:;|a(?:gger;|rr;)|otseq;)|e(?:g;?|lta;|mptyv;)|f(?:isht;|r;)|har(?:l;|r;)|i(?:am(?:;|ond(?:;|suit;)|s;)|e;|gamma;|sin;|v(?:;|ide(?:;|ontimes;|)|onx;))|jcy;|lc(?:orn;|rop;)|o(?:llar;|pf;|t(?:;|eq(?:;|dot;)|minus;|plus;|square;)|ublebarwedge;|wn(?:arrow;|downarrows;|harpoon(?:left;|right;)))|r(?:bkarow;|c(?:orn;|rop;))|s(?:c(?:r;|y;)|ol;|trok;)|t(?:dot;|ri(?:;|f;))|u(?:arr;|har;)|wangle;|z(?:cy;|igrarr;))|e(?:D(?:Dot;|ot;)|a(?:cute;?|ster;)|c(?:aron;|ir(?:;|c;?)|olon;|y;)|dot;|e;|f(?:Dot;|r;)|g(?:;|rave;?|s(?:;|dot;))|l(?:;|inters;|l;|s(?:;|dot;))|m(?:acr;|pty(?:;|set;|v;)|sp(?:1(?:3;|4;)|;))|n(?:g;|sp;)|o(?:gon;|pf;)|p(?:ar(?:;|sl;)|lus;|si(?:;|lon;|v;))|q(?:c(?:irc;|olon;)|s(?:im;|lant(?:gtr;|less;))|u(?:als;|est;|iv(?:;|DD;))|vparsl;)|r(?:Dot;|arr;)|s(?:cr;|dot;|im;)|t(?:a;|h;?)|u(?:ml;?|ro;)|x(?:cl;|ist;|p(?:ectation;|onentiale;)))|f(?:allingdotseq;|cy;|emale;|f(?:ilig;|l(?:ig;|lig;)|r;)|ilig;|jlig;|l(?:at;|lig;|tns;)|nof;|o(?:pf;|r(?:all;|k(?:;|v;)))|partint;|r(?:a(?:c(?:1(?:2;?|3;|4;?|5;|6;|8;)|2(?:3;|5;)|3(?:4;?|5;|8;)|45;|5(?:6;|8;)|78;)|sl;)|own;)|scr;)|g(?:E(?:;|l;)|a(?:cute;|mma(?:;|d;)|p;)|breve;|c(?:irc;|y;)|dot;|e(?:;|l;|q(?:;|q;|slant;)|s(?:;|cc;|dot(?:;|o(?:;|l;))|l(?:;|es;)))|fr;|g(?:;|g;)|imel;|jcy;|l(?:;|E;|a;|j;)|n(?:E;|ap(?:;|prox;)|e(?:;|q(?:;|q;))|sim;)|opf;|rave;|s(?:cr;|im(?:;|e;|l;))|t(?:;|c(?:c;|ir;)|dot;|lPar;|quest;|r(?:a(?:pprox;|rr;)|dot;|eq(?:less;|qless;)|less;|sim;)|)|v(?:ertneqq;|nE;))|h(?:Arr;|a(?:irsp;|lf;|milt;|r(?:dcy;|r(?:;|cir;|w;)))|bar;|circ;|e(?:arts(?:;|uit;)|llip;|rcon;)|fr;|ks(?:earow;|warow;)|o(?:arr;|mtht;|ok(?:leftarrow;|rightarrow;)|pf;|rbar;)|s(?:cr;|lash;|trok;)|y(?:bull;|phen;))|i(?:acute;?|c(?:;|irc;?|y;)|e(?:cy;|xcl;?)|f(?:f;|r;)|grave;?|i(?:;|i(?:int;|nt;)|nfin;|ota;)|jlig;|m(?:a(?:cr;|g(?:e;|line;|part;)|th;)|of;|ped;)|n(?:;|care;|fin(?:;|tie;)|odot;|t(?:;|cal;|e(?:gers;|rcal;)|larhk;|prod;))|o(?:cy;|gon;|pf;|ta;)|prod;|quest;?|s(?:cr;|in(?:;|E;|dot;|s(?:;|v;)|v;))|t(?:;|ilde;)|u(?:kcy;|ml;?))|j(?:c(?:irc;|y;)|fr;|math;|opf;|s(?:cr;|ercy;)|ukcy;)|k(?:appa(?:;|v;)|c(?:edil;|y;)|fr;|green;|hcy;|jcy;|opf;|scr;)|l(?:A(?:arr;|rr;|tail;)|Barr;|E(?:;|g;)|Har;|a(?:cute;|emptyv;|gran;|mbda;|ng(?:;|d;|le;)|p;|quo;?|rr(?:;|b(?:;|fs;)|fs;|hk;|lp;|pl;|sim;|tl;)|t(?:;|ail;|e(?:;|s;)))|b(?:arr;|brk;|r(?:ac(?:e;|k;)|k(?:e;|sl(?:d;|u;))))|c(?:aron;|e(?:dil;|il;)|ub;|y;)|d(?:ca;|quo(?:;|r;)|r(?:dhar;|ushar;)|sh;)|e(?:;|ft(?:arrow(?:;|tail;)|harpoon(?:down;|up;)|leftarrows;|right(?:arrow(?:;|s;)|harpoons;|squigarrow;)|threetimes;)|g;|q(?:;|q;|slant;)|s(?:;|cc;|dot(?:;|o(?:;|r;))|g(?:;|es;)|s(?:approx;|dot;|eq(?:gtr;|qgtr;)|gtr;|sim;)))|f(?:isht;|loor;|r;)|g(?:;|E;)|h(?:ar(?:d;|u(?:;|l;))|blk;)|jcy;|l(?:;|arr;|corner;|hard;|tri;)|m(?:idot;|oust(?:;|ache;))|n(?:E;|ap(?:;|prox;)|e(?:;|q(?:;|q;))|sim;)|o(?:a(?:ng;|rr;)|brk;|ng(?:left(?:arrow;|rightarrow;)|mapsto;|rightarrow;)|oparrow(?:left;|right;)|p(?:ar;|f;|lus;)|times;|w(?:ast;|bar;)|z(?:;|enge;|f;))|par(?:;|lt;)|r(?:arr;|corner;|har(?:;|d;)|m;|tri;)|s(?:aquo;|cr;|h;|im(?:;|e;|g;)|q(?:b;|uo(?:;|r;))|trok;)|t(?:;|c(?:c;|ir;)|dot;|hree;|imes;|larr;|quest;|r(?:Par;|i(?:;|e;|f;))|)|ur(?:dshar;|uhar;)|v(?:ertneqq;|nE;))|m(?:DDot;|a(?:cr;?|l(?:e;|t(?:;|ese;))|p(?:;|sto(?:;|down;|left;|up;))|rker;)|c(?:omma;|y;)|dash;|easuredangle;|fr;|ho;|i(?:cro;?|d(?:;|ast;|cir;|dot;?)|nus(?:;|b;|d(?:;|u;)))|l(?:cp;|dr;)|nplus;|o(?:dels;|pf;)|p;|s(?:cr;|tpos;)|u(?:;|ltimap;|map;))|n(?:G(?:g;|t(?:;|v;))|L(?:eft(?:arrow;|rightarrow;)|l;|t(?:;|v;))|Rightarrow;|V(?:Dash;|dash;)|a(?:bla;|cute;|ng;|p(?:;|E;|id;|os;|prox;)|tur(?:;|al(?:;|s;)))|b(?:sp;?|ump(?:;|e;))|c(?:a(?:p;|ron;)|edil;|ong(?:;|dot;)|up;|y;)|dash;|e(?:;|Arr;|ar(?:hk;|r(?:;|ow;))|dot;|quiv;|s(?:ear;|im;)|xist(?:;|s;))|fr;|g(?:E;|e(?:;|q(?:;|q;|slant;)|s;)|sim;|t(?:;|r;))|h(?:Arr;|arr;|par;)|i(?:;|s(?:;|d;)|v;)|jcy;|l(?:Arr;|E;|arr;|dr;|e(?:;|ft(?:arrow;|rightarrow;)|q(?:;|q;|slant;)|s(?:;|s;))|sim;|t(?:;|ri(?:;|e;)))|mid;|o(?:pf;|t(?:;|in(?:;|E;|dot;|v(?:a;|b;|c;))|ni(?:;|v(?:a;|b;|c;))|))|p(?:ar(?:;|allel;|sl;|t;)|olint;|r(?:;|cue;|e(?:;|c(?:;|eq;))))|r(?:Arr;|arr(?:;|c;|w;)|ightarrow;|tri(?:;|e;))|s(?:c(?:;|cue;|e;|r;)|hort(?:mid;|parallel;)|im(?:;|e(?:;|q;))|mid;|par;|qsu(?:be;|pe;)|u(?:b(?:;|E;|e;|set(?:;|eq(?:;|q;)))|cc(?:;|eq;)|p(?:;|E;|e;|set(?:;|eq(?:;|q;)))))|t(?:gl;|ilde;?|lg;|riangle(?:left(?:;|eq;)|right(?:;|eq;)))|u(?:;|m(?:;|ero;|sp;))|v(?:Dash;|Harr;|ap;|dash;|g(?:e;|t;)|infin;|l(?:Arr;|e;|t(?:;|rie;))|r(?:Arr;|trie;)|sim;)|w(?:Arr;|ar(?:hk;|r(?:;|ow;))|near;))|o(?:S;|a(?:cute;?|st;)|c(?:ir(?:;|c;?)|y;)|d(?:ash;|blac;|iv;|ot;|sold;)|elig;|f(?:cir;|r;)|g(?:on;|rave;?|t;)|h(?:bar;|m;)|int;|l(?:arr;|c(?:ir;|ross;)|ine;|t;)|m(?:acr;|ega;|i(?:cron;|d;|nus;))|opf;|p(?:ar;|erp;|lus;)|r(?:;|arr;|d(?:;|er(?:;|of;)|f;?|m;?)|igof;|or;|slope;|v;)|s(?:cr;|lash;?|ol;)|ti(?:lde;?|mes(?:;|as;))|uml;?|vbar;)|p(?:ar(?:;|a(?:;|llel;|)|s(?:im;|l;)|t;)|cy;|er(?:cnt;|iod;|mil;|p;|tenk;)|fr;|h(?:i(?:;|v;)|mmat;|one;)|i(?:;|tchfork;|v;)|l(?:an(?:ck(?:;|h;)|kv;)|us(?:;|acir;|b;|cir;|d(?:o;|u;)|e;|mn;?|sim;|two;))|m;|o(?:intint;|pf;|und;?)|r(?:;|E;|ap;|cue;|e(?:;|c(?:;|approx;|curlyeq;|eq;|n(?:approx;|eqq;|sim;)|sim;))|ime(?:;|s;)|n(?:E;|ap;|sim;)|o(?:d;|f(?:alar;|line;|surf;)|p(?:;|to;))|sim;|urel;)|s(?:cr;|i;)|uncsp;)|q(?:fr;|int;|opf;|prime;|scr;|u(?:at(?:ernions;|int;)|est(?:;|eq;)|ot;?))|r(?:A(?:arr;|rr;|tail;)|Barr;|Har;|a(?:c(?:e;|ute;)|dic;|emptyv;|ng(?:;|d;|e;|le;)|quo;?|rr(?:;|ap;|b(?:;|fs;)|c;|fs;|hk;|lp;|pl;|sim;|tl;|w;)|t(?:ail;|io(?:;|nals;)))|b(?:arr;|brk;|r(?:ac(?:e;|k;)|k(?:e;|sl(?:d;|u;))))|c(?:aron;|e(?:dil;|il;)|ub;|y;)|d(?:ca;|ldhar;|quo(?:;|r;)|sh;)|e(?:al(?:;|ine;|part;|s;)|ct;|g;?)|f(?:isht;|loor;|r;)|h(?:ar(?:d;|u(?:;|l;))|o(?:;|v;))|i(?:ght(?:arrow(?:;|tail;)|harpoon(?:down;|up;)|left(?:arrows;|harpoons;)|rightarrows;|squigarrow;|threetimes;)|ng;|singdotseq;)|l(?:arr;|har;|m;)|moust(?:;|ache;)|nmid;|o(?:a(?:ng;|rr;)|brk;|p(?:ar;|f;|lus;)|times;)|p(?:ar(?:;|gt;)|polint;)|rarr;|s(?:aquo;|cr;|h;|q(?:b;|uo(?:;|r;)))|t(?:hree;|imes;|ri(?:;|e;|f;|ltri;))|uluhar;|x;)|s(?:acute;|bquo;|c(?:;|E;|a(?:p;|ron;)|cue;|e(?:;|dil;)|irc;|n(?:E;|ap;|sim;)|polint;|sim;|y;)|dot(?:;|b;|e;)|e(?:Arr;|ar(?:hk;|r(?:;|ow;))|ct;?|mi;|swar;|tm(?:inus;|n;)|xt;)|fr(?:;|own;)|h(?:arp;|c(?:hcy;|y;)|ort(?:mid;|parallel;)|y;?)|i(?:gma(?:;|f;|v;)|m(?:;|dot;|e(?:;|q;)|g(?:;|E;)|l(?:;|E;)|ne;|plus;|rarr;))|larr;|m(?:a(?:llsetminus;|shp;)|eparsl;|i(?:d;|le;)|t(?:;|e(?:;|s;)))|o(?:ftcy;|l(?:;|b(?:;|ar;))|pf;)|pa(?:des(?:;|uit;)|r;)|q(?:c(?:ap(?:;|s;)|up(?:;|s;))|su(?:b(?:;|e;|set(?:;|eq;))|p(?:;|e;|set(?:;|eq;)))|u(?:;|ar(?:e;|f;)|f;))|rarr;|s(?:cr;|etmn;|mile;|tarf;)|t(?:ar(?:;|f;)|r(?:aight(?:epsilon;|phi;)|ns;))|u(?:b(?:;|E;|dot;|e(?:;|dot;)|mult;|n(?:E;|e;)|plus;|rarr;|s(?:et(?:;|eq(?:;|q;)|neq(?:;|q;))|im;|u(?:b;|p;)))|cc(?:;|approx;|curlyeq;|eq;|n(?:approx;|eqq;|sim;)|sim;)|m;|ng;|p(?:1;?|2;?|3;?|;|E;|d(?:ot;|sub;)|e(?:;|dot;)|hs(?:ol;|ub;)|larr;|mult;|n(?:E;|e;)|plus;|s(?:et(?:;|eq(?:;|q;)|neq(?:;|q;))|im;|u(?:b;|p;))))|w(?:Arr;|ar(?:hk;|r(?:;|ow;))|nwar;)|zlig;?)|t(?:a(?:rget;|u;)|brk;|c(?:aron;|edil;|y;)|dot;|elrec;|fr;|h(?:e(?:re(?:4;|fore;)|ta(?:;|sym;|v;))|i(?:ck(?:approx;|sim;)|nsp;)|k(?:ap;|sim;)|orn;?)|i(?:lde;|mes(?:;|b(?:;|ar;)|d;|)|nt;)|o(?:ea;|p(?:;|bot;|cir;|f(?:;|ork;))|sa;)|prime;|r(?:ade;|i(?:angle(?:;|down;|left(?:;|eq;)|q;|right(?:;|eq;))|dot;|e;|minus;|plus;|sb;|time;)|pezium;)|s(?:c(?:r;|y;)|hcy;|trok;)|w(?:ixt;|ohead(?:leftarrow;|rightarrow;)))|u(?:Arr;|Har;|a(?:cute;?|rr;)|br(?:cy;|eve;)|c(?:irc;?|y;)|d(?:arr;|blac;|har;)|f(?:isht;|r;)|grave;?|h(?:ar(?:l;|r;)|blk;)|l(?:c(?:orn(?:;|er;)|rop;)|tri;)|m(?:acr;|l;?)|o(?:gon;|pf;)|p(?:arrow;|downarrow;|harpoon(?:left;|right;)|lus;|si(?:;|h;|lon;)|uparrows;)|r(?:c(?:orn(?:;|er;)|rop;)|ing;|tri;)|scr;|t(?:dot;|ilde;|ri(?:;|f;))|u(?:arr;|ml;?)|wangle;)|v(?:Arr;|Bar(?:;|v;)|Dash;|a(?:ngrt;|r(?:epsilon;|kappa;|nothing;|p(?:hi;|i;|ropto;)|r(?:;|ho;)|s(?:igma;|u(?:bsetneq(?:;|q;)|psetneq(?:;|q;)))|t(?:heta;|riangle(?:left;|right;))))|cy;|dash;|e(?:e(?:;|bar;|eq;)|llip;|r(?:bar;|t;))|fr;|ltri;|nsu(?:b;|p;)|opf;|prop;|rtri;|s(?:cr;|u(?:bn(?:E;|e;)|pn(?:E;|e;)))|zigzag;)|w(?:circ;|e(?:d(?:bar;|ge(?:;|q;))|ierp;)|fr;|opf;|p;|r(?:;|eath;)|scr;)|x(?:c(?:ap;|irc;|up;)|dtri;|fr;|h(?:Arr;|arr;)|i;|l(?:Arr;|arr;)|map;|nis;|o(?:dot;|p(?:f;|lus;)|time;)|r(?:Arr;|arr;)|s(?:cr;|qcup;)|u(?:plus;|tri;)|vee;|wedge;)|y(?:ac(?:ute;?|y;)|c(?:irc;|y;)|en;?|fr;|icy;|opf;|scr;|u(?:cy;|ml;?))|z(?:acute;|c(?:aron;|y;)|dot;|e(?:etrf;|ta;)|fr;|hcy;|igrarr;|opf;|scr;|w(?:j;|nj;)))|[\s\S]/g,uP=32,dP=/[^\r"&\u0000]+/g,pP=/[^\r'&\u0000]+/g,cP=/[^\r\t\n\f &>\u0000]+/g,lP=/[^\r\t\n\f \/>A-Z\u0000]+/g,oP=/[^\r\t\n\f \/=>A-Z\u0000]+/g,rP=/[^\]\r\u0000\uffff]*/g,iP=/[^&<\r\u0000\uffff]*/g,Rj=/[^<\r\u0000\uffff]*/g,sP=/[^\r\u0000\uffff]*/g,Lj=/(?:(\/)?([a-z]+)>)|[\s\S]/g,Nj=/(?:([-a-z]+)[ \t\n\f]*=[ \t\n\f]*('[^'&\r\u0000]*'|"[^"&\r\u0000]*"|[^\t\n\r\f "&'\u0000>][^&> \t\n\r\f\u0000]*[ \t\n\f]))|[\s\S]/g,V6=/[^\x09\x0A\x0C\x0D\x20]/,Z3=/[^\x09\x0A\x0C\x0D\x20]/g,nP=/[^\x00\x09\x0A\x0C\x0D\x20]/,e2=/^[\x09\x0A\x0C\x0D\x20]+/,G6=/\x00/g;function N0($){var J=16384;if($.length<J)return String.fromCharCode.apply(String,$);var Z="";for(var Y=0;Y<$.length;Y+=J)Z+=String.fromCharCode.apply(String,$.slice(Y,Y+J));return Z}function aP($){var J=[];for(var Z=0;Z<$.length;Z++)J[Z]=$.charCodeAt(Z);return J}function d$($,J){if(typeof J==="string")return $.namespaceURI===X$.HTML&&$.localName===J;var Z=J[$.namespaceURI];return Z&&Z[$.localName]}function yj($){return d$($,uj)}function Tj($){if(d$($,dj))return!0;if($.namespaceURI===X$.MATHML&&$.localName==="annotation-xml"){var J=$.getAttribute("encoding");if(J)J=J.toLowerCase();if(J==="text/html"||J==="application/xhtml+xml")return!0}return!1}function tP($){if($ in Aj)return Aj[$];else return $}function kj($){for(var J=0,Z=$.length;J<Z;J++)if($[J][0]in Ij)$[J][0]=Ij[$[J][0]]}function Ej($){for(var J=0,Z=$.length;J<Z;J++)if($[J][0]==="definitionurl"){$[J][0]="definitionURL";break}}function Y3($){for(var J=0,Z=$.length;J<Z;J++)if($[J][0]in Pj)$[J].push(Pj[$[J][0]])}function xj($,J){for(var Z=0,Y=$.length;Z<Y;Z++){var K=$[Z][0],Q=$[Z][1];if(J.hasAttribute(K))continue;J._setAttribute(K,Q)}}b$.ElementStack=function(){this.elements=[],this.top=null};b$.ElementStack.prototype.push=function($){this.elements.push($),this.top=$};b$.ElementStack.prototype.pop=function($){this.elements.pop(),this.top=this.elements[this.elements.length-1]};b$.ElementStack.prototype.popTag=function($){for(var J=this.elements.length-1;J>0;J--){var Z=this.elements[J];if(d$(Z,$))break}this.elements.length=J,this.top=this.elements[J-1]};b$.ElementStack.prototype.popElementType=function($){for(var J=this.elements.length-1;J>0;J--)if(this.elements[J]instanceof $)break;this.elements.length=J,this.top=this.elements[J-1]};b$.ElementStack.prototype.popElement=function($){for(var J=this.elements.length-1;J>0;J--)if(this.elements[J]===$)break;this.elements.length=J,this.top=this.elements[J-1]};b$.ElementStack.prototype.removeElement=function($){if(this.top===$)this.pop();else{var J=this.elements.lastIndexOf($);if(J!==-1)this.elements.splice(J,1)}};b$.ElementStack.prototype.clearToContext=function($){for(var J=this.elements.length-1;J>0;J--)if(d$(this.elements[J],$))break;this.elements.length=J+1,this.top=this.elements[J]};b$.ElementStack.prototype.contains=function($){return this.inSpecificScope($,Object.create(null))};b$.ElementStack.prototype.inSpecificScope=function($,J){for(var Z=this.elements.length-1;Z>=0;Z--){var Y=this.elements[Z];if(d$(Y,$))return!0;if(d$(Y,J))return!1}return!1};b$.ElementStack.prototype.elementInSpecificScope=function($,J){for(var Z=this.elements.length-1;Z>=0;Z--){var Y=this.elements[Z];if(Y===$)return!0;if(d$(Y,J))return!1}return!1};b$.ElementStack.prototype.elementTypeInSpecificScope=function($,J){for(var Z=this.elements.length-1;Z>=0;Z--){var Y=this.elements[Z];if(Y instanceof $)return!0;if(d$(Y,J))return!1}return!1};b$.ElementStack.prototype.inScope=function($){return this.inSpecificScope($,T1)};b$.ElementStack.prototype.elementInScope=function($){return this.elementInSpecificScope($,T1)};b$.ElementStack.prototype.elementTypeInScope=function($){return this.elementTypeInSpecificScope($,T1)};b$.ElementStack.prototype.inButtonScope=function($){return this.inSpecificScope($,V3)};b$.ElementStack.prototype.inListItemScope=function($){return this.inSpecificScope($,j6)};b$.ElementStack.prototype.inTableScope=function($){return this.inSpecificScope($,mj)};b$.ElementStack.prototype.inSelectScope=function($){for(var J=this.elements.length-1;J>=0;J--){var Z=this.elements[J];if(Z.namespaceURI!==X$.HTML)return!1;var Y=Z.localName;if(Y===$)return!0;if(Y!=="optgroup"&&Y!=="option")return!1}return!1};b$.ElementStack.prototype.generateImpliedEndTags=function($,J){var Z=J?gj:hj;for(var Y=this.elements.length-1;Y>=0;Y--){var K=this.elements[Y];if($&&d$(K,$))break;if(!d$(this.elements[Y],Z))break}this.elements.length=Y+1,this.top=this.elements[Y]};b$.ActiveFormattingElements=function(){this.list=[],this.attrs=[]};b$.ActiveFormattingElements.prototype.MARKER={localName:"|"};b$.ActiveFormattingElements.prototype.insertMarker=function(){this.list.push(this.MARKER),this.attrs.push(this.MARKER)};b$.ActiveFormattingElements.prototype.push=function($,J){var Z=0;for(var Y=this.list.length-1;Y>=0;Y--){if(this.list[Y]===this.MARKER)break;if(V($,this.list[Y],this.attrs[Y])){if(Z++,Z===3){this.list.splice(Y,1),this.attrs.splice(Y,1);break}}}this.list.push($);var K=[];for(var Q=0;Q<J.length;Q++)K[Q]=J[Q];this.attrs.push(K);function V(X,W,_){if(X.localName!==W.localName)return!1;if(X._numattrs!==_.length)return!1;for(var j=0,H=_.length;j<H;j++){var q=_[j][0],U=_[j][1];if(!X.hasAttribute(q))return!1;if(X.getAttribute(q)!==U)return!1}return!0}};b$.ActiveFormattingElements.prototype.clearToMarker=function(){for(var $=this.list.length-1;$>=0;$--)if(this.list[$]===this.MARKER)break;if($<0)$=0;this.list.length=$,this.attrs.length=$};b$.ActiveFormattingElements.prototype.findElementByTag=function($){for(var J=this.list.length-1;J>=0;J--){var Z=this.list[J];if(Z===this.MARKER)break;if(Z.localName===$)return Z}return null};b$.ActiveFormattingElements.prototype.indexOf=function($){return this.list.lastIndexOf($)};b$.ActiveFormattingElements.prototype.remove=function($){var J=this.list.lastIndexOf($);if(J!==-1)this.list.splice(J,1),this.attrs.splice(J,1)};b$.ActiveFormattingElements.prototype.replace=function($,J,Z){var Y=this.list.lastIndexOf($);if(Y!==-1)this.list[Y]=J,this.attrs[Y]=Z};b$.ActiveFormattingElements.prototype.insertAfter=function($,J){var Z=this.list.lastIndexOf($);if(Z!==-1)this.list.splice(Z,0,J),this.attrs.splice(Z,0,J)};function b$($,J,Z){var Y=null,K=0,Q=0,V=!1,X=!1,W=0,_=[],j="",H=!0,q=0,U=S$,z,M,I="",C="",P=[],D="",L="",R=[],N=[],x=[],b=[],v=[],m=!1,A=fH,u=null,r=[],S=new b$.ElementStack,T=new b$.ActiveFormattingElements,k=J!==void 0,A$=null,s=null,J$=!0;if(J)J$=J.ownerDocument._scripting_enabled;if(Z&&Z.scripting_enabled===!1)J$=!1;var Z$=!0,W$=!1,y$,Q$,y=[],n=!1,a=!1,c$={document:function(){return l},_asDocumentFragment:function(){var B=l.createDocumentFragment(),O=l.firstChild;while(O.hasChildNodes())B.appendChild(O.firstChild);return B},pause:function(){q++},resume:function(){q--,this.parse("")},parse:function(B,O,w){var E;if(q>0)return j+=B,!0;if(W===0){if(j)B=j+B,j="";if(O)B+="\uFFFF",V=!0;if(Y=B,K=B.length,Q=0,H){if(H=!1,Y.charCodeAt(0)===65279)Q=1}W++,E=g(w),j=Y.substring(Q,K),W--}else{if(W++,_.push(Y,K,Q),Y=B,K=B.length,Q=0,g(),E=!1,j=Y.substring(Q,K),Q=_.pop(),K=_.pop(),Y=_.pop(),j)Y=j+Y.substring(Q),K=Y.length,Q=0,j="";W--}return E}},l=new kP(!0,$);if(l._parser=c$,l._scripting_enabled=J$,J){if(J.ownerDocument._quirks)l._quirks=!0;if(J.ownerDocument._limitedQuirks)l._limitedQuirks=!0;if(J.namespaceURI===X$.HTML)switch(J.localName){case"title":case"textarea":U=J2;break;case"style":case"xmp":case"iframe":case"noembed":case"noframes":case"script":case"plaintext":U=L6;break}var d=l.createElement("html");if(l._appendChild(d),S.push(d),J instanceof u$.HTMLTemplateElement)r.push(g6);nJ();for(var Y$=J;Y$!==null;Y$=Y$.parentElement)if(Y$ instanceof u$.HTMLFormElement){s=Y$;break}}function g(B){var O,w,E,h;while(Q<K){if(q>0||B&&B())return!0;switch(typeof U.lookahead){case"undefined":if(O=Y.charCodeAt(Q++),X){if(X=!1,O===10){Q++;continue}}switch(O){case 13:if(Q<K){if(Y.charCodeAt(Q)===10)Q++}else X=!0;U(10);break;case 65535:if(V&&Q===K){U(Q6);break}default:U(O);break}break;case"number":O=Y.charCodeAt(Q);var c=U.lookahead,U$=!0;if(c<0)U$=!1,c=-c;if(c<K-Q)w=U$?Y.substring(Q,Q+c):null,h=!1;else if(V){if(w=U$?Y.substring(Q,K):null,h=!0,O===65535&&Q===K-1)O=Q6}else return!0;U(O,w,h);break;case"string":O=Y.charCodeAt(Q),E=U.lookahead;var w$=Y.indexOf(E,Q);if(w$!==-1)w=Y.substring(Q,w$+E.length),h=!1;else{if(!V)return!0;if(w=Y.substring(Q,K),O===65535&&Q===K-1)O=Q6;h=!0}U(O,w,h);break}}return!1}function t(B,O){for(var w=0;w<v.length;w++)if(v[w][0]===B)return;if(O!==void 0)v.push([B,O]);else v.push([B])}function C$(){Nj.lastIndex=Q-1;var B=Nj.exec(Y);if(!B)throw Error("should never happen");var O=B[1];if(!O)return!1;var w=B[2],E=w.length;switch(w[0]){case'"':case"'":w=w.substring(1,E-1),Q+=B[0].length-1,U=k6;break;default:U=A1,Q+=B[0].length-1,w=w.substring(0,E-1);break}for(var h=0;h<v.length;h++)if(v[h][0]===O)return!0;return v.push([O,w]),!0}function T$(){m=!1,I="",v.length=0}function M$(){m=!0,I="",v.length=0}function r$(){P.length=0}function K0(){D=""}function t1(){L=""}function a8(){R.length=0}function e1(){N.length=0,x=null,b=null}function C1(){x=[]}function M1(){b=[]}function h$(){W$=!0}function lB(){return S.top&&S.top.namespaceURI!=="http://www.w3.org/1999/xhtml"}function r0(B){return C===B}function VJ(){if(y.length>0){var B=N0(y);if(y.length=0,a){if(a=!1,B[0]===`
|
|
33
|
+
`)B=B.substring(1);if(B.length===0)return}j0(cJ,B),n=!1}a=!1}function rJ(B){B.lastIndex=Q-1;var O=B.exec(Y);if(O&&O.index===Q-1){if(O=O[0],Q+=O.length-1,V&&Q===K)O=O.slice(0,-1),Q--;return O}else throw Error("should never happen")}function iJ(B){B.lastIndex=Q-1;var O=B.exec(Y)[0];if(!O)return!1;return oB(O),Q+=O.length-1,!0}function oB(B){if(y.length>0)VJ();if(a){if(a=!1,B[0]===`
|
|
34
|
+
`)B=B.substring(1);if(B.length===0)return}j0(cJ,B)}function k1(){if(m)j0(N$,I);else{var B=I;I="",C=B,j0(L0,B,v)}}function rB(){if(Q===K)return!1;Lj.lastIndex=Q;var B=Lj.exec(Y);if(!B)throw Error("should never happen");var O=B[2];if(!O)return!1;var w=B[1];if(w)Q+=O.length+2,j0(N$,O);else Q+=O.length+1,C=O,j0(L0,O,bP);return!0}function iB(){if(m)j0(N$,I,null,!0);else j0(L0,I,v,!0)}function g$(){j0(xP,N0(N),x?N0(x):void 0,b?N0(b):void 0)}function I$(){VJ(),A(Q6),l.modclock=1}var j0=c$.insertToken=function(O,w,E,h){VJ();var c=S.top;if(!c||c.namespaceURI===X$.HTML)A(O,w,E,h);else if(O!==L0&&O!==cJ)ZK(O,w,E,h);else if(yj(c)&&(O===cJ||O===L0&&w!=="mglyph"&&w!=="malignmark")||O===L0&&w==="svg"&&c.namespaceURI===X$.MATHML&&c.localName==="annotation-xml"||Tj(c))Q$=!0,A(O,w,E,h),Q$=!1;else ZK(O,w,E,h)};function D1(B){var O=S.top;if($2&&d$(O,lJ))e8(function(w){return w.createComment(B)});else{if(O instanceof u$.HTMLTemplateElement)O=O.content;O._appendChild(O.ownerDocument.createComment(B))}}function P1(B){var O=S.top;if($2&&d$(O,lJ))e8(function(E){return E.createTextNode(B)});else{if(O instanceof u$.HTMLTemplateElement)O=O.content;var w=O.lastChild;if(w&&w.nodeType===J3.TEXT_NODE)w.appendData(B);else O._appendChild(O.ownerDocument.createTextNode(B))}}function sJ(B,O,w){var E=bj.createElement(B,O,null);if(w)for(var h=0,c=w.length;h<c;h++)E._setAttribute(w[h][0],w[h][1]);return E}var $2=!1;function q$(B,O){var w=t8(function(E){return sJ(E,B,O)});if(d$(w,fj))w._form=s;return w}function t8(B){var O;if($2&&d$(S.top,lJ))O=e8(B);else if(S.top instanceof u$.HTMLTemplateElement)O=B(S.top.content.ownerDocument),S.top.content._appendChild(O);else O=B(S.top.ownerDocument),S.top._appendChild(O);return S.push(O),O}function w6(B,O,w){return t8(function(E){var h=E._createElementNS(B,w,null);if(O)for(var c=0,U$=O.length;c<U$;c++){var w$=O[c];if(w$.length===2)h._setAttribute(w$[0],w$[1]);else h._setAttributeNS(w$[2],w$[0],w$[1])}return h})}function u3(B){for(var O=S.elements.length-1;O>=0;O--)if(S.elements[O]instanceof B)return O;return-1}function e8(B){var O,w,E=-1,h=-1,c;if(E=u3(u$.HTMLTableElement),h=u3(u$.HTMLTemplateElement),h>=0&&(E<0||h>E))O=S.elements[h];else if(E>=0)if(O=S.elements[E].parentNode,O)w=S.elements[E];else O=S.elements[E-1];if(!O)O=S.elements[0];if(O instanceof u$.HTMLTemplateElement)O=O.content;if(c=B(O.ownerDocument),c.nodeType===J3.TEXT_NODE){var U$;if(w)U$=w.previousSibling;else U$=O.lastChild;if(U$&&U$.nodeType===J3.TEXT_NODE)return U$.appendData(c.data),c}if(w)O.insertBefore(c,w);else O._appendChild(c);return c}function nJ(){var B=!1;for(var O=S.elements.length-1;O>=0;O--){var w=S.elements[O];if(O===0){if(B=!0,k)w=J}if(w.namespaceURI===X$.HTML){var E=w.localName;switch(E){case"select":for(var h=O;h>0;){var c=S.elements[--h];if(c instanceof u$.HTMLTemplateElement)break;else if(c instanceof u$.HTMLTableElement){A=H9;return}}A=E1;return;case"tr":A=eJ;return;case"tbody":case"tfoot":case"thead":A=I2;return;case"caption":A=h6;return;case"colgroup":A=B9;return;case"table":A=i0;return;case"template":A=r[r.length-1];return;case"body":A=j$;return;case"frameset":A=f6;return;case"html":if(A$===null)A=j9;else A=v6;return;default:if(!B){if(E==="head"){A=Q0;return}if(E==="td"||E==="th"){A=GJ;return}}}}if(B){A=j$;return}}}function $9(B,O){q$(B,O),U=aJ,u=A,A=U9}function sB(B,O){q$(B,O),U=J2,u=A,A=U9}function R6(B,O){return{elt:sJ(B,T.list[O].localName,T.attrs[O]),attrs:T.attrs[O]}}function T0(){if(T.list.length===0)return;var B=T.list[T.list.length-1];if(B===T.MARKER)return;if(S.elements.lastIndexOf(B)!==-1)return;for(var O=T.list.length-2;O>=0;O--){if(B=T.list[O],B===T.MARKER)break;if(S.elements.lastIndexOf(B)!==-1)break}for(O=O+1;O<T.list.length;O++){var w=t8(function(E){return R6(E,O).elt});T.list[O]=w}}var J9={localName:"BM"};function nB(B){if(d$(S.top,B)&&T.indexOf(S.top)===-1)return S.pop(),!0;var O=0;while(O<8){O++;var w=T.findElementByTag(B);if(!w)return!1;var E=S.elements.lastIndexOf(w);if(E===-1)return T.remove(w),!0;if(!S.elementInScope(w))return!0;var h=null,c;for(var U$=E+1;U$<S.elements.length;U$++)if(d$(S.elements[U$],$J)){h=S.elements[U$],c=U$;break}if(!h)return S.popElement(w),T.remove(w),!0;else{var w$=S.elements[E-1];T.insertAfter(w,J9);var J0=h,M0=h,s0=c,X1,A2=0;while(!0){if(A2++,J0=S.elements[--s0],J0===w)break;if(X1=T.indexOf(J0),A2>3&&X1!==-1)T.remove(J0),X1=-1;if(X1===-1){S.removeElement(J0);continue}var V2=R6(w$.ownerDocument,X1);if(T.replace(J0,V2.elt,V2.attrs),S.elements[s0]=V2.elt,J0=V2.elt,M0===h)T.remove(J9),T.insertAfter(V2.elt,J9);J0._appendChild(M0),M0=J0}if($2&&d$(w$,lJ))e8(function(){return M0});else if(w$ instanceof u$.HTMLTemplateElement)w$.content._appendChild(M0);else w$._appendChild(M0);var $8=R6(h.ownerDocument,T.indexOf(w));while(h.hasChildNodes())$8.elt._appendChild(h.firstChild);h._appendChild($8.elt),T.remove(w),T.replace(J9,$8.elt,$8.attrs),S.removeElement(w);var cH=S.elements.lastIndexOf(h);S.elements.splice(cH+1,0,$8.elt)}}return!0}function aB(){S.pop(),A=u;return}function M2(){if(delete l._parser,S.elements.length=0,l.defaultView)l.defaultView.dispatchEvent(new u$.Event("load",{}))}function V$(B,O){U=O,Q--}function S$(B){switch(B){case 38:z=S$,U=tJ;break;case 60:if(rB())break;U=tB;break;case 0:y.push(B),n=!0;break;case-1:I$();break;default:iJ(iP)||y.push(B);break}}function J2(B){switch(B){case 38:z=J2,U=tJ;break;case 60:U=$H;break;case 0:y.push(65533),n=!0;break;case-1:I$();break;default:y.push(B);break}}function aJ(B){switch(B){case 60:U=YH;break;case 0:y.push(65533);break;case-1:I$();break;default:iJ(Rj)||y.push(B);break}}function Z2(B){switch(B){case 60:U=VH;break;case 0:y.push(65533);break;case-1:I$();break;default:iJ(Rj)||y.push(B);break}}function L6(B){switch(B){case 0:y.push(65533);break;case-1:I$();break;default:iJ(sP)||y.push(B);break}}function tB(B){switch(B){case 33:U=l3;break;case 47:U=eB;break;case 65:case 66:case 67:case 68:case 69:case 70:case 71:case 72:case 73:case 74:case 75:case 76:case 77:case 78:case 79:case 80:case 81:case 82:case 83:case 84:case 85:case 86:case 87:case 88:case 89:case 90:case 97:case 98:case 99:case 100:case 101:case 102:case 103:case 104:case 105:case 106:case 107:case 108:case 109:case 110:case 111:case 112:case 113:case 114:case 115:case 116:case 117:case 118:case 119:case 120:case 121:case 122:T$(),V$(B,d3);break;case 63:V$(B,Q9);break;default:y.push(60),V$(B,S$);break}}function eB(B){switch(B){case 65:case 66:case 67:case 68:case 69:case 70:case 71:case 72:case 73:case 74:case 75:case 76:case 77:case 78:case 79:case 80:case 81:case 82:case 83:case 84:case 85:case 86:case 87:case 88:case 89:case 90:case 97:case 98:case 99:case 100:case 101:case 102:case 103:case 104:case 105:case 106:case 107:case 108:case 109:case 110:case 111:case 112:case 113:case 114:case 115:case 116:case 117:case 118:case 119:case 120:case 121:case 122:M$(),V$(B,d3);break;case 62:U=S$;break;case-1:y.push(60),y.push(47),I$();break;default:V$(B,Q9);break}}function d3(B){switch(B){case 9:case 10:case 12:case 32:U=A1;break;case 47:U=K2;break;case 62:U=S$,k1();break;case 65:case 66:case 67:case 68:case 69:case 70:case 71:case 72:case 73:case 74:case 75:case 76:case 77:case 78:case 79:case 80:case 81:case 82:case 83:case 84:case 85:case 86:case 87:case 88:case 89:case 90:I+=String.fromCharCode(B+32);break;case 0:I+=String.fromCharCode(65533);break;case-1:I$();break;default:I+=rJ(lP);break}}function $H(B){if(B===47)r$(),U=JH;else y.push(60),V$(B,J2)}function JH(B){switch(B){case 65:case 66:case 67:case 68:case 69:case 70:case 71:case 72:case 73:case 74:case 75:case 76:case 77:case 78:case 79:case 80:case 81:case 82:case 83:case 84:case 85:case 86:case 87:case 88:case 89:case 90:case 97:case 98:case 99:case 100:case 101:case 102:case 103:case 104:case 105:case 106:case 107:case 108:case 109:case 110:case 111:case 112:case 113:case 114:case 115:case 116:case 117:case 118:case 119:case 120:case 121:case 122:M$(),V$(B,ZH);break;default:y.push(60),y.push(47),V$(B,J2);break}}function ZH(B){switch(B){case 9:case 10:case 12:case 32:if(r0(I)){U=A1;return}break;case 47:if(r0(I)){U=K2;return}break;case 62:if(r0(I)){U=S$,k1();return}break;case 65:case 66:case 67:case 68:case 69:case 70:case 71:case 72:case 73:case 74:case 75:case 76:case 77:case 78:case 79:case 80:case 81:case 82:case 83:case 84:case 85:case 86:case 87:case 88:case 89:case 90:I+=String.fromCharCode(B+32),P.push(B);return;case 97:case 98:case 99:case 100:case 101:case 102:case 103:case 104:case 105:case 106:case 107:case 108:case 109:case 110:case 111:case 112:case 113:case 114:case 115:case 116:case 117:case 118:case 119:case 120:case 121:case 122:I+=String.fromCharCode(B),P.push(B);return;default:break}y.push(60),y.push(47),t2(y,P),V$(B,J2)}function YH(B){if(B===47)r$(),U=KH;else y.push(60),V$(B,aJ)}function KH(B){switch(B){case 65:case 66:case 67:case 68:case 69:case 70:case 71:case 72:case 73:case 74:case 75:case 76:case 77:case 78:case 79:case 80:case 81:case 82:case 83:case 84:case 85:case 86:case 87:case 88:case 89:case 90:case 97:case 98:case 99:case 100:case 101:case 102:case 103:case 104:case 105:case 106:case 107:case 108:case 109:case 110:case 111:case 112:case 113:case 114:case 115:case 116:case 117:case 118:case 119:case 120:case 121:case 122:M$(),V$(B,QH);break;default:y.push(60),y.push(47),V$(B,aJ);break}}function QH(B){switch(B){case 9:case 10:case 12:case 32:if(r0(I)){U=A1;return}break;case 47:if(r0(I)){U=K2;return}break;case 62:if(r0(I)){U=S$,k1();return}break;case 65:case 66:case 67:case 68:case 69:case 70:case 71:case 72:case 73:case 74:case 75:case 76:case 77:case 78:case 79:case 80:case 81:case 82:case 83:case 84:case 85:case 86:case 87:case 88:case 89:case 90:I+=String.fromCharCode(B+32),P.push(B);return;case 97:case 98:case 99:case 100:case 101:case 102:case 103:case 104:case 105:case 106:case 107:case 108:case 109:case 110:case 111:case 112:case 113:case 114:case 115:case 116:case 117:case 118:case 119:case 120:case 121:case 122:I+=String.fromCharCode(B),P.push(B);return;default:break}y.push(60),y.push(47),t2(y,P),V$(B,aJ)}function VH(B){switch(B){case 47:r$(),U=GH;break;case 33:U=WH,y.push(60),y.push(33);break;default:y.push(60),V$(B,Z2);break}}function GH(B){switch(B){case 65:case 66:case 67:case 68:case 69:case 70:case 71:case 72:case 73:case 74:case 75:case 76:case 77:case 78:case 79:case 80:case 81:case 82:case 83:case 84:case 85:case 86:case 87:case 88:case 89:case 90:case 97:case 98:case 99:case 100:case 101:case 102:case 103:case 104:case 105:case 106:case 107:case 108:case 109:case 110:case 111:case 112:case 113:case 114:case 115:case 116:case 117:case 118:case 119:case 120:case 121:case 122:M$(),V$(B,XH);break;default:y.push(60),y.push(47),V$(B,Z2);break}}function XH(B){switch(B){case 9:case 10:case 12:case 32:if(r0(I)){U=A1;return}break;case 47:if(r0(I)){U=K2;return}break;case 62:if(r0(I)){U=S$,k1();return}break;case 65:case 66:case 67:case 68:case 69:case 70:case 71:case 72:case 73:case 74:case 75:case 76:case 77:case 78:case 79:case 80:case 81:case 82:case 83:case 84:case 85:case 86:case 87:case 88:case 89:case 90:I+=String.fromCharCode(B+32),P.push(B);return;case 97:case 98:case 99:case 100:case 101:case 102:case 103:case 104:case 105:case 106:case 107:case 108:case 109:case 110:case 111:case 112:case 113:case 114:case 115:case 116:case 117:case 118:case 119:case 120:case 121:case 122:I+=String.fromCharCode(B),P.push(B);return;default:break}y.push(60),y.push(47),t2(y,P),V$(B,Z2)}function WH(B){if(B===45)U=jH,y.push(45);else V$(B,Z2)}function jH(B){if(B===45)U=p3,y.push(45);else V$(B,Z2)}function I1(B){switch(B){case 45:U=UH,y.push(45);break;case 60:U=N6;break;case 0:y.push(65533);break;case-1:I$();break;default:y.push(B);break}}function UH(B){switch(B){case 45:U=p3,y.push(45);break;case 60:U=N6;break;case 0:U=I1,y.push(65533);break;case-1:I$();break;default:U=I1,y.push(B);break}}function p3(B){switch(B){case 45:y.push(45);break;case 60:U=N6;break;case 62:U=Z2,y.push(62);break;case 0:U=I1,y.push(65533);break;case-1:I$();break;default:U=I1,y.push(B);break}}function N6(B){switch(B){case 47:r$(),U=BH;break;case 65:case 66:case 67:case 68:case 69:case 70:case 71:case 72:case 73:case 74:case 75:case 76:case 77:case 78:case 79:case 80:case 81:case 82:case 83:case 84:case 85:case 86:case 87:case 88:case 89:case 90:case 97:case 98:case 99:case 100:case 101:case 102:case 103:case 104:case 105:case 106:case 107:case 108:case 109:case 110:case 111:case 112:case 113:case 114:case 115:case 116:case 117:case 118:case 119:case 120:case 121:case 122:r$(),y.push(60),V$(B,_H);break;default:y.push(60),V$(B,I1);break}}function BH(B){switch(B){case 65:case 66:case 67:case 68:case 69:case 70:case 71:case 72:case 73:case 74:case 75:case 76:case 77:case 78:case 79:case 80:case 81:case 82:case 83:case 84:case 85:case 86:case 87:case 88:case 89:case 90:case 97:case 98:case 99:case 100:case 101:case 102:case 103:case 104:case 105:case 106:case 107:case 108:case 109:case 110:case 111:case 112:case 113:case 114:case 115:case 116:case 117:case 118:case 119:case 120:case 121:case 122:M$(),V$(B,HH);break;default:y.push(60),y.push(47),V$(B,I1);break}}function HH(B){switch(B){case 9:case 10:case 12:case 32:if(r0(I)){U=A1;return}break;case 47:if(r0(I)){U=K2;return}break;case 62:if(r0(I)){U=S$,k1();return}break;case 65:case 66:case 67:case 68:case 69:case 70:case 71:case 72:case 73:case 74:case 75:case 76:case 77:case 78:case 79:case 80:case 81:case 82:case 83:case 84:case 85:case 86:case 87:case 88:case 89:case 90:I+=String.fromCharCode(B+32),P.push(B);return;case 97:case 98:case 99:case 100:case 101:case 102:case 103:case 104:case 105:case 106:case 107:case 108:case 109:case 110:case 111:case 112:case 113:case 114:case 115:case 116:case 117:case 118:case 119:case 120:case 121:case 122:I+=String.fromCharCode(B),P.push(B);return;default:break}y.push(60),y.push(47),t2(y,P),V$(B,I1)}function _H(B){switch(B){case 9:case 10:case 12:case 32:case 47:case 62:if(N0(P)==="script")U=Y2;else U=I1;y.push(B);break;case 65:case 66:case 67:case 68:case 69:case 70:case 71:case 72:case 73:case 74:case 75:case 76:case 77:case 78:case 79:case 80:case 81:case 82:case 83:case 84:case 85:case 86:case 87:case 88:case 89:case 90:P.push(B+32),y.push(B);break;case 97:case 98:case 99:case 100:case 101:case 102:case 103:case 104:case 105:case 106:case 107:case 108:case 109:case 110:case 111:case 112:case 113:case 114:case 115:case 116:case 117:case 118:case 119:case 120:case 121:case 122:P.push(B),y.push(B);break;default:V$(B,I1);break}}function Y2(B){switch(B){case 45:U=OH,y.push(45);break;case 60:U=y6,y.push(60);break;case 0:y.push(65533);break;case-1:I$();break;default:y.push(B);break}}function OH(B){switch(B){case 45:U=qH,y.push(45);break;case 60:U=y6,y.push(60);break;case 0:U=Y2,y.push(65533);break;case-1:I$();break;default:U=Y2,y.push(B);break}}function qH(B){switch(B){case 45:y.push(45);break;case 60:U=y6,y.push(60);break;case 62:U=Z2,y.push(62);break;case 0:U=Y2,y.push(65533);break;case-1:I$();break;default:U=Y2,y.push(B);break}}function y6(B){if(B===47)r$(),U=FH,y.push(47);else V$(B,Y2)}function FH(B){switch(B){case 9:case 10:case 12:case 32:case 47:case 62:if(N0(P)==="script")U=I1;else U=Y2;y.push(B);break;case 65:case 66:case 67:case 68:case 69:case 70:case 71:case 72:case 73:case 74:case 75:case 76:case 77:case 78:case 79:case 80:case 81:case 82:case 83:case 84:case 85:case 86:case 87:case 88:case 89:case 90:P.push(B+32),y.push(B);break;case 97:case 98:case 99:case 100:case 101:case 102:case 103:case 104:case 105:case 106:case 107:case 108:case 109:case 110:case 111:case 112:case 113:case 114:case 115:case 116:case 117:case 118:case 119:case 120:case 121:case 122:P.push(B),y.push(B);break;default:V$(B,Y2);break}}function A1(B){switch(B){case 9:case 10:case 12:case 32:break;case 47:U=K2;break;case 62:U=S$,k1();break;case-1:I$();break;case 61:K0(),D+=String.fromCharCode(B),U=T6;break;default:if(C$())break;K0(),V$(B,T6);break}}function T6(B){switch(B){case 9:case 10:case 12:case 32:case 47:case 62:case-1:V$(B,zH);break;case 61:U=c3;break;case 65:case 66:case 67:case 68:case 69:case 70:case 71:case 72:case 73:case 74:case 75:case 76:case 77:case 78:case 79:case 80:case 81:case 82:case 83:case 84:case 85:case 86:case 87:case 88:case 89:case 90:D+=String.fromCharCode(B+32);break;case 0:D+=String.fromCharCode(65533);break;case 34:case 39:case 60:default:D+=rJ(oP);break}}function zH(B){switch(B){case 9:case 10:case 12:case 32:break;case 47:t(D),U=K2;break;case 61:U=c3;break;case 62:U=S$,t(D),k1();break;case-1:t(D),I$();break;default:t(D),K0(),V$(B,T6);break}}function c3(B){switch(B){case 9:case 10:case 12:case 32:break;case 34:t1(),U=Z9;break;case 39:t1(),U=Y9;break;case 62:default:t1(),V$(B,K9);break}}function Z9(B){switch(B){case 34:t(D,L),U=k6;break;case 38:z=Z9,U=tJ;break;case 0:L+=String.fromCharCode(65533);break;case-1:I$();break;case 10:L+=String.fromCharCode(B);break;default:L+=rJ(dP);break}}function Y9(B){switch(B){case 39:t(D,L),U=k6;break;case 38:z=Y9,U=tJ;break;case 0:L+=String.fromCharCode(65533);break;case-1:I$();break;case 10:L+=String.fromCharCode(B);break;default:L+=rJ(pP);break}}function K9(B){switch(B){case 9:case 10:case 12:case 32:t(D,L),U=A1;break;case 38:z=K9,U=tJ;break;case 62:t(D,L),U=S$,k1();break;case 0:L+=String.fromCharCode(65533);break;case-1:Q--,U=S$;break;case 34:case 39:case 60:case 61:case 96:default:L+=rJ(cP);break}}function k6(B){switch(B){case 9:case 10:case 12:case 32:U=A1;break;case 47:U=K2;break;case 62:U=S$,k1();break;case-1:I$();break;default:V$(B,A1);break}}function K2(B){switch(B){case 62:U=S$,iB(!0);break;case-1:I$();break;default:V$(B,A1);break}}function Q9(B,O,w){var E=O.length;if(w)Q+=E-1;else Q+=E;var h=O.substring(0,E-1);h=h.replace(/\u0000/g,"\uFFFD"),h=h.replace(/\u000D\u000A/g,`
|
|
35
35
|
`),h=h.replace(/\u000D/g,`
|
|
36
|
-
`),j0(y1,h),H=S$}K9.lookahead=">";function p3(U,O,w){if(O[0]==="-"&&O[1]==="-"){Q+=2,n8(),H=_B;return}if(O.toUpperCase()==="DOCTYPE")Q+=7,H=DB;else if(O==="[CDATA["&&mH())Q+=7,H=E6;else H=K9}p3.lookahead=7;function _B(U){switch(n8(),U){case 45:H=OB;break;case 62:H=S$,j0(y1,L0(R));break;default:V$(U,D2);break}}function OB(U){switch(U){case 45:H=Q9;break;case 62:H=S$,j0(y1,L0(R));break;case-1:j0(y1,L0(R)),I$();break;default:R.push(45),V$(U,D2);break}}function D2(U){switch(U){case 60:R.push(U),H=qB;break;case 45:H=T6;break;case 0:R.push(65533);break;case-1:j0(y1,L0(R)),I$();break;default:R.push(U);break}}function qB(U){switch(U){case 33:R.push(U),H=FB;break;case 60:R.push(U);break;default:V$(U,D2);break}}function FB(U){switch(U){case 45:H=zB;break;default:V$(U,D2);break}}function zB(U){switch(U){case 45:H=CB;break;default:V$(U,T6);break}}function CB(U){switch(U){case 62:case-1:V$(U,Q9);break;default:V$(U,Q9);break}}function T6(U){switch(U){case 45:H=Q9;break;case-1:j0(y1,L0(R)),I$();break;default:R.push(45),V$(U,D2);break}}function Q9(U){switch(U){case 62:H=S$,j0(y1,L0(R));break;case 33:H=MB;break;case 45:R.push(45);break;case-1:j0(y1,L0(R)),I$();break;default:R.push(45),R.push(45),V$(U,D2);break}}function MB(U){switch(U){case 45:R.push(45),R.push(45),R.push(33),H=T6;break;case 62:H=S$,j0(y1,L0(R));break;case-1:j0(y1,L0(R)),I$();break;default:R.push(45),R.push(45),R.push(33),V$(U,D2);break}}function DB(U){switch(U){case 9:case 10:case 12:case 32:H=c3;break;case-1:e1(),h$(),g$(),I$();break;default:V$(U,c3);break}}function c3(U){switch(U){case 9:case 10:case 12:case 32:break;case 65:case 66:case 67:case 68:case 69:case 70:case 71:case 72:case 73:case 74:case 75:case 76:case 77:case 78:case 79:case 80:case 81:case 82:case 83:case 84:case 85:case 86:case 87:case 88:case 89:case 90:e1(),N.push(U+32),H=k6;break;case 0:e1(),N.push(65533),H=k6;break;case 62:e1(),h$(),H=S$,g$();break;case-1:e1(),h$(),g$(),I$();break;default:e1(),N.push(U),H=k6;break}}function k6(U){switch(U){case 9:case 10:case 12:case 32:H=l3;break;case 62:H=S$,g$();break;case 65:case 66:case 67:case 68:case 69:case 70:case 71:case 72:case 73:case 74:case 75:case 76:case 77:case 78:case 79:case 80:case 81:case 82:case 83:case 84:case 85:case 86:case 87:case 88:case 89:case 90:N.push(U+32);break;case 0:N.push(65533);break;case-1:h$(),g$(),I$();break;default:N.push(U);break}}function l3(U,O,w){switch(U){case 9:case 10:case 12:case 32:Q+=1;break;case 62:H=S$,Q+=1,g$();break;case-1:h$(),g$(),I$();break;default:if(O=O.toUpperCase(),O==="PUBLIC")Q+=6,H=PB;else if(O==="SYSTEM")Q+=6,H=SB;else h$(),H=Q2;break}}l3.lookahead=6;function PB(U){switch(U){case 9:case 10:case 12:case 32:H=IB;break;case 34:C1(),H=o3;break;case 39:C1(),H=r3;break;case 62:h$(),H=S$,g$();break;case-1:h$(),g$(),I$();break;default:h$(),H=Q2;break}}function IB(U){switch(U){case 9:case 10:case 12:case 32:break;case 34:C1(),H=o3;break;case 39:C1(),H=r3;break;case 62:h$(),H=S$,g$();break;case-1:h$(),g$(),I$();break;default:h$(),H=Q2;break}}function o3(U){switch(U){case 34:H=i3;break;case 0:x.push(65533);break;case 62:h$(),H=S$,g$();break;case-1:h$(),g$(),I$();break;default:x.push(U);break}}function r3(U){switch(U){case 39:H=i3;break;case 0:x.push(65533);break;case 62:h$(),H=S$,g$();break;case-1:h$(),g$(),I$();break;default:x.push(U);break}}function i3(U){switch(U){case 9:case 10:case 12:case 32:H=AB;break;case 62:H=S$,g$();break;case 34:M1(),H=V9;break;case 39:M1(),H=G9;break;case-1:h$(),g$(),I$();break;default:h$(),H=Q2;break}}function AB(U){switch(U){case 9:case 10:case 12:case 32:break;case 62:H=S$,g$();break;case 34:M1(),H=V9;break;case 39:M1(),H=G9;break;case-1:h$(),g$(),I$();break;default:h$(),H=Q2;break}}function SB(U){switch(U){case 9:case 10:case 12:case 32:H=wB;break;case 34:M1(),H=V9;break;case 39:M1(),H=G9;break;case 62:h$(),H=S$,g$();break;case-1:h$(),g$(),I$();break;default:h$(),H=Q2;break}}function wB(U){switch(U){case 9:case 10:case 12:case 32:break;case 34:M1(),H=V9;break;case 39:M1(),H=G9;break;case 62:h$(),H=S$,g$();break;case-1:h$(),g$(),I$();break;default:h$(),H=Q2;break}}function V9(U){switch(U){case 34:H=s3;break;case 0:b.push(65533);break;case 62:h$(),H=S$,g$();break;case-1:h$(),g$(),I$();break;default:b.push(U);break}}function G9(U){switch(U){case 39:H=s3;break;case 0:b.push(65533);break;case 62:h$(),H=S$,g$();break;case-1:h$(),g$(),I$();break;default:b.push(U);break}}function s3(U){switch(U){case 9:case 10:case 12:case 32:break;case 62:H=S$,g$();break;case-1:h$(),g$(),I$();break;default:H=Q2;break}}function Q2(U){switch(U){case 62:H=S$,g$();break;case-1:g$(),I$();break;default:break}}function E6(U){switch(U){case 93:H=RB;break;case-1:I$();break;case 0:n=!0;default:iJ(dP)||y.push(U);break}}function RB(U){switch(U){case 93:H=LB;break;default:y.push(93),V$(U,E6);break}}function LB(U){switch(U){case 93:y.push(93);break;case 62:VJ(),H=S$;break;default:y.push(93),y.push(93),V$(U,E6);break}}function tJ(U){switch(r$(),P.push(38),U){case 9:case 10:case 12:case 32:case 60:case 38:case-1:V$(U,P2);break;case 35:P.push(U),H=NB;break;default:V$(U,n3);break}}function n3(U){Ij.lastIndex=Q;var O=Ij.exec(Y);if(!O)throw Error("should never happen");var w=O[1];if(!w){H=P2;return}switch(Q+=w.length,t2(P,oP(w)),C){case J9:case Z9:case Y9:if(w[w.length-1]!==";"){if(/[=A-Za-z0-9]/.test(Y[Q])){H=P2;return}}break;default:break}r$();var E=bP[w];if(typeof E==="number")P.push(E);else t2(P,E);H=P2}n3.lookahead=-vP;function NB(U){switch(M=0,U){case 120:case 88:P.push(U),H=yB;break;default:V$(U,TB);break}}function yB(U){switch(U){case 48:case 49:case 50:case 51:case 52:case 53:case 54:case 55:case 56:case 57:case 65:case 66:case 67:case 68:case 69:case 70:case 97:case 98:case 99:case 100:case 101:case 102:V$(U,kB);break;default:V$(U,P2);break}}function TB(U){switch(U){case 48:case 49:case 50:case 51:case 52:case 53:case 54:case 55:case 56:case 57:V$(U,EB);break;default:V$(U,P2);break}}function kB(U){switch(U){case 65:case 66:case 67:case 68:case 69:case 70:M*=16,M+=U-55;break;case 97:case 98:case 99:case 100:case 101:case 102:M*=16,M+=U-87;break;case 48:case 49:case 50:case 51:case 52:case 53:case 54:case 55:case 56:case 57:M*=16,M+=U-48;break;case 59:H=X9;break;default:V$(U,X9);break}}function EB(U){switch(U){case 48:case 49:case 50:case 51:case 52:case 53:case 54:case 55:case 56:case 57:M*=10,M+=U-48;break;case 59:H=X9;break;default:V$(U,X9);break}}function X9(U){if(M in Pj)M=Pj[M];else if(M>1114111||M>=55296&&M<57344)M=65533;if(r$(),M<=65535)P.push(M);else M=M-65536,P.push(55296+(M>>10)),P.push(56320+(M&1023));V$(U,P2)}function P2(U){switch(C){case J9:case Z9:case Y9:L+=L0(P);break;default:t2(y,P);break}V$(U,C)}function xB(U,O,w,E){switch(U){case 1:if(O=O.replace(e2,""),O.length===0)return;break;case 4:l._appendChild(l.createComment(O));return;case 5:var h=O,c=w,U$=E;if(l.appendChild(new LP(l,h,c,U$)),W$||h.toLowerCase()!=="html"||TP.test(c)||U$&&U$.toLowerCase()===kP||U$===void 0&&zj.test(c))l._quirks=!0;else if(EP.test(c)||U$!==void 0&&zj.test(c))l._limitedQuirks=!0;A=a3;return}l._quirks=!0,A=a3,A(U,O,w,E)}function a3(U,O,w,E){var h;switch(U){case 1:if(O=O.replace(e2,""),O.length===0)return;break;case 5:return;case 4:l._appendChild(l.createComment(O));return;case 2:if(O==="html"){h=sJ(l,O,w),S.push(h),l.appendChild(h),A=W9;return}break;case 3:switch(O){case"html":case"head":case"body":case"br":break;default:return}}h=sJ(l,"html",null),S.push(h),l.appendChild(h),A=W9,A(U,O,w,E)}function W9(U,O,w,E){switch(U){case 1:if(O=O.replace(e2,""),O.length===0)return;break;case 5:return;case 4:D1(O);return;case 2:switch(O){case"html":j$(U,O,w,E);return;case"head":var h=q$(O,w);A$=h,A=Q0;return}break;case 3:switch(O){case"html":case"head":case"body":case"br":break;default:return}}W9(R0,"head",null),A(U,O,w,E)}function Q0(U,O,w,E){switch(U){case 1:var h=O.match(e2);if(h)P1(h[0]),O=O.substring(h[0].length);if(O.length===0)return;break;case 4:D1(O);return;case 5:return;case 2:switch(O){case"html":j$(U,O,w,E);return;case"meta":case"base":case"basefont":case"bgsound":case"link":q$(O,w),S.pop();return;case"title":cH(O,w);return;case"noscript":if(!J$){q$(O,w),A=t3;return}case"noframes":case"style":e8(O,w);return;case"script":a8(function(c){var U$=sJ(c,O,w);if(U$._parser_inserted=!0,U$._force_async=!1,k)U$._already_started=!0;return VJ(),U$}),H=Z2,u=A,A=j9;return;case"template":q$(O,w),T.insertMarker(),Z$=!1,A=v6,r.push(A);return;case"head":return}break;case 3:switch(O){case"head":S.pop(),A=x6;return;case"body":case"html":case"br":break;case"template":if(!S.contains("template"))return;S.generateImpliedEndTags(null,"thorough"),S.popTag("template"),T.clearToMarker(),r.pop(),nJ();return;default:return}break}Q0(N$,"head",null),A(U,O,w,E)}function t3(U,O,w,E){switch(U){case 5:return;case 4:Q0(U,O);return;case 1:var h=O.match(e2);if(h)Q0(U,h[0]),O=O.substring(h[0].length);if(O.length===0)return;break;case 2:switch(O){case"html":j$(U,O,w,E);return;case"basefont":case"bgsound":case"link":case"meta":case"noframes":case"style":Q0(U,O,w);return;case"head":case"noscript":return}break;case 3:switch(O){case"noscript":S.pop(),A=Q0;return;case"br":break;default:return}break}t3(N$,"noscript",null),A(U,O,w,E)}function x6(U,O,w,E){switch(U){case 1:var h=O.match(e2);if(h)P1(h[0]),O=O.substring(h[0].length);if(O.length===0)return;break;case 4:D1(O);return;case 5:return;case 2:switch(O){case"html":j$(U,O,w,E);return;case"body":q$(O,w),Z$=!1,A=j$;return;case"frameset":q$(O,w),A=h6;return;case"base":case"basefont":case"bgsound":case"link":case"meta":case"noframes":case"script":case"style":case"template":case"title":S.push(A$),Q0(R0,O,w),S.removeElement(A$);return;case"head":return}break;case 3:switch(O){case"template":return Q0(U,O,w,E);case"body":case"html":case"br":break;default:return}break}x6(R0,"body",null),Z$=!0,A(U,O,w,E)}function j$(U,O,w,E){var h,c,U$,w$;switch(U){case 1:if(n){if(O=O.replace(Q6,""),O.length===0)return}if(Z$&&K6.test(O))Z$=!1;y0(),P1(O);return;case 5:return;case 4:D1(O);return;case-1:if(r.length)return v6(U);M2();return;case 2:switch(O){case"html":if(S.contains("template"))return;Tj(w,S.elements[0]);return;case"base":case"basefont":case"bgsound":case"link":case"meta":case"noframes":case"script":case"style":case"template":case"title":Q0(R0,O,w);return;case"body":if(h=S.elements[1],!h||!(h instanceof u$.HTMLBodyElement)||S.contains("template"))return;Z$=!1,Tj(w,h);return;case"frameset":if(!Z$)return;if(h=S.elements[1],!h||!(h instanceof u$.HTMLBodyElement))return;if(h.parentNode)h.parentNode.removeChild(h);while(!(S.top instanceof u$.HTMLHtmlElement))S.pop();q$(O,w),A=h6;return;case"address":case"article":case"aside":case"blockquote":case"center":case"details":case"dialog":case"dir":case"div":case"dl":case"fieldset":case"figcaption":case"figure":case"footer":case"header":case"hgroup":case"main":case"nav":case"ol":case"p":case"section":case"summary":case"ul":if(S.inButtonScope("p"))j$(N$,"p");q$(O,w);return;case"menu":if(S.inButtonScope("p"))j$(N$,"p");if(d$(S.top,"menuitem"))S.pop();q$(O,w);return;case"h1":case"h2":case"h3":case"h4":case"h5":case"h6":if(S.inButtonScope("p"))j$(N$,"p");if(S.top instanceof u$.HTMLHeadingElement)S.pop();q$(O,w);return;case"pre":case"listing":if(S.inButtonScope("p"))j$(N$,"p");q$(O,w),a=!0,Z$=!1;return;case"form":if(s&&!S.contains("template"))return;if(S.inButtonScope("p"))j$(N$,"p");if(w$=q$(O,w),!S.contains("template"))s=w$;return;case"li":Z$=!1;for(c=S.elements.length-1;c>=0;c--){if(U$=S.elements[c],U$ instanceof u$.HTMLLIElement){j$(N$,"li");break}if(d$(U$,$J)&&!d$(U$,Z3))break}if(S.inButtonScope("p"))j$(N$,"p");q$(O,w);return;case"dd":case"dt":Z$=!1;for(c=S.elements.length-1;c>=0;c--){if(U$=S.elements[c],d$(U$,Ej)){j$(N$,U$.localName);break}if(d$(U$,$J)&&!d$(U$,Z3))break}if(S.inButtonScope("p"))j$(N$,"p");q$(O,w);return;case"plaintext":if(S.inButtonScope("p"))j$(N$,"p");q$(O,w),H=w6;return;case"button":if(S.inScope("button"))j$(N$,"button"),A(U,O,w,E);else y0(),q$(O,w),Z$=!1;return;case"a":var J0=T.findElementByTag("a");if(J0)j$(N$,O),T.remove(J0),S.removeElement(J0);case"b":case"big":case"code":case"em":case"font":case"i":case"s":case"small":case"strike":case"strong":case"tt":case"u":y0(),T.push(q$(O,w),w);return;case"nobr":if(y0(),S.inScope(O))j$(N$,O),y0();T.push(q$(O,w),w);return;case"applet":case"marquee":case"object":y0(),q$(O,w),T.insertMarker(),Z$=!1;return;case"table":if(!l._quirks&&S.inButtonScope("p"))j$(N$,"p");q$(O,w),Z$=!1,A=i0;return;case"area":case"br":case"embed":case"img":case"keygen":case"wbr":y0(),q$(O,w),S.pop(),Z$=!1;return;case"input":y0(),w$=q$(O,w),S.pop();var M0=w$.getAttribute("type");if(!M0||M0.toLowerCase()!=="hidden")Z$=!1;return;case"param":case"source":case"track":q$(O,w),S.pop();return;case"hr":if(S.inButtonScope("p"))j$(N$,"p");if(d$(S.top,"menuitem"))S.pop();q$(O,w),S.pop(),Z$=!1;return;case"image":j$(R0,"img",w,E);return;case"textarea":q$(O,w),a=!0,Z$=!1,H=J2,u=A,A=j9;return;case"xmp":if(S.inButtonScope("p"))j$(N$,"p");y0(),Z$=!1,e8(O,w);return;case"iframe":Z$=!1,e8(O,w);return;case"noembed":e8(O,w);return;case"select":if(y0(),q$(O,w),Z$=!1,A===i0||A===b6||A===I2||A===eJ||A===GJ)A=H9;else A=E1;return;case"optgroup":case"option":if(S.top instanceof u$.HTMLOptionElement)j$(N$,"option");y0(),q$(O,w);return;case"menuitem":if(d$(S.top,"menuitem"))S.pop();y0(),q$(O,w);return;case"rb":case"rtc":if(S.inScope("ruby"))S.generateImpliedEndTags();q$(O,w);return;case"rp":case"rt":if(S.inScope("ruby"))S.generateImpliedEndTags("rtc");q$(O,w);return;case"math":if(y0(),yj(w),J3(w),A6(O,w,X$.MATHML),E)S.pop();return;case"svg":if(y0(),Nj(w),J3(w),A6(O,w,X$.SVG),E)S.pop();return;case"caption":case"col":case"colgroup":case"frame":case"head":case"tbody":case"td":case"tfoot":case"th":case"thead":case"tr":return}y0(),q$(O,w);return;case 3:switch(O){case"template":Q0(N$,O,w);return;case"body":if(!S.inScope("body"))return;A=e3;return;case"html":if(!S.inScope("body"))return;A=e3,A(U,O,w);return;case"address":case"article":case"aside":case"blockquote":case"button":case"center":case"details":case"dialog":case"dir":case"div":case"dl":case"fieldset":case"figcaption":case"figure":case"footer":case"header":case"hgroup":case"listing":case"main":case"menu":case"nav":case"ol":case"pre":case"section":case"summary":case"ul":if(!S.inScope(O))return;S.generateImpliedEndTags(),S.popTag(O);return;case"form":if(!S.contains("template")){var s0=s;if(s=null,!s0||!S.elementInScope(s0))return;S.generateImpliedEndTags(),S.removeElement(s0)}else{if(!S.inScope("form"))return;S.generateImpliedEndTags(),S.popTag("form")}return;case"p":if(!S.inButtonScope(O))j$(R0,O,null),A(U,O,w,E);else S.generateImpliedEndTags(O),S.popTag(O);return;case"li":if(!S.inListItemScope(O))return;S.generateImpliedEndTags(O),S.popTag(O);return;case"dd":case"dt":if(!S.inScope(O))return;S.generateImpliedEndTags(O),S.popTag(O);return;case"h1":case"h2":case"h3":case"h4":case"h5":case"h6":if(!S.elementTypeInScope(u$.HTMLHeadingElement))return;S.generateImpliedEndTags(),S.popElementType(u$.HTMLHeadingElement);return;case"sarcasm":break;case"a":case"b":case"big":case"code":case"em":case"font":case"i":case"nobr":case"s":case"small":case"strike":case"strong":case"tt":case"u":var X1=lH(O);if(X1)return;break;case"applet":case"marquee":case"object":if(!S.inScope(O))return;S.generateImpliedEndTags(),S.popTag(O),T.clearToMarker();return;case"br":j$(R0,O,null);return}for(c=S.elements.length-1;c>=0;c--)if(U$=S.elements[c],d$(U$,O)){S.generateImpliedEndTags(O),S.popElement(U$);break}else if(d$(U$,$J))return;return}}function j9(U,O,w,E){switch(U){case 1:P1(O);return;case-1:if(S.top instanceof u$.HTMLScriptElement)S.top._already_started=!0;S.pop(),A=u,A(U);return;case 3:if(O==="script")oH();else S.pop(),A=u;return;default:return}}function i0(U,O,w,E){function h(U$){for(var w$=0,J0=U$.length;w$<J0;w$++)if(U$[w$][0]==="type")return U$[w$][1].toLowerCase();return null}switch(U){case 1:if(Q$){j$(U,O,w,E);return}else if(d$(S.top,lJ)){y$=[],u=A,A=bB,A(U,O,w,E);return}break;case 4:D1(O);return;case 5:return;case 2:switch(O){case"caption":S.clearToContext(V6),T.insertMarker(),q$(O,w),A=b6;return;case"colgroup":S.clearToContext(V6),q$(O,w),A=U9;return;case"col":i0(R0,"colgroup",null),A(U,O,w,E);return;case"tbody":case"tfoot":case"thead":S.clearToContext(V6),q$(O,w),A=I2;return;case"td":case"th":case"tr":i0(R0,"tbody",null),A(U,O,w,E);return;case"table":if(!S.inTableScope(O))return;i0(N$,O),A(U,O,w,E);return;case"style":case"script":case"template":Q0(U,O,w,E);return;case"input":var c=h(w);if(c!=="hidden")break;q$(O,w),S.pop();return;case"form":if(s||S.contains("template"))return;s=q$(O,w),S.popElement(s);return}break;case 3:switch(O){case"table":if(!S.inTableScope(O))return;S.popTag(O),nJ();return;case"body":case"caption":case"col":case"colgroup":case"html":case"tbody":case"td":case"tfoot":case"th":case"thead":case"tr":return;case"template":Q0(U,O,w,E);return}break;case-1:j$(U,O,w,E);return}$2=!0,j$(U,O,w,E),$2=!1}function bB(U,O,w,E){if(U===cJ){if(n){if(O=O.replace(Q6,""),O.length===0)return}y$.push(O)}else{var h=y$.join("");if(y$.length=0,K6.test(h))$2=!0,j$(cJ,h),$2=!1;else P1(h);A=u,A(U,O,w,E)}}function b6(U,O,w,E){function h(){if(!S.inTableScope("caption"))return!1;return S.generateImpliedEndTags(),S.popTag("caption"),T.clearToMarker(),A=i0,!0}switch(U){case 2:switch(O){case"caption":case"col":case"colgroup":case"tbody":case"td":case"tfoot":case"th":case"thead":case"tr":if(h())A(U,O,w,E);return}break;case 3:switch(O){case"caption":h();return;case"table":if(h())A(U,O,w,E);return;case"body":case"col":case"colgroup":case"html":case"tbody":case"td":case"tfoot":case"th":case"thead":case"tr":return}break}j$(U,O,w,E)}function U9(U,O,w,E){switch(U){case 1:var h=O.match(e2);if(h)P1(h[0]),O=O.substring(h[0].length);if(O.length===0)return;break;case 4:D1(O);return;case 5:return;case 2:switch(O){case"html":j$(U,O,w,E);return;case"col":q$(O,w),S.pop();return;case"template":Q0(U,O,w,E);return}break;case 3:switch(O){case"colgroup":if(!d$(S.top,"colgroup"))return;S.pop(),A=i0;return;case"col":return;case"template":Q0(U,O,w,E);return}break;case-1:j$(U,O,w,E);return}if(!d$(S.top,"colgroup"))return;U9(N$,"colgroup"),A(U,O,w,E)}function I2(U,O,w,E){function h(){if(!S.inTableScope("tbody")&&!S.inTableScope("thead")&&!S.inTableScope("tfoot"))return;S.clearToContext(G6),I2(N$,S.top.localName,null),A(U,O,w,E)}switch(U){case 2:switch(O){case"tr":S.clearToContext(G6),q$(O,w),A=eJ;return;case"th":case"td":I2(R0,"tr",null),A(U,O,w,E);return;case"caption":case"col":case"colgroup":case"tbody":case"tfoot":case"thead":h();return}break;case 3:switch(O){case"table":h();return;case"tbody":case"tfoot":case"thead":if(S.inTableScope(O))S.clearToContext(G6),S.pop(),A=i0;return;case"body":case"caption":case"col":case"colgroup":case"html":case"td":case"th":case"tr":return}break}i0(U,O,w,E)}function eJ(U,O,w,E){function h(){if(!S.inTableScope("tr"))return!1;return S.clearToContext(Y3),S.pop(),A=I2,!0}switch(U){case 2:switch(O){case"th":case"td":S.clearToContext(Y3),q$(O,w),A=GJ,T.insertMarker();return;case"caption":case"col":case"colgroup":case"tbody":case"tfoot":case"thead":case"tr":if(h())A(U,O,w,E);return}break;case 3:switch(O){case"tr":h();return;case"table":if(h())A(U,O,w,E);return;case"tbody":case"tfoot":case"thead":if(S.inTableScope(O)){if(h())A(U,O,w,E)}return;case"body":case"caption":case"col":case"colgroup":case"html":case"td":case"th":return}break}i0(U,O,w,E)}function GJ(U,O,w,E){switch(U){case 2:switch(O){case"caption":case"col":case"colgroup":case"tbody":case"td":case"tfoot":case"th":case"thead":case"tr":if(S.inTableScope("td"))GJ(N$,"td"),A(U,O,w,E);else if(S.inTableScope("th"))GJ(N$,"th"),A(U,O,w,E);return}break;case 3:switch(O){case"td":case"th":if(!S.inTableScope(O))return;S.generateImpliedEndTags(),S.popTag(O),T.clearToMarker(),A=eJ;return;case"body":case"caption":case"col":case"colgroup":case"html":return;case"table":case"tbody":case"tfoot":case"thead":case"tr":if(!S.inTableScope(O))return;GJ(N$,S.inTableScope("td")?"td":"th"),A(U,O,w,E);return}break}j$(U,O,w,E)}function E1(U,O,w,E){switch(U){case 1:if(n){if(O=O.replace(Q6,""),O.length===0)return}P1(O);return;case 4:D1(O);return;case 5:return;case-1:j$(U,O,w,E);return;case 2:switch(O){case"html":j$(U,O,w,E);return;case"option":if(S.top instanceof u$.HTMLOptionElement)E1(N$,O);q$(O,w);return;case"optgroup":if(S.top instanceof u$.HTMLOptionElement)E1(N$,"option");if(S.top instanceof u$.HTMLOptGroupElement)E1(N$,O);q$(O,w);return;case"select":E1(N$,O);return;case"input":case"keygen":case"textarea":if(!S.inSelectScope("select"))return;E1(N$,"select"),A(U,O,w,E);return;case"script":case"template":Q0(U,O,w,E);return}break;case 3:switch(O){case"optgroup":if(S.top instanceof u$.HTMLOptionElement&&S.elements[S.elements.length-2]instanceof u$.HTMLOptGroupElement)E1(N$,"option");if(S.top instanceof u$.HTMLOptGroupElement)S.pop();return;case"option":if(S.top instanceof u$.HTMLOptionElement)S.pop();return;case"select":if(!S.inSelectScope(O))return;S.popTag(O),nJ();return;case"template":Q0(U,O,w,E);return}break}}function H9(U,O,w,E){switch(O){case"caption":case"table":case"tbody":case"tfoot":case"thead":case"tr":case"td":case"th":switch(U){case 2:H9(N$,"select"),A(U,O,w,E);return;case 3:if(S.inTableScope(O))H9(N$,"select"),A(U,O,w,E);return}}E1(U,O,w,E)}function v6(U,O,w,E){function h(c){A=c,r[r.length-1]=A,A(U,O,w,E)}switch(U){case 1:case 4:case 5:j$(U,O,w,E);return;case-1:if(!S.contains("template"))M2();else S.popTag("template"),T.clearToMarker(),r.pop(),nJ(),A(U,O,w,E);return;case 2:switch(O){case"base":case"basefont":case"bgsound":case"link":case"meta":case"noframes":case"script":case"style":case"template":case"title":Q0(U,O,w,E);return;case"caption":case"colgroup":case"tbody":case"tfoot":case"thead":h(i0);return;case"col":h(U9);return;case"tr":h(I2);return;case"td":case"th":h(eJ);return}h(j$);return;case 3:switch(O){case"template":Q0(U,O,w,E);return;default:return}}}function e3(U,O,w,E){switch(U){case 1:if(K6.test(O))break;j$(U,O);return;case 4:S.elements[0]._appendChild(l.createComment(O));return;case 5:return;case-1:M2();return;case 2:if(O==="html"){j$(U,O,w,E);return}break;case 3:if(O==="html"){if(k)return;A=hB;return}break}A=j$,A(U,O,w,E)}function h6(U,O,w,E){switch(U){case 1:if(O=O.replace($3,""),O.length>0)P1(O);return;case 4:D1(O);return;case 5:return;case-1:M2();return;case 2:switch(O){case"html":j$(U,O,w,E);return;case"frameset":q$(O,w);return;case"frame":q$(O,w),S.pop();return;case"noframes":Q0(U,O,w,E);return}break;case 3:if(O==="frameset"){if(k&&S.top instanceof u$.HTMLHtmlElement)return;if(S.pop(),!k&&!(S.top instanceof u$.HTMLFrameSetElement))A=vB;return}break}}function vB(U,O,w,E){switch(U){case 1:if(O=O.replace($3,""),O.length>0)P1(O);return;case 4:D1(O);return;case 5:return;case-1:M2();return;case 2:switch(O){case"html":j$(U,O,w,E);return;case"noframes":Q0(U,O,w,E);return}break;case 3:if(O==="html"){A=gB;return}break}}function hB(U,O,w,E){switch(U){case 1:if(K6.test(O))break;j$(U,O,w,E);return;case 4:l._appendChild(l.createComment(O));return;case 5:j$(U,O,w,E);return;case-1:M2();return;case 2:if(O==="html"){j$(U,O,w,E);return}break}A=j$,A(U,O,w,E)}function gB(U,O,w,E){switch(U){case 1:if(O=O.replace($3,""),O.length>0)j$(U,O,w,E);return;case 4:l._appendChild(l.createComment(O));return;case 5:j$(U,O,w,E);return;case-1:M2();return;case 2:switch(O){case"html":j$(U,O,w,E);return;case"noframes":Q0(U,O,w,E);return}break}}function $K(U,O,w,E){function h(J0){for(var M0=0,s0=J0.length;M0<s0;M0++)switch(J0[M0][0]){case"color":case"face":case"size":return!0}return!1}var c;switch(U){case 1:if(Z$&&lP.test(O))Z$=!1;if(n)O=O.replace(Q6,"\uFFFD");P1(O);return;case 4:D1(O);return;case 5:return;case 2:switch(O){case"font":if(!h(w))break;case"b":case"big":case"blockquote":case"body":case"br":case"center":case"code":case"dd":case"div":case"dl":case"dt":case"em":case"embed":case"h1":case"h2":case"h3":case"h4":case"h5":case"h6":case"head":case"hr":case"i":case"img":case"li":case"listing":case"menu":case"meta":case"nobr":case"ol":case"p":case"pre":case"ruby":case"s":case"small":case"span":case"strong":case"strike":case"sub":case"sup":case"table":case"tt":case"u":case"ul":case"var":if(k)break;do S.pop(),c=S.top;while(c.namespaceURI!==X$.HTML&&!Rj(c)&&!Lj(c));j0(U,O,w,E);return}if(c=S.elements.length===1&&k?J:S.top,c.namespaceURI===X$.MATHML)yj(w);else if(c.namespaceURI===X$.SVG)O=rP(O),Nj(w);if(J3(w),A6(O,w,c.namespaceURI),E){if(O==="script"&&c.namespaceURI===X$.SVG);S.pop()}return;case 3:if(c=S.top,O==="script"&&c.namespaceURI===X$.SVG&&c.localName==="script")S.pop();else{var U$=S.elements.length-1,w$=S.elements[U$];for(;;){if(w$.localName.toLowerCase()===O){S.popElement(w$);break}if(w$=S.elements[--U$],w$.namespaceURI!==X$.HTML)continue;A(U,O,w,E);break}}return}}return c$.testTokenizer=function(U,O,w,E){var h=[];switch(O){case"PCDATA state":H=S$;break;case"RCDATA state":H=J2;break;case"RAWTEXT state":H=aJ;break;case"PLAINTEXT state":H=w6;break}if(w)z=w;if(j0=function(U$,w$,J0,M0){switch(VJ(),U$){case 1:if(h.length>0&&h[h.length-1][0]==="Character")h[h.length-1][1]+=w$;else h.push(["Character",w$]);break;case 4:h.push(["Comment",w$]);break;case 5:h.push(["DOCTYPE",w$,J0===void 0?null:J0,M0===void 0?null:M0,!W$]);break;case 2:var s0=Object.create(null);for(var X1=0;X1<J0.length;X1++){var A2=J0[X1];if(A2.length===1)s0[A2[0]]="";else s0[A2[0]]=A2[1]}var V2=["StartTag",w$,s0];if(M0)V2.push(!0);h.push(V2);break;case 3:h.push(["EndTag",w$]);break;case-1:break}},!E)this.parse(U,!0);else{for(var c=0;c<U.length;c++)this.parse(U[c]);this.parse("",!0)}return h},c$}});var m8=p((Jv,cj)=>{cj.exports=pj;var uj=$6(),dj=Z6(),iP=W6(),j6=X0(),sP=fZ();function pj($){this.contextObject=$}var nP={xml:{"":!0,"1.0":!0,"2.0":!0},core:{"":!0,"2.0":!0},html:{"":!0,"1.0":!0,"2.0":!0},xhtml:{"":!0,"1.0":!0,"2.0":!0}};pj.prototype={hasFeature:function(J,Z){var Y=nP[(J||"").toLowerCase()];return Y&&Y[Z||""]||!1},createDocumentType:function(J,Z,Y){if(!sP.isValidQName(J))j6.InvalidCharacterError();return new dj(this.contextObject,J,Z,Y)},createDocument:function(J,Z,Y){var K=new uj(!1,null),Q;if(Z)Q=K.createElementNS(J,Z);else Q=null;if(Y)K.appendChild(Y);if(Q)K.appendChild(Q);if(J===j6.NAMESPACE.HTML)K._contentType="application/xhtml+xml";else if(J===j6.NAMESPACE.SVG)K._contentType="image/svg+xml";else K._contentType="application/xml";return K},createHTMLDocument:function(J){var Z=new uj(!0,null);Z.appendChild(new dj(Z,"html"));var Y=Z.createElement("html");Z.appendChild(Y);var K=Z.createElement("head");if(Y.appendChild(K),J!==void 0){var Q=Z.createElement("title");K.appendChild(Q),Q.appendChild(Z.createTextNode(J))}return Y.appendChild(Z.createElement("body")),Z.modclock=1,Z},mozSetOutputMutationHandler:function($,J){$.mutationHandler=J},mozGetInputMutationHandler:function($){j6.nyi()},mozHTMLParser:iP}});var oj=p((Zv,lj)=>{var aP=sZ(),tP=lY();lj.exports=Q3;function Q3($,J){this._window=$,this._href=J}Q3.prototype=Object.create(tP.prototype,{constructor:{value:Q3},href:{get:function(){return this._href},set:function($){this.assign($)}},assign:{value:function($){var J=new aP(this._href),Z=J.resolve($);this._href=Z}},replace:{value:function($){this.assign($)}},reload:{value:function(){this.assign(this.href)}},toString:{value:function(){return this.href}}})});var ij=p((Yv,rj)=>{var eP=Object.create(null,{appCodeName:{value:"Mozilla"},appName:{value:"Netscape"},appVersion:{value:"4.0"},platform:{value:""},product:{value:"Gecko"},productSub:{value:"20100101"},userAgent:{value:""},vendor:{value:""},vendorSub:{value:""},taintEnabled:{value:function(){return!1}}});rj.exports=eP});var nj=p((Kv,sj)=>{var $I={setTimeout,clearTimeout,setInterval,clearInterval};sj.exports=$I});var G3=p((u8,aj)=>{var V3=X0();u8=aj.exports={CSSStyleDeclaration:nZ(),CharacterData:T8(),Comment:TY(),DOMException:xZ(),DOMImplementation:m8(),DOMTokenList:_Y(),Document:$6(),DocumentFragment:EY(),DocumentType:Z6(),Element:gJ(),HTMLParser:W6(),NamedNodeMap:MY(),Node:P0(),NodeList:n2(),NodeFilter:b8(),ProcessingInstruction:bY(),Text:NY(),Window:X3()};V3.merge(u8,cY());V3.merge(u8,tZ().elements);V3.merge(u8,nY().elements)});var X3=p((Qv,tj)=>{var JI=m8(),ZI=t7(),YI=oj(),d8=X0();tj.exports=U6;function U6($){this.document=$||new JI(null).createHTMLDocument(""),this.document._scripting_enabled=!0,this.document.defaultView=this,this.location=new YI(this,this.document._address||"about:blank")}U6.prototype=Object.create(ZI.prototype,{console:{value:console},history:{value:{back:d8.nyi,forward:d8.nyi,go:d8.nyi}},navigator:{value:ij()},window:{get:function(){return this}},self:{get:function(){return this}},frames:{get:function(){return this}},parent:{get:function(){return this}},top:{get:function(){return this}},length:{value:0},frameElement:{value:null},opener:{value:null},onload:{get:function(){return this._getEventHandler("load")},set:function($){this._setEventHandler("load",$)}},getComputedStyle:{value:function(J){return J.style}}});d8.expose(nj(),U6);d8.expose(G3(),U6)});var YU=p((KI)=>{var ej=m8(),$U=W6(),Vv=X3(),JU=G3();KI.createDOMImplementation=function(){return new ej(null)};KI.createDocument=function($,J){if($||J){var Z=new $U;return Z.parse($||"",!0),Z.document()}return new ej(null).createHTMLDocument("")};KI.createIncrementalHTMLParser=function(){var $=new $U;return{write:function(J){if(J.length>0)$.parse(J,!1,function(){return!0})},end:function(J){$.parse(J||"",!0,function(){return!0})},process:function(J){return $.parse("",!1,J)},document:function(){return $.document()}}};KI.createWindow=function($,J){var Z=KI.createDocument($);if(J!==void 0)Z._address=J;return new JU.Window(Z)};KI.impl=JU});var W1={};o$(W1,{layer:()=>QK,defaultLayer:()=>B_,Status:()=>H_,Service:()=>O9,Format:()=>W1});import U_ from"path";var _9={};o$(_9,{zig:()=>lB,uvformat:()=>sB,terraform:()=>J_,standardrb:()=>aB,shfmt:()=>K_,rustfmt:()=>V_,ruff:()=>YK,rubocop:()=>nB,rlang:()=>iB,prettier:()=>dB,pint:()=>G_,oxfmt:()=>pB,ormolu:()=>X_,ocamlformat:()=>$_,nixfmt:()=>Q_,mix:()=>uB,latexindent:()=>Z_,ktlint:()=>rB,htmlbeautifier:()=>tB,gofmt:()=>mB,gleam:()=>Y_,dfmt:()=>j_,dart:()=>eB,cljfmt:()=>W_,clang:()=>oB,biome:()=>cB});var mB={name:"gofmt",extensions:[".go"],async enabled(){let $=x$("gofmt");if(!$)return!1;return[$,"-w","$FILE"]}},uB={name:"mix",extensions:[".ex",".exs",".eex",".heex",".leex",".neex",".sface"],async enabled(){let $=x$("mix");if(!$)return!1;return[$,"format","$FILE"]}},JK=[".js",".jsx",".mjs",".cjs",".ts",".tsx",".mts",".cts",".html",".htm",".css",".scss",".sass",".less",".vue",".svelte",".json",".jsonc",".yaml",".yml",".toml",".xml",".md",".mdx",".graphql",".gql"];async function ZK($,J){let Z=await O0.findUp("package.json",$.directory,$.worktree);for(let Y of Z){let K=await O0.readJson(Y);if(K.dependencies?.[J]||K.devDependencies?.[J]){let Q=await g6.which(J);if(Q)return Q}}return}var dB={name:"prettier",environment:{BUN_BE_BUN:"1"},extensions:[...JK],async enabled($){let J=await ZK($,"prettier");return J?[J,"--write","$FILE"]:!1}},pB={name:"oxfmt",environment:{BUN_BE_BUN:"1"},extensions:[".js",".jsx",".mjs",".cjs",".ts",".tsx",".mts",".cts"],async enabled($){if(!k$.QITQODE_EXPERIMENTAL_OXFMT)return!1;let J=await ZK($,"oxfmt");return J?[J,"$FILE"]:!1}},cB={name:"biome",environment:{BUN_BE_BUN:"1"},extensions:[...JK],async enabled($){let J=["biome.json","biome.jsonc"];for(let Z of J)if((await O0.findUp(Z,$.directory,$.worktree)).length>0){let K=await g6.which("@biomejs/biome");if(K)return[K,"format","--write","$FILE"]}return!1}},lB={name:"zig",extensions:[".zig",".zon"],async enabled(){let $=x$("zig");if(!$)return!1;return[$,"fmt","$FILE"]}},oB={name:"clang-format",extensions:[".c",".cc",".cpp",".cxx",".c++",".h",".hh",".hpp",".hxx",".h++",".ino",".C",".H"],async enabled($){if((await O0.findUp(".clang-format",$.directory,$.worktree)).length>0){let Z=x$("clang-format");if(Z)return[Z,"-i","$FILE"]}return!1}},rB={name:"ktlint",extensions:[".kt",".kts"],async enabled(){let $=x$("ktlint");if(!$)return!1;return[$,"-F","$FILE"]}},YK={name:"ruff",extensions:[".py",".pyi"],async enabled($){if(!x$("ruff"))return!1;let J=["pyproject.toml","ruff.toml",".ruff.toml"];for(let Y of J){let K=await O0.findUp(Y,$.directory,$.worktree);if(K.length>0)if(Y==="pyproject.toml"){if((await O0.readText(K[0])).includes("[tool.ruff]"))return["ruff","format","$FILE"]}else return["ruff","format","$FILE"]}let Z=["requirements.txt","pyproject.toml","Pipfile"];for(let Y of Z){let K=await O0.findUp(Y,$.directory,$.worktree);if(K.length>0){if((await O0.readText(K[0])).includes("ruff"))return["ruff","format","$FILE"]}}return!1}},iB={name:"air",extensions:[".R"],async enabled(){let $=x$("air");if($==null)return!1;let J=await B9.text([$,"--help"],{nothrow:!0}),Z=J.text.split(`
|
|
37
|
-
`)[0],Y=Z.includes("R language"),K=Z.includes("formatter");if(J.code===0&&Y&&K)return[$,"format","$FILE"];return!1}},sB={name:"uv",extensions:[".py",".pyi"],async enabled($){if(await YK.enabled($))return!1;let J=x$("uv");if(J==null)return!1;if((await B9.run([J,"format","--help"],{nothrow:!0})).code===0)return[J,"format","--","$FILE"];return!1}},nB={name:"rubocop",extensions:[".rb",".rake",".gemspec",".ru"],async enabled(){let $=x$("rubocop");if(!$)return!1;return[$,"--autocorrect","$FILE"]}},aB={name:"standardrb",extensions:[".rb",".rake",".gemspec",".ru"],async enabled(){let $=x$("standardrb");if(!$)return!1;return[$,"--fix","$FILE"]}},tB={name:"htmlbeautifier",extensions:[".erb",".html.erb"],async enabled(){let $=x$("htmlbeautifier");if(!$)return!1;return[$,"$FILE"]}},eB={name:"dart",extensions:[".dart"],async enabled(){let $=x$("dart");if(!$)return!1;return[$,"format","$FILE"]}},$_={name:"ocamlformat",extensions:[".ml",".mli"],async enabled($){if(!x$("ocamlformat"))return!1;if((await O0.findUp(".ocamlformat",$.directory,$.worktree)).length>0)return["ocamlformat","-i","$FILE"];return!1}},J_={name:"terraform",extensions:[".tf",".tfvars"],async enabled(){let $=x$("terraform");if(!$)return!1;return[$,"fmt","$FILE"]}},Z_={name:"latexindent",extensions:[".tex"],async enabled(){let $=x$("latexindent");if(!$)return!1;return[$,"-w","-s","$FILE"]}},Y_={name:"gleam",extensions:[".gleam"],async enabled(){let $=x$("gleam");if(!$)return!1;return[$,"format","$FILE"]}},K_={name:"shfmt",extensions:[".sh",".bash"],async enabled(){let $=x$("shfmt");if(!$)return!1;return[$,"-w","$FILE"]}},Q_={name:"nixfmt",extensions:[".nix"],async enabled(){let $=x$("nixfmt");if(!$)return!1;return[$,"$FILE"]}},V_={name:"rustfmt",extensions:[".rs"],async enabled(){let $=x$("rustfmt");if(!$)return!1;return[$,"$FILE"]}},G_={name:"pint",extensions:[".php"],async enabled($){let J=await O0.findUp("composer.json",$.directory,$.worktree);for(let Z of J){let Y=await O0.readJson(Z);if(Y.require?.["laravel/pint"]||Y["require-dev"]?.["laravel/pint"])return["./vendor/bin/pint","$FILE"]}return!1}},X_={name:"ormolu",extensions:[".hs"],async enabled(){let $=x$("ormolu");if(!$)return!1;return[$,"-i","$FILE"]}},W_={name:"cljfmt",extensions:[".clj",".cljs",".cljc",".edn"],async enabled(){let $=x$("cljfmt");if(!$)return!1;return[$,"fix","--quiet","$FILE"]}},j_={name:"dfmt",extensions:[".d"],async enabled(){let $=x$("dfmt");if(!$)return!1;return[$,"-i","$FILE"]}};var x1=O$.create({service:"format"}),H_=F.object({name:F.string(),extensions:F.string().array(),enabled:F.boolean()}).meta({ref:"FormatterStatus"});class O9 extends D$.Service()("@qitqode/Format"){}var QK=f.effect(O9,G.gen(function*(){let $=yield*R$.Service,J=yield*f6.ChildProcessSpawner,Z=yield*i.make(G.fn("Format.state")(function*(V){let X={},W={};async function B(C){let M=X[C.name];if(M===!1||M===void 0)M=await C.enabled(V),X[C.name]=M;return M}async function j(C){return await B(C)!==!1}async function _(C){let M=Object.values(W).filter((z)=>z.extensions.includes(C));return(await Promise.all(M.map(async(z)=>{x1.info("checking",{name:z.name,ext:C});let P=await B(z);if(P)x1.info("enabled",{name:z.name,ext:C});return{item:z,cmd:P}}))).filter((z)=>z.cmd).map((z)=>({item:z.item,cmd:z.cmd}))}function q(C){return G.gen(function*(){x1.info("formatting",{file:C});let M=U_.extname(C);for(let{item:I,cmd:z}of yield*G.promise(()=>_(M))){if(z===!1)continue;x1.info("running",{command:z});let P=z.map((R)=>R.replace("$FILE",C)),D=yield*i.directory;if((yield*J.spawn(S1.make(P[0],P.slice(1),{cwd:D,env:I.environment,extendEnv:!0})).pipe(G.flatMap((R)=>R.exitCode),G.scoped,G.catch(()=>G.sync(()=>{return x1.error("failed to format file",{error:"spawn failed",command:z,...I.environment,file:C}),f6.ExitCode(1)}))))!==0)x1.error("failed",{command:z,...I.environment})}})}let H=yield*$.get();if(!H.formatter)return x1.info("all formatters are disabled"),x1.info("init"),{formatters:W,isEnabled:j,formatFile:q};for(let C of Object.values(_9))W[C.name]=C;if(H.formatter!==!0)for(let[C,M]of Object.entries(H.formatter)){let I=_9[C];if(["ruff","uv"].includes(C)&&(H.formatter.ruff?.disabled||H.formatter.uv?.disabled)){delete W.ruff,delete W.uv;continue}if(M.disabled){delete W[C];continue}let z=q9(I??{extensions:[]},M);W[C]={...z,name:C,extensions:z.extensions??[],enabled:I&&!z.command?I.enabled:async(P)=>z.command??!1}}return x1.info("init"),{formatters:W,isEnabled:j,formatFile:q}})),Y=G.fn("Format.init")(function*(){yield*i.get(Z)}),K=G.fn("Format.status")(function*(){let{formatters:V,isEnabled:X}=yield*i.get(Z),W=[];for(let B of Object.values(V)){let j=yield*G.promise(()=>X(B));W.push({name:B.name,extensions:B.extensions,enabled:j})}return W}),Q=G.fn("Format.file")(function*(V){let{formatFile:X}=yield*i.get(Z);yield*X(V)});return O9.of({init:Y,status:K,file:Q})})),B_=QK.pipe(f.provide(R$.defaultLayer),f.provide(XJ));var h0={};o$(h0,{layer:()=>_K,defaultLayer:()=>S_,Service:()=>z9,Ripgrep:()=>h0,Match:()=>HK});import J8 from"path";var VK=O$.create({service:"ripgrep"}),m6="15.1.0",__={"arm64-darwin":{platform:"aarch64-apple-darwin",extension:"tar.gz"},"arm64-linux":{platform:"aarch64-unknown-linux-gnu",extension:"tar.gz"},"x64-darwin":{platform:"x86_64-apple-darwin",extension:"tar.gz"},"x64-linux":{platform:"x86_64-unknown-linux-musl",extension:"tar.gz"},"arm64-win32":{platform:"aarch64-pc-windows-msvc",extension:"zip"},"ia32-win32":{platform:"i686-pc-windows-msvc",extension:"zip"},"x64-win32":{platform:"x86_64-pc-windows-msvc",extension:"zip"}},UK=F.object({elapsed:F.object({secs:F.number(),nanos:F.number(),human:F.string()}),searches:F.number(),searches_with_match:F.number(),bytes_searched:F.number(),bytes_printed:F.number(),matched_lines:F.number(),matches:F.number()}),O_=F.object({type:F.literal("begin"),data:F.object({path:F.object({text:F.string()})})}),HK=F.object({type:F.literal("match"),data:F.object({path:F.object({text:F.string()}),lines:F.object({text:F.string()}),line_number:F.number(),absolute_offset:F.number(),submatches:F.array(F.object({match:F.object({text:F.string()}),start:F.number(),end:F.number()}))})}),q_=F.object({type:F.literal("end"),data:F.object({path:F.object({text:F.string()}),binary_offset:F.number().nullable(),stats:UK})}),F_=F.object({type:F.literal("summary"),data:F.object({elapsed_total:F.object({human:F.string(),nanos:F.number(),secs:F.number()}),stats:UK})}),z_=F.union([O_,HK,q_,F_]);class z9 extends D$.Service()("@qitqode/Ripgrep"){}function C_(){let $=jK();return delete $.RIPGREP_CONFIG_PATH,$}function GK($){let J=$?.reason;if(J instanceof Error)return J;let Z=Error("Aborted");return Z.name="AbortError",Z}function M_($){if(!$)return G.never;if($.aborted)return G.fail(GK($));return G.callback((J)=>{let Z=()=>J(G.fail(GK($)));if($.addEventListener("abort",Z,{once:!0}),$.aborted)Z();return G.sync(()=>$.removeEventListener("abort",Z))})}function F9($,J){let Z=Error($.trim()||`ripgrep failed with code ${J}`);return Z.name="RipgrepError",Z}function BK($){return J8.normalize($.replace(/^\.[\\/]/,""))}function D_($){return{...$,path:{...$.path,text:BK($.path.text)}}}function P_($){return G.try({try:()=>z_.parse(JSON.parse($)),catch:(J)=>Error("invalid ripgrep output",{cause:J})})}function XK($,J){b1.failCauseUnsafe($,n0.fail(J))}function I_($){let J=["--no-config","--files","--glob=!.git/*"];if($.follow)J.push("--follow");if($.hidden!==!1)J.push("--hidden");if($.hidden===!1)J.push("--glob=!.*");if($.maxDepth!==void 0)J.push(`--max-depth=${$.maxDepth}`);if($.glob)for(let Z of $.glob)J.push(`--glob=${Z}`);return J.push("."),J}function A_($){let J=["--no-config","--json","--hidden","--glob=!.git/*","--no-messages"];if($.follow)J.push("--follow");if($.glob)for(let Z of $.glob)J.push(`--glob=${Z}`);if($.limit)J.push(`--max-count=${$.limit}`);return J.push("--",$.pattern,...$.file??["."]),J}function WK($,J){return J?$.pipe(G.raceFirst(M_(J))):$}var _K=f.effect(z9,G.gen(function*(){let $=yield*$$.Service,J=v1.filterStatusOk(yield*v1.HttpClient),Z=yield*C9,Y=G.fnUntraced(function*(_,q,H){let C=yield*Z.spawn(S1.make(_,q,{cwd:H?.cwd,extendEnv:!0,stdin:"ignore"})),[M,I,z]=yield*G.all([l$.mkString(l$.decodeText(C.stdout)),l$.mkString(l$.decodeText(C.stderr)),C.exitCode],{concurrency:"unbounded"});return{stdout:M,stderr:I,code:z}},G.scoped),K=G.fnUntraced(function*(_,q,H){let C=yield*$.makeTempDirectoryScoped({directory:f$.Path.bin,prefix:"ripgrep-"});if(q.extension==="zip"){let I=(yield*G.sync(()=>x$("powershell.exe")??x$("pwsh.exe")))??"powershell.exe",z=yield*Y(I,["-NoProfile","-NonInteractive","-Command",`$global:ProgressPreference = 'SilentlyContinue'; Expand-Archive -LiteralPath '${_.replaceAll("'","''")}' -DestinationPath '${C.replaceAll("'","''")}' -Force`]);if(z.code!==0)return yield*G.fail(F9(z.stderr||z.stdout,z.code))}if(q.extension==="tar.gz"){let I=yield*Y("tar",["-xzf",_,"-C",C]);if(I.code!==0)return yield*G.fail(F9(I.stderr||I.stdout,I.code))}let M=J8.join(C,`ripgrep-${m6}-${q.platform}`,process.platform==="win32"?"rg.exe":"rg");if(!(yield*$.isFile(M)))return yield*G.fail(Error(`ripgrep archive did not contain executable: ${M}`));if(yield*$.copyFile(M,H),process.platform==="win32")return;yield*$.chmod(H,493)},G.scoped),Q=yield*G.cached(G.gen(function*(){let _=yield*G.sync(()=>x$(process.platform==="win32"?"rg.exe":"rg"));if(_&&(yield*$.isFile(_).pipe(G.orDie)))return _;let q=J8.join(f$.Path.bin,`rg${process.platform==="win32"?".exe":""}`);if(yield*$.isFile(q).pipe(G.orDie))return q;let H=`${process.arch}-${process.platform}`,C=__[H];if(!C)return yield*G.fail(Error(`unsupported platform for ripgrep: ${H}`));let M=`ripgrep-${m6}-${C.platform}.${C.extension}`,I=`https://github.com/BurntSushi/ripgrep/releases/download/${m6}/${M}`,z=J8.join(f$.Path.bin,M);VK.info("downloading ripgrep",{url:I}),yield*$.ensureDir(f$.Path.bin).pipe(G.orDie);let P=yield*G2.get(I).pipe(J.execute,G.flatMap((D)=>D.arrayBuffer),G.mapError((D)=>D instanceof Error?D:Error(String(D))));if(P.byteLength===0)return yield*G.fail(Error(`failed to download ripgrep from ${I}`));return yield*$.writeWithDirs(z,new Uint8Array(P)),yield*K(z,C,q),yield*$.remove(z,{force:!0}).pipe(G.ignore),q})),V=G.fnUntraced(function*(_){if(yield*$.isDir(_).pipe(G.orDie))return;return yield*G.fail(Object.assign(Error(`No such file or directory: '${_}'`),{code:"ENOENT",errno:-2,path:_}))}),X=G.fnUntraced(function*(_,q){let H=yield*Q;return S1.make(H,q,{cwd:_,env:C_(),extendEnv:!0,stdin:"ignore"})}),W=(_)=>l$.callback((q)=>G.gen(function*(){yield*G.forkScoped(G.gen(function*(){yield*V(_.cwd);let H=yield*Z.spawn(yield*X(_.cwd,I_(_))),C=yield*l$.mkString(l$.decodeText(H.stderr)).pipe(G.forkScoped),M=yield*l$.decodeText(H.stdout).pipe(l$.splitLines,l$.filter((z)=>z.length>0),l$.runForEach((z)=>G.sync(()=>b1.offerUnsafe(q,BK(z)))),G.forkScoped),I=yield*WK(H.exitCode,_.signal);if(yield*Z8.join(M),I===0||I===1){b1.endUnsafe(q);return}XK(q,F9(yield*Z8.join(C),I))}).pipe(G.catch((H)=>G.sync(()=>{XK(q,H)}))))})),B=G.fn("Ripgrep.search")(function*(_){yield*V(_.cwd);let q=G.scoped(G.gen(function*(){let H=yield*Z.spawn(yield*X(_.cwd,A_(_))),[C,M,I]=yield*G.all([l$.decodeText(H.stdout).pipe(l$.splitLines,l$.filter((z)=>z.length>0),l$.mapEffect(P_),l$.filter((z)=>z.type==="match"),l$.map((z)=>D_(z.data)),l$.runCollect,G.map((z)=>[...z])),l$.mkString(l$.decodeText(H.stderr)),H.exitCode],{concurrency:"unbounded"});if(I!==0&&I!==1&&I!==2)return yield*G.fail(F9(M,I));return{items:I===1?[]:C,partial:I===2}}));return yield*WK(q,_.signal)}),j=G.fn("Ripgrep.tree")(function*(_){VK.info("tree",_);let q=Array.from(yield*W({cwd:_.cwd,signal:_.signal}).pipe(l$.runCollect));function H(R,N){let x=R.children.get(N);if(x)return x;let b={name:N,children:new Map};return R.children.set(N,b),b}function C(R){return Array.from(R.children.values()).reduce((N,x)=>N+1+C(x),0)}let M={name:"",children:new Map};for(let R of q){if(R.includes(".qitqode"))continue;let N=R.split(J8.sep);if(N.length<2)continue;let x=M;for(let b of N.slice(0,-1))x=H(x,b)}let I=C(M),z=_.limit??I,P=[],D=Array.from(M.children.values()).sort((R,N)=>R.name.localeCompare(N.name)).map((R)=>({node:R,path:R.name})),L=0;for(let R=0;R<D.length&&L<z;R++){let N=D[R];P.push(N.path),L++,D.push(...Array.from(N.node.children.values()).sort((x,b)=>x.name.localeCompare(b.name)).map((x)=>({node:x,path:`${N.path}/${x.name}`})))}if(I>L)P.push(`[${I-L} truncated]`);return P.join(`
|
|
38
|
-
`)});return
|
|
39
|
-
`)){let[R,N,x]=L.split("\t");
|
|
40
|
-
`)){let R=yield*$.readFileString(
|
|
36
|
+
`),j0(y1,h),U=S$}Q9.lookahead=">";function l3(B,O,w){if(O[0]==="-"&&O[1]==="-"){Q+=2,a8(),U=CH;return}if(O.toUpperCase()==="DOCTYPE")Q+=7,U=wH;else if(O==="[CDATA["&&lB())Q+=7,U=b6;else U=Q9}l3.lookahead=7;function CH(B){switch(a8(),B){case 45:U=MH;break;case 62:U=S$,j0(y1,N0(R));break;default:V$(B,D2);break}}function MH(B){switch(B){case 45:U=V9;break;case 62:U=S$,j0(y1,N0(R));break;case-1:j0(y1,N0(R)),I$();break;default:R.push(45),V$(B,D2);break}}function D2(B){switch(B){case 60:R.push(B),U=DH;break;case 45:U=E6;break;case 0:R.push(65533);break;case-1:j0(y1,N0(R)),I$();break;default:R.push(B);break}}function DH(B){switch(B){case 33:R.push(B),U=PH;break;case 60:R.push(B);break;default:V$(B,D2);break}}function PH(B){switch(B){case 45:U=IH;break;default:V$(B,D2);break}}function IH(B){switch(B){case 45:U=AH;break;default:V$(B,E6);break}}function AH(B){switch(B){case 62:case-1:V$(B,V9);break;default:V$(B,V9);break}}function E6(B){switch(B){case 45:U=V9;break;case-1:j0(y1,N0(R)),I$();break;default:R.push(45),V$(B,D2);break}}function V9(B){switch(B){case 62:U=S$,j0(y1,N0(R));break;case 33:U=SH;break;case 45:R.push(45);break;case-1:j0(y1,N0(R)),I$();break;default:R.push(45),R.push(45),V$(B,D2);break}}function SH(B){switch(B){case 45:R.push(45),R.push(45),R.push(33),U=E6;break;case 62:U=S$,j0(y1,N0(R));break;case-1:j0(y1,N0(R)),I$();break;default:R.push(45),R.push(45),R.push(33),V$(B,D2);break}}function wH(B){switch(B){case 9:case 10:case 12:case 32:U=o3;break;case-1:e1(),h$(),g$(),I$();break;default:V$(B,o3);break}}function o3(B){switch(B){case 9:case 10:case 12:case 32:break;case 65:case 66:case 67:case 68:case 69:case 70:case 71:case 72:case 73:case 74:case 75:case 76:case 77:case 78:case 79:case 80:case 81:case 82:case 83:case 84:case 85:case 86:case 87:case 88:case 89:case 90:e1(),N.push(B+32),U=x6;break;case 0:e1(),N.push(65533),U=x6;break;case 62:e1(),h$(),U=S$,g$();break;case-1:e1(),h$(),g$(),I$();break;default:e1(),N.push(B),U=x6;break}}function x6(B){switch(B){case 9:case 10:case 12:case 32:U=r3;break;case 62:U=S$,g$();break;case 65:case 66:case 67:case 68:case 69:case 70:case 71:case 72:case 73:case 74:case 75:case 76:case 77:case 78:case 79:case 80:case 81:case 82:case 83:case 84:case 85:case 86:case 87:case 88:case 89:case 90:N.push(B+32);break;case 0:N.push(65533);break;case-1:h$(),g$(),I$();break;default:N.push(B);break}}function r3(B,O,w){switch(B){case 9:case 10:case 12:case 32:Q+=1;break;case 62:U=S$,Q+=1,g$();break;case-1:h$(),g$(),I$();break;default:if(O=O.toUpperCase(),O==="PUBLIC")Q+=6,U=RH;else if(O==="SYSTEM")Q+=6,U=yH;else h$(),U=Q2;break}}r3.lookahead=6;function RH(B){switch(B){case 9:case 10:case 12:case 32:U=LH;break;case 34:C1(),U=i3;break;case 39:C1(),U=s3;break;case 62:h$(),U=S$,g$();break;case-1:h$(),g$(),I$();break;default:h$(),U=Q2;break}}function LH(B){switch(B){case 9:case 10:case 12:case 32:break;case 34:C1(),U=i3;break;case 39:C1(),U=s3;break;case 62:h$(),U=S$,g$();break;case-1:h$(),g$(),I$();break;default:h$(),U=Q2;break}}function i3(B){switch(B){case 34:U=n3;break;case 0:x.push(65533);break;case 62:h$(),U=S$,g$();break;case-1:h$(),g$(),I$();break;default:x.push(B);break}}function s3(B){switch(B){case 39:U=n3;break;case 0:x.push(65533);break;case 62:h$(),U=S$,g$();break;case-1:h$(),g$(),I$();break;default:x.push(B);break}}function n3(B){switch(B){case 9:case 10:case 12:case 32:U=NH;break;case 62:U=S$,g$();break;case 34:M1(),U=G9;break;case 39:M1(),U=X9;break;case-1:h$(),g$(),I$();break;default:h$(),U=Q2;break}}function NH(B){switch(B){case 9:case 10:case 12:case 32:break;case 62:U=S$,g$();break;case 34:M1(),U=G9;break;case 39:M1(),U=X9;break;case-1:h$(),g$(),I$();break;default:h$(),U=Q2;break}}function yH(B){switch(B){case 9:case 10:case 12:case 32:U=TH;break;case 34:M1(),U=G9;break;case 39:M1(),U=X9;break;case 62:h$(),U=S$,g$();break;case-1:h$(),g$(),I$();break;default:h$(),U=Q2;break}}function TH(B){switch(B){case 9:case 10:case 12:case 32:break;case 34:M1(),U=G9;break;case 39:M1(),U=X9;break;case 62:h$(),U=S$,g$();break;case-1:h$(),g$(),I$();break;default:h$(),U=Q2;break}}function G9(B){switch(B){case 34:U=a3;break;case 0:b.push(65533);break;case 62:h$(),U=S$,g$();break;case-1:h$(),g$(),I$();break;default:b.push(B);break}}function X9(B){switch(B){case 39:U=a3;break;case 0:b.push(65533);break;case 62:h$(),U=S$,g$();break;case-1:h$(),g$(),I$();break;default:b.push(B);break}}function a3(B){switch(B){case 9:case 10:case 12:case 32:break;case 62:U=S$,g$();break;case-1:h$(),g$(),I$();break;default:U=Q2;break}}function Q2(B){switch(B){case 62:U=S$,g$();break;case-1:g$(),I$();break;default:break}}function b6(B){switch(B){case 93:U=kH;break;case-1:I$();break;case 0:n=!0;default:iJ(rP)||y.push(B);break}}function kH(B){switch(B){case 93:U=EH;break;default:y.push(93),V$(B,b6);break}}function EH(B){switch(B){case 93:y.push(93);break;case 62:VJ(),U=S$;break;default:y.push(93),y.push(93),V$(B,b6);break}}function tJ(B){switch(r$(),P.push(38),B){case 9:case 10:case 12:case 32:case 60:case 38:case-1:V$(B,P2);break;case 35:P.push(B),U=xH;break;default:V$(B,t3);break}}function t3(B){wj.lastIndex=Q;var O=wj.exec(Y);if(!O)throw Error("should never happen");var w=O[1];if(!w){U=P2;return}switch(Q+=w.length,t2(P,aP(w)),z){case Z9:case Y9:case K9:if(w[w.length-1]!==";"){if(/[=A-Za-z0-9]/.test(Y[Q])){U=P2;return}}break;default:break}r$();var E=mP[w];if(typeof E==="number")P.push(E);else t2(P,E);U=P2}t3.lookahead=-uP;function xH(B){switch(M=0,B){case 120:case 88:P.push(B),U=bH;break;default:V$(B,vH);break}}function bH(B){switch(B){case 48:case 49:case 50:case 51:case 52:case 53:case 54:case 55:case 56:case 57:case 65:case 66:case 67:case 68:case 69:case 70:case 97:case 98:case 99:case 100:case 101:case 102:V$(B,hH);break;default:V$(B,P2);break}}function vH(B){switch(B){case 48:case 49:case 50:case 51:case 52:case 53:case 54:case 55:case 56:case 57:V$(B,gH);break;default:V$(B,P2);break}}function hH(B){switch(B){case 65:case 66:case 67:case 68:case 69:case 70:M*=16,M+=B-55;break;case 97:case 98:case 99:case 100:case 101:case 102:M*=16,M+=B-87;break;case 48:case 49:case 50:case 51:case 52:case 53:case 54:case 55:case 56:case 57:M*=16,M+=B-48;break;case 59:U=W9;break;default:V$(B,W9);break}}function gH(B){switch(B){case 48:case 49:case 50:case 51:case 52:case 53:case 54:case 55:case 56:case 57:M*=10,M+=B-48;break;case 59:U=W9;break;default:V$(B,W9);break}}function W9(B){if(M in Sj)M=Sj[M];else if(M>1114111||M>=55296&&M<57344)M=65533;if(r$(),M<=65535)P.push(M);else M=M-65536,P.push(55296+(M>>10)),P.push(56320+(M&1023));V$(B,P2)}function P2(B){switch(z){case Z9:case Y9:case K9:L+=N0(P);break;default:t2(y,P);break}V$(B,z)}function fH(B,O,w,E){switch(B){case 1:if(O=O.replace(e2,""),O.length===0)return;break;case 4:l._appendChild(l.createComment(O));return;case 5:var h=O,c=w,U$=E;if(l.appendChild(new EP(l,h,c,U$)),W$||h.toLowerCase()!=="html"||vP.test(c)||U$&&U$.toLowerCase()===hP||U$===void 0&&Dj.test(c))l._quirks=!0;else if(gP.test(c)||U$!==void 0&&Dj.test(c))l._limitedQuirks=!0;A=e3;return}l._quirks=!0,A=e3,A(B,O,w,E)}function e3(B,O,w,E){var h;switch(B){case 1:if(O=O.replace(e2,""),O.length===0)return;break;case 5:return;case 4:l._appendChild(l.createComment(O));return;case 2:if(O==="html"){h=sJ(l,O,w),S.push(h),l.appendChild(h),A=j9;return}break;case 3:switch(O){case"html":case"head":case"body":case"br":break;default:return}}h=sJ(l,"html",null),S.push(h),l.appendChild(h),A=j9,A(B,O,w,E)}function j9(B,O,w,E){switch(B){case 1:if(O=O.replace(e2,""),O.length===0)return;break;case 5:return;case 4:D1(O);return;case 2:switch(O){case"html":j$(B,O,w,E);return;case"head":var h=q$(O,w);A$=h,A=Q0;return}break;case 3:switch(O){case"html":case"head":case"body":case"br":break;default:return}}j9(L0,"head",null),A(B,O,w,E)}function Q0(B,O,w,E){switch(B){case 1:var h=O.match(e2);if(h)P1(h[0]),O=O.substring(h[0].length);if(O.length===0)return;break;case 4:D1(O);return;case 5:return;case 2:switch(O){case"html":j$(B,O,w,E);return;case"meta":case"base":case"basefont":case"bgsound":case"link":q$(O,w),S.pop();return;case"title":sB(O,w);return;case"noscript":if(!J$){q$(O,w),A=$K;return}case"noframes":case"style":$9(O,w);return;case"script":t8(function(c){var U$=sJ(c,O,w);if(U$._parser_inserted=!0,U$._force_async=!1,k)U$._already_started=!0;return VJ(),U$}),U=Z2,u=A,A=U9;return;case"template":q$(O,w),T.insertMarker(),Z$=!1,A=g6,r.push(A);return;case"head":return}break;case 3:switch(O){case"head":S.pop(),A=v6;return;case"body":case"html":case"br":break;case"template":if(!S.contains("template"))return;S.generateImpliedEndTags(null,"thorough"),S.popTag("template"),T.clearToMarker(),r.pop(),nJ();return;default:return}break}Q0(N$,"head",null),A(B,O,w,E)}function $K(B,O,w,E){switch(B){case 5:return;case 4:Q0(B,O);return;case 1:var h=O.match(e2);if(h)Q0(B,h[0]),O=O.substring(h[0].length);if(O.length===0)return;break;case 2:switch(O){case"html":j$(B,O,w,E);return;case"basefont":case"bgsound":case"link":case"meta":case"noframes":case"style":Q0(B,O,w);return;case"head":case"noscript":return}break;case 3:switch(O){case"noscript":S.pop(),A=Q0;return;case"br":break;default:return}break}$K(N$,"noscript",null),A(B,O,w,E)}function v6(B,O,w,E){switch(B){case 1:var h=O.match(e2);if(h)P1(h[0]),O=O.substring(h[0].length);if(O.length===0)return;break;case 4:D1(O);return;case 5:return;case 2:switch(O){case"html":j$(B,O,w,E);return;case"body":q$(O,w),Z$=!1,A=j$;return;case"frameset":q$(O,w),A=f6;return;case"base":case"basefont":case"bgsound":case"link":case"meta":case"noframes":case"script":case"style":case"template":case"title":S.push(A$),Q0(L0,O,w),S.removeElement(A$);return;case"head":return}break;case 3:switch(O){case"template":return Q0(B,O,w,E);case"body":case"html":case"br":break;default:return}break}v6(L0,"body",null),Z$=!0,A(B,O,w,E)}function j$(B,O,w,E){var h,c,U$,w$;switch(B){case 1:if(n){if(O=O.replace(G6,""),O.length===0)return}if(Z$&&V6.test(O))Z$=!1;T0(),P1(O);return;case 5:return;case 4:D1(O);return;case-1:if(r.length)return g6(B);M2();return;case 2:switch(O){case"html":if(S.contains("template"))return;xj(w,S.elements[0]);return;case"base":case"basefont":case"bgsound":case"link":case"meta":case"noframes":case"script":case"style":case"template":case"title":Q0(L0,O,w);return;case"body":if(h=S.elements[1],!h||!(h instanceof u$.HTMLBodyElement)||S.contains("template"))return;Z$=!1,xj(w,h);return;case"frameset":if(!Z$)return;if(h=S.elements[1],!h||!(h instanceof u$.HTMLBodyElement))return;if(h.parentNode)h.parentNode.removeChild(h);while(!(S.top instanceof u$.HTMLHtmlElement))S.pop();q$(O,w),A=f6;return;case"address":case"article":case"aside":case"blockquote":case"center":case"details":case"dialog":case"dir":case"div":case"dl":case"fieldset":case"figcaption":case"figure":case"footer":case"header":case"hgroup":case"main":case"nav":case"ol":case"p":case"section":case"summary":case"ul":if(S.inButtonScope("p"))j$(N$,"p");q$(O,w);return;case"menu":if(S.inButtonScope("p"))j$(N$,"p");if(d$(S.top,"menuitem"))S.pop();q$(O,w);return;case"h1":case"h2":case"h3":case"h4":case"h5":case"h6":if(S.inButtonScope("p"))j$(N$,"p");if(S.top instanceof u$.HTMLHeadingElement)S.pop();q$(O,w);return;case"pre":case"listing":if(S.inButtonScope("p"))j$(N$,"p");q$(O,w),a=!0,Z$=!1;return;case"form":if(s&&!S.contains("template"))return;if(S.inButtonScope("p"))j$(N$,"p");if(w$=q$(O,w),!S.contains("template"))s=w$;return;case"li":Z$=!1;for(c=S.elements.length-1;c>=0;c--){if(U$=S.elements[c],U$ instanceof u$.HTMLLIElement){j$(N$,"li");break}if(d$(U$,$J)&&!d$(U$,K3))break}if(S.inButtonScope("p"))j$(N$,"p");q$(O,w);return;case"dd":case"dt":Z$=!1;for(c=S.elements.length-1;c>=0;c--){if(U$=S.elements[c],d$(U$,vj)){j$(N$,U$.localName);break}if(d$(U$,$J)&&!d$(U$,K3))break}if(S.inButtonScope("p"))j$(N$,"p");q$(O,w);return;case"plaintext":if(S.inButtonScope("p"))j$(N$,"p");q$(O,w),U=L6;return;case"button":if(S.inScope("button"))j$(N$,"button"),A(B,O,w,E);else T0(),q$(O,w),Z$=!1;return;case"a":var J0=T.findElementByTag("a");if(J0)j$(N$,O),T.remove(J0),S.removeElement(J0);case"b":case"big":case"code":case"em":case"font":case"i":case"s":case"small":case"strike":case"strong":case"tt":case"u":T0(),T.push(q$(O,w),w);return;case"nobr":if(T0(),S.inScope(O))j$(N$,O),T0();T.push(q$(O,w),w);return;case"applet":case"marquee":case"object":T0(),q$(O,w),T.insertMarker(),Z$=!1;return;case"table":if(!l._quirks&&S.inButtonScope("p"))j$(N$,"p");q$(O,w),Z$=!1,A=i0;return;case"area":case"br":case"embed":case"img":case"keygen":case"wbr":T0(),q$(O,w),S.pop(),Z$=!1;return;case"input":T0(),w$=q$(O,w),S.pop();var M0=w$.getAttribute("type");if(!M0||M0.toLowerCase()!=="hidden")Z$=!1;return;case"param":case"source":case"track":q$(O,w),S.pop();return;case"hr":if(S.inButtonScope("p"))j$(N$,"p");if(d$(S.top,"menuitem"))S.pop();q$(O,w),S.pop(),Z$=!1;return;case"image":j$(L0,"img",w,E);return;case"textarea":q$(O,w),a=!0,Z$=!1,U=J2,u=A,A=U9;return;case"xmp":if(S.inButtonScope("p"))j$(N$,"p");T0(),Z$=!1,$9(O,w);return;case"iframe":Z$=!1,$9(O,w);return;case"noembed":$9(O,w);return;case"select":if(T0(),q$(O,w),Z$=!1,A===i0||A===h6||A===I2||A===eJ||A===GJ)A=H9;else A=E1;return;case"optgroup":case"option":if(S.top instanceof u$.HTMLOptionElement)j$(N$,"option");T0(),q$(O,w);return;case"menuitem":if(d$(S.top,"menuitem"))S.pop();T0(),q$(O,w);return;case"rb":case"rtc":if(S.inScope("ruby"))S.generateImpliedEndTags();q$(O,w);return;case"rp":case"rt":if(S.inScope("ruby"))S.generateImpliedEndTags("rtc");q$(O,w);return;case"math":if(T0(),Ej(w),Y3(w),w6(O,w,X$.MATHML),E)S.pop();return;case"svg":if(T0(),kj(w),Y3(w),w6(O,w,X$.SVG),E)S.pop();return;case"caption":case"col":case"colgroup":case"frame":case"head":case"tbody":case"td":case"tfoot":case"th":case"thead":case"tr":return}T0(),q$(O,w);return;case 3:switch(O){case"template":Q0(N$,O,w);return;case"body":if(!S.inScope("body"))return;A=JK;return;case"html":if(!S.inScope("body"))return;A=JK,A(B,O,w);return;case"address":case"article":case"aside":case"blockquote":case"button":case"center":case"details":case"dialog":case"dir":case"div":case"dl":case"fieldset":case"figcaption":case"figure":case"footer":case"header":case"hgroup":case"listing":case"main":case"menu":case"nav":case"ol":case"pre":case"section":case"summary":case"ul":if(!S.inScope(O))return;S.generateImpliedEndTags(),S.popTag(O);return;case"form":if(!S.contains("template")){var s0=s;if(s=null,!s0||!S.elementInScope(s0))return;S.generateImpliedEndTags(),S.removeElement(s0)}else{if(!S.inScope("form"))return;S.generateImpliedEndTags(),S.popTag("form")}return;case"p":if(!S.inButtonScope(O))j$(L0,O,null),A(B,O,w,E);else S.generateImpliedEndTags(O),S.popTag(O);return;case"li":if(!S.inListItemScope(O))return;S.generateImpliedEndTags(O),S.popTag(O);return;case"dd":case"dt":if(!S.inScope(O))return;S.generateImpliedEndTags(O),S.popTag(O);return;case"h1":case"h2":case"h3":case"h4":case"h5":case"h6":if(!S.elementTypeInScope(u$.HTMLHeadingElement))return;S.generateImpliedEndTags(),S.popElementType(u$.HTMLHeadingElement);return;case"sarcasm":break;case"a":case"b":case"big":case"code":case"em":case"font":case"i":case"nobr":case"s":case"small":case"strike":case"strong":case"tt":case"u":var X1=nB(O);if(X1)return;break;case"applet":case"marquee":case"object":if(!S.inScope(O))return;S.generateImpliedEndTags(),S.popTag(O),T.clearToMarker();return;case"br":j$(L0,O,null);return}for(c=S.elements.length-1;c>=0;c--)if(U$=S.elements[c],d$(U$,O)){S.generateImpliedEndTags(O),S.popElement(U$);break}else if(d$(U$,$J))return;return}}function U9(B,O,w,E){switch(B){case 1:P1(O);return;case-1:if(S.top instanceof u$.HTMLScriptElement)S.top._already_started=!0;S.pop(),A=u,A(B);return;case 3:if(O==="script")aB();else S.pop(),A=u;return;default:return}}function i0(B,O,w,E){function h(U$){for(var w$=0,J0=U$.length;w$<J0;w$++)if(U$[w$][0]==="type")return U$[w$][1].toLowerCase();return null}switch(B){case 1:if(Q$){j$(B,O,w,E);return}else if(d$(S.top,lJ)){y$=[],u=A,A=mH,A(B,O,w,E);return}break;case 4:D1(O);return;case 5:return;case 2:switch(O){case"caption":S.clearToContext(X6),T.insertMarker(),q$(O,w),A=h6;return;case"colgroup":S.clearToContext(X6),q$(O,w),A=B9;return;case"col":i0(L0,"colgroup",null),A(B,O,w,E);return;case"tbody":case"tfoot":case"thead":S.clearToContext(X6),q$(O,w),A=I2;return;case"td":case"th":case"tr":i0(L0,"tbody",null),A(B,O,w,E);return;case"table":if(!S.inTableScope(O))return;i0(N$,O),A(B,O,w,E);return;case"style":case"script":case"template":Q0(B,O,w,E);return;case"input":var c=h(w);if(c!=="hidden")break;q$(O,w),S.pop();return;case"form":if(s||S.contains("template"))return;s=q$(O,w),S.popElement(s);return}break;case 3:switch(O){case"table":if(!S.inTableScope(O))return;S.popTag(O),nJ();return;case"body":case"caption":case"col":case"colgroup":case"html":case"tbody":case"td":case"tfoot":case"th":case"thead":case"tr":return;case"template":Q0(B,O,w,E);return}break;case-1:j$(B,O,w,E);return}$2=!0,j$(B,O,w,E),$2=!1}function mH(B,O,w,E){if(B===cJ){if(n){if(O=O.replace(G6,""),O.length===0)return}y$.push(O)}else{var h=y$.join("");if(y$.length=0,V6.test(h))$2=!0,j$(cJ,h),$2=!1;else P1(h);A=u,A(B,O,w,E)}}function h6(B,O,w,E){function h(){if(!S.inTableScope("caption"))return!1;return S.generateImpliedEndTags(),S.popTag("caption"),T.clearToMarker(),A=i0,!0}switch(B){case 2:switch(O){case"caption":case"col":case"colgroup":case"tbody":case"td":case"tfoot":case"th":case"thead":case"tr":if(h())A(B,O,w,E);return}break;case 3:switch(O){case"caption":h();return;case"table":if(h())A(B,O,w,E);return;case"body":case"col":case"colgroup":case"html":case"tbody":case"td":case"tfoot":case"th":case"thead":case"tr":return}break}j$(B,O,w,E)}function B9(B,O,w,E){switch(B){case 1:var h=O.match(e2);if(h)P1(h[0]),O=O.substring(h[0].length);if(O.length===0)return;break;case 4:D1(O);return;case 5:return;case 2:switch(O){case"html":j$(B,O,w,E);return;case"col":q$(O,w),S.pop();return;case"template":Q0(B,O,w,E);return}break;case 3:switch(O){case"colgroup":if(!d$(S.top,"colgroup"))return;S.pop(),A=i0;return;case"col":return;case"template":Q0(B,O,w,E);return}break;case-1:j$(B,O,w,E);return}if(!d$(S.top,"colgroup"))return;B9(N$,"colgroup"),A(B,O,w,E)}function I2(B,O,w,E){function h(){if(!S.inTableScope("tbody")&&!S.inTableScope("thead")&&!S.inTableScope("tfoot"))return;S.clearToContext(W6),I2(N$,S.top.localName,null),A(B,O,w,E)}switch(B){case 2:switch(O){case"tr":S.clearToContext(W6),q$(O,w),A=eJ;return;case"th":case"td":I2(L0,"tr",null),A(B,O,w,E);return;case"caption":case"col":case"colgroup":case"tbody":case"tfoot":case"thead":h();return}break;case 3:switch(O){case"table":h();return;case"tbody":case"tfoot":case"thead":if(S.inTableScope(O))S.clearToContext(W6),S.pop(),A=i0;return;case"body":case"caption":case"col":case"colgroup":case"html":case"td":case"th":case"tr":return}break}i0(B,O,w,E)}function eJ(B,O,w,E){function h(){if(!S.inTableScope("tr"))return!1;return S.clearToContext(Q3),S.pop(),A=I2,!0}switch(B){case 2:switch(O){case"th":case"td":S.clearToContext(Q3),q$(O,w),A=GJ,T.insertMarker();return;case"caption":case"col":case"colgroup":case"tbody":case"tfoot":case"thead":case"tr":if(h())A(B,O,w,E);return}break;case 3:switch(O){case"tr":h();return;case"table":if(h())A(B,O,w,E);return;case"tbody":case"tfoot":case"thead":if(S.inTableScope(O)){if(h())A(B,O,w,E)}return;case"body":case"caption":case"col":case"colgroup":case"html":case"td":case"th":return}break}i0(B,O,w,E)}function GJ(B,O,w,E){switch(B){case 2:switch(O){case"caption":case"col":case"colgroup":case"tbody":case"td":case"tfoot":case"th":case"thead":case"tr":if(S.inTableScope("td"))GJ(N$,"td"),A(B,O,w,E);else if(S.inTableScope("th"))GJ(N$,"th"),A(B,O,w,E);return}break;case 3:switch(O){case"td":case"th":if(!S.inTableScope(O))return;S.generateImpliedEndTags(),S.popTag(O),T.clearToMarker(),A=eJ;return;case"body":case"caption":case"col":case"colgroup":case"html":return;case"table":case"tbody":case"tfoot":case"thead":case"tr":if(!S.inTableScope(O))return;GJ(N$,S.inTableScope("td")?"td":"th"),A(B,O,w,E);return}break}j$(B,O,w,E)}function E1(B,O,w,E){switch(B){case 1:if(n){if(O=O.replace(G6,""),O.length===0)return}P1(O);return;case 4:D1(O);return;case 5:return;case-1:j$(B,O,w,E);return;case 2:switch(O){case"html":j$(B,O,w,E);return;case"option":if(S.top instanceof u$.HTMLOptionElement)E1(N$,O);q$(O,w);return;case"optgroup":if(S.top instanceof u$.HTMLOptionElement)E1(N$,"option");if(S.top instanceof u$.HTMLOptGroupElement)E1(N$,O);q$(O,w);return;case"select":E1(N$,O);return;case"input":case"keygen":case"textarea":if(!S.inSelectScope("select"))return;E1(N$,"select"),A(B,O,w,E);return;case"script":case"template":Q0(B,O,w,E);return}break;case 3:switch(O){case"optgroup":if(S.top instanceof u$.HTMLOptionElement&&S.elements[S.elements.length-2]instanceof u$.HTMLOptGroupElement)E1(N$,"option");if(S.top instanceof u$.HTMLOptGroupElement)S.pop();return;case"option":if(S.top instanceof u$.HTMLOptionElement)S.pop();return;case"select":if(!S.inSelectScope(O))return;S.popTag(O),nJ();return;case"template":Q0(B,O,w,E);return}break}}function H9(B,O,w,E){switch(O){case"caption":case"table":case"tbody":case"tfoot":case"thead":case"tr":case"td":case"th":switch(B){case 2:H9(N$,"select"),A(B,O,w,E);return;case 3:if(S.inTableScope(O))H9(N$,"select"),A(B,O,w,E);return}}E1(B,O,w,E)}function g6(B,O,w,E){function h(c){A=c,r[r.length-1]=A,A(B,O,w,E)}switch(B){case 1:case 4:case 5:j$(B,O,w,E);return;case-1:if(!S.contains("template"))M2();else S.popTag("template"),T.clearToMarker(),r.pop(),nJ(),A(B,O,w,E);return;case 2:switch(O){case"base":case"basefont":case"bgsound":case"link":case"meta":case"noframes":case"script":case"style":case"template":case"title":Q0(B,O,w,E);return;case"caption":case"colgroup":case"tbody":case"tfoot":case"thead":h(i0);return;case"col":h(B9);return;case"tr":h(I2);return;case"td":case"th":h(eJ);return}h(j$);return;case 3:switch(O){case"template":Q0(B,O,w,E);return;default:return}}}function JK(B,O,w,E){switch(B){case 1:if(V6.test(O))break;j$(B,O);return;case 4:S.elements[0]._appendChild(l.createComment(O));return;case 5:return;case-1:M2();return;case 2:if(O==="html"){j$(B,O,w,E);return}break;case 3:if(O==="html"){if(k)return;A=dH;return}break}A=j$,A(B,O,w,E)}function f6(B,O,w,E){switch(B){case 1:if(O=O.replace(Z3,""),O.length>0)P1(O);return;case 4:D1(O);return;case 5:return;case-1:M2();return;case 2:switch(O){case"html":j$(B,O,w,E);return;case"frameset":q$(O,w);return;case"frame":q$(O,w),S.pop();return;case"noframes":Q0(B,O,w,E);return}break;case 3:if(O==="frameset"){if(k&&S.top instanceof u$.HTMLHtmlElement)return;if(S.pop(),!k&&!(S.top instanceof u$.HTMLFrameSetElement))A=uH;return}break}}function uH(B,O,w,E){switch(B){case 1:if(O=O.replace(Z3,""),O.length>0)P1(O);return;case 4:D1(O);return;case 5:return;case-1:M2();return;case 2:switch(O){case"html":j$(B,O,w,E);return;case"noframes":Q0(B,O,w,E);return}break;case 3:if(O==="html"){A=pH;return}break}}function dH(B,O,w,E){switch(B){case 1:if(V6.test(O))break;j$(B,O,w,E);return;case 4:l._appendChild(l.createComment(O));return;case 5:j$(B,O,w,E);return;case-1:M2();return;case 2:if(O==="html"){j$(B,O,w,E);return}break}A=j$,A(B,O,w,E)}function pH(B,O,w,E){switch(B){case 1:if(O=O.replace(Z3,""),O.length>0)j$(B,O,w,E);return;case 4:l._appendChild(l.createComment(O));return;case 5:j$(B,O,w,E);return;case-1:M2();return;case 2:switch(O){case"html":j$(B,O,w,E);return;case"noframes":Q0(B,O,w,E);return}break}}function ZK(B,O,w,E){function h(J0){for(var M0=0,s0=J0.length;M0<s0;M0++)switch(J0[M0][0]){case"color":case"face":case"size":return!0}return!1}var c;switch(B){case 1:if(Z$&&nP.test(O))Z$=!1;if(n)O=O.replace(G6,"\uFFFD");P1(O);return;case 4:D1(O);return;case 5:return;case 2:switch(O){case"font":if(!h(w))break;case"b":case"big":case"blockquote":case"body":case"br":case"center":case"code":case"dd":case"div":case"dl":case"dt":case"em":case"embed":case"h1":case"h2":case"h3":case"h4":case"h5":case"h6":case"head":case"hr":case"i":case"img":case"li":case"listing":case"menu":case"meta":case"nobr":case"ol":case"p":case"pre":case"ruby":case"s":case"small":case"span":case"strong":case"strike":case"sub":case"sup":case"table":case"tt":case"u":case"ul":case"var":if(k)break;do S.pop(),c=S.top;while(c.namespaceURI!==X$.HTML&&!yj(c)&&!Tj(c));j0(B,O,w,E);return}if(c=S.elements.length===1&&k?J:S.top,c.namespaceURI===X$.MATHML)Ej(w);else if(c.namespaceURI===X$.SVG)O=tP(O),kj(w);if(Y3(w),w6(O,w,c.namespaceURI),E){if(O==="script"&&c.namespaceURI===X$.SVG);S.pop()}return;case 3:if(c=S.top,O==="script"&&c.namespaceURI===X$.SVG&&c.localName==="script")S.pop();else{var U$=S.elements.length-1,w$=S.elements[U$];for(;;){if(w$.localName.toLowerCase()===O){S.popElement(w$);break}if(w$=S.elements[--U$],w$.namespaceURI!==X$.HTML)continue;A(B,O,w,E);break}}return}}return c$.testTokenizer=function(B,O,w,E){var h=[];switch(O){case"PCDATA state":U=S$;break;case"RCDATA state":U=J2;break;case"RAWTEXT state":U=aJ;break;case"PLAINTEXT state":U=L6;break}if(w)C=w;if(j0=function(U$,w$,J0,M0){switch(VJ(),U$){case 1:if(h.length>0&&h[h.length-1][0]==="Character")h[h.length-1][1]+=w$;else h.push(["Character",w$]);break;case 4:h.push(["Comment",w$]);break;case 5:h.push(["DOCTYPE",w$,J0===void 0?null:J0,M0===void 0?null:M0,!W$]);break;case 2:var s0=Object.create(null);for(var X1=0;X1<J0.length;X1++){var A2=J0[X1];if(A2.length===1)s0[A2[0]]="";else s0[A2[0]]=A2[1]}var V2=["StartTag",w$,s0];if(M0)V2.push(!0);h.push(V2);break;case 3:h.push(["EndTag",w$]);break;case-1:break}},!E)this.parse(B,!0);else{for(var c=0;c<B.length;c++)this.parse(B[c]);this.parse("",!0)}return h},c$}});var m8=p((Xv,rj)=>{rj.exports=oj;var cj=Z6(),lj=K6(),eP=U6(),B6=X0(),$I=uZ();function oj($){this.contextObject=$}var JI={xml:{"":!0,"1.0":!0,"2.0":!0},core:{"":!0,"2.0":!0},html:{"":!0,"1.0":!0,"2.0":!0},xhtml:{"":!0,"1.0":!0,"2.0":!0}};oj.prototype={hasFeature:function(J,Z){var Y=JI[(J||"").toLowerCase()];return Y&&Y[Z||""]||!1},createDocumentType:function(J,Z,Y){if(!$I.isValidQName(J))B6.InvalidCharacterError();return new lj(this.contextObject,J,Z,Y)},createDocument:function(J,Z,Y){var K=new cj(!1,null),Q;if(Z)Q=K.createElementNS(J,Z);else Q=null;if(Y)K.appendChild(Y);if(Q)K.appendChild(Q);if(J===B6.NAMESPACE.HTML)K._contentType="application/xhtml+xml";else if(J===B6.NAMESPACE.SVG)K._contentType="image/svg+xml";else K._contentType="application/xml";return K},createHTMLDocument:function(J){var Z=new cj(!0,null);Z.appendChild(new lj(Z,"html"));var Y=Z.createElement("html");Z.appendChild(Y);var K=Z.createElement("head");if(Y.appendChild(K),J!==void 0){var Q=Z.createElement("title");K.appendChild(Q),Q.appendChild(Z.createTextNode(J))}return Y.appendChild(Z.createElement("body")),Z.modclock=1,Z},mozSetOutputMutationHandler:function($,J){$.mutationHandler=J},mozGetInputMutationHandler:function($){B6.nyi()},mozHTMLParser:eP}});var sj=p((Wv,ij)=>{var ZI=aZ(),YI=rY();ij.exports=G3;function G3($,J){this._window=$,this._href=J}G3.prototype=Object.create(YI.prototype,{constructor:{value:G3},href:{get:function(){return this._href},set:function($){this.assign($)}},assign:{value:function($){var J=new ZI(this._href),Z=J.resolve($);this._href=Z}},replace:{value:function($){this.assign($)}},reload:{value:function(){this.assign(this.href)}},toString:{value:function(){return this.href}}})});var aj=p((jv,nj)=>{var KI=Object.create(null,{appCodeName:{value:"Mozilla"},appName:{value:"Netscape"},appVersion:{value:"4.0"},platform:{value:""},product:{value:"Gecko"},productSub:{value:"20100101"},userAgent:{value:""},vendor:{value:""},vendorSub:{value:""},taintEnabled:{value:function(){return!1}}});nj.exports=KI});var ej=p((Uv,tj)=>{var QI={setTimeout,clearTimeout,setInterval,clearInterval};tj.exports=QI});var W3=p((u8,$U)=>{var X3=X0();u8=$U.exports={CSSStyleDeclaration:tZ(),CharacterData:T8(),Comment:EY(),DOMException:vZ(),DOMImplementation:m8(),DOMTokenList:qY(),Document:Z6(),DocumentFragment:bY(),DocumentType:K6(),Element:gJ(),HTMLParser:U6(),NamedNodeMap:PY(),Node:P0(),NodeList:n2(),NodeFilter:b8(),ProcessingInstruction:hY(),Text:TY(),Window:j3()};X3.merge(u8,oY());X3.merge(u8,$6().elements);X3.merge(u8,tY().elements)});var j3=p((Bv,JU)=>{var VI=m8(),GI=$Y(),XI=sj(),d8=X0();JU.exports=H6;function H6($){this.document=$||new VI(null).createHTMLDocument(""),this.document._scripting_enabled=!0,this.document.defaultView=this,this.location=new XI(this,this.document._address||"about:blank")}H6.prototype=Object.create(GI.prototype,{console:{value:console},history:{value:{back:d8.nyi,forward:d8.nyi,go:d8.nyi}},navigator:{value:aj()},window:{get:function(){return this}},self:{get:function(){return this}},frames:{get:function(){return this}},parent:{get:function(){return this}},top:{get:function(){return this}},length:{value:0},frameElement:{value:null},opener:{value:null},onload:{get:function(){return this._getEventHandler("load")},set:function($){this._setEventHandler("load",$)}},getComputedStyle:{value:function(J){return J.style}}});d8.expose(ej(),H6);d8.expose(W3(),H6)});var VU=p((WI)=>{var ZU=m8(),YU=U6(),Hv=j3(),KU=W3();WI.createDOMImplementation=function(){return new ZU(null)};WI.createDocument=function($,J){if($||J){var Z=new YU;return Z.parse($||"",!0),Z.document()}return new ZU(null).createHTMLDocument("")};WI.createIncrementalHTMLParser=function(){var $=new YU;return{write:function(J){if(J.length>0)$.parse(J,!1,function(){return!0})},end:function(J){$.parse(J||"",!0,function(){return!0})},process:function(J){return $.parse("",!1,J)},document:function(){return $.document()}}};WI.createWindow=function($,J){var Z=WI.createDocument($);if(J!==void 0)Z._address=J;return new KU.Window(Z)};WI.impl=KU});var W1={};o$(W1,{layer:()=>GK,defaultLayer:()=>z_,Status:()=>F_,Service:()=>q9,Format:()=>W1});import q_ from"path";var O9={};o$(O9,{zig:()=>nH,uvformat:()=>$_,terraform:()=>V_,standardrb:()=>Z_,shfmt:()=>W_,rustfmt:()=>U_,ruff:()=>QK,rubocop:()=>J_,rlang:()=>eH,prettier:()=>rH,pint:()=>B_,oxfmt:()=>iH,ormolu:()=>H_,ocamlformat:()=>Q_,nixfmt:()=>j_,mix:()=>oH,latexindent:()=>G_,ktlint:()=>tH,htmlbeautifier:()=>Y_,gofmt:()=>lH,gleam:()=>X_,dfmt:()=>O_,dart:()=>K_,cljfmt:()=>__,clang:()=>aH,biome:()=>sH});var lH={name:"gofmt",extensions:[".go"],async enabled(){let $=x$("gofmt");if(!$)return!1;return[$,"-w","$FILE"]}},oH={name:"mix",extensions:[".ex",".exs",".eex",".heex",".leex",".neex",".sface"],async enabled(){let $=x$("mix");if(!$)return!1;return[$,"format","$FILE"]}},YK=[".js",".jsx",".mjs",".cjs",".ts",".tsx",".mts",".cts",".html",".htm",".css",".scss",".sass",".less",".vue",".svelte",".json",".jsonc",".yaml",".yml",".toml",".xml",".md",".mdx",".graphql",".gql"];async function KK($,J){let Z=await O0.findUp("package.json",$.directory,$.worktree);for(let Y of Z){let K=await O0.readJson(Y);if(K.dependencies?.[J]||K.devDependencies?.[J]){let Q=await m6.which(J);if(Q)return Q}}return}var rH={name:"prettier",environment:{BUN_BE_BUN:"1"},extensions:[...YK],async enabled($){let J=await KK($,"prettier");return J?[J,"--write","$FILE"]:!1}},iH={name:"oxfmt",environment:{BUN_BE_BUN:"1"},extensions:[".js",".jsx",".mjs",".cjs",".ts",".tsx",".mts",".cts"],async enabled($){if(!k$.QITQODE_EXPERIMENTAL_OXFMT)return!1;let J=await KK($,"oxfmt");return J?[J,"$FILE"]:!1}},sH={name:"biome",environment:{BUN_BE_BUN:"1"},extensions:[...YK],async enabled($){let J=["biome.json","biome.jsonc"];for(let Z of J)if((await O0.findUp(Z,$.directory,$.worktree)).length>0){let K=await m6.which("@biomejs/biome");if(K)return[K,"format","--write","$FILE"]}return!1}},nH={name:"zig",extensions:[".zig",".zon"],async enabled(){let $=x$("zig");if(!$)return!1;return[$,"fmt","$FILE"]}},aH={name:"clang-format",extensions:[".c",".cc",".cpp",".cxx",".c++",".h",".hh",".hpp",".hxx",".h++",".ino",".C",".H"],async enabled($){if((await O0.findUp(".clang-format",$.directory,$.worktree)).length>0){let Z=x$("clang-format");if(Z)return[Z,"-i","$FILE"]}return!1}},tH={name:"ktlint",extensions:[".kt",".kts"],async enabled(){let $=x$("ktlint");if(!$)return!1;return[$,"-F","$FILE"]}},QK={name:"ruff",extensions:[".py",".pyi"],async enabled($){if(!x$("ruff"))return!1;let J=["pyproject.toml","ruff.toml",".ruff.toml"];for(let Y of J){let K=await O0.findUp(Y,$.directory,$.worktree);if(K.length>0)if(Y==="pyproject.toml"){if((await O0.readText(K[0])).includes("[tool.ruff]"))return["ruff","format","$FILE"]}else return["ruff","format","$FILE"]}let Z=["requirements.txt","pyproject.toml","Pipfile"];for(let Y of Z){let K=await O0.findUp(Y,$.directory,$.worktree);if(K.length>0){if((await O0.readText(K[0])).includes("ruff"))return["ruff","format","$FILE"]}}return!1}},eH={name:"air",extensions:[".R"],async enabled(){let $=x$("air");if($==null)return!1;let J=await _9.text([$,"--help"],{nothrow:!0}),Z=J.text.split(`
|
|
37
|
+
`)[0],Y=Z.includes("R language"),K=Z.includes("formatter");if(J.code===0&&Y&&K)return[$,"format","$FILE"];return!1}},$_={name:"uv",extensions:[".py",".pyi"],async enabled($){if(await QK.enabled($))return!1;let J=x$("uv");if(J==null)return!1;if((await _9.run([J,"format","--help"],{nothrow:!0})).code===0)return[J,"format","--","$FILE"];return!1}},J_={name:"rubocop",extensions:[".rb",".rake",".gemspec",".ru"],async enabled(){let $=x$("rubocop");if(!$)return!1;return[$,"--autocorrect","$FILE"]}},Z_={name:"standardrb",extensions:[".rb",".rake",".gemspec",".ru"],async enabled(){let $=x$("standardrb");if(!$)return!1;return[$,"--fix","$FILE"]}},Y_={name:"htmlbeautifier",extensions:[".erb",".html.erb"],async enabled(){let $=x$("htmlbeautifier");if(!$)return!1;return[$,"$FILE"]}},K_={name:"dart",extensions:[".dart"],async enabled(){let $=x$("dart");if(!$)return!1;return[$,"format","$FILE"]}},Q_={name:"ocamlformat",extensions:[".ml",".mli"],async enabled($){if(!x$("ocamlformat"))return!1;if((await O0.findUp(".ocamlformat",$.directory,$.worktree)).length>0)return["ocamlformat","-i","$FILE"];return!1}},V_={name:"terraform",extensions:[".tf",".tfvars"],async enabled(){let $=x$("terraform");if(!$)return!1;return[$,"fmt","$FILE"]}},G_={name:"latexindent",extensions:[".tex"],async enabled(){let $=x$("latexindent");if(!$)return!1;return[$,"-w","-s","$FILE"]}},X_={name:"gleam",extensions:[".gleam"],async enabled(){let $=x$("gleam");if(!$)return!1;return[$,"format","$FILE"]}},W_={name:"shfmt",extensions:[".sh",".bash"],async enabled(){let $=x$("shfmt");if(!$)return!1;return[$,"-w","$FILE"]}},j_={name:"nixfmt",extensions:[".nix"],async enabled(){let $=x$("nixfmt");if(!$)return!1;return[$,"$FILE"]}},U_={name:"rustfmt",extensions:[".rs"],async enabled(){let $=x$("rustfmt");if(!$)return!1;return[$,"$FILE"]}},B_={name:"pint",extensions:[".php"],async enabled($){let J=await O0.findUp("composer.json",$.directory,$.worktree);for(let Z of J){let Y=await O0.readJson(Z);if(Y.require?.["laravel/pint"]||Y["require-dev"]?.["laravel/pint"])return["./vendor/bin/pint","$FILE"]}return!1}},H_={name:"ormolu",extensions:[".hs"],async enabled(){let $=x$("ormolu");if(!$)return!1;return[$,"-i","$FILE"]}},__={name:"cljfmt",extensions:[".clj",".cljs",".cljc",".edn"],async enabled(){let $=x$("cljfmt");if(!$)return!1;return[$,"fix","--quiet","$FILE"]}},O_={name:"dfmt",extensions:[".d"],async enabled(){let $=x$("dfmt");if(!$)return!1;return[$,"-i","$FILE"]}};var x1=O$.create({service:"format"}),F_=F.object({name:F.string(),extensions:F.string().array(),enabled:F.boolean()}).meta({ref:"FormatterStatus"});class q9 extends D$.Service()("@qitqode/Format"){}var GK=f.effect(q9,G.gen(function*(){let $=yield*R$.Service,J=yield*u6.ChildProcessSpawner,Z=yield*i.make(G.fn("Format.state")(function*(V){let X={},W={};async function _(z){let M=X[z.name];if(M===!1||M===void 0)M=await z.enabled(V),X[z.name]=M;return M}async function j(z){return await _(z)!==!1}async function H(z){let M=Object.values(W).filter((C)=>C.extensions.includes(z));return(await Promise.all(M.map(async(C)=>{x1.info("checking",{name:C.name,ext:z});let P=await _(C);if(P)x1.info("enabled",{name:C.name,ext:z});return{item:C,cmd:P}}))).filter((C)=>C.cmd).map((C)=>({item:C.item,cmd:C.cmd}))}function q(z){return G.gen(function*(){x1.info("formatting",{file:z});let M=q_.extname(z);for(let{item:I,cmd:C}of yield*G.promise(()=>H(M))){if(C===!1)continue;x1.info("running",{command:C});let P=C.map((R)=>R.replace("$FILE",z)),D=yield*i.directory;if((yield*J.spawn(S1.make(P[0],P.slice(1),{cwd:D,env:I.environment,extendEnv:!0})).pipe(G.flatMap((R)=>R.exitCode),G.scoped,G.catch(()=>G.sync(()=>{return x1.error("failed to format file",{error:"spawn failed",command:C,...I.environment,file:z}),u6.ExitCode(1)}))))!==0)x1.error("failed",{command:C,...I.environment})}})}let U=yield*$.get();if(!U.formatter)return x1.info("all formatters are disabled"),x1.info("init"),{formatters:W,isEnabled:j,formatFile:q};for(let z of Object.values(O9))W[z.name]=z;if(U.formatter!==!0)for(let[z,M]of Object.entries(U.formatter)){let I=O9[z];if(["ruff","uv"].includes(z)&&(U.formatter.ruff?.disabled||U.formatter.uv?.disabled)){delete W.ruff,delete W.uv;continue}if(M.disabled){delete W[z];continue}let C=F9(I??{extensions:[]},M);W[z]={...C,name:z,extensions:C.extensions??[],enabled:I&&!C.command?I.enabled:async(P)=>C.command??!1}}return x1.info("init"),{formatters:W,isEnabled:j,formatFile:q}})),Y=G.fn("Format.init")(function*(){yield*i.get(Z)}),K=G.fn("Format.status")(function*(){let{formatters:V,isEnabled:X}=yield*i.get(Z),W=[];for(let _ of Object.values(V)){let j=yield*G.promise(()=>X(_));W.push({name:_.name,extensions:_.extensions,enabled:j})}return W}),Q=G.fn("Format.file")(function*(V){let{formatFile:X}=yield*i.get(Z);yield*X(V)});return q9.of({init:Y,status:K,file:Q})})),z_=GK.pipe(f.provide(R$.defaultLayer),f.provide(XJ));var h0={};o$(h0,{layer:()=>qK,defaultLayer:()=>y_,Service:()=>C9,Ripgrep:()=>h0,Match:()=>_K});import J8 from"path";var XK=O$.create({service:"ripgrep"}),d6="15.1.0",C_={"arm64-darwin":{platform:"aarch64-apple-darwin",extension:"tar.gz"},"arm64-linux":{platform:"aarch64-unknown-linux-gnu",extension:"tar.gz"},"x64-darwin":{platform:"x86_64-apple-darwin",extension:"tar.gz"},"x64-linux":{platform:"x86_64-unknown-linux-musl",extension:"tar.gz"},"arm64-win32":{platform:"aarch64-pc-windows-msvc",extension:"zip"},"ia32-win32":{platform:"i686-pc-windows-msvc",extension:"zip"},"x64-win32":{platform:"x86_64-pc-windows-msvc",extension:"zip"}},HK=F.object({elapsed:F.object({secs:F.number(),nanos:F.number(),human:F.string()}),searches:F.number(),searches_with_match:F.number(),bytes_searched:F.number(),bytes_printed:F.number(),matched_lines:F.number(),matches:F.number()}),M_=F.object({type:F.literal("begin"),data:F.object({path:F.object({text:F.string()})})}),_K=F.object({type:F.literal("match"),data:F.object({path:F.object({text:F.string()}),lines:F.object({text:F.string()}),line_number:F.number(),absolute_offset:F.number(),submatches:F.array(F.object({match:F.object({text:F.string()}),start:F.number(),end:F.number()}))})}),D_=F.object({type:F.literal("end"),data:F.object({path:F.object({text:F.string()}),binary_offset:F.number().nullable(),stats:HK})}),P_=F.object({type:F.literal("summary"),data:F.object({elapsed_total:F.object({human:F.string(),nanos:F.number(),secs:F.number()}),stats:HK})}),I_=F.union([M_,_K,D_,P_]);class C9 extends D$.Service()("@qitqode/Ripgrep"){}function A_(){let $=BK();return delete $.RIPGREP_CONFIG_PATH,$}function WK($){let J=$?.reason;if(J instanceof Error)return J;let Z=Error("Aborted");return Z.name="AbortError",Z}function S_($){if(!$)return G.never;if($.aborted)return G.fail(WK($));return G.callback((J)=>{let Z=()=>J(G.fail(WK($)));if($.addEventListener("abort",Z,{once:!0}),$.aborted)Z();return G.sync(()=>$.removeEventListener("abort",Z))})}function z9($,J){let Z=Error($.trim()||`ripgrep failed with code ${J}`);return Z.name="RipgrepError",Z}function OK($){return J8.normalize($.replace(/^\.[\\/]/,""))}function w_($){return{...$,path:{...$.path,text:OK($.path.text)}}}function R_($){return G.try({try:()=>I_.parse(JSON.parse($)),catch:(J)=>Error("invalid ripgrep output",{cause:J})})}function jK($,J){b1.failCauseUnsafe($,n0.fail(J))}function L_($){let J=["--no-config","--files","--glob=!.git/*"];if($.follow)J.push("--follow");if($.hidden!==!1)J.push("--hidden");if($.hidden===!1)J.push("--glob=!.*");if($.maxDepth!==void 0)J.push(`--max-depth=${$.maxDepth}`);if($.glob)for(let Z of $.glob)J.push(`--glob=${Z}`);return J.push("."),J}function N_($){let J=["--no-config","--json","--hidden","--glob=!.git/*","--no-messages"];if($.follow)J.push("--follow");if($.glob)for(let Z of $.glob)J.push(`--glob=${Z}`);if($.limit)J.push(`--max-count=${$.limit}`);return J.push("--",$.pattern,...$.file??["."]),J}function UK($,J){return J?$.pipe(G.raceFirst(S_(J))):$}var qK=f.effect(C9,G.gen(function*(){let $=yield*$$.Service,J=v1.filterStatusOk(yield*v1.HttpClient),Z=yield*M9,Y=G.fnUntraced(function*(H,q,U){let z=yield*Z.spawn(S1.make(H,q,{cwd:U?.cwd,extendEnv:!0,stdin:"ignore"})),[M,I,C]=yield*G.all([l$.mkString(l$.decodeText(z.stdout)),l$.mkString(l$.decodeText(z.stderr)),z.exitCode],{concurrency:"unbounded"});return{stdout:M,stderr:I,code:C}},G.scoped),K=G.fnUntraced(function*(H,q,U){let z=yield*$.makeTempDirectoryScoped({directory:f$.Path.bin,prefix:"ripgrep-"});if(q.extension==="zip"){let I=(yield*G.sync(()=>x$("powershell.exe")??x$("pwsh.exe")))??"powershell.exe",C=yield*Y(I,["-NoProfile","-NonInteractive","-Command",`$global:ProgressPreference = 'SilentlyContinue'; Expand-Archive -LiteralPath '${H.replaceAll("'","''")}' -DestinationPath '${z.replaceAll("'","''")}' -Force`]);if(C.code!==0)return yield*G.fail(z9(C.stderr||C.stdout,C.code))}if(q.extension==="tar.gz"){let I=yield*Y("tar",["-xzf",H,"-C",z]);if(I.code!==0)return yield*G.fail(z9(I.stderr||I.stdout,I.code))}let M=J8.join(z,`ripgrep-${d6}-${q.platform}`,process.platform==="win32"?"rg.exe":"rg");if(!(yield*$.isFile(M)))return yield*G.fail(Error(`ripgrep archive did not contain executable: ${M}`));if(yield*$.copyFile(M,U),process.platform==="win32")return;yield*$.chmod(U,493)},G.scoped),Q=yield*G.cached(G.gen(function*(){let H=yield*G.sync(()=>x$(process.platform==="win32"?"rg.exe":"rg"));if(H&&(yield*$.isFile(H).pipe(G.orDie)))return H;let q=J8.join(f$.Path.bin,`rg${process.platform==="win32"?".exe":""}`);if(yield*$.isFile(q).pipe(G.orDie))return q;let U=`${process.arch}-${process.platform}`,z=C_[U];if(!z)return yield*G.fail(Error(`unsupported platform for ripgrep: ${U}`));let M=`ripgrep-${d6}-${z.platform}.${z.extension}`,I=`https://github.com/BurntSushi/ripgrep/releases/download/${d6}/${M}`,C=J8.join(f$.Path.bin,M);XK.info("downloading ripgrep",{url:I}),yield*$.ensureDir(f$.Path.bin).pipe(G.orDie);let P=yield*G2.get(I).pipe(J.execute,G.flatMap((D)=>D.arrayBuffer),G.mapError((D)=>D instanceof Error?D:Error(String(D))));if(P.byteLength===0)return yield*G.fail(Error(`failed to download ripgrep from ${I}`));return yield*$.writeWithDirs(C,new Uint8Array(P)),yield*K(C,z,q),yield*$.remove(C,{force:!0}).pipe(G.ignore),q})),V=G.fnUntraced(function*(H){if(yield*$.isDir(H).pipe(G.orDie))return;return yield*G.fail(Object.assign(Error(`No such file or directory: '${H}'`),{code:"ENOENT",errno:-2,path:H}))}),X=G.fnUntraced(function*(H,q){let U=yield*Q;return S1.make(U,q,{cwd:H,env:A_(),extendEnv:!0,stdin:"ignore"})}),W=(H)=>l$.callback((q)=>G.gen(function*(){yield*G.forkScoped(G.gen(function*(){yield*V(H.cwd);let U=yield*Z.spawn(yield*X(H.cwd,L_(H))),z=yield*l$.mkString(l$.decodeText(U.stderr)).pipe(G.forkScoped),M=yield*l$.decodeText(U.stdout).pipe(l$.splitLines,l$.filter((C)=>C.length>0),l$.runForEach((C)=>G.sync(()=>b1.offerUnsafe(q,OK(C)))),G.forkScoped),I=yield*UK(U.exitCode,H.signal);if(yield*Z8.join(M),I===0||I===1){b1.endUnsafe(q);return}jK(q,z9(yield*Z8.join(z),I))}).pipe(G.catch((U)=>G.sync(()=>{jK(q,U)}))))})),_=G.fn("Ripgrep.search")(function*(H){yield*V(H.cwd);let q=G.scoped(G.gen(function*(){let U=yield*Z.spawn(yield*X(H.cwd,N_(H))),[z,M,I]=yield*G.all([l$.decodeText(U.stdout).pipe(l$.splitLines,l$.filter((C)=>C.length>0),l$.mapEffect(R_),l$.filter((C)=>C.type==="match"),l$.map((C)=>w_(C.data)),l$.runCollect,G.map((C)=>[...C])),l$.mkString(l$.decodeText(U.stderr)),U.exitCode],{concurrency:"unbounded"});if(I!==0&&I!==1&&I!==2)return yield*G.fail(z9(M,I));return{items:I===1?[]:z,partial:I===2}}));return yield*UK(q,H.signal)}),j=G.fn("Ripgrep.tree")(function*(H){XK.info("tree",H);let q=Array.from(yield*W({cwd:H.cwd,signal:H.signal}).pipe(l$.runCollect));function U(R,N){let x=R.children.get(N);if(x)return x;let b={name:N,children:new Map};return R.children.set(N,b),b}function z(R){return Array.from(R.children.values()).reduce((N,x)=>N+1+z(x),0)}let M={name:"",children:new Map};for(let R of q){if(R.includes(".qitqode"))continue;let N=R.split(J8.sep);if(N.length<2)continue;let x=M;for(let b of N.slice(0,-1))x=U(x,b)}let I=z(M),C=H.limit??I,P=[],D=Array.from(M.children.values()).sort((R,N)=>R.name.localeCompare(N.name)).map((R)=>({node:R,path:R.name})),L=0;for(let R=0;R<D.length&&L<C;R++){let N=D[R];P.push(N.path),L++,D.push(...Array.from(N.node.children.values()).sort((x,b)=>x.name.localeCompare(b.name)).map((x)=>({node:x,path:`${N.path}/${x.name}`})))}if(I>L)P.push(`[${I-L} truncated]`);return P.join(`
|
|
38
|
+
`)});return C9.of({files:W,tree:j,search:_})})),y_=qK.pipe(f.provide(X2.layer),f.provide($$.defaultLayer),f.provide(XJ));var w2={};o$(w2,{layer:()=>gK,defaultLayer:()=>M4,Service:()=>A9,Node:()=>K4,Info:()=>Y4,File:()=>w2,Event:()=>V4,Content:()=>Q4});var vK=S9(Z4(),1),hK=S9(LK(),1);import k0 from"path";var S2={};o$(S2,{paths:()=>J4,names:()=>$4,Protected:()=>S2});import o6 from"path";import a_ from"os";var r6=a_.homedir(),NK=["Music","Pictures","Movies","Downloads","Desktop","Documents","Public","Applications","Library"],t_=["Application Support/AddressBook","Calendars","Mail","Messages","Safari","Cookies","Application Support/com.apple.TCC","PersonalizationPortrait","Metadata/CoreSpotlight","Suggestions"],e_=["/.DocumentRevisions-V100","/.Spotlight-V100","/.Trashes","/.fseventsd"],yK=["AppData","Downloads","Desktop","Documents","Pictures","Music","Videos","OneDrive"];function $4(){if(process.platform==="darwin")return new Set(NK);if(process.platform==="win32")return new Set(yK);return new Set}function J4(){if(process.platform==="darwin")return[...NK.map(($)=>o6.join(r6,$)),...t_.map(($)=>o6.join(r6,"Library",$)),...e_];if(process.platform==="win32")return yK.map(($)=>o6.join(r6,$));return[]}var Y4=F.object({path:F.string(),added:F.number().int(),removed:F.number().int(),status:F.enum(["added","deleted","modified"])}).meta({ref:"File"}),K4=F.object({name:F.string(),path:F.string(),absolute:F.string(),type:F.enum(["file","directory"]),ignored:F.boolean()}).meta({ref:"FileNode"}),Q4=F.object({type:F.enum(["text","binary"]),content:F.string(),diff:F.string().optional(),patch:F.object({oldFileName:F.string(),newFileName:F.string(),oldHeader:F.string().optional(),newHeader:F.string().optional(),hunks:F.array(F.object({oldStart:F.number(),oldLines:F.number(),newStart:F.number(),newLines:F.number(),lines:F.array(F.string())})),index:F.string().optional()}).optional(),encoding:F.literal("base64").optional(),mimeType:F.string().optional()}).meta({ref:"FileContent"}),V4={Edited:Z0.define("file.edited",F.object({file:F.string()}))},K8=O$.create({service:"file"}),TK=393216,G4=new Set(["exe","dll","pdb","bin","so","dylib","o","a","lib","wav","mp3","ogg","oga","ogv","ogx","flac","aac","wma","m4a","weba","mp4","avi","mov","wmv","flv","webm","mkv","zip","tar","gz","gzip","bz","bz2","bzip","bzip2","7z","rar","xz","lz","z","pdf","doc","docx","ppt","pptx","xls","xlsx","dmg","iso","img","vmdk","ttf","otf","woff","woff2","eot","sqlite","db","mdb","apk","ipa","aab","xapk","app","pkg","deb","rpm","snap","flatpak","appimage","msi","msp","jar","war","ear","class","kotlin_module","dex","vdex","odex","oat","art","wasm","wat","bc","ll","s","ko","sys","drv","efi","rom","com"]),X4=new Set(["png","jpg","jpeg","gif","bmp","webp","ico","tif","tiff","svg","svgz","avif","apng","jxl","heic","heif","raw","cr2","nef","arw","dng","orf","raf","pef","x3f"]),W4=new Set(["ts","tsx","mts","cts","mtsx","ctsx","js","jsx","mjs","cjs","sh","bash","zsh","fish","ps1","psm1","cmd","bat","json","jsonc","json5","yaml","yml","toml","md","mdx","txt","xml","html","htm","css","scss","sass","less","graphql","gql","sql","ini","cfg","conf","env"]),j4=new Set(["dockerfile","makefile",".gitignore",".gitattributes",".editorconfig",".npmrc",".nvmrc",".prettierrc",".eslintrc"]),U4={png:"image/png",jpg:"image/jpeg",jpeg:"image/jpeg",gif:"image/gif",bmp:"image/bmp",webp:"image/webp",ico:"image/x-icon",tif:"image/tiff",tiff:"image/tiff",svg:"image/svg+xml",svgz:"image/svg+xml",avif:"image/avif",apng:"image/apng",jxl:"image/jxl",heic:"image/heic",heif:"image/heif"},Q8=($)=>k0.extname($).toLowerCase().slice(1),B4=($)=>k0.basename($).toLowerCase(),H4=($)=>X4.has(Q8($)),_4=($)=>W4.has(Q8($)),O4=($)=>j4.has(B4($)),q4=($)=>G4.has(Q8($)),F4=($)=>$.startsWith("image/"),kK=($)=>U4[Q8($)]||"image/"+Q8($);function z4($){let J=$.toLowerCase();if(K8.debug("shouldEncode",{type:J}),!J)return!1;if(J.startsWith("text/"))return!1;if(J.includes("charset="))return!1;let Z=J.split("/",2)[0];return["image","audio","video","font","model","multipart"].includes(Z)}var C4=($)=>{return $.replaceAll("\\","/").replace(/\/+$/,"").split("/").some((Z)=>Z.startsWith(".")&&Z.length>1)},EK=($,J)=>{if(J)return $;let Z=[],Y=[];for(let K of $)if(C4(K))Y.push(K);else Z.push(K);return[...Z,...Y]};class A9 extends D$.Service()("@qitqode/File"){}var gK=f.effect(A9,G.gen(function*(){let $=yield*$$.Service,J=yield*h0.Service,Z=yield*HJ.Service,Y=yield*UJ.Scope,K=yield*i.make(G.fn("File.state")(()=>G.succeed({cache:{files:[],dirs:[]}}))),Q=G.fn("File.scan")(function*(){let M=yield*i.context;if(M.directory===k0.parse(M.directory).root)return;let I=M.directory===f$.Path.home&&M.project.id==="global",C={files:[],dirs:[]};if(I){let D=new Set,L=S2.names(),R=new Set(["node_modules","dist","build","target","vendor"]),N=(v)=>v.startsWith(".")||L.has(v),x=(v)=>v.startsWith(".")||R.has(v),b=yield*$.readDirectoryEntries(M.directory).pipe(G.orElseSucceed(()=>[]));for(let v of b){if(v.type!=="directory")continue;if(N(v.name))continue;D.add(v.name+"/");let m=k0.join(M.directory,v.name),A=yield*$.readDirectoryEntries(m).pipe(G.orElseSucceed(()=>[]));for(let u of A){if(u.type!=="directory")continue;if(x(u.name))continue;D.add(v.name+"/"+u.name+"/")}}C.dirs=Array.from(D).toSorted()}else{let D=yield*J.files({cwd:M.directory}).pipe(BJ,G.map((R)=>[...R])),L=new Set;for(let R of D){C.files.push(R);let N=R;while(!0){let x=k0.dirname(N);if(x===".")break;if(x===N)break;if(N=x,L.has(x))continue;L.add(x),C.dirs.push(x+"/")}}}let P=yield*i.get(K);P.cache=C}),V=yield*G.cached(Q().pipe(G.catchCause(()=>G.void))),X=G.fn("File.ensure")(function*(){yield*V,V=yield*G.cached(Q().pipe(G.catchCause(()=>G.void)))}),W=G.fnUntraced(function*(M){return(yield*Z.run(M,{cwd:(yield*i.context).directory})).text()}),_=(M,I)=>{if(!B$.containsPath(M,I))throw Error("Access denied: path escapes project directory");let C=$$.canonical(M);if(!B$.containsPath(C,I))throw Error("Access denied: path escapes project directory")},j=G.fn("File.init")(function*(){yield*X().pipe(G.forkIn(Y))}),H=G.fn("File.status")(function*(){let M=yield*i.context;if(M.project.vcs!=="git")return[];let I=yield*W(["-c","core.fsmonitor=false","-c","core.quotepath=false","diff","--numstat","HEAD"]),C=[];if(I.trim())for(let L of I.trim().split(`
|
|
39
|
+
`)){let[R,N,x]=L.split("\t");C.push({path:x,added:R==="-"?0:parseInt(R,10),removed:N==="-"?0:parseInt(N,10),status:"modified"})}let P=yield*W(["-c","core.fsmonitor=false","-c","core.quotepath=false","ls-files","--others","--exclude-standard"]);if(P.trim())for(let L of P.trim().split(`
|
|
40
|
+
`)){let R=yield*$.readFileString(k0.join(M.directory,L)).pipe(G.catch(()=>G.succeed(void 0)));if(R===void 0)continue;C.push({path:L,added:R.split(`
|
|
41
41
|
`).length,removed:0,status:"added"})}let D=yield*W(["-c","core.fsmonitor=false","-c","core.quotepath=false","diff","--name-only","--diff-filter=D","HEAD"]);if(D.trim())for(let L of D.trim().split(`
|
|
42
|
-
`))z.push({path:L,added:0,removed:0,status:"deleted"});return z.map((L)=>{let R=T0.isAbsolute(L.path)?L.path:T0.join(M.directory,L.path);return{...L,path:T0.relative(M.directory,R)}})}),q=G.fn("File.read")(function*(M){let b=[];try{const I=S9(b,K8.time("read",{file:M}),0);let z=yield*i.context;let P=T0.join(z.directory,M);B(P,z);if(X4(M)){let u=yield*$.stat(P).pipe(G.catch(()=>G.succeed(void 0)));if(!u)return{type:"text",content:""};if(Number(u.size)>NK)return{type:"binary",content:"",mimeType:yK(M)};let r=yield*$.readFile(P).pipe(G.catch(()=>G.succeed(new Uint8Array)));return{type:"text",content:Buffer.from(r).toString("base64"),mimeType:yK(M),encoding:"base64"}}let D=W4(M)||j4(M);if(U4(M)&&!D)return{type:"binary",content:""};let L=yield*$.stat(P).pipe(G.catch(()=>G.succeed(void 0)));if(!L)return{type:"text",content:""};let R=$$.mimeType(P);let N=D?!1:B4(R);if(N&&!H4(R))return{type:"binary",content:"",mimeType:R};if(N){if(Number(L.size)>NK)return{type:"binary",content:"",mimeType:R};let u=yield*$.readFile(P).pipe(G.catch(()=>G.succeed(new Uint8Array)));return{type:"text",content:Buffer.from(u).toString("base64"),mimeType:R,encoding:"base64"}}let x=yield*$.readFileString(P).pipe(G.map((u)=>u.trim()),G.catch(()=>G.succeed("")));if(z.project.vcs==="git"){let u=yield*W(["-c","core.fsmonitor=false","diff","--",M]);if(!u.trim())u=yield*W(["-c","core.fsmonitor=false","diff","--staged","--",M]);if(u.trim()){let r=yield*Z.show(z.directory,"HEAD",M),S=kK(M,M,r,x,"old","new",{context:1/0,ignoreWhitespace:!0});return{type:"text",content:x,patch:S,diff:EK(S)}}return{type:"text",content:x}}return{type:"text",content:x}}catch(v){var m=v,A=1}finally{w9(b,m,A)}}),H=G.fn("File.list")(function*(M){let I=yield*i.context,z=[".git",".DS_Store"],P=(N)=>!1;if(I.project.vcs==="git"){let N=bK.default(),x=T0.join(I.worktree,".gitignore"),b=yield*$.readFileString(x).pipe(G.catch(()=>G.succeed("")));if(b)N.add(b);let v=T0.join(I.worktree,".ignore"),m=yield*$.readFileString(v).pipe(G.catch(()=>G.succeed("")));if(m)N.add(m);P=N.ignores.bind(N)}let D=M?T0.join(I.directory,M):I.directory;B(D,I);let L=yield*$.readDirectoryEntries(D).pipe(G.orElseSucceed(()=>[])),R=[];for(let N of L){if(z.includes(N.name))continue;let x=T0.join(D,N.name),b=T0.relative(I.directory,x),v=N.type==="directory"?"directory":"file";R.push({name:N.name,path:b,absolute:x,type:v,ignored:P(v==="directory"?b+"/":b)})}return R.sort((N,x)=>{if(N.type!==x.type)return N.type==="directory"?-1:1;return N.name.localeCompare(x.name)})}),C=G.fn("File.search")(function*(M){yield*X();let{cache:I}=yield*i.get(K),z=M.query.trim(),P=M.limit??100,D=M.type??(M.dirs===!1?"file":"all");K8.info("search",{query:z,kind:D});let L=z.startsWith(".")||z.includes("/.");if(!z){if(D==="file")return I.files.slice(0,P);return TK(I.dirs.toSorted(),L).slice(0,P)}let R=D==="file"?I.files:D==="directory"?I.dirs:[...I.files,...I.dirs],N=D==="directory"&&!L?P*20:P,x=xK.default.go(z,R,{limit:N}).map((v)=>v.target),b=D==="directory"?TK(x,L).slice(0,P):x;return K8.info("search",{query:z,kind:D,results:b.length}),b});return K8.info("init"),I9.of({init:j,status:_,read:q,list:H,search:C})})),O4=vK.pipe(f.provide(h0.defaultLayer),f.provide($$.defaultLayer),f.provide(BJ.defaultLayer));var k2={};o$(k2,{layer:()=>tQ,hasNativeBinding:()=>Zq,defaultLayer:()=>Yq,Service:()=>b9,FileWatcher:()=>k2,Event:()=>x9});var N2=u0("path"),iO=pQ(),sO=iQ();function k9($,J={}){let{ignore:Z,...Y}=J;if(Array.isArray(Z)){J={...Y};for(let K of Z)if(sO(K)){if(!J.ignoreGlobs)J.ignoreGlobs=[];let Q=iO.makeRe(K,{dot:!0,lookbehinds:!1});J.ignoreGlobs.push(Q.source)}else{if(!J.ignorePaths)J.ignorePaths=[];J.ignorePaths.push(N2.resolve($,K))}}return J}var X7=($)=>{return{writeSnapshot(J,Z,Y){return $.writeSnapshot(N2.resolve(J),N2.resolve(Z),k9(J,Y))},getEventsSince(J,Z,Y){return $.getEventsSince(N2.resolve(J),N2.resolve(Z),k9(J,Y))},async subscribe(J,Z,Y){return J=N2.resolve(J),Y=k9(J,Y),await $.subscribe(J,Z,Y),{unsubscribe(){return $.unsubscribe(J,Z,Y)}}},unsubscribe(J,Z,Y){return $.unsubscribe(N2.resolve(J),Z,k9(J,Y))}}};import{readdir as tO}from"fs/promises";import E9 from"path";var U8={};o$(U8,{match:()=>aO,PATTERNS:()=>nO,FileIgnore:()=>U8});var sQ=new Set(["node_modules","bower_components",".pnpm-store","vendor",".npm","dist","build","out",".next","target","bin","obj",".git",".svn",".hg",".vscode",".idea",".turbo",".output","desktop",".sst",".cache",".webkit-cache","__pycache__",".pytest_cache","mypy_cache",".history",".gradle"]),nQ=["**/*.swp","**/*.swo","**/*.pyc","**/.DS_Store","**/Thumbs.db","**/logs/**","**/tmp/**","**/temp/**","**/*.log","**/coverage/**","**/.nyc_output/**"],nO=[...nQ,...sQ];function aO($,J){for(let K of J?.whitelist||[])if(y2.match(K,$))return!1;let Z=$.split(/[/\\]/);for(let K=0;K<Z.length;K++)if(sQ.has(Z[K]))return!0;let Y=J?.extra||[];for(let K of[...nQ,...Y])if(y2.match(K,$))return!0;return!1}var qJ=O$.create({service:"file.watcher"}),eO=1e4,x9={Updated:Z0.define("file.watcher.updated",F.object({file:F.string(),event:F.union([F.literal("add"),F.literal("change"),F.literal("unlink")])}))},aQ=T2(()=>{try{let $=u0(`@parcel/watcher-${process.platform}-${process.arch}${process.platform==="linux"?"-bionic":""}`);return X7($)}catch($){qJ.error("failed to load watcher binding",{error:$});return}});function $q(){if(process.platform==="win32")return"windows";if(process.platform==="darwin")return"fs-events";if(process.platform==="linux")return"inotify"}function Jq($){return S2.paths().filter((J)=>{let Z=E9.relative($,J);return Z!==""&&Z!==".."&&!Z.startsWith(`..${E9.sep}`)&&!E9.isAbsolute(Z)})}var Zq=()=>!!aQ();class b9 extends D$.Service()("@qitqode/FileWatcher"){}var tQ=f.effect(b9,G.gen(function*(){let $=yield*R$.Service,J=yield*BJ.Service,Z=yield*i.make(G.fn("FileWatcher.state")(function*(){if(yield*k$.QITQODE_EXPERIMENTAL_DISABLE_FILEWATCHER)return;qJ.info("init",{directory:H$.directory});let Y=$q();if(!Y){qJ.error("watcher backend not supported",{directory:H$.directory,platform:process.platform});return}let K=aQ();if(!K)return;qJ.info("watcher backend",{directory:H$.directory,platform:process.platform,backend:Y});let Q=[];yield*G.addFinalizer(()=>G.promise(()=>Promise.allSettled(Q.map((j)=>j.unsubscribe()))));let V=H$.bind((j,_)=>{if(j)return;for(let q of _){if(q.type==="create")P$.publish(x9.Updated,{file:q.path,event:"add"});if(q.type==="update")P$.publish(x9.Updated,{file:q.path,event:"change"});if(q.type==="delete")P$.publish(x9.Updated,{file:q.path,event:"unlink"})}}),X=(j,_)=>{let q=K.subscribe(j,V,{ignore:_,backend:Y});return G.gen(function*(){let H=yield*G.promise(()=>q);Q.push(H)}).pipe(G.timeout(eO),G.catchCause((H)=>{return qJ.error("failed to subscribe",{dir:j,cause:n0.pretty(H)}),q.then((C)=>C.unsubscribe()).catch(()=>{}),G.void}))},B=(yield*$.get()).watcher?.ignore??[];if(yield*k$.QITQODE_EXPERIMENTAL_FILEWATCHER)yield*X(H$.directory,[...U8.PATTERNS,...B,...Jq(H$.directory)]);if(H$.project.vcs==="git"){let j=yield*J.run(["rev-parse","--git-dir"],{cwd:H$.project.worktree}),_=j.exitCode===0?E9.resolve(H$.project.worktree,j.text().trim()):void 0;if(_&&!B.includes(".git")&&!B.includes(_)){let q=(yield*G.promise(()=>tO(_).catch(()=>[]))).filter((H)=>H!=="HEAD");yield*X(_,q)}}},G.catchCause((Y)=>{return qJ.error("failed to init watcher service",{cause:n0.pretty(Y)}),G.void})));return b9.of({init:G.fn("FileWatcher.init")(function*(){yield*i.get(Z)})})})),Yq=tQ.pipe(f.provide(R$.defaultLayer),f.provide(BJ.defaultLayer));var FJ={};o$(FJ,{layer:()=>YV,defaultLayer:()=>Vq,Service:()=>v9,Discovery:()=>FJ});var Kq=4,Qq=8;class JV extends F$.Class("IndexSkill")({name:F$.String,files:F$.Array(F$.String)}){}class ZV extends F$.Class("Index")({skills:F$.Array(JV)}){}class v9 extends D$.Service()("@qitqode/SkillDiscovery"){}var YV=f.effect(v9,G.gen(function*(){let $=O$.create({service:"skill-discovery"}),J=yield*$$.Service,Z=yield*eQ.Path,Y=v1.filterStatusOk(g9(yield*v1.HttpClient)),K=Z.join(f$.Path.cache,"skills"),Q=G.fn("Discovery.download")(function*(X,W){if(yield*J.exists(W).pipe(G.orDie))return!0;return yield*G2.get(X).pipe(Y.execute,G.flatMap((B)=>B.arrayBuffer),G.flatMap((B)=>J.writeWithDirs(W,new Uint8Array(B))),G.as(!0),G.catch((B)=>G.sync(()=>{return $.error("failed to download",{url:X,err:B}),!1})))}),V=G.fn("Discovery.pull")(function*(X){let W=X.endsWith("/")?X:`${X}/`,B=new URL("index.json",W).href,j=W.slice(0,-1);$.info("fetching index",{url:B});let _=yield*G2.get(B).pipe(G2.acceptJson,Y.execute,G.flatMap($V.schemaBodyJson(ZV)),G.catch((C)=>G.sync(()=>{return $.error("failed to fetch index",{url:B,err:C}),null})));if(!_)return[];let q=_.skills.filter((C)=>{if(!C.files.includes("SKILL.md"))return $.warn("skill entry missing SKILL.md",{url:B,skill:C.name}),!1;return!0});return(yield*G.forEach(q,(C)=>G.gen(function*(){let M=Z.join(K,C.name);yield*G.forEach(C.files,(z)=>Q(new URL(z,`${j}/${C.name}/`).href,Z.join(M,z)),{concurrency:Qq});let I=Z.join(M,"SKILL.md");return(yield*J.exists(I).pipe(G.orDie))?M:null}),{concurrency:Kq})).filter((C)=>C!==null)});return v9.of({pull:V})})),Vq=YV.pipe(f.provide(X2.layer),f.provide($$.defaultLayer),f.provide(h9.layer));var a0={};o$(a0,{layer:()=>OV,fmt:()=>Rq,defaultLayer:()=>wq,Skill:()=>a0,Service:()=>c9,NameMismatchError:()=>Pq,InvalidError:()=>Dq,Info:()=>_V});import Fq from"os";import zJ from"path";import{pathToFileURL as zq}from"url";import u9 from"path";import{pathToFileURL as Wq}from"url";var U7=A9(Xq(),1);import Gq from"path";import W7 from"fs";import j7 from"path";function KV($,J,Z){let Y=J?j7.join($,J):$;for(let K of W7.readdirSync(Y,{withFileTypes:!0})){let Q=J?`${J}/${K.name}`:K.name;if(K.isDirectory())KV($,Q,Z);else Z[Q]=W7.readFileSync(j7.join(Y,K.name),"utf8")}}function f9($){let J={};for(let Z of W7.readdirSync($,{withFileTypes:!0})){if(!Z.isDirectory())continue;let Y={};if(KV(j7.join($,Z.name),"",Y),Object.keys(Y).length>0)J[Z.name]=Y}return J}function QV(){return f9(Gq.resolve(import.meta.dir,".bundle"))}import VV from"path";function m9($){return G.gen(function*(){if($.skipIfPresent&&(yield*$.fsys.existsSafe($.marker)))return $.root;for(let[J,Z]of Object.entries($.bundle)){let Y=VV.join($.root,"skills",J);for(let[K,Q]of Object.entries(Z))yield*$.fsys.writeWithDirs(VV.join(Y,K),Q)}return yield*$.fsys.writeWithDirs($.marker,$.markerContent),$.onExtracted($.root),$.root})}function jq(){try{return{ask:{"SKILL.md":`---
|
|
42
|
+
`))C.push({path:L,added:0,removed:0,status:"deleted"});return C.map((L)=>{let R=k0.isAbsolute(L.path)?L.path:k0.join(M.directory,L.path);return{...L,path:k0.relative(M.directory,R)}})}),q=G.fn("File.read")(function*(M){let b=[];try{const I=w9(b,K8.time("read",{file:M}),0);let C=yield*i.context;let P=k0.join(C.directory,M);_(P,C);if(H4(M)){let u=yield*$.stat(P).pipe(G.catch(()=>G.succeed(void 0)));if(!u)return{type:"text",content:""};if(Number(u.size)>TK)return{type:"binary",content:"",mimeType:kK(M)};let r=yield*$.readFile(P).pipe(G.catch(()=>G.succeed(new Uint8Array)));return{type:"text",content:Buffer.from(r).toString("base64"),mimeType:kK(M),encoding:"base64"}}let D=_4(M)||O4(M);if(q4(M)&&!D)return{type:"binary",content:""};let L=yield*$.stat(P).pipe(G.catch(()=>G.succeed(void 0)));if(!L)return{type:"text",content:""};let R=$$.mimeType(P);let N=D?!1:z4(R);if(N&&!F4(R))return{type:"binary",content:"",mimeType:R};if(N){if(Number(L.size)>TK)return{type:"binary",content:"",mimeType:R};let u=yield*$.readFile(P).pipe(G.catch(()=>G.succeed(new Uint8Array)));return{type:"text",content:Buffer.from(u).toString("base64"),mimeType:R,encoding:"base64"}}let x=yield*$.readFileString(P).pipe(G.map((u)=>u.trim()),G.catch(()=>G.succeed("")));if(C.project.vcs==="git"){let u=yield*W(["-c","core.fsmonitor=false","diff","--",M]);if(!u.trim())u=yield*W(["-c","core.fsmonitor=false","diff","--staged","--",M]);if(u.trim()){let r=yield*Z.show(C.directory,"HEAD",M),S=xK(M,M,r,x,"old","new",{context:1/0,ignoreWhitespace:!0});return{type:"text",content:x,patch:S,diff:bK(S)}}return{type:"text",content:x}}return{type:"text",content:x}}catch(v){var m=v,A=1}finally{R9(b,m,A)}}),U=G.fn("File.list")(function*(M){let I=yield*i.context,C=[".git",".DS_Store"],P=(N)=>!1;if(I.project.vcs==="git"){let N=hK.default(),x=k0.join(I.worktree,".gitignore"),b=yield*$.readFileString(x).pipe(G.catch(()=>G.succeed("")));if(b)N.add(b);let v=k0.join(I.worktree,".ignore"),m=yield*$.readFileString(v).pipe(G.catch(()=>G.succeed("")));if(m)N.add(m);P=N.ignores.bind(N)}let D=M?k0.join(I.directory,M):I.directory;_(D,I);let L=yield*$.readDirectoryEntries(D).pipe(G.orElseSucceed(()=>[])),R=[];for(let N of L){if(C.includes(N.name))continue;let x=k0.join(D,N.name),b=k0.relative(I.directory,x),v=N.type==="directory"?"directory":"file";R.push({name:N.name,path:b,absolute:x,type:v,ignored:P(v==="directory"?b+"/":b)})}return R.sort((N,x)=>{if(N.type!==x.type)return N.type==="directory"?-1:1;return N.name.localeCompare(x.name)})}),z=G.fn("File.search")(function*(M){yield*X();let{cache:I}=yield*i.get(K),C=M.query.trim(),P=M.limit??100,D=M.type??(M.dirs===!1?"file":"all");K8.info("search",{query:C,kind:D});let L=C.startsWith(".")||C.includes("/.");if(!C){if(D==="file")return I.files.slice(0,P);return EK(I.dirs.toSorted(),L).slice(0,P)}let R=D==="file"?I.files:D==="directory"?I.dirs:[...I.files,...I.dirs],N=D==="directory"&&!L?P*20:P,x=vK.default.go(C,R,{limit:N}).map((v)=>v.target),b=D==="directory"?EK(x,L).slice(0,P):x;return K8.info("search",{query:C,kind:D,results:b.length}),b});return K8.info("init"),A9.of({init:j,status:H,read:q,list:U,search:z})})),M4=gK.pipe(f.provide(h0.defaultLayer),f.provide($$.defaultLayer),f.provide(HJ.defaultLayer));var k2={};o$(k2,{layer:()=>$V,hasNativeBinding:()=>Gq,defaultLayer:()=>Xq,Service:()=>v9,FileWatcher:()=>k2,Event:()=>b9});var N2=u0("path"),eO=lQ(),$q=nQ();function E9($,J={}){let{ignore:Z,...Y}=J;if(Array.isArray(Z)){J={...Y};for(let K of Z)if($q(K)){if(!J.ignoreGlobs)J.ignoreGlobs=[];let Q=eO.makeRe(K,{dot:!0,lookbehinds:!1});J.ignoreGlobs.push(Q.source)}else{if(!J.ignorePaths)J.ignorePaths=[];J.ignorePaths.push(N2.resolve($,K))}}return J}var j7=($)=>{return{writeSnapshot(J,Z,Y){return $.writeSnapshot(N2.resolve(J),N2.resolve(Z),E9(J,Y))},getEventsSince(J,Z,Y){return $.getEventsSince(N2.resolve(J),N2.resolve(Z),E9(J,Y))},async subscribe(J,Z,Y){return J=N2.resolve(J),Y=E9(J,Y),await $.subscribe(J,Z,Y),{unsubscribe(){return $.unsubscribe(J,Z,Y)}}},unsubscribe(J,Z,Y){return $.unsubscribe(N2.resolve(J),Z,E9(J,Y))}}};import{readdir as Yq}from"fs/promises";import x9 from"path";var U8={};o$(U8,{match:()=>Zq,PATTERNS:()=>Jq,FileIgnore:()=>U8});var aQ=new Set(["node_modules","bower_components",".pnpm-store","vendor",".npm","dist","build","out",".next","target","bin","obj",".git",".svn",".hg",".vscode",".idea",".turbo",".output","desktop",".sst",".cache",".webkit-cache","__pycache__",".pytest_cache","mypy_cache",".history",".gradle"]),tQ=["**/*.swp","**/*.swo","**/*.pyc","**/.DS_Store","**/Thumbs.db","**/logs/**","**/tmp/**","**/temp/**","**/*.log","**/coverage/**","**/.nyc_output/**"],Jq=[...tQ,...aQ];function Zq($,J){for(let K of J?.whitelist||[])if(y2.match(K,$))return!1;let Z=$.split(/[/\\]/);for(let K=0;K<Z.length;K++)if(aQ.has(Z[K]))return!0;let Y=J?.extra||[];for(let K of[...tQ,...Y])if(y2.match(K,$))return!0;return!1}var qJ=O$.create({service:"file.watcher"}),Kq=1e4,b9={Updated:Z0.define("file.watcher.updated",F.object({file:F.string(),event:F.union([F.literal("add"),F.literal("change"),F.literal("unlink")])}))},eQ=T2(()=>{try{let $=u0(`@parcel/watcher-${process.platform}-${process.arch}${process.platform==="linux"?"-bionic":""}`);return j7($)}catch($){qJ.error("failed to load watcher binding",{error:$});return}});function Qq(){if(process.platform==="win32")return"windows";if(process.platform==="darwin")return"fs-events";if(process.platform==="linux")return"inotify"}function Vq($){return S2.paths().filter((J)=>{let Z=x9.relative($,J);return Z!==""&&Z!==".."&&!Z.startsWith(`..${x9.sep}`)&&!x9.isAbsolute(Z)})}var Gq=()=>!!eQ();class v9 extends D$.Service()("@qitqode/FileWatcher"){}var $V=f.effect(v9,G.gen(function*(){let $=yield*R$.Service,J=yield*HJ.Service,Z=yield*i.make(G.fn("FileWatcher.state")(function*(){if(yield*k$.QITQODE_EXPERIMENTAL_DISABLE_FILEWATCHER)return;qJ.info("init",{directory:B$.directory});let Y=Qq();if(!Y){qJ.error("watcher backend not supported",{directory:B$.directory,platform:process.platform});return}let K=eQ();if(!K)return;qJ.info("watcher backend",{directory:B$.directory,platform:process.platform,backend:Y});let Q=[];yield*G.addFinalizer(()=>G.promise(()=>Promise.allSettled(Q.map((j)=>j.unsubscribe()))));let V=B$.bind((j,H)=>{if(j)return;for(let q of H){if(q.type==="create")P$.publish(b9.Updated,{file:q.path,event:"add"});if(q.type==="update")P$.publish(b9.Updated,{file:q.path,event:"change"});if(q.type==="delete")P$.publish(b9.Updated,{file:q.path,event:"unlink"})}}),X=(j,H)=>{let q=K.subscribe(j,V,{ignore:H,backend:Y});return G.gen(function*(){let U=yield*G.promise(()=>q);Q.push(U)}).pipe(G.timeout(Kq),G.catchCause((U)=>{return qJ.error("failed to subscribe",{dir:j,cause:n0.pretty(U)}),q.then((z)=>z.unsubscribe()).catch(()=>{}),G.void}))},_=(yield*$.get()).watcher?.ignore??[];if(yield*k$.QITQODE_EXPERIMENTAL_FILEWATCHER)yield*X(B$.directory,[...U8.PATTERNS,..._,...Vq(B$.directory)]);if(B$.project.vcs==="git"){let j=yield*J.run(["rev-parse","--git-dir"],{cwd:B$.project.worktree}),H=j.exitCode===0?x9.resolve(B$.project.worktree,j.text().trim()):void 0;if(H&&!_.includes(".git")&&!_.includes(H)){let q=(yield*G.promise(()=>Yq(H).catch(()=>[]))).filter((U)=>U!=="HEAD");yield*X(H,q)}}},G.catchCause((Y)=>{return qJ.error("failed to init watcher service",{cause:n0.pretty(Y)}),G.void})));return v9.of({init:G.fn("FileWatcher.init")(function*(){yield*i.get(Z)})})})),Xq=$V.pipe(f.provide(R$.defaultLayer),f.provide(HJ.defaultLayer));var FJ={};o$(FJ,{layer:()=>QV,defaultLayer:()=>Uq,Service:()=>h9,Discovery:()=>FJ});var Wq=4,jq=8;class YV extends F$.Class("IndexSkill")({name:F$.String,files:F$.Array(F$.String)}){}class KV extends F$.Class("Index")({skills:F$.Array(YV)}){}class h9 extends D$.Service()("@qitqode/SkillDiscovery"){}var QV=f.effect(h9,G.gen(function*(){let $=O$.create({service:"skill-discovery"}),J=yield*$$.Service,Z=yield*JV.Path,Y=v1.filterStatusOk(f9(yield*v1.HttpClient)),K=Z.join(f$.Path.cache,"skills"),Q=G.fn("Discovery.download")(function*(X,W){if(yield*J.exists(W).pipe(G.orDie))return!0;return yield*G2.get(X).pipe(Y.execute,G.flatMap((_)=>_.arrayBuffer),G.flatMap((_)=>J.writeWithDirs(W,new Uint8Array(_))),G.as(!0),G.catch((_)=>G.sync(()=>{return $.error("failed to download",{url:X,err:_}),!1})))}),V=G.fn("Discovery.pull")(function*(X){let W=X.endsWith("/")?X:`${X}/`,_=new URL("index.json",W).href,j=W.slice(0,-1);$.info("fetching index",{url:_});let H=yield*G2.get(_).pipe(G2.acceptJson,Y.execute,G.flatMap(ZV.schemaBodyJson(KV)),G.catch((z)=>G.sync(()=>{return $.error("failed to fetch index",{url:_,err:z}),null})));if(!H)return[];let q=H.skills.filter((z)=>{if(!z.files.includes("SKILL.md"))return $.warn("skill entry missing SKILL.md",{url:_,skill:z.name}),!1;return!0});return(yield*G.forEach(q,(z)=>G.gen(function*(){let M=Z.join(K,z.name);yield*G.forEach(z.files,(C)=>Q(new URL(C,`${j}/${z.name}/`).href,Z.join(M,C)),{concurrency:jq});let I=Z.join(M,"SKILL.md");return(yield*J.exists(I).pipe(G.orDie))?M:null}),{concurrency:Wq})).filter((z)=>z!==null)});return h9.of({pull:V})})),Uq=QV.pipe(f.provide(X2.layer),f.provide($$.defaultLayer),f.provide(g9.layer));var a0={};o$(a0,{layer:()=>FV,fmt:()=>kq,defaultLayer:()=>Tq,Skill:()=>a0,Service:()=>l9,NameMismatchError:()=>Rq,InvalidError:()=>wq,Info:()=>qV});import Pq from"os";import zJ from"path";import{pathToFileURL as Iq}from"url";import d9 from"path";import{pathToFileURL as _q}from"url";var H7=S9(Hq(),1);import Bq from"path";import U7 from"fs";import B7 from"path";function VV($,J,Z){let Y=J?B7.join($,J):$;for(let K of U7.readdirSync(Y,{withFileTypes:!0})){let Q=J?`${J}/${K.name}`:K.name;if(K.isDirectory())VV($,Q,Z);else Z[Q]=U7.readFileSync(B7.join(Y,K.name),"utf8")}}function m9($){let J={};for(let Z of U7.readdirSync($,{withFileTypes:!0})){if(!Z.isDirectory())continue;let Y={};if(VV(B7.join($,Z.name),"",Y),Object.keys(Y).length>0)J[Z.name]=Y}return J}function GV(){return m9(Bq.resolve(import.meta.dir,".bundle"))}import XV from"path";function u9($){return G.gen(function*(){if($.skipIfPresent&&(yield*$.fsys.existsSafe($.marker)))return $.root;for(let[J,Z]of Object.entries($.bundle)){let Y=XV.join($.root,"skills",J);for(let[K,Q]of Object.entries(Z))yield*$.fsys.writeWithDirs(XV.join(Y,K),Q)}return yield*$.fsys.writeWithDirs($.marker,$.markerContent),$.onExtracted($.root),$.root})}function Oq(){try{return{ask:{"SKILL.md":`---
|
|
43
43
|
name: compose:ask
|
|
44
44
|
hidden: true
|
|
45
45
|
description: "Use whenever you need a decision, clarification, or approval from the user \u2014 covers how to ask with the question tool, and how to resolve the decision yourself when no user is available (question tool absent, or a [Never-Ask] response)"
|
|
@@ -6337,8 +6337,8 @@ Ready to implement <feature-name>
|
|
|
6337
6337
|
- Verify directory is ignored for project-local
|
|
6338
6338
|
- Auto-detect and run project setup
|
|
6339
6339
|
- Verify clean test baseline
|
|
6340
|
-
`}}}catch($){if($ instanceof ReferenceError)return
|
|
6341
|
-
`)}import
|
|
6340
|
+
`}}}catch($){if($ instanceof ReferenceError)return GV();throw $}}var jV=Oq(),qq=O$.create({service:"skill.compose"}),UV=G.fn("Skill.extractComposeBundle")(function*($){let J=d9.join(B8.data,"compose",E2),Z=d9.join(J,".extracted");return yield*u9({fsys:$,bundle:jV,root:J,marker:Z,markerContent:E2,skipIfPresent:!p9,onExtracted:(Y)=>qq.info("extracted compose skills",{root:Y})})});function Fq($){try{return H7.default($,{})}catch{let J=WV($);if(J===$)return;try{return H7.default(J,{})}catch{return}}}function MR(){let $=d9.join(B8.data,"compose",E2),J=[];for(let[Z,Y]of Object.entries(jV)){let K=Y["SKILL.md"];if(!K)continue;let Q=Fq(K);if(!Q?.data?.name||!Q?.data?.description)continue;let V=_q(d9.join($,"skills",Z,"SKILL.md")).href;J.push(" <skill>",` <name>${Q.data.name}</name>`,` <description>${Q.data.description}</description>`,` <location>${V}</location>`," </skill>")}if(J.length===0)return"";return["<compose_skills>",...J,"</compose_skills>"].join(`
|
|
6341
|
+
`)}import HV from"path";import zq from"path";function BV(){return m9(zq.resolve(import.meta.dir,".bundle"))}function Cq(){try{return{"self-extend":{"reference/hook-api.md":`# Hook API Reference
|
|
6342
6342
|
|
|
6343
6343
|
## File Format
|
|
6344
6344
|
|
|
@@ -7204,9 +7204,9 @@ For full type signatures, all available fields, and more examples:
|
|
|
7204
7204
|
- Cannot modify the permission system
|
|
7205
7205
|
- Tool output truncated at 50KB / 2000 lines
|
|
7206
7206
|
- Prefer small, composable extensions over monolithic ones
|
|
7207
|
-
`}}}catch($){if($ instanceof ReferenceError)return
|
|
7207
|
+
`}}}catch($){if($ instanceof ReferenceError)return BV();throw $}}var Mq=Cq(),Dq=O$.create({service:"skill.builtin"}),_V=G.fn("Skill.extractBuiltinBundle")(function*($){let J=HV.join(B8.data,"builtin_skills",E2),Z=HV.join(J,".extracted");return yield*u9({fsys:$,bundle:Mq,root:J,marker:Z,markerContent:E2,skipIfPresent:!p9,onExtracted:(Y)=>Dq.info("extracted builtin skills",{root:Y})})});var H8=O$.create({service:"skill"}),Aq=[".claude",".agents",".codex",".opencode"],OV="skills/**/SKILL.md",Sq="{skill,skills}/**/SKILL.md",c9="**/SKILL.md",qV=F.object({name:F.string(),description:F.string(),location:F.string(),content:F.string(),hidden:F.boolean().optional()}),wq=o9.create("SkillInvalidError",F.object({path:F.string(),message:F.string().optional(),issues:F.custom().optional()})),Rq=o9.create("SkillNameMismatchError",F.object({path:F.string(),expected:F.string(),actual:F.string()})),Lq=G.fnUntraced(function*($,J,Z){let Y=yield*G.tryPromise({try:()=>_7.parse(J),catch:(Q)=>Q}).pipe(G.catch(G.fnUntraced(function*(Q){let V=_7.FrontmatterError.isInstance(Q)?Q.data.message:`Failed to parse skill ${J}`,{Session:X}=yield*G.promise(()=>import("./chunk-0j6dhrew.js"));yield*Z.publish(X.Event.Error,{error:new o9.Unknown({message:V}).toObject()}),H8.error("failed to load skill",{skill:J,err:Q});return})));if(!Y)return;let K=qV.pick({name:!0,description:!0,hidden:!0}).safeParse(Y.data);if(!K.success)return;if($.skills[K.data.name])H8.warn("duplicate skill name",{name:K.data.name,existing:$.skills[K.data.name].location,duplicate:J});$.dirs.add(zJ.dirname(J)),$.skills[K.data.name]={name:K.data.name,description:K.data.description,location:J,content:Y.content,hidden:K.data.hidden}}),x2=G.fnUntraced(function*($,J,Z,Y){let K=yield*G.tryPromise({try:()=>y2.scan(Z,{cwd:J,absolute:!0,include:"file",symlink:!0,dot:Y?.dot}),catch:(Q)=>Q}).pipe(G.catch((Q)=>{if(!Y?.scope)return G.die(Q);return H8.error(`failed to scan ${Y.scope} skills`,{dir:J,error:Q}),G.succeed([])}));for(let Q of K)$.matches.add(Q),$.dirs.add(zJ.dirname(Q))}),Nq=G.fnUntraced(function*($,J,Z,Y,K){let Q={matches:new Set,dirs:new Set};if(!k$.QITQODE_DISABLE_BUILTIN_SKILLS){let W=yield*_V(Z).pipe(G.catch(()=>G.succeed(void 0)));if(W&&(yield*Z.isDir(W)))yield*x2(Q,W,c9,{scope:"builtin"})}if(!k$.QITQODE_DISABLE_COMPOSE_SKILLS){let W=yield*UV(Z).pipe(G.catch(()=>G.succeed(void 0)));if(W&&(yield*Z.isDir(W)))yield*x2(Q,W,c9,{scope:"compose"})}if(!k$.QITQODE_DISABLE_EXTERNAL_SKILLS){let W=Aq.filter((j)=>{if(j===".claude"&&k$.QITQODE_DISABLE_CLAUDE_CODE_SKILLS)return!1;if(j===".codex"&&k$.QITQODE_DISABLE_CODEX_SKILLS)return!1;if(j===".opencode"&&k$.QITQODE_DISABLE_OPENCODE_SKILLS)return!1;return!0});for(let j of W){let H=zJ.join(f$.Path.home,j);if(!(yield*Z.isDir(H)))continue;yield*x2(Q,H,OV,{dot:!0,scope:"global"})}let _=yield*Z.up({targets:W,start:Y,stop:K}).pipe(G.catch(()=>G.succeed([])));for(let j of _)yield*x2(Q,j,OV,{dot:!0,scope:"project"})}let V=yield*$.directories();for(let W of V)yield*x2(Q,W,Sq);let X=yield*$.get();for(let W of X.skills?.paths??[]){let _=W.startsWith("~/")?zJ.join(Pq.homedir(),W.slice(2)):W,j=zJ.isAbsolute(_)?_:zJ.join(Y,_);if(!(yield*Z.isDir(j))){H8.warn("skill path not found",{path:j});continue}yield*x2(Q,j,c9)}for(let W of X.skills?.urls??[]){let _=yield*J.pull(W);for(let j of _)yield*x2(Q,j,c9)}return{matches:Array.from(Q.matches),dirs:Array.from(Q.dirs)}}),yq=G.fnUntraced(function*($,J,Z){yield*G.forEach(J.matches,(Y)=>Lq($,Y,Z),{concurrency:16,discard:!0}),H8.info("init",{count:Object.keys($.skills).length})});class l9 extends D$.Service()("@qitqode/Skill"){}var FV=f.effect(l9,G.gen(function*(){let $=yield*FJ.Service,J=yield*R$.Service,Z=yield*P$.Service,Y=yield*$$.Service,K=yield*i.make(G.fn("Skill.discovery")(function*(H){return yield*Nq(J,$,Y,H.directory,H.worktree)})),Q=yield*i.make(G.fn("Skill.state")(function*(H){let q={skills:{},dirs:new Set};return yield*yq(q,yield*i.get(K),Z),q})),V=G.fn("Skill.get")(function*(H){return(yield*i.get(Q)).skills[H]}),X=G.fn("Skill.all")(function*(){let H=yield*i.get(Q);return Object.values(H.skills)}),W=G.fn("Skill.dirs")(function*(){return(yield*i.get(K)).dirs}),_=G.fn("Skill.available")(function*(H){let q=yield*i.get(Q),U=Object.values(q.skills).filter((z)=>!z.hidden);if(U=U.toSorted((z,M)=>z.name.localeCompare(M.name)),!H)return U;return U.filter((z)=>E$.evaluate("skill",z.name,H.permission).action!=="deny")}),j=G.fn("Skill.reload")(function*(){yield*i.invalidate(K),yield*i.invalidate(Q)});return l9.of({get:V,all:X,dirs:W,available:_,reload:j})})),Tq=FV.pipe(f.provide(FJ.defaultLayer),f.provide(R$.defaultLayer),f.provide(P$.layer),f.provide($$.defaultLayer));function kq($,J){if($.length===0)return"No skills are currently available.";if(J.verbose)return["<available_skills>",...$.sort((Z,Y)=>Z.name.localeCompare(Y.name)).flatMap((Z)=>[" <skill>",` <name>${Z.name}</name>`,` <description>${Z.description}</description>`,` <location>${Iq(Z.location).href}</location>`," </skill>"]),"</available_skills>"].join(`
|
|
7208
7208
|
`);return["## Available Skills",...$.toSorted((Z,Y)=>Z.name.localeCompare(Y.name)).map((Z)=>`- **${Z.name}**: ${Z.description}`)].join(`
|
|
7209
|
-
`)}var g1={};o$(g1,{layer:()=>
|
|
7209
|
+
`)}var g1={};o$(g1,{layer:()=>RV,defaultLayer:()=>pq,Service:()=>n9});import wV from"path";import dq from"os";import*as CJ from"fs/promises";import IV from"path";var q0=b2("memory_fts",{id:t0().primaryKey({autoIncrement:!0}),path:i$().notNull().unique(),scope:i$().notNull(),scope_id:i$().notNull().default(""),type:i$().notNull(),body:i$().notNull(),fingerprint:i$().notNull(),last_indexed_at:t0().notNull()},($)=>[e0("memory_fts_scope_idx").on($.scope,$.scope_id),e0("memory_fts_type_idx").on($.type)]);var Eq=["feedback","project","reference","user"],xq=[{match:/^memory$/i,type:"memory"},{match:/^memory-/i,type:"memory"},{match:/^checkpoint$/,type:"checkpoint"},{match:/^checkpoint-/,type:"checkpoint"},{match:/^tasks\/[^/]+\/progress$/,type:"progress"},{match:/^tasks\/[^/]+\/notes$/,type:"notes"}];function bq($){for(let J of xq)if(J.match.test($))return J.type;return"free"}function zV($){let Z=$.replaceAll("\\","/").match(/\/memory\/(global|projects|sessions)(?:\/([^/]+))?\/(.+)\.md$/);if(!Z)return null;let[,Y,K,Q]=Z,V=Y==="global"?"":K??"",X=Q;return{scope:Y,scope_id:V,type:bq(X),key:X}}var vq=/\/\.claude\/projects\/([^/]+)\/memory\/(.+)\.md$/;function CV($){let J=$.replaceAll("\\","/").match(vq);if(!J)return null;let[,Z,Y]=J;return{scope:"cc",scope_id:Z,type:"free",key:Y}}var hq=/^---\n([\s\S]*?)\n---\n/,gq=/^[ \t]+type:[ \t]*(\w+)[ \t]*$/m;function MV($){let J=$.match(hq);if(!J)return null;let Y=J[1].match(gq);if(!Y)return null;let K=Y[1];return Eq.includes(K)?K:null}var DV=O$.create({service:"memory.reconcile"});async function AV($){let J=[];async function Z(Y){let K=await CJ.readdir(Y,{withFileTypes:!0}).catch((Q)=>{if(Q.code==="ENOENT")return[];throw Q});for(let Q of K){let V=IV.join(Y,Q.name);if(Q.isDirectory())await Z(V);else if(Q.isFile()&&V.endsWith(".md"))J.push(V)}}return await Z($),J}async function fq($){let J=await CJ.readdir($,{withFileTypes:!0}).catch((Y)=>{if(Y.code==="ENOENT")return[];throw Y}),Z=[];for(let Y of J){if(!Y.isDirectory())continue;let K=IV.join($,Y.name,"memory");if(!await CJ.stat(K).then(()=>!0).catch(()=>!1))continue;let V=await AV(K);for(let X of V)Z.push(X)}return Z}async function PV($,J,Z,Y){let K=await CJ.stat($).catch((W)=>{if(W.code==="ENOENT")return null;throw W});if(!K)return"skipped";let Q=`${K.size}-${K.mtimeMs}`;if(Y===Q)return"hit";let V=await Bun.file($).text(),X=Z==="cc"?MV(V)??"free":J.type;return z$.use((W)=>W.insert(q0).values({path:$,scope:J.scope,scope_id:J.scope_id,type:X,body:V,fingerprint:Q,last_indexed_at:Date.now()}).onConflictDoUpdate({target:q0.path,set:{scope:J.scope,scope_id:J.scope_id,type:X,body:V,fingerprint:Q,last_indexed_at:Date.now()}}).run()),"updated"}async function O7($){let J=new Set(await AV($.qode)),Z=$.cc?new Set(await fq($.cc)):new Set,Y=new Set([...J,...Z]),K=new Map(z$.use((X)=>X.select({path:q0.path,fingerprint:q0.fingerprint}).from(q0).all()).map((X)=>[X.path,X.fingerprint])),Q=0;for(let X of K.keys())if(!Y.has(X))z$.use((W)=>W.delete(q0).where(G$(q0.path,X)).run()),Q++;let V=0;for(let X of J){let W=zV(X);if(!W){DV.warn("path outside memory layout, skipping",{path:X});continue}if(await PV(X,W,"qode",K.get(X))==="updated")V++}for(let X of Z){let W=CV(X);if(!W){DV.warn("CC path failed to parse, skipping",{path:X});continue}if(await PV(X,W,"cc",K.get(X))==="updated")V++}return{indexed:V,pruned:Q}}function r9($,J){let Z=$.match(/[\p{L}\p{N}_]+/gu)?.map((K)=>K.trim()).filter(Boolean)??[];if(Z.length===0)return null;return Z.map((K)=>`"${K.replaceAll('"',"")}"`).join(` ${J} `)}function SV($){return r9($,"OR")}var mq=64,uq=8,i9=4096;function s9($){let J=z$.Client().$client,Z=$.conditions.length>0?`WHERE ${$.conditions.join(" AND ")}`:"",Y=`
|
|
7210
7210
|
WITH matched(fts_rowid, fts_score) AS (
|
|
7211
7211
|
SELECT rowid, rank
|
|
7212
7212
|
FROM ${$.idx}
|
|
@@ -7222,25 +7222,25 @@ For full type signatures, all available fields, and more examples:
|
|
|
7222
7222
|
${Z}
|
|
7223
7223
|
ORDER BY matched.fts_score
|
|
7224
7224
|
LIMIT ?
|
|
7225
|
-
`,K=J.query(Y),Q=[],V=Math.max($.limit,
|
|
7225
|
+
`,K=J.query(Y),Q=[],V=Math.max($.limit,mq);for(;;){if(Q=K.all($.ftsQuery,V,...$.params,$.limit),Q.length>=$.limit)break;if($.conditions.length===0)break;if(V>=i9)break;V=Math.min(V*uq,i9)}let X=!1;if(Q.length<$.limit&&$.conditions.length>0&&V>=i9){let H=`
|
|
7226
7226
|
SELECT rowid
|
|
7227
7227
|
FROM ${$.idx}
|
|
7228
7228
|
WHERE ${$.idx} MATCH ?
|
|
7229
7229
|
LIMIT 1 OFFSET ?
|
|
7230
|
-
`;X=J.query(
|
|
7230
|
+
`;X=J.query(H).all($.ftsQuery,i9).length>0}if(Q.length===0)return{rows:[],capped:X};let W=Q.map((H)=>H.fts_rowid),_=`
|
|
7231
7231
|
SELECT rowid AS fts_rowid,
|
|
7232
7232
|
snippet(${$.idx}, 0, '<<', '>>', '...', 32) AS snippet
|
|
7233
7233
|
FROM ${$.idx}
|
|
7234
7234
|
WHERE ${$.idx} MATCH ?
|
|
7235
7235
|
AND rowid IN (${W.map(()=>"?").join(",")})
|
|
7236
|
-
`,j=new Map;for(let
|
|
7236
|
+
`,j=new Map;for(let H of J.query(_).all($.ftsQuery,...W))j.set(H.fts_rowid,H.snippet);return{rows:Q.map(({fts_rowid:H,...q})=>({...q,snippet:j.get(H)??"",score:-q.score})),capped:X}}class n9 extends D$.Service()("@qitqode/Memory"){}var RV=f.effect(n9,G.gen(function*(){let $=yield*R$.Service,J=wV.join(f$.Path.data,"memory"),Z=wV.join(dq.homedir(),".claude","projects"),Y=G.fn("Memory.root")(function*(){return J}),K=G.fn("Memory.reconcile")(function*(){let X=(yield*$.get()).memory?.cc_index?Z:void 0;return yield*G.promise(()=>O7({qode:J,cc:X}))}),Q=G.fn("Memory.search")(function*(V){let X=yield*$.get();if(X.checkpoint?.memory_reconcile_on_search??!0){let D=X.memory?.cc_index?Z:void 0;yield*G.promise(()=>O7({qode:J,cc:D}))}let W=V.limit??10,_=SV(V.query);if(!_)return{results:[],incomplete:!1};let j=X.checkpoint?.memory_search_score_floor??0.15,H=[],q=[];if(V.scope)H.push("memory_fts.scope = ?"),q.push(V.scope);if(V.scope_id)H.push("memory_fts.scope_id = ?"),q.push(V.scope_id);if(V.type)H.push("memory_fts.type = ?"),q.push(V.type);let U=Math.min(W*3,50),z=s9({select:"memory_fts.path, memory_fts.scope, memory_fts.scope_id, memory_fts.type",idx:"memory_fts_idx",contentTable:"memory_fts",contentRowid:"memory_fts.id",conditions:H,params:q,ftsQuery:_,limit:U}),M=z.rows.map((D)=>({path:D.path,snippet:D.snippet,score:D.score,scope:D.scope,scope_id:D.scope_id,type:D.type})),I=z.capped&&M.length<W;if(M.length===0)return{results:[],incomplete:I};let C=M[0].score,P=j>0?C*j:-1/0;return{results:M.filter((D,L)=>L===0||D.score>=P).slice(0,W),incomplete:I}});return n9.of({root:Y,reconcile:K,search:Q})})),pq=f.suspend(()=>RV.pipe(f.provide(R$.defaultLayer)));var MJ={};o$(MJ,{layer:()=>TV,defaultLayer:()=>aq,Service:()=>ZZ});function LV($){return r9($,"AND")}var W2=b2("history_fts",{part_id:i$().primaryKey(),session_id:i$().notNull(),message_id:i$().notNull(),project_id:i$().notNull(),kind:i$().notNull(),tool_name:i$(),body:i$().notNull(),time_created:t0().notNull()},($)=>[e0("history_fts_session_idx").on($.session_id,$.time_created),e0("history_fts_project_idx").on($.project_id,$.time_created),e0("history_fts_message_idx").on($.message_id)]);var _8=["user_text","assistant_text","tool_input","tool_error"];function a9($,J,Z){switch($.type){case"text":{let Y=J==="user"?"user_text":"assistant_text";if(!Z.has(Y))return null;if(!$.text)return null;return{kind:Y,body:$.text,tool_name:null}}case"reasoning":{if(!Z.has("reasoning"))return null;if(!$.text)return null;return{kind:"reasoning",body:$.text,tool_name:null}}case"tool":{let Y=$.state;if(Y.status==="pending"||Y.status==="running")return null;if(Y.status==="error"&&Z.has("tool_error"))return{kind:"tool_error",body:`${$.tool} ${JSON.stringify(Y.input??{})} ${Y.error??""}`,tool_name:$.tool};if(Y.status==="completed"&&Z.has("tool_output"))return{kind:"tool_output",body:`${$.tool} ${JSON.stringify(Y.input??{})} ${JSON.stringify(Y.output??"")}`,tool_name:$.tool};if(Z.has("tool_input"))return{kind:"tool_input",body:`${$.tool} ${JSON.stringify(Y.input??{})}`,tool_name:$.tool};return null}default:return null}}class q7{max;map=new Map;constructor($){this.max=$}get($){let J=this.map.get($);if(J===void 0)return;return this.map.delete($),this.map.set($,J),J}set($,J){if(this.map.has($))this.map.delete($);if(this.map.set($,J),this.map.size>this.max){let Z=this.map.keys().next().value;if(Z!==void 0)this.map.delete(Z)}}}function t9(){let $=new q7(1024),J=new q7(512);return{role:(Z)=>G.sync(()=>{let Y=$.get(Z);if(Y)return Y;let Q=z$.use((V)=>V.select({data:e$.data}).from(e$).where(G$(e$.id,Z)).get())?.data?.role==="user"?"user":"assistant";return $.set(Z,Q),Q}),projectID:(Z)=>G.sync(()=>{let Y=J.get(Z);if(Y)return Y;let Q=z$.use((V)=>V.select({project_id:V0.project_id}).from(V0).where(G$(V0.id,Z)).get())?.project_id??"";return J.set(Z,Q),Q})}}var cq=O$.create({service:"history.writer"});class e9 extends D$.Service()("@qitqode/History.Writer"){}var NV=f.effect(e9,G.gen(function*(){let $=yield*R$.Service,J=yield*P$.Service,Z=yield*i.make(G.fn("History.Writer.state")(function*(Y){let Q=(yield*$.get()).history?.kinds??_8,V=new Set(Q);if(V.size===0)return{started:!0};let X=yield*b1.unbounded(),W=t9();return yield*J.subscribeCallback(E0.Event.PartUpdated,(_)=>{b1.offerUnsafe(X,{type:"upsert",part:_.properties.part,time:_.properties.time})}),yield*J.subscribeCallback(E0.Event.PartRemoved,(_)=>{b1.offerUnsafe(X,{type:"delete",partID:_.properties.partID})}),yield*G.forever(G.gen(function*(){let _=yield*b1.take(X);yield*lq(_,W,V).pipe(G.catchCause((j)=>G.sync(()=>cq.warn("write failed",{cause:String(j)}))))})).pipe(G.forkScoped),{started:!0}}));return e9.of({init:G.fn("History.Writer.init")(function*(){yield*i.get(Z)})})}));function lq($,J,Z){if($.type==="delete")return G.sync(()=>z$.use((Y)=>Y.delete(W2).where(G$(W2.part_id,$.partID)).run()));return G.gen(function*(){let Y=$.part,K=yield*J.role(Y.messageID),Q=a9(Y,K,Z);if(!Q)return;let V=yield*J.projectID(Y.sessionID);z$.use((X)=>X.insert(W2).values({part_id:Y.id,session_id:Y.sessionID,message_id:Y.messageID,project_id:V,kind:Q.kind,tool_name:Q.tool_name,body:Q.body,time_created:$.time}).onConflictDoUpdate({target:W2.part_id,set:{kind:Q.kind,tool_name:Q.tool_name,body:Q.body,time_created:$.time}}).run())})}var F7=O$.create({service:"history.backfill"}),oq=500;function rq($=new Set(_8)){return G.gen(function*(){if($.size===0)return;let J=t9(),Z=z$.use((Y)=>Y.select({id:V0.id,project_id:V0.project_id}).from(V0).orderBy(O8(V0.time_updated)).all());for(let Y of Z)yield*iq(Y,J,$).pipe(G.catchCause((K)=>G.sync(()=>F7.warn("session scan failed",{session:Y.id,cause:String(K)})))),yield*G.sleep("50 millis");F7.info("backfill complete",{sessions:Z.length})})}function iq($,J,Z){return G.gen(function*(){let Y="";while(!0){let K=z$.use((Q)=>Q.select().from($1).where(_0(G$($1.session_id,$.id),JZ($1.id,Y),f1`NOT EXISTS (SELECT 1 FROM history_fts WHERE history_fts.part_id = ${$1.id})`)).orderBy(m1($1.id)).limit(oq).all());if(K.length===0)return;yield*sq(K,$.project_id,J,Z),Y=K[K.length-1].id,yield*G.sleep("10 millis")}})}function sq($,J,Z,Y){return G.gen(function*(){let K=[];for(let Q of $){let V=yield*Z.role(Q.message_id),X={id:Q.id,sessionID:Q.session_id,messageID:Q.message_id,...Q.data},W=a9(X,V,Y);if(!W)continue;K.push({part:Q,kind:W.kind,body:W.body,tool_name:W.tool_name,time:Q.time_created})}if(K.length===0)return;z$.transaction((Q)=>{for(let V of K)Q.insert(W2).values({part_id:V.part.id,session_id:V.part.session_id,message_id:V.part.message_id,project_id:J,kind:V.kind,tool_name:V.tool_name,body:V.body,time_created:V.time}).onConflictDoUpdate({target:W2.part_id,set:{kind:V.kind,tool_name:V.tool_name,body:V.body,time_created:V.time}}).run()})})}class $Z extends D$.Service()("@qitqode/History.Backfill"){}var yV=f.effect($Z,G.gen(function*(){let $=yield*R$.Service;return $Z.of({init:G.fn("History.Backfill.init")(function*(){let Z=(yield*$.get()).history?.kinds??_8,Y=new Set(Z);yield*rq(Y).pipe(G.catchCause((K)=>G.sync(()=>F7.warn("backfill aborted",{cause:String(K)}))),G.forkDetach)})})}));class ZZ extends D$.Service()("@qitqode/History"){}var nq=50,aq=f.suspend(()=>f.mergeAll(TV,NV,yV).pipe(f.provide(R$.defaultLayer),f.provide(P$.defaultLayer))),TV=f.effect(ZZ,G.gen(function*(){let $=G.fn("History.search")(function*(Z){let Y=LV(Z.query);if(!Y)return{hits:[],incomplete:!1};let K=Math.min(Z.limit??10,nq),Q=[],V=[];if((Z.scope??"project")==="project")Q.push("history_fts.project_id = ?"),V.push(B$.project.id);if(Z.session_id)Q.push("history_fts.session_id = ?"),V.push(Z.session_id);if(Z.kind){let _=Array.isArray(Z.kind)?Z.kind:[Z.kind];Q.push(`history_fts.kind IN (${_.map(()=>"?").join(",")})`);for(let j of _)V.push(j)}if(Z.tool_name)Q.push("history_fts.tool_name = ?"),V.push(Z.tool_name);if(Z.time_after!==void 0)Q.push("history_fts.time_created >= ?"),V.push(Z.time_after);if(Z.time_before!==void 0)Q.push("history_fts.time_created <= ?"),V.push(Z.time_before);let W=s9({select:"history_fts.part_id, history_fts.session_id, history_fts.message_id, history_fts.project_id, history_fts.kind, history_fts.tool_name, history_fts.time_created",idx:"history_fts_idx",contentTable:"history_fts",contentRowid:"history_fts.rowid",conditions:Q,params:V,ftsQuery:Y,limit:K});return{hits:W.rows.map((_)=>({part_id:_.part_id,session_id:_.session_id,message_id:_.message_id,project_id:_.project_id,kind:_.kind,tool_name:_.tool_name,snippet:_.snippet,score:_.score,time_created:_.time_created})),incomplete:W.capped}}),J=G.fn("History.around")(function*(Z){let Y=Z.before??5,K=Z.after??5,Q=z$.use((q)=>q.select({id:e$.id,session_id:e$.session_id,time_created:e$.time_created}).from(e$).where(G$(e$.id,Z.message_id)).get());if(!Q)return{session_id:"",messages:[]};let V=z$.use((q)=>q.select().from(e$).where(_0(G$(e$.session_id,Q.session_id),f1`(${e$.time_created} < ${Q.time_created} OR (${e$.time_created} = ${Q.time_created} AND ${e$.id} <= ${Q.id}))`)).orderBy(O8(e$.time_created),O8(e$.id)).limit(Y+1).all()),X=z$.use((q)=>q.select().from(e$).where(_0(G$(e$.session_id,Q.session_id),f1`(${e$.time_created} > ${Q.time_created} OR (${e$.time_created} = ${Q.time_created} AND ${e$.id} > ${Q.id}))`)).orderBy(m1(e$.time_created),m1(e$.id)).limit(K).all()),W=[...V.reverse(),...X];if(W.length===0)return{session_id:Q.session_id,messages:[]};let _=z$.use((q)=>q.select().from($1).where(_0(G$($1.session_id,Q.session_id),f1`${$1.message_id} IN (${f1.join(W.map((U)=>f1`${U.id}`),f1`, `)})`)).orderBy(m1($1.message_id),m1($1.id)).all()),j=new Map;for(let q of _){let U=j.get(q.message_id)??[];U.push(q),j.set(q.message_id,U)}let H=W.map((q)=>{let U=q.data?.role==="user"?"user":"assistant",z=(j.get(q.id)??[]).map((M)=>{let I=M.data,C=I.type==="text"||I.type==="reasoning"?I.text??"":I.type==="tool"?`tool: ${I.tool??""}
|
|
7237
7237
|
input: ${JSON.stringify(I.state?.input??{})}
|
|
7238
|
-
${I.state?.error?`error: ${I.state.error}`:`output: ${JSON.stringify(I.state?.output??"")}`}`:`[${I.type}]`;return{part_id:M.id,type:I.type,role:
|
|
7239
|
-
`),K=[],Q=0;for(let V=0;V<Y.length&&K.length<J;V++){let X=Buffer.byteLength(Y[V],"utf-8")+(V>0?1:0);if(Q+X>Z){if(K.length===0)K.push(
|
|
7240
|
-
`)}function
|
|
7241
|
-
`);if(Y.length<=J&&Buffer.byteLength($,"utf-8")<=Z)return{text:$,cut:!1};let K=[],Q=0;for(let V=Y.length-1;V>=0&&K.length<J;V--){let X=Buffer.byteLength(Y[V],"utf-8")+(K.length>0?1:0);if(Q+X>Z){if(K.length===0)K.unshift(
|
|
7242
|
-
`),cut:!0}}var
|
|
7243
|
-
`),q=Buffer.byteLength(K,"utf-8");if(
|
|
7238
|
+
${I.state?.error?`error: ${I.state.error}`:`output: ${JSON.stringify(I.state?.output??"")}`}`:`[${I.type}]`;return{part_id:M.id,type:I.type,role:U,tool_name:I.type==="tool"?I.tool??null:null,text:C}});return{message_id:q.id,matched:q.id===Z.message_id,time_created:q.time_created,parts:z}});return{session_id:Q.session_id,messages:H}});return ZZ.of({search:$,around:J})}));var j1={};o$(j1,{tailLines:()=>P7,layer:()=>hV,headLines:()=>D7,defaultLayer:()=>I7,Service:()=>Z1,MAX_LINES:()=>DJ,MAX_BYTES:()=>u1,GLOB:()=>YF,DIR:()=>ZF});import z7 from"path";var tq=F$.String.annotate({[KZ]:J1.schema("tool")}).pipe(F$.brand("ToolID")),kV=tq.pipe(YZ(($)=>({ascending:(J)=>$.make(J1.ascending("tool",J)),zod:J1.schema("tool").pipe(F.custom())})));import eq from"path";var v2=eq.join(f$.Path.data,"tool-output");var $F=O$.create({service:"truncation"}),JF=h2.days(7),DJ=2000,u1=51200,ZF=v2,YF=z7.join(v2,"*"),KF=/error|exception|failed|fatal|traceback|panic|exit code/i;function C7($,J){let Z=Buffer.from($,"utf-8");if(Z.length<=J)return $;let Y=Math.min(J,Z.length);while(Y>0&&(Z[Y]&192)===128)Y--;return Z.subarray(0,Y).toString("utf-8")}function M7($,J){let Z=Buffer.from($,"utf-8");if(Z.length<=J)return $;let Y=Math.max(0,Z.length-J);while(Y<Z.length&&(Z[Y]&192)===128)Y++;return Z.subarray(Y).toString("utf-8")}function D7($,J,Z){let Y=$.split(`
|
|
7239
|
+
`),K=[],Q=0;for(let V=0;V<Y.length&&K.length<J;V++){let X=Buffer.byteLength(Y[V],"utf-8")+(V>0?1:0);if(Q+X>Z){if(K.length===0)K.push(C7(Y[V],Z));break}K.push(Y[V]),Q+=X}return K.join(`
|
|
7240
|
+
`)}function P7($,J,Z){let Y=$.split(`
|
|
7241
|
+
`);if(Y.length<=J&&Buffer.byteLength($,"utf-8")<=Z)return{text:$,cut:!1};let K=[],Q=0;for(let V=Y.length-1;V>=0&&K.length<J;V--){let X=Buffer.byteLength(Y[V],"utf-8")+(K.length>0?1:0);if(Q+X>Z){if(K.length===0)K.unshift(M7(Y[V],Z));break}K.unshift(Y[V]),Q+=X}return{text:K.join(`
|
|
7242
|
+
`),cut:!0}}var EV=2048;function xV($){if(!$?.permission)return!1;return vV("actor","*",$.permission).action!=="deny"}class Z1 extends D$.Service()("@qitqode/Truncate"){}var hV=f.effect(Z1,G.gen(function*(){let $=yield*$$.Service,J=G.fn("Truncate.cleanup")(function*(){let K=J1.timestamp(J1.create("tool","ascending",Date.now()-h2.toMillis(JF))),Q=yield*$.readDirectory(v2).pipe(G.map((V)=>V.filter((X)=>X.startsWith("tool_"))),G.catch(()=>G.succeed([])));for(let V of Q){if(J1.timestamp(V)>=K)continue;yield*$.remove(z7.join(v2,V)).pipe(G.catch(()=>G.void))}}),Z=G.fn("Truncate.write")(function*(K){let Q=z7.join(v2,kV.ascending());return yield*$.ensureDir(v2).pipe(G.orDie),yield*$.writeFileString(Q,K).pipe(G.orDie),Q}),Y=G.fn("Truncate.output")(function*(K,Q={},V){let X=Q.maxLines??DJ,W=Q.maxBytes??u1,_=Q.direction??"head+tail";if(Q.pressureCaps??!1)X=Math.floor(X/2),W=Math.floor(W/2);let H=K.split(`
|
|
7243
|
+
`),q=Buffer.byteLength(K,"utf-8");if(H.length<=X&&q<=W)return{content:K,truncated:!1};if(_==="head+tail"){let N=K.length>EV?K.slice(-EV):K;if(KF.test(N)){let b=Math.floor(X*0.7),v=Math.floor(W*0.7),m=X-b,A=W-v,u=[],r=0;for(let J$=0;J$<H.length&&u.length<b;J$++){let Z$=Buffer.byteLength(H[J$],"utf-8")+(J$>0?1:0);if(r+Z$>v){if(u.length===0)u.push(C7(H[J$],v));break}u.push(H[J$]),r+=Z$}let S=[],T=0;for(let J$=H.length-1;J$>=0&&S.length<m;J$--){let Z$=Buffer.byteLength(H[J$],"utf-8")+(S.length>0?1:0);if(T+Z$>A){if(S.length===0)S.unshift(M7(H[J$],A));break}S.unshift(H[J$]),T+=Z$}let k=Math.max(0,H.length-u.length-S.length),A$=yield*Z(K),s=xV(V)?`The tool call succeeded but the output was truncated. Full output saved to: ${A$}
|
|
7244
7244
|
Use the actor tool to have explore agent process this file with Grep and Read (with offset/limit). Do NOT read the full file yourself - delegate to save context.`:`The tool call succeeded but the output was truncated. Full output saved to: ${A$}
|
|
7245
7245
|
Use Grep to search the full content or Read with offset/limit to view specific sections.`;return{content:`${u.join(`
|
|
7246
7246
|
`)}
|
|
@@ -7250,18 +7250,18 @@ Use Grep to search the full content or Read with offset/limit to view specific s
|
|
|
7250
7250
|
${S.join(`
|
|
7251
7251
|
`)}
|
|
7252
7252
|
|
|
7253
|
-
${s}`,truncated:!0,outputPath:A$}}}let
|
|
7254
|
-
`),L=yield*Z(K),R=
|
|
7253
|
+
${s}`,truncated:!0,outputPath:A$}}}let U=[],z=0,M=0,I=!1;if(_==="head"||_==="head+tail")for(z=0;z<H.length&&z<X;z++){let N=Buffer.byteLength(H[z],"utf-8")+(z>0?1:0);if(M+N>W){if(I=!0,U.length===0)U.push(C7(H[z],W)),M+=Buffer.byteLength(U[0],"utf-8");break}U.push(H[z]),M+=N}else for(z=H.length-1;z>=0&&U.length<X;z--){let N=Buffer.byteLength(H[z],"utf-8")+(U.length>0?1:0);if(M+N>W){if(I=!0,U.length===0)U.unshift(M7(H[z],W)),M+=Buffer.byteLength(U[0],"utf-8");break}U.unshift(H[z]),M+=N}let C=I?q-M:H.length-U.length,P=I?"bytes":"lines",D=U.join(`
|
|
7254
|
+
`),L=yield*Z(K),R=xV(V)?`The tool call succeeded but the output was truncated. Full output saved to: ${L}
|
|
7255
7255
|
Use the actor tool to have explore agent process this file with Grep and Read (with offset/limit). Do NOT read the full file yourself - delegate to save context.`:`The tool call succeeded but the output was truncated. Full output saved to: ${L}
|
|
7256
|
-
Use Grep to search the full content or Read with offset/limit to view specific sections.`;return{content:
|
|
7256
|
+
Use Grep to search the full content or Read with offset/limit to view specific sections.`;return{content:_==="head"||_==="head+tail"?`${D}
|
|
7257
7257
|
|
|
7258
|
-
...${
|
|
7258
|
+
...${C} ${P} truncated...
|
|
7259
7259
|
|
|
7260
|
-
${R}`:`...${
|
|
7260
|
+
${R}`:`...${C} ${P} truncated...
|
|
7261
7261
|
|
|
7262
7262
|
${R}
|
|
7263
7263
|
|
|
7264
|
-
${D}`,truncated:!0,outputPath:L}});return yield*
|
|
7264
|
+
${D}`,truncated:!0,outputPath:L}});return yield*bV(J(),(K)=>{return $F.error("truncation cleanup failed",{cause:n0.pretty(K)}),G.void}),Z1.of({cleanup:J,write:Z,output:Y})})),I7=hV.pipe(f.provide($$.defaultLayer),f.provide(g9.layer));var B1={};o$(B1,{normalizeQuestions:()=>w7,normalizeQuestion:()=>mV,normalizeOptionLabel:()=>S7,meaningfulOptions:()=>VF,layer:()=>lV,isFreeTextQuestion:()=>GF,isFillerOption:()=>VZ,defaultLayer:()=>XF,Tool:()=>L7,Service:()=>WZ,Request:()=>UZ,Reply:()=>dV,RejectedError:()=>XZ,Question:()=>B1,Prompt:()=>q8,Option:()=>QZ,Info:()=>R7,Event:()=>GZ,Answer:()=>N7});class PJ extends gV()("QuestionID",F$.String.annotate({[KZ]:J1.schema("question")})){static ascending($){return this.make(J1.ascending("question",$))}static zod=J1.schema("question")}class QZ extends F$.Class("QuestionOption")({label:F$.String.annotate({description:"Display text (1-5 words, concise). Must name a distinct, actionable choice. Never a filler such as 'Other', 'Provide details' or 'Type your own answer' \u2014 a free-text answer is always offered separately and filler options are stripped."}),description:F$.String.annotate({description:"What choosing this option means and what work it leads to"})}){static zod=U1(this)}var A7={question:F$.String.annotate({description:"Complete question"}),header:F$.String.annotate({description:"Very short label (max 30 chars)"}),options:F$.Array(QZ).annotate({description:"At least two mutually exclusive, decision-bearing choices. If you cannot offer two genuinely different choices, do not ask through this tool \u2014 ask for what you need as prose in your reply instead."}),multiple:F$.optional(F$.Boolean).annotate({description:"Allow selecting multiple choices"})};class q8 extends F$.Class("QuestionPrompt")(A7){static zod=U1(this)}var QF=[/^others?$/,/^something else$/,/^(an)?other (option|answer|choice)$/,/^(custom|free ?-?(text|form))( answer| response| input| option)?$/,/^(type|write|enter|input|fill)( in)? (your|my) own( answer| response| text| words)?$/,/^(type|write|enter) (an )?answer$/,/^(provide|give|share|add|supply|include)( me)?( the| more| additional| further| relevant)* ?(details?|context|info|information|specifics|goals?|requirements?)(,? (and |or )?(details?|context|info|information|specifics|goals?|requirements?))*( (here|below))?$/,/^(please )?(specify|elaborate|describe it|explain it|clarify)( (here|below|yourself))?$/,/^tell (me|us) more( here| below)?$/];function S7($){return $.toLowerCase().replace(/\s+/g," ").trim().replace(/^["'\u201C\u201D\u2018\u2019(\[]+/,"").replace(/["'\u201C\u201D\u2018\u2019)\]]+$/,"").replace(/[.!?\u2026:;,\-\u2013\u2014]+$/,"").trim()}function VZ($){let J=S7($.label??"");if(!J)return!0;return QF.some((Z)=>Z.test(J))}function fV($,J){let Z=new Set,Y=[];for(let K of $){let Q=S7(K.label);if(Z.has(Q)){J?.(K.label,"duplicate");continue}Z.add(Q),Y.push(K)}return Y}function VF($){return fV($).filter((J)=>!VZ(J))}function mV($,J){let Z=fV($.options??[],J);if(Z.filter((K)=>!VZ(K)).length>=2){if(Z.length===($.options?.length??0))return $;return{...$,options:Z}}for(let K of Z)J?.(K.label,VZ(K)?"filler":"collapsed");return{...$,options:[],custom:!0,multiple:!1}}function w7($,J){return $.map((Z)=>mV(Z,J))}function GF($){return($.options?.length??0)===0&&$.custom!==!1}var g2=O$.create({service:"question"});class R7 extends F$.Class("QuestionInfo")({...A7,custom:F$.optional(F$.Boolean).annotate({description:"Allow typing a custom answer (default: true)"}),key:F$.optional(F$.String).annotate({description:"i18n key for client-side translation (e.g. plan_exit). When set, clients may translate question/options text using this key as a namespace."}),params:F$.optional(F$.Record(F$.String,F$.String)).annotate({description:"Template parameters for i18n interpolation (e.g. { plan: '.qitqode/plans/...' })"})}){static zod=U1(this)}class L7 extends F$.Class("QuestionTool")({messageID:IJ,callID:F$.String}){static zod=U1(this)}class UZ extends F$.Class("QuestionRequest")({id:PJ,sessionID:F0,questions:F$.Array(R7).annotate({description:"Questions to ask"}),tool:F$.optional(L7)}){static zod=U1(this)}var N7=F$.Array(F$.String).annotate({identifier:"QuestionAnswer"}).pipe(YZ(($)=>({zod:U1($)})));class dV extends F$.Class("QuestionReply")({answers:F$.Array(N7).annotate({description:"User answers in order of questions (each answer is an array of selected labels)"})}){static zod=U1(this)}class pV extends F$.Class("QuestionReplied")({sessionID:F0,requestID:PJ,answers:F$.Array(N7)}){}class cV extends F$.Class("QuestionRejected")({sessionID:F0,requestID:PJ}){}var GZ={Asked:Z0.define("question.asked",UZ.zod),Replied:Z0.define("question.replied",U1(pV)),Rejected:Z0.define("question.rejected",U1(cV))};class XZ extends F$.TaggedErrorClass()("QuestionRejectedError",{}){get message(){return"The user dismissed this question"}}class WZ extends D$.Service()("@qitqode/Question"){}var lV=f.effect(WZ,G.gen(function*(){let $=yield*P$.Service,J=yield*i.make(G.fn("Question.state")(function*(){let _={pending:new Map,neverAsk:!1,declined:new Map};return yield*uV(_.pending,()=>new XZ),_})),Z=G.fn("Question.ask")(function*(_){let j=(yield*i.get(J)).pending,H=PJ.ascending();g2.info("asking",{id:H,questions:_.questions.length});let q=yield*B0.make(),U=w7(_.questions,(M,I)=>g2.debug("stripped question option",{id:H,label:M,reason:I})),z=F$.decodeUnknownSync(UZ)({id:H,sessionID:_.sessionID,questions:U,tool:_.tool});return j.set(H,{info:z,deferred:q}),yield*$.publish(GZ.Asked,z),yield*jZ.awaitDeferred(q,()=>{j.delete(H)})}),Y=G.fn("Question.reply")(function*(_){let j=(yield*i.get(J)).pending,H=j.get(_.requestID);if(!H){g2.warn("reply for unknown request",{requestID:_.requestID});return}j.delete(_.requestID),g2.info("replied",{requestID:_.requestID,answers:_.answers}),yield*$.publish(GZ.Replied,{sessionID:H.info.sessionID,requestID:H.info.id,answers:_.answers}),yield*B0.succeed(H.deferred,_.answers)}),K=G.fn("Question.reject")(function*(_){let j=yield*i.get(J),H=j.pending,q=H.get(_);if(!q){g2.warn("reject for unknown request",{requestID:_});return}H.delete(_),j.declined.set(q.info.sessionID,Date.now()),g2.info("rejected",{requestID:_}),yield*$.publish(GZ.Rejected,{sessionID:q.info.sessionID,requestID:q.info.id}),yield*B0.fail(q.deferred,new XZ)}),Q=G.fn("Question.list")(function*(){let _=(yield*i.get(J)).pending;return Array.from(_.values(),(j)=>j.info)}),V=G.fn("Question.declinedAt")(function*(_){return(yield*i.get(J)).declined.get(_)}),X=G.fn("Question.neverAsk")(function*(){return(yield*i.get(J)).neverAsk}),W=G.fn("Question.setNeverAsk")(function*(_){let j=yield*i.get(J);j.neverAsk=_,g2.info("never-ask",{enabled:_})});return WZ.of({ask:Z,reply:Y,reject:K,list:Q,declinedAt:V,neverAsk:X,setNeverAsk:W})})),XF=lV.pipe(f.provide(P$.layer));import WF from"crypto";var y7=O$.create({service:"bash-interactive"}),oV={Asked:Z0.define("bash.interactive.asked",F.object({id:F.string(),command:F.string(),cwd:F.string(),env:F.record(F.string(),F.string()).optional(),description:F.string()})),Replied:Z0.define("bash.interactive.replied",F.object({id:F.string(),output:F.string(),exitCode:F.number()}))};class rV extends Error{constructor($){super($);this.name="BashInteractiveError"}}class BZ extends D$.Service()("@qitqode/BashInteractive"){}var jF=f.effect(BZ,G.gen(function*(){let $=yield*P$.Service,J=yield*i.make(G.fn("BashInteractive.state")(function*(){let Q={pending:new Map};return yield*G.addFinalizer(()=>G.gen(function*(){for(let V of Q.pending.values())yield*B0.fail(V.deferred,new rV("Instance disposed"));Q.pending.clear()})),Q})),Z=G.fn("BashInteractive.request")(function*(Q){let V=(yield*i.get(J)).pending,X=WF.randomUUID();y7.info("requesting interactive",{id:X,command:Q.command});let W=yield*B0.make(),_={id:X,command:Q.command,cwd:Q.cwd,env:Q.env,description:Q.description};return V.set(X,{request:_,deferred:W}),yield*$.publish(oV.Asked,_),yield*jZ.awaitDeferred(W,()=>{V.delete(X)})}),Y=G.fn("BashInteractive.reply")(function*(Q){let V=(yield*i.get(J)).pending,X=V.get(Q.id);if(!X){y7.warn("reply for unknown request",{id:Q.id});return}V.delete(Q.id),y7.info("replied",{id:Q.id,exitCode:Q.exitCode}),yield*$.publish(oV.Replied,{id:X.request.id,output:Q.output,exitCode:Q.exitCode}),yield*B0.succeed(X.deferred,{output:Q.output,exitCode:Q.exitCode})}),K=G.fn("BashInteractive.list")(function*(){let Q=(yield*i.get(J)).pending;return Array.from(Q.values(),(V)=>V.request)});return BZ.of({request:Z,reply:Y,list:K})})),UF=jF.pipe(f.provide(P$.layer)),{runPromise:BF}=HZ(BZ,UF);function iV($){return BF((J)=>J.request($))}var nV=F.object({tool:F.string(),error:F.string()}),aV=F.object({questions:F.array(q8.zod).describe("Questions to ask")}),tV=F.object({command:F.string().describe("The command to execute"),timeout:F.number().describe("Optional timeout in milliseconds").optional(),workdir:F.string().describe("The working directory to run the command in. Defaults to the current directory. Use this instead of 'cd' commands.").optional(),interactive:F.boolean().describe("Set to true when the command requires user interaction (password input, y/N confirmation, SSH key passphrase, etc). The terminal will be handed to the user for direct interaction.").optional(),description:F.string().describe(`Clear, concise description of what this command does in 5-10 words. Examples:
|
|
7265
7265
|
Input: ls
|
|
7266
7266
|
Output: Lists files in current directory
|
|
7267
7267
|
|
|
@@ -7272,13 +7272,13 @@ Input: npm install
|
|
|
7272
7272
|
Output: Installs package dependencies
|
|
7273
7273
|
|
|
7274
7274
|
Input: mkdir foo
|
|
7275
|
-
Output: Creates directory 'foo'`)}),aV=F.object({filePath:F.string().describe("The absolute path to the file or directory to read"),offset:F.coerce.number().int().min(1).describe("The line number to start reading from (1-indexed)").optional(),limit:F.coerce.number().int().min(1).describe("The maximum number of lines to read (defaults to 2000)").optional()}),tV=F.object({pattern:F.string().describe("The glob pattern to match files against"),path:F.string().optional().describe('The directory to search in. If not specified, the current working directory will be used. IMPORTANT: Omit this field to use the default directory. DO NOT enter "undefined" or "null" - simply omit it for the default behavior. Must be a valid directory path if provided.')}),eV=F.object({pattern:F.string().describe("The regex pattern to search for in file contents"),path:F.string().optional().describe("The directory to search in. Defaults to the current working directory."),include:F.string().optional().describe('File pattern to include in the search (e.g. "*.js", "*.{ts,tsx}")')}),XF=F.object({filePath:F.string().describe("The absolute path to the file to modify"),oldString:F.string().describe("The text to replace"),newString:F.string().describe("The text to replace it with (must be different from oldString)"),replaceAll:F.boolean().optional().describe("Replace all occurrences of oldString (default false)")}),$G=XF,JG=F.object({content:F.string().describe("The content to write to the file"),filePath:F.string().describe("The absolute path to the file to write (must be absolute, not relative)")}),WF="(optional) Model for this subagent: a model group name (e.g. fast/economical/default/power) or a literal provider/model. Overrides the agent's configured model; defaults to the agent's model, else the parent's. If no model_groups are configured, the tier names resolve to their default model.";function ZG($=F.string()){let J=F.string().min(1).describe("Actor session id to operate on. Distinct from the user-task IDs (T1, T2, ...) used by the `task` tool."),Z=F.number().int().positive().optional().describe("(optional) Milliseconds to wait before returning { status: 'timeout' }. Default 600000 (10 min)."),Y=F.string().min(1).describe("A short (3-5 words) description of the task."),K=F.string().min(1).describe("The task for the agent to perform."),Q=$.describe("The type of specialized agent to use for this task."),V=F.string().min(1).optional().describe(WF),X=F.string().min(1).optional().describe("(optional) The command that triggered this task."),W=F.string().min(1).optional().describe("(optional) If this subagent is doing work for a specific task in the `task` tool, pass that task's ID (e.g. T4, T2.1) here \u2014 only an ID the `task` tool returned this session. After completion, the actor.postStop hook validates that tasks/<task_id>/progress.md exists with the required sections. If the ID is malformed or names no existing task, the binding is silently dropped and the subagent's findings are NOT captured to that task. Leave omitted only for work that isn't tied to a task."),B=F.strictObject({action:F.literal("run").describe("Spawn a subagent and block until it completes; the result is returned inline as the tool response."),description:Y,prompt:K,subagent_type:Q,model:V,actor_id:F.string().min(1).optional().describe("(optional) If set, resume the specified prior actor session instead of creating a new one. Distinct from the user-task IDs (T1, T2, ...) used by the `task` tool."),timeout_ms:Z,command:X,context:F.enum(["none","state","full"]).optional().describe("(optional) Context inheritance. 'none' (default): child sees only prompt. 'full': child sees parent conversation (prefix cache sharing). 'state': child gets checkpoint summary."),task_id:W,output_schema:F.record(F.string(),F.any()).optional().describe("(optional) A JSON Schema. When set, the subagent is forced to return a single structured object matching this schema (via the StructuredOutput tool) instead of free text; the validated object is returned in <actor_result>.")}),j=F.strictObject({action:F.literal("spawn").describe("Spawn a subagent and return its actor_id immediately; result is delivered as a notification or via a separate `wait` call."),description:Y,prompt:K,subagent_type:Q,model:V,actor_id:F.string().min(1).optional().describe("(optional) If set, resume the specified prior actor session instead of creating a new one."),command:X,context:F.enum(["none","state","full"]).optional().describe("(optional) Context inheritance. Default 'none'."),task_id:W,output_schema:F.record(F.string(),F.any()).optional().describe("(optional) A JSON Schema. When set, the subagent is forced to return a single structured object matching this schema (via the StructuredOutput tool) instead of free text.")}),_=F.strictObject({action:F.literal("status"),actor_id:J}),q=F.strictObject({action:F.literal("wait"),actor_id:J,timeout_ms:Z}),H=F.strictObject({action:F.literal("cancel"),actor_id:J}),C=F.strictObject({action:F.literal("send"),to_session_id:F.string().min(1).optional().describe("(optional) Target session ID. Defaults to the current session \u2014 useful for sending to subagents in this session."),to_actor_id:F.string().min(1).describe("Target actor ID. Use 'main' to send to a session's main agent, or a subagent ID like 'explore-1'."),content:F.string().min(1).describe("Message content (plain text). Wrapped in <inbox> for the receiver."),type:F.string().optional().describe("(optional) Message type. Default 'text' is wrapped in <inbox>...</inbox>. 'actor_notification' is passed through verbatim (sender pre-renders).")});return F.strictObject({operation:F.discriminatedUnion("action",[B,j,_,q,H,C]).meta({type:"object"})})}var YG=F.object({url:F.string().describe("The URL to fetch content from"),format:F.enum(["text","markdown","html"]).default("markdown").describe("The format to return the content in (text, markdown, or html). Defaults to markdown."),timeout:F.number().min(1).describe("Optional timeout in seconds (min 1, max 120)").optional()}),KG=F.object({query:F.string().describe("Websearch query"),numResults:F.number().optional().describe("Number of search results to return (default: 8)"),timeout:F.number().min(1).describe("Optional timeout in seconds (min 1, max 120)").optional(),livecrawl:F.enum(["fallback","preferred"]).optional().describe("Live crawl mode - 'fallback': use live crawling as backup if cached content unavailable, 'preferred': prioritize live crawling (default: 'fallback')"),type:F.enum(["auto","fast","deep"]).optional().describe("Search type - 'auto': balanced search (default), 'fast': quick results, 'deep': comprehensive search"),contextMaxCharacters:F.number().optional().describe("Maximum characters for context string optimized for LLMs (default: 10000)")}),QG=F.object({query:F.string().describe("Search query to find relevant context for APIs, Libraries, and SDKs. For example, 'React useState hook examples', 'Python pandas dataframe filtering', 'Express.js middleware', 'Next js partial prerendering configuration'"),tokensNum:F.number().min(1000).max(50000).default(5000).describe("Number of tokens to return (1000-50000). Default is 5000 tokens. Adjust this value based on how much context you need - use lower values for focused queries and higher values for comprehensive documentation.")}),VG=F.object({name:F.string().describe("The name of the skill from available_skills")}),GG=F.object({patchText:F.string().describe("The full patch text that describes all changes to be made")}),XG=F.object({path:F.string().describe("The directory to switch to. Absolute or relative to current working directory. Use '~' to reset to project root.")}),jF=["goToDefinition","findReferences","hover","documentSymbol","workspaceSymbol","goToImplementation","prepareCallHierarchy","incomingCalls","outgoingCalls"],WG=F.object({operation:F.enum(jF).describe("The LSP operation to perform"),filePath:F.string().describe("The absolute or relative path to the file"),line:F.number().int().min(1).describe("The line number (1-based, as shown in editors)"),character:F.number().int().min(1).describe("The character offset (1-based, as shown in editors)")}),jG=F.object({}),UG=F.object({}),HG=F.object({operation:F.enum(["search"]).default("search").describe("Memory operation to perform"),query:F.string().describe("Search query (BM25 over markdown bodies)"),scope:F.enum(["global","projects","sessions","cc"]).optional().describe("Filter by memory scope"),scope_id:F.string().optional().describe("Filter by scope id (e.g., session id, task id, project id hash)"),type:F.string().optional().describe("Filter by memory type (pinned, snapshot, learning, progress, free, ...)"),limit:F.number().optional().describe("Max results (default 10)")}),UF=F.enum(["user_text","assistant_text","tool_input","tool_error","reasoning","tool_output"]),BG=F.object({operation:F.enum(["search","around"]).describe("search: FTS BM25; around: pull message context"),query:F.string().optional().describe("FTS query (BM25 over text/tool bodies). Required for operation=search."),scope:F.enum(["project","global"]).optional().describe("Default project."),session_id:F.string().optional(),kind:F.array(UF).optional(),tool_name:F.string().optional().describe("Filter to a specific tool (e.g. Bash, Read)"),time_after:F.number().optional().describe("Unix ms"),time_before:F.number().optional(),limit:F.number().optional().describe("Max 50, default 10"),message_id:F.string().optional().describe("Anchor message id. Required for operation=around."),before:F.number().optional().describe("Default 5"),after:F.number().optional().describe("Default 5")}),HF=F.enum(["open","in_progress","blocked","done","abandoned"]),BF=F.strictObject({action:F.literal("create"),summary:F.string().min(1).describe("Task summary for a single task."),parent_id:F.string().min(1).optional().describe("Parent task id for sub-tasks."),session_id:F.string().min(1).optional().describe("Session id to act on. Defaults to current session.")}),_F=F.strictObject({action:F.literal("list"),status:HF.optional().describe("Filter by status."),include_terminal:F.boolean().optional().describe("Include done/abandoned tasks. Default false."),include_archived:F.boolean().optional().describe("Include archived tasks. Default false."),session_id:F.string().min(1).optional().describe("Session id to act on. Defaults to current session.")}),OF=F.strictObject({action:F.literal("get"),id:F.string().min(1).describe("Task id, e.g. T1 or T1.1."),session_id:F.string().min(1).optional().describe("Session id to act on. Defaults to current session.")}),qF=F.strictObject({action:F.literal("start"),id:F.string().min(1).describe("Task id, e.g. T1 or T1.1."),event_summary:F.string().min(1).optional().describe("Short note on starting."),session_id:F.string().min(1).optional().describe("Session id to act on. Defaults to current session.")}),FF=F.strictObject({action:F.literal("block"),id:F.string().min(1).describe("Task id, e.g. T1 or T1.1."),event_summary:F.string().min(1).optional().describe("Short reason for blocking."),session_id:F.string().min(1).optional().describe("Session id to act on. Defaults to current session.")}),zF=F.strictObject({action:F.literal("unblock"),id:F.string().min(1).describe("Task id, e.g. T1 or T1.1."),event_summary:F.string().min(1).optional().describe("Short reason for unblocking."),session_id:F.string().min(1).optional().describe("Session id to act on. Defaults to current session.")}),CF=F.strictObject({action:F.literal("done"),id:F.string().min(1).describe("Task id, e.g. T1 or T1.1."),event_summary:F.string().min(1).optional().describe("Short summary of what was completed."),session_id:F.string().min(1).optional().describe("Session id to act on. Defaults to current session.")}),MF=F.strictObject({action:F.literal("abandon"),id:F.string().min(1).describe("Task id, e.g. T1 or T1.1."),event_summary:F.string().min(1).optional().describe("Short reason for abandoning."),session_id:F.string().min(1).optional().describe("Session id to act on. Defaults to current session.")}),DF=F.strictObject({action:F.literal("rename"),id:F.string().min(1).describe("Task id, e.g. T1 or T1.1."),summary:F.string().min(1).describe("New task summary."),session_id:F.string().min(1).optional().describe("Session id to act on. Defaults to current session.")}),_G=F.strictObject({operation:F.discriminatedUnion("action",[BF,_F,OF,qF,FF,zF,CF,MF,DF]).meta({type:"object"})}),PF=F.strictObject({operation:F.literal("run"),name:F.string().min(1).optional().describe('(optional) Name of a built-in workflow to run (e.g. "deep-research"). Provide EITHER name OR script, not both.'),script:F.string().min(1).optional().describe("(optional) Inline JS workflow script; must begin with `export const meta = {...}`. Provide EITHER name OR script, not both."),args:F.any().optional().describe("(optional) JSON value exposed to the script as `args`."),workspace:F.string().optional().describe("(optional) Absolute dir the script's file primitives (readFile/writeFile/glob/exists) are jailed to. Defaults to the project worktree."),async:F.boolean().optional().describe("(optional) When true, return a run_id immediately and let the workflow run in the background; the result arrives later as an inbox notification. Default false: block until terminal and return the transcript inline (skill-like semantics, recommended for short workflows).")}),IF=F.strictObject({operation:F.literal("status"),run_id:F.string().min(1)}),AF=F.strictObject({operation:F.literal("wait"),run_id:F.string().min(1),timeout_ms:F.number().int().positive().optional()}),SF=F.strictObject({operation:F.literal("cancel"),run_id:F.string().min(1)}),wF=F.strictObject({operation:F.literal("resume"),run_id:F.string().min(1)}),OG=F.discriminatedUnion("operation",[PF,IF,AF,SF,wF]);import E3 from"os";import{createWriteStream as fA}from"fs";import{open as mA,stat as uA}from"fs/promises";class E0 extends Error{recoverable=!0;constructor($,J){super($,J);this.name="RecoverableError"}}function Yy($){if($ instanceof E0)return!0;return qG($)&&$.recoverable===!0}var p0={};o$(p0,{layer:()=>XH,defaultLayer:()=>PA,Service:()=>P6,Info:()=>DA,Agent:()=>p0});var aU={};o$(aU,{renderWorkflowCatalog:()=>sU,layer:()=>nU,defaultLayer:()=>MA,Service:()=>M6});import RF from"path";function LF($){for(let J of k0.stream($,{agentID:"*"}))if(J.info.role==="user"&&J.info.model)return J.info.model;return}var FG=G.fn("runPlanSwitch")(function*($,J,Z){let Y=yield*$.session.get(J.sessionID),K=RF.relative(H$.worktree,Y1.plan(Y)),V=(yield*$.question.ask({sessionID:J.sessionID,questions:[{key:Z.key,params:{plan:K},question:Z.question(K),header:"Plan",options:Z.options}],tool:J.callID?{messageID:J.messageID,callID:J.callID}:void 0}))[0]?.[0];if(V==="No")return yield*new H1.RejectedError;if(V!=="Yes")return{title:"User provided feedback",output:`User chose not to switch yet and provided feedback: ${V}`,metadata:{switched:!1,feedback:V}};let X=LF(J.sessionID)??(yield*$.provider.defaultModel()),W={id:IJ.ascending(),sessionID:J.sessionID,role:"user",time:{created:Date.now()},agent:Z.agent,model:X};return yield*$.session.updateMessage(W),yield*$.session.updatePart({id:f2.ascending(),messageID:W.id,sessionID:J.sessionID,type:"text",text:Z.text(K),synthetic:!0}),{title:Z.title,output:Z.output,metadata:{switched:!0,feedback:""}}}),zG=B$("plan_enter",G.gen(function*(){let $=(yield*e.toolDescriptionEffect("plan_enter"))??"",J=yield*Y1.Service,Z=yield*H1.Service,Y=yield*B1.Service;return{description:$,parameters:jG,execute:(K,Q)=>G.gen(function*(){if(Q.agent==="plan")return{title:"Already in plan mode",output:"You are already in plan mode. This tool is only effective outside of plan mode.",metadata:{switched:!1,feedback:""}};return yield*FG({session:J,question:Z,provider:Y},Q,{key:"plan_enter",question:()=>"Would you like to switch to plan mode for structured planning?",options:[{label:"Yes",description:"Switch to plan agent for read-only planning"},{label:"No",description:"Stay in current mode"}],agent:"plan",text:(V)=>`Switched to plan mode. Create a plan at ${V}`,title:"Switching to plan agent",output:"User approved switching to plan agent. Wait for further instructions."})}).pipe(G.orDie)}})),CG=B$("plan_exit",G.gen(function*(){let $=(yield*e.toolDescriptionEffect("plan_exit"))??"",J=yield*Y1.Service,Z=yield*H1.Service,Y=yield*B1.Service;return{description:$,parameters:UG,execute:(K,Q)=>G.gen(function*(){if(Q.agent!=="plan")return{title:"Not in plan mode",output:"You are not in plan mode. This tool is only effective in plan mode.",metadata:{switched:!1,feedback:""}};return yield*FG({session:J,question:Z,provider:Y},Q,{key:"plan_exit",question:(V)=>`Plan at ${V} is complete. Would you like to switch to the build agent and start implementing?`,options:[{label:"Yes",description:"Switch to build agent and start implementing the plan"},{label:"No",description:"Stay with plan agent to continue refining the plan"}],agent:"build",text:(V)=>`The plan at ${V} has been approved, you can now edit files. Execute the plan`,title:"Switching to build agent",output:"User approved switching to build agent. Wait for further instructions."})}).pipe(G.orDie)}}));var NF=sV,yF=`
|
|
7275
|
+
Output: Creates directory 'foo'`)}),eV=F.object({filePath:F.string().describe("The absolute path to the file or directory to read"),offset:F.coerce.number().int().min(1).describe("The line number to start reading from (1-indexed)").optional(),limit:F.coerce.number().int().min(1).describe("The maximum number of lines to read (defaults to 2000)").optional()}),$G=F.object({pattern:F.string().describe("The glob pattern to match files against"),path:F.string().optional().describe('The directory to search in. If not specified, the current working directory will be used. IMPORTANT: Omit this field to use the default directory. DO NOT enter "undefined" or "null" - simply omit it for the default behavior. Must be a valid directory path if provided.')}),JG=F.object({pattern:F.string().describe("The regex pattern to search for in file contents"),path:F.string().optional().describe("The directory to search in. Defaults to the current working directory."),include:F.string().optional().describe('File pattern to include in the search (e.g. "*.js", "*.{ts,tsx}")')}),HF=F.object({filePath:F.string().describe("The absolute path to the file to modify"),oldString:F.string().describe("The text to replace"),newString:F.string().describe("The text to replace it with (must be different from oldString)"),replaceAll:F.boolean().optional().describe("Replace all occurrences of oldString (default false)")}),ZG=HF,YG=F.object({content:F.string().describe("The content to write to the file"),filePath:F.string().describe("The absolute path to the file to write (must be absolute, not relative)")}),_F="(optional) Model for this subagent: a model group name (e.g. fast/economical/default/power) or a literal provider/model. Overrides the agent's configured model; defaults to the agent's model, else the parent's. If no model_groups are configured, the tier names resolve to their default model.";function KG($=F.string()){let J=F.string().min(1).describe("Actor session id to operate on. Distinct from the user-task IDs (T1, T2, ...) used by the `task` tool."),Z=F.number().int().positive().optional().describe("(optional) Milliseconds to wait before returning { status: 'timeout' }. Default 600000 (10 min)."),Y=F.string().min(1).describe("A short (3-5 words) description of the task."),K=F.string().min(1).describe("The task for the agent to perform."),Q=$.describe("The type of specialized agent to use for this task."),V=F.string().min(1).optional().describe(_F),X=F.string().min(1).optional().describe("(optional) The command that triggered this task."),W=F.string().min(1).optional().describe("(optional) If this subagent is doing work for a specific task in the `task` tool, pass that task's ID (e.g. T4, T2.1) here \u2014 only an ID the `task` tool returned this session. After completion, the actor.postStop hook validates that tasks/<task_id>/progress.md exists with the required sections. If the ID is malformed or names no existing task, the binding is silently dropped and the subagent's findings are NOT captured to that task. Leave omitted only for work that isn't tied to a task."),_=F.strictObject({action:F.literal("run").describe("Spawn a subagent and block until it completes; the result is returned inline as the tool response."),description:Y,prompt:K,subagent_type:Q,model:V,actor_id:F.string().min(1).optional().describe("(optional) If set, resume the specified prior actor session instead of creating a new one. Distinct from the user-task IDs (T1, T2, ...) used by the `task` tool."),timeout_ms:Z,command:X,context:F.enum(["none","state","full"]).optional().describe("(optional) Context inheritance. 'none' (default): child sees only prompt. 'full': child sees parent conversation (prefix cache sharing). 'state': child gets checkpoint summary."),task_id:W,output_schema:F.record(F.string(),F.any()).optional().describe("(optional) A JSON Schema. When set, the subagent is forced to return a single structured object matching this schema (via the StructuredOutput tool) instead of free text; the validated object is returned in <actor_result>.")}),j=F.strictObject({action:F.literal("spawn").describe("Spawn a subagent and return its actor_id immediately; result is delivered as a notification or via a separate `wait` call."),description:Y,prompt:K,subagent_type:Q,model:V,actor_id:F.string().min(1).optional().describe("(optional) If set, resume the specified prior actor session instead of creating a new one."),command:X,context:F.enum(["none","state","full"]).optional().describe("(optional) Context inheritance. Default 'none'."),task_id:W,output_schema:F.record(F.string(),F.any()).optional().describe("(optional) A JSON Schema. When set, the subagent is forced to return a single structured object matching this schema (via the StructuredOutput tool) instead of free text.")}),H=F.strictObject({action:F.literal("status"),actor_id:J}),q=F.strictObject({action:F.literal("wait"),actor_id:J,timeout_ms:Z}),U=F.strictObject({action:F.literal("cancel"),actor_id:J}),z=F.strictObject({action:F.literal("send"),to_session_id:F.string().min(1).optional().describe("(optional) Target session ID. Defaults to the current session \u2014 useful for sending to subagents in this session."),to_actor_id:F.string().min(1).describe("Target actor ID. Use 'main' to send to a session's main agent, or a subagent ID like 'explore-1'."),content:F.string().min(1).describe("Message content (plain text). Wrapped in <inbox> for the receiver."),type:F.string().optional().describe("(optional) Message type. Default 'text' is wrapped in <inbox>...</inbox>. 'actor_notification' is passed through verbatim (sender pre-renders).")});return F.strictObject({operation:F.discriminatedUnion("action",[_,j,H,q,U,z]).meta({type:"object"})})}var QG=F.object({url:F.string().describe("The URL to fetch content from"),format:F.enum(["text","markdown","html"]).default("markdown").describe("The format to return the content in (text, markdown, or html). Defaults to markdown."),timeout:F.number().min(1).describe("Optional timeout in seconds (min 1, max 120)").optional()}),VG=F.object({query:F.string().describe("Websearch query"),numResults:F.number().optional().describe("Number of search results to return (default: 8)"),timeout:F.number().min(1).describe("Optional timeout in seconds (min 1, max 120)").optional(),livecrawl:F.enum(["fallback","preferred"]).optional().describe("Live crawl mode - 'fallback': use live crawling as backup if cached content unavailable, 'preferred': prioritize live crawling (default: 'fallback')"),type:F.enum(["auto","fast","deep"]).optional().describe("Search type - 'auto': balanced search (default), 'fast': quick results, 'deep': comprehensive search"),contextMaxCharacters:F.number().optional().describe("Maximum characters for context string optimized for LLMs (default: 10000)")}),GG=F.object({query:F.string().describe("Search query to find relevant context for APIs, Libraries, and SDKs. For example, 'React useState hook examples', 'Python pandas dataframe filtering', 'Express.js middleware', 'Next js partial prerendering configuration'"),tokensNum:F.number().min(1000).max(50000).default(5000).describe("Number of tokens to return (1000-50000). Default is 5000 tokens. Adjust this value based on how much context you need - use lower values for focused queries and higher values for comprehensive documentation.")}),XG=F.object({name:F.string().describe("The name of the skill from available_skills")}),WG=F.object({patchText:F.string().describe("The full patch text that describes all changes to be made")}),jG=F.object({path:F.string().describe("The directory to switch to. Absolute or relative to current working directory. Use '~' to reset to project root.")}),OF=["goToDefinition","findReferences","hover","documentSymbol","workspaceSymbol","goToImplementation","prepareCallHierarchy","incomingCalls","outgoingCalls"],UG=F.object({operation:F.enum(OF).describe("The LSP operation to perform"),filePath:F.string().describe("The absolute or relative path to the file"),line:F.number().int().min(1).describe("The line number (1-based, as shown in editors)"),character:F.number().int().min(1).describe("The character offset (1-based, as shown in editors)")}),BG=F.object({}),HG=F.object({}),_G=F.object({operation:F.enum(["search"]).default("search").describe("Memory operation to perform"),query:F.string().describe("Search query (BM25 over markdown bodies)"),scope:F.enum(["global","projects","sessions","cc"]).optional().describe("Filter by memory scope"),scope_id:F.string().optional().describe("Filter by scope id (e.g., session id, task id, project id hash)"),type:F.string().optional().describe("Filter by memory type (pinned, snapshot, learning, progress, free, ...)"),limit:F.number().optional().describe("Max results (default 10)")}),qF=F.enum(["user_text","assistant_text","tool_input","tool_error","reasoning","tool_output"]),OG=F.object({operation:F.enum(["search","around"]).describe("search: FTS BM25; around: pull message context"),query:F.string().optional().describe("FTS query (BM25 over text/tool bodies). Required for operation=search."),scope:F.enum(["project","global"]).optional().describe("Default project."),session_id:F.string().optional(),kind:F.array(qF).optional(),tool_name:F.string().optional().describe("Filter to a specific tool (e.g. Bash, Read)"),time_after:F.number().optional().describe("Unix ms"),time_before:F.number().optional(),limit:F.number().optional().describe("Max 50, default 10"),message_id:F.string().optional().describe("Anchor message id. Required for operation=around."),before:F.number().optional().describe("Default 5"),after:F.number().optional().describe("Default 5")}),FF=F.enum(["open","in_progress","blocked","done","abandoned"]),zF=F.strictObject({action:F.literal("create"),summary:F.string().min(1).describe("Task summary for a single task."),parent_id:F.string().min(1).optional().describe("Parent task id for sub-tasks."),session_id:F.string().min(1).optional().describe("Session id to act on. Defaults to current session.")}),CF=F.strictObject({action:F.literal("list"),status:FF.optional().describe("Filter by status."),include_terminal:F.boolean().optional().describe("Include done/abandoned tasks. Default false."),include_archived:F.boolean().optional().describe("Include archived tasks. Default false."),session_id:F.string().min(1).optional().describe("Session id to act on. Defaults to current session.")}),MF=F.strictObject({action:F.literal("get"),id:F.string().min(1).describe("Task id, e.g. T1 or T1.1."),session_id:F.string().min(1).optional().describe("Session id to act on. Defaults to current session.")}),DF=F.strictObject({action:F.literal("start"),id:F.string().min(1).describe("Task id, e.g. T1 or T1.1."),event_summary:F.string().min(1).optional().describe("Short note on starting."),session_id:F.string().min(1).optional().describe("Session id to act on. Defaults to current session.")}),PF=F.strictObject({action:F.literal("block"),id:F.string().min(1).describe("Task id, e.g. T1 or T1.1."),event_summary:F.string().min(1).optional().describe("Short reason for blocking."),session_id:F.string().min(1).optional().describe("Session id to act on. Defaults to current session.")}),IF=F.strictObject({action:F.literal("unblock"),id:F.string().min(1).describe("Task id, e.g. T1 or T1.1."),event_summary:F.string().min(1).optional().describe("Short reason for unblocking."),session_id:F.string().min(1).optional().describe("Session id to act on. Defaults to current session.")}),AF=F.strictObject({action:F.literal("done"),id:F.string().min(1).describe("Task id, e.g. T1 or T1.1."),event_summary:F.string().min(1).optional().describe("Short summary of what was completed."),session_id:F.string().min(1).optional().describe("Session id to act on. Defaults to current session.")}),SF=F.strictObject({action:F.literal("abandon"),id:F.string().min(1).describe("Task id, e.g. T1 or T1.1."),event_summary:F.string().min(1).optional().describe("Short reason for abandoning."),session_id:F.string().min(1).optional().describe("Session id to act on. Defaults to current session.")}),wF=F.strictObject({action:F.literal("rename"),id:F.string().min(1).describe("Task id, e.g. T1 or T1.1."),summary:F.string().min(1).describe("New task summary."),session_id:F.string().min(1).optional().describe("Session id to act on. Defaults to current session.")}),qG=F.strictObject({operation:F.discriminatedUnion("action",[zF,CF,MF,DF,PF,IF,AF,SF,wF]).meta({type:"object"})}),RF=F.strictObject({operation:F.literal("run"),name:F.string().min(1).optional().describe('(optional) Name of a built-in workflow to run (e.g. "deep-research"). Provide EITHER name OR script, not both.'),script:F.string().min(1).optional().describe("(optional) Inline JS workflow script; must begin with `export const meta = {...}`. Provide EITHER name OR script, not both."),args:F.any().optional().describe("(optional) JSON value exposed to the script as `args`."),workspace:F.string().optional().describe("(optional) Absolute dir the script's file primitives (readFile/writeFile/glob/exists) are jailed to. Defaults to the project worktree."),async:F.boolean().optional().describe("(optional) When true, return a run_id immediately and let the workflow run in the background; the result arrives later as an inbox notification. Default false: block until terminal and return the transcript inline (skill-like semantics, recommended for short workflows).")}),LF=F.strictObject({operation:F.literal("status"),run_id:F.string().min(1)}),NF=F.strictObject({operation:F.literal("wait"),run_id:F.string().min(1),timeout_ms:F.number().int().positive().optional()}),yF=F.strictObject({operation:F.literal("cancel"),run_id:F.string().min(1)}),TF=F.strictObject({operation:F.literal("resume"),run_id:F.string().min(1)}),FG=F.discriminatedUnion("operation",[RF,LF,NF,yF,TF]);import b3 from"os";import{createWriteStream as cA}from"fs";import{open as lA,stat as oA}from"fs/promises";class w0 extends Error{recoverable=!0;constructor($,J){super($,J);this.name="RecoverableError"}}function Wy($){if($ instanceof w0)return!0;return zG($)&&$.recoverable===!0}function _Z($,J){if(typeof $!=="string")return{value:$,decoded:!1,attempts:0};if($.trim()==="")return{value:$,decoded:!1,attempts:0};let Z=J?.maxDecodes,Y=Number.isFinite(Z)&&Z>=0?Z:2,K=Math.min(Y+1,3),Q=$,V=0;for(let X=0;X<K;X++){if(typeof Q!=="string")break;let W;try{W=JSON.parse(Q)}catch{return{value:$,decoded:!1,attempts:V}}if(V++,W!==null&&typeof W==="object")return{value:W,decoded:!0,attempts:V};if(typeof W==="string"){Q=W;continue}return{value:$,decoded:!1,attempts:V}}return{value:$,decoded:!1,attempts:V}}function CG($,J=500){let Z;try{Z=typeof $==="string"?$:JSON.stringify($)??String($)}catch{try{Z=String($)}catch{Z="<unrenderable>"}}let Y=J>0?J:0;if(Z.length<=Y)return Z;return`${Z.slice(0,Y)}\u2026 (${Z.length} chars total)`}var p0={};o$(p0,{layer:()=>BB,defaultLayer:()=>wA,Service:()=>A6,Info:()=>SA,Agent:()=>p0});var JB={};o$(JB,{renderWorkflowCatalog:()=>eU,layer:()=>$B,defaultLayer:()=>AA,Service:()=>P6});import kF from"path";function EF($){for(let J of E0.stream($,{agentID:"*"}))if(J.info.role==="user"&&J.info.model)return J.info.model;return}var MG=G.fn("runPlanSwitch")(function*($,J,Z){let Y=yield*$.session.get(J.sessionID),K=kF.relative(B$.worktree,Y1.plan(Y)),V=(yield*$.question.ask({sessionID:J.sessionID,questions:[{key:Z.key,params:{plan:K},question:Z.question(K),header:"Plan",options:Z.options}],tool:J.callID?{messageID:J.messageID,callID:J.callID}:void 0}))[0]?.[0];if(V==="No")return yield*new B1.RejectedError;if(V!=="Yes")return{title:"User provided feedback",output:`User chose not to switch yet and provided feedback: ${V}`,metadata:{switched:!1,feedback:V}};let X=EF(J.sessionID)??(yield*$.provider.defaultModel()),W={id:IJ.ascending(),sessionID:J.sessionID,role:"user",time:{created:Date.now()},agent:Z.agent,model:X};return yield*$.session.updateMessage(W),yield*$.session.updatePart({id:f2.ascending(),messageID:W.id,sessionID:J.sessionID,type:"text",text:Z.text(K),synthetic:!0}),{title:Z.title,output:Z.output,metadata:{switched:!0,feedback:""}}}),DG=H$("plan_enter",G.gen(function*(){let $=(yield*e.toolDescriptionEffect("plan_enter"))??"",J=yield*Y1.Service,Z=yield*B1.Service,Y=yield*H1.Service;return{description:$,parameters:BG,execute:(K,Q)=>G.gen(function*(){if(Q.agent==="plan")return{title:"Already in plan mode",output:"You are already in plan mode. This tool is only effective outside of plan mode.",metadata:{switched:!1,feedback:""}};return yield*MG({session:J,question:Z,provider:Y},Q,{key:"plan_enter",question:()=>"Would you like to switch to plan mode for structured planning?",options:[{label:"Yes",description:"Switch to plan agent for read-only planning"},{label:"No",description:"Stay in current mode"}],agent:"plan",text:(V)=>`Switched to plan mode. Create a plan at ${V}`,title:"Switching to plan agent",output:"User approved switching to plan agent. Wait for further instructions."})}).pipe(G.orDie)}})),PG=H$("plan_exit",G.gen(function*(){let $=(yield*e.toolDescriptionEffect("plan_exit"))??"",J=yield*Y1.Service,Z=yield*B1.Service,Y=yield*H1.Service;return{description:$,parameters:HG,execute:(K,Q)=>G.gen(function*(){if(Q.agent!=="plan")return{title:"Not in plan mode",output:"You are not in plan mode. This tool is only effective in plan mode.",metadata:{switched:!1,feedback:""}};return yield*MG({session:J,question:Z,provider:Y},Q,{key:"plan_exit",question:(V)=>`Plan at ${V} is complete. Would you like to switch to the build agent and start implementing?`,options:[{label:"Yes",description:"Switch to build agent and start implementing the plan"},{label:"No",description:"Stay with plan agent to continue refining the plan"}],agent:"build",text:(V)=>`The plan at ${V} has been approved, you can now edit files. Execute the plan`,title:"Switching to build agent",output:"User approved switching to build agent. Wait for further instructions."})}).pipe(G.orDie)}}));var xF=aV,bF=`
|
|
7276
7276
|
|
|
7277
7277
|
## Client rules for this prompt
|
|
7278
7278
|
- A free-text answer is ALWAYS offered alongside your options. Never add an option that only means "Type your own answer", "Provide details", "Other" or similar \u2014 the client strips those, and a list with one real entry is not a choice.
|
|
7279
7279
|
- Only call this tool when you can offer at least TWO mutually exclusive, decision-bearing options. Every option must be a distinct, actionable choice that leads to visibly different work.
|
|
7280
7280
|
- If there is no real choice to make \u2014 you simply need more information, context or goals \u2014 ask for it as prose in your reply. Do NOT call this tool for that.
|
|
7281
|
-
- The user may dismiss the prompt. You then get a "declined" result: proceed with your best judgement or stop and wait for direction. Do not re-ask the same question.`,
|
|
7281
|
+
- The user may dismiss the prompt. You then get a "declined" result: proceed with your best judgement or stop and wait for direction. Do not re-ask the same question.`,IG=($)=>({title:`Dismissed ${$} question${$===1?"":"s"}`,output:"The user declined to answer and dismissed the question. This is final for this turn \u2014 do NOT ask again. "+"Either proceed with your best judgement using what you already know, or stop and wait for the user to give direction.",metadata:{answers:[],declined:!0}});function vF($){for(let J=$.length-1;J>=0;J--){let Z=$[J]?.info;if(Z?.role==="user")return Z.time.created}return 0}var AG=H$("question",G.gen(function*(){let $=((yield*e.toolDescriptionEffect("question"))??"")+bF,J=yield*B1.Service;return{description:$,parameters:xF,execute:(Z,Y)=>G.gen(function*(){if(yield*J.neverAsk())return{title:`Auto-resolved ${Z.questions.length} question${Z.questions.length>1?"s":""}`,output:"[Never-Ask] No user is available to answer (never-ask mode is on). "+"Re-evaluate the options you just proposed for unattended/headless execution \u2014 "+"prefer text-only, non-interactive, minimal-scope paths and avoid anything that needs a GUI or the user to be present. Pick the best option yourself and continue. "+"IMPORTANT: You MUST explicitly state which option you chose and why in your response text (not just in thinking) \u2014 "+"the user will review the conversation history later and needs to see what you decided without expanding thinking blocks. This applies only to this question; never-ask may be turned off later, so keep using the question tool at future decision points (the user may have returned).",metadata:{answers:Z.questions.map(()=>["[Never-Ask] The model will decide autonomously"])}};let K=yield*J.declinedAt(Y.sessionID);if(K!==void 0&&K>=vF(Y.messages))return IG(Z.questions.length);let Q=yield*J.ask({sessionID:Y.sessionID,questions:Z.questions,tool:Y.callID?{messageID:Y.messageID,callID:Y.callID}:void 0}).pipe(G.catch(()=>G.succeed(void 0)));if(Q===void 0)return IG(Z.questions.length);let V=Z.questions.map((X,W)=>`"${X.question}"="${Q[W]?.length?Q[W].join(", "):"Unanswered"}"`).join(", ");return{title:`Asked ${Z.questions.length} question${Z.questions.length>1?"s":""}`,output:`User has answered your questions: ${V}. You can now continue with the user's answers in mind.`,metadata:{answers:Q}}}).pipe(G.orDie)}}));import*as SJ from"path";var t$={};o$(t$,{set:()=>mF,get:()=>fF,clear:()=>uF,SessionCwd:()=>t$,Event:()=>gF});var hF=1000,j2=new Map;SG(async()=>{j2.clear()});var gF={Changed:Z0.define("session.cwd",F.object({sessionID:F0.zod,cwd:F.string()}))};function fF($){return j2.get($)??B$.directory}function mF($,J){if(j2.delete($),j2.set($,J),j2.size>hF){let Z=j2.keys().next().value;if(Z!==void 0)j2.delete(Z)}}function uF($){j2.delete($)}import m2 from"path";import*as x0 from"path";var dF=["global","projects","sessions"],pF=/^T\d+(\.\d+)*$/;function cF($){if($.length<3)return!1;if($[0]==="projects"){if($.length!==3)return!1;let J=$[2];if(!J.endsWith(".md"))return!1;let Z=J.toLowerCase();return Z==="memory.md"||Z.startsWith("memory-")}if($[0]==="sessions"){let J=$.slice(2);if(J.length===1){let Z=J[0];if(!Z.endsWith(".md"))return!1;return Z==="checkpoint.md"||Z==="notes.md"||Z.startsWith("checkpoint-")}if(J.length===3&&J[0]==="tasks")return pF.test(J[1])&&J[2].endsWith(".md");return!1}return!1}function wG($,J,Z){return`Memory writes go under <memoryRoot>/<scope>/<scope_id>/<key>.md (scope: global | projects | sessions). You attempted: ${Z}.
|
|
7282
7282
|
|
|
7283
7283
|
Canonical main-agent paths (copy verbatim):
|
|
7284
7284
|
${$}
|
|
@@ -7286,214 +7286,214 @@ Canonical main-agent paths (copy verbatim):
|
|
|
7286
7286
|
${J}
|
|
7287
7287
|
`+" Append `## [turn N \xB7 ISO-Z]` entries for free-form scratch.\n"+`
|
|
7288
7288
|
Other free-form <key>.md under a valid scope dir are also allowed.
|
|
7289
|
-
checkpoint.md, task progress, and memory-/checkpoint-<topic>.md spillovers are checkpoint-writer's domain.`}function
|
|
7289
|
+
checkpoint.md, task progress, and memory-/checkpoint-<topic>.md spillovers are checkpoint-writer's domain.`}function lF($){if($[0]!=="sessions"||$.length<4)return!1;if($[2]==="tasks")return!0;return!1}function RG($){let{target:J,agentName:Z,memoryRoot:Y,projectID:K,sessionID:Q}=$,V=x0.join(Y,"projects",K,"MEMORY.md"),X=x0.join(Y,"sessions",Q,"notes.md"),W=x0.join(Y,"sessions",Q,"checkpoint.md"),_=x0.join(Y,"sessions",Q,"tasks"),j=x0.resolve(Y),H=x0.resolve(J),q=x0.relative(j,H);if(!q||q===".."||q.startsWith(`..${x0.sep}`)||x0.isAbsolute(q))return;let U=q,z=U.split(x0.sep);if(z.length<2)throw Error(wG(V,X,J));let M=z[0];if(!dF.includes(M))throw Error(wG(V,X,J));if(Z==="checkpoint-writer"){if(!cF(z))throw Error(`Path '${U}' is not in the checkpoint-writer allowlist.
|
|
7290
7290
|
Writer may only write to:
|
|
7291
7291
|
${V} \u2014 project memory (or memory-<topic>.md spillover)
|
|
7292
7292
|
`+` ${W} \u2014 session checkpoint (or checkpoint-<topic>.md spillover)
|
|
7293
|
-
`+` ${
|
|
7294
|
-
`+`You attempted: ${J}.`);return}if(
|
|
7293
|
+
`+` ${_}/<task_id>/*.md \u2014 per-task narratives (any .md filename)
|
|
7294
|
+
`+`You attempted: ${J}.`);return}if(lF(z)){if($.taskId&&z[2]==="tasks"&&z[3]===$.taskId&&z.length>=5&&z[z.length-1].endsWith(".md"))return;throw Error(`Path '${U}' is reserved for the checkpoint-writer subagent.
|
|
7295
7295
|
Main agent writes to:
|
|
7296
7296
|
${V}
|
|
7297
7297
|
${X}
|
|
7298
7298
|
Subagent bound to task <TID> may write to tasks/<TID>/*.md (pass task_id when spawning).
|
|
7299
|
-
You attempted: ${J}.`)}}var _1=G.fn("Tool.assertExternalDirectory")(function*($,J,Z){if(!J)return;if(Z?.bypass)return;let Y=yield*i.context,K=process.platform==="win32"?$$.normalizePath(J):J;if(
|
|
7299
|
+
You attempted: ${J}.`)}}var _1=G.fn("Tool.assertExternalDirectory")(function*($,J,Z){if(!J)return;if(Z?.bypass)return;let Y=yield*i.context,K=process.platform==="win32"?$$.normalizePath(J):J;if(B$.containsPath(K,Y)){let j=$$.canonical(K);if(B$.containsPath(j,Y))return;throw Error("Access denied: path escapes project directory through a symlink")}let V=m2.join(f$.Path.data,"memory");if($$.contains(V,K)){let j=$$.canonical(K);if($$.contains(V,j))return;throw Error("Access denied: path escapes memory directory through a symlink")}let W=(Z?.kind??"file")==="directory"?K:m2.dirname(K),_=process.platform==="win32"?$$.normalizePathPattern(m2.join(W,"*")):m2.join(W,"*").replaceAll("\\","/");yield*$.ask({permission:"external_directory",patterns:[_],always:[_],metadata:{filepath:K,parentDir:W}})});var u2=G.fn("Tool.assertWriteAllowed")(function*($,J,Z){if(yield*_1($,J,Z),!J)return;let Y=(()=>{try{return B$.current?.project?.id??U2.global}catch{return U2.global}})();RG({target:$$.canonical(J),agentName:$.agent,memoryRoot:m2.join(f$.Path.data,"memory"),projectID:Y,sessionID:$.sessionID,taskId:$.taskId})}),LG=G.fn("Tool.askEditUnlessMemory")(function*($,J,Z){let Y=process.platform==="win32"?$$.normalizePath(J):J;if($$.contains(m2.join(f$.Path.data,"memory"),Y))return;yield*$.ask({permission:"edit",patterns:Z.patterns,always:["*"],metadata:{filepath:J,diff:Z.diff,...Z.files!==void 0?{files:Z.files}:{}}})});import*as NG from"path";var F8=G.fnUntraced(function*($){let J=d1(R1($.filePath,$.filePath,$.diffOld,$.diffNew));return yield*LG($.ctx,$.filePath,{patterns:[NG.relative(B$.worktree,$.filePath)],diff:J}),yield*$.write,yield*$.format.file($.filePath),yield*$.bus.publish(w2.Event.Edited,{file:$.filePath}),yield*$.bus.publish(k2.Event.Updated,{file:$.filePath,event:$.event}),J});function AJ($){return $.replaceAll(`\r
|
|
7300
7300
|
`,`
|
|
7301
|
-
`)}function
|
|
7301
|
+
`)}function oF($){return $.includes(`\r
|
|
7302
7302
|
`)?`\r
|
|
7303
7303
|
`:`
|
|
7304
|
-
`}function
|
|
7304
|
+
`}function yG($,J){if(J===`
|
|
7305
7305
|
`)return $;return $.replaceAll(`
|
|
7306
7306
|
`,`\r
|
|
7307
|
-
`)}var
|
|
7307
|
+
`)}var TG=new Map;function rF($){let J=$$.resolve($),Z=TG.get(J);if(Z)return Z;let Y=bG.makeUnsafe(1);return TG.set(J,Y),Y}var T7=H$("edit",G.gen(function*(){let $=(yield*e.toolDescriptionEffect("edit"))??"",J=yield*b0.Service,Z=yield*$$.Service,Y=yield*W1.Service,K=yield*P$.Service;return{description:$,parameters:ZG,execute:(Q,V)=>G.gen(function*(){if(!Q.filePath)throw Error("filePath is required");if(Q.oldString===Q.newString)throw Error("No changes to apply: oldString and newString are identical.");let X=SJ.isAbsolute(Q.filePath)?Q.filePath:SJ.join(t$.get(V.sessionID),Q.filePath);yield*u2(V,X);let W="",_="",j="";yield*rF(X).withPermits(1)(G.gen(function*(){if(Q.oldString===""){let L=yield*Z.existsSafe(X);j=Q.newString,W=yield*F8({ctx:V,filePath:X,diffOld:_,diffNew:j,write:Z.writeWithDirs(X,Q.newString),event:L?"change":"add",format:Y,bus:K});return}let I=yield*Z.stat(X).pipe(G.catch(()=>G.succeed(void 0)));if(!I)throw Error(`File ${X} not found`);if(I.type==="Directory")throw Error(`Path is a directory, not a file: ${X}`);_=yield*Z.readFileString(X);let C=oF(_),P=yG(AJ(Q.oldString),C),D=yG(AJ(Q.newString),C);j=Qz(_,P,D,Q.replaceAll),W=yield*F8({ctx:V,filePath:X,diffOld:AJ(_),diffNew:AJ(j),write:Z.writeWithDirs(X,j),event:"change",format:Y,bus:K}),j=yield*Z.readFileString(X),W=d1(R1(X,X,AJ(_),AJ(j)))}).pipe(G.orDie));let H={file:X,patch:W,additions:0,deletions:0};for(let I of z8(_,j)){if(I.added)H.additions+=I.count||0;if(I.removed)H.deletions+=I.count||0}yield*V.metadata({metadata:{diff:W,filediff:H,diagnostics:{}}});let q="Edit applied successfully.";yield*J.touchFile(X,!0);let U=yield*J.diagnostics(),z=$$.normalizePath(X),M=b0.Diagnostic.report(X,U[z]??[]);if(M)q+=`
|
|
7308
7308
|
|
|
7309
7309
|
LSP errors detected in this file, please fix:
|
|
7310
|
-
${M}`;return{metadata:{diagnostics:
|
|
7310
|
+
${M}`;return{metadata:{diagnostics:U,diff:W,filediff:H},title:`${SJ.relative(B$.worktree,X)}`,output:q}})}})),kG=0,iF=0.3;function sF($,J){if($===""||J==="")return Math.max($.length,J.length);if($.length<J.length)[$,J]=[J,$];let Z=Array(J.length+1),Y=Array(J.length+1);for(let K=0;K<=J.length;K++)Z[K]=K;for(let K=1;K<=$.length;K++){Y[0]=K;for(let Q=1;Q<=J.length;Q++){let V=$[K-1]===J[Q-1]?0:1;Y[Q]=Math.min(Z[Q]+1,Y[Q-1]+1,Z[Q-1]+V)}[Z,Y]=[Y,Z]}return Z[J.length]}var nF=function*($,J){yield J},aF=function*($,J){let Z=$.split(`
|
|
7311
7311
|
`),Y=J.split(`
|
|
7312
|
-
`);if(Y[Y.length-1]==="")Y.pop();for(let K=0;K<=Z.length-Y.length;K++){let Q=!0;for(let V=0;V<Y.length;V++){let X=Z[K+V].trim(),W=Y[V].trim();if(X!==W){Q=!1;break}}if(Q){let V=0;for(let W=0;W<K;W++)V+=Z[W].length+1;let X=V;for(let W=0;W<Y.length;W++)if(X+=Z[K+W].length,W<Y.length-1)X+=1;yield $.substring(V,X)}}};function
|
|
7312
|
+
`);if(Y[Y.length-1]==="")Y.pop();for(let K=0;K<=Z.length-Y.length;K++){let Q=!0;for(let V=0;V<Y.length;V++){let X=Z[K+V].trim(),W=Y[V].trim();if(X!==W){Q=!1;break}}if(Q){let V=0;for(let W=0;W<K;W++)V+=Z[W].length+1;let X=V;for(let W=0;W<Y.length;W++)if(X+=Z[K+W].length,W<Y.length-1)X+=1;yield $.substring(V,X)}}};function EG($,J,Z,Y,K){let Q=J.length,V=Y-Z+1,X=0,W=Math.min(Q-2,V-2);if(W>0){for(let _=1;_<Q-1&&_<V-1;_++){let j=$[Z+_].trim(),H=J[_].trim(),q=Math.max(j.length,H.length);if(q===0)continue;let U=sF(j,H);if(K!==void 0){if(X+=(1-U/q)/W,X>=K)break}else X+=1-U/q}if(K===void 0)X/=W}else X=1;return X}function xG($,J,Z,Y){let K=0;for(let V=0;V<Z;V++)K+=J[V].length+1;let Q=K;for(let V=Z;V<=Y;V++)if(Q+=J[V].length,V<Y)Q+=1;return $.substring(K,Q)}var tF=function*($,J){let Z=$.split(`
|
|
7313
7313
|
`),Y=J.split(`
|
|
7314
|
-
`);if(Y.length<3)return;if(Y[Y.length-1]==="")Y.pop();let K=Y[0].trim(),Q=Y[Y.length-1].trim(),V=Y.length,X=[];for(let j=0;j<Z.length;j++){if(Z[j].trim()!==K)continue;for(let
|
|
7315
|
-
`);for(let V=0;V<K.length;V++){let X=K[V];if(Z(X)===Y)yield X;else if(Z(X).includes(Y)){let
|
|
7314
|
+
`);if(Y.length<3)return;if(Y[Y.length-1]==="")Y.pop();let K=Y[0].trim(),Q=Y[Y.length-1].trim(),V=Y.length,X=[];for(let j=0;j<Z.length;j++){if(Z[j].trim()!==K)continue;for(let H=j+2;H<Z.length;H++)if(Z[H].trim()===Q){X.push({startLine:j,endLine:H});break}}if(X.length===0)return;if(X.length===1){let{startLine:j,endLine:H}=X[0];if(EG(Z,Y,j,H,kG)>=kG)yield xG($,Z,j,H);return}let W=null,_=-1;for(let j of X){let H=EG(Z,Y,j.startLine,j.endLine);if(H>_)_=H,W=j}if(_>=iF&&W)yield xG($,Z,W.startLine,W.endLine)},eF=function*($,J){let Z=(V)=>V.replace(/\s+/g," ").trim(),Y=Z(J),K=$.split(`
|
|
7315
|
+
`);for(let V=0;V<K.length;V++){let X=K[V];if(Z(X)===Y)yield X;else if(Z(X).includes(Y)){let _=J.trim().split(/\s+/);if(_.length>0){let j=_.map((H)=>H.replace(/[.*+?^${}()|[\]\\]/g,"\\$&")).join("\\s+");try{let H=new RegExp(j),q=X.match(H);if(q)yield q[0]}catch{}}}}let Q=J.split(`
|
|
7316
7316
|
`);if(Q.length>1)for(let V=0;V<=K.length-Q.length;V++){let X=K.slice(V,V+Q.length);if(Z(X.join(`
|
|
7317
7317
|
`))===Y)yield X.join(`
|
|
7318
|
-
`)}}
|
|
7319
|
-
`),W=X.filter((j)=>j.trim().length>0);if(W.length===0)return V;let
|
|
7318
|
+
`)}},$z=function*($,J){let Z=(V)=>{let X=V.split(`
|
|
7319
|
+
`),W=X.filter((j)=>j.trim().length>0);if(W.length===0)return V;let _=Math.min(...W.map((j)=>{let H=j.match(/^(\s*)/);return H?H[1].length:0}));return X.map((j)=>j.trim().length===0?j:j.slice(_)).join(`
|
|
7320
7320
|
`)},Y=Z(J),K=$.split(`
|
|
7321
7321
|
`),Q=J.split(`
|
|
7322
7322
|
`);for(let V=0;V<=K.length-Q.length;V++){let X=K.slice(V,V+Q.length).join(`
|
|
7323
|
-
`);if(Z(X)===Y)yield X}},
|
|
7323
|
+
`);if(Z(X)===Y)yield X}},Jz=function*($,J){let Z=(V)=>{return V.replace(/\\(n|t|r|'|"|`|\\|\n|\$)/g,(X,W)=>{switch(W){case"n":return`
|
|
7324
7324
|
`;case"t":return"\t";case"r":return"\r";case"'":return"'";case'"':return'"';case"`":return"`";case"\\":return"\\";case`
|
|
7325
7325
|
`:return`
|
|
7326
7326
|
`;case"$":return"$";default:return X}})},Y=Z(J);if($.includes(Y))yield Y;let K=$.split(`
|
|
7327
7327
|
`),Q=Y.split(`
|
|
7328
7328
|
`);for(let V=0;V<=K.length-Q.length;V++){let X=K.slice(V,V+Q.length).join(`
|
|
7329
|
-
`);if(Z(X)===Y)yield X}},
|
|
7329
|
+
`);if(Z(X)===Y)yield X}},Zz=function*($,J){let Z=0;while(!0){let Y=$.indexOf(J,Z);if(Y===-1)break;yield J,Z=Y+J.length}},Yz=function*($,J){let Z=J.trim();if(Z===J)return;if($.includes(Z))yield Z;let Y=$.split(`
|
|
7330
7330
|
`),K=J.split(`
|
|
7331
7331
|
`);for(let Q=0;Q<=Y.length-K.length;Q++){let V=Y.slice(Q,Q+K.length).join(`
|
|
7332
|
-
`);if(V.trim()===Z)yield V}},
|
|
7332
|
+
`);if(V.trim()===Z)yield V}},Kz=function*($,J){let Z=J.split(`
|
|
7333
7333
|
`);if(Z.length<3)return;if(Z[Z.length-1]==="")Z.pop();let Y=$.split(`
|
|
7334
|
-
`),K=Z[0].trim(),Q=Z[Z.length-1].trim();for(let V=0;V<Y.length;V++){if(Y[V].trim()!==K)continue;for(let X=V+2;X<Y.length;X++)if(Y[X].trim()===Q){let W=Y.slice(V,X+1),
|
|
7335
|
-
`);if(W.length===Z.length){let j=0,
|
|
7334
|
+
`),K=Z[0].trim(),Q=Z[Z.length-1].trim();for(let V=0;V<Y.length;V++){if(Y[V].trim()!==K)continue;for(let X=V+2;X<Y.length;X++)if(Y[X].trim()===Q){let W=Y.slice(V,X+1),_=W.join(`
|
|
7335
|
+
`);if(W.length===Z.length){let j=0,H=0;for(let q=1;q<W.length-1;q++){let U=W[q].trim(),z=Z[q].trim();if(U.length>0||z.length>0){if(H++,U===z)j++}}if(H===0||j/H>=0.5){yield _;break}}break}}};function d1($){let J=$.split(`
|
|
7336
7336
|
`),Z=J.filter((Q)=>(Q.startsWith("+")||Q.startsWith("-")||Q.startsWith(" "))&&!Q.startsWith("---")&&!Q.startsWith("+++"));if(Z.length===0)return $;let Y=1/0;for(let Q of Z){let V=Q.slice(1);if(V.trim().length>0){let X=V.match(/^(\s*)/);if(X)Y=Math.min(Y,X[1].length)}}if(Y===1/0||Y===0)return $;return J.map((Q)=>{if((Q.startsWith("+")||Q.startsWith("-")||Q.startsWith(" "))&&!Q.startsWith("---")&&!Q.startsWith("+++")){let V=Q[0],X=Q.slice(1);return V+X.slice(Y)}return Q}).join(`
|
|
7337
|
-
`)}function
|
|
7338
|
-
`)}}).pipe(G.orDie)}}));import wJ from"path";var
|
|
7339
|
-
`)}}).pipe(G.orDie)}}));var
|
|
7340
|
-
`),metadata:{count:0,incomplete:q}};let
|
|
7341
|
-
`),metadata:{count:
|
|
7337
|
+
`)}function Qz($,J,Z,Y=!1){if(J===Z)throw Error("No changes to apply: oldString and newString are identical.");let K=!0;for(let Q of[nF,aF,tF,eF,$z,Jz,Yz,Kz,Zz])for(let V of Q($,J)){let X=$.indexOf(V);if(X===-1)continue;if(K=!1,Y)return $.replaceAll(V,Z);let W=$.lastIndexOf(V);if(X!==W)continue;return $.substring(0,X)+Z+$.substring(X+V.length)}if(K)throw Error("Could not find oldString in the file. It must match exactly, including whitespace, indentation, and line endings.");throw Error("Found multiple matches for oldString. Provide more surrounding context to make the match unique.")}import OZ from"path";var hG=H$("glob",G.gen(function*(){let $=(yield*e.toolDescriptionEffect("glob"))??"",J=yield*h0.Service,Z=yield*$$.Service;return{description:$,parameters:$G,execute:(Y,K)=>G.gen(function*(){let Q=yield*i.context;yield*K.ask({permission:"glob",patterns:[Y.pattern],always:["*"],metadata:{pattern:Y.pattern,path:Y.path}});let V=Y.path??t$.get(K.sessionID);if(V=OZ.isAbsolute(V)?V:OZ.resolve(t$.get(K.sessionID),V),(yield*Z.stat(V).pipe(G.catch(()=>G.succeed(void 0))))?.type==="File")throw Error(`glob path must be a directory: ${V}`);yield*_1(K,V,{kind:"directory"});let W=100,_=!1,j=yield*J.files({cwd:V,glob:[Y.pattern],signal:K.abort}).pipe(vG((q)=>G.gen(function*(){let U=OZ.resolve(V,q),M=(yield*Z.stat(U).pipe(G.catch(()=>G.succeed(void 0))))?.mtime.pipe(p1.map((I)=>I.getTime()),p1.getOrElse(()=>0))??0;return{path:U,mtime:M}})),qZ(W+1),BJ,G.map((q)=>[...q]));if(j.length>W)_=!0,j.length=W;j.sort((q,U)=>U.mtime-q.mtime);let H=[];if(j.length===0)H.push("No files found");if(j.length>0){if(H.push(...j.map((q)=>q.path)),_)H.push(""),H.push(`(Results are truncated: showing first ${W} results. Consider using a more specific path or pattern.)`)}return{title:OZ.relative(Q.worktree,V),metadata:{count:j.length,truncated:_},output:H.join(`
|
|
7338
|
+
`)}}).pipe(G.orDie)}}));import wJ from"path";var gG=2000,fG=H$("grep",G.gen(function*(){let $=(yield*e.toolDescriptionEffect("grep"))??"",J=yield*$$.Service,Z=yield*h0.Service;return{description:$,parameters:JG,execute:(Y,K)=>G.gen(function*(){let Q={title:Y.pattern,metadata:{matches:0,truncated:!1},output:"No files found"};if(!Y.pattern)throw Error("pattern is required");yield*K.ask({permission:"grep",patterns:[Y.pattern],always:["*"],metadata:{pattern:Y.pattern,path:Y.path,include:Y.include}});let V=t$.get(K.sessionID),X=wJ.isAbsolute(Y.path??V)?Y.path??V:wJ.join(V,Y.path??"."),W=$$.resolve(X),_=yield*J.stat(W).pipe(G.catch(()=>G.succeed(void 0))),j=_?.type==="Directory"?W:wJ.dirname(W),H=_?.type==="Directory"?void 0:[wJ.relative(j,W)];yield*_1(K,X,{kind:_?.type==="Directory"?"directory":"file"});let q=yield*Z.search({cwd:j,pattern:Y.pattern,glob:Y.include?[Y.include]:void 0,file:H,signal:K.abort});if(q.items.length===0)return Q;let U=q.items.map((N)=>({path:$$.resolve(wJ.isAbsolute(N.path.text)?N.path.text:wJ.join(j,N.path.text)),line:N.line_number,text:N.lines.text})),z=new Map((yield*G.forEach([...new Set(U.map((N)=>N.path))],G.fnUntraced(function*(N){let x=yield*J.stat(N).pipe(G.catch(()=>G.succeed(void 0)));if(!x||x.type==="Directory")return;return[N,x.mtime.pipe(p1.map((b)=>b.getTime()),p1.getOrElse(()=>0))??0]}),{concurrency:16})).filter((N)=>Boolean(N))),M=U.flatMap((N)=>{let x=z.get(N.path);if(x===void 0)return[];return[{...N,mtime:x}]});M.sort((N,x)=>x.mtime-N.mtime);let I=100,C=M.length>I,P=C?M.slice(0,I):M;if(P.length===0)return Q;let D=M.length,L=[`Found ${D} matches${C?` (showing first ${I})`:""}`],R="";for(let N of P){if(R!==N.path){if(R!=="")L.push("");R=N.path,L.push(`${N.path}:`)}let x=N.text.length>gG?N.text.substring(0,gG)+"...":N.text;L.push(` Line ${N.line}: ${x}`)}if(C)L.push(""),L.push(`(Results truncated: showing ${I} of ${D} matches (${D-I} hidden). Consider using a more specific path or pattern.)`);if(q.partial)L.push(""),L.push("(Some paths were inaccessible and skipped)");return{title:Y.pattern,metadata:{matches:D,truncated:C},output:L.join(`
|
|
7339
|
+
`)}}).pipe(G.orDie)}}));var Vz=20480,mG=H$("history",G.gen(function*(){let $=(yield*e.toolDescriptionEffect("history"))??"",J=yield*MJ.Service,Z=yield*Z1,Y=yield*p0.Service;return{description:$,parameters:OG,execute:(K,Q)=>G.gen(function*(){if(K.operation==="search"){if(!K.query)return{title:"History search: missing query",output:"operation=search requires a `query` argument.",metadata:{count:0,incomplete:!1}};let{hits:H,incomplete:q}=yield*J.search({query:K.query,scope:K.scope,session_id:K.session_id,kind:K.kind,tool_name:K.tool_name,time_after:K.time_after,time_before:K.time_before,limit:K.limit}),U=q?"NOTE: Results may be incomplete \u2014 the filters were too selective for the search's safety cap, so real matches may have been missed. Narrow the query (add rarer/more distinctive terms) or loosen the filters and retry.":"";if(H.length===0)return{title:"History search: 0 matches",output:[`0 matches for "${K.query}". Try memory search if you haven't, or broaden the query.`,...U?["",U]:[]].join(`
|
|
7340
|
+
`),metadata:{count:0,incomplete:q}};let z=[`Found ${H.length} match${H.length===1?"":"es"}:`,""];if(U)z.splice(1,0,U);for(let M of H){let I=M.tool_name?`${M.kind} \xB7 ${M.tool_name}`:M.kind;z.push(`### ${M.session_id} ${M.message_id} (${I})`),z.push(`Time: ${new Date(M.time_created).toISOString()}, Score: ${M.score.toFixed(3)}`),z.push(M.snippet),z.push("")}return{title:`History search: ${H.length} match${H.length===1?"":"es"}${q?" (may be incomplete)":""}`,output:z.join(`
|
|
7341
|
+
`),metadata:{count:H.length,incomplete:q}}}if(!K.message_id)return{title:"History around: missing message_id",output:"operation=around requires a `message_id` argument.",metadata:{count:0,incomplete:!1}};let V=yield*J.around({message_id:K.message_id,before:K.before,after:K.after});if(V.messages.length===0)return{title:"History around: anchor not found",output:`No message with id ${K.message_id}.`,metadata:{count:0,incomplete:!1}};let X=[`Session ${V.session_id}, ${V.messages.length} messages (anchor ${K.message_id}):`,""];for(let H of V.messages){let q=H.matched?">>>":"---";X.push(`${q} ${H.message_id} (${new Date(H.time_created).toISOString()})`);for(let U of H.parts){let z=U.tool_name?`${U.type} (${U.tool_name})`:U.type;X.push(` ${U.role} \xB7 ${z}:`),X.push(U.text.split(`
|
|
7342
7342
|
`).map((M)=>` ${M}`).join(`
|
|
7343
7343
|
`))}X.push("")}let W=X.join(`
|
|
7344
|
-
`),
|
|
7344
|
+
`),_=yield*Y.get(Q.agent),j=yield*Z.output(W,{maxBytes:Vz},_);return{title:`History around ${K.message_id}`,output:j.content,metadata:{count:V.messages.length,incomplete:!1,truncated:j.truncated,...j.truncated&&{outputPath:j.outputPath}}}})}}));var uG=H$("memory",G.gen(function*(){let $=(yield*e.toolDescriptionEffect("memory"))??"",J=yield*g1.Service;return{description:$,parameters:_G,execute:(Z)=>G.gen(function*(){let{results:Y,incomplete:K}=yield*J.search({query:Z.query,scope:Z.scope,scope_id:Z.scope_id,type:Z.type,limit:Z.limit}),Q=K?"NOTE: Results may be incomplete \u2014 the scope/type filters were too selective for the search's safety cap, so real matches may have been missed. Use rarer/more distinctive terms or loosen the filters and retry.":"";if(Y.length===0)return{title:"Memory search: 0 results",output:[`No matches for "${Z.query}".`,...Q?["",Q]:[],"","0 results does NOT mean it was never recorded. Escalate before giving up:","1. Retry with FEWER / more distinctive terms \u2014 queries are OR-joined and"," ranked, so 1-2 rare words (an exact ID, function name, flag) beat a long",' descriptive phrase. Drop generic words ("config", "params", "database").',"2. For a LITERAL string the tokenizer splits (URLs like postgres://\u2026, ports"," like 5433, paths) \u2014 Grep the memory dir directly; FTS can't see it.","3. For VERBATIM recall of something a summary may have glossed over (exact"," command, the user's precise wording) \u2014 use the history tool (raw"," conversation), which keeps original messages.","Widen scope progressively: session \u2192 project \u2192 global \u2192 history."].join(`
|
|
7345
7345
|
`),metadata:{count:0,incomplete:K}};let V=[`Found ${Y.length} match${Y.length===1?"":"es"} (BM25-ranked, best first).`,...Q?[Q]:[],"A hit here is authoritative \u2014 use it even if a parallel/sibling query returned nothing.","If you need the FULL body (snippets are truncated), Read the path.","If you need an EXACT literal (a connection string, port, token, full command line, path) and the snippet/body only paraphrases or partially shows it, the curated memory may have dropped the precise form \u2014 query the history tool for the original message, which holds it verbatim.",""];for(let X of Y)V.push(`### ${X.path}`),V.push(`Scope: ${X.scope}${X.scope_id?`/${X.scope_id}`:""}, Type: ${X.type}, Score: ${X.score.toFixed(3)}`),V.push(X.snippet),V.push("");return{title:`Memory search: ${Y.length} result${Y.length===1?"":"s"}${K?" (may be incomplete)":""}`,output:V.join(`
|
|
7346
|
-
`),metadata:{count:Y.length,incomplete:K}}})}}));import{createReadStream as
|
|
7347
|
-
${M[P]}`]:[]),...
|
|
7348
|
-
${I[P]}`]:[])]}}),j=G.fn("Instruction.find")(function*(q){for(let
|
|
7349
|
-
${v}`});R=p$.dirname(R)}return
|
|
7346
|
+
`),metadata:{count:Y.length,incomplete:K}}})}}));import{createReadStream as rG}from"fs";import*as v0 from"path";var d2={};o$(d2,{loaded:()=>Uz,layer:()=>cG,display:()=>Bz,defaultLayer:()=>jz,Service:()=>FZ,Instruction:()=>d2});import k7 from"os";import p$ from"path";var Gz=O$.create({service:"instruction"}),dG=["AGENTS.md",...k$.QITQODE_DISABLE_CLAUDE_CODE_PROMPT?[]:["CLAUDE.md"],"CONTEXT.md"],Xz=500;function Wz(){let $=[];if(k$.QITQODE_CONFIG_DIR)$.push(p$.join(k$.QITQODE_CONFIG_DIR,"AGENTS.md"));if($.push(p$.join(f$.Path.config,"AGENTS.md")),!k$.QITQODE_DISABLE_CLAUDE_CODE_PROMPT)$.push(p$.join(k7.homedir(),".claude","CLAUDE.md"));return $}function pG($){let J=new Set;for(let Z of $)for(let Y of Z.parts)if(Y.type==="tool"&&Y.tool==="read"&&Y.state.status==="completed"){if(Y.state.time.compacted)continue;let K=Y.state.metadata?.loaded;if(!K||!Array.isArray(K))continue;for(let Q of K)if(typeof Q==="string")J.add(Q)}return J}class FZ extends D$.Service()("@qitqode/Instruction"){}var cG=f.effect(FZ,G.gen(function*(){let $=yield*R$.Service,J=yield*$$.Service,Z=v1.filterStatusOk(f9(yield*v1.HttpClient)),Y=yield*i.make(G.fn("Instruction.state")(()=>G.succeed({claims:new Map}))),K=G.fnUntraced(function*(q){let U=yield*i.context;if(!k$.QITQODE_DISABLE_PROJECT_CONFIG)return yield*J.globUp(q,U.directory,U.worktree).pipe(G.catch(()=>G.succeed([])));if(!k$.QITQODE_CONFIG_DIR)return Gz.warn(`Skipping relative instruction "${q}" - no QITQODE_CONFIG_DIR set while project config is disabled`),[];return yield*J.globUp(q,k$.QITQODE_CONFIG_DIR,k$.QITQODE_CONFIG_DIR).pipe(G.catch(()=>G.succeed([])))}),Q=G.fnUntraced(function*(q){return yield*J.readFileString(q).pipe(G.catch(()=>G.succeed("")))}),V=G.fnUntraced(function*(q){let U=yield*Z.execute(G2.get(q)).pipe(G.timeout(5000),G.catch(()=>G.succeed(null)));if(!U)return"";let z=yield*U.arrayBuffer.pipe(G.catch(()=>G.succeed(new ArrayBuffer(0))));return new TextDecoder().decode(z)}),X=G.fn("Instruction.clear")(function*(q){(yield*i.get(Y)).claims.delete(q)}),W=G.fn("Instruction.systemPaths")(function*(){let q=yield*$.get(),U=yield*i.context,z=new Set;if(!k$.QITQODE_DISABLE_PROJECT_CONFIG){let M=yield*J.findUp("AGENTS.md",U.directory,U.worktree);if(M.length>0){if(M.forEach((I)=>z.add(p$.resolve(I))),!k$.QITQODE_DISABLE_CLAUDE_CODE_PROMPT){if((yield*G.forEach(M,Q,{concurrency:8})).join("").trim().length<Xz)(yield*J.findUp("CLAUDE.md",U.directory,U.worktree)).forEach((P)=>z.add(p$.resolve(P)))}}else for(let I of dG){if(I==="AGENTS.md")continue;let C=yield*J.findUp(I,U.directory,U.worktree);if(C.length>0){C.forEach((P)=>z.add(p$.resolve(P)));break}}}for(let M of Wz())if(yield*J.existsSafe(M)){z.add(p$.resolve(M));break}if(q.instructions)for(let M of q.instructions){if(M.startsWith("https://")||M.startsWith("http://"))continue;let I=M.startsWith("~/")?p$.join(k7.homedir(),M.slice(2)):M;(yield*(p$.isAbsolute(I)?J.glob(p$.basename(I),{cwd:p$.dirname(I),absolute:!0,include:"file"}):K(I)).pipe(G.catch(()=>G.succeed([])))).forEach((P)=>z.add(p$.resolve(P)))}return z}),_=G.fn("Instruction.system")(function*(){let q=yield*$.get(),U=yield*W(),z=(q.instructions??[]).filter((C)=>C.startsWith("https://")||C.startsWith("http://")),M=yield*G.forEach(Array.from(U),Q,{concurrency:8}),I=yield*G.forEach(z,V,{concurrency:4});return{paths:U,content:[...Array.from(U).flatMap((C,P)=>M[P]?[`Instructions from: ${C}
|
|
7347
|
+
${M[P]}`]:[]),...z.flatMap((C,P)=>I[P]?[`Instructions from: ${C}
|
|
7348
|
+
${I[P]}`]:[])]}}),j=G.fn("Instruction.find")(function*(q){for(let U of dG){let z=p$.resolve(p$.join(q,U));if(yield*J.existsSafe(z))return z}}),H=G.fn("Instruction.resolve")(function*(q,U,z){let M=yield*W(),I=pG(q),C=[],P=yield*i.get(Y),D=p$.resolve(yield*i.directory),L=p$.resolve(U),R=p$.dirname(L);while(R!==D){let N=p$.relative(D,R);if(N===".."||N.startsWith(`..${p$.sep}`)||p$.isAbsolute(N))break;let x=yield*j(R);if(!x||x===L||M.has(x)||I.has(x)){R=p$.dirname(R);continue}let b=P.claims.get(z);if(!b)b=new Set,P.claims.set(z,b);if(b.has(x)){R=p$.dirname(R);continue}b.add(x);let v=yield*Q(x);if(v)C.push({filepath:x,content:`Instructions from: ${x}
|
|
7349
|
+
${v}`});R=p$.dirname(R)}return C});return FZ.of({clear:X,systemPaths:W,system:_,find:j,resolve:H})})),jz=cG.pipe(f.provide(R$.defaultLayer),f.provide($$.defaultLayer),f.provide(X2.layer));function Uz($){return pG($)}function Bz($,J){let Z=p$.relative(J,$);if(Z&&Z!==".."&&!Z.startsWith(`..${p$.sep}`)&&!p$.isAbsolute(Z))return Z;let Y=k7.homedir();if($===Y||$.startsWith(Y+p$.sep))return p$.join("~",p$.relative(Y,$));return $}var lG=2000,E7=2000,Hz=`... (line truncated to ${E7} chars)`,_z=`${u1/1024} KB`,Oz=4096,qz=393216,iG=H$("read",G.gen(function*(){let $=(yield*e.toolDescriptionEffect("read"))??"",J=yield*$$.Service,Z=yield*d2.Service,Y=yield*b0.Service,K=yield*UJ.Scope,Q=G.fn("ReadTool.miss")(function*(H){let q=v0.dirname(H),U=v0.basename(H),z=yield*J.readDirectory(q).pipe(G.map((M)=>M.filter((I)=>I.toLowerCase().includes(U.toLowerCase())||U.toLowerCase().includes(I.toLowerCase())).map((I)=>v0.join(q,I)).slice(0,3)),G.catch(()=>G.succeed([])));if(z.length>0)return yield*G.fail(Error(`File not found: ${H}
|
|
7350
7350
|
|
|
7351
7351
|
Did you mean one of these?
|
|
7352
|
-
${
|
|
7353
|
-
`)}`));return yield*G.fail(Error(`File not found: ${
|
|
7352
|
+
${z.join(`
|
|
7353
|
+
`)}`));return yield*G.fail(Error(`File not found: ${H}`))}),V=G.fn("ReadTool.list")(function*(H){let q=yield*J.readDirectoryEntries(H);return yield*G.forEach(q,G.fnUntraced(function*(U){if(U.type==="directory")return U.name+"/";if(U.type!=="symlink")return U.name;if((yield*J.stat(v0.join(H,U.name)).pipe(G.catch(()=>G.void)))?.type==="Directory")return U.name+"/";return U.name}),{concurrency:32}).pipe(G.map((U)=>U.sort((z,M)=>z.localeCompare(M))))}),X=G.fn("ReadTool.warm")(function*(H){yield*Y.touchFile(H,!1).pipe(G.ignore,G.forkIn(K))}),W=G.fn("ReadTool.readSample")(function*(H,q,U){if(q===0)return new Uint8Array;return yield*G.scoped(G.gen(function*(){let M=yield*(yield*J.open(H,{flag:"r"})).readAlloc(Math.min(U,q));if(M._tag==="None")return new Uint8Array;return M.value}))}),_=(H,q)=>{switch(v0.extname(H).toLowerCase()){case".zip":case".tar":case".gz":case".exe":case".dll":case".so":case".class":case".jar":case".war":case".7z":case".doc":case".docx":case".xls":case".xlsx":case".ppt":case".pptx":case".odt":case".ods":case".odp":case".bin":case".dat":case".obj":case".o":case".a":case".lib":case".wasm":case".pyc":case".pyo":return!0}if(q.length===0)return!1;let z=0;for(let M=0;M<q.length;M++){if(q[M]===0)return!0;if(q[M]<9||q[M]>13&&q[M]<32)z++}return z/q.length>0.3},j=G.fn("ReadTool.execute")(function*(H,q){if(H.offset!==void 0&&H.offset<1)return yield*G.fail(Error("offset must be greater than or equal to 1"));let U=H.filePath;if(!v0.isAbsolute(U))U=v0.resolve(t$.get(q.sessionID),U);if(process.platform==="win32")U=$$.normalizePath(U);let z=v0.relative(B$.worktree,U),M=yield*J.stat(U).pipe(G.catchIf((b)=>("reason"in b)&&b.reason._tag==="NotFound",()=>G.succeed(void 0)));if(yield*_1(q,U,{bypass:Boolean(q.extra?.bypassCwdCheck),kind:M?.type==="Directory"?"directory":"file"}),yield*q.ask({permission:"read",patterns:[U],always:["*"],metadata:{}}),!M)return yield*Q(U);if(M.type==="Directory"){let b=yield*V(U),v=H.limit??lG,m=H.offset??1,A=m-1,u=b.slice(A,A+v),r=A+u.length<b.length;return{title:z,output:[`<path>${U}</path>`,"<type>directory</type>","<entries>",u.join(`
|
|
7354
7354
|
`),r?`
|
|
7355
7355
|
(Showing ${u.length} of ${b.length} entries. Use 'offset' parameter to read beyond entry ${m+u.length})`:`
|
|
7356
7356
|
(${b.length} entries)`,"</entries>"].join(`
|
|
7357
7357
|
`),metadata:{preview:u.slice(0,20).join(`
|
|
7358
|
-
`),truncated:r,loaded:[]}}}let I=yield*Z.resolve(q.messages,
|
|
7359
|
-
Resize or compress the ${
|
|
7358
|
+
`),truncated:r,loaded:[]}}}let I=yield*Z.resolve(q.messages,U,q.messageID),C=yield*W(U,Number(M.size),Oz),P=oG(C,$$.mimeType(U));if(CZ(P)||zZ(P)){if(Number(M.size)>qz)return yield*G.fail(Error(`Attachment is too large to send (${Math.ceil(Number(M.size)/1024)} KB; limit is 384 KB): ${U}
|
|
7359
|
+
Resize or compress the ${zZ(P)?"PDF":"image"} to under 384 KB and try again.`));let b=yield*J.readFile(U),v=zZ(P)?"PDF read successfully":"Image read successfully";return{title:z,output:v,metadata:{preview:v,truncated:!1,loaded:I.map((m)=>m.filepath)},attachments:[{type:"file",mime:P,url:`data:${P};base64,${Buffer.from(b).toString("base64")}`}]}}if(_(U,C))return yield*G.fail(Error(`Cannot read binary file: ${U}`));let D=yield*G.promise(()=>Fz(U,{limit:H.limit??lG,offset:H.offset??1}));if(D.count<D.offset&&!(D.count===0&&D.offset===1))return yield*G.fail(Error(`Offset ${D.offset} is out of range for this file (${D.count} lines)`));let L=[`<path>${U}</path>`,"<type>file</type>",`<content>
|
|
7360
7360
|
`].join(`
|
|
7361
7361
|
`);L+=D.raw.map((b,v)=>`${v+D.offset}: ${b}`).join(`
|
|
7362
7362
|
`);let R=D.offset+D.raw.length-1,N=R+1,x=D.more||D.cut;if(D.cut)L+=`
|
|
7363
7363
|
|
|
7364
|
-
(Output capped at ${
|
|
7364
|
+
(Output capped at ${_z}. Showing lines ${D.offset}-${R}. Use offset=${N} to continue.)`;else if(D.more)L+=`
|
|
7365
7365
|
|
|
7366
7366
|
(Showing lines ${D.offset}-${R} of ${D.count}. Use offset=${N} to continue.)`;else L+=`
|
|
7367
7367
|
|
|
7368
7368
|
(End of file - total ${D.count} lines)`;if(L+=`
|
|
7369
|
-
</content>`,yield*X(
|
|
7369
|
+
</content>`,yield*X(U),I.length>0)L+=`
|
|
7370
7370
|
|
|
7371
7371
|
<system-reminder>
|
|
7372
7372
|
${I.map((b)=>b.content).join(`
|
|
7373
7373
|
|
|
7374
7374
|
`)}
|
|
7375
|
-
</system-reminder>`;return{title:
|
|
7376
|
-
`),truncated:x,loaded:I.map((b)=>b.filepath)}}});return{description:$,parameters:
|
|
7375
|
+
</system-reminder>`;return{title:z,output:L,metadata:{preview:D.raw.slice(0,20).join(`
|
|
7376
|
+
`),truncated:x,loaded:I.map((b)=>b.filepath)}}});return{description:$,parameters:eV,execute:(H,q)=>j(H,q).pipe(G.orDie)}}));async function Fz($,J){let Z=rG($,{highWaterMark:65536}),Y=10,K=13,Q=J.offset-1,V=[],X=0,W=0,_=!1,j=!1,H=0,q=(I)=>{if(W+=1,W<=Q)return!0;if(V.length>=J.limit)return j=!0,!1;let C=I.length>E7?I.substring(0,E7)+Hz:I,P=Buffer.byteLength(C,"utf-8")+(V.length>0?1:0);if(X+P>u1)return _=!0,j=!0,!1;return V.push(C),X+=P,!0},U=Buffer.alloc(0),z=0,M=!1;try{for await(let I of Z){if(I.length===0)continue;let C=U.length>0?Buffer.concat([U,I]):I,P=0;while(!0){let D=C.indexOf(10,P),L=C.indexOf(13,P);if(D===-1&&L===-1)break;let R,N;if(L!==-1&&(D===-1||L<D)){if(L===C.length-1)break;R=L,N=C[L+1]===10?2:1}else R=D,N=1;let x=q(C.subarray(P,R).toString("utf8"));if(H=z+R+N,P=R+N,!x){M=!0;break}}if(M)break;U=C.subarray(P),z+=P}}finally{Z.destroy()}if(!M&&U.length>0){let I=U[U.length-1]===13?U.length-1:U.length;q(U.subarray(0,I).toString("utf8")),H=z+U.length}if(j)W=await zz($,{start:H,lines:W});return{raw:V,count:W,cut:_,more:j,offset:J.offset}}async function zz($,J){let Z=rG($,{highWaterMark:65536,...J&&J.start>0?{start:J.start}:{}}),Y=J?.lines??0,K=10,Q=13,V=0,X=-1,W=!0;try{for await(let _ of Z){if(_.length===0)continue;W=!1;let j=-1;while((j=_.indexOf(10,j+1))!==-1)V+=1;j=-1;while((j=_.indexOf(13,j+1))!==-1)if((j+1<_.length?_[j+1]:-1)!==10)V+=1;if(X===13&&_[0]===10)V-=1;X=_[_.length-1]}}finally{Z.destroy()}if(W)return Y;return Y+(X===10||X===13?V:V+1)}var VX=S9(QX(),1);function kz($){return`\x00HD${$}\x00`}function Ez($){let J=[],Z="",Y=null,K=0,Q=1;while(K<$.length){let V=$[K];if(Y){if(V==="\\"&&Y==='"'&&K+1<$.length){if(Z+=V+$[K+1],$[K+1]===`
|
|
7377
7377
|
`)Q++;K+=2;continue}if(V===Y){Y=null,Z+=V,K++;continue}if(V===`
|
|
7378
7378
|
`)Q++;Z+=V,K++;continue}if(V==='"'||V==="'"){Y=V,Z+=V,K++;continue}if(V==="<"&&$[K+1]==="<"){if($[K+2]==="<"){Z+="<<< ",K+=3;while(K<$.length&&$[K]!==`
|
|
7379
|
-
`)K++;continue}let X=K+2,W=X;if(X<$.length&&/[A-Za-z_]/.test($[X])){while(X<$.length&&/[A-Za-z0-9_]/.test($[X]))X++;let
|
|
7380
|
-
`)return{ok:!1,error:{kind:"unsupported-operator",line:Q,detail:"tokens after <<MARKER on the same line are not supported"}};let
|
|
7381
|
-
`,K=j+1,Q++;let
|
|
7379
|
+
`)K++;continue}let X=K+2,W=X;if(X<$.length&&/[A-Za-z_]/.test($[X])){while(X<$.length&&/[A-Za-z0-9_]/.test($[X]))X++;let _=$.slice(W,X),j=X;while(j<$.length&&($[j]===" "||$[j]==="\t"))j++;if(j<$.length&&$[j]!==`
|
|
7380
|
+
`)return{ok:!1,error:{kind:"unsupported-operator",line:Q,detail:"tokens after <<MARKER on the same line are not supported"}};let H=J.length,q=Q;Z+=kz(H)+`
|
|
7381
|
+
`,K=j+1,Q++;let U=[],z=!1;while(K<$.length){let M=K;while(M<$.length&&$[M]!==`
|
|
7382
7382
|
`)M++;let I=$.slice(K,M);if(Z+=`
|
|
7383
|
-
`,I.trim()===
|
|
7383
|
+
`,I.trim()===_){K=M+(M<$.length?1:0),Q++,z=!0;break}U.push(I),K=M+(M<$.length?1:0),Q++}if(!z)return{ok:!1,error:{kind:"unclosed-heredoc",line:q,detail:`unclosed heredoc <<${_}`}};J.push(U.join(`
|
|
7384
7384
|
`));continue}Z+=V,K++;continue}if(Z+=V,V===`
|
|
7385
|
-
`)Q++;K++}return{ok:!0,stripped:Z,bodies:J}}var
|
|
7385
|
+
`)Q++;K++}return{ok:!0,stripped:Z,bodies:J}}var xz=/^\x00HD(\d+)\x00$/;function bz($){let J="",Z=0,Y=null,K=!0;while(Z<$.length){let Q=$[Z];if(Y){if(J+=Q,Q==="\\"&&Y==='"'&&Z+1<$.length){J+=$[Z+1],Z+=2;continue}if(Q===Y)Y=null;Z++,K=!1;continue}if(Q==='"'||Q==="'"){Y=Q,J+=Q,Z++,K=!1;continue}if(Q==="\\"){if(Z+1<$.length&&$[Z+1]==="#"){J+="\\#",Z+=2,K=!1;continue}J+=Q,Z++,K=!1;continue}if(Q==="#"){if(K){while(Z<$.length&&$[Z]!==`
|
|
7386
7386
|
`)Z++;continue}J+="\\#",Z++,K=!1;continue}J+=Q,K=Q===`
|
|
7387
|
-
`||/\s/.test(Q),Z++}return J}function
|
|
7387
|
+
`||/\s/.test(Q),Z++}return J}function DZ($){return G.suspend(()=>{if($.trim()==="")return G.succeed([]);let J=Ez($);if(!J.ok)return G.fail(J.error);let{stripped:Z,bodies:Y}=J,K=hz(bz(Z)).filter((V)=>V.text.trim()!==""),Q=[];for(let V of K){let X=vz(V.text);if(X)return G.fail({kind:"unclosed-quote",line:V.line,detail:`unclosed ${X}-quoted string`});let W=VX.parse(V.text,(j)=>"$"+j,{escape:"\\"}),_=[];for(let j of W){if(typeof j==="string"){let H=xz.exec(j);if(H){_.push(Y[parseInt(H[1],10)]);continue}_.push(j);continue}if(typeof j==="object"&&j!==null&&"op"in j){let H=j,q=H.op==="glob"&&H.pattern!=null?`unsupported glob pattern: ${H.pattern}`:`unsupported shell operator: ${H.op}`;return G.fail({kind:"unsupported-operator",line:V.line,detail:q})}}if(_.length>0)Q.push({line:V.line,tokens:_})}return G.succeed(Q)})}function vz($){let J=null;for(let Z=0;Z<$.length;Z++){let Y=$[Z];if(J){if(Y==="\\"&&J==='"'&&Z+1<$.length){Z++;continue}if(Y===J)J=null;continue}if(Y==='"'||Y==="'")J=Y}return J}function hz($){let J=[],Z="",Y=1,K=1,Q=null,V=0;while(V<$.length){let X=$[V];if(Q){if(X==="\\"&&Q==='"'&&V+1<$.length){if(Z+=X+$[V+1],$[V+1]===`
|
|
7388
7388
|
`)K++;V+=2;continue}if(X===Q){Q=null,Z+=X,V++;continue}if(X===`
|
|
7389
7389
|
`)K++;Z+=X,V++;continue}if(X==='"'||X==="'"){Q=X,Z+=X,V++;continue}if(X==="\\"&&V+1<$.length&&$[V+1]===`
|
|
7390
7390
|
`){K++,V+=2;continue}if(X===`
|
|
7391
|
-
`){J.push({line:Y,text:Z}),Z="",K++,Y=K,V++;continue}Z+=X,V++}if(Z.length>0)J.push({line:Y,text:Z});return J}function KX($,J,Z){let Y=$.length,K=J.length;if(Math.abs(Y-K)>Z)return Z+1;if(Y===0)return K;if(K===0)return Y;if(Y<K)return KX(J,$,Z);let Q=Array(K+1),V=Array(K+1);for(let X=0;X<=K;X++)Q[X]=X;for(let X=1;X<=Y;X++){V.fill(Z+1),V[0]=X;let W=Math.max(1,X-Z),B=Math.min(K,X+Z),j=Number.POSITIVE_INFINITY;for(let _=W;_<=B;_++){let q=$[X-1]===J[_-1]?0:1;V[_]=Math.min(Q[_]+1,V[_-1]+1,Q[_-1]+q),j=Math.min(j,V[_])}if(j>Z)return Z+1;[Q,V]=[V,Q]}return Q[K]}function MZ($,J){let Z;for(let Y of J){if(KX($,Y,2)>2)continue;if(Z!==void 0)return;Z=Y}return Z}function DZ($){if($==null||typeof $!=="object")return;let J=$;if(typeof J.operation==="string")try{let Z=JSON.parse(J.operation);if(Z&&typeof Z==="object"&&!Array.isArray(Z))J={operation:Z}}catch{}if(J.operation&&typeof J.operation==="object"&&!Array.isArray(J.operation))return{kind:"operation",operation:J.operation};return{kind:"bare",obj:J}}var c2={};o$(c2,{layer:()=>GX,defaultLayer:()=>hz,Service:()=>PZ,ActorWaiter:()=>c2});var Ez=/^\s*\*\*Status\*\*:\s*(success|partial|failed|blocked)\b/im,xz=/\*\*Summary\*\*:\s*(.+)$/im;function QX($){if(!$)return{};let J=$.match(Ez)?.[1]?.toLowerCase(),Z=$.match(xz)?.[1]?.trim();return{...J?{status:J}:{},...Z?{summary:Z}:{}}}var vz=600000;function E7($){return $.status==="idle"&&($.lifecycle==="ephemeral"||$.lastOutcome!==void 0&&$.lastOutcome!=="success")}class PZ extends D$.Service()("@qitqode/ActorWaiter"){}var GX=f.effect(PZ,G.gen(function*(){let $=yield*L1.Service,J=yield*P$.Service,Z=yield*Y1.Service,Y=(V,X)=>G.gen(function*(){let B=(yield*Z.messages({sessionID:V,agentID:X})).findLast((q)=>q.info.role==="assistant");if(!B)return{result:void 0,structured:void 0};let j=B.info.role==="assistant"?B.info.structured:void 0;if(j!==void 0)return{result:void 0,structured:j};return{result:B.parts.findLast((q)=>q.type==="text")?.text,structured:void 0}}),K=(V,X,W)=>G.gen(function*(){let B=W.status==="idle"&&W.lastOutcome==="success"?yield*Y(V,X):{result:void 0,structured:void 0},j=QX(B.result);return{status:W.status,actor_id:W.actorID,description:W.description,agent:W.agent,background:W.background,turnCount:W.turnCount,lastTurnTime:W.lastTurnTime,lastOutcome:W.lastOutcome,...W.lastError!==void 0?{error:W.lastError}:{},...B.result!==void 0?{result:B.result}:{},...B.structured!==void 0?{structured:B.structured}:{},...j.status?{reportedStatus:j.status}:{},...j.summary?{reportedSummary:j.summary}:{},time:W.time}}),Q=G.fn("ActorWaiter.wait")(function*(V){let X=yield*$.get(V.sessionID,V.actor_id);if(!X)return{status:"unknown",actor_id:V.actor_id};if(E7(X))return yield*K(V.sessionID,V.actor_id,X);let W=yield*H0.make(),B=V.timeout_ms??vz,j=yield*O1.make();return yield*G.acquireUseRelease(J.subscribeCallback(VX,(_)=>{if(_.properties.actorID!==V.actor_id)return;if(_.properties.sessionID!==V.sessionID)return;j.fork(G.gen(function*(){let q=yield*$.get(V.sessionID,V.actor_id);if(!q)return;if(!E7(q))return;let H=yield*K(V.sessionID,V.actor_id,q);H0.doneUnsafe(W,G.succeed(H))}).pipe(G.catchCause((q)=>G.logError(`waiter rehydrate failed: ${q}`))))}),()=>G.gen(function*(){let _=yield*$.get(V.sessionID,V.actor_id);if(_&&E7(_))return yield*K(V.sessionID,V.actor_id,_);let q=yield*H0.await(W).pipe(G.timeout(B),G.catchTag("TimeoutError",()=>G.succeed(null)));if(q===null)return{status:"timeout",actor_id:V.actor_id};return q}),(_)=>G.sync(()=>_()))});return PZ.of({wait:Q})})),hz=GX.pipe(f.provide(P$.defaultLayer),f.provide(L1.defaultLayer),f.provide(Y1.defaultLayer));var IZ={current:void 0};var K1={};o$(K1,{layer:()=>HX,defaultLayer:()=>pz,TaskRegistry:()=>K1,Service:()=>AZ});var L$=b2("task",{id:i$().notNull(),session_id:i$().$type().notNull().references(()=>V0.id,{onDelete:"cascade"}),parent_task_id:i$(),status:i$().$type().notNull(),summary:i$().notNull(),owner:i$(),created_at:t0().notNull(),last_event_at:t0().notNull(),ended_at:t0(),cleanup_after:t0()},($)=>[WX({columns:[$.session_id,$.id]}),e0("task_session_idx").on($.session_id),e0("task_parent_idx").on($.session_id,$.parent_task_id),e0("task_status_idx").on($.status)]),RJ=b2("task_event",{id:t0().primaryKey({autoIncrement:!0}),session_id:i$().$type().notNull().references(()=>V0.id,{onDelete:"cascade"}),task_id:i$().notNull(),at:t0().notNull(),kind:i$().notNull(),summary:i$()},($)=>[XX({columns:[$.session_id,$.task_id],foreignColumns:[L$.session_id,L$.id]}).onDelete("cascade"),e0("task_event_task_idx").on($.session_id,$.task_id,$.at)]);var C8=F.string().regex(/^T\d+(\.\d+)*$/,"Task ID must be Tn or Tn.m..."),gz=F.enum(["open","in_progress","blocked","done","abandoned"]),x7=F.object({id:C8,session_id:F0.zod,parent_task_id:C8.optional(),status:gz,summary:F.string(),owner:F.string().optional(),created_at:F.number(),last_event_at:F.number(),ended_at:F.number().optional(),cleanup_after:F.number().optional()}),b7=F.enum(["created","started","unstarted","blocked","unblocked","done","abandoned","renamed"]),Ak=F.object({id:F.number(),task_id:C8,at:F.number(),kind:b7,summary:F.string().optional()});var jX=Z0.define("task.created",F.object({sessionID:F0.zod,task:x7})),fz=b7.exclude(["created"]),UX=Z0.define("task.updated",F.object({sessionID:F0.zod,task:x7,kind:fz}));var mz=86400000,LJ=($)=>`Task ${$} not found. Use \`task list\` to see valid task IDs, or \`task create\` to add one.`;function v7($){return{id:$.id,session_id:$.session_id,parent_task_id:$.parent_task_id??void 0,status:$.status,summary:$.summary,owner:$.owner??void 0,created_at:$.created_at,last_event_at:$.last_event_at,ended_at:$.ended_at??void 0,cleanup_after:$.cleanup_after??void 0}}function uz($){return{id:$.id,task_id:$.task_id,at:$.at,kind:$.kind,summary:$.summary??void 0}}function dz($,J){let Z=$?`${$}.`:"T",Y=J.filter((Q)=>$?Q.startsWith(Z):/^T\d+$/.test(Q)).map((Q)=>{let V=Q.slice(Z.length);return/^\d+$/.test(V)?Number(V):0}),K=Y.length>0?Math.max(...Y)+1:1;return`${Z}${K}`}class AZ extends D$.Service()("@qitqode/TaskRegistry"){}var HX=f.effect(AZ,G.gen(function*(){let $=yield*P$.Service,J=yield*R$.Service,Z=G.fn("TaskRegistry.cleanupAfter")(function*(z){let P=yield*J.get(),D=P.checkpoint?.task_archive_days??P.checkpoint?.task_cleanup_days??7;return z+D*mz}),Y=(z,P,D,L,R)=>{z$.use((N)=>N.insert(RJ).values({session_id:z,task_id:P,at:R,kind:D,summary:L??null}).run())},K=(z,P)=>z.fork($.publish(jX,{sessionID:P.session_id,task:P})),Q=(z,P,D)=>z.fork($.publish(UX,{sessionID:P.session_id,task:P,kind:D})),V=G.fn("TaskRegistry.create")(function*(z){let P=yield*O1.make(),D=Date.now(),L=z$.use((b)=>b.select({id:L$.id}).from(L$).where(_0(G$(L$.session_id,z.session_id),z.parent_id?G$(L$.parent_task_id,z.parent_id):h7(L$.parent_task_id))).all()),R=dz(z.parent_id,L.map((b)=>b.id)),N={id:R,session_id:z.session_id,parent_task_id:z.parent_id??null,status:"open",summary:z.summary,owner:z.owner??null,created_at:D,last_event_at:D,ended_at:null,cleanup_after:null};z$.use((b)=>b.insert(L$).values(N).run()),Y(z.session_id,R,"created",void 0,D);let x=v7(N);return K(P,x),x}),X=G.fn("TaskRegistry.list")(function*(z){let P=Date.now(),D=[];if(z.session_id)D.push(G$(L$.session_id,z.session_id));if(z.status)D.push(G$(L$.status,z.status));if(z.owner)D.push(G$(L$.owner,z.owner));if(!z.include_terminal){let N=NJ(G$(L$.status,"open"),G$(L$.status,"in_progress"),G$(L$.status,"blocked"));if(N)D.push(N)}if(!z.include_archived){let N=NJ(h7(L$.cleanup_after),$Z(L$.cleanup_after,P));if(N)D.push(N)}let L=D.length>0?_0(...D):void 0;return z$.use((N)=>N.select().from(L$).where(L).orderBy(L$.created_at).all()).map(v7)}),W=G.fn("TaskRegistry.get")(function*(z){let P=z$.use((D)=>D.select().from(L$).where(_0(G$(L$.session_id,z.session_id),G$(L$.id,z.id))).get());return P?v7(P):void 0}),B=G.fn("TaskRegistry.events")(function*(z){return z$.use((D)=>D.select().from(RJ).where(_0(G$(RJ.session_id,z.session_id),G$(RJ.task_id,z.task_id))).orderBy(RJ.at).all()).map(uz)}),j=G.fn("TaskRegistry.block")(function*(z){let P=yield*O1.make(),D=Date.now();z$.use((R)=>R.update(L$).set({status:"blocked",last_event_at:D}).where(_0(G$(L$.session_id,z.session_id),G$(L$.id,z.id))).run()),Y(z.session_id,z.id,"blocked",z.event_summary,D);let L=yield*W({session_id:z.session_id,id:z.id});if(!L)return yield*G.die(new E0(LJ(z.id)));return Q(P,L,"blocked"),L}),_=G.fn("TaskRegistry.unblock")(function*(z){let P=yield*O1.make(),D=Date.now();z$.use((R)=>R.update(L$).set({status:"open",last_event_at:D}).where(_0(G$(L$.session_id,z.session_id),G$(L$.id,z.id))).run()),Y(z.session_id,z.id,"unblocked",z.event_summary,D);let L=yield*W({session_id:z.session_id,id:z.id});if(!L)return yield*G.die(new E0(LJ(z.id)));return Q(P,L,"unblocked"),L}),q=G.fn("TaskRegistry.start")(function*(z){let P=yield*O1.make(),D=Date.now(),L=yield*W({session_id:z.session_id,id:z.id});if(!L)return yield*G.die(new E0(LJ(z.id)));if(L.status==="done"||L.status==="abandoned")return yield*G.logWarning(`refusing to start terminal task ${z.id} (status=${L.status})`),L;let R=z.owner??L.owner;if(L.status==="in_progress"&&R===L.owner)return L;z$.use((x)=>x.update(L$).set({status:"in_progress",owner:R??null,last_event_at:D}).where(_0(G$(L$.session_id,z.session_id),G$(L$.id,z.id))).run()),Y(z.session_id,z.id,"started",z.event_summary,D);let N=yield*W({session_id:z.session_id,id:z.id});if(!N)return yield*G.die(new E0(LJ(z.id)));return Q(P,N,"started"),N}),H=G.fn("TaskRegistry.finish")(function*(z){let P=yield*O1.make(),D=Date.now(),L=yield*Z(D);z$.use((N)=>N.update(L$).set({status:z.status,ended_at:D,cleanup_after:L,last_event_at:D}).where(_0(G$(L$.session_id,z.session_id),G$(L$.id,z.id))).run()),Y(z.session_id,z.id,z.status,z.event_summary,D);let R=yield*W({session_id:z.session_id,id:z.id});if(!R)return yield*G.die(new E0(LJ(z.id)));return Q(P,R,z.status),R}),C=G.fn("TaskRegistry.done")(function*(z){return yield*H({...z,status:"done"})}),M=G.fn("TaskRegistry.abandon")(function*(z){return yield*H({...z,status:"abandoned"})}),I=G.fn("TaskRegistry.rename")(function*(z){let P=yield*O1.make(),D=Date.now();z$.use((R)=>R.update(L$).set({summary:z.summary,last_event_at:D}).where(_0(G$(L$.session_id,z.session_id),G$(L$.id,z.id))).run()),Y(z.session_id,z.id,"renamed",z.summary,D);let L=yield*W({session_id:z.session_id,id:z.id});if(!L)return yield*G.die(new E0(LJ(z.id)));return Q(P,L,"renamed"),L});return AZ.of({create:V,list:X,get:W,events:B,block:j,unblock:_,done:C,abandon:M,rename:I,start:q})})),pz=f.suspend(()=>HX.pipe(f.provide(P$.layer),f.provide(R$.defaultLayer)));var o2={};o$(o2,{renderRebuildContext:()=>qC,renderIndex:()=>OC,loadLatest:()=>BC,loadCheckpoints:()=>_C,layer:()=>fX,lastBoundary:()=>FC,isWriterRunning:()=>zC,hasCheckpoint:()=>HC,defaultLayer:()=>mX,composeWriterPromptForTest:()=>wZ,SessionCheckpoint:()=>o2,Service:()=>D8});import jC from"path";import UC from"fs/promises";import yX from"path";var BX={current:void 0};function SZ(){try{return H$.current?.project?.id}catch{return}}function cz($){if(!Array.isArray($.content))return[];let J=[];for(let Z of $.content)if(Z.type==="tool_result"&&typeof Z.tool_use_id==="string")J.push(Z.tool_use_id);return J}function _X($){if(!Array.isArray($.content))return[];let J=[];for(let Z of $.content)if(Z.type==="tool_use"&&typeof Z.id==="string")J.push(Z.id);return J}function OX($,J){if(J<=0||J>=$.length)return J;let Z=J,Y=[],K=new Set;for(let X=Z;X<$.length;X++){Y.push(...cz($[X]));for(let W of _X($[X]))K.add(W)}let Q=new Set(Y.filter((X)=>!K.has(X)));for(let X=Z-1;X>=0&&Q.size>0;X--){let W=$[X];if(W.role!=="assistant")continue;let B=!1;for(let j of _X(W))if(Q.delete(j))B=!0;if(B)Z=X}let V=$[Z]?.id;if(V)for(let X=Z-1;X>=0;X--)if($[X].id===V)Z=X;else break;return Z}function qX($,J){if(J>=$.length)return J;for(let Z=J;Z>=0;Z--){let Y=$[Z];if(Y.info.role!=="user")continue;if(!(Y.parts.length>0&&Y.parts.every((Q)=>Q.type==="tool_result")))return Z}return 0}import lz from"fs/promises";import oz from"path";var rz=O$.create({service:"session.progress-reconcile"});function iz($){let J=$.match(/^---\n([\s\S]*?)\n---\n/);if(!J)return null;let Z=J[1].split(`
|
|
7392
|
-
`).find((K)=>K.startsWith("written-at:"));if(!Z)return null;let Y=Number(Z.slice(11).trim());if(!Number.isFinite(Y))return null;return Y}function
|
|
7393
|
-
`)}async function
|
|
7394
|
-
`)}async function
|
|
7391
|
+
`){J.push({line:Y,text:Z}),Z="",K++,Y=K,V++;continue}Z+=X,V++}if(Z.length>0)J.push({line:Y,text:Z});return J}function GX($,J,Z){let Y=$.length,K=J.length;if(Math.abs(Y-K)>Z)return Z+1;if(Y===0)return K;if(K===0)return Y;if(Y<K)return GX(J,$,Z);let Q=Array(K+1),V=Array(K+1);for(let X=0;X<=K;X++)Q[X]=X;for(let X=1;X<=Y;X++){V.fill(Z+1),V[0]=X;let W=Math.max(1,X-Z),_=Math.min(K,X+Z),j=Number.POSITIVE_INFINITY;for(let H=W;H<=_;H++){let q=$[X-1]===J[H-1]?0:1;V[H]=Math.min(Q[H]+1,V[H-1]+1,Q[H-1]+q),j=Math.min(j,V[H])}if(j>Z)return Z+1;[Q,V]=[V,Q]}return Q[K]}function PZ($,J){let Z;for(let Y of J){if(GX($,Y,2)>2)continue;if(Z!==void 0)return;Z=Y}return Z}function IZ($){if($==null||typeof $!=="object")return;let J=$;if(typeof J.operation==="string")try{let Z=JSON.parse(J.operation);if(Z&&typeof Z==="object"&&!Array.isArray(Z))J={operation:Z}}catch{}if(J.operation&&typeof J.operation==="object"&&!Array.isArray(J.operation))return{kind:"operation",operation:J.operation};return{kind:"bare",obj:J}}var c2={};o$(c2,{layer:()=>jX,defaultLayer:()=>dz,Service:()=>AZ,ActorWaiter:()=>c2});var gz=/^\s*\*\*Status\*\*:\s*(success|partial|failed|blocked)\b/im,fz=/\*\*Summary\*\*:\s*(.+)$/im;function XX($){if(!$)return{};let J=$.match(gz)?.[1]?.toLowerCase(),Z=$.match(fz)?.[1]?.trim();return{...J?{status:J}:{},...Z?{summary:Z}:{}}}var uz=600000;function b7($){return $.status==="idle"&&($.lifecycle==="ephemeral"||$.lastOutcome!==void 0&&$.lastOutcome!=="success")}class AZ extends D$.Service()("@qitqode/ActorWaiter"){}var jX=f.effect(AZ,G.gen(function*(){let $=yield*L1.Service,J=yield*P$.Service,Z=yield*Y1.Service,Y=(V,X)=>G.gen(function*(){let _=(yield*Z.messages({sessionID:V,agentID:X})).findLast((q)=>q.info.role==="assistant");if(!_)return{result:void 0,structured:void 0};let j=_.info.role==="assistant"?_.info.structured:void 0;if(j!==void 0)return{result:void 0,structured:j};return{result:_.parts.findLast((q)=>q.type==="text")?.text,structured:void 0}}),K=(V,X,W)=>G.gen(function*(){let _=W.status==="idle"&&W.lastOutcome==="success"?yield*Y(V,X):{result:void 0,structured:void 0},j=XX(_.result);return{status:W.status,actor_id:W.actorID,description:W.description,agent:W.agent,background:W.background,turnCount:W.turnCount,lastTurnTime:W.lastTurnTime,lastOutcome:W.lastOutcome,...W.lastError!==void 0?{error:W.lastError}:{},..._.result!==void 0?{result:_.result}:{},..._.structured!==void 0?{structured:_.structured}:{},...j.status?{reportedStatus:j.status}:{},...j.summary?{reportedSummary:j.summary}:{},time:W.time}}),Q=G.fn("ActorWaiter.wait")(function*(V){let X=yield*$.get(V.sessionID,V.actor_id);if(!X)return{status:"unknown",actor_id:V.actor_id};if(b7(X))return yield*K(V.sessionID,V.actor_id,X);let W=yield*B0.make(),_=V.timeout_ms??uz,j=yield*O1.make();return yield*G.acquireUseRelease(J.subscribeCallback(WX,(H)=>{if(H.properties.actorID!==V.actor_id)return;if(H.properties.sessionID!==V.sessionID)return;j.fork(G.gen(function*(){let q=yield*$.get(V.sessionID,V.actor_id);if(!q)return;if(!b7(q))return;let U=yield*K(V.sessionID,V.actor_id,q);B0.doneUnsafe(W,G.succeed(U))}).pipe(G.catchCause((q)=>G.logError(`waiter rehydrate failed: ${q}`))))}),()=>G.gen(function*(){let H=yield*$.get(V.sessionID,V.actor_id);if(H&&b7(H))return yield*K(V.sessionID,V.actor_id,H);let q=yield*B0.await(W).pipe(G.timeout(_),G.catchTag("TimeoutError",()=>G.succeed(null)));if(q===null)return{status:"timeout",actor_id:V.actor_id};return q}),(H)=>G.sync(()=>H()))});return AZ.of({wait:Q})})),dz=jX.pipe(f.provide(P$.defaultLayer),f.provide(L1.defaultLayer),f.provide(Y1.defaultLayer));var SZ={current:void 0};var K1={};o$(K1,{layer:()=>OX,defaultLayer:()=>iz,TaskRegistry:()=>K1,Service:()=>wZ});var L$=b2("task",{id:i$().notNull(),session_id:i$().$type().notNull().references(()=>V0.id,{onDelete:"cascade"}),parent_task_id:i$(),status:i$().$type().notNull(),summary:i$().notNull(),owner:i$(),created_at:t0().notNull(),last_event_at:t0().notNull(),ended_at:t0(),cleanup_after:t0()},($)=>[BX({columns:[$.session_id,$.id]}),e0("task_session_idx").on($.session_id),e0("task_parent_idx").on($.session_id,$.parent_task_id),e0("task_status_idx").on($.status)]),RJ=b2("task_event",{id:t0().primaryKey({autoIncrement:!0}),session_id:i$().$type().notNull().references(()=>V0.id,{onDelete:"cascade"}),task_id:i$().notNull(),at:t0().notNull(),kind:i$().notNull(),summary:i$()},($)=>[UX({columns:[$.session_id,$.task_id],foreignColumns:[L$.session_id,L$.id]}).onDelete("cascade"),e0("task_event_task_idx").on($.session_id,$.task_id,$.at)]);var C8=F.string().regex(/^T\d+(\.\d+)*$/,"Task ID must be Tn or Tn.m..."),pz=F.enum(["open","in_progress","blocked","done","abandoned"]),v7=F.object({id:C8,session_id:F0.zod,parent_task_id:C8.optional(),status:pz,summary:F.string(),owner:F.string().optional(),created_at:F.number(),last_event_at:F.number(),ended_at:F.number().optional(),cleanup_after:F.number().optional()}),h7=F.enum(["created","started","unstarted","blocked","unblocked","done","abandoned","renamed"]),Tk=F.object({id:F.number(),task_id:C8,at:F.number(),kind:h7,summary:F.string().optional()});var HX=Z0.define("task.created",F.object({sessionID:F0.zod,task:v7})),cz=h7.exclude(["created"]),_X=Z0.define("task.updated",F.object({sessionID:F0.zod,task:v7,kind:cz}));var lz=86400000,LJ=($)=>`Task ${$} not found. Use \`task list\` to see valid task IDs, or \`task create\` to add one.`;function g7($){return{id:$.id,session_id:$.session_id,parent_task_id:$.parent_task_id??void 0,status:$.status,summary:$.summary,owner:$.owner??void 0,created_at:$.created_at,last_event_at:$.last_event_at,ended_at:$.ended_at??void 0,cleanup_after:$.cleanup_after??void 0}}function oz($){return{id:$.id,task_id:$.task_id,at:$.at,kind:$.kind,summary:$.summary??void 0}}function rz($,J){let Z=$?`${$}.`:"T",Y=J.filter((Q)=>$?Q.startsWith(Z):/^T\d+$/.test(Q)).map((Q)=>{let V=Q.slice(Z.length);return/^\d+$/.test(V)?Number(V):0}),K=Y.length>0?Math.max(...Y)+1:1;return`${Z}${K}`}class wZ extends D$.Service()("@qitqode/TaskRegistry"){}var OX=f.effect(wZ,G.gen(function*(){let $=yield*P$.Service,J=yield*R$.Service,Z=G.fn("TaskRegistry.cleanupAfter")(function*(C){let P=yield*J.get(),D=P.checkpoint?.task_archive_days??P.checkpoint?.task_cleanup_days??7;return C+D*lz}),Y=(C,P,D,L,R)=>{z$.use((N)=>N.insert(RJ).values({session_id:C,task_id:P,at:R,kind:D,summary:L??null}).run())},K=(C,P)=>C.fork($.publish(HX,{sessionID:P.session_id,task:P})),Q=(C,P,D)=>C.fork($.publish(_X,{sessionID:P.session_id,task:P,kind:D})),V=G.fn("TaskRegistry.create")(function*(C){let P=yield*O1.make(),D=Date.now(),L=z$.use((b)=>b.select({id:L$.id}).from(L$).where(_0(G$(L$.session_id,C.session_id),C.parent_id?G$(L$.parent_task_id,C.parent_id):f7(L$.parent_task_id))).all()),R=rz(C.parent_id,L.map((b)=>b.id)),N={id:R,session_id:C.session_id,parent_task_id:C.parent_id??null,status:"open",summary:C.summary,owner:C.owner??null,created_at:D,last_event_at:D,ended_at:null,cleanup_after:null};z$.use((b)=>b.insert(L$).values(N).run()),Y(C.session_id,R,"created",void 0,D);let x=g7(N);return K(P,x),x}),X=G.fn("TaskRegistry.list")(function*(C){let P=Date.now(),D=[];if(C.session_id)D.push(G$(L$.session_id,C.session_id));if(C.status)D.push(G$(L$.status,C.status));if(C.owner)D.push(G$(L$.owner,C.owner));if(!C.include_terminal){let N=NJ(G$(L$.status,"open"),G$(L$.status,"in_progress"),G$(L$.status,"blocked"));if(N)D.push(N)}if(!C.include_archived){let N=NJ(f7(L$.cleanup_after),JZ(L$.cleanup_after,P));if(N)D.push(N)}let L=D.length>0?_0(...D):void 0;return z$.use((N)=>N.select().from(L$).where(L).orderBy(L$.created_at).all()).map(g7)}),W=G.fn("TaskRegistry.get")(function*(C){let P=z$.use((D)=>D.select().from(L$).where(_0(G$(L$.session_id,C.session_id),G$(L$.id,C.id))).get());return P?g7(P):void 0}),_=G.fn("TaskRegistry.events")(function*(C){return z$.use((D)=>D.select().from(RJ).where(_0(G$(RJ.session_id,C.session_id),G$(RJ.task_id,C.task_id))).orderBy(RJ.at).all()).map(oz)}),j=G.fn("TaskRegistry.block")(function*(C){let P=yield*O1.make(),D=Date.now();z$.use((R)=>R.update(L$).set({status:"blocked",last_event_at:D}).where(_0(G$(L$.session_id,C.session_id),G$(L$.id,C.id))).run()),Y(C.session_id,C.id,"blocked",C.event_summary,D);let L=yield*W({session_id:C.session_id,id:C.id});if(!L)return yield*G.die(new w0(LJ(C.id)));return Q(P,L,"blocked"),L}),H=G.fn("TaskRegistry.unblock")(function*(C){let P=yield*O1.make(),D=Date.now();z$.use((R)=>R.update(L$).set({status:"open",last_event_at:D}).where(_0(G$(L$.session_id,C.session_id),G$(L$.id,C.id))).run()),Y(C.session_id,C.id,"unblocked",C.event_summary,D);let L=yield*W({session_id:C.session_id,id:C.id});if(!L)return yield*G.die(new w0(LJ(C.id)));return Q(P,L,"unblocked"),L}),q=G.fn("TaskRegistry.start")(function*(C){let P=yield*O1.make(),D=Date.now(),L=yield*W({session_id:C.session_id,id:C.id});if(!L)return yield*G.die(new w0(LJ(C.id)));if(L.status==="done"||L.status==="abandoned")return yield*G.logWarning(`refusing to start terminal task ${C.id} (status=${L.status})`),L;let R=C.owner??L.owner;if(L.status==="in_progress"&&R===L.owner)return L;z$.use((x)=>x.update(L$).set({status:"in_progress",owner:R??null,last_event_at:D}).where(_0(G$(L$.session_id,C.session_id),G$(L$.id,C.id))).run()),Y(C.session_id,C.id,"started",C.event_summary,D);let N=yield*W({session_id:C.session_id,id:C.id});if(!N)return yield*G.die(new w0(LJ(C.id)));return Q(P,N,"started"),N}),U=G.fn("TaskRegistry.finish")(function*(C){let P=yield*O1.make(),D=Date.now(),L=yield*Z(D);z$.use((N)=>N.update(L$).set({status:C.status,ended_at:D,cleanup_after:L,last_event_at:D}).where(_0(G$(L$.session_id,C.session_id),G$(L$.id,C.id))).run()),Y(C.session_id,C.id,C.status,C.event_summary,D);let R=yield*W({session_id:C.session_id,id:C.id});if(!R)return yield*G.die(new w0(LJ(C.id)));return Q(P,R,C.status),R}),z=G.fn("TaskRegistry.done")(function*(C){return yield*U({...C,status:"done"})}),M=G.fn("TaskRegistry.abandon")(function*(C){return yield*U({...C,status:"abandoned"})}),I=G.fn("TaskRegistry.rename")(function*(C){let P=yield*O1.make(),D=Date.now();z$.use((R)=>R.update(L$).set({summary:C.summary,last_event_at:D}).where(_0(G$(L$.session_id,C.session_id),G$(L$.id,C.id))).run()),Y(C.session_id,C.id,"renamed",C.summary,D);let L=yield*W({session_id:C.session_id,id:C.id});if(!L)return yield*G.die(new w0(LJ(C.id)));return Q(P,L,"renamed"),L});return wZ.of({create:V,list:X,get:W,events:_,block:j,unblock:H,done:z,abandon:M,rename:I,start:q})})),iz=f.suspend(()=>OX.pipe(f.provide(P$.layer),f.provide(R$.defaultLayer)));var o2={};o$(o2,{renderRebuildContext:()=>DC,renderIndex:()=>MC,loadLatest:()=>zC,loadCheckpoints:()=>CC,layer:()=>dX,lastBoundary:()=>PC,isWriterRunning:()=>IC,hasCheckpoint:()=>FC,defaultLayer:()=>pX,composeWriterPromptForTest:()=>LZ,SessionCheckpoint:()=>o2,Service:()=>D8});import OC from"path";import qC from"fs/promises";import EX from"path";var qX={current:void 0};function RZ(){try{return B$.current?.project?.id}catch{return}}function sz($){if(!Array.isArray($.content))return[];let J=[];for(let Z of $.content)if(Z.type==="tool_result"&&typeof Z.tool_use_id==="string")J.push(Z.tool_use_id);return J}function FX($){if(!Array.isArray($.content))return[];let J=[];for(let Z of $.content)if(Z.type==="tool_use"&&typeof Z.id==="string")J.push(Z.id);return J}function zX($,J){if(J<=0||J>=$.length)return J;let Z=J,Y=[],K=new Set;for(let X=Z;X<$.length;X++){Y.push(...sz($[X]));for(let W of FX($[X]))K.add(W)}let Q=new Set(Y.filter((X)=>!K.has(X)));for(let X=Z-1;X>=0&&Q.size>0;X--){let W=$[X];if(W.role!=="assistant")continue;let _=!1;for(let j of FX(W))if(Q.delete(j))_=!0;if(_)Z=X}let V=$[Z]?.id;if(V)for(let X=Z-1;X>=0;X--)if($[X].id===V)Z=X;else break;return Z}function CX($,J){if(J>=$.length)return J;for(let Z=J;Z>=0;Z--){let Y=$[Z];if(Y.info.role!=="user")continue;if(!(Y.parts.length>0&&Y.parts.every((Q)=>Q.type==="tool_result")))return Z}return 0}import nz from"fs/promises";import az from"path";var tz=O$.create({service:"session.progress-reconcile"});function ez($){let J=$.match(/^---\n([\s\S]*?)\n---\n/);if(!J)return null;let Z=J[1].split(`
|
|
7392
|
+
`).find((K)=>K.startsWith("written-at:"));if(!Z)return null;let Y=Number(Z.slice(11).trim());if(!Number.isFinite(Y))return null;return Y}function $C($){let J=new Map,Z=/(?<!`)\(progress:\s*tasks\/([^/]+)\/progress\.md,\s*last-reconciled-written-at:\s*(\d+)\)/g;for(let Y of $.matchAll(Z)){let K=Number(Y[2]);if(Number.isFinite(K))J.set(Y[1],K)}return J}async function JC($){let J=await Bun.file(Q1($)).text().catch(()=>""),Z=$C(J),Y=MX($),K;try{K=await nz.readdir(Y)}catch{return[]}let Q=[];for(let V of K){let X=az.join(Y,V,"progress.md"),W;try{W=await Bun.file(X).text()}catch{continue}let _=ez(W);if(_===null)continue;let j=Z.get(V);if(j===void 0)Q.push({taskId:V,writtenAt:_,status:"NEW"});else if(_>j)Q.push({taskId:V,writtenAt:_,status:"CHANGED",prior:j})}return Q}function ZC($){if($.length===0)return"";let J=["SUBAGENT PROGRESS to integrate (since last reconcile):"];for(let Z of $)if(Z.status==="NEW")J.push(` - ${Z.taskId} (NEW, written-at=${Z.writtenAt})`);else J.push(` - ${Z.taskId} (CHANGED, written-at=${Z.writtenAt}, prior=${Z.prior})`);return J.push(""),J.push("For each: Read tasks/<TID>/progress.md, integrate \xA74 (verbatim commands) verbatim into main \xA75 Current work; integrate \xA75 (outcome+discoveries) into main \xA75 or \xA77 as appropriate. Then update the corresponding \xA74 line in main checkpoint to:"),J.push(" (progress: tasks/<TID>/progress.md, last-reconciled-written-at: <written-at from above>)"),J.join(`
|
|
7393
|
+
`)}async function DX($){let J=await JC($).catch((Z)=>{return tz.warn("buildProgressDiff failed; reconcile skipped this turn",{err:Z,sessionID:$}),[]});return ZC(J)}var YC=1e4,PX=20000,KC=5,AX=new Set(["read","bash","grep","glob","webfetch","websearch","edit","write","multiedit","apply_patch","codesearch"]);function QC($){let J=0;for(let Z of $.parts)try{J+=D0.estimate(JSON.stringify(Z))}catch{J+=1000}return J}function IX($){return $.parts.some((J)=>J.type==="text"||J.type==="reasoning")}function SX($){if($.length===0)return"";let J=$.findLastIndex((V)=>V.info.role==="assistant"&&V.info.finish!==void 0);if(J<=0)return $[J>=0?J:0].info.id;let Z=$.map((V)=>QC(V)),Y=J-1,K=0,Q=0;for(let V=Y;V<$.length;V++)if(K+=Z[V],IX($[V]))Q+=1;if(K>=PX)return $[Y].info.id;while(Y>0&&K<PX&&(K<YC||Q<KC))if(Y-=1,K+=Z[Y],IX($[Y]))Q+=1;return $[Y].info.id}import m7 from"fs/promises";import u7 from"path";async function yX($){if(!await Bun.file($).exists())await m7.mkdir(u7.dirname($),{recursive:!0}),await Bun.write($,wX)}async function TX($){if(!await Bun.file($).exists())await m7.mkdir(u7.dirname($),{recursive:!0}),await Bun.write($,RX)}async function kX($){if(!await Bun.file($).exists())await m7.mkdir(u7.dirname($),{recursive:!0}),await Bun.write($,NX)}function VC($){let J=Object.entries($);if(J.length===0)throw Error("CHECKPOINT_SECTION_BUDGETS is empty \u2014 F43 substitution would produce an empty prompt block");let Z=3,Y=["Section budgets (~tokens):"];for(let K=0;K<J.length;K+=Z){let Q=J.slice(K,K+Z).map(([V,X])=>`${V}: ${X}`).join(" ");Y.push(` ${Q}`)}return Y.join(`
|
|
7394
|
+
`)}async function LZ($){let J=await e.resolvePrompt("agent/checkpoint-writer");if(!J)throw Error("checkpoint-writer prompt unavailable from backend (agent/checkpoint-writer)");return[yJ({source:"checkpoint",trust:"session-state",posture:"system",body:["You are now operating in checkpoint-writer mode. Ignore the general coding-assistant framing in the system prompt above. The read, write, edit, glob, grep, and task tools are available; do not invoke others.","","========================================================================","ABSOLUTE PATHS \u2014 USE THESE VERBATIM. NEVER COMPUTE, INFER, OR MODIFY.","========================================================================","",`CHECKPOINT_PATH = ${$.checkpointFile}`,`MEMORY_PATH = ${$.memoryFile}`,`TASK_MEM_DIR = ${$.taskMemDir}`,`NOTES_PATH = ${$.notesFile}`,"","When using the Write tool, the first arg MUST be one of these literal","absolute paths (or for task narrative, TASK_MEM_DIR + '/' + task_id +","'/progress.md' or '/notes.md'). Do NOT abbreviate. Do NOT change","parent directories. Do NOT insert paths from memory of similar projects.","If you find yourself typing '/data/checkpoints/' as a parent, STOP \u2014 that","is the legacy v2 layout and is wrong. The current parent for the","checkpoint file is the directory portion of CHECKPOINT_PATH above.","========================================================================","",$.progressDiff,"",J.replace("{{SECTION_BUDGETS}}",VC(LX))].join(`
|
|
7395
7395
|
`)}),"","Write the next checkpoint for this session.","",$.rangeDesc,"","Use the `task` tool for ALL task state ops (create / start / progress / done / abandon / approve / rename / block / unblock / batch_create). Use the Write tool for the checkpoint, memory, and task narrative files at the CHECKPOINT_PATH / MEMORY_PATH / TASK_MEM_DIR locations declared above. After all writes and tool calls, stop immediately."].join(`
|
|
7396
|
-
`)}import
|
|
7397
|
-
`):"This is the first checkpoint of this session. No prior checkpoint exists; MEMORY.md and the task narrative directory likely don't exist yet either.",u=yield*G.promise(()=>
|
|
7398
|
-
`),W=X>0?V.slice(0,X):V,
|
|
7396
|
+
`)}import d7 from"fs/promises";var g0=O$.create({service:"session.checkpoint.writer"});function GC($,J,Z){return G.gen(function*(){let Y=yield*$.messages({sessionID:J,agentID:"*"}),K=0,Q=0,V=0,X=0;for(let H of Y){if(H.info.role!=="assistant")continue;if(H.info.agentID!==Z)continue;X+=1;let q=H.info.tokens;if(!q)continue;K+=(q.input??0)+(q.cache?.read??0)+(q.cache?.write??0),Q+=q.cache?.read??0,V+=q.cache?.write??0}let W=K-Q-V,_=Q+Math.max(W,0),j=_>0?Q/_:0;return{total_input_tokens:K,cache_read_tokens:Q,cache_write_tokens:V,cache_hit_rate:j,num_llm_calls:X}})}function gX($,J){let{session:Z,config:Y,actorRegistry:K,bus:Q,scope:V}=J,X=G.fn("SessionCheckpoint.tryStartCheckpointWriter")(function*(j){let H=$.get(j.sessionID);if(H){if(H.pending)g0.info("writer pending evicted (newer range arrived)",{sessionID:j.sessionID});else g0.info("writer already running, queueing",{sessionID:j.sessionID});return H.pending=j,"queued"}if(yield*K.isSystemSpawned(j.sessionID,"main"))return g0.info("tryStartCheckpointWriter skipping system-spawned session"),"skipped";let q=yield*Z.get(j.sessionID),U=yield*E0.filterCompactedEffect(j.sessionID,{contextFrom:q.contextFrom,contextWatermark:q.contextWatermark,agentID:"main"});if(U.length===0)return g0.info("no messages, skipping checkpoint",{sessionID:j.sessionID}),"skipped";let z=SX(U),M=U.findIndex((Y$)=>Y$.info.id===z),I=zX(U.map((Y$)=>({role:Y$.info.role,id:Y$.info.id,content:Y$.parts.flatMap((g)=>g.type==="tool"?[{type:"tool_use",id:g.callID},{type:"tool_result",tool_use_id:g.callID}]:[])})),Math.max(M,0)),C=U[I]?.info.id??z,P=RZ()??U2.global,D=NZ(j.sessionID),L=EX.join(f$.Path.data,"memory","projects",P),R=Q1(j.sessionID),N=M8(P),x=EX.join(D,"tasks"),b=TZ(j.sessionID);yield*G.promise(()=>d7.mkdir(D,{recursive:!0})),yield*G.promise(()=>d7.mkdir(x,{recursive:!0})),yield*G.promise(()=>d7.mkdir(L,{recursive:!0})),yield*G.promise(()=>yZ(P)),yield*G.promise(()=>yX(R)),yield*G.promise(()=>TX(N)),yield*G.promise(()=>kX(b));let v=yield*G.promise(()=>Bun.file(R).exists()),m=yield*G.promise(()=>Bun.file(N).exists()),A=v?[`Previous checkpoint: ${R}`,m?`Previous memory: ${N}`:"","Read BOTH the prior checkpoint (to dedupe Discovered/Dead-end titles AND to carry forward Live Resources, Execution-context frames, and Session-metadata fields that are still alive) AND the prior memory (project memory) before writing yours."].filter((Y$)=>Y$.length>0).join(`
|
|
7397
|
+
`):"This is the first checkpoint of this session. No prior checkpoint exists; MEMORY.md and the task narrative directory likely don't exist yet either.",u=yield*G.promise(()=>DX(j.sessionID)),r=yield*G.promise(()=>LZ({checkpointFile:R,memoryFile:N,taskMemDir:x,notesFile:b,rangeDesc:A,progressDiff:u})),S=SZ.current;if(!S)return g0.warn("tryStartCheckpointWriter skipping \u2014 Actor service unavailable",{sessionID:j.sessionID}),"skipped";let k=(yield*Y.get()).checkpoint?.fork??!1,s=(yield*G.sync(()=>z$.use((Y$)=>Y$.select({last:V0.last_checkpoint_message_id}).from(V0).where(G$(V0.id,j.sessionID)).get())).pipe(G.catch(()=>G.succeed(void 0))))?.last??void 0,J$=U.findIndex((Y$)=>Y$.info.id===C);if(J$<0)return g0.warn("tryStartCheckpointWriter: watermark message not found, skipping",{sessionID:j.sessionID,endMessageID:C}),"skipped";let Z$=s?U.findIndex((Y$)=>Y$.info.id===s):-1,W$=Z$>=0?Z$+1:0,y$=CX(U.map((Y$)=>({info:{role:Y$.info.role},parts:Y$.parts})),W$),Q$=k?[]:U.slice(y$,J$+1);if(!k&&Q$.length===0)return g0.warn("tryStartCheckpointWriter: empty delta under fork:false, skipping",{sessionID:j.sessionID,endMessageID:C,lastCheckpointMessageID:s}),"skipped";let y=qX.current;if(!y)g0.warn("tryStartCheckpointWriter: prefixCaptureRef not set, spawning without forkContext",{sessionID:j.sessionID});let n=yield*y?G.gen(function*(){let g=U[J$].info.agent;if(k){if(!g){g0.warn("tryStartCheckpointWriter: watermark has no agent, fork:true requires parent agent \u2014 falling back to no forkContext",{sessionID:j.sessionID,endMessageID:C});return}let C$=U.slice(0,J$+1),T$=yield*y({sessionID:j.sessionID,agentName:g,providerID:j.model.providerID,modelID:j.model.modelID,msgs:C$});return{system:T$.system,tools:T$.tools,inheritedMessages:T$.inheritedMessages,parentPermission:T$.parentPermission,watermarkMsgID:C,model:{providerID:j.model.providerID,modelID:j.model.modelID}}}let t=yield*y({sessionID:j.sessionID,agentName:"checkpoint-writer",providerID:j.model.providerID,modelID:j.model.modelID,msgs:Q$});return{system:t.system,tools:t.tools,inheritedMessages:t.inheritedMessages,parentPermission:t.parentPermission,watermarkMsgID:C,model:{providerID:j.model.providerID,modelID:j.model.modelID}}}):G.succeed(void 0),a=yield*Z.create({parentID:j.sessionID,title:`checkpoint-writer: ${A}`});g0.info("tryStartCheckpointWriter spawning",{sessionID:j.sessionID,childSessionID:a.id,mode:k?"fork":"no-fork",inheritedMessageCount:n?.inheritedMessages?.length??0,rangeDesc:A});let c$=yield*S.spawn({mode:"subagent",sessionID:a.id,parentSessionID:j.sessionID,agentType:"checkpoint-writer",description:`checkpoint writer for session ${j.sessionID} covering ${A}`,task:r,context:"full",tools:["read","write","edit","apply_patch","glob","grep","task"],model:{providerID:j.model.providerID,modelID:j.model.modelID},background:!0,forkContext:n}),l=c$.actorID;j.onStarted?.(c$.outcome);let d=yield*G.promise(()=>xX(j.sessionID));return bX(j.sessionID,l,{priorTitles:d,expectedRevisions:[]}),$.set(j.sessionID,{writing:c$.outcome}),yield*G.gen(function*(){let Y$=yield*B0.await(c$.outcome);yield*G.sync(()=>z$.use((C$)=>C$.update(V0).set({last_checkpoint_message_id:C}).where(G$(V0.id,j.sessionID)).run()));let g=$.get(j.sessionID)?.pending;$.delete(j.sessionID);let t=yield*GC(Z,j.sessionID,c$.actorID).pipe(G.catch(()=>G.succeed({total_input_tokens:0,cache_read_tokens:0,cache_write_tokens:0,cache_hit_rate:0,num_llm_calls:0})));if(yield*Q.publish(hX,{sessionID:j.sessionID,writerActorID:c$.actorID,status:Y$.status==="success"?"completed":"failed",...t}).pipe(G.ignore),g)g0.info("draining pending writer",{sessionID:j.sessionID}),yield*X(g).pipe(G.ignore)}).pipe(G.ensuring(G.sync(()=>vX(j.sessionID,l))),G.forkIn(V)),"started"}),W=G.fn("SessionCheckpoint.waitForWriter")(function*(j){let H=$.get(j);if(!H)return"no-writer";return(yield*B0.await(H.writing).pipe(G.timeout(300000),G.catch(()=>G.succeed({status:"failure",error:"timeout"})))).status==="success"?"success":"failure"}),_=G.fn("SessionCheckpoint.drainWriters")(function*(j){let H=j?.timeoutMs??120000,q=[...$.values()];if(q.length===0)return{drained:0,timedOut:0};g0.info("draining checkpoint writers before shutdown",{count:q.length,timeoutMs:H}),yield*G.all(q.map((M)=>B0.await(M.writing)),{concurrency:"unbounded"}).pipe(G.timeout(H),G.catch(()=>G.succeed(void 0)));let U=$.size,z=q.length-U;if(U>0)g0.warn("drain timed out, writers still pending",{drained:z,timedOut:U});else g0.info("drain complete",{drained:z});return{drained:z,timedOut:U}});return{tryStartCheckpointWriter:X,waitForWriter:W,drainWriters:_}}import p7 from"path";async function fX($,J){let Z=await Bun.file($).text().catch(()=>{return});if(Z===void 0)return;let Y=D0.estimate(Z);if(Y<=J)return{done:{text:Z,truncated:!1,totalTokens:Y}};return{fullText:Z,totalTokens:Y}}async function mX($,J){let Z=await fX($,J);if(Z===void 0)return;if("done"in Z)return Z.done;let{fullText:Y,totalTokens:K}=Z,Q=J/K,V=Y.slice(0,Math.floor(Y.length*Q*0.95)),X=V.lastIndexOf(`
|
|
7398
|
+
`),W=X>0?V.slice(0,X):V,_=W.split(`
|
|
7399
7399
|
`).length+1,j=`
|
|
7400
7400
|
|
|
7401
|
-
\u26A0\uFE0F Truncated at ~${J} tokens. ${$} is ~${K} tokens total. Read("${$}", offset=${
|
|
7402
|
-
`)){if(Q.startsWith("## ")){if(Y)Z.push(Y);Y={header:Q,italic:"",body:[],indexLines:[]},K=!1;continue}if(Y){if(!K&&Q.startsWith("_")&&Q.endsWith("_")){Y.italic=Q,K=!0;continue}if(/^- See \S+\.md \(\d+/.test(Q.trim()))Y.indexLines.push(Q);Y.body.push(Q)}else J.push(Q)}if(Y)Z.push(Y);return{preamble:J,sections:Z}}async function
|
|
7403
|
-
`))>=J){let
|
|
7401
|
+
\u26A0\uFE0F Truncated at ~${J} tokens. ${$} is ~${K} tokens total. Read("${$}", offset=${_}) for the rest.`;return{text:W+j,truncated:!0,totalTokens:K}}function XC($){let J=[],Z=[],Y=null,K=!1;for(let Q of $.split(`
|
|
7402
|
+
`)){if(Q.startsWith("## ")){if(Y)Z.push(Y);Y={header:Q,italic:"",body:[],indexLines:[]},K=!1;continue}if(Y){if(!K&&Q.startsWith("_")&&Q.endsWith("_")){Y.italic=Q,K=!0;continue}if(/^- See \S+\.md \(\d+/.test(Q.trim()))Y.indexLines.push(Q);Y.body.push(Q)}else J.push(Q)}if(Y)Z.push(Y);return{preamble:J,sections:Z}}async function kZ($,J){let Z=await fX($,J);if(Z===void 0)return;if("done"in Z)return Z.done;let{fullText:Y,totalTokens:K}=Z,{preamble:Q,sections:V}=XC(Y);if(D0.estimate([...Q,...V.flatMap((H)=>[H.header,H.italic,...H.indexLines])].join(`
|
|
7403
|
+
`))>=J){let H=[...Q,...V.flatMap((U)=>[U.header,U.italic,...U.indexLines,""])].join(`
|
|
7404
7404
|
`),q=`
|
|
7405
7405
|
|
|
7406
7406
|
\u26A0\uFE0F File extremely large (${K} tokens vs budget ${J}). Only structure shown.
|
|
7407
|
-
Read("${$}") for full content.`;return{text:
|
|
7408
|
-
`));for(let
|
|
7409
|
-
`)),W.push(
|
|
7410
|
-
`),
|
|
7407
|
+
Read("${$}") for full content.`;return{text:H+q,truncated:!0,totalTokens:K}}let W=[...Q],_=D0.estimate(W.join(`
|
|
7408
|
+
`));for(let H of V){_+=D0.estimate([H.header,H.italic,...H.indexLines].join(`
|
|
7409
|
+
`)),W.push(H.header,H.italic,...H.indexLines);let q=new Set(H.indexLines),U=H.body.filter((M)=>!q.has(M)).join(`
|
|
7410
|
+
`),z=D0.estimate(U);if(_+z<=J)W.push(U),_+=z;else{let M=J-_;if(M>50){let I=Math.floor(U.length*(M/z)*0.95);W.push(U.slice(0,I)),_+=M}}W.push("")}let j=`
|
|
7411
7411
|
|
|
7412
7412
|
\u26A0\uFE0F Truncated at ~${J} tokens. ${$} is ~${K} tokens total. Read("${$}") for full content.`;return{text:W.join(`
|
|
7413
|
-
`)+j,truncated:!0,totalTokens:K}}function
|
|
7414
|
-
... (truncated, full body at file)`;if(J<=0)return"";if(J<=Z.length)return Z.slice(0,J);return $.slice(0,J-Z.length)+Z}function
|
|
7415
|
-
`)}function
|
|
7416
|
-
`)}function
|
|
7417
|
-
`)})}function
|
|
7418
|
-
`)})}function
|
|
7419
|
-
`)})}var
|
|
7420
|
-
`)}),W=G.fn("SessionCheckpoint.renderRebuildContext")(function*(j,
|
|
7421
|
-
`),
|
|
7422
|
-
`)}),
|
|
7413
|
+
`)+j,truncated:!0,totalTokens:K}}function WC($,J){if($.length<=J)return $;let Z=`
|
|
7414
|
+
... (truncated, full body at file)`;if(J<=0)return"";if(J<=Z.length)return Z.slice(0,J);return $.slice(0,J-Z.length)+Z}function jC($,J,Z){if(D0.estimate($)<=J)return $;let Y=$.slice(0,Math.floor(J*0.6)*4).replace(/[\uD800-\uDBFF]$/,""),K=Math.floor(J*0.3)*4,Q=(K>0?$.slice(-K):"").replace(/^[\uDC00-\uDFFF]/,""),V=Math.max(0,D0.estimate($)-D0.estimate(Y)-D0.estimate(Q));return[Y,`[\u2026elided ${V} tokens; messageID=${Z}; use the history tool with operation=around to fetch full content]`,Q].join(`
|
|
7415
|
+
`)}function UC($){return $.filter((J)=>J.type==="text"&&!J.synthetic&&typeof J.text==="string"&&J.text.length>0).map((J)=>J.text).join(`
|
|
7416
|
+
`)}function BC(){return yJ({source:"checkpoint",trust:"runtime-safety",body:["You are mid-loop in an autonomous task. Continue your work loop:","respond to the tool results below and proceed to the next iteration."].join(`
|
|
7417
|
+
`)})}function HC($){let J=$?`Consult this session's tasks/${$}/progress.md head section.`:"Consult the most recently active task's progress.md head section.";return yJ({source:"checkpoint",trust:"runtime-safety",body:["The previous assistant turn ended with a stop. Before stopping again,",J,"Compare the Task spec to the latest Progress entries. If the task is","incomplete, proceed to the next concrete step. Only stop when the spec","is genuinely satisfied or you need user input you cannot infer."].join(`
|
|
7418
|
+
`)})}function _C(){return yJ({source:"tool-result",trust:"runtime-safety",body:["Tool results above are real history from the autonomous loop. Process","them and continue to the next iteration. Do not pause to summarize."].join(`
|
|
7419
|
+
`)})}var EZ=O$.create({service:"session.checkpoint.renderer"});function uX($,J){let{session:Z,config:Y,memory:K,taskRegistry:Q,actorRegistry:V}=J,X=G.fn("SessionCheckpoint.renderIndex")(function*(j){let H=Q1(j);if(!(yield*G.promise(()=>Bun.file(H).exists())))return"No checkpoints yet for this session.";let z=(yield*G.promise(()=>Bun.file(H).text().catch(()=>""))).match(/^Topic:\s*(.+)$/m),M=z?z[1].trim():"(unknown)",I=NZ(j),C=[];return C.push("## Checkpoint"),C.push(""),C.push(`Directory: ${I}/`),C.push(""),C.push(`Current checkpoint (${M}): checkpoint.md [shown below]`),C.push(""),C.push(`Use read("${H}") to access the full checkpoint.`),C.join(`
|
|
7420
|
+
`)}),W=G.fn("SessionCheckpoint.renderRebuildContext")(function*(j,H){if(H?.agentID&&H.agentID!=="main")return"";let q=$.get(j);if(q)EZ.info("rebuild waiting for in-flight writer",{sessionID:j}),yield*G.race(B0.await(q.writing).pipe(G.as("done")),G.sleep("60 seconds").pipe(G.tap(()=>G.sync(()=>EZ.warn("writer wait timeout \u2014 using on-disk checkpoint",{sessionID:j}))),G.as("timeout"))).pipe(G.catch(()=>G.succeed("error")));let z=(yield*Y.get()).checkpoint?.push_caps??{},M=RZ(),I=M??U2.global,C=yield*Q.list({session_id:j,include_terminal:!0}),D=(yield*G.promise(()=>kZ(Q1(j),z.checkpoint??11000)))?.text??"";yield*G.promise(()=>yZ(I));let R=(yield*G.promise(()=>kZ(M8(I),z.memory??1e4)))?.text??"",x=(yield*G.promise(()=>mX(TZ(j),z.notes??6000)))?.text??"",v=(yield*G.promise(()=>kZ(c7(),z.global??6000)))?.text??"",m=yield*V.listActive(),A=z.recent_user??16000,u=z.recent_user_per_msg??2000,r=[];if(A>0){let W$=E0.page({sessionID:j,agentID:"main",limit:200}).items.filter((Q$)=>Q$.info.role==="user"&&!Q$.parts.some((y)=>y.type==="tool"||y.type==="checkpoint"||y.type==="compaction")),y$=A;for(let Q$=W$.length-1;Q$>=0;Q$--){let y=UC(W$[Q$].parts);if(!y.trim())continue;let n=jC(y,u,W$[Q$].info.id),a=D0.estimate(n);if(y$-a<0)break;r.unshift(n),y$-=a}}if(C.length===0&&!D.trim()&&!R.trim()&&!v.trim()&&m.length===0&&r.length===0)return"";let S=[];if(S.push("The following blocks are auto-loaded from your session memory. They are already in your context \u2014 do not Read them as whole files. Use Grep for specific facts instead."),S.push(""),S.push("## Tasks ledger"),C.length===0)S.push("(none)");else{let W$=C.filter((n)=>!n.parent_task_id),y$=new Map;for(let n of C){if(!n.parent_task_id)continue;let a=y$.get(n.parent_task_id)??[];a.push(n),y$.set(n.parent_task_id,a)}let Q$=(n)=>({open:"\uD83D\uDD35",in_progress:"\uD83D\uDD04",blocked:"\uD83D\uDFE1",done:"\u2705",abandoned:"\u274C"})[n]??n,y=[];for(let n of W$){y.push(`- ${n.id} ${n.status} \u2014 ${n.summary}`);let a=y$.get(n.id)??[];if(a.length===0)continue;let c$=a.map((l)=>`${Q$(l.status)}${l.id}`).join(" / ");y.push(` Subtasks: ${c$}`)}S.push(WC(y.join(`
|
|
7421
|
+
`),z.tasks_ledger??2000))}if(S.push(""),D.trim())S.push("## Session checkpoint"),S.push(D.trim()),S.push("");if(m.length>0){S.push("## Active actors");let W$=z.actor_ledger??500;for(let y$ of m){let Q$=`- ${y$.actorID} \u2014 ${y$.status}, "${y$.description}" (agent=${y$.agent})`,y=D0.estimate(Q$);if(W$-y<0)break;S.push(Q$),W$-=y}S.push("")}if(r.length>0)S.push("## Recent user input (verbatim)"),S.push(...r),S.push("");if(R.trim())S.push("## Project memory"),S.push(R.trim()),S.push("");if(v.trim())S.push("## Global memory"),S.push(v.trim()),S.push("");if(x.trim())S.push("## Session notes"),S.push(x.trim()),S.push("");yield*K.reconcile().pipe(G.ignore);let T=new Set([M8(I),Q1(j),c7()].filter((W$)=>W$.length>0)),k=M&&M!==U2.global?NJ(G$(q0.scope,"global"),_0(G$(q0.scope,"sessions"),G$(q0.scope_id,j)),_0(G$(q0.scope,"projects"),G$(q0.scope_id,M))):NJ(G$(q0.scope,"global"),_0(G$(q0.scope,"sessions"),G$(q0.scope_id,j))),A$=yield*G.sync(()=>z$.use((W$)=>W$.select({path:q0.path}).from(q0).where(k).all())),s=yield*K.root(),J$=A$.map((W$)=>W$.path).filter((W$)=>!T.has(W$)&&!W$.includes(`${p7.sep}checkpoint${p7.sep}learning-`)).map((W$)=>W$.replace(s+p7.sep,""));if(J$.length>0){S.push("## Memory keys index");let W$=z.memory_titles??500;for(let y$ of J$){let Q$=D0.estimate(y$);if(W$-Q$<0)break;S.push(`- ${y$}`),W$-=Q$}S.push("")}S.push(""),S.push("This session is being continued from a previous conversation that hit a checkpoint. The session checkpoint and project memory above cover the earlier portion of the conversation."),S.push(""),S.push("Recent messages are preserved verbatim below \u2014 the assistant turn (and any tool results) you'll see is real history, not pseudo-content. Continue your task by responding to the most recent state."),S.push(""),S.push(`Resume directly. Do not acknowledge this memory dump, do not recap, do not preface with "I'll continue" or similar. Pick up the last task as if the break never happened.`);let Z$=H?.lastMessageInfo;if(Z$){let W$=(()=>{switch(Z$.role){case"assistant":if(Z$.finish==="tool-calls")return BC();return HC(void 0);case"tool":return _C();case"user":return""}})();if(W$)S.push(""),S.push(W$)}return S.join(`
|
|
7422
|
+
`)}),_=G.fn("SessionCheckpoint.insertRebuildBoundary")(function*(j){let H=yield*W(j.sessionID,{lastMessageInfo:j.lastMessageInfo,agentID:j.agentID}).pipe(G.catch(()=>G.succeed("")));if(!H)return!1;let q=yield*X(j.sessionID).pipe(G.catch(()=>G.succeed(""))),U=(j.boundaryCreatedAt??Date.now())+1,z=yield*Z.updateMessage({id:IJ.ascending(),role:"user",model:{providerID:j.model.providerID,modelID:j.model.modelID},sessionID:j.sessionID,agent:j.agent,time:{created:U}});if(yield*Z.updatePart({id:f2.ascending(),messageID:z.id,sessionID:j.sessionID,type:"checkpoint",checkpointDir:"",checkpointNumber:0,coveredUpTo:j.boundary}),q)yield*Z.updatePart({id:f2.ascending(),messageID:z.id,sessionID:j.sessionID,type:"text",synthetic:!0,text:q});yield*Z.updatePart({id:f2.ascending(),messageID:z.id,sessionID:j.sessionID,type:"text",synthetic:!0,text:H});let M=yield*V.renderForAgent(j.sessionID).pipe(G.catch(()=>G.succeed("")));if(M)yield*Z.updatePart({id:f2.ascending(),messageID:z.id,sessionID:j.sessionID,type:"text",synthetic:!0,text:M});let I=yield*Z.messages({sessionID:j.sessionID,agentID:"*"}),C=j.boundaryCreatedAt??I.find((D)=>D.info.id===j.boundary)?.info.time.created;if(C===void 0)return EZ.warn("microcompact skipped: no boundary timestamp available",{sessionID:j.sessionID,boundary:j.boundary}),!0;let P=0;for(let D of I){if(D.info.id===z.id)continue;if(D.info.time.created<=C)continue;for(let L of D.parts){if(L.type!=="tool")continue;if(!AX.has(L.tool))continue;if(L.state.status!=="completed")continue;if(L.state.time.compacted)continue;L.state.time.compacted=Date.now(),yield*Z.updatePart(L),P+=1}}if(P>0)EZ.info("rebuild microcompact",{sessionID:j.sessionID,cleared:P});return!0});return{renderIndex:X,renderRebuildContext:W,insertRebuildBoundary:_}}class D8 extends D$.Service()("@qitqode/SessionCheckpoint"){}var dX=f.effect(D8,G.gen(function*(){let $=yield*cX,J=yield*R$.Service,Z=yield*g1.Service,Y=yield*K1.Service,K=yield*L1.Service,Q=yield*P$.Service,V=yield*UJ.Scope,X=new Map,W=gX(X,{session:$,config:J,actorRegistry:K,bus:Q,scope:V}),_=uX(X,{session:$,config:J,memory:Z,taskRegistry:Y,actorRegistry:K}),{tryStartCheckpointWriter:j,waitForWriter:H,drainWriters:q}=W,{renderIndex:U,renderRebuildContext:z,insertRebuildBoundary:M}=_,I=G.fn("SessionCheckpoint.hasCheckpoint")(function*(N){return yield*G.promise(()=>Bun.file(Q1(N)).exists())}),C=G.fn("SessionCheckpoint.hasMemoryOrTasks")(function*(N){let x=yield*Z.root(),b=OC.join(x,"sessions",N);if((yield*G.promise(()=>qC.readdir(b).catch(()=>[]))).length>0)return!0;return(yield*Y.list({session_id:N,include_terminal:!0})).length>0}),P=G.fn("SessionCheckpoint.loadLatest")(function*(N){return(yield*G.promise(()=>Bun.file(Q1(N)).text().catch(()=>"")))||void 0}),D=G.fn("SessionCheckpoint.loadCheckpoints")(function*(N,x){let b=yield*G.promise(()=>Bun.file(Q1(N)).text().catch(()=>""));return b?[b]:[]}),L=G.fn("SessionCheckpoint.lastBoundary")(function*(N){return(yield*G.sync(()=>z$.use((b)=>b.select({last_checkpoint_message_id:V0.last_checkpoint_message_id}).from(V0).where(G$(V0.id,N)).get())))?.last_checkpoint_message_id}),R=G.fn("SessionCheckpoint.isWriterRunning")(function*(N){return X.has(N)});return D8.of({tryStartCheckpointWriter:j,waitForWriter:H,drainWriters:q,hasCheckpoint:I,hasMemoryOrTasks:C,loadLatest:P,loadCheckpoints:D,renderIndex:U,renderRebuildContext:z,lastBoundary:L,isWriterRunning:R,insertRebuildBoundary:M})})),pX=f.suspend(()=>dX.pipe(f.provide(lX),f.provide(P$.layer),f.provide(R$.defaultLayer),f.provide(g1.defaultLayer),f.provide(K1.defaultLayer),f.provide(L1.defaultLayer))),{runPromise:l2}=HZ(D8,pX);function FC($){return l2((J)=>J.hasCheckpoint($.sessionID))}function zC($){return l2((J)=>J.loadLatest($.sessionID))}function CC($){return l2((J)=>J.loadCheckpoints($.sessionID,$.count))}function MC($){return l2((J)=>J.renderIndex($.sessionID))}function DC($){return l2((J)=>J.renderRebuildContext($.sessionID,{lastMessageInfo:$.lastMessageInfo,agentID:$.agentID}))}function PC($){return l2((J)=>J.lastBoundary($.sessionID))}function IC($){return l2((J)=>J.isWriterRunning($.sessionID))}var Ax={current:void 0},oX={current:void 0};var AC="actor",rX=["run","spawn","status","wait","cancel","send"];function P8($,J,Z,Y){return G.fail({kind:"arity",line:Y,detail:`actor: ${$}: arity mismatch
|
|
7423
7423
|
got: actor ${$} ${Z.join(" ")}
|
|
7424
|
-
expected: actor ${$} ${J}`})}function
|
|
7425
|
-
available verbs: ${
|
|
7426
|
-
did you mean: ${Y}?`:"");return yield*G.fail({kind:"unknown-verb",line:Z,detail:K})}}});function
|
|
7427
|
-
`)+b}let m=yield*G.sync(()=>
|
|
7424
|
+
expected: actor ${$} ${J}`})}function l7($,J,Z){let Y=[],K={};for(let Q=0;Q<$.length;Q++){let V=$[Q],X=J.find((_)=>V===`--${_}`);if(X){let _=$[Q+1];if(_===void 0)return G.fail({kind:"flag",line:Z,detail:`actor: --${X} requires a value`});K[X]=_,Q++;continue}let W=J.find((_)=>V.startsWith(`--${_}=`));if(W){let _=V.slice(`--${W}=`.length);if(_==="")return G.fail({kind:"flag",line:Z,detail:`actor: --${W} requires a value`});K[W]=_;continue}Y.push(V)}return G.succeed({flags:K,rest:Y})}var iX=G.fn("mapActorRunSpawn")(function*($,J,Z){let Y=$==="run",K=["model","task","actor",...Y?["timeout"]:[],"command","context","output-schema"],{flags:Q,rest:V}=yield*l7(J,K,Z);if(V.length!==3)return yield*P8($,`<subagent_type> "<description>" "<prompt>" [--model <ref>] [--task <TID>] [--actor <id>]${Y?" [--timeout <ms>]":""} [--command <cmd>] [--context none|state|full] [--output-schema <json>]`,V,Z);return{operation:{action:$,subagent_type:V[0],description:V[1],prompt:V[2],...Q.model?{model:Q.model}:{},...Q.task?{task_id:Q.task}:{},...Q.actor?{actor_id:Q.actor}:{},...Y&&Q.timeout?{timeout_ms:Number(Q.timeout)}:{},...Q.command?{command:Q.command}:{},...Q.context?{context:Q.context}:{},...Q["output-schema"]?{output_schema:JSON.parse(Q["output-schema"])}:{}}}}),SC=G.fn("mapActorVerb")(function*($,J,Z){switch($){case"run":return yield*iX("run",J,Z);case"spawn":return yield*iX("spawn",J,Z);case"status":if(J.length!==1)return yield*P8("status","<actor_id>",J,Z);return{operation:{action:"status",actor_id:J[0]}};case"wait":{let{flags:Y,rest:K}=yield*l7(J,["timeout"],Z);if(K.length!==1)return yield*P8("wait","<actor_id> [--timeout <ms>]",K,Z);return{operation:{action:"wait",actor_id:K[0],...Y.timeout?{timeout_ms:Number(Y.timeout)}:{}}}}case"cancel":if(J.length!==1)return yield*P8("cancel","<actor_id>",J,Z);return{operation:{action:"cancel",actor_id:J[0]}};case"send":{let{flags:Y,rest:K}=yield*l7(J,["session","type"],Z);if(K.length!==2)return yield*P8("send",'<to_actor_id> "<content>" [--session <id>] [--type <t>]',K,Z);return{operation:{action:"send",to_actor_id:K[0],content:K[1],...Y.session?{to_session_id:Y.session}:{},...Y.type?{type:Y.type}:{}}}}default:{let Y=PZ($??"",rX),K=`actor: unknown verb "${$??""}"
|
|
7425
|
+
available verbs: ${rX.join(", ")}`+(Y?`
|
|
7426
|
+
did you mean: ${Y}?`:"");return yield*G.fail({kind:"unknown-verb",line:Z,detail:K})}}});function wC($){return G.gen(function*(){let J=yield*DZ($),Z=[];for(let Y of J){let[K,Q,...V]=Y.tokens;if(K!=="actor")return yield*G.fail({kind:"unknown-verb",line:Y.line,detail:`actor: every command must start with 'actor' (got '${K??""}')`});let X=yield*SC(Q,V,Y.line);Z.push(X)}return Z})}function RC($){if($.action==="spawn"||$.action==="run")return $.action;if($.background===!0||$.async===!0)return"spawn";return"run"}function LC($){let J=IZ($);if(!J)return;if(J.kind==="operation")return{operation:J.operation};let Z=J.obj,Y=Z.subagent_type,K=Z.description,Q=Z.prompt;if(typeof Y==="string"&&typeof K==="string"&&typeof Q==="string"){let V={action:RC(Z),subagent_type:Y,description:K,prompt:Q};if(typeof Z.model==="string")V.model=Z.model;if(typeof Z.task_id==="string")V.task_id=Z.task_id;if(typeof Z.actor_id==="string")V.actor_id=Z.actor_id;return{operation:V}}return}var o7=H$(AC,G.gen(function*(){let $=(yield*e.toolDescriptionEffect("actor"))??"",J=(yield*e.toolDescriptionEffect("actor.shell"))??"",Z=yield*p0.Service,Y=yield*R$.Service,K=yield*H1.Service,Q=yield*Y1.Service,V=yield*L1.Service,X=yield*o2.Service,W=yield*c2.Service,_=yield*K1.Service,j=()=>{let H=SZ.current;if(!H)return G.fail(Error("Actor service unavailable \u2014 Actor.defaultLayer must be running for the actor tool to spawn or cancel actors"));return G.succeed(H)};return G.fn("ActorTool.init")(function*(){let U=(yield*Z.list()).filter((C)=>C.mode==="subagent"&&!C.hidden).map((C)=>C.name);if(U.length===0)return yield*G.die(Error("No spawnable subagent types"));let z=F.enum(U),M=KG(z),I=G.fn("ActorTool.execute")(function*(C,P){let D=C.operation,L=yield*Y.get(),R=(Q$,y)=>{let n={status:"unknown",actor_id:y};return{title:`Actor ${Q$}: unknown`,output:JSON.stringify(n),metadata:{actor_id:y,status:"unknown"}}},N=G.fn("ActorTool.findActor")(function*(Q$){let y=yield*V.get(P.sessionID,Q$);if(y)return{entry:y,sessionID:P.sessionID};let n=F0.make(Q$),a=yield*V.get(n,Q$);if(a)return{entry:a,sessionID:n};return});if(D.action==="send"){let Q$=oX.current;if(!Q$)return yield*G.fail(Error("Inbox service unavailable \u2014 Inbox.layer must be running for the actor tool to send messages"));let y=D.to_session_id!==void 0?F0.make(D.to_session_id):P.sessionID,n=yield*Q$.send({receiverSessionID:y,receiverActorID:D.to_actor_id,senderSessionID:P.sessionID,senderActorID:P.agent??"main",content:D.content,...D.type!==void 0?{type:D.type}:{}}).pipe(G.catchTag("InboxReceiverNotFound",()=>G.succeed({inboxID:null,error:"receiver not found"})));if("error"in n)return{title:"Send failed: receiver not found",output:JSON.stringify(n),metadata:{receiver_actor_id:D.to_actor_id,receiver_session_id:y,error:n.error}};return{title:`Sent to ${D.to_actor_id}`,output:JSON.stringify({inboxID:n.inboxID}),metadata:{inboxID:n.inboxID,receiver_actor_id:D.to_actor_id,receiver_session_id:y}}}if(D.action==="status"){let Q$=yield*N(D.actor_id);if(!Q$)return R("status",D.actor_id);let y=Q$.entry,n={status:y.status,actor_id:y.actorID,description:y.description,agent:y.agent,background:y.background,turnCount:y.turnCount,lastTurnTime:y.lastTurnTime,...y.lastError!==void 0?{error:y.lastError}:{},time:y.time};return{title:`Actor status: ${y.status}`,output:JSON.stringify(n),metadata:{actor_id:y.actorID,status:y.status}}}if(D.action==="wait"){let Q$=yield*N(D.actor_id);if(!Q$)return R("wait",D.actor_id);let y=yield*W.wait({sessionID:Q$.sessionID,actor_id:D.actor_id,timeout_ms:D.timeout_ms});return{title:`Actor wait: ${y.status}${y.lastOutcome?"/"+y.lastOutcome:""}`,output:JSON.stringify(y),metadata:{actor_id:y.actor_id,status:y.status,...y.lastOutcome?{lastOutcome:y.lastOutcome}:{}}}}if(D.action==="cancel"){let Q$=yield*N(D.actor_id);if(!Q$)return R("cancel",D.actor_id);let y=Q$.entry;if(y.status==="idle"){let c$={status:y.status,actor_id:y.actorID,description:y.description,agent:y.agent,background:y.background};return{title:`Actor cancel: ${y.status}`,output:JSON.stringify(c$),metadata:{actor_id:y.actorID,status:y.status}}}yield*(yield*j()).cancel(Q$.sessionID,y.actorID,"graceful");let a={status:"cancelled",actor_id:y.actorID,description:y.description,agent:y.agent,background:y.background};return{title:"Actor cancel: cancelled",output:JSON.stringify(a),metadata:{actor_id:y.actorID,status:"cancelled"}}}if(!P.extra?.bypassAgentCheck)yield*P.ask({permission:"actor",patterns:[D.subagent_type],always:["*"],metadata:{description:D.description,subagent_type:D.subagent_type}});let x=yield*Z.get(D.subagent_type);if(!x)return yield*G.fail(new w0(`Unknown agent type "${D.subagent_type}". Valid subagent_type values are listed in the actor tool description \u2014 pass one of those.`));let b=D.prompt,v=D.action==="spawn";if(D.context==="state"){let Q$=yield*X.loadLatest(P.sessionID).pipe(G.catch(()=>G.succeed(void 0)));if(Q$)b=["<session-state>","Here is a summary of the parent session's progress:","",Q$,"</session-state>",""].join(`
|
|
7427
|
+
`)+b}let m=yield*G.sync(()=>E0.get({sessionID:P.sessionID,messageID:P.messageID}));if(m.info.role!=="assistant")return yield*G.fail(Error("Not an assistant message"));let A=D.model??x.modelRef,u=A?yield*K.resolveModelRef(A,m.info.providerID).pipe(G.map((Q$)=>({modelID:Q$.id,providerID:Q$.providerID}))):x.model??{modelID:m.info.modelID,providerID:m.info.providerID},r=D.task_id,S="";if(D.task_id){if(!C8.safeParse(D.task_id).success)r=void 0,S=`note: task_id "${D.task_id}" is not a valid task ID (expected Tn or Tn.m); ran ad-hoc. Task IDs come from the \`task\` tool.`;else if(!(yield*_.get({session_id:P.sessionID,id:D.task_id})))r=void 0,S=`note: task_id "${D.task_id}" does not exist in this session; ran ad-hoc. Create it with the \`task\` tool first, or omit task_id.`}let T=yield*j(),k=yield*T.spawn({mode:"subagent",sessionID:P.sessionID,agentType:x.name,description:D.description,task:b,context:D.context??"none",tools:x.toolAllowlist?[...x.toolAllowlist]:"INHERIT",model:u,background:v,task_id:r,onReady:({actorID:Q$,sessionID:y})=>P.metadata({title:D.description,metadata:{sessionId:y,actorId:Q$,model:u}}),...D.output_schema?{format:{type:"json_schema",schema:D.output_schema,retryCount:2}}:{}});if(D.action==="spawn")return{title:D.description,metadata:{sessionId:k.sessionID,actorId:k.actorID,model:u},output:(S?S+`
|
|
7428
7428
|
`:"")+`Background actor started. actor_id: ${k.actorID}
|
|
7429
|
-
The result will be delivered as a notification when complete.`};let A$=yield*O1.make(),s=()=>{A$.fork(T.cancel(k.sessionID,k.actorID,"graceful"))},J$=yield*G.acquireUseRelease(G.sync(()=>{P.abort.addEventListener("abort",s)}),()=>
|
|
7430
|
-
`)}});return{description:$,parameters:M,execute:(
|
|
7431
|
-
available verbs: ${
|
|
7429
|
+
The result will be delivered as a notification when complete.`};let A$=yield*O1.make(),s=()=>{A$.fork(T.cancel(k.sessionID,k.actorID,"graceful"))},J$=yield*G.acquireUseRelease(G.sync(()=>{P.abort.addEventListener("abort",s)}),()=>B0.await(k.outcome).pipe(G.timeout(D.timeout_ms??600000),G.catchTag("TimeoutError",()=>G.succeed({status:"timeout"}))),()=>G.sync(()=>{P.abort.removeEventListener("abort",s)}));if(J$.status==="failure")return yield*G.fail(Error(`Tool execution failed: ${J$.error??"unknown"}`));let Z$=J$.status==="success"?J$.structured!==void 0?JSON.stringify(J$.structured):J$.finalText??"(no output)":J$.status==="timeout"?"<timeout>task did not complete within timeout</timeout>":"<cancelled>task was cancelled</cancelled>",W$=J$.status==="success"?J$.reportedStatus??"unknown":J$.status,y$=J$.status==="success"&&J$.reportedSummary?` summary="${J$.reportedSummary.replace(/\s+/g," ").replace(/"/g,"'").trim()}"`:"";return{title:D.description,metadata:{sessionId:k.sessionID,actorId:k.actorID,model:u},output:[...S?[S,""]:[],`actor_id: ${k.actorID} (for resuming to continue this task if needed)`,"",`<actor_result status="${W$}"${y$}>`,Z$,"</actor_result>"].join(`
|
|
7430
|
+
`)}});return{description:$,parameters:M,execute:(C,P)=>I(C,P).pipe(G.orDie),shell:{description:J,parse:wC,recover:LC}}})}));var sX=["create","list","get","start","block","unblock","done","abandon","rename"],NC="task";function yC($){return G.gen(function*(){let J=yield*DZ($),Z=[];for(let Y of J){let[K,Q,...V]=Y.tokens;if(K!=="task")return yield*G.fail({kind:"unknown-verb",line:Y.line,detail:`task: every command must start with 'task' (got '${K??""}')`});let X=yield*kC(Q,V,Y.line);Z.push(X)}return Z})}function TC($){let J=IZ($);if(!J)return;if(J.kind==="operation")return{operation:J.operation};let Z=J.obj;if(typeof Z.summary==="string"){let Y={action:"create",summary:Z.summary};if(typeof Z.parent_id==="string")Y.parent_id=Z.parent_id;if(typeof Z.session_id==="string")Y.session_id=Z.session_id;return{operation:Y}}return}function c1($,J,Z){let Y=[],K={},Q={};for(let V=0;V<$.length;V++){let X=$[V],W=Z.find((H)=>X===`--${H}`);if(W){Q[W]=!0;continue}let _=J.find((H)=>X===`--${H}`);if(_){let H=$[V+1];if(H===void 0)return{flags:K,bools:Q,rest:Y,error:`--${_} requires a value`};K[_]=H,V++;continue}let j=J.find((H)=>X.startsWith(`--${H}=`));if(j){let H=X.slice(`--${j}=`.length);if(H==="")return{flags:K,bools:Q,rest:Y,error:`--${j} requires a value`};K[j]=H;continue}Y.push(X)}return{flags:K,bools:Q,rest:Y}}function l1($,J,Z){return G.fail({kind:"flag",line:Z,detail:`task: ${$}: ${J}`})}function kC($,J,Z){switch($){case"create":{let{flags:Y,rest:K,error:Q}=c1(J,["parent","session"],[]);if(Q)return l1("create",Q,Z);if(K.length!==1)return o1("create","<summary> [--parent <TID>] [--session <id>]",K,Z);return G.succeed({operation:{action:"create",summary:K[0],...Y.parent?{parent_id:Y.parent}:{},...Y.session?{session_id:Y.session}:{}}})}case"list":{let{flags:Y,bools:K,rest:Q,error:V}=c1(J,["session"],["include-terminal","include-archived"]);if(V)return l1("list",V,Z);if(Q.length>1)return o1("list","[<status>] [--include-terminal] [--include-archived] [--session <id>]",Q,Z);return G.succeed({operation:{action:"list",...Q.length===1?{status:Q[0]}:{},...K["include-terminal"]?{include_terminal:!0}:{},...K["include-archived"]?{include_archived:!0}:{},...Y.session?{session_id:Y.session}:{}}})}case"get":{let{flags:Y,rest:K,error:Q}=c1(J,["session"],[]);if(Q)return l1("get",Q,Z);if(K.length!==1)return o1("get","<id> [--session <id>]",K,Z);return G.succeed({operation:{action:"get",id:K[0],...Y.session?{session_id:Y.session}:{}}})}case"start":{let{flags:Y,rest:K,error:Q}=c1(J,["reason","session"],[]);if(Q)return l1("start",Q,Z);if(K.length!==1)return o1("start","<id> [--reason <note>] [--session <id>]",K,Z);return G.succeed({operation:{action:"start",id:K[0],...Y.reason?{event_summary:Y.reason}:{},...Y.session?{session_id:Y.session}:{}}})}case"block":{let{flags:Y,rest:K,error:Q}=c1(J,["session"],[]);if(Q)return l1("block",Q,Z);if(K.length!==2)return o1("block","<id> <reason> [--session <id>]",K,Z);return G.succeed({operation:{action:"block",id:K[0],event_summary:K[1],...Y.session?{session_id:Y.session}:{}}})}case"unblock":{let{flags:Y,rest:K,error:Q}=c1(J,["session"],[]);if(Q)return l1("unblock",Q,Z);if(K.length!==2)return o1("unblock","<id> <reason> [--session <id>]",K,Z);return G.succeed({operation:{action:"unblock",id:K[0],event_summary:K[1],...Y.session?{session_id:Y.session}:{}}})}case"done":{let{flags:Y,rest:K,error:Q}=c1(J,["session"],[]);if(Q)return l1("done",Q,Z);if(K.length!==2)return o1("done","<id> <summary> [--session <id>]",K,Z);return G.succeed({operation:{action:"done",id:K[0],event_summary:K[1],...Y.session?{session_id:Y.session}:{}}})}case"abandon":{let{flags:Y,rest:K,error:Q}=c1(J,["session"],[]);if(Q)return l1("abandon",Q,Z);if(K.length!==2)return o1("abandon","<id> <reason> [--session <id>]",K,Z);return G.succeed({operation:{action:"abandon",id:K[0],event_summary:K[1],...Y.session?{session_id:Y.session}:{}}})}case"rename":{let{flags:Y,rest:K,error:Q}=c1(J,["session"],[]);if(Q)return l1("rename",Q,Z);if(K.length!==2)return o1("rename","<id> <summary> [--session <id>]",K,Z);return G.succeed({operation:{action:"rename",id:K[0],summary:K[1],...Y.session?{session_id:Y.session}:{}}})}default:{let Y=PZ($??"",sX),K=`task: unknown verb "${$??""}"
|
|
7431
|
+
available verbs: ${sX.join(", ")}`+(Y?`
|
|
7432
7432
|
did you mean: ${Y}?`:"");return G.fail({kind:"unknown-verb",line:Z,detail:K})}}}function o1($,J,Z,Y){return G.fail({kind:"arity",line:Y,detail:`task: ${$}: arity mismatch
|
|
7433
7433
|
got: task ${$} ${Z.join(" ")}
|
|
7434
|
-
expected: task ${$} ${J}`})}var
|
|
7435
|
-
`),metadata:{count:W.length,ids:W.map((j)=>j.id)}}}if(V.action==="get"){let W=yield*Z.get({session_id:X,id:V.id});if(!W)return{title:`Task ${V.id}: not found`,output:`No task ${V.id}. Use \`task list\` to see valid task IDs.`,metadata:{}};return{title:`Task ${V.id}: ${W.status}`,output:JSON.stringify(W,null,2),metadata:{id:W.id,status:W.status}}}if(V.action==="start"){let W=yield*Z.start({session_id:X,id:V.id,owner:Q.actorID??Q.agent,event_summary:V.event_summary});return{title:`Task ${V.id}: ${W.status}`,output:`start \u2192 ${W.status}`,metadata:{id:W.id,status:W.status}}}if(V.action==="block"){let W=yield*Z.block({session_id:X,id:V.id,event_summary:V.event_summary});return{title:`Task ${V.id}: blocked`,output:`block \u2192 ${W.status}`,metadata:{id:W.id,status:W.status}}}if(V.action==="unblock"){let W=yield*Z.unblock({session_id:X,id:V.id,event_summary:V.event_summary});return{title:`Task ${V.id}: ${W.status}`,output:`unblock \u2192 ${W.status}`,metadata:{id:W.id,status:W.status}}}if(V.action==="done"){let W=yield*Z.done({session_id:X,id:V.id,event_summary:V.event_summary});return{title:`Task ${V.id}: done`,output:`done \u2192 ${W.status}`,metadata:{id:W.id,status:W.status}}}if(V.action==="abandon"){let W=yield*Z.abandon({session_id:X,id:V.id,event_summary:V.event_summary});return{title:`Task ${V.id}: abandoned`,output:`abandon \u2192 ${W.status}`,metadata:{id:W.id,status:W.status}}}if(V.action==="rename"){let W=yield*Z.rename({session_id:X,id:V.id,summary:V.summary});return{title:`Task ${V.id}: renamed`,output:`rename \u2192 "${W.summary}"`,metadata:{id:W.id,status:W.status}}}return yield*G.fail(Error(`Unknown operation: ${V.action}`))});return{description:$,parameters:
|
|
7436
|
-
The result will be delivered as a notification when complete.`,metadata:{runID:j,status:"running"}};yield*Q.metadata({metadata:{runID:j,status:"running",transcript:[]}});let q=0,
|
|
7434
|
+
expected: task ${$} ${J}`})}var nX=H$(NC,G.gen(function*(){let $=(yield*e.toolDescriptionEffect("task"))??"",J=(yield*e.toolDescriptionEffect("task.shell"))??"",Z=yield*K1.Service,Y=G.fn("TaskTool.execute")(function*(K,Q){let V=K.operation,X=V.session_id||Q.sessionID;if(V.action==="create"){let W=yield*Z.create({session_id:X,summary:V.summary,parent_id:V.parent_id||void 0,owner:Q.actorID??Q.agent});return{title:`Task created: ${W.id}`,output:`Created ${W.id} (${W.status}): ${W.summary}`,metadata:{id:W.id,status:W.status}}}if(V.action==="list"){let W=yield*Z.list({session_id:X,status:V.status,include_terminal:V.include_terminal,include_archived:V.include_archived}),_=W.length===0?["No tasks."]:W.map((j)=>{return`${j.id} ${j.status} \u2014 ${j.summary}`});return{title:`Tasks: ${W.length}`,output:_.join(`
|
|
7435
|
+
`),metadata:{count:W.length,ids:W.map((j)=>j.id)}}}if(V.action==="get"){let W=yield*Z.get({session_id:X,id:V.id});if(!W)return{title:`Task ${V.id}: not found`,output:`No task ${V.id}. Use \`task list\` to see valid task IDs.`,metadata:{}};return{title:`Task ${V.id}: ${W.status}`,output:JSON.stringify(W,null,2),metadata:{id:W.id,status:W.status}}}if(V.action==="start"){let W=yield*Z.start({session_id:X,id:V.id,owner:Q.actorID??Q.agent,event_summary:V.event_summary});return{title:`Task ${V.id}: ${W.status}`,output:`start \u2192 ${W.status}`,metadata:{id:W.id,status:W.status}}}if(V.action==="block"){let W=yield*Z.block({session_id:X,id:V.id,event_summary:V.event_summary});return{title:`Task ${V.id}: blocked`,output:`block \u2192 ${W.status}`,metadata:{id:W.id,status:W.status}}}if(V.action==="unblock"){let W=yield*Z.unblock({session_id:X,id:V.id,event_summary:V.event_summary});return{title:`Task ${V.id}: ${W.status}`,output:`unblock \u2192 ${W.status}`,metadata:{id:W.id,status:W.status}}}if(V.action==="done"){let W=yield*Z.done({session_id:X,id:V.id,event_summary:V.event_summary});return{title:`Task ${V.id}: done`,output:`done \u2192 ${W.status}`,metadata:{id:W.id,status:W.status}}}if(V.action==="abandon"){let W=yield*Z.abandon({session_id:X,id:V.id,event_summary:V.event_summary});return{title:`Task ${V.id}: abandoned`,output:`abandon \u2192 ${W.status}`,metadata:{id:W.id,status:W.status}}}if(V.action==="rename"){let W=yield*Z.rename({session_id:X,id:V.id,summary:V.summary});return{title:`Task ${V.id}: renamed`,output:`rename \u2192 "${W.summary}"`,metadata:{id:W.id,status:W.status}}}return yield*G.fail(Error(`Unknown operation: ${V.action}`))});return{description:$,parameters:qG,execute:(K,Q)=>Y(K,Q).pipe(G.orDie),shell:{description:J,parse:yC,recover:TC}}}));var aX={current:void 0};var B2={};o$(B2,{list:()=>EC,get:()=>xC,BuiltinWorkflow:()=>B2});function EC(){return e.resolveWorkflowSummaries()}function xC($){return e.resolveWorkflowSpec($)}var bC="workflow",vC=FG,r7=40,i7=160;function tX($){if($.length<=r7+i7+1)return $.slice();let J=$.length-r7-i7;return[...$.slice(0,r7),{kind:"log",text:`\u2026(${J} lines omitted)`},...$.slice($.length-i7)]}var s7=H$(bC,G.gen(function*(){let $=(yield*e.toolDescriptionEffect("workflow"))??"",J=yield*R$.Service,Z=()=>{let K=aX.current;if(!K)return G.fail(Error("Workflow runtime unavailable \u2014 WorkflowRuntime.defaultLayer must be running for the workflow tool"));return G.succeed(K)},Y=G.fn("WorkflowTool.execute")(function*(K,Q){let V=yield*Z();if(K.operation==="run"){let X=yield*J.get();if(K.name&&K.script)return yield*G.fail(Error("workflow run: provide either `name` (a built-in) or `script` (inline), not both."));let W=K.name?(yield*G.promise(()=>B2.get(K.name)))?.script:K.script;if(!W){let C=(yield*G.promise(()=>B2.list())).map((P)=>P.name).join(", ");return yield*G.fail(Error(K.name?`Unknown built-in workflow "${K.name}". Known: ${C||"(none)"}.`:"workflow run requires either `name` (a built-in) or `script` (inline)."))}let j=(yield*V.start({script:W,sessionID:Q.sessionID,parentActorID:Q.agent??"main",args:K.args,workspace:K.workspace,maxConcurrentAgents:X.workflow?.maxConcurrentAgents,scriptDeadlineMs:X.workflow?.scriptDeadlineMs,notifyOnTerminal:K.async===!0})).runID,H=K.name??"inline";if(K.async===!0)return{title:"workflow started",output:`Workflow started in background. run_id: ${j}
|
|
7436
|
+
The result will be delivered as a notification when complete.`,metadata:{runID:j,status:"running"}};yield*Q.metadata({metadata:{runID:j,status:"running",transcript:[]}});let q=0,U=yield*G.forkScoped(G.gen(function*(){while(!0){yield*G.sleep("250 millis");let C=yield*V.transcript({runID:j});if(C.length===q)continue;q=C.length,yield*Q.metadata({metadata:{runID:j,status:"running",transcript:tX(C)}})}})),z=yield*V.wait({runID:j});yield*Z8.interrupt(U);let M=tX(yield*V.transcript({runID:j})),I=M.map((C)=>C.kind==="phase"?`\u25B8 ${C.text}`:` ${C.text}`);if(z.status==="completed"){let C=JSON.stringify(z.result??null),P=C.length>4000?C.slice(0,4000)+" \u2026(truncated)":C;return{title:`workflow ${H} completed`,output:(I.length?I.join(`
|
|
7437
7437
|
`)+`
|
|
7438
7438
|
|
|
7439
7439
|
`:"")+`Result: ${P}
|
|
7440
|
-
run_id: ${j}`,metadata:{runID:j,status:"completed",transcript:M}}}if(
|
|
7440
|
+
run_id: ${j}`,metadata:{runID:j,status:"completed",transcript:M}}}if(z.status==="failed")return{title:`workflow ${H} failed`,output:(I.length?I.join(`
|
|
7441
7441
|
`)+`
|
|
7442
7442
|
|
|
7443
|
-
`:"")+`Error: ${
|
|
7444
|
-
run_id: ${j}`,metadata:{runID:j,status:"failed",transcript:M}};return{title:`workflow ${
|
|
7443
|
+
`:"")+`Error: ${z.error}
|
|
7444
|
+
run_id: ${j}`,metadata:{runID:j,status:"failed",transcript:M}};return{title:`workflow ${H} cancelled`,output:(I.length?I.join(`
|
|
7445
7445
|
`)+`
|
|
7446
7446
|
|
|
7447
7447
|
`:"")+`Cancelled.
|
|
7448
|
-
run_id: ${j}`,metadata:{runID:j,status:"cancelled",transcript:M}}}if(K.operation==="status"){let X=yield*V.status({runID:K.run_id});return{title:`workflow ${X.status}`,output:JSON.stringify(X),metadata:{runID:K.run_id,status:X.status}}}if(K.operation==="wait"){let X=yield*V.wait({runID:K.run_id,timeoutMs:K.timeout_ms});return{title:`workflow ${X.status}`,output:JSON.stringify(X),metadata:{runID:K.run_id,status:X.status}}}if(K.operation==="cancel")return yield*V.cancel({runID:K.run_id}),{title:"workflow cancelled",output:`Cancelled ${K.run_id}`,metadata:{runID:K.run_id,status:"cancelled"}};if(K.operation==="resume"){let X=yield*V.resume({runID:K.run_id});return{title:X.resumed?"workflow resumed":"workflow not resumable",output:JSON.stringify(X),metadata:{runID:K.run_id}}}throw Error(`unhandled workflow operation: ${K.operation}`)});return{description:$,parameters:
|
|
7449
|
-
`)J--;return $.substring(0,J)}var
|
|
7448
|
+
run_id: ${j}`,metadata:{runID:j,status:"cancelled",transcript:M}}}if(K.operation==="status"){let X=yield*V.status({runID:K.run_id});return{title:`workflow ${X.status}`,output:JSON.stringify(X),metadata:{runID:K.run_id,status:X.status}}}if(K.operation==="wait"){let X=yield*V.wait({runID:K.run_id,timeoutMs:K.timeout_ms});return{title:`workflow ${X.status}`,output:JSON.stringify(X),metadata:{runID:K.run_id,status:X.status}}}if(K.operation==="cancel")return yield*V.cancel({runID:K.run_id}),{title:"workflow cancelled",output:`Cancelled ${K.run_id}`,metadata:{runID:K.run_id,status:"cancelled"}};if(K.operation==="resume"){let X=yield*V.resume({runID:K.run_id});return{title:X.resumed?"workflow resumed":"workflow not resumable",output:JSON.stringify(X),metadata:{runID:K.run_id}}}throw Error(`unhandled workflow operation: ${K.operation}`)});return{description:$,parameters:vC,execute:(K,Q)=>Y(K,Q).pipe(G.scoped,G.orDie)}}));function _I($){for(var J=1;J<arguments.length;J++){var Z=arguments[J];for(var Y in Z)if(Z.hasOwnProperty(Y))$[Y]=Z[Y]}return $}function _3($,J){return Array(J+1).join($)}function OI($){return $.replace(/^\n*/,"")}function qI($){var J=$.length;while(J>0&&$[J-1]===`
|
|
7449
|
+
`)J--;return $.substring(0,J)}var FI=["ADDRESS","ARTICLE","ASIDE","AUDIO","BLOCKQUOTE","BODY","CANVAS","CENTER","DD","DIR","DIV","DL","DT","FIELDSET","FIGCAPTION","FIGURE","FOOTER","FORM","FRAMESET","H1","H2","H3","H4","H5","H6","HEADER","HGROUP","HR","HTML","ISINDEX","LI","MAIN","MENU","NAV","NOFRAMES","NOSCRIPT","OL","OUTPUT","P","PRE","SECTION","TABLE","TBODY","TD","TFOOT","TH","THEAD","TR","UL"];function O3($){return q3($,FI)}var WU=["AREA","BASE","BR","COL","COMMAND","EMBED","HR","IMG","INPUT","KEYGEN","LINK","META","PARAM","SOURCE","TRACK","WBR"];function jU($){return q3($,WU)}function zI($){return BU($,WU)}var UU=["A","TABLE","THEAD","TBODY","TFOOT","TH","TD","IFRAME","SCRIPT","AUDIO","VIDEO"];function CI($){return q3($,UU)}function MI($){return BU($,UU)}function q3($,J){return J.indexOf($.nodeName)>=0}function BU($,J){return $.getElementsByTagName&&J.some(function(Z){return $.getElementsByTagName(Z).length})}var y0={};y0.paragraph={filter:"p",replacement:function($){return`
|
|
7450
7450
|
|
|
7451
7451
|
`+$+`
|
|
7452
7452
|
|
|
7453
|
-
`}};
|
|
7454
|
-
`}};
|
|
7453
|
+
`}};y0.lineBreak={filter:"br",replacement:function($,J,Z){return Z.br+`
|
|
7454
|
+
`}};y0.heading={filter:["h1","h2","h3","h4","h5","h6"],replacement:function($,J,Z){var Y=Number(J.nodeName.charAt(1));if(Z.headingStyle==="setext"&&Y<3){var K=_3(Y===1?"=":"-",$.length);return`
|
|
7455
7455
|
|
|
7456
7456
|
`+$+`
|
|
7457
7457
|
`+K+`
|
|
7458
7458
|
|
|
7459
7459
|
`}else return`
|
|
7460
7460
|
|
|
7461
|
-
`+
|
|
7461
|
+
`+_3("#",Y)+" "+$+`
|
|
7462
7462
|
|
|
7463
|
-
`}};
|
|
7463
|
+
`}};y0.blockquote={filter:"blockquote",replacement:function($){return $=$.replace(/^\n+|\n+$/g,""),$=$.replace(/^/gm,"> "),`
|
|
7464
7464
|
|
|
7465
7465
|
`+$+`
|
|
7466
7466
|
|
|
7467
|
-
`}};
|
|
7467
|
+
`}};y0.list={filter:["ul","ol"],replacement:function($,J){var Z=J.parentNode;if(Z.nodeName==="LI"&&Z.lastElementChild===J)return`
|
|
7468
7468
|
`+$;else return`
|
|
7469
7469
|
|
|
7470
7470
|
`+$+`
|
|
7471
7471
|
|
|
7472
|
-
`}};
|
|
7472
|
+
`}};y0.listItem={filter:"li",replacement:function($,J,Z){$=$.replace(/^\n+/,"").replace(/\n+$/,`
|
|
7473
7473
|
`).replace(/\n/gm,`
|
|
7474
7474
|
`);var Y=Z.bulletListMarker+" ",K=J.parentNode;if(K.nodeName==="OL"){var Q=K.getAttribute("start"),V=Array.prototype.indexOf.call(K.children,J);Y=(Q?Number(Q)+V:V+1)+". "}return Y+$+(J.nextSibling&&!/\n$/.test($)?`
|
|
7475
|
-
`:"")}};
|
|
7475
|
+
`:"")}};y0.indentedCodeBlock={filter:function($,J){return J.codeBlockStyle==="indented"&&$.nodeName==="PRE"&&$.firstChild&&$.firstChild.nodeName==="CODE"},replacement:function($,J,Z){return`
|
|
7476
7476
|
|
|
7477
7477
|
`+J.firstChild.textContent.replace(/\n/g,`
|
|
7478
7478
|
`)+`
|
|
7479
7479
|
|
|
7480
|
-
`}};
|
|
7480
|
+
`}};y0.fencedCodeBlock={filter:function($,J){return J.codeBlockStyle==="fenced"&&$.nodeName==="PRE"&&$.firstChild&&$.firstChild.nodeName==="CODE"},replacement:function($,J,Z){var Y=J.firstChild.getAttribute("class")||"",K=(Y.match(/language-(\S+)/)||[null,""])[1],Q=J.firstChild.textContent,V=Z.fence.charAt(0),X=3,W=new RegExp("^"+V+"{3,}","gm"),_;while(_=W.exec(Q))if(_[0].length>=X)X=_[0].length+1;var j=_3(V,X);return`
|
|
7481
7481
|
|
|
7482
7482
|
`+j+K+`
|
|
7483
7483
|
`+Q.replace(/\n$/,"")+`
|
|
7484
7484
|
`+j+`
|
|
7485
7485
|
|
|
7486
|
-
`}};
|
|
7486
|
+
`}};y0.horizontalRule={filter:"hr",replacement:function($,J,Z){return`
|
|
7487
7487
|
|
|
7488
7488
|
`+Z.hr+`
|
|
7489
7489
|
|
|
7490
|
-
`}};
|
|
7490
|
+
`}};y0.inlineLink={filter:function($,J){return J.linkStyle==="inlined"&&$.nodeName==="A"&&$.getAttribute("href")},replacement:function($,J){var Z=J.getAttribute("href");if(Z)Z=Z.replace(/([()])/g,"\\$1");var Y=_6(J.getAttribute("title"));if(Y)Y=' "'+Y.replace(/"/g,"\\\"")+'"';return"["+$+"]("+Z+Y+")"}};y0.referenceLink={filter:function($,J){return J.linkStyle==="referenced"&&$.nodeName==="A"&&$.getAttribute("href")},replacement:function($,J,Z){var Y=J.getAttribute("href"),K=_6(J.getAttribute("title"));if(K)K=' "'+K+'"';var Q,V;switch(Z.linkReferenceStyle){case"collapsed":Q="["+$+"][]",V="["+$+"]: "+Y+K;break;case"shortcut":Q="["+$+"]",V="["+$+"]: "+Y+K;break;default:var X=this.references.length+1;Q="["+$+"]["+X+"]",V="["+X+"]: "+Y+K}return this.references.push(V),Q},references:[],append:function($){var J="";if(this.references.length)J=`
|
|
7491
7491
|
|
|
7492
7492
|
`+this.references.join(`
|
|
7493
7493
|
`)+`
|
|
7494
7494
|
|
|
7495
|
-
`,this.references=[];return J}};
|
|
7496
|
-
`):""}function
|
|
7495
|
+
`,this.references=[];return J}};y0.emphasis={filter:["em","i"],replacement:function($,J,Z){if(!$.trim())return"";return Z.emDelimiter+$+Z.emDelimiter}};y0.strong={filter:["strong","b"],replacement:function($,J,Z){if(!$.trim())return"";return Z.strongDelimiter+$+Z.strongDelimiter}};y0.code={filter:function($){var J=$.previousSibling||$.nextSibling,Z=$.parentNode.nodeName==="PRE"&&!J;return $.nodeName==="CODE"&&!Z},replacement:function($){if(!$)return"";$=$.replace(/\r?\n|\r/g," ");var J=/^`|^ .*?[^ ].* $|`$/.test($)?" ":"",Z="`",Y=$.match(/`+/gm)||[];while(Y.indexOf(Z)!==-1)Z=Z+"`";return Z+J+$+J+Z}};y0.image={filter:"img",replacement:function($,J){var Z=_6(J.getAttribute("alt")),Y=J.getAttribute("src")||"",K=_6(J.getAttribute("title")),Q=K?' "'+K+'"':"";return Y?"":""}};function _6($){return $?$.replace(/(\n+\s*)+/g,`
|
|
7496
|
+
`):""}function HU($){this.options=$,this._keep=[],this._remove=[],this.blankRule={replacement:$.blankReplacement},this.keepReplacement=$.keepReplacement,this.defaultRule={replacement:$.defaultReplacement},this.array=[];for(var J in $.rules)this.array.push($.rules[J])}HU.prototype={add:function($,J){this.array.unshift(J)},keep:function($){this._keep.unshift({filter:$,replacement:this.keepReplacement})},remove:function($){this._remove.unshift({filter:$,replacement:function(){return""}})},forNode:function($){if($.isBlank)return this.blankRule;var J;if(J=U3(this.array,$,this.options))return J;if(J=U3(this._keep,$,this.options))return J;if(J=U3(this._remove,$,this.options))return J;return this.defaultRule},forEach:function($){for(var J=0;J<this.array.length;J++)$(this.array[J],J)}};function U3($,J,Z){for(var Y=0;Y<$.length;Y++){var K=$[Y];if(DI(K,J,Z))return K}return}function DI($,J,Z){var Y=$.filter;if(typeof Y==="string"){if(Y===J.nodeName.toLowerCase())return!0}else if(Array.isArray(Y)){if(Y.indexOf(J.nodeName.toLowerCase())>-1)return!0}else if(typeof Y==="function"){if(Y.call($,J,Z))return!0}else throw TypeError("`filter` needs to be a string, array, or function")}function PI($){var{element:J,isBlock:Z,isVoid:Y}=$,K=$.isPre||function(H){return H.nodeName==="PRE"};if(!J.firstChild||K(J))return;var Q=null,V=!1,X=null,W=GU(X,J,K);while(W!==J){if(W.nodeType===3||W.nodeType===4){var _=W.data.replace(/[ \r\n\t]+/g," ");if((!Q||/ $/.test(Q.data))&&!V&&_[0]===" ")_=_.substr(1);if(!_){W=B3(W);continue}W.data=_,Q=W}else if(W.nodeType===1){if(Z(W)||W.nodeName==="BR"){if(Q)Q.data=Q.data.replace(/ $/,"");Q=null,V=!1}else if(Y(W)||K(W))Q=null,V=!0;else if(Q)V=!1}else{W=B3(W);continue}var j=GU(X,W,K);X=W,W=j}if(Q){if(Q.data=Q.data.replace(/ $/,""),!Q.data)B3(Q)}}function B3($){var J=$.nextSibling||$.parentNode;return $.parentNode.removeChild($),J}function GU($,J,Z){if($&&$.parentNode===J||Z(J))return J.nextSibling||J.parentNode;return J.firstChild||J.nextSibling||J.parentNode}var _U=typeof window<"u"?window:{};function II(){var $=_U.DOMParser,J=!1;try{if(new $().parseFromString("","text/html"))J=!0}catch(Z){}return J}function AI(){var $=function(){};{var J=VU();$.prototype.parseFromString=function(Z){return J.createDocument(Z)}}return $}var SI=II()?_U.DOMParser:AI();function wI($,J){var Z;if(typeof $==="string"){var Y=RI().parseFromString('<x-turndown id="turndown-root">'+$+"</x-turndown>","text/html");Z=Y.getElementById("turndown-root")}else Z=$.cloneNode(!0);return PI({element:Z,isBlock:O3,isVoid:jU,isPre:J.preformattedCode?LI:null}),Z}var H3;function RI(){return H3=H3||new SI,H3}function LI($){return $.nodeName==="PRE"||$.nodeName==="CODE"}function NI($,J){return $.isBlock=O3($),$.isCode=$.nodeName==="CODE"||$.parentNode.isCode,$.isBlank=yI($),$.flankingWhitespace=TI($,J),$}function yI($){return!jU($)&&!CI($)&&/^\s*$/i.test($.textContent)&&!zI($)&&!MI($)}function TI($,J){if($.isBlock||J.preformattedCode&&$.isCode)return{leading:"",trailing:""};var Z=kI($.textContent);if(Z.leadingAscii&&XU("left",$,J))Z.leading=Z.leadingNonAscii;if(Z.trailingAscii&&XU("right",$,J))Z.trailing=Z.trailingNonAscii;return{leading:Z.leading,trailing:Z.trailing}}function kI($){var J=$.match(/^(([ \t\r\n]*)(\s*))(?:(?=\S)[\s\S]*\S)?((\s*?)([ \t\r\n]*))$/);return{leading:J[1],leadingAscii:J[2],leadingNonAscii:J[3],trailing:J[4],trailingNonAscii:J[5],trailingAscii:J[6]}}function XU($,J,Z){var Y,K,Q;if($==="left")Y=J.previousSibling,K=/ $/;else Y=J.nextSibling,K=/^ /;if(Y){if(Y.nodeType===3)Q=K.test(Y.nodeValue);else if(Z.preformattedCode&&Y.nodeName==="CODE")Q=!1;else if(Y.nodeType===1&&!O3(Y))Q=K.test(Y.textContent)}return Q}var EI=Array.prototype.reduce,xI=[[/\\/g,"\\\\"],[/\*/g,"\\*"],[/^-/g,"\\-"],[/^\+ /g,"\\+ "],[/^(=+)/g,"\\$1"],[/^(#{1,6}) /g,"\\$1 "],[/`/g,"\\`"],[/^~~~/g,"\\~~~"],[/\[/g,"\\["],[/\]/g,"\\]"],[/^>/g,"\\>"],[/_/g,"\\_"],[/^(\d+)\. /g,"$1\\. "]];function O6($){if(!(this instanceof O6))return new O6($);var J={rules:y0,headingStyle:"setext",hr:"* * *",bulletListMarker:"*",codeBlockStyle:"indented",fence:"```",emDelimiter:"_",strongDelimiter:"**",linkStyle:"inlined",linkReferenceStyle:"full",br:" ",preformattedCode:!1,blankReplacement:function(Z,Y){return Y.isBlock?`
|
|
7497
7497
|
|
|
7498
7498
|
`:""},keepReplacement:function(Z,Y){return Y.isBlock?`
|
|
7499
7499
|
|
|
@@ -7503,85 +7503,87 @@ run_id: ${j}`,metadata:{runID:j,status:"cancelled",transcript:M}}}if(K.operation
|
|
|
7503
7503
|
|
|
7504
7504
|
`+Z+`
|
|
7505
7505
|
|
|
7506
|
-
`:Z}};this.options=
|
|
7506
|
+
`:Z}};this.options=_I({},J,$),this.rules=new HU(this.options)}O6.prototype={turndown:function($){if(!hI($))throw TypeError($+" is not a string, or an element/document/fragment node.");if($==="")return"";var J=OU.call(this,new wI($,this.options));return bI.call(this,J)},use:function($){if(Array.isArray($))for(var J=0;J<$.length;J++)this.use($[J]);else if(typeof $==="function")$(this);else throw TypeError("plugin must be a Function or an Array of Functions");return this},addRule:function($,J){return this.rules.add($,J),this},keep:function($){return this.rules.keep($),this},remove:function($){return this.rules.remove($),this},escape:function($){return xI.reduce(function(J,Z){return J.replace(Z[0],Z[1])},$)}};function OU($){var J=this;return EI.call($.childNodes,function(Z,Y){Y=new NI(Y,J.options);var K="";if(Y.nodeType===3)K=Y.isCode?Y.nodeValue:J.escape(Y.nodeValue);else if(Y.nodeType===1)K=vI.call(J,Y);return qU(Z,K)},"")}function bI($){var J=this;return this.rules.forEach(function(Z){if(typeof Z.append==="function")$=qU($,Z.append(J.options))}),$.replace(/^[\t\r\n]+/,"").replace(/[\t\r\n\s]+$/,"")}function vI($){var J=this.rules.forNode($),Z=OU.call(this,$),Y=$.flankingWhitespace;if(Y.leading||Y.trailing)Z=Z.trim();return Y.leading+J.replacement(Z,$,this.options)+Y.trailing}function qU($,J){var Z=qI($),Y=OI(J),K=Math.max($.length-Z.length,J.length-Y.length),Q=`
|
|
7507
7507
|
|
|
7508
|
-
`.substring(0,K);return Z+Q+Y}function
|
|
7508
|
+
`.substring(0,K);return Z+Q+Y}function hI($){return $!=null&&(typeof $==="string"||$.nodeType&&($.nodeType===1||$.nodeType===9||$.nodeType===11))}var FU=O6;import F3 from"net";function gI($){if(F3.isIP($)!==4)return;let J=$.split(".").map(Number);if(J.length!==4||J.some((Z)=>!Number.isInteger(Z)||Z<0||Z>255))return;return J}function zU($){let J=$.replace(/^\[|\]$/g,"").split("%")[0].toLowerCase(),Z=gI(J);if(Z){let[K,Q]=Z;return K===0||K===10||K===127||K===100&&Q>=64&&Q<=127||K===169&&Q===254||K===172&&Q>=16&&Q<=31||K===192&&Q===0||K===192&&Q===168||K===198&&(Q===18||Q===19)||K>=224}if(F3.isIP(J)!==6)return!0;let Y=J.match(/::ffff:(\d+\.\d+\.\d+\.\d+)$/)?.[1];if(Y)return zU(Y);return!J.startsWith("2")&&!J.startsWith("3")}function z3($){let J=new URL($);if(J.protocol!=="http:"&&J.protocol!=="https:")throw Error("URL must use http:// or https://");if(J.username||J.password)throw Error("URL credentials are not allowed");return J.hash="",J}async function CU($,J,Z={}){let Y=$.hostname.replace(/^\[|\]$/g,""),K=F3.isIP(Y),Q=K===4?[{address:Y,family:4}]:K===6?[{address:Y,family:6}]:await(Z.lookup??((j)=>Bun.dns.lookup(j,{family:0,socketType:"tcp"})))(Y);if(!Q.length)throw Error(`Unable to resolve webfetch host: ${Y}`);let V=Z.allowAddress??((j)=>!zU(j)),X=Q.find((j)=>!V(j.address,J));if(X)throw Error(`Webfetch blocked non-public address: ${X.address}`);let W=Q.toSorted((j,H)=>j.family-H.family)[0],_=new URL($);return _.hostname=W.family===6?`[${W.address}]`:W.address,{logical:$,pinned:_,serverName:Y}}function MU($,J,Z){return fetch($.pinned,{headers:{...J,Host:$.logical.host},redirect:"manual",signal:Z,...$.logical.protocol==="https:"?{tls:{serverName:$.serverName}}:{}})}async function DU($,J,Z){let Y=Number($.headers.get("content-length"));if(Number.isFinite(Y)&&Y>J)throw Error(`Response too large (exceeds ${Math.floor(J/1024)}KB limit)`);if(!$.body)return new Uint8Array;let K=$.body.getReader(),Q=()=>void K.cancel(Z.reason);Z.addEventListener("abort",Q,{once:!0});let V=new Uint8Array(J),X=0;try{for(;;){let W=await K.read();if(W.done)break;if(X+=W.value.byteLength,X>J)throw await K.cancel(),Error(`Response too large (exceeds ${Math.floor(J/1024)}KB limit)`);V.set(W.value,X-W.value.byteLength)}}finally{Z.removeEventListener("abort",Q)}return V.slice(0,X)}var fI=524288,mI=30000,uI=120000,PU=5,dI=new Set([301,302,303,307,308]);function p8($){return $ instanceof Error?$:Error(String($))}function pI($={}){return H$("webfetch",G.gen(function*(){return{description:(yield*e.toolDescriptionEffect("webfetch"))??"",parameters:QG,execute:(Z,Y)=>G.gen(function*(){let K=yield*G.try({try:()=>z3(Z.url),catch:p8}),Q=(Z.timeout??mI/1000)*1000,V=Math.min(Math.max(Q,1000),uI),X="*/*";switch(Z.format){case"markdown":X="text/markdown;q=1.0, text/x-markdown;q=0.9, text/plain;q=0.8, text/html;q=0.7, */*;q=0.1";break;case"text":X="text/plain;q=1.0, text/markdown;q=0.9, text/html;q=0.8, */*;q=0.1";break;case"html":X="text/html;q=1.0, application/xhtml+xml;q=0.9, text/plain;q=0.8, text/markdown;q=0.7, */*;q=0.1";break;default:X="text/html,application/xhtml+xml,application/xml;q=0.9,image/avif,image/webp,image/apng,*/*;q=0.8"}let W={"User-Agent":"Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/143.0.0.0 Safari/537.36",Accept:X,"Accept-Language":"en-US,en;q=0.9"},_=(C,P)=>G.gen(function*(){let D=yield*G.tryPromise({try:()=>CU(C,P,$),catch:p8});yield*Y.ask({permission:"webfetch",patterns:[C.toString()],always:["*"],metadata:{url:C.toString(),format:Z.format,timeout:Z.timeout}});let L=(v)=>G.tryPromise({try:(m)=>MU(D,{...W,"User-Agent":v},AbortSignal.any([m,Y.abort])),catch:p8}),R=yield*L(W["User-Agent"]),N=R.status===403&&R.headers.get("cf-mitigated")==="challenge"?yield*G.gen(function*(){return yield*G.promise(()=>R.body?.cancel()??Promise.resolve()),yield*L("qitqode")}):R,x=N.headers.get("location");if(dI.has(N.status)&&x){if(P>=PU)throw Error(`Too many redirects (maximum ${PU})`);yield*G.promise(()=>N.body?.cancel()??Promise.resolve());let v=yield*G.try({try:()=>z3(new URL(x,C).toString()),catch:p8});return yield*_(v,P+1)}if(!N.ok)throw Error(`Request failed with HTTP status ${N.status}`);let b=yield*G.tryPromise({try:(v)=>DU(N,fI,AbortSignal.any([v,Y.abort])),catch:p8});return{response:N,bytes:b,url:C}}),{response:j,bytes:H,url:q}=yield*_(K,0).pipe(G.timeoutOrElse({duration:V,orElse:()=>G.die(Error("Request timed out"))})),U=j.headers.get("content-type")||"",z=U.split(";")[0]?.trim().toLowerCase()||"",M=`${q.toString()} (${U})`;if(CZ(z)){let C=Buffer.from(H).toString("base64");return{title:M,output:"Image fetched successfully",metadata:{},attachments:[{type:"file",mime:z,url:`data:${z};base64,${C}`}]}}let I=new TextDecoder().decode(H);switch(Z.format){case"markdown":if(U.includes("text/html"))return{output:lI(I),title:M,metadata:{}};return{output:I,title:M,metadata:{}};case"text":if(U.includes("text/html"))return{output:yield*G.promise(()=>cI(I)),title:M,metadata:{}};return{output:I,title:M,metadata:{}};case"html":return{output:I,title:M,metadata:{}};default:return{output:I,title:M,metadata:{}}}}).pipe(G.orDie)}}))}var IU=pI();async function cI($){let J="",Z=!1;return await new HTMLRewriter().on("script, style, noscript, iframe, object, embed",{element(){Z=!0},text(){}}).on("*",{element(K){if(!["script","style","noscript","iframe","object","embed"].includes(K.tagName))Z=!1},text(K){if(!Z)J+=K.text}}).transform(new Response($)).text(),J.trim()}function lI($){let J=new FU({headingStyle:"atx",hr:"---",bulletListMarker:"-",codeBlockStyle:"fenced",emDelimiter:"*"});return J.remove(["script","style","meta","link"]),J.turndown($)}import*as n1 from"path";import{mkdir as oI}from"fs/promises";var rI=5,C3=H$("write",G.gen(function*(){let $=(yield*e.toolDescriptionEffect("write"))??"",J=yield*b0.Service,Z=yield*$$.Service,Y=yield*P$.Service,K=yield*W1.Service;return{description:$,parameters:YG,execute:(Q,V)=>G.gen(function*(){let X=n1.isAbsolute(Q.filePath)?Q.filePath:n1.join(t$.get(V.sessionID),Q.filePath);yield*u2(V,X);let W=yield*Z.existsSafe(X),_=W?yield*Z.readFileString(X):"";yield*F8({ctx:V,filePath:X,diffOld:_,diffNew:Q.content,write:G.gen(function*(){let z=n1.dirname(X);yield*G.promise(()=>oI(z,{recursive:!0}));let M=n1.join(z,`.tmp-${crypto.randomUUID()}`);yield*Z.writeFileString(M,Q.content),yield*Z.rename(M,X)}),event:W?"change":"add",format:K,bus:Y});let j="Wrote file successfully.";yield*J.touchFile(X,!0);let H=yield*J.diagnostics(),q=$$.normalizePath(X),U=0;for(let[z,M]of Object.entries(H)){let I=z===q;if(!I&&U>=rI)continue;let C=b0.Diagnostic.report(I?X:z,M);if(!C)continue;if(I){j+=`
|
|
7509
7509
|
|
|
7510
7510
|
LSP errors detected in this file, please fix:
|
|
7511
|
-
${
|
|
7511
|
+
${C}`;continue}U++,j+=`
|
|
7512
7512
|
|
|
7513
7513
|
LSP errors detected in other files:
|
|
7514
|
-
${
|
|
7515
|
-
`)));return{title:`Loaded skill: ${Q.name}`,output:[`<skill_content name="${Q.name}">`,`# Skill: ${Q.name}`,"",Q.content.trim(),"",`Base directory for this skill: ${X}`,"Relative paths in this skill (e.g., scripts/, reference/) are relative to this base directory.","Note: file list is sampled.","","<skill_files>",
|
|
7516
|
-
`),metadata:{name:Q.name,dir:V}}}).pipe(G.orDie)}}));var
|
|
7514
|
+
${C}`}return{title:n1.relative(B$.worktree,X),metadata:{diagnostics:H,filepath:X,exists:W},output:j}}).pipe(G.orDie)}}));var AU=H$("invalid",G.succeed({description:"Do not use",parameters:nV,execute:($)=>G.succeed({title:"Invalid Tool",output:`The arguments provided to the tool are invalid: ${$.error}`,metadata:{}})}));import SU from"path";import{pathToFileURL as iI}from"url";var M3=H$("skill",G.gen(function*(){let $=(yield*e.toolDescriptionEffect("skill"))??"",J=yield*a0.Service,Z=yield*h0.Service;return{description:$,parameters:XG,execute:(Y,K)=>G.gen(function*(){let Q=yield*J.get(Y.name);if(!Q){let H=(yield*J.all()).map((q)=>q.name).join(", ");throw Error(`Skill "${Y.name}" not found. Available skills: ${H||"none"}`)}yield*K.ask({permission:"skill",patterns:[Y.name],always:[Y.name],metadata:{}});let V=SU.dirname(Q.location),X=iI(V).href,W=10,_=yield*Z.files({cwd:V,follow:!1,hidden:!0,signal:K.abort}).pipe(RU((j)=>!j.includes("SKILL.md")),wU((j)=>SU.resolve(V,j)),qZ(W),BJ,G.map((j)=>[...j].map((H)=>`<file>${H}</file>`).join(`
|
|
7515
|
+
`)));return{title:`Loaded skill: ${Q.name}`,output:[`<skill_content name="${Q.name}">`,`# Skill: ${Q.name}`,"",Q.content.trim(),"",`Base directory for this skill: ${X}`,"Relative paths in this skill (e.g., scripts/, reference/) are relative to this base directory.","Note: file list is sampled.","","<skill_files>",_,"</skill_files>","</skill_content>"].join(`
|
|
7516
|
+
`),metadata:{name:Q.name,dir:V}}}).pipe(G.orDie)}}));var sI=120000;function nI($){if(typeof $==="string")return $.trim()||"No results found.";let J=Array.isArray($)?$:Array.isArray($?.results)?$.results:[];if(J.length===0)return"No results found.";return J.map((Z,Y)=>{let K=Z,Q=K?.title??K?.name??"(no title)",V=K?.url??K?.link??K?.href??"",X=K?.snippet??K?.description??K?.body??K?.text??"",W=[`${Y+1}. ${Q}`];if(V)W.push(` ${V}`);if(X)W.push(` ${X}`);return W.join(`
|
|
7517
7517
|
`)}).join(`
|
|
7518
7518
|
|
|
7519
|
-
`)}var
|
|
7519
|
+
`)}var D3=H$("websearch",G.gen(function*(){let $=(yield*e.toolDescriptionEffect("websearch"))??"";return{get description(){return $.replace("{{year}}",new Date().getFullYear().toString())},parameters:VG,execute:(J,Z)=>G.gen(function*(){yield*Z.ask({permission:"websearch",patterns:[J.query],always:["*"],metadata:{query:J.query,numResults:J.numResults,livecrawl:J.livecrawl,type:J.type,contextMaxCharacters:J.contextMaxCharacters,timeout:J.timeout}});let Y=J.timeout?Math.min(Math.max(J.timeout*1000,1000),sI):30000;return{output:yield*G.promise(()=>e.resolveBraveSearch(J.query,{numResults:J.numResults,timeoutMs:Y}).then(nI).catch((Q)=>`Web search failed: ${Q instanceof Error?Q.message:String(Q)}. Try using webfetch with a specific URL instead.`)),title:`Web search: ${J.query}`,metadata:{}}}).pipe(G.orDie)}}));function aI($){return Math.max(1,Math.min(20,Math.round($/500)))}function tI($){if(typeof $==="string")return $.trim()||"No results found.";let J=Array.isArray($)?$:Array.isArray($?.results)?$.results:[];if(J.length===0)return"No results found.";return J.map((Z,Y)=>{let K=Z,Q=K?.title??K?.name??"(no title)",V=K?.url??K?.link??K?.href??"",X=K?.snippet??K?.description??K?.body??K?.text??"",W=[`${Y+1}. ${Q}`];if(V)W.push(` ${V}`);if(X)W.push(` ${X}`);return W.join(`
|
|
7520
7520
|
`)}).join(`
|
|
7521
7521
|
|
|
7522
|
-
`)}var
|
|
7523
|
-
Suggestion: ${X.suggestion}`:"";return`${W+1}. ${j}${
|
|
7522
|
+
`)}var P3=H$("codesearch",G.gen(function*(){return{description:(yield*e.toolDescriptionEffect("codesearch"))??"",parameters:GG,execute:(J,Z)=>G.gen(function*(){yield*Z.ask({permission:"codesearch",patterns:[J.query],always:["*"],metadata:{query:J.query,tokensNum:J.tokensNum}});let Y=aI(J.tokensNum||5000);return{output:yield*G.promise(()=>e.resolveBraveSearch(J.query,{numResults:Y,timeoutMs:30000}).then(tI).catch(()=>"No code snippets or documentation found. Please try a different query, be more specific about the library or programming concept, or check the spelling of framework names.")),title:`Code search: ${J.query}`,metadata:{}}}).pipe(G.orDie)}}));var eI=F.object({filePath:F.string().describe("Path to the file to analyze"),fileContent:F.string().describe("Full content of the file"),focusAreas:F.array(F.string()).optional().describe('Optional list of focus areas to check, e.g. ["security", "performance", "correctness", "style"]. When omitted the analysis covers all areas.')}),I3=H$("analyze_code",G.gen(function*(){return{description:(yield*e.toolDescriptionEffect("analyze_code"))??"",parameters:eI,execute:(J,Z)=>G.gen(function*(){let Y=yield*G.promise(()=>e.resolveAnalyzeCodeForIssues({filePath:J.filePath,fileContent:J.fileContent,focusAreas:J.focusAreas})),K=Y.issues??[],Q;if(K.length===0)Q=Y.summary??"No issues found.";else{let V=K.map((X,W)=>{let _=X.line!=null?` (line ${X.line})`:"",j=X.severity?`[${X.severity}]`:"",H=X.category?` {${X.category}}`:"",q=X.suggestion?`
|
|
7523
|
+
Suggestion: ${X.suggestion}`:"";return`${W+1}. ${j}${H}${_} ${X.description}${q}`});if(Y.summary)V.unshift(Y.summary,"");Q=V.join(`
|
|
7524
7524
|
|
|
7525
|
-
`)}return{title:`Code analysis: ${J.filePath}`,output:Q,metadata:{issueCount:K.length,issues:K,summary:Y.summary}}}).pipe(G.orDie)}}));var
|
|
7525
|
+
`)}return{title:`Code analysis: ${J.filePath}`,output:Q,metadata:{issueCount:K.length,issues:K,summary:Y.summary}}}).pipe(G.orDie)}}));var $A=F.object({filePath:F.string().describe("Path to the file"),fileContent:F.string().describe("Full content of the file"),functionName:F.string().optional().describe("When provided, generate documentation only for this specific function or method"),format:F.enum(["markdown","jsdoc","docstring"]).optional().describe("Output format: markdown (default), jsdoc, or docstring")}),A3=H$("generate_docs",G.gen(function*(){return{description:(yield*e.toolDescriptionEffect("generate_docs"))??"",parameters:$A,execute:(J,Z)=>G.gen(function*(){let Y=yield*G.promise(()=>e.resolveGenerateDocumentation({filePath:J.filePath,fileContent:J.fileContent,functionName:J.functionName,format:J.format})),K=Y.documentation??Y.content??"";return{title:`Documentation: ${J.functionName??J.filePath}`,output:K||"No documentation generated.",metadata:{}}}).pipe(G.orDie)}}));var JA=F.object({filePath:F.string().describe("Path to the file"),fileContent:F.string().describe("Full content of the file to annotate with inline comments")}),S3=H$("add_inline_comments",G.gen(function*(){return{description:(yield*e.toolDescriptionEffect("add_inline_comments"))??"",parameters:JA,execute:(J,Z)=>G.gen(function*(){let Y=yield*G.promise(()=>e.resolveGenerateInlineComments({filePath:J.filePath,fileContent:J.fileContent})),K=Y.annotatedCode??Y.code??Y.content??"",Q=K?d1(R1(J.filePath,J.filePath,J.fileContent,K)):void 0;return{title:`Inline comments: ${J.filePath}`,output:K||"No annotated code returned.",metadata:K?{originalContent:J.fileContent,diff:Q}:{}}}).pipe(G.orDie)}}));import w3 from"path";import{pathToFileURL as ZA}from"url";var LU=H$("lsp",G.gen(function*(){let $=(yield*e.toolDescriptionEffect("lsp"))??"",J=yield*b0.Service,Z=yield*$$.Service;return{description:$,parameters:UG,execute:(Y,K)=>G.gen(function*(){let Q=w3.isAbsolute(Y.filePath)?Y.filePath:w3.join(B$.directory,Y.filePath);yield*_1(K,Q),yield*K.ask({permission:"lsp",patterns:["*"],always:["*"],metadata:{}});let V=ZA(Q).href,X={file:Q,line:Y.line-1,character:Y.character-1},W=w3.relative(B$.worktree,Q),_=`${Y.operation} ${W}:${Y.line}:${Y.character}`;if(!(yield*Z.existsSafe(Q)))throw Error(`File not found: ${Q}`);if(!(yield*J.hasClients(Q)))throw Error("No LSP server available for this file type.");yield*J.touchFile(Q,!0);let q=yield*(()=>{switch(Y.operation){case"goToDefinition":return J.definition(X);case"findReferences":return J.references(X);case"hover":return J.hover(X);case"documentSymbol":return J.documentSymbol(V);case"workspaceSymbol":return J.workspaceSymbol("");case"goToImplementation":return J.implementation(X);case"prepareCallHierarchy":return J.prepareCallHierarchy(X);case"incomingCalls":return J.incomingCalls(X);case"outgoingCalls":return J.outgoingCalls(X)}})();return{title:_,metadata:{result:q},output:q.length===0?`No results found for ${Y.operation}`:JSON.stringify(q,null,2)}})}}));import*as o0 from"path";import{rename as HA}from"fs/promises";var F2={};o$(F2,{parsePatch:()=>c8,maybeParseApplyPatchVerified:()=>BA,maybeParseApplyPatch:()=>EU,deriveNewContentsFromFileContents:()=>xU,deriveNewContentsFromChunks:()=>L3,applyPatch:()=>UA,applyHunksToFiles:()=>bU,PatchSchema:()=>YA,Patch:()=>F2,MaybeApplyPatchVerified:()=>kU,MaybeApplyPatch:()=>TU,ApplyPatchError:()=>yU});import*as a1 from"path";import*as l0 from"fs/promises";var q6=O$.create({service:"patch"}),YA=F.object({patchText:F.string().describe("The full patch text that describes all changes to be made")}),yU;((K)=>{K.ParseError="ParseError";K.IoError="IoError";K.ComputeReplacements="ComputeReplacements";K.ImplicitInvocation="ImplicitInvocation"})(yU||={});var TU;((K)=>{K.Body="Body";K.ShellParseError="ShellParseError";K.PatchParseError="PatchParseError";K.NotApplyPatch="NotApplyPatch"})(TU||={});var kU;((K)=>{K.Body="Body";K.ShellParseError="ShellParseError";K.CorrectnessError="CorrectnessError";K.NotApplyPatch="NotApplyPatch"})(kU||={});function KA($,J){let Z=$[J];if(Z.startsWith("*** Add File:")){let Y=Z.slice(13).trim();return Y?{filePath:Y,nextIdx:J+1}:null}if(Z.startsWith("*** Delete File:")){let Y=Z.slice(16).trim();return Y?{filePath:Y,nextIdx:J+1}:null}if(Z.startsWith("*** Update File:")){let Y=Z.slice(16).trim(),K,Q=J+1;if(Q<$.length&&$[Q].startsWith("*** Move to:"))K=$[Q].slice(12).trim(),Q++;return Y?{filePath:Y,movePath:K,nextIdx:Q}:null}return null}function QA($,J){let Z=[],Y=J;while(Y<$.length&&!$[Y].startsWith("***"))if($[Y].startsWith("@@")){let K=$[Y].substring(2).trim();Y++;let Q=[],V=[],X=!1;while(Y<$.length&&!$[Y].startsWith("@@")&&!$[Y].startsWith("***")){let W=$[Y];if(W==="*** End of File"){X=!0,Y++;break}if(W.startsWith(" ")){let _=W.substring(1);Q.push(_),V.push(_)}else if(W.startsWith("-"))Q.push(W.substring(1));else if(W.startsWith("+"))V.push(W.substring(1));Y++}Z.push({old_lines:Q,new_lines:V,change_context:K||void 0,is_end_of_file:X||void 0})}else Y++;return{chunks:Z,nextIdx:Y}}function VA($,J){let Z="",Y=J;while(Y<$.length&&!$[Y].startsWith("***")){if($[Y].startsWith("+"))Z+=$[Y].substring(1)+`
|
|
7526
7526
|
`;Y++}if(Z.endsWith(`
|
|
7527
|
-
`))Z=Z.slice(0,-1);return{content:Z,nextIdx:Y}}function
|
|
7528
|
-
`),Y=[],K=0,Q="*** Begin Patch",V="*** End Patch",X=Z.findIndex((
|
|
7529
|
-
`);if(Y.length>0&&Y[Y.length-1]==="")Y.pop();let K=
|
|
7530
|
-
`);return{unified_diff:
|
|
7527
|
+
`))Z=Z.slice(0,-1);return{content:Z,nextIdx:Y}}function GA($){let J=$.match(/^(?:cat\s+)?<<['"]?(\w+)['"]?\s*\n([\s\S]*?)\n\1\s*$/);if(J)return J[2];return $}function c8($){let Z=GA($.trim()).split(`
|
|
7528
|
+
`),Y=[],K=0,Q="*** Begin Patch",V="*** End Patch",X=Z.findIndex((_)=>_.trim()===Q),W=Z.findIndex((_)=>_.trim()===V);if(X===-1||W===-1||X>=W)throw Error("Invalid patch format: missing Begin/End markers");K=X+1;while(K<W){let _=KA(Z,K);if(!_){K++;continue}if(Z[K].startsWith("*** Add File:")){let{content:j,nextIdx:H}=VA(Z,_.nextIdx);Y.push({type:"add",path:_.filePath,contents:j}),K=H}else if(Z[K].startsWith("*** Delete File:"))Y.push({type:"delete",path:_.filePath}),K=_.nextIdx;else if(Z[K].startsWith("*** Update File:")){let{chunks:j,nextIdx:H}=QA(Z,_.nextIdx);Y.push({type:"update",path:_.filePath,move_path:_.movePath,chunks:j}),K=H}else K++}return{hunks:Y}}function EU($){let J=["apply_patch","applypatch"];if($.length===2&&J.includes($[0]))try{let{hunks:Z}=c8($[1]);return{type:"Body",args:{patch:$[1],hunks:Z}}}catch(Z){return{type:"PatchParseError",error:Z}}if($.length===3&&$[0]==="bash"&&$[1]==="-lc"){let Y=$[2].match(/apply_patch\s*<<['"](\w+)['"]\s*\n([\s\S]*?)\n\1/);if(Y){let K=Y[2];try{let{hunks:Q}=c8(K);return{type:"Body",args:{patch:K,hunks:Q}}}catch(Q){return{type:"PatchParseError",error:Q}}}}return{type:"NotApplyPatch"}}async function L3($,J){let Z;try{Z=await l0.readFile($,"utf-8")}catch(Y){throw Error(`Failed to read file ${$}: ${Y}`,{cause:Y})}return xU(Z,$,J)}function xU($,J,Z){let Y=$.split(`
|
|
7529
|
+
`);if(Y.length>0&&Y[Y.length-1]==="")Y.pop();let K=XA(Y,J,Z),Q=WA(Y,K);if(Q.length===0||Q[Q.length-1]!=="")Q.push("");let V=Q.join(`
|
|
7530
|
+
`);return{unified_diff:jA($,V),content:V}}function XA($,J,Z){let Y=[],K=0;for(let Q of Z){if(Q.change_context){let _=R3($,[Q.change_context],K);if(_===-1)throw Error(`Failed to find context '${Q.change_context}' in ${J}`);K=_+1}if(Q.old_lines.length===0){let _=$.length>0&&$[$.length-1]===""?$.length-1:$.length;Y.push([_,0,Q.new_lines]);continue}let{old_lines:V,new_lines:X}=Q,W=R3($,V,K,Q.is_end_of_file);if(W===-1&&V.length>0&&V[V.length-1]===""){if(V=V.slice(0,-1),X.length>0&&X[X.length-1]==="")X=X.slice(0,-1);W=R3($,V,K,Q.is_end_of_file)}if(W!==-1)Y.push([W,V.length,X]),K=W+V.length;else throw Error(`Failed to find expected lines in ${J}:
|
|
7531
7531
|
${Q.old_lines.join(`
|
|
7532
|
-
`)}`)}return Y.sort((Q,V)=>Q[0]-V[0]),Y}function
|
|
7532
|
+
`)}`)}return Y.sort((Q,V)=>Q[0]-V[0]),Y}function WA($,J){let Z=[],Y=0;for(let[K,Q,V]of J){for(let X=Y;X<K;X++)Z.push($[X]);for(let X of V)Z.push(X);Y=K+Q}for(let K=Y;K<$.length;K++)Z.push($[K]);return Z}function NU($){return $.replace(/[\u2018\u2019\u201A\u201B]/g,"'").replace(/[\u201C\u201D\u201E\u201F]/g,'"').replace(/[\u2010\u2011\u2012\u2013\u2014\u2015]/g,"-").replace(/\u2026/g,"...").replace(/\u00A0/g," ")}function F6($,J,Z,Y,K){if(K){let Q=$.length-J.length;if(Q>=Z){let V=!0;for(let X=0;X<J.length;X++)if(!Y($[Q+X],J[X])){V=!1;break}if(V)return Q}}for(let Q=Z;Q<=$.length-J.length;Q++){let V=!0;for(let X=0;X<J.length;X++)if(!Y($[Q+X],J[X])){V=!1;break}if(V)return Q}return-1}function R3($,J,Z,Y=!1){if(J.length===0)return-1;let K=F6($,J,Z,(W,_)=>W===_,Y);if(K!==-1)return K;let Q=F6($,J,Z,(W,_)=>W.trimEnd()===_.trimEnd(),Y);if(Q!==-1)return Q;let V=F6($,J,Z,(W,_)=>W.trim()===_.trim(),Y);if(V!==-1)return V;return F6($,J,Z,(W,_)=>NU(W.trim())===NU(_.trim()),Y)}function jA($,J){let Z=$.split(`
|
|
7533
7533
|
`),Y=J.split(`
|
|
7534
|
-
`),K=["@@ -1 +1 @@"],Q=Math.max(Z.length,Y.length),V=!1;for(let X=0;X<Q;X++){let W=Z[X]||"",
|
|
7534
|
+
`),K=["@@ -1 +1 @@"],Q=Math.max(Z.length,Y.length),V=!1;for(let X=0;X<Q;X++){let W=Z[X]||"",_=Y[X]||"";if(W!==_){if(W)K.push(`-${W}`);if(_)K.push(`+${_}`);V=!0}else if(W)K.push(` ${W}`)}return V?K.join(`
|
|
7535
7535
|
`)+`
|
|
7536
|
-
`:""}async function
|
|
7536
|
+
`:""}async function bU($){if($.length===0)throw Error("No files were modified.");let J=[],Z=[],Y=[];for(let K of $)switch(K.type){case"add":let Q=a1.dirname(K.path);if(Q!=="."&&Q!=="/")await l0.mkdir(Q,{recursive:!0});await l0.writeFile(K.path,K.contents,"utf-8"),J.push(K.path),q6.info(`Added file: ${K.path}`);break;case"delete":await l0.unlink(K.path),Y.push(K.path),q6.info(`Deleted file: ${K.path}`);break;case"update":let V=await L3(K.path,K.chunks);if(K.move_path){let X=a1.dirname(K.move_path);if(X!=="."&&X!=="/")await l0.mkdir(X,{recursive:!0});await l0.writeFile(K.move_path,V.content,"utf-8"),await l0.unlink(K.path),Z.push(K.move_path),q6.info(`Moved file: ${K.path} -> ${K.move_path}`)}else await l0.writeFile(K.path,V.content,"utf-8"),Z.push(K.path),q6.info(`Updated file: ${K.path}`);break}return{added:J,modified:Z,deleted:Y}}async function UA($){let{hunks:J}=c8($);return bU(J)}async function BA($,J){if($.length===1)try{return c8($[0]),{type:"CorrectnessError",error:Error("ImplicitInvocation")}}catch{}let Z=EU($);switch(Z.type){case"Body":let{args:Y}=Z,K=Y.workdir?a1.resolve(J,Y.workdir):J,Q=new Map;for(let V of Y.hunks){let X=a1.resolve(K,V.type==="update"&&V.move_path?V.move_path:V.path);switch(V.type){case"add":Q.set(X,{type:"add",content:V.contents});break;case"delete":let W=a1.resolve(K,V.path);try{let j=await l0.readFile(W,"utf-8");Q.set(X,{type:"delete",content:j})}catch{return{type:"CorrectnessError",error:Error(`Failed to read file for deletion: ${W}`)}}break;case"update":let _=a1.resolve(K,V.path);try{let j=await L3(_,V.chunks);Q.set(X,{type:"update",unified_diff:j.unified_diff,move_path:V.move_path?a1.resolve(K,V.move_path):void 0,new_content:j.content})}catch(j){return{type:"CorrectnessError",error:j}}break}}return{type:"Body",action:{changes:Q,patch:Y.patch,cwd:K}};case"PatchParseError":return{type:"CorrectnessError",error:Z.error};case"NotApplyPatch":return{type:"NotApplyPatch"}}}var N3=H$("apply_patch",G.gen(function*(){let $=(yield*e.toolDescriptionEffect("apply_patch"))??"",J=yield*b0.Service,Z=yield*$$.Service,Y=yield*W1.Service,K=yield*P$.Service,Q=G.fn("ApplyPatchTool.execute")(function*(V,X){if(!V.patchText)return yield*G.fail(Error("patchText is required"));let W;try{W=F2.parsePatch(V.patchText).hunks}catch(P){return yield*G.fail(Error(`apply_patch verification failed: ${P}`))}if(W.length===0){if(V.patchText.replace(/\r\n/g,`
|
|
7537
7537
|
`).replace(/\r/g,`
|
|
7538
7538
|
`).trim()===`*** Begin Patch
|
|
7539
|
-
*** End Patch`)return yield*G.fail(Error("patch rejected: empty patch"));return yield*G.fail(Error("apply_patch verification failed: no hunks found"))}let
|
|
7539
|
+
*** End Patch`)return yield*G.fail(Error("patch rejected: empty patch"));return yield*G.fail(Error("apply_patch verification failed: no hunks found"))}let _=[],j="";for(let P of W){let D=o0.resolve(t$.get(X.sessionID),P.path);switch(yield*u2(X,D),P.type){case"add":{let L=_.some((u)=>u.type==="delete"&&u.filePath===D);if(!L&&_.some((u)=>u.type==="add"&&u.filePath===D||u.type==="move"&&u.movePath===D))return yield*G.fail(Error(`apply_patch verification failed: Add File target already staged in this patch: ${D}. Remove the duplicate hunk.`));if(L?void 0:yield*Z.stat(D).pipe(G.catch(()=>G.succeed(void 0))))return yield*G.fail(Error(`apply_patch verification failed: Add File target already exists: ${D}. Use an Update File hunk to modify it, or delete it first if you intend to replace it.`));let x="",b=P.contents.length===0||P.contents.endsWith(`
|
|
7540
7540
|
`)?P.contents:`${P.contents}
|
|
7541
|
-
`,v=d1(R1(D,D,x,b)),m=0,A=0;for(let u of z8(x,b)){if(u.added)m+=u.count||0;if(u.removed)A+=u.count||0}
|
|
7542
|
-
`;break}case"update":{let L=yield*Z.stat(D).pipe(G.catch(()=>G.succeed(void 0)));if(!L||L.type==="Directory")return yield*G.fail(Error(`apply_patch verification failed: Failed to read file to update: ${D}`));let R=yield*Z.readFileString(D),N=R;try{N=F2.deriveNewContentsFromFileContents(R,D,P.chunks).content}catch(A){return yield*G.fail(Error(`apply_patch verification failed: ${A}`))}let x=d1(R1(D,D,R,N)),b=0,v=0;for(let A of z8(R,N)){if(A.added)b+=A.count||0;if(A.removed)v+=A.count||0}let m=P.move_path?o0.resolve(t$.get(X.sessionID),P.move_path):void 0;if(yield*u2(X,m),m&&m!==D){let A=
|
|
7541
|
+
`,v=d1(R1(D,D,x,b)),m=0,A=0;for(let u of z8(x,b)){if(u.added)m+=u.count||0;if(u.removed)A+=u.count||0}_.push({filePath:D,oldContent:x,newContent:b,type:"add",diff:v,additions:m,deletions:A}),j+=v+`
|
|
7542
|
+
`;break}case"update":{let L=yield*Z.stat(D).pipe(G.catch(()=>G.succeed(void 0)));if(!L||L.type==="Directory")return yield*G.fail(Error(`apply_patch verification failed: Failed to read file to update: ${D}`));let R=yield*Z.readFileString(D),N=R;try{N=F2.deriveNewContentsFromFileContents(R,D,P.chunks).content}catch(A){return yield*G.fail(Error(`apply_patch verification failed: ${A}`))}let x=d1(R1(D,D,R,N)),b=0,v=0;for(let A of z8(R,N)){if(A.added)b+=A.count||0;if(A.removed)v+=A.count||0}let m=P.move_path?o0.resolve(t$.get(X.sessionID),P.move_path):void 0;if(yield*u2(X,m),m&&m!==D){let A=_.some((S)=>S.type==="delete"&&S.filePath===m);if(!A&&_.some((S)=>S.type==="add"&&S.filePath===m||S.type==="move"&&S.movePath===m))return yield*G.fail(Error(`apply_patch verification failed: Move destination already staged in this patch: ${m}. Delete it first if you intend to replace it.`));if(A?void 0:yield*Z.stat(m).pipe(G.catch(()=>G.succeed(void 0))))return yield*G.fail(Error(`apply_patch verification failed: Move destination already exists: ${m}. Delete it first if you intend to replace it.`))}_.push({filePath:D,oldContent:R,newContent:N,type:P.move_path?"move":"update",movePath:m,diff:x,additions:b,deletions:v}),j+=x+`
|
|
7543
7543
|
`;break}case"delete":{let L=yield*Z.readFileString(D).pipe(G.catch((x)=>G.fail(Error(`apply_patch verification failed: ${x instanceof Error?x.message:String(x)}`)))),R=d1(R1(D,D,L,"")),N=L.split(`
|
|
7544
|
-
`).length;
|
|
7545
|
-
`;break}}}let _
|
|
7544
|
+
`).length;_.push({filePath:D,oldContent:L,newContent:"",type:"delete",diff:R,additions:0,deletions:N}),j+=R+`
|
|
7545
|
+
`;break}}}let H=_.map((P)=>({filePath:P.filePath,relativePath:o0.relative(B$.worktree,P.movePath??P.filePath).replaceAll("\\","/"),type:P.type,patch:P.diff,additions:P.additions,deletions:P.deletions,movePath:P.movePath})),q=H.length===1?H[0].relativePath:`${H.length} files`,U=_.filter((P)=>!$$.contains(o0.join(f$.Path.data,"memory"),P.movePath??P.filePath));if(U.length>0){let P=U.map((D)=>o0.relative(B$.worktree,D.filePath).replaceAll("\\","/"));yield*X.ask({permission:"edit",patterns:P,always:["*"],metadata:{filepath:P.join(", "),diff:U.map((D)=>D.diff).join(`
|
|
7546
7546
|
`)+`
|
|
7547
|
-
`,files:
|
|
7548
|
-
${
|
|
7549
|
-
`)}`;for(let P of
|
|
7547
|
+
`,files:H.filter((D)=>!$$.contains(o0.join(f$.Path.data,"memory"),D.movePath??D.filePath))}})}let z=[];for(let P of _){let D=P.type==="delete"?void 0:P.movePath??P.filePath;switch(P.type){case"add":yield*Z.writeWithDirs(P.filePath,P.newContent),z.push({file:P.filePath,event:"add"});break;case"update":yield*Z.writeWithDirs(P.filePath,P.newContent),z.push({file:P.filePath,event:"change"});break;case"move":if(P.movePath){let{filePath:L,movePath:R}=P,N=!1;if(P.newContent===P.oldContent)N=yield*G.promise(async()=>{try{return await HA(L,R),!0}catch{return!1}});if(!N)yield*Z.writeWithDirs(R,P.newContent),yield*Z.remove(L).pipe(G.mapError((x)=>Error(`Move partially completed: '${R}' was written but '${L}' could not be removed: ${x}. Remove '${L}' manually to complete the move.`)));z.push({file:L,event:"unlink"}),z.push({file:R,event:"add"})}break;case"delete":yield*Z.remove(P.filePath),z.push({file:P.filePath,event:"unlink"});break}if(D)yield*Y.file(D),yield*K.publish(w2.Event.Edited,{file:D})}for(let P of z)yield*K.publish(k2.Event.Updated,P);for(let P of _){if(P.type==="delete")continue;let D=P.movePath??P.filePath;yield*J.touchFile(D,!0)}let M=yield*J.diagnostics(),C=`Success. Updated the following files:
|
|
7548
|
+
${_.map((P)=>{if(P.type==="add")return`A ${o0.relative(B$.worktree,P.filePath).replaceAll("\\","/")}`;if(P.type==="delete")return`D ${o0.relative(B$.worktree,P.filePath).replaceAll("\\","/")}`;let D=P.movePath??P.filePath;return`M ${o0.relative(B$.worktree,D).replaceAll("\\","/")}`}).join(`
|
|
7549
|
+
`)}`;for(let P of _){if(P.type==="delete")continue;let D=P.movePath??P.filePath,L=b0.Diagnostic.report(D,M[$$.normalizePath(D)]??[]);if(!L)continue;let R=o0.relative(B$.worktree,D).replaceAll("\\","/");C+=`
|
|
7550
7550
|
|
|
7551
7551
|
LSP errors detected in ${R}, please fix:
|
|
7552
|
-
${L}`}return{title:q,metadata:{diff:j,files:
|
|
7553
|
-
`),
|
|
7554
|
-
`),metadata:{commands:
|
|
7555
|
-
`),metadata:{...
|
|
7552
|
+
${L}`}return{title:q,metadata:{diff:j,files:H,diagnostics:M},output:C}});return{description:$,parameters:WG,execute:(V,X)=>Q(V,X).pipe(G.orDie)}}));import z6 from"path";var _A=["Switch the working directory for the current session (like cd in a terminal).","","Use this when the user asks to switch, change, or cd into a directory,","or when you need to work extensively within a subdirectory (e.g., a monorepo package).","","After calling this tool, all subsequent file operations (read, edit, write, glob, grep, bash)","will resolve relative paths from the new directory. Subagents inherit the changed directory.","","Pass an absolute path, or a relative path (resolved from the current working directory).",'Pass "~" to reset back to the project root.'].join(`
|
|
7553
|
+
`),vU=H$("change_directory",G.gen(function*(){let $=yield*$$.Service,J=yield*P$.Service;return{description:_A,parameters:jG,execute:(Z,Y)=>G.gen(function*(){let K=yield*i.context,Q=t$.get(Y.sessionID);if(Z.path==="~"||Z.path==="")return t$.clear(Y.sessionID),yield*J.publish(t$.Event.Changed,{sessionID:Y.sessionID,cwd:K.directory}),{title:"reset",metadata:{from:Q,to:K.directory},output:`Working directory reset to project root: ${K.directory}`};let V=z6.isAbsolute(Z.path)?Z.path:z6.resolve(Q,Z.path),X=z6.normalize(V),W=yield*$.stat(X).pipe(G.catch(()=>G.succeed(void 0)));if(!W)throw Error(`Directory does not exist: ${X}`);if(W.type!=="Directory")throw Error(`Path is not a directory: ${X}`);return yield*_1(Y,X,{kind:"directory"}),t$.set(Y.sessionID,X),yield*J.publish(t$.Event.Changed,{sessionID:Y.sessionID,cwd:X}),{title:z6.relative(K.worktree,X)||".",metadata:{from:Q,to:X},output:`Working directory changed: ${Q} \u2192 ${X}`}})}}));import sU from"path";import{pathToFileURL as PA}from"url";var l8={};o$(l8,{layer:()=>fU,defaultLayer:()=>OA,Todo:()=>l8,Service:()=>C6,Info:()=>hU,Event:()=>gU});var hU=F.object({content:F.string().describe("Brief description of the task"),status:F.string().describe("Current status of the task: pending, in_progress, completed, cancelled")}).meta({ref:"Todo"}),gU={Updated:Z0.define("todo.updated",F.object({sessionID:F0.zod,todos:F.array(hU)}))};class C6 extends D$.Service()("@qitqode/SessionTodo"){}var fU=f.effect(C6,G.gen(function*(){let $=yield*P$.Service,J=G.fn("Todo.update")(function*(Y){yield*G.sync(()=>z$.transaction((K)=>{if(K.delete(JJ).where(G$(JJ.session_id,Y.sessionID)).run(),Y.todos.length===0)return;K.insert(JJ).values(Y.todos.map((Q,V)=>({session_id:Y.sessionID,content:Q.content,status:Q.status,position:V}))).run()})),yield*$.publish(gU.Updated,Y)}),Z=G.fn("Todo.get")(function*(Y){return(yield*G.sync(()=>z$.use((Q)=>Q.select().from(JJ).where(G$(JJ.session_id,Y)).orderBy(m1(JJ.position)).all()))).map((Q)=>({content:Q.content,status:Q.status}))});return C6.of({update:J,get:Z})})),OA=fU.pipe(f.provide(P$.layer));var o8={};o$(o8,{layer:()=>uU,defaultLayer:()=>FA,Team:()=>o8,Service:()=>M6});var mU=Z0.define("team.created",F.object({teamID:F.string(),creatorSessionID:F0.zod})),Hg=Z0.define("team.member.joined",F.object({teamID:F.string(),sessionID:F0.zod,agent:F.string(),role:F.string()}));import*as ZJ from"fs/promises";import y3 from"path";var T3=O$.create({service:"team"});class M6 extends D$.Service()("@qitqode/Team"){}var uU=f.effect(M6,G.gen(function*(){let $=yield*P$.Service,J=(j)=>G.gen(function*(){let H=yield*i.context;return y3.join(H.directory,".qitqode","teams",j)}),Z=(j)=>G.map(J(j),(H)=>y3.join(H,"members.json")),Y=(j)=>G.gen(function*(){let H=yield*Z(j);return yield*G.promise(async()=>{try{let q=await ZJ.readFile(H,"utf-8");return JSON.parse(q)}catch{return[]}})}),K=(j,H)=>G.gen(function*(){let q=yield*Z(j);yield*G.promise(()=>ZJ.writeFile(q,JSON.stringify(H,null,2)))}),Q=G.fn("Team.create")(function*(j,H){let q=yield*J(j);yield*G.promise(()=>ZJ.mkdir(q,{recursive:!0})),yield*G.promise(()=>ZJ.writeFile(y3.join(q,"members.json"),"[]")),T3.info("team created",{teamID:j}),yield*$.publish(mU,{teamID:j,creatorSessionID:H})}),V=G.fn("Team.addMember")(function*(j,H,q,U){let z=yield*Y(j);if(!z.find((I)=>I.sessionID===H))z.push({sessionID:H,agent:q,role:U,joinedAt:Date.now()}),yield*K(j,z),T3.info("team member added",{teamID:j,sessionID:H,agent:q,role:U})}),X=G.fn("Team.removeMember")(function*(j,H){let q=yield*Y(j),U=q.filter((z)=>z.sessionID!==H);if(U.length!==q.length)yield*K(j,U),T3.info("team member removed",{teamID:j,sessionID:H})}),W=G.fn("Team.getMembers")(function*(j){return yield*Y(j)}),_=G.fn("Team.teamDir")(function*(j){return yield*J(j)});return M6.of({create:Q,addMember:V,removeMember:X,getMembers:W,teamDir:_})})),FA=uU.pipe(f.provide(P$.defaultLayer));var dU=F.object({script:F.string().min(1).describe(["Multi-line shell-style script. Each non-blank line is one command; commands run sequentially and stop on first failure.",`Quoting: "..." preserves literal newlines and processes \\" \\\\ escapes; '...' is verbatim.`,"<<EOF heredoc bodies are fully verbatim (no escape, no $vars).","# starts a line comment to end-of-line (quoted # is literal).","Variables ($VAR, ${VAR}) are preserved as literal text \u2014 no expansion.","See the tool description for the verb table."].join(" ")).refine(($)=>$.trim().length>0,{message:"script must not be blank"})});function oU($){if(!$.shell)throw Error(`shellWrap called on tool '${$.id}' that has no shell field`);let J=$.shell;return{id:$.id,description:J.description,parameters:dU,execute:(Z,Y)=>G.gen(function*(){let K=_Z(Z),Q=dU.safeParse(K.value);if(!Q.success){let H=J.recover?.(K.value);if(H!==void 0){let z=pU(H),M=yield*G.exit($.execute(H,Y));if(M._tag==="Failure")return{title:`${$.id}: invalid arguments`,output:D6(lU($.id,cU(M.cause))),metadata:{commands:0,success:0}};return{title:`${$.id}: ${z}`,output:M.value.output,metadata:{...M.value.metadata,commands:1,success:1}}}let U="script"in(typeof K.value==="object"&&K.value?K.value:{})?MA($.id):lU($.id);return{title:`${$.id}: missing script`,output:D6(U),metadata:{commands:0,success:0}}}let V=yield*G.exit(J.parse(Q.data.script));if(V._tag==="Failure"){let H=n0.squash(V.cause),q=DA($.id,H);return{title:`${$.id}: parse error`,output:D6(q),metadata:{commands:0,success:0}}}let X=V.value;if(X.length===0)return{title:`${$.id}: empty script`,output:D6(`${$.id}: no commands found in script`),metadata:{commands:0,success:0}};let W=[],_={},j=0;for(let H=0;H<X.length;H++){let q=X[H],U=pU(q),z=yield*G.exit($.execute(q,Y));if(z._tag==="Failure"){if(W.push(CA(H+1,U,cU(z.cause))),H+1<X.length)W.push(`<not-executed>commands #${H+2}..#${X.length}</not-executed>`);return{title:`${$.id}: command #${H+1} failed`,output:W.join(`
|
|
7554
|
+
`),metadata:{commands:X.length,success:j}}}j++,_=z.value.metadata,W.push(zA(H+1,U,z.value.output))}return{title:`${$.id}: ${X.length} command(s)`,output:W.join(`
|
|
7555
|
+
`),metadata:{..._,commands:X.length,success:j}}})}}function zA($,J,Z){return`<command index="${$}" operation="${rU(J)}">
|
|
7556
7556
|
${Z}
|
|
7557
|
-
</command>`}function
|
|
7557
|
+
</command>`}function CA($,J,Z){return`<command index="${$}" operation="${rU(J)}" failed="true">
|
|
7558
7558
|
${Z}
|
|
7559
|
-
</command>`}function
|
|
7559
|
+
</command>`}function pU($){let J=$?.operation;if(typeof J==="string")return J;if(J&&typeof J==="object"&&typeof J.action==="string")return J.action;return"?"}function rU($){return String($??"").replace(/&/g,"&").replace(/</g,"<").replace(/>/g,">").replace(/"/g,""")}function cU($){let J=n0.squash($);if(J instanceof Error)return J.message;return String(J)}function D6($){return`<command failed="true">
|
|
7560
7560
|
${$}
|
|
7561
|
-
</command>`}function
|
|
7562
|
-
`)}function
|
|
7563
|
-
`)}function
|
|
7561
|
+
</command>`}function MA($){return[`${$}: this tool takes a single \`script\` string (shell-style), not JSON fields.`,`Put the command in \`script\`, e.g.: ${$} <verb> ...`,"See the tool description for the verb list and examples."].join(`
|
|
7562
|
+
`)}function lU($,J){return[`${$}: could not run the call.`,'Pass the operation as JSON, e.g.: {"operation":{"action":"<verb>", ...}}',...J?[`detail: ${J}`]:[]].join(`
|
|
7563
|
+
`)}function DA($,J){if(J&&typeof J==="object"&&"kind"in J){let Z=J,Y=Z.line??"?";return`${$}: parse error at line ${Y}
|
|
7564
7564
|
${Z.detail??Z.kind}`}if(J instanceof Error)return`${$}: parse error
|
|
7565
7565
|
${J.message}`;return`${$}: parse error
|
|
7566
|
-
${String(J)}`}function
|
|
7566
|
+
${String(J)}`}function iU($,J){return $?.invocation_style_by_tool?.[J]??$?.invocation_style??"json"}var tU=O$.create({service:"tool.registry"});async function eU(){let $=await B2.list();if($.length===0)return"";return["","## Built-in workflows",'These named workflows are available via operation "run" with `name`. When a request matches one, invoke it instead of writing a script from scratch:',"",...$.map((Z)=>{let Y=Z.phases?.length?`
|
|
7567
7567
|
Phases: `+Z.phases.map((Q)=>Q.title).join(" \u2192 "):"",K=Z.whenToUse?`
|
|
7568
7568
|
When to use: ${Z.whenToUse}`:"";return`- ${Z.name}: ${Z.description}${K}${Y}`}),"",'Invoke a built-in: workflow({ operation: "run", name: "deep-research", args: "<the refined request>" })'].join(`
|
|
7569
|
-
`)}var
|
|
7570
|
-
`)}),J$=G.fn("ToolRegistry.describeWorkflow")(function*(){return yield*G.promise(()=>
|
|
7569
|
+
`)}var nU=new Set;function IA($){if(nU.has($))return;nU.add($),tU.warn(`tool '${$}' configured with invocation_style='shell' but has no shell field; falling back to JSON`)}class P6 extends D$.Service()("@qitqode/ToolRegistry"){}var $B=f.effect(P6,G.gen(function*(){let $=yield*R$.Service,J=yield*z2.Service,Z=yield*p0.Service,Y=yield*a0.Service,K=yield*Z1,Q=yield*AU,V=yield*o7,X=yield*iG,W=yield*AG,_=yield*LU,j=yield*PG,H=yield*DG,q=yield*IU,U=yield*D3,z=yield*aU,M=yield*P3,I=yield*I3,C=yield*A3,P=yield*S3,D=yield*hG,L=yield*C3,R=yield*T7,N=yield*fG,x=yield*N3,b=yield*vU,v=yield*M3,m=yield*mG,A=yield*uG,u=yield*nX,r=yield*s7,S=yield*p0.Service,T=yield*i.make(G.fn("ToolRegistry.state")(function*(y){let n=[];function a(t,C$){return{id:t,parameters:F.object(C$.args),description:C$.description,execute:(T$,M$)=>G.gen(function*(){let r$={...M$,ask:(M1)=>M$.ask(M1),directory:y.directory,worktree:y.worktree},K0=yield*G.promise(()=>C$.execute(T$,r$)),t1=typeof K0==="string"?K0:K0.output,a8=typeof K0==="string"?{}:K0.metadata??{},e1=yield*S.get(M$.agent),C1=yield*K.output(t1,{},e1);return{title:"",output:C1.truncated?C1.content:t1,metadata:{...a8,truncated:C1.truncated,...C1.truncated&&{outputPath:C1.outputPath}}}})}}let l=(yield*$.directories()).flatMap((t)=>y2.scanSync("{tool,tools}/*.{js,ts}",{cwd:t,absolute:!0,dot:!0,symlink:!0}));if(l.length)yield*$.waitForDependencies();for(let t of l){let C$=sU.basename(t,sU.extname(t)),T$=yield*G.promise(()=>import(`${PA(t).href}?v=${Date.now()}`));for(let[M$,r$]of Object.entries(T$))n.push(a(M$==="default"?C$:`${C$}_${M$}`,r$))}let d=yield*J.list();for(let t of d)for(let[C$,T$]of Object.entries(t.tool??{}))n.push(a(C$,T$));yield*$.get();let Y$=["app","cli","desktop"].includes(k$.QITQODE_CLIENT)||k$.QITQODE_ENABLE_QUESTION_TOOL,g=yield*G.all({invalid:n$(Q),bash:n$(z),read:n$(X),glob:n$(D),grep:n$(N),edit:n$(R),write:n$(L),actor:n$(V),fetch:n$(q),search:n$(U),code:n$(M),analyzecode:n$(I),generatedocs:n$(C),addinlinecomments:n$(P),skill:n$(v),patch:n$(x),changedir:n$(b),question:n$(W),lsp:n$(_),planexit:n$(j),planenter:n$(H),memory:n$(A),history:n$(m),task:n$(u),workflow:n$(r)});return{custom:n,builtin:[g.invalid,...Y$?[g.question]:[],g.bash,g.read,g.glob,g.grep,g.edit,g.write,g.actor,g.fetch,g.search,g.code,g.analyzecode,g.generatedocs,g.addinlinecomments,g.skill,g.patch,g.changedir,...k$.QITQODE_EXPERIMENTAL_LSP_TOOL?[g.lsp]:[],g.planexit,g.planenter,g.memory,g.history,g.task,...k$.QITQODE_EXPERIMENTAL_WORKFLOW_TOOL?[g.workflow]:[]],actor:g.actor,read:g.read}})),k=G.fn("ToolRegistry.all")(function*(){let y=yield*i.get(T),n=new Set(y.custom.map((c$)=>c$.id));return[...y.builtin.filter((c$)=>!n.has(c$.id)),...y.custom]}),A$=G.fn("ToolRegistry.ids")(function*(){return(yield*k()).map((y)=>y.id)}),s=G.fn("ToolRegistry.describeSkill")(function*(y){let n=yield*Y.available(y);if(n.length===0)return"No skills are currently available.";return["Load a specialized skill that provides domain-specific instructions and workflows.","","When you recognize that a task matches one of the available skills listed below, use this tool to load the full skill instructions.","","The skill will inject detailed instructions, workflows, and access to bundled resources (scripts, references, templates) into the conversation context.","",'Tool output includes a `<skill_content name="...">` block with the loaded content.',"","The following skills provide specialized sets of instructions for particular tasks","Invoke this tool to load a skill when a task matches one of the available skills listed below:","",a0.fmt(n,{verbose:!1})].join(`
|
|
7570
|
+
`)}),J$=G.fn("ToolRegistry.describeWorkflow")(function*(){return yield*G.promise(()=>eU())}),Z$=G.fn("ToolRegistry.describeTask")(function*(y){return["Available agent types and the tools they have access to:",(yield*Z.list()).filter((d)=>d.mode!=="primary"&&!d.hidden).filter((d)=>E$.evaluate("task",d.name,y.permission).action!=="deny").toSorted((d,Y$)=>d.name.localeCompare(Y$.name)).map((d)=>`- ${d.name}: ${d.description??"This subagent should only be called manually by the user."}`).join(`
|
|
7571
7571
|
`)].join(`
|
|
7572
|
-
`)}),W$=G.fn("ToolRegistry.tools")(function*(y){let n=(yield*k()).filter((l)=>{if(l.id===
|
|
7573
|
-
`),parameters:t?C$.parameters:Y$.parameters,execute:C$.execute,formatValidationError:C$.formatValidationError}}catch(r$){var K0=r$,t1=1}finally{
|
|
7572
|
+
`)}),W$=G.fn("ToolRegistry.tools")(function*(y){let n=(yield*k()).filter((l)=>{if(l.id===P3.id||l.id===D3.id)return y.providerID==="qlex"||y.providerID===I6.opencode||k$.QITQODE_ENABLE_EXA;if(l.id===I3.id||l.id===A3.id||l.id===S3.id)return y.providerID==="qlex";let d=y.modelID.includes("gpt-")&&!y.modelID.includes("oss")&&!y.modelID.includes("gpt-4");if(l.id===N3.id)return d;if(l.id===T7.id||l.id===C3.id)return!d;return!0});if(y.agent.toolAllowlist){let l=new Set(y.agent.toolAllowlist);n=n.filter((d)=>d.id==="invalid"||l.has(d.id))}let a=yield*$.get(),c$=(l)=>iU(a.tool,l);return yield*G.forEach(n,G.fnUntraced(function*(l){let M$=[];try{const d=w9(M$,tU.time(l.id),0);let Y$={description:l.description,parameters:l.parameters};yield*J.trigger("tool.definition",{toolID:l.id},Y$);let g=c$(l.id);let t=g==="shell"&&l.shell!==void 0;if(g==="shell"&&!l.shell)IA(l.id);let C$=t?oU(l):l;let T$=t?l.shell.description:Y$.description;return{id:l.id,description:[T$,l.id===o7.id?yield*Z$(y.agent):void 0,l.id===M3.id?yield*s(y.agent):void 0,l.id===s7.id?yield*J$():void 0].filter(Boolean).join(`
|
|
7573
|
+
`),parameters:t?C$.parameters:Y$.parameters,execute:C$.execute,formatValidationError:C$.formatValidationError}}catch(r$){var K0=r$,t1=1}finally{R9(M$,K0,t1)}}),{concurrency:25})}),y$=G.fn("ToolRegistry.named")(function*(){let y=yield*i.get(T);return{actor:y.actor,read:y.read}}),Q$=G.fn("ToolRegistry.reload")(function*(){yield*Y.reload(),yield*J.reloadFileHooks(),yield*i.invalidate(T)});return P6.of({ids:A$,all:k,named:y$,tools:W$,reload:Q$})})),AA=f.suspend(()=>$B.pipe(f.provide(R$.defaultLayer),f.provide(z2.defaultLayer),f.provide(B1.defaultLayer),f.provide(l8.defaultLayer),f.provide(a0.defaultLayer),f.provide(p0.defaultLayer),f.provide(Y1.defaultLayer),f.provide(H1.defaultLayer),f.provide(b0.defaultLayer),f.provide(d2.defaultLayer),f.provide($$.defaultLayer),f.provide(P$.layer),f.provide(X2.layer),f.provide(W1.defaultLayer),f.provide(XJ),f.provide(h0.defaultLayer),f.provide(I7),f.provide(f.mergeAll(L1.defaultLayer,c2.defaultLayer)),f.provide(o8.defaultLayer),f.provide(f.mergeAll(g1.defaultLayer,MJ.defaultLayer,o2.defaultLayer,K1.defaultLayer,r8.defaultLayer))));import C2 from"path";function YJ($){return $.pipe(G.catchDefect((J)=>J instanceof e.BackendAuthRejectedError?G.succeed(void 0):G.die(J)))}var SA=F.object({name:F.string(),description:F.string().optional(),mode:F.enum(["subagent","primary","all"]),native:F.boolean().optional(),hidden:F.boolean().optional(),topP:F.number().optional(),temperature:F.number().optional(),color:F.union([F.string(),F.object({light:F.string(),dark:F.string()})]).optional(),permission:E$.Ruleset.zod,model:F.object({modelID:GB.zod,providerID:I6.zod}).optional(),modelRef:F.string().optional(),variant:F.string().optional(),prompt:F.string().optional(),options:F.record(F.string(),F.any()),steps:F.number().int().positive().optional(),toolAllowlist:F.array(F.string()).optional(),posture:jB.optional()}).meta({ref:"Agent"});class A6 extends D$.Service()("@qitqode/Agent"){}var BB=f.effect(A6,G.gen(function*(){let $=yield*R$.Service,J=yield*r8.Service,Z=yield*z2.Service,Y=yield*a0.Service,K=yield*H1.Service,Q=yield*i.make(G.fn("Agent.state")(function*(V){let X=yield*G.all([YJ(G.promise(()=>e.resolveAgentPrompt("explore"))),YJ(G.promise(()=>e.resolveAgentPrompt("title"))),YJ(G.promise(()=>e.resolveAgentPrompt("summary"))),YJ(G.promise(()=>e.resolveAgentPrompt("compaction"))),YJ(G.promise(()=>e.resolveAgentPrompt("dream"))),YJ(G.promise(()=>e.resolveAgentPrompt("distill")))],{concurrency:"unbounded"}),W=X[0]??"",_=X[1]??"",j=X[2]??"",H=X[3]??"",q=X[4]??"",U=X[5]??"",z=yield*$.get(),M=yield*Y.dirs(),I=[j1.GLOB,...M.map((v)=>C2.join(v,"*"))],C=E$.fromConfig({"*":"allow",doom_loop:"ask",external_directory:{"*":"ask",...Object.fromEntries(I.map((v)=>[v,"allow"]))},question:"deny",read:{"*":"allow","*.env":"ask","*.env.*":"ask","*.env.example":"allow"}}),P=E$.fromConfig(z.permission??{}),D=E$.merge(C,E$.fromConfig({"*":"deny",read:"allow",write:"allow",edit:"allow",glob:"allow",grep:"allow",memory:"allow",bash:"allow",external_directory:{[C2.join(f$.Path.data,"memory")]:"allow",[C2.join(f$.Path.data,"memory","*")]:"allow"}}),P),L=["read","write","edit","glob","grep","memory","bash"],R={build:{name:"build",color:{dark:"#ff6a00",light:"#b84a00"},description:"Executes tools based on configured permissions.",options:{},permission:E$.merge(C,E$.fromConfig({question:"allow"}),P),mode:"primary",native:!0},...z.experimental?.maxMode?{max:{name:"max",color:{dark:"#ff8a00",light:"#c2410c"},description:"Max mode (experimental). Runs N parallel reasoning candidates each step and executes the best one. Same permissions as build.",options:{},permission:E$.merge(C,E$.fromConfig({question:"allow"}),P),mode:"primary",native:!0}}:{},plan:{name:"plan",color:{dark:"#1cc7bb",light:"#0f766e"},description:"Plan mode. Disallows all edit tools.",options:{},permission:E$.merge(C,E$.fromConfig({question:"allow",external_directory:{[C2.join(f$.Path.data,"plans","*")]:"allow"},edit:{"*":"deny",[C2.join(".qitqode","plans","*.md")]:"allow",[C2.relative(B$.worktree,C2.join(f$.Path.data,C2.join("plans","*.md")))]:"allow"}}),P),mode:"primary",native:!0},compose:{name:"compose",color:{dark:"#a84462",light:"#6d213c"},description:"Compose mode. Orchestrates workflows with built-in compose skills.",options:{},permission:E$.merge(C,E$.fromConfig({question:"allow"}),P),mode:"primary",native:!0},general:{name:"general",color:{dark:"#8a8f98",light:"#6f747d"},description:"General-purpose agent for researching complex questions and executing multi-step tasks. Use this agent to execute multiple units of work in parallel.",permission:E$.merge(C,E$.fromConfig({change_directory:"deny"}),P),options:{},mode:"subagent",native:!0},explore:{name:"explore",color:{dark:"#ffb000",light:"#b45309"},permission:E$.merge(C,E$.fromConfig({"*":"deny",grep:"allow",glob:"allow",list:"allow",bash:"allow",webfetch:"allow",websearch:"allow",codesearch:"allow",read:"allow",external_directory:{"*":"ask",...Object.fromEntries(I.map((v)=>[v,"allow"]))}}),P),description:'Fast agent specialized for exploring codebases. Use this when you need to quickly find files by patterns (eg. "src/components/**/*.tsx"), search code for keywords (eg. "API endpoints"), or answer questions about the codebase (eg. "how do API endpoints work?"). When calling this agent, specify the desired thoroughness level: "quick" for basic searches, "medium" for moderate exploration, or "very thorough" for comprehensive analysis across multiple locations and naming conventions.',prompt:W,options:{},mode:"subagent",native:!0},title:{name:"title",mode:"subagent",options:{},native:!0,hidden:!0,temperature:0.5,permission:E$.merge(C,E$.fromConfig({"*":"deny"}),P),prompt:_,toolAllowlist:[]},summary:{name:"summary",mode:"subagent",options:{},native:!0,hidden:!0,permission:E$.merge(C,E$.fromConfig({"*":"deny"}),P),prompt:j,toolAllowlist:[]},compaction:{name:"compaction",mode:"subagent",options:{},native:!0,hidden:!0,permission:E$.merge(C,E$.fromConfig({"*":"deny"}),P),prompt:H,toolAllowlist:[]},"checkpoint-writer":{name:"checkpoint-writer",mode:"subagent",options:{},native:!0,hidden:!0,permission:E$.merge(C,P)},dream:{name:"dream",mode:"subagent",options:{},native:!0,hidden:!0,prompt:q,permission:D,toolAllowlist:L},distill:{name:"distill",mode:"subagent",options:{},native:!0,hidden:!0,prompt:U,permission:D,toolAllowlist:L}};for(let[v,m]of Object.entries(z.agent??{})){if(m.disable){delete R[v];continue}let A=R[v];if(!A)A=R[v]={name:v,mode:"all",permission:E$.merge(C,P),options:{},native:!1};if(m.model)if(m.model.includes("/"))A.model=H1.parseModel(m.model);else A.modelRef=m.model;A.variant=m.variant??A.variant,A.prompt=m.prompt??A.prompt,A.description=m.description??A.description,A.temperature=m.temperature??A.temperature,A.topP=m.top_p??A.topP,A.mode=m.mode??A.mode,A.color=m.color??A.color,A.hidden=m.hidden??A.hidden,A.name=m.name??A.name,A.steps=m.steps??A.steps,A.toolAllowlist=m.tool_allowlist??A.toolAllowlist,A.options=F9(A.options,m.options??{}),A.permission=E$.merge(A.permission,E$.fromConfig(m.permission??{}))}for(let v of Object.values(R))v.posture=UB(v);for(let v in R){if(R[v].permission.some((u)=>{if(u.permission!=="external_directory")return!1;if(u.action!=="deny")return!1;return u.pattern===j1.GLOB}))continue;R[v].permission=E$.merge(R[v].permission,E$.fromConfig({external_directory:{[j1.GLOB]:"allow"}}))}let N=G.fnUntraced(function*(v){return R[v]}),x=G.fnUntraced(function*(){let v=yield*$.get();return YB(R,KB(),QB([(m)=>v.default_agent!==void 0&&m.name===v.default_agent,"desc"],[(m)=>m.name==="plan","desc"],[(m)=>m.name==="build","desc"],[(m)=>m.name==="compose","desc"],[(m)=>m.name==="max","desc"],[(m)=>m.name,"asc"]))}),b=G.fnUntraced(function*(){let v=yield*$.get();if(v.default_agent){let u=R[v.default_agent];if(!u)throw Error(`default agent "${v.default_agent}" not found`);if(u.mode==="subagent")throw Error(`default agent "${v.default_agent}" is a subagent`);if(u.hidden===!0)throw Error(`default agent "${v.default_agent}" is hidden`);return u.name}let m=R.plan;if(m&&m.mode!=="subagent"&&m.hidden!==!0)return m.name;let A=Object.values(R).find((u)=>u.mode!=="subagent"&&u.hidden!==!0);if(!A)throw Error("no primary visible agent found");return A.name});return{get:N,list:x,defaultAgent:b}}));return A6.of({get:G.fn("Agent.get")(function*(V){return yield*i.useEffect(Q,(X)=>X.get(V))}),list:G.fn("Agent.list")(function*(){return yield*i.useEffect(Q,(V)=>V.list())}),defaultAgent:G.fn("Agent.defaultAgent")(function*(){return yield*i.useEffect(Q,(V)=>V.defaultAgent())}),generate:G.fn("Agent.generate")(function*(V){let X=yield*$.get(),W=V.model??(yield*K.defaultModel()),_=yield*K.getModel(W.providerID,W.modelID),j=yield*K.getLanguage(_),H=X.experimental?.openTelemetry?ZB(yield*G.serviceOption(VB)):void 0,q=[(yield*YJ(G.promise(()=>e.resolveAgentPrompt("generate"))))??""];yield*Z.trigger("experimental.chat.system.transform",{model:_},{system:q});let U=yield*i.useEffect(Q,(C)=>C.list()),z=yield*J.get(W.providerID).pipe(G.orDie),M=W.providerID==="openai"&&z?.type==="oauth",I={experimental_telemetry:{isEnabled:X.experimental?.openTelemetry,tracer:H,metadata:{userId:X.username??"unknown"}},temperature:0.3,messages:[...M?[]:q.map((C)=>({role:"system",content:C})),{role:"user",content:`Create an agent configuration based on this request:
|
|
7574
7574
|
|
|
7575
7575
|
> ${V.description.replace(/\n/g,`
|
|
7576
7576
|
> `)}
|
|
7577
7577
|
|
|
7578
|
-
IMPORTANT: The following identifiers already exist and must NOT be used: ${
|
|
7579
|
-
Return ONLY the JSON object, no other text, do not wrap in backticks`}],model:j,schema:F.object({identifier:F.string(),whenToUse:F.string(),systemPrompt:F.string()})};if(M)return yield*G.promise(async()=>{let
|
|
7580
|
-
`),store:!1}),onError:()=>{}});for await(let P of
|
|
7578
|
+
IMPORTANT: The following identifiers already exist and must NOT be used: ${U.map((C)=>C.name).join(", ")}
|
|
7579
|
+
Return ONLY the JSON object, no other text, do not wrap in backticks`}],model:j,schema:F.object({identifier:F.string(),whenToUse:F.string(),systemPrompt:F.string()})};if(M)return yield*G.promise(async()=>{let C=WB({...I,providerOptions:HB.providerOptions(_,{instructions:q.join(`
|
|
7580
|
+
`),store:!1}),onError:()=>{}});for await(let P of C.fullStream)if(P.type==="error")throw P.error;return C.object});return yield*G.promise(()=>XB(I).then((C)=>C.object))})})})),wA=BB.pipe(f.provide(z2.defaultLayer),f.provide(H1.defaultLayer),f.provide(r8.defaultLayer),f.provide(R$.defaultLayer),f.provide(a0.defaultLayer));var _B=O$.create({service:"tool-executor"});function RA($,J){if(J instanceof F.ZodError)return`Invalid arguments for the ${$} tool:
|
|
7581
7581
|
${F.prettifyError(J)}`;return`The ${$} tool was called with invalid arguments: ${J}.
|
|
7582
|
-
Please rewrite the input so it satisfies the expected schema.`}function
|
|
7582
|
+
Please rewrite the input so it satisfies the expected schema.`}var LA=4;function i8($,J=0){if(J>LA)return{};if(!$||typeof $!=="object")return{};let Z=$;if(Z.const!==void 0)return Z.const;if(Array.isArray(Z.enum)&&Z.enum.length>0)return Z.enum[0];for(let K of["anyOf","oneOf","allOf"]){let Q=Z[K];if(Array.isArray(Q)&&Q.length>0)return i8(Q[0],J)}switch(Array.isArray(Z.type)?Z.type[0]:Z.type){case"object":{let K=Z.properties??{},Q=Array.isArray(Z.required)?Z.required:[],V=Q.length>0?Q:Object.keys(K).slice(0,3),X={};for(let W of V)X[W]=W in K?i8(K[W],J+1):null;return X}case"array":return Z.items?[i8(Z.items,J+1)]:[];case"string":return"...";case"number":case"integer":return 0;case"boolean":return!1;case"null":return null;default:return Z.properties?i8({...Z,type:"object"},J):{}}}function NA($,J,Z){if(!Z.issues.some((Q)=>Q.code==="invalid_type"&&Q.path.length===0&&Q.expected==="object"))return;let K="";try{K=`
|
|
7583
|
+
A well-formed call looks like: ${JSON.stringify(i8(F.toJSONSchema(J)))}`}catch{K=""}return[`Invalid arguments for the ${$} tool: the arguments arrived as a JSON string, but this tool expects a JSON object.`,`Do not stringify the arguments \u2014 send the object itself.${K}`].join(`
|
|
7584
|
+
`)}function yA($,J,Z,Y){return()=>G.gen(function*(){let K=typeof J==="function"?{...yield*J()}:{...J},Q=K.execute;return K.execute=(V,X)=>{let W={"tool.name":$,"session.id":X.sessionID,"message.id":X.messageID,...X.callID?{"tool.call_id":X.callID}:{}};return _B.info("tool call started",{...W}),G.gen(function*(){let _=_Z(V);if(typeof V==="string")_B.debug("tool arguments arrived as a string",{...W,raw:CG(V),recovered:_.decoded,decodeAttempts:_.attempts});let j=_.value;yield*G.try({try:()=>K.parameters.parse(j),catch:(z)=>{if(z instanceof F.ZodError){let M=NA($,K.parameters,z);if(M)return new w0(M,{cause:z});if(K.formatValidationError)return new w0(K.formatValidationError(z),{cause:z})}return new w0(RA($,z),{cause:z})}});let H=yield*K.timeout?Q(j,X).pipe(G.timeoutOrElse({duration:h2.millis(K.timeout),orElse:()=>G.die(new w0(`The ${$} tool timed out after ${K.timeout} ms. If this operation is expected to take longer, retry with a larger timeout value.`))})):Q(j,X);if(H.metadata.truncated!==void 0)return H;let q=yield*Y.get(X.agent),U=yield*Z.output(H.output,{},q);return{...H,output:U.content,metadata:{...H.metadata,truncated:U.truncated,...U.truncated&&{outputPath:U.outputPath}}}}).pipe(G.orDie,G.withSpan("Tool.execute",{attributes:W}))},K})}function H$($,J){return Object.assign(G.gen(function*(){let Z=yield*J,Y=yield*Z1,K=yield*p0.Service;return{id:$,init:yA($,Z,Y,K)}}),{id:$})}function n$($){return G.gen(function*(){return{...yield*$.init(),id:$.id}})}import QJ from"path";import{fileURLToPath as CB}from"url";var KJ={};o$(KJ,{preferred:()=>uA,posix:()=>mA,name:()=>s8,login:()=>fA,killTree:()=>bA,gitbash:()=>k3,acceptable:()=>dA,Shell:()=>KJ});import S6 from"path";import{spawn as TA}from"child_process";import{setTimeout as OB}from"timers/promises";var qB=200,kA=new Set(["fish","nu"]),EA=new Set(["bash","dash","fish","ksh","sh","zsh"]),xA=new Set(["bash","dash","ksh","sh","zsh"]);async function bA($,J){let Z=$.pid;if(!Z||J?.exited?.())return;if(process.platform==="win32"){await new Promise((Y)=>{let K=TA("taskkill",["/pid",String(Z),"/f","/t"],{stdio:"ignore",windowsHide:!0});K.once("exit",()=>Y()),K.once("error",()=>Y())});return}try{if(process.kill(-Z,"SIGTERM"),await OB(qB),!J?.exited?.())process.kill(-Z,"SIGKILL")}catch(Y){if($.kill("SIGTERM"),await OB(qB),!J?.exited?.())$.kill("SIGKILL")}}function vA($){if(process.platform!=="win32")return $;let J=O0.windowsPath($);if(S6.win32.dirname(J)!=="."){if(J.startsWith("/")&&s8(J)==="bash")return k3()||J;return J}return x$(J)||J}function hA(){let $=x$("pwsh.exe");if($)return $;let J=x$("powershell.exe");if(J)return J}function FB($,J){if($&&(!J?.acceptable||!kA.has(s8($))))return vA($);if(process.platform==="win32"){let Z=hA();if(Z)return Z}return gA()}function k3(){if(process.platform!=="win32")return;if(k$.QITQODE_GIT_BASH_PATH)return k$.QITQODE_GIT_BASH_PATH;let $=x$("git");if(!$)return;let J=S6.join($,"..","..","bin","bash.exe");if(O0.stat(J)?.size)return J}function gA(){if(process.platform==="win32"){let J=k3();if(J)return J;return process.env.COMSPEC||"cmd.exe"}if(process.platform==="darwin")return"/bin/zsh";let $=x$("bash");if($)return $;return"/bin/sh"}function s8($){if(process.platform==="win32")return S6.win32.parse(O0.windowsPath($)).name.toLowerCase();return S6.basename($).toLowerCase()}function fA($){return EA.has(s8($))}function mA($){return xA.has(s8($))}var uA=T2(()=>FB(process.env.SHELL)),dA=T2(()=>FB(process.env.SHELL,{acceptable:!0}));var n8={};o$(n8,{prefixWith:()=>pA,BashArity:()=>n8});function pA($,J){return zB.bashPrefixWith($,J)}var MB=30000,rA=k$.QITQODE_EXPERIMENTAL_BASH_DEFAULT_TIMEOUT_MS||120000,wB=new Set(["powershell","pwsh"]),RB=new Set(["cd","push-location","set-location"]),iA=new Set([...RB,"rm","cp","mv","mkdir","touch","chmod","chown","cat","get-content","set-content","add-content","copy-item","move-item","remove-item","new-item","rename-item"]),sA=new Set(["-destination","-literalpath","-path"]),nA=new Set(["-confirm","-debug","-force","-nonewline","-recurse","-verbose","-whatif"]),v3=O$.create({service:"bash-tool"}),E3=($)=>{if($.startsWith("file://"))return CB($);if($.startsWith("/")||/^[a-z]:/i.test($))return $;let J=new URL($,import.meta.url);return CB(J)};function aA($){let J=[];for(let Z=0;Z<$.childCount;Z++){let Y=$.child(Z);if(!Y)continue;if(Y.type==="command_elements"){for(let K=0;K<Y.childCount;K++){let Q=Y.child(K);if(!Q||Q.type==="command_argument_sep"||Q.type==="redirection")continue;J.push({type:Q.type,text:Q.text})}continue}if(Y.type!=="command_name"&&Y.type!=="command_name_expr"&&Y.type!=="word"&&Y.type!=="string"&&Y.type!=="raw_string"&&Y.type!=="concatenation")continue;J.push({type:Y.type,text:Y.text})}return J}function tA($){return($.parent?.type==="redirected_statement"?$.parent.text:$.text).trim()}function eA($){return $.descendantsOfType("command").filter((J)=>Boolean(J))}function LB($){if($.length<2)return $;let J=$[0],Z=$[$.length-1];if((J==='"'||J==="'")&&J===Z)return $.slice(1,-1);return $}function NB($){if($==="~")return b3.homedir();if($.startsWith("~/")||$.startsWith("~\\"))return QJ.join(b3.homedir(),$.slice(2));return $}function DB($){if(process.platform!=="win32")return process.env[$];let J=Object.keys(process.env).find((Z)=>Z.toLowerCase()===$.toLowerCase());return J?process.env[J]:void 0}function $S($,J,Z){let Y=$.toUpperCase();if(Y==="HOME")return b3.homedir();if(Y==="PWD")return J;if(Y==="PSHOME")return QJ.dirname(Z)}function JS($,J,Z){let Y=LB($).replace(/\$\{env:([^}]+)\}/gi,(K,Q)=>DB(Q)||"").replace(/\$env:([A-Za-z_][A-Za-z0-9_]*)/gi,(K,Q)=>DB(Q)||"").replace(/\$(HOME|PWD|PSHOME)(?=$|[\\/])/gi,(K,Q)=>$S(Q,J,Z)||"");return NB(Y)}function ZS($){let J=$.match(/^([A-Za-z]+)::(.*)$/);if(J){if(J[1].toLowerCase()!=="filesystem")return;return J[2]}let Z=$.match(/^([A-Za-z]+):(.*)$/);if(!Z)return $;if(Z[1].length===1)return $;return}function YS($,J){if($.startsWith("(")||$.startsWith("@("))return!0;if($.includes("$(")||$.includes("${")||$.includes("`"))return!0;if(J)return/\$(?!env:)/i.test($);return $.includes("$")}function KS($){let J=/[?*[]/.exec($);if(!J)return $;if(J.index===0)return;return $.slice(0,J.index)}function QS($,J){if(!J)return $.slice(1).filter((K)=>!K.text.startsWith("-")&&!($[0]?.text==="chmod"&&K.text.startsWith("+"))).map((K)=>K.text);let Z=[],Y=!1;for(let K of $.slice(1)){if(Y){Z.push(K.text),Y=!1;continue}if(K.type==="command_parameter"){let Q=K.text.toLowerCase();if(nA.has(Q))continue;Y=sA.has(Q);continue}Z.push(K.text)}return Z}function PB($){if($.length<=MB)return $;return`...
|
|
7583
7585
|
|
|
7584
|
-
`+$.slice(-
|
|
7586
|
+
`+$.slice(-MB)}var VS=/error|exception|failed|fatal|traceback|panic|exit code/i,IB=Math.floor(u1*0.7),AB=Math.floor(DJ*0.7),GS=G.fn("BashTool.parse")(function*($,J){let Z=yield*G.promise(()=>jS().then((Y)=>(J?Y.ps:Y.bash).parse($)).catch((Y)=>{return v3.warn("tree-sitter parse of command failed",{error:String(Y)}),null}));if(!Z)throw Error("Failed to parse command");return Z.rootNode}),XS=G.fn("BashTool.ask")(function*($,J){if(J.dirs.size>0){let Z=Array.from(J.dirs).map((Y)=>{if(process.platform==="win32")return $$.normalizePathPattern(QJ.join(Y,"*"));return QJ.join(Y,"*")});yield*$.ask({permission:"external_directory",patterns:Z,always:Z,metadata:{}})}if(J.patterns.size===0)return;yield*$.ask({permission:"bash",patterns:Array.from(J.patterns),always:Array.from(J.always),metadata:{}})});function WS($,J,Z,Y,K){if(process.platform==="win32"&&wB.has(J))return S1.make($,["-NoLogo","-NoProfile","-NonInteractive","-Command",Z],{cwd:Y,env:K,stdin:"ignore",detached:!1});return S1.make(Z,[],{shell:$,cwd:Y,env:K,stdin:"ignore",detached:process.platform!=="win32"})}var jS=T2(async()=>{let{Parser:$}=await import("./chunk-fwr2qgqb.js"),{default:J}=await import("./chunk-g204pt98.js",{with:{type:"wasm"}}),Z=E3(J);await $.init({locateFile(){return Z}});let{default:Y}=await import("./chunk-r78kfhvz.js",{with:{type:"wasm"}}),{default:K}=await import("./chunk-m31d2n6h.js",{with:{type:"wasm"}}),Q=E3(Y),V=E3(K),[X,W]=await Promise.all([x3.load(Q),x3.load(V)]),_=new $;_.setLanguage(X);let j=new $;return j.setLanguage(W),{bash:_,ps:j}}),aU=H$("bash",G.gen(function*(){let $=(yield*e.toolDescriptionEffect("bash"))??"",J=yield*M9,Z=yield*$$.Service,Y=yield*Z1,K=yield*z2.Service,Q=G.fn("BashTool.cygpath")(function*(H,q){let z=(yield*J.lines(S1.make(H,["-lc",'cygpath -w -- "$1"',"_",q])).pipe(G.catch(()=>G.succeed([]))))[0]?.trim();if(!z)return;return $$.normalizePath(z)}),V=G.fn("BashTool.resolvePath")(function*(H,q,U){if(process.platform==="win32"){if(KJ.posix(U)&&H.startsWith("/")&&$$.windowsPath(H)===H){let z=yield*Q(U,H);if(z)return z}return $$.normalizePath(QJ.resolve(q,$$.windowsPath(H)))}return QJ.resolve(q,H)}),X=G.fn("BashTool.argPath")(function*(H,q,U,z){let M=U?JS(H,q,z):NB(LB(H)),I=M&&KS(M);if(!I||YS(I,U))return;let C=U?ZS(I):I;if(!C)return;return yield*V(C,q,z)}),W=G.fn("BashTool.collect")(function*(H,q,U,z){let M={dirs:new Set,patterns:new Set,always:new Set},I=yield*G.promise(()=>e.resolveBashArity());for(let C of eA(H)){let P=aA(C),D=P.map((R)=>R.text),L=U?D[0]?.toLowerCase():D[0];if(L&&iA.has(L))for(let R of QS(P,U)){let N=yield*X(R,q,U,z);if(v3.info("resolved path",{arg:R,resolved:N}),!N||B$.containsPath(N))continue;let x=(yield*Z.isDir(N))?N:QJ.dirname(N);M.dirs.add(x)}if(D.length&&(!L||!RB.has(L)))M.patterns.add(tA(C)),M.always.add(n8.prefixWith(I,D).join(" ")+" *")}return M}),_=G.fn("BashTool.shellEnv")(function*(H,q){let U=yield*K.trigger("shell.env",{cwd:q,sessionID:H.sessionID,callID:H.callID},{env:{}});return{...SB(),...U.env}}),j=G.fn("BashTool.run")(function*(H,q){let U=u1,z=DJ,M=U*2,I="",C="",P=[],D=0,L="",R,N=!1,x=!1,b=!1;yield*q.metadata({metadata:{output:"",description:H.description}});let v=yield*G.scoped(G.gen(function*(){let S=yield*J.spawn(WS(H.shell,H.name,H.command,H.cwd,H.env));yield*G.forkScoped(l$.runForEach(l$.decodeText(S.all),(s)=>{let J$=Buffer.byteLength(s,"utf-8");P.push({text:s,size:J$}),D+=J$;while(D>M&&P.length>1){let Z$=P.shift();if(!Z$)break;D-=Z$.size,N=!0}if(C=PB(C+s),L)R?.write(s);else if(I+=s,Buffer.byteLength(I,"utf-8")>U)return Y.write(I).pipe(G.andThen((Z$)=>G.sync(()=>{L=Z$,N=!0,R=cA(Z$,{flags:"a"}),I=""})),G.andThen(q.metadata({metadata:{output:C,description:H.description}})));return q.metadata({metadata:{output:C,description:H.description}})}));let T=G.callback((s)=>{if(q.abort.aborted)return s(G.void);let J$=()=>s(G.void);if(q.abort.addEventListener("abort",J$,{once:!0}),q.abort.aborted)J$();return G.sync(()=>q.abort.removeEventListener("abort",J$))}),k=G.sleep(`${H.timeout+100} millis`),A$=yield*G.raceAll([S.exitCode.pipe(G.map((s)=>({kind:"exit",code:s}))),T.pipe(G.map(()=>({kind:"abort",code:null}))),k.pipe(G.map(()=>({kind:"timeout",code:null})))]);if(A$.kind==="abort")b=!0,yield*S.kill({forceKillAfter:"3 seconds"}).pipe(G.orDie);if(A$.kind==="timeout")x=!0,yield*S.kill({forceKillAfter:"3 seconds"}).pipe(G.orDie);return A$.kind==="exit"?A$.code:null})).pipe(G.orDie),m=[];if(x)m.push(`bash tool terminated command after exceeding timeout ${H.timeout} ms. If this command is expected to take longer and is not waiting for interactive input, retry with a larger timeout value in milliseconds.`);if(b)m.push("User aborted the command");let A=P.map((S)=>S.text).join(""),u=P7(A,z,U);if(u.cut)N=!0;if(!L&&u.cut)L=yield*Y.write(A);let r=u.text;if(!r)r="(no output)";if(N&&L){let S=u.text.length>2048?u.text.slice(-2048):u.text;if(VS.test(S)){let k=yield*G.promise(async()=>{try{let A$=await oA(L),s=IB*2,J$=await lA(L,"r");try{let Z$=Math.min(Number(A$.size),s),W$=Buffer.alloc(Z$);await J$.read(W$,0,Z$,0);let y$=W$.toString("utf-8"),Q$=1;for(let n=0;n<y$.length;n++)if(y$.charCodeAt(n)===10)Q$++;let y=Q$<=AB+z;return{text:y$,overlaps:y}}finally{await J$.close()}}catch{return}});if(k){let A$=k.text;if(!k.overlaps){let s=D7(A$,AB,IB);r=`...output truncated (head+tail shown due to errors)...
|
|
7585
7587
|
|
|
7586
7588
|
Full output saved to: ${L}
|
|
7587
7589
|
|
|
@@ -7606,5 +7608,5 @@ Full output saved to: ${L}
|
|
|
7606
7608
|
<bash_metadata>
|
|
7607
7609
|
`+m.join(`
|
|
7608
7610
|
`)+`
|
|
7609
|
-
</bash_metadata>`;if(R){let S=R;yield*G.promise(()=>new Promise((T)=>{S.end(()=>T()),S.on("error",()=>T())}))}return{title:
|
|
7610
|
-
export{W1 as
|
|
7611
|
+
</bash_metadata>`;if(R){let S=R;yield*G.promise(()=>new Promise((T)=>{S.end(()=>T()),S.on("error",()=>T())}))}return{title:H.description,metadata:{output:C||PB(r),exit:v,description:H.description,truncated:N,...N&&L?{outputPath:L}:{}},output:r}});return()=>G.sync(()=>{let H=KJ.acceptable(),q=KJ.name(H),U=q==="powershell"?"If the commands depend on each other and must run sequentially, avoid '&&' in this shell because Windows PowerShell 5.1 does not support it. Use PowerShell conditionals such as `cmd1; if ($?) { cmd2 }` when later commands must depend on earlier success.":"If the commands depend on each other and must run sequentially, use a single Bash call with '&&' to chain them together (e.g., `git add . && git commit -m \"message\" && git push`). For instance, if one operation must complete before another starts (like mkdir before cp, Write before Bash for git operations, or git add before git commit), run these operations sequentially instead.";return v3.info("bash tool using shell",{shell:H}),{description:$.replaceAll("${directory}",B$.directory).replaceAll("${os}",process.platform).replaceAll("${shell}",q).replaceAll("${chaining}",U).replaceAll("${maxLines}",String(DJ)).replaceAll("${maxBytes}",String(u1)),parameters:tV,execute:(z,M)=>G.gen(function*(){let I=t$.get(M.sessionID),C=z.workdir?yield*V(z.workdir,I,H):I;if(z.timeout!==void 0&&z.timeout<0)throw Error(`Invalid timeout value: ${z.timeout}. Timeout must be a positive number.`);let P=z.timeout??rA,D=wB.has(q),L=yield*GS(z.command,D),R=yield*W(L,C,D,H);if(!B$.containsPath(C))R.dirs.add(C);if(yield*XS(M,R),z.interactive){let N=yield*_(M,C);yield*M.metadata({metadata:{output:"(waiting for user interaction...)",description:z.description}});let x=yield*G.tryPromise(()=>iV({command:z.command,cwd:C,env:N,description:z.description})).pipe(G.orDie);return{title:z.description,metadata:{output:x.output||"(interactive command completed)",exit:x.exitCode,description:z.description,truncated:!1},output:x.output||`(interactive command completed with exit code ${x.exitCode})`}}return yield*j({shell:H,name:q,command:z.command,cwd:C,env:yield*_(M,C),timeout:P,description:z.description},M)})}})}));var m3={};o$(m3,{retryable:()=>cB,policy:()=>AS,persistentRetryDelay:()=>IS,isRetryableTransientError:()=>dB,delay:()=>pB,SessionRetry:()=>m3,RETRY_MAX_DELAY_NO_HEADERS:()=>FS,RETRY_MAX_DELAY:()=>zS,RETRY_INITIAL_DELAY:()=>OS,RETRY_BACKOFF_FACTOR:()=>qS,PERSISTENT_RETRY_MAX_DELAY:()=>DS,PERSISTENT_RETRY_MAX_ATTEMPTS:()=>PS,PERSISTENT_RETRY_INITIAL_DELAY:()=>CS,PERSISTENT_RETRY_BACKOFF_FACTOR:()=>MS,GO_UPSELL_MESSAGE:()=>uB});var yB=2000,TB=2,kB=30000,EB=2147483647,US=new Set(["ECONNRESET","EPIPE","ETIMEDOUT"]);var BS=new Set([429,500,502,503,504,529]);function xB($){if(!($ instanceof Error))return!1;let J=$.status??$.statusCode??$.response?.status;if(typeof J==="number"&&BS.has(J))return!0;let Z=$.code;if(typeof Z==="string"&&US.has(Z))return!0;if($.message==="SSE read timed out")return!0;if(HS($))return!0;return!1}function HS($){let J=$;return J.retryable===!0&&typeof J.category==="string"&&J.category.length>0}function oJ($){return Math.min($,2147483647)}function bB($,J){if(J){if(typeof J.retryAfterMs==="number"&&!Number.isNaN(J.retryAfterMs))return oJ(J.retryAfterMs);let Z=J.data?.responseHeaders;if(Z){let Y=Z["retry-after-ms"];if(Y){let Q=Number.parseFloat(Y);if(!Number.isNaN(Q))return oJ(Q)}let K=Z["retry-after"];if(K){let Q=Number.parseFloat(K);if(!Number.isNaN(Q))return oJ(Math.ceil(Q*1000));let V=Date.parse(K)-Date.now();if(!Number.isNaN(V)&&V>0)return oJ(Math.ceil(V))}return oJ(2000*Math.pow(2,$-1))}}return oJ(Math.min(2000*Math.pow(2,$-1),30000))}var h3=500,g3=2,f3=300000,vB=10;function hB($){return Math.min(h3*g3**($-1),f3)}var uB="Free usage exceeded, subscribe to Go https://opencode.ai/go",OS=yB,qS=TB,FS=kB,zS=EB,dB=xB,pB=bB,CS=h3,MS=g3,DS=f3,PS=vB,IS=hB;function cB($){if(E0.ContextOverflowError.isInstance($))return;if(dB($))return $.message||"Transient network error";if(E0.APIError.isInstance($)){let K=$.data.statusCode;if($.data.category==="output_budget_exhausted"||$.data.category==="empty_output")return;if($.data.category==="stream_truncated"&&$.data.isRetryable)return $.data.message;if(!$.data.isRetryable&&!(K!==void 0&&K>=500))return;if($.data.responseBody?.includes("FreeUsageLimitError"))return uB;return $.data.message.includes("Overloaded")?"Provider is overloaded":$.data.message}let J=$.data?.message;if(typeof J==="string"){let K=J.toLowerCase();if(K.includes("rate increased too quickly")||K.includes("rate limit")||K.includes("too many requests"))return J}let Z=mB(()=>{try{if(typeof $.data?.message==="string")return JSON.parse($.data.message);return JSON.parse($.data.message)}catch{return}});if(!Z||typeof Z!=="object")return;let Y=typeof Z.code==="string"?Z.code:"";if(Z.type==="error"&&Z.error?.type==="too_many_requests")return"Too Many Requests";if(Y.includes("exhausted")||Y.includes("unavailable"))return"Provider is overloaded";if(Z.type==="error"&&typeof Z.error?.code==="string"&&Z.error.code.includes("rate_limit"))return"Rate Limited";return}function AS($){return fB.fromStepWithMetadata(G.succeed((J)=>{let Z=$.parse(J.input),Y=cB(Z);if(!Y)return n0.done(J.attempt);return G.gen(function*(){let K=J.input,Q=typeof K?.retryAfterMs==="number"?K.retryAfterMs:void 0,V=pB(J.attempt,E0.APIError.isInstance(Z)?Z:Q!==void 0?{retryAfterMs:Q}:void 0),X=yield*gB.currentTimeMillis;return yield*$.set({attempt:J.attempt,message:Y,next:X+V}),[J.attempt,h2.millis(V)]})}))}var um=Z0.define("tui.instructions.loaded",F.object({files:F.array(F.string()).describe("Display labels of loaded instruction files: worktree-relative path, ~-path, or absolute")}));
|
|
7612
|
+
export{W1 as Yg,h0 as Zg,w2 as _g,k2 as $g,FJ as ah,MR as bh,a0 as ch,g1 as dh,e9 as eh,$Z as fh,MJ as gh,um as hh,j1 as ih,PJ as jh,Wy as kh,GF as lh,B1 as mh,KJ as nh,BZ as oh,UF as ph,d1 as qh,d2 as rh,QX as sh,XX as th,c2 as uh,SZ as vh,v7 as wh,K1 as xh,qX as yh,RZ as zh,o2 as Ah,Ax as Bh,oX as Ch,o7 as Dh,aX as Eh,l8 as Fh,o8 as Gh,iU as Hh,JB as Ih,p0 as Jh,dB as Kh,CS as Lh,MS as Mh,DS as Nh,PS as Oh,IS as Ph,m3 as Qh};
|