@seatlayer/core 0.26.0 → 0.28.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/{de-73TIXYJH.js → de-UHAOVDS3.js} +3 -2
- package/dist/de-UHAOVDS3.js.map +1 -0
- package/dist/{es-SKAODLTR.js → es-6TJS2L7S.js} +3 -2
- package/dist/es-6TJS2L7S.js.map +1 -0
- package/dist/{fr-J4637T6V.js → fr-MMSY7FPE.js} +3 -2
- package/dist/fr-MMSY7FPE.js.map +1 -0
- package/dist/index.cjs +496 -42
- package/dist/index.cjs.map +1 -1
- package/dist/index.d.cts +79 -2
- package/dist/index.d.ts +79 -2
- package/dist/index.js +493 -42
- package/dist/index.js.map +1 -1
- package/package.json +1 -1
- package/dist/de-73TIXYJH.js.map +0 -1
- package/dist/es-SKAODLTR.js.map +0 -1
- package/dist/fr-J4637T6V.js.map +0 -1
package/dist/index.d.cts
CHANGED
|
@@ -406,6 +406,11 @@ interface GAAreaObject {
|
|
|
406
406
|
holes?: Point[][];
|
|
407
407
|
capacity: number;
|
|
408
408
|
categoryKey: string;
|
|
409
|
+
/** Corner-rounding radius in chart units (default 0 = sharp corners). Pure
|
|
410
|
+
* presentation — softens the polygon's corners in every renderer without
|
|
411
|
+
* touching capacity, unit identities, or the stored points. Clamped per
|
|
412
|
+
* corner to half the shorter adjacent edge at draw time. */
|
|
413
|
+
cornerRadius?: number;
|
|
409
414
|
/**
|
|
410
415
|
* Durable inventory provenance for a surface produced by Join Areas.
|
|
411
416
|
*
|
|
@@ -606,6 +611,16 @@ interface BoothObject {
|
|
|
606
611
|
width: number;
|
|
607
612
|
height: number;
|
|
608
613
|
rotation: number;
|
|
614
|
+
/**
|
|
615
|
+
* Optional custom outline (closed polygon, absolute chart coordinates) for
|
|
616
|
+
* non-rectangular booths — L-shaped, corner, or island units on expo floors.
|
|
617
|
+
* Absent = the default axis-aligned rectangle described by `width`/`height`/
|
|
618
|
+
* `rotation`. A booth stays exactly ONE atomic sellable unit whatever its
|
|
619
|
+
* outline; `points` is purely geometric. `width`/`height` are retained as the
|
|
620
|
+
* last rectangular size so "Back to rectangle" can restore it. When `points`
|
|
621
|
+
* is present, renderers draw the polygon and ignore `rotation`.
|
|
622
|
+
*/
|
|
623
|
+
points?: Point[];
|
|
609
624
|
categoryKey: string;
|
|
610
625
|
referenceInventorySource?: ReferenceInventorySource;
|
|
611
626
|
}
|
|
@@ -747,6 +762,13 @@ interface TextObject {
|
|
|
747
762
|
id: string;
|
|
748
763
|
/** Persisted provenance for objects created from the venue-icon palette. */
|
|
749
764
|
semanticKind?: 'icon';
|
|
765
|
+
/**
|
|
766
|
+
* Registry key for a vector wayfinding icon (see src/core/icons.ts). Present
|
|
767
|
+
* on modern icon placements; the object then renders as a single-color vector
|
|
768
|
+
* Path instead of `text`. Absent on legacy emoji icons, which keep rendering
|
|
769
|
+
* `text` through the shared glyph path — old charts are never rewritten.
|
|
770
|
+
*/
|
|
771
|
+
iconKey?: string;
|
|
750
772
|
text: string;
|
|
751
773
|
position: Point;
|
|
752
774
|
fontSize: number;
|
|
@@ -1860,6 +1882,8 @@ declare class SeatmapRenderer implements ISeatmapRenderer {
|
|
|
1860
1882
|
private accessGlyphById;
|
|
1861
1883
|
/** Authored free-text nodes obey the same rendered-size visibility floor. */
|
|
1862
1884
|
private freeTextById;
|
|
1885
|
+
/** Vector venue-icon Path nodes + authored size; obey the free-text size floor. */
|
|
1886
|
+
private iconNodeById;
|
|
1863
1887
|
/** Stage/rink landmarks retain a readable screen-space caption at overview. */
|
|
1864
1888
|
private primaryFocalLabels;
|
|
1865
1889
|
/** GA paint and text share price/highlight filter state. */
|
|
@@ -1873,6 +1897,12 @@ declare class SeatmapRenderer implements ISeatmapRenderer {
|
|
|
1873
1897
|
private effSelection;
|
|
1874
1898
|
/** Colorblind-safe mode (Okabe-Ito hues + hollow booked seats). */
|
|
1875
1899
|
private colorblind;
|
|
1900
|
+
/** Stable per-category-KEY colorblind hue (OV-46) — order-independent. */
|
|
1901
|
+
private cbHueByKey;
|
|
1902
|
+
/** OV-45(a): authored row-letter labels for the buyer/preview map, resolved in
|
|
1903
|
+
* world space (matching seat labels) and honouring each row's labelPresentation
|
|
1904
|
+
* (position/rotation/visibility/style). Painted at the seats LOD rung. */
|
|
1905
|
+
private rowLabelPlan;
|
|
1876
1906
|
/** Category order from the doc — the stable index into the CB palette. */
|
|
1877
1907
|
private catOrder;
|
|
1878
1908
|
private selection;
|
|
@@ -2347,11 +2377,17 @@ declare class SeatmapRenderer implements ISeatmapRenderer {
|
|
|
2347
2377
|
*/
|
|
2348
2378
|
private renderSection;
|
|
2349
2379
|
private refreshSectionHeat;
|
|
2350
|
-
/** Recompute a section's
|
|
2380
|
+
/** Recompute a section's availability shading + retained availability text. */
|
|
2351
2381
|
private refreshSectionFill;
|
|
2352
2382
|
/** True when a section/zone is currently in the `closed` event-state. */
|
|
2353
2383
|
private isSectionClosed;
|
|
2354
|
-
/**
|
|
2384
|
+
/** Resolve the four-bucket overview availability state for a section (OV-69).
|
|
2385
|
+
* `closed` (operator) outranks live availability; the availability buckets
|
|
2386
|
+
* only apply to seated sections (GA-only shells have no seat capacity here). */
|
|
2387
|
+
private sectionAvailabilityState;
|
|
2388
|
+
/** Overview shells stay neutral except for the bounded availability shading
|
|
2389
|
+
* (nearly-gone / sold-out) and the operator `closed` slab — never category
|
|
2390
|
+
* or price paint, which is deferred to section focus/seat detail. */
|
|
2355
2391
|
private sectionBlockFill;
|
|
2356
2392
|
/**
|
|
2357
2393
|
* Zone rung: one giant screen-constant label per zone (+ optional "FROM $n"),
|
|
@@ -2502,6 +2538,22 @@ declare class SeatmapRenderer implements ISeatmapRenderer {
|
|
|
2502
2538
|
* debounced cacheSeatLayer() and the synchronous forceDraw() catch-up. */
|
|
2503
2539
|
private rebuildSeatCache;
|
|
2504
2540
|
private cacheSeatLayer;
|
|
2541
|
+
/**
|
|
2542
|
+
* Drop the seat-layer overview bitmap while PRESERVING every descendant's
|
|
2543
|
+
* cached local transform + clientRect.
|
|
2544
|
+
*
|
|
2545
|
+
* Konva's public `Layer.clearCache()` releases the bitmap and then runs a deep
|
|
2546
|
+
* `_clearSelfAndDescendantCache()` that clears those caches on all 14k seat
|
|
2547
|
+
* nodes. Recomputing them on the single frame the melt first reveals a section's
|
|
2548
|
+
* live seats is the ~480ms first-drill stall (OV-80). A camera glide only marks
|
|
2549
|
+
* each seat's ABSOLUTE_TRANSFORM dirty (recomputed lazily at ordinary pan cost)
|
|
2550
|
+
* and never moves a seat's LOCAL transform, so the local caches stay valid —
|
|
2551
|
+
* keeping them lets the first melt paint at pan cost, matching the ~17ms of
|
|
2552
|
+
* every subsequent glide on the same section. Any edit that actually moves a
|
|
2553
|
+
* seat invalidates its own transform cache through the attr setter, so only
|
|
2554
|
+
* still-valid caches survive here.
|
|
2555
|
+
*/
|
|
2556
|
+
private releaseSeatLayerBitmap;
|
|
2505
2557
|
/**
|
|
2506
2558
|
* SYNCHRONOUS repaint that bypasses requestAnimationFrame — see the
|
|
2507
2559
|
* ISeatmapRenderer.forceDraw() contract. Chrome pauses rAF (and therefore
|
|
@@ -2515,6 +2567,15 @@ declare class SeatmapRenderer implements ISeatmapRenderer {
|
|
|
2515
2567
|
*/
|
|
2516
2568
|
forceDraw(): void;
|
|
2517
2569
|
private updateFreeTextVisibility;
|
|
2570
|
+
/** OV-45(a): resolve authored row-letter labels for the buyer/preview map, in
|
|
2571
|
+
* world space, matching the Designer's placement contract (start/end/both/none
|
|
2572
|
+
* preset, a free-drag `position` that wins over the preset, rotation, and
|
|
2573
|
+
* labelStyle colour/size fed through the same auto-contrast guard). Segmented
|
|
2574
|
+
* rows keep their own logical-label handling and are resolved by their owner. */
|
|
2575
|
+
private buildRowLabelPlan;
|
|
2576
|
+
/** Row labels never carry status; the buyer just dims them under the same
|
|
2577
|
+
* category/price filters that dim their seats. */
|
|
2578
|
+
private objectFilteredOut;
|
|
2518
2579
|
private updateLabels;
|
|
2519
2580
|
private handleResize;
|
|
2520
2581
|
private startFpsLoop;
|
|
@@ -2626,6 +2687,7 @@ interface SectionCategory {
|
|
|
2626
2687
|
*/
|
|
2627
2688
|
interface SectionSummary {
|
|
2628
2689
|
id: string;
|
|
2690
|
+
/** Buyer-facing section name (`displayLabel` when set, else the inventory label). */
|
|
2629
2691
|
label: string;
|
|
2630
2692
|
/** Zone label (from ChartDoc.zones); '' when the section has no zone. */
|
|
2631
2693
|
zoneLabel: string;
|
|
@@ -2826,6 +2888,21 @@ declare class PickerController {
|
|
|
2826
2888
|
private idsForLabels;
|
|
2827
2889
|
/** Resolve a physical chair id (or table inventory label) to its table unit. */
|
|
2828
2890
|
tableSelection(seatIdOrLabel: string): TableSelectionDetails | null;
|
|
2891
|
+
/**
|
|
2892
|
+
* Buyer-facing name + type word for a checkout line item, resolved from the
|
|
2893
|
+
* SAME author overrides the tray/tooltip already render. `label` stays the
|
|
2894
|
+
* booking identity; a host builds its own order summary from `displayLabel`/
|
|
2895
|
+
* `displayType` so the buyer sees the designer's copy, not the internal label.
|
|
2896
|
+
* Absent fields = no override (host falls back to `label`).
|
|
2897
|
+
*/
|
|
2898
|
+
lineItemDisplay(item: {
|
|
2899
|
+
label: string;
|
|
2900
|
+
objectId: string;
|
|
2901
|
+
objectType: 'seat' | 'booth' | 'ga' | 'table';
|
|
2902
|
+
}): {
|
|
2903
|
+
displayLabel?: string;
|
|
2904
|
+
displayType?: string;
|
|
2905
|
+
};
|
|
2829
2906
|
/** Fetch chart, build label maps, mount the renderer, seed statuses, go live. */
|
|
2830
2907
|
render(host: HTMLDivElement): Promise<{
|
|
2831
2908
|
doc: ChartDoc;
|
package/dist/index.d.ts
CHANGED
|
@@ -406,6 +406,11 @@ interface GAAreaObject {
|
|
|
406
406
|
holes?: Point[][];
|
|
407
407
|
capacity: number;
|
|
408
408
|
categoryKey: string;
|
|
409
|
+
/** Corner-rounding radius in chart units (default 0 = sharp corners). Pure
|
|
410
|
+
* presentation — softens the polygon's corners in every renderer without
|
|
411
|
+
* touching capacity, unit identities, or the stored points. Clamped per
|
|
412
|
+
* corner to half the shorter adjacent edge at draw time. */
|
|
413
|
+
cornerRadius?: number;
|
|
409
414
|
/**
|
|
410
415
|
* Durable inventory provenance for a surface produced by Join Areas.
|
|
411
416
|
*
|
|
@@ -606,6 +611,16 @@ interface BoothObject {
|
|
|
606
611
|
width: number;
|
|
607
612
|
height: number;
|
|
608
613
|
rotation: number;
|
|
614
|
+
/**
|
|
615
|
+
* Optional custom outline (closed polygon, absolute chart coordinates) for
|
|
616
|
+
* non-rectangular booths — L-shaped, corner, or island units on expo floors.
|
|
617
|
+
* Absent = the default axis-aligned rectangle described by `width`/`height`/
|
|
618
|
+
* `rotation`. A booth stays exactly ONE atomic sellable unit whatever its
|
|
619
|
+
* outline; `points` is purely geometric. `width`/`height` are retained as the
|
|
620
|
+
* last rectangular size so "Back to rectangle" can restore it. When `points`
|
|
621
|
+
* is present, renderers draw the polygon and ignore `rotation`.
|
|
622
|
+
*/
|
|
623
|
+
points?: Point[];
|
|
609
624
|
categoryKey: string;
|
|
610
625
|
referenceInventorySource?: ReferenceInventorySource;
|
|
611
626
|
}
|
|
@@ -747,6 +762,13 @@ interface TextObject {
|
|
|
747
762
|
id: string;
|
|
748
763
|
/** Persisted provenance for objects created from the venue-icon palette. */
|
|
749
764
|
semanticKind?: 'icon';
|
|
765
|
+
/**
|
|
766
|
+
* Registry key for a vector wayfinding icon (see src/core/icons.ts). Present
|
|
767
|
+
* on modern icon placements; the object then renders as a single-color vector
|
|
768
|
+
* Path instead of `text`. Absent on legacy emoji icons, which keep rendering
|
|
769
|
+
* `text` through the shared glyph path — old charts are never rewritten.
|
|
770
|
+
*/
|
|
771
|
+
iconKey?: string;
|
|
750
772
|
text: string;
|
|
751
773
|
position: Point;
|
|
752
774
|
fontSize: number;
|
|
@@ -1860,6 +1882,8 @@ declare class SeatmapRenderer implements ISeatmapRenderer {
|
|
|
1860
1882
|
private accessGlyphById;
|
|
1861
1883
|
/** Authored free-text nodes obey the same rendered-size visibility floor. */
|
|
1862
1884
|
private freeTextById;
|
|
1885
|
+
/** Vector venue-icon Path nodes + authored size; obey the free-text size floor. */
|
|
1886
|
+
private iconNodeById;
|
|
1863
1887
|
/** Stage/rink landmarks retain a readable screen-space caption at overview. */
|
|
1864
1888
|
private primaryFocalLabels;
|
|
1865
1889
|
/** GA paint and text share price/highlight filter state. */
|
|
@@ -1873,6 +1897,12 @@ declare class SeatmapRenderer implements ISeatmapRenderer {
|
|
|
1873
1897
|
private effSelection;
|
|
1874
1898
|
/** Colorblind-safe mode (Okabe-Ito hues + hollow booked seats). */
|
|
1875
1899
|
private colorblind;
|
|
1900
|
+
/** Stable per-category-KEY colorblind hue (OV-46) — order-independent. */
|
|
1901
|
+
private cbHueByKey;
|
|
1902
|
+
/** OV-45(a): authored row-letter labels for the buyer/preview map, resolved in
|
|
1903
|
+
* world space (matching seat labels) and honouring each row's labelPresentation
|
|
1904
|
+
* (position/rotation/visibility/style). Painted at the seats LOD rung. */
|
|
1905
|
+
private rowLabelPlan;
|
|
1876
1906
|
/** Category order from the doc — the stable index into the CB palette. */
|
|
1877
1907
|
private catOrder;
|
|
1878
1908
|
private selection;
|
|
@@ -2347,11 +2377,17 @@ declare class SeatmapRenderer implements ISeatmapRenderer {
|
|
|
2347
2377
|
*/
|
|
2348
2378
|
private renderSection;
|
|
2349
2379
|
private refreshSectionHeat;
|
|
2350
|
-
/** Recompute a section's
|
|
2380
|
+
/** Recompute a section's availability shading + retained availability text. */
|
|
2351
2381
|
private refreshSectionFill;
|
|
2352
2382
|
/** True when a section/zone is currently in the `closed` event-state. */
|
|
2353
2383
|
private isSectionClosed;
|
|
2354
|
-
/**
|
|
2384
|
+
/** Resolve the four-bucket overview availability state for a section (OV-69).
|
|
2385
|
+
* `closed` (operator) outranks live availability; the availability buckets
|
|
2386
|
+
* only apply to seated sections (GA-only shells have no seat capacity here). */
|
|
2387
|
+
private sectionAvailabilityState;
|
|
2388
|
+
/** Overview shells stay neutral except for the bounded availability shading
|
|
2389
|
+
* (nearly-gone / sold-out) and the operator `closed` slab — never category
|
|
2390
|
+
* or price paint, which is deferred to section focus/seat detail. */
|
|
2355
2391
|
private sectionBlockFill;
|
|
2356
2392
|
/**
|
|
2357
2393
|
* Zone rung: one giant screen-constant label per zone (+ optional "FROM $n"),
|
|
@@ -2502,6 +2538,22 @@ declare class SeatmapRenderer implements ISeatmapRenderer {
|
|
|
2502
2538
|
* debounced cacheSeatLayer() and the synchronous forceDraw() catch-up. */
|
|
2503
2539
|
private rebuildSeatCache;
|
|
2504
2540
|
private cacheSeatLayer;
|
|
2541
|
+
/**
|
|
2542
|
+
* Drop the seat-layer overview bitmap while PRESERVING every descendant's
|
|
2543
|
+
* cached local transform + clientRect.
|
|
2544
|
+
*
|
|
2545
|
+
* Konva's public `Layer.clearCache()` releases the bitmap and then runs a deep
|
|
2546
|
+
* `_clearSelfAndDescendantCache()` that clears those caches on all 14k seat
|
|
2547
|
+
* nodes. Recomputing them on the single frame the melt first reveals a section's
|
|
2548
|
+
* live seats is the ~480ms first-drill stall (OV-80). A camera glide only marks
|
|
2549
|
+
* each seat's ABSOLUTE_TRANSFORM dirty (recomputed lazily at ordinary pan cost)
|
|
2550
|
+
* and never moves a seat's LOCAL transform, so the local caches stay valid —
|
|
2551
|
+
* keeping them lets the first melt paint at pan cost, matching the ~17ms of
|
|
2552
|
+
* every subsequent glide on the same section. Any edit that actually moves a
|
|
2553
|
+
* seat invalidates its own transform cache through the attr setter, so only
|
|
2554
|
+
* still-valid caches survive here.
|
|
2555
|
+
*/
|
|
2556
|
+
private releaseSeatLayerBitmap;
|
|
2505
2557
|
/**
|
|
2506
2558
|
* SYNCHRONOUS repaint that bypasses requestAnimationFrame — see the
|
|
2507
2559
|
* ISeatmapRenderer.forceDraw() contract. Chrome pauses rAF (and therefore
|
|
@@ -2515,6 +2567,15 @@ declare class SeatmapRenderer implements ISeatmapRenderer {
|
|
|
2515
2567
|
*/
|
|
2516
2568
|
forceDraw(): void;
|
|
2517
2569
|
private updateFreeTextVisibility;
|
|
2570
|
+
/** OV-45(a): resolve authored row-letter labels for the buyer/preview map, in
|
|
2571
|
+
* world space, matching the Designer's placement contract (start/end/both/none
|
|
2572
|
+
* preset, a free-drag `position` that wins over the preset, rotation, and
|
|
2573
|
+
* labelStyle colour/size fed through the same auto-contrast guard). Segmented
|
|
2574
|
+
* rows keep their own logical-label handling and are resolved by their owner. */
|
|
2575
|
+
private buildRowLabelPlan;
|
|
2576
|
+
/** Row labels never carry status; the buyer just dims them under the same
|
|
2577
|
+
* category/price filters that dim their seats. */
|
|
2578
|
+
private objectFilteredOut;
|
|
2518
2579
|
private updateLabels;
|
|
2519
2580
|
private handleResize;
|
|
2520
2581
|
private startFpsLoop;
|
|
@@ -2626,6 +2687,7 @@ interface SectionCategory {
|
|
|
2626
2687
|
*/
|
|
2627
2688
|
interface SectionSummary {
|
|
2628
2689
|
id: string;
|
|
2690
|
+
/** Buyer-facing section name (`displayLabel` when set, else the inventory label). */
|
|
2629
2691
|
label: string;
|
|
2630
2692
|
/** Zone label (from ChartDoc.zones); '' when the section has no zone. */
|
|
2631
2693
|
zoneLabel: string;
|
|
@@ -2826,6 +2888,21 @@ declare class PickerController {
|
|
|
2826
2888
|
private idsForLabels;
|
|
2827
2889
|
/** Resolve a physical chair id (or table inventory label) to its table unit. */
|
|
2828
2890
|
tableSelection(seatIdOrLabel: string): TableSelectionDetails | null;
|
|
2891
|
+
/**
|
|
2892
|
+
* Buyer-facing name + type word for a checkout line item, resolved from the
|
|
2893
|
+
* SAME author overrides the tray/tooltip already render. `label` stays the
|
|
2894
|
+
* booking identity; a host builds its own order summary from `displayLabel`/
|
|
2895
|
+
* `displayType` so the buyer sees the designer's copy, not the internal label.
|
|
2896
|
+
* Absent fields = no override (host falls back to `label`).
|
|
2897
|
+
*/
|
|
2898
|
+
lineItemDisplay(item: {
|
|
2899
|
+
label: string;
|
|
2900
|
+
objectId: string;
|
|
2901
|
+
objectType: 'seat' | 'booth' | 'ga' | 'table';
|
|
2902
|
+
}): {
|
|
2903
|
+
displayLabel?: string;
|
|
2904
|
+
displayType?: string;
|
|
2905
|
+
};
|
|
2829
2906
|
/** Fetch chart, build label maps, mount the renderer, seed statuses, go live. */
|
|
2830
2907
|
render(host: HTMLDivElement): Promise<{
|
|
2831
2908
|
doc: ChartDoc;
|