@seatlayer/js 0.89.2 → 0.90.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
@@ -1200,8 +1200,17 @@ interface SeatPickerOptions {
1200
1200
  * sections as soon as the chart lands and fills the seats in a section at a
1201
1201
  * time, nearest the viewport first; 'plain' builds the whole scene in one
1202
1202
  * step. Small charts are built in one step either way.
1203
+ *
1204
+ * 'viewport' is an opt-in mode for very large charts. It keeps the section
1205
+ * overview light and builds seat graphics only for the visible or focused
1206
+ * sections, retaining a bounded warm cache as the buyer moves. It applies to
1207
+ * sectioned flat charts and is never selected automatically: the widget uses
1208
+ * it only when this option is set to 'viewport'. Seat availability, search
1209
+ * and selection still cover every seat. Because every seat is never built at
1210
+ * once in this mode, `onSeatsRevealed` and the `chart_seats_revealed`
1211
+ * analytics event do not fire.
1203
1212
  */
1204
- loadingReveal?: 'progressive' | 'plain';
1213
+ loadingReveal?: 'progressive' | 'plain' | 'viewport';
1205
1214
  /** Initial map projection. Buyers now toggle **Map (flat 2D) + 3D** only; the
1206
1215
  * legacy `perspective` (2.5D) value is still ACCEPTED for source compatibility
1207
1216
  * but is deprecated — it is coerced to `flat` with a one-time console warning.
@@ -1266,7 +1275,9 @@ interface SeatPickerOptions {
1266
1275
  * rest arrive in idle slices. A host that needs "the whole venue is on
1267
1276
  * screen" waits for this rather than for `render()`. Fires exactly once per
1268
1277
  * chart, and never for a chart small enough to build in one step (there is
1269
- * nothing to wait for: `render()` already was that moment).
1278
+ * nothing to wait for: `render()` already was that moment). It also never
1279
+ * fires with `loadingReveal: 'viewport'`, where only the seats around the
1280
+ * current view are built.
1270
1281
  */
1271
1282
  onSeatsRevealed?: () => void;
1272
1283
  /**
@@ -3998,6 +4009,10 @@ declare class SeatPicker implements GaPromptPicker {
3998
4009
  /** Elapsed since `render()` resolved, or undefined when it never did. */
3999
4010
  private sinceRenderResolved;
4000
4011
  /** @internal */ whenSeatsRevealed(run: () => void): void;
4012
+ /** True only when the host opted into `loadingReveal: 'viewport'`. */
4013
+ private viewportLoading;
4014
+ /** Run queued seat work once, in order, each step fenced from the next. */
4015
+ private drainSeatsRevealedWaiters;
4001
4016
  /** Keep returning buyers behind the veil until their hold is authoritative. */
4002
4017
  private restoreHoldForFirstPaint;
4003
4018
  /** Resume a redirect checkout from this tab's storage, never from the URL. */
package/dist/index.d.ts CHANGED
@@ -1200,8 +1200,17 @@ interface SeatPickerOptions {
1200
1200
  * sections as soon as the chart lands and fills the seats in a section at a
1201
1201
  * time, nearest the viewport first; 'plain' builds the whole scene in one
1202
1202
  * step. Small charts are built in one step either way.
1203
+ *
1204
+ * 'viewport' is an opt-in mode for very large charts. It keeps the section
1205
+ * overview light and builds seat graphics only for the visible or focused
1206
+ * sections, retaining a bounded warm cache as the buyer moves. It applies to
1207
+ * sectioned flat charts and is never selected automatically: the widget uses
1208
+ * it only when this option is set to 'viewport'. Seat availability, search
1209
+ * and selection still cover every seat. Because every seat is never built at
1210
+ * once in this mode, `onSeatsRevealed` and the `chart_seats_revealed`
1211
+ * analytics event do not fire.
1203
1212
  */
1204
- loadingReveal?: 'progressive' | 'plain';
1213
+ loadingReveal?: 'progressive' | 'plain' | 'viewport';
1205
1214
  /** Initial map projection. Buyers now toggle **Map (flat 2D) + 3D** only; the
1206
1215
  * legacy `perspective` (2.5D) value is still ACCEPTED for source compatibility
1207
1216
  * but is deprecated — it is coerced to `flat` with a one-time console warning.
@@ -1266,7 +1275,9 @@ interface SeatPickerOptions {
1266
1275
  * rest arrive in idle slices. A host that needs "the whole venue is on
1267
1276
  * screen" waits for this rather than for `render()`. Fires exactly once per
1268
1277
  * chart, and never for a chart small enough to build in one step (there is
1269
- * nothing to wait for: `render()` already was that moment).
1278
+ * nothing to wait for: `render()` already was that moment). It also never
1279
+ * fires with `loadingReveal: 'viewport'`, where only the seats around the
1280
+ * current view are built.
1270
1281
  */
1271
1282
  onSeatsRevealed?: () => void;
1272
1283
  /**
@@ -3998,6 +4009,10 @@ declare class SeatPicker implements GaPromptPicker {
3998
4009
  /** Elapsed since `render()` resolved, or undefined when it never did. */
3999
4010
  private sinceRenderResolved;
4000
4011
  /** @internal */ whenSeatsRevealed(run: () => void): void;
4012
+ /** True only when the host opted into `loadingReveal: 'viewport'`. */
4013
+ private viewportLoading;
4014
+ /** Run queued seat work once, in order, each step fenced from the next. */
4015
+ private drainSeatsRevealedWaiters;
4001
4016
  /** Keep returning buyers behind the veil until their hold is authoritative. */
4002
4017
  private restoreHoldForFirstPaint;
4003
4018
  /** Resume a redirect checkout from this tab's storage, never from the URL. */