@thxgg/steward 0.1.13 → 0.1.14

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.
Files changed (84) hide show
  1. package/.output/nitro.json +1 -1
  2. package/.output/public/_nuxt/-k8zG74W.js +61 -0
  3. package/.output/public/_nuxt/B-5VWizU.js +1 -0
  4. package/.output/public/_nuxt/{Bq6edYSd.js → BDqHART1.js} +1 -1
  5. package/.output/public/_nuxt/BMAq0QVD.js +42 -0
  6. package/.output/public/_nuxt/BPeTf9dd.js +1 -0
  7. package/.output/public/_nuxt/{dOaEkD-3.js → BubpH_wW.js} +1 -1
  8. package/.output/public/_nuxt/C2HGkiSP.js +1 -0
  9. package/.output/public/_nuxt/CMu9GKTH.js +4 -0
  10. package/.output/public/_nuxt/{BZ1iIOYp.js → CVvrkZkq.js} +1 -1
  11. package/.output/public/_nuxt/C_NevjZD.js +3 -0
  12. package/.output/public/_nuxt/Detail.CzXXlavD.css +1 -0
  13. package/.output/public/_nuxt/_prd_.KTotLoF_.css +1 -0
  14. package/.output/public/_nuxt/builds/latest.json +1 -1
  15. package/.output/public/_nuxt/builds/meta/b57a8fc3-6a38-4f58-b2ae-54768412ea40.json +1 -0
  16. package/.output/public/_nuxt/entry.LcDOtJnR.css +1 -0
  17. package/.output/public/_nuxt/{BFv4l3hn.js → nYTZJhvT.js} +1 -1
  18. package/.output/public/_nuxt/{kTT8NKtq.js → qKRNa41x.js} +1 -1
  19. package/.output/public/_nuxt/qt5OEWHC.js +1 -0
  20. package/.output/public/_nuxt/{C897Egk9.js → uTyw4SRK.js} +1 -1
  21. package/.output/public/_nuxt/{DoNqd8jQ.js → wbj-mIhK.js} +1 -1
  22. package/.output/server/chunks/_/task-graph.mjs +196 -0
  23. package/.output/server/chunks/_/task-graph.mjs.map +1 -0
  24. package/.output/server/chunks/build/{_prd_-CkKfJB6U.mjs → Detail-DC-KJQ1f.mjs} +911 -1688
  25. package/.output/server/chunks/build/Detail-DC-KJQ1f.mjs.map +1 -0
  26. package/.output/server/chunks/build/DiffViewer-styles-1.mjs-D0sb4vsK.mjs +4 -0
  27. package/.output/server/chunks/build/DiffViewer-styles-1.mjs-D0sb4vsK.mjs.map +1 -0
  28. package/.output/server/chunks/build/DiffViewer-styles.CkSjCQ0r.mjs +10 -0
  29. package/.output/server/chunks/build/DiffViewer-styles.CkSjCQ0r.mjs.map +1 -0
  30. package/.output/server/chunks/build/DiffViewer-styles.FJJuYjYB.mjs +8 -0
  31. package/.output/server/chunks/build/DiffViewer-styles.FJJuYjYB.mjs.map +1 -0
  32. package/.output/server/chunks/build/_prd_-C1C4GAhW.mjs +1596 -0
  33. package/.output/server/chunks/build/_prd_-C1C4GAhW.mjs.map +1 -0
  34. package/.output/server/chunks/build/client.precomputed.mjs +1 -1
  35. package/.output/server/chunks/build/{default-B5nw9_Xg.mjs → default-DWCOHHTE.mjs} +32 -20
  36. package/.output/server/chunks/build/default-DWCOHHTE.mjs.map +1 -0
  37. package/.output/server/chunks/build/{index-CTpuP9Mj.mjs → index-CckL_NBD.mjs} +2 -2
  38. package/.output/server/chunks/build/index-CckL_NBD.mjs.map +1 -0
  39. package/.output/server/chunks/build/{index-D21S97KB.mjs → index-QVeSHT3L.mjs} +3 -3
  40. package/.output/server/chunks/build/index-QVeSHT3L.mjs.map +1 -0
  41. package/.output/server/chunks/build/repo-graph-CTEkxiYd.mjs +205 -0
  42. package/.output/server/chunks/build/repo-graph-CTEkxiYd.mjs.map +1 -0
  43. package/.output/server/chunks/build/server.mjs +12 -3
  44. package/.output/server/chunks/build/styles.mjs +2 -2
  45. package/.output/server/chunks/build/{usePrd-YhvN6Ary.mjs → usePrd-SqcxGyFU.mjs} +20 -2
  46. package/.output/server/chunks/build/usePrd-SqcxGyFU.mjs.map +1 -0
  47. package/.output/server/chunks/nitro/nitro.mjs +566 -534
  48. package/.output/server/chunks/routes/api/repos/_repoId/graph.get.mjs +41 -0
  49. package/.output/server/chunks/routes/api/repos/_repoId/graph.get.mjs.map +1 -0
  50. package/.output/server/chunks/routes/api/repos/_repoId/prd/_prdSlug/graph.get.mjs +42 -0
  51. package/.output/server/chunks/routes/api/repos/_repoId/prd/_prdSlug/graph.get.mjs.map +1 -0
  52. package/.output/server/chunks/routes/api/repos/_repoId/prd/_prdSlug/progress.get.mjs +1 -1
  53. package/.output/server/chunks/routes/api/repos/_repoId/prd/_prdSlug/tasks/_taskId/commits.get.mjs +1 -1
  54. package/.output/server/chunks/routes/api/repos/_repoId/prd/_prdSlug/tasks.get.mjs +1 -1
  55. package/.output/server/chunks/routes/api/repos/_repoId/prds.get.mjs +1 -1
  56. package/.output/server/node_modules/@vue-flow/background/dist/vue-flow-background.mjs +126 -0
  57. package/.output/server/node_modules/@vue-flow/background/package.json +73 -0
  58. package/.output/server/node_modules/@vue-flow/controls/dist/vue-flow-controls.mjs +207 -0
  59. package/.output/server/node_modules/@vue-flow/controls/package.json +77 -0
  60. package/.output/server/node_modules/@vue-flow/core/dist/vue-flow-core.mjs +10186 -0
  61. package/.output/server/node_modules/@vue-flow/core/package.json +95 -0
  62. package/.output/server/package.json +4 -1
  63. package/dist/app/types/graph.js +1 -0
  64. package/dist/server/utils/task-graph.js +190 -0
  65. package/package.json +5 -1
  66. package/.output/public/_nuxt/BuQdImno.js +0 -1
  67. package/.output/public/_nuxt/CMUOpExW.js +0 -3
  68. package/.output/public/_nuxt/DE885CbX.js +0 -1
  69. package/.output/public/_nuxt/DomrzX-T.js +0 -76
  70. package/.output/public/_nuxt/R2cvz8mH.js +0 -4
  71. package/.output/public/_nuxt/_prd_.DYvuV73Q.css +0 -1
  72. package/.output/public/_nuxt/builds/meta/2ad99048-24f9-4cf6-8622-6c088fe0a244.json +0 -1
  73. package/.output/public/_nuxt/entry.Dk19PK4d.css +0 -1
  74. package/.output/server/chunks/build/DiffViewer-styles-1.mjs-ZdBUa15f.mjs +0 -4
  75. package/.output/server/chunks/build/DiffViewer-styles-1.mjs-ZdBUa15f.mjs.map +0 -1
  76. package/.output/server/chunks/build/DiffViewer-styles.CoMVrk_N.mjs +0 -8
  77. package/.output/server/chunks/build/DiffViewer-styles.CoMVrk_N.mjs.map +0 -1
  78. package/.output/server/chunks/build/DiffViewer-styles.cLfMOdMh.mjs +0 -10
  79. package/.output/server/chunks/build/DiffViewer-styles.cLfMOdMh.mjs.map +0 -1
  80. package/.output/server/chunks/build/_prd_-CkKfJB6U.mjs.map +0 -1
  81. package/.output/server/chunks/build/default-B5nw9_Xg.mjs.map +0 -1
  82. package/.output/server/chunks/build/index-CTpuP9Mj.mjs.map +0 -1
  83. package/.output/server/chunks/build/index-D21S97KB.mjs.map +0 -1
  84. package/.output/server/chunks/build/usePrd-YhvN6Ary.mjs.map +0 -1
@@ -1,76 +0,0 @@
1
- const __vite__mapDeps=(i,m=__vite__mapDeps,d=(m.f||(m.f=["./DxNHbxmM.js","./CnnebwVN.js","./wDzz0qaB.js","./DPfMkruS.js","./Cl0AqbOI.js","./2EtD6e53.js","./Cn7AkR1O.js","./BGJmEYvX.js","./CylS5w8V.js","./Cp-IABpG.js","./DxSwrfjg.js","./BPQ3VLAy.js","./CXtECtnM.js","./COt5Ahok.js","./5X7smno1.js","./DGP4VlC8.js","./BLtJtn59.js","./CquLrc37.js","./DVxCFoDh.js","./CO1LY3CK.js","./B6aJPvgy.js","./BYV0-3_D.js","./CxbxFI8M.js","./Bp3cYrEr.js","./CDVJQ6XC.js","./DZxFcAj9.js","./BIGW1oBm.js","./fKv21gyL.js","./Yzrsuije.js","./DZu-aV2c.js","./CpOuai2O.js","./CeZK1NFH.js","./CGscLIrv.js","./Bhrxn6JZ.js","./CmIQRyeF.js","./C9oPPf7i.js","./g9-lgVsj.js","./CnsnAmq5.js","./Buea-lGh.js","./CuPHTKiy.js","./Cvjx9yec.js","./B7c-h3xW.js","./BxgE0vQu.js","./BTifaqeh.js","./CenWIFCC.js","./DkwncUOv.js","./C5YyOfLZ.js","./CxGSJlkm.js","./D97Zzqfu.js","./CSXwinHm.js","./YqXBG_HV.js","./BR5kRUq4.js","./CLZrNe3w.js","./m17aaUwq.js","./CufHLc7y.js","./CYsAdtH9.js","./fuZLfV_i.js","./DWrx1Km3.js","./CzTSHFRz.js","./CXZktZb0.js","./Br6cN0cg.js","./W9tJ9s81.js","./Dspwwk_N.js","./DMwsHuHA.js","./CQ8jqdy-.js","./mjskCLCv.js","./83L43bj1.js","./B1dDrJ26.js","./TsXTqZ29.js","./Dph4kLrZ.js","./DhmSosst.js","./BzTr9Aqm.js","./DJjDtW9f.js","./BLmx8bSh.js","./BVQ-GDCI.js","./DsumFeuD.js","./COcwbKMJ.js","./DQwYQDb2.js","./D1j8_8rp.js","./CG8Ifv2g.js","./BqTXFGrv.js","./D3lLCCz7.js","./Cq5zzVJU.js","./Dzze3sRP.js","./BRZ36xJF.js","./BsS91CYL.js","./DM8c43g1.js","./BH7IYjvW.js","./DYoxhk2S.js","./CZhp0h8q.js","./CxLEBnE3.js","./Cm3UrAx6.js","./RNghxpo_.js","./DEthMvLe.js","./DqQDbK_p.js","./CW8IKDeL.js","./BEDo0Tqx.js","./yv6CvBhz.js"])))=>i.map(i=>d[i]);
2
- import{_ as _l}from"./DoNqd8jQ.js";import{u as Ts,a as As,f as Ss,c as Ft,E as yl,b as vl,d as vi,g as bl,w as kl,e as Ce,P as Rs,V as wl,D as xl,h as Ls,i as rr,T as El,B as Nt,C as cn,A as yo,j as Tl,R as Hr,L as Gr,K as Al,S as Sl,k as Rl,l as Ll,m as Cl,n as Pl,o as Ol,p as Il,q as Dl,r as Nl,s as Ml,t as $l,v as vo}from"./CMUOpExW.js";import{c as se,r as Vl,t as Bl,d as zl,e as Fl,f as bi,P as nt,g as jl,h as Cs,i as bo,j as Ve,B as at,k as jt,b as Ps,F as Os,u as ql,a as Hl}from"./DE885CbX.js";import{v as Ur,q as j,x as dt,s as $,g as U,y as ir,o as w,z as K,w as M,b as R,l as m,A as ne,B as Is,C as Gl,D as Ds,c as A,E as Pe,k as Te,G as Ul,H as Wl,I as Ot,J as Ns,K as un,L as Kl,M as Xl,n as Y,N as Yl,p as Ms,O as gn,P as _n,d as re,t as G,Q as kt,R as Ql,a as T,_ as p,S as ue,F as ve,r as He,T as Ln,U as Jl,V as Zl,W as ec,X as tc,m as ko,i as nc}from"./R2cvz8mH.js";import{_ as $s}from"./DlAUqK2U.js";import{A as wo}from"./BFv4l3hn.js";const rc=se("arrow-down",[["path",{d:"M12 5v14",key:"s699le"}],["path",{d:"m19 12-7 7-7-7",key:"1idqje"}]]);const ic=se("arrow-left",[["path",{d:"m12 19-7-7 7-7",key:"1l729n"}],["path",{d:"M19 12H5",key:"x3x0zl"}]]);const Vs=se("calendar",[["path",{d:"M8 2v4",key:"1cmpym"}],["path",{d:"M16 2v4",key:"4m81vk"}],["rect",{width:"18",height:"18",x:"3",y:"4",rx:"2",key:"1hopcy"}],["path",{d:"M3 10h18",key:"8toen8"}]]);const Wr=se("circle-check",[["circle",{cx:"12",cy:"12",r:"10",key:"1mglay"}],["path",{d:"m9 12 2 2 4-4",key:"dzmm74"}]]);const oc=se("circle-dot",[["circle",{cx:"12",cy:"12",r:"10",key:"1mglay"}],["circle",{cx:"12",cy:"12",r:"1",key:"41hilf"}]]);const sc=se("circle-play",[["path",{d:"M9 9.003a1 1 0 0 1 1.517-.859l4.997 2.997a1 1 0 0 1 0 1.718l-4.997 2.997A1 1 0 0 1 9 14.996z",key:"kmsa83"}],["circle",{cx:"12",cy:"12",r:"10",key:"1mglay"}]]);const an=se("circle",[["circle",{cx:"12",cy:"12",r:"10",key:"1mglay"}]]);const ac=se("clock",[["path",{d:"M12 6v6l4 2",key:"mmk7yg"}],["circle",{cx:"12",cy:"12",r:"10",key:"1mglay"}]]);const lc=se("diff",[["path",{d:"M12 3v14",key:"7cf3v8"}],["path",{d:"M5 10h14",key:"elsbfy"}],["path",{d:"M5 21h14",key:"11awu3"}]]);const xo=se("external-link",[["path",{d:"M15 3h6v6",key:"1q9fwt"}],["path",{d:"M10 14 21 3",key:"gplh6r"}],["path",{d:"M18 13v6a2 2 0 0 1-2 2H5a2 2 0 0 1-2-2V8a2 2 0 0 1 2-2h6",key:"a6xqqp"}]]);const cc=se("file-code",[["path",{d:"M6 22a2 2 0 0 1-2-2V4a2 2 0 0 1 2-2h8a2.4 2.4 0 0 1 1.704.706l3.588 3.588A2.4 2.4 0 0 1 20 8v12a2 2 0 0 1-2 2z",key:"1oefj6"}],["path",{d:"M14 2v5a1 1 0 0 0 1 1h5",key:"wfsgrz"}],["path",{d:"M10 12.5 8 15l2 2.5",key:"1tg20x"}],["path",{d:"m14 12.5 2 2.5-2 2.5",key:"yinavb"}]]);const uc=se("file-diff",[["path",{d:"M6 22a2 2 0 0 1-2-2V4a2 2 0 0 1 2-2h8a2.4 2.4 0 0 1 1.704.706l3.588 3.588A2.4 2.4 0 0 1 20 8v12a2 2 0 0 1-2 2z",key:"1oefj6"}],["path",{d:"M9 10h6",key:"9gxzsh"}],["path",{d:"M12 13V7",key:"h0r20n"}],["path",{d:"M9 17h6",key:"r8uit2"}]]);const dc=se("file-exclamation-point",[["path",{d:"M6 22a2 2 0 0 1-2-2V4a2 2 0 0 1 2-2h8a2.4 2.4 0 0 1 1.704.706l3.588 3.588A2.4 2.4 0 0 1 20 8v12a2 2 0 0 1-2 2z",key:"1oefj6"}],["path",{d:"M12 9v4",key:"juzpu7"}],["path",{d:"M12 17h.01",key:"p32p05"}]]);const pc=se("file-pen",[["path",{d:"M12.659 22H18a2 2 0 0 0 2-2V8a2.4 2.4 0 0 0-.706-1.706l-3.588-3.588A2.4 2.4 0 0 0 14 2H6a2 2 0 0 0-2 2v9.34",key:"o6klzx"}],["path",{d:"M14 2v5a1 1 0 0 0 1 1h5",key:"wfsgrz"}],["path",{d:"M10.378 12.622a1 1 0 0 1 3 3.003L8.36 20.637a2 2 0 0 1-.854.506l-2.867.837a.5.5 0 0 1-.62-.62l.836-2.869a2 2 0 0 1 .506-.853z",key:"zhnas1"}]]);const mc=se("file-plus",[["path",{d:"M6 22a2 2 0 0 1-2-2V4a2 2 0 0 1 2-2h8a2.4 2.4 0 0 1 1.704.706l3.588 3.588A2.4 2.4 0 0 1 20 8v12a2 2 0 0 1-2 2z",key:"1oefj6"}],["path",{d:"M14 2v5a1 1 0 0 0 1 1h5",key:"wfsgrz"}],["path",{d:"M9 15h6",key:"cctwl0"}],["path",{d:"M12 18v-6",key:"17g6i2"}]]);const fc=se("file-x",[["path",{d:"M6 22a2 2 0 0 1-2-2V4a2 2 0 0 1 2-2h8a2.4 2.4 0 0 1 1.704.706l3.588 3.588A2.4 2.4 0 0 1 20 8v12a2 2 0 0 1-2 2z",key:"1oefj6"}],["path",{d:"M14 2v5a1 1 0 0 0 1 1h5",key:"wfsgrz"}],["path",{d:"m14.5 12.5-5 5",key:"b62r18"}],["path",{d:"m9.5 12.5 5 5",key:"1rk7el"}]]);const hc=se("folder-git-2",[["path",{d:"M18 19a5 5 0 0 1-5-5v8",key:"sz5oeg"}],["path",{d:"M9 20H4a2 2 0 0 1-2-2V5a2 2 0 0 1 2-2h3.9a2 2 0 0 1 1.69.9l.81 1.2a2 2 0 0 0 1.67.9H20a2 2 0 0 1 2 2v5",key:"1w6njk"}],["circle",{cx:"13",cy:"12",r:"2",key:"1j92g6"}],["circle",{cx:"20",cy:"19",r:"2",key:"1obnsp"}]]);const gc=se("git-commit-horizontal",[["circle",{cx:"12",cy:"12",r:"3",key:"1v7zrd"}],["line",{x1:"3",x2:"9",y1:"12",y2:"12",key:"1dyftd"}],["line",{x1:"15",x2:"21",y1:"12",y2:"12",key:"oup4p8"}]]);const _c=se("link-2-off",[["path",{d:"M9 17H7A5 5 0 0 1 7 7",key:"10o201"}],["path",{d:"M15 7h2a5 5 0 0 1 4 8",key:"1d3206"}],["line",{x1:"8",x2:"12",y1:"12",y2:"12",key:"rvw6j4"}],["line",{x1:"2",x2:"22",y1:"2",y2:"22",key:"a6p6uj"}]]);const yc=se("link-2",[["path",{d:"M9 17H7A5 5 0 0 1 7 7h2",key:"8i5ue5"}],["path",{d:"M15 7h2a5 5 0 1 1 0 10h-2",key:"1b9ql8"}],["line",{x1:"8",x2:"16",y1:"12",y2:"12",key:"1jonct"}]]);const vc=se("link",[["path",{d:"M10 13a5 5 0 0 0 7.54.54l3-3a5 5 0 0 0-7.07-7.07l-1.72 1.71",key:"1cjeqo"}],["path",{d:"M14 11a5 5 0 0 0-7.54-.54l-3 3a5 5 0 0 0 7.07 7.07l1.71-1.71",key:"19qd67"}]]);const bc=se("list-ordered",[["path",{d:"M11 5h10",key:"1cz7ny"}],["path",{d:"M11 12h10",key:"1438ji"}],["path",{d:"M11 19h10",key:"11t30w"}],["path",{d:"M4 4h1v5",key:"10yrso"}],["path",{d:"M4 9h2",key:"r1h2o0"}],["path",{d:"M6.5 20H3.4c0-1 2.6-1.925 2.6-3.5a1.5 1.5 0 0 0-2.6-1.02",key:"xtkcd5"}]]);const Kr=se("minus",[["path",{d:"M5 12h14",key:"1ays0h"}]]);const kc=se("square-check-big",[["path",{d:"M21 10.656V19a2 2 0 0 1-2 2H5a2 2 0 0 1-2-2V5a2 2 0 0 1 2-2h12.344",key:"2acyp4"}],["path",{d:"m9 11 3 3L22 4",key:"1pflzl"}]]);const wc=se("tag",[["path",{d:"M12.586 2.586A2 2 0 0 0 11.172 2H4a2 2 0 0 0-2 2v7.172a2 2 0 0 0 .586 1.414l8.704 8.704a2.426 2.426 0 0 0 3.42 0l6.58-6.58a2.426 2.426 0 0 0 0-3.42z",key:"vktsd0"}],["circle",{cx:"7.5",cy:"7.5",r:".5",fill:"currentColor",key:"kqv944"}]]);const Xr=se("triangle-alert",[["path",{d:"m21.73 18-8-14a2 2 0 0 0-3.48 0l-8 14A2 2 0 0 0 4 21h16a2 2 0 0 0 1.73-3",key:"wmoenq"}],["path",{d:"M12 9v4",key:"juzpu7"}],["path",{d:"M12 17h.01",key:"p32p05"}]]);const xc=se("user",[["path",{d:"M19 21v-2a4 4 0 0 0-4-4H9a4 4 0 0 0-4 4v2",key:"975kel"}],["circle",{cx:"12",cy:"7",r:"4",key:"17ys0d"}]]);function Ec(t,e){const n=Vl(!1,300);Bl(()=>{n.value=!1});const r=j(null),i=zl();function o(){r.value=null,n.value=!1}function s(l,a){const c=l.currentTarget,u={x:l.clientX,y:l.clientY},d=Tc(u,c.getBoundingClientRect()),h=Ac(u,d,1),f=Sc(a.getBoundingClientRect()),g=Lc([...h,...f]);r.value=g,n.value=!0}return Ur(l=>{if(t.value&&e.value){const a=u=>s(u,e.value),c=u=>s(u,t.value);t.value.addEventListener("pointerleave",a),e.value.addEventListener("pointerleave",c),l(()=>{t.value?.removeEventListener("pointerleave",a),e.value?.removeEventListener("pointerleave",c)})}}),Ur(l=>{if(r.value){const a=c=>{if(!r.value||!(c.target instanceof Element))return;const u=c.target,d={x:c.clientX,y:c.clientY},h=t.value?.contains(u)||e.value?.contains(u),f=!Rc(d,r.value),g=!!u.closest("[data-grace-area-trigger]");h?o():(f||g)&&(o(),i.trigger())};t.value?.ownerDocument.addEventListener("pointermove",a),l(()=>t.value?.ownerDocument.removeEventListener("pointermove",a))}}),{isPointerInTransit:n,onPointerExit:i.on}}function Tc(t,e){const n=Math.abs(e.top-t.y),r=Math.abs(e.bottom-t.y),i=Math.abs(e.right-t.x),o=Math.abs(e.left-t.x);switch(Math.min(n,r,i,o)){case o:return"left";case i:return"right";case n:return"top";case r:return"bottom";default:throw new Error("unreachable")}}function Ac(t,e,n=5){const r=[];switch(e){case"top":r.push({x:t.x-n,y:t.y+n},{x:t.x+n,y:t.y+n});break;case"bottom":r.push({x:t.x-n,y:t.y-n},{x:t.x+n,y:t.y-n});break;case"left":r.push({x:t.x+n,y:t.y-n},{x:t.x+n,y:t.y+n});break;case"right":r.push({x:t.x-n,y:t.y-n},{x:t.x-n,y:t.y+n});break}return r}function Sc(t){const{top:e,right:n,bottom:r,left:i}=t;return[{x:i,y:e},{x:n,y:e},{x:n,y:r},{x:i,y:r}]}function Rc(t,e){const{x:n,y:r}=t;let i=!1;for(let o=0,s=e.length-1;o<e.length;s=o++){const l=e[o].x,a=e[o].y,c=e[s].x,u=e[s].y;a>r!=u>r&&n<(c-l)*(r-a)/(u-a)+l&&(i=!i)}return i}function Lc(t){const e=t.slice();return e.sort((n,r)=>n.x<r.x?-1:n.x>r.x?1:n.y<r.y?-1:n.y>r.y?1:0),Cc(e)}function Cc(t){if(t.length<=1)return t.slice();const e=[];for(let r=0;r<t.length;r++){const i=t[r];for(;e.length>=2;){const o=e[e.length-1],s=e[e.length-2];if((o.x-s.x)*(i.y-s.y)>=(o.y-s.y)*(i.x-s.x))e.pop();else break}e.push(i)}e.pop();const n=[];for(let r=t.length-1;r>=0;r--){const i=t[r];for(;n.length>=2;){const o=n[n.length-1],s=n[n.length-2];if((o.x-s.x)*(i.y-s.y)>=(o.y-s.y)*(i.x-s.x))n.pop();else break}n.push(i)}return n.pop(),e.length===1&&n.length===1&&e[0].x===n[0].x&&e[0].y===n[0].y?e:e.concat(n)}function Pc(t){const e=j(),n=$(()=>e.value?.width??0),r=$(()=>e.value?.height??0);return dt(()=>{const i=Fl(t);if(i){e.value={width:i.offsetWidth,height:i.offsetHeight};const o=new ResizeObserver(s=>{if(!Array.isArray(s)||!s.length)return;const l=s[0];let a,c;if("borderBoxSize"in l){const u=l.borderBoxSize,d=Array.isArray(u)?u[0]:u;a=d.inlineSize,c=d.blockSize}else a=i.offsetWidth,c=i.offsetHeight;e.value={width:a,height:c}});return o.observe(i,{box:"border-box"}),()=>o.unobserve(i)}else e.value=void 0}),{width:n,height:r}}const[Oc,Ic]=Ft("RovingFocusGroup");var Dc=U({__name:"RovingFocusGroup",props:{orientation:{type:String,required:!1,default:void 0},dir:{type:String,required:!1},loop:{type:Boolean,required:!1,default:!1},currentTabStopId:{type:[String,null],required:!1},defaultCurrentTabStopId:{type:String,required:!1},preventScrollOnEntryFocus:{type:Boolean,required:!1,default:!1},asChild:{type:Boolean,required:!1},as:{type:null,required:!1}},emits:["entryFocus","update:currentTabStopId"],setup(t,{expose:e,emit:n}){const r=t,i=n,{loop:o,orientation:s,dir:l}=ir(r),a=Ts(l),c=bi(r,"currentTabStopId",i,{defaultValue:r.defaultCurrentTabStopId,passive:r.currentTabStopId===void 0}),u=j(!1),d=j(!1),h=j(0),{getItems:f,CollectionSlot:g}=As({isProvider:!0});function y(v){const k=!d.value;if(v.currentTarget&&v.target===v.currentTarget&&k&&!u.value){const b=new CustomEvent(yl,vl);if(v.currentTarget.dispatchEvent(b),i("entryFocus",b),!b.defaultPrevented){const E=f().map(B=>B.ref).filter(B=>B.dataset.disabled!==""),P=E.find(B=>B.getAttribute("data-active")===""),V=E.find(B=>B.getAttribute("data-highlighted")===""),q=E.find(B=>B.id===c.value),J=[P,V,q,...E].filter(Boolean);Ss(J,r.preventScrollOnEntryFocus)}}d.value=!1}function x(){setTimeout(()=>{d.value=!1},1)}return e({getItems:f}),Ic({loop:o,dir:a,orientation:s,currentTabStopId:c,onItemFocus:v=>{c.value=v},onItemShiftTab:()=>{u.value=!0},onFocusableItemAdd:()=>{h.value++},onFocusableItemRemove:()=>{h.value--}}),(v,k)=>(w(),K(m(g),null,{default:M(()=>[R(m(nt),{tabindex:u.value||h.value===0?-1:0,"data-orientation":m(s),as:v.as,"as-child":v.asChild,dir:m(a),style:{outline:"none"},onMousedown:k[0]||(k[0]=b=>d.value=!0),onMouseup:x,onFocus:y,onBlur:k[1]||(k[1]=b=>u.value=!1)},{default:M(()=>[ne(v.$slots,"default")]),_:3},8,["tabindex","data-orientation","as","as-child","dir"])]),_:3}))}}),Nc=Dc,Mc=U({__name:"RovingFocusItem",props:{tabStopId:{type:String,required:!1},focusable:{type:Boolean,required:!1,default:!0},active:{type:Boolean,required:!1},allowShiftKey:{type:Boolean,required:!1},asChild:{type:Boolean,required:!1},as:{type:null,required:!1,default:"span"}},setup(t){const e=t,n=Oc(),r=vi(),i=$(()=>e.tabStopId||r),o=$(()=>n.currentTabStopId.value===i.value),{getItems:s,CollectionItem:l}=As();dt(()=>{e.focusable&&n.onFocusableItemAdd()}),Is(()=>{e.focusable&&n.onFocusableItemRemove()});function a(c){if(c.key==="Tab"&&c.shiftKey){n.onItemShiftTab();return}if(c.target!==c.currentTarget)return;const u=bl(c,n.orientation.value,n.dir.value);if(u!==void 0){if(c.metaKey||c.ctrlKey||c.altKey||!e.allowShiftKey&&c.shiftKey)return;c.preventDefault();let d=[...s().map(h=>h.ref).filter(h=>h.dataset.disabled!=="")];if(u==="last")d.reverse();else if(u==="prev"||u==="next"){u==="prev"&&d.reverse();const h=d.indexOf(c.currentTarget);d=n.loop.value?kl(d,h+1):d.slice(h+1)}Gl(()=>Ss(d))}}return(c,u)=>(w(),K(m(l),null,{default:M(()=>[R(m(nt),{tabindex:o.value?0:-1,"data-orientation":m(n).orientation.value,"data-active":c.active?"":void 0,"data-disabled":c.focusable?void 0:"",as:c.as,"as-child":c.asChild,onMousedown:u[0]||(u[0]=d=>{c.focusable?m(n).onItemFocus(i.value):d.preventDefault()}),onFocus:u[1]||(u[1]=d=>m(n).onItemFocus(i.value)),onKeydown:a},{default:M(()=>[ne(c.$slots,"default")]),_:3},8,["tabindex","data-orientation","data-active","data-disabled","as","as-child"])]),_:3}))}}),$c=Mc;const[Bs,Vc]=Ft("PopperRoot");var Bc=U({inheritAttrs:!1,__name:"PopperRoot",setup(t){const e=j();return Vc({anchor:e,onAnchorChange:n=>e.value=n}),(n,r)=>ne(n.$slots,"default")}}),zc=Bc,Fc=U({__name:"PopperAnchor",props:{reference:{type:null,required:!1},asChild:{type:Boolean,required:!1},as:{type:null,required:!1}},setup(t){const e=t,{forwardRef:n,currentElement:r}=Ce(),i=Bs();return Ds(()=>{i.onAnchorChange(e.reference??r.value)}),(o,s)=>(w(),K(m(nt),{ref:m(n),as:o.as,"as-child":o.asChild},{default:M(()=>[ne(o.$slots,"default")]),_:3},8,["as","as-child"]))}}),jc=Fc;const qc={key:0,d:"M0 0L6 6L12 0"},Hc={key:1,d:"M0 0L4.58579 4.58579C5.36683 5.36683 6.63316 5.36684 7.41421 4.58579L12 0"};var Gc=U({__name:"Arrow",props:{width:{type:Number,required:!1,default:10},height:{type:Number,required:!1,default:5},rounded:{type:Boolean,required:!1},asChild:{type:Boolean,required:!1},as:{type:null,required:!1,default:"svg"}},setup(t){const e=t;return Ce(),(n,r)=>(w(),K(m(nt),Pe(e,{width:n.width,height:n.height,viewBox:n.asChild?void 0:"0 0 12 6",preserveAspectRatio:n.asChild?void 0:"none"}),{default:M(()=>[ne(n.$slots,"default",{},()=>[n.rounded?(w(),A("path",Hc)):(w(),A("path",qc))])]),_:3},16,["width","height","viewBox","preserveAspectRatio"]))}}),Uc=Gc;function Wc(t){return t!==null}function Kc(t){return{name:"transformOrigin",options:t,fn(e){const{placement:n,rects:r,middlewareData:i}=e,s=i.arrow?.centerOffset!==0,l=s?0:t.arrowWidth,a=s?0:t.arrowHeight,[c,u]=Yr(n),d={start:"0%",center:"50%",end:"100%"}[u],h=(i.arrow?.x??0)+l/2,f=(i.arrow?.y??0)+a/2;let g="",y="";return c==="bottom"?(g=s?d:`${h}px`,y=`${-a}px`):c==="top"?(g=s?d:`${h}px`,y=`${r.floating.height+a}px`):c==="right"?(g=`${-a}px`,y=s?d:`${f}px`):c==="left"&&(g=`${r.floating.width+a}px`,y=s?d:`${f}px`),{data:{x:g,y}}}}}function Yr(t){const[e,n="center"]=t.split("-");return[e,n]}const Xc=["top","right","bottom","left"],pt=Math.min,Me=Math.max,Fn=Math.round,Cn=Math.floor,et=t=>({x:t,y:t}),Yc={left:"right",right:"left",bottom:"top",top:"bottom"},Qc={start:"end",end:"start"};function Qr(t,e,n){return Me(t,pt(e,n))}function lt(t,e){return typeof t=="function"?t(e):t}function ct(t){return t.split("-")[0]}function qt(t){return t.split("-")[1]}function ki(t){return t==="x"?"y":"x"}function wi(t){return t==="y"?"height":"width"}const Jc=new Set(["top","bottom"]);function Ze(t){return Jc.has(ct(t))?"y":"x"}function xi(t){return ki(Ze(t))}function Zc(t,e,n){n===void 0&&(n=!1);const r=qt(t),i=xi(t),o=wi(i);let s=i==="x"?r===(n?"end":"start")?"right":"left":r==="start"?"bottom":"top";return e.reference[o]>e.floating[o]&&(s=jn(s)),[s,jn(s)]}function eu(t){const e=jn(t);return[Jr(t),e,Jr(e)]}function Jr(t){return t.replace(/start|end/g,e=>Qc[e])}const Eo=["left","right"],To=["right","left"],tu=["top","bottom"],nu=["bottom","top"];function ru(t,e,n){switch(t){case"top":case"bottom":return n?e?To:Eo:e?Eo:To;case"left":case"right":return e?tu:nu;default:return[]}}function iu(t,e,n,r){const i=qt(t);let o=ru(ct(t),n==="start",r);return i&&(o=o.map(s=>s+"-"+i),e&&(o=o.concat(o.map(Jr)))),o}function jn(t){return t.replace(/left|right|bottom|top/g,e=>Yc[e])}function ou(t){return{top:0,right:0,bottom:0,left:0,...t}}function zs(t){return typeof t!="number"?ou(t):{top:t,right:t,bottom:t,left:t}}function qn(t){const{x:e,y:n,width:r,height:i}=t;return{width:r,height:i,top:n,left:e,right:e+r,bottom:n+i,x:e,y:n}}function Ao(t,e,n){let{reference:r,floating:i}=t;const o=Ze(e),s=xi(e),l=wi(s),a=ct(e),c=o==="y",u=r.x+r.width/2-i.width/2,d=r.y+r.height/2-i.height/2,h=r[l]/2-i[l]/2;let f;switch(a){case"top":f={x:u,y:r.y-i.height};break;case"bottom":f={x:u,y:r.y+r.height};break;case"right":f={x:r.x+r.width,y:d};break;case"left":f={x:r.x-i.width,y:d};break;default:f={x:r.x,y:r.y}}switch(qt(e)){case"start":f[s]-=h*(n&&c?-1:1);break;case"end":f[s]+=h*(n&&c?-1:1);break}return f}async function su(t,e){var n;e===void 0&&(e={});const{x:r,y:i,platform:o,rects:s,elements:l,strategy:a}=t,{boundary:c="clippingAncestors",rootBoundary:u="viewport",elementContext:d="floating",altBoundary:h=!1,padding:f=0}=lt(e,t),g=zs(f),x=l[h?d==="floating"?"reference":"floating":d],v=qn(await o.getClippingRect({element:(n=await(o.isElement==null?void 0:o.isElement(x)))==null||n?x:x.contextElement||await(o.getDocumentElement==null?void 0:o.getDocumentElement(l.floating)),boundary:c,rootBoundary:u,strategy:a})),k=d==="floating"?{x:r,y:i,width:s.floating.width,height:s.floating.height}:s.reference,b=await(o.getOffsetParent==null?void 0:o.getOffsetParent(l.floating)),E=await(o.isElement==null?void 0:o.isElement(b))?await(o.getScale==null?void 0:o.getScale(b))||{x:1,y:1}:{x:1,y:1},P=qn(o.convertOffsetParentRelativeRectToViewportRelativeRect?await o.convertOffsetParentRelativeRectToViewportRelativeRect({elements:l,rect:k,offsetParent:b,strategy:a}):k);return{top:(v.top-P.top+g.top)/E.y,bottom:(P.bottom-v.bottom+g.bottom)/E.y,left:(v.left-P.left+g.left)/E.x,right:(P.right-v.right+g.right)/E.x}}const au=async(t,e,n)=>{const{placement:r="bottom",strategy:i="absolute",middleware:o=[],platform:s}=n,l=o.filter(Boolean),a=await(s.isRTL==null?void 0:s.isRTL(e));let c=await s.getElementRects({reference:t,floating:e,strategy:i}),{x:u,y:d}=Ao(c,r,a),h=r,f={},g=0;for(let x=0;x<l.length;x++){var y;const{name:v,fn:k}=l[x],{x:b,y:E,data:P,reset:V}=await k({x:u,y:d,initialPlacement:r,placement:h,strategy:i,middlewareData:f,rects:c,platform:{...s,detectOverflow:(y=s.detectOverflow)!=null?y:su},elements:{reference:t,floating:e}});u=b??u,d=E??d,f={...f,[v]:{...f[v],...P}},V&&g<=50&&(g++,typeof V=="object"&&(V.placement&&(h=V.placement),V.rects&&(c=V.rects===!0?await s.getElementRects({reference:t,floating:e,strategy:i}):V.rects),{x:u,y:d}=Ao(c,h,a)),x=-1)}return{x:u,y:d,placement:h,strategy:i,middlewareData:f}},lu=t=>({name:"arrow",options:t,async fn(e){const{x:n,y:r,placement:i,rects:o,platform:s,elements:l,middlewareData:a}=e,{element:c,padding:u=0}=lt(t,e)||{};if(c==null)return{};const d=zs(u),h={x:n,y:r},f=xi(i),g=wi(f),y=await s.getDimensions(c),x=f==="y",v=x?"top":"left",k=x?"bottom":"right",b=x?"clientHeight":"clientWidth",E=o.reference[g]+o.reference[f]-h[f]-o.floating[g],P=h[f]-o.reference[f],V=await(s.getOffsetParent==null?void 0:s.getOffsetParent(c));let q=V?V[b]:0;(!q||!await(s.isElement==null?void 0:s.isElement(V)))&&(q=l.floating[b]||o.floating[g]);const J=E/2-P/2,B=q/2-y[g]/2-1,S=pt(d[v],B),O=pt(d[k],B),N=S,D=q-y[g]-O,I=q/2-y[g]/2+J,z=Qr(N,I,D),W=!a.arrow&&qt(i)!=null&&I!==z&&o.reference[g]/2-(I<N?S:O)-y[g]/2<0,ee=W?I<N?I-N:I-D:0;return{[f]:h[f]+ee,data:{[f]:z,centerOffset:I-z-ee,...W&&{alignmentOffset:ee}},reset:W}}}),cu=function(t){return t===void 0&&(t={}),{name:"flip",options:t,async fn(e){var n,r;const{placement:i,middlewareData:o,rects:s,initialPlacement:l,platform:a,elements:c}=e,{mainAxis:u=!0,crossAxis:d=!0,fallbackPlacements:h,fallbackStrategy:f="bestFit",fallbackAxisSideDirection:g="none",flipAlignment:y=!0,...x}=lt(t,e);if((n=o.arrow)!=null&&n.alignmentOffset)return{};const v=ct(i),k=Ze(l),b=ct(l)===l,E=await(a.isRTL==null?void 0:a.isRTL(c.floating)),P=h||(b||!y?[jn(l)]:eu(l)),V=g!=="none";!h&&V&&P.push(...iu(l,y,g,E));const q=[l,...P],J=await a.detectOverflow(e,x),B=[];let S=((r=o.flip)==null?void 0:r.overflows)||[];if(u&&B.push(J[v]),d){const I=Zc(i,s,E);B.push(J[I[0]],J[I[1]])}if(S=[...S,{placement:i,overflows:B}],!B.every(I=>I<=0)){var O,N;const I=(((O=o.flip)==null?void 0:O.index)||0)+1,z=q[I];if(z&&(!(d==="alignment"?k!==Ze(z):!1)||S.every(Z=>Ze(Z.placement)===k?Z.overflows[0]>0:!0)))return{data:{index:I,overflows:S},reset:{placement:z}};let W=(N=S.filter(ee=>ee.overflows[0]<=0).sort((ee,Z)=>ee.overflows[1]-Z.overflows[1])[0])==null?void 0:N.placement;if(!W)switch(f){case"bestFit":{var D;const ee=(D=S.filter(Z=>{if(V){const oe=Ze(Z.placement);return oe===k||oe==="y"}return!0}).map(Z=>[Z.placement,Z.overflows.filter(oe=>oe>0).reduce((oe,Oe)=>oe+Oe,0)]).sort((Z,oe)=>Z[1]-oe[1])[0])==null?void 0:D[0];ee&&(W=ee);break}case"initialPlacement":W=l;break}if(i!==W)return{reset:{placement:W}}}return{}}}};function So(t,e){return{top:t.top-e.height,right:t.right-e.width,bottom:t.bottom-e.height,left:t.left-e.width}}function Ro(t){return Xc.some(e=>t[e]>=0)}const uu=function(t){return t===void 0&&(t={}),{name:"hide",options:t,async fn(e){const{rects:n,platform:r}=e,{strategy:i="referenceHidden",...o}=lt(t,e);switch(i){case"referenceHidden":{const s=await r.detectOverflow(e,{...o,elementContext:"reference"}),l=So(s,n.reference);return{data:{referenceHiddenOffsets:l,referenceHidden:Ro(l)}}}case"escaped":{const s=await r.detectOverflow(e,{...o,altBoundary:!0}),l=So(s,n.floating);return{data:{escapedOffsets:l,escaped:Ro(l)}}}default:return{}}}}},Fs=new Set(["left","top"]);async function du(t,e){const{placement:n,platform:r,elements:i}=t,o=await(r.isRTL==null?void 0:r.isRTL(i.floating)),s=ct(n),l=qt(n),a=Ze(n)==="y",c=Fs.has(s)?-1:1,u=o&&a?-1:1,d=lt(e,t);let{mainAxis:h,crossAxis:f,alignmentAxis:g}=typeof d=="number"?{mainAxis:d,crossAxis:0,alignmentAxis:null}:{mainAxis:d.mainAxis||0,crossAxis:d.crossAxis||0,alignmentAxis:d.alignmentAxis};return l&&typeof g=="number"&&(f=l==="end"?g*-1:g),a?{x:f*u,y:h*c}:{x:h*c,y:f*u}}const pu=function(t){return t===void 0&&(t=0),{name:"offset",options:t,async fn(e){var n,r;const{x:i,y:o,placement:s,middlewareData:l}=e,a=await du(e,t);return s===((n=l.offset)==null?void 0:n.placement)&&(r=l.arrow)!=null&&r.alignmentOffset?{}:{x:i+a.x,y:o+a.y,data:{...a,placement:s}}}}},mu=function(t){return t===void 0&&(t={}),{name:"shift",options:t,async fn(e){const{x:n,y:r,placement:i,platform:o}=e,{mainAxis:s=!0,crossAxis:l=!1,limiter:a={fn:v=>{let{x:k,y:b}=v;return{x:k,y:b}}},...c}=lt(t,e),u={x:n,y:r},d=await o.detectOverflow(e,c),h=Ze(ct(i)),f=ki(h);let g=u[f],y=u[h];if(s){const v=f==="y"?"top":"left",k=f==="y"?"bottom":"right",b=g+d[v],E=g-d[k];g=Qr(b,g,E)}if(l){const v=h==="y"?"top":"left",k=h==="y"?"bottom":"right",b=y+d[v],E=y-d[k];y=Qr(b,y,E)}const x=a.fn({...e,[f]:g,[h]:y});return{...x,data:{x:x.x-n,y:x.y-r,enabled:{[f]:s,[h]:l}}}}}},fu=function(t){return t===void 0&&(t={}),{options:t,fn(e){const{x:n,y:r,placement:i,rects:o,middlewareData:s}=e,{offset:l=0,mainAxis:a=!0,crossAxis:c=!0}=lt(t,e),u={x:n,y:r},d=Ze(i),h=ki(d);let f=u[h],g=u[d];const y=lt(l,e),x=typeof y=="number"?{mainAxis:y,crossAxis:0}:{mainAxis:0,crossAxis:0,...y};if(a){const b=h==="y"?"height":"width",E=o.reference[h]-o.floating[b]+x.mainAxis,P=o.reference[h]+o.reference[b]-x.mainAxis;f<E?f=E:f>P&&(f=P)}if(c){var v,k;const b=h==="y"?"width":"height",E=Fs.has(ct(i)),P=o.reference[d]-o.floating[b]+(E&&((v=s.offset)==null?void 0:v[d])||0)+(E?0:x.crossAxis),V=o.reference[d]+o.reference[b]+(E?0:((k=s.offset)==null?void 0:k[d])||0)-(E?x.crossAxis:0);g<P?g=P:g>V&&(g=V)}return{[h]:f,[d]:g}}}},hu=function(t){return t===void 0&&(t={}),{name:"size",options:t,async fn(e){var n,r;const{placement:i,rects:o,platform:s,elements:l}=e,{apply:a=()=>{},...c}=lt(t,e),u=await s.detectOverflow(e,c),d=ct(i),h=qt(i),f=Ze(i)==="y",{width:g,height:y}=o.floating;let x,v;d==="top"||d==="bottom"?(x=d,v=h===(await(s.isRTL==null?void 0:s.isRTL(l.floating))?"start":"end")?"left":"right"):(v=d,x=h==="end"?"top":"bottom");const k=y-u.top-u.bottom,b=g-u.left-u.right,E=pt(y-u[x],k),P=pt(g-u[v],b),V=!e.middlewareData.shift;let q=E,J=P;if((n=e.middlewareData.shift)!=null&&n.enabled.x&&(J=b),(r=e.middlewareData.shift)!=null&&r.enabled.y&&(q=k),V&&!h){const S=Me(u.left,0),O=Me(u.right,0),N=Me(u.top,0),D=Me(u.bottom,0);f?J=g-2*(S!==0||O!==0?S+O:Me(u.left,u.right)):q=y-2*(N!==0||D!==0?N+D:Me(u.top,u.bottom))}await a({...e,availableWidth:J,availableHeight:q});const B=await s.getDimensions(l.floating);return g!==B.width||y!==B.height?{reset:{rects:!0}}:{}}}};function or(){return typeof window<"u"}function wt(t){return Ei(t)?(t.nodeName||"").toLowerCase():"#document"}function $e(t){var e;return(t==null||(e=t.ownerDocument)==null?void 0:e.defaultView)||window}function rt(t){var e;return(e=(Ei(t)?t.ownerDocument:t.document)||window.document)==null?void 0:e.documentElement}function Ei(t){return or()?t instanceof Node||t instanceof $e(t).Node:!1}function Ge(t){return or()?t instanceof Element||t instanceof $e(t).Element:!1}function tt(t){return or()?t instanceof HTMLElement||t instanceof $e(t).HTMLElement:!1}function Lo(t){return!or()||typeof ShadowRoot>"u"?!1:t instanceof ShadowRoot||t instanceof $e(t).ShadowRoot}const gu=new Set(["inline","contents"]);function yn(t){const{overflow:e,overflowX:n,overflowY:r,display:i}=Ue(t);return/auto|scroll|overlay|hidden|clip/.test(e+r+n)&&!gu.has(i)}const _u=new Set(["table","td","th"]);function yu(t){return _u.has(wt(t))}const vu=[":popover-open",":modal"];function sr(t){return vu.some(e=>{try{return t.matches(e)}catch{return!1}})}const bu=["transform","translate","scale","rotate","perspective"],ku=["transform","translate","scale","rotate","perspective","filter"],wu=["paint","layout","strict","content"];function Ti(t){const e=Ai(),n=Ge(t)?Ue(t):t;return bu.some(r=>n[r]?n[r]!=="none":!1)||(n.containerType?n.containerType!=="normal":!1)||!e&&(n.backdropFilter?n.backdropFilter!=="none":!1)||!e&&(n.filter?n.filter!=="none":!1)||ku.some(r=>(n.willChange||"").includes(r))||wu.some(r=>(n.contain||"").includes(r))}function xu(t){let e=mt(t);for(;tt(e)&&!Bt(e);){if(Ti(e))return e;if(sr(e))return null;e=mt(e)}return null}function Ai(){return typeof CSS>"u"||!CSS.supports?!1:CSS.supports("-webkit-backdrop-filter","none")}const Eu=new Set(["html","body","#document"]);function Bt(t){return Eu.has(wt(t))}function Ue(t){return $e(t).getComputedStyle(t)}function ar(t){return Ge(t)?{scrollLeft:t.scrollLeft,scrollTop:t.scrollTop}:{scrollLeft:t.scrollX,scrollTop:t.scrollY}}function mt(t){if(wt(t)==="html")return t;const e=t.assignedSlot||t.parentNode||Lo(t)&&t.host||rt(t);return Lo(e)?e.host:e}function js(t){const e=mt(t);return Bt(e)?t.ownerDocument?t.ownerDocument.body:t.body:tt(e)&&yn(e)?e:js(e)}function dn(t,e,n){var r;e===void 0&&(e=[]),n===void 0&&(n=!0);const i=js(t),o=i===((r=t.ownerDocument)==null?void 0:r.body),s=$e(i);if(o){const l=Zr(s);return e.concat(s,s.visualViewport||[],yn(i)?i:[],l&&n?dn(l):[])}return e.concat(i,dn(i,[],n))}function Zr(t){return t.parent&&Object.getPrototypeOf(t.parent)?t.frameElement:null}function qs(t){const e=Ue(t);let n=parseFloat(e.width)||0,r=parseFloat(e.height)||0;const i=tt(t),o=i?t.offsetWidth:n,s=i?t.offsetHeight:r,l=Fn(n)!==o||Fn(r)!==s;return l&&(n=o,r=s),{width:n,height:r,$:l}}function Si(t){return Ge(t)?t:t.contextElement}function Mt(t){const e=Si(t);if(!tt(e))return et(1);const n=e.getBoundingClientRect(),{width:r,height:i,$:o}=qs(e);let s=(o?Fn(n.width):n.width)/r,l=(o?Fn(n.height):n.height)/i;return(!s||!Number.isFinite(s))&&(s=1),(!l||!Number.isFinite(l))&&(l=1),{x:s,y:l}}const Tu=et(0);function Hs(t){const e=$e(t);return!Ai()||!e.visualViewport?Tu:{x:e.visualViewport.offsetLeft,y:e.visualViewport.offsetTop}}function Au(t,e,n){return e===void 0&&(e=!1),!n||e&&n!==$e(t)?!1:e}function vt(t,e,n,r){e===void 0&&(e=!1),n===void 0&&(n=!1);const i=t.getBoundingClientRect(),o=Si(t);let s=et(1);e&&(r?Ge(r)&&(s=Mt(r)):s=Mt(t));const l=Au(o,n,r)?Hs(o):et(0);let a=(i.left+l.x)/s.x,c=(i.top+l.y)/s.y,u=i.width/s.x,d=i.height/s.y;if(o){const h=$e(o),f=r&&Ge(r)?$e(r):r;let g=h,y=Zr(g);for(;y&&r&&f!==g;){const x=Mt(y),v=y.getBoundingClientRect(),k=Ue(y),b=v.left+(y.clientLeft+parseFloat(k.paddingLeft))*x.x,E=v.top+(y.clientTop+parseFloat(k.paddingTop))*x.y;a*=x.x,c*=x.y,u*=x.x,d*=x.y,a+=b,c+=E,g=$e(y),y=Zr(g)}}return qn({width:u,height:d,x:a,y:c})}function lr(t,e){const n=ar(t).scrollLeft;return e?e.left+n:vt(rt(t)).left+n}function Gs(t,e){const n=t.getBoundingClientRect(),r=n.left+e.scrollLeft-lr(t,n),i=n.top+e.scrollTop;return{x:r,y:i}}function Su(t){let{elements:e,rect:n,offsetParent:r,strategy:i}=t;const o=i==="fixed",s=rt(r),l=e?sr(e.floating):!1;if(r===s||l&&o)return n;let a={scrollLeft:0,scrollTop:0},c=et(1);const u=et(0),d=tt(r);if((d||!d&&!o)&&((wt(r)!=="body"||yn(s))&&(a=ar(r)),tt(r))){const f=vt(r);c=Mt(r),u.x=f.x+r.clientLeft,u.y=f.y+r.clientTop}const h=s&&!d&&!o?Gs(s,a):et(0);return{width:n.width*c.x,height:n.height*c.y,x:n.x*c.x-a.scrollLeft*c.x+u.x+h.x,y:n.y*c.y-a.scrollTop*c.y+u.y+h.y}}function Ru(t){return Array.from(t.getClientRects())}function Lu(t){const e=rt(t),n=ar(t),r=t.ownerDocument.body,i=Me(e.scrollWidth,e.clientWidth,r.scrollWidth,r.clientWidth),o=Me(e.scrollHeight,e.clientHeight,r.scrollHeight,r.clientHeight);let s=-n.scrollLeft+lr(t);const l=-n.scrollTop;return Ue(r).direction==="rtl"&&(s+=Me(e.clientWidth,r.clientWidth)-i),{width:i,height:o,x:s,y:l}}const Co=25;function Cu(t,e){const n=$e(t),r=rt(t),i=n.visualViewport;let o=r.clientWidth,s=r.clientHeight,l=0,a=0;if(i){o=i.width,s=i.height;const u=Ai();(!u||u&&e==="fixed")&&(l=i.offsetLeft,a=i.offsetTop)}const c=lr(r);if(c<=0){const u=r.ownerDocument,d=u.body,h=getComputedStyle(d),f=u.compatMode==="CSS1Compat"&&parseFloat(h.marginLeft)+parseFloat(h.marginRight)||0,g=Math.abs(r.clientWidth-d.clientWidth-f);g<=Co&&(o-=g)}else c<=Co&&(o+=c);return{width:o,height:s,x:l,y:a}}const Pu=new Set(["absolute","fixed"]);function Ou(t,e){const n=vt(t,!0,e==="fixed"),r=n.top+t.clientTop,i=n.left+t.clientLeft,o=tt(t)?Mt(t):et(1),s=t.clientWidth*o.x,l=t.clientHeight*o.y,a=i*o.x,c=r*o.y;return{width:s,height:l,x:a,y:c}}function Po(t,e,n){let r;if(e==="viewport")r=Cu(t,n);else if(e==="document")r=Lu(rt(t));else if(Ge(e))r=Ou(e,n);else{const i=Hs(t);r={x:e.x-i.x,y:e.y-i.y,width:e.width,height:e.height}}return qn(r)}function Us(t,e){const n=mt(t);return n===e||!Ge(n)||Bt(n)?!1:Ue(n).position==="fixed"||Us(n,e)}function Iu(t,e){const n=e.get(t);if(n)return n;let r=dn(t,[],!1).filter(l=>Ge(l)&&wt(l)!=="body"),i=null;const o=Ue(t).position==="fixed";let s=o?mt(t):t;for(;Ge(s)&&!Bt(s);){const l=Ue(s),a=Ti(s);!a&&l.position==="fixed"&&(i=null),(o?!a&&!i:!a&&l.position==="static"&&!!i&&Pu.has(i.position)||yn(s)&&!a&&Us(t,s))?r=r.filter(u=>u!==s):i=l,s=mt(s)}return e.set(t,r),r}function Du(t){let{element:e,boundary:n,rootBoundary:r,strategy:i}=t;const s=[...n==="clippingAncestors"?sr(e)?[]:Iu(e,this._c):[].concat(n),r],l=s[0],a=s.reduce((c,u)=>{const d=Po(e,u,i);return c.top=Me(d.top,c.top),c.right=pt(d.right,c.right),c.bottom=pt(d.bottom,c.bottom),c.left=Me(d.left,c.left),c},Po(e,l,i));return{width:a.right-a.left,height:a.bottom-a.top,x:a.left,y:a.top}}function Nu(t){const{width:e,height:n}=qs(t);return{width:e,height:n}}function Mu(t,e,n){const r=tt(e),i=rt(e),o=n==="fixed",s=vt(t,!0,o,e);let l={scrollLeft:0,scrollTop:0};const a=et(0);function c(){a.x=lr(i)}if(r||!r&&!o)if((wt(e)!=="body"||yn(i))&&(l=ar(e)),r){const f=vt(e,!0,o,e);a.x=f.x+e.clientLeft,a.y=f.y+e.clientTop}else i&&c();o&&!r&&i&&c();const u=i&&!r&&!o?Gs(i,l):et(0),d=s.left+l.scrollLeft-a.x-u.x,h=s.top+l.scrollTop-a.y-u.y;return{x:d,y:h,width:s.width,height:s.height}}function Lr(t){return Ue(t).position==="static"}function Oo(t,e){if(!tt(t)||Ue(t).position==="fixed")return null;if(e)return e(t);let n=t.offsetParent;return rt(t)===n&&(n=n.ownerDocument.body),n}function Ws(t,e){const n=$e(t);if(sr(t))return n;if(!tt(t)){let i=mt(t);for(;i&&!Bt(i);){if(Ge(i)&&!Lr(i))return i;i=mt(i)}return n}let r=Oo(t,e);for(;r&&yu(r)&&Lr(r);)r=Oo(r,e);return r&&Bt(r)&&Lr(r)&&!Ti(r)?n:r||xu(t)||n}const $u=async function(t){const e=this.getOffsetParent||Ws,n=this.getDimensions,r=await n(t.floating);return{reference:Mu(t.reference,await e(t.floating),t.strategy),floating:{x:0,y:0,width:r.width,height:r.height}}};function Vu(t){return Ue(t).direction==="rtl"}const Bu={convertOffsetParentRelativeRectToViewportRelativeRect:Su,getDocumentElement:rt,getClippingRect:Du,getOffsetParent:Ws,getElementRects:$u,getClientRects:Ru,getDimensions:Nu,getScale:Mt,isElement:Ge,isRTL:Vu};function Ks(t,e){return t.x===e.x&&t.y===e.y&&t.width===e.width&&t.height===e.height}function zu(t,e){let n=null,r;const i=rt(t);function o(){var l;clearTimeout(r),(l=n)==null||l.disconnect(),n=null}function s(l,a){l===void 0&&(l=!1),a===void 0&&(a=1),o();const c=t.getBoundingClientRect(),{left:u,top:d,width:h,height:f}=c;if(l||e(),!h||!f)return;const g=Cn(d),y=Cn(i.clientWidth-(u+h)),x=Cn(i.clientHeight-(d+f)),v=Cn(u),b={rootMargin:-g+"px "+-y+"px "+-x+"px "+-v+"px",threshold:Me(0,pt(1,a))||1};let E=!0;function P(V){const q=V[0].intersectionRatio;if(q!==a){if(!E)return s();q?s(!1,q):r=setTimeout(()=>{s(!1,1e-7)},1e3)}q===1&&!Ks(c,t.getBoundingClientRect())&&s(),E=!1}try{n=new IntersectionObserver(P,{...b,root:i.ownerDocument})}catch{n=new IntersectionObserver(P,b)}n.observe(t)}return s(!0),o}function Fu(t,e,n,r){r===void 0&&(r={});const{ancestorScroll:i=!0,ancestorResize:o=!0,elementResize:s=typeof ResizeObserver=="function",layoutShift:l=typeof IntersectionObserver=="function",animationFrame:a=!1}=r,c=Si(t),u=i||o?[...c?dn(c):[],...dn(e)]:[];u.forEach(v=>{i&&v.addEventListener("scroll",n,{passive:!0}),o&&v.addEventListener("resize",n)});const d=c&&l?zu(c,n):null;let h=-1,f=null;s&&(f=new ResizeObserver(v=>{let[k]=v;k&&k.target===c&&f&&(f.unobserve(e),cancelAnimationFrame(h),h=requestAnimationFrame(()=>{var b;(b=f)==null||b.observe(e)})),n()}),c&&!a&&f.observe(c),f.observe(e));let g,y=a?vt(t):null;a&&x();function x(){const v=vt(t);y&&!Ks(y,v)&&n(),y=v,g=requestAnimationFrame(x)}return n(),()=>{var v;u.forEach(k=>{i&&k.removeEventListener("scroll",n),o&&k.removeEventListener("resize",n)}),d?.(),(v=f)==null||v.disconnect(),f=null,a&&cancelAnimationFrame(g)}}const ju=pu,qu=mu,Io=cu,Hu=hu,Gu=uu,Uu=lu,Wu=fu,Ku=(t,e,n)=>{const r=new Map,i={platform:Bu,...n},o={...i.platform,_c:r};return au(t,e,{...i,platform:o})};function Xu(t){return t!=null&&typeof t=="object"&&"$el"in t}function ei(t){if(Xu(t)){const e=t.$el;return Ei(e)&&wt(e)==="#comment"?null:e}return t}function It(t){return typeof t=="function"?t():m(t)}function Yu(t){return{name:"arrow",options:t,fn(e){const n=ei(It(t.element));return n==null?{}:Uu({element:n,padding:t.padding}).fn(e)}}}function Xs(t){return typeof window>"u"?1:(t.ownerDocument.defaultView||window).devicePixelRatio||1}function Do(t,e){const n=Xs(t);return Math.round(e*n)/n}function Qu(t,e,n){n===void 0&&(n={});const r=n.whileElementsMounted,i=$(()=>{var q;return(q=It(n.open))!=null?q:!0}),o=$(()=>It(n.middleware)),s=$(()=>{var q;return(q=It(n.placement))!=null?q:"bottom"}),l=$(()=>{var q;return(q=It(n.strategy))!=null?q:"absolute"}),a=$(()=>{var q;return(q=It(n.transform))!=null?q:!0}),c=$(()=>ei(t.value)),u=$(()=>ei(e.value)),d=j(0),h=j(0),f=j(l.value),g=j(s.value),y=Ns({}),x=j(!1),v=$(()=>{const q={position:f.value,left:"0",top:"0"};if(!u.value)return q;const J=Do(u.value,d.value),B=Do(u.value,h.value);return a.value?{...q,transform:"translate("+J+"px, "+B+"px)",...Xs(u.value)>=1.5&&{willChange:"transform"}}:{position:f.value,left:J+"px",top:B+"px"}});let k;function b(){if(c.value==null||u.value==null)return;const q=i.value;Ku(c.value,u.value,{middleware:o.value,placement:s.value,strategy:l.value}).then(J=>{d.value=J.x,h.value=J.y,f.value=J.strategy,g.value=J.placement,y.value=J.middlewareData,x.value=q!==!1})}function E(){typeof k=="function"&&(k(),k=void 0)}function P(){if(E(),r===void 0){b();return}if(c.value!=null&&u.value!=null){k=r(c.value,u.value,b);return}}function V(){i.value||(x.value=!1)}return Te([o,s,l,i],b,{flush:"sync"}),Te([c,u],P,{flush:"sync"}),Te(i,V,{flush:"sync"}),Ul()&&Wl(E),{x:Ot(d),y:Ot(h),strategy:Ot(f),placement:Ot(g),middlewareData:Ot(y),isPositioned:Ot(x),floatingStyles:v,update:b}}const Ju={side:"bottom",sideOffset:0,sideFlip:!0,align:"center",alignOffset:0,alignFlip:!0,arrowPadding:0,hideShiftedArrow:!0,avoidCollisions:!0,collisionBoundary:()=>[],collisionPadding:0,sticky:"partial",hideWhenDetached:!1,positionStrategy:"fixed",updatePositionStrategy:"optimized",prioritizePosition:!1},[Zu,ed]=Ft("PopperContent");var td=U({inheritAttrs:!1,__name:"PopperContent",props:Kl({side:{type:null,required:!1},sideOffset:{type:Number,required:!1},sideFlip:{type:Boolean,required:!1},align:{type:null,required:!1},alignOffset:{type:Number,required:!1},alignFlip:{type:Boolean,required:!1},avoidCollisions:{type:Boolean,required:!1},collisionBoundary:{type:null,required:!1},collisionPadding:{type:[Number,Object],required:!1},arrowPadding:{type:Number,required:!1},hideShiftedArrow:{type:Boolean,required:!1},sticky:{type:String,required:!1},hideWhenDetached:{type:Boolean,required:!1},positionStrategy:{type:String,required:!1},updatePositionStrategy:{type:String,required:!1},disableUpdateOnLayoutShift:{type:Boolean,required:!1},prioritizePosition:{type:Boolean,required:!1},reference:{type:null,required:!1},asChild:{type:Boolean,required:!1},as:{type:null,required:!1}},{...Ju}),emits:["placed"],setup(t,{emit:e}){const n=t,r=e,i=Bs(),{forwardRef:o,currentElement:s}=Ce(),l=j(),a=j(),{width:c,height:u}=Pc(a),d=$(()=>n.side+(n.align!=="center"?`-${n.align}`:"")),h=$(()=>typeof n.collisionPadding=="number"?n.collisionPadding:{top:0,right:0,bottom:0,left:0,...n.collisionPadding}),f=$(()=>Array.isArray(n.collisionBoundary)?n.collisionBoundary:[n.collisionBoundary]),g=$(()=>({padding:h.value,boundary:f.value.filter(Wc),altBoundary:f.value.length>0})),y=$(()=>({mainAxis:n.sideFlip,crossAxis:n.alignFlip})),x=jl(()=>[ju({mainAxis:n.sideOffset+u.value,alignmentAxis:n.alignOffset}),n.prioritizePosition&&n.avoidCollisions&&Io({...g.value,...y.value}),n.avoidCollisions&&qu({mainAxis:!0,crossAxis:!!n.prioritizePosition,limiter:n.sticky==="partial"?Wu():void 0,...g.value}),!n.prioritizePosition&&n.avoidCollisions&&Io({...g.value,...y.value}),Hu({...g.value,apply:({elements:N,rects:D,availableWidth:I,availableHeight:z})=>{const{width:W,height:ee}=D.reference,Z=N.floating.style;Z.setProperty("--reka-popper-available-width",`${I}px`),Z.setProperty("--reka-popper-available-height",`${z}px`),Z.setProperty("--reka-popper-anchor-width",`${W}px`),Z.setProperty("--reka-popper-anchor-height",`${ee}px`)}}),a.value&&Yu({element:a.value,padding:n.arrowPadding}),Kc({arrowWidth:c.value,arrowHeight:u.value}),n.hideWhenDetached&&Gu({strategy:"referenceHidden",...g.value})]),v=$(()=>n.reference??i.anchor.value),{floatingStyles:k,placement:b,isPositioned:E,middlewareData:P}=Qu(v,l,{strategy:n.positionStrategy,placement:d,whileElementsMounted:(...N)=>Fu(...N,{layoutShift:!n.disableUpdateOnLayoutShift,animationFrame:n.updatePositionStrategy==="always"}),middleware:x}),V=$(()=>Yr(b.value)[0]),q=$(()=>Yr(b.value)[1]);Ds(()=>{E.value&&r("placed")});const J=$(()=>{const N=P.value.arrow?.centerOffset!==0;return n.hideShiftedArrow&&N}),B=j("");Ur(()=>{s.value&&(B.value=window.getComputedStyle(s.value).zIndex)});const S=$(()=>P.value.arrow?.x??0),O=$(()=>P.value.arrow?.y??0);return ed({placedSide:V,onArrowChange:N=>a.value=N,arrowX:S,arrowY:O,shouldHideArrow:J}),(N,D)=>(w(),A("div",{ref_key:"floatingRef",ref:l,"data-reka-popper-content-wrapper":"",style:un({...m(k),transform:m(E)?m(k).transform:"translate(0, -200%)",minWidth:"max-content",zIndex:B.value,"--reka-popper-transform-origin":[m(P).transformOrigin?.x,m(P).transformOrigin?.y].join(" "),...m(P).hide?.referenceHidden&&{visibility:"hidden",pointerEvents:"none"}})},[R(m(nt),Pe({ref:m(o)},N.$attrs,{"as-child":n.asChild,as:N.as,"data-side":V.value,"data-align":q.value,style:{animation:m(E)?void 0:"none"}}),{default:M(()=>[ne(N.$slots,"default")]),_:3},16,["as-child","as","data-side","data-align","style"])],4))}}),nd=td;const rd={top:"bottom",right:"left",bottom:"top",left:"right"};var id=U({inheritAttrs:!1,__name:"PopperArrow",props:{width:{type:Number,required:!1},height:{type:Number,required:!1},rounded:{type:Boolean,required:!1},asChild:{type:Boolean,required:!1},as:{type:null,required:!1,default:"svg"}},setup(t){const{forwardRef:e}=Ce(),n=Zu(),r=$(()=>rd[n.placedSide.value]);return(i,o)=>(w(),A("span",{ref:s=>{m(n).onArrowChange(s)},style:un({position:"absolute",left:m(n).arrowX?.value?`${m(n).arrowX?.value}px`:void 0,top:m(n).arrowY?.value?`${m(n).arrowY?.value}px`:void 0,[r.value]:0,transformOrigin:{top:"",right:"0 0",bottom:"center 0",left:"100% 0"}[m(n).placedSide.value],transform:{top:"translateY(100%)",right:"translateY(50%) rotate(90deg) translateX(-50%)",bottom:"rotate(180deg)",left:"translateY(50%) rotate(-90deg) translateX(50%)"}[m(n).placedSide.value],visibility:m(n).shouldHideArrow.value?"hidden":void 0})},[R(Uc,Pe(i.$attrs,{ref:m(e),style:{display:"block"},as:i.as,"as-child":i.asChild,rounded:i.rounded,width:i.width,height:i.height}),{default:M(()=>[ne(i.$slots,"default")]),_:3},16,["as","as-child","rounded","width","height"])],4))}}),od=id;const[Ri,sd]=Ft("TabsRoot");var ad=U({__name:"TabsRoot",props:{defaultValue:{type:null,required:!1},orientation:{type:String,required:!1,default:"horizontal"},dir:{type:String,required:!1},activationMode:{type:String,required:!1,default:"automatic"},modelValue:{type:null,required:!1},unmountOnHide:{type:Boolean,required:!1,default:!0},asChild:{type:Boolean,required:!1},as:{type:null,required:!1}},emits:["update:modelValue"],setup(t,{emit:e}){const n=t,r=e,{orientation:i,unmountOnHide:o,dir:s}=ir(n),l=Ts(s);Ce();const a=bi(n,"modelValue",r,{defaultValue:n.defaultValue,passive:n.modelValue===void 0}),c=j(),u=Ns(new Set);return sd({modelValue:a,changeModelValue:d=>{a.value=d},orientation:i,dir:l,unmountOnHide:o,activationMode:n.activationMode,baseId:vi(void 0,"reka-tabs"),tabsList:c,contentIds:u,registerContent:d=>{u.value=new Set([...u.value,d])},unregisterContent:d=>{const h=new Set(u.value);h.delete(d),u.value=h}}),(d,h)=>(w(),K(m(nt),{dir:m(l),"data-orientation":m(i),"as-child":d.asChild,as:d.as},{default:M(()=>[ne(d.$slots,"default",{modelValue:m(a)})]),_:3},8,["dir","data-orientation","as-child","as"]))}}),ld=ad;function Ys(t,e){return`${t}-trigger-${e}`}function Qs(t,e){return`${t}-content-${e}`}var cd=U({__name:"TabsContent",props:{value:{type:[String,Number],required:!0},forceMount:{type:Boolean,required:!1},asChild:{type:Boolean,required:!1},as:{type:null,required:!1}},setup(t){const e=t,{forwardRef:n}=Ce(),r=Ri(),i=$(()=>Ys(r.baseId,e.value)),o=$(()=>Qs(r.baseId,e.value)),s=$(()=>e.value===r.modelValue.value),l=j(s.value);return dt(()=>{r.registerContent(e.value),requestAnimationFrame(()=>{l.value=!1})}),Xl(()=>{r.unregisterContent(e.value)}),(a,c)=>(w(),K(m(Rs),{present:a.forceMount||s.value,"force-mount":""},{default:M(({present:u})=>[R(m(nt),{id:o.value,ref:m(n),"as-child":a.asChild,as:a.as,role:"tabpanel","data-state":s.value?"active":"inactive","data-orientation":m(r).orientation.value,"aria-labelledby":i.value,hidden:!u,tabindex:"0",style:un({animationDuration:l.value?"0s":void 0})},{default:M(()=>[!m(r).unmountOnHide.value||u?ne(a.$slots,"default",{key:0}):Y("v-if",!0)]),_:2},1032,["id","as-child","as","data-state","data-orientation","aria-labelledby","hidden","style"])]),_:3},8,["present"]))}}),ud=cd,dd=U({__name:"TabsList",props:{loop:{type:Boolean,required:!1,default:!0},asChild:{type:Boolean,required:!1},as:{type:null,required:!1}},setup(t){const e=t,{loop:n}=ir(e),{forwardRef:r,currentElement:i}=Ce(),o=Ri();return o.tabsList=i,(s,l)=>(w(),K(m(Nc),{"as-child":"",orientation:m(o).orientation.value,dir:m(o).dir.value,loop:m(n)},{default:M(()=>[R(m(nt),{ref:m(r),role:"tablist","as-child":s.asChild,as:s.as,"aria-orientation":m(o).orientation.value},{default:M(()=>[ne(s.$slots,"default")]),_:3},8,["as-child","as","aria-orientation"])]),_:3},8,["orientation","dir","loop"]))}}),pd=dd,md=U({__name:"TabsTrigger",props:{value:{type:[String,Number],required:!0},disabled:{type:Boolean,required:!1,default:!1},asChild:{type:Boolean,required:!1},as:{type:null,required:!1,default:"button"}},setup(t){const e=t,{forwardRef:n}=Ce(),r=Ri(),i=$(()=>Ys(r.baseId,e.value)),o=$(()=>r.contentIds.value.has(e.value)?Qs(r.baseId,e.value):void 0),s=$(()=>e.value===r.modelValue.value);return(l,a)=>(w(),K(m($c),{"as-child":"",focusable:!l.disabled,active:s.value},{default:M(()=>[R(m(nt),{id:i.value,ref:m(n),role:"tab",type:l.as==="button"?"button":void 0,as:l.as,"as-child":l.asChild,"aria-selected":s.value?"true":"false","aria-controls":o.value,"data-state":s.value?"active":"inactive",disabled:l.disabled,"data-disabled":l.disabled?"":void 0,"data-orientation":m(r).orientation.value,onMousedown:a[0]||(a[0]=Ms(c=>{!l.disabled&&c.ctrlKey===!1?m(r).changeModelValue(l.value):c.preventDefault()},["left"])),onKeydown:a[1]||(a[1]=Yl(c=>m(r).changeModelValue(l.value),["enter","space"])),onFocus:a[2]||(a[2]=()=>{const c=m(r).activationMode!=="manual";!s.value&&!l.disabled&&c&&m(r).changeModelValue(l.value)})},{default:M(()=>[ne(l.$slots,"default")]),_:3},8,["id","type","as","as-child","aria-selected","aria-controls","data-state","disabled","data-disabled","data-orientation"])]),_:3},8,["focusable","active"]))}}),fd=md,hd=U({__name:"TooltipArrow",props:{width:{type:Number,required:!1,default:10},height:{type:Number,required:!1,default:5},asChild:{type:Boolean,required:!1},as:{type:null,required:!1,default:"svg"}},setup(t){const e=t;return Ce(),(n,r)=>(w(),K(m(od),gn(_n(e)),{default:M(()=>[ne(n.$slots,"default")]),_:3},16))}}),gd=hd;const[Li,_d]=Ft("TooltipProvider");var yd=U({inheritAttrs:!1,__name:"TooltipProvider",props:{delayDuration:{type:Number,required:!1,default:700},skipDelayDuration:{type:Number,required:!1,default:300},disableHoverableContent:{type:Boolean,required:!1,default:!1},disableClosingTrigger:{type:Boolean,required:!1},disabled:{type:Boolean,required:!1},ignoreNonKeyboardFocus:{type:Boolean,required:!1,default:!1}},setup(t){const e=t,{delayDuration:n,skipDelayDuration:r,disableHoverableContent:i,disableClosingTrigger:o,ignoreNonKeyboardFocus:s,disabled:l}=ir(e);Ce();const a=j(!0),c=j(!1),{start:u,stop:d}=Cs(()=>{a.value=!0},r,{immediate:!1});return _d({isOpenDelayed:a,delayDuration:n,onOpen(){d(),a.value=!1},onClose(){u()},isPointerInTransitRef:c,disableHoverableContent:i,disableClosingTrigger:o,disabled:l,ignoreNonKeyboardFocus:s}),(h,f)=>ne(h.$slots,"default")}}),vd=yd;const Js="tooltip.open",[cr,bd]=Ft("TooltipRoot");var kd=U({__name:"TooltipRoot",props:{defaultOpen:{type:Boolean,required:!1,default:!1},open:{type:Boolean,required:!1,default:void 0},delayDuration:{type:Number,required:!1,default:void 0},disableHoverableContent:{type:Boolean,required:!1,default:void 0},disableClosingTrigger:{type:Boolean,required:!1,default:void 0},disabled:{type:Boolean,required:!1,default:void 0},ignoreNonKeyboardFocus:{type:Boolean,required:!1,default:void 0}},emits:["update:open"],setup(t,{emit:e}){const n=t,r=e;Ce();const i=Li(),o=$(()=>n.disableHoverableContent??i.disableHoverableContent.value),s=$(()=>n.disableClosingTrigger??i.disableClosingTrigger.value),l=$(()=>n.disabled??i.disabled.value),a=$(()=>n.delayDuration??i.delayDuration.value),c=$(()=>n.ignoreNonKeyboardFocus??i.ignoreNonKeyboardFocus.value),u=bi(n,"open",r,{defaultValue:n.defaultOpen,passive:n.open===void 0});Te(u,b=>{i.onClose&&(b?(i.onOpen(),document.dispatchEvent(new CustomEvent(Js))):i.onClose())});const d=j(!1),h=j(),f=$(()=>u.value?d.value?"delayed-open":"instant-open":"closed"),{start:g,stop:y}=Cs(()=>{d.value=!0,u.value=!0},a,{immediate:!1});function x(){y(),d.value=!1,u.value=!0}function v(){y(),u.value=!1}function k(){g()}return bd({contentId:"",open:u,stateAttribute:f,trigger:h,onTriggerChange(b){h.value=b},onTriggerEnter(){i.isOpenDelayed.value?k():x()},onTriggerLeave(){o.value?v():y()},onOpen:x,onClose:v,disableHoverableContent:o,disableClosingTrigger:s,disabled:l,ignoreNonKeyboardFocus:c}),(b,E)=>(w(),K(m(zc),null,{default:M(()=>[ne(b.$slots,"default",{open:m(u)})]),_:3}))}}),wd=kd,xd=U({__name:"TooltipContentImpl",props:{ariaLabel:{type:String,required:!1},asChild:{type:Boolean,required:!1},as:{type:null,required:!1},side:{type:null,required:!1,default:"top"},sideOffset:{type:Number,required:!1,default:0},align:{type:null,required:!1,default:"center"},alignOffset:{type:Number,required:!1},avoidCollisions:{type:Boolean,required:!1,default:!0},collisionBoundary:{type:null,required:!1,default:()=>[]},collisionPadding:{type:[Number,Object],required:!1,default:0},arrowPadding:{type:Number,required:!1,default:0},sticky:{type:String,required:!1,default:"partial"},hideWhenDetached:{type:Boolean,required:!1,default:!1},positionStrategy:{type:String,required:!1},updatePositionStrategy:{type:String,required:!1}},emits:["escapeKeyDown","pointerDownOutside"],setup(t,{emit:e}){const n=t,r=e,i=cr(),{forwardRef:o,currentElement:s}=Ce(),l=$(()=>n.ariaLabel||s.value?.textContent),a=$(()=>{const{ariaLabel:c,...u}=n;return u});return dt(()=>{bo(window,"scroll",c=>{c.target?.contains(i.trigger.value)&&i.onClose()}),bo(window,Js,i.onClose)}),(c,u)=>(w(),K(m(xl),{"as-child":"","disable-outside-pointer-events":!1,onEscapeKeyDown:u[0]||(u[0]=d=>r("escapeKeyDown",d)),onPointerDownOutside:u[1]||(u[1]=d=>{m(i).disableClosingTrigger.value&&m(i).trigger.value?.contains(d.target)&&d.preventDefault(),r("pointerDownOutside",d)}),onFocusOutside:u[2]||(u[2]=Ms(()=>{},["prevent"])),onDismiss:u[3]||(u[3]=d=>m(i).onClose())},{default:M(()=>[R(m(nd),Pe({ref:m(o),"data-state":m(i).stateAttribute.value},{...c.$attrs,...a.value},{style:{"--reka-tooltip-content-transform-origin":"var(--reka-popper-transform-origin)","--reka-tooltip-content-available-width":"var(--reka-popper-available-width)","--reka-tooltip-content-available-height":"var(--reka-popper-available-height)","--reka-tooltip-trigger-width":"var(--reka-popper-anchor-width)","--reka-tooltip-trigger-height":"var(--reka-popper-anchor-height)"}}),{default:M(()=>[ne(c.$slots,"default"),R(m(wl),{id:m(i).contentId,role:"tooltip"},{default:M(()=>[re(G(l.value),1)]),_:1},8,["id"])]),_:3},16,["data-state"])]),_:3}))}}),Zs=xd,Ed=U({__name:"TooltipContentHoverable",props:{ariaLabel:{type:String,required:!1},asChild:{type:Boolean,required:!1},as:{type:null,required:!1},side:{type:null,required:!1},sideOffset:{type:Number,required:!1},align:{type:null,required:!1},alignOffset:{type:Number,required:!1},avoidCollisions:{type:Boolean,required:!1},collisionBoundary:{type:null,required:!1},collisionPadding:{type:[Number,Object],required:!1},arrowPadding:{type:Number,required:!1},sticky:{type:String,required:!1},hideWhenDetached:{type:Boolean,required:!1},positionStrategy:{type:String,required:!1},updatePositionStrategy:{type:String,required:!1}},setup(t){const n=Ls(t),{forwardRef:r,currentElement:i}=Ce(),{trigger:o,onClose:s}=cr(),l=Li(),{isPointerInTransit:a,onPointerExit:c}=Ec(o,i);return l.isPointerInTransitRef=a,c(()=>{s()}),(u,d)=>(w(),K(Zs,Pe({ref:m(r)},m(n)),{default:M(()=>[ne(u.$slots,"default")]),_:3},16))}}),Td=Ed,Ad=U({__name:"TooltipContent",props:{forceMount:{type:Boolean,required:!1},ariaLabel:{type:String,required:!1},asChild:{type:Boolean,required:!1},as:{type:null,required:!1},side:{type:null,required:!1,default:"top"},sideOffset:{type:Number,required:!1},align:{type:null,required:!1},alignOffset:{type:Number,required:!1},avoidCollisions:{type:Boolean,required:!1},collisionBoundary:{type:null,required:!1},collisionPadding:{type:[Number,Object],required:!1},arrowPadding:{type:Number,required:!1},sticky:{type:String,required:!1},hideWhenDetached:{type:Boolean,required:!1},positionStrategy:{type:String,required:!1},updatePositionStrategy:{type:String,required:!1}},emits:["escapeKeyDown","pointerDownOutside"],setup(t,{emit:e}){const n=t,r=e,i=cr(),o=rr(n,r),{forwardRef:s}=Ce();return(l,a)=>(w(),K(m(Rs),{present:l.forceMount||m(i).open.value},{default:M(()=>[(w(),K(kt(m(i).disableHoverableContent.value?Zs:Td),Pe({ref:m(s)},m(o)),{default:M(()=>[ne(l.$slots,"default")]),_:3},16))]),_:3},8,["present"]))}}),Sd=Ad,Rd=U({__name:"TooltipPortal",props:{to:{type:null,required:!1},disabled:{type:Boolean,required:!1},defer:{type:Boolean,required:!1},forceMount:{type:Boolean,required:!1}},setup(t){const e=t;return(n,r)=>(w(),K(m(El),gn(_n(e)),{default:M(()=>[ne(n.$slots,"default")]),_:3},16))}}),Ld=Rd,Cd=U({__name:"TooltipTrigger",props:{reference:{type:null,required:!1},asChild:{type:Boolean,required:!1},as:{type:null,required:!1,default:"button"}},setup(t){const e=t,n=cr(),r=Li();n.contentId||=vi(void 0,"reka-tooltip-content");const{forwardRef:i,currentElement:o}=Ce(),s=j(!1),l=j(!1),a=$(()=>n.disabled.value?{}:{click:y,focus:f,pointermove:d,pointerleave:h,pointerdown:u,blur:g});dt(()=>{n.onTriggerChange(o.value)});function c(){setTimeout(()=>{s.value=!1},1)}function u(){n.open&&!n.disableClosingTrigger.value&&n.onClose(),s.value=!0,document.addEventListener("pointerup",c,{once:!0})}function d(x){x.pointerType!=="touch"&&!l.value&&!r.isPointerInTransitRef.value&&(n.onTriggerEnter(),l.value=!0)}function h(){n.onTriggerLeave(),l.value=!1}function f(x){s.value||n.ignoreNonKeyboardFocus.value&&!x.target.matches?.(":focus-visible")||n.onOpen()}function g(){n.onClose()}function y(){n.disableClosingTrigger.value||n.onClose()}return(x,v)=>(w(),K(m(jc),{"as-child":"",reference:x.reference},{default:M(()=>[R(m(nt),Pe({ref:m(i),"aria-describedby":m(n).open.value?m(n).contentId:void 0,"data-state":m(n).stateAttribute.value,as:x.as,"as-child":e.asChild,"data-grace-area-trigger":""},Ql(a.value)),{default:M(()=>[ne(x.$slots,"default")]),_:3},16,["aria-describedby","data-state","as","as-child"])]),_:3},8,["reference"]))}}),Pd=Cd;const Od={key:0,class:"flex flex-wrap items-center gap-3 text-sm"},Id={key:0,class:"flex items-center gap-1.5 text-muted-foreground"},Dd={key:1,class:"flex items-center gap-1.5 text-muted-foreground"},Nd=["href"],Md={key:4,class:"flex items-center gap-1.5 text-muted-foreground"},$d=U({__name:"Meta",props:{metadata:{}},setup(t){const e=t,n=$(()=>{const i=e.metadata.status?.toLowerCase();return i?i.includes("complete")||i.includes("done")||i.includes("progress")||i.includes("active")?"default":i.includes("draft")?"secondary":i.includes("blocked")||i.includes("paused")?"destructive":"secondary":"secondary"}),r=$(()=>e.metadata.author||e.metadata.date||e.metadata.status||e.metadata.shortcutStory);return(i,o)=>m(r)?(w(),A("div",Od,[t.metadata.author?(w(),A("div",Id,[R(m(xc),{class:"size-3.5"}),T("span",null,G(t.metadata.author),1)])):Y("",!0),t.metadata.date?(w(),A("div",Dd,[R(m(Vs),{class:"size-3.5"}),T("span",null,G(t.metadata.date),1)])):Y("",!0),t.metadata.status?(w(),K(m(Nt),{key:2,variant:m(n),class:"gap-1"},{default:M(()=>[R(m(oc),{class:"size-3"}),re(" "+G(t.metadata.status),1)]),_:1},8,["variant"])):Y("",!0),t.metadata.shortcutStory&&t.metadata.shortcutUrl?(w(),A("a",{key:3,href:t.metadata.shortcutUrl,target:"_blank",rel:"noopener noreferrer",class:"inline-flex items-center gap-1.5 text-primary hover:underline"},[R(m(xo),{class:"size-3.5"}),T("span",null,G(t.metadata.shortcutStory),1)],8,Nd)):t.metadata.shortcutStory?(w(),A("span",Md,[R(m(xo),{class:"size-3.5"}),T("span",null,G(t.metadata.shortcutStory),1)])):Y("",!0)])):Y("",!0)}}),Vd=Object.assign($d,{__name:"PrdMeta"});function Ci(){return{async:!1,breaks:!1,extensions:null,gfm:!0,hooks:null,pedantic:!1,renderer:null,silent:!1,tokenizer:null,walkTokens:null}}var xt=Ci();function ea(t){xt=t}var _t={exec:()=>null};function te(t,e=""){let n=typeof t=="string"?t:t.source,r={replace:(i,o)=>{let s=typeof o=="string"?o:o.source;return s=s.replace(Se.caret,"$1"),n=n.replace(i,s),r},getRegex:()=>new RegExp(n,e)};return r}var Bd=(()=>{try{return!!new RegExp("(?<=1)(?<!1)")}catch{return!1}})(),Se={codeRemoveIndent:/^(?: {1,4}| {0,3}\t)/gm,outputLinkReplace:/\\([\[\]])/g,indentCodeCompensation:/^(\s+)(?:```)/,beginningSpace:/^\s+/,endingHash:/#$/,startingSpaceChar:/^ /,endingSpaceChar:/ $/,nonSpaceChar:/[^ ]/,newLineCharGlobal:/\n/g,tabCharGlobal:/\t/g,multipleSpaceGlobal:/\s+/g,blankLine:/^[ \t]*$/,doubleBlankLine:/\n[ \t]*\n[ \t]*$/,blockquoteStart:/^ {0,3}>/,blockquoteSetextReplace:/\n {0,3}((?:=+|-+) *)(?=\n|$)/g,blockquoteSetextReplace2:/^ {0,3}>[ \t]?/gm,listReplaceNesting:/^ {1,4}(?=( {4})*[^ ])/g,listIsTask:/^\[[ xX]\] +\S/,listReplaceTask:/^\[[ xX]\] +/,listTaskCheckbox:/\[[ xX]\]/,anyLine:/\n.*\n/,hrefBrackets:/^<(.*)>$/,tableDelimiter:/[:|]/,tableAlignChars:/^\||\| *$/g,tableRowBlankLine:/\n[ \t]*$/,tableAlignRight:/^ *-+: *$/,tableAlignCenter:/^ *:-+: *$/,tableAlignLeft:/^ *:-+ *$/,startATag:/^<a /i,endATag:/^<\/a>/i,startPreScriptTag:/^<(pre|code|kbd|script)(\s|>)/i,endPreScriptTag:/^<\/(pre|code|kbd|script)(\s|>)/i,startAngleBracket:/^</,endAngleBracket:/>$/,pedanticHrefTitle:/^([^'"]*[^\s])\s+(['"])(.*)\2/,unicodeAlphaNumeric:/[\p{L}\p{N}]/u,escapeTest:/[&<>"']/,escapeReplace:/[&<>"']/g,escapeTestNoEncode:/[<>"']|&(?!(#\d{1,7}|#[Xx][a-fA-F0-9]{1,6}|\w+);)/,escapeReplaceNoEncode:/[<>"']|&(?!(#\d{1,7}|#[Xx][a-fA-F0-9]{1,6}|\w+);)/g,unescapeTest:/&(#(?:\d+)|(?:#x[0-9A-Fa-f]+)|(?:\w+));?/ig,caret:/(^|[^\[])\^/g,percentDecode:/%25/g,findPipe:/\|/g,splitPipe:/ \|/,slashPipe:/\\\|/g,carriageReturn:/\r\n|\r/g,spaceLine:/^ +$/gm,notSpaceStart:/^\S*/,endingNewline:/\n$/,listItemRegex:t=>new RegExp(`^( {0,3}${t})((?:[ ][^\\n]*)?(?:\\n|$))`),nextBulletRegex:t=>new RegExp(`^ {0,${Math.min(3,t-1)}}(?:[*+-]|\\d{1,9}[.)])((?:[ ][^\\n]*)?(?:\\n|$))`),hrRegex:t=>new RegExp(`^ {0,${Math.min(3,t-1)}}((?:- *){3,}|(?:_ *){3,}|(?:\\* *){3,})(?:\\n+|$)`),fencesBeginRegex:t=>new RegExp(`^ {0,${Math.min(3,t-1)}}(?:\`\`\`|~~~)`),headingBeginRegex:t=>new RegExp(`^ {0,${Math.min(3,t-1)}}#`),htmlBeginRegex:t=>new RegExp(`^ {0,${Math.min(3,t-1)}}<(?:[a-z].*>|!--)`,"i"),blockquoteBeginRegex:t=>new RegExp(`^ {0,${Math.min(3,t-1)}}>`)},zd=/^(?:[ \t]*(?:\n|$))+/,Fd=/^((?: {4}| {0,3}\t)[^\n]+(?:\n(?:[ \t]*(?:\n|$))*)?)+/,jd=/^ {0,3}(`{3,}(?=[^`\n]*(?:\n|$))|~{3,})([^\n]*)(?:\n|$)(?:|([\s\S]*?)(?:\n|$))(?: {0,3}\1[~`]* *(?=\n|$)|$)/,vn=/^ {0,3}((?:-[\t ]*){3,}|(?:_[ \t]*){3,}|(?:\*[ \t]*){3,})(?:\n+|$)/,qd=/^ {0,3}(#{1,6})(?=\s|$)(.*)(?:\n+|$)/,Pi=/ {0,3}(?:[*+-]|\d{1,9}[.)])/,ta=/^(?!bull |blockCode|fences|blockquote|heading|html|table)((?:.|\n(?!\s*?\n|bull |blockCode|fences|blockquote|heading|html|table))+?)\n {0,3}(=+|-+) *(?:\n+|$)/,na=te(ta).replace(/bull/g,Pi).replace(/blockCode/g,/(?: {4}| {0,3}\t)/).replace(/fences/g,/ {0,3}(?:`{3,}|~{3,})/).replace(/blockquote/g,/ {0,3}>/).replace(/heading/g,/ {0,3}#{1,6}/).replace(/html/g,/ {0,3}<[^\n>]+>\n/).replace(/\|table/g,"").getRegex(),Hd=te(ta).replace(/bull/g,Pi).replace(/blockCode/g,/(?: {4}| {0,3}\t)/).replace(/fences/g,/ {0,3}(?:`{3,}|~{3,})/).replace(/blockquote/g,/ {0,3}>/).replace(/heading/g,/ {0,3}#{1,6}/).replace(/html/g,/ {0,3}<[^\n>]+>\n/).replace(/table/g,/ {0,3}\|?(?:[:\- ]*\|)+[\:\- ]*\n/).getRegex(),Oi=/^([^\n]+(?:\n(?!hr|heading|lheading|blockquote|fences|list|html|table| +\n)[^\n]+)*)/,Gd=/^[^\n]+/,Ii=/(?!\s*\])(?:\\[\s\S]|[^\[\]\\])+/,Ud=te(/^ {0,3}\[(label)\]: *(?:\n[ \t]*)?([^<\s][^\s]*|<.*?>)(?:(?: +(?:\n[ \t]*)?| *\n[ \t]*)(title))? *(?:\n+|$)/).replace("label",Ii).replace("title",/(?:"(?:\\"?|[^"\\])*"|'[^'\n]*(?:\n[^'\n]+)*\n?'|\([^()]*\))/).getRegex(),Wd=te(/^(bull)([ \t][^\n]+?)?(?:\n|$)/).replace(/bull/g,Pi).getRegex(),ur="address|article|aside|base|basefont|blockquote|body|caption|center|col|colgroup|dd|details|dialog|dir|div|dl|dt|fieldset|figcaption|figure|footer|form|frame|frameset|h[1-6]|head|header|hr|html|iframe|legend|li|link|main|menu|menuitem|meta|nav|noframes|ol|optgroup|option|p|param|search|section|summary|table|tbody|td|tfoot|th|thead|title|tr|track|ul",Di=/<!--(?:-?>|[\s\S]*?(?:-->|$))/,Kd=te("^ {0,3}(?:<(script|pre|style|textarea)[\\s>][\\s\\S]*?(?:</\\1>[^\\n]*\\n+|$)|comment[^\\n]*(\\n+|$)|<\\?[\\s\\S]*?(?:\\?>\\n*|$)|<![A-Z][\\s\\S]*?(?:>\\n*|$)|<!\\[CDATA\\[[\\s\\S]*?(?:\\]\\]>\\n*|$)|</?(tag)(?: +|\\n|/?>)[\\s\\S]*?(?:(?:\\n[ ]*)+\\n|$)|<(?!script|pre|style|textarea)([a-z][\\w-]*)(?:attribute)*? */?>(?=[ \\t]*(?:\\n|$))[\\s\\S]*?(?:(?:\\n[ ]*)+\\n|$)|</(?!script|pre|style|textarea)[a-z][\\w-]*\\s*>(?=[ \\t]*(?:\\n|$))[\\s\\S]*?(?:(?:\\n[ ]*)+\\n|$))","i").replace("comment",Di).replace("tag",ur).replace("attribute",/ +[a-zA-Z:_][\w.:-]*(?: *= *"[^"\n]*"| *= *'[^'\n]*'| *= *[^\s"'=<>`]+)?/).getRegex(),ra=te(Oi).replace("hr",vn).replace("heading"," {0,3}#{1,6}(?:\\s|$)").replace("|lheading","").replace("|table","").replace("blockquote"," {0,3}>").replace("fences"," {0,3}(?:`{3,}(?=[^`\\n]*\\n)|~{3,})[^\\n]*\\n").replace("list"," {0,3}(?:[*+-]|1[.)])[ \\t]").replace("html","</?(?:tag)(?: +|\\n|/?>)|<(?:script|pre|style|textarea|!--)").replace("tag",ur).getRegex(),Xd=te(/^( {0,3}> ?(paragraph|[^\n]*)(?:\n|$))+/).replace("paragraph",ra).getRegex(),Ni={blockquote:Xd,code:Fd,def:Ud,fences:jd,heading:qd,hr:vn,html:Kd,lheading:na,list:Wd,newline:zd,paragraph:ra,table:_t,text:Gd},No=te("^ *([^\\n ].*)\\n {0,3}((?:\\| *)?:?-+:? *(?:\\| *:?-+:? *)*(?:\\| *)?)(?:\\n((?:(?! *\\n|hr|heading|blockquote|code|fences|list|html).*(?:\\n|$))*)\\n*|$)").replace("hr",vn).replace("heading"," {0,3}#{1,6}(?:\\s|$)").replace("blockquote"," {0,3}>").replace("code","(?: {4}| {0,3} )[^\\n]").replace("fences"," {0,3}(?:`{3,}(?=[^`\\n]*\\n)|~{3,})[^\\n]*\\n").replace("list"," {0,3}(?:[*+-]|1[.)])[ \\t]").replace("html","</?(?:tag)(?: +|\\n|/?>)|<(?:script|pre|style|textarea|!--)").replace("tag",ur).getRegex(),Yd={...Ni,lheading:Hd,table:No,paragraph:te(Oi).replace("hr",vn).replace("heading"," {0,3}#{1,6}(?:\\s|$)").replace("|lheading","").replace("table",No).replace("blockquote"," {0,3}>").replace("fences"," {0,3}(?:`{3,}(?=[^`\\n]*\\n)|~{3,})[^\\n]*\\n").replace("list"," {0,3}(?:[*+-]|1[.)])[ \\t]").replace("html","</?(?:tag)(?: +|\\n|/?>)|<(?:script|pre|style|textarea|!--)").replace("tag",ur).getRegex()},Qd={...Ni,html:te(`^ *(?:comment *(?:\\n|\\s*$)|<(tag)[\\s\\S]+?</\\1> *(?:\\n{2,}|\\s*$)|<tag(?:"[^"]*"|'[^']*'|\\s[^'"/>\\s]*)*?/?> *(?:\\n{2,}|\\s*$))`).replace("comment",Di).replace(/tag/g,"(?!(?:a|em|strong|small|s|cite|q|dfn|abbr|data|time|code|var|samp|kbd|sub|sup|i|b|u|mark|ruby|rt|rp|bdi|bdo|span|br|wbr|ins|del|img)\\b)\\w+(?!:|[^\\w\\s@]*@)\\b").getRegex(),def:/^ *\[([^\]]+)\]: *<?([^\s>]+)>?(?: +(["(][^\n]+[")]))? *(?:\n+|$)/,heading:/^(#{1,6})(.*)(?:\n+|$)/,fences:_t,lheading:/^(.+?)\n {0,3}(=+|-+) *(?:\n+|$)/,paragraph:te(Oi).replace("hr",vn).replace("heading",` *#{1,6} *[^
3
- ]`).replace("lheading",na).replace("|table","").replace("blockquote"," {0,3}>").replace("|fences","").replace("|list","").replace("|html","").replace("|tag","").getRegex()},Jd=/^\\([!"#$%&'()*+,\-./:;<=>?@\[\]\\^_`{|}~])/,Zd=/^(`+)([^`]|[^`][\s\S]*?[^`])\1(?!`)/,ia=/^( {2,}|\\)\n(?!\s*$)/,ep=/^(`+|[^`])(?:(?= {2,}\n)|[\s\S]*?(?:(?=[\\<!\[`*_]|\b_|$)|[^ ](?= {2,}\n)))/,dr=/[\p{P}\p{S}]/u,Mi=/[\s\p{P}\p{S}]/u,oa=/[^\s\p{P}\p{S}]/u,tp=te(/^((?![*_])punctSpace)/,"u").replace(/punctSpace/g,Mi).getRegex(),sa=/(?!~)[\p{P}\p{S}]/u,np=/(?!~)[\s\p{P}\p{S}]/u,rp=/(?:[^\s\p{P}\p{S}]|~)/u,aa=/(?![*_])[\p{P}\p{S}]/u,ip=/(?![*_])[\s\p{P}\p{S}]/u,op=/(?:[^\s\p{P}\p{S}]|[*_])/u,sp=te(/link|precode-code|html/,"g").replace("link",/\[(?:[^\[\]`]|(?<a>`+)[^`]+\k<a>(?!`))*?\]\((?:\\[\s\S]|[^\\\(\)]|\((?:\\[\s\S]|[^\\\(\)])*\))*\)/).replace("precode-",Bd?"(?<!`)()":"(^^|[^`])").replace("code",/(?<b>`+)[^`]+\k<b>(?!`)/).replace("html",/<(?! )[^<>]*?>/).getRegex(),la=/^(?:\*+(?:((?!\*)punct)|[^\s*]))|^_+(?:((?!_)punct)|([^\s_]))/,ap=te(la,"u").replace(/punct/g,dr).getRegex(),lp=te(la,"u").replace(/punct/g,sa).getRegex(),ca="^[^_*]*?__[^_*]*?\\*[^_*]*?(?=__)|[^*]+(?=[^*])|(?!\\*)punct(\\*+)(?=[\\s]|$)|notPunctSpace(\\*+)(?!\\*)(?=punctSpace|$)|(?!\\*)punctSpace(\\*+)(?=notPunctSpace)|[\\s](\\*+)(?!\\*)(?=punct)|(?!\\*)punct(\\*+)(?!\\*)(?=punct)|notPunctSpace(\\*+)(?=notPunctSpace)",cp=te(ca,"gu").replace(/notPunctSpace/g,oa).replace(/punctSpace/g,Mi).replace(/punct/g,dr).getRegex(),up=te(ca,"gu").replace(/notPunctSpace/g,rp).replace(/punctSpace/g,np).replace(/punct/g,sa).getRegex(),dp=te("^[^_*]*?\\*\\*[^_*]*?_[^_*]*?(?=\\*\\*)|[^_]+(?=[^_])|(?!_)punct(_+)(?=[\\s]|$)|notPunctSpace(_+)(?!_)(?=punctSpace|$)|(?!_)punctSpace(_+)(?=notPunctSpace)|[\\s](_+)(?!_)(?=punct)|(?!_)punct(_+)(?!_)(?=punct)","gu").replace(/notPunctSpace/g,oa).replace(/punctSpace/g,Mi).replace(/punct/g,dr).getRegex(),pp=te(/^~~?(?:((?!~)punct)|[^\s~])/,"u").replace(/punct/g,aa).getRegex(),mp="^[^~]+(?=[^~])|(?!~)punct(~~?)(?=[\\s]|$)|notPunctSpace(~~?)(?!~)(?=punctSpace|$)|(?!~)punctSpace(~~?)(?=notPunctSpace)|[\\s](~~?)(?!~)(?=punct)|(?!~)punct(~~?)(?!~)(?=punct)|notPunctSpace(~~?)(?=notPunctSpace)",fp=te(mp,"gu").replace(/notPunctSpace/g,op).replace(/punctSpace/g,ip).replace(/punct/g,aa).getRegex(),hp=te(/\\(punct)/,"gu").replace(/punct/g,dr).getRegex(),gp=te(/^<(scheme:[^\s\x00-\x1f<>]*|email)>/).replace("scheme",/[a-zA-Z][a-zA-Z0-9+.-]{1,31}/).replace("email",/[a-zA-Z0-9.!#$%&'*+/=?^_`{|}~-]+(@)[a-zA-Z0-9](?:[a-zA-Z0-9-]{0,61}[a-zA-Z0-9])?(?:\.[a-zA-Z0-9](?:[a-zA-Z0-9-]{0,61}[a-zA-Z0-9])?)+(?![-_])/).getRegex(),_p=te(Di).replace("(?:-->|$)","-->").getRegex(),yp=te("^comment|^</[a-zA-Z][\\w:-]*\\s*>|^<[a-zA-Z][\\w-]*(?:attribute)*?\\s*/?>|^<\\?[\\s\\S]*?\\?>|^<![a-zA-Z]+\\s[\\s\\S]*?>|^<!\\[CDATA\\[[\\s\\S]*?\\]\\]>").replace("comment",_p).replace("attribute",/\s+[a-zA-Z:_][\w.:-]*(?:\s*=\s*"[^"]*"|\s*=\s*'[^']*'|\s*=\s*[^\s"'=<>`]+)?/).getRegex(),Hn=/(?:\[(?:\\[\s\S]|[^\[\]\\])*\]|\\[\s\S]|`+[^`]*?`+(?!`)|[^\[\]\\`])*?/,vp=te(/^!?\[(label)\]\(\s*(href)(?:(?:[ \t]*(?:\n[ \t]*)?)(title))?\s*\)/).replace("label",Hn).replace("href",/<(?:\\.|[^\n<>\\])+>|[^ \t\n\x00-\x1f]*/).replace("title",/"(?:\\"?|[^"\\])*"|'(?:\\'?|[^'\\])*'|\((?:\\\)?|[^)\\])*\)/).getRegex(),ua=te(/^!?\[(label)\]\[(ref)\]/).replace("label",Hn).replace("ref",Ii).getRegex(),da=te(/^!?\[(ref)\](?:\[\])?/).replace("ref",Ii).getRegex(),bp=te("reflink|nolink(?!\\()","g").replace("reflink",ua).replace("nolink",da).getRegex(),Mo=/[hH][tT][tT][pP][sS]?|[fF][tT][pP]/,$i={_backpedal:_t,anyPunctuation:hp,autolink:gp,blockSkip:sp,br:ia,code:Zd,del:_t,delLDelim:_t,delRDelim:_t,emStrongLDelim:ap,emStrongRDelimAst:cp,emStrongRDelimUnd:dp,escape:Jd,link:vp,nolink:da,punctuation:tp,reflink:ua,reflinkSearch:bp,tag:yp,text:ep,url:_t},kp={...$i,link:te(/^!?\[(label)\]\((.*?)\)/).replace("label",Hn).getRegex(),reflink:te(/^!?\[(label)\]\s*\[([^\]]*)\]/).replace("label",Hn).getRegex()},ti={...$i,emStrongRDelimAst:up,emStrongLDelim:lp,delLDelim:pp,delRDelim:fp,url:te(/^((?:protocol):\/\/|www\.)(?:[a-zA-Z0-9\-]+\.?)+[^\s<]*|^email/).replace("protocol",Mo).replace("email",/[A-Za-z0-9._+-]+(@)[a-zA-Z0-9-_]+(?:\.[a-zA-Z0-9-_]*[a-zA-Z0-9])+(?![-_])/).getRegex(),_backpedal:/(?:[^?!.,:;*_'"~()&]+|\([^)]*\)|&(?![a-zA-Z0-9]+;$)|[?!.,:;*_'"~)]+(?!$))+/,del:/^(~~?)(?=[^\s~])((?:\\[\s\S]|[^\\])*?(?:\\[\s\S]|[^\s~\\]))\1(?=[^~]|$)/,text:te(/^([`~]+|[^`~])(?:(?= {2,}\n)|(?=[a-zA-Z0-9.!#$%&'*+\/=?_`{\|}~-]+@)|[\s\S]*?(?:(?=[\\<!\[`*~_]|\b_|protocol:\/\/|www\.|$)|[^ ](?= {2,}\n)|[^a-zA-Z0-9.!#$%&'*+\/=?_`{\|}~-](?=[a-zA-Z0-9.!#$%&'*+\/=?_`{\|}~-]+@)))/).replace("protocol",Mo).getRegex()},wp={...ti,br:te(ia).replace("{2,}","*").getRegex(),text:te(ti.text).replace("\\b_","\\b_| {2,}\\n").replace(/\{2,\}/g,"*").getRegex()},Pn={normal:Ni,gfm:Yd,pedantic:Qd},Xt={normal:$i,gfm:ti,breaks:wp,pedantic:kp},xp={"&":"&amp;","<":"&lt;",">":"&gt;",'"':"&quot;","'":"&#39;"},$o=t=>xp[t];function Xe(t,e){if(e){if(Se.escapeTest.test(t))return t.replace(Se.escapeReplace,$o)}else if(Se.escapeTestNoEncode.test(t))return t.replace(Se.escapeReplaceNoEncode,$o);return t}function Vo(t){try{t=encodeURI(t).replace(Se.percentDecode,"%")}catch{return null}return t}function Bo(t,e){let n=t.replace(Se.findPipe,(o,s,l)=>{let a=!1,c=s;for(;--c>=0&&l[c]==="\\";)a=!a;return a?"|":" |"}),r=n.split(Se.splitPipe),i=0;if(r[0].trim()||r.shift(),r.length>0&&!r.at(-1)?.trim()&&r.pop(),e)if(r.length>e)r.splice(e);else for(;r.length<e;)r.push("");for(;i<r.length;i++)r[i]=r[i].trim().replace(Se.slashPipe,"|");return r}function Yt(t,e,n){let r=t.length;if(r===0)return"";let i=0;for(;i<r&&t.charAt(r-i-1)===e;)i++;return t.slice(0,r-i)}function Ep(t,e){if(t.indexOf(e[1])===-1)return-1;let n=0;for(let r=0;r<t.length;r++)if(t[r]==="\\")r++;else if(t[r]===e[0])n++;else if(t[r]===e[1]&&(n--,n<0))return r;return n>0?-2:-1}function Tp(t,e=0){let n=e,r="";for(let i of t)if(i===" "){let o=4-n%4;r+=" ".repeat(o),n+=o}else r+=i,n++;return r}function zo(t,e,n,r,i){let o=e.href,s=e.title||null,l=t[1].replace(i.other.outputLinkReplace,"$1");r.state.inLink=!0;let a={type:t[0].charAt(0)==="!"?"image":"link",raw:n,href:o,title:s,text:l,tokens:r.inlineTokens(l)};return r.state.inLink=!1,a}function Ap(t,e,n){let r=t.match(n.other.indentCodeCompensation);if(r===null)return e;let i=r[1];return e.split(`
4
- `).map(o=>{let s=o.match(n.other.beginningSpace);if(s===null)return o;let[l]=s;return l.length>=i.length?o.slice(i.length):o}).join(`
5
- `)}var Gn=class{options;rules;lexer;constructor(t){this.options=t||xt}space(t){let e=this.rules.block.newline.exec(t);if(e&&e[0].length>0)return{type:"space",raw:e[0]}}code(t){let e=this.rules.block.code.exec(t);if(e){let n=e[0].replace(this.rules.other.codeRemoveIndent,"");return{type:"code",raw:e[0],codeBlockStyle:"indented",text:this.options.pedantic?n:Yt(n,`
6
- `)}}}fences(t){let e=this.rules.block.fences.exec(t);if(e){let n=e[0],r=Ap(n,e[3]||"",this.rules);return{type:"code",raw:n,lang:e[2]?e[2].trim().replace(this.rules.inline.anyPunctuation,"$1"):e[2],text:r}}}heading(t){let e=this.rules.block.heading.exec(t);if(e){let n=e[2].trim();if(this.rules.other.endingHash.test(n)){let r=Yt(n,"#");(this.options.pedantic||!r||this.rules.other.endingSpaceChar.test(r))&&(n=r.trim())}return{type:"heading",raw:e[0],depth:e[1].length,text:n,tokens:this.lexer.inline(n)}}}hr(t){let e=this.rules.block.hr.exec(t);if(e)return{type:"hr",raw:Yt(e[0],`
7
- `)}}blockquote(t){let e=this.rules.block.blockquote.exec(t);if(e){let n=Yt(e[0],`
8
- `).split(`
9
- `),r="",i="",o=[];for(;n.length>0;){let s=!1,l=[],a;for(a=0;a<n.length;a++)if(this.rules.other.blockquoteStart.test(n[a]))l.push(n[a]),s=!0;else if(!s)l.push(n[a]);else break;n=n.slice(a);let c=l.join(`
10
- `),u=c.replace(this.rules.other.blockquoteSetextReplace,`
11
- $1`).replace(this.rules.other.blockquoteSetextReplace2,"");r=r?`${r}
12
- ${c}`:c,i=i?`${i}
13
- ${u}`:u;let d=this.lexer.state.top;if(this.lexer.state.top=!0,this.lexer.blockTokens(u,o,!0),this.lexer.state.top=d,n.length===0)break;let h=o.at(-1);if(h?.type==="code")break;if(h?.type==="blockquote"){let f=h,g=f.raw+`
14
- `+n.join(`
15
- `),y=this.blockquote(g);o[o.length-1]=y,r=r.substring(0,r.length-f.raw.length)+y.raw,i=i.substring(0,i.length-f.text.length)+y.text;break}else if(h?.type==="list"){let f=h,g=f.raw+`
16
- `+n.join(`
17
- `),y=this.list(g);o[o.length-1]=y,r=r.substring(0,r.length-h.raw.length)+y.raw,i=i.substring(0,i.length-f.raw.length)+y.raw,n=g.substring(o.at(-1).raw.length).split(`
18
- `);continue}}return{type:"blockquote",raw:r,tokens:o,text:i}}}list(t){let e=this.rules.block.list.exec(t);if(e){let n=e[1].trim(),r=n.length>1,i={type:"list",raw:"",ordered:r,start:r?+n.slice(0,-1):"",loose:!1,items:[]};n=r?`\\d{1,9}\\${n.slice(-1)}`:`\\${n}`,this.options.pedantic&&(n=r?n:"[*+-]");let o=this.rules.other.listItemRegex(n),s=!1;for(;t;){let a=!1,c="",u="";if(!(e=o.exec(t))||this.rules.block.hr.test(t))break;c=e[0],t=t.substring(c.length);let d=Tp(e[2].split(`
19
- `,1)[0],e[1].length),h=t.split(`
20
- `,1)[0],f=!d.trim(),g=0;if(this.options.pedantic?(g=2,u=d.trimStart()):f?g=e[1].length+1:(g=d.search(this.rules.other.nonSpaceChar),g=g>4?1:g,u=d.slice(g),g+=e[1].length),f&&this.rules.other.blankLine.test(h)&&(c+=h+`
21
- `,t=t.substring(h.length+1),a=!0),!a){let y=this.rules.other.nextBulletRegex(g),x=this.rules.other.hrRegex(g),v=this.rules.other.fencesBeginRegex(g),k=this.rules.other.headingBeginRegex(g),b=this.rules.other.htmlBeginRegex(g),E=this.rules.other.blockquoteBeginRegex(g);for(;t;){let P=t.split(`
22
- `,1)[0],V;if(h=P,this.options.pedantic?(h=h.replace(this.rules.other.listReplaceNesting," "),V=h):V=h.replace(this.rules.other.tabCharGlobal," "),v.test(h)||k.test(h)||b.test(h)||E.test(h)||y.test(h)||x.test(h))break;if(V.search(this.rules.other.nonSpaceChar)>=g||!h.trim())u+=`
23
- `+V.slice(g);else{if(f||d.replace(this.rules.other.tabCharGlobal," ").search(this.rules.other.nonSpaceChar)>=4||v.test(d)||k.test(d)||x.test(d))break;u+=`
24
- `+h}f=!h.trim(),c+=P+`
25
- `,t=t.substring(P.length+1),d=V.slice(g)}}i.loose||(s?i.loose=!0:this.rules.other.doubleBlankLine.test(c)&&(s=!0)),i.items.push({type:"list_item",raw:c,task:!!this.options.gfm&&this.rules.other.listIsTask.test(u),loose:!1,text:u,tokens:[]}),i.raw+=c}let l=i.items.at(-1);if(l)l.raw=l.raw.trimEnd(),l.text=l.text.trimEnd();else return;i.raw=i.raw.trimEnd();for(let a of i.items){if(this.lexer.state.top=!1,a.tokens=this.lexer.blockTokens(a.text,[]),a.task){if(a.text=a.text.replace(this.rules.other.listReplaceTask,""),a.tokens[0]?.type==="text"||a.tokens[0]?.type==="paragraph"){a.tokens[0].raw=a.tokens[0].raw.replace(this.rules.other.listReplaceTask,""),a.tokens[0].text=a.tokens[0].text.replace(this.rules.other.listReplaceTask,"");for(let u=this.lexer.inlineQueue.length-1;u>=0;u--)if(this.rules.other.listIsTask.test(this.lexer.inlineQueue[u].src)){this.lexer.inlineQueue[u].src=this.lexer.inlineQueue[u].src.replace(this.rules.other.listReplaceTask,"");break}}let c=this.rules.other.listTaskCheckbox.exec(a.raw);if(c){let u={type:"checkbox",raw:c[0]+" ",checked:c[0]!=="[ ]"};a.checked=u.checked,i.loose?a.tokens[0]&&["paragraph","text"].includes(a.tokens[0].type)&&"tokens"in a.tokens[0]&&a.tokens[0].tokens?(a.tokens[0].raw=u.raw+a.tokens[0].raw,a.tokens[0].text=u.raw+a.tokens[0].text,a.tokens[0].tokens.unshift(u)):a.tokens.unshift({type:"paragraph",raw:u.raw,text:u.raw,tokens:[u]}):a.tokens.unshift(u)}}if(!i.loose){let c=a.tokens.filter(d=>d.type==="space"),u=c.length>0&&c.some(d=>this.rules.other.anyLine.test(d.raw));i.loose=u}}if(i.loose)for(let a of i.items){a.loose=!0;for(let c of a.tokens)c.type==="text"&&(c.type="paragraph")}return i}}html(t){let e=this.rules.block.html.exec(t);if(e)return{type:"html",block:!0,raw:e[0],pre:e[1]==="pre"||e[1]==="script"||e[1]==="style",text:e[0]}}def(t){let e=this.rules.block.def.exec(t);if(e){let n=e[1].toLowerCase().replace(this.rules.other.multipleSpaceGlobal," "),r=e[2]?e[2].replace(this.rules.other.hrefBrackets,"$1").replace(this.rules.inline.anyPunctuation,"$1"):"",i=e[3]?e[3].substring(1,e[3].length-1).replace(this.rules.inline.anyPunctuation,"$1"):e[3];return{type:"def",tag:n,raw:e[0],href:r,title:i}}}table(t){let e=this.rules.block.table.exec(t);if(!e||!this.rules.other.tableDelimiter.test(e[2]))return;let n=Bo(e[1]),r=e[2].replace(this.rules.other.tableAlignChars,"").split("|"),i=e[3]?.trim()?e[3].replace(this.rules.other.tableRowBlankLine,"").split(`
26
- `):[],o={type:"table",raw:e[0],header:[],align:[],rows:[]};if(n.length===r.length){for(let s of r)this.rules.other.tableAlignRight.test(s)?o.align.push("right"):this.rules.other.tableAlignCenter.test(s)?o.align.push("center"):this.rules.other.tableAlignLeft.test(s)?o.align.push("left"):o.align.push(null);for(let s=0;s<n.length;s++)o.header.push({text:n[s],tokens:this.lexer.inline(n[s]),header:!0,align:o.align[s]});for(let s of i)o.rows.push(Bo(s,o.header.length).map((l,a)=>({text:l,tokens:this.lexer.inline(l),header:!1,align:o.align[a]})));return o}}lheading(t){let e=this.rules.block.lheading.exec(t);if(e)return{type:"heading",raw:e[0],depth:e[2].charAt(0)==="="?1:2,text:e[1],tokens:this.lexer.inline(e[1])}}paragraph(t){let e=this.rules.block.paragraph.exec(t);if(e){let n=e[1].charAt(e[1].length-1)===`
27
- `?e[1].slice(0,-1):e[1];return{type:"paragraph",raw:e[0],text:n,tokens:this.lexer.inline(n)}}}text(t){let e=this.rules.block.text.exec(t);if(e)return{type:"text",raw:e[0],text:e[0],tokens:this.lexer.inline(e[0])}}escape(t){let e=this.rules.inline.escape.exec(t);if(e)return{type:"escape",raw:e[0],text:e[1]}}tag(t){let e=this.rules.inline.tag.exec(t);if(e)return!this.lexer.state.inLink&&this.rules.other.startATag.test(e[0])?this.lexer.state.inLink=!0:this.lexer.state.inLink&&this.rules.other.endATag.test(e[0])&&(this.lexer.state.inLink=!1),!this.lexer.state.inRawBlock&&this.rules.other.startPreScriptTag.test(e[0])?this.lexer.state.inRawBlock=!0:this.lexer.state.inRawBlock&&this.rules.other.endPreScriptTag.test(e[0])&&(this.lexer.state.inRawBlock=!1),{type:"html",raw:e[0],inLink:this.lexer.state.inLink,inRawBlock:this.lexer.state.inRawBlock,block:!1,text:e[0]}}link(t){let e=this.rules.inline.link.exec(t);if(e){let n=e[2].trim();if(!this.options.pedantic&&this.rules.other.startAngleBracket.test(n)){if(!this.rules.other.endAngleBracket.test(n))return;let o=Yt(n.slice(0,-1),"\\");if((n.length-o.length)%2===0)return}else{let o=Ep(e[2],"()");if(o===-2)return;if(o>-1){let s=(e[0].indexOf("!")===0?5:4)+e[1].length+o;e[2]=e[2].substring(0,o),e[0]=e[0].substring(0,s).trim(),e[3]=""}}let r=e[2],i="";if(this.options.pedantic){let o=this.rules.other.pedanticHrefTitle.exec(r);o&&(r=o[1],i=o[3])}else i=e[3]?e[3].slice(1,-1):"";return r=r.trim(),this.rules.other.startAngleBracket.test(r)&&(this.options.pedantic&&!this.rules.other.endAngleBracket.test(n)?r=r.slice(1):r=r.slice(1,-1)),zo(e,{href:r&&r.replace(this.rules.inline.anyPunctuation,"$1"),title:i&&i.replace(this.rules.inline.anyPunctuation,"$1")},e[0],this.lexer,this.rules)}}reflink(t,e){let n;if((n=this.rules.inline.reflink.exec(t))||(n=this.rules.inline.nolink.exec(t))){let r=(n[2]||n[1]).replace(this.rules.other.multipleSpaceGlobal," "),i=e[r.toLowerCase()];if(!i){let o=n[0].charAt(0);return{type:"text",raw:o,text:o}}return zo(n,i,n[0],this.lexer,this.rules)}}emStrong(t,e,n=""){let r=this.rules.inline.emStrongLDelim.exec(t);if(!(!r||r[3]&&n.match(this.rules.other.unicodeAlphaNumeric))&&(!(r[1]||r[2])||!n||this.rules.inline.punctuation.exec(n))){let i=[...r[0]].length-1,o,s,l=i,a=0,c=r[0][0]==="*"?this.rules.inline.emStrongRDelimAst:this.rules.inline.emStrongRDelimUnd;for(c.lastIndex=0,e=e.slice(-1*t.length+i);(r=c.exec(e))!=null;){if(o=r[1]||r[2]||r[3]||r[4]||r[5]||r[6],!o)continue;if(s=[...o].length,r[3]||r[4]){l+=s;continue}else if((r[5]||r[6])&&i%3&&!((i+s)%3)){a+=s;continue}if(l-=s,l>0)continue;s=Math.min(s,s+l+a);let u=[...r[0]][0].length,d=t.slice(0,i+r.index+u+s);if(Math.min(i,s)%2){let f=d.slice(1,-1);return{type:"em",raw:d,text:f,tokens:this.lexer.inlineTokens(f)}}let h=d.slice(2,-2);return{type:"strong",raw:d,text:h,tokens:this.lexer.inlineTokens(h)}}}}codespan(t){let e=this.rules.inline.code.exec(t);if(e){let n=e[2].replace(this.rules.other.newLineCharGlobal," "),r=this.rules.other.nonSpaceChar.test(n),i=this.rules.other.startingSpaceChar.test(n)&&this.rules.other.endingSpaceChar.test(n);return r&&i&&(n=n.substring(1,n.length-1)),{type:"codespan",raw:e[0],text:n}}}br(t){let e=this.rules.inline.br.exec(t);if(e)return{type:"br",raw:e[0]}}del(t,e,n=""){let r=this.rules.inline.delLDelim.exec(t);if(r&&(!r[1]||!n||this.rules.inline.punctuation.exec(n))){let i=[...r[0]].length-1,o,s,l=i,a=this.rules.inline.delRDelim;for(a.lastIndex=0,e=e.slice(-1*t.length+i);(r=a.exec(e))!=null;){if(o=r[1]||r[2]||r[3]||r[4]||r[5]||r[6],!o||(s=[...o].length,s!==i))continue;if(r[3]||r[4]){l+=s;continue}if(l-=s,l>0)continue;s=Math.min(s,s+l);let c=[...r[0]][0].length,u=t.slice(0,i+r.index+c+s),d=u.slice(i,-i);return{type:"del",raw:u,text:d,tokens:this.lexer.inlineTokens(d)}}}}autolink(t){let e=this.rules.inline.autolink.exec(t);if(e){let n,r;return e[2]==="@"?(n=e[1],r="mailto:"+n):(n=e[1],r=n),{type:"link",raw:e[0],text:n,href:r,tokens:[{type:"text",raw:n,text:n}]}}}url(t){let e;if(e=this.rules.inline.url.exec(t)){let n,r;if(e[2]==="@")n=e[0],r="mailto:"+n;else{let i;do i=e[0],e[0]=this.rules.inline._backpedal.exec(e[0])?.[0]??"";while(i!==e[0]);n=e[0],e[1]==="www."?r="http://"+e[0]:r=e[0]}return{type:"link",raw:e[0],text:n,href:r,tokens:[{type:"text",raw:n,text:n}]}}}inlineText(t){let e=this.rules.inline.text.exec(t);if(e){let n=this.lexer.state.inRawBlock;return{type:"text",raw:e[0],text:e[0],escaped:n}}}},je=class ni{tokens;options;state;inlineQueue;tokenizer;constructor(e){this.tokens=[],this.tokens.links=Object.create(null),this.options=e||xt,this.options.tokenizer=this.options.tokenizer||new Gn,this.tokenizer=this.options.tokenizer,this.tokenizer.options=this.options,this.tokenizer.lexer=this,this.inlineQueue=[],this.state={inLink:!1,inRawBlock:!1,top:!0};let n={other:Se,block:Pn.normal,inline:Xt.normal};this.options.pedantic?(n.block=Pn.pedantic,n.inline=Xt.pedantic):this.options.gfm&&(n.block=Pn.gfm,this.options.breaks?n.inline=Xt.breaks:n.inline=Xt.gfm),this.tokenizer.rules=n}static get rules(){return{block:Pn,inline:Xt}}static lex(e,n){return new ni(n).lex(e)}static lexInline(e,n){return new ni(n).inlineTokens(e)}lex(e){e=e.replace(Se.carriageReturn,`
28
- `),this.blockTokens(e,this.tokens);for(let n=0;n<this.inlineQueue.length;n++){let r=this.inlineQueue[n];this.inlineTokens(r.src,r.tokens)}return this.inlineQueue=[],this.tokens}blockTokens(e,n=[],r=!1){for(this.options.pedantic&&(e=e.replace(Se.tabCharGlobal," ").replace(Se.spaceLine,""));e;){let i;if(this.options.extensions?.block?.some(s=>(i=s.call({lexer:this},e,n))?(e=e.substring(i.raw.length),n.push(i),!0):!1))continue;if(i=this.tokenizer.space(e)){e=e.substring(i.raw.length);let s=n.at(-1);i.raw.length===1&&s!==void 0?s.raw+=`
29
- `:n.push(i);continue}if(i=this.tokenizer.code(e)){e=e.substring(i.raw.length);let s=n.at(-1);s?.type==="paragraph"||s?.type==="text"?(s.raw+=(s.raw.endsWith(`
30
- `)?"":`
31
- `)+i.raw,s.text+=`
32
- `+i.text,this.inlineQueue.at(-1).src=s.text):n.push(i);continue}if(i=this.tokenizer.fences(e)){e=e.substring(i.raw.length),n.push(i);continue}if(i=this.tokenizer.heading(e)){e=e.substring(i.raw.length),n.push(i);continue}if(i=this.tokenizer.hr(e)){e=e.substring(i.raw.length),n.push(i);continue}if(i=this.tokenizer.blockquote(e)){e=e.substring(i.raw.length),n.push(i);continue}if(i=this.tokenizer.list(e)){e=e.substring(i.raw.length),n.push(i);continue}if(i=this.tokenizer.html(e)){e=e.substring(i.raw.length),n.push(i);continue}if(i=this.tokenizer.def(e)){e=e.substring(i.raw.length);let s=n.at(-1);s?.type==="paragraph"||s?.type==="text"?(s.raw+=(s.raw.endsWith(`
33
- `)?"":`
34
- `)+i.raw,s.text+=`
35
- `+i.raw,this.inlineQueue.at(-1).src=s.text):this.tokens.links[i.tag]||(this.tokens.links[i.tag]={href:i.href,title:i.title},n.push(i));continue}if(i=this.tokenizer.table(e)){e=e.substring(i.raw.length),n.push(i);continue}if(i=this.tokenizer.lheading(e)){e=e.substring(i.raw.length),n.push(i);continue}let o=e;if(this.options.extensions?.startBlock){let s=1/0,l=e.slice(1),a;this.options.extensions.startBlock.forEach(c=>{a=c.call({lexer:this},l),typeof a=="number"&&a>=0&&(s=Math.min(s,a))}),s<1/0&&s>=0&&(o=e.substring(0,s+1))}if(this.state.top&&(i=this.tokenizer.paragraph(o))){let s=n.at(-1);r&&s?.type==="paragraph"?(s.raw+=(s.raw.endsWith(`
36
- `)?"":`
37
- `)+i.raw,s.text+=`
38
- `+i.text,this.inlineQueue.pop(),this.inlineQueue.at(-1).src=s.text):n.push(i),r=o.length!==e.length,e=e.substring(i.raw.length);continue}if(i=this.tokenizer.text(e)){e=e.substring(i.raw.length);let s=n.at(-1);s?.type==="text"?(s.raw+=(s.raw.endsWith(`
39
- `)?"":`
40
- `)+i.raw,s.text+=`
41
- `+i.text,this.inlineQueue.pop(),this.inlineQueue.at(-1).src=s.text):n.push(i);continue}if(e){let s="Infinite loop on byte: "+e.charCodeAt(0);if(this.options.silent){console.error(s);break}else throw new Error(s)}}return this.state.top=!0,n}inline(e,n=[]){return this.inlineQueue.push({src:e,tokens:n}),n}inlineTokens(e,n=[]){let r=e,i=null;if(this.tokens.links){let a=Object.keys(this.tokens.links);if(a.length>0)for(;(i=this.tokenizer.rules.inline.reflinkSearch.exec(r))!=null;)a.includes(i[0].slice(i[0].lastIndexOf("[")+1,-1))&&(r=r.slice(0,i.index)+"["+"a".repeat(i[0].length-2)+"]"+r.slice(this.tokenizer.rules.inline.reflinkSearch.lastIndex))}for(;(i=this.tokenizer.rules.inline.anyPunctuation.exec(r))!=null;)r=r.slice(0,i.index)+"++"+r.slice(this.tokenizer.rules.inline.anyPunctuation.lastIndex);let o;for(;(i=this.tokenizer.rules.inline.blockSkip.exec(r))!=null;)o=i[2]?i[2].length:0,r=r.slice(0,i.index+o)+"["+"a".repeat(i[0].length-o-2)+"]"+r.slice(this.tokenizer.rules.inline.blockSkip.lastIndex);r=this.options.hooks?.emStrongMask?.call({lexer:this},r)??r;let s=!1,l="";for(;e;){s||(l=""),s=!1;let a;if(this.options.extensions?.inline?.some(u=>(a=u.call({lexer:this},e,n))?(e=e.substring(a.raw.length),n.push(a),!0):!1))continue;if(a=this.tokenizer.escape(e)){e=e.substring(a.raw.length),n.push(a);continue}if(a=this.tokenizer.tag(e)){e=e.substring(a.raw.length),n.push(a);continue}if(a=this.tokenizer.link(e)){e=e.substring(a.raw.length),n.push(a);continue}if(a=this.tokenizer.reflink(e,this.tokens.links)){e=e.substring(a.raw.length);let u=n.at(-1);a.type==="text"&&u?.type==="text"?(u.raw+=a.raw,u.text+=a.text):n.push(a);continue}if(a=this.tokenizer.emStrong(e,r,l)){e=e.substring(a.raw.length),n.push(a);continue}if(a=this.tokenizer.codespan(e)){e=e.substring(a.raw.length),n.push(a);continue}if(a=this.tokenizer.br(e)){e=e.substring(a.raw.length),n.push(a);continue}if(a=this.tokenizer.del(e,r,l)){e=e.substring(a.raw.length),n.push(a);continue}if(a=this.tokenizer.autolink(e)){e=e.substring(a.raw.length),n.push(a);continue}if(!this.state.inLink&&(a=this.tokenizer.url(e))){e=e.substring(a.raw.length),n.push(a);continue}let c=e;if(this.options.extensions?.startInline){let u=1/0,d=e.slice(1),h;this.options.extensions.startInline.forEach(f=>{h=f.call({lexer:this},d),typeof h=="number"&&h>=0&&(u=Math.min(u,h))}),u<1/0&&u>=0&&(c=e.substring(0,u+1))}if(a=this.tokenizer.inlineText(c)){e=e.substring(a.raw.length),a.raw.slice(-1)!=="_"&&(l=a.raw.slice(-1)),s=!0;let u=n.at(-1);u?.type==="text"?(u.raw+=a.raw,u.text+=a.text):n.push(a);continue}if(e){let u="Infinite loop on byte: "+e.charCodeAt(0);if(this.options.silent){console.error(u);break}else throw new Error(u)}}return n}},Un=class{options;parser;constructor(t){this.options=t||xt}space(t){return""}code({text:t,lang:e,escaped:n}){let r=(e||"").match(Se.notSpaceStart)?.[0],i=t.replace(Se.endingNewline,"")+`
42
- `;return r?'<pre><code class="language-'+Xe(r)+'">'+(n?i:Xe(i,!0))+`</code></pre>
43
- `:"<pre><code>"+(n?i:Xe(i,!0))+`</code></pre>
44
- `}blockquote({tokens:t}){return`<blockquote>
45
- ${this.parser.parse(t)}</blockquote>
46
- `}html({text:t}){return t}def(t){return""}heading({tokens:t,depth:e}){return`<h${e}>${this.parser.parseInline(t)}</h${e}>
47
- `}hr(t){return`<hr>
48
- `}list(t){let e=t.ordered,n=t.start,r="";for(let s=0;s<t.items.length;s++){let l=t.items[s];r+=this.listitem(l)}let i=e?"ol":"ul",o=e&&n!==1?' start="'+n+'"':"";return"<"+i+o+`>
49
- `+r+"</"+i+`>
50
- `}listitem(t){return`<li>${this.parser.parse(t.tokens)}</li>
51
- `}checkbox({checked:t}){return"<input "+(t?'checked="" ':"")+'disabled="" type="checkbox"> '}paragraph({tokens:t}){return`<p>${this.parser.parseInline(t)}</p>
52
- `}table(t){let e="",n="";for(let i=0;i<t.header.length;i++)n+=this.tablecell(t.header[i]);e+=this.tablerow({text:n});let r="";for(let i=0;i<t.rows.length;i++){let o=t.rows[i];n="";for(let s=0;s<o.length;s++)n+=this.tablecell(o[s]);r+=this.tablerow({text:n})}return r&&(r=`<tbody>${r}</tbody>`),`<table>
53
- <thead>
54
- `+e+`</thead>
55
- `+r+`</table>
56
- `}tablerow({text:t}){return`<tr>
57
- ${t}</tr>
58
- `}tablecell(t){let e=this.parser.parseInline(t.tokens),n=t.header?"th":"td";return(t.align?`<${n} align="${t.align}">`:`<${n}>`)+e+`</${n}>
59
- `}strong({tokens:t}){return`<strong>${this.parser.parseInline(t)}</strong>`}em({tokens:t}){return`<em>${this.parser.parseInline(t)}</em>`}codespan({text:t}){return`<code>${Xe(t,!0)}</code>`}br(t){return"<br>"}del({tokens:t}){return`<del>${this.parser.parseInline(t)}</del>`}link({href:t,title:e,tokens:n}){let r=this.parser.parseInline(n),i=Vo(t);if(i===null)return r;t=i;let o='<a href="'+t+'"';return e&&(o+=' title="'+Xe(e)+'"'),o+=">"+r+"</a>",o}image({href:t,title:e,text:n,tokens:r}){r&&(n=this.parser.parseInline(r,this.parser.textRenderer));let i=Vo(t);if(i===null)return Xe(n);t=i;let o=`<img src="${t}" alt="${Xe(n)}"`;return e&&(o+=` title="${Xe(e)}"`),o+=">",o}text(t){return"tokens"in t&&t.tokens?this.parser.parseInline(t.tokens):"escaped"in t&&t.escaped?t.text:Xe(t.text)}},Vi=class{strong({text:t}){return t}em({text:t}){return t}codespan({text:t}){return t}del({text:t}){return t}html({text:t}){return t}text({text:t}){return t}link({text:t}){return""+t}image({text:t}){return""+t}br(){return""}checkbox({raw:t}){return t}},qe=class ri{options;renderer;textRenderer;constructor(e){this.options=e||xt,this.options.renderer=this.options.renderer||new Un,this.renderer=this.options.renderer,this.renderer.options=this.options,this.renderer.parser=this,this.textRenderer=new Vi}static parse(e,n){return new ri(n).parse(e)}static parseInline(e,n){return new ri(n).parseInline(e)}parse(e){let n="";for(let r=0;r<e.length;r++){let i=e[r];if(this.options.extensions?.renderers?.[i.type]){let s=i,l=this.options.extensions.renderers[s.type].call({parser:this},s);if(l!==!1||!["space","hr","heading","code","table","blockquote","list","html","def","paragraph","text"].includes(s.type)){n+=l||"";continue}}let o=i;switch(o.type){case"space":{n+=this.renderer.space(o);break}case"hr":{n+=this.renderer.hr(o);break}case"heading":{n+=this.renderer.heading(o);break}case"code":{n+=this.renderer.code(o);break}case"table":{n+=this.renderer.table(o);break}case"blockquote":{n+=this.renderer.blockquote(o);break}case"list":{n+=this.renderer.list(o);break}case"checkbox":{n+=this.renderer.checkbox(o);break}case"html":{n+=this.renderer.html(o);break}case"def":{n+=this.renderer.def(o);break}case"paragraph":{n+=this.renderer.paragraph(o);break}case"text":{n+=this.renderer.text(o);break}default:{let s='Token with "'+o.type+'" type was not found.';if(this.options.silent)return console.error(s),"";throw new Error(s)}}}return n}parseInline(e,n=this.renderer){let r="";for(let i=0;i<e.length;i++){let o=e[i];if(this.options.extensions?.renderers?.[o.type]){let l=this.options.extensions.renderers[o.type].call({parser:this},o);if(l!==!1||!["escape","html","link","image","strong","em","codespan","br","del","text"].includes(o.type)){r+=l||"";continue}}let s=o;switch(s.type){case"escape":{r+=n.text(s);break}case"html":{r+=n.html(s);break}case"link":{r+=n.link(s);break}case"image":{r+=n.image(s);break}case"checkbox":{r+=n.checkbox(s);break}case"strong":{r+=n.strong(s);break}case"em":{r+=n.em(s);break}case"codespan":{r+=n.codespan(s);break}case"br":{r+=n.br(s);break}case"del":{r+=n.del(s);break}case"text":{r+=n.text(s);break}default:{let l='Token with "'+s.type+'" type was not found.';if(this.options.silent)return console.error(l),"";throw new Error(l)}}}return r}},on=class{options;block;constructor(t){this.options=t||xt}static passThroughHooks=new Set(["preprocess","postprocess","processAllTokens","emStrongMask"]);static passThroughHooksRespectAsync=new Set(["preprocess","postprocess","processAllTokens"]);preprocess(t){return t}postprocess(t){return t}processAllTokens(t){return t}emStrongMask(t){return t}provideLexer(){return this.block?je.lex:je.lexInline}provideParser(){return this.block?qe.parse:qe.parseInline}},Sp=class{defaults=Ci();options=this.setOptions;parse=this.parseMarkdown(!0);parseInline=this.parseMarkdown(!1);Parser=qe;Renderer=Un;TextRenderer=Vi;Lexer=je;Tokenizer=Gn;Hooks=on;constructor(...t){this.use(...t)}walkTokens(t,e){let n=[];for(let r of t)switch(n=n.concat(e.call(this,r)),r.type){case"table":{let i=r;for(let o of i.header)n=n.concat(this.walkTokens(o.tokens,e));for(let o of i.rows)for(let s of o)n=n.concat(this.walkTokens(s.tokens,e));break}case"list":{let i=r;n=n.concat(this.walkTokens(i.items,e));break}default:{let i=r;this.defaults.extensions?.childTokens?.[i.type]?this.defaults.extensions.childTokens[i.type].forEach(o=>{let s=i[o].flat(1/0);n=n.concat(this.walkTokens(s,e))}):i.tokens&&(n=n.concat(this.walkTokens(i.tokens,e)))}}return n}use(...t){let e=this.defaults.extensions||{renderers:{},childTokens:{}};return t.forEach(n=>{let r={...n};if(r.async=this.defaults.async||r.async||!1,n.extensions&&(n.extensions.forEach(i=>{if(!i.name)throw new Error("extension name required");if("renderer"in i){let o=e.renderers[i.name];o?e.renderers[i.name]=function(...s){let l=i.renderer.apply(this,s);return l===!1&&(l=o.apply(this,s)),l}:e.renderers[i.name]=i.renderer}if("tokenizer"in i){if(!i.level||i.level!=="block"&&i.level!=="inline")throw new Error("extension level must be 'block' or 'inline'");let o=e[i.level];o?o.unshift(i.tokenizer):e[i.level]=[i.tokenizer],i.start&&(i.level==="block"?e.startBlock?e.startBlock.push(i.start):e.startBlock=[i.start]:i.level==="inline"&&(e.startInline?e.startInline.push(i.start):e.startInline=[i.start]))}"childTokens"in i&&i.childTokens&&(e.childTokens[i.name]=i.childTokens)}),r.extensions=e),n.renderer){let i=this.defaults.renderer||new Un(this.defaults);for(let o in n.renderer){if(!(o in i))throw new Error(`renderer '${o}' does not exist`);if(["options","parser"].includes(o))continue;let s=o,l=n.renderer[s],a=i[s];i[s]=(...c)=>{let u=l.apply(i,c);return u===!1&&(u=a.apply(i,c)),u||""}}r.renderer=i}if(n.tokenizer){let i=this.defaults.tokenizer||new Gn(this.defaults);for(let o in n.tokenizer){if(!(o in i))throw new Error(`tokenizer '${o}' does not exist`);if(["options","rules","lexer"].includes(o))continue;let s=o,l=n.tokenizer[s],a=i[s];i[s]=(...c)=>{let u=l.apply(i,c);return u===!1&&(u=a.apply(i,c)),u}}r.tokenizer=i}if(n.hooks){let i=this.defaults.hooks||new on;for(let o in n.hooks){if(!(o in i))throw new Error(`hook '${o}' does not exist`);if(["options","block"].includes(o))continue;let s=o,l=n.hooks[s],a=i[s];on.passThroughHooks.has(o)?i[s]=c=>{if(this.defaults.async&&on.passThroughHooksRespectAsync.has(o))return(async()=>{let d=await l.call(i,c);return a.call(i,d)})();let u=l.call(i,c);return a.call(i,u)}:i[s]=(...c)=>{if(this.defaults.async)return(async()=>{let d=await l.apply(i,c);return d===!1&&(d=await a.apply(i,c)),d})();let u=l.apply(i,c);return u===!1&&(u=a.apply(i,c)),u}}r.hooks=i}if(n.walkTokens){let i=this.defaults.walkTokens,o=n.walkTokens;r.walkTokens=function(s){let l=[];return l.push(o.call(this,s)),i&&(l=l.concat(i.call(this,s))),l}}this.defaults={...this.defaults,...r}}),this}setOptions(t){return this.defaults={...this.defaults,...t},this}lexer(t,e){return je.lex(t,e??this.defaults)}parser(t,e){return qe.parse(t,e??this.defaults)}parseMarkdown(t){return(e,n)=>{let r={...n},i={...this.defaults,...r},o=this.onError(!!i.silent,!!i.async);if(this.defaults.async===!0&&r.async===!1)return o(new Error("marked(): The async option was set to true by an extension. Remove async: false from the parse options object to return a Promise."));if(typeof e>"u"||e===null)return o(new Error("marked(): input parameter is undefined or null"));if(typeof e!="string")return o(new Error("marked(): input parameter is of type "+Object.prototype.toString.call(e)+", string expected"));if(i.hooks&&(i.hooks.options=i,i.hooks.block=t),i.async)return(async()=>{let s=i.hooks?await i.hooks.preprocess(e):e,l=await(i.hooks?await i.hooks.provideLexer():t?je.lex:je.lexInline)(s,i),a=i.hooks?await i.hooks.processAllTokens(l):l;i.walkTokens&&await Promise.all(this.walkTokens(a,i.walkTokens));let c=await(i.hooks?await i.hooks.provideParser():t?qe.parse:qe.parseInline)(a,i);return i.hooks?await i.hooks.postprocess(c):c})().catch(o);try{i.hooks&&(e=i.hooks.preprocess(e));let s=(i.hooks?i.hooks.provideLexer():t?je.lex:je.lexInline)(e,i);i.hooks&&(s=i.hooks.processAllTokens(s)),i.walkTokens&&this.walkTokens(s,i.walkTokens);let l=(i.hooks?i.hooks.provideParser():t?qe.parse:qe.parseInline)(s,i);return i.hooks&&(l=i.hooks.postprocess(l)),l}catch(s){return o(s)}}}onError(t,e){return n=>{if(n.message+=`
60
- Please report this to https://github.com/markedjs/marked.`,t){let r="<p>An error occurred:</p><pre>"+Xe(n.message+"",!0)+"</pre>";return e?Promise.resolve(r):r}if(e)return Promise.reject(n);throw n}}},bt=new Sp;function ie(t,e){return bt.parse(t,e)}ie.options=ie.setOptions=function(t){return bt.setOptions(t),ie.defaults=bt.defaults,ea(ie.defaults),ie};ie.getDefaults=Ci;ie.defaults=xt;ie.use=function(...t){return bt.use(...t),ie.defaults=bt.defaults,ea(ie.defaults),ie};ie.walkTokens=function(t,e){return bt.walkTokens(t,e)};ie.parseInline=bt.parseInline;ie.Parser=qe;ie.parser=qe.parse;ie.Renderer=Un;ie.TextRenderer=Vi;ie.Lexer=je;ie.lexer=je.lex;ie.Tokenizer=Gn;ie.Hooks=on;ie.parse=ie;ie.options;ie.setOptions;ie.use;ie.walkTokens;ie.parseInline;qe.parse;je.lex;let fe=class extends Error{constructor(e){super(e),this.name="ShikiError"}};function Rp(t){return Bi(t)}function Bi(t){return Array.isArray(t)?Lp(t):t instanceof RegExp?t:typeof t=="object"?Cp(t):t}function Lp(t){let e=[];for(let n=0,r=t.length;n<r;n++)e[n]=Bi(t[n]);return e}function Cp(t){let e={};for(let n in t)e[n]=Bi(t[n]);return e}function pa(t,...e){return e.forEach(n=>{for(let r in n)t[r]=n[r]}),t}function ma(t){const e=~t.lastIndexOf("/")||~t.lastIndexOf("\\");return e===0?t:~e===t.length-1?ma(t.substring(0,t.length-1)):t.substr(~e+1)}var Cr=/\$(\d+)|\${(\d+):\/(downcase|upcase)}/g,On=class{static hasCaptures(t){return t===null?!1:(Cr.lastIndex=0,Cr.test(t))}static replaceCaptures(t,e,n){return t.replace(Cr,(r,i,o,s)=>{let l=n[parseInt(i||o,10)];if(l){let a=e.substring(l.start,l.end);for(;a[0]===".";)a=a.substring(1);switch(s){case"downcase":return a.toLowerCase();case"upcase":return a.toUpperCase();default:return a}}else return r})}};function fa(t,e){return t<e?-1:t>e?1:0}function ha(t,e){if(t===null&&e===null)return 0;if(!t)return-1;if(!e)return 1;let n=t.length,r=e.length;if(n===r){for(let i=0;i<n;i++){let o=fa(t[i],e[i]);if(o!==0)return o}return 0}return n-r}function Fo(t){return!!(/^#[0-9a-f]{6}$/i.test(t)||/^#[0-9a-f]{8}$/i.test(t)||/^#[0-9a-f]{3}$/i.test(t)||/^#[0-9a-f]{4}$/i.test(t))}function ga(t){return t.replace(/[\-\\\{\}\*\+\?\|\^\$\.\,\[\]\(\)\#\s]/g,"\\$&")}var _a=class{constructor(t){this.fn=t}cache=new Map;get(t){if(this.cache.has(t))return this.cache.get(t);const e=this.fn(t);return this.cache.set(t,e),e}},Wn=class{constructor(t,e,n){this._colorMap=t,this._defaults=e,this._root=n}static createFromRawTheme(t,e){return this.createFromParsedTheme(Ip(t),e)}static createFromParsedTheme(t,e){return Np(t,e)}_cachedMatchRoot=new _a(t=>this._root.match(t));getColorMap(){return this._colorMap.getColorMap()}getDefaults(){return this._defaults}match(t){if(t===null)return this._defaults;const e=t.scopeName,r=this._cachedMatchRoot.get(e).find(i=>Pp(t.parent,i.parentScopes));return r?new ya(r.fontStyle,r.foreground,r.background):null}},Pr=class Vn{constructor(e,n){this.parent=e,this.scopeName=n}static push(e,n){for(const r of n)e=new Vn(e,r);return e}static from(...e){let n=null;for(let r=0;r<e.length;r++)n=new Vn(n,e[r]);return n}push(e){return new Vn(this,e)}getSegments(){let e=this;const n=[];for(;e;)n.push(e.scopeName),e=e.parent;return n.reverse(),n}toString(){return this.getSegments().join(" ")}extends(e){return this===e?!0:this.parent===null?!1:this.parent.extends(e)}getExtensionIfDefined(e){const n=[];let r=this;for(;r&&r!==e;)n.push(r.scopeName),r=r.parent;return r===e?n.reverse():void 0}};function Pp(t,e){if(e.length===0)return!0;for(let n=0;n<e.length;n++){let r=e[n],i=!1;if(r===">"){if(n===e.length-1)return!1;r=e[++n],i=!0}for(;t&&!Op(t.scopeName,r);){if(i)return!1;t=t.parent}if(!t)return!1;t=t.parent}return!0}function Op(t,e){return e===t||t.startsWith(e)&&t[e.length]==="."}var ya=class{constructor(t,e,n){this.fontStyle=t,this.foregroundId=e,this.backgroundId=n}};function Ip(t){if(!t)return[];if(!t.settings||!Array.isArray(t.settings))return[];let e=t.settings,n=[],r=0;for(let i=0,o=e.length;i<o;i++){let s=e[i];if(!s.settings)continue;let l;if(typeof s.scope=="string"){let d=s.scope;d=d.replace(/^[,]+/,""),d=d.replace(/[,]+$/,""),l=d.split(",")}else Array.isArray(s.scope)?l=s.scope:l=[""];let a=-1;if(typeof s.settings.fontStyle=="string"){a=0;let d=s.settings.fontStyle.split(" ");for(let h=0,f=d.length;h<f;h++)switch(d[h]){case"italic":a=a|1;break;case"bold":a=a|2;break;case"underline":a=a|4;break;case"strikethrough":a=a|8;break}}let c=null;typeof s.settings.foreground=="string"&&Fo(s.settings.foreground)&&(c=s.settings.foreground);let u=null;typeof s.settings.background=="string"&&Fo(s.settings.background)&&(u=s.settings.background);for(let d=0,h=l.length;d<h;d++){let g=l[d].trim().split(" "),y=g[g.length-1],x=null;g.length>1&&(x=g.slice(0,g.length-1),x.reverse()),n[r++]=new Dp(y,x,i,a,c,u)}}return n}var Dp=class{constructor(t,e,n,r,i,o){this.scope=t,this.parentScopes=e,this.index=n,this.fontStyle=r,this.foreground=i,this.background=o}},Ee=(t=>(t[t.NotSet=-1]="NotSet",t[t.None=0]="None",t[t.Italic=1]="Italic",t[t.Bold=2]="Bold",t[t.Underline=4]="Underline",t[t.Strikethrough=8]="Strikethrough",t))(Ee||{});function Np(t,e){t.sort((a,c)=>{let u=fa(a.scope,c.scope);return u!==0||(u=ha(a.parentScopes,c.parentScopes),u!==0)?u:a.index-c.index});let n=0,r="#000000",i="#ffffff";for(;t.length>=1&&t[0].scope==="";){let a=t.shift();a.fontStyle!==-1&&(n=a.fontStyle),a.foreground!==null&&(r=a.foreground),a.background!==null&&(i=a.background)}let o=new Mp(e),s=new ya(n,o.getId(r),o.getId(i)),l=new Vp(new ii(0,null,-1,0,0),[]);for(let a=0,c=t.length;a<c;a++){let u=t[a];l.insert(0,u.scope,u.parentScopes,u.fontStyle,o.getId(u.foreground),o.getId(u.background))}return new Wn(o,s,l)}var Mp=class{_isFrozen;_lastColorId;_id2color;_color2id;constructor(t){if(this._lastColorId=0,this._id2color=[],this._color2id=Object.create(null),Array.isArray(t)){this._isFrozen=!0;for(let e=0,n=t.length;e<n;e++)this._color2id[t[e]]=e,this._id2color[e]=t[e]}else this._isFrozen=!1}getId(t){if(t===null)return 0;t=t.toUpperCase();let e=this._color2id[t];if(e)return e;if(this._isFrozen)throw new Error(`Missing color in color map - ${t}`);return e=++this._lastColorId,this._color2id[t]=e,this._id2color[e]=t,e}getColorMap(){return this._id2color.slice(0)}},$p=Object.freeze([]),ii=class va{scopeDepth;parentScopes;fontStyle;foreground;background;constructor(e,n,r,i,o){this.scopeDepth=e,this.parentScopes=n||$p,this.fontStyle=r,this.foreground=i,this.background=o}clone(){return new va(this.scopeDepth,this.parentScopes,this.fontStyle,this.foreground,this.background)}static cloneArr(e){let n=[];for(let r=0,i=e.length;r<i;r++)n[r]=e[r].clone();return n}acceptOverwrite(e,n,r,i){this.scopeDepth>e?console.log("how did this happen?"):this.scopeDepth=e,n!==-1&&(this.fontStyle=n),r!==0&&(this.foreground=r),i!==0&&(this.background=i)}},Vp=class oi{constructor(e,n=[],r={}){this._mainRule=e,this._children=r,this._rulesWithParentScopes=n}_rulesWithParentScopes;static _cmpBySpecificity(e,n){if(e.scopeDepth!==n.scopeDepth)return n.scopeDepth-e.scopeDepth;let r=0,i=0;for(;e.parentScopes[r]===">"&&r++,n.parentScopes[i]===">"&&i++,!(r>=e.parentScopes.length||i>=n.parentScopes.length);){const o=n.parentScopes[i].length-e.parentScopes[r].length;if(o!==0)return o;r++,i++}return n.parentScopes.length-e.parentScopes.length}match(e){if(e!==""){let r=e.indexOf("."),i,o;if(r===-1?(i=e,o=""):(i=e.substring(0,r),o=e.substring(r+1)),this._children.hasOwnProperty(i))return this._children[i].match(o)}const n=this._rulesWithParentScopes.concat(this._mainRule);return n.sort(oi._cmpBySpecificity),n}insert(e,n,r,i,o,s){if(n===""){this._doInsertHere(e,r,i,o,s);return}let l=n.indexOf("."),a,c;l===-1?(a=n,c=""):(a=n.substring(0,l),c=n.substring(l+1));let u;this._children.hasOwnProperty(a)?u=this._children[a]:(u=new oi(this._mainRule.clone(),ii.cloneArr(this._rulesWithParentScopes)),this._children[a]=u),u.insert(e+1,c,r,i,o,s)}_doInsertHere(e,n,r,i,o){if(n===null){this._mainRule.acceptOverwrite(e,r,i,o);return}for(let s=0,l=this._rulesWithParentScopes.length;s<l;s++){let a=this._rulesWithParentScopes[s];if(ha(a.parentScopes,n)===0){a.acceptOverwrite(e,r,i,o);return}}r===-1&&(r=this._mainRule.fontStyle),i===0&&(i=this._mainRule.foreground),o===0&&(o=this._mainRule.background),this._rulesWithParentScopes.push(new ii(e,n,r,i,o))}},zt=class Be{static toBinaryStr(e){return e.toString(2).padStart(32,"0")}static print(e){const n=Be.getLanguageId(e),r=Be.getTokenType(e),i=Be.getFontStyle(e),o=Be.getForeground(e),s=Be.getBackground(e);console.log({languageId:n,tokenType:r,fontStyle:i,foreground:o,background:s})}static getLanguageId(e){return(e&255)>>>0}static getTokenType(e){return(e&768)>>>8}static containsBalancedBrackets(e){return(e&1024)!==0}static getFontStyle(e){return(e&30720)>>>11}static getForeground(e){return(e&16744448)>>>15}static getBackground(e){return(e&4278190080)>>>24}static set(e,n,r,i,o,s,l){let a=Be.getLanguageId(e),c=Be.getTokenType(e),u=Be.containsBalancedBrackets(e)?1:0,d=Be.getFontStyle(e),h=Be.getForeground(e),f=Be.getBackground(e);return n!==0&&(a=n),r!==8&&(c=r),i!==null&&(u=i?1:0),o!==-1&&(d=o),s!==0&&(h=s),l!==0&&(f=l),(a<<0|c<<8|u<<10|d<<11|h<<15|f<<24)>>>0}};function Kn(t,e){const n=[],r=Bp(t);let i=r.next();for(;i!==null;){let a=0;if(i.length===2&&i.charAt(1)===":"){switch(i.charAt(0)){case"R":a=1;break;case"L":a=-1;break;default:console.log(`Unknown priority ${i} in scope selector`)}i=r.next()}let c=s();if(n.push({matcher:c,priority:a}),i!==",")break;i=r.next()}return n;function o(){if(i==="-"){i=r.next();const a=o();return c=>!!a&&!a(c)}if(i==="("){i=r.next();const a=l();return i===")"&&(i=r.next()),a}if(jo(i)){const a=[];do a.push(i),i=r.next();while(jo(i));return c=>e(a,c)}return null}function s(){const a=[];let c=o();for(;c;)a.push(c),c=o();return u=>a.every(d=>d(u))}function l(){const a=[];let c=s();for(;c&&(a.push(c),i==="|"||i===",");){do i=r.next();while(i==="|"||i===",");c=s()}return u=>a.some(d=>d(u))}}function jo(t){return!!t&&!!t.match(/[\w\.:]+/)}function Bp(t){let e=/([LR]:|[\w\.:][\w\.:\-]*|[\,\|\-\(\)])/g,n=e.exec(t);return{next:()=>{if(!n)return null;const r=n[0];return n=e.exec(t),r}}}function ba(t){typeof t.dispose=="function"&&t.dispose()}var pn=class{constructor(t){this.scopeName=t}toKey(){return this.scopeName}},zp=class{constructor(t,e){this.scopeName=t,this.ruleName=e}toKey(){return`${this.scopeName}#${this.ruleName}`}},Fp=class{_references=[];_seenReferenceKeys=new Set;get references(){return this._references}visitedRule=new Set;add(t){const e=t.toKey();this._seenReferenceKeys.has(e)||(this._seenReferenceKeys.add(e),this._references.push(t))}},jp=class{constructor(t,e){this.repo=t,this.initialScopeName=e,this.seenFullScopeRequests.add(this.initialScopeName),this.Q=[new pn(this.initialScopeName)]}seenFullScopeRequests=new Set;seenPartialScopeRequests=new Set;Q;processQueue(){const t=this.Q;this.Q=[];const e=new Fp;for(const n of t)qp(n,this.initialScopeName,this.repo,e);for(const n of e.references)if(n instanceof pn){if(this.seenFullScopeRequests.has(n.scopeName))continue;this.seenFullScopeRequests.add(n.scopeName),this.Q.push(n)}else{if(this.seenFullScopeRequests.has(n.scopeName)||this.seenPartialScopeRequests.has(n.toKey()))continue;this.seenPartialScopeRequests.add(n.toKey()),this.Q.push(n)}}};function qp(t,e,n,r){const i=n.lookup(t.scopeName);if(!i){if(t.scopeName===e)throw new Error(`No grammar provided for <${e}>`);return}const o=n.lookup(e);t instanceof pn?Bn({baseGrammar:o,selfGrammar:i},r):si(t.ruleName,{baseGrammar:o,selfGrammar:i,repository:i.repository},r);const s=n.injections(t.scopeName);if(s)for(const l of s)r.add(new pn(l))}function si(t,e,n){if(e.repository&&e.repository[t]){const r=e.repository[t];Xn([r],e,n)}}function Bn(t,e){t.selfGrammar.patterns&&Array.isArray(t.selfGrammar.patterns)&&Xn(t.selfGrammar.patterns,{...t,repository:t.selfGrammar.repository},e),t.selfGrammar.injections&&Xn(Object.values(t.selfGrammar.injections),{...t,repository:t.selfGrammar.repository},e)}function Xn(t,e,n){for(const r of t){if(n.visitedRule.has(r))continue;n.visitedRule.add(r);const i=r.repository?pa({},e.repository,r.repository):e.repository;Array.isArray(r.patterns)&&Xn(r.patterns,{...e,repository:i},n);const o=r.include;if(!o)continue;const s=ka(o);switch(s.kind){case 0:Bn({...e,selfGrammar:e.baseGrammar},n);break;case 1:Bn(e,n);break;case 2:si(s.ruleName,{...e,repository:i},n);break;case 3:case 4:const l=s.scopeName===e.selfGrammar.scopeName?e.selfGrammar:s.scopeName===e.baseGrammar.scopeName?e.baseGrammar:void 0;if(l){const a={baseGrammar:e.baseGrammar,selfGrammar:l,repository:i};s.kind===4?si(s.ruleName,a,n):Bn(a,n)}else s.kind===4?n.add(new zp(s.scopeName,s.ruleName)):n.add(new pn(s.scopeName));break}}}var Hp=class{kind=0},Gp=class{kind=1},Up=class{constructor(t){this.ruleName=t}kind=2},Wp=class{constructor(t){this.scopeName=t}kind=3},Kp=class{constructor(t,e){this.scopeName=t,this.ruleName=e}kind=4};function ka(t){if(t==="$base")return new Hp;if(t==="$self")return new Gp;const e=t.indexOf("#");if(e===-1)return new Wp(t);if(e===0)return new Up(t.substring(1));{const n=t.substring(0,e),r=t.substring(e+1);return new Kp(n,r)}}var Xp=/\\(\d+)/,qo=/\\(\d+)/g,Yp=-1,wa=-2;var bn=class{$location;id;_nameIsCapturing;_name;_contentNameIsCapturing;_contentName;constructor(t,e,n,r){this.$location=t,this.id=e,this._name=n||null,this._nameIsCapturing=On.hasCaptures(this._name),this._contentName=r||null,this._contentNameIsCapturing=On.hasCaptures(this._contentName)}get debugName(){const t=this.$location?`${ma(this.$location.filename)}:${this.$location.line}`:"unknown";return`${this.constructor.name}#${this.id} @ ${t}`}getName(t,e){return!this._nameIsCapturing||this._name===null||t===null||e===null?this._name:On.replaceCaptures(this._name,t,e)}getContentName(t,e){return!this._contentNameIsCapturing||this._contentName===null?this._contentName:On.replaceCaptures(this._contentName,t,e)}},Qp=class extends bn{retokenizeCapturedWithRuleId;constructor(t,e,n,r,i){super(t,e,n,r),this.retokenizeCapturedWithRuleId=i}dispose(){}collectPatterns(t,e){throw new Error("Not supported!")}compile(t,e){throw new Error("Not supported!")}compileAG(t,e,n,r){throw new Error("Not supported!")}},Jp=class extends bn{_match;captures;_cachedCompiledPatterns;constructor(t,e,n,r,i){super(t,e,n,null),this._match=new mn(r,this.id),this.captures=i,this._cachedCompiledPatterns=null}dispose(){this._cachedCompiledPatterns&&(this._cachedCompiledPatterns.dispose(),this._cachedCompiledPatterns=null)}get debugMatchRegExp(){return`${this._match.source}`}collectPatterns(t,e){e.push(this._match)}compile(t,e){return this._getCachedCompiledPatterns(t).compile(t)}compileAG(t,e,n,r){return this._getCachedCompiledPatterns(t).compileAG(t,n,r)}_getCachedCompiledPatterns(t){return this._cachedCompiledPatterns||(this._cachedCompiledPatterns=new fn,this.collectPatterns(t,this._cachedCompiledPatterns)),this._cachedCompiledPatterns}},Ho=class extends bn{hasMissingPatterns;patterns;_cachedCompiledPatterns;constructor(t,e,n,r,i){super(t,e,n,r),this.patterns=i.patterns,this.hasMissingPatterns=i.hasMissingPatterns,this._cachedCompiledPatterns=null}dispose(){this._cachedCompiledPatterns&&(this._cachedCompiledPatterns.dispose(),this._cachedCompiledPatterns=null)}collectPatterns(t,e){for(const n of this.patterns)t.getRule(n).collectPatterns(t,e)}compile(t,e){return this._getCachedCompiledPatterns(t).compile(t)}compileAG(t,e,n,r){return this._getCachedCompiledPatterns(t).compileAG(t,n,r)}_getCachedCompiledPatterns(t){return this._cachedCompiledPatterns||(this._cachedCompiledPatterns=new fn,this.collectPatterns(t,this._cachedCompiledPatterns)),this._cachedCompiledPatterns}},ai=class extends bn{_begin;beginCaptures;_end;endHasBackReferences;endCaptures;applyEndPatternLast;hasMissingPatterns;patterns;_cachedCompiledPatterns;constructor(t,e,n,r,i,o,s,l,a,c){super(t,e,n,r),this._begin=new mn(i,this.id),this.beginCaptures=o,this._end=new mn(s||"￿",-1),this.endHasBackReferences=this._end.hasBackReferences,this.endCaptures=l,this.applyEndPatternLast=a||!1,this.patterns=c.patterns,this.hasMissingPatterns=c.hasMissingPatterns,this._cachedCompiledPatterns=null}dispose(){this._cachedCompiledPatterns&&(this._cachedCompiledPatterns.dispose(),this._cachedCompiledPatterns=null)}get debugBeginRegExp(){return`${this._begin.source}`}get debugEndRegExp(){return`${this._end.source}`}getEndWithResolvedBackReferences(t,e){return this._end.resolveBackReferences(t,e)}collectPatterns(t,e){e.push(this._begin)}compile(t,e){return this._getCachedCompiledPatterns(t,e).compile(t)}compileAG(t,e,n,r){return this._getCachedCompiledPatterns(t,e).compileAG(t,n,r)}_getCachedCompiledPatterns(t,e){if(!this._cachedCompiledPatterns){this._cachedCompiledPatterns=new fn;for(const n of this.patterns)t.getRule(n).collectPatterns(t,this._cachedCompiledPatterns);this.applyEndPatternLast?this._cachedCompiledPatterns.push(this._end.hasBackReferences?this._end.clone():this._end):this._cachedCompiledPatterns.unshift(this._end.hasBackReferences?this._end.clone():this._end)}return this._end.hasBackReferences&&(this.applyEndPatternLast?this._cachedCompiledPatterns.setSource(this._cachedCompiledPatterns.length()-1,e):this._cachedCompiledPatterns.setSource(0,e)),this._cachedCompiledPatterns}},Yn=class extends bn{_begin;beginCaptures;whileCaptures;_while;whileHasBackReferences;hasMissingPatterns;patterns;_cachedCompiledPatterns;_cachedCompiledWhilePatterns;constructor(t,e,n,r,i,o,s,l,a){super(t,e,n,r),this._begin=new mn(i,this.id),this.beginCaptures=o,this.whileCaptures=l,this._while=new mn(s,wa),this.whileHasBackReferences=this._while.hasBackReferences,this.patterns=a.patterns,this.hasMissingPatterns=a.hasMissingPatterns,this._cachedCompiledPatterns=null,this._cachedCompiledWhilePatterns=null}dispose(){this._cachedCompiledPatterns&&(this._cachedCompiledPatterns.dispose(),this._cachedCompiledPatterns=null),this._cachedCompiledWhilePatterns&&(this._cachedCompiledWhilePatterns.dispose(),this._cachedCompiledWhilePatterns=null)}get debugBeginRegExp(){return`${this._begin.source}`}get debugWhileRegExp(){return`${this._while.source}`}getWhileWithResolvedBackReferences(t,e){return this._while.resolveBackReferences(t,e)}collectPatterns(t,e){e.push(this._begin)}compile(t,e){return this._getCachedCompiledPatterns(t).compile(t)}compileAG(t,e,n,r){return this._getCachedCompiledPatterns(t).compileAG(t,n,r)}_getCachedCompiledPatterns(t){if(!this._cachedCompiledPatterns){this._cachedCompiledPatterns=new fn;for(const e of this.patterns)t.getRule(e).collectPatterns(t,this._cachedCompiledPatterns)}return this._cachedCompiledPatterns}compileWhile(t,e){return this._getCachedCompiledWhilePatterns(t,e).compile(t)}compileWhileAG(t,e,n,r){return this._getCachedCompiledWhilePatterns(t,e).compileAG(t,n,r)}_getCachedCompiledWhilePatterns(t,e){return this._cachedCompiledWhilePatterns||(this._cachedCompiledWhilePatterns=new fn,this._cachedCompiledWhilePatterns.push(this._while.hasBackReferences?this._while.clone():this._while)),this._while.hasBackReferences&&this._cachedCompiledWhilePatterns.setSource(0,e||"￿"),this._cachedCompiledWhilePatterns}},xa=class xe{static createCaptureRule(e,n,r,i,o){return e.registerRule(s=>new Qp(n,s,r,i,o))}static getCompiledRuleId(e,n,r){return e.id||n.registerRule(i=>{if(e.id=i,e.match)return new Jp(e.$vscodeTextmateLocation,e.id,e.name,e.match,xe._compileCaptures(e.captures,n,r));if(typeof e.begin>"u"){e.repository&&(r=pa({},r,e.repository));let o=e.patterns;return typeof o>"u"&&e.include&&(o=[{include:e.include}]),new Ho(e.$vscodeTextmateLocation,e.id,e.name,e.contentName,xe._compilePatterns(o,n,r))}return e.while?new Yn(e.$vscodeTextmateLocation,e.id,e.name,e.contentName,e.begin,xe._compileCaptures(e.beginCaptures||e.captures,n,r),e.while,xe._compileCaptures(e.whileCaptures||e.captures,n,r),xe._compilePatterns(e.patterns,n,r)):new ai(e.$vscodeTextmateLocation,e.id,e.name,e.contentName,e.begin,xe._compileCaptures(e.beginCaptures||e.captures,n,r),e.end,xe._compileCaptures(e.endCaptures||e.captures,n,r),e.applyEndPatternLast,xe._compilePatterns(e.patterns,n,r))}),e.id}static _compileCaptures(e,n,r){let i=[];if(e){let o=0;for(const s in e){if(s==="$vscodeTextmateLocation")continue;const l=parseInt(s,10);l>o&&(o=l)}for(let s=0;s<=o;s++)i[s]=null;for(const s in e){if(s==="$vscodeTextmateLocation")continue;const l=parseInt(s,10);let a=0;e[s].patterns&&(a=xe.getCompiledRuleId(e[s],n,r)),i[l]=xe.createCaptureRule(n,e[s].$vscodeTextmateLocation,e[s].name,e[s].contentName,a)}}return i}static _compilePatterns(e,n,r){let i=[];if(e)for(let o=0,s=e.length;o<s;o++){const l=e[o];let a=-1;if(l.include){const c=ka(l.include);switch(c.kind){case 0:case 1:a=xe.getCompiledRuleId(r[l.include],n,r);break;case 2:let u=r[c.ruleName];u&&(a=xe.getCompiledRuleId(u,n,r));break;case 3:case 4:const d=c.scopeName,h=c.kind===4?c.ruleName:null,f=n.getExternalGrammar(d,r);if(f)if(h){let g=f.repository[h];g&&(a=xe.getCompiledRuleId(g,n,f.repository))}else a=xe.getCompiledRuleId(f.repository.$self,n,f.repository);break}}else a=xe.getCompiledRuleId(l,n,r);if(a!==-1){const c=n.getRule(a);let u=!1;if((c instanceof Ho||c instanceof ai||c instanceof Yn)&&c.hasMissingPatterns&&c.patterns.length===0&&(u=!0),u)continue;i.push(a)}}return{patterns:i,hasMissingPatterns:(e?e.length:0)!==i.length}}},mn=class Ea{source;ruleId;hasAnchor;hasBackReferences;_anchorCache;constructor(e,n){if(e&&typeof e=="string"){const r=e.length;let i=0,o=[],s=!1;for(let l=0;l<r;l++)if(e.charAt(l)==="\\"&&l+1<r){const c=e.charAt(l+1);c==="z"?(o.push(e.substring(i,l)),o.push("$(?!\\n)(?<!\\n)"),i=l+2):(c==="A"||c==="G")&&(s=!0),l++}this.hasAnchor=s,i===0?this.source=e:(o.push(e.substring(i,r)),this.source=o.join(""))}else this.hasAnchor=!1,this.source=e;this.hasAnchor?this._anchorCache=this._buildAnchorCache():this._anchorCache=null,this.ruleId=n,typeof this.source=="string"?this.hasBackReferences=Xp.test(this.source):this.hasBackReferences=!1}clone(){return new Ea(this.source,this.ruleId)}setSource(e){this.source!==e&&(this.source=e,this.hasAnchor&&(this._anchorCache=this._buildAnchorCache()))}resolveBackReferences(e,n){if(typeof this.source!="string")throw new Error("This method should only be called if the source is a string");let r=n.map(i=>e.substring(i.start,i.end));return qo.lastIndex=0,this.source.replace(qo,(i,o)=>ga(r[parseInt(o,10)]||""))}_buildAnchorCache(){if(typeof this.source!="string")throw new Error("This method should only be called if the source is a string");let e=[],n=[],r=[],i=[],o,s,l,a;for(o=0,s=this.source.length;o<s;o++)l=this.source.charAt(o),e[o]=l,n[o]=l,r[o]=l,i[o]=l,l==="\\"&&o+1<s&&(a=this.source.charAt(o+1),a==="A"?(e[o+1]="￿",n[o+1]="￿",r[o+1]="A",i[o+1]="A"):a==="G"?(e[o+1]="￿",n[o+1]="G",r[o+1]="￿",i[o+1]="G"):(e[o+1]=a,n[o+1]=a,r[o+1]=a,i[o+1]=a),o++);return{A0_G0:e.join(""),A0_G1:n.join(""),A1_G0:r.join(""),A1_G1:i.join("")}}resolveAnchors(e,n){return!this.hasAnchor||!this._anchorCache||typeof this.source!="string"?this.source:e?n?this._anchorCache.A1_G1:this._anchorCache.A1_G0:n?this._anchorCache.A0_G1:this._anchorCache.A0_G0}},fn=class{_items;_hasAnchors;_cached;_anchorCache;constructor(){this._items=[],this._hasAnchors=!1,this._cached=null,this._anchorCache={A0_G0:null,A0_G1:null,A1_G0:null,A1_G1:null}}dispose(){this._disposeCaches()}_disposeCaches(){this._cached&&(this._cached.dispose(),this._cached=null),this._anchorCache.A0_G0&&(this._anchorCache.A0_G0.dispose(),this._anchorCache.A0_G0=null),this._anchorCache.A0_G1&&(this._anchorCache.A0_G1.dispose(),this._anchorCache.A0_G1=null),this._anchorCache.A1_G0&&(this._anchorCache.A1_G0.dispose(),this._anchorCache.A1_G0=null),this._anchorCache.A1_G1&&(this._anchorCache.A1_G1.dispose(),this._anchorCache.A1_G1=null)}push(t){this._items.push(t),this._hasAnchors=this._hasAnchors||t.hasAnchor}unshift(t){this._items.unshift(t),this._hasAnchors=this._hasAnchors||t.hasAnchor}length(){return this._items.length}setSource(t,e){this._items[t].source!==e&&(this._disposeCaches(),this._items[t].setSource(e))}compile(t){if(!this._cached){let e=this._items.map(n=>n.source);this._cached=new Go(t,e,this._items.map(n=>n.ruleId))}return this._cached}compileAG(t,e,n){return this._hasAnchors?e?n?(this._anchorCache.A1_G1||(this._anchorCache.A1_G1=this._resolveAnchors(t,e,n)),this._anchorCache.A1_G1):(this._anchorCache.A1_G0||(this._anchorCache.A1_G0=this._resolveAnchors(t,e,n)),this._anchorCache.A1_G0):n?(this._anchorCache.A0_G1||(this._anchorCache.A0_G1=this._resolveAnchors(t,e,n)),this._anchorCache.A0_G1):(this._anchorCache.A0_G0||(this._anchorCache.A0_G0=this._resolveAnchors(t,e,n)),this._anchorCache.A0_G0):this.compile(t)}_resolveAnchors(t,e,n){let r=this._items.map(i=>i.resolveAnchors(e,n));return new Go(t,r,this._items.map(i=>i.ruleId))}},Go=class{constructor(t,e,n){this.regExps=e,this.rules=n,this.scanner=t.createOnigScanner(e)}scanner;dispose(){typeof this.scanner.dispose=="function"&&this.scanner.dispose()}toString(){const t=[];for(let e=0,n=this.rules.length;e<n;e++)t.push(" - "+this.rules[e]+": "+this.regExps[e]);return t.join(`
61
- `)}findNextMatchSync(t,e,n){const r=this.scanner.findNextMatchSync(t,e,n);return r?{ruleId:this.rules[r.index],captureIndices:r.captureIndices}:null}},Or=class{constructor(t,e){this.languageId=t,this.tokenType=e}},Zp=class li{_defaultAttributes;_embeddedLanguagesMatcher;constructor(e,n){this._defaultAttributes=new Or(e,8),this._embeddedLanguagesMatcher=new em(Object.entries(n||{}))}getDefaultAttributes(){return this._defaultAttributes}getBasicScopeAttributes(e){return e===null?li._NULL_SCOPE_METADATA:this._getBasicScopeAttributes.get(e)}static _NULL_SCOPE_METADATA=new Or(0,0);_getBasicScopeAttributes=new _a(e=>{const n=this._scopeToLanguage(e),r=this._toStandardTokenType(e);return new Or(n,r)});_scopeToLanguage(e){return this._embeddedLanguagesMatcher.match(e)||0}_toStandardTokenType(e){const n=e.match(li.STANDARD_TOKEN_TYPE_REGEXP);if(!n)return 8;switch(n[1]){case"comment":return 1;case"string":return 2;case"regex":return 3;case"meta.embedded":return 0}throw new Error("Unexpected match for standard token type!")}static STANDARD_TOKEN_TYPE_REGEXP=/\b(comment|string|regex|meta\.embedded)\b/},em=class{values;scopesRegExp;constructor(t){if(t.length===0)this.values=null,this.scopesRegExp=null;else{this.values=new Map(t);const e=t.map(([n,r])=>ga(n));e.sort(),e.reverse(),this.scopesRegExp=new RegExp(`^((${e.join(")|(")}))($|\\.)`,"")}}match(t){if(!this.scopesRegExp)return;const e=t.match(this.scopesRegExp);if(e)return this.values.get(e[1])}},Uo=class{constructor(t,e){this.stack=t,this.stoppedEarly=e}};function Ta(t,e,n,r,i,o,s,l){const a=e.content.length;let c=!1,u=-1;if(s){const f=tm(t,e,n,r,i,o);i=f.stack,r=f.linePos,n=f.isFirstLine,u=f.anchorPosition}const d=Date.now();for(;!c;){if(l!==0&&Date.now()-d>l)return new Uo(i,!0);h()}return new Uo(i,!1);function h(){const f=nm(t,e,n,r,i,u);if(!f){o.produce(i,a),c=!0;return}const g=f.captureIndices,y=f.matchedRuleId,x=g&&g.length>0?g[0].end>r:!1;if(y===Yp){const v=i.getRule(t);o.produce(i,g[0].start),i=i.withContentNameScopesList(i.nameScopesList),sn(t,e,n,i,o,v.endCaptures,g),o.produce(i,g[0].end);const k=i;if(i=i.parent,u=k.getAnchorPos(),!x&&k.getEnterPos()===r){i=k,o.produce(i,a),c=!0;return}}else{const v=t.getRule(y);o.produce(i,g[0].start);const k=i,b=v.getName(e.content,g),E=i.contentNameScopesList.pushAttributed(b,t);if(i=i.push(y,r,u,g[0].end===a,null,E,E),v instanceof ai){const P=v;sn(t,e,n,i,o,P.beginCaptures,g),o.produce(i,g[0].end),u=g[0].end;const V=P.getContentName(e.content,g),q=E.pushAttributed(V,t);if(i=i.withContentNameScopesList(q),P.endHasBackReferences&&(i=i.withEndRule(P.getEndWithResolvedBackReferences(e.content,g))),!x&&k.hasSameRuleAs(i)){i=i.pop(),o.produce(i,a),c=!0;return}}else if(v instanceof Yn){const P=v;sn(t,e,n,i,o,P.beginCaptures,g),o.produce(i,g[0].end),u=g[0].end;const V=P.getContentName(e.content,g),q=E.pushAttributed(V,t);if(i=i.withContentNameScopesList(q),P.whileHasBackReferences&&(i=i.withEndRule(P.getWhileWithResolvedBackReferences(e.content,g))),!x&&k.hasSameRuleAs(i)){i=i.pop(),o.produce(i,a),c=!0;return}}else if(sn(t,e,n,i,o,v.captures,g),o.produce(i,g[0].end),i=i.pop(),!x){i=i.safePop(),o.produce(i,a),c=!0;return}}g[0].end>r&&(r=g[0].end,n=!1)}}function tm(t,e,n,r,i,o){let s=i.beginRuleCapturedEOL?0:-1;const l=[];for(let a=i;a;a=a.pop()){const c=a.getRule(t);c instanceof Yn&&l.push({rule:c,stack:a})}for(let a=l.pop();a;a=l.pop()){const{ruleScanner:c,findOptions:u}=om(a.rule,t,a.stack.endRule,n,r===s),d=c.findNextMatchSync(e,r,u);if(d){if(d.ruleId!==wa){i=a.stack.pop();break}d.captureIndices&&d.captureIndices.length&&(o.produce(a.stack,d.captureIndices[0].start),sn(t,e,n,a.stack,o,a.rule.whileCaptures,d.captureIndices),o.produce(a.stack,d.captureIndices[0].end),s=d.captureIndices[0].end,d.captureIndices[0].end>r&&(r=d.captureIndices[0].end,n=!1))}else{i=a.stack.pop();break}}return{stack:i,linePos:r,anchorPosition:s,isFirstLine:n}}function nm(t,e,n,r,i,o){const s=rm(t,e,n,r,i,o),l=t.getInjections();if(l.length===0)return s;const a=im(l,t,e,n,r,i,o);if(!a)return s;if(!s)return a;const c=s.captureIndices[0].start,u=a.captureIndices[0].start;return u<c||a.priorityMatch&&u===c?a:s}function rm(t,e,n,r,i,o){const s=i.getRule(t),{ruleScanner:l,findOptions:a}=Aa(s,t,i.endRule,n,r===o),c=l.findNextMatchSync(e,r,a);return c?{captureIndices:c.captureIndices,matchedRuleId:c.ruleId}:null}function im(t,e,n,r,i,o,s){let l=Number.MAX_VALUE,a=null,c,u=0;const d=o.contentNameScopesList.getScopeNames();for(let h=0,f=t.length;h<f;h++){const g=t[h];if(!g.matcher(d))continue;const y=e.getRule(g.ruleId),{ruleScanner:x,findOptions:v}=Aa(y,e,null,r,i===s),k=x.findNextMatchSync(n,i,v);if(!k)continue;const b=k.captureIndices[0].start;if(!(b>=l)&&(l=b,a=k.captureIndices,c=k.ruleId,u=g.priority,l===i))break}return a?{priorityMatch:u===-1,captureIndices:a,matchedRuleId:c}:null}function Aa(t,e,n,r,i){return{ruleScanner:t.compileAG(e,n,r,i),findOptions:0}}function om(t,e,n,r,i){return{ruleScanner:t.compileWhileAG(e,n,r,i),findOptions:0}}function sn(t,e,n,r,i,o,s){if(o.length===0)return;const l=e.content,a=Math.min(o.length,s.length),c=[],u=s[0].end;for(let d=0;d<a;d++){const h=o[d];if(h===null)continue;const f=s[d];if(f.length===0)continue;if(f.start>u)break;for(;c.length>0&&c[c.length-1].endPos<=f.start;)i.produceFromScopes(c[c.length-1].scopes,c[c.length-1].endPos),c.pop();if(c.length>0?i.produceFromScopes(c[c.length-1].scopes,f.start):i.produce(r,f.start),h.retokenizeCapturedWithRuleId){const y=h.getName(l,s),x=r.contentNameScopesList.pushAttributed(y,t),v=h.getContentName(l,s),k=x.pushAttributed(v,t),b=r.push(h.retokenizeCapturedWithRuleId,f.start,-1,!1,null,x,k),E=t.createOnigString(l.substring(0,f.end));Ta(t,E,n&&f.start===0,f.start,b,i,!1,0),ba(E);continue}const g=h.getName(l,s);if(g!==null){const x=(c.length>0?c[c.length-1].scopes:r.contentNameScopesList).pushAttributed(g,t);c.push(new sm(x,f.end))}}for(;c.length>0;)i.produceFromScopes(c[c.length-1].scopes,c[c.length-1].endPos),c.pop()}var sm=class{scopes;endPos;constructor(t,e){this.scopes=t,this.endPos=e}};function am(t,e,n,r,i,o,s,l){return new cm(t,e,n,r,i,o,s,l)}function Wo(t,e,n,r,i){const o=Kn(e,Qn),s=xa.getCompiledRuleId(n,r,i.repository);for(const l of o)t.push({debugSelector:e,matcher:l.matcher,ruleId:s,grammar:i,priority:l.priority})}function Qn(t,e){if(e.length<t.length)return!1;let n=0;return t.every(r=>{for(let i=n;i<e.length;i++)if(lm(e[i],r))return n=i+1,!0;return!1})}function lm(t,e){if(!t)return!1;if(t===e)return!0;const n=e.length;return t.length>n&&t.substr(0,n)===e&&t[n]==="."}var cm=class{constructor(t,e,n,r,i,o,s,l){if(this._rootScopeName=t,this.balancedBracketSelectors=o,this._onigLib=l,this._basicScopeAttributesProvider=new Zp(n,r),this._rootId=-1,this._lastRuleId=0,this._ruleId2desc=[null],this._includedGrammars={},this._grammarRepository=s,this._grammar=Ko(e,null),this._injections=null,this._tokenTypeMatchers=[],i)for(const a of Object.keys(i)){const c=Kn(a,Qn);for(const u of c)this._tokenTypeMatchers.push({matcher:u.matcher,type:i[a]})}}_rootId;_lastRuleId;_ruleId2desc;_includedGrammars;_grammarRepository;_grammar;_injections;_basicScopeAttributesProvider;_tokenTypeMatchers;get themeProvider(){return this._grammarRepository}dispose(){for(const t of this._ruleId2desc)t&&t.dispose()}createOnigScanner(t){return this._onigLib.createOnigScanner(t)}createOnigString(t){return this._onigLib.createOnigString(t)}getMetadataForScope(t){return this._basicScopeAttributesProvider.getBasicScopeAttributes(t)}_collectInjections(){const t={lookup:i=>i===this._rootScopeName?this._grammar:this.getExternalGrammar(i),injections:i=>this._grammarRepository.injections(i)},e=[],n=this._rootScopeName,r=t.lookup(n);if(r){const i=r.injections;if(i)for(let s in i)Wo(e,s,i[s],this,r);const o=this._grammarRepository.injections(n);o&&o.forEach(s=>{const l=this.getExternalGrammar(s);if(l){const a=l.injectionSelector;a&&Wo(e,a,l,this,l)}})}return e.sort((i,o)=>i.priority-o.priority),e}getInjections(){return this._injections===null&&(this._injections=this._collectInjections()),this._injections}registerRule(t){const e=++this._lastRuleId,n=t(e);return this._ruleId2desc[e]=n,n}getRule(t){return this._ruleId2desc[t]}getExternalGrammar(t,e){if(this._includedGrammars[t])return this._includedGrammars[t];if(this._grammarRepository){const n=this._grammarRepository.lookup(t);if(n)return this._includedGrammars[t]=Ko(n,e&&e.$base),this._includedGrammars[t]}}tokenizeLine(t,e,n=0){const r=this._tokenize(t,e,!1,n);return{tokens:r.lineTokens.getResult(r.ruleStack,r.lineLength),ruleStack:r.ruleStack,stoppedEarly:r.stoppedEarly}}tokenizeLine2(t,e,n=0){const r=this._tokenize(t,e,!0,n);return{tokens:r.lineTokens.getBinaryResult(r.ruleStack,r.lineLength),ruleStack:r.ruleStack,stoppedEarly:r.stoppedEarly}}_tokenize(t,e,n,r){this._rootId===-1&&(this._rootId=xa.getCompiledRuleId(this._grammar.repository.$self,this,this._grammar.repository),this.getInjections());let i;if(!e||e===ci.NULL){i=!0;const c=this._basicScopeAttributesProvider.getDefaultAttributes(),u=this.themeProvider.getDefaults(),d=zt.set(0,c.languageId,c.tokenType,null,u.fontStyle,u.foregroundId,u.backgroundId),h=this.getRule(this._rootId).getName(null,null);let f;h?f=ln.createRootAndLookUpScopeName(h,d,this):f=ln.createRoot("unknown",d),e=new ci(null,this._rootId,-1,-1,!1,null,f,f)}else i=!1,e.reset();t=t+`
62
- `;const o=this.createOnigString(t),s=o.content.length,l=new dm(n,t,this._tokenTypeMatchers,this.balancedBracketSelectors),a=Ta(this,o,i,0,e,l,!0,r);return ba(o),{lineLength:s,lineTokens:l,ruleStack:a.stack,stoppedEarly:a.stoppedEarly}}};function Ko(t,e){return t=Rp(t),t.repository=t.repository||{},t.repository.$self={$vscodeTextmateLocation:t.$vscodeTextmateLocation,patterns:t.patterns,name:t.scopeName},t.repository.$base=e||t.repository.$self,t}var ln=class Ye{constructor(e,n,r){this.parent=e,this.scopePath=n,this.tokenAttributes=r}static fromExtension(e,n){let r=e,i=e?.scopePath??null;for(const o of n)i=Pr.push(i,o.scopeNames),r=new Ye(r,i,o.encodedTokenAttributes);return r}static createRoot(e,n){return new Ye(null,new Pr(null,e),n)}static createRootAndLookUpScopeName(e,n,r){const i=r.getMetadataForScope(e),o=new Pr(null,e),s=r.themeProvider.themeMatch(o),l=Ye.mergeAttributes(n,i,s);return new Ye(null,o,l)}get scopeName(){return this.scopePath.scopeName}toString(){return this.getScopeNames().join(" ")}equals(e){return Ye.equals(this,e)}static equals(e,n){do{if(e===n||!e&&!n)return!0;if(!e||!n||e.scopeName!==n.scopeName||e.tokenAttributes!==n.tokenAttributes)return!1;e=e.parent,n=n.parent}while(!0)}static mergeAttributes(e,n,r){let i=-1,o=0,s=0;return r!==null&&(i=r.fontStyle,o=r.foregroundId,s=r.backgroundId),zt.set(e,n.languageId,n.tokenType,null,i,o,s)}pushAttributed(e,n){if(e===null)return this;if(e.indexOf(" ")===-1)return Ye._pushAttributed(this,e,n);const r=e.split(/ /g);let i=this;for(const o of r)i=Ye._pushAttributed(i,o,n);return i}static _pushAttributed(e,n,r){const i=r.getMetadataForScope(n),o=e.scopePath.push(n),s=r.themeProvider.themeMatch(o),l=Ye.mergeAttributes(e.tokenAttributes,i,s);return new Ye(e,o,l)}getScopeNames(){return this.scopePath.getSegments()}getExtensionIfDefined(e){const n=[];let r=this;for(;r&&r!==e;)n.push({encodedTokenAttributes:r.tokenAttributes,scopeNames:r.scopePath.getExtensionIfDefined(r.parent?.scopePath??null)}),r=r.parent;return r===e?n.reverse():void 0}},ci=class gt{constructor(e,n,r,i,o,s,l,a){this.parent=e,this.ruleId=n,this.beginRuleCapturedEOL=o,this.endRule=s,this.nameScopesList=l,this.contentNameScopesList=a,this.depth=this.parent?this.parent.depth+1:1,this._enterPos=r,this._anchorPos=i}_stackElementBrand=void 0;static NULL=new gt(null,0,0,0,!1,null,null,null);_enterPos;_anchorPos;depth;equals(e){return e===null?!1:gt._equals(this,e)}static _equals(e,n){return e===n?!0:this._structuralEquals(e,n)?ln.equals(e.contentNameScopesList,n.contentNameScopesList):!1}static _structuralEquals(e,n){do{if(e===n||!e&&!n)return!0;if(!e||!n||e.depth!==n.depth||e.ruleId!==n.ruleId||e.endRule!==n.endRule)return!1;e=e.parent,n=n.parent}while(!0)}clone(){return this}static _reset(e){for(;e;)e._enterPos=-1,e._anchorPos=-1,e=e.parent}reset(){gt._reset(this)}pop(){return this.parent}safePop(){return this.parent?this.parent:this}push(e,n,r,i,o,s,l){return new gt(this,e,n,r,i,o,s,l)}getEnterPos(){return this._enterPos}getAnchorPos(){return this._anchorPos}getRule(e){return e.getRule(this.ruleId)}toString(){const e=[];return this._writeString(e,0),"["+e.join(",")+"]"}_writeString(e,n){return this.parent&&(n=this.parent._writeString(e,n)),e[n++]=`(${this.ruleId}, ${this.nameScopesList?.toString()}, ${this.contentNameScopesList?.toString()})`,n}withContentNameScopesList(e){return this.contentNameScopesList===e?this:this.parent.push(this.ruleId,this._enterPos,this._anchorPos,this.beginRuleCapturedEOL,this.endRule,this.nameScopesList,e)}withEndRule(e){return this.endRule===e?this:new gt(this.parent,this.ruleId,this._enterPos,this._anchorPos,this.beginRuleCapturedEOL,e,this.nameScopesList,this.contentNameScopesList)}hasSameRuleAs(e){let n=this;for(;n&&n._enterPos===e._enterPos;){if(n.ruleId===e.ruleId)return!0;n=n.parent}return!1}toStateStackFrame(){return{ruleId:this.ruleId,beginRuleCapturedEOL:this.beginRuleCapturedEOL,endRule:this.endRule,nameScopesList:this.nameScopesList?.getExtensionIfDefined(this.parent?.nameScopesList??null)??[],contentNameScopesList:this.contentNameScopesList?.getExtensionIfDefined(this.nameScopesList)??[]}}static pushFrame(e,n){const r=ln.fromExtension(e?.nameScopesList??null,n.nameScopesList);return new gt(e,n.ruleId,n.enterPos??-1,n.anchorPos??-1,n.beginRuleCapturedEOL,n.endRule,r,ln.fromExtension(r,n.contentNameScopesList))}},um=class{balancedBracketScopes;unbalancedBracketScopes;allowAny=!1;constructor(t,e){this.balancedBracketScopes=t.flatMap(n=>n==="*"?(this.allowAny=!0,[]):Kn(n,Qn).map(r=>r.matcher)),this.unbalancedBracketScopes=e.flatMap(n=>Kn(n,Qn).map(r=>r.matcher))}get matchesAlways(){return this.allowAny&&this.unbalancedBracketScopes.length===0}get matchesNever(){return this.balancedBracketScopes.length===0&&!this.allowAny}match(t){for(const e of this.unbalancedBracketScopes)if(e(t))return!1;for(const e of this.balancedBracketScopes)if(e(t))return!0;return this.allowAny}},dm=class{constructor(t,e,n,r){this.balancedBracketSelectors=r,this._emitBinaryTokens=t,this._tokenTypeOverrides=n,this._lineText=null,this._tokens=[],this._binaryTokens=[],this._lastTokenEndIndex=0}_emitBinaryTokens;_lineText;_tokens;_binaryTokens;_lastTokenEndIndex;_tokenTypeOverrides;produce(t,e){this.produceFromScopes(t.contentNameScopesList,e)}produceFromScopes(t,e){if(this._lastTokenEndIndex>=e)return;if(this._emitBinaryTokens){let r=t?.tokenAttributes??0,i=!1;if(this.balancedBracketSelectors?.matchesAlways&&(i=!0),this._tokenTypeOverrides.length>0||this.balancedBracketSelectors&&!this.balancedBracketSelectors.matchesAlways&&!this.balancedBracketSelectors.matchesNever){const o=t?.getScopeNames()??[];for(const s of this._tokenTypeOverrides)s.matcher(o)&&(r=zt.set(r,0,s.type,null,-1,0,0));this.balancedBracketSelectors&&(i=this.balancedBracketSelectors.match(o))}if(i&&(r=zt.set(r,0,8,i,-1,0,0)),this._binaryTokens.length>0&&this._binaryTokens[this._binaryTokens.length-1]===r){this._lastTokenEndIndex=e;return}this._binaryTokens.push(this._lastTokenEndIndex),this._binaryTokens.push(r),this._lastTokenEndIndex=e;return}const n=t?.getScopeNames()??[];this._tokens.push({startIndex:this._lastTokenEndIndex,endIndex:e,scopes:n}),this._lastTokenEndIndex=e}getResult(t,e){return this._tokens.length>0&&this._tokens[this._tokens.length-1].startIndex===e-1&&this._tokens.pop(),this._tokens.length===0&&(this._lastTokenEndIndex=-1,this.produce(t,e),this._tokens[this._tokens.length-1].startIndex=0),this._tokens}getBinaryResult(t,e){this._binaryTokens.length>0&&this._binaryTokens[this._binaryTokens.length-2]===e-1&&(this._binaryTokens.pop(),this._binaryTokens.pop()),this._binaryTokens.length===0&&(this._lastTokenEndIndex=-1,this.produce(t,e),this._binaryTokens[this._binaryTokens.length-2]=0);const n=new Uint32Array(this._binaryTokens.length);for(let r=0,i=this._binaryTokens.length;r<i;r++)n[r]=this._binaryTokens[r];return n}},pm=class{constructor(t,e){this._onigLib=e,this._theme=t}_grammars=new Map;_rawGrammars=new Map;_injectionGrammars=new Map;_theme;dispose(){for(const t of this._grammars.values())t.dispose()}setTheme(t){this._theme=t}getColorMap(){return this._theme.getColorMap()}addGrammar(t,e){this._rawGrammars.set(t.scopeName,t),e&&this._injectionGrammars.set(t.scopeName,e)}lookup(t){return this._rawGrammars.get(t)}injections(t){return this._injectionGrammars.get(t)}getDefaults(){return this._theme.getDefaults()}themeMatch(t){return this._theme.match(t)}grammarForScopeName(t,e,n,r,i){if(!this._grammars.has(t)){let o=this._rawGrammars.get(t);if(!o)return null;this._grammars.set(t,am(t,o,e,n,r,i,this,this._onigLib))}return this._grammars.get(t)}},mm=class{_options;_syncRegistry;_ensureGrammarCache;constructor(e){this._options=e,this._syncRegistry=new pm(Wn.createFromRawTheme(e.theme,e.colorMap),e.onigLib),this._ensureGrammarCache=new Map}dispose(){this._syncRegistry.dispose()}setTheme(e,n){this._syncRegistry.setTheme(Wn.createFromRawTheme(e,n))}getColorMap(){return this._syncRegistry.getColorMap()}loadGrammarWithEmbeddedLanguages(e,n,r){return this.loadGrammarWithConfiguration(e,n,{embeddedLanguages:r})}loadGrammarWithConfiguration(e,n,r){return this._loadGrammar(e,n,r.embeddedLanguages,r.tokenTypes,new um(r.balancedBracketSelectors||[],r.unbalancedBracketSelectors||[]))}loadGrammar(e){return this._loadGrammar(e,0,null,null,null)}_loadGrammar(e,n,r,i,o){const s=new jp(this._syncRegistry,e);for(;s.Q.length>0;)s.Q.map(l=>this._loadSingleGrammar(l.scopeName)),s.processQueue();return this._grammarForScopeName(e,n,r,i,o)}_loadSingleGrammar(e){this._ensureGrammarCache.has(e)||(this._doLoadSingleGrammar(e),this._ensureGrammarCache.set(e,!0))}_doLoadSingleGrammar(e){const n=this._options.loadGrammar(e);if(n){const r=typeof this._options.getInjections=="function"?this._options.getInjections(e):void 0;this._syncRegistry.addGrammar(n,r)}}addGrammar(e,n=[],r=0,i=null){return this._syncRegistry.addGrammar(e,n),this._grammarForScopeName(e.scopeName,r,i)}_grammarForScopeName(e,n=0,r=null,i=null,o=null){return this._syncRegistry.grammarForScopeName(e,n,r,i,o)}},ui=ci.NULL;const fm=["area","base","basefont","bgsound","br","col","command","embed","frame","hr","image","img","input","keygen","link","meta","param","source","track","wbr"];class kn{constructor(e,n,r){this.normal=n,this.property=e,r&&(this.space=r)}}kn.prototype.normal={};kn.prototype.property={};kn.prototype.space=void 0;function Sa(t,e){const n={},r={};for(const i of t)Object.assign(n,i.property),Object.assign(r,i.normal);return new kn(n,r,e)}function di(t){return t.toLowerCase()}class De{constructor(e,n){this.attribute=n,this.property=e}}De.prototype.attribute="";De.prototype.booleanish=!1;De.prototype.boolean=!1;De.prototype.commaOrSpaceSeparated=!1;De.prototype.commaSeparated=!1;De.prototype.defined=!1;De.prototype.mustUseProperty=!1;De.prototype.number=!1;De.prototype.overloadedBoolean=!1;De.prototype.property="";De.prototype.spaceSeparated=!1;De.prototype.space=void 0;let hm=0;const X=Et(),me=Et(),pi=Et(),L=Et(),ae=Et(),$t=Et(),Ne=Et();function Et(){return 2**++hm}const mi=Object.freeze(Object.defineProperty({__proto__:null,boolean:X,booleanish:me,commaOrSpaceSeparated:Ne,commaSeparated:$t,number:L,overloadedBoolean:pi,spaceSeparated:ae},Symbol.toStringTag,{value:"Module"})),Ir=Object.keys(mi);class zi extends De{constructor(e,n,r,i){let o=-1;if(super(e,n),Xo(this,"space",i),typeof r=="number")for(;++o<Ir.length;){const s=Ir[o];Xo(this,Ir[o],(r&mi[s])===mi[s])}}}zi.prototype.defined=!0;function Xo(t,e,n){n&&(t[e]=n)}function Ht(t){const e={},n={};for(const[r,i]of Object.entries(t.properties)){const o=new zi(r,t.transform(t.attributes||{},r),i,t.space);t.mustUseProperty&&t.mustUseProperty.includes(r)&&(o.mustUseProperty=!0),e[r]=o,n[di(r)]=r,n[di(o.attribute)]=r}return new kn(e,n,t.space)}const Ra=Ht({properties:{ariaActiveDescendant:null,ariaAtomic:me,ariaAutoComplete:null,ariaBusy:me,ariaChecked:me,ariaColCount:L,ariaColIndex:L,ariaColSpan:L,ariaControls:ae,ariaCurrent:null,ariaDescribedBy:ae,ariaDetails:null,ariaDisabled:me,ariaDropEffect:ae,ariaErrorMessage:null,ariaExpanded:me,ariaFlowTo:ae,ariaGrabbed:me,ariaHasPopup:null,ariaHidden:me,ariaInvalid:null,ariaKeyShortcuts:null,ariaLabel:null,ariaLabelledBy:ae,ariaLevel:L,ariaLive:null,ariaModal:me,ariaMultiLine:me,ariaMultiSelectable:me,ariaOrientation:null,ariaOwns:ae,ariaPlaceholder:null,ariaPosInSet:L,ariaPressed:me,ariaReadOnly:me,ariaRelevant:null,ariaRequired:me,ariaRoleDescription:ae,ariaRowCount:L,ariaRowIndex:L,ariaRowSpan:L,ariaSelected:me,ariaSetSize:L,ariaSort:null,ariaValueMax:L,ariaValueMin:L,ariaValueNow:L,ariaValueText:null,role:null},transform(t,e){return e==="role"?e:"aria-"+e.slice(4).toLowerCase()}});function La(t,e){return e in t?t[e]:e}function Ca(t,e){return La(t,e.toLowerCase())}const gm=Ht({attributes:{acceptcharset:"accept-charset",classname:"class",htmlfor:"for",httpequiv:"http-equiv"},mustUseProperty:["checked","multiple","muted","selected"],properties:{abbr:null,accept:$t,acceptCharset:ae,accessKey:ae,action:null,allow:null,allowFullScreen:X,allowPaymentRequest:X,allowUserMedia:X,alt:null,as:null,async:X,autoCapitalize:null,autoComplete:ae,autoFocus:X,autoPlay:X,blocking:ae,capture:null,charSet:null,checked:X,cite:null,className:ae,cols:L,colSpan:null,content:null,contentEditable:me,controls:X,controlsList:ae,coords:L|$t,crossOrigin:null,data:null,dateTime:null,decoding:null,default:X,defer:X,dir:null,dirName:null,disabled:X,download:pi,draggable:me,encType:null,enterKeyHint:null,fetchPriority:null,form:null,formAction:null,formEncType:null,formMethod:null,formNoValidate:X,formTarget:null,headers:ae,height:L,hidden:pi,high:L,href:null,hrefLang:null,htmlFor:ae,httpEquiv:ae,id:null,imageSizes:null,imageSrcSet:null,inert:X,inputMode:null,integrity:null,is:null,isMap:X,itemId:null,itemProp:ae,itemRef:ae,itemScope:X,itemType:ae,kind:null,label:null,lang:null,language:null,list:null,loading:null,loop:X,low:L,manifest:null,max:null,maxLength:L,media:null,method:null,min:null,minLength:L,multiple:X,muted:X,name:null,nonce:null,noModule:X,noValidate:X,onAbort:null,onAfterPrint:null,onAuxClick:null,onBeforeMatch:null,onBeforePrint:null,onBeforeToggle:null,onBeforeUnload:null,onBlur:null,onCancel:null,onCanPlay:null,onCanPlayThrough:null,onChange:null,onClick:null,onClose:null,onContextLost:null,onContextMenu:null,onContextRestored:null,onCopy:null,onCueChange:null,onCut:null,onDblClick:null,onDrag:null,onDragEnd:null,onDragEnter:null,onDragExit:null,onDragLeave:null,onDragOver:null,onDragStart:null,onDrop:null,onDurationChange:null,onEmptied:null,onEnded:null,onError:null,onFocus:null,onFormData:null,onHashChange:null,onInput:null,onInvalid:null,onKeyDown:null,onKeyPress:null,onKeyUp:null,onLanguageChange:null,onLoad:null,onLoadedData:null,onLoadedMetadata:null,onLoadEnd:null,onLoadStart:null,onMessage:null,onMessageError:null,onMouseDown:null,onMouseEnter:null,onMouseLeave:null,onMouseMove:null,onMouseOut:null,onMouseOver:null,onMouseUp:null,onOffline:null,onOnline:null,onPageHide:null,onPageShow:null,onPaste:null,onPause:null,onPlay:null,onPlaying:null,onPopState:null,onProgress:null,onRateChange:null,onRejectionHandled:null,onReset:null,onResize:null,onScroll:null,onScrollEnd:null,onSecurityPolicyViolation:null,onSeeked:null,onSeeking:null,onSelect:null,onSlotChange:null,onStalled:null,onStorage:null,onSubmit:null,onSuspend:null,onTimeUpdate:null,onToggle:null,onUnhandledRejection:null,onUnload:null,onVolumeChange:null,onWaiting:null,onWheel:null,open:X,optimum:L,pattern:null,ping:ae,placeholder:null,playsInline:X,popover:null,popoverTarget:null,popoverTargetAction:null,poster:null,preload:null,readOnly:X,referrerPolicy:null,rel:ae,required:X,reversed:X,rows:L,rowSpan:L,sandbox:ae,scope:null,scoped:X,seamless:X,selected:X,shadowRootClonable:X,shadowRootDelegatesFocus:X,shadowRootMode:null,shape:null,size:L,sizes:null,slot:null,span:L,spellCheck:me,src:null,srcDoc:null,srcLang:null,srcSet:null,start:L,step:null,style:null,tabIndex:L,target:null,title:null,translate:null,type:null,typeMustMatch:X,useMap:null,value:me,width:L,wrap:null,writingSuggestions:null,align:null,aLink:null,archive:ae,axis:null,background:null,bgColor:null,border:L,borderColor:null,bottomMargin:L,cellPadding:null,cellSpacing:null,char:null,charOff:null,classId:null,clear:null,code:null,codeBase:null,codeType:null,color:null,compact:X,declare:X,event:null,face:null,frame:null,frameBorder:null,hSpace:L,leftMargin:L,link:null,longDesc:null,lowSrc:null,marginHeight:L,marginWidth:L,noResize:X,noHref:X,noShade:X,noWrap:X,object:null,profile:null,prompt:null,rev:null,rightMargin:L,rules:null,scheme:null,scrolling:me,standby:null,summary:null,text:null,topMargin:L,valueType:null,version:null,vAlign:null,vLink:null,vSpace:L,allowTransparency:null,autoCorrect:null,autoSave:null,disablePictureInPicture:X,disableRemotePlayback:X,prefix:null,property:null,results:L,security:null,unselectable:null},space:"html",transform:Ca}),_m=Ht({attributes:{accentHeight:"accent-height",alignmentBaseline:"alignment-baseline",arabicForm:"arabic-form",baselineShift:"baseline-shift",capHeight:"cap-height",className:"class",clipPath:"clip-path",clipRule:"clip-rule",colorInterpolation:"color-interpolation",colorInterpolationFilters:"color-interpolation-filters",colorProfile:"color-profile",colorRendering:"color-rendering",crossOrigin:"crossorigin",dataType:"datatype",dominantBaseline:"dominant-baseline",enableBackground:"enable-background",fillOpacity:"fill-opacity",fillRule:"fill-rule",floodColor:"flood-color",floodOpacity:"flood-opacity",fontFamily:"font-family",fontSize:"font-size",fontSizeAdjust:"font-size-adjust",fontStretch:"font-stretch",fontStyle:"font-style",fontVariant:"font-variant",fontWeight:"font-weight",glyphName:"glyph-name",glyphOrientationHorizontal:"glyph-orientation-horizontal",glyphOrientationVertical:"glyph-orientation-vertical",hrefLang:"hreflang",horizAdvX:"horiz-adv-x",horizOriginX:"horiz-origin-x",horizOriginY:"horiz-origin-y",imageRendering:"image-rendering",letterSpacing:"letter-spacing",lightingColor:"lighting-color",markerEnd:"marker-end",markerMid:"marker-mid",markerStart:"marker-start",navDown:"nav-down",navDownLeft:"nav-down-left",navDownRight:"nav-down-right",navLeft:"nav-left",navNext:"nav-next",navPrev:"nav-prev",navRight:"nav-right",navUp:"nav-up",navUpLeft:"nav-up-left",navUpRight:"nav-up-right",onAbort:"onabort",onActivate:"onactivate",onAfterPrint:"onafterprint",onBeforePrint:"onbeforeprint",onBegin:"onbegin",onCancel:"oncancel",onCanPlay:"oncanplay",onCanPlayThrough:"oncanplaythrough",onChange:"onchange",onClick:"onclick",onClose:"onclose",onCopy:"oncopy",onCueChange:"oncuechange",onCut:"oncut",onDblClick:"ondblclick",onDrag:"ondrag",onDragEnd:"ondragend",onDragEnter:"ondragenter",onDragExit:"ondragexit",onDragLeave:"ondragleave",onDragOver:"ondragover",onDragStart:"ondragstart",onDrop:"ondrop",onDurationChange:"ondurationchange",onEmptied:"onemptied",onEnd:"onend",onEnded:"onended",onError:"onerror",onFocus:"onfocus",onFocusIn:"onfocusin",onFocusOut:"onfocusout",onHashChange:"onhashchange",onInput:"oninput",onInvalid:"oninvalid",onKeyDown:"onkeydown",onKeyPress:"onkeypress",onKeyUp:"onkeyup",onLoad:"onload",onLoadedData:"onloadeddata",onLoadedMetadata:"onloadedmetadata",onLoadStart:"onloadstart",onMessage:"onmessage",onMouseDown:"onmousedown",onMouseEnter:"onmouseenter",onMouseLeave:"onmouseleave",onMouseMove:"onmousemove",onMouseOut:"onmouseout",onMouseOver:"onmouseover",onMouseUp:"onmouseup",onMouseWheel:"onmousewheel",onOffline:"onoffline",onOnline:"ononline",onPageHide:"onpagehide",onPageShow:"onpageshow",onPaste:"onpaste",onPause:"onpause",onPlay:"onplay",onPlaying:"onplaying",onPopState:"onpopstate",onProgress:"onprogress",onRateChange:"onratechange",onRepeat:"onrepeat",onReset:"onreset",onResize:"onresize",onScroll:"onscroll",onSeeked:"onseeked",onSeeking:"onseeking",onSelect:"onselect",onShow:"onshow",onStalled:"onstalled",onStorage:"onstorage",onSubmit:"onsubmit",onSuspend:"onsuspend",onTimeUpdate:"ontimeupdate",onToggle:"ontoggle",onUnload:"onunload",onVolumeChange:"onvolumechange",onWaiting:"onwaiting",onZoom:"onzoom",overlinePosition:"overline-position",overlineThickness:"overline-thickness",paintOrder:"paint-order",panose1:"panose-1",pointerEvents:"pointer-events",referrerPolicy:"referrerpolicy",renderingIntent:"rendering-intent",shapeRendering:"shape-rendering",stopColor:"stop-color",stopOpacity:"stop-opacity",strikethroughPosition:"strikethrough-position",strikethroughThickness:"strikethrough-thickness",strokeDashArray:"stroke-dasharray",strokeDashOffset:"stroke-dashoffset",strokeLineCap:"stroke-linecap",strokeLineJoin:"stroke-linejoin",strokeMiterLimit:"stroke-miterlimit",strokeOpacity:"stroke-opacity",strokeWidth:"stroke-width",tabIndex:"tabindex",textAnchor:"text-anchor",textDecoration:"text-decoration",textRendering:"text-rendering",transformOrigin:"transform-origin",typeOf:"typeof",underlinePosition:"underline-position",underlineThickness:"underline-thickness",unicodeBidi:"unicode-bidi",unicodeRange:"unicode-range",unitsPerEm:"units-per-em",vAlphabetic:"v-alphabetic",vHanging:"v-hanging",vIdeographic:"v-ideographic",vMathematical:"v-mathematical",vectorEffect:"vector-effect",vertAdvY:"vert-adv-y",vertOriginX:"vert-origin-x",vertOriginY:"vert-origin-y",wordSpacing:"word-spacing",writingMode:"writing-mode",xHeight:"x-height",playbackOrder:"playbackorder",timelineBegin:"timelinebegin"},properties:{about:Ne,accentHeight:L,accumulate:null,additive:null,alignmentBaseline:null,alphabetic:L,amplitude:L,arabicForm:null,ascent:L,attributeName:null,attributeType:null,azimuth:L,bandwidth:null,baselineShift:null,baseFrequency:null,baseProfile:null,bbox:null,begin:null,bias:L,by:null,calcMode:null,capHeight:L,className:ae,clip:null,clipPath:null,clipPathUnits:null,clipRule:null,color:null,colorInterpolation:null,colorInterpolationFilters:null,colorProfile:null,colorRendering:null,content:null,contentScriptType:null,contentStyleType:null,crossOrigin:null,cursor:null,cx:null,cy:null,d:null,dataType:null,defaultAction:null,descent:L,diffuseConstant:L,direction:null,display:null,dur:null,divisor:L,dominantBaseline:null,download:X,dx:null,dy:null,edgeMode:null,editable:null,elevation:L,enableBackground:null,end:null,event:null,exponent:L,externalResourcesRequired:null,fill:null,fillOpacity:L,fillRule:null,filter:null,filterRes:null,filterUnits:null,floodColor:null,floodOpacity:null,focusable:null,focusHighlight:null,fontFamily:null,fontSize:null,fontSizeAdjust:null,fontStretch:null,fontStyle:null,fontVariant:null,fontWeight:null,format:null,fr:null,from:null,fx:null,fy:null,g1:$t,g2:$t,glyphName:$t,glyphOrientationHorizontal:null,glyphOrientationVertical:null,glyphRef:null,gradientTransform:null,gradientUnits:null,handler:null,hanging:L,hatchContentUnits:null,hatchUnits:null,height:null,href:null,hrefLang:null,horizAdvX:L,horizOriginX:L,horizOriginY:L,id:null,ideographic:L,imageRendering:null,initialVisibility:null,in:null,in2:null,intercept:L,k:L,k1:L,k2:L,k3:L,k4:L,kernelMatrix:Ne,kernelUnitLength:null,keyPoints:null,keySplines:null,keyTimes:null,kerning:null,lang:null,lengthAdjust:null,letterSpacing:null,lightingColor:null,limitingConeAngle:L,local:null,markerEnd:null,markerMid:null,markerStart:null,markerHeight:null,markerUnits:null,markerWidth:null,mask:null,maskContentUnits:null,maskUnits:null,mathematical:null,max:null,media:null,mediaCharacterEncoding:null,mediaContentEncodings:null,mediaSize:L,mediaTime:null,method:null,min:null,mode:null,name:null,navDown:null,navDownLeft:null,navDownRight:null,navLeft:null,navNext:null,navPrev:null,navRight:null,navUp:null,navUpLeft:null,navUpRight:null,numOctaves:null,observer:null,offset:null,onAbort:null,onActivate:null,onAfterPrint:null,onBeforePrint:null,onBegin:null,onCancel:null,onCanPlay:null,onCanPlayThrough:null,onChange:null,onClick:null,onClose:null,onCopy:null,onCueChange:null,onCut:null,onDblClick:null,onDrag:null,onDragEnd:null,onDragEnter:null,onDragExit:null,onDragLeave:null,onDragOver:null,onDragStart:null,onDrop:null,onDurationChange:null,onEmptied:null,onEnd:null,onEnded:null,onError:null,onFocus:null,onFocusIn:null,onFocusOut:null,onHashChange:null,onInput:null,onInvalid:null,onKeyDown:null,onKeyPress:null,onKeyUp:null,onLoad:null,onLoadedData:null,onLoadedMetadata:null,onLoadStart:null,onMessage:null,onMouseDown:null,onMouseEnter:null,onMouseLeave:null,onMouseMove:null,onMouseOut:null,onMouseOver:null,onMouseUp:null,onMouseWheel:null,onOffline:null,onOnline:null,onPageHide:null,onPageShow:null,onPaste:null,onPause:null,onPlay:null,onPlaying:null,onPopState:null,onProgress:null,onRateChange:null,onRepeat:null,onReset:null,onResize:null,onScroll:null,onSeeked:null,onSeeking:null,onSelect:null,onShow:null,onStalled:null,onStorage:null,onSubmit:null,onSuspend:null,onTimeUpdate:null,onToggle:null,onUnload:null,onVolumeChange:null,onWaiting:null,onZoom:null,opacity:null,operator:null,order:null,orient:null,orientation:null,origin:null,overflow:null,overlay:null,overlinePosition:L,overlineThickness:L,paintOrder:null,panose1:null,path:null,pathLength:L,patternContentUnits:null,patternTransform:null,patternUnits:null,phase:null,ping:ae,pitch:null,playbackOrder:null,pointerEvents:null,points:null,pointsAtX:L,pointsAtY:L,pointsAtZ:L,preserveAlpha:null,preserveAspectRatio:null,primitiveUnits:null,propagate:null,property:Ne,r:null,radius:null,referrerPolicy:null,refX:null,refY:null,rel:Ne,rev:Ne,renderingIntent:null,repeatCount:null,repeatDur:null,requiredExtensions:Ne,requiredFeatures:Ne,requiredFonts:Ne,requiredFormats:Ne,resource:null,restart:null,result:null,rotate:null,rx:null,ry:null,scale:null,seed:null,shapeRendering:null,side:null,slope:null,snapshotTime:null,specularConstant:L,specularExponent:L,spreadMethod:null,spacing:null,startOffset:null,stdDeviation:null,stemh:null,stemv:null,stitchTiles:null,stopColor:null,stopOpacity:null,strikethroughPosition:L,strikethroughThickness:L,string:null,stroke:null,strokeDashArray:Ne,strokeDashOffset:null,strokeLineCap:null,strokeLineJoin:null,strokeMiterLimit:L,strokeOpacity:L,strokeWidth:null,style:null,surfaceScale:L,syncBehavior:null,syncBehaviorDefault:null,syncMaster:null,syncTolerance:null,syncToleranceDefault:null,systemLanguage:Ne,tabIndex:L,tableValues:null,target:null,targetX:L,targetY:L,textAnchor:null,textDecoration:null,textRendering:null,textLength:null,timelineBegin:null,title:null,transformBehavior:null,type:null,typeOf:Ne,to:null,transform:null,transformOrigin:null,u1:null,u2:null,underlinePosition:L,underlineThickness:L,unicode:null,unicodeBidi:null,unicodeRange:null,unitsPerEm:L,values:null,vAlphabetic:L,vMathematical:L,vectorEffect:null,vHanging:L,vIdeographic:L,version:null,vertAdvY:L,vertOriginX:L,vertOriginY:L,viewBox:null,viewTarget:null,visibility:null,width:null,widths:null,wordSpacing:null,writingMode:null,x:null,x1:null,x2:null,xChannelSelector:null,xHeight:L,y:null,y1:null,y2:null,yChannelSelector:null,z:null,zoomAndPan:null},space:"svg",transform:La}),Pa=Ht({properties:{xLinkActuate:null,xLinkArcRole:null,xLinkHref:null,xLinkRole:null,xLinkShow:null,xLinkTitle:null,xLinkType:null},space:"xlink",transform(t,e){return"xlink:"+e.slice(5).toLowerCase()}}),Oa=Ht({attributes:{xmlnsxlink:"xmlns:xlink"},properties:{xmlnsXLink:null,xmlns:null},space:"xmlns",transform:Ca}),Ia=Ht({properties:{xmlBase:null,xmlLang:null,xmlSpace:null},space:"xml",transform(t,e){return"xml:"+e.slice(3).toLowerCase()}}),ym=/[A-Z]/g,Yo=/-[a-z]/g,vm=/^data[-\w.:]+$/i;function bm(t,e){const n=di(e);let r=e,i=De;if(n in t.normal)return t.property[t.normal[n]];if(n.length>4&&n.slice(0,4)==="data"&&vm.test(e)){if(e.charAt(4)==="-"){const o=e.slice(5).replace(Yo,wm);r="data"+o.charAt(0).toUpperCase()+o.slice(1)}else{const o=e.slice(4);if(!Yo.test(o)){let s=o.replace(ym,km);s.charAt(0)!=="-"&&(s="-"+s),e="data"+s}}i=zi}return new i(r,e)}function km(t){return"-"+t.toLowerCase()}function wm(t){return t.charAt(1).toUpperCase()}const xm=Sa([Ra,gm,Pa,Oa,Ia],"html"),Da=Sa([Ra,_m,Pa,Oa,Ia],"svg"),Qo={}.hasOwnProperty;function Em(t,e){const n=e||{};function r(i,...o){let s=r.invalid;const l=r.handlers;if(i&&Qo.call(i,t)){const a=String(i[t]);s=Qo.call(l,a)?l[a]:r.unknown}if(s)return s.call(this,i,...o)}return r.handlers=n.handlers||{},r.invalid=n.invalid,r.unknown=n.unknown,r}const Tm=/["&'<>`]/g,Am=/[\uD800-\uDBFF][\uDC00-\uDFFF]/g,Sm=/[\x01-\t\v\f\x0E-\x1F\x7F\x81\x8D\x8F\x90\x9D\xA0-\uFFFF]/g,Rm=/[|\\{}()[\]^$+*?.]/g,Jo=new WeakMap;function Lm(t,e){if(t=t.replace(e.subset?Cm(e.subset):Tm,r),e.subset||e.escapeOnly)return t;return t.replace(Am,n).replace(Sm,r);function n(i,o,s){return e.format((i.charCodeAt(0)-55296)*1024+i.charCodeAt(1)-56320+65536,s.charCodeAt(o+2),e)}function r(i,o,s){return e.format(i.charCodeAt(0),s.charCodeAt(o+1),e)}}function Cm(t){let e=Jo.get(t);return e||(e=Pm(t),Jo.set(t,e)),e}function Pm(t){const e=[];let n=-1;for(;++n<t.length;)e.push(t[n].replace(Rm,"\\$&"));return new RegExp("(?:"+e.join("|")+")","g")}const Om=/[\dA-Fa-f]/;function Im(t,e,n){const r="&#x"+t.toString(16).toUpperCase();return n&&e&&!Om.test(String.fromCharCode(e))?r:r+";"}const Dm=/\d/;function Nm(t,e,n){const r="&#"+String(t);return n&&e&&!Dm.test(String.fromCharCode(e))?r:r+";"}const Mm=["AElig","AMP","Aacute","Acirc","Agrave","Aring","Atilde","Auml","COPY","Ccedil","ETH","Eacute","Ecirc","Egrave","Euml","GT","Iacute","Icirc","Igrave","Iuml","LT","Ntilde","Oacute","Ocirc","Ograve","Oslash","Otilde","Ouml","QUOT","REG","THORN","Uacute","Ucirc","Ugrave","Uuml","Yacute","aacute","acirc","acute","aelig","agrave","amp","aring","atilde","auml","brvbar","ccedil","cedil","cent","copy","curren","deg","divide","eacute","ecirc","egrave","eth","euml","frac12","frac14","frac34","gt","iacute","icirc","iexcl","igrave","iquest","iuml","laquo","lt","macr","micro","middot","nbsp","not","ntilde","oacute","ocirc","ograve","ordf","ordm","oslash","otilde","ouml","para","plusmn","pound","quot","raquo","reg","sect","shy","sup1","sup2","sup3","szlig","thorn","times","uacute","ucirc","ugrave","uml","uuml","yacute","yen","yuml"],Dr={nbsp:" ",iexcl:"¡",cent:"¢",pound:"£",curren:"¤",yen:"¥",brvbar:"¦",sect:"§",uml:"¨",copy:"©",ordf:"ª",laquo:"«",not:"¬",shy:"­",reg:"®",macr:"¯",deg:"°",plusmn:"±",sup2:"²",sup3:"³",acute:"´",micro:"µ",para:"¶",middot:"·",cedil:"¸",sup1:"¹",ordm:"º",raquo:"»",frac14:"¼",frac12:"½",frac34:"¾",iquest:"¿",Agrave:"À",Aacute:"Á",Acirc:"Â",Atilde:"Ã",Auml:"Ä",Aring:"Å",AElig:"Æ",Ccedil:"Ç",Egrave:"È",Eacute:"É",Ecirc:"Ê",Euml:"Ë",Igrave:"Ì",Iacute:"Í",Icirc:"Î",Iuml:"Ï",ETH:"Ð",Ntilde:"Ñ",Ograve:"Ò",Oacute:"Ó",Ocirc:"Ô",Otilde:"Õ",Ouml:"Ö",times:"×",Oslash:"Ø",Ugrave:"Ù",Uacute:"Ú",Ucirc:"Û",Uuml:"Ü",Yacute:"Ý",THORN:"Þ",szlig:"ß",agrave:"à",aacute:"á",acirc:"â",atilde:"ã",auml:"ä",aring:"å",aelig:"æ",ccedil:"ç",egrave:"è",eacute:"é",ecirc:"ê",euml:"ë",igrave:"ì",iacute:"í",icirc:"î",iuml:"ï",eth:"ð",ntilde:"ñ",ograve:"ò",oacute:"ó",ocirc:"ô",otilde:"õ",ouml:"ö",divide:"÷",oslash:"ø",ugrave:"ù",uacute:"ú",ucirc:"û",uuml:"ü",yacute:"ý",thorn:"þ",yuml:"ÿ",fnof:"ƒ",Alpha:"Α",Beta:"Β",Gamma:"Γ",Delta:"Δ",Epsilon:"Ε",Zeta:"Ζ",Eta:"Η",Theta:"Θ",Iota:"Ι",Kappa:"Κ",Lambda:"Λ",Mu:"Μ",Nu:"Ν",Xi:"Ξ",Omicron:"Ο",Pi:"Π",Rho:"Ρ",Sigma:"Σ",Tau:"Τ",Upsilon:"Υ",Phi:"Φ",Chi:"Χ",Psi:"Ψ",Omega:"Ω",alpha:"α",beta:"β",gamma:"γ",delta:"δ",epsilon:"ε",zeta:"ζ",eta:"η",theta:"θ",iota:"ι",kappa:"κ",lambda:"λ",mu:"μ",nu:"ν",xi:"ξ",omicron:"ο",pi:"π",rho:"ρ",sigmaf:"ς",sigma:"σ",tau:"τ",upsilon:"υ",phi:"φ",chi:"χ",psi:"ψ",omega:"ω",thetasym:"ϑ",upsih:"ϒ",piv:"ϖ",bull:"•",hellip:"…",prime:"′",Prime:"″",oline:"‾",frasl:"⁄",weierp:"℘",image:"ℑ",real:"ℜ",trade:"™",alefsym:"ℵ",larr:"←",uarr:"↑",rarr:"→",darr:"↓",harr:"↔",crarr:"↵",lArr:"⇐",uArr:"⇑",rArr:"⇒",dArr:"⇓",hArr:"⇔",forall:"∀",part:"∂",exist:"∃",empty:"∅",nabla:"∇",isin:"∈",notin:"∉",ni:"∋",prod:"∏",sum:"∑",minus:"−",lowast:"∗",radic:"√",prop:"∝",infin:"∞",ang:"∠",and:"∧",or:"∨",cap:"∩",cup:"∪",int:"∫",there4:"∴",sim:"∼",cong:"≅",asymp:"≈",ne:"≠",equiv:"≡",le:"≤",ge:"≥",sub:"⊂",sup:"⊃",nsub:"⊄",sube:"⊆",supe:"⊇",oplus:"⊕",otimes:"⊗",perp:"⊥",sdot:"⋅",lceil:"⌈",rceil:"⌉",lfloor:"⌊",rfloor:"⌋",lang:"〈",rang:"〉",loz:"◊",spades:"♠",clubs:"♣",hearts:"♥",diams:"♦",quot:'"',amp:"&",lt:"<",gt:">",OElig:"Œ",oelig:"œ",Scaron:"Š",scaron:"š",Yuml:"Ÿ",circ:"ˆ",tilde:"˜",ensp:" ",emsp:" ",thinsp:" ",zwnj:"‌",zwj:"‍",lrm:"‎",rlm:"‏",ndash:"–",mdash:"—",lsquo:"‘",rsquo:"’",sbquo:"‚",ldquo:"“",rdquo:"”",bdquo:"„",dagger:"†",Dagger:"‡",permil:"‰",lsaquo:"‹",rsaquo:"›",euro:"€"},$m=["cent","copy","divide","gt","lt","not","para","times"],Na={}.hasOwnProperty,fi={};let In;for(In in Dr)Na.call(Dr,In)&&(fi[Dr[In]]=In);const Vm=/[^\dA-Za-z]/;function Bm(t,e,n,r){const i=String.fromCharCode(t);if(Na.call(fi,i)){const o=fi[i],s="&"+o;return n&&Mm.includes(o)&&!$m.includes(o)&&(!r||e&&e!==61&&Vm.test(String.fromCharCode(e)))?s:s+";"}return""}function zm(t,e,n){let r=Im(t,e,n.omitOptionalSemicolons),i;if((n.useNamedReferences||n.useShortestReferences)&&(i=Bm(t,e,n.omitOptionalSemicolons,n.attribute)),(n.useShortestReferences||!i)&&n.useShortestReferences){const o=Nm(t,e,n.omitOptionalSemicolons);o.length<r.length&&(r=o)}return i&&(!n.useShortestReferences||i.length<r.length)?i:r}function Vt(t,e){return Lm(t,Object.assign({format:zm},e))}const Fm=/^>|^->|<!--|-->|--!>|<!-$/g,jm=[">"],qm=["<",">"];function Hm(t,e,n,r){return r.settings.bogusComments?"<?"+Vt(t.value,Object.assign({},r.settings.characterReferences,{subset:jm}))+">":"<!--"+t.value.replace(Fm,i)+"-->";function i(o){return Vt(o,Object.assign({},r.settings.characterReferences,{subset:qm}))}}function Gm(t,e,n,r){return"<!"+(r.settings.upperDoctype?"DOCTYPE":"doctype")+(r.settings.tightDoctype?"":" ")+"html>"}function Zo(t,e){const n=String(t);if(typeof e!="string")throw new TypeError("Expected character");let r=0,i=n.indexOf(e);for(;i!==-1;)r++,i=n.indexOf(e,i+e.length);return r}function Um(t,e){const n=e||{};return(t[t.length-1]===""?[...t,""]:t).join((n.padRight?" ":"")+","+(n.padLeft===!1?"":" ")).trim()}function Wm(t){return t.join(" ").trim()}const Km=/[ \t\n\f\r]/g;function Fi(t){return typeof t=="object"?t.type==="text"?es(t.value):!1:es(t)}function es(t){return t.replace(Km,"")===""}const _e=$a(1),Ma=$a(-1),Xm=[];function $a(t){return e;function e(n,r,i){const o=n?n.children:Xm;let s=(r||0)+t,l=o[s];if(!i)for(;l&&Fi(l);)s+=t,l=o[s];return l}}const Ym={}.hasOwnProperty;function Va(t){return e;function e(n,r,i){return Ym.call(t,n.tagName)&&t[n.tagName](n,r,i)}}const ji=Va({body:Jm,caption:Nr,colgroup:Nr,dd:nf,dt:tf,head:Nr,html:Qm,li:ef,optgroup:rf,option:of,p:Zm,rp:ts,rt:ts,tbody:af,td:ns,tfoot:lf,th:ns,thead:sf,tr:cf});function Nr(t,e,n){const r=_e(n,e,!0);return!r||r.type!=="comment"&&!(r.type==="text"&&Fi(r.value.charAt(0)))}function Qm(t,e,n){const r=_e(n,e);return!r||r.type!=="comment"}function Jm(t,e,n){const r=_e(n,e);return!r||r.type!=="comment"}function Zm(t,e,n){const r=_e(n,e);return r?r.type==="element"&&(r.tagName==="address"||r.tagName==="article"||r.tagName==="aside"||r.tagName==="blockquote"||r.tagName==="details"||r.tagName==="div"||r.tagName==="dl"||r.tagName==="fieldset"||r.tagName==="figcaption"||r.tagName==="figure"||r.tagName==="footer"||r.tagName==="form"||r.tagName==="h1"||r.tagName==="h2"||r.tagName==="h3"||r.tagName==="h4"||r.tagName==="h5"||r.tagName==="h6"||r.tagName==="header"||r.tagName==="hgroup"||r.tagName==="hr"||r.tagName==="main"||r.tagName==="menu"||r.tagName==="nav"||r.tagName==="ol"||r.tagName==="p"||r.tagName==="pre"||r.tagName==="section"||r.tagName==="table"||r.tagName==="ul"):!n||!(n.type==="element"&&(n.tagName==="a"||n.tagName==="audio"||n.tagName==="del"||n.tagName==="ins"||n.tagName==="map"||n.tagName==="noscript"||n.tagName==="video"))}function ef(t,e,n){const r=_e(n,e);return!r||r.type==="element"&&r.tagName==="li"}function tf(t,e,n){const r=_e(n,e);return!!(r&&r.type==="element"&&(r.tagName==="dt"||r.tagName==="dd"))}function nf(t,e,n){const r=_e(n,e);return!r||r.type==="element"&&(r.tagName==="dt"||r.tagName==="dd")}function ts(t,e,n){const r=_e(n,e);return!r||r.type==="element"&&(r.tagName==="rp"||r.tagName==="rt")}function rf(t,e,n){const r=_e(n,e);return!r||r.type==="element"&&r.tagName==="optgroup"}function of(t,e,n){const r=_e(n,e);return!r||r.type==="element"&&(r.tagName==="option"||r.tagName==="optgroup")}function sf(t,e,n){const r=_e(n,e);return!!(r&&r.type==="element"&&(r.tagName==="tbody"||r.tagName==="tfoot"))}function af(t,e,n){const r=_e(n,e);return!r||r.type==="element"&&(r.tagName==="tbody"||r.tagName==="tfoot")}function lf(t,e,n){return!_e(n,e)}function cf(t,e,n){const r=_e(n,e);return!r||r.type==="element"&&r.tagName==="tr"}function ns(t,e,n){const r=_e(n,e);return!r||r.type==="element"&&(r.tagName==="td"||r.tagName==="th")}const uf=Va({body:mf,colgroup:ff,head:pf,html:df,tbody:hf});function df(t){const e=_e(t,-1);return!e||e.type!=="comment"}function pf(t){const e=new Set;for(const r of t.children)if(r.type==="element"&&(r.tagName==="base"||r.tagName==="title")){if(e.has(r.tagName))return!1;e.add(r.tagName)}const n=t.children[0];return!n||n.type==="element"}function mf(t){const e=_e(t,-1,!0);return!e||e.type!=="comment"&&!(e.type==="text"&&Fi(e.value.charAt(0)))&&!(e.type==="element"&&(e.tagName==="meta"||e.tagName==="link"||e.tagName==="script"||e.tagName==="style"||e.tagName==="template"))}function ff(t,e,n){const r=Ma(n,e),i=_e(t,-1,!0);return n&&r&&r.type==="element"&&r.tagName==="colgroup"&&ji(r,n.children.indexOf(r),n)?!1:!!(i&&i.type==="element"&&i.tagName==="col")}function hf(t,e,n){const r=Ma(n,e),i=_e(t,-1);return n&&r&&r.type==="element"&&(r.tagName==="thead"||r.tagName==="tbody")&&ji(r,n.children.indexOf(r),n)?!1:!!(i&&i.type==="element"&&i.tagName==="tr")}const Dn={name:[[`
63
- \f\r &/=>`.split(""),`
64
- \f\r "&'/=>\``.split("")],[`\0
65
- \f\r "&'/<=>`.split(""),`\0
66
- \f\r "&'/<=>\``.split("")]],unquoted:[[`
67
- \f\r &>`.split(""),`\0
68
- \f\r "&'<=>\``.split("")],[`\0
69
- \f\r "&'<=>\``.split(""),`\0
70
- \f\r "&'<=>\``.split("")]],single:[["&'".split(""),"\"&'`".split("")],["\0&'".split(""),"\0\"&'`".split("")]],double:[['"&'.split(""),"\"&'`".split("")],['\0"&'.split(""),"\0\"&'`".split("")]]};function gf(t,e,n,r){const i=r.schema,o=i.space==="svg"?!1:r.settings.omitOptionalTags;let s=i.space==="svg"?r.settings.closeEmptyElements:r.settings.voids.includes(t.tagName.toLowerCase());const l=[];let a;i.space==="html"&&t.tagName==="svg"&&(r.schema=Da);const c=_f(r,t.properties),u=r.all(i.space==="html"&&t.tagName==="template"?t.content:t);return r.schema=i,u&&(s=!1),(c||!o||!uf(t,e,n))&&(l.push("<",t.tagName,c?" "+c:""),s&&(i.space==="svg"||r.settings.closeSelfClosing)&&(a=c.charAt(c.length-1),(!r.settings.tightSelfClosing||a==="/"||a&&a!=='"'&&a!=="'")&&l.push(" "),l.push("/")),l.push(">")),l.push(u),!s&&(!o||!ji(t,e,n))&&l.push("</"+t.tagName+">"),l.join("")}function _f(t,e){const n=[];let r=-1,i;if(e){for(i in e)if(e[i]!==null&&e[i]!==void 0){const o=yf(t,i,e[i]);o&&n.push(o)}}for(;++r<n.length;){const o=t.settings.tightAttributes?n[r].charAt(n[r].length-1):void 0;r!==n.length-1&&o!=='"'&&o!=="'"&&(n[r]+=" ")}return n.join("")}function yf(t,e,n){const r=bm(t.schema,e),i=t.settings.allowParseErrors&&t.schema.space==="html"?0:1,o=t.settings.allowDangerousCharacters?0:1;let s=t.quote,l;if(r.overloadedBoolean&&(n===r.attribute||n==="")?n=!0:(r.boolean||r.overloadedBoolean)&&(typeof n!="string"||n===r.attribute||n==="")&&(n=!!n),n==null||n===!1||typeof n=="number"&&Number.isNaN(n))return"";const a=Vt(r.attribute,Object.assign({},t.settings.characterReferences,{subset:Dn.name[i][o]}));return n===!0||(n=Array.isArray(n)?(r.commaSeparated?Um:Wm)(n,{padLeft:!t.settings.tightCommaSeparatedLists}):String(n),t.settings.collapseEmptyAttributes&&!n)?a:(t.settings.preferUnquoted&&(l=Vt(n,Object.assign({},t.settings.characterReferences,{attribute:!0,subset:Dn.unquoted[i][o]}))),l!==n&&(t.settings.quoteSmart&&Zo(n,s)>Zo(n,t.alternative)&&(s=t.alternative),l=s+Vt(n,Object.assign({},t.settings.characterReferences,{subset:(s==="'"?Dn.single:Dn.double)[i][o],attribute:!0}))+s),a+(l&&"="+l))}const vf=["<","&"];function Ba(t,e,n,r){return n&&n.type==="element"&&(n.tagName==="script"||n.tagName==="style")?t.value:Vt(t.value,Object.assign({},r.settings.characterReferences,{subset:vf}))}function bf(t,e,n,r){return r.settings.allowDangerousHtml?t.value:Ba(t,e,n,r)}function kf(t,e,n,r){return r.all(t)}const wf=Em("type",{invalid:xf,unknown:Ef,handlers:{comment:Hm,doctype:Gm,element:gf,raw:bf,root:kf,text:Ba}});function xf(t){throw new Error("Expected node, not `"+t+"`")}function Ef(t){const e=t;throw new Error("Cannot compile unknown node `"+e.type+"`")}const Tf={},Af={},Sf=[];function Rf(t,e){const n=e||Tf,r=n.quote||'"',i=r==='"'?"'":'"';if(r!=='"'&&r!=="'")throw new Error("Invalid quote `"+r+"`, expected `'` or `\"`");return{one:Lf,all:Cf,settings:{omitOptionalTags:n.omitOptionalTags||!1,allowParseErrors:n.allowParseErrors||!1,allowDangerousCharacters:n.allowDangerousCharacters||!1,quoteSmart:n.quoteSmart||!1,preferUnquoted:n.preferUnquoted||!1,tightAttributes:n.tightAttributes||!1,upperDoctype:n.upperDoctype||!1,tightDoctype:n.tightDoctype||!1,bogusComments:n.bogusComments||!1,tightCommaSeparatedLists:n.tightCommaSeparatedLists||!1,tightSelfClosing:n.tightSelfClosing||!1,collapseEmptyAttributes:n.collapseEmptyAttributes||!1,allowDangerousHtml:n.allowDangerousHtml||!1,voids:n.voids||fm,characterReferences:n.characterReferences||Af,closeSelfClosing:n.closeSelfClosing||!1,closeEmptyElements:n.closeEmptyElements||!1},schema:n.space==="svg"?Da:xm,quote:r,alternative:i}.one(Array.isArray(t)?{type:"root",children:t}:t,void 0,void 0)}function Lf(t,e,n){return wf(t,e,n,this)}function Cf(t){const e=[],n=t&&t.children||Sf;let r=-1;for(;++r<n.length;)e[r]=this.one(n[r],r,t);return e.join("")}function Jn(t,e){const n=typeof t=="string"?{}:{...t.colorReplacements},r=typeof t=="string"?t:t.name;for(const[i,o]of Object.entries(e?.colorReplacements||{}))typeof o=="string"?n[i]=o:i===r&&Object.assign(n,o);return n}function ut(t,e){return t&&(e?.[t?.toLowerCase()]||t)}function Pf(t){return Array.isArray(t)?t:[t]}async function za(t){return Promise.resolve(typeof t=="function"?t():t).then(e=>e.default||e)}function qi(t){return!t||["plaintext","txt","text","plain"].includes(t)}function Fa(t){return t==="ansi"||qi(t)}function Hi(t){return t==="none"}function ja(t){return Hi(t)}function qa(t,e){if(!e)return t;t.properties||={},t.properties.class||=[],typeof t.properties.class=="string"&&(t.properties.class=t.properties.class.split(/\s+/g)),Array.isArray(t.properties.class)||(t.properties.class=[]);const n=Array.isArray(e)?e:e.split(/\s+/g);for(const r of n)r&&!t.properties.class.includes(r)&&t.properties.class.push(r);return t}function pr(t,e=!1){if(t.length===0)return[["",0]];const n=t.split(/(\r?\n)/g);let r=0;const i=[];for(let o=0;o<n.length;o+=2){const s=e?n[o]+(n[o+1]||""):n[o];i.push([s,r]),r+=n[o].length,r+=n[o+1]?.length||0}return i}function Of(t){const e=pr(t,!0).map(([i])=>i);function n(i){if(i===t.length)return{line:e.length-1,character:e[e.length-1].length};let o=i,s=0;for(const l of e){if(o<l.length)break;o-=l.length,s++}return{line:s,character:o}}function r(i,o){let s=0;for(let l=0;l<i;l++)s+=e[l].length;return s+=o,s}return{lines:e,indexToPos:n,posToIndex:r}}function Ha(t,e,n){const r=new Set;for(const o of t.matchAll(/:?lang=["']([^"']+)["']/g)){const s=o[1].toLowerCase().trim();s&&r.add(s)}for(const o of t.matchAll(/(?:```|~~~)([\w-]+)/g)){const s=o[1].toLowerCase().trim();s&&r.add(s)}for(const o of t.matchAll(/\\begin\{([\w-]+)\}/g)){const s=o[1].toLowerCase().trim();s&&r.add(s)}for(const o of t.matchAll(/<script\s+(?:type|lang)=["']([^"']+)["']/gi)){const s=o[1].toLowerCase().trim(),l=s.includes("/")?s.split("/").pop():s;l&&r.add(l)}if(!n)return Array.from(r);const i=n.getBundledLanguages();return Array.from(r).filter(o=>o&&i[o])}const Gi="light-dark()",If=["color","background-color"];function Df(t,e){let n=0;const r=[];for(const i of e)i>n&&r.push({...t,content:t.content.slice(n,i),offset:t.offset+n}),n=i;return n<t.content.length&&r.push({...t,content:t.content.slice(n),offset:t.offset+n}),r}function Nf(t,e){const n=Array.from(e instanceof Set?e:new Set(e)).sort((r,i)=>r-i);return n.length?t.map(r=>r.flatMap(i=>{const o=n.filter(s=>i.offset<s&&s<i.offset+i.content.length).map(s=>s-i.offset).sort((s,l)=>s-l);return o.length?Df(i,o):i})):t}function Mf(t,e,n,r,i="css-vars"){const o={content:t.content,explanation:t.explanation,offset:t.offset},s=e.map(u=>Zn(t.variants[u])),l=new Set(s.flatMap(u=>Object.keys(u))),a={},c=(u,d)=>{const h=d==="color"?"":d==="background-color"?"-bg":`-${d}`;return n+e[u]+(d==="color"?"":h)};return s.forEach((u,d)=>{for(const h of l){const f=u[h]||"inherit";if(d===0&&r&&If.includes(h))if(r===Gi&&s.length>1){const g=e.findIndex(k=>k==="light"),y=e.findIndex(k=>k==="dark");if(g===-1||y===-1)throw new fe('When using `defaultColor: "light-dark()"`, you must provide both `light` and `dark` themes');const x=s[g][h]||"inherit",v=s[y][h]||"inherit";a[h]=`light-dark(${x}, ${v})`,i==="css-vars"&&(a[c(d,h)]=f)}else a[h]=f;else i==="css-vars"&&(a[c(d,h)]=f)}}),o.htmlStyle=a,o}function Zn(t){const e={};if(t.color&&(e.color=t.color),t.bgColor&&(e["background-color"]=t.bgColor),t.fontStyle){t.fontStyle&Ee.Italic&&(e["font-style"]="italic"),t.fontStyle&Ee.Bold&&(e["font-weight"]="bold");const n=[];t.fontStyle&Ee.Underline&&n.push("underline"),t.fontStyle&Ee.Strikethrough&&n.push("line-through"),n.length&&(e["text-decoration"]=n.join(" "))}return e}function hi(t){return typeof t=="string"?t:Object.entries(t).map(([e,n])=>`${e}:${n}`).join(";")}const Ga=new WeakMap;function mr(t,e){Ga.set(t,e)}function hn(t){return Ga.get(t)}class Gt{_stacks={};lang;get themes(){return Object.keys(this._stacks)}get theme(){return this.themes[0]}get _stack(){return this._stacks[this.theme]}static initial(e,n){return new Gt(Object.fromEntries(Pf(n).map(r=>[r,ui])),e)}constructor(...e){if(e.length===2){const[n,r]=e;this.lang=r,this._stacks=n}else{const[n,r,i]=e;this.lang=r,this._stacks={[i]:n}}}getInternalStack(e=this.theme){return this._stacks[e]}getScopes(e=this.theme){return $f(this._stacks[e])}toJSON(){return{lang:this.lang,theme:this.theme,themes:this.themes,scopes:this.getScopes()}}}function $f(t){const e=[],n=new Set;function r(i){if(n.has(i))return;n.add(i);const o=i?.nameScopesList?.scopeName;o&&e.push(o),i.parent&&r(i.parent)}return r(t),e}function Vf(t,e){if(!(t instanceof Gt))throw new fe("Invalid grammar state");return t.getInternalStack(e)}function Bf(){const t=new WeakMap;function e(n){if(!t.has(n.meta)){let r=function(s){if(typeof s=="number"){if(s<0||s>n.source.length)throw new fe(`Invalid decoration offset: ${s}. Code length: ${n.source.length}`);return{...i.indexToPos(s),offset:s}}else{const l=i.lines[s.line];if(l===void 0)throw new fe(`Invalid decoration position ${JSON.stringify(s)}. Lines length: ${i.lines.length}`);let a=s.character;if(a<0&&(a=l.length+a),a<0||a>l.length)throw new fe(`Invalid decoration position ${JSON.stringify(s)}. Line ${s.line} length: ${l.length}`);return{...s,character:a,offset:i.posToIndex(s.line,a)}}};const i=Of(n.source),o=(n.options.decorations||[]).map(s=>({...s,start:r(s.start),end:r(s.end)}));zf(o),t.set(n.meta,{decorations:o,converter:i,source:n.source})}return t.get(n.meta)}return{name:"shiki:decorations",tokens(n){if(!this.options.decorations?.length)return;const i=e(this).decorations.flatMap(s=>[s.start.offset,s.end.offset]);return Nf(n,i)},code(n){if(!this.options.decorations?.length)return;const r=e(this),i=Array.from(n.children).filter(u=>u.type==="element"&&u.tagName==="span");if(i.length!==r.converter.lines.length)throw new fe(`Number of lines in code element (${i.length}) does not match the number of lines in the source (${r.converter.lines.length}). Failed to apply decorations.`);function o(u,d,h,f){const g=i[u];let y="",x=-1,v=-1;if(d===0&&(x=0),h===0&&(v=0),h===Number.POSITIVE_INFINITY&&(v=g.children.length),x===-1||v===-1)for(let b=0;b<g.children.length;b++)y+=Ua(g.children[b]),x===-1&&y.length===d&&(x=b+1),v===-1&&y.length===h&&(v=b+1);if(x===-1)throw new fe(`Failed to find start index for decoration ${JSON.stringify(f.start)}`);if(v===-1)throw new fe(`Failed to find end index for decoration ${JSON.stringify(f.end)}`);const k=g.children.slice(x,v);if(!f.alwaysWrap&&k.length===g.children.length)l(g,f,"line");else if(!f.alwaysWrap&&k.length===1&&k[0].type==="element")l(k[0],f,"token");else{const b={type:"element",tagName:"span",properties:{},children:k};l(b,f,"wrapper"),g.children.splice(x,k.length,b)}}function s(u,d){i[u]=l(i[u],d,"line")}function l(u,d,h){const f=d.properties||{},g=d.transform||(y=>y);return u.tagName=d.tagName||"span",u.properties={...u.properties,...f,class:u.properties.class},d.properties?.class&&qa(u,d.properties.class),u=g(u,h)||u,u}const a=[],c=r.decorations.sort((u,d)=>d.start.offset-u.start.offset||u.end.offset-d.end.offset);for(const u of c){const{start:d,end:h}=u;if(d.line===h.line)o(d.line,d.character,h.character,u);else if(d.line<h.line){o(d.line,d.character,Number.POSITIVE_INFINITY,u);for(let f=d.line+1;f<h.line;f++)a.unshift(()=>s(f,u));o(h.line,0,h.character,u)}}a.forEach(u=>u())}}}function zf(t){for(let e=0;e<t.length;e++){const n=t[e];if(n.start.offset>n.end.offset)throw new fe(`Invalid decoration range: ${JSON.stringify(n.start)} - ${JSON.stringify(n.end)}`);for(let r=e+1;r<t.length;r++){const i=t[r],o=n.start.offset<=i.start.offset&&i.start.offset<n.end.offset,s=n.start.offset<i.end.offset&&i.end.offset<=n.end.offset,l=i.start.offset<=n.start.offset&&n.start.offset<i.end.offset,a=i.start.offset<n.end.offset&&n.end.offset<=i.end.offset;if(o||s||l||a){if(o&&s||l&&a||l&&n.start.offset===n.end.offset||s&&i.start.offset===i.end.offset)continue;throw new fe(`Decorations ${JSON.stringify(n.start)} and ${JSON.stringify(i.start)} intersect.`)}}}}function Ua(t){return t.type==="text"?t.value:t.type==="element"?t.children.map(Ua).join(""):""}const Ff=[Bf()];function er(t){const e=jf(t.transformers||[]);return[...e.pre,...e.normal,...e.post,...Ff]}function jf(t){const e=[],n=[],r=[];for(const i of t)switch(i.enforce){case"pre":e.push(i);break;case"post":n.push(i);break;default:r.push(i)}return{pre:e,post:n,normal:r}}var yt=["black","red","green","yellow","blue","magenta","cyan","white","brightBlack","brightRed","brightGreen","brightYellow","brightBlue","brightMagenta","brightCyan","brightWhite"],Mr={1:"bold",2:"dim",3:"italic",4:"underline",7:"reverse",8:"hidden",9:"strikethrough"};function qf(t,e){const n=t.indexOf("\x1B",e);if(n!==-1&&t[n+1]==="["){const r=t.indexOf("m",n);if(r!==-1)return{sequence:t.substring(n+2,r).split(";"),startPosition:n,position:r+1}}return{position:t.length}}function rs(t){const e=t.shift();if(e==="2"){const n=t.splice(0,3).map(r=>Number.parseInt(r));return n.length!==3||n.some(r=>Number.isNaN(r))?void 0:{type:"rgb",rgb:n}}else if(e==="5"){const n=t.shift();if(n)return{type:"table",index:Number(n)}}}function Hf(t){const e=[];for(;t.length>0;){const n=t.shift();if(!n)continue;const r=Number.parseInt(n);if(!Number.isNaN(r))if(r===0)e.push({type:"resetAll"});else if(r<=9)Mr[r]&&e.push({type:"setDecoration",value:Mr[r]});else if(r<=29){const i=Mr[r-20];i&&(e.push({type:"resetDecoration",value:i}),i==="dim"&&e.push({type:"resetDecoration",value:"bold"}))}else if(r<=37)e.push({type:"setForegroundColor",value:{type:"named",name:yt[r-30]}});else if(r===38){const i=rs(t);i&&e.push({type:"setForegroundColor",value:i})}else if(r===39)e.push({type:"resetForegroundColor"});else if(r<=47)e.push({type:"setBackgroundColor",value:{type:"named",name:yt[r-40]}});else if(r===48){const i=rs(t);i&&e.push({type:"setBackgroundColor",value:i})}else r===49?e.push({type:"resetBackgroundColor"}):r===53?e.push({type:"setDecoration",value:"overline"}):r===55?e.push({type:"resetDecoration",value:"overline"}):r>=90&&r<=97?e.push({type:"setForegroundColor",value:{type:"named",name:yt[r-90+8]}}):r>=100&&r<=107&&e.push({type:"setBackgroundColor",value:{type:"named",name:yt[r-100+8]}})}return e}function Gf(){let t=null,e=null,n=new Set;return{parse(r){const i=[];let o=0;do{const s=qf(r,o),l=s.sequence?r.substring(o,s.startPosition):r.substring(o);if(l.length>0&&i.push({value:l,foreground:t,background:e,decorations:new Set(n)}),s.sequence){const a=Hf(s.sequence);for(const c of a)c.type==="resetAll"?(t=null,e=null,n.clear()):c.type==="resetForegroundColor"?t=null:c.type==="resetBackgroundColor"?e=null:c.type==="resetDecoration"&&n.delete(c.value);for(const c of a)c.type==="setForegroundColor"?t=c.value:c.type==="setBackgroundColor"?e=c.value:c.type==="setDecoration"&&n.add(c.value)}o=s.position}while(o<r.length);return i}}}var Uf={black:"#000000",red:"#bb0000",green:"#00bb00",yellow:"#bbbb00",blue:"#0000bb",magenta:"#ff00ff",cyan:"#00bbbb",white:"#eeeeee",brightBlack:"#555555",brightRed:"#ff5555",brightGreen:"#00ff00",brightYellow:"#ffff55",brightBlue:"#5555ff",brightMagenta:"#ff55ff",brightCyan:"#55ffff",brightWhite:"#ffffff"};function Wf(t=Uf){function e(l){return t[l]}function n(l){return`#${l.map(a=>Math.max(0,Math.min(a,255)).toString(16).padStart(2,"0")).join("")}`}let r;function i(){if(r)return r;r=[];for(let c=0;c<yt.length;c++)r.push(e(yt[c]));let l=[0,95,135,175,215,255];for(let c=0;c<6;c++)for(let u=0;u<6;u++)for(let d=0;d<6;d++)r.push(n([l[c],l[u],l[d]]));let a=8;for(let c=0;c<24;c++,a+=10)r.push(n([a,a,a]));return r}function o(l){return i()[l]}function s(l){switch(l.type){case"named":return e(l.name);case"rgb":return n(l.rgb);case"table":return o(l.index)}}return{value:s}}const Kf={black:"#000000",red:"#cd3131",green:"#0DBC79",yellow:"#E5E510",blue:"#2472C8",magenta:"#BC3FBC",cyan:"#11A8CD",white:"#E5E5E5",brightBlack:"#666666",brightRed:"#F14C4C",brightGreen:"#23D18B",brightYellow:"#F5F543",brightBlue:"#3B8EEA",brightMagenta:"#D670D6",brightCyan:"#29B8DB",brightWhite:"#FFFFFF"};function Xf(t,e,n){const r=Jn(t,n),i=pr(e),o=Object.fromEntries(yt.map(a=>{const c=`terminal.ansi${a[0].toUpperCase()}${a.substring(1)}`,u=t.colors?.[c];return[a,u||Kf[a]]})),s=Wf(o),l=Gf();return i.map(a=>l.parse(a[0]).map(c=>{let u,d;c.decorations.has("reverse")?(u=c.background?s.value(c.background):t.bg,d=c.foreground?s.value(c.foreground):t.fg):(u=c.foreground?s.value(c.foreground):t.fg,d=c.background?s.value(c.background):void 0),u=ut(u,r),d=ut(d,r),c.decorations.has("dim")&&(u=Yf(u));let h=Ee.None;return c.decorations.has("bold")&&(h|=Ee.Bold),c.decorations.has("italic")&&(h|=Ee.Italic),c.decorations.has("underline")&&(h|=Ee.Underline),c.decorations.has("strikethrough")&&(h|=Ee.Strikethrough),{content:c.value,offset:a[1],color:u,bgColor:d,fontStyle:h}}))}function Yf(t){const e=t.match(/#([0-9a-f]{3,8})/i);if(e){const r=e[1];if(r.length===8){const i=Math.round(Number.parseInt(r.slice(6,8),16)/2).toString(16).padStart(2,"0");return`#${r.slice(0,6)}${i}`}else{if(r.length===6)return`#${r}80`;if(r.length===4){const i=r[0],o=r[1],s=r[2],l=r[3],a=Math.round(Number.parseInt(`${l}${l}`,16)/2).toString(16).padStart(2,"0");return`#${i}${i}${o}${o}${s}${s}${a}`}else if(r.length===3){const i=r[0],o=r[1],s=r[2];return`#${i}${i}${o}${o}${s}${s}80`}}}const n=t.match(/var\((--[\w-]+-ansi-[\w-]+)\)/);return n?`var(${n[1]}-dim)`:t}function Ui(t,e,n={}){const{theme:r=t.getLoadedThemes()[0]}=n,i=t.resolveLangAlias(n.lang||"text");if(qi(i)||Hi(r))return pr(e).map(a=>[{content:a[0],offset:a[1]}]);const{theme:o,colorMap:s}=t.setTheme(r);if(i==="ansi")return Xf(o,e,n);const l=t.getLanguage(n.lang||"text");if(n.grammarState){if(n.grammarState.lang!==l.name)throw new fe(`Grammar state language "${n.grammarState.lang}" does not match highlight language "${l.name}"`);if(!n.grammarState.themes.includes(o.name))throw new fe(`Grammar state themes "${n.grammarState.themes}" do not contain highlight theme "${o.name}"`)}return Jf(e,l,o,s,n)}function Qf(...t){if(t.length===2)return hn(t[1]);const[e,n,r={}]=t,{lang:i="text",theme:o=e.getLoadedThemes()[0]}=r;if(qi(i)||Hi(o))throw new fe("Plain language does not have grammar state");if(i==="ansi")throw new fe("ANSI language does not have grammar state");const{theme:s,colorMap:l}=e.setTheme(o),a=e.getLanguage(i);return new Gt(Wi(n,a,s,l,r).stateStack,a.name,s.name)}function Jf(t,e,n,r,i){const o=Wi(t,e,n,r,i),s=new Gt(o.stateStack,e.name,n.name);return mr(o.tokens,s),o.tokens}function Wi(t,e,n,r,i){const o=Jn(n,i),{tokenizeMaxLineLength:s=0,tokenizeTimeLimit:l=500}=i,a=pr(t);let c=i.grammarState?Vf(i.grammarState,n.name)??ui:i.grammarContextCode!=null?Wi(i.grammarContextCode,e,n,r,{...i,grammarState:void 0,grammarContextCode:void 0}).stateStack:ui,u=[];const d=[];for(let h=0,f=a.length;h<f;h++){const[g,y]=a[h];if(g===""){u=[],d.push([]);continue}if(s>0&&g.length>=s){u=[],d.push([{content:g,offset:y,color:"",fontStyle:0}]);continue}let x,v,k;i.includeExplanation&&(x=e.tokenizeLine(g,c,l),v=x.tokens,k=0);const b=e.tokenizeLine2(g,c,l),E=b.tokens.length/2;for(let P=0;P<E;P++){const V=b.tokens[2*P],q=P+1<E?b.tokens[2*P+2]:g.length;if(V===q)continue;const J=b.tokens[2*P+1],B=ut(r[zt.getForeground(J)],o),S=zt.getFontStyle(J),O={content:g.substring(V,q),offset:y+V,color:B,fontStyle:S};if(i.includeExplanation){const N=[];if(i.includeExplanation!=="scopeName")for(const I of n.settings){let z;switch(typeof I.scope){case"string":z=I.scope.split(/,/).map(W=>W.trim());break;case"object":z=I.scope;break;default:continue}N.push({settings:I,selectors:z.map(W=>W.split(/ /))})}O.explanation=[];let D=0;for(;V+D<q;){const I=v[k],z=g.substring(I.startIndex,I.endIndex);D+=z.length,O.explanation.push({content:z,scopes:i.includeExplanation==="scopeName"?Zf(I.scopes):eh(N,I.scopes)}),k+=1}}u.push(O)}d.push(u),u=[],c=b.ruleStack}return{tokens:d,stateStack:c}}function Zf(t){return t.map(e=>({scopeName:e}))}function eh(t,e){const n=[];for(let r=0,i=e.length;r<i;r++){const o=e[r];n[r]={scopeName:o,themeMatches:nh(t,o,e.slice(0,r))}}return n}function is(t,e){return t===e||e.substring(0,t.length)===t&&e[t.length]==="."}function th(t,e,n){if(!is(t[t.length-1],e))return!1;let r=t.length-2,i=n.length-1;for(;r>=0&&i>=0;)is(t[r],n[i])&&(r-=1),i-=1;return r===-1}function nh(t,e,n){const r=[];for(const{selectors:i,settings:o}of t)for(const s of i)if(th(s,e,n)){r.push(o);break}return r}function Wa(t,e,n){const r=Object.entries(n.themes).filter(a=>a[1]).map(a=>({color:a[0],theme:a[1]})),i=r.map(a=>{const c=Ui(t,e,{...n,theme:a.theme}),u=hn(c),d=typeof a.theme=="string"?a.theme:a.theme.name;return{tokens:c,state:u,theme:d}}),o=rh(...i.map(a=>a.tokens)),s=o[0].map((a,c)=>a.map((u,d)=>{const h={content:u.content,variants:{},offset:u.offset};return"includeExplanation"in n&&n.includeExplanation&&(h.explanation=u.explanation),o.forEach((f,g)=>{const{content:y,explanation:x,offset:v,...k}=f[c][d];h.variants[r[g].color]=k}),h})),l=i[0].state?new Gt(Object.fromEntries(i.map(a=>[a.theme,a.state?.getInternalStack(a.theme)])),i[0].state.lang):void 0;return l&&mr(s,l),s}function rh(...t){const e=t.map(()=>[]),n=t.length;for(let r=0;r<t[0].length;r++){const i=t.map(a=>a[r]),o=e.map(()=>[]);e.forEach((a,c)=>a.push(o[c]));const s=i.map(()=>0),l=i.map(a=>a[0]);for(;l.every(a=>a);){const a=Math.min(...l.map(c=>c.content.length));for(let c=0;c<n;c++){const u=l[c];u.content.length===a?(o[c].push(u),s[c]+=1,l[c]=i[c][s[c]]):(o[c].push({...u,content:u.content.slice(0,a)}),l[c]={...u,content:u.content.slice(a),offset:u.offset+a})}}}return e}function tr(t,e,n){let r,i,o,s,l,a;if("themes"in n){const{defaultColor:c="light",cssVariablePrefix:u="--shiki-",colorsRendering:d="css-vars"}=n,h=Object.entries(n.themes).filter(v=>v[1]).map(v=>({color:v[0],theme:v[1]})).sort((v,k)=>v.color===c?-1:k.color===c?1:0);if(h.length===0)throw new fe("`themes` option must not be empty");const f=Wa(t,e,n);if(a=hn(f),c&&Gi!==c&&!h.find(v=>v.color===c))throw new fe(`\`themes\` option must contain the defaultColor key \`${c}\``);const g=h.map(v=>t.getTheme(v.theme)),y=h.map(v=>v.color);o=f.map(v=>v.map(k=>Mf(k,y,u,c,d))),a&&mr(o,a);const x=h.map(v=>Jn(v.theme,n));i=os(h,g,x,u,c,"fg",d),r=os(h,g,x,u,c,"bg",d),s=`shiki-themes ${g.map(v=>v.name).join(" ")}`,l=c?void 0:[i,r].join(";")}else if("theme"in n){const c=Jn(n.theme,n);o=Ui(t,e,n);const u=t.getTheme(n.theme);r=ut(u.bg,c),i=ut(u.fg,c),s=u.name,a=hn(o)}else throw new fe("Invalid options, either `theme` or `themes` must be provided");return{tokens:o,fg:i,bg:r,themeName:s,rootStyle:l,grammarState:a}}function os(t,e,n,r,i,o,s){return t.map((l,a)=>{const c=ut(e[a][o],n[a])||"inherit",u=`${r+l.color}${o==="bg"?"-bg":""}:${c}`;if(a===0&&i){if(i===Gi&&t.length>1){const d=t.findIndex(y=>y.color==="light"),h=t.findIndex(y=>y.color==="dark");if(d===-1||h===-1)throw new fe('When using `defaultColor: "light-dark()"`, you must provide both `light` and `dark` themes');const f=ut(e[d][o],n[d])||"inherit",g=ut(e[h][o],n[h])||"inherit";return`light-dark(${f}, ${g});${u}`}return c}return s==="css-vars"?u:null}).filter(l=>!!l).join(";")}function nr(t,e,n,r={meta:{},options:n,codeToHast:(i,o)=>nr(t,i,o),codeToTokens:(i,o)=>tr(t,i,o)}){let i=e;for(const g of er(n))i=g.preprocess?.call(r,i,n)||i;let{tokens:o,fg:s,bg:l,themeName:a,rootStyle:c,grammarState:u}=tr(t,i,n);const{mergeWhitespaces:d=!0,mergeSameStyleTokens:h=!1}=n;d===!0?o=oh(o):d==="never"&&(o=sh(o)),h&&(o=ah(o));const f={...r,get source(){return i}};for(const g of er(n))o=g.tokens?.call(f,o)||o;return ih(o,{...n,fg:s,bg:l,themeName:a,rootStyle:n.rootStyle===!1?!1:n.rootStyle??c},f,u)}function ih(t,e,n,r=hn(t)){const i=er(e),o=[],s={type:"root",children:[]},{structure:l="classic",tabindex:a="0"}=e,c={class:`shiki ${e.themeName||""}`};e.rootStyle!==!1&&(e.rootStyle!=null?c.style=e.rootStyle:c.style=`background-color:${e.bg};color:${e.fg}`),a!==!1&&a!=null&&(c.tabindex=a.toString());for(const[y,x]of Object.entries(e.meta||{}))y.startsWith("_")||(c[y]=x);let u={type:"element",tagName:"pre",properties:c,children:[],data:e.data},d={type:"element",tagName:"code",properties:{},children:o};const h=[],f={...n,structure:l,addClassToHast:qa,get source(){return n.source},get tokens(){return t},get options(){return e},get root(){return s},get pre(){return u},get code(){return d},get lines(){return h}};if(t.forEach((y,x)=>{x&&(l==="inline"?s.children.push({type:"element",tagName:"br",properties:{},children:[]}):l==="classic"&&o.push({type:"text",value:`
71
- `}));let v={type:"element",tagName:"span",properties:{class:"line"},children:[]},k=0;for(const b of y){let E={type:"element",tagName:"span",properties:{...b.htmlAttrs},children:[{type:"text",value:b.content}]};const P=hi(b.htmlStyle||Zn(b));P&&(E.properties.style=P);for(const V of i)E=V?.span?.call(f,E,x+1,k,v,b)||E;l==="inline"?s.children.push(E):l==="classic"&&v.children.push(E),k+=b.content.length}if(l==="classic"){for(const b of i)v=b?.line?.call(f,v,x+1)||v;h.push(v),o.push(v)}else l==="inline"&&h.push(v)}),l==="classic"){for(const y of i)d=y?.code?.call(f,d)||d;u.children.push(d);for(const y of i)u=y?.pre?.call(f,u)||u;s.children.push(u)}else if(l==="inline"){const y=[];let x={type:"element",tagName:"span",properties:{class:"line"},children:[]};for(const b of s.children)b.type==="element"&&b.tagName==="br"?(y.push(x),x={type:"element",tagName:"span",properties:{class:"line"},children:[]}):(b.type==="element"||b.type==="text")&&x.children.push(b);y.push(x);let k={type:"element",tagName:"code",properties:{},children:y};for(const b of i)k=b?.code?.call(f,k)||k;s.children=[];for(let b=0;b<k.children.length;b++){b>0&&s.children.push({type:"element",tagName:"br",properties:{},children:[]});const E=k.children[b];E.type==="element"&&s.children.push(...E.children)}}let g=s;for(const y of i)g=y?.root?.call(f,g)||g;return r&&mr(g,r),g}function oh(t){return t.map(e=>{const n=[];let r="",i;return e.forEach((o,s)=>{const a=!(o.fontStyle&&(o.fontStyle&Ee.Underline||o.fontStyle&Ee.Strikethrough));a&&o.content.match(/^\s+$/)&&e[s+1]?(i===void 0&&(i=o.offset),r+=o.content):r?(a?n.push({...o,offset:i,content:r+o.content}):n.push({content:r,offset:i},o),i=void 0,r=""):n.push(o)}),n})}function sh(t){return t.map(e=>e.flatMap(n=>{if(n.content.match(/^\s+$/))return n;const r=n.content.match(/^(\s*)(.*?)(\s*)$/);if(!r)return n;const[,i,o,s]=r;if(!i&&!s)return n;const l=[{...n,offset:n.offset+i.length,content:o}];return i&&l.unshift({content:i,offset:n.offset}),s&&l.push({content:s,offset:n.offset+i.length+o.length}),l}))}function ah(t){return t.map(e=>{const n=[];for(const r of e){if(n.length===0){n.push({...r});continue}const i=n[n.length-1],o=hi(i.htmlStyle||Zn(i)),s=hi(r.htmlStyle||Zn(r)),l=i.fontStyle&&(i.fontStyle&Ee.Underline||i.fontStyle&Ee.Strikethrough),a=r.fontStyle&&(r.fontStyle&Ee.Underline||r.fontStyle&Ee.Strikethrough);!l&&!a&&o===s?i.content+=r.content:n.push({...r})}return n})}const lh=Rf;function ch(t,e,n){const r={meta:{},options:n,codeToHast:(o,s)=>nr(t,o,s),codeToTokens:(o,s)=>tr(t,o,s)};let i=lh(nr(t,e,n,r));for(const o of er(n))i=o.postprocess?.call(r,i,n)||i;return i}const ss={light:"#333333",dark:"#bbbbbb"},as={light:"#fffffe",dark:"#1e1e1e"},ls="__shiki_resolved";function Ki(t){if(t?.[ls])return t;const e={...t};e.tokenColors&&!e.settings&&(e.settings=e.tokenColors,delete e.tokenColors),e.type||="dark",e.colorReplacements={...e.colorReplacements},e.settings||=[];let{bg:n,fg:r}=e;if(!n||!r){const l=e.settings?e.settings.find(a=>!a.name&&!a.scope):void 0;l?.settings?.foreground&&(r=l.settings.foreground),l?.settings?.background&&(n=l.settings.background),!r&&e?.colors?.["editor.foreground"]&&(r=e.colors["editor.foreground"]),!n&&e?.colors?.["editor.background"]&&(n=e.colors["editor.background"]),r||(r=e.type==="light"?ss.light:ss.dark),n||(n=e.type==="light"?as.light:as.dark),e.fg=r,e.bg=n}e.settings[0]&&e.settings[0].settings&&!e.settings[0].scope||e.settings.unshift({settings:{foreground:e.fg,background:e.bg}});let i=0;const o=new Map;function s(l){if(o.has(l))return o.get(l);i+=1;const a=`#${i.toString(16).padStart(8,"0").toLowerCase()}`;return e.colorReplacements?.[`#${a}`]?s(l):(o.set(l,a),a)}e.settings=e.settings.map(l=>{const a=l.settings?.foreground&&!l.settings.foreground.startsWith("#"),c=l.settings?.background&&!l.settings.background.startsWith("#");if(!a&&!c)return l;const u={...l,settings:{...l.settings}};if(a){const d=s(l.settings.foreground);e.colorReplacements[d]=l.settings.foreground,u.settings.foreground=d}if(c){const d=s(l.settings.background);e.colorReplacements[d]=l.settings.background,u.settings.background=d}return u});for(const l of Object.keys(e.colors||{}))if((l==="editor.foreground"||l==="editor.background"||l.startsWith("terminal.ansi"))&&!e.colors[l]?.startsWith("#")){const a=s(e.colors[l]);e.colorReplacements[a]=e.colors[l],e.colors[l]=a}return Object.defineProperty(e,ls,{enumerable:!1,writable:!1,value:!0}),e}async function Ka(t){return Array.from(new Set((await Promise.all(t.filter(e=>!Fa(e)).map(async e=>await za(e).then(n=>Array.isArray(n)?n:[n])))).flat()))}async function Xa(t){return(await Promise.all(t.map(async n=>ja(n)?null:Ki(await za(n))))).filter(n=>!!n)}let uh=3;function dh(t,e=3){e>uh||console.trace(`[SHIKI DEPRECATE]: ${t}`)}let Dt=class extends Error{constructor(e){super(e),this.name="ShikiError"}};function Ya(t,e){if(!e)return t;if(e[t]){const n=new Set([t]);for(;e[t];){if(t=e[t],n.has(t))throw new Dt(`Circular alias \`${Array.from(n).join(" -> ")} -> ${t}\``);n.add(t)}}return t}class ph extends mm{constructor(e,n,r,i={}){super(e),this._resolver=e,this._themes=n,this._langs=r,this._alias=i,this._themes.map(o=>this.loadTheme(o)),this.loadLanguages(this._langs)}_resolvedThemes=new Map;_resolvedGrammars=new Map;_langMap=new Map;_langGraph=new Map;_textmateThemeCache=new WeakMap;_loadedThemesCache=null;_loadedLanguagesCache=null;getTheme(e){return typeof e=="string"?this._resolvedThemes.get(e):this.loadTheme(e)}loadTheme(e){const n=Ki(e);return n.name&&(this._resolvedThemes.set(n.name,n),this._loadedThemesCache=null),n}getLoadedThemes(){return this._loadedThemesCache||(this._loadedThemesCache=[...this._resolvedThemes.keys()]),this._loadedThemesCache}setTheme(e){let n=this._textmateThemeCache.get(e);n||(n=Wn.createFromRawTheme(e),this._textmateThemeCache.set(e,n)),this._syncRegistry.setTheme(n)}getGrammar(e){return e=Ya(e,this._alias),this._resolvedGrammars.get(e)}loadLanguage(e){if(this.getGrammar(e.name))return;const n=new Set([...this._langMap.values()].filter(o=>o.embeddedLangsLazy?.includes(e.name)));this._resolver.addLanguage(e);const r={balancedBracketSelectors:e.balancedBracketSelectors||["*"],unbalancedBracketSelectors:e.unbalancedBracketSelectors||[]};this._syncRegistry._rawGrammars.set(e.scopeName,e);const i=this.loadGrammarWithConfiguration(e.scopeName,1,r);if(i.name=e.name,this._resolvedGrammars.set(e.name,i),e.aliases&&e.aliases.forEach(o=>{this._alias[o]=e.name}),this._loadedLanguagesCache=null,n.size)for(const o of n)this._resolvedGrammars.delete(o.name),this._loadedLanguagesCache=null,this._syncRegistry?._injectionGrammars?.delete(o.scopeName),this._syncRegistry?._grammars?.delete(o.scopeName),this.loadLanguage(this._langMap.get(o.name))}dispose(){super.dispose(),this._resolvedThemes.clear(),this._resolvedGrammars.clear(),this._langMap.clear(),this._langGraph.clear(),this._loadedThemesCache=null}loadLanguages(e){for(const i of e)this.resolveEmbeddedLanguages(i);const n=Array.from(this._langGraph.entries()),r=n.filter(([i,o])=>!o);if(r.length){const i=n.filter(([o,s])=>s?(s.embeddedLanguages||s.embeddedLangs)?.some(a=>r.map(([c])=>c).includes(a)):!1).filter(o=>!r.includes(o));throw new Dt(`Missing languages ${r.map(([o])=>`\`${o}\``).join(", ")}, required by ${i.map(([o])=>`\`${o}\``).join(", ")}`)}for(const[i,o]of n)this._resolver.addLanguage(o);for(const[i,o]of n)this.loadLanguage(o)}getLoadedLanguages(){return this._loadedLanguagesCache||(this._loadedLanguagesCache=[...new Set([...this._resolvedGrammars.keys(),...Object.keys(this._alias)])]),this._loadedLanguagesCache}resolveEmbeddedLanguages(e){this._langMap.set(e.name,e),this._langGraph.set(e.name,e);const n=e.embeddedLanguages??e.embeddedLangs;if(n)for(const r of n)this._langGraph.set(r,this._langMap.get(r))}}class mh{_langs=new Map;_scopeToLang=new Map;_injections=new Map;_onigLib;constructor(e,n){this._onigLib={createOnigScanner:r=>e.createScanner(r),createOnigString:r=>e.createString(r)},n.forEach(r=>this.addLanguage(r))}get onigLib(){return this._onigLib}getLangRegistration(e){return this._langs.get(e)}loadGrammar(e){return this._scopeToLang.get(e)}addLanguage(e){this._langs.set(e.name,e),e.aliases&&e.aliases.forEach(n=>{this._langs.set(n,e)}),this._scopeToLang.set(e.scopeName,e),e.injectTo&&e.injectTo.forEach(n=>{this._injections.get(n)||this._injections.set(n,[]),this._injections.get(n).push(e.scopeName)})}getInjections(e){const n=e.split(".");let r=[];for(let i=1;i<=n.length;i++){const o=n.slice(0,i).join(".");r=[...r,...this._injections.get(o)||[]]}return r}}let Qt=0;function fh(t){Qt+=1,t.warnings!==!1&&Qt>=10&&Qt%10===0&&console.warn(`[Shiki] ${Qt} instances have been created. Shiki is supposed to be used as a singleton, consider refactoring your code to cache your highlighter instance; Or call \`highlighter.dispose()\` to release unused instances.`);let e=!1;if(!t.engine)throw new Dt("`engine` option is required for synchronous mode");const n=(t.langs||[]).flat(1),r=(t.themes||[]).flat(1).map(Ki),i=new mh(t.engine,n),o=new ph(i,r,n,t.langAlias);let s;function l(b){return Ya(b,t.langAlias)}function a(b){v();const E=o.getGrammar(typeof b=="string"?b:b.name);if(!E)throw new Dt(`Language \`${b}\` not found, you may need to load it first`);return E}function c(b){if(b==="none")return{bg:"",fg:"",name:"none",settings:[],type:"dark"};v();const E=o.getTheme(b);if(!E)throw new Dt(`Theme \`${b}\` not found, you may need to load it first`);return E}function u(b){v();const E=c(b);s!==b&&(o.setTheme(E),s=b);const P=o.getColorMap();return{theme:E,colorMap:P}}function d(){return v(),o.getLoadedThemes()}function h(){return v(),o.getLoadedLanguages()}function f(...b){v(),o.loadLanguages(b.flat(1))}async function g(...b){return f(await Ka(b))}function y(...b){v();for(const E of b.flat(1))o.loadTheme(E)}async function x(...b){return v(),y(await Xa(b))}function v(){if(e)throw new Dt("Shiki instance has been disposed")}function k(){e||(e=!0,o.dispose(),Qt-=1)}return{setTheme:u,getTheme:c,getLanguage:a,getLoadedThemes:d,getLoadedLanguages:h,resolveLangAlias:l,loadLanguage:g,loadLanguageSync:f,loadTheme:x,loadThemeSync:y,dispose:k,[Symbol.dispose]:k}}async function hh(t){t.engine||dh("`engine` option is required. Use `createOnigurumaEngine` or `createJavaScriptRegexEngine` to create an engine.");const[e,n,r]=await Promise.all([Xa(t.themes||[]),Ka(t.langs||[]),t.engine]);return fh({...t,themes:e,langs:n,engine:r})}async function gh(t){const e=await hh(t);return{getLastGrammarState:(...n)=>Qf(e,...n),codeToTokensBase:(n,r)=>Ui(e,n,r),codeToTokensWithThemes:(n,r)=>Wa(e,n,r),codeToTokens:(n,r)=>tr(e,n,r),codeToHast:(n,r)=>nr(e,n,r),codeToHtml:(n,r)=>ch(e,n,r),getBundledLanguages:()=>({}),getBundledThemes:()=>({}),...e,getInternalContext:()=>e}}function Qa(t){const e=t.langs,n=t.themes,r=t.engine;async function i(o){function s(d){if(typeof d=="string"){if(d=o.langAlias?.[d]||d,Fa(d))return[];const h=e[d];if(!h)throw new fe(`Language \`${d}\` is not included in this bundle. You may want to load it from external source.`);return h}return d}function l(d){if(ja(d))return"none";if(typeof d=="string"){const h=n[d];if(!h)throw new fe(`Theme \`${d}\` is not included in this bundle. You may want to load it from external source.`);return h}return d}const a=(o.themes??[]).map(d=>l(d)),c=(o.langs??[]).map(d=>s(d)),u=await gh({engine:o.engine??r(),...o,themes:a,langs:c});return{...u,loadLanguage(...d){return u.loadLanguage(...d.map(s))},loadTheme(...d){return u.loadTheme(...d.map(l))},getBundledLanguages(){return e},getBundledThemes(){return n}}}return i}function _h(t){let e;async function n(r={}){if(e){const i=await e;return await Promise.all([i.loadTheme(...r.themes||[]),i.loadLanguage(...r.langs||[])]),i}else{e=t({...r,themes:[],langs:[]});const i=await e;return await Promise.all([i.loadTheme(...r.themes||[]),i.loadLanguage(...r.langs||[])]),i}}return n}function Ja(t,e){const n=_h(t);async function r(i,o){const s=await n({langs:[o.lang],themes:"theme"in o?[o.theme]:Object.values(o.themes)}),l=await e?.guessEmbeddedLanguages?.(i,o.lang,s);return l&&await s.loadLanguage(...l),s}return{getSingletonHighlighter(i){return n(i)},async codeToHtml(i,o){return(await r(i,o)).codeToHtml(i,o)},async codeToHast(i,o){return(await r(i,o)).codeToHast(i,o)},async codeToTokens(i,o){return(await r(i,o)).codeToTokens(i,o)},async codeToTokensBase(i,o){return(await r(i,o)).codeToTokensBase(i,o)},async codeToTokensWithThemes(i,o){return(await r(i,o)).codeToTokensWithThemes(i,o)},async getLastGrammarState(i,o){return(await n({langs:[o.lang],themes:[o.theme]})).getLastGrammarState(i,o)}}}const Za=[{id:"abap",name:"ABAP",import:(()=>p(()=>import("./BdImnpbu.js"),[],import.meta.url))},{id:"actionscript-3",name:"ActionScript",import:(()=>p(()=>import("./CoDkCxhg.js"),[],import.meta.url))},{id:"ada",name:"Ada",import:(()=>p(()=>import("./bCR0ucgS.js"),[],import.meta.url))},{id:"angular-html",name:"Angular HTML",import:(()=>p(()=>import("./DxNHbxmM.js").then(t=>t.f),__vite__mapDeps([0,1,2,3]),import.meta.url))},{id:"angular-ts",name:"Angular TypeScript",import:(()=>p(()=>import("./Cl0AqbOI.js"),__vite__mapDeps([4,0,1,2,3,5]),import.meta.url))},{id:"apache",name:"Apache Conf",import:(()=>p(()=>import("./Pmp26Uib.js"),[],import.meta.url))},{id:"apex",name:"Apex",import:(()=>p(()=>import("./D8_7TLub.js"),[],import.meta.url))},{id:"apl",name:"APL",import:(()=>p(()=>import("./Cn7AkR1O.js"),__vite__mapDeps([6,1,2,3,7,8,9]),import.meta.url))},{id:"applescript",name:"AppleScript",import:(()=>p(()=>import("./Co6uUVPk.js"),[],import.meta.url))},{id:"ara",name:"Ara",import:(()=>p(()=>import("./BRHolxvo.js"),[],import.meta.url))},{id:"asciidoc",name:"AsciiDoc",aliases:["adoc"],import:(()=>p(()=>import("./Dv7Oe6Be.js"),[],import.meta.url))},{id:"asm",name:"Assembly",import:(()=>p(()=>import("./D_Q5rh1f.js"),[],import.meta.url))},{id:"astro",name:"Astro",import:(()=>p(()=>import("./DxSwrfjg.js"),__vite__mapDeps([10,9,2,11,3,12,13]),import.meta.url))},{id:"awk",name:"AWK",import:(()=>p(()=>import("./DMzUqQB5.js"),[],import.meta.url))},{id:"ballerina",name:"Ballerina",import:(()=>p(()=>import("./BFfxhgS-.js"),[],import.meta.url))},{id:"bat",name:"Batch File",aliases:["batch"],import:(()=>p(()=>import("./BkioyH1T.js"),[],import.meta.url))},{id:"beancount",name:"Beancount",import:(()=>p(()=>import("./k_qm7-4y.js"),[],import.meta.url))},{id:"berry",name:"Berry",aliases:["be"],import:(()=>p(()=>import("./uYugtg8r.js"),[],import.meta.url))},{id:"bibtex",name:"BibTeX",import:(()=>p(()=>import("./CHM0blh-.js"),[],import.meta.url))},{id:"bicep",name:"Bicep",import:(()=>p(()=>import("./Bmn6On1c.js"),[],import.meta.url))},{id:"blade",name:"Blade",import:(()=>p(()=>import("./5X7smno1.js"),__vite__mapDeps([14,15,1,2,3,7,8,16,9]),import.meta.url))},{id:"bsl",name:"1C (Enterprise)",aliases:["1c"],import:(()=>p(()=>import("./CquLrc37.js"),__vite__mapDeps([17,18]),import.meta.url))},{id:"c",name:"C",import:(()=>p(()=>import("./BIGW1oBm.js"),[],import.meta.url))},{id:"c3",name:"C3",import:(()=>p(()=>import("./VCDPK7BO.js"),[],import.meta.url))},{id:"cadence",name:"Cadence",aliases:["cdc"],import:(()=>p(()=>import("./Bv_4Rxtq.js"),[],import.meta.url))},{id:"cairo",name:"Cairo",import:(()=>p(()=>import("./CO1LY3CK.js"),__vite__mapDeps([19,20]),import.meta.url))},{id:"clarity",name:"Clarity",import:(()=>p(()=>import("./D53aC0YG.js"),[],import.meta.url))},{id:"clojure",name:"Clojure",aliases:["clj"],import:(()=>p(()=>import("./P80f7IUj.js"),[],import.meta.url))},{id:"cmake",name:"CMake",import:(()=>p(()=>import("./D1j8_8rp.js"),[],import.meta.url))},{id:"cobol",name:"COBOL",import:(()=>p(()=>import("./BYV0-3_D.js"),__vite__mapDeps([21,1,2,3,8]),import.meta.url))},{id:"codeowners",name:"CODEOWNERS",import:(()=>p(()=>import("./Bp6g37R7.js"),[],import.meta.url))},{id:"codeql",name:"CodeQL",aliases:["ql"],import:(()=>p(()=>import("./DsOJ9woJ.js"),[],import.meta.url))},{id:"coffee",name:"CoffeeScript",aliases:["coffeescript"],import:(()=>p(()=>import("./CxbxFI8M.js"),__vite__mapDeps([22,2]),import.meta.url))},{id:"common-lisp",name:"Common Lisp",aliases:["lisp"],import:(()=>p(()=>import("./Cg-RD9OK.js"),[],import.meta.url))},{id:"coq",name:"Coq",import:(()=>p(()=>import("./DkFqJrB1.js"),[],import.meta.url))},{id:"cpp",name:"C++",aliases:["c++"],import:(()=>p(()=>import("./Bp3cYrEr.js"),__vite__mapDeps([23,24,25,26,16]),import.meta.url))},{id:"crystal",name:"Crystal",import:(()=>p(()=>import("./fKv21gyL.js"),__vite__mapDeps([27,1,2,3,16,26,28]),import.meta.url))},{id:"csharp",name:"C#",aliases:["c#","cs"],import:(()=>p(()=>import("./COcwbKMJ.js"),[],import.meta.url))},{id:"css",name:"CSS",import:(()=>p(()=>import("./DPfMkruS.js"),[],import.meta.url))},{id:"csv",name:"CSV",import:(()=>p(()=>import("./fuZLfV_i.js"),[],import.meta.url))},{id:"cue",name:"CUE",import:(()=>p(()=>import("./D82EKSYY.js"),[],import.meta.url))},{id:"cypher",name:"Cypher",aliases:["cql"],import:(()=>p(()=>import("./COkxafJQ.js"),[],import.meta.url))},{id:"d",name:"D",import:(()=>p(()=>import("./85-TOEBH.js"),[],import.meta.url))},{id:"dart",name:"Dart",import:(()=>p(()=>import("./CF10PKvl.js"),[],import.meta.url))},{id:"dax",name:"DAX",import:(()=>p(()=>import("./CEL-wOlO.js"),[],import.meta.url))},{id:"desktop",name:"Desktop",import:(()=>p(()=>import("./BmXAJ9_W.js"),[],import.meta.url))},{id:"diff",name:"Diff",import:(()=>p(()=>import("./D97Zzqfu.js"),[],import.meta.url))},{id:"docker",name:"Dockerfile",aliases:["dockerfile"],import:(()=>p(()=>import("./BcOcwvcX.js"),[],import.meta.url))},{id:"dotenv",name:"dotEnv",import:(()=>p(()=>import("./Da5cRb03.js"),[],import.meta.url))},{id:"dream-maker",name:"Dream Maker",import:(()=>p(()=>import("./BtqSS_iP.js"),[],import.meta.url))},{id:"edge",name:"Edge",import:(()=>p(()=>import("./DZu-aV2c.js"),__vite__mapDeps([29,11,1,2,3,15]),import.meta.url))},{id:"elixir",name:"Elixir",import:(()=>p(()=>import("./CpOuai2O.js"),__vite__mapDeps([30,1,2,3]),import.meta.url))},{id:"elm",name:"Elm",import:(()=>p(()=>import("./CeZK1NFH.js"),__vite__mapDeps([31,25,26]),import.meta.url))},{id:"emacs-lisp",name:"Emacs Lisp",aliases:["elisp"],import:(()=>p(()=>import("./C9XAeP06.js"),[],import.meta.url))},{id:"erb",name:"ERB",import:(()=>p(()=>import("./CGscLIrv.js"),__vite__mapDeps([32,1,2,3,33,34,7,8,16,35,11,36,13,23,24,25,26,28,37,38]),import.meta.url))},{id:"erlang",name:"Erlang",aliases:["erl"],import:(()=>p(()=>import("./CuPHTKiy.js"),__vite__mapDeps([39,40]),import.meta.url))},{id:"fennel",name:"Fennel",import:(()=>p(()=>import("./BYunw83y.js"),[],import.meta.url))},{id:"fish",name:"Fish",import:(()=>p(()=>import("./BvzEVeQv.js"),[],import.meta.url))},{id:"fluent",name:"Fluent",aliases:["ftl"],import:(()=>p(()=>import("./C4IJs8-o.js"),[],import.meta.url))},{id:"fortran-fixed-form",name:"Fortran (Fixed Form)",aliases:["f","for","f77"],import:(()=>p(()=>import("./B7c-h3xW.js"),__vite__mapDeps([41,42]),import.meta.url))},{id:"fortran-free-form",name:"Fortran (Free Form)",aliases:["f90","f95","f03","f08","f18"],import:(()=>p(()=>import("./BxgE0vQu.js"),[],import.meta.url))},{id:"fsharp",name:"F#",aliases:["f#","fs"],import:(()=>p(()=>import("./BTifaqeh.js"),__vite__mapDeps([43,40]),import.meta.url))},{id:"gdresource",name:"GDResource",aliases:["tscn","tres"],import:(()=>p(()=>import("./CenWIFCC.js"),__vite__mapDeps([44,45,46]),import.meta.url))},{id:"gdscript",name:"GDScript",aliases:["gd"],import:(()=>p(()=>import("./C5YyOfLZ.js"),[],import.meta.url))},{id:"gdshader",name:"GDShader",import:(()=>p(()=>import("./DkwncUOv.js"),[],import.meta.url))},{id:"genie",name:"Genie",import:(()=>p(()=>import("./D0YGMca9.js"),[],import.meta.url))},{id:"gherkin",name:"Gherkin",import:(()=>p(()=>import("./DyxjwDmM.js"),[],import.meta.url))},{id:"git-commit",name:"Git Commit Message",import:(()=>p(()=>import("./CxGSJlkm.js"),__vite__mapDeps([47,48]),import.meta.url))},{id:"git-rebase",name:"Git Rebase Message",import:(()=>p(()=>import("./CSXwinHm.js"),__vite__mapDeps([49,28]),import.meta.url))},{id:"gleam",name:"Gleam",import:(()=>p(()=>import("./BspZqrRM.js"),[],import.meta.url))},{id:"glimmer-js",name:"Glimmer JS",aliases:["gjs"],import:(()=>p(()=>import("./YqXBG_HV.js"),__vite__mapDeps([50,2,11,3,1]),import.meta.url))},{id:"glimmer-ts",name:"Glimmer TS",aliases:["gts"],import:(()=>p(()=>import("./BR5kRUq4.js"),__vite__mapDeps([51,11,3,2,1]),import.meta.url))},{id:"glsl",name:"GLSL",import:(()=>p(()=>import("./DZxFcAj9.js"),__vite__mapDeps([25,26]),import.meta.url))},{id:"gn",name:"GN",import:(()=>p(()=>import("./n2N0HUVH.js"),[],import.meta.url))},{id:"gnuplot",name:"Gnuplot",import:(()=>p(()=>import("./DdkO51Og.js"),[],import.meta.url))},{id:"go",name:"Go",import:(()=>p(()=>import("./CxLEBnE3.js"),[],import.meta.url))},{id:"graphql",name:"GraphQL",aliases:["gql"],import:(()=>p(()=>import("./C9oPPf7i.js"),__vite__mapDeps([35,2,11,36,13]),import.meta.url))},{id:"groovy",name:"Groovy",import:(()=>p(()=>import("./gcz8RCvz.js"),[],import.meta.url))},{id:"hack",name:"Hack",import:(()=>p(()=>import("./CLZrNe3w.js"),__vite__mapDeps([52,1,2,3,16]),import.meta.url))},{id:"haml",name:"Ruby Haml",import:(()=>p(()=>import("./CmIQRyeF.js"),__vite__mapDeps([34,2,3]),import.meta.url))},{id:"handlebars",name:"Handlebars",aliases:["hbs"],import:(()=>p(()=>import("./m17aaUwq.js"),__vite__mapDeps([53,1,2,3,38]),import.meta.url))},{id:"haskell",name:"Haskell",aliases:["hs"],import:(()=>p(()=>import("./Df6bDoY_.js"),[],import.meta.url))},{id:"haxe",name:"Haxe",import:(()=>p(()=>import("./CzTSHFRz.js"),[],import.meta.url))},{id:"hcl",name:"HashiCorp HCL",import:(()=>p(()=>import("./BWvSN4gD.js"),[],import.meta.url))},{id:"hjson",name:"Hjson",import:(()=>p(()=>import("./D5-asLiD.js"),[],import.meta.url))},{id:"hlsl",name:"HLSL",import:(()=>p(()=>import("./D3lLCCz7.js"),[],import.meta.url))},{id:"html",name:"HTML",import:(()=>p(()=>import("./CnnebwVN.js"),__vite__mapDeps([1,2,3]),import.meta.url))},{id:"html-derivative",name:"HTML (Derivative)",import:(()=>p(()=>import("./DGP4VlC8.js"),__vite__mapDeps([15,1,2,3]),import.meta.url))},{id:"http",name:"HTTP",import:(()=>p(()=>import("./CufHLc7y.js"),__vite__mapDeps([54,28,9,7,8,35,2,11,36,13]),import.meta.url))},{id:"hurl",name:"Hurl",import:(()=>p(()=>import("./CYsAdtH9.js"),__vite__mapDeps([55,35,2,11,36,13,7,8,56]),import.meta.url))},{id:"hxml",name:"HXML",import:(()=>p(()=>import("./DWrx1Km3.js"),__vite__mapDeps([57,58]),import.meta.url))},{id:"hy",name:"Hy",import:(()=>p(()=>import("./DFXneXwc.js"),[],import.meta.url))},{id:"imba",name:"Imba",import:(()=>p(()=>import("./DGztddWO.js"),[],import.meta.url))},{id:"ini",name:"INI",aliases:["properties"],import:(()=>p(()=>import("./BEwlwnbL.js"),[],import.meta.url))},{id:"java",name:"Java",import:(()=>p(()=>import("./CylS5w8V.js"),[],import.meta.url))},{id:"javascript",name:"JavaScript",aliases:["js","cjs","mjs"],import:(()=>p(()=>import("./wDzz0qaB.js"),[],import.meta.url))},{id:"jinja",name:"Jinja",import:(()=>p(()=>import("./CXZktZb0.js"),__vite__mapDeps([59,1,2,3]),import.meta.url))},{id:"jison",name:"Jison",import:(()=>p(()=>import("./Br6cN0cg.js"),__vite__mapDeps([60,2]),import.meta.url))},{id:"json",name:"JSON",import:(()=>p(()=>import("./Cp-IABpG.js"),[],import.meta.url))},{id:"json5",name:"JSON5",import:(()=>p(()=>import("./C9tS-k6U.js"),[],import.meta.url))},{id:"jsonc",name:"JSON with Comments",import:(()=>p(()=>import("./Des-eS-w.js"),[],import.meta.url))},{id:"jsonl",name:"JSON Lines",import:(()=>p(()=>import("./DcaNXYhu.js"),[],import.meta.url))},{id:"jsonnet",name:"Jsonnet",import:(()=>p(()=>import("./DFQXde-d.js"),[],import.meta.url))},{id:"jssm",name:"JSSM",aliases:["fsl"],import:(()=>p(()=>import("./C2t-YnRu.js"),[],import.meta.url))},{id:"jsx",name:"JSX",import:(()=>p(()=>import("./g9-lgVsj.js"),[],import.meta.url))},{id:"julia",name:"Julia",aliases:["jl"],import:(()=>p(()=>import("./W9tJ9s81.js"),__vite__mapDeps([61,23,24,25,26,16,20,2,62]),import.meta.url))},{id:"kdl",name:"KDL",import:(()=>p(()=>import("./DV7GczEv.js"),[],import.meta.url))},{id:"kotlin",name:"Kotlin",aliases:["kt","kts"],import:(()=>p(()=>import("./BdnUsdx6.js"),[],import.meta.url))},{id:"kusto",name:"Kusto",aliases:["kql"],import:(()=>p(()=>import("./DZf3V79B.js"),[],import.meta.url))},{id:"latex",name:"LaTeX",import:(()=>p(()=>import("./DMwsHuHA.js"),__vite__mapDeps([63,64,62]),import.meta.url))},{id:"lean",name:"Lean 4",aliases:["lean4"],import:(()=>p(()=>import("./BZvkOJ9d.js"),[],import.meta.url))},{id:"less",name:"Less",import:(()=>p(()=>import("./B1dDrJ26.js"),[],import.meta.url))},{id:"liquid",name:"Liquid",import:(()=>p(()=>import("./mjskCLCv.js"),__vite__mapDeps([65,1,2,3,9]),import.meta.url))},{id:"llvm",name:"LLVM IR",import:(()=>p(()=>import("./BtvRca6l.js"),[],import.meta.url))},{id:"log",name:"Log file",import:(()=>p(()=>import("./2UxHyX5q.js"),[],import.meta.url))},{id:"logo",name:"Logo",import:(()=>p(()=>import("./BtOb2qkB.js"),[],import.meta.url))},{id:"lua",name:"Lua",import:(()=>p(()=>import("./CnsnAmq5.js"),__vite__mapDeps([37,26]),import.meta.url))},{id:"luau",name:"Luau",import:(()=>p(()=>import("./C-HG3fhB.js"),[],import.meta.url))},{id:"make",name:"Makefile",aliases:["makefile"],import:(()=>p(()=>import("./CHLpvVh8.js"),[],import.meta.url))},{id:"markdown",name:"Markdown",aliases:["md"],import:(()=>p(()=>import("./Cvjx9yec.js"),[],import.meta.url))},{id:"marko",name:"Marko",import:(()=>p(()=>import("./83L43bj1.js"),__vite__mapDeps([66,3,67,5,11]),import.meta.url))},{id:"matlab",name:"MATLAB",import:(()=>p(()=>import("./D7o27uSR.js"),[],import.meta.url))},{id:"mdc",name:"MDC",import:(()=>p(()=>import("./TsXTqZ29.js"),__vite__mapDeps([68,40,38,15,1,2,3]),import.meta.url))},{id:"mdx",name:"MDX",import:(()=>p(()=>import("./Cmh6b_Ma.js"),[],import.meta.url))},{id:"mermaid",name:"Mermaid",aliases:["mmd"],import:(()=>p(()=>import("./mWjccvbQ.js"),[],import.meta.url))},{id:"mipsasm",name:"MIPS Assembly",aliases:["mips"],import:(()=>p(()=>import("./CKIfxQSi.js"),[],import.meta.url))},{id:"mojo",name:"Mojo",import:(()=>p(()=>import("./B93PlW-d.js"),[],import.meta.url))},{id:"moonbit",name:"MoonBit",aliases:["mbt","mbti"],import:(()=>p(()=>import("./Ba13S78F.js"),[],import.meta.url))},{id:"move",name:"Move",import:(()=>p(()=>import("./IF9eRakj.js"),[],import.meta.url))},{id:"narrat",name:"Narrat Language",aliases:["nar"],import:(()=>p(()=>import("./DRg8JJMk.js"),[],import.meta.url))},{id:"nextflow",name:"Nextflow",aliases:["nf"],import:(()=>p(()=>import("./BrzmwbiE.js"),[],import.meta.url))},{id:"nginx",name:"Nginx",import:(()=>p(()=>import("./Dph4kLrZ.js"),__vite__mapDeps([69,37,26]),import.meta.url))},{id:"nim",name:"Nim",import:(()=>p(()=>import("./DhmSosst.js"),__vite__mapDeps([70,26,1,2,3,7,8,25,40]),import.meta.url))},{id:"nix",name:"Nix",import:(()=>p(()=>import("./CwoSXNpI.js"),[],import.meta.url))},{id:"nushell",name:"nushell",aliases:["nu"],import:(()=>p(()=>import("./C-sUppwS.js"),[],import.meta.url))},{id:"objective-c",name:"Objective-C",aliases:["objc"],import:(()=>p(()=>import("./DXmwc3jG.js"),[],import.meta.url))},{id:"objective-cpp",name:"Objective-C++",import:(()=>p(()=>import("./CLxacb5B.js"),[],import.meta.url))},{id:"ocaml",name:"OCaml",import:(()=>p(()=>import("./C0hk2d4L.js"),[],import.meta.url))},{id:"odin",name:"Odin",import:(()=>p(()=>import("./BBf5iR-q.js"),[],import.meta.url))},{id:"openscad",name:"OpenSCAD",aliases:["scad"],import:(()=>p(()=>import("./C4EeE6gA.js"),[],import.meta.url))},{id:"pascal",name:"Pascal",import:(()=>p(()=>import("./D93ZcfNL.js"),[],import.meta.url))},{id:"perl",name:"Perl",import:(()=>p(()=>import("./BzTr9Aqm.js"),__vite__mapDeps([71,1,2,3,7,8,16]),import.meta.url))},{id:"php",name:"PHP",import:(()=>p(()=>import("./DJjDtW9f.js"),__vite__mapDeps([72,1,2,3,7,8,16,9]),import.meta.url))},{id:"pkl",name:"Pkl",import:(()=>p(()=>import("./u5AG7uiY.js"),[],import.meta.url))},{id:"plsql",name:"PL/SQL",import:(()=>p(()=>import("./ChMvpjG-.js"),[],import.meta.url))},{id:"po",name:"Gettext PO",aliases:["pot","potx"],import:(()=>p(()=>import("./BTJTHyun.js"),[],import.meta.url))},{id:"polar",name:"Polar",import:(()=>p(()=>import("./C0HS_06l.js"),[],import.meta.url))},{id:"postcss",name:"PostCSS",import:(()=>p(()=>import("./CXtECtnM.js"),[],import.meta.url))},{id:"powerquery",name:"PowerQuery",import:(()=>p(()=>import("./CEu0bR-o.js"),[],import.meta.url))},{id:"powershell",name:"PowerShell",aliases:["ps","ps1"],import:(()=>p(()=>import("./Dpen1YoG.js"),[],import.meta.url))},{id:"prisma",name:"Prisma",import:(()=>p(()=>import("./Dd19v3D-.js"),[],import.meta.url))},{id:"prolog",name:"Prolog",import:(()=>p(()=>import("./CbFg5uaA.js"),[],import.meta.url))},{id:"proto",name:"Protocol Buffer 3",aliases:["protobuf"],import:(()=>p(()=>import("./C7zT0LnQ.js"),[],import.meta.url))},{id:"pug",name:"Pug",aliases:["jade"],import:(()=>p(()=>import("./BLmx8bSh.js"),__vite__mapDeps([73,2,3,1]),import.meta.url))},{id:"puppet",name:"Puppet",import:(()=>p(()=>import("./BMWR74SV.js"),[],import.meta.url))},{id:"purescript",name:"PureScript",import:(()=>p(()=>import("./CklMAg4u.js"),[],import.meta.url))},{id:"python",name:"Python",aliases:["py"],import:(()=>p(()=>import("./B6aJPvgy.js"),[],import.meta.url))},{id:"qml",name:"QML",import:(()=>p(()=>import("./BVQ-GDCI.js"),__vite__mapDeps([74,2]),import.meta.url))},{id:"qmldir",name:"QML Directory",import:(()=>p(()=>import("./C8lEn-DE.js"),[],import.meta.url))},{id:"qss",name:"Qt Style Sheets",import:(()=>p(()=>import("./IeuSbFQv.js"),[],import.meta.url))},{id:"r",name:"R",import:(()=>p(()=>import("./Dspwwk_N.js"),[],import.meta.url))},{id:"racket",name:"Racket",import:(()=>p(()=>import("./BqYA7rlc.js"),[],import.meta.url))},{id:"raku",name:"Raku",aliases:["perl6"],import:(()=>p(()=>import("./DXvB9xmW.js"),[],import.meta.url))},{id:"razor",name:"ASP.NET Razor",import:(()=>p(()=>import("./DsumFeuD.js"),__vite__mapDeps([75,1,2,3,76]),import.meta.url))},{id:"reg",name:"Windows Registry Script",import:(()=>p(()=>import("./C-SQnVFl.js"),[],import.meta.url))},{id:"regexp",name:"RegExp",aliases:["regex"],import:(()=>p(()=>import("./CDVJQ6XC.js"),[],import.meta.url))},{id:"rel",name:"Rel",import:(()=>p(()=>import("./C3B-1QV4.js"),[],import.meta.url))},{id:"riscv",name:"RISC-V",import:(()=>p(()=>import("./BM1_JUlF.js"),[],import.meta.url))},{id:"ron",name:"RON",import:(()=>p(()=>import("./BhRPY-oY.js"),[],import.meta.url))},{id:"rosmsg",name:"ROS Interface",import:(()=>p(()=>import("./BJDFO7_C.js"),[],import.meta.url))},{id:"rst",name:"reStructuredText",import:(()=>p(()=>import("./DQwYQDb2.js"),__vite__mapDeps([77,15,1,2,3,23,24,25,26,16,20,28,38,78,33,34,7,8,35,11,36,13,37]),import.meta.url))},{id:"ruby",name:"Ruby",aliases:["rb"],import:(()=>p(()=>import("./Bhrxn6JZ.js"),__vite__mapDeps([33,1,2,3,34,7,8,16,35,11,36,13,23,24,25,26,28,37,38]),import.meta.url))},{id:"rust",name:"Rust",aliases:["rs"],import:(()=>p(()=>import("./B1yitclQ.js"),[],import.meta.url))},{id:"sas",name:"SAS",import:(()=>p(()=>import("./CG8Ifv2g.js"),__vite__mapDeps([79,16]),import.meta.url))},{id:"sass",name:"Sass",import:(()=>p(()=>import("./Cj5Yp3dK.js"),[],import.meta.url))},{id:"scala",name:"Scala",import:(()=>p(()=>import("./C151Ov-r.js"),[],import.meta.url))},{id:"scheme",name:"Scheme",import:(()=>p(()=>import("./C98Dy4si.js"),[],import.meta.url))},{id:"scss",name:"SCSS",import:(()=>p(()=>import("./2EtD6e53.js"),__vite__mapDeps([5,3]),import.meta.url))},{id:"sdbl",name:"1C (Query)",aliases:["1c-query"],import:(()=>p(()=>import("./DVxCFoDh.js"),[],import.meta.url))},{id:"shaderlab",name:"ShaderLab",aliases:["shader"],import:(()=>p(()=>import("./BqTXFGrv.js"),__vite__mapDeps([80,81]),import.meta.url))},{id:"shellscript",name:"Shell",aliases:["bash","sh","shell","zsh"],import:(()=>p(()=>import("./Yzrsuije.js"),[],import.meta.url))},{id:"shellsession",name:"Shell Session",aliases:["console"],import:(()=>p(()=>import("./Cq5zzVJU.js"),__vite__mapDeps([82,28]),import.meta.url))},{id:"smalltalk",name:"Smalltalk",import:(()=>p(()=>import("./BERRCDM3.js"),[],import.meta.url))},{id:"solidity",name:"Solidity",import:(()=>p(()=>import("./rGO070M0.js"),[],import.meta.url))},{id:"soy",name:"Closure Templates",aliases:["closure-templates"],import:(()=>p(()=>import("./Dzze3sRP.js"),__vite__mapDeps([83,1,2,3]),import.meta.url))},{id:"sparql",name:"SPARQL",import:(()=>p(()=>import("./BRZ36xJF.js"),__vite__mapDeps([84,85]),import.meta.url))},{id:"splunk",name:"Splunk Query Language",aliases:["spl"],import:(()=>p(()=>import("./BtCnVYZw.js"),[],import.meta.url))},{id:"sql",name:"SQL",import:(()=>p(()=>import("./BLtJtn59.js"),[],import.meta.url))},{id:"ssh-config",name:"SSH Config",import:(()=>p(()=>import("./_ykCGR6B.js"),[],import.meta.url))},{id:"stata",name:"Stata",import:(()=>p(()=>import("./DM8c43g1.js"),__vite__mapDeps([86,16]),import.meta.url))},{id:"stylus",name:"Stylus",aliases:["styl"],import:(()=>p(()=>import("./BEDo0Tqx.js"),[],import.meta.url))},{id:"surrealql",name:"SurrealQL",aliases:["surql"],import:(()=>p(()=>import("./BH7IYjvW.js"),__vite__mapDeps([87,2]),import.meta.url))},{id:"svelte",name:"Svelte",import:(()=>p(()=>import("./DYoxhk2S.js"),__vite__mapDeps([88,2,11,3,12]),import.meta.url))},{id:"swift",name:"Swift",import:(()=>p(()=>import("./Dg5xB15N.js"),[],import.meta.url))},{id:"system-verilog",name:"SystemVerilog",import:(()=>p(()=>import("./CnnmHF94.js"),[],import.meta.url))},{id:"systemd",name:"Systemd Units",import:(()=>p(()=>import("./4A_iFExJ.js"),[],import.meta.url))},{id:"talonscript",name:"TalonScript",aliases:["talon"],import:(()=>p(()=>import("./CkByrt1z.js"),[],import.meta.url))},{id:"tasl",name:"Tasl",import:(()=>p(()=>import("./QIJgUcNo.js"),[],import.meta.url))},{id:"tcl",name:"Tcl",import:(()=>p(()=>import("./dwOrl1Do.js"),[],import.meta.url))},{id:"templ",name:"Templ",import:(()=>p(()=>import("./CZhp0h8q.js"),__vite__mapDeps([89,90,2,3]),import.meta.url))},{id:"terraform",name:"Terraform",aliases:["tf","tfvars"],import:(()=>p(()=>import("./BETggiCN.js"),[],import.meta.url))},{id:"tex",name:"TeX",import:(()=>p(()=>import("./CQ8jqdy-.js"),__vite__mapDeps([64,62]),import.meta.url))},{id:"toml",name:"TOML",import:(()=>p(()=>import("./vGWfd6FD.js"),[],import.meta.url))},{id:"ts-tags",name:"TypeScript with Tags",aliases:["lit"],import:(()=>p(()=>import("./Cm3UrAx6.js"),__vite__mapDeps([91,11,3,2,25,26,1,16,7,8]),import.meta.url))},{id:"tsv",name:"TSV",import:(()=>p(()=>import("./B_m7g4N7.js"),[],import.meta.url))},{id:"tsx",name:"TSX",import:(()=>p(()=>import("./COt5Ahok.js"),[],import.meta.url))},{id:"turtle",name:"Turtle",import:(()=>p(()=>import("./BsS91CYL.js"),[],import.meta.url))},{id:"twig",name:"Twig",import:(()=>p(()=>import("./RNghxpo_.js"),__vite__mapDeps([92,3,2,5,72,1,7,8,16,9,20,33,34,35,11,36,13,23,24,25,26,28,37,38]),import.meta.url))},{id:"typescript",name:"TypeScript",aliases:["ts","cts","mts"],import:(()=>p(()=>import("./BPQ3VLAy.js"),[],import.meta.url))},{id:"typespec",name:"TypeSpec",aliases:["tsp"],import:(()=>p(()=>import("./BGHnOYBU.js"),[],import.meta.url))},{id:"typst",name:"Typst",aliases:["typ"],import:(()=>p(()=>import("./DHCkPAjA.js"),[],import.meta.url))},{id:"v",name:"V",import:(()=>p(()=>import("./BcVCzyr7.js"),[],import.meta.url))},{id:"vala",name:"Vala",import:(()=>p(()=>import("./CsfeWuGM.js"),[],import.meta.url))},{id:"vb",name:"Visual Basic",aliases:["cmd"],import:(()=>p(()=>import("./D17OF-Vu.js"),[],import.meta.url))},{id:"verilog",name:"Verilog",import:(()=>p(()=>import("./BQ8w6xss.js"),[],import.meta.url))},{id:"vhdl",name:"VHDL",import:(()=>p(()=>import("./CeAyd5Ju.js"),[],import.meta.url))},{id:"viml",name:"Vim Script",aliases:["vim","vimscript"],import:(()=>p(()=>import("./CJc9bBzg.js"),[],import.meta.url))},{id:"vue",name:"Vue",import:(()=>p(()=>import("./DEthMvLe.js"),__vite__mapDeps([93,3,2,11,9,1,15]),import.meta.url))},{id:"vue-html",name:"Vue HTML",import:(()=>p(()=>import("./DqQDbK_p.js"),__vite__mapDeps([94,2]),import.meta.url))},{id:"vue-vine",name:"Vue Vine",import:(()=>p(()=>import("./CW8IKDeL.js"),__vite__mapDeps([95,3,5,67,96,12,2]),import.meta.url))},{id:"vyper",name:"Vyper",aliases:["vy"],import:(()=>p(()=>import("./CDx5xZoG.js"),[],import.meta.url))},{id:"wasm",name:"WebAssembly",import:(()=>p(()=>import("./MzD3tlZU.js"),[],import.meta.url))},{id:"wenyan",name:"Wenyan",aliases:["文言"],import:(()=>p(()=>import("./BV7otONQ.js"),[],import.meta.url))},{id:"wgsl",name:"WGSL",import:(()=>p(()=>import("./Dx-B1_4e.js"),[],import.meta.url))},{id:"wikitext",name:"Wikitext",aliases:["mediawiki","wiki"],import:(()=>p(()=>import("./BhOHFoWU.js"),[],import.meta.url))},{id:"wit",name:"WebAssembly Interface Types",import:(()=>p(()=>import("./5i3qLPDT.js"),[],import.meta.url))},{id:"wolfram",name:"Wolfram",aliases:["wl"],import:(()=>p(()=>import("./lXgVvXCa.js"),[],import.meta.url))},{id:"xml",name:"XML",import:(()=>p(()=>import("./BGJmEYvX.js"),__vite__mapDeps([7,8]),import.meta.url))},{id:"xsl",name:"XSL",import:(()=>p(()=>import("./yv6CvBhz.js"),__vite__mapDeps([97,7,8]),import.meta.url))},{id:"yaml",name:"YAML",aliases:["yml"],import:(()=>p(()=>import("./Buea-lGh.js"),[],import.meta.url))},{id:"zenscript",name:"ZenScript",import:(()=>p(()=>import("./DVFEvuxE.js"),[],import.meta.url))},{id:"zig",name:"Zig",import:(()=>p(()=>import("./VOosw3JB.js"),[],import.meta.url))}],yh=Object.fromEntries(Za.map(t=>[t.id,t.import])),vh=Object.fromEntries(Za.flatMap(t=>t.aliases?.map(e=>[e,t.import])||[])),bh={...yh,...vh},kh=[{id:"andromeeda",displayName:"Andromeeda",type:"dark",import:(()=>p(()=>import("./C4gqWexZ.js"),[],import.meta.url))},{id:"aurora-x",displayName:"Aurora X",type:"dark",import:(()=>p(()=>import("./D-2ljcwZ.js"),[],import.meta.url))},{id:"ayu-dark",displayName:"Ayu Dark",type:"dark",import:(()=>p(()=>import("./CMjwMIkn.js"),[],import.meta.url))},{id:"ayu-light",displayName:"Ayu Light",type:"light",import:(()=>p(()=>import("./C47S-Tmv.js"),[],import.meta.url))},{id:"ayu-mirage",displayName:"Ayu Mirage",type:"dark",import:(()=>p(()=>import("./CjoLj4QM.js"),[],import.meta.url))},{id:"catppuccin-frappe",displayName:"Catppuccin Frappé",type:"dark",import:(()=>p(()=>import("./DFWUc33u.js"),[],import.meta.url))},{id:"catppuccin-latte",displayName:"Catppuccin Latte",type:"light",import:(()=>p(()=>import("./C9dUb6Cb.js"),[],import.meta.url))},{id:"catppuccin-macchiato",displayName:"Catppuccin Macchiato",type:"dark",import:(()=>p(()=>import("./DQyhUUbL.js"),[],import.meta.url))},{id:"catppuccin-mocha",displayName:"Catppuccin Mocha",type:"dark",import:(()=>p(()=>import("./D87Tk5Gz.js"),[],import.meta.url))},{id:"dark-plus",displayName:"Dark Plus",type:"dark",import:(()=>p(()=>import("./C3mMm8J8.js"),[],import.meta.url))},{id:"dracula",displayName:"Dracula Theme",type:"dark",import:(()=>p(()=>import("./BzJJZx-M.js"),[],import.meta.url))},{id:"dracula-soft",displayName:"Dracula Theme Soft",type:"dark",import:(()=>p(()=>import("./BXkSAIEj.js"),[],import.meta.url))},{id:"everforest-dark",displayName:"Everforest Dark",type:"dark",import:(()=>p(()=>import("./BgDCqdQA.js"),[],import.meta.url))},{id:"everforest-light",displayName:"Everforest Light",type:"light",import:(()=>p(()=>import("./C8M2exoo.js"),[],import.meta.url))},{id:"github-dark",displayName:"GitHub Dark",type:"dark",import:(()=>p(()=>import("./DHJKELXO.js"),[],import.meta.url))},{id:"github-dark-default",displayName:"GitHub Dark Default",type:"dark",import:(()=>p(()=>import("./Cuk6v7N8.js"),[],import.meta.url))},{id:"github-dark-dimmed",displayName:"GitHub Dark Dimmed",type:"dark",import:(()=>p(()=>import("./DH5Ifo-i.js"),[],import.meta.url))},{id:"github-dark-high-contrast",displayName:"GitHub Dark High Contrast",type:"dark",import:(()=>p(()=>import("./E3gJ1_iC.js"),[],import.meta.url))},{id:"github-light",displayName:"GitHub Light",type:"light",import:(()=>p(()=>import("./DAi9KRSo.js"),[],import.meta.url))},{id:"github-light-default",displayName:"GitHub Light Default",type:"light",import:(()=>p(()=>import("./D7oLnXFd.js"),[],import.meta.url))},{id:"github-light-high-contrast",displayName:"GitHub Light High Contrast",type:"light",import:(()=>p(()=>import("./BfjtVDDH.js"),[],import.meta.url))},{id:"gruvbox-dark-hard",displayName:"Gruvbox Dark Hard",type:"dark",import:(()=>p(()=>import("./CFHQjOhq.js"),[],import.meta.url))},{id:"gruvbox-dark-medium",displayName:"Gruvbox Dark Medium",type:"dark",import:(()=>p(()=>import("./GsRaNv29.js"),[],import.meta.url))},{id:"gruvbox-dark-soft",displayName:"Gruvbox Dark Soft",type:"dark",import:(()=>p(()=>import("./CVdnzihN.js"),[],import.meta.url))},{id:"gruvbox-light-hard",displayName:"Gruvbox Light Hard",type:"light",import:(()=>p(()=>import("./CH1njM8p.js"),[],import.meta.url))},{id:"gruvbox-light-medium",displayName:"Gruvbox Light Medium",type:"light",import:(()=>p(()=>import("./DRw_LuNl.js"),[],import.meta.url))},{id:"gruvbox-light-soft",displayName:"Gruvbox Light Soft",type:"light",import:(()=>p(()=>import("./hJgmCMqR.js"),[],import.meta.url))},{id:"horizon",displayName:"Horizon",type:"dark",import:(()=>p(()=>import("./BUw7H-hv.js"),[],import.meta.url))},{id:"houston",displayName:"Houston",type:"dark",import:(()=>p(()=>import("./DnULxvSX.js"),[],import.meta.url))},{id:"kanagawa-dragon",displayName:"Kanagawa Dragon",type:"dark",import:(()=>p(()=>import("./CkXjmgJE.js"),[],import.meta.url))},{id:"kanagawa-lotus",displayName:"Kanagawa Lotus",type:"light",import:(()=>p(()=>import("./CfQXZHmo.js"),[],import.meta.url))},{id:"kanagawa-wave",displayName:"Kanagawa Wave",type:"dark",import:(()=>p(()=>import("./DWedfzmr.js"),[],import.meta.url))},{id:"laserwave",displayName:"LaserWave",type:"dark",import:(()=>p(()=>import("./DUszq2jm.js"),[],import.meta.url))},{id:"light-plus",displayName:"Light Plus",type:"light",import:(()=>p(()=>import("./B7mTdjB0.js"),[],import.meta.url))},{id:"material-theme",displayName:"Material Theme",type:"dark",import:(()=>p(()=>import("./D5KoaKCx.js"),[],import.meta.url))},{id:"material-theme-darker",displayName:"Material Theme Darker",type:"dark",import:(()=>p(()=>import("./BfHTSMKl.js"),[],import.meta.url))},{id:"material-theme-lighter",displayName:"Material Theme Lighter",type:"light",import:(()=>p(()=>import("./B0m2ddpp.js"),[],import.meta.url))},{id:"material-theme-ocean",displayName:"Material Theme Ocean",type:"dark",import:(()=>p(()=>import("./CyktbL80.js"),[],import.meta.url))},{id:"material-theme-palenight",displayName:"Material Theme Palenight",type:"dark",import:(()=>p(()=>import("./Csfq5Kiy.js"),[],import.meta.url))},{id:"min-dark",displayName:"Min Dark",type:"dark",import:(()=>p(()=>import("./CafNBF8u.js"),[],import.meta.url))},{id:"min-light",displayName:"Min Light",type:"light",import:(()=>p(()=>import("./CTRr51gU.js"),[],import.meta.url))},{id:"monokai",displayName:"Monokai",type:"dark",import:(()=>p(()=>import("./D4h5O-jR.js"),[],import.meta.url))},{id:"night-owl",displayName:"Night Owl",type:"dark",import:(()=>p(()=>import("./C39BiMTA.js"),[],import.meta.url))},{id:"night-owl-light",displayName:"Night Owl Light",type:"light",import:(()=>p(()=>import("./CMTm3GFP.js"),[],import.meta.url))},{id:"nord",displayName:"Nord",type:"dark",import:(()=>p(()=>import("./Ddv68eIx.js"),[],import.meta.url))},{id:"one-dark-pro",displayName:"One Dark Pro",type:"dark",import:(()=>p(()=>import("./DVMEJ2y_.js"),[],import.meta.url))},{id:"one-light",displayName:"One Light",type:"light",import:(()=>p(()=>import("./C3Wv6jpd.js"),[],import.meta.url))},{id:"plastic",displayName:"Plastic",type:"dark",import:(()=>p(()=>import("./3e1v2bzS.js"),[],import.meta.url))},{id:"poimandres",displayName:"Poimandres",type:"dark",import:(()=>p(()=>import("./CS3Unz2-.js"),[],import.meta.url))},{id:"red",displayName:"Red",type:"dark",import:(()=>p(()=>import("./bN70gL4F.js"),[],import.meta.url))},{id:"rose-pine",displayName:"Rosé Pine",type:"dark",import:(()=>p(()=>import("./qdsjHGoJ.js"),[],import.meta.url))},{id:"rose-pine-dawn",displayName:"Rosé Pine Dawn",type:"light",import:(()=>p(()=>import("./DHQR4-dF.js"),[],import.meta.url))},{id:"rose-pine-moon",displayName:"Rosé Pine Moon",type:"dark",import:(()=>p(()=>import("./D4_iv3hh.js"),[],import.meta.url))},{id:"slack-dark",displayName:"Slack Dark",type:"dark",import:(()=>p(()=>import("./BthQWCQV.js"),[],import.meta.url))},{id:"slack-ochin",displayName:"Slack Ochin",type:"light",import:(()=>p(()=>import("./DqwNpetd.js"),[],import.meta.url))},{id:"snazzy-light",displayName:"Snazzy Light",type:"light",import:(()=>p(()=>import("./Bw305WKR.js"),[],import.meta.url))},{id:"solarized-dark",displayName:"Solarized Dark",type:"dark",import:(()=>p(()=>import("./DXbdFlpD.js"),[],import.meta.url))},{id:"solarized-light",displayName:"Solarized Light",type:"light",import:(()=>p(()=>import("./L9t79GZl.js"),[],import.meta.url))},{id:"synthwave-84",displayName:"Synthwave '84",type:"dark",import:(()=>p(()=>import("./CbfX1IO0.js"),[],import.meta.url))},{id:"tokyo-night",displayName:"Tokyo Night",type:"dark",import:(()=>p(()=>import("./hegEt444.js"),[],import.meta.url))},{id:"vesper",displayName:"Vesper",type:"dark",import:(()=>p(()=>import("./DU1UobuO.js"),[],import.meta.url))},{id:"vitesse-black",displayName:"Vitesse Black",type:"dark",import:(()=>p(()=>import("./Bkuqu6BP.js"),[],import.meta.url))},{id:"vitesse-dark",displayName:"Vitesse Dark",type:"dark",import:(()=>p(()=>import("./D0r3Knsf.js"),[],import.meta.url))},{id:"vitesse-light",displayName:"Vitesse Light",type:"light",import:(()=>p(()=>import("./CVO1_9PV.js"),[],import.meta.url))}],el=Object.fromEntries(kh.map(t=>[t.id,t.import]));class Xi extends Error{constructor(e){super(e),this.name="ShikiError"}}function wh(){return 2147483648}function xh(){return typeof performance<"u"?performance.now():Date.now()}const Eh=(t,e)=>t+(e-t%e)%e;async function Th(t){let e,n;const r={};function i(f){n=f,r.HEAPU8=new Uint8Array(f),r.HEAPU32=new Uint32Array(f)}function o(f,g,y){r.HEAPU8.copyWithin(f,g,g+y)}function s(f){try{return e.grow(f-n.byteLength+65535>>>16),i(e.buffer),1}catch{}}function l(f){const g=r.HEAPU8.length;f=f>>>0;const y=wh();if(f>y)return!1;for(let x=1;x<=4;x*=2){let v=g*(1+.2/x);v=Math.min(v,f+100663296);const k=Math.min(y,Eh(Math.max(f,v),65536));if(s(k))return!0}return!1}const a=typeof TextDecoder<"u"?new TextDecoder("utf8"):void 0;function c(f,g,y=1024){const x=g+y;let v=g;for(;f[v]&&!(v>=x);)++v;if(v-g>16&&f.buffer&&a)return a.decode(f.subarray(g,v));let k="";for(;g<v;){let b=f[g++];if(!(b&128)){k+=String.fromCharCode(b);continue}const E=f[g++]&63;if((b&224)===192){k+=String.fromCharCode((b&31)<<6|E);continue}const P=f[g++]&63;if((b&240)===224?b=(b&15)<<12|E<<6|P:b=(b&7)<<18|E<<12|P<<6|f[g++]&63,b<65536)k+=String.fromCharCode(b);else{const V=b-65536;k+=String.fromCharCode(55296|V>>10,56320|V&1023)}}return k}function u(f,g){return f?c(r.HEAPU8,f,g):""}const d={emscripten_get_now:xh,emscripten_memcpy_big:o,emscripten_resize_heap:l,fd_write:()=>0};async function h(){const g=await t({env:d,wasi_snapshot_preview1:d});e=g.memory,i(e.buffer),Object.assign(r,g),r.UTF8ToString=u}return await h(),r}var Ah=Object.defineProperty,Sh=(t,e,n)=>e in t?Ah(t,e,{enumerable:!0,configurable:!0,writable:!0,value:n}):t[e]=n,ge=(t,e,n)=>Sh(t,typeof e!="symbol"?e+"":e,n);let ye=null;function Rh(t){throw new Xi(t.UTF8ToString(t.getLastOnigError()))}class fr{constructor(e){ge(this,"utf16Length"),ge(this,"utf8Length"),ge(this,"utf16Value"),ge(this,"utf8Value"),ge(this,"utf16OffsetToUtf8"),ge(this,"utf8OffsetToUtf16");const n=e.length,r=fr._utf8ByteLength(e),i=r!==n,o=i?new Uint32Array(n+1):null;i&&(o[n]=r);const s=i?new Uint32Array(r+1):null;i&&(s[r]=n);const l=new Uint8Array(r);let a=0;for(let c=0;c<n;c++){const u=e.charCodeAt(c);let d=u,h=!1;if(u>=55296&&u<=56319&&c+1<n){const f=e.charCodeAt(c+1);f>=56320&&f<=57343&&(d=(u-55296<<10)+65536|f-56320,h=!0)}i&&(o[c]=a,h&&(o[c+1]=a),d<=127?s[a+0]=c:d<=2047?(s[a+0]=c,s[a+1]=c):d<=65535?(s[a+0]=c,s[a+1]=c,s[a+2]=c):(s[a+0]=c,s[a+1]=c,s[a+2]=c,s[a+3]=c)),d<=127?l[a++]=d:d<=2047?(l[a++]=192|(d&1984)>>>6,l[a++]=128|(d&63)>>>0):d<=65535?(l[a++]=224|(d&61440)>>>12,l[a++]=128|(d&4032)>>>6,l[a++]=128|(d&63)>>>0):(l[a++]=240|(d&1835008)>>>18,l[a++]=128|(d&258048)>>>12,l[a++]=128|(d&4032)>>>6,l[a++]=128|(d&63)>>>0),h&&c++}this.utf16Length=n,this.utf8Length=r,this.utf16Value=e,this.utf8Value=l,this.utf16OffsetToUtf8=o,this.utf8OffsetToUtf16=s}static _utf8ByteLength(e){let n=0;for(let r=0,i=e.length;r<i;r++){const o=e.charCodeAt(r);let s=o,l=!1;if(o>=55296&&o<=56319&&r+1<i){const a=e.charCodeAt(r+1);a>=56320&&a<=57343&&(s=(o-55296<<10)+65536|a-56320,l=!0)}s<=127?n+=1:s<=2047?n+=2:s<=65535?n+=3:n+=4,l&&r++}return n}createString(e){const n=e.omalloc(this.utf8Length);return e.HEAPU8.set(this.utf8Value,n),n}}const hr=class Qe{constructor(e){if(ge(this,"id",++Qe.LAST_ID),ge(this,"_onigBinding"),ge(this,"content"),ge(this,"utf16Length"),ge(this,"utf8Length"),ge(this,"utf16OffsetToUtf8"),ge(this,"utf8OffsetToUtf16"),ge(this,"ptr"),!ye)throw new Xi("Must invoke loadWasm first.");this._onigBinding=ye,this.content=e;const n=new fr(e);this.utf16Length=n.utf16Length,this.utf8Length=n.utf8Length,this.utf16OffsetToUtf8=n.utf16OffsetToUtf8,this.utf8OffsetToUtf16=n.utf8OffsetToUtf16,this.utf8Length<1e4&&!Qe._sharedPtrInUse?(Qe._sharedPtr||(Qe._sharedPtr=ye.omalloc(1e4)),Qe._sharedPtrInUse=!0,ye.HEAPU8.set(n.utf8Value,Qe._sharedPtr),this.ptr=Qe._sharedPtr):this.ptr=n.createString(ye)}convertUtf8OffsetToUtf16(e){return this.utf8OffsetToUtf16?e<0?0:e>this.utf8Length?this.utf16Length:this.utf8OffsetToUtf16[e]:e}convertUtf16OffsetToUtf8(e){return this.utf16OffsetToUtf8?e<0?0:e>this.utf16Length?this.utf8Length:this.utf16OffsetToUtf8[e]:e}dispose(){this.ptr===Qe._sharedPtr?Qe._sharedPtrInUse=!1:this._onigBinding.ofree(this.ptr)}};ge(hr,"LAST_ID",0);ge(hr,"_sharedPtr",0);ge(hr,"_sharedPtrInUse",!1);let tl=hr;class Lh{constructor(e){if(ge(this,"_onigBinding"),ge(this,"_ptr"),!ye)throw new Xi("Must invoke loadWasm first.");const n=[],r=[];for(let l=0,a=e.length;l<a;l++){const c=new fr(e[l]);n[l]=c.createString(ye),r[l]=c.utf8Length}const i=ye.omalloc(4*e.length);ye.HEAPU32.set(n,i/4);const o=ye.omalloc(4*e.length);ye.HEAPU32.set(r,o/4);const s=ye.createOnigScanner(i,o,e.length);for(let l=0,a=e.length;l<a;l++)ye.ofree(n[l]);ye.ofree(o),ye.ofree(i),s===0&&Rh(ye),this._onigBinding=ye,this._ptr=s}dispose(){this._onigBinding.freeOnigScanner(this._ptr)}findNextMatchSync(e,n,r){let i=0;if(typeof r=="number"&&(i=r),typeof e=="string"){e=new tl(e);const o=this._findNextMatchSync(e,n,!1,i);return e.dispose(),o}return this._findNextMatchSync(e,n,!1,i)}_findNextMatchSync(e,n,r,i){const o=this._onigBinding,s=o.findNextOnigScannerMatch(this._ptr,e.id,e.ptr,e.utf8Length,e.convertUtf16OffsetToUtf8(n),i);if(s===0)return null;const l=o.HEAPU32;let a=s/4;const c=l[a++],u=l[a++],d=[];for(let h=0;h<u;h++){const f=e.convertUtf8OffsetToUtf16(l[a++]),g=e.convertUtf8OffsetToUtf16(l[a++]);d[h]={start:f,end:g,length:g-f}}return{index:c,captureIndices:d}}}function Ch(t){return typeof t.instantiator=="function"}function Ph(t){return typeof t.default=="function"}function Oh(t){return typeof t.data<"u"}function Ih(t){return typeof Response<"u"&&t instanceof Response}function Dh(t){return typeof ArrayBuffer<"u"&&(t instanceof ArrayBuffer||ArrayBuffer.isView(t))||typeof Buffer<"u"&&Buffer.isBuffer?.(t)||typeof SharedArrayBuffer<"u"&&t instanceof SharedArrayBuffer||typeof Uint32Array<"u"&&t instanceof Uint32Array}let Nn;function Nh(t){if(Nn)return Nn;async function e(){ye=await Th(async n=>{let r=t;return r=await r,typeof r=="function"&&(r=await r(n)),typeof r=="function"&&(r=await r(n)),Ch(r)?r=await r.instantiator(n):Ph(r)?r=await r.default(n):(Oh(r)&&(r=r.data),Ih(r)?typeof WebAssembly.instantiateStreaming=="function"?r=await Mh(r)(n):r=await $h(r)(n):Dh(r)?r=await $r(r)(n):r instanceof WebAssembly.Module?r=await $r(r)(n):"default"in r&&r.default instanceof WebAssembly.Module&&(r=await $r(r.default)(n))),"instance"in r&&(r=r.instance),"exports"in r&&(r=r.exports),r})}return Nn=e(),Nn}function $r(t){return e=>WebAssembly.instantiate(t,e)}function Mh(t){return e=>WebAssembly.instantiateStreaming(t,e)}function $h(t){return async e=>{const n=await t.arrayBuffer();return WebAssembly.instantiate(n,e)}}async function nl(t){return t&&await Nh(t),{createScanner(e){return new Lh(e.map(n=>typeof n=="string"?n:n.source))},createString(e){return new tl(e)}}}const Vh=Qa({langs:bh,themes:el,engine:()=>nl(p(()=>import("./CG6Dc4jp.js"),[],import.meta.url))}),{codeToHtml:Bh}=Ja(Vh,{guessEmbeddedLanguages:Ha});const{entries:rl,setPrototypeOf:cs,isFrozen:zh,getPrototypeOf:Fh,getOwnPropertyDescriptor:jh}=Object;let{freeze:Re,seal:ze,create:gi}=Object,{apply:_i,construct:yi}=typeof Reflect<"u"&&Reflect;Re||(Re=function(e){return e});ze||(ze=function(e){return e});_i||(_i=function(e,n){for(var r=arguments.length,i=new Array(r>2?r-2:0),o=2;o<r;o++)i[o-2]=arguments[o];return e.apply(n,i)});yi||(yi=function(e){for(var n=arguments.length,r=new Array(n>1?n-1:0),i=1;i<n;i++)r[i-1]=arguments[i];return new e(...r)});const Mn=Le(Array.prototype.forEach),qh=Le(Array.prototype.lastIndexOf),us=Le(Array.prototype.pop),Jt=Le(Array.prototype.push),Hh=Le(Array.prototype.splice),zn=Le(String.prototype.toLowerCase),Vr=Le(String.prototype.toString),Br=Le(String.prototype.match),Zt=Le(String.prototype.replace),Gh=Le(String.prototype.indexOf),Uh=Le(String.prototype.trim),Fe=Le(Object.prototype.hasOwnProperty),Ae=Le(RegExp.prototype.test),en=Wh(TypeError);function Le(t){return function(e){e instanceof RegExp&&(e.lastIndex=0);for(var n=arguments.length,r=new Array(n>1?n-1:0),i=1;i<n;i++)r[i-1]=arguments[i];return _i(t,e,r)}}function Wh(t){return function(){for(var e=arguments.length,n=new Array(e),r=0;r<e;r++)n[r]=arguments[r];return yi(t,n)}}function Q(t,e){let n=arguments.length>2&&arguments[2]!==void 0?arguments[2]:zn;cs&&cs(t,null);let r=e.length;for(;r--;){let i=e[r];if(typeof i=="string"){const o=n(i);o!==i&&(zh(e)||(e[r]=o),i=o)}t[i]=!0}return t}function Kh(t){for(let e=0;e<t.length;e++)Fe(t,e)||(t[e]=null);return t}function Je(t){const e=gi(null);for(const[n,r]of rl(t))Fe(t,n)&&(Array.isArray(r)?e[n]=Kh(r):r&&typeof r=="object"&&r.constructor===Object?e[n]=Je(r):e[n]=r);return e}function tn(t,e){for(;t!==null;){const r=jh(t,e);if(r){if(r.get)return Le(r.get);if(typeof r.value=="function")return Le(r.value)}t=Fh(t)}function n(){return null}return n}const ds=Re(["a","abbr","acronym","address","area","article","aside","audio","b","bdi","bdo","big","blink","blockquote","body","br","button","canvas","caption","center","cite","code","col","colgroup","content","data","datalist","dd","decorator","del","details","dfn","dialog","dir","div","dl","dt","element","em","fieldset","figcaption","figure","font","footer","form","h1","h2","h3","h4","h5","h6","head","header","hgroup","hr","html","i","img","input","ins","kbd","label","legend","li","main","map","mark","marquee","menu","menuitem","meter","nav","nobr","ol","optgroup","option","output","p","picture","pre","progress","q","rp","rt","ruby","s","samp","search","section","select","shadow","slot","small","source","spacer","span","strike","strong","style","sub","summary","sup","table","tbody","td","template","textarea","tfoot","th","thead","time","tr","track","tt","u","ul","var","video","wbr"]),zr=Re(["svg","a","altglyph","altglyphdef","altglyphitem","animatecolor","animatemotion","animatetransform","circle","clippath","defs","desc","ellipse","enterkeyhint","exportparts","filter","font","g","glyph","glyphref","hkern","image","inputmode","line","lineargradient","marker","mask","metadata","mpath","part","path","pattern","polygon","polyline","radialgradient","rect","stop","style","switch","symbol","text","textpath","title","tref","tspan","view","vkern"]),Fr=Re(["feBlend","feColorMatrix","feComponentTransfer","feComposite","feConvolveMatrix","feDiffuseLighting","feDisplacementMap","feDistantLight","feDropShadow","feFlood","feFuncA","feFuncB","feFuncG","feFuncR","feGaussianBlur","feImage","feMerge","feMergeNode","feMorphology","feOffset","fePointLight","feSpecularLighting","feSpotLight","feTile","feTurbulence"]),Xh=Re(["animate","color-profile","cursor","discard","font-face","font-face-format","font-face-name","font-face-src","font-face-uri","foreignobject","hatch","hatchpath","mesh","meshgradient","meshpatch","meshrow","missing-glyph","script","set","solidcolor","unknown","use"]),jr=Re(["math","menclose","merror","mfenced","mfrac","mglyph","mi","mlabeledtr","mmultiscripts","mn","mo","mover","mpadded","mphantom","mroot","mrow","ms","mspace","msqrt","mstyle","msub","msup","msubsup","mtable","mtd","mtext","mtr","munder","munderover","mprescripts"]),Yh=Re(["maction","maligngroup","malignmark","mlongdiv","mscarries","mscarry","msgroup","mstack","msline","msrow","semantics","annotation","annotation-xml","mprescripts","none"]),ps=Re(["#text"]),ms=Re(["accept","action","align","alt","autocapitalize","autocomplete","autopictureinpicture","autoplay","background","bgcolor","border","capture","cellpadding","cellspacing","checked","cite","class","clear","color","cols","colspan","controls","controlslist","coords","crossorigin","datetime","decoding","default","dir","disabled","disablepictureinpicture","disableremoteplayback","download","draggable","enctype","enterkeyhint","exportparts","face","for","headers","height","hidden","high","href","hreflang","id","inert","inputmode","integrity","ismap","kind","label","lang","list","loading","loop","low","max","maxlength","media","method","min","minlength","multiple","muted","name","nonce","noshade","novalidate","nowrap","open","optimum","part","pattern","placeholder","playsinline","popover","popovertarget","popovertargetaction","poster","preload","pubdate","radiogroup","readonly","rel","required","rev","reversed","role","rows","rowspan","spellcheck","scope","selected","shape","size","sizes","slot","span","srclang","start","src","srcset","step","style","summary","tabindex","title","translate","type","usemap","valign","value","width","wrap","xmlns","slot"]),qr=Re(["accent-height","accumulate","additive","alignment-baseline","amplitude","ascent","attributename","attributetype","azimuth","basefrequency","baseline-shift","begin","bias","by","class","clip","clippathunits","clip-path","clip-rule","color","color-interpolation","color-interpolation-filters","color-profile","color-rendering","cx","cy","d","dx","dy","diffuseconstant","direction","display","divisor","dur","edgemode","elevation","end","exponent","fill","fill-opacity","fill-rule","filter","filterunits","flood-color","flood-opacity","font-family","font-size","font-size-adjust","font-stretch","font-style","font-variant","font-weight","fx","fy","g1","g2","glyph-name","glyphref","gradientunits","gradienttransform","height","href","id","image-rendering","in","in2","intercept","k","k1","k2","k3","k4","kerning","keypoints","keysplines","keytimes","lang","lengthadjust","letter-spacing","kernelmatrix","kernelunitlength","lighting-color","local","marker-end","marker-mid","marker-start","markerheight","markerunits","markerwidth","maskcontentunits","maskunits","max","mask","mask-type","media","method","mode","min","name","numoctaves","offset","operator","opacity","order","orient","orientation","origin","overflow","paint-order","path","pathlength","patterncontentunits","patterntransform","patternunits","points","preservealpha","preserveaspectratio","primitiveunits","r","rx","ry","radius","refx","refy","repeatcount","repeatdur","restart","result","rotate","scale","seed","shape-rendering","slope","specularconstant","specularexponent","spreadmethod","startoffset","stddeviation","stitchtiles","stop-color","stop-opacity","stroke-dasharray","stroke-dashoffset","stroke-linecap","stroke-linejoin","stroke-miterlimit","stroke-opacity","stroke","stroke-width","style","surfacescale","systemlanguage","tabindex","tablevalues","targetx","targety","transform","transform-origin","text-anchor","text-decoration","text-rendering","textlength","type","u1","u2","unicode","values","viewbox","visibility","version","vert-adv-y","vert-origin-x","vert-origin-y","width","word-spacing","wrap","writing-mode","xchannelselector","ychannelselector","x","x1","x2","xmlns","y","y1","y2","z","zoomandpan"]),fs=Re(["accent","accentunder","align","bevelled","close","columnsalign","columnlines","columnspan","denomalign","depth","dir","display","displaystyle","encoding","fence","frame","height","href","id","largeop","length","linethickness","lspace","lquote","mathbackground","mathcolor","mathsize","mathvariant","maxsize","minsize","movablelimits","notation","numalign","open","rowalign","rowlines","rowspacing","rowspan","rspace","rquote","scriptlevel","scriptminsize","scriptsizemultiplier","selection","separator","separators","stretchy","subscriptshift","supscriptshift","symmetric","voffset","width","xmlns"]),$n=Re(["xlink:href","xml:id","xlink:title","xml:space","xmlns:xlink"]),Qh=ze(/\{\{[\w\W]*|[\w\W]*\}\}/gm),Jh=ze(/<%[\w\W]*|[\w\W]*%>/gm),Zh=ze(/\$\{[\w\W]*/gm),eg=ze(/^data-[\-\w.\u00B7-\uFFFF]+$/),tg=ze(/^aria-[\-\w]+$/),il=ze(/^(?:(?:(?:f|ht)tps?|mailto|tel|callto|sms|cid|xmpp|matrix):|[^a-z]|[a-z+.\-]+(?:[^a-z+.\-:]|$))/i),ng=ze(/^(?:\w+script|data):/i),rg=ze(/[\u0000-\u0020\u00A0\u1680\u180E\u2000-\u2029\u205F\u3000]/g),ol=ze(/^html$/i),ig=ze(/^[a-z][.\w]*(-[.\w]+)+$/i);var hs=Object.freeze({__proto__:null,ARIA_ATTR:tg,ATTR_WHITESPACE:rg,CUSTOM_ELEMENT:ig,DATA_ATTR:eg,DOCTYPE_NAME:ol,ERB_EXPR:Jh,IS_ALLOWED_URI:il,IS_SCRIPT_OR_DATA:ng,MUSTACHE_EXPR:Qh,TMPLIT_EXPR:Zh});const nn={element:1,text:3,progressingInstruction:7,comment:8,document:9},og=function(){return typeof window>"u"?null:window},sg=function(e,n){if(typeof e!="object"||typeof e.createPolicy!="function")return null;let r=null;const i="data-tt-policy-suffix";n&&n.hasAttribute(i)&&(r=n.getAttribute(i));const o="dompurify"+(r?"#"+r:"");try{return e.createPolicy(o,{createHTML(s){return s},createScriptURL(s){return s}})}catch{return console.warn("TrustedTypes policy "+o+" could not be created."),null}},gs=function(){return{afterSanitizeAttributes:[],afterSanitizeElements:[],afterSanitizeShadowDOM:[],beforeSanitizeAttributes:[],beforeSanitizeElements:[],beforeSanitizeShadowDOM:[],uponSanitizeAttribute:[],uponSanitizeElement:[],uponSanitizeShadowNode:[]}};function sl(){let t=arguments.length>0&&arguments[0]!==void 0?arguments[0]:og();const e=H=>sl(H);if(e.version="3.3.1",e.removed=[],!t||!t.document||t.document.nodeType!==nn.document||!t.Element)return e.isSupported=!1,e;let{document:n}=t;const r=n,i=r.currentScript,{DocumentFragment:o,HTMLTemplateElement:s,Node:l,Element:a,NodeFilter:c,NamedNodeMap:u=t.NamedNodeMap||t.MozNamedAttrMap,HTMLFormElement:d,DOMParser:h,trustedTypes:f}=t,g=a.prototype,y=tn(g,"cloneNode"),x=tn(g,"remove"),v=tn(g,"nextSibling"),k=tn(g,"childNodes"),b=tn(g,"parentNode");if(typeof s=="function"){const H=n.createElement("template");H.content&&H.content.ownerDocument&&(n=H.content.ownerDocument)}let E,P="";const{implementation:V,createNodeIterator:q,createDocumentFragment:J,getElementsByTagName:B}=n,{importNode:S}=r;let O=gs();e.isSupported=typeof rl=="function"&&typeof b=="function"&&V&&V.createHTMLDocument!==void 0;const{MUSTACHE_EXPR:N,ERB_EXPR:D,TMPLIT_EXPR:I,DATA_ATTR:z,ARIA_ATTR:W,IS_SCRIPT_OR_DATA:ee,ATTR_WHITESPACE:Z,CUSTOM_ELEMENT:oe}=hs;let{IS_ALLOWED_URI:Oe}=hs,le=null;const gr=Q({},[...ds,...zr,...Fr,...jr,...ps]);let be=null;const Yi=Q({},[...ms,...qr,...fs,...$n]);let de=Object.seal(gi(null,{tagNameCheck:{writable:!0,configurable:!1,enumerable:!0,value:null},attributeNameCheck:{writable:!0,configurable:!1,enumerable:!0,value:null},allowCustomizedBuiltInElements:{writable:!0,configurable:!1,enumerable:!0,value:!1}})),Ut=null,_r=null;const Tt=Object.seal(gi(null,{tagCheck:{writable:!0,configurable:!1,enumerable:!0,value:null},attributeCheck:{writable:!0,configurable:!1,enumerable:!0,value:null}}));let Qi=!0,yr=!0,Ji=!1,Zi=!0,At=!1,wn=!0,ft=!1,vr=!1,br=!1,St=!1,xn=!1,En=!1,eo=!0,to=!1;const cl="user-content-";let kr=!0,Wt=!1,Rt={},We=null;const wr=Q({},["annotation-xml","audio","colgroup","desc","foreignobject","head","iframe","math","mi","mn","mo","ms","mtext","noembed","noframes","noscript","plaintext","script","style","svg","template","thead","title","video","xmp"]);let no=null;const ro=Q({},["audio","video","img","source","image","track"]);let xr=null;const io=Q({},["alt","class","for","id","label","name","pattern","placeholder","role","summary","title","value","style","xmlns"]),Tn="http://www.w3.org/1998/Math/MathML",An="http://www.w3.org/2000/svg",it="http://www.w3.org/1999/xhtml";let Lt=it,Er=!1,Tr=null;const ul=Q({},[Tn,An,it],Vr);let Sn=Q({},["mi","mo","mn","ms","mtext"]),Rn=Q({},["annotation-xml"]);const dl=Q({},["title","style","font","a","script"]);let Kt=null;const pl=["application/xhtml+xml","text/html"],ml="text/html";let he=null,Ct=null;const fl=n.createElement("form"),oo=function(_){return _ instanceof RegExp||_ instanceof Function},Ar=function(){let _=arguments.length>0&&arguments[0]!==void 0?arguments[0]:{};if(!(Ct&&Ct===_)){if((!_||typeof _!="object")&&(_={}),_=Je(_),Kt=pl.indexOf(_.PARSER_MEDIA_TYPE)===-1?ml:_.PARSER_MEDIA_TYPE,he=Kt==="application/xhtml+xml"?Vr:zn,le=Fe(_,"ALLOWED_TAGS")?Q({},_.ALLOWED_TAGS,he):gr,be=Fe(_,"ALLOWED_ATTR")?Q({},_.ALLOWED_ATTR,he):Yi,Tr=Fe(_,"ALLOWED_NAMESPACES")?Q({},_.ALLOWED_NAMESPACES,Vr):ul,xr=Fe(_,"ADD_URI_SAFE_ATTR")?Q(Je(io),_.ADD_URI_SAFE_ATTR,he):io,no=Fe(_,"ADD_DATA_URI_TAGS")?Q(Je(ro),_.ADD_DATA_URI_TAGS,he):ro,We=Fe(_,"FORBID_CONTENTS")?Q({},_.FORBID_CONTENTS,he):wr,Ut=Fe(_,"FORBID_TAGS")?Q({},_.FORBID_TAGS,he):Je({}),_r=Fe(_,"FORBID_ATTR")?Q({},_.FORBID_ATTR,he):Je({}),Rt=Fe(_,"USE_PROFILES")?_.USE_PROFILES:!1,Qi=_.ALLOW_ARIA_ATTR!==!1,yr=_.ALLOW_DATA_ATTR!==!1,Ji=_.ALLOW_UNKNOWN_PROTOCOLS||!1,Zi=_.ALLOW_SELF_CLOSE_IN_ATTR!==!1,At=_.SAFE_FOR_TEMPLATES||!1,wn=_.SAFE_FOR_XML!==!1,ft=_.WHOLE_DOCUMENT||!1,St=_.RETURN_DOM||!1,xn=_.RETURN_DOM_FRAGMENT||!1,En=_.RETURN_TRUSTED_TYPE||!1,br=_.FORCE_BODY||!1,eo=_.SANITIZE_DOM!==!1,to=_.SANITIZE_NAMED_PROPS||!1,kr=_.KEEP_CONTENT!==!1,Wt=_.IN_PLACE||!1,Oe=_.ALLOWED_URI_REGEXP||il,Lt=_.NAMESPACE||it,Sn=_.MATHML_TEXT_INTEGRATION_POINTS||Sn,Rn=_.HTML_INTEGRATION_POINTS||Rn,de=_.CUSTOM_ELEMENT_HANDLING||{},_.CUSTOM_ELEMENT_HANDLING&&oo(_.CUSTOM_ELEMENT_HANDLING.tagNameCheck)&&(de.tagNameCheck=_.CUSTOM_ELEMENT_HANDLING.tagNameCheck),_.CUSTOM_ELEMENT_HANDLING&&oo(_.CUSTOM_ELEMENT_HANDLING.attributeNameCheck)&&(de.attributeNameCheck=_.CUSTOM_ELEMENT_HANDLING.attributeNameCheck),_.CUSTOM_ELEMENT_HANDLING&&typeof _.CUSTOM_ELEMENT_HANDLING.allowCustomizedBuiltInElements=="boolean"&&(de.allowCustomizedBuiltInElements=_.CUSTOM_ELEMENT_HANDLING.allowCustomizedBuiltInElements),At&&(yr=!1),xn&&(St=!0),Rt&&(le=Q({},ps),be=[],Rt.html===!0&&(Q(le,ds),Q(be,ms)),Rt.svg===!0&&(Q(le,zr),Q(be,qr),Q(be,$n)),Rt.svgFilters===!0&&(Q(le,Fr),Q(be,qr),Q(be,$n)),Rt.mathMl===!0&&(Q(le,jr),Q(be,fs),Q(be,$n))),_.ADD_TAGS&&(typeof _.ADD_TAGS=="function"?Tt.tagCheck=_.ADD_TAGS:(le===gr&&(le=Je(le)),Q(le,_.ADD_TAGS,he))),_.ADD_ATTR&&(typeof _.ADD_ATTR=="function"?Tt.attributeCheck=_.ADD_ATTR:(be===Yi&&(be=Je(be)),Q(be,_.ADD_ATTR,he))),_.ADD_URI_SAFE_ATTR&&Q(xr,_.ADD_URI_SAFE_ATTR,he),_.FORBID_CONTENTS&&(We===wr&&(We=Je(We)),Q(We,_.FORBID_CONTENTS,he)),_.ADD_FORBID_CONTENTS&&(We===wr&&(We=Je(We)),Q(We,_.ADD_FORBID_CONTENTS,he)),kr&&(le["#text"]=!0),ft&&Q(le,["html","head","body"]),le.table&&(Q(le,["tbody"]),delete Ut.tbody),_.TRUSTED_TYPES_POLICY){if(typeof _.TRUSTED_TYPES_POLICY.createHTML!="function")throw en('TRUSTED_TYPES_POLICY configuration option must provide a "createHTML" hook.');if(typeof _.TRUSTED_TYPES_POLICY.createScriptURL!="function")throw en('TRUSTED_TYPES_POLICY configuration option must provide a "createScriptURL" hook.');E=_.TRUSTED_TYPES_POLICY,P=E.createHTML("")}else E===void 0&&(E=sg(f,i)),E!==null&&typeof P=="string"&&(P=E.createHTML(""));Re&&Re(_),Ct=_}},so=Q({},[...zr,...Fr,...Xh]),ao=Q({},[...jr,...Yh]),hl=function(_){let C=b(_);(!C||!C.tagName)&&(C={namespaceURI:Lt,tagName:"template"});const F=zn(_.tagName),ce=zn(C.tagName);return Tr[_.namespaceURI]?_.namespaceURI===An?C.namespaceURI===it?F==="svg":C.namespaceURI===Tn?F==="svg"&&(ce==="annotation-xml"||Sn[ce]):!!so[F]:_.namespaceURI===Tn?C.namespaceURI===it?F==="math":C.namespaceURI===An?F==="math"&&Rn[ce]:!!ao[F]:_.namespaceURI===it?C.namespaceURI===An&&!Rn[ce]||C.namespaceURI===Tn&&!Sn[ce]?!1:!ao[F]&&(dl[F]||!so[F]):!!(Kt==="application/xhtml+xml"&&Tr[_.namespaceURI]):!1},Ke=function(_){Jt(e.removed,{element:_});try{b(_).removeChild(_)}catch{x(_)}},ht=function(_,C){try{Jt(e.removed,{attribute:C.getAttributeNode(_),from:C})}catch{Jt(e.removed,{attribute:null,from:C})}if(C.removeAttribute(_),_==="is")if(St||xn)try{Ke(C)}catch{}else try{C.setAttribute(_,"")}catch{}},lo=function(_){let C=null,F=null;if(br)_="<remove></remove>"+_;else{const pe=Br(_,/^[\r\n\t ]+/);F=pe&&pe[0]}Kt==="application/xhtml+xml"&&Lt===it&&(_='<html xmlns="http://www.w3.org/1999/xhtml"><head></head><body>'+_+"</body></html>");const ce=E?E.createHTML(_):_;if(Lt===it)try{C=new h().parseFromString(ce,Kt)}catch{}if(!C||!C.documentElement){C=V.createDocument(Lt,"template",null);try{C.documentElement.innerHTML=Er?P:ce}catch{}}const we=C.body||C.documentElement;return _&&F&&we.insertBefore(n.createTextNode(F),we.childNodes[0]||null),Lt===it?B.call(C,ft?"html":"body")[0]:ft?C.documentElement:we},co=function(_){return q.call(_.ownerDocument||_,_,c.SHOW_ELEMENT|c.SHOW_COMMENT|c.SHOW_TEXT|c.SHOW_PROCESSING_INSTRUCTION|c.SHOW_CDATA_SECTION,null)},Sr=function(_){return _ instanceof d&&(typeof _.nodeName!="string"||typeof _.textContent!="string"||typeof _.removeChild!="function"||!(_.attributes instanceof u)||typeof _.removeAttribute!="function"||typeof _.setAttribute!="function"||typeof _.namespaceURI!="string"||typeof _.insertBefore!="function"||typeof _.hasChildNodes!="function")},uo=function(_){return typeof l=="function"&&_ instanceof l};function ot(H,_,C){Mn(H,F=>{F.call(e,_,C,Ct)})}const po=function(_){let C=null;if(ot(O.beforeSanitizeElements,_,null),Sr(_))return Ke(_),!0;const F=he(_.nodeName);if(ot(O.uponSanitizeElement,_,{tagName:F,allowedTags:le}),wn&&_.hasChildNodes()&&!uo(_.firstElementChild)&&Ae(/<[/\w!]/g,_.innerHTML)&&Ae(/<[/\w!]/g,_.textContent)||_.nodeType===nn.progressingInstruction||wn&&_.nodeType===nn.comment&&Ae(/<[/\w]/g,_.data))return Ke(_),!0;if(!(Tt.tagCheck instanceof Function&&Tt.tagCheck(F))&&(!le[F]||Ut[F])){if(!Ut[F]&&fo(F)&&(de.tagNameCheck instanceof RegExp&&Ae(de.tagNameCheck,F)||de.tagNameCheck instanceof Function&&de.tagNameCheck(F)))return!1;if(kr&&!We[F]){const ce=b(_)||_.parentNode,we=k(_)||_.childNodes;if(we&&ce){const pe=we.length;for(let Ie=pe-1;Ie>=0;--Ie){const st=y(we[Ie],!0);st.__removalCount=(_.__removalCount||0)+1,ce.insertBefore(st,v(_))}}}return Ke(_),!0}return _ instanceof a&&!hl(_)||(F==="noscript"||F==="noembed"||F==="noframes")&&Ae(/<\/no(script|embed|frames)/i,_.innerHTML)?(Ke(_),!0):(At&&_.nodeType===nn.text&&(C=_.textContent,Mn([N,D,I],ce=>{C=Zt(C,ce," ")}),_.textContent!==C&&(Jt(e.removed,{element:_.cloneNode()}),_.textContent=C)),ot(O.afterSanitizeElements,_,null),!1)},mo=function(_,C,F){if(eo&&(C==="id"||C==="name")&&(F in n||F in fl))return!1;if(!(yr&&!_r[C]&&Ae(z,C))){if(!(Qi&&Ae(W,C))){if(!(Tt.attributeCheck instanceof Function&&Tt.attributeCheck(C,_))){if(!be[C]||_r[C]){if(!(fo(_)&&(de.tagNameCheck instanceof RegExp&&Ae(de.tagNameCheck,_)||de.tagNameCheck instanceof Function&&de.tagNameCheck(_))&&(de.attributeNameCheck instanceof RegExp&&Ae(de.attributeNameCheck,C)||de.attributeNameCheck instanceof Function&&de.attributeNameCheck(C,_))||C==="is"&&de.allowCustomizedBuiltInElements&&(de.tagNameCheck instanceof RegExp&&Ae(de.tagNameCheck,F)||de.tagNameCheck instanceof Function&&de.tagNameCheck(F))))return!1}else if(!xr[C]){if(!Ae(Oe,Zt(F,Z,""))){if(!((C==="src"||C==="xlink:href"||C==="href")&&_!=="script"&&Gh(F,"data:")===0&&no[_])){if(!(Ji&&!Ae(ee,Zt(F,Z,"")))){if(F)return!1}}}}}}}return!0},fo=function(_){return _!=="annotation-xml"&&Br(_,oe)},ho=function(_){ot(O.beforeSanitizeAttributes,_,null);const{attributes:C}=_;if(!C||Sr(_))return;const F={attrName:"",attrValue:"",keepAttr:!0,allowedAttributes:be,forceKeepAttr:void 0};let ce=C.length;for(;ce--;){const we=C[ce],{name:pe,namespaceURI:Ie,value:st}=we,Pt=he(pe),Rr=st;let ke=pe==="value"?Rr:Uh(Rr);if(F.attrName=Pt,F.attrValue=ke,F.keepAttr=!0,F.forceKeepAttr=void 0,ot(O.uponSanitizeAttribute,_,F),ke=F.attrValue,to&&(Pt==="id"||Pt==="name")&&(ht(pe,_),ke=cl+ke),wn&&Ae(/((--!?|])>)|<\/(style|title|textarea)/i,ke)){ht(pe,_);continue}if(Pt==="attributename"&&Br(ke,"href")){ht(pe,_);continue}if(F.forceKeepAttr)continue;if(!F.keepAttr){ht(pe,_);continue}if(!Zi&&Ae(/\/>/i,ke)){ht(pe,_);continue}At&&Mn([N,D,I],_o=>{ke=Zt(ke,_o," ")});const go=he(_.nodeName);if(!mo(go,Pt,ke)){ht(pe,_);continue}if(E&&typeof f=="object"&&typeof f.getAttributeType=="function"&&!Ie)switch(f.getAttributeType(go,Pt)){case"TrustedHTML":{ke=E.createHTML(ke);break}case"TrustedScriptURL":{ke=E.createScriptURL(ke);break}}if(ke!==Rr)try{Ie?_.setAttributeNS(Ie,pe,ke):_.setAttribute(pe,ke),Sr(_)?Ke(_):us(e.removed)}catch{ht(pe,_)}}ot(O.afterSanitizeAttributes,_,null)},gl=function H(_){let C=null;const F=co(_);for(ot(O.beforeSanitizeShadowDOM,_,null);C=F.nextNode();)ot(O.uponSanitizeShadowNode,C,null),po(C),ho(C),C.content instanceof o&&H(C.content);ot(O.afterSanitizeShadowDOM,_,null)};return e.sanitize=function(H){let _=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{},C=null,F=null,ce=null,we=null;if(Er=!H,Er&&(H="<!-->"),typeof H!="string"&&!uo(H))if(typeof H.toString=="function"){if(H=H.toString(),typeof H!="string")throw en("dirty is not a string, aborting")}else throw en("toString is not a function");if(!e.isSupported)return H;if(vr||Ar(_),e.removed=[],typeof H=="string"&&(Wt=!1),Wt){if(H.nodeName){const st=he(H.nodeName);if(!le[st]||Ut[st])throw en("root node is forbidden and cannot be sanitized in-place")}}else if(H instanceof l)C=lo("<!---->"),F=C.ownerDocument.importNode(H,!0),F.nodeType===nn.element&&F.nodeName==="BODY"||F.nodeName==="HTML"?C=F:C.appendChild(F);else{if(!St&&!At&&!ft&&H.indexOf("<")===-1)return E&&En?E.createHTML(H):H;if(C=lo(H),!C)return St?null:En?P:""}C&&br&&Ke(C.firstChild);const pe=co(Wt?H:C);for(;ce=pe.nextNode();)po(ce),ho(ce),ce.content instanceof o&&gl(ce.content);if(Wt)return H;if(St){if(xn)for(we=J.call(C.ownerDocument);C.firstChild;)we.appendChild(C.firstChild);else we=C;return(be.shadowroot||be.shadowrootmode)&&(we=S.call(r,we,!0)),we}let Ie=ft?C.outerHTML:C.innerHTML;return ft&&le["!doctype"]&&C.ownerDocument&&C.ownerDocument.doctype&&C.ownerDocument.doctype.name&&Ae(ol,C.ownerDocument.doctype.name)&&(Ie="<!DOCTYPE "+C.ownerDocument.doctype.name+`>
72
- `+Ie),At&&Mn([N,D,I],st=>{Ie=Zt(Ie,st," ")}),E&&En?E.createHTML(Ie):Ie},e.setConfig=function(){let H=arguments.length>0&&arguments[0]!==void 0?arguments[0]:{};Ar(H),vr=!0},e.clearConfig=function(){Ct=null,vr=!1},e.isValidAttribute=function(H,_,C){Ct||Ar({});const F=he(H),ce=he(_);return mo(F,ce,C)},e.addHook=function(H,_){typeof _=="function"&&Jt(O[H],_)},e.removeHook=function(H,_){if(_!==void 0){const C=qh(O[H],_);return C===-1?void 0:Hh(O[H],C,1)[0]}return us(O[H])},e.removeHooks=function(H){O[H]=[]},e.removeAllHooks=function(){O=gs()},e}var ag=sl();const lg={class:"prd-viewer"},cg={key:0,class:"flex items-center justify-center py-8"},ug=["innerHTML"],dg=U({__name:"Viewer",props:{content:{}},setup(t){const e=t,n=j(""),r=j(!0),i={ADD_TAGS:["style"],ADD_ATTR:["style","class","target","rel"]},o=new ie.Renderer;o.link=({href:c,title:u,text:d})=>{const h=u?` title="${u}"`:"";return`<a href="${c}"${h} target="_blank" rel="noopener noreferrer">${d}</a>`};async function s(c,u){try{return await Bh(c,{lang:u||"text",themes:{light:"github-light",dark:"github-dark"}})}catch{return`<pre><code class="language-${u}">${l(c)}</code></pre>`}}function l(c){return c.replace(/&/g,"&amp;").replace(/</g,"&lt;").replace(/>/g,"&gt;").replace(/"/g,"&quot;").replace(/'/g,"&#039;")}async function a(c){const u=/```(\w*)\n([\s\S]*?)```/g,d=[];let h=0;const f=c.replace(u,(v,k,b)=>{const E=`CODEBLOCK${h++}PLACEHOLDER`;return d.push({placeholder:E,lang:k||"text",code:b.trim()}),E});ie.setOptions({renderer:o,gfm:!0,breaks:!0});let g=await ie.parse(f);const y=d.map(async({placeholder:v,lang:k,code:b})=>{const E=await s(b,k);return{placeholder:v,highlighted:E}}),x=await Promise.all(y);for(const{placeholder:v,highlighted:k}of x)g=g.replace(`<p>${v}</p>`,k),g=g.replace(v,k);return ag.sanitize(g,i)}return Te(()=>e.content,async c=>{if(c){r.value=!0;try{n.value=await a(c)}finally{r.value=!1}}},{immediate:!0}),(c,u)=>(w(),A("div",lg,[m(r)?(w(),A("div",cg,[...u[0]||(u[0]=[T("div",{class:"size-6 animate-spin rounded-full border-2 border-primary border-t-transparent"},null,-1)])])):(w(),A("div",{key:1,class:"prose prose-sm dark:prose-invert max-w-none",innerHTML:m(n)},null,8,ug))]))}}),pg=Object.assign(dg,{__name:"PrdViewer"}),mg=U({__name:"Card",props:{class:{}},setup(t){const e=t;return(n,r)=>(w(),A("div",{"data-slot":"card",class:ue(m(Ve)("bg-card text-card-foreground flex flex-col gap-6 rounded-xl border py-6 shadow-sm",e.class))},[ne(n.$slots,"default")],2))}}),fg=Object.assign(mg,{__name:"UiCard"}),hg=U({__name:"CardAction",props:{class:{}},setup(t){const e=t;return(n,r)=>(w(),A("div",{"data-slot":"card-action",class:ue(m(Ve)("col-start-2 row-span-2 row-start-1 self-start justify-self-end",e.class))},[ne(n.$slots,"default")],2))}});Object.assign(hg,{__name:"UiCardAction"});const gg=U({__name:"CardContent",props:{class:{}},setup(t){const e=t;return(n,r)=>(w(),A("div",{"data-slot":"card-content",class:ue(m(Ve)("px-6",e.class))},[ne(n.$slots,"default")],2))}}),_g=Object.assign(gg,{__name:"UiCardContent"}),yg=U({__name:"CardDescription",props:{class:{}},setup(t){const e=t;return(n,r)=>(w(),A("p",{"data-slot":"card-description",class:ue(m(Ve)("text-muted-foreground text-sm",e.class))},[ne(n.$slots,"default")],2))}});Object.assign(yg,{__name:"UiCardDescription"});const vg=U({__name:"CardFooter",props:{class:{}},setup(t){const e=t;return(n,r)=>(w(),A("div",{"data-slot":"card-footer",class:ue(m(Ve)("flex items-center px-6 [.border-t]:pt-6",e.class))},[ne(n.$slots,"default")],2))}});Object.assign(vg,{__name:"UiCardFooter"});const bg=U({__name:"CardHeader",props:{class:{}},setup(t){const e=t;return(n,r)=>(w(),A("div",{"data-slot":"card-header",class:ue(m(Ve)("@container/card-header grid auto-rows-min grid-rows-[auto_auto] items-start gap-1.5 px-6 has-data-[slot=card-action]:grid-cols-[1fr_auto] [.border-b]:pb-6",e.class))},[ne(n.$slots,"default")],2))}});Object.assign(bg,{__name:"UiCardHeader"});const kg=U({__name:"CardTitle",props:{class:{}},setup(t){const e=t;return(n,r)=>(w(),A("h3",{"data-slot":"card-title",class:ue(m(Ve)("leading-none font-semibold",e.class))},[ne(n.$slots,"default")],2))}});Object.assign(kg,{__name:"UiCardTitle"});const wg={class:"flex items-center justify-between gap-2 mb-1.5"},xg={class:"text-sm font-medium leading-snug"},Eg={class:"text-muted-foreground"},Tg={key:0,class:"mt-2 flex items-center gap-1.5 text-xs text-destructive"},Ag=U({__name:"Card",props:{task:{},blockedBy:{}},emits:["click"],setup(t,{emit:e}){const n=t,r=e,i=$(()=>{switch(n.task.category){case"setup":return{label:"Setup",variant:"secondary"};case"feature":return{label:"Feature",variant:"default"};case"integration":return{label:"Integration",variant:"outline"};case"testing":return{label:"Testing",variant:"secondary"};case"documentation":return{label:"Docs",variant:"secondary"};default:return{label:n.task.category,variant:"secondary"}}}),o=$(()=>{switch(n.task.priority){case"critical":return{icon:yo,class:"text-destructive",label:"Critical"};case"high":return{icon:yo,class:"text-orange-500",label:"High"};case"medium":return{icon:Kr,class:"text-muted-foreground",label:"Medium"};case"low":return{icon:rc,class:"text-muted-foreground",label:"Low"};default:return{icon:Kr,class:"text-muted-foreground",label:"Unknown"}}}),s=$(()=>n.blockedBy&&n.blockedBy.length>0),l=$(()=>{const d=n.task.id.match(/(\d+)$/)?.[1];return d?parseInt(d,10):0}),a=$(()=>n.blockedBy?.length??0);function c(){r("click",n.task)}return(u,d)=>(w(),K(m(fg),{class:ue(["cursor-pointer py-0 gap-0 transition-all hover:shadow-md hover:border-primary/50",{"opacity-60":m(s)}]),onClick:c},{default:M(()=>[R(m(_g),{class:"p-2.5"},{default:M(()=>[T("div",wg,[R(m(Nt),{variant:m(i).variant,class:"text-xs"},{default:M(()=>[re(G(m(i).label),1)]),_:1},8,["variant"]),(w(),K(kt(m(o).icon),{class:ue(["size-4",m(o).class]),title:m(o).label},null,8,["class","title"]))]),T("h4",xg,[T("span",Eg,"#"+G(m(l)),1),re(" "+G(t.task.title),1)]),m(s)?(w(),A("div",Tg,[R(m(cn),{class:"size-3.5"}),T("span",null,"Blocked by "+G(m(a))+" task"+G(m(a)===1?"":"s"),1)])):Y("",!0)]),_:1})]),_:1},8,["class"]))}}),Sg=Object.assign(Ag,{__name:"TasksCard"}),Rg={class:"flex h-full min-w-56 flex-1 flex-col overflow-hidden rounded-lg border border-border bg-card"},Lg={class:"text-sm font-medium"},Cg={class:"ml-auto text-xs text-muted-foreground"},Pg={class:"scrollbar-hide min-h-0 flex-1 overflow-y-auto p-1.5"},Og={class:"space-y-1.5"},Ig={key:0,class:"py-8 text-center text-sm text-muted-foreground"},Dg=U({__name:"Column",props:{status:{},tasks:{},blockedByMap:{}},emits:["taskClick"],setup(t,{emit:e}){const n=t,r=e,i=$(()=>{switch(n.status){case"pending":return{label:"Pending",icon:an,headerClass:"bg-muted/50",iconClass:"text-muted-foreground"};case"in_progress":return{label:"In Progress",icon:sc,headerClass:"bg-blue-500/10",iconClass:"text-blue-500"};case"completed":return{label:"Completed",icon:Wr,headerClass:"bg-green-500/10",iconClass:"text-green-500"};default:return{label:n.status,icon:an,headerClass:"bg-muted/50",iconClass:"text-muted-foreground"}}});function o(l){return n.blockedByMap?.get(l)??[]}function s(l){r("taskClick",l)}return(l,a)=>{const c=Sg;return w(),A("div",Rg,[T("div",{class:ue(["flex items-center gap-2 rounded-t-lg border-b border-border px-3 py-2",m(i).headerClass])},[(w(),K(kt(m(i).icon),{class:ue(["size-4",m(i).iconClass])},null,8,["class"])),T("h3",Lg,G(m(i).label),1),T("span",Cg,G(t.tasks.length),1)],2),T("div",Pg,[T("div",Og,[(w(!0),A(ve,null,He(t.tasks,u=>(w(),K(c,{key:u.id,task:u,"blocked-by":o(u.id),onClick:s},null,8,["task","blocked-by"]))),128)),t.tasks.length===0?(w(),A("div",Ig," No tasks ")):Y("",!0)])])])}}}),Ng=Object.assign($s(Dg,[["__scopeId","data-v-a1317eba"]]),{__name:"TasksColumn"}),Mg={class:"flex h-full gap-3 overflow-x-auto pb-2"},$g=U({__name:"Board",props:{tasks:{}},emits:["taskClick"],setup(t,{emit:e}){const n=t,r=e;function i(d){const f=d.id.match(/(\d+)$/)?.[1];return f?parseInt(f,10):0}const o=$(()=>n.tasks.filter(d=>d.status==="pending").sort((d,h)=>i(d)-i(h))),s=$(()=>n.tasks.filter(d=>d.status==="in_progress").sort((d,h)=>i(d)-i(h))),l=$(()=>n.tasks.filter(d=>d.status==="completed").sort((d,h)=>{const f=d.completedAt?new Date(d.completedAt).getTime():0;return(h.completedAt?new Date(h.completedAt).getTime():0)-f})),a=$(()=>{const d=new Map,h=new Set(l.value.map(f=>f.id));for(const f of n.tasks)if(f.dependencies.length>0){const g=f.dependencies.filter(y=>!h.has(y));g.length>0&&d.set(f.id,g)}return d}),c=[{status:"pending",tasks:o},{status:"in_progress",tasks:s},{status:"completed",tasks:l}];function u(d){r("taskClick",d)}return(d,h)=>{const f=Ng;return w(),A("div",Mg,[(w(),A(ve,null,He(c,g=>R(f,{key:g.status,status:g.status,tasks:g.tasks.value,"blocked-by-map":m(a),onTaskClick:u},null,8,["status","tasks","blocked-by-map"])),64))])}}}),Vg=Object.assign($g,{__name:"TasksBoard"}),Bg={class:"space-y-0.5 p-2"},zg=["onClick"],Fg={class:"min-w-0 flex-1"},jg=["title"],qg={class:"text-muted-foreground"},Hg={class:"mt-1 flex h-1.5 w-full overflow-hidden rounded-full bg-muted"},Gg={class:"flex shrink-0 items-center gap-1 text-xs"},Ug={key:0,class:"text-green-600 dark:text-green-400"},Wg={key:1,class:"text-red-600 dark:text-red-400"},Kg={key:0,class:"py-4 text-center text-sm text-muted-foreground"},Xg=U({__name:"ChangesMinimap",props:{files:{},selectedFile:{}},emits:["select"],setup(t,{emit:e}){const n=t,r=e,i=$(()=>n.files.length===0?1:Math.max(...n.files.map(u=>u.additions+u.deletions),1));function o(u){switch(u){case"added":return{icon:mc,class:"text-green-600 dark:text-green-400"};case"deleted":return{icon:fc,class:"text-red-600 dark:text-red-400"};case"renamed":return{icon:wo,class:"text-blue-600 dark:text-blue-400"};default:return{icon:pc,class:"text-yellow-600 dark:text-yellow-400"}}}function s(u){const d=u.additions+u.deletions;if(d===0)return{additions:0,deletions:0,total:0};const h=d/i.value*100,f=u.additions/d*h,g=u.deletions/d*h;return{additions:f,deletions:g,total:h}}function l(u){return u.status==="renamed"&&u.oldPath?`${u.oldPath} → ${u.path}`:u.path}function a(u){return u.split("/").pop()||u}function c(u){r("select",u)}return(u,d)=>(w(),A("div",Bg,[(w(!0),A(ve,null,He(t.files,h=>(w(),A("button",{key:h.path,class:ue(["group flex w-full items-center gap-2 rounded px-2 py-1.5 text-left text-sm transition-colors hover:bg-muted/50",{"bg-muted":t.selectedFile===h.path}]),onClick:f=>c(h.path)},[(w(),K(kt(o(h.status).icon),{class:ue(["size-4 shrink-0",o(h.status).class])},null,8,["class"])),T("div",Fg,[T("div",{class:ue(["truncate text-xs",{"font-medium":t.selectedFile===h.path}]),title:l(h)},[h.status==="renamed"&&h.oldPath?(w(),A(ve,{key:0},[T("span",qg,G(a(h.oldPath)),1),R(m(wo),{class:"mx-1 inline size-3 text-muted-foreground"}),T("span",null,G(a(h.path)),1)],64)):(w(),A(ve,{key:1},[re(G(h.path),1)],64))],10,jg),T("div",Hg,[s(h).additions>0?(w(),A("div",{key:0,class:"bg-green-500 dark:bg-green-400",style:un({width:`${s(h).additions}%`})},null,4)):Y("",!0),s(h).deletions>0?(w(),A("div",{key:1,class:"bg-red-500 dark:bg-red-400",style:un({width:`${s(h).deletions}%`})},null,4)):Y("",!0)])]),T("div",Gg,[h.additions>0?(w(),A("span",Ug," +"+G(h.additions),1)):Y("",!0),h.deletions>0?(w(),A("span",Wg," -"+G(h.deletions),1)):Y("",!0)])],10,zg))),128)),t.files.length===0?(w(),A("div",Kg," No files changed ")):Y("",!0)]))}}),Yg=Object.assign(Xg,{__name:"GitChangesMinimap"}),al=[{id:"angular-html",name:"Angular HTML",import:(()=>p(()=>import("./DxNHbxmM.js").then(t=>t.f),__vite__mapDeps([0,1,2,3]),import.meta.url))},{id:"angular-ts",name:"Angular TypeScript",import:(()=>p(()=>import("./Cl0AqbOI.js"),__vite__mapDeps([4,0,1,2,3,5]),import.meta.url))},{id:"astro",name:"Astro",import:(()=>p(()=>import("./DxSwrfjg.js"),__vite__mapDeps([10,9,2,11,3,12,13]),import.meta.url))},{id:"blade",name:"Blade",import:(()=>p(()=>import("./5X7smno1.js"),__vite__mapDeps([14,15,1,2,3,7,8,16,9]),import.meta.url))},{id:"c",name:"C",import:(()=>p(()=>import("./BIGW1oBm.js"),[],import.meta.url))},{id:"coffee",name:"CoffeeScript",aliases:["coffeescript"],import:(()=>p(()=>import("./CxbxFI8M.js"),__vite__mapDeps([22,2]),import.meta.url))},{id:"cpp",name:"C++",aliases:["c++"],import:(()=>p(()=>import("./Bp3cYrEr.js"),__vite__mapDeps([23,24,25,26,16]),import.meta.url))},{id:"css",name:"CSS",import:(()=>p(()=>import("./DPfMkruS.js"),[],import.meta.url))},{id:"csv",name:"CSV",import:(()=>p(()=>import("./fuZLfV_i.js"),[],import.meta.url))},{id:"glsl",name:"GLSL",import:(()=>p(()=>import("./DZxFcAj9.js"),__vite__mapDeps([25,26]),import.meta.url))},{id:"graphql",name:"GraphQL",aliases:["gql"],import:(()=>p(()=>import("./C9oPPf7i.js"),__vite__mapDeps([35,2,11,36,13]),import.meta.url))},{id:"haml",name:"Ruby Haml",import:(()=>p(()=>import("./CmIQRyeF.js"),__vite__mapDeps([34,2,3]),import.meta.url))},{id:"handlebars",name:"Handlebars",aliases:["hbs"],import:(()=>p(()=>import("./m17aaUwq.js"),__vite__mapDeps([53,1,2,3,38]),import.meta.url))},{id:"html",name:"HTML",import:(()=>p(()=>import("./CnnebwVN.js"),__vite__mapDeps([1,2,3]),import.meta.url))},{id:"html-derivative",name:"HTML (Derivative)",import:(()=>p(()=>import("./DGP4VlC8.js"),__vite__mapDeps([15,1,2,3]),import.meta.url))},{id:"http",name:"HTTP",import:(()=>p(()=>import("./CufHLc7y.js"),__vite__mapDeps([54,28,9,7,8,35,2,11,36,13]),import.meta.url))},{id:"hurl",name:"Hurl",import:(()=>p(()=>import("./CYsAdtH9.js"),__vite__mapDeps([55,35,2,11,36,13,7,8,56]),import.meta.url))},{id:"imba",name:"Imba",import:(()=>p(()=>import("./DGztddWO.js"),[],import.meta.url))},{id:"java",name:"Java",import:(()=>p(()=>import("./CylS5w8V.js"),[],import.meta.url))},{id:"javascript",name:"JavaScript",aliases:["js","cjs","mjs"],import:(()=>p(()=>import("./wDzz0qaB.js"),[],import.meta.url))},{id:"jinja",name:"Jinja",import:(()=>p(()=>import("./CXZktZb0.js"),__vite__mapDeps([59,1,2,3]),import.meta.url))},{id:"jison",name:"Jison",import:(()=>p(()=>import("./Br6cN0cg.js"),__vite__mapDeps([60,2]),import.meta.url))},{id:"json",name:"JSON",import:(()=>p(()=>import("./Cp-IABpG.js"),[],import.meta.url))},{id:"json5",name:"JSON5",import:(()=>p(()=>import("./C9tS-k6U.js"),[],import.meta.url))},{id:"jsonc",name:"JSON with Comments",import:(()=>p(()=>import("./Des-eS-w.js"),[],import.meta.url))},{id:"jsonl",name:"JSON Lines",import:(()=>p(()=>import("./DcaNXYhu.js"),[],import.meta.url))},{id:"jsx",name:"JSX",import:(()=>p(()=>import("./g9-lgVsj.js"),[],import.meta.url))},{id:"julia",name:"Julia",aliases:["jl"],import:(()=>p(()=>import("./W9tJ9s81.js"),__vite__mapDeps([61,23,24,25,26,16,20,2,62]),import.meta.url))},{id:"less",name:"Less",import:(()=>p(()=>import("./B1dDrJ26.js"),[],import.meta.url))},{id:"markdown",name:"Markdown",aliases:["md"],import:(()=>p(()=>import("./Cvjx9yec.js"),[],import.meta.url))},{id:"marko",name:"Marko",import:(()=>p(()=>import("./83L43bj1.js"),__vite__mapDeps([66,3,67,5,11]),import.meta.url))},{id:"mdc",name:"MDC",import:(()=>p(()=>import("./TsXTqZ29.js"),__vite__mapDeps([68,40,38,15,1,2,3]),import.meta.url))},{id:"mdx",name:"MDX",import:(()=>p(()=>import("./Cmh6b_Ma.js"),[],import.meta.url))},{id:"php",name:"PHP",import:(()=>p(()=>import("./DJjDtW9f.js"),__vite__mapDeps([72,1,2,3,7,8,16,9]),import.meta.url))},{id:"postcss",name:"PostCSS",import:(()=>p(()=>import("./CXtECtnM.js"),[],import.meta.url))},{id:"pug",name:"Pug",aliases:["jade"],import:(()=>p(()=>import("./BLmx8bSh.js"),__vite__mapDeps([73,2,3,1]),import.meta.url))},{id:"python",name:"Python",aliases:["py"],import:(()=>p(()=>import("./B6aJPvgy.js"),[],import.meta.url))},{id:"r",name:"R",import:(()=>p(()=>import("./Dspwwk_N.js"),[],import.meta.url))},{id:"regexp",name:"RegExp",aliases:["regex"],import:(()=>p(()=>import("./CDVJQ6XC.js"),[],import.meta.url))},{id:"sass",name:"Sass",import:(()=>p(()=>import("./Cj5Yp3dK.js"),[],import.meta.url))},{id:"scss",name:"SCSS",import:(()=>p(()=>import("./2EtD6e53.js"),__vite__mapDeps([5,3]),import.meta.url))},{id:"shellscript",name:"Shell",aliases:["bash","sh","shell","zsh"],import:(()=>p(()=>import("./Yzrsuije.js"),[],import.meta.url))},{id:"sql",name:"SQL",import:(()=>p(()=>import("./BLtJtn59.js"),[],import.meta.url))},{id:"stylus",name:"Stylus",aliases:["styl"],import:(()=>p(()=>import("./BEDo0Tqx.js"),[],import.meta.url))},{id:"svelte",name:"Svelte",import:(()=>p(()=>import("./DYoxhk2S.js"),__vite__mapDeps([88,2,11,3,12]),import.meta.url))},{id:"ts-tags",name:"TypeScript with Tags",aliases:["lit"],import:(()=>p(()=>import("./Cm3UrAx6.js"),__vite__mapDeps([91,11,3,2,25,26,1,16,7,8]),import.meta.url))},{id:"tsx",name:"TSX",import:(()=>p(()=>import("./COt5Ahok.js"),[],import.meta.url))},{id:"typescript",name:"TypeScript",aliases:["ts","cts","mts"],import:(()=>p(()=>import("./BPQ3VLAy.js"),[],import.meta.url))},{id:"vue",name:"Vue",import:(()=>p(()=>import("./DEthMvLe.js"),__vite__mapDeps([93,3,2,11,9,1,15]),import.meta.url))},{id:"vue-html",name:"Vue HTML",import:(()=>p(()=>import("./DqQDbK_p.js"),__vite__mapDeps([94,2]),import.meta.url))},{id:"vue-vine",name:"Vue Vine",import:(()=>p(()=>import("./CW8IKDeL.js"),__vite__mapDeps([95,3,5,67,96,12,2]),import.meta.url))},{id:"wasm",name:"WebAssembly",import:(()=>p(()=>import("./MzD3tlZU.js"),[],import.meta.url))},{id:"wgsl",name:"WGSL",import:(()=>p(()=>import("./Dx-B1_4e.js"),[],import.meta.url))},{id:"wit",name:"WebAssembly Interface Types",import:(()=>p(()=>import("./5i3qLPDT.js"),[],import.meta.url))},{id:"xml",name:"XML",import:(()=>p(()=>import("./BGJmEYvX.js"),__vite__mapDeps([7,8]),import.meta.url))},{id:"yaml",name:"YAML",aliases:["yml"],import:(()=>p(()=>import("./Buea-lGh.js"),[],import.meta.url))}],Qg=Object.fromEntries(al.map(t=>[t.id,t.import])),Jg=Object.fromEntries(al.flatMap(t=>t.aliases?.map(e=>[e,t.import])||[])),Zg={...Qg,...Jg},e_=Qa({langs:Zg,themes:el,engine:()=>nl(p(()=>import("./CG6Dc4jp.js"),[],import.meta.url))}),{codeToHtml:_s}=Ja(e_,{guessEmbeddedLanguages:Ha}),t_={class:"diff-viewer"},n_={key:0,class:"flex items-center justify-center py-8"},r_={key:1,class:"flex flex-col items-center justify-center gap-3 py-12 text-muted-foreground"},i_={key:2,class:"flex flex-col items-center justify-center gap-3 py-12 text-muted-foreground"},o_={key:3,class:"diff-container"},s_={class:"flex flex-col items-center justify-center gap-3 border-b border-border bg-muted/30 py-6"},a_={class:"text-center"},l_={class:"text-sm text-muted-foreground"},c_={key:4,class:"diff-container"},u_={class:"full-file-view"},d_={class:"diff-gutter"},p_={class:"line-number"},m_={class:"diff-content"},f_=["innerHTML"],h_={key:5,class:"diff-container"},g_={class:"diff-toolbar"},__={class:"diff-split"},y_={class:"diff-column-content"},v_={key:0,class:"diff-separator-half"},b_={class:"diff-gutter"},k_={key:0,class:"line-number"},w_={class:"diff-content"},x_=["innerHTML"],E_={class:"diff-column-content"},T_={key:0,class:"diff-separator-half"},A_={class:"diff-gutter"},S_={key:0,class:"line-number"},R_={class:"diff-content"},L_=["innerHTML"],ys=1e4,C_=U({__name:"DiffViewer",props:{hunks:{},filePath:{},binary:{type:Boolean},oldPath:{},fileContent:{},showFullFile:{type:Boolean},isLoadingContent:{type:Boolean}},setup(t){const e=t,n=j(!1),r=j(!0),i=j(null),o=j(null),s=j(!1);function l(S){if(!r.value||s.value)return;const O=S.target;o.value&&(s.value=!0,o.value.scrollLeft=O.scrollLeft,requestAnimationFrame(()=>{s.value=!1}))}function a(S){if(!r.value||s.value)return;const O=S.target;i.value&&(s.value=!0,i.value.scrollLeft=O.scrollLeft,requestAnimationFrame(()=>{s.value=!1}))}const c=$(()=>{let S=0;for(const O of e.hunks)S+=O.lines.length;return S}),u=$(()=>c.value>ys),d=$(()=>e.hunks.length===0&&!e.binary),h=$(()=>{const S=new Set,O=new Set;for(const N of e.hunks)for(const D of N.lines)D.type==="add"&&D.newNumber!==void 0&&S.add(D.newNumber),D.type==="remove"&&D.oldNumber!==void 0&&O.add(D.oldNumber);return{added:S,removed:O}}),f=$(()=>e.fileContent?e.fileContent.split(`
73
- `):[]);function g(S){const O=S.split(".").pop()?.toLowerCase()||"";return{ts:"typescript",tsx:"tsx",js:"javascript",jsx:"jsx",vue:"vue",svelte:"svelte",py:"python",rb:"ruby",rs:"rust",go:"go",java:"java",kt:"kotlin",swift:"swift",c:"c",cpp:"cpp",h:"c",hpp:"cpp",cs:"csharp",php:"php",html:"html",css:"css",scss:"scss",sass:"sass",less:"less",json:"json",yaml:"yaml",yml:"yaml",toml:"toml",xml:"xml",md:"markdown",mdx:"mdx",sh:"bash",bash:"bash",zsh:"bash",fish:"fish",ps1:"powershell",sql:"sql",graphql:"graphql",gql:"graphql",dockerfile:"dockerfile",makefile:"makefile"}[O]||"text"}const y=$(()=>g(e.filePath)),x=j(new Map),v=j(!0),k=$(()=>{const S=[];for(let O=0;O<e.hunks.length;O++){const N=e.hunks[O];O>0&&S.push({type:"separator",hunkIndex:O});const D=N.lines;let I=0;for(;I<D.length;){const z=D[I];if(z.type==="context")S.push({type:"line",pair:{id:`${O}-${I}`,left:{lineNum:z.oldNumber,content:z.content,type:"context"},right:{lineNum:z.newNumber,content:z.content,type:"context"}}}),I++;else if(z.type==="remove"){const W=[],ee=[];for(;I<D.length&&D[I].type==="remove";)W.push(D[I]),I++;for(;I<D.length&&D[I].type==="add";)ee.push(D[I]),I++;const Z=Math.max(W.length,ee.length);for(let oe=0;oe<Z;oe++){const Oe=W[oe],le=ee[oe];S.push({type:"line",pair:{id:`${O}-${I-Z+oe}`,left:Oe?{lineNum:Oe.oldNumber,content:Oe.content,type:"remove"}:{content:"",type:"empty"},right:le?{lineNum:le.newNumber,content:le.content,type:"add"}:{content:"",type:"empty"}}})}}else z.type==="add"&&S.push({type:"line",pair:{id:`${O}-${I}`,left:{content:"",type:"empty"},right:{lineNum:z.newNumber,content:z.content,type:"add"}}}),I++}}return S});async function b(S,O){if(!S.trim())return"";try{const D=(await _s(S,{lang:O,themes:{light:"catppuccin-latte",dark:"catppuccin-mocha"}})).match(/<code[^>]*>([\s\S]*?)<\/code>/);return D?D[1]||"":P(S)}catch{return P(S)}}async function E(S,O){if(!S)return[];try{const D=(await _s(S,{lang:O,themes:{light:"catppuccin-latte",dark:"catppuccin-mocha"}})).match(/<code[^>]*>([\s\S]*?)<\/code>/);return!D||!D[1]?S.split(`
74
- `).map(P):D[1].split(`
75
- `)}catch{return S.split(`
76
- `).map(P)}}function P(S){return S.replace(/&/g,"&amp;").replace(/</g,"&lt;").replace(/>/g,"&gt;").replace(/"/g,"&quot;").replace(/'/g,"&#039;")}const V=j([]),q=j(!1);Te(()=>[e.fileContent,e.filePath],async([S])=>{if(!S){V.value=[];return}q.value=!0;const O=y.value;V.value=await E(S,O),q.value=!1},{immediate:!0}),Te(()=>[e.hunks,e.filePath,V.value],async()=>{v.value=!0;const S=y.value,O=new Map,N=V.value,D=[];for(const z of k.value)if(z.type==="line"&&z.pair){if(z.pair.left.content&&z.pair.left.type!=="empty"){const W=`${z.pair.id}-old`;if(z.pair.left.type==="context"&&z.pair.left.lineNum&&N.length>0){const ee=z.pair.right.lineNum?z.pair.right.lineNum-1:-1;ee>=0&&ee<N.length?O.set(W,N[ee]||""):D.push({key:W,content:z.pair.left.content})}else D.push({key:W,content:z.pair.left.content})}if(z.pair.right.content&&z.pair.right.type!=="empty"){const W=`${z.pair.id}-new`,ee=z.pair.right.lineNum;ee&&N.length>0&&ee<=N.length?O.set(W,N[ee-1]||""):D.push({key:W,content:z.pair.right.content})}}const I=50;for(let z=0;z<D.length;z+=I){const W=D.slice(z,z+I),ee=await Promise.all(W.map(async({key:Z,content:oe})=>{const Oe=await b(oe,S);return{key:Z,result:Oe}}));for(const{key:Z,result:oe}of ee)O.set(Z,oe)}x.value=O,v.value=!1},{immediate:!0});function J(S,O){return x.value.get(`${S}-${O}`)||""}function B(S){return h.value.added.has(S)?"add":"context"}return(S,O)=>(w(),A("div",t_,[(m(v)||t.isLoadingContent||m(q))&&!t.binary?(w(),A("div",n_,[...O[2]||(O[2]=[T("div",{class:"size-6 animate-spin rounded-full border-2 border-primary border-t-transparent"},null,-1)])])):t.binary?(w(),A("div",r_,[R(m(dc),{class:"size-10 opacity-50"}),O[3]||(O[3]=T("div",{class:"text-center"},[T("p",{class:"font-medium"},"Binary file"),T("p",{class:"text-sm"},"This file cannot be displayed as a diff")],-1))])):m(d)&&!t.showFullFile?(w(),A("div",i_,[R(m(Xr),{class:"size-10 opacity-50"}),O[4]||(O[4]=T("div",{class:"text-center"},[T("p",{class:"font-medium"},"No changes"),T("p",{class:"text-sm"},"This file was touched but has no content changes")],-1))])):m(u)&&!m(n)&&!t.showFullFile?(w(),A("div",o_,[T("div",s_,[R(m(Xr),{class:"size-8 text-yellow-500"}),T("div",a_,[O[5]||(O[5]=T("p",{class:"font-medium"},"Large file",-1)),T("p",l_," This file has "+G(m(c).toLocaleString())+" lines (threshold: "+G(ys.toLocaleString())+") ",1)]),R(m(at),{variant:"outline",size:"sm",onClick:O[0]||(O[0]=N=>n.value=!0)},{default:M(()=>[R(m(Tl),{class:"mr-2 size-4"}),O[6]||(O[6]=re(" Show full diff ",-1))]),_:1})])])):t.showFullFile&&t.fileContent?(w(),A("div",c_,[T("div",u_,[(w(!0),A(ve,null,He(m(f),(N,D)=>(w(),A("div",{key:D,class:ue(["full-file-line",{"diff-add":B(D+1)==="add"}])},[T("div",d_,[T("span",p_,G(D+1),1)]),T("div",m_,[T("span",{class:"diff-code",innerHTML:m(V)[D]||P(N)},null,8,f_)])],2))),128))])])):(w(),A("div",h_,[T("div",g_,[R(m(at),{variant:"ghost",size:"sm",class:ue(["h-7 gap-1.5 text-xs",{"text-primary":m(r)}]),onClick:O[1]||(O[1]=N=>r.value=!m(r))},{default:M(()=>[(w(),K(kt(m(r)?m(vc):m(_c)),{class:"size-3.5"})),re(" "+G(m(r)?"Sync scroll":"Scroll unlocked"),1)]),_:1},8,["class"])]),T("div",__,[T("div",{ref_key:"leftScrollRef",ref:i,class:"diff-column diff-column-left",onScroll:l},[T("div",y_,[(w(!0),A(ve,null,He(m(k),N=>(w(),A(ve,{key:N.type==="line"?`left-${N.pair?.id}`:`left-sep-${N.hunkIndex}`},[N.type==="separator"?(w(),A("div",v_,[...O[7]||(O[7]=[T("div",{class:"separator-line"},null,-1),T("span",{class:"separator-text"},"···",-1)])])):N.pair?(w(),A("div",{key:1,class:ue(["diff-line",{"diff-remove":N.pair.left.type==="remove","diff-empty":N.pair.left.type==="empty","diff-context":N.pair.left.type==="context"}])},[T("div",b_,[N.pair.left.lineNum?(w(),A("span",k_,G(N.pair.left.lineNum),1)):Y("",!0)]),T("div",w_,[N.pair.left.type!=="empty"?(w(),A("span",{key:0,class:"diff-code",innerHTML:J(N.pair.id,"old")||P(N.pair.left.content)},null,8,x_)):Y("",!0)])],2)):Y("",!0)],64))),128))])],544),T("div",{ref_key:"rightScrollRef",ref:o,class:"diff-column diff-column-right",onScroll:a},[T("div",E_,[(w(!0),A(ve,null,He(m(k),N=>(w(),A(ve,{key:N.type==="line"?`right-${N.pair?.id}`:`right-sep-${N.hunkIndex}`},[N.type==="separator"?(w(),A("div",T_,[...O[8]||(O[8]=[T("span",{class:"separator-text"},"···",-1),T("div",{class:"separator-line"},null,-1)])])):N.pair?(w(),A("div",{key:1,class:ue(["diff-line",{"diff-add":N.pair.right.type==="add","diff-empty":N.pair.right.type==="empty","diff-context":N.pair.right.type==="context"}])},[T("div",A_,[N.pair.right.lineNum?(w(),A("span",S_,G(N.pair.right.lineNum),1)):Y("",!0)]),T("div",R_,[N.pair.right.type!=="empty"?(w(),A("span",{key:0,class:"diff-code",innerHTML:J(N.pair.id,"new")||P(N.pair.right.content)},null,8,L_)):Y("",!0)])],2)):Y("",!0)],64))),128))])],544)])]))]))}}),P_=Object.assign($s(C_,[["__scopeId","data-v-2678ccde"]]),{__name:"GitDiffViewer"}),O_=U({__name:"Tooltip",props:{defaultOpen:{type:Boolean},open:{type:Boolean},delayDuration:{},disableHoverableContent:{type:Boolean},disableClosingTrigger:{type:Boolean},disabled:{type:Boolean},ignoreNonKeyboardFocus:{type:Boolean}},emits:["update:open"],setup(t,{emit:e}){const i=rr(t,e);return(o,s)=>(w(),K(m(wd),Pe({"data-slot":"tooltip"},m(i)),{default:M(l=>[ne(o.$slots,"default",gn(_n(l)))]),_:3},16))}}),vs=Object.assign(O_,{__name:"UiTooltip"}),I_=U({inheritAttrs:!1,__name:"TooltipContent",props:{forceMount:{type:Boolean},ariaLabel:{},asChild:{type:Boolean},as:{},side:{},sideOffset:{default:4},align:{},alignOffset:{},avoidCollisions:{type:Boolean},collisionBoundary:{},collisionPadding:{},arrowPadding:{},sticky:{},hideWhenDetached:{type:Boolean},positionStrategy:{},updatePositionStrategy:{},class:{}},emits:["escapeKeyDown","pointerDownOutside"],setup(t,{emit:e}){const n=t,r=e,i=jt(n,"class"),o=rr(i,r);return(s,l)=>(w(),K(m(Ld),null,{default:M(()=>[R(m(Sd),Pe({"data-slot":"tooltip-content"},{...m(o),...s.$attrs},{class:m(Ve)("bg-foreground text-background animate-in fade-in-0 zoom-in-95 data-[state=closed]:animate-out data-[state=closed]:fade-out-0 data-[state=closed]:zoom-out-95 data-[side=bottom]:slide-in-from-top-2 data-[side=left]:slide-in-from-right-2 data-[side=right]:slide-in-from-left-2 data-[side=top]:slide-in-from-bottom-2 z-50 w-fit rounded-md px-3 py-1.5 text-xs text-balance",n.class)}),{default:M(()=>[ne(s.$slots,"default"),R(m(gd),{class:"bg-foreground fill-foreground z-50 size-2.5 translate-y-[calc(-50%_-_2px)] rotate-45 rounded-[2px]"})]),_:3},16,["class"])]),_:3}))}}),bs=Object.assign(I_,{__name:"UiTooltipContent"}),D_=U({__name:"TooltipProvider",props:{delayDuration:{default:0},skipDelayDuration:{},disableHoverableContent:{type:Boolean},disableClosingTrigger:{type:Boolean},disabled:{type:Boolean},ignoreNonKeyboardFocus:{type:Boolean}},setup(t){const e=t;return(n,r)=>(w(),K(m(vd),gn(_n(e)),{default:M(()=>[ne(n.$slots,"default")]),_:3},16))}}),ks=Object.assign(D_,{__name:"UiTooltipProvider"}),N_=U({__name:"TooltipTrigger",props:{reference:{},asChild:{type:Boolean},as:{}},setup(t){const e=t;return(n,r)=>(w(),K(m(Pd),Pe({"data-slot":"tooltip-trigger"},e),{default:M(()=>[ne(n.$slots,"default")]),_:3},16))}}),ws=Object.assign(N_,{__name:"UiTooltipTrigger"});function ll(){const{showError:t}=Ps();function e(u){if(u&&typeof u=="object"){const d=u;return d.data?.message||d.data?.statusMessage||d.message||"Unknown error"}return"Unknown error"}const n=j(!1),r=j(!1),i=j(!1),o=j(!1);async function s(u,d,h){if(!u||d.length===0)return{commits:[],failedShas:[]};n.value=!0;try{const f={shas:d.join(",")};h&&(f.repo=h);const g=await $fetch(`/api/repos/${u}/git/commits`,{query:f}),y=g.map(v=>v.shortSha),x=d.filter(v=>!y.some(k=>k.startsWith(v)||v.startsWith(k)));return{commits:g,failedShas:x}}catch(f){return t("Failed to fetch commits",e(f)),{commits:[],failedShas:d}}finally{n.value=!1}}async function l(u,d,h){if(!u||!d)return[];r.value=!0;try{const f={commit:d};return h&&(f.repo=h),await $fetch(`/api/repos/${u}/git/diff`,{query:f})}catch(f){return t("Failed to fetch diff",e(f)),[]}finally{r.value=!1}}async function a(u,d,h,f){if(!u||!d||!h)return[];i.value=!0;try{const g={commit:d,file:h};return f&&(g.repo=f),await $fetch(`/api/repos/${u}/git/file-diff`,{query:g})}catch(g){return t("Failed to fetch file diff",e(g)),[]}finally{i.value=!1}}async function c(u,d,h,f){if(!u||!d||!h)return null;o.value=!0;try{const g={commit:d,file:h};return f&&(g.repo=f),(await $fetch(`/api/repos/${u}/git/file-content`,{query:g})).content}catch(g){return t("Failed to fetch file content",e(g)),null}finally{o.value=!1}}return{fetchCommits:s,fetchDiff:l,fetchFileDiff:a,fetchFileContent:c,isLoadingCommits:Ln(n),isLoadingDiff:Ln(r),isLoadingFileDiff:Ln(i),isLoadingFileContent:Ln(o)}}const M_={key:0,class:"flex flex-1 flex-col items-center justify-center gap-4 p-8"},$_={class:"text-center"},V_={class:"text-sm text-muted-foreground"},B_={key:1,class:"flex flex-1 items-center justify-center"},z_={key:2,class:"flex flex-1 flex-col items-center justify-center gap-2 p-8 text-center text-muted-foreground"},F_={key:3,class:"flex min-h-0 flex-1 overflow-hidden"},j_={class:"flex w-56 shrink-0 flex-col border-r border-border"},q_={class:"flex items-center justify-between border-b border-border px-3 py-2"},H_={class:"text-xs font-medium text-muted-foreground"},G_={class:"text-muted-foreground/50 transition-colors hover:text-muted-foreground"},U_={class:"min-h-0 flex-1 overflow-y-auto"},W_={class:"flex min-h-0 flex-1 flex-col overflow-hidden"},K_={key:0,class:"flex items-center gap-2 border-b border-border px-4 py-2"},X_={key:0,class:"min-w-0 flex-1 truncate font-mono text-sm"},Y_={class:"text-muted-foreground"},Q_={key:1,class:"min-w-0 flex-1 truncate font-mono text-sm"},J_={key:2,class:"rounded bg-yellow-500/10 px-1.5 py-0.5 text-xs text-yellow-600 dark:text-yellow-400"},Z_={key:1,class:"flex flex-1 items-center justify-center"},ey={key:2,class:"flex flex-1 flex-col items-center justify-center gap-4 p-8"},ty={class:"text-center"},ny={class:"text-xs text-muted-foreground"},ry={key:4,class:"flex flex-1 items-center justify-center text-sm text-muted-foreground"},iy=U({__name:"DiffPanel",props:{repoId:{},commitSha:{},repoPath:{}},emits:["close"],setup(t,{emit:e}){const n=t,r=e,{fetchDiff:i,fetchFileDiff:o,fetchFileContent:s,isLoadingDiff:l,isLoadingFileDiff:a,isLoadingFileContent:c}=ll(),u=j([]),d=j(),h=j([]),f=j(null),g=j(null),y=j(null),x=j("changes"),v=$(()=>u.value.find(D=>D.path===d.value));async function k(){g.value=null,u.value=[],d.value=void 0,h.value=[];const D=await i(n.repoId,n.commitSha,n.repoPath);D.length===0&&!l.value&&(g.value=null),u.value=D,D.length>0&&(d.value=D[0].path)}async function b(){if(!d.value){h.value=[],f.value=null;return}y.value=null;const D=await o(n.repoId,n.commitSha,d.value,n.repoPath);if(h.value=D,x.value==="full"){const I=await s(n.repoId,n.commitSha,d.value,n.repoPath);f.value=I}}function E(){x.value=x.value==="changes"?"full":"changes"}Te(x,async D=>{if(D==="full"&&d.value&&!f.value){const I=await s(n.repoId,n.commitSha,d.value,n.repoPath);f.value=I}});function P(D){d.value=D}function V(){k()}function q(){b()}Te(d,()=>{b()}),Te(()=>[n.repoId,n.commitSha,n.repoPath],()=>{k()},{immediate:!0});const J=j(null),B=j(null);function S(D){if(u.value.length===0)return;const I=d.value?u.value.findIndex(ee=>ee.path===d.value):-1;let z;D==="next"?z=I<u.value.length-1?I+1:0:z=I>0?I-1:u.value.length-1;const W=u.value[z];W&&(d.value=W.path)}function O(D){if(!B.value)return;const I=B.value.querySelectorAll(".diff-separator");if(I.length===0)return;const z=B.value.closest(".overflow-y-auto, [data-radix-scroll-area-viewport]");if(!z)return;const W=z.scrollTop,ee=z.getBoundingClientRect();let Z=null;if(D==="next"){for(const oe of I)if(oe.getBoundingClientRect().top-ee.top+W>W+50){Z=oe;break}!Z&&I.length>0&&(Z=I[0])}else{for(let oe=I.length-1;oe>=0;oe--){const Oe=I[oe];if(Oe.getBoundingClientRect().top-ee.top+W<W-10){Z=Oe;break}}!Z&&I.length>0&&(Z=I[I.length-1])}Z&&Z.scrollIntoView({behavior:"smooth",block:"start"})}function N(D){if(!(D.target instanceof HTMLInputElement||D.target instanceof HTMLTextAreaElement))switch(D.key){case"j":case"ArrowDown":!D.ctrlKey&&!D.metaKey&&(D.preventDefault(),S("next"));break;case"k":case"ArrowUp":!D.ctrlKey&&!D.metaKey&&(D.preventDefault(),S("prev"));break;case"[":D.preventDefault(),O("prev");break;case"]":D.preventDefault(),O("next");break;case"Escape":D.preventDefault(),r("close");break}}return dt(()=>{document.addEventListener("keydown",N)}),Is(()=>{document.removeEventListener("keydown",N)}),(D,I)=>{const z=Yg,W=P_;return w(),A("div",{ref_key:"panelRef",ref:J,class:"flex h-full flex-col overflow-hidden",tabindex:"-1"},[m(g)?(w(),A("div",M_,[R(m(cn),{class:"size-12 text-destructive"}),T("div",$_,[I[0]||(I[0]=T("p",{class:"font-medium"},"Failed to load diff",-1)),T("p",V_,G(m(g)),1)]),R(m(at),{variant:"outline",size:"sm",onClick:V},{default:M(()=>[R(m(Hr),{class:"mr-2 size-4"}),I[1]||(I[1]=re(" Retry ",-1))]),_:1})])):m(l)&&m(u).length===0?(w(),A("div",B_,[R(m(Gr),{class:"size-8 animate-spin text-muted-foreground"})])):m(u).length===0?(w(),A("div",z_,[...I[2]||(I[2]=[T("p",null,"No files changed in this commit",-1)])])):(w(),A("div",F_,[T("div",j_,[T("div",q_,[T("span",H_,G(m(u).length)+" file"+G(m(u).length!==1?"s":"")+" changed ",1),R(m(ks),null,{default:M(()=>[R(m(vs),null,{default:M(()=>[R(m(ws),{"as-child":""},{default:M(()=>[T("button",G_,[R(m(Al),{class:"size-3.5"})])]),_:1}),R(m(bs),{side:"bottom",align:"end",class:"max-w-xs"},{default:M(()=>[...I[3]||(I[3]=[T("div",{class:"space-y-1 text-xs"},[T("div",{class:"flex justify-between gap-4"},[T("span",{class:"text-muted-foreground"},"Navigate files"),T("span",{class:"font-mono"},"j/k or ↑/↓")]),T("div",{class:"flex justify-between gap-4"},[T("span",{class:"text-muted-foreground"},"Jump to hunk"),T("span",{class:"font-mono"},"[ / ]")]),T("div",{class:"flex justify-between gap-4"},[T("span",{class:"text-muted-foreground"},"Close"),T("span",{class:"font-mono"},"Esc")])],-1)])]),_:1})]),_:1})]),_:1})]),T("div",U_,[R(z,{files:m(u),"selected-file":m(d),onSelect:P},null,8,["files","selected-file"])])]),T("div",W_,[m(d)?(w(),A("div",K_,[m(v)?.oldPath?(w(),A("span",X_,[T("span",Y_,G(m(v).oldPath),1),I[4]||(I[4]=T("span",{class:"mx-2 text-muted-foreground"},"→",-1)),T("span",null,G(m(d)),1)])):(w(),A("span",Q_,G(m(d)),1)),m(v)?.binary?(w(),A("span",J_," binary ")):Y("",!0),m(v)?.binary?Y("",!0):(w(),K(m(ks),{key:3},{default:M(()=>[R(m(vs),null,{default:M(()=>[R(m(ws),{"as-child":""},{default:M(()=>[R(m(at),{variant:"ghost",size:"sm",class:"h-7 shrink-0 gap-1.5 text-xs",onClick:E},{default:M(()=>[(w(),K(kt(m(x)==="changes"?m(uc):m(cc)),{class:"size-3.5"})),re(" "+G(m(x)==="changes"?"Changes":"Full file"),1)]),_:1})]),_:1}),R(m(bs),null,{default:M(()=>[re(G(m(x)==="changes"?"Show full file with changes":"Show changes only"),1)]),_:1})]),_:1})]),_:1}))])):Y("",!0),m(a)?(w(),A("div",Z_,[R(m(Gr),{class:"size-6 animate-spin text-muted-foreground"})])):m(y)?(w(),A("div",ey,[R(m(cn),{class:"size-8 text-destructive"}),T("div",ty,[I[5]||(I[5]=T("p",{class:"text-sm font-medium"},"Failed to load file diff",-1)),T("p",ny,G(m(y)),1)]),R(m(at),{variant:"outline",size:"sm",onClick:q},{default:M(()=>[R(m(Hr),{class:"mr-2 size-4"}),I[6]||(I[6]=re(" Retry ",-1))]),_:1})])):m(d)?(w(),K(m(Sl),{key:3,class:"h-0 flex-1 overflow-hidden"},{default:M(()=>[T("div",{ref_key:"diffViewerRef",ref:B},[R(W,{hunks:m(h),"file-path":m(d),binary:m(v)?.binary,"old-path":m(v)?.oldPath,"file-content":m(f),"show-full-file":m(x)==="full","is-loading-content":m(c)},null,8,["hunks","file-path","binary","old-path","file-content","show-full-file","is-loading-content"])],512)]),_:1})):(w(),A("div",ry," Select a file to view changes "))])]))],512)}}}),oy=Object.assign(iy,{__name:"GitDiffPanel"}),sy={class:"space-y-2"},ay={key:1,class:"rounded-lg border border-dashed p-4 text-center text-sm text-muted-foreground"},ly=["onClick"],cy={class:"flex items-start gap-3"},uy={class:"min-w-0 flex-1"},dy={class:"flex flex-wrap items-center gap-2"},py={class:"font-mono text-xs font-medium text-primary"},my={class:"flex items-center gap-1 text-xs text-muted-foreground"},fy={class:"flex items-center gap-0.5 text-xs text-green-600 dark:text-green-400"},hy={class:"flex items-center gap-0.5 text-xs text-red-600 dark:text-red-400"},gy={class:"mt-1 truncate text-sm"},_y={key:1,class:"flex items-center gap-1 text-muted-foreground"},yy={key:2,class:"text-muted-foreground"},vy={key:0,class:"mt-1 text-xs text-muted-foreground"},by=U({__name:"CommitList",props:{commits:{},repoId:{}},emits:["select"],setup(t,{emit:e}){const n=t,r=e,{fetchCommits:i,isLoadingCommits:o}=ll(),s=j(new Map),l=j(new Set),a=$(()=>new Set(n.commits.map(g=>g.repo).filter(Boolean)).size>1);Te(()=>({commits:n.commits,repoId:n.repoId}),async({commits:f,repoId:g})=>{if(f.length===0||!g){s.value=new Map,l.value=new Set;return}const y=new Map;for(const b of f){const E=b.repo||"";y.has(E)||y.set(E,[]),y.get(E).push(b.sha)}const x=await Promise.all(Array.from(y.entries()).map(async([b,E])=>{const P=await i(g,E,b||void 0);return{commits:P.commits.map(V=>({...V,repoPath:b})),failedShas:P.failedShas}})),v=new Map,k=new Set;for(const{commits:b,failedShas:E}of x){for(const P of b)v.set(P.shortSha,P);for(const P of E)k.add(P)}s.value=v,l.value=k},{immediate:!0});function c(f){const g=new Date(f),x=new Date().getTime()-g.getTime(),v=Math.floor(x/1e3),k=Math.floor(v/60),b=Math.floor(k/60),E=Math.floor(b/24);return v<60?"just now":k<60?`${k} minute${k===1?"":"s"} ago`:b<24?`${b} hour${b===1?"":"s"} ago`:E<7?`${E} day${E===1?"":"s"} ago`:g.toLocaleDateString()}function u(f){r("select",f.sha,f.repo)}function d(f){const g=s.value.get(f);if(g)return g;for(const[y,x]of s.value)if(y.startsWith(f)||f.startsWith(y))return x}function h(f){if(l.value.has(f))return!0;for(const g of l.value)if(g.startsWith(f)||f.startsWith(g))return!0;return!1}return(f,g)=>(w(),A("div",sy,[m(o)?(w(!0),A(ve,{key:0},He(Math.min(t.commits.length,3),y=>(w(),A("div",{key:y,class:"animate-pulse rounded-lg border bg-muted/50 p-3"},[...g[0]||(g[0]=[Jl('<div class="flex items-start gap-3"><div class="h-5 w-5 rounded bg-muted"></div><div class="flex-1 space-y-2"><div class="h-4 w-20 rounded bg-muted"></div><div class="h-4 w-3/4 rounded bg-muted"></div><div class="h-3 w-1/2 rounded bg-muted"></div></div></div>',1)])]))),128)):t.commits.length===0?(w(),A("div",ay," No commits recorded for this task ")):(w(!0),A(ve,{key:2},He(t.commits,y=>(w(),A("button",{key:y.sha,class:"w-full rounded-lg border bg-card p-3 text-left transition-colors hover:bg-muted/50 focus:outline-none focus:ring-2 focus:ring-ring",onClick:x=>u(y)},[T("div",cy,[R(m(gc),{class:"mt-0.5 size-5 shrink-0 text-muted-foreground"}),T("div",uy,[T("div",dy,[T("code",py,G(d(y.sha)?.shortSha||y.sha.substring(0,7)),1),d(y.sha)?(w(),A(ve,{key:0},[T("span",my,[R(m(Os),{class:"size-3"}),re(" "+G(d(y.sha).filesChanged),1)]),T("span",fy,[R(m(Rl),{class:"size-3"}),re(G(d(y.sha).additions),1)]),T("span",hy,[R(m(Kr),{class:"size-3"}),re(G(d(y.sha).deletions),1)])],64)):Y("",!0),y.repo&&m(a)?(w(),K(m(Nt),{key:1,variant:"secondary",class:"gap-1 text-xs"},{default:M(()=>[R(m(hc),{class:"size-3"}),re(" "+G(y.repo),1)]),_:2},1024)):Y("",!0)]),T("p",gy,[d(y.sha)?(w(),A(ve,{key:0},[re(G(d(y.sha).message),1)],64)):h(y.sha)?(w(),A("span",_y,[R(m(cn),{class:"size-3"}),g[1]||(g[1]=re(" Commit unavailable ",-1))])):(w(),A("span",yy,"Loading..."))]),d(y.sha)?(w(),A("p",vy,G(d(y.sha).author)+" · "+G(c(d(y.sha).date)),1)):Y("",!0)])])],8,ly))),128))]))}}),ky=Object.assign(by,{__name:"GitCommitList"}),wy=U({__name:"Separator",props:{orientation:{default:"horizontal"},decorative:{type:Boolean,default:!0},asChild:{type:Boolean},as:{},class:{}},setup(t){const e=t,n=jt(e,"class");return(r,i)=>(w(),K(m(Ll),Pe({"data-slot":"separator"},m(n),{class:m(Ve)("bg-border shrink-0 data-[orientation=horizontal]:h-px data-[orientation=horizontal]:w-full data-[orientation=vertical]:h-full data-[orientation=vertical]:w-px",e.class)}),null,16,["class"]))}}),rn=Object.assign(wy,{__name:"UiSeparator"}),xy={class:"flex items-center gap-2"},Ey={key:1,class:"min-h-0 flex-1 overflow-hidden"},Ty={key:2,class:"min-h-0 flex-1 space-y-4 overflow-y-auto px-6"},Ay={class:"flex flex-wrap items-center gap-2"},Sy={class:"space-y-2"},Ry={class:"text-sm text-muted-foreground leading-relaxed"},Ly={key:0,class:"space-y-2"},Cy={class:"flex items-center gap-2 text-sm font-medium"},Py={class:"ml-4 list-decimal space-y-1 text-sm text-muted-foreground"},Oy={key:2,class:"space-y-2"},Iy={class:"flex items-center gap-2 text-sm font-medium"},Dy={class:"space-y-1.5 text-sm text-muted-foreground"},Ny={key:4,class:"space-y-2"},My={class:"flex items-center gap-2 text-sm font-medium"},$y={class:"space-y-1 text-sm text-muted-foreground"},Vy={class:"font-mono text-xs"},By={class:"space-y-2"},zy={class:"flex items-center gap-2 text-sm font-medium"},Fy={key:6,class:"space-y-2"},jy={class:"flex flex-col gap-1 text-xs text-muted-foreground"},qy={key:0,class:"flex items-center gap-2"},Hy={key:1,class:"flex items-center gap-2"},Gy=U({__name:"Detail",props:ec({task:{},taskTitles:{},commits:{},repoId:{}},{open:{type:Boolean,default:!1},openModifiers:{}}),emits:["update:open"],setup(t){const e=t,n=Zl(t,"open"),r=$(()=>{if(!e.task)return{label:"",variant:"secondary"};switch(e.task.category){case"setup":return{label:"Setup",variant:"secondary"};case"feature":return{label:"Feature",variant:"default"};case"integration":return{label:"Integration",variant:"outline"};case"testing":return{label:"Testing",variant:"secondary"};case"documentation":return{label:"Docs",variant:"secondary"};default:return{label:e.task.category,variant:"secondary"}}}),i=$(()=>{if(!e.task)return{label:"",class:""};switch(e.task.priority){case"critical":return{label:"Critical",class:"text-destructive"};case"high":return{label:"High",class:"text-orange-500"};case"medium":return{label:"Medium",class:"text-muted-foreground"};case"low":return{label:"Low",class:"text-muted-foreground"};default:return{label:e.task.priority,class:"text-muted-foreground"}}}),o=$(()=>{if(!e.task)return{label:"",icon:an,class:""};switch(e.task.status){case"pending":return{label:"Pending",icon:an,class:"text-muted-foreground"};case"in_progress":return{label:"In Progress",icon:ac,class:"text-blue-500"};case"completed":return{label:"Completed",icon:Wr,class:"text-green-500"};default:return{label:e.task.status,icon:an,class:"text-muted-foreground"}}});function s(g){if(!g)return"";try{return new Date(g).toLocaleString()}catch{return g}}function l(g){return e.taskTitles?.get(g)??g}const a=$(()=>e.commits&&e.commits.length>0&&e.repoId),c=j("details"),u=j(null),d=j(null);function h(g,y){u.value=g,d.value=y||null,c.value="diff"}function f(){c.value="details",u.value=null,d.value=null}return Te(()=>e.task,()=>{c.value="details",u.value=null,d.value=null}),Te(n,g=>{g||(c.value="details",u.value=null,d.value=null)}),(g,y)=>{const x=oy,v=ky;return w(),K(m(Ml),{open:n.value,"onUpdate:open":y[0]||(y[0]=k=>n.value=k)},{default:M(()=>[R(m(Nl),{class:ue(["flex h-full w-full flex-col overflow-hidden sm:max-w-lg",{"sm:!max-w-none !max-w-none":m(c)==="diff"}])},{default:M(()=>[t.task?(w(),K(m(Cl),{key:0,class:"px-6 pr-12"},{default:M(()=>[T("div",xy,[m(c)==="diff"?(w(),K(m(at),{key:0,variant:"ghost",size:"icon",class:"size-8 shrink-0",onClick:f},{default:M(()=>[R(m(ic),{class:"size-4"})]),_:1})):Y("",!0),R(m(Pl),{class:"text-left text-lg"},{default:M(()=>[re(G(m(c)==="diff"?"Commit Changes":t.task.title),1)]),_:1})]),R(m(Ol),{class:"sr-only"},{default:M(()=>[...y[1]||(y[1]=[re("Task details",-1)])]),_:1})]),_:1})):Y("",!0),t.task&&m(c)==="diff"&&m(u)&&t.repoId?(w(),A("div",Ey,[R(x,{"repo-id":t.repoId,"commit-sha":m(u),"repo-path":m(d)||void 0,class:"h-full",onClose:f},null,8,["repo-id","commit-sha","repo-path"])])):t.task?(w(),A("div",Ty,[T("div",Ay,[R(m(Nt),{variant:m(r).variant},{default:M(()=>[R(m(wc),{class:"mr-1 size-3"}),re(" "+G(m(r).label),1)]),_:1},8,["variant"]),R(m(Nt),{variant:"outline",class:ue(m(i).class)},{default:M(()=>[R(m(Xr),{class:"mr-1 size-3"}),re(" "+G(m(i).label),1)]),_:1},8,["class"]),R(m(Nt),{variant:"outline",class:ue(m(o).class)},{default:M(()=>[(w(),K(kt(m(o).icon),{class:"mr-1 size-3"})),re(" "+G(m(o).label),1)]),_:1},8,["class"])]),T("div",Sy,[y[2]||(y[2]=T("h4",{class:"text-sm font-medium"},"Description",-1)),T("p",Ry,G(t.task.description),1)]),R(m(rn)),t.task.steps.length>0?(w(),A("div",Ly,[T("h4",Cy,[R(m(bc),{class:"size-4"}),y[3]||(y[3]=re(" Steps ",-1))]),T("ol",Py,[(w(!0),A(ve,null,He(t.task.steps,(k,b)=>(w(),A("li",{key:b,class:"pl-1"},G(k),1))),128))])])):Y("",!0),t.task.steps.length>0&&t.task.passes.length>0?(w(),K(m(rn),{key:1})):Y("",!0),t.task.passes.length>0?(w(),A("div",Oy,[T("h4",Iy,[R(m(kc),{class:"size-4"}),y[4]||(y[4]=re(" Pass Criteria ",-1))]),T("ul",Dy,[(w(!0),A(ve,null,He(t.task.passes,(k,b)=>(w(),A("li",{key:b,class:"flex items-start gap-2"},[T("div",{class:ue(["mt-0.5 flex size-4 shrink-0 items-center justify-center rounded border",t.task.status==="completed"?"border-primary bg-primary text-primary-foreground":"border-muted-foreground/50"])},[t.task.status==="completed"?(w(),K(m($l),{key:0,class:"size-3"})):Y("",!0)],2),T("span",null,G(k),1)]))),128))])])):Y("",!0),t.task.dependencies.length>0?(w(),K(m(rn),{key:3})):Y("",!0),t.task.dependencies.length>0?(w(),A("div",Ny,[T("h4",My,[R(m(yc),{class:"size-4"}),y[5]||(y[5]=re(" Dependencies ",-1))]),T("ul",$y,[(w(!0),A(ve,null,He(t.task.dependencies,k=>(w(),A("li",{key:k,class:"flex items-center gap-2"},[T("span",Vy,G(k),1),T("span",null,G(l(k)),1)]))),128))])])):Y("",!0),m(a)?(w(),A(ve,{key:5},[R(m(rn)),T("div",By,[T("h4",zy,[R(m(lc),{class:"size-4"}),y[6]||(y[6]=re(" Changes ",-1))]),R(v,{commits:t.commits,"repo-id":t.repoId,onSelect:h},null,8,["commits","repo-id"])])],64)):Y("",!0),t.task.startedAt||t.task.completedAt?(w(),A("div",Fy,[R(m(rn)),T("div",jy,[t.task.startedAt?(w(),A("div",qy,[R(m(Vs),{class:"size-3"}),T("span",null,"Started: "+G(s(t.task.startedAt)),1)])):Y("",!0),t.task.completedAt?(w(),A("div",Hy,[R(m(Wr),{class:"size-3"}),T("span",null,"Completed: "+G(s(t.task.completedAt)),1)])):Y("",!0)])])):Y("",!0)])):Y("",!0),R(m(Il),{class:"px-6 pb-6"},{default:M(()=>[R(m(Dl),{"as-child":""},{default:M(()=>[R(m(at),{variant:"outline",class:"w-full"},{default:M(()=>[...y[7]||(y[7]=[re("Close",-1)])]),_:1})]),_:1})]),_:1})]),_:1},8,["class"])]),_:1},8,["open"])}}}),Uy=Object.assign(Gy,{__name:"TasksDetail"}),Wy=U({__name:"Tabs",props:{defaultValue:{},orientation:{},dir:{},activationMode:{},modelValue:{},unmountOnHide:{type:Boolean},asChild:{type:Boolean},as:{},class:{}},emits:["update:modelValue"],setup(t,{emit:e}){const n=t,r=e,i=jt(n,"class"),o=rr(i,r);return(s,l)=>(w(),K(m(ld),Pe({"data-slot":"tabs"},m(o),{class:m(Ve)("flex flex-col gap-2",n.class)}),{default:M(a=>[ne(s.$slots,"default",gn(_n(a)))]),_:3},16,["class"]))}}),Ky=Object.assign(Wy,{__name:"UiTabs"}),Xy=U({__name:"TabsContent",props:{value:{},forceMount:{type:Boolean},asChild:{type:Boolean},as:{},class:{}},setup(t){const e=t,n=jt(e,"class");return(r,i)=>(w(),K(m(ud),Pe({"data-slot":"tabs-content",class:m(Ve)("flex-1 outline-none",e.class)},m(n)),{default:M(()=>[ne(r.$slots,"default")]),_:3},16,["class"]))}}),xs=Object.assign(Xy,{__name:"UiTabsContent"}),Yy=U({__name:"TabsList",props:{loop:{type:Boolean},asChild:{type:Boolean},as:{},class:{}},setup(t){const e=t,n=jt(e,"class");return(r,i)=>(w(),K(m(pd),Pe({"data-slot":"tabs-list"},m(n),{class:m(Ve)("bg-muted text-muted-foreground inline-flex h-9 w-fit items-center justify-center rounded-lg p-[3px]",e.class)}),{default:M(()=>[ne(r.$slots,"default")]),_:3},16,["class"]))}}),Qy=Object.assign(Yy,{__name:"UiTabsList"}),Jy=U({__name:"TabsTrigger",props:{value:{},disabled:{type:Boolean},asChild:{type:Boolean},as:{},class:{}},setup(t){const e=t,n=jt(e,"class"),r=Ls(n);return(i,o)=>(w(),K(m(fd),Pe({"data-slot":"tabs-trigger",class:m(Ve)("data-[state=active]:bg-background dark:data-[state=active]:text-foreground focus-visible:border-ring focus-visible:ring-ring/50 focus-visible:outline-ring dark:data-[state=active]:border-input dark:data-[state=active]:bg-input/30 text-foreground dark:text-muted-foreground inline-flex h-[calc(100%-1px)] flex-1 items-center justify-center gap-1.5 rounded-md border border-transparent px-2 py-1 text-sm font-medium whitespace-nowrap transition-[color,box-shadow] focus-visible:ring-[3px] focus-visible:outline-1 disabled:pointer-events-none disabled:opacity-50 data-[state=active]:shadow-sm [&_svg]:pointer-events-none [&_svg]:shrink-0 [&_svg:not([class*='size-'])]:size-4",e.class)},m(r)),{default:M(()=>[ne(i.$slots,"default")]),_:3},16,["class"]))}}),Es=Object.assign(Jy,{__name:"UiTabsTrigger"}),Zy={class:"h-full p-4 md:p-6"},ev={key:0,class:"flex h-full items-center justify-center"},tv={class:"flex flex-col items-center gap-4"},nv={key:1,class:"flex h-full items-center justify-center"},rv={class:"flex max-w-md flex-col items-center gap-4 text-center"},iv={class:"text-sm text-muted-foreground"},ov={class:"flex gap-3"},sv={key:2,class:"mx-auto max-w-6xl space-y-6"},av={class:"space-y-2"},lv={class:"text-2xl font-bold tracking-tight"},cv={key:0,class:"text-xs text-muted-foreground"},uv={class:"rounded-lg border border-border bg-card p-4 md:p-6"},dv={key:0,class:"h-[calc(100vh-280px)] min-h-[400px]"},pv={key:1,class:"py-12 text-center"},wv=U({__name:"[prd]",setup(t){const e=tc(),{selectRepo:n}=ql(),{fetchDocument:r,fetchTasks:i,fetchProgress:o,fetchTaskCommits:s}=Hl(),{showError:l}=Ps(),a=$(()=>e.params.repo),c=$(()=>e.params.prd),u=j(null),d=j(null),h=j(null),f=j(!0),g=j(null),y=j("document");dt(()=>{{const B=localStorage.getItem("prd-viewer-tab");(B==="document"||B==="board")&&(y.value=B),window.addEventListener("storage",S=>{S.key==="prd-viewer-tab"&&S.newValue&&(S.newValue==="document"||S.newValue==="board")&&(y.value=S.newValue)})}}),Te(y,B=>{localStorage.setItem("prd-viewer-tab",B)});const x=j(null),v=j(!1),k=$(()=>{const B=new Map;if(d.value?.tasks)for(const S of d.value.tasks)B.set(S.id,S.title);return B}),b=nc("fileChangeEvent",j(null));async function E(){const B=await r(c.value);B&&(u.value=B)}async function P(){const[B,S]=await Promise.all([i(c.value),o(c.value)]);d.value=B,h.value=S}async function V(){f.value=!0,g.value=null;try{n(a.value);const[B,S,O]=await Promise.all([r(c.value),i(c.value),o(c.value)]);if(!B){g.value=`PRD "${c.value}" not found in this repository.`;return}u.value=B,d.value=S,h.value=O,S||(y.value="document")}catch(B){const S=B;S.statusCode===404?g.value=`PRD "${c.value}" not found. Check if the file exists in docs/prd/.`:S.statusCode===500?(g.value="Server error while loading the PRD. Check the file format.",l("Server error",S.data?.message||"Failed to read PRD file")):(g.value="Failed to load PRD document. Please try again.",l("Load failed","Could not fetch the PRD document"))}finally{f.value=!1}}Te(()=>b.value,B=>{B&&(B.category==="prd"?E():(B.category==="tasks"||B.category==="progress")&&P())}),dt(V),Te([a,c],V);async function q(B){x.value=B,v.value=!0,J.value=await s(c.value,B.id)}const J=j([]);return(B,S)=>{const O=_l,N=Vd,D=pg,I=Vg,z=Uy;return w(),A("div",Zy,[m(f)?(w(),A("div",ev,[T("div",tv,[R(m(Gr),{class:"size-8 animate-spin text-primary"}),S[2]||(S[2]=T("p",{class:"text-sm text-muted-foreground"},"Loading PRD...",-1))])])):m(g)?(w(),A("div",nv,[T("div",rv,[R(m(cn),{class:"size-12 text-destructive"}),S[5]||(S[5]=T("h2",{class:"text-lg font-semibold"},"Error Loading PRD",-1)),T("p",iv,G(m(g)),1),T("div",ov,[R(m(at),{variant:"outline",size:"sm",onClick:V},{default:M(()=>[R(m(Hr),{class:"mr-2 size-4"}),S[3]||(S[3]=re(" Retry ",-1))]),_:1}),R(O,{to:"/"},{default:M(()=>[R(m(at),{variant:"ghost",size:"sm"},{default:M(()=>[...S[4]||(S[4]=[re(" Go back home ",-1)])]),_:1})]),_:1})])])])):m(u)?(w(),A("div",sv,[T("div",av,[T("h1",lv,G(m(u).name),1),R(N,{metadata:m(u).metadata},null,8,["metadata"])]),R(m(Ky),{modelValue:m(y),"onUpdate:modelValue":S[0]||(S[0]=W=>ko(y)?y.value=W:null),class:"w-full"},{default:M(()=>[R(m(Qy),null,{default:M(()=>[R(m(Es),{value:"document",class:"gap-2"},{default:M(()=>[R(m(Os),{class:"size-4"}),S[6]||(S[6]=re(" Document ",-1))]),_:1}),R(m(Es),{value:"board",class:"gap-2",disabled:!m(d)},{default:M(()=>[R(m(vo),{class:"size-4"}),S[7]||(S[7]=re(" Task Board ",-1)),m(d)?(w(),A("span",cv," ("+G(m(d).tasks.length)+") ",1)):Y("",!0)]),_:1},8,["disabled"])]),_:1}),R(m(xs),{value:"document",class:"mt-4"},{default:M(()=>[T("div",uv,[R(D,{content:m(u).content},null,8,["content"])])]),_:1}),R(m(xs),{value:"board",class:"mt-4"},{default:M(()=>[m(d)?(w(),A("div",dv,[R(I,{tasks:m(d).tasks,onTaskClick:q},null,8,["tasks"])])):(w(),A("div",pv,[R(m(vo),{class:"mx-auto size-12 text-muted-foreground/50"}),S[8]||(S[8]=T("p",{class:"mt-4 text-muted-foreground"}," No tasks found for this PRD ",-1)),S[9]||(S[9]=T("p",{class:"mt-1 text-sm text-muted-foreground/70"}," Task state has not been generated for this PRD yet. ",-1))]))]),_:1})]),_:1},8,["modelValue"])])):Y("",!0),R(z,{open:m(v),"onUpdate:open":S[1]||(S[1]=W=>ko(v)?v.value=W:null),task:m(x),"task-titles":m(k),commits:m(J),"repo-id":m(a)},null,8,["open","task","task-titles","commits","repo-id"])])}}});export{wv as default};