@seatlayer/core 0.1.0
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/index.cjs +2418 -0
- package/dist/index.cjs.map +1 -0
- package/dist/index.d.cts +826 -0
- package/dist/index.d.ts +826 -0
- package/dist/index.js +2377 -0
- package/dist/index.js.map +1 -0
- package/package.json +30 -0
package/dist/index.d.ts
ADDED
|
@@ -0,0 +1,826 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* SeatMap chart document — the single source of truth shared by the
|
|
3
|
+
* Designer (authoring) and the Renderer (buyer picker).
|
|
4
|
+
*
|
|
5
|
+
* Mirrors docs/seatmap-build-spec.md §5. Coordinates are abstract units
|
|
6
|
+
* (roughly "pixels at scale 1"); the renderer fits the chart to its container.
|
|
7
|
+
* Rows are PARAMETRIC (origin + count + spacing + curve + rotation) — never
|
|
8
|
+
* store per-seat coordinates in the document; expansion happens in layout.ts.
|
|
9
|
+
*/
|
|
10
|
+
interface Point {
|
|
11
|
+
x: number;
|
|
12
|
+
y: number;
|
|
13
|
+
}
|
|
14
|
+
interface Category {
|
|
15
|
+
key: string;
|
|
16
|
+
label: string;
|
|
17
|
+
color: string;
|
|
18
|
+
/** Demo-only convenience; real pricing comes from ticket tiers server-side. */
|
|
19
|
+
price?: number;
|
|
20
|
+
}
|
|
21
|
+
/**
|
|
22
|
+
* Accessibility accommodations a seat can carry. Mirrors the taxonomy real
|
|
23
|
+
* venues (and seats.io) expose so buyers can filter for exactly what they need
|
|
24
|
+
* and organizers can mark seats precisely. `wheelchair` is the legacy default.
|
|
25
|
+
*/
|
|
26
|
+
type AccessibilityType = 'wheelchair' | 'companion' | 'semi-ambulatory' | 'hearing' | 'sign-language' | 'plus-size' | 'lift-armrest';
|
|
27
|
+
interface AccessibilityMeta {
|
|
28
|
+
key: AccessibilityType;
|
|
29
|
+
/** Full descriptive label (designer checkbox, picker legend). */
|
|
30
|
+
label: string;
|
|
31
|
+
/** Compact label for chips/badges. */
|
|
32
|
+
short: string;
|
|
33
|
+
/** Single-glyph badge shown on seat chips + filter chips. */
|
|
34
|
+
icon: string;
|
|
35
|
+
}
|
|
36
|
+
/** Ordered taxonomy — drives the designer seat panel and the picker filters. */
|
|
37
|
+
declare const ACCESSIBILITY_TYPES: AccessibilityMeta[];
|
|
38
|
+
/** Metadata for one accessibility key (undefined for unknown keys). */
|
|
39
|
+
declare function accessibilityMeta(key: AccessibilityType): AccessibilityMeta | undefined;
|
|
40
|
+
interface SeatOverride {
|
|
41
|
+
/** 0-based seat index within the row. */
|
|
42
|
+
index: number;
|
|
43
|
+
/** Physical seat absent (pillar, sound desk) — numbering gap preserved. */
|
|
44
|
+
skip?: boolean;
|
|
45
|
+
/** Position nudge in chart units. */
|
|
46
|
+
dx?: number;
|
|
47
|
+
dy?: number;
|
|
48
|
+
/** Replace the computed label entirely. */
|
|
49
|
+
label?: string;
|
|
50
|
+
categoryKey?: string;
|
|
51
|
+
/** @deprecated legacy flag — read as `['wheelchair']`; write `accessibility`. */
|
|
52
|
+
accessible?: boolean;
|
|
53
|
+
/** Accessibility accommodations of this seat (empty/absent = none). */
|
|
54
|
+
accessibility?: AccessibilityType[];
|
|
55
|
+
}
|
|
56
|
+
/** Brand/venue theming — applied by the renderer in both designer and picker. */
|
|
57
|
+
interface ChartTheme {
|
|
58
|
+
/** Canvas background color (default dark: #0e1117-ish radial). */
|
|
59
|
+
background?: string;
|
|
60
|
+
/** Seat label text color (default dark ink #0b1220). */
|
|
61
|
+
seatLabelColor?: string;
|
|
62
|
+
/** Selection ring / accent color (default white ring + brand accent). */
|
|
63
|
+
selectionColor?: string;
|
|
64
|
+
/** Décor (stage/shape) default fill. */
|
|
65
|
+
decorFill?: string;
|
|
66
|
+
/** Free-text color default. */
|
|
67
|
+
textColor?: string;
|
|
68
|
+
/** Font family (CSS stack) for all rendered text — seat labels, sections, décor text. */
|
|
69
|
+
fontFamily?: string;
|
|
70
|
+
/** Seat size multiplier on the base radius (0.7–1.6, default 1) — bigger seats fit longer labels. */
|
|
71
|
+
seatScale?: number;
|
|
72
|
+
/** Brand accent color — recolors buttons, links, the hold pill, selection UI. */
|
|
73
|
+
accent?: string;
|
|
74
|
+
/** Ink color for text on the accent (e.g. button labels). Default light. */
|
|
75
|
+
accentInk?: string;
|
|
76
|
+
/** Organizer logo shown in the picker header (data/R2 URL). Falls back to the name. */
|
|
77
|
+
logoUrl?: string;
|
|
78
|
+
/** Brand/venue name shown in the picker header when no event name is set. */
|
|
79
|
+
brandName?: string;
|
|
80
|
+
/** Paid-tier flag: hide the "Powered by SeatMap" badge. */
|
|
81
|
+
hideBadge?: boolean;
|
|
82
|
+
}
|
|
83
|
+
interface RowObject {
|
|
84
|
+
type: 'row';
|
|
85
|
+
id: string;
|
|
86
|
+
/** Row label, e.g. "A". Seat labels are `${label}-${n}`. */
|
|
87
|
+
label: string;
|
|
88
|
+
/** Position of the FIRST seat. */
|
|
89
|
+
origin: Point;
|
|
90
|
+
/** Degrees, clockwise. 0 = seats laid out along +x. */
|
|
91
|
+
rotation: number;
|
|
92
|
+
/**
|
|
93
|
+
* Total arc sweep in degrees across the whole row. 0 = straight.
|
|
94
|
+
* Positive bends away from +y (concave toward the focal point when the
|
|
95
|
+
* row faces it). Typical theatre rows: 10–40.
|
|
96
|
+
*/
|
|
97
|
+
curve: number;
|
|
98
|
+
seatCount: number;
|
|
99
|
+
/** Distance between adjacent seat centers, in chart units. */
|
|
100
|
+
seatSpacing: number;
|
|
101
|
+
categoryKey: string;
|
|
102
|
+
/** First seat number (default 1). */
|
|
103
|
+
seatLabelStart?: number;
|
|
104
|
+
/** Seat numbering within the row (default ltr, step 1). */
|
|
105
|
+
seatNumbering?: {
|
|
106
|
+
direction: 'ltr' | 'rtl';
|
|
107
|
+
/** 2 = odd/even numbering (1,3,5… — start at 2 for evens). */
|
|
108
|
+
step?: 1 | 2;
|
|
109
|
+
};
|
|
110
|
+
/**
|
|
111
|
+
* Per-seat exceptions, keyed by seat index (0-based position in the row).
|
|
112
|
+
* `skip` removes the physical seat but keeps the numbering gap (theatre
|
|
113
|
+
* convention: a pillar eats A-3; A-4 stays A-4).
|
|
114
|
+
*/
|
|
115
|
+
overrides?: SeatOverride[];
|
|
116
|
+
/**
|
|
117
|
+
* Organizer-supplied equirectangular 360 (or wide photo) shown as the
|
|
118
|
+
* view-from-seat for every seat in this row. When absent, the picker
|
|
119
|
+
* generates a synthetic panorama from chart geometry.
|
|
120
|
+
*/
|
|
121
|
+
viewFromSeatUrl?: string;
|
|
122
|
+
}
|
|
123
|
+
interface GAAreaObject {
|
|
124
|
+
type: 'gaArea';
|
|
125
|
+
id: string;
|
|
126
|
+
label: string;
|
|
127
|
+
/** Closed polygon, in chart units. */
|
|
128
|
+
points: Point[];
|
|
129
|
+
capacity: number;
|
|
130
|
+
categoryKey: string;
|
|
131
|
+
}
|
|
132
|
+
/** Non-bookable décor: stage, walls, exits. */
|
|
133
|
+
interface ShapeObject {
|
|
134
|
+
type: 'shape';
|
|
135
|
+
id: string;
|
|
136
|
+
kind: 'rect' | 'ellipse' | 'polygon';
|
|
137
|
+
label?: string;
|
|
138
|
+
/** For rect/ellipse: bounding box. For a stage polygon: the base (pre-shape) box, so its kind can be regenerated. */
|
|
139
|
+
x?: number;
|
|
140
|
+
y?: number;
|
|
141
|
+
width?: number;
|
|
142
|
+
height?: number;
|
|
143
|
+
/** For polygon. */
|
|
144
|
+
points?: Point[];
|
|
145
|
+
fill?: string;
|
|
146
|
+
/** Degrees clockwise about the shape's center (default 0). Applied at render time. */
|
|
147
|
+
rotation?: number;
|
|
148
|
+
/**
|
|
149
|
+
* Semantic tag driving special rendering. `'stage'` gets the gradient +
|
|
150
|
+
* prominent uppercase label treatment; a décor landmark role (bar, exit…)
|
|
151
|
+
* gets a quieter label. Loose string to avoid a circular import with
|
|
152
|
+
* stage.ts / decor.ts (see StageKind / DecorRole there).
|
|
153
|
+
*/
|
|
154
|
+
role?: string;
|
|
155
|
+
/** For a stage: which `StageKind` its polygon was generated from. */
|
|
156
|
+
stageKind?: string;
|
|
157
|
+
}
|
|
158
|
+
/** Seats arranged around a table; bookable per-seat or as a whole. */
|
|
159
|
+
interface TableObject {
|
|
160
|
+
type: 'table';
|
|
161
|
+
id: string;
|
|
162
|
+
/** e.g. "T1" — seat labels are `${label}-${n}`. */
|
|
163
|
+
label: string;
|
|
164
|
+
center: Point;
|
|
165
|
+
shape: 'round' | 'rect';
|
|
166
|
+
/** Seats around the perimeter (round) or along the enabled edges (rect). */
|
|
167
|
+
seatCount: number;
|
|
168
|
+
/** Rect tables: which edges get seats (default ['top','bottom']). */
|
|
169
|
+
sides?: Array<'top' | 'bottom' | 'left' | 'right'>;
|
|
170
|
+
rotation: number;
|
|
171
|
+
/** Round tables. */
|
|
172
|
+
radius?: number;
|
|
173
|
+
/** Rect tables. */
|
|
174
|
+
width?: number;
|
|
175
|
+
height?: number;
|
|
176
|
+
categoryKey: string;
|
|
177
|
+
/** Whole-table booking: buyers get all seats or none (per-event override later). */
|
|
178
|
+
bookAsWhole?: boolean;
|
|
179
|
+
}
|
|
180
|
+
/** A booth: one bookable unit rendered as a block (trade shows, VIP boxes). */
|
|
181
|
+
interface BoothObject {
|
|
182
|
+
type: 'booth';
|
|
183
|
+
id: string;
|
|
184
|
+
label: string;
|
|
185
|
+
center: Point;
|
|
186
|
+
width: number;
|
|
187
|
+
height: number;
|
|
188
|
+
rotation: number;
|
|
189
|
+
categoryKey: string;
|
|
190
|
+
}
|
|
191
|
+
/**
|
|
192
|
+
* A named region of the venue (Balcony Left, Floor B…). Sections are outlines
|
|
193
|
+
* only — objects belong to a section spatially (center inside the outline),
|
|
194
|
+
* keeping the document flat (no nesting; simpler for tools and for AI edits).
|
|
195
|
+
* Renderer: far zoom shows section shapes/labels instead of seats; clicking
|
|
196
|
+
* a section zooms into it.
|
|
197
|
+
*/
|
|
198
|
+
interface SectionObject {
|
|
199
|
+
type: 'section';
|
|
200
|
+
id: string;
|
|
201
|
+
label: string;
|
|
202
|
+
/** Closed polygon, chart units. */
|
|
203
|
+
outline: Point[];
|
|
204
|
+
/** Optional tint override (defaults to a neutral fill / dominant category mix). */
|
|
205
|
+
color?: string;
|
|
206
|
+
/** Zone this section belongs to (id into `ChartDoc.zones`). Far-zoom nav + pricing group. */
|
|
207
|
+
zone?: string;
|
|
208
|
+
/**
|
|
209
|
+
* Tier height. 0 = floor (default). Higher values lift the section in the
|
|
210
|
+
* picker's isometric ("3D") view, drawn on extruded side faces. Same field a
|
|
211
|
+
* future multi-floor mode reuses — authored in 2D, never drawn by the user.
|
|
212
|
+
*/
|
|
213
|
+
elevation?: number;
|
|
214
|
+
/** Uniform scale about the outline centroid (1 = as drawn). Scales members too. */
|
|
215
|
+
scale?: number;
|
|
216
|
+
/** 0–1: how strongly member-row curves are bent toward a common arc fitted to the outline. */
|
|
217
|
+
smoothing?: number;
|
|
218
|
+
/** Degrees clockwise about the outline centroid (default 0). Rotates members too. */
|
|
219
|
+
rotation?: number;
|
|
220
|
+
}
|
|
221
|
+
/**
|
|
222
|
+
* A group of sections (Lower Bowl, Upper Bowl, Floor…). One concept, three jobs:
|
|
223
|
+
* the farthest-zoom navigation unit, a pricing group, and (Batch 3) a timed-
|
|
224
|
+
* release unit. Kept as a flat list on the doc; sections point back by `zone` id.
|
|
225
|
+
*/
|
|
226
|
+
interface ZoneDef {
|
|
227
|
+
id: string;
|
|
228
|
+
label: string;
|
|
229
|
+
color?: string;
|
|
230
|
+
}
|
|
231
|
+
/**
|
|
232
|
+
* Selection layer — a hit-test/dim filter in the designer, NOT z-order management.
|
|
233
|
+
* Fixed set of four; derived from object type via `layerOf()` (no per-object field yet).
|
|
234
|
+
*/
|
|
235
|
+
type SelectionLayer = 'interactive' | 'background' | 'foreground' | 'surroundings';
|
|
236
|
+
/** Derive an object's selection layer from its type (design contract, HANDOFF §03). */
|
|
237
|
+
declare function layerOf(obj: ChartObject): SelectionLayer;
|
|
238
|
+
/** Free-standing text on the chart (aisle names, door labels…). */
|
|
239
|
+
interface TextObject {
|
|
240
|
+
type: 'text';
|
|
241
|
+
id: string;
|
|
242
|
+
text: string;
|
|
243
|
+
position: Point;
|
|
244
|
+
fontSize: number;
|
|
245
|
+
rotation: number;
|
|
246
|
+
color?: string;
|
|
247
|
+
}
|
|
248
|
+
type ChartObject = RowObject | GAAreaObject | ShapeObject | TableObject | BoothObject | TextObject | SectionObject;
|
|
249
|
+
interface ChartDoc {
|
|
250
|
+
version: 1;
|
|
251
|
+
name: string;
|
|
252
|
+
venueType: 'SIMPLE' | 'MIXED';
|
|
253
|
+
/** The stage / point every seat looks at. Anchors seat-view + sightlines. */
|
|
254
|
+
focalPoint: Point;
|
|
255
|
+
categories: Category[];
|
|
256
|
+
/** Section groupings for far-zoom navigation + pricing (optional; sections reference by id). */
|
|
257
|
+
zones?: ZoneDef[];
|
|
258
|
+
objects: ChartObject[];
|
|
259
|
+
/** Floor-plan photo the organizer traces over (designer-only aid, also rendered dimly in picker if kept). */
|
|
260
|
+
backgroundImage?: {
|
|
261
|
+
url: string;
|
|
262
|
+
center: Point;
|
|
263
|
+
/** Rendered width in chart units (height follows the image aspect). */
|
|
264
|
+
width: number;
|
|
265
|
+
opacity: number;
|
|
266
|
+
locked?: boolean;
|
|
267
|
+
};
|
|
268
|
+
/** Brand/venue theming (colors); categories carry their own colors separately. */
|
|
269
|
+
theme?: ChartTheme;
|
|
270
|
+
}
|
|
271
|
+
interface ExpandedSeat {
|
|
272
|
+
/** Stable id: `${rowId}:${index}` */
|
|
273
|
+
id: string;
|
|
274
|
+
/** Public label: `${rowLabel}-${seatNumber}` */
|
|
275
|
+
label: string;
|
|
276
|
+
x: number;
|
|
277
|
+
y: number;
|
|
278
|
+
rowId: string;
|
|
279
|
+
categoryKey: string;
|
|
280
|
+
/** 'booth' units render as blocks (dimensions looked up via rowId = booth id). */
|
|
281
|
+
kind?: 'seat' | 'booth';
|
|
282
|
+
/** True when the seat has any accessibility accommodation — renderer rings/dims these. */
|
|
283
|
+
accessible?: boolean;
|
|
284
|
+
/** Specific accessibility accommodations (absent = none) — picker badges/filters these. */
|
|
285
|
+
accessibility?: AccessibilityType[];
|
|
286
|
+
/** Organizer-supplied view-from-seat image (inherited from the row). */
|
|
287
|
+
viewUrl?: string;
|
|
288
|
+
}
|
|
289
|
+
type SeatStatus = 'free' | 'held' | 'booked' | 'not_for_sale';
|
|
290
|
+
interface RendererCallbacks {
|
|
291
|
+
onSelect?: (seat: ExpandedSeat) => void;
|
|
292
|
+
onDeselect?: (seat: ExpandedSeat) => void;
|
|
293
|
+
/** seat is null when the pointer leaves any seat. */
|
|
294
|
+
onHover?: (seat: ExpandedSeat | null) => void;
|
|
295
|
+
/** Keyboard focus moved to a seat (arrow-key navigation) — for screen-reader announcements. */
|
|
296
|
+
onFocusSeat?: (seat: ExpandedSeat | null) => void;
|
|
297
|
+
/** Called ~1×/sec with the measured frames-per-second. */
|
|
298
|
+
onFps?: (fps: number) => void;
|
|
299
|
+
/** Fired when a GA area is clicked (quantity picking is UI-side). */
|
|
300
|
+
onGAClick?: (areaId: string) => void;
|
|
301
|
+
/** Fired after any pan/zoom/resize settles — re-anchor screen-space overlays. */
|
|
302
|
+
onViewChange?: () => void;
|
|
303
|
+
}
|
|
304
|
+
interface RendererOptions extends RendererCallbacks {
|
|
305
|
+
/** Max seats selectable at once (default 10). */
|
|
306
|
+
maxSelection?: number;
|
|
307
|
+
/** Only these statuses are clickable (default ['free']). */
|
|
308
|
+
selectableStatuses?: SeatStatus[];
|
|
309
|
+
/**
|
|
310
|
+
* Opt-in host behaviour flag — the renderer's own click/selection logic is
|
|
311
|
+
* unchanged (it still selects + fires `onSelect` immediately, so the seat
|
|
312
|
+
* highlights right away). When true, the host (e.g. PublicEventPage) treats
|
|
313
|
+
* that `onSelect` as a pending candidate and shows a confirm card instead of
|
|
314
|
+
* pushing straight into the cart; `deselect([seat.id])` on Cancel un-highlights.
|
|
315
|
+
*/
|
|
316
|
+
confirmSelection?: boolean;
|
|
317
|
+
}
|
|
318
|
+
interface ISeatmapRenderer {
|
|
319
|
+
/** Replace the chart. Resets selection and statuses, zooms to fit. */
|
|
320
|
+
setChart(doc: ChartDoc): void;
|
|
321
|
+
/** Bulk status update; re-renders affected seats only. */
|
|
322
|
+
setStatus(seatIds: string[], status: SeatStatus): void;
|
|
323
|
+
getStatus(seatId: string): SeatStatus;
|
|
324
|
+
getSelection(): ExpandedSeat[];
|
|
325
|
+
clearSelection(): void;
|
|
326
|
+
/** Programmatic deselect of specific seats (e.g. chip × in the cart). */
|
|
327
|
+
deselect(seatIds: string[]): void;
|
|
328
|
+
/**
|
|
329
|
+
* Brief attention pulse on a seat (a ring that expands + fades once) — used to
|
|
330
|
+
* signal live activity, e.g. a seat "just taken" by another buyer via a WS
|
|
331
|
+
* delta. Purely visual; no state change. `color` overrides the default.
|
|
332
|
+
*/
|
|
333
|
+
flashSeat(seatId: string, color?: string): void;
|
|
334
|
+
zoomToFit(): void;
|
|
335
|
+
/** Zoom in one step about the viewport center, clamped to the usual zoom bounds. */
|
|
336
|
+
zoomIn(): void;
|
|
337
|
+
/** Zoom out one step about the viewport center, clamped to the usual zoom bounds. */
|
|
338
|
+
zoomOut(): void;
|
|
339
|
+
/** Total seat count of the current chart. */
|
|
340
|
+
seatCount(): number;
|
|
341
|
+
/**
|
|
342
|
+
* Maps a chart-space point (or a seat, by its x/y) to container-relative
|
|
343
|
+
* screen pixels, using the current stage scale/position. Lets host UI anchor
|
|
344
|
+
* DOM overlays (confirm card, tooltip) over a live seat and re-anchor them
|
|
345
|
+
* on `onViewChange`.
|
|
346
|
+
*/
|
|
347
|
+
worldToScreen(point: Point): {
|
|
348
|
+
x: number;
|
|
349
|
+
y: number;
|
|
350
|
+
};
|
|
351
|
+
/** When on, dim non-accessible free seats so accessible seats stand out. */
|
|
352
|
+
setAccessibleFilter(on: boolean): void;
|
|
353
|
+
/**
|
|
354
|
+
* Dim free seats that lack ANY of these accessibility types. `null` clears the
|
|
355
|
+
* filter; `[]` means "any accessible seat" (same as setAccessibleFilter(true)).
|
|
356
|
+
*/
|
|
357
|
+
setAccessibilityFilter(types: AccessibilityType[] | null): void;
|
|
358
|
+
/** Legend hover-highlight: dim free seats of other categories (null clears). */
|
|
359
|
+
setCategoryHighlight?(key: string | null): void;
|
|
360
|
+
/**
|
|
361
|
+
* Switch the projection. `'flat'` = normal top-down; `'isometric'` = the "3D"
|
|
362
|
+
* view (affine skew/rotate + elevation lift), hit-testing preserved in screen
|
|
363
|
+
* space. Purely visual — the chart is authored flat. Animated unless reduced-motion.
|
|
364
|
+
*/
|
|
365
|
+
setViewMode?(mode: 'flat' | 'isometric'): void;
|
|
366
|
+
/**
|
|
367
|
+
* Section id whose outline contains a container-relative screen point (or null).
|
|
368
|
+
* Feeds the far-zoom "tap a section to zoom in" flow (Slice 5).
|
|
369
|
+
*/
|
|
370
|
+
sectionAt?(clientPoint: Point): string | null;
|
|
371
|
+
/** Seat ids belonging to a section — for the section-summary card (Slice 5). */
|
|
372
|
+
sectionMembers?(id: string): string[];
|
|
373
|
+
destroy(): void;
|
|
374
|
+
}
|
|
375
|
+
/** localStorage key the Designer writes and the Picker reads. */
|
|
376
|
+
declare const CHART_STORAGE_KEY = "seatmap.chart";
|
|
377
|
+
|
|
378
|
+
/**
|
|
379
|
+
* Pure geometry helpers — no Konva, no DOM. Turns the parametric chart
|
|
380
|
+
* document into concrete seat coordinates and computes bounding boxes.
|
|
381
|
+
*/
|
|
382
|
+
|
|
383
|
+
/**
|
|
384
|
+
* Every seat slot of a row INCLUDING skipped ones (designer seat-edit mode uses
|
|
385
|
+
* this to draw un-skip handles). Overrides (dx/dy/label/categoryKey) are applied
|
|
386
|
+
* but a skipped slot is flagged, not omitted.
|
|
387
|
+
*/
|
|
388
|
+
interface RowSeatSlot {
|
|
389
|
+
index: number;
|
|
390
|
+
x: number;
|
|
391
|
+
y: number;
|
|
392
|
+
label: string;
|
|
393
|
+
categoryKey: string;
|
|
394
|
+
skipped: boolean;
|
|
395
|
+
accessible: boolean;
|
|
396
|
+
accessibility: AccessibilityType[];
|
|
397
|
+
}
|
|
398
|
+
declare function expandRowSlots(row: RowObject): RowSeatSlot[];
|
|
399
|
+
declare function expandRow(row: RowObject): ExpandedSeat[];
|
|
400
|
+
/**
|
|
401
|
+
* Expand a table into its perimeter seats.
|
|
402
|
+
*
|
|
403
|
+
* Round: seats spread evenly on a circle of radius `radius + 16`, the first at
|
|
404
|
+
* angle `rotation` (degrees, clockwise from +x). Rect: seats line the top and
|
|
405
|
+
* bottom edges (split evenly, any remainder to the top), 16u outside the edge,
|
|
406
|
+
* the whole set rotated about the table centre.
|
|
407
|
+
*/
|
|
408
|
+
declare function expandTable(t: TableObject): ExpandedSeat[];
|
|
409
|
+
/** Expand a booth into its single bookable block unit. */
|
|
410
|
+
declare function expandBooth(b: BoothObject): ExpandedSeat[];
|
|
411
|
+
/** Ray-cast point-in-polygon test — odd crossings ⇒ inside. */
|
|
412
|
+
declare function pointInPolygon(p: Point, poly: Point[]): boolean;
|
|
413
|
+
/**
|
|
414
|
+
* Visual centre of any object — used for spatial section membership and for
|
|
415
|
+
* rotating an object about its centre. Rows: centroid of expanded seats (or
|
|
416
|
+
* origin when empty); tables/booths: centre; GA/section: polygon centroid;
|
|
417
|
+
* shape: bbox centre; text: its position.
|
|
418
|
+
*/
|
|
419
|
+
declare function objectCenter(o: ChartObject): Point;
|
|
420
|
+
/** Expand every seat-bearing object (rows, tables, booths). */
|
|
421
|
+
declare function expandChart(doc: ChartDoc): ExpandedSeat[];
|
|
422
|
+
/** Axis-aligned bounds over every object plus the background image, with padding. */
|
|
423
|
+
declare function chartBounds(doc: ChartDoc): {
|
|
424
|
+
x: number;
|
|
425
|
+
y: number;
|
|
426
|
+
width: number;
|
|
427
|
+
height: number;
|
|
428
|
+
};
|
|
429
|
+
|
|
430
|
+
/**
|
|
431
|
+
* SeatmapRenderer — the shared canvas rendering core (buyer picker shell).
|
|
432
|
+
*
|
|
433
|
+
* Uses Konva directly with per-module imports to keep the bundle lean. The
|
|
434
|
+
* whole point of the spike is staying smooth at ~5,000 seats on mobile, so the
|
|
435
|
+
* hot paths lean on: layer bitmap caching + listening(false) when zoomed out,
|
|
436
|
+
* per-seat fill updates (never full rebuilds) on status change, and viewport-
|
|
437
|
+
* only label rendering rebuilt on interaction-end rather than per frame.
|
|
438
|
+
*/
|
|
439
|
+
|
|
440
|
+
declare class SeatmapRenderer implements ISeatmapRenderer {
|
|
441
|
+
private container;
|
|
442
|
+
private opts;
|
|
443
|
+
private stage;
|
|
444
|
+
private bgLayer;
|
|
445
|
+
private seatLayer;
|
|
446
|
+
private overlayLayer;
|
|
447
|
+
private labelGroup;
|
|
448
|
+
private seats;
|
|
449
|
+
private seatById;
|
|
450
|
+
/** Interactive node per seat/booth — a Circle for seats, a Rect for booths. */
|
|
451
|
+
private circleById;
|
|
452
|
+
/** Booth block geometry, keyed by booth id (= the unit's rowId). */
|
|
453
|
+
private boothDims;
|
|
454
|
+
private statusById;
|
|
455
|
+
private catColor;
|
|
456
|
+
private theme;
|
|
457
|
+
private selection;
|
|
458
|
+
private selectionRings;
|
|
459
|
+
private hoverRing;
|
|
460
|
+
/** Keyboard-navigation focus ring + the currently focused seat id. */
|
|
461
|
+
private focusRing;
|
|
462
|
+
private focusedId;
|
|
463
|
+
/**
|
|
464
|
+
* Accessibility filter: `null` = off; `[]` = dim all non-accessible free seats;
|
|
465
|
+
* a type list = dim free seats lacking any of those accommodations.
|
|
466
|
+
*/
|
|
467
|
+
private accessFilter;
|
|
468
|
+
/** Category highlight (legend hover): dims free seats NOT of this category. */
|
|
469
|
+
private categoryHighlight;
|
|
470
|
+
private sections;
|
|
471
|
+
private zones;
|
|
472
|
+
private seatSection;
|
|
473
|
+
private catPrice;
|
|
474
|
+
/** Zone id → colour (drives extruded side faces in iso view). */
|
|
475
|
+
private zoneColor;
|
|
476
|
+
private hasSections;
|
|
477
|
+
/** seatLayer carries Text (booth labels) — gate the upright-label scan. */
|
|
478
|
+
private hasBoothText;
|
|
479
|
+
/** 0 = flat (default), 1 = full isometric; animated by setViewMode. */
|
|
480
|
+
private isoT;
|
|
481
|
+
private isoTarget;
|
|
482
|
+
private isoRaf;
|
|
483
|
+
/** Chart centre the iso projection pivots about (bounds centre). */
|
|
484
|
+
private isoCentre;
|
|
485
|
+
/** Set in destroy() so an in-flight iso tween bails. */
|
|
486
|
+
private destroyed;
|
|
487
|
+
/** Cached scale the section/zone labels were last sized for (scale-compensation). */
|
|
488
|
+
private lodScale;
|
|
489
|
+
/** prefers-reduced-motion → hard-swap rungs instead of cross-fading. */
|
|
490
|
+
private reducedMotion;
|
|
491
|
+
private fitScale;
|
|
492
|
+
/** Effective seat radius (base × theme.seatScale), set per chart in setChart. */
|
|
493
|
+
private seatR;
|
|
494
|
+
private bounds;
|
|
495
|
+
private cached;
|
|
496
|
+
private dpr;
|
|
497
|
+
private rafId;
|
|
498
|
+
private frames;
|
|
499
|
+
private lastFpsAt;
|
|
500
|
+
private recacheTimer;
|
|
501
|
+
private resizeObs;
|
|
502
|
+
/** Coalesces bursty view-change sources (pointermove, wheel) into ≤1 callback/frame. */
|
|
503
|
+
private viewChangeRaf;
|
|
504
|
+
private pointers;
|
|
505
|
+
private pinch;
|
|
506
|
+
private panLast;
|
|
507
|
+
/** Cumulative gesture movement in px — clicks are suppressed after a real pan/pinch. */
|
|
508
|
+
private moved;
|
|
509
|
+
constructor(container: HTMLDivElement, options?: RendererOptions);
|
|
510
|
+
setChart(doc: ChartDoc): void;
|
|
511
|
+
setStatus(seatIds: string[], status: SeatStatus): void;
|
|
512
|
+
getStatus(seatId: string): SeatStatus;
|
|
513
|
+
getSelection(): ExpandedSeat[];
|
|
514
|
+
clearSelection(): void;
|
|
515
|
+
deselect(seatIds: string[]): void;
|
|
516
|
+
flashSeat(seatId: string, color?: string): void;
|
|
517
|
+
private onKeyDown;
|
|
518
|
+
/** Nearest seat from `fromId` in a cardinal direction (aligned + close wins). */
|
|
519
|
+
private nearestSeat;
|
|
520
|
+
private focusSeat;
|
|
521
|
+
/** Pan/zoom so a seat sits on-screen at a legible scale (for keyboard focus). */
|
|
522
|
+
private ensureVisible;
|
|
523
|
+
zoomToFit(): void;
|
|
524
|
+
/** Step factor for the on-screen +/− buttons (B1) — same clamp path as pinch/wheel. */
|
|
525
|
+
private static readonly ZOOM_STEP;
|
|
526
|
+
zoomIn(): void;
|
|
527
|
+
zoomOut(): void;
|
|
528
|
+
seatCount(): number;
|
|
529
|
+
worldToScreen(point: Point): {
|
|
530
|
+
x: number;
|
|
531
|
+
y: number;
|
|
532
|
+
};
|
|
533
|
+
setAccessibleFilter(on: boolean): void;
|
|
534
|
+
setAccessibilityFilter(types: AccessibilityType[] | null): void;
|
|
535
|
+
private sameAccessFilter;
|
|
536
|
+
/**
|
|
537
|
+
* Switch the projection between flat top-down and the isometric "3D" view
|
|
538
|
+
* (rotate + y-squash about the chart centre, plus per-elevation lift). Tweens
|
|
539
|
+
* `isoT` 0⇄1 over ~0.32s (ease in-out); reduced-motion snaps. Purely visual —
|
|
540
|
+
* geometry stays flat, so hit-testing (Konva's own, plus the manual section
|
|
541
|
+
* inverse) keeps landing on the projected seats/sections.
|
|
542
|
+
*/
|
|
543
|
+
setViewMode(mode: 'flat' | 'isometric'): void;
|
|
544
|
+
/** Iso angle (rad) + y-squash for the current isoT. */
|
|
545
|
+
private isoParams;
|
|
546
|
+
/** Effective vertical scale = stage scale × iso squash — legibility math uses this. */
|
|
547
|
+
private effScale;
|
|
548
|
+
/** Project a world point through the iso affine about the chart centre (→ iso-world). */
|
|
549
|
+
private isoForward;
|
|
550
|
+
/** Inverse of isoForward (iso-world → world) for screen-space hit-testing. */
|
|
551
|
+
private isoInverse;
|
|
552
|
+
/**
|
|
553
|
+
* Local-space offset that, once the layer applies the iso affine, lifts an
|
|
554
|
+
* object straight UP in iso-world by `elevation × LIFT_PER_STEP × isoT`
|
|
555
|
+
* (= inverse-linear of the pure vertical lift). Zero at isoT=0.
|
|
556
|
+
*/
|
|
557
|
+
private isoLiftLocal;
|
|
558
|
+
/** Restore the three layers to identity (flat) — byte-for-byte the original. */
|
|
559
|
+
private resetLayerTransforms;
|
|
560
|
+
/**
|
|
561
|
+
* Apply the current isoT to the scene: the base rotate+squash as a decomposed
|
|
562
|
+
* layer transform (so seats/décor/rings project together and Konva's own
|
|
563
|
+
* hit-testing follows), upright counter-transforms on text, and the elevation
|
|
564
|
+
* lift + extruded side faces on elevated sections.
|
|
565
|
+
*/
|
|
566
|
+
private applyIso;
|
|
567
|
+
/** Counter-skew every visible label so it renders upright at its projected anchor. */
|
|
568
|
+
private applyUprightLabels;
|
|
569
|
+
/** Lift elevated sections (+ their members) and update their extruded side faces. */
|
|
570
|
+
private applyElevation;
|
|
571
|
+
destroy(): void;
|
|
572
|
+
/** Theme font stack for all rendered text (falls back to Inter). */
|
|
573
|
+
private labelFont;
|
|
574
|
+
/**
|
|
575
|
+
* Where a seat's nodes live: an elevated section's lift group (so the whole
|
|
576
|
+
* tier shifts with one offset in iso view) or the seat layer directly.
|
|
577
|
+
*/
|
|
578
|
+
private seatContainer;
|
|
579
|
+
private renderSeats;
|
|
580
|
+
/** A booth renders as a click-selectable rounded block (dims from the doc). */
|
|
581
|
+
private renderBoothUnit;
|
|
582
|
+
/** Apply fill/stroke/opacity for a seat's current status + selection. */
|
|
583
|
+
private paintSeat;
|
|
584
|
+
/** Legend hover: highlight one category (dim the rest), or null to clear. */
|
|
585
|
+
setCategoryHighlight(key: string | null): void;
|
|
586
|
+
private renderBackground;
|
|
587
|
+
/** Organizer floor-plan photo, dimmed, at the very bottom of the bg layer. */
|
|
588
|
+
private renderBackgroundImage;
|
|
589
|
+
private renderTable;
|
|
590
|
+
private renderText;
|
|
591
|
+
private renderShape;
|
|
592
|
+
/** Prominent stage caption: uppercase, letter-spaced, larger, softly dimmed. */
|
|
593
|
+
private addStageLabel;
|
|
594
|
+
private renderGA;
|
|
595
|
+
/**
|
|
596
|
+
* A section renders in three coordinated layers driven by the LOD melt:
|
|
597
|
+
* • a faint outline (the existing near-zoom look, untouched),
|
|
598
|
+
* • a solid category-mix block that fades in at the block rung, and
|
|
599
|
+
* • a name + "N LEFT" sublabel.
|
|
600
|
+
* Membership (which seats live inside the outline) + the mix fill + the live
|
|
601
|
+
* availability count are precomputed here (once), not per frame.
|
|
602
|
+
*/
|
|
603
|
+
private renderSection;
|
|
604
|
+
/** Recompute a section's availability-tinted fill + "N LEFT" (cheap; on status change). */
|
|
605
|
+
private refreshSectionFill;
|
|
606
|
+
/**
|
|
607
|
+
* Zone rung: one giant screen-constant label per zone (+ optional "FROM $n"),
|
|
608
|
+
* shown at the farthest zoom in place of per-section detail. Skipped entirely
|
|
609
|
+
* when the doc declares no zones — sections then stay the far rung (graceful).
|
|
610
|
+
*/
|
|
611
|
+
private renderZones;
|
|
612
|
+
/**
|
|
613
|
+
* THE MELT — a continuous, scale-driven cross-fade across the three rungs:
|
|
614
|
+
* seats ⇄ section blocks ⇄ zone blocks.
|
|
615
|
+
* `blockT` ramps 0→1 as scale falls through [SECTION_PROMINENT, CACHE_THRESHOLD]
|
|
616
|
+
* so the solid fill is fully present exactly as seats become the cached bitmap
|
|
617
|
+
* and fade out; `zoneT` ramps 0→1 across [ZONE_PROMINENT, SECTION_PROMINENT] so
|
|
618
|
+
* per-section detail hands off to giant zone labels. Reduced-motion hard-swaps.
|
|
619
|
+
* Section/zone labels are scale-compensated to hold a roughly constant screen size.
|
|
620
|
+
*/
|
|
621
|
+
private applySectionLod;
|
|
622
|
+
/** Set a centred label's world fontSize (for a target screen px) and re-anchor it. */
|
|
623
|
+
private sizeLabel;
|
|
624
|
+
/**
|
|
625
|
+
* Map a container-relative screen point back to world coords. Inverts the
|
|
626
|
+
* stage (scale/pos) and, in iso view, the iso affine — so screen-space taps
|
|
627
|
+
* test against the flat world outlines/geometry. Identity-equivalent at isoT=0.
|
|
628
|
+
*/
|
|
629
|
+
private screenToWorld;
|
|
630
|
+
/** Section id under a container-relative screen point, or null (Slice 5 tap-to-zoom). */
|
|
631
|
+
sectionAt(clientPoint: {
|
|
632
|
+
x: number;
|
|
633
|
+
y: number;
|
|
634
|
+
}): string | null;
|
|
635
|
+
/** Seat ids belonging to a section (Slice 5 section-summary card). */
|
|
636
|
+
sectionMembers(id: string): string[];
|
|
637
|
+
private addCentredLabel;
|
|
638
|
+
private isSelectable;
|
|
639
|
+
private toggleSeat;
|
|
640
|
+
private setSelected;
|
|
641
|
+
private wireInteraction;
|
|
642
|
+
private toLocal;
|
|
643
|
+
private onPointerDown;
|
|
644
|
+
private onPointerMove;
|
|
645
|
+
private onPointerEnd;
|
|
646
|
+
/**
|
|
647
|
+
* Min is chart-relative (never lose the room); max is absolute so seats
|
|
648
|
+
* reach a readable size on any chart, however large the venue.
|
|
649
|
+
*/
|
|
650
|
+
private zoomBounds;
|
|
651
|
+
/** Zoom so `clientPoint` (stage-relative px) stays fixed under the cursor. */
|
|
652
|
+
private zoomAbout;
|
|
653
|
+
/** Zoom + pan so world-rect `b` fills the viewport (with a small margin). */
|
|
654
|
+
private zoomToBounds;
|
|
655
|
+
/** Recompute LOD (cache/labels) after any pan/zoom settles. */
|
|
656
|
+
private afterViewChange;
|
|
657
|
+
/** rAF-coalesced `onViewChange` — at most one host callback per animation frame. */
|
|
658
|
+
private scheduleViewChange;
|
|
659
|
+
private updateLOD;
|
|
660
|
+
private cacheSeatLayer;
|
|
661
|
+
private updateLabels;
|
|
662
|
+
private handleResize;
|
|
663
|
+
private startFpsLoop;
|
|
664
|
+
}
|
|
665
|
+
declare function createRenderer(container: HTMLDivElement, opts?: RendererOptions): ISeatmapRenderer;
|
|
666
|
+
|
|
667
|
+
interface PickerSeat {
|
|
668
|
+
id: string;
|
|
669
|
+
label: string;
|
|
670
|
+
categoryKey: string;
|
|
671
|
+
price: number;
|
|
672
|
+
}
|
|
673
|
+
interface HoldConflict {
|
|
674
|
+
label: string;
|
|
675
|
+
reason: string;
|
|
676
|
+
}
|
|
677
|
+
/** An open hold — its id, the labels it covers, and the server's expiry time (ms epoch). */
|
|
678
|
+
interface HoldInfo {
|
|
679
|
+
holdId: string;
|
|
680
|
+
labels: string[];
|
|
681
|
+
expiresAt: number;
|
|
682
|
+
}
|
|
683
|
+
interface HoldResponse {
|
|
684
|
+
holdId: string;
|
|
685
|
+
expiresAt: number;
|
|
686
|
+
}
|
|
687
|
+
interface BestAvailableResponse extends HoldResponse {
|
|
688
|
+
labels: string[];
|
|
689
|
+
}
|
|
690
|
+
/** Swappable public-surface transport (SDK PubApi or a dashboard `api.pub.*` adapter). */
|
|
691
|
+
interface PickerTransport {
|
|
692
|
+
chart(key: string): Promise<{
|
|
693
|
+
doc: ChartDoc;
|
|
694
|
+
event: {
|
|
695
|
+
key: string;
|
|
696
|
+
name: string;
|
|
697
|
+
salesClosed?: boolean;
|
|
698
|
+
venue?: string | null;
|
|
699
|
+
startsAt?: number | null;
|
|
700
|
+
};
|
|
701
|
+
}>;
|
|
702
|
+
objects(key: string): Promise<{
|
|
703
|
+
seats: Record<string, string>;
|
|
704
|
+
}>;
|
|
705
|
+
hold(key: string, labels: string[]): Promise<HoldResponse>;
|
|
706
|
+
bestAvailable(key: string, qty: number, categoryKey?: string): Promise<BestAvailableResponse>;
|
|
707
|
+
release(key: string, labels: string[], holdId: string): Promise<unknown>;
|
|
708
|
+
/** Optional — the SDK omits booking (it hands the holdId to the host page). */
|
|
709
|
+
book?(key: string, labels: string[], holdId: string, bookingRef: string): Promise<unknown>;
|
|
710
|
+
socketUrl(key: string): string;
|
|
711
|
+
}
|
|
712
|
+
interface PickerCallbacks extends RendererCallbacks {
|
|
713
|
+
/** Selection changed (manual clicks or a server best-available pick). */
|
|
714
|
+
onSelectionChange?: (seats: PickerSeat[]) => void;
|
|
715
|
+
/** A hold opened (manual hold or best-available). */
|
|
716
|
+
onHold?: (hold: HoldInfo) => void;
|
|
717
|
+
/** The open hold expired server-side (the controller has already released it). */
|
|
718
|
+
onHoldExpired?: () => void;
|
|
719
|
+
/** A booking completed with this ref. */
|
|
720
|
+
onBook?: (bookingRef: string) => void;
|
|
721
|
+
/** Any live seat-status change arrived (delta or snapshot) — e.g. to recount "N left". */
|
|
722
|
+
onStatusChange?: () => void;
|
|
723
|
+
/** The server declared the event closed (a 409 event_closed). */
|
|
724
|
+
onSalesClosed?: () => void;
|
|
725
|
+
onError?: (err: unknown) => void;
|
|
726
|
+
}
|
|
727
|
+
interface PickerOptions extends PickerCallbacks {
|
|
728
|
+
transport: PickerTransport;
|
|
729
|
+
eventKey: string;
|
|
730
|
+
maxSelection?: number;
|
|
731
|
+
/** Renderer confirm-card mode (host shows a confirm popover instead of instant cart add). */
|
|
732
|
+
confirmSelection?: boolean;
|
|
733
|
+
/** Flash a pulse when a seat we didn't touch goes free→taken (live-activity cue). */
|
|
734
|
+
flashOnLiveChange?: boolean;
|
|
735
|
+
}
|
|
736
|
+
declare class PickerController {
|
|
737
|
+
private readonly opts;
|
|
738
|
+
private readonly api;
|
|
739
|
+
private readonly key;
|
|
740
|
+
private readonly maxSelection;
|
|
741
|
+
private renderer;
|
|
742
|
+
private _doc;
|
|
743
|
+
/** label ⇄ id maps — backend speaks labels, the engine speaks ids. */
|
|
744
|
+
private labelToId;
|
|
745
|
+
private labelToSeat;
|
|
746
|
+
private allIds;
|
|
747
|
+
private ws;
|
|
748
|
+
private reconnectTimer;
|
|
749
|
+
private attempt;
|
|
750
|
+
private closed;
|
|
751
|
+
private hold_;
|
|
752
|
+
private expiryTimer;
|
|
753
|
+
constructor(options: PickerOptions);
|
|
754
|
+
get doc(): ChartDoc | null;
|
|
755
|
+
currentHold(): HoldInfo | null;
|
|
756
|
+
getRenderer(): ISeatmapRenderer | null;
|
|
757
|
+
seatByLabel(label: string): ExpandedSeat | undefined;
|
|
758
|
+
idForLabel(label: string): string | undefined;
|
|
759
|
+
/** Fetch chart, build label maps, mount the renderer, seed statuses, go live. */
|
|
760
|
+
render(host: HTMLDivElement): Promise<{
|
|
761
|
+
doc: ChartDoc;
|
|
762
|
+
salesClosed: boolean;
|
|
763
|
+
eventName: string;
|
|
764
|
+
venue?: string | null;
|
|
765
|
+
startsAt?: number | null;
|
|
766
|
+
} | null>;
|
|
767
|
+
getSelection(): PickerSeat[];
|
|
768
|
+
clearSelection(): void;
|
|
769
|
+
deselect(ids: string[]): void;
|
|
770
|
+
/**
|
|
771
|
+
* Hold the current selection (or a given label set). The controller does the
|
|
772
|
+
* renderer/hold side (409 → deselect + repaint the taken seats held) and then
|
|
773
|
+
* re-throws so the caller can choose the banner copy. Returns null only when
|
|
774
|
+
* there's nothing to hold.
|
|
775
|
+
*/
|
|
776
|
+
hold(labelsArg?: string[]): Promise<HoldInfo | null>;
|
|
777
|
+
/** Server-picks `qty` best free seats and holds them atomically. Throws on failure. */
|
|
778
|
+
bestAvailable(qty: number, categoryKey?: string): Promise<HoldInfo | null>;
|
|
779
|
+
/**
|
|
780
|
+
* Complete a booking. Requires a transport that supports book() (the SDK
|
|
781
|
+
* deliberately does not). `bookingRef` MUST be a real reference from the caller.
|
|
782
|
+
* `labelsArg` lets the caller book its own cart (the live page's confirm-flow
|
|
783
|
+
* cart can hold best-available seats that aren't in the renderer selection);
|
|
784
|
+
* defaults to the renderer selection. Reuses an existing exact-match hold, else
|
|
785
|
+
* holds first. Returns the labels booked, or null on failure (conflicts painted).
|
|
786
|
+
*/
|
|
787
|
+
book(bookingRef: string, labelsArg?: string[]): Promise<string[] | null>;
|
|
788
|
+
/** Release the whole open hold (if any), repaint those seats free. */
|
|
789
|
+
release(): Promise<void>;
|
|
790
|
+
/**
|
|
791
|
+
* Release just some labels from the open hold, keeping the rest held (used when
|
|
792
|
+
* a buyer removes one seat chip). Clears the hold entirely once it empties.
|
|
793
|
+
*/
|
|
794
|
+
releaseLabels(labels: string[]): Promise<void>;
|
|
795
|
+
setStatus(ids: string[], status: SeatStatus): void;
|
|
796
|
+
getStatus(id: string): SeatStatus | undefined;
|
|
797
|
+
flashSeat(id: string, color?: string): void;
|
|
798
|
+
zoomIn(): void;
|
|
799
|
+
zoomOut(): void;
|
|
800
|
+
zoomToFit(): void;
|
|
801
|
+
worldToScreen(p: {
|
|
802
|
+
x: number;
|
|
803
|
+
y: number;
|
|
804
|
+
}): {
|
|
805
|
+
x: number;
|
|
806
|
+
y: number;
|
|
807
|
+
};
|
|
808
|
+
setAccessibilityFilter(types: string[] | null): void;
|
|
809
|
+
destroy(): void;
|
|
810
|
+
private toSeat;
|
|
811
|
+
private priceFor;
|
|
812
|
+
private emitSelectionChange;
|
|
813
|
+
private emitError;
|
|
814
|
+
private holdCovers;
|
|
815
|
+
private handle409Conflicts;
|
|
816
|
+
/** Set the open hold + (re)arm the server-authoritative expiry timer. */
|
|
817
|
+
private setHold;
|
|
818
|
+
private clearHold;
|
|
819
|
+
private onHoldExpired;
|
|
820
|
+
private applySeatsMap;
|
|
821
|
+
private resnapshot;
|
|
822
|
+
private connect;
|
|
823
|
+
private scheduleReconnect;
|
|
824
|
+
}
|
|
825
|
+
|
|
826
|
+
export { ACCESSIBILITY_TYPES, type AccessibilityMeta, type AccessibilityType, type BoothObject, CHART_STORAGE_KEY, type Category, type ChartDoc, type ChartObject, type ChartTheme, type ExpandedSeat, type GAAreaObject, type HoldConflict, type HoldInfo, type ISeatmapRenderer, type PickerCallbacks, PickerController, type PickerOptions, type PickerSeat, type PickerTransport, type Point, type RendererCallbacks, type RendererOptions, type RowObject, type RowSeatSlot, type SeatOverride, type SeatStatus, SeatmapRenderer, type SectionObject, type SelectionLayer, type ShapeObject, type TableObject, type TextObject, type ZoneDef, accessibilityMeta, chartBounds, createRenderer, expandBooth, expandChart, expandRow, expandRowSlots, expandTable, layerOf, objectCenter, pointInPolygon };
|