strapi-plugin-magic-sessionmanager 4.4.2 → 4.4.4
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/_chunks/{Analytics-sX94t6D9.mjs → Analytics-CFlATYIp.mjs} +50 -57
- package/dist/_chunks/{Analytics-tOOj5T92.js → Analytics-mFarhu5A.js} +50 -57
- package/dist/_chunks/{App-Cs4KKd3L.mjs → App-BkFz8R3I.mjs} +93 -123
- package/dist/_chunks/{App-D4qVym6y.js → App-CrdNlRlL.js} +93 -123
- package/dist/_chunks/{License-kfVcskd3.js → License-BI04KWfw.js} +9 -9
- package/dist/_chunks/{License-CN5YpqIu.mjs → License-BnbIePhc.mjs} +9 -9
- package/dist/_chunks/{OnlineUsersWidget-Cg3R7602.js → OnlineUsersWidget-D1B_2ge5.js} +2 -2
- package/dist/_chunks/{OnlineUsersWidget-ytykP_tA.mjs → OnlineUsersWidget-eBwttUiU.mjs} +2 -2
- package/dist/_chunks/{Settings-XloJ-aHl.mjs → Settings-BfKDErt5.mjs} +55 -61
- package/dist/_chunks/{Settings-DVRIrGho.js → Settings-Cy-6vah_.js} +55 -61
- package/dist/_chunks/{StyledButtons-fbNVRlMY.mjs → StyledButtons-Cz8oYhmc.mjs} +47 -47
- package/dist/_chunks/{StyledButtons-D2EbG_Zw.js → StyledButtons-DDuxnYz8.js} +47 -47
- package/dist/_chunks/{UpgradePage-C441wvPX.mjs → UpgradePage-2mV2iqDM.mjs} +14 -14
- package/dist/_chunks/{UpgradePage-D2FRalDz.js → UpgradePage-B8kz6Cyz.js} +14 -14
- package/dist/_chunks/{index-Ij0JRf9W.mjs → index-B0wQeSSu.mjs} +30 -30
- package/dist/_chunks/{index-DtBfKBne.js → index-BEh2DizI.js} +30 -30
- package/dist/_chunks/{useLicense-NCFYHpDd.js → useLicense-DFdVp_qI.js} +1 -1
- package/dist/_chunks/{useLicense-DJEDGSap.mjs → useLicense-RxDUbCoU.mjs} +1 -1
- package/dist/admin/index.js +1 -1
- package/dist/admin/index.mjs +1 -1
- package/dist/server/index.js +1 -1
- package/dist/server/index.mjs +1 -1
- package/package.json +1 -1
|
@@ -4,16 +4,9 @@ import { useFetchClient } from "@strapi/strapi/admin";
|
|
|
4
4
|
import styled, { css, keyframes } from "styled-components";
|
|
5
5
|
import { Loader, Typography, Box, Flex, Badge } from "@strapi/design-system";
|
|
6
6
|
import { ChartBubble, Crown, User, Clock, Monitor } from "@strapi/icons";
|
|
7
|
-
import { a as pluginId } from "./index-
|
|
8
|
-
import { u as useLicense } from "./useLicense-
|
|
7
|
+
import { a as pluginId } from "./index-B0wQeSSu.mjs";
|
|
8
|
+
import { u as useLicense } from "./useLicense-RxDUbCoU.mjs";
|
|
9
9
|
const theme = {
|
|
10
|
-
colors: {
|
|
11
|
-
primary: { 100: "#E0F2FE", 500: "#0EA5E9", 600: "#0284C7" },
|
|
12
|
-
secondary: { 100: "#EDE9FE", 500: "#A855F7", 600: "#9333EA" },
|
|
13
|
-
success: { 100: "#DCFCE7", 500: "#22C55E", 600: "#16A34A" },
|
|
14
|
-
warning: { 100: "#FEF3C7", 500: "#F59E0B", 600: "#D97706" },
|
|
15
|
-
neutral: { 0: "#FFFFFF", 100: "#F3F4F6", 200: "#E5E7EB", 600: "#4B5563", 700: "#374151", 800: "#1F2937" }
|
|
16
|
-
},
|
|
17
10
|
shadows: {
|
|
18
11
|
sm: "0 1px 3px 0 rgba(0, 0, 0, 0.1)",
|
|
19
12
|
md: "0 4px 6px -1px rgba(0, 0, 0, 0.1)",
|
|
@@ -59,7 +52,7 @@ const Container = styled(Box)`
|
|
|
59
52
|
padding: ${theme.spacing.xl} 24px 0;
|
|
60
53
|
`;
|
|
61
54
|
const Header = styled(Box)`
|
|
62
|
-
background: linear-gradient(135deg, ${
|
|
55
|
+
background: linear-gradient(135deg, ${"var(--colors-primary600, #0284C7)"} 0%, ${"var(--colors-secondary600, #9333EA)"} 100%);
|
|
63
56
|
border-radius: ${theme.borderRadius.xl};
|
|
64
57
|
padding: ${theme.spacing.xl} ${theme.spacing["2xl"]};
|
|
65
58
|
margin-bottom: ${theme.spacing.xl};
|
|
@@ -95,7 +88,7 @@ const HeaderContent = styled(Flex)`
|
|
|
95
88
|
z-index: 1;
|
|
96
89
|
`;
|
|
97
90
|
const Title = styled(Typography)`
|
|
98
|
-
color: ${theme.colors.
|
|
91
|
+
color: ${(p) => p.theme.colors.neutral0};
|
|
99
92
|
font-size: 2.25rem;
|
|
100
93
|
font-weight: 700;
|
|
101
94
|
letter-spacing: -0.025em;
|
|
@@ -124,7 +117,7 @@ const StatsGrid = styled.div`
|
|
|
124
117
|
margin-bottom: 40px;
|
|
125
118
|
`;
|
|
126
119
|
const StatCard = styled(Box)`
|
|
127
|
-
background: ${theme.colors.
|
|
120
|
+
background: ${(p) => p.theme.colors.neutral0};
|
|
128
121
|
border-radius: ${theme.borderRadius.lg};
|
|
129
122
|
padding: 32px;
|
|
130
123
|
position: relative;
|
|
@@ -133,7 +126,7 @@ const StatCard = styled(Box)`
|
|
|
133
126
|
${css`animation: ${fadeIn} ${theme.transitions.slow} backwards;`}
|
|
134
127
|
animation-delay: ${(props) => props.$delay || "0s"};
|
|
135
128
|
box-shadow: ${theme.shadows.sm};
|
|
136
|
-
border: 1px solid ${
|
|
129
|
+
border: 1px solid ${"rgba(128, 128, 128, 0.2)"};
|
|
137
130
|
text-align: center;
|
|
138
131
|
display: flex;
|
|
139
132
|
flex-direction: column;
|
|
@@ -143,7 +136,7 @@ const StatCard = styled(Box)`
|
|
|
143
136
|
&:hover {
|
|
144
137
|
transform: translateY(-6px);
|
|
145
138
|
box-shadow: ${theme.shadows.xl};
|
|
146
|
-
border-color: ${(props) => props.$borderColor ||
|
|
139
|
+
border-color: ${(props) => props.$borderColor || "var(--colors-primary600, #0EA5E9)"};
|
|
147
140
|
|
|
148
141
|
.stat-icon {
|
|
149
142
|
transform: scale(1.15) rotate(5deg);
|
|
@@ -151,7 +144,7 @@ const StatCard = styled(Box)`
|
|
|
151
144
|
|
|
152
145
|
.stat-value {
|
|
153
146
|
transform: scale(1.08);
|
|
154
|
-
color: ${(props) => props.$accentColor ||
|
|
147
|
+
color: ${(props) => props.$accentColor || "var(--colors-primary600, #0284C7)"};
|
|
155
148
|
}
|
|
156
149
|
}
|
|
157
150
|
`;
|
|
@@ -162,7 +155,7 @@ const StatIcon = styled(Box)`
|
|
|
162
155
|
display: flex;
|
|
163
156
|
align-items: center;
|
|
164
157
|
justify-content: center;
|
|
165
|
-
background: ${(props) => props.$bg ||
|
|
158
|
+
background: ${(props) => props.$bg || "rgba(2, 132, 199, 0.12)"};
|
|
166
159
|
transition: all ${theme.transitions.normal};
|
|
167
160
|
margin: 0 auto 24px;
|
|
168
161
|
box-shadow: ${theme.shadows.sm};
|
|
@@ -170,13 +163,13 @@ const StatIcon = styled(Box)`
|
|
|
170
163
|
svg {
|
|
171
164
|
width: 40px;
|
|
172
165
|
height: 40px;
|
|
173
|
-
color: ${(props) => props.$color ||
|
|
166
|
+
color: ${(props) => props.$color || "var(--colors-primary600, #0284C7)"};
|
|
174
167
|
}
|
|
175
168
|
`;
|
|
176
169
|
const StatValue = styled(Typography)`
|
|
177
170
|
font-size: 3.5rem;
|
|
178
171
|
font-weight: 700;
|
|
179
|
-
color: ${
|
|
172
|
+
color: ${"var(--colors-neutral800)"};
|
|
180
173
|
line-height: 1;
|
|
181
174
|
margin-bottom: 12px;
|
|
182
175
|
transition: all ${theme.transitions.normal};
|
|
@@ -184,29 +177,29 @@ const StatValue = styled(Typography)`
|
|
|
184
177
|
`;
|
|
185
178
|
const StatLabel = styled(Typography)`
|
|
186
179
|
font-size: 1rem;
|
|
187
|
-
color: ${
|
|
180
|
+
color: ${"var(--colors-neutral600)"};
|
|
188
181
|
font-weight: 500;
|
|
189
182
|
text-align: center;
|
|
190
183
|
`;
|
|
191
184
|
const ChartCard = styled(Box)`
|
|
192
|
-
background: ${theme.colors.
|
|
185
|
+
background: ${(p) => p.theme.colors.neutral0};
|
|
193
186
|
border-radius: ${theme.borderRadius.lg};
|
|
194
187
|
padding: 36px;
|
|
195
188
|
box-shadow: ${theme.shadows.md};
|
|
196
|
-
border: 1px solid ${
|
|
189
|
+
border: 1px solid ${"rgba(128, 128, 128, 0.2)"};
|
|
197
190
|
margin-bottom: 28px;
|
|
198
191
|
${css`animation: ${slideIn} ${theme.transitions.slow};`}
|
|
199
192
|
transition: all ${theme.transitions.normal};
|
|
200
193
|
|
|
201
194
|
&:hover {
|
|
202
195
|
box-shadow: ${theme.shadows.lg};
|
|
203
|
-
border-color: ${
|
|
196
|
+
border-color: ${"rgba(2, 132, 199, 0.2)"};
|
|
204
197
|
}
|
|
205
198
|
`;
|
|
206
199
|
const ChartTitle = styled(Typography)`
|
|
207
200
|
font-size: 1.25rem;
|
|
208
201
|
font-weight: 700;
|
|
209
|
-
color: ${
|
|
202
|
+
color: ${"var(--colors-neutral800)"};
|
|
210
203
|
margin-bottom: 24px;
|
|
211
204
|
display: flex;
|
|
212
205
|
align-items: center;
|
|
@@ -215,7 +208,7 @@ const ChartTitle = styled(Typography)`
|
|
|
215
208
|
svg {
|
|
216
209
|
width: 24px;
|
|
217
210
|
height: 24px;
|
|
218
|
-
color: ${
|
|
211
|
+
color: ${"var(--colors-primary600, #0284C7)"};
|
|
219
212
|
}
|
|
220
213
|
`;
|
|
221
214
|
const BarChart = styled.div`
|
|
@@ -234,12 +227,12 @@ const BarLabel = styled(Typography)`
|
|
|
234
227
|
min-width: 110px;
|
|
235
228
|
font-size: 15px;
|
|
236
229
|
font-weight: 600;
|
|
237
|
-
color: ${
|
|
230
|
+
color: ${"var(--colors-neutral700)"};
|
|
238
231
|
`;
|
|
239
232
|
const BarContainer = styled.div`
|
|
240
233
|
flex: 1;
|
|
241
234
|
height: 40px;
|
|
242
|
-
background: ${
|
|
235
|
+
background: ${"var(--colors-neutral100)"};
|
|
243
236
|
border-radius: 10px;
|
|
244
237
|
overflow: hidden;
|
|
245
238
|
position: relative;
|
|
@@ -247,7 +240,7 @@ const BarContainer = styled.div`
|
|
|
247
240
|
`;
|
|
248
241
|
const BarFill = styled.div`
|
|
249
242
|
height: 100%;
|
|
250
|
-
background: linear-gradient(90deg, ${(props) => props.$color1 ||
|
|
243
|
+
background: linear-gradient(90deg, ${(props) => props.$color1 || "var(--colors-primary600, #0EA5E9)"}, ${(props) => props.$color2 || "var(--colors-primary600, #0284C7)"});
|
|
251
244
|
border-radius: 10px;
|
|
252
245
|
--bar-width: ${(props) => props.$percentage || 0}%;
|
|
253
246
|
${css`animation: ${growBar} 1s cubic-bezier(0.4, 0, 0.2, 1) forwards;`}
|
|
@@ -280,7 +273,7 @@ const AnimatedIcon = styled.div`
|
|
|
280
273
|
${css`animation: ${float} 3s ease-in-out infinite;`}
|
|
281
274
|
width: 96px;
|
|
282
275
|
height: 96px;
|
|
283
|
-
color: #
|
|
276
|
+
color: var(--colors-warning600, #D97706);
|
|
284
277
|
margin: 0 auto 32px;
|
|
285
278
|
display: flex;
|
|
286
279
|
align-items: center;
|
|
@@ -377,7 +370,7 @@ const AnalyticsPage = () => {
|
|
|
377
370
|
};
|
|
378
371
|
if (licenseLoading) {
|
|
379
372
|
return /* @__PURE__ */ jsx(Container, { children: /* @__PURE__ */ jsxs(LoadingOverlay, { children: [
|
|
380
|
-
/* @__PURE__ */ jsx(ChartBubble, { className: "loader-icon", style: { width: "64px", height: "64px", color:
|
|
373
|
+
/* @__PURE__ */ jsx(ChartBubble, { className: "loader-icon", style: { width: "64px", height: "64px", color: "var(--colors-primary600, #0284C7)" } }),
|
|
381
374
|
/* @__PURE__ */ jsx(Loader, { children: "Checking license..." }),
|
|
382
375
|
/* @__PURE__ */ jsx(Typography, { variant: "pi", textColor: "neutral600", children: "Please wait while we verify your premium access" })
|
|
383
376
|
] }) });
|
|
@@ -388,9 +381,9 @@ const AnalyticsPage = () => {
|
|
|
388
381
|
{
|
|
389
382
|
padding: 10,
|
|
390
383
|
style: {
|
|
391
|
-
background: "linear-gradient(135deg,
|
|
384
|
+
background: "linear-gradient(135deg, rgba(234, 179, 8, 0.12) 0%, rgba(234, 179, 8, 0.25) 100%)",
|
|
392
385
|
borderRadius: "20px",
|
|
393
|
-
border: "3px solid
|
|
386
|
+
border: "3px solid rgba(234, 179, 8, 0.4)",
|
|
394
387
|
textAlign: "center",
|
|
395
388
|
boxShadow: "0 20px 40px rgba(245, 158, 11, 0.2)",
|
|
396
389
|
maxWidth: "800px",
|
|
@@ -417,7 +410,7 @@ const AnalyticsPage = () => {
|
|
|
417
410
|
{
|
|
418
411
|
variant: "alpha",
|
|
419
412
|
style: {
|
|
420
|
-
color: "#92400e",
|
|
413
|
+
color: "var(--colors-warning600, #92400e)",
|
|
421
414
|
fontWeight: "700",
|
|
422
415
|
marginBottom: "24px",
|
|
423
416
|
fontSize: "36px",
|
|
@@ -432,7 +425,7 @@ const AnalyticsPage = () => {
|
|
|
432
425
|
{
|
|
433
426
|
variant: "omega",
|
|
434
427
|
style: {
|
|
435
|
-
color: "#78350f",
|
|
428
|
+
color: "var(--colors-warning600, #78350f)",
|
|
436
429
|
lineHeight: "1.9",
|
|
437
430
|
marginBottom: "44px",
|
|
438
431
|
fontSize: "17px",
|
|
@@ -448,7 +441,7 @@ const AnalyticsPage = () => {
|
|
|
448
441
|
{
|
|
449
442
|
onClick: () => window.open("https://magicapi.fitlex.me", "_blank"),
|
|
450
443
|
style: {
|
|
451
|
-
background: "linear-gradient(135deg, #f59e0b 0%, #d97706 100%)",
|
|
444
|
+
background: "linear-gradient(135deg, var(--colors-warning600, #f59e0b) 0%, var(--colors-warning600, #d97706) 100%)",
|
|
452
445
|
color: "white",
|
|
453
446
|
border: "none",
|
|
454
447
|
padding: "16px 48px",
|
|
@@ -477,7 +470,7 @@ const AnalyticsPage = () => {
|
|
|
477
470
|
}
|
|
478
471
|
if (loading) {
|
|
479
472
|
return /* @__PURE__ */ jsx(Container, { children: /* @__PURE__ */ jsxs(LoadingOverlay, { children: [
|
|
480
|
-
/* @__PURE__ */ jsx(ChartBubble, { className: "loader-icon", style: { width: "64px", height: "64px", color:
|
|
473
|
+
/* @__PURE__ */ jsx(ChartBubble, { className: "loader-icon", style: { width: "64px", height: "64px", color: "var(--colors-primary600, #0284C7)" } }),
|
|
481
474
|
/* @__PURE__ */ jsx(Loader, { children: "Loading analytics data..." })
|
|
482
475
|
] }) });
|
|
483
476
|
}
|
|
@@ -486,17 +479,17 @@ const AnalyticsPage = () => {
|
|
|
486
479
|
Math.max(...Object.values(analytics?.operatingSystems || {}), 1);
|
|
487
480
|
Math.max(...analytics?.loginHours || [], 1);
|
|
488
481
|
const deviceColors = {
|
|
489
|
-
"Desktop": [
|
|
490
|
-
"Mobile": [
|
|
491
|
-
"Tablet": [
|
|
482
|
+
"Desktop": ["var(--colors-primary600, #0EA5E9)", "var(--colors-primary600, #0284C7)"],
|
|
483
|
+
"Mobile": ["var(--colors-success600, #22C55E)", "var(--colors-success600, #16A34A)"],
|
|
484
|
+
"Tablet": ["var(--colors-warning600, #F59E0B)", "var(--colors-warning600, #D97706)"]
|
|
492
485
|
};
|
|
493
486
|
const browserColors = {
|
|
494
|
-
"Chrome": [
|
|
495
|
-
"Firefox": [
|
|
496
|
-
"Safari": [
|
|
497
|
-
"Edge": [
|
|
498
|
-
"API Client": [
|
|
499
|
-
"Other": [
|
|
487
|
+
"Chrome": ["var(--colors-success600, #22C55E)", "var(--colors-success600, #16A34A)"],
|
|
488
|
+
"Firefox": ["var(--colors-warning600, #F59E0B)", "var(--colors-warning600, #D97706)"],
|
|
489
|
+
"Safari": ["var(--colors-primary600, #0EA5E9)", "var(--colors-primary600, #0284C7)"],
|
|
490
|
+
"Edge": ["var(--colors-secondary500, #A855F7)", "var(--colors-secondary600, #9333EA)"],
|
|
491
|
+
"API Client": ["var(--colors-neutral600)", "var(--colors-neutral700)"],
|
|
492
|
+
"Other": ["var(--colors-neutral500)", "var(--colors-neutral600)"]
|
|
500
493
|
};
|
|
501
494
|
return /* @__PURE__ */ jsxs(Container, { children: [
|
|
502
495
|
/* @__PURE__ */ jsx(Header, { children: /* @__PURE__ */ jsxs(HeaderContent, { direction: "column", alignItems: "flex-start", gap: 2, children: [
|
|
@@ -507,23 +500,23 @@ const AnalyticsPage = () => {
|
|
|
507
500
|
/* @__PURE__ */ jsx(Subtitle, { children: "Comprehensive insights and statistics about user sessions" })
|
|
508
501
|
] }) }),
|
|
509
502
|
/* @__PURE__ */ jsxs(StatsGrid, { children: [
|
|
510
|
-
/* @__PURE__ */ jsxs(StatCard, { $delay: "0.1s", $borderColor:
|
|
511
|
-
/* @__PURE__ */ jsx(StatIcon, { className: "stat-icon", $bg:
|
|
503
|
+
/* @__PURE__ */ jsxs(StatCard, { $delay: "0.1s", $borderColor: "var(--colors-primary600, #0EA5E9)", $accentColor: "var(--colors-primary600, #0284C7)", children: [
|
|
504
|
+
/* @__PURE__ */ jsx(StatIcon, { className: "stat-icon", $bg: "rgba(2, 132, 199, 0.12)", $color: "var(--colors-primary600, #0284C7)", children: /* @__PURE__ */ jsx(ChartBubble, {}) }),
|
|
512
505
|
/* @__PURE__ */ jsx(StatValue, { className: "stat-value", children: analytics?.totalSessions || 0 }),
|
|
513
506
|
/* @__PURE__ */ jsx(StatLabel, { children: "Total Sessions" })
|
|
514
507
|
] }),
|
|
515
|
-
/* @__PURE__ */ jsxs(StatCard, { $delay: "0.2s", $borderColor:
|
|
516
|
-
/* @__PURE__ */ jsx(StatIcon, { className: "stat-icon", $bg:
|
|
508
|
+
/* @__PURE__ */ jsxs(StatCard, { $delay: "0.2s", $borderColor: "var(--colors-success600, #22C55E)", $accentColor: "var(--colors-success600, #16A34A)", children: [
|
|
509
|
+
/* @__PURE__ */ jsx(StatIcon, { className: "stat-icon", $bg: "rgba(22, 163, 74, 0.12)", $color: "var(--colors-success600, #16A34A)", children: /* @__PURE__ */ jsx(User, {}) }),
|
|
517
510
|
/* @__PURE__ */ jsx(StatValue, { className: "stat-value", children: analytics?.activeSessions || 0 }),
|
|
518
511
|
/* @__PURE__ */ jsx(StatLabel, { children: "Active Now" })
|
|
519
512
|
] }),
|
|
520
|
-
/* @__PURE__ */ jsxs(StatCard, { $delay: "0.3s", $borderColor:
|
|
521
|
-
/* @__PURE__ */ jsx(StatIcon, { className: "stat-icon", $bg:
|
|
513
|
+
/* @__PURE__ */ jsxs(StatCard, { $delay: "0.3s", $borderColor: "var(--colors-warning600, #F59E0B)", $accentColor: "var(--colors-warning600, #D97706)", children: [
|
|
514
|
+
/* @__PURE__ */ jsx(StatIcon, { className: "stat-icon", $bg: "rgba(234, 179, 8, 0.12)", $color: "var(--colors-warning600, #D97706)", children: /* @__PURE__ */ jsx(Clock, {}) }),
|
|
522
515
|
/* @__PURE__ */ jsx(StatValue, { className: "stat-value", children: analytics?.todayLogins || 0 }),
|
|
523
516
|
/* @__PURE__ */ jsx(StatLabel, { children: "Today's Logins" })
|
|
524
517
|
] }),
|
|
525
|
-
/* @__PURE__ */ jsxs(StatCard, { $delay: "0.4s", $borderColor:
|
|
526
|
-
/* @__PURE__ */ jsx(StatIcon, { className: "stat-icon", $bg:
|
|
518
|
+
/* @__PURE__ */ jsxs(StatCard, { $delay: "0.4s", $borderColor: "var(--colors-secondary500, #A855F7)", $accentColor: "var(--colors-secondary600, #9333EA)", children: [
|
|
519
|
+
/* @__PURE__ */ jsx(StatIcon, { className: "stat-icon", $bg: "rgba(139, 92, 246, 0.12)", $color: "var(--colors-secondary600, #9333EA)", children: /* @__PURE__ */ jsx(Clock, {}) }),
|
|
527
520
|
/* @__PURE__ */ jsx(StatValue, { className: "stat-value", children: analytics?.weekLogins || 0 }),
|
|
528
521
|
/* @__PURE__ */ jsx(StatLabel, { children: "This Week" })
|
|
529
522
|
] })
|
|
@@ -540,8 +533,8 @@ const AnalyticsPage = () => {
|
|
|
540
533
|
BarFill,
|
|
541
534
|
{
|
|
542
535
|
$percentage: count / maxDevices * 100,
|
|
543
|
-
$color1: deviceColors[device]?.[0] ||
|
|
544
|
-
$color2: deviceColors[device]?.[1] ||
|
|
536
|
+
$color1: deviceColors[device]?.[0] || "var(--colors-neutral500)",
|
|
537
|
+
$color2: deviceColors[device]?.[1] || "var(--colors-neutral600)",
|
|
545
538
|
$delay: `${0.5 + idx * 0.1}s`,
|
|
546
539
|
children: /* @__PURE__ */ jsx(BarValue, { children: count })
|
|
547
540
|
}
|
|
@@ -559,8 +552,8 @@ const AnalyticsPage = () => {
|
|
|
559
552
|
BarFill,
|
|
560
553
|
{
|
|
561
554
|
$percentage: count / maxBrowsers * 100,
|
|
562
|
-
$color1: browserColors[browser]?.[0] ||
|
|
563
|
-
$color2: browserColors[browser]?.[1] ||
|
|
555
|
+
$color1: browserColors[browser]?.[0] || "var(--colors-neutral500)",
|
|
556
|
+
$color2: browserColors[browser]?.[1] || "var(--colors-neutral600)",
|
|
564
557
|
$delay: `${0.5 + idx * 0.1}s`,
|
|
565
558
|
children: /* @__PURE__ */ jsx(BarValue, { children: count })
|
|
566
559
|
}
|
|
@@ -592,7 +585,7 @@ const AnalyticsPage = () => {
|
|
|
592
585
|
}
|
|
593
586
|
)
|
|
594
587
|
] }),
|
|
595
|
-
analytics?.avgSessionDuration > 0 && /* @__PURE__ */ jsx(Box, { marginTop: 5, padding: 5, background: "primary50", hasRadius: true, style: { border: `1px solid ${
|
|
588
|
+
analytics?.avgSessionDuration > 0 && /* @__PURE__ */ jsx(Box, { marginTop: 5, padding: 5, background: "primary50", hasRadius: true, style: { border: `1px solid ${"rgba(2, 132, 199, 0.12)"}` }, children: /* @__PURE__ */ jsx(Typography, { variant: "omega", textColor: "primary700", style: { fontSize: "14px", lineHeight: "1.8", fontWeight: "500" }, children: "ℹ️ Average time between login and last activity across all sessions. Lower values indicate more frequent activity, higher values may indicate idle or abandoned sessions." }) })
|
|
596
589
|
] })
|
|
597
590
|
] });
|
|
598
591
|
};
|
|
@@ -6,18 +6,11 @@ const admin = require("@strapi/strapi/admin");
|
|
|
6
6
|
const styled = require("styled-components");
|
|
7
7
|
const designSystem = require("@strapi/design-system");
|
|
8
8
|
const icons = require("@strapi/icons");
|
|
9
|
-
const index = require("./index-
|
|
10
|
-
const useLicense = require("./useLicense-
|
|
9
|
+
const index = require("./index-BEh2DizI.js");
|
|
10
|
+
const useLicense = require("./useLicense-DFdVp_qI.js");
|
|
11
11
|
const _interopDefault = (e) => e && e.__esModule ? e : { default: e };
|
|
12
12
|
const styled__default = /* @__PURE__ */ _interopDefault(styled);
|
|
13
13
|
const theme = {
|
|
14
|
-
colors: {
|
|
15
|
-
primary: { 100: "#E0F2FE", 500: "#0EA5E9", 600: "#0284C7" },
|
|
16
|
-
secondary: { 100: "#EDE9FE", 500: "#A855F7", 600: "#9333EA" },
|
|
17
|
-
success: { 100: "#DCFCE7", 500: "#22C55E", 600: "#16A34A" },
|
|
18
|
-
warning: { 100: "#FEF3C7", 500: "#F59E0B", 600: "#D97706" },
|
|
19
|
-
neutral: { 0: "#FFFFFF", 100: "#F3F4F6", 200: "#E5E7EB", 600: "#4B5563", 700: "#374151", 800: "#1F2937" }
|
|
20
|
-
},
|
|
21
14
|
shadows: {
|
|
22
15
|
sm: "0 1px 3px 0 rgba(0, 0, 0, 0.1)",
|
|
23
16
|
md: "0 4px 6px -1px rgba(0, 0, 0, 0.1)",
|
|
@@ -63,7 +56,7 @@ const Container = styled__default.default(designSystem.Box)`
|
|
|
63
56
|
padding: ${theme.spacing.xl} 24px 0;
|
|
64
57
|
`;
|
|
65
58
|
const Header = styled__default.default(designSystem.Box)`
|
|
66
|
-
background: linear-gradient(135deg, ${
|
|
59
|
+
background: linear-gradient(135deg, ${"var(--colors-primary600, #0284C7)"} 0%, ${"var(--colors-secondary600, #9333EA)"} 100%);
|
|
67
60
|
border-radius: ${theme.borderRadius.xl};
|
|
68
61
|
padding: ${theme.spacing.xl} ${theme.spacing["2xl"]};
|
|
69
62
|
margin-bottom: ${theme.spacing.xl};
|
|
@@ -99,7 +92,7 @@ const HeaderContent = styled__default.default(designSystem.Flex)`
|
|
|
99
92
|
z-index: 1;
|
|
100
93
|
`;
|
|
101
94
|
const Title = styled__default.default(designSystem.Typography)`
|
|
102
|
-
color: ${theme.colors.
|
|
95
|
+
color: ${(p) => p.theme.colors.neutral0};
|
|
103
96
|
font-size: 2.25rem;
|
|
104
97
|
font-weight: 700;
|
|
105
98
|
letter-spacing: -0.025em;
|
|
@@ -128,7 +121,7 @@ const StatsGrid = styled__default.default.div`
|
|
|
128
121
|
margin-bottom: 40px;
|
|
129
122
|
`;
|
|
130
123
|
const StatCard = styled__default.default(designSystem.Box)`
|
|
131
|
-
background: ${theme.colors.
|
|
124
|
+
background: ${(p) => p.theme.colors.neutral0};
|
|
132
125
|
border-radius: ${theme.borderRadius.lg};
|
|
133
126
|
padding: 32px;
|
|
134
127
|
position: relative;
|
|
@@ -137,7 +130,7 @@ const StatCard = styled__default.default(designSystem.Box)`
|
|
|
137
130
|
${styled.css`animation: ${fadeIn} ${theme.transitions.slow} backwards;`}
|
|
138
131
|
animation-delay: ${(props) => props.$delay || "0s"};
|
|
139
132
|
box-shadow: ${theme.shadows.sm};
|
|
140
|
-
border: 1px solid ${
|
|
133
|
+
border: 1px solid ${"rgba(128, 128, 128, 0.2)"};
|
|
141
134
|
text-align: center;
|
|
142
135
|
display: flex;
|
|
143
136
|
flex-direction: column;
|
|
@@ -147,7 +140,7 @@ const StatCard = styled__default.default(designSystem.Box)`
|
|
|
147
140
|
&:hover {
|
|
148
141
|
transform: translateY(-6px);
|
|
149
142
|
box-shadow: ${theme.shadows.xl};
|
|
150
|
-
border-color: ${(props) => props.$borderColor ||
|
|
143
|
+
border-color: ${(props) => props.$borderColor || "var(--colors-primary600, #0EA5E9)"};
|
|
151
144
|
|
|
152
145
|
.stat-icon {
|
|
153
146
|
transform: scale(1.15) rotate(5deg);
|
|
@@ -155,7 +148,7 @@ const StatCard = styled__default.default(designSystem.Box)`
|
|
|
155
148
|
|
|
156
149
|
.stat-value {
|
|
157
150
|
transform: scale(1.08);
|
|
158
|
-
color: ${(props) => props.$accentColor ||
|
|
151
|
+
color: ${(props) => props.$accentColor || "var(--colors-primary600, #0284C7)"};
|
|
159
152
|
}
|
|
160
153
|
}
|
|
161
154
|
`;
|
|
@@ -166,7 +159,7 @@ const StatIcon = styled__default.default(designSystem.Box)`
|
|
|
166
159
|
display: flex;
|
|
167
160
|
align-items: center;
|
|
168
161
|
justify-content: center;
|
|
169
|
-
background: ${(props) => props.$bg ||
|
|
162
|
+
background: ${(props) => props.$bg || "rgba(2, 132, 199, 0.12)"};
|
|
170
163
|
transition: all ${theme.transitions.normal};
|
|
171
164
|
margin: 0 auto 24px;
|
|
172
165
|
box-shadow: ${theme.shadows.sm};
|
|
@@ -174,13 +167,13 @@ const StatIcon = styled__default.default(designSystem.Box)`
|
|
|
174
167
|
svg {
|
|
175
168
|
width: 40px;
|
|
176
169
|
height: 40px;
|
|
177
|
-
color: ${(props) => props.$color ||
|
|
170
|
+
color: ${(props) => props.$color || "var(--colors-primary600, #0284C7)"};
|
|
178
171
|
}
|
|
179
172
|
`;
|
|
180
173
|
const StatValue = styled__default.default(designSystem.Typography)`
|
|
181
174
|
font-size: 3.5rem;
|
|
182
175
|
font-weight: 700;
|
|
183
|
-
color: ${
|
|
176
|
+
color: ${"var(--colors-neutral800)"};
|
|
184
177
|
line-height: 1;
|
|
185
178
|
margin-bottom: 12px;
|
|
186
179
|
transition: all ${theme.transitions.normal};
|
|
@@ -188,29 +181,29 @@ const StatValue = styled__default.default(designSystem.Typography)`
|
|
|
188
181
|
`;
|
|
189
182
|
const StatLabel = styled__default.default(designSystem.Typography)`
|
|
190
183
|
font-size: 1rem;
|
|
191
|
-
color: ${
|
|
184
|
+
color: ${"var(--colors-neutral600)"};
|
|
192
185
|
font-weight: 500;
|
|
193
186
|
text-align: center;
|
|
194
187
|
`;
|
|
195
188
|
const ChartCard = styled__default.default(designSystem.Box)`
|
|
196
|
-
background: ${theme.colors.
|
|
189
|
+
background: ${(p) => p.theme.colors.neutral0};
|
|
197
190
|
border-radius: ${theme.borderRadius.lg};
|
|
198
191
|
padding: 36px;
|
|
199
192
|
box-shadow: ${theme.shadows.md};
|
|
200
|
-
border: 1px solid ${
|
|
193
|
+
border: 1px solid ${"rgba(128, 128, 128, 0.2)"};
|
|
201
194
|
margin-bottom: 28px;
|
|
202
195
|
${styled.css`animation: ${slideIn} ${theme.transitions.slow};`}
|
|
203
196
|
transition: all ${theme.transitions.normal};
|
|
204
197
|
|
|
205
198
|
&:hover {
|
|
206
199
|
box-shadow: ${theme.shadows.lg};
|
|
207
|
-
border-color: ${
|
|
200
|
+
border-color: ${"rgba(2, 132, 199, 0.2)"};
|
|
208
201
|
}
|
|
209
202
|
`;
|
|
210
203
|
const ChartTitle = styled__default.default(designSystem.Typography)`
|
|
211
204
|
font-size: 1.25rem;
|
|
212
205
|
font-weight: 700;
|
|
213
|
-
color: ${
|
|
206
|
+
color: ${"var(--colors-neutral800)"};
|
|
214
207
|
margin-bottom: 24px;
|
|
215
208
|
display: flex;
|
|
216
209
|
align-items: center;
|
|
@@ -219,7 +212,7 @@ const ChartTitle = styled__default.default(designSystem.Typography)`
|
|
|
219
212
|
svg {
|
|
220
213
|
width: 24px;
|
|
221
214
|
height: 24px;
|
|
222
|
-
color: ${
|
|
215
|
+
color: ${"var(--colors-primary600, #0284C7)"};
|
|
223
216
|
}
|
|
224
217
|
`;
|
|
225
218
|
const BarChart = styled__default.default.div`
|
|
@@ -238,12 +231,12 @@ const BarLabel = styled__default.default(designSystem.Typography)`
|
|
|
238
231
|
min-width: 110px;
|
|
239
232
|
font-size: 15px;
|
|
240
233
|
font-weight: 600;
|
|
241
|
-
color: ${
|
|
234
|
+
color: ${"var(--colors-neutral700)"};
|
|
242
235
|
`;
|
|
243
236
|
const BarContainer = styled__default.default.div`
|
|
244
237
|
flex: 1;
|
|
245
238
|
height: 40px;
|
|
246
|
-
background: ${
|
|
239
|
+
background: ${"var(--colors-neutral100)"};
|
|
247
240
|
border-radius: 10px;
|
|
248
241
|
overflow: hidden;
|
|
249
242
|
position: relative;
|
|
@@ -251,7 +244,7 @@ const BarContainer = styled__default.default.div`
|
|
|
251
244
|
`;
|
|
252
245
|
const BarFill = styled__default.default.div`
|
|
253
246
|
height: 100%;
|
|
254
|
-
background: linear-gradient(90deg, ${(props) => props.$color1 ||
|
|
247
|
+
background: linear-gradient(90deg, ${(props) => props.$color1 || "var(--colors-primary600, #0EA5E9)"}, ${(props) => props.$color2 || "var(--colors-primary600, #0284C7)"});
|
|
255
248
|
border-radius: 10px;
|
|
256
249
|
--bar-width: ${(props) => props.$percentage || 0}%;
|
|
257
250
|
${styled.css`animation: ${growBar} 1s cubic-bezier(0.4, 0, 0.2, 1) forwards;`}
|
|
@@ -284,7 +277,7 @@ const AnimatedIcon = styled__default.default.div`
|
|
|
284
277
|
${styled.css`animation: ${float} 3s ease-in-out infinite;`}
|
|
285
278
|
width: 96px;
|
|
286
279
|
height: 96px;
|
|
287
|
-
color: #
|
|
280
|
+
color: var(--colors-warning600, #D97706);
|
|
288
281
|
margin: 0 auto 32px;
|
|
289
282
|
display: flex;
|
|
290
283
|
align-items: center;
|
|
@@ -381,7 +374,7 @@ const AnalyticsPage = () => {
|
|
|
381
374
|
};
|
|
382
375
|
if (licenseLoading) {
|
|
383
376
|
return /* @__PURE__ */ jsxRuntime.jsx(Container, { children: /* @__PURE__ */ jsxRuntime.jsxs(LoadingOverlay, { children: [
|
|
384
|
-
/* @__PURE__ */ jsxRuntime.jsx(icons.ChartBubble, { className: "loader-icon", style: { width: "64px", height: "64px", color:
|
|
377
|
+
/* @__PURE__ */ jsxRuntime.jsx(icons.ChartBubble, { className: "loader-icon", style: { width: "64px", height: "64px", color: "var(--colors-primary600, #0284C7)" } }),
|
|
385
378
|
/* @__PURE__ */ jsxRuntime.jsx(designSystem.Loader, { children: "Checking license..." }),
|
|
386
379
|
/* @__PURE__ */ jsxRuntime.jsx(designSystem.Typography, { variant: "pi", textColor: "neutral600", children: "Please wait while we verify your premium access" })
|
|
387
380
|
] }) });
|
|
@@ -392,9 +385,9 @@ const AnalyticsPage = () => {
|
|
|
392
385
|
{
|
|
393
386
|
padding: 10,
|
|
394
387
|
style: {
|
|
395
|
-
background: "linear-gradient(135deg,
|
|
388
|
+
background: "linear-gradient(135deg, rgba(234, 179, 8, 0.12) 0%, rgba(234, 179, 8, 0.25) 100%)",
|
|
396
389
|
borderRadius: "20px",
|
|
397
|
-
border: "3px solid
|
|
390
|
+
border: "3px solid rgba(234, 179, 8, 0.4)",
|
|
398
391
|
textAlign: "center",
|
|
399
392
|
boxShadow: "0 20px 40px rgba(245, 158, 11, 0.2)",
|
|
400
393
|
maxWidth: "800px",
|
|
@@ -421,7 +414,7 @@ const AnalyticsPage = () => {
|
|
|
421
414
|
{
|
|
422
415
|
variant: "alpha",
|
|
423
416
|
style: {
|
|
424
|
-
color: "#92400e",
|
|
417
|
+
color: "var(--colors-warning600, #92400e)",
|
|
425
418
|
fontWeight: "700",
|
|
426
419
|
marginBottom: "24px",
|
|
427
420
|
fontSize: "36px",
|
|
@@ -436,7 +429,7 @@ const AnalyticsPage = () => {
|
|
|
436
429
|
{
|
|
437
430
|
variant: "omega",
|
|
438
431
|
style: {
|
|
439
|
-
color: "#78350f",
|
|
432
|
+
color: "var(--colors-warning600, #78350f)",
|
|
440
433
|
lineHeight: "1.9",
|
|
441
434
|
marginBottom: "44px",
|
|
442
435
|
fontSize: "17px",
|
|
@@ -452,7 +445,7 @@ const AnalyticsPage = () => {
|
|
|
452
445
|
{
|
|
453
446
|
onClick: () => window.open("https://magicapi.fitlex.me", "_blank"),
|
|
454
447
|
style: {
|
|
455
|
-
background: "linear-gradient(135deg, #f59e0b 0%, #d97706 100%)",
|
|
448
|
+
background: "linear-gradient(135deg, var(--colors-warning600, #f59e0b) 0%, var(--colors-warning600, #d97706) 100%)",
|
|
456
449
|
color: "white",
|
|
457
450
|
border: "none",
|
|
458
451
|
padding: "16px 48px",
|
|
@@ -481,7 +474,7 @@ const AnalyticsPage = () => {
|
|
|
481
474
|
}
|
|
482
475
|
if (loading) {
|
|
483
476
|
return /* @__PURE__ */ jsxRuntime.jsx(Container, { children: /* @__PURE__ */ jsxRuntime.jsxs(LoadingOverlay, { children: [
|
|
484
|
-
/* @__PURE__ */ jsxRuntime.jsx(icons.ChartBubble, { className: "loader-icon", style: { width: "64px", height: "64px", color:
|
|
477
|
+
/* @__PURE__ */ jsxRuntime.jsx(icons.ChartBubble, { className: "loader-icon", style: { width: "64px", height: "64px", color: "var(--colors-primary600, #0284C7)" } }),
|
|
485
478
|
/* @__PURE__ */ jsxRuntime.jsx(designSystem.Loader, { children: "Loading analytics data..." })
|
|
486
479
|
] }) });
|
|
487
480
|
}
|
|
@@ -490,17 +483,17 @@ const AnalyticsPage = () => {
|
|
|
490
483
|
Math.max(...Object.values(analytics?.operatingSystems || {}), 1);
|
|
491
484
|
Math.max(...analytics?.loginHours || [], 1);
|
|
492
485
|
const deviceColors = {
|
|
493
|
-
"Desktop": [
|
|
494
|
-
"Mobile": [
|
|
495
|
-
"Tablet": [
|
|
486
|
+
"Desktop": ["var(--colors-primary600, #0EA5E9)", "var(--colors-primary600, #0284C7)"],
|
|
487
|
+
"Mobile": ["var(--colors-success600, #22C55E)", "var(--colors-success600, #16A34A)"],
|
|
488
|
+
"Tablet": ["var(--colors-warning600, #F59E0B)", "var(--colors-warning600, #D97706)"]
|
|
496
489
|
};
|
|
497
490
|
const browserColors = {
|
|
498
|
-
"Chrome": [
|
|
499
|
-
"Firefox": [
|
|
500
|
-
"Safari": [
|
|
501
|
-
"Edge": [
|
|
502
|
-
"API Client": [
|
|
503
|
-
"Other": [
|
|
491
|
+
"Chrome": ["var(--colors-success600, #22C55E)", "var(--colors-success600, #16A34A)"],
|
|
492
|
+
"Firefox": ["var(--colors-warning600, #F59E0B)", "var(--colors-warning600, #D97706)"],
|
|
493
|
+
"Safari": ["var(--colors-primary600, #0EA5E9)", "var(--colors-primary600, #0284C7)"],
|
|
494
|
+
"Edge": ["var(--colors-secondary500, #A855F7)", "var(--colors-secondary600, #9333EA)"],
|
|
495
|
+
"API Client": ["var(--colors-neutral600)", "var(--colors-neutral700)"],
|
|
496
|
+
"Other": ["var(--colors-neutral500)", "var(--colors-neutral600)"]
|
|
504
497
|
};
|
|
505
498
|
return /* @__PURE__ */ jsxRuntime.jsxs(Container, { children: [
|
|
506
499
|
/* @__PURE__ */ jsxRuntime.jsx(Header, { children: /* @__PURE__ */ jsxRuntime.jsxs(HeaderContent, { direction: "column", alignItems: "flex-start", gap: 2, children: [
|
|
@@ -511,23 +504,23 @@ const AnalyticsPage = () => {
|
|
|
511
504
|
/* @__PURE__ */ jsxRuntime.jsx(Subtitle, { children: "Comprehensive insights and statistics about user sessions" })
|
|
512
505
|
] }) }),
|
|
513
506
|
/* @__PURE__ */ jsxRuntime.jsxs(StatsGrid, { children: [
|
|
514
|
-
/* @__PURE__ */ jsxRuntime.jsxs(StatCard, { $delay: "0.1s", $borderColor:
|
|
515
|
-
/* @__PURE__ */ jsxRuntime.jsx(StatIcon, { className: "stat-icon", $bg:
|
|
507
|
+
/* @__PURE__ */ jsxRuntime.jsxs(StatCard, { $delay: "0.1s", $borderColor: "var(--colors-primary600, #0EA5E9)", $accentColor: "var(--colors-primary600, #0284C7)", children: [
|
|
508
|
+
/* @__PURE__ */ jsxRuntime.jsx(StatIcon, { className: "stat-icon", $bg: "rgba(2, 132, 199, 0.12)", $color: "var(--colors-primary600, #0284C7)", children: /* @__PURE__ */ jsxRuntime.jsx(icons.ChartBubble, {}) }),
|
|
516
509
|
/* @__PURE__ */ jsxRuntime.jsx(StatValue, { className: "stat-value", children: analytics?.totalSessions || 0 }),
|
|
517
510
|
/* @__PURE__ */ jsxRuntime.jsx(StatLabel, { children: "Total Sessions" })
|
|
518
511
|
] }),
|
|
519
|
-
/* @__PURE__ */ jsxRuntime.jsxs(StatCard, { $delay: "0.2s", $borderColor:
|
|
520
|
-
/* @__PURE__ */ jsxRuntime.jsx(StatIcon, { className: "stat-icon", $bg:
|
|
512
|
+
/* @__PURE__ */ jsxRuntime.jsxs(StatCard, { $delay: "0.2s", $borderColor: "var(--colors-success600, #22C55E)", $accentColor: "var(--colors-success600, #16A34A)", children: [
|
|
513
|
+
/* @__PURE__ */ jsxRuntime.jsx(StatIcon, { className: "stat-icon", $bg: "rgba(22, 163, 74, 0.12)", $color: "var(--colors-success600, #16A34A)", children: /* @__PURE__ */ jsxRuntime.jsx(icons.User, {}) }),
|
|
521
514
|
/* @__PURE__ */ jsxRuntime.jsx(StatValue, { className: "stat-value", children: analytics?.activeSessions || 0 }),
|
|
522
515
|
/* @__PURE__ */ jsxRuntime.jsx(StatLabel, { children: "Active Now" })
|
|
523
516
|
] }),
|
|
524
|
-
/* @__PURE__ */ jsxRuntime.jsxs(StatCard, { $delay: "0.3s", $borderColor:
|
|
525
|
-
/* @__PURE__ */ jsxRuntime.jsx(StatIcon, { className: "stat-icon", $bg:
|
|
517
|
+
/* @__PURE__ */ jsxRuntime.jsxs(StatCard, { $delay: "0.3s", $borderColor: "var(--colors-warning600, #F59E0B)", $accentColor: "var(--colors-warning600, #D97706)", children: [
|
|
518
|
+
/* @__PURE__ */ jsxRuntime.jsx(StatIcon, { className: "stat-icon", $bg: "rgba(234, 179, 8, 0.12)", $color: "var(--colors-warning600, #D97706)", children: /* @__PURE__ */ jsxRuntime.jsx(icons.Clock, {}) }),
|
|
526
519
|
/* @__PURE__ */ jsxRuntime.jsx(StatValue, { className: "stat-value", children: analytics?.todayLogins || 0 }),
|
|
527
520
|
/* @__PURE__ */ jsxRuntime.jsx(StatLabel, { children: "Today's Logins" })
|
|
528
521
|
] }),
|
|
529
|
-
/* @__PURE__ */ jsxRuntime.jsxs(StatCard, { $delay: "0.4s", $borderColor:
|
|
530
|
-
/* @__PURE__ */ jsxRuntime.jsx(StatIcon, { className: "stat-icon", $bg:
|
|
522
|
+
/* @__PURE__ */ jsxRuntime.jsxs(StatCard, { $delay: "0.4s", $borderColor: "var(--colors-secondary500, #A855F7)", $accentColor: "var(--colors-secondary600, #9333EA)", children: [
|
|
523
|
+
/* @__PURE__ */ jsxRuntime.jsx(StatIcon, { className: "stat-icon", $bg: "rgba(139, 92, 246, 0.12)", $color: "var(--colors-secondary600, #9333EA)", children: /* @__PURE__ */ jsxRuntime.jsx(icons.Clock, {}) }),
|
|
531
524
|
/* @__PURE__ */ jsxRuntime.jsx(StatValue, { className: "stat-value", children: analytics?.weekLogins || 0 }),
|
|
532
525
|
/* @__PURE__ */ jsxRuntime.jsx(StatLabel, { children: "This Week" })
|
|
533
526
|
] })
|
|
@@ -544,8 +537,8 @@ const AnalyticsPage = () => {
|
|
|
544
537
|
BarFill,
|
|
545
538
|
{
|
|
546
539
|
$percentage: count / maxDevices * 100,
|
|
547
|
-
$color1: deviceColors[device]?.[0] ||
|
|
548
|
-
$color2: deviceColors[device]?.[1] ||
|
|
540
|
+
$color1: deviceColors[device]?.[0] || "var(--colors-neutral500)",
|
|
541
|
+
$color2: deviceColors[device]?.[1] || "var(--colors-neutral600)",
|
|
549
542
|
$delay: `${0.5 + idx * 0.1}s`,
|
|
550
543
|
children: /* @__PURE__ */ jsxRuntime.jsx(BarValue, { children: count })
|
|
551
544
|
}
|
|
@@ -563,8 +556,8 @@ const AnalyticsPage = () => {
|
|
|
563
556
|
BarFill,
|
|
564
557
|
{
|
|
565
558
|
$percentage: count / maxBrowsers * 100,
|
|
566
|
-
$color1: browserColors[browser]?.[0] ||
|
|
567
|
-
$color2: browserColors[browser]?.[1] ||
|
|
559
|
+
$color1: browserColors[browser]?.[0] || "var(--colors-neutral500)",
|
|
560
|
+
$color2: browserColors[browser]?.[1] || "var(--colors-neutral600)",
|
|
568
561
|
$delay: `${0.5 + idx * 0.1}s`,
|
|
569
562
|
children: /* @__PURE__ */ jsxRuntime.jsx(BarValue, { children: count })
|
|
570
563
|
}
|
|
@@ -596,7 +589,7 @@ const AnalyticsPage = () => {
|
|
|
596
589
|
}
|
|
597
590
|
)
|
|
598
591
|
] }),
|
|
599
|
-
analytics?.avgSessionDuration > 0 && /* @__PURE__ */ jsxRuntime.jsx(designSystem.Box, { marginTop: 5, padding: 5, background: "primary50", hasRadius: true, style: { border: `1px solid ${
|
|
592
|
+
analytics?.avgSessionDuration > 0 && /* @__PURE__ */ jsxRuntime.jsx(designSystem.Box, { marginTop: 5, padding: 5, background: "primary50", hasRadius: true, style: { border: `1px solid ${"rgba(2, 132, 199, 0.12)"}` }, children: /* @__PURE__ */ jsxRuntime.jsx(designSystem.Typography, { variant: "omega", textColor: "primary700", style: { fontSize: "14px", lineHeight: "1.8", fontWeight: "500" }, children: "ℹ️ Average time between login and last activity across all sessions. Lower values indicate more frequent activity, higher values may indicate idle or abandoned sessions." }) })
|
|
600
593
|
] })
|
|
601
594
|
] });
|
|
602
595
|
};
|