agentworkshop 0.7.23 → 0.7.27

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 (344) hide show
  1. package/.output/nitro.json +1 -1
  2. package/.output/public/_nuxt/0jKrzLuM.js +19 -0
  3. package/.output/public/_nuxt/2jaJHWIJ.js +1 -0
  4. package/.output/public/_nuxt/{Cor9siSf.js → 6PZPfFcO.js} +1 -1
  5. package/.output/public/_nuxt/B7gZokg82.js +209 -0
  6. package/.output/public/_nuxt/B8kt898d.js +1 -0
  7. package/.output/public/_nuxt/{B-xskWta.js → BCJFMBQ6.js} +1 -1
  8. package/.output/public/_nuxt/BFGpEo8S.js +1 -0
  9. package/.output/public/_nuxt/BG4zduPf.js +14 -0
  10. package/.output/public/_nuxt/{DNxVTfhe.js → BGhOrgle.js} +1 -1
  11. package/.output/public/_nuxt/{n3vMFfrv.js → BHcpzI2n.js} +3 -3
  12. package/.output/public/_nuxt/{CEHmSufQ.js → BTLEvDxM.js} +1 -1
  13. package/.output/public/_nuxt/{CYBq3kS7.js → BWyR3awA.js} +1 -1
  14. package/.output/public/_nuxt/Bc89zKq2.js +1 -0
  15. package/.output/public/_nuxt/BetmGSO4.js +1 -0
  16. package/.output/public/_nuxt/{DAR70Lf5.js → BgCrZKv_2.js} +1 -1
  17. package/.output/public/_nuxt/BowTbasd.js +1 -0
  18. package/.output/public/_nuxt/BvtknqSC2.js +1 -0
  19. package/.output/public/_nuxt/CJviSvm-.js +1 -0
  20. package/.output/public/_nuxt/CTfqWGdy.js +1 -0
  21. package/.output/public/_nuxt/Cb3SnTM8.js +1 -0
  22. package/.output/public/_nuxt/Chc5pfAA.js +1 -0
  23. package/.output/public/_nuxt/CmHzfVc5.js +3 -0
  24. package/.output/public/_nuxt/Cn3J3NXR.js +23 -0
  25. package/.output/public/_nuxt/CobSUzQv.js +2 -0
  26. package/.output/public/_nuxt/{kZV5TQvh2.js → CucID8qg2.js} +1 -1
  27. package/.output/public/_nuxt/{CfVAr2nf.js → Cz9gD2Yo.js} +1 -1
  28. package/.output/public/_nuxt/{E88a-JCG.js → DGAOugLt.js} +1 -1
  29. package/.output/public/_nuxt/DHbTyoAV.js +1 -0
  30. package/.output/public/_nuxt/{BxtpDtzC.js → DNQF_TXX.js} +1 -1
  31. package/.output/public/_nuxt/DfLUN8kY.js +1 -0
  32. package/.output/public/_nuxt/DjU9Dx5Y.js +1 -0
  33. package/.output/public/_nuxt/DnziMlcX.js +1 -0
  34. package/.output/public/_nuxt/{BBwMH_hG.js → DoAlYsiF.js} +1 -1
  35. package/.output/public/_nuxt/{DA4lxCWC2.js → DosOJEmZ2.js} +2 -2
  36. package/.output/public/_nuxt/{DWcEk1ur2.js → DvgKXPgu2.js} +1 -1
  37. package/.output/public/_nuxt/{ed5qX-x5.js → Q_SJDSgx.js} +1 -1
  38. package/.output/public/_nuxt/{TownView.zu2rU5nS.css → TownView.CtskuMXS.css} +1 -1
  39. package/.output/public/_nuxt/XY2z78rj.js +1 -0
  40. package/.output/public/_nuxt/_id_.DdbYeLqn.css +1 -0
  41. package/.output/public/_nuxt/bFnZa2yd.js +1 -0
  42. package/.output/public/_nuxt/builds/latest.json +1 -1
  43. package/.output/public/_nuxt/builds/meta/f7a8e33d-5422-45ac-895d-27168f97e3ad.json +1 -0
  44. package/.output/public/_nuxt/daq.DGV9QS8d.css +1 -0
  45. package/.output/public/_nuxt/entry.BN02X8iR.css +1 -0
  46. package/.output/public/_nuxt/monitor.B--1dPzs.css +1 -0
  47. package/.output/public/_nuxt/permissions.B1pjGChZ.css +1 -0
  48. package/.output/public/_nuxt/plugins.DpCuwaJt.css +1 -0
  49. package/.output/public/_nuxt/rkVgzg62.js +1 -0
  50. package/.output/public/_nuxt/settings.W6qrYAui.css +1 -0
  51. package/.output/public/_nuxt/teams.BBXVkyKq.css +1 -0
  52. package/.output/public/_nuxt/tokens.xRb1fSPU.css +1 -0
  53. package/.output/public/_nuxt/users.DuAt_Zwf.css +1 -0
  54. package/.output/public/_nuxt/workshop.BJg84pOK.css +1 -0
  55. package/.output/public/assets/game/character/yangyang-walk.glb +0 -0
  56. package/.output/server/chunks/_/host-bindings.mjs +1 -1
  57. package/.output/server/chunks/_/nitro.mjs +1073 -925
  58. package/.output/server/chunks/_/nitro.mjs.map +1 -1
  59. package/.output/server/chunks/build/{OmpTerminalPanel-Ban3yJZ4.mjs → OmpTerminalPanel-Cw_Vw9oO.mjs} +3 -3
  60. package/.output/server/chunks/build/{OmpTerminalPanel-Ban3yJZ4.mjs.map → OmpTerminalPanel-Cw_Vw9oO.mjs.map} +1 -1
  61. package/.output/server/chunks/build/{TownView-DxeQe1Bl.mjs → TownView-ftIylqiD.mjs} +178 -151
  62. package/.output/server/chunks/build/{TownView-DxeQe1Bl.mjs.map → TownView-ftIylqiD.mjs.map} +1 -1
  63. package/.output/server/chunks/build/{_id_-DQDqj-cZ.mjs → _id_-3Axz2-gV.mjs} +35 -35
  64. package/.output/server/chunks/build/{_id_-DQDqj-cZ.mjs.map → _id_-3Axz2-gV.mjs.map} +1 -1
  65. package/.output/server/chunks/build/{_id_-DY6v6sqB.mjs → _id_-CahfkmEt.mjs} +5 -5
  66. package/.output/server/chunks/build/{_id_-DY6v6sqB.mjs.map → _id_-CahfkmEt.mjs.map} +1 -1
  67. package/.output/server/chunks/build/{_wsId_-C2O5zZsI.mjs → _wsId_-BymlQhzS.mjs} +13 -15
  68. package/.output/server/chunks/build/{_wsId_-C2O5zZsI.mjs.map → _wsId_-BymlQhzS.mjs.map} +1 -1
  69. package/.output/server/chunks/build/{agents--6bzGtES.mjs → agents-DuMiSWKp.mjs} +7 -9
  70. package/.output/server/chunks/build/agents-DuMiSWKp.mjs.map +1 -0
  71. package/.output/server/chunks/build/button-DEcZFcqN.mjs +1 -1
  72. package/.output/server/chunks/build/{card-CCPQoKlh.mjs → card-Dipvaykh.mjs} +4 -4
  73. package/.output/server/chunks/build/{card-CCPQoKlh.mjs.map → card-Dipvaykh.mjs.map} +1 -1
  74. package/.output/server/chunks/build/{channel-templates-C1Bb-U75.mjs → channel-templates-BStqJ-of.mjs} +5 -7
  75. package/.output/server/chunks/build/channel-templates-BStqJ-of.mjs.map +1 -0
  76. package/.output/server/chunks/build/{checkbox-Dv1kjaUZ.mjs → checkbox-C1gABOca.mjs} +5 -5
  77. package/.output/server/chunks/build/{checkbox-Dv1kjaUZ.mjs.map → checkbox-C1gABOca.mjs.map} +1 -1
  78. package/.output/server/chunks/build/{daq-B-3xCp_2.mjs → daq-ChYCABz1.mjs} +312 -426
  79. package/.output/server/chunks/build/daq-ChYCABz1.mjs.map +1 -0
  80. package/.output/server/chunks/build/{dcw-BL2dhuz7.mjs → dcw-CcQNGggh.mjs} +3 -3
  81. package/.output/server/chunks/build/{dcw-BL2dhuz7.mjs.map → dcw-CcQNGggh.mjs.map} +1 -1
  82. package/.output/server/chunks/build/{default-DdV642BY.mjs → default-95-zOTPt.mjs} +3 -4
  83. package/.output/server/chunks/build/{default-DdV642BY.mjs.map → default-95-zOTPt.mjs.map} +1 -1
  84. package/.output/server/chunks/build/dropdown-vhn1NPFs.mjs +1 -1
  85. package/.output/server/chunks/build/{input-number-CZ3ZrCsy.mjs → input-number-Bd55elNN.mjs} +3 -3
  86. package/.output/server/chunks/build/{input-number-CZ3ZrCsy.mjs.map → input-number-Bd55elNN.mjs.map} +1 -1
  87. package/.output/server/chunks/build/{input-DxDqeyQW.mjs → input-sf_BT6o6.mjs} +553 -5
  88. package/.output/server/chunks/build/input-sf_BT6o6.mjs.map +1 -0
  89. package/.output/server/chunks/build/{logs-Dto_umFY.mjs → logs-D-2UyGtE.mjs} +3 -3
  90. package/.output/server/chunks/build/{logs-Dto_umFY.mjs.map → logs-D-2UyGtE.mjs.map} +1 -1
  91. package/.output/server/chunks/build/menu-WCrlpYVh.mjs +2 -2
  92. package/.output/server/chunks/build/modal-yvUquPj5.mjs +2 -2
  93. package/.output/server/chunks/build/{monitor-miqq9xHB.mjs → monitor-mfG5jBtz.mjs} +70 -192
  94. package/.output/server/chunks/build/monitor-mfG5jBtz.mjs.map +1 -0
  95. package/.output/server/chunks/build/{pages-D9tOoJsf.mjs → pages-Dfosfchr.mjs} +5 -6
  96. package/.output/server/chunks/build/pages-Dfosfchr.mjs.map +1 -0
  97. package/.output/server/chunks/build/{permissions-CxEgXic0.mjs → permissions-B-hhZuzm.mjs} +288 -194
  98. package/.output/server/chunks/build/permissions-B-hhZuzm.mjs.map +1 -0
  99. package/.output/server/chunks/build/{plugins-wLIKHcIE.mjs → plugins-DZR0T4Mh.mjs} +17 -17
  100. package/.output/server/chunks/build/{plugins-wLIKHcIE.mjs.map → plugins-DZR0T4Mh.mjs.map} +1 -1
  101. package/.output/server/chunks/build/popconfirm-CRaHcz5O.mjs +1 -1
  102. package/.output/server/chunks/build/{segmented-ChmQZwz6.mjs → segmented-LPPREMtZ.mjs} +336 -5
  103. package/.output/server/chunks/build/{segmented-ChmQZwz6.mjs.map → segmented-LPPREMtZ.mjs.map} +1 -1
  104. package/.output/server/chunks/build/{settings-BPBll_7K.mjs → settings-BajN9TQW.mjs} +254 -27
  105. package/.output/server/chunks/build/settings-BajN9TQW.mjs.map +1 -0
  106. package/.output/server/chunks/build/space-CCBYAkXt.mjs +1 -1
  107. package/.output/server/chunks/build/switch-CelRXpcy.mjs +1 -1
  108. package/.output/server/chunks/build/{table-BtksyDlQ.mjs → table-Bf1r2JjE.mjs} +5 -5
  109. package/.output/server/chunks/build/{table-BtksyDlQ.mjs.map → table-Bf1r2JjE.mjs.map} +1 -1
  110. package/.output/server/chunks/build/{tabs-DQv-_-R6.mjs → tabs-BM3tAh_J.mjs} +2 -2
  111. package/.output/server/chunks/build/{tabs-DQv-_-R6.mjs.map → tabs-BM3tAh_J.mjs.map} +1 -1
  112. package/.output/server/chunks/build/{tag-A0tZ2Ouq.mjs → tag-NO9jEqKy.mjs} +3 -3
  113. package/.output/server/chunks/build/{tag-A0tZ2Ouq.mjs.map → tag-NO9jEqKy.mjs.map} +1 -1
  114. package/.output/server/chunks/build/{teams-DD8ZXTKL.mjs → teams-t2SkRlJP.mjs} +349 -51
  115. package/.output/server/chunks/build/teams-t2SkRlJP.mjs.map +1 -0
  116. package/.output/server/chunks/build/{tokens-Dxnuw96_.mjs → tokens-DiCojbN8.mjs} +296 -200
  117. package/.output/server/chunks/build/tokens-DiCojbN8.mjs.map +1 -0
  118. package/.output/server/chunks/build/{town-Dsh0jlwZ.mjs → town-C7QM8DYK.mjs} +5 -5
  119. package/.output/server/chunks/build/{town-Dsh0jlwZ.mjs.map → town-C7QM8DYK.mjs.map} +1 -1
  120. package/.output/server/chunks/build/{useDaqStream-DkRL3tEW.mjs → useDaqStream-BeA2X8KR.mjs} +26 -11
  121. package/.output/server/chunks/build/useDaqStream-BeA2X8KR.mjs.map +1 -0
  122. package/.output/server/chunks/build/{useDcwStream-DyB2ufQI.mjs → useDcwStream-BJW_MitY.mjs} +14 -6
  123. package/.output/server/chunks/build/useDcwStream-BJW_MitY.mjs.map +1 -0
  124. package/.output/server/chunks/build/{useDeviceTwins-ZbT86L9O.mjs → useDeviceTwins-Dwz_EY_i.mjs} +2 -2
  125. package/.output/server/chunks/build/{useDeviceTwins-ZbT86L9O.mjs.map → useDeviceTwins-Dwz_EY_i.mjs.map} +1 -1
  126. package/.output/server/chunks/build/{useOpsLog-8HCYFb6n.mjs → useOpsLog-Dm8QEb1I.mjs} +2 -2
  127. package/.output/server/chunks/build/{useOpsLog-8HCYFb6n.mjs.map → useOpsLog-Dm8QEb1I.mjs.map} +1 -1
  128. package/.output/server/chunks/build/{useWorkshopApi-D2gq06N2.mjs → useWorkshopApi-B-L3MmIX.mjs} +9 -2
  129. package/.output/server/chunks/build/{useWorkshopApi-D2gq06N2.mjs.map → useWorkshopApi-B-L3MmIX.mjs.map} +1 -1
  130. package/.output/server/chunks/build/{users-D6RNylrW.mjs → users-B9SAdEtH.mjs} +12 -13
  131. package/.output/server/chunks/build/users-B9SAdEtH.mjs.map +1 -0
  132. package/.output/server/chunks/build/{workshop-CTcYDq2i.mjs → workshop-81xhz368.mjs} +21 -22
  133. package/.output/server/chunks/build/workshop-81xhz368.mjs.map +1 -0
  134. package/.output/server/chunks/routes/api/plugins/_name/_...path_.mjs +14 -2
  135. package/.output/server/chunks/routes/api/plugins/_name/_...path_.mjs.map +1 -1
  136. package/.output/server/chunks/routes/api/workshop/channel-templates/_id/instantiate.post.mjs +1 -1
  137. package/.output/server/chunks/routes/api/workshop/channels/_id/index.put.mjs +40 -0
  138. package/.output/server/chunks/routes/api/workshop/channels/_id/index.put.mjs.map +1 -0
  139. package/.output/server/chunks/routes/api/workshop/channels/_id/index4.get.mjs +21 -9
  140. package/.output/server/chunks/routes/api/workshop/channels/_id/index4.get.mjs.map +1 -1
  141. package/.output/server/chunks/routes/api/workshop/channels/_id/index5.get.mjs +33 -0
  142. package/.output/server/chunks/routes/api/workshop/channels/_id/index5.get.mjs.map +1 -0
  143. package/.output/server/chunks/routes/api/workshop/channels/_id/terminals.get.mjs +1 -1
  144. package/.output/server/chunks/routes/api/workshop/channels.post.mjs +15 -1
  145. package/.output/server/chunks/routes/api/workshop/channels.post.mjs.map +1 -1
  146. package/.output/server/chunks/routes/api/workshop/daq/_id/bind.post.mjs +1 -1
  147. package/.output/server/chunks/routes/api/workshop/daq/_id/bindings.put.mjs +1 -1
  148. package/.output/server/chunks/routes/api/workshop/daq/_id/frames/content.get.mjs +1 -1
  149. package/.output/server/chunks/routes/api/workshop/daq/_id/frames.get.mjs +1 -1
  150. package/.output/server/chunks/routes/api/workshop/daq/_id/samples.get.mjs +1 -1
  151. package/.output/server/chunks/routes/api/workshop/daq/_id/test.post.mjs +1 -1
  152. package/.output/server/chunks/routes/api/workshop/daq/_id_.delete.mjs +1 -1
  153. package/.output/server/chunks/routes/api/workshop/daq/_id_.patch.mjs +1 -1
  154. package/.output/server/chunks/routes/api/workshop/daq/alarms/_id/ack.post.mjs +1 -1
  155. package/.output/server/chunks/routes/api/workshop/daq/controller.post.mjs +1 -1
  156. package/.output/server/chunks/routes/api/workshop/daq/index.post.mjs +1 -1
  157. package/.output/server/chunks/routes/api/workshop/daq/infra/reconnect.post.mjs +1 -1
  158. package/.output/server/chunks/routes/api/workshop/daq/infra.get.mjs +1 -1
  159. package/.output/server/chunks/routes/api/workshop/daq/templates/_key_.delete.mjs +1 -1
  160. package/.output/server/chunks/routes/api/workshop/daq/templates/_key_.patch.mjs +1 -1
  161. package/.output/server/chunks/routes/api/workshop/daq/test-driver.post.mjs +1 -1
  162. package/.output/server/chunks/routes/api/workshop/dcw/_id/bind.post.mjs +1 -1
  163. package/.output/server/chunks/routes/api/workshop/dcw/_id/bindings.put.mjs +1 -1
  164. package/.output/server/chunks/routes/api/workshop/dcw/_id/param-ledger.get.mjs +1 -1
  165. package/.output/server/chunks/routes/api/workshop/dcw/_id/read.post.mjs +1 -1
  166. package/.output/server/chunks/routes/api/workshop/dcw/_id/test.post.mjs +1 -1
  167. package/.output/server/chunks/routes/api/workshop/dcw/_id/write.post.mjs +1 -1
  168. package/.output/server/chunks/routes/api/workshop/dcw/_id_.delete.mjs +1 -1
  169. package/.output/server/chunks/routes/api/workshop/dcw/_id_.patch.mjs +1 -1
  170. package/.output/server/chunks/routes/api/workshop/dcw/controller.post.mjs +1 -1
  171. package/.output/server/chunks/routes/api/workshop/dcw/index.get.mjs +1 -1
  172. package/.output/server/chunks/routes/api/workshop/dcw/index.post.mjs +1 -1
  173. package/.output/server/chunks/routes/api/workshop/dcw/index2.get.mjs +1 -1
  174. package/.output/server/chunks/routes/api/workshop/dcw/index2.post.mjs +1 -1
  175. package/.output/server/chunks/routes/api/workshop/dcw/index3.get.mjs +1 -1
  176. package/.output/server/chunks/routes/api/workshop/dcw/index3.post.mjs +1 -1
  177. package/.output/server/chunks/routes/api/workshop/dcw/index4.get.mjs +1 -1
  178. package/.output/server/chunks/routes/api/workshop/dcw/index4.post.mjs +1 -1
  179. package/.output/server/chunks/routes/api/workshop/dcw/index5.get.mjs +1 -1
  180. package/.output/server/chunks/routes/api/workshop/dcw/journal/node/_nodeId/rollback.post.mjs +1 -1
  181. package/.output/server/chunks/routes/api/workshop/dcw/line/query.get.mjs +1 -1
  182. package/.output/server/chunks/routes/api/workshop/dcw/lines/_id/start.post.mjs +1 -1
  183. package/.output/server/chunks/routes/api/workshop/dcw/lines/_id/stop.post.mjs +1 -1
  184. package/.output/server/chunks/routes/api/workshop/dcw/lines/_id_.delete.mjs +1 -1
  185. package/.output/server/chunks/routes/api/workshop/dcw/optimizations/_id/judge.post.mjs +1 -1
  186. package/.output/server/chunks/routes/api/workshop/dcw/optimizations/_id/rollback.post.mjs +1 -1
  187. package/.output/server/chunks/routes/api/workshop/dcw/optimizations/_id/series.get.mjs +1 -1
  188. package/.output/server/chunks/routes/api/workshop/dcw/optimizations/_id_.get.mjs +1 -1
  189. package/.output/server/chunks/routes/api/workshop/dcw/products/_id_.delete.mjs +1 -1
  190. package/.output/server/chunks/routes/api/workshop/dcw/products/_id_.patch.mjs +1 -1
  191. package/.output/server/chunks/routes/api/workshop/dcw/recipes/_id/apply.post.mjs +1 -1
  192. package/.output/server/chunks/routes/api/workshop/dcw/recipes/_id/mark-good.post.mjs +1 -1
  193. package/.output/server/chunks/routes/api/workshop/dcw/recipes/_id/rollback-good.post.mjs +1 -1
  194. package/.output/server/chunks/routes/api/workshop/dcw/recipes/_id_.delete.mjs +1 -1
  195. package/.output/server/chunks/routes/api/workshop/dcw/runs/_id/close.post.mjs +1 -1
  196. package/.output/server/chunks/routes/api/workshop/dcw/runs/_id/data.get.mjs +1 -1
  197. package/.output/server/chunks/routes/api/workshop/dcw/runs/_id/rollback.post.mjs +1 -1
  198. package/.output/server/chunks/routes/api/workshop/dcw/templates/_key_.delete.mjs +1 -1
  199. package/.output/server/chunks/routes/api/workshop/dcw/templates/_key_.patch.mjs +1 -1
  200. package/.output/server/chunks/routes/api/workshop/dcw/test-driver.post.mjs +1 -1
  201. package/.output/server/chunks/routes/api/workshop/device-twins/_id_.delete.mjs +1 -1
  202. package/.output/server/chunks/routes/api/workshop/device-twins/_id_.patch.mjs +1 -1
  203. package/.output/server/chunks/routes/api/workshop/harnesses/_id/providers.get.mjs +1 -1
  204. package/.output/server/chunks/routes/api/workshop/harnesses.get.mjs +1 -1
  205. package/.output/server/chunks/routes/api/workshop/hitl/pending.get.mjs +1 -1
  206. package/.output/server/chunks/routes/api/workshop/hitl/respond.post.mjs +1 -1
  207. package/.output/server/chunks/routes/api/workshop/index.put.mjs +1 -1
  208. package/.output/server/chunks/routes/api/workshop/index3.post.mjs +1 -1
  209. package/.output/server/chunks/routes/api/workshop/index4.get.mjs +1 -1
  210. package/.output/server/chunks/routes/api/workshop/index4.post.mjs +1 -1
  211. package/.output/server/chunks/routes/api/workshop/index5.get.mjs +1 -1
  212. package/.output/server/chunks/routes/api/workshop/index5.post.mjs +1 -1
  213. package/.output/server/chunks/routes/api/workshop/index6.post.mjs +1 -1
  214. package/.output/server/chunks/routes/api/workshop/plugins/_name/disable.post.mjs +1 -1
  215. package/.output/server/chunks/routes/api/workshop/plugins/_name/enable.post.mjs +1 -1
  216. package/.output/server/chunks/routes/api/workshop/scene/layouts/_channelId_.delete.mjs +1 -1
  217. package/.output/server/chunks/routes/api/workshop/scene/layouts/_channelId_.put.mjs +1 -1
  218. package/.output/server/chunks/routes/api/workshop/workspaces/_id/channel-templates/_tplId_.post.mjs +1 -1
  219. package/.output/server/chunks/routes/renderer.mjs +3 -3
  220. package/.output/server/chunks/virtual/entry.mjs +381 -438
  221. package/.output/server/chunks/virtual/entry.mjs.map +1 -1
  222. package/.output/server/chunks/virtual/precomputed.mjs +1 -1
  223. package/.output/server/package.json +1 -1
  224. package/app/app.vue +7 -0
  225. package/app/assets/css/main.css +12 -1
  226. package/app/components/workshop/DaqNodeRow.vue +398 -0
  227. package/app/components/workshop/town/ModelPreview3D.vue +26 -4
  228. package/app/components/workshop/town/TownScene3D.ts +60 -12
  229. package/app/components/workshop/town/TownView.vue +4 -3
  230. package/app/composables/workshop/useCharacterAssets.ts +1 -0
  231. package/app/composables/workshop/useDaqStream.ts +24 -5
  232. package/app/composables/workshop/useDcwStream.ts +13 -4
  233. package/app/composables/workshop/useWorkshopApi.ts +294 -259
  234. package/app/pages/daq/[id].vue +27 -3
  235. package/app/pages/daq/index.vue +8 -355
  236. package/app/pages/monitor.vue +56 -68
  237. package/app/pages/permissions/index.vue +86 -82
  238. package/app/pages/plugins/index.vue +12 -7
  239. package/app/pages/settings.vue +253 -2
  240. package/app/pages/tokens.vue +94 -96
  241. package/app/pages/users.vue +10 -18
  242. package/app/pages/workshop/index.vue +34 -5
  243. package/app/pages/workshop/teams.vue +212 -2
  244. package/i18n/dicts/_en.json +361 -1
  245. package/i18n/dicts/plugins.json +10 -0
  246. package/i18n/dicts/settings.json +1 -0
  247. package/i18n/dicts/teamPlugins.json +10 -0
  248. package/i18n/locales/en.ts +1861 -1901
  249. package/i18n/locales/zh-CN.ts +1789 -1830
  250. package/package.json +149 -148
  251. package/public/assets/game/character/yangyang-walk.glb +0 -0
  252. package/scripts/_dbg-cpu-profile.mjs +53 -0
  253. package/scripts/_dbg-logs-ui-e2e.py +3 -2
  254. package/scripts/_dbg-render-perf.mjs +142 -0
  255. package/scripts/_dbg-render-regression.mjs +130 -0
  256. package/scripts/_dbg-ui-survey.py +52 -0
  257. package/scripts/i18n-merge.mjs +152 -30
  258. package/scripts/production-closed-loop-e2e.mjs +254 -0
  259. package/scripts/team-plugins-api-smoke.mjs +149 -0
  260. package/scripts/three-system-e2e.mjs +448 -0
  261. package/server/api/plugins/[name]/[...path].ts +46 -31
  262. package/server/api/workshop/channels/[id]/plugins/index.get.ts +35 -0
  263. package/server/api/workshop/channels/[id]/plugins/index.put.ts +39 -0
  264. package/server/api/workshop/channels.post.ts +17 -0
  265. package/server/data/dcw-lines.json +14 -0
  266. package/server/data/dcw-products.json +14 -0
  267. package/server/data/dcw-recipes.json +23 -1
  268. package/server/data/dcw-rollback.json +585 -10
  269. package/server/data/dcw-runs.json +27 -27
  270. package/server/data/dcw-writes.json +96 -0
  271. package/server/data/dcws.json +394 -366
  272. package/server/data/scene-layouts.json +66 -0
  273. package/server/plugins/aw-plugins.ts +35 -27
  274. package/server/plugins-builtin/diag-bridge/index.mjs +556 -0
  275. package/server/plugins-builtin/rag-bridge/index.mjs +364 -0
  276. package/server/services/workshop/agents/host-tool-bridge.ts +659 -642
  277. package/server/services/workshop/agents/omp-agent.ts +1178 -1178
  278. package/server/services/workshop/agents/plugin-tools.ts +10 -1
  279. package/server/services/workshop/db/channel-plugins.repo.ts +65 -0
  280. package/server/services/workshop/plugins/host.mjs +52 -4
  281. package/server/services/workshop/runtime/manager.ts +2976 -2968
  282. package/shared/config/schema.json +4 -0
  283. package/.output/public/_nuxt/BJbhwS5o.js +0 -1
  284. package/.output/public/_nuxt/BUcmySDa2.js +0 -209
  285. package/.output/public/_nuxt/BWC4HQHQ.js +0 -1
  286. package/.output/public/_nuxt/BbZAzXjZ2.js +0 -1
  287. package/.output/public/_nuxt/BgOhoDTI.js +0 -1
  288. package/.output/public/_nuxt/Bo8t5fkJ.js +0 -1
  289. package/.output/public/_nuxt/BuiGDfMB.js +0 -1
  290. package/.output/public/_nuxt/BxPPAkGA.js +0 -3
  291. package/.output/public/_nuxt/C53drffV.js +0 -1
  292. package/.output/public/_nuxt/CcwJ2mrD2.js +0 -1
  293. package/.output/public/_nuxt/Cr9DkD1d.js +0 -1
  294. package/.output/public/_nuxt/DTYBfjRY.js +0 -1
  295. package/.output/public/_nuxt/DVoWWlUW.js +0 -1
  296. package/.output/public/_nuxt/Dc32T41C.js +0 -1
  297. package/.output/public/_nuxt/Dhqra7NB.js +0 -1
  298. package/.output/public/_nuxt/DlRO_q5L.js +0 -1
  299. package/.output/public/_nuxt/DsUUYP292.js +0 -1
  300. package/.output/public/_nuxt/Dsdy4Ua-.js +0 -1
  301. package/.output/public/_nuxt/DtzZqC0z.js +0 -1
  302. package/.output/public/_nuxt/Ko9mMsJj.js +0 -14
  303. package/.output/public/_nuxt/RzXYI9FM.js +0 -23
  304. package/.output/public/_nuxt/UtviM1bg.js +0 -1
  305. package/.output/public/_nuxt/_id_.C-YXjn8Q.css +0 -1
  306. package/.output/public/_nuxt/bAFueD6a.js +0 -1
  307. package/.output/public/_nuxt/builds/meta/1adc96e0-8bbd-4a79-ac7e-b6952556fef8.json +0 -1
  308. package/.output/public/_nuxt/daq.3OKj58HH.css +0 -1
  309. package/.output/public/_nuxt/dbi5bHkY.js +0 -2
  310. package/.output/public/_nuxt/eHYnGew0.js +0 -19
  311. package/.output/public/_nuxt/entry.OR_psZHp.css +0 -1
  312. package/.output/public/_nuxt/jyQyulh-.js +0 -1
  313. package/.output/public/_nuxt/monitor.CmwpEUCI.css +0 -1
  314. package/.output/public/_nuxt/permissions.DTRtZeTw.css +0 -1
  315. package/.output/public/_nuxt/plugins.BcSEwwGb.css +0 -1
  316. package/.output/public/_nuxt/settings.BqMF2nfj.css +0 -1
  317. package/.output/public/_nuxt/teams.DN0pAGGu.css +0 -1
  318. package/.output/public/_nuxt/tokens.BVXU1jOK.css +0 -1
  319. package/.output/public/_nuxt/users.D8lcLE62.css +0 -1
  320. package/.output/public/_nuxt/workshop.CbymC2LY.css +0 -1
  321. package/.output/public/_nuxt/zVkqCZ78.js +0 -1
  322. package/.output/server/chunks/build/Col-biaNnEPf.mjs +0 -338
  323. package/.output/server/chunks/build/Col-biaNnEPf.mjs.map +0 -1
  324. package/.output/server/chunks/build/agents--6bzGtES.mjs.map +0 -1
  325. package/.output/server/chunks/build/channel-templates-C1Bb-U75.mjs.map +0 -1
  326. package/.output/server/chunks/build/daq-B-3xCp_2.mjs.map +0 -1
  327. package/.output/server/chunks/build/hasIn-vQ9LWt-J.mjs +0 -554
  328. package/.output/server/chunks/build/hasIn-vQ9LWt-J.mjs.map +0 -1
  329. package/.output/server/chunks/build/input-DxDqeyQW.mjs.map +0 -1
  330. package/.output/server/chunks/build/monitor-miqq9xHB.mjs.map +0 -1
  331. package/.output/server/chunks/build/pages-D9tOoJsf.mjs.map +0 -1
  332. package/.output/server/chunks/build/permissions-CxEgXic0.mjs.map +0 -1
  333. package/.output/server/chunks/build/settings-BPBll_7K.mjs.map +0 -1
  334. package/.output/server/chunks/build/teams-DD8ZXTKL.mjs.map +0 -1
  335. package/.output/server/chunks/build/tokens-Dxnuw96_.mjs.map +0 -1
  336. package/.output/server/chunks/build/useDaqStream-DkRL3tEW.mjs.map +0 -1
  337. package/.output/server/chunks/build/useDcwStream-DyB2ufQI.mjs.map +0 -1
  338. package/.output/server/chunks/build/useSiteConfig-DJe_KMVr.mjs +0 -27
  339. package/.output/server/chunks/build/useSiteConfig-DJe_KMVr.mjs.map +0 -1
  340. package/.output/server/chunks/build/users-D6RNylrW.mjs.map +0 -1
  341. package/.output/server/chunks/build/workshop-CTcYDq2i.mjs.map +0 -1
  342. /package/.output/public/_nuxt/{CNs_Ozdc.js → CNs_Ozdc2.js} +0 -0
  343. /package/.output/public/_nuxt/{Cno6kYiO.js → Cno6kYiO2.js} +0 -0
  344. /package/.output/public/_nuxt/{ORt9oDIy2.js → ORt9oDIy.js} +0 -0
@@ -1,4 +1,4 @@
1
- import{G as e,I as t,K as n,W as r,q as i}from"./rqZ-1SoP.js";import{A as a,B as o,C as s,F as c,G as l,H as u,Ht as d,M as f,O as p,Q as m,St as h,U as g,Ut as _,V as v,Wt as y,Y as b,a as x,b as S,bt as C,c as w,d as T,dt as E,et as D,f as O,ft as k,g as A,gt as j,h as M,lt as N,m as P,mt as F,nt as I,p as L,q as R,rt as z,t as B,x as V,y as H,z as U}from"./BSCpFtzG.js";import{d as W,p as G}from"./-6OnbLFb.js";import{n as K}from"./B5S_UyaC.js";import{n as q}from"./BeIfu4N3.js";import{t as J}from"./DpojD719.js";import{t as Y}from"./DXRZPxGs.js";import{$ as X,At as Z,Ct as ee,E as te,J as ne,O as re,Q as ie,X as ae,Z as oe,at as se,ct as ce,d as le,et as ue,h as de,it as fe,j as pe,kt as Q,m as me,n as he,pt as ge,t as _e,tt as ve,u as ye}from"./BDUjyaF4.js";import{$ as be,c as xe,i as Se}from"./DtBu71ev.js";import{t as Ce}from"./BfGc7TJp.js";import{G as we,V as Te,t as Ee}from"./VLI2Zy4t.js";import{n as De,r as Oe,t as ke}from"./eHYnGew0.js";import{a as Ae,i as je,t as Me}from"./BN_PdN3J.js";import{f as Ne,p as Pe,r as $,s as Fe,x as Ie}from"./D-Ca4BGY.js";import{a as Le,i as Re,n as ze,r as Be,t as Ve}from"./RzXYI9FM.js";import{i as He,n as Ue,r as We,t as Ge}from"./B-xskWta.js";import{t as Ke}from"./CKfhtOt7.js";import{n as qe,r as Je,t as Ye}from"./BxPPAkGA.js";import{t as Xe}from"./BBwMH_hG.js";import{t as Ze}from"./DTYBfjRY.js";import{t as Qe}from"./lO5tpDZ5.js";import{t as $e}from"./D1z7i2UP.js";import{t as et}from"./ORt9oDIy2.js";import{t as tt}from"./DA4lxCWC2.js";import{n as nt,r as rt,t as it}from"./DWcEk1ur2.js";import{t as at}from"./Bp5luxkg2.js";import{t as ot}from"./C9f8QMp12.js";import{t as st}from"./DoLasgPj2.js";import{t as ct}from"./BcrN7QEl2.js";import{t as lt}from"./C4OAdbVK2.js";import{t as ut}from"./G0qIw7Gq2.js";import{a as dt,c as ft,d as pt,f as mt,i as ht,l as gt,m as _t,n as vt,o as yt,r as bt,s as xt,t as St,u as Ct}from"./arUY5dyq2.js";import{t as wt}from"./kZV5TQvh2.js";import{t as Tt}from"./CNs_Ozdc.js";import{t as Et}from"./DeYsUzhr.js";import{t as Dt}from"./BxtpDtzC.js";import{n as Ot,t as kt}from"./dbi5bHkY.js";function At(e){let{prefixCls:t,value:n,current:r,offset:i=0}=e,a;return i&&(a={position:`absolute`,top:`${i}00%`,left:0}),V(`p`,{style:a,class:ee(`${t}-only-unit`,{current:r})},[n])}function jt(e,t,n){let r=e,i=0;for(;(r+10)%10!==t;)r+=n,i+=n;return i}var Mt=s({compatConfig:{MODE:3},name:`SingleNumber`,props:{prefixCls:String,value:String,count:Number},setup(e){let t=O(()=>Number(e.value)),n=O(()=>Math.abs(e.count)),r=k({prevValue:t.value,prevCount:n.value}),i=()=>{r.prevValue=t.value,r.prevCount=n.value},a=F();return D(t,()=>{clearTimeout(a.value),a.value=setTimeout(()=>{i()},1e3)},{flush:`post`}),o(()=>{clearTimeout(a.value)}),()=>{let a,o={},s=t.value;if(r.prevValue===s||Number.isNaN(s)||Number.isNaN(r.prevValue))a=[At(Q(Q({},e),{current:!0}))],o={transition:`none`};else{a=[];let t=s+10,i=[];for(let e=s;e<=t;e+=1)i.push(e);let c=i.findIndex(e=>e%10===r.prevValue);a=i.map((t,n)=>{let r=t%10;return At(Q(Q({},e),{value:r,offset:n-c,current:n===c}))});let l=r.prevCount<n.value?1:-1;o={transform:`translateY(${-jt(r.prevValue,s,l)}00%)`}}return V(`span`,{class:`${e.prefixCls}-only`,style:o,onTransitionend:()=>i()},[a])}}}),Nt=function(e,t){var n={};for(var r in e)Object.prototype.hasOwnProperty.call(e,r)&&t.indexOf(r)<0&&(n[r]=e[r]);if(e!=null&&typeof Object.getOwnPropertySymbols==`function`)for(var i=0,r=Object.getOwnPropertySymbols(e);i<r.length;i++)t.indexOf(r[i])<0&&Object.prototype.propertyIsEnumerable.call(e,r[i])&&(n[r[i]]=e[r[i]]);return n},Pt={prefixCls:String,count:_e.any,component:String,title:_e.any,show:Boolean},Ft=s({compatConfig:{MODE:3},name:`ScrollNumber`,inheritAttrs:!1,props:Pt,setup(e,t){let{attrs:n,slots:r}=t,{prefixCls:i}=he(`scroll-number`,e);return()=>{let t=Q(Q({},e),n),{prefixCls:a,count:o,title:s,show:c,component:l=`sup`,class:u,style:d}=t,f=Nt(t,[`prefixCls`,`count`,`title`,`show`,`component`,`class`,`style`]),p=Q(Q({},f),{style:d,"data-show":e.show,class:ee(i.value,u),title:s}),m=o;if(o&&Number(o)%1==0){let e=String(o).split(``);m=e.map((t,n)=>V(Mt,{prefixCls:i.value,count:Number(o),value:t,key:e.length-n},null))}d&&d.borderColor&&(p.style=Q(Q({},d),{boxShadow:`0 0 0 1px ${d.borderColor} inset`}));let h=se(r.default?.call(r));return h&&h.length?Te(h,{class:ee(`${i.value}-custom-component`)},!1):V(l,p,{default:()=>[m]})}}}),It=new re(`antStatusProcessing`,{"0%":{transform:`scale(0.8)`,opacity:.5},"100%":{transform:`scale(2.4)`,opacity:0}}),Lt=new re(`antZoomBadgeIn`,{"0%":{transform:`scale(0) translate(50%, -50%)`,opacity:0},"100%":{transform:`scale(1) translate(50%, -50%)`}}),Rt=new re(`antZoomBadgeOut`,{"0%":{transform:`scale(1) translate(50%, -50%)`},"100%":{transform:`scale(0) translate(50%, -50%)`,opacity:0}}),zt=new re(`antNoWrapperZoomBadgeIn`,{"0%":{transform:`scale(0)`,opacity:0},"100%":{transform:`scale(1)`}}),Bt=new re(`antNoWrapperZoomBadgeOut`,{"0%":{transform:`scale(1)`},"100%":{transform:`scale(0)`,opacity:0}}),Vt=new re(`antBadgeLoadingCircle`,{"0%":{transformOrigin:`50%`},"100%":{transform:`translate(50%, -50%) rotate(360deg)`,transformOrigin:`50%`}}),Ht=e=>{let{componentCls:t,iconCls:n,antCls:r,badgeFontHeight:i,badgeShadowSize:a,badgeHeightSm:o,motionDurationSlow:s,badgeStatusSize:c,marginXS:l,badgeRibbonOffset:u}=e,d=`${r}-scroll-number`,f=`${r}-ribbon`,p=`${r}-ribbon-wrapper`,m=be(e,(e,n)=>{let{darkColor:r}=n;return{[`&${t} ${t}-color-${e}`]:{background:r,[`&:not(${t}-count)`]:{color:r}}}}),h=be(e,(e,t)=>{let{darkColor:n}=t;return{[`&${f}-color-${e}`]:{background:n,color:n}}});return{[t]:Q(Q(Q(Q({},de(e)),{position:`relative`,display:`inline-block`,width:`fit-content`,lineHeight:1,[`${t}-count`]:{zIndex:e.badgeZIndex,minWidth:e.badgeHeight,height:e.badgeHeight,color:e.badgeTextColor,fontWeight:e.badgeFontWeight,fontSize:e.badgeFontSize,lineHeight:`${e.badgeHeight}px`,whiteSpace:`nowrap`,textAlign:`center`,background:e.badgeColor,borderRadius:e.badgeHeight/2,boxShadow:`0 0 0 ${a}px ${e.badgeShadowColor}`,transition:`background ${e.motionDurationMid}`,a:{color:e.badgeTextColor},"a:hover":{color:e.badgeTextColor},"a:hover &":{background:e.badgeColorHover}},[`${t}-count-sm`]:{minWidth:o,height:o,fontSize:e.badgeFontSizeSm,lineHeight:`${o}px`,borderRadius:o/2},[`${t}-multiple-words`]:{padding:`0 ${e.paddingXS}px`},[`${t}-dot`]:{zIndex:e.badgeZIndex,width:e.badgeDotSize,minWidth:e.badgeDotSize,height:e.badgeDotSize,background:e.badgeColor,borderRadius:`100%`,boxShadow:`0 0 0 ${a}px ${e.badgeShadowColor}`},[`${t}-dot${d}`]:{transition:`background ${s}`},[`${t}-count, ${t}-dot, ${d}-custom-component`]:{position:`absolute`,top:0,insetInlineEnd:0,transform:`translate(50%, -50%)`,transformOrigin:`100% 0%`,[`&${n}-spin`]:{animationName:Vt,animationDuration:`1s`,animationIterationCount:`infinite`,animationTimingFunction:`linear`}},[`&${t}-status`]:{lineHeight:`inherit`,verticalAlign:`baseline`,[`${t}-status-dot`]:{position:`relative`,top:-1,display:`inline-block`,width:c,height:c,verticalAlign:`middle`,borderRadius:`50%`},[`${t}-status-success`]:{backgroundColor:e.colorSuccess},[`${t}-status-processing`]:{overflow:`visible`,color:e.colorPrimary,backgroundColor:e.colorPrimary,"&::after":{position:`absolute`,top:0,insetInlineStart:0,width:`100%`,height:`100%`,borderWidth:a,borderStyle:`solid`,borderColor:`inherit`,borderRadius:`50%`,animationName:It,animationDuration:e.badgeProcessingDuration,animationIterationCount:`infinite`,animationTimingFunction:`ease-in-out`,content:`""`}},[`${t}-status-default`]:{backgroundColor:e.colorTextPlaceholder},[`${t}-status-error`]:{backgroundColor:e.colorError},[`${t}-status-warning`]:{backgroundColor:e.colorWarning},[`${t}-status-text`]:{marginInlineStart:l,color:e.colorText,fontSize:e.fontSize}}}),m),{[`${t}-zoom-appear, ${t}-zoom-enter`]:{animationName:Lt,animationDuration:e.motionDurationSlow,animationTimingFunction:e.motionEaseOutBack,animationFillMode:`both`},[`${t}-zoom-leave`]:{animationName:Rt,animationDuration:e.motionDurationSlow,animationTimingFunction:e.motionEaseOutBack,animationFillMode:`both`},[`&${t}-not-a-wrapper`]:{[`${t}-zoom-appear, ${t}-zoom-enter`]:{animationName:zt,animationDuration:e.motionDurationSlow,animationTimingFunction:e.motionEaseOutBack},[`${t}-zoom-leave`]:{animationName:Bt,animationDuration:e.motionDurationSlow,animationTimingFunction:e.motionEaseOutBack},[`&:not(${t}-status)`]:{verticalAlign:`middle`},[`${d}-custom-component, ${t}-count`]:{transform:`none`},[`${d}-custom-component, ${d}`]:{position:`relative`,top:`auto`,display:`block`,transformOrigin:`50% 50%`}},[`${d}`]:{overflow:`hidden`,[`${d}-only`]:{position:`relative`,display:`inline-block`,height:e.badgeHeight,transition:`all ${e.motionDurationSlow} ${e.motionEaseOutBack}`,WebkitTransformStyle:`preserve-3d`,WebkitBackfaceVisibility:`hidden`,[`> p${d}-only-unit`]:{height:e.badgeHeight,margin:0,WebkitTransformStyle:`preserve-3d`,WebkitBackfaceVisibility:`hidden`}},[`${d}-symbol`]:{verticalAlign:`top`}},"&-rtl":{direction:`rtl`,[`${t}-count, ${t}-dot, ${d}-custom-component`]:{transform:`translate(-50%, -50%)`}}}),[`${p}`]:{position:`relative`},[`${f}`]:Q(Q(Q(Q({},de(e)),{position:`absolute`,top:l,padding:`0 ${e.paddingXS}px`,color:e.colorPrimary,lineHeight:`${i}px`,whiteSpace:`nowrap`,backgroundColor:e.colorPrimary,borderRadius:e.borderRadiusSM,[`${f}-text`]:{color:e.colorTextLightSolid},[`${f}-corner`]:{position:`absolute`,top:`100%`,width:u,height:u,color:`currentcolor`,border:`${u/2}px solid`,transform:e.badgeRibbonCornerTransform,transformOrigin:`top`,filter:e.badgeRibbonCornerFilter}}),h),{[`&${f}-placement-end`]:{insetInlineEnd:-u,borderEndEndRadius:0,[`${f}-corner`]:{insetInlineEnd:0,borderInlineEndColor:`transparent`,borderBlockEndColor:`transparent`}},[`&${f}-placement-start`]:{insetInlineStart:-u,borderEndStartRadius:0,[`${f}-corner`]:{insetInlineStart:0,borderBlockEndColor:`transparent`,borderInlineStartColor:`transparent`}},"&-rtl":{direction:`rtl`}})}},Ut=le(`Badge`,e=>{let{fontSize:t,lineHeight:n,fontSizeSM:r,lineWidth:i,marginXS:a,colorBorderBg:o}=e,s=Math.round(t*n),c=i,l=s-2*c,u=e.colorBgContainer,d=r,f=e.colorError,p=e.colorErrorHover,m=t,h=r/2,g=r,_=r/2;return[Ht(ye(e,{badgeFontHeight:s,badgeShadowSize:c,badgeZIndex:`auto`,badgeHeight:l,badgeTextColor:u,badgeFontWeight:`normal`,badgeFontSize:d,badgeColor:f,badgeColorHover:p,badgeShadowColor:o,badgeHeightSm:m,badgeDotSize:h,badgeFontSizeSm:g,badgeStatusSize:_,badgeProcessingDuration:`1.2s`,badgeRibbonOffset:a,badgeRibbonCornerTransform:`scaleY(0.75)`,badgeRibbonCornerFilter:`brightness(75%)`}))]}),Wt=function(e,t){var n={};for(var r in e)Object.prototype.hasOwnProperty.call(e,r)&&t.indexOf(r)<0&&(n[r]=e[r]);if(e!=null&&typeof Object.getOwnPropertySymbols==`function`)for(var i=0,r=Object.getOwnPropertySymbols(e);i<r.length;i++)t.indexOf(r[i])<0&&Object.prototype.propertyIsEnumerable.call(e,r[i])&&(n[r[i]]=e[r[i]]);return n},Gt=s({compatConfig:{MODE:3},name:`ABadgeRibbon`,inheritAttrs:!1,props:{prefix:String,color:{type:String},text:_e.any,placement:{type:String,default:`end`}},slots:Object,setup(e,t){let{attrs:n,slots:r}=t,{prefixCls:i,direction:a}=he(`ribbon`,e),[o,s]=Ut(i),c=O(()=>xe(e.color,!1)),l=O(()=>[i.value,`${i.value}-placement-${e.placement}`,{[`${i.value}-rtl`]:a.value===`rtl`,[`${i.value}-color-${e.color}`]:c.value}]);return()=>{let{class:t,style:a}=n,u=Wt(n,[`class`,`style`]),d={},f={};return e.color&&!c.value&&(d.background=e.color,f.color=e.color),o(V(`div`,Z({class:`${i.value}-wrapper ${s.value}`},u),[r.default?.call(r),V(`div`,{class:[l.value,t,s.value],style:Q(Q({},d),a)},[V(`span`,{class:`${i.value}-text`},[e.text||r.text?.call(r)]),V(`div`,{class:`${i.value}-corner`,style:f},null)])]))}}}),Kt=s({compatConfig:{MODE:3},name:`ABadge`,Ribbon:Gt,inheritAttrs:!1,props:{count:_e.any.def(null),showZero:{type:Boolean,default:void 0},overflowCount:{type:Number,default:99},dot:{type:Boolean,default:void 0},prefixCls:String,scrollNumberPrefixCls:String,status:{type:String},size:{type:String,default:`default`},color:String,text:_e.any,offset:Array,numberStyle:{type:Object,default:void 0},title:String},slots:Object,setup(n,r){let{slots:i,attrs:a}=r,{prefixCls:o,direction:s}=he(`badge`,n),[c,l]=Ut(o),u=O(()=>n.count>n.overflowCount?`${n.overflowCount}+`:n.count),d=O(()=>u.value===`0`||u.value===0),f=O(()=>n.count===null||d.value&&!n.showZero),p=O(()=>(n.status!==null&&n.status!==void 0||n.color!==null&&n.color!==void 0)&&f.value),m=O(()=>n.dot&&!d.value),h=O(()=>m.value?``:u.value),g=O(()=>(h.value===null||h.value===void 0||h.value===``||d.value&&!n.showZero)&&!m.value),_=F(n.count),v=F(h.value),y=F(m.value);D([()=>n.count,h,m],()=>{g.value||(_.value=n.count,v.value=h.value,y.value=m.value)},{immediate:!0});let b=O(()=>xe(n.color,!1)),x=O(()=>({[`${o.value}-status-dot`]:p.value,[`${o.value}-status-${n.status}`]:!!n.status,[`${o.value}-color-${n.color}`]:b.value})),S=O(()=>n.color&&!b.value?{background:n.color,color:n.color}:{}),C=O(()=>({[`${o.value}-dot`]:y.value,[`${o.value}-count`]:!y.value,[`${o.value}-count-sm`]:n.size===`small`,[`${o.value}-multiple-words`]:!y.value&&v.value&&v.value.toString().length>1,[`${o.value}-status-${n.status}`]:!!n.status,[`${o.value}-color-${n.color}`]:b.value}));return()=>{let{offset:r,title:u,color:d}=n,f=a.style,m=ge(i,n,`text`),h=o.value,y=_.value,w=ce(i.default?.call(i));w=w.length?w:null;let T=!!(!g.value||i.count),E=(()=>{if(!r)return Q({},f);let e={marginTop:Qe(r[1])?`${r[1]}px`:r[1]};return s.value===`rtl`?e.left=`${parseInt(r[0],10)}px`:e.right=`${-parseInt(r[0],10)}px`,Q(Q({},e),f)})(),D=u??(typeof y==`string`||typeof y==`number`?y:void 0),O=T||!m?null:V(`span`,{class:`${h}-status-text`},[m]),k=typeof y==`object`||y===void 0&&i.count?Te(y??i.count?.call(i),{style:E},!1):null,A=ee(h,{[`${h}-status`]:p.value,[`${h}-not-a-wrapper`]:!w,[`${h}-rtl`]:s.value===`rtl`},a.class,l.value);if(!w&&p.value){let e=E.color;return c(V(`span`,Z(Z({},a),{},{class:A,style:E}),[V(`span`,{class:x.value,style:S.value},null),V(`span`,{style:{color:e},class:`${h}-status-text`},[m])]))}let j=Ie(w?`${h}-zoom`:``,{appear:!1}),M=Q(Q({},E),n.numberStyle);return d&&!b.value&&(M||={},M.background=d),c(V(`span`,Z(Z({},a),{},{class:A}),[w,V(t,j,{default:()=>[z(V(Ft,{prefixCls:n.scrollNumberPrefixCls,show:T,class:C.value,count:v.value,title:D,style:M,key:`scrollNumber`},{default:()=>[k]}),[[e,T]])]}),O]))}}});Kt.install=function(e){return e.component(Kt.name,Kt),e.component(Gt.name,Gt),e};var qt=Kt,Jt=function(e,t){var n={};for(var r in e)Object.prototype.hasOwnProperty.call(e,r)&&t.indexOf(r)<0&&(n[r]=e[r]);if(e!=null&&typeof Object.getOwnPropertySymbols==`function`)for(var i=0,r=Object.getOwnPropertySymbols(e);i<r.length;i++)t.indexOf(r[i])<0&&Object.prototype.propertyIsEnumerable.call(e,r[i])&&(n[r[i]]=e[r[i]]);return n},Yt=s({compatConfig:{MODE:3},name:`ABreadcrumbItem`,inheritAttrs:!1,__ANT_BREADCRUMB_ITEM:!0,props:{prefixCls:String,href:String,separator:_e.any,dropdownProps:X(),overlay:_e.any,onClick:oe()},slots:Object,setup(e,t){let{slots:n,attrs:r,emit:i}=t,{prefixCls:a}=he(`breadcrumb`,e),o=(t,r)=>{let i=ge(n,e,`overlay`);return i?V($e,Z(Z({},e.dropdownProps),{},{overlay:i,placement:`bottom`}),{default:()=>[V(`span`,{class:`${r}-overlay-link`},[t,V(Ae,null,null)])]}):t},s=e=>{i(`click`,e)};return()=>{let t=ge(n,e,`separator`)??`/`,i=ge(n,e),{class:c,style:l}=r,u=Jt(r,[`class`,`style`]),d;return d=e.href===void 0?V(`span`,Z({class:`${a.value}-link`,onClick:s},u),[i]):V(`a`,Z({class:`${a.value}-link`,onClick:s},u),[i]),d=o(d,a.value),i==null?null:V(`li`,{class:c,style:l},[d,t&&V(`span`,{class:`${a.value}-separator`},[t])])}}}),Xt=e=>{let{componentCls:t,iconCls:n}=e;return{[t]:Q(Q({},de(e)),{color:e.breadcrumbBaseColor,fontSize:e.breadcrumbFontSize,[n]:{fontSize:e.breadcrumbIconFontSize},ol:{display:`flex`,flexWrap:`wrap`,margin:0,padding:0,listStyle:`none`},a:Q({color:e.breadcrumbLinkColor,transition:`color ${e.motionDurationMid}`,padding:`0 ${e.paddingXXS}px`,borderRadius:e.borderRadiusSM,height:e.lineHeight*e.fontSize,display:`inline-block`,marginInline:-e.marginXXS,"&:hover":{color:e.breadcrumbLinkColorHover,backgroundColor:e.colorBgTextHover}},me(e)),"li:last-child":{color:e.breadcrumbLastItemColor,[`& > ${t}-separator`]:{display:`none`}},[`${t}-separator`]:{marginInline:e.breadcrumbSeparatorMargin,color:e.breadcrumbSeparatorColor},[`${t}-link`]:{[`
1
+ import{G as e,I as t,K as n,W as r,q as i}from"./rqZ-1SoP.js";import{A as a,B as o,C as s,F as c,G as l,H as u,Ht as d,M as f,O as p,Q as m,St as h,U as g,Ut as _,V as v,Wt as y,Y as b,a as x,b as S,bt as C,c as w,d as T,dt as E,et as D,f as O,ft as k,g as A,gt as j,h as M,lt as N,m as P,mt as F,nt as I,p as L,q as R,rt as z,t as B,x as V,y as H,z as U}from"./BSCpFtzG.js";import{d as W,p as G}from"./-6OnbLFb.js";import{n as K}from"./B5S_UyaC.js";import{n as q}from"./BeIfu4N3.js";import{t as J}from"./DpojD719.js";import{t as Y}from"./DXRZPxGs.js";import{$ as X,At as Z,Ct as ee,E as te,J as ne,O as re,Q as ie,X as ae,Z as oe,at as se,ct as ce,d as le,et as ue,h as de,it as fe,j as pe,kt as Q,m as me,n as he,pt as ge,t as _e,tt as ve,u as ye}from"./BDUjyaF4.js";import{$ as be,c as xe,i as Se}from"./DtBu71ev.js";import{t as Ce}from"./BfGc7TJp.js";import{G as we,V as Te,t as Ee}from"./VLI2Zy4t.js";import{n as De,r as Oe,t as ke}from"./0jKrzLuM.js";import{a as Ae,i as je,t as Me}from"./BN_PdN3J.js";import{f as Ne,p as Pe,r as $,s as Fe,x as Ie}from"./D-Ca4BGY.js";import{a as Le,i as Re,n as ze,r as Be,t as Ve}from"./Cn3J3NXR.js";import{i as He,n as Ue,r as We,t as Ge}from"./BCJFMBQ6.js";import{t as Ke}from"./CKfhtOt7.js";import{n as qe,r as Je,t as Ye}from"./CmHzfVc5.js";import{t as Xe}from"./DoAlYsiF.js";import{t as Ze}from"./Cb3SnTM8.js";import{t as Qe}from"./lO5tpDZ5.js";import{t as $e}from"./D1z7i2UP.js";import{t as et}from"./ORt9oDIy.js";import{t as tt}from"./DosOJEmZ2.js";import{n as nt,r as rt,t as it}from"./DvgKXPgu2.js";import{t as at}from"./Bp5luxkg2.js";import{t as ot}from"./C9f8QMp12.js";import{t as st}from"./DoLasgPj2.js";import{t as ct}from"./BcrN7QEl2.js";import{t as lt}from"./C4OAdbVK2.js";import{t as ut}from"./G0qIw7Gq2.js";import{a as dt,c as ft,d as pt,f as mt,i as ht,l as gt,m as _t,n as vt,o as yt,r as bt,s as xt,t as St,u as Ct}from"./arUY5dyq2.js";import{t as wt}from"./CucID8qg2.js";import{t as Tt}from"./CNs_Ozdc2.js";import{t as Et}from"./DeYsUzhr.js";import{t as Dt}from"./DNQF_TXX.js";import{n as Ot,t as kt}from"./CobSUzQv.js";function At(e){let{prefixCls:t,value:n,current:r,offset:i=0}=e,a;return i&&(a={position:`absolute`,top:`${i}00%`,left:0}),V(`p`,{style:a,class:ee(`${t}-only-unit`,{current:r})},[n])}function jt(e,t,n){let r=e,i=0;for(;(r+10)%10!==t;)r+=n,i+=n;return i}var Mt=s({compatConfig:{MODE:3},name:`SingleNumber`,props:{prefixCls:String,value:String,count:Number},setup(e){let t=O(()=>Number(e.value)),n=O(()=>Math.abs(e.count)),r=k({prevValue:t.value,prevCount:n.value}),i=()=>{r.prevValue=t.value,r.prevCount=n.value},a=F();return D(t,()=>{clearTimeout(a.value),a.value=setTimeout(()=>{i()},1e3)},{flush:`post`}),o(()=>{clearTimeout(a.value)}),()=>{let a,o={},s=t.value;if(r.prevValue===s||Number.isNaN(s)||Number.isNaN(r.prevValue))a=[At(Q(Q({},e),{current:!0}))],o={transition:`none`};else{a=[];let t=s+10,i=[];for(let e=s;e<=t;e+=1)i.push(e);let c=i.findIndex(e=>e%10===r.prevValue);a=i.map((t,n)=>{let r=t%10;return At(Q(Q({},e),{value:r,offset:n-c,current:n===c}))});let l=r.prevCount<n.value?1:-1;o={transform:`translateY(${-jt(r.prevValue,s,l)}00%)`}}return V(`span`,{class:`${e.prefixCls}-only`,style:o,onTransitionend:()=>i()},[a])}}}),Nt=function(e,t){var n={};for(var r in e)Object.prototype.hasOwnProperty.call(e,r)&&t.indexOf(r)<0&&(n[r]=e[r]);if(e!=null&&typeof Object.getOwnPropertySymbols==`function`)for(var i=0,r=Object.getOwnPropertySymbols(e);i<r.length;i++)t.indexOf(r[i])<0&&Object.prototype.propertyIsEnumerable.call(e,r[i])&&(n[r[i]]=e[r[i]]);return n},Pt={prefixCls:String,count:_e.any,component:String,title:_e.any,show:Boolean},Ft=s({compatConfig:{MODE:3},name:`ScrollNumber`,inheritAttrs:!1,props:Pt,setup(e,t){let{attrs:n,slots:r}=t,{prefixCls:i}=he(`scroll-number`,e);return()=>{let t=Q(Q({},e),n),{prefixCls:a,count:o,title:s,show:c,component:l=`sup`,class:u,style:d}=t,f=Nt(t,[`prefixCls`,`count`,`title`,`show`,`component`,`class`,`style`]),p=Q(Q({},f),{style:d,"data-show":e.show,class:ee(i.value,u),title:s}),m=o;if(o&&Number(o)%1==0){let e=String(o).split(``);m=e.map((t,n)=>V(Mt,{prefixCls:i.value,count:Number(o),value:t,key:e.length-n},null))}d&&d.borderColor&&(p.style=Q(Q({},d),{boxShadow:`0 0 0 1px ${d.borderColor} inset`}));let h=se(r.default?.call(r));return h&&h.length?Te(h,{class:ee(`${i.value}-custom-component`)},!1):V(l,p,{default:()=>[m]})}}}),It=new re(`antStatusProcessing`,{"0%":{transform:`scale(0.8)`,opacity:.5},"100%":{transform:`scale(2.4)`,opacity:0}}),Lt=new re(`antZoomBadgeIn`,{"0%":{transform:`scale(0) translate(50%, -50%)`,opacity:0},"100%":{transform:`scale(1) translate(50%, -50%)`}}),Rt=new re(`antZoomBadgeOut`,{"0%":{transform:`scale(1) translate(50%, -50%)`},"100%":{transform:`scale(0) translate(50%, -50%)`,opacity:0}}),zt=new re(`antNoWrapperZoomBadgeIn`,{"0%":{transform:`scale(0)`,opacity:0},"100%":{transform:`scale(1)`}}),Bt=new re(`antNoWrapperZoomBadgeOut`,{"0%":{transform:`scale(1)`},"100%":{transform:`scale(0)`,opacity:0}}),Vt=new re(`antBadgeLoadingCircle`,{"0%":{transformOrigin:`50%`},"100%":{transform:`translate(50%, -50%) rotate(360deg)`,transformOrigin:`50%`}}),Ht=e=>{let{componentCls:t,iconCls:n,antCls:r,badgeFontHeight:i,badgeShadowSize:a,badgeHeightSm:o,motionDurationSlow:s,badgeStatusSize:c,marginXS:l,badgeRibbonOffset:u}=e,d=`${r}-scroll-number`,f=`${r}-ribbon`,p=`${r}-ribbon-wrapper`,m=be(e,(e,n)=>{let{darkColor:r}=n;return{[`&${t} ${t}-color-${e}`]:{background:r,[`&:not(${t}-count)`]:{color:r}}}}),h=be(e,(e,t)=>{let{darkColor:n}=t;return{[`&${f}-color-${e}`]:{background:n,color:n}}});return{[t]:Q(Q(Q(Q({},de(e)),{position:`relative`,display:`inline-block`,width:`fit-content`,lineHeight:1,[`${t}-count`]:{zIndex:e.badgeZIndex,minWidth:e.badgeHeight,height:e.badgeHeight,color:e.badgeTextColor,fontWeight:e.badgeFontWeight,fontSize:e.badgeFontSize,lineHeight:`${e.badgeHeight}px`,whiteSpace:`nowrap`,textAlign:`center`,background:e.badgeColor,borderRadius:e.badgeHeight/2,boxShadow:`0 0 0 ${a}px ${e.badgeShadowColor}`,transition:`background ${e.motionDurationMid}`,a:{color:e.badgeTextColor},"a:hover":{color:e.badgeTextColor},"a:hover &":{background:e.badgeColorHover}},[`${t}-count-sm`]:{minWidth:o,height:o,fontSize:e.badgeFontSizeSm,lineHeight:`${o}px`,borderRadius:o/2},[`${t}-multiple-words`]:{padding:`0 ${e.paddingXS}px`},[`${t}-dot`]:{zIndex:e.badgeZIndex,width:e.badgeDotSize,minWidth:e.badgeDotSize,height:e.badgeDotSize,background:e.badgeColor,borderRadius:`100%`,boxShadow:`0 0 0 ${a}px ${e.badgeShadowColor}`},[`${t}-dot${d}`]:{transition:`background ${s}`},[`${t}-count, ${t}-dot, ${d}-custom-component`]:{position:`absolute`,top:0,insetInlineEnd:0,transform:`translate(50%, -50%)`,transformOrigin:`100% 0%`,[`&${n}-spin`]:{animationName:Vt,animationDuration:`1s`,animationIterationCount:`infinite`,animationTimingFunction:`linear`}},[`&${t}-status`]:{lineHeight:`inherit`,verticalAlign:`baseline`,[`${t}-status-dot`]:{position:`relative`,top:-1,display:`inline-block`,width:c,height:c,verticalAlign:`middle`,borderRadius:`50%`},[`${t}-status-success`]:{backgroundColor:e.colorSuccess},[`${t}-status-processing`]:{overflow:`visible`,color:e.colorPrimary,backgroundColor:e.colorPrimary,"&::after":{position:`absolute`,top:0,insetInlineStart:0,width:`100%`,height:`100%`,borderWidth:a,borderStyle:`solid`,borderColor:`inherit`,borderRadius:`50%`,animationName:It,animationDuration:e.badgeProcessingDuration,animationIterationCount:`infinite`,animationTimingFunction:`ease-in-out`,content:`""`}},[`${t}-status-default`]:{backgroundColor:e.colorTextPlaceholder},[`${t}-status-error`]:{backgroundColor:e.colorError},[`${t}-status-warning`]:{backgroundColor:e.colorWarning},[`${t}-status-text`]:{marginInlineStart:l,color:e.colorText,fontSize:e.fontSize}}}),m),{[`${t}-zoom-appear, ${t}-zoom-enter`]:{animationName:Lt,animationDuration:e.motionDurationSlow,animationTimingFunction:e.motionEaseOutBack,animationFillMode:`both`},[`${t}-zoom-leave`]:{animationName:Rt,animationDuration:e.motionDurationSlow,animationTimingFunction:e.motionEaseOutBack,animationFillMode:`both`},[`&${t}-not-a-wrapper`]:{[`${t}-zoom-appear, ${t}-zoom-enter`]:{animationName:zt,animationDuration:e.motionDurationSlow,animationTimingFunction:e.motionEaseOutBack},[`${t}-zoom-leave`]:{animationName:Bt,animationDuration:e.motionDurationSlow,animationTimingFunction:e.motionEaseOutBack},[`&:not(${t}-status)`]:{verticalAlign:`middle`},[`${d}-custom-component, ${t}-count`]:{transform:`none`},[`${d}-custom-component, ${d}`]:{position:`relative`,top:`auto`,display:`block`,transformOrigin:`50% 50%`}},[`${d}`]:{overflow:`hidden`,[`${d}-only`]:{position:`relative`,display:`inline-block`,height:e.badgeHeight,transition:`all ${e.motionDurationSlow} ${e.motionEaseOutBack}`,WebkitTransformStyle:`preserve-3d`,WebkitBackfaceVisibility:`hidden`,[`> p${d}-only-unit`]:{height:e.badgeHeight,margin:0,WebkitTransformStyle:`preserve-3d`,WebkitBackfaceVisibility:`hidden`}},[`${d}-symbol`]:{verticalAlign:`top`}},"&-rtl":{direction:`rtl`,[`${t}-count, ${t}-dot, ${d}-custom-component`]:{transform:`translate(-50%, -50%)`}}}),[`${p}`]:{position:`relative`},[`${f}`]:Q(Q(Q(Q({},de(e)),{position:`absolute`,top:l,padding:`0 ${e.paddingXS}px`,color:e.colorPrimary,lineHeight:`${i}px`,whiteSpace:`nowrap`,backgroundColor:e.colorPrimary,borderRadius:e.borderRadiusSM,[`${f}-text`]:{color:e.colorTextLightSolid},[`${f}-corner`]:{position:`absolute`,top:`100%`,width:u,height:u,color:`currentcolor`,border:`${u/2}px solid`,transform:e.badgeRibbonCornerTransform,transformOrigin:`top`,filter:e.badgeRibbonCornerFilter}}),h),{[`&${f}-placement-end`]:{insetInlineEnd:-u,borderEndEndRadius:0,[`${f}-corner`]:{insetInlineEnd:0,borderInlineEndColor:`transparent`,borderBlockEndColor:`transparent`}},[`&${f}-placement-start`]:{insetInlineStart:-u,borderEndStartRadius:0,[`${f}-corner`]:{insetInlineStart:0,borderBlockEndColor:`transparent`,borderInlineStartColor:`transparent`}},"&-rtl":{direction:`rtl`}})}},Ut=le(`Badge`,e=>{let{fontSize:t,lineHeight:n,fontSizeSM:r,lineWidth:i,marginXS:a,colorBorderBg:o}=e,s=Math.round(t*n),c=i,l=s-2*c,u=e.colorBgContainer,d=r,f=e.colorError,p=e.colorErrorHover,m=t,h=r/2,g=r,_=r/2;return[Ht(ye(e,{badgeFontHeight:s,badgeShadowSize:c,badgeZIndex:`auto`,badgeHeight:l,badgeTextColor:u,badgeFontWeight:`normal`,badgeFontSize:d,badgeColor:f,badgeColorHover:p,badgeShadowColor:o,badgeHeightSm:m,badgeDotSize:h,badgeFontSizeSm:g,badgeStatusSize:_,badgeProcessingDuration:`1.2s`,badgeRibbonOffset:a,badgeRibbonCornerTransform:`scaleY(0.75)`,badgeRibbonCornerFilter:`brightness(75%)`}))]}),Wt=function(e,t){var n={};for(var r in e)Object.prototype.hasOwnProperty.call(e,r)&&t.indexOf(r)<0&&(n[r]=e[r]);if(e!=null&&typeof Object.getOwnPropertySymbols==`function`)for(var i=0,r=Object.getOwnPropertySymbols(e);i<r.length;i++)t.indexOf(r[i])<0&&Object.prototype.propertyIsEnumerable.call(e,r[i])&&(n[r[i]]=e[r[i]]);return n},Gt=s({compatConfig:{MODE:3},name:`ABadgeRibbon`,inheritAttrs:!1,props:{prefix:String,color:{type:String},text:_e.any,placement:{type:String,default:`end`}},slots:Object,setup(e,t){let{attrs:n,slots:r}=t,{prefixCls:i,direction:a}=he(`ribbon`,e),[o,s]=Ut(i),c=O(()=>xe(e.color,!1)),l=O(()=>[i.value,`${i.value}-placement-${e.placement}`,{[`${i.value}-rtl`]:a.value===`rtl`,[`${i.value}-color-${e.color}`]:c.value}]);return()=>{let{class:t,style:a}=n,u=Wt(n,[`class`,`style`]),d={},f={};return e.color&&!c.value&&(d.background=e.color,f.color=e.color),o(V(`div`,Z({class:`${i.value}-wrapper ${s.value}`},u),[r.default?.call(r),V(`div`,{class:[l.value,t,s.value],style:Q(Q({},d),a)},[V(`span`,{class:`${i.value}-text`},[e.text||r.text?.call(r)]),V(`div`,{class:`${i.value}-corner`,style:f},null)])]))}}}),Kt=s({compatConfig:{MODE:3},name:`ABadge`,Ribbon:Gt,inheritAttrs:!1,props:{count:_e.any.def(null),showZero:{type:Boolean,default:void 0},overflowCount:{type:Number,default:99},dot:{type:Boolean,default:void 0},prefixCls:String,scrollNumberPrefixCls:String,status:{type:String},size:{type:String,default:`default`},color:String,text:_e.any,offset:Array,numberStyle:{type:Object,default:void 0},title:String},slots:Object,setup(n,r){let{slots:i,attrs:a}=r,{prefixCls:o,direction:s}=he(`badge`,n),[c,l]=Ut(o),u=O(()=>n.count>n.overflowCount?`${n.overflowCount}+`:n.count),d=O(()=>u.value===`0`||u.value===0),f=O(()=>n.count===null||d.value&&!n.showZero),p=O(()=>(n.status!==null&&n.status!==void 0||n.color!==null&&n.color!==void 0)&&f.value),m=O(()=>n.dot&&!d.value),h=O(()=>m.value?``:u.value),g=O(()=>(h.value===null||h.value===void 0||h.value===``||d.value&&!n.showZero)&&!m.value),_=F(n.count),v=F(h.value),y=F(m.value);D([()=>n.count,h,m],()=>{g.value||(_.value=n.count,v.value=h.value,y.value=m.value)},{immediate:!0});let b=O(()=>xe(n.color,!1)),x=O(()=>({[`${o.value}-status-dot`]:p.value,[`${o.value}-status-${n.status}`]:!!n.status,[`${o.value}-color-${n.color}`]:b.value})),S=O(()=>n.color&&!b.value?{background:n.color,color:n.color}:{}),C=O(()=>({[`${o.value}-dot`]:y.value,[`${o.value}-count`]:!y.value,[`${o.value}-count-sm`]:n.size===`small`,[`${o.value}-multiple-words`]:!y.value&&v.value&&v.value.toString().length>1,[`${o.value}-status-${n.status}`]:!!n.status,[`${o.value}-color-${n.color}`]:b.value}));return()=>{let{offset:r,title:u,color:d}=n,f=a.style,m=ge(i,n,`text`),h=o.value,y=_.value,w=ce(i.default?.call(i));w=w.length?w:null;let T=!!(!g.value||i.count),E=(()=>{if(!r)return Q({},f);let e={marginTop:Qe(r[1])?`${r[1]}px`:r[1]};return s.value===`rtl`?e.left=`${parseInt(r[0],10)}px`:e.right=`${-parseInt(r[0],10)}px`,Q(Q({},e),f)})(),D=u??(typeof y==`string`||typeof y==`number`?y:void 0),O=T||!m?null:V(`span`,{class:`${h}-status-text`},[m]),k=typeof y==`object`||y===void 0&&i.count?Te(y??i.count?.call(i),{style:E},!1):null,A=ee(h,{[`${h}-status`]:p.value,[`${h}-not-a-wrapper`]:!w,[`${h}-rtl`]:s.value===`rtl`},a.class,l.value);if(!w&&p.value){let e=E.color;return c(V(`span`,Z(Z({},a),{},{class:A,style:E}),[V(`span`,{class:x.value,style:S.value},null),V(`span`,{style:{color:e},class:`${h}-status-text`},[m])]))}let j=Ie(w?`${h}-zoom`:``,{appear:!1}),M=Q(Q({},E),n.numberStyle);return d&&!b.value&&(M||={},M.background=d),c(V(`span`,Z(Z({},a),{},{class:A}),[w,V(t,j,{default:()=>[z(V(Ft,{prefixCls:n.scrollNumberPrefixCls,show:T,class:C.value,count:v.value,title:D,style:M,key:`scrollNumber`},{default:()=>[k]}),[[e,T]])]}),O]))}}});Kt.install=function(e){return e.component(Kt.name,Kt),e.component(Gt.name,Gt),e};var qt=Kt,Jt=function(e,t){var n={};for(var r in e)Object.prototype.hasOwnProperty.call(e,r)&&t.indexOf(r)<0&&(n[r]=e[r]);if(e!=null&&typeof Object.getOwnPropertySymbols==`function`)for(var i=0,r=Object.getOwnPropertySymbols(e);i<r.length;i++)t.indexOf(r[i])<0&&Object.prototype.propertyIsEnumerable.call(e,r[i])&&(n[r[i]]=e[r[i]]);return n},Yt=s({compatConfig:{MODE:3},name:`ABreadcrumbItem`,inheritAttrs:!1,__ANT_BREADCRUMB_ITEM:!0,props:{prefixCls:String,href:String,separator:_e.any,dropdownProps:X(),overlay:_e.any,onClick:oe()},slots:Object,setup(e,t){let{slots:n,attrs:r,emit:i}=t,{prefixCls:a}=he(`breadcrumb`,e),o=(t,r)=>{let i=ge(n,e,`overlay`);return i?V($e,Z(Z({},e.dropdownProps),{},{overlay:i,placement:`bottom`}),{default:()=>[V(`span`,{class:`${r}-overlay-link`},[t,V(Ae,null,null)])]}):t},s=e=>{i(`click`,e)};return()=>{let t=ge(n,e,`separator`)??`/`,i=ge(n,e),{class:c,style:l}=r,u=Jt(r,[`class`,`style`]),d;return d=e.href===void 0?V(`span`,Z({class:`${a.value}-link`,onClick:s},u),[i]):V(`a`,Z({class:`${a.value}-link`,onClick:s},u),[i]),d=o(d,a.value),i==null?null:V(`li`,{class:c,style:l},[d,t&&V(`span`,{class:`${a.value}-separator`},[t])])}}}),Xt=e=>{let{componentCls:t,iconCls:n}=e;return{[t]:Q(Q({},de(e)),{color:e.breadcrumbBaseColor,fontSize:e.breadcrumbFontSize,[n]:{fontSize:e.breadcrumbIconFontSize},ol:{display:`flex`,flexWrap:`wrap`,margin:0,padding:0,listStyle:`none`},a:Q({color:e.breadcrumbLinkColor,transition:`color ${e.motionDurationMid}`,padding:`0 ${e.paddingXXS}px`,borderRadius:e.borderRadiusSM,height:e.lineHeight*e.fontSize,display:`inline-block`,marginInline:-e.marginXXS,"&:hover":{color:e.breadcrumbLinkColorHover,backgroundColor:e.colorBgTextHover}},me(e)),"li:last-child":{color:e.breadcrumbLastItemColor,[`& > ${t}-separator`]:{display:`none`}},[`${t}-separator`]:{marginInline:e.breadcrumbSeparatorMargin,color:e.breadcrumbSeparatorColor},[`${t}-link`]:{[`
2
2
  > ${n} + span,
3
3
  > ${n} + a
4
4
  `]:{marginInlineStart:e.marginXXS}},[`${t}-overlay-link`]:{borderRadius:e.borderRadiusSM,height:e.lineHeight*e.fontSize,display:`inline-block`,padding:`0 ${e.paddingXXS}px`,marginInline:-e.marginXXS,[`> ${n}`]:{marginInlineStart:e.marginXXS,fontSize:e.fontSizeIcon},"&:hover":{color:e.breadcrumbLinkColorHover,backgroundColor:e.colorBgTextHover,a:{color:e.breadcrumbLinkColorHover}},a:{"&:hover":{backgroundColor:`transparent`}}},[`&${e.componentCls}-rtl`]:{direction:`rtl`}})}},Zt=le(`Breadcrumb`,e=>[Xt(ye(e,{breadcrumbBaseColor:e.colorTextDescription,breadcrumbFontSize:e.fontSize,breadcrumbIconFontSize:e.fontSize,breadcrumbLinkColor:e.colorTextDescription,breadcrumbLinkColorHover:e.colorText,breadcrumbLastItemColor:e.colorText,breadcrumbSeparatorMargin:e.marginXS,breadcrumbSeparatorColor:e.colorTextDescription}))]),Qt=()=>({prefixCls:String,routes:{type:Array},params:_e.any,separator:_e.any,itemRender:{type:Function}});function $t(e,t){if(!e.breadcrumbName)return null;let n=Object.keys(t).join(`|`);return e.breadcrumbName.replace(RegExp(`:(${n})`,`g`),(e,n)=>t[n]||e)}function en(e){let{route:t,params:n,routes:r,paths:i}=e,a=r.indexOf(t)===r.length-1,o=$t(t,n);return a?V(`span`,null,[o]):V(`a`,{href:`#/${i.join(`/`)}`},[o])}var tn=s({compatConfig:{MODE:3},name:`ABreadcrumb`,inheritAttrs:!1,props:Qt(),slots:Object,setup(e,t){let{slots:n,attrs:r}=t,{prefixCls:i,direction:a}=he(`breadcrumb`,e),[o,s]=Zt(i),c=(e,t)=>(e=(e||``).replace(/^\//,``),Object.keys(t).forEach(n=>{e=e.replace(`:${n}`,t[n])}),e),l=(e,t,n)=>{let r=[...e],i=c(t||``,n);return i&&r.push(i),r},u=e=>{let{routes:t=[],params:n={},separator:r,itemRender:i=en}=e,a=[];return t.map(e=>{let o=c(e.path,n);o&&a.push(o);let s=[...a],u=null;e.children&&e.children.length&&(u=V(Ke,{items:e.children.map(e=>({key:e.path||e.breadcrumbName,label:i({route:e,params:n,routes:t,paths:l(s,e.path,n)})}))},null));let d={separator:r};return u&&(d.overlay=u),V(Yt,Z(Z({},d),{},{key:o||e.breadcrumbName}),{default:()=>[i({route:e,params:n,routes:t,paths:s})]})})};return()=>{let t,{routes:c,params:l={}}=e,d=ce(ge(n,e)),f=ge(n,e,`separator`)??`/`,p=e.itemRender||n.itemRender||en;c&&c.length>0?t=u({routes:c,params:l,separator:f,itemRender:p}):d.length&&(t=d.map((e,t)=>(pe(typeof e.type==`object`&&(e.type.__ANT_BREADCRUMB_ITEM||e.type.__ANT_BREADCRUMB_SEPARATOR),`Breadcrumb`,`Only accepts Breadcrumb.Item and Breadcrumb.Separator as it's children`),T(e,{separator:f,key:t}))));let m={[i.value]:!0,[`${i.value}-rtl`]:a.value===`rtl`,[`${r.class}`]:!!r.class,[s.value]:!0};return o(V(`nav`,Z(Z({},r),{},{class:m}),[V(`ol`,null,[t])]))}}}),nn=function(e,t){var n={};for(var r in e)Object.prototype.hasOwnProperty.call(e,r)&&t.indexOf(r)<0&&(n[r]=e[r]);if(e!=null&&typeof Object.getOwnPropertySymbols==`function`)for(var i=0,r=Object.getOwnPropertySymbols(e);i<r.length;i++)t.indexOf(r[i])<0&&Object.prototype.propertyIsEnumerable.call(e,r[i])&&(n[r[i]]=e[r[i]]);return n},rn=s({compatConfig:{MODE:3},name:`ABreadcrumbSeparator`,__ANT_BREADCRUMB_SEPARATOR:!0,inheritAttrs:!1,props:{prefixCls:String},setup(e,t){let{slots:n,attrs:r}=t,{prefixCls:i}=he(`breadcrumb`,e);return()=>{let{separator:e,class:t}=r,a=nn(r,[`separator`,`class`]),o=ce(n.default?.call(n));return V(`span`,Z({class:[`${i.value}-separator`,t]},a),[o.length>0?o:`/`])}}});tn.Item=Yt,tn.Separator=rn,tn.install=function(e){return e.component(tn.name,tn),e.component(Yt.name,Yt),e.component(rn.name,rn),e};var an=tn,on=[`normal`,`exception`,`active`,`success`],sn=()=>({prefixCls:String,type:ve(),percent:Number,format:ie(),status:ve(),showInfo:ae(),strokeWidth:Number,strokeLinecap:ve(),strokeColor:ne(),trailColor:String,width:Number,success:X(),gapDegree:Number,gapPosition:ve(),size:ue([String,Number,Array]),steps:Number,successPercent:Number,title:String,progressStatus:ve()});function cn(e){return!e||e<0?0:e>100?100:e}function ln(e){let{success:t,successPercent:n}=e,r=n;return t&&`progress`in t&&(we(!1,`Progress`,"`success.progress` is deprecated. Please use `success.percent` instead."),r=t.progress),t&&`percent`in t&&(r=t.percent),r}function un(e){let{percent:t,success:n,successPercent:r}=e,i=cn(ln({success:n,successPercent:r}));return[i,cn(cn(t)-i)]}function dn(e){let{success:t={},strokeColor:n}=e,{strokeColor:r}=t;return[r||te.green,n||null]}var fn=(e,t,n)=>{let r=-1,i=-1;if(t===`step`){let t=n.steps,a=n.strokeWidth;typeof e==`string`||e===void 0?(r=e===`small`?2:14,i=a??8):typeof e==`number`?[r,i]=[e,e]:[r=14,i=8]=e,r*=t}else if(t===`line`){let t=n?.strokeWidth;typeof e==`string`||e===void 0?i=t||(e===`small`?6:8):typeof e==`number`?[r,i]=[e,e]:[r=-1,i=8]=e}else(t===`circle`||t===`dashboard`)&&(typeof e==`string`||e===void 0?[r,i]=e===`small`?[60,60]:[120,120]:typeof e==`number`?[r,i]=[e,e]:(r=e[0]??e[1]??120,i=e[0]??e[1]??120));return{width:r,height:i}},pn=function(e,t){var n={};for(var r in e)Object.prototype.hasOwnProperty.call(e,r)&&t.indexOf(r)<0&&(n[r]=e[r]);if(e!=null&&typeof Object.getOwnPropertySymbols==`function`)for(var i=0,r=Object.getOwnPropertySymbols(e);i<r.length;i++)t.indexOf(r[i])<0&&Object.prototype.propertyIsEnumerable.call(e,r[i])&&(n[r[i]]=e[r[i]]);return n},mn=()=>Q(Q({},sn()),{strokeColor:ne(),direction:ve()}),hn=e=>{let t=[];return Object.keys(e).forEach(n=>{let r=parseFloat(n.replace(/%/g,``));isNaN(r)||t.push({key:r,value:e[n]})}),t=t.sort((e,t)=>e.key-t.key),t.map(e=>{let{key:t,value:n}=e;return`${n} ${t}%`}).join(`, `)},gn=(e,t)=>{let{from:n=te.blue,to:r=te.blue,direction:i=t===`rtl`?`to left`:`to right`}=e,a=pn(e,[`from`,`to`,`direction`]);return Object.keys(a).length===0?{backgroundImage:`linear-gradient(${i}, ${n}, ${r})`}:{backgroundImage:`linear-gradient(${i}, ${hn(a)})`}},_n=s({compatConfig:{MODE:3},name:`ProgressLine`,inheritAttrs:!1,props:mn(),setup(e,t){let{slots:n,attrs:r}=t,i=O(()=>{let{strokeColor:t,direction:n}=e;return t&&typeof t!=`string`?gn(t,n):{backgroundColor:t}}),a=O(()=>e.strokeLinecap===`square`||e.strokeLinecap===`butt`?0:void 0),o=O(()=>e.trailColor?{backgroundColor:e.trailColor}:void 0),s=O(()=>e.size??[-1,e.strokeWidth||(e.size===`small`?6:8)]),c=O(()=>fn(s.value,`line`,{strokeWidth:e.strokeWidth})),l=O(()=>{let{percent:t}=e;return Q({width:`${cn(t)}%`,height:`${c.value.height}px`,borderRadius:a.value},i.value)}),u=O(()=>ln(e)),d=O(()=>{let{success:t}=e;return{width:`${cn(u.value)}%`,height:`${c.value.height}px`,borderRadius:a.value,backgroundColor:t?.strokeColor}}),f={width:c.value.width<0?`100%`:c.value.width,height:`${c.value.height}px`};return()=>V(x,null,[V(`div`,Z(Z({},r),{},{class:[`${e.prefixCls}-outer`,r.class],style:[r.style,f]}),[V(`div`,{class:`${e.prefixCls}-inner`,style:o.value},[V(`div`,{class:`${e.prefixCls}-bg`,style:l.value},null),u.value===void 0?null:V(`div`,{class:`${e.prefixCls}-success-bg`,style:d.value},null)])]),n.default?.call(n)])}}),vn={percent:0,prefixCls:`vc-progress`,strokeColor:`#2db7f5`,strokeLinecap:`round`,strokeWidth:1,trailColor:`#D9D9D9`,trailWidth:1},yn=e=>{let t=F(null);return v(()=>{let n=Date.now(),r=!1;e.value.forEach(e=>{let i=e?.$el||e;if(!i)return;r=!0;let a=i.style;a.transitionDuration=`.3s, .3s, .3s, .06s`,t.value&&n-t.value<100&&(a.transitionDuration=`0s, 0s`)}),r&&(t.value=Date.now())}),e},bn={gapDegree:Number,gapPosition:{type:String},percent:{type:[Array,Number]},prefixCls:String,strokeColor:{type:[Object,String,Array]},strokeLinecap:{type:String},strokeWidth:Number,trailColor:String,trailWidth:Number,transition:String},xn=function(e,t){var n={};for(var r in e)Object.prototype.hasOwnProperty.call(e,r)&&t.indexOf(r)<0&&(n[r]=e[r]);if(e!=null&&typeof Object.getOwnPropertySymbols==`function`)for(var i=0,r=Object.getOwnPropertySymbols(e);i<r.length;i++)t.indexOf(r[i])<0&&Object.prototype.propertyIsEnumerable.call(e,r[i])&&(n[r[i]]=e[r[i]]);return n},Sn=0;function Cn(e){return+e.replace(`%`,``)}function wn(e){return Array.isArray(e)?e:[e]}function Tn(e,t,n,r){let i=arguments.length>4&&arguments[4]!==void 0?arguments[4]:0,a=arguments.length>5?arguments[5]:void 0,o=50-r/2,s=0,c=-o,l=0,u=-2*o;switch(a){case`left`:s=-o,c=0,l=2*o,u=0;break;case`right`:s=o,c=0,l=-2*o,u=0;break;case`bottom`:c=o,u=2*o}let d=`M 50,50 m ${s},${c}
@@ -1 +1 @@
1
- import{C as e,G as t,H as n,Ht as r,St as i,Wt as a,a as o,b as s,f as c,ft as l,g as u,h as d,lt as f,m as ee,mt as p,nt as m,p as h,t as g,x as _}from"./BSCpFtzG.js";import{d as te}from"./-6OnbLFb.js";import{n as v}from"./B5S_UyaC.js";import{n as y}from"./BeIfu4N3.js";import{t as ne}from"./VLI2Zy4t.js";import{n as re,t as b}from"./DNxVTfhe.js";import{n as ie,r as ae,t as oe}from"./eHYnGew0.js";import{t as se}from"./BN_PdN3J.js";import{r as x}from"./D-Ca4BGY.js";import{r as ce,t as le}from"./RzXYI9FM.js";import{i as ue,n as de,t as fe}from"./B-xskWta.js";import{t as pe}from"./BBwMH_hG.js";import{t as me}from"./DTYBfjRY.js";import{t as he}from"./ORt9oDIy2.js";import{t as ge}from"./DoLasgPj2.js";import{t as S}from"./BcrN7QEl2.js";import{t as C}from"./G0qIw7Gq2.js";import{t as w}from"./kZV5TQvh2.js";import{t as T}from"./CNs_Ozdc.js";var E={class:`page`},D={class:`head`},O={class:`sub`},k={class:`toolbar`},A={key:0,class:`admin-note`},j={class:`tpl-name`},M=[`title`],N={key:0,class:`h-miss`},P={class:`owner`},F={class:`inst-id`},I={class:`inst-ch`},L={key:0,class:`empty`},_e={class:`mono`},ve={key:1,class:`harness-caps`},R=g(e({__name:`agents`,setup(e){let{t:g}=y();T({layout:`default`});let R=w(),z=S(),B=p([]),V=p(!1),H=async()=>{V.value=!0;try{let e=await R.listTemplates();B.value=e?.data??[]}finally{V.value=!1}};H();let U=p(`all`),ye=c(()=>{let e=[{value:`all`,label:g(`chips.chipAll`,{n:B.value.length})},{value:`mine`,label:g(`chips.chipMine`,{n:B.value.filter(e=>e.ownerUserId===z.user?.id).length})},{value:`public`,label:g(`chips.chipPublic`,{n:B.value.filter(e=>e.visibility===`public`).length})},{value:`builtin`,label:g(`chips.chipBuiltin`,{n:B.value.filter(e=>e.isBuiltin).length})}];return z.isAdmin&&e.push({value:`others`,label:g(`chips.chipOthers`,{n:B.value.filter(e=>e.ownerUserId!==null&&e.ownerUserId!==z.user?.id&&e.visibility===`private`).length})}),e}),be=c(()=>{let e=z.user?.id;switch(U.value){case`mine`:return B.value.filter(t=>t.ownerUserId===e);case`public`:return B.value.filter(e=>e.visibility===`public`);case`builtin`:return B.value.filter(e=>e.isBuiltin);case`others`:return B.value.filter(t=>t.ownerUserId!==null&&t.ownerUserId!==e&&t.visibility===`private`);default:return B.value}}),W=e=>!e.isBuiltin&&(e.ownerUserId===z.user?.id||z.isAdmin),G=e=>e.isBuiltin?{text:g(`agents.k3x23c017`),color:`default`,icon:`i-tabler-lock`}:e.visibility===`public`?{text:g(`agents.k3wv1t018`),color:`green`}:{text:g(`agents.k447jj019`),color:`default`},K=p([]),q=c(()=>new Map(K.value.map(e=>[e.id,e]))),J=e=>q.value.get(e)?.available===!1,xe=c(()=>(K.value.length>0?K.value:[{id:`mock`,label:`mock(测试)`,description:``,capabilities:{steer:!0,supervise:!1,hitl:!1,terminal:!1,contextStats:!1,compact:!1}},{id:`omp`,label:`omp(真实 LLM)`,description:``,capabilities:{steer:!0,supervise:!0,hitl:!0,terminal:!0,contextStats:!0,compact:!0}},{id:`claude`,label:`claude`,description:``,capabilities:{steer:!1,supervise:!1,hitl:!1,terminal:!1,contextStats:!1,compact:!1}}]).map(e=>{let t=e.available===!1;return{value:e.id,label:t?`${e.label}(${g(`agents.notInstalled`)})`:e.label,disabled:t}})),Y=e=>{let t=K.value.find(t=>t.id===e)?.capabilities;if(!t)return[];let n=[];return t.steer&&n.push(`steer`),t.supervise&&n.push(`lead`),t.hitl&&n.push(`HITL`),t.compact&&n.push(`compact`),n};(async()=>{try{let e=(await R.listHarnesses())?.data?.harnesses;Array.isArray(e)&&e.length>0&&(K.value=e)}catch{}})();let X=p(!1),Z=p(null),Q=l({name:``,harness:`mock`,configJson:`{}`,visibility:`private`}),Se=()=>{Z.value=null,Q.name=``,Q.harness=`mock`,Q.configJson=`{}`,Q.visibility=`private`,X.value=!0},Ce=e=>{Z.value=e,Q.name=e.name,Q.harness=e.harness,Q.configJson=JSON.stringify(e.config??{},null,2),Q.visibility=e.visibility,X.value=!0},$=async()=>{let e={};try{e=JSON.parse(Q.configJson||`{}`)}catch{x.error(`config 不是合法 JSON`);return}if(J(Q.harness)){x.error(q.value.get(Q.harness)?.error??g(`agents.notInstalled`));return}try{Z.value?(await R.updateTemplate(Z.value.id,{name:Q.name,harness:Q.harness,config:e,visibility:Q.visibility}),x.success(g(`agents.k3n9aij020`))):(await R.createTemplate({name:Q.name,harness:Q.harness,config:e,visibility:Q.visibility}),x.success(g(`agents.k3n5hak021`))),X.value=!1,H()}catch(e){x.error(C(e))}},we=async e=>{await R.deleteTemplate(e.id),x.success(g(`agents.k3n5sd7022`)),H()},Te=async e=>{await R.updateTemplate(e.id,{enabled:e.enabled===1?0:1}),H()},Ee=async(e,t)=>{try{await R.updateTemplate(e.id,{visibility:t?`public`:`private`}),x.success(g(t?`agents.kxa6cxx023`:`agents.k1xxabaf024`)),H()}catch(e){x.error(C(e))}};return v({title:()=>g(`titles.agents`)}),(e,c)=>{let l=ne,p=he,v=oe,y=re,x=fe,S=ge,C=me,w=b,T=le,R=ae,B=se,H=de,De=ue,Oe=ce,ke=ie,Ae=pe;return n(),u(`div`,E,[h(`div`,D,[h(`div`,null,[h(`h2`,null,`Agent `+a(e.$t(`agents.k3pa5h4025`)),1),h(`p`,O,a(e.$t(`agents.k5nsz7y008`)),1)]),_(p,null,{default:m(()=>[_(l,{onClick:c[0]||=t=>(`navigateTo`in e?e.navigateTo:i(te))(`/workshop`)},{default:m(()=>[s(a(e.$t(`agents.krpx6qa009`)),1)]),_:1}),_(l,{type:`primary`,onClick:Se},{default:m(()=>[s(a(e.$t(`agents.k1efixrj010`)),1)]),_:1})]),_:1})]),h(`div`,k,[_(v,{value:i(U),"onUpdate:value":c[1]||=e=>f(U)?U.value=e:null,size:`small`,options:i(ye)},null,8,[`value`,`options`]),i(z).isAdmin?(n(),u(`span`,A,[c[7]||=h(`span`,{class:`i-tabler-shield-check`},null,-1),s(` `+a(e.$t(`agents.ka1gpdj011`)),1)])):d(``,!0)]),_(w,{"data-source":i(be),loading:i(V),"row-key":`id`,size:`small`,pagination:!1},{expandedRowRender:m(({record:r})=>[(n(!0),u(o,null,t(r.instances,e=>(n(),u(`div`,{key:e.id,class:`inst`},[_(x,{color:e.role===`lead`?`gold`:`blue`},{default:m(()=>[s(a(e.role),1)]),_:2},1032,[`color`]),h(`span`,F,a(e.id.slice(0,8)),1),h(`span`,I,`channel `+a(e.channelId.slice(0,8)),1)]))),128)),r.instances.length===0?(n(),u(`div`,L,a(e.$t(`agents.k1d036zs014`)),1)):d(``,!0)]),default:m(()=>[_(y,{title:e.$t(`agents.k3xhia001`),"data-index":`name`},{default:m(({record:e})=>[h(`span`,j,[c[8]||=h(`span`,{class:`i-tabler-user-square`},null,-1),s(` `+a(e.name),1)])]),_:1},8,[`title`]),_(y,{title:`harness`,"data-index":`harness`,width:120},{default:m(({record:e})=>[h(`span`,{class:r([`h-cell`,{off:J(e.harness)}]),title:J(e.harness)?i(q).get(e.harness)?.error??``:i(q).get(e.harness)?.resolvedPath??``},[c[9]||=h(`span`,{class:`h-dot`},null,-1),s(a(e.harness),1),J(e.harness)?(n(),u(`span`,N,`(`+a(i(g)(`agents.notInstalled`))+`)`,1)):d(``,!0)],10,M)]),_:1}),_(y,{title:e.$t(`agents.k3lrqn0002`),width:120},{default:m(({record:e})=>[_(x,{color:G(e).color,class:`vis-tag`},{default:m(()=>[G(e).icon?(n(),u(`span`,{key:0,class:r(G(e).icon)},null,2)):d(``,!0),s(a(G(e).text),1)]),_:2},1032,[`color`]),!e.isBuiltin&&W(e)?(n(),ee(S,{key:0,checked:e.visibility===`public`,size:`small`,"checked-children":`公开`,"un-checked-children":`私有`,title:e.visibility===`public`?`点击转为私有`:`点击公开(全员可读可用)`,onChange:t=>Ee(e,t===!0)},null,8,[`checked`,`title`,`onChange`])):d(``,!0)]),_:1},8,[`title`]),_(y,{title:e.$t(`agents.k3l98u7003`),width:130},{default:m(({record:e})=>[h(`span`,P,a(e.ownerName??e.ownerUserId?.slice(0,8)??`-`),1)]),_:1},8,[`title`]),_(y,{title:e.$t(`agents.k3mr526004`),width:70},{default:m(({record:e})=>[s(a(e.instances.length),1)]),_:1},8,[`title`]),_(y,{title:e.$t(`agents.k3xhfg005`),width:70},{default:m(({record:e})=>[_(S,{checked:e.enabled===1,size:`small`,disabled:!W(e),onChange:t=>Te(e)},null,8,[`checked`,`disabled`,`onChange`])]),_:1},8,[`title`]),_(y,{title:e.$t(`agents.k40aa6006`),width:130},{default:m(({record:t})=>[_(p,{size:`small`},{default:m(()=>[_(l,{size:`small`,type:`text`,disabled:!W(t),title:t.isBuiltin?`内置模板不可修改`:W(t)?`编辑`:`仅属主可修改`,onClick:e=>Ce(t)},{default:m(()=>[s(a(e.$t(`agents.k45eb0012`)),1)]),_:1},8,[`disabled`,`title`,`onClick`]),_(C,{title:e.$t(`agents.keetzvf007`),disabled:!W(t),onConfirm:e=>we(t)},{default:m(()=>[_(l,{size:`small`,type:`text`,danger:``,disabled:!W(t),title:t.isBuiltin?`内置模板不可删除`:`删除`},{default:m(()=>[s(a(e.$t(`agents.k3xakp013`)),1)]),_:1},8,[`disabled`,`title`])]),_:2},1032,[`title`,`disabled`,`onConfirm`])]),_:2},1024)]),_:1},8,[`title`])]),_:1},8,[`data-source`,`loading`]),_(Ae,{open:i(X),"onUpdate:open":c[6]||=e=>f(X)?X.value=e:null,title:i(Z)?`编辑模板`:`新建模板`,"ok-text":`保存`,"cancel-text":`取消`,onOk:$},{default:m(()=>[_(ke,{layout:`vertical`},{default:m(()=>[_(R,{label:e.$t(`agents.k3xhia001`)},{default:m(()=>[_(T,{value:i(Q).name,"onUpdate:value":c[2]||=e=>i(Q).name=e},null,8,[`value`])]),_:1},8,[`label`]),_(R,{label:`harness`},{default:m(()=>[_(B,{value:i(Q).harness,"onUpdate:value":c[3]||=e=>i(Q).harness=e,options:i(xe)},null,8,[`value`,`options`]),i(K).length>0?(n(),u(`div`,{key:0,class:r([`harness-status`,{off:J(i(Q).harness)}])},[J(i(Q).harness)?(n(),u(o,{key:0},[c[10]||=h(`span`,{class:`i-tabler-plug-off`},null,-1),s(` `+a(i(q).get(i(Q).harness)?.error),1)],64)):i(q).get(i(Q).harness)?.inprocess?(n(),u(o,{key:1},[c[11]||=h(`span`,{class:`i-tabler-plug-connected`},null,-1),s(` `+a(i(g)(`agents.harnessInprocess`)),1)],64)):i(q).get(i(Q).harness)?.resolvedPath?(n(),u(o,{key:2},[c[12]||=h(`span`,{class:`i-tabler-plug-connected`},null,-1),c[13]||=s(),h(`span`,_e,a(i(q).get(i(Q).harness)?.resolvedPath),1)],64)):d(``,!0)],2)):d(``,!0),Y(i(Q).harness).length?(n(),u(`div`,ve,[(n(!0),u(o,null,t(Y(i(Q).harness),e=>(n(),u(`span`,{key:e,class:`harness-cap`},a(e),1))),128))])):d(``,!0)]),_:1}),_(R,{label:e.$t(`agents.k3lrqn0002`)},{default:m(()=>[_(De,{value:i(Q).visibility,"onUpdate:value":c[4]||=e=>i(Q).visibility=e},{default:m(()=>[_(H,{value:`private`},{default:m(()=>[s(a(e.$t(`agents.k17jfge3015`)),1)]),_:1}),_(H,{value:`public`},{default:m(()=>[s(a(e.$t(`agents.k1tt5zyo016`)),1)]),_:1})]),_:1},8,[`value`])]),_:1},8,[`label`]),_(R,{label:`config(JSON;mock 可配 delayMs)`},{default:m(()=>[_(Oe,{value:i(Q).configJson,"onUpdate:value":c[5]||=e=>i(Q).configJson=e,rows:6},null,8,[`value`])]),_:1})]),_:1})]),_:1},8,[`open`,`title`])])}}}),[[`__scopeId`,`data-v-d7a5c98d`]]);export{R as default};
1
+ import{C as e,G as t,H as n,Ht as r,St as i,Wt as a,a as o,b as s,f as c,ft as l,g as u,h as d,lt as f,m as ee,mt as p,nt as m,p as h,t as g,x as _}from"./BSCpFtzG.js";import{d as te}from"./-6OnbLFb.js";import{n as v}from"./B5S_UyaC.js";import{n as y}from"./BeIfu4N3.js";import{t as ne}from"./VLI2Zy4t.js";import{n as re,t as b}from"./BGhOrgle.js";import{n as ie,r as ae,t as oe}from"./0jKrzLuM.js";import{t as se}from"./BN_PdN3J.js";import{r as x}from"./D-Ca4BGY.js";import{r as ce,t as le}from"./Cn3J3NXR.js";import{i as ue,n as de,t as fe}from"./BCJFMBQ6.js";import{t as pe}from"./DoAlYsiF.js";import{t as me}from"./Cb3SnTM8.js";import{t as he}from"./ORt9oDIy.js";import{t as ge}from"./DoLasgPj2.js";import{t as S}from"./BcrN7QEl2.js";import{t as C}from"./G0qIw7Gq2.js";import{t as w}from"./CucID8qg2.js";import{t as T}from"./CNs_Ozdc2.js";var E={class:`page`},D={class:`head`},O={class:`sub`},k={class:`toolbar`},A={key:0,class:`admin-note`},j={class:`tpl-name`},M=[`title`],N={key:0,class:`h-miss`},P={class:`owner`},F={class:`inst-id`},I={class:`inst-ch`},L={key:0,class:`empty`},_e={class:`mono`},ve={key:1,class:`harness-caps`},R=g(e({__name:`agents`,setup(e){let{t:g}=y();T({layout:`default`});let R=w(),z=S(),B=p([]),V=p(!1),H=async()=>{V.value=!0;try{let e=await R.listTemplates();B.value=e?.data??[]}finally{V.value=!1}};H();let U=p(`all`),ye=c(()=>{let e=[{value:`all`,label:g(`chips.chipAll`,{n:B.value.length})},{value:`mine`,label:g(`chips.chipMine`,{n:B.value.filter(e=>e.ownerUserId===z.user?.id).length})},{value:`public`,label:g(`chips.chipPublic`,{n:B.value.filter(e=>e.visibility===`public`).length})},{value:`builtin`,label:g(`chips.chipBuiltin`,{n:B.value.filter(e=>e.isBuiltin).length})}];return z.isAdmin&&e.push({value:`others`,label:g(`chips.chipOthers`,{n:B.value.filter(e=>e.ownerUserId!==null&&e.ownerUserId!==z.user?.id&&e.visibility===`private`).length})}),e}),be=c(()=>{let e=z.user?.id;switch(U.value){case`mine`:return B.value.filter(t=>t.ownerUserId===e);case`public`:return B.value.filter(e=>e.visibility===`public`);case`builtin`:return B.value.filter(e=>e.isBuiltin);case`others`:return B.value.filter(t=>t.ownerUserId!==null&&t.ownerUserId!==e&&t.visibility===`private`);default:return B.value}}),W=e=>!e.isBuiltin&&(e.ownerUserId===z.user?.id||z.isAdmin),G=e=>e.isBuiltin?{text:g(`agents.k3x23c017`),color:`default`,icon:`i-tabler-lock`}:e.visibility===`public`?{text:g(`agents.k3wv1t018`),color:`green`}:{text:g(`agents.k447jj019`),color:`default`},K=p([]),q=c(()=>new Map(K.value.map(e=>[e.id,e]))),J=e=>q.value.get(e)?.available===!1,xe=c(()=>(K.value.length>0?K.value:[{id:`mock`,label:`mock(测试)`,description:``,capabilities:{steer:!0,supervise:!1,hitl:!1,terminal:!1,contextStats:!1,compact:!1}},{id:`omp`,label:`omp(真实 LLM)`,description:``,capabilities:{steer:!0,supervise:!0,hitl:!0,terminal:!0,contextStats:!0,compact:!0}},{id:`claude`,label:`claude`,description:``,capabilities:{steer:!1,supervise:!1,hitl:!1,terminal:!1,contextStats:!1,compact:!1}}]).map(e=>{let t=e.available===!1;return{value:e.id,label:t?`${e.label}(${g(`agents.notInstalled`)})`:e.label,disabled:t}})),Y=e=>{let t=K.value.find(t=>t.id===e)?.capabilities;if(!t)return[];let n=[];return t.steer&&n.push(`steer`),t.supervise&&n.push(`lead`),t.hitl&&n.push(`HITL`),t.compact&&n.push(`compact`),n};(async()=>{try{let e=(await R.listHarnesses())?.data?.harnesses;Array.isArray(e)&&e.length>0&&(K.value=e)}catch{}})();let X=p(!1),Z=p(null),Q=l({name:``,harness:`mock`,configJson:`{}`,visibility:`private`}),Se=()=>{Z.value=null,Q.name=``,Q.harness=`mock`,Q.configJson=`{}`,Q.visibility=`private`,X.value=!0},Ce=e=>{Z.value=e,Q.name=e.name,Q.harness=e.harness,Q.configJson=JSON.stringify(e.config??{},null,2),Q.visibility=e.visibility,X.value=!0},$=async()=>{let e={};try{e=JSON.parse(Q.configJson||`{}`)}catch{x.error(`config 不是合法 JSON`);return}if(J(Q.harness)){x.error(q.value.get(Q.harness)?.error??g(`agents.notInstalled`));return}try{Z.value?(await R.updateTemplate(Z.value.id,{name:Q.name,harness:Q.harness,config:e,visibility:Q.visibility}),x.success(g(`agents.k3n9aij020`))):(await R.createTemplate({name:Q.name,harness:Q.harness,config:e,visibility:Q.visibility}),x.success(g(`agents.k3n5hak021`))),X.value=!1,H()}catch(e){x.error(C(e))}},we=async e=>{await R.deleteTemplate(e.id),x.success(g(`agents.k3n5sd7022`)),H()},Te=async e=>{await R.updateTemplate(e.id,{enabled:e.enabled===1?0:1}),H()},Ee=async(e,t)=>{try{await R.updateTemplate(e.id,{visibility:t?`public`:`private`}),x.success(g(t?`agents.kxa6cxx023`:`agents.k1xxabaf024`)),H()}catch(e){x.error(C(e))}};return v({title:()=>g(`titles.agents`)}),(e,c)=>{let l=ne,p=he,v=oe,y=re,x=fe,S=ge,C=me,w=b,T=le,R=ae,B=se,H=de,De=ue,Oe=ce,ke=ie,Ae=pe;return n(),u(`div`,E,[h(`div`,D,[h(`div`,null,[h(`h2`,null,`Agent `+a(e.$t(`agents.k3pa5h4025`)),1),h(`p`,O,a(e.$t(`agents.k5nsz7y008`)),1)]),_(p,null,{default:m(()=>[_(l,{onClick:c[0]||=t=>(`navigateTo`in e?e.navigateTo:i(te))(`/workshop`)},{default:m(()=>[s(a(e.$t(`agents.krpx6qa009`)),1)]),_:1}),_(l,{type:`primary`,onClick:Se},{default:m(()=>[s(a(e.$t(`agents.k1efixrj010`)),1)]),_:1})]),_:1})]),h(`div`,k,[_(v,{value:i(U),"onUpdate:value":c[1]||=e=>f(U)?U.value=e:null,size:`small`,options:i(ye)},null,8,[`value`,`options`]),i(z).isAdmin?(n(),u(`span`,A,[c[7]||=h(`span`,{class:`i-tabler-shield-check`},null,-1),s(` `+a(e.$t(`agents.ka1gpdj011`)),1)])):d(``,!0)]),_(w,{"data-source":i(be),loading:i(V),"row-key":`id`,size:`small`,pagination:!1},{expandedRowRender:m(({record:r})=>[(n(!0),u(o,null,t(r.instances,e=>(n(),u(`div`,{key:e.id,class:`inst`},[_(x,{color:e.role===`lead`?`gold`:`blue`},{default:m(()=>[s(a(e.role),1)]),_:2},1032,[`color`]),h(`span`,F,a(e.id.slice(0,8)),1),h(`span`,I,`channel `+a(e.channelId.slice(0,8)),1)]))),128)),r.instances.length===0?(n(),u(`div`,L,a(e.$t(`agents.k1d036zs014`)),1)):d(``,!0)]),default:m(()=>[_(y,{title:e.$t(`agents.k3xhia001`),"data-index":`name`},{default:m(({record:e})=>[h(`span`,j,[c[8]||=h(`span`,{class:`i-tabler-user-square`},null,-1),s(` `+a(e.name),1)])]),_:1},8,[`title`]),_(y,{title:`harness`,"data-index":`harness`,width:120},{default:m(({record:e})=>[h(`span`,{class:r([`h-cell`,{off:J(e.harness)}]),title:J(e.harness)?i(q).get(e.harness)?.error??``:i(q).get(e.harness)?.resolvedPath??``},[c[9]||=h(`span`,{class:`h-dot`},null,-1),s(a(e.harness),1),J(e.harness)?(n(),u(`span`,N,`(`+a(i(g)(`agents.notInstalled`))+`)`,1)):d(``,!0)],10,M)]),_:1}),_(y,{title:e.$t(`agents.k3lrqn0002`),width:120},{default:m(({record:e})=>[_(x,{color:G(e).color,class:`vis-tag`},{default:m(()=>[G(e).icon?(n(),u(`span`,{key:0,class:r(G(e).icon)},null,2)):d(``,!0),s(a(G(e).text),1)]),_:2},1032,[`color`]),!e.isBuiltin&&W(e)?(n(),ee(S,{key:0,checked:e.visibility===`public`,size:`small`,"checked-children":`公开`,"un-checked-children":`私有`,title:e.visibility===`public`?`点击转为私有`:`点击公开(全员可读可用)`,onChange:t=>Ee(e,t===!0)},null,8,[`checked`,`title`,`onChange`])):d(``,!0)]),_:1},8,[`title`]),_(y,{title:e.$t(`agents.k3l98u7003`),width:130},{default:m(({record:e})=>[h(`span`,P,a(e.ownerName??e.ownerUserId?.slice(0,8)??`-`),1)]),_:1},8,[`title`]),_(y,{title:e.$t(`agents.k3mr526004`),width:70},{default:m(({record:e})=>[s(a(e.instances.length),1)]),_:1},8,[`title`]),_(y,{title:e.$t(`agents.k3xhfg005`),width:70},{default:m(({record:e})=>[_(S,{checked:e.enabled===1,size:`small`,disabled:!W(e),onChange:t=>Te(e)},null,8,[`checked`,`disabled`,`onChange`])]),_:1},8,[`title`]),_(y,{title:e.$t(`agents.k40aa6006`),width:130},{default:m(({record:t})=>[_(p,{size:`small`},{default:m(()=>[_(l,{size:`small`,type:`text`,disabled:!W(t),title:t.isBuiltin?`内置模板不可修改`:W(t)?`编辑`:`仅属主可修改`,onClick:e=>Ce(t)},{default:m(()=>[s(a(e.$t(`agents.k45eb0012`)),1)]),_:1},8,[`disabled`,`title`,`onClick`]),_(C,{title:e.$t(`agents.keetzvf007`),disabled:!W(t),onConfirm:e=>we(t)},{default:m(()=>[_(l,{size:`small`,type:`text`,danger:``,disabled:!W(t),title:t.isBuiltin?`内置模板不可删除`:`删除`},{default:m(()=>[s(a(e.$t(`agents.k3xakp013`)),1)]),_:1},8,[`disabled`,`title`])]),_:2},1032,[`title`,`disabled`,`onConfirm`])]),_:2},1024)]),_:1},8,[`title`])]),_:1},8,[`data-source`,`loading`]),_(Ae,{open:i(X),"onUpdate:open":c[6]||=e=>f(X)?X.value=e:null,title:i(Z)?`编辑模板`:`新建模板`,"ok-text":`保存`,"cancel-text":`取消`,onOk:$},{default:m(()=>[_(ke,{layout:`vertical`},{default:m(()=>[_(R,{label:e.$t(`agents.k3xhia001`)},{default:m(()=>[_(T,{value:i(Q).name,"onUpdate:value":c[2]||=e=>i(Q).name=e},null,8,[`value`])]),_:1},8,[`label`]),_(R,{label:`harness`},{default:m(()=>[_(B,{value:i(Q).harness,"onUpdate:value":c[3]||=e=>i(Q).harness=e,options:i(xe)},null,8,[`value`,`options`]),i(K).length>0?(n(),u(`div`,{key:0,class:r([`harness-status`,{off:J(i(Q).harness)}])},[J(i(Q).harness)?(n(),u(o,{key:0},[c[10]||=h(`span`,{class:`i-tabler-plug-off`},null,-1),s(` `+a(i(q).get(i(Q).harness)?.error),1)],64)):i(q).get(i(Q).harness)?.inprocess?(n(),u(o,{key:1},[c[11]||=h(`span`,{class:`i-tabler-plug-connected`},null,-1),s(` `+a(i(g)(`agents.harnessInprocess`)),1)],64)):i(q).get(i(Q).harness)?.resolvedPath?(n(),u(o,{key:2},[c[12]||=h(`span`,{class:`i-tabler-plug-connected`},null,-1),c[13]||=s(),h(`span`,_e,a(i(q).get(i(Q).harness)?.resolvedPath),1)],64)):d(``,!0)],2)):d(``,!0),Y(i(Q).harness).length?(n(),u(`div`,ve,[(n(!0),u(o,null,t(Y(i(Q).harness),e=>(n(),u(`span`,{key:e,class:`harness-cap`},a(e),1))),128))])):d(``,!0)]),_:1}),_(R,{label:e.$t(`agents.k3lrqn0002`)},{default:m(()=>[_(De,{value:i(Q).visibility,"onUpdate:value":c[4]||=e=>i(Q).visibility=e},{default:m(()=>[_(H,{value:`private`},{default:m(()=>[s(a(e.$t(`agents.k17jfge3015`)),1)]),_:1}),_(H,{value:`public`},{default:m(()=>[s(a(e.$t(`agents.k1tt5zyo016`)),1)]),_:1})]),_:1},8,[`value`])]),_:1},8,[`label`]),_(R,{label:`config(JSON;mock 可配 delayMs)`},{default:m(()=>[_(Oe,{value:i(Q).configJson,"onUpdate:value":c[5]||=e=>i(Q).configJson=e,rows:6},null,8,[`value`])]),_:1})]),_:1})]),_:1},8,[`open`,`title`])])}}}),[[`__scopeId`,`data-v-d7a5c98d`]]);export{R as default};
@@ -0,0 +1 @@
1
+ import{G as e,w as t}from"./rqZ-1SoP.js";import{C as n,G as r,H as i,Ht as a,St as o,Ut as ee,Wt as s,a as c,b as l,et as u,f as d,g as f,h as p,m,mt as h,nt as g,p as _,rt as v,t as y,x as b}from"./BSCpFtzG.js";import{n as x,t as S}from"./Cz9gD2Yo.js";import{n as C}from"./BeIfu4N3.js";import{t as te}from"./BN_PdN3J.js";import{r as w}from"./D-Ca4BGY.js";import{t as ne}from"./Cn3J3NXR.js";import{t as re}from"./niDwBOZW.js";import{t as ie}from"./6PZPfFcO.js";import{n as ae,r as oe,t as se}from"./DvgKXPgu2.js";import{t as ce}from"./C9f8QMp12.js";import{t as le}from"./DoLasgPj2.js";import{t as T}from"./BcrN7QEl2.js";import{t as E}from"./BytVi9VX2.js";import{t as D}from"./G0qIw7Gq2.js";import{t as ue}from"./CucID8qg2.js";var de={class:`settings-page`},fe={class:`aw-page-head`},pe={class:`aw-kicker`},me={class:`aw-stamp`},he={class:`settings-layout`},ge={class:`settings-nav`},_e=[`onClick`],ve={class:`settings-body`},ye={class:`section-title`},be={class:`section-desc`},xe={class:`set-row`},Se={class:`set-text`},Ce={class:`set-title`},we={class:`set-sub`},O={class:`color-swatches`},k=[`title`,`onClick`],Te={class:`swatch-label`},Ee={key:0,class:`i-tabler-check swatch-check`},De={class:`toggle-row`},Oe={class:`set-text`},ke={class:`set-title`},Ae={class:`set-sub`},je=[`aria-checked`],Me={class:`toggle-row`},Ne={class:`set-text`},Pe={class:`set-title`},Fe={class:`set-sub`},Ie={class:`section-title`},Le={class:`section-desc`},Re={class:`rt-group-title`},ze={class:`rt-main`},Be={class:`rt-title`},Ve={class:`rt-sub`},He={class:`rt-ctrl`},Ue={key:3,class:`rt-color`},We=[`value`,`onInput`],Ge=[`title`,`onClick`],Ke={class:`rt-actions`},qe=[`disabled`],Je={class:`rt-path aw-mono`},Ye={class:`rt-group-title plugin-group-title`},Xe={class:`section-desc`},Ze={key:1,class:`identity-note`},Qe={class:`plugin-main`},$e={class:`rt-title`},et={class:`aw-mono`},tt={key:0,class:`rt-tag`},nt={key:1,class:`rt-tag src-runtime`},rt={key:2,class:`rt-tag restart`},it={class:`rt-sub`},at={class:`rt-ctrl`},ot={key:0,class:`plugin-health faint`},st=[`onClick`],ct=[`aria-checked`,`disabled`,`onClick`],lt={key:0,class:`identity-note`},ut={class:`section-title`},dt={class:`section-desc`},ft={class:`aw-mono`},pt={class:`identity-note`},A=y(n({__name:`settings`,setup(n){let{t:y,locale:A,locales:mt,setLocale:ht}=C(),j=x(),M=S(),N=t().public,P=T(),F=ue(),I=h(`appearance`),L=E(),R=h({}),z=h(new Set),B=h(!1),V=h(null);function H(){R.value={...L.effective},z.value=new Set}u(()=>L.loaded,e=>{e&&H()}),u(()=>L.effective,()=>{z.value.size===0&&H()},{deep:!0});function U(e){z.value.add(e),V.value=null}async function gt(){if(z.value.size){B.value=!0,V.value=null;try{let e={};for(let t of z.value)e[t]=R.value[t];let t=await L.patch(e);H();let n=t.restartRequired??[];V.value=n.length?{type:`warning`,text:y(`settings.runtime.restartNotice`,{keys:n.join(`, `)})}:{type:`success`,text:y(`settings.runtime.savedLive`)}}catch(e){V.value={type:`error`,text:e?.response?.data?.message||e?.message||String(e)}}finally{B.value=!1}}}async function _t(e){try{await L.patch({[e]:null}),z.value.delete(e),R.value[e]=L.effective[e],V.value={type:`success`,text:y(`settings.runtime.keyReset`,{key:e})}}catch(e){V.value={type:`error`,text:e?.response?.data?.message||e?.message||String(e)}}}async function vt(){try{await L.resetAll(),H(),V.value={type:`success`,text:y(`settings.runtime.resetAllDone`)}}catch(e){V.value={type:`error`,text:e?.response?.data?.message||e?.message||String(e)}}}function yt(e){return{server:y(`settings.runtime.groupServer`),app:y(`settings.runtime.groupApp`),api:y(`settings.runtime.groupApi`),theme:y(`settings.runtime.groupTheme`),i18n:y(`settings.runtime.groupI18n`),security:y(`settings.runtime.groupSecurity`),daq:y(`settings.runtime.groupDaq`),memory:y(`settings.runtime.groupMemory`),omp:y(`settings.runtime.groupOmp`),harness:y(`settings.runtime.groupHarness`),dcw:y(`settings.runtime.groupDcw`),workshop:y(`settings.runtime.groupWorkshop`),backup:y(`settings.runtime.groupBackup`),retention:y(`settings.runtime.groupRetention`),log:y(`settings.runtime.groupLog`),plugins:y(`settings.runtime.groupPlugins`)}[e]??e}function bt(e){return e===`runtime`?`src-runtime`:e===`env`?`src-env`:`src-yaml`}function xt(e){let t=e.labelKey;return t&&y(t)!==t?y(t):e.label}let W=h([]),G=h(!1),K=h(!1),q=h(new Set),J=h({}),Y=e=>(e.routes??[]).some(e=>String(e.path||``).endsWith(`/health`));async function St(){G.value=!0;try{let e=await F.listPlugins(),t=e?.plugins??e?.data?.plugins??[];W.value=Array.isArray(t)?t:[],K.value=!0}catch(e){w.error(D(e,y(`plugins.loadFail`)))}finally{G.value=!1}}async function X(e,t){if(!q.value.has(e.name)){q.value.add(e.name);try{t?await F.enablePlugin(e.name):await F.disablePlugin(e.name),e.enabled=t,w.success(y(t?`plugins.enabled`:`plugins.disabled`))}catch(e){w.error(D(e,y(`plugins.adminRequired`)))}finally{q.value.delete(e.name)}}}async function Ct(e){if(Y(e)){J.value={...J.value,[e.name]:`checking`};try{let t=await F.pluginHealth(e.name);J.value={...J.value,[e.name]:wt(e.name,t)}}catch(t){J.value={...J.value,[e.name]:{ok:!1,reason:D(t,y(`plugins.loadFail`))}}}}}function wt(e,t){if(e===`rag-bridge`){let e=t.backend,n=t.web,r=!!e?.ok&&!!n?.ok,i=e?.ok?n?.error||n?.status||`web`:e?.error||e?.status||`backend`;return r?{ok:!0}:{ok:!1,reason:i}}if(e===`diag-bridge`){let e=t.remote;return e?.status===`ok`?{ok:!0}:{ok:!1,reason:e?.status||`remote`}}return{ok:!0}}function Tt(e){return J.value[e]===`checking`}function Z(e){let t=J.value[e];return t&&t!==`checking`?t:null}function Et(e){return q.value.has(e)}u(I,e=>{e===`runtime`&&!K.value&&!G.value&&P.isLoggedIn&&St()},{immediate:!0});let Q=String(N.primaryColor),Dt=[{value:Q,label:y(`settings.accentInk`)},{value:`#c9963f`,label:y(`settings.accentStone`)},{value:`#44615a`,label:y(`settings.accentMoss`)},{value:`#3f6094`,label:y(`settings.accentSlate`)},{value:`#6b5aa0`,label:y(`settings.accentPlum`)},{value:`#9c5744`,label:y(`settings.accentClay`)}],$=d(()=>j.accent??Q);function Ot(e){j.setAccent(e===Q?null:e),w.success(y(`settings.accentApplied`))}function kt(){j.setAccent(null),w.success(y(`settings.accentReset`))}let At=d(()=>mt.value.map(e=>({label:e.name,value:e.code}))),jt=e=>{e!=null&&(localStorage.setItem(`aw.locale`,String(e)),ht(String(e)),window.location.reload())},Mt=d(()=>[{label:y(`home.fields.name`),value:M.name},{label:y(`home.fields.version`),value:`v${M.version}`},{label:y(`home.fields.mode`),value:M.mode},{label:y(`home.fields.apiBase`),value:`${M.apiBase} (${N.apiTimeout}ms)`},{label:y(`home.fields.primary`),value:Q},{label:`i18n`,value:A.value}]),Nt=d(()=>[{key:`appearance`,icon:`i-tabler-palette`,label:y(`settings.theme`)},{key:`runtime`,icon:`i-tabler-settings`,label:y(`settings.runtimeTab`)},{key:`system`,icon:`i-tabler-server-2`,label:y(`settings.systemTab`)}]);return(t,n)=>{let u=te,d=re,h=se,x=le,S=ne,C=ce,w=oe,T=ae,E=ie;return i(),f(`div`,de,[_(`div`,fe,[_(`div`,null,[_(`p`,pe,s(o(y)(`menu.system`))+` / settings `,1),_(`h1`,null,s(o(y)(`settings.title`)),1)]),_(`span`,me,`v`+s(o(M).version),1)]),b(E,{bordered:!1,class:`settings-card`},{default:g(()=>[_(`div`,he,[_(`div`,ge,[(i(!0),f(c,null,r(o(Nt),e=>(i(),f(`button`,{key:e.key,class:a([`nav-item`,{active:o(I)===e.key}]),onClick:t=>I.value=e.key},[_(`span`,{class:a(e.icon)},null,2),_(`span`,null,s(e.label),1)],10,_e))),128))]),_(`div`,ve,[v(_(`div`,null,[_(`h3`,ye,s(o(y)(`settings.theme`)),1),_(`p`,be,s(o(y)(`settings.appearanceDesc`)),1),_(`div`,xe,[_(`div`,Se,[_(`div`,Ce,s(o(y)(`settings.primaryColor`)),1),_(`div`,we,s(o(y)(`settings.accentDesc`)),1)])]),_(`div`,O,[(i(),f(c,null,r(Dt,e=>_(`button`,{key:e.value,class:a([`swatch`,{on:o($).toLowerCase()===e.value.toLowerCase()}]),style:ee({"--sw":e.value}),title:e.label,onClick:t=>Ot(e.value)},[n[1]||=_(`span`,{class:`swatch-dot`},null,-1),_(`span`,Te,s(e.label),1),o($).toLowerCase()===e.value.toLowerCase()?(i(),f(`span`,Ee)):p(``,!0)],14,k)),64))]),_(`button`,{class:`aw-pill outline reset-btn`,onClick:kt},[n[2]||=_(`span`,{class:`i-tabler-rotate`},null,-1),l(` `+s(o(y)(`settings.accentResetAction`)),1)]),_(`div`,De,[_(`div`,Oe,[_(`div`,ke,s(o(j).isDark?o(y)(`common.dark`):o(y)(`common.light`)),1),_(`div`,Ae,s(o(y)(`settings.darkDesc`)),1)]),_(`button`,{class:a([`switch`,{on:o(j).isDark}]),role:`switch`,"aria-checked":o(j).isDark,onClick:n[0]||=e=>o(j).toggleDark()},[...n[3]||=[_(`span`,{class:`knob`},null,-1)]],10,je)]),_(`div`,Me,[_(`div`,Ne,[_(`div`,Pe,s(o(y)(`header.language`)),1),_(`div`,Fe,s(o(y)(`settings.languageDesc`)),1)]),b(u,{value:o(A),options:o(At),style:{width:`140px`},onChange:jt},null,8,[`value`,`options`])])],512),[[e,o(I)===`appearance`]]),v(_(`div`,null,[_(`h3`,Ie,s(o(y)(`settings.runtimeTab`)),1),_(`p`,Le,s(o(y)(`settings.runtime.desc`)),1),o(V)?(i(),m(d,{key:0,type:o(V).type,"show-icon":``,class:`rt-notice`,message:o(V).text},null,8,[`type`,`message`])):p(``,!0),(i(!0),f(c,null,r(o(L).groups,e=>(i(),f(c,{key:e.group},[_(`h4`,Re,s(yt(e.group)),1),(i(!0),f(c,null,r(e.items,e=>(i(),f(`div`,{key:e.key,class:`rt-row`},[_(`div`,ze,[_(`div`,Be,[l(s(xt(e))+` `,1),_(`span`,{class:a([`rt-tag`,bt(o(L).sourceOf(e.key))])},s(o(L).sourceOf(e.key)),3),_(`span`,{class:a([`rt-tag`,e.applies])},s(e.applies===`live`?o(y)(`settings.runtime.live`):o(y)(`settings.runtime.restart`)),3)]),_(`div`,Ve,s(e.description),1)]),_(`div`,He,[e.type===`number`?(i(),m(h,{key:0,value:o(R)[e.key],"onUpdate:value":t=>o(R)[e.key]=t,min:e.min,max:e.max,onChange:t=>U(e.key)},null,8,[`value`,`onUpdate:value`,`min`,`max`,`onChange`])):e.type===`boolean`?(i(),m(x,{key:1,checked:o(R)[e.key],"onUpdate:checked":t=>o(R)[e.key]=t,onChange:t=>U(e.key)},null,8,[`checked`,`onUpdate:checked`,`onChange`])):e.type===`select`?(i(),m(u,{key:2,value:o(R)[e.key],"onUpdate:value":t=>o(R)[e.key]=t,style:{width:`160px`},options:(e.options??[]).map(e=>({label:e,value:e})),onChange:t=>U(e.key)},null,8,[`value`,`onUpdate:value`,`options`,`onChange`])):e.type===`color`?(i(),f(`span`,Ue,[_(`input`,{type:`color`,value:String(o(R)[e.key]??`#35e0a0`),onInput:t=>{o(R)[e.key]=t.target.value,U(e.key)}},null,40,We),b(S,{value:String(o(R)[e.key]??``),style:{width:`110px`},class:`aw-mono`,onChange:t=>{o(R)[e.key]=t.target.value,U(e.key)}},null,8,[`value`,`onChange`])])):(i(),m(S,{key:4,value:o(R)[e.key],"onUpdate:value":t=>o(R)[e.key]=t,style:{width:`220px`},onChange:t=>U(e.key)},null,8,[`value`,`onUpdate:value`,`onChange`])),_(`button`,{class:`aw-pill outline rt-reset`,title:o(y)(`settings.runtime.resetKey`),onClick:t=>_t(e.key)},[...n[4]||=[_(`span`,{class:`i-tabler-rotate`},null,-1)]],8,Ge)])]))),128))],64))),128)),_(`div`,Ke,[_(`button`,{class:`aw-pill primary`,disabled:!o(z).size||o(B),onClick:gt},[n[5]||=_(`span`,{class:`i-tabler-device-floppy`},null,-1),l(` `+s(o(B)?`…`:o(y)(`settings.runtime.save`)),1)],8,qe),_(`button`,{class:`aw-pill outline`,onClick:vt},s(o(y)(`settings.runtime.resetAll`)),1),_(`span`,Je,s(o(L).settingsPath),1)]),_(`h4`,Ye,s(o(y)(`plugins.title`)),1),_(`p`,Xe,s(o(y)(`plugins.desc`)),1),o(P).isLoggedIn?(i(),m(C,{key:2,spinning:o(G)},{default:g(()=>[(i(!0),f(c,null,r(o(W),e=>(i(),f(`div`,{key:e.name,class:a([`plugin-row`,{off:e.enabled===!1}])},[_(`div`,Qe,[_(`div`,$e,[_(`span`,et,s(e.name),1),e.version?(i(),f(`span`,tt,`v`+s(e.version),1)):p(``,!0),e.builtin?(i(),f(`span`,nt,s(o(y)(`plugins.builtin`)),1)):p(``,!0),e.error?(i(),f(`span`,rt,s(e.error),1)):p(``,!0)]),_(`div`,it,s(e.description||`—`),1)]),_(`div`,at,[Tt(e.name)?(i(),f(`span`,ot,[n[6]||=_(`span`,{class:`i-tabler-loader-2 spin`},null,-1),l(` `+s(o(y)(`plugins.healthChecking`)),1)])):Z(e.name)?(i(),f(`span`,{key:1,class:a([`plugin-health`,Z(e.name).ok?`ok`:`bad`])},[_(`span`,{class:a(Z(e.name).ok?`i-tabler-circle-check`:`i-tabler-alert-circle`)},null,2),l(` `+s(Z(e.name).ok?o(y)(`plugins.healthOk`):`${o(y)(`plugins.healthBad`)}: ${Z(e.name).reason??``}`),1)],2)):p(``,!0),Y(e)?(i(),f(`button`,{key:2,class:`aw-pill outline rt-reset`,onClick:t=>Ct(e)},[n[7]||=_(`span`,{class:`i-tabler-heartbeat`},null,-1),l(` `+s(o(y)(`plugins.healthCheck`)),1)],8,st)):p(``,!0),_(`button`,{class:a([`switch`,{on:e.enabled!==!1}]),role:`switch`,"aria-checked":e.enabled!==!1,disabled:Et(e.name),onClick:t=>X(e,e.enabled===!1)},[...n[8]||=[_(`span`,{class:`knob`},null,-1)]],10,ct)])],2))),128)),o(W).length===0&&!o(G)?(i(),f(`div`,lt,s(o(y)(`plugins.empty`)),1)):p(``,!0)]),_:1},8,[`spinning`])):(i(),f(`div`,Ze,s(o(y)(`plugins.needLogin`)),1))],512),[[e,o(I)===`runtime`]]),v(_(`div`,null,[_(`h3`,ut,s(o(y)(`settings.systemTab`)),1),_(`p`,dt,s(o(y)(`settings.systemDesc`)),1),b(T,{bordered:``,column:1,size:`small`},{default:g(()=>[(i(!0),f(c,null,r(o(Mt),e=>(i(),m(w,{key:e.label,label:e.label},{default:g(()=>[_(`span`,ft,s(e.value),1)]),_:2},1032,[`label`]))),128))]),_:1}),_(`p`,pt,s(o(P).isLoggedIn?`${o(y)(`settings.identity`)}: ${o(P).user?.name} (${o(P).user?.role})`:o(y)(`settings.identityGuest`)),1)],512),[[e,o(I)===`system`]])])])]),_:1})])}}}),[[`__scopeId`,`data-v-82462534`]]);export{A as default};
@@ -0,0 +1 @@
1
+ import{C as e,K as t,U as n,W as r,q as ee}from"./rqZ-1SoP.js";import{C as i,G as a,H as o,Ht as s,St as c,Wt as l,a as u,b as d,c as te,f,ft as p,g as m,h,m as ne,mt as g,p as _,rt as v,t as y,z as re}from"./BSCpFtzG.js";import{r as b}from"./D-Ca4BGY.js";import{t as ie}from"./G0qIw7Gq2.js";import{t as ae}from"./arUY5dyq2.js";import{t as oe}from"./BgCrZKv_2.js";import{t as se}from"./B8kt898d.js";var ce={class:`page`},le={class:`aw-page-head`},ue={class:`sub`},de={class:`head-actions`},fe=[`title`],pe={class:`live-txt mono`},x={class:`filter-card`},S={class:`flt`},C={value:``},w=[`value`],T={class:`flt`},E={value:``},D=[`value`],O={class:`flt`},k={value:``},A=[`value`],j={class:`flt`},M={value:``},N={value:`user`},P={value:`system`},F={class:`flt`},I={value:``},L=[`value`],R={class:`flt flt-grow`},z=[`placeholder`],B=[`disabled`],me={class:`table-card`},he={key:0,class:`err`},ge={class:`log-table`},_e={class:`th-time`},ve={class:`th-src`},ye={class:`th-kind`},be={class:`th-scope`},xe={class:`th-detail`},Se={class:`mono dim`},Ce={class:`actor`},we={class:`summary`},Te={class:`mono dim action`},Ee={class:`scope`},De=[`title`],Oe=[`title`],ke={key:2,class:`scope-chip`,title:`Recipe`},Ae={key:3,class:`dim`},je={class:`detail-cell`},Me=[`onClick`],V={key:1,class:`dim`},Ne={key:0},Pe={colspan:`7`,class:`detail-td`},Fe={class:`detail-box mono`},Ie={key:0,colspan:`7`,class:`empty`},Le={class:`modal`},Re={class:`m-title`},ze={class:`m-f`},Be=[`placeholder`],Ve={class:`m-f`},He=[`placeholder`],Ue={class:`m-grid`},We={class:`m-f`},Ge={value:``},Ke=[`value`],qe={class:`m-f`},Je={value:``},Ye=[`value`],Xe={class:`m-f`},Ze={value:``},Qe=[`value`],$e={key:0,class:`err`},et={class:`m-actions`},tt=[`disabled`],H=y(i({name:`OpsLogsPage`,setup(i){let y=t=>e().$i18n.t(t),H=oe(),nt=ae(),U=se(),rt=[`write`,`manual`,`alarm`,`line`,`recipe`,`rollback`,`daq`,`system`],W=p({lineId:``,productId:``,recipeId:``,actorKind:``,kind:``,text:``}),G=g(null),K=g(!1),q=p({summary:``,detail:``,lineId:``,productId:``,recipeId:``}),it=f(()=>!!(W.lineId||W.productId||W.recipeId||W.actorKind||W.kind||W.text.trim())),J=f(()=>H.products.filter(e=>!W.lineId||e.lineId===W.lineId)),Y=f(()=>H.recipes.filter(e=>(!W.lineId||e.lineId===W.lineId)&&(!W.productId||e.productId===W.productId)));function X(){U.fetchLogs({lineId:W.lineId,productId:W.productId,recipeId:W.recipeId,actorKind:W.actorKind,kind:W.kind,q:W.text.trim(),limit:300}),G.value=null}function at(){W.lineId=``,W.productId=``,W.recipeId=``,W.actorKind=``,W.kind=``,W.text=``,X()}function ot(){q.summary=``,q.detail=``,q.lineId=W.lineId,q.productId=W.productId,q.recipeId=W.recipeId,K.value=!0}async function st(){try{let e=q.detail.trim();await U.postManual({summary:q.summary.trim(),lineId:q.lineId,productId:q.productId,recipeId:q.recipeId,...e?{detail:{note:e}}:{}}),b.success(y(`logs.mOk`)),K.value=!1,X()}catch(e){b.error(ie(e))}}function ct(e){return!!e.detailJson&&e.detailJson!==`{}`}function lt(e){G.value=G.value===e.id?null:e.id}function ut(e){try{return JSON.stringify(JSON.parse(e),null,2)}catch{return e}}function dt(e){let t=new Date(e);if(!Number.isFinite(t.getTime()))return e;let n=e=>String(e).padStart(2,`0`);return`${n(t.getMonth()+1)}-${n(t.getDate())} ${n(t.getHours())}:${n(t.getMinutes())}:${n(t.getSeconds())}`}function ft(e){return e===`agent`?`Agent`:y(e===`user`?`logs.src.user`:`logs.src.system`)}function pt(e){return e?y(`logs.kind.${e}`):`—`}function Z(e){return H.lines.find(t=>t.id===e)?.name??``}function Q(e){return H.products.find(t=>t.id===e)?.name??``}function $(e){return H.recipes.find(t=>t.id===e)?.name??``}return re(()=>{nt.ensureConnected(),U.ensureLive(),H.load(),X()}),(e,i)=>(o(),m(`div`,ce,[_(`header`,le,[_(`div`,null,[i[17]||=_(`p`,{class:`aw-kicker`},` agentworkshop / audit log `,-1),_(`h1`,null,l(e.$t(`logs.title`)),1),_(`p`,ue,l(e.$t(`logs.sub`)),1)]),_(`div`,de,[_(`span`,{class:`live-dot`,title:e.$t(`logs.liveHint`)},null,8,fe),_(`span`,pe,l(e.$t(`logs.live`))+` `+l(c(U).recent.length),1),_(`button`,{class:`pill-btn`,onClick:ot},[i[18]||=_(`span`,{class:`i-tabler-plus`},null,-1),d(` `+l(e.$t(`logs.manual`)),1)])])]),_(`section`,x,[_(`label`,S,[_(`span`,null,l(e.$t(`logs.fLine`)),1),v(_(`select`,{"onUpdate:modelValue":i[0]||=e=>W.lineId=e,class:`inp-sel`,onChange:i[1]||=e=>{W.productId=``,W.recipeId=``}},[_(`option`,C,l(e.$t(`logs.all`)),1),(o(!0),m(u,null,a(c(H).lines,e=>(o(),m(`option`,{key:e.id,value:e.id},l(e.name),9,w))),128))],544),[[n,W.lineId]])]),_(`label`,T,[_(`span`,null,l(e.$t(`logs.fProduct`)),1),v(_(`select`,{"onUpdate:modelValue":i[2]||=e=>W.productId=e,class:`inp-sel`,onChange:i[3]||=e=>W.recipeId=``},[_(`option`,E,l(e.$t(`logs.all`)),1),(o(!0),m(u,null,a(J.value,e=>(o(),m(`option`,{key:e.id,value:e.id},l(e.name),9,D))),128))],544),[[n,W.productId]])]),_(`label`,O,[i[19]||=_(`span`,null,`Recipe`,-1),v(_(`select`,{"onUpdate:modelValue":i[4]||=e=>W.recipeId=e,class:`inp-sel`},[_(`option`,k,l(e.$t(`logs.all`)),1),(o(!0),m(u,null,a(Y.value,e=>(o(),m(`option`,{key:e.id,value:e.id},l(e.name),9,A))),128))],512),[[n,W.recipeId]])]),_(`label`,j,[_(`span`,null,l(e.$t(`logs.fSource`)),1),v(_(`select`,{"onUpdate:modelValue":i[5]||=e=>W.actorKind=e,class:`inp-sel`},[_(`option`,M,l(e.$t(`logs.all`)),1),_(`option`,N,l(e.$t(`logs.src.user`)),1),i[20]||=_(`option`,{value:`agent`},` Agent `,-1),_(`option`,P,l(e.$t(`logs.src.system`)),1)],512),[[n,W.actorKind]])]),_(`label`,F,[_(`span`,null,l(e.$t(`logs.fKind`)),1),v(_(`select`,{"onUpdate:modelValue":i[6]||=e=>W.kind=e,class:`inp-sel`},[_(`option`,I,l(e.$t(`logs.all`)),1),(o(),m(u,null,a(rt,t=>_(`option`,{key:t,value:t},l(e.$t(`logs.kind.${t}`)),9,L)),64))],512),[[n,W.kind]])]),_(`label`,R,[_(`span`,null,l(e.$t(`logs.fKeyword`)),1),v(_(`input`,{"onUpdate:modelValue":i[7]||=e=>W.text=e,class:`inp-sel`,type:`search`,placeholder:e.$t(`logs.fKeywordPh`),onKeydown:t(X,[`enter`])},null,40,z),[[r,W.text]])]),_(`button`,{class:`pill-btn`,disabled:c(U).loading.list,onClick:X},[i[21]||=_(`span`,{class:`i-tabler-search`},null,-1),d(` `+l(e.$t(`logs.query`)),1)],8,B),it.value?(o(),m(`button`,{key:0,class:`mini-btn`,onClick:at},l(e.$t(`logs.reset`)),1)):h(``,!0)]),_(`section`,me,[c(U).error.list?(o(),m(`p`,he,l(c(U).error.list),1)):h(``,!0),_(`table`,ge,[_(`thead`,null,[_(`tr`,null,[_(`th`,_e,l(e.$t(`logs.thTime`)),1),_(`th`,ve,l(e.$t(`logs.fSource`)),1),_(`th`,null,l(e.$t(`logs.thActor`)),1),_(`th`,ye,l(e.$t(`logs.fKind`)),1),_(`th`,null,l(e.$t(`logs.thSummary`)),1),_(`th`,be,l(e.$t(`logs.thScope`)),1),_(`th`,xe,l(e.$t(`logs.thDetail`)),1)])]),_(`tbody`,null,[(o(!0),m(u,null,a(c(U).results,t=>(o(),m(u,{key:t.id},[_(`tr`,null,[_(`td`,Se,l(dt(t.at)),1),_(`td`,null,[_(`span`,{class:s([`src-badge`,t.actorKind])},l(ft(t.actorKind)),3)]),_(`td`,Ce,l(t.actorName||t.actor||`—`),1),_(`td`,null,[_(`span`,{class:s([`kind-chip`,t.kind])},l(pt(t.kind)),3)]),_(`td`,we,[d(l(t.summary)+` `,1),_(`small`,Te,l(t.action),1)]),_(`td`,Ee,[Z(t.lineId)?(o(),m(`span`,{key:0,class:`scope-chip`,title:e.$t(`logs.fLine`)},l(Z(t.lineId)),9,De)):h(``,!0),Q(t.productId)?(o(),m(`span`,{key:1,class:`scope-chip`,title:e.$t(`logs.fProduct`)},l(Q(t.productId)),9,Oe)):h(``,!0),$(t.recipeId)?(o(),m(`span`,ke,l($(t.recipeId)),1)):h(``,!0),!t.lineId&&!t.productId&&!t.recipeId?(o(),m(`span`,Ae,`—`)):h(``,!0)]),_(`td`,je,[ct(t)?(o(),m(`button`,{key:0,class:`mini-btn`,onClick:e=>lt(t)},l(G.value===t.id?e.$t(`logs.fold`):e.$t(`logs.expand`)),9,Me)):(o(),m(`span`,V,l(e.$t(`logs.noDetail`)),1))])]),G.value===t.id?(o(),m(`tr`,Ne,[_(`td`,Pe,[_(`pre`,Fe,l(ut(t.detailJson)),1)])])):h(``,!0)],64))),128)),_(`tr`,null,[c(U).results.length===0?(o(),m(`td`,Ie,[c(U).loading.list?(o(),m(u,{key:0},[d(l(e.$t(`logs.loading`)),1)],64)):(o(),m(u,{key:1},[d(l(e.$t(`logs.empty`)),1)],64))])):h(``,!0)])])])]),(o(),ne(te,{to:`body`},[K.value?(o(),m(`div`,{key:0,class:`modal-mask`,onClick:i[16]||=ee(e=>K.value=!1,[`self`])},[_(`div`,Le,[_(`h3`,Re,l(e.$t(`logs.manual`)),1),_(`label`,ze,[_(`span`,null,l(e.$t(`logs.mSummary`))+` *`,1),v(_(`textarea`,{"onUpdate:modelValue":i[8]||=e=>q.summary=e,rows:`3`,placeholder:e.$t(`logs.mSummaryPh`)},null,8,Be),[[r,q.summary]])]),_(`label`,Ve,[_(`span`,null,l(e.$t(`logs.mDetail`)),1),v(_(`textarea`,{"onUpdate:modelValue":i[9]||=e=>q.detail=e,rows:`2`,placeholder:e.$t(`logs.mDetailPh`)},null,8,He),[[r,q.detail]])]),_(`div`,Ue,[_(`label`,We,[_(`span`,null,l(e.$t(`logs.fLine`)),1),v(_(`select`,{"onUpdate:modelValue":i[10]||=e=>q.lineId=e,class:`inp-sel`,onChange:i[11]||=e=>{q.productId=``,q.recipeId=``}},[_(`option`,Ge,l(e.$t(`logs.all`)),1),(o(!0),m(u,null,a(c(H).lines,e=>(o(),m(`option`,{key:e.id,value:e.id},l(e.name),9,Ke))),128))],544),[[n,q.lineId]])]),_(`label`,qe,[_(`span`,null,l(e.$t(`logs.fProduct`)),1),v(_(`select`,{"onUpdate:modelValue":i[12]||=e=>q.productId=e,class:`inp-sel`,onChange:i[13]||=e=>q.recipeId=``},[_(`option`,Je,l(e.$t(`logs.all`)),1),(o(!0),m(u,null,a(J.value,e=>(o(),m(`option`,{key:e.id,value:e.id},l(e.name),9,Ye))),128))],544),[[n,q.productId]])]),_(`label`,Xe,[i[22]||=_(`span`,null,`Recipe`,-1),v(_(`select`,{"onUpdate:modelValue":i[14]||=e=>q.recipeId=e,class:`inp-sel`},[_(`option`,Ze,l(e.$t(`logs.all`)),1),(o(!0),m(u,null,a(Y.value,e=>(o(),m(`option`,{key:e.id,value:e.id},l(e.name),9,Qe))),128))],512),[[n,q.recipeId]])])]),c(U).error.post?(o(),m(`p`,$e,l(c(U).error.post),1)):h(``,!0),_(`div`,et,[_(`button`,{class:`ghost-btn`,onClick:i[15]||=e=>K.value=!1},l(e.$t(`common.cancel`)),1),_(`button`,{class:`pill-btn`,disabled:c(U).loading.posting||!q.summary.trim(),onClick:st},l(e.$t(`logs.mSubmit`)),9,tt)])])])):h(``,!0)]))]))}}),[[`__scopeId`,`data-v-0b613117`]]);export{H as default};
@@ -1 +1 @@
1
- import{ft as e}from"./BSCpFtzG.js";import{t}from"./G0qIw7Gq2.js";import{t as n}from"./36oeS8_R2.js";var r=class extends Error{code;status;constructor(e,t,n){super(n),this.name=`ApiError`,this.code=e,this.status=t}};function i(e=!0){let t=typeof document<`u`?document.cookie.match(/(?:^|;\s*)token=([^;]+)/)?.[1]??``:``,n={};return t&&(n.authorization=`Bearer ${decodeURIComponent(t)}`),e&&(n[`content-type`]=`application/json`),n}var a=e=>new Promise(t=>setTimeout(t,e));function o(e){let t=(e?.method??`GET`).toUpperCase();return t===`GET`||t===`HEAD`}async function s(e,t,n){let a;try{a=await fetch(e+t,{...n,headers:{...i(!!n?.body),...n?.headers},signal:n?.signal??AbortSignal.timeout(n?.method&&n.method.toUpperCase()!==`GET`?3e4:15e3)})}catch(e){throw e instanceof Error&&(e.name===`TimeoutError`||e.name===`AbortError`)?new r(`TIMEOUT`,0,`请求超时,请检查网络或服务状态`):new r(`NETWORK`,0,`无法连接服务器,请检查网络或服务状态`)}let o=null;try{o=await a.json()}catch{}if(!a.ok)throw new r(o?.code??`HTTP_${a.status}`,a.status,o?.message||`请求失败(HTTP ${a.status})`);if(o?.code!==0)throw new r(o?.code??`REQUEST_ERROR`,a.status,o?.message||`请求失败`);return o.data}async function c(e){let{base:n,path:i=``,init:c,retries:l=0}=e,u=o(c),d=u?l+1:1,f;for(let e=0;e<d;e++)try{return await s(n,i,c)}catch(n){let i=n instanceof r?n:new r(`INTERNAL_ERROR`,0,t(n)),o=u&&(i.code===`NETWORK`||i.status>=500);if(f=i,!o||e===d-1)throw i;await a(400*(e+1))}throw f??new r(`INTERNAL_ERROR`,0,`请求失败`)}var l=[{key:`temp-sp`,name:`温度设定器`,code:`TEMP · SP`,ch:`烘箱温度设定`,unit:`℃`,min:150,max:200,decimals:1,icon:`thermo`,semantics:`烘箱/熔体温度设定:升高使热塑温度上升(成膜更均匀但能耗高、过热降解风险),降低则偏冷易厚度不均。调整后需等待热惯性(数十秒级)再评估效果。`},{key:`speed-sp`,name:`速度设定器`,code:`LINE · SP`,ch:`产线速度设定`,unit:`m/min`,min:280,max:360,decimals:0,icon:`encoder`,semantics:`产线速度设定:升速提高产能但缩短物料受热时间(温度补偿需联动),降速利于精细工艺。速度变化会同步影响张力与厚度分布。`},{key:`tension-sp`,name:`张力设定器`,code:`TENSION · SP`,ch:`膜张力设定`,unit:`kN`,min:18,max:26,decimals:1,icon:`tension`,semantics:`膜张力设定:张力过大易断膜/拉伸变形,过小则跑偏起皱。调整需平缓,并与速度联动观察。`},{key:`pressure-sp`,name:`压力设定器`,code:`PRESSURE · SP`,ch:`熔体压力设定`,unit:`MPa`,min:.6,max:1.2,decimals:2,icon:`pressure`,semantics:`熔体压力设定:反映挤出/泵送负荷,压力偏高提示阻力大或温度偏低,偏低可能是料位不足。调整需小幅步进。`}],u=[{kind:`mock`,label:`Mock 模拟 PLC`,status:`builtin`,configFields:[]},{kind:`modbus-tcp`,label:`Modbus TCP(PLC/网关 写保持寄存器)`,status:`real`,configFields:[{key:`host`,label:`设备地址(host)`,type:`string`,required:!0,placeholder:`192.168.1.10`,hint:`PLC 或 Modbus 网关 IP`},{key:`port`,label:`端口`,type:`number`,default:502,hint:`Modbus TCP 标准端口 502`},{key:`unitId`,label:`单元号(unitId)`,type:`number`,default:1,hint:`从站地址,常见 1`},{key:`register`,label:`写寄存器地址`,type:`number`,required:!0,placeholder:`40021`,hint:`4xxxx=保持寄存器(写);回读同址校验`},{key:`dataType`,label:`数据类型`,type:`select`,default:`float32`,options:[{value:`int16`,label:`int16(1 寄存器)`},{value:`uint16`,label:`uint16(1 寄存器)`},{value:`int32`,label:`int32(2 寄存器)`},{value:`uint32`,label:`uint32(2 寄存器)`},{value:`float32`,label:`float32(2 寄存器,常用)`}]},{key:`byteOrder`,label:`字节序`,type:`select`,default:`big`,options:[{value:`big`,label:`大端(AB CD)`},{value:`little`,label:`小端(CD AB)`},{value:`wordSwap`,label:`字交换(CD AB / 交换单字)`}]},{key:`engMin`,label:`工程量程下限`,type:`number`,hint:`线性换算:eng ∈ [engMin, engMax] ↔ raw ∈ [rawMin, rawMax];float32 且未填原始量程时 raw=eng`},{key:`engMax`,label:`工程量程上限`,type:`number`},{key:`rawMin`,label:`原始值下限`,type:`number`,hint:`如 int16 用 0~2000 表示 0.1 分辨率`},{key:`rawMax`,label:`原始值上限`,type:`number`}]},{kind:`opcua`,label:`OPC UA(PLC/MES 写节点值)`,status:`real`,configFields:[{key:`endpoint`,label:`端点(endpoint)`,type:`string`,required:!0,placeholder:`opc.tcp://192.168.1.10:4840`,hint:`OPC UA 服务器地址`},{key:`nodeId`,label:`节点 ID(NodeId)`,type:`string`,required:!0,placeholder:`ns=2;s=Channel1.Device1.SetTemp`,hint:`要写入的变量节点`},{key:`securityMode`,label:`安全策略`,type:`select`,default:`None`,options:[{value:`None`,label:`None(无加密,内网常用)`},{value:`Sign`,label:`Sign(签名)`},{value:`SignAndEncrypt`,label:`SignAndEncrypt(签名+加密)`}]},{key:`username`,label:`用户名(可选)`,type:`string`},{key:`password`,label:`密码(可选)`,type:`string`}]},{kind:`modbus-rtu`,label:`Modbus RTU over TCP(串口网关 写保持寄存器)`,status:`real`,configFields:[{key:`host`,label:`网关地址(host)`,type:`string`,required:!0,placeholder:`192.168.1.50`,hint:`串口服务器/RTU 转 TCP 网关 IP`},{key:`port`,label:`端口`,type:`number`,default:502,hint:`网关透传端口(常见 502 / 8899 / 26)`},{key:`unitId`,label:`从站地址(unitId)`,type:`number`,default:1,hint:`RS-485 总线上的从站地址`},{key:`register`,label:`写寄存器地址`,type:`number`,required:!0,placeholder:`40021`,hint:`4xxxx=保持寄存器(写);回读同址校验`},{key:`dataType`,label:`数据类型`,type:`select`,default:`float32`,options:[{value:`int16`,label:`int16(1 寄存器)`},{value:`uint16`,label:`uint16(1 寄存器)`},{value:`int32`,label:`int32(2 寄存器)`},{value:`uint32`,label:`uint32(2 寄存器)`},{value:`float32`,label:`float32(2 寄存器,常用)`}]},{key:`byteOrder`,label:`字节序`,type:`select`,default:`big`,options:[{value:`big`,label:`大端(AB CD)`},{value:`little`,label:`小端(CD AB)`},{value:`wordSwap`,label:`字交换(CD AB / 交换单字)`}]},{key:`engMin`,label:`工程量程下限`,type:`number`,hint:`线性换算:eng ∈ [engMin, engMax] ↔ raw ∈ [rawMin, rawMax];float32 且未填原始量程时 raw=eng`},{key:`engMax`,label:`工程量程上限`,type:`number`},{key:`rawMin`,label:`原始值下限`,type:`number`},{key:`rawMax`,label:`原始值上限`,type:`number`}]},{kind:`mqtt`,label:`MQTT(发布设定值到 Broker)`,status:`real`,configFields:[{key:`host`,label:`Broker 地址(host)`,type:`string`,required:!0,placeholder:`192.168.1.20`,hint:`MQTT Broker 地址(与边缘网关约定同一 Broker)`},{key:`port`,label:`端口`,type:`number`,default:1883,hint:`MQTT TCP 端口 1883`},{key:`topic`,label:`下发主题(topic)`,type:`string`,required:!0,placeholder:`factory/line1/setpoint`,hint:`网关订阅的控制主题(勿与采集主题相同)`},{key:`jsonKey`,label:`JSON 键(可选)`,type:`string`,placeholder:`setpoint`,hint:`留空 = 纯数字报文;填写 = {"键":值} JSON 报文`},{key:`qos`,label:`QoS`,type:`number`,default:1,hint:`0=至多一次 1=至少一次(推荐)`},{key:`username`,label:`用户名(可选)`,type:`string`},{key:`password`,label:`密码(可选)`,type:`string`}]},{kind:`http`,label:`HTTP/REST(POST 设定值)`,status:`real`,configFields:[{key:`url`,label:`写接口地址(URL)`,type:`string`,required:!0,placeholder:`http://192.168.1.30/api/setpoint`,hint:`接收设定值的 HTTP 接口(POST JSON)`},{key:`bodyKey`,label:`JSON 键(可选)`,type:`string`,placeholder:`setpoint`,hint:`留空 = {"value": 设定值};填写 = {"键": 设定值}`},{key:`headersJSON`,label:`请求头(可选)`,type:`string`,placeholder:`{"Authorization":"Bearer xxx"}`,hint:`JSON 对象形式的 HTTP 头`}]}],d=[`#3aa0ff`,`#f4c542`,`#35e0a0`,`#41c8f4`,`#b58cff`,`#ff8a5c`],f=(e,t)=>c({base:`/api/workshop/dcw`,path:e,init:t,retries:(t?.method??`GET`).toUpperCase()===`GET`?2:0});function p(){let r=e([]),i=e({running:!0,nodesTotal:0,nodesOnline:0,writesTotal:0,writesFailed:0}),a=e(l.map(e=>({...e}))),o=e([]),s=e([]),c=e([]),u=e([]),d=e([]),p=e({}),m=e([]);function h(e){let t=r.findIndex(t=>t.id===e.id);t>=0?r[t]=Object.assign(r[t],e):r.push(e)}function g(e){if(e.node){if(e.op===`removed`){let t=r.findIndex(t=>t.id===e.node.id);t>=0&&r.splice(t,1);return}h(e.node)}}let _=0,v=null;function y(){_++,_===1&&(v=n().subscribe(b));let e=!1;return()=>{e||(e=!0,--_===0&&(v?.(),v=null))}}function b(e){if(e.type===`dcw.written`){let t=e.payload,n=r.find(e=>e.id===t.nodeId);n&&(n.value=t.value,n.state=t.ok?`ok`:`error`,n.lastWriteAt=t.at,t.ok&&(n.lastAckAt=t.at)),c.unshift({id:`${t.nodeId}-${t.at}`,nodeId:t.nodeId,nodeName:n?.name??t.nodeId,param:``,eng:t.value,raw:t.raw,ok:t.ok,message:t.message,recipeRunId:t.recipeRunId,at:t.at}),c.length>60&&c.splice(60)}else if(e.type===`dcw.read`){let t=e.payload,n=r.find(e=>e.id===t.nodeId);n&&(t.ok&&(n.readValue=t.value),n.lastReadAt=t.at,n.lastReadError=t.ok?null:t.message)}else if(e.type===`dcw.node.changed`)g(e.payload);else if(e.type===`dcw.controller`)Object.assign(i,e.payload);else if(e.type===`dcw.optimization.changed`){let t=e.payload.record,n=m.findIndex(e=>e.id===t.id);n>=0?m[n]=t:m.unshift(t),m.length>200&&(m.length=200)}}async function x(){try{let e=await f(``);r.splice(0,r.length,...e.nodes),Object.assign(i,e.controller),e.templates?.length&&a.splice(0,a.length,...e.templates.map(e=>({...e}))),o.splice(0,o.length,...e.recipes??[]),s.splice(0,s.length,...e.runs??[]),c.splice(0,c.length,...e.history??[]),u.splice(0,u.length,...e.products??[]),d.splice(0,d.length,...e.lines??[]);for(let e of Object.keys(p))Reflect.deleteProperty(p,e);for(let t of e.lineStates??[])p[t.lineId]=t;S.loaded=!0,S.error=``}catch(e){S.error=t(e)}}let S=e({nodes:r,controller:i,templates:a,recipes:o,runs:s,history:c,products:u,lines:d,lineStates:p,optimizations:m,loaded:!1,error:``,ensureWsFeed:y,load:x,loadOptimizations:async e=>{let t=new URLSearchParams;e?.lineId&&t.set(`lineId`,e.lineId),e?.recipeId&&t.set(`recipeId`,e.recipeId),e?.nodeId&&t.set(`nodeId`,e.nodeId),e?.status&&t.set(`status`,e.status),t.set(`limit`,String(e?.limit??100));let n=await f(`/optimizations?${t.toString()}`);m.splice(0,m.length,...n.records)},fetchLedger:async e=>(await f(`/${e}/param-ledger`)).ledger,optimizationSeries:async(e,t)=>f(`/optimizations/${e}/series${t?`?windowMs=${t}`:``}`),judgeOptimization:async(e,t,n)=>{await f(`/optimizations/${e}/judge`,{method:`POST`,body:JSON.stringify({verdict:t,reason:n})})},rollbackOptimization:async e=>{await f(`/optimizations/${e}/rollback`,{method:`POST`,body:JSON.stringify({})})},rollbackNode:async(e,t)=>{await f(`/journal/node/${e}/rollback`,{method:`POST`,body:JSON.stringify({to:t})})},markGood:async(e,t)=>{await f(`/recipes/${e}/mark-good`,{method:`POST`,body:JSON.stringify({runId:t})})},rollbackRecipeGood:async e=>{await f(`/recipes/${e}/rollback-good`,{method:`POST`,body:JSON.stringify({})})},createFromTemplate:async(e,t)=>{let n=await f(``,{method:`POST`,body:JSON.stringify({templateRef:e,...t})});return h(n.node),n.node},patchNode:async(e,t)=>{await f(`/${e}`,{method:`PATCH`,body:JSON.stringify(t)})},removeNode:async e=>{await f(`/${e}`,{method:`DELETE`});let t=r.findIndex(t=>t.id===e);t>=0&&r.splice(t,1)},bindNode:async(e,t)=>{h((await f(`/${e}/bind`,{method:`POST`,body:JSON.stringify({deviceId:t})})).node)},write:async(e,t)=>f(`/${e}/write`,{method:`POST`,body:JSON.stringify({value:t})}).then(e=>e.outcome),readNode:async e=>f(`/${e}/read`,{method:`POST`,body:JSON.stringify({})}).then(e=>e.read),testDriver:async(e,t)=>f(`/test-driver`,{method:`POST`,body:JSON.stringify({driver:e,driverConfig:t})}).then(e=>e.test),testNode:async e=>f(`/${e}/test`,{method:`POST`}).then(e=>e.test),startStop:async e=>{let t=await f(`/controller`,{method:`POST`,body:JSON.stringify({action:e})});Object.assign(i,t.controller)},createTemplate:async e=>{let t=await f(`/templates`,{method:`POST`,body:JSON.stringify(e)});return a.push(t.template),t.template},createRecipe:async e=>{let t=await f(`/recipes`,{method:`POST`,body:JSON.stringify(e)});return o.push(t.recipe),t.recipe},updateRecipe:async(e,t)=>{let n=await f(`/recipes/${e}`,{method:`PATCH`,body:JSON.stringify(t)}),r=o.findIndex(t=>t.id===e);return r>=0&&(o[r]=n.recipe),n.recipe},removeRecipe:async e=>{await f(`/recipes/${e}`,{method:`DELETE`});let t=o.findIndex(t=>t.id===e);t>=0&&o.splice(t,1)},applyRecipe:async e=>{let t=await f(`/recipes/${e}/apply`,{method:`POST`});return s.push(t.run),t.run},recipeVersions:async e=>(await f(`/recipes/${e}/versions`)).versions??[],revertRecipe:async(e,t)=>{let n=await f(`/recipes/${e}/revert`,{method:`POST`,body:JSON.stringify(t)}),r=o.findIndex(t=>t.id===e);return r>=0&&(o[r]=n.recipe),n.recipe},closeRun:async e=>{let t=await f(`/runs/${e}/close`,{method:`POST`}),n=s.findIndex(t=>t.id===e);return n>=0&&(s[n]=t.run),t.run},runData:e=>f(`/runs/${e}/data`),nodeById:e=>r.find(t=>t.id===e),createProduct:async e=>{let t=await f(`/products`,{method:`POST`,body:JSON.stringify(e)});return u.push(t.product),t.product},updateProduct:async(e,t)=>f(`/products/${e}`,{method:`PATCH`,body:JSON.stringify(t)}).then(e=>(C(),e.product)),removeProduct:async e=>{await f(`/products/${e}`,{method:`DELETE`});let t=u.findIndex(t=>t.id===e);t>=0&&u.splice(t,1)},createLine:async e=>{let t=await f(`/lines`,{method:`POST`,body:JSON.stringify(e)});return d.push(t.line),t.line},updateLine:async(e,t)=>{let n=await f(`/lines/${e}`,{method:`PATCH`,body:JSON.stringify(t)}),r=d.findIndex(t=>t.id===e);r>=0&&(d[r]=n.line)},removeLine:async(e,t=!1)=>{await f(`/lines/${e}${t?`?purge=1`:``}`,{method:`DELETE`});let n=d.findIndex(t=>t.id===e);n>=0&&d.splice(n,1),Reflect.deleteProperty(p,e),await x()},startLine:async(e,t)=>{let n=await f(`/lines/${e}/start`,{method:`POST`,body:JSON.stringify({recipeId:t})});p[e]=n.line},stopLine:async e=>{let t=await f(`/lines/${e}/stop`,{method:`POST`});p[e]=t.line},lineStateOf:e=>p[e]??{lineId:e,active:!1,runId:null,recipeId:null,recipeName:null,productId:null,productName:null,startedAt:null,taggedSamples:0},queryLine:e=>{let t=new URLSearchParams;return e.lineId&&t.set(`lineId`,e.lineId),e.productId&&t.set(`productId`,e.productId),e.recipeId&&t.set(`recipeId`,e.recipeId),e.paramKey&&t.set(`paramKey`,e.paramKey),e.nodeId&&t.set(`nodeId`,e.nodeId),e.fromMs!=null&&t.set(`from`,String(e.fromMs)),e.toMs!=null&&t.set(`to`,String(e.toMs)),e.bucketMs!=null&&t.set(`bucketMs`,String(e.bucketMs)),e.limit!=null&&t.set(`limit`,String(e.limit)),f(`/line/query?${t.toString()}`)}});async function C(){try{let e=await f(``);u.splice(0,u.length,...e.products??[]),o.splice(0,o.length,...e.recipes??[])}catch{}}return S}var m=`__dcwStream`;function h(){let e=globalThis;return e[m]||(e[m]=p()),e[m]}export{c as i,u as n,d as r,h as t};
1
+ import{ft as e}from"./BSCpFtzG.js";import{t}from"./G0qIw7Gq2.js";import{t as n}from"./36oeS8_R2.js";var r=class extends Error{code;status;constructor(e,t,n){super(n),this.name=`ApiError`,this.code=e,this.status=t}};function i(e=!0){let t=typeof document<`u`?document.cookie.match(/(?:^|;\s*)token=([^;]+)/)?.[1]??``:``,n={};return t&&(n.authorization=`Bearer ${decodeURIComponent(t)}`),e&&(n[`content-type`]=`application/json`),n}var a=e=>new Promise(t=>setTimeout(t,e));function o(e){let t=(e?.method??`GET`).toUpperCase();return t===`GET`||t===`HEAD`}async function s(e,t,n){let a;try{a=await fetch(e+t,{...n,headers:{...i(!!n?.body),...n?.headers},signal:n?.signal??AbortSignal.timeout(n?.method&&n.method.toUpperCase()!==`GET`?3e4:15e3)})}catch(e){throw e instanceof Error&&(e.name===`TimeoutError`||e.name===`AbortError`)?new r(`TIMEOUT`,0,`请求超时,请检查网络或服务状态`):new r(`NETWORK`,0,`无法连接服务器,请检查网络或服务状态`)}let o=null;try{o=await a.json()}catch{}if(!a.ok)throw new r(o?.code??`HTTP_${a.status}`,a.status,o?.message||`请求失败(HTTP ${a.status})`);if(o?.code!==0)throw new r(o?.code??`REQUEST_ERROR`,a.status,o?.message||`请求失败`);return o.data}async function c(e){let{base:n,path:i=``,init:c,retries:l=0}=e,u=o(c),d=u?l+1:1,f;for(let e=0;e<d;e++)try{return await s(n,i,c)}catch(n){let i=n instanceof r?n:new r(`INTERNAL_ERROR`,0,t(n)),o=u&&(i.code===`NETWORK`||i.status>=500);if(f=i,!o||e===d-1)throw i;await a(400*(e+1))}throw f??new r(`INTERNAL_ERROR`,0,`请求失败`)}var l=[{key:`temp-sp`,name:`温度设定器`,code:`TEMP · SP`,ch:`烘箱温度设定`,unit:`℃`,min:150,max:200,decimals:1,icon:`thermo`,semantics:`烘箱/熔体温度设定:升高使热塑温度上升(成膜更均匀但能耗高、过热降解风险),降低则偏冷易厚度不均。调整后需等待热惯性(数十秒级)再评估效果。`},{key:`speed-sp`,name:`速度设定器`,code:`LINE · SP`,ch:`产线速度设定`,unit:`m/min`,min:280,max:360,decimals:0,icon:`encoder`,semantics:`产线速度设定:升速提高产能但缩短物料受热时间(温度补偿需联动),降速利于精细工艺。速度变化会同步影响张力与厚度分布。`},{key:`tension-sp`,name:`张力设定器`,code:`TENSION · SP`,ch:`膜张力设定`,unit:`kN`,min:18,max:26,decimals:1,icon:`tension`,semantics:`膜张力设定:张力过大易断膜/拉伸变形,过小则跑偏起皱。调整需平缓,并与速度联动观察。`},{key:`pressure-sp`,name:`压力设定器`,code:`PRESSURE · SP`,ch:`熔体压力设定`,unit:`MPa`,min:.6,max:1.2,decimals:2,icon:`pressure`,semantics:`熔体压力设定:反映挤出/泵送负荷,压力偏高提示阻力大或温度偏低,偏低可能是料位不足。调整需小幅步进。`}],u=[{kind:`mock`,label:`Mock 模拟 PLC`,status:`builtin`,configFields:[]},{kind:`modbus-tcp`,label:`Modbus TCP(PLC/网关 写保持寄存器)`,status:`real`,configFields:[{key:`host`,label:`设备地址(host)`,type:`string`,required:!0,placeholder:`192.168.1.10`,hint:`PLC 或 Modbus 网关 IP`},{key:`port`,label:`端口`,type:`number`,default:502,hint:`Modbus TCP 标准端口 502`},{key:`unitId`,label:`单元号(unitId)`,type:`number`,default:1,hint:`从站地址,常见 1`},{key:`register`,label:`写寄存器地址`,type:`number`,required:!0,placeholder:`40021`,hint:`4xxxx=保持寄存器(写);回读同址校验`},{key:`dataType`,label:`数据类型`,type:`select`,default:`float32`,options:[{value:`int16`,label:`int16(1 寄存器)`},{value:`uint16`,label:`uint16(1 寄存器)`},{value:`int32`,label:`int32(2 寄存器)`},{value:`uint32`,label:`uint32(2 寄存器)`},{value:`float32`,label:`float32(2 寄存器,常用)`}]},{key:`byteOrder`,label:`字节序`,type:`select`,default:`big`,options:[{value:`big`,label:`大端(AB CD)`},{value:`little`,label:`小端(CD AB)`},{value:`wordSwap`,label:`字交换(CD AB / 交换单字)`}]},{key:`engMin`,label:`工程量程下限`,type:`number`,hint:`线性换算:eng ∈ [engMin, engMax] ↔ raw ∈ [rawMin, rawMax];float32 且未填原始量程时 raw=eng`},{key:`engMax`,label:`工程量程上限`,type:`number`},{key:`rawMin`,label:`原始值下限`,type:`number`,hint:`如 int16 用 0~2000 表示 0.1 分辨率`},{key:`rawMax`,label:`原始值上限`,type:`number`}]},{kind:`opcua`,label:`OPC UA(PLC/MES 写节点值)`,status:`real`,configFields:[{key:`endpoint`,label:`端点(endpoint)`,type:`string`,required:!0,placeholder:`opc.tcp://192.168.1.10:4840`,hint:`OPC UA 服务器地址`},{key:`nodeId`,label:`节点 ID(NodeId)`,type:`string`,required:!0,placeholder:`ns=2;s=Channel1.Device1.SetTemp`,hint:`要写入的变量节点`},{key:`securityMode`,label:`安全策略`,type:`select`,default:`None`,options:[{value:`None`,label:`None(无加密,内网常用)`},{value:`Sign`,label:`Sign(签名)`},{value:`SignAndEncrypt`,label:`SignAndEncrypt(签名+加密)`}]},{key:`username`,label:`用户名(可选)`,type:`string`},{key:`password`,label:`密码(可选)`,type:`string`}]},{kind:`modbus-rtu`,label:`Modbus RTU over TCP(串口网关 写保持寄存器)`,status:`real`,configFields:[{key:`host`,label:`网关地址(host)`,type:`string`,required:!0,placeholder:`192.168.1.50`,hint:`串口服务器/RTU 转 TCP 网关 IP`},{key:`port`,label:`端口`,type:`number`,default:502,hint:`网关透传端口(常见 502 / 8899 / 26)`},{key:`unitId`,label:`从站地址(unitId)`,type:`number`,default:1,hint:`RS-485 总线上的从站地址`},{key:`register`,label:`写寄存器地址`,type:`number`,required:!0,placeholder:`40021`,hint:`4xxxx=保持寄存器(写);回读同址校验`},{key:`dataType`,label:`数据类型`,type:`select`,default:`float32`,options:[{value:`int16`,label:`int16(1 寄存器)`},{value:`uint16`,label:`uint16(1 寄存器)`},{value:`int32`,label:`int32(2 寄存器)`},{value:`uint32`,label:`uint32(2 寄存器)`},{value:`float32`,label:`float32(2 寄存器,常用)`}]},{key:`byteOrder`,label:`字节序`,type:`select`,default:`big`,options:[{value:`big`,label:`大端(AB CD)`},{value:`little`,label:`小端(CD AB)`},{value:`wordSwap`,label:`字交换(CD AB / 交换单字)`}]},{key:`engMin`,label:`工程量程下限`,type:`number`,hint:`线性换算:eng ∈ [engMin, engMax] ↔ raw ∈ [rawMin, rawMax];float32 且未填原始量程时 raw=eng`},{key:`engMax`,label:`工程量程上限`,type:`number`},{key:`rawMin`,label:`原始值下限`,type:`number`},{key:`rawMax`,label:`原始值上限`,type:`number`}]},{kind:`mqtt`,label:`MQTT(发布设定值到 Broker)`,status:`real`,configFields:[{key:`host`,label:`Broker 地址(host)`,type:`string`,required:!0,placeholder:`192.168.1.20`,hint:`MQTT Broker 地址(与边缘网关约定同一 Broker)`},{key:`port`,label:`端口`,type:`number`,default:1883,hint:`MQTT TCP 端口 1883`},{key:`topic`,label:`下发主题(topic)`,type:`string`,required:!0,placeholder:`factory/line1/setpoint`,hint:`网关订阅的控制主题(勿与采集主题相同)`},{key:`jsonKey`,label:`JSON 键(可选)`,type:`string`,placeholder:`setpoint`,hint:`留空 = 纯数字报文;填写 = {"键":值} JSON 报文`},{key:`qos`,label:`QoS`,type:`number`,default:1,hint:`0=至多一次 1=至少一次(推荐)`},{key:`username`,label:`用户名(可选)`,type:`string`},{key:`password`,label:`密码(可选)`,type:`string`}]},{kind:`http`,label:`HTTP/REST(POST 设定值)`,status:`real`,configFields:[{key:`url`,label:`写接口地址(URL)`,type:`string`,required:!0,placeholder:`http://192.168.1.30/api/setpoint`,hint:`接收设定值的 HTTP 接口(POST JSON)`},{key:`bodyKey`,label:`JSON 键(可选)`,type:`string`,placeholder:`setpoint`,hint:`留空 = {"value": 设定值};填写 = {"键": 设定值}`},{key:`headersJSON`,label:`请求头(可选)`,type:`string`,placeholder:`{"Authorization":"Bearer xxx"}`,hint:`JSON 对象形式的 HTTP 头`}]}],d=[`#3aa0ff`,`#f4c542`,`#35e0a0`,`#41c8f4`,`#b58cff`,`#ff8a5c`],f=(e,t)=>c({base:`/api/workshop/dcw`,path:e,init:t,retries:(t?.method??`GET`).toUpperCase()===`GET`?2:0});function p(){let r=e([]),i=new Map,a=e({running:!0,nodesTotal:0,nodesOnline:0,writesTotal:0,writesFailed:0}),o=e(l.map(e=>({...e}))),s=e([]),c=e([]),u=e([]),d=e([]),p=e([]),m=e({}),h=e([]);function g(e){let t=r.findIndex(t=>t.id===e.id);t>=0?r[t]=Object.assign(r[t],e):(r.push(e),i.set(e.id,r[r.length-1]))}function _(e){if(e.node){if(e.op===`removed`){let t=r.findIndex(t=>t.id===e.node.id);t>=0&&r.splice(t,1),i.delete(e.node.id);return}g(e.node)}}let v=0,y=null;function b(){v++,v===1&&(y=n().subscribe(x));let e=!1;return()=>{e||(e=!0,--v===0&&(y?.(),y=null))}}function x(e){if(e.type===`dcw.written`){let t=e.payload,n=i.get(t.nodeId);n&&(n.value=t.value,n.state=t.ok?`ok`:`error`,n.lastWriteAt=t.at,t.ok&&(n.lastAckAt=t.at)),u.unshift({id:`${t.nodeId}-${t.at}`,nodeId:t.nodeId,nodeName:n?.name??t.nodeId,param:``,eng:t.value,raw:t.raw,ok:t.ok,message:t.message,recipeRunId:t.recipeRunId,at:t.at}),u.length>60&&u.splice(60)}else if(e.type===`dcw.read`){let t=e.payload,n=i.get(t.nodeId);n&&(t.ok&&(n.readValue=t.value),n.lastReadAt=t.at,n.lastReadError=t.ok?null:t.message)}else if(e.type===`dcw.node.changed`)_(e.payload);else if(e.type===`dcw.controller`)Object.assign(a,e.payload);else if(e.type===`dcw.optimization.changed`){let t=e.payload.record,n=h.findIndex(e=>e.id===t.id);n>=0?h[n]=t:h.unshift(t),h.length>200&&(h.length=200)}}async function S(){try{let e=await f(``);r.splice(0,r.length,...e.nodes),i.clear();for(let e of r)i.set(e.id,e);Object.assign(a,e.controller),e.templates?.length&&o.splice(0,o.length,...e.templates.map(e=>({...e}))),s.splice(0,s.length,...e.recipes??[]),c.splice(0,c.length,...e.runs??[]),u.splice(0,u.length,...e.history??[]),d.splice(0,d.length,...e.products??[]),p.splice(0,p.length,...e.lines??[]);for(let e of Object.keys(m))Reflect.deleteProperty(m,e);for(let t of e.lineStates??[])m[t.lineId]=t;C.loaded=!0,C.error=``}catch(e){C.error=t(e)}}let C=e({nodes:r,controller:a,templates:o,recipes:s,runs:c,history:u,products:d,lines:p,lineStates:m,optimizations:h,loaded:!1,error:``,ensureWsFeed:b,load:S,loadOptimizations:async e=>{let t=new URLSearchParams;e?.lineId&&t.set(`lineId`,e.lineId),e?.recipeId&&t.set(`recipeId`,e.recipeId),e?.nodeId&&t.set(`nodeId`,e.nodeId),e?.status&&t.set(`status`,e.status),t.set(`limit`,String(e?.limit??100));let n=await f(`/optimizations?${t.toString()}`);h.splice(0,h.length,...n.records)},fetchLedger:async e=>(await f(`/${e}/param-ledger`)).ledger,optimizationSeries:async(e,t)=>f(`/optimizations/${e}/series${t?`?windowMs=${t}`:``}`),judgeOptimization:async(e,t,n)=>{await f(`/optimizations/${e}/judge`,{method:`POST`,body:JSON.stringify({verdict:t,reason:n})})},rollbackOptimization:async e=>{await f(`/optimizations/${e}/rollback`,{method:`POST`,body:JSON.stringify({})})},rollbackNode:async(e,t)=>{await f(`/journal/node/${e}/rollback`,{method:`POST`,body:JSON.stringify({to:t})})},markGood:async(e,t)=>{await f(`/recipes/${e}/mark-good`,{method:`POST`,body:JSON.stringify({runId:t})})},rollbackRecipeGood:async e=>{await f(`/recipes/${e}/rollback-good`,{method:`POST`,body:JSON.stringify({})})},createFromTemplate:async(e,t)=>{let n=await f(``,{method:`POST`,body:JSON.stringify({templateRef:e,...t})});return g(n.node),n.node},patchNode:async(e,t)=>{await f(`/${e}`,{method:`PATCH`,body:JSON.stringify(t)})},removeNode:async e=>{await f(`/${e}`,{method:`DELETE`});let t=r.findIndex(t=>t.id===e);t>=0&&r.splice(t,1),i.delete(e)},bindNode:async(e,t)=>{g((await f(`/${e}/bind`,{method:`POST`,body:JSON.stringify({deviceId:t})})).node)},write:async(e,t)=>f(`/${e}/write`,{method:`POST`,body:JSON.stringify({value:t})}).then(e=>e.outcome),readNode:async e=>f(`/${e}/read`,{method:`POST`,body:JSON.stringify({})}).then(e=>e.read),testDriver:async(e,t)=>f(`/test-driver`,{method:`POST`,body:JSON.stringify({driver:e,driverConfig:t})}).then(e=>e.test),testNode:async e=>f(`/${e}/test`,{method:`POST`}).then(e=>e.test),startStop:async e=>{let t=await f(`/controller`,{method:`POST`,body:JSON.stringify({action:e})});Object.assign(a,t.controller)},createTemplate:async e=>{let t=await f(`/templates`,{method:`POST`,body:JSON.stringify(e)});return o.push(t.template),t.template},createRecipe:async e=>{let t=await f(`/recipes`,{method:`POST`,body:JSON.stringify(e)});return s.push(t.recipe),t.recipe},updateRecipe:async(e,t)=>{let n=await f(`/recipes/${e}`,{method:`PATCH`,body:JSON.stringify(t)}),r=s.findIndex(t=>t.id===e);return r>=0&&(s[r]=n.recipe),n.recipe},removeRecipe:async e=>{await f(`/recipes/${e}`,{method:`DELETE`});let t=s.findIndex(t=>t.id===e);t>=0&&s.splice(t,1)},applyRecipe:async e=>{let t=await f(`/recipes/${e}/apply`,{method:`POST`});return c.push(t.run),t.run},recipeVersions:async e=>(await f(`/recipes/${e}/versions`)).versions??[],revertRecipe:async(e,t)=>{let n=await f(`/recipes/${e}/revert`,{method:`POST`,body:JSON.stringify(t)}),r=s.findIndex(t=>t.id===e);return r>=0&&(s[r]=n.recipe),n.recipe},closeRun:async e=>{let t=await f(`/runs/${e}/close`,{method:`POST`}),n=c.findIndex(t=>t.id===e);return n>=0&&(c[n]=t.run),t.run},runData:e=>f(`/runs/${e}/data`),nodeById:e=>i.get(e)??r.find(t=>t.id===e),createProduct:async e=>{let t=await f(`/products`,{method:`POST`,body:JSON.stringify(e)});return d.push(t.product),t.product},updateProduct:async(e,t)=>f(`/products/${e}`,{method:`PATCH`,body:JSON.stringify(t)}).then(e=>(w(),e.product)),removeProduct:async e=>{await f(`/products/${e}`,{method:`DELETE`});let t=d.findIndex(t=>t.id===e);t>=0&&d.splice(t,1)},createLine:async e=>{let t=await f(`/lines`,{method:`POST`,body:JSON.stringify(e)});return p.push(t.line),t.line},updateLine:async(e,t)=>{let n=await f(`/lines/${e}`,{method:`PATCH`,body:JSON.stringify(t)}),r=p.findIndex(t=>t.id===e);r>=0&&(p[r]=n.line)},removeLine:async(e,t=!1)=>{await f(`/lines/${e}${t?`?purge=1`:``}`,{method:`DELETE`});let n=p.findIndex(t=>t.id===e);n>=0&&p.splice(n,1),Reflect.deleteProperty(m,e),await S()},startLine:async(e,t)=>{let n=await f(`/lines/${e}/start`,{method:`POST`,body:JSON.stringify({recipeId:t})});m[e]=n.line},stopLine:async e=>{let t=await f(`/lines/${e}/stop`,{method:`POST`});m[e]=t.line},lineStateOf:e=>m[e]??{lineId:e,active:!1,runId:null,recipeId:null,recipeName:null,productId:null,productName:null,startedAt:null,taggedSamples:0},queryLine:e=>{let t=new URLSearchParams;return e.lineId&&t.set(`lineId`,e.lineId),e.productId&&t.set(`productId`,e.productId),e.recipeId&&t.set(`recipeId`,e.recipeId),e.paramKey&&t.set(`paramKey`,e.paramKey),e.nodeId&&t.set(`nodeId`,e.nodeId),e.fromMs!=null&&t.set(`from`,String(e.fromMs)),e.toMs!=null&&t.set(`to`,String(e.toMs)),e.bucketMs!=null&&t.set(`bucketMs`,String(e.bucketMs)),e.limit!=null&&t.set(`limit`,String(e.limit)),f(`/line/query?${t.toString()}`)}});async function w(){try{let e=await f(``);d.splice(0,d.length,...e.products??[]),s.splice(0,s.length,...e.recipes??[])}catch{}}return C}var m=`__dcwStream`;function h(){let e=globalThis;return e[m]||(e[m]=p()),e[m]}export{c as i,u as n,d as r,h as t};
@@ -0,0 +1 @@
1
+ import{C as e,F as t,H as n,Ht as r,St as i,Wt as a,a as o,b as s,et as c,f as l,g as u,h as d,lt as f,m as p,mt as m,nt as h,p as g,t as _,x as v,z as y}from"./BSCpFtzG.js";import{d as b,p as x}from"./-6OnbLFb.js";import{s as S}from"./C3tCneTM.js";import{n as C}from"./BeIfu4N3.js";import{t as w}from"./DXRZPxGs.js";import{At as T,Ct as E,d as D,n as O,t as k,u as A}from"./BDUjyaF4.js";import{t as ee}from"./VLI2Zy4t.js";import{t as te}from"./BGhOrgle.js";import{f as j,h as M,o as N,r as P,s as F}from"./D-Ca4BGY.js";import{t as ne}from"./BCJFMBQ6.js";import{t as re}from"./Cb3SnTM8.js";import{t as ie}from"./6PZPfFcO.js";import{t as ae}from"./ORt9oDIy.js";import{t as oe}from"./DoLasgPj2.js";import{t as se}from"./BcrN7QEl2.js";import{t as ce}from"./CNs_Ozdc2.js";import{t as le}from"./DNQF_TXX.js";var I={icon:{tag:`svg`,attrs:{viewBox:`64 64 896 896`,focusable:`false`},children:[{tag:`path`,attrs:{d:`M955.7 856l-416-720c-6.2-10.7-16.9-16-27.7-16s-21.6 5.3-27.7 16l-416 720C56 877.4 71.4 904 96 904h832c24.6 0 40-26.6 27.7-48zM480 416c0-4.4 3.6-8 8-8h48c4.4 0 8 3.6 8 8v184c0 4.4-3.6 8-8 8h-48c-4.4 0-8-3.6-8-8V416zm32 352a48.01 48.01 0 010-96 48.01 48.01 0 010 96z`}}]},name:`warning`,theme:`filled`};function L(e){for(var t=1;t<arguments.length;t++){var n=arguments[t]==null?{}:Object(arguments[t]),r=Object.keys(n);typeof Object.getOwnPropertySymbols==`function`&&(r=r.concat(Object.getOwnPropertySymbols(n).filter(function(e){return Object.getOwnPropertyDescriptor(n,e).enumerable}))),r.forEach(function(t){R(e,t,n[t])})}return e}function R(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}var z=function(e,t){var n=L({},e,t.attrs);return v(M,L({},n,{icon:I}),null)};z.displayName=`WarningFilled`,z.inheritAttrs=!1;var B=()=>v(`svg`,{width:`252`,height:`294`},[v(`defs`,null,[v(`path`,{d:`M0 .387h251.772v251.772H0z`},null)]),v(`g`,{fill:`none`,"fill-rule":`evenodd`},[v(`g`,{transform:`translate(0 .012)`},[v(`mask`,{fill:`#fff`},null),v(`path`,{d:`M0 127.32v-2.095C0 56.279 55.892.387 124.838.387h2.096c68.946 0 124.838 55.892 124.838 124.838v2.096c0 68.946-55.892 124.838-124.838 124.838h-2.096C55.892 252.16 0 196.267 0 127.321`,fill:`#E4EBF7`,mask:`url(#b)`},null)]),v(`path`,{d:`M39.755 130.84a8.276 8.276 0 1 1-16.468-1.66 8.276 8.276 0 0 1 16.468 1.66`,fill:`#FFF`},null),v(`path`,{d:`M36.975 134.297l10.482 5.943M48.373 146.508l-12.648 10.788`,stroke:`#FFF`,"stroke-width":`2`},null),v(`path`,{d:`M39.875 159.352a5.667 5.667 0 1 1-11.277-1.136 5.667 5.667 0 0 1 11.277 1.136M57.588 143.247a5.708 5.708 0 1 1-11.358-1.145 5.708 5.708 0 0 1 11.358 1.145M99.018 26.875l29.82-.014a4.587 4.587 0 1 0-.003-9.175l-29.82.013a4.587 4.587 0 1 0 .003 9.176M110.424 45.211l29.82-.013a4.588 4.588 0 0 0-.004-9.175l-29.82.013a4.587 4.587 0 1 0 .004 9.175`,fill:`#FFF`},null),v(`path`,{d:`M112.798 26.861v-.002l15.784-.006a4.588 4.588 0 1 0 .003 9.175l-15.783.007v-.002a4.586 4.586 0 0 0-.004-9.172M184.523 135.668c-.553 5.485-5.447 9.483-10.931 8.93-5.485-.553-9.483-5.448-8.93-10.932.552-5.485 5.447-9.483 10.932-8.93 5.485.553 9.483 5.447 8.93 10.932`,fill:`#FFF`},null),v(`path`,{d:`M179.26 141.75l12.64 7.167M193.006 156.477l-15.255 13.011`,stroke:`#FFF`,"stroke-width":`2`},null),v(`path`,{d:`M184.668 170.057a6.835 6.835 0 1 1-13.6-1.372 6.835 6.835 0 0 1 13.6 1.372M203.34 153.325a6.885 6.885 0 1 1-13.7-1.382 6.885 6.885 0 0 1 13.7 1.382`,fill:`#FFF`},null),v(`path`,{d:`M151.931 192.324a2.222 2.222 0 1 1-4.444 0 2.222 2.222 0 0 1 4.444 0zM225.27 116.056a2.222 2.222 0 1 1-4.445 0 2.222 2.222 0 0 1 4.444 0zM216.38 151.08a2.223 2.223 0 1 1-4.446-.001 2.223 2.223 0 0 1 4.446 0zM176.917 107.636a2.223 2.223 0 1 1-4.445 0 2.223 2.223 0 0 1 4.445 0zM195.291 92.165a2.223 2.223 0 1 1-4.445 0 2.223 2.223 0 0 1 4.445 0zM202.058 180.711a2.223 2.223 0 1 1-4.446 0 2.223 2.223 0 0 1 4.446 0z`,stroke:`#FFF`,"stroke-width":`2`},null),v(`path`,{stroke:`#FFF`,"stroke-width":`2`,d:`M214.404 153.302l-1.912 20.184-10.928 5.99M173.661 174.792l-6.356 9.814h-11.36l-4.508 6.484M174.941 125.168v-15.804M220.824 117.25l-12.84 7.901-15.31-7.902V94.39`},null),v(`path`,{d:`M166.588 65.936h-3.951a4.756 4.756 0 0 1-4.743-4.742 4.756 4.756 0 0 1 4.743-4.743h3.951a4.756 4.756 0 0 1 4.743 4.743 4.756 4.756 0 0 1-4.743 4.742`,fill:`#FFF`},null),v(`path`,{d:`M174.823 30.03c0-16.281 13.198-29.48 29.48-29.48 16.28 0 29.48 13.199 29.48 29.48 0 16.28-13.2 29.48-29.48 29.48-16.282 0-29.48-13.2-29.48-29.48`,fill:`#1890FF`},null),v(`path`,{d:`M205.952 38.387c.5.5.785 1.142.785 1.928s-.286 1.465-.785 1.964c-.572.5-1.214.75-2 .75-.785 0-1.429-.285-1.929-.785-.572-.5-.82-1.143-.82-1.929s.248-1.428.82-1.928c.5-.5 1.144-.75 1.93-.75.785 0 1.462.25 1.999.75m4.285-19.463c1.428 1.249 2.143 2.963 2.143 5.142 0 1.712-.427 3.13-1.219 4.25-.067.096-.137.18-.218.265-.416.429-1.41 1.346-2.956 2.699a5.07 5.07 0 0 0-1.428 1.75 5.207 5.207 0 0 0-.536 2.357v.5h-4.107v-.5c0-1.357.215-2.536.714-3.5.464-.964 1.857-2.464 4.178-4.536l.43-.5c.643-.785.964-1.643.964-2.535 0-1.18-.358-2.108-1-2.785-.678-.68-1.643-1.001-2.858-1.001-1.536 0-2.642.464-3.357 1.43-.37.5-.621 1.135-.76 1.904a1.999 1.999 0 0 1-1.971 1.63h-.004c-1.277 0-2.257-1.183-1.98-2.43.337-1.518 1.02-2.78 2.073-3.784 1.536-1.5 3.607-2.25 6.25-2.25 2.32 0 4.214.607 5.642 1.894`,fill:`#FFF`},null),v(`path`,{d:`M52.04 76.131s21.81 5.36 27.307 15.945c5.575 10.74-6.352 9.26-15.73 4.935-10.86-5.008-24.7-11.822-11.577-20.88`,fill:`#FFB594`},null),v(`path`,{d:`M90.483 67.504l-.449 2.893c-.753.49-4.748-2.663-4.748-2.663l-1.645.748-1.346-5.684s6.815-4.589 8.917-5.018c2.452-.501 9.884.94 10.7 2.278 0 0 1.32.486-2.227.69-3.548.203-5.043.447-6.79 3.132-1.747 2.686-2.412 3.624-2.412 3.624`,fill:`#FFC6A0`},null),v(`path`,{d:`M128.055 111.367c-2.627-7.724-6.15-13.18-8.917-15.478-3.5-2.906-9.34-2.225-11.366-4.187-1.27-1.231-3.215-1.197-3.215-1.197s-14.98-3.158-16.828-3.479c-2.37-.41-2.124-.714-6.054-1.405-1.57-1.907-2.917-1.122-2.917-1.122l-7.11-1.383c-.853-1.472-2.423-1.023-2.423-1.023l-2.468-.897c-1.645 9.976-7.74 13.796-7.74 13.796 1.795 1.122 15.703 8.3 15.703 8.3l5.107 37.11s-3.321 5.694 1.346 9.109c0 0 19.883-3.743 34.921-.329 0 0 3.047-2.546.972-8.806.523-3.01 1.394-8.263 1.736-11.622.385.772 2.019 1.918 3.14 3.477 0 0 9.407-7.365 11.052-14.012-.832-.723-1.598-1.585-2.267-2.453-.567-.736-.358-2.056-.765-2.717-.669-1.084-1.804-1.378-1.907-1.682`,fill:`#FFF`},null),v(`path`,{d:`M101.09 289.998s4.295 2.041 7.354 1.021c2.821-.94 4.53.668 7.08 1.178 2.55.51 6.874 1.1 11.686-1.26-.103-5.51-6.889-3.98-11.96-6.713-2.563-1.38-3.784-4.722-3.598-8.799h-9.402s-1.392 10.52-1.16 14.573`,fill:`#CBD1D1`},null),v(`path`,{d:`M101.067 289.826s2.428 1.271 6.759.653c3.058-.437 3.712.481 7.423 1.031 3.712.55 10.724-.069 11.823-.894.413 1.1-.343 2.063-.343 2.063s-1.512.603-4.812.824c-2.03.136-5.8.291-7.607-.503-1.787-1.375-5.247-1.903-5.728-.241-3.918.95-7.355-.286-7.355-.286l-.16-2.647z`,fill:`#2B0849`},null),v(`path`,{d:`M108.341 276.044h3.094s-.103 6.702 4.536 8.558c-4.64.618-8.558-2.303-7.63-8.558`,fill:`#A4AABA`},null),v(`path`,{d:`M57.542 272.401s-2.107 7.416-4.485 12.306c-1.798 3.695-4.225 7.492 5.465 7.492 6.648 0 8.953-.48 7.423-6.599-1.53-6.12.266-13.199.266-13.199h-8.669z`,fill:`#CBD1D1`},null),v(`path`,{d:`M51.476 289.793s2.097 1.169 6.633 1.169c6.083 0 8.249-1.65 8.249-1.65s.602 1.114-.619 2.165c-.993.855-3.597 1.591-7.39 1.546-4.145-.048-5.832-.566-6.736-1.168-.825-.55-.687-1.58-.137-2.062`,fill:`#2B0849`},null),v(`path`,{d:`M58.419 274.304s.033 1.519-.314 2.93c-.349 1.42-1.078 3.104-1.13 4.139-.058 1.151 4.537 1.58 5.155.034.62-1.547 1.294-6.427 1.913-7.252.619-.825-4.903-2.119-5.624.15`,fill:`#A4AABA`},null),v(`path`,{d:`M99.66 278.514l13.378.092s1.298-54.52 1.853-64.403c.554-9.882 3.776-43.364 1.002-63.128l-12.547-.644-22.849.78s-.434 3.966-1.195 9.976c-.063.496-.682.843-.749 1.365-.075.585.423 1.354.32 1.966-2.364 14.08-6.377 33.104-8.744 46.677-.116.666-1.234 1.009-1.458 2.691-.04.302.211 1.525.112 1.795-6.873 18.744-10.949 47.842-14.277 61.885l14.607-.014s2.197-8.57 4.03-16.97c2.811-12.886 23.111-85.01 23.111-85.01l3.016-.521 1.043 46.35s-.224 1.234.337 2.02c.56.785-.56 1.123-.392 2.244l.392 1.794s-.449 7.178-.898 11.89c-.448 4.71-.092 39.165-.092 39.165`,fill:`#7BB2F9`},null),v(`path`,{d:`M76.085 221.626c1.153.094 4.038-2.019 6.955-4.935M106.36 225.142s2.774-1.11 6.103-3.883`,stroke:`#648BD8`,"stroke-width":`1.051`,"stroke-linecap":`round`,"stroke-linejoin":`round`},null),v(`path`,{d:`M107.275 222.1s2.773-1.11 6.102-3.884`,stroke:`#648BD8`,"stroke-linecap":`round`,"stroke-linejoin":`round`},null),v(`path`,{d:`M74.74 224.767s2.622-.591 6.505-3.365M86.03 151.634c-.27 3.106.3 8.525-4.336 9.123M103.625 149.88s.11 14.012-1.293 15.065c-2.219 1.664-2.99 1.944-2.99 1.944M99.79 150.438s.035 12.88-1.196 24.377M93.673 175.911s7.212-1.664 9.431-1.664M74.31 205.861a212.013 212.013 0 0 1-.979 4.56s-1.458 1.832-1.009 3.776c.449 1.944-.947 2.045-4.985 15.355-1.696 5.59-4.49 18.591-6.348 27.597l-.231 1.12M75.689 197.807a320.934 320.934 0 0 1-.882 4.754M82.591 152.233L81.395 162.7s-1.097.15-.5 2.244c.113 1.346-2.674 15.775-5.18 30.43M56.12 274.418h13.31`,stroke:`#648BD8`,"stroke-width":`1.051`,"stroke-linecap":`round`,"stroke-linejoin":`round`},null),v(`path`,{d:`M116.241 148.22s-17.047-3.104-35.893.2c.158 2.514-.003 4.15-.003 4.15s14.687-2.818 35.67-.312c.252-2.355.226-4.038.226-4.038`,fill:`#192064`},null),v(`path`,{d:`M106.322 151.165l.003-4.911a.81.81 0 0 0-.778-.815c-2.44-.091-5.066-.108-7.836-.014a.818.818 0 0 0-.789.815l-.003 4.906a.81.81 0 0 0 .831.813c2.385-.06 4.973-.064 7.73.017a.815.815 0 0 0 .842-.81`,fill:`#FFF`},null),v(`path`,{d:`M105.207 150.233l.002-3.076a.642.642 0 0 0-.619-.646 94.321 94.321 0 0 0-5.866-.01.65.65 0 0 0-.63.647v3.072a.64.64 0 0 0 .654.644 121.12 121.12 0 0 1 5.794.011c.362.01.665-.28.665-.642`,fill:`#192064`},null),v(`path`,{d:`M100.263 275.415h12.338M101.436 270.53c.006 3.387.042 5.79.111 6.506M101.451 264.548a915.75 915.75 0 0 0-.015 4.337M100.986 174.965l.898 44.642s.673 1.57-.225 2.692c-.897 1.122 2.468.673.898 2.243-1.57 1.57.897 1.122 0 3.365-.596 1.489-.994 21.1-1.096 35.146`,stroke:`#648BD8`,"stroke-width":`1.051`,"stroke-linecap":`round`,"stroke-linejoin":`round`},null),v(`path`,{d:`M46.876 83.427s-.516 6.045 7.223 5.552c11.2-.712 9.218-9.345 31.54-21.655-.786-2.708-2.447-4.744-2.447-4.744s-11.068 3.11-22.584 8.046c-6.766 2.9-13.395 6.352-13.732 12.801M104.46 91.057l.941-5.372-8.884-11.43-5.037 5.372-1.74 7.834a.321.321 0 0 0 .108.32c.965.8 6.5 5.013 14.347 3.544a.332.332 0 0 0 .264-.268`,fill:`#FFC6A0`},null),v(`path`,{d:`M93.942 79.387s-4.533-2.853-2.432-6.855c1.623-3.09 4.513 1.133 4.513 1.133s.52-3.642 3.121-3.642c.52-1.04 1.561-4.162 1.561-4.162s11.445 2.601 13.526 3.121c0 5.203-2.304 19.424-7.84 19.861-8.892.703-12.449-9.456-12.449-9.456`,fill:`#FFC6A0`},null),v(`path`,{d:`M113.874 73.446c2.601-2.081 3.47-9.722 3.47-9.722s-2.479-.49-6.64-2.05c-4.683-2.081-12.798-4.747-17.48.976-9.668 3.223-2.05 19.823-2.05 19.823l2.713-3.021s-3.935-3.287-2.08-6.243c2.17-3.462 3.92 1.073 3.92 1.073s.637-2.387 3.581-3.342c.355-.71 1.036-2.674 1.432-3.85a1.073 1.073 0 0 1 1.263-.704c2.4.558 8.677 2.019 11.356 2.662.522.125.871.615.82 1.15l-.305 3.248z`,fill:`#520038`},null),v(`path`,{d:`M104.977 76.064c-.103.61-.582 1.038-1.07.956-.489-.083-.801-.644-.698-1.254.103-.61.582-1.038 1.07-.956.488.082.8.644.698 1.254M112.132 77.694c-.103.61-.582 1.038-1.07.956-.488-.083-.8-.644-.698-1.254.103-.61.582-1.038 1.07-.956.488.082.8.643.698 1.254`,fill:`#552950`},null),v(`path`,{stroke:`#DB836E`,"stroke-width":`1.118`,"stroke-linecap":`round`,"stroke-linejoin":`round`,d:`M110.13 74.84l-.896 1.61-.298 4.357h-2.228`},null),v(`path`,{d:`M110.846 74.481s1.79-.716 2.506.537`,stroke:`#5C2552`,"stroke-width":`1.118`,"stroke-linecap":`round`,"stroke-linejoin":`round`},null),v(`path`,{d:`M92.386 74.282s.477-1.114 1.113-.716c.637.398 1.274 1.433.558 1.99-.717.556.159 1.67.159 1.67`,stroke:`#DB836E`,"stroke-width":`1.118`,"stroke-linecap":`round`,"stroke-linejoin":`round`},null),v(`path`,{d:`M103.287 72.93s1.83 1.113 4.137.954`,stroke:`#5C2552`,"stroke-width":`1.118`,"stroke-linecap":`round`,"stroke-linejoin":`round`},null),v(`path`,{d:`M103.685 81.762s2.227 1.193 4.376 1.193M104.64 84.308s.954.398 1.511.318M94.693 81.205s2.308 7.4 10.424 7.639`,stroke:`#DB836E`,"stroke-width":`1.118`,"stroke-linecap":`round`,"stroke-linejoin":`round`},null),v(`path`,{d:`M81.45 89.384s.45 5.647-4.935 12.787M69 82.654s-.726 9.282-8.204 14.206`,stroke:`#E4EBF7`,"stroke-width":`1.101`,"stroke-linecap":`round`,"stroke-linejoin":`round`},null),v(`path`,{d:`M129.405 122.865s-5.272 7.403-9.422 10.768`,stroke:`#E4EBF7`,"stroke-width":`1.051`,"stroke-linecap":`round`,"stroke-linejoin":`round`},null),v(`path`,{d:`M119.306 107.329s.452 4.366-2.127 32.062`,stroke:`#E4EBF7`,"stroke-width":`1.101`,"stroke-linecap":`round`,"stroke-linejoin":`round`},null),v(`path`,{d:`M150.028 151.232h-49.837a1.01 1.01 0 0 1-1.01-1.01v-31.688c0-.557.452-1.01 1.01-1.01h49.837c.558 0 1.01.453 1.01 1.01v31.688a1.01 1.01 0 0 1-1.01 1.01`,fill:`#F2D7AD`},null),v(`path`,{d:`M150.29 151.232h-19.863v-33.707h20.784v32.786a.92.92 0 0 1-.92.92`,fill:`#F4D19D`},null),v(`path`,{d:`M123.554 127.896H92.917a.518.518 0 0 1-.425-.816l6.38-9.113c.193-.277.51-.442.85-.442h31.092l-7.26 10.371z`,fill:`#F2D7AD`},null),v(`path`,{fill:`#CC9B6E`,d:`M123.689 128.447H99.25v-.519h24.169l7.183-10.26.424.298z`},null),v(`path`,{d:`M158.298 127.896h-18.669a2.073 2.073 0 0 1-1.659-.83l-7.156-9.541h19.965c.49 0 .95.23 1.244.622l6.69 8.92a.519.519 0 0 1-.415.83`,fill:`#F4D19D`},null),v(`path`,{fill:`#CC9B6E`,d:`M157.847 128.479h-19.384l-7.857-10.475.415-.31 7.7 10.266h19.126zM130.554 150.685l-.032-8.177.519-.002.032 8.177z`},null),v(`path`,{fill:`#CC9B6E`,d:`M130.511 139.783l-.08-21.414.519-.002.08 21.414zM111.876 140.932l-.498-.143 1.479-5.167.498.143zM108.437 141.06l-2.679-2.935 2.665-3.434.41.318-2.397 3.089 2.384 2.612zM116.607 141.06l-.383-.35 2.383-2.612-2.397-3.089.41-.318 2.665 3.434z`},null),v(`path`,{d:`M154.316 131.892l-3.114-1.96.038 3.514-1.043.092c-1.682.115-3.634.23-4.789.23-1.902 0-2.693 2.258 2.23 2.648l-2.645-.596s-2.168 1.317.504 2.3c0 0-1.58 1.217.561 2.58-.584 3.504 5.247 4.058 7.122 3.59 1.876-.47 4.233-2.359 4.487-5.16.28-3.085-.89-5.432-3.35-7.238`,fill:`#FFC6A0`},null),v(`path`,{d:`M153.686 133.577s-6.522.47-8.36.372c-1.836-.098-1.904 2.19 2.359 2.264 3.739.15 5.451-.044 5.451-.044`,stroke:`#DB836E`,"stroke-width":`1.051`,"stroke-linecap":`round`,"stroke-linejoin":`round`},null),v(`path`,{d:`M145.16 135.877c-1.85 1.346.561 2.355.561 2.355s3.478.898 6.73.617`,stroke:`#DB836E`,"stroke-width":`1.051`,"stroke-linecap":`round`,"stroke-linejoin":`round`},null),v(`path`,{d:`M151.89 141.71s-6.28.111-6.73-2.132c-.223-1.346.45-1.402.45-1.402M146.114 140.868s-1.103 3.16 5.44 3.533M151.202 129.932v3.477M52.838 89.286c3.533-.337 8.423-1.248 13.582-7.754`,stroke:`#DB836E`,"stroke-width":`1.051`,"stroke-linecap":`round`,"stroke-linejoin":`round`},null),v(`path`,{d:`M168.567 248.318a6.647 6.647 0 0 1-6.647-6.647v-66.466a6.647 6.647 0 1 1 13.294 0v66.466a6.647 6.647 0 0 1-6.647 6.647`,fill:`#5BA02E`},null),v(`path`,{d:`M176.543 247.653a6.647 6.647 0 0 1-6.646-6.647v-33.232a6.647 6.647 0 1 1 13.293 0v33.232a6.647 6.647 0 0 1-6.647 6.647`,fill:`#92C110`},null),v(`path`,{d:`M186.443 293.613H158.92a3.187 3.187 0 0 1-3.187-3.187v-46.134a3.187 3.187 0 0 1 3.187-3.187h27.524a3.187 3.187 0 0 1 3.187 3.187v46.134a3.187 3.187 0 0 1-3.187 3.187`,fill:`#F2D7AD`},null),v(`path`,{d:`M88.979 89.48s7.776 5.384 16.6 2.842`,stroke:`#E4EBF7`,"stroke-width":`1.101`,"stroke-linecap":`round`,"stroke-linejoin":`round`},null)])]),V=()=>v(`svg`,{width:`254`,height:`294`},[v(`defs`,null,[v(`path`,{d:`M0 .335h253.49v253.49H0z`},null),v(`path`,{d:`M0 293.665h253.49V.401H0z`},null)]),v(`g`,{fill:`none`,"fill-rule":`evenodd`},[v(`g`,{transform:`translate(0 .067)`},[v(`mask`,{fill:`#fff`},null),v(`path`,{d:`M0 128.134v-2.11C0 56.608 56.273.334 125.69.334h2.11c69.416 0 125.69 56.274 125.69 125.69v2.11c0 69.417-56.274 125.69-125.69 125.69h-2.11C56.273 253.824 0 197.551 0 128.134`,fill:`#E4EBF7`,mask:`url(#b)`},null)]),v(`path`,{d:`M39.989 132.108a8.332 8.332 0 1 1-16.581-1.671 8.332 8.332 0 0 1 16.58 1.671`,fill:`#FFF`},null),v(`path`,{d:`M37.19 135.59l10.553 5.983M48.665 147.884l-12.734 10.861`,stroke:`#FFF`,"stroke-width":`2`},null),v(`path`,{d:`M40.11 160.816a5.706 5.706 0 1 1-11.354-1.145 5.706 5.706 0 0 1 11.354 1.145M57.943 144.6a5.747 5.747 0 1 1-11.436-1.152 5.747 5.747 0 0 1 11.436 1.153M99.656 27.434l30.024-.013a4.619 4.619 0 1 0-.004-9.238l-30.024.013a4.62 4.62 0 0 0 .004 9.238M111.14 45.896l30.023-.013a4.62 4.62 0 1 0-.004-9.238l-30.024.013a4.619 4.619 0 1 0 .004 9.238`,fill:`#FFF`},null),v(`path`,{d:`M113.53 27.421v-.002l15.89-.007a4.619 4.619 0 1 0 .005 9.238l-15.892.007v-.002a4.618 4.618 0 0 0-.004-9.234M150.167 70.091h-3.979a4.789 4.789 0 0 1-4.774-4.775 4.788 4.788 0 0 1 4.774-4.774h3.979a4.789 4.789 0 0 1 4.775 4.774 4.789 4.789 0 0 1-4.775 4.775`,fill:`#FFF`},null),v(`path`,{d:`M171.687 30.234c0-16.392 13.289-29.68 29.681-29.68 16.392 0 29.68 13.288 29.68 29.68 0 16.393-13.288 29.681-29.68 29.681s-29.68-13.288-29.68-29.68`,fill:`#FF603B`},null),v(`path`,{d:`M203.557 19.435l-.676 15.035a1.514 1.514 0 0 1-3.026 0l-.675-15.035a2.19 2.19 0 1 1 4.377 0m-.264 19.378c.513.477.77 1.1.77 1.87s-.257 1.393-.77 1.907c-.55.476-1.21.733-1.943.733a2.545 2.545 0 0 1-1.87-.77c-.55-.514-.806-1.136-.806-1.87 0-.77.256-1.393.806-1.87.513-.513 1.137-.733 1.87-.733.77 0 1.43.22 1.943.733`,fill:`#FFF`},null),v(`path`,{d:`M119.3 133.275c4.426-.598 3.612-1.204 4.079-4.778.675-5.18-3.108-16.935-8.262-25.118-1.088-10.72-12.598-11.24-12.598-11.24s4.312 4.895 4.196 16.199c1.398 5.243.804 14.45.804 14.45s5.255 11.369 11.78 10.487`,fill:`#FFB594`},null),v(`path`,{d:`M100.944 91.61s1.463-.583 3.211.582c8.08 1.398 10.368 6.706 11.3 11.368 1.864 1.282 1.864 2.33 1.864 3.496.365.777 1.515 3.03 1.515 3.03s-7.225 1.748-10.954 6.758c-1.399-6.41-6.936-25.235-6.936-25.235`,fill:`#FFF`},null),v(`path`,{d:`M94.008 90.5l1.019-5.815-9.23-11.874-5.233 5.581-2.593 9.863s8.39 5.128 16.037 2.246`,fill:`#FFB594`},null),v(`path`,{d:`M82.931 78.216s-4.557-2.868-2.445-6.892c1.632-3.107 4.537 1.139 4.537 1.139s.524-3.662 3.139-3.662c.523-1.046 1.569-4.184 1.569-4.184s11.507 2.615 13.6 3.138c-.001 5.23-2.317 19.529-7.884 19.969-8.94.706-12.516-9.508-12.516-9.508`,fill:`#FFC6A0`},null),v(`path`,{d:`M102.971 72.243c2.616-2.093 3.489-9.775 3.489-9.775s-2.492-.492-6.676-2.062c-4.708-2.092-12.867-4.771-17.575.982-9.54 4.41-2.062 19.93-2.062 19.93l2.729-3.037s-3.956-3.304-2.092-6.277c2.183-3.48 3.943 1.08 3.943 1.08s.64-2.4 3.6-3.36c.356-.714 1.04-2.69 1.44-3.872a1.08 1.08 0 0 1 1.27-.707c2.41.56 8.723 2.03 11.417 2.676.524.126.876.619.825 1.156l-.308 3.266z`,fill:`#520038`},null),v(`path`,{d:`M101.22 76.514c-.104.613-.585 1.044-1.076.96-.49-.082-.805-.646-.702-1.26.104-.613.585-1.044 1.076-.961.491.083.805.647.702 1.26M94.26 75.074c-.104.613-.585 1.044-1.076.96-.49-.082-.805-.646-.702-1.26.104-.613.585-1.044 1.076-.96.491.082.805.646.702 1.26`,fill:`#552950`},null),v(`path`,{stroke:`#DB836E`,"stroke-width":`1.063`,"stroke-linecap":`round`,"stroke-linejoin":`round`,d:`M99.206 73.644l-.9 1.62-.3 4.38h-2.24`},null),v(`path`,{d:`M99.926 73.284s1.8-.72 2.52.54`,stroke:`#5C2552`,"stroke-width":`1.117`,"stroke-linecap":`round`,"stroke-linejoin":`round`},null),v(`path`,{d:`M81.367 73.084s.48-1.12 1.12-.72c.64.4 1.28 1.44.56 2s.16 1.68.16 1.68`,stroke:`#DB836E`,"stroke-width":`1.117`,"stroke-linecap":`round`,"stroke-linejoin":`round`},null),v(`path`,{d:`M92.326 71.724s1.84 1.12 4.16.96`,stroke:`#5C2552`,"stroke-width":`1.117`,"stroke-linecap":`round`,"stroke-linejoin":`round`},null),v(`path`,{d:`M92.726 80.604s2.24 1.2 4.4 1.2M93.686 83.164s.96.4 1.52.32M83.687 80.044s1.786 6.547 9.262 7.954`,stroke:`#DB836E`,"stroke-width":`1.063`,"stroke-linecap":`round`,"stroke-linejoin":`round`},null),v(`path`,{d:`M95.548 91.663s-1.068 2.821-8.298 2.105c-7.23-.717-10.29-5.044-10.29-5.044`,stroke:`#E4EBF7`,"stroke-width":`1.136`,"stroke-linecap":`round`,"stroke-linejoin":`round`},null),v(`path`,{d:`M78.126 87.478s6.526 4.972 16.47 2.486c0 0 9.577 1.02 11.536 5.322 5.36 11.77.543 36.835 0 39.962 3.496 4.055-.466 8.483-.466 8.483-15.624-3.548-35.81-.6-35.81-.6-4.849-3.546-1.223-9.044-1.223-9.044L62.38 110.32c-2.485-15.227.833-19.803 3.549-20.743 3.03-1.049 8.04-1.282 8.04-1.282.496-.058 1.08-.076 1.37-.233 2.36-1.282 2.787-.583 2.787-.583`,fill:`#FFF`},null),v(`path`,{d:`M65.828 89.81s-6.875.465-7.59 8.156c-.466 8.857 3.03 10.954 3.03 10.954s6.075 22.102 16.796 22.957c8.39-2.176 4.758-6.702 4.661-11.42-.233-11.304-7.108-16.897-7.108-16.897s-4.212-13.75-9.789-13.75`,fill:`#FFC6A0`},null),v(`path`,{d:`M71.716 124.225s.855 11.264 9.828 6.486c4.765-2.536 7.581-13.828 9.789-22.568 1.456-5.768 2.58-12.197 2.58-12.197l-4.973-1.709s-2.408 5.516-7.769 12.275c-4.335 5.467-9.144 11.11-9.455 17.713`,fill:`#FFC6A0`},null),v(`path`,{d:`M108.463 105.191s1.747 2.724-2.331 30.535c2.376 2.216 1.053 6.012-.233 7.51`,stroke:`#E4EBF7`,"stroke-width":`1.085`,"stroke-linecap":`round`,"stroke-linejoin":`round`},null),v(`path`,{d:`M123.262 131.527s-.427 2.732-11.77 1.981c-15.187-1.006-25.326-3.25-25.326-3.25l.933-5.8s.723.215 9.71-.068c11.887-.373 18.714-6.07 24.964-1.022 4.039 3.263 1.489 8.16 1.489 8.16`,fill:`#FFC6A0`},null),v(`path`,{d:`M70.24 90.974s-5.593-4.739-11.054 2.68c-3.318 7.223.517 15.284 2.664 19.578-.31 3.729 2.33 4.311 2.33 4.311s.108.895 1.516 2.68c4.078-7.03 6.72-9.166 13.711-12.546-.328-.656-1.877-3.265-1.825-3.767.175-1.69-1.282-2.623-1.282-2.623s-.286-.156-1.165-2.738c-.788-2.313-2.036-5.177-4.895-7.575`,fill:`#FFF`},null),v(`path`,{d:`M90.232 288.027s4.855 2.308 8.313 1.155c3.188-1.063 5.12.755 8.002 1.331 2.881.577 7.769 1.243 13.207-1.424-.117-6.228-7.786-4.499-13.518-7.588-2.895-1.56-4.276-5.336-4.066-9.944H91.544s-1.573 11.89-1.312 16.47`,fill:`#CBD1D1`},null),v(`path`,{d:`M90.207 287.833s2.745 1.437 7.639.738c3.456-.494 3.223.66 7.418 1.282 4.195.621 13.092-.194 14.334-1.126.466 1.242-.388 2.33-.388 2.33s-1.709.682-5.438.932c-2.295.154-8.098.276-10.14-.621-2.02-1.554-4.894-1.515-6.06-.234-4.427 1.075-7.184-.31-7.184-.31l-.181-2.991z`,fill:`#2B0849`},null),v(`path`,{d:`M98.429 272.257h3.496s-.117 7.574 5.127 9.671c-5.244.7-9.672-2.602-8.623-9.671`,fill:`#A4AABA`},null),v(`path`,{d:`M44.425 272.046s-2.208 7.774-4.702 12.899c-1.884 3.874-4.428 7.854 5.729 7.854 6.97 0 9.385-.503 7.782-6.917-1.604-6.415.279-13.836.279-13.836h-9.088z`,fill:`#CBD1D1`},null),v(`path`,{d:`M38.066 290.277s2.198 1.225 6.954 1.225c6.376 0 8.646-1.73 8.646-1.73s.63 1.168-.649 2.27c-1.04.897-3.77 1.668-7.745 1.621-4.347-.05-6.115-.593-7.062-1.224-.864-.577-.72-1.657-.144-2.162`,fill:`#2B0849`},null),v(`path`,{d:`M45.344 274.041s.035 1.592-.329 3.07c-.365 1.49-1.13 3.255-1.184 4.34-.061 1.206 4.755 1.657 5.403.036.65-1.622 1.357-6.737 2.006-7.602.648-.865-5.14-2.222-5.896.156`,fill:`#A4AABA`},null),v(`path`,{d:`M89.476 277.57l13.899.095s1.349-56.643 1.925-66.909c.576-10.267 3.923-45.052 1.042-65.585l-13.037-.669-23.737.81s-.452 4.12-1.243 10.365c-.065.515-.708.874-.777 1.417-.078.608.439 1.407.332 2.044-2.455 14.627-5.797 32.736-8.256 46.837-.121.693-1.282 1.048-1.515 2.796-.042.314.22 1.584.116 1.865-7.14 19.473-12.202 52.601-15.66 67.19l15.176-.015s2.282-10.145 4.185-18.871c2.922-13.389 24.012-88.32 24.012-88.32l3.133-.954-.158 48.568s-.233 1.282.35 2.098c.583.815-.581 1.167-.408 2.331l.408 1.864s-.466 7.458-.932 12.352c-.467 4.895 1.145 40.69 1.145 40.69`,fill:`#7BB2F9`},null),v(`path`,{d:`M64.57 218.881c1.197.099 4.195-2.097 7.225-5.127M96.024 222.534s2.881-1.152 6.34-4.034`,stroke:`#648BD8`,"stroke-width":`1.085`,"stroke-linecap":`round`,"stroke-linejoin":`round`},null),v(`path`,{d:`M96.973 219.373s2.882-1.153 6.34-4.034`,stroke:`#648BD8`,"stroke-width":`1.032`,"stroke-linecap":`round`,"stroke-linejoin":`round`},null),v(`path`,{d:`M63.172 222.144s2.724-.614 6.759-3.496M74.903 146.166c-.281 3.226.31 8.856-4.506 9.478M93.182 144.344s.115 14.557-1.344 15.65c-2.305 1.73-3.107 2.02-3.107 2.02M89.197 144.923s.269 13.144-1.01 25.088M83.525 170.71s6.81-1.051 9.116-1.051M46.026 270.045l-.892 4.538M46.937 263.289l-.815 4.157M62.725 202.503c-.33 1.618-.102 1.904-.449 3.438 0 0-2.756 1.903-2.29 3.923.466 2.02-.31 3.424-4.505 17.252-1.762 5.807-4.233 18.922-6.165 28.278-.03.144-.521 2.646-1.14 5.8M64.158 194.136c-.295 1.658-.6 3.31-.917 4.938M71.33 146.787l-1.244 10.877s-1.14.155-.519 2.33c.117 1.399-2.778 16.39-5.382 31.615M44.242 273.727H58.07`,stroke:`#648BD8`,"stroke-width":`1.085`,"stroke-linecap":`round`,"stroke-linejoin":`round`},null),v(`path`,{d:`M106.18 142.117c-3.028-.489-18.825-2.744-36.219.2a.625.625 0 0 0-.518.644c.063 1.307.044 2.343.015 2.995a.617.617 0 0 0 .716.636c3.303-.534 17.037-2.412 35.664-.266.347.04.66-.214.692-.56.124-1.347.16-2.425.17-3.029a.616.616 0 0 0-.52-.62`,fill:`#192064`},null),v(`path`,{d:`M96.398 145.264l.003-5.102a.843.843 0 0 0-.809-.847 114.104 114.104 0 0 0-8.141-.014.85.85 0 0 0-.82.847l-.003 5.097c0 .476.388.857.864.845 2.478-.064 5.166-.067 8.03.017a.848.848 0 0 0 .876-.843`,fill:`#FFF`},null),v(`path`,{d:`M95.239 144.296l.002-3.195a.667.667 0 0 0-.643-.672c-1.9-.061-3.941-.073-6.094-.01a.675.675 0 0 0-.654.672l-.002 3.192c0 .376.305.677.68.669 1.859-.042 3.874-.043 6.02.012.376.01.69-.291.691-.668`,fill:`#192064`},null),v(`path`,{d:`M90.102 273.522h12.819M91.216 269.761c.006 3.519-.072 5.55 0 6.292M90.923 263.474c-.009 1.599-.016 2.558-.016 4.505M90.44 170.404l.932 46.38s.7 1.631-.233 2.796c-.932 1.166 2.564.7.932 2.33-1.63 1.633.933 1.166 0 3.497-.618 1.546-1.031 21.921-1.138 36.513`,stroke:`#648BD8`,"stroke-width":`1.085`,"stroke-linecap":`round`,"stroke-linejoin":`round`},null),v(`path`,{d:`M73.736 98.665l2.214 4.312s2.098.816 1.865 2.68l.816 2.214M64.297 116.611c.233-.932 2.176-7.147 12.585-10.488M77.598 90.042s7.691 6.137 16.547 2.72`,stroke:`#E4EBF7`,"stroke-width":`1.085`,"stroke-linecap":`round`,"stroke-linejoin":`round`},null),v(`path`,{d:`M91.974 86.954s5.476-.816 7.574-4.545c1.297-.345.72 2.212-.33 3.671-.7.971-1.01 1.554-1.01 1.554s.194.31.155.816c-.053.697-.175.653-.272 1.048-.081.335.108.657 0 1.049-.046.17-.198.5-.382.878-.12.249-.072.687-.2.948-.231.469-1.562 1.87-2.622 2.855-3.826 3.554-5.018 1.644-6.001-.408-.894-1.865-.661-5.127-.874-6.875-.35-2.914-2.622-3.03-1.923-4.429.343-.685 2.87.69 3.263 1.748.757 2.04 2.952 1.807 2.622 1.69`,fill:`#FFC6A0`},null),v(`path`,{d:`M99.8 82.429c-.465.077-.35.272-.97 1.243-.622.971-4.817 2.932-6.39 3.224-2.589.48-2.278-1.56-4.254-2.855-1.69-1.107-3.562-.638-1.398 1.398.99.932.932 1.107 1.398 3.205.335 1.506-.64 3.67.7 5.593`,stroke:`#DB836E`,"stroke-width":`.774`,"stroke-linecap":`round`,"stroke-linejoin":`round`},null),v(`path`,{d:`M79.543 108.673c-2.1 2.926-4.266 6.175-5.557 8.762`,stroke:`#E59788`,"stroke-width":`.774`,"stroke-linecap":`round`,"stroke-linejoin":`round`},null),v(`path`,{d:`M87.72 124.768s-2.098-1.942-5.127-2.719c-3.03-.777-3.574-.155-5.516.078-1.942.233-3.885-.932-3.652.7.233 1.63 5.05 1.01 5.206 2.097.155 1.087-6.37 2.796-8.313 2.175-.777.777.466 1.864 2.02 2.175.233 1.554 2.253 1.554 2.253 1.554s.699 1.01 2.641 1.088c2.486 1.32 8.934-.7 10.954-1.554 2.02-.855-.466-5.594-.466-5.594`,fill:`#FFC6A0`},null),v(`path`,{d:`M73.425 122.826s.66 1.127 3.167 1.418c2.315.27 2.563.583 2.563.583s-2.545 2.894-9.07 2.272M72.416 129.274s3.826.097 4.933-.718M74.98 130.75s1.961.136 3.36-.505M77.232 131.916s1.748.019 2.914-.505M73.328 122.321s-.595-1.032 1.262-.427c1.671.544 2.833.055 5.128.155 1.389.061 3.067-.297 3.982.15 1.606.784 3.632 2.181 3.632 2.181s10.526 1.204 19.033-1.127M78.864 108.104s-8.39 2.758-13.168 12.12`,stroke:`#E59788`,"stroke-width":`.774`,"stroke-linecap":`round`,"stroke-linejoin":`round`},null),v(`path`,{d:`M109.278 112.533s3.38-3.613 7.575-4.662`,stroke:`#E4EBF7`,"stroke-width":`1.085`,"stroke-linecap":`round`,"stroke-linejoin":`round`},null),v(`path`,{d:`M107.375 123.006s9.697-2.745 11.445-.88`,stroke:`#E59788`,"stroke-width":`.774`,"stroke-linecap":`round`,"stroke-linejoin":`round`},null),v(`path`,{d:`M194.605 83.656l3.971-3.886M187.166 90.933l3.736-3.655M191.752 84.207l-4.462-4.56M198.453 91.057l-4.133-4.225M129.256 163.074l3.718-3.718M122.291 170.039l3.498-3.498M126.561 163.626l-4.27-4.27M132.975 170.039l-3.955-3.955`,stroke:`#BFCDDD`,"stroke-width":`2`,"stroke-linecap":`round`,"stroke-linejoin":`round`},null),v(`path`,{d:`M190.156 211.779h-1.604a4.023 4.023 0 0 1-4.011-4.011V175.68a4.023 4.023 0 0 1 4.01-4.01h1.605a4.023 4.023 0 0 1 4.011 4.01v32.088a4.023 4.023 0 0 1-4.01 4.01`,fill:`#A3B4C6`},null),v(`path`,{d:`M237.824 212.977a4.813 4.813 0 0 1-4.813 4.813h-86.636a4.813 4.813 0 0 1 0-9.626h86.636a4.813 4.813 0 0 1 4.813 4.813`,fill:`#A3B4C6`},null),v(`mask`,{fill:`#fff`},null),v(`path`,{fill:`#A3B4C6`,mask:`url(#d)`,d:`M154.098 190.096h70.513v-84.617h-70.513z`},null),v(`path`,{d:`M224.928 190.096H153.78a3.219 3.219 0 0 1-3.208-3.209V167.92a3.219 3.219 0 0 1 3.208-3.21h71.148a3.219 3.219 0 0 1 3.209 3.21v18.967a3.219 3.219 0 0 1-3.21 3.209M224.928 130.832H153.78a3.218 3.218 0 0 1-3.208-3.208v-18.968a3.219 3.219 0 0 1 3.208-3.209h71.148a3.219 3.219 0 0 1 3.209 3.21v18.967a3.218 3.218 0 0 1-3.21 3.208`,fill:`#BFCDDD`,mask:`url(#d)`},null),v(`path`,{d:`M159.563 120.546a2.407 2.407 0 1 1 0-4.813 2.407 2.407 0 0 1 0 4.813M166.98 120.546a2.407 2.407 0 1 1 0-4.813 2.407 2.407 0 0 1 0 4.813M174.397 120.546a2.407 2.407 0 1 1 0-4.813 2.407 2.407 0 0 1 0 4.813M222.539 120.546h-22.461a.802.802 0 0 1-.802-.802v-3.208c0-.443.359-.803.802-.803h22.46c.444 0 .803.36.803.803v3.208c0 .443-.36.802-.802.802`,fill:`#FFF`,mask:`url(#d)`},null),v(`path`,{d:`M224.928 160.464H153.78a3.218 3.218 0 0 1-3.208-3.209v-18.967a3.219 3.219 0 0 1 3.208-3.209h71.148a3.219 3.219 0 0 1 3.209 3.209v18.967a3.218 3.218 0 0 1-3.21 3.209`,fill:`#BFCDDD`,mask:`url(#d)`},null),v(`path`,{d:`M173.455 130.832h49.301M164.984 130.832h6.089M155.952 130.832h6.75M173.837 160.613h49.3M165.365 160.613h6.089M155.57 160.613h6.751`,stroke:`#7C90A5`,"stroke-width":`1.124`,"stroke-linecap":`round`,"stroke-linejoin":`round`,mask:`url(#d)`},null),v(`path`,{d:`M159.563 151.038a2.407 2.407 0 1 1 0-4.814 2.407 2.407 0 0 1 0 4.814M166.98 151.038a2.407 2.407 0 1 1 0-4.814 2.407 2.407 0 0 1 0 4.814M174.397 151.038a2.407 2.407 0 1 1 .001-4.814 2.407 2.407 0 0 1 0 4.814M222.539 151.038h-22.461a.802.802 0 0 1-.802-.802v-3.209c0-.443.359-.802.802-.802h22.46c.444 0 .803.36.803.802v3.209c0 .443-.36.802-.802.802M159.563 179.987a2.407 2.407 0 1 1 0-4.813 2.407 2.407 0 0 1 0 4.813M166.98 179.987a2.407 2.407 0 1 1 0-4.813 2.407 2.407 0 0 1 0 4.813M174.397 179.987a2.407 2.407 0 1 1 0-4.813 2.407 2.407 0 0 1 0 4.813M222.539 179.987h-22.461a.802.802 0 0 1-.802-.802v-3.209c0-.443.359-.802.802-.802h22.46c.444 0 .803.36.803.802v3.209c0 .443-.36.802-.802.802`,fill:`#FFF`,mask:`url(#d)`},null),v(`path`,{d:`M203.04 221.108h-27.372a2.413 2.413 0 0 1-2.406-2.407v-11.448a2.414 2.414 0 0 1 2.406-2.407h27.372a2.414 2.414 0 0 1 2.407 2.407V218.7a2.413 2.413 0 0 1-2.407 2.407`,fill:`#BFCDDD`,mask:`url(#d)`},null),v(`path`,{d:`M177.259 207.217v11.52M201.05 207.217v11.52`,stroke:`#A3B4C6`,"stroke-width":`1.124`,"stroke-linecap":`round`,"stroke-linejoin":`round`,mask:`url(#d)`},null),v(`path`,{d:`M162.873 267.894a9.422 9.422 0 0 1-9.422-9.422v-14.82a9.423 9.423 0 0 1 18.845 0v14.82a9.423 9.423 0 0 1-9.423 9.422`,fill:`#5BA02E`,mask:`url(#d)`},null),v(`path`,{d:`M171.22 267.83a9.422 9.422 0 0 1-9.422-9.423v-3.438a9.423 9.423 0 0 1 18.845 0v3.438a9.423 9.423 0 0 1-9.422 9.423`,fill:`#92C110`,mask:`url(#d)`},null),v(`path`,{d:`M181.31 293.666h-27.712a3.209 3.209 0 0 1-3.209-3.21V269.79a3.209 3.209 0 0 1 3.209-3.21h27.711a3.209 3.209 0 0 1 3.209 3.21v20.668a3.209 3.209 0 0 1-3.209 3.209`,fill:`#F2D7AD`,mask:`url(#d)`},null)])]),H=()=>v(`svg`,{width:`251`,height:`294`},[v(`g`,{fill:`none`,"fill-rule":`evenodd`},[v(`path`,{d:`M0 129.023v-2.084C0 58.364 55.591 2.774 124.165 2.774h2.085c68.574 0 124.165 55.59 124.165 124.165v2.084c0 68.575-55.59 124.166-124.165 124.166h-2.085C55.591 253.189 0 197.598 0 129.023`,fill:`#E4EBF7`},null),v(`path`,{d:`M41.417 132.92a8.231 8.231 0 1 1-16.38-1.65 8.231 8.231 0 0 1 16.38 1.65`,fill:`#FFF`},null),v(`path`,{d:`M38.652 136.36l10.425 5.91M49.989 148.505l-12.58 10.73`,stroke:`#FFF`,"stroke-width":`2`},null),v(`path`,{d:`M41.536 161.28a5.636 5.636 0 1 1-11.216-1.13 5.636 5.636 0 0 1 11.216 1.13M59.154 145.261a5.677 5.677 0 1 1-11.297-1.138 5.677 5.677 0 0 1 11.297 1.138M100.36 29.516l29.66-.013a4.562 4.562 0 1 0-.004-9.126l-29.66.013a4.563 4.563 0 0 0 .005 9.126M111.705 47.754l29.659-.013a4.563 4.563 0 1 0-.004-9.126l-29.66.013a4.563 4.563 0 1 0 .005 9.126`,fill:`#FFF`},null),v(`path`,{d:`M114.066 29.503V29.5l15.698-.007a4.563 4.563 0 1 0 .004 9.126l-15.698.007v-.002a4.562 4.562 0 0 0-.004-9.122M185.405 137.723c-.55 5.455-5.418 9.432-10.873 8.882-5.456-.55-9.432-5.418-8.882-10.873.55-5.455 5.418-9.432 10.873-8.882 5.455.55 9.432 5.418 8.882 10.873`,fill:`#FFF`},null),v(`path`,{d:`M180.17 143.772l12.572 7.129M193.841 158.42L178.67 171.36`,stroke:`#FFF`,"stroke-width":`2`},null),v(`path`,{d:`M185.55 171.926a6.798 6.798 0 1 1-13.528-1.363 6.798 6.798 0 0 1 13.527 1.363M204.12 155.285a6.848 6.848 0 1 1-13.627-1.375 6.848 6.848 0 0 1 13.626 1.375`,fill:`#FFF`},null),v(`path`,{d:`M152.988 194.074a2.21 2.21 0 1 1-4.42 0 2.21 2.21 0 0 1 4.42 0zM225.931 118.217a2.21 2.21 0 1 1-4.421 0 2.21 2.21 0 0 1 4.421 0zM217.09 153.051a2.21 2.21 0 1 1-4.421 0 2.21 2.21 0 0 1 4.42 0zM177.84 109.842a2.21 2.21 0 1 1-4.422 0 2.21 2.21 0 0 1 4.421 0zM196.114 94.454a2.21 2.21 0 1 1-4.421 0 2.21 2.21 0 0 1 4.421 0zM202.844 182.523a2.21 2.21 0 1 1-4.42 0 2.21 2.21 0 0 1 4.42 0z`,stroke:`#FFF`,"stroke-width":`2`},null),v(`path`,{stroke:`#FFF`,"stroke-width":`2`,d:`M215.125 155.262l-1.902 20.075-10.87 5.958M174.601 176.636l-6.322 9.761H156.98l-4.484 6.449M175.874 127.28V111.56M221.51 119.404l-12.77 7.859-15.228-7.86V96.668`},null),v(`path`,{d:`M180.68 29.32C180.68 13.128 193.806 0 210 0c16.193 0 29.32 13.127 29.32 29.32 0 16.194-13.127 29.322-29.32 29.322-16.193 0-29.32-13.128-29.32-29.321`,fill:`#A26EF4`},null),v(`path`,{d:`M221.45 41.706l-21.563-.125a1.744 1.744 0 0 1-1.734-1.754l.071-12.23a1.744 1.744 0 0 1 1.754-1.734l21.562.125c.964.006 1.74.791 1.735 1.755l-.071 12.229a1.744 1.744 0 0 1-1.754 1.734`,fill:`#FFF`},null),v(`path`,{d:`M215.106 29.192c-.015 2.577-2.049 4.654-4.543 4.64-2.494-.014-4.504-2.115-4.489-4.693l.04-6.925c.016-2.577 2.05-4.654 4.543-4.64 2.494.015 4.504 2.116 4.49 4.693l-.04 6.925zm-4.53-14.074a6.877 6.877 0 0 0-6.916 6.837l-.043 7.368a6.877 6.877 0 0 0 13.754.08l.042-7.368a6.878 6.878 0 0 0-6.837-6.917zM167.566 68.367h-3.93a4.73 4.73 0 0 1-4.717-4.717 4.73 4.73 0 0 1 4.717-4.717h3.93a4.73 4.73 0 0 1 4.717 4.717 4.73 4.73 0 0 1-4.717 4.717`,fill:`#FFF`},null),v(`path`,{d:`M168.214 248.838a6.611 6.611 0 0 1-6.61-6.611v-66.108a6.611 6.611 0 0 1 13.221 0v66.108a6.611 6.611 0 0 1-6.61 6.61`,fill:`#5BA02E`},null),v(`path`,{d:`M176.147 248.176a6.611 6.611 0 0 1-6.61-6.61v-33.054a6.611 6.611 0 1 1 13.221 0v33.053a6.611 6.611 0 0 1-6.61 6.611`,fill:`#92C110`},null),v(`path`,{d:`M185.994 293.89h-27.376a3.17 3.17 0 0 1-3.17-3.17v-45.887a3.17 3.17 0 0 1 3.17-3.17h27.376a3.17 3.17 0 0 1 3.17 3.17v45.886a3.17 3.17 0 0 1-3.17 3.17`,fill:`#F2D7AD`},null),v(`path`,{d:`M81.972 147.673s6.377-.927 17.566-1.28c11.729-.371 17.57 1.086 17.57 1.086s3.697-3.855.968-8.424c1.278-12.077 5.982-32.827.335-48.273-1.116-1.339-3.743-1.512-7.536-.62-1.337.315-7.147-.149-7.983-.1l-15.311-.347s-3.487-.17-8.035-.508c-1.512-.113-4.227-1.683-5.458-.338-.406.443-2.425 5.669-1.97 16.077l8.635 35.642s-3.141 3.61 1.219 7.085`,fill:`#FFF`},null),v(`path`,{d:`M75.768 73.325l-.9-6.397 11.982-6.52s7.302-.118 8.038 1.205c.737 1.324-5.616.993-5.616.993s-1.836 1.388-2.615 2.5c-1.654 2.363-.986 6.471-8.318 5.986-1.708.284-2.57 2.233-2.57 2.233`,fill:`#FFC6A0`},null),v(`path`,{d:`M52.44 77.672s14.217 9.406 24.973 14.444c1.061.497-2.094 16.183-11.892 11.811-7.436-3.318-20.162-8.44-21.482-14.496-.71-3.258 2.543-7.643 8.401-11.76M141.862 80.113s-6.693 2.999-13.844 6.876c-3.894 2.11-10.137 4.704-12.33 7.988-6.224 9.314 3.536 11.22 12.947 7.503 6.71-2.651 28.999-12.127 13.227-22.367`,fill:`#FFB594`},null),v(`path`,{d:`M76.166 66.36l3.06 3.881s-2.783 2.67-6.31 5.747c-7.103 6.195-12.803 14.296-15.995 16.44-3.966 2.662-9.754 3.314-12.177-.118-3.553-5.032.464-14.628 31.422-25.95`,fill:`#FFC6A0`},null),v(`path`,{d:`M64.674 85.116s-2.34 8.413-8.912 14.447c.652.548 18.586 10.51 22.144 10.056 5.238-.669 6.417-18.968 1.145-20.531-.702-.208-5.901-1.286-8.853-2.167-.87-.26-1.611-1.71-3.545-.936l-1.98-.869zM128.362 85.826s5.318 1.956 7.325 13.734c-.546.274-17.55 12.35-21.829 7.805-6.534-6.94-.766-17.393 4.275-18.61 4.646-1.121 5.03-1.37 10.23-2.929`,fill:`#FFF`},null),v(`path`,{d:`M78.18 94.656s.911 7.41-4.914 13.078`,stroke:`#E4EBF7`,"stroke-width":`1.051`,"stroke-linecap":`round`,"stroke-linejoin":`round`},null),v(`path`,{d:`M87.397 94.68s3.124 2.572 10.263 2.572c7.14 0 9.074-3.437 9.074-3.437`,stroke:`#E4EBF7`,"stroke-width":`.932`,"stroke-linecap":`round`,"stroke-linejoin":`round`},null),v(`path`,{d:`M117.184 68.639l-6.781-6.177s-5.355-4.314-9.223-.893c-3.867 3.422 4.463 2.083 5.653 4.165 1.19 2.082.848 1.143-2.083.446-5.603-1.331-2.082.893 2.975 5.355 2.091 1.845 6.992.955 6.992.955l2.467-3.851z`,fill:`#FFC6A0`},null),v(`path`,{d:`M105.282 91.315l-.297-10.937-15.918-.027-.53 10.45c-.026.403.17.788.515.999 2.049 1.251 9.387 5.093 15.799.424.287-.21.443-.554.431-.91`,fill:`#FFB594`},null),v(`path`,{d:`M107.573 74.24c.817-1.147.982-9.118 1.015-11.928a1.046 1.046 0 0 0-.965-1.055l-4.62-.365c-7.71-1.044-17.071.624-18.253 6.346-5.482 5.813-.421 13.244-.421 13.244s1.963 3.566 4.305 6.791c.756 1.041.398-3.731 3.04-5.929 5.524-4.594 15.899-7.103 15.899-7.103`,fill:`#5C2552`},null),v(`path`,{d:`M88.426 83.206s2.685 6.202 11.602 6.522c7.82.28 8.973-7.008 7.434-17.505l-.909-5.483c-6.118-2.897-15.478.54-15.478.54s-.576 2.044-.19 5.504c-2.276 2.066-1.824 5.618-1.824 5.618s-.905-1.922-1.98-2.321c-.86-.32-1.897.089-2.322 1.98-1.04 4.632 3.667 5.145 3.667 5.145`,fill:`#FFC6A0`},null),v(`path`,{stroke:`#DB836E`,"stroke-width":`1.145`,"stroke-linecap":`round`,"stroke-linejoin":`round`,d:`M100.843 77.099l1.701-.928-1.015-4.324.674-1.406`},null),v(`path`,{d:`M105.546 74.092c-.022.713-.452 1.279-.96 1.263-.51-.016-.904-.607-.882-1.32.021-.713.452-1.278.96-1.263.51.016.904.607.882 1.32M97.592 74.349c-.022.713-.452 1.278-.961 1.263-.509-.016-.904-.607-.882-1.32.022-.713.452-1.279.961-1.263.51.016.904.606.882 1.32`,fill:`#552950`},null),v(`path`,{d:`M91.132 86.786s5.269 4.957 12.679 2.327`,stroke:`#DB836E`,"stroke-width":`1.145`,"stroke-linecap":`round`,"stroke-linejoin":`round`},null),v(`path`,{d:`M99.776 81.903s-3.592.232-1.44-2.79c1.59-1.496 4.897-.46 4.897-.46s1.156 3.906-3.457 3.25`,fill:`#DB836E`},null),v(`path`,{d:`M102.88 70.6s2.483.84 3.402.715M93.883 71.975s2.492-1.144 4.778-1.073`,stroke:`#5C2552`,"stroke-width":`1.526`,"stroke-linecap":`round`,"stroke-linejoin":`round`},null),v(`path`,{d:`M86.32 77.374s.961.879 1.458 2.106c-.377.48-1.033 1.152-.236 1.809M99.337 83.719s1.911.151 2.509-.254`,stroke:`#DB836E`,"stroke-width":`1.145`,"stroke-linecap":`round`,"stroke-linejoin":`round`},null),v(`path`,{d:`M87.782 115.821l15.73-3.012M100.165 115.821l10.04-2.008`,stroke:`#E4EBF7`,"stroke-width":`1.051`,"stroke-linecap":`round`,"stroke-linejoin":`round`},null),v(`path`,{d:`M66.508 86.763s-1.598 8.83-6.697 14.078`,stroke:`#E4EBF7`,"stroke-width":`1.114`,"stroke-linecap":`round`,"stroke-linejoin":`round`},null),v(`path`,{d:`M128.31 87.934s3.013 4.121 4.06 11.785`,stroke:`#E4EBF7`,"stroke-width":`1.051`,"stroke-linecap":`round`,"stroke-linejoin":`round`},null),v(`path`,{d:`M64.09 84.816s-6.03 9.912-13.607 9.903`,stroke:`#DB836E`,"stroke-width":`.795`,"stroke-linecap":`round`,"stroke-linejoin":`round`},null),v(`path`,{d:`M112.366 65.909l-.142 5.32s5.993 4.472 11.945 9.202c4.482 3.562 8.888 7.455 10.985 8.662 4.804 2.766 8.9 3.355 11.076 1.808 4.071-2.894 4.373-9.878-8.136-15.263-4.271-1.838-16.144-6.36-25.728-9.73`,fill:`#FFC6A0`},null),v(`path`,{d:`M130.532 85.488s4.588 5.757 11.619 6.214`,stroke:`#DB836E`,"stroke-width":`.75`,"stroke-linecap":`round`,"stroke-linejoin":`round`},null),v(`path`,{d:`M121.708 105.73s-.393 8.564-1.34 13.612`,stroke:`#E4EBF7`,"stroke-width":`1.051`,"stroke-linecap":`round`,"stroke-linejoin":`round`},null),v(`path`,{d:`M115.784 161.512s-3.57-1.488-2.678-7.14`,stroke:`#648BD8`,"stroke-width":`1.051`,"stroke-linecap":`round`,"stroke-linejoin":`round`},null),v(`path`,{d:`M101.52 290.246s4.326 2.057 7.408 1.03c2.842-.948 4.564.673 7.132 1.186 2.57.514 6.925 1.108 11.772-1.269-.104-5.551-6.939-4.01-12.048-6.763-2.582-1.39-3.812-4.757-3.625-8.863h-9.471s-1.402 10.596-1.169 14.68`,fill:`#CBD1D1`},null),v(`path`,{d:`M101.496 290.073s2.447 1.281 6.809.658c3.081-.44 3.74.485 7.479 1.039 3.739.554 10.802-.07 11.91-.9.415 1.108-.347 2.077-.347 2.077s-1.523.608-4.847.831c-2.045.137-5.843.293-7.663-.507-1.8-1.385-5.286-1.917-5.77-.243-3.947.958-7.41-.288-7.41-.288l-.16-2.667z`,fill:`#2B0849`},null),v(`path`,{d:`M108.824 276.19h3.116s-.103 6.751 4.57 8.62c-4.673.624-8.62-2.32-7.686-8.62`,fill:`#A4AABA`},null),v(`path`,{d:`M57.65 272.52s-2.122 7.47-4.518 12.396c-1.811 3.724-4.255 7.548 5.505 7.548 6.698 0 9.02-.483 7.479-6.648-1.541-6.164.268-13.296.268-13.296H57.65z`,fill:`#CBD1D1`},null),v(`path`,{d:`M51.54 290.04s2.111 1.178 6.682 1.178c6.128 0 8.31-1.662 8.31-1.662s.605 1.122-.624 2.18c-1 .862-3.624 1.603-7.444 1.559-4.177-.049-5.876-.57-6.786-1.177-.831-.554-.692-1.593-.138-2.078`,fill:`#2B0849`},null),v(`path`,{d:`M58.533 274.438s.034 1.529-.315 2.95c-.352 1.431-1.087 3.127-1.139 4.17-.058 1.16 4.57 1.592 5.194.035.623-1.559 1.303-6.475 1.927-7.306.622-.831-4.94-2.135-5.667.15`,fill:`#A4AABA`},null),v(`path`,{d:`M100.885 277.015l13.306.092s1.291-54.228 1.843-64.056c.552-9.828 3.756-43.13.997-62.788l-12.48-.64-22.725.776s-.433 3.944-1.19 9.921c-.062.493-.677.838-.744 1.358-.075.582.42 1.347.318 1.956-2.35 14.003-6.343 32.926-8.697 46.425-.116.663-1.227 1.004-1.45 2.677-.04.3.21 1.516.112 1.785-6.836 18.643-10.89 47.584-14.2 61.551l14.528-.014s2.185-8.524 4.008-16.878c2.796-12.817 22.987-84.553 22.987-84.553l3-.517 1.037 46.1s-.223 1.228.334 2.008c.558.782-.556 1.117-.39 2.233l.39 1.784s-.446 7.14-.892 11.826c-.446 4.685-.092 38.954-.092 38.954`,fill:`#7BB2F9`},null),v(`path`,{d:`M77.438 220.434c1.146.094 4.016-2.008 6.916-4.91M107.55 223.931s2.758-1.103 6.069-3.862`,stroke:`#648BD8`,"stroke-width":`1.051`,"stroke-linecap":`round`,"stroke-linejoin":`round`},null),v(`path`,{d:`M108.459 220.905s2.759-1.104 6.07-3.863`,stroke:`#648BD8`,"stroke-linecap":`round`,"stroke-linejoin":`round`},null),v(`path`,{d:`M76.099 223.557s2.608-.587 6.47-3.346M87.33 150.82c-.27 3.088.297 8.478-4.315 9.073M104.829 149.075s.11 13.936-1.286 14.983c-2.207 1.655-2.975 1.934-2.975 1.934M101.014 149.63s.035 12.81-1.19 24.245M94.93 174.965s7.174-1.655 9.38-1.655M75.671 204.754c-.316 1.55-.64 3.067-.973 4.535 0 0-1.45 1.822-1.003 3.756.446 1.934-.943 2.034-4.96 15.273-1.686 5.559-4.464 18.49-6.313 27.447-.078.38-4.018 18.06-4.093 18.423M77.043 196.743a313.269 313.269 0 0 1-.877 4.729M83.908 151.414l-1.19 10.413s-1.091.148-.496 2.23c.111 1.34-2.66 15.692-5.153 30.267M57.58 272.94h13.238`,stroke:`#648BD8`,"stroke-width":`1.051`,"stroke-linecap":`round`,"stroke-linejoin":`round`},null),v(`path`,{d:`M117.377 147.423s-16.955-3.087-35.7.199c.157 2.501-.002 4.128-.002 4.128s14.607-2.802 35.476-.31c.251-2.342.226-4.017.226-4.017`,fill:`#192064`},null),v(`path`,{d:`M107.511 150.353l.004-4.885a.807.807 0 0 0-.774-.81c-2.428-.092-5.04-.108-7.795-.014a.814.814 0 0 0-.784.81l-.003 4.88c0 .456.371.82.827.808a140.76 140.76 0 0 1 7.688.017.81.81 0 0 0 .837-.806`,fill:`#FFF`},null),v(`path`,{d:`M106.402 149.426l.002-3.06a.64.64 0 0 0-.616-.643 94.135 94.135 0 0 0-5.834-.009.647.647 0 0 0-.626.643l-.001 3.056c0 .36.291.648.651.64 1.78-.04 3.708-.041 5.762.012.36.009.662-.279.662-.64`,fill:`#192064`},null),v(`path`,{d:`M101.485 273.933h12.272M102.652 269.075c.006 3.368.04 5.759.11 6.47M102.667 263.125c-.009 1.53-.015 2.98-.016 4.313M102.204 174.024l.893 44.402s.669 1.561-.224 2.677c-.892 1.116 2.455.67.893 2.231-1.562 1.562.893 1.116 0 3.347-.592 1.48-.988 20.987-1.09 34.956`,stroke:`#648BD8`,"stroke-width":`1.051`,"stroke-linecap":`round`,"stroke-linejoin":`round`},null)])]),U=e=>{let{componentCls:t,lineHeightHeading3:n,iconCls:r,padding:i,paddingXL:a,paddingXS:o,paddingLG:s,marginXS:c,lineHeight:l}=e;return{[t]:{padding:`${s*2}px ${a}px`,"&-rtl":{direction:`rtl`}},[`${t} ${t}-image`]:{width:e.imageWidth,height:e.imageHeight,margin:`auto`},[`${t} ${t}-icon`]:{marginBottom:s,textAlign:`center`,[`& > ${r}`]:{fontSize:e.resultIconFontSize}},[`${t} ${t}-title`]:{color:e.colorTextHeading,fontSize:e.resultTitleFontSize,lineHeight:n,marginBlock:c,textAlign:`center`},[`${t} ${t}-subtitle`]:{color:e.colorTextDescription,fontSize:e.resultSubtitleFontSize,lineHeight:l,textAlign:`center`},[`${t} ${t}-content`]:{marginTop:s,padding:`${s}px ${i*2.5}px`,backgroundColor:e.colorFillAlter},[`${t} ${t}-extra`]:{margin:e.resultExtraMargin,textAlign:`center`,"& > *":{marginInlineEnd:o,"&:last-child":{marginInlineEnd:0}}}}},W=e=>{let{componentCls:t,iconCls:n}=e;return{[`${t}-success ${t}-icon > ${n}`]:{color:e.resultSuccessIconColor},[`${t}-error ${t}-icon > ${n}`]:{color:e.resultErrorIconColor},[`${t}-info ${t}-icon > ${n}`]:{color:e.resultInfoIconColor},[`${t}-warning ${t}-icon > ${n}`]:{color:e.resultWarningIconColor}}},G=e=>[U(e),W(e)],K=e=>G(e),q=D(`Result`,e=>{let{paddingLG:t,fontSizeHeading3:n}=e,r=e.fontSize,i=`${t}px 0 0 0`,a=e.colorInfo,o=e.colorError,s=e.colorSuccess,c=e.colorWarning;return[K(A(e,{resultTitleFontSize:n,resultSubtitleFontSize:r,resultIconFontSize:n*3,resultExtraMargin:i,resultInfoIconColor:a,resultErrorIconColor:o,resultSuccessIconColor:s,resultWarningIconColor:c}))]},{imageWidth:250,imageHeight:295}),J={success:F,error:j,info:N,warning:z},Y={404:B,500:V,403:H},X=Object.keys(Y),Z=()=>({prefixCls:String,icon:k.any,status:{type:[Number,String],default:`info`},title:k.any,subTitle:k.any,extra:k.any}),Q=(e,t)=>{let{status:n,icon:r}=t;if(X.includes(`${n}`)){let t=Y[n];return v(`div`,{class:`${e}-icon ${e}-image`},[v(t,null,null)])}let i=J[n],a=r||v(i,null,null);return v(`div`,{class:`${e}-icon`},[a])},ue=(e,t)=>t&&v(`div`,{class:`${e}-extra`},[t]),$=e({compatConfig:{MODE:3},name:`AResult`,inheritAttrs:!1,props:Z(),slots:Object,setup(e,t){let{slots:n,attrs:r}=t,{prefixCls:i,direction:a}=O(`result`,e),[o,s]=q(i),c=l(()=>E(i.value,s.value,`${i.value}-${e.status}`,{[`${i.value}-rtl`]:a.value===`rtl`}));return()=>{let t=e.title??n.title?.call(n),a=e.subTitle??n.subTitle?.call(n),s=e.icon??n.icon?.call(n),l=e.extra??n.extra?.call(n),u=i.value;return o(v(`div`,T(T({},r),{},{class:[c.value,r.class]}),[Q(u,{status:e.status,icon:s}),v(`div`,{class:`${u}-title`},[t]),a&&v(`div`,{class:`${u}-subtitle`},[a]),ue(u,l),n.default&&v(`div`,{class:`${u}-content`},[n.default()])]))}}});$.PRESENTED_IMAGE_403=Y[403],$.PRESENTED_IMAGE_404=Y[404],$.PRESENTED_IMAGE_500=Y[500],$.install=function(e){return e.component($.name,$),e};var de={class:`monitor`},fe={class:`aw-page-head`},pe={class:`aw-kicker`},me={class:`head-right`},he={class:`toggle-label`},ge={class:`stat-grid`},_e={class:`stat-label`},ve={class:`stat-value aw-mono`},ye={class:`stat-label`},be={class:`stat-value aw-mono`},xe={class:`stat-label`},Se={class:`stat-value aw-mono`},Ce={key:0,class:`orphan-badge`},we={class:`stat-label`},Te={class:`stat-value aw-mono small`},Ee={class:`stat-updated`},De={class:`aw-mono count-extra`},Oe={key:0,class:`aw-mono`},ke={key:2,class:`aw-mono`},Ae={class:`aw-mono count-extra`},je={key:3,class:`aw-mono`},Me={key:4,class:`aw-mono`},Ne={key:0},Pe={key:1,class:`aw-mono`},Fe={class:`aw-mono count-extra`},Ie={key:0,class:`aw-mono`},Le={key:0,class:`aw-mono agent-sub`},Re={key:0},ze={key:1},Be={key:4,class:`aw-mono small`},Ve={key:5,class:`aw-mono small`},He=_(e({__name:`monitor`,setup(e){ce({layout:`default`});let{t:_}=C(),T=x(),E=se(),D=l(()=>E.isAdmin),O=m(null),k=m(!1),A=m(!0),j=m(``),M=async()=>{if(E.token){k.value=!0;try{let e=await S(`/api/system/monitor`,{headers:{authorization:`Bearer ${E.token}`}});O.value=e.data,j.value=new Date().toLocaleTimeString()}catch(e){P.error(e instanceof Error?e.message:_(`monitor.loadFailed`))}finally{k.value=!1}}},N=null,F=()=>{N&&=(clearInterval(N),null),A.value&&E.token&&(N=w(()=>void M(),5e3))};c(A,()=>F()),c(()=>E.token,()=>{E.token?M():O.value=null,F()}),y(()=>{E.token&&M().then(()=>U()),F()}),t(()=>{N&&clearInterval(N)});let I=m(!1),L=async e=>{I.value=!0;try{let t=await S(`/api/system/monitor/terminate`,{method:`POST`,headers:{authorization:`Bearer ${E.token}`},body:{channelId:e.channelId,agentId:e.agentId}});P.success(t.code===0?`${e.name} ${_(`monitor.terminated`)}`:t.message??_(`monitor.failed`)),await M()}catch(e){P.error(e instanceof Error?e.message:_(`monitor.failed`))}finally{I.value=!1}},R=async e=>{I.value=!0;try{let t=await S(`/api/system/monitor/terminate`,{method:`POST`,headers:{authorization:`Bearer ${E.token}`},body:{pid:e.pid}});P.success(t.code===0?`PID ${e.pid} ${_(`monitor.terminated`)}`:t.message??_(`monitor.failed`)),await M()}catch(e){P.error(e instanceof Error?e.message:_(`monitor.failed`))}finally{I.value=!1}},z=m(!1),B=m(null),V=m(``),H=(e,t,n)=>{B.value=e,V.value=[t,n].filter(Boolean).join(` · `)||`omp harness`,z.value=!0},U=()=>{let e=T.query.agentId;if(typeof e!=`string`||!e)return;let t=typeof T.query.channelId==`string`?T.query.channelId:``,n=O.value?.processes.find(n=>n.agentId===e&&(!t||n.channelId===t));n?.pid&&(H(n.pid,n.name,n.role),b({path:`/monitor`},{replace:!0}))},W=e=>e&&e.length>8?`${e.slice(0,8)}…`:e??`-`,G={idle:`success`,busy:`processing`,stopped:`error`},K={idle:_(`monitor.stateIdle`),busy:_(`monitor.stateBusy`),stopped:_(`monitor.stateStopped`)},q=e=>{let t=Math.floor(e/1e3),n=Math.floor(t/3600),r=Math.floor(t%3600/60),i=t%60;return n>0?`${n}h ${r}m`:r>0?`${r}m ${i}s`:`${i}s`},J=e=>new Date(e).toLocaleTimeString(),Y=l(()=>D.value?[{title:_(`monitor.k1dg9sr8001`),dataIndex:`ownerName`,key:`ownerName`,width:110}]:[]),X=l(()=>[{title:_(`monitor.chChannel`),dataIndex:`channelId`,key:`channelId`},{title:_(`monitor.members`),dataIndex:`memberCount`,key:`memberCount`,width:100},{title:_(`monitor.wired`),dataIndex:`wiredAgentCount`,key:`wiredAgentCount`,width:90},{title:_(`monitor.scheduler`),dataIndex:`hasScheduler`,key:`hasScheduler`,width:110},{title:_(`monitor.lead`),dataIndex:`leadAgentId`,key:`leadAgentId`},...Y.value]),Z=l(()=>[{title:_(`monitor.name`),dataIndex:`name`,key:`name`},{title:_(`monitor.role`),dataIndex:`role`,key:`role`,width:90},{title:_(`monitor.harness`),dataIndex:`harness`,key:`harness`,width:90},{title:_(`monitor.state`),dataIndex:`state`,key:`state`,width:110},{title:_(`monitor.currentTask`),dataIndex:`currentTaskId`,key:`currentTaskId`},{title:_(`monitor.queue`),dataIndex:`queuedCount`,key:`queuedCount`,width:90},{title:`PID`,dataIndex:`process`,key:`pid`,width:130},{title:_(`monitor.channel`),dataIndex:`channelId`,key:`channelId`,width:130},...Y.value,{title:_(`monitor.actions`),key:`actions`,width:190,fixed:`right`}]),Q=l(()=>[{title:`PID`,dataIndex:`pid`,key:`pid`,width:100},{title:_(`monitor.binding`),dataIndex:`bound`,key:`bound`,width:100},{title:_(`monitor.agent`),dataIndex:`name`,key:`name`},{title:_(`monitor.role`),dataIndex:`role`,key:`role`,width:90},{title:_(`monitor.command`),dataIndex:`command`,key:`command`},{title:_(`monitor.startedAt`),dataIndex:`startedAt`,key:`startedAt`,width:110},{title:_(`monitor.state`),dataIndex:`alive`,key:`alive`,width:100},...Y.value,{title:_(`monitor.actions`),key:`actions`,width:170,fixed:`right`}]);return(e,t)=>{let c=ne,l=oe,m=ee,y=$,x=ie,S=te,C=re,w=ae;return n(),u(`div`,de,[g(`div`,fe,[g(`div`,null,[g(`p`,pe,a(i(_)(`menu.system`))+` / runtime ledger `,1),g(`h1`,null,[s(a(i(_)(`monitor.title`))+` `,1),v(c,{color:i(O)?.scope===`admin`?`volcano`:`blue`,class:`scope-tag`},{default:h(()=>[g(`span`,{class:r(i(O)?.scope===`admin`?`i-tabler-shield-check`:`i-tabler-user`)},null,2),s(` `+a(i(O)?.scope===`admin`?e.$t(`monitor.k16zpmg9002`):e.$t(`monitor.k1dzryry003`)),1)]),_:1},8,[`color`])])]),g(`div`,me,[v(l,{checked:i(A),"onUpdate:checked":t[0]||=e=>f(A)?A.value=e:null,size:`small`},null,8,[`checked`]),g(`span`,he,a(i(_)(`monitor.autoRefresh`)),1),v(m,{size:`small`,loading:i(k),onClick:M},{icon:h(()=>[...t[3]||=[g(`span`,{class:`i-tabler-refresh`},null,-1)]]),default:h(()=>[s(` `+a(i(_)(`monitor.refresh`)),1)]),_:1},8,[`loading`])])]),i(E).token?(n(),u(o,{key:1},[g(`div`,ge,[v(x,{class:`aw-panel stat`},{default:h(()=>[g(`p`,_e,a(i(_)(`monitor.channels`)),1),g(`p`,ve,a(i(O)?.counts.channels??`–`),1)]),_:1}),v(x,{class:`aw-panel stat`},{default:h(()=>[g(`p`,ye,a(i(_)(`monitor.agents`)),1),g(`p`,be,a(i(O)?.counts.agents??`–`),1)]),_:1}),v(x,{class:`aw-panel stat`},{default:h(()=>[g(`p`,xe,a(i(_)(`monitor.aliveProcesses`)),1),g(`p`,Se,[s(a(i(O)?.counts.aliveProcesses??`–`)+` `,1),(i(O)?.counts.orphanProcesses??0)>0?(n(),u(`span`,Ce,` +`+a(i(O)?.counts.orphanProcesses)+` `+a(i(_)(`monitor.orphan`)),1)):d(``,!0)])]),_:1}),v(x,{class:`aw-panel stat`},{default:h(()=>[g(`p`,we,a(i(_)(`monitor.server`)),1),g(`p`,Te,` PID `+a(i(O)?.serverPid??`–`)+` · `+a(i(O)?q(i(O).uptimeMs):``),1),g(`p`,Ee,a(i(j))+` · `+a(i(_)(`monitor.updated`))+` `+a(i(O)?.generatedAt??``),1)]),_:1})]),v(x,{class:`aw-panel`,title:i(_)(`monitor.channelRuntimes`)},{extra:h(()=>[g(`span`,De,a(i(O)?.channels.length??0)+` wired`,1)]),default:h(()=>[v(S,{columns:i(X),"data-source":i(O)?.channels??[],pagination:!1,loading:i(k),"row-key":`channelId`,size:`small`,scroll:{x:720}},{bodyCell:h(({column:e,record:r})=>[e.key===`channelId`?(n(),u(`span`,Oe,a(W(r.channelId)),1)):e.key===`hasScheduler`?(n(),u(o,{key:1},[r.hasScheduler?(n(),p(c,{key:0,color:`purple`},{default:h(()=>[s(a(i(_)(`monitor.scheduling`)),1)]),_:1})):(n(),p(c,{key:1},{default:h(()=>[...t[4]||=[s(` – `,-1)]]),_:1}))],64)):e.key===`leadAgentId`?(n(),u(`span`,ke,a(W(r.leadAgentId)),1)):d(``,!0)]),_:1},8,[`columns`,`data-source`,`loading`])]),_:1},8,[`title`]),v(x,{class:`aw-panel`,title:i(_)(`monitor.agentRuntimes`)},{extra:h(()=>[g(`span`,Ae,a(i(O)?.agents.length??0)+` wired`,1)]),default:h(()=>[v(S,{columns:i(Z),"data-source":i(O)?.agents??[],pagination:!1,loading:i(k),"row-key":`agentId`,size:`small`,scroll:{x:980}},{bodyCell:h(({column:e,record:r})=>[e.key===`role`?(n(),p(c,{key:0,color:r.role===`lead`?`gold`:`blue`},{default:h(()=>[s(a(r.role),1)]),_:2},1032,[`color`])):e.key===`harness`?(n(),p(c,{key:1},{default:h(()=>[s(a(r.harness),1)]),_:2},1024)):e.key===`state`?(n(),p(c,{key:2,color:G[r.state]??`default`},{default:h(()=>[s(a(K[r.state]??r.state),1)]),_:2},1032,[`color`])):e.key===`currentTaskId`?(n(),u(`span`,je,a(W(r.currentTaskId)),1)):e.key===`channelId`?(n(),u(`span`,Me,a(W(r.channelId)),1)):e.key===`pid`?(n(),u(o,{key:5},[r.process?(n(),u(`span`,Ne,[v(c,{color:r.process.alive?`success`:`default`,class:`aw-mono`},{default:h(()=>[s(` PID `+a(r.process.pid),1)]),_:2},1032,[`color`])])):(n(),u(`span`,Pe,`in-proc`))],64)):e.key===`actions`?(n(),p(w,{key:6,size:4},{default:h(()=>[r.process?.alive?(n(),p(m,{key:0,size:`small`,type:`primary`,ghost:``,title:i(_)(`monitor.openTerminalHint`),onClick:e=>H(r.process.pid,r.name,r.role)},{icon:h(()=>[...t[5]||=[g(`span`,{class:`i-tabler-terminal-2`},null,-1)]]),default:h(()=>[s(` `+a(i(_)(`monitor.openTerminal`)),1)]),_:1},8,[`title`,`onClick`])):d(``,!0),v(C,{title:`${i(_)(`monitor.terminateConfirm`)}(${r.name})`,"ok-text":i(_)(`common.confirm`),"cancel-text":i(_)(`common.cancel`),onConfirm:e=>L(r)},{default:h(()=>[v(m,{size:`small`,danger:``,disabled:i(I)},{icon:h(()=>[...t[6]||=[g(`span`,{class:`i-tabler-square-x`},null,-1)]]),default:h(()=>[s(` `+a(i(_)(`monitor.terminate`)),1)]),_:1},8,[`disabled`])]),_:1},8,[`title`,`ok-text`,`cancel-text`,`onConfirm`])]),_:2},1024)):d(``,!0)]),_:1},8,[`columns`,`data-source`,`loading`])]),_:1},8,[`title`]),v(x,{class:`aw-panel`,title:i(_)(`monitor.harnessProcesses`)},{extra:h(()=>[g(`span`,Fe,a(i(O)?.processes.length??0)+` spawned · `+a(i(O)?.counts.orphanProcesses??0)+` orphan `,1)]),default:h(()=>[v(S,{columns:i(Q),"data-source":i(O)?.processes??[],pagination:!1,loading:i(k),"row-key":`pid`,size:`small`,scroll:{x:900}},{bodyCell:h(({column:e,record:r})=>[e.key===`pid`?(n(),u(`span`,Ie,a(r.pid),1)):e.key===`bound`?(n(),p(c,{key:1,color:r.bound?`success`:`warning`},{default:h(()=>[s(a(r.bound?i(_)(`monitor.bound`):i(_)(`monitor.orphan`)),1)]),_:2},1032,[`color`])):e.key===`name`?(n(),u(o,{key:2},[g(`span`,null,a(r.name??`–`),1),r.agentId?(n(),u(`span`,Le,a(W(r.agentId)),1)):d(``,!0)],64)):e.key===`role`?(n(),u(o,{key:3},[r.role?(n(),u(`span`,Re,a(r.role),1)):(n(),u(`span`,ze,`–`))],64)):e.key===`command`?(n(),u(`span`,Be,a(r.command),1)):e.key===`startedAt`?(n(),u(`span`,Ve,a(J(r.startedAt)),1)):e.key===`alive`?(n(),p(c,{key:6,color:r.alive?`success`:`error`},{default:h(()=>[s(a(r.alive?i(_)(`monitor.alive`):`${i(_)(`monitor.exited`)} ${r.exitCode??``}`),1)]),_:2},1032,[`color`])):e.key===`actions`?(n(),p(w,{key:7,size:4},{default:h(()=>[r.terminal?(n(),p(m,{key:0,size:`small`,type:`primary`,ghost:``,title:i(_)(`monitor.openTerminalHint`),onClick:e=>H(r.pid,r.name,r.role)},{icon:h(()=>[...t[7]||=[g(`span`,{class:`i-tabler-terminal-2`},null,-1)]]),default:h(()=>[s(` `+a(i(_)(`monitor.openTerminal`)),1)]),_:1},8,[`title`,`onClick`])):d(``,!0),v(C,{title:i(_)(`monitor.terminatePidConfirm`),"ok-text":i(_)(`common.confirm`),"cancel-text":i(_)(`common.cancel`),onConfirm:e=>R(r)},{default:h(()=>[v(m,{size:`small`,danger:``,disabled:i(I)||!r.alive},{icon:h(()=>[...t[8]||=[g(`span`,{class:`i-tabler-square-x`},null,-1)]]),default:h(()=>[s(` `+a(i(_)(`monitor.terminate`)),1)]),_:1},8,[`disabled`])]),_:2},1032,[`title`,`ok-text`,`cancel-text`,`onConfirm`])]),_:2},1024)):d(``,!0)]),_:1},8,[`columns`,`data-source`,`loading`])]),_:1},8,[`title`]),v(le,{open:i(z),"onUpdate:open":t[2]||=e=>f(z)?z.value=e:null,pid:i(B),subtitle:i(V)},null,8,[`open`,`pid`,`subtitle`])],64)):(n(),p(x,{key:0,class:`aw-panel`},{default:h(()=>[v(y,{title:i(_)(`monitor.needLogin`)},{extra:h(()=>[v(m,{type:`primary`,onClick:t[1]||=t=>(`navigateTo`in e?e.navigateTo:i(b))(`/workshop`)},{default:h(()=>[s(a(i(_)(`monitor.goLogin`)),1)]),_:1})]),_:1},8,[`title`])]),_:1}))])}}}),[[`__scopeId`,`data-v-d899c904`]]);export{He as default};
@@ -0,0 +1 @@
1
+ import{G as e,I as t,K as n,L as r,q as i}from"./rqZ-1SoP.js";import{C as a,F as o,G as s,H as c,Ht as l,K as u,O as d,St as f,U as p,Ut as m,Wt as h,a as g,b as _,et as v,f as y,g as b,gt as x,h as S,m as C,mt as w,nt as T,p as E,rt as D,t as O,x as k,y as A,z as j}from"./BSCpFtzG.js";import{d as M,p as N}from"./-6OnbLFb.js";import{i as ee}from"./C3tCneTM.js";import{n as te,r as ne,t as re}from"./Cz9gD2Yo.js";import{n as ie}from"./BeIfu4N3.js";import{t as ae}from"./DpojD719.js";import{At as oe,Ct as P,d as se,kt as F,n as I,nt as L,t as R,u as z}from"./BDUjyaF4.js";import{i as ce}from"./DtBu71ev.js";import{t as B}from"./BfGc7TJp.js";import{t as le}from"./VLI2Zy4t.js";import{t as ue}from"./BN_PdN3J.js";import{h as V,r as de}from"./D-Ca4BGY.js";import{a as H,i as fe,n as pe,r as me,t as he}from"./CKfhtOt7.js";import{t as U}from"./lO5tpDZ5.js";import{n as W}from"./D1z7i2UP.js";import{t as G}from"./B7wL3pDk.js";import{t as ge}from"./Dy-mxvXY2.js";import{t as _e}from"./BSSUlJnx2.js";import{t as ve}from"./BcrN7QEl2.js";import{t as ye}from"./C4OAdbVK2.js";import{t as be}from"./G0qIw7Gq2.js";import{m as xe,p as Se,t as Ce}from"./arUY5dyq2.js";import{t as we}from"./CucID8qg2.js";var K=e=>{let{componentCls:t,colorBgContainer:n,colorBgBody:r,colorText:i}=e;return{[`${t}-sider-light`]:{background:n,[`${t}-sider-trigger`]:{color:i,background:n},[`${t}-sider-zero-width-trigger`]:{color:i,background:n,border:`1px solid ${r}`,borderInlineStart:0}}}},Te=e=>{let{antCls:t,componentCls:n,colorText:r,colorTextLightSolid:i,colorBgHeader:a,colorBgBody:o,colorBgTrigger:s,layoutHeaderHeight:c,layoutHeaderPaddingInline:l,layoutHeaderColor:u,layoutFooterPadding:d,layoutTriggerHeight:f,layoutZeroTriggerSize:p,motionDurationMid:m,motionDurationSlow:h,fontSize:g,borderRadius:_}=e;return{[n]:F(F({display:`flex`,flex:`auto`,flexDirection:`column`,color:r,minHeight:0,background:o,"&, *":{boxSizing:`border-box`},[`&${n}-has-sider`]:{flexDirection:`row`,[`> ${n}, > ${n}-content`]:{width:0}},[`${n}-header, &${n}-footer`]:{flex:`0 0 auto`},[`${n}-header`]:{height:c,paddingInline:l,color:u,lineHeight:`${c}px`,background:a,[`${t}-menu`]:{lineHeight:`inherit`}},[`${n}-footer`]:{padding:d,color:r,fontSize:g,background:o},[`${n}-content`]:{flex:`auto`,minHeight:0},[`${n}-sider`]:{position:`relative`,minWidth:0,background:a,transition:`all ${m}, background 0s`,"&-children":{height:`100%`,marginTop:-.1,paddingTop:.1,[`${t}-menu${t}-menu-inline-collapsed`]:{width:`auto`}},"&-has-trigger":{paddingBottom:f},"&-right":{order:1},"&-trigger":{position:`fixed`,bottom:0,zIndex:1,height:f,color:i,lineHeight:`${f}px`,textAlign:`center`,background:s,cursor:`pointer`,transition:`all ${m}`},"&-zero-width":{"> *":{overflow:`hidden`},"&-trigger":{position:`absolute`,top:c,insetInlineEnd:-p,zIndex:1,width:p,height:p,color:i,fontSize:e.fontSizeXL,display:`flex`,alignItems:`center`,justifyContent:`center`,background:a,borderStartStartRadius:0,borderStartEndRadius:_,borderEndEndRadius:_,borderEndStartRadius:0,cursor:`pointer`,transition:`background ${h} ease`,"&::after":{position:`absolute`,inset:0,background:`transparent`,transition:`all ${h}`,content:`""`},"&:hover::after":{background:`rgba(255, 255, 255, 0.2)`},"&-right":{insetInlineStart:-p,borderStartStartRadius:_,borderStartEndRadius:0,borderEndEndRadius:0,borderEndStartRadius:_}}}}},K(e)),{"&-rtl":{direction:`rtl`}})}},Ee=se(`Layout`,e=>{let{colorText:t,controlHeightSM:n,controlHeight:r,controlHeightLG:i,marginXXS:a}=e,o=i*1.25;return[Te(z(e,{layoutHeaderHeight:r*2,layoutHeaderPaddingInline:o,layoutHeaderColor:t,layoutFooterPadding:`${n}px ${o}px`,layoutTriggerHeight:i+a*2,layoutZeroTriggerSize:i}))]},e=>{let{colorBgLayout:t}=e;return{colorBgHeader:`#001529`,colorBgBody:t,colorBgTrigger:`#002140`}}),q=()=>({prefixCls:String,hasSider:{type:Boolean,default:void 0},tagName:String});function J(e){let{suffixCls:t,tagName:n,name:r}=e;return e=>a({compatConfig:{MODE:3},name:r,props:q(),setup(r,i){let{slots:a}=i,{prefixCls:o}=I(t,r);return()=>{let t=F(F({},r),{prefixCls:o.value,tagName:n});return k(e,t,a)}}})}var Y=a({compatConfig:{MODE:3},props:q(),setup(e,t){let{slots:n}=t;return()=>k(e.tagName,{class:e.prefixCls},n)}}),De=a({compatConfig:{MODE:3},inheritAttrs:!1,props:q(),setup(e,t){let{slots:n,attrs:r}=t,{prefixCls:i,direction:a}=I(``,e),[o,s]=Ee(i),c=w([]);p(H,{addSider:e=>{c.value=[...c.value,e]},removeSider:e=>{c.value=c.value.filter(t=>t!==e)}});let l=y(()=>{let{prefixCls:t,hasSider:n}=e;return{[s.value]:!0,[`${t}`]:!0,[`${t}-has-sider`]:typeof n==`boolean`?n:c.value.length>0,[`${t}-rtl`]:a.value===`rtl`}});return()=>{let{tagName:t}=e;return o(k(t,F(F({},r),{class:[l.value,r.class]}),n))}}}),Oe=J({suffixCls:`layout`,tagName:`section`,name:`ALayout`})(De),X=J({suffixCls:`layout-header`,tagName:`header`,name:`ALayoutHeader`})(Y),Z=J({suffixCls:`layout-footer`,tagName:`footer`,name:`ALayoutFooter`})(Y),Q=J({suffixCls:`layout-content`,tagName:`main`,name:`ALayoutContent`})(Y),ke={icon:{tag:`svg`,attrs:{viewBox:`0 0 1024 1024`,focusable:`false`},children:[{tag:`path`,attrs:{d:`M912 192H328c-4.4 0-8 3.6-8 8v56c0 4.4 3.6 8 8 8h584c4.4 0 8-3.6 8-8v-56c0-4.4-3.6-8-8-8zm0 284H328c-4.4 0-8 3.6-8 8v56c0 4.4 3.6 8 8 8h584c4.4 0 8-3.6 8-8v-56c0-4.4-3.6-8-8-8zm0 284H328c-4.4 0-8 3.6-8 8v56c0 4.4 3.6 8 8 8h584c4.4 0 8-3.6 8-8v-56c0-4.4-3.6-8-8-8zM104 228a56 56 0 10112 0 56 56 0 10-112 0zm0 284a56 56 0 10112 0 56 56 0 10-112 0zm0 284a56 56 0 10112 0 56 56 0 10-112 0z`}}]},name:`bars`,theme:`outlined`};function Ae(e){for(var t=1;t<arguments.length;t++){var n=arguments[t]==null?{}:Object(arguments[t]),r=Object.keys(n);typeof Object.getOwnPropertySymbols==`function`&&(r=r.concat(Object.getOwnPropertySymbols(n).filter(function(e){return Object.getOwnPropertyDescriptor(n,e).enumerable}))),r.forEach(function(t){je(e,t,n[t])})}return e}function je(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}var Me=function(e,t){var n=Ae({},e,t.attrs);return k(V,Ae({},n,{icon:ke}),null)};Me.displayName=`BarsOutlined`,Me.inheritAttrs=!1;var Ne={xs:`479.98px`,sm:`575.98px`,md:`767.98px`,lg:`991.98px`,xl:`1199.98px`,xxl:`1599.98px`,xxxl:`1999.98px`},Pe=()=>({prefixCls:String,collapsible:{type:Boolean,default:void 0},collapsed:{type:Boolean,default:void 0},defaultCollapsed:{type:Boolean,default:void 0},reverseArrow:{type:Boolean,default:void 0},zeroWidthTriggerStyle:{type:Object,default:void 0},trigger:R.any,width:R.oneOfType([R.number,R.string]),collapsedWidth:R.oneOfType([R.number,R.string]),breakpoint:R.oneOf(L(`xs`,`sm`,`md`,`lg`,`xl`,`xxl`,`xxxl`)),theme:R.oneOf(L(`light`,`dark`)).def(`dark`),onBreakpoint:Function,onCollapse:Function}),Fe=(()=>{let e=0;return function(){let t=arguments.length>0&&arguments[0]!==void 0?arguments[0]:``;return e+=1,`${t}${e}`}})(),$=a({compatConfig:{MODE:3},name:`ALayoutSider`,inheritAttrs:!1,props:B(Pe(),{collapsible:!1,defaultCollapsed:!1,reverseArrow:!1,width:200,collapsedWidth:80}),emits:[`breakpoint`,`update:collapsed`,`collapse`],setup(e,t){let{emit:n,attrs:r,slots:i}=t,{prefixCls:a}=I(`layout-sider`,e),s=d(H,void 0),c=x(!!(e.collapsed===void 0?e.defaultCollapsed:e.collapsed)),l=x(!1);v(()=>e.collapsed,()=>{c.value=!!e.collapsed}),p(fe,c);let u=(t,r)=>{e.collapsed===void 0&&(c.value=t),n(`update:collapsed`,t),n(`collapse`,t,r)},f=x(e=>{l.value=e.matches,n(`breakpoint`,e.matches),c.value!==e.matches&&u(e.matches,`responsive`)}),m;function h(e){return f.value(e)}let g=Fe(`ant-sider-`);s&&s.addSider(g),j(()=>{v(()=>e.breakpoint,()=>{try{m?.removeEventListener(`change`,h)}catch{m?.removeListener(h)}if(typeof window<`u`){let{matchMedia:t}=window;if(t&&e.breakpoint&&e.breakpoint in Ne){m=t(`(max-width: ${Ne[e.breakpoint]})`);try{m.addEventListener(`change`,h)}catch{m.addListener(h)}h(m)}}},{immediate:!0})}),o(()=>{try{m?.removeEventListener(`change`,h)}catch{m?.removeListener(h)}s&&s.removeSider(g)});let _=()=>{u(!c.value,`clickTrigger`)};return()=>{let t=a.value,{collapsedWidth:n,width:o,reverseArrow:s,zeroWidthTriggerStyle:u,trigger:d=i.trigger?.call(i),collapsible:f,theme:p}=e,m=c.value?n:o,h=U(m)?`${m}px`:String(m),g=parseFloat(String(n||0))===0?k(`span`,{onClick:_,class:P(`${t}-zero-width-trigger`,`${t}-zero-width-trigger-${s?`right`:`left`}`),style:u},[d||k(Me,null,null)]):null,v={expanded:k(s?W:G,null,null),collapsed:k(s?G:W,null,null)}[c.value?`collapsed`:`expanded`],y=d===null?null:g||k(`div`,{class:`${t}-trigger`,onClick:_,style:{width:h}},[d||v]),b=[r.style,{flex:`0 0 ${h}`,maxWidth:h,minWidth:h,width:h}],x=P(t,`${t}-${p}`,{[`${t}-collapsed`]:!!c.value,[`${t}-has-trigger`]:f&&d!==null&&!g,[`${t}-below`]:!!l.value,[`${t}-zero-width`]:parseFloat(h)===0},r.class);return k(`aside`,oe(oe({},r),{},{class:x,style:b}),[k(`div`,{class:`${t}-children`},[i.default?.call(i)]),f||l.value&&g?y:null])}}}),Ie=X,Le=Z,Re=$,ze=Q,Be=F(Oe,{Header:X,Footer:Z,Content:Q,Sider:$,install:e=>(e.component(Oe.name,Oe),e.component(X.name,X),e.component(Z.name,Z),e.component($.name,$),e.component(Q.name,Q),e)}),Ve=[`width`,`height`],He=Object.assign(a({__name:`AwLogo`,props:{size:{default:32}},setup(e){return(t,n)=>(c(),b(`svg`,{width:e.size,height:e.size,viewBox:`0 0 64 64`,fill:`none`,"aria-hidden":`true`},[...n[0]||=[A(`<defs><linearGradient id="aw-logo-gradient" x1="0" y1="0" x2="1" y2="1"><stop offset="0" stop-color="#35e0a0"></stop><stop offset="1" stop-color="#41c8f4"></stop></linearGradient></defs><path d="M32 4 L56 18 V46 L32 60 L8 46 V18 Z" stroke="url(#aw-logo-gradient)" stroke-width="4" stroke-linejoin="round"></path><path d="M32 15 L46.7 23.5 V40.5 L32 49 L17.3 40.5 V23.5 Z" stroke="#41c8f4" stroke-opacity="0.45" stroke-width="1.8" stroke-dasharray="4 3"></path><path d="M32 23 L25 38 M32 23 L39 38 M25 38 L39 38" stroke="#35e0a0" stroke-width="1.8" stroke-opacity="0.75"></path><circle cx="32" cy="23" r="3.4" fill="#35e0a0"></circle><circle cx="25" cy="38" r="3.4" fill="#41c8f4"></circle><circle cx="39" cy="38" r="3.4" fill="#41c8f4"></circle>`,7)]],8,Ve))}}),{__name:`AwLogo`}),Ue={class:`logo`},We={class:`logo-mark`,"aria-hidden":`true`},Ge={class:`logo-text`},Ke={class:`logo-title`},qe={class:`app-menu`},Je=[`title`,`onClick`],Ye={class:`sider-footer`},Xe={class:`footer-line`},Ze=Object.assign(O(a({__name:`AppSidebar`,setup(n){let r=ve(),{t:i}=ie(),a=N(),o=re(),u=te(),d=y(()=>[{key:`/`,icon:`i-tabler-layout-dashboard`,label:i(`menu.dashboard`),motion:`im-pop`},{key:`/workshop`,icon:`i-tabler-box`,label:i(`menu.workshop`),motion:`im-pop`},{key:`/town`,icon:`i-tabler-map-2`,label:i(`menu.town`),motion:`im-pop`},{key:`/tokens`,icon:`i-tabler-key`,label:i(`menu.tokens`),motion:`im-nudge-up`},{key:`/daq`,icon:`i-tabler-activity`,label:i(`menu.daq`),motion:`im-pop`},{key:`/dcw`,icon:`i-tabler-settings-automation`,label:i(`menu.dcw`),motion:`im-pop`},{key:`/logs`,icon:`i-tabler-list-details`,label:i(`menu.logs`),motion:`im-pop`},{key:`/users`,icon:`i-tabler-users-group`,label:i(`menu.users`),motion:`im-pop`},{key:`/permissions`,icon:`i-tabler-shield-lock`,label:i(`menu.permissions`),motion:`im-pop`,adminOnly:!0},{key:`/monitor`,icon:`i-tabler-cpu`,label:i(`menu.monitor`),motion:`im-pulse`},{key:`/plugins`,icon:`i-tabler-puzzle`,label:i(`menu.plugins`),motion:`im-pop`},{key:`/settings`,icon:`i-tabler-settings`,label:i(`menu.settings`),motion:`im-rotate`}].filter(e=>!e.adminOnly||r.isAdmin)),p=e=>e===`/`?a.path===`/`:a.path.startsWith(e),m=e=>{p(e)||M(e)};return(n,r)=>{let a=He,_=Re;return c(),C(_,{collapsed:f(u).sidebarCollapsed,"onUpdate:collapsed":r[0]||=e=>f(u).sidebarCollapsed=e,trigger:null,collapsible:``,breakpoint:`lg`,width:228,"collapsed-width":64,class:`app-sider`},{default:T(()=>[E(`div`,Ue,[E(`div`,We,[k(a,{size:30})]),k(t,{name:`slide-fade`},{default:T(()=>[D(E(`div`,Ge,[E(`span`,Ke,h(f(o).name),1),r[1]||=E(`span`,{class:`logo-sub`},`digital twin`,-1)],512),[[e,!f(u).sidebarCollapsed]])]),_:1})]),D(E(`div`,{class:`sider-section-label`},h(f(i)(`menu.system`)),513),[[e,!f(u).sidebarCollapsed]]),E(`nav`,qe,[(c(!0),b(g,null,s(f(d),t=>(c(),b(`button`,{key:t.key,type:`button`,class:l([`menu-item im`,{active:p(t.key)}]),title:f(u).sidebarCollapsed?t.label:void 0,onClick:e=>m(t.key)},[E(`span`,{class:l([`menu-icon`,[t.icon,t.motion]])},null,2),D(E(`span`,{class:`menu-label`},h(t.label),513),[[e,!f(u).sidebarCollapsed]])],10,Je))),128))]),D(E(`div`,Ye,[E(`div`,Xe,[E(`span`,null,`v`+h(f(o).version),1),r[2]||=E(`span`,{class:`sep`},`/`,-1),E(`span`,null,h(f(o).mode),1)])],512),[[e,!f(u).sidebarCollapsed]])]),_:1},8,[`collapsed`])}}}),[[`__scopeId`,`data-v-62a7e637`]]),{__name:`AppSidebar`}),Qe=ee(`app.routeTrail`,()=>{let e=w([]);function t(t){if(!t||t.startsWith(`/api`))return;let n=e.value.filter(e=>e.path!==t);e.value=[...n,{path:t,at:Date.now()}].slice(-8)}function n(t){let n=e.value.findIndex(e=>e.path===t);return n>=0&&(e.value=e.value.filter(e=>e.path!==t)),n}function r(){e.value=[]}return{waypoints:e,visit:t,remove:n,clear:r}},{persist:{pick:[`waypoints`],storage:ne.localStorage()}});function $e(){let{t:e}=ie(),t=ye(),n={"/":{key:`menu.dashboard`,icon:`i-tabler-layout-dashboard`},"/workshop":{key:`menu.workshop`,icon:`i-tabler-box`},"/workshop/agents":{key:`meta.agents`,icon:`i-tabler-users`},"/workshop/teams":{key:`meta.teams`,icon:`i-tabler-users-group`},"/workshop/channel-templates":{key:`meta.ctpl`,icon:`i-tabler-layout-grid-add`},"/town":{key:`menu.town`,icon:`i-tabler-map-2`},"/tokens":{key:`menu.tokens`,icon:`i-tabler-key`},"/daq":{key:`menu.daq`,icon:`i-tabler-activity`},"/dcw":{key:`menu.dcw`,icon:`i-tabler-settings-automation`},"/logs":{key:`menu.logs`,icon:`i-tabler-list-details`},"/permissions":{key:`menu.permissions`,icon:`i-tabler-shield-lock`},"/plugins":{key:`menu.plugins`,icon:`i-tabler-puzzle`},"/users":{key:`menu.users`,icon:`i-tabler-users-group`},"/monitor":{key:`menu.monitor`,icon:`i-tabler-cpu`},"/settings":{key:`menu.settings`,icon:`i-tabler-settings`}};return{metaFor:r=>{let i=n[r];if(i)return{title:e(i.key),icon:i.icon};let a=r.match(/^\/workshop\/w\/([^/]+)$/);if(a){let n=a[1];return{title:t.workspaces.find(e=>e.id===n)?.name??`${e(`header.workspace`)} ${n.slice(0,6)}`,icon:`i-tabler-console`}}let o=r.split(`/`).filter(Boolean).pop()??`·`;return{title:o.charAt(0).toUpperCase()+o.slice(1),icon:`i-tabler-point`}}}}var et={class:`header-left`},tt=[`aria-label`],nt=[`aria-label`],rt=[`title`,`onClick`,`onKeydown`],it={class:`node-title`},at=[`aria-label`,`title`,`onClick`],ot={class:`header-right`},st=[`title`],ct={class:`hitl-count`},lt={class:`hitl-menu`},ut={class:`hitl-menu-title`},dt=[`onClick`],ft={class:`hitl-item-top`},pt={class:`hitl-item-agent`},mt={class:`hitl-item-kind`},ht={class:`hitl-item-title`},gt=[`title`],_t={class:`user-chip`},vt={class:`user-initial aw-avatar`},yt={class:`user-meta`},bt={class:`user-name`},xt={class:`user-role`},St=Object.assign(O(a({__name:`AppHeader`,setup(e){let{t,locale:a,locales:u,setLocale:d}=ie(),p=te(),m=N(),x=Qe(),D=ve(),{metaFor:O}=$e(),A=Se(),ee=Ce(),ne=()=>{D.isLoggedIn&&ee.ensureConnected()};v(()=>D.token,e=>{e?(ne(),A.loadSnapshot()):A.clear()},{immediate:!0});let re=new Set([`codex-approval`,`opencode-permission`,`dsh-permission`]),oe=e=>{switch(e){case`omp-dialog`:return t(`appHeader.hitlKindOmp`);case`dcw-approval`:return t(`appHeader.hitlKindDcw`);case`codex-approval`:return t(`appHeader.hitlKindCodex`);case`opencode-permission`:return t(`appHeader.hitlKindOpencode`);case`dsh-permission`:return t(`appHeader.hitlKindDsh`);default:return e}},P=e=>{M({path:`/monitor`,query:{agentId:e.agentId,channelId:e.channelId}})},se=we(),F=w(null),I=async(e,t)=>{F.value=`${e.kind}:${e.id}`;try{await se.respondHitl({kind:e.kind,id:e.id,confirmed:t,cancelled:!t}),await A.loadSnapshot()}catch(e){de.error(be(e))}finally{F.value=null}},L=y(()=>u.value.map(e=>({label:e.name,value:e.code}))),R=e=>{e!=null&&(localStorage.setItem(`aw.locale`,String(e)),d(String(e)),window.location.reload())},z=w(!1),B=w(!1),V=null;v(()=>m.path,()=>{x.visit(m.path),B.value=!1,requestAnimationFrame(()=>{B.value=!0,V&&clearTimeout(V),V=setTimeout(()=>{B.value=!1},620)})},{immediate:!1}),j(()=>{z.value=!0,x.visit(m.path)}),o(()=>{V&&clearTimeout(V)});let H=e=>{e!==m.path&&M(e)},fe=e=>{let t=x.remove(e);if(e!==m.path)return;let n=x.waypoints,r=n[Math.min(Math.max(t-1,0),Math.max(n.length-1,0))]?.path??`/`;M(r)},U=w(!1);function W(){document.fullscreenElement?(document.exitFullscreen(),U.value=!1):(document.documentElement.requestFullscreen(),U.value=!0)}let G=y(()=>(D.user?.name??`?`).trim().charAt(0).toUpperCase()),_e=y(()=>D.user?.name??t(`header.guest`)),ye=y(()=>D.isLoggedIn?D.user?.role??`user`:`anonymous`),K=xe(),Te=y(()=>K.state!==`closed`||K.lastDataAt>0),Ee=y(()=>K.state===`open`?K.pendingReplay?`syncing`:`live`:K.state===`connecting`?`syncing`:`down`),q=y(()=>K.state===`open`?K.pendingReplay?t(`appHeader.kwsdot0002`):t(`appHeader.kwsdot0001`):K.state===`connecting`?t(`appHeader.kwsdot0003`):t(`appHeader.kwsdot0004`)),J=y(()=>{let e=[{key:`tokens`,icon:`i-tabler-key`,label:t(`menu.tokens`)},{key:`settings`,icon:`i-tabler-adjustments`,label:t(`menu.settings`)}];return D.isLoggedIn&&(e.push({key:`d-logout`,label:``,divider:!0}),e.push({key:`logout`,icon:`i-tabler-logout`,label:t(`header.logout`),danger:!0})),e}),Y=async({key:e})=>{e===`settings`?M(`/settings`):e===`tokens`?M(`/tokens`):e===`logout`&&(await D.logout(),M(`/workshop`))};return(e,o)=>{let u=le,d=ge,v=ae,y=ce,w=ue,D=pe,j=me,M=he,N=Ie;return c(),C(N,{class:`app-header app-header-glass`},{default:T(()=>[E(`div`,et,[E(`button`,{class:`collapse-btn`,"aria-label":f(p).sidebarCollapsed?f(t)(`header.expand`):f(t)(`header.collapse`),onClick:o[0]||=e=>f(p).toggleSidebar()},[...o[3]||=[E(`span`,{class:`i-tabler-menu-2`},null,-1)]],8,tt),o[5]||=E(`span`,{class:`rail-mark i-tabler-route`},null,-1),E(`nav`,{class:`trail`,"aria-label":f(t)(`header.trail`)},[k(r,{name:`stamp`,tag:`div`,class:`trail-row`},{default:T(()=>[f(z)?(c(!0),b(g,{key:0},s(f(x).waypoints,(t,r)=>(c(),b(g,{key:t.path},[r>0?(c(),b(`span`,{key:`link-${t.path}`,class:`trail-link`,"aria-hidden":`true`})):S(``,!0),E(`div`,{class:l([`trail-node`,{active:t.path===f(m).path}]),role:`button`,tabindex:`0`,title:f(O)(t.path).title,onClick:e=>H(t.path),onKeydown:n(i(e=>H(t.path),[`prevent`]),[`enter`])},[E(`span`,{class:l([`node-icon`,f(O)(t.path).icon])},null,2),E(`span`,it,h(f(O)(t.path).title),1),E(`button`,{class:`node-close`,"aria-label":e.$t(`appHeader.kzwjv99001`,{p0:f(O)(t.path).title}),title:e.$t(`appHeader.kzwjv99001`,{p0:f(O)(t.path).title}),onClick:i(e=>fe(t.path),[`stop`])},[...o[4]||=[E(`span`,{class:`i-tabler-x`},null,-1)]],8,at)],42,rt)],64))),128)):S(``,!0)]),_:1})],8,nt)]),E(`div`,ot,[k(v,null,{default:T(()=>[f(A).count>0?(c(),C(d,{key:0,placement:`bottomRight`},{overlay:T(()=>[E(`div`,lt,[E(`div`,ut,h(f(t)(`appHeader.hitlBadge`))+` · `+h(f(A).count),1),(c(!0),b(g,null,s(f(A).items,e=>(c(),b(`button`,{key:`${e.kind}:${e.id}`,class:`hitl-item`,onClick:t=>P(e)},[E(`span`,ft,[E(`span`,pt,h(e.agentName),1),E(`span`,mt,h(oe(e.kind)),1)]),E(`span`,ht,h(e.title),1),f(re).has(e.kind)?(c(),b(`span`,{key:0,class:`hitl-item-actions`,onClick:o[1]||=i(()=>{},[`stop`])},[k(u,{size:`small`,type:`primary`,loading:f(F)===`${e.kind}:${e.id}`,onClick:t=>I(e,!0)},{default:T(()=>[_(h(f(t)(`appHeader.hitlApprove`)),1)]),_:1},8,[`loading`,`onClick`]),k(u,{size:`small`,danger:``,disabled:f(F)===`${e.kind}:${e.id}`,onClick:t=>I(e,!1)},{default:T(()=>[_(h(f(t)(`appHeader.hitlReject`)),1)]),_:1},8,[`disabled`,`onClick`])])):S(``,!0)],8,dt))),128))])]),default:T(()=>[E(`button`,{class:`icon-btn hitl-bell`,title:f(t)(`appHeader.hitlBadge`)},[o[6]||=E(`span`,{class:`i-tabler-bell-ringing`},null,-1),E(`span`,ct,h(f(A).count),1)],8,st)]),_:1})):S(``,!0)]),_:1}),f(Te)?(c(),b(`span`,{key:0,class:l([`ws-dot`,f(Ee)]),title:f(q)},null,10,gt)):S(``,!0),k(y,{title:f(t)(`header.fullscreen`)},{default:T(()=>[E(`button`,{class:`icon-btn`,onClick:W},[E(`span`,{class:l([`i-tabler-arrows-maximize`,{hidden:f(U)}])},null,2),E(`span`,{class:l([`i-tabler-arrows-minimize`,{hidden:!f(U)}])},null,2)])]),_:1},8,[`title`]),k(w,{id:`hdr-locale`,value:f(a),size:`middle`,options:f(L),class:`lang-select`,onChange:R},null,8,[`value`,`options`]),k(y,{title:f(p).isDark?f(t)(`common.light`):f(t)(`common.dark`)},{default:T(()=>[E(`button`,{class:`icon-btn`,onClick:o[2]||=e=>f(p).toggleDark()},[E(`span`,{class:l([`i-tabler-sun-high`,{hidden:f(p).isDark}])},null,2),E(`span`,{class:l([`i-tabler-moon-stars`,{hidden:!f(p).isDark}])},null,2)])]),_:1},8,[`title`]),k(d,null,{overlay:T(()=>[k(M,{onClick:Y},{default:T(()=>[(c(!0),b(g,null,s(f(J),e=>(c(),b(g,{key:e.key},[e.divider?(c(),C(D,{key:0})):(c(),C(j,{key:e.key,danger:e.danger},{default:T(()=>[E(`span`,{class:l([e.icon,`mr-2`])},null,2),_(` `+h(e.label),1)]),_:2},1032,[`danger`]))],64))),128))]),_:1})]),default:T(()=>[E(`div`,_t,[k(v,null,{fallback:T(()=>[...o[7]||=[E(`span`,{class:`user-initial aw-avatar`},`·`,-1),E(`span`,{class:`user-meta`},[E(`span`,{class:`user-name`},`·`),E(`span`,{class:`user-role`},`·`)],-1)]]),default:T(()=>[E(`span`,vt,h(f(G)),1),E(`span`,yt,[E(`span`,bt,h(f(_e)),1),E(`span`,xt,h(f(ye)),1)])]),_:1})])]),_:1})]),E(`span`,{class:l([`plotter-line`,{run:f(B)}]),"aria-hidden":`true`},null,2)]),_:1})}}}),[[`__scopeId`,`data-v-057ba9d0`]]),{__name:`AppHeader`}),Ct={class:`footer-title aw-serif-accent`},wt=O(a({__name:`default`,setup(e){let{token:t}=_e.useToken(),n=re();return(e,r)=>{let i=Ze,a=St,o=ze,s=Le,l=Be;return c(),C(l,{class:`app-layout`},{default:T(()=>[k(i),k(l,{class:`app-main`,style:m({background:`transparent`,"--app-bg-container":f(t)?.colorBgContainer,"--app-bg-layout":f(t)?.colorBgLayout,"--app-text":f(t)?.colorText,"--app-text-secondary":f(t)?.colorTextSecondary,"--app-border":f(t)?.colorBorderSecondary,"--app-fill":f(t)?.colorFillQuaternary,"--app-header-h":`56px`,"--app-footer-h":`46px`})},{default:T(()=>[k(a),k(o,{class:`app-content`},{default:T(()=>[u(e.$slots,`default`,{},void 0,!0)]),_:3}),k(s,{class:`app-footer`,style:m({color:f(t)?.colorTextSecondary})},{default:T(()=>[E(`span`,Ct,h(f(n).title),1),r[0]||=E(`span`,{class:`sep`},`/`,-1),E(`span`,null,`v`+h(f(n).version),1),r[1]||=E(`span`,{class:`sep`},`/`,-1),E(`span`,null,`mode=`+h(f(n).mode),1)]),_:1},8,[`style`])]),_:3},8,[`style`]),r[2]||=E(`span`,{class:`aw-noise`,"aria-hidden":`true`},null,-1)]),_:3})}}}),[[`__scopeId`,`data-v-05636ece`]]);export{wt as default};
@@ -0,0 +1 @@
1
+ import{q as e}from"./rqZ-1SoP.js";import{C as t,G as n,H as r,Ht as i,Wt as a,a as o,b as s,f as c,g as l,h as u,m as d,mt as f,nt as p,p as m,t as h,x as g,z as _}from"./BSCpFtzG.js";import{s as v}from"./C3tCneTM.js";import{n as ee}from"./BeIfu4N3.js";import{t as y}from"./VLI2Zy4t.js";import{r as b}from"./D-Ca4BGY.js";import{t as x}from"./niDwBOZW.js";import{t as S}from"./Bp5luxkg2.js";import{t as C}from"./DoLasgPj2.js";import{t as te}from"./BcrN7QEl2.js";import{t as w}from"./G0qIw7Gq2.js";var ne={class:`plugins-page`},re={class:`aw-page-head`},ie={class:`pg-sub`},ae={class:`pg-stats`},T={class:`stat`},E={class:`stat`},D={class:`stat`},O={key:1,class:`pg-empty`},k={class:`pg-empty-t`},A={class:`pg-grid aw-stagger`},j=[`onClick`],M={class:`card-head`},N={class:`card-name`},P={class:`card-ver`},F={class:`card-desc`},I={class:`card-tags`},L={key:0,class:`tag client`},R={key:0,class:`card-routes`},z={class:`detail`},B={class:`scope-hint`},oe={key:0},V={key:1,style:{color:`#ff6b6b`}},H={key:0,class:`dim`},U=h(t({__name:`index`,setup(t){let{t:h}=ee(),U=te(),W=f([]),G=f([]),K=f(!1),q=f(``),J=f(!1),Y=f(null);function X(){let e=U.token;return e?{authorization:`Bearer ${e}`}:{}}async function Z(){K.value=!0;try{let e=await v(`/api/workshop/plugins`,{headers:X()});W.value=e.plugins??[],G.value=e.failures??[]}catch(e){b.error(w(e,h(`plugins.loadFail`)))}finally{K.value=!1}}async function se(e){q.value=e.name;try{let t=await v(`/api/workshop/plugins/${e.name}/${e.enabled?`disable`:`enable`}`,{method:`POST`,headers:X()});if(t.code!==0||!t.data)throw Error(h(`plugins.enableFail`));e.enabled=t.data.enabled,b.success(`${e.name} · ${t.data.enabled?h(`plugins.enabled`):h(`plugins.disabled`)}`),setTimeout(Z,800)}catch(e){b.error(w(e,h(`plugins.enableFail`)))}finally{q.value=``}}let ce=c(()=>W.value.filter(e=>e.enabled).length),le=c(()=>W.value.filter(e=>e.hasClient).length);function Q(e){return h(e===`project`?`plugins.scopeProject`:`plugins.scopeUser`)}function $(e){Y.value=e,J.value=!0}return _(Z),(t,c)=>{let f=y,h=x,_=C,v=S;return r(),l(`div`,ne,[m(`header`,re,[m(`div`,null,[c[2]||=m(`p`,{class:`aw-kicker`},` agentworkshop / plugins `,-1),m(`h1`,null,a(t.$t(`plugins.title`)),1),m(`p`,ie,a(t.$t(`plugins.subtitle`)),1)]),m(`div`,ae,[m(`span`,T,[s(a(t.$t(`plugins.enabled`))+` `,1),m(`b`,null,a(ce.value),1)]),m(`span`,E,[s(a(t.$t(`plugins.hasClient`))+` `,1),m(`b`,null,a(le.value),1)]),m(`span`,D,[s(a(t.$t(`plugins.routes`))+` `,1),m(`b`,null,a(W.value.reduce((e,t)=>e+t.routes.length,0)),1)]),g(f,{size:`small`,loading:K.value,onClick:Z},{default:p(()=>[s(a(t.$t(`plugins.refresh`)),1)]),_:1},8,[`loading`])])]),G.value.length?(r(),d(h,{key:0,type:`error`,"show-icon":``,class:`pg-failures`,message:t.$t(`plugins.loadFailures`,{n:G.value.length})},{description:p(()=>[(r(!0),l(o,null,n(G.value,e=>(r(),l(`div`,{key:e.source,class:`fail-line`},a(e.source)+` — `+a(e.error),1))),128))]),_:1},8,[`message`])):u(``,!0),!W.value.length&&!K.value?(r(),l(`div`,O,[c[3]||=m(`span`,{class:`i-tabler-puzzle pg-empty-ico`},null,-1),m(`p`,k,a(t.$t(`plugins.empty`)),1)])):u(``,!0),m(`div`,A,[(r(!0),l(o,null,n(W.value,s=>(r(),l(`article`,{key:`${s.scope}:${s.name}`,class:i([`pg-card aw-liftable`,{"is-off":!s.enabled}]),onClick:e=>$(s)},[m(`div`,M,[m(`span`,N,a(s.name),1),m(`span`,P,a(s.version),1),g(_,{checked:s.enabled,loading:q.value===s.name,size:`small`,onClick:c[0]||=e(()=>{},[`stop`]),onChange:e=>se(s)},null,8,[`checked`,`loading`,`onChange`])]),m(`p`,F,a(s.description||`—`),1),m(`div`,I,[m(`span`,{class:i([`tag`,s.scope])},a(Q(s.scope)),3),m(`span`,{class:i([`tag`,s.enabled?`on`:`off`])},a(s.enabled?t.$t(`plugins.enabled`):t.$t(`plugins.disabled`)),3),s.hasClient?(r(),l(`span`,L,a(t.$t(`plugins.hasClient`)),1)):u(``,!0)]),s.routes.length?(r(),l(`div`,R,[(r(!0),l(o,null,n(s.routes,e=>(r(),l(`code`,{key:e.method+e.path},a(e.method)+` `+a(e.path),1))),128))])):u(``,!0)],10,j))),128))]),g(v,{open:J.value,"onUpdate:open":c[1]||=e=>J.value=e,title:Y.value?.name,width:`460`},{default:p(()=>[Y.value?(r(),l(o,{key:0},[m(`dl`,z,[c[4]||=m(`dt`,null,`version`,-1),m(`dd`,null,a(Y.value.version),1),c[5]||=m(`dt`,null,`scope`,-1),m(`dd`,null,a(Q(Y.value.scope)),1),m(`dd`,B,a(Y.value.scope===`project`?t.$t(`plugins.scopeBuiltinHint`):t.$t(`plugins.scopeUserHint`)),1),c[6]||=m(`dt`,null,`enabled`,-1),m(`dd`,null,a(Y.value.enabled),1),c[7]||=m(`dt`,null,`client`,-1),m(`dd`,null,a(Y.value.hasClient?`✓`:`—`),1),Y.value.error?(r(),l(`dt`,oe,` error `)):u(``,!0),Y.value.error?(r(),l(`dd`,V,a(Y.value.error),1)):u(``,!0)]),m(`h4`,null,a(t.$t(`plugins.routes`)),1),(r(!0),l(o,null,n(Y.value.routes,e=>(r(),l(`code`,{key:e.method+e.path,class:`detail-route`},a(e.method)+` /api/plugins/`+a(Y.value.name)+a(e.path),1))),128)),Y.value.routes.length?u(``,!0):(r(),l(`p`,H,` — `))],64)):u(``,!0)]),_:1},8,[`open`,`title`])])}}}),[[`__scopeId`,`data-v-617e5e4e`]]);export{U as default};