@devalok/shilp-sutra-karm 0.12.0 → 0.14.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/_chunks/daily-brief.js +134 -85
- package/dist/_chunks/kanban-board.js +635 -590
- package/dist/board/board-column.d.ts +9 -1
- package/dist/board/board-column.d.ts.map +1 -1
- package/dist/board/kanban-board.d.ts.map +1 -1
- package/dist/dashboard/daily-brief.d.ts +5 -0
- package/dist/dashboard/daily-brief.d.ts.map +1 -1
- package/dist/dashboard/index.d.ts +2 -0
- package/dist/dashboard/index.d.ts.map +1 -1
- package/dist/dashboard/index.js +267 -3
- package/dist/dashboard/scratchpad-widget.d.ts +25 -0
- package/dist/dashboard/scratchpad-widget.d.ts.map +1 -0
- package/dist/dashboard/sidebar-scratchpad.d.ts +12 -0
- package/dist/dashboard/sidebar-scratchpad.d.ts.map +1 -0
- package/package.json +1 -1
|
@@ -1,9 +1,17 @@
|
|
|
1
|
-
import { BoardColumn as BoardColumnType } from './board-types';
|
|
1
|
+
import { BoardColumn as BoardColumnType, BoardTask } from './board-types';
|
|
2
2
|
import * as React from 'react';
|
|
3
3
|
export interface BoardColumnProps {
|
|
4
4
|
column: BoardColumnType;
|
|
5
5
|
index: number;
|
|
6
6
|
isOverlay?: boolean;
|
|
7
|
+
/** Preview state for a task being dragged into this column */
|
|
8
|
+
dragPreview?: {
|
|
9
|
+
taskId: string;
|
|
10
|
+
columnId: string;
|
|
11
|
+
index: number;
|
|
12
|
+
};
|
|
13
|
+
/** The task currently being dragged (for silhouette rendering) */
|
|
14
|
+
draggedTask?: BoardTask | null;
|
|
7
15
|
}
|
|
8
16
|
export declare const BoardColumn: React.ForwardRefExoticComponent<BoardColumnProps & React.RefAttributes<HTMLDivElement>>;
|
|
9
17
|
//# sourceMappingURL=board-column.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"board-column.d.ts","sourceRoot":"","sources":["../../src/board/board-column.tsx"],"names":[],"mappings":"AAEA,OAAO,KAAK,KAAK,MAAM,OAAO,CAAA;AAW9B,OAAO,KAAK,EAAE,WAAW,IAAI,eAAe,EAAE,MAAM,eAAe,CAAA;
|
|
1
|
+
{"version":3,"file":"board-column.d.ts","sourceRoot":"","sources":["../../src/board/board-column.tsx"],"names":[],"mappings":"AAEA,OAAO,KAAK,KAAK,MAAM,OAAO,CAAA;AAW9B,OAAO,KAAK,EAAE,WAAW,IAAI,eAAe,EAAE,SAAS,EAAE,MAAM,eAAe,CAAA;AAM9E,MAAM,WAAW,gBAAgB;IAC/B,MAAM,EAAE,eAAe,CAAA;IACvB,KAAK,EAAE,MAAM,CAAA;IACb,SAAS,CAAC,EAAE,OAAO,CAAA;IACnB,8DAA8D;IAC9D,WAAW,CAAC,EAAE;QAAE,MAAM,EAAE,MAAM,CAAC;QAAC,QAAQ,EAAE,MAAM,CAAC;QAAC,KAAK,EAAE,MAAM,CAAA;KAAE,CAAA;IACjE,kEAAkE;IAClE,WAAW,CAAC,EAAE,SAAS,GAAG,IAAI,CAAA;CAC/B;AAsBD,eAAO,MAAM,WAAW,yFA+EvB,CAAA"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"kanban-board.d.ts","sourceRoot":"","sources":["../../src/board/kanban-board.tsx"],"names":[],"mappings":"AAEA,OAAO,KAAK,KAAK,MAAM,OAAO,CAAA;AAuB9B,OAAO,EAAkC,KAAK,kBAAkB,EAAE,MAAM,iBAAiB,CAAA;AAkDzF,MAAM,WAAW,gBAAiB,SAAQ,IAAI,CAAC,kBAAkB,EAAE,UAAU,CAAC;IAC5E,iDAAiD;IACjD,SAAS,CAAC,EAAE,MAAM,CAAA;CACnB;
|
|
1
|
+
{"version":3,"file":"kanban-board.d.ts","sourceRoot":"","sources":["../../src/board/kanban-board.tsx"],"names":[],"mappings":"AAEA,OAAO,KAAK,KAAK,MAAM,OAAO,CAAA;AAuB9B,OAAO,EAAkC,KAAK,kBAAkB,EAAE,MAAM,iBAAiB,CAAA;AAkDzF,MAAM,WAAW,gBAAiB,SAAQ,IAAI,CAAC,kBAAkB,EAAE,UAAU,CAAC;IAC5E,iDAAiD;IACjD,SAAS,CAAC,EAAE,MAAM,CAAA;CACnB;AAgPD,eAAO,MAAM,WAAW,yFAcvB,CAAA"}
|
|
@@ -6,6 +6,11 @@ export interface BriefData {
|
|
|
6
6
|
export interface DailyBriefProps {
|
|
7
7
|
data: BriefData | null;
|
|
8
8
|
loading?: boolean;
|
|
9
|
+
onRefresh?: () => void;
|
|
10
|
+
unavailable?: boolean;
|
|
11
|
+
collapsible?: boolean;
|
|
12
|
+
defaultCollapsed?: boolean;
|
|
13
|
+
title?: string;
|
|
9
14
|
className?: string;
|
|
10
15
|
}
|
|
11
16
|
declare const DailyBrief: React.ForwardRefExoticComponent<DailyBriefProps & React.RefAttributes<HTMLDivElement>>;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"daily-brief.d.ts","sourceRoot":"","sources":["../../src/dashboard/daily-brief.tsx"],"names":[],"mappings":"AAEA,OAAO,KAAK,KAAK,MAAM,OAAO,CAAA;AAU9B,MAAM,WAAW,SAAS;IACxB,KAAK,EAAE,MAAM,EAAE,CAAA;IACf,WAAW,EAAE,MAAM,CAAA;CACpB;AAED,MAAM,WAAW,eAAe;IAC9B,IAAI,EAAE,SAAS,GAAG,IAAI,CAAA;IACtB,OAAO,CAAC,EAAE,OAAO,CAAA;IACjB,SAAS,CAAC,EAAE,MAAM,CAAA;CACnB;
|
|
1
|
+
{"version":3,"file":"daily-brief.d.ts","sourceRoot":"","sources":["../../src/dashboard/daily-brief.tsx"],"names":[],"mappings":"AAEA,OAAO,KAAK,KAAK,MAAM,OAAO,CAAA;AAU9B,MAAM,WAAW,SAAS;IACxB,KAAK,EAAE,MAAM,EAAE,CAAA;IACf,WAAW,EAAE,MAAM,CAAA;CACpB;AAED,MAAM,WAAW,eAAe;IAC9B,IAAI,EAAE,SAAS,GAAG,IAAI,CAAA;IACtB,OAAO,CAAC,EAAE,OAAO,CAAA;IACjB,SAAS,CAAC,EAAE,MAAM,IAAI,CAAA;IACtB,WAAW,CAAC,EAAE,OAAO,CAAA;IACrB,WAAW,CAAC,EAAE,OAAO,CAAA;IACrB,gBAAgB,CAAC,EAAE,OAAO,CAAA;IAC1B,KAAK,CAAC,EAAE,MAAM,CAAA;IACd,SAAS,CAAC,EAAE,MAAM,CAAA;CACnB;AA+BD,QAAA,MAAM,UAAU,wFAkHf,CAAA;AAID,OAAO,EAAE,UAAU,EAAE,CAAA"}
|
|
@@ -1,3 +1,5 @@
|
|
|
1
1
|
export { AttendanceCTA, type AttendanceCTAProps } from './attendance-cta';
|
|
2
2
|
export { DailyBrief, type BriefData, type DailyBriefProps } from './daily-brief';
|
|
3
|
+
export { ScratchpadWidget, type ScratchpadItem, type ScratchpadWidgetProps } from './scratchpad-widget';
|
|
4
|
+
export { SidebarScratchpad, type SidebarScratchpadProps } from './sidebar-scratchpad';
|
|
3
5
|
//# sourceMappingURL=index.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../src/dashboard/index.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,aAAa,EAAE,KAAK,kBAAkB,EAAE,MAAM,kBAAkB,CAAA;AACzE,OAAO,EAAE,UAAU,EAAE,KAAK,SAAS,EAAE,KAAK,eAAe,EAAE,MAAM,eAAe,CAAA"}
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../src/dashboard/index.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,aAAa,EAAE,KAAK,kBAAkB,EAAE,MAAM,kBAAkB,CAAA;AACzE,OAAO,EAAE,UAAU,EAAE,KAAK,SAAS,EAAE,KAAK,eAAe,EAAE,MAAM,eAAe,CAAA;AAChF,OAAO,EAAE,gBAAgB,EAAE,KAAK,cAAc,EAAE,KAAK,qBAAqB,EAAE,MAAM,qBAAqB,CAAA;AACvG,OAAO,EAAE,iBAAiB,EAAE,KAAK,sBAAsB,EAAE,MAAM,sBAAsB,CAAA"}
|
package/dist/dashboard/index.js
CHANGED
|
@@ -1,6 +1,270 @@
|
|
|
1
1
|
"use client";
|
|
2
|
-
import { A as
|
|
2
|
+
import { A as Q, D as V } from "../_chunks/daily-brief.js";
|
|
3
|
+
import { jsxs as s, jsx as e } from "react/jsx-runtime";
|
|
4
|
+
import * as I from "react";
|
|
5
|
+
import { useState as v, useRef as W, useEffect as _ } from "react";
|
|
6
|
+
import { IconX as $, IconChevronDown as B } from "@tabler/icons-react";
|
|
7
|
+
import { cn as l } from "@devalok/shilp-sutra/ui/lib/utils";
|
|
8
|
+
import { Checkbox as A } from "@devalok/shilp-sutra/ui/checkbox";
|
|
9
|
+
import { Input as G } from "@devalok/shilp-sutra/ui/input";
|
|
10
|
+
import { Button as M } from "@devalok/shilp-sutra/ui/button";
|
|
11
|
+
const d = 20, w = 2, k = (d - w) / 2, D = 2 * Math.PI * k;
|
|
12
|
+
function K({ count: h, max: a, allDone: n }) {
|
|
13
|
+
const i = a > 0 ? h / a : 0, o = D * (1 - i);
|
|
14
|
+
return /* @__PURE__ */ s("div", { className: l("relative flex items-center justify-center", n && "animate-[scale-pulse_300ms_ease-out]"), children: [
|
|
15
|
+
/* @__PURE__ */ s("svg", { width: d, height: d, viewBox: `0 0 ${d} ${d}`, className: "-rotate-90", children: [
|
|
16
|
+
/* @__PURE__ */ e(
|
|
17
|
+
"circle",
|
|
18
|
+
{
|
|
19
|
+
cx: d / 2,
|
|
20
|
+
cy: d / 2,
|
|
21
|
+
r: k,
|
|
22
|
+
fill: "none",
|
|
23
|
+
strokeWidth: w,
|
|
24
|
+
className: "stroke-layer-02"
|
|
25
|
+
}
|
|
26
|
+
),
|
|
27
|
+
/* @__PURE__ */ e(
|
|
28
|
+
"circle",
|
|
29
|
+
{
|
|
30
|
+
cx: d / 2,
|
|
31
|
+
cy: d / 2,
|
|
32
|
+
r: k,
|
|
33
|
+
fill: "none",
|
|
34
|
+
strokeWidth: w,
|
|
35
|
+
strokeLinecap: "round",
|
|
36
|
+
strokeDasharray: D,
|
|
37
|
+
strokeDashoffset: o,
|
|
38
|
+
className: l(
|
|
39
|
+
"transition-all duration-300",
|
|
40
|
+
n ? "stroke-success" : "stroke-interactive"
|
|
41
|
+
)
|
|
42
|
+
}
|
|
43
|
+
)
|
|
44
|
+
] }),
|
|
45
|
+
/* @__PURE__ */ s("span", { className: "absolute text-[8px] font-medium text-text-secondary", "data-testid": "progress-count", children: [
|
|
46
|
+
h,
|
|
47
|
+
"/",
|
|
48
|
+
a
|
|
49
|
+
] })
|
|
50
|
+
] });
|
|
51
|
+
}
|
|
52
|
+
const z = I.forwardRef(
|
|
53
|
+
function({
|
|
54
|
+
items: a,
|
|
55
|
+
maxItems: n = 5,
|
|
56
|
+
onToggle: i,
|
|
57
|
+
onAdd: o,
|
|
58
|
+
onDelete: f,
|
|
59
|
+
title: m = "My Scratchpad",
|
|
60
|
+
resetLabel: c,
|
|
61
|
+
emptyText: u = "Nothing here yet. Add a task!",
|
|
62
|
+
emptyIcon: r,
|
|
63
|
+
loading: g = !1,
|
|
64
|
+
className: S
|
|
65
|
+
}, R) {
|
|
66
|
+
const [p, y] = v(!1), [N, x] = v(""), b = W(null), j = a.length > 0 && a.every((t) => t.done);
|
|
67
|
+
_(() => {
|
|
68
|
+
p && b.current && b.current.focus();
|
|
69
|
+
}, [p]);
|
|
70
|
+
function C() {
|
|
71
|
+
const t = N.trim();
|
|
72
|
+
t && (o(t), x(""));
|
|
73
|
+
}
|
|
74
|
+
function E(t) {
|
|
75
|
+
t.key === "Enter" ? (t.preventDefault(), C()) : t.key === "Escape" && (y(!1), x(""));
|
|
76
|
+
}
|
|
77
|
+
return g ? /* @__PURE__ */ s(
|
|
78
|
+
"div",
|
|
79
|
+
{
|
|
80
|
+
ref: R,
|
|
81
|
+
className: l(
|
|
82
|
+
"flex flex-col gap-ds-04 rounded-ds-2xl border border-border bg-layer-01 shadow-01 p-ds-05b",
|
|
83
|
+
S
|
|
84
|
+
),
|
|
85
|
+
children: [
|
|
86
|
+
/* @__PURE__ */ s("div", { className: "flex items-center justify-between", children: [
|
|
87
|
+
/* @__PURE__ */ e("div", { className: "h-4 w-28 animate-pulse rounded bg-layer-02" }),
|
|
88
|
+
/* @__PURE__ */ e("div", { className: "h-5 w-5 animate-pulse rounded-full bg-layer-02" })
|
|
89
|
+
] }),
|
|
90
|
+
[1, 2, 3].map((t) => /* @__PURE__ */ s("div", { className: "flex items-center gap-ds-03", children: [
|
|
91
|
+
/* @__PURE__ */ e("div", { className: "h-ico-md w-ico-md shrink-0 animate-pulse rounded-ds-sm bg-layer-02" }),
|
|
92
|
+
/* @__PURE__ */ e(
|
|
93
|
+
"div",
|
|
94
|
+
{
|
|
95
|
+
className: "h-4 animate-pulse rounded bg-layer-02",
|
|
96
|
+
style: { width: `${50 + t * 12}%` }
|
|
97
|
+
}
|
|
98
|
+
)
|
|
99
|
+
] }, t))
|
|
100
|
+
]
|
|
101
|
+
}
|
|
102
|
+
) : /* @__PURE__ */ s(
|
|
103
|
+
"div",
|
|
104
|
+
{
|
|
105
|
+
ref: R,
|
|
106
|
+
className: l(
|
|
107
|
+
"flex flex-col rounded-ds-2xl border border-border bg-layer-01 shadow-01",
|
|
108
|
+
S
|
|
109
|
+
),
|
|
110
|
+
children: [
|
|
111
|
+
/* @__PURE__ */ s("div", { className: "flex items-center justify-between px-ds-05b py-ds-05", children: [
|
|
112
|
+
/* @__PURE__ */ e("span", { className: "text-ds-base font-semibold text-text-primary", children: m }),
|
|
113
|
+
/* @__PURE__ */ e(K, { count: a.length, max: n, allDone: j })
|
|
114
|
+
] }),
|
|
115
|
+
/* @__PURE__ */ s("div", { className: "flex flex-col border-t border-border px-ds-05b pb-ds-04 pt-ds-04", children: [
|
|
116
|
+
a.length === 0 && !p ? /* @__PURE__ */ s("div", { className: "flex flex-col items-center justify-center gap-ds-03 py-ds-06 text-center", children: [
|
|
117
|
+
r && /* @__PURE__ */ e(r, { className: "h-ico-lg w-ico-lg text-text-placeholder" }),
|
|
118
|
+
/* @__PURE__ */ e("span", { className: "text-ds-md text-text-placeholder", children: u })
|
|
119
|
+
] }) : /* @__PURE__ */ e("div", { className: "flex flex-col gap-ds-02b", children: a.map((t) => /* @__PURE__ */ s(
|
|
120
|
+
"div",
|
|
121
|
+
{
|
|
122
|
+
className: "group flex items-center gap-ds-03 rounded-ds-md px-ds-02 py-ds-02 transition-colors hover:bg-layer-02",
|
|
123
|
+
children: [
|
|
124
|
+
/* @__PURE__ */ e(
|
|
125
|
+
A,
|
|
126
|
+
{
|
|
127
|
+
checked: t.done,
|
|
128
|
+
onCheckedChange: (T) => i(t.id, T === !0),
|
|
129
|
+
"aria-label": `Toggle ${t.text}`
|
|
130
|
+
}
|
|
131
|
+
),
|
|
132
|
+
/* @__PURE__ */ e(
|
|
133
|
+
"span",
|
|
134
|
+
{
|
|
135
|
+
className: l(
|
|
136
|
+
"flex-1 text-ds-md transition-all duration-200 ease-in-out",
|
|
137
|
+
t.done && "text-text-placeholder line-through"
|
|
138
|
+
),
|
|
139
|
+
children: t.text
|
|
140
|
+
}
|
|
141
|
+
),
|
|
142
|
+
/* @__PURE__ */ e(
|
|
143
|
+
"button",
|
|
144
|
+
{
|
|
145
|
+
type: "button",
|
|
146
|
+
onClick: () => f(t.id),
|
|
147
|
+
"aria-label": `Delete ${t.text}`,
|
|
148
|
+
className: "flex h-ico-md w-ico-md items-center justify-center rounded-ds-sm opacity-0 transition-opacity group-hover:opacity-100 group-focus-within:opacity-100 hover:bg-layer-03",
|
|
149
|
+
children: /* @__PURE__ */ e($, { className: "h-3 w-3 text-text-placeholder" })
|
|
150
|
+
}
|
|
151
|
+
)
|
|
152
|
+
]
|
|
153
|
+
},
|
|
154
|
+
t.id
|
|
155
|
+
)) }),
|
|
156
|
+
a.length < n && /* @__PURE__ */ e("div", { className: "mt-ds-02b", children: p ? /* @__PURE__ */ s("div", { className: "flex items-center gap-ds-03", children: [
|
|
157
|
+
/* @__PURE__ */ e(
|
|
158
|
+
G,
|
|
159
|
+
{
|
|
160
|
+
ref: b,
|
|
161
|
+
size: "sm",
|
|
162
|
+
value: N,
|
|
163
|
+
onChange: (t) => x(t.target.value),
|
|
164
|
+
onKeyDown: E,
|
|
165
|
+
onBlur: () => {
|
|
166
|
+
N.trim() || (y(!1), x(""));
|
|
167
|
+
},
|
|
168
|
+
placeholder: "What needs doing?",
|
|
169
|
+
className: "flex-1"
|
|
170
|
+
}
|
|
171
|
+
),
|
|
172
|
+
/* @__PURE__ */ e(
|
|
173
|
+
M,
|
|
174
|
+
{
|
|
175
|
+
size: "sm",
|
|
176
|
+
onClick: C,
|
|
177
|
+
onMouseDown: (t) => t.preventDefault(),
|
|
178
|
+
children: "Add"
|
|
179
|
+
}
|
|
180
|
+
)
|
|
181
|
+
] }) : /* @__PURE__ */ e(
|
|
182
|
+
"button",
|
|
183
|
+
{
|
|
184
|
+
type: "button",
|
|
185
|
+
onClick: () => y(!0),
|
|
186
|
+
className: "w-full rounded-ds-md px-ds-02 py-ds-02 text-left text-ds-md text-text-placeholder transition-colors hover:bg-layer-02",
|
|
187
|
+
children: "+ Add a task..."
|
|
188
|
+
}
|
|
189
|
+
) }),
|
|
190
|
+
c && /* @__PURE__ */ e("span", { className: "mt-ds-03 text-ds-xs text-text-placeholder", children: c })
|
|
191
|
+
] })
|
|
192
|
+
]
|
|
193
|
+
}
|
|
194
|
+
);
|
|
195
|
+
}
|
|
196
|
+
);
|
|
197
|
+
z.displayName = "ScratchpadWidget";
|
|
198
|
+
const O = I.forwardRef(
|
|
199
|
+
function({ items: a, onToggle: n, defaultOpen: i = !0, badgeCount: o, className: f }, m) {
|
|
200
|
+
const [c, u] = v(i);
|
|
201
|
+
return /* @__PURE__ */ s("div", { ref: m, className: l("flex flex-col", f), children: [
|
|
202
|
+
/* @__PURE__ */ s(
|
|
203
|
+
"button",
|
|
204
|
+
{
|
|
205
|
+
type: "button",
|
|
206
|
+
onClick: () => u((r) => !r),
|
|
207
|
+
"aria-expanded": c,
|
|
208
|
+
className: "flex w-full items-center gap-ds-02 px-ds-03 py-ds-02 text-left text-ds-xs font-semibold text-text-secondary transition-colors hover:bg-layer-02",
|
|
209
|
+
children: [
|
|
210
|
+
/* @__PURE__ */ e(
|
|
211
|
+
B,
|
|
212
|
+
{
|
|
213
|
+
className: l(
|
|
214
|
+
"h-3.5 w-3.5 shrink-0 transition-transform duration-200",
|
|
215
|
+
!c && "-rotate-180"
|
|
216
|
+
)
|
|
217
|
+
}
|
|
218
|
+
),
|
|
219
|
+
/* @__PURE__ */ e("span", { className: "flex-1", children: "Scratchpad" }),
|
|
220
|
+
o != null && o > 0 && /* @__PURE__ */ e("span", { className: "rounded-full bg-layer-02 px-1.5 text-ds-xs text-text-secondary", children: o })
|
|
221
|
+
]
|
|
222
|
+
}
|
|
223
|
+
),
|
|
224
|
+
/* @__PURE__ */ e(
|
|
225
|
+
"div",
|
|
226
|
+
{
|
|
227
|
+
className: l(
|
|
228
|
+
"grid transition-[grid-template-rows] duration-200",
|
|
229
|
+
c ? "grid-rows-[1fr]" : "grid-rows-[0fr]"
|
|
230
|
+
),
|
|
231
|
+
children: /* @__PURE__ */ e("div", { className: "overflow-hidden", children: /* @__PURE__ */ e("div", { className: "flex flex-col gap-0.5 px-ds-03 pb-ds-02", children: a.map((r) => /* @__PURE__ */ s(
|
|
232
|
+
"label",
|
|
233
|
+
{
|
|
234
|
+
className: "flex cursor-pointer items-center gap-ds-02 rounded-ds-sm px-ds-02 py-0.5 transition-colors hover:bg-layer-02",
|
|
235
|
+
children: [
|
|
236
|
+
/* @__PURE__ */ e(
|
|
237
|
+
A,
|
|
238
|
+
{
|
|
239
|
+
checked: r.done,
|
|
240
|
+
onCheckedChange: (g) => n(r.id, g === !0),
|
|
241
|
+
"aria-label": `Toggle ${r.text}`,
|
|
242
|
+
className: "h-3.5 w-3.5"
|
|
243
|
+
}
|
|
244
|
+
),
|
|
245
|
+
/* @__PURE__ */ e(
|
|
246
|
+
"span",
|
|
247
|
+
{
|
|
248
|
+
className: l(
|
|
249
|
+
"flex-1 text-xs transition-all duration-200",
|
|
250
|
+
r.done ? "text-text-placeholder line-through" : "text-text-primary"
|
|
251
|
+
),
|
|
252
|
+
children: r.text
|
|
253
|
+
}
|
|
254
|
+
)
|
|
255
|
+
]
|
|
256
|
+
},
|
|
257
|
+
r.id
|
|
258
|
+
)) }) })
|
|
259
|
+
}
|
|
260
|
+
)
|
|
261
|
+
] });
|
|
262
|
+
}
|
|
263
|
+
);
|
|
264
|
+
O.displayName = "SidebarScratchpad";
|
|
3
265
|
export {
|
|
4
|
-
|
|
5
|
-
|
|
266
|
+
Q as AttendanceCTA,
|
|
267
|
+
V as DailyBrief,
|
|
268
|
+
z as ScratchpadWidget,
|
|
269
|
+
O as SidebarScratchpad
|
|
6
270
|
};
|
|
@@ -0,0 +1,25 @@
|
|
|
1
|
+
import * as React from 'react';
|
|
2
|
+
export interface ScratchpadItem {
|
|
3
|
+
id: string;
|
|
4
|
+
text: string;
|
|
5
|
+
done: boolean;
|
|
6
|
+
}
|
|
7
|
+
export interface ScratchpadWidgetProps {
|
|
8
|
+
items: ScratchpadItem[];
|
|
9
|
+
maxItems?: number;
|
|
10
|
+
onToggle: (id: string, done: boolean) => void;
|
|
11
|
+
onAdd: (text: string) => void;
|
|
12
|
+
onDelete: (id: string) => void;
|
|
13
|
+
onReorder?: (items: ScratchpadItem[]) => void;
|
|
14
|
+
title?: string;
|
|
15
|
+
resetLabel?: string;
|
|
16
|
+
emptyText?: string;
|
|
17
|
+
emptyIcon?: React.ComponentType<{
|
|
18
|
+
className?: string;
|
|
19
|
+
}>;
|
|
20
|
+
loading?: boolean;
|
|
21
|
+
className?: string;
|
|
22
|
+
}
|
|
23
|
+
declare const ScratchpadWidget: React.ForwardRefExoticComponent<ScratchpadWidgetProps & React.RefAttributes<HTMLDivElement>>;
|
|
24
|
+
export { ScratchpadWidget };
|
|
25
|
+
//# sourceMappingURL=scratchpad-widget.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"scratchpad-widget.d.ts","sourceRoot":"","sources":["../../src/dashboard/scratchpad-widget.tsx"],"names":[],"mappings":"AAEA,OAAO,KAAK,KAAK,MAAM,OAAO,CAAA;AAY9B,MAAM,WAAW,cAAc;IAC7B,EAAE,EAAE,MAAM,CAAA;IACV,IAAI,EAAE,MAAM,CAAA;IACZ,IAAI,EAAE,OAAO,CAAA;CACd;AAED,MAAM,WAAW,qBAAqB;IACpC,KAAK,EAAE,cAAc,EAAE,CAAA;IACvB,QAAQ,CAAC,EAAE,MAAM,CAAA;IACjB,QAAQ,EAAE,CAAC,EAAE,EAAE,MAAM,EAAE,IAAI,EAAE,OAAO,KAAK,IAAI,CAAA;IAC7C,KAAK,EAAE,CAAC,IAAI,EAAE,MAAM,KAAK,IAAI,CAAA;IAC7B,QAAQ,EAAE,CAAC,EAAE,EAAE,MAAM,KAAK,IAAI,CAAA;IAC9B,SAAS,CAAC,EAAE,CAAC,KAAK,EAAE,cAAc,EAAE,KAAK,IAAI,CAAA;IAC7C,KAAK,CAAC,EAAE,MAAM,CAAA;IACd,UAAU,CAAC,EAAE,MAAM,CAAA;IACnB,SAAS,CAAC,EAAE,MAAM,CAAA;IAClB,SAAS,CAAC,EAAE,KAAK,CAAC,aAAa,CAAC;QAAE,SAAS,CAAC,EAAE,MAAM,CAAA;KAAE,CAAC,CAAA;IACvD,OAAO,CAAC,EAAE,OAAO,CAAA;IACjB,SAAS,CAAC,EAAE,MAAM,CAAA;CACnB;AAoDD,QAAA,MAAM,gBAAgB,8FAiLrB,CAAA;AAID,OAAO,EAAE,gBAAgB,EAAE,CAAA"}
|
|
@@ -0,0 +1,12 @@
|
|
|
1
|
+
import { ScratchpadItem } from './scratchpad-widget';
|
|
2
|
+
import * as React from 'react';
|
|
3
|
+
export interface SidebarScratchpadProps {
|
|
4
|
+
items: ScratchpadItem[];
|
|
5
|
+
onToggle: (id: string, done: boolean) => void;
|
|
6
|
+
defaultOpen?: boolean;
|
|
7
|
+
badgeCount?: number;
|
|
8
|
+
className?: string;
|
|
9
|
+
}
|
|
10
|
+
declare const SidebarScratchpad: React.ForwardRefExoticComponent<SidebarScratchpadProps & React.RefAttributes<HTMLDivElement>>;
|
|
11
|
+
export { SidebarScratchpad };
|
|
12
|
+
//# sourceMappingURL=sidebar-scratchpad.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"sidebar-scratchpad.d.ts","sourceRoot":"","sources":["../../src/dashboard/sidebar-scratchpad.tsx"],"names":[],"mappings":"AAEA,OAAO,KAAK,KAAK,MAAM,OAAO,CAAA;AAK9B,OAAO,KAAK,EAAE,cAAc,EAAE,MAAM,qBAAqB,CAAA;AAMzD,MAAM,WAAW,sBAAsB;IACrC,KAAK,EAAE,cAAc,EAAE,CAAA;IACvB,QAAQ,EAAE,CAAC,EAAE,EAAE,MAAM,EAAE,IAAI,EAAE,OAAO,KAAK,IAAI,CAAA;IAC7C,WAAW,CAAC,EAAE,OAAO,CAAA;IACrB,UAAU,CAAC,EAAE,MAAM,CAAA;IACnB,SAAS,CAAC,EAAE,MAAM,CAAA;CACnB;AAMD,QAAA,MAAM,iBAAiB,+FAkEtB,CAAA;AAID,OAAO,EAAE,iBAAiB,EAAE,CAAA"}
|