@vc-shell/framework 2.4.0-pr306.cc97338 → 2.4.0-pr308.b67c788
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.
- package/dist/ai-agent/index.js +2 -2
- package/dist/chunks/{VcAiAgentPanel.vue_vue_type_script_setup_true_lang-B6-CbU4n.js → VcAiAgentPanel.vue_vue_type_script_setup_true_lang-bvyt-Rtf.js} +337 -344
- package/dist/chunks/VcAiAgentPanel.vue_vue_type_script_setup_true_lang-bvyt-Rtf.js.map +1 -0
- package/dist/chunks/{VcScheduler.vue_vue_type_script_setup_true_lang-rZsBM9o8.js → VcScheduler.vue_vue_type_script_setup_true_lang-CfaVA4mj.js} +6739 -6795
- package/dist/chunks/VcScheduler.vue_vue_type_script_setup_true_lang-CfaVA4mj.js.map +1 -0
- package/dist/chunks/{dashboard-feed-row.vue_vue_type_script_setup_true_lang-BCsJG_hk.js → dashboard-feed-row.vue_vue_type_script_setup_true_lang-DSujdkDw.js} +141 -146
- package/dist/chunks/{dashboard-feed-row.vue_vue_type_script_setup_true_lang-BCsJG_hk.js.map → dashboard-feed-row.vue_vue_type_script_setup_true_lang-DSujdkDw.js.map} +1 -1
- package/dist/chunks/{index-QlzA13tK.js → index-DYMV0pFy.js} +1 -1
- package/dist/chunks/{index-QlzA13tK.js.map → index-DYMV0pFy.js.map} +1 -1
- package/dist/core/composables/usePopup/index.d.ts.map +1 -1
- package/dist/core/plugins/ai-agent/components/VcAiAgentPanel.vue.d.ts +1 -4
- package/dist/core/plugins/ai-agent/components/VcAiAgentPanel.vue.d.ts.map +1 -1
- package/dist/core/plugins/ai-agent/services/message-transport.d.ts.map +1 -1
- package/dist/dashboard/index.js +1 -1
- package/dist/framework.js +12 -12
- package/dist/locales/de.js +0 -1
- package/dist/locales/en.js +0 -1
- package/dist/locales/en.json +0 -1
- package/dist/locales/types.d.ts +0 -1
- package/dist/shell/dashboard/draggable-dashboard/GridstackDashboard.vue.d.ts.map +1 -1
- package/dist/tsconfig.tsbuildinfo +1 -1
- package/dist/ui/components/molecules/vc-popover/vc-popover.vue.d.ts +0 -4
- package/dist/ui/components/molecules/vc-popover/vc-popover.vue.d.ts.map +1 -1
- package/dist/ui/components/organisms/vc-app/_internal/app-bar/components/MenuSidebar.vue.d.ts +0 -1
- package/dist/ui/components/organisms/vc-app/_internal/app-bar/components/MenuSidebar.vue.d.ts.map +1 -1
- package/dist/ui/components/organisms/vc-app/_internal/layouts/MobileLayout.vue.d.ts.map +1 -1
- package/dist/ui/components/organisms/vc-app/vc-app.vue.d.ts.map +1 -1
- package/dist/ui/components/organisms/vc-blade/vc-blade.vue.d.ts.map +1 -1
- package/dist/ui/components/organisms/vc-scheduler/_internal/month/MonthMorePopover.vue.d.ts.map +1 -1
- package/dist/ui/components/organisms/vc-sidebar/vc-sidebar.vue.d.ts +0 -1
- package/dist/ui/components/organisms/vc-sidebar/vc-sidebar.vue.d.ts.map +1 -1
- package/dist/ui/index.js +1 -1
- package/package.json +4 -4
- package/dist/chunks/VcAiAgentPanel.vue_vue_type_script_setup_true_lang-B6-CbU4n.js.map +0 -1
- package/dist/chunks/VcScheduler.vue_vue_type_script_setup_true_lang-rZsBM9o8.js.map +0 -1
- package/dist/ui/components/organisms/vc-blade/useBladeSkeleton.d.ts +0 -16
- package/dist/ui/components/organisms/vc-blade/useBladeSkeleton.d.ts.map +0 -1
|
@@ -1,7 +1,7 @@
|
|
|
1
|
-
import { shallowRef as he, ref as D, watch as le, nextTick as de, onUnmounted as pe, openBlock as v, createElementBlock as _, createStaticVNode as me, defineComponent as
|
|
1
|
+
import { shallowRef as he, ref as D, watch as le, nextTick as de, onUnmounted as pe, openBlock as v, createElementBlock as _, createStaticVNode as me, defineComponent as B, inject as fe, computed as se, onMounted as ve, createBlock as V, withCtx as ge, unref as X, Fragment as re, renderList as ie, normalizeStyle as ye, normalizeClass as ce, createElementVNode as b, createCommentVNode as N, resolveDynamicComponent as _e, mergeProps as be, toDisplayString as Y, renderSlot as M, createVNode as we, withDirectives as ke } from "vue";
|
|
2
2
|
import { q as $e, r as xe, s as Se, l as Le } from "./VcScheduler.vue_vue_type_style_index_0_lang-BTg4PjTB.js";
|
|
3
|
-
import { G as
|
|
4
|
-
import { M as
|
|
3
|
+
import { G as ze } from "./vendor-gridstack-Beau2jQ7.js";
|
|
4
|
+
import { M as We, _ as De } from "./VcAiAgentPanel.vue_vue_type_style_index_0_lang-CZdY18Hq.js";
|
|
5
5
|
import "vee-validate";
|
|
6
6
|
import "./vendor-tiptap-starter-kit-ny-AoaO_.js";
|
|
7
7
|
import "./vendor-tiptap-extension-underline-Bo1pXXDN.js";
|
|
@@ -82,7 +82,7 @@ import "./ExtensionPoint.vue_vue_type_style_index_0_lang-B1R06zHa.js";
|
|
|
82
82
|
import "./vendor-truncate-html-ChA1T5zy.js";
|
|
83
83
|
import "./vendor-sortablejs-Bsvu-FKn.js";
|
|
84
84
|
const j = "vc-dashboard-layout";
|
|
85
|
-
function
|
|
85
|
+
function Z(t, s) {
|
|
86
86
|
const a = s ?? t.position;
|
|
87
87
|
return {
|
|
88
88
|
id: t.id,
|
|
@@ -96,7 +96,7 @@ function ee(t, s) {
|
|
|
96
96
|
minH: 2
|
|
97
97
|
};
|
|
98
98
|
}
|
|
99
|
-
function
|
|
99
|
+
function ee(t) {
|
|
100
100
|
return {
|
|
101
101
|
id: t.id ?? "",
|
|
102
102
|
position: {
|
|
@@ -122,7 +122,7 @@ function Ae(t) {
|
|
|
122
122
|
});
|
|
123
123
|
return s;
|
|
124
124
|
}
|
|
125
|
-
function
|
|
125
|
+
function te() {
|
|
126
126
|
try {
|
|
127
127
|
const t = localStorage.getItem(j);
|
|
128
128
|
if (!t) return null;
|
|
@@ -168,18 +168,18 @@ function Ge() {
|
|
|
168
168
|
}
|
|
169
169
|
function Pe(t, s = 12) {
|
|
170
170
|
const a = /* @__PURE__ */ new Map(), h = /* @__PURE__ */ new Map(), p = (o, y, f, k) => {
|
|
171
|
-
for (let
|
|
172
|
-
const
|
|
171
|
+
for (let w = y; w < y + k; w++) {
|
|
172
|
+
const W = h.get(w) || [];
|
|
173
173
|
for (let S = o; S < o + f; S++)
|
|
174
|
-
if (
|
|
174
|
+
if (W.includes(S)) return !1;
|
|
175
175
|
}
|
|
176
176
|
return !0;
|
|
177
|
-
},
|
|
178
|
-
for (let
|
|
179
|
-
const
|
|
177
|
+
}, z = (o, y, f, k) => {
|
|
178
|
+
for (let w = y; w < y + k; w++) {
|
|
179
|
+
const W = h.get(w) || [];
|
|
180
180
|
for (let S = o; S < o + f; S++)
|
|
181
|
-
|
|
182
|
-
h.set(
|
|
181
|
+
W.push(S);
|
|
182
|
+
h.set(w, W);
|
|
183
183
|
}
|
|
184
184
|
}, i = (o, y) => {
|
|
185
185
|
let f = 0;
|
|
@@ -193,15 +193,15 @@ function Pe(t, s = 12) {
|
|
|
193
193
|
};
|
|
194
194
|
for (const o of t) {
|
|
195
195
|
const y = i(o.size.width, o.size.height);
|
|
196
|
-
a.set(o.id, y),
|
|
196
|
+
a.set(o.id, y), z(y.x, y.y, o.size.width, o.size.height);
|
|
197
197
|
}
|
|
198
198
|
return a;
|
|
199
199
|
}
|
|
200
|
-
function
|
|
200
|
+
function oe(t, s) {
|
|
201
201
|
if (s && s.size > 0) {
|
|
202
202
|
const h = /* @__PURE__ */ new Map();
|
|
203
203
|
for (const p of t) {
|
|
204
|
-
const
|
|
204
|
+
const z = s.get(p.id), i = p.position, o = z ?? i ?? { x: 0, y: 0 };
|
|
205
205
|
h.set(p.id, o);
|
|
206
206
|
}
|
|
207
207
|
return h;
|
|
@@ -234,84 +234,84 @@ const Me = {
|
|
|
234
234
|
}
|
|
235
235
|
};
|
|
236
236
|
function Oe(t, s = {}) {
|
|
237
|
-
const { gridOptions: a = {}, resizable: h = !1, autoSave: p = !0, onLayoutChange:
|
|
237
|
+
const { gridOptions: a = {}, resizable: h = !1, autoSave: p = !0, onLayoutChange: z } = s, i = he(null), o = D(/* @__PURE__ */ new Map()), y = D(!1), f = D(!1), k = {
|
|
238
238
|
...Me,
|
|
239
239
|
...a,
|
|
240
240
|
disableResize: !h
|
|
241
|
-
},
|
|
241
|
+
}, w = (r) => {
|
|
242
242
|
if (i.value) {
|
|
243
243
|
console.warn("[useGridstack] Grid already initialized");
|
|
244
244
|
return;
|
|
245
245
|
}
|
|
246
|
-
const l =
|
|
247
|
-
o.value =
|
|
246
|
+
const l = te();
|
|
247
|
+
o.value = oe(t.value, l), i.value = ze.init(k, r), i.value.on("change", W), i.value.on("added", S), i.value.on("removed", J);
|
|
248
248
|
const c = t.value.map((g) => {
|
|
249
249
|
const m = o.value.get(g.id);
|
|
250
|
-
return
|
|
250
|
+
return Z(g, m);
|
|
251
251
|
});
|
|
252
252
|
i.value.load(c), y.value = !0;
|
|
253
|
-
},
|
|
253
|
+
}, W = (r, l) => {
|
|
254
254
|
if (!f.value) {
|
|
255
255
|
for (const c of l) {
|
|
256
|
-
const { id: g, position: m } =
|
|
256
|
+
const { id: g, position: m } = ee(c);
|
|
257
257
|
if (g) {
|
|
258
|
-
const $ = o.value.get(g),
|
|
258
|
+
const $ = o.value.get(g), I = typeof c.w == "number" ? c.w : $?.width, L = typeof c.h == "number" ? c.h : $?.height;
|
|
259
259
|
o.value.set(g, {
|
|
260
260
|
...m,
|
|
261
|
-
...typeof
|
|
261
|
+
...typeof I == "number" ? { width: I } : {},
|
|
262
262
|
...typeof L == "number" ? { height: L } : {}
|
|
263
263
|
});
|
|
264
264
|
}
|
|
265
265
|
}
|
|
266
|
-
o.value = new Map(o.value),
|
|
266
|
+
o.value = new Map(o.value), z?.(o.value), p && P();
|
|
267
267
|
}
|
|
268
268
|
}, S = (r, l) => {
|
|
269
269
|
for (const c of l) {
|
|
270
|
-
const { id: g, position: m } =
|
|
270
|
+
const { id: g, position: m } = ee(c);
|
|
271
271
|
g && !o.value.has(g) && o.value.set(g, m);
|
|
272
272
|
}
|
|
273
273
|
o.value = new Map(o.value);
|
|
274
|
-
},
|
|
274
|
+
}, J = (r, l) => {
|
|
275
275
|
for (const c of l)
|
|
276
276
|
c.id && o.value.delete(c.id);
|
|
277
277
|
o.value = new Map(o.value);
|
|
278
|
-
},
|
|
278
|
+
}, R = () => {
|
|
279
279
|
i.value && (i.value.off("change"), i.value.off("added"), i.value.off("removed"), i.value.destroy(!1), i.value = null, y.value = !1);
|
|
280
|
-
},
|
|
280
|
+
}, U = (r) => {
|
|
281
281
|
if (!i.value) return;
|
|
282
|
-
const l = o.value.get(r.id) ?? r.position, c =
|
|
282
|
+
const l = o.value.get(r.id) ?? r.position, c = Z(r, l), g = document.querySelector(`[gs-id="${r.id}"]`);
|
|
283
283
|
g && i.value.makeWidget(g, c);
|
|
284
|
-
},
|
|
284
|
+
}, F = (r) => {
|
|
285
285
|
if (!i.value) return;
|
|
286
286
|
const l = document.querySelector(`[gs-id="${r}"]`);
|
|
287
287
|
l && i.value.removeWidget(l, !1), o.value.delete(r);
|
|
288
|
-
},
|
|
289
|
-
const m = l.gridstackNode, $ = o.value.get(r),
|
|
288
|
+
}, C = (r, l, c, g) => {
|
|
289
|
+
const m = l.gridstackNode, $ = o.value.get(r), I = m?.x ?? c?.x ?? $?.x ?? 0, L = m?.y ?? c?.y ?? $?.y ?? 0, H = m?.w ?? g?.width ?? $?.width, Q = m?.h ?? g?.height ?? $?.height;
|
|
290
290
|
o.value.set(r, {
|
|
291
|
-
x:
|
|
291
|
+
x: I,
|
|
292
292
|
y: L,
|
|
293
|
-
...typeof
|
|
294
|
-
...typeof
|
|
293
|
+
...typeof H == "number" ? { width: H } : {},
|
|
294
|
+
...typeof Q == "number" ? { height: Q } : {}
|
|
295
295
|
}), o.value = new Map(o.value);
|
|
296
296
|
}, q = (r, l) => {
|
|
297
297
|
if (!i.value) return;
|
|
298
298
|
const c = document.querySelector(`[gs-id="${r}"]`);
|
|
299
|
-
c && (f.value = !0, i.value.update(c, { x: l.x, y: l.y }),
|
|
300
|
-
},
|
|
299
|
+
c && (f.value = !0, i.value.update(c, { x: l.x, y: l.y }), C(r, c, l), f.value = !1);
|
|
300
|
+
}, G = (r, l) => {
|
|
301
301
|
if (!i.value) return;
|
|
302
302
|
const c = document.querySelector(`[gs-id="${r}"]`);
|
|
303
|
-
c && (f.value = !0, i.value.update(c, { w: l.width, h: l.height }),
|
|
303
|
+
c && (f.value = !0, i.value.update(c, { w: l.width, h: l.height }), C(r, c, void 0, l), f.value = !1);
|
|
304
304
|
}, P = () => {
|
|
305
305
|
ue(t.value, o.value);
|
|
306
|
+
}, E = () => {
|
|
307
|
+
const r = te();
|
|
308
|
+
r && (o.value = oe(t.value, r), A());
|
|
306
309
|
}, T = () => {
|
|
307
|
-
const r = oe();
|
|
308
|
-
r && (o.value = ae(t.value, r), G());
|
|
309
|
-
}, I = () => {
|
|
310
310
|
o.value = /* @__PURE__ */ new Map();
|
|
311
311
|
for (const r of t.value)
|
|
312
312
|
r.position && o.value.set(r.id, { ...r.position });
|
|
313
|
-
|
|
314
|
-
},
|
|
313
|
+
A(), P();
|
|
314
|
+
}, A = () => {
|
|
315
315
|
if (i.value) {
|
|
316
316
|
f.value = !0, i.value.batchUpdate();
|
|
317
317
|
for (const r of t.value) {
|
|
@@ -330,7 +330,7 @@ function Oe(t, s = {}) {
|
|
|
330
330
|
}
|
|
331
331
|
i.value.batchUpdate(!1), f.value = !1;
|
|
332
332
|
}
|
|
333
|
-
},
|
|
333
|
+
}, O = (r) => {
|
|
334
334
|
if (!i.value) {
|
|
335
335
|
r();
|
|
336
336
|
return;
|
|
@@ -344,27 +344,27 @@ function Oe(t, s = {}) {
|
|
|
344
344
|
await de();
|
|
345
345
|
const c = r.filter((m) => !l?.some(($) => $.id === m.id)), g = l?.filter((m) => !r.some(($) => $.id === m.id)).map((m) => m.id) ?? [];
|
|
346
346
|
for (const m of g)
|
|
347
|
-
C(m);
|
|
348
|
-
for (const m of c)
|
|
349
347
|
F(m);
|
|
348
|
+
for (const m of c)
|
|
349
|
+
U(m);
|
|
350
350
|
},
|
|
351
351
|
{ deep: !1 }
|
|
352
352
|
), pe(() => {
|
|
353
|
-
|
|
353
|
+
R();
|
|
354
354
|
}), {
|
|
355
355
|
grid: i,
|
|
356
356
|
layout: o,
|
|
357
357
|
isInitialized: y,
|
|
358
|
-
initGrid:
|
|
359
|
-
destroyGrid:
|
|
360
|
-
addWidget:
|
|
361
|
-
removeWidget:
|
|
358
|
+
initGrid: w,
|
|
359
|
+
destroyGrid: R,
|
|
360
|
+
addWidget: U,
|
|
361
|
+
removeWidget: F,
|
|
362
362
|
updateWidgetPosition: q,
|
|
363
|
-
updateWidgetSize:
|
|
363
|
+
updateWidgetSize: G,
|
|
364
364
|
saveLayout: P,
|
|
365
|
-
loadLayout:
|
|
366
|
-
resetToDefaults:
|
|
367
|
-
batchUpdate:
|
|
365
|
+
loadLayout: E,
|
|
366
|
+
resetToDefaults: T,
|
|
367
|
+
batchUpdate: O
|
|
368
368
|
};
|
|
369
369
|
}
|
|
370
370
|
const Ee = {}, Te = {
|
|
@@ -385,7 +385,7 @@ const Ne = /* @__PURE__ */ $e(Ee, [["render", Ie]]), Be = ["aria-label"], Re = [
|
|
|
385
385
|
role: "status",
|
|
386
386
|
"aria-live": "polite",
|
|
387
387
|
"aria-atomic": "true"
|
|
388
|
-
}, ne = 2, Ke = /* @__PURE__ */
|
|
388
|
+
}, ne = 2, Ke = /* @__PURE__ */ B({
|
|
389
389
|
__name: "GridstackDashboard",
|
|
390
390
|
props: {
|
|
391
391
|
showDragHandles: { type: Boolean, default: !1 },
|
|
@@ -414,10 +414,10 @@ const Ne = /* @__PURE__ */ $e(Ee, [["render", Ie]]), Be = ["aria-label"], Re = [
|
|
|
414
414
|
return null;
|
|
415
415
|
}
|
|
416
416
|
}
|
|
417
|
-
const p = t,
|
|
417
|
+
const p = t, z = D(null), i = D(""), o = fe(We, D(!0)), y = se(() => o.value ? [] : h() ?? a), f = (e) => ({
|
|
418
418
|
gridColumn: `${e.x + 1} / span ${e.w}`,
|
|
419
419
|
gridRow: `${e.y + 1} / span ${e.h}`
|
|
420
|
-
}), k = xe(),
|
|
420
|
+
}), k = xe(), w = se(() => k.getWidgets()), { layout: W, isInitialized: S, initGrid: J, saveLayout: R, resetToDefaults: U, updateWidgetPosition: F, updateWidgetSize: C } = Oe(w, {
|
|
421
421
|
resizable: p.resizable,
|
|
422
422
|
autoSave: !0,
|
|
423
423
|
gridOptions: {
|
|
@@ -430,44 +430,39 @@ const Ne = /* @__PURE__ */ $e(Ee, [["render", Ie]]), Be = ["aria-label"], Re = [
|
|
|
430
430
|
k.updateWidgetPosition(u, n);
|
|
431
431
|
L("Widget positions updated");
|
|
432
432
|
}
|
|
433
|
-
}), q = (e) =>
|
|
434
|
-
const u =
|
|
433
|
+
}), q = (e) => W.value.get(e), G = D(null), P = D(null), E = D(null), T = (e) => W.value.get(e.id) ?? e.position ?? { x: 0, y: 0 }, A = (e) => {
|
|
434
|
+
const u = W.value.get(e.id);
|
|
435
435
|
return {
|
|
436
436
|
width: u?.width ?? e.size.width,
|
|
437
437
|
height: u?.height ?? e.size.height
|
|
438
438
|
};
|
|
439
|
-
},
|
|
440
|
-
|
|
441
|
-
`${
|
|
439
|
+
}, O = (e) => e.name || e.id, r = (e) => {
|
|
440
|
+
G.value = e.id, P.value = { ...T(e) }, E.value = { ...A(e) }, L(
|
|
441
|
+
`${O(e)} picked up. Use arrow keys to move, Shift and arrow keys to resize, Enter to drop, Escape to cancel.`
|
|
442
442
|
);
|
|
443
443
|
}, l = (e) => {
|
|
444
|
-
|
|
445
|
-
const { x: u, y: n } =
|
|
446
|
-
L(`${
|
|
444
|
+
G.value = null, P.value = null, E.value = null, R();
|
|
445
|
+
const { x: u, y: n } = T(e);
|
|
446
|
+
L(`${O(e)} dropped at column ${u + 1}, row ${n + 1}.`);
|
|
447
447
|
}, c = (e) => {
|
|
448
|
-
const u = P.value, n =
|
|
449
|
-
n && (n.width !== d.width || n.height !== d.height) &&
|
|
448
|
+
const u = P.value, n = E.value, d = A(e);
|
|
449
|
+
n && (n.width !== d.width || n.height !== d.height) && C(e.id, n), u && F(e.id, u), G.value = null, P.value = null, E.value = null, L(`Move cancelled. ${O(e)} returned to its original position and size.`);
|
|
450
450
|
}, g = (e, u, n) => {
|
|
451
|
-
const d =
|
|
451
|
+
const d = T(e), x = { x: d.x + u, y: d.y + n };
|
|
452
452
|
if (x.x < 0 || x.y < 0) return;
|
|
453
|
-
|
|
454
|
-
const
|
|
455
|
-
L(`${
|
|
453
|
+
F(e.id, x);
|
|
454
|
+
const K = T(e);
|
|
455
|
+
L(`${O(e)} moved to column ${K.x + 1}, row ${K.y + 1}.`);
|
|
456
456
|
}, m = (e, u, n) => {
|
|
457
|
-
const d =
|
|
458
|
-
if (x === d.width &&
|
|
459
|
-
|
|
460
|
-
const
|
|
461
|
-
L(`${
|
|
457
|
+
const d = A(e), x = u ? Math.max(ne, d.width + u) : d.width, K = n ? Math.max(ne, d.height + n) : d.height;
|
|
458
|
+
if (x === d.width && K === d.height) return;
|
|
459
|
+
C(e.id, { width: x, height: K });
|
|
460
|
+
const ae = A(e);
|
|
461
|
+
L(`${O(e)} resized to ${ae.width} by ${ae.height} cells.`);
|
|
462
462
|
}, $ = (e, u) => {
|
|
463
|
-
|
|
464
|
-
const n = A.value === u.id;
|
|
463
|
+
const n = G.value === u.id;
|
|
465
464
|
if (e.key === "Enter" || e.key === " ") {
|
|
466
|
-
|
|
467
|
-
else {
|
|
468
|
-
const M = b.value.find((V) => V.id === A.value);
|
|
469
|
-
M && c(M), r(u);
|
|
470
|
-
}
|
|
465
|
+
e.preventDefault(), n ? l(u) : r(u);
|
|
471
466
|
return;
|
|
472
467
|
}
|
|
473
468
|
if (e.key === "Escape" && n) {
|
|
@@ -476,95 +471,95 @@ const Ne = /* @__PURE__ */ $e(Ee, [["render", Ie]]), Be = ["aria-label"], Re = [
|
|
|
476
471
|
}
|
|
477
472
|
const d = e.key === "ArrowLeft" ? -1 : e.key === "ArrowRight" ? 1 : 0, x = e.key === "ArrowUp" ? -1 : e.key === "ArrowDown" ? 1 : 0;
|
|
478
473
|
d === 0 && x === 0 || !n || (e.preventDefault(), e.shiftKey ? p.resizable && m(u, d, x) : g(u, d, x));
|
|
479
|
-
},
|
|
480
|
-
const n = e.name || e.id, d =
|
|
481
|
-
return `${n}, widget ${u + 1} of ${
|
|
474
|
+
}, I = (e, u) => {
|
|
475
|
+
const n = e.name || e.id, d = G.value === e.id ? "Picked up. Arrow keys move, Enter drops, Escape cancels." : "Press Enter to pick up and rearrange with the arrow keys.";
|
|
476
|
+
return `${n}, widget ${u + 1} of ${w.value.length}. ${d}`;
|
|
482
477
|
}, L = (e) => {
|
|
483
478
|
i.value = e, setTimeout(() => {
|
|
484
479
|
i.value = "";
|
|
485
480
|
}, 1e3);
|
|
486
|
-
},
|
|
487
|
-
await de(),
|
|
481
|
+
}, H = async () => {
|
|
482
|
+
await de(), z.value && !S.value && J(z.value);
|
|
488
483
|
};
|
|
489
|
-
return ve(
|
|
490
|
-
e &&
|
|
484
|
+
return ve(H), le(o, (e) => {
|
|
485
|
+
e && H();
|
|
491
486
|
}), s({
|
|
492
487
|
rearrangeWidgets: () => {
|
|
493
|
-
|
|
488
|
+
U();
|
|
494
489
|
},
|
|
495
490
|
recalculateLayout: () => {
|
|
496
491
|
},
|
|
497
|
-
saveLayout:
|
|
498
|
-
useBuiltInPositions: () => (
|
|
499
|
-
}), (e, u) => (v(),
|
|
492
|
+
saveLayout: R,
|
|
493
|
+
useBuiltInPositions: () => (U(), !0)
|
|
494
|
+
}), (e, u) => (v(), V(Se, {
|
|
500
495
|
"no-padding": "",
|
|
501
496
|
class: "vc-gridstack-dashboard"
|
|
502
497
|
}, {
|
|
503
498
|
default: ge(() => [
|
|
504
|
-
|
|
499
|
+
X(o) ? (v(), _("div", {
|
|
505
500
|
key: 1,
|
|
506
501
|
ref_key: "gridRef",
|
|
507
|
-
ref:
|
|
502
|
+
ref: z,
|
|
508
503
|
class: "grid-stack vc-gridstack-dashboard__grid",
|
|
509
504
|
role: "list",
|
|
510
505
|
"aria-label": t.ariaLabel
|
|
511
506
|
}, [
|
|
512
|
-
(v(!0), _(re, null, ie(
|
|
507
|
+
(v(!0), _(re, null, ie(w.value, (n, d) => (v(), _("div", {
|
|
513
508
|
key: n.id,
|
|
514
|
-
class: ce(["grid-stack-item", { "vc-gridstack-dashboard__item--grabbed":
|
|
509
|
+
class: ce(["grid-stack-item", { "vc-gridstack-dashboard__item--grabbed": G.value === n.id }]),
|
|
515
510
|
"gs-id": n.id,
|
|
516
511
|
"gs-x": q(n.id)?.x ?? n.position?.x ?? 0,
|
|
517
512
|
"gs-y": q(n.id)?.y ?? n.position?.y ?? 0,
|
|
518
|
-
"gs-w":
|
|
519
|
-
"gs-h":
|
|
513
|
+
"gs-w": A(n).width,
|
|
514
|
+
"gs-h": A(n).height,
|
|
520
515
|
"gs-min-w": 2,
|
|
521
516
|
"gs-min-h": 2,
|
|
522
517
|
role: "listitem",
|
|
523
518
|
tabindex: "0",
|
|
524
|
-
"aria-label":
|
|
519
|
+
"aria-label": I(n, d),
|
|
525
520
|
onKeydown: (x) => $(x, n)
|
|
526
521
|
}, [
|
|
527
|
-
|
|
522
|
+
b("div", Fe, [
|
|
528
523
|
t.showDragHandles ? (v(), _("div", Ce, [...u[0] || (u[0] = [
|
|
529
|
-
|
|
524
|
+
b("svg", {
|
|
530
525
|
width: "16",
|
|
531
526
|
height: "16",
|
|
532
527
|
viewBox: "0 0 16 16",
|
|
533
528
|
fill: "currentColor"
|
|
534
529
|
}, [
|
|
535
|
-
|
|
530
|
+
b("circle", {
|
|
536
531
|
cx: "5",
|
|
537
532
|
cy: "3",
|
|
538
533
|
r: "1.5"
|
|
539
534
|
}),
|
|
540
|
-
|
|
535
|
+
b("circle", {
|
|
541
536
|
cx: "11",
|
|
542
537
|
cy: "3",
|
|
543
538
|
r: "1.5"
|
|
544
539
|
}),
|
|
545
|
-
|
|
540
|
+
b("circle", {
|
|
546
541
|
cx: "5",
|
|
547
542
|
cy: "8",
|
|
548
543
|
r: "1.5"
|
|
549
544
|
}),
|
|
550
|
-
|
|
545
|
+
b("circle", {
|
|
551
546
|
cx: "11",
|
|
552
547
|
cy: "8",
|
|
553
548
|
r: "1.5"
|
|
554
549
|
}),
|
|
555
|
-
|
|
550
|
+
b("circle", {
|
|
556
551
|
cx: "5",
|
|
557
552
|
cy: "13",
|
|
558
553
|
r: "1.5"
|
|
559
554
|
}),
|
|
560
|
-
|
|
555
|
+
b("circle", {
|
|
561
556
|
cx: "11",
|
|
562
557
|
cy: "13",
|
|
563
558
|
r: "1.5"
|
|
564
559
|
})
|
|
565
560
|
], -1)
|
|
566
|
-
])])) :
|
|
567
|
-
(v(),
|
|
561
|
+
])])) : N("", !0),
|
|
562
|
+
(v(), V(_e(n.component), be({ ref_for: !0 }, n.props || {}, { class: "vc-gridstack-dashboard__widget-content" }), null, 16))
|
|
568
563
|
])
|
|
569
564
|
], 42, Ue))), 128))
|
|
570
565
|
], 8, Re)) : (v(), _("div", {
|
|
@@ -574,18 +569,18 @@ const Ne = /* @__PURE__ */ $e(Ee, [["render", Ie]]), Be = ["aria-label"], Re = [
|
|
|
574
569
|
"aria-busy": "true",
|
|
575
570
|
"aria-label": t.ariaLabel
|
|
576
571
|
}, [
|
|
577
|
-
(v(!0), _(re, null, ie(y.value, (n, d) => (v(),
|
|
572
|
+
(v(!0), _(re, null, ie(y.value, (n, d) => (v(), V(Ne, {
|
|
578
573
|
key: `skeleton-${d}`,
|
|
579
574
|
class: "vc-gridstack-dashboard__skeleton-item",
|
|
580
575
|
style: ye(f(n))
|
|
581
576
|
}, null, 8, ["style"]))), 128))
|
|
582
577
|
], 8, Be)),
|
|
583
|
-
|
|
578
|
+
b("div", He, Y(i.value), 1)
|
|
584
579
|
]),
|
|
585
580
|
_: 1
|
|
586
581
|
}));
|
|
587
582
|
}
|
|
588
|
-
}), No = /* @__PURE__ */
|
|
583
|
+
}), No = /* @__PURE__ */ B({
|
|
589
584
|
__name: "DraggableDashboard",
|
|
590
585
|
props: {
|
|
591
586
|
showDragHandles: { type: Boolean, default: !1 },
|
|
@@ -605,7 +600,7 @@ const Ne = /* @__PURE__ */ $e(Ee, [["render", Ie]]), Be = ["aria-label"], Re = [
|
|
|
605
600
|
a.value?.saveLayout?.();
|
|
606
601
|
},
|
|
607
602
|
useBuiltInPositions: () => a.value?.useBuiltInPositions?.() ?? !1
|
|
608
|
-
}), (o, y) => (v(),
|
|
603
|
+
}), (o, y) => (v(), V(Ke, {
|
|
609
604
|
ref_key: "dashboardRef",
|
|
610
605
|
ref: a,
|
|
611
606
|
"show-drag-handles": t.showDragHandles,
|
|
@@ -613,7 +608,7 @@ const Ne = /* @__PURE__ */ $e(Ee, [["render", Ie]]), Be = ["aria-label"], Re = [
|
|
|
613
608
|
"aria-label": t.ariaLabel
|
|
614
609
|
}, null, 8, ["show-drag-handles", "resizable", "aria-label"]));
|
|
615
610
|
}
|
|
616
|
-
}), Bo =
|
|
611
|
+
}), Bo = Z, Ro = ee, Uo = te, Fo = ue, Co = oe, Ho = Ge, Ko = j, je = { class: "dashboard-widget-card" }, qe = { class: "dashboard-widget-card__header" }, Ve = { class: "dashboard-widget-card__header-content" }, Ye = {
|
|
617
612
|
key: 0,
|
|
618
613
|
class: "dashboard-widget-card__icon-wrapper"
|
|
619
614
|
}, Je = { class: "dashboard-widget-card__title" }, Qe = {
|
|
@@ -625,7 +620,7 @@ const Ne = /* @__PURE__ */ $e(Ee, [["render", Ie]]), Be = ["aria-label"], Re = [
|
|
|
625
620
|
}, Ze = { class: "dashboard-widget-card__body" }, et = {
|
|
626
621
|
key: 1,
|
|
627
622
|
class: "dashboard-widget-card__footer"
|
|
628
|
-
}, jo = /* @__PURE__ */
|
|
623
|
+
}, jo = /* @__PURE__ */ B({
|
|
629
624
|
__name: "dashboard-widget-card",
|
|
630
625
|
props: {
|
|
631
626
|
header: {},
|
|
@@ -635,37 +630,37 @@ const Ne = /* @__PURE__ */ $e(Ee, [["render", Ie]]), Be = ["aria-label"], Re = [
|
|
|
635
630
|
setup(t) {
|
|
636
631
|
const s = t;
|
|
637
632
|
return (a, h) => (v(), _("div", je, [
|
|
638
|
-
|
|
639
|
-
|
|
640
|
-
|
|
633
|
+
b("div", qe, [
|
|
634
|
+
M(a.$slots, "header", {}, () => [
|
|
635
|
+
b("div", Ve, [
|
|
641
636
|
t.icon ? (v(), _("div", Ye, [
|
|
642
|
-
we(
|
|
637
|
+
we(X(De), {
|
|
643
638
|
class: "dashboard-widget-card__icon",
|
|
644
639
|
icon: t.icon,
|
|
645
640
|
size: "l"
|
|
646
641
|
}, null, 8, ["icon"])
|
|
647
|
-
])) :
|
|
648
|
-
|
|
642
|
+
])) : N("", !0),
|
|
643
|
+
b("div", Je, Y(s.header), 1)
|
|
649
644
|
])
|
|
650
645
|
]),
|
|
651
646
|
a.$slots.actions ? (v(), _("div", Qe, [
|
|
652
|
-
|
|
653
|
-
])) :
|
|
647
|
+
M(a.$slots, "actions")
|
|
648
|
+
])) : N("", !0)
|
|
654
649
|
]),
|
|
655
650
|
a.$slots.stats ? (v(), _("div", Xe, [
|
|
656
|
-
|
|
657
|
-
])) :
|
|
651
|
+
M(a.$slots, "stats")
|
|
652
|
+
])) : N("", !0),
|
|
658
653
|
ke((v(), _("div", Ze, [
|
|
659
|
-
|
|
654
|
+
M(a.$slots, "content")
|
|
660
655
|
])), [
|
|
661
|
-
[
|
|
656
|
+
[X(Le), t.loading]
|
|
662
657
|
]),
|
|
663
658
|
a.$slots.footer ? (v(), _("div", et, [
|
|
664
|
-
|
|
665
|
-
])) :
|
|
659
|
+
M(a.$slots, "footer")
|
|
660
|
+
])) : N("", !0)
|
|
666
661
|
]));
|
|
667
662
|
}
|
|
668
|
-
}), tt = { class: "dashboard-stat-item" }, ot = { class: "dashboard-stat-item__label" }, qo = /* @__PURE__ */
|
|
663
|
+
}), tt = { class: "dashboard-stat-item" }, ot = { class: "dashboard-stat-item__label" }, qo = /* @__PURE__ */ B({
|
|
669
664
|
__name: "dashboard-stat-item",
|
|
670
665
|
props: {
|
|
671
666
|
value: {},
|
|
@@ -674,23 +669,23 @@ const Ne = /* @__PURE__ */ $e(Ee, [["render", Ie]]), Be = ["aria-label"], Re = [
|
|
|
674
669
|
},
|
|
675
670
|
setup(t) {
|
|
676
671
|
return (s, a) => (v(), _("div", tt, [
|
|
677
|
-
|
|
672
|
+
b("div", {
|
|
678
673
|
class: ce(["dashboard-stat-item__value", t.variant ? `dashboard-stat-item__value--${t.variant}` : ""])
|
|
679
|
-
},
|
|
680
|
-
|
|
674
|
+
}, Y(t.value), 3),
|
|
675
|
+
b("div", ot, Y(t.label), 1)
|
|
681
676
|
]));
|
|
682
677
|
}
|
|
683
|
-
}), at = { class: "tw-divide-y tw-divide-[var(--neutrals-200)]" }, Vo = /* @__PURE__ */
|
|
678
|
+
}), at = { class: "tw-divide-y tw-divide-[var(--neutrals-200)]" }, Vo = /* @__PURE__ */ B({
|
|
684
679
|
__name: "dashboard-feed-list",
|
|
685
680
|
setup(t) {
|
|
686
681
|
return (s, a) => (v(), _("div", at, [
|
|
687
|
-
|
|
682
|
+
M(s.$slots, "default")
|
|
688
683
|
]));
|
|
689
684
|
}
|
|
690
685
|
}), st = { class: "tw-flex tw-items-center tw-gap-2.5 tw-min-w-0" }, rt = {
|
|
691
686
|
key: 0,
|
|
692
687
|
class: "tw-flex tw-items-center tw-gap-3 tw-flex-shrink-0 tw-ml-3"
|
|
693
|
-
}, Yo = /* @__PURE__ */
|
|
688
|
+
}, Yo = /* @__PURE__ */ B({
|
|
694
689
|
__name: "dashboard-feed-row",
|
|
695
690
|
emits: ["click"],
|
|
696
691
|
setup(t) {
|
|
@@ -698,12 +693,12 @@ const Ne = /* @__PURE__ */ $e(Ee, [["render", Ie]]), Be = ["aria-label"], Re = [
|
|
|
698
693
|
class: "dashboard-feed-row",
|
|
699
694
|
onClick: a[0] || (a[0] = (h) => s.$emit("click"))
|
|
700
695
|
}, [
|
|
701
|
-
|
|
702
|
-
|
|
696
|
+
b("div", st, [
|
|
697
|
+
M(s.$slots, "default")
|
|
703
698
|
]),
|
|
704
699
|
s.$slots.trailing ? (v(), _("div", rt, [
|
|
705
|
-
|
|
706
|
-
])) :
|
|
700
|
+
M(s.$slots, "trailing")
|
|
701
|
+
])) : N("", !0)
|
|
707
702
|
]));
|
|
708
703
|
}
|
|
709
704
|
});
|