@seatlayer/angular 0.109.2 → 0.110.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
@@ -142,6 +142,21 @@ apply the package price, tax, and payment decision before booking the
142
142
  identity-only allocation. `SeatLayerSeasonPickerComponent` is supported in
143
143
  `@seatlayer/angular` `0.72.0` and newer.
144
144
 
145
+ The component exposes the same calls as `@seatlayer/js`, including Season
146
+ Best Available: `seasonPicker.holdBestAvailable(2, 'sop_checkout_1184', {
147
+ categoryKey: 'stalls' })` holds the best two seats free on every date.
148
+
149
+ To sell child or concession seats too, bind `[priceTypes]="['adult', 'child']"`:
150
+ the buyer chooses a type per seat before the hold, and the handoff's `seats`
151
+ lists each seat's `priceTypeKey`. `seasonPicker.holdSameSeat(labels,
152
+ operationId, { 'A-2': 'child' })` names them yourself; a label left out is adult.
153
+
154
+ The picker opens on step 1, the package with its dates and prices. Bind
155
+ `package="spl_half"` (the package's key) to open on that package instead of the
156
+ Season's first one; a host token is already bound to one package, so it ignores
157
+ this. If your own checkout emails a ticket for every date, bind
158
+ `[ticketsByEmail]="true"` and step 1 says so.
159
+
145
160
  ## Inputs
146
161
 
147
162
  | Input | Type | Notes |
package/dist/README.md CHANGED
@@ -142,6 +142,21 @@ apply the package price, tax, and payment decision before booking the
142
142
  identity-only allocation. `SeatLayerSeasonPickerComponent` is supported in
143
143
  `@seatlayer/angular` `0.72.0` and newer.
144
144
 
145
+ The component exposes the same calls as `@seatlayer/js`, including Season
146
+ Best Available: `seasonPicker.holdBestAvailable(2, 'sop_checkout_1184', {
147
+ categoryKey: 'stalls' })` holds the best two seats free on every date.
148
+
149
+ To sell child or concession seats too, bind `[priceTypes]="['adult', 'child']"`:
150
+ the buyer chooses a type per seat before the hold, and the handoff's `seats`
151
+ lists each seat's `priceTypeKey`. `seasonPicker.holdSameSeat(labels,
152
+ operationId, { 'A-2': 'child' })` names them yourself; a label left out is adult.
153
+
154
+ The picker opens on step 1, the package with its dates and prices. Bind
155
+ `package="spl_half"` (the package's key) to open on that package instead of the
156
+ Season's first one; a host token is already bound to one package, so it ignores
157
+ this. If your own checkout emails a ticket for every date, bind
158
+ `[ticketsByEmail]="true"` and step 1 says so.
159
+
145
160
  ## Inputs
146
161
 
147
162
  | Input | Type | Notes |
@@ -377,10 +377,19 @@ class SeatLayerSeasonPickerComponent {
377
377
  buyerAccessToken;
378
378
  /** Operation restored after an uncertain create response. */
379
379
  initialOperationId;
380
+ /** The package to open on, by its key; the first package without it. */
381
+ package;
382
+ /** The host emails a ticket per date itself: step 1 says so. */
383
+ ticketsByEmail;
380
384
  /** Maximum recovery polling time. */
381
385
  recoveryTimeoutMs;
382
386
  /** Test or host fetch implementation. */
383
387
  fetch;
388
+ /**
389
+ * The price types the picker sells, e.g. `['adult', 'child']`. With a type
390
+ * besides adult, the buyer chooses one per seat before the hold.
391
+ */
392
+ priceTypes;
384
393
  /** A same-seat hold reached a safe handoff. */
385
394
  hold = new EventEmitter();
386
395
  /** The active handoff changed or was released. */
@@ -403,7 +412,7 @@ class SeatLayerSeasonPickerComponent {
403
412
  static REBUILD_INPUTS = new Set([
404
413
  'season', 'apiBase', 'publicKey', 'checkout', 'returnUrl',
405
414
  'buyerAccessTokenProvider', 'buyerAccessToken',
406
- 'initialOperationId', 'recoveryTimeoutMs', 'fetch',
415
+ 'initialOperationId', 'package', 'ticketsByEmail', 'recoveryTimeoutMs', 'fetch', 'priceTypes',
407
416
  ]);
408
417
  zone = inject(NgZone);
409
418
  picker = null;
@@ -415,9 +424,21 @@ class SeatLayerSeasonPickerComponent {
415
424
  this.build();
416
425
  }
417
426
  }
418
- /** Holds the same labels across every included occurrence. */
419
- holdSameSeat(labels, operationId) {
420
- return this.current().holdSameSeat(labels, operationId);
427
+ /**
428
+ * Holds the same labels across every included occurrence. `priceTypes` names
429
+ * each seat's price type by label (`{ 'A-2': 'child' }`); a label it leaves
430
+ * out is adult.
431
+ */
432
+ holdSameSeat(labels, operationId, priceTypes) {
433
+ return this.current().holdSameSeat(labels, operationId, priceTypes);
434
+ }
435
+ /**
436
+ * Holds the best `qty` seats free on every included performance, as a map
437
+ * selection would. Same contract as `@seatlayer/js` `holdBestAvailable`: a
438
+ * caller-stable `sop_` id, 1 to `maxSelection` seats, one call at a time.
439
+ */
440
+ holdBestAvailable(qty, operationId, options) {
441
+ return this.current().holdBestAvailable(qty, operationId, options);
421
442
  }
422
443
  /** Restores a caller-stable Season operation after uncertainty. */
423
444
  restoreOperation(operationId) {
@@ -456,8 +477,11 @@ class SeatLayerSeasonPickerComponent {
456
477
  buyerAccessTokenProvider: this.buyerAccessTokenProvider,
457
478
  buyerAccessToken: this.buyerAccessToken,
458
479
  initialOperationId: this.initialOperationId,
480
+ package: this.package,
481
+ ticketsByEmail: this.ticketsByEmail,
459
482
  recoveryTimeoutMs: this.recoveryTimeoutMs,
460
483
  fetch: this.fetch,
484
+ priceTypes: this.priceTypes,
461
485
  onHold: (value) => this.zone.run(() => this.hold.emit(value)),
462
486
  onHoldChange: (value) => this.zone.run(() => this.holdChange.emit(value)),
463
487
  onContinue: (value) => this.zone.run(() => this.continued.emit(value)),
@@ -482,7 +506,7 @@ class SeatLayerSeasonPickerComponent {
482
506
  this.picker = null;
483
507
  }
484
508
  static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "20.3.29", ngImport: i0, type: SeatLayerSeasonPickerComponent, deps: [], target: i0.ɵɵFactoryTarget.Component });
485
- static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "20.3.29", type: SeatLayerSeasonPickerComponent, isStandalone: true, selector: "seatlayer-season-picker", inputs: { season: "season", apiBase: "apiBase", publicKey: "publicKey", checkout: "checkout", returnUrl: "returnUrl", buyerAccessTokenProvider: "buyerAccessTokenProvider", buyerAccessToken: "buyerAccessToken", initialOperationId: "initialOperationId", recoveryTimeoutMs: "recoveryTimeoutMs", fetch: "fetch" }, outputs: { hold: "hold", holdChange: "holdChange", continued: "continued", renewalIntent: "renewalIntent", accessExpired: "accessExpired", accessUnavailable: "accessUnavailable", orderConfirmed: "orderConfirmed", statusChange: "statusChange", errored: "errored" }, viewQueries: [{ propertyName: "container", first: true, predicate: ["container"], descendants: true, static: true }], usesOnChanges: true, ngImport: i0, template: '<div #container class="seatlayer-season-container"></div>', isInline: true, styles: [":host{display:block}.seatlayer-season-container{width:100%}\n"], changeDetection: i0.ChangeDetectionStrategy.OnPush });
509
+ static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "20.3.29", type: SeatLayerSeasonPickerComponent, isStandalone: true, selector: "seatlayer-season-picker", inputs: { season: "season", apiBase: "apiBase", publicKey: "publicKey", checkout: "checkout", returnUrl: "returnUrl", buyerAccessTokenProvider: "buyerAccessTokenProvider", buyerAccessToken: "buyerAccessToken", initialOperationId: "initialOperationId", package: "package", ticketsByEmail: "ticketsByEmail", recoveryTimeoutMs: "recoveryTimeoutMs", fetch: "fetch", priceTypes: "priceTypes" }, outputs: { hold: "hold", holdChange: "holdChange", continued: "continued", renewalIntent: "renewalIntent", accessExpired: "accessExpired", accessUnavailable: "accessUnavailable", orderConfirmed: "orderConfirmed", statusChange: "statusChange", errored: "errored" }, viewQueries: [{ propertyName: "container", first: true, predicate: ["container"], descendants: true, static: true }], usesOnChanges: true, ngImport: i0, template: '<div #container class="seatlayer-season-container"></div>', isInline: true, styles: [":host{display:block}.seatlayer-season-container{width:100%}\n"], changeDetection: i0.ChangeDetectionStrategy.OnPush });
486
510
  }
487
511
  i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "20.3.29", ngImport: i0, type: SeatLayerSeasonPickerComponent, decorators: [{
488
512
  type: Component,
@@ -504,10 +528,16 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "20.3.29", ngImpo
504
528
  type: Input
505
529
  }], initialOperationId: [{
506
530
  type: Input
531
+ }], package: [{
532
+ type: Input
533
+ }], ticketsByEmail: [{
534
+ type: Input
507
535
  }], recoveryTimeoutMs: [{
508
536
  type: Input
509
537
  }], fetch: [{
510
538
  type: Input
539
+ }], priceTypes: [{
540
+ type: Input
511
541
  }], hold: [{
512
542
  type: Output
513
543
  }], holdChange: [{
@@ -1 +1 @@
1
- {"version":3,"file":"seatlayer-angular.mjs","sources":["../../src/seating-chart.component.ts","../../src/season-picker.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 PickerSelectionValidator,\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 /** Local buyer selection guards. Changing them rebuilds the chart. */\n @Input() selectionValidators?: PickerSelectionValidator[];\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 selectionValidators: this.selectionValidators,\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","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 SeasonPicker as CoreSeasonPicker,\n type SeasonAvailability,\n type SeasonCheckoutHandoff,\n type SeasonDescriptor,\n type SeasonPickerOptions,\n type SeasonRenewalIntent,\n type SeasonStatusEvent,\n} from '@seatlayer/js';\n\n/** Standalone Angular adapter for the distinct fixed-inclusion Season buyer flow. */\n@Component({\n selector: 'seatlayer-season-picker',\n standalone: true,\n template: '<div #container class=\"seatlayer-season-container\"></div>',\n styles: [':host { display: block; } .seatlayer-season-container { width: 100%; }'],\n changeDetection: ChangeDetectionStrategy.OnPush,\n})\nexport class SeatLayerSeasonPickerComponent implements OnChanges {\n /** Season key to render. */\n @Input({ required: true }) season!: string;\n\n /** Public API base override. */\n @Input() apiBase?: string;\n\n /** Publishable account key, accepted for snippet parity. Never sent. */\n @Input() publicKey?: string;\n\n /** Who takes the money once the package is held. Default `'handoff'`. */\n @Input() checkout?: SeasonPickerOptions['checkout'];\n\n /** Where a redirecting gateway returns the buyer, for hosted checkout. */\n @Input() returnUrl?: string;\n\n /** Refreshable one-time browser bearer provider. */\n @Input() buyerAccessTokenProvider?: SeasonPickerOptions['buyerAccessTokenProvider'];\n\n /** One-time Season browser bearer. */\n @Input() buyerAccessToken?: SeasonPickerOptions['buyerAccessToken'];\n\n /** Operation restored after an uncertain create response. */\n @Input() initialOperationId?: string;\n\n /** Maximum recovery polling time. */\n @Input() recoveryTimeoutMs?: number;\n\n /** Test or host fetch implementation. */\n @Input() fetch?: typeof fetch;\n\n /** A same-seat hold reached a safe handoff. */\n @Output() readonly hold = new EventEmitter<SeasonCheckoutHandoff>();\n\n /** The active handoff changed or was released. */\n @Output() readonly holdChange = new EventEmitter<SeasonCheckoutHandoff | null>();\n\n /** The buyer continued with an opaque handoff. */\n @Output() readonly continued = new EventEmitter<SeasonCheckoutHandoff>();\n\n /** A returning holder recorded browser intent only. */\n @Output() readonly renewalIntent = new EventEmitter<SeasonRenewalIntent>();\n\n /** Buyer access expired. */\n @Output() readonly accessExpired = new EventEmitter<unknown>();\n\n /** Buyer access cannot be recovered. */\n @Output() readonly accessUnavailable = new EventEmitter<unknown>();\n\n /** Hosted checkout only: the gateway webhook landed and the order is paid. */\n @Output() readonly orderConfirmed = new EventEmitter<unknown>();\n\n /** Buyer-visible operation status changed. */\n @Output() readonly statusChange = new EventEmitter<SeasonStatusEvent>();\n\n /** The Season buyer flow failed. */\n @Output() readonly errored = new EventEmitter<unknown>();\n\n @ViewChild('container', { static: true })\n private readonly container!: ElementRef<HTMLDivElement>;\n\n private static readonly REBUILD_INPUTS = new Set([\n 'season', 'apiBase', 'publicKey', 'checkout', 'returnUrl',\n 'buyerAccessTokenProvider', 'buyerAccessToken',\n 'initialOperationId', 'recoveryTimeoutMs', 'fetch',\n ]);\n private readonly zone = inject(NgZone);\n private picker: CoreSeasonPicker | null = null;\n\n constructor() {\n inject(DestroyRef).onDestroy(() => this.destroy());\n }\n\n ngOnChanges(changes: SimpleChanges): void {\n if (Object.keys(changes).some((name) => SeatLayerSeasonPickerComponent.REBUILD_INPUTS.has(name))) {\n this.build();\n }\n }\n\n /** Holds the same labels across every included occurrence. */\n holdSameSeat(labels: readonly string[], operationId: string): Promise<SeasonCheckoutHandoff> {\n return this.current().holdSameSeat(labels, operationId);\n }\n\n /** Restores a caller-stable Season operation after uncertainty. */\n restoreOperation(operationId: string): Promise<SeasonCheckoutHandoff | null> {\n return this.current().restoreOperation(operationId);\n }\n\n /** Releases the active selection with a caller-stable action id. */\n release(releaseActionId: string): Promise<void> {\n return this.current().release(releaseActionId);\n }\n\n /** Records renewal intent; trusted server code still inspects and commits it. */\n createRenewalIntent(offerId: string): Promise<SeasonRenewalIntent> {\n return this.current().createRenewalIntent(offerId);\n }\n\n /** Current immutable Season descriptor. */\n getDescriptor(): SeasonDescriptor | null {\n return this.picker?.getDescriptor() ?? null;\n }\n\n /** Current same-seat aggregate availability. */\n getAvailability(): SeasonAvailability | null {\n return this.picker?.getAvailability() ?? null;\n }\n\n /** Current opaque checkout handoff. */\n getHandoff(): SeasonCheckoutHandoff | null {\n return this.picker?.getHandoff() ?? null;\n }\n\n private build(): void {\n this.destroy();\n this.zone.runOutsideAngular(() => {\n const picker = new CoreSeasonPicker({\n container: this.container.nativeElement,\n season: this.season,\n apiBase: this.apiBase,\n publicKey: this.publicKey,\n checkout: this.checkout,\n returnUrl: this.returnUrl,\n buyerAccessTokenProvider: this.buyerAccessTokenProvider,\n buyerAccessToken: this.buyerAccessToken,\n initialOperationId: this.initialOperationId,\n recoveryTimeoutMs: this.recoveryTimeoutMs,\n fetch: this.fetch,\n onHold: (value) => this.zone.run(() => this.hold.emit(value)),\n onHoldChange: (value) => this.zone.run(() => this.holdChange.emit(value)),\n onContinue: (value) => this.zone.run(() => this.continued.emit(value)),\n onRenewalIntent: (value) => this.zone.run(() => this.renewalIntent.emit(value)),\n onAccessExpired: (value) => this.zone.run(() => this.accessExpired.emit(value)),\n onAccessUnavailable: (value) => this.zone.run(() => this.accessUnavailable.emit(value)),\n onOrderConfirmed: (value) => this.zone.run(() => this.orderConfirmed.emit(value)),\n onStatusChange: (value) => this.zone.run(() => this.statusChange.emit(value)),\n onError: (value) => this.zone.run(() => this.errored.emit(value)),\n });\n this.picker = picker;\n void picker.render().catch(() => undefined);\n });\n }\n\n private current(): CoreSeasonPicker {\n if (!this.picker) throw new Error('seatlayer: Angular SeasonPicker is not mounted');\n return this.picker;\n }\n\n private destroy(): void {\n this.picker?.destroy();\n this.picker = 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';\nexport { SeatLayerSeasonPickerComponent } from './season-picker.component';\n\nexport type {\n SelectedSeat,\n HoldResult,\n BestAvailableResult,\n GAAreaAvailability,\n HoldLineItem,\n SeatHoverDetails,\n SeasonAvailability,\n SeasonCheckoutHandoff,\n SeasonDescriptor,\n SeasonOperation,\n SeasonOperationState,\n SeasonPickerOptions,\n SeasonRenewalIntent,\n SeasonStatusEvent,\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","CoreSeasonPicker"],"mappings":";;;;;AAoCA;;;;;;;;;;;;;;;;;;;;;AAqBG;MAQU,8BAA8B,CAAA;;AAEd,IAAA,KAAK;;AAGvB,IAAA,OAAO;;AAGP,IAAA,YAAY;;AAGZ,IAAA,eAAe;;AAGf,IAAA,iBAAiB;;AAGjB,IAAA,sBAAsB;;AAGtB,IAAA,mBAAmB;;AAGnB,IAAA,SAAS;;AAGT,IAAA,MAAM;;AAGN,IAAA,QAAQ;;AAGR,IAAA,cAAc;AAEvB;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,EAAA,QAAA,EAAA,IAAA,EAAA,MAAA,EAAA,CAAA,+DAAA,CAAA,EAAA,eAAA,EAAA,EAAA,CAAA,uBAAA,CAAA,MAAA,EAAA,CAAA;;4FAI1D,8BAA8B,EAAA,UAAA,EAAA,CAAA;kBAP1C,SAAS;AACE,YAAA,IAAA,EAAA,CAAA,EAAA,QAAA,EAAA,yBAAyB,cACvB,IAAI,EAAA,QAAA,EACN,2DAA2D,EAAA,eAAA,EAEpD,uBAAuB,CAAC,MAAM,EAAA,MAAA,EAAA,CAAA,+DAAA,CAAA,EAAA;;sBAI9C,KAAK;uBAAC,EAAE,QAAQ,EAAE,IAAI,EAAE;;sBAGxB;;sBAGA;;sBAGA;;sBAGA;;sBAGA;;sBAGA;;sBAGA;;sBAGA;;sBAGA;;sBAGA;;sBAGA;;sBAGA;;sBAGA;;sBAGA;;sBAGA;;sBAGA;;sBAGA;;sBAGA;;sBAEA,SAAS;AAAC,gBAAA,IAAA,EAAA,CAAA,WAAW,EAAE,EAAE,MAAM,EAAE,IAAI,EAAE;;;AC1F1C;;;;;AAKG;;ACLH;;AAEG;;;;"}
1
+ {"version":3,"file":"seatlayer-angular.mjs","sources":["../../src/seating-chart.component.ts","../../src/season-picker.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 PickerSelectionValidator,\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 /** Local buyer selection guards. Changing them rebuilds the chart. */\n @Input() selectionValidators?: PickerSelectionValidator[];\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 selectionValidators: this.selectionValidators,\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","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 SeasonPicker as CoreSeasonPicker,\n type SeasonAvailability,\n type SeasonBestAvailableOptions,\n type SeasonCheckoutHandoff,\n type SeasonDescriptor,\n type SeasonPickerOptions,\n type SeasonPriceType,\n type SeasonRenewalIntent,\n type SeasonSeatPriceTypes,\n type SeasonStatusEvent,\n} from '@seatlayer/js';\n\n/** Standalone Angular adapter for the distinct fixed-inclusion Season buyer flow. */\n@Component({\n selector: 'seatlayer-season-picker',\n standalone: true,\n template: '<div #container class=\"seatlayer-season-container\"></div>',\n styles: [':host { display: block; } .seatlayer-season-container { width: 100%; }'],\n changeDetection: ChangeDetectionStrategy.OnPush,\n})\nexport class SeatLayerSeasonPickerComponent implements OnChanges {\n /** Season key to render. */\n @Input({ required: true }) season!: string;\n\n /** Public API base override. */\n @Input() apiBase?: string;\n\n /** Publishable account key, accepted for snippet parity. Never sent. */\n @Input() publicKey?: string;\n\n /** Who takes the money once the package is held. Default `'handoff'`. */\n @Input() checkout?: SeasonPickerOptions['checkout'];\n\n /** Where a redirecting gateway returns the buyer, for hosted checkout. */\n @Input() returnUrl?: string;\n\n /** Refreshable one-time browser bearer provider. */\n @Input() buyerAccessTokenProvider?: SeasonPickerOptions['buyerAccessTokenProvider'];\n\n /** One-time Season browser bearer. */\n @Input() buyerAccessToken?: SeasonPickerOptions['buyerAccessToken'];\n\n /** Operation restored after an uncertain create response. */\n @Input() initialOperationId?: string;\n\n /** The package to open on, by its key; the first package without it. */\n @Input() package?: string;\n\n /** The host emails a ticket per date itself: step 1 says so. */\n @Input() ticketsByEmail?: boolean;\n\n /** Maximum recovery polling time. */\n @Input() recoveryTimeoutMs?: number;\n\n /** Test or host fetch implementation. */\n @Input() fetch?: typeof fetch;\n\n /**\n * The price types the picker sells, e.g. `['adult', 'child']`. With a type\n * besides adult, the buyer chooses one per seat before the hold.\n */\n @Input() priceTypes?: readonly SeasonPriceType[];\n\n /** A same-seat hold reached a safe handoff. */\n @Output() readonly hold = new EventEmitter<SeasonCheckoutHandoff>();\n\n /** The active handoff changed or was released. */\n @Output() readonly holdChange = new EventEmitter<SeasonCheckoutHandoff | null>();\n\n /** The buyer continued with an opaque handoff. */\n @Output() readonly continued = new EventEmitter<SeasonCheckoutHandoff>();\n\n /** A returning holder recorded browser intent only. */\n @Output() readonly renewalIntent = new EventEmitter<SeasonRenewalIntent>();\n\n /** Buyer access expired. */\n @Output() readonly accessExpired = new EventEmitter<unknown>();\n\n /** Buyer access cannot be recovered. */\n @Output() readonly accessUnavailable = new EventEmitter<unknown>();\n\n /** Hosted checkout only: the gateway webhook landed and the order is paid. */\n @Output() readonly orderConfirmed = new EventEmitter<unknown>();\n\n /** Buyer-visible operation status changed. */\n @Output() readonly statusChange = new EventEmitter<SeasonStatusEvent>();\n\n /** The Season buyer flow failed. */\n @Output() readonly errored = new EventEmitter<unknown>();\n\n @ViewChild('container', { static: true })\n private readonly container!: ElementRef<HTMLDivElement>;\n\n private static readonly REBUILD_INPUTS = new Set([\n 'season', 'apiBase', 'publicKey', 'checkout', 'returnUrl',\n 'buyerAccessTokenProvider', 'buyerAccessToken',\n 'initialOperationId', 'package', 'ticketsByEmail', 'recoveryTimeoutMs', 'fetch', 'priceTypes',\n ]);\n private readonly zone = inject(NgZone);\n private picker: CoreSeasonPicker | null = null;\n\n constructor() {\n inject(DestroyRef).onDestroy(() => this.destroy());\n }\n\n ngOnChanges(changes: SimpleChanges): void {\n if (Object.keys(changes).some((name) => SeatLayerSeasonPickerComponent.REBUILD_INPUTS.has(name))) {\n this.build();\n }\n }\n\n /**\n * Holds the same labels across every included occurrence. `priceTypes` names\n * each seat's price type by label (`{ 'A-2': 'child' }`); a label it leaves\n * out is adult.\n */\n holdSameSeat(\n labels: readonly string[], operationId: string, priceTypes?: SeasonSeatPriceTypes,\n ): Promise<SeasonCheckoutHandoff> {\n return this.current().holdSameSeat(labels, operationId, priceTypes);\n }\n\n /**\n * Holds the best `qty` seats free on every included performance, as a map\n * selection would. Same contract as `@seatlayer/js` `holdBestAvailable`: a\n * caller-stable `sop_` id, 1 to `maxSelection` seats, one call at a time.\n */\n holdBestAvailable(\n qty: number, operationId: string, options?: SeasonBestAvailableOptions,\n ): Promise<SeasonCheckoutHandoff> {\n return this.current().holdBestAvailable(qty, operationId, options);\n }\n\n /** Restores a caller-stable Season operation after uncertainty. */\n restoreOperation(operationId: string): Promise<SeasonCheckoutHandoff | null> {\n return this.current().restoreOperation(operationId);\n }\n\n /** Releases the active selection with a caller-stable action id. */\n release(releaseActionId: string): Promise<void> {\n return this.current().release(releaseActionId);\n }\n\n /** Records renewal intent; trusted server code still inspects and commits it. */\n createRenewalIntent(offerId: string): Promise<SeasonRenewalIntent> {\n return this.current().createRenewalIntent(offerId);\n }\n\n /** Current immutable Season descriptor. */\n getDescriptor(): SeasonDescriptor | null {\n return this.picker?.getDescriptor() ?? null;\n }\n\n /** Current same-seat aggregate availability. */\n getAvailability(): SeasonAvailability | null {\n return this.picker?.getAvailability() ?? null;\n }\n\n /** Current opaque checkout handoff. */\n getHandoff(): SeasonCheckoutHandoff | null {\n return this.picker?.getHandoff() ?? null;\n }\n\n private build(): void {\n this.destroy();\n this.zone.runOutsideAngular(() => {\n const picker = new CoreSeasonPicker({\n container: this.container.nativeElement,\n season: this.season,\n apiBase: this.apiBase,\n publicKey: this.publicKey,\n checkout: this.checkout,\n returnUrl: this.returnUrl,\n buyerAccessTokenProvider: this.buyerAccessTokenProvider,\n buyerAccessToken: this.buyerAccessToken,\n initialOperationId: this.initialOperationId,\n package: this.package,\n ticketsByEmail: this.ticketsByEmail,\n recoveryTimeoutMs: this.recoveryTimeoutMs,\n fetch: this.fetch,\n priceTypes: this.priceTypes,\n onHold: (value) => this.zone.run(() => this.hold.emit(value)),\n onHoldChange: (value) => this.zone.run(() => this.holdChange.emit(value)),\n onContinue: (value) => this.zone.run(() => this.continued.emit(value)),\n onRenewalIntent: (value) => this.zone.run(() => this.renewalIntent.emit(value)),\n onAccessExpired: (value) => this.zone.run(() => this.accessExpired.emit(value)),\n onAccessUnavailable: (value) => this.zone.run(() => this.accessUnavailable.emit(value)),\n onOrderConfirmed: (value) => this.zone.run(() => this.orderConfirmed.emit(value)),\n onStatusChange: (value) => this.zone.run(() => this.statusChange.emit(value)),\n onError: (value) => this.zone.run(() => this.errored.emit(value)),\n });\n this.picker = picker;\n void picker.render().catch(() => undefined);\n });\n }\n\n private current(): CoreSeasonPicker {\n if (!this.picker) throw new Error('seatlayer: Angular SeasonPicker is not mounted');\n return this.picker;\n }\n\n private destroy(): void {\n this.picker?.destroy();\n this.picker = 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';\nexport { SeatLayerSeasonPickerComponent } from './season-picker.component';\n\nexport type {\n SelectedSeat,\n HoldResult,\n BestAvailableResult,\n GAAreaAvailability,\n HoldLineItem,\n SeatHoverDetails,\n SeasonAvailability,\n SeasonBestAvailableOptions,\n SeasonCheckoutHandoff,\n SeasonCheckoutSeat,\n SeasonDescriptor,\n SeasonOperation,\n SeasonOperationState,\n SeasonPickerOptions,\n SeasonPriceType,\n SeasonRenewalIntent,\n SeasonSeatPriceTypes,\n SeasonStatusEvent,\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","CoreSeasonPicker"],"mappings":";;;;;AAoCA;;;;;;;;;;;;;;;;;;;;;AAqBG;MAQU,8BAA8B,CAAA;;AAEd,IAAA,KAAK;;AAGvB,IAAA,OAAO;;AAGP,IAAA,YAAY;;AAGZ,IAAA,eAAe;;AAGf,IAAA,iBAAiB;;AAGjB,IAAA,sBAAsB;;AAGtB,IAAA,mBAAmB;;AAGnB,IAAA,SAAS;;AAGT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"}
package/dist/index.d.ts CHANGED
@@ -1,7 +1,7 @@
1
1
  import * as i0 from '@angular/core';
2
2
  import { OnChanges, EventEmitter, SimpleChanges } from '@angular/core';
3
- import { PickerSelectionValidator, RendererViewMode, SeatingChartOptions, BuyerAccessTokenProvider, BuyerAccessToken, SelectedSeat, PickerSelectionValidity, HoldResult, GAAreaAvailability, SeatHoverDetails, BuyerAccessExpiredEvent, BuyerAccessUnavailableEvent, SelectedObjectUnavailableEvent, BestAvailableResult, SeasonPickerOptions, SeasonCheckoutHandoff, SeasonRenewalIntent, SeasonStatusEvent, SeasonDescriptor, SeasonAvailability } from '@seatlayer/js';
4
- export { AttachPickerFrameOptions, BestAvailableResult, BuyerAccessExpiredEvent, BuyerAccessRefreshReason, BuyerAccessToken, BuyerAccessTokenProvider, BuyerAccessUnavailableEvent, BuyerAccessUnavailableReason, GAAreaAvailability, HoldLineItem, HoldResult, SeasonAvailability, SeasonCheckoutHandoff, SeasonDescriptor, SeasonOperation, SeasonOperationState, SeasonPickerOptions, SeasonRenewalIntent, SeasonStatusEvent, SeatHoverDetails, SeatPicker as SeatPickerWidget, SelectedObjectUnavailableEvent, SelectedSeat, attachPickerFrame } from '@seatlayer/js';
3
+ import { PickerSelectionValidator, RendererViewMode, SeatingChartOptions, BuyerAccessTokenProvider, BuyerAccessToken, SelectedSeat, PickerSelectionValidity, HoldResult, GAAreaAvailability, SeatHoverDetails, BuyerAccessExpiredEvent, BuyerAccessUnavailableEvent, SelectedObjectUnavailableEvent, BestAvailableResult, SeasonPickerOptions, SeasonPriceType, SeasonCheckoutHandoff, SeasonRenewalIntent, SeasonStatusEvent, SeasonSeatPriceTypes, SeasonBestAvailableOptions, SeasonDescriptor, SeasonAvailability } from '@seatlayer/js';
4
+ export { AttachPickerFrameOptions, BestAvailableResult, BuyerAccessExpiredEvent, BuyerAccessRefreshReason, BuyerAccessToken, BuyerAccessTokenProvider, BuyerAccessUnavailableEvent, BuyerAccessUnavailableReason, GAAreaAvailability, HoldLineItem, HoldResult, SeasonAvailability, SeasonBestAvailableOptions, SeasonCheckoutHandoff, SeasonCheckoutSeat, SeasonDescriptor, SeasonOperation, SeasonOperationState, SeasonPickerOptions, SeasonPriceType, SeasonRenewalIntent, SeasonSeatPriceTypes, SeasonStatusEvent, SeatHoverDetails, SeatPicker as SeatPickerWidget, SelectedObjectUnavailableEvent, SelectedSeat, attachPickerFrame } from '@seatlayer/js';
5
5
 
6
6
  /**
7
7
  * Angular wrapper around the framework-agnostic `@seatlayer/js` SDK.
@@ -199,10 +199,19 @@ declare class SeatLayerSeasonPickerComponent implements OnChanges {
199
199
  buyerAccessToken?: SeasonPickerOptions['buyerAccessToken'];
200
200
  /** Operation restored after an uncertain create response. */
201
201
  initialOperationId?: string;
202
+ /** The package to open on, by its key; the first package without it. */
203
+ package?: string;
204
+ /** The host emails a ticket per date itself: step 1 says so. */
205
+ ticketsByEmail?: boolean;
202
206
  /** Maximum recovery polling time. */
203
207
  recoveryTimeoutMs?: number;
204
208
  /** Test or host fetch implementation. */
205
209
  fetch?: typeof fetch;
210
+ /**
211
+ * The price types the picker sells, e.g. `['adult', 'child']`. With a type
212
+ * besides adult, the buyer chooses one per seat before the hold.
213
+ */
214
+ priceTypes?: readonly SeasonPriceType[];
206
215
  /** A same-seat hold reached a safe handoff. */
207
216
  readonly hold: EventEmitter<SeasonCheckoutHandoff>;
208
217
  /** The active handoff changed or was released. */
@@ -227,8 +236,18 @@ declare class SeatLayerSeasonPickerComponent implements OnChanges {
227
236
  private picker;
228
237
  constructor();
229
238
  ngOnChanges(changes: SimpleChanges): void;
230
- /** Holds the same labels across every included occurrence. */
231
- holdSameSeat(labels: readonly string[], operationId: string): Promise<SeasonCheckoutHandoff>;
239
+ /**
240
+ * Holds the same labels across every included occurrence. `priceTypes` names
241
+ * each seat's price type by label (`{ 'A-2': 'child' }`); a label it leaves
242
+ * out is adult.
243
+ */
244
+ holdSameSeat(labels: readonly string[], operationId: string, priceTypes?: SeasonSeatPriceTypes): Promise<SeasonCheckoutHandoff>;
245
+ /**
246
+ * Holds the best `qty` seats free on every included performance, as a map
247
+ * selection would. Same contract as `@seatlayer/js` `holdBestAvailable`: a
248
+ * caller-stable `sop_` id, 1 to `maxSelection` seats, one call at a time.
249
+ */
250
+ holdBestAvailable(qty: number, operationId: string, options?: SeasonBestAvailableOptions): Promise<SeasonCheckoutHandoff>;
232
251
  /** Restores a caller-stable Season operation after uncertainty. */
233
252
  restoreOperation(operationId: string): Promise<SeasonCheckoutHandoff | null>;
234
253
  /** Releases the active selection with a caller-stable action id. */
@@ -245,7 +264,7 @@ declare class SeatLayerSeasonPickerComponent implements OnChanges {
245
264
  private current;
246
265
  private destroy;
247
266
  static ɵfac: i0.ɵɵFactoryDeclaration<SeatLayerSeasonPickerComponent, never>;
248
- static ɵcmp: i0.ɵɵComponentDeclaration<SeatLayerSeasonPickerComponent, "seatlayer-season-picker", never, { "season": { "alias": "season"; "required": true; }; "apiBase": { "alias": "apiBase"; "required": false; }; "publicKey": { "alias": "publicKey"; "required": false; }; "checkout": { "alias": "checkout"; "required": false; }; "returnUrl": { "alias": "returnUrl"; "required": false; }; "buyerAccessTokenProvider": { "alias": "buyerAccessTokenProvider"; "required": false; }; "buyerAccessToken": { "alias": "buyerAccessToken"; "required": false; }; "initialOperationId": { "alias": "initialOperationId"; "required": false; }; "recoveryTimeoutMs": { "alias": "recoveryTimeoutMs"; "required": false; }; "fetch": { "alias": "fetch"; "required": false; }; }, { "hold": "hold"; "holdChange": "holdChange"; "continued": "continued"; "renewalIntent": "renewalIntent"; "accessExpired": "accessExpired"; "accessUnavailable": "accessUnavailable"; "orderConfirmed": "orderConfirmed"; "statusChange": "statusChange"; "errored": "errored"; }, never, never, true, never>;
267
+ static ɵcmp: i0.ɵɵComponentDeclaration<SeatLayerSeasonPickerComponent, "seatlayer-season-picker", never, { "season": { "alias": "season"; "required": true; }; "apiBase": { "alias": "apiBase"; "required": false; }; "publicKey": { "alias": "publicKey"; "required": false; }; "checkout": { "alias": "checkout"; "required": false; }; "returnUrl": { "alias": "returnUrl"; "required": false; }; "buyerAccessTokenProvider": { "alias": "buyerAccessTokenProvider"; "required": false; }; "buyerAccessToken": { "alias": "buyerAccessToken"; "required": false; }; "initialOperationId": { "alias": "initialOperationId"; "required": false; }; "package": { "alias": "package"; "required": false; }; "ticketsByEmail": { "alias": "ticketsByEmail"; "required": false; }; "recoveryTimeoutMs": { "alias": "recoveryTimeoutMs"; "required": false; }; "fetch": { "alias": "fetch"; "required": false; }; "priceTypes": { "alias": "priceTypes"; "required": false; }; }, { "hold": "hold"; "holdChange": "holdChange"; "continued": "continued"; "renewalIntent": "renewalIntent"; "accessExpired": "accessExpired"; "accessUnavailable": "accessUnavailable"; "orderConfirmed": "orderConfirmed"; "statusChange": "statusChange"; "errored": "errored"; }, never, never, true, never>;
249
268
  }
250
269
 
251
270
  export { SeatLayerSeasonPickerComponent, SeatLayerSeatingChartComponent };
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@seatlayer/angular",
3
- "version": "0.109.2",
3
+ "version": "0.110.0",
4
4
  "description": "SeatLayer's official Angular seating chart and seat map SDK: live availability, seat selection, temporary holds, and a typed TypeScript API for ticketing apps.",
5
5
  "license": "MIT",
6
6
  "author": {
@@ -36,8 +36,8 @@
36
36
  "typescript"
37
37
  ],
38
38
  "dependencies": {
39
- "@seatlayer/core": "0.109.2",
40
- "@seatlayer/js": "0.109.2",
39
+ "@seatlayer/core": "0.110.0",
40
+ "@seatlayer/js": "0.110.0",
41
41
  "tslib": "^2.8.1"
42
42
  },
43
43
  "peerDependencies": {