@burdenoff/microfe-calendar 2026.1114.1 → 2026.1119.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.
@@ -8,9 +8,9 @@ import { useMemo as l, useState as u } from "react";
8
8
  import { AccessDenied as d } from "@burdenoff/fe-libs/shared/components";
9
9
  import { Car as f, DoorOpen as p, MapPin as m, Monitor as h, Package as g, Plus as _, Users as v, X as y } from "lucide-react";
10
10
  import { Fragment as b, jsx as x, jsxs as S } from "react/jsx-runtime";
11
- import { EmphasisPanel as C, GlassCard as w, GradientText as T, IllustratedEmptyState as E, PagePurpose as D } from "@burdenoff/fe-libs/ui";
11
+ import { EmphasisPanel as C, GlassCard as w, GradientText as T, IllustratedEmptyState as E, PagePurpose as D, ThemedSelect as O } from "@burdenoff/fe-libs/ui";
12
12
  // src/pages/ResourcesPage.tsx
13
- var O = {
13
+ var k = {
14
14
  ROOM: p,
15
15
  EQUIPMENT: h,
16
16
  VEHICLE: f,
@@ -18,11 +18,11 @@ var O = {
18
18
  PARKING_SPOT: f,
19
19
  OTHER: g
20
20
  };
21
- function k() {
22
- let { hasPermission: f, isLoading: h } = o(), k = e(), [A, j] = u(!1), [M, N] = u(null), P = f(a.CALENDAR_RESOURCE_READ), { data: F, loading: I, error: L, refetch: R } = r({
21
+ function A() {
22
+ let { hasPermission: f, isLoading: h } = o(), A = e(), [j, M] = u(!1), [N, P] = u(null), F = f(a.CALENDAR_RESOURCE_READ), { data: I, loading: L, error: R, refetch: z } = r({
23
23
  fetchPolicy: "cache-and-network",
24
- skip: h || !P
25
- }), z = F?.getCalendarResources ?? [], [B, { loading: V, error: H }] = t(), [U, { loading: W }] = n(), [G, K] = u({
24
+ skip: h || !F
25
+ }), B = I?.getCalendarResources ?? [], [V, { loading: H, error: U }] = t(), [W, { loading: G }] = n(), [K, q] = u({
26
26
  name: "",
27
27
  description: "",
28
28
  resourceType: "ROOM",
@@ -32,26 +32,26 @@ function k() {
32
32
  floor: "",
33
33
  room: "",
34
34
  requireApproval: !1
35
- }), q = l(() => ({
36
- ROOM: k("calendar.room", "Room"),
37
- EQUIPMENT: k("calendar.equipment", "Equipment"),
38
- VEHICLE: k("calendar.vehicle", "Vehicle"),
39
- DESK: k("calendar.desk", "Desk"),
40
- PARKING_SPOT: k("calendar.parkingSpot", "Parking Spot"),
41
- OTHER: k("calendar.other", "Other")
42
- }), [k]), J = (e, t) => {
43
- K((n) => ({
35
+ }), J = l(() => ({
36
+ ROOM: A("calendar.room", "Room"),
37
+ EQUIPMENT: A("calendar.equipment", "Equipment"),
38
+ VEHICLE: A("calendar.vehicle", "Vehicle"),
39
+ DESK: A("calendar.desk", "Desk"),
40
+ PARKING_SPOT: A("calendar.parkingSpot", "Parking Spot"),
41
+ OTHER: A("calendar.other", "Other")
42
+ }), [A]), Y = (e, t) => {
43
+ q((n) => ({
44
44
  ...n,
45
45
  [e]: t
46
46
  }));
47
47
  };
48
- return h || I && !F ? /* @__PURE__ */ x("div", {
48
+ return h || L && !I ? /* @__PURE__ */ x("div", {
49
49
  className: "@container min-h-screen bg-bg-canvas flex items-center justify-center",
50
50
  children: /* @__PURE__ */ x("p", {
51
51
  className: "font-text-md text-text-secondary",
52
- children: k("calendar.loading", "Loading...")
52
+ children: A("calendar.loading", "Loading...")
53
53
  })
54
- }) : P ? /* @__PURE__ */ S("div", {
54
+ }) : F ? /* @__PURE__ */ S("div", {
55
55
  className: "@container min-h-screen bg-bg-canvas",
56
56
  children: [
57
57
  /* @__PURE__ */ x("header", {
@@ -60,72 +60,72 @@ function k() {
60
60
  className: "flex flex-col @lg:flex-row @lg:items-center @lg:justify-between gap-stack-gap",
61
61
  children: [/* @__PURE__ */ S("div", { children: [/* @__PURE__ */ x("h1", {
62
62
  className: "font-heading-lg text-text-primary mb-stack-gap-sm",
63
- children: /* @__PURE__ */ x(T, { children: k("calendar.resources", "Resources") })
63
+ children: /* @__PURE__ */ x(T, { children: A("calendar.resources", "Resources") })
64
64
  }), /* @__PURE__ */ x(D, {
65
65
  className: "max-w-2xl",
66
- children: k("calendar.resourcesPagePurpose", "A shared inventory of bookable rooms, equipment, vehicles, and desks. Add a resource here, then attach it to an event so it is reserved for that time — capacity, location, and approval rules keep double-bookings out.")
66
+ children: A("calendar.resourcesPagePurpose", "A shared inventory of bookable rooms, equipment, vehicles, and desks. Add a resource here, then attach it to an event so it is reserved for that time — capacity, location, and approval rules keep double-bookings out.")
67
67
  })] }), f(a.CALENDAR_RESOURCE_CREATE) ? /* @__PURE__ */ S("button", {
68
68
  type: "button",
69
- onClick: () => j(!0),
69
+ onClick: () => M(!0),
70
70
  className: "inline-flex items-center gap-inline-gap-sm px-element-padding py-element-padding-sm rounded-radius-md bg-action-primary-bg text-action-primary-fg font-text-sm font-weight-medium hover:bg-action-primary-bg-hover transition-colors",
71
- children: [/* @__PURE__ */ x(_, { className: "size-4" }), k("calendar.addResource", "Add Resource")]
71
+ children: [/* @__PURE__ */ x(_, { className: "size-4" }), A("calendar.addResource", "Add Resource")]
72
72
  }) : null]
73
73
  })
74
74
  }),
75
75
  /* @__PURE__ */ S("div", {
76
76
  className: "p-page-padding",
77
77
  children: [
78
- I && z.length === 0 && /* @__PURE__ */ x("div", {
78
+ L && B.length === 0 && /* @__PURE__ */ x("div", {
79
79
  className: "text-center py-12",
80
80
  children: /* @__PURE__ */ x("p", {
81
81
  className: "font-text-md text-text-secondary",
82
- children: k("calendar.loadingResources", "Loading resources...")
82
+ children: A("calendar.loadingResources", "Loading resources...")
83
83
  })
84
84
  }),
85
- L && /* @__PURE__ */ x("div", {
85
+ R && /* @__PURE__ */ x("div", {
86
86
  className: "text-center py-12",
87
87
  children: /* @__PURE__ */ S("p", {
88
88
  className: "font-text-md text-red-600 dark:text-red-400",
89
89
  children: [
90
- k("calendar.failedToLoadResources", "Failed to load resources:"),
90
+ A("calendar.failedToLoadResources", "Failed to load resources:"),
91
91
  " ",
92
- L.message
92
+ R.message
93
93
  ]
94
94
  })
95
95
  }),
96
- !I && !L && z.length === 0 && /* @__PURE__ */ x(E, {
96
+ !L && !R && B.length === 0 && /* @__PURE__ */ x(E, {
97
97
  illustration: "empty-data",
98
- title: k("calendar.noResourcesYet", "No resources yet"),
99
- description: k("calendar.bookConferenceRooms", "Book conference rooms, equipment, and other workspace resources"),
98
+ title: A("calendar.noResourcesYet", "No resources yet"),
99
+ description: A("calendar.bookConferenceRooms", "Book conference rooms, equipment, and other workspace resources"),
100
100
  action: f(a.CALENDAR_RESOURCE_CREATE) ? /* @__PURE__ */ S("button", {
101
101
  type: "button",
102
- onClick: () => j(!0),
102
+ onClick: () => M(!0),
103
103
  className: "inline-flex min-h-11 items-center gap-inline-gap-sm px-element-padding py-element-padding-sm rounded-radius-md bg-action-primary-bg text-action-primary-fg font-text-sm font-weight-medium hover:bg-action-primary-bg-hover transition-colors focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-action-primary-border",
104
- children: [/* @__PURE__ */ x(_, { className: "size-4" }), k("calendar.addYourFirstResource", "Add your first resource")]
104
+ children: [/* @__PURE__ */ x(_, { className: "size-4" }), A("calendar.addYourFirstResource", "Add your first resource")]
105
105
  }) : void 0
106
106
  }),
107
- z.length > 0 && /* @__PURE__ */ S(b, { children: [/* @__PURE__ */ S(C, {
107
+ B.length > 0 && /* @__PURE__ */ S(b, { children: [/* @__PURE__ */ S(C, {
108
108
  className: "mb-section-gap flex flex-wrap items-center justify-between gap-stack-gap",
109
109
  children: [/* @__PURE__ */ S("div", {
110
110
  className: "flex items-start gap-3",
111
111
  children: [/* @__PURE__ */ x(p, { className: "size-5 text-action-primary-bg shrink-0 mt-0.5" }), /* @__PURE__ */ S("div", { children: [/* @__PURE__ */ x("p", {
112
112
  className: "font-text-sm font-weight-semibold text-text-primary mb-0.5",
113
- children: k("calendar.bookableResources", "Bookable resources")
113
+ children: A("calendar.bookableResources", "Bookable resources")
114
114
  }), /* @__PURE__ */ x("p", {
115
115
  className: "font-text-sm text-text-secondary",
116
- children: k("calendar.resourcesSummary", "{{count}} resources ready to attach to your events. Open an event and add a resource to reserve it.", { count: z.length })
116
+ children: A("calendar.resourcesSummary", "{{count}} resources ready to attach to your events. Open an event and add a resource to reserve it.", { count: B.length })
117
117
  })] })]
118
118
  }), f(a.CALENDAR_RESOURCE_CREATE) ? /* @__PURE__ */ S("button", {
119
119
  type: "button",
120
- onClick: () => j(!0),
120
+ onClick: () => M(!0),
121
121
  className: "inline-flex items-center gap-inline-gap-sm px-element-padding py-element-padding-sm rounded-radius-md bg-action-primary-bg text-action-primary-fg font-text-sm font-weight-medium hover:bg-action-primary-bg-hover transition-colors focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-action-primary-border",
122
- children: [/* @__PURE__ */ x(_, { className: "size-4" }), k("calendar.addResource", "Add Resource")]
122
+ children: [/* @__PURE__ */ x(_, { className: "size-4" }), A("calendar.addResource", "Add Resource")]
123
123
  }) : null]
124
124
  }), /* @__PURE__ */ x("div", {
125
125
  className: "grid gap-grid-gap",
126
126
  style: { gridTemplateColumns: "repeat(auto-fit, minmax(18rem, 1fr))" },
127
- children: z.map((e) => {
128
- let t = O[e.resourceType] ?? g;
127
+ children: B.map((e) => {
128
+ let t = k[e.resourceType] ?? g;
129
129
  return /* @__PURE__ */ x(w, {
130
130
  treatment: "metric",
131
131
  className: "@container p-card-padding",
@@ -144,12 +144,12 @@ function k() {
144
144
  children: e.name
145
145
  }), f(a.CALENDAR_RESOURCE_DELETE) && /* @__PURE__ */ x("button", {
146
146
  type: "button",
147
- onClick: () => N({
147
+ onClick: () => P({
148
148
  id: e.id,
149
149
  name: e.name
150
150
  }),
151
151
  className: "size-6 inline-flex items-center justify-center rounded-radius-sm hover:bg-red-50 dark:hover:bg-red-950/20 text-text-tertiary hover:text-red-600 transition-colors shrink-0",
152
- "aria-label": `${k("calendar.deleteResource", "Delete Resource")} ${e.name}`,
152
+ "aria-label": `${A("calendar.deleteResource", "Delete Resource")} ${e.name}`,
153
153
  children: /* @__PURE__ */ x(y, { className: "size-3.5" })
154
154
  })]
155
155
  }),
@@ -162,7 +162,7 @@ function k() {
162
162
  children: [
163
163
  /* @__PURE__ */ x("span", {
164
164
  className: "font-text-xs px-2 py-0.5 rounded-radius-sm bg-bg-neutral text-text-secondary",
165
- children: q[e.resourceType] ?? e.resourceType
165
+ children: J[e.resourceType] ?? e.resourceType
166
166
  }),
167
167
  e.capacity && /* @__PURE__ */ S("span", {
168
168
  className: "inline-flex items-center gap-1 font-text-xs text-text-tertiary",
@@ -178,10 +178,10 @@ function k() {
178
178
  className: "mt-2 flex items-center gap-2",
179
179
  children: [/* @__PURE__ */ x("span", {
180
180
  className: `font-text-xs px-2 py-0.5 rounded-radius-sm ${e.isActive ? "bg-green-100 dark:bg-green-900/30 text-green-700 dark:text-green-300" : "bg-gray-100 dark:bg-gray-800 text-gray-600 dark:text-gray-400"}`,
181
- children: e.isActive ? k("calendar.active", "Active") : k("calendar.inactive", "Inactive")
181
+ children: e.isActive ? A("calendar.active", "Active") : A("calendar.inactive", "Inactive")
182
182
  }), e.requireApproval && /* @__PURE__ */ x("span", {
183
183
  className: "font-text-xs px-2 py-0.5 rounded-radius-sm bg-amber-100 dark:bg-amber-900/30 text-amber-700 dark:text-amber-300",
184
- children: k("calendar.requiresApproval", "Requires Approval")
184
+ children: A("calendar.requiresApproval", "Requires Approval")
185
185
  })]
186
186
  })
187
187
  ]
@@ -192,28 +192,28 @@ function k() {
192
192
  })] })
193
193
  ]
194
194
  }),
195
- A && /* @__PURE__ */ S("dialog", {
195
+ j && /* @__PURE__ */ S("dialog", {
196
196
  open: !0,
197
197
  className: "fixed inset-0 z-50 m-auto rounded-radius-lg border border-border-default bg-bg-surface shadow-lg backdrop:bg-black/50 max-w-lg w-full p-0",
198
198
  style: { position: "fixed" },
199
199
  children: [/* @__PURE__ */ x("button", {
200
200
  type: "button",
201
- "aria-label": k("calendar.closeDialog", "Close dialog"),
201
+ "aria-label": A("calendar.closeDialog", "Close dialog"),
202
202
  className: "fixed inset-0 bg-black/50",
203
- onClick: () => j(!1)
203
+ onClick: () => M(!1)
204
204
  }), /* @__PURE__ */ S("form", {
205
205
  onSubmit: async (e) => {
206
- e.preventDefault(), G.name.trim() && (await B({ variables: { input: {
207
- name: G.name,
208
- description: G.description || void 0,
209
- resourceType: G.resourceType,
210
- capacity: G.capacity ? parseInt(G.capacity, 10) : void 0,
211
- location: G.location || void 0,
212
- building: G.building || void 0,
213
- floor: G.floor || void 0,
214
- room: G.room || void 0,
215
- requireApproval: G.requireApproval
216
- } } }), K({
206
+ e.preventDefault(), K.name.trim() && (await V({ variables: { input: {
207
+ name: K.name,
208
+ description: K.description || void 0,
209
+ resourceType: K.resourceType,
210
+ capacity: K.capacity ? parseInt(K.capacity, 10) : void 0,
211
+ location: K.location || void 0,
212
+ building: K.building || void 0,
213
+ floor: K.floor || void 0,
214
+ room: K.room || void 0,
215
+ requireApproval: K.requireApproval
216
+ } } }), q({
217
217
  name: "",
218
218
  description: "",
219
219
  resourceType: "ROOM",
@@ -223,7 +223,7 @@ function k() {
223
223
  floor: "",
224
224
  room: "",
225
225
  requireApproval: !1
226
- }), j(!1), R());
226
+ }), M(!1), z());
227
227
  },
228
228
  className: "relative z-10 bg-bg-surface rounded-radius-lg p-6 max-w-lg w-full mx-auto mt-20 border border-border-default shadow-lg",
229
229
  children: [
@@ -231,19 +231,19 @@ function k() {
231
231
  className: "flex items-center justify-between mb-6",
232
232
  children: [/* @__PURE__ */ x("h2", {
233
233
  className: "font-heading-md text-text-primary",
234
- children: k("calendar.addResource", "Add Resource")
234
+ children: A("calendar.addResource", "Add Resource")
235
235
  }), /* @__PURE__ */ x("button", {
236
236
  type: "button",
237
- onClick: () => j(!1),
237
+ onClick: () => M(!1),
238
238
  className: "size-8 inline-flex items-center justify-center rounded-radius-sm hover:bg-bg-elevated text-text-tertiary",
239
239
  children: /* @__PURE__ */ x(y, { className: "size-5" })
240
240
  })]
241
241
  }),
242
- H && /* @__PURE__ */ x("div", {
242
+ U && /* @__PURE__ */ x("div", {
243
243
  className: "mb-4 p-3 rounded-radius-md bg-red-50 dark:bg-red-950/20 border border-red-200 dark:border-red-800",
244
244
  children: /* @__PURE__ */ x("p", {
245
245
  className: "font-text-sm text-red-700 dark:text-red-300",
246
- children: H.message
246
+ children: U.message
247
247
  })
248
248
  }),
249
249
  /* @__PURE__ */ S("div", {
@@ -253,7 +253,7 @@ function k() {
253
253
  htmlFor: "resource-name",
254
254
  className: "block font-text-sm font-weight-medium text-text-primary mb-1",
255
255
  children: [
256
- k("calendar.name", "Name"),
256
+ A("calendar.name", "Name"),
257
257
  " ",
258
258
  /* @__PURE__ */ x("span", {
259
259
  className: "text-red-500",
@@ -264,45 +264,45 @@ function k() {
264
264
  id: "resource-name",
265
265
  type: "text",
266
266
  required: !0,
267
- value: G.name,
268
- onChange: (e) => J("name", e.target.value),
269
- placeholder: k("calendar.resourceNameExample", "e.g. Conference Room A"),
267
+ value: K.name,
268
+ onChange: (e) => Y("name", e.target.value),
269
+ placeholder: A("calendar.resourceNameExample", "e.g. Conference Room A"),
270
270
  className: "w-full px-3 py-2 rounded-radius-md border border-border-default bg-bg-surface text-text-primary font-text-sm placeholder:text-text-tertiary focus:outline-none focus:ring-2 focus:ring-action-primary-border",
271
- "aria-label": k("calendar.name", "Name")
271
+ "aria-label": A("calendar.name", "Name")
272
272
  })] }),
273
273
  /* @__PURE__ */ S("div", { children: [/* @__PURE__ */ x("label", {
274
274
  htmlFor: "resource-type",
275
275
  className: "block font-text-sm font-weight-medium text-text-primary mb-1",
276
- children: k("calendar.type", "Type")
277
- }), /* @__PURE__ */ S("select", {
276
+ children: A("calendar.type", "Type")
277
+ }), /* @__PURE__ */ S(O, {
278
278
  id: "resource-type",
279
- value: G.resourceType,
280
- onChange: (e) => J("resourceType", e.target.value),
279
+ value: K.resourceType,
280
+ onChange: (e) => Y("resourceType", e.target.value),
281
281
  className: "w-full px-3 py-2 rounded-radius-md border border-border-default bg-bg-surface text-text-primary font-text-sm focus:outline-none focus:ring-2 focus:ring-action-primary-border scheme-normal dark:scheme-dark [&_option]:bg-bg-surface [&_option]:text-text-primary",
282
282
  children: [
283
283
  /* @__PURE__ */ x("option", {
284
284
  value: "ROOM",
285
- children: k("calendar.room", "Room")
285
+ children: A("calendar.room", "Room")
286
286
  }),
287
287
  /* @__PURE__ */ x("option", {
288
288
  value: "EQUIPMENT",
289
- children: k("calendar.equipment", "Equipment")
289
+ children: A("calendar.equipment", "Equipment")
290
290
  }),
291
291
  /* @__PURE__ */ x("option", {
292
292
  value: "DESK",
293
- children: k("calendar.desk", "Desk")
293
+ children: A("calendar.desk", "Desk")
294
294
  }),
295
295
  /* @__PURE__ */ x("option", {
296
296
  value: "VEHICLE",
297
- children: k("calendar.vehicle", "Vehicle")
297
+ children: A("calendar.vehicle", "Vehicle")
298
298
  }),
299
299
  /* @__PURE__ */ x("option", {
300
300
  value: "PARKING_SPOT",
301
- children: k("calendar.parkingSpot", "Parking Spot")
301
+ children: A("calendar.parkingSpot", "Parking Spot")
302
302
  }),
303
303
  /* @__PURE__ */ x("option", {
304
304
  value: "OTHER",
305
- children: k("calendar.other", "Other")
305
+ children: A("calendar.other", "Other")
306
306
  })
307
307
  ]
308
308
  })] }),
@@ -311,41 +311,41 @@ function k() {
311
311
  children: [/* @__PURE__ */ S("div", { children: [/* @__PURE__ */ x("label", {
312
312
  htmlFor: "resource-capacity",
313
313
  className: "block font-text-sm font-weight-medium text-text-primary mb-1",
314
- children: k("calendar.capacity", "Capacity")
314
+ children: A("calendar.capacity", "Capacity")
315
315
  }), /* @__PURE__ */ x("input", {
316
316
  id: "resource-capacity",
317
317
  type: "number",
318
318
  min: "1",
319
- value: G.capacity,
320
- onChange: (e) => J("capacity", e.target.value),
321
- placeholder: k("calendar.resourceCapacityExample", "e.g. 12"),
319
+ value: K.capacity,
320
+ onChange: (e) => Y("capacity", e.target.value),
321
+ placeholder: A("calendar.resourceCapacityExample", "e.g. 12"),
322
322
  className: "w-full px-3 py-2 rounded-radius-md border border-border-default bg-bg-surface text-text-primary font-text-sm placeholder:text-text-tertiary focus:outline-none focus:ring-2 focus:ring-action-primary-border",
323
- "aria-label": k("calendar.capacity", "Capacity")
323
+ "aria-label": A("calendar.capacity", "Capacity")
324
324
  })] }), /* @__PURE__ */ S("div", { children: [/* @__PURE__ */ x("label", {
325
325
  htmlFor: "resource-location",
326
326
  className: "block font-text-sm font-weight-medium text-text-primary mb-1",
327
- children: k("calendar.location", "Location")
327
+ children: A("calendar.location", "Location")
328
328
  }), /* @__PURE__ */ x("input", {
329
329
  id: "resource-location",
330
330
  type: "text",
331
- value: G.location,
332
- onChange: (e) => J("location", e.target.value),
333
- placeholder: k("calendar.resourceLocationExample", "e.g. Building A"),
334
- "aria-label": k("calendar.location", "Location"),
331
+ value: K.location,
332
+ onChange: (e) => Y("location", e.target.value),
333
+ placeholder: A("calendar.resourceLocationExample", "e.g. Building A"),
334
+ "aria-label": A("calendar.location", "Location"),
335
335
  className: "w-full px-3 py-2 rounded-radius-md border border-border-default bg-bg-surface text-text-primary font-text-sm placeholder:text-text-tertiary focus:outline-none focus:ring-2 focus:ring-action-primary-border"
336
336
  })] })]
337
337
  }),
338
338
  /* @__PURE__ */ S("div", { children: [/* @__PURE__ */ x("label", {
339
339
  htmlFor: "resource-description",
340
340
  className: "block font-text-sm font-weight-medium text-text-primary mb-1",
341
- children: k("calendar.resourceDescriptionLabel", "Description")
341
+ children: A("calendar.resourceDescriptionLabel", "Description")
342
342
  }), /* @__PURE__ */ x("textarea", {
343
343
  id: "resource-description",
344
- value: G.description,
345
- onChange: (e) => J("description", e.target.value),
346
- placeholder: k("calendar.addDescription", "Add a description"),
344
+ value: K.description,
345
+ onChange: (e) => Y("description", e.target.value),
346
+ placeholder: A("calendar.addDescription", "Add a description"),
347
347
  rows: 2,
348
- "aria-label": k("calendar.resourceDescriptionLabel", "Description"),
348
+ "aria-label": A("calendar.resourceDescriptionLabel", "Description"),
349
349
  className: "w-full px-3 py-2 rounded-radius-md border border-border-default bg-bg-surface text-text-primary font-text-sm placeholder:text-text-tertiary focus:outline-none focus:ring-2 focus:ring-action-primary-border resize-none"
350
350
  })] }),
351
351
  /* @__PURE__ */ S("div", {
@@ -353,14 +353,14 @@ function k() {
353
353
  children: [/* @__PURE__ */ x("input", {
354
354
  id: "resource-approval",
355
355
  type: "checkbox",
356
- checked: G.requireApproval,
357
- onChange: (e) => J("requireApproval", e.target.checked),
356
+ checked: K.requireApproval,
357
+ onChange: (e) => Y("requireApproval", e.target.checked),
358
358
  className: "size-4 rounded border-border-default",
359
- "aria-label": k("calendar.requireApprovalForBookings", "Require approval for bookings")
359
+ "aria-label": A("calendar.requireApprovalForBookings", "Require approval for bookings")
360
360
  }), /* @__PURE__ */ x("label", {
361
361
  htmlFor: "resource-approval",
362
362
  className: "font-text-sm text-text-primary",
363
- children: k("calendar.requireApprovalForBookings", "Require approval for bookings")
363
+ children: A("calendar.requireApprovalForBookings", "Require approval for bookings")
364
364
  })]
365
365
  })
366
366
  ]
@@ -369,46 +369,46 @@ function k() {
369
369
  className: "mt-6 flex justify-end gap-3",
370
370
  children: [/* @__PURE__ */ x("button", {
371
371
  type: "button",
372
- onClick: () => j(!1),
373
- disabled: V,
372
+ onClick: () => M(!1),
373
+ disabled: H,
374
374
  className: "px-4 py-2 rounded-radius-md border border-border-default bg-bg-surface hover:bg-bg-elevated font-text-sm font-weight-medium text-text-primary transition-colors disabled:opacity-50",
375
- children: k("calendar.cancel", "Cancel")
375
+ children: A("calendar.cancel", "Cancel")
376
376
  }), /* @__PURE__ */ x("button", {
377
377
  type: "submit",
378
- disabled: V || !G.name.trim(),
378
+ disabled: H || !K.name.trim(),
379
379
  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 transition-colors disabled:opacity-50",
380
- children: V ? k("calendar.creating", "Creating...") : k("calendar.createResource", "Create Resource")
380
+ children: H ? A("calendar.creating", "Creating...") : A("calendar.createResource", "Create Resource")
381
381
  })]
382
382
  })
383
383
  ]
384
384
  })]
385
385
  }),
386
386
  /* @__PURE__ */ x(i, {
387
- open: !!M,
388
- title: k("calendar.deleteResource", "Delete Resource"),
389
- message: k("calendar.deleteResourceConfirmation", "Are you sure you want to delete \"{{name}}\"? This will also cancel all future bookings.", { name: M?.name ?? "" }),
390
- confirmLabel: k("calendar.delete", "Delete"),
387
+ open: !!N,
388
+ title: A("calendar.deleteResource", "Delete Resource"),
389
+ message: A("calendar.deleteResourceConfirmation", "Are you sure you want to delete \"{{name}}\"? This will also cancel all future bookings.", { name: N?.name ?? "" }),
390
+ confirmLabel: A("calendar.delete", "Delete"),
391
391
  variant: "danger",
392
- loading: W,
392
+ loading: G,
393
393
  onConfirm: async () => {
394
- if (M && await s({
395
- title: k("calendar.deleteResource", "Delete Resource"),
396
- message: k("calendar.deleteResourceConfirmation", "Are you sure you want to delete \"{{name}}\"? This will also cancel all future bookings.", { name: M.name }),
397
- okButtonTitle: k("calendar.delete", "Delete")
394
+ if (N && await s({
395
+ title: A("calendar.deleteResource", "Delete Resource"),
396
+ message: A("calendar.deleteResourceConfirmation", "Are you sure you want to delete \"{{name}}\"? This will also cancel all future bookings.", { name: N.name }),
397
+ okButtonTitle: A("calendar.delete", "Delete")
398
398
  }) !== !1) try {
399
- await U({ variables: { id: M.id } }), c("success"), N(null), R();
399
+ await W({ variables: { id: N.id } }), c("success"), P(null), z();
400
400
  } catch (e) {
401
401
  throw c("error"), e;
402
402
  }
403
403
  },
404
- onCancel: () => N(null)
404
+ onCancel: () => P(null)
405
405
  })
406
406
  ]
407
407
  }) : /* @__PURE__ */ x(d, {
408
- title: k("calendar.accessDenied", "Access Denied"),
409
- description: k("calendar.noPermissionViewResources", "You don't have permission to view resources.")
408
+ title: A("calendar.accessDenied", "Access Denied"),
409
+ description: A("calendar.noPermissionViewResources", "You don't have permission to view resources.")
410
410
  });
411
411
  }
412
- export { k as ResourcesPage };
412
+ export { A as ResourcesPage };
413
413
 
414
414
  //# sourceMappingURL=ResourcesPage.js.map