@seatlayer/js 0.82.0 → 0.84.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/dist/index.d.cts CHANGED
@@ -3274,6 +3274,21 @@ interface CheckoutOrderStatus {
3274
3274
  pdfUrl?: string;
3275
3275
  }
3276
3276
 
3277
+ /**
3278
+ * THE PHONE SHEET HAS THREE RESTING HEIGHTS, smallest first.
3279
+ *
3280
+ * `mini` is the footer alone — total, CTA, by-line — and hands the map every
3281
+ * pixel the widget can spare. `peek` adds the cart, capped at three cards and
3282
+ * a sliver of the fourth. `open` is the whole panel. Owner, 2026-09-06: two
3283
+ * held seats left the collapsed sheet owning ~45% of a real iPhone with no way
3284
+ * to make it smaller, and the arrow was the control that should have done it.
3285
+ *
3286
+ * Order is load-bearing: `stepSheet` walks this array, so a swipe up is +1 and
3287
+ * a swipe down is -1 with no state table anywhere else.
3288
+ */
3289
+ declare const SHEET_STATES: readonly ["mini", "peek", "open"];
3290
+ /** @internal */
3291
+ type SheetState = (typeof SHEET_STATES)[number];
3277
3292
  declare class SeatPicker implements GaPromptPicker {
3278
3293
  /** @internal Read by pickerGaPrompt for the `onGAPrompt` host hook. */
3279
3294
  readonly opts: SeatPickerOptions;
@@ -3312,6 +3327,7 @@ declare class SeatPicker implements GaPromptPicker {
3312
3327
  /** Feature 6 anchor regions — positioned flex containers over the map. */
3313
3328
  /** @internal */ regions: Record<string, HTMLElement>;
3314
3329
  private ro;
3330
+ private viewportResizeHandler;
3315
3331
  /** @internal */ holdTimer: ReturnType<typeof setInterval> | null;
3316
3332
  private toastTimer;
3317
3333
  /** The availability read every other caller joins. See refreshOfferAvailability. */
@@ -3453,6 +3469,7 @@ declare class SeatPicker implements GaPromptPicker {
3453
3469
  /** @internal */ view3dPassportEl: HTMLDivElement | null;
3454
3470
  /** @internal */ view3dPassportCleanup: (() => void) | null;
3455
3471
  private floorsEl;
3472
+ private arenaViewportInsets;
3456
3473
  private viewEl;
3457
3474
  private viewCleanup;
3458
3475
  /** Supersedes an older authored-view byte request when another seat is opened. */
@@ -3474,6 +3491,7 @@ declare class SeatPicker implements GaPromptPicker {
3474
3491
  /** @internal */ priceSelect: HTMLSelectElement | null;
3475
3492
  /** @internal */ minimap: PickerMinimap | null;
3476
3493
  private pickerLayoutSize;
3494
+ private fullscreenAffordanceSize;
3477
3495
  /** @internal */ priceBandKeys: Set<string> | null;
3478
3496
  /** @internal */ focusedCatKey: string | null;
3479
3497
  /** "Hide limited-view seats" — mirrored into 3D by `seatState3dFor`. */
@@ -3487,7 +3505,9 @@ declare class SeatPicker implements GaPromptPicker {
3487
3505
  * repaint — see SectionCard.adopt. */
3488
3506
  /** @internal */ get lastSection(): SectionSummary | null;
3489
3507
  /** @internal */ set lastSection(summary: SectionSummary | null);
3490
- /** Previous tray ticket count — first 0→n transition auto-expands the mobile sheet. */
3508
+ /** Previous tray ticket count — a 0→n transition pulses the CTA and, on the
3509
+ * phone, decides whether the seat landed in a sheet that was showing the
3510
+ * footer alone (which then stays that way). It never expands the sheet. */
3491
3511
  /** @internal */ lastTrayCount: number;
3492
3512
  /** The opt-in language switcher, when `languages` named at least two. */
3493
3513
  private langSel;
@@ -3571,6 +3591,7 @@ declare class SeatPicker implements GaPromptPicker {
3571
3591
  * that is the only way back out.
3572
3592
  */
3573
3593
  private syncFullscreenAffordance;
3594
+ private fullscreenMeasurementChanged;
3574
3595
  private syncFullscreenButtons;
3575
3596
  /**
3576
3597
  * Native element-fullscreen was unavailable or rejected. When framed, a CSS
@@ -3606,11 +3627,69 @@ declare class SeatPicker implements GaPromptPicker {
3606
3627
  /** Wire host chrome after the skeleton exists and before the renderer owns its map host. */
3607
3628
  private wireBuyerShell;
3608
3629
  /**
3609
- * Open or collapse the phone sheet, and say so.
3630
+ * Which rung the phone sheet is resting on.
3631
+ *
3632
+ * Anything the DOM does not recognise reads as `peek`, which is the state a
3633
+ * narrow layout is born in (see observeLayout).
3634
+ *
3635
+ * @internal
3636
+ */
3637
+ sheetState(): SheetState;
3638
+ /**
3639
+ * AN EMPTY CART HAS NO `mini`.
3640
+ *
3641
+ * `mini` exists to get the ticket LIST out of the way; with nothing in the
3642
+ * cart `peek` already hides the tray, so the two states would be the same
3643
+ * pixels with two names — and a chevron that appears to do nothing.
3644
+ */
3645
+ private sheetHasCards;
3646
+ /**
3647
+ * Put the phone sheet on a named rung, and say so.
3648
+ *
3649
+ * The one place `data-sheet` is written, so the chevron's direction, its
3650
+ * `aria-expanded` and its label can never drift from the state — a chevron
3651
+ * that says "Open ticket panel" over an open panel is worse than no label.
3652
+ *
3653
+ * @internal
3654
+ */
3655
+ setSheetState(state: SheetState): void;
3656
+ /**
3657
+ * The chevron's whole meaning: "there is still something here to put away".
3658
+ *
3659
+ * DOWN — and `aria-expanded` aside, the label says collapse — whenever a tap
3660
+ * makes the sheet smaller: from `open`, and from `peek` while the cart has
3661
+ * cards to hide. UP in `mini`, and in a `peek` whose cart is empty, because
3662
+ * from there the only way is up. `aria-expanded` is true in `open` alone:
3663
+ * that is the only state where the whole panel is disclosed.
3664
+ *
3665
+ * @internal
3666
+ */
3667
+ syncSheetAffordance(): void;
3668
+ /**
3669
+ * A TAP ALWAYS DOES WHAT THE CHEVRON SHOWS.
3670
+ *
3671
+ * `open` → `peek` → `mini` → `peek` → … so a buyer who wants the map keeps
3672
+ * tapping the same spot and keeps getting more of it, and one more tap brings
3673
+ * their tickets back. An empty cart skips `mini` entirely: `peek` is already
3674
+ * the footer alone, so its tap opens the panel instead.
3675
+ *
3676
+ * @internal
3677
+ */
3678
+ cycleSheet(): void;
3679
+ /**
3680
+ * One rung up (+1) or down (-1), clamped at both ends.
3681
+ *
3682
+ * The swipe's counterpart to `cycleSheet`: a drag says which DIRECTION the
3683
+ * buyer wants, so it never wraps the way the tap does.
3684
+ *
3685
+ * @internal
3686
+ */
3687
+ stepSheet(delta: 1 | -1): void;
3688
+ /**
3689
+ * Open or collapse the phone sheet.
3610
3690
  *
3611
- * The one place `data-sheet` is written together with the chevron's
3612
- * `aria-expanded` and its label: the two used to drift, and a chevron that
3613
- * says "Open ticket panel" over an open panel is worse than no label at all.
3691
+ * Kept as the two-value door for callers that only ever mean "all the way
3692
+ * up" or "back to the cart" — the price disclosure and the best-seats form.
3614
3693
  *
3615
3694
  * @internal
3616
3695
  */
@@ -3840,23 +3919,45 @@ declare class SeatPicker implements GaPromptPicker {
3840
3919
  /** @internal */ applyPriceBand(keys: string[] | null): void;
3841
3920
  /** Build projection, rung and floor controls for arena-scale charts. */
3842
3921
  private buildArenaChrome;
3922
+ /** Keep the camera's fitted viewport clear of measured multi-floor chrome. */
3923
+ /** @internal */ syncArenaViewportInsets(): void;
3843
3924
  /** Reflect the engine's current LOD rung onto the pill group. */
3844
3925
  /** @internal */ syncRung(): void;
3845
3926
  /**
3846
- * The phone's back-out controls, and whether they still have anywhere to go.
3927
+ * The map's back-out controls, and whether they still have anywhere to go.
3847
3928
  *
3848
3929
  * On narrow the corner carries "+", "−" and the fit disc (owner call
3849
3930
  * 2026-09-05). "−" is the ladder — one tap to the section the buyer drilled
3850
3931
  * into, one more to the whole venue — and the fit disc is that last step on
3851
- * its own. The ladder itself is `mapZoomOutStep`; this only dresses it, and
3852
- * only on narrow: wide keeps "+" and "−" undimmed and never shows the disc.
3853
- *
3854
- * DIMMED, NOT GONE. The controls used to appear only once the buyer was deep
3855
- * enough to be lost, so the corner grew and shrank a button underneath their
3856
- * thumb. A control that stays put and plainly cannot be pressed says "you
3857
- * are already looking at everything" without moving the target — as long as
3858
- * it dims only when that is TRUE, which is why the reading is the engine's
3859
- * fit pose and not a guess from whether seats happen to be on screen.
3932
+ * its own. The ladder itself is `mapZoomOutStep`; this only dresses it. Wide
3933
+ * carries "+" and "−" and never shows the fit disc (CSS, see pickerStyles),
3934
+ * but "−" answers to the same reading there.
3935
+ *
3936
+ * GONE, NOT DIMMED (owner call 2026-09-06, from real-iPhone captures, and
3937
+ * the second time this has been asked for). The previous rationale here was
3938
+ * that a control which stays put and plainly cannot be pressed says "you are
3939
+ * already looking at everything" without moving the target. It does not: two
3940
+ * greyed discs at the arrival view are read as a broken map, and they are
3941
+ * the FIRST thing a buyer sees, before they have any model of the ladder
3942
+ * they are at the top of. Hidden, the column at the whole-venue view is ♿
3943
+ * and "+" — every disc on screen does something — and "−"/fit reappear the
3944
+ * moment there is a step to take, which is the tap that put them there.
3945
+ *
3946
+ * `hidden`, and a CSS rule loud enough to beat the narrow `display:flex` on
3947
+ * the fit disc. display:none, so the column closes the gap rather than
3948
+ * leaving the ♿ floating a disc and a half off the corner — which is also
3949
+ * why the ♿ menu is re-bounded afterwards: its panel is clamped to the room
3950
+ * above a button that has just moved.
3951
+ *
3952
+ * "+" GOES THE SAME WAY AT THE OTHER END (owner, 2026-09-06, from the phone:
3953
+ * "if we already deep where we selecting the seat, plus not make further
3954
+ * sense"). "Deep" is the renderer's own `seatsPickable` — seats drawn big
3955
+ * enough to aim a thumb at — not the numeric zoom ceiling, which sits well
3956
+ * past that and left the disc standing on the very camera the owner was
3957
+ * looking at ("minus icon still showing", same afternoon, meaning the
3958
+ * column had not changed). The ceiling still counts: a press there is a
3959
+ * no-op whatever the seats measure. An engine that cannot answer either
3960
+ * question leaves the disc alone.
3860
3961
  */
3861
3962
  private syncMapStepBack;
3862
3963
  /** @internal */ syncProjection(): void;
package/dist/index.d.ts CHANGED
@@ -3274,6 +3274,21 @@ interface CheckoutOrderStatus {
3274
3274
  pdfUrl?: string;
3275
3275
  }
3276
3276
 
3277
+ /**
3278
+ * THE PHONE SHEET HAS THREE RESTING HEIGHTS, smallest first.
3279
+ *
3280
+ * `mini` is the footer alone — total, CTA, by-line — and hands the map every
3281
+ * pixel the widget can spare. `peek` adds the cart, capped at three cards and
3282
+ * a sliver of the fourth. `open` is the whole panel. Owner, 2026-09-06: two
3283
+ * held seats left the collapsed sheet owning ~45% of a real iPhone with no way
3284
+ * to make it smaller, and the arrow was the control that should have done it.
3285
+ *
3286
+ * Order is load-bearing: `stepSheet` walks this array, so a swipe up is +1 and
3287
+ * a swipe down is -1 with no state table anywhere else.
3288
+ */
3289
+ declare const SHEET_STATES: readonly ["mini", "peek", "open"];
3290
+ /** @internal */
3291
+ type SheetState = (typeof SHEET_STATES)[number];
3277
3292
  declare class SeatPicker implements GaPromptPicker {
3278
3293
  /** @internal Read by pickerGaPrompt for the `onGAPrompt` host hook. */
3279
3294
  readonly opts: SeatPickerOptions;
@@ -3312,6 +3327,7 @@ declare class SeatPicker implements GaPromptPicker {
3312
3327
  /** Feature 6 anchor regions — positioned flex containers over the map. */
3313
3328
  /** @internal */ regions: Record<string, HTMLElement>;
3314
3329
  private ro;
3330
+ private viewportResizeHandler;
3315
3331
  /** @internal */ holdTimer: ReturnType<typeof setInterval> | null;
3316
3332
  private toastTimer;
3317
3333
  /** The availability read every other caller joins. See refreshOfferAvailability. */
@@ -3453,6 +3469,7 @@ declare class SeatPicker implements GaPromptPicker {
3453
3469
  /** @internal */ view3dPassportEl: HTMLDivElement | null;
3454
3470
  /** @internal */ view3dPassportCleanup: (() => void) | null;
3455
3471
  private floorsEl;
3472
+ private arenaViewportInsets;
3456
3473
  private viewEl;
3457
3474
  private viewCleanup;
3458
3475
  /** Supersedes an older authored-view byte request when another seat is opened. */
@@ -3474,6 +3491,7 @@ declare class SeatPicker implements GaPromptPicker {
3474
3491
  /** @internal */ priceSelect: HTMLSelectElement | null;
3475
3492
  /** @internal */ minimap: PickerMinimap | null;
3476
3493
  private pickerLayoutSize;
3494
+ private fullscreenAffordanceSize;
3477
3495
  /** @internal */ priceBandKeys: Set<string> | null;
3478
3496
  /** @internal */ focusedCatKey: string | null;
3479
3497
  /** "Hide limited-view seats" — mirrored into 3D by `seatState3dFor`. */
@@ -3487,7 +3505,9 @@ declare class SeatPicker implements GaPromptPicker {
3487
3505
  * repaint — see SectionCard.adopt. */
3488
3506
  /** @internal */ get lastSection(): SectionSummary | null;
3489
3507
  /** @internal */ set lastSection(summary: SectionSummary | null);
3490
- /** Previous tray ticket count — first 0→n transition auto-expands the mobile sheet. */
3508
+ /** Previous tray ticket count — a 0→n transition pulses the CTA and, on the
3509
+ * phone, decides whether the seat landed in a sheet that was showing the
3510
+ * footer alone (which then stays that way). It never expands the sheet. */
3491
3511
  /** @internal */ lastTrayCount: number;
3492
3512
  /** The opt-in language switcher, when `languages` named at least two. */
3493
3513
  private langSel;
@@ -3571,6 +3591,7 @@ declare class SeatPicker implements GaPromptPicker {
3571
3591
  * that is the only way back out.
3572
3592
  */
3573
3593
  private syncFullscreenAffordance;
3594
+ private fullscreenMeasurementChanged;
3574
3595
  private syncFullscreenButtons;
3575
3596
  /**
3576
3597
  * Native element-fullscreen was unavailable or rejected. When framed, a CSS
@@ -3606,11 +3627,69 @@ declare class SeatPicker implements GaPromptPicker {
3606
3627
  /** Wire host chrome after the skeleton exists and before the renderer owns its map host. */
3607
3628
  private wireBuyerShell;
3608
3629
  /**
3609
- * Open or collapse the phone sheet, and say so.
3630
+ * Which rung the phone sheet is resting on.
3631
+ *
3632
+ * Anything the DOM does not recognise reads as `peek`, which is the state a
3633
+ * narrow layout is born in (see observeLayout).
3634
+ *
3635
+ * @internal
3636
+ */
3637
+ sheetState(): SheetState;
3638
+ /**
3639
+ * AN EMPTY CART HAS NO `mini`.
3640
+ *
3641
+ * `mini` exists to get the ticket LIST out of the way; with nothing in the
3642
+ * cart `peek` already hides the tray, so the two states would be the same
3643
+ * pixels with two names — and a chevron that appears to do nothing.
3644
+ */
3645
+ private sheetHasCards;
3646
+ /**
3647
+ * Put the phone sheet on a named rung, and say so.
3648
+ *
3649
+ * The one place `data-sheet` is written, so the chevron's direction, its
3650
+ * `aria-expanded` and its label can never drift from the state — a chevron
3651
+ * that says "Open ticket panel" over an open panel is worse than no label.
3652
+ *
3653
+ * @internal
3654
+ */
3655
+ setSheetState(state: SheetState): void;
3656
+ /**
3657
+ * The chevron's whole meaning: "there is still something here to put away".
3658
+ *
3659
+ * DOWN — and `aria-expanded` aside, the label says collapse — whenever a tap
3660
+ * makes the sheet smaller: from `open`, and from `peek` while the cart has
3661
+ * cards to hide. UP in `mini`, and in a `peek` whose cart is empty, because
3662
+ * from there the only way is up. `aria-expanded` is true in `open` alone:
3663
+ * that is the only state where the whole panel is disclosed.
3664
+ *
3665
+ * @internal
3666
+ */
3667
+ syncSheetAffordance(): void;
3668
+ /**
3669
+ * A TAP ALWAYS DOES WHAT THE CHEVRON SHOWS.
3670
+ *
3671
+ * `open` → `peek` → `mini` → `peek` → … so a buyer who wants the map keeps
3672
+ * tapping the same spot and keeps getting more of it, and one more tap brings
3673
+ * their tickets back. An empty cart skips `mini` entirely: `peek` is already
3674
+ * the footer alone, so its tap opens the panel instead.
3675
+ *
3676
+ * @internal
3677
+ */
3678
+ cycleSheet(): void;
3679
+ /**
3680
+ * One rung up (+1) or down (-1), clamped at both ends.
3681
+ *
3682
+ * The swipe's counterpart to `cycleSheet`: a drag says which DIRECTION the
3683
+ * buyer wants, so it never wraps the way the tap does.
3684
+ *
3685
+ * @internal
3686
+ */
3687
+ stepSheet(delta: 1 | -1): void;
3688
+ /**
3689
+ * Open or collapse the phone sheet.
3610
3690
  *
3611
- * The one place `data-sheet` is written together with the chevron's
3612
- * `aria-expanded` and its label: the two used to drift, and a chevron that
3613
- * says "Open ticket panel" over an open panel is worse than no label at all.
3691
+ * Kept as the two-value door for callers that only ever mean "all the way
3692
+ * up" or "back to the cart" — the price disclosure and the best-seats form.
3614
3693
  *
3615
3694
  * @internal
3616
3695
  */
@@ -3840,23 +3919,45 @@ declare class SeatPicker implements GaPromptPicker {
3840
3919
  /** @internal */ applyPriceBand(keys: string[] | null): void;
3841
3920
  /** Build projection, rung and floor controls for arena-scale charts. */
3842
3921
  private buildArenaChrome;
3922
+ /** Keep the camera's fitted viewport clear of measured multi-floor chrome. */
3923
+ /** @internal */ syncArenaViewportInsets(): void;
3843
3924
  /** Reflect the engine's current LOD rung onto the pill group. */
3844
3925
  /** @internal */ syncRung(): void;
3845
3926
  /**
3846
- * The phone's back-out controls, and whether they still have anywhere to go.
3927
+ * The map's back-out controls, and whether they still have anywhere to go.
3847
3928
  *
3848
3929
  * On narrow the corner carries "+", "−" and the fit disc (owner call
3849
3930
  * 2026-09-05). "−" is the ladder — one tap to the section the buyer drilled
3850
3931
  * into, one more to the whole venue — and the fit disc is that last step on
3851
- * its own. The ladder itself is `mapZoomOutStep`; this only dresses it, and
3852
- * only on narrow: wide keeps "+" and "−" undimmed and never shows the disc.
3853
- *
3854
- * DIMMED, NOT GONE. The controls used to appear only once the buyer was deep
3855
- * enough to be lost, so the corner grew and shrank a button underneath their
3856
- * thumb. A control that stays put and plainly cannot be pressed says "you
3857
- * are already looking at everything" without moving the target — as long as
3858
- * it dims only when that is TRUE, which is why the reading is the engine's
3859
- * fit pose and not a guess from whether seats happen to be on screen.
3932
+ * its own. The ladder itself is `mapZoomOutStep`; this only dresses it. Wide
3933
+ * carries "+" and "−" and never shows the fit disc (CSS, see pickerStyles),
3934
+ * but "−" answers to the same reading there.
3935
+ *
3936
+ * GONE, NOT DIMMED (owner call 2026-09-06, from real-iPhone captures, and
3937
+ * the second time this has been asked for). The previous rationale here was
3938
+ * that a control which stays put and plainly cannot be pressed says "you are
3939
+ * already looking at everything" without moving the target. It does not: two
3940
+ * greyed discs at the arrival view are read as a broken map, and they are
3941
+ * the FIRST thing a buyer sees, before they have any model of the ladder
3942
+ * they are at the top of. Hidden, the column at the whole-venue view is ♿
3943
+ * and "+" — every disc on screen does something — and "−"/fit reappear the
3944
+ * moment there is a step to take, which is the tap that put them there.
3945
+ *
3946
+ * `hidden`, and a CSS rule loud enough to beat the narrow `display:flex` on
3947
+ * the fit disc. display:none, so the column closes the gap rather than
3948
+ * leaving the ♿ floating a disc and a half off the corner — which is also
3949
+ * why the ♿ menu is re-bounded afterwards: its panel is clamped to the room
3950
+ * above a button that has just moved.
3951
+ *
3952
+ * "+" GOES THE SAME WAY AT THE OTHER END (owner, 2026-09-06, from the phone:
3953
+ * "if we already deep where we selecting the seat, plus not make further
3954
+ * sense"). "Deep" is the renderer's own `seatsPickable` — seats drawn big
3955
+ * enough to aim a thumb at — not the numeric zoom ceiling, which sits well
3956
+ * past that and left the disc standing on the very camera the owner was
3957
+ * looking at ("minus icon still showing", same afternoon, meaning the
3958
+ * column had not changed). The ceiling still counts: a press there is a
3959
+ * no-op whatever the seats measure. An engine that cannot answer either
3960
+ * question leaves the disc alone.
3860
3961
  */
3861
3962
  private syncMapStepBack;
3862
3963
  /** @internal */ syncProjection(): void;