@streamlayer/react-ui 1.0.0 → 1.2.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/lib/app/app/Advertisement/index.d.ts +10 -0
- package/lib/app/app/Advertisement/index.js +89 -0
- package/lib/{ui/app/masters → app/app}/Features/FeatureProvider.d.ts +2 -2
- package/lib/{ui/app → app}/app/Features/FeatureProvider.js +8 -8
- package/lib/{ui/app → app}/app/Features/Gamification/Friends.d.ts +0 -1
- package/lib/{ui/app → app}/app/Features/Gamification/Friends.js +2 -2
- package/lib/{ui/app → app}/app/Features/Gamification/Leaderboard.d.ts +3 -3
- package/lib/{ui/app → app}/app/Features/Gamification/Leaderboard.js +16 -16
- package/lib/{ui/app/masters → app/app}/Features/Gamification/Question.d.ts +1 -1
- package/lib/app/app/Features/Gamification/Question.js +69 -0
- package/lib/{ui/app → app}/app/Features/Gamification/QuestionsList.d.ts +2 -2
- package/lib/{ui/app → app}/app/Features/Gamification/QuestionsList.js +1 -1
- package/lib/{ui/app/masters → app/app}/Features/Gamification/Tabs.d.ts +3 -3
- package/lib/{ui/app → app}/app/Features/Gamification/Tabs.js +12 -12
- package/lib/{ui/app → app}/app/Features/Gamification/UserSummary.d.ts +2 -2
- package/lib/{ui/app/masters → app/app}/Features/Gamification/UserSummary.js +1 -1
- package/lib/{ui/app → app}/app/Features/Gamification/gamification-feature.d.ts +1 -0
- package/lib/{ui/app → app}/app/Features/Gamification/index.d.ts +3 -3
- package/lib/{ui/app/masters → app/app}/Features/Gamification/index.js +29 -29
- package/lib/{ui/app/masters → app/app}/Features/index.d.ts +4 -4
- package/lib/app/app/Navigation/index.d.ts +6 -0
- package/lib/app/app/Navigation/index.js +64 -0
- package/lib/{ui/app → app}/app/Notifications/Onboarding/Notification/index.d.ts +2 -2
- package/lib/app/app/Notifications/Onboarding/Notification/styles.d.ts +9 -0
- package/lib/app/app/Notifications/Onboarding/Notification/styles.js +50 -0
- package/lib/{ui/app/masters → app/app}/Notifications/Onboarding/index.d.ts +4 -4
- package/lib/app/app/Notifications/Onboarding/index.js +168 -0
- package/lib/{ui/app → app}/app/Notifications/index.d.ts +3 -3
- package/lib/{ui/app → app}/app/Notifications/index.js +27 -27
- package/lib/app/app/Notifications/styles.d.ts +9 -0
- package/lib/app/app/Notifications/styles.js +31 -0
- package/lib/{ui/app/app/Navigation → app/app/Points}/index.d.ts +2 -2
- package/lib/{ui/app → app}/app/Points/index.js +1 -1
- package/lib/{ui/app → app}/app/index.d.ts +2 -2
- package/lib/{ui/app → app}/app/index.js +32 -32
- package/lib/app/app/story/content.d.ts +4 -0
- package/lib/app/app/story/content.js +30 -0
- package/lib/app/app/story/index.d.ts +10 -0
- package/lib/app/app/story/index.js +113 -0
- package/lib/app/app/story/login.d.ts +1 -0
- package/lib/app/app/story/login.js +34 -0
- package/lib/app/app/story/styles.d.ts +9 -0
- package/lib/app/app/story/styles.js +49 -0
- package/lib/app/app/story/useResponsive.d.ts +1 -0
- package/lib/app/app/story/useResponsive.js +15 -0
- package/lib/app/app/story/video.d.ts +10 -0
- package/lib/app/app/story/video.js +67 -0
- package/lib/{ui/app → app}/app/useApp.d.ts +2 -1
- package/lib/{ui/app → app}/app/useApp.js +20 -17
- package/lib/app/app/useAppContext.d.ts +8 -0
- package/lib/{ui/app → app}/index.d.ts +0 -1
- package/lib/app/login/demo.d.ts +5 -0
- package/lib/{ui → app}/login/index.d.ts +0 -1
- package/lib/{ui → app}/login/index.js +1 -1
- package/lib/app/login/styles.d.ts +7 -0
- package/lib/app/login/styles.js +39 -0
- package/lib/{ui/app/app → app/masters}/Features/FeatureProvider.d.ts +2 -2
- package/lib/{ui/app → app}/masters/Features/FeatureProvider.js +8 -8
- package/lib/{ui/app → app}/masters/Features/Gamification/Friends.d.ts +0 -1
- package/lib/app/masters/Features/Gamification/Friends.js +19 -0
- package/lib/{ui/app → app}/masters/Features/Gamification/Leaderboard.d.ts +3 -3
- package/lib/{ui/app → app}/masters/Features/Gamification/Leaderboard.js +10 -10
- package/lib/{ui/app/app → app/masters}/Features/Gamification/Question.d.ts +1 -1
- package/lib/{ui/app → app}/masters/Features/Gamification/Question.js +11 -11
- package/lib/{ui/app → app}/masters/Features/Gamification/QuestionsList.d.ts +2 -2
- package/lib/{ui/app → app}/masters/Features/Gamification/QuestionsList.js +1 -1
- package/lib/{ui/app/app → app/masters}/Features/Gamification/Tabs.d.ts +3 -3
- package/lib/{ui/app → app}/masters/Features/Gamification/Tabs.js +12 -12
- package/lib/{ui/app → app}/masters/Features/Gamification/UserSummary.d.ts +2 -2
- package/lib/{ui/app/app → app/masters}/Features/Gamification/UserSummary.js +1 -1
- package/lib/{ui/app → app}/masters/Features/Gamification/gamification-feature.d.ts +1 -0
- package/lib/{ui/app → app}/masters/Features/Gamification/index.d.ts +3 -3
- package/lib/app/masters/Features/Gamification/index.js +88 -0
- package/lib/{ui/app/app → app/masters}/Features/index.d.ts +4 -4
- package/lib/{ui/app → app}/masters/Navigation/MastersNavigation/index.d.ts +5 -5
- package/lib/{ui/app → app}/masters/Navigation/MastersNavigation/index.js +5 -5
- package/lib/{ui/app → app}/masters/Notifications/Onboarding/Notification/index.d.ts +2 -2
- package/lib/app/masters/Notifications/Onboarding/Notification/styles.d.ts +9 -0
- package/lib/{ui/app/app → app/masters}/Notifications/Onboarding/Notification/styles.js +16 -16
- package/lib/{ui/app/app → app/masters}/Notifications/Onboarding/index.d.ts +4 -4
- package/lib/{mastersLogoSolid-B4Dz-vm1.js → app/masters/Notifications/Onboarding/index.js} +166 -2
- package/lib/{ui/app → app}/masters/Notifications/index.d.ts +3 -3
- package/lib/{ui/app → app}/masters/Notifications/index.js +48 -47
- package/lib/app/masters/Notifications/styles.d.ts +9 -0
- package/lib/{ui/app/app → app/masters}/Notifications/styles.js +10 -10
- package/lib/app/masters/Points/index.d.ts +5 -0
- package/lib/{ui/app → app}/masters/Points/index.js +1 -1
- package/lib/{ui/app → app}/masters/masters.d.ts +3 -3
- package/lib/{ui/app → app}/masters/masters.js +20 -20
- package/lib/{ui/app → app}/masters/useMastersApp.d.ts +2 -1
- package/lib/app/masters/useMastersApp.js +71 -0
- package/lib/app/masters/useMastersContext.d.ts +8 -0
- package/lib/app/styles.d.ts +20 -0
- package/lib/{ui/app → app}/styles.js +13 -13
- package/lib/{ui/app → app}/useClipboardCopy.d.ts +3 -3
- package/lib/{ui/app → app}/useClipboardCopy.js +2 -2
- package/lib/{ui/app → app}/useSdkFeature.d.ts +2 -1
- package/lib/{ui/app → app}/useSdkResponsive.d.ts +3 -1
- package/lib/{ui/app → app}/useSdkResponsive.js +2 -2
- package/lib/{ui/app → app}/useSdkScroll.d.ts +3 -2
- package/lib/{ui/app → app}/useSdkScroll.js +2 -2
- package/lib/assets/style.css +1 -1
- package/lib/hooks/showIn.js +1 -1
- package/lib/{index-Bicco-Aq.js → index-B1QdimmR.js} +7737 -8219
- package/lib/index.d.ts +1 -1
- package/lib/index.js +1 -1
- package/lib/ui/advertisement/banner/index.d.ts +8 -0
- package/lib/ui/advertisement/banner/index.js +32 -0
- package/lib/ui/advertisement/index.d.ts +10 -0
- package/lib/ui/advertisement/index.js +19 -0
- package/lib/ui/advertisement/mock.d.ts +4 -0
- package/lib/ui/advertisement/mock.js +67 -0
- package/lib/ui/advertisement/overlay/index.d.ts +7 -0
- package/lib/ui/advertisement/overlay/index.js +74 -0
- package/lib/ui/advertisement/overlay/styles.d.ts +18 -0
- package/lib/ui/advertisement/overlay/styles.js +95 -0
- package/lib/ui/advertisement/sidebar/index.d.ts +7 -0
- package/lib/ui/advertisement/sidebar/index.js +25 -0
- package/lib/ui/animated-counter/index.d.ts +1 -1
- package/lib/ui/button/index.d.ts +0 -1
- package/lib/ui/button/styles.d.ts +2 -3
- package/lib/ui/gamification/constants.d.ts +1 -0
- package/lib/ui/gamification/copyNotification/index.d.ts +0 -1
- package/lib/ui/gamification/copyNotification/styles.d.ts +3 -4
- package/lib/ui/gamification/detail/header/index.d.ts +1 -1
- package/lib/ui/gamification/detail/header/styles.d.ts +4 -5
- package/lib/ui/gamification/detail/sponsor/index.d.ts +1 -1
- package/lib/ui/gamification/detail/sponsor/index.js +13 -7
- package/lib/ui/gamification/insight/index.d.ts +1 -1
- package/lib/ui/gamification/insight/styles.d.ts +8 -9
- package/lib/ui/gamification/insight-list/index.d.ts +1 -1
- package/lib/ui/gamification/insight-list/styles.d.ts +2 -3
- package/lib/ui/gamification/invite-link/index.d.ts +0 -1
- package/lib/ui/gamification/invite-link/index.js +13 -13
- package/lib/ui/gamification/invite-link/styles.d.ts +5 -6
- package/lib/ui/gamification/invite-link/styles.js +11 -11
- package/lib/ui/gamification/leaderboard/index.d.ts +1 -1
- package/lib/ui/gamification/leaderboard/list-item/index.d.ts +2 -2
- package/lib/ui/gamification/leaderboard/list-item/styles.d.ts +7 -8
- package/lib/ui/gamification/leaderboard/static.d.ts +3 -3
- package/lib/ui/gamification/leaderboard/styles.d.ts +1 -2
- package/lib/ui/gamification/leaderboard/styles.js +1 -1
- package/lib/ui/gamification/onboarding/index.d.ts +3 -3
- package/lib/ui/gamification/onboarding/invitingUser/index.d.ts +0 -1
- package/lib/ui/gamification/onboarding/invitingUser/styles.d.ts +5 -6
- package/lib/ui/gamification/onboarding/slides/onboarding-instructions/index.d.ts +1 -0
- package/lib/ui/gamification/onboarding/slides/onboarding-instructions/styles.d.ts +10 -11
- package/lib/ui/gamification/onboarding/slides/onboarding-invite-card/index.d.ts +1 -1
- package/lib/ui/gamification/onboarding/slides/onboarding-invite-card/index.js +6 -6
- package/lib/ui/gamification/onboarding/slides/onboarding-invite-card/styles.d.ts +9 -10
- package/lib/ui/gamification/onboarding/slides/onboarding-rules/index.d.ts +1 -1
- package/lib/ui/gamification/onboarding/slides/onboarding-rules/styles.d.ts +8 -9
- package/lib/ui/gamification/onboarding/slides/onboarding-terms/index.d.ts +0 -1
- package/lib/ui/gamification/onboarding/slides/onboarding-terms/styles.d.ts +4 -5
- package/lib/ui/gamification/onboarding/styles.d.ts +5 -6
- package/lib/ui/gamification/points/index.d.ts +0 -1
- package/lib/ui/gamification/points/styles.d.ts +5 -6
- package/lib/ui/gamification/question/index.d.ts +2 -2
- package/lib/ui/gamification/question/index.js +27 -26
- package/lib/ui/gamification/question/insight/index.d.ts +1 -1
- package/lib/ui/gamification/question/insight/styles.d.ts +2 -3
- package/lib/ui/gamification/question/list/index.d.ts +2 -2
- package/lib/ui/gamification/question/list/styles.d.ts +1 -2
- package/lib/ui/gamification/question/notification/index.d.ts +2 -2
- package/lib/ui/gamification/question/notification/insight/index.d.ts +2 -2
- package/lib/ui/gamification/question/notification/insight/styles.d.ts +7 -8
- package/lib/ui/gamification/question/notification/pill/index.d.ts +0 -1
- package/lib/ui/gamification/question/notification/pill/styles.d.ts +3 -4
- package/lib/ui/gamification/question/notification/prediction-result/animation-lines/index.d.ts +0 -1
- package/lib/ui/gamification/question/notification/prediction-result/animation-lines/styles.d.ts +58 -31
- package/lib/ui/gamification/question/notification/prediction-result/index.d.ts +3 -2
- package/lib/ui/gamification/question/notification/prediction-result/index.js +55 -54
- package/lib/ui/gamification/question/notification/prediction-result/styles.d.ts +11 -10
- package/lib/ui/gamification/question/notification/styles.d.ts +6 -7
- package/lib/ui/gamification/question/notification/tweet/index.d.ts +3 -3
- package/lib/ui/gamification/question/notification/tweet/styles.d.ts +4 -5
- package/lib/ui/gamification/question/styles.d.ts +14 -14
- package/lib/ui/gamification/question/styles.js +48 -43
- package/lib/ui/gamification/question/twitter/index.d.ts +2 -2
- package/lib/ui/gamification/question/twitter/styles.d.ts +3 -4
- package/lib/ui/gamification/tabs/index.d.ts +0 -1
- package/lib/ui/gamification/tabs/styles.d.ts +4 -5
- package/lib/ui/gamification/user-statistics/components/rank/index.d.ts +0 -1
- package/lib/ui/gamification/user-statistics/components/rank/styles.d.ts +3 -4
- package/lib/ui/gamification/user-statistics/components/statistic/index.d.ts +0 -1
- package/lib/ui/gamification/user-statistics/components/statistic/styles.d.ts +3 -4
- package/lib/ui/gamification/user-statistics/index.d.ts +0 -1
- package/lib/ui/gamification/user-statistics/styles.d.ts +17 -18
- package/lib/ui/gamification/vote/alert/index.d.ts +2 -1
- package/lib/ui/gamification/vote/alert/styles.d.ts +3 -4
- package/lib/ui/gamification/vote/feedback/index.d.ts +1 -1
- package/lib/ui/gamification/vote/feedback/styles.d.ts +8 -9
- package/lib/ui/gamification/vote/index.d.ts +1 -1
- package/lib/ui/gamification/vote/insight-details/index.d.ts +1 -1
- package/lib/ui/gamification/vote/insight-details/styles.d.ts +2 -3
- package/lib/ui/gamification/vote/styles.d.ts +4 -5
- package/lib/ui/gamification/vote/styles.js +1 -1
- package/lib/ui/gamification/vote/twitter-details/index.d.ts +2 -2
- package/lib/ui/gamification/vote/twitter-details/styles.d.ts +2 -3
- package/lib/ui/gamification/vote/vote-option/index.d.ts +1 -1
- package/lib/ui/gamification/vote/vote-option/index.js +6 -6
- package/lib/ui/gamification/vote/vote-option/styles.d.ts +19 -16
- package/lib/ui/gamification/vote/win-bar/index.d.ts +1 -1
- package/lib/ui/gamification/vote/win-bar/styles.d.ts +6 -7
- package/lib/ui/icons/index.d.ts +1 -1
- package/lib/ui/icons/index.js +108 -47
- package/lib/ui/lottie/index.d.ts +0 -1
- package/lib/ui/modal/index.d.ts +0 -1
- package/lib/ui/modal/index.js +1 -1
- package/lib/ui/navigation/button/Channels.d.ts +1 -1
- package/lib/ui/navigation/button/FeaturedGroups.d.ts +1 -1
- package/lib/ui/navigation/button/LeaderBoard.d.ts +1 -1
- package/lib/ui/navigation/button/index.d.ts +1 -1
- package/lib/ui/navigation/button/styles.d.ts +6 -7
- package/lib/ui/navigation/index.d.ts +1 -1
- package/lib/ui/navigation/masters.d.ts +6 -5
- package/lib/ui/questions/insight/index.d.ts +1 -1
- package/lib/ui/questions/insight/styles.d.ts +6 -7
- package/lib/ui/questions/twitter/account/index.d.ts +0 -1
- package/lib/ui/questions/twitter/account/styles.d.ts +6 -7
- package/lib/ui/questions/twitter/index.d.ts +1 -1
- package/lib/ui/questions/twitter/styles.d.ts +14 -11
- package/lib/ui/show-in/index.d.ts +2 -1
- package/lib/ui/skeleton/index.d.ts +0 -1
- package/lib/ui/skeleton/styles.d.ts +1 -2
- package/lib/ui/slide-in/index.d.ts +11 -0
- package/lib/ui/slide-in/index.js +24 -0
- package/lib/ui/theme/ThemeColors.js +1 -1
- package/lib/ui/theme/ThemeColorsAdvertisement.d.ts +1 -0
- package/lib/ui/theme/ThemeColorsAdvertisement.js +15 -0
- package/lib/ui/theme/breakpoints.d.ts +1 -0
- package/lib/ui/theme/constants.d.ts +23 -59
- package/lib/ui/theme/constants.js +41 -56
- package/lib/ui/theme/index.d.ts +0 -1
- package/lib/ui/theme/masters-theme.d.ts +4 -24
- package/lib/ui/theme/masters-theme.js +26 -58
- package/lib/ui/theme/masters.d.ts +0 -1
- package/lib/ui/theme/theme.d.ts +1 -1
- package/lib/ui/theme/theme.js +14 -11
- package/lib/ui/timer/index.d.ts +3 -2
- package/lib/ui/timer/index.js +32 -32
- package/lib/ui/video-player/index.d.ts +1 -1
- package/lib/ui/video-player/index.js +70 -62
- package/lib/ui/video-player/styles.d.ts +5 -6
- package/lib/utils/debug/storage.js +1 -1
- package/lib/utils/storage.js +1 -1
- package/package.json +47 -41
- package/lib/styles_z07sl8-l0sNRNKZ.js +0 -1
- package/lib/ui/app/app/Features/Gamification/Question.js +0 -69
- package/lib/ui/app/app/Features/Gamification/index.js +0 -88
- package/lib/ui/app/app/Navigation/index.js +0 -42
- package/lib/ui/app/app/Notifications/Onboarding/Notification/styles.d.ts +0 -10
- package/lib/ui/app/app/Notifications/Onboarding/index.js +0 -172
- package/lib/ui/app/app/Notifications/styles.d.ts +0 -8
- package/lib/ui/app/app/Points/index.d.ts +0 -5
- package/lib/ui/app/app/useAppContext.d.ts +0 -8
- package/lib/ui/app/masters/Features/Gamification/Friends.js +0 -19
- package/lib/ui/app/masters/Navigation/index.d.ts +0 -9
- package/lib/ui/app/masters/Navigation/index.js +0 -30
- package/lib/ui/app/masters/Notifications/Onboarding/Notification/styles.d.ts +0 -10
- package/lib/ui/app/masters/Notifications/Onboarding/Notification/styles.js +0 -50
- package/lib/ui/app/masters/Notifications/Onboarding/index.js +0 -172
- package/lib/ui/app/masters/Notifications/styles.d.ts +0 -8
- package/lib/ui/app/masters/Notifications/styles.js +0 -31
- package/lib/ui/app/masters/Points/index.d.ts +0 -5
- package/lib/ui/app/masters/useMastersApp.js +0 -68
- package/lib/ui/app/masters/useMastersContext.d.ts +0 -8
- package/lib/ui/app/styles.d.ts +0 -15
- package/lib/ui/login/demo.d.ts +0 -6
- package/lib/ui/login/styles.d.ts +0 -8
- package/lib/ui/login/styles.js +0 -39
- /package/lib/{ui/app → app}/app/Features/Gamification/gamification-feature.js +0 -0
- /package/lib/{ui/app → app}/app/Features/index.js +0 -0
- /package/lib/{ui/app → app}/app/Notifications/Onboarding/Notification/index.js +0 -0
- /package/lib/{ui/app → app}/app/useAppContext.js +0 -0
- /package/lib/{ui/app → app}/index.js +0 -0
- /package/lib/{ui → app}/login/demo.js +0 -0
- /package/lib/{ui/app → app}/masters/Features/Gamification/gamification-feature.js +0 -0
- /package/lib/{ui/app → app}/masters/Features/index.js +0 -0
- /package/lib/{ui/app → app}/masters/Notifications/Onboarding/Notification/index.js +0 -0
- /package/lib/{ui/app → app}/masters/useMastersContext.js +0 -0
- /package/lib/{ui/app → app}/useImagesPreload.d.ts +0 -0
- /package/lib/{ui/app → app}/useImagesPreload.js +0 -0
- /package/lib/{ui/app → app}/useSdkFeature.js +0 -0
package/lib/ui/theme/theme.js
CHANGED
|
@@ -1,7 +1,8 @@
|
|
|
1
1
|
import { jsx as e, jsxs as r } from "react/jsx-runtime";
|
|
2
2
|
import { breakpoints as n } from "./breakpoints.js";
|
|
3
|
-
import { colors as h, FONT as t } from "./constants.js";
|
|
3
|
+
import { colors as s, colorsAdvertisement as h, FONT as t } from "./constants.js";
|
|
4
4
|
const l = `
|
|
5
|
+
${s}
|
|
5
6
|
${h}
|
|
6
7
|
--font-family: ${t.REGULAR};
|
|
7
8
|
--font-regular: ${t.REGULAR};
|
|
@@ -10,9 +11,11 @@ const l = `
|
|
|
10
11
|
--font-weight-default: ${t.WEIGHT_DEFAULT};
|
|
11
12
|
|
|
12
13
|
--header-offset: 0px;
|
|
13
|
-
--header-height:
|
|
14
|
+
--header-height: 68px;
|
|
14
15
|
--watch-live-header: 0px;
|
|
15
16
|
--animation-duration: 0.5s;
|
|
17
|
+
--promo-animation-duration: 0.5s;
|
|
18
|
+
--promo-animation-function: ease-in;
|
|
16
19
|
--animation-function: ease;
|
|
17
20
|
--container-padding: 16px;
|
|
18
21
|
--border-radius: 8px;
|
|
@@ -21,14 +24,14 @@ const l = `
|
|
|
21
24
|
--max-notifications-width: 400px;
|
|
22
25
|
|
|
23
26
|
${n.down("xl")`
|
|
24
|
-
--header-offset:
|
|
27
|
+
--header-offset: 0px;
|
|
25
28
|
--watch-live-header: 46px;
|
|
26
29
|
`}
|
|
27
30
|
|
|
28
31
|
${n.intermediate("xl", "lg")`
|
|
29
|
-
--header-offset:
|
|
32
|
+
--header-offset: 0px;
|
|
30
33
|
`}
|
|
31
|
-
`,
|
|
34
|
+
`, f = "StreamLayerCSSReset", x = "ttkj0ah", u = () => /* @__PURE__ */ e("table", {
|
|
32
35
|
children: /* @__PURE__ */ r("table", {
|
|
33
36
|
children: [/* @__PURE__ */ e("thead", {
|
|
34
37
|
children: /* @__PURE__ */ r("tr", {
|
|
@@ -39,11 +42,11 @@ const l = `
|
|
|
39
42
|
})]
|
|
40
43
|
})
|
|
41
44
|
}), /* @__PURE__ */ e("tbody", {
|
|
42
|
-
children: l.split(";").map((
|
|
43
|
-
const i =
|
|
45
|
+
children: l.split(";").map((o) => {
|
|
46
|
+
const i = o.trim(), [a, d] = i.split(":");
|
|
44
47
|
return /* @__PURE__ */ r("tr", {
|
|
45
48
|
children: [/* @__PURE__ */ e("td", {
|
|
46
|
-
children:
|
|
49
|
+
children: a
|
|
47
50
|
}), /* @__PURE__ */ e("td", {
|
|
48
51
|
children: d
|
|
49
52
|
})]
|
|
@@ -53,8 +56,8 @@ const l = `
|
|
|
53
56
|
})
|
|
54
57
|
});
|
|
55
58
|
export {
|
|
56
|
-
|
|
57
|
-
|
|
58
|
-
|
|
59
|
+
u as ThemeVariables,
|
|
60
|
+
f as resetCss,
|
|
61
|
+
x as theme,
|
|
59
62
|
l as themeStr
|
|
60
63
|
};
|
package/lib/ui/timer/index.d.ts
CHANGED
|
@@ -1,9 +1,10 @@
|
|
|
1
|
-
import React from 'react';
|
|
1
|
+
import { default as React } from 'react';
|
|
2
|
+
|
|
2
3
|
interface TimerProps {
|
|
3
4
|
isPlaying?: boolean;
|
|
4
5
|
duration?: number;
|
|
5
6
|
onTimerExpired?: () => void;
|
|
6
7
|
}
|
|
7
|
-
export declare const RemainingTime: import(
|
|
8
|
+
export declare const RemainingTime: import('@linaria/react').StyledComponent<React.ClassAttributes<HTMLDivElement> & React.HTMLAttributes<HTMLDivElement> & Record<never, unknown>>;
|
|
8
9
|
export declare const Timer: React.FC<TimerProps>;
|
|
9
10
|
export {};
|
package/lib/ui/timer/index.js
CHANGED
|
@@ -1,45 +1,45 @@
|
|
|
1
|
-
import { jsx as
|
|
2
|
-
import { styled as
|
|
3
|
-
import { useState as c, useEffect as
|
|
4
|
-
import { CountdownCircleTimer as
|
|
5
|
-
import {
|
|
6
|
-
const
|
|
1
|
+
import { jsx as r } from "react/jsx-runtime";
|
|
2
|
+
import { styled as M } from "@linaria/react";
|
|
3
|
+
import { useState as c, useEffect as _, useCallback as n } from "react";
|
|
4
|
+
import { CountdownCircleTimer as h } from "react-countdown-circle-timer";
|
|
5
|
+
import { TIMER_COLORS as p, TIMER_GREEN as E, TIMER_RED as S, TIMER_GRAY as g } from "../theme/constants.js";
|
|
6
|
+
const k = [10, 10, 1, 0], O = /* @__PURE__ */ M("div")({
|
|
7
7
|
name: "RemainingTime",
|
|
8
8
|
class: "r165427",
|
|
9
9
|
propsAsIs: !1
|
|
10
|
-
}),
|
|
10
|
+
}), u = E, l = S, m = g, L = ({
|
|
11
11
|
isPlaying: i = !0,
|
|
12
|
-
duration:
|
|
13
|
-
onTimerExpired:
|
|
12
|
+
duration: t = 30,
|
|
13
|
+
onTimerExpired: s
|
|
14
14
|
}) => {
|
|
15
|
-
const [
|
|
16
|
-
|
|
17
|
-
|
|
15
|
+
const [R, o] = c(t > 10 ? u : l), [f, a] = c(2);
|
|
16
|
+
_(() => {
|
|
17
|
+
t === 0 && (a(0), o(m));
|
|
18
|
+
}, [t]);
|
|
19
|
+
const C = ({
|
|
20
|
+
remainingTime: e
|
|
21
|
+
}) => /* @__PURE__ */ r(O, {
|
|
22
|
+
children: t === 0 ? 0 : e
|
|
23
|
+
}), T = n(() => {
|
|
24
|
+
s == null || s(), o(m);
|
|
25
|
+
}, [s, o]), I = n((e) => {
|
|
26
|
+
e === 10 && o(l);
|
|
18
27
|
}, [o]);
|
|
19
|
-
|
|
20
|
-
remainingTime: r
|
|
21
|
-
}) => /* @__PURE__ */ R(Y, {
|
|
22
|
-
children: o === 0 ? 0 : r
|
|
23
|
-
}), A = n(() => {
|
|
24
|
-
e == null || e(), s(m);
|
|
25
|
-
}, [e, s]), O = n((r) => {
|
|
26
|
-
r === 10 && s(l);
|
|
27
|
-
}, [s]);
|
|
28
|
-
return /* @__PURE__ */ R(N, {
|
|
28
|
+
return /* @__PURE__ */ r(h, {
|
|
29
29
|
isPlaying: i,
|
|
30
|
-
duration:
|
|
31
|
-
colors:
|
|
32
|
-
colorsTime:
|
|
30
|
+
duration: t,
|
|
31
|
+
colors: p,
|
|
32
|
+
colorsTime: k,
|
|
33
33
|
size: 32,
|
|
34
|
-
strokeWidth:
|
|
34
|
+
strokeWidth: f,
|
|
35
35
|
trailStrokeWidth: 2,
|
|
36
|
-
trailColor:
|
|
37
|
-
onComplete:
|
|
38
|
-
onUpdate:
|
|
39
|
-
children:
|
|
36
|
+
trailColor: R,
|
|
37
|
+
onComplete: T,
|
|
38
|
+
onUpdate: I,
|
|
39
|
+
children: C
|
|
40
40
|
});
|
|
41
41
|
};
|
|
42
42
|
export {
|
|
43
|
-
|
|
44
|
-
|
|
43
|
+
O as RemainingTime,
|
|
44
|
+
L as Timer
|
|
45
45
|
};
|
|
@@ -1,4 +1,3 @@
|
|
|
1
|
-
/// <reference types="react" />
|
|
2
1
|
type ControlVideoProps = {
|
|
3
2
|
muted: boolean;
|
|
4
3
|
};
|
|
@@ -6,6 +5,7 @@ export type VideoPlayerProps = {
|
|
|
6
5
|
poster?: string;
|
|
7
6
|
source?: string;
|
|
8
7
|
controlVideo?: (props: ControlVideoProps) => void;
|
|
8
|
+
aspectRatio?: string;
|
|
9
9
|
};
|
|
10
10
|
export declare const pauseAllVideos: () => void;
|
|
11
11
|
/**
|
|
@@ -1,77 +1,85 @@
|
|
|
1
|
-
import { jsxs as
|
|
2
|
-
import { cx as
|
|
3
|
-
import { useRef as
|
|
4
|
-
import { eventBus as
|
|
5
|
-
import { SvgIcon as
|
|
6
|
-
import { Container as
|
|
7
|
-
const
|
|
1
|
+
import { jsxs as C, jsx as o } from "react/jsx-runtime";
|
|
2
|
+
import { cx as E } from "@linaria/core";
|
|
3
|
+
import { useRef as S, useState as v, useCallback as d, useEffect as y } from "react";
|
|
4
|
+
import { eventBus as T } from "@streamlayer/sdk-web-interfaces";
|
|
5
|
+
import { SvgIcon as P } from "../icons/index.js";
|
|
6
|
+
import { Container as L, ToggleIconPause as j, Player as k, Poster as H, Control as M } from "./styles.js";
|
|
7
|
+
const A = (s, a) => {
|
|
8
8
|
for (const t of s)
|
|
9
9
|
t.isIntersecting || t.target instanceof HTMLVideoElement && !t.target.paused && (a.unobserve(t.target), t.target.pause());
|
|
10
|
-
},
|
|
11
|
-
|
|
12
|
-
},
|
|
13
|
-
|
|
14
|
-
},
|
|
15
|
-
for (const s of
|
|
16
|
-
s instanceof HTMLVideoElement && !s.paused && (s.pause(),
|
|
17
|
-
},
|
|
18
|
-
const e =
|
|
19
|
-
|
|
20
|
-
}, [
|
|
21
|
-
|
|
22
|
-
}, [
|
|
23
|
-
|
|
24
|
-
const
|
|
25
|
-
if (
|
|
26
|
-
if (
|
|
27
|
-
|
|
10
|
+
}, h = new IntersectionObserver(A, { threshold: 0.5 }), m = /* @__PURE__ */ new Set(), B = (s) => {
|
|
11
|
+
h.observe(s), m.add(s);
|
|
12
|
+
}, i = (s) => {
|
|
13
|
+
h.unobserve(s), m.delete(s);
|
|
14
|
+
}, F = () => {
|
|
15
|
+
for (const s of m)
|
|
16
|
+
s instanceof HTMLVideoElement && !s.paused && (s.pause(), i(s));
|
|
17
|
+
}, K = ({ poster: s, source: a, aspectRatio: t, controlVideo: r }) => {
|
|
18
|
+
const e = S(null), [c, l] = v(!1), [p, b] = v(!0), I = d(() => {
|
|
19
|
+
r == null || r({ muted: !0 });
|
|
20
|
+
}, [r]), u = d(() => {
|
|
21
|
+
r == null || r({ muted: !1 });
|
|
22
|
+
}, [r]), O = (n) => {
|
|
23
|
+
n.stopPropagation();
|
|
24
|
+
const g = e == null ? void 0 : e.current;
|
|
25
|
+
if (g) {
|
|
26
|
+
if (c)
|
|
27
|
+
g.pause(), e.current && i(e.current);
|
|
28
28
|
else {
|
|
29
|
-
const
|
|
30
|
-
if (!
|
|
29
|
+
const f = e == null ? void 0 : e.current;
|
|
30
|
+
if (!f)
|
|
31
31
|
return;
|
|
32
|
-
|
|
32
|
+
F(), B(f), f.play().catch((x) => console.log(x)), b(!1);
|
|
33
33
|
}
|
|
34
|
-
|
|
34
|
+
T.emit("interactions", {
|
|
35
35
|
action: "tap",
|
|
36
36
|
payload: {}
|
|
37
37
|
});
|
|
38
38
|
}
|
|
39
|
-
},
|
|
40
|
-
var
|
|
41
|
-
e.current &&
|
|
39
|
+
}, w = () => {
|
|
40
|
+
var n;
|
|
41
|
+
e.current && i(e.current), (n = e == null ? void 0 : e.current) == null || n.load(), b(!0);
|
|
42
42
|
};
|
|
43
|
-
return
|
|
44
|
-
e.current &&
|
|
45
|
-
}, []),
|
|
46
|
-
const
|
|
43
|
+
return y(() => {
|
|
44
|
+
e.current && i(e.current);
|
|
45
|
+
}, []), y(() => {
|
|
46
|
+
const n = e == null ? void 0 : e.current;
|
|
47
47
|
return () => {
|
|
48
|
-
|
|
48
|
+
n && (n.paused || u(), i(n));
|
|
49
49
|
};
|
|
50
|
-
}, [
|
|
51
|
-
|
|
52
|
-
|
|
53
|
-
|
|
54
|
-
|
|
55
|
-
|
|
56
|
-
|
|
57
|
-
|
|
58
|
-
|
|
59
|
-
|
|
60
|
-
|
|
61
|
-
|
|
62
|
-
|
|
63
|
-
|
|
64
|
-
|
|
65
|
-
|
|
66
|
-
|
|
67
|
-
|
|
68
|
-
|
|
69
|
-
|
|
70
|
-
|
|
71
|
-
|
|
72
|
-
|
|
50
|
+
}, [u]), /* @__PURE__ */ C(
|
|
51
|
+
L,
|
|
52
|
+
{
|
|
53
|
+
onClick: O,
|
|
54
|
+
className: E(c && j),
|
|
55
|
+
style: t ? { aspectRatio: t } : {},
|
|
56
|
+
children: [
|
|
57
|
+
/* @__PURE__ */ o(
|
|
58
|
+
k,
|
|
59
|
+
{
|
|
60
|
+
ref: e,
|
|
61
|
+
src: a,
|
|
62
|
+
onPlay: () => {
|
|
63
|
+
I(), l(!0);
|
|
64
|
+
},
|
|
65
|
+
onPause: () => {
|
|
66
|
+
u(), l(!1);
|
|
67
|
+
},
|
|
68
|
+
onEnded: () => {
|
|
69
|
+
u(), l(!1), w();
|
|
70
|
+
},
|
|
71
|
+
style: { visibility: p ? "hidden" : "visible" },
|
|
72
|
+
controls: !1,
|
|
73
|
+
playsInline: !0
|
|
74
|
+
}
|
|
75
|
+
),
|
|
76
|
+
/* @__PURE__ */ o(H, { src: s, style: { visibility: p ? "visible" : "hidden" } }),
|
|
77
|
+
/* @__PURE__ */ o(M, { children: c ? /* @__PURE__ */ o(P, { name: "icon-pause" }) : /* @__PURE__ */ o(P, { name: "icon-play" }) })
|
|
78
|
+
]
|
|
79
|
+
}
|
|
80
|
+
);
|
|
73
81
|
};
|
|
74
82
|
export {
|
|
75
|
-
|
|
76
|
-
|
|
83
|
+
K as VideoPlayer,
|
|
84
|
+
F as pauseAllVideos
|
|
77
85
|
};
|
|
@@ -1,6 +1,5 @@
|
|
|
1
|
-
|
|
2
|
-
export declare const
|
|
3
|
-
export declare const
|
|
4
|
-
export declare const
|
|
5
|
-
export declare const
|
|
6
|
-
export declare const ToggleIconPause: import("@linaria/core").LinariaClassName;
|
|
1
|
+
export declare const Container: import('@linaria/react').StyledComponent<import('react').ClassAttributes<HTMLDivElement> & import('react').HTMLAttributes<HTMLDivElement> & Record<never, unknown>>;
|
|
2
|
+
export declare const Player: import('@linaria/react').StyledComponent<import('react').ClassAttributes<HTMLVideoElement> & import('react').VideoHTMLAttributes<HTMLVideoElement> & Record<never, unknown>>;
|
|
3
|
+
export declare const Poster: import('@linaria/react').StyledComponent<import('react').ClassAttributes<HTMLImageElement> & import('react').ImgHTMLAttributes<HTMLImageElement> & Record<never, unknown>>;
|
|
4
|
+
export declare const Control: import('@linaria/react').StyledComponent<import('react').ClassAttributes<HTMLDivElement> & import('react').HTMLAttributes<HTMLDivElement> & Record<never, unknown>>;
|
|
5
|
+
export declare const ToggleIconPause: import('@linaria/core').LinariaClassName;
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
var n = Object.defineProperty;
|
|
2
2
|
var i = (s, r, e) => r in s ? n(s, r, { enumerable: !0, configurable: !0, writable: !0, value: e }) : s[r] = e;
|
|
3
|
-
var t = (s, r, e) =>
|
|
3
|
+
var t = (s, r, e) => i(s, typeof r != "symbol" ? r + "" : r, e);
|
|
4
4
|
import { Storage as h } from "@streamlayer/sdk-web-storage";
|
|
5
5
|
class d extends h {
|
|
6
6
|
constructor() {
|
package/lib/utils/storage.js
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
var n = Object.defineProperty;
|
|
2
2
|
var i = (s, r, e) => r in s ? n(s, r, { enumerable: !0, configurable: !0, writable: !0, value: e }) : s[r] = e;
|
|
3
|
-
var t = (s, r, e) =>
|
|
3
|
+
var t = (s, r, e) => i(s, typeof r != "symbol" ? r + "" : r, e);
|
|
4
4
|
import { Storage as h } from "@streamlayer/sdk-web-storage";
|
|
5
5
|
class d extends h {
|
|
6
6
|
constructor() {
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@streamlayer/react-ui",
|
|
3
|
-
"version": "1.
|
|
3
|
+
"version": "1.2.0",
|
|
4
4
|
"type": "module",
|
|
5
5
|
"main": "./src/index.js",
|
|
6
6
|
"typings": "./lib/index.d.ts",
|
|
@@ -11,19 +11,24 @@
|
|
|
11
11
|
"types": "./lib/index.d.ts"
|
|
12
12
|
},
|
|
13
13
|
"./masters": {
|
|
14
|
-
"import": "./lib/
|
|
15
|
-
"default": "./lib/
|
|
16
|
-
"types": "./lib/
|
|
14
|
+
"import": "./lib/app/masters/masters.js",
|
|
15
|
+
"default": "./lib/app/masters/masters.js",
|
|
16
|
+
"types": "./lib/app/masters/masters.d.ts"
|
|
17
17
|
},
|
|
18
18
|
"./mastersPoints": {
|
|
19
|
-
"import": "./lib/
|
|
20
|
-
"default": "./lib/
|
|
21
|
-
"types": "./lib/
|
|
19
|
+
"import": "./lib/app/masters/Points/index.js",
|
|
20
|
+
"default": "./lib/app/masters/Points/index.js",
|
|
21
|
+
"types": "./lib/app/masters/Points/index.d.ts"
|
|
22
22
|
},
|
|
23
23
|
"./points": {
|
|
24
|
-
"import": "./lib/
|
|
25
|
-
"default": "./lib/
|
|
26
|
-
"types": "./lib/
|
|
24
|
+
"import": "./lib/app/app/Points/index.js",
|
|
25
|
+
"default": "./lib/app/app/Points/index.js",
|
|
26
|
+
"types": "./lib/app/app/Points/index.d.ts"
|
|
27
|
+
},
|
|
28
|
+
"./advertisement": {
|
|
29
|
+
"import": "./lib/app/app/Advertisement/index.js",
|
|
30
|
+
"default": "./lib/app/app/Advertisement/index.js",
|
|
31
|
+
"types": "./lib/app/app/Advertisement/index.d.ts"
|
|
27
32
|
},
|
|
28
33
|
"./*": {
|
|
29
34
|
"import": "./lib/*/index.js",
|
|
@@ -40,8 +45,8 @@
|
|
|
40
45
|
"package.json"
|
|
41
46
|
],
|
|
42
47
|
"peerDependencies": {
|
|
43
|
-
"@lottiefiles/react-lottie-player": "^3.5.
|
|
44
|
-
"@streamlayer/sl-eslib": "^5.
|
|
48
|
+
"@lottiefiles/react-lottie-player": "^3.5.4",
|
|
49
|
+
"@streamlayer/sl-eslib": "^5.104.1",
|
|
45
50
|
"@types/lodash.throttle": "^4.1.9",
|
|
46
51
|
"lodash.throttle": "^4.1.1",
|
|
47
52
|
"nanoid": "3.3.7",
|
|
@@ -49,18 +54,18 @@
|
|
|
49
54
|
"react-virtualized-auto-sizer": "^1.0.24",
|
|
50
55
|
"react-window": "^1.8.10",
|
|
51
56
|
"react-window-infinite-loader": "^1.0.9",
|
|
52
|
-
"@streamlayer/feature-gamification": "^1.
|
|
53
|
-
"@streamlayer/sdk-web
|
|
54
|
-
"@streamlayer/sdk-web": "^1.0.
|
|
55
|
-
"@streamlayer/sdk-web-
|
|
56
|
-
"@streamlayer/sdk-web-
|
|
57
|
-
"@streamlayer/sdk-web-
|
|
58
|
-
"@streamlayer/sdk-web-features": "^1.0.
|
|
59
|
-
"@streamlayer/sdk-web-interfaces": "^1.0.
|
|
60
|
-
"@streamlayer/sdk-web-logger": "^1.0.
|
|
61
|
-
"@streamlayer/sdk-web-notifications": "^1.0.
|
|
62
|
-
"@streamlayer/sdk-web-storage": "^1.0.
|
|
63
|
-
"@streamlayer/sdk-web-types": "^1.
|
|
57
|
+
"@streamlayer/feature-gamification": "^1.2.0",
|
|
58
|
+
"@streamlayer/sdk-web": "^1.0.2",
|
|
59
|
+
"@streamlayer/sdk-web-analytics": "^1.0.2",
|
|
60
|
+
"@streamlayer/sdk-web-anonymous-auth": "^1.0.2",
|
|
61
|
+
"@streamlayer/sdk-web-api": "^1.1.1",
|
|
62
|
+
"@streamlayer/sdk-web-core": "^1.0.2",
|
|
63
|
+
"@streamlayer/sdk-web-features": "^1.0.2",
|
|
64
|
+
"@streamlayer/sdk-web-interfaces": "^1.0.2",
|
|
65
|
+
"@streamlayer/sdk-web-logger": "^1.0.2",
|
|
66
|
+
"@streamlayer/sdk-web-notifications": "^1.0.2",
|
|
67
|
+
"@streamlayer/sdk-web-storage": "^1.0.2",
|
|
68
|
+
"@streamlayer/sdk-web-types": "^1.1.1"
|
|
64
69
|
},
|
|
65
70
|
"nx": {
|
|
66
71
|
"implicitDependencies": [
|
|
@@ -73,33 +78,34 @@
|
|
|
73
78
|
"@esbuild-plugins/node-globals-polyfill": "^0.2.3",
|
|
74
79
|
"@esbuild-plugins/node-modules-polyfill": "^0.2.2",
|
|
75
80
|
"@linaria/babel-preset": "^5.0.4",
|
|
76
|
-
"@linaria/core": "^6.
|
|
77
|
-
"@linaria/react": "^6.
|
|
81
|
+
"@linaria/core": "^6.2.0",
|
|
82
|
+
"@linaria/react": "^6.2.1",
|
|
78
83
|
"@nanostores/react": "^0.7.2",
|
|
79
|
-
"@storybook/addon-docs": "^8.
|
|
80
|
-
"@storybook/addon-viewport": "^8.
|
|
81
|
-
"@storybook/blocks": "^8.
|
|
82
|
-
"@storybook/jest": "
|
|
83
|
-
"@storybook/react": "^8.
|
|
84
|
-
"@storybook/testing-library": "
|
|
84
|
+
"@storybook/addon-docs": "^8.1.11",
|
|
85
|
+
"@storybook/addon-viewport": "^8.1.11",
|
|
86
|
+
"@storybook/blocks": "^8.1.11",
|
|
87
|
+
"@storybook/jest": "^0.2.3",
|
|
88
|
+
"@storybook/react": "^8.1.11",
|
|
89
|
+
"@storybook/testing-library": "^0.2.2",
|
|
85
90
|
"@types/react-infinite-scroller": "^1.2.5",
|
|
86
91
|
"@types/react-window": "^1.8.8",
|
|
87
92
|
"@types/react-window-infinite-loader": "^1.0.9",
|
|
88
|
-
"@wyw-in-js/vite": "^0.
|
|
93
|
+
"@wyw-in-js/vite": "^0.5.3",
|
|
89
94
|
"esbuild-plugin-babel": "^0.2.3",
|
|
90
|
-
"glob": "^10.
|
|
91
|
-
"react": "18.
|
|
95
|
+
"glob": "^10.4.2",
|
|
96
|
+
"react": "18.3.1",
|
|
92
97
|
"react-auth-code-input": "^3.2.1",
|
|
93
98
|
"react-countdown-circle-timer": "^3.2.1",
|
|
94
|
-
"react-countup": "^6.5.
|
|
95
|
-
"react-phone-number-input": "^3.3
|
|
99
|
+
"react-countup": "^6.5.3",
|
|
100
|
+
"react-phone-number-input": "^3.4.3",
|
|
96
101
|
"rollup-plugin-node-polyfills": "^0.2.1",
|
|
97
|
-
"
|
|
98
|
-
"
|
|
99
|
-
"vite
|
|
102
|
+
"screenfull": "^6.0.2",
|
|
103
|
+
"tslib": "^2.6.3",
|
|
104
|
+
"vite": "5.3.2",
|
|
105
|
+
"vite-plugin-node-polyfills": "^0.22.0",
|
|
100
106
|
"vite-plugin-svgr": "^4.2.0",
|
|
101
107
|
"vite-svg-loader": "^5.1.0",
|
|
102
108
|
"vite-tsconfig-paths": "^4.3.2",
|
|
103
|
-
"@streamlayer/react": "^1.
|
|
109
|
+
"@streamlayer/react": "^1.1.1"
|
|
104
110
|
}
|
|
105
111
|
}
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
|
|
@@ -1,69 +0,0 @@
|
|
|
1
|
-
import { jsxs as u, jsx as e } from "react/jsx-runtime";
|
|
2
|
-
import { styled as l } from "@linaria/react";
|
|
3
|
-
import { useStore as n } from "@nanostores/react";
|
|
4
|
-
import { QuestionType as a } from "@streamlayer/sdk-web-types";
|
|
5
|
-
import { useAppContext as m } from "../../useAppContext.js";
|
|
6
|
-
import { VoteHeader as c } from "../../../../gamification/detail/header/index.js";
|
|
7
|
-
import { Sponsor as p } from "../../../../gamification/detail/sponsor/index.js";
|
|
8
|
-
import { Vote as f, VoteSkeleton as b } from "../../../../gamification/vote/index.js";
|
|
9
|
-
import { InsightDetails as y } from "../../../../gamification/vote/insight-details/index.js";
|
|
10
|
-
import { TwitterDetails as V } from "../../../../gamification/vote/twitter-details/index.js";
|
|
11
|
-
const x = /* @__PURE__ */ l("div")({
|
|
12
|
-
name: "QuestionContainer",
|
|
13
|
-
class: "qfnqmpg",
|
|
14
|
-
propsAsIs: !1
|
|
15
|
-
}), d = ({
|
|
16
|
-
openedQuestion: t
|
|
17
|
-
}) => {
|
|
18
|
-
var s, o;
|
|
19
|
-
const {
|
|
20
|
-
sdk: r
|
|
21
|
-
} = m();
|
|
22
|
-
return ((s = t == null ? void 0 : t.attributes) == null ? void 0 : s.attributes.case) === "insight" ? /* @__PURE__ */ e(y, {
|
|
23
|
-
...t.attributes.attributes.value,
|
|
24
|
-
controlVideo: r == null ? void 0 : r.controlVideoPlayer
|
|
25
|
-
}) : ((o = t == null ? void 0 : t.attributes) == null ? void 0 : o.attributes.case) === "tweet" ? /* @__PURE__ */ e(V, {
|
|
26
|
-
...t.attributes.attributes.value,
|
|
27
|
-
controlVideo: r == null ? void 0 : r.controlVideoPlayer
|
|
28
|
-
}) : null;
|
|
29
|
-
}, h = ({
|
|
30
|
-
extendedQuestion: t,
|
|
31
|
-
vote: r,
|
|
32
|
-
close: s
|
|
33
|
-
}) => {
|
|
34
|
-
const {
|
|
35
|
-
loading: o,
|
|
36
|
-
data: i
|
|
37
|
-
} = t;
|
|
38
|
-
return i ? /* @__PURE__ */ e(f, {
|
|
39
|
-
vote: r,
|
|
40
|
-
close: s,
|
|
41
|
-
openedQuestion: i,
|
|
42
|
-
isLoading: !!o
|
|
43
|
-
}) : /* @__PURE__ */ e(b, {});
|
|
44
|
-
}, j = ({
|
|
45
|
-
gamification: t
|
|
46
|
-
}) => {
|
|
47
|
-
var i;
|
|
48
|
-
const r = n(t.openedQuestion.$store), s = n(t.openedQuestion.$extendedStore);
|
|
49
|
-
if (!r)
|
|
50
|
-
return null;
|
|
51
|
-
const o = r.type;
|
|
52
|
-
return /* @__PURE__ */ u(x, {
|
|
53
|
-
children: [/* @__PURE__ */ e(c, {
|
|
54
|
-
close: t.closeQuestion,
|
|
55
|
-
type: ((i = r.attributes) == null ? void 0 : i.type) || a.UNSET
|
|
56
|
-
}), o === "question" && /* @__PURE__ */ e(h, {
|
|
57
|
-
vote: t.submitAnswer,
|
|
58
|
-
close: t.closeQuestion,
|
|
59
|
-
extendedQuestion: s
|
|
60
|
-
}), o !== "question" && /* @__PURE__ */ e(d, {
|
|
61
|
-
openedQuestion: r
|
|
62
|
-
}), /* @__PURE__ */ e(p, {
|
|
63
|
-
sponsorLogo: ""
|
|
64
|
-
})]
|
|
65
|
-
});
|
|
66
|
-
};
|
|
67
|
-
export {
|
|
68
|
-
j as Question
|
|
69
|
-
};
|
|
@@ -1,88 +0,0 @@
|
|
|
1
|
-
import { jsx as o, jsxs as f } from "react/jsx-runtime";
|
|
2
|
-
import { styled as m } from "@linaria/react";
|
|
3
|
-
import { useStore as c } from "@nanostores/react";
|
|
4
|
-
import { useHideTransition as h } from "../../../../../hooks/showIn.js";
|
|
5
|
-
import { SDKWhiteContainer as C } from "../../../styles.js";
|
|
6
|
-
import { VoteHeader as k } from "../../../../gamification/detail/header/index.js";
|
|
7
|
-
import { UserStatistics as S } from "../../../../gamification/user-statistics/index.js";
|
|
8
|
-
import { ModalPortal as U } from "../../../../modal/index.js";
|
|
9
|
-
import { ShowIn as y } from "../../../../show-in/index.js";
|
|
10
|
-
import { Question as I } from "./Question.js";
|
|
11
|
-
import { Tabs as x } from "./Tabs.js";
|
|
12
|
-
const O = () => y, p = /* @__PURE__ */ m(O())({
|
|
13
|
-
name: "OpenedContainer",
|
|
14
|
-
class: "o1o2cpiy",
|
|
15
|
-
propsAsIs: !0
|
|
16
|
-
}), b = /* @__PURE__ */ m("div")({
|
|
17
|
-
name: "UserContainer",
|
|
18
|
-
class: "u1ob6f8q",
|
|
19
|
-
propsAsIs: !1
|
|
20
|
-
}), v = ({
|
|
21
|
-
correct: e,
|
|
22
|
-
incorrect: r
|
|
23
|
-
}) => {
|
|
24
|
-
const n = e + r;
|
|
25
|
-
return n === 0 ? 0 : Math.round(e / n * 100);
|
|
26
|
-
}, q = ({
|
|
27
|
-
gamification: e,
|
|
28
|
-
scrollStore: r,
|
|
29
|
-
className: n,
|
|
30
|
-
appNode: i,
|
|
31
|
-
scrollNode: s,
|
|
32
|
-
responsiveStore: t
|
|
33
|
-
}) => /* @__PURE__ */ o(x, {
|
|
34
|
-
appNode: i,
|
|
35
|
-
scrollStore: r,
|
|
36
|
-
scrollNode: s,
|
|
37
|
-
className: n,
|
|
38
|
-
gamification: e,
|
|
39
|
-
responsiveStore: t
|
|
40
|
-
}), E = ({
|
|
41
|
-
gamification: e,
|
|
42
|
-
className: r,
|
|
43
|
-
appNode: n,
|
|
44
|
-
responsiveStore: i
|
|
45
|
-
}) => {
|
|
46
|
-
const s = c(e.openedQuestion.$store), t = c(e.openedUser), {
|
|
47
|
-
sdkInDesktopView: d
|
|
48
|
-
} = c(i, {
|
|
49
|
-
keys: ["sdkInDesktopView"]
|
|
50
|
-
}), {
|
|
51
|
-
hiding: a,
|
|
52
|
-
onAnimationEnd: l
|
|
53
|
-
} = h();
|
|
54
|
-
if (!n.current || !s && !t)
|
|
55
|
-
return null;
|
|
56
|
-
const u = s ? /* @__PURE__ */ o(p, {
|
|
57
|
-
className: r,
|
|
58
|
-
hiding: a,
|
|
59
|
-
onAnimationEnd: l,
|
|
60
|
-
children: /* @__PURE__ */ o(I, {
|
|
61
|
-
gamification: e
|
|
62
|
-
})
|
|
63
|
-
}) : t ? /* @__PURE__ */ o(p, {
|
|
64
|
-
className: r,
|
|
65
|
-
hiding: a,
|
|
66
|
-
onAnimationEnd: l,
|
|
67
|
-
children: /* @__PURE__ */ f(b, {
|
|
68
|
-
children: [/* @__PURE__ */ o(k, {
|
|
69
|
-
label: "Friend's Rank",
|
|
70
|
-
close: e.closeUser
|
|
71
|
-
}), /* @__PURE__ */ o(C, {
|
|
72
|
-
children: /* @__PURE__ */ o(S, {
|
|
73
|
-
...t,
|
|
74
|
-
successRate: v(t)
|
|
75
|
-
})
|
|
76
|
-
})]
|
|
77
|
-
})
|
|
78
|
-
}) : null;
|
|
79
|
-
return /* @__PURE__ */ o(U, {
|
|
80
|
-
container: n,
|
|
81
|
-
useContainer: !d,
|
|
82
|
-
children: u
|
|
83
|
-
});
|
|
84
|
-
};
|
|
85
|
-
export {
|
|
86
|
-
q as GamificationOverlay,
|
|
87
|
-
E as GamificationOverlayStandalone
|
|
88
|
-
};
|