@seatlayer/angular 0.53.0 → 0.55.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/README.md CHANGED
@@ -64,6 +64,9 @@ export class CheckoutComponent {
64
64
  | `event` | `string` | **Required.** Changing it rebuilds the chart. |
65
65
  | `apiBase` | `string` | Defaults to the public API. |
66
66
  | `maxSelection` | `number` | Cap on how many seats a buyer may select. |
67
+ | `selectedObjects` | `string[]` | Initial object ids or public labels. |
68
+ | `selectableObjects` | `string[] \| null` | Buyer-selectable allow-list. |
69
+ | `numberOfPlacesToSelect` | `number` | Exact count required for a valid selection. |
67
70
  | `publicKey` | `string` | Reserved compatibility input; stored by the chart but not transmitted to SeatLayer. |
68
71
  | `locale` | `string` | BCP-47 locale for built-in copy. |
69
72
  | `currency` | `string` | ISO currency for price formatting. |
@@ -71,15 +74,19 @@ export class CheckoutComponent {
71
74
  | `seatTooltip` | `boolean` | Set `false` to draw your own popover from `(seatHover)`. |
72
75
  | `messages` | `object` | Copy overrides. Read once per rebuild. |
73
76
 
74
- Only `event`, `apiBase`, `maxSelection`, `publicKey`, `locale`, `currency` and
75
- `colorblindSafe` rebuild the canvas an unrelated change-detection pass never
76
- destroys the chart mid-selection.
77
+ `numberOfPlacesToSelect` and the other primitive identity inputs rebuild the
78
+ canvas. `selectedObjects` and `selectableObjects` are initial values; use the
79
+ imperative methods for later changes so change detection never destroys a chart
80
+ mid-selection because an array instance changed.
77
81
 
78
82
  ## Outputs
79
83
 
80
84
  | Output | Payload |
81
85
  | --- | --- |
82
86
  | `(selectionChange)` | `SelectedSeat[]` |
87
+ | `(selectionValidityChange)` | Exact-count state |
88
+ | `(selectionValid)` / `(selectionInvalid)` | Exact-count transition |
89
+ | `(selectionLimit)` | Active numeric cap |
83
90
  | `(hold)` | `HoldResult` |
84
91
  | `(holdRestored)` | `HoldResult` |
85
92
  | `(holdExpired)` | — |
@@ -99,6 +106,9 @@ Via a template ref (`#chart`):
99
106
 
100
107
  `holdSelection` · `resumeHold` · `getCurrentHold` · `getGAAreas` · `holdGA` ·
101
108
  `bestAvailable` · `release` · `releaseLabels` · `getSelection` · `setSeatTier` ·
109
+ `selectObjects` · `deselectObjects` · `clearSelection` · `selectCategories` ·
110
+ `deselectCategories` · `setSelectableObjects` · `setMaxSelection` ·
111
+ `getSelectionValidity` ·
102
112
  `getFloors` · `setFloor` · `setColorblindSafe` · `zoomIn` · `zoomOut` ·
103
113
  `zoomToFit`
104
114
 
package/dist/README.md CHANGED
@@ -64,6 +64,9 @@ export class CheckoutComponent {
64
64
  | `event` | `string` | **Required.** Changing it rebuilds the chart. |
65
65
  | `apiBase` | `string` | Defaults to the public API. |
66
66
  | `maxSelection` | `number` | Cap on how many seats a buyer may select. |
67
+ | `selectedObjects` | `string[]` | Initial object ids or public labels. |
68
+ | `selectableObjects` | `string[] \| null` | Buyer-selectable allow-list. |
69
+ | `numberOfPlacesToSelect` | `number` | Exact count required for a valid selection. |
67
70
  | `publicKey` | `string` | Reserved compatibility input; stored by the chart but not transmitted to SeatLayer. |
68
71
  | `locale` | `string` | BCP-47 locale for built-in copy. |
69
72
  | `currency` | `string` | ISO currency for price formatting. |
@@ -71,15 +74,19 @@ export class CheckoutComponent {
71
74
  | `seatTooltip` | `boolean` | Set `false` to draw your own popover from `(seatHover)`. |
72
75
  | `messages` | `object` | Copy overrides. Read once per rebuild. |
73
76
 
74
- Only `event`, `apiBase`, `maxSelection`, `publicKey`, `locale`, `currency` and
75
- `colorblindSafe` rebuild the canvas an unrelated change-detection pass never
76
- destroys the chart mid-selection.
77
+ `numberOfPlacesToSelect` and the other primitive identity inputs rebuild the
78
+ canvas. `selectedObjects` and `selectableObjects` are initial values; use the
79
+ imperative methods for later changes so change detection never destroys a chart
80
+ mid-selection because an array instance changed.
77
81
 
78
82
  ## Outputs
79
83
 
80
84
  | Output | Payload |
81
85
  | --- | --- |
82
86
  | `(selectionChange)` | `SelectedSeat[]` |
87
+ | `(selectionValidityChange)` | Exact-count state |
88
+ | `(selectionValid)` / `(selectionInvalid)` | Exact-count transition |
89
+ | `(selectionLimit)` | Active numeric cap |
83
90
  | `(hold)` | `HoldResult` |
84
91
  | `(holdRestored)` | `HoldResult` |
85
92
  | `(holdExpired)` | — |
@@ -99,6 +106,9 @@ Via a template ref (`#chart`):
99
106
 
100
107
  `holdSelection` · `resumeHold` · `getCurrentHold` · `getGAAreas` · `holdGA` ·
101
108
  `bestAvailable` · `release` · `releaseLabels` · `getSelection` · `setSeatTier` ·
109
+ `selectObjects` · `deselectObjects` · `clearSelection` · `selectCategories` ·
110
+ `deselectCategories` · `setSelectableObjects` · `setMaxSelection` ·
111
+ `getSelectionValidity` ·
102
112
  `getFloors` · `setFloor` · `setColorblindSafe` · `zoomIn` · `zoomOut` ·
103
113
  `zoomToFit`
104
114
 
@@ -10,7 +10,7 @@ export { SeatPicker as SeatPickerWidget, attachPickerFrame } from '@seatlayer/js
10
10
  *
11
11
  * The canvas is created once and torn down on destroy. Only the inputs that
12
12
  * change the chart's identity (`SEATING_CHART_IDENTITY_PROPS`: `event`,
13
- * `apiBase`, `maxSelection`, `publicKey`, `locale`, `currency`,
13
+ * `apiBase`, `maxSelection`, `numberOfPlacesToSelect`, `publicKey`, `locale`, `currency`,
14
14
  * `colorblindSafe`, `initialView`, `errorDisplay`) trigger a rebuild, so an
15
15
  * unrelated change-detection pass never destroys the canvas mid-selection.
16
16
  *
@@ -32,6 +32,12 @@ class SeatLayerSeatingChartComponent {
32
32
  apiBase;
33
33
  /** Cap on how many seats a buyer may select. */
34
34
  maxSelection;
35
+ /** Object ids or public labels selected after availability loads. */
36
+ selectedObjects;
37
+ /** Object ids or public labels the buyer may select. */
38
+ selectableObjects;
39
+ /** Exact ticket count required for a valid selection. */
40
+ numberOfPlacesToSelect;
35
41
  /** Publishable key, when your integration uses one. */
36
42
  publicKey;
37
43
  /** BCP-47 locale for built-in copy. */
@@ -67,6 +73,14 @@ class SeatLayerSeatingChartComponent {
67
73
  buyerAccessToken;
68
74
  /** The buyer's selection changed. */
69
75
  selectionChange = new EventEmitter();
76
+ /** Exact-count state changed. */
77
+ selectionValidityChange = new EventEmitter();
78
+ /** The exact count was reached. */
79
+ selectionValid = new EventEmitter();
80
+ /** The selection is not at the exact count. */
81
+ selectionInvalid = new EventEmitter();
82
+ /** The active selection cap was reached. */
83
+ selectionLimit = new EventEmitter();
70
84
  /** A hold succeeded. */
71
85
  hold = new EventEmitter();
72
86
  /** A previous hold was restored on mount. */
@@ -150,6 +164,30 @@ class SeatLayerSeatingChartComponent {
150
164
  getSelection() {
151
165
  return this.handle.getSelection();
152
166
  }
167
+ selectObjects(objects) {
168
+ return this.handle.selectObjects(objects);
169
+ }
170
+ deselectObjects(objects) {
171
+ this.handle.deselectObjects(objects);
172
+ }
173
+ clearSelection() {
174
+ this.handle.clearSelection();
175
+ }
176
+ selectCategories(categoryKeys) {
177
+ return this.handle.selectCategories(categoryKeys);
178
+ }
179
+ deselectCategories(categoryKeys) {
180
+ this.handle.deselectCategories(categoryKeys);
181
+ }
182
+ setSelectableObjects(objects) {
183
+ this.handle.setSelectableObjects(objects);
184
+ }
185
+ setMaxSelection(maxSelection) {
186
+ this.handle.setMaxSelection(maxSelection);
187
+ }
188
+ getSelectionValidity() {
189
+ return this.handle.getSelectionValidity();
190
+ }
153
191
  /** Choose a ticket tier for a selected seat; `null` reverts to the default. */
154
192
  setSeatTier(seatId, tierId) {
155
193
  this.handle.setSeatTier(seatId, tierId);
@@ -201,6 +239,9 @@ class SeatLayerSeatingChartComponent {
201
239
  event: this.event,
202
240
  apiBase: this.apiBase,
203
241
  maxSelection: this.maxSelection,
242
+ selectedObjects: this.selectedObjects,
243
+ selectableObjects: this.selectableObjects,
244
+ numberOfPlacesToSelect: this.numberOfPlacesToSelect,
204
245
  publicKey: this.publicKey,
205
246
  locale: this.locale,
206
247
  currency: this.currency,
@@ -213,6 +254,10 @@ class SeatLayerSeatingChartComponent {
213
254
  buyerAccessToken: this.buyerAccessToken,
214
255
  }, {
215
256
  onSelectionChange: (seats) => emit(this.selectionChange, seats),
257
+ onSelectionValidityChange: (state) => emit(this.selectionValidityChange, state),
258
+ onSelectionValid: (seats) => emit(this.selectionValid, seats),
259
+ onSelectionInvalid: (state) => emit(this.selectionInvalid, state),
260
+ onSelectionLimit: (max) => emit(this.selectionLimit, max),
216
261
  onHold: (result) => emit(this.hold, result),
217
262
  onHoldRestored: (result) => emit(this.holdRestored, result),
218
263
  onHoldExpired: () => this.zone.run(() => this.holdExpired.emit()),
@@ -234,7 +279,7 @@ class SeatLayerSeatingChartComponent {
234
279
  this.chart = null;
235
280
  }
236
281
  static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "19.2.25", ngImport: i0, type: SeatLayerSeatingChartComponent, deps: [], target: i0.ɵɵFactoryTarget.Component });
237
- static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "19.2.25", type: SeatLayerSeatingChartComponent, isStandalone: true, selector: "seatlayer-seating-chart", inputs: { event: "event", apiBase: "apiBase", maxSelection: "maxSelection", publicKey: "publicKey", locale: "locale", currency: "currency", colorblindSafe: "colorblindSafe", initialView: "initialView", errorDisplay: "errorDisplay", seatTooltip: "seatTooltip", messages: "messages", buyerAccessTokenProvider: "buyerAccessTokenProvider", buyerAccessToken: "buyerAccessToken" }, outputs: { selectionChange: "selectionChange", hold: "hold", holdRestored: "holdRestored", holdExpired: "holdExpired", gaClick: "gaClick", errored: "errored", deckTap: "deckTap", hint: "hint", seatHover: "seatHover", accessExpired: "accessExpired", accessUnavailable: "accessUnavailable", selectedObjectUnavailable: "selectedObjectUnavailable" }, viewQueries: [{ propertyName: "container", first: true, predicate: ["container"], descendants: true, static: true }], usesOnChanges: true, ngImport: i0, template: '<div #container class="seatlayer-container"></div>', isInline: true, styles: [":host{display:block}.seatlayer-container{width:100%;height:100%}\n"], changeDetection: i0.ChangeDetectionStrategy.OnPush });
282
+ static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "19.2.25", type: SeatLayerSeatingChartComponent, isStandalone: true, selector: "seatlayer-seating-chart", inputs: { event: "event", apiBase: "apiBase", maxSelection: "maxSelection", selectedObjects: "selectedObjects", selectableObjects: "selectableObjects", numberOfPlacesToSelect: "numberOfPlacesToSelect", publicKey: "publicKey", locale: "locale", currency: "currency", colorblindSafe: "colorblindSafe", initialView: "initialView", errorDisplay: "errorDisplay", seatTooltip: "seatTooltip", messages: "messages", buyerAccessTokenProvider: "buyerAccessTokenProvider", buyerAccessToken: "buyerAccessToken" }, outputs: { selectionChange: "selectionChange", selectionValidityChange: "selectionValidityChange", selectionValid: "selectionValid", selectionInvalid: "selectionInvalid", selectionLimit: "selectionLimit", hold: "hold", holdRestored: "holdRestored", holdExpired: "holdExpired", gaClick: "gaClick", errored: "errored", deckTap: "deckTap", hint: "hint", seatHover: "seatHover", accessExpired: "accessExpired", accessUnavailable: "accessUnavailable", selectedObjectUnavailable: "selectedObjectUnavailable" }, viewQueries: [{ propertyName: "container", first: true, predicate: ["container"], descendants: true, static: true }], usesOnChanges: true, ngImport: i0, template: '<div #container class="seatlayer-container"></div>', isInline: true, styles: [":host{display:block}.seatlayer-container{width:100%;height:100%}\n"], changeDetection: i0.ChangeDetectionStrategy.OnPush });
238
283
  }
239
284
  i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "19.2.25", ngImport: i0, type: SeatLayerSeatingChartComponent, decorators: [{
240
285
  type: Component,
@@ -246,6 +291,12 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "19.2.25", ngImpo
246
291
  type: Input
247
292
  }], maxSelection: [{
248
293
  type: Input
294
+ }], selectedObjects: [{
295
+ type: Input
296
+ }], selectableObjects: [{
297
+ type: Input
298
+ }], numberOfPlacesToSelect: [{
299
+ type: Input
249
300
  }], publicKey: [{
250
301
  type: Input
251
302
  }], locale: [{
@@ -268,6 +319,14 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "19.2.25", ngImpo
268
319
  type: Input
269
320
  }], selectionChange: [{
270
321
  type: Output
322
+ }], selectionValidityChange: [{
323
+ type: Output
324
+ }], selectionValid: [{
325
+ type: Output
326
+ }], selectionInvalid: [{
327
+ type: Output
328
+ }], selectionLimit: [{
329
+ type: Output
271
330
  }], hold: [{
272
331
  type: Output
273
332
  }], holdRestored: [{
@@ -1 +1 @@
1
- {"version":3,"file":"seatlayer-angular.mjs","sources":["../../src/seating-chart.component.ts","../../src/index.ts","../../src/seatlayer-angular.ts"],"sourcesContent":["import {\n ChangeDetectionStrategy,\n Component,\n DestroyRef,\n ElementRef,\n EventEmitter,\n Input,\n NgZone,\n OnChanges,\n Output,\n SimpleChanges,\n ViewChild,\n inject,\n} from '@angular/core';\nimport {\n SeatingChart as CoreSeatingChart,\n SEATING_CHART_IDENTITY_PROPS,\n bindSeatingChartHandle,\n buildSeatingChartOptions,\n type RendererViewMode,\n type SeatingChartHandle,\n type SeatingChartOptions,\n type SelectedSeat,\n type HoldResult,\n type BestAvailableResult,\n type GAAreaAvailability,\n type SeatHoverDetails,\n type BuyerAccessToken,\n type BuyerAccessTokenProvider,\n type BuyerAccessExpiredEvent,\n type BuyerAccessUnavailableEvent,\n type SelectedObjectUnavailableEvent,\n} from '@seatlayer/js';\n\n/**\n * Angular wrapper around the framework-agnostic `@seatlayer/js` SDK.\n *\n * Standalone, so it is imported directly rather than through an NgModule.\n *\n * The canvas is created once and torn down on destroy. Only the inputs that\n * change the chart's identity (`SEATING_CHART_IDENTITY_PROPS`: `event`,\n * `apiBase`, `maxSelection`, `publicKey`, `locale`, `currency`,\n * `colorblindSafe`, `initialView`, `errorDisplay`) trigger a rebuild, so an\n * unrelated change-detection pass never destroys the canvas mid-selection.\n *\n * @example\n * ```html\n * <seatlayer-seating-chart\n * #chart\n * event=\"summer-gala\"\n * (selectionChange)=\"onSelectionChange($event)\"\n * (hold)=\"onHold($event)\"\n * />\n * <button (click)=\"chart.hold()\">Continue</button>\n * ```\n */\n@Component({\n selector: 'seatlayer-seating-chart',\n standalone: true,\n template: '<div #container class=\"seatlayer-container\"></div>',\n styles: [':host { display: block; } .seatlayer-container { width: 100%; height: 100%; }'],\n changeDetection: ChangeDetectionStrategy.OnPush,\n})\nexport class SeatLayerSeatingChartComponent implements OnChanges {\n /** Event key to render. Changing it rebuilds the chart. */\n @Input({ required: true }) event!: string;\n\n /** API base URL. Defaults to the public API. */\n @Input() apiBase?: string;\n\n /** Cap on how many seats a buyer may select. */\n @Input() maxSelection?: number;\n\n /** Publishable key, when your integration uses one. */\n @Input() publicKey?: string;\n\n /** BCP-47 locale for built-in copy. */\n @Input() locale?: string;\n\n /** ISO currency for price formatting. */\n @Input() currency?: string;\n\n /** Render with colorblind-safe seat glyphs. */\n @Input() colorblindSafe?: boolean;\n\n /**\n * Initial canvas projection. Read once when the chart is built, so changing\n * it rebuilds.\n * @deprecated `'isometric'` and `'perspective'` are retired in favour of the\n * real 3D venue view; use `'flat'`.\n */\n @Input() initialView?: RendererViewMode;\n\n /**\n * What the BUYER sees when the chart cannot load: `'message'` (default) is a\n * styleable notice with a Try again button, `'none'` is silent for hosts that\n * render their own failure UI from `errored`.\n */\n @Input() errorDisplay?: 'message' | 'none';\n\n /** Show the built-in seat tooltip. Set false to draw your own from `seatHover`. */\n @Input() seatTooltip?: boolean;\n\n /** Copy overrides, read once per rebuild. */\n @Input() messages?: SeatingChartOptions['messages'];\n\n /**\n * Sales Channels: mint a buyer access session on demand. Called with a\n * `reason`; returns `{ token, expiresAt }` from YOUR backend. The token is\n * held in memory only — never storage, never a URL, never a log.\n */\n @Input() buyerAccessTokenProvider?: BuyerAccessTokenProvider;\n\n /** One-shot session for hosts that own the lifecycle. Cannot be renewed. */\n @Input() buyerAccessToken?: string | BuyerAccessToken;\n\n /** The buyer's selection changed. */\n @Output() readonly selectionChange: EventEmitter<SelectedSeat[]> = new EventEmitter<SelectedSeat[]>();\n\n /** A hold succeeded. */\n @Output() readonly hold: EventEmitter<HoldResult> = new EventEmitter<HoldResult>();\n\n /** A previous hold was restored on mount. */\n @Output() readonly holdRestored: EventEmitter<HoldResult> = new EventEmitter<HoldResult>();\n\n /** The active hold lapsed. */\n @Output() readonly holdExpired: EventEmitter<void> = new EventEmitter<void>();\n\n /** A GA area was clicked. */\n @Output() readonly gaClick: EventEmitter<GAAreaAvailability> = new EventEmitter<GAAreaAvailability>();\n\n /** Something failed — a network error, a rejected hold. */\n @Output() readonly errored: EventEmitter<unknown> = new EventEmitter<unknown>();\n\n /** A floor deck was tapped in the 3D view. */\n @Output() readonly deckTap: EventEmitter<string> = new EventEmitter<string>();\n\n /** A transient hint worth showing the buyer, or `null` to clear it. */\n @Output() readonly hint: EventEmitter<string | null> = new EventEmitter<string | null>();\n\n /** The pointer moved onto a seat, or off one (`null`). */\n @Output() readonly seatHover: EventEmitter<SeatHoverDetails | null> = new EventEmitter<SeatHoverDetails | null>();\n\n /** The buyer access session lapsed; `refreshed` says whether it recovered. */\n @Output() readonly accessExpired: EventEmitter<BuyerAccessExpiredEvent> =\n new EventEmitter<BuyerAccessExpiredEvent>();\n\n /** Private inventory is unavailable and refreshing will not fix it. */\n @Output() readonly accessUnavailable: EventEmitter<BuyerAccessUnavailableEvent> =\n new EventEmitter<BuyerAccessUnavailableEvent>();\n\n /** Selected-but-unheld units stopped being selectable. */\n @Output() readonly selectedObjectUnavailable: EventEmitter<SelectedObjectUnavailableEvent> =\n new EventEmitter<SelectedObjectUnavailableEvent>();\n\n @ViewChild('container', { static: true })\n private readonly container!: ElementRef<HTMLDivElement>;\n\n private readonly zone = inject(NgZone);\n private chart: CoreSeatingChart | null = null;\n\n /**\n * Inputs that require tearing the canvas down and rebuilding it. The shared\n * list from `@seatlayer/js`, not a hand-copied one — this is exactly the place\n * Angular fell two inputs behind React.\n */\n private static readonly REBUILD_INPUTS = SEATING_CHART_IDENTITY_PROPS;\n\n /**\n * The canonical forwarding object. Every imperative method below is a\n * one-line delegate to it, so the component cannot forward a method the other\n * wrappers do not, or miss one they do.\n */\n private readonly handle: SeatingChartHandle = bindSeatingChartHandle(() => this.chart);\n\n constructor() {\n inject(DestroyRef).onDestroy(() => this.destroy());\n }\n\n ngOnChanges(changes: SimpleChanges): void {\n const needsRebuild = SeatLayerSeatingChartComponent.REBUILD_INPUTS.some((name) => name in changes);\n if (needsRebuild) {\n this.build();\n }\n }\n\n // ---------- imperative API, for a template ref ----------\n\n /** Hold the current selection. Resolves the hold, or `null` on a 409 conflict. */\n holdSelection(options?: { ttlMs?: number }): Promise<HoldResult | null> {\n return this.handle.hold(options);\n }\n\n /** Restore an active hold by its opaque id. */\n resumeHold(holdId: string): Promise<HoldResult | null> {\n return this.handle.resumeHold(holdId);\n }\n\n /** Current active hold known to the chart. */\n getCurrentHold(): HoldResult | null {\n return this.handle.getCurrentHold();\n }\n\n /** GA areas with live remaining capacity. */\n getGAAreas(): GAAreaAvailability[] {\n return this.handle.getGAAreas();\n }\n\n /** Atomically hold a quantity from one GA area. */\n holdGA(\n areaId: string,\n qty: number,\n options?: { tierId?: string | null; ttlMs?: number },\n ): Promise<HoldResult | null> {\n return this.handle.holdGA(areaId, qty, options);\n }\n\n /** Ask the server for the `qty` best free seats and hold them atomically. */\n bestAvailable(qty: number, categoryKey?: string): Promise<BestAvailableResult | null> {\n return this.handle.bestAvailable(qty, categoryKey);\n }\n\n /** Release the current hold (if any). */\n release(): Promise<void> {\n return this.handle.release();\n }\n\n /** Release some held labels while keeping the remainder active. */\n releaseLabels(labels: string[]): Promise<boolean> {\n return this.handle.releaseLabels(labels);\n }\n\n /** The current selection, with prices resolved from the chart categories. */\n getSelection(): SelectedSeat[] {\n return this.handle.getSelection();\n }\n\n /** Choose a ticket tier for a selected seat; `null` reverts to the default. */\n setSeatTier(seatId: string, tierId: string | null): void {\n this.handle.setSeatTier(seatId, tierId);\n }\n\n /** Floors of a multi-floor chart. Empty before the first render. */\n getFloors(): { id: string; name: string }[] {\n return this.handle.getFloors();\n }\n\n /** Switch the shown floor (2D). No-ops on single-floor charts. */\n setFloor(floorId: string): void {\n this.handle.setFloor(floorId);\n }\n\n /** Toggle colorblind-safe rendering at runtime. */\n setColorblindSafe(on: boolean): void {\n this.handle.setColorblindSafe(on);\n }\n\n /** Zoom in one step (same increment as the wheel/pinch gesture). */\n zoomIn(): void {\n this.handle.zoomIn();\n }\n\n /** Zoom out one step. */\n zoomOut(): void {\n this.handle.zoomOut();\n }\n\n /** Reset the camera so the whole chart fits the container. */\n zoomToFit(): void {\n this.handle.zoomToFit();\n }\n\n /**\n * Re-acquire the buyer access session after your app re-authorizes the buyer\n * (Sales Channels). Resolves false when the chart is not access-scoped.\n */\n refreshAccess(): Promise<boolean> {\n return this.handle.refreshAccess();\n }\n\n // ---------- internals ----------\n\n private build(): void {\n const element = this.container?.nativeElement;\n if (!element) return;\n\n this.destroy();\n\n // The chart runs a rAF render loop and pointer handlers. Left inside the\n // Angular zone, every frame would schedule change detection for the whole\n // application — so it is built outside, and each callback re-enters the zone\n // only to emit, which is the only part Angular needs to see.\n this.zone.runOutsideAngular(() => {\n const emit = <T>(emitter: EventEmitter<T>, value: T) =>\n this.zone.run(() => emitter.emit(value));\n\n const instance = new CoreSeatingChart(buildSeatingChartOptions(\n element,\n {\n event: this.event,\n apiBase: this.apiBase,\n maxSelection: this.maxSelection,\n publicKey: this.publicKey,\n locale: this.locale,\n currency: this.currency,\n colorblindSafe: this.colorblindSafe,\n initialView: this.initialView,\n errorDisplay: this.errorDisplay,\n messages: this.messages,\n seatTooltip: this.seatTooltip,\n buyerAccessTokenProvider: this.buyerAccessTokenProvider,\n buyerAccessToken: this.buyerAccessToken,\n },\n {\n onSelectionChange: (seats) => emit(this.selectionChange, seats),\n onHold: (result) => emit(this.hold, result),\n onHoldRestored: (result) => emit(this.holdRestored, result),\n onHoldExpired: () => this.zone.run(() => this.holdExpired.emit()),\n onGAClick: (area) => emit(this.gaClick, area),\n onError: (error) => emit(this.errored, error),\n onDeckTap: (floorId) => emit(this.deckTap, floorId),\n onHint: (message) => emit(this.hint, message),\n onSeatHover: (details) => emit(this.seatHover, details),\n onAccessExpired: (state) => emit(this.accessExpired, state),\n onAccessUnavailable: (state) => emit(this.accessUnavailable, state),\n onSelectedObjectUnavailable: (state) => emit(this.selectedObjectUnavailable, state),\n },\n ));\n\n this.chart = instance;\n void instance.render();\n });\n }\n\n private destroy(): void {\n this.chart?.destroy();\n this.chart = null;\n }\n}\n","/**\n * @seatlayer/angular — the Angular wrapper for the SeatLayer embed SDK.\n *\n * The component is standalone; import it directly rather than through an\n * NgModule.\n */\nexport { SeatLayerSeatingChartComponent } from './seating-chart.component';\n\nexport type {\n SelectedSeat,\n HoldResult,\n BestAvailableResult,\n GAAreaAvailability,\n HoldLineItem,\n SeatHoverDetails,\n} from '@seatlayer/js';\n\n// Sales Channels — buyer access sessions for private channel inventory.\nexport type {\n BuyerAccessToken,\n BuyerAccessTokenProvider,\n BuyerAccessRefreshReason,\n BuyerAccessUnavailableReason,\n BuyerAccessExpiredEvent,\n BuyerAccessUnavailableEvent,\n SelectedObjectUnavailableEvent,\n} from '@seatlayer/js';\n\n// The framework-agnostic widget class — for the one-call modal (SeatPickerWidget.open()).\nexport { SeatPicker as SeatPickerWidget } from '@seatlayer/js';\n\n// Host-side embed helper: grows the iframe on `seatlayer:height` and pins it on\n// `seatlayer:fullscreen`. Angular hosts depend on this package alone, so it has to\n// be reachable here rather than only from @seatlayer/js.\nexport { attachPickerFrame } from '@seatlayer/js';\nexport type { AttachPickerFrameOptions } from '@seatlayer/js';\n","/**\n * Generated bundle index. Do not edit.\n */\n\nexport * from './index';\n"],"names":["CoreSeatingChart"],"mappings":";;;;;AAkCA;;;;;;;;;;;;;;;;;;;;;AAqBG;MAQU,8BAA8B,CAAA;;AAEd,IAAA,KAAK;;AAGvB,IAAA,OAAO;;AAGP,IAAA,YAAY;;AAGZ,IAAA,SAAS;;AAGT,IAAA,MAAM;;AAGN,IAAA,QAAQ;;AAGR,IAAA,cAAc;AAEvB;;;;;AAKG;AACM,IAAA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YAAY,EAAA,CAAA;sBAApB;gBAGQ,WAAW,EAAA,CAAA;sBAAnB;gBAGQ,QAAQ,EAAA,CAAA;sBAAhB;gBAOQ,wBAAwB,EAAA,CAAA;sBAAhC;gBAGQ,gBAAgB,EAAA,CAAA;sBAAxB;gBAGkB,eAAe,EAAA,CAAA;sBAAjC;gBAGkB,IAAI,EAAA,CAAA;sBAAtB;gBAGkB,YAAY,EAAA,CAAA;sBAA9B;gBAGkB,WAAW,EAAA,CAAA;sBAA7B;gBAGkB,OAAO,EAAA,CAAA;sBAAzB;gBAGkB,OAAO,EAAA,CAAA;sBAAzB;gBAGkB,OAAO,EAAA,CAAA;sBAAzB;gBAGkB,IAAI,EAAA,CAAA;sBAAtB;gBAGkB,SAAS,EAAA,CAAA;sBAA3B;gBAGkB,aAAa,EAAA,CAAA;sBAA/B;gBAIkB,iBAAiB,EAAA,CAAA;sBAAnC;gBAIkB,yBAAyB,EAAA,CAAA;sBAA3C;gBAIgB,SAAS,EAAA,CAAA;sBADzB,SAAS;AAAC,gBAAA,IAAA,EAAA,CAAA,WAAW,EAAE,EAAE,MAAM,EAAE,IAAI,EAAE;;;AC3J1C;;;;;AAKG;;ACLH;;AAEG;;;;"}
1
+ {"version":3,"file":"seatlayer-angular.mjs","sources":["../../src/seating-chart.component.ts","../../src/index.ts","../../src/seatlayer-angular.ts"],"sourcesContent":["import {\n ChangeDetectionStrategy,\n Component,\n DestroyRef,\n ElementRef,\n EventEmitter,\n Input,\n NgZone,\n OnChanges,\n Output,\n SimpleChanges,\n ViewChild,\n inject,\n} from '@angular/core';\nimport {\n SeatingChart as CoreSeatingChart,\n SEATING_CHART_IDENTITY_PROPS,\n bindSeatingChartHandle,\n buildSeatingChartOptions,\n type RendererViewMode,\n type SeatingChartHandle,\n type SeatingChartOptions,\n type SelectedSeat,\n type HoldResult,\n type BestAvailableResult,\n type GAAreaAvailability,\n type SeatHoverDetails,\n type PickerSelectionValidity,\n type BuyerAccessToken,\n type BuyerAccessTokenProvider,\n type BuyerAccessExpiredEvent,\n type BuyerAccessUnavailableEvent,\n type SelectedObjectUnavailableEvent,\n} from '@seatlayer/js';\n\n/**\n * Angular wrapper around the framework-agnostic `@seatlayer/js` SDK.\n *\n * Standalone, so it is imported directly rather than through an NgModule.\n *\n * The canvas is created once and torn down on destroy. Only the inputs that\n * change the chart's identity (`SEATING_CHART_IDENTITY_PROPS`: `event`,\n * `apiBase`, `maxSelection`, `numberOfPlacesToSelect`, `publicKey`, `locale`, `currency`,\n * `colorblindSafe`, `initialView`, `errorDisplay`) trigger a rebuild, so an\n * unrelated change-detection pass never destroys the canvas mid-selection.\n *\n * @example\n * ```html\n * <seatlayer-seating-chart\n * #chart\n * event=\"summer-gala\"\n * (selectionChange)=\"onSelectionChange($event)\"\n * (hold)=\"onHold($event)\"\n * />\n * <button (click)=\"chart.hold()\">Continue</button>\n * ```\n */\n@Component({\n selector: 'seatlayer-seating-chart',\n standalone: true,\n template: '<div #container class=\"seatlayer-container\"></div>',\n styles: [':host { display: block; } .seatlayer-container { width: 100%; height: 100%; }'],\n changeDetection: ChangeDetectionStrategy.OnPush,\n})\nexport class SeatLayerSeatingChartComponent implements OnChanges {\n /** Event key to render. Changing it rebuilds the chart. */\n @Input({ required: true }) event!: string;\n\n /** API base URL. Defaults to the public API. */\n @Input() apiBase?: string;\n\n /** Cap on how many seats a buyer may select. */\n @Input() maxSelection?: number;\n\n /** Object ids or public labels selected after availability loads. */\n @Input() selectedObjects?: string[];\n\n /** Object ids or public labels the buyer may select. */\n @Input() selectableObjects?: string[] | null;\n\n /** Exact ticket count required for a valid selection. */\n @Input() numberOfPlacesToSelect?: number;\n\n /** Publishable key, when your integration uses one. */\n @Input() publicKey?: string;\n\n /** BCP-47 locale for built-in copy. */\n @Input() locale?: string;\n\n /** ISO currency for price formatting. */\n @Input() currency?: string;\n\n /** Render with colorblind-safe seat glyphs. */\n @Input() colorblindSafe?: boolean;\n\n /**\n * Initial canvas projection. Read once when the chart is built, so changing\n * it rebuilds.\n * @deprecated `'isometric'` and `'perspective'` are retired in favour of the\n * real 3D venue view; use `'flat'`.\n */\n @Input() initialView?: RendererViewMode;\n\n /**\n * What the BUYER sees when the chart cannot load: `'message'` (default) is a\n * styleable notice with a Try again button, `'none'` is silent for hosts that\n * render their own failure UI from `errored`.\n */\n @Input() errorDisplay?: 'message' | 'none';\n\n /** Show the built-in seat tooltip. Set false to draw your own from `seatHover`. */\n @Input() seatTooltip?: boolean;\n\n /** Copy overrides, read once per rebuild. */\n @Input() messages?: SeatingChartOptions['messages'];\n\n /**\n * Sales Channels: mint a buyer access session on demand. Called with a\n * `reason`; returns `{ token, expiresAt }` from YOUR backend. The token is\n * held in memory only — never storage, never a URL, never a log.\n */\n @Input() buyerAccessTokenProvider?: BuyerAccessTokenProvider;\n\n /** One-shot session for hosts that own the lifecycle. Cannot be renewed. */\n @Input() buyerAccessToken?: string | BuyerAccessToken;\n\n /** The buyer's selection changed. */\n @Output() readonly selectionChange: EventEmitter<SelectedSeat[]> = new EventEmitter<SelectedSeat[]>();\n\n /** Exact-count state changed. */\n @Output() readonly selectionValidityChange: EventEmitter<PickerSelectionValidity> =\n new EventEmitter<PickerSelectionValidity>();\n\n /** The exact count was reached. */\n @Output() readonly selectionValid: EventEmitter<SelectedSeat[]> = new EventEmitter<SelectedSeat[]>();\n\n /** The selection is not at the exact count. */\n @Output() readonly selectionInvalid: EventEmitter<PickerSelectionValidity> =\n new EventEmitter<PickerSelectionValidity>();\n\n /** The active selection cap was reached. */\n @Output() readonly selectionLimit: EventEmitter<number> = new EventEmitter<number>();\n\n /** A hold succeeded. */\n @Output() readonly hold: EventEmitter<HoldResult> = new EventEmitter<HoldResult>();\n\n /** A previous hold was restored on mount. */\n @Output() readonly holdRestored: EventEmitter<HoldResult> = new EventEmitter<HoldResult>();\n\n /** The active hold lapsed. */\n @Output() readonly holdExpired: EventEmitter<void> = new EventEmitter<void>();\n\n /** A GA area was clicked. */\n @Output() readonly gaClick: EventEmitter<GAAreaAvailability> = new EventEmitter<GAAreaAvailability>();\n\n /** Something failed — a network error, a rejected hold. */\n @Output() readonly errored: EventEmitter<unknown> = new EventEmitter<unknown>();\n\n /** A floor deck was tapped in the 3D view. */\n @Output() readonly deckTap: EventEmitter<string> = new EventEmitter<string>();\n\n /** A transient hint worth showing the buyer, or `null` to clear it. */\n @Output() readonly hint: EventEmitter<string | null> = new EventEmitter<string | null>();\n\n /** The pointer moved onto a seat, or off one (`null`). */\n @Output() readonly seatHover: EventEmitter<SeatHoverDetails | null> = new EventEmitter<SeatHoverDetails | null>();\n\n /** The buyer access session lapsed; `refreshed` says whether it recovered. */\n @Output() readonly accessExpired: EventEmitter<BuyerAccessExpiredEvent> =\n new EventEmitter<BuyerAccessExpiredEvent>();\n\n /** Private inventory is unavailable and refreshing will not fix it. */\n @Output() readonly accessUnavailable: EventEmitter<BuyerAccessUnavailableEvent> =\n new EventEmitter<BuyerAccessUnavailableEvent>();\n\n /** Selected-but-unheld units stopped being selectable. */\n @Output() readonly selectedObjectUnavailable: EventEmitter<SelectedObjectUnavailableEvent> =\n new EventEmitter<SelectedObjectUnavailableEvent>();\n\n @ViewChild('container', { static: true })\n private readonly container!: ElementRef<HTMLDivElement>;\n\n private readonly zone = inject(NgZone);\n private chart: CoreSeatingChart | null = null;\n\n /**\n * Inputs that require tearing the canvas down and rebuilding it. The shared\n * list from `@seatlayer/js`, not a hand-copied one — this is exactly the place\n * Angular fell two inputs behind React.\n */\n private static readonly REBUILD_INPUTS = SEATING_CHART_IDENTITY_PROPS;\n\n /**\n * The canonical forwarding object. Every imperative method below is a\n * one-line delegate to it, so the component cannot forward a method the other\n * wrappers do not, or miss one they do.\n */\n private readonly handle: SeatingChartHandle = bindSeatingChartHandle(() => this.chart);\n\n constructor() {\n inject(DestroyRef).onDestroy(() => this.destroy());\n }\n\n ngOnChanges(changes: SimpleChanges): void {\n const needsRebuild = SeatLayerSeatingChartComponent.REBUILD_INPUTS.some((name) => name in changes);\n if (needsRebuild) {\n this.build();\n }\n }\n\n // ---------- imperative API, for a template ref ----------\n\n /** Hold the current selection. Resolves the hold, or `null` on a 409 conflict. */\n holdSelection(options?: { ttlMs?: number }): Promise<HoldResult | null> {\n return this.handle.hold(options);\n }\n\n /** Restore an active hold by its opaque id. */\n resumeHold(holdId: string): Promise<HoldResult | null> {\n return this.handle.resumeHold(holdId);\n }\n\n /** Current active hold known to the chart. */\n getCurrentHold(): HoldResult | null {\n return this.handle.getCurrentHold();\n }\n\n /** GA areas with live remaining capacity. */\n getGAAreas(): GAAreaAvailability[] {\n return this.handle.getGAAreas();\n }\n\n /** Atomically hold a quantity from one GA area. */\n holdGA(\n areaId: string,\n qty: number,\n options?: { tierId?: string | null; ttlMs?: number },\n ): Promise<HoldResult | null> {\n return this.handle.holdGA(areaId, qty, options);\n }\n\n /** Ask the server for the `qty` best free seats and hold them atomically. */\n bestAvailable(qty: number, categoryKey?: string): Promise<BestAvailableResult | null> {\n return this.handle.bestAvailable(qty, categoryKey);\n }\n\n /** Release the current hold (if any). */\n release(): Promise<void> {\n return this.handle.release();\n }\n\n /** Release some held labels while keeping the remainder active. */\n releaseLabels(labels: string[]): Promise<boolean> {\n return this.handle.releaseLabels(labels);\n }\n\n /** The current selection, with prices resolved from the chart categories. */\n getSelection(): SelectedSeat[] {\n return this.handle.getSelection();\n }\n\n selectObjects(objects: string[]): SelectedSeat[] {\n return this.handle.selectObjects(objects);\n }\n\n deselectObjects(objects: string[]): void {\n this.handle.deselectObjects(objects);\n }\n\n clearSelection(): void {\n this.handle.clearSelection();\n }\n\n selectCategories(categoryKeys: string[]): SelectedSeat[] {\n return this.handle.selectCategories(categoryKeys);\n }\n\n deselectCategories(categoryKeys: string[]): void {\n this.handle.deselectCategories(categoryKeys);\n }\n\n setSelectableObjects(objects: string[] | null): void {\n this.handle.setSelectableObjects(objects);\n }\n\n setMaxSelection(maxSelection: number): void {\n this.handle.setMaxSelection(maxSelection);\n }\n\n getSelectionValidity(): PickerSelectionValidity | null {\n return this.handle.getSelectionValidity();\n }\n\n /** Choose a ticket tier for a selected seat; `null` reverts to the default. */\n setSeatTier(seatId: string, tierId: string | null): void {\n this.handle.setSeatTier(seatId, tierId);\n }\n\n /** Floors of a multi-floor chart. Empty before the first render. */\n getFloors(): { id: string; name: string }[] {\n return this.handle.getFloors();\n }\n\n /** Switch the shown floor (2D). No-ops on single-floor charts. */\n setFloor(floorId: string): void {\n this.handle.setFloor(floorId);\n }\n\n /** Toggle colorblind-safe rendering at runtime. */\n setColorblindSafe(on: boolean): void {\n this.handle.setColorblindSafe(on);\n }\n\n /** Zoom in one step (same increment as the wheel/pinch gesture). */\n zoomIn(): void {\n this.handle.zoomIn();\n }\n\n /** Zoom out one step. */\n zoomOut(): void {\n this.handle.zoomOut();\n }\n\n /** Reset the camera so the whole chart fits the container. */\n zoomToFit(): void {\n this.handle.zoomToFit();\n }\n\n /**\n * Re-acquire the buyer access session after your app re-authorizes the buyer\n * (Sales Channels). Resolves false when the chart is not access-scoped.\n */\n refreshAccess(): Promise<boolean> {\n return this.handle.refreshAccess();\n }\n\n // ---------- internals ----------\n\n private build(): void {\n const element = this.container?.nativeElement;\n if (!element) return;\n\n this.destroy();\n\n // The chart runs a rAF render loop and pointer handlers. Left inside the\n // Angular zone, every frame would schedule change detection for the whole\n // application — so it is built outside, and each callback re-enters the zone\n // only to emit, which is the only part Angular needs to see.\n this.zone.runOutsideAngular(() => {\n const emit = <T>(emitter: EventEmitter<T>, value: T) =>\n this.zone.run(() => emitter.emit(value));\n\n const instance = new CoreSeatingChart(buildSeatingChartOptions(\n element,\n {\n event: this.event,\n apiBase: this.apiBase,\n maxSelection: this.maxSelection,\n selectedObjects: this.selectedObjects,\n selectableObjects: this.selectableObjects,\n numberOfPlacesToSelect: this.numberOfPlacesToSelect,\n publicKey: this.publicKey,\n locale: this.locale,\n currency: this.currency,\n colorblindSafe: this.colorblindSafe,\n initialView: this.initialView,\n errorDisplay: this.errorDisplay,\n messages: this.messages,\n seatTooltip: this.seatTooltip,\n buyerAccessTokenProvider: this.buyerAccessTokenProvider,\n buyerAccessToken: this.buyerAccessToken,\n },\n {\n onSelectionChange: (seats) => emit(this.selectionChange, seats),\n onSelectionValidityChange: (state) => emit(this.selectionValidityChange, state),\n onSelectionValid: (seats) => emit(this.selectionValid, seats),\n onSelectionInvalid: (state) => emit(this.selectionInvalid, state),\n onSelectionLimit: (max) => emit(this.selectionLimit, max),\n onHold: (result) => emit(this.hold, result),\n onHoldRestored: (result) => emit(this.holdRestored, result),\n onHoldExpired: () => this.zone.run(() => this.holdExpired.emit()),\n onGAClick: (area) => emit(this.gaClick, area),\n onError: (error) => emit(this.errored, error),\n onDeckTap: (floorId) => emit(this.deckTap, floorId),\n onHint: (message) => emit(this.hint, message),\n onSeatHover: (details) => emit(this.seatHover, details),\n onAccessExpired: (state) => emit(this.accessExpired, state),\n onAccessUnavailable: (state) => emit(this.accessUnavailable, state),\n onSelectedObjectUnavailable: (state) => emit(this.selectedObjectUnavailable, state),\n },\n ));\n\n this.chart = instance;\n void instance.render();\n });\n }\n\n private destroy(): void {\n this.chart?.destroy();\n this.chart = null;\n }\n}\n","/**\n * @seatlayer/angular — the Angular wrapper for the SeatLayer embed SDK.\n *\n * The component is standalone; import it directly rather than through an\n * NgModule.\n */\nexport { SeatLayerSeatingChartComponent } from './seating-chart.component';\n\nexport type {\n SelectedSeat,\n HoldResult,\n BestAvailableResult,\n GAAreaAvailability,\n HoldLineItem,\n SeatHoverDetails,\n} from '@seatlayer/js';\n\n// Sales Channels — buyer access sessions for private channel inventory.\nexport type {\n BuyerAccessToken,\n BuyerAccessTokenProvider,\n BuyerAccessRefreshReason,\n BuyerAccessUnavailableReason,\n BuyerAccessExpiredEvent,\n BuyerAccessUnavailableEvent,\n SelectedObjectUnavailableEvent,\n} from '@seatlayer/js';\n\n// The framework-agnostic widget class — for the one-call modal (SeatPickerWidget.open()).\nexport { SeatPicker as SeatPickerWidget } from '@seatlayer/js';\n\n// Host-side embed helper: grows the iframe on `seatlayer:height` and pins it on\n// `seatlayer:fullscreen`. Angular hosts depend on this package alone, so it has to\n// be reachable here rather than only from @seatlayer/js.\nexport { attachPickerFrame } from '@seatlayer/js';\nexport type { AttachPickerFrameOptions } from '@seatlayer/js';\n","/**\n * Generated bundle index. Do not edit.\n */\n\nexport * from './index';\n"],"names":["CoreSeatingChart"],"mappings":";;;;;AAmCA;;;;;;;;;;;;;;;;;;;;;AAqBG;MAQU,8BAA8B,CAAA;;AAEd,IAAA,KAAK;;AAGvB,IAAA,OAAO;;AAGP,IAAA,YAAY;;AAGZ,IAAA,eAAe;;AAGf,IAAA,iBAAiB;;AAGjB,IAAA,sBAAsB;;AAGtB,IAAA,SAAS;;AAGT,IAAA,MAAM;;AAGN,IAAA,QAAQ;;AAGR,IAAA,cAAc;AAEvB;;;;;AAKG;AACM,IAAA,WAAW;AAEpB;;;;AAIG;AACM,IAAA,YAAY;;AAGZ,IAAA,WAAW;;AAGX,IAAA,QAAQ;AAEjB;;;;AAIG;AACM,IAAA,wBAAwB;;AAGxB,IAAA,gBAAgB;;AAGN,IAAA,eAAe,GAAiC,IAAI,YAAY,EAAkB;;AAGlF,IAAA,uBAAuB,GACxC,IAAI,YAAY,EAA2B;;AAG1B,IAAA,cAAc,GAAiC,IAAI,YAAY,EAAkB;;AAGjF,IAAA,gBAAgB,GACjC,IAAI,YAAY,EAA2B;;AAG1B,IAAA,cAAc,GAAyB,IAAI,YAAY,EAAU;;AAGjE,IAAA,IAAI,GAA6B,IAAI,YAAY,EAAc;;AAG/D,IAAA,YAAY,GAA6B,IAAI,YAAY,EAAc;;AAGvE,IAAA,WAAW,GAAuB,IAAI,YAAY,EAAQ;;AAG1D,IAAA,OAAO,GAAqC,IAAI,YAAY,EAAsB;;AAGlF,IAAA,OAAO,GAA0B,IAAI,YAAY,EAAW;;AAG5D,IAAA,OAAO,GAAyB,IAAI,YAAY,EAAU;;AAG1D,IAAA,IAAI,GAAgC,IAAI,YAAY,EAAiB;;AAGrE,IAAA,SAAS,GA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gBAGkB,IAAI,EAAA,CAAA;sBAAtB;gBAGkB,YAAY,EAAA,CAAA;sBAA9B;gBAGkB,WAAW,EAAA,CAAA;sBAA7B;gBAGkB,OAAO,EAAA,CAAA;sBAAzB;gBAGkB,OAAO,EAAA,CAAA;sBAAzB;gBAGkB,OAAO,EAAA,CAAA;sBAAzB;gBAGkB,IAAI,EAAA,CAAA;sBAAtB;gBAGkB,SAAS,EAAA,CAAA;sBAA3B;gBAGkB,aAAa,EAAA,CAAA;sBAA/B;gBAIkB,iBAAiB,EAAA,CAAA;sBAAnC;gBAIkB,yBAAyB,EAAA,CAAA;sBAA3C;gBAIgB,SAAS,EAAA,CAAA;sBADzB,SAAS;AAAC,gBAAA,IAAA,EAAA,CAAA,WAAW,EAAE,EAAE,MAAM,EAAE,IAAI,EAAE;;;ACnL1C;;;;;AAKG;;ACLH;;AAEG;;;;"}
@@ -1,5 +1,5 @@
1
1
  import { EventEmitter, OnChanges, SimpleChanges } from '@angular/core';
2
- import { type RendererViewMode, type SeatingChartOptions, type SelectedSeat, type HoldResult, type BestAvailableResult, type GAAreaAvailability, type SeatHoverDetails, type BuyerAccessToken, type BuyerAccessTokenProvider, type BuyerAccessExpiredEvent, type BuyerAccessUnavailableEvent, type SelectedObjectUnavailableEvent } from '@seatlayer/js';
2
+ import { type RendererViewMode, type SeatingChartOptions, type SelectedSeat, type HoldResult, type BestAvailableResult, type GAAreaAvailability, type SeatHoverDetails, type PickerSelectionValidity, type BuyerAccessToken, type BuyerAccessTokenProvider, type BuyerAccessExpiredEvent, type BuyerAccessUnavailableEvent, type SelectedObjectUnavailableEvent } from '@seatlayer/js';
3
3
  import * as i0 from "@angular/core";
4
4
  /**
5
5
  * Angular wrapper around the framework-agnostic `@seatlayer/js` SDK.
@@ -8,7 +8,7 @@ import * as i0 from "@angular/core";
8
8
  *
9
9
  * The canvas is created once and torn down on destroy. Only the inputs that
10
10
  * change the chart's identity (`SEATING_CHART_IDENTITY_PROPS`: `event`,
11
- * `apiBase`, `maxSelection`, `publicKey`, `locale`, `currency`,
11
+ * `apiBase`, `maxSelection`, `numberOfPlacesToSelect`, `publicKey`, `locale`, `currency`,
12
12
  * `colorblindSafe`, `initialView`, `errorDisplay`) trigger a rebuild, so an
13
13
  * unrelated change-detection pass never destroys the canvas mid-selection.
14
14
  *
@@ -30,6 +30,12 @@ export declare class SeatLayerSeatingChartComponent implements OnChanges {
30
30
  apiBase?: string;
31
31
  /** Cap on how many seats a buyer may select. */
32
32
  maxSelection?: number;
33
+ /** Object ids or public labels selected after availability loads. */
34
+ selectedObjects?: string[];
35
+ /** Object ids or public labels the buyer may select. */
36
+ selectableObjects?: string[] | null;
37
+ /** Exact ticket count required for a valid selection. */
38
+ numberOfPlacesToSelect?: number;
33
39
  /** Publishable key, when your integration uses one. */
34
40
  publicKey?: string;
35
41
  /** BCP-47 locale for built-in copy. */
@@ -65,6 +71,14 @@ export declare class SeatLayerSeatingChartComponent implements OnChanges {
65
71
  buyerAccessToken?: string | BuyerAccessToken;
66
72
  /** The buyer's selection changed. */
67
73
  readonly selectionChange: EventEmitter<SelectedSeat[]>;
74
+ /** Exact-count state changed. */
75
+ readonly selectionValidityChange: EventEmitter<PickerSelectionValidity>;
76
+ /** The exact count was reached. */
77
+ readonly selectionValid: EventEmitter<SelectedSeat[]>;
78
+ /** The selection is not at the exact count. */
79
+ readonly selectionInvalid: EventEmitter<PickerSelectionValidity>;
80
+ /** The active selection cap was reached. */
81
+ readonly selectionLimit: EventEmitter<number>;
68
82
  /** A hold succeeded. */
69
83
  readonly hold: EventEmitter<HoldResult>;
70
84
  /** A previous hold was restored on mount. */
@@ -127,6 +141,14 @@ export declare class SeatLayerSeatingChartComponent implements OnChanges {
127
141
  releaseLabels(labels: string[]): Promise<boolean>;
128
142
  /** The current selection, with prices resolved from the chart categories. */
129
143
  getSelection(): SelectedSeat[];
144
+ selectObjects(objects: string[]): SelectedSeat[];
145
+ deselectObjects(objects: string[]): void;
146
+ clearSelection(): void;
147
+ selectCategories(categoryKeys: string[]): SelectedSeat[];
148
+ deselectCategories(categoryKeys: string[]): void;
149
+ setSelectableObjects(objects: string[] | null): void;
150
+ setMaxSelection(maxSelection: number): void;
151
+ getSelectionValidity(): PickerSelectionValidity | null;
130
152
  /** Choose a ticket tier for a selected seat; `null` reverts to the default. */
131
153
  setSeatTier(seatId: string, tierId: string | null): void;
132
154
  /** Floors of a multi-floor chart. Empty before the first render. */
@@ -152,5 +174,5 @@ export declare class SeatLayerSeatingChartComponent implements OnChanges {
152
174
  private build;
153
175
  private destroy;
154
176
  static ɵfac: i0.ɵɵFactoryDeclaration<SeatLayerSeatingChartComponent, never>;
155
- static ɵcmp: i0.ɵɵComponentDeclaration<SeatLayerSeatingChartComponent, "seatlayer-seating-chart", never, { "event": { "alias": "event"; "required": true; }; "apiBase": { "alias": "apiBase"; "required": false; }; "maxSelection": { "alias": "maxSelection"; "required": false; }; "publicKey": { "alias": "publicKey"; "required": false; }; "locale": { "alias": "locale"; "required": false; }; "currency": { "alias": "currency"; "required": false; }; "colorblindSafe": { "alias": "colorblindSafe"; "required": false; }; "initialView": { "alias": "initialView"; "required": false; }; "errorDisplay": { "alias": "errorDisplay"; "required": false; }; "seatTooltip": { "alias": "seatTooltip"; "required": false; }; "messages": { "alias": "messages"; "required": false; }; "buyerAccessTokenProvider": { "alias": "buyerAccessTokenProvider"; "required": false; }; "buyerAccessToken": { "alias": "buyerAccessToken"; "required": false; }; }, { "selectionChange": "selectionChange"; "hold": "hold"; "holdRestored": "holdRestored"; "holdExpired": "holdExpired"; "gaClick": "gaClick"; "errored": "errored"; "deckTap": "deckTap"; "hint": "hint"; "seatHover": "seatHover"; "accessExpired": "accessExpired"; "accessUnavailable": "accessUnavailable"; "selectedObjectUnavailable": "selectedObjectUnavailable"; }, never, never, true, never>;
177
+ static ɵcmp: i0.ɵɵComponentDeclaration<SeatLayerSeatingChartComponent, "seatlayer-seating-chart", never, { "event": { "alias": "event"; "required": true; }; "apiBase": { "alias": "apiBase"; "required": false; }; "maxSelection": { "alias": "maxSelection"; "required": false; }; "selectedObjects": { "alias": "selectedObjects"; "required": false; }; "selectableObjects": { "alias": "selectableObjects"; "required": false; }; "numberOfPlacesToSelect": { "alias": "numberOfPlacesToSelect"; "required": false; }; "publicKey": { "alias": "publicKey"; "required": false; }; "locale": { "alias": "locale"; "required": false; }; "currency": { "alias": "currency"; "required": false; }; "colorblindSafe": { "alias": "colorblindSafe"; "required": false; }; "initialView": { "alias": "initialView"; "required": false; }; "errorDisplay": { "alias": "errorDisplay"; "required": false; }; "seatTooltip": { "alias": "seatTooltip"; "required": false; }; "messages": { "alias": "messages"; "required": false; }; "buyerAccessTokenProvider": { "alias": "buyerAccessTokenProvider"; "required": false; }; "buyerAccessToken": { "alias": "buyerAccessToken"; "required": false; }; }, { "selectionChange": "selectionChange"; "selectionValidityChange": "selectionValidityChange"; "selectionValid": "selectionValid"; "selectionInvalid": "selectionInvalid"; "selectionLimit": "selectionLimit"; "hold": "hold"; "holdRestored": "holdRestored"; "holdExpired": "holdExpired"; "gaClick": "gaClick"; "errored": "errored"; "deckTap": "deckTap"; "hint": "hint"; "seatHover": "seatHover"; "accessExpired": "accessExpired"; "accessUnavailable": "accessUnavailable"; "selectedObjectUnavailable": "selectedObjectUnavailable"; }, never, never, true, never>;
156
178
  }
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@seatlayer/angular",
3
- "version": "0.53.0",
3
+ "version": "0.55.0",
4
4
  "description": "Angular SeatLayer SDK — one native SeatingChart wrapper plus raw JS SeatPickerWidget and iframe helper.",
5
5
  "license": "MIT",
6
6
  "homepage": "https://docs.seatlayer.io/buyer-sdk/seat-picker/",
@@ -23,8 +23,8 @@
23
23
  "ticketing"
24
24
  ],
25
25
  "dependencies": {
26
- "@seatlayer/core": "0.53.0",
27
- "@seatlayer/js": "0.53.0",
26
+ "@seatlayer/core": "0.55.0",
27
+ "@seatlayer/js": "0.55.0",
28
28
  "tslib": "^2.8.1"
29
29
  },
30
30
  "peerDependencies": {