@streamlayer/react-ui 0.72.0 → 0.74.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/assets/style.css +1 -1
- package/lib/ui/app/Features/Gamification/Friends.js +9 -9
- package/lib/ui/app/Features/Gamification/Question.js +27 -24
- package/lib/ui/app/Features/Gamification/gamification-feature.js +1 -0
- package/lib/ui/app/Features/Gamification/index.js +3 -2
- package/lib/ui/app/masters.d.ts +2 -2
- package/lib/ui/app/masters.js +20 -20
- package/lib/ui/app/useMastersApp.d.ts +4 -4
- package/lib/ui/app/useMastersApp.js +21 -21
- package/lib/ui/gamification/detail/sponsor/index.js +11 -12
- package/lib/ui/gamification/onboarding/slides/onboarding-invite-card/styles.js +8 -8
- package/lib/ui/icons/index.d.ts +1 -0
- package/lib/ui/icons/index.js +53 -50
- package/package.json +8 -8
|
@@ -1,9 +1,9 @@
|
|
|
1
1
|
import { useStore as m } from "@nanostores/react";
|
|
2
|
-
import { useRef as y, useState as
|
|
3
|
-
import { FeatureType as
|
|
2
|
+
import { useRef as y, useState as v, useCallback as F, useEffect as d } from "react";
|
|
3
|
+
import { FeatureType as I } from "@streamlayer/sdk-web-types";
|
|
4
4
|
import "react/jsx-runtime";
|
|
5
5
|
import { ChannelsButtonId as c } from "../navigation/button/Channels.js";
|
|
6
|
-
import { FeaturedGroupsButtonId as
|
|
6
|
+
import { FeaturedGroupsButtonId as a } from "../navigation/button/FeaturedGroups.js";
|
|
7
7
|
import "@linaria/react";
|
|
8
8
|
import "../icons/index.js";
|
|
9
9
|
import "../navigation/button/styles.js";
|
|
@@ -11,26 +11,26 @@ import "../../LeaderBoard_16p26hz-4ed993c7.js";
|
|
|
11
11
|
import "../../index_4nhkck-4ed993c7.js";
|
|
12
12
|
import "../../masters_k70xsy-4ed993c7.js";
|
|
13
13
|
import "../navigation/button/index.js";
|
|
14
|
-
const
|
|
15
|
-
const
|
|
14
|
+
const j = (e) => {
|
|
15
|
+
const n = y(""), [f, l] = v(!1), A = m(e.status), r = m(e.userId()), i = A === "ready", [s, u] = v(a), p = F(
|
|
16
16
|
(t, o) => {
|
|
17
|
-
u(o), o ===
|
|
17
|
+
u(o), o === a ? (t && e.createEventSession(t), e.openFeature(I.GAMES)) : e.closeFeature();
|
|
18
18
|
},
|
|
19
19
|
[e]
|
|
20
20
|
);
|
|
21
|
-
|
|
22
|
-
!i && s ===
|
|
21
|
+
d(() => {
|
|
22
|
+
!i && s === a && (u(c), e.closeFeature());
|
|
23
23
|
}, [i, s, e]);
|
|
24
|
-
const
|
|
25
|
-
|
|
26
|
-
if (
|
|
24
|
+
const E = (t) => {
|
|
25
|
+
n.current = t, e.initializeApp().then(({ enabled: o, err: b }) => {
|
|
26
|
+
if (l(!0), b) {
|
|
27
27
|
p(t, c);
|
|
28
28
|
return;
|
|
29
29
|
}
|
|
30
30
|
if (o) {
|
|
31
31
|
e.isUserAuthorized().then((h) => {
|
|
32
32
|
if (h) {
|
|
33
|
-
p(t,
|
|
33
|
+
p(t, a);
|
|
34
34
|
return;
|
|
35
35
|
} else
|
|
36
36
|
e.disableApp();
|
|
@@ -38,27 +38,27 @@ const q = (e) => {
|
|
|
38
38
|
return;
|
|
39
39
|
}
|
|
40
40
|
});
|
|
41
|
-
},
|
|
42
|
-
|
|
41
|
+
}, S = () => {
|
|
42
|
+
l(!1), e.disableApp();
|
|
43
43
|
};
|
|
44
|
-
return
|
|
44
|
+
return d(() => {
|
|
45
45
|
if (!r) {
|
|
46
46
|
i && (u(c), e.disableApp());
|
|
47
47
|
return;
|
|
48
48
|
}
|
|
49
|
-
r &&
|
|
50
|
-
e.createEventSession(
|
|
49
|
+
r && n.current && f && e.initializeApp().then(() => {
|
|
50
|
+
e.createEventSession(n.current);
|
|
51
51
|
});
|
|
52
52
|
}, [r]), {
|
|
53
|
-
sdkEnabled:
|
|
53
|
+
sdkEnabled: f,
|
|
54
54
|
sdkReady: i,
|
|
55
55
|
activeOverlay: s,
|
|
56
56
|
activateAndLoadOverlay: p,
|
|
57
|
-
|
|
58
|
-
|
|
57
|
+
activateEventWithId: E,
|
|
58
|
+
deactivate: S,
|
|
59
59
|
isLogged: !!r
|
|
60
60
|
};
|
|
61
61
|
};
|
|
62
62
|
export {
|
|
63
|
-
|
|
63
|
+
j as useMastersApp
|
|
64
64
|
};
|
|
@@ -1,21 +1,20 @@
|
|
|
1
|
-
import { jsx as
|
|
2
|
-
import { styled as
|
|
3
|
-
|
|
1
|
+
import { jsx as o } from "react/jsx-runtime";
|
|
2
|
+
import { styled as s } from "@linaria/react";
|
|
3
|
+
import { SvgIcon as r } from "../../../icons/index.js";
|
|
4
|
+
import "react";
|
|
5
|
+
const p = /* @__PURE__ */ s("div")({
|
|
4
6
|
name: "SponsorLogoWrap",
|
|
5
7
|
class: "s8p5v5z",
|
|
6
8
|
propsAsIs: !1
|
|
7
|
-
}), n = /* @__PURE__ */
|
|
9
|
+
}), n = () => r, t = /* @__PURE__ */ s(n())({
|
|
8
10
|
name: "SponsorLogo",
|
|
9
11
|
class: "s755yti",
|
|
10
|
-
propsAsIs: !
|
|
11
|
-
}),
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
children: /* @__PURE__ */ s(n, {
|
|
15
|
-
alt: "sponsor-logo",
|
|
16
|
-
src: o
|
|
12
|
+
propsAsIs: !0
|
|
13
|
+
}), i = () => /* @__PURE__ */ o(p, {
|
|
14
|
+
children: /* @__PURE__ */ o(t, {
|
|
15
|
+
name: "mastersLogo"
|
|
17
16
|
})
|
|
18
17
|
});
|
|
19
18
|
export {
|
|
20
|
-
|
|
19
|
+
i as Sponsor
|
|
21
20
|
};
|
|
@@ -10,7 +10,7 @@ const l = /* @__PURE__ */ s("div")({
|
|
|
10
10
|
name: "IconContainer",
|
|
11
11
|
class: "i1w4fsni",
|
|
12
12
|
propsAsIs: !1
|
|
13
|
-
}),
|
|
13
|
+
}), a = () => n, r = /* @__PURE__ */ s(a())({
|
|
14
14
|
name: "InviteGameIcon",
|
|
15
15
|
class: "i19m85r1",
|
|
16
16
|
propsAsIs: !0
|
|
@@ -26,15 +26,15 @@ const l = /* @__PURE__ */ s("div")({
|
|
|
26
26
|
name: "Subtext",
|
|
27
27
|
class: "s1lhlj9j",
|
|
28
28
|
propsAsIs: !1
|
|
29
|
-
}),
|
|
29
|
+
}), f = /* @__PURE__ */ s("div")({
|
|
30
30
|
name: "LinkContainer",
|
|
31
31
|
class: "l1wot35e",
|
|
32
32
|
propsAsIs: !1
|
|
33
|
-
}),
|
|
33
|
+
}), L = /* @__PURE__ */ s("div")({
|
|
34
34
|
name: "LinkInfo",
|
|
35
35
|
class: "l1jdw39q",
|
|
36
36
|
propsAsIs: !1
|
|
37
|
-
}),
|
|
37
|
+
}), d = /* @__PURE__ */ s("span")({
|
|
38
38
|
name: "LinkTitle",
|
|
39
39
|
class: "l1cr5mk",
|
|
40
40
|
propsAsIs: !1
|
|
@@ -42,7 +42,7 @@ const l = /* @__PURE__ */ s("div")({
|
|
|
42
42
|
name: "LinkAddress",
|
|
43
43
|
class: "lvi87q4",
|
|
44
44
|
propsAsIs: !1
|
|
45
|
-
}),
|
|
45
|
+
}), o = () => n, v = /* @__PURE__ */ s(o())({
|
|
46
46
|
name: "LinkIcon",
|
|
47
47
|
class: "l1pqlvw3",
|
|
48
48
|
propsAsIs: !0
|
|
@@ -66,10 +66,10 @@ export {
|
|
|
66
66
|
p as IconContainer,
|
|
67
67
|
r as InviteGameIcon,
|
|
68
68
|
A as LinkAddress,
|
|
69
|
-
|
|
69
|
+
f as LinkContainer,
|
|
70
70
|
v as LinkIcon,
|
|
71
|
-
|
|
72
|
-
|
|
71
|
+
L as LinkInfo,
|
|
72
|
+
d as LinkTitle,
|
|
73
73
|
S as SocialLink,
|
|
74
74
|
b as SocialLinkLabel,
|
|
75
75
|
C as SocialLinksContainer,
|