@streamlayer/react-ui 0.44.0 → 0.46.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 +31 -30
- package/lib/ui/app/Features/Gamification/Leaderboard.js +21 -21
- package/lib/ui/demo/DemoPoints.js +7 -4
- package/lib/ui/demo/index.js +86 -47
- package/lib/ui/gamification/points/index.d.ts +4 -2
- package/lib/ui/gamification/points/index.js +10 -7
- package/lib/ui/gamification/points/styles.js +67 -28
- package/lib/ui/theme/breakpoints.d.ts +6 -0
- package/lib/ui/theme/breakpoints.js +18 -0
- package/lib/ui/theme/constants.d.ts +7 -0
- package/lib/ui/theme/constants.js +7 -0
- package/package.json +8 -8
package/lib/index.js
CHANGED
|
@@ -1,16 +1,16 @@
|
|
|
1
|
-
import { QuestionInApp as
|
|
2
|
-
import { Login as
|
|
3
|
-
import { Onboarding as
|
|
4
|
-
import { ActivePages as
|
|
5
|
-
import { LeaderboardItemDetail as
|
|
6
|
-
import { Question as
|
|
7
|
-
import { QuestionList as
|
|
8
|
-
import { UserStatistics as
|
|
9
|
-
import { Vote as
|
|
10
|
-
import { Demo as
|
|
11
|
-
import { Points as
|
|
12
|
-
import { StreamLayerThemeProvider as
|
|
13
|
-
import { ThemeVariables as
|
|
1
|
+
import { QuestionInApp as yo } from "./ui/notifications/notification/question-inapp/index.js";
|
|
2
|
+
import { Login as Uo } from "./ui/login/index.js";
|
|
3
|
+
import { Onboarding as ko } from "./ui/gamification/onboarding/index.js";
|
|
4
|
+
import { ActivePages as wo, Tab as zo, Tabs as Bo } from "./ui/gamification/tabs/index.js";
|
|
5
|
+
import { LeaderboardItemDetail as Eo } from "./ui/gamification/leaderboard-item-detail/index.js";
|
|
6
|
+
import { Question as Go } from "./ui/gamification/question/index.js";
|
|
7
|
+
import { QuestionList as Jo } from "./ui/gamification/question/list/index.js";
|
|
8
|
+
import { UserStatistics as Mo } from "./ui/gamification/user-statistics/index.js";
|
|
9
|
+
import { Vote as Ro } from "./ui/gamification/vote/index.js";
|
|
10
|
+
import { Demo as Xo } from "./ui/demo/index.js";
|
|
11
|
+
import { Points as Zo } from "./ui/gamification/points/index.js";
|
|
12
|
+
import { StreamLayerThemeProvider as $o } from "./ui/theme/index.js";
|
|
13
|
+
import { ThemeVariables as rr, theme as tr, themeStr as mr } from "./ui/theme/theme.js";
|
|
14
14
|
import "react/jsx-runtime";
|
|
15
15
|
import "react";
|
|
16
16
|
import "./icon-exit-d3f9fc80.js";
|
|
@@ -89,23 +89,24 @@ import "./ui/gamification/detailed-insight/index.js";
|
|
|
89
89
|
import "./ui/demo/Login.js";
|
|
90
90
|
import "@streamlayer/sdk-web-anonymous-auth";
|
|
91
91
|
import "./ui/gamification/points/styles.js";
|
|
92
|
+
import "./ui/theme/breakpoints.js";
|
|
92
93
|
import "@linaria/core";
|
|
93
94
|
export {
|
|
94
|
-
|
|
95
|
-
|
|
96
|
-
|
|
97
|
-
|
|
98
|
-
|
|
99
|
-
|
|
100
|
-
|
|
101
|
-
|
|
102
|
-
|
|
103
|
-
|
|
104
|
-
|
|
105
|
-
|
|
106
|
-
|
|
107
|
-
|
|
108
|
-
|
|
109
|
-
|
|
110
|
-
|
|
95
|
+
wo as ActivePages,
|
|
96
|
+
Xo as Demo,
|
|
97
|
+
Eo as LeaderboardItemDetail,
|
|
98
|
+
Uo as Login,
|
|
99
|
+
ko as Onboarding,
|
|
100
|
+
Zo as Points,
|
|
101
|
+
Go as Question,
|
|
102
|
+
yo as QuestionInApp,
|
|
103
|
+
Jo as QuestionList,
|
|
104
|
+
$o as StreamLayerThemeProvider,
|
|
105
|
+
zo as Tab,
|
|
106
|
+
Bo as Tabs,
|
|
107
|
+
rr as ThemeVariables,
|
|
108
|
+
Mo as UserStatistics,
|
|
109
|
+
Ro as Vote,
|
|
110
|
+
tr as theme,
|
|
111
|
+
mr as themeStr
|
|
111
112
|
};
|
|
@@ -1,8 +1,8 @@
|
|
|
1
|
-
import { jsx as
|
|
2
|
-
import { useStore as
|
|
3
|
-
import { useState as
|
|
4
|
-
import { LeaderboardItemDetail as
|
|
5
|
-
import { LeaderboardList as
|
|
1
|
+
import { jsx as e, jsxs as l, Fragment as u } from "react/jsx-runtime";
|
|
2
|
+
import { useStore as b } from "@nanostores/react";
|
|
3
|
+
import { useState as f } from "react";
|
|
4
|
+
import { LeaderboardItemDetail as I } from "../../../gamification/leaderboard-item-detail/index.js";
|
|
5
|
+
import { LeaderboardList as v } from "../../../gamification/leaderboard-list/index.js";
|
|
6
6
|
import "../../../gamification/common-header/index.js";
|
|
7
7
|
import "../../../../icon-exit-d3f9fc80.js";
|
|
8
8
|
import "../../../gamification/common-header/styles.js";
|
|
@@ -12,29 +12,29 @@ import "../../../gamification/leaderboard-item/index.js";
|
|
|
12
12
|
import "../../../../utils/common.js";
|
|
13
13
|
import "../../../gamification/leaderboard-item/styles.js";
|
|
14
14
|
import "../../../gamification/leaderboard-list/styles.js";
|
|
15
|
-
const
|
|
16
|
-
const { data:
|
|
17
|
-
if (
|
|
18
|
-
return /* @__PURE__ */
|
|
15
|
+
const z = ({ store: s }) => {
|
|
16
|
+
const { data: i = [], loading: d } = b(s), [r, p] = f(void 0);
|
|
17
|
+
if (d)
|
|
18
|
+
return /* @__PURE__ */ e("div", { children: "wait leader board..." });
|
|
19
19
|
const o = (t) => {
|
|
20
|
-
var
|
|
21
|
-
const
|
|
22
|
-
var
|
|
23
|
-
return ((
|
|
24
|
-
})) == null ? void 0 :
|
|
25
|
-
|
|
20
|
+
var a;
|
|
21
|
+
const n = (a = i.find((c) => {
|
|
22
|
+
var m;
|
|
23
|
+
return ((m = c.attributes) == null ? void 0 : m.userId) === t;
|
|
24
|
+
})) == null ? void 0 : a.attributes;
|
|
25
|
+
p(n);
|
|
26
26
|
};
|
|
27
|
-
return /* @__PURE__ */
|
|
28
|
-
|
|
29
|
-
!
|
|
30
|
-
|
|
27
|
+
return /* @__PURE__ */ l(u, { children: [
|
|
28
|
+
r && /* @__PURE__ */ e(I, { comeBack: () => o(null), ...r }),
|
|
29
|
+
!r && /* @__PURE__ */ e(
|
|
30
|
+
v,
|
|
31
31
|
{
|
|
32
|
-
items:
|
|
32
|
+
items: i.filter((t) => t.attributes).map((t) => t.attributes),
|
|
33
33
|
openItemDetail: o
|
|
34
34
|
}
|
|
35
35
|
)
|
|
36
36
|
] });
|
|
37
37
|
};
|
|
38
38
|
export {
|
|
39
|
-
|
|
39
|
+
z as Leaderboard
|
|
40
40
|
};
|
|
@@ -3,21 +3,24 @@ import { FeatureType as s } from "@streamlayer/sdk-web-types";
|
|
|
3
3
|
import { useStore as p } from "@nanostores/react";
|
|
4
4
|
import { styled as u } from "@linaria/react";
|
|
5
5
|
import { Points as a } from "../gamification/points/index.js";
|
|
6
|
+
import "../../utils/common.js";
|
|
6
7
|
import "../gamification/points/styles.js";
|
|
7
8
|
import "../icons/index.js";
|
|
8
9
|
import "react";
|
|
10
|
+
import "../theme/breakpoints.js";
|
|
11
|
+
import "../theme/constants.js";
|
|
9
12
|
const d = u.div`
|
|
10
13
|
position: fixed;
|
|
11
14
|
top: 0;
|
|
12
15
|
right: 0;
|
|
13
16
|
`, f = ({ store: o }) => {
|
|
14
|
-
var
|
|
17
|
+
var m, i, e, n;
|
|
15
18
|
const t = p(o);
|
|
16
|
-
return ((
|
|
17
|
-
},
|
|
19
|
+
return ((i = (m = t.data) == null ? void 0 : m.summary) == null ? void 0 : i.points) === void 0 ? null : /* @__PURE__ */ r(d, { children: ((n = (e = t.data) == null ? void 0 : e.summary) == null ? void 0 : n.points) && /* @__PURE__ */ r(a, { points: t.data.summary.points }) });
|
|
20
|
+
}, F = ({ sdk: o }) => {
|
|
18
21
|
const t = o.getFeature(s.GAMES);
|
|
19
22
|
return t != null && t.userSummary ? /* @__PURE__ */ r(f, { store: t.userSummary.getStore() }) : null;
|
|
20
23
|
};
|
|
21
24
|
export {
|
|
22
|
-
|
|
25
|
+
F as DemoPoints
|
|
23
26
|
};
|
package/lib/ui/demo/index.js
CHANGED
|
@@ -1,16 +1,19 @@
|
|
|
1
|
-
|
|
2
|
-
|
|
1
|
+
var y = Object.defineProperty;
|
|
2
|
+
var b = (o, r, t) => r in o ? y(o, r, { enumerable: !0, configurable: !0, writable: !0, value: t }) : o[r] = t;
|
|
3
|
+
var m = (o, r, t) => (b(o, typeof r != "symbol" ? r + "" : r, t), t);
|
|
4
|
+
import { jsx as e, jsxs as l, Fragment as T } from "react/jsx-runtime";
|
|
5
|
+
import { FeatureStatus as c } from "@streamlayer/sdk-web-interfaces";
|
|
3
6
|
import { FeatureType as g } from "@streamlayer/sdk-web-types";
|
|
4
|
-
import { AvailableFeatures as
|
|
5
|
-
import { useState as
|
|
7
|
+
import { AvailableFeatures as C } from "@streamlayer/sdk-web-features";
|
|
8
|
+
import { useState as w, useMemo as S, useEffect as F } from "react";
|
|
6
9
|
import "@streamlayer/sdk-web-api";
|
|
7
|
-
import "@streamlayer/sdk-web-storage";
|
|
8
|
-
import { useStore as
|
|
9
|
-
import { Notifications as
|
|
10
|
-
import { GamificationComponent as
|
|
10
|
+
import { Storage as k } from "@streamlayer/sdk-web-storage";
|
|
11
|
+
import { useStore as f } from "@nanostores/react";
|
|
12
|
+
import { Notifications as x } from "../notifications/index.js";
|
|
13
|
+
import { GamificationComponent as E } from "./Gamification.js";
|
|
11
14
|
import { HighlightsComponent as G } from "./Highlights.js";
|
|
12
15
|
import { LoginComponent as H } from "./Login.js";
|
|
13
|
-
import { Buttons as
|
|
16
|
+
import { Buttons as A, Button as d } from "./styles.js";
|
|
14
17
|
import "../notifications/notification/index.js";
|
|
15
18
|
import "@streamlayer/sdk-web-notifications";
|
|
16
19
|
import "../notifications/notification/onboarding-inapp/index.js";
|
|
@@ -84,55 +87,91 @@ import "@connectrpc/connect";
|
|
|
84
87
|
import "@connectrpc/connect-web";
|
|
85
88
|
import "@streamlayer/sl-eslib/users/users_connect";
|
|
86
89
|
import "../login/styles.js";
|
|
87
|
-
|
|
88
|
-
|
|
89
|
-
|
|
90
|
-
|
|
91
|
-
|
|
92
|
-
|
|
93
|
-
|
|
94
|
-
|
|
95
|
-
|
|
96
|
-
|
|
90
|
+
class B extends k {
|
|
91
|
+
constructor() {
|
|
92
|
+
super("user");
|
|
93
|
+
// Schema
|
|
94
|
+
m(this, "setSchema", (t) => {
|
|
95
|
+
this.write("schema", t);
|
|
96
|
+
});
|
|
97
|
+
m(this, "getSchema", () => this.read(
|
|
98
|
+
"schema"
|
|
99
|
+
/* SCHEMA */
|
|
100
|
+
));
|
|
101
|
+
// Token
|
|
102
|
+
m(this, "setToken", (t) => {
|
|
103
|
+
this.write("token", t);
|
|
104
|
+
});
|
|
105
|
+
m(this, "getToken", () => this.read(
|
|
106
|
+
"token"
|
|
107
|
+
/* TOKEN */
|
|
108
|
+
));
|
|
109
|
+
// External Token
|
|
110
|
+
m(this, "setExternalToken", (t) => {
|
|
111
|
+
this.write("eToken", t);
|
|
112
|
+
});
|
|
113
|
+
m(this, "getExternalToken", () => this.read(
|
|
114
|
+
"eToken"
|
|
115
|
+
/* EXTERNAL_TOKEN */
|
|
116
|
+
));
|
|
117
|
+
m(this, "removeToken", () => {
|
|
118
|
+
this.remove(
|
|
119
|
+
"token"
|
|
120
|
+
/* TOKEN */
|
|
121
|
+
);
|
|
122
|
+
});
|
|
123
|
+
}
|
|
124
|
+
}
|
|
125
|
+
new B();
|
|
126
|
+
const R = ({ activeFeature: o, sdk: r }) => {
|
|
127
|
+
const [t, a] = w(null), { organizationSettings: s, streamSettings: u } = f(r.sdkStore), v = S(() => {
|
|
128
|
+
const i = (u == null ? void 0 : u.data) || (s == null ? void 0 : s.data);
|
|
129
|
+
return i != null && i.overlays ? i.overlays : [];
|
|
130
|
+
}, [s, u]);
|
|
131
|
+
F(() => {
|
|
132
|
+
const i = r.getFeatures();
|
|
133
|
+
if (o)
|
|
134
|
+
for (const [n, p] of i)
|
|
135
|
+
n === o ? p.status.get() === c.Suspended && (p.enable(), a(p)) : p.status.get() === c.Ready && p.disable();
|
|
97
136
|
else {
|
|
98
|
-
for (const [,
|
|
99
|
-
|
|
100
|
-
|
|
137
|
+
for (const [, n] of i)
|
|
138
|
+
n.status.get() === c.Ready && n.disable();
|
|
139
|
+
a(null);
|
|
101
140
|
}
|
|
102
141
|
return () => {
|
|
103
|
-
for (const [,
|
|
104
|
-
|
|
142
|
+
for (const [, n] of i)
|
|
143
|
+
n.status.get() === c.Ready && n.disable();
|
|
105
144
|
};
|
|
106
|
-
}, [
|
|
107
|
-
const
|
|
108
|
-
return /* @__PURE__ */
|
|
109
|
-
/* @__PURE__ */
|
|
110
|
-
/* @__PURE__ */
|
|
111
|
-
/* @__PURE__ */
|
|
112
|
-
|
|
113
|
-
|
|
145
|
+
}, [o, r]);
|
|
146
|
+
const h = S(() => t ? t.featureConfig.get().type === g.GAMES ? t ? /* @__PURE__ */ e("div", { children: /* @__PURE__ */ e(E, { gamification: t, sdk: r }) }) : /* @__PURE__ */ e("div", { children: "wait gamification..." }) : t.featureConfig.get().type === g.HIGHLIGHTS ? t ? /* @__PURE__ */ e("div", { children: /* @__PURE__ */ e(G, { highlights: t, sdk: r }) }) : /* @__PURE__ */ e("div", { children: "wait highlights..." }) : /* @__PURE__ */ e("div", { children: "unknown feature" }) : null, [r, t]);
|
|
147
|
+
return /* @__PURE__ */ l("div", { children: [
|
|
148
|
+
/* @__PURE__ */ l(A, { children: [
|
|
149
|
+
/* @__PURE__ */ e(d, { onClick: () => r.closeFeature(), disabled: !h, children: "close" }),
|
|
150
|
+
/* @__PURE__ */ e(d, { onClick: () => r.logout(), children: "logout" }),
|
|
151
|
+
v.map((i) => /* @__PURE__ */ l(
|
|
152
|
+
d,
|
|
114
153
|
{
|
|
115
|
-
onClick: () =>
|
|
116
|
-
disabled: !(
|
|
117
|
-
"data-enable_sdk_button":
|
|
118
|
-
"data-selected":
|
|
154
|
+
onClick: () => r.openFeature(i.type),
|
|
155
|
+
disabled: !(i.type in C),
|
|
156
|
+
"data-enable_sdk_button": i.enableSdkButton.toString(),
|
|
157
|
+
"data-selected": i.type === o,
|
|
119
158
|
children: [
|
|
120
|
-
/* @__PURE__ */
|
|
121
|
-
|
|
159
|
+
/* @__PURE__ */ e("img", { src: i.icon, alt: "" }),
|
|
160
|
+
i.name
|
|
122
161
|
]
|
|
123
162
|
},
|
|
124
|
-
|
|
163
|
+
i.name
|
|
125
164
|
))
|
|
126
165
|
] }),
|
|
127
|
-
|
|
166
|
+
h
|
|
128
167
|
] });
|
|
129
|
-
},
|
|
130
|
-
const
|
|
131
|
-
return
|
|
132
|
-
/* @__PURE__ */
|
|
133
|
-
/* @__PURE__ */
|
|
134
|
-
] }) : /* @__PURE__ */
|
|
168
|
+
}, lr = ({ sdk: o }) => {
|
|
169
|
+
const r = f(o.organizationStore()), t = f(o.getUserStore()), a = f(o.getActiveFeature());
|
|
170
|
+
return r.loading ? /* @__PURE__ */ e("div", { children: "authentication..." }) : r.data ? t.loading ? /* @__PURE__ */ e("div", { children: "authentication..." }) : t.data ? /* @__PURE__ */ l(T, { children: [
|
|
171
|
+
/* @__PURE__ */ e(x, { notificationsStore: o.getNotificationsStore() }),
|
|
172
|
+
/* @__PURE__ */ e(R, { sdk: o, activeFeature: a })
|
|
173
|
+
] }) : /* @__PURE__ */ e(H, { sdk: o }) : /* @__PURE__ */ e("div", { children: "wrong sdk key..." });
|
|
135
174
|
};
|
|
136
175
|
export {
|
|
137
|
-
|
|
176
|
+
lr as Demo
|
|
138
177
|
};
|
|
@@ -1,15 +1,18 @@
|
|
|
1
1
|
import { jsxs as i, jsx as o } from "react/jsx-runtime";
|
|
2
|
-
import {
|
|
2
|
+
import { formatDecimals as r } from "../../../utils/common.js";
|
|
3
|
+
import { PointsContainer as n, PointsIcon as m, PointsSvg as s, PointsBody as e, PointsTitle as p, PointsValue as c } from "./styles.js";
|
|
3
4
|
import "@linaria/react";
|
|
4
5
|
import "../../icons/index.js";
|
|
5
6
|
import "react";
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
7
|
+
import "../../theme/breakpoints.js";
|
|
8
|
+
import "../../theme/constants.js";
|
|
9
|
+
const u = ({ points: t }) => /* @__PURE__ */ i(n, { children: [
|
|
10
|
+
/* @__PURE__ */ o(m, { children: /* @__PURE__ */ o(s, { name: "icon-trophy" }) }),
|
|
11
|
+
/* @__PURE__ */ i(e, { children: [
|
|
12
|
+
/* @__PURE__ */ o(p, { children: "Total points" }),
|
|
13
|
+
/* @__PURE__ */ o(c, { children: r(t) })
|
|
11
14
|
] })
|
|
12
15
|
] });
|
|
13
16
|
export {
|
|
14
|
-
|
|
17
|
+
u as Points
|
|
15
18
|
};
|
|
@@ -1,47 +1,86 @@
|
|
|
1
1
|
import { styled as t } from "@linaria/react";
|
|
2
|
-
import { SvgIcon as
|
|
2
|
+
import { SvgIcon as o } from "../../icons/index.js";
|
|
3
|
+
import { breakpoints as i } from "../../theme/breakpoints.js";
|
|
3
4
|
import "react/jsx-runtime";
|
|
4
5
|
import "react";
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
|
|
6
|
+
import "../../theme/constants.js";
|
|
7
|
+
const l = t.div`
|
|
8
|
+
position: relative;
|
|
9
|
+
display: inline-flex;
|
|
10
|
+
align-items: center;
|
|
11
|
+
column-gap: 8px;
|
|
12
|
+
padding: 4px 17px 4px 4px;
|
|
8
13
|
border-radius: 40px;
|
|
14
|
+
|
|
15
|
+
&:before {
|
|
16
|
+
content: '';
|
|
17
|
+
position: absolute;
|
|
18
|
+
top: 0;
|
|
19
|
+
left: 0;
|
|
20
|
+
bottom: 0;
|
|
21
|
+
right: 0;
|
|
22
|
+
border-radius: 40px;
|
|
23
|
+
border: 1px solid var(--color-neutrals-white);
|
|
24
|
+
opacity: 0.4;
|
|
25
|
+
z-index: -1;
|
|
26
|
+
}
|
|
27
|
+
|
|
28
|
+
${i.down("md")`
|
|
29
|
+
padding-right: 10px;
|
|
30
|
+
`}
|
|
31
|
+
`, x = t.div`
|
|
9
32
|
display: flex;
|
|
10
|
-
height: 48px;
|
|
11
|
-
width: 140px;
|
|
12
|
-
box-sizing: border-box;
|
|
13
|
-
padding: 4px;
|
|
14
33
|
flex-shrink: 0;
|
|
15
|
-
justify-content: start;
|
|
16
34
|
align-items: center;
|
|
17
|
-
|
|
18
|
-
border-radius: 50%;
|
|
19
|
-
background: #006747;
|
|
35
|
+
justify-content: center;
|
|
20
36
|
width: 40px;
|
|
21
37
|
height: 40px;
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
|
|
38
|
+
border-radius: 50%;
|
|
39
|
+
background: #006747;
|
|
40
|
+
|
|
41
|
+
${i.down("md")`
|
|
42
|
+
width: 28px;
|
|
43
|
+
height: 28px;
|
|
44
|
+
`}
|
|
45
|
+
`, a = t(o)`
|
|
28
46
|
width: 20px;
|
|
29
47
|
height: 20px;
|
|
30
48
|
|
|
31
49
|
path {
|
|
32
50
|
fill: #fff;
|
|
33
51
|
}
|
|
34
|
-
|
|
35
|
-
|
|
36
|
-
|
|
52
|
+
|
|
53
|
+
${i.down("md")`
|
|
54
|
+
width: 14px;
|
|
55
|
+
height: 14px;
|
|
56
|
+
`}
|
|
57
|
+
`, h = t.div`
|
|
58
|
+
display: flex;
|
|
59
|
+
flex-direction: column;
|
|
60
|
+
color: var(--color-neutrals-white);
|
|
61
|
+
font-weight: var(--font-weight-default);
|
|
37
62
|
`, c = t.div`
|
|
38
|
-
|
|
63
|
+
margin-bottom: 1px;
|
|
64
|
+
font-size: 9px;
|
|
65
|
+
text-transform: uppercase;
|
|
66
|
+
|
|
67
|
+
${i.down("md")`
|
|
68
|
+
display: none;
|
|
69
|
+
`}
|
|
70
|
+
`, f = t.div`
|
|
71
|
+
font-size: 18px;
|
|
72
|
+
line-height: 20px;
|
|
73
|
+
|
|
74
|
+
${i.down("md")`
|
|
75
|
+
font-size: 14px;
|
|
76
|
+
line-height: 22px;
|
|
77
|
+
`}
|
|
39
78
|
`;
|
|
40
79
|
export {
|
|
41
|
-
|
|
42
|
-
|
|
43
|
-
|
|
44
|
-
|
|
45
|
-
|
|
46
|
-
|
|
80
|
+
h as PointsBody,
|
|
81
|
+
l as PointsContainer,
|
|
82
|
+
x as PointsIcon,
|
|
83
|
+
a as PointsSvg,
|
|
84
|
+
c as PointsTitle,
|
|
85
|
+
f as PointsValue
|
|
47
86
|
};
|
|
@@ -0,0 +1,6 @@
|
|
|
1
|
+
import { BREAKPOINTS } from './constants';
|
|
2
|
+
export type Breakpoints = keyof typeof BREAKPOINTS;
|
|
3
|
+
export declare const breakpoints: {
|
|
4
|
+
up: (key: Breakpoints) => (styles: TemplateStringsArray) => string;
|
|
5
|
+
down: (key: Breakpoints) => (styles: TemplateStringsArray) => string;
|
|
6
|
+
};
|
|
@@ -0,0 +1,18 @@
|
|
|
1
|
+
import { BREAKPOINTS as e } from "./constants.js";
|
|
2
|
+
const i = (t) => (n) => `
|
|
3
|
+
@media (${t}) {
|
|
4
|
+
${n}
|
|
5
|
+
}
|
|
6
|
+
`, o = {
|
|
7
|
+
up: (t) => {
|
|
8
|
+
const n = e[t];
|
|
9
|
+
return i(`min-width: ${n}px`);
|
|
10
|
+
},
|
|
11
|
+
down: (t) => {
|
|
12
|
+
const n = e[t] - 1;
|
|
13
|
+
return i(`max-width: ${n}px`);
|
|
14
|
+
}
|
|
15
|
+
};
|
|
16
|
+
export {
|
|
17
|
+
o as breakpoints
|
|
18
|
+
};
|
|
@@ -54,6 +54,12 @@ const N = {
|
|
|
54
54
|
SERIF: "'Tiempos', 'Tiempos Text', Times New Roman, serif",
|
|
55
55
|
COLOR: "#fff",
|
|
56
56
|
WEIGHT_DEFAULT: "500"
|
|
57
|
+
}, O = {
|
|
58
|
+
sm: 576,
|
|
59
|
+
md: 768,
|
|
60
|
+
lg: 992,
|
|
61
|
+
xl: 1200,
|
|
62
|
+
xxl: 1400
|
|
57
63
|
}, G = Object.keys(E).reduce((A, R) => {
|
|
58
64
|
const _ = E[R];
|
|
59
65
|
return `
|
|
@@ -62,6 +68,7 @@ const N = {
|
|
|
62
68
|
`;
|
|
63
69
|
}, "");
|
|
64
70
|
export {
|
|
71
|
+
O as BREAKPOINTS,
|
|
65
72
|
E as COLORS,
|
|
66
73
|
S as FONT,
|
|
67
74
|
T as MASTERS_COLORS,
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@streamlayer/react-ui",
|
|
3
|
-
"version": "0.
|
|
3
|
+
"version": "0.46.0",
|
|
4
4
|
"type": "module",
|
|
5
5
|
"main": "./src/index.js",
|
|
6
6
|
"typings": "./lib/index.d.ts",
|
|
@@ -27,12 +27,12 @@
|
|
|
27
27
|
],
|
|
28
28
|
"peerDependencies": {
|
|
29
29
|
"@streamlayer/sl-eslib": "^5.52.0",
|
|
30
|
-
"@streamlayer/feature-gamification": "^0.18.
|
|
31
|
-
"@streamlayer/sdk-web": "^0.28.
|
|
32
|
-
"@streamlayer/sdk-web-anonymous-auth": "^0.
|
|
33
|
-
"@streamlayer/sdk-web-api": "^0.0
|
|
34
|
-
"@streamlayer/sdk-web-core": "^0.
|
|
35
|
-
"@streamlayer/sdk-web-features": "^0.10.
|
|
30
|
+
"@streamlayer/feature-gamification": "^0.18.3",
|
|
31
|
+
"@streamlayer/sdk-web": "^0.28.5",
|
|
32
|
+
"@streamlayer/sdk-web-anonymous-auth": "^0.11.0",
|
|
33
|
+
"@streamlayer/sdk-web-api": "^0.1.0",
|
|
34
|
+
"@streamlayer/sdk-web-core": "^0.16.0",
|
|
35
|
+
"@streamlayer/sdk-web-features": "^0.10.8",
|
|
36
36
|
"@streamlayer/sdk-web-interfaces": "^0.18.5",
|
|
37
37
|
"@streamlayer/sdk-web-notifications": "^0.10.4",
|
|
38
38
|
"@streamlayer/sdk-web-storage": "^0.3.7",
|
|
@@ -73,6 +73,6 @@
|
|
|
73
73
|
"vite-plugin-svgr": "^4.1.0",
|
|
74
74
|
"vite-svg-loader": "^4.0.0",
|
|
75
75
|
"vite-tsconfig-paths": "^4.2.1",
|
|
76
|
-
"@streamlayer/react": "^0.24.
|
|
76
|
+
"@streamlayer/react": "^0.24.6"
|
|
77
77
|
}
|
|
78
78
|
}
|