strapi-plugin-magic-link-v5 5.3.15 → 5.3.17

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.
@@ -5,7 +5,7 @@ import styled, { keyframes, css } from "styled-components";
5
5
  import { useIntl } from "react-intl";
6
6
  import { Box, Flex, Typography, Button, TextInput, Textarea, Checkbox, IconButton, Loader, Searchbar, SingleSelect, SingleSelectOption, Thead, Tr, Th, Tbody, Td, Pagination, PreviousLink, PageLink, NextLink, Table, Badge, VisuallyHidden, Main } from "@strapi/design-system";
7
7
  import { Cross, Sparkle, Check, Shield, Clock, Lock, Trash, ArrowClockwise, CaretDown, User, Monitor, Calendar, Plus, Earth, WarningCircle, Server, Eye, Mail, Cog, Key, Link } from "@strapi/icons";
8
- import { g as getTrad, P as PLUGIN_ID } from "./index-Df4P6nwt.mjs";
8
+ import { g as getTrad, P as PLUGIN_ID } from "./index-BgpjdW58.mjs";
9
9
  import { useFetchClient, useNotification } from "@strapi/strapi/admin";
10
10
  import { L as LicenseGuard, a as LanguageProvider } from "./LicenseGuard-B_r3b1Vh.mjs";
11
11
  const CreateTokenModal = ({ isOpen, onClose, onSubmit, formData, setFormData }) => {
@@ -421,12 +421,12 @@ const ExtendTokenModal = ({
421
421
  paddingLeft: 6,
422
422
  paddingRight: 5,
423
423
  style: {
424
- borderBottom: "1px solid rgba(255,255,255,0.08)"
424
+ borderBottom: "1px solid rgba(128, 128, 128, 0.15)"
425
425
  },
426
426
  children: [
427
427
  /* @__PURE__ */ jsxs(Flex, { direction: "column", gap: 1, alignItems: "flex-start", children: [
428
- /* @__PURE__ */ jsx(Typography, { variant: "beta", style: { fontSize: "16px", fontWeight: "600", color: "#ffffff" }, children: formatMessage({ id: getTrad("tokens.extend.title") }) }),
429
- /* @__PURE__ */ jsx(Typography, { variant: "pi", style: { fontSize: "13px", color: "rgba(255,255,255,0.6)" }, children: selectedToken.email })
428
+ /* @__PURE__ */ jsx(Typography, { variant: "beta", textColor: "neutral800", style: { fontSize: "16px", fontWeight: "600" }, children: formatMessage({ id: getTrad("tokens.extend.title") }) }),
429
+ /* @__PURE__ */ jsx(Typography, { variant: "pi", textColor: "neutral500", style: { fontSize: "13px" }, children: selectedToken.email })
430
430
  ] }),
431
431
  /* @__PURE__ */ jsx(
432
432
  IconButton,
@@ -445,22 +445,23 @@ const ExtendTokenModal = ({
445
445
  Box,
446
446
  {
447
447
  padding: 3,
448
+ background: "neutral100",
448
449
  style: {
449
450
  borderRadius: "6px",
450
451
  textAlign: "center",
451
- background: "rgba(255,255,255,0.06)",
452
- border: "1px solid rgba(255,255,255,0.1)"
452
+ border: "1px solid rgba(128, 128, 128, 0.15)"
453
453
  },
454
454
  children: [
455
455
  /* @__PURE__ */ jsx(
456
456
  Typography,
457
457
  {
458
458
  variant: "omega",
459
- style: { fontSize: "11px", display: "block", marginBottom: "4px", color: "rgba(255,255,255,0.5)" },
459
+ textColor: "neutral500",
460
+ style: { fontSize: "11px", display: "block", marginBottom: "4px" },
460
461
  children: formatMessage({ id: getTrad("tokens.extend.currentExpiry") })
461
462
  }
462
463
  ),
463
- /* @__PURE__ */ jsx(Typography, { variant: "pi", style: { fontSize: "15px", fontWeight: "600", color: "#ffffff" }, children: formatDate2(selectedToken.expires_at) || formatMessage({ id: getTrad("tokens.details.unlimited") }) })
464
+ /* @__PURE__ */ jsx(Typography, { variant: "pi", textColor: "neutral800", style: { fontSize: "15px", fontWeight: "600" }, children: formatDate2(selectedToken.expires_at) || formatMessage({ id: getTrad("tokens.details.unlimited") }) })
464
465
  ]
465
466
  }
466
467
  ),
@@ -469,7 +470,8 @@ const ExtendTokenModal = ({
469
470
  Typography,
470
471
  {
471
472
  variant: "omega",
472
- style: { fontSize: "12px", marginBottom: "12px", display: "block", color: "rgba(255,255,255,0.6)" },
473
+ textColor: "neutral600",
474
+ style: { fontSize: "12px", marginBottom: "12px", display: "block" },
473
475
  children: formatMessage({ id: getTrad("tokens.extend.selectExtension") })
474
476
  }
475
477
  ),
@@ -547,8 +549,8 @@ const ExtendTokenModal = ({
547
549
  ] }),
548
550
  /* @__PURE__ */ jsxs(Box, { children: [
549
551
  /* @__PURE__ */ jsxs(Flex, { alignItems: "center", gap: 1, style: { marginBottom: "8px" }, children: [
550
- /* @__PURE__ */ jsx(Check, { style: { width: "14px", height: "14px", color: "#4ade80" } }),
551
- /* @__PURE__ */ jsx(Typography, { variant: "omega", style: { fontSize: "12px", color: "#4ade80" }, children: formatMessage({ id: getTrad("tokens.extend.newExpiry") }) })
552
+ /* @__PURE__ */ jsx(Check, { style: { width: "14px", height: "14px", color: "#16a34a" } }),
553
+ /* @__PURE__ */ jsx(Typography, { variant: "omega", textColor: "success600", style: { fontSize: "12px" }, children: formatMessage({ id: getTrad("tokens.extend.newExpiry") }) })
552
554
  ] }),
553
555
  /* @__PURE__ */ jsx(
554
556
  Box,
@@ -556,11 +558,11 @@ const ExtendTokenModal = ({
556
558
  padding: 3,
557
559
  style: {
558
560
  borderRadius: "6px",
559
- border: "1px solid rgba(74, 222, 128, 0.3)",
560
- background: "rgba(74, 222, 128, 0.08)",
561
+ border: "1px solid rgba(22, 163, 74, 0.3)",
562
+ background: "rgba(22, 163, 74, 0.06)",
561
563
  textAlign: "center"
562
564
  },
563
- children: /* @__PURE__ */ jsx(Typography, { variant: "pi", style: { fontSize: "15px", color: "#4ade80", fontWeight: "600" }, children: calculateNewExpiryDate() })
565
+ children: /* @__PURE__ */ jsx(Typography, { variant: "pi", textColor: "success600", style: { fontSize: "15px", fontWeight: "600" }, children: calculateNewExpiryDate() })
564
566
  }
565
567
  )
566
568
  ] })
@@ -572,9 +574,9 @@ const ExtendTokenModal = ({
572
574
  paddingBottom: 5,
573
575
  paddingLeft: 6,
574
576
  paddingRight: 6,
577
+ background: "neutral100",
575
578
  style: {
576
- borderTop: "1px solid rgba(255,255,255,0.08)",
577
- background: "rgba(255,255,255,0.03)",
579
+ borderTop: "1px solid rgba(128, 128, 128, 0.12)",
578
580
  borderBottomLeftRadius: "8px",
579
581
  borderBottomRightRadius: "8px"
580
582
  },
@@ -4267,13 +4269,13 @@ const TokensProfessional = () => {
4267
4269
  {
4268
4270
  variant: "pi",
4269
4271
  fontWeight: "semiBold",
4272
+ textColor: "neutral800",
4270
4273
  style: {
4271
4274
  fontFamily: "monospace",
4272
4275
  fontSize: "12px",
4273
- background: "rgba(255, 255, 255, 0.12)",
4276
+ background: "rgba(128, 128, 128, 0.1)",
4274
4277
  padding: "2px 8px",
4275
4278
  borderRadius: "4px",
4276
- color: "#ffffff",
4277
4279
  letterSpacing: "0.5px"
4278
4280
  },
4279
4281
  children: [
@@ -4452,7 +4454,7 @@ const TokensProfessional = () => {
4452
4454
  ),
4453
4455
  /* @__PURE__ */ jsx(Box, { padding: 7, children: /* @__PURE__ */ jsxs(Flex, { direction: "column", alignItems: "stretch", gap: 5, children: [
4454
4456
  /* @__PURE__ */ jsxs(Flex, { alignItems: "center", gap: 3, children: [
4455
- /* @__PURE__ */ jsxs(Typography, { variant: "sigma", fontWeight: "semiBold", style: { fontSize: "12px", color: "rgba(255,255,255,0.6)" }, children: [
4457
+ /* @__PURE__ */ jsxs(Typography, { variant: "sigma", fontWeight: "semiBold", textColor: "neutral500", style: { fontSize: "12px" }, children: [
4456
4458
  formatMessage({ id: getTrad("tokens.details.reference") }),
4457
4459
  ":"
4458
4460
  ] }),
@@ -4461,13 +4463,13 @@ const TokensProfessional = () => {
4461
4463
  {
4462
4464
  variant: "pi",
4463
4465
  fontWeight: "bold",
4466
+ textColor: "neutral800",
4464
4467
  style: {
4465
4468
  fontFamily: "monospace",
4466
4469
  fontSize: "14px",
4467
- background: "rgba(255,255,255,0.12)",
4470
+ background: "rgba(128, 128, 128, 0.1)",
4468
4471
  padding: "4px 12px",
4469
- borderRadius: "6px",
4470
- color: "#ffffff"
4472
+ borderRadius: "6px"
4471
4473
  },
4472
4474
  children: [
4473
4475
  "#",
@@ -4481,7 +4483,7 @@ const TokensProfessional = () => {
4481
4483
  {
4482
4484
  style: {
4483
4485
  borderRadius: "12px",
4484
- border: "1px solid rgba(255,255,255,0.1)",
4486
+ border: "1px solid rgba(128, 128, 128, 0.15)",
4485
4487
  overflow: "hidden"
4486
4488
  },
4487
4489
  children: [
@@ -4492,11 +4494,11 @@ const TokensProfessional = () => {
4492
4494
  justifyContent: "space-between",
4493
4495
  style: {
4494
4496
  padding: "14px 20px",
4495
- background: "rgba(255,255,255,0.06)",
4496
- borderBottom: "1px solid rgba(255,255,255,0.1)"
4497
+ background: "rgba(128, 128, 128, 0.06)",
4498
+ borderBottom: "1px solid rgba(128, 128, 128, 0.15)"
4497
4499
  },
4498
4500
  children: [
4499
- /* @__PURE__ */ jsx(Typography, { variant: "omega", fontWeight: "semiBold", style: { fontSize: "13px", color: "rgba(255,255,255,0.7)" }, children: formatMessage({ id: getTrad("tokens.details.status") }) }),
4501
+ /* @__PURE__ */ jsx(Typography, { variant: "omega", fontWeight: "semiBold", textColor: "neutral600", style: { fontSize: "13px" }, children: formatMessage({ id: getTrad("tokens.details.status") }) }),
4500
4502
  getStatusBadge(selectedTokenDetails)
4501
4503
  ]
4502
4504
  }
@@ -4508,12 +4510,11 @@ const TokensProfessional = () => {
4508
4510
  justifyContent: "space-between",
4509
4511
  style: {
4510
4512
  padding: "12px 20px",
4511
- background: "rgba(255,255,255,0.03)",
4512
- borderBottom: "1px solid rgba(255,255,255,0.06)"
4513
+ borderBottom: "1px solid rgba(128, 128, 128, 0.08)"
4513
4514
  },
4514
4515
  children: [
4515
- /* @__PURE__ */ jsx(Typography, { variant: "omega", style: { fontSize: "13px", color: "rgba(255,255,255,0.6)" }, children: formatMessage({ id: getTrad("tokens.details.created") }) }),
4516
- /* @__PURE__ */ jsx(Typography, { variant: "pi", style: { fontSize: "13px", fontWeight: "600", color: "#ffffff" }, children: formatDate(selectedTokenDetails.createdAt) })
4516
+ /* @__PURE__ */ jsx(Typography, { variant: "omega", textColor: "neutral500", style: { fontSize: "13px" }, children: formatMessage({ id: getTrad("tokens.details.created") }) }),
4517
+ /* @__PURE__ */ jsx(Typography, { variant: "pi", textColor: "neutral800", style: { fontSize: "13px", fontWeight: "600" }, children: formatDate(selectedTokenDetails.createdAt) })
4517
4518
  ]
4518
4519
  }
4519
4520
  ),
@@ -4524,20 +4525,16 @@ const TokensProfessional = () => {
4524
4525
  justifyContent: "space-between",
4525
4526
  style: {
4526
4527
  padding: "12px 20px",
4527
- background: "rgba(255,255,255,0.03)",
4528
- borderBottom: selectedTokenDetails.used_at || selectedTokenDetails.last_used_at ? "1px solid rgba(255,255,255,0.06)" : "none"
4528
+ borderBottom: selectedTokenDetails.used_at || selectedTokenDetails.last_used_at ? "1px solid rgba(128, 128, 128, 0.08)" : "none"
4529
4529
  },
4530
4530
  children: [
4531
- /* @__PURE__ */ jsx(Typography, { variant: "omega", style: { fontSize: "13px", color: "rgba(255,255,255,0.6)" }, children: formatMessage({ id: getTrad("tokens.details.expiresAt") }) }),
4531
+ /* @__PURE__ */ jsx(Typography, { variant: "omega", textColor: "neutral500", style: { fontSize: "13px" }, children: formatMessage({ id: getTrad("tokens.details.expiresAt") }) }),
4532
4532
  /* @__PURE__ */ jsx(
4533
4533
  Typography,
4534
4534
  {
4535
4535
  variant: "pi",
4536
- style: {
4537
- fontSize: "13px",
4538
- fontWeight: "600",
4539
- color: isDateExpired(selectedTokenDetails.expires_at) ? "#f87171" : "#ffffff"
4540
- },
4536
+ textColor: isDateExpired(selectedTokenDetails.expires_at) ? "danger600" : "neutral800",
4537
+ style: { fontSize: "13px", fontWeight: "600" },
4541
4538
  children: formatDate(selectedTokenDetails.expires_at) || formatMessage({ id: getTrad("tokens.details.unlimited") })
4542
4539
  }
4543
4540
  )
@@ -4551,19 +4548,19 @@ const TokensProfessional = () => {
4551
4548
  justifyContent: "space-between",
4552
4549
  style: {
4553
4550
  padding: "12px 20px",
4554
- background: "rgba(34, 197, 94, 0.08)",
4555
- borderBottom: selectedTokenDetails.last_used_at && selectedTokenDetails.last_used_at !== selectedTokenDetails.used_at ? "1px solid rgba(34, 197, 94, 0.15)" : "none"
4551
+ background: "rgba(34, 197, 94, 0.06)",
4552
+ borderBottom: selectedTokenDetails.last_used_at && selectedTokenDetails.last_used_at !== selectedTokenDetails.used_at ? "1px solid rgba(34, 197, 94, 0.12)" : "none"
4556
4553
  },
4557
4554
  children: [
4558
- /* @__PURE__ */ jsx(Typography, { variant: "omega", style: { fontSize: "13px", color: "rgba(255,255,255,0.6)" }, children: formatMessage({ id: getTrad("tokens.details.usedAt") }) }),
4555
+ /* @__PURE__ */ jsx(Typography, { variant: "omega", textColor: "neutral500", style: { fontSize: "13px" }, children: formatMessage({ id: getTrad("tokens.details.usedAt") }) }),
4559
4556
  /* @__PURE__ */ jsxs(Flex, { alignItems: "center", gap: 2, children: [
4560
4557
  /* @__PURE__ */ jsx(Box, { style: {
4561
4558
  width: "8px",
4562
4559
  height: "8px",
4563
4560
  borderRadius: "50%",
4564
- background: "#4ade80"
4561
+ background: "#22c55e"
4565
4562
  } }),
4566
- /* @__PURE__ */ jsx(Typography, { variant: "pi", style: { fontSize: "13px", fontWeight: "600", color: "#4ade80" }, children: formatDate(selectedTokenDetails.used_at) })
4563
+ /* @__PURE__ */ jsx(Typography, { variant: "pi", textColor: "success600", style: { fontSize: "13px", fontWeight: "600" }, children: formatDate(selectedTokenDetails.used_at) })
4567
4564
  ] })
4568
4565
  ]
4569
4566
  }
@@ -4573,13 +4570,10 @@ const TokensProfessional = () => {
4573
4570
  {
4574
4571
  alignItems: "center",
4575
4572
  justifyContent: "space-between",
4576
- style: {
4577
- padding: "12px 20px",
4578
- background: "rgba(255,255,255,0.03)"
4579
- },
4573
+ style: { padding: "12px 20px" },
4580
4574
  children: [
4581
- /* @__PURE__ */ jsx(Typography, { variant: "omega", style: { fontSize: "13px", color: "rgba(255,255,255,0.6)" }, children: formatMessage({ id: getTrad("tokens.details.lastUsedAt") }) }),
4582
- /* @__PURE__ */ jsx(Typography, { variant: "pi", style: { fontSize: "13px", fontWeight: "600", color: "#ffffff" }, children: formatDate(selectedTokenDetails.last_used_at) })
4575
+ /* @__PURE__ */ jsx(Typography, { variant: "omega", textColor: "neutral500", style: { fontSize: "13px" }, children: formatMessage({ id: getTrad("tokens.details.lastUsedAt") }) }),
4576
+ /* @__PURE__ */ jsx(Typography, { variant: "pi", textColor: "neutral800", style: { fontSize: "13px", fontWeight: "600" }, children: formatDate(selectedTokenDetails.last_used_at) })
4583
4577
  ]
4584
4578
  }
4585
4579
  )
@@ -4587,28 +4581,28 @@ const TokensProfessional = () => {
4587
4581
  }
4588
4582
  ),
4589
4583
  (selectedTokenDetails.ip_address || selectedTokenDetails.user_agent) && /* @__PURE__ */ jsxs(Box, { children: [
4590
- /* @__PURE__ */ jsx(Typography, { variant: "sigma", fontWeight: "semiBold", style: { marginBottom: "8px", textTransform: "uppercase", fontSize: "11px", letterSpacing: "0.5px", color: "rgba(255,255,255,0.5)" }, children: formatMessage({ id: getTrad("tokens.details.technicalInfo") }) }),
4584
+ /* @__PURE__ */ jsx(Typography, { variant: "sigma", fontWeight: "semiBold", textColor: "neutral500", style: { marginBottom: "8px", textTransform: "uppercase", fontSize: "11px", letterSpacing: "0.5px" }, children: formatMessage({ id: getTrad("tokens.details.technicalInfo") }) }),
4591
4585
  /* @__PURE__ */ jsx(
4592
4586
  Box,
4593
4587
  {
4594
4588
  padding: 4,
4589
+ background: "neutral100",
4595
4590
  style: {
4596
4591
  borderRadius: "8px",
4597
- border: "1px solid rgba(255,255,255,0.1)",
4598
- background: "rgba(255,255,255,0.04)"
4592
+ border: "1px solid rgba(128, 128, 128, 0.15)"
4599
4593
  },
4600
4594
  children: /* @__PURE__ */ jsxs(Flex, { direction: "column", gap: 2, children: [
4601
4595
  selectedTokenDetails.ip_address && /* @__PURE__ */ jsxs(Flex, { alignItems: "center", gap: 2, children: [
4602
- /* @__PURE__ */ jsx(Earth, { style: { width: "14px", height: "14px", color: "rgba(255,255,255,0.5)" } }),
4603
- /* @__PURE__ */ jsx(Typography, { variant: "pi", style: { fontFamily: "monospace", fontSize: "12px", color: "rgba(255,255,255,0.8)" }, children: selectedTokenDetails.ip_address })
4596
+ /* @__PURE__ */ jsx(Earth, { style: { width: "14px", height: "14px", color: "var(--colors-neutral500)" } }),
4597
+ /* @__PURE__ */ jsx(Typography, { variant: "pi", textColor: "neutral700", style: { fontFamily: "monospace", fontSize: "12px" }, children: selectedTokenDetails.ip_address })
4604
4598
  ] }),
4605
- selectedTokenDetails.user_agent && /* @__PURE__ */ jsx(Typography, { variant: "pi", style: { fontSize: "11px", wordBreak: "break-all", color: "rgba(255,255,255,0.5)" }, children: selectedTokenDetails.user_agent })
4599
+ selectedTokenDetails.user_agent && /* @__PURE__ */ jsx(Typography, { variant: "pi", textColor: "neutral500", style: { fontSize: "11px", wordBreak: "break-all" }, children: selectedTokenDetails.user_agent })
4606
4600
  ] })
4607
4601
  }
4608
4602
  )
4609
4603
  ] }),
4610
4604
  selectedTokenDetails.context && Object.keys(selectedTokenDetails.context).length > 0 && /* @__PURE__ */ jsxs(Box, { children: [
4611
- /* @__PURE__ */ jsx(Typography, { variant: "sigma", fontWeight: "semiBold", style: { marginBottom: "8px", textTransform: "uppercase", fontSize: "11px", letterSpacing: "0.5px", color: "rgba(255,255,255,0.5)" }, children: formatMessage({ id: getTrad("tokens.details.context") }) }),
4605
+ /* @__PURE__ */ jsx(Typography, { variant: "sigma", fontWeight: "semiBold", textColor: "neutral500", style: { marginBottom: "8px", textTransform: "uppercase", fontSize: "11px", letterSpacing: "0.5px" }, children: formatMessage({ id: getTrad("tokens.details.context") }) }),
4612
4606
  /* @__PURE__ */ jsx(
4613
4607
  Box,
4614
4608
  {
@@ -4631,7 +4625,7 @@ const TokensProfessional = () => {
4631
4625
  )
4632
4626
  ] }),
4633
4627
  /* @__PURE__ */ jsxs(Box, { style: { marginTop: "8px" }, children: [
4634
- /* @__PURE__ */ jsx(Typography, { variant: "sigma", fontWeight: "semiBold", style: { marginBottom: "12px", textTransform: "uppercase", fontSize: "11px", letterSpacing: "0.5px", color: "rgba(255,255,255,0.5)" }, children: formatMessage({ id: getTrad("tokens.details.actions") }) }),
4628
+ /* @__PURE__ */ jsx(Typography, { variant: "sigma", fontWeight: "semiBold", textColor: "neutral500", style: { marginBottom: "12px", textTransform: "uppercase", fontSize: "11px", letterSpacing: "0.5px" }, children: formatMessage({ id: getTrad("tokens.details.actions") }) }),
4635
4629
  /* @__PURE__ */ jsxs(Flex, { gap: 2, wrap: "wrap", children: [
4636
4630
  (selectedTokenDetails.is_used || selectedTokenDetails.expires_at && new Date(selectedTokenDetails.expires_at) < /* @__PURE__ */ new Date() || selectedTokenDetails.status === "blocked") && /* @__PURE__ */ jsx(
4637
4631
  Button,
@@ -4755,9 +4749,9 @@ const TokensProfessional = () => {
4755
4749
  paddingBottom: 5,
4756
4750
  paddingLeft: 7,
4757
4751
  paddingRight: 7,
4752
+ background: "neutral100",
4758
4753
  style: {
4759
- borderTop: "1px solid rgba(255,255,255,0.08)",
4760
- background: "rgba(255,255,255,0.03)",
4754
+ borderTop: "1px solid rgba(128, 128, 128, 0.12)",
4761
4755
  borderBottomLeftRadius: "8px",
4762
4756
  borderBottomRightRadius: "8px"
4763
4757
  },
@@ -1,4 +1,4 @@
1
1
  "use strict";
2
- const index = require("../_chunks/index-BbJpwVk7.js");
2
+ const index = require("../_chunks/index-CKTfFcY_.js");
3
3
  require("@strapi/icons");
4
4
  module.exports = index.index;
@@ -1,4 +1,4 @@
1
- import { i } from "../_chunks/index-Df4P6nwt.mjs";
1
+ import { i } from "../_chunks/index-BgpjdW58.mjs";
2
2
  import "@strapi/icons";
3
3
  export {
4
4
  i as default
package/package.json CHANGED
@@ -1,5 +1,5 @@
1
1
  {
2
- "version": "5.3.15",
2
+ "version": "5.3.17",
3
3
  "keywords": [],
4
4
  "type": "commonjs",
5
5
  "exports": {