@burdenoff/microfe-calendar 2026.527.1 → 2026.625.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.
Files changed (35) hide show
  1. package/dist/components/AgendaView.js +71 -55
  2. package/dist/components/AgendaView.js.map +1 -1
  3. package/dist/components/CalendarErrorState.js +40 -0
  4. package/dist/components/CalendarErrorState.js.map +1 -0
  5. package/dist/components/DayView.js +43 -32
  6. package/dist/components/DayView.js.map +1 -1
  7. package/dist/components/EventBlock.js +14 -26
  8. package/dist/components/EventBlock.js.map +1 -1
  9. package/dist/components/EventFormModal.js +458 -468
  10. package/dist/components/EventFormModal.js.map +1 -1
  11. package/dist/components/MonthView.js +37 -26
  12. package/dist/components/MonthView.js.map +1 -1
  13. package/dist/components/TimelineView.js +50 -39
  14. package/dist/components/TimelineView.js.map +1 -1
  15. package/dist/components/WeekView.js +53 -39
  16. package/dist/components/WeekView.js.map +1 -1
  17. package/dist/components/YearView.js +73 -51
  18. package/dist/components/YearView.js.map +1 -1
  19. package/dist/hooks/useEvents.js +22 -16
  20. package/dist/hooks/useEvents.js.map +1 -1
  21. package/dist/hooks/useOpenEvent.js +24 -0
  22. package/dist/hooks/useOpenEvent.js.map +1 -0
  23. package/dist/pages/CalendarPage.js +97 -86
  24. package/dist/pages/CalendarPage.js.map +1 -1
  25. package/dist/pages/EventDetailsPage.js +167 -172
  26. package/dist/pages/EventDetailsPage.js.map +1 -1
  27. package/dist/pages/ResourcesPage.js +120 -123
  28. package/dist/pages/ResourcesPage.js.map +1 -1
  29. package/dist/pages/SettingsPage.js +177 -172
  30. package/dist/pages/SettingsPage.js.map +1 -1
  31. package/dist/pages/SubscriptionsPage.js +49 -49
  32. package/dist/pages/SubscriptionsPage.js.map +1 -1
  33. package/dist/store/calendarStore.js +11 -4
  34. package/dist/store/calendarStore.js.map +1 -1
  35. package/package.json +4 -2
@@ -1,35 +1,40 @@
1
1
  import { useGetCalendarsQuery as e } from "../generated/wspace-operations.js";
2
2
  import { useCalendarStore as t } from "../store/calendarStore.js";
3
3
  import { useSafePermissions as n } from "../hooks/useSafePermissions.js";
4
- import { AVAILABILITY_RULES_QUERY as r, BLACKOUT_DATES_QUERY as i, CALENDAR_DETAILS_QUERY as ee, CONNECT_EXTERNAL_CALENDAR_MUTATION as te, CREATE_AVAILABILITY_RULE_MUTATION as ne, CREATE_BLACKOUT_DATE_MUTATION as re, CREATE_BOOKING_PAGE_MUTATION as ie, DELETE_AVAILABILITY_RULE_MUTATION as ae, DELETE_BLACKOUT_DATE_MUTATION as oe, DELETE_BOOKING_PAGE_MUTATION as se, DISCONNECT_EXTERNAL_CALENDAR_MUTATION as ce, EXTERNAL_SYNCS_QUERY as le, PAUSE_SYNC_MUTATION as ue, RESUME_SYNC_MUTATION as a, REVOKE_CALENDAR_SHARE_MUTATION as o, SHARE_CALENDAR_MUTATION as s, TRIGGER_SYNC_MUTATION as c } from "../graphql/calendarDocuments.js";
5
- import { CALENDAR_PERMISSIONS as l } from "../constants/permissions.js";
6
- import { useMemo as u, useState as d } from "react";
7
- import { AccessDenied as de } from "@burdenoff/fe-libs/shared/components";
8
- import { useI18n as fe } from "@burdenoff/fe-libs/shared/providers/shell/I18nProvider";
9
- import { CalendarClock as pe, CalendarDays as me, Clock as he, Link2 as ge, Settings as _e, Shield as ve, Users as ye } from "lucide-react";
10
- import { jsx as f, jsxs as p } from "react/jsx-runtime";
4
+ import { AVAILABILITY_RULES_QUERY as r, BLACKOUT_DATES_QUERY as ee, CALENDAR_DETAILS_QUERY as te, CONNECT_EXTERNAL_CALENDAR_MUTATION as ne, CREATE_AVAILABILITY_RULE_MUTATION as re, CREATE_BLACKOUT_DATE_MUTATION as ie, CREATE_BOOKING_PAGE_MUTATION as ae, DELETE_AVAILABILITY_RULE_MUTATION as oe, DELETE_BLACKOUT_DATE_MUTATION as se, DELETE_BOOKING_PAGE_MUTATION as ce, DISCONNECT_EXTERNAL_CALENDAR_MUTATION as le, EXTERNAL_SYNCS_QUERY as ue, PAUSE_SYNC_MUTATION as de, RESUME_SYNC_MUTATION as i, REVOKE_CALENDAR_SHARE_MUTATION as a, SHARE_CALENDAR_MUTATION as o, TRIGGER_SYNC_MUTATION as s } from "../graphql/calendarDocuments.js";
5
+ import { CALENDAR_PERMISSIONS as c } from "../constants/permissions.js";
6
+ import { useMemo as l, useState as u } from "react";
7
+ import { AccessDenied as fe } from "@burdenoff/fe-libs/shared/components";
8
+ import { useI18n as pe } from "@burdenoff/fe-libs/shared/providers/shell/I18nProvider";
9
+ import { CalendarClock as me, CalendarDays as he, Clock as ge, Link2 as _e, Settings as ve, Shield as ye, Users as be } from "lucide-react";
10
+ import { jsx as d, jsxs as f } from "react/jsx-runtime";
11
+ import { GlassCard as p, GradientText as xe } from "@burdenoff/fe-libs/ui";
11
12
  import { useMutation as m, useQuery as h } from "@apollo/client/react";
12
13
  //#region src/pages/SettingsPage.tsx
13
14
  function g({ title: e, description: t, icon: n, children: r }) {
14
- return /* @__PURE__ */ p("section", {
15
- className: "bg-bg-surface border border-border-default rounded-radius-lg p-card-padding space-y-4",
16
- children: [/* @__PURE__ */ p("div", {
17
- className: "flex items-start gap-3",
18
- children: [/* @__PURE__ */ f(n, { className: "size-5 text-text-secondary shrink-0" }), /* @__PURE__ */ p("div", { children: [/* @__PURE__ */ f("h2", {
19
- className: "font-heading-sm text-text-primary",
20
- children: e
21
- }), t ? /* @__PURE__ */ f("p", {
22
- className: "font-text-sm text-text-secondary mt-1",
23
- children: t
24
- }) : null] })]
25
- }), r]
15
+ return /* @__PURE__ */ d(p, {
16
+ treatment: "metric",
17
+ className: "p-card-padding",
18
+ children: /* @__PURE__ */ f("div", {
19
+ className: "space-y-4",
20
+ children: [/* @__PURE__ */ f("div", {
21
+ className: "flex items-start gap-3",
22
+ children: [/* @__PURE__ */ d(n, { className: "size-5 text-text-secondary shrink-0" }), /* @__PURE__ */ f("div", { children: [/* @__PURE__ */ d("h2", {
23
+ className: "font-heading-sm text-text-primary",
24
+ children: e
25
+ }), t ? /* @__PURE__ */ d("p", {
26
+ className: "font-text-sm text-text-secondary mt-1",
27
+ children: t
28
+ }) : null] })]
29
+ }), r]
30
+ })
26
31
  });
27
32
  }
28
33
  function _(e) {
29
34
  return e ? new Date(e).toLocaleString() : "—";
30
35
  }
31
36
  function v() {
32
- let { hasPermission: v, isLoading: y } = n(), b = t((e) => e.currentView), x = t((e) => e.selectedTimeZone), be = t((e) => e.setTimeZone), xe = t((e) => e.miniCalendarVisible), Se = t((e) => e.setMiniCalendarVisible), { t: S } = fe(), C = (e, t) => {
37
+ let { hasPermission: p, isLoading: v } = n(), y = t((e) => e.currentView), b = t((e) => e.selectedTimeZone), Se = t((e) => e.setTimeZone), Ce = t((e) => e.miniCalendarVisible), x = t((e) => e.setMiniCalendarVisible), { t: S } = pe(), C = (e, t) => {
33
38
  let n = S(e);
34
39
  return n === e ? t : n;
35
40
  }, w = {
@@ -39,7 +44,7 @@ function v() {
39
44
  year: C("calendar.year", "Year"),
40
45
  agenda: C("calendar.agenda", "Agenda"),
41
46
  timeline: C("calendar.timeline", "Timeline")
42
- }, [T, E] = d(""), [D, O] = d(""), [k, A] = d("user"), [j, M] = d("VIEW"), [N, P] = d({
47
+ }, [T, E] = u(""), [D, O] = u(""), [k, A] = u("user"), [j, M] = u("VIEW"), [N, P] = u({
43
48
  dayOfWeek: "MONDAY",
44
49
  startTime: "09:00",
45
50
  endTime: "17:00",
@@ -48,11 +53,11 @@ function v() {
48
53
  slotIncrement: "30",
49
54
  minNotice: "60",
50
55
  maxNotice: "43200"
51
- }), [F, I] = d({
56
+ }), [F, I] = u({
52
57
  startDate: "",
53
58
  endDate: "",
54
59
  reason: ""
55
- }), [L, R] = d({
60
+ }), [L, R] = u({
56
61
  name: "",
57
62
  slug: "",
58
63
  pageType: "ONE_ON_ONE",
@@ -60,7 +65,7 @@ function v() {
60
65
  locationType: "ONLINE",
61
66
  maxAttendees: "1",
62
67
  requireApproval: !1
63
- }), [z, B] = d({
68
+ }), [z, B] = u({
64
69
  provider: "GOOGLE_CALENDAR",
65
70
  externalCalendarId: "",
66
71
  externalCalendarName: "",
@@ -68,123 +73,123 @@ function v() {
68
73
  refreshToken: "",
69
74
  syncFrequency: "300",
70
75
  direction: "TWO_WAY"
71
- }), { data: V, loading: Ce, refetch: we } = e({
76
+ }), { data: V, loading: we, refetch: Te } = e({
72
77
  variables: { pagination: { limit: 50 } },
73
- skip: y
74
- }), H = u(() => V?.calendars?.calendars ?? [], [V?.calendars?.calendars]), U = u(() => T || ((H.find((e) => e.isDefault) ?? H[0])?.id ?? ""), [H, T]), W = u(() => /* @__PURE__ */ new Date(), []), Te = u(() => new Date(W.getFullYear() - 1, W.getMonth(), W.getDate()).toISOString(), [W]), Ee = u(() => new Date(W.getFullYear() + 1, W.getMonth(), W.getDate()).toISOString(), [W]), { data: De, refetch: Oe } = h(ee, {
78
+ skip: v
79
+ }), H = l(() => V?.calendars?.calendars ?? [], [V?.calendars?.calendars]), U = l(() => T || ((H.find((e) => e.isDefault) ?? H[0])?.id ?? ""), [H, T]), W = l(() => /* @__PURE__ */ new Date(), []), Ee = l(() => new Date(W.getFullYear() - 1, W.getMonth(), W.getDate()).toISOString(), [W]), De = l(() => new Date(W.getFullYear() + 1, W.getMonth(), W.getDate()).toISOString(), [W]), { data: Oe, refetch: ke } = h(te, {
75
80
  variables: { id: U },
76
81
  skip: !U,
77
82
  fetchPolicy: "cache-and-network"
78
- }), { data: ke, refetch: Ae } = h(r, {
83
+ }), { data: Ae, refetch: je } = h(r, {
79
84
  variables: { calendarId: U },
80
85
  skip: !U,
81
86
  fetchPolicy: "cache-and-network"
82
- }), { data: je, refetch: Me } = h(i, {
87
+ }), { data: Me, refetch: Ne } = h(ee, {
83
88
  variables: {
84
89
  calendarId: U,
85
- startDate: Te,
86
- endDate: Ee
90
+ startDate: Ee,
91
+ endDate: De
87
92
  },
88
93
  skip: !U,
89
94
  fetchPolicy: "cache-and-network"
90
- }), { data: Ne, refetch: Pe } = h(le, {
95
+ }), { data: Pe, refetch: Fe } = h(ue, {
91
96
  variables: { calendarId: U },
92
97
  skip: !U,
93
98
  fetchPolicy: "cache-and-network"
94
- }), [Fe, { loading: G }] = m(s), [Ie] = m(o), [Le, { loading: K }] = m(ne), [Re] = m(ae), [ze, { loading: q }] = m(re), [Be] = m(oe), [Ve, { loading: J }] = m(ie), [He] = m(se), [Ue, { loading: Y }] = m(te), [We] = m(ue), [X] = m(a), [Ge] = m(c), [Ke] = m(ce), Z = De?.calendar, Q = Z?.shares ?? [], qe = Z?.bookingPages ?? [], Je = ke?.getAvailabilityRules ?? [], Ye = je?.getBlackoutDates ?? [], Xe = Ne?.getExternalCalendarSyncs ?? [], $ = async () => {
99
+ }), [Ie, { loading: G }] = m(o), [Le] = m(a), [Re, { loading: K }] = m(re), [ze] = m(oe), [Be, { loading: q }] = m(ie), [Ve] = m(se), [He, { loading: J }] = m(ae), [Ue] = m(ce), [We, { loading: Y }] = m(ne), [Ge] = m(de), [Ke] = m(i), [qe] = m(s), [X] = m(le), Z = Oe?.calendar, Q = Z?.shares ?? [], Je = Z?.bookingPages ?? [], Ye = Ae?.getAvailabilityRules ?? [], Xe = Me?.getBlackoutDates ?? [], Ze = Pe?.getExternalCalendarSyncs ?? [], $ = async () => {
95
100
  await Promise.all([
96
- we(),
97
- Oe(),
98
- Ae(),
99
- Me(),
100
- Pe()
101
+ Te(),
102
+ ke(),
103
+ je(),
104
+ Ne(),
105
+ Fe()
101
106
  ]);
102
107
  };
103
- return y || Ce ? /* @__PURE__ */ f("div", {
108
+ return v || we ? /* @__PURE__ */ d("div", {
104
109
  className: "@container min-h-screen bg-bg-canvas flex items-center justify-center",
105
- children: /* @__PURE__ */ f("p", {
110
+ children: /* @__PURE__ */ d("p", {
106
111
  className: "font-text-md text-text-secondary",
107
112
  children: C("calendar.loading", "Loading...")
108
113
  })
109
- }) : v(l.CALENDAR_READ) ? /* @__PURE__ */ p("div", {
114
+ }) : p(c.CALENDAR_READ) ? /* @__PURE__ */ f("div", {
110
115
  className: "@container min-h-screen bg-bg-canvas",
111
- children: [/* @__PURE__ */ f("header", {
112
- className: "border-b border-border-default bg-bg-surface px-page-padding py-element-padding",
113
- children: /* @__PURE__ */ p("div", {
116
+ children: [/* @__PURE__ */ d("header", {
117
+ className: "border-b border-border-seam bg-bg-surface px-page-padding py-element-padding",
118
+ children: /* @__PURE__ */ f("div", {
114
119
  className: "flex items-center gap-inline-gap",
115
- children: [/* @__PURE__ */ f(_e, { className: "size-5 text-text-secondary" }), /* @__PURE__ */ f("h1", {
120
+ children: [/* @__PURE__ */ d(ve, { className: "size-5 text-text-secondary" }), /* @__PURE__ */ d("h1", {
116
121
  className: "font-heading-lg text-text-primary",
117
- children: C("calendar.calendarSettings", "Calendar Settings")
122
+ children: /* @__PURE__ */ d(xe, { children: C("calendar.calendarSettings", "Calendar Settings") })
118
123
  })]
119
124
  })
120
- }), /* @__PURE__ */ p("div", {
125
+ }), /* @__PURE__ */ f("div", {
121
126
  className: "max-w-5xl mx-auto p-page-padding space-y-6",
122
127
  children: [
123
- /* @__PURE__ */ f(g, {
128
+ /* @__PURE__ */ d(g, {
124
129
  title: C("calendar.activeCalendar", "Active calendar"),
125
130
  description: C("calendar.activeCalendarDescription", "Choose which calendar to manage for availability, shares, booking pages, and syncs."),
126
- icon: me,
127
- children: /* @__PURE__ */ f("select", {
131
+ icon: he,
132
+ children: /* @__PURE__ */ d("select", {
128
133
  value: U,
129
134
  onChange: (e) => E(e.target.value),
130
135
  className: "w-full px-3 py-2 rounded-radius-md border border-border-default bg-bg-canvas text-text-primary font-text-sm focus:outline-none focus:ring-2 focus:ring-action-primary-border",
131
- children: H.map((e) => /* @__PURE__ */ f("option", {
136
+ children: H.map((e) => /* @__PURE__ */ d("option", {
132
137
  value: e.id,
133
138
  children: e.name
134
139
  }, e.id))
135
140
  })
136
141
  }),
137
- /* @__PURE__ */ p(g, {
142
+ /* @__PURE__ */ f(g, {
138
143
  title: C("calendar.displayPreferences", "Display preferences"),
139
144
  description: C("calendar.displayPreferencesDescription", "Personalize your default view, sidebar visibility, and timezone rendering."),
140
- icon: he,
141
- children: [/* @__PURE__ */ p("div", {
145
+ icon: ge,
146
+ children: [/* @__PURE__ */ f("div", {
142
147
  className: "grid grid-cols-1 gap-4 @md:grid-cols-2",
143
- children: [/* @__PURE__ */ p("div", {
148
+ children: [/* @__PURE__ */ f("div", {
144
149
  className: "space-y-2",
145
- children: [/* @__PURE__ */ f("p", {
150
+ children: [/* @__PURE__ */ d("p", {
146
151
  className: "font-text-sm font-weight-medium text-text-primary",
147
152
  children: C("calendar.currentView", "Current view")
148
- }), /* @__PURE__ */ f("p", {
153
+ }), /* @__PURE__ */ d("p", {
149
154
  className: "font-text-sm text-text-secondary",
150
- children: w[b] ?? b
155
+ children: w[y] ?? y
151
156
  })]
152
- }), /* @__PURE__ */ p("div", {
157
+ }), /* @__PURE__ */ f("div", {
153
158
  className: "flex items-center justify-between rounded-radius-md border border-border-subtle px-3 py-2 bg-bg-canvas",
154
- children: [/* @__PURE__ */ p("div", { children: [/* @__PURE__ */ f("p", {
159
+ children: [/* @__PURE__ */ f("div", { children: [/* @__PURE__ */ d("p", {
155
160
  className: "font-text-sm font-weight-medium text-text-primary",
156
161
  children: C("calendar.showMiniCalendar", "Show mini calendar")
157
- }), /* @__PURE__ */ f("p", {
162
+ }), /* @__PURE__ */ d("p", {
158
163
  className: "font-text-xs text-text-tertiary",
159
164
  children: C("calendar.showMiniCalendarDescription", "Display the mini calendar sidebar in calendar views.")
160
- })] }), /* @__PURE__ */ f("input", {
165
+ })] }), /* @__PURE__ */ d("input", {
161
166
  type: "checkbox",
162
- checked: xe,
163
- onChange: (e) => Se(e.target.checked),
167
+ checked: Ce,
168
+ onChange: (e) => x(e.target.checked),
164
169
  className: "size-4 rounded border-border-default",
165
170
  "aria-label": C("calendar.showMiniCalendar", "Show mini calendar")
166
171
  })]
167
172
  })]
168
- }), /* @__PURE__ */ p("div", { children: [/* @__PURE__ */ f("label", {
173
+ }), /* @__PURE__ */ f("div", { children: [/* @__PURE__ */ d("label", {
169
174
  className: "block font-text-sm font-weight-medium text-text-primary mb-1",
170
175
  children: C("calendar.timezone", "Timezone")
171
- }), /* @__PURE__ */ f("select", {
172
- value: x,
173
- onChange: (e) => be(e.target.value),
176
+ }), /* @__PURE__ */ d("select", {
177
+ value: b,
178
+ onChange: (e) => Se(e.target.value),
174
179
  className: "w-full px-3 py-2 rounded-radius-md border border-border-default bg-bg-canvas text-text-primary font-text-sm focus:outline-none focus:ring-2 focus:ring-action-primary-border",
175
- children: Intl.supportedValuesOf("timeZone").map((e) => /* @__PURE__ */ f("option", {
180
+ children: Intl.supportedValuesOf("timeZone").map((e) => /* @__PURE__ */ d("option", {
176
181
  value: e,
177
182
  children: e
178
183
  }, e))
179
184
  })] })]
180
185
  }),
181
- /* @__PURE__ */ p(g, {
186
+ /* @__PURE__ */ f(g, {
182
187
  title: C("calendar.sharingAndPermissions", "Sharing and permissions"),
183
188
  description: C("calendar.sharingAndPermissionsDescription", "Share calendars with users or teams using view, edit, or admin access."),
184
- icon: ye,
185
- children: [/* @__PURE__ */ p("form", {
189
+ icon: be,
190
+ children: [/* @__PURE__ */ f("form", {
186
191
  onSubmit: async (e) => {
187
- e.preventDefault(), !(!U || !D.trim()) && (await Fe({ variables: {
192
+ e.preventDefault(), !(!U || !D.trim()) && (await Ie({ variables: {
188
193
  calendarId: U,
189
194
  userId: k === "user" ? D.trim() : void 0,
190
195
  teamId: k === "team" ? D.trim() : void 0,
@@ -195,62 +200,62 @@ function v() {
195
200
  },
196
201
  className: "grid grid-cols-1 gap-3 @md:grid-cols-4",
197
202
  children: [
198
- /* @__PURE__ */ p("select", {
203
+ /* @__PURE__ */ f("select", {
199
204
  value: k,
200
205
  onChange: (e) => A(e.target.value),
201
206
  className: "px-3 py-2 rounded-radius-md border border-border-default bg-bg-canvas text-text-primary font-text-sm focus:outline-none focus:ring-2 focus:ring-action-primary-border",
202
- children: [/* @__PURE__ */ f("option", {
207
+ children: [/* @__PURE__ */ d("option", {
203
208
  value: "user",
204
209
  children: C("calendar.shareWithUser", "User")
205
- }), /* @__PURE__ */ f("option", {
210
+ }), /* @__PURE__ */ d("option", {
206
211
  value: "team",
207
212
  children: C("calendar.shareWithTeam", "Team")
208
213
  })]
209
214
  }),
210
- /* @__PURE__ */ f("input", {
215
+ /* @__PURE__ */ d("input", {
211
216
  value: D,
212
217
  onChange: (e) => O(e.target.value),
213
218
  placeholder: C("calendar.shareTargetPlaceholder", "User ID or team ID"),
214
219
  "aria-label": C("calendar.shareTarget", "Share target"),
215
220
  className: "px-3 py-2 rounded-radius-md border border-border-default bg-bg-canvas text-text-primary font-text-sm placeholder:text-text-tertiary focus:outline-none focus:ring-2 focus:ring-action-primary-border"
216
221
  }),
217
- /* @__PURE__ */ p("select", {
222
+ /* @__PURE__ */ f("select", {
218
223
  value: j,
219
224
  onChange: (e) => M(e.target.value),
220
225
  className: "px-3 py-2 rounded-radius-md border border-border-default bg-bg-canvas text-text-primary font-text-sm focus:outline-none focus:ring-2 focus:ring-action-primary-border",
221
226
  children: [
222
- /* @__PURE__ */ f("option", {
227
+ /* @__PURE__ */ d("option", {
223
228
  value: "VIEW",
224
229
  children: C("calendar.permissionView", "View")
225
230
  }),
226
- /* @__PURE__ */ f("option", {
231
+ /* @__PURE__ */ d("option", {
227
232
  value: "EDIT",
228
233
  children: C("calendar.permissionEdit", "Edit")
229
234
  }),
230
- /* @__PURE__ */ f("option", {
235
+ /* @__PURE__ */ d("option", {
231
236
  value: "ADMIN",
232
237
  children: C("calendar.permissionAdmin", "Admin")
233
238
  })
234
239
  ]
235
240
  }),
236
- /* @__PURE__ */ f("button", {
241
+ /* @__PURE__ */ d("button", {
237
242
  type: "submit",
238
243
  disabled: !U || !D.trim() || G,
239
244
  className: "px-4 py-2 rounded-radius-md bg-action-primary-bg text-action-primary-fg font-text-sm font-weight-medium hover:bg-action-primary-bg-hover disabled:opacity-50",
240
245
  children: G ? C("calendar.sharing", "Sharing...") : C("calendar.shareCalendar", "Share calendar")
241
246
  })
242
247
  ]
243
- }), /* @__PURE__ */ f("div", {
248
+ }), /* @__PURE__ */ d("div", {
244
249
  className: "space-y-2",
245
- children: Q.length === 0 ? /* @__PURE__ */ f("p", {
250
+ children: Q.length === 0 ? /* @__PURE__ */ d("p", {
246
251
  className: "font-text-sm text-text-secondary",
247
252
  children: C("calendar.noSharesConfigured", "No calendar shares configured yet.")
248
- }) : Q.map((e) => /* @__PURE__ */ p("div", {
253
+ }) : Q.map((e) => /* @__PURE__ */ f("div", {
249
254
  className: "flex flex-col gap-2 rounded-radius-md border border-border-subtle bg-bg-canvas p-3 @md:flex-row @md:items-center @md:justify-between",
250
- children: [/* @__PURE__ */ p("div", { children: [/* @__PURE__ */ f("p", {
255
+ children: [/* @__PURE__ */ f("div", { children: [/* @__PURE__ */ d("p", {
251
256
  className: "font-text-sm font-weight-medium text-text-primary",
252
257
  children: e.userId ?? e.teamId ?? C("calendar.unknownShareTarget", "Unknown target")
253
- }), /* @__PURE__ */ p("p", {
258
+ }), /* @__PURE__ */ f("p", {
254
259
  className: "font-text-xs text-text-tertiary",
255
260
  children: [
256
261
  e.canManage ? "ADMIN" : e.canEdit ? "EDIT" : "VIEW",
@@ -258,10 +263,10 @@ function v() {
258
263
  " ",
259
264
  _(e.createdAt)
260
265
  ]
261
- })] }), /* @__PURE__ */ f("button", {
266
+ })] }), /* @__PURE__ */ d("button", {
262
267
  type: "button",
263
268
  onClick: async () => {
264
- await Ie({ variables: { shareId: e.id } }), await $();
269
+ await Le({ variables: { shareId: e.id } }), await $();
265
270
  },
266
271
  className: "px-3 py-2 rounded-radius-md border border-border-default bg-bg-surface hover:bg-bg-elevated text-text-primary font-text-sm",
267
272
  children: C("calendar.revokeShare", "Revoke")
@@ -269,20 +274,20 @@ function v() {
269
274
  }, e.id))
270
275
  })]
271
276
  }),
272
- /* @__PURE__ */ p(g, {
277
+ /* @__PURE__ */ f(g, {
273
278
  title: C("calendar.availabilityAndBlocking", "Availability and blocking"),
274
279
  description: C("calendar.availabilityAndBlockingDescription", "Define recurring availability and create manual blackout windows for booking protection."),
275
- icon: pe,
280
+ icon: me,
276
281
  children: [
277
- /* @__PURE__ */ p("form", {
282
+ /* @__PURE__ */ f("form", {
278
283
  onSubmit: async (e) => {
279
- e.preventDefault(), U && (await Le({ variables: { input: {
284
+ e.preventDefault(), U && (await Re({ variables: { input: {
280
285
  calendarId: U,
281
286
  dayOfWeek: N.dayOfWeek,
282
287
  isAvailable: !0,
283
288
  startTime: N.startTime,
284
289
  endTime: N.endTime,
285
- timezone: x,
290
+ timezone: b,
286
291
  bufferBefore: parseInt(N.bufferBefore, 10),
287
292
  bufferAfter: parseInt(N.bufferAfter, 10),
288
293
  slotIncrement: parseInt(N.slotIncrement, 10),
@@ -292,7 +297,7 @@ function v() {
292
297
  },
293
298
  className: "grid grid-cols-1 gap-3 @md:grid-cols-4",
294
299
  children: [
295
- /* @__PURE__ */ f("select", {
300
+ /* @__PURE__ */ d("select", {
296
301
  value: N.dayOfWeek,
297
302
  onChange: (e) => P((t) => ({
298
303
  ...t,
@@ -307,12 +312,12 @@ function v() {
307
312
  "FRIDAY",
308
313
  "SATURDAY",
309
314
  "SUNDAY"
310
- ].map((e) => /* @__PURE__ */ f("option", {
315
+ ].map((e) => /* @__PURE__ */ d("option", {
311
316
  value: e,
312
317
  children: e
313
318
  }, e))
314
319
  }),
315
- /* @__PURE__ */ f("input", {
320
+ /* @__PURE__ */ d("input", {
316
321
  type: "time",
317
322
  value: N.startTime,
318
323
  onChange: (e) => P((t) => ({
@@ -322,7 +327,7 @@ function v() {
322
327
  className: "px-3 py-2 rounded-radius-md border border-border-default bg-bg-canvas text-text-primary font-text-sm focus:outline-none focus:ring-2 focus:ring-action-primary-border",
323
328
  "aria-label": C("calendar.availabilityStart", "Availability start time")
324
329
  }),
325
- /* @__PURE__ */ f("input", {
330
+ /* @__PURE__ */ d("input", {
326
331
  type: "time",
327
332
  value: N.endTime,
328
333
  onChange: (e) => P((t) => ({
@@ -332,7 +337,7 @@ function v() {
332
337
  className: "px-3 py-2 rounded-radius-md border border-border-default bg-bg-canvas text-text-primary font-text-sm focus:outline-none focus:ring-2 focus:ring-action-primary-border",
333
338
  "aria-label": C("calendar.availabilityEnd", "Availability end time")
334
339
  }),
335
- /* @__PURE__ */ f("button", {
340
+ /* @__PURE__ */ d("button", {
336
341
  type: "submit",
337
342
  disabled: !U || K,
338
343
  className: "px-4 py-2 rounded-radius-md bg-action-primary-bg text-action-primary-fg font-text-sm font-weight-medium hover:bg-action-primary-bg-hover disabled:opacity-50",
@@ -340,11 +345,11 @@ function v() {
340
345
  })
341
346
  ]
342
347
  }),
343
- /* @__PURE__ */ f("div", {
348
+ /* @__PURE__ */ d("div", {
344
349
  className: "space-y-2",
345
- children: Je.map((e) => /* @__PURE__ */ p("div", {
350
+ children: Ye.map((e) => /* @__PURE__ */ f("div", {
346
351
  className: "flex items-center justify-between rounded-radius-md border border-border-subtle bg-bg-canvas p-3",
347
- children: [/* @__PURE__ */ p("div", { children: [/* @__PURE__ */ p("p", {
352
+ children: [/* @__PURE__ */ f("div", { children: [/* @__PURE__ */ f("p", {
348
353
  className: "font-text-sm font-weight-medium text-text-primary",
349
354
  children: [
350
355
  e.dayOfWeek,
@@ -353,22 +358,22 @@ function v() {
353
358
  " - ",
354
359
  e.endTime
355
360
  ]
356
- }), /* @__PURE__ */ f("p", {
361
+ }), /* @__PURE__ */ d("p", {
357
362
  className: "font-text-xs text-text-tertiary",
358
363
  children: e.timezone
359
- })] }), /* @__PURE__ */ f("button", {
364
+ })] }), /* @__PURE__ */ d("button", {
360
365
  type: "button",
361
366
  onClick: async () => {
362
- await Re({ variables: { id: e.id } }), await $();
367
+ await ze({ variables: { id: e.id } }), await $();
363
368
  },
364
369
  className: "px-3 py-2 rounded-radius-md border border-border-default bg-bg-surface hover:bg-bg-elevated text-text-primary font-text-sm",
365
370
  children: C("calendar.delete", "Delete")
366
371
  })]
367
372
  }, e.id))
368
373
  }),
369
- /* @__PURE__ */ p("form", {
374
+ /* @__PURE__ */ f("form", {
370
375
  onSubmit: async (e) => {
371
- e.preventDefault(), !(!U || !F.startDate || !F.endDate) && (await ze({ variables: { input: {
376
+ e.preventDefault(), !(!U || !F.startDate || !F.endDate) && (await Be({ variables: { input: {
372
377
  calendarId: U,
373
378
  startDate: new Date(F.startDate).toISOString(),
374
379
  endDate: new Date(F.endDate).toISOString(),
@@ -381,7 +386,7 @@ function v() {
381
386
  },
382
387
  className: "grid grid-cols-1 gap-3 @md:grid-cols-4",
383
388
  children: [
384
- /* @__PURE__ */ f("input", {
389
+ /* @__PURE__ */ d("input", {
385
390
  type: "datetime-local",
386
391
  value: F.startDate,
387
392
  onChange: (e) => I((t) => ({
@@ -391,7 +396,7 @@ function v() {
391
396
  className: "px-3 py-2 rounded-radius-md border border-border-default bg-bg-canvas text-text-primary font-text-sm focus:outline-none focus:ring-2 focus:ring-action-primary-border",
392
397
  "aria-label": C("calendar.blackoutStart", "Blackout start")
393
398
  }),
394
- /* @__PURE__ */ f("input", {
399
+ /* @__PURE__ */ d("input", {
395
400
  type: "datetime-local",
396
401
  value: F.endDate,
397
402
  onChange: (e) => I((t) => ({
@@ -401,7 +406,7 @@ function v() {
401
406
  className: "px-3 py-2 rounded-radius-md border border-border-default bg-bg-canvas text-text-primary font-text-sm focus:outline-none focus:ring-2 focus:ring-action-primary-border",
402
407
  "aria-label": C("calendar.blackoutEnd", "Blackout end")
403
408
  }),
404
- /* @__PURE__ */ f("input", {
409
+ /* @__PURE__ */ d("input", {
405
410
  value: F.reason,
406
411
  onChange: (e) => I((t) => ({
407
412
  ...t,
@@ -411,7 +416,7 @@ function v() {
411
416
  "aria-label": C("calendar.blackoutReason", "Reason for block"),
412
417
  className: "px-3 py-2 rounded-radius-md border border-border-default bg-bg-canvas text-text-primary font-text-sm placeholder:text-text-tertiary focus:outline-none focus:ring-2 focus:ring-action-primary-border"
413
418
  }),
414
- /* @__PURE__ */ f("button", {
419
+ /* @__PURE__ */ d("button", {
415
420
  type: "submit",
416
421
  disabled: !U || q,
417
422
  className: "px-4 py-2 rounded-radius-md bg-action-primary-bg text-action-primary-fg font-text-sm font-weight-medium hover:bg-action-primary-bg-hover disabled:opacity-50",
@@ -419,24 +424,24 @@ function v() {
419
424
  })
420
425
  ]
421
426
  }),
422
- /* @__PURE__ */ f("div", {
427
+ /* @__PURE__ */ d("div", {
423
428
  className: "space-y-2",
424
- children: Ye.map((e) => /* @__PURE__ */ p("div", {
429
+ children: Xe.map((e) => /* @__PURE__ */ f("div", {
425
430
  className: "flex items-center justify-between rounded-radius-md border border-border-subtle bg-bg-canvas p-3",
426
- children: [/* @__PURE__ */ p("div", { children: [/* @__PURE__ */ p("p", {
431
+ children: [/* @__PURE__ */ f("div", { children: [/* @__PURE__ */ f("p", {
427
432
  className: "font-text-sm font-weight-medium text-text-primary",
428
433
  children: [
429
434
  _(e.startDate),
430
435
  " → ",
431
436
  _(e.endDate)
432
437
  ]
433
- }), /* @__PURE__ */ f("p", {
438
+ }), /* @__PURE__ */ d("p", {
434
439
  className: "font-text-xs text-text-tertiary",
435
440
  children: e.reason ?? "—"
436
- })] }), /* @__PURE__ */ f("button", {
441
+ })] }), /* @__PURE__ */ d("button", {
437
442
  type: "button",
438
443
  onClick: async () => {
439
- await Be({ variables: { id: e.id } }), await $();
444
+ await Ve({ variables: { id: e.id } }), await $();
440
445
  },
441
446
  className: "px-3 py-2 rounded-radius-md border border-border-default bg-bg-surface hover:bg-bg-elevated text-text-primary font-text-sm",
442
447
  children: C("calendar.delete", "Delete")
@@ -445,13 +450,13 @@ function v() {
445
450
  })
446
451
  ]
447
452
  }),
448
- /* @__PURE__ */ p(g, {
453
+ /* @__PURE__ */ f(g, {
449
454
  title: C("calendar.bookingPages", "Booking pages"),
450
455
  description: C("calendar.bookingPagesDescription", "Create Calendly-style booking pages for appointment scheduling from your calendar availability."),
451
- icon: ge,
452
- children: [/* @__PURE__ */ p("form", {
456
+ icon: _e,
457
+ children: [/* @__PURE__ */ f("form", {
453
458
  onSubmit: async (e) => {
454
- e.preventDefault(), !(!U || !L.name.trim() || !L.slug.trim()) && (await Ve({ variables: { input: {
459
+ e.preventDefault(), !(!U || !L.name.trim() || !L.slug.trim()) && (await He({ variables: { input: {
455
460
  calendarId: U,
456
461
  name: L.name.trim(),
457
462
  slug: L.slug.trim(),
@@ -474,7 +479,7 @@ function v() {
474
479
  },
475
480
  className: "grid grid-cols-1 gap-3 @md:grid-cols-3",
476
481
  children: [
477
- /* @__PURE__ */ f("input", {
482
+ /* @__PURE__ */ d("input", {
478
483
  "aria-label": C("calendar.bookingPageName", "Booking page name"),
479
484
  value: L.name,
480
485
  onChange: (e) => R((t) => ({
@@ -484,7 +489,7 @@ function v() {
484
489
  placeholder: C("calendar.bookingPageName", "Booking page name"),
485
490
  className: "px-3 py-2 rounded-radius-md border border-border-default bg-bg-canvas text-text-primary font-text-sm placeholder:text-text-tertiary focus:outline-none focus:ring-2 focus:ring-action-primary-border"
486
491
  }),
487
- /* @__PURE__ */ f("input", {
492
+ /* @__PURE__ */ d("input", {
488
493
  "aria-label": C("calendar.bookingPageSlugLabel", "Booking page slug"),
489
494
  value: L.slug,
490
495
  onChange: (e) => R((t) => ({
@@ -494,7 +499,7 @@ function v() {
494
499
  placeholder: C("calendar.bookingPageSlug", "booking-page-slug"),
495
500
  className: "px-3 py-2 rounded-radius-md border border-border-default bg-bg-canvas text-text-primary font-text-sm placeholder:text-text-tertiary focus:outline-none focus:ring-2 focus:ring-action-primary-border"
496
501
  }),
497
- /* @__PURE__ */ f("input", {
502
+ /* @__PURE__ */ d("input", {
498
503
  "aria-label": C("calendar.bookingPageDuration", "Event duration in minutes"),
499
504
  type: "number",
500
505
  min: "15",
@@ -506,7 +511,7 @@ function v() {
506
511
  })),
507
512
  className: "px-3 py-2 rounded-radius-md border border-border-default bg-bg-canvas text-text-primary font-text-sm focus:outline-none focus:ring-2 focus:ring-action-primary-border"
508
513
  }),
509
- /* @__PURE__ */ f("select", {
514
+ /* @__PURE__ */ d("select", {
510
515
  value: L.pageType,
511
516
  onChange: (e) => R((t) => ({
512
517
  ...t,
@@ -518,12 +523,12 @@ function v() {
518
523
  "GROUP",
519
524
  "ROUND_ROBIN",
520
525
  "COLLECTIVE"
521
- ].map((e) => /* @__PURE__ */ f("option", {
526
+ ].map((e) => /* @__PURE__ */ d("option", {
522
527
  value: e,
523
528
  children: e
524
529
  }, e))
525
530
  }),
526
- /* @__PURE__ */ f("select", {
531
+ /* @__PURE__ */ d("select", {
527
532
  value: L.locationType,
528
533
  onChange: (e) => R((t) => ({
529
534
  ...t,
@@ -535,14 +540,14 @@ function v() {
535
540
  "PHYSICAL",
536
541
  "HYBRID",
537
542
  "TBD"
538
- ].map((e) => /* @__PURE__ */ f("option", {
543
+ ].map((e) => /* @__PURE__ */ d("option", {
539
544
  value: e,
540
545
  children: e
541
546
  }, e))
542
547
  }),
543
- /* @__PURE__ */ p("div", {
548
+ /* @__PURE__ */ f("div", {
544
549
  className: "flex items-center gap-3 rounded-radius-md border border-border-subtle bg-bg-canvas px-3 py-2",
545
- children: [/* @__PURE__ */ f("input", {
550
+ children: [/* @__PURE__ */ d("input", {
546
551
  id: "booking-page-approval",
547
552
  "aria-label": C("calendar.requireApproval", "Require approval"),
548
553
  type: "checkbox",
@@ -552,31 +557,31 @@ function v() {
552
557
  requireApproval: e.target.checked
553
558
  })),
554
559
  className: "size-4 rounded border-border-default"
555
- }), /* @__PURE__ */ f("label", {
560
+ }), /* @__PURE__ */ d("label", {
556
561
  htmlFor: "booking-page-approval",
557
562
  className: "font-text-sm text-text-primary",
558
563
  children: C("calendar.requireApproval", "Require approval")
559
564
  })]
560
565
  }),
561
- /* @__PURE__ */ f("button", {
566
+ /* @__PURE__ */ d("button", {
562
567
  type: "submit",
563
568
  disabled: !U || J,
564
569
  className: "@md:col-span-3 px-4 py-2 rounded-radius-md bg-action-primary-bg text-action-primary-fg font-text-sm font-weight-medium hover:bg-action-primary-bg-hover disabled:opacity-50",
565
570
  children: J ? C("calendar.creating", "Creating...") : C("calendar.createBookingPage", "Create booking page")
566
571
  })
567
572
  ]
568
- }), /* @__PURE__ */ f("div", {
573
+ }), /* @__PURE__ */ d("div", {
569
574
  className: "space-y-2",
570
- children: qe.map((e) => /* @__PURE__ */ p("div", {
575
+ children: Je.map((e) => /* @__PURE__ */ f("div", {
571
576
  className: "flex items-center justify-between rounded-radius-md border border-border-subtle bg-bg-canvas p-3",
572
- children: [/* @__PURE__ */ p("div", { children: [/* @__PURE__ */ p("p", {
577
+ children: [/* @__PURE__ */ f("div", { children: [/* @__PURE__ */ f("p", {
573
578
  className: "font-text-sm font-weight-medium text-text-primary",
574
579
  children: [
575
580
  e.name,
576
581
  " • ",
577
582
  e.pageType
578
583
  ]
579
- }), /* @__PURE__ */ p("p", {
584
+ }), /* @__PURE__ */ f("p", {
580
585
  className: "font-text-xs text-text-tertiary",
581
586
  children: [
582
587
  "/book/",
@@ -587,10 +592,10 @@ function v() {
587
592
  " ",
588
593
  e.isActive ? "ACTIVE" : "INACTIVE"
589
594
  ]
590
- })] }), /* @__PURE__ */ f("button", {
595
+ })] }), /* @__PURE__ */ d("button", {
591
596
  type: "button",
592
597
  onClick: async () => {
593
- await He({ variables: { id: e.id } }), await $();
598
+ await Ue({ variables: { id: e.id } }), await $();
594
599
  },
595
600
  className: "px-3 py-2 rounded-radius-md border border-border-default bg-bg-surface hover:bg-bg-elevated text-text-primary font-text-sm",
596
601
  children: C("calendar.delete", "Delete")
@@ -598,13 +603,13 @@ function v() {
598
603
  }, e.id))
599
604
  })]
600
605
  }),
601
- /* @__PURE__ */ p(g, {
606
+ /* @__PURE__ */ f(g, {
602
607
  title: C("calendar.externalCalendarSync", "External calendar sync"),
603
608
  description: C("calendar.externalCalendarSyncDescription", "Configure Google, Outlook, and Apple-compatible sync connections and trigger synchronization cycles."),
604
- icon: ve,
605
- children: [/* @__PURE__ */ p("form", {
609
+ icon: ye,
610
+ children: [/* @__PURE__ */ f("form", {
606
611
  onSubmit: async (e) => {
607
- e.preventDefault(), !(!U || !z.externalCalendarId.trim() || !z.accessToken.trim()) && (await Ue({ variables: { input: {
612
+ e.preventDefault(), !(!U || !z.externalCalendarId.trim() || !z.accessToken.trim()) && (await We({ variables: { input: {
608
613
  calendarId: U,
609
614
  provider: z.provider,
610
615
  externalCalendarId: z.externalCalendarId.trim(),
@@ -625,7 +630,7 @@ function v() {
625
630
  },
626
631
  className: "grid grid-cols-1 gap-3 @md:grid-cols-3",
627
632
  children: [
628
- /* @__PURE__ */ p("select", {
633
+ /* @__PURE__ */ f("select", {
629
634
  value: z.provider,
630
635
  onChange: (e) => B((t) => ({
631
636
  ...t,
@@ -633,25 +638,25 @@ function v() {
633
638
  })),
634
639
  className: "px-3 py-2 rounded-radius-md border border-border-default bg-bg-canvas text-text-primary font-text-sm focus:outline-none focus:ring-2 focus:ring-action-primary-border",
635
640
  children: [
636
- /* @__PURE__ */ f("option", {
641
+ /* @__PURE__ */ d("option", {
637
642
  value: "GOOGLE_CALENDAR",
638
643
  children: "Google Calendar"
639
644
  }),
640
- /* @__PURE__ */ f("option", {
645
+ /* @__PURE__ */ d("option", {
641
646
  value: "OUTLOOK_CALENDAR",
642
647
  children: "Outlook Calendar"
643
648
  }),
644
- /* @__PURE__ */ f("option", {
649
+ /* @__PURE__ */ d("option", {
645
650
  value: "APPLE_ICAL",
646
651
  children: "Apple Calendar"
647
652
  }),
648
- /* @__PURE__ */ f("option", {
653
+ /* @__PURE__ */ d("option", {
649
654
  value: "CALDAV",
650
655
  children: "CalDAV"
651
656
  })
652
657
  ]
653
658
  }),
654
- /* @__PURE__ */ f("input", {
659
+ /* @__PURE__ */ d("input", {
655
660
  "aria-label": C("calendar.externalCalendarId", "External calendar ID"),
656
661
  value: z.externalCalendarId,
657
662
  onChange: (e) => B((t) => ({
@@ -661,7 +666,7 @@ function v() {
661
666
  placeholder: C("calendar.externalCalendarId", "External calendar ID"),
662
667
  className: "px-3 py-2 rounded-radius-md border border-border-default bg-bg-canvas text-text-primary font-text-sm placeholder:text-text-tertiary focus:outline-none focus:ring-2 focus:ring-action-primary-border"
663
668
  }),
664
- /* @__PURE__ */ f("input", {
669
+ /* @__PURE__ */ d("input", {
665
670
  "aria-label": C("calendar.externalCalendarName", "External calendar name"),
666
671
  value: z.externalCalendarName,
667
672
  onChange: (e) => B((t) => ({
@@ -671,7 +676,7 @@ function v() {
671
676
  placeholder: C("calendar.externalCalendarName", "External calendar name"),
672
677
  className: "px-3 py-2 rounded-radius-md border border-border-default bg-bg-canvas text-text-primary font-text-sm placeholder:text-text-tertiary focus:outline-none focus:ring-2 focus:ring-action-primary-border"
673
678
  }),
674
- /* @__PURE__ */ f("input", {
679
+ /* @__PURE__ */ d("input", {
675
680
  "aria-label": C("calendar.accessToken", "Access token"),
676
681
  value: z.accessToken,
677
682
  onChange: (e) => B((t) => ({
@@ -681,7 +686,7 @@ function v() {
681
686
  placeholder: C("calendar.accessToken", "Access token"),
682
687
  className: "px-3 py-2 rounded-radius-md border border-border-default bg-bg-canvas text-text-primary font-text-sm placeholder:text-text-tertiary focus:outline-none focus:ring-2 focus:ring-action-primary-border"
683
688
  }),
684
- /* @__PURE__ */ f("input", {
689
+ /* @__PURE__ */ d("input", {
685
690
  "aria-label": C("calendar.refreshToken", "Refresh token (optional)"),
686
691
  value: z.refreshToken,
687
692
  onChange: (e) => B((t) => ({
@@ -691,7 +696,7 @@ function v() {
691
696
  placeholder: C("calendar.refreshToken", "Refresh token (optional)"),
692
697
  className: "px-3 py-2 rounded-radius-md border border-border-default bg-bg-canvas text-text-primary font-text-sm placeholder:text-text-tertiary focus:outline-none focus:ring-2 focus:ring-action-primary-border"
693
698
  }),
694
- /* @__PURE__ */ f("input", {
699
+ /* @__PURE__ */ d("input", {
695
700
  "aria-label": C("calendar.syncFrequencyLabel", "Sync frequency in seconds"),
696
701
  type: "number",
697
702
  min: "60",
@@ -703,7 +708,7 @@ function v() {
703
708
  })),
704
709
  className: "px-3 py-2 rounded-radius-md border border-border-default bg-bg-canvas text-text-primary font-text-sm focus:outline-none focus:ring-2 focus:ring-action-primary-border"
705
710
  }),
706
- /* @__PURE__ */ p("select", {
711
+ /* @__PURE__ */ f("select", {
707
712
  value: z.direction,
708
713
  onChange: (e) => B((t) => ({
709
714
  ...t,
@@ -711,33 +716,33 @@ function v() {
711
716
  })),
712
717
  className: "@md:col-span-2 px-3 py-2 rounded-radius-md border border-border-default bg-bg-canvas text-text-primary font-text-sm focus:outline-none focus:ring-2 focus:ring-action-primary-border",
713
718
  children: [
714
- /* @__PURE__ */ f("option", {
719
+ /* @__PURE__ */ d("option", {
715
720
  value: "TWO_WAY",
716
721
  children: C("calendar.twoWaySync", "Two-way sync")
717
722
  }),
718
- /* @__PURE__ */ f("option", {
723
+ /* @__PURE__ */ d("option", {
719
724
  value: "ONE_WAY_TO_EXTERNAL",
720
725
  children: C("calendar.oneWayToExternal", "One-way to external")
721
726
  }),
722
- /* @__PURE__ */ f("option", {
727
+ /* @__PURE__ */ d("option", {
723
728
  value: "ONE_WAY_FROM_EXTERNAL",
724
729
  children: C("calendar.oneWayFromExternal", "One-way from external")
725
730
  })
726
731
  ]
727
732
  }),
728
- /* @__PURE__ */ f("button", {
733
+ /* @__PURE__ */ d("button", {
729
734
  type: "submit",
730
735
  disabled: !U || Y,
731
736
  className: "px-4 py-2 rounded-radius-md bg-action-primary-bg text-action-primary-fg font-text-sm font-weight-medium hover:bg-action-primary-bg-hover disabled:opacity-50",
732
737
  children: Y ? C("calendar.connecting", "Connecting...") : C("calendar.connectExternalCalendar", "Connect external calendar")
733
738
  })
734
739
  ]
735
- }), /* @__PURE__ */ f("div", {
740
+ }), /* @__PURE__ */ d("div", {
736
741
  className: "space-y-3",
737
- children: Xe.map((e) => /* @__PURE__ */ p("div", {
742
+ children: Ze.map((e) => /* @__PURE__ */ f("div", {
738
743
  className: "rounded-radius-md border border-border-subtle bg-bg-canvas p-3 space-y-3",
739
- children: [/* @__PURE__ */ p("div", { children: [
740
- /* @__PURE__ */ p("p", {
744
+ children: [/* @__PURE__ */ f("div", { children: [
745
+ /* @__PURE__ */ f("p", {
741
746
  className: "font-text-sm font-weight-medium text-text-primary",
742
747
  children: [
743
748
  e.provider,
@@ -745,7 +750,7 @@ function v() {
745
750
  e.externalCalendarName ?? e.externalCalendarId
746
751
  ]
747
752
  }),
748
- /* @__PURE__ */ p("p", {
753
+ /* @__PURE__ */ f("p", {
749
754
  className: "font-text-xs text-text-tertiary",
750
755
  children: [
751
756
  e.status,
@@ -754,7 +759,7 @@ function v() {
754
759
  C("calendar.everySeconds", "Every {value} seconds").replace("{value}", String(e.syncFrequency))
755
760
  ]
756
761
  }),
757
- /* @__PURE__ */ p("p", {
762
+ /* @__PURE__ */ f("p", {
758
763
  className: "font-text-xs text-text-tertiary",
759
764
  children: [
760
765
  C("calendar.lastSync", "Last sync"),
@@ -765,33 +770,33 @@ function v() {
765
770
  e.lastSyncStatus ?? "—"
766
771
  ]
767
772
  }),
768
- e.lastSyncError ? /* @__PURE__ */ f("p", {
773
+ e.lastSyncError ? /* @__PURE__ */ d("p", {
769
774
  className: "font-text-xs text-text-secondary",
770
775
  children: e.lastSyncError
771
776
  }) : null
772
- ] }), /* @__PURE__ */ p("div", {
777
+ ] }), /* @__PURE__ */ f("div", {
773
778
  className: "flex flex-wrap gap-2",
774
779
  children: [
775
- /* @__PURE__ */ f("button", {
780
+ /* @__PURE__ */ d("button", {
776
781
  type: "button",
777
782
  onClick: async () => {
778
- await Ge({ variables: { syncId: e.id } }), await $();
783
+ await qe({ variables: { syncId: e.id } }), await $();
779
784
  },
780
785
  className: "px-3 py-2 rounded-radius-md border border-border-default bg-bg-surface hover:bg-bg-elevated text-text-primary font-text-sm",
781
786
  children: C("calendar.triggerSync", "Trigger sync")
782
787
  }),
783
- /* @__PURE__ */ f("button", {
788
+ /* @__PURE__ */ d("button", {
784
789
  type: "button",
785
790
  onClick: async () => {
786
- e.syncEnabled ? await We({ variables: { syncId: e.id } }) : await X({ variables: { syncId: e.id } }), await $();
791
+ e.syncEnabled ? await Ge({ variables: { syncId: e.id } }) : await Ke({ variables: { syncId: e.id } }), await $();
787
792
  },
788
793
  className: "px-3 py-2 rounded-radius-md border border-border-default bg-bg-surface hover:bg-bg-elevated text-text-primary font-text-sm",
789
794
  children: e.syncEnabled ? C("calendar.pauseSync", "Pause") : C("calendar.resumeSync", "Resume")
790
795
  }),
791
- /* @__PURE__ */ f("button", {
796
+ /* @__PURE__ */ d("button", {
792
797
  type: "button",
793
798
  onClick: async () => {
794
- await Ke({ variables: { syncId: e.id } }), await $();
799
+ await X({ variables: { syncId: e.id } }), await $();
795
800
  },
796
801
  className: "px-3 py-2 rounded-radius-md border border-border-default bg-bg-surface hover:bg-bg-elevated text-text-primary font-text-sm",
797
802
  children: C("calendar.disconnect", "Disconnect")
@@ -803,7 +808,7 @@ function v() {
803
808
  })
804
809
  ]
805
810
  })]
806
- }) : /* @__PURE__ */ f(de, {
811
+ }) : /* @__PURE__ */ d(fe, {
807
812
  title: C("calendar.accessDenied", "Access Denied"),
808
813
  description: C("calendar.noPermissionViewSettings", "You don't have permission to view calendar settings.")
809
814
  });