@burdenoff/microfe-timecampus 2026.1205.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 (125) 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/ErrorBoundary.js +1 -1
  5. package/dist/timecampus/components/ErrorBoundary.js.map +1 -1
  6. package/dist/timecampus/components/StatusBadge.js +4 -4
  7. package/dist/timecampus/components/StatusBadge.js.map +1 -1
  8. package/dist/timecampus/components/Toast.js +4 -4
  9. package/dist/timecampus/components/Toast.js.map +1 -1
  10. package/dist/timecampus/components/dateFieldValues.d.ts +39 -0
  11. package/dist/timecampus/components/dateFieldValues.js +49 -0
  12. package/dist/timecampus/components/dateFieldValues.js.map +1 -0
  13. package/dist/timecampus/components/maps/LocationGeofenceMap.js +2 -2
  14. package/dist/timecampus/components/maps/LocationGeofenceMap.js.map +1 -1
  15. package/dist/timecampus/pages/HomePage.js +1 -1
  16. package/dist/timecampus/pages/HomePage.js.map +1 -1
  17. package/dist/timecampus/pages/admin/AdminPage.js +6 -6
  18. package/dist/timecampus/pages/admin/AdminPage.js.map +1 -1
  19. package/dist/timecampus/pages/application-usage/ApplicationUsagePage.js +5 -5
  20. package/dist/timecampus/pages/application-usage/ApplicationUsagePage.js.map +1 -1
  21. package/dist/timecampus/pages/channels/ChannelsPage.js +1 -1
  22. package/dist/timecampus/pages/channels/ChannelsPage.js.map +1 -1
  23. package/dist/timecampus/pages/client-portal/ClientPortalPage.js +4 -4
  24. package/dist/timecampus/pages/client-portal/ClientPortalPage.js.map +1 -1
  25. package/dist/timecampus/pages/dashboard/AnalyticsPage.js +3 -3
  26. package/dist/timecampus/pages/dashboard/AnalyticsPage.js.map +1 -1
  27. package/dist/timecampus/pages/dashboard/ReportsPage.js +4 -4
  28. package/dist/timecampus/pages/dashboard/ReportsPage.js.map +1 -1
  29. package/dist/timecampus/pages/dashboard/ServerReportExports.js +1 -1
  30. package/dist/timecampus/pages/dashboard/ServerReportExports.js.map +1 -1
  31. package/dist/timecampus/pages/email-tracking/EmailTrackingPage.js +121 -120
  32. package/dist/timecampus/pages/email-tracking/EmailTrackingPage.js.map +1 -1
  33. package/dist/timecampus/pages/expense-tracking/ExpenseTrackingPage.js +71 -71
  34. package/dist/timecampus/pages/expense-tracking/ExpenseTrackingPage.js.map +1 -1
  35. package/dist/timecampus/pages/extend/AppletDeveloperPage.js +1 -1
  36. package/dist/timecampus/pages/extend/AppletDeveloperPage.js.map +1 -1
  37. package/dist/timecampus/pages/extend/ThirdPartyAppletsSection.js +1 -1
  38. package/dist/timecampus/pages/extend/ThirdPartyAppletsSection.js.map +1 -1
  39. package/dist/timecampus/pages/extend/TimeTriggersPage.js +1 -1
  40. package/dist/timecampus/pages/extend/TimeTriggersPage.js.map +1 -1
  41. package/dist/timecampus/pages/focus/FocusProtectionPage.js +250 -253
  42. package/dist/timecampus/pages/focus/FocusProtectionPage.js.map +1 -1
  43. package/dist/timecampus/pages/focus-score/FocusScorePage.js +1 -1
  44. package/dist/timecampus/pages/focus-score/FocusScorePage.js.map +1 -1
  45. package/dist/timecampus/pages/geofencing/GeofencingPage.js +5 -5
  46. package/dist/timecampus/pages/geofencing/GeofencingPage.js.map +1 -1
  47. package/dist/timecampus/pages/invoicing/InvoicingPage.js +264 -263
  48. package/dist/timecampus/pages/invoicing/InvoicingPage.js.map +1 -1
  49. package/dist/timecampus/pages/lifetime/DeadTimeRadarPage.js +1 -1
  50. package/dist/timecampus/pages/lifetime/DeadTimeRadarPage.js.map +1 -1
  51. package/dist/timecampus/pages/lifetime/FiniteLifePage.js +103 -103
  52. package/dist/timecampus/pages/lifetime/FiniteLifePage.js.map +1 -1
  53. package/dist/timecampus/pages/lifetime/LifeBalancePage.js +1 -1
  54. package/dist/timecampus/pages/lifetime/LifeBalancePage.js.map +1 -1
  55. package/dist/timecampus/pages/lifetime/LifeTimelinePage.js +43 -43
  56. package/dist/timecampus/pages/lifetime/LifeTimelinePage.js.map +1 -1
  57. package/dist/timecampus/pages/lifetime/PersonalCorporatePage.js +3 -3
  58. package/dist/timecampus/pages/lifetime/PersonalCorporatePage.js.map +1 -1
  59. package/dist/timecampus/pages/lifetime/RecommendationsPage.js +1 -1
  60. package/dist/timecampus/pages/lifetime/RecommendationsPage.js.map +1 -1
  61. package/dist/timecampus/pages/lifetime/TimeWellSpentPage.js +2 -2
  62. package/dist/timecampus/pages/lifetime/TimeWellSpentPage.js.map +1 -1
  63. package/dist/timecampus/pages/lifetime/ValuesGoalsPage.js +5 -5
  64. package/dist/timecampus/pages/lifetime/ValuesGoalsPage.js.map +1 -1
  65. package/dist/timecampus/pages/location-tracking/LocationTrackingPage.js +223 -221
  66. package/dist/timecampus/pages/location-tracking/LocationTrackingPage.js.map +1 -1
  67. package/dist/timecampus/pages/meetings/ActionItemFormModal.js +65 -64
  68. package/dist/timecampus/pages/meetings/ActionItemFormModal.js.map +1 -1
  69. package/dist/timecampus/pages/meetings/MeetingAnalyticsPage.js +1 -1
  70. package/dist/timecampus/pages/meetings/MeetingAnalyticsPage.js.map +1 -1
  71. package/dist/timecampus/pages/meetings/MeetingCreatePage.js +55 -55
  72. package/dist/timecampus/pages/meetings/MeetingCreatePage.js.map +1 -1
  73. package/dist/timecampus/pages/meetings/MeetingDetailPage.js +8 -8
  74. package/dist/timecampus/pages/meetings/MeetingDetailPage.js.map +1 -1
  75. package/dist/timecampus/pages/meetings/MeetingFormModal.js +99 -97
  76. package/dist/timecampus/pages/meetings/MeetingFormModal.js.map +1 -1
  77. package/dist/timecampus/pages/meetings/MeetingsPage.js +3 -3
  78. package/dist/timecampus/pages/meetings/MeetingsPage.js.map +1 -1
  79. package/dist/timecampus/pages/meetings/ParticipantFormModal.js +1 -1
  80. package/dist/timecampus/pages/meetings/ParticipantFormModal.js.map +1 -1
  81. package/dist/timecampus/pages/mobile/MobileLifeBalancePage.js +1 -1
  82. package/dist/timecampus/pages/mobile/MobileLifeBalancePage.js.map +1 -1
  83. package/dist/timecampus/pages/mobile/MobileTimelinePage.js +4 -4
  84. package/dist/timecampus/pages/mobile/MobileTimelinePage.js.map +1 -1
  85. package/dist/timecampus/pages/mobile/MobileTimerPage.js +1 -1
  86. package/dist/timecampus/pages/mobile/MobileTimerPage.js.map +1 -1
  87. package/dist/timecampus/pages/pomodoro/PomodoroAnalyticsPage.js +2 -2
  88. package/dist/timecampus/pages/pomodoro/PomodoroAnalyticsPage.js.map +1 -1
  89. package/dist/timecampus/pages/pomodoro/PomodoroPage.js +155 -154
  90. package/dist/timecampus/pages/pomodoro/PomodoroPage.js.map +1 -1
  91. package/dist/timecampus/pages/pomodoro/PomodoroSettingsPage.js +1 -1
  92. package/dist/timecampus/pages/pomodoro/PomodoroSettingsPage.js.map +1 -1
  93. package/dist/timecampus/pages/projects/ProjectCreatePage.js +1 -1
  94. package/dist/timecampus/pages/projects/ProjectCreatePage.js.map +1 -1
  95. package/dist/timecampus/pages/projects/ProjectDetailPage.js +5 -5
  96. package/dist/timecampus/pages/projects/ProjectDetailPage.js.map +1 -1
  97. package/dist/timecampus/pages/projects/ProjectsPage.js +6 -6
  98. package/dist/timecampus/pages/projects/ProjectsPage.js.map +1 -1
  99. package/dist/timecampus/pages/projects/TasksPage.js +189 -188
  100. package/dist/timecampus/pages/projects/TasksPage.js.map +1 -1
  101. package/dist/timecampus/pages/resource-planning/ResourcePlanningPage.js +356 -361
  102. package/dist/timecampus/pages/resource-planning/ResourcePlanningPage.js.map +1 -1
  103. package/dist/timecampus/pages/team/TeamAnalyticsPage.js +2 -2
  104. package/dist/timecampus/pages/team/TeamAnalyticsPage.js.map +1 -1
  105. package/dist/timecampus/pages/team/TeamMembersPage.js +3 -3
  106. package/dist/timecampus/pages/team/TeamMembersPage.js.map +1 -1
  107. package/dist/timecampus/pages/team/TeamPage.js +2 -2
  108. package/dist/timecampus/pages/team/TeamPage.js.map +1 -1
  109. package/dist/timecampus/pages/team-activity/TeamActivityPage.js +2 -2
  110. package/dist/timecampus/pages/team-activity/TeamActivityPage.js.map +1 -1
  111. package/dist/timecampus/pages/time/TimeEntriesPage.js +133 -131
  112. package/dist/timecampus/pages/time/TimeEntriesPage.js.map +1 -1
  113. package/dist/timecampus/pages/time/TimeTrackingPage.js +1 -1
  114. package/dist/timecampus/pages/time/TimeTrackingPage.js.map +1 -1
  115. package/dist/timecampus/pages/time/TimerPage.js +1 -1
  116. package/dist/timecampus/pages/time/TimerPage.js.map +1 -1
  117. package/dist/timecampus/pages/time-approval/SubmitTimesheetModal.js +47 -48
  118. package/dist/timecampus/pages/time-approval/SubmitTimesheetModal.js.map +1 -1
  119. package/dist/timecampus/pages/time-approval/TimeApprovalPage.js +8 -8
  120. package/dist/timecampus/pages/time-approval/TimeApprovalPage.js.map +1 -1
  121. package/dist/timecampus/pages/timeline/TimelinePage.js +237 -237
  122. package/dist/timecampus/pages/timeline/TimelinePage.js.map +1 -1
  123. package/dist/timecampus/pages/work-patterns/SustainedLoadCard.js +3 -3
  124. package/dist/timecampus/pages/work-patterns/SustainedLoadCard.js.map +1 -1
  125. package/package.json +1 -1
@@ -7,18 +7,19 @@ import { ToastContainer as te, useToast as ne } from "../../components/Toast.js"
7
7
  import { useTimeCampus as re } from "../../providers/TimeCampusProvider.js";
8
8
  import { TimeCampusFocusBlockResponse as i, TimeCampusFocusProtectionLevel as a, TimeCampusFocusSessionStatus as o } from "../../../generated/wspace-types.js";
9
9
  import { useCancelFocusBlockMutation as ie, useEndFocusSessionMutation as ae, useGetActiveFocusSessionQuery as oe, useGetFocusBlockSuggestionsQuery as se, useGetFocusCalendarConnectionQuery as ce, useGetFocusPreferencesQuery as le, useGetFocusProtectionSummaryQuery as ue, useListFocusBlocksQuery as de, useLogFocusInterruptionMutation as fe, useRespondToFocusBlockSuggestionMutation as pe, useStartFocusSessionMutation as me, useUpdateFocusPreferencesMutation as he } from "../../../generated/wspace-operations.js";
10
- import { DAY_MS as s, announceFocusChange as ge, calendarHoldLabel as _e, calendarProviderLabel as ve, canStartBlock as ye, formatDuration as c, formatRange as be, localDayStart as xe, minutesLeft as Se, minutesToTime as Ce, parseAppList as we, parseSiteList as Te, readStartBlockParam as Ee, reasonLabel as De, startNudgeOptions as Oe, timeToMinutes as ke, withoutStartBlockParam as Ae } from "./focusHelpers.js";
11
- import { useEffect as l, useMemo as u, useRef as d, useState as f } from "react";
12
- import { AlarmClock as je, Ban as p, CalendarClock as Me, Check as Ne, Play as m, Shield as h, ShieldCheck as Pe, Square as Fe, Target as g, X as Ie } from "lucide-react";
13
- import { Fragment as _, jsx as v, jsxs as y } from "react/jsx-runtime";
14
- import { GlassCard as Le, ThemedSelect as b } from "@burdenoff/fe-libs/ui";
10
+ import { DAY_MS as ge, announceFocusChange as _e, calendarHoldLabel as ve, calendarProviderLabel as ye, canStartBlock as be, formatDuration as s, formatRange as xe, localDayStart as Se, minutesLeft as Ce, minutesToTime as c, parseAppList as we, parseSiteList as Te, readStartBlockParam as Ee, reasonLabel as De, startNudgeOptions as Oe, timeToMinutes as l, withoutStartBlockParam as ke } from "./focusHelpers.js";
11
+ import { TimeField as Ae } from "../../components/DateFields.js";
12
+ import { useEffect as u, useMemo as d, useRef as f, useState as p } from "react";
13
+ import { AlarmClock as je, Ban as m, CalendarClock as Me, Check as Ne, Play as h, Shield as Pe, ShieldCheck as Fe, Square as Ie, Target as Le, X as Re } from "lucide-react";
14
+ import { Fragment as ze, jsx as g, jsxs as _ } from "react/jsx-runtime";
15
+ import { GlassCard as Be, ThemedSelect as Ve } from "@burdenoff/fe-libs/ui";
15
16
  // src/timecampus/pages/focus/FocusProtectionPage.tsx
16
- var x = "Focus Protection", S = "Adaptive focus blocks and distraction blocking during focus sessions", Re = [
17
+ var v = "Focus Protection", y = "Adaptive focus blocks and distraction blocking during focus sessions", He = [
17
18
  "GetActiveFocusSession",
18
19
  "GetFocusBlockSuggestions",
19
20
  "ListFocusBlocks",
20
21
  "GetFocusProtectionSummary"
21
- ], C = "rounded-md border border-border-subtle bg-bg-surface px-3 py-1.5 text-sm text-text-primary", w = "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 disabled:opacity-50", T = "inline-flex items-center gap-1.5 rounded-md border border-border-subtle bg-bg-surface px-3 py-1.5 text-sm font-medium text-text-primary hover:bg-bg-surface-hover disabled:opacity-50", E = {
22
+ ], b = "rounded-md border border-border-subtle bg-bg-surface px-3 py-1.5 text-sm text-text-primary", x = "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 disabled:opacity-50", S = "inline-flex items-center gap-1.5 rounded-md border border-border-subtle bg-bg-surface px-3 py-1.5 text-sm font-medium text-text-primary hover:bg-bg-surface-hover disabled:opacity-50", C = {
22
23
  on: "on",
23
24
  off: "off",
24
25
  running: "on",
@@ -27,90 +28,90 @@ var x = "Focus Protection", S = "Adaptive focus blocks and distraction blocking
27
28
  "needs-setup": "needs a one-time setup",
28
29
  error: "not working"
29
30
  };
30
- function D(e) {
31
- return E[e] ?? e;
31
+ function w(e) {
32
+ return C[e] ?? e;
32
33
  }
33
- function O(e) {
34
+ function T(e) {
34
35
  return e instanceof Error ? e.message : "Something went wrong";
35
36
  }
36
- function k() {
37
- let { workspaceId: E = "" } = re(), { toasts: k, addToast: A, dismissToast: ze } = ne(), [j, Be] = f(0), [M, Ve] = f(() => Date.now());
38
- l(() => {
39
- let e = window.setInterval(() => Ve(Date.now()), 6e4);
37
+ function E() {
38
+ let { workspaceId: C = "" } = re(), { toasts: E, addToast: D, dismissToast: Ue } = ne(), [O, We] = p(0), [k, Ge] = p(() => Date.now());
39
+ u(() => {
40
+ let e = window.setInterval(() => Ge(Date.now()), 6e4);
40
41
  return () => window.clearInterval(e);
41
42
  }, []);
42
- let N = u(() => xe(/* @__PURE__ */ new Date(), j), [j]), He = u(() => new Date(N.getTime() + s), [N]), Ue = u(() => {
43
+ let A = d(() => Se(/* @__PURE__ */ new Date(), O), [O]), Ke = d(() => new Date(A.getTime() + ge), [A]), qe = d(() => {
43
44
  let e = /* @__PURE__ */ new Date();
44
45
  return {
45
- from: (/* @__PURE__ */ new Date(e.getTime() - 7 * s)).toISOString(),
46
+ from: (/* @__PURE__ */ new Date(e.getTime() - 7 * ge)).toISOString(),
46
47
  to: e.toISOString()
47
48
  };
48
- }, []), P = oe({ skip: !E }), F = se({
49
- variables: { dayStart: N.toISOString() },
50
- skip: !E
51
- }), I = de({
49
+ }, []), j = oe({ skip: !C }), M = se({
50
+ variables: { dayStart: A.toISOString() },
51
+ skip: !C
52
+ }), N = de({
52
53
  variables: {
53
- from: N.toISOString(),
54
- to: He.toISOString()
54
+ from: A.toISOString(),
55
+ to: Ke.toISOString()
55
56
  },
56
- skip: !E
57
- }), L = le({ skip: !E }), We = ce({ skip: !E }), Ge = ue({
58
- variables: Ue,
59
- skip: !E
60
- }), R = { refetchQueries: Re }, [z, { loading: B }] = me(R), [Ke, { loading: qe }] = ae(R), [Je] = fe(R), [Ye, { loading: V }] = pe(R), [Xe] = ie(R), [Ze, { loading: Qe }] = he({ refetchQueries: [
57
+ skip: !C
58
+ }), P = le({ skip: !C }), Je = ce({ skip: !C }), Ye = ue({
59
+ variables: qe,
60
+ skip: !C
61
+ }), F = { refetchQueries: He }, [I, { loading: L }] = me(F), [Xe, { loading: R }] = ae(F), [Ze] = fe(F), [Qe, { loading: z }] = pe(F), [$e] = ie(F), [et, { loading: B }] = he({ refetchQueries: [
61
62
  "GetFocusPreferences",
62
63
  "GetFocusBlockSuggestions",
63
64
  "GetFocusCalendarConnection"
64
- ] }), [$e, et] = f(50), [tt, nt] = f(!1), H = L.data?.timeCampusFocusPreferences, [rt, it] = f("09:00"), [U, at] = f("18:00"), [W, ot] = f(90), [st, ct] = f(2), [lt, ut] = f(10), [dt, ft] = f(!0), [pt, mt] = f(""), [ht, gt] = f(""), [_t, vt] = f(!0), [yt, bt] = f(!0), [G, xt] = f(5), K = e();
65
- l(() => {
66
- H && (it(Ce(H.workdayStartMinute)), at(Ce(H.workdayEndMinute)), ot(H.preferredBlockMinutes), ct(H.maxBlocksPerDay), ut(H.meetingBufferMinutes), ft(H.blockingEnabled), mt(H.blockedDomains.join("\n")), gt(H.blockedApps.join("\n")), vt(H.doNotDisturb), bt(H.calendarHoldEnabled), xt(H.startNudgeMinutes));
65
+ ] }), [V, tt] = p(50), [nt, rt] = p(!1), H = P.data?.timeCampusFocusPreferences, [it, at] = p("09:00"), [U, ot] = p("18:00"), [W, G] = p(90), [st, ct] = p(2), [lt, ut] = p(10), [dt, ft] = p(!0), [pt, mt] = p(""), [ht, gt] = p(""), [_t, vt] = p(!0), [yt, bt] = p(!0), [K, xt] = p(5), q = e();
66
+ u(() => {
67
+ H && (at(c(H.workdayStartMinute)), ot(c(H.workdayEndMinute)), G(H.preferredBlockMinutes), ct(H.maxBlocksPerDay), ut(H.meetingBufferMinutes), ft(H.blockingEnabled), mt(H.blockedDomains.join("\n")), gt(H.blockedApps.join("\n")), vt(H.doNotDisturb), bt(H.calendarHoldEnabled), xt(H.startNudgeMinutes));
67
68
  }, [H]);
68
- let q = P.data?.timeCampusActiveFocusSession ?? null, St = F.data?.timeCampusFocusBlockSuggestions ?? [], Ct = I.data?.timeCampusFocusBlocks ?? [], J = Ge.data?.timeCampusFocusSummary, Y = We.data?.timeCampusFocusCalendarConnection, wt = ve(Y?.provider), Tt = !P.data && P.loading || !L.data && L.loading, Et = P.error ?? L.error;
69
- async function X(e, t) {
69
+ let J = j.data?.timeCampusActiveFocusSession ?? null, St = M.data?.timeCampusFocusBlockSuggestions ?? [], Ct = N.data?.timeCampusFocusBlocks ?? [], Y = Ye.data?.timeCampusFocusSummary, X = Je.data?.timeCampusFocusCalendarConnection, wt = ye(X?.provider), Tt = !j.data && j.loading || !P.data && P.loading, Et = j.error ?? P.error;
70
+ async function Z(e, t) {
70
71
  try {
71
- await e(), ge(), A({
72
+ await e(), _e(), D({
72
73
  title: t,
73
74
  variant: "success"
74
75
  });
75
76
  } catch (e) {
76
- A({
77
- title: O(e),
77
+ D({
78
+ title: T(e),
78
79
  variant: "error"
79
80
  });
80
81
  }
81
82
  }
82
- let Dt = (e) => X(() => z({ variables: {
83
- plannedDurationSeconds: e ? void 0 : $e * 60,
84
- protectionLevel: tt ? a.Strict : a.Standard,
83
+ let Dt = (e) => Z(() => I({ variables: {
84
+ plannedDurationSeconds: e ? void 0 : V * 60,
85
+ protectionLevel: nt ? a.Strict : a.Standard,
85
86
  focusBlockId: e
86
- } }), "Focus session started"), Z = d(!1), Ot = d(() => void 0);
87
- l(() => {
88
- Ot.current = (e, t) => {
89
- t ? A({
87
+ } }), "Focus session started"), Ot = f(!1), kt = f(() => void 0);
88
+ u(() => {
89
+ kt.current = (e, t) => {
90
+ t ? D({
90
91
  title: "A focus session is already running",
91
92
  variant: "info"
92
- }) : X(() => z({ variables: { focusBlockId: e } }), "Focus block started");
93
+ }) : Z(() => I({ variables: { focusBlockId: e } }), "Focus block started");
93
94
  };
94
- }), l(() => {
95
- if (Z.current || !E || !P.data) return;
95
+ }), u(() => {
96
+ if (Ot.current || !C || !j.data) return;
96
97
  let e = Ee(window.location.search);
97
- e && (Z.current = !0, window.history.replaceState(window.history.state, "", Ae(window.location.href)), Ot.current(e, !!P.data.timeCampusActiveFocusSession));
98
- }, [E, P.data]);
99
- let kt = (e) => q ? X(() => Ke({ variables: {
100
- id: q.id,
98
+ e && (Ot.current = !0, window.history.replaceState(window.history.state, "", ke(window.location.href)), kt.current(e, !!j.data.timeCampusActiveFocusSession));
99
+ }, [C, j.data]);
100
+ let At = (e) => J ? Z(() => Xe({ variables: {
101
+ id: J.id,
101
102
  status: e
102
- } }), e === o.Completed ? "Focus session completed" : "Focus session abandoned") : void 0, Q = (e, t) => X(() => Ye({ variables: { input: {
103
+ } }), e === o.Completed ? "Focus session completed" : "Focus session abandoned") : void 0, Q = (e, t) => Z(() => Qe({ variables: { input: {
103
104
  startTime: e.startTime,
104
105
  endTime: e.endTime,
105
106
  response: t,
106
- dayStart: N.toISOString(),
107
+ dayStart: A.toISOString(),
107
108
  snoozeMinutes: t === i.Snooze ? 30 : null
108
- } } }), t === i.Accept ? "Focus block scheduled" : t === i.Snooze ? "Snoozed for 30 minutes" : "Suggestion dismissed"), At = () => {
109
- let e = ke(rt), t = ke(U);
110
- e === null || t === null ? A({
109
+ } } }), t === i.Accept ? "Focus block scheduled" : t === i.Snooze ? "Snoozed for 30 minutes" : "Suggestion dismissed"), jt = () => {
110
+ let e = l(it), t = l(U);
111
+ e === null || t === null ? D({
111
112
  title: "Use HH:MM for the workday",
112
113
  variant: "error"
113
- }) : X(() => Ze({ variables: { input: {
114
+ }) : Z(() => et({ variables: { input: {
114
115
  workdayStartMinute: e,
115
116
  workdayEndMinute: t,
116
117
  preferredBlockMinutes: W,
@@ -122,232 +123,232 @@ function k() {
122
123
  blockedApps: we(ht),
123
124
  doNotDisturb: _t,
124
125
  calendarHoldEnabled: yt,
125
- startNudgeMinutes: G
126
+ startNudgeMinutes: K
126
127
  } } }), "Focus settings saved");
127
128
  };
128
- if (Tt) return /* @__PURE__ */ v(t, {
129
- title: x,
130
- description: S,
131
- children: /* @__PURE__ */ v(ee, {
129
+ if (Tt) return /* @__PURE__ */ g(t, {
130
+ title: v,
131
+ description: y,
132
+ children: /* @__PURE__ */ g(ee, {
132
133
  variant: "card",
133
134
  count: 4
134
135
  })
135
136
  });
136
- if (Et && !P.data) return /* @__PURE__ */ v(t, {
137
- title: x,
138
- description: S,
139
- children: /* @__PURE__ */ v("div", {
137
+ if (Et && !j.data) return /* @__PURE__ */ g(t, {
138
+ title: v,
139
+ description: y,
140
+ children: /* @__PURE__ */ g("div", {
140
141
  className: "rounded-xl border border-status-error-border/50 bg-status-error-bg/10 p-4 text-sm text-status-error-text",
141
142
  children: "Failed to load focus protection. Please try again later."
142
143
  })
143
144
  });
144
- let $ = q ? Se(q.startTime, q.plannedDurationSeconds, M) : null, jt = J ? Math.round(J.averageProtectionRatio * 100) : null;
145
- return /* @__PURE__ */ y(t, {
146
- title: x,
147
- description: S,
145
+ let $ = J ? Ce(J.startTime, J.plannedDurationSeconds, k) : null, Mt = Y ? Math.round(Y.averageProtectionRatio * 100) : null;
146
+ return /* @__PURE__ */ _(t, {
147
+ title: v,
148
+ description: y,
148
149
  purpose: "Protect the hours that matter: TimeCampus suggests focus blocks around your meetings and the times you focus best, and blocks distracting sites in your browser, and in the desktop app turns on Do Not Disturb and hides distracting apps while a session runs.",
149
150
  children: [
150
- /* @__PURE__ */ v(te, {
151
- toasts: k,
152
- onDismiss: ze
151
+ /* @__PURE__ */ g(te, {
152
+ toasts: E,
153
+ onDismiss: Ue
153
154
  }),
154
- /* @__PURE__ */ y("div", {
155
+ /* @__PURE__ */ _("div", {
155
156
  className: "grid grid-cols-1 gap-4 sm:grid-cols-2 lg:grid-cols-4",
156
157
  children: [
157
- /* @__PURE__ */ v(n, {
158
+ /* @__PURE__ */ g(n, {
158
159
  featured: !0,
159
160
  title: "Protected Time",
160
- value: J ? c(J.totalProtectedSeconds) : "--",
161
- icon: /* @__PURE__ */ v(Pe, { className: "h-5 w-5" }),
161
+ value: Y ? s(Y.totalProtectedSeconds) : "--",
162
+ icon: /* @__PURE__ */ g(Fe, { className: "h-5 w-5" }),
162
163
  description: "Last 7 days"
163
164
  }),
164
- /* @__PURE__ */ v(n, {
165
+ /* @__PURE__ */ g(n, {
165
166
  title: "Protection Ratio",
166
- value: jt === null ? "--" : `${jt}%`,
167
- icon: /* @__PURE__ */ v(h, { className: "h-5 w-5" }),
167
+ value: Mt === null ? "--" : `${Mt}%`,
168
+ icon: /* @__PURE__ */ g(Pe, { className: "h-5 w-5" }),
168
169
  description: "Protected vs interrupted"
169
170
  }),
170
- /* @__PURE__ */ v(n, {
171
+ /* @__PURE__ */ g(n, {
171
172
  title: "Sessions",
172
- value: J ? String(J.totalSessions) : "--",
173
- icon: /* @__PURE__ */ v(g, { className: "h-5 w-5" }),
174
- description: J ? `${J.completedSessions} completed` : "Last 7 days"
173
+ value: Y ? String(Y.totalSessions) : "--",
174
+ icon: /* @__PURE__ */ g(Le, { className: "h-5 w-5" }),
175
+ description: Y ? `${Y.completedSessions} completed` : "Last 7 days"
175
176
  }),
176
- /* @__PURE__ */ v(n, {
177
+ /* @__PURE__ */ g(n, {
177
178
  title: "Interruptions",
178
- value: J ? String(J.totalInterruptionCount) : "--",
179
- icon: /* @__PURE__ */ v(p, { className: "h-5 w-5" }),
179
+ value: Y ? String(Y.totalInterruptionCount) : "--",
180
+ icon: /* @__PURE__ */ g(m, { className: "h-5 w-5" }),
180
181
  description: "Logged, detected or bypassed"
181
182
  })
182
183
  ]
183
184
  }),
184
- /* @__PURE__ */ v("div", {
185
+ /* @__PURE__ */ g("div", {
185
186
  className: "mt-6",
186
187
  "data-testid": "focus-session-card",
187
- children: /* @__PURE__ */ y(Le, {
188
+ children: /* @__PURE__ */ _(Be, {
188
189
  treatment: "glass",
189
190
  glow: !0,
190
191
  className: "p-6",
191
- children: [/* @__PURE__ */ y("div", {
192
+ children: [/* @__PURE__ */ _("div", {
192
193
  className: "flex flex-wrap items-start justify-between gap-4",
193
- children: [/* @__PURE__ */ y("div", { children: [/* @__PURE__ */ y("h3", {
194
+ children: [/* @__PURE__ */ _("div", { children: [/* @__PURE__ */ _("h3", {
194
195
  className: "flex items-center gap-2 text-sm font-semibold text-text-primary",
195
- children: [/* @__PURE__ */ v(h, { className: "h-4 w-4" }), "Focus session"]
196
- }), q ? /* @__PURE__ */ y("p", {
196
+ children: [/* @__PURE__ */ g(Pe, { className: "h-4 w-4" }), "Focus session"]
197
+ }), J ? /* @__PURE__ */ _("p", {
197
198
  className: "mt-1 text-sm text-text-secondary",
198
199
  "data-testid": "focus-session-status",
199
200
  children: [
200
201
  $ === null ? "Open-ended session in progress." : $ === 0 ? "Planned time is up — finish when you're ready." : `${$} minute${$ === 1 ? "" : "s"} left.`,
201
202
  " ",
202
- q.interruptionCount,
203
+ J.interruptionCount,
203
204
  " interruption",
204
- q.interruptionCount === 1 ? "" : "s",
205
+ J.interruptionCount === 1 ? "" : "s",
205
206
  ",",
206
207
  " ",
207
- q.blockedAttemptCount,
208
+ J.blockedAttemptCount,
208
209
  " distraction",
209
- q.blockedAttemptCount === 1 ? "" : "s",
210
+ J.blockedAttemptCount === 1 ? "" : "s",
210
211
  " blocked."
211
212
  ]
212
- }) : /* @__PURE__ */ v("p", {
213
+ }) : /* @__PURE__ */ g("p", {
213
214
  className: "mt-1 text-sm text-text-secondary",
214
215
  children: "No session running. While one is active, the TimeCampus browser extension blocks the sites listed below and the TimeCampus desktop app hides or flags the apps listed below."
215
- })] }), q && /* @__PURE__ */ v(r, {
216
- variant: q.protectionLevel === a.Strict ? "warning" : "success",
217
- label: q.protectionLevel === a.Strict ? "Strict" : "Standard"
216
+ })] }), J && /* @__PURE__ */ g(r, {
217
+ variant: J.protectionLevel === a.Strict ? "warning" : "success",
218
+ label: J.protectionLevel === a.Strict ? "Strict" : "Standard"
218
219
  })]
219
- }), /* @__PURE__ */ v("div", {
220
+ }), /* @__PURE__ */ g("div", {
220
221
  className: "mt-4 flex flex-wrap items-center gap-3",
221
- children: q ? /* @__PURE__ */ y(_, { children: [
222
- /* @__PURE__ */ y("button", {
222
+ children: J ? /* @__PURE__ */ _(ze, { children: [
223
+ /* @__PURE__ */ _("button", {
223
224
  type: "button",
224
- className: w,
225
- disabled: qe,
226
- onClick: () => kt(o.Completed),
225
+ className: x,
226
+ disabled: R,
227
+ onClick: () => At(o.Completed),
227
228
  "data-testid": "focus-end",
228
- children: [/* @__PURE__ */ v(Fe, { className: "h-4 w-4" }), " End session"]
229
+ children: [/* @__PURE__ */ g(Ie, { className: "h-4 w-4" }), " End session"]
229
230
  }),
230
- /* @__PURE__ */ v("button", {
231
+ /* @__PURE__ */ g("button", {
231
232
  type: "button",
232
- className: T,
233
- disabled: qe,
234
- onClick: () => kt(o.Abandoned),
233
+ className: S,
234
+ disabled: R,
235
+ onClick: () => At(o.Abandoned),
235
236
  children: "Abandon"
236
237
  }),
237
- /* @__PURE__ */ v("button", {
238
+ /* @__PURE__ */ g("button", {
238
239
  type: "button",
239
- className: T,
240
- onClick: () => X(() => Je({ variables: { focusSessionId: q.id } }), "Interruption logged"),
240
+ className: S,
241
+ onClick: () => Z(() => Ze({ variables: { focusSessionId: J.id } }), "Interruption logged"),
241
242
  "data-testid": "focus-log-interruption",
242
243
  children: "Log an interruption"
243
244
  })
244
- ] }) : /* @__PURE__ */ y(_, { children: [
245
- /* @__PURE__ */ y("label", {
245
+ ] }) : /* @__PURE__ */ _(ze, { children: [
246
+ /* @__PURE__ */ _("label", {
246
247
  className: "flex items-center gap-2 text-sm text-text-secondary",
247
- children: ["Length", /* @__PURE__ */ y(b, {
248
- className: C,
249
- value: $e,
250
- onChange: (e) => et(Number(e.target.value)),
248
+ children: ["Length", /* @__PURE__ */ _(Ve, {
249
+ className: b,
250
+ value: V,
251
+ onChange: (e) => tt(Number(e.target.value)),
251
252
  "data-testid": "focus-length",
252
253
  children: [
253
- /* @__PURE__ */ v("option", {
254
+ /* @__PURE__ */ g("option", {
254
255
  value: 25,
255
256
  children: "25 min"
256
257
  }),
257
- /* @__PURE__ */ v("option", {
258
+ /* @__PURE__ */ g("option", {
258
259
  value: 50,
259
260
  children: "50 min"
260
261
  }),
261
- /* @__PURE__ */ v("option", {
262
+ /* @__PURE__ */ g("option", {
262
263
  value: 90,
263
264
  children: "90 min"
264
265
  }),
265
- /* @__PURE__ */ v("option", {
266
+ /* @__PURE__ */ g("option", {
266
267
  value: 120,
267
268
  children: "2 hours"
268
269
  })
269
270
  ]
270
271
  })]
271
272
  }),
272
- /* @__PURE__ */ y("label", {
273
+ /* @__PURE__ */ _("label", {
273
274
  className: "flex items-center gap-2 text-sm text-text-secondary",
274
- children: [/* @__PURE__ */ v("input", {
275
+ children: [/* @__PURE__ */ g("input", {
275
276
  type: "checkbox",
276
- checked: tt,
277
- onChange: (e) => nt(e.target.checked),
277
+ checked: nt,
278
+ onChange: (e) => rt(e.target.checked),
278
279
  className: "h-4 w-4 rounded border-border-subtle"
279
280
  }), "Strict (no “continue anyway”)"]
280
281
  }),
281
- /* @__PURE__ */ y("button", {
282
+ /* @__PURE__ */ _("button", {
282
283
  type: "button",
283
- className: w,
284
- disabled: B,
284
+ className: x,
285
+ disabled: L,
285
286
  onClick: () => Dt(),
286
287
  "data-testid": "focus-start",
287
- children: [/* @__PURE__ */ v(m, { className: "h-4 w-4" }), " Start focus session"]
288
+ children: [/* @__PURE__ */ g(h, { className: "h-4 w-4" }), " Start focus session"]
288
289
  })
289
290
  ] })
290
291
  })]
291
292
  })
292
293
  }),
293
- /* @__PURE__ */ y("div", {
294
+ /* @__PURE__ */ _("div", {
294
295
  className: "mt-6 grid grid-cols-1 gap-6 lg:grid-cols-2",
295
- children: [/* @__PURE__ */ y("div", {
296
+ children: [/* @__PURE__ */ _("div", {
296
297
  className: "rounded-xl border border-border-seam bg-bg-surface p-6 shadow-elevation-1",
297
298
  "data-testid": "focus-suggestions",
298
299
  children: [
299
- /* @__PURE__ */ y("div", {
300
+ /* @__PURE__ */ _("div", {
300
301
  className: "flex flex-wrap items-center justify-between gap-2",
301
- children: [/* @__PURE__ */ y("h3", {
302
+ children: [/* @__PURE__ */ _("h3", {
302
303
  className: "flex items-center gap-2 text-sm font-semibold text-text-primary",
303
- children: [/* @__PURE__ */ v(Me, { className: "h-4 w-4" }), "Suggested focus blocks"]
304
- }), /* @__PURE__ */ v("div", {
304
+ children: [/* @__PURE__ */ g(Me, { className: "h-4 w-4" }), "Suggested focus blocks"]
305
+ }), /* @__PURE__ */ g("div", {
305
306
  className: "flex gap-1",
306
307
  role: "group",
307
308
  "aria-label": "Day to plan",
308
- children: ["Today", "Tomorrow"].map((e, t) => /* @__PURE__ */ v("button", {
309
+ children: ["Today", "Tomorrow"].map((e, t) => /* @__PURE__ */ g("button", {
309
310
  type: "button",
310
- "aria-pressed": j === t,
311
- className: j === t ? w : T,
312
- onClick: () => Be(t),
311
+ "aria-pressed": O === t,
312
+ className: O === t ? x : S,
313
+ onClick: () => We(t),
313
314
  children: e
314
315
  }, e))
315
316
  })]
316
317
  }),
317
- /* @__PURE__ */ v("p", {
318
+ /* @__PURE__ */ g("p", {
318
319
  className: "mt-1 text-xs text-text-secondary",
319
320
  children: "Ranked from your peak hours, meetings and how well past sessions held up. Snoozed and dismissed slots are planned around."
320
321
  }),
321
- /* @__PURE__ */ y("div", {
322
+ /* @__PURE__ */ _("div", {
322
323
  className: "mt-4 space-y-3",
323
324
  children: [
324
- F.error && /* @__PURE__ */ v("p", {
325
+ M.error && /* @__PURE__ */ g("p", {
325
326
  className: "text-sm text-status-error-text",
326
- children: O(F.error)
327
+ children: T(M.error)
327
328
  }),
328
- !F.error && F.data && St.length === 0 && /* @__PURE__ */ y("p", {
329
+ !M.error && M.data && St.length === 0 && /* @__PURE__ */ _("p", {
329
330
  className: "text-sm text-text-secondary",
330
331
  "data-testid": "focus-suggestions-empty",
331
332
  children: [
332
333
  "No free window left for",
333
334
  " ",
334
- j === 0 ? "today" : "tomorrow",
335
+ O === 0 ? "today" : "tomorrow",
335
336
  " — your day is full or you have scheduled your maximum blocks."
336
337
  ]
337
338
  }),
338
- St.map((e) => /* @__PURE__ */ y("div", {
339
+ St.map((e) => /* @__PURE__ */ _("div", {
339
340
  className: "rounded-lg border border-border-subtle p-3",
340
341
  "data-testid": "focus-suggestion",
341
342
  children: [
342
- /* @__PURE__ */ y("div", {
343
+ /* @__PURE__ */ _("div", {
343
344
  className: "flex flex-wrap items-center justify-between gap-2",
344
- children: [/* @__PURE__ */ y("span", {
345
+ children: [/* @__PURE__ */ _("span", {
345
346
  className: "text-sm font-medium text-text-primary",
346
- children: [be(e.startTime, e.endTime), /* @__PURE__ */ v("span", {
347
+ children: [xe(e.startTime, e.endTime), /* @__PURE__ */ g("span", {
347
348
  className: "ms-2 text-xs text-text-secondary",
348
- children: c(e.durationMinutes * 60)
349
+ children: s(e.durationMinutes * 60)
349
350
  })]
350
- }), /* @__PURE__ */ y("span", {
351
+ }), /* @__PURE__ */ _("span", {
351
352
  className: "text-xs text-text-secondary",
352
353
  children: [
353
354
  "Fit ",
@@ -356,39 +357,39 @@ function k() {
356
357
  ]
357
358
  })]
358
359
  }),
359
- /* @__PURE__ */ v("div", {
360
+ /* @__PURE__ */ g("div", {
360
361
  className: "mt-2 flex flex-wrap gap-1.5",
361
- children: e.reasons.map((e) => /* @__PURE__ */ v(r, {
362
+ children: e.reasons.map((e) => /* @__PURE__ */ g(r, {
362
363
  variant: "info",
363
364
  label: De(e)
364
365
  }, e))
365
366
  }),
366
- /* @__PURE__ */ y("div", {
367
+ /* @__PURE__ */ _("div", {
367
368
  className: "mt-3 flex flex-wrap gap-2",
368
369
  children: [
369
- /* @__PURE__ */ y("button", {
370
+ /* @__PURE__ */ _("button", {
370
371
  type: "button",
371
- className: w,
372
- disabled: V,
372
+ className: x,
373
+ disabled: z,
373
374
  onClick: () => Q(e, i.Accept),
374
375
  "data-testid": "focus-suggestion-accept",
375
- children: [/* @__PURE__ */ v(Ne, { className: "h-4 w-4" }), " Accept"]
376
+ children: [/* @__PURE__ */ g(Ne, { className: "h-4 w-4" }), " Accept"]
376
377
  }),
377
- /* @__PURE__ */ y("button", {
378
+ /* @__PURE__ */ _("button", {
378
379
  type: "button",
379
- className: T,
380
- disabled: V,
380
+ className: S,
381
+ disabled: z,
381
382
  onClick: () => Q(e, i.Snooze),
382
383
  "data-testid": "focus-suggestion-snooze",
383
- children: [/* @__PURE__ */ v(je, { className: "h-4 w-4" }), " Snooze 30 min"]
384
+ children: [/* @__PURE__ */ g(je, { className: "h-4 w-4" }), " Snooze 30 min"]
384
385
  }),
385
- /* @__PURE__ */ y("button", {
386
+ /* @__PURE__ */ _("button", {
386
387
  type: "button",
387
- className: T,
388
- disabled: V,
388
+ className: S,
389
+ disabled: z,
389
390
  onClick: () => Q(e, i.Dismiss),
390
391
  "data-testid": "focus-suggestion-dismiss",
391
- children: [/* @__PURE__ */ v(Ie, { className: "h-4 w-4" }), " Dismiss"]
392
+ children: [/* @__PURE__ */ g(Re, { className: "h-4 w-4" }), " Dismiss"]
392
393
  })
393
394
  ]
394
395
  })
@@ -397,64 +398,64 @@ function k() {
397
398
  ]
398
399
  })
399
400
  ]
400
- }), /* @__PURE__ */ y("div", {
401
+ }), /* @__PURE__ */ _("div", {
401
402
  className: "rounded-xl border border-border-seam bg-bg-surface p-6 shadow-elevation-1",
402
403
  "data-testid": "focus-scheduled",
403
404
  children: [
404
- /* @__PURE__ */ y("h3", {
405
+ /* @__PURE__ */ _("h3", {
405
406
  className: "flex items-center gap-2 text-sm font-semibold text-text-primary",
406
407
  children: [
407
- /* @__PURE__ */ v(g, { className: "h-4 w-4" }),
408
+ /* @__PURE__ */ g(Le, { className: "h-4 w-4" }),
408
409
  "Scheduled (",
409
- j === 0 ? "today" : "tomorrow",
410
+ O === 0 ? "today" : "tomorrow",
410
411
  ")"
411
412
  ]
412
413
  }),
413
- Y && /* @__PURE__ */ v("p", {
414
+ X && /* @__PURE__ */ g("p", {
414
415
  className: "mt-1 text-xs text-text-secondary",
415
416
  "data-testid": "focus-calendar-connection",
416
- children: Y.holdsEnabled ? Y.connected ? `Accepted blocks are held as busy "Focus" time on ${Y.calendarName ?? "your calendar"}${wt ? ` and sync to ${wt}` : ""}.` : Y.reachable ? "No personal calendar yet. Create one in Calendar to hold accepted blocks there and plan around its events." : "Your calendar could not be reached just now; blocks are still scheduled here." : "Calendar holds are off — accepted blocks stay in TimeCampus only."
417
+ children: X.holdsEnabled ? X.connected ? `Accepted blocks are held as busy "Focus" time on ${X.calendarName ?? "your calendar"}${wt ? ` and sync to ${wt}` : ""}.` : X.reachable ? "No personal calendar yet. Create one in Calendar to hold accepted blocks there and plan around its events." : "Your calendar could not be reached just now; blocks are still scheduled here." : "Calendar holds are off — accepted blocks stay in TimeCampus only."
417
418
  }),
418
- /* @__PURE__ */ y("div", {
419
+ /* @__PURE__ */ _("div", {
419
420
  className: "mt-4 space-y-3",
420
- children: [I.data && Ct.length === 0 && /* @__PURE__ */ v("p", {
421
+ children: [N.data && Ct.length === 0 && /* @__PURE__ */ g("p", {
421
422
  className: "text-sm text-text-secondary",
422
423
  children: "Accept a suggestion to put a focus block on your schedule."
423
424
  }), Ct.map((e) => {
424
- let t = _e(e.calendarHoldStatus, e.calendarId && e.calendarId === Y?.calendarId ? Y?.calendarName : null);
425
- return /* @__PURE__ */ y("div", {
425
+ let t = ve(e.calendarHoldStatus, e.calendarId && e.calendarId === X?.calendarId ? X?.calendarName : null);
426
+ return /* @__PURE__ */ _("div", {
426
427
  className: "flex flex-wrap items-center justify-between gap-2 rounded-lg border border-border-subtle p-3",
427
428
  "data-testid": "focus-scheduled-block",
428
- children: [/* @__PURE__ */ y("div", { children: [/* @__PURE__ */ v("p", {
429
+ children: [/* @__PURE__ */ _("div", { children: [/* @__PURE__ */ g("p", {
429
430
  className: "text-sm font-medium text-text-primary",
430
- children: be(e.startTime, e.endTime)
431
- }), /* @__PURE__ */ y("p", {
431
+ children: xe(e.startTime, e.endTime)
432
+ }), /* @__PURE__ */ _("p", {
432
433
  className: "text-xs text-text-secondary",
433
434
  children: [
434
435
  e.source === "ADAPTIVE" ? "Suggested" : "Manual",
435
436
  " ·",
436
437
  " ",
437
- c(e.durationMinutes * 60),
438
- t && /* @__PURE__ */ y("span", {
438
+ s(e.durationMinutes * 60),
439
+ t && /* @__PURE__ */ _("span", {
439
440
  "data-testid": "focus-block-calendar-hold",
440
441
  children: [" · ", t]
441
442
  })
442
443
  ]
443
- })] }), e.status === "STARTED" ? /* @__PURE__ */ v(r, {
444
+ })] }), e.status === "STARTED" ? /* @__PURE__ */ g(r, {
444
445
  variant: "success",
445
446
  label: "Started"
446
- }) : /* @__PURE__ */ y("div", {
447
+ }) : /* @__PURE__ */ _("div", {
447
448
  className: "flex gap-2",
448
- children: [!q && ye(e.endTime, M) && /* @__PURE__ */ y("button", {
449
+ children: [!J && be(e.endTime, k) && /* @__PURE__ */ _("button", {
449
450
  type: "button",
450
- className: w,
451
- disabled: B,
451
+ className: x,
452
+ disabled: L,
452
453
  onClick: () => Dt(e.id),
453
- children: [/* @__PURE__ */ v(m, { className: "h-4 w-4" }), " Start"]
454
- }), /* @__PURE__ */ v("button", {
454
+ children: [/* @__PURE__ */ g(h, { className: "h-4 w-4" }), " Start"]
455
+ }), /* @__PURE__ */ g("button", {
455
456
  type: "button",
456
- className: T,
457
- onClick: () => X(() => Xe({ variables: { id: e.id } }), "Focus block canceled"),
457
+ className: S,
458
+ onClick: () => Z(() => $e({ variables: { id: e.id } }), "Focus block canceled"),
458
459
  "data-testid": "focus-block-cancel",
459
460
  children: "Cancel"
460
461
  })]
@@ -465,22 +466,22 @@ function k() {
465
466
  ]
466
467
  })]
467
468
  }),
468
- /* @__PURE__ */ y("div", {
469
+ /* @__PURE__ */ _("div", {
469
470
  className: "mt-6 rounded-xl border border-border-seam bg-bg-surface p-6 shadow-elevation-1",
470
471
  "data-testid": "focus-settings",
471
472
  children: [
472
- /* @__PURE__ */ y("h3", {
473
+ /* @__PURE__ */ _("h3", {
473
474
  className: "flex items-center gap-2 text-sm font-semibold text-text-primary",
474
- children: [/* @__PURE__ */ v(p, { className: "h-4 w-4" }), "Distraction blocking and planning"]
475
+ children: [/* @__PURE__ */ g(m, { className: "h-4 w-4" }), "Distraction blocking and planning"]
475
476
  }),
476
- /* @__PURE__ */ y("div", {
477
+ /* @__PURE__ */ _("div", {
477
478
  className: "mt-4 grid grid-cols-1 gap-6 lg:grid-cols-2",
478
- children: [/* @__PURE__ */ y("div", {
479
+ children: [/* @__PURE__ */ _("div", {
479
480
  className: "space-y-3",
480
481
  children: [
481
- /* @__PURE__ */ y("label", {
482
+ /* @__PURE__ */ _("label", {
482
483
  className: "flex items-center justify-between gap-4 text-sm text-text-primary",
483
- children: ["Block sites and apps during focus sessions", /* @__PURE__ */ v("input", {
484
+ children: ["Block sites and apps during focus sessions", /* @__PURE__ */ g("input", {
484
485
  type: "checkbox",
485
486
  checked: dt,
486
487
  onChange: (e) => ft(e.target.checked),
@@ -488,41 +489,41 @@ function k() {
488
489
  "data-testid": "focus-blocking-enabled"
489
490
  })]
490
491
  }),
491
- /* @__PURE__ */ y("label", {
492
+ /* @__PURE__ */ _("label", {
492
493
  className: "block text-sm text-text-primary",
493
- children: ["Blocked sites", /* @__PURE__ */ v("textarea", {
494
+ children: ["Blocked sites", /* @__PURE__ */ g("textarea", {
494
495
  rows: 6,
495
496
  value: pt,
496
497
  onChange: (e) => mt(e.target.value),
497
- className: `${C} mt-1 w-full font-mono`,
498
+ className: `${b} mt-1 w-full font-mono`,
498
499
  "aria-describedby": "focus-sites-help",
499
500
  "data-testid": "focus-blocked-sites"
500
501
  })]
501
502
  }),
502
- /* @__PURE__ */ v("p", {
503
+ /* @__PURE__ */ g("p", {
503
504
  id: "focus-sites-help",
504
505
  className: "text-xs text-text-secondary",
505
506
  children: "One site per line (subdomains are included). Blocking is enforced by the TimeCampus browser extension while a session is active; allow-listed apps on a session are never blocked."
506
507
  }),
507
- /* @__PURE__ */ y("label", {
508
+ /* @__PURE__ */ _("label", {
508
509
  className: "block text-sm text-text-primary",
509
- children: ["Blocked desktop apps", /* @__PURE__ */ v("textarea", {
510
+ children: ["Blocked desktop apps", /* @__PURE__ */ g("textarea", {
510
511
  rows: 5,
511
512
  value: ht,
512
513
  onChange: (e) => gt(e.target.value),
513
- className: `${C} mt-1 w-full font-mono`,
514
+ className: `${b} mt-1 w-full font-mono`,
514
515
  "aria-describedby": "focus-apps-help",
515
516
  "data-testid": "focus-blocked-apps"
516
517
  })]
517
518
  }),
518
- /* @__PURE__ */ v("p", {
519
+ /* @__PURE__ */ g("p", {
519
520
  id: "focus-apps-help",
520
521
  className: "text-xs text-text-secondary",
521
522
  children: "One app per line, as your computer names it (for example Discord or Steam). In the TimeCampus desktop app, strict sessions hide these apps and standard sessions warn you and count the time as an interruption."
522
523
  }),
523
- /* @__PURE__ */ y("label", {
524
+ /* @__PURE__ */ _("label", {
524
525
  className: "flex items-center justify-between gap-4 text-sm text-text-primary",
525
- children: ["Turn on Do Not Disturb during focus sessions", /* @__PURE__ */ v("input", {
526
+ children: ["Turn on Do Not Disturb during focus sessions", /* @__PURE__ */ g("input", {
526
527
  type: "checkbox",
527
528
  checked: _t,
528
529
  onChange: (e) => vt(e.target.checked),
@@ -530,79 +531,75 @@ function k() {
530
531
  "data-testid": "focus-do-not-disturb"
531
532
  })]
532
533
  }),
533
- K && /* @__PURE__ */ y("p", {
534
+ q && /* @__PURE__ */ _("p", {
534
535
  className: "text-xs text-text-secondary",
535
536
  "data-testid": "focus-desktop-status",
536
537
  children: [
537
538
  "This computer: Do Not Disturb",
538
539
  " ",
539
- D(K.doNotDisturb),
540
+ w(q.doNotDisturb),
540
541
  ", app blocking",
541
542
  " ",
542
- D(K.appWatcher),
543
+ w(q.appWatcher),
543
544
  ".",
544
- K.detail ? ` ${K.detail}` : ""
545
+ q.detail ? ` ${q.detail}` : ""
545
546
  ]
546
547
  })
547
548
  ]
548
- }), /* @__PURE__ */ y("div", {
549
+ }), /* @__PURE__ */ _("div", {
549
550
  className: "space-y-3",
550
551
  children: [
551
- /* @__PURE__ */ y("div", {
552
+ /* @__PURE__ */ _("div", {
552
553
  className: "flex items-center justify-between gap-4",
553
- children: [/* @__PURE__ */ v("span", {
554
+ children: [/* @__PURE__ */ g("span", {
554
555
  className: "text-sm text-text-primary",
555
556
  children: "Workday"
556
- }), /* @__PURE__ */ y("span", {
557
+ }), /* @__PURE__ */ _("span", {
557
558
  className: "flex items-center gap-2",
558
559
  children: [
559
- /* @__PURE__ */ v("input", {
560
- type: "time",
561
- value: rt,
562
- onChange: (e) => it(e.target.value),
563
- className: C,
564
- "aria-label": "Workday start"
560
+ /* @__PURE__ */ g(Ae, {
561
+ value: it,
562
+ onChange: at,
563
+ label: "Workday start"
565
564
  }),
566
- /* @__PURE__ */ v("span", {
565
+ /* @__PURE__ */ g("span", {
567
566
  className: "text-text-secondary",
568
567
  children: "to"
569
568
  }),
570
- /* @__PURE__ */ v("input", {
571
- type: "time",
569
+ /* @__PURE__ */ g(Ae, {
572
570
  value: U === "24:00" ? "23:59" : U,
573
- onChange: (e) => at(e.target.value),
574
- className: C,
575
- "aria-label": "Workday end"
571
+ onChange: ot,
572
+ label: "Workday end"
576
573
  })
577
574
  ]
578
575
  })]
579
576
  }),
580
- /* @__PURE__ */ y("label", {
577
+ /* @__PURE__ */ _("label", {
581
578
  className: "flex items-center justify-between gap-4 text-sm text-text-primary",
582
- children: ["Preferred block length (minutes)", /* @__PURE__ */ v("input", {
579
+ children: ["Preferred block length (minutes)", /* @__PURE__ */ g("input", {
583
580
  type: "number",
584
581
  min: 15,
585
582
  max: 240,
586
583
  step: 15,
587
584
  value: W,
588
- onChange: (e) => ot(Number(e.target.value)),
589
- className: `${C} w-24 text-end`
585
+ onChange: (e) => G(Number(e.target.value)),
586
+ className: `${b} w-24 text-end`
590
587
  })]
591
588
  }),
592
- /* @__PURE__ */ y("label", {
589
+ /* @__PURE__ */ _("label", {
593
590
  className: "flex items-center justify-between gap-4 text-sm text-text-primary",
594
- children: ["Focus blocks per day", /* @__PURE__ */ v("input", {
591
+ children: ["Focus blocks per day", /* @__PURE__ */ g("input", {
595
592
  type: "number",
596
593
  min: 1,
597
594
  max: 6,
598
595
  value: st,
599
596
  onChange: (e) => ct(Number(e.target.value)),
600
- className: `${C} w-24 text-end`
597
+ className: `${b} w-24 text-end`
601
598
  })]
602
599
  }),
603
- /* @__PURE__ */ y("label", {
600
+ /* @__PURE__ */ _("label", {
604
601
  className: "flex items-center justify-between gap-4 text-sm text-text-primary",
605
- children: ["Hold accepted blocks on my calendar", /* @__PURE__ */ v("input", {
602
+ children: ["Hold accepted blocks on my calendar", /* @__PURE__ */ g("input", {
606
603
  type: "checkbox",
607
604
  checked: yt,
608
605
  onChange: (e) => bt(e.target.checked),
@@ -610,43 +607,43 @@ function k() {
610
607
  "data-testid": "focus-calendar-hold"
611
608
  })]
612
609
  }),
613
- /* @__PURE__ */ y("label", {
610
+ /* @__PURE__ */ _("label", {
614
611
  className: "flex items-center justify-between gap-4 text-sm text-text-primary",
615
- children: ["Remind me before a block starts", /* @__PURE__ */ v(b, {
616
- value: G,
612
+ children: ["Remind me before a block starts", /* @__PURE__ */ g(Ve, {
613
+ value: K,
617
614
  onChange: (e) => xt(Number(e.target.value)),
618
- className: C,
615
+ className: b,
619
616
  "data-testid": "focus-start-nudge",
620
- children: Oe(G).map((e) => /* @__PURE__ */ v("option", {
617
+ children: Oe(K).map((e) => /* @__PURE__ */ g("option", {
621
618
  value: e.value,
622
619
  children: e.label
623
620
  }, e.value))
624
621
  })]
625
622
  }),
626
- /* @__PURE__ */ y("label", {
623
+ /* @__PURE__ */ _("label", {
627
624
  className: "flex items-center justify-between gap-4 text-sm text-text-primary",
628
- children: ["Buffer around meetings (minutes)", /* @__PURE__ */ v("input", {
625
+ children: ["Buffer around meetings (minutes)", /* @__PURE__ */ g("input", {
629
626
  type: "number",
630
627
  min: 0,
631
628
  max: 60,
632
629
  step: 5,
633
630
  value: lt,
634
631
  onChange: (e) => ut(Number(e.target.value)),
635
- className: `${C} w-24 text-end`
632
+ className: `${b} w-24 text-end`
636
633
  })]
637
634
  })
638
635
  ]
639
636
  })]
640
637
  }),
641
- /* @__PURE__ */ v("div", {
638
+ /* @__PURE__ */ g("div", {
642
639
  className: "mt-4 flex justify-end",
643
- children: /* @__PURE__ */ v("button", {
640
+ children: /* @__PURE__ */ g("button", {
644
641
  type: "button",
645
- className: w,
646
- disabled: Qe,
647
- onClick: At,
642
+ className: x,
643
+ disabled: B,
644
+ onClick: jt,
648
645
  "data-testid": "focus-save-settings",
649
- children: Qe ? "Saving..." : "Save focus settings"
646
+ children: B ? "Saving..." : "Save focus settings"
650
647
  })
651
648
  })
652
649
  ]
@@ -654,6 +651,6 @@ function k() {
654
651
  ]
655
652
  });
656
653
  }
657
- export { k as FocusProtectionPage };
654
+ export { E as FocusProtectionPage };
658
655
 
659
656
  //# sourceMappingURL=FocusProtectionPage.js.map