strapi-plugin-magic-sessionmanager 4.2.16 → 4.3.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.
@@ -6,8 +6,8 @@ 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-BuxWeACw.js");
10
- const useLicense = require("./useLicense-D7FSpX8c.js");
9
+ const index = require("./index-Cf1Wqdeg.js");
10
+ const useLicense = require("./useLicense-DOnfhNxz.js");
11
11
  const _interopDefault = (e) => e && e.__esModule ? e : { default: e };
12
12
  const styled__default = /* @__PURE__ */ _interopDefault(styled);
13
13
  const theme = {
@@ -4,8 +4,8 @@ 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-CUSrDKCG.mjs";
8
- import { u as useLicense } from "./useLicense-xjKLHcVq.mjs";
7
+ import { a as pluginId } from "./index-Dpdcg2zl.mjs";
8
+ import { u as useLicense } from "./useLicense-CThICQyr.mjs";
9
9
  const theme = {
10
10
  colors: {
11
11
  primary: { 100: "#E0F2FE", 500: "#0EA5E9", 600: "#0284C7" },
@@ -3,10 +3,10 @@ import { useState, useEffect } from "react";
3
3
  import { useIntl } from "react-intl";
4
4
  import { useFetchClient, useNotification } from "@strapi/strapi/admin";
5
5
  import styled, { css, keyframes } from "styled-components";
6
- import { p as parseUserAgent, a as pluginId, g as getTranslation } from "./index-CUSrDKCG.mjs";
6
+ import { p as parseUserAgent, a as pluginId, g as getTranslation } from "./index-Dpdcg2zl.mjs";
7
7
  import { Modal, Flex, Box, Typography, Badge, Divider, Button, Loader, SingleSelect, SingleSelectOption, Thead, Tr, Th, Tbody, Td, Table, TextInput } from "@strapi/design-system";
8
8
  import { Check, Information, Monitor, Server, Clock, Cross, Earth, Shield, Crown, Phone, Download, User, Eye, Trash, Search, Key } from "@strapi/icons";
9
- import { u as useLicense } from "./useLicense-xjKLHcVq.mjs";
9
+ import { u as useLicense } from "./useLicense-CThICQyr.mjs";
10
10
  import { useNavigate } from "react-router-dom";
11
11
  const theme = {
12
12
  colors: {
@@ -5,10 +5,10 @@ const react = require("react");
5
5
  const reactIntl = require("react-intl");
6
6
  const admin = require("@strapi/strapi/admin");
7
7
  const styled = require("styled-components");
8
- const index = require("./index-BuxWeACw.js");
8
+ const index = require("./index-Cf1Wqdeg.js");
9
9
  const designSystem = require("@strapi/design-system");
10
10
  const icons = require("@strapi/icons");
11
- const useLicense = require("./useLicense-D7FSpX8c.js");
11
+ const useLicense = require("./useLicense-DOnfhNxz.js");
12
12
  const reactRouterDom = require("react-router-dom");
13
13
  const _interopDefault = (e) => e && e.__esModule ? e : { default: e };
14
14
  const styled__default = /* @__PURE__ */ _interopDefault(styled);
@@ -4,7 +4,7 @@ import { Loader, Box, Alert, Flex, Typography, Button, Badge, Accordion } from "
4
4
  import { useFetchClient, useNotification } from "@strapi/strapi/admin";
5
5
  import { ArrowClockwise, Duplicate, Download, User, Shield, Sparkle, ChartBubble } from "@strapi/icons";
6
6
  import styled, { css, keyframes } from "styled-components";
7
- import { a as pluginId } from "./index-CUSrDKCG.mjs";
7
+ import { a as pluginId } from "./index-Dpdcg2zl.mjs";
8
8
  const theme = {
9
9
  borderRadius: { lg: "12px" }
10
10
  };
@@ -6,7 +6,7 @@ const designSystem = require("@strapi/design-system");
6
6
  const admin = require("@strapi/strapi/admin");
7
7
  const icons = require("@strapi/icons");
8
8
  const styled = require("styled-components");
9
- const index = require("./index-BuxWeACw.js");
9
+ const index = require("./index-Cf1Wqdeg.js");
10
10
  const _interopDefault = (e) => e && e.__esModule ? e : { default: e };
11
11
  const styled__default = /* @__PURE__ */ _interopDefault(styled);
12
12
  const theme = {
@@ -6,7 +6,7 @@ const reactIntl = require("react-intl");
6
6
  const designSystem = require("@strapi/design-system");
7
7
  const icons = require("@strapi/icons");
8
8
  const admin = require("@strapi/strapi/admin");
9
- const index = require("./index-BuxWeACw.js");
9
+ const index = require("./index-Cf1Wqdeg.js");
10
10
  const OnlineUsersWidget = () => {
11
11
  const { formatMessage } = reactIntl.useIntl();
12
12
  const { get } = admin.useFetchClient();
@@ -4,7 +4,7 @@ import { useIntl } from "react-intl";
4
4
  import { Box, Typography, Flex, Grid } from "@strapi/design-system";
5
5
  import { Check, Cross, Clock, User } from "@strapi/icons";
6
6
  import { useFetchClient } from "@strapi/strapi/admin";
7
- import { g as getTranslation } from "./index-CUSrDKCG.mjs";
7
+ import { g as getTranslation } from "./index-Dpdcg2zl.mjs";
8
8
  const OnlineUsersWidget = () => {
9
9
  const { formatMessage } = useIntl();
10
10
  const { get } = useFetchClient();
@@ -7,10 +7,376 @@ const designSystem = require("@strapi/design-system");
7
7
  const admin = require("@strapi/strapi/admin");
8
8
  const icons = require("@strapi/icons");
9
9
  const styled = require("styled-components");
10
- const index = require("./index-BuxWeACw.js");
11
- const useLicense = require("./useLicense-D7FSpX8c.js");
10
+ const index = require("./index-Cf1Wqdeg.js");
11
+ const useLicense = require("./useLicense-DOnfhNxz.js");
12
12
  const _interopDefault = (e) => e && e.__esModule ? e : { default: e };
13
13
  const styled__default = /* @__PURE__ */ _interopDefault(styled);
14
+ const GradientButton = styled__default.default(designSystem.Button)`
15
+ && {
16
+ background: linear-gradient(135deg, #0EA5E9 0%, #A855F7 100%);
17
+ color: white;
18
+ font-weight: 600;
19
+ border: none;
20
+ padding: 10px 20px;
21
+ min-height: 40px;
22
+ transition: all 0.2s ease;
23
+
24
+ &:hover:not(:disabled) {
25
+ background: linear-gradient(135deg, #0284C7 0%, #9333EA 100%);
26
+ transform: translateY(-1px);
27
+ box-shadow: 0 4px 12px rgba(14, 165, 233, 0.3);
28
+ }
29
+
30
+ &:active:not(:disabled) {
31
+ transform: translateY(0);
32
+ }
33
+
34
+ &:disabled {
35
+ opacity: 0.6;
36
+ cursor: not-allowed;
37
+ }
38
+ }
39
+ `;
40
+ const SecondaryButton = styled__default.default(designSystem.Button)`
41
+ && {
42
+ background: white;
43
+ color: #7C3AED;
44
+ font-weight: 600;
45
+ border: 2px solid transparent;
46
+ background-image: linear-gradient(white, white), linear-gradient(135deg, #0EA5E9 0%, #A855F7 100%);
47
+ background-origin: border-box;
48
+ background-clip: padding-box, border-box;
49
+ padding: 10px 20px;
50
+ min-height: 40px;
51
+ transition: all 0.2s ease;
52
+
53
+ &:hover:not(:disabled) {
54
+ background: linear-gradient(135deg, #0EA5E9 0%, #A855F7 100%);
55
+ background-clip: padding-box;
56
+ color: white;
57
+ transform: translateY(-1px);
58
+ box-shadow: 0 4px 12px rgba(168, 85, 247, 0.3);
59
+ }
60
+
61
+ &:active:not(:disabled) {
62
+ transform: translateY(0);
63
+ }
64
+
65
+ &:disabled {
66
+ opacity: 0.6;
67
+ cursor: not-allowed;
68
+ }
69
+ }
70
+ `;
71
+ const TertiaryButton = styled__default.default(designSystem.Button)`
72
+ && {
73
+ background: transparent;
74
+ color: #64748B;
75
+ font-weight: 500;
76
+ border: 1px solid #E2E8F0;
77
+ padding: 10px 20px;
78
+ min-height: 40px;
79
+ transition: all 0.2s ease;
80
+
81
+ &:hover:not(:disabled) {
82
+ background: #F1F5F9;
83
+ border-color: #CBD5E1;
84
+ color: #334155;
85
+ }
86
+
87
+ &:disabled {
88
+ opacity: 0.6;
89
+ cursor: not-allowed;
90
+ }
91
+ }
92
+ `;
93
+ const DangerButton = styled__default.default(designSystem.Button)`
94
+ && {
95
+ background: #FEE2E2;
96
+ color: #DC2626;
97
+ font-weight: 600;
98
+ border: 1px solid #FECACA;
99
+ padding: 10px 20px;
100
+ min-height: 40px;
101
+ transition: all 0.2s ease;
102
+
103
+ &:hover:not(:disabled) {
104
+ background: #DC2626;
105
+ color: white;
106
+ border-color: #DC2626;
107
+ }
108
+
109
+ &:disabled {
110
+ opacity: 0.6;
111
+ cursor: not-allowed;
112
+ }
113
+ }
114
+ `;
115
+ styled__default.default(designSystem.Button)`
116
+ && {
117
+ background: linear-gradient(135deg, #10B981 0%, #059669 100%);
118
+ color: white;
119
+ font-weight: 600;
120
+ border: none;
121
+ padding: 10px 20px;
122
+ min-height: 40px;
123
+ transition: all 0.2s ease;
124
+
125
+ &:hover:not(:disabled) {
126
+ background: linear-gradient(135deg, #059669 0%, #047857 100%);
127
+ transform: translateY(-1px);
128
+ box-shadow: 0 4px 12px rgba(16, 185, 129, 0.3);
129
+ }
130
+
131
+ &:disabled {
132
+ opacity: 0.6;
133
+ cursor: not-allowed;
134
+ }
135
+ }
136
+ `;
137
+ styled__default.default(designSystem.Button)`
138
+ && {
139
+ background: linear-gradient(135deg, #F8FAFC 0%, #F1F5F9 100%);
140
+ color: #64748B;
141
+ border: 1px solid #E2E8F0;
142
+ padding: 8px;
143
+ min-width: 38px;
144
+ min-height: 38px;
145
+ width: 38px;
146
+ height: 38px;
147
+ border-radius: 10px;
148
+ display: flex;
149
+ align-items: center;
150
+ justify-content: center;
151
+ transition: all 0.2s ease;
152
+ box-shadow: 0 1px 2px rgba(0, 0, 0, 0.04);
153
+
154
+ svg {
155
+ width: 18px;
156
+ height: 18px;
157
+ }
158
+
159
+ &:hover:not(:disabled) {
160
+ background: linear-gradient(135deg, #0EA5E9 0%, #0284C7 100%);
161
+ border-color: #0EA5E9;
162
+ color: white;
163
+ transform: translateY(-1px);
164
+ box-shadow: 0 4px 12px rgba(14, 165, 233, 0.25);
165
+ }
166
+
167
+ &:disabled {
168
+ opacity: 0.6;
169
+ cursor: not-allowed;
170
+ }
171
+ }
172
+ `;
173
+ styled__default.default(designSystem.Button)`
174
+ && {
175
+ background: linear-gradient(135deg, #FEF2F2 0%, #FEE2E2 100%);
176
+ color: #EF4444;
177
+ border: 1px solid #FECACA;
178
+ padding: 8px;
179
+ min-width: 38px;
180
+ min-height: 38px;
181
+ width: 38px;
182
+ height: 38px;
183
+ border-radius: 10px;
184
+ display: flex;
185
+ align-items: center;
186
+ justify-content: center;
187
+ transition: all 0.2s ease;
188
+ box-shadow: 0 1px 2px rgba(0, 0, 0, 0.04);
189
+
190
+ svg {
191
+ width: 18px;
192
+ height: 18px;
193
+ }
194
+
195
+ &:hover:not(:disabled) {
196
+ background: linear-gradient(135deg, #EF4444 0%, #DC2626 100%);
197
+ border-color: #EF4444;
198
+ color: white;
199
+ transform: translateY(-1px);
200
+ box-shadow: 0 4px 12px rgba(239, 68, 68, 0.3);
201
+ }
202
+
203
+ &:disabled {
204
+ opacity: 0.6;
205
+ cursor: not-allowed;
206
+ }
207
+ }
208
+ `;
209
+ styled__default.default(designSystem.Button)`
210
+ && {
211
+ background: linear-gradient(135deg, #F0F9FF 0%, #E0F2FE 100%);
212
+ color: #0EA5E9;
213
+ border: 1px solid #BAE6FD;
214
+ padding: 8px;
215
+ min-width: 38px;
216
+ min-height: 38px;
217
+ width: 38px;
218
+ height: 38px;
219
+ border-radius: 10px;
220
+ display: flex;
221
+ align-items: center;
222
+ justify-content: center;
223
+ transition: all 0.2s ease;
224
+ box-shadow: 0 1px 2px rgba(0, 0, 0, 0.04);
225
+
226
+ svg {
227
+ width: 18px;
228
+ height: 18px;
229
+ }
230
+
231
+ &:hover:not(:disabled) {
232
+ background: linear-gradient(135deg, #0EA5E9 0%, #0284C7 100%);
233
+ border-color: #0EA5E9;
234
+ color: white;
235
+ transform: translateY(-1px);
236
+ box-shadow: 0 4px 12px rgba(14, 165, 233, 0.3);
237
+ }
238
+
239
+ &:disabled {
240
+ opacity: 0.6;
241
+ cursor: not-allowed;
242
+ }
243
+ }
244
+ `;
245
+ styled__default.default(designSystem.Button)`
246
+ && {
247
+ background: linear-gradient(135deg, #F0FDF4 0%, #DCFCE7 100%);
248
+ color: #22C55E;
249
+ border: 1px solid #BBF7D0;
250
+ padding: 8px;
251
+ min-width: 38px;
252
+ min-height: 38px;
253
+ width: 38px;
254
+ height: 38px;
255
+ border-radius: 10px;
256
+ display: flex;
257
+ align-items: center;
258
+ justify-content: center;
259
+ transition: all 0.2s ease;
260
+ box-shadow: 0 1px 2px rgba(0, 0, 0, 0.04);
261
+
262
+ svg {
263
+ width: 18px;
264
+ height: 18px;
265
+ }
266
+
267
+ &:hover:not(:disabled) {
268
+ background: linear-gradient(135deg, #22C55E 0%, #16A34A 100%);
269
+ border-color: #22C55E;
270
+ color: white;
271
+ transform: translateY(-1px);
272
+ box-shadow: 0 4px 12px rgba(34, 197, 94, 0.3);
273
+ }
274
+
275
+ &:disabled {
276
+ opacity: 0.6;
277
+ cursor: not-allowed;
278
+ }
279
+ }
280
+ `;
281
+ styled__default.default(designSystem.Button)`
282
+ && {
283
+ background: linear-gradient(135deg, #0EA5E9 0%, #A855F7 100%);
284
+ color: white;
285
+ font-weight: 700;
286
+ font-size: 1rem;
287
+ border: none;
288
+ padding: 14px 28px;
289
+ min-height: 52px;
290
+ border-radius: 12px;
291
+ transition: all 0.2s ease;
292
+ box-shadow: 0 4px 14px rgba(14, 165, 233, 0.25);
293
+
294
+ &:hover:not(:disabled) {
295
+ background: linear-gradient(135deg, #0284C7 0%, #9333EA 100%);
296
+ transform: translateY(-2px);
297
+ box-shadow: 0 6px 20px rgba(14, 165, 233, 0.35);
298
+ }
299
+
300
+ &:active:not(:disabled) {
301
+ transform: translateY(0);
302
+ }
303
+
304
+ &:disabled {
305
+ opacity: 0.6;
306
+ cursor: not-allowed;
307
+ }
308
+ }
309
+ `;
310
+ styled__default.default(designSystem.Button)`
311
+ && {
312
+ background: transparent;
313
+ color: #0EA5E9;
314
+ font-weight: 500;
315
+ border: none;
316
+ padding: 4px 8px;
317
+ min-height: auto;
318
+ text-decoration: underline;
319
+ transition: all 0.2s ease;
320
+
321
+ &:hover:not(:disabled) {
322
+ color: #0284C7;
323
+ text-decoration: none;
324
+ }
325
+
326
+ &:disabled {
327
+ opacity: 0.6;
328
+ cursor: not-allowed;
329
+ }
330
+ }
331
+ `;
332
+ const ShowHideButton = styled__default.default(designSystem.Button)`
333
+ && {
334
+ background: linear-gradient(135deg, #F8FAFC 0%, #F1F5F9 100%);
335
+ color: #64748B;
336
+ font-weight: 600;
337
+ border: 1px solid #E2E8F0;
338
+ padding: 10px 16px;
339
+ min-height: 40px;
340
+ border-radius: 8px;
341
+ transition: all 0.2s ease;
342
+
343
+ &:hover:not(:disabled) {
344
+ background: linear-gradient(135deg, #E2E8F0 0%, #CBD5E1 100%);
345
+ color: #334155;
346
+ transform: translateY(-1px);
347
+ }
348
+
349
+ &:disabled {
350
+ opacity: 0.6;
351
+ cursor: not-allowed;
352
+ }
353
+ }
354
+ `;
355
+ const CopyButton = styled__default.default(designSystem.Button)`
356
+ && {
357
+ background: linear-gradient(135deg, #F0F9FF 0%, #E0F2FE 100%);
358
+ color: #0284C7;
359
+ font-weight: 600;
360
+ border: 1px solid #BAE6FD;
361
+ padding: 10px 16px;
362
+ min-height: 40px;
363
+ border-radius: 8px;
364
+ transition: all 0.2s ease;
365
+
366
+ &:hover:not(:disabled) {
367
+ background: linear-gradient(135deg, #0EA5E9 0%, #0284C7 100%);
368
+ color: white;
369
+ border-color: #0EA5E9;
370
+ transform: translateY(-1px);
371
+ box-shadow: 0 4px 12px rgba(14, 165, 233, 0.25);
372
+ }
373
+
374
+ &:disabled {
375
+ opacity: 0.6;
376
+ cursor: not-allowed;
377
+ }
378
+ }
379
+ `;
14
380
  const theme = {
15
381
  colors: {
16
382
  primary: { 600: "#0284C7", 700: "#075985", 100: "#E0F2FE", 50: "#F0F9FF" },
@@ -641,12 +1007,11 @@ const SettingsPage = () => {
641
1007
  /* @__PURE__ */ jsxRuntime.jsx(designSystem.Typography, { variant: "pi", textColor: "danger600", style: { fontSize: "13px", lineHeight: "1.7" }, children: t("settings.general.danger.description", "Clean All Inactive: Permanently deletes all inactive sessions. This cannot be undone.") })
642
1008
  ] }),
643
1009
  /* @__PURE__ */ jsxRuntime.jsx(
644
- designSystem.Button,
1010
+ DangerButton,
645
1011
  {
646
1012
  onClick: handleCleanInactive,
647
1013
  loading: cleaning,
648
1014
  startIcon: /* @__PURE__ */ jsxRuntime.jsx(icons.Trash, {}),
649
- variant: "danger",
650
1015
  size: "S",
651
1016
  style: { flexShrink: 0 },
652
1017
  children: t("settings.general.danger.cleanNow", "Clean Now")
@@ -705,9 +1070,8 @@ const SettingsPage = () => {
705
1070
  }
706
1071
  ) }),
707
1072
  /* @__PURE__ */ jsxRuntime.jsx(
708
- designSystem.Button,
1073
+ ShowHideButton,
709
1074
  {
710
- variant: "secondary",
711
1075
  onClick: () => setShowEncryptionKey(!showEncryptionKey),
712
1076
  size: "L",
713
1077
  children: showEncryptionKey ? t("settings.security.encryption.hide", "Hide") : t("settings.security.encryption.show", "Show")
@@ -716,9 +1080,8 @@ const SettingsPage = () => {
716
1080
  ] }),
717
1081
  /* @__PURE__ */ jsxRuntime.jsxs(designSystem.Flex, { gap: 3, children: [
718
1082
  /* @__PURE__ */ jsxRuntime.jsx(
719
- designSystem.Button,
1083
+ GradientButton,
720
1084
  {
721
- variant: "default",
722
1085
  startIcon: /* @__PURE__ */ jsxRuntime.jsx(icons.Code, {}),
723
1086
  onClick: () => {
724
1087
  const key = generateSecureKey();
@@ -734,9 +1097,8 @@ const SettingsPage = () => {
734
1097
  }
735
1098
  ),
736
1099
  /* @__PURE__ */ jsxRuntime.jsx(
737
- designSystem.Button,
1100
+ CopyButton,
738
1101
  {
739
- variant: "tertiary",
740
1102
  startIcon: /* @__PURE__ */ jsxRuntime.jsx(icons.Duplicate, {}),
741
1103
  onClick: () => {
742
1104
  if (encryptionKey) {
@@ -753,9 +1115,8 @@ const SettingsPage = () => {
753
1115
  }
754
1116
  ),
755
1117
  /* @__PURE__ */ jsxRuntime.jsx(
756
- designSystem.Button,
1118
+ CopyButton,
757
1119
  {
758
- variant: "tertiary",
759
1120
  startIcon: /* @__PURE__ */ jsxRuntime.jsx(icons.Duplicate, {}),
760
1121
  onClick: () => {
761
1122
  if (encryptionKey) {
@@ -1098,10 +1459,9 @@ const SettingsPage = () => {
1098
1459
  ] }),
1099
1460
  /* @__PURE__ */ jsxRuntime.jsx(designSystem.Badge, { variant: "success", children: t("settings.email.templates.html.badge", "Main Template") })
1100
1461
  ] }),
1101
- /* @__PURE__ */ jsxRuntime.jsxs(
1102
- designSystem.Button,
1462
+ /* @__PURE__ */ jsxRuntime.jsx(
1463
+ TertiaryButton,
1103
1464
  {
1104
- variant: "tertiary",
1105
1465
  size: "S",
1106
1466
  onClick: () => {
1107
1467
  const defaultTemplates = getDefaultTemplates();
@@ -1110,10 +1470,7 @@ const SettingsPage = () => {
1110
1470
  handleChange("emailTemplates", newTemplates);
1111
1471
  toggleNotification({ type: "success", message: t("notifications.success.defaultLoaded", "Default template loaded!") });
1112
1472
  },
1113
- children: [
1114
- "📋 ",
1115
- t("settings.email.templates.html.loadDefault", "Load Default")
1116
- ]
1473
+ children: t("settings.email.templates.html.loadDefault", "Load Default")
1117
1474
  }
1118
1475
  )
1119
1476
  ] }),
@@ -1173,25 +1530,20 @@ const SettingsPage = () => {
1173
1530
  }
1174
1531
  ),
1175
1532
  /* @__PURE__ */ jsxRuntime.jsxs(designSystem.Flex, { gap: 2, style: { marginTop: "12px" }, wrap: "wrap", children: [
1176
- /* @__PURE__ */ jsxRuntime.jsxs(
1177
- designSystem.Button,
1533
+ /* @__PURE__ */ jsxRuntime.jsx(
1534
+ CopyButton,
1178
1535
  {
1179
- variant: "secondary",
1180
1536
  size: "S",
1181
1537
  onClick: () => {
1182
1538
  navigator.clipboard.writeText(settings.emailTemplates[templateKey].html);
1183
1539
  toggleNotification({ type: "success", message: t("notifications.success.htmlCopied", "HTML template copied!") });
1184
1540
  },
1185
- children: [
1186
- "📋 ",
1187
- t("settings.email.templates.html.copy", "Copy Template")
1188
- ]
1541
+ children: t("settings.email.templates.html.copy", "Copy Template")
1189
1542
  }
1190
1543
  ),
1191
- /* @__PURE__ */ jsxRuntime.jsxs(
1192
- designSystem.Button,
1544
+ /* @__PURE__ */ jsxRuntime.jsx(
1545
+ SecondaryButton,
1193
1546
  {
1194
- variant: "tertiary",
1195
1547
  size: "S",
1196
1548
  onClick: () => {
1197
1549
  const validation = validateTemplate(settings.emailTemplates[templateKey].html, templateKey);
@@ -1200,16 +1552,12 @@ const SettingsPage = () => {
1200
1552
  message: validation.isValid ? t("notifications.success.validated", "Template valid! Found {found}/{total} variables.", { found: validation.foundVars.length, total: validation.totalAvailable }) : t("notifications.warning.noVariables", "[WARNING] No variables found. Add at least one variable.")
1201
1553
  });
1202
1554
  },
1203
- children: [
1204
- "✓ ",
1205
- t("settings.email.templates.html.validate", "Validate")
1206
- ]
1555
+ children: t("settings.email.templates.html.validate", "Validate")
1207
1556
  }
1208
1557
  ),
1209
- /* @__PURE__ */ jsxRuntime.jsxs(
1210
- designSystem.Button,
1558
+ /* @__PURE__ */ jsxRuntime.jsx(
1559
+ TertiaryButton,
1211
1560
  {
1212
- variant: "tertiary",
1213
1561
  size: "S",
1214
1562
  onClick: () => {
1215
1563
  const lines = settings.emailTemplates[templateKey].html.split("\n").length;
@@ -1219,10 +1567,7 @@ const SettingsPage = () => {
1219
1567
  message: t("notifications.info.templateStats", "Template has {lines} lines and {chars} characters", { lines, chars })
1220
1568
  });
1221
1569
  },
1222
- children: [
1223
- "ℹ️ ",
1224
- t("settings.email.templates.html.info", "Template Info")
1225
- ]
1570
+ children: t("settings.email.templates.html.info", "Template Info")
1226
1571
  }
1227
1572
  )
1228
1573
  ] })
@@ -1244,10 +1589,9 @@ const SettingsPage = () => {
1244
1589
  ] }),
1245
1590
  /* @__PURE__ */ jsxRuntime.jsx(designSystem.Badge, { variant: "secondary", children: t("settings.email.templates.text.badge", "Fallback") })
1246
1591
  ] }),
1247
- /* @__PURE__ */ jsxRuntime.jsxs(
1248
- designSystem.Button,
1592
+ /* @__PURE__ */ jsxRuntime.jsx(
1593
+ TertiaryButton,
1249
1594
  {
1250
- variant: "tertiary",
1251
1595
  size: "S",
1252
1596
  onClick: () => {
1253
1597
  const defaultTemplates = getDefaultTemplates();
@@ -1256,10 +1600,7 @@ const SettingsPage = () => {
1256
1600
  handleChange("emailTemplates", newTemplates);
1257
1601
  toggleNotification({ type: "success", message: t("notifications.success.defaultLoaded", "Default template loaded!") });
1258
1602
  },
1259
- children: [
1260
- "📋 ",
1261
- t("settings.email.templates.text.loadDefault", "Load Default")
1262
- ]
1603
+ children: t("settings.email.templates.text.loadDefault", "Load Default")
1263
1604
  }
1264
1605
  )
1265
1606
  ] }),
@@ -1318,19 +1659,15 @@ const SettingsPage = () => {
1318
1659
  ]
1319
1660
  }
1320
1661
  ),
1321
- /* @__PURE__ */ jsxRuntime.jsx(designSystem.Flex, { gap: 2, style: { marginTop: "12px" }, wrap: "wrap", children: /* @__PURE__ */ jsxRuntime.jsxs(
1322
- designSystem.Button,
1662
+ /* @__PURE__ */ jsxRuntime.jsx(designSystem.Flex, { gap: 2, style: { marginTop: "12px" }, wrap: "wrap", children: /* @__PURE__ */ jsxRuntime.jsx(
1663
+ CopyButton,
1323
1664
  {
1324
- variant: "secondary",
1325
1665
  size: "S",
1326
1666
  onClick: () => {
1327
1667
  navigator.clipboard.writeText(settings.emailTemplates[templateKey].text);
1328
1668
  toggleNotification({ type: "success", message: t("notifications.success.textCopied", "Text template copied!") });
1329
1669
  },
1330
- children: [
1331
- "📋 ",
1332
- t("settings.email.templates.text.copy", "Copy Template")
1333
- ]
1670
+ children: t("settings.email.templates.text.copy", "Copy Template")
1334
1671
  }
1335
1672
  ) })
1336
1673
  ]