@burdenoff/microfe-timecampus 2026.1206.1 → 2026.1206.2

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (39) hide show
  1. package/dist/timecampus/components/DateFields.d.ts +53 -0
  2. package/dist/timecampus/components/DateFields.js +87 -0
  3. package/dist/timecampus/components/DateFields.js.map +1 -0
  4. package/dist/timecampus/components/dateFieldValues.d.ts +39 -0
  5. package/dist/timecampus/components/dateFieldValues.js +49 -0
  6. package/dist/timecampus/components/dateFieldValues.js.map +1 -0
  7. package/dist/timecampus/pages/email-tracking/EmailTrackingPage.js +112 -111
  8. package/dist/timecampus/pages/email-tracking/EmailTrackingPage.js.map +1 -1
  9. package/dist/timecampus/pages/expense-tracking/ExpenseTrackingPage.js +65 -65
  10. package/dist/timecampus/pages/expense-tracking/ExpenseTrackingPage.js.map +1 -1
  11. package/dist/timecampus/pages/focus/FocusProtectionPage.js +250 -253
  12. package/dist/timecampus/pages/focus/FocusProtectionPage.js.map +1 -1
  13. package/dist/timecampus/pages/invoicing/InvoicingPage.js +259 -258
  14. package/dist/timecampus/pages/invoicing/InvoicingPage.js.map +1 -1
  15. package/dist/timecampus/pages/lifetime/FiniteLifePage.js +103 -103
  16. package/dist/timecampus/pages/lifetime/FiniteLifePage.js.map +1 -1
  17. package/dist/timecampus/pages/lifetime/LifeTimelinePage.js +38 -38
  18. package/dist/timecampus/pages/lifetime/LifeTimelinePage.js.map +1 -1
  19. package/dist/timecampus/pages/location-tracking/LocationTrackingPage.js +218 -216
  20. package/dist/timecampus/pages/location-tracking/LocationTrackingPage.js.map +1 -1
  21. package/dist/timecampus/pages/meetings/ActionItemFormModal.js +64 -63
  22. package/dist/timecampus/pages/meetings/ActionItemFormModal.js.map +1 -1
  23. package/dist/timecampus/pages/meetings/MeetingCreatePage.js +54 -54
  24. package/dist/timecampus/pages/meetings/MeetingCreatePage.js.map +1 -1
  25. package/dist/timecampus/pages/meetings/MeetingFormModal.js +98 -96
  26. package/dist/timecampus/pages/meetings/MeetingFormModal.js.map +1 -1
  27. package/dist/timecampus/pages/pomodoro/PomodoroPage.js +150 -149
  28. package/dist/timecampus/pages/pomodoro/PomodoroPage.js.map +1 -1
  29. package/dist/timecampus/pages/projects/TasksPage.js +183 -182
  30. package/dist/timecampus/pages/projects/TasksPage.js.map +1 -1
  31. package/dist/timecampus/pages/resource-planning/ResourcePlanningPage.js +346 -351
  32. package/dist/timecampus/pages/resource-planning/ResourcePlanningPage.js.map +1 -1
  33. package/dist/timecampus/pages/time/TimeEntriesPage.js +129 -127
  34. package/dist/timecampus/pages/time/TimeEntriesPage.js.map +1 -1
  35. package/dist/timecampus/pages/time-approval/SubmitTimesheetModal.js +46 -47
  36. package/dist/timecampus/pages/time-approval/SubmitTimesheetModal.js.map +1 -1
  37. package/dist/timecampus/pages/timeline/TimelinePage.js +231 -231
  38. package/dist/timecampus/pages/timeline/TimelinePage.js.map +1 -1
  39. package/package.json +1 -1
@@ -9,46 +9,47 @@ import { useCompletePomodoroSessionMutation as ie, useCreatePomodoroGoalMutation
9
9
  import "../../analytics/index.js";
10
10
  import { PomodoroGoalType as i, PomodoroSessionOrderByField as he, PomodoroSessionType as a, TimeCampusSortDirection as ge } from "../../../generated/wspace-types.js";
11
11
  import { durationForSession as _e, nextSessionAfter as o } from "./pomodoroDuration.js";
12
- import { useCallback as s, useEffect as c, useRef as ve, useState as l } from "react";
12
+ import { DateField as s } from "../../components/DateFields.js";
13
+ import { useCallback as c, useEffect as l, useRef as ve, useState as u } from "react";
13
14
  import { Pause as ye, Pencil as be, Play as xe, Plus as Se, RotateCcw as Ce, SkipForward as we, Target as Te, Trash2 as Ee } from "lucide-react";
14
- import { Fragment as u, jsx as d, jsxs as f } from "react/jsx-runtime";
15
- import { GlassCard as p, NextSteps as De, ThemedSelect as Oe } from "@burdenoff/fe-libs/ui";
15
+ import { Fragment as d, jsx as f, jsxs as p } from "react/jsx-runtime";
16
+ import { GlassCard as m, NextSteps as De, ThemedSelect as Oe } from "@burdenoff/fe-libs/ui";
16
17
  // src/timecampus/pages/pomodoro/PomodoroPage.tsx
17
- var m = "mt-1 w-full rounded-md border border-border-subtle bg-bg-surface px-3 py-2 text-sm text-text-primary placeholder:text-text-secondary", h = "block text-sm font-medium text-text-primary";
18
- function g(e) {
18
+ var h = "mt-1 w-full rounded-md border border-border-subtle bg-bg-surface px-3 py-2 text-sm text-text-primary placeholder:text-text-secondary", g = "block text-sm font-medium text-text-primary";
19
+ function _(e) {
19
20
  let t = new Date(e);
20
21
  return Number.isNaN(t.getTime()) ? "" : (/* @__PURE__ */ new Date(t.getTime() - t.getTimezoneOffset() * 6e4)).toISOString().slice(0, 10);
21
22
  }
22
- function _() {
23
+ function v() {
23
24
  let e = /* @__PURE__ */ new Date();
24
25
  return (/* @__PURE__ */ new Date(e.getTime() - e.getTimezoneOffset() * 6e4)).toISOString().slice(0, 10);
25
26
  }
26
- function v(e) {
27
+ function y(e) {
27
28
  let t = /* @__PURE__ */ new Date();
28
29
  return t.setDate(t.getDate() + e), (/* @__PURE__ */ new Date(t.getTime() - t.getTimezoneOffset() * 6e4)).toISOString().slice(0, 10);
29
30
  }
30
- function y(e) {
31
+ function b(e) {
31
32
  return {
32
33
  type: e?.type ?? i.Daily,
33
34
  target: e?.target == null ? "8" : String(e.target),
34
35
  period: e?.period ?? "DAILY",
35
- startDate: e?.startDate ? g(e.startDate) : _(),
36
- endDate: e?.endDate ? g(e.endDate) : v(0)
36
+ startDate: e?.startDate ? _(e.startDate) : v(),
37
+ endDate: e?.endDate ? _(e.endDate) : y(0)
37
38
  };
38
39
  }
39
- function b() {
40
- let { workspaceId: g = "" } = ne(), _ = re(), { data: b, loading: ke, error: Ae } = le({
41
- variables: { workspaceId: g },
42
- skip: !g
40
+ function x() {
41
+ let { workspaceId: _ = "" } = ne(), v = re(), { data: x, loading: ke, error: Ae } = le({
42
+ variables: { workspaceId: _ },
43
+ skip: !_
43
44
  }), { data: je, loading: Me, error: Ne } = se({
44
- variables: { workspaceId: g },
45
- skip: !g
46
- }), { data: Pe, loading: x, error: Fe } = ce({
47
- variables: { workspaceId: g },
48
- skip: !g
49
- }), { data: Ie } = fe({
45
+ variables: { workspaceId: _ },
46
+ skip: !_
47
+ }), { data: Pe, loading: Fe, error: Ie } = ce({
48
+ variables: { workspaceId: _ },
49
+ skip: !_
50
+ }), { data: Le } = fe({
50
51
  variables: {
51
- workspaceId: g,
52
+ workspaceId: _,
52
53
  orderBy: {
53
54
  field: he.StartTime,
54
55
  direction: ge.Desc
@@ -58,23 +59,23 @@ function b() {
58
59
  offset: 0
59
60
  }
60
61
  },
61
- skip: !g
62
- }), [S] = pe(), [C] = ie(), w = te(), [Le] = ue(), { data: Re, refetch: T } = de({
63
- variables: { workspaceId: g },
64
- skip: !g
65
- }), E = Re?.pomodoroGoals ?? [], [ze, { loading: D, error: Be }] = ae(), [Ve, { loading: O, error: He }] = me(), [Ue, { loading: k, error: We }] = oe(), [Ge, A] = l(!1), [j, M] = l(null), [N, P] = l(null), [F, I] = l(y()), L = (e, t) => I((n) => ({
62
+ skip: !_
63
+ }), [S] = pe(), [C] = ie(), w = te(), [Re] = ue(), { data: ze, refetch: T } = de({
64
+ variables: { workspaceId: _ },
65
+ skip: !_
66
+ }), E = ze?.pomodoroGoals ?? [], [Be, { loading: D, error: Ve }] = ae(), [He, { loading: O, error: Ue }] = me(), [We, { loading: k, error: Ge }] = oe(), [Ke, A] = u(!1), [j, M] = u(null), [N, P] = u(null), [F, I] = u(b()), L = (e, t) => I((n) => ({
66
67
  ...n,
67
68
  [e]: t
68
- })), Ke = () => {
69
- M(null), I(y()), A(!0);
70
- }, qe = (e) => {
71
- M(e), I(y(e)), A(!0);
72
- }, Je = async () => {
73
- if (!g) return;
69
+ })), qe = () => {
70
+ M(null), I(b()), A(!0);
71
+ }, Je = (e) => {
72
+ M(e), I(b(e)), A(!0);
73
+ }, Ye = async () => {
74
+ if (!_) return;
74
75
  let e = Number(F.target);
75
- !e || e <= 0 || (j ? await Ve({ variables: {
76
+ !e || e <= 0 || (j ? await He({ variables: {
76
77
  id: j.id,
77
- workspaceId: g,
78
+ workspaceId: _,
78
79
  input: {
79
80
  type: F.type,
80
81
  target: e,
@@ -82,24 +83,24 @@ function b() {
82
83
  startDate: new Date(F.startDate).toISOString(),
83
84
  endDate: new Date(F.endDate).toISOString()
84
85
  }
85
- } }) : await ze({ variables: { input: {
86
- workspaceId: g,
86
+ } }) : await Be({ variables: { input: {
87
+ workspaceId: _,
87
88
  type: F.type,
88
89
  target: e,
89
90
  period: F.period.trim() || F.type,
90
91
  startDate: new Date(F.startDate).toISOString(),
91
92
  endDate: new Date(F.endDate).toISOString()
92
93
  } } }), A(!1), await T());
93
- }, Ye = async () => {
94
- N && g && (await Ue({ variables: {
94
+ }, Xe = async () => {
95
+ N && _ && (await We({ variables: {
95
96
  id: N.id,
96
- workspaceId: g
97
+ workspaceId: _
97
98
  } }), P(null), await T());
98
- }, R = b?.pomodoroStats, z = je?.activePomodoroSession, B = Pe?.pomodoroSettings, V = Ie?.pomodoroSessions[0], [H, U] = l(1500), [W, G] = l(!1), [K, q] = l(a.Focus), J = ve(null), Y = s((e) => _e(e, B), [B]), X = s((e) => {
99
+ }, R = x?.pomodoroStats, z = je?.activePomodoroSession, B = Pe?.pomodoroSettings, V = Le?.pomodoroSessions[0], [H, U] = u(1500), [W, G] = u(!1), [K, q] = u(a.Focus), J = ve(null), Y = c((e) => _e(e, B), [B]), X = c((e) => {
99
100
  let t = (R?.completedSessions ?? 0) + 1;
100
101
  return o(e, t, B?.sessionsBeforeLongBreak ?? 4);
101
102
  }, [B?.sessionsBeforeLongBreak, R?.completedSessions]);
102
- c(() => {
103
+ l(() => {
103
104
  if (z || !V?.completed) return;
104
105
  let e = o(V.type, R?.completedSessions ?? 0, B?.sessionsBeforeLongBreak ?? 4);
105
106
  q(e), U(Y(e));
@@ -109,20 +110,20 @@ function b() {
109
110
  V,
110
111
  B,
111
112
  R
112
- ]), c(() => {
113
+ ]), l(() => {
113
114
  if (z && !z.completed) {
114
115
  let e = Math.floor((Date.now() - new Date(z.startTime).getTime()) / 1e3), t = z.duration ?? Y(z.type), n = Math.max(0, t - e);
115
116
  U(n), G(n > 0);
116
117
  }
117
118
  }, [z, Y]);
118
- let Z = s(async () => {
119
- if (z && g && J.current !== z.id) {
119
+ let Z = c(async () => {
120
+ if (z && _ && J.current !== z.id) {
120
121
  J.current = z.id;
121
122
  try {
122
123
  let e = (await C({
123
124
  variables: {
124
125
  id: z.id,
125
- workspaceId: g
126
+ workspaceId: _
126
127
  },
127
128
  refetchQueries: [
128
129
  "GetActivePomodoroSession",
@@ -144,9 +145,9 @@ function b() {
144
145
  C,
145
146
  Y,
146
147
  X,
147
- g
148
+ _
148
149
  ]);
149
- c(() => {
150
+ l(() => {
150
151
  if (H <= 0) {
151
152
  G(!1), Z();
152
153
  return;
@@ -159,11 +160,11 @@ function b() {
159
160
  W,
160
161
  H
161
162
  ]);
162
- let Xe = (e) => {
163
+ let Ze = (e) => {
163
164
  let t = Math.floor(e / 60), n = e % 60;
164
165
  return `${String(t).padStart(2, "0")}:${String(n).padStart(2, "0")}`;
165
- }, Q = s(async () => {
166
- if (!g) return;
166
+ }, Q = c(async () => {
167
+ if (!_) return;
167
168
  if (z && !z.completed) {
168
169
  G(!0);
169
170
  return;
@@ -171,23 +172,23 @@ function b() {
171
172
  let e = K;
172
173
  await S({
173
174
  variables: { input: {
174
- workspaceId: g,
175
+ workspaceId: _,
175
176
  type: e
176
177
  } },
177
178
  refetchQueries: ["GetActivePomodoroSession", "GetPomodoroStats"],
178
179
  awaitRefetchQueries: !0
179
180
  }), U(Y(e)), G(!0);
180
181
  }, [
181
- g,
182
+ _,
182
183
  z,
183
184
  Y,
184
185
  K,
185
186
  S
186
- ]), Ze = async () => {
187
- G(!1), z && g && (await Le({
187
+ ]), Qe = async () => {
188
+ G(!1), z && _ && (await Re({
188
189
  variables: {
189
190
  id: z.id,
190
- workspaceId: g,
191
+ workspaceId: _,
191
192
  reason: "Reset by user"
192
193
  },
193
194
  refetchQueries: [
@@ -198,30 +199,30 @@ function b() {
198
199
  awaitRefetchQueries: !0
199
200
  }), q(z.type)), U(Y(z?.type ?? K));
200
201
  };
201
- if (ke || Me || x) return /* @__PURE__ */ d(t, {
202
+ if (ke || Me || Fe) return /* @__PURE__ */ f(t, {
202
203
  title: "Pomodoro Timer",
203
204
  description: "Focus with the Pomodoro Technique",
204
- children: /* @__PURE__ */ d(ee, {
205
+ children: /* @__PURE__ */ f(ee, {
205
206
  variant: "card",
206
207
  count: 3
207
208
  })
208
209
  });
209
- if (Ae || Ne || Fe) return /* @__PURE__ */ d(t, {
210
+ if (Ae || Ne || Ie) return /* @__PURE__ */ f(t, {
210
211
  title: "Pomodoro Timer",
211
212
  description: "Focus with the Pomodoro Technique",
212
- children: /* @__PURE__ */ d("div", {
213
+ children: /* @__PURE__ */ f("div", {
213
214
  className: "rounded-lg border border-status-error-border bg-status-error-bgSubtle p-4 text-sm text-status-error-text",
214
215
  children: "Failed to load pomodoro data. Please try again later."
215
216
  })
216
217
  });
217
- let Qe = Math.floor((R?.totalFocusMinutes ?? 0) / 60), $e = (R?.totalFocusMinutes ?? 0) % 60, $ = z?.type ?? K, et = $ === a.ShortBreak ? z ? "Short Break" : "Short Break Ready" : $ === a.LongBreak ? z ? "Long Break" : "Long Break Ready" : z ? "Focus Session" : "Focus Ready", tt = $ === a.ShortBreak ? "Start Short Break" : $ === a.LongBreak ? "Start Long Break" : "Start Focus";
218
- return /* @__PURE__ */ f(t, {
218
+ let $e = Math.floor((R?.totalFocusMinutes ?? 0) / 60), et = (R?.totalFocusMinutes ?? 0) % 60, $ = z?.type ?? K, tt = $ === a.ShortBreak ? z ? "Short Break" : "Short Break Ready" : $ === a.LongBreak ? z ? "Long Break" : "Long Break Ready" : z ? "Focus Session" : "Focus Ready", nt = $ === a.ShortBreak ? "Start Short Break" : $ === a.LongBreak ? "Start Long Break" : "Start Focus";
219
+ return /* @__PURE__ */ p(t, {
219
220
  title: "Pomodoro Timer",
220
221
  description: "Focus with the Pomodoro Technique",
221
222
  purpose: "Work in focused sprints with prompted short and long breaks — configure a cadence that fits your rhythm and build a deep-work streak you can measure.",
222
223
  children: [
223
- /* @__PURE__ */ d(e, { path: "/mobile/timer" }),
224
- /* @__PURE__ */ d(De, {
224
+ /* @__PURE__ */ f(e, { path: "/mobile/timer" }),
225
+ /* @__PURE__ */ f(De, {
225
226
  storageKey: "timecampus-pomodoro",
226
227
  className: "mb-6",
227
228
  steps: [
@@ -235,118 +236,118 @@ function b() {
235
236
  id: "analytics",
236
237
  label: "Review your pomodoro stats",
237
238
  description: "See streaks, completion rate and focus time.",
238
- onClick: () => _("/pomodoro/analytics")
239
+ onClick: () => v("/pomodoro/analytics")
239
240
  },
240
241
  {
241
242
  id: "settings",
242
243
  label: "Tune your intervals",
243
244
  description: "Adjust focus and break lengths to fit you.",
244
- onClick: () => _("/pomodoro/settings")
245
+ onClick: () => v("/pomodoro/settings")
245
246
  }
246
247
  ]
247
248
  }),
248
- /* @__PURE__ */ f("div", {
249
+ /* @__PURE__ */ p("div", {
249
250
  className: "grid grid-cols-1 gap-4 sm:grid-cols-3",
250
251
  children: [
251
- /* @__PURE__ */ d(n, {
252
+ /* @__PURE__ */ f(n, {
252
253
  title: "Sessions Today",
253
254
  value: String(R?.completedSessions ?? 0),
254
255
  description: `Total: ${R?.totalSessions ?? 0} sessions`
255
256
  }),
256
- /* @__PURE__ */ d(n, {
257
+ /* @__PURE__ */ f(n, {
257
258
  title: "Focus Time",
258
- value: `${Qe}h ${$e}m`,
259
+ value: `${$e}h ${et}m`,
259
260
  trend: {
260
261
  value: R?.completionRate ?? 0,
261
262
  label: "completion rate"
262
263
  }
263
264
  }),
264
- /* @__PURE__ */ d(n, {
265
+ /* @__PURE__ */ f(n, {
265
266
  title: "Current Streak",
266
267
  value: `${R?.streakDays ?? 0} days`,
267
268
  description: `Avg: ${R?.averageSessionMinutes ?? 0}m per session`
268
269
  })
269
270
  ]
270
271
  }),
271
- /* @__PURE__ */ d("div", {
272
+ /* @__PURE__ */ f("div", {
272
273
  className: "mx-auto max-w-md",
273
- children: /* @__PURE__ */ f(p, {
274
+ children: /* @__PURE__ */ p(m, {
274
275
  treatment: "glass",
275
276
  glow: !0,
276
277
  className: "p-8 text-center",
277
278
  children: [
278
- /* @__PURE__ */ d("div", {
279
+ /* @__PURE__ */ f("div", {
279
280
  className: "mb-2",
280
- children: /* @__PURE__ */ d("span", {
281
+ children: /* @__PURE__ */ f("span", {
281
282
  "aria-live": "polite",
282
283
  className: "inline-flex rounded-full bg-action-primary-bg/10 px-3 py-1 text-xs font-medium text-primary",
283
- children: et
284
+ children: tt
284
285
  })
285
286
  }),
286
- /* @__PURE__ */ d("p", {
287
+ /* @__PURE__ */ f("p", {
287
288
  className: "text-7xl font-mono font-bold text-text-primary",
288
- children: Xe(H)
289
+ children: Ze(H)
289
290
  }),
290
- /* @__PURE__ */ d("p", {
291
+ /* @__PURE__ */ f("p", {
291
292
  className: "mt-2 text-sm text-text-secondary",
292
293
  children: R ? `${R.completedSessions} of ${R.totalSessions} sessions` : "No sessions yet"
293
294
  }),
294
- /* @__PURE__ */ f("div", {
295
+ /* @__PURE__ */ p("div", {
295
296
  className: "mt-6 flex items-center justify-center gap-3",
296
297
  children: [
297
- W ? /* @__PURE__ */ f("button", {
298
+ W ? /* @__PURE__ */ p("button", {
298
299
  onClick: () => G(!1),
299
300
  className: "inline-flex items-center gap-2 rounded-md bg-action-primary-bg px-6 py-3 text-sm font-medium text-action-primary-text hover:bg-action-primary-bg/90",
300
- children: [/* @__PURE__ */ d(ye, { className: "h-4 w-4" }), "Pause"]
301
- }) : /* @__PURE__ */ f("button", {
301
+ children: [/* @__PURE__ */ f(ye, { className: "h-4 w-4" }), "Pause"]
302
+ }) : /* @__PURE__ */ p("button", {
302
303
  onClick: Q,
303
304
  className: "inline-flex items-center gap-2 rounded-md bg-action-primary-bg px-6 py-3 text-sm font-medium text-action-primary-text hover:bg-action-primary-bg/90",
304
- children: [/* @__PURE__ */ d(xe, { className: "h-4 w-4" }), tt]
305
+ children: [/* @__PURE__ */ f(xe, { className: "h-4 w-4" }), nt]
305
306
  }),
306
- /* @__PURE__ */ f("button", {
307
+ /* @__PURE__ */ p("button", {
307
308
  onClick: Z,
308
309
  disabled: !z,
309
310
  className: "inline-flex items-center gap-2 rounded-md border border-border-subtle px-4 py-3 text-sm font-medium text-text-primary hover:bg-bg-sunken/50 disabled:opacity-50",
310
- children: [/* @__PURE__ */ d(we, { className: "h-4 w-4" }), "Skip"]
311
+ children: [/* @__PURE__ */ f(we, { className: "h-4 w-4" }), "Skip"]
311
312
  }),
312
- /* @__PURE__ */ f("button", {
313
- onClick: () => void Ze(),
313
+ /* @__PURE__ */ p("button", {
314
+ onClick: () => void Qe(),
314
315
  className: "inline-flex items-center gap-2 rounded-md border border-border-subtle px-4 py-3 text-sm font-medium text-text-primary hover:bg-bg-sunken/50",
315
- children: [/* @__PURE__ */ d(Ce, { className: "h-4 w-4" }), "Reset"]
316
+ children: [/* @__PURE__ */ f(Ce, { className: "h-4 w-4" }), "Reset"]
316
317
  })
317
318
  ]
318
319
  })
319
320
  ]
320
321
  })
321
322
  }),
322
- /* @__PURE__ */ f(p, {
323
+ /* @__PURE__ */ p(m, {
323
324
  treatment: "glass",
324
325
  className: "p-6",
325
- children: [/* @__PURE__ */ f("div", {
326
+ children: [/* @__PURE__ */ p("div", {
326
327
  className: "mb-4 flex items-center justify-between",
327
- children: [/* @__PURE__ */ f("h3", {
328
+ children: [/* @__PURE__ */ p("h3", {
328
329
  className: "flex items-center gap-2 text-sm font-semibold text-text-primary",
329
- children: [/* @__PURE__ */ d(Te, { className: "h-4 w-4" }), "Focus Goals"]
330
- }), /* @__PURE__ */ f("button", {
331
- onClick: Ke,
330
+ children: [/* @__PURE__ */ f(Te, { className: "h-4 w-4" }), "Focus Goals"]
331
+ }), /* @__PURE__ */ p("button", {
332
+ onClick: qe,
332
333
  className: "inline-flex items-center gap-1.5 rounded-md bg-action-primary-bg px-3 py-1.5 text-sm font-medium text-action-primary-text hover:bg-action-primary-bg/90",
333
- children: [/* @__PURE__ */ d(Se, { className: "h-4 w-4" }), "Add Goal"]
334
+ children: [/* @__PURE__ */ f(Se, { className: "h-4 w-4" }), "Add Goal"]
334
335
  })]
335
- }), E.length === 0 ? /* @__PURE__ */ d("p", {
336
+ }), E.length === 0 ? /* @__PURE__ */ f("p", {
336
337
  className: "py-6 text-center text-sm text-text-secondary",
337
338
  children: "No focus goals yet. Set a daily or weekly target to build a consistent focus habit."
338
- }) : /* @__PURE__ */ d("div", {
339
+ }) : /* @__PURE__ */ f("div", {
339
340
  className: "space-y-3",
340
341
  children: E.map((e) => {
341
342
  let t = e.target ? Math.min(100, Math.round(e.current / e.target * 100)) : 0;
342
- return /* @__PURE__ */ f("div", {
343
+ return /* @__PURE__ */ p("div", {
343
344
  className: "rounded-lg border border-border-subtle p-4",
344
- children: [/* @__PURE__ */ f("div", {
345
+ children: [/* @__PURE__ */ p("div", {
345
346
  className: "flex items-center justify-between",
346
- children: [/* @__PURE__ */ f("div", { children: [/* @__PURE__ */ f("p", {
347
+ children: [/* @__PURE__ */ p("div", { children: [/* @__PURE__ */ p("p", {
347
348
  className: "text-sm font-medium capitalize text-text-primary",
348
349
  children: [e.type.toLowerCase(), " goal"]
349
- }), /* @__PURE__ */ f("p", {
350
+ }), /* @__PURE__ */ p("p", {
350
351
  className: "text-xs text-text-secondary",
351
352
  children: [
352
353
  e.current,
@@ -354,30 +355,30 @@ function b() {
354
355
  e.target,
355
356
  " sessions"
356
357
  ]
357
- })] }), /* @__PURE__ */ f("div", {
358
+ })] }), /* @__PURE__ */ p("div", {
358
359
  className: "flex items-center gap-2",
359
360
  children: [
360
- /* @__PURE__ */ f("span", {
361
+ /* @__PURE__ */ p("span", {
361
362
  className: "text-sm font-medium text-text-primary",
362
363
  children: [t, "%"]
363
364
  }),
364
- /* @__PURE__ */ d("button", {
365
- onClick: () => qe(e),
365
+ /* @__PURE__ */ f("button", {
366
+ onClick: () => Je(e),
366
367
  className: "rounded-md p-1.5 text-text-secondary hover:bg-bg-sunken hover:text-text-primary",
367
368
  "aria-label": "Edit goal",
368
- children: /* @__PURE__ */ d(be, { className: "h-4 w-4" })
369
+ children: /* @__PURE__ */ f(be, { className: "h-4 w-4" })
369
370
  }),
370
- /* @__PURE__ */ d("button", {
371
+ /* @__PURE__ */ f("button", {
371
372
  onClick: () => P(e),
372
373
  className: "rounded-md p-1.5 text-text-secondary hover:bg-status-error-bgSubtle hover:text-status-error-text",
373
374
  "aria-label": "Delete goal",
374
- children: /* @__PURE__ */ d(Ee, { className: "h-4 w-4" })
375
+ children: /* @__PURE__ */ f(Ee, { className: "h-4 w-4" })
375
376
  })
376
377
  ]
377
378
  })]
378
- }), /* @__PURE__ */ d("div", {
379
+ }), /* @__PURE__ */ f("div", {
379
380
  className: "mt-3 h-2 w-full rounded-full bg-bg-sunken",
380
- children: /* @__PURE__ */ d("div", {
381
+ children: /* @__PURE__ */ f("div", {
381
382
  className: "h-2 rounded-full bg-action-primary-bg",
382
383
  style: { width: `${t}%` }
383
384
  })
@@ -386,31 +387,31 @@ function b() {
386
387
  })
387
388
  })]
388
389
  }),
389
- /* @__PURE__ */ f(r, {
390
- open: Ge,
390
+ /* @__PURE__ */ p(r, {
391
+ open: Ke,
391
392
  onClose: () => A(!1),
392
393
  title: j ? "Edit Focus Goal" : "Add Focus Goal",
393
394
  description: "Set a target number of focus sessions",
394
- footer: /* @__PURE__ */ f(u, { children: [/* @__PURE__ */ d("button", {
395
+ footer: /* @__PURE__ */ p(d, { children: [/* @__PURE__ */ f("button", {
395
396
  onClick: () => A(!1),
396
397
  className: "rounded-md border border-border-subtle px-4 py-2 text-sm font-medium text-text-primary hover:bg-bg-sunken/50",
397
398
  children: "Cancel"
398
- }), /* @__PURE__ */ d("button", {
399
- onClick: Je,
399
+ }), /* @__PURE__ */ f("button", {
400
+ onClick: Ye,
400
401
  disabled: D || O || Number(F.target) <= 0,
401
402
  className: "rounded-md bg-action-primary-bg px-4 py-2 text-sm font-medium text-action-primary-text hover:bg-action-primary-bg/90 disabled:opacity-50",
402
403
  children: D || O ? "Saving..." : j ? "Save Changes" : "Add Goal"
403
404
  })] }),
404
- children: [(Be || He) && /* @__PURE__ */ d("div", {
405
+ children: [(Ve || Ue) && /* @__PURE__ */ f("div", {
405
406
  className: "mb-4 rounded-lg border border-status-error-border bg-status-error-bgSubtle p-3 text-sm text-status-error-text",
406
407
  children: "Failed to save goal. Please try again."
407
- }), /* @__PURE__ */ f("div", {
408
+ }), /* @__PURE__ */ p("div", {
408
409
  className: "space-y-4",
409
410
  children: [
410
- /* @__PURE__ */ f("div", { children: [/* @__PURE__ */ d("label", {
411
- className: h,
411
+ /* @__PURE__ */ p("div", { children: [/* @__PURE__ */ f("label", {
412
+ className: g,
412
413
  children: "Goal Type"
413
- }), /* @__PURE__ */ f(Oe, {
414
+ }), /* @__PURE__ */ p(Oe, {
414
415
  value: F.type,
415
416
  onChange: (e) => {
416
417
  let t = e.target.value;
@@ -418,78 +419,78 @@ function b() {
418
419
  ...e,
419
420
  type: t,
420
421
  period: t,
421
- endDate: t === i.Daily ? v(0) : t === i.Weekly ? v(7) : v(30)
422
+ endDate: t === i.Daily ? y(0) : t === i.Weekly ? y(7) : y(30)
422
423
  }));
423
424
  },
424
- className: m,
425
+ className: h,
425
426
  children: [
426
- /* @__PURE__ */ d("option", {
427
+ /* @__PURE__ */ f("option", {
427
428
  value: i.Daily,
428
429
  children: "Daily"
429
430
  }),
430
- /* @__PURE__ */ d("option", {
431
+ /* @__PURE__ */ f("option", {
431
432
  value: i.Weekly,
432
433
  children: "Weekly"
433
434
  }),
434
- /* @__PURE__ */ d("option", {
435
+ /* @__PURE__ */ f("option", {
435
436
  value: i.Monthly,
436
437
  children: "Monthly"
437
438
  })
438
439
  ]
439
440
  })] }),
440
- /* @__PURE__ */ f("div", { children: [/* @__PURE__ */ d("label", {
441
- className: h,
441
+ /* @__PURE__ */ p("div", { children: [/* @__PURE__ */ f("label", {
442
+ className: g,
442
443
  children: "Target Sessions"
443
- }), /* @__PURE__ */ d("input", {
444
+ }), /* @__PURE__ */ f("input", {
444
445
  type: "number",
445
446
  min: "1",
446
447
  placeholder: "8",
447
448
  value: F.target,
448
449
  onChange: (e) => L("target", e.target.value),
449
- className: m
450
+ className: h
450
451
  })] }),
451
- /* @__PURE__ */ f("div", {
452
+ /* @__PURE__ */ p("div", {
452
453
  className: "grid grid-cols-1 gap-4 sm:grid-cols-2",
453
- children: [/* @__PURE__ */ f("div", { children: [/* @__PURE__ */ d("label", {
454
- className: h,
454
+ children: [/* @__PURE__ */ p("div", { children: [/* @__PURE__ */ f("label", {
455
+ className: g,
455
456
  children: "Start Date"
456
- }), /* @__PURE__ */ d("input", {
457
- type: "date",
457
+ }), /* @__PURE__ */ f(s, {
458
458
  value: F.startDate,
459
- onChange: (e) => L("startDate", e.target.value),
460
- className: m
461
- })] }), /* @__PURE__ */ f("div", { children: [/* @__PURE__ */ d("label", {
462
- className: h,
459
+ onChange: (e) => L("startDate", e),
460
+ label: "Start date",
461
+ clearable: !0
462
+ })] }), /* @__PURE__ */ p("div", { children: [/* @__PURE__ */ f("label", {
463
+ className: g,
463
464
  children: "End Date"
464
- }), /* @__PURE__ */ d("input", {
465
- type: "date",
465
+ }), /* @__PURE__ */ f(s, {
466
466
  value: F.endDate,
467
- onChange: (e) => L("endDate", e.target.value),
468
- className: m
467
+ onChange: (e) => L("endDate", e),
468
+ label: "End date",
469
+ clearable: !0
469
470
  })] })]
470
471
  })
471
472
  ]
472
473
  })]
473
474
  }),
474
- /* @__PURE__ */ f(r, {
475
+ /* @__PURE__ */ p(r, {
475
476
  open: N !== null,
476
477
  onClose: () => P(null),
477
478
  title: "Delete Focus Goal",
478
479
  size: "sm",
479
- footer: /* @__PURE__ */ f(u, { children: [/* @__PURE__ */ d("button", {
480
+ footer: /* @__PURE__ */ p(d, { children: [/* @__PURE__ */ f("button", {
480
481
  onClick: () => P(null),
481
482
  className: "rounded-md border border-border-subtle px-4 py-2 text-sm font-medium text-text-primary hover:bg-bg-sunken/50",
482
483
  children: "Cancel"
483
- }), /* @__PURE__ */ d("button", {
484
- onClick: Ye,
484
+ }), /* @__PURE__ */ f("button", {
485
+ onClick: Xe,
485
486
  disabled: k,
486
487
  className: "rounded-md bg-status-error-bgSubtle px-4 py-2 text-sm font-medium text-status-error-text hover:bg-status-error-bgSubtle/70 disabled:opacity-50",
487
488
  children: k ? "Deleting..." : "Delete"
488
489
  })] }),
489
- children: [We && /* @__PURE__ */ d("div", {
490
+ children: [Ge && /* @__PURE__ */ f("div", {
490
491
  className: "mb-4 rounded-lg border border-status-error-border bg-status-error-bgSubtle p-3 text-sm text-status-error-text",
491
492
  children: "Failed to delete goal. Please try again."
492
- }), /* @__PURE__ */ f("p", {
493
+ }), /* @__PURE__ */ p("p", {
493
494
  className: "text-sm text-text-secondary",
494
495
  children: [
495
496
  "Are you sure you want to delete this",
@@ -502,6 +503,6 @@ function b() {
502
503
  ]
503
504
  });
504
505
  }
505
- export { b as PomodoroPage };
506
+ export { x as PomodoroPage };
506
507
 
507
508
  //# sourceMappingURL=PomodoroPage.js.map