@intent-hq/web 2.320.1 → 2.321.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 (263) hide show
  1. package/package.json +1 -1
  2. package/web/app/immutable/chunks/{4o1DPfmL.js → -x_SoK5J.js} +1 -1
  3. package/web/app/immutable/chunks/{DJbnWCnN.js → 0Orrh1Id.js} +6 -6
  4. package/web/app/immutable/chunks/{Wm9WFHAU.js → 0TFOtiMK.js} +1 -1
  5. package/web/app/immutable/chunks/{DgvFQ5ps.js → 0x0gscua.js} +1 -1
  6. package/web/app/immutable/chunks/{D2Hsf4lo.js → 45y_L1a9.js} +1 -1
  7. package/web/app/immutable/chunks/{CVQvxrRM.js → 4iRc0E9v.js} +1 -1
  8. package/web/app/immutable/chunks/{CcjhvQaU.js → 5MGYaOe_.js} +1 -1
  9. package/web/app/immutable/chunks/{D7hkdi6r.js → 5QXDo1_h.js} +1 -1
  10. package/web/app/immutable/chunks/{VlQJw7Mt.js → 6cxhz2FS.js} +1 -1
  11. package/web/app/immutable/chunks/{B-NH8jPK.js → 7fl6VDRo.js} +1 -1
  12. package/web/app/immutable/chunks/{BIzCpN2r.js → 8OpKoiOO.js} +1 -1
  13. package/web/app/immutable/chunks/{Byh9jXBr.js → 8biy-UQv.js} +1 -1
  14. package/web/app/immutable/chunks/{Ck3dkN4B.js → Ab2YxsyL.js} +1 -1
  15. package/web/app/immutable/chunks/{CAoY2-K6.js → B-WefpDP.js} +1 -1
  16. package/web/app/immutable/chunks/{CQX4KubR.js → B0FM877X.js} +1 -1
  17. package/web/app/immutable/chunks/{C23Piy_l.js → B0FYEeEw.js} +1 -1
  18. package/web/app/immutable/chunks/{CpEHCOut.js → B0JWnOsx.js} +1 -1
  19. package/web/app/immutable/chunks/{C0Eg_x6y.js → B0pgN3Jj.js} +1 -1
  20. package/web/app/immutable/chunks/{BJfH3e03.js → B1WyTcs2.js} +3 -3
  21. package/web/app/immutable/chunks/{C-r1nQ0P.js → B2c_0_UD.js} +2 -2
  22. package/web/app/immutable/chunks/{BtxYdCDO.js → B2yYgkwz.js} +1 -1
  23. package/web/app/immutable/chunks/{DnIfn_Q5.js → B5nbjbRb.js} +1 -1
  24. package/web/app/immutable/chunks/{Cmsg1-Jz.js → B6DUgu-2.js} +1 -1
  25. package/web/app/immutable/chunks/{BpzYGtC7.js → B7BTR3Z_.js} +1 -1
  26. package/web/app/immutable/chunks/{eeOO6ePS.js → B9MBednq.js} +1 -1
  27. package/web/app/immutable/chunks/{GzyujEXJ.js → BBZiE97y.js} +1 -1
  28. package/web/app/immutable/chunks/{CjOd6IrN.js → BBeErNG6.js} +1 -1
  29. package/web/app/immutable/chunks/{CwKQMp5y.js → BC1v75_H.js} +1 -1
  30. package/web/app/immutable/chunks/{D02FkLBh.js → BD8I8FK1.js} +1 -1
  31. package/web/app/immutable/chunks/{gV7ZxrZ2.js → BDgfVkJh.js} +1 -1
  32. package/web/app/immutable/chunks/{DBEuoua2.js → BEQ_aNVt.js} +2 -2
  33. package/web/app/immutable/chunks/{C-_w8CdN.js → BG-UHIO1.js} +2 -2
  34. package/web/app/immutable/chunks/{BtA94G-4.js → BGFrQA7m.js} +1 -1
  35. package/web/app/immutable/chunks/{CW_i4yzi.js → BGiTQR4x.js} +1 -1
  36. package/web/app/immutable/chunks/{O4y88_QN.js → BLhWzQz2.js} +1 -1
  37. package/web/app/immutable/chunks/{BRqOyyER.js → BM51eWC-.js} +1 -1
  38. package/web/app/immutable/chunks/{VE9Tc-Fm.js → BMH4mbSd.js} +2 -2
  39. package/web/app/immutable/chunks/{CpnH3je1.js → BMc6OzJ-.js} +2 -2
  40. package/web/app/immutable/chunks/{Dkt7Tsgw.js → BMvbnoDk.js} +1 -1
  41. package/web/app/immutable/chunks/{DAgho_P-.js → BOaNSc_1.js} +1 -1
  42. package/web/app/immutable/chunks/{BZrP_BN5.js → BOrghaSd.js} +2 -2
  43. package/web/app/immutable/chunks/{DDRNgELR.js → BPp7FHiR.js} +1 -1
  44. package/web/app/immutable/chunks/{C0HDG-tg.js → BS5yagDq.js} +1 -1
  45. package/web/app/immutable/chunks/{4EPU-1_C.js → BWHu0fap.js} +1 -1
  46. package/web/app/immutable/chunks/{CT5WLLvq.js → BX-dt_Uh.js} +1 -1
  47. package/web/app/immutable/chunks/{DnWPcgvb.js → BXPwex0u.js} +1 -1
  48. package/web/app/immutable/chunks/{CDFwOYFZ.js → BXean12D.js} +1 -1
  49. package/web/app/immutable/chunks/{BTVnc-yD.js → BZyfa8QR.js} +1 -1
  50. package/web/app/immutable/chunks/{DcQGtdYG.js → BbCn81lZ.js} +1 -1
  51. package/web/app/immutable/chunks/{D2MFHl3c.js → Bc-CUZMV.js} +1 -1
  52. package/web/app/immutable/chunks/{49Xcxy9Z.js → Bcc7Bzbg.js} +1 -1
  53. package/web/app/immutable/chunks/{DQSz8rIC.js → BcpqnYRX.js} +5 -5
  54. package/web/app/immutable/chunks/{H5XG0yyu.js → BdWpSBC4.js} +2 -2
  55. package/web/app/immutable/chunks/{BxxQ5pIU.js → BeqbwVaJ.js} +1 -1
  56. package/web/app/immutable/chunks/{DgDI47Tl.js → BflC9e-C.js} +1 -1
  57. package/web/app/immutable/chunks/{DSP3ClFU.js → Bgw4M5Hc.js} +1 -1
  58. package/web/app/immutable/chunks/{lzfQOUtM.js → Bi4OiJD3.js} +1 -1
  59. package/web/app/immutable/chunks/{CIH3mb7Y.js → BkR5Qiti.js} +1 -1
  60. package/web/app/immutable/chunks/{BMJ3_jM1.js → Bknqawxe.js} +1 -1
  61. package/web/app/immutable/chunks/{2d9ARddo.js → Bm_1OUSw.js} +1 -1
  62. package/web/app/immutable/chunks/{DVX1HL-4.js → Bmmshx2M.js} +1 -1
  63. package/web/app/immutable/chunks/{DYepVMa7.js → Bo4s1kgI.js} +3 -3
  64. package/web/app/immutable/chunks/{D_FHOcPH.js → Bok30zBH.js} +1 -1
  65. package/web/app/immutable/chunks/{DsQHEEWt.js → BsB3ty-n.js} +1 -1
  66. package/web/app/immutable/chunks/{BsCDeyle.js → BtTBXjdJ.js} +1 -1
  67. package/web/app/immutable/chunks/{r2I2bB7k.js → BtWwzwrf.js} +1 -1
  68. package/web/app/immutable/chunks/{D8UQMJEh.js → BvkV35-O.js} +1 -1
  69. package/web/app/immutable/chunks/{fUyHJpWx.js → BwICfRz9.js} +1 -1
  70. package/web/app/immutable/chunks/{CfpYQrWa.js → BwYRCP9e.js} +1 -1
  71. package/web/app/immutable/chunks/{C9Az19Q-.js → ByKL05wN.js} +1 -1
  72. package/web/app/immutable/chunks/{u-Ou3zHY.js → Byv2GcxJ.js} +2 -2
  73. package/web/app/immutable/chunks/{D-NAfI6p.js → BziQ6zwo.js} +1 -1
  74. package/web/app/immutable/chunks/{SrOLwB5L.js → C-RJDuZ9.js} +1 -1
  75. package/web/app/immutable/chunks/{IsZuHG2a.js → C-neqscP.js} +1 -1
  76. package/web/app/immutable/chunks/{CtNKFf3W.js → C06rhFz-.js} +1 -1
  77. package/web/app/immutable/chunks/{VKc1-U2z.js → C0VXEpDj.js} +1 -1
  78. package/web/app/immutable/chunks/{ivVGXMNS.js → C0mBOV7w.js} +1 -1
  79. package/web/app/immutable/chunks/{B9MzVcgv.js → C11XjPnf.js} +3 -3
  80. package/web/app/immutable/chunks/{55B_mQC6.js → C3AKbypo.js} +6 -6
  81. package/web/app/immutable/chunks/{ChV6OcuF.js → C3lgqjB4.js} +1 -1
  82. package/web/app/immutable/chunks/{DFRP5ruh.js → C5aeZ3Yo.js} +2 -2
  83. package/web/app/immutable/chunks/{Bk4gFCP5.js → C6-BVYMv.js} +1 -1
  84. package/web/app/immutable/chunks/C76-jvlr.js +19 -0
  85. package/web/app/immutable/chunks/{DlUfd75E.js → C7JWgw8J.js} +3 -3
  86. package/web/app/immutable/chunks/{DjWen1vr.js → C804xHCz.js} +1 -1
  87. package/web/app/immutable/chunks/{DdteGby8.js → C8xPpxcv.js} +1 -1
  88. package/web/app/immutable/chunks/{BoUhyyfU.js → C8zzua9V.js} +1 -1
  89. package/web/app/immutable/chunks/{CuTNRxpo.js → CAgY0H5Q.js} +1 -1
  90. package/web/app/immutable/chunks/{ApbPdiAE.js → CBxbaIvA.js} +1 -1
  91. package/web/app/immutable/chunks/CCaX_DIa.js +1 -0
  92. package/web/app/immutable/chunks/{7z2H_RtS.js → CCnP87Jb.js} +1 -1
  93. package/web/app/immutable/chunks/{CrkvePNd.js → CCsRc7xx.js} +1 -1
  94. package/web/app/immutable/chunks/{CXux1NAJ.js → CDsY8gY8.js} +1 -1
  95. package/web/app/immutable/chunks/{DMu4mjpX.js → CEFpGNTq.js} +1 -1
  96. package/web/app/immutable/chunks/{V4Dt-iuy.js → CEj75uMJ.js} +1 -1
  97. package/web/app/immutable/chunks/{Le4YFzxz.js → CG9qWr93.js} +3 -3
  98. package/web/app/immutable/chunks/{DjfcjPFA.js → CGBBhq8k.js} +1 -1
  99. package/web/app/immutable/chunks/{DU9iEtZ1.js → CGIf2jXM.js} +1 -1
  100. package/web/app/immutable/chunks/{BS3L5ssG.js → CGVJO4eq.js} +1 -1
  101. package/web/app/immutable/chunks/{ipFV2AXr.js → CHM5tGJ6.js} +1 -1
  102. package/web/app/immutable/chunks/CHRkLzGl.js +1 -0
  103. package/web/app/immutable/chunks/{D5BYjywr.js → CHZAzCO9.js} +2 -2
  104. package/web/app/immutable/chunks/{Dby-RtfB.js → CIh8Ybhq.js} +1 -1
  105. package/web/app/immutable/chunks/{BnY6qa9O.js → CKO4faLg.js} +1 -1
  106. package/web/app/immutable/chunks/{Cm-Ux8AK.js → CKwPlZ66.js} +1 -1
  107. package/web/app/immutable/chunks/{5BaUgoc7.js → CLmrIbfi.js} +1 -1
  108. package/web/app/immutable/chunks/{DeFnstZp.js → CM7Hb3PZ.js} +1 -1
  109. package/web/app/immutable/chunks/{JwXVdNK9.js → CN70DRE5.js} +1 -1
  110. package/web/app/immutable/chunks/{Dbcyn1sm.js → CPKLysog.js} +1 -1
  111. package/web/app/immutable/chunks/CRyHSgI1.js +1 -0
  112. package/web/app/immutable/chunks/{Bv7Cc181.js → CS7dHtKw.js} +1 -1
  113. package/web/app/immutable/chunks/{XL81JlY3.js → CTlGDL05.js} +1 -1
  114. package/web/app/immutable/chunks/{DkrIcKd4.js → CVjlpAWj.js} +3 -3
  115. package/web/app/immutable/chunks/{vnFqKiHP.js → CVrH3Neh.js} +1 -1
  116. package/web/app/immutable/chunks/{D7ZBvVv7.js → CXIZuwd7.js} +1 -1
  117. package/web/app/immutable/chunks/{IYLMGQxr.js → CY9IKMQG.js} +1 -1
  118. package/web/app/immutable/chunks/{CKiOztob.js → CYOvUFvY.js} +1 -1
  119. package/web/app/immutable/chunks/{DOxrGs5l.js → CZEWv-Gf.js} +1 -1
  120. package/web/app/immutable/chunks/{jiIr1QvR.js → C_Vz3LCC.js} +1 -1
  121. package/web/app/immutable/chunks/{sOHh4EMg.js → Cb3FWEmc.js} +1 -1
  122. package/web/app/immutable/chunks/{BvO0zD3q.js → Cbqk5Mud.js} +1 -1
  123. package/web/app/immutable/chunks/{BkH6TsO0.js → CchM71Qw.js} +1 -1
  124. package/web/app/immutable/chunks/{zl8Sz0Gx.js → CdGIN-T1.js} +3 -3
  125. package/web/app/immutable/chunks/{V_BIwIYH.js → CdVKa6AF.js} +2 -2
  126. package/web/app/immutable/chunks/{CMcfEzCt.js → Ced26xBL.js} +1 -1
  127. package/web/app/immutable/chunks/{DukwQosN.js → Ci959ZOg.js} +1 -1
  128. package/web/app/immutable/chunks/{DDhu5Shq.js → Cja4W1Zb.js} +4 -4
  129. package/web/app/immutable/chunks/{DtL3mwiX.js → CmAVmm3T.js} +1 -1
  130. package/web/app/immutable/chunks/CmYXfe7_.js +1 -0
  131. package/web/app/immutable/chunks/{BoAwi0I6.js → CoUfnBeR.js} +1 -1
  132. package/web/app/immutable/chunks/{COuKp8NZ.js → Cq6ekj5I.js} +1 -1
  133. package/web/app/immutable/chunks/{CrF5hjNA.js → CqGkRJXi.js} +1 -1
  134. package/web/app/immutable/chunks/{CGVZRNqq.js → Cqay3Iio.js} +1 -1
  135. package/web/app/immutable/chunks/{D8l-pxCs.js → CsqvO7xN.js} +1 -1
  136. package/web/app/immutable/chunks/{DQhHyGm2.js → Ctggj9Y1.js} +1 -1
  137. package/web/app/immutable/chunks/{CTIoKRdg.js → Cts399i7.js} +1 -1
  138. package/web/app/immutable/chunks/{TRcwahzR.js → CulY8r4s.js} +1 -1
  139. package/web/app/immutable/chunks/{3TX-_riq.js → CvBuWqyP.js} +4 -4
  140. package/web/app/immutable/chunks/{DB531Hr_.js → CvegPRPp.js} +2 -2
  141. package/web/app/immutable/chunks/{Do2QepJk.js → Cwv7iryQ.js} +1 -1
  142. package/web/app/immutable/chunks/{CYvGLw1Y.js → CxQ0SCX2.js} +1 -1
  143. package/web/app/immutable/chunks/{DZxiqmZj.js → CxZuxrAL.js} +1 -1
  144. package/web/app/immutable/chunks/{sWFJeG75.js → Cz8iOYm8.js} +1 -1
  145. package/web/app/immutable/chunks/{DUW0BlH5.js → CztKENY4.js} +1 -1
  146. package/web/app/immutable/chunks/{XWXuV5J_.js → D26IPp5S.js} +1 -1
  147. package/web/app/immutable/chunks/{mEKKjA-u.js → D2iCI9dn.js} +1 -1
  148. package/web/app/immutable/chunks/{CZFJH8pA.js → D2zJp5fS.js} +29 -29
  149. package/web/app/immutable/chunks/{Bv-JB2Uu.js → D4e2w8TP.js} +1 -1
  150. package/web/app/immutable/chunks/{BmGPu7Nl.js → D5lr7eae.js} +2 -2
  151. package/web/app/immutable/chunks/{9Lm8k_8r.js → D6dCvfQe.js} +1 -1
  152. package/web/app/immutable/chunks/{CMeoq2YD.js → D7q-DSVP.js} +1 -1
  153. package/web/app/immutable/chunks/{Btkc4GhJ.js → D84A4J8d.js} +1 -1
  154. package/web/app/immutable/chunks/{Df_CcsUd.js → DDdLPEvL.js} +1 -1
  155. package/web/app/immutable/chunks/{DU9yd1xn.js → DDnwQoVq.js} +1 -1
  156. package/web/app/immutable/chunks/{MJGmlCLu.js → DFcwI6Rh.js} +1 -1
  157. package/web/app/immutable/chunks/{BQKHJuv8.js → DFyBaL9d.js} +1 -1
  158. package/web/app/immutable/chunks/{CCmXROuj.js → DI4wCe7O.js} +1 -1
  159. package/web/app/immutable/chunks/{DSbw-nyW.js → DJKXcaw9.js} +1 -1
  160. package/web/app/immutable/chunks/{B524kvVw.js → DMRQ6CDd.js} +2 -2
  161. package/web/app/immutable/chunks/{i3h2CX4F.js → DMvfzQWM.js} +1 -1
  162. package/web/app/immutable/chunks/{KJelEqX3.js → DNFHGDC9.js} +1 -1
  163. package/web/app/immutable/chunks/{R6dAjEem.js → DNNMwmDG.js} +1 -1
  164. package/web/app/immutable/chunks/{CZ5Pr0zI.js → DOzF5uE-.js} +1 -1
  165. package/web/app/immutable/chunks/{DDdEHmdT.js → DPoarPZL.js} +1 -1
  166. package/web/app/immutable/chunks/{273-ejOd.js → DR4i54x0.js} +1 -1
  167. package/web/app/immutable/chunks/{CCVg2HgS.js → DRpDjwRs.js} +1 -1
  168. package/web/app/immutable/chunks/{Dy4G53ce.js → DS2Q5gr9.js} +1 -1
  169. package/web/app/immutable/chunks/{B-ukGsyU.js → DSdY0J1g.js} +1 -1
  170. package/web/app/immutable/chunks/{DgvGDMI5.js → DXySew1R.js} +1 -1
  171. package/web/app/immutable/chunks/{C72zM9oE.js → DYfBNrOV.js} +1 -1
  172. package/web/app/immutable/chunks/{CCghBHzC.js → DYhpST_X.js} +1 -1
  173. package/web/app/immutable/chunks/{QeTaV4Op.js → DZAWjsA4.js} +1 -1
  174. package/web/app/immutable/chunks/{CBE9bOjQ.js → DZtstCLQ.js} +1 -1
  175. package/web/app/immutable/chunks/{B1892jNy.js → D_HysCp7.js} +1 -1
  176. package/web/app/immutable/chunks/{BOypJjQg.js → Dd0rdLMI.js} +1 -1
  177. package/web/app/immutable/chunks/{CwSP6heW.js → Dd7A9glX.js} +1 -1
  178. package/web/app/immutable/chunks/{C2pLxq9N.js → Dgqdx3pd.js} +1 -1
  179. package/web/app/immutable/chunks/{Ca0VZzWN.js → DhtKWu39.js} +1 -1
  180. package/web/app/immutable/chunks/{BBvT7Bb8.js → Dix9BiYu.js} +1 -1
  181. package/web/app/immutable/chunks/{CK2xtMaJ.js → DjqPgoUP.js} +1 -1
  182. package/web/app/immutable/chunks/DlBxdhh5.js +2 -0
  183. package/web/app/immutable/chunks/{CgQiyraX.js → DlZzAKZ2.js} +1 -1
  184. package/web/app/immutable/chunks/{CW_MTCOu.js → DnfX8iZ_.js} +1 -1
  185. package/web/app/immutable/chunks/Dritbi2C.js +6 -0
  186. package/web/app/immutable/chunks/{cYktK7bI.js → DsRLPs6I.js} +10 -10
  187. package/web/app/immutable/chunks/{DVijqcE1.js → Du7yAEgM.js} +1 -1
  188. package/web/app/immutable/chunks/{oB6nSTCC.js → DuMlpvYZ.js} +1 -1
  189. package/web/app/immutable/chunks/{DbSP_yi5.js → DwNzQjT_.js} +1 -1
  190. package/web/app/immutable/chunks/{DWcUEP_3.js → DwsRDnkS.js} +4 -4
  191. package/web/app/immutable/chunks/{T2aO1XPv.js → DyVNmy1r.js} +1 -1
  192. package/web/app/immutable/chunks/{IwQXvQKq.js → I0eHZGMz.js} +1 -1
  193. package/web/app/immutable/chunks/{DLme1vI4.js → JfyBNQs2.js} +1 -1
  194. package/web/app/immutable/chunks/{YGDnq71P.js → NeHKo0ZG.js} +1 -1
  195. package/web/app/immutable/chunks/{CAhuuwZ9.js → O0CxvO89.js} +1 -1
  196. package/web/app/immutable/chunks/{DudXAl_N.js → Ob5NWDgS.js} +1 -1
  197. package/web/app/immutable/chunks/{Dczc0YMo.js → PUalo3UE.js} +1 -1
  198. package/web/app/immutable/chunks/{DXjHY2hF.js → QGE3iD8D.js} +1 -1
  199. package/web/app/immutable/chunks/{_p09hiud.js → QSR6vsk4.js} +1 -1
  200. package/web/app/immutable/chunks/{9tzjcklF.js → QjpXu0Du.js} +1 -1
  201. package/web/app/immutable/chunks/{CPObUSo8.js → UEd-gngc.js} +1 -1
  202. package/web/app/immutable/chunks/VEkj47bo.js +1 -0
  203. package/web/app/immutable/chunks/{Cx547a39.js → VeIqG7dc.js} +4 -4
  204. package/web/app/immutable/chunks/{j3QkolT-.js → XF_IbTR1.js} +3 -3
  205. package/web/app/immutable/chunks/{CcVvQKcJ.js → XV0T3w4n.js} +1 -1
  206. package/web/app/immutable/chunks/{Dk1FwKDL.js → YO4PhogQ.js} +1 -1
  207. package/web/app/immutable/chunks/{BLl4jbbs.js → aLZSbque.js} +2 -2
  208. package/web/app/immutable/chunks/{DKBox7Ew.js → csuWDYc9.js} +1 -1
  209. package/web/app/immutable/chunks/{CnlzKY2y.js → dmSYAakE.js} +1 -1
  210. package/web/app/immutable/chunks/eK7OULll.js +1 -0
  211. package/web/app/immutable/chunks/{Cugknw1m.js → gCXIPBa3.js} +1 -1
  212. package/web/app/immutable/chunks/{CJhkZF1l.js → hxIWaKu8.js} +1 -1
  213. package/web/app/immutable/chunks/{C3lmZVdU.js → jMKjj8ae.js} +1 -1
  214. package/web/app/immutable/chunks/{Dpk7e0gp.js → jvHJQ-Xz.js} +1 -1
  215. package/web/app/immutable/chunks/{BB6TPLRQ.js → k4eU_FWk.js} +1 -1
  216. package/web/app/immutable/chunks/{BigdBsL9.js → nLw8YrmA.js} +1 -1
  217. package/web/app/immutable/chunks/{mk8wN9pR.js → nR16njgN.js} +1 -1
  218. package/web/app/immutable/chunks/{Dld3dCA-.js → o5rEX9Xy.js} +1 -1
  219. package/web/app/immutable/chunks/{B30Ssr1r.js → p5gLe3PS.js} +1 -1
  220. package/web/app/immutable/chunks/{VKC6gzws.js → pnKMO5U0.js} +53 -53
  221. package/web/app/immutable/chunks/{CGTFiYKr.js → reR1kPlm.js} +1 -1
  222. package/web/app/immutable/chunks/{BwfkZxtl.js → tGqA6xQ9.js} +1 -1
  223. package/web/app/immutable/chunks/uLB4Kp9c.js +1 -0
  224. package/web/app/immutable/chunks/{CI-U2zwu.js → ubLEbEcV.js} +1 -1
  225. package/web/app/immutable/chunks/{Dtei9o3U.js → uyOfKmty.js} +3 -3
  226. package/web/app/immutable/chunks/{DVRDTT5s.js → vUGF5JqJ.js} +1 -1
  227. package/web/app/immutable/chunks/{DamIfQPR.js → vzGm0J_h.js} +1 -1
  228. package/web/app/immutable/chunks/{Dlalsrb2.js → w6mFE4SD.js} +1 -1
  229. package/web/app/immutable/chunks/{OvSKCwS-.js → z3QVK190.js} +2 -2
  230. package/web/app/immutable/entry/{app.DnikQ4I9.js → app.PHHlgSoZ.js} +3 -3
  231. package/web/app/immutable/entry/start.Cltn4m6a.js +1 -0
  232. package/web/app/immutable/nodes/{0.C7A1xQm9.js → 0.D7bJjS_y.js} +1 -1
  233. package/web/app/immutable/nodes/{1.D3O5lTcl.js → 1.B3gH8FG5.js} +1 -1
  234. package/web/app/immutable/nodes/{10.BaLN4VIK.js → 10.NQcSgQgq.js} +4 -4
  235. package/web/app/immutable/nodes/{11.DNy1N3E_.js → 11.Drfz7PRj.js} +1 -1
  236. package/web/app/immutable/nodes/{12.CkJqJXDQ.js → 12.gXokqM9g.js} +1 -1
  237. package/web/app/immutable/nodes/{13.BQO-XqRU.js → 13.DFxxGy6Y.js} +3 -3
  238. package/web/app/immutable/nodes/{14.BycEEfsq.js → 14.7T2ChNl_.js} +1 -1
  239. package/web/app/immutable/nodes/{15.Cul5GEsK.js → 15.CgEeXtgJ.js} +1 -1
  240. package/web/app/immutable/nodes/{16.BjrtGDLp.js → 16.CWrHY2VB.js} +2 -2
  241. package/web/app/immutable/nodes/{2.Cfk2c4l0.js → 2.DQ6QcB9c.js} +8 -8
  242. package/web/app/immutable/nodes/{3.Dp8QGgRH.js → 3.Fjkgohv2.js} +1 -1
  243. package/web/app/immutable/nodes/{4.D3m3OUdj.js → 4.D1BNF_ep.js} +1 -1
  244. package/web/app/immutable/nodes/{5.BMBYYbKi.js → 5.C5OySrRk.js} +2 -2
  245. package/web/app/immutable/nodes/{6.BIo4yUgT.js → 6.BrxG9qCf.js} +1 -1
  246. package/web/app/immutable/nodes/{7.DdNd4GXX.js → 7.CvdabbdY.js} +1 -1
  247. package/web/app/immutable/nodes/8.BSQtFfFS.js +15 -0
  248. package/web/app/immutable/nodes/{9.kCWJBZ1N.js → 9.D6DS9Z9f.js} +5 -5
  249. package/web/app/version.json +1 -1
  250. package/web/generated/paraglide.js +49 -49
  251. package/web/index.html +18 -18
  252. package/web/app/immutable/chunks/4Qt-u50Z.js +0 -1
  253. package/web/app/immutable/chunks/B--T3tY0.js +0 -19
  254. package/web/app/immutable/chunks/BJzlL5VK.js +0 -1
  255. package/web/app/immutable/chunks/C7-4lB53.js +0 -6
  256. package/web/app/immutable/chunks/CR8nwpLC.js +0 -1
  257. package/web/app/immutable/chunks/CduK2Osu.js +0 -1
  258. package/web/app/immutable/chunks/CmTfIBH2.js +0 -2
  259. package/web/app/immutable/chunks/DakbBhJV.js +0 -1
  260. package/web/app/immutable/chunks/DclJ6-AA.js +0 -1
  261. package/web/app/immutable/chunks/DozYGPQ1.js +0 -1
  262. package/web/app/immutable/entry/start.DW0TPq6E.js +0 -1
  263. package/web/app/immutable/nodes/8.Cp6GdAVQ.js +0 -15
@@ -1,2 +1,2 @@
1
- import{N as U,f as L,an as G,ak as Q,av as j,o as V,c as X}from"./SrOLwB5L.js";import{HQ as u,nl as M,HZ as H,bj as T,a0 as $,n7 as _,qR as N,nk as W,rb as z,ka as Y,r9 as R,Ig as v,qy as Z,fK as q,qS as P,a2 as J,bh as tt,g as et}from"./DYepVMa7.js";import{y as K,aA as nt,v as st}from"./BLl4jbbs.js";const ot=["[WORKSPACE EVENTS]","[TASK WAKE]","[AGENT MESSAGE]"];function it(t){const e=t.metadata;if(e&&typeof e=="object"){if(e.type==="question_answers")return!1;if(!U(e))return!0}const n=L(t);return ot.some(s=>n.startsWith(s))}const rt=1440*60*1e3;function at(t){let e=null;for(const n of t){if(it({id:n.id,timestamp:n.createdAt,metadata:n.metadata,contentBlocks:[{type:"text",text:n.preview.trimStart()}]}))continue;const s=Date.parse(n.createdAt);Number.isFinite(s)&&(e===null||s>e)&&(e=s)}return e}const ct=50,lt=20;function E(t,e){return t===null||e!==null&&e>t?e:t}async function Mt(t,e){let n,s=null;for(let i=0;i<lt;i++){const o=await t({limit:ct,nextToken:n});if(!o.ok)return null;const c=o.items;s===null&&c.length>0&&(s=c[c.length-1].id);const l=e?.newestId!=null?c.findIndex(a=>a.id===e.newestId):-1,r=at(l>=0?c.slice(l+1):c);if(l>=0)return{latest:E(r,e?.latest??null),newestId:s};if(r!==null)return{latest:E(r,e?.latest??null),newestId:s};if(typeof o.nextToken!="string")return{latest:null,newestId:s};n=o.nextToken}return{latest:e?.latest??null,newestId:s}}function ut(t,e){return t!=null&&t<=e&&t>e-rt}u.createSelector(t=>t.hud.active);u.createSelector(t=>t.hud.feed);u.createSelector(t=>t.hud.usage);u.createSelector(t=>t.hud.usageError);const _t=u.createSelector(t=>t.hud.rateHistory),Wt=u.createSelector(t=>M(t.workspace.workspaces)),Bt=u.createSelector(t=>{const e=t.hud.usage?.totals;return e?H(e):0}),Rt=u.createSelector(t=>t.hud.burnRatePerMin),Et=u.createSelector(t=>t.hud.burnTrend),Dt=u.createSelector(t=>{const{health:e,stats:n,lastUpdated:s,hostLocality:i}=t.daemonHealth,o=n?.hostname;return{online:e!=="down",uptimeSeconds:typeof n?.uptimeSeconds=="number"?n.uptimeSeconds:null,version:n?.version??null,fetchedAtMs:s?Date.parse(s):null,remoteHostname:i==="remote"&&o?o.split(".",1)[0]??o:null}}),Ct=u.createSelector(t=>t.hud.gridFilter);u.createSelector(t=>t.hud.attentionByWorkspaceId);const Ht=u.createSelector((t,e)=>{const n=t.hud?.questionsByAgentId?.[e];if(!n)return!1;const s=t.agentSessions?.byAgentId[e]?.metadata??{};return!K(s,n.messageId)}),Nt=u.createSelector(t=>t.hud.takeoverRequestWorkspaceId);function dt(t,e){return e[String(t.id)]??t.displayStatus}const S=u.createSelector(t=>{const e=t.hud.displayStatusByWorkspaceId;return M(t.workspace.workspaces).filter(n=>n.status!==T.Archived&&n.status!==T.Retired&&n.status!==T.Deleted).map(n=>{const s=dt(n,e);return s&&s!==n.displayStatus?{...n,displayStatus:s}:n})});function y(t){const e=t.agentSummary;return!e||!Array.isArray(e.agents)?[]:e.agents.filter(n=>!!n&&typeof n=="object"&&typeof n.id=="string"&&n.status!=="deleted"&&!st(n.id))}const qt=u.createSelector(t=>{const e=Object.fromEntries($.map(n=>[n,0]));for(const n of S.select(t))for(const s of y(n))e[m(t,s).bucket]+=1;return e}),Pt=u.createSelector(t=>{const e={idle:0,unread:0,progress:0,attention:0,waiting:0,prOpen:0,prMerged:0,failed:0,completed:0,total:0};for(const n of B.select(t))switch(e.total+=1,n.isUnread&&(e.unread+=1),n.isWaiting&&(e.waiting+=1),n.stateKey){case"wait":case"blocked":e.attention+=1;break;case"failed":e.failed+=1;break;case"in_progress":e.progress+=1;break;case"complete":e.completed+=1;break;case"pr_open":case"pr_ready":case"pr_queued":e.prOpen+=1;break;case"pr_merged":e.prMerged+=1;break;default:e.idle+=1}return e}),gt=u.createSelector(t=>{const e={};for(const n of S.select(t))for(const s of y(n))typeof s.name=="string"&&s.name.length>0&&(e[s.id]=s.name);return e});function D(t){if(!t.sinceTs)return 0;const e=Date.parse(t.sinceTs);return Number.isFinite(e)?e:0}const Kt=u.createSelector(t=>{const e=t.hud.attentionByWorkspaceId,n=t.hud.questionsByAgentId,s=[];for(const i of S.select(t)){const o=String(i.id);let c=!1;for(const r of b(i,t)){const{bucket:a,attentionKind:d,hasQuestion:g}=r;if(a!=="needs-attention"&&a!=="failed"||!r.topLevel||r.isBackground||A(t,r.id))continue;const k=g?n[r.id]:void 0,f=d?_(t.agentSessions?.byAgentId[r.id])?.reason:void 0,p=k?"question":d??void 0;s.push({workspaceId:o,workspaceTitle:i.title,kind:a==="needs-attention"?"agent_waiting":"agent_failed",...a==="needs-attention"&&p?{signal:p}:{},agentName:r.name,message:k?.question??f??null,sinceTs:r.lastActivityTs}),c=!0}const l=e[o];l&&N(l.attention)&&(s.push({workspaceId:o,workspaceTitle:i.title,kind:"workspace_attention",attention:l.attention,message:null,sinceTs:l.raisedAtTs}),c=!0),x.has(I(i))&&!c&&s.push({workspaceId:o,workspaceTitle:i.title,kind:"workspace_attention",message:null,sinceTs:null})}return s.sort((i,o)=>D(o)-D(i))}),xt=u.createSelector(t=>{const e=gt.select(t);return t.hud.feed.map(n=>({...n,workspaceTitle:W(t.workspace.workspaces,n.source)?.title??null,resolvedAgentName:n.agentName??(n.agentId?e[n.agentId]??null:null)}))}),ft={total:0,completed:0,inProgress:0};function I(t){const e=z(t.displayStatus)?t.displayStatus:"not_started";return Y(e)??"not_started"}const x=new Set(["wait","blocked","failed"]);function pt(t,e,n){if(e==="failed"){const i=n.find(c=>c.bucket==="failed"&&!A(t,c.id)),o=i?t.agentSessions?.byAgentId[i.id]?.stopReason:null;return{kind:"failed",text:typeof o=="string"&&o.length>0?o:""}}if(e!=="wait"&&e!=="blocked")return null;const s=n.filter(i=>i.topLevel&&!i.isBackground&&!A(t,i.id));for(const i of s){if(!i.hasQuestion)continue;const o=t.hud.questionsByAgentId[i.id];if(o?.question)return{kind:"question",text:o.question}}for(const i of["blocker","discussion"])for(const o of s){if(o.attentionKind!==i)continue;const c=t.agentSessions?.byAgentId[o.id],l=_(c)?.reason;if(l)return{kind:i,text:l}}return{kind:"pending",text:""}}const h=new Set(["running","needs-attention","failed"]);function C(t){const e=typeof t.lastActivity=="string"?Date.parse(t.lastActivity):NaN;return Number.isFinite(e)?e:-1/0}function kt(t){const e=n=>{const s=t.get(n.id)?.bucket;return s!==void 0&&h.has(s)?0:1};return(n,s)=>{const i=n.specialist==="spec-writer",o=s.specialist==="spec-writer";if(i!==o)return i?-1:1;const c=e(n)-e(s);if(c!==0)return c;const l=C(n),r=C(s);return l!==r?r-l:n.id<s.id?-1:n.id>s.id?1:0}}function St(t,e){const n=new Set(t.map(r=>r.id)),s=new Map,i=[];for(const r of t){const a=typeof r.parentAgentId=="string"&&r.parentAgentId!==r.id&&n.has(r.parentAgentId)?r.parentAgentId:null;if(a){const d=s.get(a)??[];d.push(r),s.set(a,d)}else i.push(r)}i.sort(e);for(const r of s.values())r.sort(e);const o=[],c=new Set,l=(r,a,d)=>{if(!c.has(r.id)){c.add(r.id),o.push({info:r,depth:a,parentAgentId:d});for(const g of s.get(r.id)??[])l(g,a+1,r.id)}};for(const r of i)l(r,0,null);for(const r of t)l(r,0,null);return o}function m(t,e){const n=t.agentSessions?.byAgentId[e.id],s=n?.metadata??{},i=n?_(n)?.kind??null:null,o=n?G.select(t,e.id)||typeof n.status=="string"&&R(n.status):R(e.status),c=n?v(typeof n.status=="string"?n.status:e.status):null,l=!!n&&c!=="failed"&&c!=="done"&&(n.isWaitingForOtherAgents===!0||Array.isArray(n.waitingForAgentIds)&&n.waitingForAgentIds.length>0||Array.isArray(n.waitingOnHooks)&&n.waitingOnHooks.length>0||Array.isArray(n.waitingOnPrMonitors)&&n.waitingOnPrMonitors.length>0||Array.isArray(n.waitingOnScriptMonitors)&&n.waitingOnScriptMonitors.length>0),r=!!n&&(n.turnInFlight===!0||n.liveTurnOpen===!0);let a;n?l&&!r&&n.isStreaming!==!0&&n.isProcessing!==!0?a="idle":Q.select(t,e.id)?a="running":o?a="idle":a=v(typeof n.status=="string"?n.status:e.status):a=e.isResponding===!0||e.isStreaming===!0?"running":v(e.status);const d=t.hud.questionsByAgentId[e.id],g=a!=="failed"&&!!d&&!K(s,d.messageId);return{bucket:a==="failed"?"failed":i!==null||g?"needs-attention":a,attentionKind:i,hasQuestion:g,isRunning:a==="running"}}function F(t,e){const n=i=>typeof i=="string"&&i!==t.id?i:null,s=i=>({isBackground:i?.isBackground,createdByAgentId:n(i?.createdByAgentId)});return{parentAgentId:n(t.parentAgentId)??n(e?.parentAgentId),isBackground:t.isBackground??e?.isBackground,metadata:s(e?.metadata),agentMetadata:s(e?.agentMetadata)}}function A(t,e){return t.agentSessions?.byAgentId[e]?.notificationsMuted===!0}function At(t){if(!t)return null;switch(t.kind){case"attention":return t.attention.reason??null;case"live-tool":case"last-tool":{const e=X(t.toolUse.name,t.toolUse.input||{});return e.hidden?null:[e.verb,e.subject,e.path].filter(Boolean).join(" ").trim()||null}default:{const e=t.text||"";return e?e.includes(`
2
- `)?V(e)||null:e:null}}}function b(t,e){const n=y(t),s=new Map(n.map(o=>[o.id,m(e,o)]));return St(n,kt(s)).map(({info:o,depth:c,parentAgentId:l})=>{const r=e.agentSessions?.byAgentId[o.id],a=F(o,r),{bucket:d,attentionKind:g,hasQuestion:k}=s.get(o.id)??m(e,o),f=Array.isArray(r?.waitingForAgentIds)?r.waitingForAgentIds.filter(p=>typeof p=="string"):[];return{id:o.id,name:o.name,bucket:d,lastActivityTs:o.lastActivity??null,line:At(j.select(e,o.id)),parentAgentId:l,depth:c,treePrefix:"",topLevel:q(a)==="topLevel",isBackground:Z(a),attentionKind:g,hasQuestion:k,isWaitingForAgents:r?.isWaitingForOtherAgents===!0||f.length>0||Array.isArray(r?.waitingOnHooks)&&r.waitingOnHooks.length>0||Array.isArray(r?.waitingOnPrMonitors)&&r.waitingOnPrMonitors.length>0||Array.isArray(r?.waitingOnScriptMonitors)&&r.waitingOnScriptMonitors.length>0,waitingForAgentIds:f}})}function ht(t){const e=new Set;for(const i of t)for(const o of i.waitingForAgentIds)e.add(o);const n=i=>h.has(i.bucket)||i.isWaitingForAgents||e.has(i.id);return t.filter((i,o)=>{if(n(i))return!0;for(let c=o+1;c<t.length&&!(t[c].depth<=i.depth);c++)if(n(t[c]))return!0;return!1}).map((i,o,c)=>{if(i.depth===0)return{...i,treePrefix:""};let l=!0;for(let r=o+1;r<c.length&&!(c[r].depth<i.depth);r++)if(c[r].depth===i.depth){l=!1;break}return{...i,treePrefix:(i.depth>=2?"│ ":"")+(l?"└─":"├─")}})}const B=u.createSelector(t=>{const e=t.hud.attentionByWorkspaceId,n=nt.select(t);return S.select(t).map(s=>{const i=String(s.id),o=n.indexOf(i),c=e[i]?.attention??(typeof s.attention=="string"&&P(s.attention)?s.attention:null),l=b(s,t),r=I(s),a=t.tokenUsage?.byWorkspaceId[i]?.totals,d=t.workspaceTasks?.byWorkspaceId[i]?.stats,g=typeof s.statusMessage=="string"&&s.statusMessage.trim().length>0?s.statusMessage:null;return{workspaceId:i,title:s.title,repoRef:s.repositoryName?`${s.repositoryOwner?`${s.repositoryOwner}/`:""}${s.repositoryName}`:s.branch,stateKey:r,attention:c,isUnread:c===J,isWaiting:s.waiting===!0,statusMessage:g,attentionSnippet:pt(t,r,l),prNumber:typeof s.prNumber=="number"?s.prNumber:null,keySlot:o===-1?null:o,tasks:d?{total:d.total,completed:d.completed,inProgress:d.inProgress}:ft,tokens:a?H(a):0,agents:ht(l)}})}),O=4;function mt(t,e,n){const s=t.agentSessions?.byAgentId[n.id];return!s||String(s.workspaceId)!==e||s.pendingDeleteAt||q(F(n,s))!=="topLevel"?!1:!A(t,n.id)}const yt=u.createSelector(t=>{const e={},n=t.hud.attentionByWorkspaceId;for(const s of S.select(t)){const i=String(s.id),o=new Map,c=(f,p)=>{const w=o.get(f)??[];w.includes(p)||w.push(p),o.set(f,w)},r=y(s).filter(f=>mt(t,i,f));for(const f of r){const p=m(t,f);p.bucket==="failed"?c("failed",f.name):p.hasQuestion?c("question",f.name):p.attentionKind==="blocker"?c("blocker",f.name):p.attentionKind==="discussion"&&c("discussion",f.name),p.isRunning&&c("running",f.name)}const a=I(s);a==="failed"&&!o.has("failed")&&o.set("failed",[]),a==="blocked"&&!o.has("blocker")&&o.set("blocker",[]),a==="wait"&&!o.has("question")&&!o.has("blocker")&&!o.has("discussion")&&o.set("needs_input",[]);const d=n[i]?.attention??(typeof s.attention=="string"&&P(s.attention)?s.attention:null);d==="review_required"&&o.set("review",[]),d==="unread"&&o.set("unread",[]),s.activity==="agent_running"&&!o.has("running")&&o.set("running",[]);const g=tt.flatMap(f=>{const p=o.get(f);return p?[{category:f,count:Math.max(1,p.length),agentNames:p}]:[]});if(g.length===0)continue;const k=g.length>O;e[i]={agentCount:r.length,categories:g,visibleCategories:k?g.slice(0,O-1):g,hiddenCategoryCount:k?g.length-(O-1):0}}return e});u.createSelector(t=>{const e=t.hud.attentionByWorkspaceId;let n=0;for(const s of S.select(t)){let i=!1;for(const l of b(s,t))l.topLevel&&!l.isBackground&&!A(t,l.id)&&(l.bucket==="failed"||l.attentionKind!==null||l.hasQuestion)&&(n+=1,i=!0);const o=e[String(s.id)],c=o!==void 0&&N(o.attention);c&&(n+=1),x.has(I(s))&&!i&&!c&&(n+=1)}return n});function It(t,e,n,s){const i=s.slice().sort((r,a)=>a.createdAt-r.createdAt);for(const r of i){const d=t.agentSessions?.byAgentId[r.agentId]?.metadata?.completionReport;if(typeof d=="string"&&d.trim().length>0)return d}const o=t.workspaceNotes?.byWorkspaceId[e]?.notes,c=o?W(o,n):void 0,l=c?.content||c?.contentPreview;return typeof l=="string"&&l.trim().length>0?l:null}const Ft=u.createSelector((t,e)=>{const n=B.select(t).find(a=>a.workspaceId===e);if(!n)return null;const s=W(t.workspace.workspaces,e),i=s?b(s,t):[],o=new Map(i.map(a=>[a.id,a])),c=t.taskAgentAssociations?.byWorkspaceId[e]?.byNoteId??{},l=t.workspaceTasks?.byWorkspaceId[e],r=l?M(l.tasks).filter(a=>a.status!=="cancelled").map(a=>{const d=Object.values(c[a.id]??{});return{id:a.id,title:a.title,status:a.status,agents:d.map(g=>o.get(g.agentId)).filter(g=>!!g),report:a.status==="complete"?It(t,e,a.id,d):null,...a.specLinked!==void 0?{specLinked:a.specLinked}:{},...a.dependsOn?{dependsOn:a.dependsOn}:{},...a.conflictsWith?{conflictsWith:a.conflictsWith}:{},...a.unmetDependsOn?{unmetDependsOn:a.unmetDependsOn}:{}}}):[];return{workspaceId:e,title:n.title,repoRef:n.repoRef,statusMessage:n.statusMessage,keySlot:n.keySlot,stats:n.tasks,tasks:r,activeAgents:i.filter(a=>h.has(a.bucket)),idleAgents:i.filter(a=>!h.has(a.bucket))}}),bt=new Set(["failed","blocker","question","discussion","needs_input","review"]);function wt(t){for(const e of t?.categories??[])switch(e.category){case"failed":return"failure";case"blocker":return"blocker";case"question":return"question";case"review":return"review"}return"none"}const Ut=u.createSelector(t=>{const e=B.select(t),n=yt.select(t),s=new Map(S.select(t).map(o=>[String(o.id),o])),i={action:[],unread:[],active:[]};for(const o of e){const c=s.get(o.workspaceId);if(!c||c.id===et||!ut(t.hud.dockConversationAtByWorkspaceId[o.workspaceId],t.hud.dockRecencyNow))continue;const l=n[o.workspaceId],r=l?.categories??[],a=r.some(f=>bt.has(f.category)),d=o.isUnread,g=r.some(f=>f.category==="running"),k=a?"action":d?"unread":"active";i[k].push({workspace:c,badgeKind:wt(l),priorityGroup:k,isUnread:d,isRunning:g,isWaiting:o.isWaiting})}return[...i.action,...i.unread,...i.active].sort((o,c)=>t.hud.dockConversationAtByWorkspaceId[String(c.workspace.id)]-t.hud.dockConversationAtByWorkspaceId[String(o.workspace.id)]||String(o.workspace.id).localeCompare(String(c.workspace.id)))}),Lt=u.createSelector(t=>t.hud.dockPlacement),Gt=u.createSelector(t=>t.hud.dockPlacementError),Qt=u.createSelector(t=>t.hud.dockFocusRequest),jt=u.createSelector(t=>t.hud.dockDragStartResult),Vt=u.createSelector(t=>t.hud.dockResizeStartResult),Xt=u.createSelector(t=>({pending:t.hud.dockMachineSwitching,error:t.hud.dockMachineSwitchError}));export{jt as a,Qt as b,Xt as c,Lt as d,Gt as e,Vt as f,Ut as g,Ht as h,it as i,qt as j,Kt as k,Rt as l,Et as m,xt as n,Ct as o,_t as p,Dt as q,Nt as r,Mt as s,Ft as t,Bt as u,B as v,Wt as w,Pt as x,yt as y};
1
+ import{N as U,f as L,an as G,ak as j,av as Q,o as V,c as X}from"./C-RJDuZ9.js";import{HR as u,nl as M,H_ as H,bj as T,a0 as $,n7 as _,qR as N,nk as R,rb as z,ka as Y,r9 as B,Ih as v,qy as Z,fK as q,qS as P,a2 as J,bh as tt,g as et}from"./Bo4s1kgI.js";import{y as K,aA as nt,v as st}from"./aLZSbque.js";const ot=["[WORKSPACE EVENTS]","[TASK WAKE]","[AGENT MESSAGE]"];function it(t){const e=t.metadata;if(e&&typeof e=="object"){if(e.type==="question_answers")return!1;if(!U(e))return!0}const n=L(t);return ot.some(s=>n.startsWith(s))}const rt=1440*60*1e3;function at(t){let e=null;for(const n of t){if(it({id:n.id,timestamp:n.createdAt,metadata:n.metadata,contentBlocks:[{type:"text",text:n.preview.trimStart()}]}))continue;const s=Date.parse(n.createdAt);Number.isFinite(s)&&(e===null||s>e)&&(e=s)}return e}const ct=50,lt=20;function E(t,e){return t===null||e!==null&&e>t?e:t}async function Mt(t,e){let n,s=null;for(let i=0;i<lt;i++){const o=await t({limit:ct,nextToken:n});if(!o.ok)return null;const c=o.items;s===null&&c.length>0&&(s=c[c.length-1].id);const l=e?.newestId!=null?c.findIndex(a=>a.id===e.newestId):-1,r=at(l>=0?c.slice(l+1):c);if(l>=0)return{latest:E(r,e?.latest??null),newestId:s};if(r!==null)return{latest:E(r,e?.latest??null),newestId:s};if(typeof o.nextToken!="string")return{latest:null,newestId:s};n=o.nextToken}return{latest:e?.latest??null,newestId:s}}function ut(t,e){return t!=null&&t<=e&&t>e-rt}u.createSelector(t=>t.hud.active);u.createSelector(t=>t.hud.feed);u.createSelector(t=>t.hud.usage);u.createSelector(t=>t.hud.usageError);const _t=u.createSelector(t=>t.hud.rateHistory),Rt=u.createSelector(t=>M(t.workspace.workspaces)),Wt=u.createSelector(t=>{const e=t.hud.usage?.totals;return e?H(e):0}),Bt=u.createSelector(t=>t.hud.burnRatePerMin),Et=u.createSelector(t=>t.hud.burnTrend),Dt=u.createSelector(t=>{const{health:e,stats:n,lastUpdated:s,hostLocality:i}=t.daemonHealth,o=n?.hostname;return{online:e!=="down",uptimeSeconds:typeof n?.uptimeSeconds=="number"?n.uptimeSeconds:null,version:n?.version??null,fetchedAtMs:s?Date.parse(s):null,remoteHostname:i==="remote"&&o?o.split(".",1)[0]??o:null}}),Ct=u.createSelector(t=>t.hud.gridFilter);u.createSelector(t=>t.hud.attentionByWorkspaceId);const Ht=u.createSelector((t,e)=>{const n=t.hud?.questionsByAgentId?.[e];if(!n)return!1;const s=t.agentSessions?.byAgentId[e]?.metadata??{};return!K(s,n.messageId)}),Nt=u.createSelector(t=>t.hud.takeoverRequestWorkspaceId);function dt(t,e){return e[String(t.id)]??t.displayStatus}const S=u.createSelector(t=>{const e=t.hud.displayStatusByWorkspaceId;return M(t.workspace.workspaces).filter(n=>n.status!==T.Archived&&n.status!==T.Retired&&n.status!==T.Deleted).map(n=>{const s=dt(n,e);return s&&s!==n.displayStatus?{...n,displayStatus:s}:n})});function y(t){const e=t.agentSummary;return!e||!Array.isArray(e.agents)?[]:e.agents.filter(n=>!!n&&typeof n=="object"&&typeof n.id=="string"&&n.status!=="deleted"&&!st(n.id))}const qt=u.createSelector(t=>{const e=Object.fromEntries($.map(n=>[n,0]));for(const n of S.select(t))for(const s of y(n))e[m(t,s).bucket]+=1;return e}),Pt=u.createSelector(t=>{const e={idle:0,unread:0,progress:0,attention:0,waiting:0,prOpen:0,prMerged:0,failed:0,completed:0,total:0};for(const n of W.select(t))switch(e.total+=1,n.isUnread&&(e.unread+=1),n.isWaiting&&(e.waiting+=1),n.stateKey){case"wait":case"blocked":e.attention+=1;break;case"failed":e.failed+=1;break;case"in_progress":e.progress+=1;break;case"complete":e.completed+=1;break;case"pr_open":case"pr_ready":case"pr_queued":e.prOpen+=1;break;case"pr_merged":e.prMerged+=1;break;default:e.idle+=1}return e}),gt=u.createSelector(t=>{const e={};for(const n of S.select(t))for(const s of y(n))typeof s.name=="string"&&s.name.length>0&&(e[s.id]=s.name);return e});function D(t){if(!t.sinceTs)return 0;const e=Date.parse(t.sinceTs);return Number.isFinite(e)?e:0}const Kt=u.createSelector(t=>{const e=t.hud.attentionByWorkspaceId,n=t.hud.questionsByAgentId,s=[];for(const i of S.select(t)){const o=String(i.id);let c=!1;for(const r of b(i,t)){const{bucket:a,attentionKind:d,hasQuestion:g}=r;if(a!=="needs-attention"&&a!=="failed"||!r.topLevel||r.isBackground||A(t,r.id))continue;const k=g?n[r.id]:void 0,f=d?_(t.agentSessions?.byAgentId[r.id])?.reason:void 0,p=k?"question":d??void 0;s.push({workspaceId:o,workspaceTitle:i.title,kind:a==="needs-attention"?"agent_waiting":"agent_failed",...a==="needs-attention"&&p?{signal:p}:{},agentName:r.name,message:k?.question??f??null,sinceTs:r.lastActivityTs}),c=!0}const l=e[o];l&&N(l.attention)&&(s.push({workspaceId:o,workspaceTitle:i.title,kind:"workspace_attention",attention:l.attention,message:null,sinceTs:l.raisedAtTs}),c=!0),x.has(I(i))&&!c&&s.push({workspaceId:o,workspaceTitle:i.title,kind:"workspace_attention",message:null,sinceTs:null})}return s.sort((i,o)=>D(o)-D(i))}),xt=u.createSelector(t=>{const e=gt.select(t);return t.hud.feed.map(n=>({...n,workspaceTitle:R(t.workspace.workspaces,n.source)?.title??null,resolvedAgentName:n.agentName??(n.agentId?e[n.agentId]??null:null)}))}),ft={total:0,completed:0,inProgress:0};function I(t){const e=z(t.displayStatus)?t.displayStatus:"not_started";return Y(e)??"not_started"}const x=new Set(["wait","blocked","failed"]);function pt(t,e,n){if(e==="failed"){const i=n.find(c=>c.bucket==="failed"&&!A(t,c.id)),o=i?t.agentSessions?.byAgentId[i.id]?.stopReason:null;return{kind:"failed",text:typeof o=="string"&&o.length>0?o:""}}if(e!=="wait"&&e!=="blocked")return null;const s=n.filter(i=>i.topLevel&&!i.isBackground&&!A(t,i.id));for(const i of s){if(!i.hasQuestion)continue;const o=t.hud.questionsByAgentId[i.id];if(o?.question)return{kind:"question",text:o.question}}for(const i of["blocker","discussion"])for(const o of s){if(o.attentionKind!==i)continue;const c=t.agentSessions?.byAgentId[o.id],l=_(c)?.reason;if(l)return{kind:i,text:l}}return{kind:"pending",text:""}}const h=new Set(["running","needs-attention","failed"]);function C(t){const e=typeof t.lastActivity=="string"?Date.parse(t.lastActivity):NaN;return Number.isFinite(e)?e:-1/0}function kt(t){const e=n=>{const s=t.get(n.id)?.bucket;return s!==void 0&&h.has(s)?0:1};return(n,s)=>{const i=n.specialist==="spec-writer",o=s.specialist==="spec-writer";if(i!==o)return i?-1:1;const c=e(n)-e(s);if(c!==0)return c;const l=C(n),r=C(s);return l!==r?r-l:n.id<s.id?-1:n.id>s.id?1:0}}function St(t,e){const n=new Set(t.map(r=>r.id)),s=new Map,i=[];for(const r of t){const a=typeof r.parentAgentId=="string"&&r.parentAgentId!==r.id&&n.has(r.parentAgentId)?r.parentAgentId:null;if(a){const d=s.get(a)??[];d.push(r),s.set(a,d)}else i.push(r)}i.sort(e);for(const r of s.values())r.sort(e);const o=[],c=new Set,l=(r,a,d)=>{if(!c.has(r.id)){c.add(r.id),o.push({info:r,depth:a,parentAgentId:d});for(const g of s.get(r.id)??[])l(g,a+1,r.id)}};for(const r of i)l(r,0,null);for(const r of t)l(r,0,null);return o}function m(t,e){const n=t.agentSessions?.byAgentId[e.id],s=n?.metadata??{},i=n?_(n)?.kind??null:null,o=n?G.select(t,e.id)||typeof n.status=="string"&&B(n.status):B(e.status),c=n?v(typeof n.status=="string"?n.status:e.status):null,l=!!n&&c!=="failed"&&c!=="done"&&(n.isWaitingForOtherAgents===!0||Array.isArray(n.waitingForAgentIds)&&n.waitingForAgentIds.length>0||Array.isArray(n.waitingOnHooks)&&n.waitingOnHooks.length>0||Array.isArray(n.waitingOnPrMonitors)&&n.waitingOnPrMonitors.length>0||Array.isArray(n.waitingOnScriptMonitors)&&n.waitingOnScriptMonitors.length>0),r=!!n&&(n.turnInFlight===!0||n.liveTurnOpen===!0);let a;n?l&&!r&&n.isStreaming!==!0&&n.isProcessing!==!0?a="idle":j.select(t,e.id)?a="running":o?a="idle":a=v(typeof n.status=="string"?n.status:e.status):a=e.isResponding===!0||e.isStreaming===!0?"running":v(e.status);const d=t.hud.questionsByAgentId[e.id],g=a!=="failed"&&!!d&&!K(s,d.messageId);return{bucket:a==="failed"?"failed":i!==null||g?"needs-attention":a,attentionKind:i,hasQuestion:g,isRunning:a==="running"}}function F(t,e){const n=i=>typeof i=="string"&&i!==t.id?i:null,s=i=>({isBackground:i?.isBackground,createdByAgentId:n(i?.createdByAgentId)});return{parentAgentId:n(t.parentAgentId)??n(e?.parentAgentId),isBackground:t.isBackground??e?.isBackground,metadata:s(e?.metadata),agentMetadata:s(e?.agentMetadata)}}function A(t,e){return t.agentSessions?.byAgentId[e]?.notificationsMuted===!0}function At(t){if(!t)return null;switch(t.kind){case"attention":return t.attention.reason??null;case"live-tool":case"last-tool":{const e=X(t.toolUse.name,t.toolUse.input||{});return e.hidden?null:[e.verb,e.subject,e.path].filter(Boolean).join(" ").trim()||null}default:{const e=t.text||"";return e?e.includes(`
2
+ `)?V(e)||null:e:null}}}function b(t,e){const n=y(t),s=new Map(n.map(o=>[o.id,m(e,o)]));return St(n,kt(s)).map(({info:o,depth:c,parentAgentId:l})=>{const r=e.agentSessions?.byAgentId[o.id],a=F(o,r),{bucket:d,attentionKind:g,hasQuestion:k}=s.get(o.id)??m(e,o),f=Array.isArray(r?.waitingForAgentIds)?r.waitingForAgentIds.filter(p=>typeof p=="string"):[];return{id:o.id,name:o.name,bucket:d,lastActivityTs:o.lastActivity??null,line:At(Q.select(e,o.id)),parentAgentId:l,depth:c,treePrefix:"",topLevel:q(a)==="topLevel",isBackground:Z(a),attentionKind:g,hasQuestion:k,isWaitingForAgents:r?.isWaitingForOtherAgents===!0||f.length>0||Array.isArray(r?.waitingOnHooks)&&r.waitingOnHooks.length>0||Array.isArray(r?.waitingOnPrMonitors)&&r.waitingOnPrMonitors.length>0||Array.isArray(r?.waitingOnScriptMonitors)&&r.waitingOnScriptMonitors.length>0,waitingForAgentIds:f}})}function ht(t){const e=new Set;for(const i of t)for(const o of i.waitingForAgentIds)e.add(o);const n=i=>h.has(i.bucket)||i.isWaitingForAgents||e.has(i.id);return t.filter((i,o)=>{if(n(i))return!0;for(let c=o+1;c<t.length&&!(t[c].depth<=i.depth);c++)if(n(t[c]))return!0;return!1}).map((i,o,c)=>{if(i.depth===0)return{...i,treePrefix:""};let l=!0;for(let r=o+1;r<c.length&&!(c[r].depth<i.depth);r++)if(c[r].depth===i.depth){l=!1;break}return{...i,treePrefix:(i.depth>=2?"│ ":"")+(l?"└─":"├─")}})}const W=u.createSelector(t=>{const e=t.hud.attentionByWorkspaceId,n=nt.select(t);return S.select(t).map(s=>{const i=String(s.id),o=n.indexOf(i),c=e[i]?.attention??(typeof s.attention=="string"&&P(s.attention)?s.attention:null),l=b(s,t),r=I(s),a=t.tokenUsage?.byWorkspaceId[i]?.totals,d=t.workspaceTasks?.byWorkspaceId[i]?.stats,g=typeof s.statusMessage=="string"&&s.statusMessage.trim().length>0?s.statusMessage:null;return{workspaceId:i,title:s.title,repoRef:s.repositoryName?`${s.repositoryOwner?`${s.repositoryOwner}/`:""}${s.repositoryName}`:s.branch,stateKey:r,attention:c,isUnread:c===J,isWaiting:s.waiting===!0,statusMessage:g,attentionSnippet:pt(t,r,l),prNumber:typeof s.prNumber=="number"?s.prNumber:null,keySlot:o===-1?null:o,tasks:d?{total:d.total,completed:d.completed,inProgress:d.inProgress}:ft,tokens:a?H(a):0,agents:ht(l)}})}),O=4;function mt(t,e,n){const s=t.agentSessions?.byAgentId[n.id];return!s||String(s.workspaceId)!==e||s.pendingDeleteAt||q(F(n,s))!=="topLevel"?!1:!A(t,n.id)}const yt=u.createSelector(t=>{const e={},n=t.hud.attentionByWorkspaceId;for(const s of S.select(t)){const i=String(s.id),o=new Map,c=(f,p)=>{const w=o.get(f)??[];w.includes(p)||w.push(p),o.set(f,w)},r=y(s).filter(f=>mt(t,i,f));for(const f of r){const p=m(t,f);p.bucket==="failed"?c("failed",f.name):p.hasQuestion?c("question",f.name):p.attentionKind==="blocker"?c("blocker",f.name):p.attentionKind==="discussion"&&c("discussion",f.name),p.isRunning&&c("running",f.name)}const a=I(s);a==="failed"&&!o.has("failed")&&o.set("failed",[]),a==="blocked"&&!o.has("blocker")&&o.set("blocker",[]),a==="wait"&&!o.has("question")&&!o.has("blocker")&&!o.has("discussion")&&o.set("needs_input",[]);const d=n[i]?.attention??(typeof s.attention=="string"&&P(s.attention)?s.attention:null);d==="review_required"&&o.set("review",[]),d==="unread"&&o.set("unread",[]),s.activity==="agent_running"&&!o.has("running")&&o.set("running",[]);const g=tt.flatMap(f=>{const p=o.get(f);return p?[{category:f,count:Math.max(1,p.length),agentNames:p}]:[]});if(g.length===0)continue;const k=g.length>O;e[i]={agentCount:r.length,categories:g,visibleCategories:k?g.slice(0,O-1):g,hiddenCategoryCount:k?g.length-(O-1):0}}return e});u.createSelector(t=>{const e=t.hud.attentionByWorkspaceId;let n=0;for(const s of S.select(t)){let i=!1;for(const l of b(s,t))l.topLevel&&!l.isBackground&&!A(t,l.id)&&(l.bucket==="failed"||l.attentionKind!==null||l.hasQuestion)&&(n+=1,i=!0);const o=e[String(s.id)],c=o!==void 0&&N(o.attention);c&&(n+=1),x.has(I(s))&&!i&&!c&&(n+=1)}return n});function It(t,e,n,s){const i=s.slice().sort((r,a)=>a.createdAt-r.createdAt);for(const r of i){const d=t.agentSessions?.byAgentId[r.agentId]?.metadata?.completionReport;if(typeof d=="string"&&d.trim().length>0)return d}const o=t.workspaceNotes?.byWorkspaceId[e]?.notes,c=o?R(o,n):void 0,l=c?.content||c?.contentPreview;return typeof l=="string"&&l.trim().length>0?l:null}const Ft=u.createSelector((t,e)=>{const n=W.select(t).find(a=>a.workspaceId===e);if(!n)return null;const s=R(t.workspace.workspaces,e),i=s?b(s,t):[],o=new Map(i.map(a=>[a.id,a])),c=t.taskAgentAssociations?.byWorkspaceId[e]?.byNoteId??{},l=t.workspaceTasks?.byWorkspaceId[e],r=l?M(l.tasks).filter(a=>a.status!=="cancelled").map(a=>{const d=Object.values(c[a.id]??{});return{id:a.id,title:a.title,status:a.status,agents:d.map(g=>o.get(g.agentId)).filter(g=>!!g),report:a.status==="complete"?It(t,e,a.id,d):null,...a.specLinked!==void 0?{specLinked:a.specLinked}:{},...a.dependsOn?{dependsOn:a.dependsOn}:{},...a.conflictsWith?{conflictsWith:a.conflictsWith}:{},...a.unmetDependsOn?{unmetDependsOn:a.unmetDependsOn}:{}}}):[];return{workspaceId:e,title:n.title,repoRef:n.repoRef,statusMessage:n.statusMessage,keySlot:n.keySlot,stats:n.tasks,tasks:r,activeAgents:i.filter(a=>h.has(a.bucket)),idleAgents:i.filter(a=>!h.has(a.bucket))}}),bt=new Set(["failed","blocker","question","discussion","needs_input","review"]);function wt(t){for(const e of t?.categories??[])switch(e.category){case"failed":return"failure";case"blocker":return"blocker";case"question":return"question";case"review":return"review"}return"none"}const Ut=u.createSelector(t=>{const e=W.select(t),n=yt.select(t),s=new Map(S.select(t).map(o=>[String(o.id),o])),i={action:[],unread:[],active:[]};for(const o of e){const c=s.get(o.workspaceId);if(!c||c.id===et||!ut(t.hud.dockConversationAtByWorkspaceId[o.workspaceId],t.hud.dockRecencyNow))continue;const l=n[o.workspaceId],r=l?.categories??[],a=r.some(f=>bt.has(f.category)),d=o.isUnread,g=r.some(f=>f.category==="running"),k=a?"action":d?"unread":"active";i[k].push({workspace:c,badgeKind:wt(l),priorityGroup:k,isUnread:d,isRunning:g,isWaiting:o.isWaiting})}return[...i.action,...i.unread,...i.active].sort((o,c)=>t.hud.dockConversationAtByWorkspaceId[String(c.workspace.id)]-t.hud.dockConversationAtByWorkspaceId[String(o.workspace.id)]||String(o.workspace.id).localeCompare(String(c.workspace.id)))}),Lt=u.createSelector(t=>t.hud.dockPlacement),Gt=u.createSelector(t=>t.hud.dockPlacementError),jt=u.createSelector(t=>t.hud.dockFocusRequest),Qt=u.createSelector(t=>t.hud.dockDragStartResult),Vt=u.createSelector(t=>t.hud.dockResizeStartResult),Xt=u.createSelector(t=>({pending:t.hud.dockMachineSwitching,error:t.hud.dockMachineSwitchError}));export{Qt as a,jt as b,Xt as c,Lt as d,Gt as e,Vt as f,Ut as g,Ht as h,it as i,qt as j,Kt as k,Bt as l,Et as m,xt as n,Ct as o,_t as p,Dt as q,Nt as r,Mt as s,Ft as t,Wt as u,W as v,Rt as w,Pt as x,yt as y};
@@ -1,4 +1,4 @@
1
- import{c as t,s as r}from"./CW_MTCOu.js";import{b as a}from"./DWcUEP_3.js";var s=a(e=>`${r(e)}
1
+ import{c as t,s as r}from"./DnfX8iZ_.js";import{b as a}from"./DwsRDnkS.js";var s=a(e=>`${r(e)}
2
2
  .swimlane.cluster:not([data-color-id]) rect {
3
3
  stroke: ${e.clusterBorder} !important;
4
4
  }
@@ -1,4 +1,4 @@
1
- import{I as le}from"./CuTNRxpo.js";import{p as he}from"./CIH3mb7Y.js";import{Y as $e,b0 as fe,aZ as ge,U as ue,V as ye,a_ as xe,b as h,W as J,ay as w,aW as me,X as P,bh as pe,b4 as be,r as we,z as B,q as ke,O as ve,aM as Ce}from"./DWcUEP_3.js";import{p as Ee}from"./QeTaV4Op.js";var m={NORMAL:0,REVERSE:1,HIGHLIGHT:2,MERGE:3,CHERRY_PICK:4},Be=ve.gitGraph,S=h(()=>ke({...Be,...J().gitGraph}),"getConfig"),d=new le(()=>{const e=S(),r=e.mainBranchName,t=e.mainBranchOrder;return{mainBranchName:r,commits:new Map,head:null,branchConfig:new Map([[r,{name:r,order:t}]]),branches:new Map([[r,null]]),currBranch:r,direction:"LR",seq:0,options:{}}});function Y(){return Ce({length:7})}h(Y,"getID");function te(e,r){const t=Object.create(null);return e.reduce((s,o)=>{const i=r(o);return t[i]||(t[i]=!0,s.push(o)),s},[])}h(te,"uniqBy");var Te=h(function(e){d.records.direction=e},"setDirection"),Le=h(function(e){w.debug("options str",e),e=e?.trim(),e=e||"{}";try{d.records.options=JSON.parse(e)}catch(r){w.error("error while parsing gitGraph options",r.message)}},"setOptions"),Me=h(function(){return d.records.options},"getOptions"),Re=h(function(e){let r=e.msg,t=e.id;const s=e.type;let o=e.tags;w.info("commit",r,t,s,o),w.debug("Entering commit:",r,t,s,o);const i=S();t=B.sanitizeText(t,i),r=B.sanitizeText(r,i),o=o?.map(a=>B.sanitizeText(a,i));const n={id:t||d.records.seq+"-"+Y(),message:r,seq:d.records.seq++,type:s??m.NORMAL,tags:o??[],parents:d.records.head==null?[]:[d.records.head.id],branch:d.records.currBranch};d.records.head=n,w.info("main branch",i.mainBranchName),d.records.commits.has(n.id)&&w.warn(`Commit ID ${n.id} already exists`),d.records.commits.set(n.id,n),d.records.branches.set(d.records.currBranch,n.id),w.debug("in pushCommit "+n.id)},"commit"),Ie=h(function(e){let r=e.name;const t=e.order;if(r=B.sanitizeText(r,S()),d.records.branches.has(r))throw new Error(`Trying to create an existing branch. (Help: Either use a new name if you want create a new branch or try using "checkout ${r}")`);d.records.branches.set(r,d.records.head!=null?d.records.head.id:null),d.records.branchConfig.set(r,{name:r,order:t}),ae(r),w.debug("in createBranch")},"branch"),Oe=h(e=>{let r=e.branch,t=e.id;const s=e.type,o=e.tags,i=S();r=B.sanitizeText(r,i),t&&(t=B.sanitizeText(t,i));const n=d.records.branches.get(d.records.currBranch),a=d.records.branches.get(r),l=n?d.records.commits.get(n):void 0,f=a?d.records.commits.get(a):void 0;if(l&&f&&l.branch===r)throw new Error(`Cannot merge branch '${r}' into itself.`);if(d.records.currBranch===r){const c=new Error('Incorrect usage of "merge". Cannot merge a branch to itself');throw c.hash={text:`merge ${r}`,token:`merge ${r}`,expected:["branch abc"]},c}if(l===void 0||!l){const c=new Error(`Incorrect usage of "merge". Current branch (${d.records.currBranch})has no commits`);throw c.hash={text:`merge ${r}`,token:`merge ${r}`,expected:["commit"]},c}if(!d.records.branches.has(r)){const c=new Error('Incorrect usage of "merge". Branch to be merged ('+r+") does not exist");throw c.hash={text:`merge ${r}`,token:`merge ${r}`,expected:[`branch ${r}`]},c}if(f===void 0||!f){const c=new Error('Incorrect usage of "merge". Branch to be merged ('+r+") has no commits");throw c.hash={text:`merge ${r}`,token:`merge ${r}`,expected:['"commit"']},c}if(l===f){const c=new Error('Incorrect usage of "merge". Both branches have same head');throw c.hash={text:`merge ${r}`,token:`merge ${r}`,expected:["branch abc"]},c}if(t&&d.records.commits.has(t)){const c=new Error('Incorrect usage of "merge". Commit with id:'+t+" already exists, use different custom id");throw c.hash={text:`merge ${r} ${t} ${s} ${o?.join(" ")}`,token:`merge ${r} ${t} ${s} ${o?.join(" ")}`,expected:[`merge ${r} ${t}_UNIQUE ${s} ${o?.join(" ")}`]},c}const g=a||"",$={id:t||`${d.records.seq}-${Y()}`,message:`merged branch ${r} into ${d.records.currBranch}`,seq:d.records.seq++,parents:d.records.head==null?[]:[d.records.head.id,g],branch:d.records.currBranch,type:m.MERGE,customType:s,customId:!!t,tags:o??[]};d.records.head=$,d.records.commits.set($.id,$),d.records.branches.set(d.records.currBranch,$.id),w.debug(d.records.branches),w.debug("in mergeBranch")},"merge"),_e=h(function(e){let r=e.id,t=e.targetId,s=e.tags,o=e.parent;w.debug("Entering cherryPick:",r,t,s);const i=S();if(r=B.sanitizeText(r,i),t=B.sanitizeText(t,i),s=s?.map(l=>B.sanitizeText(l,i)),o=B.sanitizeText(o,i),!r||!d.records.commits.has(r)){const l=new Error('Incorrect usage of "cherryPick". Source commit id should exist and provided');throw l.hash={text:`cherryPick ${r} ${t}`,token:`cherryPick ${r} ${t}`,expected:["cherry-pick abc"]},l}const n=d.records.commits.get(r);if(n===void 0||!n)throw new Error('Incorrect usage of "cherryPick". Source commit id should exist and provided');if(o&&!(Array.isArray(n.parents)&&n.parents.includes(o)))throw new Error("Invalid operation: The specified parent commit is not an immediate parent of the cherry-picked commit.");const a=n.branch;if(n.type===m.MERGE&&!o)throw new Error("Incorrect usage of cherry-pick: If the source commit is a merge commit, an immediate parent commit must be specified.");if(!t||!d.records.commits.has(t)){if(a===d.records.currBranch){const $=new Error('Incorrect usage of "cherryPick". Source commit is already on current branch');throw $.hash={text:`cherryPick ${r} ${t}`,token:`cherryPick ${r} ${t}`,expected:["cherry-pick abc"]},$}const l=d.records.branches.get(d.records.currBranch);if(l===void 0||!l){const $=new Error(`Incorrect usage of "cherry-pick". Current branch (${d.records.currBranch})has no commits`);throw $.hash={text:`cherryPick ${r} ${t}`,token:`cherryPick ${r} ${t}`,expected:["cherry-pick abc"]},$}const f=d.records.commits.get(l);if(f===void 0||!f){const $=new Error(`Incorrect usage of "cherry-pick". Current branch (${d.records.currBranch})has no commits`);throw $.hash={text:`cherryPick ${r} ${t}`,token:`cherryPick ${r} ${t}`,expected:["cherry-pick abc"]},$}const g={id:d.records.seq+"-"+Y(),message:`cherry-picked ${n?.message} into ${d.records.currBranch}`,seq:d.records.seq++,parents:d.records.head==null?[]:[d.records.head.id,n.id],branch:d.records.currBranch,type:m.CHERRY_PICK,tags:s?s.filter(Boolean):[`cherry-pick:${n.id}${n.type===m.MERGE?`|parent:${o}`:""}`]};d.records.head=g,d.records.commits.set(g.id,g),d.records.branches.set(d.records.currBranch,g.id),w.debug(d.records.branches),w.debug("in cherryPick")}},"cherryPick"),ae=h(function(e){if(e=B.sanitizeText(e,S()),d.records.branches.has(e)){d.records.currBranch=e;const r=d.records.branches.get(d.records.currBranch);r===void 0||!r?d.records.head=null:d.records.head=d.records.commits.get(r)??null}else{const r=new Error(`Trying to checkout branch which is not yet created. (Help try using "branch ${e}")`);throw r.hash={text:`checkout ${e}`,token:`checkout ${e}`,expected:[`branch ${e}`]},r}},"checkout");function V(e,r,t){const s=e.indexOf(r);s===-1?e.push(t):e.splice(s,1,t)}h(V,"upsert");function Q(e){const r=e.reduce((o,i)=>o.seq>i.seq?o:i,e[0]);let t="";e.forEach(function(o){o===r?t+=" *":t+=" |"});const s=[t,r.id,r.seq];for(const o in d.records.branches)d.records.branches.get(o)===r.id&&s.push(o);if(w.debug(s.join(" ")),r.parents&&r.parents.length==2&&r.parents[0]&&r.parents[1]){const o=d.records.commits.get(r.parents[0]);V(e,r,o),r.parents[1]&&e.push(d.records.commits.get(r.parents[1]))}else{if(r.parents.length==0)return;if(r.parents[0]){const o=d.records.commits.get(r.parents[0]);V(e,r,o)}}e=te(e,o=>o.id),Q(e)}h(Q,"prettyPrintCommitHistory");var Ge=h(function(){w.debug(d.records.commits);const e=ne()[0];Q([e])},"prettyPrint"),He=h(function(){d.reset(),we()},"clear"),Se=h(function(){return[...d.records.branchConfig.values()].map((r,t)=>r.order!==null&&r.order!==void 0?r:{...r,order:parseFloat(`0.${t}`)}).sort((r,t)=>(r.order??0)-(t.order??0)).map(({name:r})=>({name:r}))},"getBranchesAsObjArray"),Ae=h(function(){return d.records.branches},"getBranches"),We=h(function(){return d.records.commits},"getCommits"),ne=h(function(){const e=[...d.records.commits.values()];return e.forEach(function(r){w.debug(r.id)}),e.sort((r,t)=>r.seq-t.seq),e},"getCommitsArray"),De=h(function(){return d.records.currBranch},"getCurrentBranch"),qe=h(function(){return d.records.direction},"getDirection"),Pe=h(function(){return d.records.head},"getHead"),se={commitType:m,getConfig:S,setDirection:Te,setOptions:Le,getOptions:Me,commit:Re,branch:Ie,merge:Oe,cherryPick:_e,checkout:ae,prettyPrint:Ge,clear:He,getBranchesAsObjArray:Se,getBranches:Ae,getCommits:We,getCommitsArray:ne,getCurrentBranch:De,getDirection:qe,getHead:Pe,setAccTitle:xe,getAccTitle:ye,getAccDescription:ue,setAccDescription:ge,setDiagramTitle:fe,getDiagramTitle:$e},Ne=h((e,r)=>{he(e,r),e.dir&&r.setDirection(e.dir);for(const t of e.statements)Fe(t,r)},"populate"),Fe=h((e,r)=>{const s={Commit:h(o=>r.commit(ze(o)),"Commit"),Branch:h(o=>r.branch(Ye(o)),"Branch"),Merge:h(o=>r.merge(je(o)),"Merge"),Checkout:h(o=>r.checkout(Ue(o)),"Checkout"),CherryPicking:h(o=>r.cherryPick(Ke(o)),"CherryPicking")}[e.$type];s?s(e):w.error(`Unknown statement type: ${e.$type}`)},"parseStatement"),ze=h(e=>({id:e.id,msg:e.message??"",type:e.type!==void 0?m[e.type]:m.NORMAL,tags:e.tags??void 0}),"parseCommit"),Ye=h(e=>({name:e.name,order:e.order??0}),"parseBranch"),je=h(e=>({branch:e.branch,id:e.id??"",type:e.type!==void 0?m[e.type]:void 0,tags:e.tags??void 0}),"parseMerge"),Ue=h(e=>e.branch,"parseCheckout"),Ke=h(e=>({id:e.id,targetId:"",tags:e.tags?.length===0?void 0:e.tags,parent:e.parent}),"parseCherryPicking"),Ve={parse:h(async e=>{const r=await Ee("gitGraph",e);w.debug(r),Ne(r,se)},"parse")},O=10,_=40,L=4,R=2,G=8,j=new Set(["redux","redux-dark","redux-color","redux-dark-color"]),X=12,Z=new Set(["redux-color","redux-dark-color"]),Xe=new Set(["dark","redux-dark","redux-dark-color","neo-dark"]),H=h((e,r,t=!1)=>t&&e>0?(e-1)%(r-1)+1:e%r,"calcColorIndex"),C=new Map,E=new Map,F=30,D=new Map,z=[],I=0,y="LR",Je=h(()=>{C.clear(),E.clear(),D.clear(),I=0,z=[],y="LR"},"clear"),oe=h(e=>{const r=document.createElementNS("http://www.w3.org/2000/svg","text");return(typeof e=="string"?e.split(/\\n|\n|<br\s*\/?>/gi):e).forEach(s=>{const o=document.createElementNS("http://www.w3.org/2000/svg","tspan");o.setAttributeNS("http://www.w3.org/XML/1998/namespace","xml:space","preserve"),o.setAttribute("dy","1em"),o.setAttribute("x","0"),o.setAttribute("class","row"),o.textContent=s.trim(),r.appendChild(o)}),r},"drawText"),ce=h(e=>{let r,t,s;return y==="BT"?(t=h((o,i)=>o<=i,"comparisonFunc"),s=1/0):(t=h((o,i)=>o>=i,"comparisonFunc"),s=0),e.forEach(o=>{const i=y==="TB"||y=="BT"?E.get(o)?.y:E.get(o)?.x;i!==void 0&&t(i,s)&&(r=o,s=i)}),r},"findClosestParent"),Qe=h(e=>{let r="",t=1/0;return e.forEach(s=>{const o=E.get(s).y;o<=t&&(r=s,t=o)}),r||void 0},"findClosestParentBT"),Ze=h((e,r,t)=>{let s=t,o=t;const i=[];e.forEach(n=>{const a=r.get(n);if(!a)throw new Error(`Commit not found for key ${n}`);a.parents.length?(s=rr(a),o=Math.max(s,o)):i.push(a),tr(a,s)}),s=o,i.forEach(n=>{ar(n,s,t)}),e.forEach(n=>{const a=r.get(n);if(a?.parents.length){const l=Qe(a.parents);s=E.get(l).y-_,s<=o&&(o=s);const f=C.get(a.branch).pos,g=s-O;E.set(a.id,{x:f,y:g})}})},"setParallelBTPos"),er=h(e=>{const r=ce(e.parents.filter(s=>s!==null));if(!r)throw new Error(`Closest parent not found for commit ${e.id}`);const t=E.get(r)?.y;if(t===void 0)throw new Error(`Closest parent position not found for commit ${e.id}`);return t},"findClosestParentPos"),rr=h(e=>er(e)+_,"calculateCommitPosition"),tr=h((e,r)=>{const t=C.get(e.branch);if(!t)throw new Error(`Branch not found for commit ${e.id}`);const s=t.pos,o=r+O;return E.set(e.id,{x:s,y:o}),{x:s,y:o}},"setCommitPosition"),ar=h((e,r,t)=>{const s=C.get(e.branch);if(!s)throw new Error(`Branch not found for commit ${e.id}`);const o=r+t,i=s.pos;E.set(e.id,{x:i,y:o})},"setRootPosition"),nr=h((e,r,t,s,o,i)=>{const{theme:n}=P(),a=j.has(n??""),l=Z.has(n??""),f=Xe.has(n??"");if(i===m.HIGHLIGHT)e.append("rect").attr("x",t.x-10+(a?3:0)).attr("y",t.y-10+(a?3:0)).attr("width",a?14:20).attr("height",a?14:20).attr("class",`commit ${r.id} commit-highlight${H(o,G,l)} ${s}-outer`),e.append("rect").attr("x",t.x-6+(a?2:0)).attr("y",t.y-6+(a?2:0)).attr("width",a?8:12).attr("height",a?8:12).attr("class",`commit ${r.id} commit${H(o,G,l)} ${s}-inner`);else if(i===m.CHERRY_PICK)e.append("circle").attr("cx",t.x).attr("cy",t.y).attr("r",a?7:10).attr("class",`commit ${r.id} ${s}`),e.append("circle").attr("cx",t.x-3).attr("cy",t.y+2).attr("r",a?2.5:2.75).attr("fill",f?"#000000":"#fff").attr("class",`commit ${r.id} ${s}`),e.append("circle").attr("cx",t.x+3).attr("cy",t.y+2).attr("r",a?2.5:2.75).attr("fill",f?"#000000":"#fff").attr("class",`commit ${r.id} ${s}`),e.append("line").attr("x1",t.x+3).attr("y1",t.y+1).attr("x2",t.x).attr("y2",t.y-5).attr("stroke",f?"#000000":"#fff").attr("class",`commit ${r.id} ${s}`),e.append("line").attr("x1",t.x-3).attr("y1",t.y+1).attr("x2",t.x).attr("y2",t.y-5).attr("stroke",f?"#000000":"#fff").attr("class",`commit ${r.id} ${s}`);else{const g=e.append("circle");if(g.attr("cx",t.x),g.attr("cy",t.y),g.attr("r",a?7:10),g.attr("class",`commit ${r.id} commit${H(o,G,l)}`),i===m.MERGE){const $=e.append("circle");$.attr("cx",t.x),$.attr("cy",t.y),$.attr("r",a?5:6),$.attr("class",`commit ${s} ${r.id} commit${H(o,G,l)}`)}if(i===m.REVERSE){const $=e.append("path"),c=a?4:5;$.attr("d",`M ${t.x-c},${t.y-c}L${t.x+c},${t.y+c}M${t.x-c},${t.y+c}L${t.x+c},${t.y-c}`).attr("class",`commit ${s} ${r.id} commit${H(o,G,l)}`)}}},"drawCommitBullet"),sr=h((e,r,t,s,o)=>{if(r.type!==m.CHERRY_PICK&&(r.customId&&r.type===m.MERGE||r.type!==m.MERGE)&&o.showCommitLabel){const i=e.append("g"),n=i.insert("rect").attr("class","commit-label-bkg"),a=i.append("text").attr("x",s).attr("y",t.y+25).attr("class","commit-label").text(r.id),l=a.node()?.getBBox();if(l&&(n.attr("x",t.posWithOffset-l.width/2-R).attr("y",t.y+13.5).attr("width",l.width+2*R).attr("height",l.height+2*R),y==="TB"||y==="BT"?(n.attr("x",t.x-(l.width+4*L+5)).attr("y",t.y-12),a.attr("x",t.x-(l.width+4*L)).attr("y",t.y+l.height-12)):a.attr("x",t.posWithOffset-l.width/2),o.rotateCommitLabel))if(y==="TB"||y==="BT")a.attr("transform","rotate(-45, "+t.x+", "+t.y+")"),n.attr("transform","rotate(-45, "+t.x+", "+t.y+")");else{const f=-7.5-(l.width+10)/25*9.5,g=10+l.width/25*8.5;i.attr("transform","translate("+f+", "+g+") rotate(-45, "+s+", "+t.y+")")}}},"drawCommitLabel"),or=h((e,r,t,s)=>{if(r.tags.length>0){let o=0,i=0,n=0;const a=[];for(const l of r.tags.reverse()){const f=e.insert("polygon"),g=e.append("circle"),$=e.append("text").attr("y",t.y-16-o).attr("class","tag-label").text(l),c=$.node()?.getBBox();if(!c)throw new Error("Tag bbox not found");i=Math.max(i,c.width),n=Math.max(n,c.height),$.attr("x",t.posWithOffset-c.width/2),a.push({tag:$,hole:g,rect:f,yOffset:o}),o+=20}for(const{tag:l,hole:f,rect:g,yOffset:$}of a){const c=n/2,x=t.y-19.2-$;if(g.attr("class","tag-label-bkg").attr("points",`
1
+ import{I as le}from"./CAgY0H5Q.js";import{p as he}from"./BkR5Qiti.js";import{Y as $e,b0 as fe,aZ as ge,U as ue,V as ye,a_ as xe,b as h,W as J,ay as w,aW as me,X as P,bh as pe,b4 as be,r as we,z as B,q as ke,O as ve,aM as Ce}from"./DwsRDnkS.js";import{p as Ee}from"./DZAWjsA4.js";var m={NORMAL:0,REVERSE:1,HIGHLIGHT:2,MERGE:3,CHERRY_PICK:4},Be=ve.gitGraph,S=h(()=>ke({...Be,...J().gitGraph}),"getConfig"),d=new le(()=>{const e=S(),r=e.mainBranchName,t=e.mainBranchOrder;return{mainBranchName:r,commits:new Map,head:null,branchConfig:new Map([[r,{name:r,order:t}]]),branches:new Map([[r,null]]),currBranch:r,direction:"LR",seq:0,options:{}}});function Y(){return Ce({length:7})}h(Y,"getID");function te(e,r){const t=Object.create(null);return e.reduce((s,o)=>{const i=r(o);return t[i]||(t[i]=!0,s.push(o)),s},[])}h(te,"uniqBy");var Te=h(function(e){d.records.direction=e},"setDirection"),Le=h(function(e){w.debug("options str",e),e=e?.trim(),e=e||"{}";try{d.records.options=JSON.parse(e)}catch(r){w.error("error while parsing gitGraph options",r.message)}},"setOptions"),Me=h(function(){return d.records.options},"getOptions"),Re=h(function(e){let r=e.msg,t=e.id;const s=e.type;let o=e.tags;w.info("commit",r,t,s,o),w.debug("Entering commit:",r,t,s,o);const i=S();t=B.sanitizeText(t,i),r=B.sanitizeText(r,i),o=o?.map(a=>B.sanitizeText(a,i));const n={id:t||d.records.seq+"-"+Y(),message:r,seq:d.records.seq++,type:s??m.NORMAL,tags:o??[],parents:d.records.head==null?[]:[d.records.head.id],branch:d.records.currBranch};d.records.head=n,w.info("main branch",i.mainBranchName),d.records.commits.has(n.id)&&w.warn(`Commit ID ${n.id} already exists`),d.records.commits.set(n.id,n),d.records.branches.set(d.records.currBranch,n.id),w.debug("in pushCommit "+n.id)},"commit"),Ie=h(function(e){let r=e.name;const t=e.order;if(r=B.sanitizeText(r,S()),d.records.branches.has(r))throw new Error(`Trying to create an existing branch. (Help: Either use a new name if you want create a new branch or try using "checkout ${r}")`);d.records.branches.set(r,d.records.head!=null?d.records.head.id:null),d.records.branchConfig.set(r,{name:r,order:t}),ae(r),w.debug("in createBranch")},"branch"),Oe=h(e=>{let r=e.branch,t=e.id;const s=e.type,o=e.tags,i=S();r=B.sanitizeText(r,i),t&&(t=B.sanitizeText(t,i));const n=d.records.branches.get(d.records.currBranch),a=d.records.branches.get(r),l=n?d.records.commits.get(n):void 0,f=a?d.records.commits.get(a):void 0;if(l&&f&&l.branch===r)throw new Error(`Cannot merge branch '${r}' into itself.`);if(d.records.currBranch===r){const c=new Error('Incorrect usage of "merge". Cannot merge a branch to itself');throw c.hash={text:`merge ${r}`,token:`merge ${r}`,expected:["branch abc"]},c}if(l===void 0||!l){const c=new Error(`Incorrect usage of "merge". Current branch (${d.records.currBranch})has no commits`);throw c.hash={text:`merge ${r}`,token:`merge ${r}`,expected:["commit"]},c}if(!d.records.branches.has(r)){const c=new Error('Incorrect usage of "merge". Branch to be merged ('+r+") does not exist");throw c.hash={text:`merge ${r}`,token:`merge ${r}`,expected:[`branch ${r}`]},c}if(f===void 0||!f){const c=new Error('Incorrect usage of "merge". Branch to be merged ('+r+") has no commits");throw c.hash={text:`merge ${r}`,token:`merge ${r}`,expected:['"commit"']},c}if(l===f){const c=new Error('Incorrect usage of "merge". Both branches have same head');throw c.hash={text:`merge ${r}`,token:`merge ${r}`,expected:["branch abc"]},c}if(t&&d.records.commits.has(t)){const c=new Error('Incorrect usage of "merge". Commit with id:'+t+" already exists, use different custom id");throw c.hash={text:`merge ${r} ${t} ${s} ${o?.join(" ")}`,token:`merge ${r} ${t} ${s} ${o?.join(" ")}`,expected:[`merge ${r} ${t}_UNIQUE ${s} ${o?.join(" ")}`]},c}const g=a||"",$={id:t||`${d.records.seq}-${Y()}`,message:`merged branch ${r} into ${d.records.currBranch}`,seq:d.records.seq++,parents:d.records.head==null?[]:[d.records.head.id,g],branch:d.records.currBranch,type:m.MERGE,customType:s,customId:!!t,tags:o??[]};d.records.head=$,d.records.commits.set($.id,$),d.records.branches.set(d.records.currBranch,$.id),w.debug(d.records.branches),w.debug("in mergeBranch")},"merge"),_e=h(function(e){let r=e.id,t=e.targetId,s=e.tags,o=e.parent;w.debug("Entering cherryPick:",r,t,s);const i=S();if(r=B.sanitizeText(r,i),t=B.sanitizeText(t,i),s=s?.map(l=>B.sanitizeText(l,i)),o=B.sanitizeText(o,i),!r||!d.records.commits.has(r)){const l=new Error('Incorrect usage of "cherryPick". Source commit id should exist and provided');throw l.hash={text:`cherryPick ${r} ${t}`,token:`cherryPick ${r} ${t}`,expected:["cherry-pick abc"]},l}const n=d.records.commits.get(r);if(n===void 0||!n)throw new Error('Incorrect usage of "cherryPick". Source commit id should exist and provided');if(o&&!(Array.isArray(n.parents)&&n.parents.includes(o)))throw new Error("Invalid operation: The specified parent commit is not an immediate parent of the cherry-picked commit.");const a=n.branch;if(n.type===m.MERGE&&!o)throw new Error("Incorrect usage of cherry-pick: If the source commit is a merge commit, an immediate parent commit must be specified.");if(!t||!d.records.commits.has(t)){if(a===d.records.currBranch){const $=new Error('Incorrect usage of "cherryPick". Source commit is already on current branch');throw $.hash={text:`cherryPick ${r} ${t}`,token:`cherryPick ${r} ${t}`,expected:["cherry-pick abc"]},$}const l=d.records.branches.get(d.records.currBranch);if(l===void 0||!l){const $=new Error(`Incorrect usage of "cherry-pick". Current branch (${d.records.currBranch})has no commits`);throw $.hash={text:`cherryPick ${r} ${t}`,token:`cherryPick ${r} ${t}`,expected:["cherry-pick abc"]},$}const f=d.records.commits.get(l);if(f===void 0||!f){const $=new Error(`Incorrect usage of "cherry-pick". Current branch (${d.records.currBranch})has no commits`);throw $.hash={text:`cherryPick ${r} ${t}`,token:`cherryPick ${r} ${t}`,expected:["cherry-pick abc"]},$}const g={id:d.records.seq+"-"+Y(),message:`cherry-picked ${n?.message} into ${d.records.currBranch}`,seq:d.records.seq++,parents:d.records.head==null?[]:[d.records.head.id,n.id],branch:d.records.currBranch,type:m.CHERRY_PICK,tags:s?s.filter(Boolean):[`cherry-pick:${n.id}${n.type===m.MERGE?`|parent:${o}`:""}`]};d.records.head=g,d.records.commits.set(g.id,g),d.records.branches.set(d.records.currBranch,g.id),w.debug(d.records.branches),w.debug("in cherryPick")}},"cherryPick"),ae=h(function(e){if(e=B.sanitizeText(e,S()),d.records.branches.has(e)){d.records.currBranch=e;const r=d.records.branches.get(d.records.currBranch);r===void 0||!r?d.records.head=null:d.records.head=d.records.commits.get(r)??null}else{const r=new Error(`Trying to checkout branch which is not yet created. (Help try using "branch ${e}")`);throw r.hash={text:`checkout ${e}`,token:`checkout ${e}`,expected:[`branch ${e}`]},r}},"checkout");function V(e,r,t){const s=e.indexOf(r);s===-1?e.push(t):e.splice(s,1,t)}h(V,"upsert");function Q(e){const r=e.reduce((o,i)=>o.seq>i.seq?o:i,e[0]);let t="";e.forEach(function(o){o===r?t+=" *":t+=" |"});const s=[t,r.id,r.seq];for(const o in d.records.branches)d.records.branches.get(o)===r.id&&s.push(o);if(w.debug(s.join(" ")),r.parents&&r.parents.length==2&&r.parents[0]&&r.parents[1]){const o=d.records.commits.get(r.parents[0]);V(e,r,o),r.parents[1]&&e.push(d.records.commits.get(r.parents[1]))}else{if(r.parents.length==0)return;if(r.parents[0]){const o=d.records.commits.get(r.parents[0]);V(e,r,o)}}e=te(e,o=>o.id),Q(e)}h(Q,"prettyPrintCommitHistory");var Ge=h(function(){w.debug(d.records.commits);const e=ne()[0];Q([e])},"prettyPrint"),He=h(function(){d.reset(),we()},"clear"),Se=h(function(){return[...d.records.branchConfig.values()].map((r,t)=>r.order!==null&&r.order!==void 0?r:{...r,order:parseFloat(`0.${t}`)}).sort((r,t)=>(r.order??0)-(t.order??0)).map(({name:r})=>({name:r}))},"getBranchesAsObjArray"),Ae=h(function(){return d.records.branches},"getBranches"),We=h(function(){return d.records.commits},"getCommits"),ne=h(function(){const e=[...d.records.commits.values()];return e.forEach(function(r){w.debug(r.id)}),e.sort((r,t)=>r.seq-t.seq),e},"getCommitsArray"),De=h(function(){return d.records.currBranch},"getCurrentBranch"),qe=h(function(){return d.records.direction},"getDirection"),Pe=h(function(){return d.records.head},"getHead"),se={commitType:m,getConfig:S,setDirection:Te,setOptions:Le,getOptions:Me,commit:Re,branch:Ie,merge:Oe,cherryPick:_e,checkout:ae,prettyPrint:Ge,clear:He,getBranchesAsObjArray:Se,getBranches:Ae,getCommits:We,getCommitsArray:ne,getCurrentBranch:De,getDirection:qe,getHead:Pe,setAccTitle:xe,getAccTitle:ye,getAccDescription:ue,setAccDescription:ge,setDiagramTitle:fe,getDiagramTitle:$e},Ne=h((e,r)=>{he(e,r),e.dir&&r.setDirection(e.dir);for(const t of e.statements)Fe(t,r)},"populate"),Fe=h((e,r)=>{const s={Commit:h(o=>r.commit(ze(o)),"Commit"),Branch:h(o=>r.branch(Ye(o)),"Branch"),Merge:h(o=>r.merge(je(o)),"Merge"),Checkout:h(o=>r.checkout(Ue(o)),"Checkout"),CherryPicking:h(o=>r.cherryPick(Ke(o)),"CherryPicking")}[e.$type];s?s(e):w.error(`Unknown statement type: ${e.$type}`)},"parseStatement"),ze=h(e=>({id:e.id,msg:e.message??"",type:e.type!==void 0?m[e.type]:m.NORMAL,tags:e.tags??void 0}),"parseCommit"),Ye=h(e=>({name:e.name,order:e.order??0}),"parseBranch"),je=h(e=>({branch:e.branch,id:e.id??"",type:e.type!==void 0?m[e.type]:void 0,tags:e.tags??void 0}),"parseMerge"),Ue=h(e=>e.branch,"parseCheckout"),Ke=h(e=>({id:e.id,targetId:"",tags:e.tags?.length===0?void 0:e.tags,parent:e.parent}),"parseCherryPicking"),Ve={parse:h(async e=>{const r=await Ee("gitGraph",e);w.debug(r),Ne(r,se)},"parse")},O=10,_=40,L=4,R=2,G=8,j=new Set(["redux","redux-dark","redux-color","redux-dark-color"]),X=12,Z=new Set(["redux-color","redux-dark-color"]),Xe=new Set(["dark","redux-dark","redux-dark-color","neo-dark"]),H=h((e,r,t=!1)=>t&&e>0?(e-1)%(r-1)+1:e%r,"calcColorIndex"),C=new Map,E=new Map,F=30,D=new Map,z=[],I=0,y="LR",Je=h(()=>{C.clear(),E.clear(),D.clear(),I=0,z=[],y="LR"},"clear"),oe=h(e=>{const r=document.createElementNS("http://www.w3.org/2000/svg","text");return(typeof e=="string"?e.split(/\\n|\n|<br\s*\/?>/gi):e).forEach(s=>{const o=document.createElementNS("http://www.w3.org/2000/svg","tspan");o.setAttributeNS("http://www.w3.org/XML/1998/namespace","xml:space","preserve"),o.setAttribute("dy","1em"),o.setAttribute("x","0"),o.setAttribute("class","row"),o.textContent=s.trim(),r.appendChild(o)}),r},"drawText"),ce=h(e=>{let r,t,s;return y==="BT"?(t=h((o,i)=>o<=i,"comparisonFunc"),s=1/0):(t=h((o,i)=>o>=i,"comparisonFunc"),s=0),e.forEach(o=>{const i=y==="TB"||y=="BT"?E.get(o)?.y:E.get(o)?.x;i!==void 0&&t(i,s)&&(r=o,s=i)}),r},"findClosestParent"),Qe=h(e=>{let r="",t=1/0;return e.forEach(s=>{const o=E.get(s).y;o<=t&&(r=s,t=o)}),r||void 0},"findClosestParentBT"),Ze=h((e,r,t)=>{let s=t,o=t;const i=[];e.forEach(n=>{const a=r.get(n);if(!a)throw new Error(`Commit not found for key ${n}`);a.parents.length?(s=rr(a),o=Math.max(s,o)):i.push(a),tr(a,s)}),s=o,i.forEach(n=>{ar(n,s,t)}),e.forEach(n=>{const a=r.get(n);if(a?.parents.length){const l=Qe(a.parents);s=E.get(l).y-_,s<=o&&(o=s);const f=C.get(a.branch).pos,g=s-O;E.set(a.id,{x:f,y:g})}})},"setParallelBTPos"),er=h(e=>{const r=ce(e.parents.filter(s=>s!==null));if(!r)throw new Error(`Closest parent not found for commit ${e.id}`);const t=E.get(r)?.y;if(t===void 0)throw new Error(`Closest parent position not found for commit ${e.id}`);return t},"findClosestParentPos"),rr=h(e=>er(e)+_,"calculateCommitPosition"),tr=h((e,r)=>{const t=C.get(e.branch);if(!t)throw new Error(`Branch not found for commit ${e.id}`);const s=t.pos,o=r+O;return E.set(e.id,{x:s,y:o}),{x:s,y:o}},"setCommitPosition"),ar=h((e,r,t)=>{const s=C.get(e.branch);if(!s)throw new Error(`Branch not found for commit ${e.id}`);const o=r+t,i=s.pos;E.set(e.id,{x:i,y:o})},"setRootPosition"),nr=h((e,r,t,s,o,i)=>{const{theme:n}=P(),a=j.has(n??""),l=Z.has(n??""),f=Xe.has(n??"");if(i===m.HIGHLIGHT)e.append("rect").attr("x",t.x-10+(a?3:0)).attr("y",t.y-10+(a?3:0)).attr("width",a?14:20).attr("height",a?14:20).attr("class",`commit ${r.id} commit-highlight${H(o,G,l)} ${s}-outer`),e.append("rect").attr("x",t.x-6+(a?2:0)).attr("y",t.y-6+(a?2:0)).attr("width",a?8:12).attr("height",a?8:12).attr("class",`commit ${r.id} commit${H(o,G,l)} ${s}-inner`);else if(i===m.CHERRY_PICK)e.append("circle").attr("cx",t.x).attr("cy",t.y).attr("r",a?7:10).attr("class",`commit ${r.id} ${s}`),e.append("circle").attr("cx",t.x-3).attr("cy",t.y+2).attr("r",a?2.5:2.75).attr("fill",f?"#000000":"#fff").attr("class",`commit ${r.id} ${s}`),e.append("circle").attr("cx",t.x+3).attr("cy",t.y+2).attr("r",a?2.5:2.75).attr("fill",f?"#000000":"#fff").attr("class",`commit ${r.id} ${s}`),e.append("line").attr("x1",t.x+3).attr("y1",t.y+1).attr("x2",t.x).attr("y2",t.y-5).attr("stroke",f?"#000000":"#fff").attr("class",`commit ${r.id} ${s}`),e.append("line").attr("x1",t.x-3).attr("y1",t.y+1).attr("x2",t.x).attr("y2",t.y-5).attr("stroke",f?"#000000":"#fff").attr("class",`commit ${r.id} ${s}`);else{const g=e.append("circle");if(g.attr("cx",t.x),g.attr("cy",t.y),g.attr("r",a?7:10),g.attr("class",`commit ${r.id} commit${H(o,G,l)}`),i===m.MERGE){const $=e.append("circle");$.attr("cx",t.x),$.attr("cy",t.y),$.attr("r",a?5:6),$.attr("class",`commit ${s} ${r.id} commit${H(o,G,l)}`)}if(i===m.REVERSE){const $=e.append("path"),c=a?4:5;$.attr("d",`M ${t.x-c},${t.y-c}L${t.x+c},${t.y+c}M${t.x-c},${t.y+c}L${t.x+c},${t.y-c}`).attr("class",`commit ${s} ${r.id} commit${H(o,G,l)}`)}}},"drawCommitBullet"),sr=h((e,r,t,s,o)=>{if(r.type!==m.CHERRY_PICK&&(r.customId&&r.type===m.MERGE||r.type!==m.MERGE)&&o.showCommitLabel){const i=e.append("g"),n=i.insert("rect").attr("class","commit-label-bkg"),a=i.append("text").attr("x",s).attr("y",t.y+25).attr("class","commit-label").text(r.id),l=a.node()?.getBBox();if(l&&(n.attr("x",t.posWithOffset-l.width/2-R).attr("y",t.y+13.5).attr("width",l.width+2*R).attr("height",l.height+2*R),y==="TB"||y==="BT"?(n.attr("x",t.x-(l.width+4*L+5)).attr("y",t.y-12),a.attr("x",t.x-(l.width+4*L)).attr("y",t.y+l.height-12)):a.attr("x",t.posWithOffset-l.width/2),o.rotateCommitLabel))if(y==="TB"||y==="BT")a.attr("transform","rotate(-45, "+t.x+", "+t.y+")"),n.attr("transform","rotate(-45, "+t.x+", "+t.y+")");else{const f=-7.5-(l.width+10)/25*9.5,g=10+l.width/25*8.5;i.attr("transform","translate("+f+", "+g+") rotate(-45, "+s+", "+t.y+")")}}},"drawCommitLabel"),or=h((e,r,t,s)=>{if(r.tags.length>0){let o=0,i=0,n=0;const a=[];for(const l of r.tags.reverse()){const f=e.insert("polygon"),g=e.append("circle"),$=e.append("text").attr("y",t.y-16-o).attr("class","tag-label").text(l),c=$.node()?.getBBox();if(!c)throw new Error("Tag bbox not found");i=Math.max(i,c.width),n=Math.max(n,c.height),$.attr("x",t.posWithOffset-c.width/2),a.push({tag:$,hole:g,rect:f,yOffset:o}),o+=20}for(const{tag:l,hole:f,rect:g,yOffset:$}of a){const c=n/2,x=t.y-19.2-$;if(g.attr("class","tag-label-bkg").attr("points",`
2
2
  ${s-i/2-L/2},${x+R}
3
3
  ${s-i/2-L/2},${x-R}
4
4
  ${t.posWithOffset-i/2-L},${x-c-R}
@@ -1 +1 @@
1
- import{y as b}from"./BBvT7Bb8.js";const u=/^[A-Za-z0-9._:-]{1,128}$/,C="connections.manage",l="";class f extends Error{constructor(t,e){super(t),this.status=e,this.name="HostRequestError"}}function d(n){return typeof n=="string"&&n.startsWith("/")&&!n.startsWith("//")}function h(){const n=globalThis.__INTENT_RUNTIME_CONFIG__;if(!n)return null;const{backendId:t,connectionsUrl:e,eventsUrl:o,hostCapabilities:s}=n,r=Array.isArray(s)&&s.includes(C),a=t===null&&r;return!a&&(typeof t!="string"||!u.test(t))||!d(e)?null:{backendId:a?null:t,connectionsUrl:e,eventsUrl:d(o)?o:null,canManageConnections:r,tailcatAvailable:n.tailcatAvailable===!0}}function g(){return b()?null:h()}function E(){const n=g();return n?.canManageConnections?n:null}function w(n,t){const e=n.backendId??l;return{...t,activeId:t.activeId??l,windowBackendId:e}}async function H(n,t=fetch){const e=n.backendId===null?n.connectionsUrl:`${n.connectionsUrl}?backend=${encodeURIComponent(n.backendId)}`,o=await t(e,{credentials:"same-origin",cache:"no-store"});if(!o.ok)throw new f(`connections list failed: HTTP ${o.status}`,o.status);return w(n,await o.json())}function I(n,t=(s,r,a)=>globalThis.open?.(s,r,a),e=s=>globalThis.location?.assign(s),o=!1){if(!u.test(n))throw new Error(`invalid connection id: ${n}`);const s=`/?backend=${encodeURIComponent(n)}`;return o?e(s):t(s,"_blank","noopener"),{status:"opened",id:n}}function i(n,t,e){if(!u.test(t))throw new Error(`invalid connection id: ${t}`);return`${n.connectionsUrl}/${encodeURIComponent(t)}${e?`/${e}`:""}`}async function c(n,t,e,o){const s=await n(e,{method:t,credentials:"same-origin",cache:"no-store",...o===void 0?{}:{headers:{"Content-Type":"application/json"},body:JSON.stringify(o)}});if(!s.ok)throw new f(`connections request failed: HTTP ${s.status}`,s.status);return await s.json()}async function k(n,t,e=fetch){const o=await c(e,"POST",`${n.connectionsUrl}/capture-fingerprint`,{host:t.host,port:t.port,...t.token?{token:t.token}:{}});if(!o.ok)throw new Error(o.error??"fingerprint capture failed");return{fingerprint:o.fingerprint,tokenValid:o.tokenValid,...o.statusCode!==void 0?{statusCode:o.statusCode}:{}}}function y(n,t,e=fetch){const{syncExcluded:o,...s}=t;return c(e,"POST",n.connectionsUrl,s)}function A(n,t,e=fetch){const{id:o,syncExcluded:s,...r}=t;return c(e,"PATCH",i(n,o),r)}function _(n,t,e=fetch){const{id:o,...s}=t;return c(e,"POST",i(n,o,"test"),s)}function N(n,t,e=fetch){const{id:o,...s}=t;return c(e,"POST",i(n,o,"rotate-secret"),s)}function P(n,t,e=fetch){return c(e,"GET",i(n,t,"tunnel"))}function U(n,t,e=fetch){return c(e,"PUT",i(n,t.id,"tunnel"),{enabled:t.enabled})}async function $(n,t,e=fetch){return await c(e,"DELETE",i(n,t),{}),{id:t}}function T(n){return{manageConnections:n.canManageConnections,backendBound:n.backendId!==null,tailcatAvailable:n.tailcatAvailable}}function O(n){const t=g(),e=n?.connections;if(!t||e&&"browserHost"in e)return n;const o={...e,browserHost:T(t)};return{...n,connections:o}}export{f as H,y as a,w as b,k as c,$ as d,P as e,H as f,h as g,E as h,g as i,T as j,I as o,N as r,U as s,_ as t,A as u,O as w};
1
+ import{y as b}from"./Dix9BiYu.js";const u=/^[A-Za-z0-9._:-]{1,128}$/,C="connections.manage",l="";class f extends Error{constructor(t,e){super(t),this.status=e,this.name="HostRequestError"}}function d(n){return typeof n=="string"&&n.startsWith("/")&&!n.startsWith("//")}function h(){const n=globalThis.__INTENT_RUNTIME_CONFIG__;if(!n)return null;const{backendId:t,connectionsUrl:e,eventsUrl:o,hostCapabilities:s}=n,r=Array.isArray(s)&&s.includes(C),a=t===null&&r;return!a&&(typeof t!="string"||!u.test(t))||!d(e)?null:{backendId:a?null:t,connectionsUrl:e,eventsUrl:d(o)?o:null,canManageConnections:r,tailcatAvailable:n.tailcatAvailable===!0}}function g(){return b()?null:h()}function E(){const n=g();return n?.canManageConnections?n:null}function w(n,t){const e=n.backendId??l;return{...t,activeId:t.activeId??l,windowBackendId:e}}async function H(n,t=fetch){const e=n.backendId===null?n.connectionsUrl:`${n.connectionsUrl}?backend=${encodeURIComponent(n.backendId)}`,o=await t(e,{credentials:"same-origin",cache:"no-store"});if(!o.ok)throw new f(`connections list failed: HTTP ${o.status}`,o.status);return w(n,await o.json())}function I(n,t=(s,r,a)=>globalThis.open?.(s,r,a),e=s=>globalThis.location?.assign(s),o=!1){if(!u.test(n))throw new Error(`invalid connection id: ${n}`);const s=`/?backend=${encodeURIComponent(n)}`;return o?e(s):t(s,"_blank","noopener"),{status:"opened",id:n}}function i(n,t,e){if(!u.test(t))throw new Error(`invalid connection id: ${t}`);return`${n.connectionsUrl}/${encodeURIComponent(t)}${e?`/${e}`:""}`}async function c(n,t,e,o){const s=await n(e,{method:t,credentials:"same-origin",cache:"no-store",...o===void 0?{}:{headers:{"Content-Type":"application/json"},body:JSON.stringify(o)}});if(!s.ok)throw new f(`connections request failed: HTTP ${s.status}`,s.status);return await s.json()}async function k(n,t,e=fetch){const o=await c(e,"POST",`${n.connectionsUrl}/capture-fingerprint`,{host:t.host,port:t.port,...t.token?{token:t.token}:{}});if(!o.ok)throw new Error(o.error??"fingerprint capture failed");return{fingerprint:o.fingerprint,tokenValid:o.tokenValid,...o.statusCode!==void 0?{statusCode:o.statusCode}:{}}}function y(n,t,e=fetch){const{syncExcluded:o,...s}=t;return c(e,"POST",n.connectionsUrl,s)}function A(n,t,e=fetch){const{id:o,syncExcluded:s,...r}=t;return c(e,"PATCH",i(n,o),r)}function _(n,t,e=fetch){const{id:o,...s}=t;return c(e,"POST",i(n,o,"test"),s)}function N(n,t,e=fetch){const{id:o,...s}=t;return c(e,"POST",i(n,o,"rotate-secret"),s)}function P(n,t,e=fetch){return c(e,"GET",i(n,t,"tunnel"))}function U(n,t,e=fetch){return c(e,"PUT",i(n,t.id,"tunnel"),{enabled:t.enabled})}async function $(n,t,e=fetch){return await c(e,"DELETE",i(n,t),{}),{id:t}}function T(n){return{manageConnections:n.canManageConnections,backendBound:n.backendId!==null,tailcatAvailable:n.tailcatAvailable}}function O(n){const t=g(),e=n?.connections;if(!t||e&&"browserHost"in e)return n;const o={...e,browserHost:T(t)};return{...n,connections:o}}export{f as H,y as a,w as b,k as c,$ as d,P as e,H as f,h as g,E as h,g as i,T as j,I as o,N as r,U as s,_ as t,A as u,O as w};
@@ -1,4 +1,4 @@
1
- import{g as Fe}from"./DAgho_P-.js";import{ap as Me,a5 as xe,ar as Ke,bc as We,bb as Ye,be as Ve,bd as Ue,b9 as He,b7 as Xe,b2 as je,aN as Ge,aF as qe,aE as Je,az as Ze,aj as Qe,ai as $e,ak as et,S as tt,R as st,K as rt,k as it,I as at,f as nt,g as ot,e as ct,b as u,W as P,aW as X,ag as lt,aD as ut,B as ht,ay as y,r as gt,am as dt,aU as pt,ab as ft,x as bt,aT as St,p as xt,X as Le,ae as Lt,af as mt,aK as yt,z as wt,a3 as Et,ah as me,b6 as kt,aL as _t}from"./DWcUEP_3.js";import{G as Dt}from"./-xK_vQQs.js";function Tt(e){return Array.isArray(e)}function Nt(e){if(Me(e))return e;const a=xe(e);if(!It(e))return{};if(Tt(e)){const s=Array.from(e);return e.length>0&&typeof e[0]=="string"&&Object.hasOwn(e,"index")&&(s.index=e.index,s.input=e.input),s}if(Ke(e)){const s=e,c=s.constructor;return new c(s.buffer,s.byteOffset,s.length)}if(a==="[object ArrayBuffer]")return new ArrayBuffer(e.byteLength);if(a==="[object DataView]"){const s=e,c=s.buffer,g=s.byteOffset,t=s.byteLength,h=new ArrayBuffer(t),x=new Uint8Array(c,g,t);return new Uint8Array(h).set(x),new DataView(h)}if(a==="[object Boolean]"||a==="[object Number]"||a==="[object String]"){const s=e.constructor,c=new s(e.valueOf());return a==="[object String]"?Ct(c,e):se(c,e),c}if(a==="[object Date]")return new Date(Number(e));if(a==="[object RegExp]"){const s=e,c=new RegExp(s.source,s.flags);return c.lastIndex=s.lastIndex,c}if(a==="[object Symbol]")return Object(Symbol.prototype.valueOf.call(e));if(a==="[object Map]"){const s=e,c=new Map;return s.forEach((g,t)=>{c.set(t,g)}),c}if(a==="[object Set]"){const s=e,c=new Set;return s.forEach(g=>{c.add(g)}),c}if(a==="[object Arguments]"){const s=e,c={};return se(c,s),c.length=s.length,c[Symbol.iterator]=s[Symbol.iterator],c}const o={};return vt(o,e),se(o,e),Ot(o,e),o}function It(e){switch(xe(e)){case ct:case ot:case nt:case at:case it:case rt:case st:case tt:case et:case $e:case Qe:case Ze:case Je:case qe:case Ge:case je:case Xe:case He:case Ue:case Ve:case Ye:case We:return!0;default:return!1}}function se(e,a){for(const o in a)Object.hasOwn(a,o)&&(e[o]=a[o])}function Ot(e,a){const o=Object.getOwnPropertySymbols(a);for(let s=0;s<o.length;s++){const c=o[s];Object.prototype.propertyIsEnumerable.call(a,c)&&(e[c]=a[c])}}function Ct(e,a){const o=a.valueOf().length;for(const s in a)Object.hasOwn(a,s)&&(Number.isNaN(Number(s))||Number(s)>=o)&&(e[s]=a[s])}function vt(e,a){const o=Object.getPrototypeOf(a);o!==null&&typeof a.constructor=="function"&&Object.setPrototypeOf(e,o)}var ie=(function(){var e=u(function(C,d,i,l){for(i=i||{},l=C.length;l--;i[C[l]]=d);return i},"o"),a=[1,15],o=[1,7],s=[1,13],c=[1,14],g=[1,19],t=[1,16],h=[1,17],x=[1,18],L=[8,30],b=[8,10,21,28,29,30,31,39,43,46],f=[1,23],m=[1,24],w=[8,10,15,16,21,28,29,30,31,39,43,46],S=[8,10,15,16,21,27,28,29,30,31,39,43,46],_=[1,49],k={trace:u(function(){},"trace"),yy:{},symbols_:{error:2,spaceLines:3,SPACELINE:4,NL:5,separator:6,SPACE:7,EOF:8,start:9,BLOCK_DIAGRAM_KEY:10,document:11,stop:12,statement:13,link:14,LINK:15,START_LINK:16,LINK_LABEL:17,STR:18,nodeStatement:19,columnsStatement:20,SPACE_BLOCK:21,blockStatement:22,classDefStatement:23,cssClassStatement:24,styleStatement:25,node:26,SIZE:27,COLUMNS:28,"id-block":29,end:30,NODE_ID:31,nodeShapeNLabel:32,dirList:33,DIR:34,NODE_DSTART:35,NODE_DEND:36,BLOCK_ARROW_START:37,BLOCK_ARROW_END:38,classDef:39,CLASSDEF_ID:40,CLASSDEF_STYLEOPTS:41,DEFAULT:42,class:43,CLASSENTITY_IDS:44,STYLECLASS:45,style:46,STYLE_ENTITY_IDS:47,STYLE_DEFINITION_DATA:48,$accept:0,$end:1},terminals_:{2:"error",4:"SPACELINE",5:"NL",7:"SPACE",8:"EOF",10:"BLOCK_DIAGRAM_KEY",15:"LINK",16:"START_LINK",17:"LINK_LABEL",18:"STR",21:"SPACE_BLOCK",27:"SIZE",28:"COLUMNS",29:"id-block",30:"end",31:"NODE_ID",34:"DIR",35:"NODE_DSTART",36:"NODE_DEND",37:"BLOCK_ARROW_START",38:"BLOCK_ARROW_END",39:"classDef",40:"CLASSDEF_ID",41:"CLASSDEF_STYLEOPTS",42:"DEFAULT",43:"class",44:"CLASSENTITY_IDS",45:"STYLECLASS",46:"style",47:"STYLE_ENTITY_IDS",48:"STYLE_DEFINITION_DATA"},productions_:[0,[3,1],[3,2],[3,2],[6,1],[6,1],[6,1],[9,3],[12,1],[12,1],[12,2],[12,2],[11,1],[11,2],[14,1],[14,4],[13,1],[13,1],[13,1],[13,1],[13,1],[13,1],[13,1],[19,3],[19,2],[19,1],[20,1],[22,4],[22,3],[26,1],[26,2],[33,1],[33,2],[32,3],[32,4],[23,3],[23,3],[24,3],[25,3]],performAction:u(function(d,i,l,p,E,r,K){var n=r.length-1;switch(E){case 4:p.getLogger().debug("Rule: separator (NL) ");break;case 5:p.getLogger().debug("Rule: separator (Space) ");break;case 6:p.getLogger().debug("Rule: separator (EOF) ");break;case 7:p.getLogger().debug("Rule: hierarchy: ",r[n-1]),p.setHierarchy(r[n-1]);break;case 8:p.getLogger().debug("Stop NL ");break;case 9:p.getLogger().debug("Stop EOF ");break;case 10:p.getLogger().debug("Stop NL2 ");break;case 11:p.getLogger().debug("Stop EOF2 ");break;case 12:p.getLogger().debug("Rule: statement: ",r[n]),typeof r[n].length=="number"?this.$=r[n]:this.$=[r[n]];break;case 13:p.getLogger().debug("Rule: statement #2: ",r[n-1]),this.$=[r[n-1]].concat(r[n]);break;case 14:p.getLogger().debug("Rule: link: ",r[n],d),this.$={edgeTypeStr:r[n],label:""};break;case 15:p.getLogger().debug("Rule: LABEL link: ",r[n-3],r[n-1],r[n]),this.$={edgeTypeStr:r[n],label:r[n-1]};break;case 18:const F=parseInt(r[n]),Y=p.generateId();this.$={id:Y,type:"space",label:"",width:F,children:[]};break;case 23:p.getLogger().debug("Rule: (nodeStatement link node) ",r[n-2],r[n-1],r[n]," typestr: ",r[n-1].edgeTypeStr);const J=p.edgeStrToEdgeData(r[n-1].edgeTypeStr),V=p.edgeStrToEdgeStartData(r[n-1].edgeTypeStr),Z=p.edgeStrToThickness(r[n-1].edgeTypeStr),D=p.edgeStrToPattern(r[n-1].edgeTypeStr);this.$=[{id:r[n-2].id,label:r[n-2].label,type:r[n-2].type,directions:r[n-2].directions},{id:r[n-2].id+"-"+r[n].id,start:r[n-2].id,end:r[n].id,label:r[n-1].label,type:"edge",thickness:Z,pattern:D,directions:r[n].directions,arrowTypeEnd:J,arrowTypeStart:V},{id:r[n].id,label:r[n].label,type:p.typeStr2Type(r[n].typeStr),directions:r[n].directions}];break;case 24:p.getLogger().debug("Rule: nodeStatement (abc88 node size) ",r[n-1],r[n]),this.$={id:r[n-1].id,label:r[n-1].label,type:p.typeStr2Type(r[n-1].typeStr),directions:r[n-1].directions,widthInColumns:parseInt(r[n],10)};break;case 25:p.getLogger().debug("Rule: nodeStatement (node) ",r[n]),this.$={id:r[n].id,label:r[n].label,type:p.typeStr2Type(r[n].typeStr),directions:r[n].directions,widthInColumns:1};break;case 26:p.getLogger().debug("APA123",this?this:"na"),p.getLogger().debug("COLUMNS: ",r[n]),this.$={type:"column-setting",columns:r[n]==="auto"?-1:parseInt(r[n])};break;case 27:p.getLogger().debug("Rule: id-block statement : ",r[n-2],r[n-1]),p.generateId(),this.$={...r[n-2],type:"composite",children:r[n-1]};break;case 28:p.getLogger().debug("Rule: blockStatement : ",r[n-2],r[n-1],r[n]);const z=p.generateId();this.$={id:z,type:"composite",label:"",children:r[n-1]};break;case 29:p.getLogger().debug("Rule: node (NODE_ID separator): ",r[n]),this.$={id:r[n]};break;case 30:p.getLogger().debug("Rule: node (NODE_ID nodeShapeNLabel separator): ",r[n-1],r[n]),this.$={id:r[n-1],label:r[n].label,typeStr:r[n].typeStr,directions:r[n].directions};break;case 31:p.getLogger().debug("Rule: dirList: ",r[n]),this.$=[r[n]];break;case 32:p.getLogger().debug("Rule: dirList: ",r[n-1],r[n]),this.$=[r[n-1]].concat(r[n]);break;case 33:p.getLogger().debug("Rule: nodeShapeNLabel: ",r[n-2],r[n-1],r[n]),this.$={typeStr:r[n-2]+r[n],label:r[n-1]};break;case 34:p.getLogger().debug("Rule: BLOCK_ARROW nodeShapeNLabel: ",r[n-3],r[n-2]," #3:",r[n-1],r[n]),this.$={typeStr:r[n-3]+r[n],label:r[n-2],directions:r[n-1]};break;case 35:case 36:this.$={type:"classDef",id:r[n-1].trim(),css:r[n].trim()};break;case 37:this.$={type:"applyClass",id:r[n-1].trim(),styleClass:r[n].trim()};break;case 38:this.$={type:"applyStyles",id:r[n-1].trim(),stylesStr:r[n].trim()};break}},"anonymous"),table:[{9:1,10:[1,2]},{1:[3]},{10:a,11:3,13:4,19:5,20:6,21:o,22:8,23:9,24:10,25:11,26:12,28:s,29:c,31:g,39:t,43:h,46:x},{8:[1,20]},e(L,[2,12],{13:4,19:5,20:6,22:8,23:9,24:10,25:11,26:12,11:21,10:a,21:o,28:s,29:c,31:g,39:t,43:h,46:x}),e(b,[2,16],{14:22,15:f,16:m}),e(b,[2,17]),e(b,[2,18]),e(b,[2,19]),e(b,[2,20]),e(b,[2,21]),e(b,[2,22]),e(w,[2,25],{27:[1,25]}),e(b,[2,26]),{19:26,26:12,31:g},{10:a,11:27,13:4,19:5,20:6,21:o,22:8,23:9,24:10,25:11,26:12,28:s,29:c,31:g,39:t,43:h,46:x},{40:[1,28],42:[1,29]},{44:[1,30]},{47:[1,31]},e(S,[2,29],{32:32,35:[1,33],37:[1,34]}),{1:[2,7]},e(L,[2,13]),{26:35,31:g},{31:[2,14]},{17:[1,36]},e(w,[2,24]),{10:a,11:37,13:4,14:22,15:f,16:m,19:5,20:6,21:o,22:8,23:9,24:10,25:11,26:12,28:s,29:c,31:g,39:t,43:h,46:x},{30:[1,38]},{41:[1,39]},{41:[1,40]},{45:[1,41]},{48:[1,42]},e(S,[2,30]),{18:[1,43]},{18:[1,44]},e(w,[2,23]),{18:[1,45]},{30:[1,46]},e(b,[2,28]),e(b,[2,35]),e(b,[2,36]),e(b,[2,37]),e(b,[2,38]),{36:[1,47]},{33:48,34:_},{15:[1,50]},e(b,[2,27]),e(S,[2,33]),{38:[1,51]},{33:52,34:_,38:[2,31]},{31:[2,15]},e(S,[2,34]),{38:[2,32]}],defaultActions:{20:[2,7],23:[2,14],50:[2,15],52:[2,32]},parseError:u(function(d,i){if(i.recoverable)this.trace(d);else{var l=new Error(d);throw l.hash=i,l}},"parseError"),parse:u(function(d){var i=this,l=[0],p=[],E=[null],r=[],K=this.table,n="",F=0,Y=0,J=2,V=1,Z=r.slice.call(arguments,1),D=Object.create(this.lexer),z={yy:{}};for(var Q in this.yy)Object.prototype.hasOwnProperty.call(this.yy,Q)&&(z.yy[Q]=this.yy[Q]);D.setInput(d,z.yy),z.yy.lexer=D,z.yy.parser=this,typeof D.yylloc>"u"&&(D.yylloc={});var $=D.yylloc;r.push($);var Re=D.options&&D.options.ranges;typeof z.yy.parseError=="function"?this.parseError=z.yy.parseError:this.parseError=Object.getPrototypeOf(this).parseError;function Pe(I){l.length=l.length-2*I,E.length=E.length-I,r.length=r.length-I}u(Pe,"popStack");function de(){var I;return I=p.pop()||D.lex()||V,typeof I!="number"&&(I instanceof Array&&(p=I,I=p.pop()),I=i.symbols_[I]||I),I}u(de,"lex");for(var N,R,v,ee,M={},U,B,pe,H;;){if(R=l[l.length-1],this.defaultActions[R]?v=this.defaultActions[R]:((N===null||typeof N>"u")&&(N=de()),v=K[R]&&K[R][N]),typeof v>"u"||!v.length||!v[0]){var te="";H=[];for(U in K[R])this.terminals_[U]&&U>J&&H.push("'"+this.terminals_[U]+"'");D.showPosition?te="Parse error on line "+(F+1)+`:
1
+ import{g as Fe}from"./BOaNSc_1.js";import{ap as Me,a5 as xe,ar as Ke,bc as We,bb as Ye,be as Ve,bd as Ue,b9 as He,b7 as Xe,b2 as je,aN as Ge,aF as qe,aE as Je,az as Ze,aj as Qe,ai as $e,ak as et,S as tt,R as st,K as rt,k as it,I as at,f as nt,g as ot,e as ct,b as u,W as P,aW as X,ag as lt,aD as ut,B as ht,ay as y,r as gt,am as dt,aU as pt,ab as ft,x as bt,aT as St,p as xt,X as Le,ae as Lt,af as mt,aK as yt,z as wt,a3 as Et,ah as me,b6 as kt,aL as _t}from"./DwsRDnkS.js";import{G as Dt}from"./-xK_vQQs.js";function Tt(e){return Array.isArray(e)}function Nt(e){if(Me(e))return e;const a=xe(e);if(!It(e))return{};if(Tt(e)){const s=Array.from(e);return e.length>0&&typeof e[0]=="string"&&Object.hasOwn(e,"index")&&(s.index=e.index,s.input=e.input),s}if(Ke(e)){const s=e,c=s.constructor;return new c(s.buffer,s.byteOffset,s.length)}if(a==="[object ArrayBuffer]")return new ArrayBuffer(e.byteLength);if(a==="[object DataView]"){const s=e,c=s.buffer,g=s.byteOffset,t=s.byteLength,h=new ArrayBuffer(t),x=new Uint8Array(c,g,t);return new Uint8Array(h).set(x),new DataView(h)}if(a==="[object Boolean]"||a==="[object Number]"||a==="[object String]"){const s=e.constructor,c=new s(e.valueOf());return a==="[object String]"?Ct(c,e):se(c,e),c}if(a==="[object Date]")return new Date(Number(e));if(a==="[object RegExp]"){const s=e,c=new RegExp(s.source,s.flags);return c.lastIndex=s.lastIndex,c}if(a==="[object Symbol]")return Object(Symbol.prototype.valueOf.call(e));if(a==="[object Map]"){const s=e,c=new Map;return s.forEach((g,t)=>{c.set(t,g)}),c}if(a==="[object Set]"){const s=e,c=new Set;return s.forEach(g=>{c.add(g)}),c}if(a==="[object Arguments]"){const s=e,c={};return se(c,s),c.length=s.length,c[Symbol.iterator]=s[Symbol.iterator],c}const o={};return vt(o,e),se(o,e),Ot(o,e),o}function It(e){switch(xe(e)){case ct:case ot:case nt:case at:case it:case rt:case st:case tt:case et:case $e:case Qe:case Ze:case Je:case qe:case Ge:case je:case Xe:case He:case Ue:case Ve:case Ye:case We:return!0;default:return!1}}function se(e,a){for(const o in a)Object.hasOwn(a,o)&&(e[o]=a[o])}function Ot(e,a){const o=Object.getOwnPropertySymbols(a);for(let s=0;s<o.length;s++){const c=o[s];Object.prototype.propertyIsEnumerable.call(a,c)&&(e[c]=a[c])}}function Ct(e,a){const o=a.valueOf().length;for(const s in a)Object.hasOwn(a,s)&&(Number.isNaN(Number(s))||Number(s)>=o)&&(e[s]=a[s])}function vt(e,a){const o=Object.getPrototypeOf(a);o!==null&&typeof a.constructor=="function"&&Object.setPrototypeOf(e,o)}var ie=(function(){var e=u(function(C,d,i,l){for(i=i||{},l=C.length;l--;i[C[l]]=d);return i},"o"),a=[1,15],o=[1,7],s=[1,13],c=[1,14],g=[1,19],t=[1,16],h=[1,17],x=[1,18],L=[8,30],b=[8,10,21,28,29,30,31,39,43,46],f=[1,23],m=[1,24],w=[8,10,15,16,21,28,29,30,31,39,43,46],S=[8,10,15,16,21,27,28,29,30,31,39,43,46],_=[1,49],k={trace:u(function(){},"trace"),yy:{},symbols_:{error:2,spaceLines:3,SPACELINE:4,NL:5,separator:6,SPACE:7,EOF:8,start:9,BLOCK_DIAGRAM_KEY:10,document:11,stop:12,statement:13,link:14,LINK:15,START_LINK:16,LINK_LABEL:17,STR:18,nodeStatement:19,columnsStatement:20,SPACE_BLOCK:21,blockStatement:22,classDefStatement:23,cssClassStatement:24,styleStatement:25,node:26,SIZE:27,COLUMNS:28,"id-block":29,end:30,NODE_ID:31,nodeShapeNLabel:32,dirList:33,DIR:34,NODE_DSTART:35,NODE_DEND:36,BLOCK_ARROW_START:37,BLOCK_ARROW_END:38,classDef:39,CLASSDEF_ID:40,CLASSDEF_STYLEOPTS:41,DEFAULT:42,class:43,CLASSENTITY_IDS:44,STYLECLASS:45,style:46,STYLE_ENTITY_IDS:47,STYLE_DEFINITION_DATA:48,$accept:0,$end:1},terminals_:{2:"error",4:"SPACELINE",5:"NL",7:"SPACE",8:"EOF",10:"BLOCK_DIAGRAM_KEY",15:"LINK",16:"START_LINK",17:"LINK_LABEL",18:"STR",21:"SPACE_BLOCK",27:"SIZE",28:"COLUMNS",29:"id-block",30:"end",31:"NODE_ID",34:"DIR",35:"NODE_DSTART",36:"NODE_DEND",37:"BLOCK_ARROW_START",38:"BLOCK_ARROW_END",39:"classDef",40:"CLASSDEF_ID",41:"CLASSDEF_STYLEOPTS",42:"DEFAULT",43:"class",44:"CLASSENTITY_IDS",45:"STYLECLASS",46:"style",47:"STYLE_ENTITY_IDS",48:"STYLE_DEFINITION_DATA"},productions_:[0,[3,1],[3,2],[3,2],[6,1],[6,1],[6,1],[9,3],[12,1],[12,1],[12,2],[12,2],[11,1],[11,2],[14,1],[14,4],[13,1],[13,1],[13,1],[13,1],[13,1],[13,1],[13,1],[19,3],[19,2],[19,1],[20,1],[22,4],[22,3],[26,1],[26,2],[33,1],[33,2],[32,3],[32,4],[23,3],[23,3],[24,3],[25,3]],performAction:u(function(d,i,l,p,E,r,K){var n=r.length-1;switch(E){case 4:p.getLogger().debug("Rule: separator (NL) ");break;case 5:p.getLogger().debug("Rule: separator (Space) ");break;case 6:p.getLogger().debug("Rule: separator (EOF) ");break;case 7:p.getLogger().debug("Rule: hierarchy: ",r[n-1]),p.setHierarchy(r[n-1]);break;case 8:p.getLogger().debug("Stop NL ");break;case 9:p.getLogger().debug("Stop EOF ");break;case 10:p.getLogger().debug("Stop NL2 ");break;case 11:p.getLogger().debug("Stop EOF2 ");break;case 12:p.getLogger().debug("Rule: statement: ",r[n]),typeof r[n].length=="number"?this.$=r[n]:this.$=[r[n]];break;case 13:p.getLogger().debug("Rule: statement #2: ",r[n-1]),this.$=[r[n-1]].concat(r[n]);break;case 14:p.getLogger().debug("Rule: link: ",r[n],d),this.$={edgeTypeStr:r[n],label:""};break;case 15:p.getLogger().debug("Rule: LABEL link: ",r[n-3],r[n-1],r[n]),this.$={edgeTypeStr:r[n],label:r[n-1]};break;case 18:const F=parseInt(r[n]),Y=p.generateId();this.$={id:Y,type:"space",label:"",width:F,children:[]};break;case 23:p.getLogger().debug("Rule: (nodeStatement link node) ",r[n-2],r[n-1],r[n]," typestr: ",r[n-1].edgeTypeStr);const J=p.edgeStrToEdgeData(r[n-1].edgeTypeStr),V=p.edgeStrToEdgeStartData(r[n-1].edgeTypeStr),Z=p.edgeStrToThickness(r[n-1].edgeTypeStr),D=p.edgeStrToPattern(r[n-1].edgeTypeStr);this.$=[{id:r[n-2].id,label:r[n-2].label,type:r[n-2].type,directions:r[n-2].directions},{id:r[n-2].id+"-"+r[n].id,start:r[n-2].id,end:r[n].id,label:r[n-1].label,type:"edge",thickness:Z,pattern:D,directions:r[n].directions,arrowTypeEnd:J,arrowTypeStart:V},{id:r[n].id,label:r[n].label,type:p.typeStr2Type(r[n].typeStr),directions:r[n].directions}];break;case 24:p.getLogger().debug("Rule: nodeStatement (abc88 node size) ",r[n-1],r[n]),this.$={id:r[n-1].id,label:r[n-1].label,type:p.typeStr2Type(r[n-1].typeStr),directions:r[n-1].directions,widthInColumns:parseInt(r[n],10)};break;case 25:p.getLogger().debug("Rule: nodeStatement (node) ",r[n]),this.$={id:r[n].id,label:r[n].label,type:p.typeStr2Type(r[n].typeStr),directions:r[n].directions,widthInColumns:1};break;case 26:p.getLogger().debug("APA123",this?this:"na"),p.getLogger().debug("COLUMNS: ",r[n]),this.$={type:"column-setting",columns:r[n]==="auto"?-1:parseInt(r[n])};break;case 27:p.getLogger().debug("Rule: id-block statement : ",r[n-2],r[n-1]),p.generateId(),this.$={...r[n-2],type:"composite",children:r[n-1]};break;case 28:p.getLogger().debug("Rule: blockStatement : ",r[n-2],r[n-1],r[n]);const z=p.generateId();this.$={id:z,type:"composite",label:"",children:r[n-1]};break;case 29:p.getLogger().debug("Rule: node (NODE_ID separator): ",r[n]),this.$={id:r[n]};break;case 30:p.getLogger().debug("Rule: node (NODE_ID nodeShapeNLabel separator): ",r[n-1],r[n]),this.$={id:r[n-1],label:r[n].label,typeStr:r[n].typeStr,directions:r[n].directions};break;case 31:p.getLogger().debug("Rule: dirList: ",r[n]),this.$=[r[n]];break;case 32:p.getLogger().debug("Rule: dirList: ",r[n-1],r[n]),this.$=[r[n-1]].concat(r[n]);break;case 33:p.getLogger().debug("Rule: nodeShapeNLabel: ",r[n-2],r[n-1],r[n]),this.$={typeStr:r[n-2]+r[n],label:r[n-1]};break;case 34:p.getLogger().debug("Rule: BLOCK_ARROW nodeShapeNLabel: ",r[n-3],r[n-2]," #3:",r[n-1],r[n]),this.$={typeStr:r[n-3]+r[n],label:r[n-2],directions:r[n-1]};break;case 35:case 36:this.$={type:"classDef",id:r[n-1].trim(),css:r[n].trim()};break;case 37:this.$={type:"applyClass",id:r[n-1].trim(),styleClass:r[n].trim()};break;case 38:this.$={type:"applyStyles",id:r[n-1].trim(),stylesStr:r[n].trim()};break}},"anonymous"),table:[{9:1,10:[1,2]},{1:[3]},{10:a,11:3,13:4,19:5,20:6,21:o,22:8,23:9,24:10,25:11,26:12,28:s,29:c,31:g,39:t,43:h,46:x},{8:[1,20]},e(L,[2,12],{13:4,19:5,20:6,22:8,23:9,24:10,25:11,26:12,11:21,10:a,21:o,28:s,29:c,31:g,39:t,43:h,46:x}),e(b,[2,16],{14:22,15:f,16:m}),e(b,[2,17]),e(b,[2,18]),e(b,[2,19]),e(b,[2,20]),e(b,[2,21]),e(b,[2,22]),e(w,[2,25],{27:[1,25]}),e(b,[2,26]),{19:26,26:12,31:g},{10:a,11:27,13:4,19:5,20:6,21:o,22:8,23:9,24:10,25:11,26:12,28:s,29:c,31:g,39:t,43:h,46:x},{40:[1,28],42:[1,29]},{44:[1,30]},{47:[1,31]},e(S,[2,29],{32:32,35:[1,33],37:[1,34]}),{1:[2,7]},e(L,[2,13]),{26:35,31:g},{31:[2,14]},{17:[1,36]},e(w,[2,24]),{10:a,11:37,13:4,14:22,15:f,16:m,19:5,20:6,21:o,22:8,23:9,24:10,25:11,26:12,28:s,29:c,31:g,39:t,43:h,46:x},{30:[1,38]},{41:[1,39]},{41:[1,40]},{45:[1,41]},{48:[1,42]},e(S,[2,30]),{18:[1,43]},{18:[1,44]},e(w,[2,23]),{18:[1,45]},{30:[1,46]},e(b,[2,28]),e(b,[2,35]),e(b,[2,36]),e(b,[2,37]),e(b,[2,38]),{36:[1,47]},{33:48,34:_},{15:[1,50]},e(b,[2,27]),e(S,[2,33]),{38:[1,51]},{33:52,34:_,38:[2,31]},{31:[2,15]},e(S,[2,34]),{38:[2,32]}],defaultActions:{20:[2,7],23:[2,14],50:[2,15],52:[2,32]},parseError:u(function(d,i){if(i.recoverable)this.trace(d);else{var l=new Error(d);throw l.hash=i,l}},"parseError"),parse:u(function(d){var i=this,l=[0],p=[],E=[null],r=[],K=this.table,n="",F=0,Y=0,J=2,V=1,Z=r.slice.call(arguments,1),D=Object.create(this.lexer),z={yy:{}};for(var Q in this.yy)Object.prototype.hasOwnProperty.call(this.yy,Q)&&(z.yy[Q]=this.yy[Q]);D.setInput(d,z.yy),z.yy.lexer=D,z.yy.parser=this,typeof D.yylloc>"u"&&(D.yylloc={});var $=D.yylloc;r.push($);var Re=D.options&&D.options.ranges;typeof z.yy.parseError=="function"?this.parseError=z.yy.parseError:this.parseError=Object.getPrototypeOf(this).parseError;function Pe(I){l.length=l.length-2*I,E.length=E.length-I,r.length=r.length-I}u(Pe,"popStack");function de(){var I;return I=p.pop()||D.lex()||V,typeof I!="number"&&(I instanceof Array&&(p=I,I=p.pop()),I=i.symbols_[I]||I),I}u(de,"lex");for(var N,R,v,ee,M={},U,B,pe,H;;){if(R=l[l.length-1],this.defaultActions[R]?v=this.defaultActions[R]:((N===null||typeof N>"u")&&(N=de()),v=K[R]&&K[R][N]),typeof v>"u"||!v.length||!v[0]){var te="";H=[];for(U in K[R])this.terminals_[U]&&U>J&&H.push("'"+this.terminals_[U]+"'");D.showPosition?te="Parse error on line "+(F+1)+`:
2
2
  `+D.showPosition()+`
3
3
  Expecting `+H.join(", ")+", got '"+(this.terminals_[N]||N)+"'":te="Parse error on line "+(F+1)+": Unexpected "+(N==V?"end of input":"'"+(this.terminals_[N]||N)+"'"),this.parseError(te,{text:D.match,token:this.terminals_[N]||N,line:D.yylineno,loc:$,expected:H})}if(v[0]instanceof Array&&v.length>1)throw new Error("Parse Error: multiple actions possible at state: "+R+", token: "+N);switch(v[0]){case 1:l.push(N),E.push(D.yytext),r.push(D.yylloc),l.push(v[1]),N=null,Y=D.yyleng,n=D.yytext,F=D.yylineno,$=D.yylloc;break;case 2:if(B=this.productions_[v[1]][1],M.$=E[E.length-B],M._$={first_line:r[r.length-(B||1)].first_line,last_line:r[r.length-1].last_line,first_column:r[r.length-(B||1)].first_column,last_column:r[r.length-1].last_column},Re&&(M._$.range=[r[r.length-(B||1)].range[0],r[r.length-1].range[1]]),ee=this.performAction.apply(M,[n,Y,F,z.yy,v[1],E,r].concat(Z)),typeof ee<"u")return ee;B&&(l=l.slice(0,-1*B*2),E=E.slice(0,-1*B),r=r.slice(0,-1*B)),l.push(this.productions_[v[1]][0]),E.push(M.$),r.push(M._$),pe=K[l[l.length-2]][l[l.length-1]],l.push(pe);break;case 3:return!0}}return!0},"parse")},T=(function(){var C={EOF:1,parseError:u(function(i,l){if(this.yy.parser)this.yy.parser.parseError(i,l);else throw new Error(i)},"parseError"),setInput:u(function(d,i){return this.yy=i||this.yy||{},this._input=d,this._more=this._backtrack=this.done=!1,this.yylineno=this.yyleng=0,this.yytext=this.matched=this.match="",this.conditionStack=["INITIAL"],this.yylloc={first_line:1,first_column:0,last_line:1,last_column:0},this.options.ranges&&(this.yylloc.range=[0,0]),this.offset=0,this},"setInput"),input:u(function(){var d=this._input[0];this.yytext+=d,this.yyleng++,this.offset++,this.match+=d,this.matched+=d;var i=d.match(/(?:\r\n?|\n).*/g);return i?(this.yylineno++,this.yylloc.last_line++):this.yylloc.last_column++,this.options.ranges&&this.yylloc.range[1]++,this._input=this._input.slice(1),d},"input"),unput:u(function(d){var i=d.length,l=d.split(/(?:\r\n?|\n)/g);this._input=d+this._input,this.yytext=this.yytext.substr(0,this.yytext.length-i),this.offset-=i;var p=this.match.split(/(?:\r\n?|\n)/g);this.match=this.match.substr(0,this.match.length-1),this.matched=this.matched.substr(0,this.matched.length-1),l.length-1&&(this.yylineno-=l.length-1);var E=this.yylloc.range;return this.yylloc={first_line:this.yylloc.first_line,last_line:this.yylineno+1,first_column:this.yylloc.first_column,last_column:l?(l.length===p.length?this.yylloc.first_column:0)+p[p.length-l.length].length-l[0].length:this.yylloc.first_column-i},this.options.ranges&&(this.yylloc.range=[E[0],E[0]+this.yyleng-i]),this.yyleng=this.yytext.length,this},"unput"),more:u(function(){return this._more=!0,this},"more"),reject:u(function(){if(this.options.backtrack_lexer)this._backtrack=!0;else return this.parseError("Lexical error on line "+(this.yylineno+1)+`. You can only invoke reject() in the lexer when the lexer is of the backtracking persuasion (options.backtrack_lexer = true).
4
4
  `+this.showPosition(),{text:"",token:null,line:this.yylineno});return this},"reject"),less:u(function(d){this.unput(this.match.slice(d))},"less"),pastInput:u(function(){var d=this.matched.substr(0,this.matched.length-this.match.length);return(d.length>20?"...":"")+d.substr(-20).replace(/\n/g,"")},"pastInput"),upcomingInput:u(function(){var d=this.match;return d.length<20&&(d+=this._input.substr(0,20-d.length)),(d.substr(0,20)+(d.length>20?"...":"")).replace(/\n/g,"")},"upcomingInput"),showPosition:u(function(){var d=this.pastInput(),i=new Array(d.length+1).join("-");return d+this.upcomingInput()+`
@@ -1 +1 @@
1
- import{t as Ye,bq as h,a_ as M,by as Ze,b as $e,bs as nt,bo as k,bu as Xe}from"./DozYGPQ1.js";import{bo as st,bs as et,a7 as H,ay as y,aD as e,bS as L,W as c,a5 as Pe,bA as De,bH as X,bl as _e,b_ as oe,bO as de,bn as tt,bf as je,bV as Ee,aA as v,c9 as w,aB as U,be as it,b$ as lt,bj as dt,cd as ct,ca as Ve,bk as ut}from"./DYhIMPy1.js";import{i as G}from"./7z2H_RtS.js";import{HQ as He,mF as pt,t_ as ft}from"./DYepVMa7.js";import{b1 as ht}from"./OvSKCwS-.js";import{ck as vt}from"./SrOLwB5L.js";import{c as gt}from"./ChTqQfQN.js";import{i as Le,t as Ue}from"./H2jLkRRS.js";import{v as _t}from"./BBvT7Bb8.js";import{d as mt}from"./B0Z-1lwJ.js";import{F as Re,av as bt,aw as kt,cQ as Je,aX as qe,be as wt,an as yt,am as At,cN as Ge}from"./CpEHCOut.js";import{n as Q,w as Ft}from"./4o1DPfmL.js";import{h as Wt,s as Ne,k as xe,a as Te,d as Ct}from"./CBE9bOjQ.js";import{s as xt}from"./B30Ssr1r.js";import{f as It,ai as Pt,aX as Dt}from"./DkrIcKd4.js";import"./CnlzKY2y.js";import{c as K}from"./MJGmlCLu.js";import{a as Mt,r as Et}from"./C0HDG-tg.js";import{M as Ot,m as Be,t as ze}from"./D_FHOcPH.js";import{o as Qe,r as St,q as Rt,R as Nt,p as Tt,n as Bt,j as zt,l as Xt}from"./Dlalsrb2.js";var jt=U('<img alt="" class="size-4"/>'),Vt=U('<span class="min-w-0 flex-1 text-left"><span class="block truncate"> </span> <span class="block text-muted-foreground" aria-hidden="true" data-menu-action-reason=""> </span></span>'),Ht=U("<span> </span>"),Lt=U('<span data-menu-action-detail=""> </span>'),Ut=U('<span aria-hidden="true"><!></span>'),Ke=U("<!> <!> <!>",1),Jt=U('<div class="my-1 h-px bg-border" role="separator"></div>'),Me=U("<!> <!>",1),qt=U('<!> <p data-menu-action-note=""> </p>',1),Gt=U('<span class="flex size-4 shrink-0 items-center justify-center" aria-hidden="true"><!></span> <!> <!>',1),Qt=U('<p data-menu-action-note=""> </p>'),Kt=U('<div class="pl-4"><!> <!></div>'),Yt=U('<span class="sr-only"> </span>');function me(be,d){const ke=st();if(new.target)return Ye({component:me,...be});et(d,!0);const Ie=(p,r=je)=>{var O=H(),S=y(O);{var j=W=>{const x=w(()=>Mt(r().editor));var V=H(),m=y(V);{var f=s=>{var i=jt();oe(()=>Ne(i,"src",`data:image/png;base64,${r().editor.iconBase64??""}`)),c(s,i)},o=s=>{var i=H(),b=y(i);K(b,()=>e(x),(T,ae)=>{ae(T,{size:16})}),c(s,i)},N=s=>{{let i=w(()=>Et(r().editor.category));Re(s,{get icon(){return e(i)},size:16})}};M(m,s=>{r().editor.iconBase64?s(f):e(x)?s(o,1):s(N,-1)})}c(W,V)},R=W=>{var x=H(),V=y(x);xt(V,()=>r().iconSnippet),c(W,x)},q=W=>{{let x=w(()=>r().variant==="destructive"?"text-current":"text-muted-foreground");Re(W,{get icon(){return r().icon},get weight(){return J()},size:16,get class(){return e(x)}})}};M(S,W=>{r().editor?W(j):r().iconSnippet?W(R,1):r().icon&&W(q,2)})}c(p,O)},ne=(p,r=je)=>{var O=Ke(),S=y(O);{var j=m=>{var f=Vt(),o=Pe(f),N=_e(o,!0);Te(o,(b,T)=>ze?.(b,T),()=>r().label);var s=L(o,2),i=_e(s,!0);De(f),oe(()=>{de(N,r().label),de(i,r().disabledReason)}),c(m,f)},R=m=>{var f=Ht(),o=_e(f,!0);Te(f,(N,s)=>ze?.(N,s),()=>r().label),oe(()=>{xe(f,1,`min-w-0 truncate text-left ${r().detail?"flex-[1_0_auto]":"flex-1"}`),de(o,r().label)}),c(m,f)};M(S,m=>{r().disabledReason?m(j):m(R,-1)})}var q=L(S,2);{var W=m=>{var f=Lt(),o=_e(f,!0);Te(f,(N,s)=>ze?.(N,s),()=>r().detail),oe(()=>{xe(f,1,`ml-4 min-w-0 truncate ${(r().detailTone==="danger"?"text-danger":Be)??""}`),de(o,r().detail)}),c(m,f)};M(q,m=>{r().detail&&m(W)})}var x=L(q,2);{var V=m=>{var f=Ut(),o=Pe(f);Pt(o,{children:(N,s)=>{it();var i=lt();oe(b=>de(i,b),[()=>Dt(r().shortcut)]),c(N,i)},$$slots:{default:!0}}),De(f),oe(()=>xe(f,1,Ct(E()?"ml-4 flex h-lh shrink-0 items-center":"ml-4"))),c(m,f)};M(x,m=>{r().shortcut&&m(V)})}c(p,O)};let we=h(d,"actions",7),E=h(d,"menu",7),J=h(d,"iconWeight",7),u=h(d,"onClose",7),A=h(d,"selection",7),F=Ee(null);function Y(p){p.disabled||p.disabledReason!==void 0||(p.onClick(),u()?.())}var ce={get actions(){return we()},set actions(p){we(p),v()},get menu(){return E()},set menu(p){E(p),v()},get iconWeight(){return J()},set iconWeight(p){J(p),v()},get onClose(){return u()},set onClose(p){u(p),v()},get selection(){return A()},set selection(p){A(p),v()},$set:Ze,$on:(p,r)=>$e(d,p,r)},se=H(),ie=y(se);return Wt(ie,17,we,p=>p.id,(p,r)=>{const O=i=>{Ie(i,()=>e(r))},S=w(()=>!!(e(r).editor||e(r).iconSnippet||e(r).icon)),j=w(()=>e(r).disabled||e(r).disabledReason!==void 0),R=w(()=>e(r).disabledReason?`${ke}-${e(r).id}-reason`:void 0);var q=Ke(),W=y(q);{var x=i=>{var b=H(),T=y(b);{var ae=a=>{var n=H(),g=y(n);K(g,()=>Qe,(C,P)=>{P(C,{})}),c(a,n)},ue=a=>{var n=Jt();c(a,n)};M(T,a=>{E()?a(ae):a(ue,-1)})}c(i,b)};M(W,i=>{e(r).dividerBefore&&i(x)})}var V=L(W,2);{var m=i=>{var b=H(),T=y(b);{var ae=g=>{var C=H(),P=y(C);K(P,()=>Tt,(I,D)=>{D(I,{children:(B,Z)=>{var $=Me(),pe=y($);{let te=w(()=>e(S)?O:void 0);K(pe,()=>St,(fe,he)=>{he(fe,{get leading(){return e(te)},get disabled(){return e(j)},get"aria-describedby"(){return e(R)},get"data-action-id"(){return e(r).id},children:(ve,ye)=>{ne(ve,()=>e(r))},$$slots:{default:!0}})})}var ee=L(pe,2);{let te=w(()=>e(r).note?`${ke}-${e(r).id}-note`:void 0);K(ee,()=>Rt,(fe,he)=>{he(fe,{class:"w-60",get"aria-describedby"(){return e(te)},children:(ve,ye)=>{var t=Me(),l=y(t);{var _=re=>{var Ae=Me(),Fe=y(Ae);{let Ce=w(()=>e(r).submenu.find(ge=>ge.checked)?.id??"");K(Fe,()=>Nt,(ge,Se)=>{Se(ge,{get value(){return e(Ce)},get"aria-label"(){return e(r).label},children:(rt,$t)=>{{let at=w(()=>e(r).submenu.filter(ot=>ot.checked!==void 0));me(rt,{get actions(){return e(at)},selection:"single",get menu(){return E()},get iconWeight(){return J()},get onClose(){return u()}})}},$$slots:{default:!0}})})}var We=L(Fe,2);{let Ce=w(()=>e(r).submenu.filter(ge=>ge.checked===void 0));me(We,{get actions(){return e(Ce)},get menu(){return E()},get iconWeight(){return J()},get onClose(){return u()}})}c(re,Ae)},z=re=>{me(re,{get actions(){return e(r).submenu},get menu(){return E()},get iconWeight(){return J()},get onClose(){return u()}})};M(l,re=>{e(r).selection==="single"?re(_):re(z,-1)})}var le=L(l,2);{var Oe=re=>{var Ae=qt(),Fe=y(Ae);K(Fe,()=>Qe,(ge,Se)=>{Se(ge,{})});var We=L(Fe,2),Ce=_e(We,!0);oe(()=>{Ne(We,"id",`${ke}-${e(r).id}-note`),xe(We,1,`type-caption px-2 py-1 ${Be}`),de(Ce,e(r).note)}),c(re,Ae)};M(le,re=>{e(r).note&&re(Oe)})}c(ve,t)},$$slots:{default:!0}})})}c(B,$)},$$slots:{default:!0}})}),c(g,C)},ue=g=>{var C=H(),P=y(C);{let I=w(()=>e(S)?O:void 0);K(P,()=>Bt,(D,B)=>{B(D,{get leading(){return e(I)},get value(){return e(r).id},get disabled(){return e(j)},get"aria-describedby"(){return e(R)},closeOnSelect:!0,onSelect:()=>Y(e(r)),get"data-action-id"(){return e(r).id},children:(Z,$)=>{ne(Z,()=>e(r))},$$slots:{default:!0}})})}c(g,C)},a=g=>{var C=H(),P=y(C);{let I=w(()=>e(S)?O:void 0);K(P,()=>zt,(D,B)=>{B(D,{get leading(){return e(I)},get checked(){return e(r).checked},get disabled(){return e(j)},get"aria-describedby"(){return e(R)},closeOnSelect:!0,onSelect:()=>Y(e(r)),get"data-action-id"(){return e(r).id},children:(Z,$)=>{ne(Z,()=>e(r))},$$slots:{default:!0}})})}c(g,C)},n=g=>{var C=H(),P=y(C);{let I=w(()=>e(S)?O:void 0),D=w(()=>e(r).variant==="destructive");K(P,()=>Xt,(B,Z)=>{Z(B,{get leading(){return e(I)},get destructive(){return e(D)},get disabled(){return e(j)},get"aria-describedby"(){return e(R)},onSelect:()=>Y(e(r)),get"data-action-id"(){return e(r).id},children:($,pe)=>{ne($,()=>e(r))},$$slots:{default:!0}})})}c(g,C)};M(T,g=>{e(r).submenu?g(ae):A()==="single"&&e(r).checked!==void 0?g(ue,1):e(r).checked!==void 0?g(a,2):g(n,-1)})}c(i,b)},f=i=>{me(i,{get actions(){return e(r).submenu},get menu(){return E()},get iconWeight(){return J()},get onClose(){return u()}})},o=i=>{var b=Me(),T=y(b);{let a=w(()=>e(r).variant==="destructive"?"text-danger hover:text-danger":""),n=w(()=>e(r).submenu?e(F)===e(r).id:void 0);It(T,{variant:"ghost",size:"sm",get class(){return`w-full justify-start gap-2 ${e(a)??""}`},get disabled(){return e(j)},get"aria-describedby"(){return e(R)},get"aria-expanded"(){return e(n)},onclick:()=>e(r).submenu?X(F,e(F)===e(r).id?null:e(r).id,!0):Y(e(r)),children:(g,C)=>{var P=Gt(),I=y(P),D=Pe(I);Ie(D,()=>e(r)),De(I);var B=L(I,2);ne(B,()=>e(r));var Z=L(B,2);{var $=ee=>{{let te=w(()=>e(F)===e(r).id?bt:kt);Re(ee,{get icon(){return e(te)},size:12})}},pe=ee=>{var te=H(),fe=y(te);{let he=w(()=>e(r).checked?"checked":"empty");K(fe,()=>Ot,(ve,ye)=>{ye(ve,{get state(){return e(he)}})})}c(ee,te)};M(Z,ee=>{e(r).submenu?ee($):e(r).checked!==void 0&&ee(pe,1)})}c(g,P)},$$slots:{default:!0}})}var ae=L(T,2);{var ue=a=>{var n=Kt(),g=Pe(n);me(g,{get actions(){return e(r).submenu},get menu(){return E()},get iconWeight(){return J()},get onClose(){return u()}});var C=L(g,2);{var P=I=>{var D=Qt(),B=_e(D,!0);oe(()=>{xe(D,1,`type-caption px-2 py-1 ${Be}`),de(B,e(r).note)}),c(I,D)};M(C,I=>{e(r).note&&I(P)})}De(n),c(a,n)};M(ae,a=>{e(r).submenu&&e(F)===e(r).id&&a(ue)})}c(i,b)};M(V,i=>{E()?i(m):e(r).id==="open-in"&&e(r).submenu?i(f,1):i(o,-1)})}var N=L(V,2);{var s=i=>{var b=Yt(),T=_e(b,!0);oe(()=>{Ne(b,"id",e(R)),de(T,e(r).disabledReason)}),c(i,b)};M(N,i=>{e(r).disabledReason&&i(s)})}c(p,q)}),c(be,se),tt(ce)}function Zt(be,d){if(new.target)return Ye({component:Zt,...be});et(d,!0);const ke=()=>Xe(T,"$installedEditors$",ne),Ie=()=>Xe(ue,"$isWorkspaceHostLocal$",ne),[ne,we]=nt();let E=h(d,"layout",7,"list"),J=h(d,"iconWeight",7),u=h(d,"filePath",7,""),A=h(d,"workspaceId",7,""),F=h(d,"isDirectory",7,!0),Y=h(d,"onDelete",7,void 0),ce=h(d,"onArchive",7,void 0),se=h(d,"onUnarchive",7,void 0),ie=h(d,"isArchived",7,!1),p=h(d,"onClose",7,void 0),r=h(d,"showDeleteOption",7,!0),O=h(d,"showArchiveOption",7,!1),S=h(d,"showPathCopy",7,!0),j=h(d,"showFileNameCopy",7,!1),R=h(d,"showFileActions",7,!0),q=h(d,"workspaceFolderPath",7,""),W=h(d,"isDiff",7,!1),x=h(d,"isWorkspaceRoot",7,!1),V=h(d,"additionalActions",23,()=>[]),m=h(d,"showDeleteFileOption",7,!1),f=h(d,"onFileDeleted",7,void 0);const o=gt("WorkspaceActionsMenu");let N=!1;dt(()=>{N=!0});function s(){N||p()?.()}const i=_t("externalEditors"),b=ct(A());Ve(()=>{b.set(A())});const T=ht(b),ae=w(ke),ue=vt(b);let a=Ee(""),n=Ee(""),g=Ee(!1);ut(()=>{He.dispatch(pt())}),Ve(()=>{u()&&A()?G("workspace:get",{id:A()}).then(t=>{if(t&&t.success&&t.data){const l=t.data,_=l.worktreePath||l.repositoryPath||l.path,z=q()==="__WORKSPACE_ROOT__"?_:q()||_;if(z){const le=z.replace(/\\/g,"/");x()?X(a,le,!0):Le(u())?X(a,u().replace(/\\/g,"/"),!0):X(a,`${le}/${u()}`.replace(/\/+/g,"/"),!0),X(n,le,!0),o.info("[WorkspaceActionsMenu] Resolved file path:",{filePath:u(),workspacePath:z,resolvedPath:e(a)})}else X(a,u()),X(n,""),l.status!=="archived"&&l.status!=="deleted"&&o.warn("[WorkspaceActionsMenu] No workspace path found:",l)}else X(a,u()),X(n,""),t?.error&&!t.error.includes("not found")&&o.warn("[WorkspaceActionsMenu] Workspace not available:",t)}).catch(t=>{X(a,u()),X(n,""),t?.message?.includes("not found")||o.error("[WorkspaceActionsMenu] Failed to resolve path:",t)}):(X(a,u()),o.info("[WorkspaceActionsMenu] Using filePath directly:",{filePath:u(),workspaceId:A()}))});async function C(){if(!e(a)){o.warn("[WorkspaceActionsMenu] No resolved path for VSCode");return}try{if(W()&&!F()){o.info("[WorkspaceActionsMenu] Opening diff in VSCode:",{resolvedPath:e(a)}),await G("vscode:open-git-diff",{filePath:e(a),workspacePath:e(n)||void 0}),s();return}let t=e(a);if(e(n))!F()&&!x()?t={folder:e(n),file:e(a)}:t=e(n);else if(!F()){const l=e(a).includes("\\")?"\\":"/",_=e(a).split(l);_.length>1&&(t={folder:_.slice(0,-1).join(l),file:e(a)})}await G("vscode:open",t),s()}catch(t){o.error("Failed to open in VSCode:",t),Q.error(t instanceof Error?t.message:k.ui_workspaceActions_openFailed_error({name:"VS Code"}))}}async function P(){if(!e(a)){o.warn("[WorkspaceActionsMenu] No resolved path for JetBrains");return}try{let t=e(a);e(n)&&!F()?t={folder:e(n),file:e(a)}:e(n)&&(t=e(n)),await G("jetbrains:open",t),s()}catch(t){o.error("Failed to open in JetBrains:",t),Q.error(t instanceof Error?t.message:k.ui_workspaceActions_openFailed_error({name:"JetBrains"}))}}async function I(){if(!e(a)){o.warn("[WorkspaceActionsMenu] No resolved path for Xcode");return}try{if(A()&&e(n)){He.dispatch(ft(A(),e(n),F()?void 0:e(a))),s();return}let t=e(a);e(n)&&!F()?t={folder:e(n),file:e(a)}:e(n)&&(t={folder:e(n)}),await G("xcode:open",t),s()}catch(t){o.error("Failed to open in Xcode:",t),Q.error(t instanceof Error?t.message:k.ui_workspaceActions_openFailed_error({name:"Xcode"}))}}async function D(t){if(o.info("[WorkspaceActionsMenu] openInEditor called",{editorId:t.id,appName:t.appName,handlerType:t.handlerType,resolvedPath:e(a),isDirectory:F()}),!e(a)){o.warn("[WorkspaceActionsMenu] openInEditor: No resolved path, aborting");return}const l=F()?e(a):e(a).substring(0,e(a).lastIndexOf("/"));o.info(`[WorkspaceActionsMenu] openInEditor: targetPath=${l}, handlerType=${t.handlerType}`);try{switch(t.handlerType){case"finder":o.info("[WorkspaceActionsMenu] openInEditor: Invoking shell:showItemInFolder"),await G("shell:showItemInFolder",{path:l});break;case"vscode":o.info("[WorkspaceActionsMenu] openInEditor: Delegating to openInVSCode"),await C();return;case"jetbrains":o.info("[WorkspaceActionsMenu] openInEditor: Delegating to openInJetBrains"),await P();return;case"xcode":o.info("[WorkspaceActionsMenu] openInEditor: Delegating to openInXcode"),await I();return;case"generic":default:{o.info(`[WorkspaceActionsMenu] openInEditor: Invoking external-editors:open for ${t.id}`);const _=await G("external-editors:open",{editorId:t.id,path:l});o.info("[WorkspaceActionsMenu] openInEditor: external-editors:open result",_);break}}s()}catch(_){o.error(`[WorkspaceActionsMenu] Failed to open in ${t.appName}:`,_),Q.error(_ instanceof Error?_.message:k.ui_workspaceActions_openFailed_error({name:t.appName}))}}async function B(){if(!e(a)){o.warn("No resolved path for openWithOther");return}try{let t=e(a);F()&&e(n)&&(t=e(n));const l=await G("external-editors:open-with-other",{path:t});if(!l?.success){l?.error!=="No application selected"&&(o.error("Failed to open with other app:",l?.error),Q.error(l?.error||k.ui_workspaceActions_openOtherFailed_error()));return}s()}catch(t){o.error("Failed to open with other app:",t),Q.error(t instanceof Error?t.message:k.ui_workspaceActions_openOtherFailed_error())}}async function Z(){if(e(a))try{await navigator.clipboard.writeText(Ue(e(a))),s()}catch(t){o.error("Failed to copy path:",t)}}async function $(){if(u())try{let t=u().replace(/\\/g,"/");if(Le(u())&&e(n)){const l=e(n).endsWith("/")?e(n):e(n)+"/";t.startsWith(l)&&(t=t.slice(l.length))}await navigator.clipboard.writeText(Ue(t)),s()}catch(t){o.error("Failed to copy workspace path:",t)}}async function pe(){if(u())try{const t=u().split(/[/\\]/).pop()||"";await navigator.clipboard.writeText(t),s()}catch(t){o.error("Failed to copy file name:",t)}}function ee(){Y()&&(Y()(),s())}async function te(){if(!(!A()||!e(a)||e(g))){X(g,!0);try{const t=u().split(/[/\\]/).pop()||"file",l=e(a);let _="";try{_=(await G("file:read",{path:l,workspaceId:A()}))?.data?.content??""}catch{}const z=await G("file:delete",{path:l,workspaceId:A()});if(z?.success){f()?.(),s();const le=Q.warning(k.ui_workspaceActions_deletedFile_label({name:t}),Ft({duration:15e3,action:{label:k.ui_workspaceActions_undo_label(),onClick:async()=>{try{await G("file:write",{path:l,content:_,workspaceId:A()}),mt("file:changed",{workspaceId:A(),type:"create",filePath:l}),Q.dismiss(le)}catch(Oe){o.error("[WorkspaceActionsMenu] Failed to restore file",Oe),Q.error(k.ui_workspaceActions_restoreFileFailed_error())}}}}))}else Q.error(k.ui_workspaceActions_deleteFileFailedDetail_error({error:z?.error||k.ui_workspaceActions_unknown_error()}))}catch(t){o.error("[WorkspaceActionsMenu] Error deleting file",t),Q.error(k.ui_workspaceActions_deleteFileFailed_error())}finally{X(g,!1)}}}function fe(){ie()&&se()?(se()(),s()):!ie()&&ce()&&(ce()(),s())}const he=w(()=>{const t=[];R()&&(i&&Ie()&&t.push({id:"open-in",label:k.ui_openCombo_openInApp_tooltip(),icon:Je,onClick:()=>{},submenu:[...e(ae).map(_=>({id:`editor:${_.id}`,label:k.ui_workspaceActions_openIn_label({name:_.name}),editor:_,onClick:()=>{D(_)}})),{id:"choose-app",label:k.ui_workspaceActions_chooseApp_label(),icon:Je,onClick:()=>{B()}}]}),S()&&t.push({id:"copy-absolute-path",label:k.ui_workspaceActions_copyAbsolutePath_label(),icon:qe,disabled:!e(a),dividerBefore:t.length>0,onClick:()=>{Z()}}),S()&&!x()&&t.push({id:"copy-relative-path",label:k.ui_workspaceActions_copyRelativePath_label(),icon:qe,disabled:!u(),onClick:()=>{$()}}),j()&&!F()&&t.push({id:"copy-file-name",label:k.ui_workspaceActions_copyFileName_label(),icon:wt,disabled:!u(),onClick:()=>{pe()}}));const l=_=>_.map(z=>({...z,submenu:z.submenu?l(z.submenu):void 0,onClick:()=>{z.onClick(),s()}}));return t.push(...l(V())),O()&&(ce()||se())&&t.push({id:"archive-workspace",label:ie()?k.ui_workspaceActions_unarchiveSpace_label():k.ui_workspaceActions_archiveSpace_label(),icon:ie()?yt:At,dividerBefore:t.length>0,onClick:fe}),r()&&Y()&&t.push({id:"delete-workspace",label:k.ui_workspaceActions_deleteSpace_label(),icon:Ge,variant:"destructive",dividerBefore:t.length>0&&t.at(-1)?.id!=="archive-workspace",onClick:ee}),m()&&!F()&&t.push({id:"delete-file",label:k.ui_workspaceActions_deleteFile_label(),icon:Ge,variant:"destructive",disabled:e(g)||!e(a)||!A(),dividerBefore:t.length>0,onClick:()=>{te()}}),t});var ve={get layout(){return E()},set layout(t="list"){E(t),v()},get iconWeight(){return J()},set iconWeight(t){J(t),v()},get filePath(){return u()},set filePath(t=""){u(t),v()},get workspaceId(){return A()},set workspaceId(t=""){A(t),v()},get isDirectory(){return F()},set isDirectory(t=!0){F(t),v()},get onDelete(){return Y()},set onDelete(t=void 0){Y(t),v()},get onArchive(){return ce()},set onArchive(t=void 0){ce(t),v()},get onUnarchive(){return se()},set onUnarchive(t=void 0){se(t),v()},get isArchived(){return ie()},set isArchived(t=!1){ie(t),v()},get onClose(){return p()},set onClose(t=void 0){p(t),v()},get showDeleteOption(){return r()},set showDeleteOption(t=!0){r(t),v()},get showArchiveOption(){return O()},set showArchiveOption(t=!1){O(t),v()},get showPathCopy(){return S()},set showPathCopy(t=!0){S(t),v()},get showFileNameCopy(){return j()},set showFileNameCopy(t=!1){j(t),v()},get showFileActions(){return R()},set showFileActions(t=!0){R(t),v()},get workspaceFolderPath(){return q()},set workspaceFolderPath(t=""){q(t),v()},get isDiff(){return W()},set isDiff(t=!1){W(t),v()},get isWorkspaceRoot(){return x()},set isWorkspaceRoot(t=!1){x(t),v()},get additionalActions(){return V()},set additionalActions(t=[]){V(t),v()},get showDeleteFileOption(){return m()},set showDeleteFileOption(t=!1){m(t),v()},get onFileDeleted(){return f()},set onFileDeleted(t=void 0){f(t),v()},$set:Ze,$on:(t,l)=>$e(d,t,l)};{let t=w(()=>E()!=="list");me(be,{get actions(){return e(he)},get menu(){return e(t)},get iconWeight(){return J()}})}var ye=tt(ve);return we(),ye}export{Zt as default};
1
+ import{t as Ye,bq as h,a_ as M,by as Ze,b as $e,bs as nt,bo as k,bu as Xe}from"./eK7OULll.js";import{bo as st,bs as et,a7 as H,ay as y,aD as e,bS as L,W as c,a5 as Pe,bA as De,bH as X,bl as _e,b_ as oe,bO as de,bn as tt,bf as je,bV as Ee,aA as v,c9 as w,aB as U,be as it,b$ as lt,bj as dt,cd as ct,ca as Ve,bk as ut}from"./DYhIMPy1.js";import{i as G}from"./CCnP87Jb.js";import{HR as He,mF as pt,t_ as ft}from"./Bo4s1kgI.js";import{b1 as ht}from"./z3QVK190.js";import{ck as vt}from"./C-RJDuZ9.js";import{c as gt}from"./ChTqQfQN.js";import{i as Le,t as Ue}from"./H2jLkRRS.js";import{v as _t}from"./Dix9BiYu.js";import{d as mt}from"./B0Z-1lwJ.js";import{F as Re,av as bt,aw as kt,cQ as Je,aX as qe,be as wt,an as yt,am as At,cN as Ge}from"./B0JWnOsx.js";import{n as K,w as Ft}from"./-x_SoK5J.js";import{h as Wt,s as Ne,k as xe,a as Te,d as Ct}from"./DZtstCLQ.js";import{s as xt}from"./p5gLe3PS.js";import{f as It,ai as Pt,aX as Dt}from"./CVjlpAWj.js";import"./dmSYAakE.js";import{c as Q}from"./DFcwI6Rh.js";import{a as Mt,r as Et}from"./BS5yagDq.js";import{M as Ot,m as Be,t as ze}from"./Bok30zBH.js";import{o as Ke,r as St,q as Rt,R as Nt,p as Tt,n as Bt,j as zt,l as Xt}from"./w6mFE4SD.js";var jt=U('<img alt="" class="size-4"/>'),Vt=U('<span class="min-w-0 flex-1 text-left"><span class="block truncate"> </span> <span class="block text-muted-foreground" aria-hidden="true" data-menu-action-reason=""> </span></span>'),Ht=U("<span> </span>"),Lt=U('<span data-menu-action-detail=""> </span>'),Ut=U('<span aria-hidden="true"><!></span>'),Qe=U("<!> <!> <!>",1),Jt=U('<div class="my-1 h-px bg-border" role="separator"></div>'),Me=U("<!> <!>",1),qt=U('<!> <p data-menu-action-note=""> </p>',1),Gt=U('<span class="flex size-4 shrink-0 items-center justify-center" aria-hidden="true"><!></span> <!> <!>',1),Kt=U('<p data-menu-action-note=""> </p>'),Qt=U('<div class="pl-4"><!> <!></div>'),Yt=U('<span class="sr-only"> </span>');function me(be,d){const ke=st();if(new.target)return Ye({component:me,...be});et(d,!0);const Ie=(p,r=je)=>{var O=H(),S=y(O);{var j=W=>{const x=w(()=>Mt(r().editor));var V=H(),m=y(V);{var f=s=>{var i=jt();oe(()=>Ne(i,"src",`data:image/png;base64,${r().editor.iconBase64??""}`)),c(s,i)},o=s=>{var i=H(),b=y(i);Q(b,()=>e(x),(T,ae)=>{ae(T,{size:16})}),c(s,i)},N=s=>{{let i=w(()=>Et(r().editor.category));Re(s,{get icon(){return e(i)},size:16})}};M(m,s=>{r().editor.iconBase64?s(f):e(x)?s(o,1):s(N,-1)})}c(W,V)},R=W=>{var x=H(),V=y(x);xt(V,()=>r().iconSnippet),c(W,x)},q=W=>{{let x=w(()=>r().variant==="destructive"?"text-current":"text-muted-foreground");Re(W,{get icon(){return r().icon},get weight(){return J()},size:16,get class(){return e(x)}})}};M(S,W=>{r().editor?W(j):r().iconSnippet?W(R,1):r().icon&&W(q,2)})}c(p,O)},ne=(p,r=je)=>{var O=Qe(),S=y(O);{var j=m=>{var f=Vt(),o=Pe(f),N=_e(o,!0);Te(o,(b,T)=>ze?.(b,T),()=>r().label);var s=L(o,2),i=_e(s,!0);De(f),oe(()=>{de(N,r().label),de(i,r().disabledReason)}),c(m,f)},R=m=>{var f=Ht(),o=_e(f,!0);Te(f,(N,s)=>ze?.(N,s),()=>r().label),oe(()=>{xe(f,1,`min-w-0 truncate text-left ${r().detail?"flex-[1_0_auto]":"flex-1"}`),de(o,r().label)}),c(m,f)};M(S,m=>{r().disabledReason?m(j):m(R,-1)})}var q=L(S,2);{var W=m=>{var f=Lt(),o=_e(f,!0);Te(f,(N,s)=>ze?.(N,s),()=>r().detail),oe(()=>{xe(f,1,`ml-4 min-w-0 truncate ${(r().detailTone==="danger"?"text-danger":Be)??""}`),de(o,r().detail)}),c(m,f)};M(q,m=>{r().detail&&m(W)})}var x=L(q,2);{var V=m=>{var f=Ut(),o=Pe(f);Pt(o,{children:(N,s)=>{it();var i=lt();oe(b=>de(i,b),[()=>Dt(r().shortcut)]),c(N,i)},$$slots:{default:!0}}),De(f),oe(()=>xe(f,1,Ct(E()?"ml-4 flex h-lh shrink-0 items-center":"ml-4"))),c(m,f)};M(x,m=>{r().shortcut&&m(V)})}c(p,O)};let we=h(d,"actions",7),E=h(d,"menu",7),J=h(d,"iconWeight",7),u=h(d,"onClose",7),A=h(d,"selection",7),F=Ee(null);function Y(p){p.disabled||p.disabledReason!==void 0||(p.onClick(),u()?.())}var ce={get actions(){return we()},set actions(p){we(p),v()},get menu(){return E()},set menu(p){E(p),v()},get iconWeight(){return J()},set iconWeight(p){J(p),v()},get onClose(){return u()},set onClose(p){u(p),v()},get selection(){return A()},set selection(p){A(p),v()},$set:Ze,$on:(p,r)=>$e(d,p,r)},se=H(),ie=y(se);return Wt(ie,17,we,p=>p.id,(p,r)=>{const O=i=>{Ie(i,()=>e(r))},S=w(()=>!!(e(r).editor||e(r).iconSnippet||e(r).icon)),j=w(()=>e(r).disabled||e(r).disabledReason!==void 0),R=w(()=>e(r).disabledReason?`${ke}-${e(r).id}-reason`:void 0);var q=Qe(),W=y(q);{var x=i=>{var b=H(),T=y(b);{var ae=a=>{var n=H(),g=y(n);Q(g,()=>Ke,(C,P)=>{P(C,{})}),c(a,n)},ue=a=>{var n=Jt();c(a,n)};M(T,a=>{E()?a(ae):a(ue,-1)})}c(i,b)};M(W,i=>{e(r).dividerBefore&&i(x)})}var V=L(W,2);{var m=i=>{var b=H(),T=y(b);{var ae=g=>{var C=H(),P=y(C);Q(P,()=>Tt,(I,D)=>{D(I,{children:(B,Z)=>{var $=Me(),pe=y($);{let te=w(()=>e(S)?O:void 0);Q(pe,()=>St,(fe,he)=>{he(fe,{get leading(){return e(te)},get disabled(){return e(j)},get"aria-describedby"(){return e(R)},get"data-action-id"(){return e(r).id},children:(ve,ye)=>{ne(ve,()=>e(r))},$$slots:{default:!0}})})}var ee=L(pe,2);{let te=w(()=>e(r).note?`${ke}-${e(r).id}-note`:void 0);Q(ee,()=>Rt,(fe,he)=>{he(fe,{class:"w-60",get"aria-describedby"(){return e(te)},children:(ve,ye)=>{var t=Me(),l=y(t);{var _=re=>{var Ae=Me(),Fe=y(Ae);{let Ce=w(()=>e(r).submenu.find(ge=>ge.checked)?.id??"");Q(Fe,()=>Nt,(ge,Se)=>{Se(ge,{get value(){return e(Ce)},get"aria-label"(){return e(r).label},children:(rt,$t)=>{{let at=w(()=>e(r).submenu.filter(ot=>ot.checked!==void 0));me(rt,{get actions(){return e(at)},selection:"single",get menu(){return E()},get iconWeight(){return J()},get onClose(){return u()}})}},$$slots:{default:!0}})})}var We=L(Fe,2);{let Ce=w(()=>e(r).submenu.filter(ge=>ge.checked===void 0));me(We,{get actions(){return e(Ce)},get menu(){return E()},get iconWeight(){return J()},get onClose(){return u()}})}c(re,Ae)},z=re=>{me(re,{get actions(){return e(r).submenu},get menu(){return E()},get iconWeight(){return J()},get onClose(){return u()}})};M(l,re=>{e(r).selection==="single"?re(_):re(z,-1)})}var le=L(l,2);{var Oe=re=>{var Ae=qt(),Fe=y(Ae);Q(Fe,()=>Ke,(ge,Se)=>{Se(ge,{})});var We=L(Fe,2),Ce=_e(We,!0);oe(()=>{Ne(We,"id",`${ke}-${e(r).id}-note`),xe(We,1,`type-caption px-2 py-1 ${Be}`),de(Ce,e(r).note)}),c(re,Ae)};M(le,re=>{e(r).note&&re(Oe)})}c(ve,t)},$$slots:{default:!0}})})}c(B,$)},$$slots:{default:!0}})}),c(g,C)},ue=g=>{var C=H(),P=y(C);{let I=w(()=>e(S)?O:void 0);Q(P,()=>Bt,(D,B)=>{B(D,{get leading(){return e(I)},get value(){return e(r).id},get disabled(){return e(j)},get"aria-describedby"(){return e(R)},closeOnSelect:!0,onSelect:()=>Y(e(r)),get"data-action-id"(){return e(r).id},children:(Z,$)=>{ne(Z,()=>e(r))},$$slots:{default:!0}})})}c(g,C)},a=g=>{var C=H(),P=y(C);{let I=w(()=>e(S)?O:void 0);Q(P,()=>zt,(D,B)=>{B(D,{get leading(){return e(I)},get checked(){return e(r).checked},get disabled(){return e(j)},get"aria-describedby"(){return e(R)},closeOnSelect:!0,onSelect:()=>Y(e(r)),get"data-action-id"(){return e(r).id},children:(Z,$)=>{ne(Z,()=>e(r))},$$slots:{default:!0}})})}c(g,C)},n=g=>{var C=H(),P=y(C);{let I=w(()=>e(S)?O:void 0),D=w(()=>e(r).variant==="destructive");Q(P,()=>Xt,(B,Z)=>{Z(B,{get leading(){return e(I)},get destructive(){return e(D)},get disabled(){return e(j)},get"aria-describedby"(){return e(R)},onSelect:()=>Y(e(r)),get"data-action-id"(){return e(r).id},children:($,pe)=>{ne($,()=>e(r))},$$slots:{default:!0}})})}c(g,C)};M(T,g=>{e(r).submenu?g(ae):A()==="single"&&e(r).checked!==void 0?g(ue,1):e(r).checked!==void 0?g(a,2):g(n,-1)})}c(i,b)},f=i=>{me(i,{get actions(){return e(r).submenu},get menu(){return E()},get iconWeight(){return J()},get onClose(){return u()}})},o=i=>{var b=Me(),T=y(b);{let a=w(()=>e(r).variant==="destructive"?"text-danger hover:text-danger":""),n=w(()=>e(r).submenu?e(F)===e(r).id:void 0);It(T,{variant:"ghost",size:"sm",get class(){return`w-full justify-start gap-2 ${e(a)??""}`},get disabled(){return e(j)},get"aria-describedby"(){return e(R)},get"aria-expanded"(){return e(n)},onclick:()=>e(r).submenu?X(F,e(F)===e(r).id?null:e(r).id,!0):Y(e(r)),children:(g,C)=>{var P=Gt(),I=y(P),D=Pe(I);Ie(D,()=>e(r)),De(I);var B=L(I,2);ne(B,()=>e(r));var Z=L(B,2);{var $=ee=>{{let te=w(()=>e(F)===e(r).id?bt:kt);Re(ee,{get icon(){return e(te)},size:12})}},pe=ee=>{var te=H(),fe=y(te);{let he=w(()=>e(r).checked?"checked":"empty");Q(fe,()=>Ot,(ve,ye)=>{ye(ve,{get state(){return e(he)}})})}c(ee,te)};M(Z,ee=>{e(r).submenu?ee($):e(r).checked!==void 0&&ee(pe,1)})}c(g,P)},$$slots:{default:!0}})}var ae=L(T,2);{var ue=a=>{var n=Qt(),g=Pe(n);me(g,{get actions(){return e(r).submenu},get menu(){return E()},get iconWeight(){return J()},get onClose(){return u()}});var C=L(g,2);{var P=I=>{var D=Kt(),B=_e(D,!0);oe(()=>{xe(D,1,`type-caption px-2 py-1 ${Be}`),de(B,e(r).note)}),c(I,D)};M(C,I=>{e(r).note&&I(P)})}De(n),c(a,n)};M(ae,a=>{e(r).submenu&&e(F)===e(r).id&&a(ue)})}c(i,b)};M(V,i=>{E()?i(m):e(r).id==="open-in"&&e(r).submenu?i(f,1):i(o,-1)})}var N=L(V,2);{var s=i=>{var b=Yt(),T=_e(b,!0);oe(()=>{Ne(b,"id",e(R)),de(T,e(r).disabledReason)}),c(i,b)};M(N,i=>{e(r).disabledReason&&i(s)})}c(p,q)}),c(be,se),tt(ce)}function Zt(be,d){if(new.target)return Ye({component:Zt,...be});et(d,!0);const ke=()=>Xe(T,"$installedEditors$",ne),Ie=()=>Xe(ue,"$isWorkspaceHostLocal$",ne),[ne,we]=nt();let E=h(d,"layout",7,"list"),J=h(d,"iconWeight",7),u=h(d,"filePath",7,""),A=h(d,"workspaceId",7,""),F=h(d,"isDirectory",7,!0),Y=h(d,"onDelete",7,void 0),ce=h(d,"onArchive",7,void 0),se=h(d,"onUnarchive",7,void 0),ie=h(d,"isArchived",7,!1),p=h(d,"onClose",7,void 0),r=h(d,"showDeleteOption",7,!0),O=h(d,"showArchiveOption",7,!1),S=h(d,"showPathCopy",7,!0),j=h(d,"showFileNameCopy",7,!1),R=h(d,"showFileActions",7,!0),q=h(d,"workspaceFolderPath",7,""),W=h(d,"isDiff",7,!1),x=h(d,"isWorkspaceRoot",7,!1),V=h(d,"additionalActions",23,()=>[]),m=h(d,"showDeleteFileOption",7,!1),f=h(d,"onFileDeleted",7,void 0);const o=gt("WorkspaceActionsMenu");let N=!1;dt(()=>{N=!0});function s(){N||p()?.()}const i=_t("externalEditors"),b=ct(A());Ve(()=>{b.set(A())});const T=ht(b),ae=w(ke),ue=vt(b);let a=Ee(""),n=Ee(""),g=Ee(!1);ut(()=>{He.dispatch(pt())}),Ve(()=>{u()&&A()?G("workspace:get",{id:A()}).then(t=>{if(t&&t.success&&t.data){const l=t.data,_=l.worktreePath||l.repositoryPath||l.path,z=q()==="__WORKSPACE_ROOT__"?_:q()||_;if(z){const le=z.replace(/\\/g,"/");x()?X(a,le,!0):Le(u())?X(a,u().replace(/\\/g,"/"),!0):X(a,`${le}/${u()}`.replace(/\/+/g,"/"),!0),X(n,le,!0),o.info("[WorkspaceActionsMenu] Resolved file path:",{filePath:u(),workspacePath:z,resolvedPath:e(a)})}else X(a,u()),X(n,""),l.status!=="archived"&&l.status!=="deleted"&&o.warn("[WorkspaceActionsMenu] No workspace path found:",l)}else X(a,u()),X(n,""),t?.error&&!t.error.includes("not found")&&o.warn("[WorkspaceActionsMenu] Workspace not available:",t)}).catch(t=>{X(a,u()),X(n,""),t?.message?.includes("not found")||o.error("[WorkspaceActionsMenu] Failed to resolve path:",t)}):(X(a,u()),o.info("[WorkspaceActionsMenu] Using filePath directly:",{filePath:u(),workspaceId:A()}))});async function C(){if(!e(a)){o.warn("[WorkspaceActionsMenu] No resolved path for VSCode");return}try{if(W()&&!F()){o.info("[WorkspaceActionsMenu] Opening diff in VSCode:",{resolvedPath:e(a)}),await G("vscode:open-git-diff",{filePath:e(a),workspacePath:e(n)||void 0}),s();return}let t=e(a);if(e(n))!F()&&!x()?t={folder:e(n),file:e(a)}:t=e(n);else if(!F()){const l=e(a).includes("\\")?"\\":"/",_=e(a).split(l);_.length>1&&(t={folder:_.slice(0,-1).join(l),file:e(a)})}await G("vscode:open",t),s()}catch(t){o.error("Failed to open in VSCode:",t),K.error(t instanceof Error?t.message:k.ui_workspaceActions_openFailed_error({name:"VS Code"}))}}async function P(){if(!e(a)){o.warn("[WorkspaceActionsMenu] No resolved path for JetBrains");return}try{let t=e(a);e(n)&&!F()?t={folder:e(n),file:e(a)}:e(n)&&(t=e(n)),await G("jetbrains:open",t),s()}catch(t){o.error("Failed to open in JetBrains:",t),K.error(t instanceof Error?t.message:k.ui_workspaceActions_openFailed_error({name:"JetBrains"}))}}async function I(){if(!e(a)){o.warn("[WorkspaceActionsMenu] No resolved path for Xcode");return}try{if(A()&&e(n)){He.dispatch(ft(A(),e(n),F()?void 0:e(a))),s();return}let t=e(a);e(n)&&!F()?t={folder:e(n),file:e(a)}:e(n)&&(t={folder:e(n)}),await G("xcode:open",t),s()}catch(t){o.error("Failed to open in Xcode:",t),K.error(t instanceof Error?t.message:k.ui_workspaceActions_openFailed_error({name:"Xcode"}))}}async function D(t){if(o.info("[WorkspaceActionsMenu] openInEditor called",{editorId:t.id,appName:t.appName,handlerType:t.handlerType,resolvedPath:e(a),isDirectory:F()}),!e(a)){o.warn("[WorkspaceActionsMenu] openInEditor: No resolved path, aborting");return}const l=F()?e(a):e(a).substring(0,e(a).lastIndexOf("/"));o.info(`[WorkspaceActionsMenu] openInEditor: targetPath=${l}, handlerType=${t.handlerType}`);try{switch(t.handlerType){case"finder":o.info("[WorkspaceActionsMenu] openInEditor: Invoking shell:showItemInFolder"),await G("shell:showItemInFolder",{path:l});break;case"vscode":o.info("[WorkspaceActionsMenu] openInEditor: Delegating to openInVSCode"),await C();return;case"jetbrains":o.info("[WorkspaceActionsMenu] openInEditor: Delegating to openInJetBrains"),await P();return;case"xcode":o.info("[WorkspaceActionsMenu] openInEditor: Delegating to openInXcode"),await I();return;case"generic":default:{o.info(`[WorkspaceActionsMenu] openInEditor: Invoking external-editors:open for ${t.id}`);const _=await G("external-editors:open",{editorId:t.id,path:l});o.info("[WorkspaceActionsMenu] openInEditor: external-editors:open result",_);break}}s()}catch(_){o.error(`[WorkspaceActionsMenu] Failed to open in ${t.appName}:`,_),K.error(_ instanceof Error?_.message:k.ui_workspaceActions_openFailed_error({name:t.appName}))}}async function B(){if(!e(a)){o.warn("No resolved path for openWithOther");return}try{let t=e(a);F()&&e(n)&&(t=e(n));const l=await G("external-editors:open-with-other",{path:t});if(!l?.success){l?.error!=="No application selected"&&(o.error("Failed to open with other app:",l?.error),K.error(l?.error||k.ui_workspaceActions_openOtherFailed_error()));return}s()}catch(t){o.error("Failed to open with other app:",t),K.error(t instanceof Error?t.message:k.ui_workspaceActions_openOtherFailed_error())}}async function Z(){if(e(a))try{await navigator.clipboard.writeText(Ue(e(a))),s()}catch(t){o.error("Failed to copy path:",t)}}async function $(){if(u())try{let t=u().replace(/\\/g,"/");if(Le(u())&&e(n)){const l=e(n).endsWith("/")?e(n):e(n)+"/";t.startsWith(l)&&(t=t.slice(l.length))}await navigator.clipboard.writeText(Ue(t)),s()}catch(t){o.error("Failed to copy workspace path:",t)}}async function pe(){if(u())try{const t=u().split(/[/\\]/).pop()||"";await navigator.clipboard.writeText(t),s()}catch(t){o.error("Failed to copy file name:",t)}}function ee(){Y()&&(Y()(),s())}async function te(){if(!(!A()||!e(a)||e(g))){X(g,!0);try{const t=u().split(/[/\\]/).pop()||"file",l=e(a);let _="";try{_=(await G("file:read",{path:l,workspaceId:A()}))?.data?.content??""}catch{}const z=await G("file:delete",{path:l,workspaceId:A()});if(z?.success){f()?.(),s();const le=K.warning(k.ui_workspaceActions_deletedFile_label({name:t}),Ft({duration:15e3,action:{label:k.ui_workspaceActions_undo_label(),onClick:async()=>{try{await G("file:write",{path:l,content:_,workspaceId:A()}),mt("file:changed",{workspaceId:A(),type:"create",filePath:l}),K.dismiss(le)}catch(Oe){o.error("[WorkspaceActionsMenu] Failed to restore file",Oe),K.error(k.ui_workspaceActions_restoreFileFailed_error())}}}}))}else K.error(k.ui_workspaceActions_deleteFileFailedDetail_error({error:z?.error||k.ui_workspaceActions_unknown_error()}))}catch(t){o.error("[WorkspaceActionsMenu] Error deleting file",t),K.error(k.ui_workspaceActions_deleteFileFailed_error())}finally{X(g,!1)}}}function fe(){ie()&&se()?(se()(),s()):!ie()&&ce()&&(ce()(),s())}const he=w(()=>{const t=[];R()&&(i&&Ie()&&t.push({id:"open-in",label:k.ui_openCombo_openInApp_tooltip(),icon:Je,onClick:()=>{},submenu:[...e(ae).map(_=>({id:`editor:${_.id}`,label:k.ui_workspaceActions_openIn_label({name:_.name}),editor:_,onClick:()=>{D(_)}})),{id:"choose-app",label:k.ui_workspaceActions_chooseApp_label(),icon:Je,onClick:()=>{B()}}]}),S()&&t.push({id:"copy-absolute-path",label:k.ui_workspaceActions_copyAbsolutePath_label(),icon:qe,disabled:!e(a),dividerBefore:t.length>0,onClick:()=>{Z()}}),S()&&!x()&&t.push({id:"copy-relative-path",label:k.ui_workspaceActions_copyRelativePath_label(),icon:qe,disabled:!u(),onClick:()=>{$()}}),j()&&!F()&&t.push({id:"copy-file-name",label:k.ui_workspaceActions_copyFileName_label(),icon:wt,disabled:!u(),onClick:()=>{pe()}}));const l=_=>_.map(z=>({...z,submenu:z.submenu?l(z.submenu):void 0,onClick:()=>{z.onClick(),s()}}));return t.push(...l(V())),O()&&(ce()||se())&&t.push({id:"archive-workspace",label:ie()?k.ui_workspaceActions_unarchiveSpace_label():k.ui_workspaceActions_archiveSpace_label(),icon:ie()?yt:At,dividerBefore:t.length>0,onClick:fe}),r()&&Y()&&t.push({id:"delete-workspace",label:k.ui_workspaceActions_deleteSpace_label(),icon:Ge,variant:"destructive",dividerBefore:t.length>0&&t.at(-1)?.id!=="archive-workspace",onClick:ee}),m()&&!F()&&t.push({id:"delete-file",label:k.ui_workspaceActions_deleteFile_label(),icon:Ge,variant:"destructive",disabled:e(g)||!e(a)||!A(),dividerBefore:t.length>0,onClick:()=>{te()}}),t});var ve={get layout(){return E()},set layout(t="list"){E(t),v()},get iconWeight(){return J()},set iconWeight(t){J(t),v()},get filePath(){return u()},set filePath(t=""){u(t),v()},get workspaceId(){return A()},set workspaceId(t=""){A(t),v()},get isDirectory(){return F()},set isDirectory(t=!0){F(t),v()},get onDelete(){return Y()},set onDelete(t=void 0){Y(t),v()},get onArchive(){return ce()},set onArchive(t=void 0){ce(t),v()},get onUnarchive(){return se()},set onUnarchive(t=void 0){se(t),v()},get isArchived(){return ie()},set isArchived(t=!1){ie(t),v()},get onClose(){return p()},set onClose(t=void 0){p(t),v()},get showDeleteOption(){return r()},set showDeleteOption(t=!0){r(t),v()},get showArchiveOption(){return O()},set showArchiveOption(t=!1){O(t),v()},get showPathCopy(){return S()},set showPathCopy(t=!0){S(t),v()},get showFileNameCopy(){return j()},set showFileNameCopy(t=!1){j(t),v()},get showFileActions(){return R()},set showFileActions(t=!0){R(t),v()},get workspaceFolderPath(){return q()},set workspaceFolderPath(t=""){q(t),v()},get isDiff(){return W()},set isDiff(t=!1){W(t),v()},get isWorkspaceRoot(){return x()},set isWorkspaceRoot(t=!1){x(t),v()},get additionalActions(){return V()},set additionalActions(t=[]){V(t),v()},get showDeleteFileOption(){return m()},set showDeleteFileOption(t=!1){m(t),v()},get onFileDeleted(){return f()},set onFileDeleted(t=void 0){f(t),v()},$set:Ze,$on:(t,l)=>$e(d,t,l)};{let t=w(()=>E()!=="list");me(be,{get actions(){return e(he)},get menu(){return e(t)},get iconWeight(){return J()}})}var ye=tt(ve);return we(),ye}export{Zt as default};
@@ -1 +1 @@
1
- import{t as P,bq as d,by as V,b as B,a_ as F,bo as L}from"./DozYGPQ1.js";import{bs as H,b_ as E,W as _,bn as j,aA as p,aC as T,a7 as I,ay as O,aD as r,a5 as U,bS as X,bH as b,bA as Y,be as Z,b$ as $,bO as ee,c9 as c,aB as te,bV as k,bk as re}from"./DYhIMPy1.js";import{s as ne,k as ie,d as oe}from"./CBE9bOjQ.js";import{F as ae}from"./BBvT7Bb8.js";import{I as se}from"./CZ5Pr0zI.js";import"./C3lmZVdU.js";import{L as le}from"./Dlalsrb2.js";import"./BLl4jbbs.js";import{D as ue,k as z}from"./H5XG0yyu.js";import{r as ce,q as y}from"./9tzjcklF.js";var fe=T('<svg viewBox="0 0 24 24" fill="none" xmlns="http://www.w3.org/2000/svg" aria-hidden="true"><path d="M12 15.82L12 23.76M4.44 21L8.35 16.35A1.96 1.96 0 0 0 6.4 12.99L0.42 14.04M1.82 6.12L7.08 9.16A1.96 1.96 0 0 0 10.06 6.66L7.98 0.95M16.02 0.95L13.94 6.66A1.96 1.96 0 0 0 16.92 9.16L22.18 6.12M23.58 14.04L17.6 12.99A1.96 1.96 0 0 0 15.65 16.35L19.56 21" stroke="currentColor" stroke-width="2.06" stroke-linecap="butt" stroke-linejoin="round"></path></svg>');function me(f,o){if(new.target)return P({component:me,...f});H(o,!0);let e=d(o,"width",7,24),n=d(o,"class",7,"");var a={get width(){return e()},set width(s=24){e(s),p()},get class(){return n()},set class(s=""){n(s),p()},$set:V,$on:(s,m)=>B(o,s,m)},l=fe();return E(()=>{ne(l,"width",e()),ie(l,0,oe(n()))}),_(f,l),j(a)}var de=te('<div class="grid gap-2"><!> <!></div>');function G(f,o){if(new.target)return P({component:G,...f});H(o,!0);let e=d(o,"request",7),n=d(o,"value",15,""),a=d(o,"busy",7,!1),l=d(o,"static",7,!1),s=d(o,"onAccept",7),m=d(o,"onCancel",7),v=k(null);var A={get request(){return e()},set request(t){e(t),p()},get value(){return n()},set value(t=""){n(t),p()},get busy(){return a()},set busy(t=!1){a(t),p()},get static(){return l()},set static(t=!1){l(t),p()},get onAccept(){return s()},set onAccept(t){s(t),p()},get onCancel(){return m()},set onCancel(t){m(t),p()},$set:V,$on:(t,g)=>B(o,t,g)},h=I(),i=O(h);{var u=t=>{{let g=c(()=>e().options.confirmLabel??L.modals_bulkActionConfirm_confirm_label()),M=c(()=>e().options.cancelLabel??L.modals_bulkActionConfirm_cancel_label()),S=c(()=>e().options.destructive??!1);ue(t,{open:!0,get static(){return l()},get title(){return e().options.title},get description(){return e().options.description},get confirmLabel(){return r(g)},get cancelLabel(){return r(M)},get destructive(){return r(S)},get busy(){return a()},onConfirm:()=>s()(n()),get onCancel(){return m()}})}},q=t=>{{let g=c(()=>e().options.confirmLabel??L.modals_input_confirm_label()),M=c(()=>e().options.cancelLabel??L.modals_input_cancel_label()),S=c(()=>!e().options.field.required||n().trim().length>0);z(t,{open:!0,get static(){return l()},get title(){return e().options.title},get description(){return e().options.description},get submitLabel(){return r(g)},get cancelLabel(){return r(M)},get canSubmit(){return r(S)},get busy(){return a()},get initialFocus(){return r(v)},onSubmit:()=>s()(n()),get onCancel(){return m()},children:(J,ge)=>{var D=de(),N=U(D);{var K=C=>{le(C,{for:"confirm-prompt-field",children:(R,w)=>{Z();var W=$();E(()=>ee(W,e().options.field.label)),_(R,W)},$$slots:{default:!0}})};F(N,C=>{e().options.field.label&&C(K)})}var Q=X(N,2);{let C=c(()=>e().options.field.type??"text"),R=c(()=>e().options.field.label?void 0:e().options.title);se(Q,{id:"confirm-prompt-field",get type(){return r(C)},get placeholder(){return e().options.field.placeholder},get"aria-label"(){return r(R)},get ref(){return r(v)},set ref(w){b(v,w,!0)},get value(){return n()},set value(w){n(w)}})}Y(D),_(J,D)},$$slots:{default:!0}})}},x=t=>{{let g=c(()=>e().options.confirmLabel??L.modals_input_confirm_label());z(t,{open:!0,get static(){return l()},role:"alertdialog",get title(){return e().options.title},get description(){return e().options.description},get submitLabel(){return r(g)},showCancel:!1,dismissOnInteractOutside:!1,get busy(){return a()},onSubmit:()=>s()(n()),onCancel:()=>s()(n())})}};F(i,t=>{e()?.kind==="confirm"?t(u):e()?.kind==="prompt"?t(q,1):e()?.kind==="alert"&&t(x,2)})}return _(f,h),j(A)}function pe(f,o){if(new.target)return P({component:pe,...f});H(o,!0);let e=k(null),n=k(""),a=k(!1);re(()=>ce(i=>{b(e,i,!0),b(n,i?.kind==="prompt"?i.options.field.initialValue??"":"",!0),b(a,!1)}));function l(){!r(e)||r(a)||y(r(e).id,r(e).kind==="confirm"?!1:null)}async function s(){if(!r(e)||r(a))return;const i=r(e);b(a,!0);try{i.kind==="confirm"?(await i.options.onConfirm?.(),y(i.id,!0)):i.kind==="prompt"?(await i.options.onConfirm?.(r(n).trim()),y(i.id,r(n).trim())):y(i.id,void 0)}catch(u){throw console.error("Confirm action failed:",u),b(a,!1),u}}var m={$set:V,$on:(i,u)=>B(o,i,u)},v=I(),A=O(v);{var h=i=>{var u=I(),q=O(u);ae(q,()=>r(e).id,x=>{G(x,{get request(){return r(e)},get busy(){return r(a)},onAccept:s,onCancel:l,get value(){return r(n)},set value(t){b(n,t,!0)}})}),_(i,u)};F(A,i=>{r(e)&&i(h)})}return _(f,v),j(m)}export{pe as C,me as L};
1
+ import{t as P,bq as d,by as V,b as B,a_ as F,bo as L}from"./eK7OULll.js";import{bs as H,b_ as E,W as _,bn as j,aA as p,aC as T,a7 as I,ay as O,aD as r,a5 as U,bS as X,bH as b,bA as Y,be as Z,b$ as $,bO as ee,c9 as c,aB as te,bV as k,bk as re}from"./DYhIMPy1.js";import{s as ne,k as ie,d as oe}from"./DZtstCLQ.js";import{F as ae}from"./Dix9BiYu.js";import{I as se}from"./DOzF5uE-.js";import"./jMKjj8ae.js";import{L as le}from"./w6mFE4SD.js";import"./aLZSbque.js";import{D as ue,k as z}from"./BdWpSBC4.js";import{r as ce,q as y}from"./QjpXu0Du.js";var fe=T('<svg viewBox="0 0 24 24" fill="none" xmlns="http://www.w3.org/2000/svg" aria-hidden="true"><path d="M12 15.82L12 23.76M4.44 21L8.35 16.35A1.96 1.96 0 0 0 6.4 12.99L0.42 14.04M1.82 6.12L7.08 9.16A1.96 1.96 0 0 0 10.06 6.66L7.98 0.95M16.02 0.95L13.94 6.66A1.96 1.96 0 0 0 16.92 9.16L22.18 6.12M23.58 14.04L17.6 12.99A1.96 1.96 0 0 0 15.65 16.35L19.56 21" stroke="currentColor" stroke-width="2.06" stroke-linecap="butt" stroke-linejoin="round"></path></svg>');function me(f,o){if(new.target)return P({component:me,...f});H(o,!0);let e=d(o,"width",7,24),n=d(o,"class",7,"");var a={get width(){return e()},set width(s=24){e(s),p()},get class(){return n()},set class(s=""){n(s),p()},$set:V,$on:(s,m)=>B(o,s,m)},l=fe();return E(()=>{ne(l,"width",e()),ie(l,0,oe(n()))}),_(f,l),j(a)}var de=te('<div class="grid gap-2"><!> <!></div>');function G(f,o){if(new.target)return P({component:G,...f});H(o,!0);let e=d(o,"request",7),n=d(o,"value",15,""),a=d(o,"busy",7,!1),l=d(o,"static",7,!1),s=d(o,"onAccept",7),m=d(o,"onCancel",7),v=k(null);var A={get request(){return e()},set request(t){e(t),p()},get value(){return n()},set value(t=""){n(t),p()},get busy(){return a()},set busy(t=!1){a(t),p()},get static(){return l()},set static(t=!1){l(t),p()},get onAccept(){return s()},set onAccept(t){s(t),p()},get onCancel(){return m()},set onCancel(t){m(t),p()},$set:V,$on:(t,g)=>B(o,t,g)},h=I(),i=O(h);{var u=t=>{{let g=c(()=>e().options.confirmLabel??L.modals_bulkActionConfirm_confirm_label()),M=c(()=>e().options.cancelLabel??L.modals_bulkActionConfirm_cancel_label()),S=c(()=>e().options.destructive??!1);ue(t,{open:!0,get static(){return l()},get title(){return e().options.title},get description(){return e().options.description},get confirmLabel(){return r(g)},get cancelLabel(){return r(M)},get destructive(){return r(S)},get busy(){return a()},onConfirm:()=>s()(n()),get onCancel(){return m()}})}},q=t=>{{let g=c(()=>e().options.confirmLabel??L.modals_input_confirm_label()),M=c(()=>e().options.cancelLabel??L.modals_input_cancel_label()),S=c(()=>!e().options.field.required||n().trim().length>0);z(t,{open:!0,get static(){return l()},get title(){return e().options.title},get description(){return e().options.description},get submitLabel(){return r(g)},get cancelLabel(){return r(M)},get canSubmit(){return r(S)},get busy(){return a()},get initialFocus(){return r(v)},onSubmit:()=>s()(n()),get onCancel(){return m()},children:(J,ge)=>{var D=de(),N=U(D);{var K=C=>{le(C,{for:"confirm-prompt-field",children:(R,w)=>{Z();var W=$();E(()=>ee(W,e().options.field.label)),_(R,W)},$$slots:{default:!0}})};F(N,C=>{e().options.field.label&&C(K)})}var Q=X(N,2);{let C=c(()=>e().options.field.type??"text"),R=c(()=>e().options.field.label?void 0:e().options.title);se(Q,{id:"confirm-prompt-field",get type(){return r(C)},get placeholder(){return e().options.field.placeholder},get"aria-label"(){return r(R)},get ref(){return r(v)},set ref(w){b(v,w,!0)},get value(){return n()},set value(w){n(w)}})}Y(D),_(J,D)},$$slots:{default:!0}})}},x=t=>{{let g=c(()=>e().options.confirmLabel??L.modals_input_confirm_label());z(t,{open:!0,get static(){return l()},role:"alertdialog",get title(){return e().options.title},get description(){return e().options.description},get submitLabel(){return r(g)},showCancel:!1,dismissOnInteractOutside:!1,get busy(){return a()},onSubmit:()=>s()(n()),onCancel:()=>s()(n())})}};F(i,t=>{e()?.kind==="confirm"?t(u):e()?.kind==="prompt"?t(q,1):e()?.kind==="alert"&&t(x,2)})}return _(f,h),j(A)}function pe(f,o){if(new.target)return P({component:pe,...f});H(o,!0);let e=k(null),n=k(""),a=k(!1);re(()=>ce(i=>{b(e,i,!0),b(n,i?.kind==="prompt"?i.options.field.initialValue??"":"",!0),b(a,!1)}));function l(){!r(e)||r(a)||y(r(e).id,r(e).kind==="confirm"?!1:null)}async function s(){if(!r(e)||r(a))return;const i=r(e);b(a,!0);try{i.kind==="confirm"?(await i.options.onConfirm?.(),y(i.id,!0)):i.kind==="prompt"?(await i.options.onConfirm?.(r(n).trim()),y(i.id,r(n).trim())):y(i.id,void 0)}catch(u){throw console.error("Confirm action failed:",u),b(a,!1),u}}var m={$set:V,$on:(i,u)=>B(o,i,u)},v=I(),A=O(v);{var h=i=>{var u=I(),q=O(u);ae(q,()=>r(e).id,x=>{G(x,{get request(){return r(e)},get busy(){return r(a)},onAccept:s,onCancel:l,get value(){return r(n)},set value(t){b(n,t,!0)}})}),_(i,u)};F(A,i=>{r(e)&&i(h)})}return _(f,v),j(m)}export{pe as C,me as L};
@@ -1 +1 @@
1
- import{g as l,r as m,d as n}from"./ChV6OcuF.js";import{p}from"./CIH3mb7Y.js";import{b as t,ay as o}from"./DWcUEP_3.js";import{M as u,a as f}from"./QeTaV4Op.js";var c=f().RailroadEbnf.parser.LangiumParser,s=t(e=>{const r=e.alternatives.map(E);return r.length===1?r[0]:{type:"choice",alternatives:r}},"transformChoice"),E=t(e=>{const r=e.elements.map(y);return r.length===1?r[0]:{type:"sequence",elements:r}},"transformSequence"),i=t(e=>{switch(e.$type){case"EbnfTerminal":return{type:"terminal",value:e.value};case"EbnfNonTerminal":return{type:"nonterminal",name:e.name};case"EbnfSpecial":return{type:"special",text:e.text};case"EbnfGroup":return s(e.element);case"EbnfOptional":return{type:"optional",element:s(e.element)};case"EbnfRepetition":return{type:"repetition",element:s(e.element),min:0,max:1/0};default:throw new Error(`Unsupported EBNF primary node: ${e.$type}`)}},"transformPrimary"),b=t((e,r)=>{switch(r.$type){case"EbnfOptionalPostfix":return{type:"optional",element:e};case"EbnfZeroOrMorePostfix":return{type:"repetition",element:e,min:0,max:1/0};case"EbnfOneOrMorePostfix":return{type:"repetition",element:e,min:1,max:1/0};case"EbnfExceptionPostfix":return{type:"sequence",elements:[e,{type:"terminal",value:"-"},i(r.except)]};default:throw new Error(`Unsupported EBNF postfix node: ${r.$type}`)}},"transformPostfix"),y=t(e=>e.postfixes.reduce((r,a)=>b(r,a),i(e.base)),"transformTerm"),d=t(e=>({name:e.name,definition:s(e.definition)}),"transformRule"),v=t(e=>{p(e,n),e.title&&n.setTitle(e.title),e.rules.map(r=>n.addRule(d(r)))},"populateDb"),g={parse:t(e=>{n.clear(),o.debug("[EBNF Parser] Starting Langium parse");const r=c.parse(e);if(r.lexerErrors.length>0||r.parserErrors.length>0)throw new u(r);const a=r.value;o.debug("[EBNF Parser] Parsed rules:",a.rules.length),v(a),o.debug("[EBNF Parser] Parse complete")},"parse"),parser:{yy:n}},N={parser:g,db:n,renderer:m,styles:l};export{N as diagram};
1
+ import{g as l,r as m,d as n}from"./C3lgqjB4.js";import{p}from"./BkR5Qiti.js";import{b as t,ay as o}from"./DwsRDnkS.js";import{M as u,a as f}from"./DZAWjsA4.js";var c=f().RailroadEbnf.parser.LangiumParser,s=t(e=>{const r=e.alternatives.map(E);return r.length===1?r[0]:{type:"choice",alternatives:r}},"transformChoice"),E=t(e=>{const r=e.elements.map(y);return r.length===1?r[0]:{type:"sequence",elements:r}},"transformSequence"),i=t(e=>{switch(e.$type){case"EbnfTerminal":return{type:"terminal",value:e.value};case"EbnfNonTerminal":return{type:"nonterminal",name:e.name};case"EbnfSpecial":return{type:"special",text:e.text};case"EbnfGroup":return s(e.element);case"EbnfOptional":return{type:"optional",element:s(e.element)};case"EbnfRepetition":return{type:"repetition",element:s(e.element),min:0,max:1/0};default:throw new Error(`Unsupported EBNF primary node: ${e.$type}`)}},"transformPrimary"),b=t((e,r)=>{switch(r.$type){case"EbnfOptionalPostfix":return{type:"optional",element:e};case"EbnfZeroOrMorePostfix":return{type:"repetition",element:e,min:0,max:1/0};case"EbnfOneOrMorePostfix":return{type:"repetition",element:e,min:1,max:1/0};case"EbnfExceptionPostfix":return{type:"sequence",elements:[e,{type:"terminal",value:"-"},i(r.except)]};default:throw new Error(`Unsupported EBNF postfix node: ${r.$type}`)}},"transformPostfix"),y=t(e=>e.postfixes.reduce((r,a)=>b(r,a),i(e.base)),"transformTerm"),d=t(e=>({name:e.name,definition:s(e.definition)}),"transformRule"),v=t(e=>{p(e,n),e.title&&n.setTitle(e.title),e.rules.map(r=>n.addRule(d(r)))},"populateDb"),g={parse:t(e=>{n.clear(),o.debug("[EBNF Parser] Starting Langium parse");const r=c.parse(e);if(r.lexerErrors.length>0||r.parserErrors.length>0)throw new u(r);const a=r.value;o.debug("[EBNF Parser] Parsed rules:",a.rules.length),v(a),o.debug("[EBNF Parser] Parse complete")},"parse"),parser:{yy:n}},N={parser:g,db:n,renderer:m,styles:l};export{N as diagram};