@burdenoff/microfe-timecampus 2026.1203.1 → 2026.1204.1
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/timecampus/components/EmptyState.d.ts +7 -0
- package/dist/timecampus/components/EmptyState.js +3 -2
- package/dist/timecampus/components/EmptyState.js.map +1 -1
- package/dist/timecampus/components/FilterBar.js +1 -0
- package/dist/timecampus/components/Toast.js +1 -1
- package/dist/timecampus/components/Toast.js.map +1 -1
- package/dist/timecampus/components/charts/Heatmap.js +1 -1
- package/dist/timecampus/components/charts/Heatmap.js.map +1 -1
- package/dist/timecampus/components/maps/LocationGeofenceMap.js +3 -3
- package/dist/timecampus/components/maps/LocationGeofenceMap.js.map +1 -1
- package/dist/timecampus/pages/HomePage.js +1 -1
- package/dist/timecampus/pages/HomePage.js.map +1 -1
- package/dist/timecampus/pages/admin/AdminPage.js +283 -283
- package/dist/timecampus/pages/admin/AdminPage.js.map +1 -1
- package/dist/timecampus/pages/application-usage/ApplicationUsagePage.js +79 -79
- package/dist/timecampus/pages/application-usage/ApplicationUsagePage.js.map +1 -1
- package/dist/timecampus/pages/channels/ChannelsPage.js +8 -8
- package/dist/timecampus/pages/channels/ChannelsPage.js.map +1 -1
- package/dist/timecampus/pages/client-portal/ClientPortalPage.js +2 -2
- package/dist/timecampus/pages/client-portal/ClientPortalPage.js.map +1 -1
- package/dist/timecampus/pages/dashboard/ServerReportExports.js +34 -34
- package/dist/timecampus/pages/dashboard/ServerReportExports.js.map +1 -1
- package/dist/timecampus/pages/expense-tracking/ExpenseTrackingPage.js +49 -48
- package/dist/timecampus/pages/expense-tracking/ExpenseTrackingPage.js.map +1 -1
- package/dist/timecampus/pages/extend/AppletDeveloperPage.js +122 -117
- package/dist/timecampus/pages/extend/AppletDeveloperPage.js.map +1 -1
- package/dist/timecampus/pages/extend/AppletReviewPage.js +2 -2
- package/dist/timecampus/pages/extend/AppletReviewPage.js.map +1 -1
- package/dist/timecampus/pages/extend/AppletStorePage.js +2 -2
- package/dist/timecampus/pages/extend/AppletStorePage.js.map +1 -1
- package/dist/timecampus/pages/extend/MarketplaceCertificationPage.js +131 -126
- package/dist/timecampus/pages/extend/MarketplaceCertificationPage.js.map +1 -1
- package/dist/timecampus/pages/extend/ThirdPartyAppletsSection.js +94 -94
- package/dist/timecampus/pages/extend/ThirdPartyAppletsSection.js.map +1 -1
- package/dist/timecampus/pages/extend/TimeTriggersPage.js +98 -98
- package/dist/timecampus/pages/extend/TimeTriggersPage.js.map +1 -1
- package/dist/timecampus/pages/focus/FocusProtectionPage.js +121 -121
- package/dist/timecampus/pages/focus/FocusProtectionPage.js.map +1 -1
- package/dist/timecampus/pages/geofencing/GeofencingPage.js +348 -348
- package/dist/timecampus/pages/geofencing/GeofencingPage.js.map +1 -1
- package/dist/timecampus/pages/lifetime/LifeBalancePage.js +3 -3
- package/dist/timecampus/pages/lifetime/LifeBalancePage.js.map +1 -1
- package/dist/timecampus/pages/lifetime/LifeTimelinePage.js +25 -25
- package/dist/timecampus/pages/lifetime/LifeTimelinePage.js.map +1 -1
- package/dist/timecampus/pages/lifetime/RecommendationsPage.js +297 -297
- package/dist/timecampus/pages/lifetime/RecommendationsPage.js.map +1 -1
- package/dist/timecampus/pages/lifetime/ValuesGoalsPage.js +189 -189
- package/dist/timecampus/pages/lifetime/ValuesGoalsPage.js.map +1 -1
- package/dist/timecampus/pages/location-tracking/LocationTrackingPage.js +2 -2
- package/dist/timecampus/pages/location-tracking/LocationTrackingPage.js.map +1 -1
- package/dist/timecampus/pages/meetings/ActionItemFormModal.js +47 -46
- package/dist/timecampus/pages/meetings/ActionItemFormModal.js.map +1 -1
- package/dist/timecampus/pages/meetings/MeetingDetailPage.js +207 -207
- package/dist/timecampus/pages/meetings/MeetingDetailPage.js.map +1 -1
- package/dist/timecampus/pages/meetings/MeetingFormModal.js +73 -72
- package/dist/timecampus/pages/meetings/MeetingFormModal.js.map +1 -1
- package/dist/timecampus/pages/meetings/MeetingsPage.js +1 -1
- package/dist/timecampus/pages/meetings/MeetingsPage.js.map +1 -1
- package/dist/timecampus/pages/meetings/ParticipantFormModal.js +32 -31
- package/dist/timecampus/pages/meetings/ParticipantFormModal.js.map +1 -1
- package/dist/timecampus/pages/mobile/MobileScreen.js +1 -1
- package/dist/timecampus/pages/mobile/MobileScreen.js.map +1 -1
- package/dist/timecampus/pages/mobile/MobileTimelinePage.js +8 -8
- package/dist/timecampus/pages/mobile/MobileTimelinePage.js.map +1 -1
- package/dist/timecampus/pages/pomodoro/PomodoroAnalyticsPage.js +1 -1
- package/dist/timecampus/pages/pomodoro/PomodoroAnalyticsPage.js.map +1 -1
- package/dist/timecampus/pages/pomodoro/PomodoroPage.js +34 -34
- package/dist/timecampus/pages/pomodoro/PomodoroPage.js.map +1 -1
- package/dist/timecampus/pages/pomodoro/PomodoroSettingsPage.js +3 -3
- package/dist/timecampus/pages/pomodoro/PomodoroSettingsPage.js.map +1 -1
- package/dist/timecampus/pages/projects/ProjectDetailPage.js +163 -163
- package/dist/timecampus/pages/projects/ProjectDetailPage.js.map +1 -1
- package/dist/timecampus/pages/projects/ProjectsPage.js +193 -192
- package/dist/timecampus/pages/projects/ProjectsPage.js.map +1 -1
- package/dist/timecampus/pages/projects/TasksPage.js +92 -92
- package/dist/timecampus/pages/projects/TasksPage.js.map +1 -1
- package/dist/timecampus/pages/resource-planning/ResourcePlanningPage.js +66 -66
- package/dist/timecampus/pages/resource-planning/ResourcePlanningPage.js.map +1 -1
- package/dist/timecampus/pages/settings/IdleDetectionCard.js +33 -33
- package/dist/timecampus/pages/settings/IdleDetectionCard.js.map +1 -1
- package/dist/timecampus/pages/settings/PrivacySettingsPage.js +32 -32
- package/dist/timecampus/pages/settings/PrivacySettingsPage.js.map +1 -1
- package/dist/timecampus/pages/settings/SettingsPage.js +3 -3
- package/dist/timecampus/pages/settings/SettingsPage.js.map +1 -1
- package/dist/timecampus/pages/team/TeamMembersPage.js +1 -1
- package/dist/timecampus/pages/team/TeamMembersPage.js.map +1 -1
- package/dist/timecampus/pages/time/TimeEntriesPage.js +169 -169
- package/dist/timecampus/pages/time/TimeEntriesPage.js.map +1 -1
- package/dist/timecampus/pages/time/TimeTrackingPage.js +32 -32
- package/dist/timecampus/pages/time/TimeTrackingPage.js.map +1 -1
- package/dist/timecampus/pages/time/TimerPage.js +85 -85
- package/dist/timecampus/pages/time/TimerPage.js.map +1 -1
- package/dist/timecampus/pages/time-approval/SubmitTimesheetModal.js +1 -1
- package/dist/timecampus/pages/time-approval/SubmitTimesheetModal.js.map +1 -1
- package/dist/timecampus/pages/timeline/TimelinePage.js +227 -227
- package/dist/timecampus/pages/timeline/TimelinePage.js.map +1 -1
- package/dist/timecampus/shared/hooks/useConfirmedAction.d.ts +10 -0
- package/dist/timecampus/shared/hooks/useConfirmedAction.js +14 -0
- package/dist/timecampus/shared/hooks/useConfirmedAction.js.map +1 -0
- package/package.json +6 -4
|
@@ -15,7 +15,7 @@ import { useCreateLifeGoalMutation as ce, useDeclareLifeValueMutation as le, use
|
|
|
15
15
|
import { useState as o } from "react";
|
|
16
16
|
import { Briefcase as s, Bus as c, Circle as l, Coffee as ge, Compass as _e, Flag as ve, GraduationCap as u, Handshake as d, Heart as ye, HeartPulse as f, Home as p, Hourglass as m, Layers as be, Moon as xe, Pencil as Se, Plus as Ce, Sparkles as h, Target as we, Trash2 as Te, Users as Ee, Wallet as g } from "lucide-react";
|
|
17
17
|
import { Fragment as _, jsx as v, jsxs as y } from "react/jsx-runtime";
|
|
18
|
-
import { GlassCard as De } from "@burdenoff/fe-libs/ui";
|
|
18
|
+
import { GlassCard as De, ThemedSelect as b } from "@burdenoff/fe-libs/ui";
|
|
19
19
|
// src/timecampus/pages/lifetime/ValuesGoalsPage.tsx
|
|
20
20
|
var Oe = [
|
|
21
21
|
"daily",
|
|
@@ -33,7 +33,7 @@ var Oe = [
|
|
|
33
33
|
"sessions",
|
|
34
34
|
"days",
|
|
35
35
|
"times"
|
|
36
|
-
],
|
|
36
|
+
], x = {
|
|
37
37
|
[a.Work]: s,
|
|
38
38
|
[a.Sleep]: xe,
|
|
39
39
|
[a.Health]: f,
|
|
@@ -48,20 +48,20 @@ var Oe = [
|
|
|
48
48
|
[a.FinanceAdmin]: g,
|
|
49
49
|
[a.Reflection]: h,
|
|
50
50
|
[a.Other]: l
|
|
51
|
-
},
|
|
52
|
-
function
|
|
51
|
+
}, S = "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", C = "block text-sm font-medium text-text-primary", w = "inline-flex items-center gap-1.5 rounded-md bg-action-primary-bg px-3 py-2 text-sm font-medium text-action-primary-text hover:bg-action-primary-bg/90 disabled:opacity-50", T = "rounded-md border border-border-subtle px-4 py-2 text-sm font-medium text-text-primary hover:bg-bg-sunken/50", E = "rounded-md bg-status-error-bg px-4 py-2 text-sm font-medium text-status-error-text hover:bg-status-error-bg/80 disabled:opacity-50", D = "rounded-md p-1.5 text-text-secondary hover:bg-bg-sunken hover:text-text-primary";
|
|
52
|
+
function O(e) {
|
|
53
53
|
return e && e.charAt(0).toUpperCase() + e.slice(1);
|
|
54
54
|
}
|
|
55
|
-
function
|
|
56
|
-
return
|
|
55
|
+
function k(e) {
|
|
56
|
+
return x[e] ?? l;
|
|
57
57
|
}
|
|
58
|
-
var
|
|
58
|
+
var A = {
|
|
59
59
|
name: "",
|
|
60
60
|
description: "",
|
|
61
61
|
weight: "1",
|
|
62
62
|
domains: [],
|
|
63
63
|
isActive: !0
|
|
64
|
-
},
|
|
64
|
+
}, j = {
|
|
65
65
|
title: "",
|
|
66
66
|
domain: a.Health,
|
|
67
67
|
targetValue: "",
|
|
@@ -70,36 +70,36 @@ var k = {
|
|
|
70
70
|
status: "active",
|
|
71
71
|
valueId: ""
|
|
72
72
|
};
|
|
73
|
-
function
|
|
74
|
-
let { workspaceId: s = "" } = ee(), { toasts: c, addToast: l, dismissToast: ge } = ae(), { data: u, loading: d, error: ye, refetch: f } = pe({ skip: !s }), { data: p, loading: m, error: xe, refetch: h } = fe({ skip: !s }), [Ee, { loading: g }] = le(), [
|
|
75
|
-
|
|
76
|
-
},
|
|
77
|
-
|
|
73
|
+
function M() {
|
|
74
|
+
let { workspaceId: s = "" } = ee(), { toasts: c, addToast: l, dismissToast: ge } = ae(), { data: u, loading: d, error: ye, refetch: f } = pe({ skip: !s }), { data: p, loading: m, error: xe, refetch: h } = fe({ skip: !s }), [Ee, { loading: g }] = le(), [x, { loading: M }] = he(), [je, { loading: N }] = de(), [Me, { loading: Ne }] = ce(), [Pe, { loading: Fe }] = me(), [Ie, { loading: Le }] = ue(), P = u?.myLifeValues ?? [], F = p?.myLifeGoals ?? [], Re = P.filter((e) => e.isActive).length, ze = new Set(P.flatMap((e) => e.domains)).size, Be = Math.max(1, ...P.map((e) => e.weight)), Ve = new Map(P.map((e) => [e.id, e.name])), [He, I] = o(!1), [L, R] = o(null), [z, B] = o(A), [V, H] = o(null), [Ue, U] = o(!1), [W, G] = o(null), [K, q] = o(j), [J, Y] = o(null), We = () => {
|
|
75
|
+
R(null), B(A), I(!0);
|
|
76
|
+
}, Ge = (e) => {
|
|
77
|
+
R(e), B({
|
|
78
78
|
name: e.name,
|
|
79
79
|
description: e.description ?? "",
|
|
80
80
|
weight: String(e.weight),
|
|
81
81
|
domains: [...e.domains],
|
|
82
82
|
isActive: e.isActive
|
|
83
|
-
}),
|
|
84
|
-
},
|
|
85
|
-
|
|
86
|
-
},
|
|
87
|
-
|
|
83
|
+
}), I(!0);
|
|
84
|
+
}, X = () => {
|
|
85
|
+
I(!1), R(null);
|
|
86
|
+
}, Ke = (e) => {
|
|
87
|
+
B((t) => ({
|
|
88
88
|
...t,
|
|
89
89
|
domains: t.domains.includes(e) ? t.domains.filter((t) => t !== e) : [...t.domains, e]
|
|
90
90
|
}));
|
|
91
|
-
},
|
|
92
|
-
if (!
|
|
93
|
-
let e =
|
|
94
|
-
name:
|
|
95
|
-
description:
|
|
91
|
+
}, Z = z.name.trim().length > 0 && (z.weight === "" || !Number.isNaN(Number(z.weight))), qe = async () => {
|
|
92
|
+
if (!Z) return;
|
|
93
|
+
let e = z.weight.trim() === "" ? void 0 : Number(z.weight), t = {
|
|
94
|
+
name: z.name.trim(),
|
|
95
|
+
description: z.description.trim() || void 0,
|
|
96
96
|
weight: e,
|
|
97
|
-
domains:
|
|
98
|
-
isActive:
|
|
97
|
+
domains: z.domains,
|
|
98
|
+
isActive: z.isActive
|
|
99
99
|
};
|
|
100
100
|
try {
|
|
101
|
-
|
|
102
|
-
id:
|
|
101
|
+
L ? (await x({ variables: {
|
|
102
|
+
id: L.id,
|
|
103
103
|
input: t
|
|
104
104
|
} }), l({
|
|
105
105
|
title: "Value updated",
|
|
@@ -107,29 +107,29 @@ function j() {
|
|
|
107
107
|
})) : (await Ee({ variables: { input: t } }), l({
|
|
108
108
|
title: "Value declared",
|
|
109
109
|
variant: "success"
|
|
110
|
-
})),
|
|
110
|
+
})), X(), await Promise.all([f(), h()]);
|
|
111
111
|
} catch {
|
|
112
112
|
l({
|
|
113
|
-
title:
|
|
113
|
+
title: L ? "Failed to update value" : "Failed to declare value",
|
|
114
114
|
variant: "error"
|
|
115
115
|
});
|
|
116
116
|
}
|
|
117
|
-
},
|
|
118
|
-
if (
|
|
119
|
-
await je({ variables: { id:
|
|
117
|
+
}, Je = async () => {
|
|
118
|
+
if (V) try {
|
|
119
|
+
await je({ variables: { id: V.id } }), l({
|
|
120
120
|
title: "Value deleted",
|
|
121
121
|
variant: "success"
|
|
122
|
-
}),
|
|
122
|
+
}), H(null), await Promise.all([f(), h()]);
|
|
123
123
|
} catch {
|
|
124
124
|
l({
|
|
125
125
|
title: "Failed to delete value",
|
|
126
126
|
variant: "error"
|
|
127
127
|
});
|
|
128
128
|
}
|
|
129
|
-
},
|
|
130
|
-
|
|
131
|
-
},
|
|
132
|
-
|
|
129
|
+
}, Ye = () => {
|
|
130
|
+
G(null), q(j), U(!0);
|
|
131
|
+
}, Xe = (e) => {
|
|
132
|
+
G(e), q({
|
|
133
133
|
title: e.title,
|
|
134
134
|
domain: e.domain,
|
|
135
135
|
targetValue: String(e.targetValue),
|
|
@@ -137,23 +137,23 @@ function j() {
|
|
|
137
137
|
cadence: e.cadence,
|
|
138
138
|
status: e.status,
|
|
139
139
|
valueId: e.valueId ?? ""
|
|
140
|
-
}),
|
|
140
|
+
}), U(!0);
|
|
141
141
|
}, Q = () => {
|
|
142
|
-
|
|
143
|
-
},
|
|
144
|
-
if (!
|
|
142
|
+
U(!1), G(null);
|
|
143
|
+
}, Ze = K.title.trim().length > 0 && K.targetValue.trim() !== "" && !Number.isNaN(Number(K.targetValue)), Qe = async () => {
|
|
144
|
+
if (!Ze) return;
|
|
145
145
|
let e = {
|
|
146
|
-
title:
|
|
147
|
-
domain:
|
|
148
|
-
targetValue: Number(
|
|
149
|
-
unit:
|
|
150
|
-
cadence:
|
|
151
|
-
status:
|
|
152
|
-
valueId:
|
|
146
|
+
title: K.title.trim(),
|
|
147
|
+
domain: K.domain,
|
|
148
|
+
targetValue: Number(K.targetValue),
|
|
149
|
+
unit: K.unit.trim() || void 0,
|
|
150
|
+
cadence: K.cadence || void 0,
|
|
151
|
+
status: K.status || void 0,
|
|
152
|
+
valueId: K.valueId || void 0
|
|
153
153
|
};
|
|
154
154
|
try {
|
|
155
|
-
|
|
156
|
-
id:
|
|
155
|
+
W ? (await Pe({ variables: {
|
|
156
|
+
id: W.id,
|
|
157
157
|
input: e
|
|
158
158
|
} }), l({
|
|
159
159
|
title: "Goal updated",
|
|
@@ -164,31 +164,31 @@ function j() {
|
|
|
164
164
|
})), Q(), await h();
|
|
165
165
|
} catch {
|
|
166
166
|
l({
|
|
167
|
-
title:
|
|
167
|
+
title: W ? "Failed to update goal" : "Failed to create goal",
|
|
168
168
|
variant: "error"
|
|
169
169
|
});
|
|
170
170
|
}
|
|
171
|
-
},
|
|
172
|
-
if (
|
|
173
|
-
await
|
|
171
|
+
}, $e = async () => {
|
|
172
|
+
if (J) try {
|
|
173
|
+
await Ie({ variables: { id: J.id } }), l({
|
|
174
174
|
title: "Goal deleted",
|
|
175
175
|
variant: "success"
|
|
176
|
-
}),
|
|
176
|
+
}), Y(null), await h();
|
|
177
177
|
} catch {
|
|
178
178
|
l({
|
|
179
179
|
title: "Failed to delete goal",
|
|
180
180
|
variant: "error"
|
|
181
181
|
});
|
|
182
182
|
}
|
|
183
|
-
},
|
|
184
|
-
onClick:
|
|
185
|
-
className:
|
|
183
|
+
}, et = /* @__PURE__ */ y("button", {
|
|
184
|
+
onClick: We,
|
|
185
|
+
className: w,
|
|
186
186
|
children: [/* @__PURE__ */ v(Ce, { className: "h-4 w-4" }), "Declare value"]
|
|
187
187
|
}), $ = /* @__PURE__ */ y("button", {
|
|
188
|
-
onClick:
|
|
189
|
-
className:
|
|
188
|
+
onClick: Ye,
|
|
189
|
+
className: w,
|
|
190
190
|
children: [/* @__PURE__ */ v(Ce, { className: "h-4 w-4" }), "Add goal"]
|
|
191
|
-
}),
|
|
191
|
+
}), tt = P.length > 0 || F.length > 0;
|
|
192
192
|
return d && m && !u && !p ? /* @__PURE__ */ v(te, {
|
|
193
193
|
title: "Values & Goals",
|
|
194
194
|
description: "Declare what matters and set the life goals that shape it",
|
|
@@ -200,27 +200,27 @@ function j() {
|
|
|
200
200
|
title: "Values & Goals",
|
|
201
201
|
description: "Declare what matters and set the life goals that shape it",
|
|
202
202
|
purpose: "Name the things you value and the goals that serve them. These directly shape your Balance Wheel, your Time-Well-Spent score, and the recommendations TimeCampus surfaces — so your time can follow your intentions, not the other way round.",
|
|
203
|
-
actions:
|
|
203
|
+
actions: et,
|
|
204
204
|
children: [
|
|
205
|
-
|
|
205
|
+
tt && /* @__PURE__ */ y("div", {
|
|
206
206
|
className: "grid grid-cols-1 gap-4 sm:grid-cols-3",
|
|
207
207
|
children: [
|
|
208
208
|
/* @__PURE__ */ v(e, {
|
|
209
209
|
featured: !0,
|
|
210
210
|
title: "Active values",
|
|
211
|
-
value: String(
|
|
211
|
+
value: String(Re),
|
|
212
212
|
icon: /* @__PURE__ */ v(_e, { className: "h-5 w-5" }),
|
|
213
|
-
description: `of ${
|
|
213
|
+
description: `of ${P.length} declared`
|
|
214
214
|
}),
|
|
215
215
|
/* @__PURE__ */ v(e, {
|
|
216
216
|
title: "Life goals",
|
|
217
|
-
value: String(
|
|
217
|
+
value: String(F.length),
|
|
218
218
|
icon: /* @__PURE__ */ v(ve, { className: "h-5 w-5" }),
|
|
219
219
|
description: "targets you're working toward"
|
|
220
220
|
}),
|
|
221
221
|
/* @__PURE__ */ v(e, {
|
|
222
222
|
title: "Domains covered",
|
|
223
|
-
value: String(
|
|
223
|
+
value: String(ze),
|
|
224
224
|
icon: /* @__PURE__ */ v(be, { className: "h-5 w-5" }),
|
|
225
225
|
description: "life areas your values touch"
|
|
226
226
|
})
|
|
@@ -240,18 +240,18 @@ function j() {
|
|
|
240
240
|
}), ye ? /* @__PURE__ */ v("div", {
|
|
241
241
|
className: "rounded-lg border border-status-error-bg/40 bg-status-error-bg p-4 text-sm text-status-error-text",
|
|
242
242
|
children: "Failed to load your values. Please try again later."
|
|
243
|
-
}) : d &&
|
|
243
|
+
}) : d && P.length === 0 ? /* @__PURE__ */ v(t, {
|
|
244
244
|
variant: "list",
|
|
245
245
|
count: 3
|
|
246
|
-
}) :
|
|
246
|
+
}) : P.length === 0 ? /* @__PURE__ */ v(n, {
|
|
247
247
|
illustration: "empty-data",
|
|
248
248
|
title: "Declare what you value",
|
|
249
249
|
description: "Name the life areas that matter to you — family, health, craft — and give each a weight. TimeCampus uses them to score how well your time is spent.",
|
|
250
|
-
action:
|
|
250
|
+
action: et
|
|
251
251
|
}) : /* @__PURE__ */ v("div", {
|
|
252
252
|
className: "grid grid-cols-1 gap-4 sm:grid-cols-2 lg:grid-cols-3 xl:grid-cols-4",
|
|
253
|
-
children:
|
|
254
|
-
let t =
|
|
253
|
+
children: P.map((e) => {
|
|
254
|
+
let t = k(e.domains[0] ?? a.Other);
|
|
255
255
|
return /* @__PURE__ */ y(De, {
|
|
256
256
|
treatment: "glass",
|
|
257
257
|
glow: e.isActive,
|
|
@@ -266,13 +266,13 @@ function j() {
|
|
|
266
266
|
className: "flex items-center gap-1",
|
|
267
267
|
children: [/* @__PURE__ */ v("button", {
|
|
268
268
|
type: "button",
|
|
269
|
-
onClick: () =>
|
|
269
|
+
onClick: () => Ge(e),
|
|
270
270
|
title: "Edit value",
|
|
271
|
-
className:
|
|
271
|
+
className: D,
|
|
272
272
|
children: /* @__PURE__ */ v(Se, { className: "h-4 w-4" })
|
|
273
273
|
}), /* @__PURE__ */ v("button", {
|
|
274
274
|
type: "button",
|
|
275
|
-
onClick: () =>
|
|
275
|
+
onClick: () => H(e),
|
|
276
276
|
title: "Delete value",
|
|
277
277
|
className: "rounded-md p-1.5 text-status-error-text hover:bg-status-error-bg",
|
|
278
278
|
children: /* @__PURE__ */ v(Te, { className: "h-4 w-4" })
|
|
@@ -291,7 +291,7 @@ function j() {
|
|
|
291
291
|
}),
|
|
292
292
|
/* @__PURE__ */ v(oe, {
|
|
293
293
|
value: e.weight,
|
|
294
|
-
max:
|
|
294
|
+
max: Be,
|
|
295
295
|
label: "Importance",
|
|
296
296
|
higherIsWorse: !1,
|
|
297
297
|
size: "sm",
|
|
@@ -329,14 +329,14 @@ function j() {
|
|
|
329
329
|
}), /* @__PURE__ */ v("p", {
|
|
330
330
|
className: "text-sm text-text-secondary",
|
|
331
331
|
children: "Concrete targets that put your values into practice."
|
|
332
|
-
})] }),
|
|
332
|
+
})] }), F.length > 0 && $]
|
|
333
333
|
}), xe ? /* @__PURE__ */ v("div", {
|
|
334
334
|
className: "rounded-lg border border-status-error-bg/40 bg-status-error-bg p-4 text-sm text-status-error-text",
|
|
335
335
|
children: "Failed to load your goals. Please try again later."
|
|
336
|
-
}) : m &&
|
|
336
|
+
}) : m && F.length === 0 ? /* @__PURE__ */ v(t, {
|
|
337
337
|
variant: "list",
|
|
338
338
|
count: 3
|
|
339
|
-
}) :
|
|
339
|
+
}) : F.length === 0 ? /* @__PURE__ */ v(n, {
|
|
340
340
|
illustration: "empty-data",
|
|
341
341
|
title: "Set your first life goal",
|
|
342
342
|
description: "Turn a value into a target — like 'Run a marathon' or '12h of family time a week' — and track it alongside everything else you do.",
|
|
@@ -345,8 +345,8 @@ function j() {
|
|
|
345
345
|
className: "overflow-hidden rounded-xl border border-border-seam bg-gloss-card shadow-pop",
|
|
346
346
|
children: /* @__PURE__ */ v("div", {
|
|
347
347
|
className: "divide-y divide-border",
|
|
348
|
-
children:
|
|
349
|
-
let t =
|
|
348
|
+
children: F.map((e) => {
|
|
349
|
+
let t = k(e.domain), n = e.valueId ? Ve.get(e.valueId) : void 0;
|
|
350
350
|
return /* @__PURE__ */ y("div", {
|
|
351
351
|
className: "flex flex-col gap-3 p-4 transition-colors hover:bg-bg-sunken/50 sm:flex-row sm:items-center sm:justify-between",
|
|
352
352
|
children: [/* @__PURE__ */ y("div", {
|
|
@@ -376,24 +376,24 @@ function j() {
|
|
|
376
376
|
e.unit,
|
|
377
377
|
" ·",
|
|
378
378
|
" ",
|
|
379
|
-
|
|
379
|
+
O(e.cadence)
|
|
380
380
|
]
|
|
381
381
|
}),
|
|
382
382
|
/* @__PURE__ */ v(ne, {
|
|
383
383
|
status: e.status,
|
|
384
|
-
label:
|
|
384
|
+
label: O(e.status)
|
|
385
385
|
}),
|
|
386
386
|
/* @__PURE__ */ y("div", {
|
|
387
387
|
className: "flex items-center gap-1",
|
|
388
388
|
children: [/* @__PURE__ */ v("button", {
|
|
389
389
|
type: "button",
|
|
390
|
-
onClick: () =>
|
|
390
|
+
onClick: () => Xe(e),
|
|
391
391
|
title: "Edit goal",
|
|
392
|
-
className:
|
|
392
|
+
className: D,
|
|
393
393
|
children: /* @__PURE__ */ v(Se, { className: "h-4 w-4" })
|
|
394
394
|
}), /* @__PURE__ */ v("button", {
|
|
395
395
|
type: "button",
|
|
396
|
-
onClick: () =>
|
|
396
|
+
onClick: () => Y(e),
|
|
397
397
|
title: "Delete goal",
|
|
398
398
|
className: "rounded-md p-1.5 text-status-error-text hover:bg-status-error-bg",
|
|
399
399
|
children: /* @__PURE__ */ v(Te, { className: "h-4 w-4" })
|
|
@@ -406,67 +406,67 @@ function j() {
|
|
|
406
406
|
})
|
|
407
407
|
})]
|
|
408
408
|
}),
|
|
409
|
-
|
|
409
|
+
P.length > 0 && F.length > 0 && /* @__PURE__ */ v(re, {
|
|
410
410
|
title: "How your goals map to your values",
|
|
411
411
|
description: "Every goal counts toward the value it supports — the fuel behind your Balance Wheel.",
|
|
412
412
|
className: "mt-6",
|
|
413
413
|
children: /* @__PURE__ */ y("p", {
|
|
414
414
|
className: "text-sm text-text-secondary",
|
|
415
415
|
children: [
|
|
416
|
-
|
|
416
|
+
F.filter((e) => e.valueId).length,
|
|
417
417
|
" of ",
|
|
418
|
-
|
|
418
|
+
F.length,
|
|
419
419
|
" goals are linked to a declared value. Linking a goal to a value tells TimeCampus which priority the time you invest is really serving."
|
|
420
420
|
]
|
|
421
421
|
})
|
|
422
422
|
}),
|
|
423
423
|
/* @__PURE__ */ v(r, {
|
|
424
|
-
open:
|
|
425
|
-
onClose:
|
|
426
|
-
title:
|
|
427
|
-
description:
|
|
424
|
+
open: He,
|
|
425
|
+
onClose: X,
|
|
426
|
+
title: L ? "Edit value" : "Declare a value",
|
|
427
|
+
description: L ? "Update what this value stands for and how much it weighs." : "Name a life area that matters and how the domains map to it.",
|
|
428
428
|
footer: /* @__PURE__ */ y(_, { children: [/* @__PURE__ */ v("button", {
|
|
429
|
-
onClick:
|
|
430
|
-
className:
|
|
429
|
+
onClick: X,
|
|
430
|
+
className: T,
|
|
431
431
|
children: "Cancel"
|
|
432
432
|
}), /* @__PURE__ */ v("button", {
|
|
433
|
-
onClick:
|
|
434
|
-
disabled: !
|
|
435
|
-
className:
|
|
436
|
-
children: g ||
|
|
433
|
+
onClick: qe,
|
|
434
|
+
disabled: !Z || g || M,
|
|
435
|
+
className: w,
|
|
436
|
+
children: g || M ? "Saving..." : L ? "Save changes" : "Declare value"
|
|
437
437
|
})] }),
|
|
438
438
|
children: /* @__PURE__ */ y("div", {
|
|
439
439
|
className: "space-y-4",
|
|
440
440
|
children: [
|
|
441
441
|
/* @__PURE__ */ y("div", { children: [/* @__PURE__ */ v("label", {
|
|
442
|
-
className:
|
|
442
|
+
className: C,
|
|
443
443
|
children: "Name"
|
|
444
444
|
}), /* @__PURE__ */ v("input", {
|
|
445
445
|
type: "text",
|
|
446
446
|
placeholder: "e.g. Family, Health, Craft",
|
|
447
|
-
value:
|
|
448
|
-
onChange: (e) =>
|
|
449
|
-
...
|
|
447
|
+
value: z.name,
|
|
448
|
+
onChange: (e) => B({
|
|
449
|
+
...z,
|
|
450
450
|
name: e.target.value
|
|
451
451
|
}),
|
|
452
|
-
className:
|
|
452
|
+
className: S
|
|
453
453
|
})] }),
|
|
454
454
|
/* @__PURE__ */ y("div", { children: [/* @__PURE__ */ v("label", {
|
|
455
|
-
className:
|
|
455
|
+
className: C,
|
|
456
456
|
children: "Description"
|
|
457
457
|
}), /* @__PURE__ */ v("textarea", {
|
|
458
458
|
rows: 2,
|
|
459
459
|
placeholder: "What does this value mean to you?",
|
|
460
|
-
value:
|
|
461
|
-
onChange: (e) =>
|
|
462
|
-
...
|
|
460
|
+
value: z.description,
|
|
461
|
+
onChange: (e) => B({
|
|
462
|
+
...z,
|
|
463
463
|
description: e.target.value
|
|
464
464
|
}),
|
|
465
|
-
className:
|
|
465
|
+
className: S
|
|
466
466
|
})] }),
|
|
467
467
|
/* @__PURE__ */ y("div", { children: [
|
|
468
468
|
/* @__PURE__ */ v("label", {
|
|
469
|
-
className:
|
|
469
|
+
className: C,
|
|
470
470
|
children: "Weight (relative importance)"
|
|
471
471
|
}),
|
|
472
472
|
/* @__PURE__ */ v("input", {
|
|
@@ -474,12 +474,12 @@ function j() {
|
|
|
474
474
|
min: 0,
|
|
475
475
|
step: "0.1",
|
|
476
476
|
placeholder: "1",
|
|
477
|
-
value:
|
|
478
|
-
onChange: (e) =>
|
|
479
|
-
...
|
|
477
|
+
value: z.weight,
|
|
478
|
+
onChange: (e) => B({
|
|
479
|
+
...z,
|
|
480
480
|
weight: e.target.value
|
|
481
481
|
}),
|
|
482
|
-
className:
|
|
482
|
+
className: S
|
|
483
483
|
}),
|
|
484
484
|
/* @__PURE__ */ v("p", {
|
|
485
485
|
className: "mt-1 text-xs text-text-secondary",
|
|
@@ -488,7 +488,7 @@ function j() {
|
|
|
488
488
|
] }),
|
|
489
489
|
/* @__PURE__ */ y("div", { children: [
|
|
490
490
|
/* @__PURE__ */ v("label", {
|
|
491
|
-
className:
|
|
491
|
+
className: C,
|
|
492
492
|
children: "Domains"
|
|
493
493
|
}),
|
|
494
494
|
/* @__PURE__ */ v("p", {
|
|
@@ -498,10 +498,10 @@ function j() {
|
|
|
498
498
|
/* @__PURE__ */ v("div", {
|
|
499
499
|
className: "mt-2 flex flex-wrap gap-2",
|
|
500
500
|
children: se.map((e) => {
|
|
501
|
-
let t =
|
|
501
|
+
let t = z.domains.includes(e);
|
|
502
502
|
return /* @__PURE__ */ v("button", {
|
|
503
503
|
type: "button",
|
|
504
|
-
onClick: () =>
|
|
504
|
+
onClick: () => Ke(e),
|
|
505
505
|
className: t ? "rounded-full bg-action-primary-bg px-3 py-1 text-xs font-medium text-action-primary-text" : "rounded-full border border-border-subtle px-3 py-1 text-xs font-medium text-text-secondary hover:bg-bg-sunken/50",
|
|
506
506
|
children: i(e)
|
|
507
507
|
}, e);
|
|
@@ -512,9 +512,9 @@ function j() {
|
|
|
512
512
|
className: "flex items-center gap-2 text-sm text-text-primary",
|
|
513
513
|
children: [/* @__PURE__ */ v("input", {
|
|
514
514
|
type: "checkbox",
|
|
515
|
-
checked:
|
|
516
|
-
onChange: (e) =>
|
|
517
|
-
...
|
|
515
|
+
checked: z.isActive,
|
|
516
|
+
onChange: (e) => B({
|
|
517
|
+
...z,
|
|
518
518
|
isActive: e.target.checked
|
|
519
519
|
}),
|
|
520
520
|
className: "h-4 w-4 rounded border-border-subtle"
|
|
@@ -524,20 +524,20 @@ function j() {
|
|
|
524
524
|
})
|
|
525
525
|
}),
|
|
526
526
|
/* @__PURE__ */ v(r, {
|
|
527
|
-
open:
|
|
528
|
-
onClose: () =>
|
|
527
|
+
open: V !== null,
|
|
528
|
+
onClose: () => H(null),
|
|
529
529
|
title: "Delete value?",
|
|
530
|
-
description:
|
|
530
|
+
description: V ? `"${V.name}" will be removed from your Balance Wheel.` : void 0,
|
|
531
531
|
size: "sm",
|
|
532
532
|
footer: /* @__PURE__ */ y(_, { children: [/* @__PURE__ */ v("button", {
|
|
533
|
-
onClick: () =>
|
|
534
|
-
className:
|
|
533
|
+
onClick: () => H(null),
|
|
534
|
+
className: T,
|
|
535
535
|
children: "Cancel"
|
|
536
536
|
}), /* @__PURE__ */ v("button", {
|
|
537
|
-
onClick:
|
|
538
|
-
disabled:
|
|
539
|
-
className:
|
|
540
|
-
children:
|
|
537
|
+
onClick: Je,
|
|
538
|
+
disabled: N,
|
|
539
|
+
className: E,
|
|
540
|
+
children: N ? "Deleting..." : "Delete"
|
|
541
541
|
})] }),
|
|
542
542
|
children: /* @__PURE__ */ v("p", {
|
|
543
543
|
className: "text-sm text-text-secondary",
|
|
@@ -545,66 +545,66 @@ function j() {
|
|
|
545
545
|
})
|
|
546
546
|
}),
|
|
547
547
|
/* @__PURE__ */ v(r, {
|
|
548
|
-
open:
|
|
548
|
+
open: Ue,
|
|
549
549
|
onClose: Q,
|
|
550
|
-
title:
|
|
551
|
-
description:
|
|
550
|
+
title: W ? "Edit goal" : "Add a goal",
|
|
551
|
+
description: W ? "Update this goal's target and status." : "Set a concrete target that puts one of your values into practice.",
|
|
552
552
|
footer: /* @__PURE__ */ y(_, { children: [/* @__PURE__ */ v("button", {
|
|
553
553
|
onClick: Q,
|
|
554
|
-
className:
|
|
554
|
+
className: T,
|
|
555
555
|
children: "Cancel"
|
|
556
556
|
}), /* @__PURE__ */ v("button", {
|
|
557
|
-
onClick:
|
|
558
|
-
disabled: !
|
|
559
|
-
className:
|
|
560
|
-
children:
|
|
557
|
+
onClick: Qe,
|
|
558
|
+
disabled: !Ze || Ne || Fe,
|
|
559
|
+
className: w,
|
|
560
|
+
children: Ne || Fe ? "Saving..." : W ? "Save changes" : "Add goal"
|
|
561
561
|
})] }),
|
|
562
562
|
children: /* @__PURE__ */ y("div", {
|
|
563
563
|
className: "space-y-4",
|
|
564
564
|
children: [
|
|
565
565
|
/* @__PURE__ */ y("div", { children: [/* @__PURE__ */ v("label", {
|
|
566
|
-
className:
|
|
566
|
+
className: C,
|
|
567
567
|
children: "Title"
|
|
568
568
|
}), /* @__PURE__ */ v("input", {
|
|
569
569
|
type: "text",
|
|
570
570
|
placeholder: "e.g. Run a marathon, 12h family time",
|
|
571
|
-
value:
|
|
572
|
-
onChange: (e) =>
|
|
573
|
-
...
|
|
571
|
+
value: K.title,
|
|
572
|
+
onChange: (e) => q({
|
|
573
|
+
...K,
|
|
574
574
|
title: e.target.value
|
|
575
575
|
}),
|
|
576
|
-
className:
|
|
576
|
+
className: S
|
|
577
577
|
})] }),
|
|
578
578
|
/* @__PURE__ */ y("div", {
|
|
579
579
|
className: "grid grid-cols-1 gap-4 sm:grid-cols-2",
|
|
580
580
|
children: [/* @__PURE__ */ y("div", { children: [/* @__PURE__ */ v("label", {
|
|
581
|
-
className:
|
|
581
|
+
className: C,
|
|
582
582
|
children: "Domain"
|
|
583
|
-
}), /* @__PURE__ */ v(
|
|
584
|
-
value:
|
|
585
|
-
onChange: (e) =>
|
|
586
|
-
...
|
|
583
|
+
}), /* @__PURE__ */ v(b, {
|
|
584
|
+
value: K.domain,
|
|
585
|
+
onChange: (e) => q({
|
|
586
|
+
...K,
|
|
587
587
|
domain: e.target.value
|
|
588
588
|
}),
|
|
589
|
-
className:
|
|
589
|
+
className: S,
|
|
590
590
|
children: se.map((e) => /* @__PURE__ */ v("option", {
|
|
591
591
|
value: e,
|
|
592
592
|
children: i(e)
|
|
593
593
|
}, e))
|
|
594
594
|
})] }), /* @__PURE__ */ y("div", { children: [/* @__PURE__ */ v("label", {
|
|
595
|
-
className:
|
|
595
|
+
className: C,
|
|
596
596
|
children: "Supports value"
|
|
597
|
-
}), /* @__PURE__ */ y(
|
|
598
|
-
value:
|
|
599
|
-
onChange: (e) =>
|
|
600
|
-
...
|
|
597
|
+
}), /* @__PURE__ */ y(b, {
|
|
598
|
+
value: K.valueId,
|
|
599
|
+
onChange: (e) => q({
|
|
600
|
+
...K,
|
|
601
601
|
valueId: e.target.value
|
|
602
602
|
}),
|
|
603
|
-
className:
|
|
603
|
+
className: S,
|
|
604
604
|
children: [/* @__PURE__ */ v("option", {
|
|
605
605
|
value: "",
|
|
606
606
|
children: "None"
|
|
607
|
-
}),
|
|
607
|
+
}), P.map((e) => /* @__PURE__ */ v("option", {
|
|
608
608
|
value: e.id,
|
|
609
609
|
children: e.name
|
|
610
610
|
}, e.id))]
|
|
@@ -614,35 +614,35 @@ function j() {
|
|
|
614
614
|
className: "grid grid-cols-1 gap-4 sm:grid-cols-3",
|
|
615
615
|
children: [
|
|
616
616
|
/* @__PURE__ */ y("div", { children: [/* @__PURE__ */ v("label", {
|
|
617
|
-
className:
|
|
617
|
+
className: C,
|
|
618
618
|
children: "Target"
|
|
619
619
|
}), /* @__PURE__ */ v("input", {
|
|
620
620
|
type: "number",
|
|
621
621
|
min: 0,
|
|
622
622
|
step: "0.5",
|
|
623
623
|
placeholder: "12",
|
|
624
|
-
value:
|
|
625
|
-
onChange: (e) =>
|
|
626
|
-
...
|
|
624
|
+
value: K.targetValue,
|
|
625
|
+
onChange: (e) => q({
|
|
626
|
+
...K,
|
|
627
627
|
targetValue: e.target.value
|
|
628
628
|
}),
|
|
629
|
-
className:
|
|
629
|
+
className: S
|
|
630
630
|
})] }),
|
|
631
631
|
/* @__PURE__ */ y("div", { children: [
|
|
632
632
|
/* @__PURE__ */ v("label", {
|
|
633
|
-
className:
|
|
633
|
+
className: C,
|
|
634
634
|
children: "Unit"
|
|
635
635
|
}),
|
|
636
636
|
/* @__PURE__ */ v("input", {
|
|
637
637
|
type: "text",
|
|
638
638
|
list: "timecampus-goal-units",
|
|
639
639
|
placeholder: "hours",
|
|
640
|
-
value:
|
|
641
|
-
onChange: (e) =>
|
|
642
|
-
...
|
|
640
|
+
value: K.unit,
|
|
641
|
+
onChange: (e) => q({
|
|
642
|
+
...K,
|
|
643
643
|
unit: e.target.value
|
|
644
644
|
}),
|
|
645
|
-
className:
|
|
645
|
+
className: S
|
|
646
646
|
}),
|
|
647
647
|
/* @__PURE__ */ v("datalist", {
|
|
648
648
|
id: "timecampus-goal-units",
|
|
@@ -650,55 +650,55 @@ function j() {
|
|
|
650
650
|
})
|
|
651
651
|
] }),
|
|
652
652
|
/* @__PURE__ */ y("div", { children: [/* @__PURE__ */ v("label", {
|
|
653
|
-
className:
|
|
653
|
+
className: C,
|
|
654
654
|
children: "Cadence"
|
|
655
|
-
}), /* @__PURE__ */ v(
|
|
656
|
-
value:
|
|
657
|
-
onChange: (e) =>
|
|
658
|
-
...
|
|
655
|
+
}), /* @__PURE__ */ v(b, {
|
|
656
|
+
value: K.cadence,
|
|
657
|
+
onChange: (e) => q({
|
|
658
|
+
...K,
|
|
659
659
|
cadence: e.target.value
|
|
660
660
|
}),
|
|
661
|
-
className:
|
|
661
|
+
className: S,
|
|
662
662
|
children: Oe.map((e) => /* @__PURE__ */ v("option", {
|
|
663
663
|
value: e,
|
|
664
|
-
children:
|
|
664
|
+
children: O(e)
|
|
665
665
|
}, e))
|
|
666
666
|
})] })
|
|
667
667
|
]
|
|
668
668
|
}),
|
|
669
669
|
/* @__PURE__ */ y("div", { children: [/* @__PURE__ */ v("label", {
|
|
670
|
-
className:
|
|
670
|
+
className: C,
|
|
671
671
|
children: "Status"
|
|
672
|
-
}), /* @__PURE__ */ v(
|
|
673
|
-
value:
|
|
674
|
-
onChange: (e) =>
|
|
675
|
-
...
|
|
672
|
+
}), /* @__PURE__ */ v(b, {
|
|
673
|
+
value: K.status,
|
|
674
|
+
onChange: (e) => q({
|
|
675
|
+
...K,
|
|
676
676
|
status: e.target.value
|
|
677
677
|
}),
|
|
678
|
-
className:
|
|
678
|
+
className: S,
|
|
679
679
|
children: ke.map((e) => /* @__PURE__ */ v("option", {
|
|
680
680
|
value: e,
|
|
681
|
-
children:
|
|
681
|
+
children: O(e)
|
|
682
682
|
}, e))
|
|
683
683
|
})] })
|
|
684
684
|
]
|
|
685
685
|
})
|
|
686
686
|
}),
|
|
687
687
|
/* @__PURE__ */ v(r, {
|
|
688
|
-
open:
|
|
689
|
-
onClose: () =>
|
|
688
|
+
open: J !== null,
|
|
689
|
+
onClose: () => Y(null),
|
|
690
690
|
title: "Delete goal?",
|
|
691
|
-
description:
|
|
691
|
+
description: J ? `"${J.title}" will be removed.` : void 0,
|
|
692
692
|
size: "sm",
|
|
693
693
|
footer: /* @__PURE__ */ y(_, { children: [/* @__PURE__ */ v("button", {
|
|
694
|
-
onClick: () =>
|
|
695
|
-
className:
|
|
694
|
+
onClick: () => Y(null),
|
|
695
|
+
className: T,
|
|
696
696
|
children: "Cancel"
|
|
697
697
|
}), /* @__PURE__ */ v("button", {
|
|
698
|
-
onClick:
|
|
699
|
-
disabled:
|
|
700
|
-
className:
|
|
701
|
-
children:
|
|
698
|
+
onClick: $e,
|
|
699
|
+
disabled: Le,
|
|
700
|
+
className: E,
|
|
701
|
+
children: Le ? "Deleting..." : "Delete"
|
|
702
702
|
})] }),
|
|
703
703
|
children: /* @__PURE__ */ v("p", {
|
|
704
704
|
className: "text-sm text-text-secondary",
|
|
@@ -712,6 +712,6 @@ function j() {
|
|
|
712
712
|
]
|
|
713
713
|
});
|
|
714
714
|
}
|
|
715
|
-
export {
|
|
715
|
+
export { M as ValuesGoalsPage };
|
|
716
716
|
|
|
717
717
|
//# sourceMappingURL=ValuesGoalsPage.js.map
|