@devalok/shilp-sutra-karm 0.12.0 → 0.13.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -1,22 +1,22 @@
1
1
  "use client";
2
2
  import { jsx as e, jsxs as a, Fragment as se } from "react/jsx-runtime";
3
- import * as j from "react";
4
- import { useMemo as ne, useState as A, useEffect as oe, useCallback as E, useContext as Ye, createContext as qe, useRef as ae } from "react";
5
- import { createPortal as Xe } from "react-dom";
6
- import { u as Ce, C as Ne, c as Ie, a as Je, S as De, v as Ze, b as et, d as he, D as tt, e as st, h as nt, f as at, s as rt, K as it, T as ot, P as lt } from "./vendor.js";
7
- import { cn as I } from "@devalok/shilp-sutra/ui/lib/utils";
3
+ import * as Q from "react";
4
+ import { useMemo as ne, useState as O, useEffect as oe, useCallback as B, useContext as qe, createContext as Xe, useRef as ae } from "react";
5
+ import { createPortal as Je } from "react-dom";
6
+ import { u as Ne, C as Ie, c as De, a as Ze, S as Te, v as et, b as tt, d as he, D as st, e as nt, h as at, f as rt, s as it, K as ot, T as lt, P as ct } from "./vendor.js";
7
+ import { cn as N } from "@devalok/shilp-sutra/ui/lib/utils";
8
8
  import { Input as re } from "@devalok/shilp-sutra/ui/input";
9
- import { Button as O } from "@devalok/shilp-sutra/ui/button";
10
- import { Badge as ct } from "@devalok/shilp-sutra/ui/badge";
11
- import { DropdownMenu as z, DropdownMenuTrigger as V, DropdownMenuContent as F, DropdownMenuLabel as Q, DropdownMenuSeparator as G, DropdownMenuCheckboxItem as ge, DropdownMenuRadioGroup as dt, DropdownMenuRadioItem as mt, DropdownMenuItem as $ } from "@devalok/shilp-sutra/ui/dropdown-menu";
12
- import { SegmentedControl as ut } from "@devalok/shilp-sutra/ui/segmented-control";
13
- import { IconX as ie, IconSearch as ht, IconFilter as gt, IconUser as q, IconLayoutGrid as ft, IconLayoutList as pt, IconArrowRight as fe, IconAlertTriangle as le, IconEye as X, IconTrash as pe, IconPlus as xe, IconDots as xt, IconPencil as yt, IconGauge as vt, IconEyeOff as Te, IconCalendar as ye, IconCheck as wt, IconArrowUp as Re, IconArrowDown as Se, IconGripVertical as bt, IconSubtask as kt, IconLock as Ct, IconTag as Nt } from "@tabler/icons-react";
14
- import { AvatarGroup as It } from "@devalok/shilp-sutra/composed/avatar-group";
15
- import { u as Ae } from "./use-composed-ref.js";
16
- import { Checkbox as Me } from "@devalok/shilp-sutra/ui";
17
- import { Avatar as Dt, AvatarImage as Tt, AvatarFallback as Rt } from "@devalok/shilp-sutra/ui/avatar";
18
- import { ContextMenu as St, ContextMenuTrigger as At, ContextMenuContent as Mt, ContextMenuSub as Z, ContextMenuSubTrigger as ee, ContextMenuSubContent as te, ContextMenuItem as H, ContextMenuSeparator as Lt } from "@devalok/shilp-sutra/ui/context-menu";
19
- const Et = 320, ve = [
9
+ import { Button as $ } from "@devalok/shilp-sutra/ui/button";
10
+ import { Badge as dt } from "@devalok/shilp-sutra/ui/badge";
11
+ import { DropdownMenu as V, DropdownMenuTrigger as U, DropdownMenuContent as G, DropdownMenuLabel as Y, DropdownMenuSeparator as H, DropdownMenuCheckboxItem as ge, DropdownMenuRadioGroup as ut, DropdownMenuRadioItem as mt, DropdownMenuItem as F } from "@devalok/shilp-sutra/ui/dropdown-menu";
12
+ import { SegmentedControl as ht } from "@devalok/shilp-sutra/ui/segmented-control";
13
+ import { IconX as ie, IconSearch as gt, IconFilter as ft, IconUser as q, IconLayoutGrid as pt, IconLayoutList as xt, IconArrowRight as pe, IconAlertTriangle as le, IconEye as X, IconTrash as xe, IconPlus as ye, IconDots as yt, IconPencil as vt, IconGauge as wt, IconEyeOff as Re, IconCalendar as ve, IconCheck as bt, IconArrowUp as Se, IconArrowDown as Ae, IconGripVertical as kt, IconSubtask as Ct, IconLock as Nt, IconTag as It } from "@tabler/icons-react";
14
+ import { AvatarGroup as Dt } from "@devalok/shilp-sutra/composed/avatar-group";
15
+ import { u as Me } from "./use-composed-ref.js";
16
+ import { Checkbox as Le } from "@devalok/shilp-sutra/ui";
17
+ import { Avatar as Tt, AvatarImage as Rt, AvatarFallback as St } from "@devalok/shilp-sutra/ui/avatar";
18
+ import { ContextMenu as At, ContextMenuTrigger as Mt, ContextMenuContent as Lt, ContextMenuSub as Z, ContextMenuSubTrigger as ee, ContextMenuSubContent as te, ContextMenuItem as j, ContextMenuSeparator as Et } from "@devalok/shilp-sutra/ui/context-menu";
19
+ const Ot = 320, we = [
20
20
  "bg-category-cyan",
21
21
  "bg-category-amber",
22
22
  "bg-category-teal",
@@ -25,7 +25,7 @@ const Et = 320, ve = [
25
25
  "bg-category-emerald",
26
26
  "bg-category-slate",
27
27
  "bg-accent"
28
- ], fs = {
28
+ ], ps = {
29
29
  LOW: "IconArrowDown",
30
30
  MEDIUM: "IconArrowRight",
31
31
  HIGH: "IconArrowUp",
@@ -35,14 +35,14 @@ const Et = 320, ve = [
35
35
  MEDIUM: "text-warning",
36
36
  HIGH: "text-error",
37
37
  URGENT: "text-error"
38
- }, we = {
38
+ }, be = {
39
39
  search: "",
40
40
  assignees: [],
41
41
  priorities: [],
42
42
  labels: [],
43
43
  dueDateRange: null
44
44
  };
45
- function Ot(s, t) {
45
+ function Bt(s, t) {
46
46
  if (t.search) {
47
47
  const n = t.search.toLowerCase();
48
48
  if (!s.title.toLowerCase().includes(n) && !s.taskId.toLowerCase().includes(n))
@@ -80,19 +80,19 @@ function Ot(s, t) {
80
80
  }
81
81
  return !0;
82
82
  }
83
- function Bt(s, t) {
83
+ function Wt(s, t) {
84
84
  return ne(() => t.search !== "" || t.priorities.length > 0 || t.assignees.length > 0 || t.labels.length > 0 || t.dueDateRange != null && t.dueDateRange !== "none" ? s.map((r) => ({
85
85
  ...r,
86
- tasks: r.tasks.filter((o) => Ot(o, t))
86
+ tasks: r.tasks.filter((o) => Bt(o, t))
87
87
  })) : s, [s, t]);
88
88
  }
89
- const Le = qe(null);
90
- function U() {
91
- const s = Ye(Le);
89
+ const Ee = Xe(null);
90
+ function K() {
91
+ const s = qe(Ee);
92
92
  if (!s) throw new Error("useBoardContext must be used within <BoardProvider>");
93
93
  return s;
94
94
  }
95
- const L = () => {
95
+ const P = () => {
96
96
  };
97
97
  function Pt({
98
98
  initialData: s,
@@ -100,94 +100,94 @@ function Pt({
100
100
  children: n,
101
101
  ...r
102
102
  }) {
103
- const [o, h] = A(s.columns);
103
+ const [o, h] = O(s.columns);
104
104
  oe(() => {
105
105
  h(s.columns);
106
106
  }, [s]);
107
- const [b, v] = A("default"), [d, c] = A(we), x = E((B) => {
108
- c((_) => ({ ..._, ...B }));
109
- }, []), T = E(() => c(we), []), y = ne(
107
+ const [b, v] = O("default"), [d, l] = O(be), x = B((T) => {
108
+ l((R) => ({ ...R, ...T }));
109
+ }, []), D = B(() => l(be), []), g = ne(
110
110
  () => d.search !== "" || d.priorities.length > 0 || d.assignees.length > 0 || d.labels.length > 0 || d.dueDateRange != null && d.dueDateRange !== "none",
111
111
  [d]
112
- ), g = Bt(o, d), [S, u] = A(/* @__PURE__ */ new Set()), k = E((B) => {
113
- u((_) => {
114
- const P = new Set(_);
115
- return P.has(B) ? P.delete(B) : P.add(B), P;
112
+ ), f = Wt(o, d), [A, c] = O(/* @__PURE__ */ new Set()), k = B((T) => {
113
+ c((R) => {
114
+ const C = new Set(R);
115
+ return C.has(T) ? C.delete(T) : C.add(T), C;
116
116
  });
117
- }, []), l = E(
118
- (B, _) => {
119
- const P = g.flatMap((W) => W.tasks), Y = P.findIndex((W) => W.id === B), K = P.findIndex((W) => W.id === _);
120
- if (Y === -1 || K === -1) return;
121
- const [J, me] = Y < K ? [Y, K] : [K, Y], ue = P.slice(J, me + 1).map((W) => W.id);
122
- u((W) => {
123
- const w = new Set(W);
124
- return ue.forEach((je) => w.add(je)), w;
117
+ }, []), u = B(
118
+ (T, R) => {
119
+ const C = f.flatMap((_) => _.tasks), W = C.findIndex((_) => _.id === T), z = C.findIndex((_) => _.id === R);
120
+ if (W === -1 || z === -1) return;
121
+ const [J, ue] = W < z ? [W, z] : [z, W], me = C.slice(J, ue + 1).map((_) => _.id);
122
+ c((_) => {
123
+ const w = new Set(_);
124
+ return me.forEach((Ye) => w.add(Ye)), w;
125
125
  });
126
126
  },
127
- [g]
128
- ), p = E(() => {
129
- const B = g.flatMap((_) => _.tasks.map((P) => P.id));
130
- u(new Set(B));
131
- }, [g]), m = E(() => u(/* @__PURE__ */ new Set()), []), [C, i] = A(null), [f, D] = A(!1), [M, N] = A(null), R = ne(
127
+ [f]
128
+ ), I = B(() => {
129
+ const T = f.flatMap((R) => R.tasks.map((C) => C.id));
130
+ c(new Set(T));
131
+ }, [f]), m = B(() => c(/* @__PURE__ */ new Set()), []), [y, i] = O(null), [p, S] = O(!1), [M, L] = O(null), E = ne(
132
132
  () => ({
133
- columns: g,
133
+ columns: f,
134
134
  rawColumns: o,
135
135
  viewMode: b,
136
136
  setViewMode: v,
137
137
  filters: d,
138
138
  setFilters: x,
139
- clearFilters: T,
140
- hasActiveFilters: y,
141
- selectedTaskIds: S,
139
+ clearFilters: D,
140
+ hasActiveFilters: g,
141
+ selectedTaskIds: A,
142
142
  toggleTaskSelection: k,
143
- selectRange: l,
144
- selectAll: p,
143
+ selectRange: u,
144
+ selectAll: I,
145
145
  clearSelection: m,
146
- focusedTaskId: C,
146
+ focusedTaskId: y,
147
147
  setFocusedTaskId: i,
148
148
  currentUserId: t,
149
- highlightMyTasks: f,
150
- setHighlightMyTasks: D,
149
+ highlightMyTasks: p,
150
+ setHighlightMyTasks: S,
151
151
  activeTask: M,
152
- setActiveTask: N,
153
- onTaskMove: r.onTaskMove ?? L,
154
- onTaskAdd: r.onTaskAdd ?? L,
155
- onBulkAction: r.onBulkAction ?? L,
156
- onColumnReorder: r.onColumnReorder ?? L,
157
- onColumnRename: r.onColumnRename ?? L,
158
- onColumnDelete: r.onColumnDelete ?? L,
159
- onColumnToggleVisibility: r.onColumnToggleVisibility ?? L,
160
- onColumnWipLimitChange: r.onColumnWipLimitChange ?? L,
161
- onClickTask: r.onClickTask ?? L,
162
- onAddColumn: r.onAddColumn ?? L,
163
- onQuickPriorityChange: r.onQuickPriorityChange ?? L,
164
- onQuickAssign: r.onQuickAssign ?? L,
165
- onQuickDueDateChange: r.onQuickDueDateChange ?? L,
166
- onQuickLabelAdd: r.onQuickLabelAdd ?? L,
167
- onQuickVisibilityChange: r.onQuickVisibilityChange ?? L,
168
- onQuickDelete: r.onQuickDelete ?? L
152
+ setActiveTask: L,
153
+ onTaskMove: r.onTaskMove ?? P,
154
+ onTaskAdd: r.onTaskAdd ?? P,
155
+ onBulkAction: r.onBulkAction ?? P,
156
+ onColumnReorder: r.onColumnReorder ?? P,
157
+ onColumnRename: r.onColumnRename ?? P,
158
+ onColumnDelete: r.onColumnDelete ?? P,
159
+ onColumnToggleVisibility: r.onColumnToggleVisibility ?? P,
160
+ onColumnWipLimitChange: r.onColumnWipLimitChange ?? P,
161
+ onClickTask: r.onClickTask ?? P,
162
+ onAddColumn: r.onAddColumn ?? P,
163
+ onQuickPriorityChange: r.onQuickPriorityChange ?? P,
164
+ onQuickAssign: r.onQuickAssign ?? P,
165
+ onQuickDueDateChange: r.onQuickDueDateChange ?? P,
166
+ onQuickLabelAdd: r.onQuickLabelAdd ?? P,
167
+ onQuickVisibilityChange: r.onQuickVisibilityChange ?? P,
168
+ onQuickDelete: r.onQuickDelete ?? P
169
169
  }),
170
170
  [
171
- g,
171
+ f,
172
172
  o,
173
173
  b,
174
174
  d,
175
175
  x,
176
- T,
177
- y,
178
- S,
176
+ D,
177
+ g,
178
+ A,
179
179
  k,
180
- l,
181
- p,
180
+ u,
181
+ I,
182
182
  m,
183
- C,
183
+ y,
184
184
  t,
185
- f,
185
+ p,
186
186
  M,
187
187
  r
188
188
  ]
189
189
  );
190
- return /* @__PURE__ */ e(Le.Provider, { value: R, children: n });
190
+ return /* @__PURE__ */ e(Ee.Provider, { value: E, children: n });
191
191
  }
192
192
  function de(s) {
193
193
  const t = /* @__PURE__ */ new Set(), n = [];
@@ -199,19 +199,19 @@ function de(s) {
199
199
  }
200
200
  return n;
201
201
  }
202
- function Ee(s) {
202
+ function Oe(s) {
203
203
  const t = /* @__PURE__ */ new Set();
204
204
  for (const n of s)
205
205
  for (const r of n.tasks)
206
206
  for (const o of r.labels) t.add(o);
207
207
  return Array.from(t).sort();
208
208
  }
209
- const Wt = ["LOW", "MEDIUM", "HIGH", "URGENT"], be = [
209
+ const $t = ["LOW", "MEDIUM", "HIGH", "URGENT"], ke = [
210
210
  { value: "overdue", label: "Overdue" },
211
211
  { value: "today", label: "Today" },
212
212
  { value: "this-week", label: "This week" }
213
213
  ];
214
- function Oe() {
214
+ function Be() {
215
215
  const {
216
216
  rawColumns: s,
217
217
  filters: t,
@@ -222,11 +222,11 @@ function Oe() {
222
222
  setViewMode: b,
223
223
  highlightMyTasks: v,
224
224
  setHighlightMyTasks: d
225
- } = U(), [c, x] = A(t.search), T = ae(null), y = E(
225
+ } = K(), [l, x] = O(t.search), D = ae(null), g = B(
226
226
  (i) => {
227
- const f = i.target.value;
228
- x(f), T.current && clearTimeout(T.current), T.current = setTimeout(() => {
229
- n({ search: f });
227
+ const p = i.target.value;
228
+ x(p), D.current && clearTimeout(D.current), D.current = setTimeout(() => {
229
+ n({ search: p });
230
230
  }, 200);
231
231
  },
232
232
  [n]
@@ -234,52 +234,52 @@ function Oe() {
234
234
  oe(() => {
235
235
  x(t.search);
236
236
  }, [t.search]);
237
- const g = de(s), S = Ee(s), u = (i) => {
238
- const f = t.priorities;
237
+ const f = de(s), A = Oe(s), c = (i) => {
238
+ const p = t.priorities;
239
239
  n({
240
- priorities: f.includes(i) ? f.filter((D) => D !== i) : [...f, i]
240
+ priorities: p.includes(i) ? p.filter((S) => S !== i) : [...p, i]
241
241
  });
242
242
  }, k = (i) => {
243
- const f = t.assignees;
243
+ const p = t.assignees;
244
244
  n({
245
- assignees: f.includes(i) ? f.filter((D) => D !== i) : [...f, i]
245
+ assignees: p.includes(i) ? p.filter((S) => S !== i) : [...p, i]
246
246
  });
247
- }, l = (i) => {
248
- const f = t.labels;
247
+ }, u = (i) => {
248
+ const p = t.labels;
249
249
  n({
250
- labels: f.includes(i) ? f.filter((D) => D !== i) : [...f, i]
250
+ labels: p.includes(i) ? p.filter((S) => S !== i) : [...p, i]
251
251
  });
252
- }, p = (i) => {
252
+ }, I = (i) => {
253
253
  n({
254
254
  dueDateRange: i === t.dueDateRange ? null : i
255
255
  });
256
256
  }, m = [
257
- { id: "default", text: "Board", icon: ft },
258
- { id: "compact", text: "Compact", icon: pt }
259
- ], C = [];
257
+ { id: "default", text: "Board", icon: pt },
258
+ { id: "compact", text: "Compact", icon: xt }
259
+ ], y = [];
260
260
  for (const i of t.priorities)
261
- C.push({
261
+ y.push({
262
262
  key: `priority-${i}`,
263
263
  label: i.charAt(0) + i.slice(1).toLowerCase(),
264
- onRemove: () => u(i)
264
+ onRemove: () => c(i)
265
265
  });
266
266
  for (const i of t.assignees) {
267
- const f = g.find((D) => D.id === i);
268
- C.push({
267
+ const p = f.find((S) => S.id === i);
268
+ y.push({
269
269
  key: `assignee-${i}`,
270
- label: (f == null ? void 0 : f.name) ?? i,
270
+ label: (p == null ? void 0 : p.name) ?? i,
271
271
  onRemove: () => k(i)
272
272
  });
273
273
  }
274
274
  for (const i of t.labels)
275
- C.push({
275
+ y.push({
276
276
  key: `label-${i}`,
277
277
  label: i,
278
- onRemove: () => l(i)
278
+ onRemove: () => u(i)
279
279
  });
280
280
  if (t.dueDateRange && t.dueDateRange !== "none") {
281
- const i = be.find((f) => f.value === t.dueDateRange);
282
- C.push({
281
+ const i = ke.find((p) => p.value === t.dueDateRange);
282
+ y.push({
283
283
  key: "due-date",
284
284
  label: (i == null ? void 0 : i.label) ?? t.dueDateRange,
285
285
  onRemove: () => n({ dueDateRange: null })
@@ -290,13 +290,13 @@ function Oe() {
290
290
  /* @__PURE__ */ e("div", { className: "relative flex-1 max-w-xs", children: /* @__PURE__ */ e(
291
291
  re,
292
292
  {
293
- value: c,
294
- onChange: y,
293
+ value: l,
294
+ onChange: g,
295
295
  placeholder: "Search tasks...",
296
296
  "aria-label": "Search tasks",
297
297
  size: "sm",
298
- startIcon: /* @__PURE__ */ e(ht, { className: "h-ico-sm w-ico-sm" }),
299
- endIcon: c ? /* @__PURE__ */ e(
298
+ startIcon: /* @__PURE__ */ e(gt, { className: "h-ico-sm w-ico-sm" }),
299
+ endIcon: l ? /* @__PURE__ */ e(
300
300
  "button",
301
301
  {
302
302
  onClick: () => {
@@ -310,18 +310,18 @@ function Oe() {
310
310
  }
311
311
  ) }),
312
312
  /* @__PURE__ */ a("div", { className: "flex items-center gap-ds-01", children: [
313
- /* @__PURE__ */ a(z, { children: [
314
- /* @__PURE__ */ e(V, { asChild: !0, children: /* @__PURE__ */ a(
315
- O,
313
+ /* @__PURE__ */ a(V, { children: [
314
+ /* @__PURE__ */ e(U, { asChild: !0, children: /* @__PURE__ */ a(
315
+ $,
316
316
  {
317
317
  variant: "ghost",
318
318
  size: "sm",
319
- className: I(
319
+ className: N(
320
320
  t.priorities.length > 0 && "text-interactive"
321
321
  ),
322
322
  title: "Filter by priority",
323
323
  children: [
324
- /* @__PURE__ */ e(gt, { className: "h-ico-sm w-ico-sm mr-ds-01" }),
324
+ /* @__PURE__ */ e(ft, { className: "h-ico-sm w-ico-sm mr-ds-01" }),
325
325
  "Priority",
326
326
  t.priorities.length > 0 && /* @__PURE__ */ a("span", { className: "ml-ds-01 text-ds-xs", children: [
327
327
  "(",
@@ -331,27 +331,27 @@ function Oe() {
331
331
  ]
332
332
  }
333
333
  ) }),
334
- /* @__PURE__ */ a(F, { align: "start", className: "w-44", children: [
335
- /* @__PURE__ */ e(Q, { children: "Priority" }),
336
- /* @__PURE__ */ e(G, {}),
337
- Wt.map((i) => /* @__PURE__ */ e(
334
+ /* @__PURE__ */ a(G, { align: "start", className: "w-44", children: [
335
+ /* @__PURE__ */ e(Y, { children: "Priority" }),
336
+ /* @__PURE__ */ e(H, {}),
337
+ $t.map((i) => /* @__PURE__ */ e(
338
338
  ge,
339
339
  {
340
340
  checked: t.priorities.includes(i),
341
- onCheckedChange: () => u(i),
341
+ onCheckedChange: () => c(i),
342
342
  children: i.charAt(0) + i.slice(1).toLowerCase()
343
343
  },
344
344
  i
345
345
  ))
346
346
  ] })
347
347
  ] }),
348
- g.length > 0 && /* @__PURE__ */ a(z, { children: [
349
- /* @__PURE__ */ e(V, { asChild: !0, children: /* @__PURE__ */ a(
350
- O,
348
+ f.length > 0 && /* @__PURE__ */ a(V, { children: [
349
+ /* @__PURE__ */ e(U, { asChild: !0, children: /* @__PURE__ */ a(
350
+ $,
351
351
  {
352
352
  variant: "ghost",
353
353
  size: "sm",
354
- className: I(
354
+ className: N(
355
355
  t.assignees.length > 0 && "text-interactive"
356
356
  ),
357
357
  title: "Filter by assignee",
@@ -366,10 +366,10 @@ function Oe() {
366
366
  ]
367
367
  }
368
368
  ) }),
369
- /* @__PURE__ */ a(F, { align: "start", className: "w-48 max-h-56 overflow-y-auto", children: [
370
- /* @__PURE__ */ e(Q, { children: "Assignee" }),
371
- /* @__PURE__ */ e(G, {}),
372
- g.map((i) => /* @__PURE__ */ e(
369
+ /* @__PURE__ */ a(G, { align: "start", className: "w-48 max-h-56 overflow-y-auto", children: [
370
+ /* @__PURE__ */ e(Y, { children: "Assignee" }),
371
+ /* @__PURE__ */ e(H, {}),
372
+ f.map((i) => /* @__PURE__ */ e(
373
373
  ge,
374
374
  {
375
375
  checked: t.assignees.includes(i.id),
@@ -380,13 +380,13 @@ function Oe() {
380
380
  ))
381
381
  ] })
382
382
  ] }),
383
- S.length > 0 && /* @__PURE__ */ a(z, { children: [
384
- /* @__PURE__ */ e(V, { asChild: !0, children: /* @__PURE__ */ a(
385
- O,
383
+ A.length > 0 && /* @__PURE__ */ a(V, { children: [
384
+ /* @__PURE__ */ e(U, { asChild: !0, children: /* @__PURE__ */ a(
385
+ $,
386
386
  {
387
387
  variant: "ghost",
388
388
  size: "sm",
389
- className: I(
389
+ className: N(
390
390
  t.labels.length > 0 && "text-interactive"
391
391
  ),
392
392
  title: "Filter by label",
@@ -400,42 +400,42 @@ function Oe() {
400
400
  ]
401
401
  }
402
402
  ) }),
403
- /* @__PURE__ */ a(F, { align: "start", className: "w-44 max-h-56 overflow-y-auto", children: [
404
- /* @__PURE__ */ e(Q, { children: "Label" }),
405
- /* @__PURE__ */ e(G, {}),
406
- S.map((i) => /* @__PURE__ */ e(
403
+ /* @__PURE__ */ a(G, { align: "start", className: "w-44 max-h-56 overflow-y-auto", children: [
404
+ /* @__PURE__ */ e(Y, { children: "Label" }),
405
+ /* @__PURE__ */ e(H, {}),
406
+ A.map((i) => /* @__PURE__ */ e(
407
407
  ge,
408
408
  {
409
409
  checked: t.labels.includes(i),
410
- onCheckedChange: () => l(i),
410
+ onCheckedChange: () => u(i),
411
411
  children: i
412
412
  },
413
413
  i
414
414
  ))
415
415
  ] })
416
416
  ] }),
417
- /* @__PURE__ */ a(z, { children: [
418
- /* @__PURE__ */ e(V, { asChild: !0, children: /* @__PURE__ */ e(
419
- O,
417
+ /* @__PURE__ */ a(V, { children: [
418
+ /* @__PURE__ */ e(U, { asChild: !0, children: /* @__PURE__ */ e(
419
+ $,
420
420
  {
421
421
  variant: "ghost",
422
422
  size: "sm",
423
- className: I(
423
+ className: N(
424
424
  t.dueDateRange && t.dueDateRange !== "none" && "text-interactive"
425
425
  ),
426
426
  title: "Filter by due date",
427
427
  children: "Due date"
428
428
  }
429
429
  ) }),
430
- /* @__PURE__ */ a(F, { align: "start", className: "w-40", children: [
431
- /* @__PURE__ */ e(Q, { children: "Due date" }),
432
- /* @__PURE__ */ e(G, {}),
430
+ /* @__PURE__ */ a(G, { align: "start", className: "w-40", children: [
431
+ /* @__PURE__ */ e(Y, { children: "Due date" }),
432
+ /* @__PURE__ */ e(H, {}),
433
433
  /* @__PURE__ */ e(
434
- dt,
434
+ ut,
435
435
  {
436
436
  value: t.dueDateRange ?? "",
437
- onValueChange: p,
438
- children: be.map((i) => /* @__PURE__ */ e(mt, { value: i.value, children: i.label }, i.value))
437
+ onValueChange: I,
438
+ children: ke.map((i) => /* @__PURE__ */ e(mt, { value: i.value, children: i.label }, i.value))
439
439
  }
440
440
  )
441
441
  ] })
@@ -443,7 +443,7 @@ function Oe() {
443
443
  ] }),
444
444
  /* @__PURE__ */ e("div", { className: "flex-1" }),
445
445
  /* @__PURE__ */ e(
446
- O,
446
+ $,
447
447
  {
448
448
  variant: v ? "outline" : "ghost",
449
449
  size: "sm",
@@ -451,12 +451,12 @@ function Oe() {
451
451
  title: "Highlight my tasks",
452
452
  "aria-label": "Highlight my tasks",
453
453
  "aria-pressed": v,
454
- className: I(v && "text-interactive"),
454
+ className: N(v && "text-interactive"),
455
455
  children: /* @__PURE__ */ e(q, { className: "h-ico-sm w-ico-sm" })
456
456
  }
457
457
  ),
458
458
  /* @__PURE__ */ e(
459
- ut,
459
+ ht,
460
460
  {
461
461
  size: "sm",
462
462
  variant: "tonal",
@@ -466,14 +466,14 @@ function Oe() {
466
466
  }
467
467
  )
468
468
  ] }),
469
- C.length > 0 && /* @__PURE__ */ a("div", { className: "flex items-center gap-ds-02 flex-wrap", children: [
470
- C.map((i, f) => /* @__PURE__ */ e(
469
+ y.length > 0 && /* @__PURE__ */ a("div", { className: "flex items-center gap-ds-02 flex-wrap", children: [
470
+ y.map((i, p) => /* @__PURE__ */ e(
471
471
  "div",
472
472
  {
473
473
  className: "animate-scale-in delay-stagger",
474
- style: { "--stagger-index": f },
474
+ style: { "--stagger-index": p },
475
475
  children: /* @__PURE__ */ e(
476
- ct,
476
+ dt,
477
477
  {
478
478
  variant: "subtle",
479
479
  size: "sm",
@@ -496,22 +496,22 @@ function Oe() {
496
496
  ] })
497
497
  ] });
498
498
  }
499
- Oe.displayName = "BoardToolbar";
500
- const $t = ["LOW", "MEDIUM", "HIGH", "URGENT"];
501
- function Be() {
499
+ Be.displayName = "BoardToolbar";
500
+ const _t = ["LOW", "MEDIUM", "HIGH", "URGENT"];
501
+ function We() {
502
502
  const {
503
503
  rawColumns: s,
504
504
  columns: t,
505
505
  selectedTaskIds: n,
506
506
  clearSelection: r,
507
507
  onBulkAction: o
508
- } = U(), h = n.size, b = Array.from(n), v = de(s), d = (c, x) => {
509
- o({ type: c, taskIds: b, value: x }), r();
508
+ } = K(), h = n.size, b = Array.from(n), v = de(s), d = (l, x) => {
509
+ o({ type: l, taskIds: b, value: x }), r();
510
510
  };
511
511
  return /* @__PURE__ */ e(
512
512
  "div",
513
513
  {
514
- className: I(
514
+ className: N(
515
515
  "grid transition-[grid-template-rows,opacity] duration-moderate-02 ease-expressive-entrance",
516
516
  h > 0 ? "grid-rows-[1fr] opacity-100" : "grid-rows-[0fr] opacity-0"
517
517
  ),
@@ -523,7 +523,7 @@ function Be() {
523
523
  " selected"
524
524
  ] }),
525
525
  /* @__PURE__ */ e(
526
- O,
526
+ $,
527
527
  {
528
528
  variant: "ghost",
529
529
  size: "icon-md",
@@ -536,74 +536,74 @@ function Be() {
536
536
  )
537
537
  ] }),
538
538
  /* @__PURE__ */ e("div", { className: "h-4 w-px bg-border-subtle" }),
539
- /* @__PURE__ */ e("div", { className: "animate-fade-in delay-stagger", style: { "--stagger-index": 0 }, children: /* @__PURE__ */ a(z, { children: [
540
- /* @__PURE__ */ e(V, { asChild: !0, children: /* @__PURE__ */ a(O, { variant: "ghost", size: "sm", title: "Move to column", tabIndex: h > 0 ? 0 : -1, children: [
541
- /* @__PURE__ */ e(fe, { className: "h-ico-sm w-ico-sm mr-ds-01" }),
539
+ /* @__PURE__ */ e("div", { className: "animate-fade-in delay-stagger", style: { "--stagger-index": 0 }, children: /* @__PURE__ */ a(V, { children: [
540
+ /* @__PURE__ */ e(U, { asChild: !0, children: /* @__PURE__ */ a($, { variant: "ghost", size: "sm", title: "Move to column", tabIndex: h > 0 ? 0 : -1, children: [
541
+ /* @__PURE__ */ e(pe, { className: "h-ico-sm w-ico-sm mr-ds-01" }),
542
542
  "Move"
543
543
  ] }) }),
544
- /* @__PURE__ */ a(F, { align: "start", className: "w-44", children: [
545
- /* @__PURE__ */ e(Q, { children: "Move to" }),
546
- /* @__PURE__ */ e(G, {}),
547
- t.map((c) => /* @__PURE__ */ e(
548
- $,
544
+ /* @__PURE__ */ a(G, { align: "start", className: "w-44", children: [
545
+ /* @__PURE__ */ e(Y, { children: "Move to" }),
546
+ /* @__PURE__ */ e(H, {}),
547
+ t.map((l) => /* @__PURE__ */ e(
548
+ F,
549
549
  {
550
- onClick: () => d("move", c.id),
551
- children: c.name
550
+ onClick: () => d("move", l.id),
551
+ children: l.name
552
552
  },
553
- c.id
553
+ l.id
554
554
  ))
555
555
  ] })
556
556
  ] }) }),
557
- /* @__PURE__ */ e("div", { className: "animate-fade-in delay-stagger", style: { "--stagger-index": 1 }, children: /* @__PURE__ */ a(z, { children: [
558
- /* @__PURE__ */ e(V, { asChild: !0, children: /* @__PURE__ */ a(O, { variant: "ghost", size: "sm", title: "Set priority", tabIndex: h > 0 ? 0 : -1, children: [
557
+ /* @__PURE__ */ e("div", { className: "animate-fade-in delay-stagger", style: { "--stagger-index": 1 }, children: /* @__PURE__ */ a(V, { children: [
558
+ /* @__PURE__ */ e(U, { asChild: !0, children: /* @__PURE__ */ a($, { variant: "ghost", size: "sm", title: "Set priority", tabIndex: h > 0 ? 0 : -1, children: [
559
559
  /* @__PURE__ */ e(le, { className: "h-ico-sm w-ico-sm mr-ds-01" }),
560
560
  "Priority"
561
561
  ] }) }),
562
- /* @__PURE__ */ a(F, { align: "start", className: "w-40", children: [
563
- /* @__PURE__ */ e(Q, { children: "Set priority" }),
564
- /* @__PURE__ */ e(G, {}),
565
- $t.map((c) => /* @__PURE__ */ e(
566
- $,
562
+ /* @__PURE__ */ a(G, { align: "start", className: "w-40", children: [
563
+ /* @__PURE__ */ e(Y, { children: "Set priority" }),
564
+ /* @__PURE__ */ e(H, {}),
565
+ _t.map((l) => /* @__PURE__ */ e(
566
+ F,
567
567
  {
568
- onClick: () => d("priority", c),
569
- className: ce[c],
570
- children: c.charAt(0) + c.slice(1).toLowerCase()
568
+ onClick: () => d("priority", l),
569
+ className: ce[l],
570
+ children: l.charAt(0) + l.slice(1).toLowerCase()
571
571
  },
572
- c
572
+ l
573
573
  ))
574
574
  ] })
575
575
  ] }) }),
576
- v.length > 0 && /* @__PURE__ */ e("div", { className: "animate-fade-in delay-stagger", style: { "--stagger-index": 2 }, children: /* @__PURE__ */ a(z, { children: [
577
- /* @__PURE__ */ e(V, { asChild: !0, children: /* @__PURE__ */ a(O, { variant: "ghost", size: "sm", title: "Assign", tabIndex: h > 0 ? 0 : -1, children: [
576
+ v.length > 0 && /* @__PURE__ */ e("div", { className: "animate-fade-in delay-stagger", style: { "--stagger-index": 2 }, children: /* @__PURE__ */ a(V, { children: [
577
+ /* @__PURE__ */ e(U, { asChild: !0, children: /* @__PURE__ */ a($, { variant: "ghost", size: "sm", title: "Assign", tabIndex: h > 0 ? 0 : -1, children: [
578
578
  /* @__PURE__ */ e(q, { className: "h-ico-sm w-ico-sm mr-ds-01" }),
579
579
  "Assign"
580
580
  ] }) }),
581
- /* @__PURE__ */ a(F, { align: "start", className: "w-44 max-h-48 overflow-y-auto", children: [
582
- /* @__PURE__ */ e(Q, { children: "Assign to" }),
583
- /* @__PURE__ */ e(G, {}),
584
- v.map((c) => /* @__PURE__ */ e(
585
- $,
581
+ /* @__PURE__ */ a(G, { align: "start", className: "w-44 max-h-48 overflow-y-auto", children: [
582
+ /* @__PURE__ */ e(Y, { children: "Assign to" }),
583
+ /* @__PURE__ */ e(H, {}),
584
+ v.map((l) => /* @__PURE__ */ e(
585
+ F,
586
586
  {
587
- onClick: () => d("assign", c.id),
588
- children: c.name
587
+ onClick: () => d("assign", l.id),
588
+ children: l.name
589
589
  },
590
- c.id
590
+ l.id
591
591
  ))
592
592
  ] })
593
593
  ] }) }),
594
- /* @__PURE__ */ e("div", { className: "animate-fade-in delay-stagger", style: { "--stagger-index": 3 }, children: /* @__PURE__ */ a(z, { children: [
595
- /* @__PURE__ */ e(V, { asChild: !0, children: /* @__PURE__ */ a(O, { variant: "ghost", size: "sm", title: "Set visibility", tabIndex: h > 0 ? 0 : -1, children: [
594
+ /* @__PURE__ */ e("div", { className: "animate-fade-in delay-stagger", style: { "--stagger-index": 3 }, children: /* @__PURE__ */ a(V, { children: [
595
+ /* @__PURE__ */ e(U, { asChild: !0, children: /* @__PURE__ */ a($, { variant: "ghost", size: "sm", title: "Set visibility", tabIndex: h > 0 ? 0 : -1, children: [
596
596
  /* @__PURE__ */ e(X, { className: "h-ico-sm w-ico-sm mr-ds-01" }),
597
597
  "Visibility"
598
598
  ] }) }),
599
- /* @__PURE__ */ a(F, { align: "start", className: "w-40", children: [
600
- /* @__PURE__ */ e($, { onClick: () => d("visibility", "INTERNAL"), children: "Internal only" }),
601
- /* @__PURE__ */ e($, { onClick: () => d("visibility", "EVERYONE"), children: "Visible to all" })
599
+ /* @__PURE__ */ a(G, { align: "start", className: "w-40", children: [
600
+ /* @__PURE__ */ e(F, { onClick: () => d("visibility", "INTERNAL"), children: "Internal only" }),
601
+ /* @__PURE__ */ e(F, { onClick: () => d("visibility", "EVERYONE"), children: "Visible to all" })
602
602
  ] })
603
603
  ] }) }),
604
604
  /* @__PURE__ */ e("div", { className: "flex-1" }),
605
605
  /* @__PURE__ */ e("div", { className: "animate-fade-in delay-stagger", style: { "--stagger-index": 4 }, children: /* @__PURE__ */ a(
606
- O,
606
+ $,
607
607
  {
608
608
  variant: "ghost",
609
609
  size: "sm",
@@ -612,7 +612,7 @@ function Be() {
612
612
  title: "Delete selected tasks",
613
613
  tabIndex: h > 0 ? 0 : -1,
614
614
  children: [
615
- /* @__PURE__ */ e(pe, { className: "h-ico-sm w-ico-sm mr-ds-01" }),
615
+ /* @__PURE__ */ e(xe, { className: "h-ico-sm w-ico-sm mr-ds-01" }),
616
616
  "Delete"
617
617
  ]
618
618
  }
@@ -621,8 +621,8 @@ function Be() {
621
621
  }
622
622
  );
623
623
  }
624
- Be.displayName = "BulkActionBar";
625
- function _t(s) {
624
+ We.displayName = "BulkActionBar";
625
+ function zt(s) {
626
626
  const t = /* @__PURE__ */ new Set(), n = [];
627
627
  for (const r of s.tasks) {
628
628
  r.owner && !t.has(r.owner.id) && (t.add(r.owner.id), n.push(r.owner));
@@ -631,14 +631,14 @@ function _t(s) {
631
631
  }
632
632
  return n;
633
633
  }
634
- function zt({ columnId: s, currentLimit: t, onClose: n }) {
635
- const { onColumnWipLimitChange: r } = U(), [o, h] = A(t != null ? String(t) : ""), b = E(() => {
634
+ function Ft({ columnId: s, currentLimit: t, onClose: n }) {
635
+ const { onColumnWipLimitChange: r } = K(), [o, h] = O(t != null ? String(t) : ""), b = B(() => {
636
636
  const d = o.trim();
637
637
  if (d === "")
638
638
  r(s, null);
639
639
  else {
640
- const c = parseInt(d, 10);
641
- !isNaN(c) && c > 0 && r(s, c);
640
+ const l = parseInt(d, 10);
641
+ !isNaN(l) && l > 0 && r(s, l);
642
642
  }
643
643
  n();
644
644
  }, [o, s, r, n]);
@@ -665,33 +665,33 @@ function zt({ columnId: s, currentLimit: t, onClose: n }) {
665
665
  );
666
666
  }
667
667
  function Pe({ column: s, index: t }) {
668
- var W;
668
+ var _;
669
669
  const {
670
670
  rawColumns: n,
671
671
  onColumnRename: r,
672
672
  onColumnDelete: o,
673
673
  onColumnToggleVisibility: h,
674
674
  onTaskAdd: b
675
- } = U(), [v, d] = A(!1), [c, x] = A(s.name), [T, y] = A(!1), [g, S] = A(!1), [u, k] = A(""), [l, p] = A(null), [m, C] = A(""), i = ae(null), f = de(n), D = ve[t % ve.length], M = s.tasks.length, N = s.wipLimit ?? null, R = N != null && M > N, B = _t(s), _ = () => {
675
+ } = K(), [v, d] = O(!1), [l, x] = O(s.name), [D, g] = O(!1), [f, A] = O(!1), [c, k] = O(""), [u, I] = O(null), [m, y] = O(""), i = ae(null), p = de(n), S = we[t % we.length], M = s.tasks.length, L = s.wipLimit ?? null, E = L != null && M > L, T = zt(s), R = () => {
676
676
  x(s.name), d(!0);
677
- }, P = () => {
678
- const w = c.trim();
677
+ }, C = () => {
678
+ const w = l.trim();
679
679
  w && w !== s.name && r(s.id, w), d(!1);
680
- }, Y = (w) => {
681
- w.key === "Enter" && P(), w.key === "Escape" && (x(s.name), d(!1));
682
- }, K = () => {
683
- k(""), p(null), C(""), S(!1);
680
+ }, W = (w) => {
681
+ w.key === "Enter" && C(), w.key === "Escape" && (x(s.name), d(!1));
682
+ }, z = () => {
683
+ k(""), I(null), y(""), A(!1);
684
684
  }, J = () => {
685
- const w = u.trim();
685
+ const w = c.trim();
686
686
  w && (b(s.id, {
687
687
  title: w,
688
- ownerId: l,
688
+ ownerId: u,
689
689
  dueDate: m || null
690
- }), K());
691
- }, me = (w) => {
692
- w.key === "Enter" && J(), w.key === "Escape" && K();
693
- }, ue = () => {
694
- g ? K() : (S(!0), setTimeout(() => {
690
+ }), z());
691
+ }, ue = (w) => {
692
+ w.key === "Enter" && J(), w.key === "Escape" && z();
693
+ }, me = () => {
694
+ f ? z() : (A(!0), setTimeout(() => {
695
695
  var w;
696
696
  return (w = i.current) == null ? void 0 : w.focus();
697
697
  }, 50));
@@ -701,7 +701,7 @@ function Pe({ column: s, index: t }) {
701
701
  /* @__PURE__ */ e(
702
702
  "span",
703
703
  {
704
- className: I("h-2.5 w-2.5 flex-shrink-0 rounded-full", D),
704
+ className: N("h-2.5 w-2.5 flex-shrink-0 rounded-full", S),
705
705
  "aria-hidden": "true",
706
706
  title: s.name
707
707
  }
@@ -711,10 +711,10 @@ function Pe({ column: s, index: t }) {
711
711
  /* @__PURE__ */ e(
712
712
  re,
713
713
  {
714
- value: c,
714
+ value: l,
715
715
  onChange: (w) => x(w.target.value),
716
- onBlur: P,
717
- onKeyDown: Y,
716
+ onBlur: C,
717
+ onKeyDown: W,
718
718
  "aria-label": "Column name",
719
719
  size: "sm",
720
720
  className: "h-ds-xs flex-1 text-ds-sm font-semibold",
@@ -725,9 +725,9 @@ function Pe({ column: s, index: t }) {
725
725
  "h3",
726
726
  {
727
727
  className: "flex-1 truncate text-ds-sm font-semibold text-text-primary",
728
- onDoubleClick: _,
728
+ onDoubleClick: R,
729
729
  title: s.name,
730
- "aria-label": N != null ? `${s.name}, ${M} of ${N} tasks${R ? ", WIP limit exceeded" : ""}` : `${s.name}, ${M} tasks`,
730
+ "aria-label": L != null ? `${s.name}, ${M} of ${L} tasks${E ? ", WIP limit exceeded" : ""}` : `${s.name}, ${M} tasks`,
731
731
  children: [
732
732
  s.name,
733
733
  /* @__PURE__ */ a("span", { className: "ml-ds-02 text-ds-xs font-normal text-text-tertiary", children: [
@@ -738,73 +738,73 @@ function Pe({ column: s, index: t }) {
738
738
  ]
739
739
  }
740
740
  ),
741
- T ? /* @__PURE__ */ e(
742
- zt,
741
+ D ? /* @__PURE__ */ e(
742
+ Ft,
743
743
  {
744
744
  columnId: s.id,
745
- currentLimit: N,
746
- onClose: () => y(!1)
745
+ currentLimit: L,
746
+ onClose: () => g(!1)
747
747
  }
748
- ) : N != null ? /* @__PURE__ */ a(
748
+ ) : L != null ? /* @__PURE__ */ a(
749
749
  "span",
750
750
  {
751
- className: I(
751
+ className: N(
752
752
  "flex-shrink-0 text-ds-xs tabular-nums",
753
- R ? "font-semibold text-error" : "text-text-tertiary"
753
+ E ? "font-semibold text-error" : "text-text-tertiary"
754
754
  ),
755
- "aria-label": `WIP limit: ${N}${R ? ", exceeded" : ""}`,
755
+ "aria-label": `WIP limit: ${L}${E ? ", exceeded" : ""}`,
756
756
  children: [
757
757
  "/ ",
758
- N
758
+ L
759
759
  ]
760
760
  }
761
761
  ) : null,
762
762
  /* @__PURE__ */ e(
763
- O,
763
+ $,
764
764
  {
765
765
  variant: "ghost",
766
766
  size: "icon-md",
767
- className: I(
767
+ className: N(
768
768
  "h-ds-xs w-ds-xs flex-shrink-0 opacity-0 transition-opacity",
769
769
  "group-hover/header:opacity-100 focus:opacity-100",
770
770
  "hover:bg-interactive-subtle hover:text-interactive"
771
771
  ),
772
772
  "aria-label": "Add task",
773
773
  title: "Add task",
774
- onClick: ue,
775
- children: /* @__PURE__ */ e(xe, { className: "h-ico-sm w-ico-sm" })
774
+ onClick: me,
775
+ children: /* @__PURE__ */ e(ye, { className: "h-ico-sm w-ico-sm" })
776
776
  }
777
777
  ),
778
- /* @__PURE__ */ a(z, { children: [
779
- /* @__PURE__ */ e(V, { asChild: !0, children: /* @__PURE__ */ e(
780
- O,
778
+ /* @__PURE__ */ a(V, { children: [
779
+ /* @__PURE__ */ e(U, { asChild: !0, children: /* @__PURE__ */ e(
780
+ $,
781
781
  {
782
782
  variant: "ghost",
783
783
  size: "icon-md",
784
- className: I(
784
+ className: N(
785
785
  "h-ds-xs w-ds-xs flex-shrink-0 opacity-0 transition-opacity",
786
786
  "group-hover/header:opacity-100 focus:opacity-100"
787
787
  ),
788
788
  "aria-label": "Column options",
789
789
  title: "Column options",
790
- children: /* @__PURE__ */ e(xt, { className: "h-ico-sm w-ico-sm" })
790
+ children: /* @__PURE__ */ e(yt, { className: "h-ico-sm w-ico-sm" })
791
791
  }
792
792
  ) }),
793
- /* @__PURE__ */ a(F, { align: "end", className: "w-48", children: [
794
- /* @__PURE__ */ a($, { onClick: _, children: [
795
- /* @__PURE__ */ e(yt, { className: "mr-ds-03 h-ico-sm w-ico-sm" }),
793
+ /* @__PURE__ */ a(G, { align: "end", className: "w-48", children: [
794
+ /* @__PURE__ */ a(F, { onClick: R, children: [
795
+ /* @__PURE__ */ e(vt, { className: "mr-ds-03 h-ico-sm w-ico-sm" }),
796
796
  "Rename"
797
797
  ] }),
798
- /* @__PURE__ */ a($, { onClick: () => y(!0), children: [
799
- /* @__PURE__ */ e(vt, { className: "mr-ds-03 h-ico-sm w-ico-sm" }),
798
+ /* @__PURE__ */ a(F, { onClick: () => g(!0), children: [
799
+ /* @__PURE__ */ e(wt, { className: "mr-ds-03 h-ico-sm w-ico-sm" }),
800
800
  "Set WIP Limit"
801
801
  ] }),
802
802
  /* @__PURE__ */ e(
803
- $,
803
+ F,
804
804
  {
805
805
  onClick: () => h(s.id, !(s.isClientVisible ?? !1)),
806
806
  children: s.isClientVisible ? /* @__PURE__ */ a(se, { children: [
807
- /* @__PURE__ */ e(Te, { className: "mr-ds-03 h-ico-sm w-ico-sm" }),
807
+ /* @__PURE__ */ e(Re, { className: "mr-ds-03 h-ico-sm w-ico-sm" }),
808
808
  "Hide from client"
809
809
  ] }) : /* @__PURE__ */ a(se, { children: [
810
810
  /* @__PURE__ */ e(X, { className: "mr-ds-03 h-ico-sm w-ico-sm" }),
@@ -812,14 +812,14 @@ function Pe({ column: s, index: t }) {
812
812
  ] })
813
813
  }
814
814
  ),
815
- /* @__PURE__ */ e(G, {}),
815
+ /* @__PURE__ */ e(H, {}),
816
816
  /* @__PURE__ */ a(
817
- $,
817
+ F,
818
818
  {
819
819
  className: "text-error focus:text-error",
820
820
  onClick: () => o(s.id),
821
821
  children: [
822
- /* @__PURE__ */ e(pe, { className: "mr-ds-03 h-ico-sm w-ico-sm" }),
822
+ /* @__PURE__ */ e(xe, { className: "mr-ds-03 h-ico-sm w-ico-sm" }),
823
823
  "Delete column"
824
824
  ]
825
825
  }
@@ -827,10 +827,10 @@ function Pe({ column: s, index: t }) {
827
827
  ] })
828
828
  ] })
829
829
  ] }),
830
- B.length > 0 && /* @__PURE__ */ e("div", { className: "px-ds-04 pb-ds-02", children: /* @__PURE__ */ e(
831
- It,
830
+ T.length > 0 && /* @__PURE__ */ e("div", { className: "px-ds-04 pb-ds-02", children: /* @__PURE__ */ e(
831
+ Dt,
832
832
  {
833
- users: B,
833
+ users: T,
834
834
  max: 3,
835
835
  size: "sm",
836
836
  showTooltip: !0
@@ -839,54 +839,54 @@ function Pe({ column: s, index: t }) {
839
839
  /* @__PURE__ */ e(
840
840
  "div",
841
841
  {
842
- className: I(
842
+ className: N(
843
843
  "grid transition-[grid-template-rows,opacity] duration-moderate-02 ease-expressive-entrance",
844
- g ? "grid-rows-[1fr] opacity-100" : "grid-rows-[0fr] opacity-0"
844
+ f ? "grid-rows-[1fr] opacity-100" : "grid-rows-[0fr] opacity-0"
845
845
  ),
846
846
  children: /* @__PURE__ */ e("div", { className: "overflow-hidden", children: /* @__PURE__ */ a("div", { className: "px-ds-04 pb-ds-03 flex flex-col gap-ds-02", children: [
847
847
  /* @__PURE__ */ e(
848
848
  re,
849
849
  {
850
850
  ref: i,
851
- value: u,
851
+ value: c,
852
852
  onChange: (w) => k(w.target.value),
853
- onKeyDown: me,
853
+ onKeyDown: ue,
854
854
  placeholder: "Task title...",
855
855
  "aria-label": "New task title",
856
856
  size: "sm",
857
- tabIndex: g ? 0 : -1,
858
- autoFocus: g
857
+ tabIndex: f ? 0 : -1,
858
+ autoFocus: f
859
859
  }
860
860
  ),
861
861
  /* @__PURE__ */ a("div", { className: "flex items-center gap-ds-01", children: [
862
- /* @__PURE__ */ a(z, { children: [
863
- /* @__PURE__ */ e(V, { asChild: !0, children: /* @__PURE__ */ e(
862
+ /* @__PURE__ */ a(V, { children: [
863
+ /* @__PURE__ */ e(U, { asChild: !0, children: /* @__PURE__ */ e(
864
864
  "button",
865
865
  {
866
- className: I(
866
+ className: N(
867
867
  "flex items-center justify-center h-6 w-6 rounded-ds-md transition-colors",
868
- l ? "text-interactive bg-interactive-subtle" : "text-text-tertiary hover:text-text-primary hover:bg-layer-active"
868
+ u ? "text-interactive bg-interactive-subtle" : "text-text-tertiary hover:text-text-primary hover:bg-layer-active"
869
869
  ),
870
- title: l ? `Lead: ${(W = f.find((w) => w.id === l)) == null ? void 0 : W.name}` : "Assign task lead",
870
+ title: u ? `Lead: ${(_ = p.find((w) => w.id === u)) == null ? void 0 : _.name}` : "Assign task lead",
871
871
  "aria-label": "Assign task lead",
872
- tabIndex: g ? 0 : -1,
872
+ tabIndex: f ? 0 : -1,
873
873
  children: /* @__PURE__ */ e(q, { className: "h-3.5 w-3.5" })
874
874
  }
875
875
  ) }),
876
- /* @__PURE__ */ a(F, { align: "start", className: "w-44 max-h-48 overflow-y-auto", children: [
877
- f.length === 0 && /* @__PURE__ */ e("div", { className: "px-ds-03 py-ds-02 text-ds-xs text-text-tertiary", children: "No members found" }),
878
- l && /* @__PURE__ */ a(se, { children: [
879
- /* @__PURE__ */ a($, { onClick: () => p(null), children: [
876
+ /* @__PURE__ */ a(G, { align: "start", className: "w-44 max-h-48 overflow-y-auto", children: [
877
+ p.length === 0 && /* @__PURE__ */ e("div", { className: "px-ds-03 py-ds-02 text-ds-xs text-text-tertiary", children: "No members found" }),
878
+ u && /* @__PURE__ */ a(se, { children: [
879
+ /* @__PURE__ */ a(F, { onClick: () => I(null), children: [
880
880
  /* @__PURE__ */ e(ie, { className: "mr-ds-02 h-3 w-3 text-text-tertiary" }),
881
881
  "Clear lead"
882
882
  ] }),
883
- /* @__PURE__ */ e(G, {})
883
+ /* @__PURE__ */ e(H, {})
884
884
  ] }),
885
- f.map((w) => /* @__PURE__ */ e(
886
- $,
885
+ p.map((w) => /* @__PURE__ */ e(
886
+ F,
887
887
  {
888
- onClick: () => p(w.id),
889
- className: I(l === w.id && "bg-interactive-subtle"),
888
+ onClick: () => I(w.id),
889
+ className: N(u === w.id && "bg-interactive-subtle"),
890
890
  children: w.name
891
891
  },
892
892
  w.id
@@ -896,23 +896,23 @@ function Pe({ column: s, index: t }) {
896
896
  /* @__PURE__ */ a(
897
897
  "label",
898
898
  {
899
- className: I(
899
+ className: N(
900
900
  "relative flex items-center justify-center h-6 w-6 rounded-ds-md cursor-pointer transition-colors",
901
901
  m ? "text-interactive bg-interactive-subtle" : "text-text-tertiary hover:text-text-primary hover:bg-layer-active"
902
902
  ),
903
903
  title: m ? `Due: ${m}` : "Set due date",
904
904
  "aria-label": "Set due date",
905
905
  children: [
906
- /* @__PURE__ */ e(ye, { className: "h-3.5 w-3.5" }),
906
+ /* @__PURE__ */ e(ve, { className: "h-3.5 w-3.5" }),
907
907
  /* @__PURE__ */ e(
908
908
  "input",
909
909
  {
910
910
  type: "date",
911
911
  value: m,
912
- onChange: (w) => C(w.target.value),
912
+ onChange: (w) => y(w.target.value),
913
913
  className: "absolute inset-0 opacity-0 cursor-pointer w-full h-full",
914
914
  "aria-label": "Due date",
915
- tabIndex: g ? 0 : -1
915
+ tabIndex: f ? 0 : -1
916
916
  }
917
917
  )
918
918
  ]
@@ -923,25 +923,25 @@ function Pe({ column: s, index: t }) {
923
923
  "button",
924
924
  {
925
925
  onClick: J,
926
- disabled: !u.trim(),
927
- className: I(
926
+ disabled: !c.trim(),
927
+ className: N(
928
928
  "flex items-center justify-center h-6 w-6 rounded-ds-md transition-colors",
929
- u.trim() ? "text-success hover:bg-success-surface" : "text-text-quaternary cursor-not-allowed"
929
+ c.trim() ? "text-success hover:bg-success-surface" : "text-text-quaternary cursor-not-allowed"
930
930
  ),
931
931
  title: "Confirm add task",
932
932
  "aria-label": "Confirm add task",
933
- tabIndex: g ? 0 : -1,
934
- children: /* @__PURE__ */ e(wt, { className: "h-3.5 w-3.5" })
933
+ tabIndex: f ? 0 : -1,
934
+ children: /* @__PURE__ */ e(bt, { className: "h-3.5 w-3.5" })
935
935
  }
936
936
  ),
937
937
  /* @__PURE__ */ e(
938
938
  "button",
939
939
  {
940
- onClick: K,
940
+ onClick: z,
941
941
  className: "flex items-center justify-center h-6 w-6 rounded-ds-md text-text-tertiary hover:text-text-primary hover:bg-layer-active transition-colors",
942
942
  title: "Cancel",
943
943
  "aria-label": "Cancel adding task",
944
- tabIndex: g ? 0 : -1,
944
+ tabIndex: f ? 0 : -1,
945
945
  children: /* @__PURE__ */ e(ie, { className: "h-3.5 w-3.5" })
946
946
  }
947
947
  )
@@ -972,7 +972,7 @@ function Vt() {
972
972
  }
973
973
  );
974
974
  }
975
- function Ft() {
975
+ function Ut() {
976
976
  return /* @__PURE__ */ a(
977
977
  "svg",
978
978
  {
@@ -991,7 +991,7 @@ function Ft() {
991
991
  }
992
992
  );
993
993
  }
994
- function Ut() {
994
+ function Gt() {
995
995
  return /* @__PURE__ */ a(
996
996
  "svg",
997
997
  {
@@ -1053,18 +1053,18 @@ function Kt() {
1053
1053
  }
1054
1054
  );
1055
1055
  }
1056
- const ke = [
1056
+ const Ce = [
1057
1057
  Vt,
1058
- Ft,
1059
1058
  Ut,
1059
+ Gt,
1060
1060
  Kt
1061
1061
  ];
1062
- function We({ index: s, onAddTask: t, isDropTarget: n = !1, className: r }) {
1063
- const o = ke[s % ke.length];
1062
+ function $e({ index: s, onAddTask: t, isDropTarget: n = !1, className: r }) {
1063
+ const o = Ce[s % Ce.length];
1064
1064
  return /* @__PURE__ */ a(
1065
1065
  "div",
1066
1066
  {
1067
- className: I(
1067
+ className: N(
1068
1068
  "flex flex-col items-center justify-center gap-ds-03 py-ds-07 text-center",
1069
1069
  r
1070
1070
  ),
@@ -1073,13 +1073,13 @@ function We({ index: s, onAddTask: t, isDropTarget: n = !1, className: r }) {
1073
1073
  n ? /* @__PURE__ */ e("p", { className: "text-ds-sm text-text-tertiary", children: "Drop tasks here" }) : /* @__PURE__ */ a(se, { children: [
1074
1074
  /* @__PURE__ */ e("p", { className: "text-ds-sm text-text-tertiary", children: "No tasks yet" }),
1075
1075
  /* @__PURE__ */ a(
1076
- O,
1076
+ $,
1077
1077
  {
1078
1078
  variant: "ghost",
1079
1079
  size: "sm",
1080
1080
  onClick: t,
1081
1081
  children: [
1082
- /* @__PURE__ */ e(xe, { className: "h-ico-sm w-ico-sm" }),
1082
+ /* @__PURE__ */ e(ye, { className: "h-ico-sm w-ico-sm" }),
1083
1083
  "Add a task"
1084
1084
  ]
1085
1085
  }
@@ -1089,20 +1089,20 @@ function We({ index: s, onAddTask: t, isDropTarget: n = !1, className: r }) {
1089
1089
  }
1090
1090
  );
1091
1091
  }
1092
- We.displayName = "ColumnEmpty";
1093
- function Gt(s) {
1092
+ $e.displayName = "ColumnEmpty";
1093
+ function Ht(s) {
1094
1094
  const t = new Date(s), n = /* @__PURE__ */ new Date(), r = t.getTime() - n.getTime(), o = Math.ceil(r / (1e3 * 60 * 60 * 24));
1095
1095
  return o < 0 ? { label: "Overdue", className: "text-error" } : o === 0 ? { label: "Today", className: "text-warning" } : o === 1 ? { label: "Tomorrow", className: "text-warning" } : {
1096
1096
  label: t.toLocaleDateString("en-IN", { month: "short", day: "numeric" }),
1097
1097
  className: "text-text-tertiary"
1098
1098
  };
1099
1099
  }
1100
- const $e = {
1101
- LOW: Se,
1102
- MEDIUM: fe,
1103
- HIGH: Re,
1100
+ const _e = {
1101
+ LOW: Ae,
1102
+ MEDIUM: pe,
1103
+ HIGH: Se,
1104
1104
  URGENT: le
1105
- }, Ht = Ie(
1105
+ }, Qt = De(
1106
1106
  "group/card relative rounded-ds-lg border border-transparent bg-layer-01 pl-3 pr-ds-03 py-ds-03 transition-all duration-fast-02 ease-productive-standard cursor-pointer",
1107
1107
  {
1108
1108
  variants: {
@@ -1132,30 +1132,30 @@ const $e = {
1132
1132
  }
1133
1133
  }
1134
1134
  );
1135
- function _e(s) {
1135
+ function ze(s) {
1136
1136
  const t = s.trim();
1137
1137
  if (!t) return "";
1138
1138
  const n = t.split(/\s+/);
1139
1139
  return n.length >= 2 ? (n[0][0] + n[1][0]).toUpperCase() : t.slice(0, 2).toUpperCase();
1140
1140
  }
1141
- function ze({
1141
+ function Fe({
1142
1142
  task: s,
1143
1143
  isDragging: t,
1144
1144
  isDragOverlay: n,
1145
1145
  dragHandleProps: r
1146
1146
  }) {
1147
- var p;
1147
+ var I;
1148
1148
  const {
1149
1149
  selectedTaskIds: o,
1150
1150
  toggleTaskSelection: h,
1151
1151
  focusedTaskId: b,
1152
1152
  currentUserId: v,
1153
1153
  highlightMyTasks: d,
1154
- onClickTask: c
1155
- } = U(), x = o.has(s.id), T = o.size > 0, y = b === s.id, g = s.dueDate ? Gt(s.dueDate) : null, S = $e[s.priority], u = ce[s.priority], k = d && v != null && ((p = s.owner) == null ? void 0 : p.id) !== v && !s.assignees.some((m) => m.id === v), l = [];
1156
- s.owner && l.push({ name: s.owner.name, image: s.owner.image, isOwner: !0 });
1154
+ onClickTask: l
1155
+ } = K(), x = o.has(s.id), D = o.size > 0, g = b === s.id, f = s.dueDate ? Ht(s.dueDate) : null, A = _e[s.priority], c = ce[s.priority], k = d && v != null && ((I = s.owner) == null ? void 0 : I.id) !== v && !s.assignees.some((m) => m.id === v), u = [];
1156
+ s.owner && u.push({ name: s.owner.name, image: s.owner.image, isOwner: !0 });
1157
1157
  for (const m of s.assignees)
1158
- s.owner && m.id === s.owner.id || l.push({ name: m.name, image: m.image, isOwner: !1 });
1158
+ s.owner && m.id === s.owner.id || u.push({ name: m.name, image: m.image, isOwner: !1 });
1159
1159
  return /* @__PURE__ */ a(
1160
1160
  "div",
1161
1161
  {
@@ -1163,8 +1163,8 @@ function ze({
1163
1163
  tabIndex: 0,
1164
1164
  "data-task-id": s.id,
1165
1165
  "aria-label": `Task ${s.taskId}: ${s.title}`,
1166
- className: I(
1167
- Ht({
1166
+ className: N(
1167
+ Qt({
1168
1168
  state: n ? "overlay" : t ? "dragging" : "default",
1169
1169
  blocked: s.isBlocked,
1170
1170
  selected: x,
@@ -1172,22 +1172,22 @@ function ze({
1172
1172
  }),
1173
1173
  n && "scale-[1.03] rotate-[1.5deg] shadow-03",
1174
1174
  t && "opacity-40",
1175
- y && "ring-1 ring-focus"
1175
+ g && "ring-1 ring-focus"
1176
1176
  ),
1177
- onClick: () => c(s.id),
1177
+ onClick: () => l(s.id),
1178
1178
  onKeyDown: (m) => {
1179
- (m.key === "Enter" || m.key === " ") && (m.preventDefault(), c(s.id));
1179
+ (m.key === "Enter" || m.key === " ") && (m.preventDefault(), l(s.id));
1180
1180
  },
1181
1181
  children: [
1182
1182
  /* @__PURE__ */ e(
1183
1183
  "div",
1184
1184
  {
1185
- className: I(
1185
+ className: N(
1186
1186
  "absolute -top-2 -left-2 z-10 transition-opacity",
1187
- T || x ? "opacity-100 animate-scale-bounce" : "opacity-0 group-hover/card:opacity-100"
1187
+ D || x ? "opacity-100 animate-scale-bounce" : "opacity-0 group-hover/card:opacity-100"
1188
1188
  ),
1189
1189
  children: /* @__PURE__ */ e(
1190
- Me,
1190
+ Le,
1191
1191
  {
1192
1192
  checked: x,
1193
1193
  onCheckedChange: () => h(s.id),
@@ -1200,12 +1200,12 @@ function ze({
1200
1200
  ),
1201
1201
  /* @__PURE__ */ a("div", { className: "flex items-center gap-ds-02", children: [
1202
1202
  /* @__PURE__ */ e("span", { className: "text-ds-xs font-mono leading-none text-text-tertiary", children: s.taskId }),
1203
- /* @__PURE__ */ e(S, { className: I("h-3 w-3 flex-shrink-0", u), title: `Priority: ${s.priority}` }),
1203
+ /* @__PURE__ */ e(A, { className: N("h-3 w-3 flex-shrink-0", c), title: `Priority: ${s.priority}` }),
1204
1204
  /* @__PURE__ */ e("div", { className: "flex-1" }),
1205
1205
  /* @__PURE__ */ e(
1206
1206
  "button",
1207
1207
  {
1208
- className: I(
1208
+ className: N(
1209
1209
  "flex-shrink-0 cursor-grab rounded p-ds-01 opacity-0 transition-opacity",
1210
1210
  "group-hover/card:opacity-[0.38] hover:!opacity-100",
1211
1211
  "active:cursor-grabbing",
@@ -1216,23 +1216,23 @@ function ze({
1216
1216
  "aria-label": `Drag handle for task: ${s.title}`,
1217
1217
  "aria-roledescription": "sortable",
1218
1218
  onClick: (m) => m.stopPropagation(),
1219
- children: /* @__PURE__ */ e(bt, { className: "h-ico-sm w-ico-sm text-icon-secondary" })
1219
+ children: /* @__PURE__ */ e(kt, { className: "h-ico-sm w-ico-sm text-icon-secondary" })
1220
1220
  }
1221
1221
  )
1222
1222
  ] }),
1223
1223
  /* @__PURE__ */ e("p", { className: "mt-ds-02 text-ds-sm font-medium text-text-primary line-clamp-2", children: s.title }),
1224
1224
  /* @__PURE__ */ a("div", { className: "mt-ds-03 flex items-center gap-ds-02", children: [
1225
- g && /* @__PURE__ */ a(
1225
+ f && /* @__PURE__ */ a(
1226
1226
  "div",
1227
1227
  {
1228
- className: I(
1228
+ className: N(
1229
1229
  "flex items-center gap-ds-01 text-ds-xs leading-tight",
1230
- g.className
1230
+ f.className
1231
1231
  ),
1232
- title: `Due: ${g.label}`,
1232
+ title: `Due: ${f.label}`,
1233
1233
  children: [
1234
- /* @__PURE__ */ e(ye, { className: "h-3 w-3" }),
1235
- /* @__PURE__ */ e("span", { children: g.label })
1234
+ /* @__PURE__ */ e(ve, { className: "h-3 w-3" }),
1235
+ /* @__PURE__ */ e("span", { children: f.label })
1236
1236
  ]
1237
1237
  }
1238
1238
  ),
@@ -1242,7 +1242,7 @@ function ze({
1242
1242
  className: "flex items-center gap-ds-01 text-ds-xs text-text-tertiary",
1243
1243
  title: `Subtasks: ${s.subtasksDone} of ${s.subtaskCount} done`,
1244
1244
  children: [
1245
- /* @__PURE__ */ e(kt, { className: "h-3 w-3" }),
1245
+ /* @__PURE__ */ e(Ct, { className: "h-3 w-3" }),
1246
1246
  /* @__PURE__ */ a("span", { children: [
1247
1247
  s.subtasksDone,
1248
1248
  "/",
@@ -1252,30 +1252,30 @@ function ze({
1252
1252
  }
1253
1253
  ),
1254
1254
  s.visibility === "EVERYONE" && /* @__PURE__ */ e("span", { className: "flex items-center text-text-tertiary", "aria-label": "Client visible", title: "Visible to client", children: /* @__PURE__ */ e(X, { className: "h-3 w-3" }) }),
1255
- s.isBlocked && /* @__PURE__ */ e("span", { className: "flex items-center text-error", "aria-label": "Blocked", title: "Blocked", children: /* @__PURE__ */ e(Ct, { className: "h-3 w-3" }) }),
1255
+ s.isBlocked && /* @__PURE__ */ e("span", { className: "flex items-center text-error", "aria-label": "Blocked", title: "Blocked", children: /* @__PURE__ */ e(Nt, { className: "h-3 w-3" }) }),
1256
1256
  /* @__PURE__ */ e("div", { className: "flex-1" }),
1257
- l.length > 0 && /* @__PURE__ */ a("div", { className: "flex items-center flex-shrink-0", children: [
1258
- l.slice(0, 3).map((m, C) => /* @__PURE__ */ a(
1259
- Dt,
1257
+ u.length > 0 && /* @__PURE__ */ a("div", { className: "flex items-center flex-shrink-0", children: [
1258
+ u.slice(0, 3).map((m, y) => /* @__PURE__ */ a(
1259
+ Tt,
1260
1260
  {
1261
1261
  size: "xs",
1262
- className: I(
1262
+ className: N(
1263
1263
  "text-ds-xs border-2 border-layer-01",
1264
- C > 0 && "-ml-ds-02b",
1264
+ y > 0 && "-ml-ds-02b",
1265
1265
  m.isOwner && "shadow-[0_0_0_1.5px_rgba(var(--accent-rgb,99,102,241),0.35),0_0_6px_rgba(var(--accent-rgb,99,102,241),0.2)]"
1266
1266
  ),
1267
- style: { zIndex: l.length - C },
1267
+ style: { zIndex: u.length - y },
1268
1268
  title: m.name,
1269
1269
  children: [
1270
- m.image && /* @__PURE__ */ e(Tt, { src: m.image, alt: m.name }),
1271
- /* @__PURE__ */ e(Rt, { className: "font-body font-semibold", children: _e(m.name) })
1270
+ m.image && /* @__PURE__ */ e(Rt, { src: m.image, alt: m.name }),
1271
+ /* @__PURE__ */ e(St, { className: "font-body font-semibold", children: ze(m.name) })
1272
1272
  ]
1273
1273
  },
1274
- C
1274
+ y
1275
1275
  )),
1276
- l.length > 3 && /* @__PURE__ */ a("span", { className: "ml-ds-01 text-ds-xs text-text-tertiary", children: [
1276
+ u.length > 3 && /* @__PURE__ */ a("span", { className: "ml-ds-01 text-ds-xs text-text-tertiary", children: [
1277
1277
  "+",
1278
- l.length - 3
1278
+ u.length - 3
1279
1279
  ] })
1280
1280
  ] })
1281
1281
  ] })
@@ -1283,7 +1283,7 @@ function ze({
1283
1283
  }
1284
1284
  );
1285
1285
  }
1286
- const Ve = j.forwardRef(
1286
+ const Ve = Q.forwardRef(
1287
1287
  function({ task: t }, n) {
1288
1288
  const {
1289
1289
  attributes: r,
@@ -1292,18 +1292,18 @@ const Ve = j.forwardRef(
1292
1292
  transform: b,
1293
1293
  transition: v,
1294
1294
  isDragging: d
1295
- } = Ce({
1295
+ } = Ne({
1296
1296
  id: t.id,
1297
1297
  data: {
1298
1298
  type: "task",
1299
1299
  task: t
1300
1300
  }
1301
- }), c = Ae(h, n), x = {
1302
- transform: Ne.Transform.toString(b),
1301
+ }), l = Me(h, n), x = {
1302
+ transform: Ie.Transform.toString(b),
1303
1303
  transition: v
1304
1304
  };
1305
- return /* @__PURE__ */ e("div", { ref: c, style: x, children: /* @__PURE__ */ e(
1306
- ze,
1305
+ return /* @__PURE__ */ e("div", { ref: l, style: x, children: /* @__PURE__ */ e(
1306
+ Fe,
1307
1307
  {
1308
1308
  task: t,
1309
1309
  isDragging: d,
@@ -1313,7 +1313,7 @@ const Ve = j.forwardRef(
1313
1313
  }
1314
1314
  );
1315
1315
  Ve.displayName = "TaskCard";
1316
- const Qt = Ie(
1316
+ const jt = De(
1317
1317
  "group/card flex items-center gap-ds-02 py-2 pl-3 pr-ds-03 border border-transparent rounded-ds-lg bg-layer-01 transition-all duration-fast-02 ease-productive-standard cursor-pointer hover:bg-layer-active hover:shadow-02 hover:-translate-y-px",
1318
1318
  {
1319
1319
  variants: {
@@ -1332,7 +1332,7 @@ const Qt = Ie(
1332
1332
  }
1333
1333
  }
1334
1334
  );
1335
- function Fe({
1335
+ function Ue({
1336
1336
  task: s,
1337
1337
  isDragging: t,
1338
1338
  isDragOverlay: n
@@ -1345,7 +1345,7 @@ function Fe({
1345
1345
  currentUserId: b,
1346
1346
  highlightMyTasks: v,
1347
1347
  onClickTask: d
1348
- } = U(), c = r.has(s.id), x = r.size > 0, T = h === s.id, y = $e[s.priority], g = ce[s.priority], S = v && b != null && ((k = s.owner) == null ? void 0 : k.id) !== b && !s.assignees.some((l) => l.id === b), u = s.owner ?? s.assignees[0] ?? null;
1348
+ } = K(), l = r.has(s.id), x = r.size > 0, D = h === s.id, g = _e[s.priority], f = ce[s.priority], A = v && b != null && ((k = s.owner) == null ? void 0 : k.id) !== b && !s.assignees.some((u) => u.id === b), c = s.owner ?? s.assignees[0] ?? null;
1349
1349
  return /* @__PURE__ */ a(
1350
1350
  "div",
1351
1351
  {
@@ -1353,41 +1353,41 @@ function Fe({
1353
1353
  tabIndex: 0,
1354
1354
  "data-task-id": s.id,
1355
1355
  "aria-label": `Task ${s.taskId}: ${s.title}`,
1356
- className: I(
1356
+ className: N(
1357
1357
  "relative",
1358
- Qt({
1359
- selected: c,
1360
- dimmed: S
1358
+ jt({
1359
+ selected: l,
1360
+ dimmed: A
1361
1361
  }),
1362
1362
  t && "opacity-40",
1363
1363
  n && "scale-[1.03] rotate-[1.5deg] shadow-03",
1364
- T && "ring-1 ring-focus"
1364
+ D && "ring-1 ring-focus"
1365
1365
  ),
1366
1366
  onClick: () => d(s.id),
1367
- onKeyDown: (l) => {
1368
- (l.key === "Enter" || l.key === " ") && (l.preventDefault(), d(s.id));
1367
+ onKeyDown: (u) => {
1368
+ (u.key === "Enter" || u.key === " ") && (u.preventDefault(), d(s.id));
1369
1369
  },
1370
1370
  children: [
1371
1371
  /* @__PURE__ */ e(
1372
1372
  "div",
1373
1373
  {
1374
- className: I(
1374
+ className: N(
1375
1375
  "absolute -top-1.5 -left-1.5 z-10 transition-opacity",
1376
- x || c ? "opacity-100 animate-scale-bounce" : "opacity-0 group-hover/card:opacity-100"
1376
+ x || l ? "opacity-100 animate-scale-bounce" : "opacity-0 group-hover/card:opacity-100"
1377
1377
  ),
1378
1378
  children: /* @__PURE__ */ e(
1379
- Me,
1379
+ Le,
1380
1380
  {
1381
- checked: c,
1381
+ checked: l,
1382
1382
  onCheckedChange: () => o(s.id),
1383
- onClick: (l) => l.stopPropagation(),
1383
+ onClick: (u) => u.stopPropagation(),
1384
1384
  "aria-label": `Select task ${s.taskId}`,
1385
1385
  className: "rounded-full bg-layer-01 shadow-01"
1386
1386
  }
1387
1387
  )
1388
1388
  }
1389
1389
  ),
1390
- /* @__PURE__ */ e(y, { className: I("h-3.5 w-3.5 flex-shrink-0", g), title: `Priority: ${s.priority}` }),
1390
+ /* @__PURE__ */ e(g, { className: N("h-3.5 w-3.5 flex-shrink-0", f), title: `Priority: ${s.priority}` }),
1391
1391
  /* @__PURE__ */ e("span", { className: "text-ds-xs font-mono text-text-tertiary flex-shrink-0", children: s.taskId }),
1392
1392
  /* @__PURE__ */ e("span", { className: "text-ds-sm text-text-primary line-clamp-1 flex-1 min-w-0", children: s.title }),
1393
1393
  s.subtaskCount > 0 && /* @__PURE__ */ a("span", { className: "text-ds-xs text-text-tertiary flex-shrink-0", children: [
@@ -1395,22 +1395,22 @@ function Fe({
1395
1395
  "/",
1396
1396
  s.subtaskCount
1397
1397
  ] }),
1398
- u && /* @__PURE__ */ e(
1398
+ c && /* @__PURE__ */ e(
1399
1399
  "div",
1400
1400
  {
1401
- className: I(
1401
+ className: N(
1402
1402
  "flex h-[14px] w-[14px] shrink-0 items-center justify-center rounded-full border border-layer-01 bg-interactive-subtle text-[6px] font-semibold leading-none text-interactive overflow-hidden",
1403
1403
  s.owner && "shadow-[0_0_0_1px_rgba(var(--accent-rgb,99,102,241),0.35),0_0_4px_rgba(var(--accent-rgb,99,102,241),0.2)]"
1404
1404
  ),
1405
- title: u.name,
1406
- children: u.image ? /* @__PURE__ */ e("img", { src: u.image, alt: u.name, className: "h-full w-full object-cover" }) : _e(u.name)
1405
+ title: c.name,
1406
+ children: c.image ? /* @__PURE__ */ e("img", { src: c.image, alt: c.name, className: "h-full w-full object-cover" }) : ze(c.name)
1407
1407
  }
1408
1408
  )
1409
1409
  ]
1410
1410
  }
1411
1411
  );
1412
1412
  }
1413
- const Ue = j.forwardRef(
1413
+ const Ge = Q.forwardRef(
1414
1414
  function({ task: t }, n) {
1415
1415
  const {
1416
1416
  attributes: r,
@@ -1419,18 +1419,18 @@ const Ue = j.forwardRef(
1419
1419
  transform: b,
1420
1420
  transition: v,
1421
1421
  isDragging: d
1422
- } = Ce({
1422
+ } = Ne({
1423
1423
  id: t.id,
1424
1424
  data: {
1425
1425
  type: "task",
1426
1426
  task: t
1427
1427
  }
1428
- }), c = Ae(h, n), x = {
1429
- transform: Ne.Transform.toString(b),
1428
+ }), l = Me(h, n), x = {
1429
+ transform: Ie.Transform.toString(b),
1430
1430
  transition: v
1431
1431
  };
1432
- return /* @__PURE__ */ e("div", { ref: c, style: x, children: /* @__PURE__ */ e(
1433
- Fe,
1432
+ return /* @__PURE__ */ e("div", { ref: l, style: x, children: /* @__PURE__ */ e(
1433
+ Ue,
1434
1434
  {
1435
1435
  task: t,
1436
1436
  isDragging: d,
@@ -1439,24 +1439,24 @@ const Ue = j.forwardRef(
1439
1439
  ) });
1440
1440
  }
1441
1441
  );
1442
- Ue.displayName = "TaskCardCompact";
1443
- const Ke = j.forwardRef(function({ task: t }, n) {
1444
- return /* @__PURE__ */ e("div", { ref: n, children: /* @__PURE__ */ e(Fe, { task: t, isDragOverlay: !0 }) });
1442
+ Ge.displayName = "TaskCardCompact";
1443
+ const Ke = Q.forwardRef(function({ task: t }, n) {
1444
+ return /* @__PURE__ */ e("div", { ref: n, children: /* @__PURE__ */ e(Ue, { task: t, isDragOverlay: !0 }) });
1445
1445
  });
1446
1446
  Ke.displayName = "TaskCardCompactOverlay";
1447
- const Ge = j.forwardRef(
1447
+ const He = Q.forwardRef(
1448
1448
  function({ task: t }, n) {
1449
- return /* @__PURE__ */ e("div", { ref: n, children: /* @__PURE__ */ e(ze, { task: t, isDragOverlay: !0 }) });
1449
+ return /* @__PURE__ */ e("div", { ref: n, children: /* @__PURE__ */ e(Fe, { task: t, isDragOverlay: !0 }) });
1450
1450
  }
1451
1451
  );
1452
- Ge.displayName = "TaskCardOverlay";
1453
- const jt = [
1454
- { value: "LOW", label: "Low", icon: Se },
1455
- { value: "MEDIUM", label: "Medium", icon: fe },
1456
- { value: "HIGH", label: "High", icon: Re },
1452
+ He.displayName = "TaskCardOverlay";
1453
+ const Yt = [
1454
+ { value: "LOW", label: "Low", icon: Ae },
1455
+ { value: "MEDIUM", label: "Medium", icon: pe },
1456
+ { value: "HIGH", label: "High", icon: Se },
1457
1457
  { value: "URGENT", label: "Urgent", icon: le }
1458
1458
  ];
1459
- function He({ taskId: s, children: t }) {
1459
+ function Qe({ taskId: s, children: t }) {
1460
1460
  const {
1461
1461
  rawColumns: n,
1462
1462
  onQuickPriorityChange: r,
@@ -1465,84 +1465,84 @@ function He({ taskId: s, children: t }) {
1465
1465
  onQuickDueDateChange: b,
1466
1466
  onQuickVisibilityChange: v,
1467
1467
  onQuickDelete: d
1468
- } = U(), c = de(n), x = Ee(n), T = j.useRef(null);
1469
- return /* @__PURE__ */ a(St, { children: [
1470
- /* @__PURE__ */ e(At, { children: t }),
1471
- /* @__PURE__ */ a(Mt, { className: "w-52 animate-scale-in", children: [
1468
+ } = K(), l = de(n), x = Oe(n), D = Q.useRef(null);
1469
+ return /* @__PURE__ */ a(At, { children: [
1470
+ /* @__PURE__ */ e(Mt, { children: t }),
1471
+ /* @__PURE__ */ a(Lt, { className: "w-52 animate-scale-in", children: [
1472
1472
  /* @__PURE__ */ a(Z, { children: [
1473
1473
  /* @__PURE__ */ a(ee, { children: [
1474
1474
  /* @__PURE__ */ e(le, { className: "mr-ds-03 h-ico-sm w-ico-sm" }),
1475
1475
  "Set Priority"
1476
1476
  ] }),
1477
- /* @__PURE__ */ e(te, { className: "w-40", children: jt.map((y) => {
1478
- const g = y.icon;
1477
+ /* @__PURE__ */ e(te, { className: "w-40", children: Yt.map((g) => {
1478
+ const f = g.icon;
1479
1479
  return /* @__PURE__ */ a(
1480
- H,
1480
+ j,
1481
1481
  {
1482
- onSelect: () => r(s, y.value),
1482
+ onSelect: () => r(s, g.value),
1483
1483
  children: [
1484
1484
  /* @__PURE__ */ e(
1485
- g,
1485
+ f,
1486
1486
  {
1487
- className: I(
1487
+ className: N(
1488
1488
  "mr-ds-03 h-ico-sm w-ico-sm",
1489
- ce[y.value]
1489
+ ce[g.value]
1490
1490
  )
1491
1491
  }
1492
1492
  ),
1493
- y.label
1493
+ g.label
1494
1494
  ]
1495
1495
  },
1496
- y.value
1496
+ g.value
1497
1497
  );
1498
1498
  }) })
1499
1499
  ] }),
1500
- c.length > 0 && /* @__PURE__ */ a(Z, { children: [
1500
+ l.length > 0 && /* @__PURE__ */ a(Z, { children: [
1501
1501
  /* @__PURE__ */ a(ee, { children: [
1502
1502
  /* @__PURE__ */ e(q, { className: "mr-ds-03 h-ico-sm w-ico-sm" }),
1503
1503
  "Assign"
1504
1504
  ] }),
1505
- /* @__PURE__ */ e(te, { className: "w-44 max-h-48 overflow-y-auto", children: c.map((y) => /* @__PURE__ */ e(
1506
- H,
1505
+ /* @__PURE__ */ e(te, { className: "w-44 max-h-48 overflow-y-auto", children: l.map((g) => /* @__PURE__ */ e(
1506
+ j,
1507
1507
  {
1508
- onSelect: () => o(s, y.id),
1509
- children: y.name
1508
+ onSelect: () => o(s, g.id),
1509
+ children: g.name
1510
1510
  },
1511
- y.id
1511
+ g.id
1512
1512
  )) })
1513
1513
  ] }),
1514
1514
  /* @__PURE__ */ a(Z, { children: [
1515
1515
  /* @__PURE__ */ a(ee, { children: [
1516
- /* @__PURE__ */ e(Nt, { className: "mr-ds-03 h-ico-sm w-ico-sm" }),
1516
+ /* @__PURE__ */ e(It, { className: "mr-ds-03 h-ico-sm w-ico-sm" }),
1517
1517
  "Add Label"
1518
1518
  ] }),
1519
- /* @__PURE__ */ e(te, { className: "w-40 max-h-48 overflow-y-auto", children: x.length > 0 ? x.map((y) => /* @__PURE__ */ e(
1520
- H,
1519
+ /* @__PURE__ */ e(te, { className: "w-40 max-h-48 overflow-y-auto", children: x.length > 0 ? x.map((g) => /* @__PURE__ */ e(
1520
+ j,
1521
1521
  {
1522
- onSelect: () => h(s, y),
1523
- children: y
1522
+ onSelect: () => h(s, g),
1523
+ children: g
1524
1524
  },
1525
- y
1525
+ g
1526
1526
  )) : /* @__PURE__ */ e("div", { className: "px-ds-03 py-ds-02 text-ds-xs text-text-tertiary", children: "No labels found" }) })
1527
1527
  ] }),
1528
1528
  /* @__PURE__ */ a(
1529
- H,
1529
+ j,
1530
1530
  {
1531
- onSelect: (y) => {
1532
- var g;
1533
- y.preventDefault(), (g = T.current) == null || g.showPicker();
1531
+ onSelect: (g) => {
1532
+ var f;
1533
+ g.preventDefault(), (f = D.current) == null || f.showPicker();
1534
1534
  },
1535
1535
  children: [
1536
- /* @__PURE__ */ e(ye, { className: "mr-ds-03 h-ico-sm w-ico-sm" }),
1536
+ /* @__PURE__ */ e(ve, { className: "mr-ds-03 h-ico-sm w-ico-sm" }),
1537
1537
  "Set Due Date",
1538
1538
  /* @__PURE__ */ e(
1539
1539
  "input",
1540
1540
  {
1541
- ref: T,
1541
+ ref: D,
1542
1542
  type: "date",
1543
1543
  className: "absolute opacity-0 pointer-events-none w-0 h-0",
1544
- onChange: (y) => {
1545
- b(s, y.target.value || null);
1544
+ onChange: (g) => {
1545
+ b(s, g.target.value || null);
1546
1546
  },
1547
1547
  tabIndex: -1
1548
1548
  }
@@ -1557,17 +1557,17 @@ function He({ taskId: s, children: t }) {
1557
1557
  ] }),
1558
1558
  /* @__PURE__ */ a(te, { className: "w-44", children: [
1559
1559
  /* @__PURE__ */ a(
1560
- H,
1560
+ j,
1561
1561
  {
1562
1562
  onSelect: () => v(s, "INTERNAL"),
1563
1563
  children: [
1564
- /* @__PURE__ */ e(Te, { className: "mr-ds-03 h-ico-sm w-ico-sm" }),
1564
+ /* @__PURE__ */ e(Re, { className: "mr-ds-03 h-ico-sm w-ico-sm" }),
1565
1565
  "Internal only"
1566
1566
  ]
1567
1567
  }
1568
1568
  ),
1569
1569
  /* @__PURE__ */ a(
1570
- H,
1570
+ j,
1571
1571
  {
1572
1572
  onSelect: () => v(s, "EVERYONE"),
1573
1573
  children: [
@@ -1578,14 +1578,14 @@ function He({ taskId: s, children: t }) {
1578
1578
  )
1579
1579
  ] })
1580
1580
  ] }),
1581
- /* @__PURE__ */ e(Lt, {}),
1581
+ /* @__PURE__ */ e(Et, {}),
1582
1582
  /* @__PURE__ */ a(
1583
- H,
1583
+ j,
1584
1584
  {
1585
1585
  className: "text-error focus:text-error",
1586
1586
  onSelect: () => d(s),
1587
1587
  children: [
1588
- /* @__PURE__ */ e(pe, { className: "mr-ds-03 h-ico-sm w-ico-sm" }),
1588
+ /* @__PURE__ */ e(xe, { className: "mr-ds-03 h-ico-sm w-ico-sm" }),
1589
1589
  "Delete"
1590
1590
  ]
1591
1591
  }
@@ -1593,53 +1593,72 @@ function He({ taskId: s, children: t }) {
1593
1593
  ] })
1594
1594
  ] });
1595
1595
  }
1596
- He.displayName = "TaskContextMenu";
1597
- const Qe = j.forwardRef(
1598
- function({ column: t, index: n, isOverlay: r }, o) {
1599
- const { viewMode: h } = U(), { setNodeRef: b, isOver: v } = Je({
1596
+ Qe.displayName = "TaskContextMenu";
1597
+ function fe() {
1598
+ return /* @__PURE__ */ a(
1599
+ "div",
1600
+ {
1601
+ className: "rounded-ds-lg border-2 border-dashed border-interactive/40 bg-interactive/[0.06] px-ds-04 py-ds-05",
1602
+ "aria-hidden": !0,
1603
+ children: [
1604
+ /* @__PURE__ */ e("div", { className: "h-ds-xs-plus w-3/4 rounded-ds-md bg-interactive/10" }),
1605
+ /* @__PURE__ */ e("div", { className: "mt-ds-02 h-[12px] w-1/2 rounded-ds-md bg-interactive/[0.06]" })
1606
+ ]
1607
+ }
1608
+ );
1609
+ }
1610
+ const je = Q.forwardRef(
1611
+ function({ column: t, index: n, isOverlay: r, dragPreview: o, draggedTask: h }, b) {
1612
+ const { viewMode: v } = K(), { setNodeRef: d, isOver: l } = Ze({
1600
1613
  id: `column-${t.id}`,
1601
1614
  data: {
1602
1615
  type: "column",
1603
1616
  column: t
1604
1617
  }
1605
- }), d = t.tasks.map((x) => x.id), c = t.wipLimit != null && t.tasks.length > t.wipLimit;
1618
+ }), x = t.tasks.map((g) => g.id), D = t.wipLimit != null && t.tasks.length > t.wipLimit;
1606
1619
  return /* @__PURE__ */ a(
1607
1620
  "div",
1608
1621
  {
1609
- ref: o,
1610
- className: I(
1622
+ ref: b,
1623
+ className: N(
1611
1624
  "flex h-full flex-shrink-0 flex-col rounded-ds-xl bg-layer-01/40 backdrop-blur-[2px] border border-border-subtle/20 hover:border-border-subtle/40 transition-colors p-1",
1612
1625
  r && "shadow-04",
1613
- c && "bg-error-surface/50"
1626
+ D && "bg-error-surface/50"
1614
1627
  ),
1615
- style: { width: Et },
1628
+ style: { width: Ot },
1616
1629
  children: [
1617
1630
  /* @__PURE__ */ e(Pe, { column: t, index: n }),
1618
1631
  /* @__PURE__ */ a(
1619
1632
  "div",
1620
1633
  {
1621
- ref: b,
1622
- className: I(
1634
+ ref: d,
1635
+ className: N(
1623
1636
  "no-scrollbar flex flex-1 flex-col gap-ds-02 overflow-y-auto px-ds-03 pt-2.5 pb-ds-03 transition-colors duration-fast-02 ease-productive-standard",
1624
- v && "bg-interactive-subtle/30"
1637
+ l && "bg-interactive-subtle/30"
1625
1638
  ),
1626
1639
  children: [
1627
- /* @__PURE__ */ e(De, { items: d, strategy: Ze, children: t.tasks.map((x, T) => /* @__PURE__ */ e(
1628
- "div",
1629
- {
1630
- className: "animate-slide-up delay-stagger",
1631
- style: { "--stagger-index": T },
1632
- children: /* @__PURE__ */ e(He, { taskId: x.id, children: h === "compact" ? /* @__PURE__ */ e(Ue, { task: x }) : /* @__PURE__ */ e(Ve, { task: x }) })
1633
- },
1634
- x.id
1635
- )) }),
1636
- t.tasks.length === 0 && /* @__PURE__ */ e(
1637
- We,
1640
+ /* @__PURE__ */ a(Te, { items: x, strategy: et, children: [
1641
+ t.tasks.map((g, f) => /* @__PURE__ */ a(Q.Fragment, { children: [
1642
+ o && o.index === f && /* @__PURE__ */ e(fe, {}),
1643
+ /* @__PURE__ */ e(
1644
+ "div",
1645
+ {
1646
+ className: "animate-slide-up delay-stagger",
1647
+ style: { "--stagger-index": f },
1648
+ children: /* @__PURE__ */ e(Qe, { taskId: g.id, children: v === "compact" ? /* @__PURE__ */ e(Ge, { task: g }) : /* @__PURE__ */ e(Ve, { task: g }) })
1649
+ }
1650
+ )
1651
+ ] }, g.id)),
1652
+ o && o.index >= t.tasks.length && /* @__PURE__ */ e(fe, {})
1653
+ ] }),
1654
+ t.tasks.length === 0 && !o && /* @__PURE__ */ e(
1655
+ $e,
1638
1656
  {
1639
1657
  index: n,
1640
- isDropTarget: v
1658
+ isDropTarget: l
1641
1659
  }
1642
- )
1660
+ ),
1661
+ t.tasks.length === 0 && o && /* @__PURE__ */ e(fe, {})
1643
1662
  ]
1644
1663
  }
1645
1664
  )
@@ -1648,8 +1667,8 @@ const Qe = j.forwardRef(
1648
1667
  );
1649
1668
  }
1650
1669
  );
1651
- Qe.displayName = "BoardColumn";
1652
- function Yt(s) {
1670
+ je.displayName = "BoardColumn";
1671
+ function qt(s) {
1653
1672
  const {
1654
1673
  columns: t,
1655
1674
  focusedTaskId: n,
@@ -1659,80 +1678,80 @@ function Yt(s) {
1659
1678
  selectRange: b,
1660
1679
  clearSelection: v,
1661
1680
  clearFilters: d,
1662
- hasActiveFilters: c,
1681
+ hasActiveFilters: l,
1663
1682
  onClickTask: x
1664
- } = U(), T = E(
1665
- (u) => {
1683
+ } = K(), D = B(
1684
+ (c) => {
1666
1685
  for (let k = 0; k < t.length; k++)
1667
- for (let l = 0; l < t[k].tasks.length; l++)
1668
- if (t[k].tasks[l].id === u)
1669
- return { columnIndex: k, taskIndex: l, taskId: u };
1686
+ for (let u = 0; u < t[k].tasks.length; u++)
1687
+ if (t[k].tasks[u].id === c)
1688
+ return { columnIndex: k, taskIndex: u, taskId: c };
1670
1689
  return null;
1671
1690
  },
1672
1691
  [t]
1673
- ), y = E(
1674
- (u, k) => {
1675
- const l = t[u];
1676
- if (!l) return null;
1677
- const p = l.tasks[k];
1678
- return (p == null ? void 0 : p.id) ?? null;
1692
+ ), g = B(
1693
+ (c, k) => {
1694
+ const u = t[c];
1695
+ if (!u) return null;
1696
+ const I = u.tasks[k];
1697
+ return (I == null ? void 0 : I.id) ?? null;
1679
1698
  },
1680
1699
  [t]
1681
- ), g = E((u) => {
1682
- const k = document.querySelector(`[data-task-id="${u}"]`);
1700
+ ), f = B((c) => {
1701
+ const k = document.querySelector(`[data-task-id="${c}"]`);
1683
1702
  k && k.scrollIntoView({ block: "nearest", behavior: "smooth" });
1684
- }, []), S = E(
1685
- (u) => {
1686
- const k = u.target;
1703
+ }, []), A = B(
1704
+ (c) => {
1705
+ const k = c.target;
1687
1706
  if (!(k.tagName === "INPUT" || k.tagName === "TEXTAREA" || k.isContentEditable))
1688
- switch (u.key) {
1707
+ switch (c.key) {
1689
1708
  case "ArrowDown":
1690
1709
  case "ArrowUp": {
1691
- u.preventDefault();
1692
- const l = u.key === "ArrowDown" ? 1 : -1;
1710
+ c.preventDefault();
1711
+ const u = c.key === "ArrowDown" ? 1 : -1;
1693
1712
  if (!n) {
1694
1713
  for (const i of t)
1695
1714
  if (i.tasks.length > 0) {
1696
- const f = i.tasks[0].id;
1697
- r(f), g(f);
1715
+ const p = i.tasks[0].id;
1716
+ r(p), f(p);
1698
1717
  break;
1699
1718
  }
1700
1719
  return;
1701
1720
  }
1702
- const p = T(n);
1703
- if (!p) return;
1704
- const m = p.taskIndex + l, C = y(p.columnIndex, m);
1705
- C && (r(C), g(C), u.shiftKey && n && b(n, C));
1721
+ const I = D(n);
1722
+ if (!I) return;
1723
+ const m = I.taskIndex + u, y = g(I.columnIndex, m);
1724
+ y && (r(y), f(y), c.shiftKey && n && b(n, y));
1706
1725
  return;
1707
1726
  }
1708
1727
  case "ArrowLeft":
1709
1728
  case "ArrowRight": {
1710
- u.preventDefault();
1711
- const l = u.key === "ArrowRight" ? 1 : -1;
1729
+ c.preventDefault();
1730
+ const u = c.key === "ArrowRight" ? 1 : -1;
1712
1731
  if (!n) return;
1713
- const p = T(n);
1714
- if (!p) return;
1715
- let m = p.columnIndex + l;
1732
+ const I = D(n);
1733
+ if (!I) return;
1734
+ let m = I.columnIndex + u;
1716
1735
  for (; m >= 0 && m < t.length; ) {
1717
1736
  if (t[m].tasks.length > 0) {
1718
- const C = Math.min(p.taskIndex, t[m].tasks.length - 1), i = t[m].tasks[C].id;
1719
- r(i), g(i);
1737
+ const y = Math.min(I.taskIndex, t[m].tasks.length - 1), i = t[m].tasks[y].id;
1738
+ r(i), f(i);
1720
1739
  return;
1721
1740
  }
1722
- m += l;
1741
+ m += u;
1723
1742
  }
1724
1743
  return;
1725
1744
  }
1726
1745
  case "Enter": {
1727
- n && (u.preventDefault(), x(n));
1746
+ n && (c.preventDefault(), x(n));
1728
1747
  return;
1729
1748
  }
1730
1749
  case " ": {
1731
- n && (u.preventDefault(), h(n));
1750
+ n && (c.preventDefault(), h(n));
1732
1751
  return;
1733
1752
  }
1734
1753
  case "Escape": {
1735
- u.preventDefault(), o.size > 0 ? v() : c && d();
1754
+ c.preventDefault(), o.size > 0 ? v() : l && d();
1736
1755
  return;
1737
1756
  }
1738
1757
  }
@@ -1741,11 +1760,11 @@ function Yt(s) {
1741
1760
  n,
1742
1761
  t,
1743
1762
  o,
1744
- c,
1745
- T,
1746
- y,
1747
- r,
1763
+ l,
1764
+ D,
1748
1765
  g,
1766
+ r,
1767
+ f,
1749
1768
  h,
1750
1769
  b,
1751
1770
  v,
@@ -1754,12 +1773,12 @@ function Yt(s) {
1754
1773
  ]
1755
1774
  );
1756
1775
  oe(() => {
1757
- const u = s.current;
1758
- if (u)
1759
- return u.addEventListener("keydown", S), () => u.removeEventListener("keydown", S);
1760
- }, [s, S]);
1776
+ const c = s.current;
1777
+ if (c)
1778
+ return c.addEventListener("keydown", A), () => c.removeEventListener("keydown", A);
1779
+ }, [s, A]);
1761
1780
  }
1762
- function qt() {
1781
+ function Xt() {
1763
1782
  return {
1764
1783
  onDragStart({ active: s }) {
1765
1784
  const t = s.data.current;
@@ -1781,7 +1800,7 @@ function qt() {
1781
1800
  }
1782
1801
  };
1783
1802
  }
1784
- function Xt({ className: s }) {
1803
+ function Jt({ className: s }) {
1785
1804
  const {
1786
1805
  columns: t,
1787
1806
  viewMode: n,
@@ -1789,118 +1808,144 @@ function Xt({ className: s }) {
1789
1808
  setActiveTask: o,
1790
1809
  onTaskMove: h,
1791
1810
  onAddColumn: b
1792
- } = U(), [v, d] = A(!1);
1811
+ } = K(), [v, d] = O(!1), [l, x] = O(null);
1793
1812
  ae(null);
1794
- const c = ae(null);
1795
- Yt(c), oe(() => {
1813
+ const D = ae(null);
1814
+ qt(D), oe(() => {
1796
1815
  d(!0);
1797
1816
  }, []);
1798
- const x = et(
1799
- he(lt, {
1817
+ const g = tt(
1818
+ he(ct, {
1800
1819
  activationConstraint: { distance: 5 }
1801
1820
  }),
1802
- he(ot, {
1821
+ he(lt, {
1803
1822
  activationConstraint: { delay: 200, tolerance: 5 }
1804
1823
  }),
1805
- he(it, {
1806
- coordinateGetter: rt
1824
+ he(ot, {
1825
+ coordinateGetter: it
1807
1826
  })
1808
- ), T = ne(() => qt(), []), y = t.map((l) => `column-${l.id}`), g = E(
1809
- (l) => {
1810
- for (const p of t)
1811
- if (p.tasks.some((m) => m.id === l))
1812
- return p.id;
1827
+ ), f = ne(() => Xt(), []), A = t.map((y) => `column-${y.id}`), c = B(
1828
+ (y) => {
1829
+ for (const i of t)
1830
+ if (i.tasks.some((p) => p.id === y))
1831
+ return i.id;
1813
1832
  return null;
1814
1833
  },
1815
1834
  [t]
1816
- ), S = E(
1817
- (l) => {
1818
- const p = l.active.data.current;
1819
- (p == null ? void 0 : p.type) === "task" && o(p.task);
1835
+ ), k = B(
1836
+ (y) => {
1837
+ const i = y.active.data.current;
1838
+ (i == null ? void 0 : i.type) === "task" && o(i.task);
1820
1839
  },
1821
1840
  [o]
1822
- ), u = E(
1823
- (l) => {
1824
- const { active: p, over: m } = l;
1825
- if (!m) return;
1826
- const C = p.id, i = m.id, f = g(C);
1827
- if (!f) return;
1828
- let D = null, M = 0;
1829
- if (i.startsWith("column-")) {
1830
- D = i.replace("column-", "");
1831
- const N = t.find((R) => R.id === D);
1832
- M = (N == null ? void 0 : N.tasks.length) ?? 0;
1833
- } else if (D = g(i), D) {
1834
- const N = t.find((R) => R.id === D);
1835
- M = (N == null ? void 0 : N.tasks.findIndex((R) => R.id === i)) ?? 0;
1841
+ ), u = B(
1842
+ (y) => {
1843
+ const { active: i, over: p } = y;
1844
+ if (!p) {
1845
+ x(null);
1846
+ return;
1847
+ }
1848
+ const S = i.id, M = p.id, L = c(S);
1849
+ if (!L) return;
1850
+ let E = null, T = 0;
1851
+ if (M.startsWith("column-")) {
1852
+ E = M.replace("column-", "");
1853
+ const R = t.find((C) => C.id === E);
1854
+ T = (R == null ? void 0 : R.tasks.length) ?? 0;
1855
+ } else if (E = c(M), E) {
1856
+ const R = t.find((C) => C.id === E);
1857
+ T = (R == null ? void 0 : R.tasks.findIndex((C) => C.id === M)) ?? 0;
1836
1858
  }
1837
- !D || f === D || h(C, D, M);
1859
+ if (!E) {
1860
+ x(null);
1861
+ return;
1862
+ }
1863
+ if (L === E) {
1864
+ x(null);
1865
+ return;
1866
+ }
1867
+ x({ taskId: S, columnId: E, index: T });
1838
1868
  },
1839
- [t, g, h]
1840
- ), k = E(
1841
- (l) => {
1842
- const { active: p, over: m } = l;
1843
- if (o(null), !m) return;
1844
- const C = p.id, i = m.id, f = g(C);
1845
- if (!f) return;
1846
- let D, M;
1847
- if (i.startsWith("column-")) {
1848
- D = i.replace("column-", "");
1849
- const N = t.find((R) => R.id === D);
1850
- if (M = (N == null ? void 0 : N.tasks.length) ?? 0, f === D) {
1851
- const R = N == null ? void 0 : N.tasks.findIndex((B) => B.id === C);
1852
- R !== void 0 && R >= 0 && (M = R);
1869
+ [t, c]
1870
+ ), I = B(
1871
+ (y) => {
1872
+ const { active: i, over: p } = y, S = l;
1873
+ if (o(null), x(null), !p) return;
1874
+ const M = i.id, L = p.id, E = c(M);
1875
+ if (!E) return;
1876
+ if (S && S.taskId === M) {
1877
+ h(M, S.columnId, S.index);
1878
+ return;
1879
+ }
1880
+ let T, R;
1881
+ if (L.startsWith("column-")) {
1882
+ T = L.replace("column-", "");
1883
+ const C = t.find((W) => W.id === T);
1884
+ if (R = (C == null ? void 0 : C.tasks.length) ?? 0, E === T) {
1885
+ const W = C == null ? void 0 : C.tasks.findIndex((z) => z.id === M);
1886
+ W !== void 0 && W >= 0 && (R = W);
1853
1887
  }
1854
1888
  } else {
1855
- D = g(i) ?? f;
1856
- const N = t.find((R) => R.id === D);
1857
- M = (N == null ? void 0 : N.tasks.findIndex((R) => R.id === i)) ?? 0;
1889
+ T = c(L) ?? E;
1890
+ const C = t.find((W) => W.id === T);
1891
+ R = (C == null ? void 0 : C.tasks.findIndex((W) => W.id === L)) ?? 0;
1858
1892
  }
1859
- h(C, D, M);
1893
+ h(M, T, R);
1860
1894
  },
1861
- [t, g, o, h]
1862
- );
1895
+ [t, l, c, o, h]
1896
+ ), m = B(() => {
1897
+ o(null), x(null);
1898
+ }, [o]);
1863
1899
  return /* @__PURE__ */ a(
1864
- tt,
1900
+ st,
1865
1901
  {
1866
- sensors: x,
1867
- collisionDetection: st,
1868
- onDragStart: S,
1902
+ sensors: g,
1903
+ collisionDetection: nt,
1904
+ onDragStart: k,
1869
1905
  onDragOver: u,
1870
- onDragEnd: k,
1871
- accessibility: { announcements: T },
1906
+ onDragEnd: I,
1907
+ onDragCancel: m,
1908
+ accessibility: { announcements: f },
1872
1909
  children: [
1873
1910
  /* @__PURE__ */ a(
1874
1911
  "div",
1875
1912
  {
1876
- ref: c,
1913
+ ref: D,
1877
1914
  tabIndex: 0,
1878
1915
  className: "no-scrollbar flex h-full gap-ds-05 overflow-x-auto pb-ds-05 outline-none",
1879
1916
  children: [
1880
1917
  /* @__PURE__ */ e(
1881
- De,
1918
+ Te,
1882
1919
  {
1883
- items: y,
1884
- strategy: nt,
1885
- children: t.map((l, p) => /* @__PURE__ */ e(
1920
+ items: A,
1921
+ strategy: at,
1922
+ children: t.map((y, i) => /* @__PURE__ */ e(
1886
1923
  "div",
1887
1924
  {
1888
1925
  className: "flex-shrink-0 animate-slide-right delay-stagger-50",
1889
- style: { "--stagger-index": p },
1890
- children: /* @__PURE__ */ e(Qe, { column: l, index: p })
1926
+ style: { "--stagger-index": i },
1927
+ children: /* @__PURE__ */ e(
1928
+ je,
1929
+ {
1930
+ column: y,
1931
+ index: i,
1932
+ dragPreview: (l == null ? void 0 : l.columnId) === y.id ? l : void 0,
1933
+ draggedTask: r
1934
+ }
1935
+ )
1891
1936
  },
1892
- l.id
1937
+ y.id
1893
1938
  ))
1894
1939
  }
1895
1940
  ),
1896
1941
  /* @__PURE__ */ e("div", { className: "flex-shrink-0", children: /* @__PURE__ */ a(
1897
- O,
1942
+ $,
1898
1943
  {
1899
1944
  variant: "ghost",
1900
1945
  onClick: b,
1901
1946
  className: "h-ds-md w-[320px] justify-start gap-ds-03 rounded-ds-xl border border-dashed border-border/60 bg-layer-02 text-text-tertiary hover:border-border-interactive hover:bg-interactive-subtle/50 hover:text-interactive",
1902
1947
  children: [
1903
- /* @__PURE__ */ e(xe, { className: "h-ico-sm w-ico-sm" }),
1948
+ /* @__PURE__ */ e(ye, { className: "h-ico-sm w-ico-sm" }),
1904
1949
  "Add column"
1905
1950
  ]
1906
1951
  }
@@ -1908,42 +1953,42 @@ function Xt({ className: s }) {
1908
1953
  ]
1909
1954
  }
1910
1955
  ),
1911
- v && Xe(
1912
- /* @__PURE__ */ e(at, { dropAnimation: { duration: 240, easing: "cubic-bezier(0.34, 1.56, 0.64, 1)" }, children: r ? n === "compact" ? /* @__PURE__ */ e(Ke, { task: r }) : /* @__PURE__ */ e(Ge, { task: r }) : null }),
1956
+ v && Je(
1957
+ /* @__PURE__ */ e(rt, { dropAnimation: { duration: 240, easing: "cubic-bezier(0.34, 1.56, 0.64, 1)" }, children: r ? n === "compact" ? /* @__PURE__ */ e(Ke, { task: r }) : /* @__PURE__ */ e(He, { task: r }) : null }),
1913
1958
  document.body
1914
1959
  )
1915
1960
  ]
1916
1961
  }
1917
1962
  );
1918
1963
  }
1919
- const Jt = j.forwardRef(
1964
+ const Zt = Q.forwardRef(
1920
1965
  function({ className: t, ...n }, r) {
1921
1966
  return /* @__PURE__ */ e("div", { ref: r, className: t, children: /* @__PURE__ */ e(Pt, { ...n, children: /* @__PURE__ */ a("div", { className: "flex flex-col gap-ds-03", children: [
1922
- /* @__PURE__ */ e(Oe, {}),
1923
1967
  /* @__PURE__ */ e(Be, {}),
1924
- /* @__PURE__ */ e(Xt, {})
1968
+ /* @__PURE__ */ e(We, {}),
1969
+ /* @__PURE__ */ e(Jt, {})
1925
1970
  ] }) }) });
1926
1971
  }
1927
1972
  );
1928
- Jt.displayName = "KanbanBoard";
1973
+ Zt.displayName = "KanbanBoard";
1929
1974
  export {
1930
- Qe as B,
1931
- ve as C,
1932
- we as D,
1933
- Jt as K,
1975
+ je as B,
1976
+ we as C,
1977
+ be as D,
1978
+ Zt as K,
1934
1979
  ce as P,
1935
1980
  Ve as T,
1936
1981
  Pt as a,
1937
- Oe as b,
1938
- Be as c,
1939
- Et as d,
1940
- We as e,
1982
+ Be as b,
1983
+ We as c,
1984
+ Ot as d,
1985
+ $e as e,
1941
1986
  Pe as f,
1942
- fs as g,
1943
- Ue as h,
1987
+ ps as g,
1988
+ Ge as h,
1944
1989
  Ke as i,
1945
- Ge as j,
1946
- He as k,
1947
- Yt as l,
1948
- U as u
1990
+ He as j,
1991
+ Qe as k,
1992
+ qt as l,
1993
+ K as u
1949
1994
  };