@tiledev/sdk-apptile-live-selling 0.1.0 → 0.2.1
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 +24 -6
- package/dist/index.d.ts +17 -2
- package/dist/index.d.ts.map +1 -1
- package/dist/index.js +31 -6
- package/dist/index.js.map +1 -1
- package/dist/react/index.web.d.ts +42 -0
- package/dist/react/index.web.d.ts.map +1 -0
- package/dist/react/index.web.js +167 -0
- package/dist/react/index.web.js.map +1 -0
- package/package.json +8 -13
- package/session/package.json +6 -0
- package/types/package.json +6 -0
- package/react/package.json +0 -6
package/README.md
CHANGED
|
@@ -14,11 +14,19 @@ supply, so there is no Shopify dependency.
|
|
|
14
14
|
npm i @tiledev/sdk-apptile-live-selling
|
|
15
15
|
```
|
|
16
16
|
|
|
17
|
-
Peers
|
|
18
|
-
|
|
17
|
+
Peers: `react` and `react-native` are needed by the main entry, which re-exports the React layer;
|
|
18
|
+
`expo` and `zego-express-engine-reactnative` stay optional — off-device the engine and PIP resolve to
|
|
19
|
+
no-ops.
|
|
19
20
|
|
|
20
|
-
|
|
21
|
-
|
|
21
|
+
**Everything ships from the package root**, including the providers, the hooks and `LiveVideoTarget`.
|
|
22
|
+
There is no `./react` subpath — a subpath is reachable only through the `exports` map, which a
|
|
23
|
+
resolver that ignores it (node10, some test runners and bundlers) cannot see at all. What remains
|
|
24
|
+
beside the root is `./types` (types alone) and a wildcard for any module in `dist` — `/session`,
|
|
25
|
+
`/streams`, `/polls` — the escape hatch below.
|
|
26
|
+
|
|
27
|
+
> The root entry pulls in `react-native`, so it no longer loads in a plain Node runtime. Driving the
|
|
28
|
+
> pure data layer from Node — `sessionReducer`, the wire mappers — goes through the module subpaths
|
|
29
|
+
> (`@tiledev/sdk-apptile-live-selling/session`), which stay free of React and react-native.
|
|
22
30
|
|
|
23
31
|
## 1. Add the config plugin
|
|
24
32
|
|
|
@@ -95,7 +103,7 @@ player). Own it per screen and whichever unmounts first kills the other's video.
|
|
|
95
103
|
```tsx
|
|
96
104
|
import {
|
|
97
105
|
LiveSellingProvider, LiveSessionProvider, useLiveSession, LiveVideoTarget,
|
|
98
|
-
} from '@tiledev/sdk-apptile-live-selling
|
|
106
|
+
} from '@tiledev/sdk-apptile-live-selling';
|
|
99
107
|
|
|
100
108
|
<LiveSellingProvider config={config}>
|
|
101
109
|
<LiveSessionProvider onPipRestore={() => navigate('Live')}>
|
|
@@ -249,6 +257,15 @@ Two pairs of files, and Metro picks by platform. TypeScript resolves the non-nat
|
|
|
249
257
|
|---|---|
|
|
250
258
|
| `engine.native.ts` — the real Zego engine; owns the room, plays into a rebindable view, publishes a guest's camera, translates every Zego channel into a `LiveEvent` | `engine.ts` — no-op, `isNoop: true` |
|
|
251
259
|
| `pip.native.ts` — the `LivePip` Expo module | `pip.ts` — no-op, `isLivePipSupported: false` |
|
|
260
|
+
| `react/index.ts` — the real providers, hooks and video target | `react/index.web.ts` — real client and read hooks, idle session, `View` in place of the texture view |
|
|
261
|
+
|
|
262
|
+
The web file is not only about behaviour. `LiveVideoTarget` requires `zego-express-engine-reactnative`
|
|
263
|
+
for its texture view, and a bundler collects that `require` whichever branch would run it — so a web
|
|
264
|
+
build in a workspace without the Zego SDK installed fails to *resolve* it, before any of this runs.
|
|
265
|
+
Serving the stand-ins keeps the native entry out of a web graph altogether. What a browser can do
|
|
266
|
+
honestly stays real: the client, the gateway calls, and the stream/replay/clip read hooks. What it
|
|
267
|
+
cannot is inert — `useLiveSession()` reports a permanently `ended` session (the empty state every
|
|
268
|
+
surface already draws), the bid gate never blocks, and the wins tab is empty.
|
|
252
269
|
|
|
253
270
|
So the session never arms a handover that cannot happen, and a web bundle never evaluates the Zego
|
|
254
271
|
entry module.
|
|
@@ -293,7 +310,8 @@ Subscribe via `LiveSellingProvider`'s `onEvent` or `liveSelling.engine.subscribe
|
|
|
293
310
|
| `npm pack` | The publish tarball — use it to verify `dist`, `ios/`, `android/`, `expo-module.config.json`, `app.plugin.js` and `plugin/build` all ship |
|
|
294
311
|
|
|
295
312
|
The reducer is exported on its own (`sessionReducer`, `deriveStatus`, `timeLeftMs`) and is pure, so it
|
|
296
|
-
can be driven with no room, socket or React
|
|
313
|
+
can be driven with no room, socket or React — from Node, import it as
|
|
314
|
+
`@tiledev/sdk-apptile-live-selling/session` rather than off the root.
|
|
297
315
|
|
|
298
316
|
## Gotchas
|
|
299
317
|
|
package/dist/index.d.ts
CHANGED
|
@@ -2,8 +2,9 @@
|
|
|
2
2
|
* `@tiledev/sdk-apptile-live-selling` — the live-selling integration as a standalone package.
|
|
3
3
|
*
|
|
4
4
|
* A typed, imperative client for the Apptile live-selling gateway (streams, auctions, polls, clips,
|
|
5
|
-
* replays, co-host guest) driven by one `companyId` brand-id config, plus
|
|
6
|
-
*
|
|
5
|
+
* replays, co-host guest) driven by one `companyId` brand-id config, plus a native Zego engine kept
|
|
6
|
+
* behind a platform boundary and the React helpers — providers, hooks and `LiveVideoTarget` — all of
|
|
7
|
+
* which ship from this one entry.
|
|
7
8
|
*
|
|
8
9
|
* ```ts
|
|
9
10
|
* import { liveSelling } from '@tiledev/sdk-apptile-live-selling';
|
|
@@ -28,4 +29,18 @@ export { livePip, isLivePipSupported } from './pip';
|
|
|
28
29
|
export { COMMENT_SOURCES } from './types';
|
|
29
30
|
export type * from './types';
|
|
30
31
|
export type * from './sessionTypes';
|
|
32
|
+
/**
|
|
33
|
+
* The React layer — providers, hooks and `LiveVideoTarget`.
|
|
34
|
+
*
|
|
35
|
+
* Exported from here rather than a `./react` subpath: a subpath is reachable only through the
|
|
36
|
+
* package's `exports` map, which a consumer resolving the old way (node10, a bundler or test runner
|
|
37
|
+
* that ignores `exports`) cannot see at all, and one entry every resolver agrees on beats two.
|
|
38
|
+
*
|
|
39
|
+
* It costs this entry its purity — `react` and `react-native` are now loaded with it, so it is no
|
|
40
|
+
* longer importable from a plain Node runtime (react-native ships Flow source). Anything that needs
|
|
41
|
+
* the data layer alone (a replay reducer, a test of `sessionReducer`) imports the module it lives in
|
|
42
|
+
* instead: `@tiledev/sdk-apptile-live-selling/session`, `/streams`, `/polls`, which the package's
|
|
43
|
+
* wildcard subpath serves straight out of `dist`.
|
|
44
|
+
*/
|
|
45
|
+
export * from './react/index';
|
|
31
46
|
//# sourceMappingURL=index.d.ts.map
|
package/dist/index.d.ts.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":"AAAA
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;GAeG;AAGH,OAAO,EAAE,WAAW,EAAE,WAAW,IAAI,OAAO,EAAE,MAAM,eAAe,CAAC;AAGpE,OAAO,EAAE,MAAM,IAAI,UAAU,EAAE,MAAM,UAAU,CAAC;AAGhD,OAAO,EAAE,gBAAgB,EAAE,YAAY,EAAE,MAAM,UAAU,CAAC;AAG1D,OAAO,EACL,YAAY,EACZ,aAAa,EACb,mBAAmB,EACnB,cAAc,EACd,iBAAiB,GAClB,MAAM,WAAW,CAAC;AACnB,OAAO,EAAE,UAAU,EAAE,iBAAiB,EAAE,iBAAiB,EAAE,MAAM,SAAS,CAAC;AAC3E,OAAO,EAAE,aAAa,EAAE,MAAM,SAAS,CAAC;AACxC,OAAO,EAAE,sBAAsB,EAAE,MAAM,SAAS,CAAC;AACjD,OAAO,EAAE,eAAe,EAAE,MAAM,UAAU,CAAC;AAC3C,OAAO,EACL,iBAAiB,EACjB,cAAc,EACd,mBAAmB,EACnB,YAAY,EACZ,WAAW,EACX,KAAK,WAAW,EAChB,KAAK,cAAc,GACpB,MAAM,gBAAgB,CAAC;AAGxB,OAAO,EACL,cAAc,EACd,mBAAmB,EACnB,YAAY,EACZ,WAAW,EACX,UAAU,EACV,YAAY,EACZ,WAAW,GACZ,MAAM,WAAW,CAAC;AACnB,OAAO,EACL,eAAe,EACf,iBAAiB,EACjB,oBAAoB,EACpB,mBAAmB,EACnB,YAAY,EACZ,aAAa,GACd,MAAM,gBAAgB,CAAC;AAGxB,OAAO,EAAE,OAAO,EAAE,kBAAkB,EAAE,MAAM,OAAO,CAAC;AAGpD,OAAO,EAAE,eAAe,EAAE,MAAM,SAAS,CAAC;AAC1C,mBAAmB,SAAS,CAAC;AAC7B,mBAAmB,gBAAgB,CAAC;AAEpC;;;;;;;;;;;;GAYG;AACH,cAAc,eAAe,CAAC"}
|
package/dist/index.js
CHANGED
|
@@ -3,8 +3,9 @@
|
|
|
3
3
|
* `@tiledev/sdk-apptile-live-selling` — the live-selling integration as a standalone package.
|
|
4
4
|
*
|
|
5
5
|
* A typed, imperative client for the Apptile live-selling gateway (streams, auctions, polls, clips,
|
|
6
|
-
* replays, co-host guest) driven by one `companyId` brand-id config, plus
|
|
7
|
-
*
|
|
6
|
+
* replays, co-host guest) driven by one `companyId` brand-id config, plus a native Zego engine kept
|
|
7
|
+
* behind a platform boundary and the React helpers — providers, hooks and `LiveVideoTarget` — all of
|
|
8
|
+
* which ship from this one entry.
|
|
8
9
|
*
|
|
9
10
|
* ```ts
|
|
10
11
|
* import { liveSelling } from '@tiledev/sdk-apptile-live-selling';
|
|
@@ -14,6 +15,20 @@
|
|
|
14
15
|
* const { replays } = await liveSelling.replays.list();
|
|
15
16
|
* ```
|
|
16
17
|
*/
|
|
18
|
+
var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {
|
|
19
|
+
if (k2 === undefined) k2 = k;
|
|
20
|
+
var desc = Object.getOwnPropertyDescriptor(m, k);
|
|
21
|
+
if (!desc || ("get" in desc ? !m.__esModule : desc.writable || desc.configurable)) {
|
|
22
|
+
desc = { enumerable: true, get: function() { return m[k]; } };
|
|
23
|
+
}
|
|
24
|
+
Object.defineProperty(o, k2, desc);
|
|
25
|
+
}) : (function(o, m, k, k2) {
|
|
26
|
+
if (k2 === undefined) k2 = k;
|
|
27
|
+
o[k2] = m[k];
|
|
28
|
+
}));
|
|
29
|
+
var __exportStar = (this && this.__exportStar) || function(m, exports) {
|
|
30
|
+
for (var p in m) if (p !== "default" && !Object.prototype.hasOwnProperty.call(exports, p)) __createBinding(exports, m, p);
|
|
31
|
+
};
|
|
17
32
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
18
33
|
exports.COMMENT_SOURCES = exports.isLivePipSupported = exports.livePip = exports.IDLE_GIVEAWAY = exports.IDLE_AUCTION = exports.REPLAY_CAPABILITIES = exports.AUCTION_CAPABILITIES = exports.LIVE_CAPABILITIES = exports.capabilitiesFor = exports.REACTION_MS = exports.SOLD_CARD_MS = exports.timeLeftMs = exports.remainingMs = exports.deriveStatus = exports.initialSessionState = exports.sessionReducer = exports.displayHost = exports.toUrlPreview = exports.classifyCommentLink = exports.hasCommentLink = exports.toCommentSegments = exports.MAX_VIEWER_NAME = exports.resetCompanyFlagsCache = exports.toMixerLayout = exports.toEmbeddedResults = exports.toLivePollResults = exports.toLivePoll = exports.toGiveawayEntries = exports.toLiveGiveaway = exports.toLiveStreamProduct = exports.toLiveStreams = exports.toLiveStream = exports.toProductGid = exports.LiveSellingError = exports.liveEngine = exports.default = exports.liveSelling = void 0;
|
|
19
34
|
// The imperative client (default + named).
|
|
@@ -67,14 +82,24 @@ Object.defineProperty(exports, "REPLAY_CAPABILITIES", { enumerable: true, get: f
|
|
|
67
82
|
Object.defineProperty(exports, "IDLE_AUCTION", { enumerable: true, get: function () { return sessionTypes_1.IDLE_AUCTION; } });
|
|
68
83
|
Object.defineProperty(exports, "IDLE_GIVEAWAY", { enumerable: true, get: function () { return sessionTypes_1.IDLE_GIVEAWAY; } });
|
|
69
84
|
// Picture-in-picture, for a host that drives the window itself. No-op off-device.
|
|
70
|
-
//
|
|
71
|
-
// `nativeViewTag` is deliberately NOT re-exported here: it imports react-native, and this entry has to
|
|
72
|
-
// stay loadable in a plain JavaScript runtime (Node, SSR, a test) the way the rest of the data layer is.
|
|
73
|
-
// It ships from `/react` instead.
|
|
74
85
|
var pip_1 = require("./pip");
|
|
75
86
|
Object.defineProperty(exports, "livePip", { enumerable: true, get: function () { return pip_1.livePip; } });
|
|
76
87
|
Object.defineProperty(exports, "isLivePipSupported", { enumerable: true, get: function () { return pip_1.isLivePipSupported; } });
|
|
77
88
|
// The whole public type surface.
|
|
78
89
|
var types_1 = require("./types");
|
|
79
90
|
Object.defineProperty(exports, "COMMENT_SOURCES", { enumerable: true, get: function () { return types_1.COMMENT_SOURCES; } });
|
|
91
|
+
/**
|
|
92
|
+
* The React layer — providers, hooks and `LiveVideoTarget`.
|
|
93
|
+
*
|
|
94
|
+
* Exported from here rather than a `./react` subpath: a subpath is reachable only through the
|
|
95
|
+
* package's `exports` map, which a consumer resolving the old way (node10, a bundler or test runner
|
|
96
|
+
* that ignores `exports`) cannot see at all, and one entry every resolver agrees on beats two.
|
|
97
|
+
*
|
|
98
|
+
* It costs this entry its purity — `react` and `react-native` are now loaded with it, so it is no
|
|
99
|
+
* longer importable from a plain Node runtime (react-native ships Flow source). Anything that needs
|
|
100
|
+
* the data layer alone (a replay reducer, a test of `sessionReducer`) imports the module it lives in
|
|
101
|
+
* instead: `@tiledev/sdk-apptile-live-selling/session`, `/streams`, `/polls`, which the package's
|
|
102
|
+
* wildcard subpath serves straight out of `dist`.
|
|
103
|
+
*/
|
|
104
|
+
__exportStar(require("./react/index"), exports);
|
|
80
105
|
//# sourceMappingURL=index.js.map
|
package/dist/index.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.js","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":";AAAA
|
|
1
|
+
{"version":3,"file":"index.js","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":";AAAA;;;;;;;;;;;;;;;GAeG;;;;;;;;;;;;;;;;;AAEH,2CAA2C;AAC3C,6CAAoE;AAA3D,0GAAA,WAAW,OAAA;AAAE,sGAAA,WAAW,OAAW;AAE5C,0EAA0E;AAC1E,mCAAgD;AAAvC,oGAAA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react-native';
|
|
2
|
+
import type { ViewProps } from 'react-native';
|
|
3
|
+
import type { LiveSession } from '../sessionTypes';
|
|
4
|
+
import type { AuctionBidGate, UseAuctionBidGateOptions } from './useAuctionBidGate';
|
|
5
|
+
import type { UseAuctionWinsOptions, UseAuctionWinsState } from './useAuctionWins';
|
|
6
|
+
import type { LiveSessionProviderProps } from './useLiveSession';
|
|
7
|
+
import type { LiveVideoTargetProps } from './LiveVideoTarget';
|
|
8
|
+
export { LiveSellingProvider, useLiveSelling, type LiveSellingProviderProps, type LiveSellingContextType, } from './LiveSellingProvider';
|
|
9
|
+
export { useOngoingLive, type UseOngoingLiveOptions, type UseOngoingLiveState } from './useOngoingLive';
|
|
10
|
+
export { useLiveStreams, type UseLiveStreamsState } from './useLiveStreams';
|
|
11
|
+
export { useAuction, type UseAuctionState } from './useAuction';
|
|
12
|
+
export { useReplays, type UseReplaysOptions, type UseReplaysState } from './useReplays';
|
|
13
|
+
export { useClips, type UseClipsState } from './useClips';
|
|
14
|
+
export { useStreamInfo, refreshStreamRecords, refreshStreamRecordsIfStale, } from './useStreamInfo';
|
|
15
|
+
export { nativeViewTag } from '../nativeViewTag';
|
|
16
|
+
export type { AuctionBidGate, BidBlocker } from './useAuctionBidGate';
|
|
17
|
+
export type { AuctionWinRow, UseAuctionWinsOptions, UseAuctionWinsState } from './useAuctionWins';
|
|
18
|
+
export type { LiveSessionProviderProps } from './useLiveSession';
|
|
19
|
+
export type { LiveVideoTargetProps } from './LiveVideoTarget';
|
|
20
|
+
export declare function LiveSessionProvider({ children }: LiveSessionProviderProps): import("react").FunctionComponentElement<import("react").ProviderProps<LiveSession | null>>;
|
|
21
|
+
/**
|
|
22
|
+
* The idle session, read without touching the context: a surface rendered outside the provider
|
|
23
|
+
* behaves the same as one inside it, because on the web there is only ever this one session.
|
|
24
|
+
*/
|
|
25
|
+
export declare function useLiveSession<TRaw = unknown>(): LiveSession<TRaw>;
|
|
26
|
+
export declare const isNativeVideoSupported = false;
|
|
27
|
+
/**
|
|
28
|
+
* A plain `View`, which is what the native file falls back to on a build without the Zego SDK:
|
|
29
|
+
* callers position this and draw a poster over it, so returning null would collapse the layout the
|
|
30
|
+
* poster depends on.
|
|
31
|
+
*/
|
|
32
|
+
export declare const NativeVideoView: import("react").ForwardRefExoticComponent<ViewProps & import("react").RefAttributes<unknown>>;
|
|
33
|
+
export declare function LiveVideoTarget({ style, children }: LiveVideoTargetProps): import("react").CElement<ViewProps, View>;
|
|
34
|
+
export declare const SHEET_HANDOFF_MS = 380;
|
|
35
|
+
/** Never blocks, because there is no bid to gate — `placeBid` above resolves without sending. */
|
|
36
|
+
export declare function useAuctionBidGate(_options: UseAuctionBidGateOptions): AuctionBidGate;
|
|
37
|
+
/**
|
|
38
|
+
* An empty tab rather than a failure. The wins metafield is readable from a browser, but settling one
|
|
39
|
+
* mints a cart and sends the shopper to checkout — not something a preview should be able to start.
|
|
40
|
+
*/
|
|
41
|
+
export declare function useAuctionWins<TRaw = unknown>(_options?: UseAuctionWinsOptions): UseAuctionWinsState<TRaw>;
|
|
42
|
+
//# sourceMappingURL=index.web.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"index.web.d.ts","sourceRoot":"","sources":["../../src/react/index.web.ts"],"names":[],"mappings":"AAyBA,OAAO,EAAE,IAAI,EAAE,MAAM,cAAc,CAAC;AAEpC,OAAO,KAAK,EAAE,SAAS,EAAE,MAAM,cAAc,CAAC;AAG9C,OAAO,KAAK,EAAE,WAAW,EAAsB,MAAM,iBAAiB,CAAC;AACvE,OAAO,KAAK,EAAE,cAAc,EAAE,wBAAwB,EAAE,MAAM,qBAAqB,CAAC;AACpF,OAAO,KAAK,EAAiB,qBAAqB,EAAE,mBAAmB,EAAE,MAAM,kBAAkB,CAAC;AAClG,OAAO,KAAK,EAAE,wBAAwB,EAAE,MAAM,kBAAkB,CAAC;AACjE,OAAO,KAAK,EAAE,oBAAoB,EAAE,MAAM,mBAAmB,CAAC;AAG9D,OAA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AAC;AAEpC,iGAAiG;AACjG,wBAAgB,iBAAiB,CAAC,QAAQ,EAAE,wBAAwB,GAAG,cAAc,CAapF;AAED;;;GAGG;AACH,wBAAgB,cAAc,CAAC,IAAI,GAAG,OAAO,EAC3C,QAAQ,CAAC,EAAE,qBAAqB,GAC/B,mBAAmB,CAAC,IAAI,CAAC,CAc3B"}
|
|
@@ -0,0 +1,167 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.SHEET_HANDOFF_MS = exports.NativeVideoView = exports.isNativeVideoSupported = exports.nativeViewTag = exports.refreshStreamRecordsIfStale = exports.refreshStreamRecords = exports.useStreamInfo = exports.useClips = exports.useReplays = exports.useAuction = exports.useLiveStreams = exports.useOngoingLive = exports.useLiveSelling = exports.LiveSellingProvider = void 0;
|
|
4
|
+
exports.LiveSessionProvider = LiveSessionProvider;
|
|
5
|
+
exports.useLiveSession = useLiveSession;
|
|
6
|
+
exports.LiveVideoTarget = LiveVideoTarget;
|
|
7
|
+
exports.useAuctionBidGate = useAuctionBidGate;
|
|
8
|
+
exports.useAuctionWins = useAuctionWins;
|
|
9
|
+
/**
|
|
10
|
+
* The React layer on the **web** — real where a browser can honestly do the work, inert where it
|
|
11
|
+
* cannot. Metro resolves this file in place of `./index` for web, and TypeScript reads the native
|
|
12
|
+
* one, so the two surfaces are kept identical by the compiler.
|
|
13
|
+
*
|
|
14
|
+
* Two separate reasons this file exists, and only the first is about behaviour:
|
|
15
|
+
*
|
|
16
|
+
* 1. **Nothing here may reach the Zego module.** `LiveVideoTarget` requires
|
|
17
|
+
* `zego-express-engine-reactnative` for its texture view on native. A bundler collects that
|
|
18
|
+
* `require` whichever branch would run it, so a web bundle built where the SDK is not installed
|
|
19
|
+
* fails to resolve it at build time — before a line of this runs. Serving the stand-ins below
|
|
20
|
+
* keeps the native entry out of a web graph entirely.
|
|
21
|
+
* 2. **There is no room to join.** Video is Zego, the package ships a documented no-op engine off
|
|
22
|
+
* device, so a session here is a permanently idle one rather than a fabricated live show.
|
|
23
|
+
*
|
|
24
|
+
* `status: 'ended'` is the deliberate choice for that idle session. Every surface already draws a
|
|
25
|
+
* finished stream as an empty state; `loading` spins for ever, and `error` puts a failure in front of
|
|
26
|
+
* a shopper for a feature the browser was never going to run.
|
|
27
|
+
*
|
|
28
|
+
* The **client** is real: `liveSelling` and its HTTP calls work from a browser, so `useLiveSelling()`,
|
|
29
|
+
* the stream/replay/clip read hooks and the polled record all behave as they do on device.
|
|
30
|
+
*
|
|
31
|
+
* `createElement` rather than JSX, like the rest of the package, so this stays a plain `.ts`.
|
|
32
|
+
*/
|
|
33
|
+
const react_1 = require("react");
|
|
34
|
+
const react_native_1 = require("react-native");
|
|
35
|
+
const sessionTypes_1 = require("../sessionTypes");
|
|
36
|
+
// Real on the web: the gateway is plain HTTP, and the engine it configures is the no-op build.
|
|
37
|
+
var LiveSellingProvider_1 = require("./LiveSellingProvider");
|
|
38
|
+
Object.defineProperty(exports, "LiveSellingProvider", { enumerable: true, get: function () { return LiveSellingProvider_1.LiveSellingProvider; } });
|
|
39
|
+
Object.defineProperty(exports, "useLiveSelling", { enumerable: true, get: function () { return LiveSellingProvider_1.useLiveSelling; } });
|
|
40
|
+
var useOngoingLive_1 = require("./useOngoingLive");
|
|
41
|
+
Object.defineProperty(exports, "useOngoingLive", { enumerable: true, get: function () { return useOngoingLive_1.useOngoingLive; } });
|
|
42
|
+
var useLiveStreams_1 = require("./useLiveStreams");
|
|
43
|
+
Object.defineProperty(exports, "useLiveStreams", { enumerable: true, get: function () { return useLiveStreams_1.useLiveStreams; } });
|
|
44
|
+
var useAuction_1 = require("./useAuction");
|
|
45
|
+
Object.defineProperty(exports, "useAuction", { enumerable: true, get: function () { return useAuction_1.useAuction; } });
|
|
46
|
+
var useReplays_1 = require("./useReplays");
|
|
47
|
+
Object.defineProperty(exports, "useReplays", { enumerable: true, get: function () { return useReplays_1.useReplays; } });
|
|
48
|
+
var useClips_1 = require("./useClips");
|
|
49
|
+
Object.defineProperty(exports, "useClips", { enumerable: true, get: function () { return useClips_1.useClips; } });
|
|
50
|
+
var useStreamInfo_1 = require("./useStreamInfo");
|
|
51
|
+
Object.defineProperty(exports, "useStreamInfo", { enumerable: true, get: function () { return useStreamInfo_1.useStreamInfo; } });
|
|
52
|
+
Object.defineProperty(exports, "refreshStreamRecords", { enumerable: true, get: function () { return useStreamInfo_1.refreshStreamRecords; } });
|
|
53
|
+
Object.defineProperty(exports, "refreshStreamRecordsIfStale", { enumerable: true, get: function () { return useStreamInfo_1.refreshStreamRecordsIfStale; } });
|
|
54
|
+
// Already returns null off device — react-native-web *throws* from `findNodeHandle`, which this
|
|
55
|
+
// wraps, so the honest answer costs nothing here.
|
|
56
|
+
var nativeViewTag_1 = require("../nativeViewTag");
|
|
57
|
+
Object.defineProperty(exports, "nativeViewTag", { enumerable: true, get: function () { return nativeViewTag_1.nativeViewTag; } });
|
|
58
|
+
// ─── The session ─────────────────────────────────────────────────────────────
|
|
59
|
+
/** Every action, resolved and doing nothing. There is no room to send any of it to. */
|
|
60
|
+
const IDLE_ACTIONS = {
|
|
61
|
+
bindVideoView: () => undefined,
|
|
62
|
+
sendComment: async () => undefined,
|
|
63
|
+
sendReaction: async () => undefined,
|
|
64
|
+
announceAddToCart: async () => undefined,
|
|
65
|
+
voteInPoll: async () => undefined,
|
|
66
|
+
chooseViewerName: async () => null,
|
|
67
|
+
addToCart: async () => false,
|
|
68
|
+
joinAsGuest: () => Promise.reject(new Error('Co-hosting needs a device build.')),
|
|
69
|
+
leaveGuest: async () => undefined,
|
|
70
|
+
setGuestMicMuted: async () => undefined,
|
|
71
|
+
setGuestCameraOff: async () => undefined,
|
|
72
|
+
flipGuestCamera: async () => undefined,
|
|
73
|
+
bindGuestPreview: () => undefined,
|
|
74
|
+
bindGuestHostView: () => undefined,
|
|
75
|
+
setMuted: () => undefined,
|
|
76
|
+
enterPip: () => undefined,
|
|
77
|
+
exitPip: () => undefined,
|
|
78
|
+
placeBid: async () => undefined,
|
|
79
|
+
enterGiveaway: async () => undefined,
|
|
80
|
+
dismissAuctionWin: () => undefined,
|
|
81
|
+
dismissGiveawayResult: () => undefined,
|
|
82
|
+
};
|
|
83
|
+
/** A stream that is over: the one state every surface already knows how to draw. */
|
|
84
|
+
const IDLE_SESSION = {
|
|
85
|
+
status: 'ended',
|
|
86
|
+
stream: null,
|
|
87
|
+
viewerCount: 0,
|
|
88
|
+
rawViewerCount: 0,
|
|
89
|
+
comments: [],
|
|
90
|
+
activeProduct: null,
|
|
91
|
+
products: [],
|
|
92
|
+
sold: [],
|
|
93
|
+
reactions: [],
|
|
94
|
+
poll: null,
|
|
95
|
+
muted: true,
|
|
96
|
+
videoTag: null,
|
|
97
|
+
elapsedMs: 0,
|
|
98
|
+
pipMode: 'none',
|
|
99
|
+
guest: {
|
|
100
|
+
mode: false,
|
|
101
|
+
status: 'idle',
|
|
102
|
+
slot: null,
|
|
103
|
+
mutedByHost: false,
|
|
104
|
+
cameraOffByHost: false,
|
|
105
|
+
mixerLayout: null,
|
|
106
|
+
},
|
|
107
|
+
viewerName: null,
|
|
108
|
+
auction: sessionTypes_1.IDLE_AUCTION,
|
|
109
|
+
giveaway: sessionTypes_1.IDLE_GIVEAWAY,
|
|
110
|
+
error: null,
|
|
111
|
+
actions: IDLE_ACTIONS,
|
|
112
|
+
};
|
|
113
|
+
const LiveSessionContext = (0, react_1.createContext)(null);
|
|
114
|
+
function LiveSessionProvider({ children }) {
|
|
115
|
+
return (0, react_1.createElement)(LiveSessionContext.Provider, { value: IDLE_SESSION }, children);
|
|
116
|
+
}
|
|
117
|
+
/**
|
|
118
|
+
* The idle session, read without touching the context: a surface rendered outside the provider
|
|
119
|
+
* behaves the same as one inside it, because on the web there is only ever this one session.
|
|
120
|
+
*/
|
|
121
|
+
function useLiveSession() {
|
|
122
|
+
return IDLE_SESSION;
|
|
123
|
+
}
|
|
124
|
+
// ─── The video ───────────────────────────────────────────────────────────────
|
|
125
|
+
exports.isNativeVideoSupported = false;
|
|
126
|
+
/**
|
|
127
|
+
* A plain `View`, which is what the native file falls back to on a build without the Zego SDK:
|
|
128
|
+
* callers position this and draw a poster over it, so returning null would collapse the layout the
|
|
129
|
+
* poster depends on.
|
|
130
|
+
*/
|
|
131
|
+
exports.NativeVideoView = (0, react_1.forwardRef)(function NativeVideoView(props, _ref) {
|
|
132
|
+
return (0, react_1.createElement)(react_native_1.View, props);
|
|
133
|
+
});
|
|
134
|
+
function LiveVideoTarget({ style, children }) {
|
|
135
|
+
return (0, react_1.createElement)(react_native_1.View, { style: style !== null && style !== void 0 ? style : { flex: 1 } }, children);
|
|
136
|
+
}
|
|
137
|
+
// ─── Auctions ────────────────────────────────────────────────────────────────
|
|
138
|
+
exports.SHEET_HANDOFF_MS = 380;
|
|
139
|
+
/** Never blocks, because there is no bid to gate — `placeBid` above resolves without sending. */
|
|
140
|
+
function useAuctionBidGate(_options) {
|
|
141
|
+
return (0, react_1.useMemo)(() => ({
|
|
142
|
+
blocker: null,
|
|
143
|
+
variantId: null,
|
|
144
|
+
requestBid: () => undefined,
|
|
145
|
+
acceptTerms: () => undefined,
|
|
146
|
+
chooseVariant: () => undefined,
|
|
147
|
+
dismiss: () => undefined,
|
|
148
|
+
refreshUnpaidWins: () => undefined,
|
|
149
|
+
}), []);
|
|
150
|
+
}
|
|
151
|
+
/**
|
|
152
|
+
* An empty tab rather than a failure. The wins metafield is readable from a browser, but settling one
|
|
153
|
+
* mints a cart and sends the shopper to checkout — not something a preview should be able to start.
|
|
154
|
+
*/
|
|
155
|
+
function useAuctionWins(_options) {
|
|
156
|
+
return (0, react_1.useMemo)(() => ({
|
|
157
|
+
rows: [],
|
|
158
|
+
totalBids: 0,
|
|
159
|
+
streamingId: null,
|
|
160
|
+
loading: false,
|
|
161
|
+
checkingOut: false,
|
|
162
|
+
error: null,
|
|
163
|
+
refresh: () => undefined,
|
|
164
|
+
checkout: async () => null,
|
|
165
|
+
}), []);
|
|
166
|
+
}
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AE,GAAG,EAAE,CAAC,SAAS;KACnC,CAAC,EACF,EAAE,CACH,CAAC;AACJ,CAAC;AAED;;;GAGG;AACH,SAAgB,cAAc,CAC5B,QAAgC;IAEhC,OAAO,IAAA,eAAO,EACZ,GAAG,EAAE,CAAC,CAAC;QACL,IAAI,EAAE,EAA2B;QACjC,SAAS,EAAE,CAAC;QACZ,WAAW,EAAE,IAAI;QACjB,OAAO,EAAE,KAAK;QACd,WAAW,EAAE,KAAK;QAClB,KAAK,EAAE,IAAI;QACX,OAAO,EAAE,GAAG,EAAE,CAAC,SAAS;QACxB,QAAQ,EAAE,KAAK,IAAI,EAAE,CAAC,IAAI;KAC3B,CAAC,EACF,EAAE,CACH,CAAC;AACJ,CAAC"}
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@tiledev/sdk-apptile-live-selling",
|
|
3
|
-
"version": "0.1
|
|
3
|
+
"version": "0.2.1",
|
|
4
4
|
"description": "Live selling, auctions and giveaways for React Native \u2014 the Apptile live-selling gateway as a typed singleton, a Zego room engine behind a platform boundary, an assembled session state machine, and system picture-in-picture with its own config plugin. Commerce comes from an adapter.",
|
|
5
5
|
"license": "UNLICENSED",
|
|
6
6
|
"private": false,
|
|
@@ -13,21 +13,22 @@
|
|
|
13
13
|
"types": "./dist/index.d.ts",
|
|
14
14
|
"default": "./dist/index.js"
|
|
15
15
|
},
|
|
16
|
-
"./react": {
|
|
17
|
-
"types": "./dist/react/index.d.ts",
|
|
18
|
-
"default": "./dist/react/index.js"
|
|
19
|
-
},
|
|
20
16
|
"./types": {
|
|
21
17
|
"types": "./dist/types.d.ts",
|
|
22
18
|
"default": "./dist/types.js"
|
|
23
19
|
},
|
|
24
20
|
"./app.plugin.js": "./app.plugin.js",
|
|
25
21
|
"./expo-module.config.json": "./expo-module.config.json",
|
|
26
|
-
"./package.json": "./package.json"
|
|
22
|
+
"./package.json": "./package.json",
|
|
23
|
+
"./*": {
|
|
24
|
+
"types": "./dist/*.d.ts",
|
|
25
|
+
"default": "./dist/*.js"
|
|
26
|
+
}
|
|
27
27
|
},
|
|
28
28
|
"files": [
|
|
29
29
|
"dist",
|
|
30
|
-
"
|
|
30
|
+
"types",
|
|
31
|
+
"session",
|
|
31
32
|
"ios",
|
|
32
33
|
"android",
|
|
33
34
|
"!android/build",
|
|
@@ -70,12 +71,6 @@
|
|
|
70
71
|
"expo": {
|
|
71
72
|
"optional": true
|
|
72
73
|
},
|
|
73
|
-
"react": {
|
|
74
|
-
"optional": true
|
|
75
|
-
},
|
|
76
|
-
"react-native": {
|
|
77
|
-
"optional": true
|
|
78
|
-
},
|
|
79
74
|
"zego-express-engine-reactnative": {
|
|
80
75
|
"optional": true
|
|
81
76
|
}
|