@seatlayer/js 0.86.13 → 0.88.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 +26 -0
- package/dist/index.cjs +65 -21
- package/dist/index.d.cts +89 -2
- package/dist/index.d.ts +89 -2
- package/dist/index.js +62 -18
- package/package.json +2 -2
package/README.md
CHANGED
|
@@ -89,6 +89,29 @@ together. Login, presale, partner, and channel inventory instead use
|
|
|
89
89
|
backend; either explicit credential takes precedence over `publicKey`. Managed
|
|
90
90
|
public/unlisted events retain anonymous event-key access and omit `publicKey`.
|
|
91
91
|
|
|
92
|
+
### Prewarm on intent
|
|
93
|
+
|
|
94
|
+
That bootstrap is the one round trip everything else waits behind, and a buyer
|
|
95
|
+
signals the open before they make it. `SeatPicker.prewarm` (or the
|
|
96
|
+
`prewarmSeatPicker` function export) starts it from a hover or a pointerdown,
|
|
97
|
+
so the answer is already in flight when the picker mounts:
|
|
98
|
+
|
|
99
|
+
```js
|
|
100
|
+
import { SeatPicker } from '@seatlayer/js';
|
|
101
|
+
|
|
102
|
+
const seating = { event: 'ev_9f3a', publicKey: 'pk_live_…' };
|
|
103
|
+
button.addEventListener('pointerenter', () => SeatPicker.prewarm(seating));
|
|
104
|
+
button.addEventListener('pointerdown', () => SeatPicker.prewarm(seating));
|
|
105
|
+
button.addEventListener('click', () => SeatPicker.open({ ...seating }));
|
|
106
|
+
```
|
|
107
|
+
|
|
108
|
+
The page still makes exactly one bootstrap request: the picker's first read
|
|
109
|
+
joins the one already in flight, or takes its completed answer. Calling it
|
|
110
|
+
repeatedly is free, it never throws, and a prewarm that fails simply is not
|
|
111
|
+
there when the picker mounts — the mount then behaves as it does without one.
|
|
112
|
+
It applies to `publicKey` mounts; options carrying a custom `transport`,
|
|
113
|
+
`buyerAccessToken` or `buyerAccessTokenProvider` are a no-op.
|
|
114
|
+
|
|
92
115
|
## Fixed Renewable Season
|
|
93
116
|
|
|
94
117
|
`SeasonPicker` is supported in `@seatlayer/js` `0.72.0` and newer. It is an SDK
|
|
@@ -467,6 +490,9 @@ Lifecycle/hold methods: `render()`, `hold()`, `bestAvailable(qty, categoryKey?)`
|
|
|
467
490
|
The full `SeatPicker` automatically restores an active hold after same-tab
|
|
468
491
|
checkout navigation and lets the buyer remove individual held tickets. Set
|
|
469
492
|
`restoreHold: false` and pass `initialHoldId` when your host owns persistence.
|
|
493
|
+
Closing the picker before checkout releases an active hold; `holdOnClose: 'keep'`
|
|
494
|
+
leaves it running for the rest of its window instead, so a buyer who dismissed
|
|
495
|
+
the map by accident gets the same seats back on the next mount.
|
|
470
496
|
|
|
471
497
|
The browser **holds**; your **server books** with a secret key. See
|
|
472
498
|
[how the integration works](https://docs.seatlayer.io/start/how-it-works/).
|