@tiledev/sdk-apptile-live-selling 0.16.0 → 0.16.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/dist/attribution.d.ts +2 -16
- package/dist/attribution.d.ts.map +1 -1
- package/dist/attribution.js +4 -10
- package/dist/attribution.js.map +1 -1
- package/dist/auctions.d.ts.map +1 -1
- package/dist/auctions.js +11 -42
- package/dist/auctions.js.map +1 -1
- package/dist/cartAttributes.d.ts +0 -10
- package/dist/cartAttributes.d.ts.map +1 -1
- package/dist/cartAttributes.js +1 -20
- package/dist/cartAttributes.js.map +1 -1
- package/dist/client.d.ts +2 -51
- package/dist/client.d.ts.map +1 -1
- package/dist/client.js +23 -123
- package/dist/client.js.map +1 -1
- package/dist/clips.d.ts +1 -12
- package/dist/clips.d.ts.map +1 -1
- package/dist/clips.js +6 -114
- package/dist/clips.js.map +1 -1
- package/dist/commentLinks.d.ts +0 -29
- package/dist/commentLinks.d.ts.map +1 -1
- package/dist/commentLinks.js.map +1 -1
- package/dist/engine.native.d.ts.map +1 -1
- package/dist/engine.native.js +845 -17
- package/dist/engine.native.js.map +1 -1
- package/dist/index.d.ts +4 -48
- package/dist/index.d.ts.map +1 -1
- package/dist/index.js +3 -240
- package/dist/index.js.map +1 -1
- package/dist/polls.d.ts.map +1 -1
- package/dist/polls.js +0 -3
- package/dist/polls.js.map +1 -1
- package/dist/react/LiveSellingProvider.d.ts +1 -54
- package/dist/react/LiveSellingProvider.d.ts.map +1 -1
- package/dist/react/LiveSellingProvider.js +3 -60
- package/dist/react/LiveSellingProvider.js.map +1 -1
- package/dist/react/LiveVideoTarget.d.ts.map +1 -1
- package/dist/react/LiveVideoTarget.js +3 -41
- package/dist/react/LiveVideoTarget.js.map +1 -1
- package/dist/react/index.d.ts +3 -30
- package/dist/react/index.d.ts.map +1 -1
- package/dist/react/index.js +1 -79
- package/dist/react/index.js.map +1 -1
- package/dist/react/index.web.d.ts +32 -36
- package/dist/react/index.web.d.ts.map +1 -1
- package/dist/react/index.web.js +122 -102
- package/dist/react/index.web.js.map +1 -1
- package/dist/react/useAuctionBidGate.d.ts +6 -62
- package/dist/react/useAuctionBidGate.d.ts.map +1 -1
- package/dist/react/useAuctionBidGate.js +27 -228
- package/dist/react/useAuctionBidGate.js.map +1 -1
- package/dist/react/useAuctionWins.d.ts +4 -14
- package/dist/react/useAuctionWins.d.ts.map +1 -1
- package/dist/react/useAuctionWins.js +5 -16
- package/dist/react/useAuctionWins.js.map +1 -1
- package/dist/react/useClips.d.ts +1 -7
- package/dist/react/useClips.d.ts.map +1 -1
- package/dist/react/useClips.js +7 -20
- package/dist/react/useClips.js.map +1 -1
- package/dist/react/useLiveSession.d.ts +3 -15
- package/dist/react/useLiveSession.d.ts.map +1 -1
- package/dist/react/useLiveSession.js +199 -612
- package/dist/react/useLiveSession.js.map +1 -1
- package/dist/react/useLiveStreams.d.ts.map +1 -1
- package/dist/react/useLiveStreams.js +2 -6
- package/dist/react/useLiveStreams.js.map +1 -1
- package/dist/react/useOngoingLive.d.ts +0 -1
- package/dist/react/useOngoingLive.d.ts.map +1 -1
- package/dist/react/useOngoingLive.js +1 -7
- package/dist/react/useOngoingLive.js.map +1 -1
- package/dist/react/useReplays.d.ts +0 -12
- package/dist/react/useReplays.d.ts.map +1 -1
- package/dist/react/useReplays.js +24 -56
- package/dist/react/useReplays.js.map +1 -1
- package/dist/react/useStreamInfo.d.ts +2 -13
- package/dist/react/useStreamInfo.d.ts.map +1 -1
- package/dist/react/useStreamInfo.js +8 -36
- package/dist/react/useStreamInfo.js.map +1 -1
- package/dist/replays.d.ts +0 -14
- package/dist/replays.d.ts.map +1 -1
- package/dist/replays.js +22 -68
- package/dist/replays.js.map +1 -1
- package/dist/session.d.ts +6 -39
- package/dist/session.d.ts.map +1 -1
- package/dist/session.js +22 -209
- package/dist/session.js.map +1 -1
- package/dist/sessionTypes.d.ts +18 -217
- package/dist/sessionTypes.d.ts.map +1 -1
- package/dist/sessionTypes.js +1 -2
- package/dist/sessionTypes.js.map +1 -1
- package/dist/streams.d.ts +1 -27
- package/dist/streams.d.ts.map +1 -1
- package/dist/streams.js +21 -84
- package/dist/streams.js.map +1 -1
- package/dist/types.d.ts +10 -288
- package/dist/types.d.ts.map +1 -1
- package/dist/types.js +1 -2
- package/dist/types.js.map +1 -1
- package/dist/wire.d.ts +0 -31
- package/dist/wire.d.ts.map +1 -1
- package/dist/wire.js +0 -25
- package/dist/wire.js.map +1 -1
- package/dist/zego.d.ts +1 -3
- package/dist/zego.d.ts.map +1 -1
- package/dist/zego.js +1 -1
- package/package.json +1 -1
- package/dist/auctionComments.d.ts +0 -25
- package/dist/auctionComments.d.ts.map +0 -1
- package/dist/auctionComments.js +0 -28
- package/dist/auctionComments.js.map +0 -1
- package/dist/auctionRules.d.ts +0 -77
- package/dist/auctionRules.d.ts.map +0 -1
- package/dist/auctionRules.js +0 -107
- package/dist/auctionRules.js.map +0 -1
- package/dist/cartExtension.d.ts +0 -39
- package/dist/cartExtension.d.ts.map +0 -1
- package/dist/cartExtension.js +0 -51
- package/dist/cartExtension.js.map +0 -1
- package/dist/checkoutRefused.d.ts +0 -9
- package/dist/checkoutRefused.d.ts.map +0 -1
- package/dist/checkoutRefused.js +0 -16
- package/dist/checkoutRefused.js.map +0 -1
- package/dist/clipsPage.d.ts +0 -29
- package/dist/clipsPage.d.ts.map +0 -1
- package/dist/clipsPage.js +0 -49
- package/dist/clipsPage.js.map +0 -1
- package/dist/commentHistory.d.ts +0 -70
- package/dist/commentHistory.d.ts.map +0 -1
- package/dist/commentHistory.js +0 -133
- package/dist/commentHistory.js.map +0 -1
- package/dist/commentLinkCards.d.ts +0 -11
- package/dist/commentLinkCards.d.ts.map +0 -1
- package/dist/commentLinkCards.js +0 -70
- package/dist/commentLinkCards.js.map +0 -1
- package/dist/giveawayPrize.d.ts +0 -13
- package/dist/giveawayPrize.d.ts.map +0 -1
- package/dist/giveawayPrize.js +0 -18
- package/dist/giveawayPrize.js.map +0 -1
- package/dist/giveawayPrizeLines.d.ts +0 -120
- package/dist/giveawayPrizeLines.d.ts.map +0 -1
- package/dist/giveawayPrizeLines.js +0 -97
- package/dist/giveawayPrizeLines.js.map +0 -1
- package/dist/giveawayPrizes.d.ts +0 -20
- package/dist/giveawayPrizes.d.ts.map +0 -1
- package/dist/giveawayPrizes.js +0 -50
- package/dist/giveawayPrizes.js.map +0 -1
- package/dist/giveawayRoster.d.ts +0 -53
- package/dist/giveawayRoster.d.ts.map +0 -1
- package/dist/giveawayRoster.js +0 -93
- package/dist/giveawayRoster.js.map +0 -1
- package/dist/heldComments.d.ts +0 -40
- package/dist/heldComments.d.ts.map +0 -1
- package/dist/heldComments.js +0 -75
- package/dist/heldComments.js.map +0 -1
- package/dist/hiddenShows.d.ts +0 -44
- package/dist/hiddenShows.d.ts.map +0 -1
- package/dist/hiddenShows.js +0 -53
- package/dist/hiddenShows.js.map +0 -1
- package/dist/linkLots.d.ts +0 -64
- package/dist/linkLots.d.ts.map +0 -1
- package/dist/linkLots.js +0 -84
- package/dist/linkLots.js.map +0 -1
- package/dist/liveHaptics.d.ts +0 -7
- package/dist/liveHaptics.d.ts.map +0 -1
- package/dist/liveHaptics.js +0 -11
- package/dist/liveHaptics.js.map +0 -1
- package/dist/liveHaptics.native.d.ts +0 -7
- package/dist/liveHaptics.native.d.ts.map +0 -1
- package/dist/liveHaptics.native.js +0 -12
- package/dist/liveHaptics.native.js.map +0 -1
- package/dist/livePages.d.ts +0 -176
- package/dist/livePages.d.ts.map +0 -1
- package/dist/livePages.js +0 -216
- package/dist/livePages.js.map +0 -1
- package/dist/liveRoom.d.ts +0 -21
- package/dist/liveRoom.d.ts.map +0 -1
- package/dist/liveRoom.js +0 -28
- package/dist/liveRoom.js.map +0 -1
- package/dist/liveShow.d.ts +0 -65
- package/dist/liveShow.d.ts.map +0 -1
- package/dist/liveShow.js +0 -65
- package/dist/liveShow.js.map +0 -1
- package/dist/missedPolls.d.ts +0 -27
- package/dist/missedPolls.d.ts.map +0 -1
- package/dist/missedPolls.js +0 -16
- package/dist/missedPolls.js.map +0 -1
- package/dist/pageOptions.d.ts +0 -149
- package/dist/pageOptions.d.ts.map +0 -1
- package/dist/pageOptions.js +0 -123
- package/dist/pageOptions.js.map +0 -1
- package/dist/pageTypes.d.ts +0 -185
- package/dist/pageTypes.d.ts.map +0 -1
- package/dist/pageTypes.js +0 -3
- package/dist/pageTypes.js.map +0 -1
- package/dist/phoneTaps.d.ts +0 -25
- package/dist/phoneTaps.d.ts.map +0 -1
- package/dist/phoneTaps.js +0 -47
- package/dist/phoneTaps.js.map +0 -1
- package/dist/pipWindow.d.ts +0 -85
- package/dist/pipWindow.d.ts.map +0 -1
- package/dist/pipWindow.js +0 -88
- package/dist/pipWindow.js.map +0 -1
- package/dist/react/clocks.d.ts +0 -29
- package/dist/react/clocks.d.ts.map +0 -1
- package/dist/react/clocks.js +0 -124
- package/dist/react/clocks.js.map +0 -1
- package/dist/react/navigation.d.ts +0 -13
- package/dist/react/navigation.d.ts.map +0 -1
- package/dist/react/navigation.js +0 -7
- package/dist/react/navigation.js.map +0 -1
- package/dist/react/platformSession.d.ts +0 -16
- package/dist/react/platformSession.d.ts.map +0 -1
- package/dist/react/platformSession.js +0 -28
- package/dist/react/platformSession.js.map +0 -1
- package/dist/react/platformSession.web.d.ts +0 -35
- package/dist/react/platformSession.web.d.ts.map +0 -1
- package/dist/react/platformSession.web.js +0 -148
- package/dist/react/platformSession.web.js.map +0 -1
- package/dist/react/replayPlayer.d.ts +0 -83
- package/dist/react/replayPlayer.d.ts.map +0 -1
- package/dist/react/replayPlayer.js +0 -315
- package/dist/react/replayPlayer.js.map +0 -1
- package/dist/react/share.d.ts +0 -22
- package/dist/react/share.d.ts.map +0 -1
- package/dist/react/share.js +0 -45
- package/dist/react/share.js.map +0 -1
- package/dist/react/shopifyProviders.d.ts +0 -82
- package/dist/react/shopifyProviders.d.ts.map +0 -1
- package/dist/react/shopifyProviders.js +0 -113
- package/dist/react/shopifyProviders.js.map +0 -1
- package/dist/react/showPages.d.ts +0 -106
- package/dist/react/showPages.d.ts.map +0 -1
- package/dist/react/showPages.js +0 -166
- package/dist/react/showPages.js.map +0 -1
- package/dist/react/showPagesOnDevice.d.ts +0 -18
- package/dist/react/showPagesOnDevice.d.ts.map +0 -1
- package/dist/react/showPagesOnDevice.js +0 -31
- package/dist/react/showPagesOnDevice.js.map +0 -1
- package/dist/react/startSignIn.d.ts +0 -3
- package/dist/react/startSignIn.d.ts.map +0 -1
- package/dist/react/startSignIn.js +0 -19
- package/dist/react/startSignIn.js.map +0 -1
- package/dist/react/systemPictureInPicture.d.ts +0 -34
- package/dist/react/systemPictureInPicture.d.ts.map +0 -1
- package/dist/react/systemPictureInPicture.js +0 -93
- package/dist/react/systemPictureInPicture.js.map +0 -1
- package/dist/react/useAccountName.d.ts +0 -8
- package/dist/react/useAccountName.d.ts.map +0 -1
- package/dist/react/useAccountName.js +0 -49
- package/dist/react/useAccountName.js.map +0 -1
- package/dist/react/useClipsPage.d.ts +0 -47
- package/dist/react/useClipsPage.d.ts.map +0 -1
- package/dist/react/useClipsPage.js +0 -130
- package/dist/react/useClipsPage.js.map +0 -1
- package/dist/react/useCommentLinkCards.d.ts +0 -6
- package/dist/react/useCommentLinkCards.d.ts.map +0 -1
- package/dist/react/useCommentLinkCards.js +0 -67
- package/dist/react/useCommentLinkCards.js.map +0 -1
- package/dist/react/useFeaturedClip.d.ts +0 -15
- package/dist/react/useFeaturedClip.d.ts.map +0 -1
- package/dist/react/useFeaturedClip.js +0 -52
- package/dist/react/useFeaturedClip.js.map +0 -1
- package/dist/react/useGiveawayEntry.d.ts +0 -59
- package/dist/react/useGiveawayEntry.d.ts.map +0 -1
- package/dist/react/useGiveawayEntry.js +0 -170
- package/dist/react/useGiveawayEntry.js.map +0 -1
- package/dist/react/useGiveawayPrize.d.ts +0 -12
- package/dist/react/useGiveawayPrize.d.ts.map +0 -1
- package/dist/react/useGiveawayPrize.js +0 -53
- package/dist/react/useGiveawayPrize.js.map +0 -1
- package/dist/react/useGiveawayPrizes.d.ts +0 -4
- package/dist/react/useGiveawayPrizes.d.ts.map +0 -1
- package/dist/react/useGiveawayPrizes.js +0 -58
- package/dist/react/useGiveawayPrizes.js.map +0 -1
- package/dist/react/useHiddenShows.d.ts +0 -10
- package/dist/react/useHiddenShows.d.ts.map +0 -1
- package/dist/react/useHiddenShows.js +0 -30
- package/dist/react/useHiddenShows.js.map +0 -1
- package/dist/react/useKeepScreenAwake.d.ts +0 -2
- package/dist/react/useKeepScreenAwake.d.ts.map +0 -1
- package/dist/react/useKeepScreenAwake.js +0 -34
- package/dist/react/useKeepScreenAwake.js.map +0 -1
- package/dist/react/useLiveAuction.d.ts +0 -106
- package/dist/react/useLiveAuction.d.ts.map +0 -1
- package/dist/react/useLiveAuction.js +0 -255
- package/dist/react/useLiveAuction.js.map +0 -1
- package/dist/react/useLiveChat.d.ts +0 -110
- package/dist/react/useLiveChat.d.ts.map +0 -1
- package/dist/react/useLiveChat.js +0 -230
- package/dist/react/useLiveChat.js.map +0 -1
- package/dist/react/useLiveGiveawaysAndPolls.d.ts +0 -95
- package/dist/react/useLiveGiveawaysAndPolls.d.ts.map +0 -1
- package/dist/react/useLiveGiveawaysAndPolls.js +0 -225
- package/dist/react/useLiveGiveawaysAndPolls.js.map +0 -1
- package/dist/react/useLivePage.d.ts +0 -136
- package/dist/react/useLivePage.d.ts.map +0 -1
- package/dist/react/useLivePage.js +0 -319
- package/dist/react/useLivePage.js.map +0 -1
- package/dist/react/useLiveShop.d.ts +0 -97
- package/dist/react/useLiveShop.d.ts.map +0 -1
- package/dist/react/useLiveShop.js +0 -197
- package/dist/react/useLiveShop.js.map +0 -1
- package/dist/react/useLiveShow.d.ts +0 -3
- package/dist/react/useLiveShow.d.ts.map +0 -1
- package/dist/react/useLiveShow.js +0 -21
- package/dist/react/useLiveShow.js.map +0 -1
- package/dist/react/useMySilentAuctionBids.d.ts +0 -29
- package/dist/react/useMySilentAuctionBids.d.ts.map +0 -1
- package/dist/react/useMySilentAuctionBids.js +0 -157
- package/dist/react/useMySilentAuctionBids.js.map +0 -1
- package/dist/react/useReplayPage.d.ts +0 -155
- package/dist/react/useReplayPage.d.ts.map +0 -1
- package/dist/react/useReplayPage.js +0 -580
- package/dist/react/useReplayPage.js.map +0 -1
- package/dist/react/useSilentAuctionLot.d.ts +0 -44
- package/dist/react/useSilentAuctionLot.d.ts.map +0 -1
- package/dist/react/useSilentAuctionLot.js +0 -168
- package/dist/react/useSilentAuctionLot.js.map +0 -1
- package/dist/react/useSilentAuctionLots.d.ts +0 -41
- package/dist/react/useSilentAuctionLots.d.ts.map +0 -1
- package/dist/react/useSilentAuctionLots.js +0 -64
- package/dist/react/useSilentAuctionLots.js.map +0 -1
- package/dist/react/useSilentAuctionRounds.d.ts +0 -15
- package/dist/react/useSilentAuctionRounds.d.ts.map +0 -1
- package/dist/react/useSilentAuctionRounds.js +0 -44
- package/dist/react/useSilentAuctionRounds.js.map +0 -1
- package/dist/replayPages.d.ts +0 -31
- package/dist/replayPages.d.ts.map +0 -1
- package/dist/replayPages.js +0 -34
- package/dist/replayPages.js.map +0 -1
- package/dist/shopifyCommerce.d.ts +0 -204
- package/dist/shopifyCommerce.d.ts.map +0 -1
- package/dist/shopifyCommerce.js +0 -217
- package/dist/shopifyCommerce.js.map +0 -1
- package/dist/shopifyIdentity.d.ts +0 -61
- package/dist/shopifyIdentity.d.ts.map +0 -1
- package/dist/shopifyIdentity.js +0 -61
- package/dist/shopifyIdentity.js.map +0 -1
- package/dist/shopifyIds.d.ts +0 -9
- package/dist/shopifyIds.d.ts.map +0 -1
- package/dist/shopifyIds.js +0 -18
- package/dist/shopifyIds.js.map +0 -1
- package/dist/showCredit.d.ts +0 -89
- package/dist/showCredit.d.ts.map +0 -1
- package/dist/showCredit.js +0 -120
- package/dist/showCredit.js.map +0 -1
- package/dist/showLinks.d.ts +0 -24
- package/dist/showLinks.d.ts.map +0 -1
- package/dist/showLinks.js +0 -23
- package/dist/showLinks.js.map +0 -1
- package/dist/showLots.d.ts +0 -44
- package/dist/showLots.d.ts.map +0 -1
- package/dist/showLots.js +0 -70
- package/dist/showLots.js.map +0 -1
- package/dist/showNames.d.ts +0 -77
- package/dist/showNames.d.ts.map +0 -1
- package/dist/showNames.js +0 -143
- package/dist/showNames.js.map +0 -1
- package/dist/showPages.d.ts +0 -56
- package/dist/showPages.d.ts.map +0 -1
- package/dist/showPages.js +0 -48
- package/dist/showPages.js.map +0 -1
- package/dist/silentAuctionFeed.d.ts +0 -49
- package/dist/silentAuctionFeed.d.ts.map +0 -1
- package/dist/silentAuctionFeed.js +0 -242
- package/dist/silentAuctionFeed.js.map +0 -1
- package/dist/silentAuctionRules.d.ts +0 -253
- package/dist/silentAuctionRules.d.ts.map +0 -1
- package/dist/silentAuctionRules.js +0 -489
- package/dist/silentAuctionRules.js.map +0 -1
- package/dist/silentAuctions.d.ts +0 -65
- package/dist/silentAuctions.d.ts.map +0 -1
- package/dist/silentAuctions.js +0 -272
- package/dist/silentAuctions.js.map +0 -1
- package/dist/storeData.d.ts +0 -16
- package/dist/storeData.d.ts.map +0 -1
- package/dist/storeData.js +0 -19
- package/dist/storeData.js.map +0 -1
- package/dist/ui/BubbleFrame.d.ts +0 -38
- package/dist/ui/BubbleFrame.d.ts.map +0 -1
- package/dist/ui/BubbleFrame.js +0 -181
- package/dist/ui/BubbleFrame.js.map +0 -1
- package/dist/ui/LiveBubble.d.ts +0 -43
- package/dist/ui/LiveBubble.d.ts.map +0 -1
- package/dist/ui/LiveBubble.js +0 -116
- package/dist/ui/LiveBubble.js.map +0 -1
- package/dist/ui/ReplayBubble.d.ts +0 -23
- package/dist/ui/ReplayBubble.d.ts.map +0 -1
- package/dist/ui/ReplayBubble.js +0 -71
- package/dist/ui/ReplayBubble.js.map +0 -1
- package/dist/ui.d.ts +0 -27
- package/dist/ui.d.ts.map +0 -1
- package/dist/ui.js +0 -34
- package/dist/ui.js.map +0 -1
- package/dist/unreadRoomMessages.d.ts +0 -26
- package/dist/unreadRoomMessages.d.ts.map +0 -1
- package/dist/unreadRoomMessages.js +0 -62
- package/dist/unreadRoomMessages.js.map +0 -1
- package/dist/viewerRules.d.ts +0 -38
- package/dist/viewerRules.d.ts.map +0 -1
- package/dist/viewerRules.js +0 -46
- package/dist/viewerRules.js.map +0 -1
- package/dist/winsAttribution.d.ts +0 -22
- package/dist/winsAttribution.d.ts.map +0 -1
- package/dist/winsAttribution.js +0 -49
- package/dist/winsAttribution.js.map +0 -1
- package/dist/zegoEngine.d.ts +0 -173
- package/dist/zegoEngine.d.ts.map +0 -1
- package/dist/zegoEngine.js +0 -1069
- package/dist/zegoEngine.js.map +0 -1
package/dist/react/index.web.js
CHANGED
|
@@ -1,10 +1,11 @@
|
|
|
1
1
|
"use strict";
|
|
2
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
-
exports.
|
|
4
|
-
exports.
|
|
5
|
-
exports.
|
|
6
|
-
exports.
|
|
7
|
-
exports.
|
|
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.refreshOngoingLive = 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;
|
|
8
9
|
/**
|
|
9
10
|
* The React layer on the **web** — real where a browser can honestly do the work, inert where it
|
|
10
11
|
* cannot. Metro resolves this file in place of `./index` for web, and TypeScript reads the native
|
|
@@ -27,18 +28,15 @@ exports.useLiveRail = useLiveRail;
|
|
|
27
28
|
* The **client** is real: `liveSelling` and its HTTP calls work from a browser, so `useLiveSelling()`,
|
|
28
29
|
* the stream/replay/clip read hooks and the polled record all behave as they do on device.
|
|
29
30
|
*
|
|
30
|
-
*
|
|
31
|
-
* wins) live in `platformSession.web.ts` since 0.14.0, which the page hooks and the `/ui` bubbles read
|
|
32
|
-
* the session from, so they run here too; this file re-exports them.
|
|
31
|
+
* `createElement` rather than JSX, like the rest of the package, so this stays a plain `.ts`.
|
|
33
32
|
*/
|
|
34
|
-
const
|
|
35
|
-
const
|
|
33
|
+
const react_1 = require("react");
|
|
34
|
+
const react_native_1 = require("react-native");
|
|
35
|
+
const sessionTypes_1 = require("../sessionTypes");
|
|
36
36
|
// Real on the web: the gateway is plain HTTP, and the engine it configures is the no-op build.
|
|
37
37
|
var LiveSellingProvider_1 = require("./LiveSellingProvider");
|
|
38
38
|
Object.defineProperty(exports, "LiveSellingProvider", { enumerable: true, get: function () { return LiveSellingProvider_1.LiveSellingProvider; } });
|
|
39
39
|
Object.defineProperty(exports, "useLiveSelling", { enumerable: true, get: function () { return LiveSellingProvider_1.useLiveSelling; } });
|
|
40
|
-
var useHiddenShows_1 = require("./useHiddenShows");
|
|
41
|
-
Object.defineProperty(exports, "useHiddenShows", { enumerable: true, get: function () { return useHiddenShows_1.useHiddenShows; } });
|
|
42
40
|
var useOngoingLive_1 = require("./useOngoingLive");
|
|
43
41
|
Object.defineProperty(exports, "useOngoingLive", { enumerable: true, get: function () { return useOngoingLive_1.useOngoingLive; } });
|
|
44
42
|
var ongoingLiveStore_1 = require("../ongoingLiveStore");
|
|
@@ -51,105 +49,127 @@ var useReplays_1 = require("./useReplays");
|
|
|
51
49
|
Object.defineProperty(exports, "useReplays", { enumerable: true, get: function () { return useReplays_1.useReplays; } });
|
|
52
50
|
var useClips_1 = require("./useClips");
|
|
53
51
|
Object.defineProperty(exports, "useClips", { enumerable: true, get: function () { return useClips_1.useClips; } });
|
|
54
|
-
var useFeaturedClip_1 = require("./useFeaturedClip");
|
|
55
|
-
Object.defineProperty(exports, "useFeaturedClip", { enumerable: true, get: function () { return useFeaturedClip_1.useFeaturedClip; } });
|
|
56
|
-
Object.defineProperty(exports, "forgetFeaturedClips", { enumerable: true, get: function () { return useFeaturedClip_1.forgetFeaturedClips; } });
|
|
57
|
-
var useGiveawayPrizes_1 = require("./useGiveawayPrizes");
|
|
58
|
-
Object.defineProperty(exports, "useGiveawayPrizes", { enumerable: true, get: function () { return useGiveawayPrizes_1.useGiveawayPrizes; } });
|
|
59
52
|
var useStreamInfo_1 = require("./useStreamInfo");
|
|
60
53
|
Object.defineProperty(exports, "useStreamInfo", { enumerable: true, get: function () { return useStreamInfo_1.useStreamInfo; } });
|
|
61
54
|
Object.defineProperty(exports, "refreshStreamRecords", { enumerable: true, get: function () { return useStreamInfo_1.refreshStreamRecords; } });
|
|
62
55
|
Object.defineProperty(exports, "refreshStreamRecordsIfStale", { enumerable: true, get: function () { return useStreamInfo_1.refreshStreamRecordsIfStale; } });
|
|
63
|
-
// Real on the web: plain React timers, counting to a number the caller passes.
|
|
64
|
-
var clocks_1 = require("./clocks");
|
|
65
|
-
Object.defineProperty(exports, "useAuctionCountdown", { enumerable: true, get: function () { return clocks_1.useAuctionCountdown; } });
|
|
66
|
-
Object.defineProperty(exports, "useShowClock", { enumerable: true, get: function () { return clocks_1.useShowClock; } });
|
|
67
|
-
// Real on the web: they read only the session a screen passes in (here the idle one, so no giveaway is
|
|
68
|
-
// ever open) and the adapter's catalogue.
|
|
69
|
-
var useGiveawayEntry_1 = require("./useGiveawayEntry");
|
|
70
|
-
Object.defineProperty(exports, "useGiveawayEntry", { enumerable: true, get: function () { return useGiveawayEntry_1.useGiveawayEntry; } });
|
|
71
|
-
var useGiveawayPrize_1 = require("./useGiveawayPrize");
|
|
72
|
-
Object.defineProperty(exports, "useGiveawayPrize", { enumerable: true, get: function () { return useGiveawayPrize_1.useGiveawayPrize; } });
|
|
73
|
-
var useCommentLinkCards_1 = require("./useCommentLinkCards");
|
|
74
|
-
Object.defineProperty(exports, "useCommentLinkCards", { enumerable: true, get: function () { return useCommentLinkCards_1.useCommentLinkCards; } });
|
|
75
|
-
// Silent auctions are plain requests, so the same on the web.
|
|
76
|
-
var useSilentAuctionLots_1 = require("./useSilentAuctionLots");
|
|
77
|
-
Object.defineProperty(exports, "useSilentAuctionLots", { enumerable: true, get: function () { return useSilentAuctionLots_1.useSilentAuctionLots; } });
|
|
78
|
-
var useSilentAuctionLot_1 = require("./useSilentAuctionLot");
|
|
79
|
-
Object.defineProperty(exports, "useSilentAuctionLot", { enumerable: true, get: function () { return useSilentAuctionLot_1.useSilentAuctionLot; } });
|
|
80
|
-
var useMySilentAuctionBids_1 = require("./useMySilentAuctionBids");
|
|
81
|
-
Object.defineProperty(exports, "useMySilentAuctionBids", { enumerable: true, get: function () { return useMySilentAuctionBids_1.useMySilentAuctionBids; } });
|
|
82
|
-
var useSilentAuctionRounds_1 = require("./useSilentAuctionRounds");
|
|
83
|
-
Object.defineProperty(exports, "useSilentAuctionRounds", { enumerable: true, get: function () { return useSilentAuctionRounds_1.useSilentAuctionRounds; } });
|
|
84
56
|
// Already returns null off device — react-native-web *throws* from `findNodeHandle`, which this
|
|
85
57
|
// wraps, so the honest answer costs nothing here.
|
|
86
58
|
var nativeViewTag_1 = require("../nativeViewTag");
|
|
87
59
|
Object.defineProperty(exports, "nativeViewTag", { enumerable: true, get: function () { return nativeViewTag_1.nativeViewTag; } });
|
|
88
|
-
//
|
|
89
|
-
|
|
90
|
-
|
|
91
|
-
|
|
92
|
-
|
|
93
|
-
|
|
94
|
-
|
|
95
|
-
|
|
96
|
-
|
|
97
|
-
|
|
98
|
-
|
|
99
|
-
|
|
100
|
-
|
|
101
|
-
|
|
102
|
-
|
|
103
|
-
|
|
104
|
-
|
|
105
|
-
|
|
106
|
-
|
|
107
|
-
|
|
108
|
-
|
|
109
|
-
|
|
110
|
-
|
|
111
|
-
|
|
112
|
-
|
|
113
|
-
|
|
114
|
-
|
|
115
|
-
|
|
116
|
-
|
|
117
|
-
|
|
118
|
-
|
|
119
|
-
|
|
120
|
-
|
|
121
|
-
|
|
122
|
-
|
|
123
|
-
|
|
124
|
-
|
|
125
|
-
|
|
126
|
-
|
|
127
|
-
|
|
128
|
-
|
|
129
|
-
|
|
130
|
-
|
|
131
|
-
|
|
132
|
-
|
|
133
|
-
|
|
134
|
-
|
|
135
|
-
|
|
136
|
-
|
|
137
|
-
|
|
138
|
-
|
|
139
|
-
|
|
140
|
-
|
|
141
|
-
|
|
142
|
-
|
|
143
|
-
|
|
144
|
-
|
|
145
|
-
|
|
60
|
+
// ─── The session ─────────────────────────────────────────────────────────────
|
|
61
|
+
/** Every action, resolved and doing nothing. There is no room to send any of it to. */
|
|
62
|
+
const IDLE_ACTIONS = {
|
|
63
|
+
bindVideoView: () => undefined,
|
|
64
|
+
sendComment: async () => undefined,
|
|
65
|
+
sendReaction: async () => undefined,
|
|
66
|
+
announceAddToCart: async () => undefined,
|
|
67
|
+
voteInPoll: async () => undefined,
|
|
68
|
+
chooseViewerName: async () => null,
|
|
69
|
+
addToCart: async () => false,
|
|
70
|
+
joinAsGuest: () => Promise.reject(new Error('Co-hosting needs a device build.')),
|
|
71
|
+
leaveGuest: async () => undefined,
|
|
72
|
+
setGuestMicMuted: async () => undefined,
|
|
73
|
+
setGuestCameraOff: async () => undefined,
|
|
74
|
+
flipGuestCamera: async () => undefined,
|
|
75
|
+
bindGuestPreview: () => undefined,
|
|
76
|
+
bindGuestHostView: () => undefined,
|
|
77
|
+
setMuted: () => undefined,
|
|
78
|
+
setOutputMuted: () => undefined,
|
|
79
|
+
setPipHandover: () => undefined,
|
|
80
|
+
holdStream: () => undefined,
|
|
81
|
+
releaseStream: () => undefined,
|
|
82
|
+
enterPip: () => undefined,
|
|
83
|
+
exitPip: () => undefined,
|
|
84
|
+
placeBid: async () => undefined,
|
|
85
|
+
enterGiveaway: async () => undefined,
|
|
86
|
+
dismissAuctionWin: () => undefined,
|
|
87
|
+
dismissGiveawayResult: () => undefined,
|
|
88
|
+
};
|
|
89
|
+
/** A stream that is over: the one state every surface already knows how to draw. */
|
|
90
|
+
const IDLE_SESSION = {
|
|
91
|
+
status: 'ended',
|
|
92
|
+
stream: null,
|
|
93
|
+
viewerCount: 0,
|
|
94
|
+
rawViewerCount: 0,
|
|
95
|
+
reactionStyle: 'single',
|
|
96
|
+
comments: [],
|
|
97
|
+
activeProduct: null,
|
|
98
|
+
products: [],
|
|
99
|
+
sold: [],
|
|
100
|
+
cartAnnouncements: [],
|
|
101
|
+
reactions: [],
|
|
102
|
+
poll: null,
|
|
103
|
+
muted: true,
|
|
104
|
+
videoTag: null,
|
|
105
|
+
elapsedMs: 0,
|
|
106
|
+
pipMode: 'none',
|
|
107
|
+
guest: {
|
|
108
|
+
mode: false,
|
|
109
|
+
status: 'idle',
|
|
110
|
+
slot: null,
|
|
111
|
+
mutedByHost: false,
|
|
112
|
+
cameraOffByHost: false,
|
|
113
|
+
mixerLayout: null,
|
|
114
|
+
},
|
|
115
|
+
viewerName: null,
|
|
116
|
+
auction: sessionTypes_1.IDLE_AUCTION,
|
|
117
|
+
giveaway: sessionTypes_1.IDLE_GIVEAWAY,
|
|
118
|
+
error: null,
|
|
119
|
+
actions: IDLE_ACTIONS,
|
|
120
|
+
};
|
|
121
|
+
const LiveSessionContext = (0, react_1.createContext)(null);
|
|
122
|
+
function LiveSessionProvider({ children }) {
|
|
123
|
+
return (0, react_1.createElement)(LiveSessionContext.Provider, { value: IDLE_SESSION }, children);
|
|
146
124
|
}
|
|
147
|
-
/**
|
|
148
|
-
|
|
149
|
-
|
|
125
|
+
/**
|
|
126
|
+
* The idle session, read without touching the context: a surface rendered outside the provider
|
|
127
|
+
* behaves the same as one inside it, because on the web there is only ever this one session.
|
|
128
|
+
*/
|
|
129
|
+
function useLiveSession() {
|
|
130
|
+
return IDLE_SESSION;
|
|
131
|
+
}
|
|
132
|
+
// ─── The video ───────────────────────────────────────────────────────────────
|
|
133
|
+
exports.isNativeVideoSupported = false;
|
|
134
|
+
/**
|
|
135
|
+
* A plain `View`, which is what the native file falls back to on a build without the Zego SDK:
|
|
136
|
+
* callers position this and draw a poster over it, so returning null would collapse the layout the
|
|
137
|
+
* poster depends on.
|
|
138
|
+
*/
|
|
139
|
+
exports.NativeVideoView = (0, react_1.forwardRef)(function NativeVideoView(props, _ref) {
|
|
140
|
+
return (0, react_1.createElement)(react_native_1.View, props);
|
|
141
|
+
});
|
|
142
|
+
function LiveVideoTarget({ style, children }) {
|
|
143
|
+
return (0, react_1.createElement)(react_native_1.View, { style: style !== null && style !== void 0 ? style : { flex: 1 } }, children);
|
|
144
|
+
}
|
|
145
|
+
// ─── Auctions ────────────────────────────────────────────────────────────────
|
|
146
|
+
exports.SHEET_HANDOFF_MS = 380;
|
|
147
|
+
/** Never blocks, because there is no bid to gate — `placeBid` above resolves without sending. */
|
|
148
|
+
function useAuctionBidGate(_options) {
|
|
149
|
+
return (0, react_1.useMemo)(() => ({
|
|
150
|
+
blocker: null,
|
|
151
|
+
variantId: null,
|
|
152
|
+
requestBid: () => undefined,
|
|
153
|
+
acceptTerms: () => undefined,
|
|
154
|
+
chooseVariant: () => undefined,
|
|
155
|
+
dismiss: () => undefined,
|
|
156
|
+
refreshUnpaidWins: () => undefined,
|
|
157
|
+
}), []);
|
|
150
158
|
}
|
|
151
|
-
/**
|
|
152
|
-
|
|
153
|
-
|
|
159
|
+
/**
|
|
160
|
+
* An empty tab rather than a failure. The wins metafield is readable from a browser, but settling one
|
|
161
|
+
* mints a cart and sends the shopper to checkout — not something a preview should be able to start.
|
|
162
|
+
*/
|
|
163
|
+
function useAuctionWins(_options) {
|
|
164
|
+
return (0, react_1.useMemo)(() => ({
|
|
165
|
+
rows: [],
|
|
166
|
+
totalBids: 0,
|
|
167
|
+
streamingId: null,
|
|
168
|
+
loading: false,
|
|
169
|
+
checkingOut: false,
|
|
170
|
+
error: null,
|
|
171
|
+
refresh: () => undefined,
|
|
172
|
+
checkout: async () => null,
|
|
173
|
+
}), []);
|
|
154
174
|
}
|
|
155
175
|
//# sourceMappingURL=index.web.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.web.js","sourceRoot":"","sources":["../../src/react/index.web.ts"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"index.web.js","sourceRoot":"","sources":["../../src/react/index.web.ts"],"names":[],"mappings":"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"}
|
|
@@ -1,5 +1,3 @@
|
|
|
1
|
-
import { type BidRound } from '../auctionRules';
|
|
2
|
-
import type { BidResult } from '../sessionTypes';
|
|
3
1
|
/**
|
|
4
2
|
* How long to leave between one panel closing and the next opening.
|
|
5
3
|
*
|
|
@@ -11,25 +9,8 @@ import type { BidResult } from '../sessionTypes';
|
|
|
11
9
|
* Long enough to outlast a slide-out, short enough not to read as a pause.
|
|
12
10
|
*/
|
|
13
11
|
export declare const SHEET_HANDOFF_MS = 380;
|
|
14
|
-
/**
|
|
15
|
-
export
|
|
16
|
-
/**
|
|
17
|
-
* What is standing between the viewer and the bid they asked for. `checkingAccount` (0.16.0): the bid
|
|
18
|
-
* waits while the account is read ("Checking your account…"); `accountUnknown`: it couldn't be, and the
|
|
19
|
-
* bid was dropped ("We couldn't check your account just now").
|
|
20
|
-
*/
|
|
21
|
-
export type BidBlocker = 'signIn' | 'blocked' | 'checkingAccount' | 'accountUnknown' | 'unpaidWins' | 'terms' | 'variant' | null;
|
|
22
|
-
/**
|
|
23
|
-
* A bid the gate didn't send, and why (0.9.0, `atAmountShown`): the room moved past it (`outbid`), or
|
|
24
|
-
* it is over the host's ceiling (`overCap`).
|
|
25
|
-
*/
|
|
26
|
-
export interface BidRefusal {
|
|
27
|
-
/** A new number for each refusal, so the same reason twice is shown twice. */
|
|
28
|
-
id: number;
|
|
29
|
-
reason: 'outbid' | 'overCap';
|
|
30
|
-
/** What to tell the shopper: the round's next bid now (`outbid`), or the ceiling (`overCap`). */
|
|
31
|
-
amount: number;
|
|
32
|
-
}
|
|
12
|
+
/** What is standing between the viewer and the bid they asked for. */
|
|
13
|
+
export type BidBlocker = 'signIn' | 'unpaidWins' | 'terms' | 'variant' | null;
|
|
33
14
|
export interface AuctionBidGate {
|
|
34
15
|
blocker: BidBlocker;
|
|
35
16
|
/** The variant chosen for this round, once asked. */
|
|
@@ -50,55 +31,18 @@ export interface AuctionBidGate {
|
|
|
50
31
|
* cannot hook navigation focus itself.
|
|
51
32
|
*/
|
|
52
33
|
refreshUnpaidWins: () => void;
|
|
53
|
-
/** The last bid not sent because the room moved past it or it passed the ceiling (`atAmountShown`). 0.9.0. */
|
|
54
|
-
refusal: BidRefusal | null;
|
|
55
|
-
/** A bid was just handed to `placeBid`: true for `BID_ON_ITS_WAY_MS`, so the bar takes no other. 0.9.0. */
|
|
56
|
-
bidOnItsWay: boolean;
|
|
57
34
|
}
|
|
58
|
-
interface
|
|
35
|
+
export interface UseAuctionBidGateOptions {
|
|
59
36
|
streamingId: string | null;
|
|
60
37
|
isLoggedIn: boolean;
|
|
61
|
-
/** True while a round is open. Closing one forgets the chosen variant
|
|
38
|
+
/** True while a round is open. Closing one forgets the chosen variant. */
|
|
62
39
|
biddingOpen: boolean;
|
|
63
40
|
/** How many variants the lot under the hammer has. 1 or 0 skips the variant step. */
|
|
64
41
|
variantCount: number;
|
|
65
|
-
/** The session's `actions.placeBid`, or a wrapper round it. */
|
|
66
42
|
placeBid: (options?: {
|
|
67
43
|
amount?: number;
|
|
68
44
|
variantId?: string | null;
|
|
69
|
-
}) => Promise<
|
|
70
|
-
/**
|
|
71
|
-
* Starts the app's sign-in (0.9.0). With it the gate never stops at `signIn`: it holds the bid and
|
|
72
|
-
* calls this, then comes back to the bid once `isLoggedIn`, if bidding on its lot is still open.
|
|
73
|
-
* Without it the gate stops at `signIn`, as in 0.8, and the app decides.
|
|
74
|
-
*/
|
|
75
|
-
startSignIn?: () => unknown;
|
|
76
|
-
/**
|
|
77
|
-
* Signed in, the bidder still loading (a stored sign-in being read, a customer on its way): a bid
|
|
78
|
-
* asked for now waits for them, and no sign-in is started. 0.9.0, with `startSignIn`.
|
|
79
|
-
*/
|
|
80
|
-
signInLoading?: boolean;
|
|
81
|
-
/**
|
|
82
|
-
* The screen is on show, with nothing over it (navigation focus). When it comes back on show and the
|
|
83
|
-
* shopper is still signed out (the app's Sign In page closed without a sign-in), a bid waiting for
|
|
84
|
-
* the sign-in is dropped. A sign-in that never leaves the screen (a system sheet) keeps it until the
|
|
85
|
-
* lot closes. Defaults to true. 0.9.0, with `startSignIn`.
|
|
86
|
-
*/
|
|
87
|
-
screenOnShow?: boolean;
|
|
45
|
+
}) => Promise<void>;
|
|
88
46
|
}
|
|
89
|
-
export
|
|
90
|
-
/**
|
|
91
|
-
* A bid goes out at the amount the shopper saw, or not at all (0.9.0): `requestBid()` holds the
|
|
92
|
-
* round's next bid as it is at the tap, and every bid gets a last look at the round as it goes
|
|
93
|
-
* (`bidRefusal`). Needs `round`.
|
|
94
|
-
*/
|
|
95
|
-
atAmountShown: true;
|
|
96
|
-
/** The round as the shopper sees it: `session.auction`. */
|
|
97
|
-
round: BidRound;
|
|
98
|
-
} | {
|
|
99
|
-
atAmountShown?: false;
|
|
100
|
-
round?: BidRound;
|
|
101
|
-
});
|
|
102
|
-
export declare function useAuctionBidGate(options: UseAuctionBidGateOptions): AuctionBidGate;
|
|
103
|
-
export {};
|
|
47
|
+
export declare function useAuctionBidGate({ streamingId, isLoggedIn, biddingOpen, variantCount, placeBid, }: UseAuctionBidGateOptions): AuctionBidGate;
|
|
104
48
|
//# sourceMappingURL=useAuctionBidGate.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"useAuctionBidGate.d.ts","sourceRoot":"","sources":["../../src/react/useAuctionBidGate.ts"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"useAuctionBidGate.d.ts","sourceRoot":"","sources":["../../src/react/useAuctionBidGate.ts"],"names":[],"mappings":"AA6BA;;;;;;;;;GASG;AACH,eAAO,MAAM,gBAAgB,MAAM,CAAC;AAEpC,sEAAsE;AACtE,MAAM,MAAM,UAAU,GAAG,QAAQ,GAAG,YAAY,GAAG,OAAO,GAAG,SAAS,GAAG,IAAI,CAAC;AAE9E,MAAM,WAAW,cAAc;IAC7B,OAAO,EAAE,UAAU,CAAC;IACpB,qDAAqD;IACrD,SAAS,EAAE,MAAM,GAAG,IAAI,CAAC;IACzB,qFAAqF;IACrF,UAAU,EAAE,CAAC,MAAM,CAAC,EAAE,MAAM,KAAK,IAAI,CAAC;IACtC,6DAA6D;IAC7D,WAAW,EAAE,MAAM,IAAI,CAAC;IACxB,iFAAiF;IACjF,aAAa,EAAE,CAAC,SAAS,EAAE,MAAM,KAAK,IAAI,CAAC;IAC3C,oDAAoD;IACpD,OAAO,EAAE,MAAM,IAAI,CAAC;IACpB;;;;;;OAMG;IACH,iBAAiB,EAAE,MAAM,IAAI,CAAC;CAC/B;AAED,MAAM,WAAW,wBAAwB;IACvC,WAAW,EAAE,MAAM,GAAG,IAAI,CAAC;IAC3B,UAAU,EAAE,OAAO,CAAC;IACpB,0EAA0E;IAC1E,WAAW,EAAE,OAAO,CAAC;IACrB,qFAAqF;IACrF,YAAY,EAAE,MAAM,CAAC;IACrB,QAAQ,EAAE,CAAC,OAAO,CAAC,EAAE;QAAE,MAAM,CAAC,EAAE,MAAM,CAAC;QAAC,SAAS,CAAC,EAAE,MAAM,GAAG,IAAI,CAAA;KAAE,KAAK,OAAO,CAAC,IAAI,CAAC,CAAC;CACvF;AAED,wBAAgB,iBAAiB,CAAC,EAChC,WAAW,EACX,UAAU,EACV,WAAW,EACX,YAAY,EACZ,QAAQ,GACT,EAAE,wBAAwB,GAAG,cAAc,CAyH3C"}
|