@vc-shell/framework 2.6.3-rc.0-pr389.87def60 → 2.7.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (34) hide show
  1. package/dist/ai-agent/index.js +2 -2
  2. package/dist/chunks/{VcAiAgentPanel.vue_vue_type_script_setup_true_lang-DCA-Ffyd.js → VcAiAgentPanel.vue_vue_type_script_setup_true_lang-c2L9ZMv-.js} +355 -349
  3. package/dist/chunks/VcAiAgentPanel.vue_vue_type_script_setup_true_lang-c2L9ZMv-.js.map +1 -0
  4. package/dist/chunks/{VcScheduler.vue_vue_type_script_setup_true_lang-qXf9_bH2.js → VcScheduler.vue_vue_type_script_setup_true_lang-0d1Dle1T.js} +5810 -5806
  5. package/dist/chunks/VcScheduler.vue_vue_type_script_setup_true_lang-0d1Dle1T.js.map +1 -0
  6. package/dist/chunks/{VcScheduler.vue_vue_type_style_index_0_lang-Dr98EAcc.js → VcScheduler.vue_vue_type_style_index_0_lang-CSqtsFQm.js} +67 -67
  7. package/dist/chunks/VcScheduler.vue_vue_type_style_index_0_lang-CSqtsFQm.js.map +1 -0
  8. package/dist/chunks/{dashboard-feed-row.vue_vue_type_script_setup_true_lang-D4pPtjsM.js → dashboard-feed-row.vue_vue_type_script_setup_true_lang-DuuZ_8d4.js} +1 -1
  9. package/dist/chunks/{dashboard-feed-row.vue_vue_type_script_setup_true_lang-D4pPtjsM.js.map → dashboard-feed-row.vue_vue_type_script_setup_true_lang-DuuZ_8d4.js.map} +1 -1
  10. package/dist/chunks/{index-DSdo2M5t.js → index-DUQy_82B.js} +1 -1
  11. package/dist/chunks/{index-DSdo2M5t.js.map → index-DUQy_82B.js.map} +1 -1
  12. package/dist/core/blade-navigation/utils/urlSync.d.ts.map +1 -1
  13. package/dist/core/composables/index.d.ts +1 -0
  14. package/dist/core/composables/index.d.ts.map +1 -1
  15. package/dist/core/composables/useBladeForm/index.d.ts.map +1 -1
  16. package/dist/core/interceptors/index.d.ts.map +1 -1
  17. package/dist/core/utilities/authGuard.d.ts.map +1 -1
  18. package/dist/core/utilities/redirectAfterLogin.d.ts +12 -0
  19. package/dist/core/utilities/redirectAfterLogin.d.ts.map +1 -0
  20. package/dist/dashboard/index.js +1 -1
  21. package/dist/framework.js +1115 -1103
  22. package/dist/framework.js.map +1 -1
  23. package/dist/shell/auth/LoginPage/components/login/Login.vue.d.ts.map +1 -1
  24. package/dist/tsconfig.tsbuildinfo +1 -1
  25. package/dist/ui/components/molecules/vc-date-picker/vc-date-picker.vue.d.ts.map +1 -1
  26. package/dist/ui/components/molecules/vc-dropdown/vc-dropdown.vue.d.ts +2 -0
  27. package/dist/ui/components/molecules/vc-dropdown/vc-dropdown.vue.d.ts.map +1 -1
  28. package/dist/ui/components/organisms/vc-blade/_internal/toolbar/ToolbarDesktop.vue.d.ts.map +1 -1
  29. package/dist/ui/composables/useAdaptiveItems.d.ts.map +1 -1
  30. package/dist/ui/index.js +2 -2
  31. package/package.json +4 -4
  32. package/dist/chunks/VcAiAgentPanel.vue_vue_type_script_setup_true_lang-DCA-Ffyd.js.map +0 -1
  33. package/dist/chunks/VcScheduler.vue_vue_type_script_setup_true_lang-qXf9_bH2.js.map +0 -1
  34. package/dist/chunks/VcScheduler.vue_vue_type_style_index_0_lang-Dr98EAcc.js.map +0 -1
@@ -1,35 +1,35 @@
1
- import { ref as D, computed as b, shallowRef as ze, watch as z, getCurrentInstance as ne, inject as M, isRef as We, provide as ke, defineComponent as R, openBlock as A, createElementBlock as k, createElementVNode as x, createCommentVNode as H, createStaticVNode as qe, Fragment as Ee, renderList as Se, toDisplayString as le, createBlock as ce, unref as V, withCtx as j, renderSlot as He, createTextVNode as Ze, createVNode as F, withKeys as we, withModifiers as Ae, Transition as Oe, normalizeClass as Pe, onUnmounted as Xe, normalizeStyle as Ye } from "vue";
2
- import { c as Z, d as Le, e as je, B as Qe, f as Je, g as et, N as tt, A as be, L as nt, h as at, T as ot, a as rt, _ as De, E as it } from "./VcAiAgentPanel.vue_vue_type_style_index_0_lang-TiaFg1wQ.js";
1
+ import { ref as D, computed as b, shallowRef as We, watch as V, getCurrentInstance as ne, inject as M, isRef as qe, provide as ke, defineComponent as R, openBlock as A, createElementBlock as k, createElementVNode as x, createCommentVNode as H, createStaticVNode as He, Fragment as Ee, renderList as Se, toDisplayString as le, createBlock as ce, unref as K, withCtx as Q, renderSlot as Ze, createTextVNode as Xe, createVNode as F, withKeys as we, withModifiers as Ae, Transition as Oe, normalizeClass as Pe, onUnmounted as Ye, normalizeStyle as je } from "vue";
2
+ import { c as Z, d as Le, e as Qe, B as Je, f as et, g as tt, N as nt, A as be, L as at, h as ot, T as it, a as rt, _ as De, E as st } from "./VcAiAgentPanel.vue_vue_type_style_index_0_lang-TiaFg1wQ.js";
3
3
  import { c as ae } from "./vendor-lodash-es-D2n90GJy.js";
4
- import { u as st } from "./vendor-vueuse-core-BwXFv1rx.js";
5
- import { u as lt } from "./vendor-vue-i18n-LO-EJStU.js";
6
- const ct = {
4
+ import { u as lt } from "./vendor-vueuse-core-BwXFv1rx.js";
5
+ import { u as ct } from "./vendor-vue-i18n-LO-EJStU.js";
6
+ const dt = {
7
7
  url: "",
8
8
  title: "Virto OZ",
9
9
  width: 362,
10
10
  expandedWidth: 500,
11
11
  // Secure by default: no origins trusted until the embedder configures them.
12
12
  allowedOrigins: []
13
- }, An = "APP_AI_AGENT_URL", yn = {
13
+ }, yn = "APP_AI_AGENT_URL", xn = {
14
14
  EMBEDDED_APP_READY: "EMBEDDED_APP_READY",
15
15
  AI_TOGGLE_PANEL: "AI_TOGGLE_PANEL",
16
16
  AI_CONTEXT_UPDATE: "AI_CONTEXT_UPDATE",
17
17
  AI_CONTEXT_CLEAR: "AI_CONTEXT_CLEAR"
18
- }, xn = {
18
+ }, Bn = {
19
19
  EMBEDDED_HOST_READY: "EMBEDDED_HOST_READY",
20
20
  AI_CHAT_MESSAGE: "AI_CHAT_MESSAGE"
21
- }, dt = "ai-agent-toggle", ut = "lucide-sparkles", ft = "AI Assistant", oe = Z("ai-agent-panel");
22
- function pt() {
23
- const e = D("closed"), i = D(!1), a = b(() => e.value !== "closed"), t = b(() => e.value === "expanded"), o = () => {
21
+ }, ut = "ai-agent-toggle", ft = "lucide-sparkles", pt = "AI Assistant", oe = Z("ai-agent-panel");
22
+ function gt() {
23
+ const e = D("closed"), r = D(!1), a = b(() => e.value !== "closed"), t = b(() => e.value === "expanded"), o = () => {
24
24
  e.value === "closed" && (e.value = "open", oe.debug("Panel opened"));
25
25
  }, l = () => {
26
- e.value = "closed", i.value = !1, oe.debug("Panel closed, reset initialized state");
26
+ e.value = "closed", r.value = !1, oe.debug("Panel closed, reset initialized state");
27
27
  };
28
28
  return {
29
29
  panelState: e,
30
30
  isOpen: a,
31
31
  isExpanded: t,
32
- isInitialized: i,
32
+ isInitialized: r,
33
33
  open: o,
34
34
  close: l,
35
35
  toggle: () => {
@@ -42,7 +42,7 @@ function pt() {
42
42
  e.value === "expanded" && (e.value = "open", oe.debug("Panel collapsed"));
43
43
  },
44
44
  resetInitialized: () => {
45
- i.value = !1;
45
+ r.value = !1;
46
46
  }
47
47
  };
48
48
  }
@@ -55,8 +55,8 @@ function ye(e) {
55
55
  param: e.param
56
56
  } : { id: "unknown", name: "unknown", title: "Unknown" };
57
57
  }
58
- function gt(e) {
59
- const { userGetter: i, bladeGetter: a, localeGetter: t, tokenGetter: o } = e, l = D(/* @__PURE__ */ new Map()), f = () => {
58
+ function vt(e) {
59
+ const { userGetter: r, bladeGetter: a, localeGetter: t, tokenGetter: o } = e, l = D(/* @__PURE__ */ new Map()), f = () => {
60
60
  const p = a();
61
61
  return p ? l.value.get(p.id) ?? {
62
62
  items: [],
@@ -73,14 +73,14 @@ function gt(e) {
73
73
  contextType: h,
74
74
  contextSuggestions: v,
75
75
  totalItemsCount: c,
76
- setContextData: (p, _, I, P) => {
76
+ setContextData: (p, _, B, P) => {
77
77
  const L = a()?.id || P;
78
- return L ? p.length === 0 && !I ? (l.value.delete(L), _e.debug(`Context cleared for blade: ${L}`), { cleared: !0 }) : (l.value.set(L, { items: p, type: _, suggestions: I }), _e.debug(`Context set for blade: ${L}, items: ${p.length}, type: ${_}`), { cleared: !1 }) : (_e.warn("Cannot set context data: no blade id available"), { cleared: !1 });
78
+ return L ? p.length === 0 && !B ? (l.value.delete(L), _e.debug(`Context cleared for blade: ${L}`), { cleared: !0 }) : (l.value.set(L, { items: p, type: _, suggestions: B }), _e.debug(`Context set for blade: ${L}, items: ${p.length}, type: ${_}`), { cleared: !1 }) : (_e.warn("Cannot set context data: no blade id available"), { cleared: !1 });
79
79
  },
80
80
  buildInitPayload: async () => {
81
81
  const p = o ? await o() ?? void 0 : void 0;
82
82
  return {
83
- userId: i()?.id || "",
83
+ userId: r()?.id || "",
84
84
  locale: t(),
85
85
  blade: ye(a()),
86
86
  contextType: h.value,
@@ -103,8 +103,8 @@ function gt(e) {
103
103
  };
104
104
  }
105
105
  const O = Z("ai-agent-transport");
106
- function vt(e) {
107
- const { getConfig: i, isEmbedded: a, navigateToBlade: t, closePanel: o } = e, l = ze(null), f = D(!1), g = D(!1), h = /* @__PURE__ */ new Set(), v = /* @__PURE__ */ new Set();
106
+ function Ct(e) {
107
+ const { getConfig: r, isEmbedded: a, navigateToBlade: t, closePanel: o } = e, l = We(null), f = D(!1), g = D(!1), h = /* @__PURE__ */ new Set(), v = /* @__PURE__ */ new Set();
108
108
  function c(u, w) {
109
109
  switch (u) {
110
110
  case "NAVIGATE_TO_APP": {
@@ -129,13 +129,13 @@ function vt(e) {
129
129
  h.forEach((_) => {
130
130
  try {
131
131
  _(p);
132
- } catch (I) {
133
- O.error("Handler error:", I);
132
+ } catch (B) {
133
+ O.error("Handler error:", B);
134
134
  }
135
135
  });
136
136
  }
137
137
  function d(u) {
138
- const p = i().allowedOrigins ?? [];
138
+ const p = r().allowedOrigins ?? [];
139
139
  if (p.length === 0) {
140
140
  O.warn(
141
141
  "Ignoring postMessage: aiAgentConfig.allowedOrigins is empty. Configure explicit origins to enable the AI agent bridge.",
@@ -154,13 +154,13 @@ function vt(e) {
154
154
  const _ = a ? window.parent : l.value?.contentWindow;
155
155
  if (!_ || u.source !== _)
156
156
  return;
157
- const I = u.data;
158
- if (!(!I?.type || typeof I.type != "string"))
159
- switch (O.debug(`Message received: ${I.type}`), I.type) {
157
+ const B = u.data;
158
+ if (!(!B?.type || typeof B.type != "string"))
159
+ switch (O.debug(`Message received: ${B.type}`), B.type) {
160
160
  // Embedded: parent forwards chat messages wrapped in AI_CHAT_MESSAGE
161
161
  case "AI_CHAT_MESSAGE": {
162
162
  if (a) {
163
- const P = I.payload;
163
+ const P = B.payload;
164
164
  P?.type && c(P.type, P.payload);
165
165
  }
166
166
  return;
@@ -177,7 +177,7 @@ function vt(e) {
177
177
  break;
178
178
  // Normal: direct chat protocol messages
179
179
  default:
180
- c(I.type, I.payload);
180
+ c(B.type, B.payload);
181
181
  break;
182
182
  }
183
183
  }
@@ -193,7 +193,7 @@ function vt(e) {
193
193
  O.warn("Cannot send message: iframe not available");
194
194
  return;
195
195
  }
196
- const w = i().allowedOrigins?.[0];
196
+ const w = r().allowedOrigins?.[0];
197
197
  if (!w || w === "*") {
198
198
  O.error(
199
199
  "Refusing to send to iframe: aiAgentConfig.allowedOrigins must contain an explicit origin. Message dropped to avoid leaking data (including access tokens) to arbitrary origins.",
@@ -208,7 +208,7 @@ function vt(e) {
208
208
  O.warn("Cannot send to parent: not in iframe");
209
209
  return;
210
210
  }
211
- const w = i().parentOrigin;
211
+ const w = r().parentOrigin;
212
212
  if (!w || w === "*") {
213
213
  O.error(
214
214
  "Refusing to send to parent: aiAgentConfig.parentOrigin must be an explicit origin. Message dropped to avoid leaking data (including access tokens) to arbitrary origins.",
@@ -236,66 +236,66 @@ function vt(e) {
236
236
  }
237
237
  };
238
238
  }
239
- const re = Z("ai-agent-service");
240
- function Ct(e) {
239
+ const ie = Z("ai-agent-service");
240
+ function mt(e) {
241
241
  const {
242
- userGetter: i,
242
+ userGetter: r,
243
243
  bladeGetter: a,
244
244
  localeGetter: t,
245
245
  tokenGetter: o,
246
246
  navigateToBlade: l,
247
247
  initialConfig: f,
248
248
  isEmbedded: g = !1
249
- } = e, h = D({ ...ct, ...f }), v = pt(), c = gt({
250
- userGetter: i,
249
+ } = e, h = D({ ...dt, ...f }), v = gt(), c = vt({
250
+ userGetter: r,
251
251
  bladeGetter: a,
252
252
  localeGetter: t,
253
253
  tokenGetter: o
254
- }), d = vt({
254
+ }), d = Ct({
255
255
  getConfig: () => h.value,
256
256
  isEmbedded: g,
257
257
  navigateToBlade: l,
258
258
  closePanel: () => v.close()
259
259
  }), u = b(() => ({
260
- user: i(),
260
+ user: r(),
261
261
  currentBlade: a(),
262
262
  items: c.contextItems.value
263
263
  })), w = async () => {
264
264
  if (d.pendingInitContext.value && d.iframeRef.value?.contentWindow) {
265
265
  d.pendingInitContext.value = !1, v.isInitialized.value = !0;
266
- const B = await c.buildInitPayload();
267
- d.sendToIframe({ type: "INIT_CONTEXT", payload: B }), re.debug("Flushed pending INIT_CONTEXT");
266
+ const I = await c.buildInitPayload();
267
+ d.sendToIframe({ type: "INIT_CONTEXT", payload: I }), ie.debug("Flushed pending INIT_CONTEXT");
268
268
  }
269
269
  };
270
270
  d.onChatReady(() => {
271
- d.iframeRef.value?.contentWindow ? (v.isInitialized.value = !0, c.buildInitPayload().then((B) => {
272
- d.sendToIframe({ type: "INIT_CONTEXT", payload: B }), re.info("Chatbot ready, sent INIT_CONTEXT");
273
- })) : (d.pendingInitContext.value = !0, re.info("Chatbot ready, iframe ref not available yet — pending INIT_CONTEXT"));
274
- }), z(d.iframeRef, () => w()), z(
271
+ d.iframeRef.value?.contentWindow ? (v.isInitialized.value = !0, c.buildInitPayload().then((I) => {
272
+ d.sendToIframe({ type: "INIT_CONTEXT", payload: I }), ie.info("Chatbot ready, sent INIT_CONTEXT");
273
+ })) : (d.pendingInitContext.value = !0, ie.info("Chatbot ready, iframe ref not available yet — pending INIT_CONTEXT"));
274
+ }), V(d.iframeRef, () => w()), V(
275
275
  () => ({ currentBlade: u.value.currentBlade, items: u.value.items }),
276
276
  async () => {
277
277
  if (g) {
278
- const B = await c.buildInitPayload();
279
- d.sendToParent({ type: "AI_CONTEXT_UPDATE", payload: B });
278
+ const I = await c.buildInitPayload();
279
+ d.sendToParent({ type: "AI_CONTEXT_UPDATE", payload: I });
280
280
  return;
281
281
  }
282
282
  if (v.isOpen.value && v.isInitialized.value && d.iframeRef.value?.contentWindow) {
283
- const B = await c.buildUpdatePayload();
284
- d.sendToIframe({ type: "UPDATE_CONTEXT", payload: B });
283
+ const I = await c.buildUpdatePayload();
284
+ d.sendToIframe({ type: "UPDATE_CONTEXT", payload: I });
285
285
  }
286
286
  },
287
287
  { deep: !0 }
288
288
  );
289
- const p = () => g ? d.sendToParent({ type: "AI_TOGGLE_PANEL" }) : v.open(), _ = () => g ? d.sendToParent({ type: "AI_TOGGLE_PANEL" }) : v.close(), I = () => g ? d.sendToParent({ type: "AI_TOGGLE_PANEL" }) : v.toggle(), P = (B) => {
290
- d.setIframeRef(B), w();
291
- }, L = (B, G, X, N) => {
292
- const { cleared: Y } = c.setContextData(B, G, X, N);
293
- g && Y && d.sendToParent({ type: "AI_CONTEXT_CLEAR" });
289
+ const p = () => g ? d.sendToParent({ type: "AI_TOGGLE_PANEL" }) : v.open(), _ = () => g ? d.sendToParent({ type: "AI_TOGGLE_PANEL" }) : v.close(), B = () => g ? d.sendToParent({ type: "AI_TOGGLE_PANEL" }) : v.toggle(), P = (I) => {
290
+ d.setIframeRef(I), w();
291
+ }, L = (I, G, X, Y) => {
292
+ const { cleared: N } = c.setContextData(I, G, X, Y);
293
+ g && N && d.sendToParent({ type: "AI_CONTEXT_CLEAR" });
294
294
  };
295
295
  return d.startListening(), g && (d.sendToParent({
296
296
  type: "EMBEDDED_APP_READY",
297
297
  payload: { supportedFeatures: ["ai-agent"] }
298
- }), re.info("Embedded mode: sent EMBEDDED_APP_READY to parent")), {
298
+ }), ie.info("Embedded mode: sent EMBEDDED_APP_READY to parent")), {
299
299
  // State
300
300
  panelState: v.panelState,
301
301
  config: h,
@@ -306,16 +306,16 @@ function Ct(e) {
306
306
  // Panel control
307
307
  openPanel: p,
308
308
  closePanel: _,
309
- togglePanel: I,
309
+ togglePanel: B,
310
310
  expandPanel: () => v.expand(),
311
311
  collapsePanel: () => v.collapse(),
312
312
  // Configuration
313
- setConfig: (B) => {
314
- h.value = { ...h.value, ...B };
313
+ setConfig: (I) => {
314
+ h.value = { ...h.value, ...I };
315
315
  },
316
316
  // Communication
317
- sendMessage: (B, G) => {
318
- d.sendToIframe({ type: B, payload: G });
317
+ sendMessage: (I, G) => {
318
+ d.sendToIframe({ type: I, payload: G });
319
319
  },
320
320
  onMessage: d.onMessage,
321
321
  // Internal API
@@ -326,19 +326,19 @@ function Ct(e) {
326
326
  _setContextData: L
327
327
  };
328
328
  }
329
- const mt = /* @__PURE__ */ new Set(["mod", "ctrl", "meta", "alt", "shift"]);
329
+ const ht = /* @__PURE__ */ new Set(["mod", "ctrl", "meta", "alt", "shift"]);
330
330
  function Me(e) {
331
331
  return new Proxy(
332
332
  {},
333
333
  {
334
- get(i, a) {
334
+ get(r, a) {
335
335
  if (!(typeof a != "string" || a === "then"))
336
- return mt.has(a) ? Me({ ...e, [a]: !0 }) : { key: a, ...e };
336
+ return ht.has(a) ? Me({ ...e, [a]: !0 }) : { key: a, ...e };
337
337
  }
338
338
  }
339
339
  );
340
340
  }
341
- const q = Me({}), ie = { ctrl: "⌃", alt: "⌥", shift: "⇧", meta: "⌘" }, se = { ctrl: "Ctrl", alt: "Alt", shift: "Shift", meta: "Meta" }, xe = {
341
+ const q = Me({}), re = { ctrl: "⌃", alt: "⌥", shift: "⇧", meta: "⌘" }, se = { ctrl: "Ctrl", alt: "Alt", shift: "Shift", meta: "Meta" }, xe = {
342
342
  escape: "Esc",
343
343
  enter: "Enter",
344
344
  tab: "Tab",
@@ -369,16 +369,16 @@ const q = Me({}), ie = { ctrl: "⌃", alt: "⌥", shift: "⇧", meta: "⌘" }, s
369
369
  comma: ",",
370
370
  slash: "/"
371
371
  };
372
- function ht(e) {
372
+ function _t(e) {
373
373
  return e in xe ? xe[e] : (e.length === 1, e.toUpperCase());
374
374
  }
375
- function _t(e) {
375
+ function Et(e) {
376
376
  return e in Be ? Be[e] : e.length === 1 ? e.toUpperCase() : e.charAt(0).toUpperCase() + e.slice(1);
377
377
  }
378
- function Fe(e, i) {
379
- const a = !!e.ctrl || !!e.mod && !i, t = !!e.meta || !!e.mod && i, o = [], l = [];
380
- i ? (a && o.push(ie.ctrl), e.alt && o.push(ie.alt), e.shift && o.push(ie.shift), t && o.push(ie.meta)) : (a && o.push(se.ctrl), t && o.push(se.meta), e.alt && o.push(se.alt), e.shift && o.push(se.shift)), a && l.push("Control"), t && l.push("Meta"), e.alt && l.push("Alt"), e.shift && l.push("Shift"), o.push(ht(e.key));
381
- const f = [...l, _t(e.key)].join("+");
378
+ function Fe(e, r) {
379
+ const a = !!e.ctrl || !!e.mod && !r, t = !!e.meta || !!e.mod && r, o = [], l = [];
380
+ r ? (a && o.push(re.ctrl), e.alt && o.push(re.alt), e.shift && o.push(re.shift), t && o.push(re.meta)) : (a && o.push(se.ctrl), t && o.push(se.meta), e.alt && o.push(se.alt), e.shift && o.push(se.shift)), a && l.push("Control"), t && l.push("Meta"), e.alt && l.push("Alt"), e.shift && l.push("Shift"), o.push(_t(e.key));
381
+ const f = [...l, Et(e.key)].join("+");
382
382
  return { parts: o, aria: f };
383
383
  }
384
384
  const Ie = {
@@ -398,35 +398,35 @@ const Ie = {
398
398
  arrowleft: "ArrowLeft",
399
399
  arrowright: "ArrowRight"
400
400
  };
401
- function Et(e) {
401
+ function bt(e) {
402
402
  return e.length === 1 && e >= "a" && e <= "z";
403
403
  }
404
- function bt(e) {
404
+ function wt(e) {
405
405
  return e.length === 1 && e >= "0" && e <= "9";
406
406
  }
407
- function wt(e) {
407
+ function At(e) {
408
408
  return /^f([1-9]|1[0-2])$/.test(e);
409
409
  }
410
- function At(e) {
411
- if (Et(e)) return `Key${e.toUpperCase()}`;
412
- if (bt(e)) return `Digit${e}`;
410
+ function yt(e) {
411
+ if (bt(e)) return `Key${e.toUpperCase()}`;
412
+ if (wt(e)) return `Digit${e}`;
413
413
  if (e in Ie) return Ie[e];
414
414
  }
415
- function yt(e) {
415
+ function xt(e) {
416
416
  if (e in Te) return Te[e];
417
- if (wt(e)) return e.toUpperCase();
417
+ if (At(e)) return e.toUpperCase();
418
418
  }
419
- function xt(e, i) {
420
- const a = At(e.key);
421
- if (a !== void 0) return i.code === a;
422
- const t = yt(e.key);
423
- return t !== void 0 ? i.key === t : !1;
419
+ function Bt(e, r) {
420
+ const a = yt(e.key);
421
+ if (a !== void 0) return r.code === a;
422
+ const t = xt(e.key);
423
+ return t !== void 0 ? r.key === t : !1;
424
424
  }
425
- function Bt(e, i, a) {
425
+ function It(e, r, a) {
426
426
  const t = !!e.ctrl || !!e.mod && !a, o = !!e.meta || !!e.mod && a, l = !!e.alt, f = !!e.shift;
427
- return i.ctrlKey !== t || i.metaKey !== o || i.altKey !== l || i.shiftKey !== f ? !1 : xt(e, i);
427
+ return r.ctrlKey !== t || r.metaKey !== o || r.altKey !== l || r.shiftKey !== f ? !1 : Bt(e, r);
428
428
  }
429
- const It = /* @__PURE__ */ new Set([
429
+ const Tt = /* @__PURE__ */ new Set([
430
430
  "button",
431
431
  "submit",
432
432
  "reset",
@@ -437,51 +437,51 @@ const It = /* @__PURE__ */ new Set([
437
437
  "range",
438
438
  "color"
439
439
  ]);
440
- function Bn() {
440
+ function In() {
441
441
  const e = document.activeElement;
442
442
  if (!e) return !1;
443
- const i = e.tagName;
444
- if (i === "INPUT") return !It.has(e.type);
445
- if (i === "TEXTAREA" || i === "SELECT" || e.isContentEditable === !0) return !0;
443
+ const r = e.tagName;
444
+ if (r === "INPUT") return !Tt.has(e.type);
445
+ if (r === "TEXTAREA" || r === "SELECT" || e.isContentEditable === !0) return !0;
446
446
  const a = e.getAttribute("contenteditable");
447
447
  return a === "true" || a === "";
448
448
  }
449
- function Tt() {
449
+ function kt() {
450
450
  return typeof navigator > "u" ? !1 : /Mac|iPhone|iPad|iPod/i.test(navigator.userAgent);
451
451
  }
452
452
  function Ne() {
453
- const e = Tt();
453
+ const e = kt();
454
454
  return {
455
455
  hotkey: q,
456
456
  isMac: e,
457
- formatShortcut: (i) => Fe(i, e)
457
+ formatShortcut: (r) => Fe(r, e)
458
458
  };
459
459
  }
460
- let kt, $e, Re, St;
461
- function In(e) {
462
- kt = e;
463
- }
460
+ let St, $e, Re, Ot;
464
461
  function Tn(e) {
465
- $e = e;
462
+ St = e;
466
463
  }
467
464
  function kn(e) {
468
- Re = e;
465
+ $e = e;
469
466
  }
470
467
  function Sn(e) {
471
- St = e;
468
+ Re = e;
472
469
  }
473
- const Ot = "useBlade() was called outside a blade. Navigation methods (openBlade) work everywhere, but blade-specific methods require the component to be rendered inside VcBladeSlot.";
470
+ function On(e) {
471
+ Ot = e;
472
+ }
473
+ const Pt = "useBlade() was called outside a blade. Navigation methods (openBlade) work everywhere, but blade-specific methods require the component to be rendered inside VcBladeSlot.";
474
474
  function y(e) {
475
475
  throw new Error(`[vc-shell] ${e} requires blade context.
476
- ${Ot}`);
476
+ ${Pt}`);
477
477
  }
478
- function Pt() {
479
- const e = (ne() ? M(Le, void 0) : void 0) ?? $e, i = (ne() ? M(je, void 0) : void 0) ?? Re;
480
- if (!e || !i)
478
+ function Lt() {
479
+ const e = (ne() ? M(Le, void 0) : void 0) ?? $e, r = (ne() ? M(Qe, void 0) : void 0) ?? Re;
480
+ if (!e || !r)
481
481
  throw new Error(
482
482
  "[vc-shell] useBlade() failed: BladeStack or BladeMessaging not available. Ensure BladeNavigationPlugin (plugin-v2) is installed."
483
483
  );
484
- const a = e, t = i, o = ne() ? M(Qe, void 0) : void 0, l = ne() ? M(Je, void 0) : void 0, f = b(() => (o || y("id"), o.value.id)), g = b(() => (o || y("param"), o.value.param)), h = b(() => (o || y("options"), o.value.options)), v = b(() => (o || y("query"), o.value.query)), c = b(() => (o || y("closable"), o.value.parentId !== void 0)), d = b(() => (o || y("expanded"), a.activeBlade.value?.id === o.value.id)), u = b(() => (o || y("name"), o.value.name)), w = b(() => {
484
+ const a = e, t = r, o = ne() ? M(Je, void 0) : void 0, l = ne() ? M(et, void 0) : void 0, f = b(() => (o || y("id"), o.value.id)), g = b(() => (o || y("param"), o.value.param)), h = b(() => (o || y("options"), o.value.options)), v = b(() => (o || y("query"), o.value.query)), c = b(() => (o || y("closable"), o.value.parentId !== void 0)), d = b(() => (o || y("expanded"), a.activeBlade.value?.id === o.value.id)), u = b(() => (o || y("name"), o.value.name)), w = b(() => {
485
485
  if (!o) return;
486
486
  const m = o.value.id;
487
487
  return a.blades.value.find((T) => T.parentId === m)?.param;
@@ -495,16 +495,16 @@ function Pt() {
495
495
  return;
496
496
  }
497
497
  p = !0;
498
- const T = We(m) ? m : D(m);
499
- ke(et, T);
498
+ const T = qe(m) ? m : D(m);
499
+ ke(tt, T);
500
500
  }
501
- async function I(m) {
502
- const { isWorkspace: T, ...U } = m;
501
+ async function B(m) {
502
+ const { isWorkspace: T, ...j } = m;
503
503
  if (T)
504
- await a.openWorkspace(U);
504
+ await a.openWorkspace(j);
505
505
  else {
506
- const te = o?.value.id;
507
- te ? await a.openBlade({ ...U, parentId: te }) : await a.openBlade(U);
506
+ const z = o?.value.id;
507
+ z ? await a.openBlade({ ...j, parentId: z }) : await a.openBlade(j);
508
508
  }
509
509
  }
510
510
  async function P() {
@@ -513,7 +513,7 @@ function Pt() {
513
513
  async function L() {
514
514
  o || y("closeChildren()"), await a.closeChildren(o.value.id);
515
515
  }
516
- async function B(m) {
516
+ async function I(m) {
517
517
  o || y("replaceWith()"), await a.replaceCurrentBlade({
518
518
  ...m,
519
519
  parentId: o.value.parentId
@@ -528,10 +528,10 @@ function Pt() {
528
528
  async function X(m, T) {
529
529
  return o || y("callParent()"), t.callParent(o.value.id, m, T);
530
530
  }
531
- function N(m) {
531
+ function Y(m) {
532
532
  o || y("exposeToChildren()"), t.exposeToChildren(o.value.id, m);
533
533
  }
534
- function Y(m) {
534
+ function N(m) {
535
535
  o || y("onBeforeClose()"), a.registerBeforeClose(o.value.id, m);
536
536
  }
537
537
  function de(m) {
@@ -550,28 +550,28 @@ function Pt() {
550
550
  dismissible: m.dismissible ?? !1
551
551
  }), T;
552
552
  }
553
- function Q(m) {
553
+ function ge(m) {
554
554
  l || y("removeBanner()"), l.value = l.value.filter((T) => T.id !== m);
555
555
  }
556
- function ge() {
556
+ function J() {
557
557
  l || y("clearBanners()"), l.value = l.value.filter((m) => m._system);
558
558
  }
559
- let J = !1, ee = !1;
559
+ let ee = !1, te = !1;
560
560
  function ve(m) {
561
- if (o || y("onActivated()"), J) {
561
+ if (o || y("onActivated()"), ee) {
562
562
  console.warn("[useBlade] onActivated() already registered in this blade.");
563
563
  return;
564
564
  }
565
- J = !0, z(d, (T) => {
565
+ ee = !0, V(d, (T) => {
566
566
  T && m();
567
567
  });
568
568
  }
569
569
  function Ce(m) {
570
- if (o || y("onDeactivated()"), ee) {
570
+ if (o || y("onDeactivated()"), te) {
571
571
  console.warn("[useBlade] onDeactivated() already registered in this blade.");
572
572
  return;
573
573
  }
574
- ee = !0, z(d, (T) => {
574
+ te = !0, V(d, (T) => {
575
575
  T || m();
576
576
  });
577
577
  }
@@ -585,35 +585,35 @@ function Pt() {
585
585
  expanded: d,
586
586
  name: u,
587
587
  provideBladeData: _,
588
- openBlade: I,
588
+ openBlade: B,
589
589
  closeSelf: P,
590
590
  closeChildren: L,
591
- replaceWith: B,
591
+ replaceWith: I,
592
592
  coverWith: G,
593
593
  callParent: X,
594
- exposeToChildren: N,
595
- onBeforeClose: Y,
594
+ exposeToChildren: Y,
595
+ onBeforeClose: N,
596
596
  onActivated: ve,
597
597
  onDeactivated: Ce,
598
598
  setError: de,
599
599
  clearError: ue,
600
600
  addBanner: pe,
601
- removeBanner: Q,
602
- clearBanners: ge
601
+ removeBanner: ge,
602
+ clearBanners: J
603
603
  };
604
604
  }
605
- function Lt(e, i) {
605
+ function Dt(e, r) {
606
606
  return {
607
- id: i.generateId(),
607
+ id: r.generateId(),
608
608
  name: e.name,
609
- url: i.resolveUrl(e.name),
609
+ url: r.resolveUrl(e.name),
610
610
  // workspace blades don't have param when opened first
611
611
  query: e.query,
612
612
  options: e.options,
613
613
  visible: !0
614
614
  };
615
615
  }
616
- function Dt(e, i, a) {
616
+ function Mt(e, r, a) {
617
617
  return {
618
618
  id: a.generateId(),
619
619
  name: e.name,
@@ -621,11 +621,11 @@ function Dt(e, i, a) {
621
621
  param: e.param,
622
622
  query: e.query,
623
623
  options: e.options,
624
- parentId: i,
624
+ parentId: r,
625
625
  visible: !0
626
626
  };
627
627
  }
628
- function Mt(e, i, a) {
628
+ function Ft(e, r, a) {
629
629
  return {
630
630
  id: a.generateId(),
631
631
  name: e.name,
@@ -633,11 +633,11 @@ function Mt(e, i, a) {
633
633
  param: e.param,
634
634
  query: e.query,
635
635
  options: e.options,
636
- parentId: i,
636
+ parentId: r,
637
637
  visible: !0
638
638
  };
639
639
  }
640
- function Ft(e, i, a) {
640
+ function Nt(e, r, a) {
641
641
  return {
642
642
  id: a.generateId(),
643
643
  name: e.name,
@@ -645,15 +645,15 @@ function Ft(e, i, a) {
645
645
  param: e.param,
646
646
  query: e.query,
647
647
  options: e.options,
648
- parentId: i,
648
+ parentId: r,
649
649
  visible: !0
650
650
  };
651
651
  }
652
- let Nt = 0;
653
- function $t() {
654
- return `blade_${++Nt}_${Math.random().toString(36).slice(2, 8)}`;
652
+ let $t = 0;
653
+ function Rt() {
654
+ return `blade_${++$t}_${Math.random().toString(36).slice(2, 8)}`;
655
655
  }
656
- function On(e, i, a = tt) {
656
+ function Pn(e, r, a = nt) {
657
657
  const t = D([]), o = /* @__PURE__ */ new Map(), l = /* @__PURE__ */ new Map(), f = /* @__PURE__ */ new Map(), g = /* @__PURE__ */ new Map(), h = b(() => t.value[0]), v = b(() => t.value), c = b(() => {
658
658
  for (let n = t.value.length - 1; n >= 0; n--)
659
659
  if (t.value[n].visible) return t.value[n];
@@ -662,59 +662,63 @@ function On(e, i, a = tt) {
662
662
  o.delete(n), l.delete(n), f.delete(n), g.delete(n);
663
663
  }
664
664
  function u(n) {
665
- const r = e.getBlade(n);
666
- if (r)
667
- return r.route;
665
+ const i = e.getBlade(n);
666
+ if (i)
667
+ return i.route;
668
668
  }
669
669
  const w = {
670
- generateId: $t,
670
+ generateId: Rt,
671
671
  resolveUrl: u
672
672
  };
673
673
  async function p(n) {
674
- for (let r = n.length - 1; r >= 0; r--) {
675
- const s = o.get(n[r].id);
674
+ for (let i = n.length - 1; i >= 0; i--) {
675
+ const s = o.get(n[i].id);
676
676
  if (s && await s())
677
677
  return !0;
678
678
  }
679
679
  return !1;
680
680
  }
681
681
  function _(n) {
682
- for (const r of n)
683
- f.get(r.id)?.(), d(r.id);
682
+ for (const i of n)
683
+ f.get(i.id)?.(), d(i.id);
684
684
  }
685
- async function I(n) {
685
+ function B(n) {
686
+ for (const [i, s] of g)
687
+ i !== n && (s.value = !1);
688
+ }
689
+ async function P(n) {
686
690
  if (h.value?.name === n.name) return !1;
687
691
  const s = e.getBlade(n.name);
688
692
  if (!s)
689
693
  throw new Error(`[BladeStack] Blade '${n.name}' not found in registry`);
690
- if (i && s.permissions && !i(s.permissions))
694
+ if (r && s.permissions && !r(s.permissions))
691
695
  return console.warn(`[BladeStack] Access denied to workspace '${n.name}'`), !1;
692
696
  _([...t.value]);
693
- const C = Lt(n, w);
697
+ const C = Dt(n, w);
694
698
  return t.value = [C], n.onOpen && l.set(C.id, n.onOpen), n.onClose && f.set(C.id, n.onClose), n.onOpen?.(), !0;
695
699
  }
696
- async function P(n) {
700
+ async function L(n) {
697
701
  if (!e.getBlade(n.name))
698
702
  throw new Error(`[BladeStack] Blade '${n.name}' not found in registry`);
699
- const r = n.parentId ?? c.value?.id ?? h.value?.id;
700
- if (!r)
703
+ const i = n.parentId ?? c.value?.id ?? h.value?.id;
704
+ if (!i)
701
705
  throw new Error("[BladeStack] Cannot open blade: no parent blade found");
702
- const s = t.value.findIndex((S) => S.id === r);
706
+ const s = t.value.findIndex((S) => S.id === i);
703
707
  if (s === -1)
704
- throw new Error(`[BladeStack] Parent blade '${r}' not found in stack`);
708
+ throw new Error(`[BladeStack] Parent blade '${i}' not found in stack`);
705
709
  const C = t.value.slice(s + 1);
706
710
  if (C.length > 0 && await p(C))
707
711
  return !1;
708
- _(C);
709
- const E = Dt(n, r, w);
712
+ _(C), B();
713
+ const E = Mt(n, i, w);
710
714
  return t.value = [...t.value.slice(0, s + 1), E], n.onOpen && l.set(E.id, n.onOpen), n.onClose && f.set(E.id, n.onClose), n.onOpen?.(), !0;
711
715
  }
712
- async function L(n) {
713
- const r = t.value.findIndex((S) => S.id === n);
714
- if (r === -1 || r === 0) return "refused";
715
- const s = t.value.slice(r);
716
+ async function I(n) {
717
+ const i = t.value.findIndex((S) => S.id === n);
718
+ if (i === -1 || i === 0) return "refused";
719
+ const s = t.value.slice(i);
716
720
  if (await p(s)) return "prevented";
717
- _(s), t.value = t.value.slice(0, r);
721
+ _(s), t.value = t.value.slice(0, i);
718
722
  const E = t.value.length - 1;
719
723
  if (E > 0 && !t.value[E].visible) {
720
724
  const S = [...t.value];
@@ -722,168 +726,170 @@ function On(e, i, a = tt) {
722
726
  }
723
727
  return "closed";
724
728
  }
725
- async function B(n) {
726
- const r = c.value;
727
- if (!r)
729
+ async function G(n) {
730
+ const i = c.value;
731
+ if (!i)
728
732
  throw new Error("[BladeStack] No active blade to replace");
729
733
  if (!e.getBlade(n.name))
730
734
  throw new Error(`[BladeStack] Blade '${n.name}' not found in registry`);
731
- const s = t.value.findIndex(($) => $.id === r.id);
735
+ const s = t.value.findIndex(($) => $.id === i.id);
732
736
  if (s === -1)
733
- throw new Error(`[BladeStack] Active blade '${r.id}' not found in stack`);
737
+ throw new Error(`[BladeStack] Active blade '${i.id}' not found in stack`);
734
738
  const C = t.value.slice(s + 1);
735
739
  if (C.length > 0) {
736
740
  if (await p(C)) return !1;
737
741
  _(C);
738
742
  }
739
- const E = Mt(n, r.parentId, w);
740
- _([r]);
743
+ const E = Ft(n, i.parentId, w);
744
+ B(), _([i]);
741
745
  const S = [...t.value.slice(0, s), E, ...t.value.slice(s + 1)];
742
746
  return t.value = S, n.onOpen && l.set(E.id, n.onOpen), n.onClose && f.set(E.id, n.onClose), n.onOpen?.(), !0;
743
747
  }
744
- async function G(n) {
745
- const r = c.value;
746
- if (!r)
748
+ async function X(n) {
749
+ const i = c.value;
750
+ if (!i)
747
751
  throw new Error("[BladeStack] No active blade to cover");
748
752
  if (!e.getBlade(n.name))
749
753
  throw new Error(`[BladeStack] Blade '${n.name}' not found in registry`);
750
- const s = t.value.findIndex(($) => $.id === r.id);
754
+ const s = t.value.findIndex(($) => $.id === i.id);
751
755
  if (s === -1)
752
- throw new Error(`[BladeStack] Active blade '${r.id}' not found in stack`);
756
+ throw new Error(`[BladeStack] Active blade '${i.id}' not found in stack`);
753
757
  const C = t.value.slice(s + 1);
754
758
  if (C.length > 0) {
755
759
  if (await p(C)) return !1;
756
760
  _(C);
757
761
  }
758
- const E = Ft(n, r.id, w), S = t.value.slice(0, s);
759
- return S.push({ ...r, visible: !1 }), S.push(E), t.value = S, n.onOpen && l.set(E.id, n.onOpen), n.onClose && f.set(E.id, n.onClose), n.onOpen?.(), !0;
762
+ const E = Nt(n, i.id, w);
763
+ B(i.id);
764
+ const S = t.value.slice(0, s);
765
+ return S.push({ ...i, visible: !1 }), S.push(E), t.value = S, n.onOpen && l.set(E.id, n.onOpen), n.onClose && f.set(E.id, n.onClose), n.onOpen?.(), !0;
760
766
  }
761
- async function X(n) {
762
- const r = t.value.findIndex((E) => E.id === n);
763
- if (r === -1) return !1;
764
- const s = t.value.slice(r + 1);
765
- return s.length === 0 || await p(s) ? !1 : (_(s), t.value = t.value.slice(0, r + 1), !0);
767
+ async function Y(n) {
768
+ const i = t.value.findIndex((E) => E.id === n);
769
+ if (i === -1) return !1;
770
+ const s = t.value.slice(i + 1);
771
+ return s.length === 0 || await p(s) ? !1 : (_(s), t.value = t.value.slice(0, i + 1), !0);
766
772
  }
767
773
  function N(n) {
768
774
  c.value?.url && a[n]();
769
775
  }
770
- async function Y(n) {
771
- await I(n) && N("push");
772
- }
773
776
  async function de(n) {
774
777
  await P(n) && N("push");
775
778
  }
776
779
  async function ue(n) {
777
- await B(n) && N("replace");
780
+ await L(n) && N("push");
778
781
  }
779
782
  async function fe(n) {
780
- await G(n) && N("push");
783
+ await G(n) && N("replace");
781
784
  }
782
785
  async function pe(n) {
783
- const r = await L(n);
784
- return r === "closed" && a.replace(), r === "prevented";
786
+ await X(n) && N("push");
787
+ }
788
+ async function ge(n) {
789
+ const i = await I(n);
790
+ return i === "closed" && a.replace(), i === "prevented";
785
791
  }
786
- async function Q(n) {
787
- await X(n) && a.replace();
792
+ async function J(n) {
793
+ await Y(n) && a.replace();
788
794
  }
789
- function ge(n, r) {
790
- o.set(n, r);
795
+ function ee(n, i) {
796
+ o.set(n, i);
791
797
  }
792
- function J(n) {
798
+ function te(n) {
793
799
  o.delete(n);
794
800
  }
795
- function ee(n, r) {
801
+ function ve(n, i) {
796
802
  const s = t.value.findIndex((E) => E.id === n);
797
803
  if (s === -1) return;
798
804
  const C = [...t.value];
799
- C[s] = { ...C[s], error: r }, t.value = C;
805
+ C[s] = { ...C[s], error: i }, t.value = C;
800
806
  }
801
- function ve(n) {
802
- const r = t.value.findIndex((C) => C.id === n);
803
- if (r === -1) return;
807
+ function Ce(n) {
808
+ const i = t.value.findIndex((C) => C.id === n);
809
+ if (i === -1) return;
804
810
  const s = [...t.value];
805
- s[r] = { ...s[r], error: void 0 }, t.value = s;
811
+ s[i] = { ...s[i], error: void 0 }, t.value = s;
806
812
  }
807
- function Ce(n, r) {
813
+ function m(n, i) {
808
814
  const s = t.value.findIndex((E) => E.id === n);
809
- if (s === -1 || t.value[s].title === r) return;
815
+ if (s === -1 || t.value[s].title === i) return;
810
816
  const C = [...t.value];
811
- C[s] = { ...C[s], title: r }, t.value = C;
817
+ C[s] = { ...C[s], title: i }, t.value = C;
812
818
  }
813
- function m(n) {
814
- const r = t.value.findIndex((s) => s.id === n);
815
- return r === -1 ? [] : t.value.slice(0, r).filter((s) => s.visible).map((s) => ({
819
+ function T(n) {
820
+ const i = t.value.findIndex((s) => s.id === n);
821
+ return i === -1 ? [] : t.value.slice(0, i).filter((s) => s.visible).map((s) => ({
816
822
  id: s.id,
817
823
  title: s.title ?? s.name,
818
824
  clickHandler: async (C) => {
819
- await Q(C);
825
+ await J(C);
820
826
  }
821
827
  }));
822
828
  }
823
- function T(n, r) {
824
- const s = t.value.findIndex((K) => K.id === n);
829
+ function j(n, i) {
830
+ const s = t.value.findIndex((U) => U.id === n);
825
831
  if (s === -1) return;
826
832
  const C = t.value[s].query ?? {}, E = { ...C };
827
- for (const [K, he] of Object.entries(r))
828
- he === "" || he == null ? delete E[K] : E[K] = he;
833
+ for (const [U, he] of Object.entries(i))
834
+ he === "" || he == null ? delete E[U] : E[U] = he;
829
835
  const S = Object.keys(C), $ = Object.keys(E);
830
- if (S.length === $.length && $.every((K) => C[K] === E[K]))
836
+ if (S.length === $.length && $.every((U) => C[U] === E[U]))
831
837
  return;
832
838
  const me = [...t.value];
833
839
  me[s] = { ...me[s], query: E }, t.value = me;
834
840
  }
835
- function U(n) {
836
- let r = g.get(n);
837
- return r || (r = D(!1), g.set(n, r)), r;
841
+ function z(n) {
842
+ let i = g.get(n);
843
+ return i || (i = D(!1), g.set(n, i)), i;
838
844
  }
839
- function te(n) {
845
+ function Ue(n) {
840
846
  return g.get(n)?.value ?? !1;
841
847
  }
842
- function Ue(n, r) {
843
- U(n).value = r;
844
- }
845
- function Ke(n) {
846
- const r = U(n);
847
- r.value = !r.value;
848
+ function Ke(n, i) {
849
+ z(n).value = i;
848
850
  }
849
851
  function Ve(n) {
850
- for (const r of t.value)
851
- d(r.id);
852
+ const i = z(n);
853
+ i.value = !i.value;
854
+ }
855
+ function ze(n) {
856
+ for (const i of t.value)
857
+ d(i.id);
852
858
  t.value = n;
853
859
  }
854
860
  return {
855
861
  workspace: h,
856
862
  blades: v,
857
863
  activeBlade: c,
858
- openWorkspace: Y,
859
- openBlade: de,
860
- closeBlade: pe,
861
- closeChildren: Q,
862
- replaceCurrentBlade: ue,
863
- coverCurrentBlade: fe,
864
- registerBeforeClose: ge,
865
- unregisterBeforeClose: J,
866
- setBladeError: ee,
867
- clearBladeError: ve,
868
- setBladeTitle: Ce,
869
- trailFor: m,
870
- updateBladeQuery: T,
871
- getMaximizedRef: U,
872
- isMaximized: te,
873
- setMaximized: Ue,
874
- toggleMaximized: Ke,
875
- _restoreStack: Ve
864
+ openWorkspace: de,
865
+ openBlade: ue,
866
+ closeBlade: ge,
867
+ closeChildren: J,
868
+ replaceCurrentBlade: fe,
869
+ coverCurrentBlade: pe,
870
+ registerBeforeClose: ee,
871
+ unregisterBeforeClose: te,
872
+ setBladeError: ve,
873
+ clearBladeError: Ce,
874
+ setBladeTitle: m,
875
+ trailFor: T,
876
+ updateBladeQuery: j,
877
+ getMaximizedRef: z,
878
+ isMaximized: Ue,
879
+ setMaximized: Ke,
880
+ toggleMaximized: Ve,
881
+ _restoreStack: ze
876
882
  };
877
883
  }
878
- function Rt() {
884
+ function Gt() {
879
885
  const e = M(Le);
880
886
  if (!e)
881
887
  throw new Error("[useBladeStack] BladeStack not found. Ensure BladeNavigationPlugin is installed.");
882
888
  return e;
883
889
  }
884
890
  const W = Z("use-ai-agent");
885
- function Pn(e) {
886
- const i = M(nt), { user: a, getAccessToken: t } = at(), { openBlade: o } = Pt(), { blades: l, activeBlade: f } = Rt(), g = e?.isEmbedded, h = Ct({
891
+ function Ln(e) {
892
+ const r = M(at), { user: a, getAccessToken: t } = ot(), { openBlade: o } = Lt(), { blades: l, activeBlade: f } = Gt(), g = e?.isEmbedded, h = mt({
887
893
  userGetter: () => {
888
894
  if (a.value)
889
895
  return {
@@ -903,7 +909,7 @@ function Pn(e) {
903
909
  options: c.options
904
910
  } : null;
905
911
  },
906
- localeGetter: () => i?.currentLocale.value ?? "en",
912
+ localeGetter: () => r?.currentLocale.value ?? "en",
907
913
  tokenGetter: t,
908
914
  navigateToBlade: (c, d, u) => {
909
915
  o({ name: c, param: d, options: u }).then(() => {
@@ -916,12 +922,12 @@ function Pn(e) {
916
922
  isEmbedded: g
917
923
  });
918
924
  if (ke(be, h), W.debug("AiAgentService provided"), e?.addGlobalToolbarButton ?? !0) {
919
- const c = M(ot, null);
925
+ const c = M(it, null);
920
926
  c ? (c.registerToolbarItem(
921
927
  {
922
- id: dt,
923
- icon: ut,
924
- title: ft,
928
+ id: ut,
929
+ icon: ft,
930
+ title: pt,
925
931
  shortcut: q.mod.i,
926
932
  clickHandler: () => {
927
933
  h.togglePanel();
@@ -933,7 +939,7 @@ function Pn(e) {
933
939
  }
934
940
  return h;
935
941
  }
936
- function Ln() {
942
+ function Dn() {
937
943
  const e = M(be);
938
944
  if (!e) {
939
945
  W.error("AiAgentService not found. Did you forget to call provideAiAgentService()?");
@@ -960,7 +966,7 @@ function Ln() {
960
966
  onMessage: e.onMessage
961
967
  };
962
968
  }
963
- function Dn(e) {
969
+ function Mn(e) {
964
970
  return {
965
971
  id: "ai-agent-toggle",
966
972
  icon: e?.icon ?? "lucide-sparkles",
@@ -970,11 +976,11 @@ function Dn(e) {
970
976
  }
971
977
  };
972
978
  }
973
- const Gt = ["width", "height"], Ut = ["clip-path"], Kt = {
979
+ const Ut = ["width", "height"], Kt = ["clip-path"], Vt = {
974
980
  key: 1,
975
981
  d: "M72.9199 46.4165C73.2527 46.9495 73.5831 47.4996 73.9092 48.0679C78.4022 55.8976 79.0605 66.3551 76.7793 76.6079C74.5635 86.5668 69.6096 96.1504 62.9795 102.692L58.1514 105.48C52.5725 108.701 45.699 108.701 40.1201 105.48L21.665 94.8247C29.1398 95.4723 37.0781 94.4072 44.3848 91.9233C54.5984 88.4512 63.7463 82.1497 68.6807 73.6548C75.124 62.5619 75.4351 53.2694 72.9199 46.4165ZM56.5205 29.5093C65.5697 29.5331 75.1259 33.9964 83.0215 40.8853C89.9848 46.9608 95.5441 54.8286 98.2715 62.9478V71.9058C98.2715 78.3478 94.8348 84.301 89.2559 87.522L69.4658 98.9468C74.0688 92.6731 77.4601 84.9996 79.207 77.1479C81.5723 66.517 80.9666 55.3703 76.0654 46.8296C69.6817 35.7054 61.7917 30.789 54.6006 29.5396C55.2271 29.5179 55.867 29.5076 56.5205 29.5093ZM0 50.688C3.16812 57.476 8.04614 63.7935 13.8389 68.853C21.9305 75.9204 31.9368 80.6465 41.7578 80.6724C54.5833 80.706 62.7851 76.3308 67.4629 70.728C67.1684 71.2812 66.8584 71.8408 66.5303 72.4058C61.9844 80.2318 53.417 86.2251 43.584 89.5679C34.4355 92.6779 24.3375 93.4401 15.6328 91.3423L9.01562 87.522C3.43667 84.301 0 78.3478 0 71.9058V50.688ZM26.7559 10.1313C22.5672 16.2131 19.6599 23.483 18.2695 30.9126C16.3077 41.3962 17.3358 52.3558 22.2188 60.8647C28.6034 71.9905 36.4946 76.9061 43.6865 78.1548C43.0594 78.1765 42.4188 78.1868 41.7646 78.1851C32.7113 78.1612 23.2602 73.7801 15.4746 66.98C8.2197 60.6434 2.52684 52.3035 0 43.7075V35.9897C6.33247e-05 29.5479 3.43687 23.5955 9.01562 20.3745L26.7559 10.1313ZM51.2432 31.6978C54.0287 31.7659 57.0796 32.4389 60.1875 33.9976C58.8529 33.7029 57.5584 33.677 56.3965 33.9722L57.0088 36.3833C58.4774 36.0102 60.6741 36.4134 63.0332 37.8237C65.3553 39.212 67.6865 41.4953 69.375 44.5923C70.7081 47.0376 71.6489 50.015 71.8535 53.4839C71.4414 52.1828 70.818 51.0505 69.9824 50.1929L68.2012 51.9282C69.2585 53.0135 70.0076 55.1176 69.9658 57.8657C69.9246 60.5708 69.1121 63.731 67.2744 66.7417C65.8225 69.1203 63.7129 71.4251 60.8086 73.3374C61.7311 72.329 62.4012 71.2217 62.7266 70.0679L60.333 69.3931C59.9218 70.8514 58.4742 72.5523 56.0732 73.8901C53.71 75.207 50.5672 76.0837 47.041 75.9976C44.2551 75.9294 41.204 75.2549 38.0957 73.6958C39.4307 73.9907 40.7254 74.0184 41.8877 73.7231L41.2754 71.312C39.8069 71.6851 37.6101 71.2818 35.251 69.8716C32.9289 68.4834 30.5977 66.2 28.9092 63.103C27.5754 60.6565 26.6337 57.6775 26.4297 54.2065C26.8418 55.5096 27.4661 56.6438 28.3027 57.5024L30.084 55.7661C29.0267 54.6807 28.2775 52.5767 28.3193 49.8286C28.3606 47.1236 29.173 43.9633 31.0107 40.9526C32.4621 38.5751 34.5702 36.2706 37.4727 34.3589C36.5514 35.3666 35.8827 36.4736 35.5576 37.6265L37.9512 38.3013C38.3625 36.8429 39.8101 35.142 42.2109 33.8042C44.5742 32.4874 47.717 31.6116 51.2432 31.6978ZM40.1201 2.4165C45.6991 -0.804509 52.5724 -0.804509 58.1514 2.4165L75.6777 12.5356C68.4683 12.0708 60.8765 13.1991 53.8691 15.6333C43.6671 19.1774 34.5353 25.5492 29.6035 34.0396C23.1612 45.1305 22.8486 54.4223 25.3623 61.2749C25.0301 60.7429 24.7004 60.1936 24.375 59.6265C19.8639 51.765 18.8286 41.4457 20.7139 31.3706C22.4486 22.1007 26.633 13.1734 32.6709 6.71631L40.1201 2.4165ZM54.6855 17.9829C63.3703 14.966 72.9092 14.0715 81.3008 15.7817L89.2559 20.3745C94.8346 23.5955 98.2714 29.5479 98.2715 35.9897V56.4692C95.0606 49.9731 90.2759 43.9144 84.6562 39.0112C76.4636 31.8632 66.3524 27.0488 56.5273 27.0229C43.6978 26.9893 35.4935 31.3659 30.8164 36.9712C31.1117 36.4161 31.4247 35.8554 31.7539 35.2886C36.3024 27.4582 44.8633 21.395 54.6855 17.9829Z",
976
982
  fill: "url(#virto-oz-gradient-animated)"
977
- }, Vt = ["id"], zt = {
983
+ }, zt = ["id"], Wt = {
978
984
  key: 1,
979
985
  id: "virto-oz-gradient-animated",
980
986
  gradientUnits: "userSpaceOnUse",
@@ -990,7 +996,7 @@ const Gt = ["width", "height"], Ut = ["clip-path"], Kt = {
990
996
  animated: { type: Boolean, default: !1 }
991
997
  },
992
998
  setup(e) {
993
- const i = b(() => `virto-oz-clip-${Math.random().toString(36).substring(2, 11)}`);
999
+ const r = b(() => `virto-oz-clip-${Math.random().toString(36).substring(2, 11)}`);
994
1000
  return (a, t) => (A(), k("svg", {
995
1001
  width: e.width,
996
1002
  height: e.height,
@@ -1003,9 +1009,9 @@ const Gt = ["width", "height"], Ut = ["clip-path"], Kt = {
1003
1009
  d: "M40.1199 2.41576C45.6989 -0.805254 52.5724 -0.805253 58.1514 2.41576L89.2556 20.3738C94.8345 23.5948 98.2713 29.5475 98.2713 35.9895V71.9055C98.2713 78.3475 94.8345 84.3002 89.2556 87.5212L58.1514 105.479C52.5724 108.7 45.6989 108.7 40.1199 105.479L9.01574 87.5212C3.43678 84.3002 0 78.3475 0 71.9055V35.9895C0 29.5475 3.43678 23.5948 9.01574 20.3738L40.1199 2.41576Z",
1004
1010
  fill: "white"
1005
1011
  }, null, -1)),
1006
- e.animated ? (A(), k("path", Kt)) : (A(), k("g", {
1012
+ e.animated ? (A(), k("path", Vt)) : (A(), k("g", {
1007
1013
  key: 0,
1008
- "clip-path": `url(#${i.value})`
1014
+ "clip-path": `url(#${r.value})`
1009
1015
  }, [...t[0] || (t[0] = [
1010
1016
  x("g", { transform: "matrix(0 -0.161514 0.160417 0 49.1357 53.9479)" }, [
1011
1017
  x("foreignObject", {
@@ -1028,7 +1034,7 @@ const Gt = ["width", "height"], Ut = ["clip-path"], Kt = {
1028
1034
  })
1029
1035
  ])
1030
1036
  ], -1)
1031
- ])], 8, Ut)),
1037
+ ])], 8, Kt)),
1032
1038
  t[4] || (t[4] = x("path", {
1033
1039
  d: "M72.1266 54.0945C72.1266 60.0873 74.3028 71.0379 60.6238 82.8517C65.2871 73.0587 55.8339 77.1002 49.1209 77.1002C36.4152 77.1002 26.1152 66.8002 26.1152 54.0945C26.1152 41.3889 36.4152 31.0889 49.1209 31.0889C61.8266 31.0889 72.1266 41.3889 72.1266 54.0945Z",
1034
1040
  fill: "white"
@@ -1057,70 +1063,70 @@ const Gt = ["width", "height"], Ut = ["clip-path"], Kt = {
1057
1063
  x("defs", null, [
1058
1064
  e.animated ? H("", !0) : (A(), k("clipPath", {
1059
1065
  key: 0,
1060
- id: i.value
1066
+ id: r.value
1061
1067
  }, [...t[1] || (t[1] = [
1062
1068
  x("path", { d: "M72.9199 46.4165C73.2527 46.9495 73.5831 47.4996 73.9092 48.0679C78.4022 55.8976 79.0605 66.3551 76.7793 76.6079C74.5635 86.5668 69.6096 96.1504 62.9795 102.692L58.1514 105.48C52.5725 108.701 45.699 108.701 40.1201 105.48L21.665 94.8247C29.1398 95.4723 37.0781 94.4072 44.3848 91.9233C54.5984 88.4512 63.7463 82.1497 68.6807 73.6548C75.124 62.5619 75.4351 53.2694 72.9199 46.4165ZM56.5205 29.5093C65.5697 29.5331 75.1259 33.9964 83.0215 40.8853C89.9848 46.9608 95.5441 54.8286 98.2715 62.9478V71.9058C98.2715 78.3478 94.8348 84.301 89.2559 87.522L69.4658 98.9468C74.0688 92.6731 77.4601 84.9996 79.207 77.1479C81.5723 66.517 80.9666 55.3703 76.0654 46.8296C69.6817 35.7054 61.7917 30.789 54.6006 29.5396C55.2271 29.5179 55.867 29.5076 56.5205 29.5093ZM0 50.688C3.16812 57.476 8.04614 63.7935 13.8389 68.853C21.9305 75.9204 31.9368 80.6465 41.7578 80.6724C54.5833 80.706 62.7851 76.3308 67.4629 70.728C67.1684 71.2812 66.8584 71.8408 66.5303 72.4058C61.9844 80.2318 53.417 86.2251 43.584 89.5679C34.4355 92.6779 24.3375 93.4401 15.6328 91.3423L9.01562 87.522C3.43667 84.301 0 78.3478 0 71.9058V50.688ZM26.7559 10.1313C22.5672 16.2131 19.6599 23.483 18.2695 30.9126C16.3077 41.3962 17.3358 52.3558 22.2188 60.8647C28.6034 71.9905 36.4946 76.9061 43.6865 78.1548C43.0594 78.1765 42.4188 78.1868 41.7646 78.1851C32.7113 78.1612 23.2602 73.7801 15.4746 66.98C8.2197 60.6434 2.52684 52.3035 0 43.7075V35.9897C6.33247e-05 29.5479 3.43687 23.5955 9.01562 20.3745L26.7559 10.1313ZM51.2432 31.6978C54.0287 31.7659 57.0796 32.4389 60.1875 33.9976C58.8529 33.7029 57.5584 33.677 56.3965 33.9722L57.0088 36.3833C58.4774 36.0102 60.6741 36.4134 63.0332 37.8237C65.3553 39.212 67.6865 41.4953 69.375 44.5923C70.7081 47.0376 71.6489 50.015 71.8535 53.4839C71.4414 52.1828 70.818 51.0505 69.9824 50.1929L68.2012 51.9282C69.2585 53.0135 70.0076 55.1176 69.9658 57.8657C69.9246 60.5708 69.1121 63.731 67.2744 66.7417C65.8225 69.1203 63.7129 71.4251 60.8086 73.3374C61.7311 72.329 62.4012 71.2217 62.7266 70.0679L60.333 69.3931C59.9218 70.8514 58.4742 72.5523 56.0732 73.8901C53.71 75.207 50.5672 76.0837 47.041 75.9976C44.2551 75.9294 41.204 75.2549 38.0957 73.6958C39.4307 73.9907 40.7254 74.0184 41.8877 73.7231L41.2754 71.312C39.8069 71.6851 37.6101 71.2818 35.251 69.8716C32.9289 68.4834 30.5977 66.2 28.9092 63.103C27.5754 60.6565 26.6337 57.6775 26.4297 54.2065C26.8418 55.5096 27.4661 56.6438 28.3027 57.5024L30.084 55.7661C29.0267 54.6807 28.2775 52.5767 28.3193 49.8286C28.3606 47.1236 29.173 43.9633 31.0107 40.9526C32.4621 38.5751 34.5702 36.2706 37.4727 34.3589C36.5514 35.3666 35.8827 36.4736 35.5576 37.6265L37.9512 38.3013C38.3625 36.8429 39.8101 35.142 42.2109 33.8042C44.5742 32.4874 47.717 31.6116 51.2432 31.6978ZM40.1201 2.4165C45.6991 -0.804509 52.5724 -0.804509 58.1514 2.4165L75.6777 12.5356C68.4683 12.0708 60.8765 13.1991 53.8691 15.6333C43.6671 19.1774 34.5353 25.5492 29.6035 34.0396C23.1612 45.1305 22.8486 54.4223 25.3623 61.2749C25.0301 60.7429 24.7004 60.1936 24.375 59.6265C19.8639 51.765 18.8286 41.4457 20.7139 31.3706C22.4486 22.1007 26.633 13.1734 32.6709 6.71631L40.1201 2.4165ZM54.6855 17.9829C63.3703 14.966 72.9092 14.0715 81.3008 15.7817L89.2559 20.3745C94.8346 23.5955 98.2714 29.5479 98.2715 35.9897V56.4692C95.0606 49.9731 90.2759 43.9144 84.6562 39.0112C76.4636 31.8632 66.3524 27.0488 56.5273 27.0229C43.6978 26.9893 35.4935 31.3659 30.8164 36.9712C31.1117 36.4161 31.4247 35.8554 31.7539 35.2886C36.3024 27.4582 44.8633 21.395 54.6855 17.9829Z" }, null, -1)
1063
- ])], 8, Vt)),
1064
- e.animated ? (A(), k("linearGradient", zt, [...t[2] || (t[2] = [
1065
- qe('<stop offset="0%" stop-color="#FF9533"><animate attributeName="stop-color" values="#FF9533;#FF4FBB;#EAFF4F;#1C91FC;#9A2DF8;#FF9533" dur="4s" repeatCount="indefinite"></animate></stop><stop offset="25%" stop-color="#FF4FBB"><animate attributeName="stop-color" values="#FF4FBB;#EAFF4F;#1C91FC;#9A2DF8;#FF9533;#FF4FBB" dur="4s" repeatCount="indefinite"></animate></stop><stop offset="50%" stop-color="#EAFF4F"><animate attributeName="stop-color" values="#EAFF4F;#1C91FC;#9A2DF8;#FF9533;#FF4FBB;#EAFF4F" dur="4s" repeatCount="indefinite"></animate></stop><stop offset="75%" stop-color="#1C91FC"><animate attributeName="stop-color" values="#1C91FC;#9A2DF8;#FF9533;#FF4FBB;#EAFF4F;#1C91FC" dur="4s" repeatCount="indefinite"></animate></stop><stop offset="100%" stop-color="#9A2DF8"><animate attributeName="stop-color" values="#9A2DF8;#FF9533;#FF4FBB;#EAFF4F;#1C91FC;#9A2DF8" dur="4s" repeatCount="indefinite"></animate></stop>', 5)
1069
+ ])], 8, zt)),
1070
+ e.animated ? (A(), k("linearGradient", Wt, [...t[2] || (t[2] = [
1071
+ He('<stop offset="0%" stop-color="#FF9533"><animate attributeName="stop-color" values="#FF9533;#FF4FBB;#EAFF4F;#1C91FC;#9A2DF8;#FF9533" dur="4s" repeatCount="indefinite"></animate></stop><stop offset="25%" stop-color="#FF4FBB"><animate attributeName="stop-color" values="#FF4FBB;#EAFF4F;#1C91FC;#9A2DF8;#FF9533;#FF4FBB" dur="4s" repeatCount="indefinite"></animate></stop><stop offset="50%" stop-color="#EAFF4F"><animate attributeName="stop-color" values="#EAFF4F;#1C91FC;#9A2DF8;#FF9533;#FF4FBB;#EAFF4F" dur="4s" repeatCount="indefinite"></animate></stop><stop offset="75%" stop-color="#1C91FC"><animate attributeName="stop-color" values="#1C91FC;#9A2DF8;#FF9533;#FF4FBB;#EAFF4F;#1C91FC" dur="4s" repeatCount="indefinite"></animate></stop><stop offset="100%" stop-color="#9A2DF8"><animate attributeName="stop-color" values="#9A2DF8;#FF9533;#FF4FBB;#EAFF4F;#1C91FC;#9A2DF8" dur="4s" repeatCount="indefinite"></animate></stop>', 5)
1066
1072
  ])])) : H("", !0)
1067
1073
  ])
1068
- ], 8, Gt));
1074
+ ], 8, Ut));
1069
1075
  }
1070
- }), Wt = { class: "vc-shortcut-kbd" }, qt = {
1076
+ }), qt = { class: "vc-shortcut-kbd" }, Ht = {
1071
1077
  key: 0,
1072
1078
  class: "vc-shortcut-kbd__plus"
1073
- }, Ht = { class: "vc-shortcut-kbd__key" }, Zt = /* @__PURE__ */ R({
1079
+ }, Zt = { class: "vc-shortcut-kbd__key" }, Xt = /* @__PURE__ */ R({
1074
1080
  __name: "shortcut-kbd",
1075
1081
  props: {
1076
1082
  parts: {},
1077
1083
  separated: { type: Boolean, default: !1 }
1078
1084
  },
1079
1085
  setup(e) {
1080
- return (i, a) => (A(), k("span", Wt, [
1086
+ return (r, a) => (A(), k("span", qt, [
1081
1087
  (A(!0), k(Ee, null, Se(e.parts, (t, o) => (A(), k(Ee, { key: o }, [
1082
- e.separated && o > 0 ? (A(), k("span", qt, "+")) : H("", !0),
1083
- x("kbd", Ht, le(t), 1)
1088
+ e.separated && o > 0 ? (A(), k("span", Ht, "+")) : H("", !0),
1089
+ x("kbd", Zt, le(t), 1)
1084
1090
  ], 64))), 128))
1085
1091
  ]));
1086
1092
  }
1087
- }), Xt = { class: "tw-inline-flex tw-items-center tw-gap-2" }, Yt = 500, jt = /* @__PURE__ */ R({
1093
+ }), Yt = { class: "tw-inline-flex tw-items-center tw-gap-2" }, jt = 500, Qt = /* @__PURE__ */ R({
1088
1094
  __name: "shortcut-tooltip",
1089
1095
  props: {
1090
1096
  shortcut: {},
1091
1097
  label: {}
1092
1098
  },
1093
1099
  setup(e) {
1094
- const i = e, { isMac: a } = Ne(), t = b(() => Fe(i.shortcut, a));
1095
- return (o, l) => (A(), ce(V(rt), {
1100
+ const r = e, { isMac: a } = Ne(), t = b(() => Fe(r.shortcut, a));
1101
+ return (o, l) => (A(), ce(K(rt), {
1096
1102
  placement: "bottom",
1097
- delay: Yt
1103
+ delay: jt
1098
1104
  }, {
1099
- tooltip: j(() => [
1100
- x("span", Xt, [
1101
- Ze(le(e.label) + " ", 1),
1102
- F(V(Zt), {
1105
+ tooltip: Q(() => [
1106
+ x("span", Yt, [
1107
+ Xe(le(e.label) + " ", 1),
1108
+ F(K(Xt), {
1103
1109
  parts: t.value.parts,
1104
- separated: !V(a)
1110
+ separated: !K(a)
1105
1111
  }, null, 8, ["parts", "separated"])
1106
1112
  ])
1107
1113
  ]),
1108
- default: j(() => [
1109
- He(o.$slots, "default", {
1114
+ default: Q(() => [
1115
+ Ze(o.$slots, "default", {
1110
1116
  aria: t.value.aria
1111
1117
  })
1112
1118
  ]),
1113
1119
  _: 3
1114
1120
  }));
1115
1121
  }
1116
- }), Qt = ["data-blade-expand-control", "aria-label", "aria-keyshortcuts", "onClick", "onKeydown"], Jt = /* @__PURE__ */ R({
1122
+ }), Jt = ["data-blade-expand-control", "aria-label", "aria-keyshortcuts", "onClick", "onKeydown"], en = /* @__PURE__ */ R({
1117
1123
  __name: "header-controls",
1118
1124
  props: {
1119
1125
  maximized: { type: Boolean }
1120
1126
  },
1121
1127
  emits: ["expand", "collapse", "close"],
1122
- setup(e, { emit: i }) {
1123
- const a = e, t = i, { t: o } = lt(), l = b(() => [
1128
+ setup(e, { emit: r }) {
1129
+ const a = e, t = r, { t: o } = ct(), l = b(() => [
1124
1130
  a.maximized ? {
1125
1131
  key: "collapse",
1126
1132
  activate: () => t("collapse"),
@@ -1147,7 +1153,7 @@ const Gt = ["width", "height"], Ut = ["clip-path"], Kt = {
1147
1153
  f.value?.querySelector("[data-blade-expand-control]")?.focus();
1148
1154
  });
1149
1155
  }
1150
- return z(
1156
+ return V(
1151
1157
  () => a.maximized,
1152
1158
  () => g()
1153
1159
  ), (h, v) => (A(), k("div", {
@@ -1155,12 +1161,12 @@ const Gt = ["width", "height"], Ut = ["clip-path"], Kt = {
1155
1161
  ref: f,
1156
1162
  class: "vc-blade-header__controls"
1157
1163
  }, [
1158
- (A(!0), k(Ee, null, Se(l.value, (c) => (A(), ce(V(jt), {
1164
+ (A(!0), k(Ee, null, Se(l.value, (c) => (A(), ce(K(Qt), {
1159
1165
  key: c.key,
1160
1166
  shortcut: c.shortcut,
1161
1167
  label: c.label
1162
1168
  }, {
1163
- default: j(({ aria: d }) => [
1169
+ default: Q(({ aria: d }) => [
1164
1170
  x("div", {
1165
1171
  class: "vc-blade-header__button",
1166
1172
  role: "button",
@@ -1174,16 +1180,16 @@ const Gt = ["width", "height"], Ut = ["clip-path"], Kt = {
1174
1180
  we(Ae(c.activate, ["prevent"]), ["space"])
1175
1181
  ]
1176
1182
  }, [
1177
- F(V(De), {
1183
+ F(K(De), {
1178
1184
  icon: c.icon
1179
1185
  }, null, 8, ["icon"])
1180
- ], 40, Qt)
1186
+ ], 40, Jt)
1181
1187
  ]),
1182
1188
  _: 2
1183
1189
  }, 1032, ["shortcut", "label"]))), 128))
1184
1190
  ], 512));
1185
1191
  }
1186
- }), en = { class: "vc-ai-agent-header" }, tn = { class: "vc-ai-agent-header__icon" }, nn = { class: "vc-ai-agent-header__wrapper" }, an = { class: "vc-ai-agent-header__content" }, on = { class: "vc-ai-agent-header__title" }, rn = /* @__PURE__ */ R({
1192
+ }), tn = { class: "vc-ai-agent-header" }, nn = { class: "vc-ai-agent-header__icon" }, an = { class: "vc-ai-agent-header__wrapper" }, on = { class: "vc-ai-agent-header__content" }, rn = { class: "vc-ai-agent-header__title" }, sn = /* @__PURE__ */ R({
1187
1193
  __name: "VcAiAgentHeader",
1188
1194
  props: {
1189
1195
  title: {},
@@ -1192,61 +1198,61 @@ const Gt = ["width", "height"], Ut = ["clip-path"], Kt = {
1192
1198
  },
1193
1199
  emits: ["close", "expand", "collapse"],
1194
1200
  setup(e) {
1195
- return (i, a) => (A(), k("div", en, [
1196
- x("div", tn, [
1201
+ return (r, a) => (A(), k("div", tn, [
1202
+ x("div", nn, [
1197
1203
  F(Ge, {
1198
1204
  width: 22,
1199
1205
  height: 24,
1200
1206
  "show-dots": ""
1201
1207
  })
1202
1208
  ]),
1203
- x("div", nn, [
1204
- x("div", an, [
1205
- x("div", on, le(e.title), 1)
1209
+ x("div", an, [
1210
+ x("div", on, [
1211
+ x("div", rn, le(e.title), 1)
1206
1212
  ])
1207
1213
  ]),
1208
- F(V(Jt), {
1214
+ F(K(en), {
1209
1215
  maximized: e.isExpanded,
1210
- onExpand: a[0] || (a[0] = (t) => i.$emit("expand")),
1211
- onCollapse: a[1] || (a[1] = (t) => i.$emit("collapse")),
1212
- onClose: a[2] || (a[2] = (t) => i.$emit("close"))
1216
+ onExpand: a[0] || (a[0] = (t) => r.$emit("expand")),
1217
+ onCollapse: a[1] || (a[1] = (t) => r.$emit("collapse")),
1218
+ onClose: a[2] || (a[2] = (t) => r.$emit("close"))
1213
1219
  }, null, 8, ["maximized"])
1214
1220
  ]));
1215
1221
  }
1216
- }), sn = { class: "vc-ai-agent-loader" }, ln = { class: "vc-ai-agent-loader__content" }, cn = { class: "vc-ai-agent-loader__logo" }, dn = {
1222
+ }), ln = { class: "vc-ai-agent-loader" }, cn = { class: "vc-ai-agent-loader__content" }, dn = { class: "vc-ai-agent-loader__logo" }, un = {
1217
1223
  key: 0,
1218
1224
  class: "vc-ai-agent-loader__text"
1219
- }, un = /* @__PURE__ */ R({
1225
+ }, fn = /* @__PURE__ */ R({
1220
1226
  __name: "VcAiAgentLoader",
1221
1227
  props: {
1222
1228
  text: {}
1223
1229
  },
1224
1230
  setup(e) {
1225
- return (i, a) => (A(), k("div", sn, [
1226
- x("div", ln, [
1227
- x("div", cn, [
1231
+ return (r, a) => (A(), k("div", ln, [
1232
+ x("div", cn, [
1233
+ x("div", dn, [
1228
1234
  F(Ge, {
1229
1235
  width: 80,
1230
1236
  height: 87,
1231
1237
  animated: ""
1232
1238
  })
1233
1239
  ]),
1234
- e.text ? (A(), k("p", dn, le(e.text), 1)) : H("", !0)
1240
+ e.text ? (A(), k("p", un, le(e.text), 1)) : H("", !0)
1235
1241
  ])
1236
1242
  ]));
1237
1243
  }
1238
- }), fn = { class: "vc-ai-agent-iframe" }, pn = ["src"], gn = {
1244
+ }), pn = { class: "vc-ai-agent-iframe" }, gn = ["src"], vn = {
1239
1245
  key: 1,
1240
1246
  class: "vc-ai-agent-iframe__placeholder"
1241
- }, vn = /* @__PURE__ */ R({
1247
+ }, Cn = /* @__PURE__ */ R({
1242
1248
  __name: "VcAiAgentIframe",
1243
1249
  props: {
1244
1250
  url: {}
1245
1251
  },
1246
1252
  emits: ["iframe-ready"],
1247
- setup(e, { emit: i }) {
1248
- const a = Z("ai-agent-iframe"), t = e, o = i, l = D(null), f = D(!0);
1249
- z(
1253
+ setup(e, { emit: r }) {
1254
+ const a = Z("ai-agent-iframe"), t = e, o = r, l = D(null), f = D(!0);
1255
+ V(
1250
1256
  l,
1251
1257
  (h) => {
1252
1258
  h && o("iframe-ready", h);
@@ -1256,15 +1262,15 @@ const Gt = ["width", "height"], Ut = ["clip-path"], Kt = {
1256
1262
  const g = () => {
1257
1263
  f.value = !1, a.debug("Iframe loaded");
1258
1264
  };
1259
- return z(
1265
+ return V(
1260
1266
  () => t.url,
1261
1267
  () => {
1262
1268
  f.value = !0;
1263
1269
  }
1264
- ), (h, v) => (A(), k("div", fn, [
1270
+ ), (h, v) => (A(), k("div", pn, [
1265
1271
  F(Oe, { name: "fade" }, {
1266
- default: j(() => [
1267
- f.value && e.url ? (A(), ce(un, {
1272
+ default: Q(() => [
1273
+ f.value && e.url ? (A(), ce(fn, {
1268
1274
  key: 0,
1269
1275
  text: h.$t("AI_AGENT.LOADING")
1270
1276
  }, null, 8, ["text"])) : H("", !0)
@@ -1280,8 +1286,8 @@ const Gt = ["width", "height"], Ut = ["clip-path"], Kt = {
1280
1286
  sandbox: "allow-scripts allow-same-origin allow-forms allow-popups allow-popups-to-escape-sandbox",
1281
1287
  allow: "clipboard-read; clipboard-write",
1282
1288
  onLoad: g
1283
- }, null, 42, pn)) : (A(), k("div", gn, [
1284
- F(V(De), {
1289
+ }, null, 42, gn)) : (A(), k("div", vn, [
1290
+ F(K(De), {
1285
1291
  icon: "lucide-sparkles",
1286
1292
  size: "xl",
1287
1293
  class: "vc-ai-agent-iframe__placeholder-icon"
@@ -1290,26 +1296,26 @@ const Gt = ["width", "height"], Ut = ["clip-path"], Kt = {
1290
1296
  ]))
1291
1297
  ]));
1292
1298
  }
1293
- }), Cn = ["inert"], mn = { class: "vc-ai-agent-panel__content" }, Mn = /* @__PURE__ */ R({
1299
+ }), mn = ["inert"], hn = { class: "vc-ai-agent-panel__content" }, Fn = /* @__PURE__ */ R({
1294
1300
  __name: "VcAiAgentPanel",
1295
1301
  props: {
1296
1302
  inert: { type: Boolean }
1297
1303
  },
1298
1304
  setup(e) {
1299
- const { isMac: i } = Ne(), a = M(be), t = M(it, !1);
1305
+ const { isMac: r } = Ne(), a = M(be), t = M(st, !1);
1300
1306
  a || console.error("[VcAiAgentPanel] AiAgentService not provided");
1301
1307
  const o = b(
1302
1308
  () => a?.config.value ?? { url: "", title: "AI Assistant", width: 362, expandedWidth: 500 }
1303
1309
  ), l = b(() => !t && (a?.isOpen.value ?? !1)), f = b(() => a?.isExpanded.value ?? !1), g = b(() => a?.totalItemsCount.value ?? 0), h = b(() => ({
1304
1310
  width: f.value ? `${o.value.expandedWidth ?? 500}px` : `${o.value.width ?? 362}px`
1305
1311
  })), v = () => a?.closePanel(), c = () => a?.expandPanel(), d = () => a?.collapsePanel(), u = D(null);
1306
- st(document, "keydown", (p) => {
1312
+ lt(document, "keydown", (p) => {
1307
1313
  if (l.value && !p.isComposing && !p.defaultPrevented) {
1308
1314
  if (p.key === "Escape") {
1309
1315
  p.preventDefault(), v();
1310
1316
  return;
1311
1317
  }
1312
- if (Bt(q.mod.backslash, p, i)) {
1318
+ if (It(q.mod.backslash, p, r)) {
1313
1319
  const _ = document.activeElement;
1314
1320
  if (!_ || !u.value?.contains(_)) return;
1315
1321
  p.preventDefault(), f.value ? d() : c();
@@ -1319,10 +1325,10 @@ const Gt = ["width", "height"], Ut = ["clip-path"], Kt = {
1319
1325
  const w = (p) => {
1320
1326
  a?._setIframeRef(p);
1321
1327
  };
1322
- return Xe(() => {
1328
+ return Ye(() => {
1323
1329
  a?._setIframeRef(null);
1324
1330
  }), (p, _) => (A(), ce(Oe, { name: "ai-panel-slide" }, {
1325
- default: j(() => [
1331
+ default: Q(() => [
1326
1332
  l.value ? (A(), k("div", {
1327
1333
  key: 0,
1328
1334
  ref_key: "panelRef",
@@ -1330,10 +1336,10 @@ const Gt = ["width", "height"], Ut = ["clip-path"], Kt = {
1330
1336
  class: Pe(["vc-ai-agent-panel", {
1331
1337
  "vc-ai-agent-panel--expanded": f.value
1332
1338
  }]),
1333
- style: Ye(h.value),
1339
+ style: je(h.value),
1334
1340
  inert: e.inert || void 0
1335
1341
  }, [
1336
- F(rn, {
1342
+ F(sn, {
1337
1343
  title: o.value.title,
1338
1344
  "is-expanded": f.value,
1339
1345
  "items-count": g.value,
@@ -1341,46 +1347,46 @@ const Gt = ["width", "height"], Ut = ["clip-path"], Kt = {
1341
1347
  onExpand: c,
1342
1348
  onCollapse: d
1343
1349
  }, null, 8, ["title", "is-expanded", "items-count"]),
1344
- x("div", mn, [
1345
- F(vn, {
1350
+ x("div", hn, [
1351
+ F(Cn, {
1346
1352
  url: o.value.url,
1347
1353
  onIframeReady: w
1348
1354
  }, null, 8, ["url"])
1349
1355
  ])
1350
- ], 14, Cn)) : H("", !0)
1356
+ ], 14, mn)) : H("", !0)
1351
1357
  ]),
1352
1358
  _: 1
1353
1359
  }));
1354
1360
  }
1355
1361
  });
1356
1362
  export {
1357
- An as A,
1358
- ct as D,
1359
- yn as E,
1360
- xn as H,
1361
- Mn as _,
1362
- On as a,
1363
- kn as b,
1364
- Dn as c,
1365
- In as d,
1366
- Sn as e,
1367
- Pt as f,
1368
- kt as g,
1363
+ yn as A,
1364
+ dt as D,
1365
+ xn as E,
1366
+ Bn as H,
1367
+ Fn as _,
1368
+ Pn as a,
1369
+ Sn as b,
1370
+ Mn as c,
1371
+ Tn as d,
1372
+ On as e,
1373
+ Lt as f,
1374
+ St as g,
1369
1375
  $e as h,
1370
- St as i,
1376
+ Ot as i,
1371
1377
  Re as j,
1372
- At as k,
1373
- yt as l,
1378
+ yt as k,
1379
+ xt as l,
1374
1380
  Fe as m,
1375
1381
  q as n,
1376
- Bn as o,
1377
- Bt as p,
1378
- Rt as q,
1379
- Tt as r,
1380
- Tn as s,
1382
+ In as o,
1383
+ It as p,
1384
+ Gt as q,
1385
+ kt as r,
1386
+ kn as s,
1381
1387
  Ne as t,
1382
- Ln as u,
1383
- Jt as v,
1384
- jt as w,
1385
- Pn as x
1388
+ Dn as u,
1389
+ en as v,
1390
+ Qt as w,
1391
+ Ln as x
1386
1392
  };