@seatlayer/core 0.22.0 → 0.24.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.d.cts CHANGED
@@ -175,6 +175,16 @@ interface LabelPresentation {
175
175
  style?: 'plain' | 'pill';
176
176
  /** Per-object size/color override for this row's or section's label. */
177
177
  labelStyle?: LabelStyle;
178
+ /**
179
+ * End-position preset for a ROW label — which end(s) of the row show it:
180
+ * - `start` (default/undefined) — the row's numbering-start end (legacy behaviour).
181
+ * - `end` — the far end of the row.
182
+ * - `both` — a label at BOTH ends.
183
+ * - `none` — hidden (kept coherent with `visible: false`).
184
+ * A free-drag `position` overrides the preset (the designer shows a 'custom'
185
+ * state). Ignored for sections (they use `position`/`visible` only).
186
+ */
187
+ positionPreset?: 'start' | 'end' | 'both' | 'none';
178
188
  }
179
189
  /** Brand/venue theming — applied by the renderer in both designer and picker. */
180
190
  interface ChartTheme {
@@ -263,15 +273,42 @@ interface RowObject {
263
273
  rowIndex: number;
264
274
  segmentIndex: number;
265
275
  };
266
- /** First seat number (default 1). */
276
+ /** First seat number (default 1). Roman/letters read it as a 1-based ordinal
277
+ * (start 1 → I / A). */
267
278
  seatLabelStart?: number;
268
- /** Seat numbering within the row (default ltr, step 1). */
279
+ /** Seat numbering within the row (default decimal, ltr, step 1). */
269
280
  seatNumbering?: {
270
281
  /** ltr / rtl number from an end; `center` numbers outward from the middle
271
282
  * (centre seat lowest — the premium-centre theatre convention). */
272
283
  direction: 'ltr' | 'rtl' | 'center';
273
284
  /** 2 = odd/even numbering (1,3,5… — start at 2 for evens). */
274
285
  step?: 1 | 2;
286
+ /**
287
+ * Label scheme for the seat NUMBER part (the row prefix is separate).
288
+ * Default `decimal`. Composition with `direction`/`step`/`seatLabelStart`:
289
+ * - `decimal` 1,2,3 — honours direction + step + start.
290
+ * - `odd` 1,3,5 — odd numbers from the first odd ≥ start.
291
+ * - `even` 2,4,6 — even numbers from the first even ≥ start.
292
+ * - `updown` 1,3,5,…,6,4,2 — odd-up-even-back; REPLACES direction (uses
293
+ * physical left→right order); start shifts.
294
+ * - `roman` I,II,III — honours direction + step + start (uppercase).
295
+ * - `letters-upper` A,B,C…Z,AA — honours direction + step + start.
296
+ * - `letters-lower` a,b,c…z,aa — honours direction + step + start.
297
+ * Like `step`/`direction` today, the scheme changes the seat's inventory
298
+ * label (its booking identity), by design.
299
+ */
300
+ scheme?: 'decimal' | 'odd' | 'even' | 'updown' | 'roman' | 'letters-upper' | 'letters-lower';
301
+ /** Optional prefix prepended to every seat number, e.g. 'R' → 'R1', 'R2'. */
302
+ prefix?: string;
303
+ /**
304
+ * End-at preset ("useEndAt"): the row's numbering ENDS at this value instead
305
+ * of starting at `seatLabelStart`. The start is derived so the last-numbered
306
+ * seat (highest position rank) lands on `endAt`, respecting the scheme's step
307
+ * (odd/even = 2). When set it WINS over the stored `seatLabelStart` (which is
308
+ * left untouched). For letters it is a 1-based number index (26 → last seat
309
+ * 'Z'); `updown` owns its own sequence and ignores `endAt`.
310
+ */
311
+ endAt?: number;
275
312
  };
276
313
  /**
277
314
  * Per-seat exceptions, keyed by seat index (0-based position in the row).
@@ -1052,6 +1089,25 @@ declare const CHART_STORAGE_KEY = "seatmap.chart";
1052
1089
  * document into concrete seat coordinates and computes bounding boxes.
1053
1090
  */
1054
1091
 
1092
+ /**
1093
+ * Expand a parametric row into seat positions.
1094
+ *
1095
+ * Straight (curve === 0): seat i sits at local (i·spacing, 0).
1096
+ *
1097
+ * Curved: seats lie on a circular arc. Per-seat angular step is
1098
+ * `curve/(seatCount-1)`; radius is derived so the chord between neighbours
1099
+ * equals seatSpacing → radius = spacing / (2·sin(step/2)). Seat 0 sits at the
1100
+ * bottom of the arc (local origin) with the circle centre directly above it at
1101
+ * (0,-radius); increasing index sweeps toward +x while the ends rise toward -y,
1102
+ * i.e. positive curve is concave toward -y (a row wrapping a stage above it).
1103
+ * Local points are then rotated by `rotation` and translated to `origin`.
1104
+ *
1105
+ * Numbering (labels only, never geometry): `seatNumbering.direction === 'rtl'`
1106
+ * numbers from the far physical end; `step === 2` produces odd/even numbering
1107
+ * (start at 1 → 1,3,5…; start at 2 → 2,4,6…).
1108
+ */
1109
+ /** Base (pre-override) seat centre per index — shared by expandRow + designer edit mode. */
1110
+ declare function rowSeatPositions(row: RowObject): Point[];
1055
1111
  /**
1056
1112
  * Every seat slot of a row INCLUDING skipped ones (designer seat-edit mode uses
1057
1113
  * this to draw un-skip handles). Overrides (dx/dy/label/categoryKey) are applied
@@ -1071,6 +1127,12 @@ interface RowSeatSlot {
1071
1127
  viewUrl?: string;
1072
1128
  labelStyle?: LabelStyle;
1073
1129
  }
1130
+ /**
1131
+ * The seat NUMBER part of a row seat's label (the row prefix is prepended by the
1132
+ * caller). Applies the row's numbering scheme, direction, step, start and label
1133
+ * prefix. Labels only — never geometry. See `RowObject.seatNumbering.scheme`.
1134
+ */
1135
+ declare function seatLabelPart(row: RowObject, i: number): string;
1074
1136
  declare function expandRowSlots(row: RowObject): RowSeatSlot[];
1075
1137
  declare function expandRow(row: RowObject): ExpandedSeat[];
1076
1138
  /**
@@ -1238,6 +1300,15 @@ declare class SeatmapRenderer implements ISeatmapRenderer {
1238
1300
  private boothLabelById;
1239
1301
  /** Viewport seat labels are rebuilt after each settled camera change. */
1240
1302
  private seatLabelById;
1303
+ /** Coloured accommodation ring per accessible seat (few per chart). */
1304
+ private accessRingById;
1305
+ /** Centred accessibility glyph per accessible seat — shown once the seat is
1306
+ * big enough on-screen (see {@link SEAT_GLYPH_MIN_PX}); the ring is the
1307
+ * smaller-zoom fallback. Kept in a map so zoom toggles touch only the handful
1308
+ * of accessible seats, never all 13k nodes. */
1309
+ private accessGlyphById;
1310
+ /** Whether the accessibility glyph is legible at the current camera scale. */
1311
+ private accessGlyphVisible;
1241
1312
  /** Authored free-text nodes obey the same rendered-size visibility floor. */
1242
1313
  private freeTextById;
1243
1314
  /** Stage/rink landmarks retain a readable screen-space caption at overview. */
@@ -1503,6 +1574,26 @@ declare class SeatmapRenderer implements ISeatmapRenderer {
1503
1574
  private renderSeats;
1504
1575
  /** A booth renders as a click-selectable rounded block (dims from the doc). */
1505
1576
  private renderBoothUnit;
1577
+ /**
1578
+ * Build the centred accessibility glyph for a seat. Sized relative to the seat
1579
+ * radius (so it always fills the marker at any zoom) and given a contrast-aware
1580
+ * fill against the seat's paint — recomputed per state in {@link paintSeat}.
1581
+ */
1582
+ private buildAccessGlyph;
1583
+ /**
1584
+ * Toggle the accessibility glyphs for the current camera scale: shown once the
1585
+ * effective on-screen seat radius clears {@link SEAT_GLYPH_MIN_PX}, otherwise
1586
+ * hidden so only the ring remains. Iterates the (small) accessible-seat set,
1587
+ * never the full node graph, so it is cheap to call on every view change.
1588
+ */
1589
+ private updateAccessGlyphs;
1590
+ /**
1591
+ * Whether an accessible seat's glyph should show for its current status. It is
1592
+ * hidden on seats a buyer cannot take (sold, or another buyer's hold) where the
1593
+ * overlay status cue (diagonal mark / lock) carries the state instead — mirrors
1594
+ * the `unavailable` test in {@link updateLabels} so the two never collide.
1595
+ */
1596
+ private accessGlyphEligible;
1506
1597
  /** The category's display color — Okabe-Ito hue when colorblind-safe is on. */
1507
1598
  private seatBaseColor;
1508
1599
  /** Per-seat authored label size relative to the neutral default (1 = default),
@@ -1770,6 +1861,9 @@ declare function createRenderer(container: HTMLDivElement, opts?: RendererOption
1770
1861
  interface PickerSeat {
1771
1862
  id: string;
1772
1863
  label: string;
1864
+ /** Buyer-facing label (row `displayLabel` applied). Falls back to `label`;
1865
+ * never use for booking — `label` is the inventory/booking identity. */
1866
+ displayLabel?: string;
1773
1867
  categoryKey: string;
1774
1868
  /** Price for the chosen tier when the category has tiers, else the base price. */
1775
1869
  price: number;
@@ -2067,8 +2161,28 @@ declare class PickerController {
2067
2161
  tierId?: string | null;
2068
2162
  ttlMs?: number;
2069
2163
  }): Promise<HoldInfo | null>;
2070
- /** Server-picks `qty` best free seats and holds them atomically. Throws on failure. */
2071
- bestAvailable(qty: number, categoryKey?: string): Promise<HoldInfo | null>;
2164
+ /** True when any seat on the visible chart carries the `premium` commercial
2165
+ * flag gates the buyer widget's "★ Best seats" premium quick-pick (chip is
2166
+ * present-only, exactly like the accessibility filter chips). */
2167
+ hasPremiumSeats(): boolean;
2168
+ /**
2169
+ * Client-side premium pre-pass: find the best contiguous block of `qty`
2170
+ * PREMIUM-flagged free seats (orphan-avoiding, closest to the focal point)
2171
+ * using the local seat geometry + live availability, mirroring the server's
2172
+ * held-back exclusion via the visible (hidden-stripped) chart and current
2173
+ * seat status. Returns a FULL premium block of `qty`, or null when none
2174
+ * exists (the caller then falls back to the normal server pick).
2175
+ */
2176
+ private pickPremiumBlock;
2177
+ /**
2178
+ * Server-picks `qty` best free seats and holds them atomically. Throws on
2179
+ * failure. With `preferPremium`, first tries to hold the best PREMIUM block
2180
+ * locally; when none matches the requested quantity it falls back to the
2181
+ * normal server pick (the widget surfaces a subtle note on that fallback).
2182
+ */
2183
+ bestAvailable(qty: number, categoryKey?: string, opts?: {
2184
+ preferPremium?: boolean;
2185
+ }): Promise<HoldInfo | null>;
2072
2186
  /**
2073
2187
  * Complete a booking. Requires a transport that supports book() (the SDK
2074
2188
  * deliberately does not). `bookingRef` MUST be a real reference from the caller.
@@ -2324,4 +2438,4 @@ declare function formatMoney(amount: number, currency?: string, fractionDigits?:
2324
2438
  /** Bare symbol for input adornments ("€", "$", "₹"). */
2325
2439
  declare function currencySymbol(currency?: string): string;
2326
2440
 
2327
- export { ACCESSIBILITY_RING_COLOR, ACCESSIBILITY_TYPES, type AccessibilityMeta, type AccessibilityType, type AvailabilityRule, type BoothObject, CHART_STORAGE_KEY, type Category, type CategoryTier, type ChartDoc, type ChartObject, type ChartReferenceImage, type ChartTheme, type CubicPath, DEFAULT_CURRENCY, type DecorImageObject, type Dict, type ExpandedSeat, type Floor, type GAAreaObject, type HoldConflict, type HoldInfo, type HoldSelectionRequest, type HoldServerItem, type ISeatmapRenderer, LABEL_STYLE_MAX_SIZE, LABEL_STYLE_MIN_SIZE, type LabelPresentation, type LabelStyle, type Locale, type LodRung, MAX_EVENT_INVENTORY, MAX_GA_CAPACITY, type PanoramaResult, type PickerCallbacks, PickerController, type PickerOptions, type PickerSeat, type PickerTransport, type Point, type ReferenceAccessibilitySource, type ReferenceCalibration, type ReferenceCategorySource, type ReferenceDerivedScale, type ReferenceInventoryExclusionSource, type ReferenceInventorySource, type RenderedBookableLabelEvidence, type RenderedFreeTextEvidence, type RenderedGAAreaEvidence, type RenderedHierarchyLabelEvidence, type RenderedLabelHiddenReason, type RendererCallbacks, type RendererOptions, type RendererQualityEvidence, type RowObject, type RowSeatSlot, SUPPORTED_LOCALES, type SeatCommercialAttributes, type SeatHoverDetails, type SeatOverride, type SeatStatus, SeatmapRenderer, type SectionCategory, type SectionNode, type SectionObject, type SectionOutlinePath, type SectionPathSegment, type SectionSummary, type SelectionLayer, type ShapeObject, type TableObject, type TextObject, UNGROUPED_ID, type ZoneDef, accessibilityMeta, accessibilityRingColor, allObjects, applyHidden, chartBounds, computeSections, createRenderer, currencySymbol, expandBooth, expandChart, expandRow, expandRowSlots, expandTable, floorObjects, floorsOf, formatDate, formatMoney, gaAreasOf, gaUnitLabel, gaUnitLabels, generateSeatPanorama, generateSeatThumb, getLocale, hiddenObjectIds, isGaUnitLabel, isSectionHidden, layerOf, loadLocale, objectCenter, pointInPolygon, pointInPolygonWithHoles, polygonLabelPoint, resolveLocale, setLocale, setMoneyLocale, setStringOverrides, stackFloors, t, tCount };
2441
+ export { ACCESSIBILITY_RING_COLOR, ACCESSIBILITY_TYPES, type AccessibilityMeta, type AccessibilityType, type AvailabilityRule, type BoothObject, CHART_STORAGE_KEY, type Category, type CategoryTier, type ChartDoc, type ChartObject, type ChartReferenceImage, type ChartTheme, type CubicPath, DEFAULT_CURRENCY, type DecorImageObject, type Dict, type ExpandedSeat, type Floor, type GAAreaObject, type HoldConflict, type HoldInfo, type HoldSelectionRequest, type HoldServerItem, type ISeatmapRenderer, LABEL_STYLE_MAX_SIZE, LABEL_STYLE_MIN_SIZE, type LabelPresentation, type LabelStyle, type Locale, type LodRung, MAX_EVENT_INVENTORY, MAX_GA_CAPACITY, type PanoramaResult, type PickerCallbacks, PickerController, type PickerOptions, type PickerSeat, type PickerTransport, type Point, type ReferenceAccessibilitySource, type ReferenceCalibration, type ReferenceCategorySource, type ReferenceDerivedScale, type ReferenceInventoryExclusionSource, type ReferenceInventorySource, type RenderedBookableLabelEvidence, type RenderedFreeTextEvidence, type RenderedGAAreaEvidence, type RenderedHierarchyLabelEvidence, type RenderedLabelHiddenReason, type RendererCallbacks, type RendererOptions, type RendererQualityEvidence, type RowObject, type RowSeatSlot, SUPPORTED_LOCALES, type SeatCommercialAttributes, type SeatHoverDetails, type SeatOverride, type SeatStatus, SeatmapRenderer, type SectionCategory, type SectionNode, type SectionObject, type SectionOutlinePath, type SectionPathSegment, type SectionSummary, type SelectionLayer, type ShapeObject, type TableObject, type TextObject, UNGROUPED_ID, type ZoneDef, accessibilityMeta, accessibilityRingColor, allObjects, applyHidden, chartBounds, computeSections, createRenderer, currencySymbol, expandBooth, expandChart, expandRow, expandRowSlots, expandTable, floorObjects, floorsOf, formatDate, formatMoney, gaAreasOf, gaUnitLabel, gaUnitLabels, generateSeatPanorama, generateSeatThumb, getLocale, hiddenObjectIds, isGaUnitLabel, isSectionHidden, layerOf, loadLocale, objectCenter, pointInPolygon, pointInPolygonWithHoles, polygonLabelPoint, resolveLocale, rowSeatPositions, seatLabelPart, setLocale, setMoneyLocale, setStringOverrides, stackFloors, t, tCount };
package/dist/index.d.ts CHANGED
@@ -175,6 +175,16 @@ interface LabelPresentation {
175
175
  style?: 'plain' | 'pill';
176
176
  /** Per-object size/color override for this row's or section's label. */
177
177
  labelStyle?: LabelStyle;
178
+ /**
179
+ * End-position preset for a ROW label — which end(s) of the row show it:
180
+ * - `start` (default/undefined) — the row's numbering-start end (legacy behaviour).
181
+ * - `end` — the far end of the row.
182
+ * - `both` — a label at BOTH ends.
183
+ * - `none` — hidden (kept coherent with `visible: false`).
184
+ * A free-drag `position` overrides the preset (the designer shows a 'custom'
185
+ * state). Ignored for sections (they use `position`/`visible` only).
186
+ */
187
+ positionPreset?: 'start' | 'end' | 'both' | 'none';
178
188
  }
179
189
  /** Brand/venue theming — applied by the renderer in both designer and picker. */
180
190
  interface ChartTheme {
@@ -263,15 +273,42 @@ interface RowObject {
263
273
  rowIndex: number;
264
274
  segmentIndex: number;
265
275
  };
266
- /** First seat number (default 1). */
276
+ /** First seat number (default 1). Roman/letters read it as a 1-based ordinal
277
+ * (start 1 → I / A). */
267
278
  seatLabelStart?: number;
268
- /** Seat numbering within the row (default ltr, step 1). */
279
+ /** Seat numbering within the row (default decimal, ltr, step 1). */
269
280
  seatNumbering?: {
270
281
  /** ltr / rtl number from an end; `center` numbers outward from the middle
271
282
  * (centre seat lowest — the premium-centre theatre convention). */
272
283
  direction: 'ltr' | 'rtl' | 'center';
273
284
  /** 2 = odd/even numbering (1,3,5… — start at 2 for evens). */
274
285
  step?: 1 | 2;
286
+ /**
287
+ * Label scheme for the seat NUMBER part (the row prefix is separate).
288
+ * Default `decimal`. Composition with `direction`/`step`/`seatLabelStart`:
289
+ * - `decimal` 1,2,3 — honours direction + step + start.
290
+ * - `odd` 1,3,5 — odd numbers from the first odd ≥ start.
291
+ * - `even` 2,4,6 — even numbers from the first even ≥ start.
292
+ * - `updown` 1,3,5,…,6,4,2 — odd-up-even-back; REPLACES direction (uses
293
+ * physical left→right order); start shifts.
294
+ * - `roman` I,II,III — honours direction + step + start (uppercase).
295
+ * - `letters-upper` A,B,C…Z,AA — honours direction + step + start.
296
+ * - `letters-lower` a,b,c…z,aa — honours direction + step + start.
297
+ * Like `step`/`direction` today, the scheme changes the seat's inventory
298
+ * label (its booking identity), by design.
299
+ */
300
+ scheme?: 'decimal' | 'odd' | 'even' | 'updown' | 'roman' | 'letters-upper' | 'letters-lower';
301
+ /** Optional prefix prepended to every seat number, e.g. 'R' → 'R1', 'R2'. */
302
+ prefix?: string;
303
+ /**
304
+ * End-at preset ("useEndAt"): the row's numbering ENDS at this value instead
305
+ * of starting at `seatLabelStart`. The start is derived so the last-numbered
306
+ * seat (highest position rank) lands on `endAt`, respecting the scheme's step
307
+ * (odd/even = 2). When set it WINS over the stored `seatLabelStart` (which is
308
+ * left untouched). For letters it is a 1-based number index (26 → last seat
309
+ * 'Z'); `updown` owns its own sequence and ignores `endAt`.
310
+ */
311
+ endAt?: number;
275
312
  };
276
313
  /**
277
314
  * Per-seat exceptions, keyed by seat index (0-based position in the row).
@@ -1052,6 +1089,25 @@ declare const CHART_STORAGE_KEY = "seatmap.chart";
1052
1089
  * document into concrete seat coordinates and computes bounding boxes.
1053
1090
  */
1054
1091
 
1092
+ /**
1093
+ * Expand a parametric row into seat positions.
1094
+ *
1095
+ * Straight (curve === 0): seat i sits at local (i·spacing, 0).
1096
+ *
1097
+ * Curved: seats lie on a circular arc. Per-seat angular step is
1098
+ * `curve/(seatCount-1)`; radius is derived so the chord between neighbours
1099
+ * equals seatSpacing → radius = spacing / (2·sin(step/2)). Seat 0 sits at the
1100
+ * bottom of the arc (local origin) with the circle centre directly above it at
1101
+ * (0,-radius); increasing index sweeps toward +x while the ends rise toward -y,
1102
+ * i.e. positive curve is concave toward -y (a row wrapping a stage above it).
1103
+ * Local points are then rotated by `rotation` and translated to `origin`.
1104
+ *
1105
+ * Numbering (labels only, never geometry): `seatNumbering.direction === 'rtl'`
1106
+ * numbers from the far physical end; `step === 2` produces odd/even numbering
1107
+ * (start at 1 → 1,3,5…; start at 2 → 2,4,6…).
1108
+ */
1109
+ /** Base (pre-override) seat centre per index — shared by expandRow + designer edit mode. */
1110
+ declare function rowSeatPositions(row: RowObject): Point[];
1055
1111
  /**
1056
1112
  * Every seat slot of a row INCLUDING skipped ones (designer seat-edit mode uses
1057
1113
  * this to draw un-skip handles). Overrides (dx/dy/label/categoryKey) are applied
@@ -1071,6 +1127,12 @@ interface RowSeatSlot {
1071
1127
  viewUrl?: string;
1072
1128
  labelStyle?: LabelStyle;
1073
1129
  }
1130
+ /**
1131
+ * The seat NUMBER part of a row seat's label (the row prefix is prepended by the
1132
+ * caller). Applies the row's numbering scheme, direction, step, start and label
1133
+ * prefix. Labels only — never geometry. See `RowObject.seatNumbering.scheme`.
1134
+ */
1135
+ declare function seatLabelPart(row: RowObject, i: number): string;
1074
1136
  declare function expandRowSlots(row: RowObject): RowSeatSlot[];
1075
1137
  declare function expandRow(row: RowObject): ExpandedSeat[];
1076
1138
  /**
@@ -1238,6 +1300,15 @@ declare class SeatmapRenderer implements ISeatmapRenderer {
1238
1300
  private boothLabelById;
1239
1301
  /** Viewport seat labels are rebuilt after each settled camera change. */
1240
1302
  private seatLabelById;
1303
+ /** Coloured accommodation ring per accessible seat (few per chart). */
1304
+ private accessRingById;
1305
+ /** Centred accessibility glyph per accessible seat — shown once the seat is
1306
+ * big enough on-screen (see {@link SEAT_GLYPH_MIN_PX}); the ring is the
1307
+ * smaller-zoom fallback. Kept in a map so zoom toggles touch only the handful
1308
+ * of accessible seats, never all 13k nodes. */
1309
+ private accessGlyphById;
1310
+ /** Whether the accessibility glyph is legible at the current camera scale. */
1311
+ private accessGlyphVisible;
1241
1312
  /** Authored free-text nodes obey the same rendered-size visibility floor. */
1242
1313
  private freeTextById;
1243
1314
  /** Stage/rink landmarks retain a readable screen-space caption at overview. */
@@ -1503,6 +1574,26 @@ declare class SeatmapRenderer implements ISeatmapRenderer {
1503
1574
  private renderSeats;
1504
1575
  /** A booth renders as a click-selectable rounded block (dims from the doc). */
1505
1576
  private renderBoothUnit;
1577
+ /**
1578
+ * Build the centred accessibility glyph for a seat. Sized relative to the seat
1579
+ * radius (so it always fills the marker at any zoom) and given a contrast-aware
1580
+ * fill against the seat's paint — recomputed per state in {@link paintSeat}.
1581
+ */
1582
+ private buildAccessGlyph;
1583
+ /**
1584
+ * Toggle the accessibility glyphs for the current camera scale: shown once the
1585
+ * effective on-screen seat radius clears {@link SEAT_GLYPH_MIN_PX}, otherwise
1586
+ * hidden so only the ring remains. Iterates the (small) accessible-seat set,
1587
+ * never the full node graph, so it is cheap to call on every view change.
1588
+ */
1589
+ private updateAccessGlyphs;
1590
+ /**
1591
+ * Whether an accessible seat's glyph should show for its current status. It is
1592
+ * hidden on seats a buyer cannot take (sold, or another buyer's hold) where the
1593
+ * overlay status cue (diagonal mark / lock) carries the state instead — mirrors
1594
+ * the `unavailable` test in {@link updateLabels} so the two never collide.
1595
+ */
1596
+ private accessGlyphEligible;
1506
1597
  /** The category's display color — Okabe-Ito hue when colorblind-safe is on. */
1507
1598
  private seatBaseColor;
1508
1599
  /** Per-seat authored label size relative to the neutral default (1 = default),
@@ -1770,6 +1861,9 @@ declare function createRenderer(container: HTMLDivElement, opts?: RendererOption
1770
1861
  interface PickerSeat {
1771
1862
  id: string;
1772
1863
  label: string;
1864
+ /** Buyer-facing label (row `displayLabel` applied). Falls back to `label`;
1865
+ * never use for booking — `label` is the inventory/booking identity. */
1866
+ displayLabel?: string;
1773
1867
  categoryKey: string;
1774
1868
  /** Price for the chosen tier when the category has tiers, else the base price. */
1775
1869
  price: number;
@@ -2067,8 +2161,28 @@ declare class PickerController {
2067
2161
  tierId?: string | null;
2068
2162
  ttlMs?: number;
2069
2163
  }): Promise<HoldInfo | null>;
2070
- /** Server-picks `qty` best free seats and holds them atomically. Throws on failure. */
2071
- bestAvailable(qty: number, categoryKey?: string): Promise<HoldInfo | null>;
2164
+ /** True when any seat on the visible chart carries the `premium` commercial
2165
+ * flag gates the buyer widget's "★ Best seats" premium quick-pick (chip is
2166
+ * present-only, exactly like the accessibility filter chips). */
2167
+ hasPremiumSeats(): boolean;
2168
+ /**
2169
+ * Client-side premium pre-pass: find the best contiguous block of `qty`
2170
+ * PREMIUM-flagged free seats (orphan-avoiding, closest to the focal point)
2171
+ * using the local seat geometry + live availability, mirroring the server's
2172
+ * held-back exclusion via the visible (hidden-stripped) chart and current
2173
+ * seat status. Returns a FULL premium block of `qty`, or null when none
2174
+ * exists (the caller then falls back to the normal server pick).
2175
+ */
2176
+ private pickPremiumBlock;
2177
+ /**
2178
+ * Server-picks `qty` best free seats and holds them atomically. Throws on
2179
+ * failure. With `preferPremium`, first tries to hold the best PREMIUM block
2180
+ * locally; when none matches the requested quantity it falls back to the
2181
+ * normal server pick (the widget surfaces a subtle note on that fallback).
2182
+ */
2183
+ bestAvailable(qty: number, categoryKey?: string, opts?: {
2184
+ preferPremium?: boolean;
2185
+ }): Promise<HoldInfo | null>;
2072
2186
  /**
2073
2187
  * Complete a booking. Requires a transport that supports book() (the SDK
2074
2188
  * deliberately does not). `bookingRef` MUST be a real reference from the caller.
@@ -2324,4 +2438,4 @@ declare function formatMoney(amount: number, currency?: string, fractionDigits?:
2324
2438
  /** Bare symbol for input adornments ("€", "$", "₹"). */
2325
2439
  declare function currencySymbol(currency?: string): string;
2326
2440
 
2327
- export { ACCESSIBILITY_RING_COLOR, ACCESSIBILITY_TYPES, type AccessibilityMeta, type AccessibilityType, type AvailabilityRule, type BoothObject, CHART_STORAGE_KEY, type Category, type CategoryTier, type ChartDoc, type ChartObject, type ChartReferenceImage, type ChartTheme, type CubicPath, DEFAULT_CURRENCY, type DecorImageObject, type Dict, type ExpandedSeat, type Floor, type GAAreaObject, type HoldConflict, type HoldInfo, type HoldSelectionRequest, type HoldServerItem, type ISeatmapRenderer, LABEL_STYLE_MAX_SIZE, LABEL_STYLE_MIN_SIZE, type LabelPresentation, type LabelStyle, type Locale, type LodRung, MAX_EVENT_INVENTORY, MAX_GA_CAPACITY, type PanoramaResult, type PickerCallbacks, PickerController, type PickerOptions, type PickerSeat, type PickerTransport, type Point, type ReferenceAccessibilitySource, type ReferenceCalibration, type ReferenceCategorySource, type ReferenceDerivedScale, type ReferenceInventoryExclusionSource, type ReferenceInventorySource, type RenderedBookableLabelEvidence, type RenderedFreeTextEvidence, type RenderedGAAreaEvidence, type RenderedHierarchyLabelEvidence, type RenderedLabelHiddenReason, type RendererCallbacks, type RendererOptions, type RendererQualityEvidence, type RowObject, type RowSeatSlot, SUPPORTED_LOCALES, type SeatCommercialAttributes, type SeatHoverDetails, type SeatOverride, type SeatStatus, SeatmapRenderer, type SectionCategory, type SectionNode, type SectionObject, type SectionOutlinePath, type SectionPathSegment, type SectionSummary, type SelectionLayer, type ShapeObject, type TableObject, type TextObject, UNGROUPED_ID, type ZoneDef, accessibilityMeta, accessibilityRingColor, allObjects, applyHidden, chartBounds, computeSections, createRenderer, currencySymbol, expandBooth, expandChart, expandRow, expandRowSlots, expandTable, floorObjects, floorsOf, formatDate, formatMoney, gaAreasOf, gaUnitLabel, gaUnitLabels, generateSeatPanorama, generateSeatThumb, getLocale, hiddenObjectIds, isGaUnitLabel, isSectionHidden, layerOf, loadLocale, objectCenter, pointInPolygon, pointInPolygonWithHoles, polygonLabelPoint, resolveLocale, setLocale, setMoneyLocale, setStringOverrides, stackFloors, t, tCount };
2441
+ export { ACCESSIBILITY_RING_COLOR, ACCESSIBILITY_TYPES, type AccessibilityMeta, type AccessibilityType, type AvailabilityRule, type BoothObject, CHART_STORAGE_KEY, type Category, type CategoryTier, type ChartDoc, type ChartObject, type ChartReferenceImage, type ChartTheme, type CubicPath, DEFAULT_CURRENCY, type DecorImageObject, type Dict, type ExpandedSeat, type Floor, type GAAreaObject, type HoldConflict, type HoldInfo, type HoldSelectionRequest, type HoldServerItem, type ISeatmapRenderer, LABEL_STYLE_MAX_SIZE, LABEL_STYLE_MIN_SIZE, type LabelPresentation, type LabelStyle, type Locale, type LodRung, MAX_EVENT_INVENTORY, MAX_GA_CAPACITY, type PanoramaResult, type PickerCallbacks, PickerController, type PickerOptions, type PickerSeat, type PickerTransport, type Point, type ReferenceAccessibilitySource, type ReferenceCalibration, type ReferenceCategorySource, type ReferenceDerivedScale, type ReferenceInventoryExclusionSource, type ReferenceInventorySource, type RenderedBookableLabelEvidence, type RenderedFreeTextEvidence, type RenderedGAAreaEvidence, type RenderedHierarchyLabelEvidence, type RenderedLabelHiddenReason, type RendererCallbacks, type RendererOptions, type RendererQualityEvidence, type RowObject, type RowSeatSlot, SUPPORTED_LOCALES, type SeatCommercialAttributes, type SeatHoverDetails, type SeatOverride, type SeatStatus, SeatmapRenderer, type SectionCategory, type SectionNode, type SectionObject, type SectionOutlinePath, type SectionPathSegment, type SectionSummary, type SelectionLayer, type ShapeObject, type TableObject, type TextObject, UNGROUPED_ID, type ZoneDef, accessibilityMeta, accessibilityRingColor, allObjects, applyHidden, chartBounds, computeSections, createRenderer, currencySymbol, expandBooth, expandChart, expandRow, expandRowSlots, expandTable, floorObjects, floorsOf, formatDate, formatMoney, gaAreasOf, gaUnitLabel, gaUnitLabels, generateSeatPanorama, generateSeatThumb, getLocale, hiddenObjectIds, isGaUnitLabel, isSectionHidden, layerOf, loadLocale, objectCenter, pointInPolygon, pointInPolygonWithHoles, polygonLabelPoint, resolveLocale, rowSeatPositions, seatLabelPart, setLocale, setMoneyLocale, setStringOverrides, stackFloors, t, tCount };