@tiledev/sdk-apptile-live-selling 0.13.0 → 0.15.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 +116 -12
- package/dist/clipsPage.d.ts +29 -0
- package/dist/clipsPage.d.ts.map +1 -0
- package/dist/clipsPage.js +49 -0
- package/dist/clipsPage.js.map +1 -0
- package/dist/giveawayPrizeLines.d.ts +10 -0
- package/dist/giveawayPrizeLines.d.ts.map +1 -1
- package/dist/giveawayPrizeLines.js +11 -1
- package/dist/giveawayPrizeLines.js.map +1 -1
- package/dist/hiddenShows.d.ts +10 -0
- package/dist/hiddenShows.d.ts.map +1 -1
- package/dist/hiddenShows.js +11 -0
- package/dist/hiddenShows.js.map +1 -1
- package/dist/index.d.ts +10 -3
- package/dist/index.d.ts.map +1 -1
- package/dist/index.js +53 -2
- package/dist/index.js.map +1 -1
- package/dist/linkLots.d.ts +64 -0
- package/dist/linkLots.d.ts.map +1 -0
- package/dist/linkLots.js +84 -0
- package/dist/linkLots.js.map +1 -0
- package/dist/livePages.d.ts +166 -0
- package/dist/livePages.d.ts.map +1 -0
- package/dist/livePages.js +187 -0
- package/dist/livePages.js.map +1 -0
- package/dist/liveRoom.d.ts +21 -0
- package/dist/liveRoom.d.ts.map +1 -0
- package/dist/liveRoom.js +28 -0
- package/dist/liveRoom.js.map +1 -0
- package/dist/pageOptions.d.ts +118 -0
- package/dist/pageOptions.d.ts.map +1 -0
- package/dist/pageOptions.js +99 -0
- package/dist/pageOptions.js.map +1 -0
- package/dist/pageTypes.d.ts +185 -0
- package/dist/pageTypes.d.ts.map +1 -0
- package/dist/pageTypes.js +3 -0
- package/dist/pageTypes.js.map +1 -0
- package/dist/react/LiveSellingProvider.d.ts +31 -1
- package/dist/react/LiveSellingProvider.d.ts.map +1 -1
- package/dist/react/LiveSellingProvider.js +44 -2
- package/dist/react/LiveSellingProvider.js.map +1 -1
- package/dist/react/index.d.ts +12 -0
- package/dist/react/index.d.ts.map +1 -1
- package/dist/react/index.js +34 -1
- package/dist/react/index.js.map +1 -1
- package/dist/react/index.web.d.ts +13 -32
- package/dist/react/index.web.d.ts.map +1 -1
- package/dist/react/index.web.js +52 -139
- package/dist/react/index.web.js.map +1 -1
- package/dist/react/navigation.d.ts +13 -0
- package/dist/react/navigation.d.ts.map +1 -0
- package/dist/react/navigation.js +7 -0
- package/dist/react/navigation.js.map +1 -0
- package/dist/react/platformSession.d.ts +16 -0
- package/dist/react/platformSession.d.ts.map +1 -0
- package/dist/react/platformSession.js +28 -0
- package/dist/react/platformSession.js.map +1 -0
- package/dist/react/platformSession.web.d.ts +35 -0
- package/dist/react/platformSession.web.d.ts.map +1 -0
- package/dist/react/platformSession.web.js +148 -0
- package/dist/react/platformSession.web.js.map +1 -0
- package/dist/react/replayPlayer.d.ts +74 -0
- package/dist/react/replayPlayer.d.ts.map +1 -0
- package/dist/react/replayPlayer.js +279 -0
- package/dist/react/replayPlayer.js.map +1 -0
- package/dist/react/shopifyProviders.d.ts +69 -0
- package/dist/react/shopifyProviders.d.ts.map +1 -0
- package/dist/react/shopifyProviders.js +100 -0
- package/dist/react/shopifyProviders.js.map +1 -0
- package/dist/react/useAccountName.d.ts +8 -0
- package/dist/react/useAccountName.d.ts.map +1 -0
- package/dist/react/useAccountName.js +49 -0
- package/dist/react/useAccountName.js.map +1 -0
- package/dist/react/useClipsPage.d.ts +47 -0
- package/dist/react/useClipsPage.d.ts.map +1 -0
- package/dist/react/useClipsPage.js +130 -0
- package/dist/react/useClipsPage.js.map +1 -0
- package/dist/react/useKeepScreenAwake.d.ts +2 -0
- package/dist/react/useKeepScreenAwake.d.ts.map +1 -0
- package/dist/react/useKeepScreenAwake.js +34 -0
- package/dist/react/useKeepScreenAwake.js.map +1 -0
- package/dist/react/useLiveAuction.d.ts +106 -0
- package/dist/react/useLiveAuction.d.ts.map +1 -0
- package/dist/react/useLiveAuction.js +249 -0
- package/dist/react/useLiveAuction.js.map +1 -0
- package/dist/react/useLiveChat.d.ts +110 -0
- package/dist/react/useLiveChat.d.ts.map +1 -0
- package/dist/react/useLiveChat.js +209 -0
- package/dist/react/useLiveChat.js.map +1 -0
- package/dist/react/useLiveGiveawaysAndPolls.d.ts +95 -0
- package/dist/react/useLiveGiveawaysAndPolls.d.ts.map +1 -0
- package/dist/react/useLiveGiveawaysAndPolls.js +225 -0
- package/dist/react/useLiveGiveawaysAndPolls.js.map +1 -0
- package/dist/react/useLivePage.d.ts +134 -0
- package/dist/react/useLivePage.d.ts.map +1 -0
- package/dist/react/useLivePage.js +304 -0
- package/dist/react/useLivePage.js.map +1 -0
- package/dist/react/useLiveShop.d.ts +103 -0
- package/dist/react/useLiveShop.d.ts.map +1 -0
- package/dist/react/useLiveShop.js +211 -0
- package/dist/react/useLiveShop.js.map +1 -0
- package/dist/react/useReplayPage.d.ts +133 -0
- package/dist/react/useReplayPage.d.ts.map +1 -0
- package/dist/react/useReplayPage.js +565 -0
- package/dist/react/useReplayPage.js.map +1 -0
- package/dist/showCredit.d.ts +87 -0
- package/dist/showCredit.d.ts.map +1 -0
- package/dist/showCredit.js +120 -0
- package/dist/showCredit.js.map +1 -0
- package/dist/showNames.d.ts +11 -0
- package/dist/showNames.d.ts.map +1 -1
- package/dist/showNames.js +23 -1
- package/dist/showNames.js.map +1 -1
- package/dist/ui/BubbleFrame.d.ts +38 -0
- package/dist/ui/BubbleFrame.d.ts.map +1 -0
- package/dist/ui/BubbleFrame.js +181 -0
- package/dist/ui/BubbleFrame.js.map +1 -0
- package/dist/ui/LiveBubble.d.ts +37 -0
- package/dist/ui/LiveBubble.d.ts.map +1 -0
- package/dist/ui/LiveBubble.js +101 -0
- package/dist/ui/LiveBubble.js.map +1 -0
- package/dist/ui/ReplayBubble.d.ts +23 -0
- package/dist/ui/ReplayBubble.d.ts.map +1 -0
- package/dist/ui/ReplayBubble.js +65 -0
- package/dist/ui/ReplayBubble.js.map +1 -0
- package/dist/ui.d.ts +27 -0
- package/dist/ui.d.ts.map +1 -0
- package/dist/ui.js +34 -0
- package/dist/ui.js.map +1 -0
- package/package.json +36 -5
- package/ui/package.json +6 -0
|
@@ -0,0 +1,565 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.useReplayPage = useReplayPage;
|
|
4
|
+
/**
|
|
5
|
+
* The Replay screen's page model (0.14.0, moved from amore-v2's `src/core/hooks/useReplayPage.ts`: old
|
|
6
|
+
* Amore's Replay, rebuilt; 0.15.0 adds its link lots and a tap on the video that pauses and plays, from
|
|
7
|
+
* amore-v2's `eng928/integration`). The routes are the app's (`LiveSellingProvider`'s `routes`); the
|
|
8
|
+
* route's `feedId` and `streamId` params are read here, and `feedId` is set as the shopper swipes.
|
|
9
|
+
*/
|
|
10
|
+
const sdk_shopify_1 = require("@tiledev/sdk-shopify");
|
|
11
|
+
const react_1 = require("react");
|
|
12
|
+
const react_native_1 = require("react-native");
|
|
13
|
+
const client_1 = require("../client");
|
|
14
|
+
const linkLots_1 = require("../linkLots");
|
|
15
|
+
const liveSelling_1 = require("../liveSelling");
|
|
16
|
+
const livePages_1 = require("../livePages");
|
|
17
|
+
const pageOptions_1 = require("../pageOptions");
|
|
18
|
+
const showCredit_1 = require("../showCredit");
|
|
19
|
+
const LiveSellingProvider_1 = require("./LiveSellingProvider");
|
|
20
|
+
const platformSession_1 = require("./platformSession");
|
|
21
|
+
const replayPlayer_1 = require("./replayPlayer");
|
|
22
|
+
const useLiveShop_1 = require("./useLiveShop");
|
|
23
|
+
const useReplays_1 = require("./useReplays");
|
|
24
|
+
const navigation_1 = require("./navigation");
|
|
25
|
+
/** Recordings per read: the gateway's own page size, as the Live tab. */
|
|
26
|
+
const PAGE_SIZE = 20;
|
|
27
|
+
/** How often the playhead is read. Product windows are seconds wide, so this is plenty. */
|
|
28
|
+
const POSITION_CHECK_MS = 500;
|
|
29
|
+
/** A seek has landed once the player reports within this of it (it plays on while it seeks). */
|
|
30
|
+
const SEEK_LANDED_WITHIN_MS = 600;
|
|
31
|
+
/** Checks a seek is held for before the player is believed anyway (about 3 s): one that never lands mustn't freeze the bar. */
|
|
32
|
+
const SEEK_GIVE_UP_CHECKS = 6;
|
|
33
|
+
/** The playback controls fade this long after they last showed or were touched. */
|
|
34
|
+
const CONTROLS_SHOW_MS = 4000;
|
|
35
|
+
/**
|
|
36
|
+
* Everything the Replay screen wires, so the screen stays plain tiles. Call it from the Replay screen
|
|
37
|
+
* and from each of its tiles' wiring.
|
|
38
|
+
*
|
|
39
|
+
* - **A feed over the archive.** The route names where the shopper comes in (`feedId` from a card,
|
|
40
|
+
* `streamId` from a push or link); `useReplays` (playable recordings, 20 a read) is paged until that
|
|
41
|
+
* recording turns up. A swipe moves along the archive, and the next page is read when the shopper
|
|
42
|
+
* reaches the last one or two read so far. Hidden shows a shopper can't see are left out
|
|
43
|
+
* (`hiddenShows`), as on the Live tab: one opened by its id reads the archive to its end, then "This
|
|
44
|
+
* show has ended".
|
|
45
|
+
* - **One player** (expo-video) for the whole app, borrowed from `ReplayPlayerProvider`, which owns it
|
|
46
|
+
* above the navigator so it outlives this screen: a new recording replaces the source, one source per
|
|
47
|
+
* recording, and its poster covers the picture until the video has a frame. It plays while the screen
|
|
48
|
+
* is on show, or only covered by a sheet (`routes.sheets`: the variant page), or in the bubble, and
|
|
49
|
+
* pauses under anything else.
|
|
50
|
+
* - **Picture-in-picture, in the app** (decided 2026-10-05, amore-v2's Head of Engineering): the
|
|
51
|
+
* header's picture-in-picture button shrinks the show into a floating bubble over the app and goes
|
|
52
|
+
* back (Home when there's nothing to go back to: `routes.openHome`); its cart button shrinks it the
|
|
53
|
+
* same way and opens the Cart (`routes.openCart`). Arriving on this screen ends the bubble, and the
|
|
54
|
+
* screen shows the video where the bubble had it; ✕ stops the show, with no bubble. Opening another
|
|
55
|
+
* recording replaces the bubble's. No system picture-in-picture. One shrunk show at a time: arriving
|
|
56
|
+
* here stops a live show's bubble, as the Live screen stops this one's.
|
|
57
|
+
* - **The playhead** is read twice a second. A seek is held until the player reports arriving there,
|
|
58
|
+
* so the bar never jumps back to where it was.
|
|
59
|
+
* - **A tap on the video pauses or plays** (0.15.0; decided 2026-10-20 by amore-v2's Head of
|
|
60
|
+
* Engineering, as the clips reel's; until then a tap showed or hid the controls): the controls' own
|
|
61
|
+
* Play and Pause, which shows the controls for their 4 s, so the skips and the bar are in reach.
|
|
62
|
+
* While the shopper has paused, the player draws the reel's play mark (`player.paused`).
|
|
63
|
+
* - **The product on screen** is the one whose time window covers the playhead
|
|
64
|
+
* (`liveSelling.replays.segments`, `productOnScreen`); before the first window, the first tagged
|
|
65
|
+
* product. Picking a product in the shop sheet goes to where the host first showed it, playing, then
|
|
66
|
+
* opens the variant page (`routes.openVariantPage`); a product the host never showed (tagged, no time
|
|
67
|
+
* window) leaves the player untouched, where it was and playing or paused, and only opens the variant
|
|
68
|
+
* page. Every add from there is credited to the recording (`replayShowCredit`): `_replay_id` on the
|
|
69
|
+
* line, `replayAddToCart` (`track`), and the cart's `_apptile_attribution` count against the show's
|
|
70
|
+
* `streamingId`, never the replay's feed id. Products are read at sdk-shopify's `CARD_IMAGE`.
|
|
71
|
+
* - **Links the host added** (0.15.0; amore-v2, 2026-10-19: lots that are web addresses, mostly
|
|
72
|
+
* affiliate links): the feed lists only products, so the show's record (`liveSelling.streams.byId`) is
|
|
73
|
+
* read with them, once per recording per visit, and gives the shop its order, the links among the
|
|
74
|
+
* products (`recordingShopItems`). A link can be the lot on screen (its time window, by its id) and is
|
|
75
|
+
* a card in the sheet (`ReplayShopLink`); a tap opens it inside the app, the show in the bubble as for
|
|
76
|
+
* the cart (`routes.openLink`), and share shares its address. An unreadable record leaves the products
|
|
77
|
+
* alone, as before, and is reported.
|
|
78
|
+
* - **The chat** is the show's comments file (`liveSelling.replays.comments`), revealed up to the
|
|
79
|
+
* playhead, the newest 60 (`replayCommentsAt`).
|
|
80
|
+
* - **A view** is counted once per recording per visit (not on the web, where the Tile preview would
|
|
81
|
+
* count on the merchant's real counter); a show back from the bubble isn't a new view.
|
|
82
|
+
* - **A read that fails** (the products, the time windows, the chat) goes to `onWarning`; a failed
|
|
83
|
+
* products or windows read is tried again when the shopper comes back to the recording.
|
|
84
|
+
*/
|
|
85
|
+
function useReplayPage() {
|
|
86
|
+
var _a, _b, _c, _d, _e, _f, _g, _h, _j, _k;
|
|
87
|
+
const nav = (0, navigation_1.useNavigation)();
|
|
88
|
+
const route = (0, navigation_1.useRoute)();
|
|
89
|
+
const linkedId = (_d = (_b = (_a = route.params) === null || _a === void 0 ? void 0 : _a.feedId) !== null && _b !== void 0 ? _b : (_c = route.params) === null || _c === void 0 ? void 0 : _c.streamId) !== null && _d !== void 0 ? _d : '';
|
|
90
|
+
const { ready } = (0, LiveSellingProvider_1.useLiveSelling)();
|
|
91
|
+
const { routes, track, canOpenLinks } = (0, LiveSellingProvider_1.useLivePageOptions)();
|
|
92
|
+
const wishlist = (0, sdk_shopify_1.useWishlist)();
|
|
93
|
+
// `firstReadDone`: the first read has finished; until then an empty archive is still being read.
|
|
94
|
+
const archive = (0, useReplays_1.useReplays)({ pageSize: PAGE_SIZE, playableOnly: true });
|
|
95
|
+
const { loadMore, hasMore, hasRead: firstReadDone, loading: reading, error: readFailed } = archive;
|
|
96
|
+
// The recordings this shopper may see: hidden shows they can't see are left out.
|
|
97
|
+
const shows = archive.replays;
|
|
98
|
+
const { itemCount } = (0, sdk_shopify_1.useCart)();
|
|
99
|
+
// The app's one replay player: borrowed, as it outlives this screen for the bubble.
|
|
100
|
+
const replayPlayer = (0, replayPlayer_1.useReplayPlayer)();
|
|
101
|
+
const { player, bubbleShown, muted, openRecording, holdsVideo, stop, showBubble, hideBubble, setPausedByShopper, markVideoReady, setScreenShowing, screenClosed, } = replayPlayer;
|
|
102
|
+
// ─── Which recording ───────────────────────────────────────────────────────────────────────────
|
|
103
|
+
// State, seeded from the route: a swipe moves on without a navigation, and a new link moves it again.
|
|
104
|
+
const [currentId, setCurrentId] = (0, react_1.useState)(linkedId);
|
|
105
|
+
(0, react_1.useEffect)(() => setCurrentId(linkedId), [linkedId]);
|
|
106
|
+
const index = currentId ? shows.findIndex((replay) => (0, livePages_1.isTheShow)(replay, currentId)) : -1;
|
|
107
|
+
// A recording back from the bubble shows at once: the player holds it, and a new screen reads the
|
|
108
|
+
// archive from the start, so it would otherwise wait for that read to find it again.
|
|
109
|
+
const heldRecording = replayPlayer.recording;
|
|
110
|
+
const show = index >= 0 ? shows[index] : heldRecording && currentId && (0, livePages_1.isTheShow)(heldRecording, currentId) ? heldRecording : null;
|
|
111
|
+
const previousShow = index > 0 ? shows[index - 1] : null;
|
|
112
|
+
const nextShow = index >= 0 ? ((_e = shows[index + 1]) !== null && _e !== void 0 ? _e : null) : null;
|
|
113
|
+
// Read on until the recording turns up. One read at a time: `useReplays` ignores a second.
|
|
114
|
+
const readSoFar = !!currentId && archive.replays.some((replay) => (0, livePages_1.isTheShow)(replay, currentId));
|
|
115
|
+
const searching = !!currentId && !readSoFar && hasMore && !readFailed;
|
|
116
|
+
(0, react_1.useEffect)(() => {
|
|
117
|
+
if (ready && firstReadDone && searching && !reading)
|
|
118
|
+
void loadMore();
|
|
119
|
+
}, [ready, firstReadDone, searching, reading, loadMore]);
|
|
120
|
+
// The next page before the shopper reaches the end, so the swipe after the last one lands.
|
|
121
|
+
const nearTheEnd = index >= 0 && index >= shows.length - 2;
|
|
122
|
+
(0, react_1.useEffect)(() => {
|
|
123
|
+
if (nearTheEnd && hasMore && !reading && !readFailed)
|
|
124
|
+
void loadMore();
|
|
125
|
+
}, [nearTheEnd, hasMore, reading, readFailed, loadMore]);
|
|
126
|
+
// Not in the archive (or a hidden show this shopper can't see), or the archive couldn't be read.
|
|
127
|
+
const missing = !currentId || (firstReadDone && !show && !searching && !reading);
|
|
128
|
+
const goTo = (0, react_1.useCallback)((target) => {
|
|
129
|
+
if (!target)
|
|
130
|
+
return;
|
|
131
|
+
setCurrentId(target.id);
|
|
132
|
+
// The route follows, so a reload or a later link starts from the show being watched.
|
|
133
|
+
nav.setParams({ feedId: target.id, streamId: undefined });
|
|
134
|
+
}, [nav]);
|
|
135
|
+
// ─── The player ────────────────────────────────────────────────────────────────────────────────
|
|
136
|
+
const isFocused = (0, navigation_1.useIsFocused)();
|
|
137
|
+
const coveredOnlyBySheet = (0, navigation_1.useNavigationState)((state) => (0, livePages_1.isCoveredOnlyBySheet)(state, route.key, routes.sheets));
|
|
138
|
+
const onScreen = isFocused || coveredOnlyBySheet;
|
|
139
|
+
const videoUrl = (_f = show === null || show === void 0 ? void 0 : show.videoUrl) !== null && _f !== void 0 ? _f : null;
|
|
140
|
+
/** The player holds this screen's recording. It may hold another (the bubble's, until this screen takes over) or none. */
|
|
141
|
+
const holdsThisShow = !!videoUrl && replayPlayer.videoUrl === videoUrl;
|
|
142
|
+
const playing = holdsThisShow && replayPlayer.playing;
|
|
143
|
+
const status = holdsThisShow ? replayPlayer.status : 'loading';
|
|
144
|
+
const videoReady = holdsThisShow && replayPlayer.videoReady;
|
|
145
|
+
// Back from the bubble, the player is already somewhere in the recording: start from there.
|
|
146
|
+
const [positionMs, setPositionMs] = (0, react_1.useState)(() => (holdsThisShow ? (0, livePages_1.playerMs)(player.currentTime) : 0));
|
|
147
|
+
/** While the shopper drags the bar: the product card and chat follow the finger, not the playhead. */
|
|
148
|
+
const [scrubMs, setScrubMs] = (0, react_1.useState)(null);
|
|
149
|
+
const [durationMs, setDurationMs] = (0, react_1.useState)(() => (holdsThisShow ? (0, livePages_1.playerMs)(player.duration) : 0));
|
|
150
|
+
/** A seek asked for and not yet reported back: the player keeps saying the old time until it lands. */
|
|
151
|
+
const pendingSeek = (0, react_1.useRef)(null);
|
|
152
|
+
const latest = (0, react_1.useRef)({ durationMs, holdsThisShow });
|
|
153
|
+
latest.current = { durationMs, holdsThisShow };
|
|
154
|
+
/** ✕ was pressed: the show has stopped, and the screen slides away on its poster. */
|
|
155
|
+
const [closing, setClosing] = (0, react_1.useState)(false);
|
|
156
|
+
// On show here, this screen's recording goes into the player, from the start, unless the player
|
|
157
|
+
// already holds it (back from the bubble, it plays on where it was). Not while the bubble is still
|
|
158
|
+
// up: arriving closes it first (below), so its view never loads another recording. Not once ✕ has
|
|
159
|
+
// stopped it, while the screen is still on show for its way out. The player is asked at the moment
|
|
160
|
+
// this runs (`holdsVideo`).
|
|
161
|
+
const showToOpen = (0, react_1.useRef)(show);
|
|
162
|
+
showToOpen.current = show;
|
|
163
|
+
(0, react_1.useEffect)(() => {
|
|
164
|
+
const target = showToOpen.current;
|
|
165
|
+
if (closing || !onScreen || bubbleShown || !videoUrl || !target || holdsVideo(videoUrl))
|
|
166
|
+
return;
|
|
167
|
+
setPositionMs(0);
|
|
168
|
+
setScrubMs(null);
|
|
169
|
+
setDurationMs(0);
|
|
170
|
+
// Held at 0 until the player stops reporting the last recording's time.
|
|
171
|
+
pendingSeek.current = { targetMs: 0, checks: 0 };
|
|
172
|
+
openRecording(target);
|
|
173
|
+
}, [closing, onScreen, bubbleShown, videoUrl, holdsVideo, openRecording]);
|
|
174
|
+
// Arriving here ends the bubble, however the shopper came (its tap, a link, back from the cart): the
|
|
175
|
+
// screen shows the video again. A screen ✕ couldn't take away (nothing behind it, so Home opened
|
|
176
|
+
// over it) plays again if the shopper comes back to it.
|
|
177
|
+
(0, react_1.useEffect)(() => {
|
|
178
|
+
if (!isFocused)
|
|
179
|
+
return;
|
|
180
|
+
hideBubble();
|
|
181
|
+
setClosing(false);
|
|
182
|
+
}, [isFocused, hideBubble]);
|
|
183
|
+
// One shrunk show at a time: a live show left in its bubble stops, and its pin goes with it.
|
|
184
|
+
const { pipMode: livePipMode, actions: liveActions } = (0, platformSession_1.useLiveSession)();
|
|
185
|
+
const { exitPip: closeLiveBubble, releaseStream: releaseLiveShow } = liveActions;
|
|
186
|
+
(0, react_1.useEffect)(() => {
|
|
187
|
+
if (!isFocused || livePipMode !== 'inapp')
|
|
188
|
+
return;
|
|
189
|
+
closeLiveBubble({ stopVideo: true });
|
|
190
|
+
releaseLiveShow();
|
|
191
|
+
}, [isFocused, livePipMode, closeLiveBubble, releaseLiveShow]);
|
|
192
|
+
// The player plays only while something shows it: this screen says when it does. Closing it stops
|
|
193
|
+
// the video, unless the bubble took it.
|
|
194
|
+
const screenKey = route.key;
|
|
195
|
+
const showingHere = onScreen && holdsThisShow;
|
|
196
|
+
(0, react_1.useEffect)(() => {
|
|
197
|
+
setScreenShowing(screenKey, showingHere);
|
|
198
|
+
}, [screenKey, showingHere, setScreenShowing]);
|
|
199
|
+
(0, react_1.useEffect)(() => () => screenClosed(screenKey), [screenKey, screenClosed]);
|
|
200
|
+
// The playhead, read rather than subscribed: product windows only need to land within half a second.
|
|
201
|
+
(0, react_1.useEffect)(() => {
|
|
202
|
+
const timer = setInterval(() => {
|
|
203
|
+
// Another recording's time (the player holds the bubble's, or nothing) isn't this one's.
|
|
204
|
+
if (!latest.current.holdsThisShow)
|
|
205
|
+
return;
|
|
206
|
+
try {
|
|
207
|
+
const reportedMs = (player.currentTime || 0) * 1000;
|
|
208
|
+
const pending = pendingSeek.current;
|
|
209
|
+
if (!pending)
|
|
210
|
+
setPositionMs(reportedMs);
|
|
211
|
+
else if (Math.abs(reportedMs - pending.targetMs) <= SEEK_LANDED_WITHIN_MS || pending.checks + 1 >= SEEK_GIVE_UP_CHECKS) {
|
|
212
|
+
pendingSeek.current = null;
|
|
213
|
+
setPositionMs(reportedMs);
|
|
214
|
+
}
|
|
215
|
+
else
|
|
216
|
+
pendingSeek.current = { targetMs: pending.targetMs, checks: pending.checks + 1 };
|
|
217
|
+
// A length that arrives late, or that the playlist revises.
|
|
218
|
+
const lengthSeconds = player.duration;
|
|
219
|
+
if (Number.isFinite(lengthSeconds) && lengthSeconds > 0)
|
|
220
|
+
setDurationMs(lengthSeconds * 1000);
|
|
221
|
+
}
|
|
222
|
+
catch {
|
|
223
|
+
// The player was released under the timer (the app is closing).
|
|
224
|
+
}
|
|
225
|
+
}, POSITION_CHECK_MS);
|
|
226
|
+
return () => clearInterval(timer);
|
|
227
|
+
}, [player]);
|
|
228
|
+
const seekTo = (0, react_1.useCallback)((targetMs) => {
|
|
229
|
+
if (!latest.current.holdsThisShow)
|
|
230
|
+
return;
|
|
231
|
+
const length = latest.current.durationMs;
|
|
232
|
+
const target = Math.max(0, length > 0 ? Math.min(targetMs, length) : targetMs);
|
|
233
|
+
pendingSeek.current = { targetMs: target, checks: 0 };
|
|
234
|
+
try {
|
|
235
|
+
player.currentTime = target / 1000;
|
|
236
|
+
}
|
|
237
|
+
catch {
|
|
238
|
+
pendingSeek.current = null;
|
|
239
|
+
return;
|
|
240
|
+
}
|
|
241
|
+
setPositionMs(target);
|
|
242
|
+
setScrubMs(null);
|
|
243
|
+
}, [player]);
|
|
244
|
+
const shownPositionMs = scrubMs !== null && scrubMs !== void 0 ? scrubMs : positionMs;
|
|
245
|
+
// ─── The controls: up for 4 s after they show or are touched; a tap on the video shows them ───
|
|
246
|
+
const [controlsVisible, setControlsVisible] = (0, react_1.useState)(true);
|
|
247
|
+
const [controlsTouches, setControlsTouches] = (0, react_1.useState)(0);
|
|
248
|
+
const showControls = (0, react_1.useCallback)(() => {
|
|
249
|
+
setControlsVisible(true);
|
|
250
|
+
setControlsTouches((count) => count + 1);
|
|
251
|
+
}, []);
|
|
252
|
+
(0, react_1.useEffect)(() => {
|
|
253
|
+
if (!controlsVisible)
|
|
254
|
+
return;
|
|
255
|
+
const timer = setTimeout(() => setControlsVisible(false), CONTROLS_SHOW_MS);
|
|
256
|
+
return () => clearTimeout(timer);
|
|
257
|
+
}, [controlsVisible, controlsTouches]);
|
|
258
|
+
/**
|
|
259
|
+
* Pause or play: the controls' middle button, and a tap on the video, as the clips reel's (0.15.0;
|
|
260
|
+
* decided 2026-10-20 by amore-v2's Head of Engineering; until then a tap showed or hid the controls).
|
|
261
|
+
* Either shows the controls for their 4 s, so after a tap on the video the skips and the bar are in reach.
|
|
262
|
+
*/
|
|
263
|
+
const togglePlay = () => {
|
|
264
|
+
showControls();
|
|
265
|
+
if (!holdsThisShow)
|
|
266
|
+
return;
|
|
267
|
+
if (playing) {
|
|
268
|
+
setPausedByShopper(true);
|
|
269
|
+
return;
|
|
270
|
+
}
|
|
271
|
+
setPausedByShopper(false);
|
|
272
|
+
// At the end of the recording, play means from the start.
|
|
273
|
+
if (durationMs > 0 && shownPositionMs >= durationMs - 1000)
|
|
274
|
+
seekTo(0);
|
|
275
|
+
player.play();
|
|
276
|
+
};
|
|
277
|
+
// ─── What the show sells, and its chat ─────────────────────────────────────────────────────────
|
|
278
|
+
const shoppingRead = (0, react_1.useRef)(new Map());
|
|
279
|
+
const [shopping, setShopping] = (0, react_1.useState)({ showId: '', products: [], segments: [], recordLots: null });
|
|
280
|
+
const showId = (_g = show === null || show === void 0 ? void 0 : show.id) !== null && _g !== void 0 ? _g : null;
|
|
281
|
+
const productIds = show === null || show === void 0 ? void 0 : show.productIds;
|
|
282
|
+
const streamingId = (_h = show === null || show === void 0 ? void 0 : show.streamingId) !== null && _h !== void 0 ? _h : null;
|
|
283
|
+
(0, react_1.useEffect)(() => {
|
|
284
|
+
if (!showId)
|
|
285
|
+
return;
|
|
286
|
+
const kept = shoppingRead.current.get(showId);
|
|
287
|
+
if (kept) {
|
|
288
|
+
setShopping({ showId, ...kept });
|
|
289
|
+
return;
|
|
290
|
+
}
|
|
291
|
+
let stillThisShow = true;
|
|
292
|
+
let everythingRead = true;
|
|
293
|
+
const failed = (at) => (error) => {
|
|
294
|
+
everythingRead = false;
|
|
295
|
+
(0, pageOptions_1.reportLiveWarning)(error, { at, feedId: showId });
|
|
296
|
+
return [];
|
|
297
|
+
};
|
|
298
|
+
void Promise.all([
|
|
299
|
+
(productIds === null || productIds === void 0 ? void 0 : productIds.length) ? sdk_shopify_1.shopify.products.byIds(productIds, { imageTransform: sdk_shopify_1.CARD_IMAGE }).catch(failed('replay.products')) : Promise.resolve([]),
|
|
300
|
+
liveSelling_1.liveSelling.replays.segments(showId).catch(failed('replay.segments')),
|
|
301
|
+
// The record lists the links the host added, which the feed doesn't, and the host's order.
|
|
302
|
+
streamingId
|
|
303
|
+
? liveSelling_1.liveSelling.streams
|
|
304
|
+
.byId(streamingId)
|
|
305
|
+
.then((record) => { var _a; return (_a = record === null || record === void 0 ? void 0 : record.products) !== null && _a !== void 0 ? _a : null; })
|
|
306
|
+
.catch((error) => {
|
|
307
|
+
failed('replay.record')(error);
|
|
308
|
+
return null;
|
|
309
|
+
})
|
|
310
|
+
: Promise.resolve(null),
|
|
311
|
+
]).then(([products, segments, recordLots]) => {
|
|
312
|
+
const read = { products, segments, recordLots };
|
|
313
|
+
// Kept for the visit only when it all came back: a failed read is tried again when the shopper returns.
|
|
314
|
+
if (everythingRead)
|
|
315
|
+
shoppingRead.current.set(showId, read);
|
|
316
|
+
if (stillThisShow)
|
|
317
|
+
setShopping({ showId, ...read });
|
|
318
|
+
});
|
|
319
|
+
return () => {
|
|
320
|
+
stillThisShow = false;
|
|
321
|
+
};
|
|
322
|
+
}, [showId, productIds, streamingId]);
|
|
323
|
+
const products = shopping.showId === showId ? shopping.products : [];
|
|
324
|
+
const segments = shopping.showId === showId ? shopping.segments : [];
|
|
325
|
+
const recordLots = shopping.showId === showId ? shopping.recordLots : null;
|
|
326
|
+
/** The shop in the host's order: the products and the links the host added among them. */
|
|
327
|
+
const shopItems = (0, react_1.useMemo)(() => (0, linkLots_1.recordingShopItems)(products, recordLots, client_1.toProductGid, { canOpen: canOpenLinks }), [products, recordLots, canOpenLinks]);
|
|
328
|
+
// A link's window is keyed by its lot's id, as a product's is.
|
|
329
|
+
const onScreenItem = (0, react_1.useMemo)(() => (0, livePages_1.productOnScreen)(segments, shopItems, shownPositionMs, (item) => ((0, linkLots_1.isShowLink)(item) ? (0, client_1.toProductGid)(item.id) : item.id)), [segments, shopItems, shownPositionMs]);
|
|
330
|
+
const onScreenProduct = onScreenItem && !(0, linkLots_1.isShowLink)(onScreenItem) ? onScreenItem : null;
|
|
331
|
+
const onScreenLink = onScreenItem && (0, linkLots_1.isShowLink)(onScreenItem) ? onScreenItem : null;
|
|
332
|
+
const firstShownAt = (0, react_1.useCallback)((productId) => (0, livePages_1.firstShownAt)(segments, productId), [segments]);
|
|
333
|
+
const chatRead = (0, react_1.useRef)(new Map());
|
|
334
|
+
const [chat, setChat] = (0, react_1.useState)({ streamingId: '', comments: [] });
|
|
335
|
+
(0, react_1.useEffect)(() => {
|
|
336
|
+
if (!streamingId)
|
|
337
|
+
return;
|
|
338
|
+
const kept = chatRead.current.get(streamingId);
|
|
339
|
+
if (kept) {
|
|
340
|
+
setChat({ streamingId, comments: kept });
|
|
341
|
+
return;
|
|
342
|
+
}
|
|
343
|
+
let stillThisShow = true;
|
|
344
|
+
liveSelling_1.liveSelling.replays
|
|
345
|
+
.comments(streamingId)
|
|
346
|
+
.then((comments) => {
|
|
347
|
+
chatRead.current.set(streamingId, comments);
|
|
348
|
+
if (stillThisShow)
|
|
349
|
+
setChat({ streamingId, comments });
|
|
350
|
+
})
|
|
351
|
+
.catch((error) => (0, pageOptions_1.reportLiveWarning)(error, { at: 'replay.comments', streamingId }));
|
|
352
|
+
return () => {
|
|
353
|
+
stillThisShow = false;
|
|
354
|
+
};
|
|
355
|
+
}, [streamingId]);
|
|
356
|
+
const allComments = chat.streamingId === streamingId ? chat.comments : [];
|
|
357
|
+
const saidSoFar = (0, react_1.useMemo)(() => (0, livePages_1.replayCommentsAt)(allComments, shownPositionMs), [allComments, shownPositionMs]);
|
|
358
|
+
const [chatHidden, setChatHidden] = (0, react_1.useState)(false);
|
|
359
|
+
// A swipe is a new show: its own controls showing, its chat out.
|
|
360
|
+
(0, react_1.useEffect)(() => {
|
|
361
|
+
setChatHidden(false);
|
|
362
|
+
showControls();
|
|
363
|
+
}, [showId, showControls]);
|
|
364
|
+
// ─── A view, once per recording per visit; never from the web preview ─────────────────────────
|
|
365
|
+
// A recording back from the bubble was counted when it was opened: a round trip isn't a new view
|
|
366
|
+
// (production's new Replay screen on every return counted another, amore-v2's audit L4).
|
|
367
|
+
const counted = (0, react_1.useRef)(null);
|
|
368
|
+
if (!counted.current)
|
|
369
|
+
counted.current = new Set(holdsThisShow && show ? [show.id] : []);
|
|
370
|
+
(0, react_1.useEffect)(() => {
|
|
371
|
+
const seen = counted.current;
|
|
372
|
+
if (!showId || react_native_1.Platform.OS === 'web' || !seen || seen.has(showId))
|
|
373
|
+
return;
|
|
374
|
+
seen.add(showId);
|
|
375
|
+
void liveSelling_1.liveSelling.replays.incrementViews(showId);
|
|
376
|
+
}, [showId]);
|
|
377
|
+
// ─── Buying: every add from this screen is credited to the recording ──────────────────────────
|
|
378
|
+
const credit = (0, react_1.useMemo)(() => (0, showCredit_1.replayShowCredit)(showId, streamingId), [showId, streamingId]);
|
|
379
|
+
const quickAdd = (0, sdk_shopify_1.useQuickAdd)((0, showCredit_1.showQuickAddOptions)((params) => routes.openVariantPage(params, nav), { credit, track }));
|
|
380
|
+
const openVariantPage = (0, react_1.useCallback)((product) => {
|
|
381
|
+
if (!credit.lineAttributes)
|
|
382
|
+
return;
|
|
383
|
+
routes.openVariantPage({ handle: product.handle, ...credit }, nav);
|
|
384
|
+
}, [routes, nav, credit]);
|
|
385
|
+
const pickFromSheet = (0, react_1.useCallback)((product) => {
|
|
386
|
+
// Shown in the recording: to where the host first showed it, playing, so the pitch goes on behind
|
|
387
|
+
// the variant page. Never shown (no time window): the player is left exactly as it was, where it
|
|
388
|
+
// was and playing or paused; only the variant page opens (2026-10-05, Head of Engineering).
|
|
389
|
+
const startMs = firstShownAt(product.id);
|
|
390
|
+
if (startMs != null) {
|
|
391
|
+
seekTo(startMs);
|
|
392
|
+
setPausedByShopper(false);
|
|
393
|
+
}
|
|
394
|
+
openVariantPage(product);
|
|
395
|
+
}, [firstShownAt, seekTo, setPausedByShopper, openVariantPage]);
|
|
396
|
+
const nowProduct = (0, react_1.useMemo)(() => {
|
|
397
|
+
var _a, _b, _c, _d;
|
|
398
|
+
return onScreenProduct
|
|
399
|
+
? {
|
|
400
|
+
id: onScreenProduct.id,
|
|
401
|
+
title: onScreenProduct.title,
|
|
402
|
+
price: (0, sdk_shopify_1.formatMoney)(onScreenProduct.priceRange.min),
|
|
403
|
+
imageUrl: (_d = (_b = (_a = onScreenProduct.featuredImage) === null || _a === void 0 ? void 0 : _a.url) !== null && _b !== void 0 ? _b : (_c = onScreenProduct.images[0]) === null || _c === void 0 ? void 0 : _c.url) !== null && _d !== void 0 ? _d : null,
|
|
404
|
+
}
|
|
405
|
+
: onScreenLink
|
|
406
|
+
? {
|
|
407
|
+
id: onScreenLink.id,
|
|
408
|
+
title: onScreenLink.title,
|
|
409
|
+
price: onScreenLink.price,
|
|
410
|
+
imageUrl: onScreenLink.imageUrl,
|
|
411
|
+
isLink: true,
|
|
412
|
+
canOpen: !!onScreenLink.url,
|
|
413
|
+
}
|
|
414
|
+
: null;
|
|
415
|
+
}, [onScreenProduct, onScreenLink]);
|
|
416
|
+
const auctionProductIds = (0, react_1.useMemo)(() => products.filter(sdk_shopify_1.isAuctioned).map((product) => product.id), [products]);
|
|
417
|
+
const poster = (replay) => (replay ? { id: replay.id, posterUrl: replay.thumbnailUrl } : null);
|
|
418
|
+
const leave = (0, react_1.useCallback)(() => {
|
|
419
|
+
if (nav.canGoBack())
|
|
420
|
+
nav.goBack();
|
|
421
|
+
else
|
|
422
|
+
routes.openHome(nav);
|
|
423
|
+
}, [nav, routes]);
|
|
424
|
+
// ✕: the show stops, with no bubble.
|
|
425
|
+
const close = (0, react_1.useCallback)(() => {
|
|
426
|
+
setClosing(true);
|
|
427
|
+
stop();
|
|
428
|
+
leave();
|
|
429
|
+
}, [stop, leave]);
|
|
430
|
+
// Picture-in-picture: the show shrinks into the bubble, and the shopper goes back.
|
|
431
|
+
const shrinkIntoBubble = (0, react_1.useCallback)(() => {
|
|
432
|
+
if (holdsVideo(videoUrl))
|
|
433
|
+
showBubble();
|
|
434
|
+
leave();
|
|
435
|
+
}, [holdsVideo, videoUrl, showBubble, leave]);
|
|
436
|
+
// The cart opens under the bubble, so the show plays on over it, as production's; coming back here ends the bubble.
|
|
437
|
+
const openCart = (0, react_1.useCallback)(() => {
|
|
438
|
+
if (holdsVideo(videoUrl))
|
|
439
|
+
showBubble();
|
|
440
|
+
routes.openCart({ itemsYouWon: false }, nav);
|
|
441
|
+
}, [holdsVideo, videoUrl, showBubble, routes, nav]);
|
|
442
|
+
/**
|
|
443
|
+
* A link the host added (0.15.0): inside the app, never the phone's browser (`routes.openLink`, with the
|
|
444
|
+
* lot's title), the show in the bubble as for the cart; coming back here ends the bubble. Nothing for
|
|
445
|
+
* one that can't open (`url` null: not https, or an app with no `routes.openLink`).
|
|
446
|
+
*/
|
|
447
|
+
const openLink = (0, react_1.useCallback)((link) => {
|
|
448
|
+
if (!link.url)
|
|
449
|
+
return;
|
|
450
|
+
if (holdsVideo(videoUrl))
|
|
451
|
+
showBubble();
|
|
452
|
+
routes.openLink(link.url, link.title, nav);
|
|
453
|
+
}, [holdsVideo, videoUrl, showBubble, routes, nav]);
|
|
454
|
+
const playerShown = !missing;
|
|
455
|
+
const showing = !!show;
|
|
456
|
+
return {
|
|
457
|
+
/** The video is on screen: light status bar text over it. */
|
|
458
|
+
darkBehindStatusBar: playerShown && onScreen,
|
|
459
|
+
player: {
|
|
460
|
+
visible: playerShown,
|
|
461
|
+
show: poster(show),
|
|
462
|
+
previousShow: poster(previousShow),
|
|
463
|
+
nextShow: poster(nextShow),
|
|
464
|
+
// Drawn only once the player holds this recording, a new view per recording: on web a view still
|
|
465
|
+
// showing the last one would load the new one twice (from `replace`, then from React setting its
|
|
466
|
+
// `src`), and the second load aborts the first's `play()` (an unhandled `AbortError` inside
|
|
467
|
+
// expo-video's web player). And one view at a time: while the bubble has the video, none here.
|
|
468
|
+
player: holdsThisShow && !bubbleShown ? player : null,
|
|
469
|
+
// The poster stands in for the picture while the bubble has it (the screen sliding away, or under the cart).
|
|
470
|
+
videoReady: videoReady && !bubbleShown,
|
|
471
|
+
buffering: !closing && !!videoUrl && status !== 'error' && (status === 'loading' || !videoReady),
|
|
472
|
+
// The reel's play mark while the shopper has paused it (0.15.0).
|
|
473
|
+
paused: holdsThisShow && replayPlayer.pausedByShopper,
|
|
474
|
+
onVideoFirstFrame: () => {
|
|
475
|
+
if (holdsThisShow)
|
|
476
|
+
markVideoReady();
|
|
477
|
+
},
|
|
478
|
+
onTapVideo: togglePlay,
|
|
479
|
+
onSwipeToNext: () => goTo(nextShow),
|
|
480
|
+
onSwipeToPrevious: () => goTo(previousShow),
|
|
481
|
+
},
|
|
482
|
+
header: {
|
|
483
|
+
title: (_j = show === null || show === void 0 ? void 0 : show.title) !== null && _j !== void 0 ? _j : null,
|
|
484
|
+
muted,
|
|
485
|
+
canMute: showing,
|
|
486
|
+
// Something to shrink: the player holds this recording.
|
|
487
|
+
canPip: holdsThisShow,
|
|
488
|
+
cartCount: itemCount,
|
|
489
|
+
onClose: close,
|
|
490
|
+
onToggleMute: () => {
|
|
491
|
+
replayPlayer.setMuted(!muted);
|
|
492
|
+
showControls();
|
|
493
|
+
},
|
|
494
|
+
onPip: shrinkIntoBubble,
|
|
495
|
+
onCart: openCart,
|
|
496
|
+
},
|
|
497
|
+
controls: {
|
|
498
|
+
visible: showing && controlsVisible,
|
|
499
|
+
positionMs: shownPositionMs,
|
|
500
|
+
durationMs,
|
|
501
|
+
playing,
|
|
502
|
+
onScrub: (atMs) => {
|
|
503
|
+
setScrubMs(atMs);
|
|
504
|
+
showControls();
|
|
505
|
+
},
|
|
506
|
+
onSeek: (atMs) => {
|
|
507
|
+
seekTo(atMs);
|
|
508
|
+
showControls();
|
|
509
|
+
},
|
|
510
|
+
onSkip: (changeMs) => {
|
|
511
|
+
var _a, _b;
|
|
512
|
+
// From the time last asked for, so tapping +10 twice adds up while the first is still seeking.
|
|
513
|
+
seekTo(((_b = (_a = pendingSeek.current) === null || _a === void 0 ? void 0 : _a.targetMs) !== null && _b !== void 0 ? _b : shownPositionMs) + changeMs);
|
|
514
|
+
showControls();
|
|
515
|
+
},
|
|
516
|
+
onTogglePlay: togglePlay,
|
|
517
|
+
},
|
|
518
|
+
nowCard: {
|
|
519
|
+
visible: showing,
|
|
520
|
+
product: nowProduct,
|
|
521
|
+
favorite: !!onScreenProduct && wishlist.has(onScreenProduct.id),
|
|
522
|
+
onOpen: () => {
|
|
523
|
+
if (onScreenProduct)
|
|
524
|
+
openVariantPage(onScreenProduct);
|
|
525
|
+
else if (onScreenLink)
|
|
526
|
+
openLink(onScreenLink);
|
|
527
|
+
},
|
|
528
|
+
onToggleFavorite: () => {
|
|
529
|
+
if (onScreenProduct)
|
|
530
|
+
void wishlist.toggle(onScreenProduct);
|
|
531
|
+
},
|
|
532
|
+
onShare: () => {
|
|
533
|
+
if (onScreenProduct)
|
|
534
|
+
void (0, useLiveShop_1.shareProduct)(onScreenProduct);
|
|
535
|
+
else if (onScreenLink)
|
|
536
|
+
void (0, useLiveShop_1.shareAddress)(onScreenLink.url);
|
|
537
|
+
},
|
|
538
|
+
},
|
|
539
|
+
comments: {
|
|
540
|
+
visible: showing,
|
|
541
|
+
comments: saidSoFar,
|
|
542
|
+
hasChat: allComments.length > 0,
|
|
543
|
+
hidden: chatHidden,
|
|
544
|
+
onToggleHidden: () => setChatHidden((wasHidden) => !wasHidden),
|
|
545
|
+
},
|
|
546
|
+
shopBar: {
|
|
547
|
+
visible: showing,
|
|
548
|
+
/** The products and the links the host added (`ReplayShopLink`), in the record's order. */
|
|
549
|
+
products: shopItems,
|
|
550
|
+
onScreenProductId: (_k = onScreenItem === null || onScreenItem === void 0 ? void 0 : onScreenItem.id) !== null && _k !== void 0 ? _k : null,
|
|
551
|
+
favoriteIds: wishlist.ids,
|
|
552
|
+
auctionProductIds,
|
|
553
|
+
onPressProduct: pickFromSheet,
|
|
554
|
+
onOpenLink: openLink,
|
|
555
|
+
onToggleFavorite: (product) => void wishlist.toggle(product),
|
|
556
|
+
onQuickAdd: quickAdd.add,
|
|
557
|
+
addingProductIds: quickAdd.addingProductIds,
|
|
558
|
+
},
|
|
559
|
+
missing: {
|
|
560
|
+
visible: missing,
|
|
561
|
+
onAction: () => routes.openHome(nav),
|
|
562
|
+
},
|
|
563
|
+
};
|
|
564
|
+
}
|
|
565
|
+
//# sourceMappingURL=useReplayPage.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"useReplayPage.js","sourceRoot":"","sources":["../../src/react/useReplayPage.ts"],"names":[],"mappings":";;AAkHA,sCAkfC;AApmBD;;;;;GAKG;AACH,sDAS8B;AAE9B,iCAA0E;AAC1E,+CAAwC;AAExC,sCAAyC;AACzC,0CAA4F;AAC5F,gDAA6C;AAC7C,4CAA4I;AAC5I,gDAAmD;AAEnD,8CAAsE;AAEtE,+DAA2E;AAC3E,uDAAmD;AACnD,iDAAiD;AACjD,+CAA2D;AAC3D,6CAA0C;AAC1C,6CAQsB;AAEtB,yEAAyE;AACzE,MAAM,SAAS,GAAG,EAAE,CAAC;AACrB,2FAA2F;AAC3F,MAAM,iBAAiB,GAAG,GAAG,CAAC;AAC9B,gGAAgG;AAChG,MAAM,qBAAqB,GAAG,GAAG,CAAC;AAClC,+HAA+H;AAC/H,MAAM,mBAAmB,GAAG,CAAC,CAAC;AAC9B,mFAAmF;AACnF,MAAM,gBAAgB,GAAG,IAAI,CAAC;AAY9B;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;GAiDG;AACH,SAAgB,aAAa;;IAC3B,MAAM,GAAG,GAAG,IAAA,0BAAa,GAAiC,CAAC;IAC3D,MAAM,KAAK,GAAG,IAAA,qBAAQ,GAAe,CAAC;IACtC,MAAM,QAAQ,GAAG,MAAA,MAAA,MAAA,KAAK,CAAC,MAAM,0CAAE,MAAM,mCAAI,MAAA,KAAK,CAAC,MAAM,0CAAE,QAAQ,mCAAI,EAAE,CAAC;IACtE,MAAM,EAAE,KAAK,EAAE,GAAG,IAAA,oCAAc,GAAE,CAAC;IACnC,MAAM,EAAE,MAAM,EAAE,KAAK,EAAE,YAAY,EAAE,GAAG,IAAA,wCAAkB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