@thebuoyant-tsdev/mui-ts-library 3.30.0 → 3.31.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.
- package/dist/components/kanban-board/KanbanBoard.d.ts +1 -1
- package/dist/components/kanban-board/KanbanBoard.js +55 -52
- package/dist/components/kanban-board/KanbanBoard.types.d.ts +9 -0
- package/dist/components/kanban-board/KanbanBoardCard.d.ts +2 -1
- package/dist/components/kanban-board/KanbanBoardCard.js +59 -45
- package/dist/components/kanban-board/KanbanBoardColumn.d.ts +2 -1
- package/dist/components/kanban-board/KanbanBoardColumn.js +20 -17
- package/dist/index.cjs +2 -2
- package/package.json +1 -1
|
@@ -1,2 +1,2 @@
|
|
|
1
1
|
import { type KanbanBoardProps } from "./KanbanBoard.types";
|
|
2
|
-
export declare function KanbanBoard({ tasks, columns, onTasksChange, onCardClick, enableBuiltinDialogs, onTaskCreated, onTaskUpdated, onTaskDeleted, onTaskMoved, showAssignee, showDueDate, chipVariant, height, translation, }: KanbanBoardProps): import("react/jsx-runtime").JSX.Element;
|
|
2
|
+
export declare function KanbanBoard({ tasks, columns, onTasksChange, onCardClick, enableBuiltinDialogs, onTaskCreated, onTaskUpdated, onTaskDeleted, onTaskMoved, showAssignee, showDueDate, showDueDateWarning, chipVariant, width, height, translation, }: KanbanBoardProps): import("react/jsx-runtime").JSX.Element;
|
|
@@ -9,62 +9,62 @@ import { Box as m } from "@mui/material";
|
|
|
9
9
|
import { useEffect as h, useState as g } from "react";
|
|
10
10
|
import { jsx as _, jsxs as v } from "react/jsx-runtime";
|
|
11
11
|
//#region src/components/kanban-board/KanbanBoard.tsx
|
|
12
|
-
function y({ tasks: y, columns: b, onTasksChange: x, onCardClick: S, enableBuiltinDialogs: C = !0, onTaskCreated: w, onTaskUpdated: T, onTaskDeleted: E, onTaskMoved: D, showAssignee: O = !0, showDueDate: k = !0,
|
|
13
|
-
let
|
|
12
|
+
function y({ tasks: y, columns: b, onTasksChange: x, onCardClick: S, enableBuiltinDialogs: C = !0, onTaskCreated: w, onTaskUpdated: T, onTaskDeleted: E, onTaskMoved: D, showAssignee: O = !0, showDueDate: k = !0, showDueDateWarning: A = !0, chipVariant: j = "outlined", width: M = "100%", height: N = "100%", translation: P }) {
|
|
13
|
+
let F = {
|
|
14
14
|
...t,
|
|
15
|
-
...
|
|
16
|
-
}, [
|
|
15
|
+
...P
|
|
16
|
+
}, [I, L] = g(y);
|
|
17
17
|
h(() => {
|
|
18
|
-
|
|
18
|
+
L(y);
|
|
19
19
|
}, [y]);
|
|
20
|
-
let [
|
|
21
|
-
function
|
|
22
|
-
|
|
20
|
+
let [R, z] = g(null), [B, V] = g(null), H = d(u(c, { activationConstraint: { distance: 8 } }), u(s, { coordinateGetter: p }));
|
|
21
|
+
function U({ active: e }) {
|
|
22
|
+
z(I.find((t) => t.id === e.id) ?? null);
|
|
23
23
|
}
|
|
24
|
-
function
|
|
24
|
+
function W({ active: e, over: t }) {
|
|
25
25
|
if (!t) return;
|
|
26
|
-
let n = e.id, r = t.id, i =
|
|
26
|
+
let n = e.id, r = t.id, i = I.find((e) => e.id === n);
|
|
27
27
|
if (!i) return;
|
|
28
|
-
let a = b.find((e) => e.id === r), o =
|
|
29
|
-
!s || i.status === s ||
|
|
28
|
+
let a = b.find((e) => e.id === r), o = I.find((e) => e.id === r), s = a?.id ?? o?.status;
|
|
29
|
+
!s || i.status === s || L((e) => e.map((e) => e.id === n ? {
|
|
30
30
|
...e,
|
|
31
31
|
status: s
|
|
32
32
|
} : e));
|
|
33
33
|
}
|
|
34
|
-
function
|
|
35
|
-
let n =
|
|
36
|
-
if (
|
|
37
|
-
|
|
34
|
+
function G({ active: e, over: t }) {
|
|
35
|
+
let n = R?.status;
|
|
36
|
+
if (z(null), !t) {
|
|
37
|
+
L(y);
|
|
38
38
|
return;
|
|
39
39
|
}
|
|
40
|
-
let r = e.id, i = t.id, a =
|
|
41
|
-
if (s = a !== -1 && o !== -1 && a !== o ? f(
|
|
40
|
+
let r = e.id, i = t.id, a = I.findIndex((e) => e.id === r), o = I.findIndex((e) => e.id === i), s;
|
|
41
|
+
if (s = a !== -1 && o !== -1 && a !== o ? f(I, a, o) : [...I], L(s), x?.(s), n) {
|
|
42
42
|
let e = s.find((e) => e.id === r);
|
|
43
43
|
e && e.status !== n && D?.(e, n, e.status);
|
|
44
44
|
}
|
|
45
45
|
}
|
|
46
|
-
function
|
|
47
|
-
C ?
|
|
46
|
+
function K(e) {
|
|
47
|
+
C ? V({
|
|
48
48
|
mode: "edit",
|
|
49
49
|
task: e
|
|
50
50
|
}) : S?.(e);
|
|
51
51
|
}
|
|
52
|
-
function
|
|
53
|
-
|
|
52
|
+
function q(e) {
|
|
53
|
+
V({
|
|
54
54
|
mode: "add",
|
|
55
55
|
columnId: e
|
|
56
56
|
});
|
|
57
57
|
}
|
|
58
|
-
function
|
|
59
|
-
let t = !
|
|
60
|
-
|
|
58
|
+
function J(e) {
|
|
59
|
+
let t = !I.find((t) => t.id === e.id), n = t ? [...I, e] : I.map((t) => t.id === e.id ? e : t);
|
|
60
|
+
L(n), x?.(n), t ? w?.(e) : T?.(e), V(null);
|
|
61
61
|
}
|
|
62
|
-
function
|
|
63
|
-
let t =
|
|
64
|
-
|
|
62
|
+
function Y(e) {
|
|
63
|
+
let t = I.filter((t) => t.id !== e);
|
|
64
|
+
L(t), x?.(t), E?.(e), V(null);
|
|
65
65
|
}
|
|
66
|
-
function
|
|
67
|
-
|
|
66
|
+
function X(e) {
|
|
67
|
+
V({
|
|
68
68
|
mode: "delete",
|
|
69
69
|
task: e
|
|
70
70
|
});
|
|
@@ -72,17 +72,18 @@ function y({ tasks: y, columns: b, onTasksChange: x, onCardClick: S, enableBuilt
|
|
|
72
72
|
return /* @__PURE__ */ v(m, {
|
|
73
73
|
className: e.root,
|
|
74
74
|
sx: {
|
|
75
|
-
|
|
75
|
+
width: M,
|
|
76
|
+
height: N,
|
|
76
77
|
display: "flex",
|
|
77
78
|
flexDirection: "column",
|
|
78
79
|
overflow: "hidden"
|
|
79
80
|
},
|
|
80
81
|
children: [/* @__PURE__ */ v(a, {
|
|
81
|
-
sensors:
|
|
82
|
+
sensors: H,
|
|
82
83
|
collisionDetection: l,
|
|
83
|
-
onDragStart:
|
|
84
|
-
onDragOver:
|
|
85
|
-
onDragEnd:
|
|
84
|
+
onDragStart: U,
|
|
85
|
+
onDragOver: W,
|
|
86
|
+
onDragEnd: G,
|
|
86
87
|
children: [/* @__PURE__ */ _(m, {
|
|
87
88
|
className: e.columns,
|
|
88
89
|
sx: {
|
|
@@ -92,37 +93,39 @@ function y({ tasks: y, columns: b, onTasksChange: x, onCardClick: S, enableBuilt
|
|
|
92
93
|
p: 2,
|
|
93
94
|
overflowX: "auto",
|
|
94
95
|
overflowY: "hidden",
|
|
95
|
-
alignItems: "
|
|
96
|
+
alignItems: "stretch"
|
|
96
97
|
},
|
|
97
98
|
children: b.map((e) => /* @__PURE__ */ _(i, {
|
|
98
99
|
column: e,
|
|
99
|
-
tasks:
|
|
100
|
+
tasks: I.filter((t) => t.status === e.id),
|
|
100
101
|
showAssignee: O,
|
|
101
102
|
showDueDate: k,
|
|
102
|
-
|
|
103
|
-
|
|
103
|
+
showDueDateWarning: A,
|
|
104
|
+
chipVariant: j,
|
|
105
|
+
t: F,
|
|
104
106
|
enableBuiltinDialogs: C,
|
|
105
|
-
onCardClick:
|
|
106
|
-
onAddClick:
|
|
107
|
+
onCardClick: K,
|
|
108
|
+
onAddClick: q
|
|
107
109
|
}, e.id))
|
|
108
|
-
}), /* @__PURE__ */ _(o, { children:
|
|
109
|
-
task:
|
|
110
|
+
}), /* @__PURE__ */ _(o, { children: R && /* @__PURE__ */ _(n, {
|
|
111
|
+
task: R,
|
|
110
112
|
showAssignee: O,
|
|
111
113
|
showDueDate: k,
|
|
112
|
-
|
|
113
|
-
|
|
114
|
+
showDueDateWarning: A,
|
|
115
|
+
chipVariant: j,
|
|
116
|
+
t: F,
|
|
114
117
|
onCardClick: () => {},
|
|
115
118
|
isOverlay: !0
|
|
116
119
|
}) })]
|
|
117
120
|
}), C && /* @__PURE__ */ _(r, {
|
|
118
|
-
state:
|
|
121
|
+
state: B,
|
|
119
122
|
columns: b,
|
|
120
|
-
t:
|
|
121
|
-
onSave:
|
|
122
|
-
onDelete:
|
|
123
|
-
onRequestDelete:
|
|
124
|
-
onClose: () =>
|
|
125
|
-
},
|
|
123
|
+
t: F,
|
|
124
|
+
onSave: J,
|
|
125
|
+
onDelete: Y,
|
|
126
|
+
onRequestDelete: X,
|
|
127
|
+
onClose: () => V(null)
|
|
128
|
+
}, B ? `${B.mode}-${B.mode === "add" ? B.columnId : B.task.id}` : "closed")]
|
|
126
129
|
});
|
|
127
130
|
}
|
|
128
131
|
//#endregion
|
|
@@ -71,12 +71,21 @@ export type KanbanBoardProps = {
|
|
|
71
71
|
showAssignee?: boolean;
|
|
72
72
|
/** Show the due date on cards (default: true). */
|
|
73
73
|
showDueDate?: boolean;
|
|
74
|
+
/**
|
|
75
|
+
* Highlight cards whose `dueDate` is in the past (default: true).
|
|
76
|
+
* When true, the due-date chip turns red (`color="error"`) and the card
|
|
77
|
+
* receives a subtle red background tint and left border stripe.
|
|
78
|
+
* Has no effect when `showDueDate` is false or when the card has no `dueDate`.
|
|
79
|
+
*/
|
|
80
|
+
showDueDateWarning?: boolean;
|
|
74
81
|
/**
|
|
75
82
|
* MUI Chip variant for assignee and due-date chips on cards.
|
|
76
83
|
* `"outlined"` (default) — subtle border, transparent background.
|
|
77
84
|
* `"filled"` — solid background, more prominent.
|
|
78
85
|
*/
|
|
79
86
|
chipVariant?: "outlined" | "filled";
|
|
87
|
+
/** Width of the board. Default: "100%". */
|
|
88
|
+
width?: number | string;
|
|
80
89
|
/** Height of the board. Default: "100%". */
|
|
81
90
|
height?: number | string;
|
|
82
91
|
/** Override any label or message — unset keys fall back to English defaults. */
|
|
@@ -3,11 +3,12 @@ type KanbanBoardCardProps = {
|
|
|
3
3
|
task: KanbanTask;
|
|
4
4
|
showAssignee: boolean;
|
|
5
5
|
showDueDate: boolean;
|
|
6
|
+
showDueDateWarning: boolean;
|
|
6
7
|
chipVariant: "outlined" | "filled";
|
|
7
8
|
t: Required<KanbanBoardTranslation>;
|
|
8
9
|
onCardClick: (task: KanbanTask) => void;
|
|
9
10
|
/** True when this card is the drag overlay ghost — rendered without transform/listeners. */
|
|
10
11
|
isOverlay?: boolean;
|
|
11
12
|
};
|
|
12
|
-
export declare function KanbanBoardCard({ task, showAssignee, showDueDate, chipVariant, t, onCardClick, isOverlay, }: KanbanBoardCardProps): import("react/jsx-runtime").JSX.Element;
|
|
13
|
+
export declare function KanbanBoardCard({ task, showAssignee, showDueDate, showDueDateWarning, chipVariant, t, onCardClick, isOverlay, }: KanbanBoardCardProps): import("react/jsx-runtime").JSX.Element;
|
|
13
14
|
export {};
|
|
@@ -5,9 +5,10 @@ import { Box as r, Card as i, CardActionArea as a, CardContent as o, Chip as s,
|
|
|
5
5
|
import { CSS as l } from "@dnd-kit/utilities";
|
|
6
6
|
import u from "@mui/icons-material/CalendarToday";
|
|
7
7
|
import d from "@mui/icons-material/Person";
|
|
8
|
-
import {
|
|
8
|
+
import { alpha as f } from "@mui/material/styles";
|
|
9
|
+
import { jsx as p, jsxs as m } from "react/jsx-runtime";
|
|
9
10
|
//#region src/components/kanban-board/KanbanBoardCard.tsx
|
|
10
|
-
var
|
|
11
|
+
var h = {
|
|
11
12
|
fontSize: "0.7rem",
|
|
12
13
|
height: 22,
|
|
13
14
|
"& .MuiChip-icon": {
|
|
@@ -22,78 +23,91 @@ var m = {
|
|
|
22
23
|
pr: "10px"
|
|
23
24
|
}
|
|
24
25
|
};
|
|
25
|
-
function
|
|
26
|
-
let { attributes:
|
|
27
|
-
id:
|
|
28
|
-
disabled:
|
|
29
|
-
}),
|
|
30
|
-
transform: l.Transform.toString(
|
|
31
|
-
transition:
|
|
32
|
-
opacity: +!
|
|
33
|
-
|
|
34
|
-
}, k = g && !!h.assignee || _ && !!h.dueDate, A = h.dueDate ? h.dueDate.toLocaleDateString(void 0, {
|
|
26
|
+
function g({ task: g, showAssignee: _, showDueDate: v, showDueDateWarning: y, chipVariant: b, t: x, onCardClick: S, isOverlay: C = !1 }) {
|
|
27
|
+
let { attributes: w, listeners: T, setNodeRef: E, transform: D, transition: O, isDragging: k } = n({
|
|
28
|
+
id: g.id,
|
|
29
|
+
disabled: C
|
|
30
|
+
}), A = C ? void 0 : {
|
|
31
|
+
transform: l.Transform.toString(D),
|
|
32
|
+
transition: O,
|
|
33
|
+
opacity: +!k
|
|
34
|
+
}, j = _ && !!g.assignee || v && !!g.dueDate, M = g.dueDate ? g.dueDate.toLocaleDateString(void 0, {
|
|
35
35
|
day: "2-digit",
|
|
36
36
|
month: "short",
|
|
37
37
|
year: "numeric"
|
|
38
|
-
}) : null;
|
|
39
|
-
|
|
40
|
-
|
|
41
|
-
|
|
42
|
-
|
|
38
|
+
}) : null, N = /* @__PURE__ */ new Date();
|
|
39
|
+
N.setHours(0, 0, 0, 0);
|
|
40
|
+
let P = y && !!g.dueDate && g.dueDate < N;
|
|
41
|
+
return /* @__PURE__ */ p(i, {
|
|
42
|
+
ref: C ? void 0 : E,
|
|
43
|
+
style: A,
|
|
44
|
+
elevation: 0,
|
|
45
|
+
className: [t.card, k && e.selected].filter(Boolean).join(" "),
|
|
43
46
|
sx: {
|
|
44
47
|
mb: 1,
|
|
45
|
-
|
|
48
|
+
border: "1px solid",
|
|
49
|
+
borderColor: P && !g.color ? "error.light" : "divider",
|
|
50
|
+
borderLeft: g.color ? `4px solid ${g.color}` : P ? (e) => `4px solid ${e.palette.error.main}` : void 0,
|
|
46
51
|
userSelect: "none",
|
|
47
|
-
|
|
52
|
+
cursor: C ? "grabbing" : "grab",
|
|
53
|
+
bgcolor: (e) => P ? e.palette.mode === "dark" ? f(e.palette.error.main, .12) : f(e.palette.error.main, .04) : e.palette.mode === "dark" ? e.palette.grey[800] : e.palette.background.paper,
|
|
54
|
+
boxShadow: (e) => e.palette.mode === "dark" ? "0 1px 3px rgba(0,0,0,0.4)" : "0 1px 3px rgba(0,0,0,0.08)",
|
|
55
|
+
transition: "box-shadow 0.15s ease, transform 0.15s ease",
|
|
56
|
+
...!k && !C && { "&:hover": {
|
|
57
|
+
boxShadow: (e) => e.palette.mode === "dark" ? "0 4px 14px rgba(0,0,0,0.5)" : "0 4px 14px rgba(0,0,0,0.12)",
|
|
58
|
+
transform: "translateY(-1px)"
|
|
59
|
+
} },
|
|
48
60
|
"&:active": { cursor: "grabbing" }
|
|
49
61
|
},
|
|
50
|
-
...
|
|
51
|
-
...
|
|
52
|
-
...
|
|
62
|
+
...C ? {} : {
|
|
63
|
+
...w,
|
|
64
|
+
...T
|
|
53
65
|
},
|
|
54
|
-
onClick: () => !
|
|
55
|
-
"aria-label":
|
|
56
|
-
children: /* @__PURE__ */
|
|
66
|
+
onClick: () => !k && S(g),
|
|
67
|
+
"aria-label": g.title,
|
|
68
|
+
children: /* @__PURE__ */ p(a, {
|
|
57
69
|
component: "div",
|
|
58
70
|
sx: { cursor: "inherit" },
|
|
59
|
-
children: /* @__PURE__ */
|
|
71
|
+
children: /* @__PURE__ */ m(o, {
|
|
60
72
|
sx: {
|
|
61
73
|
p: 1.5,
|
|
62
74
|
"&:last-child": { pb: 1.5 }
|
|
63
75
|
},
|
|
64
|
-
children: [/* @__PURE__ */
|
|
76
|
+
children: [/* @__PURE__ */ p(c, {
|
|
65
77
|
className: t.cardTitle,
|
|
66
78
|
variant: "body2",
|
|
67
79
|
sx: {
|
|
68
|
-
mb: +!!
|
|
80
|
+
mb: +!!j,
|
|
69
81
|
lineHeight: 1.4,
|
|
70
|
-
fontWeight:
|
|
82
|
+
fontWeight: 700,
|
|
83
|
+
letterSpacing: "-0.01em"
|
|
71
84
|
},
|
|
72
|
-
children:
|
|
73
|
-
}),
|
|
85
|
+
children: g.title
|
|
86
|
+
}), j && /* @__PURE__ */ m(r, {
|
|
74
87
|
className: t.cardMeta,
|
|
75
88
|
sx: {
|
|
76
89
|
display: "flex",
|
|
77
|
-
gap:
|
|
90
|
+
gap: 1,
|
|
78
91
|
flexWrap: "wrap",
|
|
79
92
|
alignItems: "center"
|
|
80
93
|
},
|
|
81
|
-
children: [
|
|
94
|
+
children: [_ && g.assignee && /* @__PURE__ */ p(s, {
|
|
82
95
|
className: t.cardAssignee,
|
|
83
|
-
icon: /* @__PURE__ */
|
|
84
|
-
label:
|
|
96
|
+
icon: /* @__PURE__ */ p(d, {}),
|
|
97
|
+
label: g.assignee,
|
|
85
98
|
size: "small",
|
|
86
|
-
variant:
|
|
87
|
-
"aria-label": `${
|
|
88
|
-
sx:
|
|
89
|
-
}),
|
|
99
|
+
variant: b,
|
|
100
|
+
"aria-label": `${x.dialogFieldAssignee}: ${g.assignee}`,
|
|
101
|
+
sx: h
|
|
102
|
+
}), v && M && /* @__PURE__ */ p(s, {
|
|
90
103
|
className: t.cardDueDate,
|
|
91
|
-
icon: /* @__PURE__ */
|
|
92
|
-
label:
|
|
104
|
+
icon: /* @__PURE__ */ p(u, {}),
|
|
105
|
+
label: M,
|
|
93
106
|
size: "small",
|
|
94
|
-
variant:
|
|
95
|
-
"
|
|
96
|
-
|
|
107
|
+
variant: b,
|
|
108
|
+
color: P ? "error" : "default",
|
|
109
|
+
"aria-label": `${x.dialogFieldDueDate}: ${M}`,
|
|
110
|
+
sx: h
|
|
97
111
|
})]
|
|
98
112
|
})]
|
|
99
113
|
})
|
|
@@ -101,4 +115,4 @@ function h({ task: h, showAssignee: g, showDueDate: _, chipVariant: v, t: y, onC
|
|
|
101
115
|
});
|
|
102
116
|
}
|
|
103
117
|
//#endregion
|
|
104
|
-
export {
|
|
118
|
+
export { g as KanbanBoardCard };
|
|
@@ -4,11 +4,12 @@ type KanbanBoardColumnProps = {
|
|
|
4
4
|
tasks: KanbanTask[];
|
|
5
5
|
showAssignee: boolean;
|
|
6
6
|
showDueDate: boolean;
|
|
7
|
+
showDueDateWarning: boolean;
|
|
7
8
|
chipVariant: "outlined" | "filled";
|
|
8
9
|
t: Required<KanbanBoardTranslation>;
|
|
9
10
|
enableBuiltinDialogs: boolean;
|
|
10
11
|
onCardClick: (task: KanbanTask) => void;
|
|
11
12
|
onAddClick: (columnId: string) => void;
|
|
12
13
|
};
|
|
13
|
-
export declare function KanbanBoardColumn({ column, tasks, showAssignee, showDueDate, chipVariant, t, enableBuiltinDialogs, onCardClick, onAddClick, }: KanbanBoardColumnProps): import("react/jsx-runtime").JSX.Element;
|
|
14
|
+
export declare function KanbanBoardColumn({ column, tasks, showAssignee, showDueDate, showDueDateWarning, chipVariant, t, enableBuiltinDialogs, onCardClick, onAddClick, }: KanbanBoardColumnProps): import("react/jsx-runtime").JSX.Element;
|
|
14
15
|
export {};
|
|
@@ -6,8 +6,8 @@ import { Box as a, Button as o, Chip as s, Typography as c } from "@mui/material
|
|
|
6
6
|
import { jsx as l, jsxs as u } from "react/jsx-runtime";
|
|
7
7
|
import d from "@mui/icons-material/Add";
|
|
8
8
|
//#region src/components/kanban-board/KanbanBoardColumn.tsx
|
|
9
|
-
function f({ column: f, tasks: p, showAssignee: m, showDueDate: h,
|
|
10
|
-
let { setNodeRef:
|
|
9
|
+
function f({ column: f, tasks: p, showAssignee: m, showDueDate: h, showDueDateWarning: g, chipVariant: _, t: v, enableBuiltinDialogs: y, onCardClick: b, onAddClick: x }) {
|
|
10
|
+
let { setNodeRef: S, isOver: C } = n({ id: f.id }), w = f.wipLimit !== void 0 && p.length > f.wipLimit, T = f.wipLimit === void 0 ? `${p.length}` : `${p.length} / ${f.wipLimit}`, E = f.color ?? "primary.main";
|
|
11
11
|
return /* @__PURE__ */ u(a, {
|
|
12
12
|
className: e.column,
|
|
13
13
|
sx: {
|
|
@@ -46,13 +46,13 @@ function f({ column: f, tasks: p, showAssignee: m, showDueDate: h, chipVariant:
|
|
|
46
46
|
children: f.label
|
|
47
47
|
}), /* @__PURE__ */ l(s, {
|
|
48
48
|
className: e.columnCount,
|
|
49
|
-
label:
|
|
49
|
+
label: T,
|
|
50
50
|
size: "small",
|
|
51
|
-
color:
|
|
51
|
+
color: w ? "error" : "default",
|
|
52
52
|
sx: {
|
|
53
53
|
height: 20,
|
|
54
54
|
fontSize: "0.7rem",
|
|
55
|
-
...!
|
|
55
|
+
...!w && f.color && {
|
|
56
56
|
bgcolor: f.color,
|
|
57
57
|
color: "#fff"
|
|
58
58
|
}
|
|
@@ -64,17 +64,19 @@ function f({ column: f, tasks: p, showAssignee: m, showDueDate: h, chipVariant:
|
|
|
64
64
|
items: p.map((e) => e.id),
|
|
65
65
|
strategy: i,
|
|
66
66
|
children: /* @__PURE__ */ u(a, {
|
|
67
|
-
ref:
|
|
67
|
+
ref: S,
|
|
68
68
|
className: e.columnBody,
|
|
69
69
|
sx: {
|
|
70
70
|
flex: 1,
|
|
71
71
|
overflowY: "auto",
|
|
72
|
+
scrollbarWidth: "none",
|
|
73
|
+
"&::-webkit-scrollbar": { display: "none" },
|
|
72
74
|
p: 1,
|
|
73
75
|
minHeight: 80,
|
|
74
|
-
bgcolor: (e) =>
|
|
76
|
+
bgcolor: (e) => C ? e.palette.action.selected : e.palette.mode === "dark" ? e.palette.grey[900] : e.palette.grey[100],
|
|
75
77
|
transition: "background-color 0.15s"
|
|
76
78
|
},
|
|
77
|
-
children: [p.length === 0 && !
|
|
79
|
+
children: [p.length === 0 && !C && /* @__PURE__ */ l(c, {
|
|
78
80
|
variant: "caption",
|
|
79
81
|
color: "text.disabled",
|
|
80
82
|
sx: {
|
|
@@ -82,18 +84,19 @@ function f({ column: f, tasks: p, showAssignee: m, showDueDate: h, chipVariant:
|
|
|
82
84
|
textAlign: "center",
|
|
83
85
|
mt: 2
|
|
84
86
|
},
|
|
85
|
-
children:
|
|
87
|
+
children: v.noCardsLabel
|
|
86
88
|
}), p.map((e) => /* @__PURE__ */ l(t, {
|
|
87
89
|
task: e,
|
|
88
90
|
showAssignee: m,
|
|
89
91
|
showDueDate: h,
|
|
90
|
-
|
|
91
|
-
|
|
92
|
-
|
|
92
|
+
showDueDateWarning: g,
|
|
93
|
+
chipVariant: _,
|
|
94
|
+
t: v,
|
|
95
|
+
onCardClick: b
|
|
93
96
|
}, e.id))]
|
|
94
97
|
})
|
|
95
98
|
}),
|
|
96
|
-
|
|
99
|
+
y && /* @__PURE__ */ l(a, {
|
|
97
100
|
sx: {
|
|
98
101
|
p: 1,
|
|
99
102
|
borderTop: "1px solid",
|
|
@@ -104,12 +107,12 @@ function f({ column: f, tasks: p, showAssignee: m, showDueDate: h, chipVariant:
|
|
|
104
107
|
startIcon: /* @__PURE__ */ l(d, {}),
|
|
105
108
|
size: "small",
|
|
106
109
|
fullWidth: !0,
|
|
107
|
-
onClick: () =>
|
|
110
|
+
onClick: () => x(f.id),
|
|
108
111
|
sx: {
|
|
109
112
|
justifyContent: "flex-start",
|
|
110
|
-
color:
|
|
113
|
+
color: E,
|
|
111
114
|
border: "1px dashed",
|
|
112
|
-
borderColor:
|
|
115
|
+
borderColor: E,
|
|
113
116
|
borderRadius: 1,
|
|
114
117
|
py: .75,
|
|
115
118
|
fontWeight: 600,
|
|
@@ -119,7 +122,7 @@ function f({ column: f, tasks: p, showAssignee: m, showDueDate: h, chipVariant:
|
|
|
119
122
|
borderStyle: "dashed"
|
|
120
123
|
}
|
|
121
124
|
},
|
|
122
|
-
children:
|
|
125
|
+
children: v.addCardLabel
|
|
123
126
|
})
|
|
124
127
|
})
|
|
125
128
|
]
|