@seatlayer/core 0.58.0 → 0.60.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.
Files changed (104) hide show
  1. package/dist/ar-H46G25IW.js +1 -0
  2. package/dist/be-X2N4CNF6.js +1 -0
  3. package/dist/bg-WAFRHN4U.js +1 -0
  4. package/dist/ca-KJY6UBX2.js +1 -0
  5. package/dist/{categoryInventory-BwarniiK.d.ts → categoryInventory-B-0p5PBr.d.ts} +1 -1
  6. package/dist/{categoryInventory-D3qPwfKz.d.cts → categoryInventory-DjFHXtp6.d.cts} +1 -1
  7. package/dist/{chunk-4BVXDBFE.js → chunk-ATFAQDPR.js} +1 -1
  8. package/dist/chunk-CNCFI5RT.js +1 -0
  9. package/dist/chunk-FOYQOIWG.js +1 -0
  10. package/dist/{chunk-66HGMU7D.js → chunk-IZTHA3X2.js} +1 -1
  11. package/dist/{chunk-N4CBOQFB.js → chunk-P2NJ6UO6.js} +1 -1
  12. package/dist/chunk-T2LWVOQ3.js +1 -0
  13. package/dist/{chunk-6XJN4REG.js → chunk-VI3IZS2B.js} +1 -1
  14. package/dist/{chunk-IRFG5DVH.js → chunk-VOJMGPDK.js} +1 -1
  15. package/dist/{chunk-PMU3VPNK.js → chunk-XU73MULJ.js} +1 -1
  16. package/dist/core/cdnAsset.cjs +1 -0
  17. package/dist/core/cdnAsset.d.cts +35 -0
  18. package/dist/core/cdnAsset.d.ts +35 -0
  19. package/dist/core/cdnAsset.js +1 -0
  20. package/dist/core/chart-ops/index.cjs +1 -1
  21. package/dist/core/chart-ops/index.d.cts +5 -5
  22. package/dist/core/chart-ops/index.d.ts +5 -5
  23. package/dist/core/chart-ops/index.js +1 -1
  24. package/dist/core/inventory/index.cjs +1 -1
  25. package/dist/core/inventory/index.d.cts +4 -4
  26. package/dist/core/inventory/index.d.ts +4 -4
  27. package/dist/core/inventory/index.js +1 -1
  28. package/dist/core/layout/index.cjs +1 -1
  29. package/dist/core/layout/index.d.cts +4 -4
  30. package/dist/core/layout/index.d.ts +4 -4
  31. package/dist/core/layout/index.js +1 -1
  32. package/dist/core/quality/index.d.cts +3 -3
  33. package/dist/core/quality/index.d.ts +3 -3
  34. package/dist/core/render-assets/index.d.cts +1 -1
  35. package/dist/core/render-assets/index.d.ts +1 -1
  36. package/dist/core/seatConfidence.d.cts +1 -1
  37. package/dist/core/seatConfidence.d.ts +1 -1
  38. package/dist/core/sections/index.cjs +1 -1
  39. package/dist/core/sections/index.d.cts +5 -5
  40. package/dist/core/sections/index.d.ts +5 -5
  41. package/dist/core/sections/index.js +1 -1
  42. package/dist/cs-6DGE2CXL.js +1 -0
  43. package/dist/cy-IN3H2JGF.js +1 -0
  44. package/dist/da-CW77LCG4.js +1 -0
  45. package/dist/{de-JS2HQ675.js → de-BTL7PM4X.js} +1 -1
  46. package/dist/el-TWE62U4P.js +1 -0
  47. package/dist/es-EJCQGGF7.js +1 -0
  48. package/dist/et-UQ6VFRG2.js +1 -0
  49. package/dist/fa-A5636YDV.js +1 -0
  50. package/dist/fi-6YNSAFLB.js +1 -0
  51. package/dist/fr-TGUAIAOM.js +1 -0
  52. package/dist/he-PAFZSFIR.js +1 -0
  53. package/dist/hr-SIQR4W7D.js +1 -0
  54. package/dist/hu-YBOAMZ2D.js +1 -0
  55. package/dist/index.cjs +1 -1
  56. package/dist/index.d.cts +125 -41
  57. package/dist/index.d.ts +125 -41
  58. package/dist/index.js +1 -1
  59. package/dist/it-KCSKVAKE.js +1 -0
  60. package/dist/ja-4454OUK5.js +1 -0
  61. package/dist/ku-JPB5LQ72.js +1 -0
  62. package/dist/{labeling-BmCzW50y.d.ts → labeling-BPCTQfDG.d.ts} +1 -1
  63. package/dist/{labeling-VfJBEOn0.d.cts → labeling-iVwhgoip.d.cts} +1 -1
  64. package/dist/{layout-ClQkmixY.d.ts → layout-D-R46h1m.d.ts} +40 -4
  65. package/dist/{layout-Dlv5bIf2.d.cts → layout-Vk2ZGdMS.d.cts} +40 -4
  66. package/dist/localeLoaders-KUIWB7O3.js +1 -0
  67. package/dist/lt-54TNW6YF.js +1 -0
  68. package/dist/lv-TJ75JL4U.js +1 -0
  69. package/dist/nl-B67UFSMM.js +1 -0
  70. package/dist/no-6JQSRSCX.js +1 -0
  71. package/dist/pl-MKZX6GFZ.js +1 -0
  72. package/dist/pt-F2GLS7QA.js +1 -0
  73. package/dist/{renderedQuality-B3jgdgPO.d.ts → renderedQuality-CsXNQCCH.d.ts} +1 -1
  74. package/dist/{renderedQuality-bDkUOyBL.d.cts → renderedQuality-h9RvUWMo.d.cts} +1 -1
  75. package/dist/{renderer-B_g-W_QB.d.ts → renderer-Bo9JzqMA.d.ts} +46 -8
  76. package/dist/{renderer-DySMcKAR.d.cts → renderer-QnB3a1yh.d.cts} +46 -8
  77. package/dist/ro-2WKWAK7S.js +1 -0
  78. package/dist/ru-I7I76LMP.js +1 -0
  79. package/dist/{sections-DIzgtDjF.d.ts → sections-9_Ka3i-z.d.ts} +1 -1
  80. package/dist/{sections-Dna1nZgR.d.cts → sections-Dmjtj1BQ.d.cts} +1 -1
  81. package/dist/{segmentedRowModel-COXw4GCh.d.ts → segmentedRowModel-CO6Jogaa.d.ts} +1 -1
  82. package/dist/{segmentedRowModel-BNXEUeHp.d.cts → segmentedRowModel-s157HmRp.d.cts} +1 -1
  83. package/dist/sk-6ERFVKXJ.js +1 -0
  84. package/dist/sl-AVE6GE3D.js +1 -0
  85. package/dist/sr-D5KFFJNW.js +1 -0
  86. package/dist/sv-JJ7HXVOK.js +1 -0
  87. package/dist/{ticketRestrictions-CzchbX_o.d.cts → ticketRestrictions-DetdPbsL.d.cts} +2 -2
  88. package/dist/{ticketRestrictions-DaYOCpEw.d.ts → ticketRestrictions-EJTEWPGN.d.ts} +2 -2
  89. package/dist/tr-KKJMU4QY.js +1 -0
  90. package/dist/{types-DTSG6_Hq.d.cts → types-Db9rXT14.d.cts} +155 -1
  91. package/dist/{types-DTSG6_Hq.d.ts → types-Db9rXT14.d.ts} +155 -1
  92. package/dist/uk-KX5ZFXAR.js +1 -0
  93. package/dist/view3d/crossfade/panorama.d.cts +1 -1
  94. package/dist/view3d/crossfade/panorama.d.ts +1 -1
  95. package/dist/view3d/index.cjs +21 -21
  96. package/dist/view3d/index.d.cts +2 -2
  97. package/dist/view3d/index.d.ts +2 -2
  98. package/dist/view3d/index.js +23 -23
  99. package/dist/zh-Hans-TTCOG4UW.js +1 -0
  100. package/dist/zh-Hant-37V5VMCE.js +1 -0
  101. package/package.json +19 -2
  102. package/dist/chunk-GHJUDU3U.js +0 -1
  103. package/dist/es-XJUREIJL.js +0 -1
  104. package/dist/fr-CAT46QLZ.js +0 -1
package/dist/index.d.cts CHANGED
@@ -1,13 +1,13 @@
1
- import { C as ChartDoc, P as Point, A as AccessibilityType, l as CategoryTier, f as SeatCommercialAttributes } from './types-DTSG6_Hq.cjs';
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.cjs';
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-Dlv5bIf2.cjs';
4
- import { c as TicketSelectionIssue } from './ticketRestrictions-CzchbX_o.cjs';
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-CzchbX_o.cjs';
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-Dna1nZgR.cjs';
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-bDkUOyBL.cjs';
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-DySMcKAR.cjs';
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-DySMcKAR.cjs';
10
- import './segmentedRowModel-BNXEUeHp.cjs';
1
+ import { C as ChartDoc, P as Point, A as AccessibilityType, l as CategoryTier, f as SeatCommercialAttributes } from './types-Db9rXT14.cjs';
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 ReferenceEnrichmentStatus, W as ReferenceExtractEmptyReason, X as ReferenceExtractEnrichment, Y as ReferenceExtractInput, Z as ReferenceExtractProposal, _ as ReferenceExtractRegionSeats, $ as ReferenceInventoryExclusionSource, a0 as ReferenceInventorySource, a1 as ReferenceScanProposal, a2 as ReferenceScanRowProposal, a3 as ReferenceScanSectionProposal, a4 as ReferenceSeatSeed, a5 as ReferenceSectionTraceBatchInput, a6 as ReferenceSectionTraceBatchProposal, a7 as ReferenceSectionTraceInput, a8 as ReferenceSectionTraceProposal, g as ResolvedSeatConfidenceEvidence, R as RowObject, a9 as SEAT_COMMERCIAL_MARKS, aa as SURROUNDINGS_SHAPE_ROLES, ab as SeatCommercialMark, ac as SeatCommercialMeta, ad as SeatConfidenceCoverage, ae as SeatConfidenceEvidence, af as SeatConfidenceModelLevel, ag as SeatConfidenceModeledTarget, ah as SeatConfidenceRealityLevel, S as SeatOverride, h as SeatViewCoverage, a as SeatViewMetadata, d as SectionObject, i as SectionOutlinePath, j as SectionPathSegment, ai as SelectionLayer, n as ShapeLineCap, o as ShapeLineEnding, p as ShapeLineJoin, q as ShapeObject, T as TableObject, aj as TextAlignment, ak as TextBackground, s as TextObject, al as TicketTierApplicability, am as TicketTierEvidence, an as TicketTierRestriction, ao as ZoneDef, ap as accessibilityMeta, aq as accessibilityRingColor, ar as layerOf, as as seatCommercialMeta } from './types-Db9rXT14.cjs';
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 floorsShareFootprint, m as layoutFloorOverview, n as layoutFloorRings, o as objectCenter, p as owningSectionForObject, q as pointInPolygon, r as pointInPolygonWithHoles, s as polygonLabelPoint, t as rowInventoryCount, u as rowSeatPositions, v as stackFloors, w as tableInventoryCount, x as tableSeatCountsBySide, y as translateObject } from './layout-Vk2ZGdMS.cjs';
4
+ import { c as TicketSelectionIssue } from './ticketRestrictions-DetdPbsL.cjs';
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-DetdPbsL.cjs';
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-Dmjtj1BQ.cjs';
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-h9RvUWMo.cjs';
8
+ import { I as ISeatmapRenderer, b as RendererOptions, S as SeatStatus, E as ExpandedSeat, G as GAAreaState, c as RendererViewMode, d as RendererMinimapSnapshot, L as LodRung, R as RendererQualityEvidence, e as RendererCallbacks } from './renderer-QnB3a1yh.cjs';
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-QnB3a1yh.cjs';
10
+ import './segmentedRowModel-s157HmRp.cjs';
11
11
 
12
12
  declare class SeatmapRenderer implements ISeatmapRenderer {
13
13
  private container;
@@ -324,10 +324,12 @@ declare class SeatmapRenderer implements ISeatmapRenderer {
324
324
  * widget resolves which categories fall inside the buyer's chosen band.
325
325
  */
326
326
  setCategoryFilter(keys: string[] | null): void;
327
- private gaCategoryDimmed;
328
327
  /** Keep GA paint and its two labels in the same legend/price-filter state. */
329
328
  private applyGAFilterState;
330
329
  private paintGAStateForView;
330
+ /** Host-pushed GA availability / pending quantity — see {@link paintGAState}. */
331
+ setGAStates(states: Record<string, GAAreaState>): void;
332
+ setGAState(areaId: string, state: GAAreaState): void;
331
333
  /** Frame the currently available inventory that survived a buyer price
332
334
  * filter. Clearing the filter glides back to the full venue. */
333
335
  focusCategories(keys: string[] | null): void;
@@ -457,8 +459,9 @@ declare class SeatmapRenderer implements ISeatmapRenderer {
457
459
  * the `unavailable` test in {@link updateLabels} so the two never collide.
458
460
  */
459
461
  private accessGlyphEligible;
460
- /** The category's display color — Okabe-Ito hue when colorblind-safe is on. */
461
- private seatBaseColor;
462
+ /** The category's on-screen color — Okabe-Ito hue in colorblind-safe mode.
463
+ * Public because a legend must ask; see the contract for why. */
464
+ categoryDisplayColor(categoryKey: string): string;
462
465
  /** Per-seat authored label size relative to the neutral default (1 = default),
463
466
  * mirroring the section convention (labelStyle.size ?? 18) / 18. Only real
464
467
  * seats carry labelStyle, so booths and unstyled seats resolve to 1. */
@@ -1213,6 +1216,8 @@ declare class PickerController {
1213
1216
  private selectableSeatIds;
1214
1217
  private lastSelectionValidity;
1215
1218
  private renderer;
1219
+ /** Host-tracked pending GA quantity per area id (the widget cart's chips). */
1220
+ private gaSelected;
1216
1221
  private _doc;
1217
1222
  /** Section/zone ids hidden from buyers this event (3.3) — seats vanish, not grey. */
1218
1223
  private hidden;
@@ -1404,6 +1409,13 @@ declare class PickerController {
1404
1409
  /** Seat ids belonging to a currently-closed section (excluded from counts). */
1405
1410
  private closedMemberIds;
1406
1411
  getGAAreas(): PickerGAArea[];
1412
+ /**
1413
+ * The buyer's own pending GA quantities, per area id — the widget's cart. Kept
1414
+ * here so every availability push repaints the count chips from one truth.
1415
+ */
1416
+ setGASelection(selected: ReadonlyMap<string, number> | null): void;
1417
+ /** Mirror live GA availability (and the pending chip) onto the map. */
1418
+ pushGAState(): void;
1407
1419
  /** Select a quantity from one GA area and hold it atomically. */
1408
1420
  holdGA(areaId: string, qty: number, options?: {
1409
1421
  tierId?: string | null;
@@ -1715,37 +1727,95 @@ declare function generateSeatThumb(seat: ExpandedSeat, focalPoint: Point, _neigh
1715
1727
 
1716
1728
  /**
1717
1729
  * i18n core — deliberately tiny and framework-free so the embed SDK can share
1718
- * it without dragging in a runtime library every KB here lands in the complete
1719
- * CDN bundle every buyer downloads, which is ~207 KB gzipped as of 0.37.0+.
1720
- * (This used to cite a "150 KB product contract". That number was never true of
1721
- * any shipped bundle the dashboard advertised it while the artifact measured
1722
- * 215 KB so it is stated as the measured figure now, not as a budget nobody
1723
- * was holding. The measured artifact, not an old marketing estimate, is the
1724
- * bundle-size authority.)
1730
+ * it without dragging in a runtime library. Every KB here lands in the complete
1731
+ * CDN bundle every buyer downloads, which is ~227 KB brotli as of 0.59.0.
1732
+ *
1733
+ * NOTHING in this file may import a non-English locale. English is the built-in
1734
+ * fallback and must resolve synchronously; the other 36 locales are fetched on
1735
+ * demand — see `./bundles.ts` for why that split is load-bearing rather than a
1736
+ * nicety, and `./localeLoaders.ts` for the map the npm build code-splits on.
1725
1737
  *
1726
- * Scope: the buyer surface (picker, public event
1727
- * page, SDK) ships fully translated in en/es/de/fr; dashboard pages route
1728
- * their strings through t() as they are rebuilt but ship English this round.
1738
+ * Scope: the buyer surface (picker, public event page, SDK). Dashboard and
1739
+ * Designer pages route strings through t() as they are rebuilt but ship
1740
+ * English that is a deliberate scope call, not a gap.
1729
1741
  *
1730
1742
  * Keys are flat dot-namespaced strings ("picker.holdSeats"). Interpolation
1731
1743
  * uses {name} placeholders. Missing keys fall back to English, then to the
1732
1744
  * key itself — a page never crashes over a translation.
1733
1745
  */
1734
- type Locale = 'en' | 'es' | 'de' | 'fr';
1746
+ /**
1747
+ * Every locale the buyer surface can render, matching the set a chart embed is
1748
+ * expected to cover. `zh-Hans`/`zh-Hant` carry a script subtag because Chinese
1749
+ * cannot be selected by language alone — see {@link resolveLocale}.
1750
+ */
1751
+ type Locale = 'ar' | 'be' | 'bg' | 'ca' | 'cs' | 'cy' | 'da' | 'de' | 'el' | 'en' | 'es' | 'et' | 'fa' | 'fi' | 'fr' | 'he' | 'hr' | 'hu' | 'it' | 'ja' | 'ku' | 'lt' | 'lv' | 'nl' | 'no' | 'pl' | 'pt' | 'ro' | 'ru' | 'sk' | 'sl' | 'sr' | 'sv' | 'tr' | 'uk' | 'zh-Hans' | 'zh-Hant';
1735
1752
  declare const SUPPORTED_LOCALES: Locale[];
1753
+ /**
1754
+ * Each language's name in itself. A reader scanning a language switcher for
1755
+ * their own language finds "Deutsch", never "German" — an English list is
1756
+ * unreadable to exactly the people who need to change it.
1757
+ *
1758
+ * Exported because a language switcher is integrator surface, not page
1759
+ * furniture: the SDK playground and any customer picker read the same table.
1760
+ */
1761
+ declare const LOCALE_NAMES: Record<Locale, string>;
1762
+ /**
1763
+ * The locales that actually have a dictionary today, as opposed to the ones the
1764
+ * product intends to cover.
1765
+ *
1766
+ * Two lists rather than one because the CDN build cannot see `localeLoaders.ts`
1767
+ * — that module is deliberately unreachable there — and without this it would
1768
+ * fire a doomed cross-origin request for every locale it does not ship, wait for
1769
+ * the 404, and only then fall back to English. During a rollout that is the
1770
+ * COMMON case, and it delays first paint for a buyer who was always going to see
1771
+ * English.
1772
+ *
1773
+ * Deliberately written out rather than `[...SUPPORTED_LOCALES]`, even now that
1774
+ * the two agree: spreading would make the guard vacuous the moment someone adds
1775
+ * a 38th locale to the supported set, which is exactly when it is needed.
1776
+ * `test/i18nBundles.test.ts` pins this against the loader map and the files on
1777
+ * disk, so the two cannot drift.
1778
+ */
1779
+ declare const TRANSLATED_LOCALES: Locale[];
1780
+ type Direction = 'ltr' | 'rtl';
1736
1781
  type Dict = Record<string, string>;
1737
- /** explicit setting → stored preference → browser language → en */
1782
+ /**
1783
+ * explicit setting → stored preference → browser languages → en.
1784
+ *
1785
+ * `navigator.languages` is preferred over `navigator.language` so a reader
1786
+ * whose first choice we do not ship still gets their second rather than
1787
+ * English.
1788
+ */
1738
1789
  declare function resolveLocale(explicit?: string | null, stored?: string | null): Locale;
1739
1790
  declare function getLocale(): Locale;
1791
+ /** Whether `locale` (default: the active one) is written right-to-left. */
1792
+ declare function localeDirection(locale?: Locale): Direction;
1793
+ /** Whether a bundle for `locale` is already registered (English always is). */
1794
+ declare function isLocaleLoaded(locale: Locale): boolean;
1740
1795
  /**
1741
1796
  * Set the active locale. Locale bundles other than English are registered by
1742
- * the surface that needs them (the picker imports its own es/de/fr bundles;
1743
- * the dashboard stays English until its translations ship).
1797
+ * the surface that needs them — `loadLocale()` in `./bundles.ts` is the one
1798
+ * caller that should normally do this.
1799
+ *
1800
+ * Deliberately does NOT touch `document.documentElement.dir`. This module runs
1801
+ * inside an embedded widget on somebody else's page, and flipping the host
1802
+ * document to RTL to render an Arabic seat map would mirror THEIR layout. The
1803
+ * picker sets `lang`/`dir` on its own container instead; read
1804
+ * {@link localeDirection} to do the same on any new surface.
1744
1805
  */
1745
1806
  declare function setLocale(locale: Locale, bundle?: Dict): void;
1746
1807
  declare function setStringOverrides(next: Dict): void;
1747
1808
  declare function t(key: string, vars?: Record<string, string | number>): string;
1748
- /** "1 seat" / "3 seats" without hand-rolled concatenation. */
1809
+ /**
1810
+ * "1 seat" / "3 seats" without hand-rolled concatenation.
1811
+ *
1812
+ * The category comes from `Intl.PluralRules`, so a locale that needs `few` or
1813
+ * `many` (most Slavic languages, Romanian, Arabic) gets the right form AS LONG
1814
+ * AS its bundle defines those keys. A bundle missing the exact category falls
1815
+ * back to `.other` rather than throwing — wrong grammar beats a blank string —
1816
+ * which is why `test/i18nBundles.test.ts` fails the build when a bundle omits
1817
+ * a category its own plural rules require.
1818
+ */
1749
1819
  declare function tCount(key: string, count: number, vars?: Record<string, string | number>): string;
1750
1820
  /**
1751
1821
  * Kept for the SDK surface that imports dates from here. It is a thin pass to
@@ -1758,24 +1828,38 @@ declare function tCount(key: string, count: number, vars?: Record<string, string
1758
1828
  declare function formatDate(value: number | Date, opts?: Intl.DateTimeFormatOptions): string;
1759
1829
 
1760
1830
  /**
1761
- * Locale bundle loader — keeps non-English translations OUT of the initial
1762
- * bundle they are ~2.5 KB gzipped of the complete CDN artifact — and
1763
- * code-splits each locale so a page/SDK only downloads the language it actually
1764
- * uses. (The "150 KB product contract" this used to cite was never true of a
1765
- * shipped bundle; the measured artifact, not an old marketing estimate, is
1766
- * the bundle-size authority.)
1831
+ * Locale bundle loader — the ONE place that decides how a non-English
1832
+ * dictionary reaches the page, and the reason 36 locales cost the buyer
1833
+ * nothing.
1834
+ *
1835
+ * There are two delivery paths because there are two builds:
1836
+ *
1837
+ * - **npm / bundler consumers** (and the vendored app copy): a dynamic import
1838
+ * of `./localeLoaders`, whose specifiers every bundler code-splits into one
1839
+ * chunk per locale.
1840
+ * - **the CDN artifact**: a Vite `lib` build with `codeSplitting: false`. It
1841
+ * physically cannot emit a chunk, so a reachable `import('./locales/de')`
1842
+ * is INLINED. Until 0.59.0 that is exactly what happened — es/de/fr shipped
1843
+ * inside `seatlayer.js` to every buyer of every chart while this file's own
1844
+ * comment claimed they were code-split. At ~5 KB brotli each, carrying all
1845
+ * 36 that way would have added ~180 KB to a 227 KB bundle. So the CDN path
1846
+ * loads a sibling ESM asset by absolute URL instead, exactly like the 3D
1847
+ * scene, panorama and hosted-checkout chunks do.
1848
+ *
1849
+ * English is built into the core and never fetched — it is the synchronous
1850
+ * fallback `t()` reads when a key is missing, so it cannot be a network call.
1767
1851
  *
1768
- * `loadLocale('de')` dynamic-imports the German dictionary, registers it via
1769
- * setLocale(), and resolves once it's active. English is built in, so
1770
- * `loadLocale('en')` is synchronous and never fetches. Unknown/unsupported
1771
- * codes fall back to English without throwing.
1852
+ * Unknown, unsupported, and not-yet-translated codes fall back to English
1853
+ * without throwing, as does any network or parse failure. A seat map renders
1854
+ * in English rather than not at all.
1772
1855
  */
1773
1856
 
1774
1857
  /**
1775
1858
  * Resolve `code` to a supported locale, load its bundle if needed, and make it
1776
- * active. Returns the locale that ended up active (English on any failure).
1859
+ * active. Returns the locale that ended up active (English on any failure, on
1860
+ * an unsupported code, or on a locale we have not translated yet).
1777
1861
  */
1778
- declare function loadLocale(code?: string | null): Promise<Locale>;
1862
+ declare function loadLocale(code?: string | null, stored?: string | null): Promise<Locale>;
1779
1863
 
1780
1864
  /**
1781
1865
  * Money formatting — the ONE place currency rendering happens.
@@ -1838,4 +1922,4 @@ declare function formatMinor(minor: number, currency?: string, locale?: string):
1838
1922
  /** Bare symbol for input adornments ("€", "$", "₹"). */
1839
1923
  declare function currencySymbol(currency?: string): string;
1840
1924
 
1841
- 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 PickerSelectionValidator, type PickerSelectionValidity, type PickerSelectionViolation, 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 };
1925
+ export { AccessibilityType, CURRENCY_CHOICES, CategoryTier, ChartDoc, DEFAULT_CURRENCY, type Dict, type Direction, ExpandedSeat, GAAreaState, type HoldConflict, type HoldInfo, type HoldSelectionRequest, type HoldServerItem, ISeatmapRenderer, LOCALE_NAMES, 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 PickerSelectionValidator, type PickerSelectionValidity, type PickerSelectionViolation, type PickerStatusChange, type PickerTransport, Point, RendererCallbacks, RendererMinimapSnapshot, RendererOptions, RendererQualityEvidence, RendererViewMode, SUPPORTED_LOCALES, SeatCommercialAttributes, type SeatHoverDetails, SeatStatus, SeatmapRenderer, type SectionCategory, type SectionSummary, TRANSLATED_LOCALES, type TableSelectionDetails, createRenderer, currencyExponent, currencySymbol, formatDate, formatMinor, formatMoney, fromMinorUnits, generateSeatPanorama, generateSeatThumb, getLocale, isLocaleLoaded, loadLocale, localeDirection, resolveLocale, setLocale, setMoneyLocale, setStringOverrides, t, tCount };
package/dist/index.d.ts CHANGED
@@ -1,13 +1,13 @@
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';
1
+ import { C as ChartDoc, P as Point, A as AccessibilityType, l as CategoryTier, f as SeatCommercialAttributes } from './types-Db9rXT14.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 ReferenceEnrichmentStatus, W as ReferenceExtractEmptyReason, X as ReferenceExtractEnrichment, Y as ReferenceExtractInput, Z as ReferenceExtractProposal, _ as ReferenceExtractRegionSeats, $ as ReferenceInventoryExclusionSource, a0 as ReferenceInventorySource, a1 as ReferenceScanProposal, a2 as ReferenceScanRowProposal, a3 as ReferenceScanSectionProposal, a4 as ReferenceSeatSeed, a5 as ReferenceSectionTraceBatchInput, a6 as ReferenceSectionTraceBatchProposal, a7 as ReferenceSectionTraceInput, a8 as ReferenceSectionTraceProposal, g as ResolvedSeatConfidenceEvidence, R as RowObject, a9 as SEAT_COMMERCIAL_MARKS, aa as SURROUNDINGS_SHAPE_ROLES, ab as SeatCommercialMark, ac as SeatCommercialMeta, ad as SeatConfidenceCoverage, ae as SeatConfidenceEvidence, af as SeatConfidenceModelLevel, ag as SeatConfidenceModeledTarget, ah as SeatConfidenceRealityLevel, S as SeatOverride, h as SeatViewCoverage, a as SeatViewMetadata, d as SectionObject, i as SectionOutlinePath, j as SectionPathSegment, ai as SelectionLayer, n as ShapeLineCap, o as ShapeLineEnding, p as ShapeLineJoin, q as ShapeObject, T as TableObject, aj as TextAlignment, ak as TextBackground, s as TextObject, al as TicketTierApplicability, am as TicketTierEvidence, an as TicketTierRestriction, ao as ZoneDef, ap as accessibilityMeta, aq as accessibilityRingColor, ar as layerOf, as as seatCommercialMeta } from './types-Db9rXT14.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 floorsShareFootprint, m as layoutFloorOverview, n as layoutFloorRings, o as objectCenter, p as owningSectionForObject, q as pointInPolygon, r as pointInPolygonWithHoles, s as polygonLabelPoint, t as rowInventoryCount, u as rowSeatPositions, v as stackFloors, w as tableInventoryCount, x as tableSeatCountsBySide, y as translateObject } from './layout-D-R46h1m.js';
4
+ import { c as TicketSelectionIssue } from './ticketRestrictions-EJTEWPGN.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-EJTEWPGN.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-9_Ka3i-z.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-CsXNQCCH.js';
8
+ import { I as ISeatmapRenderer, b as RendererOptions, S as SeatStatus, E as ExpandedSeat, G as GAAreaState, c as RendererViewMode, d as RendererMinimapSnapshot, L as LodRung, R as RendererQualityEvidence, e as RendererCallbacks } from './renderer-Bo9JzqMA.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-Bo9JzqMA.js';
10
+ import './segmentedRowModel-CO6Jogaa.js';
11
11
 
12
12
  declare class SeatmapRenderer implements ISeatmapRenderer {
13
13
  private container;
@@ -324,10 +324,12 @@ declare class SeatmapRenderer implements ISeatmapRenderer {
324
324
  * widget resolves which categories fall inside the buyer's chosen band.
325
325
  */
326
326
  setCategoryFilter(keys: string[] | null): void;
327
- private gaCategoryDimmed;
328
327
  /** Keep GA paint and its two labels in the same legend/price-filter state. */
329
328
  private applyGAFilterState;
330
329
  private paintGAStateForView;
330
+ /** Host-pushed GA availability / pending quantity — see {@link paintGAState}. */
331
+ setGAStates(states: Record<string, GAAreaState>): void;
332
+ setGAState(areaId: string, state: GAAreaState): void;
331
333
  /** Frame the currently available inventory that survived a buyer price
332
334
  * filter. Clearing the filter glides back to the full venue. */
333
335
  focusCategories(keys: string[] | null): void;
@@ -457,8 +459,9 @@ declare class SeatmapRenderer implements ISeatmapRenderer {
457
459
  * the `unavailable` test in {@link updateLabels} so the two never collide.
458
460
  */
459
461
  private accessGlyphEligible;
460
- /** The category's display color — Okabe-Ito hue when colorblind-safe is on. */
461
- private seatBaseColor;
462
+ /** The category's on-screen color — Okabe-Ito hue in colorblind-safe mode.
463
+ * Public because a legend must ask; see the contract for why. */
464
+ categoryDisplayColor(categoryKey: string): string;
462
465
  /** Per-seat authored label size relative to the neutral default (1 = default),
463
466
  * mirroring the section convention (labelStyle.size ?? 18) / 18. Only real
464
467
  * seats carry labelStyle, so booths and unstyled seats resolve to 1. */
@@ -1213,6 +1216,8 @@ declare class PickerController {
1213
1216
  private selectableSeatIds;
1214
1217
  private lastSelectionValidity;
1215
1218
  private renderer;
1219
+ /** Host-tracked pending GA quantity per area id (the widget cart's chips). */
1220
+ private gaSelected;
1216
1221
  private _doc;
1217
1222
  /** Section/zone ids hidden from buyers this event (3.3) — seats vanish, not grey. */
1218
1223
  private hidden;
@@ -1404,6 +1409,13 @@ declare class PickerController {
1404
1409
  /** Seat ids belonging to a currently-closed section (excluded from counts). */
1405
1410
  private closedMemberIds;
1406
1411
  getGAAreas(): PickerGAArea[];
1412
+ /**
1413
+ * The buyer's own pending GA quantities, per area id — the widget's cart. Kept
1414
+ * here so every availability push repaints the count chips from one truth.
1415
+ */
1416
+ setGASelection(selected: ReadonlyMap<string, number> | null): void;
1417
+ /** Mirror live GA availability (and the pending chip) onto the map. */
1418
+ pushGAState(): void;
1407
1419
  /** Select a quantity from one GA area and hold it atomically. */
1408
1420
  holdGA(areaId: string, qty: number, options?: {
1409
1421
  tierId?: string | null;
@@ -1715,37 +1727,95 @@ declare function generateSeatThumb(seat: ExpandedSeat, focalPoint: Point, _neigh
1715
1727
 
1716
1728
  /**
1717
1729
  * i18n core — deliberately tiny and framework-free so the embed SDK can share
1718
- * it without dragging in a runtime library every KB here lands in the complete
1719
- * CDN bundle every buyer downloads, which is ~207 KB gzipped as of 0.37.0+.
1720
- * (This used to cite a "150 KB product contract". That number was never true of
1721
- * any shipped bundle the dashboard advertised it while the artifact measured
1722
- * 215 KB so it is stated as the measured figure now, not as a budget nobody
1723
- * was holding. The measured artifact, not an old marketing estimate, is the
1724
- * bundle-size authority.)
1730
+ * it without dragging in a runtime library. Every KB here lands in the complete
1731
+ * CDN bundle every buyer downloads, which is ~227 KB brotli as of 0.59.0.
1732
+ *
1733
+ * NOTHING in this file may import a non-English locale. English is the built-in
1734
+ * fallback and must resolve synchronously; the other 36 locales are fetched on
1735
+ * demand — see `./bundles.ts` for why that split is load-bearing rather than a
1736
+ * nicety, and `./localeLoaders.ts` for the map the npm build code-splits on.
1725
1737
  *
1726
- * Scope: the buyer surface (picker, public event
1727
- * page, SDK) ships fully translated in en/es/de/fr; dashboard pages route
1728
- * their strings through t() as they are rebuilt but ship English this round.
1738
+ * Scope: the buyer surface (picker, public event page, SDK). Dashboard and
1739
+ * Designer pages route strings through t() as they are rebuilt but ship
1740
+ * English that is a deliberate scope call, not a gap.
1729
1741
  *
1730
1742
  * Keys are flat dot-namespaced strings ("picker.holdSeats"). Interpolation
1731
1743
  * uses {name} placeholders. Missing keys fall back to English, then to the
1732
1744
  * key itself — a page never crashes over a translation.
1733
1745
  */
1734
- type Locale = 'en' | 'es' | 'de' | 'fr';
1746
+ /**
1747
+ * Every locale the buyer surface can render, matching the set a chart embed is
1748
+ * expected to cover. `zh-Hans`/`zh-Hant` carry a script subtag because Chinese
1749
+ * cannot be selected by language alone — see {@link resolveLocale}.
1750
+ */
1751
+ type Locale = 'ar' | 'be' | 'bg' | 'ca' | 'cs' | 'cy' | 'da' | 'de' | 'el' | 'en' | 'es' | 'et' | 'fa' | 'fi' | 'fr' | 'he' | 'hr' | 'hu' | 'it' | 'ja' | 'ku' | 'lt' | 'lv' | 'nl' | 'no' | 'pl' | 'pt' | 'ro' | 'ru' | 'sk' | 'sl' | 'sr' | 'sv' | 'tr' | 'uk' | 'zh-Hans' | 'zh-Hant';
1735
1752
  declare const SUPPORTED_LOCALES: Locale[];
1753
+ /**
1754
+ * Each language's name in itself. A reader scanning a language switcher for
1755
+ * their own language finds "Deutsch", never "German" — an English list is
1756
+ * unreadable to exactly the people who need to change it.
1757
+ *
1758
+ * Exported because a language switcher is integrator surface, not page
1759
+ * furniture: the SDK playground and any customer picker read the same table.
1760
+ */
1761
+ declare const LOCALE_NAMES: Record<Locale, string>;
1762
+ /**
1763
+ * The locales that actually have a dictionary today, as opposed to the ones the
1764
+ * product intends to cover.
1765
+ *
1766
+ * Two lists rather than one because the CDN build cannot see `localeLoaders.ts`
1767
+ * — that module is deliberately unreachable there — and without this it would
1768
+ * fire a doomed cross-origin request for every locale it does not ship, wait for
1769
+ * the 404, and only then fall back to English. During a rollout that is the
1770
+ * COMMON case, and it delays first paint for a buyer who was always going to see
1771
+ * English.
1772
+ *
1773
+ * Deliberately written out rather than `[...SUPPORTED_LOCALES]`, even now that
1774
+ * the two agree: spreading would make the guard vacuous the moment someone adds
1775
+ * a 38th locale to the supported set, which is exactly when it is needed.
1776
+ * `test/i18nBundles.test.ts` pins this against the loader map and the files on
1777
+ * disk, so the two cannot drift.
1778
+ */
1779
+ declare const TRANSLATED_LOCALES: Locale[];
1780
+ type Direction = 'ltr' | 'rtl';
1736
1781
  type Dict = Record<string, string>;
1737
- /** explicit setting → stored preference → browser language → en */
1782
+ /**
1783
+ * explicit setting → stored preference → browser languages → en.
1784
+ *
1785
+ * `navigator.languages` is preferred over `navigator.language` so a reader
1786
+ * whose first choice we do not ship still gets their second rather than
1787
+ * English.
1788
+ */
1738
1789
  declare function resolveLocale(explicit?: string | null, stored?: string | null): Locale;
1739
1790
  declare function getLocale(): Locale;
1791
+ /** Whether `locale` (default: the active one) is written right-to-left. */
1792
+ declare function localeDirection(locale?: Locale): Direction;
1793
+ /** Whether a bundle for `locale` is already registered (English always is). */
1794
+ declare function isLocaleLoaded(locale: Locale): boolean;
1740
1795
  /**
1741
1796
  * Set the active locale. Locale bundles other than English are registered by
1742
- * the surface that needs them (the picker imports its own es/de/fr bundles;
1743
- * the dashboard stays English until its translations ship).
1797
+ * the surface that needs them — `loadLocale()` in `./bundles.ts` is the one
1798
+ * caller that should normally do this.
1799
+ *
1800
+ * Deliberately does NOT touch `document.documentElement.dir`. This module runs
1801
+ * inside an embedded widget on somebody else's page, and flipping the host
1802
+ * document to RTL to render an Arabic seat map would mirror THEIR layout. The
1803
+ * picker sets `lang`/`dir` on its own container instead; read
1804
+ * {@link localeDirection} to do the same on any new surface.
1744
1805
  */
1745
1806
  declare function setLocale(locale: Locale, bundle?: Dict): void;
1746
1807
  declare function setStringOverrides(next: Dict): void;
1747
1808
  declare function t(key: string, vars?: Record<string, string | number>): string;
1748
- /** "1 seat" / "3 seats" without hand-rolled concatenation. */
1809
+ /**
1810
+ * "1 seat" / "3 seats" without hand-rolled concatenation.
1811
+ *
1812
+ * The category comes from `Intl.PluralRules`, so a locale that needs `few` or
1813
+ * `many` (most Slavic languages, Romanian, Arabic) gets the right form AS LONG
1814
+ * AS its bundle defines those keys. A bundle missing the exact category falls
1815
+ * back to `.other` rather than throwing — wrong grammar beats a blank string —
1816
+ * which is why `test/i18nBundles.test.ts` fails the build when a bundle omits
1817
+ * a category its own plural rules require.
1818
+ */
1749
1819
  declare function tCount(key: string, count: number, vars?: Record<string, string | number>): string;
1750
1820
  /**
1751
1821
  * Kept for the SDK surface that imports dates from here. It is a thin pass to
@@ -1758,24 +1828,38 @@ declare function tCount(key: string, count: number, vars?: Record<string, string
1758
1828
  declare function formatDate(value: number | Date, opts?: Intl.DateTimeFormatOptions): string;
1759
1829
 
1760
1830
  /**
1761
- * Locale bundle loader — keeps non-English translations OUT of the initial
1762
- * bundle they are ~2.5 KB gzipped of the complete CDN artifact — and
1763
- * code-splits each locale so a page/SDK only downloads the language it actually
1764
- * uses. (The "150 KB product contract" this used to cite was never true of a
1765
- * shipped bundle; the measured artifact, not an old marketing estimate, is
1766
- * the bundle-size authority.)
1831
+ * Locale bundle loader — the ONE place that decides how a non-English
1832
+ * dictionary reaches the page, and the reason 36 locales cost the buyer
1833
+ * nothing.
1834
+ *
1835
+ * There are two delivery paths because there are two builds:
1836
+ *
1837
+ * - **npm / bundler consumers** (and the vendored app copy): a dynamic import
1838
+ * of `./localeLoaders`, whose specifiers every bundler code-splits into one
1839
+ * chunk per locale.
1840
+ * - **the CDN artifact**: a Vite `lib` build with `codeSplitting: false`. It
1841
+ * physically cannot emit a chunk, so a reachable `import('./locales/de')`
1842
+ * is INLINED. Until 0.59.0 that is exactly what happened — es/de/fr shipped
1843
+ * inside `seatlayer.js` to every buyer of every chart while this file's own
1844
+ * comment claimed they were code-split. At ~5 KB brotli each, carrying all
1845
+ * 36 that way would have added ~180 KB to a 227 KB bundle. So the CDN path
1846
+ * loads a sibling ESM asset by absolute URL instead, exactly like the 3D
1847
+ * scene, panorama and hosted-checkout chunks do.
1848
+ *
1849
+ * English is built into the core and never fetched — it is the synchronous
1850
+ * fallback `t()` reads when a key is missing, so it cannot be a network call.
1767
1851
  *
1768
- * `loadLocale('de')` dynamic-imports the German dictionary, registers it via
1769
- * setLocale(), and resolves once it's active. English is built in, so
1770
- * `loadLocale('en')` is synchronous and never fetches. Unknown/unsupported
1771
- * codes fall back to English without throwing.
1852
+ * Unknown, unsupported, and not-yet-translated codes fall back to English
1853
+ * without throwing, as does any network or parse failure. A seat map renders
1854
+ * in English rather than not at all.
1772
1855
  */
1773
1856
 
1774
1857
  /**
1775
1858
  * Resolve `code` to a supported locale, load its bundle if needed, and make it
1776
- * active. Returns the locale that ended up active (English on any failure).
1859
+ * active. Returns the locale that ended up active (English on any failure, on
1860
+ * an unsupported code, or on a locale we have not translated yet).
1777
1861
  */
1778
- declare function loadLocale(code?: string | null): Promise<Locale>;
1862
+ declare function loadLocale(code?: string | null, stored?: string | null): Promise<Locale>;
1779
1863
 
1780
1864
  /**
1781
1865
  * Money formatting — the ONE place currency rendering happens.
@@ -1838,4 +1922,4 @@ declare function formatMinor(minor: number, currency?: string, locale?: string):
1838
1922
  /** Bare symbol for input adornments ("€", "$", "₹"). */
1839
1923
  declare function currencySymbol(currency?: string): string;
1840
1924
 
1841
- 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 PickerSelectionValidator, type PickerSelectionValidity, type PickerSelectionViolation, 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 };
1925
+ export { AccessibilityType, CURRENCY_CHOICES, CategoryTier, ChartDoc, DEFAULT_CURRENCY, type Dict, type Direction, ExpandedSeat, GAAreaState, type HoldConflict, type HoldInfo, type HoldSelectionRequest, type HoldServerItem, ISeatmapRenderer, LOCALE_NAMES, 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 PickerSelectionValidator, type PickerSelectionValidity, type PickerSelectionViolation, type PickerStatusChange, type PickerTransport, Point, RendererCallbacks, RendererMinimapSnapshot, RendererOptions, RendererQualityEvidence, RendererViewMode, SUPPORTED_LOCALES, SeatCommercialAttributes, type SeatHoverDetails, SeatStatus, SeatmapRenderer, type SectionCategory, type SectionSummary, TRANSLATED_LOCALES, type TableSelectionDetails, createRenderer, currencyExponent, currencySymbol, formatDate, formatMinor, formatMoney, fromMinorUnits, generateSeatPanorama, generateSeatThumb, getLocale, isLocaleLoaded, loadLocale, localeDirection, resolveLocale, setLocale, setMoneyLocale, setStringOverrides, t, tCount };