@ai-matrx/vault 0.1.49 → 0.1.51
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/CHANGELOG.md +14 -2
- package/dist/{chunk-LXFJBJR6.js → chunk-YDYTU3NY.js} +31 -8
- package/dist/chunk-YDYTU3NY.js.map +1 -0
- package/dist/identity.cjs +30 -7
- package/dist/identity.cjs.map +1 -1
- package/dist/identity.d.cts +4 -0
- package/dist/identity.d.ts +4 -0
- package/dist/identity.js +1 -1
- package/dist/index.cjs +35 -10
- package/dist/index.cjs.map +1 -1
- package/dist/index.js +6 -4
- package/dist/index.js.map +1 -1
- package/package.json +2 -2
- package/dist/chunk-LXFJBJR6.js.map +0 -1
package/dist/index.js
CHANGED
|
@@ -55,7 +55,7 @@ import {
|
|
|
55
55
|
useCopy,
|
|
56
56
|
useNotify,
|
|
57
57
|
wasCancelled
|
|
58
|
-
} from "./chunk-
|
|
58
|
+
} from "./chunk-YDYTU3NY.js";
|
|
59
59
|
|
|
60
60
|
// src/VaultApp.tsx
|
|
61
61
|
import { useCallback as useCallback4, useEffect as useEffect22, useMemo as useMemo6, useRef as useRef18, useState as useState40, useSyncExternalStore as useSyncExternalStore5 } from "react";
|
|
@@ -1666,8 +1666,10 @@ import { CopyIcon as CopyIcon4 } from "@ai-matrx/design-system/icons";
|
|
|
1666
1666
|
// src/authenticator/port.ts
|
|
1667
1667
|
var OTP_SEED_KEY = "totp_seed";
|
|
1668
1668
|
function mfaMethodOf(item) {
|
|
1669
|
-
const
|
|
1670
|
-
|
|
1669
|
+
const declarations = item.custom.filter((c) => c.key === MFA_METHOD_KEY);
|
|
1670
|
+
if (declarations.length !== 1) return null;
|
|
1671
|
+
const value = declarations[0]?.value;
|
|
1672
|
+
return value === "sms" || value === "push_or_other" ? value : null;
|
|
1671
1673
|
}
|
|
1672
1674
|
|
|
1673
1675
|
// src/authenticator/TotpRows.tsx
|
|
@@ -5024,7 +5026,7 @@ function withMfaMethod(custom, v) {
|
|
|
5024
5026
|
return v === "sms" || v === "push_or_other" ? [...rest, { key: MFA_METHOD_KEY, label: "Two-factor method", value: v }] : rest;
|
|
5025
5027
|
}
|
|
5026
5028
|
function DraftTwoFactorRow({ custom, onCustom }) {
|
|
5027
|
-
const value =
|
|
5029
|
+
const value = mfaMethodOf({ custom }) ?? "none";
|
|
5028
5030
|
return /* @__PURE__ */ jsx19(VaultRow, { label: "Two-factor", children: /* @__PURE__ */ jsx19(
|
|
5029
5031
|
Select7,
|
|
5030
5032
|
{
|