@burdenoff/microfe-eventfullymanaged 2026.1123.5 → 2026.1124.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/eventfullymanaged/EventfullyManagedRoutes.js +58 -54
- package/dist/eventfullymanaged/EventfullyManagedRoutes.js.map +1 -1
- package/dist/eventfullymanaged/api/eventApi.js +1 -0
- package/dist/eventfullymanaged/api/eventApi.js.map +1 -1
- package/dist/eventfullymanaged/components/ActionMenu.js +19 -19
- package/dist/eventfullymanaged/components/CampaignAudiencePicker.js +1 -1
- package/dist/eventfullymanaged/components/CampaignAudiencePicker.js.map +1 -1
- package/dist/eventfullymanaged/components/EntityFormShell.js +9 -9
- package/dist/eventfullymanaged/components/EntityTagsField.js +13 -13
- package/dist/eventfullymanaged/components/EntityTagsField.js.map +1 -1
- package/dist/eventfullymanaged/components/ImageUploadField.js +5 -5
- package/dist/eventfullymanaged/components/Pagination.js +7 -7
- package/dist/eventfullymanaged/components/floorPlanEditor/ZonePanels.js +51 -51
- package/dist/eventfullymanaged/components/floorPlanEditor/ZonePanels.js.map +1 -1
- package/dist/eventfullymanaged/pages/certificates/CertificateAccess.d.ts +7 -0
- package/dist/eventfullymanaged/pages/certificates/CertificateAccess.js +29 -0
- package/dist/eventfullymanaged/pages/certificates/CertificateAccess.js.map +1 -0
- package/dist/eventfullymanaged/pages/certificates/CertificateIssuance.d.ts +7 -0
- package/dist/eventfullymanaged/pages/certificates/CertificateIssuance.js +253 -0
- package/dist/eventfullymanaged/pages/certificates/CertificateIssuance.js.map +1 -0
- package/dist/eventfullymanaged/pages/certificates/CertificateTemplates.d.ts +8 -0
- package/dist/eventfullymanaged/pages/certificates/CertificateTemplates.js +260 -0
- package/dist/eventfullymanaged/pages/certificates/CertificateTemplates.js.map +1 -0
- package/dist/eventfullymanaged/pages/certificates/CertificatesPage.d.ts +1 -0
- package/dist/eventfullymanaged/pages/certificates/CertificatesPage.js +121 -0
- package/dist/eventfullymanaged/pages/certificates/CertificatesPage.js.map +1 -0
- package/dist/eventfullymanaged/pages/dashboard/DashboardPage.js +26 -26
- package/dist/eventfullymanaged/pages/events/EventDetailPage.js +150 -148
- package/dist/eventfullymanaged/pages/events/EventDetailPage.js.map +1 -1
- package/dist/eventfullymanaged/pages/events/VirtualSessionPage.js +100 -100
- package/dist/eventfullymanaged/pages/events/VirtualSessionPage.js.map +1 -1
- package/dist/eventfullymanaged/pages/exhibitors/ExhibitorsPage.js +19 -19
- package/dist/eventfullymanaged/pages/exhibitors/ExhibitorsPage.js.map +1 -1
- package/dist/eventfullymanaged/pages/leads/LeadCaptureDialog.js +16 -16
- package/dist/eventfullymanaged/pages/leads/LeadCaptureDialog.js.map +1 -1
- package/dist/eventfullymanaged/pages/modules/AnalyticsPage.js +103 -103
- package/dist/eventfullymanaged/pages/modules/AnalyticsPage.js.map +1 -1
- package/dist/eventfullymanaged/pages/modules/AttendeeProfilePage.js +15 -15
- package/dist/eventfullymanaged/pages/modules/AttendeeRecommendations.js +12 -12
- package/dist/eventfullymanaged/pages/modules/AttendeeRecommendations.js.map +1 -1
- package/dist/eventfullymanaged/pages/modules/CommunicationPage.js +155 -111
- package/dist/eventfullymanaged/pages/modules/CommunicationPage.js.map +1 -1
- package/dist/eventfullymanaged/pages/modules/EventTemplatesSection.js +14 -14
- package/dist/eventfullymanaged/pages/modules/EventTemplatesSection.js.map +1 -1
- package/dist/eventfullymanaged/pages/modules/EventsPage.js +121 -121
- package/dist/eventfullymanaged/pages/modules/EventsPage.js.map +1 -1
- package/dist/eventfullymanaged/pages/modules/IntegrationsPage.js +57 -57
- package/dist/eventfullymanaged/pages/modules/IntegrationsPage.js.map +1 -1
- package/dist/eventfullymanaged/pages/modules/KioskPage.js +241 -241
- package/dist/eventfullymanaged/pages/modules/KioskPage.js.map +1 -1
- package/dist/eventfullymanaged/pages/modules/NetworkingPage.js +120 -120
- package/dist/eventfullymanaged/pages/modules/NetworkingPage.js.map +1 -1
- package/dist/eventfullymanaged/pages/modules/OperationsHubPage.js +17 -17
- package/dist/eventfullymanaged/pages/modules/OperationsHubPage.js.map +1 -1
- package/dist/eventfullymanaged/pages/modules/RegistrationPage.js +61 -61
- package/dist/eventfullymanaged/pages/modules/RegistrationPage.js.map +1 -1
- package/dist/eventfullymanaged/pages/modules/RoadmapPanel.js +23 -23
- package/dist/eventfullymanaged/pages/modules/RoadmapPanel.js.map +1 -1
- package/dist/eventfullymanaged/pages/modules/SponsorDetailsPage.js +17 -17
- package/dist/eventfullymanaged/pages/modules/SponsorDetailsPage.js.map +1 -1
- package/dist/eventfullymanaged/pages/modules/SponsorLeadsPage.js +11 -11
- package/dist/eventfullymanaged/pages/modules/VenueResourcesPage.js +13 -13
- package/dist/eventfullymanaged/pages/modules/WorkflowsPage.js +108 -108
- package/dist/eventfullymanaged/pages/modules/WorkflowsPage.js.map +1 -1
- package/dist/eventfullymanaged/pages/registration/PromoCodeFormPage.js +22 -22
- package/dist/eventfullymanaged/pages/registration/PromoCodeFormPage.js.map +1 -1
- package/dist/eventfullymanaged/pages/registration/RegisterAttendeePage.js +45 -45
- package/dist/eventfullymanaged/pages/speakers/SpeakersPage.js +24 -24
- package/dist/eventfullymanaged/pages/speakers/SpeakersPage.js.map +1 -1
- package/dist/eventfullymanaged/pages/sponsors/SponsorFormPage.js +37 -37
- package/dist/eventfullymanaged/pages/sponsors/SponsorsListPage.js +23 -23
- package/dist/eventfullymanaged/pages/sponsors/SponsorsListPage.js.map +1 -1
- package/dist/eventfullymanaged/pages/venues/FloorPlansPage.js +123 -123
- package/dist/eventfullymanaged/pages/venues/FloorPlansPage.js.map +1 -1
- package/dist/eventfullymanaged/pages/venues/VenueDetailPage.js +37 -37
- package/dist/eventfullymanaged/pages/venues/VenueDetailPage.js.map +1 -1
- package/dist/eventfullymanaged/pages/venues/VenueFormPage.js +25 -25
- package/dist/eventfullymanaged/pages/venues/VenueListPage.js +26 -26
- package/dist/eventfullymanaged/pages/venues/VenueListPage.js.map +1 -1
- package/dist/generated/wspace-operations.d.ts +383 -0
- package/dist/generated/wspace-operations.js +177 -11
- package/dist/generated/wspace-operations.js.map +1 -1
- package/dist/generated/wspace-types.d.ts +29809 -1503
- package/dist/node_modules/@apollo/client/react/hooks/internal/useRenderGuard.js +19 -0
- package/dist/node_modules/@apollo/client/react/hooks/internal/useRenderGuard.js.map +1 -0
- package/dist/node_modules/@apollo/client/react/hooks/useLazyQuery.js +110 -0
- package/dist/node_modules/@apollo/client/react/hooks/useLazyQuery.js.map +1 -0
- package/dist/utils/pageContext.js +5 -0
- package/dist/utils/pageContext.js.map +1 -1
- package/package.json +1 -1
|
@@ -6,18 +6,18 @@ import { ImageUploadField as s } from "../../components/ImageUploadField.js";
|
|
|
6
6
|
import { ResolvedImage as c } from "../../components/ResolvedImage.js";
|
|
7
7
|
import { useEventfullyManaged as l } from "../../context/EventfullyManagedContext.js";
|
|
8
8
|
import { useResolvedImageUrl as u } from "../../hooks/useResolvedImageUrl.js";
|
|
9
|
-
import { asNumber as d, asString as f, extractZones as
|
|
10
|
-
import { describeError as
|
|
11
|
-
import { notify as
|
|
12
|
-
import { useCallback as
|
|
13
|
-
import { useParams as
|
|
14
|
-
import { jsx as
|
|
15
|
-
import {
|
|
16
|
-
import {
|
|
9
|
+
import { asNumber as d, asString as f, extractZones as p, serializeZones as ee, summarizeZones as m, zoneTypeLabel as h } from "../../lib/floorPlanZones.js";
|
|
10
|
+
import { describeError as g, mutationSucceeded as _ } from "../../lib/mutationResult.js";
|
|
11
|
+
import { notify as v } from "../../lib/toast.js";
|
|
12
|
+
import { useCallback as te, useEffect as ne, useMemo as y, useState as b } from "react";
|
|
13
|
+
import { useParams as re } from "react-router";
|
|
14
|
+
import { jsx as x, jsxs as S } from "react/jsx-runtime";
|
|
15
|
+
import { AlertDialog as C, AlertDialogAction as ie, AlertDialogCancel as ae, AlertDialogContent as oe, AlertDialogDescription as se, AlertDialogFooter as ce, AlertDialogHeader as le, AlertDialogTitle as ue, Badge as w, Button as T, GlassCard as E, GradientText as de, IllustratedEmptyState as fe, Input as pe, Skeleton as D } from "@burdenoff/fe-libs/ui";
|
|
16
|
+
import { ArrowLeft as me, LayoutGrid as O, Map as k, PencilRuler as A, Plus as j, SquareStack as he } from "lucide-react";
|
|
17
17
|
// src/eventfullymanaged/pages/venues/FloorPlansPage.tsx
|
|
18
18
|
var M = "/EventfullyManaged/FloorPlans";
|
|
19
19
|
function ge(e, t) {
|
|
20
|
-
let n = [], r =
|
|
20
|
+
let n = [], r = m(t);
|
|
21
21
|
r.zones > 0 && n.push({
|
|
22
22
|
label: "Zones",
|
|
23
23
|
value: r.zones.toLocaleString()
|
|
@@ -42,89 +42,89 @@ function ge(e, t) {
|
|
|
42
42
|
}
|
|
43
43
|
function N({ imageValue: e, editor: t, planName: n, saving: r, onSave: i, onCancel: o }) {
|
|
44
44
|
let { url: s, failed: c, retry: l } = u(e);
|
|
45
|
-
return s ? /* @__PURE__ */
|
|
45
|
+
return s ? /* @__PURE__ */ x(a, {
|
|
46
46
|
editor: t,
|
|
47
47
|
planName: n,
|
|
48
48
|
imageUrl: s,
|
|
49
49
|
saving: r,
|
|
50
50
|
onSave: i,
|
|
51
51
|
onCancel: o
|
|
52
|
-
}) : c ? /* @__PURE__ */
|
|
52
|
+
}) : c ? /* @__PURE__ */ S("div", {
|
|
53
53
|
className: "flex flex-col items-center gap-3 bg-bg-sunken p-6 text-center",
|
|
54
54
|
role: "alert",
|
|
55
|
-
children: [/* @__PURE__ */
|
|
55
|
+
children: [/* @__PURE__ */ x("p", {
|
|
56
56
|
className: "text-sm text-text-secondary",
|
|
57
57
|
children: "The floor plan image could not be loaded for editing."
|
|
58
|
-
}), /* @__PURE__ */
|
|
58
|
+
}), /* @__PURE__ */ S("div", {
|
|
59
59
|
className: "flex items-center gap-2",
|
|
60
|
-
children: [/* @__PURE__ */
|
|
60
|
+
children: [/* @__PURE__ */ x(T, {
|
|
61
61
|
type: "button",
|
|
62
62
|
size: "sm",
|
|
63
63
|
variant: "outline",
|
|
64
64
|
onClick: o,
|
|
65
65
|
children: "Cancel"
|
|
66
|
-
}), /* @__PURE__ */
|
|
66
|
+
}), /* @__PURE__ */ x(T, {
|
|
67
67
|
type: "button",
|
|
68
68
|
size: "sm",
|
|
69
69
|
onClick: l,
|
|
70
70
|
children: "Retry"
|
|
71
71
|
})]
|
|
72
72
|
})]
|
|
73
|
-
}) : /* @__PURE__ */
|
|
73
|
+
}) : /* @__PURE__ */ x("div", {
|
|
74
74
|
className: "flex justify-center bg-bg-sunken p-3",
|
|
75
75
|
"aria-busy": "true",
|
|
76
|
-
children: /* @__PURE__ */
|
|
76
|
+
children: /* @__PURE__ */ x(D, { className: "h-64 w-[min(40rem,80vw)] max-w-full" })
|
|
77
77
|
});
|
|
78
78
|
}
|
|
79
79
|
function _e({ plan: e, zones: t, editing: n, saving: r, onAttachImage: i, onStartEditing: a, onSaveZones: o, onStopEditing: l, editor: u }) {
|
|
80
80
|
let d = t.filter((e) => e.rect);
|
|
81
|
-
return /* @__PURE__ */
|
|
81
|
+
return /* @__PURE__ */ S(E, {
|
|
82
82
|
treatment: "plain",
|
|
83
83
|
className: "overflow-hidden border-border-seam p-0",
|
|
84
84
|
children: [
|
|
85
|
-
/* @__PURE__ */
|
|
85
|
+
/* @__PURE__ */ S("div", {
|
|
86
86
|
className: "flex items-center justify-between gap-2 border-b border-border-seam px-5 py-3",
|
|
87
|
-
children: [/* @__PURE__ */
|
|
87
|
+
children: [/* @__PURE__ */ S("div", {
|
|
88
88
|
className: "flex min-w-0 items-center gap-2 text-text-primary",
|
|
89
|
-
children: [/* @__PURE__ */
|
|
89
|
+
children: [/* @__PURE__ */ x(k, { className: "h-4 w-4 shrink-0 text-action-primary-bg" }), /* @__PURE__ */ x("h2", {
|
|
90
90
|
className: "truncate text-base font-semibold",
|
|
91
91
|
children: e.name
|
|
92
92
|
})]
|
|
93
|
-
}), /* @__PURE__ */
|
|
93
|
+
}), /* @__PURE__ */ S("div", {
|
|
94
94
|
className: "flex shrink-0 items-center gap-2",
|
|
95
|
-
children: [t.length > 0 ? /* @__PURE__ */
|
|
95
|
+
children: [t.length > 0 ? /* @__PURE__ */ S(w, {
|
|
96
96
|
variant: "secondary",
|
|
97
97
|
children: [
|
|
98
98
|
t.length,
|
|
99
99
|
" ",
|
|
100
100
|
t.length === 1 ? "zone" : "zones"
|
|
101
101
|
]
|
|
102
|
-
}) : null, e.imageUrl && !n ? /* @__PURE__ */
|
|
102
|
+
}) : null, e.imageUrl && !n ? /* @__PURE__ */ S(T, {
|
|
103
103
|
type: "button",
|
|
104
104
|
size: "sm",
|
|
105
105
|
variant: "outline",
|
|
106
106
|
onClick: a,
|
|
107
|
-
children: [/* @__PURE__ */
|
|
107
|
+
children: [/* @__PURE__ */ x(A, { className: "h-4 w-4" }), t.length > 0 ? "Edit zones" : "Add zones"]
|
|
108
108
|
}) : null]
|
|
109
109
|
})]
|
|
110
110
|
}),
|
|
111
|
-
e.imageUrl && n ? /* @__PURE__ */
|
|
111
|
+
e.imageUrl && n ? /* @__PURE__ */ x(N, {
|
|
112
112
|
imageValue: e.imageUrl,
|
|
113
113
|
editor: u,
|
|
114
114
|
planName: e.name,
|
|
115
115
|
saving: r,
|
|
116
116
|
onSave: (t) => o(e, t),
|
|
117
117
|
onCancel: l
|
|
118
|
-
}) : e.imageUrl ? /* @__PURE__ */
|
|
118
|
+
}) : e.imageUrl ? /* @__PURE__ */ x("div", {
|
|
119
119
|
className: "flex justify-center bg-bg-sunken p-3",
|
|
120
|
-
children: /* @__PURE__ */
|
|
120
|
+
children: /* @__PURE__ */ S("div", {
|
|
121
121
|
className: "relative inline-block max-w-full",
|
|
122
|
-
children: [/* @__PURE__ */
|
|
122
|
+
children: [/* @__PURE__ */ x(c, {
|
|
123
123
|
value: e.imageUrl,
|
|
124
124
|
alt: `${e.name} floor plan`,
|
|
125
125
|
className: "block h-auto max-h-[32rem] w-auto max-w-full",
|
|
126
|
-
fallback: /* @__PURE__ */
|
|
127
|
-
}), d.map((e) => /* @__PURE__ */
|
|
126
|
+
fallback: /* @__PURE__ */ x(D, { className: "h-64 w-[min(40rem,80vw)] max-w-full" })
|
|
127
|
+
}), d.map((e) => /* @__PURE__ */ S("div", {
|
|
128
128
|
"data-testid": "floor-plan-zone",
|
|
129
129
|
className: "absolute flex flex-col items-center justify-center overflow-hidden rounded-md border border-accent-primary/70 bg-action-primary-bg/15 text-[10px] font-medium leading-tight text-accent-primary",
|
|
130
130
|
style: {
|
|
@@ -135,26 +135,26 @@ function _e({ plan: e, zones: t, editing: n, saving: r, onAttachImage: i, onStar
|
|
|
135
135
|
},
|
|
136
136
|
title: [
|
|
137
137
|
e.label,
|
|
138
|
-
|
|
138
|
+
h(e.type),
|
|
139
139
|
e.capacity === void 0 ? "" : `capacity ${e.capacity}`
|
|
140
140
|
].filter(Boolean).join(" · "),
|
|
141
|
-
children: [/* @__PURE__ */
|
|
141
|
+
children: [/* @__PURE__ */ x("span", {
|
|
142
142
|
className: "max-w-full truncate px-1",
|
|
143
143
|
children: e.label
|
|
144
|
-
}), e.capacity === void 0 ? null : /* @__PURE__ */
|
|
144
|
+
}), e.capacity === void 0 ? null : /* @__PURE__ */ x("span", {
|
|
145
145
|
className: "max-w-full truncate px-1 text-text-muted",
|
|
146
146
|
children: e.capacity
|
|
147
147
|
})]
|
|
148
148
|
}, e.id))]
|
|
149
149
|
})
|
|
150
|
-
}) : /* @__PURE__ */
|
|
150
|
+
}) : /* @__PURE__ */ x("div", {
|
|
151
151
|
className: "p-6",
|
|
152
|
-
children: /* @__PURE__ */
|
|
152
|
+
children: /* @__PURE__ */ S("div", {
|
|
153
153
|
className: "rounded-card border border-dashed border-border-default bg-bg-sunken p-6",
|
|
154
|
-
children: [/* @__PURE__ */
|
|
154
|
+
children: [/* @__PURE__ */ x("p", {
|
|
155
155
|
className: "mb-3 text-center text-sm text-text-secondary",
|
|
156
156
|
children: "No image attached yet. Upload the hall map for this plan, then draw its zones and booths."
|
|
157
|
-
}), /* @__PURE__ */
|
|
157
|
+
}), /* @__PURE__ */ x(s, {
|
|
158
158
|
label: "Upload floor plan image",
|
|
159
159
|
folderPath: M,
|
|
160
160
|
value: null,
|
|
@@ -163,25 +163,25 @@ function _e({ plan: e, zones: t, editing: n, saving: r, onAttachImage: i, onStar
|
|
|
163
163
|
})]
|
|
164
164
|
})
|
|
165
165
|
}),
|
|
166
|
-
t.length > 0 && !n ? /* @__PURE__ */
|
|
166
|
+
t.length > 0 && !n ? /* @__PURE__ */ S("div", {
|
|
167
167
|
className: "border-t border-border-seam px-5 py-4",
|
|
168
|
-
children: [/* @__PURE__ */
|
|
168
|
+
children: [/* @__PURE__ */ S("div", {
|
|
169
169
|
className: "mb-2 flex items-center gap-2 text-sm font-medium text-text-primary",
|
|
170
|
-
children: [/* @__PURE__ */
|
|
171
|
-
}), /* @__PURE__ */
|
|
170
|
+
children: [/* @__PURE__ */ x(O, { className: "h-4 w-4 text-text-muted" }), "Labeled zones"]
|
|
171
|
+
}), /* @__PURE__ */ x("div", {
|
|
172
172
|
className: "flex flex-wrap gap-2",
|
|
173
173
|
children: t.map((e) => {
|
|
174
|
-
let t =
|
|
175
|
-
return /* @__PURE__ */
|
|
174
|
+
let t = h(e.type);
|
|
175
|
+
return /* @__PURE__ */ S(w, {
|
|
176
176
|
variant: "outline",
|
|
177
177
|
className: "gap-1.5",
|
|
178
178
|
children: [
|
|
179
179
|
e.label,
|
|
180
|
-
t ? /* @__PURE__ */
|
|
180
|
+
t ? /* @__PURE__ */ S("span", {
|
|
181
181
|
className: "text-text-muted",
|
|
182
182
|
children: ["· ", t]
|
|
183
183
|
}) : null,
|
|
184
|
-
e.capacity === void 0 ? null : /* @__PURE__ */
|
|
184
|
+
e.capacity === void 0 ? null : /* @__PURE__ */ S("span", {
|
|
185
185
|
className: "text-text-muted",
|
|
186
186
|
children: ["· ", e.capacity]
|
|
187
187
|
})
|
|
@@ -194,25 +194,25 @@ function _e({ plan: e, zones: t, editing: n, saving: r, onAttachImage: i, onStar
|
|
|
194
194
|
});
|
|
195
195
|
}
|
|
196
196
|
function P() {
|
|
197
|
-
let { id: a = "" } =
|
|
198
|
-
if (
|
|
199
|
-
let e = await
|
|
197
|
+
let { id: a = "" } = re(), { navigate: c } = l(), { data: u, loading: d, refetch: f } = r(a), [m, { loading: h }] = e(), [w] = n(), [O] = t(), [k, A] = b(""), [N, P] = b(""), [F, ve] = b(!1), [I, L] = b(null), [R, z] = b(!1), [B, V] = b(null), [ye, H] = b(!1), U = o(), [W, G] = b(null), K = u?.venue, q = y(() => u?.floorPlans?.items ?? [], [u]), J = y(() => q.find((e) => e.id === I) ?? q[0] ?? null, [q, I]), Y = y(() => p(J?.interactiveAreas), [J]), X = y(() => J ? ge(J, Y) : [], [J, Y]), Z = (e) => e.venueId || a, be = async () => {
|
|
198
|
+
if (k.trim() && a) try {
|
|
199
|
+
let e = await m({ variables: { input: {
|
|
200
200
|
venueId: a,
|
|
201
|
-
name:
|
|
201
|
+
name: k.trim(),
|
|
202
202
|
imageUrl: N,
|
|
203
203
|
dimensions: {},
|
|
204
204
|
interactiveAreas: {}
|
|
205
205
|
} } });
|
|
206
|
-
if (!
|
|
207
|
-
|
|
206
|
+
if (!_(e, e.data?.createFloorPlan?.id, "Could not create floor plan")) return;
|
|
207
|
+
A(""), P(""), z(!1);
|
|
208
208
|
let t = e.data?.createFloorPlan?.id;
|
|
209
|
-
t && L(t),
|
|
209
|
+
t && L(t), v.success("Floor plan created"), await f();
|
|
210
210
|
} catch (e) {
|
|
211
|
-
|
|
211
|
+
v.error("Could not create floor plan", g(e));
|
|
212
212
|
}
|
|
213
213
|
}, xe = async (e, t) => {
|
|
214
214
|
try {
|
|
215
|
-
let n = await
|
|
215
|
+
let n = await w({ variables: {
|
|
216
216
|
id: e.id,
|
|
217
217
|
input: {
|
|
218
218
|
venueId: Z(e),
|
|
@@ -222,17 +222,17 @@ function P() {
|
|
|
222
222
|
interactiveAreas: e.interactiveAreas ?? {}
|
|
223
223
|
}
|
|
224
224
|
} });
|
|
225
|
-
if (!
|
|
225
|
+
if (!_(n, n.data?.updateFloorPlan?.id, "Could not attach image")) return;
|
|
226
226
|
await f();
|
|
227
227
|
} catch (e) {
|
|
228
|
-
|
|
228
|
+
v.error("Could not attach image", g(e));
|
|
229
229
|
}
|
|
230
|
-
}, Q =
|
|
230
|
+
}, Q = te(() => {
|
|
231
231
|
V(null);
|
|
232
232
|
}, []), Se = (e, t) => {
|
|
233
233
|
U.reset(t), V(e.id);
|
|
234
234
|
}, $ = B !== null && U.dirty;
|
|
235
|
-
|
|
235
|
+
ne(() => {
|
|
236
236
|
if (!$) return;
|
|
237
237
|
let e = (e) => {
|
|
238
238
|
e.preventDefault();
|
|
@@ -252,85 +252,85 @@ function P() {
|
|
|
252
252
|
}, Ee = async (e, t) => {
|
|
253
253
|
H(!0);
|
|
254
254
|
try {
|
|
255
|
-
let n = await
|
|
255
|
+
let n = await w({ variables: {
|
|
256
256
|
id: e.id,
|
|
257
257
|
input: {
|
|
258
258
|
venueId: Z(e),
|
|
259
259
|
name: e.name,
|
|
260
260
|
imageUrl: e.imageUrl ?? null,
|
|
261
261
|
dimensions: e.dimensions ?? {},
|
|
262
|
-
interactiveAreas:
|
|
262
|
+
interactiveAreas: ee(t, e.interactiveAreas)
|
|
263
263
|
}
|
|
264
264
|
} });
|
|
265
|
-
return
|
|
265
|
+
return _(n, n.data?.updateFloorPlan?.id, "Could not save zones") ? (await f(), Q(), v.success("Zones saved", `${t.length} ${t.length === 1 ? "zone" : "zones"} on ${e.name}`), !0) : !1;
|
|
266
266
|
} catch (e) {
|
|
267
|
-
return
|
|
267
|
+
return v.error("Could not save zones", g(e)), !1;
|
|
268
268
|
} finally {
|
|
269
269
|
H(!1);
|
|
270
270
|
}
|
|
271
271
|
}, De = async (e) => {
|
|
272
272
|
let t;
|
|
273
273
|
try {
|
|
274
|
-
t = await
|
|
274
|
+
t = await O({ variables: { id: e.id } });
|
|
275
275
|
} catch (e) {
|
|
276
|
-
throw
|
|
276
|
+
throw v.error("Could not delete floor plan", g(e)), e;
|
|
277
277
|
}
|
|
278
|
-
if (t.error) throw
|
|
279
|
-
if (!t.data?.deleteFloorPlan) throw
|
|
280
|
-
I === e.id && L(null), B === e.id && Q(),
|
|
278
|
+
if (t.error) throw v.error("Could not delete floor plan", t.error.message), t.error;
|
|
279
|
+
if (!t.data?.deleteFloorPlan) throw v.error("Could not delete floor plan", "The server did not confirm the change."), Error("delete-unconfirmed");
|
|
280
|
+
I === e.id && L(null), B === e.id && Q(), v.success("Floor plan deleted", e.name), await f();
|
|
281
281
|
};
|
|
282
|
-
return /* @__PURE__ */
|
|
282
|
+
return /* @__PURE__ */ S("div", {
|
|
283
283
|
className: "space-y-6 p-6",
|
|
284
284
|
children: [
|
|
285
|
-
/* @__PURE__ */
|
|
285
|
+
/* @__PURE__ */ S("div", {
|
|
286
286
|
className: "flex flex-col gap-4 sm:flex-row sm:items-end sm:justify-between",
|
|
287
|
-
children: [/* @__PURE__ */
|
|
287
|
+
children: [/* @__PURE__ */ S("div", {
|
|
288
288
|
className: "space-y-3",
|
|
289
289
|
children: [
|
|
290
|
-
/* @__PURE__ */
|
|
290
|
+
/* @__PURE__ */ S(T, {
|
|
291
291
|
type: "button",
|
|
292
292
|
variant: "ghost",
|
|
293
293
|
size: "sm",
|
|
294
294
|
onClick: Ce,
|
|
295
|
-
children: [/* @__PURE__ */
|
|
295
|
+
children: [/* @__PURE__ */ x(me, { className: "h-4 w-4" }), "Back to Venue"]
|
|
296
296
|
}),
|
|
297
|
-
/* @__PURE__ */
|
|
297
|
+
/* @__PURE__ */ x(de, {
|
|
298
298
|
as: "h1",
|
|
299
299
|
className: "text-2xl font-bold",
|
|
300
300
|
children: K?.name ? `${K.name} — Floor Plans` : "Floor Plans"
|
|
301
301
|
}),
|
|
302
|
-
/* @__PURE__ */
|
|
302
|
+
/* @__PURE__ */ x("p", {
|
|
303
303
|
className: "text-sm text-text-secondary",
|
|
304
304
|
children: "Map the hall layout, booth positions, stage and entrances so exhibitors and attendees can navigate on the day."
|
|
305
305
|
})
|
|
306
306
|
]
|
|
307
|
-
}), /* @__PURE__ */
|
|
307
|
+
}), /* @__PURE__ */ S(T, {
|
|
308
308
|
type: "button",
|
|
309
309
|
onClick: () => z((e) => !e),
|
|
310
|
-
children: [/* @__PURE__ */
|
|
310
|
+
children: [/* @__PURE__ */ x(j, { className: "h-4 w-4" }), "Add floor plan"]
|
|
311
311
|
})]
|
|
312
312
|
}),
|
|
313
|
-
d ? /* @__PURE__ */
|
|
313
|
+
d ? /* @__PURE__ */ S("div", {
|
|
314
314
|
className: "grid grid-cols-1 gap-6 lg:grid-cols-3",
|
|
315
|
-
children: [/* @__PURE__ */
|
|
316
|
-
}) : q.length === 0 && !R ? /* @__PURE__ */
|
|
315
|
+
children: [/* @__PURE__ */ x(D, { className: "h-96 rounded-card lg:col-span-2" }), /* @__PURE__ */ x(D, { className: "h-96 rounded-card" })]
|
|
316
|
+
}) : q.length === 0 && !R ? /* @__PURE__ */ x(E, {
|
|
317
317
|
treatment: "plain",
|
|
318
318
|
className: "border-border-seam",
|
|
319
|
-
children: /* @__PURE__ */
|
|
319
|
+
children: /* @__PURE__ */ x(fe, {
|
|
320
320
|
illustration: "empty-files",
|
|
321
321
|
title: "No floor plans yet.",
|
|
322
322
|
description: "Add one to start mapping this venue — upload the hall map and label its zones.",
|
|
323
|
-
action: /* @__PURE__ */
|
|
323
|
+
action: /* @__PURE__ */ S(T, {
|
|
324
324
|
type: "button",
|
|
325
325
|
onClick: () => z(!0),
|
|
326
|
-
children: [/* @__PURE__ */
|
|
326
|
+
children: [/* @__PURE__ */ x(j, { className: "h-4 w-4" }), "Add floor plan"]
|
|
327
327
|
})
|
|
328
328
|
})
|
|
329
|
-
}) : /* @__PURE__ */
|
|
329
|
+
}) : /* @__PURE__ */ S("div", {
|
|
330
330
|
className: "grid grid-cols-1 gap-6 lg:grid-cols-3",
|
|
331
|
-
children: [/* @__PURE__ */
|
|
331
|
+
children: [/* @__PURE__ */ x("div", {
|
|
332
332
|
className: "lg:col-span-2",
|
|
333
|
-
children: J ? /* @__PURE__ */
|
|
333
|
+
children: J ? /* @__PURE__ */ x(_e, {
|
|
334
334
|
plan: J,
|
|
335
335
|
zones: Y,
|
|
336
336
|
editing: B === J.id,
|
|
@@ -340,52 +340,52 @@ function P() {
|
|
|
340
340
|
onSaveZones: Ee,
|
|
341
341
|
onStopEditing: Q,
|
|
342
342
|
editor: U
|
|
343
|
-
}) : /* @__PURE__ */
|
|
343
|
+
}) : /* @__PURE__ */ x(E, {
|
|
344
344
|
treatment: "plain",
|
|
345
345
|
className: "flex h-full items-center justify-center border-border-seam p-10",
|
|
346
|
-
children: /* @__PURE__ */
|
|
346
|
+
children: /* @__PURE__ */ x("p", {
|
|
347
347
|
className: "text-sm text-text-secondary",
|
|
348
348
|
children: "Add a floor plan to preview it here."
|
|
349
349
|
})
|
|
350
350
|
})
|
|
351
|
-
}), /* @__PURE__ */
|
|
351
|
+
}), /* @__PURE__ */ S("div", {
|
|
352
352
|
className: "space-y-6",
|
|
353
353
|
children: [
|
|
354
|
-
/* @__PURE__ */
|
|
354
|
+
/* @__PURE__ */ S(E, {
|
|
355
355
|
treatment: "plain",
|
|
356
356
|
className: "border-border-seam p-5",
|
|
357
|
-
children: [/* @__PURE__ */
|
|
357
|
+
children: [/* @__PURE__ */ x("h2", {
|
|
358
358
|
className: "text-sm font-semibold text-text-primary",
|
|
359
359
|
children: "Available Floor Plans"
|
|
360
|
-
}), /* @__PURE__ */
|
|
360
|
+
}), /* @__PURE__ */ x("ul", {
|
|
361
361
|
className: "mt-3 space-y-2",
|
|
362
362
|
role: "list",
|
|
363
|
-
children: q.length === 0 ? /* @__PURE__ */
|
|
363
|
+
children: q.length === 0 ? /* @__PURE__ */ x("li", {
|
|
364
364
|
className: "text-sm text-text-secondary",
|
|
365
365
|
children: "None yet — create one below."
|
|
366
366
|
}) : q.map((e) => {
|
|
367
367
|
let t = J?.id === e.id;
|
|
368
|
-
return /* @__PURE__ */
|
|
368
|
+
return /* @__PURE__ */ x("li", { children: /* @__PURE__ */ S("div", {
|
|
369
369
|
className: `flex items-center gap-3 rounded-card border p-3 transition-colors ${t ? "border-accent-primary bg-action-primary-bg/10" : "border-border-seam hover:border-border-strong"}`,
|
|
370
|
-
children: [/* @__PURE__ */
|
|
370
|
+
children: [/* @__PURE__ */ S("button", {
|
|
371
371
|
type: "button",
|
|
372
372
|
onClick: () => we(e.id),
|
|
373
373
|
className: "flex min-w-0 flex-1 items-center gap-3 text-left focus-visible:outline-none",
|
|
374
374
|
"aria-pressed": t,
|
|
375
|
-
children: [/* @__PURE__ */
|
|
375
|
+
children: [/* @__PURE__ */ x("span", {
|
|
376
376
|
className: `flex h-9 w-9 shrink-0 items-center justify-center rounded-md ${t ? "bg-action-primary-bg text-action-primary-text" : "bg-bg-sunken text-text-secondary"}`,
|
|
377
|
-
children: /* @__PURE__ */
|
|
378
|
-
}), /* @__PURE__ */
|
|
377
|
+
children: /* @__PURE__ */ x(he, { className: "h-4 w-4" })
|
|
378
|
+
}), /* @__PURE__ */ S("span", {
|
|
379
379
|
className: "min-w-0",
|
|
380
|
-
children: [/* @__PURE__ */
|
|
380
|
+
children: [/* @__PURE__ */ x("span", {
|
|
381
381
|
className: "block truncate text-sm font-medium text-text-primary",
|
|
382
382
|
children: e.name
|
|
383
|
-
}), /* @__PURE__ */
|
|
383
|
+
}), /* @__PURE__ */ x("span", {
|
|
384
384
|
className: "block text-xs text-text-muted",
|
|
385
385
|
children: e.imageUrl ? "Map attached" : "No image yet"
|
|
386
386
|
})]
|
|
387
387
|
})]
|
|
388
|
-
}), /* @__PURE__ */
|
|
388
|
+
}), /* @__PURE__ */ x(i, {
|
|
389
389
|
ariaLabel: `Floor plan actions for ${e.name}`,
|
|
390
390
|
entityName: e.name,
|
|
391
391
|
deleteLabel: "Delete floor plan",
|
|
@@ -395,46 +395,46 @@ function P() {
|
|
|
395
395
|
})
|
|
396
396
|
})]
|
|
397
397
|
}),
|
|
398
|
-
J ? /* @__PURE__ */
|
|
398
|
+
J ? /* @__PURE__ */ S(E, {
|
|
399
399
|
treatment: "metric",
|
|
400
400
|
className: "p-5",
|
|
401
|
-
children: [/* @__PURE__ */
|
|
401
|
+
children: [/* @__PURE__ */ x("h2", {
|
|
402
402
|
className: "text-sm font-semibold text-text-primary",
|
|
403
403
|
children: "Plan Details"
|
|
404
|
-
}), X.length > 0 ? /* @__PURE__ */
|
|
404
|
+
}), X.length > 0 ? /* @__PURE__ */ x("dl", {
|
|
405
405
|
className: "mt-3 space-y-2",
|
|
406
|
-
children: X.map((e) => /* @__PURE__ */
|
|
406
|
+
children: X.map((e) => /* @__PURE__ */ S("div", {
|
|
407
407
|
className: "flex items-center justify-between text-sm",
|
|
408
|
-
children: [/* @__PURE__ */
|
|
408
|
+
children: [/* @__PURE__ */ x("dt", {
|
|
409
409
|
className: "text-text-secondary",
|
|
410
410
|
children: e.label
|
|
411
|
-
}), /* @__PURE__ */
|
|
411
|
+
}), /* @__PURE__ */ x("dd", {
|
|
412
412
|
className: "font-semibold tabular-nums text-text-primary",
|
|
413
413
|
children: e.value
|
|
414
414
|
})]
|
|
415
415
|
}, e.label))
|
|
416
|
-
}) : /* @__PURE__ */
|
|
416
|
+
}) : /* @__PURE__ */ x("p", {
|
|
417
417
|
className: "mt-3 text-sm text-text-secondary",
|
|
418
418
|
children: "No zones or dimensions captured for this plan yet."
|
|
419
419
|
})]
|
|
420
420
|
}) : null,
|
|
421
|
-
R || q.length === 0 ? /* @__PURE__ */
|
|
421
|
+
R || q.length === 0 ? /* @__PURE__ */ S(E, {
|
|
422
422
|
treatment: "plain",
|
|
423
423
|
className: "border-border-seam p-5",
|
|
424
|
-
children: [/* @__PURE__ */
|
|
424
|
+
children: [/* @__PURE__ */ x("h2", {
|
|
425
425
|
className: "mb-3 text-sm font-semibold text-text-primary",
|
|
426
426
|
children: "Add a floor plan"
|
|
427
|
-
}), /* @__PURE__ */
|
|
427
|
+
}), /* @__PURE__ */ S("div", {
|
|
428
428
|
className: "space-y-4",
|
|
429
429
|
children: [
|
|
430
|
-
/* @__PURE__ */
|
|
430
|
+
/* @__PURE__ */ x(pe, {
|
|
431
431
|
type: "text",
|
|
432
|
-
value:
|
|
433
|
-
onChange: (e) =>
|
|
432
|
+
value: k,
|
|
433
|
+
onChange: (e) => A(e.target.value),
|
|
434
434
|
placeholder: "Main Hall Layout",
|
|
435
435
|
"aria-label": "Floor plan name"
|
|
436
436
|
}),
|
|
437
|
-
/* @__PURE__ */
|
|
437
|
+
/* @__PURE__ */ x(s, {
|
|
438
438
|
label: "Upload floor plan image",
|
|
439
439
|
folderPath: M,
|
|
440
440
|
value: N || null,
|
|
@@ -442,18 +442,18 @@ function P() {
|
|
|
442
442
|
onUploadingChange: ve,
|
|
443
443
|
hint: "Optional now — you can attach it later from the viewer."
|
|
444
444
|
}),
|
|
445
|
-
/* @__PURE__ */
|
|
445
|
+
/* @__PURE__ */ S("div", {
|
|
446
446
|
className: "flex justify-end gap-2",
|
|
447
|
-
children: [q.length > 0 ? /* @__PURE__ */
|
|
447
|
+
children: [q.length > 0 ? /* @__PURE__ */ x(T, {
|
|
448
448
|
type: "button",
|
|
449
449
|
variant: "ghost",
|
|
450
450
|
onClick: () => z(!1),
|
|
451
451
|
children: "Cancel"
|
|
452
|
-
}) : null, /* @__PURE__ */
|
|
452
|
+
}) : null, /* @__PURE__ */ S(T, {
|
|
453
453
|
type: "button",
|
|
454
454
|
onClick: be,
|
|
455
|
-
disabled:
|
|
456
|
-
children: [/* @__PURE__ */
|
|
455
|
+
disabled: h || !k.trim() || F,
|
|
456
|
+
children: [/* @__PURE__ */ x(j, { className: "h-4 w-4" }), F ? "Uploading image…" : h ? "Creating…" : "Create"]
|
|
457
457
|
})]
|
|
458
458
|
})
|
|
459
459
|
]
|
|
@@ -462,15 +462,15 @@ function P() {
|
|
|
462
462
|
]
|
|
463
463
|
})]
|
|
464
464
|
}),
|
|
465
|
-
/* @__PURE__ */
|
|
465
|
+
/* @__PURE__ */ x(C, {
|
|
466
466
|
open: W !== null,
|
|
467
467
|
onOpenChange: (e) => e ? void 0 : G(null),
|
|
468
|
-
children: /* @__PURE__ */
|
|
468
|
+
children: /* @__PURE__ */ S(oe, { children: [/* @__PURE__ */ S(le, { children: [/* @__PURE__ */ x(ue, { children: "Discard unsaved zone changes?" }), /* @__PURE__ */ S(se, { children: [
|
|
469
469
|
"The zones you edited on this floor plan have not been saved.",
|
|
470
470
|
" ",
|
|
471
471
|
W?.kind === "venue" ? "Leaving this page" : "Switching plans",
|
|
472
472
|
" will discard them."
|
|
473
|
-
] })] }), /* @__PURE__ */
|
|
473
|
+
] })] }), /* @__PURE__ */ S(ce, { children: [/* @__PURE__ */ x(ae, { children: "Keep editing" }), /* @__PURE__ */ x(ie, {
|
|
474
474
|
onClick: Te,
|
|
475
475
|
children: "Discard changes"
|
|
476
476
|
})] })] })
|