@primeui/vue-taskboard 0.0.1-alpha.1 → 1.0.0-beta.1

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 (126) hide show
  1. package/dist/TaskBoard.context.d.ts +21 -21
  2. package/dist/TaskBoard.parts.d.ts +20 -20
  3. package/dist/TaskBoard.vue.d.ts +37 -37
  4. package/dist/TaskBoardContent.vue.d.ts +2 -2
  5. package/dist/chunks/TaskBoard.context-BCq7uauT.mjs +29 -0
  6. package/dist/chunks/TaskBoard.vue_vue_type_script_setup_true_lang-Djmr6yoF.mjs +841 -0
  7. package/dist/chunks/TaskBoardCard.vue_vue_type_script_setup_true_lang-B1Ix7Gjf.mjs +34 -0
  8. package/dist/chunks/TaskBoardCardAdd.vue_vue_type_script_setup_true_lang-Dy4BuCa9.mjs +14 -0
  9. package/dist/chunks/TaskBoardCardContent.vue_vue_type_script_setup_true_lang-DNEmpvcn.mjs +19 -0
  10. package/dist/chunks/TaskBoardCardFooter.vue_vue_type_script_setup_true_lang-8FWnuxSl.mjs +19 -0
  11. package/dist/chunks/TaskBoardCardHeader.vue_vue_type_script_setup_true_lang-Dr-XJfaE.mjs +19 -0
  12. package/dist/chunks/TaskBoardColumn.vue_vue_type_script_setup_true_lang-D_AJ5j7c.mjs +42 -0
  13. package/dist/chunks/TaskBoardColumnAdd-C_JSN3pp.mjs +10 -0
  14. package/dist/chunks/TaskBoardColumnContent.vue_vue_type_script_setup_true_lang-DNRiWBN_.mjs +180 -0
  15. package/dist/chunks/TaskBoardColumnEmpty.vue_vue_type_script_setup_true_lang-D23AtNeX.mjs +18 -0
  16. package/dist/chunks/TaskBoardColumnFooter.vue_vue_type_script_setup_true_lang-BpKRnC6u.mjs +19 -0
  17. package/dist/chunks/TaskBoardColumnHeader.vue_vue_type_script_setup_true_lang-DMc9zcWV.mjs +51 -0
  18. package/dist/chunks/TaskBoardContent.vue_vue_type_script_setup_true_lang-lDUg6UrJ.mjs +292 -0
  19. package/dist/chunks/TaskBoardDragConfirm.vue_vue_type_script_setup_true_lang-B4OdxK5L.mjs +20 -0
  20. package/dist/chunks/TaskBoardDragPreview.vue_vue_type_script_setup_true_lang-B7F-FPY1.mjs +40 -0
  21. package/dist/chunks/TaskBoardDropIndicator-BUMSBiQC.mjs +14 -0
  22. package/dist/chunks/TaskBoardHeader.vue_vue_type_script_setup_true_lang-CwtaadkE.mjs +21 -0
  23. package/dist/chunks/TaskBoardLoading-CrgtYPP-.mjs +10 -0
  24. package/dist/chunks/TaskBoardSwimlaneColumnHeader.vue_vue_type_script_setup_true_lang-BVpen7mj.mjs +23 -0
  25. package/dist/chunks/TaskBoardSwimlaneHeader.vue_vue_type_script_setup_true_lang-D6NdS4hP.mjs +32 -0
  26. package/dist/chunks/_plugin-vue_export-helper-CHgC5LLL.mjs +9 -0
  27. package/dist/chunks/useHistory-C-Ud-WgS.mjs +510 -0
  28. package/dist/chunks/useTaskBoardDrag-BvBISSNb.mjs +58 -0
  29. package/dist/components/card/TaskBoardCard.vue.d.ts +3 -3
  30. package/dist/components/card/TaskBoardCardContent.vue.d.ts +1 -1
  31. package/dist/components/card/TaskBoardCardFooter.vue.d.ts +1 -1
  32. package/dist/components/card/TaskBoardCardHeader.vue.d.ts +1 -1
  33. package/dist/components/column/TaskBoardColumn.vue.d.ts +2 -2
  34. package/dist/components/column/TaskBoardColumnContent.vue.d.ts +1 -1
  35. package/dist/components/column/TaskBoardColumnFooter.vue.d.ts +1 -1
  36. package/dist/components/column/TaskBoardColumnHeader.vue.d.ts +1 -1
  37. package/dist/components/overlay/TaskBoardDragConfirm.vue.d.ts +2 -2
  38. package/dist/components/swimlane/TaskBoardSwimlaneColumnHeader.vue.d.ts +3 -3
  39. package/dist/components.d.ts +20 -0
  40. package/dist/components.mjs +42 -0
  41. package/dist/composables/index.mjs +6 -5
  42. package/dist/composables/useCardDrag.d.ts +2 -2
  43. package/dist/composables/useColumnDrag.d.ts +5 -5
  44. package/dist/composables/useControllerInit.d.ts +3 -3
  45. package/dist/composables/useKeyboardHandling.d.ts +2 -2
  46. package/dist/index.d.ts +20 -20
  47. package/dist/index.mjs +77 -1650
  48. package/dist/parts/card/index.d.ts +1 -0
  49. package/dist/parts/card/index.mjs +4 -0
  50. package/dist/parts/cardadd/index.d.ts +1 -0
  51. package/dist/parts/cardadd/index.mjs +4 -0
  52. package/dist/parts/cardcontent/index.d.ts +1 -0
  53. package/dist/parts/cardcontent/index.mjs +4 -0
  54. package/dist/parts/cardfooter/index.d.ts +1 -0
  55. package/dist/parts/cardfooter/index.mjs +4 -0
  56. package/dist/parts/cardheader/index.d.ts +1 -0
  57. package/dist/parts/cardheader/index.mjs +4 -0
  58. package/dist/parts/column/index.d.ts +1 -0
  59. package/dist/parts/column/index.mjs +4 -0
  60. package/dist/parts/columnadd/index.d.ts +1 -0
  61. package/dist/parts/columnadd/index.mjs +4 -0
  62. package/dist/parts/columncontent/index.d.ts +1 -0
  63. package/dist/parts/columncontent/index.mjs +4 -0
  64. package/dist/parts/columnempty/index.d.ts +1 -0
  65. package/dist/parts/columnempty/index.mjs +4 -0
  66. package/dist/parts/columnfooter/index.d.ts +1 -0
  67. package/dist/parts/columnfooter/index.mjs +4 -0
  68. package/dist/parts/columnheader/index.d.ts +1 -0
  69. package/dist/parts/columnheader/index.mjs +4 -0
  70. package/dist/parts/content/index.d.ts +1 -0
  71. package/dist/parts/content/index.mjs +4 -0
  72. package/dist/parts/dragconfirm/index.d.ts +1 -0
  73. package/dist/parts/dragconfirm/index.mjs +4 -0
  74. package/dist/parts/dragpreview/index.d.ts +1 -0
  75. package/dist/parts/dragpreview/index.mjs +4 -0
  76. package/dist/parts/dropindicator/index.d.ts +1 -0
  77. package/dist/parts/dropindicator/index.mjs +4 -0
  78. package/dist/parts/header/index.d.ts +1 -0
  79. package/dist/parts/header/index.mjs +4 -0
  80. package/dist/parts/loading/index.d.ts +1 -0
  81. package/dist/parts/loading/index.mjs +4 -0
  82. package/dist/parts/root/index.d.ts +1 -0
  83. package/dist/parts/root/index.mjs +4 -0
  84. package/dist/parts/swimlanecolumnheader/index.d.ts +1 -0
  85. package/dist/parts/swimlanecolumnheader/index.mjs +4 -0
  86. package/dist/parts/swimlaneheader/index.d.ts +1 -0
  87. package/dist/parts/swimlaneheader/index.mjs +4 -0
  88. package/package.json +22 -12
  89. package/dist/TaskBoard.context.d.mts +0 -235
  90. package/dist/TaskBoard.parts.d.mts +0 -20
  91. package/dist/TaskBoard.vue.d.mts +0 -291
  92. package/dist/TaskBoardContent.vue.d.mts +0 -27
  93. package/dist/TaskBoardHeader.vue.d.mts +0 -18
  94. package/dist/TaskBoardLoading.vue.d.mts +0 -13
  95. package/dist/chunks/useTaskBoardDrag-ByZvmcfw.mjs +0 -590
  96. package/dist/components/card/TaskBoardCard.vue.d.mts +0 -23
  97. package/dist/components/card/TaskBoardCardAdd.vue.d.mts +0 -15
  98. package/dist/components/card/TaskBoardCardContent.vue.d.mts +0 -18
  99. package/dist/components/card/TaskBoardCardFooter.vue.d.mts +0 -18
  100. package/dist/components/card/TaskBoardCardHeader.vue.d.mts +0 -18
  101. package/dist/components/column/TaskBoardColumn.vue.d.mts +0 -19
  102. package/dist/components/column/TaskBoardColumnAdd.vue.d.mts +0 -13
  103. package/dist/components/column/TaskBoardColumnContent.vue.d.mts +0 -20
  104. package/dist/components/column/TaskBoardColumnEmpty.vue.d.mts +0 -13
  105. package/dist/components/column/TaskBoardColumnFooter.vue.d.mts +0 -16
  106. package/dist/components/column/TaskBoardColumnHeader.vue.d.mts +0 -19
  107. package/dist/components/overlay/TaskBoardDragConfirm.vue.d.mts +0 -20
  108. package/dist/components/overlay/TaskBoardDragPreview.vue.d.mts +0 -16
  109. package/dist/components/overlay/TaskBoardDropIndicator.d.mts +0 -2
  110. package/dist/components/swimlane/TaskBoardSwimlaneColumnHeader.vue.d.mts +0 -20
  111. package/dist/components/swimlane/TaskBoardSwimlaneHeader.vue.d.mts +0 -22
  112. package/dist/composables/index.d.mts +0 -9
  113. package/dist/composables/useCardDrag.d.mts +0 -47
  114. package/dist/composables/useCardDragGeometry.d.mts +0 -21
  115. package/dist/composables/useColumnDrag.d.mts +0 -24
  116. package/dist/composables/useControllerInit.d.mts +0 -64
  117. package/dist/composables/useHistory.d.mts +0 -15
  118. package/dist/composables/useKeyboardHandling.d.mts +0 -37
  119. package/dist/composables/useTaskBoardAccess.d.mts +0 -9
  120. package/dist/composables/useTaskBoardDrag.d.mts +0 -14
  121. package/dist/composables/useTaskBoardHistory.d.mts +0 -6
  122. package/dist/composables/useTaskBoardPrintRuntime.d.mts +0 -7
  123. package/dist/composables/useTaskBoardSelection.d.mts +0 -11
  124. package/dist/composables/useTaskBoardWorkflow.d.mts +0 -8
  125. package/dist/index.d.mts +0 -29
  126. package/dist/release-date.d.mts +0 -11
package/dist/index.mjs CHANGED
@@ -1,1654 +1,81 @@
1
- import { onBeforeUnmount as je, nextTick as Se, defineComponent as V, useModel as ua, computed as g, ref as x, watch as Z, provide as $e, onMounted as ke, openBlock as i, createElementBlock as c, unref as t, normalizeClass as k, createElementVNode as B, toDisplayString as te, createCommentVNode as $, renderSlot as A, createBlock as z, Teleport as Xl, normalizeStyle as ue, mergeModels as Ul, inject as L, Fragment as E, renderList as pe, createTextVNode as Be, resolveDynamicComponent as ee, withModifiers as Re, mergeProps as Jl, useSlots as qe, toRef as zl, h as ia } from "vue";
2
- import { verifyLicense as ca } from "@primeui/license-manager";
3
- import { classes as U, createTaskIndex as ma, createDataAccessor as va, processColumns as ga, isFeatureEnabled as pa, computeColumnGroupSegments as Ca, processSwimlanes as Nl, resolveRootClasses as fa, exportToCSV as jl, exportToJSON as ql, canMoveIntoColumn as Sa, canMoveOutOfColumn as ka, canViewColumn as Ia, calculateVisibleRangeDynamic as Ql, countSwimlaneTasks as wa, resolveSwimlaneRowClasses as ha, getOrderedColumnTasks as ya, getColumnTasksFromIndex as Sl, toggleCollapsedIds as ba, getOrderedCellTasks as Ta, getCellTasksFromIndex as Yl, countColumnTasks as xa, resolveColumnClasses as Da, resolveCardClasses as Ha, serializeBoardState as _a, deserializeBoardState as Ma, applyTaskUpdate as Ba, applyTaskCreate as Ra, applyCardMove as $a, applyTaskDelete as Aa } from "@primeui/taskboard-core";
4
- import { b as Ea, u as Pa, a as Fa, c as La, T as Y, C as he, S as Zl, i as sl } from "./chunks/useTaskBoardDrag-ByZvmcfw.mjs";
5
- import { d as Yo, j as Xo, k as Jo, l as Qo, e as Zo, f as en, g as ln, m as tn, h as an } from "./chunks/useTaskBoardDrag-ByZvmcfw.mjs";
6
- let Ne = null;
7
- const Va = /* @__PURE__ */ new Set(["INPUT", "TEXTAREA", "SELECT", "BUTTON"]), Ka = /* @__PURE__ */ new Set(["button", "link", "menuitem", "option", "checkbox", "radio", "switch", "textbox", "combobox", "listbox", "tab", "slider"]), Ga = (s) => (s.closest("[role]")?.getAttribute("role")?.split(/\s+/).filter(Boolean) ?? []).some((o) => Ka.has(o.toLowerCase())), Oa = (s) => {
8
- const l = s.closest("[contenteditable]");
9
- if (!l) return !1;
10
- const n = l.getAttribute("contenteditable");
11
- return n == null || n === "" || n.toLowerCase() !== "false";
12
- }, Wa = (s) => !!s.closest("label")?.querySelector("input:not([disabled]), textarea:not([disabled]), select:not([disabled]), button:not([disabled])");
13
- function Ua(s) {
14
- if (!(s instanceof Element)) return !1;
15
- if (s.closest("a[href]")) return !0;
16
- const l = s.closest("input, textarea, select, button");
17
- return l && Va.has(l.tagName) ? !0 : Oa(s) || Ga(s) || Wa(s);
18
- }
19
- function za(s, l) {
20
- return s.altKey || s.ctrlKey || s.metaKey ? !1 : l === "Tab" ? !0 : s.shiftKey ? !1 : l === "ArrowUp" || l === "ArrowDown" || l === "ArrowLeft" || l === "ArrowRight" || l === "Home" || l === "End";
21
- }
22
- function Na(s) {
23
- const l = () => {
24
- s.rootRef.value && (Ne = s.rootRef.value);
25
- }, n = () => {
26
- Ne === s.rootRef.value && (Ne = null);
27
- }, o = (C) => {
28
- const y = s.rootRef.value;
29
- return y ? C.target instanceof Node && y.contains(C.target) ? (Ne = y, !0) : Ne === y : !0;
30
- };
31
- return { onKeyDown: (C) => {
32
- if (!o(C)) return;
33
- const y = Ua(C.target), R = C.key.length === 1 ? C.key.toLowerCase() : C.key, I = R === "Escape";
34
- if (y && !I)
35
- return;
36
- if ((C.ctrlKey || C.metaKey) && R === "z") {
37
- C.preventDefault(), C.shiftKey ? s.performRedo() : s.performUndo();
38
- return;
39
- }
40
- if ((C.ctrlKey || C.metaKey) && R === "y") {
41
- C.preventDefault(), s.performRedo();
42
- return;
43
- }
44
- if (I && s.isDragging.value) {
45
- if (y)
46
- return;
47
- const H = s.draggedCardData.value, b = s.getDragController(), F = b?.state.sourceColumnId, d = F != null ? s.allColumns.value.find((S) => S.id === F) : null;
48
- b?.cancel(), H && d && s.emit("dragCancel", { card: H, column: d }), s.isDragging.value = !1, s.draggedCardId.value = null, s.dragTargetColumnId.value = null, s.dragTargetIndex.value = null, s.dragTargetSwimlaneId.value = null, s.ghostPosition.value = null, s.draggedCardData.value = null, document.removeEventListener("pointermove", s.onDocumentPointerMove), document.removeEventListener("pointerup", s.onDocumentPointerUp);
49
- return;
50
- }
51
- if (I) {
52
- if (y)
53
- return;
54
- if (s.selectedCardIds.value.length > 0) {
55
- s.getSelectionController()?.clearSelection();
56
- return;
57
- }
58
- if (s.focusedCardId.value != null) {
59
- s.focusedCardId.value = null, s.focusedColumnId.value = null, s.focusedSwimlaneId.value = null;
60
- const H = s.getKeyboardController();
61
- H && (H.focusedCardId = null, H.focusedColumnId = null, H.focusedSwimlaneId = null);
62
- return;
63
- }
64
- if (s.focusedColumnId.value != null) {
65
- s.focusedColumnId.value = null, s.focusedSwimlaneId.value = null;
66
- const H = s.getKeyboardController();
67
- H && (H.focusedColumnId = null, H.focusedSwimlaneId = null);
68
- }
69
- return;
70
- }
71
- (s.getKeyboardController()?.handleKeyDown(C) ?? !1) && s.selectionOrigin.value === "pointer" && s.selectedCardIds.value.length > 0 && za(C, R) && (s.selectionOrigin.value = null, s.getSelectionController()?.clearSelection());
72
- }, onDocumentClick: (C) => {
73
- if (s.rootRef.value && !s.rootRef.value.contains(C.target)) {
74
- if (n(), s.selectedCardIds.value.length > 0 && s.getSelectionController()?.clearSelection(), s.focusedCardId.value != null) {
75
- s.focusedCardId.value = null, s.focusedColumnId.value = null, s.focusedSwimlaneId.value = null;
76
- const y = s.getKeyboardController();
77
- y && (y.focusedCardId = null, y.focusedColumnId = null, y.focusedSwimlaneId = null);
78
- } else if (s.focusedColumnId.value != null) {
79
- s.focusedColumnId.value = null, s.focusedSwimlaneId.value = null;
80
- const y = s.getKeyboardController();
81
- y && (y.focusedColumnId = null, y.focusedSwimlaneId = null);
82
- }
83
- }
84
- }, activateKeyboardScope: l, deactivateKeyboardScope: n };
85
- }
86
- function ja(s) {
87
- let l = null;
88
- je(() => {
89
- l?.(), l = null;
90
- });
91
- const n = (p, m) => {
92
- try {
93
- window.scrollTo(p, m);
94
- } catch {
95
- }
96
- };
97
- return {
98
- print: () => {
99
- if (!s.rootRef.value) return;
100
- l?.(), l = null;
101
- const p = s.rootRef.value, m = document.body, C = m.classList.contains(U.printActive), y = p.classList.contains(U.printing), R = p.getAttribute("data-print-target"), I = p.hasAttribute("data-print-target"), K = window.scrollX, H = window.scrollY, b = /* @__PURE__ */ new Map();
102
- Se(() => {
103
- if (s.rootRef.value !== p) return;
104
- let F = !1;
105
- const d = () => {
106
- F || (F = !0, window.removeEventListener("afterprint", d), C ? m.classList.add(U.printActive) : m.classList.remove(U.printActive), y ? p.classList.add(U.printing) : p.classList.remove(U.printing), I ? p.setAttribute("data-print-target", R ?? "") : p.removeAttribute("data-print-target"), b.forEach((u, f) => {
107
- u ? f.classList.add(U.printAncestor) : f.classList.remove(U.printAncestor);
108
- }), n(K, H), l === d && (l = null));
109
- };
110
- l = d, m.classList.add(U.printActive), p.classList.add(U.printing), p.setAttribute("data-print-target", "true");
111
- let S = p.parentElement;
112
- for (; S && S !== m; )
113
- b.set(S, S.classList.contains(U.printAncestor)), S.classList.add(U.printAncestor), S = S.parentElement;
114
- n(0, 0), window.addEventListener("afterprint", d);
115
- try {
116
- window.print();
117
- } catch (u) {
118
- throw d(), u;
119
- }
120
- });
121
- }
122
- };
123
- }
124
- const qa = "2026-04-23", Ya = ["dir"], Xa = {
125
- key: 0,
126
- role: "alert",
127
- class: "p-taskboard-license-banner",
128
- style: { display: "flex", "align-items": "center", gap: "8px", padding: "10px 14px", "margin-bottom": "12px", background: "#fef2f2", border: "1px solid #fecaca", color: "#991b1b", "border-radius": "6px", "font-size": "13px" }
129
- }, Ja = ["innerHTML"], Qa = {
130
- "aria-live": "polite",
131
- "aria-atomic": "true",
132
- style: { position: "absolute", width: "1px", height: "1px", overflow: "hidden", "clip-path": "inset(50%)", "white-space": "nowrap" }
133
- }, Za = /* @__PURE__ */ V({
134
- __name: "TaskBoard",
135
- props: /* @__PURE__ */ Ul({
136
- columns: { default: () => [] },
137
- swimlanes: { default: () => [] },
138
- draggable: { type: Boolean, default: !0 },
139
- selectionMode: { default: "none" },
140
- contextMenu: { type: Boolean, default: !1 },
141
- density: { default: "standard" },
142
- features: {},
143
- rtl: { type: Boolean },
144
- disabled: { type: Boolean, default: !1 },
145
- readonly: { type: Boolean, default: !1 },
146
- columnWidth: {},
147
- cardGap: {},
148
- scrollable: { type: Boolean, default: !0 },
149
- dragMinDistance: {},
150
- columnCollapsible: { type: Boolean, default: !0 },
151
- columnReorderable: { type: Boolean, default: !1 },
152
- columnGroups: {},
153
- virtualScroll: { type: Boolean, default: !1 },
154
- virtualScrollItemHeight: { default: 250 },
155
- virtualScrollBuffer: { default: 3 },
156
- access: {},
157
- items: {},
158
- dataKey: {},
159
- columnField: {},
160
- swimlaneField: {}
161
- }, {
162
- tasks: { default: () => [] },
163
- tasksModifiers: {}
164
- }),
165
- emits: /* @__PURE__ */ Ul(["cardMove", "cardClick", "cardDblclick", "cardActivate", "cardSelect", "selectionChange", "cardCreate", "cardUpdate", "cardDelete", "columnCollapse", "columnReorder", "swimlaneCollapse", "dragStart", "dragEnd", "dragCancel", "cardContextMenu", "cardDropBlocked", "cardReorder"], ["update:tasks"]),
166
- setup(s, { expose: l, emit: n }) {
167
- const o = s, p = ua(s, "tasks"), m = g(() => o.items ?? p.value ?? []), C = g(() => ma(m.value ?? [], { columnField: o.columnField, swimlaneField: o.swimlaneField })), y = g(() => va({ dataKey: o.dataKey, columnField: o.columnField, swimlaneField: o.swimlaneField })), R = g(() => ({ idField: o.dataKey, columnField: o.columnField, swimlaneField: o.swimlaneField })), I = (e) => y.value.getItemId(e), K = (e) => y.value.getItemColumnValue(e), H = (e) => y.value.getItemSwimlaneValue(e), b = n, F = x(), d = x(), S = x(), u = x(null), f = x(null), D = x(null), le = x(""), G = x(null), ie = g(() => !!G.value?.valid), Ae = g(() => G.value?.message ?? null), ne = x(null), N = x([]), Ee = x(null), ae = x([]), ce = x([]), Ce = x(null), Ye = x(!1), X = x(!1), Pe = x(null), re = x(null), Ie = x(null), j = x(null), fe = x(null), Xe = x(0), ye = x(null), me = x(null);
168
- let O = () => {
169
- };
170
- const Fe = g(() => {
171
- if (!X.value || !me.value || !F.value) return null;
172
- const e = String(I(me.value)), a = Array.from(F.value.querySelectorAll("[data-task-id]")).find((r) => r.getAttribute("data-task-id") === e);
173
- return a ? a.innerHTML : null;
174
- }), be = x(!1), v = x(null), T = x(0), h = x(/* @__PURE__ */ new Map()), M = (e) => {
175
- le.value = "", Se(() => {
176
- le.value = e;
177
- });
178
- }, P = g(() => ga(o.columns ?? [])), J = x([]), Le = (e) => {
179
- J.value.some((a) => String(a.id) === String(e.id)) || (J.value = [...J.value, e]);
180
- }, ve = (e) => {
181
- J.value = J.value.filter((a) => String(a.id) !== String(e));
182
- }, W = g(() => P.value.length > 0 ? P.value : J.value), Ve = x(null), Ke = x(null), Te = x(null), lt = (e) => {
183
- Ve.value = e;
184
- }, tt = (e) => {
185
- Ke.value = e;
186
- }, at = (e) => {
187
- Te.value = e;
188
- }, kl = x(null), ot = (e) => {
189
- kl.value = e;
190
- }, Il = x(null), nt = (e) => {
191
- Il.value = e;
192
- }, Je = g(() => o.access?.canDrag !== !1 && o.draggable && Qe("dragDrop")), rt = g(() => o.access?.canEdit !== !1), wl = g(() => o.access?.canCreate !== !1), st = g(() => o.access?.canDelete !== !1), dt = g(() => o.access?.canReorderColumns !== !1 && o.columnReorderable && Qe("columnReorder")), hl = (e) => Sa(o.access, e), dl = (e) => ka(o.access, e), yl = (e) => Ia(o.access, e), Qe = (e) => pa(o.features, e), Ze = g(() => W.value.filter((e) => yl(e.id))), se = g(() => (o.swimlanes ?? []).length > 0), ut = g(() => (o.columnGroups ?? []).length > 0), it = g(() => Ca(Ze.value, o.columnGroups ?? [])), ct = g(
193
- () => Ze.value.map((e) => {
194
- const a = (o.columnGroups ?? []).find((r) => r.columns.some((w) => String(w) === String(e.id)));
195
- return {
196
- key: `column-${e.id}`,
197
- column: e,
198
- label: a?.label,
199
- group: a
200
- };
201
- })
202
- ), mt = (e) => {
203
- const a = "var(--p-taskboard-column-effective-width, var(--p-taskboard-column-min-width))", r = {};
204
- if (e.group?.color && (r["--p-taskboard-column-group-color"] = e.group.color), e.span === 1)
205
- return { ...r, flex: `1 0 ${a}`, minWidth: a };
206
- const w = `calc(${e.span} * ${a} + ${e.span - 1} * var(--p-taskboard-column-gap))`;
207
- return { ...r, flex: `${e.span} 0 ${w}`, minWidth: w };
208
- }, vt = (e) => {
209
- const a = "var(--p-taskboard-column-effective-width, var(--p-taskboard-column-min-width))", r = {};
210
- return e?.group?.color && (r["--p-taskboard-column-group-color"] = e.group.color), { ...r, flex: `0 0 ${a}`, minWidth: a };
211
- }, gt = (e) => e.columnIds ? e.columnIds.map((a) => Ze.value.find((r) => String(r.id) === String(a))).filter(Boolean) : [], pt = () => {
212
- O();
213
- }, Q = g(() => Nl(o.swimlanes ?? [])), Ct = g(() => {
214
- if (!o.virtualScroll)
215
- return Q.value;
216
- if (!Ce.value) {
217
- const e = o.virtualScrollItemHeight ?? 250, a = o.virtualScrollBuffer ?? 3, r = Math.ceil(600 / e) + a * 2;
218
- return Q.value.slice(0, Math.min(r, Q.value.length));
219
- }
220
- return Q.value.slice(Ce.value.startIndex, Ce.value.endIndex);
221
- });
222
- let ul = 0, we = null;
223
- const Ge = /* @__PURE__ */ new Map(), Oe = x(/* @__PURE__ */ new Map()), bl = () => o.virtualScrollItemHeight ?? 250, ft = () => o.virtualScrollBuffer ?? 3, xe = (e) => String(e.id), il = (e) => Ge.get(xe(e)) ?? bl(), St = (e = Q.value) => e.map((a) => Ge.get(xe(a)) ?? 0), kt = (e) => e.reduce((a, r) => a + il(r), 0), Tl = (e, a, r) => Math.max(0, Math.min(e, Math.max(0, kt(a) - r))), It = (e, a) => {
224
- let r = 0;
225
- for (let w = 0; w < Math.max(0, a); w++)
226
- r += il(e[w]);
227
- return r;
228
- }, wt = (e, a) => {
229
- let r = 0;
230
- for (let w = 0; w < e.length; w++) {
231
- const _ = il(e[w]);
232
- if (r + _ > a)
233
- return w;
234
- r += _;
235
- }
236
- return Math.max(0, e.length - 1);
237
- }, ht = (e, a = Q.value) => a.length ? xe(a[wt(a, e)]) : null, yt = (e = Q.value) => {
238
- const a = new Set(e.map((r) => xe(r)));
239
- for (const r of Ge.keys())
240
- a.has(r) || Ge.delete(r);
241
- }, el = () => {
242
- if (!d.value) return;
243
- const e = d.value.querySelectorAll('[role="rowgroup"][data-swimlane-id]'), a = /* @__PURE__ */ new Set();
244
- e.forEach((r) => {
245
- const w = r.getAttribute("data-swimlane-id");
246
- !w || a.has(w) || (a.add(w), Ge.set(w, r.offsetHeight));
247
- });
248
- }, bt = () => {
249
- if (!d.value || !se.value) {
250
- Oe.value = /* @__PURE__ */ new Map();
251
- return;
252
- }
253
- const e = /* @__PURE__ */ new Map();
254
- d.value.querySelectorAll('[role="rowgroup"][data-swimlane-id]').forEach((r) => {
255
- const w = r.getAttribute("data-swimlane-id"), _ = r.offsetHeight;
256
- w && _ > 0 && e.set(w, _);
257
- }), Oe.value = e;
258
- };
259
- Z(
260
- X,
261
- (e) => {
262
- if (!se.value) {
263
- Oe.value = /* @__PURE__ */ new Map();
264
- return;
265
- }
266
- e ? bt() : Oe.value = /* @__PURE__ */ new Map();
267
- },
268
- { flush: "sync" }
269
- );
270
- const ll = (e, a) => {
271
- const r = Tl(e, Q.value, a);
272
- d.value && Math.abs(d.value.scrollTop - r) > 1 && (d.value.scrollTop = r), ul = r, Ce.value = Ql(r, a, Q.value.length, St(), bl(), ft());
273
- }, xl = (e = Q.value) => {
274
- if (!o.virtualScroll || !se.value || !d.value) return;
275
- const r = d.value.scrollTop, w = ht(r, e);
276
- yt(), Se(() => {
277
- if (!d.value) return;
278
- const _ = Q.value, oe = w == null ? -1 : _.findIndex((fl) => xe(fl) === w), Ue = oe >= 0 ? It(_, oe) : r, ze = Tl(Ue, _, d.value.clientHeight ?? 600);
279
- d.value.scrollTop = ze, el(), ll(ze, d.value.clientHeight ?? 600), O();
280
- });
281
- };
282
- Z(
283
- () => d.value,
284
- (e) => {
285
- e && o.virtualScroll && se.value && !Ce.value && Se(() => {
286
- el(), ll(0, e.clientHeight ?? 600);
287
- });
288
- }
289
- );
290
- const Tt = (e) => {
291
- if (O(), !o.virtualScroll || !se.value) return;
292
- const a = e.target;
293
- Math.abs(a.scrollTop - ul) < 1 || (ul = a.scrollTop, we && cancelAnimationFrame(we), we = requestAnimationFrame(() => {
294
- el(), ll(a.scrollTop, a.clientHeight), O(), we = null;
295
- }));
296
- }, xt = (e) => o.swimlaneField ? wa(C.value, e) : 0, cl = (e) => ce.value.some((a) => String(a) === String(e)), Dt = (e) => ha(e, { collapsedSwimlaneIds: ce.value }), Ht = () => {
297
- const e = W.value.length, a = Math.max(0, e - 1);
298
- return `calc(var(--p-taskboard-swimlane-header-width) + (2 * var(--p-taskboard-columns-padding)) + (${e} * var(--p-taskboard-column-min-width)) + (${e * 2} * var(--p-taskboard-column-body-padding)) + (${a} * var(--p-taskboard-column-gap)))`;
299
- }, Dl = () => ({
300
- minWidth: Ht()
301
- }), _t = (e) => {
302
- const a = Dl(), r = Oe.value.get(xe(e));
303
- return X.value && r && !cl(e.id) && (a.height = `${r}px`, a.minHeight = `${r}px`), a;
304
- }, Hl = () => ({
305
- columns: W.value,
306
- tasks: m.value,
307
- swimlanes: o.swimlanes,
308
- draggable: o.draggable,
309
- selectionMode: o.selectionMode,
310
- contextMenu: o.contextMenu,
311
- density: o.density,
312
- features: o.features,
313
- disabled: o.disabled,
314
- readonly: o.readonly,
315
- columnWidth: o.columnWidth,
316
- cardGap: o.cardGap,
317
- scrollable: o.scrollable
318
- }), { initializeCore: Mt, cleanupControllers: Bt, recordAudit: tl, canUndoState: _l, canRedoState: Ml, getCoreInstance: de, getDragController: al, getSelectionController: De, getWorkflowController: ol, getKeyboardController: He, getHistoryController: _e, getAuditController: Bl } = Ea({
319
- rootRef: F,
320
- columnsContainerRef: d,
321
- selectedCardIds: N,
322
- collapsedColumnIds: ae,
323
- collapsedSwimlaneIds: ce,
324
- focusedCardId: u,
325
- focusedColumnId: f,
326
- focusedSwimlaneId: D,
327
- selectionOrigin: Ee,
328
- pendingConfirmMove: ne,
329
- tasks: m,
330
- allColumns: W,
331
- visibleColumns: Ze,
332
- processedSwimlanes: Q,
333
- getCoreProps: Hl,
334
- getColumnTasks: (e) => ml(e),
335
- getVisibleCellTasks: (e, a) => pl(e, a),
336
- getItemId: I,
337
- getItemColumnValue: K,
338
- getItemSwimlaneValue: H,
339
- canMoveIntoColumn: hl,
340
- canMoveOutOfColumn: dl,
341
- canKeyboardMove: () => Je.value,
342
- applyCardMoveHandler: (e) => Cl(e),
343
- announce: M,
344
- scrollToColumnImpl: (e) => Fl(e),
345
- scrollToCardImpl: (e) => Ll(e),
346
- emit: (e, ...a) => b(e, ...a),
347
- getDisabled: () => o.disabled,
348
- getReadonly: () => o.readonly,
349
- getSelectionMode: () => o.selectionMode,
350
- dragMinDistance: o.dragMinDistance
351
- }), Rt = (e) => {
352
- cl(e.id) ? de()?.expandSwimlane(e.id) : de()?.collapseSwimlane(e.id), O(), Se(() => O());
353
- }, ml = (e) => ya(Sl(C.value, e), e, o.columnField), q = () => {
354
- de()?.$setProps(Hl());
355
- }, {
356
- getDragHiddenIds: Me,
357
- onCardPointerDown: $t,
358
- onDocumentPointerMove: At,
359
- onDocumentPointerUp: Et,
360
- cleanupCardDrag: Pt,
361
- markDragGeometryDirty: Ft
362
- } = Pa({
363
- getDisabled: () => o.disabled,
364
- getReadonly: () => o.readonly,
365
- getSelectionMode: () => o.selectionMode,
366
- getDragMinDistance: () => o.dragMinDistance,
367
- tasks: m,
368
- columnsContainerRef: d,
369
- isDragging: X,
370
- draggedCardId: Pe,
371
- dragTargetColumnId: re,
372
- dragTargetIndex: Ie,
373
- dragTargetSwimlaneId: ye,
374
- ghostPosition: j,
375
- dragPreviewWidth: fe,
376
- draggedCardData: me,
377
- selectedCardIds: N,
378
- selectionOrigin: Ee,
379
- hasSwimlanes: se,
380
- canDrag: Je,
381
- getDragController: al,
382
- getSelectionController: De,
383
- isFeatureEnabled: (e) => Qe(e),
384
- canMoveOutOfColumn: dl,
385
- focusCard: (e) => He()?.setFocusedCard(e),
386
- emit: (e, a) => {
387
- b(e, a);
388
- },
389
- getItemId: I,
390
- getItemColumnValue: K,
391
- getItemSwimlaneValue: H
392
- });
393
- O = Ft;
394
- const We = () => {
395
- O(), (X.value || al()?.state.isPending || al()?.state.isDragging) && Se(() => O());
396
- }, Rl = (e) => ae.value.some((a) => String(a) === String(e)), $l = (e) => {
397
- if (!o.columnCollapsible) return;
398
- const a = ba(ae.value, e.id);
399
- ae.value = a.ids, de()?.$setState({ collapsedColumnIds: a.ids }), b("columnCollapse", { column: e, collapsed: a.collapsed }), We();
400
- }, { onColumnHeaderPointerDown: Lt, onColumnHeaderClick: Vt, onColumnDragMove: Po, onColumnDragEnd: Fo, getColumnStyle: Kt, cleanupColumnDrag: Gt } = Fa({
401
- getDisabled: () => o.disabled,
402
- getColumnCollapsible: () => o.columnCollapsible,
403
- columnsContainerRef: d,
404
- isColumnDragging: be,
405
- draggedColumnId: v,
406
- columnDragStartX: T,
407
- columnDragOffsets: h,
408
- processedColumns: W,
409
- canReorderColumns: dt,
410
- isColumnCollapsed: Rl,
411
- onColumnToggle: $l,
412
- emit: (e, a) => {
413
- const r = e.replace(/-([a-z])/g, (w, _) => _.toUpperCase());
414
- b(r, a);
415
- }
416
- }), Al = (e, a, r) => {
417
- o.items || (p.value = Ra(m.value, e), q(), _e()?.pushAction({
418
- type: "create",
419
- taskId: I(e),
420
- before: null,
421
- after: { ...e },
422
- description: r
423
- }), tl("create", I(e), r)), b("cardCreate", { card: e, column: a });
424
- }, Ot = (e, a, r) => {
425
- o.items || (p.value = Aa(m.value, I(e), R.value), q(), _e()?.pushAction({
426
- type: "delete",
427
- taskId: I(e),
428
- before: { ...e },
429
- after: null,
430
- description: r
431
- }), tl("delete", I(e), r)), b("cardDelete", { card: e, column: a });
432
- }, Wt = (e, a, r) => {
433
- b("cardDblclick", { card: e, column: a, jsEvent: r }), b("cardActivate", { card: e, column: a, origin: "pointer", jsEvent: r });
434
- }, Ut = (e, a) => {
435
- if (!wl.value) return;
436
- const r = {
437
- ...e,
438
- [o.columnField]: a.id
439
- };
440
- r[o.dataKey] == null && (r[o.dataKey] = `task-${Date.now()}`), r.order == null && (r.order = Kl(a.id).length), Al(r, a, "Created task");
441
- }, { performUndo: vl, performRedo: gl } = La({
442
- tasks: m,
443
- tasksWritable: p,
444
- syncCoreProps: q,
445
- announce: M,
446
- getHistoryController: _e,
447
- getMutationFields: () => R.value
448
- }), pl = (e, a) => {
449
- const r = Ta(Yl(C.value, e, a), e, a, o.columnField, o.swimlaneField ?? ""), w = Me();
450
- return w.length > 0 ? r.filter((_) => !w.includes(I(_))) : r;
451
- }, zt = (e, a, r) => !X.value || String(re.value) !== String(e) || String(ye.value) !== String(a) ? !1 : Ie.value === r, Nt = (e, a) => !X.value || String(re.value) !== String(e) || String(ye.value) !== String(a) ? !1 : Ie.value === pl(e, a).length, jt = (e) => {
452
- const a = ml(e), r = Me();
453
- return r.length > 0 ? a.filter((w) => !r.includes(I(w))) : a;
454
- }, qt = (e) => xa(C.value, e), Yt = g(
455
- () => fa({
456
- disabled: o.disabled,
457
- readonly: o.readonly,
458
- density: o.density,
459
- isDragging: X.value,
460
- isColumnReordering: be.value,
461
- isTouch: Ye.value,
462
- rtl: o.rtl
463
- })
464
- ), Xt = (e) => Da(e, {
465
- collapsedColumnIds: ae.value,
466
- isColumnDragging: be.value,
467
- draggedColumnId: v.value,
468
- focusedColumnId: f.value,
469
- wipStatus: ol() ? ol().getWipStatus(e.id) : void 0
470
- }), Jt = (e) => Ha(e, {
471
- taskId: I(e),
472
- canDrag: Je.value,
473
- selectedCardIds: N.value,
474
- draggedCardId: Pe.value,
475
- focusedCardId: u.value
476
- }), Qt = (e, a, r) => {
477
- !o.contextMenu || !Qe("contextMenu") || (r.preventDefault(), b("cardContextMenu", { card: e, column: a, position: { x: r.clientX, y: r.clientY }, jsEvent: r }));
478
- }, Zt = () => {
479
- if (N.value.length > 0 && De()?.clearSelection(), u.value != null) {
480
- u.value = null;
481
- const e = He();
482
- e && (e.focusedCardId = null);
483
- }
484
- if (f.value != null) {
485
- f.value = null, D.value = null;
486
- const e = He();
487
- e && (e.focusedColumnId = null, e.focusedSwimlaneId = null);
488
- }
489
- }, { onKeyDown: El, onDocumentClick: Pl, activateKeyboardScope: nl, deactivateKeyboardScope: ea } = Na({
490
- isDragging: X,
491
- draggedCardId: Pe,
492
- dragTargetColumnId: re,
493
- dragTargetIndex: Ie,
494
- dragTargetSwimlaneId: ye,
495
- ghostPosition: j,
496
- draggedCardData: me,
497
- selectedCardIds: N,
498
- selectionOrigin: Ee,
499
- focusedCardId: u,
500
- focusedColumnId: f,
501
- focusedSwimlaneId: D,
502
- rootRef: F,
503
- allColumns: W,
504
- getDragController: al,
505
- getSelectionController: De,
506
- getKeyboardController: He,
507
- onDocumentPointerMove: At,
508
- onDocumentPointerUp: Et,
509
- performUndo: vl,
510
- performRedo: gl,
511
- emit: (e, ...a) => b(e, ...a)
512
- }), Cl = (e) => {
513
- o.items || (p.value = $a(m.value ?? [], {
514
- cardId: I(e.card),
515
- targetColumnId: e.newColumnId,
516
- targetIndex: e.newIndex,
517
- targetSwimlaneId: e.newSwimlaneId,
518
- selectedCardIds: N.value,
519
- fields: R.value
520
- }), q(), _e()?.pushAction({
521
- type: "move",
522
- taskId: I(e.card),
523
- before: { columnId: e.oldColumnId, swimlaneId: e.oldSwimlaneId, order: e.oldIndex },
524
- after: { columnId: e.newColumnId, swimlaneId: e.newSwimlaneId, order: e.newIndex },
525
- description: "Moved task"
526
- }), tl("move", I(e.card), "Moved card", { columnId: e.oldColumnId }, { columnId: e.newColumnId })), b("cardMove", e), String(e.oldColumnId) === String(e.newColumnId) && b("cardReorder", { card: e.card, columnValue: e.newColumnId, oldIndex: e.oldIndex, newIndex: e.newIndex });
527
- const a = W.value.find((r) => String(r.id) === String(e.newColumnId));
528
- a && M(`Task moved to ${a.label}`);
529
- }, la = () => {
530
- if (!ne.value) return;
531
- const e = ne.value.payload;
532
- Cl(e), ne.value = null;
533
- }, ta = () => {
534
- ne.value = null;
535
- };
536
- Z(
537
- () => o.columns,
538
- () => {
539
- q(), We();
540
- },
541
- { deep: !0 }
542
- ), Z(
543
- () => m.value,
544
- () => {
545
- q(), We(), o.virtualScroll && se.value && xl();
546
- },
547
- { deep: !0 }
548
- ), Z(
549
- () => o.swimlanes,
550
- (e, a) => {
551
- q(), We(), o.virtualScroll && xl(Nl(a ?? []));
552
- },
553
- { deep: !0 }
554
- ), Z(() => o.density, q), Z(() => o.disabled, q), Z(() => o.readonly, q), Z(() => o.draggable, q), Z(() => o.selectionMode, q), Z(
555
- () => o.columnCollapsible,
556
- (e) => {
557
- q(), !e && ae.value.length && (ae.value = [], de()?.$setState({ collapsedColumnIds: [] }), We());
558
- }
559
- ), $e(Y, {
560
- items: m,
561
- dataKey: o.dataKey,
562
- columnField: o.columnField,
563
- swimlaneField: g(() => se.value ? o.swimlaneField : void 0),
564
- getItemId: I,
565
- getItemsByColumn: ml,
566
- getVisibleItemsByColumn: jt,
567
- itemCount: qt,
568
- getDragHiddenIds: Me,
569
- isDragging: X,
570
- dragTargetColumnValue: re,
571
- dragTargetIndex: Ie,
572
- selectedItemIds: N,
573
- ghostPosition: j,
574
- dragPreviewWidth: fe,
575
- draggedItem: me,
576
- customDragPreviewCount: Xe,
577
- onCardPointerDown: $t,
578
- onCardDblClick: Wt,
579
- onCardContextMenu: Qt,
580
- onColumnToggle: $l,
581
- onColumnHeaderClick: Vt,
582
- onColumnHeaderPointerDown: Lt,
583
- onBoardBackgroundClick: Zt,
584
- isColumnCollapsed: Rl,
585
- columnClasses: Xt,
586
- getColumnStyle: Kt,
587
- cardWrapperClasses: Jt,
588
- virtualScroll: g(() => o.virtualScroll),
589
- canUndoState: _l,
590
- canRedoState: Ml,
591
- performUndo: vl,
592
- performRedo: gl,
593
- selectCard: (e, a) => De()?.selectCard(e, a),
594
- selectAllCards: (e) => De()?.selectAll(e),
595
- clearSelection: () => De()?.clearSelection(),
596
- canDrag: Je,
597
- canEdit: rt,
598
- canCreate: wl,
599
- canDelete: st,
600
- canMoveIntoColumn: hl,
601
- canMoveOutOfColumn: dl,
602
- canViewColumn: yl,
603
- createItem: Ut,
604
- getWipStatus: (e) => ol()?.getWipStatus(e),
605
- canMoveCard: (e, a, r) => ol()?.canMoveCard(e, a, r) ?? { allowed: !0 },
606
- classes: U,
607
- props: o,
608
- licenseValid: ie,
609
- licenseMessage: Ae,
610
- hasColumnGroups: ut,
611
- columnGroupSegments: it,
612
- columnGroupColumnSegments: ct,
613
- getGroupSegmentStyle: mt,
614
- getGroupColumnSegmentStyle: vt,
615
- getGroupColumns: gt,
616
- onColumnsHorizontalScroll: pt,
617
- markDragGeometryDirty: O,
618
- groupHeadersRef: S,
619
- columnsContainerRef: d,
620
- hasSwimlanes: se,
621
- processedSwimlanes: Q,
622
- visibleSwimlanes: Ct,
623
- swimlaneTaskCount: xt,
624
- isSwimlaneCollapsed: cl,
625
- swimlaneRowClasses: Dt,
626
- swimlaneTrackStyle: Dl,
627
- swimlaneRowStyle: _t,
628
- onSwimlaneToggle: Rt,
629
- onSwimlaneGridScroll: Tt,
630
- virtualScrollState: Ce,
631
- getVisibleCellTasks: pl,
632
- showDropIndicator: zt,
633
- showDropIndicatorAtEnd: Nt,
634
- cardSlotRenderer: Ve,
635
- columnHeaderSlotRenderer: Ke,
636
- swimlaneHeaderSlotRenderer: Te,
637
- registerCardSlot: lt,
638
- registerColumnHeaderSlot: tt,
639
- registerSwimlaneHeaderSlot: at,
640
- dropIndicatorSlotRenderer: kl,
641
- registerDropIndicatorSlot: ot,
642
- swimlaneColumnHeaderSlotRenderer: Il,
643
- registerSwimlaneColumnHeaderSlot: nt,
644
- pendingConfirmMove: ne,
645
- confirmPendingMove: la,
646
- cancelPendingMove: ta,
647
- processedColumns: W,
648
- registerColumn: Le,
649
- unregisterColumn: ve,
650
- emitCardMove: (e) => b("cardMove", e),
651
- emitCardReorder: (e) => b("cardReorder", e),
652
- emitColumnReorder: (e) => b("columnReorder", e),
653
- emitCardClick: (e) => b("cardClick", e),
654
- emitCardDblClick: (e) => b("cardDblclick", e),
655
- emitCardActivate: (e) => b("cardActivate", e),
656
- emitSelectionChange: (e) => b("selectionChange", e),
657
- emitColumnCollapse: (e) => b("columnCollapse", e),
658
- emitContextMenu: (e) => b("cardContextMenu", e)
659
- }), ke(() => {
660
- Ye.value = "ontouchstart" in window || navigator.maxTouchPoints > 0, Mt(), o.virtualScroll && se.value && d.value && Se(() => {
661
- el(), ll(0, d.value?.clientHeight ?? 600);
662
- }), document.addEventListener("keydown", El), document.addEventListener("click", Pl), aa();
663
- });
664
- async function aa() {
665
- const e = await ca("taskboard", { releaseDate: qa });
666
- G.value = e, e.valid || console.warn(`[PrimeUI TaskBoard] ${e.message}`);
667
- }
668
- je(() => {
669
- Bt(), ea(), document.removeEventListener("keydown", El), document.removeEventListener("click", Pl), Pt(), Gt(), we && (cancelAnimationFrame(we), we = null);
670
- });
671
- const Fl = (e, a) => {
672
- if (!d.value) return;
673
- const r = String(e), w = Array.from(d.value.querySelectorAll("[data-column-id]")).find((_) => _.getAttribute("data-column-id") === r);
674
- w && w.scrollIntoView({ behavior: a?.behavior ?? "smooth", block: "nearest", inline: "start" });
675
- }, Ll = (e, a) => {
676
- if (!F.value) return;
677
- const r = String(e), w = Array.from(F.value.querySelectorAll("[data-task-id]")).find((_) => _.getAttribute("data-task-id") === r);
678
- if (w) {
679
- w.scrollIntoView({ behavior: a?.behavior ?? "smooth", block: a?.block ?? "center", inline: "nearest" }), u.value = e;
680
- const _ = He();
681
- _ && (_.focusedCardId = e);
682
- }
683
- }, { print: oa } = ja({ rootRef: F }), Vl = (e, a, r) => {
684
- const w = new Blob([e], { type: r }), _ = URL.createObjectURL(w), oe = document.createElement("a");
685
- oe.href = _, oe.download = a, document.body.appendChild(oe), oe.click(), document.body.removeChild(oe), URL.revokeObjectURL(_);
686
- }, na = () => _a({
687
- collapsedColumnIds: ae.value,
688
- collapsedSwimlaneIds: ce.value,
689
- selectedCardIds: N.value,
690
- focusedCardId: u.value,
691
- focusedColumnId: f.value,
692
- focusedSwimlaneId: D.value
693
- }), ra = (e) => {
694
- const a = Ma(e);
695
- if (a.collapsedColumnIds && (ae.value = a.collapsedColumnIds, de()?.$setState({ collapsedColumnIds: a.collapsedColumnIds })), a.collapsedSwimlaneIds && (ce.value = a.collapsedSwimlaneIds, de()?.$setState({ collapsedSwimlaneIds: a.collapsedSwimlaneIds })), a.selectedCardIds && (N.value = a.selectedCardIds, de()?.$setState({ selectedCardIds: a.selectedCardIds })), "focusedCardId" in a) {
696
- u.value = a.focusedCardId ?? null;
697
- const r = He();
698
- r && (r.focusedCardId = u.value);
699
- }
700
- "focusedColumnId" in a && (f.value = a.focusedColumnId ?? null), "focusedSwimlaneId" in a && (D.value = a.focusedSwimlaneId ?? null);
701
- }, ge = () => de(), rl = (e) => (m.value ?? []).find((a) => String(I(a)) === String(e)), Kl = (e) => [...Sl(C.value, e)], Gl = (e, a) => [...o.swimlaneField && a != null ? Yl(C.value, e, a) : Sl(C.value, e)].sort((w, _) => (w.order ?? 0) - (_.order ?? 0)), Ol = (e = N.value) => {
702
- const a = new Set(e.map((r) => String(r)));
703
- return (m.value ?? []).filter((r) => a.has(String(I(r))));
704
- }, Wl = (e) => {
705
- N.value = e, de()?.$setState({ selectedCardIds: e }), b("selectionChange", { selectedIds: e, cards: Ol(e) });
706
- };
707
- return l({
708
- getColumns: () => ge()?.getColumns() ?? [],
709
- getColumnById: (e) => ge()?.getColumnById(e),
710
- getTasks: () => ge()?.getTasks() ?? [],
711
- getTaskById: rl,
712
- getTasksByColumn: Kl,
713
- getSelectedCardIds: () => N.value,
714
- getSelectedCards: () => Ol(),
715
- setSelectedCards: Wl,
716
- clearSelection: () => Wl([]),
717
- addTask: (e) => {
718
- const a = W.value.find((r) => String(r.id) === String(K(e)));
719
- a && Al(e, a, "Created task");
720
- },
721
- updateTask: (e) => {
722
- const a = I(e), r = rl(a);
723
- r && (o.items || (p.value = Ba(m.value ?? [], a, e, R.value), q(), _e()?.pushAction({
724
- type: "edit",
725
- taskId: a,
726
- before: { ...r },
727
- after: { ...e },
728
- description: "Updated task"
729
- }), tl("update", a, "Updated task")), b("cardUpdate", { card: e, oldCard: r }));
730
- },
731
- removeTask: (e) => {
732
- const a = rl(e);
733
- if (!a) return;
734
- const r = W.value.find((w) => String(w.id) === String(K(a)));
735
- r && Ot(a, r, "Deleted task");
736
- },
737
- moveTask: (e, a, r, w) => {
738
- const _ = rl(e);
739
- if (!_) return;
740
- const oe = K(_), Ue = H(_), ze = w ?? Ue, fl = Gl(oe, Ue).findIndex((da) => String(I(da)) === String(e)), sa = r ?? Gl(a, ze).length;
741
- Cl({
742
- card: _,
743
- oldColumnId: oe,
744
- newColumnId: a,
745
- oldIndex: fl,
746
- newIndex: sa,
747
- oldSwimlaneId: Ue,
748
- newSwimlaneId: ze
749
- });
750
- },
751
- collapseColumn: (e) => ge()?.collapseColumn(e),
752
- expandColumn: (e) => ge()?.expandColumn(e),
753
- toggleColumn: (e) => ge()?.toggleColumn(e),
754
- collapseSwimlane: (e) => ge()?.collapseSwimlane(e),
755
- expandSwimlane: (e) => ge()?.expandSwimlane(e),
756
- toggleSwimlane: (e) => ge()?.toggleSwimlane(e),
757
- scrollToColumn: (e, a) => Fl(e, a),
758
- scrollToCard: (e, a) => Ll(e, a),
759
- undo: vl,
760
- redo: gl,
761
- canUndo: () => _l.value,
762
- canRedo: () => Ml.value,
763
- clearHistory: () => _e()?.clearHistory(),
764
- exportToJSON: () => ql(W.value, m.value ?? [], o.swimlanes ?? []),
765
- exportToCSV: (e) => jl(m.value ?? [], e),
766
- downloadJSON: () => Vl(ql(W.value, m.value ?? [], o.swimlanes ?? []), "taskboard-export.json", "application/json"),
767
- downloadCSV: (e) => Vl(jl(m.value ?? [], e), "taskboard-export.csv", "text/csv"),
768
- print: oa,
769
- serializeState: na,
770
- restoreState: ra,
771
- licenseValid: () => ie.value,
772
- licenseMessage: () => Ae.value,
773
- getAuditLog: () => Bl()?.getLog() ?? [],
774
- clearAuditLog: () => {
775
- Bl()?.clear();
776
- }
777
- }), (e, a) => (i(), c("div", {
778
- ref_key: "rootRef",
779
- ref: F,
780
- class: k(Yt.value),
781
- dir: o.rtl ? "rtl" : void 0,
782
- role: "treegrid",
783
- "aria-label": "Task board",
784
- tabindex: "0",
785
- onPointerdownCapture: a[0] || (a[0] = //@ts-ignore
786
- (...r) => t(nl) && t(nl)(...r)),
787
- onFocusinCapture: a[1] || (a[1] = //@ts-ignore
788
- (...r) => t(nl) && t(nl)(...r))
789
- }, [
790
- G.value && !G.value.valid ? (i(), c("div", Xa, [
791
- a[2] || (a[2] = B("span", { style: { "font-weight": "600" } }, "PrimeUI TaskBoard", -1)),
792
- B("span", null, te(G.value.message), 1)
793
- ])) : $("", !0),
794
- A(e.$slots, "default"),
795
- (i(), z(Xl, { to: "body" }, [
796
- X.value && j.value && me.value && Xe.value === 0 ? (i(), c("div", {
797
- key: 0,
798
- class: k(t(U).dragPreview),
799
- style: ue({
800
- position: "fixed",
801
- left: j.value.x + "px",
802
- top: j.value.y + "px",
803
- width: fe.value ? fe.value + "px" : void 0,
804
- maxWidth: fe.value ? fe.value + "px" : void 0,
805
- transform: "translate(-50%, -50%) rotate(var(--p-taskboard-drag-preview-rotation, 1.5deg))",
806
- pointerEvents: "none",
807
- zIndex: 9999
808
- })
809
- }, [
810
- t(Me)().length > 1 ? (i(), c("span", {
811
- key: 0,
812
- class: k(t(U).dragPreviewBadge)
813
- }, te(t(Me)().length), 3)) : $("", !0),
814
- A(e.$slots, "drag-preview", {
815
- item: me.value,
816
- count: t(Me)().length
817
- }, () => [
818
- Fe.value ? (i(), c("div", {
819
- key: 0,
820
- innerHTML: Fe.value
821
- }, null, 8, Ja)) : $("", !0)
822
- ])
823
- ], 6)) : $("", !0)
824
- ])),
825
- B("div", Qa, te(le.value), 1)
826
- ], 42, Ya));
827
- }
828
- }), eo = /* @__PURE__ */ V({
829
- __name: "TaskBoardHeader",
830
- setup(s) {
831
- const l = L(Y);
832
- return (n, o) => (i(), c("div", {
833
- class: k(t(l).classes.header)
834
- }, [
835
- A(n.$slots, "default", {
836
- canUndo: t(l).canUndoState.value,
837
- canRedo: t(l).canRedoState.value,
838
- undo: t(l).performUndo,
839
- redo: t(l).performRedo
840
- })
841
- ], 2));
842
- }
843
- }), lo = { class: "p-taskboard-column-group-headers-inner" }, to = { class: "p-taskboard-column-group-mobile-headers-inner" }, ao = ["aria-hidden"], oo = ["data-swimlane-id", "aria-expanded", "aria-label"], no = ["aria-label", "onClick"], ro = ["data-column-id"], so = ["data-column-id", "data-swimlane-id"], uo = ["data-task-id", "data-task-index", "onDblclick", "onPointerdown", "onContextmenu"], io = { style: { display: "none" } }, co = /* @__PURE__ */ V({
844
- __name: "TaskBoardContent",
845
- setup(s) {
846
- const l = L(Y), n = g(() => l.swimlaneColumnHeaderSlotRenderer?.value ?? null), o = g(() => l.dropIndicatorSlotRenderer?.value ?? null), p = (d, S) => {
847
- const u = o.value;
848
- return u ? () => u({ column: d, index: S }) : null;
849
- }, m = g(() => l.virtualScrollState.value?.topSpacerHeight ?? 0), C = g(() => {
850
- const d = l.virtualScrollState.value;
851
- if (d) return d.bottomSpacerHeight;
852
- if (!l.virtualScroll.value) return 0;
853
- const S = l.processedSwimlanes.value.length, u = l.visibleSwimlanes.value.length, f = S - u, D = l.props.virtualScrollItemHeight ?? 250;
854
- return f > 0 ? f * D : 0;
855
- }), y = (d) => {
856
- l.groupHeadersRef.value = d;
857
- }, R = (d) => {
858
- l.columnsContainerRef.value = d;
859
- }, I = (d, S) => {
860
- const u = l.cardSlotRenderer.value;
861
- return u ? () => u({ item: d, column: S, isSelected: l.selectedItemIds.value.includes(l.getItemId(d)), isDragging: !1 }) : null;
862
- }, K = (d, S) => l.getVisibleCellTasks(d.id, S.id).length, H = (d, S = l.itemCount(d.id)) => {
863
- const u = l.columnHeaderSlotRenderer.value;
864
- return u ? () => u({
865
- column: d,
866
- itemCount: S,
867
- isCollapsed: l.isColumnCollapsed(d.id),
868
- toggleCollapse: () => l.onColumnToggle(d),
869
- startDrag: (f) => l.onColumnHeaderPointerDown(d, f)
870
- }) : null;
871
- }, b = (d, S) => {
872
- const u = n.value;
873
- return u ? V({
874
- name: "TaskBoardRenderedSwimlaneColumnHeader",
875
- setup() {
876
- const f = g(() => S ? K(d, S) : l.itemCount(d.id)), D = g(() => S ? l.getVisibleCellTasks(d.id, S.id) : l.getItemsByColumn(d.id)), le = g(() => S ? l.getVisibleCellTasks(d.id, S.id) : l.getVisibleItemsByColumn(d.id));
877
- return $e(he, {
878
- label: d.label,
879
- value: d.id,
880
- columnData: d,
881
- itemCount: f,
882
- isCollapsed: g(() => l.isColumnCollapsed(d.id)),
883
- toggleCollapse: () => l.onColumnToggle(d),
884
- startDrag: (G) => l.onColumnHeaderPointerDown(d, G),
885
- items: D,
886
- visibleItems: le,
887
- addItem: (G) => l.createItem(G ?? {}, d)
888
- }), () => u({ column: d, itemCount: f.value });
889
- }
890
- }) : null;
891
- }, F = (d) => {
892
- const S = l.swimlaneHeaderSlotRenderer.value;
893
- return S ? V({
894
- name: "TaskBoardRenderedSwimlaneHeader",
895
- setup() {
896
- const u = g(() => l.swimlaneTaskCount(d.id)), f = g(() => l.isSwimlaneCollapsed(d.id)), D = () => l.onSwimlaneToggle(d);
897
- return $e(Zl, {
898
- swimlaneData: d,
899
- taskCount: u,
900
- isCollapsed: f,
901
- toggleCollapse: D
902
- }), () => S({
903
- swimlane: d,
904
- itemCount: u.value,
905
- isCollapsed: f.value,
906
- toggleCollapse: D
907
- });
908
- }
909
- }) : null;
910
- };
911
- return (d, S) => (i(), c("div", {
912
- class: k(t(l).classes.body)
913
- }, [
914
- t(l).hasSwimlanes.value ? (i(), c(E, { key: 1 }, [
915
- B("div", {
916
- ref: R,
917
- class: k(t(l).classes.swimlaneGrid),
918
- onScroll: S[3] || (S[3] = //@ts-ignore
919
- (...u) => t(l).onSwimlaneGridScroll && t(l).onSwimlaneGridScroll(...u))
920
- }, [
921
- B("div", {
922
- class: k(t(l).classes.columnHeaders),
923
- style: ue(t(l).swimlaneTrackStyle())
924
- }, [
925
- B("div", {
926
- class: k(t(l).classes.columnHeadersSpacer)
927
- }, null, 2),
928
- B("div", {
929
- class: k(t(l).classes.columnHeadersContent)
930
- }, [
931
- (i(!0), c(E, null, pe(t(l).processedColumns.value, (u) => (i(), c("div", {
932
- key: u.id
933
- }, [
934
- n.value ? (i(), z(ee(b(u)), { key: 0 })) : t(l).columnHeaderSlotRenderer.value ? (i(), z(ee(H(u)), { key: 1 })) : (i(), c(E, { key: 2 }, [
935
- Be(te(u.label), 1)
936
- ], 64))
937
- ]))), 128))
938
- ], 2)
939
- ], 6),
940
- t(l).virtualScroll.value && m.value > 0 ? (i(), c("div", {
941
- key: 0,
942
- style: ue({ height: m.value + "px", flexShrink: "0", minWidth: "fit-content" })
943
- }, null, 4)) : $("", !0),
944
- (i(!0), c(E, null, pe(t(l).visibleSwimlanes.value, (u) => (i(), c("div", {
945
- key: u.id,
946
- class: k(t(l).swimlaneRowClasses(u)),
947
- style: ue(t(l).swimlaneRowStyle(u)),
948
- "data-swimlane-id": u.id,
949
- role: "rowgroup",
950
- "aria-expanded": !t(l).isSwimlaneCollapsed(u.id),
951
- "aria-label": u.label + ", " + t(l).swimlaneTaskCount(u.id) + " items"
952
- }, [
953
- B("div", {
954
- class: k(t(l).classes.swimlaneHeader)
955
- }, [
956
- t(l).swimlaneHeaderSlotRenderer.value ? (i(), z(ee(F(u)), { key: 0 })) : (i(), c(E, { key: 1 }, [
957
- B("button", {
958
- type: "button",
959
- class: k(t(l).classes.swimlaneCollapseToggle),
960
- "aria-label": `${t(l).isSwimlaneCollapsed(u.id) ? "Expand" : "Collapse"} ${u.label} swimlane`,
961
- onPointerdown: S[1] || (S[1] = Re(() => {
962
- }, ["stop"])),
963
- onClick: Re((f) => t(l).onSwimlaneToggle(u), ["stop"])
964
- }, [
965
- (i(), c("svg", {
966
- class: k(t(l).classes.swimlaneCollapseToggleIcon),
967
- width: "12",
968
- height: "12",
969
- viewBox: "0 0 12 12",
970
- fill: "none",
971
- "aria-hidden": "true"
972
- }, [...S[4] || (S[4] = [
973
- B("path", {
974
- d: "M2.5 4.5L6 8L9.5 4.5",
975
- stroke: "currentColor",
976
- "stroke-width": "1.5",
977
- "stroke-linecap": "round",
978
- "stroke-linejoin": "round"
979
- }, null, -1)
980
- ])], 2))
981
- ], 42, no),
982
- B("span", null, te(u.label) + " (" + te(t(l).swimlaneTaskCount(u.id)) + ")", 1)
983
- ], 64))
984
- ], 2),
985
- B("div", {
986
- class: k(t(l).classes.swimlanePrintHeader),
987
- "aria-hidden": "true"
988
- }, [
989
- B("span", {
990
- class: k(t(l).classes.swimlanePrintHeaderTitle)
991
- }, te(u.label), 3),
992
- B("span", {
993
- class: k(t(l).classes.swimlanePrintHeaderCount)
994
- }, te(t(l).swimlaneTaskCount(u.id)) + " items", 3)
995
- ], 2),
996
- B("div", {
997
- class: k(t(l).classes.swimlanePrintColumns),
998
- "aria-hidden": "true"
999
- }, [
1000
- (i(!0), c(E, null, pe(t(l).processedColumns.value, (f) => (i(), c("div", {
1001
- key: f.id,
1002
- class: k(t(l).classes.swimlanePrintColumn),
1003
- "data-column-id": f.id
1004
- }, [
1005
- B("div", {
1006
- class: k(t(l).classes.swimlanePrintColumnHeader)
1007
- }, [
1008
- n.value ? (i(), z(ee(b(f, u)), { key: 0 })) : t(l).columnHeaderSlotRenderer.value ? (i(), z(ee(H(f, K(f, u))), { key: 1 })) : (i(), c(E, { key: 2 }, [
1009
- Be(te(f.label), 1)
1010
- ], 64))
1011
- ], 2),
1012
- B("div", {
1013
- class: k(t(l).classes.swimlanePrintColumnBody)
1014
- }, [
1015
- (i(!0), c(E, null, pe(t(l).getVisibleCellTasks(f.id, u.id), (D) => (i(), c("div", {
1016
- key: t(l).getItemId(D),
1017
- class: k(t(l).cardWrapperClasses(D)),
1018
- role: "row"
1019
- }, [
1020
- t(l).cardSlotRenderer.value ? (i(), z(ee(I(D, f)), { key: 0 })) : $("", !0)
1021
- ], 2))), 128))
1022
- ], 2)
1023
- ], 10, ro))), 128))
1024
- ], 2),
1025
- B("div", {
1026
- class: k(t(l).classes.swimlaneBody),
1027
- onClick: S[2] || (S[2] = Re((f) => t(l).onBoardBackgroundClick(), ["self"]))
1028
- }, [
1029
- (i(!0), c(E, null, pe(t(l).processedColumns.value, (f) => (i(), c("div", {
1030
- key: f.id,
1031
- class: k(t(l).classes.swimlaneCell),
1032
- "data-column-id": f.id,
1033
- "data-swimlane-id": u.id
1034
- }, [
1035
- (i(!0), c(E, null, pe(t(l).getVisibleCellTasks(f.id, u.id), (D, le) => (i(), c(E, {
1036
- key: t(l).getItemId(D)
1037
- }, [
1038
- t(l).showDropIndicator(f.id, u.id, le) ? (i(), c(E, { key: 0 }, [
1039
- o.value ? (i(), z(ee(p(f, le)), { key: 0 })) : (i(), c("div", {
1040
- key: 1,
1041
- class: k([t(l).classes.dropIndicator, t(l).classes.swimlaneDropIndicator])
1042
- }, null, 2))
1043
- ], 64)) : $("", !0),
1044
- B("div", {
1045
- "data-task-id": t(l).getItemId(D),
1046
- "data-task-index": le,
1047
- class: k(t(l).cardWrapperClasses(D)),
1048
- role: "row",
1049
- onDblclick: (G) => t(l).onCardDblClick(D, f, G),
1050
- onPointerdown: (G) => t(l).onCardPointerDown(D, f, G),
1051
- onContextmenu: (G) => t(l).onCardContextMenu(D, f, G)
1052
- }, [
1053
- t(l).cardSlotRenderer.value ? (i(), z(ee(I(D, f)), { key: 0 })) : $("", !0)
1054
- ], 42, uo)
1055
- ], 64))), 128)),
1056
- t(l).showDropIndicatorAtEnd(f.id, u.id) ? (i(), c(E, { key: 0 }, [
1057
- o.value ? (i(), z(ee(p(f, t(l).getVisibleCellTasks(f.id, u.id).length)), { key: 0 })) : (i(), c("div", {
1058
- key: 1,
1059
- class: k([t(l).classes.dropIndicator, t(l).classes.swimlaneDropIndicator])
1060
- }, null, 2))
1061
- ], 64)) : $("", !0)
1062
- ], 10, so))), 128))
1063
- ], 2)
1064
- ], 14, oo))), 128)),
1065
- t(l).virtualScroll.value && C.value > 0 ? (i(), c("div", {
1066
- key: 1,
1067
- style: ue({ height: C.value + "px", flexShrink: "0", minWidth: "fit-content" })
1068
- }, null, 4)) : $("", !0)
1069
- ], 34),
1070
- B("div", io, [
1071
- A(d.$slots, "default")
1072
- ])
1073
- ], 64)) : (i(), c("div", {
1074
- key: 0,
1075
- ref: R,
1076
- class: k([t(l).classes.columns, t(l).hasColumnGroups.value && t(l).classes.columnsWithGroups]),
1077
- onScroll: S[0] || (S[0] = (u) => t(l).onColumnsHorizontalScroll())
1078
- }, [
1079
- t(l).hasColumnGroups.value ? (i(), c(E, { key: 0 }, [
1080
- B("div", {
1081
- ref: y,
1082
- class: k(t(l).classes.columnGroupHeaders)
1083
- }, [
1084
- B("div", lo, [
1085
- (i(!0), c(E, null, pe(t(l).columnGroupSegments.value, (u) => (i(), c("div", {
1086
- key: u.key,
1087
- class: k(u.label ? t(l).classes.columnGroupHeader : void 0),
1088
- style: ue(t(l).getGroupSegmentStyle(u))
1089
- }, [
1090
- u.label ? A(d.$slots, "column-group-header", {
1091
- key: 0,
1092
- group: u.group,
1093
- columns: t(l).getGroupColumns(u)
1094
- }, () => [
1095
- Be(te(u.label), 1)
1096
- ]) : $("", !0)
1097
- ], 6))), 128))
1098
- ])
1099
- ], 2),
1100
- B("div", {
1101
- class: k(t(l).classes.columnGroupMobileHeaders)
1102
- }, [
1103
- B("div", to, [
1104
- (i(!0), c(E, null, pe(t(l).columnGroupColumnSegments.value, (u) => (i(), c("div", {
1105
- key: u.key,
1106
- class: k([t(l).classes.columnGroupMobileHeader, !u.label && t(l).classes.columnGroupMobileHeaderEmpty]),
1107
- style: ue(t(l).getGroupColumnSegmentStyle(u)),
1108
- "aria-hidden": u.label ? void 0 : "true"
1109
- }, [
1110
- u.label ? A(d.$slots, "column-group-header", {
1111
- key: 0,
1112
- group: u.group,
1113
- columns: [u.column]
1114
- }, () => [
1115
- Be(te(u.label), 1)
1116
- ]) : $("", !0)
1117
- ], 14, ao))), 128))
1118
- ])
1119
- ], 2),
1120
- B("div", {
1121
- class: k(t(l).classes.columnsTrack)
1122
- }, [
1123
- A(d.$slots, "default")
1124
- ], 2)
1125
- ], 64)) : A(d.$slots, "default", { key: 1 })
1126
- ], 34))
1127
- ], 2));
1128
- }
1129
- }), mo = ["data-column-id", "aria-label", "aria-expanded"], vo = /* @__PURE__ */ V({
1130
- inheritAttrs: !1,
1131
- __name: "TaskBoardColumn",
1132
- props: {
1133
- label: {},
1134
- value: {},
1135
- column: {}
1136
- },
1137
- setup(s) {
1138
- const l = s, n = L(Y), o = g(() => l.column ? { ...l.column, id: l.value, label: l.label } : { id: l.value, label: l.label });
1139
- ke(() => n.registerColumn(l.column ? { ...l.column, id: l.value, label: l.label } : { id: l.value, label: l.label })), je(() => n.unregisterColumn(l.value));
1140
- const p = g(() => n.itemCount(l.value)), m = g(() => n.isColumnCollapsed(l.value)), C = g(() => n.getItemsByColumn(l.value)), y = g(() => n.getVisibleItemsByColumn(l.value)), R = {
1141
- label: l.label,
1142
- value: l.value,
1143
- columnData: o.value,
1144
- itemCount: p,
1145
- isCollapsed: m,
1146
- toggleCollapse: () => n.onColumnToggle(o.value),
1147
- startDrag: (I) => n.onColumnHeaderPointerDown(o.value, I),
1148
- items: C,
1149
- visibleItems: y,
1150
- addItem: (I) => {
1151
- n.createItem(I ?? {}, o.value);
1152
- }
1153
- };
1154
- return $e(he, R), (I, K) => (i(), c("div", Jl({
1155
- class: t(n).columnClasses(o.value),
1156
- "data-column-id": l.value,
1157
- style: t(n).getColumnStyle(o.value),
1158
- role: "group",
1159
- "aria-label": l.label + ", " + p.value + " items",
1160
- "aria-expanded": t(n).props.columnCollapsible ? !m.value : void 0
1161
- }, I.$attrs), [
1162
- A(I.$slots, "default")
1163
- ], 16, mo));
1164
- }
1165
- }), go = ["aria-label"], po = /* @__PURE__ */ V({
1166
- __name: "TaskBoardColumnHeader",
1167
- setup(s) {
1168
- const l = qe(), n = L(Y), o = L(he);
1169
- return ke(() => {
1170
- l.default && !n.columnHeaderSlotRenderer.value && n.registerColumnHeaderSlot(l.default);
1171
- }), (p, m) => (i(), c("div", {
1172
- class: k(t(n).classes.columnHeader),
1173
- role: "columnheader",
1174
- onPointerdown: m[2] || (m[2] = (C) => t(n).onColumnHeaderPointerDown(t(o).columnData, C))
1175
- }, [
1176
- t(l).default ? A(p.$slots, "default", {
1177
- key: 0,
1178
- column: t(o).columnData,
1179
- itemCount: t(o).itemCount.value,
1180
- isCollapsed: t(o).isCollapsed.value,
1181
- toggleCollapse: t(o).toggleCollapse,
1182
- startDrag: t(o).startDrag
1183
- }) : t(o).isCollapsed.value ? (i(), c("button", {
1184
- key: 1,
1185
- type: "button",
1186
- class: k(t(n).classes.columnCollapseToggle),
1187
- "aria-label": `Expand ${t(o).label} column`,
1188
- onPointerdown: m[0] || (m[0] = Re(() => {
1189
- }, ["stop"])),
1190
- onClick: m[1] || (m[1] = Re((C) => t(o).toggleCollapse(), ["stop"]))
1191
- }, [
1192
- (i(), c("svg", {
1193
- class: k(t(n).classes.columnCollapseToggleIcon),
1194
- width: "12",
1195
- height: "12",
1196
- viewBox: "0 0 12 12",
1197
- fill: "none",
1198
- "aria-hidden": "true"
1199
- }, [...m[3] || (m[3] = [
1200
- B("path", {
1201
- d: "M4.5 2.5L8 6L4.5 9.5",
1202
- stroke: "currentColor",
1203
- "stroke-width": "1.5",
1204
- "stroke-linecap": "round",
1205
- "stroke-linejoin": "round"
1206
- }, null, -1)
1207
- ])], 2))
1208
- ], 42, go)) : $("", !0)
1209
- ], 34));
1210
- }
1211
- }), Co = ["data-task-id", "data-task-index", "onDblclick", "onPointerdown", "onContextmenu"], fo = /* @__PURE__ */ V({
1212
- inheritAttrs: !1,
1213
- __name: "TaskBoardColumnContent",
1214
- setup(s) {
1215
- const l = qe(), n = L(Y), o = L(he), p = x(), m = x(null), C = /* @__PURE__ */ new Map();
1216
- let y = null, R = null, I = /* @__PURE__ */ new Set(), K = null;
1217
- const H = g(() => n.virtualScroll.value);
1218
- ke(() => {
1219
- l.default && !n.cardSlotRenderer.value && n.registerCardSlot(l.default), l["drop-indicator"] && !n.dropIndicatorSlotRenderer.value && n.registerDropIndicatorSlot(l["drop-indicator"]), H.value && p.value && (R = new ResizeObserver((v) => {
1220
- (v[0]?.contentRect.height ?? 0) > 0 && (R?.disconnect(), R = null, re(0));
1221
- }), R.observe(p.value));
1222
- }), je(() => {
1223
- R?.disconnect(), R = null, y && (cancelAnimationFrame(y), y = null);
1224
- });
1225
- const b = g(() => o.columnData), F = g(() => l["drop-indicator"] ?? n.dropIndicatorSlotRenderer.value), d = g(() => n.isDragging.value && String(n.dragTargetColumnValue.value) === String(o.value)), S = g(() => n.dragTargetIndex.value ?? 0), u = (v) => d.value && n.dragTargetIndex.value === v, f = (v) => {
1226
- const T = F.value;
1227
- return T ? () => T({ column: b.value, index: v }) : null;
1228
- }, D = g(() => o.visibleItems.value), le = () => n.props.virtualScrollItemHeight ?? 120, G = () => n.props.virtualScrollBuffer ?? 3, ie = (v) => String(n.getItemId(v)), Ae = () => {
1229
- if (C.size === 0) return le();
1230
- const T = Array.from(C.values()).reduce((h, M) => h + M, 0) / C.size;
1231
- return Number.isFinite(T) && T > 0 ? T : le();
1232
- }, ne = (v) => C.get(ie(v)) ?? Ae(), N = (v = D.value) => v.map((T) => C.get(ie(T)) ?? 0), Ee = (v) => v.reduce((T, h) => T + ne(h), 0), ae = () => {
1233
- const v = p.value;
1234
- return v ? Math.max(0, v.scrollHeight - v.clientHeight) : 0;
1235
- }, ce = (v, T, h) => {
1236
- const M = Math.max(0, Ee(T) - h), P = ae();
1237
- return Math.max(0, Math.min(v, Math.max(M, P)));
1238
- }, Ce = (v, T) => {
1239
- let h = 0;
1240
- for (let M = 0; M < Math.max(0, T); M++)
1241
- h += ne(v[M]);
1242
- return h;
1243
- }, Ye = (v, T) => {
1244
- let h = 0;
1245
- for (let M = 0; M < v.length; M++) {
1246
- const P = ne(v[M]);
1247
- if (h + P > T)
1248
- return M;
1249
- h += P;
1250
- }
1251
- return Math.max(0, v.length - 1);
1252
- }, X = (v, T) => v.length ? ie(v[Ye(v, T)]) : null, Pe = (v) => {
1253
- const T = new Set(v.map((h) => ie(h)));
1254
- for (const h of C.keys())
1255
- T.has(h) || C.delete(h);
1256
- };
1257
- function re(v) {
1258
- if (!p.value) return;
1259
- const T = m.value?.startIndex ?? 0;
1260
- p.value.querySelectorAll("[data-task-id]").forEach((J, Le) => {
1261
- const ve = D.value[T + Le], W = J.getAttribute("data-task-id") ?? (ve ? ie(ve) : null);
1262
- W && C.set(String(W), J.offsetHeight);
1263
- });
1264
- const M = p.value.clientHeight, P = ce(v, D.value, M);
1265
- Math.abs(p.value.scrollTop - P) > 1 && (p.value.scrollTop = P), m.value = Ql(P, M, D.value.length, N(), Ae(), G());
1266
- }
1267
- function Ie(v) {
1268
- if (n.markDragGeometryDirty(), !H.value) return;
1269
- const T = v.target;
1270
- y && cancelAnimationFrame(y), y = requestAnimationFrame(() => {
1271
- re(T.scrollTop), y = null;
1272
- });
1273
- }
1274
- Z(
1275
- () => n.isDragging.value,
1276
- (v) => {
1277
- H.value && v && K == null && (K = p.value?.scrollTop ?? null);
1278
- },
1279
- { flush: "sync" }
1280
- ), Z(D, (v, T = []) => {
1281
- if (!H.value) return;
1282
- const h = p.value, M = h?.scrollTop ?? 0, P = X(T, M), J = new Set(n.getDragHiddenIds().map((ve) => String(ve))), Le = n.isDragging.value || J.size > 0 || I.size > 0;
1283
- if (I = J, Pe(v), !h) {
1284
- m.value = null;
1285
- return;
1286
- }
1287
- Se(() => {
1288
- if (Le) {
1289
- const Te = ce(K ?? M, v, h.clientHeight);
1290
- Math.abs(h.scrollTop - Te) > 1 && (h.scrollTop = Te), re(Te), n.markDragGeometryDirty(), !n.isDragging.value && J.size === 0 && (K = null);
1291
- return;
1292
- }
1293
- K = null;
1294
- const ve = P == null ? -1 : v.findIndex((Ke) => ie(Ke) === P), W = ve >= 0 ? Ce(v, ve) : M, Ve = ce(W, v, h.clientHeight);
1295
- h.scrollTop = Ve, re(Ve), n.markDragGeometryDirty();
1296
- });
1297
- });
1298
- const j = g(() => {
1299
- if (!H.value) return D.value;
1300
- if (!m.value) {
1301
- const v = n.props.virtualScrollItemHeight ?? 120, T = n.props.virtualScrollBuffer ?? 3, h = Math.ceil(600 / v) + T * 2;
1302
- return D.value.slice(0, Math.min(h, D.value.length));
1303
- }
1304
- return D.value.slice(m.value.startIndex, m.value.endIndex);
1305
- }), fe = g(() => O(0)), Xe = g(() => O(j.value.length)), ye = g(() => H.value && d.value && n.dragTargetIndex.value != null && j.value.length > 0 && n.dragTargetIndex.value < fe.value), me = g(() => H.value && d.value && n.dragTargetIndex.value != null && j.value.length > 0 && n.dragTargetIndex.value > Xe.value), O = (v) => !H.value || !m.value ? v : m.value.startIndex + v, Fe = g(() => m.value?.topSpacerHeight ?? 0), be = g(() => {
1306
- if (m.value) return m.value.bottomSpacerHeight;
1307
- if (!H.value) return 0;
1308
- const v = n.props.virtualScrollItemHeight ?? 120, T = n.props.virtualScrollBuffer ?? 3, h = Math.ceil(600 / v) + T * 2, M = Math.min(h, D.value.length), P = D.value.length - M;
1309
- return P > 0 ? P * v : 0;
1310
- });
1311
- return (v, T) => (i(), c("div", Jl({
1312
- ref_key: "bodyRef",
1313
- ref: p,
1314
- class: t(n).classes.columnBody
1315
- }, v.$attrs, {
1316
- onScroll: Ie,
1317
- onClick: T[0] || (T[0] = Re((h) => t(o).isCollapsed.value ? t(o).toggleCollapse() : t(n).onBoardBackgroundClick(), ["self"]))
1318
- }), [
1319
- H.value && Fe.value > 0 ? (i(), c("div", {
1320
- key: 0,
1321
- style: ue({ height: Fe.value + "px", flexShrink: "0" })
1322
- }, null, 4)) : $("", !0),
1323
- ye.value ? (i(), c(E, { key: 1 }, [
1324
- F.value ? (i(), z(ee(f(S.value)), { key: 0 })) : (i(), c("div", {
1325
- key: 1,
1326
- class: k(t(n).classes.dropIndicator)
1327
- }, null, 2))
1328
- ], 64)) : $("", !0),
1329
- j.value.length > 0 || t(n).isDragging.value && String(t(n).dragTargetColumnValue.value) === String(t(o).value) ? (i(), c(E, { key: 2 }, [
1330
- (i(!0), c(E, null, pe(j.value, (h, M) => (i(), c(E, {
1331
- key: t(n).getItemId(h)
1332
- }, [
1333
- u(O(M)) ? (i(), c(E, { key: 0 }, [
1334
- F.value ? (i(), z(ee(f(O(M))), { key: 0 })) : (i(), c("div", {
1335
- key: 1,
1336
- class: k(t(n).classes.dropIndicator)
1337
- }, null, 2))
1338
- ], 64)) : $("", !0),
1339
- B("div", {
1340
- "data-task-id": t(n).getItemId(h),
1341
- "data-task-index": O(M),
1342
- class: k(t(n).cardWrapperClasses(h)),
1343
- role: "row",
1344
- onDblclick: (P) => t(n).onCardDblClick(h, b.value, P),
1345
- onPointerdown: (P) => t(n).onCardPointerDown(h, b.value, P),
1346
- onContextmenu: (P) => t(n).onCardContextMenu(h, b.value, P)
1347
- }, [
1348
- A(v.$slots, "default", {
1349
- item: h,
1350
- column: b.value,
1351
- isSelected: t(n).selectedItemIds.value.includes(t(n).getItemId(h)),
1352
- isDragging: t(n).isDragging.value && t(n).draggedItem.value && t(n).getItemId(t(n).draggedItem.value) === t(n).getItemId(h)
1353
- })
1354
- ], 42, Co)
1355
- ], 64))), 128)),
1356
- u(O(j.value.length)) ? (i(), c(E, { key: 0 }, [
1357
- F.value ? (i(), z(ee(f(O(j.value.length))), { key: 0 })) : (i(), c("div", {
1358
- key: 1,
1359
- class: k(t(n).classes.dropIndicator)
1360
- }, null, 2))
1361
- ], 64)) : $("", !0)
1362
- ], 64)) : (i(), c(E, { key: 3 }, [
1363
- t(n).isDragging.value && String(t(n).dragTargetColumnValue.value) === String(t(o).value) ? $("", !0) : (i(), c("div", {
1364
- key: 0,
1365
- class: k(t(n).classes.emptyColumn)
1366
- }, [
1367
- A(v.$slots, "empty", {}, () => [
1368
- T[1] || (T[1] = Be("No items", -1))
1369
- ])
1370
- ], 2))
1371
- ], 64)),
1372
- me.value ? (i(), c(E, { key: 4 }, [
1373
- F.value ? (i(), z(ee(f(S.value)), { key: 0 })) : (i(), c("div", {
1374
- key: 1,
1375
- class: k(t(n).classes.dropIndicator)
1376
- }, null, 2))
1377
- ], 64)) : $("", !0),
1378
- H.value && be.value > 0 ? (i(), c("div", {
1379
- key: 5,
1380
- style: ue({ height: be.value + "px", flexShrink: "0" })
1381
- }, null, 4)) : $("", !0)
1382
- ], 16));
1383
- }
1384
- }), So = /* @__PURE__ */ V({
1385
- __name: "TaskBoardColumnFooter",
1386
- setup(s) {
1387
- const l = L(Y), n = L(he);
1388
- return (o, p) => (i(), c("div", {
1389
- class: k(t(l).classes.columnFooter)
1390
- }, [
1391
- A(o.$slots, "default", {
1392
- column: t(n).columnData,
1393
- itemCount: t(n).itemCount.value
1394
- })
1395
- ], 2));
1396
- }
1397
- }), ko = /* @__PURE__ */ V({
1398
- __name: "TaskBoardColumnEmpty",
1399
- setup(s) {
1400
- const l = L(Y);
1401
- return (n, o) => (i(), c("div", {
1402
- class: k(t(l).classes.emptyColumn)
1403
- }, [
1404
- A(n.$slots, "default", {}, () => [
1405
- o[0] || (o[0] = Be("No items", -1))
1406
- ])
1407
- ], 2));
1408
- }
1409
- }), et = (s, l) => {
1410
- const n = s.__vccOpts || s;
1411
- for (const [o, p] of l)
1412
- n[o] = p;
1413
- return n;
1414
- }, Io = {};
1415
- function wo(s, l) {
1416
- return A(s.$slots, "default");
1417
- }
1418
- const ho = /* @__PURE__ */ et(Io, [["render", wo]]), yo = /* @__PURE__ */ V({
1419
- __name: "TaskBoardCard",
1420
- props: {
1421
- item: {},
1422
- column: {}
1423
- },
1424
- setup(s) {
1425
- const l = s, n = L(Y), o = L(he, null), p = g(() => l.item), m = g(() => l.column ?? (o ? o.columnData : void 0)), C = g(() => {
1426
- if (!l.item) return !1;
1427
- const I = n.getItemId(l.item);
1428
- return n.selectedItemIds.value.includes(I);
1429
- }), y = g(() => {
1430
- if (!l.item) return !1;
1431
- const I = n.getItemId(l.item);
1432
- return !!(n.isDragging.value && n.draggedItem.value && n.getItemId(n.draggedItem.value) === I);
1433
- }), R = {
1434
- item: zl(() => l.item),
1435
- column: zl(() => m.value),
1436
- isSelected: C,
1437
- isDragging: y
1438
- };
1439
- return $e(sl, R), (I, K) => A(I.$slots, "default", {
1440
- item: p.value,
1441
- isSelected: C.value,
1442
- isDragging: y.value,
1443
- column: m.value
1444
- });
1445
- }
1446
- }), bo = /* @__PURE__ */ V({
1447
- __name: "TaskBoardCardHeader",
1448
- setup(s) {
1449
- const l = L(sl);
1450
- return (n, o) => (i(), c("div", null, [
1451
- A(n.$slots, "default", {
1452
- item: t(l).item.value,
1453
- isSelected: t(l).isSelected.value,
1454
- isDragging: t(l).isDragging.value,
1455
- column: t(l).column.value
1456
- })
1457
- ]));
1458
- }
1459
- }), To = /* @__PURE__ */ V({
1460
- __name: "TaskBoardCardContent",
1461
- setup(s) {
1462
- const l = L(sl);
1463
- return (n, o) => (i(), c("div", null, [
1464
- A(n.$slots, "default", {
1465
- item: t(l).item.value,
1466
- isSelected: t(l).isSelected.value,
1467
- isDragging: t(l).isDragging.value,
1468
- column: t(l).column.value
1469
- })
1470
- ]));
1471
- }
1472
- }), xo = /* @__PURE__ */ V({
1473
- __name: "TaskBoardCardFooter",
1474
- setup(s) {
1475
- const l = L(sl);
1476
- return (n, o) => (i(), c("div", null, [
1477
- A(n.$slots, "default", {
1478
- item: t(l).item.value,
1479
- isSelected: t(l).isSelected.value,
1480
- isDragging: t(l).isDragging.value,
1481
- column: t(l).column.value
1482
- })
1483
- ]));
1484
- }
1485
- }), Do = /* @__PURE__ */ V({
1486
- __name: "TaskBoardCardAdd",
1487
- setup(s) {
1488
- const l = L(he);
1489
- return (n, o) => A(n.$slots, "default", {
1490
- add: t(l).addItem
1491
- });
1492
- }
1493
- }), Ho = /* @__PURE__ */ V({
1494
- __name: "TaskBoardDragPreview",
1495
- setup(s) {
1496
- const l = L(Y);
1497
- return ke(() => {
1498
- l.customDragPreviewCount.value += 1;
1499
- }), je(() => {
1500
- l.customDragPreviewCount.value = Math.max(0, l.customDragPreviewCount.value - 1);
1501
- }), (n, o) => (i(), z(Xl, { to: "body" }, [
1502
- t(l).isDragging.value && t(l).ghostPosition.value && t(l).draggedItem.value ? (i(), c("div", {
1503
- key: 0,
1504
- class: k(t(l).classes.dragPreview),
1505
- style: ue({
1506
- position: "fixed",
1507
- left: t(l).ghostPosition.value.x + "px",
1508
- top: t(l).ghostPosition.value.y + "px",
1509
- width: t(l).dragPreviewWidth.value ? t(l).dragPreviewWidth.value + "px" : void 0,
1510
- maxWidth: t(l).dragPreviewWidth.value ? t(l).dragPreviewWidth.value + "px" : void 0,
1511
- transform: "translate(-50%, -50%) rotate(var(--p-taskboard-drag-preview-rotation, 1.5deg))",
1512
- pointerEvents: "none",
1513
- zIndex: 9999
1514
- })
1515
- }, [
1516
- t(l).getDragHiddenIds().length > 1 ? (i(), c("span", {
1517
- key: 0,
1518
- class: k(t(l).classes.dragPreviewBadge)
1519
- }, te(t(l).getDragHiddenIds().length), 3)) : $("", !0),
1520
- A(n.$slots, "default", {
1521
- item: t(l).draggedItem.value,
1522
- count: t(l).getDragHiddenIds().length
1523
- })
1524
- ], 6)) : $("", !0)
1525
- ]));
1526
- }
1527
- }), _o = /* @__PURE__ */ V({
1528
- __name: "TaskBoardDragConfirm",
1529
- setup(s) {
1530
- const l = L(Y);
1531
- return (n, o) => t(l).pendingConfirmMove.value ? A(n.$slots, "default", {
1532
- key: 0,
1533
- task: t(l).pendingConfirmMove.value.task,
1534
- sourceColumn: t(l).processedColumns.value.find((p) => String(p.id) === String(t(l).pendingConfirmMove.value?.payload.oldColumnId)),
1535
- targetColumn: t(l).processedColumns.value.find((p) => String(p.id) === String(t(l).pendingConfirmMove.value?.payload.newColumnId)),
1536
- confirm: t(l).confirmPendingMove,
1537
- cancel: t(l).cancelPendingMove,
1538
- message: t(l).pendingConfirmMove.value.message
1539
- }) : $("", !0);
1540
- }
1541
- }), Mo = V({
1542
- name: "TaskBoardDropIndicator",
1543
- setup() {
1544
- const s = L(Y), l = qe();
1545
- return ke(() => {
1546
- s.registerDropIndicatorSlot((n) => l.default?.(n) ?? ia("div", { class: s.classes.dropIndicator }));
1547
- }), () => null;
1548
- }
1549
- }), Bo = {};
1550
- function Ro(s, l) {
1551
- return A(s.$slots, "default");
1552
- }
1553
- const $o = /* @__PURE__ */ et(Bo, [["render", Ro]]), Ao = /* @__PURE__ */ V({
1554
- __name: "TaskBoardSwimlaneHeader",
1555
- props: {
1556
- swimlane: {}
1557
- },
1558
- setup(s) {
1559
- const l = s, n = qe(), o = L(Y);
1560
- ke(() => {
1561
- n.default && !o.swimlaneHeaderSlotRenderer.value && o.registerSwimlaneHeaderSlot(n.default);
1562
- });
1563
- const p = g(() => l.swimlane ? o.swimlaneTaskCount(l.swimlane.id) : 0), m = g(() => l.swimlane ? o.isSwimlaneCollapsed(l.swimlane.id) : !1), C = () => {
1564
- l.swimlane && o.onSwimlaneToggle(l.swimlane);
1565
- };
1566
- return l.swimlane && $e(Zl, {
1567
- swimlaneData: l.swimlane,
1568
- taskCount: p,
1569
- isCollapsed: m,
1570
- toggleCollapse: C
1571
- }), (y, R) => l.swimlane ? A(y.$slots, "default", {
1572
- key: 0,
1573
- swimlane: s.swimlane,
1574
- itemCount: p.value,
1575
- isCollapsed: m.value,
1576
- toggleCollapse: C
1577
- }) : $("", !0);
1578
- }
1579
- }), Eo = /* @__PURE__ */ V({
1580
- __name: "TaskBoardSwimlaneColumnHeader",
1581
- props: {
1582
- column: {}
1583
- },
1584
- setup(s) {
1585
- const l = s, n = qe(), o = L(Y);
1586
- ke(() => {
1587
- n.default && !o.swimlaneColumnHeaderSlotRenderer?.value && o.registerSwimlaneColumnHeaderSlot?.(n.default);
1588
- });
1589
- const p = g(() => l.column ? o.itemCount(l.column.id) : 0);
1590
- return (m, C) => l.column ? A(m.$slots, "default", {
1591
- key: 0,
1592
- column: s.column,
1593
- itemCount: p.value
1594
- }) : $("", !0);
1595
- }
1596
- }), No = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
1
+ import { _ as a } from "./chunks/TaskBoard.vue_vue_type_script_setup_true_lang-Djmr6yoF.mjs";
2
+ import { _ as o } from "./chunks/TaskBoardHeader.vue_vue_type_script_setup_true_lang-CwtaadkE.mjs";
3
+ import { _ as r } from "./chunks/TaskBoardContent.vue_vue_type_script_setup_true_lang-lDUg6UrJ.mjs";
4
+ import { _ as s } from "./chunks/TaskBoardColumn.vue_vue_type_script_setup_true_lang-D_AJ5j7c.mjs";
5
+ import { _ as m } from "./chunks/TaskBoardColumnHeader.vue_vue_type_script_setup_true_lang-DMc9zcWV.mjs";
6
+ import { _ as e } from "./chunks/TaskBoardColumnContent.vue_vue_type_script_setup_true_lang-DNRiWBN_.mjs";
7
+ import { _ as d } from "./chunks/TaskBoardColumnFooter.vue_vue_type_script_setup_true_lang-BpKRnC6u.mjs";
8
+ import { _ as n } from "./chunks/TaskBoardColumnEmpty.vue_vue_type_script_setup_true_lang-D23AtNeX.mjs";
9
+ import { T as t } from "./chunks/TaskBoardColumnAdd-C_JSN3pp.mjs";
10
+ import { _ } from "./chunks/TaskBoardCard.vue_vue_type_script_setup_true_lang-B1Ix7Gjf.mjs";
11
+ import { _ as i } from "./chunks/TaskBoardCardHeader.vue_vue_type_script_setup_true_lang-Dr-XJfaE.mjs";
12
+ import { _ as f } from "./chunks/TaskBoardCardContent.vue_vue_type_script_setup_true_lang-DNEmpvcn.mjs";
13
+ import { _ as C } from "./chunks/TaskBoardCardFooter.vue_vue_type_script_setup_true_lang-8FWnuxSl.mjs";
14
+ import { _ as T } from "./chunks/TaskBoardCardAdd.vue_vue_type_script_setup_true_lang-Dy4BuCa9.mjs";
15
+ import { _ as k } from "./chunks/TaskBoardDragPreview.vue_vue_type_script_setup_true_lang-B7F-FPY1.mjs";
16
+ import { _ as B } from "./chunks/TaskBoardDragConfirm.vue_vue_type_script_setup_true_lang-B4OdxK5L.mjs";
17
+ import { T as p } from "./chunks/TaskBoardDropIndicator-BUMSBiQC.mjs";
18
+ import { T as u } from "./chunks/TaskBoardLoading-CrgtYPP-.mjs";
19
+ import { _ as c } from "./chunks/TaskBoardSwimlaneHeader.vue_vue_type_script_setup_true_lang-D6NdS4hP.mjs";
20
+ import { _ as l } from "./chunks/TaskBoardSwimlaneColumnHeader.vue_vue_type_script_setup_true_lang-BVpen7mj.mjs";
21
+ import { C as W, a as z, S as U, T as h, u as q, b as G, c as J, d as Q } from "./chunks/TaskBoard.context-BCq7uauT.mjs";
22
+ import { u as X, a as Z, b as aa, c as oa, d as ra } from "./chunks/useTaskBoardDrag-BvBISSNb.mjs";
23
+ const P = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
1597
24
  __proto__: null,
1598
- Card: yo,
1599
- CardAdd: Do,
1600
- CardContent: To,
1601
- CardFooter: xo,
1602
- CardHeader: bo,
1603
- Column: vo,
1604
- ColumnAdd: ho,
1605
- ColumnContent: fo,
1606
- ColumnEmpty: ko,
1607
- ColumnFooter: So,
1608
- ColumnHeader: po,
1609
- Content: co,
1610
- DragConfirm: _o,
1611
- DragPreview: Ho,
1612
- DropIndicator: Mo,
1613
- Header: eo,
1614
- Loading: $o,
1615
- Root: Za,
1616
- SwimlaneColumnHeader: Eo,
1617
- SwimlaneHeader: Ao
25
+ Card: _,
26
+ CardAdd: T,
27
+ CardContent: f,
28
+ CardFooter: C,
29
+ CardHeader: i,
30
+ Column: s,
31
+ ColumnAdd: t,
32
+ ColumnContent: e,
33
+ ColumnEmpty: n,
34
+ ColumnFooter: d,
35
+ ColumnHeader: m,
36
+ Content: r,
37
+ DragConfirm: B,
38
+ DragPreview: k,
39
+ DropIndicator: p,
40
+ Header: o,
41
+ Loading: u,
42
+ Root: a,
43
+ SwimlaneColumnHeader: l,
44
+ SwimlaneHeader: c
1618
45
  }, Symbol.toStringTag, { value: "Module" }));
1619
46
  export {
1620
- sl as CARD_KEY,
1621
- he as COLUMN_KEY,
1622
- Zl as SWIMLANE_KEY,
1623
- Y as TASKBOARD_KEY,
1624
- No as TaskBoard,
1625
- yo as TaskBoardCard,
1626
- Do as TaskBoardCardAdd,
1627
- To as TaskBoardCardContent,
1628
- xo as TaskBoardCardFooter,
1629
- bo as TaskBoardCardHeader,
1630
- vo as TaskBoardColumn,
1631
- ho as TaskBoardColumnAdd,
1632
- fo as TaskBoardColumnContent,
1633
- ko as TaskBoardColumnEmpty,
1634
- So as TaskBoardColumnFooter,
1635
- po as TaskBoardColumnHeader,
1636
- co as TaskBoardContent,
1637
- _o as TaskBoardDragConfirm,
1638
- Ho as TaskBoardDragPreview,
1639
- Mo as TaskBoardDropIndicator,
1640
- eo as TaskBoardHeader,
1641
- $o as TaskBoardLoading,
1642
- Za as TaskBoardRoot,
1643
- Eo as TaskBoardSwimlaneColumnHeader,
1644
- Ao as TaskBoardSwimlaneHeader,
1645
- Yo as useTaskBoardAccess,
1646
- Xo as useTaskBoardCardContext,
1647
- Jo as useTaskBoardColumnContext,
1648
- Qo as useTaskBoardContext,
1649
- Zo as useTaskBoardDrag,
1650
- en as useTaskBoardHistory,
1651
- ln as useTaskBoardSelection,
1652
- tn as useTaskBoardSwimlaneHeaderContext,
1653
- an as useTaskBoardWorkflow
47
+ W as CARD_KEY,
48
+ z as COLUMN_KEY,
49
+ U as SWIMLANE_KEY,
50
+ h as TASKBOARD_KEY,
51
+ P as TaskBoard,
52
+ _ as TaskBoardCard,
53
+ T as TaskBoardCardAdd,
54
+ f as TaskBoardCardContent,
55
+ C as TaskBoardCardFooter,
56
+ i as TaskBoardCardHeader,
57
+ s as TaskBoardColumn,
58
+ t as TaskBoardColumnAdd,
59
+ e as TaskBoardColumnContent,
60
+ n as TaskBoardColumnEmpty,
61
+ d as TaskBoardColumnFooter,
62
+ m as TaskBoardColumnHeader,
63
+ r as TaskBoardContent,
64
+ B as TaskBoardDragConfirm,
65
+ k as TaskBoardDragPreview,
66
+ p as TaskBoardDropIndicator,
67
+ o as TaskBoardHeader,
68
+ u as TaskBoardLoading,
69
+ a as TaskBoardRoot,
70
+ l as TaskBoardSwimlaneColumnHeader,
71
+ c as TaskBoardSwimlaneHeader,
72
+ X as useTaskBoardAccess,
73
+ q as useTaskBoardCardContext,
74
+ G as useTaskBoardColumnContext,
75
+ J as useTaskBoardContext,
76
+ Z as useTaskBoardDrag,
77
+ aa as useTaskBoardHistory,
78
+ oa as useTaskBoardSelection,
79
+ Q as useTaskBoardSwimlaneHeaderContext,
80
+ ra as useTaskBoardWorkflow
1654
81
  };