@seatlayer/core 0.53.0 → 0.55.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/README.md +2 -2
- package/dist/categoryInventory-BwarniiK.d.ts +109 -0
- package/dist/categoryInventory-D3qPwfKz.d.cts +109 -0
- package/dist/chunk-55NOSZK5.js +1 -0
- package/dist/chunk-6VTTBC5F.js +1 -0
- package/dist/chunk-6XJN4REG.js +1 -0
- package/dist/chunk-7PT7OQUO.js +1 -0
- package/dist/chunk-AQKYUJBX.js +1 -0
- package/dist/chunk-CXF32VPG.js +1 -0
- package/dist/chunk-DNGP2HDT.js +1 -0
- package/dist/chunk-EQM4FFN5.js +1 -0
- package/dist/chunk-HHM3PB66.js +1 -0
- package/dist/chunk-PXWKSYCK.js +1 -0
- package/dist/chunk-VDZ24QVV.js +1 -0
- package/dist/chunk-VI2CLV3Y.js +1 -0
- package/dist/core/chart-ops/index.cjs +1 -0
- package/dist/core/chart-ops/index.d.cts +1235 -0
- package/dist/core/chart-ops/index.d.ts +1235 -0
- package/dist/core/chart-ops/index.js +1 -0
- package/dist/core/color.cjs +1 -0
- package/dist/core/color.d.cts +192 -0
- package/dist/core/color.d.ts +192 -0
- package/dist/core/color.js +1 -0
- package/dist/core/inventory/index.cjs +1 -0
- package/dist/core/inventory/index.d.cts +209 -0
- package/dist/core/inventory/index.d.ts +209 -0
- package/dist/core/inventory/index.js +1 -0
- package/dist/core/layout/index.cjs +1 -0
- package/dist/core/layout/index.d.cts +376 -0
- package/dist/core/layout/index.d.ts +376 -0
- package/dist/core/layout/index.js +1 -0
- package/dist/core/quality/index.cjs +1 -0
- package/dist/core/quality/index.d.cts +132 -0
- package/dist/core/quality/index.d.ts +132 -0
- package/dist/core/quality/index.js +1 -0
- package/dist/core/render-assets/index.cjs +1 -0
- package/dist/core/render-assets/index.d.cts +99 -0
- package/dist/core/render-assets/index.d.ts +99 -0
- package/dist/core/render-assets/index.js +1 -0
- package/dist/core/seatConfidence.cjs +1 -1
- package/dist/core/seatConfidence.d.cts +1 -1
- package/dist/core/seatConfidence.d.ts +1 -1
- package/dist/core/seatConfidence.js +1 -1
- package/dist/core/sections/index.cjs +1 -0
- package/dist/core/sections/index.d.cts +346 -0
- package/dist/core/sections/index.d.ts +346 -0
- package/dist/core/sections/index.js +1 -0
- package/dist/{de-75NWRKC5.js → de-WPX4D3SY.js} +1 -1
- package/dist/{es-BM7EJ7PW.js → es-6KAJQVVX.js} +1 -1
- package/dist/{fr-HPXQHIB4.js → fr-5DTMRBN5.js} +1 -1
- package/dist/index.cjs +1 -1
- package/dist/index.d.cts +85 -534
- package/dist/index.d.ts +85 -534
- package/dist/index.js +1 -1
- package/dist/labeling-BmCzW50y.d.ts +90 -0
- package/dist/labeling-VfJBEOn0.d.cts +90 -0
- package/dist/layout-ClQkmixY.d.ts +181 -0
- package/dist/layout-Dlv5bIf2.d.cts +181 -0
- package/dist/renderedQuality-B3jgdgPO.d.ts +113 -0
- package/dist/renderedQuality-bDkUOyBL.d.cts +113 -0
- package/dist/renderer-B_g-W_QB.d.ts +534 -0
- package/dist/renderer-DySMcKAR.d.cts +534 -0
- package/dist/sections-DIzgtDjF.d.ts +123 -0
- package/dist/sections-Dna1nZgR.d.cts +123 -0
- package/dist/segmentedRowModel-BNXEUeHp.d.cts +75 -0
- package/dist/segmentedRowModel-COXw4GCh.d.ts +75 -0
- package/dist/ticketRestrictions-CzchbX_o.d.cts +72 -0
- package/dist/ticketRestrictions-DaYOCpEw.d.ts +72 -0
- package/dist/{types-tLOunI-B.d.cts → types-DTSG6_Hq.d.cts} +238 -761
- package/dist/{types-tLOunI-B.d.ts → types-DTSG6_Hq.d.ts} +238 -761
- package/dist/view3d/crossfade/panorama.d.cts +1 -1
- package/dist/view3d/crossfade/panorama.d.ts +1 -1
- package/dist/view3d/index.cjs +27 -27
- package/dist/view3d/index.d.cts +109 -2
- package/dist/view3d/index.d.ts +109 -2
- package/dist/view3d/index.js +26 -26
- package/package.json +94 -5
- package/dist/chunk-54A7LIL5.js +0 -1
package/dist/index.d.ts
CHANGED
|
@@ -1,463 +1,13 @@
|
|
|
1
|
-
import {
|
|
2
|
-
export {
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
* 1. **At draft time** — given the author's nodes, exactly which components,
|
|
12
|
-
* seat counts and pitches will be committed? (`segmentedRowComponents`)
|
|
13
|
-
* 2. **At read time** — given stored physical rows, what is the logical row they
|
|
14
|
-
* form, and where does each component sit inside its numbering?
|
|
15
|
-
* (`resolveSegmentedRowGroups`)
|
|
16
|
-
*
|
|
17
|
-
* These lived apart — (1) in `rowDraft.ts` next to the ghost preview, (2) in
|
|
18
|
-
* `layout.ts` next to buyer expansion — which is precisely how the canvas came
|
|
19
|
-
* to number a segmented row `1-7` / `1-6` while buyers correctly saw
|
|
20
|
-
* `A-1…A-13`. They are two halves of one rule, so they live in one module.
|
|
21
|
-
*
|
|
22
|
-
* The standing rule this module exists to enforce: **the ghost preview and the
|
|
23
|
-
* commit share one resolver.** A preview that can lie is a bug.
|
|
24
|
-
*/
|
|
25
|
-
|
|
26
|
-
/** Resolved logical placement of one physical component inside a segmented row. */
|
|
27
|
-
interface SegmentedRowPlacement {
|
|
28
|
-
groupId: string;
|
|
29
|
-
/** Buyer adjacency index base (a declared aisle break costs one index). */
|
|
30
|
-
adjacencyOffset: number;
|
|
31
|
-
/** Continuous seat-numbering base across the whole logical row. */
|
|
32
|
-
displayOffset: number;
|
|
33
|
-
displayLabel: string;
|
|
34
|
-
totalSeats: number;
|
|
35
|
-
canonical: RowObject;
|
|
36
|
-
viewFromSeatUrl?: string;
|
|
37
|
-
viewFromSeatMeta?: RowObject['viewFromSeatMeta'];
|
|
38
|
-
confidenceEvidence?: RowObject['confidenceEvidence'];
|
|
39
|
-
}
|
|
40
|
-
|
|
41
|
-
/**
|
|
42
|
-
* Pure geometry helpers — no Konva, no DOM. Turns the parametric chart
|
|
43
|
-
* document into concrete seat coordinates and computes bounding boxes.
|
|
44
|
-
*/
|
|
45
|
-
|
|
46
|
-
/**
|
|
47
|
-
* Expand a parametric row into seat positions.
|
|
48
|
-
*
|
|
49
|
-
* Straight (curve === 0): seat i sits at local (i·spacing, 0).
|
|
50
|
-
*
|
|
51
|
-
* Curved: seats lie on a circular arc. Per-seat angular step is
|
|
52
|
-
* `curve/(seatCount-1)`; radius is derived so the chord between neighbours
|
|
53
|
-
* equals seatSpacing → radius = spacing / (2·sin(step/2)). Seat 0 sits at the
|
|
54
|
-
* bottom of the arc (local origin) with the circle centre directly above it at
|
|
55
|
-
* (0,-radius); increasing index sweeps toward +x while the ends rise toward -y,
|
|
56
|
-
* i.e. positive curve is concave toward -y (a row wrapping a stage above it).
|
|
57
|
-
* Local points are then rotated by `rotation` and translated to `origin`.
|
|
58
|
-
*
|
|
59
|
-
* Numbering (labels only, never geometry): `seatNumbering.direction === 'rtl'`
|
|
60
|
-
* numbers from the far physical end; `step === 2` produces odd/even numbering
|
|
61
|
-
* (start at 1 → 1,3,5…; start at 2 → 2,4,6…).
|
|
62
|
-
*/
|
|
63
|
-
/** Base (pre-override) seat centre per index — shared by expandRow + designer edit mode. */
|
|
64
|
-
declare function rowSeatPositions(row: RowObject): Point[];
|
|
65
|
-
/** Sellable row slots: skipped slots are absent; empty wheelchair bays remain. */
|
|
66
|
-
declare function rowInventoryCount(row: RowObject): number;
|
|
67
|
-
/**
|
|
68
|
-
* Every seat slot of a row INCLUDING skipped ones (designer seat-edit mode uses
|
|
69
|
-
* this to draw un-skip handles). Overrides (dx/dy/label/categoryKey) are applied
|
|
70
|
-
* but a skipped slot is flagged, not omitted.
|
|
71
|
-
*/
|
|
72
|
-
interface RowSeatSlot {
|
|
73
|
-
index: number;
|
|
74
|
-
x: number;
|
|
75
|
-
y: number;
|
|
76
|
-
label: string;
|
|
77
|
-
displayLabel: string;
|
|
78
|
-
categoryKey: string;
|
|
79
|
-
skipped: boolean;
|
|
80
|
-
accessible: boolean;
|
|
81
|
-
accessibility: AccessibilityType[];
|
|
82
|
-
wheelchairSpaceType?: SeatOverride['wheelchairSpaceType'];
|
|
83
|
-
commercial?: RowObject['commercial'];
|
|
84
|
-
viewUrl?: string;
|
|
85
|
-
viewMeta?: SeatViewMetadata;
|
|
86
|
-
labelStyle?: LabelStyle;
|
|
87
|
-
}
|
|
88
|
-
/** Every authored table-chair slot, including skipped inventory. This mirrors
|
|
89
|
-
* row seat slots so Designer, MCP and buyer/event expansion share one semantic
|
|
90
|
-
* source while retaining the table's stable numeric slot identity. */
|
|
91
|
-
interface TableSeatSlot extends RowSeatSlot {
|
|
92
|
-
side?: RectTableSide;
|
|
93
|
-
}
|
|
94
|
-
/**
|
|
95
|
-
* Seat slots for one physical row.
|
|
96
|
-
*
|
|
97
|
-
* `placement` makes the slots read as part of a logical segmented row: labels
|
|
98
|
-
* continue across components (`A-8`, not a second `A-1`) using the logical row's
|
|
99
|
-
* numbering scheme and total seat count.
|
|
100
|
-
*/
|
|
101
|
-
declare function expandRowSlots(row: RowObject, placement?: SegmentedRowPlacement): RowSeatSlot[];
|
|
102
|
-
declare function expandRow(row: RowObject): ExpandedSeat[];
|
|
103
|
-
/**
|
|
104
|
-
* Expand a table into its perimeter seats.
|
|
105
|
-
*
|
|
106
|
-
* Round: seats spread evenly on a circle of radius `radius + 16`, the first at
|
|
107
|
-
* angle `rotation` (degrees, clockwise from +x). Rect: seats line the top and
|
|
108
|
-
* bottom edges (split evenly, any remainder to the top), 16u outside the edge,
|
|
109
|
-
* the whole set rotated about the table centre.
|
|
110
|
-
*/
|
|
111
|
-
/** Legacy rect tables distribute aggregate capacity round-robin across enabled
|
|
112
|
-
* sides, then emit chairs in canonical top/bottom/left/right order. */
|
|
113
|
-
declare function tableSeatCountsBySide(t: TableObject): RectTableSeatCounts;
|
|
114
|
-
/** Expand every authored table chair, including skipped slots needed by the
|
|
115
|
-
* Designer to restore inventory. */
|
|
116
|
-
declare function expandTableSlots(t: TableObject): TableSeatSlot[];
|
|
117
|
-
/** Sellable individual table chairs. Grouped tables own one atomic inventory
|
|
118
|
-
* unit elsewhere and therefore retain their full authored chair capacity. */
|
|
119
|
-
declare function tableInventoryCount(t: TableObject): number;
|
|
120
|
-
declare function expandTable(t: TableObject): ExpandedSeat[];
|
|
121
|
-
/** Expand a booth into its single bookable block unit. */
|
|
122
|
-
declare function expandBooth(b: BoothObject): ExpandedSeat[];
|
|
123
|
-
/** Ray-cast point-in-polygon test — odd crossings ⇒ inside. */
|
|
124
|
-
declare function pointInPolygon(p: Point, poly: Point[]): boolean;
|
|
125
|
-
declare function pointInPolygonWithHoles(p: Point, outer: Point[], holes: Point[][] | undefined): boolean;
|
|
126
|
-
/**
|
|
127
|
-
* Stable interior label anchor: the centre of the largest circle that fits in
|
|
128
|
-
* the polygon (holes excluded).
|
|
129
|
-
*
|
|
130
|
-
* This used to return the average-of-vertices centroid whenever that happened
|
|
131
|
-
* to be inside, and only fell back to a coarse 24×24 grid search when it was
|
|
132
|
-
* not. "Inside" is a much weaker property than "has room": on a traced arena
|
|
133
|
-
* the outer arc of a wedge carries dozens of sampled vertices and the radial
|
|
134
|
-
* edges carry two, so the average is dragged onto the arc and the label pill —
|
|
135
|
-
* far wider than a point — straddled the boundary into the next section.
|
|
136
|
-
* Measured on the 36-section traced arena corpus, 15 of 36 anchors had under
|
|
137
|
-
* 75% of the clearance actually available, some as little as 43%.
|
|
138
|
-
*
|
|
139
|
-
* `polygonInscribedAnchor` is deterministic and coordinate-free, so callers may
|
|
140
|
-
* memoize it on geometry alone.
|
|
141
|
-
*/
|
|
142
|
-
declare function polygonLabelPoint(outer: Point[], holes: Point[][] | undefined): Point;
|
|
143
|
-
/**
|
|
144
|
-
* Visual centre of any object — used for spatial section membership and for
|
|
145
|
-
* rotating an object about its centre. Rows: centroid of expanded seats (or
|
|
146
|
-
* origin when empty); tables/booths: centre; GA/section: polygon centroid;
|
|
147
|
-
* shape: bbox centre; text: its position.
|
|
148
|
-
*/
|
|
149
|
-
declare function objectCenter(o: ChartObject): Point;
|
|
150
|
-
/**
|
|
151
|
-
* Resolve one bookable object's owning physical section using the canonical
|
|
152
|
-
* first-match rule. Generated reference inventory may name a logical section,
|
|
153
|
-
* but that provenance is trusted only when the stored geometry confirms it.
|
|
154
|
-
* Keeping this primitive in layout lets section inventory, category painting,
|
|
155
|
-
* and buyer view inheritance share one ownership decision.
|
|
156
|
-
*/
|
|
157
|
-
declare function owningSectionForObject(objects: ChartObject[], object: ChartObject): SectionObject | undefined;
|
|
158
|
-
/**
|
|
159
|
-
* Normalized floor list (Batch 5): a multi-floor chart's `floors`, or a synthetic
|
|
160
|
-
* single floor wrapping a single-floor chart's `objects`. Every consumer that needs
|
|
161
|
-
* to reason about floors goes through this so single-floor charts stay untouched.
|
|
162
|
-
*/
|
|
163
|
-
declare function floorsOf(doc: ChartDoc): Floor[];
|
|
164
|
-
/** Objects of one floor by id (defaults to the first floor). */
|
|
165
|
-
declare function floorObjects(doc: ChartDoc, floorId?: string): ChartObject[];
|
|
166
|
-
/** Every object across ALL floors — the whole venue (single-floor = `doc.objects`). */
|
|
167
|
-
declare function allObjects(doc: ChartDoc): ChartObject[];
|
|
168
|
-
/** A copy of an object translated by (dx, dy) — every coordinate field shifted. */
|
|
169
|
-
declare function translateObject(o: ChartObject, dx: number, dy: number): ChartObject;
|
|
170
|
-
/**
|
|
171
|
-
* Multi-floor 3D stack (Batch 5): flatten every floor into ONE doc with floor `i`
|
|
172
|
-
* lifted by `i * spread` in −y, so the isometric view shows the floors as stacked
|
|
173
|
-
* decks (ground at the bottom). Returns a single-floor doc (no `floors`). Meant
|
|
174
|
-
* only for the 3D overview render — 2D still shows one floor via `floorObjects`.
|
|
175
|
-
*/
|
|
176
|
-
declare function stackFloors(doc: ChartDoc, spread?: number): ChartDoc;
|
|
177
|
-
/**
|
|
178
|
-
* Build the buyer-facing 2D overview of a multi-floor chart.
|
|
179
|
-
*
|
|
180
|
-
* Floors commonly reuse the same drawing origin (a balcony is authored over
|
|
181
|
-
* the stalls it overlooks). Flattening those source coordinates makes a valid
|
|
182
|
-
* import look corrupt because every level is painted on top of every other
|
|
183
|
-
* level. This projection packs complete floors into a compact, content-aware
|
|
184
|
-
* grid. Each floor receives one rigid translation: no seat, row, section,
|
|
185
|
-
* annotation, gap, or rotation changes, and the canonical document is never
|
|
186
|
-
* mutated.
|
|
187
|
-
*/
|
|
188
|
-
declare function layoutFloorOverview(doc: ChartDoc): ChartDoc;
|
|
189
|
-
/**
|
|
190
|
-
* Rigid per-floor translations used by the buyer's complete-venue overview.
|
|
191
|
-
*
|
|
192
|
-
* Kept as a pure public helper so 2D and 3D can present the same non-overlapping
|
|
193
|
-
* level arrangement without either renderer rewriting the authored chart. A
|
|
194
|
-
* zero translation is returned for a single-floor document.
|
|
195
|
-
*/
|
|
196
|
-
declare function floorOverviewTranslations(doc: ChartDoc): Point[];
|
|
197
|
-
interface ExpandChartOptions {
|
|
198
|
-
/** Physical height for a single-floor projection extracted from a multi-floor
|
|
199
|
-
* document. Full multi-floor documents resolve each floor directly. */
|
|
200
|
-
floorBaseHeightM?: number;
|
|
201
|
-
/** Resolve per-seat 3D eye heights (default true). Two-dimensional consumers
|
|
202
|
-
* such as thumbnails can disable this expensive stand-structure pass. */
|
|
203
|
-
resolveEyeHeights?: boolean;
|
|
204
|
-
}
|
|
205
|
-
/** Expand every seat-bearing object across all floors (rows, tables, booths).
|
|
206
|
-
* Multi-floor ownership is resolved one floor at a time: local coordinates may
|
|
207
|
-
* overlap between floors and must never assign a seat to another floor's section. */
|
|
208
|
-
declare function expandChart(doc: ChartDoc, options?: ExpandChartOptions): ExpandedSeat[];
|
|
209
|
-
/** Axis-aligned bounds over every object plus the background image, with padding. */
|
|
210
|
-
declare function chartBounds(doc: ChartDoc): {
|
|
211
|
-
x: number;
|
|
212
|
-
y: number;
|
|
213
|
-
width: number;
|
|
214
|
-
height: number;
|
|
215
|
-
};
|
|
216
|
-
|
|
217
|
-
declare const MAX_GA_CAPACITY = 100000;
|
|
218
|
-
declare const MAX_EVENT_INVENTORY = 100000;
|
|
219
|
-
/** Stable internal inventory label for one unit of a GA area's capacity. */
|
|
220
|
-
declare function gaUnitLabel(areaId: string, index: number): string;
|
|
221
|
-
/** Strict, bounded validation for durable Join Areas inventory provenance. */
|
|
222
|
-
declare function validGAInventorySegments(area: GAAreaObject): boolean;
|
|
223
|
-
/** Canonical source ranges. Invalid explicit provenance intentionally yields no
|
|
224
|
-
* labels: chart validation blocks publication instead of inventing identities. */
|
|
225
|
-
declare function gaInventorySegments(area: GAAreaObject): GAInventorySegment[];
|
|
226
|
-
declare function gaUnitLabels(area: GAAreaObject): string[];
|
|
227
|
-
/** Append-only capacity semantics for an already joined GA surface. */
|
|
228
|
-
declare function growJoinedGAInventory(area: GAAreaObject, nextCapacity: number): GAInventorySegment[] | undefined;
|
|
229
|
-
declare function gaAreasOf(doc: ChartDoc): GAAreaObject[];
|
|
230
|
-
declare function isGaUnitLabel(label: string): boolean;
|
|
231
|
-
|
|
232
|
-
/**
|
|
233
|
-
* Real-world scale primitives — the ONE place the app fixes chart-unit ↔ metre ↔
|
|
234
|
-
* renderer-world scale, and the section 3D-geometry resolver that rides on it.
|
|
235
|
-
*
|
|
236
|
-
* Everything that converts between chart units, metres, and renderer "world"
|
|
237
|
-
* units derives from {@link METRES_PER_CHART_UNIT}. Renderer world units and
|
|
238
|
-
* chart units are 1:1, so metres → world is exactly {@link CHART_UNITS_PER_METRE}
|
|
239
|
-
* (the single m→world conversion constant Phase B consumers use).
|
|
240
|
-
*
|
|
241
|
-
* This is a leaf module (types only) so both `layout.ts` and `sections.ts` can
|
|
242
|
-
* import it without the two forming an import cycle.
|
|
243
|
-
*/
|
|
244
|
-
|
|
245
|
-
/**
|
|
246
|
-
* Metres of front-edge height one elevation tier represents. Chosen (not guessed)
|
|
247
|
-
* so `elevation × TIER_HEIGHT_M` metres, scaled back through
|
|
248
|
-
* {@link CHART_UNITS_PER_METRE}, equals the legacy `elevation × LIFT_PER_STEP`
|
|
249
|
-
* world lift exactly — an un-authored chart stays pixel-identical. ≈ 1.329 m/tier.
|
|
250
|
-
*/
|
|
251
|
-
declare const TIER_HEIGHT_M: number;
|
|
252
|
-
/**
|
|
253
|
-
* Resolve a section's real 3D geometry, applying the legacy-elevation fallback so
|
|
254
|
-
* old charts and new charts share ONE code path. Every consumer (iso lift, 360°
|
|
255
|
-
* eye-height, author lint, any 2D depth cue) must call this and never read the raw
|
|
256
|
-
* {@link SectionObject.height}/{@link SectionObject.rake} fields — that is what
|
|
257
|
-
* keeps un-authored charts rendering identically to today.
|
|
258
|
-
*
|
|
259
|
-
* - `height`: authored absolute metres if present, else owning-floor base height
|
|
260
|
-
* plus `elevation × TIER_HEIGHT_M`.
|
|
261
|
-
* - `rake`: authored degrees if present, else 0 (flat).
|
|
262
|
-
*
|
|
263
|
-
* Malformed values are bounded here as a last defensive barrier. Structural
|
|
264
|
-
* validation still reports them so drafts can be repaired instead of silently
|
|
265
|
-
* persisting a renderer-only interpretation.
|
|
266
|
-
*
|
|
267
|
-
* Pure — no document mutation, no side effects.
|
|
268
|
-
*/
|
|
269
|
-
interface SectionGeometryContext {
|
|
270
|
-
/** Absolute physical height of the owning floor above the venue datum. */
|
|
271
|
-
floorBaseHeightM?: number;
|
|
272
|
-
}
|
|
273
|
-
declare function sectionGeometry(section: Pick<SectionObject, 'elevation' | 'height' | 'rake'>, context?: SectionGeometryContext): {
|
|
274
|
-
height: number;
|
|
275
|
-
rake: number;
|
|
276
|
-
};
|
|
277
|
-
|
|
278
|
-
/**
|
|
279
|
-
* Section membership + hide/show resolution (Batch 3.3).
|
|
280
|
-
*
|
|
281
|
-
* A `SectionObject` is a polygon drawn over existing seat objects; an object
|
|
282
|
-
* "belongs" to a section when its visual centre (`objectCenter`) falls inside
|
|
283
|
-
* the section outline, first section in doc order winning. This is the same
|
|
284
|
-
* spatial notion `objectCenter`'s doc-comment describes, resolved once here so
|
|
285
|
-
* BOTH the event manager (Sections tab counts) and the buyer picker (omit
|
|
286
|
-
* hidden seats) agree on which seats live in which section.
|
|
287
|
-
*
|
|
288
|
-
* Hiding is per-EVENT (the EventDO holds the hidden id set), not a chart edit —
|
|
289
|
-
* so a republish of the chart never disturbs it. A hidden id may be a section
|
|
290
|
-
* id, a zone id (hides every section in the zone), or `UNGROUPED_ID` (the
|
|
291
|
-
* catch-all bucket of seat objects that sit in no section).
|
|
292
|
-
*/
|
|
293
|
-
|
|
294
|
-
/** Synthetic section id for seat objects that fall in no drawn section. */
|
|
295
|
-
declare const UNGROUPED_ID = "__ungrouped__";
|
|
296
|
-
/**
|
|
297
|
-
* A per section/zone availability window (Batch 3.4). Wire-compatible with the
|
|
298
|
-
* EventDO's own `AvailabilityRule`. Absence of a rule for an id = on sale.
|
|
299
|
-
* 'hidden' — manual: hidden until the organizer reveals it (3.3).
|
|
300
|
-
* 'timed' — hidden until `revealAt` (epoch ms), then auto-reveals.
|
|
301
|
-
* 'threshold' — auto-reveals once the on-sale inventory is `thresholdPct`% sold.
|
|
302
|
-
* 'closed' — visible to buyers but not purchasable (rendered flat grey);
|
|
303
|
-
* unlike 'hidden', the seats stay on the map, just off sale.
|
|
304
|
-
* `labels` are the seat labels the id governs, so a threshold's denominator can
|
|
305
|
-
* exclude still-hidden seats.
|
|
306
|
-
*/
|
|
307
|
-
interface AvailabilityRule {
|
|
308
|
-
mode: 'hidden' | 'timed' | 'threshold' | 'closed';
|
|
309
|
-
revealAt?: number;
|
|
310
|
-
thresholdPct?: number;
|
|
311
|
-
labels?: string[];
|
|
312
|
-
}
|
|
313
|
-
interface SectionNode {
|
|
314
|
-
/** Section id (a `SectionObject.id`, or `UNGROUPED_ID`). */
|
|
315
|
-
id: string;
|
|
316
|
-
label: string;
|
|
317
|
-
/** Zone id this section points at (`SectionObject.zone`), if any. */
|
|
318
|
-
zone?: string;
|
|
319
|
-
/** Total seats across the member objects. */
|
|
320
|
-
seatCount: number;
|
|
321
|
-
/** Ids of the seat-bearing objects that belong to this section. */
|
|
322
|
-
objectIds: string[];
|
|
323
|
-
/** Seat labels across the member objects (for availability-rule denominators). */
|
|
324
|
-
seatLabels: string[];
|
|
325
|
-
}
|
|
326
|
-
/**
|
|
327
|
-
* Resolve section membership for a chart. Returns one node per drawn section
|
|
328
|
-
* (doc order), a synthetic "Ungrouped" node for loose seat objects (null when
|
|
329
|
-
* every seat sits in a section), and the object→section id map.
|
|
330
|
-
*/
|
|
331
|
-
declare function computeSections(doc: ChartDoc): {
|
|
332
|
-
sections: SectionNode[];
|
|
333
|
-
ungrouped: SectionNode | null;
|
|
334
|
-
/** seat-object id → owning section id (or `UNGROUPED_ID`). */
|
|
335
|
-
objectToSection: Map<string, string>;
|
|
336
|
-
};
|
|
337
|
-
/** Is a drawn section hidden under `hidden` — directly, or via its zone? */
|
|
338
|
-
declare function isSectionHidden(s: SectionObject, hidden: ReadonlySet<string>): boolean;
|
|
339
|
-
/**
|
|
340
|
-
* The set of seat-object ids to omit from the buyer view for a given hidden id
|
|
341
|
-
* set. An object is hidden when its owning section is hidden (directly or via
|
|
342
|
-
* zone), or it is ungrouped and the catch-all bucket is hidden.
|
|
343
|
-
*/
|
|
344
|
-
declare function hiddenObjectIds(doc: ChartDoc, hidden: ReadonlySet<string>): Set<string>;
|
|
345
|
-
/**
|
|
346
|
-
* A copy of the doc with hidden sections' member objects removed, plus the
|
|
347
|
-
* hidden section overlays themselves (so no empty block renders). Returns the
|
|
348
|
-
* SAME reference when nothing is hidden — callers can skip a re-render on `===`.
|
|
349
|
-
*/
|
|
350
|
-
declare function applyHidden(doc: ChartDoc, hidden: ReadonlySet<string>): ChartDoc;
|
|
351
|
-
|
|
352
|
-
declare const RENDERED_QUALITY_REPORT_VERSION = 3;
|
|
353
|
-
type RenderedEvidenceState = 'overview' | 'interaction';
|
|
354
|
-
type RenderedQualityFindingCode = 'bookable-label-undersized' | 'bookable-label-contrast-low' | 'bookable-label-collision' | 'hierarchy-label-undersized' | 'hierarchy-label-contrast-low' | 'hierarchy-label-outside-section' | 'hierarchy-label-collision' | 'hierarchy-bookable-collision' | 'overview-section-category-paint' | 'overview-category-detail-visible' | 'overview-row-hints-visible' | 'overview-availability-clutter' | 'overview-ga-detail-visible' | 'free-text-undersized' | 'free-text-contrast-low' | 'free-text-collision' | 'free-text-bookable-collision' | 'free-text-hierarchy-collision' | 'ga-contrast-low' | 'detail-rung-missing' | 'detail-inventory-not-visible' | 'pointer-target-undersized' | 'pointer-target-inactive' | 'selected-state-missing' | 'selected-state-contrast-low' | 'held-state-missing' | 'booked-state-missing' | 'status-state-indistinct' | 'section-focus-missing' | 'category-filter-missing' | 'category-filter-ineffective' | 'target-category-not-visible' | 'target-category-filter-mismatch';
|
|
355
|
-
interface RenderedQualitySample {
|
|
356
|
-
primaryId: string;
|
|
357
|
-
primaryLabel: string;
|
|
358
|
-
secondaryId?: string;
|
|
359
|
-
secondaryLabel?: string;
|
|
360
|
-
measured?: number;
|
|
361
|
-
minimum?: number;
|
|
362
|
-
}
|
|
363
|
-
interface RenderedQualityFinding {
|
|
364
|
-
code: RenderedQualityFindingCode;
|
|
365
|
-
message: string;
|
|
366
|
-
count: number;
|
|
367
|
-
samples: RenderedQualitySample[];
|
|
368
|
-
}
|
|
369
|
-
interface RenderedQualityReport {
|
|
370
|
-
version: typeof RENDERED_QUALITY_REPORT_VERSION;
|
|
371
|
-
passed: boolean;
|
|
372
|
-
state: RenderedEvidenceState;
|
|
373
|
-
/** Server-selected category exercised by a category-specific detail scene. */
|
|
374
|
-
targetCategoryKey: string | null;
|
|
375
|
-
/** Exact overview checks discharged by this browser-rendered report. */
|
|
376
|
-
resolvedRules: string[];
|
|
377
|
-
viewport: {
|
|
378
|
-
width: number;
|
|
379
|
-
height: number;
|
|
380
|
-
};
|
|
381
|
-
canvasBackground: string;
|
|
382
|
-
effectiveScale: number;
|
|
383
|
-
rung: RendererQualityEvidence['rung'];
|
|
384
|
-
inventory: {
|
|
385
|
-
totalBookableUnits: number;
|
|
386
|
-
totalLabelledBookableUnits: number;
|
|
387
|
-
visibleBookableLabels: number;
|
|
388
|
-
hiddenBookableLabels: number;
|
|
389
|
-
visibleHierarchyLabels: number;
|
|
390
|
-
visibleFreeTextLabels: number;
|
|
391
|
-
visibleGAAreas: number;
|
|
392
|
-
};
|
|
393
|
-
overviewStyle?: RendererQualityEvidence['overviewStyle'];
|
|
394
|
-
/**
|
|
395
|
-
* Coordinate-free identity evidence from the exact buyer scene. The Worker
|
|
396
|
-
* uses this to compare persisted reference semantics with what Chromium
|
|
397
|
-
* actually painted, without exposing screen boxes or accepting geometry.
|
|
398
|
-
*/
|
|
399
|
-
composition: {
|
|
400
|
-
hierarchy: Array<{
|
|
401
|
-
id: string;
|
|
402
|
-
kind: 'section' | 'zone';
|
|
403
|
-
label: string;
|
|
404
|
-
visible: boolean;
|
|
405
|
-
}>;
|
|
406
|
-
labelledObjects: Array<{
|
|
407
|
-
objectId: string;
|
|
408
|
-
kind: RenderedFreeTextEvidence['kind'];
|
|
409
|
-
text: string;
|
|
410
|
-
visible: boolean;
|
|
411
|
-
}>;
|
|
412
|
-
gaAreas: Array<{
|
|
413
|
-
areaId: string;
|
|
414
|
-
label: string;
|
|
415
|
-
categoryKey: string;
|
|
416
|
-
sectionId?: string;
|
|
417
|
-
visible: boolean;
|
|
418
|
-
}>;
|
|
419
|
-
bookableSectionIds: string[];
|
|
420
|
-
categoryKeys: string[];
|
|
421
|
-
/** Categories whose non-dimmed bookable paint is visible in this scene. */
|
|
422
|
-
activeCategoryKeys: string[];
|
|
423
|
-
};
|
|
424
|
-
metrics: {
|
|
425
|
-
minimumRenderedBookableLabelPx: number | null;
|
|
426
|
-
minimumBookableLabelContrast: number | null;
|
|
427
|
-
minimumRenderedHierarchyLabelPx: number | null;
|
|
428
|
-
minimumHierarchyLabelContrast: number | null;
|
|
429
|
-
minimumRenderedFreeTextPx: number | null;
|
|
430
|
-
minimumFreeTextContrast: number | null;
|
|
431
|
-
minimumGAContrast: number | null;
|
|
432
|
-
minimumEffectivePointerTargetPx: number | null;
|
|
433
|
-
selectedRingContrast: number | null;
|
|
434
|
-
};
|
|
435
|
-
interaction: {
|
|
436
|
-
applicable: {
|
|
437
|
-
detail: boolean;
|
|
438
|
-
pointer: boolean;
|
|
439
|
-
held: boolean;
|
|
440
|
-
booked: boolean;
|
|
441
|
-
sectionFocus: boolean;
|
|
442
|
-
categoryFilter: boolean;
|
|
443
|
-
};
|
|
444
|
-
selectedUnits: number;
|
|
445
|
-
heldUnits: number;
|
|
446
|
-
bookedUnits: number;
|
|
447
|
-
activePointerTargets: number;
|
|
448
|
-
focusedSectionId: string | null;
|
|
449
|
-
focusBackdropVisible: boolean;
|
|
450
|
-
categoryFilterKeys: string[] | null;
|
|
451
|
-
};
|
|
452
|
-
findings: RenderedQualityFinding[];
|
|
453
|
-
}
|
|
454
|
-
/**
|
|
455
|
-
* Inspect what the buyer renderer actually decided to paint at one exact
|
|
456
|
-
* viewport. This is deliberately downstream of ChartDoc validation: screen
|
|
457
|
-
* size, LOD visibility, fitted hierarchy text, transient paint, and label
|
|
458
|
-
* collisions cannot be proven from stored geometry alone.
|
|
459
|
-
*/
|
|
460
|
-
declare function inspectRenderedQualityEvidence(evidence: RendererQualityEvidence, state?: RenderedEvidenceState, targetCategoryKey?: string | null): RenderedQualityReport;
|
|
1
|
+
import { C as ChartDoc, P as Point, A as AccessibilityType, l as CategoryTier, f as SeatCommercialAttributes } from './types-DTSG6_Hq.js';
|
|
2
|
+
export { t as ACCESSIBILITY_RING_COLOR, u as ACCESSIBILITY_TYPES, v as AccessibilityMeta, w as AuthoringObjectState, B as BoothObject, x as Category, y as ChartLayoutConstraint, c as ChartObject, m as ChartReferenceImage, z as ChartTheme, r as CubicPath, D as DecorImageObject, F as Floor, G as GAAreaObject, k as GAInventorySegment, E as LABEL_STYLE_MAX_SIZE, H as LABEL_STYLE_MIN_SIZE, I as LabelPresentation, L as LabelStyle, O as ObjectEditorState, J as Physical3dEvidence, K as RadialClearanceLayoutConstraint, e as RectTableSeatCounts, b as RectTableSide, M as ReferenceAccessibilitySource, N as ReferenceCalibration, Q as ReferenceCategorySource, U as ReferenceDerivedScale, V as ReferenceInventoryExclusionSource, W as ReferenceInventorySource, X as ReferenceScanProposal, Y as ReferenceScanRowProposal, Z as ReferenceScanSectionProposal, _ as ReferenceSeatSeed, $ as ReferenceSectionTraceBatchInput, a0 as ReferenceSectionTraceBatchProposal, a1 as ReferenceSectionTraceInput, a2 as ReferenceSectionTraceProposal, g as ResolvedSeatConfidenceEvidence, R as RowObject, a3 as SEAT_COMMERCIAL_MARKS, a4 as SURROUNDINGS_SHAPE_ROLES, a5 as SeatCommercialMark, a6 as SeatCommercialMeta, a7 as SeatConfidenceCoverage, a8 as SeatConfidenceEvidence, a9 as SeatConfidenceModelLevel, aa as SeatConfidenceModeledTarget, ab as SeatConfidenceRealityLevel, S as SeatOverride, h as SeatViewCoverage, a as SeatViewMetadata, d as SectionObject, i as SectionOutlinePath, j as SectionPathSegment, ac as SelectionLayer, n as ShapeLineCap, o as ShapeLineEnding, p as ShapeLineJoin, q as ShapeObject, T as TableObject, ad as TextAlignment, ae as TextBackground, s as TextObject, af as TicketTierApplicability, ag as TicketTierEvidence, ah as TicketTierRestriction, ai as ZoneDef, aj as accessibilityMeta, ak as accessibilityRingColor, al as layerOf, am as seatCommercialMeta } from './types-DTSG6_Hq.js';
|
|
3
|
+
export { E as ExpandChartOptions, R as RowSeatSlot, T as TableSeatSlot, a as allObjects, c as chartBounds, e as expandBooth, b as expandChart, d as expandRow, f as expandRowSlots, g as expandTable, h as expandTableSlots, i as floorObjects, j as floorOverviewTranslations, k as floorsOf, l as layoutFloorOverview, o as objectCenter, m as owningSectionForObject, p as pointInPolygon, n as pointInPolygonWithHoles, q as polygonLabelPoint, r as rowInventoryCount, s as rowSeatPositions, t as stackFloors, u as tableInventoryCount, v as tableSeatCountsBySide, w as translateObject } from './layout-ClQkmixY.js';
|
|
4
|
+
import { c as TicketSelectionIssue } from './ticketRestrictions-DaYOCpEw.js';
|
|
5
|
+
export { M as MAX_EVENT_INVENTORY, a as MAX_GA_CAPACITY, g as gaAreasOf, h as gaInventorySegments, i as gaUnitLabel, j as gaUnitLabels, k as growJoinedGAInventory, l as isGaUnitLabel, v as validGAInventorySegments } from './ticketRestrictions-DaYOCpEw.js';
|
|
6
|
+
export { A as AvailabilityRule, S as SectionNode, T as TIER_HEIGHT_M, U as UNGROUPED_ID, a as applyHidden, c as computeSections, h as hiddenObjectIds, i as isSectionHidden, s as sectionGeometry } from './sections-DIzgtDjF.js';
|
|
7
|
+
export { R as RENDERED_QUALITY_REPORT_VERSION, a as RenderedEvidenceState, b as RenderedQualityFinding, c as RenderedQualityFindingCode, d as RenderedQualityReport, e as RenderedQualitySample, i as inspectRenderedQualityEvidence } from './renderedQuality-B3jgdgPO.js';
|
|
8
|
+
import { I as ISeatmapRenderer, b as RendererOptions, S as SeatStatus, E as ExpandedSeat, c as RendererViewMode, d as RendererMinimapSnapshot, L as LodRung, R as RendererQualityEvidence, e as RendererCallbacks } from './renderer-B_g-W_QB.js';
|
|
9
|
+
export { C as CHART_STORAGE_KEY, f as RenderedBookableLabelEvidence, a as RenderedFreeTextEvidence, g as RenderedGAAreaEvidence, h as RenderedHierarchyLabelEvidence, i as RenderedLabelHiddenReason, j as RenderedRowLabelEvidence, k as RendererMinimapSeat, l as RendererMinimapSection } from './renderer-B_g-W_QB.js';
|
|
10
|
+
import './segmentedRowModel-COXw4GCh.js';
|
|
461
11
|
|
|
462
12
|
declare class SeatmapRenderer implements ISeatmapRenderer {
|
|
463
13
|
private container;
|
|
@@ -681,6 +231,8 @@ declare class SeatmapRenderer implements ISeatmapRenderer {
|
|
|
681
231
|
}[];
|
|
682
232
|
getActiveFloorId(): string;
|
|
683
233
|
setStatus(seatIds: string[], status: SeatStatus): void;
|
|
234
|
+
/** Repaint event-only category overrides without rebuilding the chart. */
|
|
235
|
+
setSeatCategories(assignments: Record<string, string>): void;
|
|
684
236
|
setOwnedHold(seatIds: string[] | null): void;
|
|
685
237
|
setSelectionFocus(seatId: string | null): void;
|
|
686
238
|
getStatus(seatId: string): SeatStatus;
|
|
@@ -1024,62 +576,17 @@ declare class SeatmapRenderer implements ISeatmapRenderer {
|
|
|
1024
576
|
*/
|
|
1025
577
|
private renderSection;
|
|
1026
578
|
private refreshSectionHeat;
|
|
1027
|
-
/** Recompute a section's availability shading + retained availability text. */
|
|
1028
579
|
private refreshSectionFill;
|
|
1029
|
-
/** True when a section/zone is currently in the `closed` event-state. */
|
|
1030
580
|
private isSectionClosed;
|
|
1031
|
-
/** Resolve the four-bucket overview availability state for a section (OV-69).
|
|
1032
|
-
* `closed` (operator) outranks live availability; the availability buckets
|
|
1033
|
-
* only apply to seated sections (GA-only shells have no seat capacity here). */
|
|
1034
581
|
private sectionAvailabilityState;
|
|
1035
|
-
/** Overview shells stay neutral except for the bounded availability shading
|
|
1036
|
-
* (nearly-gone / sold-out) and the operator `closed` slab — never category
|
|
1037
|
-
* or price paint, which is deferred to section focus/seat detail. */
|
|
1038
582
|
private sectionBlockFill;
|
|
583
|
+
private get sectionLodPaintContext();
|
|
1039
584
|
/**
|
|
1040
585
|
* Zone rung: one giant screen-constant label per zone (+ optional "FROM $n"),
|
|
1041
586
|
* shown at the farthest zoom in place of per-section detail. Skipped entirely
|
|
1042
587
|
* when the doc declares no zones — sections then stay the far rung (graceful).
|
|
1043
588
|
*/
|
|
1044
589
|
private renderZones;
|
|
1045
|
-
/**
|
|
1046
|
-
* THE MELT — a continuous, scale-driven cross-fade across the three rungs:
|
|
1047
|
-
* seats ⇄ section blocks ⇄ zone blocks.
|
|
1048
|
-
* `blockT` ramps 0→1 as scale falls through [SECTION_PROMINENT, CACHE_THRESHOLD]
|
|
1049
|
-
* so the solid fill is fully present exactly as seats become the cached bitmap
|
|
1050
|
-
* and fade out; `zoneT` ramps 0→1 across [ZONE_PROMINENT, SECTION_PROMINENT] so
|
|
1051
|
-
* per-section detail hands off to giant zone labels. Reduced-motion hard-swaps.
|
|
1052
|
-
* Section/zone labels are scale-compensated to hold a roughly constant screen size.
|
|
1053
|
-
*/
|
|
1054
|
-
private applySectionLod;
|
|
1055
|
-
/** One semantic section gets one overview label, even across split contours. */
|
|
1056
|
-
private dedupeLogicalSectionLabels;
|
|
1057
|
-
/**
|
|
1058
|
-
* Keep transitional zone pills from covering section names, and keep section
|
|
1059
|
-
* names off each other.
|
|
1060
|
-
*
|
|
1061
|
-
* This used to assume section labels "do not collide by construction",
|
|
1062
|
-
* because each is proven to fit inside its own shell. That holds only while
|
|
1063
|
-
* shells are disjoint. Hand-traced and imported plans routinely produce
|
|
1064
|
-
* shells that touch or overlap slightly along a shared edge, and a label
|
|
1065
|
-
* fitted into one can then land under its neighbour's — which is exactly the
|
|
1066
|
-
* unreadable smear a 36-section arena showed. Section labels now block each
|
|
1067
|
-
* other too, largest shell first so the big stands keep their names.
|
|
1068
|
-
*/
|
|
1069
|
-
private decollideRungLabels;
|
|
1070
|
-
/** Set a centred label's world fontSize (for a target screen px) and re-anchor it. */
|
|
1071
|
-
private sizeLabel;
|
|
1072
|
-
/** Fit one centred section name, rotating narrow shells like the target chart. */
|
|
1073
|
-
private fitSectionRungLabels;
|
|
1074
|
-
/**
|
|
1075
|
-
* Screen-constant chrome must still respect the screen it is constant on:
|
|
1076
|
-
* an 18px zone cap sized for a 900px designer canvas eats a 360px phone map
|
|
1077
|
-
* (owner report, 2026-08-14). Scales the fixed-px chrome down to 66% on the
|
|
1078
|
-
* smallest containers; never up.
|
|
1079
|
-
*/
|
|
1080
|
-
private uiScale;
|
|
1081
|
-
/** Size one screen-constant zone name/price pill around its shared anchor. */
|
|
1082
|
-
private sizeZonePill;
|
|
1083
590
|
/**
|
|
1084
591
|
* Map a container-relative screen point back to world coords. Inverts the
|
|
1085
592
|
* stage (scale/pos) and, in iso view, the iso affine — so screen-space taps
|
|
@@ -1192,6 +699,8 @@ declare class SeatmapRenderer implements ISeatmapRenderer {
|
|
|
1192
699
|
private afterViewChange;
|
|
1193
700
|
/** rAF-coalesced `onViewChange` — at most one host callback per animation frame. */
|
|
1194
701
|
private scheduleViewChange;
|
|
702
|
+
/** Keep focal labels centred while their world font size tracks camera scale. */
|
|
703
|
+
private sizeLabel;
|
|
1195
704
|
private updateLOD;
|
|
1196
705
|
/** Rebuild the seat-layer bitmap synchronously (no paint). Shared by the
|
|
1197
706
|
* debounced cacheSeatLayer() and the synchronous forceDraw() catch-up. */
|
|
@@ -1254,27 +763,20 @@ declare class SeatmapRenderer implements ISeatmapRenderer {
|
|
|
1254
763
|
* category/price filters that dim their seats. */
|
|
1255
764
|
private objectFilteredOut;
|
|
1256
765
|
private updateLabels;
|
|
766
|
+
private get viewportLabelContext();
|
|
1257
767
|
private handleResize;
|
|
1258
768
|
private startFpsLoop;
|
|
1259
769
|
}
|
|
1260
770
|
declare function createRenderer(container: HTMLDivElement, opts?: RendererOptions): ISeatmapRenderer;
|
|
1261
771
|
|
|
1262
|
-
|
|
1263
|
-
|
|
1264
|
-
|
|
1265
|
-
|
|
1266
|
-
|
|
1267
|
-
|
|
1268
|
-
|
|
1269
|
-
|
|
1270
|
-
message: string;
|
|
1271
|
-
}
|
|
1272
|
-
interface NotForSaleSelectionIssue {
|
|
1273
|
-
code: 'not_for_sale';
|
|
1274
|
-
labels: string[];
|
|
1275
|
-
message: string;
|
|
1276
|
-
}
|
|
1277
|
-
type TicketSelectionIssue = CompanionSelectionIssue | TicketOptionApplicabilityIssue | NotForSaleSelectionIssue;
|
|
772
|
+
/**
|
|
773
|
+
* Public host contracts for the framework-agnostic buyer picker.
|
|
774
|
+
*
|
|
775
|
+
* Kept separate from `PickerController` so SDK and application consumers can
|
|
776
|
+
* find the integration surface without wading through controller state and
|
|
777
|
+
* transport orchestration. `PickerController` re-exports these names for
|
|
778
|
+
* source compatibility.
|
|
779
|
+
*/
|
|
1278
780
|
|
|
1279
781
|
interface PickerSeat {
|
|
1280
782
|
id: string;
|
|
@@ -1550,6 +1052,15 @@ interface PickerTransport {
|
|
|
1550
1052
|
interface PickerCallbacks extends RendererCallbacks {
|
|
1551
1053
|
/** Selection changed (manual clicks or a server best-available pick). */
|
|
1552
1054
|
onSelectionChange?: (seats: PickerSeat[]) => void;
|
|
1055
|
+
/**
|
|
1056
|
+
* Exact-selection validity changed. Emitted only when
|
|
1057
|
+
* `numberOfPlacesToSelect` is configured, after `onSelectionChange`.
|
|
1058
|
+
*/
|
|
1059
|
+
onSelectionValidityChange?: (state: PickerSelectionValidity) => void;
|
|
1060
|
+
/** The configured exact selection count has just been reached. */
|
|
1061
|
+
onSelectionValid?: (seats: PickerSeat[]) => void;
|
|
1062
|
+
/** The current selection does not yet match the configured exact count. */
|
|
1063
|
+
onSelectionInvalid?: (state: PickerSelectionValidity) => void;
|
|
1553
1064
|
/** A grouped table was selected and needs buyer confirmation/guest quantity. */
|
|
1554
1065
|
onTableSelectionRequest?: (table: TableSelectionDetails) => void;
|
|
1555
1066
|
/** A hold opened (manual hold or best-available). */
|
|
@@ -1590,6 +1101,18 @@ interface PickerOptions extends PickerCallbacks {
|
|
|
1590
1101
|
transport: PickerTransport;
|
|
1591
1102
|
eventKey: string;
|
|
1592
1103
|
maxSelection?: number;
|
|
1104
|
+
/** Object ids or public labels selected after the first live snapshot lands. */
|
|
1105
|
+
selectedObjects?: string[];
|
|
1106
|
+
/**
|
|
1107
|
+
* Object ids or public labels a buyer may select. Omit/null for every free
|
|
1108
|
+
* object. A grouped table reference expands to the whole booking unit.
|
|
1109
|
+
*/
|
|
1110
|
+
selectableObjects?: string[] | null;
|
|
1111
|
+
/**
|
|
1112
|
+
* Require exactly this many seated/table guest units. It also becomes the
|
|
1113
|
+
* selection cap when `maxSelection` is omitted.
|
|
1114
|
+
*/
|
|
1115
|
+
numberOfPlacesToSelect?: number;
|
|
1593
1116
|
/** Renderer confirm-card mode (host shows a confirm popover instead of instant cart add). */
|
|
1594
1117
|
confirmSelection?: boolean;
|
|
1595
1118
|
/** ISO 4217 currency for on-map prices (default from money.DEFAULT_CURRENCY). */
|
|
@@ -1616,6 +1139,14 @@ interface PickerOptions extends PickerCallbacks {
|
|
|
1616
1139
|
*/
|
|
1617
1140
|
mapTheme?: PickerMapTheme | null;
|
|
1618
1141
|
}
|
|
1142
|
+
/** Exact-count state shared by the bare chart, full picker, and wrappers. */
|
|
1143
|
+
interface PickerSelectionValidity {
|
|
1144
|
+
isValid: boolean;
|
|
1145
|
+
count: number;
|
|
1146
|
+
required: number;
|
|
1147
|
+
remaining: number;
|
|
1148
|
+
seats: PickerSeat[];
|
|
1149
|
+
}
|
|
1619
1150
|
/** Privacy-safe timings for one buyer-map load. Values are milliseconds and
|
|
1620
1151
|
* contain no chart, seat, hold, buyer, or URL data. Hosts may aggregate these
|
|
1621
1152
|
* with coarse chart-size/device dimensions supplied by the widget. */
|
|
@@ -1655,11 +1186,16 @@ interface PickerMapTheme {
|
|
|
1655
1186
|
/** Selection / hover ring. */
|
|
1656
1187
|
selectionColor?: string;
|
|
1657
1188
|
}
|
|
1189
|
+
|
|
1658
1190
|
declare class PickerController {
|
|
1659
1191
|
private readonly opts;
|
|
1660
1192
|
private readonly api;
|
|
1661
1193
|
private readonly key;
|
|
1662
1194
|
private maxSelection;
|
|
1195
|
+
private readonly numberOfPlacesToSelect;
|
|
1196
|
+
private selectableObjectRefs;
|
|
1197
|
+
private selectableSeatIds;
|
|
1198
|
+
private lastSelectionValidity;
|
|
1663
1199
|
private renderer;
|
|
1664
1200
|
private _doc;
|
|
1665
1201
|
/** Section/zone ids hidden from buyers this event (3.3) — seats vanish, not grey. */
|
|
@@ -1799,7 +1335,16 @@ declare class PickerController {
|
|
|
1799
1335
|
clearSelection(): void;
|
|
1800
1336
|
deselect(ids: string[]): void;
|
|
1801
1337
|
setMaxSelection(maxSelection: number): void;
|
|
1802
|
-
select(
|
|
1338
|
+
select(references: string[]): PickerSeat[];
|
|
1339
|
+
/** Select every currently selectable object in the given categories. */
|
|
1340
|
+
selectCategories(categoryKeys: string[]): PickerSeat[];
|
|
1341
|
+
/** Deselect every selected object in the given categories. */
|
|
1342
|
+
deselectCategories(categoryKeys: string[]): void;
|
|
1343
|
+
/** Replace the buyer-selectable object allow-list without rebuilding. */
|
|
1344
|
+
setSelectableObjects(references: string[] | null): void;
|
|
1345
|
+
getSelectionValidity(): PickerSelectionValidity | null;
|
|
1346
|
+
private rebuildSelectableSeatIds;
|
|
1347
|
+
private isSelectableByPolicy;
|
|
1803
1348
|
/** Confirm/update the guest quantity for a selected variable table. */
|
|
1804
1349
|
setTableQuantity(label: string, quantity: number): boolean;
|
|
1805
1350
|
/**
|
|
@@ -2023,6 +1568,7 @@ declare class PickerController {
|
|
|
2023
1568
|
/** PickerSeats (with chosen tier) for a set of held labels. */
|
|
2024
1569
|
private seatsForLabels;
|
|
2025
1570
|
private emitSelectionChange;
|
|
1571
|
+
private emitSelectionValidity;
|
|
2026
1572
|
/** Check explicit tier applicability and companion relationships for the
|
|
2027
1573
|
* current (or supplied) seats. Ticket display names are never semantic input. */
|
|
2028
1574
|
ticketIssue(labels?: string[]): TicketSelectionIssue | null;
|
|
@@ -2232,16 +1778,21 @@ declare const DEFAULT_CURRENCY = "USD";
|
|
|
2232
1778
|
* express create forms so the two can never offer different lists. */
|
|
2233
1779
|
declare const CURRENCY_CHOICES: string[];
|
|
2234
1780
|
declare function setMoneyLocale(locale: string | undefined): void;
|
|
2235
|
-
|
|
2236
|
-
|
|
2237
|
-
|
|
2238
|
-
|
|
2239
|
-
|
|
2240
|
-
|
|
2241
|
-
|
|
2242
|
-
|
|
2243
|
-
|
|
2244
|
-
|
|
1781
|
+
interface MoneyFormatOptions {
|
|
1782
|
+
/** BCP 47 locale for this value; takes precedence over `setMoneyLocale`. */
|
|
1783
|
+
locale?: string;
|
|
1784
|
+
/** Leave unset to use the currency's standard exponent (`$45.00`, `¥45`). */
|
|
1785
|
+
minimumFractionDigits?: number;
|
|
1786
|
+
/** Leave unset to use the currency's standard exponent (`$45.00`, `¥45`). */
|
|
1787
|
+
maximumFractionDigits?: number;
|
|
1788
|
+
/**
|
|
1789
|
+
* Rendering for invalid/unknown currency input. Required by buyer SDK
|
|
1790
|
+
* surfaces that must remain usable even when a host supplies a bad code.
|
|
1791
|
+
* Without one, the original `Intl.NumberFormat` error is rethrown.
|
|
1792
|
+
*/
|
|
1793
|
+
fallback?: (amount: number, currency: string) => string;
|
|
1794
|
+
}
|
|
1795
|
+
declare function formatMoney(amount: number, currency: string, options: MoneyFormatOptions): string;
|
|
2245
1796
|
declare function formatMoney(amount: number, currency?: string, fractionDigits?: number, locale?: string): string;
|
|
2246
1797
|
/**
|
|
2247
1798
|
* How many decimal places a currency has — 2 for USD/EUR, 0 for JPY/KRW/VND,
|
|
@@ -2270,4 +1821,4 @@ declare function formatMinor(minor: number, currency?: string, locale?: string):
|
|
|
2270
1821
|
/** Bare symbol for input adornments ("€", "$", "₹"). */
|
|
2271
1822
|
declare function currencySymbol(currency?: string): string;
|
|
2272
1823
|
|
|
2273
|
-
export { AccessibilityType,
|
|
1824
|
+
export { AccessibilityType, CURRENCY_CHOICES, CategoryTier, ChartDoc, DEFAULT_CURRENCY, type Dict, ExpandedSeat, type HoldConflict, type HoldInfo, type HoldSelectionRequest, type HoldServerItem, ISeatmapRenderer, type Locale, LodRung, type MoneyFormatOptions, type PanoramaResult, type PickerCallbacks, PickerController, type PickerGAArea, type PickerMapTheme, type PickerOptions, type PickerRealtimeConnection, type PickerRealtimeSink, type PickerRenderPerformanceProfile, type PickerSeat, PickerSelectionError, type PickerSelectionValidity, type PickerStatusChange, type PickerTransport, Point, RendererCallbacks, RendererMinimapSnapshot, RendererOptions, RendererQualityEvidence, RendererViewMode, SUPPORTED_LOCALES, SeatCommercialAttributes, type SeatHoverDetails, SeatStatus, SeatmapRenderer, type SectionCategory, type SectionSummary, type TableSelectionDetails, createRenderer, currencyExponent, currencySymbol, formatDate, formatMinor, formatMoney, fromMinorUnits, generateSeatPanorama, generateSeatThumb, getLocale, loadLocale, resolveLocale, setLocale, setMoneyLocale, setStringOverrides, t, tCount };
|