@piwitests/server 0.22.1 → 0.24.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (528) hide show
  1. package/.output/nitro.json +1 -1
  2. package/.output/public/_nuxt/{By5qkOq8.js → -COcylA_.js} +1 -1
  3. package/.output/public/_nuxt/03FA4-rI.js +1 -0
  4. package/.output/public/_nuxt/{2VtBYkNh.js → 5a7jHE9s.js} +1 -1
  5. package/.output/public/_nuxt/6Z_ZwH8I.js +1 -0
  6. package/.output/public/_nuxt/7ZHq6PCI.js +1 -0
  7. package/.output/public/_nuxt/{cSeAgciy.js → 98sAB6Gu.js} +1 -1
  8. package/.output/public/_nuxt/{CoPntblj.js → B--J7VNt.js} +1 -1
  9. package/.output/public/_nuxt/{Dj-TetcW.js → B1LUinhp.js} +1 -1
  10. package/.output/public/_nuxt/{CCP6Tyle.js → B33YjaHr.js} +1 -1
  11. package/.output/public/_nuxt/B69RP95P.js +1 -0
  12. package/.output/public/_nuxt/{x8YSyy4c.js → B8H4XydJ.js} +1 -1
  13. package/.output/public/_nuxt/{DpalT0nH.js → B8Xm4_S_.js} +1 -1
  14. package/.output/public/_nuxt/{9N6hSApy.js → BBhrClA9.js} +1 -1
  15. package/.output/public/_nuxt/{BhH0TNTi.js → BCGljaM0.js} +1 -1
  16. package/.output/public/_nuxt/{BVN50jIb.js → BFxvHlO9.js} +1 -1
  17. package/.output/public/_nuxt/{DsX5CCb5.js → BKrWWV14.js} +1 -1
  18. package/.output/public/_nuxt/BN1zZw5b.js +9 -0
  19. package/.output/public/_nuxt/{iubpj2qv.js → BPXqL9vK.js} +1 -1
  20. package/.output/public/_nuxt/{CAZpjzvB.js → BUnwEAjq.js} +1 -1
  21. package/.output/public/_nuxt/{D6Mo5HeX.js → BVLqydCr.js} +1 -1
  22. package/.output/public/_nuxt/{9P8iHISX.js → BWMSVSNM.js} +1 -1
  23. package/.output/public/_nuxt/B_r0xHVS.js +1 -0
  24. package/.output/public/_nuxt/{DtSn2Q9-.js → BakMHV79.js} +1 -1
  25. package/.output/public/_nuxt/{_VzR8bwc.js → Bd8B-yeR.js} +1 -1
  26. package/.output/public/_nuxt/{BUMoU50-.js → BevElZaK.js} +1 -1
  27. package/.output/public/_nuxt/BfA6lfg4.js +1 -0
  28. package/.output/public/_nuxt/{DGyGmFem.js → Bg93Rnts.js} +1 -1
  29. package/.output/public/_nuxt/BgABj4Ty.js +4 -0
  30. package/.output/public/_nuxt/{CkKCKAYp.js → BkM2KXUo.js} +2 -2
  31. package/.output/public/_nuxt/{DQnsFoJn.js → BkxRbXIj.js} +1 -1
  32. package/.output/public/_nuxt/{CNcu4khZ.js → Bme1UkOl.js} +1 -1
  33. package/.output/public/_nuxt/{CobveFaj.js → BmzxRbcg.js} +1 -1
  34. package/.output/public/_nuxt/Bn0jaRxI.js +1 -0
  35. package/.output/public/_nuxt/{SBmMTKQb.js → BoNKdx5o.js} +1 -1
  36. package/.output/public/_nuxt/{BQzG26t0.js → Bp3FRuEm.js} +1 -1
  37. package/.output/public/_nuxt/{DOLeth7M.js → BrUBOQ0y.js} +1 -1
  38. package/.output/public/_nuxt/{nANaAHCd.js → BtSGUY-7.js} +1 -1
  39. package/.output/public/_nuxt/{BfS8BZTO.js → BtbpLWDs.js} +1 -1
  40. package/.output/public/_nuxt/{Cwwe5bRS.js → BvAfKk6C.js} +1 -1
  41. package/.output/public/_nuxt/{BqCiYSVY.js → BwEN1fJ1.js} +1 -1
  42. package/.output/public/_nuxt/{B0hK-xDF.js → C-XjxjG5.js} +1 -1
  43. package/.output/public/_nuxt/{kfFeu9tK.js → C3W_wyr9.js} +1 -1
  44. package/.output/public/_nuxt/{h49q_GXF.js → C5TrTuWv.js} +42 -42
  45. package/.output/public/_nuxt/{B2a-Phk3.js → C7D5Wl7T.js} +1 -1
  46. package/.output/public/_nuxt/{B09ddw9C.js → C7fq_rHE.js} +1 -1
  47. package/.output/public/_nuxt/{CWoSSKhQ.js → C8Paf_V1.js} +1 -1
  48. package/.output/public/_nuxt/{BQOWm9mQ.js → CD8ZzAFC.js} +1 -1
  49. package/.output/public/_nuxt/{DwyFnMoY.js → CDTeSrLO.js} +1 -1
  50. package/.output/public/_nuxt/{Cf52zHyB.js → CGHV0Y2d.js} +1 -1
  51. package/.output/public/_nuxt/{BtaTvcz6.js → CIpF9l75.js} +1 -1
  52. package/.output/public/_nuxt/{CkyMZI-0.js → CJ1rmnk4.js} +1 -1
  53. package/.output/public/_nuxt/{DOBSrxzY.js → CMuzkARi.js} +1 -1
  54. package/.output/public/_nuxt/{3xlGO1qT.js → COuZu9FO.js} +1 -1
  55. package/.output/public/_nuxt/{BZnfiR67.js → CX5Q0dZ8.js} +1 -1
  56. package/.output/public/_nuxt/{DBhdObsO.js → CX_G-FHC.js} +14 -14
  57. package/.output/public/_nuxt/{DDN2tt0a.js → Ce5_Tq63.js} +1 -1
  58. package/.output/public/_nuxt/{BlRWlfdD.js → Cf4MFOuf.js} +1 -1
  59. package/.output/public/_nuxt/{BYB8NVJZ.js → CgkXEZMo.js} +1 -1
  60. package/.output/public/_nuxt/{BFcdtAzg.js → CjBktNrC.js} +1 -1
  61. package/.output/public/_nuxt/{DXXnDejN.js → CjtjQV60.js} +1 -1
  62. package/.output/public/_nuxt/{x8w_1_rn.js → CpcrljrH.js} +1 -1
  63. package/.output/public/_nuxt/{C0v6l4pr.js → Cq33x7yV.js} +1 -1
  64. package/.output/public/_nuxt/{BDQCwxpX.js → CsV7pmcT.js} +1 -1
  65. package/.output/public/_nuxt/{C9p0YCAi.js → Cu2Q4iPh.js} +1 -1
  66. package/.output/public/_nuxt/CyLcEDg2.js +2 -0
  67. package/.output/public/_nuxt/{PdEEuEsg.js → D0Kop4bS.js} +1 -1
  68. package/.output/public/_nuxt/D1Y43xM1.js +2 -0
  69. package/.output/public/_nuxt/{DK7xciFW.js → D1vqYZsL.js} +1 -1
  70. package/.output/public/_nuxt/{BmJUhCIO.js → D2rZosKf.js} +1 -1
  71. package/.output/public/_nuxt/D7jpwkRG.js +5 -0
  72. package/.output/public/_nuxt/{CZ9ThISn.js → D8NAb7VE.js} +1 -1
  73. package/.output/public/_nuxt/{6-ivqM_I.js → D8vguZKg.js} +1 -1
  74. package/.output/public/_nuxt/{Hot1UcKY.js → DEvYVl9M.js} +1 -1
  75. package/.output/public/_nuxt/{CMhK1PvI.js → DF6Mes5z.js} +1 -1
  76. package/.output/public/_nuxt/{Sgis3xif.js → DGq4A2Pd.js} +1 -1
  77. package/.output/public/_nuxt/{BKJetfRH.js → DH5H1DJh.js} +1 -1
  78. package/.output/public/_nuxt/{Gik813Ek.js → DL8knjzi.js} +1 -1
  79. package/.output/public/_nuxt/{b_yFgp5S.js → DM3bDZC6.js} +1 -1
  80. package/.output/public/_nuxt/{DLNNAYfu.js → DMAiMrNr.js} +1 -1
  81. package/.output/public/_nuxt/{DLn-VPtK.js → DMWfVJCj.js} +1 -1
  82. package/.output/public/_nuxt/{BNAHBHbY.js → DMsm-RGQ.js} +1 -1
  83. package/.output/public/_nuxt/{CD3R-ggS.js → DMtrFQqi.js} +1 -1
  84. package/.output/public/_nuxt/{B9kt7ySS.js → DPZBpFOX.js} +1 -1
  85. package/.output/public/_nuxt/DVEGfqtt.js +2 -0
  86. package/.output/public/_nuxt/{D4UlSVir.js → D_y2VS8k.js} +1 -1
  87. package/.output/public/_nuxt/DaNC-xl1.js +1 -0
  88. package/.output/public/_nuxt/{DzM9oeLa.js → DbmGeOus.js} +1 -1
  89. package/.output/public/_nuxt/{DHUT-BKj.js → DcLbz6DV.js} +1 -1
  90. package/.output/public/_nuxt/{CWw9WGlv.js → DcR0Mmdl.js} +1 -1
  91. package/.output/public/_nuxt/{CDh_Qt7h.js → DhYznn-U.js} +1 -1
  92. package/.output/public/_nuxt/DhuRRlmK.js +1 -0
  93. package/.output/public/_nuxt/{CBZD8ym8.js → Drw8yQg6.js} +1 -1
  94. package/.output/public/_nuxt/{Bt4FLbe0.js → DuO5wfAC.js} +1 -1
  95. package/.output/public/_nuxt/{CRPt9SfB.js → DuOH5jcQ.js} +1 -1
  96. package/.output/public/_nuxt/{BH-ym1CI.js → DvEsAuE9.js} +1 -1
  97. package/.output/public/_nuxt/Dz6g_QJT.js +1 -0
  98. package/.output/public/_nuxt/{4yvOL9PC.js → DzZpIs4W.js} +1 -1
  99. package/.output/public/_nuxt/DzzNS-K1.js +1 -0
  100. package/.output/public/_nuxt/{COP3KBCA.js → Fsw2W4TA.js} +1 -1
  101. package/.output/public/_nuxt/{DWEkQ7bl.js → LwoTUb-r.js} +1 -1
  102. package/.output/public/_nuxt/{BjU3HZuS.js → OfPjZaky.js} +1 -1
  103. package/.output/public/_nuxt/{czXrP7NB.js → P5uOaRUZ.js} +1 -1
  104. package/.output/public/_nuxt/{BTvE9qca.js → Qo6oszaF.js} +1 -1
  105. package/.output/public/_nuxt/{Cd8r0xk5.js → T5UuMUxA.js} +1 -1
  106. package/.output/public/_nuxt/UY8pjaZA.js +1 -0
  107. package/.output/public/_nuxt/{B6s20NbT.js → V9p3z39z.js} +1 -1
  108. package/.output/public/_nuxt/{CJEp4i0N.js → VACXezo0.js} +1 -1
  109. package/.output/public/_nuxt/{CrOA9onF.js → YmCeJkZ2.js} +1 -1
  110. package/.output/public/_nuxt/builds/latest.json +1 -1
  111. package/.output/public/_nuxt/builds/meta/70224ee0-4d1f-45d2-b380-2ecb18064bf1.json +1 -0
  112. package/.output/public/_nuxt/entry.DzPSf_u5.css +1 -0
  113. package/.output/public/_nuxt/fXUwH_3d.js +1 -0
  114. package/.output/public/_nuxt/{t-juTK3X.js → opwuUqHG.js} +1 -1
  115. package/.output/public/_nuxt/{B_mN5eMV.js → opyDpgSw.js} +1 -1
  116. package/.output/public/_nuxt/{HwFFbACq.js → sVV8xB9f.js} +1 -1
  117. package/.output/public/_nuxt/{DSvBQHzW.js → xa5UHCot.js} +1 -1
  118. package/.output/server/chunks/_/collect.mjs +1 -1
  119. package/.output/server/chunks/_/markers.mjs +1 -1
  120. package/.output/server/chunks/_/quarantine.mjs +1 -1
  121. package/.output/server/chunks/_/users.mjs +1 -1
  122. package/.output/server/chunks/build/{Alert-DAb8nKVs.mjs → Alert-He-UxEt6.mjs} +2 -2
  123. package/.output/server/chunks/build/Alert-He-UxEt6.mjs.map +1 -0
  124. package/.output/server/chunks/build/{Breadcrumb-DJp5WvUM.mjs → Breadcrumb-DEP2dVCZ.mjs} +3 -3
  125. package/.output/server/chunks/build/Breadcrumb-DEP2dVCZ.mjs.map +1 -0
  126. package/.output/server/chunks/build/{BreadcrumbNav-BrQwfL8G.mjs → BreadcrumbNav-y6nMDYcR.mjs} +3 -3
  127. package/.output/server/chunks/build/BreadcrumbNav-y6nMDYcR.mjs.map +1 -0
  128. package/.output/server/chunks/build/{BrowserBadge-Djw_e_I9.mjs → BrowserBadge-DIASU8Gf.mjs} +6 -66
  129. package/.output/server/chunks/build/BrowserBadge-DIASU8Gf.mjs.map +1 -0
  130. package/.output/server/chunks/build/{ChartCard-B2gd_8HP.mjs → ChartCard-ZTsCvItQ.mjs} +2 -2
  131. package/.output/server/chunks/build/ChartCard-ZTsCvItQ.mjs.map +1 -0
  132. package/.output/server/chunks/build/{Checkbox-C1khEdTh.mjs → Checkbox-BisdHf8n.mjs} +7 -7
  133. package/.output/server/chunks/build/Checkbox-BisdHf8n.mjs.map +1 -0
  134. package/.output/server/chunks/build/{CodeBlock-CjnDrO3Y.mjs → CodeBlock-B8BNtZAe.mjs} +3 -3
  135. package/.output/server/chunks/build/CodeBlock-B8BNtZAe.mjs.map +1 -0
  136. package/.output/server/chunks/build/{DashboardNavbar-DYtmVlhy.mjs → DashboardNavbar-D7-3zBUU.mjs} +3 -3
  137. package/.output/server/chunks/build/DashboardNavbar-D7-3zBUU.mjs.map +1 -0
  138. package/.output/server/chunks/build/{DashboardSidebarToggle-BPNxODwj.mjs → DashboardSidebarToggle-C3HdHvlE.mjs} +3 -3
  139. package/.output/server/chunks/build/DashboardSidebarToggle-C3HdHvlE.mjs.map +1 -0
  140. package/.output/server/chunks/build/{DataLocationCard-2B-sVSMr.mjs → DataLocationCard-CC2-lHiP.mjs} +3 -3
  141. package/.output/server/chunks/build/DataLocationCard-CC2-lHiP.mjs.map +1 -0
  142. package/.output/server/chunks/build/{MetaStripGroup-BBByVvpR.mjs → DesktopRunLocallyButton-iNzrDsEs.mjs} +601 -623
  143. package/.output/server/chunks/build/DesktopRunLocallyButton-iNzrDsEs.mjs.map +1 -0
  144. package/.output/server/chunks/build/{DiagnosisPanel-D6QO30FQ.mjs → DiagnosisPanel-BVb2LgHu.mjs} +6 -6
  145. package/.output/server/chunks/build/DiagnosisPanel-BVb2LgHu.mjs.map +1 -0
  146. package/.output/server/chunks/build/{DiagnosisResult-ujB5Lt2A.mjs → DiagnosisResult-xVgZlfKK.mjs} +9 -9
  147. package/.output/server/chunks/build/DiagnosisResult-xVgZlfKK.mjs.map +1 -0
  148. package/.output/server/chunks/build/{EntityLinks-F8_kC-IH.mjs → EntityLinks-Dzn73fbq.mjs} +3 -3
  149. package/.output/server/chunks/build/EntityLinks-Dzn73fbq.mjs.map +1 -0
  150. package/.output/server/chunks/build/{EnvManagedBadge-D6e-10M9.mjs → EnvManagedBadge-C-agmABK.mjs} +3 -3
  151. package/.output/server/chunks/build/EnvManagedBadge-C-agmABK.mjs.map +1 -0
  152. package/.output/server/chunks/build/{FeatureUnavailable-BMw4euTk.mjs → FeatureUnavailable-DHFkwI7t.mjs} +2 -2
  153. package/.output/server/chunks/build/FeatureUnavailable-DHFkwI7t.mjs.map +1 -0
  154. package/.output/server/chunks/build/{FormField-QptK0rPg.mjs → FormField-GYHKiSI6.mjs} +2 -2
  155. package/.output/server/chunks/build/FormField-GYHKiSI6.mjs.map +1 -0
  156. package/.output/server/chunks/build/{GetStartedWizard-DxT8T14Y.mjs → GetStartedWizard-BpcGYsm2.mjs} +3 -3
  157. package/.output/server/chunks/build/GetStartedWizard-BpcGYsm2.mjs.map +1 -0
  158. package/.output/server/chunks/build/{HelpHint-C5Ru8BCc.mjs → HelpHint-plioHKA0.mjs} +29 -2
  159. package/.output/server/chunks/build/HelpHint-plioHKA0.mjs.map +1 -0
  160. package/.output/server/chunks/build/MetaStripGroup-A0a72vt5.mjs +193 -0
  161. package/.output/server/chunks/build/MetaStripGroup-A0a72vt5.mjs.map +1 -0
  162. package/.output/server/chunks/build/{Modal-BacZmQCX.mjs → Modal-hKLvVFNp.mjs} +2 -2
  163. package/.output/server/chunks/build/Modal-hKLvVFNp.mjs.map +1 -0
  164. package/.output/server/chunks/build/{NavigationMenu-sTiKSWDm.mjs → NavigationMenu-RfBOyS32.mjs} +5 -5
  165. package/.output/server/chunks/build/NavigationMenu-RfBOyS32.mjs.map +1 -0
  166. package/.output/server/chunks/build/{OpenInIdeLink-Crc8y0Yx.mjs → OpenInIdeLink-Jp6SzEtD.mjs} +5 -5
  167. package/.output/server/chunks/build/{OpenInIdeLink-Crc8y0Yx.mjs.map → OpenInIdeLink-Jp6SzEtD.mjs.map} +1 -1
  168. package/.output/server/chunks/build/{ProjectTestCasesTable-DwjqZ2i5.mjs → ProjectTestCasesTable-DxOTfhi4.mjs} +8 -8
  169. package/.output/server/chunks/build/{ProjectTestCasesTable-DwjqZ2i5.mjs.map → ProjectTestCasesTable-DxOTfhi4.mjs.map} +1 -1
  170. package/.output/server/chunks/build/{RovingFocusItem--OEHI2P3.mjs → RovingFocusItem-BOSx1Z9Z.mjs} +2 -2
  171. package/.output/server/chunks/build/RovingFocusItem-BOSx1Z9Z.mjs.map +1 -0
  172. package/.output/server/chunks/build/RunReports-nuLb-Nm3.mjs +1 -1
  173. package/.output/server/chunks/build/{SectionCard-C753B3Yo.mjs → SectionCard-DHAFvJxm.mjs} +2 -2
  174. package/.output/server/chunks/build/SectionCard-DHAFvJxm.mjs.map +1 -0
  175. package/.output/server/chunks/build/{Select-BAyYwPuo.mjs → Select-CEyw7HGK.mjs} +4 -4
  176. package/.output/server/chunks/build/Select-CEyw7HGK.mjs.map +1 -0
  177. package/.output/server/chunks/build/{SelectMenu-zE_AhMX8.mjs → SelectMenu-C02Hs2_F.mjs} +5 -5
  178. package/.output/server/chunks/build/{SelectMenu-zE_AhMX8.mjs.map → SelectMenu-C02Hs2_F.mjs.map} +1 -1
  179. package/.output/server/chunks/build/{Separator-BbgCfKKJ.mjs → Separator-lrN70ODV.mjs} +2 -2
  180. package/.output/server/chunks/build/Separator-lrN70ODV.mjs.map +1 -0
  181. package/.output/server/chunks/build/{SettingsField-D-VriK9X.mjs → SettingsField-tRmytcEJ.mjs} +5 -5
  182. package/.output/server/chunks/build/SettingsField-tRmytcEJ.mjs.map +1 -0
  183. package/.output/server/chunks/build/{Slideover-CNbGvbUF.mjs → Slideover-D6cRIqch.mjs} +3 -3
  184. package/.output/server/chunks/build/Slideover-D6cRIqch.mjs.map +1 -0
  185. package/.output/server/chunks/build/{Switch-DdkA3Fii.mjs → Switch-R2n82ncQ.mjs} +4 -4
  186. package/.output/server/chunks/build/Switch-R2n82ncQ.mjs.map +1 -0
  187. package/.output/server/chunks/build/{Table-CfDVAuUJ.mjs → Table-qZdnm9t2.mjs} +3 -3
  188. package/.output/server/chunks/build/Table-qZdnm9t2.mjs.map +1 -0
  189. package/.output/server/chunks/build/{Tabs-BCOhHEB9.mjs → Tabs-BDP7MWl4.mjs} +3 -3
  190. package/.output/server/chunks/build/Tabs-BDP7MWl4.mjs.map +1 -0
  191. package/.output/server/chunks/build/{TestStatusBar-wquHQqtp.mjs → TestStatusBar-CvsmKJ4D.mjs} +2 -2
  192. package/.output/server/chunks/build/TestStatusBar-CvsmKJ4D.mjs.map +1 -0
  193. package/.output/server/chunks/build/{Textarea-Ohs6QTXf.mjs → Textarea-DpmpM-lN.mjs} +2 -2
  194. package/.output/server/chunks/build/Textarea-DpmpM-lN.mjs.map +1 -0
  195. package/.output/server/chunks/build/{Tooltip-BRBnl4pE.mjs → Tooltip-BI3WQErw.mjs} +3 -3
  196. package/.output/server/chunks/build/Tooltip-BI3WQErw.mjs.map +1 -0
  197. package/.output/server/chunks/build/{VisuallyHiddenInput-BHvzNumK.mjs → VisuallyHiddenInput-D4E5aJCQ.mjs} +2 -2
  198. package/.output/server/chunks/build/VisuallyHiddenInput-D4E5aJCQ.mjs.map +1 -0
  199. package/.output/server/chunks/build/{_id_-BesWjK_d.mjs → _id_-26komi8G.mjs} +47 -37
  200. package/.output/server/chunks/build/{_id_-BesWjK_d.mjs.map → _id_-26komi8G.mjs.map} +1 -1
  201. package/.output/server/chunks/build/{_id_-CQ0lolEK.mjs → _id_-T965GKYC.mjs} +58 -15
  202. package/.output/server/chunks/build/_id_-T965GKYC.mjs.map +1 -0
  203. package/.output/server/chunks/build/{_id_-CGs0u8Fr.mjs → _id_-w7YCSiiy.mjs} +70 -41
  204. package/.output/server/chunks/build/{_id_-CGs0u8Fr.mjs.map → _id_-w7YCSiiy.mjs.map} +1 -1
  205. package/.output/server/chunks/build/{_id_-D1-06Fcl.mjs → _id_-wiULjAVc.mjs} +44 -40
  206. package/.output/server/chunks/build/{_id_-D1-06Fcl.mjs.map → _id_-wiULjAVc.mjs.map} +1 -1
  207. package/.output/server/chunks/build/{about-DdyOj-dj.mjs → about-B3V_OEiu.mjs} +5 -5
  208. package/.output/server/chunks/build/about-B3V_OEiu.mjs.map +1 -0
  209. package/.output/server/chunks/build/{account-7aVMKekZ.mjs → account-DpBdYE46.mjs} +6 -6
  210. package/.output/server/chunks/build/account-DpBdYE46.mjs.map +1 -0
  211. package/.output/server/chunks/build/{ai-zw3T9b5u.mjs → ai-DYhpzbqp.mjs} +16 -16
  212. package/.output/server/chunks/build/{ai-zw3T9b5u.mjs.map → ai-DYhpzbqp.mjs.map} +1 -1
  213. package/.output/server/chunks/build/{analytics-CeCzKwEX.mjs → analytics-CZJEU0an.mjs} +17 -17
  214. package/.output/server/chunks/build/{analytics-CeCzKwEX.mjs.map → analytics-CZJEU0an.mjs.map} +1 -1
  215. package/.output/server/chunks/build/client.precomputed.mjs +1 -1
  216. package/.output/server/chunks/build/{db.client-Bdqk_eYQ.mjs → db.client-DijpEH6i.mjs} +3 -1
  217. package/.output/server/chunks/build/db.client-DijpEH6i.mjs.map +1 -0
  218. package/.output/server/chunks/build/{default-CkyAx_Mu.mjs → default-CQa_bmAf.mjs} +505 -89
  219. package/.output/server/chunks/build/default-CQa_bmAf.mjs.map +1 -0
  220. package/.output/server/chunks/build/{docs-Dhj-wEks.mjs → docs-C8bndVXg.mjs} +11 -11
  221. package/.output/server/chunks/build/{docs-Dhj-wEks.mjs.map → docs-C8bndVXg.mjs.map} +1 -1
  222. package/.output/server/chunks/build/{edit-CVz_gdoe.mjs → edit-BdfF9er2.mjs} +12 -12
  223. package/.output/server/chunks/build/edit-BdfF9er2.mjs.map +1 -0
  224. package/.output/server/chunks/build/{fetch-Be-j7hF1.mjs → fetch-tkz5_OA-.mjs} +3 -3
  225. package/.output/server/chunks/build/fetch-tkz5_OA-.mjs.map +1 -0
  226. package/.output/server/chunks/build/{forgot-password-CwdjL7BO.mjs → forgot-password-swZRcvXE.mjs} +3 -3
  227. package/.output/server/chunks/build/forgot-password-swZRcvXE.mjs.map +1 -0
  228. package/.output/server/chunks/build/{import-DyQEw4V3.mjs → import-B27Sv7h5.mjs} +11 -11
  229. package/.output/server/chunks/build/import-B27Sv7h5.mjs.map +1 -0
  230. package/.output/server/chunks/build/{index-DcnICCZU.mjs → index-BdZmxLtC.mjs} +17 -17
  231. package/.output/server/chunks/build/{index-DcnICCZU.mjs.map → index-BdZmxLtC.mjs.map} +1 -1
  232. package/.output/server/chunks/build/{index-D7Bmj6bq.mjs → index-C7m32bRI.mjs} +9 -9
  233. package/.output/server/chunks/build/index-C7m32bRI.mjs.map +1 -0
  234. package/.output/server/chunks/build/{index-DghAFpNR.mjs → index-Dq6nk6OB.mjs} +385 -104
  235. package/.output/server/chunks/build/index-Dq6nk6OB.mjs.map +1 -0
  236. package/.output/server/chunks/build/{isValueEqualOrExist-D2qw9YEr.mjs → isValueEqualOrExist-D4lZ8uRY.mjs} +3 -3
  237. package/.output/server/chunks/build/isValueEqualOrExist-D4lZ8uRY.mjs.map +1 -0
  238. package/.output/server/chunks/build/{login-rXKF63j6.mjs → login-hxCF06JT.mjs} +5 -5
  239. package/.output/server/chunks/build/login-hxCF06JT.mjs.map +1 -0
  240. package/.output/server/chunks/build/{mcp-ByNvFy4o.mjs → mcp-BVW1llyW.mjs} +12 -12
  241. package/.output/server/chunks/build/mcp-BVW1llyW.mjs.map +1 -0
  242. package/.output/server/chunks/build/{notifications-CbLAZnKJ.mjs → notifications-Dn-evqXM.mjs} +11 -11
  243. package/.output/server/chunks/build/notifications-Dn-evqXM.mjs.map +1 -0
  244. package/.output/server/chunks/build/{performance-C93MEPaZ.mjs → performance-CV8qm94u.mjs} +10 -10
  245. package/.output/server/chunks/build/performance-CV8qm94u.mjs.map +1 -0
  246. package/.output/server/chunks/build/{pr-feedback-DKCB0bDE.mjs → pr-feedback-gKDz8LyA.mjs} +9 -9
  247. package/.output/server/chunks/build/pr-feedback-gKDz8LyA.mjs.map +1 -0
  248. package/.output/server/chunks/build/{reset-password-BBoHKMqD.mjs → reset-password-DtEISa1I.mjs} +3 -3
  249. package/.output/server/chunks/build/reset-password-DtEISa1I.mjs.map +1 -0
  250. package/.output/server/chunks/build/server.mjs +87 -33
  251. package/.output/server/chunks/build/{settings-DiG0JjzC.mjs → settings-BJDnuLpc.mjs} +8 -8
  252. package/.output/server/chunks/build/settings-BJDnuLpc.mjs.map +1 -0
  253. package/.output/server/chunks/build/settings-metadata-DnAK4Rzg.mjs +1 -1
  254. package/.output/server/chunks/build/{setup-0-1O6Hjz.mjs → setup-BO9tXa_G.mjs} +14 -14
  255. package/.output/server/chunks/build/{setup-0-1O6Hjz.mjs.map → setup-BO9tXa_G.mjs.map} +1 -1
  256. package/.output/server/chunks/build/{storage-3JiFJ843.mjs → storage-zN92cA9q.mjs} +11 -11
  257. package/.output/server/chunks/build/storage-zN92cA9q.mjs.map +1 -0
  258. package/.output/server/chunks/build/{tags-CqYcp7js.mjs → tags-CJFnoyQc.mjs} +5 -5
  259. package/.output/server/chunks/build/tags-CJFnoyQc.mjs.map +1 -0
  260. package/.output/server/chunks/build/{test-cases-y1HSgPX2.mjs → test-cases-0Q6rT73d.mjs} +18 -18
  261. package/.output/server/chunks/build/test-cases-0Q6rT73d.mjs.map +1 -0
  262. package/.output/server/chunks/build/{test-functions-D2ju95Ly.mjs → test-functions-DVRJgiWo.mjs} +9 -9
  263. package/.output/server/chunks/build/test-functions-DVRJgiWo.mjs.map +1 -0
  264. package/.output/server/chunks/build/{useCopyRich-CVFeYfkG.mjs → useCopyRich-BM9GTjJi.mjs} +75 -29
  265. package/.output/server/chunks/build/{useCopyRich-CVFeYfkG.mjs.map → useCopyRich-BM9GTjJi.mjs.map} +1 -1
  266. package/.output/server/chunks/build/useDesktopLocalRuns-k7Gw3Fv3.mjs +319 -0
  267. package/.output/server/chunks/build/useDesktopLocalRuns-k7Gw3Fv3.mjs.map +1 -0
  268. package/.output/server/chunks/build/useDesktopProjectLink-WwLte59P.mjs +67 -0
  269. package/.output/server/chunks/build/useDesktopProjectLink-WwLte59P.mjs.map +1 -0
  270. package/.output/server/chunks/build/{useFormControl-CZ9So7iX.mjs → useFormControl-8skMOTIf.mjs} +2 -2
  271. package/.output/server/chunks/build/useFormControl-8skMOTIf.mjs.map +1 -0
  272. package/.output/server/chunks/build/{useOpenInIde--6Me0WlL.mjs → useOpenInIde-D74FmDNg.mjs} +2 -2
  273. package/.output/server/chunks/build/useOpenInIde-D74FmDNg.mjs.map +1 -0
  274. package/.output/server/chunks/build/{users-IdmY9JZV.mjs → users-C9bjOBde.mjs} +6 -6
  275. package/.output/server/chunks/build/users-C9bjOBde.mjs.map +1 -0
  276. package/.output/server/chunks/nitro/nitro.mjs +982 -664
  277. package/.output/server/chunks/nitro/nitro.mjs.map +1 -1
  278. package/.output/server/chunks/routes/__piwi/session.get.mjs +1 -1
  279. package/.output/server/chunks/routes/api/ai/step-resolution.post.mjs +88 -0
  280. package/.output/server/chunks/routes/api/ai/step-resolution.post.mjs.map +1 -0
  281. package/.output/server/chunks/routes/api/analytics/_widget_.get.mjs +1 -1
  282. package/.output/server/chunks/routes/api/auth/change-password.post.mjs +1 -1
  283. package/.output/server/chunks/routes/api/auth/forgot-password.post.mjs +1 -1
  284. package/.output/server/chunks/routes/api/auth/login.post.mjs +1 -1
  285. package/.output/server/chunks/routes/api/auth/logout.post.mjs +1 -1
  286. package/.output/server/chunks/routes/api/auth/me.get.mjs +1 -1
  287. package/.output/server/chunks/routes/api/auth/oauth/_provider/callback.get.mjs +1 -1
  288. package/.output/server/chunks/routes/api/auth/oauth/_provider/login.get.mjs +1 -1
  289. package/.output/server/chunks/routes/api/auth/oauth/_provider/unlink.post.mjs +1 -1
  290. package/.output/server/chunks/routes/api/auth/reset-password.post.mjs +1 -1
  291. package/.output/server/chunks/routes/api/auth/send-verify-email.post.mjs +1 -1
  292. package/.output/server/chunks/routes/api/auth/setup.get.mjs +1 -1
  293. package/.output/server/chunks/routes/api/auth/setup.post.mjs +1 -1
  294. package/.output/server/chunks/routes/api/auth/verify-email.get.mjs +1 -1
  295. package/.output/server/chunks/routes/api/channels/_id/test.post.mjs +1 -1
  296. package/.output/server/chunks/routes/api/channels/_id_.delete.mjs +1 -1
  297. package/.output/server/chunks/routes/api/cluster-merge-suggestions/_id/approve.post.mjs +1 -1
  298. package/.output/server/chunks/routes/api/cluster-merge-suggestions/_id/reject.post.mjs +1 -1
  299. package/.output/server/chunks/routes/api/desktop/import-local.post.mjs +1 -1
  300. package/.output/server/chunks/routes/api/failure-clusters/_id/base-commit.patch.mjs +1 -1
  301. package/.output/server/chunks/routes/api/failure-clusters/_id/branches.get.mjs +1 -1
  302. package/.output/server/chunks/routes/api/failure-clusters/_id/commit-diff.get.mjs +1 -1
  303. package/.output/server/chunks/routes/api/failure-clusters/_id/commits.get.mjs +1 -1
  304. package/.output/server/chunks/routes/api/failure-clusters/_id/context.get.mjs +1 -1
  305. package/.output/server/chunks/routes/api/failure-clusters/_id/diagnose/stream.post.mjs +1 -1
  306. package/.output/server/chunks/routes/api/failure-clusters/_id/diagnose.post.mjs +1 -1
  307. package/.output/server/chunks/routes/api/failure-clusters/_id/diagnoses.get.mjs +1 -1
  308. package/.output/server/chunks/routes/api/failure-clusters/_id/diagnosis.get.mjs +1 -1
  309. package/.output/server/chunks/routes/api/failure-clusters/_id/export.get.mjs +1 -1
  310. package/.output/server/chunks/routes/api/failure-clusters/_id/extract-cases.post.mjs +1 -1
  311. package/.output/server/chunks/routes/api/failure-clusters/_id/fix-plan.get.mjs +1 -1
  312. package/.output/server/chunks/routes/api/failure-clusters/_id/status.patch.mjs +1 -1
  313. package/.output/server/chunks/routes/api/failure-clusters/_id_.get.mjs +1 -1
  314. package/.output/server/chunks/routes/api/failure-diagnoses/_id/feedback.patch.mjs +1 -1
  315. package/.output/server/chunks/routes/api/files/_...path_.get.mjs +1 -1
  316. package/.output/server/chunks/routes/api/health.get.mjs +1 -1
  317. package/.output/server/chunks/routes/api/index.get.mjs +1 -1
  318. package/.output/server/chunks/routes/api/index.get2.mjs +1 -1
  319. package/.output/server/chunks/routes/api/index.get3.mjs +1 -1
  320. package/.output/server/chunks/routes/api/index.get4.mjs +1 -1
  321. package/.output/server/chunks/routes/api/index.get5.mjs +1 -1
  322. package/.output/server/chunks/routes/api/index.post.mjs +1 -1
  323. package/.output/server/chunks/routes/api/index.post2.mjs +1 -1
  324. package/.output/server/chunks/routes/api/index.post3.mjs +1 -1
  325. package/.output/server/chunks/routes/api/index.post4.mjs +1 -1
  326. package/.output/server/chunks/routes/api/index.post5.mjs +1 -1
  327. package/.output/server/chunks/routes/api/index.post6.mjs +1 -1
  328. package/.output/server/chunks/routes/api/links/_id/refresh.post.mjs +1 -1
  329. package/.output/server/chunks/routes/api/links/_id_.delete.mjs +1 -1
  330. package/.output/server/chunks/routes/api/links/_id_.patch.mjs +1 -1
  331. package/.output/server/chunks/routes/api/markers/_id_.delete.mjs +1 -1
  332. package/.output/server/chunks/routes/api/markers/_id_.put.mjs +1 -1
  333. package/.output/server/chunks/routes/api/notifications/stream.get.mjs +1 -1
  334. package/.output/server/chunks/routes/api/projects/_id/ai-steps.get.mjs +63 -0
  335. package/.output/server/chunks/routes/api/projects/_id/ai-steps.get.mjs.map +1 -0
  336. package/.output/server/chunks/routes/api/projects/_id/cluster-merge-suggestions.get.mjs +1 -1
  337. package/.output/server/chunks/routes/api/projects/_id/failure-clusters.get.mjs +1 -1
  338. package/.output/server/chunks/routes/api/projects/_id/flaky-classify.post.mjs +1 -1
  339. package/.output/server/chunks/routes/api/projects/_id/flaky-tests.get.mjs +1 -1
  340. package/.output/server/chunks/routes/api/projects/_id/latest-run.get.mjs +1 -1
  341. package/.output/server/chunks/routes/api/projects/_id/markers.get.mjs +1 -1
  342. package/.output/server/chunks/routes/api/projects/_id/markers.post.mjs +1 -1
  343. package/.output/server/chunks/routes/api/projects/_id/members.get.mjs +1 -1
  344. package/.output/server/chunks/routes/api/projects/_id/members.put.mjs +1 -1
  345. package/.output/server/chunks/routes/api/projects/_id/performance.get.mjs +1 -1
  346. package/.output/server/chunks/routes/api/projects/_id/quarantine/_testCaseId_.delete.mjs +1 -1
  347. package/.output/server/chunks/routes/api/projects/_id/quarantine.get.mjs +1 -1
  348. package/.output/server/chunks/routes/api/projects/_id/quarantine.post.mjs +1 -1
  349. package/.output/server/chunks/routes/api/projects/_id/slow-tests.get.mjs +1 -1
  350. package/.output/server/chunks/routes/api/projects/_id/spec-health.get.mjs +1 -1
  351. package/.output/server/chunks/routes/api/projects/_id/test-cases.get.mjs +1 -1
  352. package/.output/server/chunks/routes/api/projects/_id/test-functions/extract.post.mjs +1 -1
  353. package/.output/server/chunks/routes/api/projects/_id/test-functions/validate-proposal.post.mjs +1 -1
  354. package/.output/server/chunks/routes/api/projects/_id/test-functions.get.mjs +1 -1
  355. package/.output/server/chunks/routes/api/projects/_id/test-functions.post.mjs +1 -1
  356. package/.output/server/chunks/routes/api/projects/_id/timeout-opportunities.get.mjs +1 -1
  357. package/.output/server/chunks/routes/api/projects/_id_.delete.mjs +1 -1
  358. package/.output/server/chunks/routes/api/projects/_id_.get.mjs +1 -1
  359. package/.output/server/chunks/routes/api/projects/_id_.put.mjs +1 -1
  360. package/.output/server/chunks/routes/api/projects/menu.get.mjs +1 -1
  361. package/.output/server/chunks/routes/api/projects/overview.get.mjs +1 -1
  362. package/.output/server/chunks/routes/api/projects.get.mjs +1 -1
  363. package/.output/server/chunks/routes/api/search.get.mjs +1 -1
  364. package/.output/server/chunks/routes/api/settings/ai/limits.get.mjs +1 -1
  365. package/.output/server/chunks/routes/api/settings/ai/limits.put.mjs +1 -1
  366. package/.output/server/chunks/routes/api/settings/ai/test.post.mjs +1 -1
  367. package/.output/server/chunks/routes/api/settings/ai/usage.get.mjs +1 -1
  368. package/.output/server/chunks/routes/api/settings/ai.get.mjs +1 -1
  369. package/.output/server/chunks/routes/api/settings/ai.put.mjs +1 -1
  370. package/.output/server/chunks/routes/api/settings/pr-feedback.get.mjs +1 -1
  371. package/.output/server/chunks/routes/api/settings/pr-feedback.put.mjs +1 -1
  372. package/.output/server/chunks/routes/api/settings/smtp/test.post.mjs +1 -1
  373. package/.output/server/chunks/routes/api/settings/smtp.get.mjs +1 -1
  374. package/.output/server/chunks/routes/api/settings/timeout-hygiene.get.mjs +1 -1
  375. package/.output/server/chunks/routes/api/settings/timeout-hygiene.put.mjs +1 -1
  376. package/.output/server/chunks/routes/api/settings/wasted-waits.get.mjs +1 -1
  377. package/.output/server/chunks/routes/api/settings/wasted-waits.put.mjs +1 -1
  378. package/.output/server/chunks/routes/api/setup-status.get.mjs +1 -1
  379. package/.output/server/chunks/routes/api/stream.get.mjs +1 -1
  380. package/.output/server/chunks/routes/api/subscriptions/_id_.delete.mjs +1 -1
  381. package/.output/server/chunks/routes/api/subscriptions/_id_.patch.mjs +1 -1
  382. package/.output/server/chunks/routes/api/tags/_id_.delete.mjs +1 -1
  383. package/.output/server/chunks/routes/api/tags/_id_.put.mjs +1 -1
  384. package/.output/server/chunks/routes/api/test-cases/_id/history.get.mjs +1 -1
  385. package/.output/server/chunks/routes/api/test-cases/_id/stability-trend.get.mjs +1 -1
  386. package/.output/server/chunks/routes/api/test-cases/_id_.get.mjs +1 -1
  387. package/.output/server/chunks/routes/api/test-functions/_id_.delete.mjs +1 -1
  388. package/.output/server/chunks/routes/api/test-functions/_id_.put.mjs +1 -1
  389. package/.output/server/chunks/routes/api/test-run-cases/_id/diagnose.post.mjs +1 -1
  390. package/.output/server/chunks/routes/api/test-run-cases/_id/diagnosis-context.get.mjs +1 -1
  391. package/.output/server/chunks/routes/api/test-run-cases/_id/diagnosis.get.mjs +1 -1
  392. package/.output/server/chunks/routes/api/test-run-cases/_id/export.get.mjs +1 -1
  393. package/.output/server/chunks/routes/api/test-run-cases/_id/traces.get.mjs +1 -1
  394. package/.output/server/chunks/routes/api/test-run-cases/_id_.get.mjs +1 -1
  395. package/.output/server/chunks/routes/api/test-runs/_id/begin.post.mjs +1 -1
  396. package/.output/server/chunks/routes/api/test-runs/_id/case-files.post.mjs +1 -1
  397. package/.output/server/chunks/routes/api/test-runs/_id/cases/_caseId/dom-snapshot.get.mjs +1 -1
  398. package/.output/server/chunks/routes/api/test-runs/_id/cases/_caseId/environment-diff.get.mjs +1 -1
  399. package/.output/server/chunks/routes/api/test-runs/_id/cases/_caseId/locator-healing.get.mjs +1 -1
  400. package/.output/server/chunks/routes/api/test-runs/_id/cases/_caseId/locator-pick.post.mjs +1 -1
  401. package/.output/server/chunks/routes/api/test-runs/_id/cases/_caseId/trace-network-body.get.mjs +1 -1
  402. package/.output/server/chunks/routes/api/test-runs/_id/cases/_caseId/trace-network.get.mjs +1 -1
  403. package/.output/server/chunks/routes/api/test-runs/_id/cases/_caseId/trace-stacks.get.mjs +1 -1
  404. package/.output/server/chunks/routes/api/test-runs/_id/cases/_caseId/visual-diff.get.mjs +1 -1
  405. package/.output/server/chunks/routes/api/test-runs/_id/events.post.mjs +1 -1
  406. package/.output/server/chunks/routes/api/test-runs/_id/failure-groups.get.mjs +1 -1
  407. package/.output/server/chunks/routes/api/test-runs/_id/finish.post.mjs +1 -1
  408. package/.output/server/chunks/routes/api/test-runs/_id/gate.post.mjs +1 -1
  409. package/.output/server/chunks/routes/api/test-runs/_id/heartbeat.post.mjs +1 -1
  410. package/.output/server/chunks/routes/api/test-runs/_id/insights.get.mjs +1 -1
  411. package/.output/server/chunks/routes/api/test-runs/_id/network-requests.get.mjs +1 -1
  412. package/.output/server/chunks/routes/api/test-runs/_id/regression-context.get.mjs +1 -1
  413. package/.output/server/chunks/routes/api/test-runs/_id/stream.get.mjs +1 -1
  414. package/.output/server/chunks/routes/api/test-runs/_id/summary.get.mjs +1 -1
  415. package/.output/server/chunks/routes/api/test-runs/_id_.delete.mjs +1 -1
  416. package/.output/server/chunks/routes/api/test-runs/_id_.get.mjs +1 -1
  417. package/.output/server/chunks/routes/api/test-runs/_id_.patch.mjs +1 -1
  418. package/.output/server/chunks/routes/api/test-runs/import/check.post.mjs +1 -1
  419. package/.output/server/chunks/routes/api/test-runs/import.post.mjs +1 -1
  420. package/.output/server/chunks/routes/api/test-runs/recent.get.mjs +1 -1
  421. package/.output/server/chunks/routes/api/test-runs/setup.post.mjs +1 -1
  422. package/.output/server/chunks/routes/api/test-runs/start.post.mjs +1 -1
  423. package/.output/server/chunks/routes/api/test-runs/submit.post.mjs +3 -1
  424. package/.output/server/chunks/routes/api/test-runs/submit.post.mjs.map +1 -1
  425. package/.output/server/chunks/routes/api/test-runs/upload.post.mjs +2 -1
  426. package/.output/server/chunks/routes/api/test-runs/upload.post.mjs.map +1 -1
  427. package/.output/server/chunks/routes/api/tests/cleanup.delete.mjs +2 -1
  428. package/.output/server/chunks/routes/api/tests/cleanup.delete.mjs.map +1 -1
  429. package/.output/server/chunks/routes/api/traces/check.post.mjs +1 -1
  430. package/.output/server/chunks/routes/api/users/_id/api-keys/_keyId_.delete.mjs +1 -1
  431. package/.output/server/chunks/routes/api/users/_id/index.get.mjs +1 -1
  432. package/.output/server/chunks/routes/api/users/_id/index.post.mjs +1 -1
  433. package/.output/server/chunks/routes/api/users/_id/invite.post.mjs +1 -1
  434. package/.output/server/chunks/routes/api/users/_id/projects.get.mjs +1 -1
  435. package/.output/server/chunks/routes/api/users/_id/projects.put.mjs +1 -1
  436. package/.output/server/chunks/routes/api/users/_id_.delete.mjs +1 -1
  437. package/.output/server/chunks/routes/api/users/_id_.patch.mjs +1 -1
  438. package/.output/server/chunks/routes/api/version.get.mjs +1 -1
  439. package/.output/server/chunks/routes/mcp.post.mjs +1 -1
  440. package/.output/server/chunks/routes/renderer.mjs +1 -1
  441. package/.output/server/database/migrations/0045_productive_stingray.sql +1 -0
  442. package/.output/server/database/migrations/meta/0045_snapshot.json +3779 -0
  443. package/.output/server/database/migrations/meta/_journal.json +7 -0
  444. package/.output/server/database/migrations-pg/0046_gorgeous_hercules.sql +1 -0
  445. package/.output/server/database/migrations-pg/meta/0046_snapshot.json +4486 -0
  446. package/.output/server/database/migrations-pg/meta/_journal.json +7 -0
  447. package/.output/server/index.mjs +1 -1
  448. package/.output/server/package.json +1 -1
  449. package/package.json +1 -1
  450. package/.output/public/_nuxt/B-6GGrhr.js +0 -1
  451. package/.output/public/_nuxt/B9FSuKdA.js +0 -1
  452. package/.output/public/_nuxt/BaDhDBCV.js +0 -1
  453. package/.output/public/_nuxt/Bb7Uckln.js +0 -5
  454. package/.output/public/_nuxt/Be4c943G.js +0 -2
  455. package/.output/public/_nuxt/BpUXqOVj.js +0 -2
  456. package/.output/public/_nuxt/BtSJxOdh.js +0 -1
  457. package/.output/public/_nuxt/CI_q0F1O.js +0 -9
  458. package/.output/public/_nuxt/CScusXhF.js +0 -1
  459. package/.output/public/_nuxt/Cot8fIp5.js +0 -2
  460. package/.output/public/_nuxt/D0ROfwV0.js +0 -1
  461. package/.output/public/_nuxt/D4oheDIm.js +0 -4
  462. package/.output/public/_nuxt/DS2ANCQh.js +0 -1
  463. package/.output/public/_nuxt/DslnXfcH.js +0 -1
  464. package/.output/public/_nuxt/builds/meta/28bca36d-5571-4157-b1b8-7f62c934eed6.json +0 -1
  465. package/.output/public/_nuxt/entry.BAvBQY-h.css +0 -1
  466. package/.output/public/_nuxt/hzsG6cAc.js +0 -1
  467. package/.output/public/_nuxt/jjOqY9Tv.js +0 -1
  468. package/.output/public/_nuxt/xbO0VmDX.js +0 -1
  469. package/.output/server/chunks/build/Alert-DAb8nKVs.mjs.map +0 -1
  470. package/.output/server/chunks/build/Breadcrumb-DJp5WvUM.mjs.map +0 -1
  471. package/.output/server/chunks/build/BreadcrumbNav-BrQwfL8G.mjs.map +0 -1
  472. package/.output/server/chunks/build/BrowserBadge-Djw_e_I9.mjs.map +0 -1
  473. package/.output/server/chunks/build/ChartCard-B2gd_8HP.mjs.map +0 -1
  474. package/.output/server/chunks/build/Checkbox-C1khEdTh.mjs.map +0 -1
  475. package/.output/server/chunks/build/CodeBlock-CjnDrO3Y.mjs.map +0 -1
  476. package/.output/server/chunks/build/DashboardNavbar-DYtmVlhy.mjs.map +0 -1
  477. package/.output/server/chunks/build/DashboardSidebarToggle-BPNxODwj.mjs.map +0 -1
  478. package/.output/server/chunks/build/DataLocationCard-2B-sVSMr.mjs.map +0 -1
  479. package/.output/server/chunks/build/DiagnosisPanel-D6QO30FQ.mjs.map +0 -1
  480. package/.output/server/chunks/build/DiagnosisResult-ujB5Lt2A.mjs.map +0 -1
  481. package/.output/server/chunks/build/EntityLinks-F8_kC-IH.mjs.map +0 -1
  482. package/.output/server/chunks/build/EnvManagedBadge-D6e-10M9.mjs.map +0 -1
  483. package/.output/server/chunks/build/FeatureUnavailable-BMw4euTk.mjs.map +0 -1
  484. package/.output/server/chunks/build/FormField-QptK0rPg.mjs.map +0 -1
  485. package/.output/server/chunks/build/GetStartedWizard-DxT8T14Y.mjs.map +0 -1
  486. package/.output/server/chunks/build/HelpHint-C5Ru8BCc.mjs.map +0 -1
  487. package/.output/server/chunks/build/MetaStripGroup-BBByVvpR.mjs.map +0 -1
  488. package/.output/server/chunks/build/Modal-BacZmQCX.mjs.map +0 -1
  489. package/.output/server/chunks/build/NavigationMenu-sTiKSWDm.mjs.map +0 -1
  490. package/.output/server/chunks/build/RovingFocusItem--OEHI2P3.mjs.map +0 -1
  491. package/.output/server/chunks/build/SectionCard-C753B3Yo.mjs.map +0 -1
  492. package/.output/server/chunks/build/Select-BAyYwPuo.mjs.map +0 -1
  493. package/.output/server/chunks/build/Separator-BbgCfKKJ.mjs.map +0 -1
  494. package/.output/server/chunks/build/SettingsField-D-VriK9X.mjs.map +0 -1
  495. package/.output/server/chunks/build/Slideover-CNbGvbUF.mjs.map +0 -1
  496. package/.output/server/chunks/build/Switch-DdkA3Fii.mjs.map +0 -1
  497. package/.output/server/chunks/build/Table-CfDVAuUJ.mjs.map +0 -1
  498. package/.output/server/chunks/build/Tabs-BCOhHEB9.mjs.map +0 -1
  499. package/.output/server/chunks/build/TestStatusBar-wquHQqtp.mjs.map +0 -1
  500. package/.output/server/chunks/build/Textarea-Ohs6QTXf.mjs.map +0 -1
  501. package/.output/server/chunks/build/Tooltip-BRBnl4pE.mjs.map +0 -1
  502. package/.output/server/chunks/build/VisuallyHiddenInput-BHvzNumK.mjs.map +0 -1
  503. package/.output/server/chunks/build/_id_-CQ0lolEK.mjs.map +0 -1
  504. package/.output/server/chunks/build/about-DdyOj-dj.mjs.map +0 -1
  505. package/.output/server/chunks/build/account-7aVMKekZ.mjs.map +0 -1
  506. package/.output/server/chunks/build/db.client-Bdqk_eYQ.mjs.map +0 -1
  507. package/.output/server/chunks/build/default-CkyAx_Mu.mjs.map +0 -1
  508. package/.output/server/chunks/build/edit-CVz_gdoe.mjs.map +0 -1
  509. package/.output/server/chunks/build/fetch-Be-j7hF1.mjs.map +0 -1
  510. package/.output/server/chunks/build/forgot-password-CwdjL7BO.mjs.map +0 -1
  511. package/.output/server/chunks/build/import-DyQEw4V3.mjs.map +0 -1
  512. package/.output/server/chunks/build/index-D7Bmj6bq.mjs.map +0 -1
  513. package/.output/server/chunks/build/index-DghAFpNR.mjs.map +0 -1
  514. package/.output/server/chunks/build/isValueEqualOrExist-D2qw9YEr.mjs.map +0 -1
  515. package/.output/server/chunks/build/login-rXKF63j6.mjs.map +0 -1
  516. package/.output/server/chunks/build/mcp-ByNvFy4o.mjs.map +0 -1
  517. package/.output/server/chunks/build/notifications-CbLAZnKJ.mjs.map +0 -1
  518. package/.output/server/chunks/build/performance-C93MEPaZ.mjs.map +0 -1
  519. package/.output/server/chunks/build/pr-feedback-DKCB0bDE.mjs.map +0 -1
  520. package/.output/server/chunks/build/reset-password-BBoHKMqD.mjs.map +0 -1
  521. package/.output/server/chunks/build/settings-DiG0JjzC.mjs.map +0 -1
  522. package/.output/server/chunks/build/storage-3JiFJ843.mjs.map +0 -1
  523. package/.output/server/chunks/build/tags-CqYcp7js.mjs.map +0 -1
  524. package/.output/server/chunks/build/test-cases-y1HSgPX2.mjs.map +0 -1
  525. package/.output/server/chunks/build/test-functions-D2ju95Ly.mjs.map +0 -1
  526. package/.output/server/chunks/build/useFormControl-CZ9So7iX.mjs.map +0 -1
  527. package/.output/server/chunks/build/useOpenInIde--6Me0WlL.mjs.map +0 -1
  528. package/.output/server/chunks/build/users-IdmY9JZV.mjs.map +0 -1
@@ -0,0 +1,2 @@
1
+ import{d as fe,o as b,f as D,g as I,V as H,W as Z,k as n,X as ia,a2 as Ee,a3 as Me,b8 as nt,a6 as ze,bb as Xa,a4 as Ke,a5 as Ie,c as z,j as A,_ as ye,cb as ra,ac as Dt,i as N,q as K,F as de,y as ge,c4 as ua,v as E,a0 as Ae,a1 as De,h as R,cc as st,b9 as Be,ba as Le,a8 as Oe,B as Re,ak as ca,t as Q,r as U,cd as da,O as fa,as as pa,R as ha,A as Ue,ax as Bt,C as Za,bN as en,Y as tn,$ as an,J as re,L as ut,aw as nn,af as sn,ad as on,a7 as ot,bP as ln,bS as rn,c3 as un,bY as cn,m as oe,ag as dn,c7 as fn,ce as ma,an as va,H as qe,u as Lt,aU as pn,I as lt,aD as hn,ab as be,cf as mn,cg as vn,aP as ga,x as ya,bc as gn,aJ as ve,bd as yn,p as ke,aK as bn,bR as wn,E as Et,S as _n,c1 as kn,ch as xn,aS as Sn,a9 as ba,ci as $n,l as we,cj as Cn,s as wa,M as In,ar as Tn,ah as An,a as _a,w as ka,ck as Dn,b as Bn,cl as Ln,cm as En}from"./C5TrTuWv.js";import{a as xa,b as Mn,_ as On,c as Rn,p as jn}from"./BCGljaM0.js";import{_ as Mt}from"./DuOH5jcQ.js";import{_ as Fn}from"./BPXqL9vK.js";import{u as Sa,l as Pn}from"./Bn0jaRxI.js";import{u as zn}from"./UY8pjaZA.js";import{a as $a,I as Gt,V as Jt,J as qn}from"./CX5Q0dZ8.js";import{_ as Nn}from"./Bp3FRuEm.js";import{b as Kn,c as Un,g as Hn,D as Vn,a as Wn,d as ft,e as pt,f as Gn,_ as ct}from"./6Z_ZwH8I.js";import{i as Jn,L as Yn,a as Qn,b as Xn,c as Zn,d as es,e as ts,f as as,g as ns,_ as ss}from"./DvEsAuE9.js";import{a as os,_ as ls}from"./B69RP95P.js";import{_ as is}from"./Ce5_Tq63.js";import{_ as Ca}from"./DH5H1DJh.js";import{_ as Ia}from"./C-XjxjG5.js";import{_ as rs}from"./BrUBOQ0y.js";import{_ as us}from"./BBhrClA9.js";import{_ as cs}from"./BFxvHlO9.js";import{u as Ot}from"./T5UuMUxA.js";import{e as ds}from"./DMtrFQqi.js";import{u as Rt,s as fs}from"./Bme1UkOl.js";import{u as ps}from"./opwuUqHG.js";import{u as hs}from"./BVLqydCr.js";import"./CpcrljrH.js";import"./BmzxRbcg.js";import"./BjaRappk.js";import"./fXUwH_3d.js";import"./DaNC-xl1.js";import"./DMsm-RGQ.js";import"./V9p3z39z.js";import"./D_y2VS8k.js";import"./03FA4-rI.js";var ms=fe({__name:"ListboxGroupLabel",props:{for:{type:String,required:!1},asChild:{type:Boolean,required:!1},as:{type:null,required:!1,default:"div"}},setup(e){const t=e,s=Jn({id:""});return(o,l)=>(b(),D(n(ia),Z(t,{id:n(s).id}),{default:I(()=>[H(o.$slots,"default")]),_:3},16,["id"]))}}),vs=ms;const gs={slots:{base:"",label:"",trailing:"hidden lg:flex items-center gap-0.5 ms-auto"},variants:{collapsed:{true:{label:"hidden",trailing:"lg:hidden"}}}},ys=Object.assign({inheritAttrs:!1},{__name:"UDashboardSearchButton",props:{icon:{type:[String,Boolean],required:!1,skipCheck:!0},label:{type:String,required:!1},color:{type:null,required:!1,default:"neutral"},variant:{type:null,required:!1},collapsed:{type:Boolean,required:!1,default:!1},tooltip:{type:[Boolean,Object],required:!1,default:!1},kbds:{type:Array,required:!1,default:()=>["meta","k"]},ui:{type:Object,required:!1},class:{type:null,required:!1},activeColor:{type:null,required:!1},activeVariant:{type:null,required:!1},size:{type:null,required:!1},square:{type:Boolean,required:!1},block:{type:Boolean,required:!1},loadingAuto:{type:Boolean,required:!1},onClick:{type:[Function,Array],required:!1},avatar:{type:Object,required:!1},leading:{type:Boolean,required:!1},leadingIcon:{type:null,required:!1},trailing:{type:Boolean,required:!1},trailingIcon:{type:null,required:!1},loading:{type:Boolean,required:!1},loadingIcon:{type:null,required:!1},as:{type:null,required:!1},type:{type:null,required:!1},disabled:{type:Boolean,required:!1},exactActiveClass:{type:String,required:!1},viewTransition:{type:Boolean,required:!1}},setup(e){const t=e,s=Ee(),o=Me("dashboardSearchButton",t),[l,a]=nt(),i=()=>st(s,["trailing"]),u=ze(Xa(o,"icon","label","variant","collapsed","tooltip","kbds","class","ui")),r=Be(()=>Le(typeof o.tooltip=="boolean"?{}:o.tooltip,{delayDuration:0,content:{side:"right"}})),{t:g}=Ke(),m=Ie(),{toggleSearch:v}=xa({toggleSearch:()=>{}}),f=R(()=>Oe({extend:gs,...m.ui?.dashboardSearchButton||{}})({collapsed:o.collapsed}));return(c,p)=>(b(),z(de,null,[A(n(l),null,{default:I(()=>[A(ye,Z({icon:n(o).icon===!1?void 0:n(o).icon??n(m).ui.icons.search,label:n(o).label||n(g)("dashboardSearchButton.label"),variant:n(o).variant||(n(o).collapsed?"ghost":"outline")},{...n(u),...n(o).collapsed?{square:!0,"aria-label":n(o).label||n(g)("dashboardSearchButton.label")}:{},...c.$attrs},{class:f.value.base({class:[n(o).ui?.base,n(o).class]}),ui:n(ra)(f.value,n(o).ui),onClick:n(v)}),Dt({trailing:I(({ui:y})=>[N("span",{"data-slot":"trailing",class:K(f.value.trailing({class:n(o).ui?.trailing}))},[H(c.$slots,"trailing",{ui:y},()=>[n(o).kbds?.length?(b(!0),z(de,{key:0},ge(n(o).kbds,(L,O)=>(b(),D(ua,Z({key:O,variant:"subtle"},{ref_for:!0},typeof L=="string"?{value:L}:L),null,16))),128)):E("",!0)])],2)]),_:2},[ge(i(),(y,L)=>({name:L,fn:I(O=>[H(c.$slots,L,Ae(De(O)))])}))]),1040,["icon","label","variant","class","ui","onClick"])]),_:3}),n(o).collapsed&&n(o).tooltip?(b(),D(Mt,Z({key:0,text:n(o).label||n(g)("dashboardSearchButton.label")},r.value),{default:I(()=>[A(n(a))]),_:1},16,["text"])):(b(),D(n(a),{key:1}))],64))}}),bs={class:"truncate"},ws={key:0,class:"text-muted tabular-nums"},_s=fe({__name:"DesktopLocalRunsIndicator",props:{collapsed:{type:Boolean}},setup(e){const t=e,s=Sa(),o=U(!1);Re(()=>{o.value=!!ca()});const l=R(()=>s.runs.value.filter(u=>u.status==="running")),a=R(()=>`${l.value.length} local run${l.value.length===1?"":"s"}`),i=R(()=>{const u=l.value.filter(m=>m.progressTotal);if(u.length===0)return"";const r=u.reduce((m,v)=>m+v.progressDone,0),g=u.reduce((m,v)=>m+(v.progressTotal??0),0);return`${r}/${g}`});return(u,r)=>{const g=ye,m=Mt;return n(o)&&n(l).length>0?(b(),D(m,{key:0,text:t.collapsed?n(a):"Open the Local runs tray"},{default:I(()=>[A(g,{color:"info",variant:"soft",size:"xs",block:"",square:t.collapsed,"aria-label":n(a),class:K(t.collapsed?"":"justify-start"),onClick:r[0]||(r[0]=v=>n(s).trayOpen.value=!0)},{default:I(()=>[r[1]||(r[1]=N("span",{class:"relative flex size-2 shrink-0","aria-hidden":"true"},[N("span",{class:"absolute inline-flex h-full w-full animate-ping rounded-full bg-info opacity-60 motion-reduce:hidden"}),N("span",{class:"relative inline-flex size-2 rounded-full bg-info"})],-1)),t.collapsed?E("",!0):(b(),z(de,{key:0},[N("span",bs,Q(n(a)),1),n(i)?(b(),z("span",ws,Q(n(i)),1)):E("",!0)],64))]),_:1},8,["square","aria-label","class"])]),_:1},8,["text"])):E("",!0)}}}),ks=Object.assign(_s,{__name:"DesktopLocalRunsIndicator"}),xs={class:"inline-flex items-center justify-center shrink-0 size-5"},Ss=fe({__name:"UserMenu",props:{collapsed:{type:Boolean}},setup(e){const t=da(),s=Ie(),o=Ue(),{authState:l,logout:a}=fa(),i=zn(),{openSettings:u}=$a(),r=["red","orange","amber","yellow","lime","green","emerald","teal","cyan","sky","blue","indigo","violet","purple","fuchsia","pink","rose"],g=["slate","gray","zinc","neutral","stone"],m=R(()=>{if(o.public.authEnabled&&l.value.authenticated&&l.value.user){const f=l.value.user.avatarUrl;return{name:l.value.user.name||l.value.user.username,icon:f?void 0:"i-lucide-user",avatar:f?{src:f}:void 0,role:l.value.user.role}}return{name:"Configuration",icon:"i-lucide-cog"}}),v=R(()=>{const f=[];(!o.public.authEnabled||l.value.authenticated&&l.value.user?.role==="administrator")&&f.push(...i.value.flat());const c=[f,[{label:"Theme",icon:"i-lucide-palette",children:[{label:"Primary",slot:"chip",chip:s.ui.colors.primary,content:{align:"center",collisionPadding:16},children:r.map(p=>({label:p,chip:p,slot:"chip",checked:s.ui.colors.primary===p,type:"checkbox",onSelect:y=>{y.preventDefault(),s.ui.colors.primary=p}}))},{label:"Neutral",slot:"chip",chip:s.ui.colors.neutral==="neutral"?"old-neutral":s.ui.colors.neutral,content:{align:"end",collisionPadding:16},children:g.map(p=>({label:p,chip:p==="neutral"?"old-neutral":p,slot:"chip",type:"checkbox",checked:s.ui.colors.neutral===p,onSelect:y=>{y.preventDefault(),s.ui.colors.neutral=p}}))}]},{label:"Appearance",icon:"i-lucide-sun-moon",children:[{label:"Light",icon:"i-lucide-sun",type:"checkbox",checked:t.value==="light",onSelect(p){p.preventDefault(),t.preference="light"}},{label:"Dark",icon:"i-lucide-moon",type:"checkbox",checked:t.value==="dark",onUpdateChecked(p){p&&(t.preference="dark")},onSelect(p){p.preventDefault()}}]},{label:"Open in IDE…",icon:"i-lucide-external-link",onSelect:p=>{p.preventDefault(),u()}}],[{label:"GitHub repository",icon:"i-lucide-github",to:"https://github.com/piwitests/platform",target:"_blank"}]];return o.public.authEnabled&&l.value.authenticated&&!o.public.demoMode&&c.push([{label:"Logout",icon:"i-lucide-log-out",onSelect:async p=>{p.preventDefault(),await a()}}]),c});return(f,c)=>{const p=ye,y=pa;return b(),D(y,{items:n(v),content:{align:"center",collisionPadding:12},ui:{content:e.collapsed?"w-48":"w-(--reka-dropdown-menu-trigger-width)"}},{"chip-leading":I(({item:L})=>[N("div",xs,[N("span",{class:"rounded-full ring ring-bg bg-(--chip-light) dark:bg-(--chip-dark) size-2",style:ha({"--chip-light":`var(--color-${L.chip}-500)`,"--chip-dark":`var(--color-${L.chip}-400)`})},null,4)])]),default:I(()=>[A(p,Z({...n(m),label:e.collapsed?void 0:n(m)?.name,trailingIcon:e.collapsed?void 0:"i-lucide-chevrons-up-down"},{color:"neutral",variant:"ghost",block:"",square:e.collapsed,class:"data-[state=open]:bg-elevated",ui:{trailingIcon:"text-dimmed"}}),null,16,["square"])]),_:1},8,["items","ui"])}}}),$s=Object.assign(Ss,{__name:"UserMenu"});(function(){var e;try{if(typeof document<"u"){var t=document.createElement("style");t.nonce=(e=document.head.querySelector("meta[property=csp-nonce]"))==null?void 0:e.content,t.appendChild(document.createTextNode('[data-vaul-drawer]{touch-action:none;will-change:transform;transition:transform .5s cubic-bezier(.32,.72,0,1);animation-duration:.5s;animation-timing-function:cubic-bezier(.32,.72,0,1)}[data-vaul-drawer][data-vaul-snap-points=false][data-vaul-drawer-direction=bottom][data-state=open]{animation-name:slideFromBottom}[data-vaul-drawer][data-vaul-snap-points=false][data-vaul-drawer-direction=bottom][data-state=closed]{animation-name:slideToBottom}[data-vaul-drawer][data-vaul-snap-points=false][data-vaul-drawer-direction=top][data-state=open]{animation-name:slideFromTop}[data-vaul-drawer][data-vaul-snap-points=false][data-vaul-drawer-direction=top][data-state=closed]{animation-name:slideToTop}[data-vaul-drawer][data-vaul-snap-points=false][data-vaul-drawer-direction=left][data-state=open]{animation-name:slideFromLeft}[data-vaul-drawer][data-vaul-snap-points=false][data-vaul-drawer-direction=left][data-state=closed]{animation-name:slideToLeft}[data-vaul-drawer][data-vaul-snap-points=false][data-vaul-drawer-direction=right][data-state=open]{animation-name:slideFromRight}[data-vaul-drawer][data-vaul-snap-points=false][data-vaul-drawer-direction=right][data-state=closed]{animation-name:slideToRight}[data-vaul-drawer][data-vaul-snap-points=true][data-vaul-drawer-direction=bottom]{transform:translate3d(0,var(--initial-transform, 100%),0)}[data-vaul-drawer][data-vaul-snap-points=true][data-vaul-drawer-direction=top]{transform:translate3d(0,calc(var(--initial-transform, 100%) * -1),0)}[data-vaul-drawer][data-vaul-snap-points=true][data-vaul-drawer-direction=left]{transform:translate3d(calc(var(--initial-transform, 100%) * -1),0,0)}[data-vaul-drawer][data-vaul-snap-points=true][data-vaul-drawer-direction=right]{transform:translate3d(var(--initial-transform, 100%),0,0)}[data-vaul-drawer][data-vaul-delayed-snap-points=true][data-vaul-drawer-direction=top],[data-vaul-drawer][data-vaul-delayed-snap-points=true][data-vaul-drawer-direction=bottom]{transform:translate3d(0,var(--snap-point-height, 0),0)}[data-vaul-drawer][data-vaul-delayed-snap-points=true][data-vaul-drawer-direction=left],[data-vaul-drawer][data-vaul-delayed-snap-points=true][data-vaul-drawer-direction=right]{transform:translate3d(var(--snap-point-height, 0),0,0)}[data-vaul-overlay][data-vaul-snap-points=false]{animation-duration:.5s;animation-timing-function:cubic-bezier(.32,.72,0,1)}[data-vaul-overlay][data-vaul-snap-points=false][data-state=open]{animation-name:fadeIn}[data-vaul-overlay][data-state=closed]{animation-name:fadeOut}[data-vaul-animate=false]{animation:none!important}[data-vaul-overlay][data-vaul-snap-points=true]{opacity:0;transition:opacity .5s cubic-bezier(.32,.72,0,1)}[data-vaul-overlay][data-vaul-snap-points=true]{opacity:1}[data-vaul-drawer]:not([data-vaul-custom-container=true]):after{content:"";position:absolute;background:inherit;background-color:inherit}[data-vaul-drawer][data-vaul-drawer-direction=top]:after{top:initial;bottom:100%;left:0;right:0;height:200%}[data-vaul-drawer][data-vaul-drawer-direction=bottom]:after{top:100%;bottom:initial;left:0;right:0;height:200%}[data-vaul-drawer][data-vaul-drawer-direction=left]:after{left:initial;right:100%;top:0;bottom:0;width:200%}[data-vaul-drawer][data-vaul-drawer-direction=right]:after{left:100%;right:initial;top:0;bottom:0;width:200%}[data-vaul-overlay][data-vaul-snap-points=true]:not([data-vaul-snap-points-overlay=true]):not([data-state=closed]){opacity:0}[data-vaul-overlay][data-vaul-snap-points-overlay=true]{opacity:1}[data-vaul-handle]{display:block;position:relative;opacity:.7;background:#e2e2e4;margin-left:auto;margin-right:auto;height:5px;width:32px;border-radius:1rem;touch-action:pan-y}[data-vaul-handle]:hover,[data-vaul-handle]:active{opacity:1}[data-vaul-handle-hitarea]{position:absolute;left:50%;top:50%;transform:translate(-50%,-50%);width:max(100%,2.75rem);height:max(100%,2.75rem);touch-action:inherit}@media (hover: hover) and (pointer: fine){[data-vaul-drawer]{-webkit-user-select:none;user-select:none}}@media (pointer: fine){[data-vaul-handle-hitarea]:{width:100%;height:100%}}@keyframes fadeIn{0%{opacity:0}to{opacity:1}}@keyframes fadeOut{to{opacity:0}}@keyframes slideFromBottom{0%{transform:translate3d(0,var(--initial-transform, 100%),0)}to{transform:translateZ(0)}}@keyframes slideToBottom{to{transform:translate3d(0,var(--initial-transform, 100%),0)}}@keyframes slideFromTop{0%{transform:translate3d(0,calc(var(--initial-transform, 100%) * -1),0)}to{transform:translateZ(0)}}@keyframes slideToTop{to{transform:translate3d(0,calc(var(--initial-transform, 100%) * -1),0)}}@keyframes slideFromLeft{0%{transform:translate3d(calc(var(--initial-transform, 100%) * -1),0,0)}to{transform:translateZ(0)}}@keyframes slideToLeft{to{transform:translate3d(calc(var(--initial-transform, 100%) * -1),0,0)}}@keyframes slideFromRight{0%{transform:translate3d(var(--initial-transform, 100%),0,0)}to{transform:translateZ(0)}}@keyframes slideToRight{to{transform:translate3d(var(--initial-transform, 100%),0,0)}}')),document.head.appendChild(t)}}catch(s){console.error("vite-plugin-css-injected-by-js",s)}})();const Cs=typeof window<"u"&&typeof document<"u";typeof WorkerGlobalScope<"u"&&globalThis instanceof WorkerGlobalScope;const Is=e=>typeof e<"u";function Ts(e){return JSON.parse(JSON.stringify(e))}function Yt(e,t,s,o={}){var l,a,i;const{clone:u=!1,passive:r=!1,eventName:g,deep:m=!1,defaultValue:v,shouldEmit:f}=o,c=nn(),p=s||c?.emit||((l=c?.$emit)==null?void 0:l.bind(c))||((i=(a=c?.proxy)==null?void 0:a.$emit)==null?void 0:i.bind(c?.proxy));let y=g;t||(t="modelValue"),y=y||`update:${t.toString()}`;const L=w=>u?typeof u=="function"?u(w):Ts(w):w,O=()=>Is(e[t])?L(e[t]):v,T=w=>{f?f(w)&&p(y,w):p(y,w)};if(r){const w=O(),d=U(w);let S=!1;return re(()=>e[t],$=>{S||(S=!0,d.value=L($),ut(()=>S=!1))}),re(d,$=>{!S&&($!==e[t]||m)&&T($)},{deep:m}),d}else return R({get(){return O()},set(w){T(w)}})}const[He,As]=an("DrawerRoot"),Ta=new WeakMap;function le(e,t,s=!1){if(!e||!(e instanceof HTMLElement)||!t)return;const o={};Object.entries(t).forEach(([l,a])=>{if(l.startsWith("--")){e.style.setProperty(l,a);return}o[l]=e.style[l],e.style[l]=a}),!s&&Ta.set(e,o)}function Ds(e,t){if(!e||!(e instanceof HTMLElement))return;const s=Ta.get(e);s&&Object.entries(s).forEach(([o,l])=>{e.style[o]=l})}function Ye(e,t){const s=window.getComputedStyle(e),o=s.transform||s.webkitTransform||s.mozTransform;let l=o.match(/^matrix3d\((.+)\)$/);return l?Number.parseFloat(l[1].split(", ")[ae(t)?13:12]):(l=o.match(/^matrix\((.+)\)$/),l?Number.parseFloat(l[1].split(", ")[ae(t)?5:4]):null)}function Bs(e){return 8*(Math.log(e+1)-2)}function ae(e){switch(e){case"top":case"bottom":return!0;case"left":case"right":return!1;default:return e}}function ht(e,t){if(!e)return()=>{};const s=e.style.cssText;return Object.assign(e.style,t),()=>{e.style.cssText=s}}function Ls(...e){return(...t)=>{for(const s of e)typeof s=="function"&&s(...t)}}const ee={DURATION:.5,EASE:[.32,.72,0,1]},Aa=.4,Es=.25,Ms=100,Da=8,Qe=16,Ba=26,Qt="vaul-dragging";function Os({activeSnapPoint:e,snapPoints:t,drawerRef:s,overlayRef:o,fadeFromIndex:l,onSnapPointChange:a,direction:i}){const u=U(typeof window<"u"?{innerWidth:window.innerWidth,innerHeight:window.innerHeight}:void 0);function r(){u.value={innerWidth:window.innerWidth,innerHeight:window.innerHeight}}Re(()=>{typeof window<"u"&&window.addEventListener("resize",r)}),sn(()=>{typeof window<"u"&&window.removeEventListener("resize",r)});const g=R(()=>(t.value&&e.value===t.value[t.value.length-1])??null),m=R(()=>t.value&&t.value.length>0&&(l?.value||l?.value===0)&&!Number.isNaN(l?.value)&&t.value[l?.value??-1]===e.value||!t.value),v=R(()=>{var T;return((T=t.value)==null?void 0:T.findIndex(w=>w===e.value))??null}),f=R(()=>{var T;return((T=t.value)==null?void 0:T.map(w=>{const d=typeof w=="string";let S=0;if(d&&(S=Number.parseInt(w,10)),ae(i.value)){const B=d?S:u.value?w*u.value.innerHeight:0;return u.value?i.value==="bottom"?u.value.innerHeight-B:-u.value.innerHeight+B:B}const $=d?S:u.value?w*u.value.innerWidth:0;return u.value?i.value==="right"?u.value.innerWidth-$:-u.value.innerWidth+$:$}))??[]}),c=R(()=>{var T;return v.value!==null?(T=f.value)==null?void 0:T[v.value]:null}),p=T=>{var w,d,S,$;const B=((w=f.value)==null?void 0:w.findIndex(C=>C===T))??null;ut(()=>{var C;a(B,f.value),le((C=s.value)==null?void 0:C.$el,{transition:`transform ${ee.DURATION}s cubic-bezier(${ee.EASE.join(",")})`,transform:ae(i.value)?`translate3d(0, ${T}px, 0)`:`translate3d(${T}px, 0, 0)`})}),f.value&&B!==f.value.length-1&&B!==l?.value?le((d=o.value)==null?void 0:d.$el,{transition:`opacity ${ee.DURATION}s cubic-bezier(${ee.EASE.join(",")})`,opacity:"0"}):le((S=o.value)==null?void 0:S.$el,{transition:`opacity ${ee.DURATION}s cubic-bezier(${ee.EASE.join(",")})`,opacity:"1"}),e.value=B!==null?(($=t.value)==null?void 0:$[B])??null:null};re([e,f,t],()=>{var T;if(e.value){const w=((T=t.value)==null?void 0:T.findIndex(d=>d===e.value))??-1;f.value&&w!==-1&&typeof f.value[w]=="number"&&p(f.value[w])}},{immediate:!0});function y({draggedDistance:T,closeDrawer:w,velocity:d,dismissible:S}){var $,B,C;if(l.value===void 0)return;const x=i.value==="bottom"||i.value==="right"?(c.value??0)-T:(c.value??0)+T,k=v.value===l.value-1,j=v.value===0,G=T>0;if(k&&le(($=o.value)==null?void 0:$.$el,{transition:`opacity ${ee.DURATION}s cubic-bezier(${ee.EASE.join(",")})`}),d>2&&!G){S?w():p(f.value[0]);return}if(d>2&&G&&f&&t.value){p(f.value[t.value.length-1]);return}const Y=(B=f.value)==null?void 0:B.reduce((P,h)=>typeof P!="number"||typeof h!="number"?P:Math.abs(h-x)<Math.abs(P-x)?h:P),_=ae(i.value)?window.innerHeight:window.innerWidth;if(d>Aa&&Math.abs(T)<_*.4){const P=G?1:-1;if(P>0&&g){p(f.value[(((C=t.value)==null?void 0:C.length)??0)-1]);return}if(j&&P<0&&S&&w(),v.value===null)return;p(f.value[v.value+P]);return}p(Y)}function L({draggedDistance:T}){var w;if(c.value===null)return;const d=i.value==="bottom"||i.value==="right"?c.value-T:c.value+T;(i.value==="bottom"||i.value==="right")&&d<f.value[f.value.length-1]||(i.value==="top"||i.value==="left")&&d>f.value[f.value.length-1]||le((w=s.value)==null?void 0:w.$el,{transform:ae(i.value)?`translate3d(0, ${d}px, 0)`:`translate3d(${d}px, 0, 0)`})}function O(T,w){if(!t.value||typeof v.value!="number"||!f.value||l.value===void 0)return null;const d=v.value===l.value-1;if(v.value>=l.value&&w)return 0;if(d&&!w)return 1;if(!m.value&&!d)return null;const S=d?v.value+1:v.value-1,$=d?f.value[S]-f.value[S-1]:f.value[S+1]-f.value[S],B=T/Math.abs($);return d?1-B:B}return{isLastSnapPoint:g,shouldFade:m,getPercentageDragged:O,activeSnapPointIndex:v,onRelease:y,onDrag:L,snapPointsOffset:f}}function Xt(){return/^((?!chrome|android).)*safari/i.test(navigator.userAgent)}let Fe=null;function Rs(e){const{isOpen:t,modal:s,nested:o,hasBeenOpened:l,preventScrollRestoration:a,noBodyStyles:i}=e,u=U(typeof window<"u"?window.location.href:""),r=U(0);function g(){if(Xt()&&Fe===null&&t.value&&!i.value){Fe={position:document.body.style.position,top:document.body.style.top,left:document.body.style.left,height:document.body.style.height};const{scrollX:v,innerHeight:f}=window;document.body.style.setProperty("position","fixed","important"),Object.assign(document.body.style,{top:`${-r.value}px`,left:`${-v}px`,right:"0px",height:"auto"}),setTimeout(()=>{requestAnimationFrame(()=>{const c=f-window.innerHeight;c&&r.value>=f&&(document.body.style.top=`-${r.value+c}px`)})},300)}}function m(){if(Xt()&&Fe!==null&&!i.value){const v=-Number.parseInt(document.body.style.top,10),f=-Number.parseInt(document.body.style.left,10);Object.assign(document.body.style,Fe),window.requestAnimationFrame(()=>{if(a.value&&u.value!==window.location.href){u.value=window.location.href;return}window.scrollTo(f,v)}),Fe=null}}return Re(()=>{function v(){r.value=window.scrollY}v(),window.addEventListener("scroll",v),on(()=>{window.removeEventListener("scroll",v)})}),re([t,l,u],()=>{o.value||!l.value||(t.value?(window.matchMedia("(display-mode: standalone)").matches||g(),s.value||setTimeout(()=>{m()},500)):m())}),{restorePositionSetting:m}}function js(e,t){return e&&e.value?e:t}function Fs(e){const{emitDrag:t,emitRelease:s,emitClose:o,emitOpenChange:l,open:a,dismissible:i,nested:u,modal:r,shouldScaleBackground:g,setBackgroundColorOnScale:m,scrollLockTimeout:v,closeThreshold:f,activeSnapPoint:c,fadeFromIndex:p,direction:y,noBodyStyles:L,handleOnly:O,preventScrollRestoration:T}=e,w=U(a.value??!1),d=U(!1),S=U(!1),$=U(!1),B=U(null),C=U(null),x=U(null),k=U(null),j=U(null),G=U(!1),Y=U(null),_=U(0),P=U(!1),h=U(null),V=R(()=>{var q;return((q=h.value)==null?void 0:q.$el.getBoundingClientRect().height)||0}),M=js(e.snapPoints,U(void 0)),J=R(()=>{var q;return M&&(((q=M.value)==null?void 0:q.length)??0)>0}),ne=U(null),{activeSnapPointIndex:W,onRelease:_e,snapPointsOffset:me,onDrag:Na,shouldFade:qt,getPercentageDragged:Ka}=Os({snapPoints:M,activeSnapPoint:c,drawerRef:h,fadeFromIndex:p,overlayRef:B,onSnapPointChange:Ua,direction:y});function Ua(q,te){M.value&&q===te.length-1&&(C.value=new Date)}Rs({isOpen:w,modal:r,nested:u,hasBeenOpened:d,noBodyStyles:L,preventScrollRestoration:T});function Ve(){return(window.innerWidth-Ba)/window.innerWidth}function Nt(q,te){var se;if(!q)return!1;let X=q;const ie=(se=window.getSelection())==null?void 0:se.toString(),ce=h.value?Ye(h.value.$el,y.value):null,he=new Date;if(X.hasAttribute("data-vaul-no-drag")||X.closest("[data-vaul-no-drag]"))return!1;if(y.value==="right"||y.value==="left")return!0;if(C.value&&he.getTime()-C.value.getTime()<500)return!1;if(ce!==null&&(y.value==="bottom"?ce>0:ce<0))return!0;if(ie&&ie.length>0)return!1;if(j.value&&he.getTime()-j.value.getTime()<v.value&&ce===0||te)return j.value=he,!1;for(;X;){if(X.scrollHeight>X.clientHeight){if(X.scrollTop!==0)return j.value=new Date,!1;if(X.getAttribute("role")==="dialog")return!0}X=X.parentNode}return!0}function Ha(q){!i.value&&!M.value||h.value&&!h.value.$el.contains(q.target)||(S.value=!0,x.value=new Date,q.target.setPointerCapture(q.pointerId),_.value=ae(y.value)?q.clientY:q.clientX)}function Va(q){var te,se,X,ie,ce,he;if(h.value&&S.value){const Te=y.value==="bottom"||y.value==="right"?1:-1,We=(_.value-(ae(y.value)?q.clientY:q.clientX))*Te,Ge=We>0,Ut=M.value&&!i.value&&!Ge;if(Ut&&W.value===0)return;const dt=Math.abs(We),Ht=document.querySelector("[data-vaul-drawer-wrapper]")||document.querySelector("[vaul-drawer-wrapper]");let $e=dt/V.value;const Vt=Ka(dt,Ge);if(Vt!==null&&($e=Vt),Ut&&$e>=1||!G.value&&!Nt(q.target,Ge))return;if((te=h?.value)==null||te.$el.classList.add(Qt),G.value=!0,le((se=h.value)==null?void 0:se.$el,{transition:"none"}),le((X=B.value)==null?void 0:X.$el,{transition:"none"}),M.value&&Na({draggedDistance:We}),Ge&&!M.value){const Ce=Bs(We),Je=Math.min(Ce*-1,0)*Te;le((ie=h.value)==null?void 0:ie.$el,{transform:ae(y.value)?`translate3d(0, ${Je}px, 0)`:`translate3d(${Je}px, 0, 0)`});return}const Qa=1-$e;if((qt.value||p.value&&W.value===p.value-1)&&(t($e),le((ce=B.value)==null?void 0:ce.$el,{opacity:`${Qa}`,transition:"none"},!0)),Ht&&B.value&&g.value){const Ce=Math.min(Ve()+$e*(1-Ve()),1),Je=8-$e*8,Wt=Math.max(0,14-$e*14);le(Ht,{borderRadius:`${Je}px`,transform:ae(y.value)?`scale(${Ce}) translate3d(0, ${Wt}px, 0)`:`scale(${Ce}) translate3d(${Wt}px, 0, 0)`,transition:"none"},!0)}if(!M.value){const Ce=dt*Te;le((he=h.value)==null?void 0:he.$el,{transform:ae(y.value)?`translate3d(0, ${Ce}px, 0)`:`translate3d(${Ce}px, 0, 0)`})}}}function Kt(){var q;if(!h.value)return;const te=document.querySelector("[data-vaul-drawer-wrapper]")||document.querySelector("[vaul-drawer-wrapper]"),se=Ye(h.value.$el,y.value);le(h.value.$el,{transform:"translate3d(0, 0, 0)",transition:`transform ${ee.DURATION}s cubic-bezier(${ee.EASE.join(",")})`}),le((q=B.value)==null?void 0:q.$el,{transition:`opacity ${ee.DURATION}s cubic-bezier(${ee.EASE.join(",")})`,opacity:"1"}),g.value&&se&&se>0&&w.value&&le(te,{borderRadius:`${Da}px`,overflow:"hidden",...ae(y.value)?{transform:`scale(${Ve()}) translate3d(0, calc(env(safe-area-inset-top) + 14px), 0)`,transformOrigin:"top"}:{transform:`scale(${Ve()}) translate3d(calc(env(safe-area-inset-top) + 14px), 0, 0)`,transformOrigin:"left"},transitionProperty:"transform, border-radius",transitionDuration:`${ee.DURATION}s`,transitionTimingFunction:`cubic-bezier(${ee.EASE.join(",")})`},!0)}function je(q){h.value&&(o(),q||(w.value=!1),window.setTimeout(()=>{M.value&&(c.value=M.value[0])},ee.DURATION*1e3))}Bt(()=>{if(!w.value&&g.value&&Cs){const q=setTimeout(()=>{Ds(document.body)},200);return()=>clearTimeout(q)}}),re(a,()=>{w.value=a.value,a.value||je()});function Wa(q){if(!S.value||!h.value)return;h.value.$el.classList.remove(Qt),G.value=!1,S.value=!1,k.value=new Date;const te=Ye(h.value.$el,y.value);if(!Nt(q.target,!1)||!te||Number.isNaN(te)||x.value===null)return;const se=k.value.getTime()-x.value.getTime(),X=_.value-(ae(y.value)?q.clientY:q.clientX),ie=Math.abs(X)/se;if(ie>.05&&($.value=!0,window.setTimeout(()=>{$.value=!1},200)),M.value){const he=y.value==="bottom"||y.value==="right"?1:-1;_e({draggedDistance:X*he,closeDrawer:je,velocity:ie,dismissible:i.value}),s(!0);return}if(y.value==="bottom"||y.value==="right"?X>0:X<0){Kt(),s(!0);return}if(ie>Aa){je(),s(!1);return}const ce=Math.min(h.value.$el.getBoundingClientRect().height??0,window.innerHeight);if(te>=ce*f.value){je(),s(!1);return}s(!0),Kt()}re(w,q=>{q&&(C.value=new Date),l(q)},{immediate:!0});function Ga(q){var te,se;const X=q?(window.innerWidth-Qe)/window.innerWidth:1,ie=q?-16:0;Y.value&&window.clearTimeout(Y.value),le((te=h.value)==null?void 0:te.$el,{transition:`transform ${ee.DURATION}s cubic-bezier(${ee.EASE.join(",")})`,transform:`scale(${X}) translate3d(0, ${ie}px, 0)`}),!q&&(se=h.value)!=null&&se.$el&&(Y.value=window.setTimeout(()=>{var ce,he;const Te=Ye((ce=h.value)==null?void 0:ce.$el,y.value);le((he=h.value)==null?void 0:he.$el,{transition:"none",transform:ae(y.value)?`translate3d(0, ${Te}px, 0)`:`translate3d(${Te}px, 0, 0)`})},500))}function Ja(q){var te;if(q<0)return;const se=ae(y.value)?window.innerHeight:window.innerWidth,X=(se-Qe)/se,ie=X+q*(1-X),ce=-16+q*Qe;le((te=h.value)==null?void 0:te.$el,{transform:ae(y.value)?`scale(${ie}) translate3d(0, ${ce}px, 0)`:`scale(${ie}) translate3d(${ce}px, 0, 0)`,transition:"none"})}function Ya(q){var te;const se=ae(y.value)?window.innerHeight:window.innerWidth,X=q?(se-Qe)/se:1,ie=q?-16:0;q&&le((te=h.value)==null?void 0:te.$el,{transition:`transform ${ee.DURATION}s cubic-bezier(${ee.EASE.join(",")})`,transform:ae(y.value)?`scale(${X}) translate3d(0, ${ie}px, 0)`:`scale(${X}) translate3d(${ie}px, 0, 0)`})}return{open:a,isOpen:w,modal:r,keyboardIsOpen:P,hasBeenOpened:d,drawerRef:h,drawerHeightRef:V,overlayRef:B,handleRef:ne,isDragging:S,dragStartTime:x,isAllowedToDrag:G,snapPoints:M,activeSnapPoint:c,hasSnapPoints:J,pointerStart:_,dismissible:i,snapPointsOffset:me,direction:y,shouldFade:qt,fadeFromIndex:p,shouldScaleBackground:g,setBackgroundColorOnScale:m,onPress:Ha,onDrag:Va,onRelease:Wa,closeDrawer:je,onNestedDrag:Ja,onNestedRelease:Ya,onNestedOpenChange:Ga,emitClose:o,emitDrag:t,emitRelease:s,emitOpenChange:l,nested:u,handleOnly:O,noBodyStyles:L}}const La=fe({__name:"DrawerRoot",props:{activeSnapPoint:{default:void 0},closeThreshold:{default:Es},shouldScaleBackground:{type:Boolean,default:void 0},setBackgroundColorOnScale:{type:Boolean,default:!0},scrollLockTimeout:{default:Ms},fixed:{type:Boolean,default:void 0},dismissible:{type:Boolean,default:!0},modal:{type:Boolean,default:!0},open:{type:Boolean,default:void 0},defaultOpen:{type:Boolean,default:void 0},nested:{type:Boolean,default:!1},direction:{default:"bottom"},noBodyStyles:{type:Boolean},handleOnly:{type:Boolean,default:!1},preventScrollRestoration:{type:Boolean},snapPoints:{default:void 0},fadeFromIndex:{default:void 0}},emits:["drag","release","close","update:open","update:activeSnapPoint","animationEnd"],setup(e,{expose:t,emit:s}){const o=e,l=s;Ee();const a=R(()=>o.fadeFromIndex??(o.snapPoints&&o.snapPoints.length-1)),i=Yt(o,"open",l,{defaultValue:o.defaultOpen,passive:o.open===void 0}),u=Yt(o,"activeSnapPoint",l,{passive:o.activeSnapPoint===void 0}),r={emitDrag:p=>l("drag",p),emitRelease:p=>l("release",p),emitClose:()=>l("close"),emitOpenChange:p=>{l("update:open",p),setTimeout(()=>{l("animationEnd",p)},ee.DURATION*1e3)}},{closeDrawer:g,hasBeenOpened:m,modal:v,isOpen:f}=As(Fs({...r,...tn(o),activeSnapPoint:u,fadeFromIndex:a,open:i}));function c(p){if(i.value!==void 0){r.emitOpenChange(p);return}f.value=p,p?m.value=!0:g()}return t({open:f}),(p,y)=>(b(),D(n(Hn),{open:n(f),modal:n(v),"onUpdate:open":c},{default:I(()=>[H(p.$slots,"default",{open:n(f)})]),_:3},8,["open","modal"]))}}),Ps=fe({__name:"DrawerRootNested",props:{activeSnapPoint:{},closeThreshold:{},shouldScaleBackground:{type:Boolean},setBackgroundColorOnScale:{type:Boolean},scrollLockTimeout:{},fixed:{type:Boolean},dismissible:{type:Boolean},modal:{type:Boolean},open:{type:Boolean},defaultOpen:{type:Boolean},nested:{type:Boolean},direction:{},noBodyStyles:{type:Boolean},handleOnly:{type:Boolean},preventScrollRestoration:{type:Boolean},snapPoints:{},fadeFromIndex:{}},emits:["drag","release","close","update:open","update:activeSnapPoint","animationEnd"],setup(e,{emit:t}){const s=e,o=t,{onNestedDrag:l,onNestedOpenChange:a,onNestedRelease:i}=He();function u(){a(!1)}function r(v){l(v)}function g(v){v&&a(v),o("update:open",v)}const m=en(s,o);return(v,f)=>(b(),D(La,Z(n(m),{nested:"",onClose:u,onDrag:r,onRelease:n(i),"onUpdate:open":g}),{default:I(()=>[H(v.$slots,"default")]),_:3},16,["onRelease"]))}}),zs=fe({__name:"DrawerOverlay",setup(e){const{overlayRef:t,hasSnapPoints:s,isOpen:o,shouldFade:l}=He();return(a,i)=>(b(),D(n(Kn),{ref_key:"overlayRef",ref:t,"data-vaul-overlay":"","data-vaul-snap-points":n(o)&&n(s)?"true":"false","data-vaul-snap-points-overlay":n(o)&&n(l)?"true":"false"},null,8,["data-vaul-snap-points","data-vaul-snap-points-overlay"]))}}),qs=()=>()=>{};function Ns(){const{direction:e,isOpen:t,shouldScaleBackground:s,setBackgroundColorOnScale:o,noBodyStyles:l}=He(),a=U(null),i=U(document.body.style.backgroundColor);function u(){return(window.innerWidth-Ba)/window.innerWidth}Bt(r=>{if(t.value&&s.value){a.value&&clearTimeout(a.value);const g=document.querySelector("[data-vaul-drawer-wrapper]")||document.querySelector("[vaul-drawer-wrapper]");if(!g)return;Ls(o.value&&!l.value?ht(document.body,{background:"black"}):qs,ht(g,{transformOrigin:ae(e.value)?"top":"left",transitionProperty:"transform, border-radius",transitionDuration:`${ee.DURATION}s`,transitionTimingFunction:`cubic-bezier(${ee.EASE.join(",")})`}));const m=ht(g,{borderRadius:`${Da}px`,overflow:"hidden",...ae(e.value)?{transform:`scale(${u()}) translate3d(0, calc(env(safe-area-inset-top) + 14px), 0)`}:{transform:`scale(${u()}) translate3d(calc(env(safe-area-inset-top) + 14px), 0, 0)`}});r(()=>{m(),a.value=window.setTimeout(()=>{i.value?document.body.style.background=i.value:document.body.style.removeProperty("background")},ee.DURATION*1e3)})}},{flush:"pre"})}const Ks=fe({__name:"DrawerContent",setup(e){const{open:t,isOpen:s,snapPointsOffset:o,hasSnapPoints:l,drawerRef:a,onPress:i,onDrag:u,onRelease:r,modal:g,emitOpenChange:m,dismissible:v,keyboardIsOpen:f,closeDrawer:c,direction:p,handleOnly:y}=He();Ns();const L=U(!1),O=R(()=>o.value&&o.value.length>0?`${o.value[0]}px`:"0");function T(S){if(!g.value||S.defaultPrevented){S.preventDefault();return}f.value&&(f.value=!1),v.value?m(!1):S.preventDefault()}function w(S){y.value||i(S)}function d(S){y.value||u(S)}return Bt(()=>{l.value&&window.requestAnimationFrame(()=>{L.value=!0})}),(S,$)=>(b(),D(n(Un),{ref_key:"drawerRef",ref:a,"data-vaul-drawer":"","data-vaul-drawer-direction":n(p),"data-vaul-delayed-snap-points":L.value?"true":"false","data-vaul-snap-points":n(s)&&n(l)?"true":"false",style:ha({"--snap-point-height":O.value}),onPointerdown:w,onPointermove:d,onPointerup:n(r),onPointerDownOutside:T,onOpenAutoFocus:$[0]||($[0]=Za(()=>{},["prevent"])),onEscapeKeyDown:$[1]||($[1]=B=>{n(v)||B.preventDefault()})},{default:I(()=>[H(S.$slots,"default")]),_:3},8,["data-vaul-drawer-direction","data-vaul-delayed-snap-points","data-vaul-snap-points","style","onPointerup"]))}}),Us=["data-vaul-drawer-visible"],Hs={"data-vaul-handle-hitarea":"","aria-hidden":"true"},Vs=250,Ws=120,Gs=fe({__name:"DrawerHandle",props:{preventCycle:{type:Boolean,default:!1}},setup(e){const t=e,{onPress:s,onDrag:o,handleRef:l,handleOnly:a,isOpen:i,snapPoints:u,activeSnapPoint:r,isDragging:g,dismissible:m,closeDrawer:v}=He(),f=U(null),c=U(!1);function p(){if(c.value){O();return}window.setTimeout(()=>{y()},Ws)}function y(){if(g.value||t.preventCycle||c.value){O();return}if(O(),!u.value||u.value.length===0){m.value||v();return}const d=r.value===u.value[u.value.length-1];if(d&&m.value){v();return}const S=u.value.findIndex(B=>B===r.value);if(S===-1)return;const $=d?0:S+1;r.value=u.value[$]}function L(){f.value=window.setTimeout(()=>{c.value=!0},Vs)}function O(){f.value&&window.clearTimeout(f.value),c.value=!1}function T(d){a.value&&s(d),L()}function w(d){a.value&&o(d)}return(d,S)=>(b(),z("div",{ref_key:"handleRef",ref:l,"data-vaul-drawer-visible":n(i)?"true":"false","data-vaul-handle":"","aria-hidden":"true",onClick:p,onPointercancel:O,onPointerdown:T,onPointermove:w},[N("span",Hs,[H(d.$slots,"default")])],40,Us))}}),Js={slots:{overlay:"fixed inset-0 bg-elevated/75",content:"fixed bg-default ring ring-default flex focus:outline-none",handle:["shrink-0 !bg-accented","transition-opacity"],container:"w-full flex flex-col gap-4 p-4 overflow-y-auto",header:"flex items-center gap-1.5 min-h-8",wrapper:"min-w-0 flex-1",title:"text-highlighted font-semibold",description:"mt-1 text-muted text-sm",actions:"flex items-center gap-1.5 shrink-0 ms-auto",body:"flex-1",footer:"flex flex-col gap-1.5",close:""},variants:{direction:{top:{content:"mb-24 flex-col-reverse",handle:"mb-4"},right:{content:"flex-row rtl:flex-row-reverse",handle:"!ml-4"},bottom:{content:"mt-24 flex-col",handle:"mt-4"},left:{content:"flex-row-reverse rtl:flex-row",handle:"!mr-4"}},inset:{true:{content:"rounded-lg after:hidden overflow-hidden [--initial-transform:calc(100%+1.5rem)]"}},snapPoints:{true:""}},compoundVariants:[{direction:["top","bottom"],class:{content:"h-auto max-h-[96%]",handle:"!w-12 !h-1.5 mx-auto"}},{direction:["top","bottom"],snapPoints:!0,class:{content:"h-full"}},{direction:["right","left"],class:{content:"w-auto max-w-[calc(100%-2rem)]",handle:"!h-12 !w-1.5 mt-auto mb-auto"}},{direction:["right","left"],snapPoints:!0,class:{content:"w-full"}},{direction:"top",inset:!0,class:{content:"inset-x-4 top-4"}},{direction:"top",inset:!1,class:{content:"inset-x-0 top-0 rounded-b-lg"}},{direction:"bottom",inset:!0,class:{content:"inset-x-4 bottom-4"}},{direction:"bottom",inset:!1,class:{content:"inset-x-0 bottom-0 rounded-t-lg"}},{direction:"left",inset:!0,class:{content:"inset-y-4 left-4"}},{direction:"left",inset:!1,class:{content:"inset-y-0 left-0 rounded-r-lg"}},{direction:"right",inset:!0,class:{content:"inset-y-4 right-4"}},{direction:"right",inset:!1,class:{content:"inset-y-0 right-0 rounded-l-lg"}}]},Ys={__name:"UDrawer",props:{as:{type:null,required:!1},title:{type:String,required:!1},description:{type:String,required:!1},inset:{type:Boolean,required:!1},content:{type:Object,required:!1},overlay:{type:Boolean,required:!1,default:!0},handle:{type:Boolean,required:!1,default:!0},portal:{type:[Boolean,String],required:!1,skipCheck:!0,default:!0},nested:{type:Boolean,required:!1},close:{type:[Boolean,Object],required:!1},closeIcon:{type:null,required:!1},class:{type:null,required:!1},ui:{type:Object,required:!1},activeSnapPoint:{type:[Number,String,null],required:!1},closeThreshold:{type:Number,required:!1},shouldScaleBackground:{type:Boolean,required:!1},setBackgroundColorOnScale:{type:Boolean,required:!1},scrollLockTimeout:{type:Number,required:!1},fixed:{type:Boolean,required:!1},dismissible:{type:Boolean,required:!1,default:!0},modal:{type:Boolean,required:!1,default:!0},open:{type:Boolean,required:!1},defaultOpen:{type:Boolean,required:!1},direction:{type:String,required:!1,default:"bottom"},noBodyStyles:{type:Boolean,required:!1},handleOnly:{type:Boolean,required:!1},preventScrollRestoration:{type:Boolean,required:!1},snapPoints:{type:Array,required:!1}},emits:["close:prevent","drag","release","close","update:open","update:activeSnapPoint","animationEnd"],setup(e,{emit:t}){const s=e,o=t,l=Ee(),a=Me("drawer",s),{t:i}=Ke(),u=Ie(),r=ze(ot(a,"activeSnapPoint","closeThreshold","shouldScaleBackground","setBackgroundColorOnScale","scrollLockTimeout","fixed","dismissible","modal","open","defaultOpen","nested","direction","noBodyStyles","handleOnly","preventScrollRestoration","snapPoints"),o),g=ln(Be(()=>a.portal)),m=Be(()=>a.content),v=R(()=>a.dismissible?{pointerDownOutside:fn}:["interactOutside","escapeKeyDown"].reduce((p,y)=>(p[y]=L=>{L.preventDefault(),o("close:prevent")},p),{})),f=R(()=>Oe({extend:Js,...u.ui?.drawer||{}})({direction:a.direction,inset:a.inset,snapPoints:a.snapPoints&&a.snapPoints.length>0}));return(c,p)=>(b(),D(dn(n(a).nested?n(Ps):n(La)),Ae(De(n(r))),{default:I(()=>[l.default?(b(),D(n(Vn),{key:0,"as-child":"",class:K(n(a).class)},{default:I(()=>[H(c.$slots,"default")]),_:3},8,["class"])):E("",!0),A(n(Wn),Ae(De(n(g))),{default:I(()=>[A(n(rn),null,{default:I(()=>[n(a).overlay?(b(),D(n(zs),{key:0,"data-slot":"overlay",class:K(f.value.overlay({class:n(a).ui?.overlay}))},null,8,["class"])):E("",!0),A(n(Ks),Z({"data-slot":"content",class:f.value.content({class:[!l.default&&n(a).class,n(a).ui?.content]})},m.value,un(v.value)),{default:I(()=>[n(a).handle?(b(),D(n(Gs),{key:0,"data-slot":"handle",class:K(f.value.handle({class:n(a).ui?.handle}))},null,8,["class"])):E("",!0),!n(a).title&&!l.title||!n(a).description&&!l.description||l.content?(b(),D(n(cn),{key:1},{default:I(()=>[!n(a).title&&!l.title?(b(),D(n(ft),{key:0})):l.content?(b(),D(n(ft),{key:1},{default:I(()=>[H(c.$slots,"title",{},()=>[oe(Q(n(a).title),1)])]),_:3})):E("",!0),!n(a).description&&!l.description?(b(),D(n(pt),{key:2})):l.content?(b(),D(n(pt),{key:3},{default:I(()=>[H(c.$slots,"description",{},()=>[oe(Q(n(a).description),1)])]),_:3})):E("",!0)]),_:3})):E("",!0),H(c.$slots,"content",{},()=>[N("div",{"data-slot":"container",class:K(f.value.container({class:n(a).ui?.container}))},[l.header||n(a).title||l.title||n(a).description||l.description||n(a).close||l.close||l.actions?(b(),z("div",{key:0,"data-slot":"header",class:K(f.value.header({class:n(a).ui?.header}))},[H(c.$slots,"header",{},()=>[n(a).title||l.title||n(a).description||l.description?(b(),z("div",{key:0,"data-slot":"wrapper",class:K(f.value.wrapper({class:n(a).ui?.wrapper}))},[n(a).title||l.title?(b(),D(n(ft),{key:0,"data-slot":"title",class:K(f.value.title({class:n(a).ui?.title}))},{default:I(()=>[H(c.$slots,"title",{},()=>[oe(Q(n(a).title),1)])]),_:3},8,["class"])):E("",!0),n(a).description||l.description?(b(),D(n(pt),{key:1,"data-slot":"description",class:K(f.value.description({class:n(a).ui?.description}))},{default:I(()=>[H(c.$slots,"description",{},()=>[oe(Q(n(a).description),1)])]),_:3},8,["class"])):E("",!0)],2)):E("",!0),l.actions||n(a).close||l.close?(b(),z("div",{key:1,"data-slot":"actions",class:K(f.value.actions({class:n(a).ui?.actions}))},[H(c.$slots,"actions"),n(a).close||l.close?(b(),D(n(Gn),{key:0,"as-child":""},{default:I(()=>[H(c.$slots,"close",{ui:f.value},()=>[n(a).close?(b(),D(ye,Z({key:0,icon:n(a).closeIcon||n(u).ui.icons.close,color:"neutral",variant:"ghost","aria-label":n(i)("drawer.close")},typeof n(a).close=="object"?n(a).close:{},{"data-slot":"close",class:f.value.close({class:n(a).ui?.close})}),null,16,["icon","aria-label","class"])):E("",!0)])]),_:3})):E("",!0)],2)):E("",!0)])],2)):E("",!0),l.body?(b(),z("div",{key:1,"data-slot":"body",class:K(f.value.body({class:n(a).ui?.body}))},[H(c.$slots,"body")],2)):E("",!0),l.footer?(b(),z("div",{key:2,"data-slot":"footer",class:K(f.value.footer({class:n(a).ui?.footer}))},[H(c.$slots,"footer")],2)):E("",!0)],2)])]),_:3},16,["class"])]),_:3})]),_:3},16)]),_:3},16))}},Qs={slots:{root:"relative hidden lg:flex flex-col min-h-svh min-w-16 w-(--width) shrink-0",header:"h-(--ui-header-height) shrink-0 flex items-center gap-1.5 px-4",body:"flex flex-col gap-4 flex-1 overflow-y-auto px-4 py-2",footer:"shrink-0 flex items-center gap-1.5 px-4 py-2",toggle:"",handle:"",content:"lg:hidden",overlay:"lg:hidden"},variants:{menu:{true:{header:"sm:px-6",body:"sm:px-6",footer:"sm:px-6"}},side:{left:{root:"border-e border-default"},right:{root:""}},toggleSide:{left:{toggle:""},right:{toggle:"ms-auto"}}}};function wt(e,t){const o=ma().hook(e,t);va(o)}const Xs=["data-collapsed","data-dragging"],Zs=Object.assign({inheritAttrs:!1},{__name:"UDashboardSidebar",props:lt({mode:{type:null,required:!1,default:"slideover"},menu:{type:null,required:!1},toggle:{type:[Boolean,Object],required:!1,default:!0},toggleSide:{type:String,required:!1,default:"left"},autoClose:{type:Boolean,required:!1,default:!0},class:{type:null,required:!1},ui:{type:Object,required:!1},id:{type:String,required:!1},side:{type:String,required:!1,default:"left"},minSize:{type:Number,required:!1,default:10},maxSize:{type:Number,required:!1,default:20},defaultSize:{type:Number,required:!1,default:15},resizable:{type:Boolean,required:!1,default:!1},collapsible:{type:Boolean,required:!1,default:!1},collapsedSize:{type:Number,required:!1,default:0}},{open:{type:Boolean,default:!1},openModifiers:{},collapsed:{type:Boolean,default:!1},collapsedModifiers:{}}),emits:["update:open","update:collapsed"],setup(e){const t=e,s=Ee(),o=Me("dashboardSidebar",t),l=qe(e,"open",{type:Boolean,default:!1}),a=qe(e,"collapsed",{type:Boolean,default:!1}),i=Lt(),{t:u}=Ke(),r=Ie(),g=xa({storageKey:"dashboard",unit:"%",sidebarOpen:U(!1),sidebarCollapsed:U(!1)}),m=`${g.storageKey}-sidebar-${o.id||pn()}`,{el:v,size:f,collapse:c,isCollapsed:p,isDragging:y,onMouseDown:L,onTouchStart:O,onDoubleClick:T}=Mn(m,Be(()=>({...g,...o})),{collapsed:a}),[w,d]=nt(),[S,$]=nt();wt("dashboard:sidebar:toggle",()=>{l.value=!l.value}),wt("dashboard:sidebar:collapse",j=>{p.value=j}),re(l,()=>g.sidebarOpen.value=l.value,{immediate:!0}),re(p,()=>g.sidebarCollapsed.value=p.value,{immediate:!0}),re(()=>i.fullPath,()=>{o.autoClose&&(l.value=!1)});const B=R(()=>Oe({extend:Qs,...r.ui?.dashboardSidebar||{}})({side:o.side})),C=R(()=>({slideover:Nn,modal:ct,drawer:Ys})[o.mode]),x=Be(()=>Le(o.menu,{},o.mode==="modal"?{fullscreen:!0,transition:!1}:o.mode==="slideover"?{side:"left"}:{}));function k(){l.value=!l.value}return(j,G)=>(b(),z(de,null,[A(n(w),null,{default:I(()=>[H(j.$slots,"toggle",{open:l.value,toggle:k,ui:B.value},()=>[n(o).toggle?(b(),D(On,Z({key:0},typeof n(o).toggle=="object"?n(o).toggle:{},{side:n(o).toggleSide,"data-slot":"toggle",class:B.value.toggle({class:n(o).ui?.toggle,toggleSide:n(o).toggleSide})}),null,16,["side","class"])):E("",!0)])]),_:3}),A(n(S),null,{default:I(()=>[H(j.$slots,"resize-handle",{onMouseDown:n(L),onTouchStart:n(O),onDoubleClick:n(T),ui:B.value},()=>[n(o).resizable?(b(),D(Rn,{key:0,"aria-controls":m,"data-slot":"handle",class:K(B.value.handle({class:n(o).ui?.handle})),onMousedown:n(L),onTouchstart:n(O),onDblclick:n(T)},null,8,["class","onMousedown","onTouchstart","onDblclick"])):E("",!0)])]),_:3}),n(o).side==="right"?(b(),D(n($),{key:0})):E("",!0),N("div",Z({id:m,ref_key:"el",ref:v,"data-slot":"root"},j.$attrs,{"data-collapsed":n(p),"data-dragging":n(y),class:B.value.root({class:[n(o).ui?.root,n(o).class]}),style:{"--width":`${n(f)||0}${n(g).unit}`}}),[s.header?(b(),z("div",{key:0,"data-slot":"header",class:K(B.value.header({class:n(o).ui?.header}))},[H(j.$slots,"header",{collapsed:n(p),collapse:n(c)})],2)):E("",!0),N("div",{"data-slot":"body",class:K(B.value.body({class:n(o).ui?.body}))},[H(j.$slots,"default",{collapsed:n(p),collapse:n(c)})],2),s.footer?(b(),z("div",{key:1,"data-slot":"footer",class:K(B.value.footer({class:n(o).ui?.footer}))},[H(j.$slots,"footer",{collapsed:n(p),collapse:n(c)})],2)):E("",!0)],16,Xs),n(o).side==="left"?(b(),D(n($),{key:1})):E("",!0),A(n(C),Z({open:l.value,"onUpdate:open":G[0]||(G[0]=Y=>l.value=Y),title:n(u)("dashboardSidebar.title"),description:n(u)("dashboardSidebar.description")},x.value,{ui:{overlay:B.value.overlay({class:n(o).ui?.overlay}),content:B.value.content({class:n(o).ui?.content})}}),{content:I(Y=>[H(j.$slots,"content",Ae(De(Y)),()=>[s.header||n(o).mode!=="drawer"?(b(),z("div",{key:0,"data-slot":"header",class:K(B.value.header({class:n(o).ui?.header,menu:!0}))},[n(o).mode!=="drawer"&&n(o).toggleSide==="left"?(b(),D(n(d),{key:0})):E("",!0),H(j.$slots,"header",{collapsed:!1,collapse:()=>{}}),n(o).mode!=="drawer"&&n(o).toggleSide==="right"?(b(),D(n(d),{key:1})):E("",!0)],2)):E("",!0),N("div",{"data-slot":"body",class:K(B.value.body({class:n(o).ui?.body,menu:!0}))},[H(j.$slots,"default",{collapsed:!1,collapse:()=>{}})],2),s.footer?(b(),z("div",{key:1,"data-slot":"footer",class:K(B.value.footer({class:n(o).ui?.footer,menu:!0}))},[H(j.$slots,"footer",{collapsed:!1,collapse:()=>{}})],2)):E("",!0)])]),_:3},16,["open","title","description","ui"])],64))}});function xe(e){return Array.isArray?Array.isArray(e):Ma(e)==="[object Array]"}function eo(e){if(typeof e=="string")return e;if(typeof e=="bigint")return e.toString();const t=e+"";return t=="0"&&1/e==-1/0?"-0":t}function _t(e){return e==null?"":eo(e)}function ue(e){return typeof e=="string"}function et(e){return typeof e=="number"}function to(e){return e===!0||e===!1||ao(e)&&Ma(e)=="[object Boolean]"}function Ea(e){return typeof e=="object"}function ao(e){return Ea(e)&&e!==null}function pe(e){return e!=null}function Xe(e){return!e.trim().length}function Ma(e){return e==null?e===void 0?"[object Undefined]":"[object Null]":Object.prototype.toString.call(e)}const no="Incorrect 'index' type",kt="Invalid doc index: must be a non-negative integer within the bounds of the docs array",so=e=>`Invalid value for key ${e}`,oo=e=>`Pattern length exceeds max of ${e}.`,lo=e=>`Missing ${e} property in key`,io=e=>`Property 'weight' in key '${e}' must be a positive integer`,ro="Fuse.match does not support useTokenSearch: token search requires corpus-level statistics (df, fieldCount) that a one-off string comparison does not have. Use new Fuse(...).search(...) instead.",Zt=Object.prototype.hasOwnProperty;var uo=class{constructor(e){this._keys=[],this._keyMap={};let t=0;e.forEach(s=>{const o=Oa(s);this._keys.push(o),this._keyMap[o.id]=o,t+=o.weight}),this._keys.forEach(s=>{s.weight/=t})}get(e){return this._keyMap[e]}keys(){return this._keys}toJSON(){return JSON.stringify(this._keys)}};function Oa(e){let t=null,s=null,o=null,l=1,a=null;if(ue(e)||xe(e))o=e,t=ea(e),s=tt(e);else{if(!Zt.call(e,"name"))throw new Error(lo("name"));const i=e.name;if(o=i,Zt.call(e,"weight")&&e.weight!==void 0&&(l=e.weight,l<=0))throw new Error(io(tt(i)));t=ea(i),s=tt(i),a=e.getFn??null}return{path:t,id:s,weight:l,src:o,getFn:a}}function ea(e){return xe(e)?e:e.split(".")}function tt(e){return xe(e)?e.join("."):e}function co(e,t){const s=[];let o=!1;const l=(a,i,u,r)=>{if(pe(a))if(!i[u])s.push(r!==void 0?{v:a,i:r}:a);else{const g=a[i[u]];if(!pe(g))return;if(u===i.length-1&&(ue(g)||et(g)||to(g)||typeof g=="bigint"))s.push(r!==void 0?{v:_t(g),i:r}:_t(g));else if(xe(g)){o=!0;for(let m=0,v=g.length;m<v;m+=1)l(g[m],i,u+1,m)}else i.length&&l(g,i,u+1,r)}};return l(e,ue(t)?t.split("."):t,0),o?s:s[0]}const fo={includeMatches:!1,findAllMatches:!1,minMatchCharLength:1},po={isCaseSensitive:!1,ignoreDiacritics:!1,includeScore:!1,keys:[],shouldSort:!0,sortFn:(e,t)=>e.score===t.score?e.idx<t.idx?-1:1:e.score<t.score?-1:1},ho={location:0,threshold:.6,distance:100},mo={useExtendedSearch:!1,useTokenSearch:!1,tokenize:void 0,tokenMatch:"any",getFn:co,ignoreLocation:!1,ignoreFieldNorm:!1,fieldNormWeight:1},F=Object.freeze({...po,...fo,...ho,...mo});function vo(e){return e>=9&&e<=13||e===32||e===160}function go(e=1,t=3){const s=new Map,o=Math.pow(10,t);return{get(l){let a=0,i=!1;for(let r=0;r<l.length;r++)vo(l.charCodeAt(r))?i=!1:i||(a++,i=!0);if(a===0&&(a=1),s.has(a))return s.get(a);const u=Math.round(o/Math.pow(a,.5*e))/o;return s.set(a,u),u},clear(){s.clear()}}}var jt=class{constructor({getFn:e=F.getFn,fieldNormWeight:t=F.fieldNormWeight}={}){this.norm=go(t,3),this.getFn=e,this.isCreated=!1,this.docs=[],this.keys=[],this._keysMap={},this.setIndexRecords()}setSources(e=[]){this.docs=e}setIndexRecords(e=[]){this.records=e}setKeys(e=[]){this.keys=e,this._keysMap={},e.forEach((t,s)=>{this._keysMap[t.id]=s})}create(){if(this.isCreated||!this.docs.length)return;this.isCreated=!0;const e=this.docs.length;this.records=new Array(e);let t=0;if(ue(this.docs[0]))for(let s=0;s<e;s++){const o=this._createStringRecord(this.docs[s],s);o&&(this.records[t++]=o)}else for(let s=0;s<e;s++)this.records[t++]=this._createObjectRecord(this.docs[s],s);this.records.length=t,this.norm.clear()}add(e,t){if(!Number.isInteger(t)||t<0)throw new Error(kt);if(ue(e)){const o=this._createStringRecord(e,t);return o&&this.records.push(o),o}const s=this._createObjectRecord(e,t);return this.records.push(s),s}removeAt(e){if(!Number.isInteger(e)||e<0)throw new Error(kt);for(let t=0,s=this.records.length;t<s;t+=1)if(this.records[t].i===e){this.records.splice(t,1);break}for(let t=0,s=this.records.length;t<s;t+=1)this.records[t].i>e&&(this.records[t].i-=1)}removeAll(e){const t=new Set;for(const o of e)Number.isInteger(o)&&o>=0&&t.add(o);if(t.size===0)return;this.records=this.records.filter(o=>!t.has(o.i));const s=Array.from(t).sort((o,l)=>o-l);for(const o of this.records){let l=0,a=s.length;for(;l<a;){const i=l+a>>>1;s[i]<o.i?l=i+1:a=i}o.i-=l}}getValueForItemAtKeyId(e,t){return e[this._keysMap[t]]}size(){return this.records.length}_createStringRecord(e,t){return!pe(e)||Xe(e)?null:{v:e,i:t,n:this.norm.get(e)}}_createObjectRecord(e,t){const s={i:t,$:{}};for(let o=0,l=this.keys.length;o<l;o++){const a=this.keys[o],i=a.getFn?a.getFn(e):this.getFn(e,a.path);if(pe(i)){if(xe(i)){const u=[];for(let r=0,g=i.length;r<g;r+=1){const m=i[r];if(pe(m)){if(ue(m)){if(!Xe(m)){const v={v:m,i:r,n:this.norm.get(m)};u.push(v)}}else if(pe(m.v)){const v=ue(m.v)?m.v:_t(m.v);if(!Xe(v)){const f={v,i:m.i,n:this.norm.get(v)};u.push(f)}}}}s.$[o]=u}else if(ue(i)&&!Xe(i)){const u={v:i,n:this.norm.get(i)};s.$[o]=u}}}return s}toJSON(){return{keys:this.keys.map(({getFn:e,...t})=>t),records:this.records}}};function Ra(e,t,{getFn:s=F.getFn,fieldNormWeight:o=F.fieldNormWeight}={}){const l=new jt({getFn:s,fieldNormWeight:o});return l.setKeys(e.map(Oa)),l.setSources(t),l.create(),l}function yo(e,{getFn:t=F.getFn,fieldNormWeight:s=F.fieldNormWeight}={}){const{keys:o,records:l}=e,a=new jt({getFn:t,fieldNormWeight:s});return a.setKeys(o),a.setIndexRecords(l),a}function bo(e=[],t=F.minMatchCharLength){const s=[];let o=-1,l=-1,a=0;for(let i=e.length;a<i;a+=1){const u=e[a];u&&o===-1?o=a:!u&&o!==-1&&(l=a-1,l-o+1>=t&&s.push([o,l]),o=-1)}return e[a-1]&&a-o>=t&&s.push([o,a-1]),s}function wo(e,t,s,{location:o=F.location,distance:l=F.distance,threshold:a=F.threshold,findAllMatches:i=F.findAllMatches,minMatchCharLength:u=F.minMatchCharLength,includeMatches:r=F.includeMatches,ignoreLocation:g=F.ignoreLocation}={}){if(t.length>32)throw new Error(oo(32));const m=t.length,v=e.length,f=Math.max(0,Math.min(o,v));let c=a,p=f;const y=(x,k)=>{const j=x/m;if(g)return j;const G=Math.abs(f-k);return l?j+G/l:G?1:j},L=u>1||r,O=L?Array(v):[];let T;for(;(T=e.indexOf(t,p))>-1;){const x=y(0,T);if(c=Math.min(x,c),p=T+m,L){let k=0;for(;k<m;)O[T+k]=1,k+=1}}p=-1;let w=[],d=1,S=0,$=m+v;const B=1<<m-1;for(let x=0;x<m;x+=1){let k=0,j=$;for(;k<j;)y(x,f+j)<=c?k=j:$=j,j=Math.floor(($-k)/2+k);$=j;let G=Math.max(1,f-j+1);const Y=i?v:Math.min(f+j,v)+m,_=Array(Y+2);_[Y+1]=(1<<x)-1;for(let P=Y;P>=G;P-=1){const h=P-1,V=s[e[h]];if(_[P]=(_[P+1]<<1|1)&V,x&&(_[P]|=(w[P+1]|w[P])<<1|1|w[P+1]),_[P]&B&&(d=y(x,h),d<=c)){if(c=d,p=h,S=x,p<=f)break;G=Math.max(1,2*f-p)}}if(y(x+1,f)>c)break;w=_}if(L&&p>=0){const x=Math.min(v-1,p+m-1+S);for(let k=p;k<=x;k+=1)s[e[k]]&&(O[k]=1)}const C={isMatch:p>=0,score:Math.max(.001,d)};if(L){const x=bo(O,u);x.length?r&&(C.indices=x):C.isMatch=!1}return C}function _o(e){const t={};for(let s=0,o=e.length;s<o;s+=1){const l=e.charAt(s);t[l]=(t[l]||0)|1<<o-s-1}return t}function Ft(e){if(e.length<=1)return e;e.sort((s,o)=>s[0]-o[0]||s[1]-o[1]);const t=[e[0]];for(let s=1,o=e.length;s<o;s+=1){const l=t[t.length-1],a=e[s];a[0]<=l[1]+1?l[1]=Math.max(l[1],a[1]):t.push(a)}return t}const ja={ł:"l",Ł:"L",đ:"d",Đ:"D",ø:"o",Ø:"O",ħ:"h",Ħ:"H",ŧ:"t",Ŧ:"T",ı:"i",ß:"ss"},ko=new RegExp("["+Object.keys(ja).join("")+"]","g"),Ne=typeof String.prototype.normalize=="function"?e=>e.normalize("NFD").replace(/[\u0300-\u036F\u0483-\u0489\u0591-\u05BD\u05BF\u05C1\u05C2\u05C4\u05C5\u05C7\u0610-\u061A\u064B-\u065F\u0670\u06D6-\u06DC\u06DF-\u06E4\u06E7\u06E8\u06EA-\u06ED\u0711\u0730-\u074A\u07A6-\u07B0\u07EB-\u07F3\u07FD\u0816-\u0819\u081B-\u0823\u0825-\u0827\u0829-\u082D\u0859-\u085B\u08D3-\u08E1\u08E3-\u0903\u093A-\u093C\u093E-\u094F\u0951-\u0957\u0962\u0963\u0981-\u0983\u09BC\u09BE-\u09C4\u09C7\u09C8\u09CB-\u09CD\u09D7\u09E2\u09E3\u09FE\u0A01-\u0A03\u0A3C\u0A3E-\u0A42\u0A47\u0A48\u0A4B-\u0A4D\u0A51\u0A70\u0A71\u0A75\u0A81-\u0A83\u0ABC\u0ABE-\u0AC5\u0AC7-\u0AC9\u0ACB-\u0ACD\u0AE2\u0AE3\u0AFA-\u0AFF\u0B01-\u0B03\u0B3C\u0B3E-\u0B44\u0B47\u0B48\u0B4B-\u0B4D\u0B56\u0B57\u0B62\u0B63\u0B82\u0BBE-\u0BC2\u0BC6-\u0BC8\u0BCA-\u0BCD\u0BD7\u0C00-\u0C04\u0C3E-\u0C44\u0C46-\u0C48\u0C4A-\u0C4D\u0C55\u0C56\u0C62\u0C63\u0C81-\u0C83\u0CBC\u0CBE-\u0CC4\u0CC6-\u0CC8\u0CCA-\u0CCD\u0CD5\u0CD6\u0CE2\u0CE3\u0D00-\u0D03\u0D3B\u0D3C\u0D3E-\u0D44\u0D46-\u0D48\u0D4A-\u0D4D\u0D57\u0D62\u0D63\u0D82\u0D83\u0DCA\u0DCF-\u0DD4\u0DD6\u0DD8-\u0DDF\u0DF2\u0DF3\u0E31\u0E34-\u0E3A\u0E47-\u0E4E\u0EB1\u0EB4-\u0EB9\u0EBB\u0EBC\u0EC8-\u0ECD\u0F18\u0F19\u0F35\u0F37\u0F39\u0F3E\u0F3F\u0F71-\u0F84\u0F86\u0F87\u0F8D-\u0F97\u0F99-\u0FBC\u0FC6\u102B-\u103E\u1056-\u1059\u105E-\u1060\u1062-\u1064\u1067-\u106D\u1071-\u1074\u1082-\u108D\u108F\u109A-\u109D\u135D-\u135F\u1712-\u1714\u1732-\u1734\u1752\u1753\u1772\u1773\u17B4-\u17D3\u17DD\u180B-\u180D\u1885\u1886\u18A9\u1920-\u192B\u1930-\u193B\u1A17-\u1A1B\u1A55-\u1A5E\u1A60-\u1A7C\u1A7F\u1AB0-\u1ABE\u1B00-\u1B04\u1B34-\u1B44\u1B6B-\u1B73\u1B80-\u1B82\u1BA1-\u1BAD\u1BE6-\u1BF3\u1C24-\u1C37\u1CD0-\u1CD2\u1CD4-\u1CE8\u1CED\u1CF2-\u1CF4\u1CF7-\u1CF9\u1DC0-\u1DF9\u1DFB-\u1DFF\u20D0-\u20F0\u2CEF-\u2CF1\u2D7F\u2DE0-\u2DFF\u302A-\u302F\u3099\u309A\uA66F-\uA672\uA674-\uA67D\uA69E\uA69F\uA6F0\uA6F1\uA802\uA806\uA80B\uA823-\uA827\uA880\uA881\uA8B4-\uA8C5\uA8E0-\uA8F1\uA8FF\uA926-\uA92D\uA947-\uA953\uA980-\uA983\uA9B3-\uA9C0\uA9E5\uAA29-\uAA36\uAA43\uAA4C\uAA4D\uAA7B-\uAA7D\uAAB0\uAAB2-\uAAB4\uAAB7\uAAB8\uAABE\uAABF\uAAC1\uAAEB-\uAAEF\uAAF5\uAAF6\uABE3-\uABEA\uABEC\uABED\uFB1E\uFE00-\uFE0F\uFE20-\uFE2F]/g,"").replace(ko,t=>ja[t]):e=>e;var Pt=class{constructor(e,{location:t=F.location,threshold:s=F.threshold,distance:o=F.distance,includeMatches:l=F.includeMatches,findAllMatches:a=F.findAllMatches,minMatchCharLength:i=F.minMatchCharLength,isCaseSensitive:u=F.isCaseSensitive,ignoreDiacritics:r=F.ignoreDiacritics,ignoreLocation:g=F.ignoreLocation}={}){if(this.options={location:t,threshold:s,distance:o,includeMatches:l,findAllMatches:a,minMatchCharLength:i,isCaseSensitive:u,ignoreDiacritics:r,ignoreLocation:g},e=u?e:e.toLowerCase(),e=r?Ne(e):e,this.pattern=e,this.chunks=[],!this.pattern.length)return;const m=(f,c)=>{this.chunks.push({pattern:f,alphabet:_o(f),startIndex:c})},v=this.pattern.length;if(v>32){let f=0;const c=v%32,p=v-c;for(;f<p;)m(this.pattern.substr(f,32),f),f+=32;if(c){const y=v-32;m(this.pattern.substr(y),y)}}else m(this.pattern,0)}searchIn(e){const{isCaseSensitive:t,ignoreDiacritics:s,includeMatches:o}=this.options;if(e=t?e:e.toLowerCase(),e=s?Ne(e):e,this.pattern===e){if(e.length<this.options.minMatchCharLength)return{isMatch:!1,score:1};const p={isMatch:!0,score:0};return o&&(p.indices=[[0,e.length-1]]),p}const{location:l,distance:a,threshold:i,findAllMatches:u,minMatchCharLength:r,ignoreLocation:g}=this.options,m=[];let v=0,f=!1;this.chunks.forEach(({pattern:p,alphabet:y,startIndex:L})=>{const{isMatch:O,score:T,indices:w}=wo(e,p,y,{location:l+L,distance:a,threshold:i,findAllMatches:u,minMatchCharLength:r,includeMatches:o,ignoreLocation:g});O&&(f=!0),v+=T,O&&w&&m.push(...w)});const c={isMatch:f,score:f?v/this.chunks.length:1};return f&&o&&(c.indices=Ft(m)),c}};const xo=new Set(["fuzzy","include"]);function So(e){return e.startsWith("inverse")}const xt=[{type:"exact",multiRegex:/^="(.*)"$/,singleRegex:/^=(.*)$/,create:e=>({type:"exact",search(t){const s=t===e;return{isMatch:s,score:s?0:1,indices:[0,e.length-1]}}})},{type:"include",multiRegex:/^'"(.*)"$/,singleRegex:/^'(.*)$/,create:e=>({type:"include",search(t){let s=0,o;const l=[],a=e.length;for(;(o=t.indexOf(e,s))>-1;)s=o+a,l.push([o,s-1]);const i=!!l.length;return{isMatch:i,score:i?0:1,indices:l}}})},{type:"prefix-exact",multiRegex:/^\^"(.*)"$/,singleRegex:/^\^(.*)$/,create:e=>({type:"prefix-exact",search(t){const s=t.startsWith(e);return{isMatch:s,score:s?0:1,indices:[0,e.length-1]}}})},{type:"inverse-prefix-exact",multiRegex:/^!\^"(.*)"$/,singleRegex:/^!\^(.*)$/,create:e=>({type:"inverse-prefix-exact",search(t){const s=!t.startsWith(e);return{isMatch:s,score:s?0:1,indices:[0,t.length-1]}}})},{type:"inverse-suffix-exact",multiRegex:/^!"(.*)"\$$/,singleRegex:/^!(.*)\$$/,create:e=>({type:"inverse-suffix-exact",search(t){const s=!t.endsWith(e);return{isMatch:s,score:s?0:1,indices:[0,t.length-1]}}})},{type:"suffix-exact",multiRegex:/^"(.*)"\$$/,singleRegex:/^(.*)\$$/,create:e=>({type:"suffix-exact",search(t){const s=t.endsWith(e);return{isMatch:s,score:s?0:1,indices:[t.length-e.length,t.length-1]}}})},{type:"inverse-exact",multiRegex:/^!"(.*)"$/,singleRegex:/^!(.*)$/,create:e=>({type:"inverse-exact",search(t){const s=t.indexOf(e)===-1;return{isMatch:s,score:s?0:1,indices:[0,t.length-1]}}})},{type:"fuzzy",multiRegex:/^"(.*)"$/,singleRegex:/^(.*)$/,create:(e,t={})=>{const s=new Pt(e,{location:t.location??F.location,threshold:t.threshold??F.threshold,distance:t.distance??F.distance,includeMatches:t.includeMatches??F.includeMatches,findAllMatches:t.findAllMatches??F.findAllMatches,minMatchCharLength:t.minMatchCharLength??F.minMatchCharLength,isCaseSensitive:t.isCaseSensitive??F.isCaseSensitive,ignoreDiacritics:t.ignoreDiacritics??F.ignoreDiacritics,ignoreLocation:t.ignoreLocation??F.ignoreLocation});return{type:"fuzzy",search(o){return s.searchIn(o)}}}}],ta=xt.length,$o="\0",Co="|";function Io(e){const t=[],s=e.length;let o=0;for(;o<s;){for(;o<s&&e[o]===" ";)o++;if(o>=s)break;let l=o;for(;l<s&&e[l]!==" "&&e[l]!=='"';)l++;if(l<s&&e[l]==='"'){for(l++;l<s;){if(e[l]==='"'){const a=l+1;if(a>=s||e[a]===" "){l++;break}if(e[a]==="$"&&(a+1>=s||e[a+1]===" ")){l+=2;break}}l++}t.push(e.substring(o,l)),o=l}else{for(;l<s&&e[l]!==" ";)l++;t.push(e.substring(o,l)),o=l}}return t}function aa(e,t){const s=e.match(t);return s?s[1]:null}function To(e,t={}){return e.replace(/\\\|/g,$o).split(Co).map(s=>{const o=Io(s.replace(/\u0000/g,"|").trim()).filter(a=>a&&!!a.trim()),l=[];for(let a=0,i=o.length;a<i;a+=1){const u=o[a];let r=!1,g=-1;for(;!r&&++g<ta;){const m=xt[g],v=aa(u,m.multiRegex);v&&(l.push(m.create(v,t)),r=!0)}if(!r)for(g=-1;++g<ta;){const m=xt[g],v=aa(u,m.singleRegex);if(v){l.push(m.create(v,t));break}}}return l})}var Ao=class{constructor(e,{isCaseSensitive:t=F.isCaseSensitive,ignoreDiacritics:s=F.ignoreDiacritics,includeMatches:o=F.includeMatches,minMatchCharLength:l=F.minMatchCharLength,ignoreLocation:a=F.ignoreLocation,findAllMatches:i=F.findAllMatches,location:u=F.location,threshold:r=F.threshold,distance:g=F.distance}={}){this.query=null,this.options={isCaseSensitive:t,ignoreDiacritics:s,includeMatches:o,minMatchCharLength:l,findAllMatches:i,ignoreLocation:a,location:u,threshold:r,distance:g},e=t?e:e.toLowerCase(),e=s?Ne(e):e,this.pattern=e,this.query=To(this.pattern,this.options)}static condition(e,t){return t.useExtendedSearch}searchIn(e){const t=this.query;if(!t)return{isMatch:!1,score:1};const{includeMatches:s,isCaseSensitive:o,ignoreDiacritics:l}=this.options;e=o?e:e.toLowerCase(),e=l?Ne(e):e;let a=0;const i=[];let u=0,r=!1;for(let g=0,m=t.length;g<m;g+=1){const v=t[g];i.length=0,a=0,r=!1;for(let f=0,c=v.length;f<c;f+=1){const p=v[f],{isMatch:y,indices:L,score:O}=p.search(e);if(y)a+=1,u+=O,So(p.type)&&(r=!0),s&&(xo.has(p.type)?i.push(...L):i.push(L));else{u=0,a=0,i.length=0,r=!1;break}}if(a){const f={isMatch:!0,score:u/a};return r&&(f.hasInverse=!0),s&&(f.indices=Ft(i)),f}}return{isMatch:!1,score:1}}};const St=[];function zt(...e){St.push(...e)}function it(e,t){for(let s=0,o=St.length;s<o;s+=1){const l=St[s];if(l.condition(e,t))return new l(e,t)}return new Pt(e,t)}const rt={AND:"$and",OR:"$or"},$t={PATH:"$path",PATTERN:"$val"},Ct=e=>!!(e[rt.AND]||e[rt.OR]),Do=e=>!!e[$t.PATH],Bo=e=>!xe(e)&&Ea(e)&&!Ct(e),na=e=>({[rt.AND]:Object.keys(e).map(t=>({[t]:e[t]}))});function Fa(e,t,{auto:s=!0}={}){const o=l=>{if(ue(l)){const r={keyId:null,pattern:l};return s&&(r.searcher=it(l,t)),r}const a=Object.keys(l),i=Do(l);if(!i&&a.length>1&&!Ct(l))return o(na(l));if(Bo(l)){const r=i?l[$t.PATH]:a[0],g=i?l[$t.PATTERN]:l[r];if(!ue(g))throw new Error(so(r));const m={keyId:tt(r),pattern:g};return s&&(m.searcher=it(g,t)),m}const u={children:[],operator:a[0]};return a.forEach(r=>{const g=l[r];xe(g)&&g.forEach(m=>{u.children.push(o(m))})}),u};return Ct(e)||(e=na(e)),o(e)}function It(e,{ignoreFieldNorm:t=F.ignoreFieldNorm}){let s=1;return e.forEach(({key:o,norm:l,score:a})=>{const i=o?o.weight:null;s*=Math.pow(a===0&&i?Number.EPSILON:a,(i||1)*(t?1:l))}),s}function Lo(e,{ignoreFieldNorm:t=F.ignoreFieldNorm}){e.forEach(s=>{s.score=It(s.matches,{ignoreFieldNorm:t})})}var Eo=class{constructor(e,t){this.limit=e,this.heap=[],this.comparator=t}get size(){return this.heap.length}insert(e){this.size<this.limit?(this.heap.push(e),this._bubbleUp(this.size-1)):this.comparator(e,this.heap[0])<0&&(this.heap[0]=e,this._sinkDown(0))}extractSorted(){return this.heap.sort(this.comparator)}_bubbleUp(e){const t=this.heap;for(;e>0;){const s=e-1>>1;if(this.comparator(t[e],t[s])<=0)break;const o=t[e];t[e]=t[s],t[s]=o,e=s}}_sinkDown(e){const t=this.heap,s=t.length;let o=e;do{e=o;const l=2*e+1,a=2*e+2;if(l<s&&this.comparator(t[l],t[o])>0&&(o=l),a<s&&this.comparator(t[a],t[o])>0&&(o=a),o!==e){const i=t[e];t[e]=t[o],t[o]=i}}while(o!==e)}};function Mo(e){const t=[];return e.matches.forEach(s=>{if(!pe(s.indices)||!s.indices.length)return;const o={indices:s.indices,value:s.value};s.key&&(o.key=s.key.id),s.idx>-1&&(o.refIndex=s.idx),t.push(o)}),t}function Oo(e,t,{includeMatches:s=F.includeMatches,includeScore:o=F.includeScore}={}){return e.map(l=>{const{idx:a}=l,i={item:t[a],refIndex:a};return s&&(i.matches=Mo(l)),o&&(i.score=l.score),i})}const Ro=/[\p{L}\p{M}\p{N}_]+/gu,sa=new WeakSet;function jo(e){sa.has(e)||(sa.add(e),console.warn(`[Fuse] tokenize regex ${e} lacks the global flag; only the first match per text will be returned. Add the 'g' flag.`))}function Fo(e){if(typeof e=="function"){let t=!1;return s=>{const o=e(s);if(!t&&(t=!0,!Array.isArray(o)||o.some(l=>typeof l!="string")))throw new Error(`[Fuse] tokenize function must return string[]; received ${Array.isArray(o)?"array containing non-strings":typeof o}.`);return o}}return e instanceof RegExp?(e.global||jo(e),t=>t.match(e)||[]):t=>t.match(Ro)||[]}function Tt({isCaseSensitive:e=!1,ignoreDiacritics:t=!1,tokenize:s}={}){const o=Fo(s);return{tokenize(l){return e||(l=l.toLowerCase()),t&&(l=Ne(l)),o(l)}}}var Po=class{static condition(e,t){return t.useTokenSearch}constructor(e,t){this.options=t,this.analyzer=Tt({isCaseSensitive:t.isCaseSensitive,ignoreDiacritics:t.ignoreDiacritics,tokenize:t.tokenize});const s=this.analyzer.tokenize(e),{df:o,fieldCount:l}=t._invertedIndex;this.termSearchers=[],this.idfWeights=[];for(const a of s){this.termSearchers.push(new Pt(a,{location:t.location,threshold:t.threshold,distance:t.distance,includeMatches:t.includeMatches,findAllMatches:t.findAllMatches,minMatchCharLength:t.minMatchCharLength,isCaseSensitive:t.isCaseSensitive,ignoreDiacritics:t.ignoreDiacritics,ignoreLocation:!0}));const i=o.get(a)||0,u=Math.log(1+(l-i+.5)/(i+.5));this.idfWeights.push(u)}this.combineAll=t.tokenMatch==="all",this.numTerms=this.termSearchers.length,this.useMask=this.numTerms<=31}searchIn(e){if(!this.termSearchers.length)return{isMatch:!1,score:1};const t=[];let s=0,o=0,l=0,a=0;const i=this.combineAll&&!this.useMask?new Set:null;for(let g=0;g<this.termSearchers.length;g++){const m=this.termSearchers[g].searchIn(e),v=this.idfWeights[g];o+=v,m.isMatch&&(l++,s+=v*(1-m.score),m.indices&&t.push(...m.indices),this.combineAll&&(this.useMask?a|=1<<g:i.add(g)))}if(l===0)return{isMatch:!1,score:1};const u=o>0?1-s/o:0,r={isMatch:!0,score:Math.max(.001,u)};return this.options.includeMatches&&t.length&&(r.indices=Ft(t)),this.combineAll&&(this.useMask?r.matchedMask=a:r.matchedTerms=i,r.termCount=this.numTerms),r}};function mt(e,t,s,o){const l=o.tokenize(t);if(!l.length)return;e.fieldCount++,e.docFieldCount.set(s,(e.docFieldCount.get(s)||0)+1);const a=new Set(l);let i=e.docTermFieldHits.get(s);i||(i=new Map,e.docTermFieldHits.set(s,i));for(const u of a)i.set(u,(i.get(u)||0)+1),e.df.set(u,(e.df.get(u)||0)+1)}function Pa(e,t,s,o){const{i:l,v:a,$:i}=t;if(a!==void 0){mt(e,a,l,o);return}if(i)for(let u=0;u<s;u++){const r=i[u];if(r)if(Array.isArray(r))for(const g of r)mt(e,g.v,l,o);else mt(e,r.v,l,o)}}function zo(e,t,s){const o={fieldCount:0,df:new Map,docFieldCount:new Map,docTermFieldHits:new Map};for(const l of e)Pa(o,l,t,s);return o}function qo(e,t,s,o){Pa(e,t,s,o)}function No(e,t){const s=e.docFieldCount.get(t);if(s===void 0)return;e.fieldCount-=s,e.docFieldCount.delete(t);const o=e.docTermFieldHits.get(t);if(o){for(const[l,a]of o){const i=(e.df.get(l)||0)-a;i<=0?e.df.delete(l):e.df.set(l,i)}e.docTermFieldHits.delete(t)}}function oa(e,t){if(t.length===0)return;const s=Array.from(new Set(t)).sort((u,r)=>u-r);for(const u of s)No(e,u);const o=u=>{let r=0,g=s.length;for(;r<g;){const m=r+g>>>1;s[m]<u?r=m+1:g=m}return u-r},l=s[0],a=new Map;for(const[u,r]of e.docFieldCount)a.set(u>l?o(u):u,r);e.docFieldCount=a;const i=new Map;for(const[u,r]of e.docTermFieldHits)i.set(u>l?o(u):u,r);e.docTermFieldHits=i}var Se=class{constructor(e,t,s){this.options={...F,...t},this.options.useExtendedSearch,this.options.useTokenSearch,this._keyStore=new uo(this.options.keys),this._docs=e,this._myIndex=null,this._invertedIndex=null,this.setCollection(e,s),this._lastQuery=null,this._lastSearcher=null}_getSearcher(e){if(this._lastQuery===e)return this._lastSearcher;const t=it(e,this._invertedIndex?{...this.options,_invertedIndex:this._invertedIndex}:this.options);return this._lastQuery=e,this._lastSearcher=t,t}setCollection(e,t){if(this._docs=e,t&&!(t instanceof jt))throw new Error(no);if(this._myIndex=t||Ra(this.options.keys,this._docs,{getFn:this.options.getFn,fieldNormWeight:this.options.fieldNormWeight}),this.options.useTokenSearch){const s=Tt({isCaseSensitive:this.options.isCaseSensitive,ignoreDiacritics:this.options.ignoreDiacritics,tokenize:this.options.tokenize});this._invertedIndex=zo(this._myIndex.records,this._myIndex.keys.length,s)}this._invalidateSearcherCache()}add(e){if(!pe(e))return;this._docs.push(e);const t=this._myIndex.add(e,this._docs.length-1);if(this._invertedIndex&&t){const s=Tt({isCaseSensitive:this.options.isCaseSensitive,ignoreDiacritics:this.options.ignoreDiacritics,tokenize:this.options.tokenize});qo(this._invertedIndex,t,this._myIndex.keys.length,s)}this._invalidateSearcherCache()}remove(e=()=>!1){const t=[],s=[];for(let o=0,l=this._docs.length;o<l;o+=1)e(this._docs[o],o)&&(t.push(this._docs[o]),s.push(o));if(s.length){this._invertedIndex&&oa(this._invertedIndex,s);const o=new Set(s);this._docs=this._docs.filter((l,a)=>!o.has(a)),this._myIndex.removeAll(s),this._invalidateSearcherCache()}return t}removeAt(e){if(!Number.isInteger(e)||e<0||e>=this._docs.length)throw new Error(kt);this._invertedIndex&&oa(this._invertedIndex,[e]);const t=this._docs.splice(e,1)[0];return this._myIndex.removeAt(e),this._invalidateSearcherCache(),t}_invalidateSearcherCache(){this._lastQuery=null,this._lastSearcher=null}getIndex(){return this._myIndex}_normalizedKeys(){return this._myIndex.keys.map(e=>this._keyStore.get(e.id)||e)}search(e,t){const{limit:s=-1}=t||{},{includeMatches:o,includeScore:l,shouldSort:a,sortFn:i,ignoreFieldNorm:u}=this.options;if(ue(e)&&!e.trim()){let f=this._docs.map((c,p)=>({item:c,refIndex:p}));return et(s)&&s>-1&&(f=f.slice(0,s)),f}const r=a&&et(s)&&s>0&&ue(e),g=i,m=(f,c)=>g(f,c)||f.idx-c.idx;let v;if(r){const f=new Eo(s,m);ue(this._docs[0])?this._searchStringList(e,{heap:f,ignoreFieldNorm:u}):this._searchObjectList(e,{heap:f,ignoreFieldNorm:u}),v=f.extractSorted()}else v=ue(e)?ue(this._docs[0])?this._searchStringList(e):this._searchObjectList(e):this._searchLogical(e),Lo(v,{ignoreFieldNorm:u}),a&&v.sort(ue(e)?m:g),et(s)&&s>-1&&(v=v.slice(0,s));return Oo(v,this._docs,{includeMatches:o,includeScore:l})}_searchStringList(e,{heap:t,ignoreFieldNorm:s}={}){const o=this._getSearcher(e),l=this.options.useTokenSearch&&this.options.tokenMatch==="all",{records:a}=this._myIndex,i=t?null:[];return a.forEach(({v:u,i:r,n:g})=>{if(!pe(u))return;const m=o.searchIn(u);if(m.isMatch){const v={score:m.score,value:u,norm:g,indices:m.indices};l&&(v.matchedMask=m.matchedMask,v.matchedTerms=m.matchedTerms,v.termCount=m.termCount);const f=[v];if(!l||this._coversAllTokens(f)){const c={item:u,idx:r,matches:f};t?(c.score=It(c.matches,{ignoreFieldNorm:s}),t.insert(c)):i.push(c)}}}),i}_searchLogical(e){const t=Fa(e,this.options),s=this._normalizedKeys(),o=(u,r,g)=>{if(!("children"in u)){const{keyId:c,searcher:p}=u;let y;return c===null?(y=[],s.forEach((L,O)=>{y.push(...this._findMatches({key:L,value:r[O],searcher:p}))})):y=this._findMatches({key:this._keyStore.get(c),value:this._myIndex.getValueForItemAtKeyId(r,c),searcher:p}),y&&y.length?[{idx:g,item:r,matches:y}]:[]}const{children:m,operator:v}=u,f=[];for(let c=0,p=m.length;c<p;c+=1){const y=m[c],L=o(y,r,g);if(L.length)f.push(...L);else if(v===rt.AND)return[]}return f},l=this._myIndex.records,a=new Map,i=[];return l.forEach(({$:u,i:r})=>{if(pe(u)){const g=o(t,u,r);g.length&&(a.has(r)||(a.set(r,{idx:r,item:u,matches:[]}),i.push(a.get(r))),g.forEach(({matches:m})=>{a.get(r).matches.push(...m)}))}}),i}_searchObjectList(e,{heap:t,ignoreFieldNorm:s}={}){const o=this._getSearcher(e),l=this.options.useTokenSearch&&this.options.tokenMatch==="all",{records:a}=this._myIndex,i=this._normalizedKeys(),u=t?null:[];return a.forEach(({$:r,i:g})=>{if(!pe(r))return;const m=[];let v=!1,f=!1;if(i.forEach((c,p)=>{const y=this._findMatches({key:c,value:r[p],searcher:o});y.length?(m.push(...y),y[0].hasInverse&&(f=!0)):v=!0}),!(f&&v)&&m.length&&(!l||this._coversAllTokens(m))){const c={idx:g,item:r,matches:m};t?(c.score=It(c.matches,{ignoreFieldNorm:s}),t.insert(c)):u.push(c)}}),u}_findMatches({key:e,value:t,searcher:s}){if(!pe(t))return[];const o=[];if(xe(t))t.forEach(({v:l,i:a,n:i})=>{if(!pe(l))return;const u=s.searchIn(l);if(u.isMatch){const r={score:u.score,key:e,value:l,idx:a,norm:i,indices:u.indices,hasInverse:u.hasInverse};u.termCount!==void 0&&(r.matchedMask=u.matchedMask,r.matchedTerms=u.matchedTerms,r.termCount=u.termCount),o.push(r)}});else{const{v:l,n:a}=t,i=s.searchIn(l);if(i.isMatch){const u={score:i.score,key:e,value:l,norm:a,indices:i.indices,hasInverse:i.hasInverse};i.termCount!==void 0&&(u.matchedMask=i.matchedMask,u.matchedTerms=i.matchedTerms,u.termCount=i.termCount),o.push(u)}}return o}_coversAllTokens(e){const t=e.length?e[0].termCount:void 0;if(t===void 0)return!0;if(t<=31){let o=0;for(let l=0;l<e.length;l++)o|=e[l].matchedMask||0;return o===2**t-1}const s=new Set;for(let o=0;o<e.length;o++){const l=e[o].matchedTerms;if(l)for(const a of l)s.add(a)}return s.size===t}};Se.version="7.5.0";Se.createIndex=Ra;Se.parseIndex=yo;Se.config=F;Se.match=function(e,t,s){if(s&&s.useTokenSearch)throw new Error(ro);return it(e,{...F,...s}).searchIn(t)};Se.parseQuery=Fa;zt(Ao);zt(Po);Se.use=function(...e){e.forEach(t=>zt(t))};var Ko=Se;function Uo(e,t,s){const o=()=>{var a,i;return new Ko((a=be(t))!==null&&a!==void 0?a:[],(i=be(s))===null||i===void 0?void 0:i.fuseOptions)},l=hn(o());return re(()=>{var a;return(a=be(s))===null||a===void 0?void 0:a.fuseOptions},()=>{l.value=o()},{deep:!0}),re(()=>be(t),a=>{l.value.setCollection(a)},{deep:!0}),{fuse:l,results:R(()=>{const a=be(s);if(a?.matchAllWhenSearchEmpty&&!be(e))return be(t).map((u,r)=>({item:u,refIndex:r}));const i=a?.resultLimit;return l.value.search(be(e),i?{limit:i}:void 0)})}}const Ho={"&":"&amp;","<":"&lt;",">":"&gt;",'"':"&quot;","'":"&#39;"};function Vo(e){return e.replace(/[&<>"']/g,t=>Ho[t])}function Wo(e){return/&(?:amp|lt|gt|quot|#39);/.test(e)}function vt(e){return Wo(e)?e:Vo(e)}function Go(e,t){let s="",o=0,l=!1;for(let a=e.length-1;a>=0;a--){if(e[a]===">")l=!0;else if(e[a]==="<"){l=!1,s=e[a]+s;continue}if(l||o++,o<=t)s=e[a]+s;else{s="..."+s;break}}return s}function gt(e,t,s,o,l){const a=l?t.match(/[\p{L}\p{M}\p{N}_]+/gu)||[]:[],i=a.length>0?Math.min(...a.map(r=>r.length)):t.length;function u(r,g=[]){r=r||"";let m="",v=0;g.forEach(c=>{if(c.length===2&&c[0]===c[1])return;const p=c[1]+1,y=p-c[0]>=i;m+=[vt(r.substring(v,c[0])),y&&"<mark>",vt(r.substring(c[0],p)),y&&"</mark>"].filter(Boolean).join(""),v=p}),m+=vt(r.substring(v));const f=m.indexOf("<mark>");return f!==-1&&(m=Go(m,m.length-f)),m}if(e.matches?.length){for(const r of e.matches)if(!(s&&r.key!==s)&&!o?.includes(r.key))return u(r.value,r.indices)}}const Jo={slots:{root:"flex flex-col min-h-0 min-w-0 divide-y divide-default",input:"",close:"",back:"p-0",content:"relative overflow-hidden flex flex-col",footer:"p-1",viewport:"relative scroll-py-1 overflow-y-auto flex-1 focus:outline-none",group:"p-1 isolate",empty:"text-center text-muted",label:"font-semibold text-highlighted",item:"group relative w-full flex items-start select-none outline-none before:absolute before:z-[-1] before:inset-px before:rounded-md data-disabled:cursor-not-allowed data-disabled:opacity-75",itemLeadingIcon:"shrink-0",itemLeadingAvatar:"shrink-0",itemLeadingAvatarSize:"",itemLeadingChip:"shrink-0",itemLeadingChipSize:"",itemTrailing:"ms-auto inline-flex items-center",itemTrailingIcon:"shrink-0",itemTrailingHighlightedIcon:"shrink-0 text-dimmed hidden group-data-highlighted:inline-flex",itemTrailingKbds:"hidden lg:inline-flex items-center shrink-0",itemTrailingKbdsSize:"",itemWrapper:"flex-1 flex flex-col text-start min-w-0",itemLabel:"truncate space-x-1 text-dimmed",itemLabelBase:"text-highlighted [&>mark]:text-primary [&>mark]:bg-primary/15",itemLabelPrefix:"text-default",itemLabelSuffix:"text-dimmed [&>mark]:text-primary [&>mark]:bg-primary/15",itemDescription:"truncate text-muted [&>mark]:text-primary [&>mark]:bg-primary/15"},variants:{virtualize:{true:{viewport:"p-1 isolate"},false:{viewport:"divide-y divide-default"}},size:{xs:{input:"[&>input]:h-10",empty:"py-3 text-xs",label:"p-1 text-[10px]/3 gap-1",item:"p-1 text-xs gap-1",itemLeadingIcon:"size-4",itemLeadingAvatarSize:"3xs",itemLeadingChip:"size-4",itemLeadingChipSize:"sm",itemTrailing:"gap-1",itemTrailingIcon:"size-4",itemTrailingHighlightedIcon:"size-4",itemTrailingKbds:"gap-0.5",itemTrailingKbdsSize:"sm"},sm:{input:"[&>input]:h-11",empty:"py-4 text-xs",label:"p-1.5 text-[10px]/3 gap-1.5",item:"p-1.5 text-xs gap-1.5",itemLeadingIcon:"size-4",itemLeadingAvatarSize:"3xs",itemLeadingChip:"size-4",itemLeadingChipSize:"sm",itemTrailing:"gap-1.5",itemTrailingIcon:"size-4",itemTrailingHighlightedIcon:"size-4",itemTrailingKbds:"gap-0.5",itemTrailingKbdsSize:"sm"},md:{input:"[&>input]:h-12",empty:"py-6 text-sm",label:"p-1.5 text-xs gap-1.5",item:"p-1.5 text-sm gap-1.5",itemLeadingIcon:"size-5",itemLeadingAvatarSize:"2xs",itemLeadingChip:"size-5",itemLeadingChipSize:"md",itemTrailing:"gap-1.5",itemTrailingIcon:"size-5",itemTrailingHighlightedIcon:"size-5",itemTrailingKbds:"gap-0.5",itemTrailingKbdsSize:"md"},lg:{input:"[&>input]:h-13",empty:"py-7 text-sm",label:"p-2 text-xs gap-2",item:"p-2 text-sm gap-2",itemLeadingIcon:"size-5",itemLeadingAvatarSize:"2xs",itemLeadingChip:"size-5",itemLeadingChipSize:"md",itemTrailing:"gap-2",itemTrailingIcon:"size-5",itemTrailingHighlightedIcon:"size-5",itemTrailingKbds:"gap-0.5",itemTrailingKbdsSize:"md"},xl:{input:"[&>input]:h-14",empty:"py-8 text-base",label:"p-2 text-sm gap-2",item:"p-2 text-base gap-2",itemLeadingIcon:"size-6",itemLeadingAvatarSize:"xs",itemLeadingChip:"size-6",itemLeadingChipSize:"lg",itemTrailing:"gap-2",itemTrailingIcon:"size-6",itemTrailingHighlightedIcon:"size-6",itemTrailingKbds:"gap-0.5",itemTrailingKbdsSize:"lg"}},active:{true:{item:"text-highlighted before:bg-elevated",itemLeadingIcon:"text-default"},false:{item:["text-default data-highlighted:not-data-disabled:text-highlighted data-highlighted:not-data-disabled:before:bg-elevated/50","transition-colors before:transition-colors"],itemLeadingIcon:["text-dimmed group-data-highlighted:not-group-data-disabled:text-default","transition-colors"]}},loading:{true:{itemLeadingIcon:"animate-spin"}}},defaultVariants:{size:"md"}},Yo=["innerHTML"],Qo=["innerHTML"],Xo=["innerHTML"],Zo=Object.assign({inheritAttrs:!1},{__name:"UCommandPalette",props:lt({as:{type:null,required:!1},size:{type:null,required:!1},icon:{type:[String,Boolean],required:!1,skipCheck:!0},trailingIcon:{type:null,required:!1},selectedIcon:{type:null,required:!1},childrenIcon:{type:null,required:!1},placeholder:{type:String,required:!1},autofocus:{type:Boolean,required:!1,default:!0},close:{type:[Boolean,Object],required:!1},closeIcon:{type:null,required:!1},back:{type:[Boolean,Object],required:!1,default:!0},backIcon:{type:null,required:!1},input:{type:[Boolean,Object],required:!1,default:!0},groups:{type:Array,required:!1},fuse:{type:Object,required:!1},virtualize:{type:[Boolean,Object],required:!1,default:!1},valueKey:{type:null,required:!1},labelKey:{type:null,required:!1,default:"label"},descriptionKey:{type:null,required:!1,default:"description"},preserveGroupOrder:{type:Boolean,required:!1,default:!1},searchDelay:{type:Number,required:!1,default:0},class:{type:null,required:!1},ui:{type:Object,required:!1},multiple:{type:Boolean,required:!1},disabled:{type:Boolean,required:!1},modelValue:{type:null,required:!1},defaultValue:{type:null,required:!1},highlightOnHover:{type:Boolean,required:!1,default:!0},selectionBehavior:{type:String,required:!1},by:{type:[String,Function],required:!1},loading:{type:Boolean,required:!1},loadingIcon:{type:null,required:!1}},{searchTerm:{type:String,default:""},searchTermModifiers:{}}),emits:lt(["update:modelValue","highlight","entryFocus","leave","update:open"],["update:searchTerm"]),setup(e,{emit:t}){const s=e,o=t,l=Ee(),a=Me("commandPalette",s),i=qe(e,"searchTerm",{type:String,default:""}),{t:u}=Ke(),r=Ie(),g=ze(ot(a,"as","disabled","multiple","modelValue","defaultValue","highlightOnHover","by"),o),m=Be(()=>a.virtualize?Le(typeof a.virtualize=="boolean"?{}:a.virtualize,{estimateSize:ns(C.value,"md",a.descriptionKey,!!l["item-description"])}):!1),[v,f]=nt({props:{item:{type:Object,required:!0},group:{type:Object,required:!1},index:{type:Number,required:!1}}}),c=R(()=>Oe({extend:Jo,...r.ui?.commandPalette||{}})({size:a.size,virtualize:!!a.virtualize})),p=R(()=>Le({},a.fuse,{fuseOptions:{ignoreLocation:!0,threshold:.1,keys:[a.labelKey,a.descriptionKey,"suffix"]},resultLimit:12,matchAllWhenSearchEmpty:!0})),y=U([]),L=R(()=>y.value[y.value.length-1]?.placeholder||a.placeholder||u("commandPalette.placeholder")),O=R(()=>y.value?.length?[y.value[y.value.length-1]]:a.groups),T=R(()=>O.value?.filter(_=>_.id?!_.ignoreFilter:(console.warn("[@nuxt/ui] CommandPalette group is missing an `id` property"),!1))?.flatMap(_=>_.items?.map(P=>({...P,group:_.id}))||[])||[]),w=mn(i,()=>a.searchDelay),{results:d}=Uo(w,T,p),S=vn(d,16,!0);function $(_,P){let h=P;return _?.postFilter&&typeof _.postFilter=="function"&&(h=_.postFilter(w.value,h)),{..._,items:h.slice(0,p.value.resultLimit).map(V=>({...V,labelHtml:V.labelHtml??gt(V,w.value,a.labelKey,void 0,p.value.fuseOptions?.useTokenSearch),suffixHtml:V.suffixHtml??gt(V,w.value,"suffix",[a.labelKey],p.value.fuseOptions?.useTokenSearch),descriptionHtml:V.descriptionHtml??gt(V,w.value,a.descriptionKey,[a.labelKey,"suffix"],p.value.fuseOptions?.useTokenSearch)}))}}const B=R(()=>{const _=O.value,P=S.value.reduce((M,J)=>{const{item:ne,matches:W}=J;return ne.group&&(M[ne.group]||=[],M[ne.group]?.push({...ne,matches:W})),M},{});if(a.preserveGroupOrder){const M=[];for(const J of _||[]){if(!J.items?.length)continue;const ne=J.ignoreFilter?J.items:P[J.id];if(!ne?.length)continue;const W=$(J,ne);W.items?.length&&M.push(W)}return M}const V=[...Object.entries(P).map(([M,J])=>{const ne=_?.find(_e=>_e.id===M);if(!ne)return;const W=$(ne,J);return W.items?.length?W:void 0}).filter(M=>!!M)];for(const M of _||[]){if(!M.ignoreFilter||!M.items?.length)continue;const J=$(M,M.items);if(!J.items?.length)continue;const ne=_.indexOf(M),W=new Set;for(let me=0;me<ne;me++)W.add(_[me].id);let _e=-1;for(let me=0;me<V.length;me++)W.has(V[me].id)&&(_e=me);V.splice(_e+1,0,J)}return V}),C=R(()=>B.value.flatMap(_=>_.items||[])),x=ga("rootRef");re(B,()=>{ut(()=>{const _=x.value;_?.$el?.contains(document.activeElement)?_?.highlightFirstItem():_?.highlightSelected(void 0,!1)})});function k(_){_.children?.length&&(y.value.push({id:`history-${y.value.length}`,label:_.label,slot:_.slot,placeholder:_.placeholder,items:_.children}),i.value="",x.value?.highlightFirstItem())}function j(){y.value.length&&(y.value.pop(),i.value="",x.value?.highlightFirstItem())}function G(){i.value||j()}function Y(_,P){P.children?.length?(_.preventDefault(),k(P)):P.onSelect?.(_)}return(_,P)=>(b(),z(de,null,[A(n(v),null,{default:I(({item:h,index:V,group:M})=>[A(ya,Z(n(gn)(h),{custom:""}),{default:I(({active:J,...ne})=>[A(n(Yn),{value:n(a).valueKey?n(ve)(h,n(a).valueKey):n(st)(h,["matches","group","onSelect","labelHtml","suffixHtml","descriptionHtml","children"]),disabled:h.disabled,"as-child":"",onSelect:W=>Y(W,h)},{default:I(()=>[A(yn,Z(ne,{"data-slot":"item",class:c.value.item({class:[n(a).ui?.item,h.ui?.item,h.class],active:J||h.active})}),{default:I(()=>[H(_.$slots,h.slot||M?.slot||"item",{item:h,index:V,ui:c.value},()=>[H(_.$slots,h.slot?`${h.slot}-leading`:M?.slot?`${M.slot}-leading`:"item-leading",{item:h,index:V,ui:c.value},()=>[h.loading?(b(),D(ke,{key:0,name:n(a).loadingIcon||n(r).ui.icons.loading,"data-slot":"itemLeadingIcon",class:K(c.value.itemLeadingIcon({class:[n(a).ui?.itemLeadingIcon,h.ui?.itemLeadingIcon],loading:!0}))},null,8,["name","class"])):h.icon?(b(),D(ke,{key:1,name:h.icon,"data-slot":"itemLeadingIcon",class:K(c.value.itemLeadingIcon({class:[n(a).ui?.itemLeadingIcon,h.ui?.itemLeadingIcon],active:J||h.active}))},null,8,["name","class"])):h.avatar?(b(),D(bn,Z({key:2,size:h.ui?.itemLeadingAvatarSize||n(a).ui?.itemLeadingAvatarSize||c.value.itemLeadingAvatarSize()},h.avatar,{"data-slot":"itemLeadingAvatar",class:c.value.itemLeadingAvatar({class:[n(a).ui?.itemLeadingAvatar,h.ui?.itemLeadingAvatar],active:J||h.active})}),null,16,["size","class"])):h.chip?(b(),D(wn,Z({key:3,size:h.ui?.itemLeadingChipSize||n(a).ui?.itemLeadingChipSize||c.value.itemLeadingChipSize(),inset:"",standalone:""},h.chip,{"data-slot":"itemLeadingChip",class:c.value.itemLeadingChip({class:[n(a).ui?.itemLeadingChip,h.ui?.itemLeadingChip],active:J||h.active})}),null,16,["size","class"])):E("",!0)]),h.prefix||h.labelHtml||n(ve)(h,n(a).labelKey)||h.suffixHtml||h.suffix||l[h.slot?`${h.slot}-label`:M?.slot?`${M.slot}-label`:"item-label"]||n(ve)(h,n(a).descriptionKey)||l[h.slot?`${h.slot}-description`:M?.slot?`${M.slot}-description`:"item-description"]?(b(),z("span",{key:0,"data-slot":"itemWrapper",class:K(c.value.itemWrapper({class:[n(a).ui?.itemWrapper,h.ui?.itemWrapper]}))},[N("span",{"data-slot":"itemLabel",class:K(c.value.itemLabel({class:[n(a).ui?.itemLabel,h.ui?.itemLabel],active:J||h.active}))},[H(_.$slots,h.slot?`${h.slot}-label`:M?.slot?`${M.slot}-label`:"item-label",{item:h,index:V,ui:c.value},()=>[h.prefix?(b(),z("span",{key:0,"data-slot":"itemLabelPrefix",class:K(c.value.itemLabelPrefix({class:[n(a).ui?.itemLabelPrefix,h.ui?.itemLabelPrefix]}))},Q(h.prefix),3)):E("",!0),h.labelHtml?(b(),z("span",{key:1,"data-slot":"itemLabelBase",class:K(c.value.itemLabelBase({class:[n(a).ui?.itemLabelBase,h.ui?.itemLabelBase],active:J||h.active})),innerHTML:h.labelHtml},null,10,Yo)):(b(),z("span",{key:2,"data-slot":"itemLabelBase",class:K(c.value.itemLabelBase({class:[n(a).ui?.itemLabelBase,h.ui?.itemLabelBase],active:J||h.active}))},Q(n(ve)(h,n(a).labelKey)),3)),h.suffixHtml?(b(),z("span",{key:3,"data-slot":"itemLabelSuffix",class:K(c.value.itemLabelSuffix({class:[n(a).ui?.itemLabelSuffix,h.ui?.itemLabelSuffix],active:J||h.active})),innerHTML:h.suffixHtml},null,10,Qo)):h.suffix?(b(),z("span",{key:4,"data-slot":"itemLabelSuffix",class:K(c.value.itemLabelSuffix({class:[n(a).ui?.itemLabelSuffix,h.ui?.itemLabelSuffix],active:J||h.active}))},Q(h.suffix),3)):E("",!0)])],2),h.descriptionHtml?(b(),z("span",{key:0,"data-slot":"itemDescription",class:K(c.value.itemDescription({class:[n(a).ui?.itemDescription,h.ui?.itemDescription]})),innerHTML:h.descriptionHtml},null,10,Xo)):n(ve)(h,n(a).descriptionKey)||l[h.slot?`${h.slot}-description`:M?.slot?`${M.slot}-description`:"item-description"]?(b(),z("span",{key:1,"data-slot":"itemDescription",class:K(c.value.itemDescription({class:[n(a).ui?.itemDescription,h.ui?.itemDescription]}))},[H(_.$slots,h.slot?`${h.slot}-description`:M?.slot?`${M.slot}-description`:"item-description",{item:h,index:V,ui:c.value},()=>[oe(Q(n(ve)(h,n(a).descriptionKey)),1)])],2)):E("",!0)],2)):E("",!0),N("span",{"data-slot":"itemTrailing",class:K(c.value.itemTrailing({class:[n(a).ui?.itemTrailing,h.ui?.itemTrailing]}))},[H(_.$slots,h.slot?`${h.slot}-trailing`:M?.slot?`${M.slot}-trailing`:"item-trailing",{item:h,index:V,ui:c.value},()=>[h.children&&h.children.length>0?(b(),D(ke,{key:0,name:n(a).childrenIcon||n(r).ui.icons.chevronRight,"data-slot":"itemTrailingIcon",class:K(c.value.itemTrailingIcon({class:[n(a).ui?.itemTrailingIcon,h.ui?.itemTrailingIcon]}))},null,8,["name","class"])):h.kbds?.length?(b(),z("span",{key:1,"data-slot":"itemTrailingKbds",class:K(c.value.itemTrailingKbds({class:[n(a).ui?.itemTrailingKbds,h.ui?.itemTrailingKbds]}))},[(b(!0),z(de,null,ge(h.kbds,(W,_e)=>(b(),D(ua,Z({key:_e,size:h.ui?.itemTrailingKbdsSize||n(a).ui?.itemTrailingKbdsSize||c.value.itemTrailingKbdsSize()},{ref_for:!0},typeof W=="string"?{value:W}:W),null,16,["size"]))),128))],2)):M?.highlightedIcon?(b(),D(ke,{key:2,name:M.highlightedIcon,"data-slot":"itemTrailingHighlightedIcon",class:K(c.value.itemTrailingHighlightedIcon({class:[n(a).ui?.itemTrailingHighlightedIcon,h.ui?.itemTrailingHighlightedIcon]}))},null,8,["name","class"])):E("",!0)]),h.children?.length?E("",!0):(b(),D(n(Qn),{key:0,"as-child":""},{default:I(()=>[A(ke,{name:n(a).selectedIcon||n(r).ui.icons.check,"data-slot":"itemTrailingIcon",class:K(c.value.itemTrailingIcon({class:[n(a).ui?.itemTrailingIcon,h.ui?.itemTrailingIcon]}))},null,8,["name","class"])]),_:2},1024))],2)])]),_:2},1040,["class"])]),_:2},1032,["value","disabled","onSelect"])]),_:2},1040)]),_:3}),A(n(as),Z({ref_key:"rootRef",ref:x,"data-slot":"root"},{...n(g),..._.$attrs},{"selection-behavior":n(a).selectionBehavior,class:c.value.root({class:[n(a).ui?.root,n(a).class]})}),{default:I(()=>[n(a).input?(b(),D(n(Xn),{key:0,modelValue:i.value,"onUpdate:modelValue":P[1]||(P[1]=h=>i.value=h),"as-child":""},{default:I(()=>[A(Et,Z({variant:"none",size:n(a).size,placeholder:L.value,autofocus:n(a).autofocus,loading:n(a).loading,"loading-icon":n(a).loadingIcon,"trailing-icon":n(a).trailingIcon,icon:n(a).icon===!1?void 0:n(a).icon??n(r).ui.icons.search},typeof n(a).input=="object"?n(a).input:{},{"data-slot":"input",class:c.value.input({class:n(a).ui?.input}),onKeydown:_n(G,["backspace"])}),Dt({_:2},[y.value?.length&&(n(a).back||l.back)?{name:"leading",fn:I(()=>[H(_.$slots,"back",{ui:c.value},()=>[A(ye,Z({size:n(a).size,icon:n(a).backIcon||n(r).ui.icons.arrowLeft,color:"neutral",variant:"link","aria-label":n(u)("commandPalette.back")},typeof n(a).back=="object"?n(a).back:{},{"data-slot":"back",class:c.value.back({class:n(a).ui?.back}),onClick:j}),null,16,["size","icon","aria-label","class"])])]),key:"0"}:void 0,n(a).close||l.close?{name:"trailing",fn:I(()=>[H(_.$slots,"close",{ui:c.value},()=>[n(a).close?(b(),D(ye,Z({key:0,size:n(a).size,icon:n(a).closeIcon||n(r).ui.icons.close,color:"neutral",variant:"ghost","aria-label":n(u)("commandPalette.close")},typeof n(a).close=="object"?n(a).close:{},{"data-slot":"close",class:c.value.close({class:n(a).ui?.close}),onClick:P[0]||(P[0]=h=>o("update:open",!1))}),null,16,["size","icon","aria-label","class"])):E("",!0)])]),key:"1"}:void 0]),1040,["size","placeholder","autofocus","loading","loading-icon","trailing-icon","icon","class"])]),_:3},8,["modelValue"])):E("",!0),A(n(Zn),{"data-slot":"content",class:K(c.value.content({class:n(a).ui?.content}))},{default:I(()=>[B.value?.length?(b(),z("div",{key:0,role:"presentation","data-slot":"viewport",class:K(c.value.viewport({class:n(a).ui?.viewport}))},[n(a).virtualize?(b(),D(n(es),Z({key:0,options:C.value,"text-content":h=>n(ve)(h,n(a).labelKey)},m.value),{default:I(({option:h,virtualItem:V})=>[A(n(f),{item:h,index:V.index},null,8,["item","index"])]),_:1},16,["options","text-content"])):(b(!0),z(de,{key:1},ge(B.value,h=>(b(),D(n(ts),{key:`group-${h.id}`,"data-slot":"group",class:K(c.value.group({class:n(a).ui?.group}))},{default:I(()=>[n(ve)(h,n(a).labelKey)||l[h.slot?`${h.slot}-group-label`:"group-label"]?(b(),D(n(vs),{key:0,"data-slot":"label",class:K(c.value.label({class:n(a).ui?.label}))},{default:I(()=>[H(_.$slots,h.slot?`${h.slot}-group-label`:"group-label",{group:h,label:n(ve)(h,n(a).labelKey),ui:c.value},()=>[oe(Q(n(ve)(h,n(a).labelKey)),1)])]),_:2},1032,["class"])):E("",!0),(b(!0),z(de,null,ge(h.items,(V,M)=>(b(),D(n(f),{key:`group-${h.id}-${M}`,item:V,index:M,group:h},null,8,["item","index","group"]))),128))]),_:2},1032,["class"]))),128))],2)):(b(),z("div",{key:1,"data-slot":"empty",class:K(c.value.empty({class:n(a).ui?.empty}))},[H(_.$slots,"empty",{searchTerm:i.value},()=>[oe(Q(i.value?n(u)("commandPalette.noMatch",{searchTerm:i.value}):n(u)("commandPalette.noData")),1)])],2))]),_:3},8,["class"]),l.footer?(b(),z("div",{key:1,"data-slot":"footer",class:K(c.value.footer({class:n(a).ui?.footer}))},[H(_.$slots,"footer",{ui:c.value})],2)):E("",!0)]),_:3},16,["selection-behavior","class"])],64))}}),el={slots:{modal:"",input:""},variants:{fullscreen:{false:{modal:"sm:max-w-3xl h-full sm:h-[28rem]"}},size:{xs:{},sm:{},md:{},lg:{},xl:{}}},defaultVariants:{size:"md"}},tl=/^[^-]+.*-.*[^-]+$/,al=/^[^_]+.*_.*[^_]+$/,la=["arrowleft","arrowright","arrowup","arrowdown","tab","escape","enter","backspace"];function Ze(e){return/^[a-z]$/i.test(e)?`Key${e.toUpperCase()}`:/^\d$/.test(e)?`Digit${e}`:/^f\d+$/i.test(e)?e.toUpperCase():{space:"Space",enter:"Enter",escape:"Escape",tab:"Tab",backspace:"Backspace",delete:"Delete",arrowup:"ArrowUp",arrowdown:"ArrowDown",arrowleft:"ArrowLeft",arrowright:"ArrowRight"}[e.toLowerCase()]||e}function za(e,t={}){const s=t.chainDelay??800,o=U([]),l=()=>{o.value.splice(0,o.value.length)},a=ba(l,s);let i;const u=()=>{i=void 0,g.stop()},r=()=>{const d=i;if(u(),!d)return;const S=T.value.find($=>$.key===d.shortcut.key&&!$.metaKey&&!$.ctrlKey&&!$.altKey&&!$.shiftKey);S?.enabled&&S.handler(d.event)},g=kn(()=>{r(),l()},s,{immediate:!1}),{macOS:m}=xn(),v=$n(),f=t.layoutIndependent??!1,c=la.map(d=>Ze(d)),p=d=>{if(!d.key)return;const S=f||d.altKey,$=S?/^Key[A-Z]$/i.test(d.code):/^[a-z]{1}$/i.test(d.key),B=S?c.includes(d.code):la.includes(d.key.toLowerCase());let C;if(o.value.push(f?d.code:d.key),o.value.length>=2){C=o.value.slice(-2).join("-");for(const x of O.value)if(x.key===C){x.enabled?(u(),d.preventDefault(),x.handler(d)):r(),l();return}}r();for(const x of T.value){if(f){if(d.code!==x.key)continue}else if(x.altKey&&d.altKey){if(d.code!==Ze(x.key))continue}else if(d.key.toLowerCase()!==x.key)continue;if(d.metaKey!==x.metaKey||d.ctrlKey!==x.ctrlKey||d.altKey!==x.altKey||($||B||x.shiftKey||d.shiftKey&&(d.metaKey||d.ctrlKey))&&d.shiftKey!==x.shiftKey)continue;if(!x.metaKey&&!x.ctrlKey&&!x.altKey&&!x.shiftKey&&w.value.has(x.key)){x.enabled&&d.preventDefault(),i={shortcut:x,event:d},g.start();return}x.enabled&&(d.preventDefault(),x.handler(d)),l();return}a()},y=R(()=>{const d=v.value?.tagName,S=v.value?.contentEditable;return d==="INPUT"||d==="TEXTAREA"||S==="true"||S==="plaintext-only"?v.value?.name||!0:!1}),L=R(()=>Object.entries(be(e)).map(([d,S])=>{if(!S)return null;let $;d.includes("-")&&d!=="-"&&!d.includes("_")&&!d.match(tl)?.length&&console.trace(`[Shortcut] Invalid key: "${d}"`),d.includes("_")&&d!=="_"&&!d.match(al)?.length&&console.trace(`[Shortcut] Invalid key: "${d}"`);const B=d.includes("-")&&d!=="-"&&!d.includes("_");if(B)f?$={key:d.split("-").map(k=>Ze(k)).join("-"),metaKey:!1,ctrlKey:!1,shiftKey:!1,altKey:!1}:$={key:d.toLowerCase(),metaKey:!1,ctrlKey:!1,shiftKey:!1,altKey:!1};else{const x=d.toLowerCase().split("_").map(j=>j);let k=x.filter(j=>!["meta","command","ctrl","shift","alt","option"].includes(j)).join("_");f&&(k=Ze(k)),$={key:k,metaKey:x.includes("meta")||x.includes("command"),ctrlKey:x.includes("ctrl"),shiftKey:x.includes("shift"),altKey:x.includes("alt")||x.includes("option")}}if($.chained=B,!m.value&&$.metaKey&&!$.ctrlKey&&($.metaKey=!1,$.ctrlKey=!0),typeof S=="function"?$.handler=S:typeof S=="object"&&($={...$,handler:S.handler}),!$.handler)return console.trace("[Shortcut] Invalid value"),null;let C=!0;return S.usingInput?typeof S.usingInput=="string"&&(C=y.value===S.usingInput):C=!y.value,$.enabled=C,$}).filter(Boolean)),O=R(()=>L.value.filter(d=>d.chained)),T=R(()=>L.value.filter(d=>!d.chained)),w=R(()=>new Set(O.value.map(d=>d.key.split("-")[0])));return Sn("keydown",p)}const nl={__name:"UDashboardSearch",props:lt({size:{type:null,required:!1},close:{type:[Boolean,Object],required:!1,default:!0},input:{type:[Boolean,Object],required:!1},shortcut:{type:String,required:!1,default:"meta_k"},fuse:{type:Object,required:!1},searchDelay:{type:Number,required:!1,default:100},colorMode:{type:Boolean,required:!1,default:!0},class:{type:null,required:!1},ui:{type:Object,required:!1},title:{type:String,required:!1},description:{type:String,required:!1},overlay:{type:Boolean,required:!1},transition:{type:Boolean,required:!1},content:{type:Object,required:!1},dismissible:{type:Boolean,required:!1},fullscreen:{type:Boolean,required:!1,default:!1},modal:{type:Boolean,required:!1},portal:{type:[Boolean,String],required:!1,skipCheck:!0},unmountOnHide:{type:Boolean,required:!1},icon:{type:[String,Boolean],required:!1,skipCheck:!0},trailingIcon:{type:null,required:!1},selectedIcon:{type:null,required:!1},childrenIcon:{type:null,required:!1},placeholder:{type:String,required:!1},autofocus:{type:Boolean,required:!1},loading:{type:Boolean,required:!1},loadingIcon:{type:null,required:!1},closeIcon:{type:null,required:!1},back:{type:[Boolean,Object],required:!1},backIcon:{type:null,required:!1},disabled:{type:Boolean,required:!1},highlightOnHover:{type:Boolean,required:!1},labelKey:{type:null,required:!1},descriptionKey:{type:null,required:!1},preserveGroupOrder:{type:Boolean,required:!1},virtualize:{type:[Boolean,Object],required:!1},groups:{type:Array,required:!1}},{open:{type:Boolean,default:!1},openModifiers:{},searchTerm:{type:String,default:""},searchTermModifiers:{}}),emits:["update:open","update:searchTerm"],setup(e,{expose:t}){const s=e,o=Ee(),l=Me("dashboardSearch",s),a=qe(e,"open",{type:Boolean,default:!1}),i=qe(e,"searchTerm",{type:String,default:""});wt("dashboard:search:toggle",()=>{a.value=!a.value});const{t:u}=Ke(),r=da(),g=Ie(),m=ze(ot(l,"size","icon","trailingIcon","selectedIcon","childrenIcon","placeholder","autofocus","loading","loadingIcon","close","closeIcon","back","backIcon","disabled","highlightOnHover","labelKey","descriptionKey","preserveGroupOrder","virtualize","searchDelay")),v=ze(ot(l,"overlay","transition","content","dismissible","fullscreen","modal","portal","unmountOnHide")),f=R(()=>l.input===!1?!1:Le(typeof l.input=="object"?l.input:{},{fixed:!0})),c=()=>st(o,["content"]),p=R(()=>Le({},l.fuse,{fuseOptions:{useTokenSearch:!0}})),y=R(()=>Oe({extend:el,...g.ui?.dashboardSearch||{}})({size:l.size,fullscreen:l.fullscreen})),L=R(()=>{const w=[];return w.push(...l.groups||[]),l.colorMode&&!r?.forced&&w.push({id:"theme",label:u("dashboardSearch.theme"),items:[{label:u("colorMode.system"),icon:g.ui.icons.system,active:r.preference==="system",onSelect:()=>{r.preference="system"}},{label:u("colorMode.light"),icon:g.ui.icons.light,active:r.preference==="light",onSelect:()=>{r.preference="light"}},{label:u("colorMode.dark"),icon:g.ui.icons.dark,active:r.preference==="dark",onSelect:()=>{r.preference="dark"}}]}),w}),O=ga("commandPaletteRef");function T(w){w.disabled||(a.value=!1,i.value="")}return za({[l.shortcut]:{usingInput:!0,handler:()=>a.value=!a.value}}),t({commandPaletteRef:O}),(w,d)=>(b(),D(ct,Z({open:a.value,"onUpdate:open":d[2]||(d[2]=S=>a.value=S),title:n(l).title||n(u)("dashboardSearch.title"),description:n(l).description||n(u)("dashboardSearch.description")},n(v),{"data-slot":"modal",class:y.value.modal({class:[n(l).ui?.modal,n(l).class]})}),{content:I(S=>[H(w.$slots,"content",Ae(De(S)),()=>[A(Zo,Z({ref_key:"commandPaletteRef",ref:O,"search-term":i.value,"onUpdate:searchTerm":d[0]||(d[0]=$=>i.value=$)},n(m),{groups:L.value,fuse:p.value,input:f.value,ui:n(ra)(n(st)(y.value,["modal"]),n(l).ui),"onUpdate:modelValue":T,"onUpdate:open":d[1]||(d[1]=$=>a.value=$)}),Dt({_:2},[ge(c(),($,B)=>({name:B,fn:I(C=>[H(w.$slots,B,Ae(De(C)))])}))]),1040,["search-term","groups","fuse","input","ui"])])]),_:3},16,["open","title","description","class"]))}},sl={class:"flex items-center gap-2"},ol={class:"space-y-4"},ll={class:"grid grid-cols-2 gap-3"},il={id:"jb-products"},rl=["value"],ul={class:"flex items-center gap-2"},cl={class:"text-xs font-medium text-muted uppercase tracking-wider"},dl={class:"flex items-center justify-between pt-1"},fl=fe({__name:"OpenInIdeSettingsModal",setup(e){const{prefs:t,settingsOpen:s,settingsContext:o}=$a(),l=Object.keys(Gt).map(c=>({label:Gt[c],value:c})),a=Object.keys(Jt).map(c=>({label:Jt[c],value:c})),i=R(()=>t.value.method==="auto"||t.value.method==="vscode"),u=R(()=>t.value.method!=="vscode"),r=R(()=>o.value.projectKey??null),g=R(()=>o.value.projectName||(r.value?`project ${r.value}`:""));function m(c){return R({get:()=>r.value?t.value[c][r.value]??"":"",set:p=>{const y=r.value;if(!y)return;const L={...t.value[c]};p.trim()?L[y]=p:delete L[y],t.value[c]=L}})}const v=m("projectRoots"),f=m("jetbrainsProjectNames");return(c,p)=>{const y=ke,L=ls,O=is,T=Ca,w=Et,d=Ia,S=rs,$=us,B=os,C=ye,x=ct;return b(),D(x,{open:n(s),"onUpdate:open":p[9]||(p[9]=k=>we(s)?s.value=k:null),ui:{content:"max-w-lg"}},{header:I(()=>[N("div",sl,[A(y,{name:"i-lucide-external-link",class:"size-5 text-primary"}),p[10]||(p[10]=N("h2",{class:"text-base font-semibold"},"Open in IDE",-1)),A(L,{topic:"ide.open"})])]),body:I(()=>[N("div",ol,[p[14]||(p[14]=N("p",{class:"text-sm text-muted"}," Click a source path anywhere in the dashboard to open it in your editor. These preferences are stored in this browser only. ",-1)),A(T,{label:"Method",name:"method",description:"Auto probes the JetBrains local server first, then falls back to a URL launch."},{default:I(()=>[A(O,{modelValue:n(t).method,"onUpdate:modelValue":p[0]||(p[0]=k=>n(t).method=k),items:n(l),class:"w-full"},null,8,["modelValue","items"])]),_:1}),A(T,{label:"Workspace root",name:"defaultRoot",description:"Absolute path to your local checkout — repo-relative paths are joined onto it (VS Code needs this)."},{default:I(()=>[A(w,{modelValue:n(t).defaultRoot,"onUpdate:modelValue":p[1]||(p[1]=k=>n(t).defaultRoot=k),placeholder:"/home/me/my-repo",class:"w-full"},null,8,["modelValue"])]),_:1}),n(i)?(b(),D(T,{key:0,label:"VS Code flavor",name:"vscodeScheme"},{default:I(()=>[A(O,{modelValue:n(t).vscodeScheme,"onUpdate:modelValue":p[2]||(p[2]=k=>n(t).vscodeScheme=k),items:n(a),class:"w-full"},null,8,["modelValue","items"])]),_:1})):E("",!0),n(u)?(b(),z(de,{key:1},[N("div",ll,[A(T,{label:"JetBrains product",name:"jetbrainsProduct",description:"e.g. idea, webstorm, pycharm."},{default:I(()=>[A(w,{modelValue:n(t).jetbrainsProduct,"onUpdate:modelValue":p[3]||(p[3]=k=>n(t).jetbrainsProduct=k),placeholder:"idea",list:"jb-products",class:"w-full"},null,8,["modelValue"]),N("datalist",il,[(b(!0),z(de,null,ge(n(qn),k=>(b(),z("option",{key:k,value:k},null,8,rl))),128))])]),_:1}),A(T,{label:"Local server port",name:"jetbrainsPort",description:"Remote Control plugin."},{default:I(()=>[A(w,{modelValue:n(t).jetbrainsPort,"onUpdate:modelValue":p[4]||(p[4]=k=>n(t).jetbrainsPort=k),modelModifiers:{number:!0},type:"number",class:"w-full"},null,8,["modelValue"])]),_:1})]),A(T,{name:"jetbrainsHttpUsesRelativePath"},{default:I(()=>[N("div",ul,[A(d,{modelValue:n(t).jetbrainsHttpUsesRelativePath,"onUpdate:modelValue":p[5]||(p[5]=k=>n(t).jetbrainsHttpUsesRelativePath=k)},null,8,["modelValue"]),p[11]||(p[11]=N("span",{class:"text-sm"},"Send a content-root-relative path to the local server",-1))])]),_:1})],64)):E("",!0),n(r)?(b(),z(de,{key:2},[A(S),N("p",cl,"Override for "+Q(n(g)),1),A(T,{label:"Workspace root override",name:"projectRoot",description:"Use a different local folder for this project (monorepos, multiple checkouts)."},{default:I(()=>[A(w,{modelValue:n(v),"onUpdate:modelValue":p[6]||(p[6]=k=>we(v)?v.value=k:null),placeholder:n(t).defaultRoot||"/home/me/this-project",class:"w-full"},null,8,["modelValue","placeholder"])]),_:1}),n(u)?(b(),D(T,{key:0,label:"JetBrains project name",name:"projectJbName",description:"The open IDE project name for the jetbrains:// link."},{default:I(()=>[A(w,{modelValue:n(f),"onUpdate:modelValue":p[7]||(p[7]=k=>we(f)?f.value=k:null),placeholder:n(g),class:"w-full"},null,8,["modelValue","placeholder"])]),_:1})):E("",!0)],64)):E("",!0),n(u)?(b(),D($,{key:3,color:"neutral",variant:"soft",icon:"i-lucide-info",title:"JetBrains prerequisites",description:"The jetbrains:// link needs JetBrains Toolbox. The local server needs the IDE Remote Control plugin with 'Allow unsigned requests', and browsers block it when this dashboard is served over HTTPS."})):E("",!0),N("div",dl,[A(B,{to:"ide-integration"},{default:I(()=>[...p[12]||(p[12]=[oe("Learn more",-1)])]),_:1}),A(C,{color:"neutral",onClick:p[8]||(p[8]=k=>s.value=!1)},{default:I(()=>[...p[13]||(p[13]=[oe("Done",-1)])]),_:1})])])]),_:1},8,["open"])}}}),pl=Object.assign(fl,{__name:"OpenInIdeSettingsModal"}),hl={class:"flex items-center gap-2"},ml={class:"space-y-4"},vl={class:"space-y-2"},gl={class:"min-w-0 flex-1"},yl={class:"text-sm truncate"},bl={class:"text-xs text-muted truncate"},wl={key:0,class:"text-xs text-error"},_l={class:"grid grid-cols-2 gap-3"},kl={class:"flex items-center justify-end w-full gap-2"},xl=fe({__name:"DesktopImportModal",setup(e){const{files:t,open:s,removeFile:o,clear:l}=Cn(),{data:a,execute:i,status:u}=Ot("/api/projects/menu",{immediate:!1,default:()=>[]},"$fWNyjYhgL_");re(s,w=>{w&&a.value.length===0&&i()});const r=U(),g=U(""),m=U(!0),v=U(!1),f=In({}),c=R(()=>a.value.map(w=>({label:w.label||w.name,value:w.name})));function p(w){return w.split(/[\\/]/).pop()||w}function y(){const w=new Uint8Array(32);return crypto.getRandomValues(w),Array.from(w,d=>d.toString(16).padStart(2,"0")).join("")}async function L(){if(!r.value||v.value||t.value.length===0)return;v.value=!0;const w=m.value&&t.value.length>1?y():void 0;try{for(const d of[...t.value]){const S=f[d]?.status;if(!(S==="imported"||S==="duplicate")){f[d]={status:"importing"};try{const $=await $fetch("/api/desktop/import-local",{method:"POST",body:{path:d,projectName:r.value,label:g.value.trim()||void 0,importGroup:w}});f[d]={status:$.status,testRunId:$.testRunId}}catch($){f[d]={status:"error",message:ds($)}}}}}finally{v.value=!1}}const O=R(()=>t.value.length>0&&t.value.every(w=>f[w]?.status==="imported"||f[w]?.status==="duplicate"));re(s,w=>{if(!w&&O.value){l();for(const d of Object.keys(f))delete f[d]}});function T(w){const d=f[w];if(!d)return null;switch(d.status){case"importing":return{label:"Importing…",color:"info"};case"imported":return{label:"Imported",color:"success"};case"duplicate":return{label:"Already imported",color:"neutral"};case"error":return{label:"Failed",color:"error"}}}return(w,d)=>{const S=ke,$=wa,B=ye,C=cs,x=ss,k=Ca,j=Et,G=Ia,Y=ct;return b(),D(Y,{open:n(s),"onUpdate:open":d[6]||(d[6]=_=>we(s)?s.value=_:null),ui:{content:"max-w-xl"}},{header:I(()=>[N("div",hl,[A(S,{name:"i-lucide-file-input",class:"size-5 text-primary"}),d[7]||(d[7]=N("h2",{class:"text-base font-semibold"},"Import archives",-1)),A($,{color:"neutral",variant:"subtle",size:"sm"},{default:I(()=>[oe(Q(n(t).length),1)]),_:1})])]),body:I(()=>[N("div",ml,[d[9]||(d[9]=N("p",{class:"text-sm text-muted"}," Playwright blob reports become complete runs; bare traces become single executions. Re-importing the same archive is a no-op, and imports never trigger notifications or regression signals. ",-1)),N("div",vl,[(b(!0),z(de,null,ge(n(t),_=>(b(),z("div",{key:_,class:"flex items-center gap-2 rounded-md border border-default p-2"},[A(S,{name:"i-lucide-file-archive",class:"size-4 text-gray-400 shrink-0"}),N("div",gl,[N("p",yl,Q(p(_)),1),N("p",bl,Q(_),1),n(f)[_]?.message?(b(),z("p",wl,Q(n(f)[_]?.message),1)):E("",!0)]),T(_)?(b(),D($,{key:0,color:T(_).color,variant:"subtle",size:"sm"},{default:I(()=>[oe(Q(T(_).label),1)]),_:2},1032,["color"])):E("",!0),n(f)[_]?.status==="imported"||n(f)[_]?.status==="duplicate"?(b(),D(B,{key:1,to:`/test-runs/${n(f)[_]?.testRunId}`,size:"xs",color:"neutral",variant:"soft",onClick:d[0]||(d[0]=P=>s.value=!1)},{default:I(()=>[...d[8]||(d[8]=[oe(" View run ",-1)])]),_:1},8,["to"])):(b(),D(B,{key:2,icon:"i-lucide-x",size:"xs",color:"neutral",variant:"ghost",disabled:n(v),"aria-label":"Remove from import",onClick:P=>n(o)(_)},null,8,["disabled","onClick"]))]))),128)),n(t).length===0?(b(),D(C,{key:0,icon:"i-lucide-file-x",text:"Nothing to import"})):E("",!0)]),A(k,{label:"Import into project",name:"projectName"},{default:I(()=>[A(x,{modelValue:n(r),"onUpdate:modelValue":d[1]||(d[1]=_=>we(r)?r.value=_:null),items:n(c),"value-key":"value",loading:n(u)==="pending",placeholder:"Select a project…",class:"w-full",disabled:n(v)},null,8,["modelValue","items","loading","disabled"])]),_:1}),N("div",_l,[A(k,{label:"Label",name:"label",description:"Optional run label."},{default:I(()=>[A(j,{modelValue:n(g),"onUpdate:modelValue":d[2]||(d[2]=_=>we(g)?g.value=_:null),disabled:n(v),class:"w-full"},null,8,["modelValue","disabled"])]),_:1}),n(t).length>1?(b(),D(k,{key:0,label:"Combine traces",name:"combine",description:"Gather dropped traces into one run."},{default:I(()=>[A(G,{modelValue:n(m),"onUpdate:modelValue":d[3]||(d[3]=_=>we(m)?m.value=_:null),disabled:n(v)},null,8,["modelValue","disabled"])]),_:1})):E("",!0)])])]),footer:I(()=>[N("div",kl,[A(B,{color:"neutral",variant:"ghost",onClick:d[4]||(d[4]=_=>s.value=!1)},{default:I(()=>[...d[10]||(d[10]=[oe("Close",-1)])]),_:1}),A(B,{icon:"i-lucide-file-input",loading:n(v),disabled:!n(r)||n(t).length===0||n(O),onClick:d[5]||(d[5]=_=>L())},{default:I(()=>[...d[11]||(d[11]=[oe(" Import ",-1)])]),_:1},8,["loading","disabled"])])]),_:1},8,["open"])}}}),Sl=Object.assign(xl,{__name:"DesktopImportModal"}),$l={key:0,class:"font-mono text-xs text-zinc-500"},Cl=fe({__name:"DesktopLocalRunConsole",props:{lines:{}},setup(e){const t=e,s=U(null),o=U(!0);function l(){const a=s.value;a&&(o.value=a.scrollHeight-a.scrollTop-a.clientHeight<24)}return re(()=>t.lines.length,async()=>{o.value&&(await ut(),s.value?.scrollTo({top:s.value.scrollHeight}))}),Re(()=>{s.value?.scrollTo({top:s.value.scrollHeight})}),(a,i)=>(b(),z("div",{ref_key:"el",ref:s,class:"h-56 overflow-y-auto rounded-md bg-zinc-950 p-3",onScrollPassive:l},[(b(!0),z(de,null,ge(e.lines,(u,r)=>(b(),z("p",{key:r,class:K(["font-mono text-xs whitespace-pre-wrap",u.error?"text-red-400":"text-zinc-300"])},Q(u.text||" "),3))),128)),e.lines.length===0?(b(),z("p",$l,"Waiting for output…")):E("",!0)],544))}}),Il=Object.assign(Cl,{__name:"DesktopLocalRunConsole"}),Tl={key:0,"aria-label":"Local runs",class:"fixed bottom-4 right-4 z-40 w-[600px] max-w-[calc(100vw-2rem)] rounded-lg border border-default bg-default shadow-xl"},Al={class:"flex items-center gap-2 px-3 py-2 border-b border-default"},Dl={class:"max-h-[60vh] overflow-y-auto divide-y divide-default"},Bl={key:0,class:"px-3 py-6 text-sm text-muted text-center"},Ll={class:"flex items-center gap-2 min-w-0"},El={class:"text-sm font-medium truncate shrink-0 max-w-40"},Ml=["title"],Ol={class:"text-xs text-muted tabular-nums shrink-0"},Rl={key:0,class:"mt-1.5"},jl=fe({__name:"DesktopLocalRunsTray",setup(e){const t=Sa(),{runs:s,trayOpen:o,activeCount:l}=t,a=U(!1);Re(()=>{a.value=!!ca()}),Rt(()=>t.correlatePiwiRuns());const i=U({});function u(c){return i.value[c.key]??(c.status==="running"||c.key===s.value[0]?.key)}function r(c){i.value={...i.value,[c.key]:!u(c)}}const g=Tn({interval:1e3});function m(c){const p=(c.finishedAt??g.value)-c.startedAt,y=Math.max(0,Math.round(p/1e3));return y<60?`${y}s`:`${Math.floor(y/60)}m ${String(y%60).padStart(2,"0")}s`}function v(c){switch(c.status){case"running":return{label:Pn(c),color:"info"};case"passed":return{label:"Passed",color:"success"};case"failed":return{label:c.exitCode!=null?`Failed (exit ${c.exitCode})`:"Failed",color:"error"};case"stopped":return{label:"Stopped",color:"neutral"};default:return{label:"Could not run",color:"error"}}}const f=R(()=>s.value.some(c=>c.status!=="running"));return(c,p)=>{const y=ke,L=wa,O=ye,T=Mt,w=Il;return b(),D(An,{to:"body"},[n(a)&&n(o)?(b(),z("section",Tl,[N("header",Al,[A(y,{name:"i-lucide-terminal",class:"size-4 text-muted shrink-0"}),p[3]||(p[3]=N("h2",{class:"text-sm font-semibold"},"Local runs",-1)),n(l)>0?(b(),D(L,{key:0,color:"info",variant:"subtle",size:"sm"},{default:I(()=>[oe(Q(n(l))+" active",1)]),_:1})):E("",!0),p[4]||(p[4]=N("span",{class:"flex-1"},null,-1)),n(f)?(b(),D(T,{key:1,text:"Clear finished runs"},{default:I(()=>[A(O,{size:"xs",color:"neutral",variant:"ghost",icon:"i-lucide-trash-2","aria-label":"Clear finished runs",onClick:p[0]||(p[0]=d=>n(t).clearFinished())})]),_:1})):E("",!0),A(O,{size:"xs",color:"neutral",variant:"ghost",icon:"i-lucide-x","aria-label":"Close local runs",onClick:p[1]||(p[1]=d=>o.value=!1)})]),N("div",Dl,[n(s).length===0?(b(),z("p",Bl," No local runs yet — start one from a “Run locally” button. ")):E("",!0),(b(!0),z(de,null,ge(n(s),d=>(b(),z("article",{key:d.key,class:"px-3 py-2"},[N("div",Ll,[A(L,{color:v(d).color,variant:"subtle",size:"sm",class:"shrink-0"},{default:I(()=>[oe(Q(v(d).label),1)]),_:2},1032,["color"]),N("span",El,Q(d.projectLabel||`Project ${d.projectId}`),1),N("code",{class:"text-[11px] text-muted truncate flex-1 min-w-0",title:d.steps[d.stepIndex]?.display},Q(d.steps[d.stepIndex]?.display),9,Ml),N("span",Ol,Q(m(d)),1),d.status==="running"?(b(),D(O,{key:0,size:"xs",color:"error",variant:"soft",icon:"i-lucide-square",onClick:S=>n(t).stopRun(d)},{default:I(()=>[...p[5]||(p[5]=[oe(" Stop ",-1)])]),_:1},8,["onClick"])):(b(),D(T,{key:1,text:"Run again with the same options"},{default:I(()=>[A(O,{size:"xs",color:"neutral",variant:"soft",icon:"i-lucide-rotate-ccw","aria-label":"Run again",onClick:S=>n(t).rerun(d)},null,8,["onClick"])]),_:2},1024)),A(O,{size:"xs",color:"neutral",variant:"ghost",icon:u(d)?"i-lucide-chevron-down":"i-lucide-chevron-left","aria-label":u(d)?"Collapse output":"Expand output",onClick:S=>r(d)},null,8,["icon","aria-label","onClick"])]),d.piwiRunId!=null?(b(),z("div",Rl,[A(O,{size:"xs",color:"success",variant:"soft",icon:"i-lucide-external-link",to:`/test-runs/${d.piwiRunId}`,onClick:p[2]||(p[2]=S=>o.value=!1)},{default:I(()=>[oe(" Live in Piwi — Run #"+Q(d.piwiRunId),1)]),_:2},1032,["to"])])):E("",!0),u(d)?(b(),D(w,{key:1,lines:d.lines,class:"mt-2"},null,8,["lines"])):E("",!0)]))),128))])])):E("",!0)])}}}),Fl=Object.assign(jl,{__name:"DesktopLocalRunsTray"}),Pl={base:"fixed inset-0 flex overflow-hidden"},zl={__name:"UDashboardGroup",props:{as:{type:null,required:!1},class:{type:null,required:!1},ui:{type:Object,required:!1},storage:{type:String,required:!1,default:"cookie"},storageKey:{type:String,required:!1,default:"dashboard"},storageOptions:{type:Object,required:!1},persistent:{type:Boolean,required:!1,default:!0},unit:{type:String,required:!1,default:"%"}},setup(e){const s=Me("dashboardGroup",e),o=ma(),l=Ie(),a=R(()=>Oe({extend:Pl,...l.ui?.dashboardGroup||{}})),i=U(!1),u=U(!1);return jn({storage:s.storage,storageKey:s.storageKey,storageOptions:s.storageOptions,persistent:s.persistent,unit:s.unit,sidebarOpen:i,toggleSidebar:()=>{o.hooks.callHook("dashboard:sidebar:toggle")},sidebarCollapsed:u,collapseSidebar:r=>{o.hooks.callHook("dashboard:sidebar:collapse",r)},toggleSearch:()=>{o.hooks.callHook("dashboard:search:toggle")}}),(r,g)=>(b(),D(n(ia),{as:n(s).as,class:K(a.value({class:[n(s).ui?.base,n(s).class]}))},{default:I(()=>[H(r.$slots,"default")]),_:3},8,["as","class"]))}},ql=fe({__name:"ProjectsMenu",props:{collapsed:{type:Boolean}},async setup(e){let t,s;const o=Lt(),l=_a(),{data:a,refresh:i}=([t,s]=ka(()=>Ot("/api/projects/menu","$uvvrKI5K9p")),t=await t,s(),t);Rt(i);const u=R(()=>{const m=o.params.id;return m?parseInt(m):null}),r=R(()=>{if(!u.value||!a.value)return{label:"All projects",icon:"i-lucide-folder-open"};const m=a.value.find(v=>v.id===u.value);return m?{label:m.label||m.name,icon:"i-lucide-folder"}:{label:"All projects",icon:"i-lucide-folder-open"}}),g=R(()=>{const m=[{label:"All projects",icon:"i-lucide-folder-open",onSelect(){l.push("/projects")}}];return a.value&&a.value.length>0&&m.push(...a.value.map(v=>({label:v.label||v.name,icon:"i-lucide-folder",onSelect(){l.push(`/projects/${v.id}`)}}))),[m]});return(m,v)=>{const f=ye,c=pa;return b(),D(c,{items:n(g),content:{align:"center",collisionPadding:12},ui:{content:e.collapsed?"w-40":"w-(--reka-dropdown-menu-trigger-width)"}},{default:I(()=>[A(f,Z({...n(r),label:e.collapsed?void 0:n(r)?.label,trailingIcon:e.collapsed?void 0:"i-lucide-chevrons-up-down"},{color:"neutral",variant:"ghost",block:"",square:e.collapsed,class:["data-[state=open]:bg-elevated",[!e.collapsed&&"py-2"]],ui:{trailingIcon:"text-dimmed"}}),null,16,["square","class"])]),_:1},8,["items","ui"])}}}),Nl=Object.assign(ql,{__name:"ProjectsMenu"});let yt=null,bt=!1,at=!0;window.addEventListener("focus",()=>{at=!0}),window.addEventListener("blur",()=>{at=!1}),at=document.hasFocus();let Pe=null;function Kl(e){const t=[];switch(e.type){case"run.finished":case"run.failed":case"run.failed.default_branch":case"flakiness.spike":case"perf.regression":{const s=e.projectName??`Project #${e.projectId}`,o=e.branch&&e.type!=="perf.regression"?` on ${e.branch}`:"";if(e.type==="run.finished"?t.push(`${s}${o}: ${e.status??"finished"}`):e.type==="run.failed"?t.push(`${s}${o}: ${e.failedTests??0}/${e.totalTests??0} tests failed`):e.type==="run.failed.default_branch"?t.push(`${s}: ${e.failedTests??0} failures on default branch`):e.type==="flakiness.spike"?t.push(`${s}: flakiness spike detected`):e.type==="perf.regression"&&t.push(`${s}: performance regression detected`),e.failedTests&&t.push(`${e.failedTests} failed, ${e.totalTests} total`),e.topFailures?.length){const[l,...a]=e.topFailures;t.push(a.length?`${l.title} +${a.length} more`:l.title)}break}case"cluster.new":t.push(`${e.projectName??`Project #${e.projectId}`}: new failure cluster`),e.signature&&t.push(e.signature);break;case"diagnosis.completed":case"diagnosis-completed":t.push(e.summary||e.rootCause||""),e.category&&t.push(`Category: ${e.category}`),e.confidence&&t.push(`Confidence: ${e.confidence}`);break}return t.filter(Boolean).join(`
2
+ `)}function Ul(e){return e.clusterId?`/failure-clusters/${e.clusterId}`:e.runId&&e.projectId?`/test-runs/${e.runId}`:null}let At=null;function qa(e){if(!("Notification"in window)||Notification.permission!=="granted"||document.visibilityState==="visible"&&at||(e.type==="diagnosis.completed"||e.type==="diagnosis-completed")&&At&&!At.value)return;if(Pe&&e.projectId!=null){const i=Pe.isEventSubscribed(e.projectId,e.type);if(console.log("[notify-stream] GATE: cookie filter",{projectId:e.projectId,type:e.type,subscribed:i,cookieProjects:Object.keys(Pe.stored.value.projects),matchingEvents:Pe.stored.value.projects[e.projectId]?.events??[]}),!i)return}const t=Kl(e);if(!t)return;const s=e.clusterId??e.runId??e.signature??e.type,o=`piwi-${e.type}-${s}`,l=new Notification("Piwi Dashboard",{body:t,tag:o,icon:"/logo.svg"});console.log("[notify-stream] notification fired",{type:e.type,projectId:e.projectId});const a=Ul(e);a?l.onclick=()=>{window.focus(),window.location.href=a,l.close()}:l.onclick=()=>{window.focus(),l.close()}}async function Hl(){if(Ue().public.demoMode)return!0;if(!("Notification"in window)||Notification.permission!=="granted")return!1;try{return(await $fetch("/api/channels")).channels.some(t=>t.type==="browser")}catch{return!1}}async function Vl(){const e=Ue();return e.public.demoMode?!0:e.public.authEnabled?Hl():!0}function Wl(){fs(e=>{e.scope==="notification"&&qa(e.event)})}function Gl(){yt=new EventSource("/api/notifications/stream"),yt.onmessage=e=>{try{const t=JSON.parse(e.data);qa(t)}catch{}},yt.onerror=()=>{}}function Jl(){if(bt)return;bt=!0,bt=!0;const{active:e}=ps();At=e;const t=Ue();t.public.authEnabled||(Pe=hs()),Vl().then(s=>{s&&(t.public.demoMode?Wl():Gl())}),va(()=>{})}const Yl=()=>{const e=_a();return za({"g-h":()=>e.push("/"),"g-p":()=>e.push("/projects"),"g-a":()=>e.push("/analytics"),"g-s":()=>e.push("/settings")}),{}},Ql=Dn(Yl),Xl={class:"flex flex-col gap-1 w-full"},Zl=10,Bi=fe({__name:"default",async setup(e){let t,s;const o=Lt(),l=Bn(),a=Ue(),i=U(!1),u=U(""),r=U(null),g=ba(async C=>{if(C.trim().length<2){r.value=null;return}try{r.value=await $fetch("/api/search",{query:{q:C.trim()}})}catch{r.value=null}},250);re(u,g),re(()=>i.value,C=>{C||(u.value="",r.value=null)});const{data:m,refresh:v}=([t,s]=ka(()=>Ot("/api/projects",{key:"projects",lazy:!0,default:()=>[]},"$uZFDOvnd1e")),t=await t,s(),t);Rt(v),Jl(),Ql();const{canSeeAdmin:f}=fa(),c=R(()=>{const C=o.path.match(/^\/projects\/(\d+)/);return C?.[1]?parseInt(C[1],10):null}),p=R(()=>{if(!m.value||m.value.length===0)return[];const C=Date.now()-Zl*24*60*60*1e3,x=[...m.value].sort((_,P)=>{const h=(_.label||_.name).toLowerCase(),V=(P.label||P.name).toLowerCase();return h.localeCompare(V)}),k=x.filter(_=>_.latestRun&&new Date(_.latestRun.startTime).getTime()>C),j=x.filter(_=>!_.latestRun||new Date(_.latestRun.startTime).getTime()<=C);function G(_){const P=c.value!==null&&c.value===_.id,h=_.latestRun?.status==="running"||_.latestRun?.status==="initialising",V=_.latestRun?.status||"unknown",M=V==="passed"?"i-lucide-circle-check-big":V==="failed"?"i-lucide-circle-x":"i-lucide-circle",J=V==="passed"?"success":V==="failed"?"error":h?"info":"neutral";return{label:_.label||_.name,icon:h?"i-lucide-loader-circle":"i-lucide-circle",ui:h?{linkLeadingIcon:"animate-spin"}:void 0,badge:{icon:M,color:J},value:`project-${_.id}`,type:"link",to:`/projects/${_.id}`,active:P}}const Y=[];return k.length>0&&(Y.push({label:`Active (${k.length})`,type:"label"}),Y.push(...k.map(G))),j.length>0&&(Y.push({label:`Others (${j.length})`,type:"label"}),Y.push(...j.map(G))),Y}),y=R(()=>{const C=[{label:"GitHub",icon:"i-lucide-github",to:"https://github.com/piwitests/platform",target:"_blank"}];return C.unshift({label:"MCP server",icon:"i-lucide-bot",to:"/mcp",onSelect:()=>{i.value=!1}}),f.value&&C.unshift({label:"Setup",icon:"i-lucide-rocket",to:"/setup",onSelect:()=>{i.value=!1}}),C.unshift({label:"API Docs",icon:"i-lucide-book-open",to:"/docs",onSelect:()=>{i.value=!1}}),[[{label:"Home",icon:"i-lucide-house",to:"/",onSelect:()=>{i.value=!1}},{label:"Analytics",icon:"i-lucide-chart-line",to:"/analytics",onSelect:()=>{i.value=!1}},{label:"Projects",icon:"i-lucide-folder",to:"/projects",onSelect:()=>{i.value=!1}},...p.value],C]}),L=C=>({label:typeof C.label=="string"?C.label:void 0,icon:C.icon,to:C.to,target:C.target,active:C.active,disabled:C.disabled,suffix:typeof C.badge=="string"?C.badge:void 0,children:C.children?.map(x=>L(x)),onSelect:C.onSelect}),O=R(()=>{const C="https://github.com/piwitests/platform/blob/main/application/app/pages",x="https://github.com/piwitests/platform/tree/main/application/app/pages",k=o.matched[o.matched.length-1]?.path??o.path;return k.includes(":")?x:`${C}${k==="/"?"/index":k}.vue`});function T(C){return C==="passed"?"i-lucide-circle-check-big":C==="failed"?"i-lucide-circle-x":C==="running"||C==="initialising"?"i-lucide-loader-circle":"i-lucide-circle"}const w=R(()=>{const C=[{id:"links",label:"Go to",items:y.value.flat().map(k=>L(k))},{id:"code",label:"Code",items:[{id:"source",label:"View page source",icon:"i-lucide-github",to:O.value,target:"_blank"}]}];if(c.value){const k=c.value,j=[["test-runs","Test runs","i-lucide-play"],["test-cases","Test cases","i-lucide-flask-conical"],["compare","Compare","i-lucide-git-compare-arrows"],["failure-clusters","Failure clusters","i-lucide-layers"],["flaky-tests","Flaky tests","i-lucide-shuffle"],["quarantine","Quarantine","i-lucide-shield-alert"],["spec-health","Spec health","i-lucide-table-2"],["performance","Performance","i-lucide-trending-up"],["timeline","Timeline","i-lucide-git-commit-horizontal"]];C.unshift({id:"project-tabs",label:"This project",items:j.map(([G,Y,_])=>({id:`project-tab-${G}`,label:Y,icon:_,to:`/projects/${k}?tab=${G}`,onSelect:()=>{i.value=!1}}))})}if(!r.value)return C;const x=[];return r.value.projects.length>0&&x.push({id:"search-projects",label:"Projects",ignoreFilter:!0,items:r.value.projects.map(k=>({id:`project-${k.id}`,label:k.label||k.name,description:k.label&&k.label!==k.name?k.name:void 0,icon:"i-lucide-folder",to:`/projects/${k.id}`}))}),r.value.runs.length>0&&x.push({id:"search-runs",label:"Test runs",ignoreFilter:!0,items:r.value.runs.map(k=>({id:`run-${k.id}`,label:k.label?`Run #${k.id} — ${k.label}`:`Run #${k.id}`,description:k.projectLabel||k.projectName,suffix:k.status,icon:T(k.status),to:`/test-runs/${k.id}`}))}),r.value.cases.length>0&&x.push({id:"search-cases",label:"Test cases",ignoreFilter:!0,items:r.value.cases.map(k=>({id:`case-${k.id}`,label:k.title,description:`${k.projectLabel||k.projectName} · ${k.filePath}`,icon:"i-lucide-flask-conical",to:`/test-cases/${k.id}`}))}),[...x,...C]}),d=a.public.demoMode,S=a.public.demoDataVersion,$=a.public.appVersion,{resetDemo:B}=Ln();return Re(async()=>{if(d&&S){const C=await En();C!==null&&C!==S&&l.add({title:"New demo data available",description:'The demo seed data has been updated since your last visit. Click "Refresh" to reload with the latest data.',duration:0,color:"warning",actions:[{label:"Refresh",color:"warning",onClick:()=>{B()}},{label:"Dismiss",color:"neutral",variant:"ghost"}]})}}),(C,x)=>{const k=ys,j=Fn,G=ks,Y=$s,_=ya,P=Zs,h=nl,V=pl,M=Sl,J=Fl,ne=zl;return b(),D(ne,{unit:"rem",style:{top:"var(--demo-banner-height, 0px)",height:"calc(100dvh - var(--demo-banner-height, 0px))"}},{default:I(()=>[x[2]||(x[2]=N("a",{href:"#main-content",class:"sr-only focus:not-sr-only focus:fixed focus:top-2 focus:left-2 focus:z-[100] focus:rounded-md focus:bg-primary focus:px-3 focus:py-2 focus:text-sm focus:font-medium focus:text-inverted focus:shadow-lg focus:outline-2 focus:outline-primary"}," Skip to main content ",-1)),A(P,{id:"default",open:n(i),"onUpdate:open":x[0]||(x[0]=W=>we(i)?i.value=W:null),collapsible:"",resizable:"",width:"20",class:"bg-elevated/25",ui:{root:"min-h-full",footer:"lg:border-t lg:border-default"}},{header:I(({collapsed:W})=>[A(Nl,{collapsed:W},null,8,["collapsed"])]),default:I(({collapsed:W})=>[A(k,{collapsed:W,class:"bg-transparent ring-default"},null,8,["collapsed"]),(b(),D(j,{key:n(c)??void 0,collapsed:W,items:n(y)[0],orientation:"vertical",tooltip:"",popover:""},null,8,["collapsed","items"])),A(j,{collapsed:W,items:n(y)[1],orientation:"vertical",tooltip:"",class:"mt-auto"},null,8,["collapsed","items"])]),footer:I(({collapsed:W})=>[N("div",Xl,[A(G,{collapsed:W},null,8,["collapsed"]),A(Y,{collapsed:W},null,8,["collapsed"]),W?E("",!0):(b(),D(_,{key:0,to:"/settings/about",class:"text-xs text-gray-400 hover:text-gray-600 dark:hover:text-gray-300 text-center",title:"View version and build info"},{default:I(()=>[oe(" v"+Q(n($)),1)]),_:1}))])]),_:1},8,["open"]),A(h,{"search-term":n(u),"onUpdate:searchTerm":x[1]||(x[1]=W=>we(u)?u.value=W:null),groups:n(w),"preserve-group-order":!!n(r)},null,8,["search-term","groups","preserve-group-order"]),x[3]||(x[3]=N("span",{id:"main-content",tabindex:"-1",class:"sr-only"},"Main content",-1)),H(C.$slots,"default"),A(V),A(M),A(J)]),_:3})}}});export{Bi as default};
@@ -1,4 +1,4 @@
1
- import{_ as ee,a as te}from"./B_mN5eMV.js";import{_ as se}from"./9N6hSApy.js";import{d as B,b as re,B as oe,ao as D,k as o,o as r,f as w,g as d,c as a,j as c,p as E,m as s,F as _,y as O,q as ie,i as t,t as l,s as ne,v as g,_ as F,r as U,w as ae,e as ce,A as pe,h as x}from"./h49q_GXF.js";import{_ as G}from"./DLNNAYfu.js";import{e as N}from"./CD3R-ggS.js";import{_ as de}from"./Dj-TetcW.js";import{_ as le}from"./CDh_Qt7h.js";import{E as ue}from"./DWwiVTZX.js";import{u as me}from"./BaDhDBCV.js";import{a as ge,u as fe}from"./Cd8r0xk5.js";import"./BhH0TNTi.js";import"./BtSJxOdh.js";import"./BjaRappk.js";import"./CWoSSKhQ.js";import"./Hot1UcKY.js";import"./DGnQ69wW.js";const ye={key:0,class:"flex items-center gap-2 text-sm text-muted"},he={key:1,class:"space-y-2"},be=["data-testid"],xe={class:"min-w-0 flex-1"},_e={class:"flex items-center gap-2"},ve={class:"text-sm font-medium"},ke={key:0,class:"text-xs text-muted truncate"},we={key:1,class:"text-xs text-warning"},je={class:"flex items-center gap-1.5 shrink-0"},Ie=B({__name:"DesktopMcpClientsCard",setup(M){const v=re(),C=U(!1),S=U(!0),j=U([]),f=U(null);async function A(){const n=D();if(n)try{j.value=await n.invoke("desktop_mcp_clients"),C.value=!0}catch{C.value=!1}finally{S.value=!1}}oe(()=>{D()?A():S.value=!1});async function y(n,p){const h=D();if(h){f.value=n.id;try{const k=await h.invoke(p?"desktop_mcp_connect":"desktop_mcp_disconnect",{clientId:n.id});j.value=j.value.map(b=>b.id===k.id?k:b),v.add({title:p?`${n.label} connected`:`${n.label} disconnected`,description:p?`Restart ${n.label} to pick up the new server.`:void 0,color:"success",icon:"i-lucide-plug"})}catch(k){v.add({title:`Could not update ${n.label}`,description:N(k),color:"error"})}finally{f.value=null}}}async function u(n){const p=D();if(p)try{await p.invoke("desktop_mcp_reveal",{clientId:n.id})}catch(h){v.add({title:"Could not open the file",description:N(h),color:"error"})}}function q(n){switch(n.status){case"connected":return{label:"Connected",color:"success"};case"stale":return{label:"Needs update",color:"warning"};case"manual":return{label:"Manual setup",color:"warning"};case"not_installed":return{label:"Not detected",color:"neutral"};default:return null}}return(n,p)=>{const h=E,k=ne,b=F,$=G;return o(C)?(r(),w($,{key:0,icon:"i-lucide-plug-zap",title:"Connect a client on this machine"},{subtitle:d(()=>[...p[0]||(p[0]=[s(" One click writes the ",-1),t("code",null,"piwi",-1),s(" entry into the client's own config file (a backup is kept next to it), and entries are kept current when this app's address changes. Restart the client after connecting. ",-1)])]),default:d(()=>[o(S)?(r(),a("div",ye,[c(h,{name:"i-lucide-loader-2",class:"size-4 animate-spin"}),p[1]||(p[1]=s(" Detecting clients… ",-1))])):(r(),a("div",he,[(r(!0),a(_,null,O(o(j),i=>(r(),a("div",{key:i.id,"data-testid":`mcp-client-${i.id}`,class:ie(["flex items-center gap-3 rounded-md border border-default p-2.5",i.status==="not_installed"?"opacity-60":""])},[c(h,{name:"i-lucide-bot",class:"size-4 text-gray-400 shrink-0"}),t("div",xe,[t("div",_e,[t("p",ve,l(i.label),1),q(i)?(r(),w(k,{key:0,color:q(i).color,variant:"subtle",size:"sm"},{default:d(()=>[s(l(q(i).label),1)]),_:2},1032,["color"])):g("",!0)]),i.config_path?(r(),a("p",ke,l(i.config_path),1)):g("",!0),i.detail?(r(),a("p",we,l(i.detail),1)):g("",!0)]),t("div",je,[i.status==="not_connected"?(r(),w(b,{key:0,size:"xs",icon:"i-lucide-plug",loading:o(f)===i.id,onClick:P=>y(i,!0)},{default:d(()=>[...p[2]||(p[2]=[s(" Connect ",-1)])]),_:1},8,["loading","onClick"])):i.status==="stale"?(r(),w(b,{key:1,size:"xs",color:"warning",icon:"i-lucide-refresh-cw",loading:o(f)===i.id,onClick:P=>y(i,!0)},{default:d(()=>[...p[3]||(p[3]=[s(" Update ",-1)])]),_:1},8,["loading","onClick"])):g("",!0),i.status==="connected"||i.status==="stale"?(r(),w(b,{key:2,size:"xs",color:"neutral",variant:"ghost",icon:"i-lucide-unplug",loading:o(f)===i.id,onClick:P=>y(i,!1)},{default:d(()=>[...p[4]||(p[4]=[s(" Disconnect ",-1)])]),_:1},8,["loading","onClick"])):g("",!0),i.status!=="not_installed"&&i.config_path?(r(),w(b,{key:3,size:"xs",color:"neutral",variant:"ghost",icon:"i-lucide-folder-open","aria-label":"Reveal config file",title:"Reveal config file",onClick:P=>u(i)},null,8,["onClick"])):g("",!0)])],10,be))),128)),p[5]||(p[5]=t("p",{class:"text-xs text-muted"}," A client that is not listed — or marked manual — can always be connected with the snippets below. ",-1))]))]),_:1})):g("",!0)}}}),Ce=Object.assign(Ie,{__name:"DesktopMcpClientsCard"}),Se=[{name:"list_projects",description:"List all projects with stats: total runs, test cases, latest run status and branch. Use this first to discover available projects and their IDs.",inputSchema:{type:"object",properties:{}}},{name:"get_project",description:"Get project details and its recent test runs with pass/fail counts. Results are paginated — use pageSize and cursor for the runs list.",inputSchema:{type:"object",properties:{id:{type:"number",description:"Project ID from list_projects"},pageSize:{type:"number",description:"Runs per page (default 10, max 50)"},cursor:{type:"string",description:"Opaque cursor from a previous response to get the next page of runs"}},required:["id"]}},{name:"list_runs",description:"List test runs for a project with filters.",inputSchema:{type:"object",properties:{projectId:{type:"number",description:"Project ID"},status:{type:"string",enum:["passed","failed","running","initialising","aborted"],description:"Filter by status"},branch:{type:"string",description:"Filter by branch name (exact match against SCM metadata)"},pageSize:{type:"number",description:"Results per page (default 10, max 50)"},cursor:{type:"string",description:"Opaque cursor from a previous response to get the next page"}},required:["projectId"]}},{name:"get_run",description:"Get a test run summary plus its test cases (paginated), with status, truncated error text, and failure cluster IDs. Filter by status and page with pageSize/cursor.",inputSchema:{type:"object",properties:{id:{type:"number",description:"Test run ID"},status_filter:{type:"string",enum:["failed","flaky","all"],description:'Which test cases to include (default: "failed" — only failed+timedOut; "flaky" — only flaky; "all" — every case)'},pageSize:{type:"number",description:"Cases per page (default 10, max 50)"},cursor:{type:"string",description:"Opaque cursor from a previous response for the next page of cases"}},required:["id"]}},{name:"list_failed_cases",description:"List failed and timed-out test cases across recent runs for a project.",inputSchema:{type:"object",properties:{projectId:{type:"number",description:"Project ID"},pageSize:{type:"number",description:"Results per page (default 10, max 50)"},cursor:{type:"string",description:"Opaque cursor from a previous response to get the next page"},runId:{type:"number",description:"Optional: restrict to a specific run"}},required:["projectId"]}},{name:"list_flaky_tests",description:"List flaky tests for a project with flakiness scores.",inputSchema:{type:"object",properties:{projectId:{type:"number",description:"Project ID"},runs:{type:"number",description:"Number of recent runs to analyze (default 50, max 200)"},pageSize:{type:"number",description:"Results per page (default 10, max 50)"},cursor:{type:"string",description:"Opaque cursor from a previous response. Cursor is the flakyScore value (descending)."}},required:["projectId"]}},{name:"get_test_case",description:"Get test case details including aggregated pass/fail stats, flakiness metrics, and recent executions (paginated). Use testCaseId (stable identity), not the per-run caseId.",inputSchema:{type:"object",properties:{id:{type:"number",description:"Test case ID (testCaseId from list_failed_cases or list_flaky_tests)"},pageSize:{type:"number",description:"Executions per page (default 10, max 50)"},cursor:{type:"string",description:"Opaque cursor from a previous response to get the next page of executions"}},required:["id"]}},{name:"list_clusters",description:"List failure clusters for a project. Each cluster groups similar failures by error fingerprint.",inputSchema:{type:"object",properties:{projectId:{type:"number",description:"Project ID"},status:{type:"string",enum:["open","resolved","ignored"],description:"Filter by triage status (default: all statuses)"},pageSize:{type:"number",description:"Results per page (default 10, max 50)"},cursor:{type:"string",description:"Opaque cursor from a previous response to get the next page"}},required:["projectId"]}},{name:"get_cluster",description:"Get full details for a failure cluster including all affected test cases, a compact diagnosis summary, and locator healing suggestions for up to 5 affected cases. Each healing entry includes the failing locator, the recommended fix, and the number of alternatives available. Use get_cluster_diagnosis for the full diagnosis text, or get_cluster_context for the raw AI evidence.",inputSchema:{type:"object",properties:{id:{type:"number",description:"Cluster ID from list_clusters"}},required:["id"]}},{name:"get_fix_plan",description:"Everything needed to fix one failure cluster, in a single answer: the diagnosis and its validated patch, ranked locator replacements with the exact file and line to edit, the failing tests, the owning team, and the command that verifies the work. `verify.expectation` states what the dashboard records once those tests pass, so you can confirm the fix landed rather than guessing. Prefer this over assembling get_cluster + get_cluster_diagnosis + get_locator_healing yourself.",inputSchema:{type:"object",properties:{clusterId:{type:"number",description:"Cluster ID from list_clusters or list_open_clusters"}},required:["clusterId"]}},{name:"get_cluster_diagnosis",description:"Get the stored AI diagnosis for a failure cluster. Returns category, confidence, root cause, evidence, and suggested fix. Returns null if no diagnosis has been run yet.",inputSchema:{type:"object",properties:{id:{type:"number",description:"Cluster ID"}},required:["id"]}},{name:"get_test_case_context",description:"Get the AI evidence context for a specific test-run-case (execution scope). Use this when debugging a single test failure — it provides the execution-scoped evidence including steps, console, network, and SCM diff.",inputSchema:{type:"object",properties:{id:{type:"number",description:"Test run case ID"}},required:["id"]}},{name:"get_case_screenshots",description:"Get screenshots for a test-run-case. By default returns metadata only (name, type, size). Set content=true to include base64-encoded image data (max 3, capped at ~100 KB each). Call metadata-only first to discover what exists, then request content for the ones you need.",inputSchema:{type:"object",properties:{testRunsCaseId:{type:"number",description:"Test run case ID"},content:{type:"boolean",description:"Include base64 image data (default false — metadata only)"}},required:["testRunsCaseId"]}},{name:"get_cluster_context",description:"Get the full AI evidence context for a failure cluster — the same data sent to the diagnosis AI. Includes error samples, stack traces, test steps, console logs, network failures, ARIA snapshots, SCM diff (changed files since last green run), and a per-section breakdown with char counts and truncation flags. This is the richest available evidence for debugging a failure.",inputSchema:{type:"object",properties:{id:{type:"number",description:"Cluster ID"},baseCommit:{type:"string",description:"Optional: override the baseline commit SHA for SCM diff comparison"},selectedCommitShas:{type:"array",items:{type:"string"},description:"Optional: specific commit SHAs to include in the diff context (max 10)"}},required:["id"]}},{name:"search_test_cases",description:"Search test cases by title or file path within a project. Accepts a free-text query and returns matching test cases with basic stats. Use this to find a test case when you don't know its ID.",inputSchema:{type:"object",properties:{projectId:{type:"number",description:"Project ID"},q:{type:"string",description:"Search query — matched against title and file path (case-insensitive)"},pageSize:{type:"number",description:"Results per page (default 10, max 50)"},cursor:{type:"string",description:"Opaque cursor from a previous response to get the next page"}},required:["projectId","q"]}},{name:"get_test_run_case",description:"Get a single test-run-case execution record with full (untruncated) error text plus steps, console logs, web vitals, and ARIA snapshot. Use include to fetch only the blobs you need. The ID is the executionId from get_run.cases or testRunsCaseId from get_cluster.affectedTestCases.",inputSchema:{type:"object",properties:{id:{type:"number",description:"Test run case ID (executionId from get_run.cases or testRunsCaseId from get_cluster.affectedTestCases)"},include:{type:"array",items:{type:"string",enum:["steps","console","webVitals","aria","source"]},description:"Optional: which heavy blobs to include (default: all). The error, status, and summary are always returned."}},required:["id"]}},{name:"list_recent_activity",description:"List the most recent test runs across all projects. No projectId required — returns a cross-project view of recent CI activity. Paginated by startTime descending.",inputSchema:{type:"object",properties:{pageSize:{type:"number",description:"Results per page (default 10, max 50)"},cursor:{type:"string",description:"Opaque cursor from a previous response to get the next page"}}}},{name:"get_repo_commits",description:"List recent commits for a project's repository. Requires SCM token configuration (per-project or global). Returns commit details (SHA, message, author, date).",inputSchema:{type:"object",properties:{projectId:{type:"number",description:"Project ID"},branch:{type:"string",description:"Branch name (default: repository default branch)"},limit:{type:"number",description:"Max commits (default 20, max 100)"}},required:["projectId"]}},{name:"get_repo_diff",description:"Get the diff (changed files with patches) for a single commit in a project's repository. Requires SCM token configuration (per-project or global). Useful for inspecting what code changed in a specific commit suspected of causing a failure.",inputSchema:{type:"object",properties:{projectId:{type:"number",description:"Project ID"},sha:{type:"string",description:"Full commit SHA"}},required:["projectId","sha"]}},{name:"get_run_insights",description:'Compare a run to its last green baseline: pass-rate delta, new regressions, recurrences, recovered tests, new flaky tests, biggest perf improvements/regressions, worker imbalance, and newly opened clusters. Use this to answer "what changed?" and "did my fix work?".',inputSchema:{type:"object",properties:{id:{type:"number",description:"Test run ID"}},required:["id"]}},{name:"get_spec_health",description:"Per-spec-file health for a project: pass rate, flaky rate, failure count, test count, and average duration grouped by spec-file prefix over the last N days. Use to find which areas of the suite are unhealthy.",inputSchema:{type:"object",properties:{projectId:{type:"number",description:"Project ID"},days:{type:"number",description:"Lookback window in days (default 30, max 90)"}},required:["projectId"]}},{name:"get_slow_tests",description:"Slowest test cases in a project by average duration, with max/min and trend direction across recent runs. Use to target performance work.",inputSchema:{type:"object",properties:{projectId:{type:"number",description:"Project ID"},runs:{type:"number",description:"Recent runs to analyze (default 50, max 100)"}},required:["projectId"]}},{name:"get_performance_trend",description:'Time series of run duration, average test duration, and p90 test duration for a project. Use to answer "is the suite getting slower?".',inputSchema:{type:"object",properties:{projectId:{type:"number",description:"Project ID"},limit:{type:"number",description:"Number of recent runs (default 30, max 100)"}},required:["projectId"]}},{name:"get_test_stability_trend",description:'Time-series stability for a single test case: flaky rate, pass rate, and average duration bucketed over its recent execution history. Use to answer "is this test getting flakier?".',inputSchema:{type:"object",properties:{id:{type:"number",description:"Test case ID (stable testCaseId)"},buckets:{type:"number",description:"Number of time buckets (default 20, 5–50)"}},required:["id"]}},{name:"get_network_requests",description:"A run's network requests aggregated by method + normalized route, sorted by average duration, with status codes and captured backend server logs. Use to pin a UI failure on a slow or failing endpoint.",inputSchema:{type:"object",properties:{id:{type:"number",description:"Test run ID"}},required:["id"]}},{name:"get_failure_groups",description:"One run's failures grouped by failure cluster, with per-group affected cases and worker correlation. Run-scoped counterpart to list_clusters.",inputSchema:{type:"object",properties:{id:{type:"number",description:"Test run ID"}},required:["id"]}},{name:"get_locator_healing",description:"Ranked alternative locators for a failing test-run-case: the failing locator, the recommended durable fix, and the full alternative lists (from prior success, element match, and ARIA snapshot). Use when fixing a broken selector.",inputSchema:{type:"object",properties:{testRunsCaseId:{type:"number",description:"Test run case ID (executionId)"}},required:["testRunsCaseId"]}},{name:"search",description:"Global search across all in-scope projects, runs (by label or numeric id), and test cases (by title). Use to find a run by its label or locate an entity across projects.",inputSchema:{type:"object",properties:{q:{type:"string",description:"Search query (min 2 chars)"}},required:["q"]}},{name:"list_case_traces",description:"List Playwright trace files for a test-run-case, with a download path for each. Fetch the bytes via GET /api/files/<path>.",inputSchema:{type:"object",properties:{testRunsCaseId:{type:"number",description:"Test run case ID (executionId)"}},required:["testRunsCaseId"]}},{name:"list_links",description:"List external entity links (Jira, GitHub PR/issue, etc.) attached to a run, test-run-case, or test case, with provider and unfurled status.",inputSchema:{type:"object",properties:{entityType:{type:"string",enum:["test_run","test_runs_case","test_case"],description:"Which entity the links are attached to"},id:{type:"number",description:"The entity ID matching entityType"}},required:["entityType","id"]}},{name:"list_tags",description:"List the project tag catalog (id, text, color).",inputSchema:{type:"object",properties:{}}},{name:"get_project_test_catalog",description:"The full test-case catalog for a project with aggregated pass/fail/flaky counts, average duration, and last status per test. Offset-paginated bulk companion to get_test_case.",inputSchema:{type:"object",properties:{projectId:{type:"number",description:"Project ID"},pageSize:{type:"number",description:"Results per page (default 10, max 50)"},offset:{type:"number",description:"Row offset for paging (default 0)"},query:{type:"string",description:"Optional case-insensitive substring filter on title or file path"},tags:{type:"string",description:"Comma-separated tags; a test must carry every one of them. A leading @ is optional."},owner:{type:"string",description:"Exact owner declared via the piwi:owner annotation"},priority:{type:"string",enum:["critical","high","medium","low"],description:"Priority declared via the piwi:priority annotation"}},required:["projectId"]}},{name:"list_open_clusters",description:"Open failure clusters across all in-scope projects, ranked by occurrences — a cross-project triage queue. Filter by status; paginate with pageSize/cursor.",inputSchema:{type:"object",properties:{status:{type:"string",enum:["open","resolved","ignored"],description:"Triage status (default: open)"},pageSize:{type:"number",description:"Results per page (default 10, max 50)"},cursor:{type:"string",description:"Opaque cursor from a previous response to get the next page"}}}},{name:"get_instance_stats",description:"Instance-wide counts (projects, runs, test cases, executions, files) and total storage size. Admin only.",inputSchema:{type:"object",properties:{}}},{name:"explain_failure",description:"One-call evidence bundle for a single failing execution: error, steps, console, ARIA snapshot, the recommended locator fix, a screenshot count, and the AI diagnosis context. Prefer this over chaining get_test_run_case + get_locator_healing + get_test_case_context.",inputSchema:{type:"object",properties:{testRunsCaseId:{type:"number",description:"Test run case ID (executionId)"}},required:["testRunsCaseId"]}},{name:"set_cluster_status",description:"Triage a failure cluster: set its status to open, resolved, or ignored with an optional note. Requires reporter or admin access. Use after fixing the underlying issue.",inputSchema:{type:"object",properties:{id:{type:"number",description:"Cluster ID"},status:{type:"string",enum:["open","resolved","ignored"],description:"New triage status"},triageNote:{type:"string",description:"Optional note explaining the status change"}},required:["id","status"]}},{name:"set_cluster_base_commit",description:'Pin the baseline commit SHA a cluster uses for its SCM-diff diagnosis context, so "what changed since green" is accurate. Requires reporter or admin access.',inputSchema:{type:"object",properties:{id:{type:"number",description:"Cluster ID"},commit:{type:"string",description:"Baseline commit SHA (empty to clear)"}},required:["id","commit"]}},{name:"submit_diagnosis_feedback",description:"Record thumbs up/down feedback on a stored diagnosis, with an optional note. Requires reporter or admin access.",inputSchema:{type:"object",properties:{id:{type:"number",description:"Diagnosis ID"},feedback:{type:"string",enum:["up","down"],description:"Rating (omit to clear)"},feedbackNote:{type:"string",description:"Optional note"}},required:["id"]}},{name:"run_cluster_diagnosis",description:"Trigger an AI diagnosis for a failure cluster and return the result (category, confidence, root cause, suggested fix). Returns the existing completed diagnosis unless force is set. Requires reporter or admin access and a configured AI provider.",inputSchema:{type:"object",properties:{id:{type:"number",description:"Cluster ID"},force:{type:"boolean",description:"Re-run even if a completed diagnosis exists (default false)"},baseCommit:{type:"string",description:"Optional baseline commit SHA for SCM-diff context"}},required:["id"]}},{name:"create_test_function",description:`Register a page-object method or helper in a project's test-function catalog, so the Piwi Picker browser extension (and its recorder) can match a live page or a recorded session against it and substitute a call to your own code instead of raw locator lines. This tool does not call an AI itself — you (the calling agent) read the function's real source in your own context and fill in these fields directly; the tool only validates the shape and persists it. Follow these extraction rules when deciding the field values:
1
+ import{_ as ee,a as te}from"./opyDpgSw.js";import{_ as se}from"./BBhrClA9.js";import{d as B,b as re,B as oe,ak as D,k as o,o as r,f as w,g as d,c as a,j as c,p as E,m as s,F as _,y as O,q as ie,i as t,t as l,s as ne,v as g,_ as F,r as U,w as ae,e as ce,A as pe,h as x}from"./C5TrTuWv.js";import{_ as G}from"./DMAiMrNr.js";import{e as N}from"./DMtrFQqi.js";import{_ as de}from"./B1LUinhp.js";import{_ as le}from"./DhYznn-U.js";import{E as ue}from"./DWwiVTZX.js";import{u as me}from"./fXUwH_3d.js";import{a as ge,u as fe}from"./T5UuMUxA.js";import"./BCGljaM0.js";import"./B69RP95P.js";import"./BjaRappk.js";import"./C8Paf_V1.js";import"./DEvYVl9M.js";import"./DGnQ69wW.js";const ye={key:0,class:"flex items-center gap-2 text-sm text-muted"},he={key:1,class:"space-y-2"},be=["data-testid"],xe={class:"min-w-0 flex-1"},_e={class:"flex items-center gap-2"},ve={class:"text-sm font-medium"},ke={key:0,class:"text-xs text-muted truncate"},we={key:1,class:"text-xs text-warning"},je={class:"flex items-center gap-1.5 shrink-0"},Ie=B({__name:"DesktopMcpClientsCard",setup(M){const v=re(),C=U(!1),S=U(!0),j=U([]),f=U(null);async function A(){const n=D();if(n)try{j.value=await n.invoke("desktop_mcp_clients"),C.value=!0}catch{C.value=!1}finally{S.value=!1}}oe(()=>{D()?A():S.value=!1});async function y(n,p){const h=D();if(h){f.value=n.id;try{const k=await h.invoke(p?"desktop_mcp_connect":"desktop_mcp_disconnect",{clientId:n.id});j.value=j.value.map(b=>b.id===k.id?k:b),v.add({title:p?`${n.label} connected`:`${n.label} disconnected`,description:p?`Restart ${n.label} to pick up the new server.`:void 0,color:"success",icon:"i-lucide-plug"})}catch(k){v.add({title:`Could not update ${n.label}`,description:N(k),color:"error"})}finally{f.value=null}}}async function u(n){const p=D();if(p)try{await p.invoke("desktop_mcp_reveal",{clientId:n.id})}catch(h){v.add({title:"Could not open the file",description:N(h),color:"error"})}}function q(n){switch(n.status){case"connected":return{label:"Connected",color:"success"};case"stale":return{label:"Needs update",color:"warning"};case"manual":return{label:"Manual setup",color:"warning"};case"not_installed":return{label:"Not detected",color:"neutral"};default:return null}}return(n,p)=>{const h=E,k=ne,b=F,$=G;return o(C)?(r(),w($,{key:0,icon:"i-lucide-plug-zap",title:"Connect a client on this machine"},{subtitle:d(()=>[...p[0]||(p[0]=[s(" One click writes the ",-1),t("code",null,"piwi",-1),s(" entry into the client's own config file (a backup is kept next to it), and entries are kept current when this app's address changes. Restart the client after connecting. ",-1)])]),default:d(()=>[o(S)?(r(),a("div",ye,[c(h,{name:"i-lucide-loader-2",class:"size-4 animate-spin"}),p[1]||(p[1]=s(" Detecting clients… ",-1))])):(r(),a("div",he,[(r(!0),a(_,null,O(o(j),i=>(r(),a("div",{key:i.id,"data-testid":`mcp-client-${i.id}`,class:ie(["flex items-center gap-3 rounded-md border border-default p-2.5",i.status==="not_installed"?"opacity-60":""])},[c(h,{name:"i-lucide-bot",class:"size-4 text-gray-400 shrink-0"}),t("div",xe,[t("div",_e,[t("p",ve,l(i.label),1),q(i)?(r(),w(k,{key:0,color:q(i).color,variant:"subtle",size:"sm"},{default:d(()=>[s(l(q(i).label),1)]),_:2},1032,["color"])):g("",!0)]),i.config_path?(r(),a("p",ke,l(i.config_path),1)):g("",!0),i.detail?(r(),a("p",we,l(i.detail),1)):g("",!0)]),t("div",je,[i.status==="not_connected"?(r(),w(b,{key:0,size:"xs",icon:"i-lucide-plug",loading:o(f)===i.id,onClick:P=>y(i,!0)},{default:d(()=>[...p[2]||(p[2]=[s(" Connect ",-1)])]),_:1},8,["loading","onClick"])):i.status==="stale"?(r(),w(b,{key:1,size:"xs",color:"warning",icon:"i-lucide-refresh-cw",loading:o(f)===i.id,onClick:P=>y(i,!0)},{default:d(()=>[...p[3]||(p[3]=[s(" Update ",-1)])]),_:1},8,["loading","onClick"])):g("",!0),i.status==="connected"||i.status==="stale"?(r(),w(b,{key:2,size:"xs",color:"neutral",variant:"ghost",icon:"i-lucide-unplug",loading:o(f)===i.id,onClick:P=>y(i,!1)},{default:d(()=>[...p[4]||(p[4]=[s(" Disconnect ",-1)])]),_:1},8,["loading","onClick"])):g("",!0),i.status!=="not_installed"&&i.config_path?(r(),w(b,{key:3,size:"xs",color:"neutral",variant:"ghost",icon:"i-lucide-folder-open","aria-label":"Reveal config file",title:"Reveal config file",onClick:P=>u(i)},null,8,["onClick"])):g("",!0)])],10,be))),128)),p[5]||(p[5]=t("p",{class:"text-xs text-muted"}," A client that is not listed — or marked manual — can always be connected with the snippets below. ",-1))]))]),_:1})):g("",!0)}}}),Ce=Object.assign(Ie,{__name:"DesktopMcpClientsCard"}),Se=[{name:"list_projects",description:"List all projects with stats: total runs, test cases, latest run status and branch. Use this first to discover available projects and their IDs.",inputSchema:{type:"object",properties:{}}},{name:"get_project",description:"Get project details and its recent test runs with pass/fail counts. Results are paginated — use pageSize and cursor for the runs list.",inputSchema:{type:"object",properties:{id:{type:"number",description:"Project ID from list_projects"},pageSize:{type:"number",description:"Runs per page (default 10, max 50)"},cursor:{type:"string",description:"Opaque cursor from a previous response to get the next page of runs"}},required:["id"]}},{name:"list_runs",description:"List test runs for a project with filters.",inputSchema:{type:"object",properties:{projectId:{type:"number",description:"Project ID"},status:{type:"string",enum:["passed","failed","running","initialising","aborted"],description:"Filter by status"},branch:{type:"string",description:"Filter by branch name (exact match against SCM metadata)"},pageSize:{type:"number",description:"Results per page (default 10, max 50)"},cursor:{type:"string",description:"Opaque cursor from a previous response to get the next page"}},required:["projectId"]}},{name:"get_run",description:"Get a test run summary plus its test cases (paginated), with status, truncated error text, and failure cluster IDs. Filter by status and page with pageSize/cursor.",inputSchema:{type:"object",properties:{id:{type:"number",description:"Test run ID"},status_filter:{type:"string",enum:["failed","flaky","all"],description:'Which test cases to include (default: "failed" — only failed+timedOut; "flaky" — only flaky; "all" — every case)'},pageSize:{type:"number",description:"Cases per page (default 10, max 50)"},cursor:{type:"string",description:"Opaque cursor from a previous response for the next page of cases"}},required:["id"]}},{name:"list_failed_cases",description:"List failed and timed-out test cases across recent runs for a project.",inputSchema:{type:"object",properties:{projectId:{type:"number",description:"Project ID"},pageSize:{type:"number",description:"Results per page (default 10, max 50)"},cursor:{type:"string",description:"Opaque cursor from a previous response to get the next page"},runId:{type:"number",description:"Optional: restrict to a specific run"}},required:["projectId"]}},{name:"list_flaky_tests",description:"List flaky tests for a project with flakiness scores.",inputSchema:{type:"object",properties:{projectId:{type:"number",description:"Project ID"},runs:{type:"number",description:"Number of recent runs to analyze (default 50, max 200)"},pageSize:{type:"number",description:"Results per page (default 10, max 50)"},cursor:{type:"string",description:"Opaque cursor from a previous response. Cursor is the flakyScore value (descending)."}},required:["projectId"]}},{name:"get_test_case",description:"Get test case details including aggregated pass/fail stats, flakiness metrics, and recent executions (paginated). Use testCaseId (stable identity), not the per-run caseId.",inputSchema:{type:"object",properties:{id:{type:"number",description:"Test case ID (testCaseId from list_failed_cases or list_flaky_tests)"},pageSize:{type:"number",description:"Executions per page (default 10, max 50)"},cursor:{type:"string",description:"Opaque cursor from a previous response to get the next page of executions"}},required:["id"]}},{name:"list_clusters",description:"List failure clusters for a project. Each cluster groups similar failures by error fingerprint.",inputSchema:{type:"object",properties:{projectId:{type:"number",description:"Project ID"},status:{type:"string",enum:["open","resolved","ignored"],description:"Filter by triage status (default: all statuses)"},pageSize:{type:"number",description:"Results per page (default 10, max 50)"},cursor:{type:"string",description:"Opaque cursor from a previous response to get the next page"}},required:["projectId"]}},{name:"get_cluster",description:"Get full details for a failure cluster including all affected test cases, a compact diagnosis summary, and locator healing suggestions for up to 5 affected cases. Each healing entry includes the failing locator, the recommended fix, and the number of alternatives available. Use get_cluster_diagnosis for the full diagnosis text, or get_cluster_context for the raw AI evidence.",inputSchema:{type:"object",properties:{id:{type:"number",description:"Cluster ID from list_clusters"}},required:["id"]}},{name:"get_fix_plan",description:"Everything needed to fix one failure cluster, in a single answer: the diagnosis and its validated patch, ranked locator replacements with the exact file and line to edit, the failing tests, the owning team, and the command that verifies the work. `verify.expectation` states what the dashboard records once those tests pass, so you can confirm the fix landed rather than guessing. Prefer this over assembling get_cluster + get_cluster_diagnosis + get_locator_healing yourself.",inputSchema:{type:"object",properties:{clusterId:{type:"number",description:"Cluster ID from list_clusters or list_open_clusters"}},required:["clusterId"]}},{name:"get_cluster_diagnosis",description:"Get the stored AI diagnosis for a failure cluster. Returns category, confidence, root cause, evidence, and suggested fix. Returns null if no diagnosis has been run yet.",inputSchema:{type:"object",properties:{id:{type:"number",description:"Cluster ID"}},required:["id"]}},{name:"get_test_case_context",description:"Get the AI evidence context for a specific test-run-case (execution scope). Use this when debugging a single test failure — it provides the execution-scoped evidence including steps, console, network, and SCM diff.",inputSchema:{type:"object",properties:{id:{type:"number",description:"Test run case ID"}},required:["id"]}},{name:"get_case_screenshots",description:"Get screenshots for a test-run-case. By default returns metadata only (name, type, size). Set content=true to include base64-encoded image data (max 3, capped at ~100 KB each). Call metadata-only first to discover what exists, then request content for the ones you need.",inputSchema:{type:"object",properties:{testRunsCaseId:{type:"number",description:"Test run case ID"},content:{type:"boolean",description:"Include base64 image data (default false — metadata only)"}},required:["testRunsCaseId"]}},{name:"get_cluster_context",description:"Get the full AI evidence context for a failure cluster — the same data sent to the diagnosis AI. Includes error samples, stack traces, test steps, console logs, network failures, ARIA snapshots, SCM diff (changed files since last green run), and a per-section breakdown with char counts and truncation flags. This is the richest available evidence for debugging a failure.",inputSchema:{type:"object",properties:{id:{type:"number",description:"Cluster ID"},baseCommit:{type:"string",description:"Optional: override the baseline commit SHA for SCM diff comparison"},selectedCommitShas:{type:"array",items:{type:"string"},description:"Optional: specific commit SHAs to include in the diff context (max 10)"}},required:["id"]}},{name:"search_test_cases",description:"Search test cases by title or file path within a project. Accepts a free-text query and returns matching test cases with basic stats. Use this to find a test case when you don't know its ID.",inputSchema:{type:"object",properties:{projectId:{type:"number",description:"Project ID"},q:{type:"string",description:"Search query — matched against title and file path (case-insensitive)"},pageSize:{type:"number",description:"Results per page (default 10, max 50)"},cursor:{type:"string",description:"Opaque cursor from a previous response to get the next page"}},required:["projectId","q"]}},{name:"get_test_run_case",description:"Get a single test-run-case execution record with full (untruncated) error text plus steps, console logs, web vitals, and ARIA snapshot. Use include to fetch only the blobs you need. The ID is the executionId from get_run.cases or testRunsCaseId from get_cluster.affectedTestCases.",inputSchema:{type:"object",properties:{id:{type:"number",description:"Test run case ID (executionId from get_run.cases or testRunsCaseId from get_cluster.affectedTestCases)"},include:{type:"array",items:{type:"string",enum:["steps","console","webVitals","aria","source"]},description:"Optional: which heavy blobs to include (default: all). The error, status, and summary are always returned."}},required:["id"]}},{name:"list_recent_activity",description:"List the most recent test runs across all projects. No projectId required — returns a cross-project view of recent CI activity. Paginated by startTime descending.",inputSchema:{type:"object",properties:{pageSize:{type:"number",description:"Results per page (default 10, max 50)"},cursor:{type:"string",description:"Opaque cursor from a previous response to get the next page"}}}},{name:"get_repo_commits",description:"List recent commits for a project's repository. Requires SCM token configuration (per-project or global). Returns commit details (SHA, message, author, date).",inputSchema:{type:"object",properties:{projectId:{type:"number",description:"Project ID"},branch:{type:"string",description:"Branch name (default: repository default branch)"},limit:{type:"number",description:"Max commits (default 20, max 100)"}},required:["projectId"]}},{name:"get_repo_diff",description:"Get the diff (changed files with patches) for a single commit in a project's repository. Requires SCM token configuration (per-project or global). Useful for inspecting what code changed in a specific commit suspected of causing a failure.",inputSchema:{type:"object",properties:{projectId:{type:"number",description:"Project ID"},sha:{type:"string",description:"Full commit SHA"}},required:["projectId","sha"]}},{name:"get_run_insights",description:'Compare a run to its last green baseline: pass-rate delta, new regressions, recurrences, recovered tests, new flaky tests, biggest perf improvements/regressions, worker imbalance, and newly opened clusters. Use this to answer "what changed?" and "did my fix work?".',inputSchema:{type:"object",properties:{id:{type:"number",description:"Test run ID"}},required:["id"]}},{name:"get_spec_health",description:"Per-spec-file health for a project: pass rate, flaky rate, failure count, test count, and average duration grouped by spec-file prefix over the last N days. Use to find which areas of the suite are unhealthy.",inputSchema:{type:"object",properties:{projectId:{type:"number",description:"Project ID"},days:{type:"number",description:"Lookback window in days (default 30, max 90)"}},required:["projectId"]}},{name:"get_slow_tests",description:"Slowest test cases in a project by average duration, with max/min and trend direction across recent runs. Use to target performance work.",inputSchema:{type:"object",properties:{projectId:{type:"number",description:"Project ID"},runs:{type:"number",description:"Recent runs to analyze (default 50, max 100)"}},required:["projectId"]}},{name:"get_performance_trend",description:'Time series of run duration, average test duration, and p90 test duration for a project. Use to answer "is the suite getting slower?".',inputSchema:{type:"object",properties:{projectId:{type:"number",description:"Project ID"},limit:{type:"number",description:"Number of recent runs (default 30, max 100)"}},required:["projectId"]}},{name:"get_test_stability_trend",description:'Time-series stability for a single test case: flaky rate, pass rate, and average duration bucketed over its recent execution history. Use to answer "is this test getting flakier?".',inputSchema:{type:"object",properties:{id:{type:"number",description:"Test case ID (stable testCaseId)"},buckets:{type:"number",description:"Number of time buckets (default 20, 5–50)"}},required:["id"]}},{name:"get_network_requests",description:"A run's network requests aggregated by method + normalized route, sorted by average duration, with status codes and captured backend server logs. Use to pin a UI failure on a slow or failing endpoint.",inputSchema:{type:"object",properties:{id:{type:"number",description:"Test run ID"}},required:["id"]}},{name:"get_failure_groups",description:"One run's failures grouped by failure cluster, with per-group affected cases and worker correlation. Run-scoped counterpart to list_clusters.",inputSchema:{type:"object",properties:{id:{type:"number",description:"Test run ID"}},required:["id"]}},{name:"get_locator_healing",description:"Ranked alternative locators for a failing test-run-case: the failing locator, the recommended durable fix, and the full alternative lists (from prior success, element match, and ARIA snapshot). Use when fixing a broken selector.",inputSchema:{type:"object",properties:{testRunsCaseId:{type:"number",description:"Test run case ID (executionId)"}},required:["testRunsCaseId"]}},{name:"search",description:"Global search across all in-scope projects, runs (by label or numeric id), and test cases (by title). Use to find a run by its label or locate an entity across projects.",inputSchema:{type:"object",properties:{q:{type:"string",description:"Search query (min 2 chars)"}},required:["q"]}},{name:"list_case_traces",description:"List Playwright trace files for a test-run-case, with a download path for each. Fetch the bytes via GET /api/files/<path>.",inputSchema:{type:"object",properties:{testRunsCaseId:{type:"number",description:"Test run case ID (executionId)"}},required:["testRunsCaseId"]}},{name:"list_links",description:"List external entity links (Jira, GitHub PR/issue, etc.) attached to a run, test-run-case, or test case, with provider and unfurled status.",inputSchema:{type:"object",properties:{entityType:{type:"string",enum:["test_run","test_runs_case","test_case"],description:"Which entity the links are attached to"},id:{type:"number",description:"The entity ID matching entityType"}},required:["entityType","id"]}},{name:"list_tags",description:"List the project tag catalog (id, text, color).",inputSchema:{type:"object",properties:{}}},{name:"get_project_test_catalog",description:"The full test-case catalog for a project with aggregated pass/fail/flaky counts, average duration, and last status per test. Offset-paginated bulk companion to get_test_case.",inputSchema:{type:"object",properties:{projectId:{type:"number",description:"Project ID"},pageSize:{type:"number",description:"Results per page (default 10, max 50)"},offset:{type:"number",description:"Row offset for paging (default 0)"},query:{type:"string",description:"Optional case-insensitive substring filter on title or file path"},tags:{type:"string",description:"Comma-separated tags; a test must carry every one of them. A leading @ is optional."},owner:{type:"string",description:"Exact owner declared via the piwi:owner annotation"},priority:{type:"string",enum:["critical","high","medium","low"],description:"Priority declared via the piwi:priority annotation"}},required:["projectId"]}},{name:"list_open_clusters",description:"Open failure clusters across all in-scope projects, ranked by occurrences — a cross-project triage queue. Filter by status; paginate with pageSize/cursor.",inputSchema:{type:"object",properties:{status:{type:"string",enum:["open","resolved","ignored"],description:"Triage status (default: open)"},pageSize:{type:"number",description:"Results per page (default 10, max 50)"},cursor:{type:"string",description:"Opaque cursor from a previous response to get the next page"}}}},{name:"get_instance_stats",description:"Instance-wide counts (projects, runs, test cases, executions, files) and total storage size. Admin only.",inputSchema:{type:"object",properties:{}}},{name:"explain_failure",description:"One-call evidence bundle for a single failing execution: error, steps, console, ARIA snapshot, the recommended locator fix, a screenshot count, and the AI diagnosis context. Prefer this over chaining get_test_run_case + get_locator_healing + get_test_case_context.",inputSchema:{type:"object",properties:{testRunsCaseId:{type:"number",description:"Test run case ID (executionId)"}},required:["testRunsCaseId"]}},{name:"set_cluster_status",description:"Triage a failure cluster: set its status to open, resolved, or ignored with an optional note. Requires reporter or admin access. Use after fixing the underlying issue.",inputSchema:{type:"object",properties:{id:{type:"number",description:"Cluster ID"},status:{type:"string",enum:["open","resolved","ignored"],description:"New triage status"},triageNote:{type:"string",description:"Optional note explaining the status change"}},required:["id","status"]}},{name:"set_cluster_base_commit",description:'Pin the baseline commit SHA a cluster uses for its SCM-diff diagnosis context, so "what changed since green" is accurate. Requires reporter or admin access.',inputSchema:{type:"object",properties:{id:{type:"number",description:"Cluster ID"},commit:{type:"string",description:"Baseline commit SHA (empty to clear)"}},required:["id","commit"]}},{name:"submit_diagnosis_feedback",description:"Record thumbs up/down feedback on a stored diagnosis, with an optional note. Requires reporter or admin access.",inputSchema:{type:"object",properties:{id:{type:"number",description:"Diagnosis ID"},feedback:{type:"string",enum:["up","down"],description:"Rating (omit to clear)"},feedbackNote:{type:"string",description:"Optional note"}},required:["id"]}},{name:"run_cluster_diagnosis",description:"Trigger an AI diagnosis for a failure cluster and return the result (category, confidence, root cause, suggested fix). Returns the existing completed diagnosis unless force is set. Requires reporter or admin access and a configured AI provider.",inputSchema:{type:"object",properties:{id:{type:"number",description:"Cluster ID"},force:{type:"boolean",description:"Re-run even if a completed diagnosis exists (default false)"},baseCommit:{type:"string",description:"Optional baseline commit SHA for SCM-diff context"}},required:["id"]}},{name:"create_test_function",description:`Register a page-object method or helper in a project's test-function catalog, so the Piwi Picker browser extension (and its recorder) can match a live page or a recorded session against it and substitute a call to your own code instead of raw locator lines. This tool does not call an AI itself — you (the calling agent) read the function's real source in your own context and fill in these fields directly; the tool only validates the shape and persists it. Follow these extraction rules when deciding the field values:
2
2
 
3
3
  ${ue}
4
4
 
@@ -1,4 +1,4 @@
1
- import{_ as ie}from"./3xlGO1qT.js";import{d as re,b as de,w as A,c as r,j as a,ac as ce,k as s,g as d,F as y,f as v,h as D,r as k,o as l,i,E as ue,l as me,_ as pe,m as c,p as fe,t as p,v as _,y as R,s as _e,q as ge,M as ye,A as ve}from"./h49q_GXF.js";import{_ as he}from"./Dj-TetcW.js";import{_ as ke}from"./BtSJxOdh.js";import{_ as xe}from"./DLNNAYfu.js";import{_ as be}from"./BKJetfRH.js";import{_ as Se}from"./DDN2tt0a.js";import{_ as we}from"./CRPt9SfB.js";import{_ as Te}from"./9N6hSApy.js";import{u as F}from"./Cd8r0xk5.js";import"./CD3R-ggS.js";import"./BjaRappk.js";import"./CWoSSKhQ.js";import"./D4UlSVir.js";import"./xbO0VmDX.js";const Pe={class:"space-y-6"},Ue={class:"space-y-3"},Ce={key:0,class:"flex items-center gap-2 text-sm text-success-600 dark:text-success-400"},Ie={key:1,class:"flex items-center gap-2 text-sm text-warning-600 dark:text-warning-400"},Me={key:2,class:"grid grid-cols-2 gap-2 text-sm"},$e={class:"font-mono"},Ve={class:"font-mono"},Ee={key:3,class:"text-sm text-muted space-y-1"},Ne={class:"flex items-center gap-2 w-full"},ze={key:0,class:"mb-4 p-4 rounded-lg border border-primary/30 bg-primary/5 space-y-3"},Ae={class:"grid grid-cols-2 gap-3"},De={class:"flex justify-end gap-2"},Re={key:1,class:"text-sm text-muted py-4 text-center"},Fe={class:"space-y-2"},We={class:"flex-1 min-w-0"},Le={class:"font-medium text-sm flex items-center gap-1.5"},Oe={class:"text-xs text-muted"},Be={key:3,class:"ml-1 text-primary text-xs"},je={class:"flex items-center gap-1"},He={key:0,class:"text-sm text-muted py-4 text-center"},qe={class:"space-y-2"},Ye={class:"flex-1 min-w-0 space-y-0.5"},Je={class:"font-medium text-sm"},Qe={class:"text-xs text-muted flex flex-wrap gap-x-3"},Xe={key:0},Ge={key:1},Ke={key:2,class:"text-warning-500"},Ze={class:"flex flex-wrap gap-1 mt-1"},et={class:"flex items-center gap-1"},yt=re({__name:"notifications",async setup(tt){let f,x;const u=de(),j=ve(),I=D(()=>j.public.authEnabled),H=["PIWI_SMTP_HOST","PIWI_SMTP_PORT","PIWI_SMTP_USER","PIWI_SMTP_PASS","PIWI_SMTP_FROM","PIWI_SMTP_FROM_NAME","PIWI_SMTP_SECURE"],{data:m}=([f,x]=A(()=>F("/api/settings/smtp","$v5NL0FLSog")),f=await f,x(),f),h=k(""),M=k(!1);async function q(){if(h.value){M.value=!0;try{const o=await $fetch("/api/settings/smtp/test",{method:"POST",body:{to:h.value}});o.success?u.add({title:"Test email sent",description:`Check ${h.value}`,color:"success"}):u.add({title:"Send failed",description:o.error||"Unknown error",color:"error"})}catch(o){u.add({title:"Send failed",description:String(o?.message??o),color:"error"})}finally{M.value=!1}}}const{data:Y,refresh:W}=I.value?([f,x]=A(()=>F("/api/channels","$rT8YNpmgfl")),f=await f,x(),f):{data:k(null),refresh:()=>{}},$=D(()=>Y.value?.channels??[]),b=k(!1),n=ye({name:"",type:"email",address:"",webhookUrl:"",url:"",secret:"",global:!1}),V=k(!1),E=k(null),J=[{label:"Email",value:"email"},{label:"Slack webhook",value:"slack"},{label:"Webhook",value:"webhook"}];async function Q(){V.value=!0;try{const o={};n.type==="email"?o.address=n.address:n.type==="slack"?o.webhookUrl=n.webhookUrl:n.type==="webhook"&&(o.url=n.url,n.secret&&(o.secret=n.secret)),await $fetch("/api/channels",{method:"POST",body:{name:n.name,type:n.type,config:o,global:n.global}}),b.value=!1,Object.assign(n,{name:"",type:"email",address:"",webhookUrl:"",url:"",secret:"",global:!1}),await W(),u.add({title:"Channel created",color:"success"})}catch(o){u.add({title:"Failed to create channel",description:String(o?.message??o),color:"error"})}finally{V.value=!1}}async function X(o){try{await $fetch(`/api/channels/${o}`,{method:"DELETE"}),await W(),u.add({title:"Channel deleted",color:"success"})}catch(e){u.add({title:"Failed to delete channel",description:String(e?.message??e),color:"error"})}}async function G(o){E.value=o;try{const e=await $fetch(`/api/channels/${o}/test`,{method:"POST"});e.success?u.add({title:"Test notification sent",color:"success"}):u.add({title:"Test failed",description:e.error,color:"error"})}catch(e){u.add({title:"Test failed",description:String(e?.message??e),color:"error"})}finally{E.value=null}}const{data:K,refresh:L}=I.value?([f,x]=A(()=>F("/api/subscriptions","$J_5QzL_eLh")),f=await f,x(),f):{data:k(null),refresh:()=>{}},N=D(()=>K.value?.subscriptions??[]);async function Z(o){try{await $fetch(`/api/subscriptions/${o}`,{method:"DELETE"}),await L(),u.add({title:"Subscription removed",color:"success"})}catch(e){u.add({title:"Failed to remove subscription",description:String(e?.message??e),color:"error"})}}async function ee(o){const e=o.mutedUntil&&new Date(o.mutedUntil)>new Date;try{await $fetch(`/api/subscriptions/${o.id}`,{method:"PATCH",body:{mutedUntil:e?null:new Date(Date.now()+10080*60*1e3).toISOString()}}),await L(),u.add({title:e?"Unmuted":"Muted for 7 days",color:"success"})}catch(U){u.add({title:"Failed to update subscription",description:String(U?.message??U),color:"error"})}}function P(o){return o.mutedUntil&&new Date(o.mutedUntil)>new Date}function O(o){return o==="personal_email"?"i-lucide-user-round":o==="email"?"i-lucide-mail":o==="slack"?"i-lucide-slack":"i-lucide-webhook"}function te(o){return o.replace(/\./g," › ")}return(o,e)=>{const U=ie,C=fe,se=he,oe=ke,S=ue,g=pe,z=xe,w=be,le=Se,B=_e,ne=we,ae=Te;return l(),r("div",Pe,[a(z,{icon:"i-lucide-mail",title:"SMTP email delivery",help:"settings.smtp"},ce({subtitle:d(()=>[e[9]||(e[9]=c(" Configure SMTP via environment variables. The connection cannot be changed here. ",-1))]),actions:d(()=>[s(m)?.configured?(l(),v(U,{key:0,"env-vars":H,size:"md"})):_("",!0)]),default:d(()=>[i("div",Ue,[s(m)?.configured?(l(),r("div",Ce,[a(C,{name:"i-lucide-circle-check-big",class:"size-4"}),e[10]||(e[10]=c(" Configured ",-1))])):(l(),r("div",Ie,[a(C,{name:"i-lucide-circle-alert",class:"size-4"}),e[11]||(e[11]=c(" Not configured ",-1))])),s(m)?.configured?(l(),r("div",Me,[e[12]||(e[12]=i("div",{class:"text-muted"},"Host",-1)),i("div",$e,p(s(m)?.host)+":"+p(s(m)?.port),1),e[13]||(e[13]=i("div",{class:"text-muted"},"From",-1)),i("div",null,p(s(m)?.fromName?`${s(m).fromName} <${s(m).from}>`:s(m)?.from),1),e[14]||(e[14]=i("div",{class:"text-muted"},"User",-1)),i("div",Ve,p(s(m)?.user),1),e[15]||(e[15]=i("div",{class:"text-muted"},"TLS",-1)),i("div",null,p(s(m)?.secure?"Yes (port 465)":"STARTTLS / plain"),1)])):_("",!0),s(m)?.configured?_("",!0):(l(),r("div",Ee,[e[16]||(e[16]=i("p",null,"Set these environment variables to enable email notifications:",-1)),a(se,{code:`PIWI_SMTP_HOST=smtp.example.com
1
+ import{_ as ie}from"./COuZu9FO.js";import{d as re,b as de,w as A,c as r,j as a,ac as ce,k as s,g as d,F as y,f as v,h as D,r as k,o as l,i,E as ue,l as me,_ as pe,m as c,p as fe,t as p,v as _,y as R,s as _e,q as ge,M as ye,A as ve}from"./C5TrTuWv.js";import{_ as he}from"./B1LUinhp.js";import{_ as ke}from"./B69RP95P.js";import{_ as xe}from"./DMAiMrNr.js";import{_ as be}from"./DH5H1DJh.js";import{_ as Se}from"./Ce5_Tq63.js";import{_ as we}from"./DuOH5jcQ.js";import{_ as Te}from"./BBhrClA9.js";import{u as F}from"./T5UuMUxA.js";import"./DMtrFQqi.js";import"./BjaRappk.js";import"./C8Paf_V1.js";import"./D_y2VS8k.js";import"./DaNC-xl1.js";const Pe={class:"space-y-6"},Ue={class:"space-y-3"},Ce={key:0,class:"flex items-center gap-2 text-sm text-success-600 dark:text-success-400"},Ie={key:1,class:"flex items-center gap-2 text-sm text-warning-600 dark:text-warning-400"},Me={key:2,class:"grid grid-cols-2 gap-2 text-sm"},$e={class:"font-mono"},Ve={class:"font-mono"},Ee={key:3,class:"text-sm text-muted space-y-1"},Ne={class:"flex items-center gap-2 w-full"},ze={key:0,class:"mb-4 p-4 rounded-lg border border-primary/30 bg-primary/5 space-y-3"},Ae={class:"grid grid-cols-2 gap-3"},De={class:"flex justify-end gap-2"},Re={key:1,class:"text-sm text-muted py-4 text-center"},Fe={class:"space-y-2"},We={class:"flex-1 min-w-0"},Le={class:"font-medium text-sm flex items-center gap-1.5"},Oe={class:"text-xs text-muted"},Be={key:3,class:"ml-1 text-primary text-xs"},je={class:"flex items-center gap-1"},He={key:0,class:"text-sm text-muted py-4 text-center"},qe={class:"space-y-2"},Ye={class:"flex-1 min-w-0 space-y-0.5"},Je={class:"font-medium text-sm"},Qe={class:"text-xs text-muted flex flex-wrap gap-x-3"},Xe={key:0},Ge={key:1},Ke={key:2,class:"text-warning-500"},Ze={class:"flex flex-wrap gap-1 mt-1"},et={class:"flex items-center gap-1"},yt=re({__name:"notifications",async setup(tt){let f,x;const u=de(),j=ve(),I=D(()=>j.public.authEnabled),H=["PIWI_SMTP_HOST","PIWI_SMTP_PORT","PIWI_SMTP_USER","PIWI_SMTP_PASS","PIWI_SMTP_FROM","PIWI_SMTP_FROM_NAME","PIWI_SMTP_SECURE"],{data:m}=([f,x]=A(()=>F("/api/settings/smtp","$v5NL0FLSog")),f=await f,x(),f),h=k(""),M=k(!1);async function q(){if(h.value){M.value=!0;try{const o=await $fetch("/api/settings/smtp/test",{method:"POST",body:{to:h.value}});o.success?u.add({title:"Test email sent",description:`Check ${h.value}`,color:"success"}):u.add({title:"Send failed",description:o.error||"Unknown error",color:"error"})}catch(o){u.add({title:"Send failed",description:String(o?.message??o),color:"error"})}finally{M.value=!1}}}const{data:Y,refresh:W}=I.value?([f,x]=A(()=>F("/api/channels","$rT8YNpmgfl")),f=await f,x(),f):{data:k(null),refresh:()=>{}},$=D(()=>Y.value?.channels??[]),b=k(!1),n=ye({name:"",type:"email",address:"",webhookUrl:"",url:"",secret:"",global:!1}),V=k(!1),E=k(null),J=[{label:"Email",value:"email"},{label:"Slack webhook",value:"slack"},{label:"Webhook",value:"webhook"}];async function Q(){V.value=!0;try{const o={};n.type==="email"?o.address=n.address:n.type==="slack"?o.webhookUrl=n.webhookUrl:n.type==="webhook"&&(o.url=n.url,n.secret&&(o.secret=n.secret)),await $fetch("/api/channels",{method:"POST",body:{name:n.name,type:n.type,config:o,global:n.global}}),b.value=!1,Object.assign(n,{name:"",type:"email",address:"",webhookUrl:"",url:"",secret:"",global:!1}),await W(),u.add({title:"Channel created",color:"success"})}catch(o){u.add({title:"Failed to create channel",description:String(o?.message??o),color:"error"})}finally{V.value=!1}}async function X(o){try{await $fetch(`/api/channels/${o}`,{method:"DELETE"}),await W(),u.add({title:"Channel deleted",color:"success"})}catch(e){u.add({title:"Failed to delete channel",description:String(e?.message??e),color:"error"})}}async function G(o){E.value=o;try{const e=await $fetch(`/api/channels/${o}/test`,{method:"POST"});e.success?u.add({title:"Test notification sent",color:"success"}):u.add({title:"Test failed",description:e.error,color:"error"})}catch(e){u.add({title:"Test failed",description:String(e?.message??e),color:"error"})}finally{E.value=null}}const{data:K,refresh:L}=I.value?([f,x]=A(()=>F("/api/subscriptions","$J_5QzL_eLh")),f=await f,x(),f):{data:k(null),refresh:()=>{}},N=D(()=>K.value?.subscriptions??[]);async function Z(o){try{await $fetch(`/api/subscriptions/${o}`,{method:"DELETE"}),await L(),u.add({title:"Subscription removed",color:"success"})}catch(e){u.add({title:"Failed to remove subscription",description:String(e?.message??e),color:"error"})}}async function ee(o){const e=o.mutedUntil&&new Date(o.mutedUntil)>new Date;try{await $fetch(`/api/subscriptions/${o.id}`,{method:"PATCH",body:{mutedUntil:e?null:new Date(Date.now()+10080*60*1e3).toISOString()}}),await L(),u.add({title:e?"Unmuted":"Muted for 7 days",color:"success"})}catch(U){u.add({title:"Failed to update subscription",description:String(U?.message??U),color:"error"})}}function P(o){return o.mutedUntil&&new Date(o.mutedUntil)>new Date}function O(o){return o==="personal_email"?"i-lucide-user-round":o==="email"?"i-lucide-mail":o==="slack"?"i-lucide-slack":"i-lucide-webhook"}function te(o){return o.replace(/\./g," › ")}return(o,e)=>{const U=ie,C=fe,se=he,oe=ke,S=ue,g=pe,z=xe,w=be,le=Se,B=_e,ne=we,ae=Te;return l(),r("div",Pe,[a(z,{icon:"i-lucide-mail",title:"SMTP email delivery",help:"settings.smtp"},ce({subtitle:d(()=>[e[9]||(e[9]=c(" Configure SMTP via environment variables. The connection cannot be changed here. ",-1))]),actions:d(()=>[s(m)?.configured?(l(),v(U,{key:0,"env-vars":H,size:"md"})):_("",!0)]),default:d(()=>[i("div",Ue,[s(m)?.configured?(l(),r("div",Ce,[a(C,{name:"i-lucide-circle-check-big",class:"size-4"}),e[10]||(e[10]=c(" Configured ",-1))])):(l(),r("div",Ie,[a(C,{name:"i-lucide-circle-alert",class:"size-4"}),e[11]||(e[11]=c(" Not configured ",-1))])),s(m)?.configured?(l(),r("div",Me,[e[12]||(e[12]=i("div",{class:"text-muted"},"Host",-1)),i("div",$e,p(s(m)?.host)+":"+p(s(m)?.port),1),e[13]||(e[13]=i("div",{class:"text-muted"},"From",-1)),i("div",null,p(s(m)?.fromName?`${s(m).fromName} <${s(m).from}>`:s(m)?.from),1),e[14]||(e[14]=i("div",{class:"text-muted"},"User",-1)),i("div",Ve,p(s(m)?.user),1),e[15]||(e[15]=i("div",{class:"text-muted"},"TLS",-1)),i("div",null,p(s(m)?.secure?"Yes (port 465)":"STARTTLS / plain"),1)])):_("",!0),s(m)?.configured?_("",!0):(l(),r("div",Ee,[e[16]||(e[16]=i("p",null,"Set these environment variables to enable email notifications:",-1)),a(se,{code:`PIWI_SMTP_HOST=smtp.example.com
2
2
  PIWI_SMTP_PORT=465
3
3
  PIWI_SMTP_USER=user@example.com
4
4
  PIWI_SMTP_PASS=secret