@streamlayer/react-ui 0.47.0 → 0.49.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/index.js +34 -32
- package/lib/ui/app/Features/Gamification/Question.js +22 -56
- package/lib/ui/app/Features/Gamification/index.js +12 -9
- package/lib/ui/app/Features/index.js +11 -8
- package/lib/ui/app/masters.js +11 -8
- package/lib/ui/demo/Gamification.js +6 -4
- package/lib/ui/demo/Highlights.js +6 -4
- package/lib/ui/demo/components/Question.js +22 -20
- package/lib/ui/demo/components/index.js +18 -16
- package/lib/ui/demo/index.js +6 -4
- package/lib/ui/gamification/detail/sponsor/index.d.ts +4 -0
- package/lib/ui/gamification/detail/sponsor/index.js +14 -0
- package/lib/ui/gamification/points/styles.js +8 -8
- package/lib/ui/gamification/vote/feedback/index.d.ts +14 -0
- package/lib/ui/gamification/vote/feedback/index.js +33 -0
- package/lib/ui/gamification/vote/feedback/styles.d.ts +8 -0
- package/lib/ui/gamification/vote/feedback/styles.js +70 -0
- package/lib/ui/gamification/vote/index.d.ts +3 -8
- package/lib/ui/gamification/vote/index.js +62 -49
- package/lib/ui/gamification/vote/insight-details/index.d.ts +10 -0
- package/lib/ui/gamification/vote/insight-details/index.js +21 -0
- package/lib/ui/gamification/vote/insight-details/styles.d.ts +6 -0
- package/lib/ui/gamification/vote/insight-details/styles.js +43 -0
- package/lib/ui/gamification/vote/styles.d.ts +1 -5
- package/lib/ui/gamification/vote/styles.js +18 -53
- package/lib/ui/gamification/vote/vote-option/index.d.ts +9 -17
- package/lib/ui/gamification/vote/vote-option/index.js +53 -5
- package/lib/ui/gamification/vote/vote-option/styles.d.ts +12 -8
- package/lib/ui/gamification/vote/vote-option/styles.js +119 -66
- package/lib/ui/icons/index.d.ts +4 -0
- package/lib/ui/icons/index.js +30 -26
- package/lib/ui/video-player/index.d.ts +33 -0
- package/lib/ui/video-player/index.js +30 -0
- package/lib/ui/video-player/styles.d.ts +5 -0
- package/lib/ui/video-player/styles.js +29 -0
- package/package.json +10 -10
- package/lib/index-7f3361f2.js +0 -71
- package/lib/ui/gamification/vote/types.d.js +0 -1
- /package/lib/ui/gamification/{vote → detail}/header/index.d.ts +0 -0
- /package/lib/ui/gamification/{vote → detail}/header/index.js +0 -0
- /package/lib/ui/gamification/{vote → detail}/header/styles.d.ts +0 -0
- /package/lib/ui/gamification/{vote → detail}/header/styles.js +0 -0
|
@@ -0,0 +1,29 @@
|
|
|
1
|
+
import { styled as o } from "@linaria/react";
|
|
2
|
+
const i = o.div`
|
|
3
|
+
display: flex;
|
|
4
|
+
position: relative;
|
|
5
|
+
border-radius: 8px;
|
|
6
|
+
overflow: hidden;
|
|
7
|
+
cursor: pointer;
|
|
8
|
+
`, e = o.video`
|
|
9
|
+
width: 100%;
|
|
10
|
+
`, r = o.img`
|
|
11
|
+
position: absolute;
|
|
12
|
+
top: 0;
|
|
13
|
+
left: 0;
|
|
14
|
+
width: 100%;
|
|
15
|
+
height: 100%;
|
|
16
|
+
`, s = o.div`
|
|
17
|
+
display: flex;
|
|
18
|
+
position: absolute;
|
|
19
|
+
top: 50%;
|
|
20
|
+
left: 50%;
|
|
21
|
+
transform: translate(-50%, -50%);
|
|
22
|
+
cursor: pointer;
|
|
23
|
+
`;
|
|
24
|
+
export {
|
|
25
|
+
i as Container,
|
|
26
|
+
s as Control,
|
|
27
|
+
e as Player,
|
|
28
|
+
r as Poster
|
|
29
|
+
};
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@streamlayer/react-ui",
|
|
3
|
-
"version": "0.
|
|
3
|
+
"version": "0.49.0",
|
|
4
4
|
"type": "module",
|
|
5
5
|
"main": "./src/index.js",
|
|
6
6
|
"typings": "./lib/index.d.ts",
|
|
@@ -30,16 +30,16 @@
|
|
|
30
30
|
"react-virtualized-auto-sizer": "^1.0.20",
|
|
31
31
|
"react-window": "^1.8.9",
|
|
32
32
|
"react-window-infinite-loader": "^1.0.9",
|
|
33
|
-
"@streamlayer/feature-gamification": "^0.19.
|
|
34
|
-
"@streamlayer/sdk-web
|
|
35
|
-
"@streamlayer/sdk-web": "^0.
|
|
33
|
+
"@streamlayer/feature-gamification": "^0.19.1",
|
|
34
|
+
"@streamlayer/sdk-web": "^0.28.8",
|
|
35
|
+
"@streamlayer/sdk-web-anonymous-auth": "^0.11.3",
|
|
36
36
|
"@streamlayer/sdk-web-api": "^0.1.0",
|
|
37
|
-
"@streamlayer/sdk-web-core": "^0.16.
|
|
38
|
-
"@streamlayer/sdk-web-features": "^0.10.
|
|
39
|
-
"@streamlayer/sdk-web-interfaces": "^0.18.
|
|
40
|
-
"@streamlayer/sdk-web-notifications": "^0.10.
|
|
37
|
+
"@streamlayer/sdk-web-core": "^0.16.3",
|
|
38
|
+
"@streamlayer/sdk-web-features": "^0.10.11",
|
|
39
|
+
"@streamlayer/sdk-web-interfaces": "^0.18.8",
|
|
40
|
+
"@streamlayer/sdk-web-notifications": "^0.10.7",
|
|
41
41
|
"@streamlayer/sdk-web-storage": "^0.3.9",
|
|
42
|
-
"@streamlayer/sdk-web-types": "^0.
|
|
42
|
+
"@streamlayer/sdk-web-types": "^0.17.0"
|
|
43
43
|
},
|
|
44
44
|
"nx": {
|
|
45
45
|
"implicitDependencies": [
|
|
@@ -78,6 +78,6 @@
|
|
|
78
78
|
"vite-plugin-svgr": "^4.1.0",
|
|
79
79
|
"vite-svg-loader": "^4.0.0",
|
|
80
80
|
"vite-tsconfig-paths": "^4.2.1",
|
|
81
|
-
"@streamlayer/react": "^0.24.
|
|
81
|
+
"@streamlayer/react": "^0.24.10"
|
|
82
82
|
}
|
|
83
83
|
}
|
package/lib/index-7f3361f2.js
DELETED
|
@@ -1,71 +0,0 @@
|
|
|
1
|
-
import { jsxs as N, jsx as M } from "react/jsx-runtime";
|
|
2
|
-
import { QuestionType as w } from "@streamlayer/sdk-web-types";
|
|
3
|
-
import { AnsweredContainer as k, ButtonPct as L, Button as O, Icon as l, Title as E, Indicators as u, CheckIconWrap as S, CheckIcon as n, Percentage as i, Container as r } from "./ui/gamification/vote/vote-option/styles.js";
|
|
4
|
-
const o = "data:image/svg+xml;base64,PHN2ZyB3aWR0aD0iMjQiIGhlaWdodD0iMjQiIHZpZXdCb3g9IjAgMCAyNCAyNCIgZmlsbD0ibm9uZSIgeG1sbnM9Imh0dHA6Ly93d3cudzMub3JnLzIwMDAvc3ZnIj4KPGcgaWQ9IkNoZWNrbWFyayI+CjxwYXRoIGlkPSJTZWxlY3RlZCIgZmlsbC1ydWxlPSJldmVub2RkIiBjbGlwLXJ1bGU9ImV2ZW5vZGQiIGQ9Ik0yNCAxMi4wMDJDMjQgMTguNjI5NCAxOC42Mjc0IDI0LjAwMiAxMiAyNC4wMDJDNS4zNzI1OCAyNC4wMDIgMCAxOC42Mjk0IDAgMTIuMDAyQzAgNS4zNzQ1NCA1LjM3MjU4IDAuMDAxOTUzMTIgMTIgMC4wMDE5NTMxMkMxOC42Mjc0IDAuMDAxOTUzMTIgMjQgNS4zNzQ1NCAyNCAxMi4wMDJaTTE3LjQwODYgOC4xNTM1N0MxNi45NCA3LjY4NDk0IDE2LjE4MDIgNy42ODQ5NCAxNS43MTE2IDguMTUzNTdMMTAuNDA3MiAxNC45NTc5TDcuNjI1NzMgMTMuMTAzNkM3LjA3NDI5IDEyLjczNiA2LjMyOTI1IDEyLjg4NSA1Ljk2MTYzIDEzLjQzNjVDNS41OTQwMSAxMy45ODc5IDUuNzQzMDEgMTQuNzMyOSA2LjI5NDQ1IDE1LjEwMDZMOS44OTQ0NSAxNy41MDA2QzEwLjM3MDQgMTcuODE3OSAxMS4wMDQxIDE3Ljc1NTEgMTEuNDA4NiAxNy4zNTA2TDE3LjQwODYgOS44NTA2M0MxNy44NzcyIDkuMzgyIDE3Ljg3NzIgOC42MjIyIDE3LjQwODYgOC4xNTM1N1oiIGZpbGw9IiMwMEJENjAiLz4KPC9nPgo8L3N2Zz4K", a = "data:image/svg+xml;base64,PH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,
|
|
12
|
-
toggleIsLoadingSubmitAnswer: t,
|
|
13
|
-
correct: j,
|
|
14
|
-
questionAnswered: I,
|
|
15
|
-
hasCorrectAnswer: T,
|
|
16
|
-
answered: g,
|
|
17
|
-
points: Z,
|
|
18
|
-
questionType: d
|
|
19
|
-
}) => {
|
|
20
|
-
var Q;
|
|
21
|
-
return I && g ? /* @__PURE__ */ N(
|
|
22
|
-
k,
|
|
23
|
-
{
|
|
24
|
-
"data-answeredCorrect": (Q = !T || j) == null ? void 0 : Q.toString(),
|
|
25
|
-
"data-questionAnswered": "false",
|
|
26
|
-
children: [
|
|
27
|
-
/* @__PURE__ */ M(L, { style: { width: `${A}%` } }),
|
|
28
|
-
/* @__PURE__ */ N(O, { disabled: x, onClick: () => y(z, C), children: [
|
|
29
|
-
D && /* @__PURE__ */ M(l, { alt: "option-icon", src: D }),
|
|
30
|
-
/* @__PURE__ */ M(E, { children: c }),
|
|
31
|
-
/* @__PURE__ */ N(u, { children: [
|
|
32
|
-
T && j && /* @__PURE__ */ M(S, { children: /* @__PURE__ */ M(n, { alt: "icon-correct", src: g ? a : o }) }),
|
|
33
|
-
/* @__PURE__ */ N(i, { children: [
|
|
34
|
-
A,
|
|
35
|
-
"%"
|
|
36
|
-
] })
|
|
37
|
-
] })
|
|
38
|
-
] })
|
|
39
|
-
]
|
|
40
|
-
}
|
|
41
|
-
) : /* @__PURE__ */ N(r, { "data-questionAnswered": I == null ? void 0 : I.toString(), children: [
|
|
42
|
-
I && /* @__PURE__ */ M(L, { style: { width: `${A}%` } }),
|
|
43
|
-
/* @__PURE__ */ N(
|
|
44
|
-
O,
|
|
45
|
-
{
|
|
46
|
-
disabled: x,
|
|
47
|
-
onClick: () => {
|
|
48
|
-
t(!0), y(z, C);
|
|
49
|
-
},
|
|
50
|
-
children: [
|
|
51
|
-
D && /* @__PURE__ */ M(l, { alt: "option-icon", src: D }),
|
|
52
|
-
/* @__PURE__ */ M(E, { children: c }),
|
|
53
|
-
I ? /* @__PURE__ */ N(u, { children: [
|
|
54
|
-
T && j && /* @__PURE__ */ M(S, { children: /* @__PURE__ */ M(n, { alt: "icon-correct", src: g ? a : o }) }),
|
|
55
|
-
/* @__PURE__ */ N(i, { children: [
|
|
56
|
-
A,
|
|
57
|
-
"%"
|
|
58
|
-
] })
|
|
59
|
-
] }) : d === w.PREDICTION ? /* @__PURE__ */ N(i, { children: [
|
|
60
|
-
Z,
|
|
61
|
-
" pts"
|
|
62
|
-
] }) : null
|
|
63
|
-
]
|
|
64
|
-
}
|
|
65
|
-
)
|
|
66
|
-
] });
|
|
67
|
-
};
|
|
68
|
-
export {
|
|
69
|
-
G as V,
|
|
70
|
-
o as c
|
|
71
|
-
};
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|