@ory/elements-react 1.0.0-next.11 → 1.0.0-next.12
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 +32 -0
- package/api-report/elements-react-theme.api.md +1 -0
- package/api-report/elements-react.api.json +710 -53
- package/api-report/elements-react.api.md +86 -3
- package/api-report/temp/elements-react-theme.api.md +1 -0
- package/api-report/temp/elements-react.api.md +86 -3
- package/dist/index.d.mts +96 -4
- package/dist/index.d.ts +96 -4
- package/dist/index.js +697 -124
- package/dist/index.js.map +1 -1
- package/dist/index.mjs +695 -125
- package/dist/index.mjs.map +1 -1
- package/dist/theme/default/index.css +292 -29
- package/dist/theme/default/index.css.map +1 -1
- package/dist/theme/default/index.js +993 -249
- package/dist/theme/default/index.js.map +1 -1
- package/dist/theme/default/index.mjs +968 -214
- package/dist/theme/default/index.mjs.map +1 -1
- package/jest.config.ts +4 -3
- package/package.json +9 -7
- package/tailwind.config.ts +6 -1
- package/tsconfig.json +5 -5
package/dist/index.js
CHANGED
|
@@ -1,10 +1,10 @@
|
|
|
1
1
|
'use strict';
|
|
2
2
|
|
|
3
|
+
var clientFetch = require('@ory/client-fetch');
|
|
3
4
|
var react = require('react');
|
|
4
5
|
var jsxRuntime = require('react/jsx-runtime');
|
|
5
6
|
var reactIntl = require('react-intl');
|
|
6
7
|
var reactHookForm = require('react-hook-form');
|
|
7
|
-
var clientFetch = require('@ory/client-fetch');
|
|
8
8
|
var zustand = require('zustand');
|
|
9
9
|
var middleware = require('zustand/middleware');
|
|
10
10
|
|
|
@@ -5516,7 +5516,8 @@ var require_lodash = __commonJS({
|
|
|
5516
5516
|
var ComponentContext = react.createContext({
|
|
5517
5517
|
components: null,
|
|
5518
5518
|
// fine because we throw an error if it's not provided
|
|
5519
|
-
nodeSorter: () => 0
|
|
5519
|
+
nodeSorter: () => 0,
|
|
5520
|
+
groupSorter: () => 0
|
|
5520
5521
|
});
|
|
5521
5522
|
function useComponents() {
|
|
5522
5523
|
const ctx = react.useContext(ComponentContext);
|
|
@@ -5528,11 +5529,18 @@ function useComponents() {
|
|
|
5528
5529
|
function useNodeSorter() {
|
|
5529
5530
|
const ctx = react.useContext(ComponentContext);
|
|
5530
5531
|
if (!ctx) {
|
|
5531
|
-
throw new Error("
|
|
5532
|
+
throw new Error("useNodeSorter must be used within a ComponentProvider");
|
|
5532
5533
|
}
|
|
5533
5534
|
return ctx.nodeSorter;
|
|
5534
5535
|
}
|
|
5535
|
-
|
|
5536
|
+
function useGroupSorter() {
|
|
5537
|
+
const ctx = react.useContext(ComponentContext);
|
|
5538
|
+
if (!ctx) {
|
|
5539
|
+
throw new Error("useGroupSorter must be used within a ComponentProvider");
|
|
5540
|
+
}
|
|
5541
|
+
return ctx.groupSorter;
|
|
5542
|
+
}
|
|
5543
|
+
var defaultNodeOrder = [
|
|
5536
5544
|
"oidc",
|
|
5537
5545
|
"identifier_first",
|
|
5538
5546
|
"default",
|
|
@@ -5544,21 +5552,40 @@ var defaultGroupOrder = [
|
|
|
5544
5552
|
];
|
|
5545
5553
|
function defaultNodeSorter(a, b) {
|
|
5546
5554
|
var _a, _b;
|
|
5547
|
-
const aGroupWeight = (_a =
|
|
5548
|
-
const bGroupWeight = (_b =
|
|
5555
|
+
const aGroupWeight = (_a = defaultNodeOrder.indexOf(a.group)) != null ? _a : 999;
|
|
5556
|
+
const bGroupWeight = (_b = defaultNodeOrder.indexOf(b.group)) != null ? _b : 999;
|
|
5557
|
+
return aGroupWeight - bGroupWeight;
|
|
5558
|
+
}
|
|
5559
|
+
var defaultGroupOrder = [
|
|
5560
|
+
clientFetch.UiNodeGroupEnum.Default,
|
|
5561
|
+
clientFetch.UiNodeGroupEnum.Profile,
|
|
5562
|
+
clientFetch.UiNodeGroupEnum.Password,
|
|
5563
|
+
clientFetch.UiNodeGroupEnum.Oidc,
|
|
5564
|
+
clientFetch.UiNodeGroupEnum.Code,
|
|
5565
|
+
clientFetch.UiNodeGroupEnum.LookupSecret,
|
|
5566
|
+
clientFetch.UiNodeGroupEnum.Passkey,
|
|
5567
|
+
clientFetch.UiNodeGroupEnum.Webauthn,
|
|
5568
|
+
clientFetch.UiNodeGroupEnum.Totp
|
|
5569
|
+
];
|
|
5570
|
+
function defaultGroupSorter(a, b) {
|
|
5571
|
+
var _a, _b;
|
|
5572
|
+
const aGroupWeight = (_a = defaultGroupOrder.indexOf(a)) != null ? _a : 999;
|
|
5573
|
+
const bGroupWeight = (_b = defaultGroupOrder.indexOf(b)) != null ? _b : 999;
|
|
5549
5574
|
return aGroupWeight - bGroupWeight;
|
|
5550
5575
|
}
|
|
5551
5576
|
function OryComponentProvider({
|
|
5552
5577
|
children,
|
|
5553
5578
|
components,
|
|
5554
|
-
nodeSorter = defaultNodeSorter
|
|
5579
|
+
nodeSorter = defaultNodeSorter,
|
|
5580
|
+
groupSorter = defaultGroupSorter
|
|
5555
5581
|
}) {
|
|
5556
5582
|
return /* @__PURE__ */ jsxRuntime.jsx(
|
|
5557
5583
|
ComponentContext.Provider,
|
|
5558
5584
|
{
|
|
5559
5585
|
value: {
|
|
5560
5586
|
components,
|
|
5561
|
-
nodeSorter
|
|
5587
|
+
nodeSorter,
|
|
5588
|
+
groupSorter
|
|
5562
5589
|
},
|
|
5563
5590
|
children
|
|
5564
5591
|
}
|
|
@@ -5653,7 +5680,7 @@ var en_default = {
|
|
|
5653
5680
|
"identities.messages.1050005": "Authenticator app QR code",
|
|
5654
5681
|
"identities.messages.1050006": "{secret}",
|
|
5655
5682
|
"identities.messages.1050007": "Reveal backup recovery codes",
|
|
5656
|
-
"identities.messages.1050008": "
|
|
5683
|
+
"identities.messages.1050008": "Enable",
|
|
5657
5684
|
"identities.messages.1050009": "{secret}",
|
|
5658
5685
|
"identities.messages.1050010": "These are your back up recovery codes. Please keep them in a safe place!",
|
|
5659
5686
|
"identities.messages.1050011": "Confirm backup recovery codes",
|
|
@@ -5662,7 +5689,7 @@ var en_default = {
|
|
|
5662
5689
|
"identities.messages.1050014": "Secret was used at {used_at, date, long}",
|
|
5663
5690
|
"identities.messages.1050015": "{secrets_list}",
|
|
5664
5691
|
"identities.messages.1050016": "Disable this method",
|
|
5665
|
-
"identities.messages.1050017": "
|
|
5692
|
+
"identities.messages.1050017": "Authenticator Secret",
|
|
5666
5693
|
"identities.messages.1050018": 'Remove security key "{display_name}"',
|
|
5667
5694
|
"identities.messages.1050019": "Add passkey",
|
|
5668
5695
|
"identities.messages.1050020": 'Remove passkey "{display_name}"',
|
|
@@ -5786,7 +5813,6 @@ var en_default = {
|
|
|
5786
5813
|
"settings.navigation-webauthn": "Hardware Tokens",
|
|
5787
5814
|
"settings.navigation-passkey": "Passkeys",
|
|
5788
5815
|
"settings.subtitle-instructions": "Here you can manage settings related to your account. Keep in mind that certain actions require you to re-authenticate.",
|
|
5789
|
-
"settings.title": "Update your account",
|
|
5790
5816
|
"settings.subtitle": "Update your account settings",
|
|
5791
5817
|
"settings.title-lookup-secret": "Manage 2FA Backup Recovery Codes",
|
|
5792
5818
|
"settings.title-navigation": "Account Settings",
|
|
@@ -5796,6 +5822,14 @@ var en_default = {
|
|
|
5796
5822
|
"settings.title-totp": "Manage 2FA TOTP Authenticator App",
|
|
5797
5823
|
"settings.title-webauthn": "Manage Hardware Tokens",
|
|
5798
5824
|
"settings.title-passkey": "Manage Passkeys",
|
|
5825
|
+
"settings.title": "Account Settings",
|
|
5826
|
+
"settings.navigation.title": "Account Settings",
|
|
5827
|
+
"settings.password.title": "Change Password",
|
|
5828
|
+
"settings.password.description": "Modify your password",
|
|
5829
|
+
"settings.profile.title": "Profile Settings",
|
|
5830
|
+
"settings.profile.description": "Update your profile information",
|
|
5831
|
+
"settings.webauthn.title": "Manage Hardware Tokens",
|
|
5832
|
+
"settings.webauthn.description": "Manage your hardware token settings",
|
|
5799
5833
|
"verification.registration-button": "Sign up",
|
|
5800
5834
|
"verification.registration-label": "Don't have an account?",
|
|
5801
5835
|
"verification.title": "Verify your account",
|
|
@@ -5821,7 +5855,20 @@ var en_default = {
|
|
|
5821
5855
|
"card.header.description.login": "Sign in with {identifierLabel}",
|
|
5822
5856
|
"card.header.description.registration": "Sign up with {identifierLabel}",
|
|
5823
5857
|
"misc.or": "or",
|
|
5824
|
-
"forms.label.forgot-password": "Forgot Password?"
|
|
5858
|
+
"forms.label.forgot-password": "Forgot Password?",
|
|
5859
|
+
"settings.totp.title": "Authenticator App",
|
|
5860
|
+
"settings.totp.description": "Add a TOTP Authenticator App to your account to improve your account security. Popular Authenticator Apps are LastPass and Google Authenticator",
|
|
5861
|
+
"settings.totp.info.not-linked": "To enable scan the QR code with your authenticator and enter the code.",
|
|
5862
|
+
"settings.totp.info.linked": "You currently have an authenticator app connected.",
|
|
5863
|
+
"settings.lookup_secret.title": "Backup Recovery Codes (second factor)",
|
|
5864
|
+
"settings.lookup_secret.description": "Recovery codes are a secure backup for 2FA, allowing you to regain access to your account if you lose your 2FA device.",
|
|
5865
|
+
"settings.oidc.title": "Connected accounts",
|
|
5866
|
+
"settings.oidc.description": "Connect a social login provider with your account.",
|
|
5867
|
+
"settings.oidc.info": "Connected accounts from these providers can be used to login to your account",
|
|
5868
|
+
"settings.webauthn.info": "Hardware Tokens are used for second-factor authentication or as first-factor with Passkeys",
|
|
5869
|
+
"settings.passkey.title": "Manage Passkeys",
|
|
5870
|
+
"settings.passkey.description": "Manage your passkey settings",
|
|
5871
|
+
"settings.passkey.info": "Manage your passkey settings"
|
|
5825
5872
|
};
|
|
5826
5873
|
|
|
5827
5874
|
// src/locales/de.json
|
|
@@ -5977,25 +6024,6 @@ var de_default = {
|
|
|
5977
6024
|
"registration.login-label": "Sie haben bereits ein Konto?",
|
|
5978
6025
|
"registration.subtitle-oauth2": "Zur Authentifizierung bei {clientName}",
|
|
5979
6026
|
"registration.title": "Konto registrieren",
|
|
5980
|
-
"settings.navigation-back-button": "Zur\xFCck",
|
|
5981
|
-
"settings.navigation-backup-codes": "2FA-Backup-Codes",
|
|
5982
|
-
"settings.navigation-logout": "Abmelden",
|
|
5983
|
-
"settings.navigation-oidc": "Soziale Medien",
|
|
5984
|
-
"settings.navigation-password": "Passwort",
|
|
5985
|
-
"settings.navigation-profile": "Profil",
|
|
5986
|
-
"settings.navigation-totp": "Zwei-Faktor App",
|
|
5987
|
-
"settings.navigation-webauthn": "Sicherheitsschl\xFCssel",
|
|
5988
|
-
"settings.navigation-passkey": "Passkeys",
|
|
5989
|
-
"settings.subtitle-instructions": "Hier k\xF6nnen Sie Einstellungen zu Ihrem Konto vornehmen. F\xFCr manche Einstellungen m\xFCssen Sie Ihre Identit\xE4t erneut best\xE4tigen.",
|
|
5990
|
-
"settings.title": "Kontoeinstellungen",
|
|
5991
|
-
"settings.title-lookup-secret": "Manage 2FA Backup Recovery Codes",
|
|
5992
|
-
"settings.title-navigation": "Konto Einstellungen",
|
|
5993
|
-
"settings.title-oidc": "Anmeldung \xFCber soziale Medien",
|
|
5994
|
-
"settings.title-password": "Passwort \xE4ndern",
|
|
5995
|
-
"settings.title-profile": "Profil Einstellungen",
|
|
5996
|
-
"settings.title-totp": "Zwei-Faktor TOTP App",
|
|
5997
|
-
"settings.title-webauthn": "Sicherheitsschl\xFCssel verwalten",
|
|
5998
|
-
"settings.title-passkey": "Passkeys verwalten",
|
|
5999
6027
|
"verification.registration-button": "Registrieren",
|
|
6000
6028
|
"verification.registration-label": "Sie haben noch kein Konto?",
|
|
6001
6029
|
"verification.title": "Verifizieren Sie ihr Konto",
|
|
@@ -6024,7 +6052,7 @@ var de_default = {
|
|
|
6024
6052
|
"identities.messages.1040007": "",
|
|
6025
6053
|
"identities.messages.1040008": "",
|
|
6026
6054
|
"identities.messages.1040009": "",
|
|
6027
|
-
"identities.messages.1050019": "",
|
|
6055
|
+
"identities.messages.1050019": "Passkey hinzuf\xFCgen",
|
|
6028
6056
|
"identities.messages.1050020": "",
|
|
6029
6057
|
"identities.messages.4000037": "",
|
|
6030
6058
|
"identities.messages.4010009": "",
|
|
@@ -6038,7 +6066,6 @@ var de_default = {
|
|
|
6038
6066
|
"card.header.parts.password.registration": "Ihrer {identifierLabel} und einem Passwort",
|
|
6039
6067
|
"card.header.parts.webauthn": "ein Sicherheitsschl\xFCssel",
|
|
6040
6068
|
"recovery.subtitle": "Geben Sie die mit Ihrem Konto verkn\xFCpfte E-Mail-Adresse ein, um einen einmaligen Zugangscode zu erhalten",
|
|
6041
|
-
"settings.subtitle": "Aktualisieren Sie Ihre Kontoeinstellungen",
|
|
6042
6069
|
"verification.subtitle": "Geben Sie die mit Ihrem Konto verkn\xFCpfte E-Mail-Adresse ein, um es zu best\xE4tigen",
|
|
6043
6070
|
"card.header.description.login": "Melden Sie sich mit {identifierLabel} an",
|
|
6044
6071
|
"card.header.description.registration": "Registrieren Sie sich mit {identifierLabel}",
|
|
@@ -6046,7 +6073,47 @@ var de_default = {
|
|
|
6046
6073
|
"login.subtitle-refresh": "Best\xE4tigen Sie ihre Identit\xE4t mit {parts}",
|
|
6047
6074
|
"misc.or": "oder",
|
|
6048
6075
|
"registration.subtitle": "Registrieren Sie sich mit {parts}",
|
|
6049
|
-
"forms.label.forgot-password": "Passwort vergessen?"
|
|
6076
|
+
"forms.label.forgot-password": "Passwort vergessen?",
|
|
6077
|
+
"settings.title": "Kontoeinstellungen",
|
|
6078
|
+
"settings.navigation.title": "Kontoeinstellungen",
|
|
6079
|
+
"settings.subtitle": "Aktualisieren Sie Ihre Kontoeinstellungen",
|
|
6080
|
+
"settings.navigation-back-button": "Zur\xFCck",
|
|
6081
|
+
"settings.navigation-backup-codes": "2FA-Backup-Codes",
|
|
6082
|
+
"settings.navigation-logout": "Abmelden",
|
|
6083
|
+
"settings.navigation-oidc": "Soziale Medien",
|
|
6084
|
+
"settings.navigation-password": "Passwort",
|
|
6085
|
+
"settings.navigation-profile": "Profil",
|
|
6086
|
+
"settings.navigation-totp": "Zwei-Faktor App",
|
|
6087
|
+
"settings.navigation-webauthn": "Sicherheitsschl\xFCssel",
|
|
6088
|
+
"settings.navigation-passkey": "Passkeys",
|
|
6089
|
+
"settings.subtitle-instructions": "Hier k\xF6nnen Sie Einstellungen zu Ihrem Konto vornehmen. F\xFCr manche Einstellungen m\xFCssen Sie Ihre Identit\xE4t erneut best\xE4tigen.",
|
|
6090
|
+
"settings.totp.info.linked": "Sie haben derzeit eine Authenticator-App verbunden.",
|
|
6091
|
+
"settings.totp.info.not-linked": "Um dies zu erm\xF6glichen, scannen Sie den QR-Code mit Ihrem Authenticator und geben Sie den Code ein.",
|
|
6092
|
+
"settings.totp.title": "Authenticator App",
|
|
6093
|
+
"settings.totp.description": "F\xFCgen Sie eine TOTP Authenticator App zu Ihrem Konto hinzu, um die Sicherheit Ihres Kontos zu verbessern. Beliebte Authenticator Apps sind LastPass und Google Authenticator.",
|
|
6094
|
+
"settings.lookup_secret.description": "Verwalten Sie Ihre 2FA-Backup-Wiederherstellungscodes",
|
|
6095
|
+
"settings.lookup_secret.title": "Wiederherstellungscodes",
|
|
6096
|
+
"settings.oidc.description": "Verwalten Sie Ihre Einstellungen f\xFCr die soziale Anmeldung",
|
|
6097
|
+
"settings.oidc.title": "Soziales Anmelden",
|
|
6098
|
+
"settings.passkey.description": "Verwalten Sie Ihre Passworteinstellungen",
|
|
6099
|
+
"settings.passkey.title": "Passkeys verwalten",
|
|
6100
|
+
"settings.password.description": "\xC4ndern Sie Ihr Passwort",
|
|
6101
|
+
"settings.password.title": "Passwort \xE4ndern",
|
|
6102
|
+
"settings.profile.description": "Aktualisieren Sie Ihre Profilinformationen",
|
|
6103
|
+
"settings.profile.title": "Profileinstellungen",
|
|
6104
|
+
"settings.webauthn.description": "Verwalten Sie Ihre Hardware-Token-Einstellungen",
|
|
6105
|
+
"settings.webauthn.title": "Hardware-Token verwalten",
|
|
6106
|
+
"settings.oidc.info": "Verbundene Konten dieser Anbieter k\xF6nnen f\xFCr die Anmeldung bei Ihrem Konto verwendet werden",
|
|
6107
|
+
"settings.passkey.info": "Verwalten Sie Ihre Passkey-Einstellungen",
|
|
6108
|
+
"settings.title-lookup-secret": "Verwalten Sie 2FA-Backup-Wiederherstellungscodes",
|
|
6109
|
+
"settings.title-navigation": "Kontoeinstellungen",
|
|
6110
|
+
"settings.title-oidc": "Social Sign In",
|
|
6111
|
+
"settings.title-passkey": "Passkeys verwalten",
|
|
6112
|
+
"settings.title-password": "Kennwort \xE4ndern",
|
|
6113
|
+
"settings.title-profile": "Profileinstellungen",
|
|
6114
|
+
"settings.title-totp": "Verwalten Sie die 2FA TOTP Authenticator-App",
|
|
6115
|
+
"settings.title-webauthn": "Hardware-Token verwalten",
|
|
6116
|
+
"settings.webauthn.info": "Hardware-Tokens werden f\xFCr die Zweitfaktor-Authentifizierung oder als Erstfaktor-Authentifizierung mit Passkeys verwendet"
|
|
6050
6117
|
};
|
|
6051
6118
|
|
|
6052
6119
|
// src/locales/es.json
|
|
@@ -6213,14 +6280,6 @@ var es_default = {
|
|
|
6213
6280
|
"settings.navigation-passkey": "Passkeys",
|
|
6214
6281
|
"settings.subtitle-instructions": "Aqu\xED puede gestionar las configuraciones relacionadas con su cuenta. Tenga en cuenta que ciertas acciones requieren que vuelva a autenticarse.",
|
|
6215
6282
|
"settings.title": "Configuraciones de la Cuenta",
|
|
6216
|
-
"settings.title-lookup-secret": "Gestionar C\xF3digos de Recuperaci\xF3n de Respaldo de 2FA",
|
|
6217
|
-
"settings.title-navigation": "Configuraciones de la Cuenta",
|
|
6218
|
-
"settings.title-oidc": "Inicio de Sesi\xF3n Social",
|
|
6219
|
-
"settings.title-password": "Cambiar Contrase\xF1a",
|
|
6220
|
-
"settings.title-profile": "Configuraciones del Perfil",
|
|
6221
|
-
"settings.title-totp": "Gestionar Aplicaci\xF3n Autenticadora de 2FA",
|
|
6222
|
-
"settings.title-webauthn": "Gestionar Tokens de Hardware",
|
|
6223
|
-
"settings.title-passkey": "Gestionar Passkeys",
|
|
6224
6283
|
"verification.registration-button": "Registrarse",
|
|
6225
6284
|
"verification.registration-label": "\xBFNo tiene una cuenta?",
|
|
6226
6285
|
"verification.title": "Verificar su cuenta",
|
|
@@ -6271,7 +6330,35 @@ var es_default = {
|
|
|
6271
6330
|
"recovery.subtitle": "",
|
|
6272
6331
|
"registration.subtitle": "",
|
|
6273
6332
|
"settings.subtitle": "",
|
|
6274
|
-
"verification.subtitle": ""
|
|
6333
|
+
"verification.subtitle": "",
|
|
6334
|
+
"settings.totp.info.linked": "Actualmente tienes una aplicaci\xF3n de autenticaci\xF3n conectada.",
|
|
6335
|
+
"settings.totp.info.not-linked": "Para habilitar, escanea el c\xF3digo QR con tu autenticador e ingresa el c\xF3digo.",
|
|
6336
|
+
"settings.totp.title": "Aplicaci\xF3n Autenticadora",
|
|
6337
|
+
"settings.totp.description": "Agrega una aplicaci\xF3n de autenticaci\xF3n TOTP a tu cuenta para mejorar la seguridad de tu cuenta. Las aplicaciones de autenticaci\xF3n populares son LastPass y Google Authenticator.",
|
|
6338
|
+
"settings.lookup_secret.description": "Gestiona tus c\xF3digos de recuperaci\xF3n de respaldo 2FA",
|
|
6339
|
+
"settings.lookup_secret.title": "C\xF3digos de Recuperaci\xF3n",
|
|
6340
|
+
"settings.navigation.title": "Configuraci\xF3n de la Cuenta",
|
|
6341
|
+
"settings.oidc.description": "Administra la configuraci\xF3n de tu inicio de sesi\xF3n social",
|
|
6342
|
+
"settings.oidc.title": "Inicio de Sesi\xF3n Social",
|
|
6343
|
+
"settings.passkey.description": "Administra la configuraci\xF3n de tu clave de acceso",
|
|
6344
|
+
"settings.passkey.title": "Gestionar Claves de Acceso",
|
|
6345
|
+
"settings.password.description": "Modifica tu contrase\xF1a",
|
|
6346
|
+
"settings.password.title": "Cambiar Contrase\xF1a",
|
|
6347
|
+
"settings.profile.description": "Actualiza la informaci\xF3n de tu perfil",
|
|
6348
|
+
"settings.profile.title": "Configuraci\xF3n de Perfil",
|
|
6349
|
+
"settings.webauthn.description": "Administra la configuraci\xF3n de tu token de hardware",
|
|
6350
|
+
"settings.webauthn.title": "Gestionar Tokens de Hardware",
|
|
6351
|
+
"settings.oidc.info": "",
|
|
6352
|
+
"settings.passkey.info": "",
|
|
6353
|
+
"settings.title-lookup-secret": "",
|
|
6354
|
+
"settings.title-navigation": "",
|
|
6355
|
+
"settings.title-oidc": "",
|
|
6356
|
+
"settings.title-passkey": "",
|
|
6357
|
+
"settings.title-password": "",
|
|
6358
|
+
"settings.title-profile": "",
|
|
6359
|
+
"settings.title-totp": "",
|
|
6360
|
+
"settings.title-webauthn": "",
|
|
6361
|
+
"settings.webauthn.info": ""
|
|
6275
6362
|
};
|
|
6276
6363
|
|
|
6277
6364
|
// src/locales/fr.json
|
|
@@ -6438,14 +6525,6 @@ var fr_default = {
|
|
|
6438
6525
|
"settings.navigation-passkey": "Passkeys",
|
|
6439
6526
|
"settings.subtitle-instructions": "Ici, vous pouvez g\xE9rer les param\xE8tres li\xE9s \xE0 votre compte. Gardez \xE0 l'esprit que certaines actions n\xE9cessitent une nouvelle authentification.",
|
|
6440
6527
|
"settings.title": "Param\xE8tres du compte",
|
|
6441
|
-
"settings.title-lookup-secret": "G\xE9rer les codes de r\xE9cup\xE9ration 2FA",
|
|
6442
|
-
"settings.title-navigation": "Param\xE8tres du compte",
|
|
6443
|
-
"settings.title-oidc": "Connexion sociale",
|
|
6444
|
-
"settings.title-password": "Changer le mot de passe",
|
|
6445
|
-
"settings.title-profile": "Param\xE8tres de profil",
|
|
6446
|
-
"settings.title-totp": "G\xE9rer l'application d'authentification TOTP 2FA",
|
|
6447
|
-
"settings.title-webauthn": "G\xE9rer les tokens mat\xE9riels",
|
|
6448
|
-
"settings.title-passkey": "G\xE9rer les Passkeys",
|
|
6449
6528
|
"verification.registration-button": "S'inscrire",
|
|
6450
6529
|
"verification.registration-label": "Vous n'avez pas de compte ?",
|
|
6451
6530
|
"verification.title": "V\xE9rifiez votre compte",
|
|
@@ -6496,7 +6575,35 @@ var fr_default = {
|
|
|
6496
6575
|
"recovery.subtitle": "",
|
|
6497
6576
|
"registration.subtitle": "",
|
|
6498
6577
|
"settings.subtitle": "",
|
|
6499
|
-
"verification.subtitle": ""
|
|
6578
|
+
"verification.subtitle": "",
|
|
6579
|
+
"settings.totp.info.linked": "Vous avez actuellement une application d'authentification connect\xE9e.",
|
|
6580
|
+
"settings.totp.info.not-linked": "Pour activer, scannez le QR code avec votre authentificateur et entrez le code.",
|
|
6581
|
+
"settings.totp.title": "Application d'authentification",
|
|
6582
|
+
"settings.totp.description": "Ajoutez une application d'authentification TOTP \xE0 votre compte pour am\xE9liorer la s\xE9curit\xE9 de votre compte. Les applications d'authentification populaires sont LastPass et Google Authenticator.",
|
|
6583
|
+
"settings.lookup_secret.description": "",
|
|
6584
|
+
"settings.lookup_secret.title": "",
|
|
6585
|
+
"settings.navigation.title": "",
|
|
6586
|
+
"settings.oidc.description": "",
|
|
6587
|
+
"settings.oidc.info": "",
|
|
6588
|
+
"settings.oidc.title": "",
|
|
6589
|
+
"settings.passkey.description": "",
|
|
6590
|
+
"settings.passkey.info": "",
|
|
6591
|
+
"settings.passkey.title": "",
|
|
6592
|
+
"settings.password.description": "",
|
|
6593
|
+
"settings.password.title": "",
|
|
6594
|
+
"settings.profile.description": "",
|
|
6595
|
+
"settings.profile.title": "",
|
|
6596
|
+
"settings.title-lookup-secret": "",
|
|
6597
|
+
"settings.title-navigation": "",
|
|
6598
|
+
"settings.title-oidc": "",
|
|
6599
|
+
"settings.title-passkey": "",
|
|
6600
|
+
"settings.title-password": "",
|
|
6601
|
+
"settings.title-profile": "",
|
|
6602
|
+
"settings.title-totp": "",
|
|
6603
|
+
"settings.title-webauthn": "",
|
|
6604
|
+
"settings.webauthn.description": "",
|
|
6605
|
+
"settings.webauthn.info": "",
|
|
6606
|
+
"settings.webauthn.title": ""
|
|
6500
6607
|
};
|
|
6501
6608
|
|
|
6502
6609
|
// src/locales/nl.json
|
|
@@ -6663,14 +6770,6 @@ var nl_default = {
|
|
|
6663
6770
|
"settings.navigation-passkey": "Passkeys",
|
|
6664
6771
|
"settings.subtitle-instructions": "Hier kun je instellingen beheren die verband houden met je account. Houd er rekening mee dat bepaalde acties vereisen dat je opnieuw wordt geauthenticeerd.",
|
|
6665
6772
|
"settings.title": "Accountinstellingen",
|
|
6666
|
-
"settings.title-lookup-secret": "Beheer 2FA Backup Herstelcodes",
|
|
6667
|
-
"settings.title-navigation": "Accountinstellingen",
|
|
6668
|
-
"settings.title-oidc": "Sociaal Inloggen",
|
|
6669
|
-
"settings.title-password": "Wachtwoord wijzigen",
|
|
6670
|
-
"settings.title-profile": "Profielinstellingen",
|
|
6671
|
-
"settings.title-totp": "Beheer 2FA TOTP Authenticator App",
|
|
6672
|
-
"settings.title-webauthn": "Beheer Hardware Tokens",
|
|
6673
|
-
"settings.title-passkey": "Beheer Passkeys",
|
|
6674
6773
|
"verification.registration-button": "Registreren",
|
|
6675
6774
|
"verification.registration-label": "Heb je nog geen account?",
|
|
6676
6775
|
"verification.title": "Verifieer je account",
|
|
@@ -6721,7 +6820,35 @@ var nl_default = {
|
|
|
6721
6820
|
"recovery.subtitle": "",
|
|
6722
6821
|
"registration.subtitle": "",
|
|
6723
6822
|
"settings.subtitle": "",
|
|
6724
|
-
"verification.subtitle": ""
|
|
6823
|
+
"verification.subtitle": "",
|
|
6824
|
+
"settings.totp.info.linked": "U heeft momenteel een authenticator-app verbonden.",
|
|
6825
|
+
"settings.totp.info.not-linked": "Om te activeren, scan de QR-code met je authenticator en voer de code in.",
|
|
6826
|
+
"settings.totp.title": "",
|
|
6827
|
+
"settings.totp.description": "Voeg een TOTP Authenticator App toe aan uw account om de beveiliging van uw account te verbeteren. Populaire Authenticator Apps zijn LastPass en Google Authenticator.",
|
|
6828
|
+
"settings.lookup_secret.description": "",
|
|
6829
|
+
"settings.lookup_secret.title": "",
|
|
6830
|
+
"settings.navigation.title": "",
|
|
6831
|
+
"settings.oidc.description": "",
|
|
6832
|
+
"settings.oidc.info": "",
|
|
6833
|
+
"settings.oidc.title": "",
|
|
6834
|
+
"settings.passkey.description": "",
|
|
6835
|
+
"settings.passkey.info": "",
|
|
6836
|
+
"settings.passkey.title": "",
|
|
6837
|
+
"settings.password.description": "",
|
|
6838
|
+
"settings.password.title": "",
|
|
6839
|
+
"settings.profile.description": "",
|
|
6840
|
+
"settings.profile.title": "",
|
|
6841
|
+
"settings.title-lookup-secret": "",
|
|
6842
|
+
"settings.title-navigation": "",
|
|
6843
|
+
"settings.title-oidc": "",
|
|
6844
|
+
"settings.title-passkey": "",
|
|
6845
|
+
"settings.title-password": "",
|
|
6846
|
+
"settings.title-profile": "",
|
|
6847
|
+
"settings.title-totp": "",
|
|
6848
|
+
"settings.title-webauthn": "",
|
|
6849
|
+
"settings.webauthn.description": "",
|
|
6850
|
+
"settings.webauthn.info": "",
|
|
6851
|
+
"settings.webauthn.title": ""
|
|
6725
6852
|
};
|
|
6726
6853
|
|
|
6727
6854
|
// src/locales/pl.json
|
|
@@ -6888,14 +7015,6 @@ var pl_default = {
|
|
|
6888
7015
|
"settings.navigation-passkey": "Passkeys",
|
|
6889
7016
|
"settings.subtitle-instructions": "Tutaj mo\u017Cesz zarz\u0105dza\u0107 ustawieniami zwi\u0105zanymi z Twoim kontem. Miej na uwadze \u017Ce niekt\xF3re akcje mog\u0105 wymaga\u0107 ponownej uwierzytelnienia.",
|
|
6890
7017
|
"settings.title": "Ustawienia Konta",
|
|
6891
|
-
"settings.title-lookup-secret": "Zarz\u0105dzaj kodami odzyskiwania 2FA",
|
|
6892
|
-
"settings.title-navigation": "Ustawienia Konta",
|
|
6893
|
-
"settings.title-oidc": "Zewn\u0119trzne logowanie",
|
|
6894
|
-
"settings.title-password": "Zmie\u0144 Has\u0142o",
|
|
6895
|
-
"settings.title-profile": "Ustawienia Profilu",
|
|
6896
|
-
"settings.title-totp": "Zarz\u0105dzaj aplikacj\u0105 autentykator 2FA TOTP",
|
|
6897
|
-
"settings.title-webauthn": "Zarz\u0105dzaj tokenami sprz\u0119towymi",
|
|
6898
|
-
"settings.title-passkey": "Zarz\u0105dzaj Passkeys",
|
|
6899
7018
|
"verification.registration-button": "Zarejestruj si\u0119",
|
|
6900
7019
|
"verification.registration-label": "Nie posiadasz konta?",
|
|
6901
7020
|
"verification.title": "Zweryfikuj konto",
|
|
@@ -6946,7 +7065,35 @@ var pl_default = {
|
|
|
6946
7065
|
"recovery.subtitle": "",
|
|
6947
7066
|
"registration.subtitle": "",
|
|
6948
7067
|
"settings.subtitle": "",
|
|
6949
|
-
"verification.subtitle": ""
|
|
7068
|
+
"verification.subtitle": "",
|
|
7069
|
+
"settings.totp.info.linked": "Aktualnie masz pod\u0142\u0105czon\u0105 aplikacj\u0119 uwierzytelniaj\u0105c\u0105.",
|
|
7070
|
+
"settings.totp.info.not-linked": "Aby w\u0142\u0105czy\u0107, zeskanuj kod QR za pomoc\u0105 swojego uwierzytelniaj\u0105cego i wprowad\u017A kod.",
|
|
7071
|
+
"settings.totp.title": "",
|
|
7072
|
+
"settings.totp.description": "Dodaj aplikacj\u0119 do uwierzytelniania TOTP do swojego konta, aby poprawi\u0107 bezpiecze\u0144stwo swojego konta. Popularne aplikacje uwierzytelniaj\u0105ce to LastPass i Google Authenticator.",
|
|
7073
|
+
"settings.lookup_secret.description": "",
|
|
7074
|
+
"settings.lookup_secret.title": "",
|
|
7075
|
+
"settings.navigation.title": "",
|
|
7076
|
+
"settings.oidc.description": "",
|
|
7077
|
+
"settings.oidc.info": "",
|
|
7078
|
+
"settings.oidc.title": "",
|
|
7079
|
+
"settings.passkey.description": "",
|
|
7080
|
+
"settings.passkey.info": "",
|
|
7081
|
+
"settings.passkey.title": "",
|
|
7082
|
+
"settings.password.description": "",
|
|
7083
|
+
"settings.password.title": "",
|
|
7084
|
+
"settings.profile.description": "",
|
|
7085
|
+
"settings.profile.title": "",
|
|
7086
|
+
"settings.title-lookup-secret": "",
|
|
7087
|
+
"settings.title-navigation": "",
|
|
7088
|
+
"settings.title-oidc": "",
|
|
7089
|
+
"settings.title-passkey": "",
|
|
7090
|
+
"settings.title-password": "",
|
|
7091
|
+
"settings.title-profile": "",
|
|
7092
|
+
"settings.title-totp": "",
|
|
7093
|
+
"settings.title-webauthn": "",
|
|
7094
|
+
"settings.webauthn.description": "",
|
|
7095
|
+
"settings.webauthn.info": "",
|
|
7096
|
+
"settings.webauthn.title": ""
|
|
6950
7097
|
};
|
|
6951
7098
|
|
|
6952
7099
|
// src/locales/pt.json
|
|
@@ -7113,14 +7260,6 @@ var pt_default = {
|
|
|
7113
7260
|
"settings.navigation-passkey": "Passkeys",
|
|
7114
7261
|
"settings.subtitle-instructions": "Aqui pode gerar configura\xE7\xF5es relacionadas com a sua conta. Lembre-se de que certas a\xE7\xF5es exigem que efetue novamente login.",
|
|
7115
7262
|
"settings.title": "Configura\xE7\xF5es da Conta",
|
|
7116
|
-
"settings.title-lookup-secret": "Gerar C\xF3digos de Recupera\xE7\xE3o de Backup de 2FA",
|
|
7117
|
-
"settings.title-navigation": "Configura\xE7\xF5es da Conta",
|
|
7118
|
-
"settings.title-oidc": "login social",
|
|
7119
|
-
"settings.title-password": "Alterar password",
|
|
7120
|
-
"settings.title-profile": "Configura\xE7\xF5es de Perfil",
|
|
7121
|
-
"settings.title-totp": "Gerar Aplica\xE7\xE3o Autenticador 2FA",
|
|
7122
|
-
"settings.title-webauthn": "Gerar Tokens de Hardware",
|
|
7123
|
-
"settings.title-passkey": "Gerar Passkeys",
|
|
7124
7263
|
"verification.registration-button": "Registar",
|
|
7125
7264
|
"verification.registration-label": "N\xE3o tem uma conta?",
|
|
7126
7265
|
"verification.title": "Verifique a sua conta",
|
|
@@ -7171,7 +7310,35 @@ var pt_default = {
|
|
|
7171
7310
|
"recovery.subtitle": "",
|
|
7172
7311
|
"registration.subtitle": "",
|
|
7173
7312
|
"settings.subtitle": "",
|
|
7174
|
-
"verification.subtitle": ""
|
|
7313
|
+
"verification.subtitle": "",
|
|
7314
|
+
"settings.totp.info.linked": "Voc\xEA atualmente tem um aplicativo autenticador conectado.",
|
|
7315
|
+
"settings.totp.info.not-linked": "Para ativar, escaneie o c\xF3digo QR com seu autenticador e insira o c\xF3digo.",
|
|
7316
|
+
"settings.totp.title": "",
|
|
7317
|
+
"settings.totp.description": "Adicione um aplicativo autenticador TOTP \xE0 sua conta para melhorar a seguran\xE7a da sua conta. Aplicativos autenticadores populares s\xE3o LastPass e Google Authenticator.",
|
|
7318
|
+
"settings.lookup_secret.description": "",
|
|
7319
|
+
"settings.lookup_secret.title": "",
|
|
7320
|
+
"settings.navigation.title": "",
|
|
7321
|
+
"settings.oidc.description": "",
|
|
7322
|
+
"settings.oidc.info": "",
|
|
7323
|
+
"settings.oidc.title": "",
|
|
7324
|
+
"settings.passkey.description": "",
|
|
7325
|
+
"settings.passkey.info": "",
|
|
7326
|
+
"settings.passkey.title": "",
|
|
7327
|
+
"settings.password.description": "",
|
|
7328
|
+
"settings.password.title": "",
|
|
7329
|
+
"settings.profile.description": "",
|
|
7330
|
+
"settings.profile.title": "",
|
|
7331
|
+
"settings.title-lookup-secret": "",
|
|
7332
|
+
"settings.title-navigation": "",
|
|
7333
|
+
"settings.title-oidc": "",
|
|
7334
|
+
"settings.title-passkey": "",
|
|
7335
|
+
"settings.title-password": "",
|
|
7336
|
+
"settings.title-profile": "",
|
|
7337
|
+
"settings.title-totp": "",
|
|
7338
|
+
"settings.title-webauthn": "",
|
|
7339
|
+
"settings.webauthn.description": "",
|
|
7340
|
+
"settings.webauthn.info": "",
|
|
7341
|
+
"settings.webauthn.title": ""
|
|
7175
7342
|
};
|
|
7176
7343
|
|
|
7177
7344
|
// src/locales/sv.json
|
|
@@ -7356,14 +7523,6 @@ var sv_default = {
|
|
|
7356
7523
|
"settings.navigation-passkey": "Passkeys",
|
|
7357
7524
|
"settings.subtitle-instructions": "H\xE4r kan du hantera inst\xE4llningar relaterade till ditt konto. T\xE4nk p\xE5 att vissa \xE5tg\xE4rder kr\xE4ver att du autentiseras p\xE5 nytt.",
|
|
7358
7525
|
"settings.title": "Kontoinst\xE4llningar",
|
|
7359
|
-
"settings.title-lookup-secret": "Hantera 2FA backup-\xE5terst\xE4llningskoder",
|
|
7360
|
-
"settings.title-navigation": "Kontoinst\xE4llningar",
|
|
7361
|
-
"settings.title-oidc": "Social Inloggning",
|
|
7362
|
-
"settings.title-password": "Byt l\xF6senord",
|
|
7363
|
-
"settings.title-profile": "Profilinst\xE4llningar",
|
|
7364
|
-
"settings.title-totp": "Hantera 2FA TOTP Autentiserings App",
|
|
7365
|
-
"settings.title-webauthn": "Hantera H\xE5rdvaru Tokens",
|
|
7366
|
-
"settings.title-passkey": "Hantera Passkeys",
|
|
7367
7526
|
"verification.registration-button": "Skapa konto",
|
|
7368
7527
|
"verification.registration-label": "Har du inget konto?",
|
|
7369
7528
|
"verification.title": "Verifiera ditt konto",
|
|
@@ -7379,7 +7538,7 @@ var sv_default = {
|
|
|
7379
7538
|
"identities.messages.4000037": "Detta konto finns inte eller har ingen inloggningsmetod konfigurerad.",
|
|
7380
7539
|
"identities.messages.4000038": "Captcha-verifiering misslyckades, f\xF6rs\xF6k igen.",
|
|
7381
7540
|
"identities.messages.1010020": "",
|
|
7382
|
-
"input.placeholder": "Ange
|
|
7541
|
+
"input.placeholder": "Ange din {placeholder}",
|
|
7383
7542
|
"card.header.description.login": "Logga in med {identifierLabel}",
|
|
7384
7543
|
"card.header.description.registration": "Registrera dig med {identifierLabel}",
|
|
7385
7544
|
"card.header.parts.code": "en kod skickad till din e-post",
|
|
@@ -7396,7 +7555,35 @@ var sv_default = {
|
|
|
7396
7555
|
"recovery.subtitle": "Ange e-postadressen kopplad till ditt konto f\xF6r att f\xE5 en eng\xE5ngskod f\xF6r \xE5tkomst",
|
|
7397
7556
|
"registration.subtitle": "Registrera dig med {parts}",
|
|
7398
7557
|
"settings.subtitle": "Uppdatera dina kontoinst\xE4llningar",
|
|
7399
|
-
"verification.subtitle": "Ange e-postadressen kopplad till ditt konto f\xF6r att verifiera det"
|
|
7558
|
+
"verification.subtitle": "Ange e-postadressen kopplad till ditt konto f\xF6r att verifiera det",
|
|
7559
|
+
"settings.totp.info.linked": "Du har f\xF6r n\xE4rvarande en autentiseringsapp kopplad.",
|
|
7560
|
+
"settings.totp.info.not-linked": "F\xF6r att aktivera, skanna QR-koden med din autentiserare och ange koden.",
|
|
7561
|
+
"settings.totp.title": "",
|
|
7562
|
+
"settings.totp.description": "L\xE4gg till en TOTP-autentiseringsapp till ditt konto f\xF6r att f\xF6rb\xE4ttra s\xE4kerheten p\xE5 ditt konto. Popul\xE4ra autentiseringsappar \xE4r LastPass och Google Authenticator.",
|
|
7563
|
+
"settings.lookup_secret.description": "\xC5terst\xE4llningskoder \xE4r en s\xE4ker backup f\xF6r 2FA, vilket g\xF6r att du kan \xE5terf\xE5 \xE5tkomst till ditt konto om du tappar bort din 2FA-enhet.",
|
|
7564
|
+
"settings.lookup_secret.title": "Backup-\xE5terst\xE4llningskoder (andra faktorn)",
|
|
7565
|
+
"settings.navigation.title": "Kontoinst\xE4llningar",
|
|
7566
|
+
"settings.oidc.description": "Anslut en social inloggningsleverant\xF6r till ditt konto.",
|
|
7567
|
+
"settings.oidc.info": "Anslutna konton fr\xE5n dessa leverant\xF6rer kan anv\xE4ndas f\xF6r att logga in p\xE5 ditt konto",
|
|
7568
|
+
"settings.oidc.title": "Anslutna konton",
|
|
7569
|
+
"settings.passkey.description": "Hantera dina l\xF6senordsinst\xE4llningar",
|
|
7570
|
+
"settings.passkey.info": "Hantera dina l\xF6senordsinst\xE4llningar",
|
|
7571
|
+
"settings.passkey.title": "Hantera l\xF6senord",
|
|
7572
|
+
"settings.password.description": "\xC4ndra ditt l\xF6senord",
|
|
7573
|
+
"settings.password.title": "\xC4ndra l\xF6senord",
|
|
7574
|
+
"settings.profile.description": "Uppdatera din profilinformation",
|
|
7575
|
+
"settings.profile.title": "Profilinst\xE4llningar",
|
|
7576
|
+
"settings.title-lookup-secret": "Hantera 2FA Backup Recovery-koder",
|
|
7577
|
+
"settings.title-navigation": "Kontoinst\xE4llningar",
|
|
7578
|
+
"settings.title-oidc": "Social logga in",
|
|
7579
|
+
"settings.title-passkey": "Hantera l\xF6senord",
|
|
7580
|
+
"settings.title-password": "\xC4ndra l\xF6senord",
|
|
7581
|
+
"settings.title-profile": "Profilinst\xE4llningar",
|
|
7582
|
+
"settings.title-totp": "Hantera 2FA TOTP Authenticator-appen",
|
|
7583
|
+
"settings.title-webauthn": "Hantera maskinvarutokens",
|
|
7584
|
+
"settings.webauthn.description": "Hantera inst\xE4llningarna f\xF6r din maskinvarutoken",
|
|
7585
|
+
"settings.webauthn.info": "H\xE5rdvarutokens anv\xE4nds f\xF6r andrafaktorsautentisering eller som f\xF6rstafaktor med l\xF6senordsnycklar",
|
|
7586
|
+
"settings.webauthn.title": "Hantera maskinvarutokens"
|
|
7400
7587
|
};
|
|
7401
7588
|
|
|
7402
7589
|
// src/locales/index.ts
|
|
@@ -7498,6 +7685,7 @@ function triggerToFunction(trigger) {
|
|
|
7498
7685
|
return triggerFn;
|
|
7499
7686
|
}
|
|
7500
7687
|
function useNodesGroups(nodes) {
|
|
7688
|
+
const groupSorter = useGroupSorter();
|
|
7501
7689
|
const groups = react.useMemo(() => {
|
|
7502
7690
|
var _a;
|
|
7503
7691
|
const groups2 = {};
|
|
@@ -7508,13 +7696,22 @@ function useNodesGroups(nodes) {
|
|
|
7508
7696
|
}
|
|
7509
7697
|
return groups2;
|
|
7510
7698
|
}, [nodes]);
|
|
7511
|
-
|
|
7699
|
+
const entries = react.useMemo(
|
|
7700
|
+
() => Object.entries(groups).sort(([a], [b]) => groupSorter(a, b)),
|
|
7701
|
+
[groups, groupSorter]
|
|
7702
|
+
);
|
|
7703
|
+
return {
|
|
7704
|
+
groups,
|
|
7705
|
+
entries
|
|
7706
|
+
};
|
|
7512
7707
|
}
|
|
7513
7708
|
var NodeInput = ({
|
|
7514
7709
|
node,
|
|
7515
7710
|
attributes
|
|
7516
7711
|
}) => {
|
|
7712
|
+
var _a;
|
|
7517
7713
|
const { Node: Node2 } = useComponents();
|
|
7714
|
+
const { setValue } = reactHookForm.useFormContext();
|
|
7518
7715
|
const nodeType = attributes.type;
|
|
7519
7716
|
const {
|
|
7520
7717
|
onloadTrigger,
|
|
@@ -7525,9 +7722,15 @@ var NodeInput = ({
|
|
|
7525
7722
|
//
|
|
7526
7723
|
...attrs
|
|
7527
7724
|
} = attributes;
|
|
7725
|
+
const setFormValue = () => {
|
|
7726
|
+
if (attrs.value) {
|
|
7727
|
+
setValue(attrs.name, attrs.value);
|
|
7728
|
+
}
|
|
7729
|
+
};
|
|
7528
7730
|
const hasRun = react.useRef(false);
|
|
7529
7731
|
react.useEffect(
|
|
7530
7732
|
() => {
|
|
7733
|
+
setFormValue();
|
|
7531
7734
|
if (!hasRun.current && onloadTrigger) {
|
|
7532
7735
|
hasRun.current = true;
|
|
7533
7736
|
triggerToWindowCall(onloadTrigger);
|
|
@@ -7538,13 +7741,14 @@ var NodeInput = ({
|
|
|
7538
7741
|
[]
|
|
7539
7742
|
);
|
|
7540
7743
|
const handleClick = () => {
|
|
7744
|
+
setFormValue();
|
|
7541
7745
|
if (onclickTrigger) {
|
|
7542
7746
|
triggerToWindowCall(onclickTrigger);
|
|
7543
7747
|
}
|
|
7544
7748
|
};
|
|
7545
7749
|
const isSocial = (attrs.name === "provider" || attrs.name === "link") && node.group === "oidc";
|
|
7546
7750
|
const isPinCodeInput = attrs.name === "code" && node.group === "code" || attrs.name === "totp_code" && node.group === "totp";
|
|
7547
|
-
const isResend =
|
|
7751
|
+
const isResend = ((_a = node.meta.label) == null ? void 0 : _a.id) === 1070008;
|
|
7548
7752
|
switch (nodeType) {
|
|
7549
7753
|
case clientFetch.UiNodeInputAttributesTypeEnum.Submit:
|
|
7550
7754
|
case clientFetch.UiNodeInputAttributesTypeEnum.Button:
|
|
@@ -7663,8 +7867,8 @@ function OryFormSocialButtonsForm() {
|
|
|
7663
7867
|
}
|
|
7664
7868
|
return /* @__PURE__ */ jsxRuntime.jsx(OryForm, { children: /* @__PURE__ */ jsxRuntime.jsx(OryFormOidcButtons, {}) });
|
|
7665
7869
|
}
|
|
7666
|
-
function computeDefaultValues(
|
|
7667
|
-
return
|
|
7870
|
+
function computeDefaultValues(nodes) {
|
|
7871
|
+
return nodes.reduce((acc, node) => {
|
|
7668
7872
|
var _a;
|
|
7669
7873
|
if (clientFetch.isUiNodeInputAttributes(node.attributes)) {
|
|
7670
7874
|
if (node.attributes.name === "method") {
|
|
@@ -7712,9 +7916,9 @@ async function onSubmitLogin({ config, flow }, {
|
|
|
7712
7916
|
},
|
|
7713
7917
|
onValidationError: (body2) => {
|
|
7714
7918
|
setFlowContainer({
|
|
7919
|
+
config,
|
|
7715
7920
|
flow: body2,
|
|
7716
|
-
flowType: clientFetch.FlowType.Login
|
|
7717
|
-
config
|
|
7921
|
+
flowType: clientFetch.FlowType.Login
|
|
7718
7922
|
});
|
|
7719
7923
|
},
|
|
7720
7924
|
onRedirect
|
|
@@ -7880,13 +8084,14 @@ async function onSubmitSettings({ config, flow }, {
|
|
|
7880
8084
|
})
|
|
7881
8085
|
);
|
|
7882
8086
|
}
|
|
7883
|
-
function OryForm({ children }) {
|
|
8087
|
+
function OryForm({ children, onAfterSubmit, nodes }) {
|
|
7884
8088
|
var _a;
|
|
7885
8089
|
const { Form } = useComponents();
|
|
7886
8090
|
const flowContainer = useOryFlow();
|
|
8091
|
+
const defaultNodes = nodes ? flowContainer.flow.ui.nodes.filter((node) => node.group === clientFetch.UiNodeGroupEnum.Default).concat(nodes) : flowContainer.flow.ui.nodes;
|
|
7887
8092
|
const methods = reactHookForm.useForm({
|
|
7888
8093
|
// TODO: Generify this, so we have typesafety in the submit handler.
|
|
7889
|
-
defaultValues: computeDefaultValues(
|
|
8094
|
+
defaultValues: computeDefaultValues(defaultNodes)
|
|
7890
8095
|
});
|
|
7891
8096
|
const intl = reactIntl.useIntl();
|
|
7892
8097
|
const onRedirect = (url, external) => {
|
|
@@ -7898,7 +8103,7 @@ function OryForm({ children }) {
|
|
|
7898
8103
|
};
|
|
7899
8104
|
const handleSuccess = (flow) => {
|
|
7900
8105
|
flowContainer.setFlowContainer(flow);
|
|
7901
|
-
methods.reset(computeDefaultValues(flow));
|
|
8106
|
+
methods.reset(computeDefaultValues(flow.flow.ui.nodes));
|
|
7902
8107
|
};
|
|
7903
8108
|
const onSubmit = async (data) => {
|
|
7904
8109
|
switch (flowContainer.flowType) {
|
|
@@ -7909,7 +8114,6 @@ function OryForm({ children }) {
|
|
|
7909
8114
|
if (submitData.method === "code" && data.code) {
|
|
7910
8115
|
submitData.resend = "";
|
|
7911
8116
|
}
|
|
7912
|
-
console.log(submitData);
|
|
7913
8117
|
await onSubmitLogin(flowContainer, {
|
|
7914
8118
|
onRedirect,
|
|
7915
8119
|
setFlowContainer: handleSuccess,
|
|
@@ -7952,14 +8156,34 @@ function OryForm({ children }) {
|
|
|
7952
8156
|
});
|
|
7953
8157
|
break;
|
|
7954
8158
|
}
|
|
7955
|
-
case clientFetch.FlowType.Settings:
|
|
8159
|
+
case clientFetch.FlowType.Settings: {
|
|
8160
|
+
const submitData = {
|
|
8161
|
+
...data
|
|
8162
|
+
};
|
|
8163
|
+
if ("totp_unlink" in submitData) {
|
|
8164
|
+
submitData.method = "totp";
|
|
8165
|
+
}
|
|
8166
|
+
if ("lookup_secret_confirm" in submitData || "lookup_secret_reveal" in submitData || "lookup_secret_regenerate" in submitData) {
|
|
8167
|
+
submitData.method = "lookup_secret";
|
|
8168
|
+
}
|
|
8169
|
+
if ("link" in submitData || "unlink" in submitData) {
|
|
8170
|
+
submitData.method = "oidc";
|
|
8171
|
+
}
|
|
8172
|
+
if ("webauthn_remove" in submitData) {
|
|
8173
|
+
submitData.method = "webauthn";
|
|
8174
|
+
}
|
|
8175
|
+
if ("passkey_remove" in submitData) {
|
|
8176
|
+
submitData.method = "passkey";
|
|
8177
|
+
}
|
|
7956
8178
|
await onSubmitSettings(flowContainer, {
|
|
7957
8179
|
onRedirect,
|
|
7958
8180
|
setFlowContainer: handleSuccess,
|
|
7959
|
-
body:
|
|
8181
|
+
body: submitData
|
|
7960
8182
|
});
|
|
7961
8183
|
break;
|
|
8184
|
+
}
|
|
7962
8185
|
}
|
|
8186
|
+
onAfterSubmit == null ? void 0 : onAfterSubmit(data.method);
|
|
7963
8187
|
};
|
|
7964
8188
|
const hasMethods = flowContainer.flow.ui.nodes.filter((node) => {
|
|
7965
8189
|
if (clientFetch.isUiNodeInputAttributes(node.attributes)) {
|
|
@@ -8013,6 +8237,10 @@ function OryCardValidationMessages({ ...props }) {
|
|
|
8013
8237
|
}
|
|
8014
8238
|
return /* @__PURE__ */ jsxRuntime.jsx(Message.Root, { ...props, children: messages == null ? void 0 : messages.map((message) => /* @__PURE__ */ jsxRuntime.jsx(Message.Content, { message }, message.id)) });
|
|
8015
8239
|
}
|
|
8240
|
+
function OryFormSection({ children, nodes }) {
|
|
8241
|
+
const { Card } = useComponents();
|
|
8242
|
+
return /* @__PURE__ */ jsxRuntime.jsx(OryForm, { nodes, children: /* @__PURE__ */ jsxRuntime.jsx(Card.SettingsSection, { children }) });
|
|
8243
|
+
}
|
|
8016
8244
|
function OryCardContent({ children }) {
|
|
8017
8245
|
const { Card } = useComponents();
|
|
8018
8246
|
if (children) {
|
|
@@ -8057,7 +8285,7 @@ function OryCardFooter() {
|
|
|
8057
8285
|
}
|
|
8058
8286
|
function isChoosingMethod(uiNodes) {
|
|
8059
8287
|
return uiNodes.some(
|
|
8060
|
-
(node) => "value" in node.attributes && node.attributes.value === "
|
|
8288
|
+
(node) => "name" in node.attributes && node.attributes.name === "screen" && "value" in node.attributes && node.attributes.value === "previous"
|
|
8061
8289
|
) || uiNodes.some(
|
|
8062
8290
|
(node) => node.group === clientFetch.UiNodeGroupEnum.IdentifierFirst && "name" in node.attributes && node.attributes.name === "identifier" && node.attributes.type === "hidden"
|
|
8063
8291
|
);
|
|
@@ -8075,6 +8303,11 @@ function getFinalNodes(uniqueGroups, selectedGroup) {
|
|
|
8075
8303
|
(node) => "type" in node.attributes && node.attributes.type === "hidden"
|
|
8076
8304
|
).concat(selectedNodes);
|
|
8077
8305
|
}
|
|
8306
|
+
|
|
8307
|
+
// src/theme/default/utils/form.ts
|
|
8308
|
+
function isGroupImmediateSubmit(group) {
|
|
8309
|
+
return group === "code";
|
|
8310
|
+
}
|
|
8078
8311
|
function OryTwoStepCard() {
|
|
8079
8312
|
var _a;
|
|
8080
8313
|
const {
|
|
@@ -8083,14 +8316,14 @@ function OryTwoStepCard() {
|
|
|
8083
8316
|
} = useOryFlow();
|
|
8084
8317
|
const choosingMethod = isChoosingMethod(ui.nodes);
|
|
8085
8318
|
const [selectedGroup, setSelectedGroup] = react.useState();
|
|
8086
|
-
const { Form
|
|
8319
|
+
const { Form } = useComponents();
|
|
8087
8320
|
const { flowType } = useOryFlow();
|
|
8088
8321
|
const nodeSorter = useNodeSorter();
|
|
8089
8322
|
const sortNodes = (a, b) => nodeSorter(a, b, { flowType });
|
|
8090
8323
|
const uniqueGroups = useNodesGroups(ui.nodes);
|
|
8091
8324
|
const options = Object.values(clientFetch.UiNodeGroupEnum).filter((group) => {
|
|
8092
8325
|
var _a2;
|
|
8093
|
-
return (_a2 = uniqueGroups[group]) == null ? void 0 : _a2.length;
|
|
8326
|
+
return (_a2 = uniqueGroups.groups[group]) == null ? void 0 : _a2.length;
|
|
8094
8327
|
}).filter(
|
|
8095
8328
|
(group) => ![
|
|
8096
8329
|
clientFetch.UiNodeGroupEnum.Oidc,
|
|
@@ -8099,37 +8332,61 @@ function OryTwoStepCard() {
|
|
|
8099
8332
|
clientFetch.UiNodeGroupEnum.Profile
|
|
8100
8333
|
].includes(group)
|
|
8101
8334
|
);
|
|
8102
|
-
const hasOidc = Boolean((_a = uniqueGroups.
|
|
8335
|
+
const hasOidc = Boolean((_a = uniqueGroups.groups[clientFetch.UiNodeGroupEnum.Oidc]) == null ? void 0 : _a.length);
|
|
8103
8336
|
const zeroStepGroups = filterZeroStepGroups(ui.nodes);
|
|
8104
|
-
const finalNodes = getFinalNodes(uniqueGroups, selectedGroup);
|
|
8337
|
+
const finalNodes = getFinalNodes(uniqueGroups.groups, selectedGroup);
|
|
8105
8338
|
const step = selectedGroup ? 2 /* ExecuteAuthMethod */ : choosingMethod ? 1 /* ChooseAuthMethod */ : 0 /* ProvideIdentifier */;
|
|
8106
8339
|
return /* @__PURE__ */ jsxRuntime.jsxs(OryCard, { children: [
|
|
8107
8340
|
/* @__PURE__ */ jsxRuntime.jsx(OryCardHeader, {}),
|
|
8108
8341
|
/* @__PURE__ */ jsxRuntime.jsxs(OryCardContent, { children: [
|
|
8109
8342
|
/* @__PURE__ */ jsxRuntime.jsx(OryCardValidationMessages, {}),
|
|
8110
8343
|
step === 0 /* ProvideIdentifier */ && hasOidc && /* @__PURE__ */ jsxRuntime.jsx(OryFormSocialButtonsForm, {}),
|
|
8111
|
-
/* @__PURE__ */ jsxRuntime.jsx(
|
|
8112
|
-
|
|
8113
|
-
|
|
8114
|
-
|
|
8115
|
-
|
|
8116
|
-
|
|
8117
|
-
{
|
|
8118
|
-
|
|
8119
|
-
|
|
8120
|
-
|
|
8121
|
-
|
|
8122
|
-
|
|
8123
|
-
|
|
8124
|
-
|
|
8125
|
-
|
|
8126
|
-
|
|
8127
|
-
|
|
8128
|
-
|
|
8344
|
+
/* @__PURE__ */ jsxRuntime.jsx(
|
|
8345
|
+
OryForm,
|
|
8346
|
+
{
|
|
8347
|
+
onAfterSubmit: (method) => isGroupImmediateSubmit(method + "") ? setSelectedGroup(method) : void 0,
|
|
8348
|
+
children: /* @__PURE__ */ jsxRuntime.jsxs(Form.Group, { children: [
|
|
8349
|
+
step === 0 /* ProvideIdentifier */ && zeroStepGroups.sort(sortNodes).map((node, k) => /* @__PURE__ */ jsxRuntime.jsx(Node, { node }, k)),
|
|
8350
|
+
step === 1 /* ChooseAuthMethod */ && /* @__PURE__ */ jsxRuntime.jsxs(jsxRuntime.Fragment, { children: [
|
|
8351
|
+
flowType === clientFetch.FlowType.Login && /* @__PURE__ */ jsxRuntime.jsx(BackButton, { href: config.project.login_ui_url }),
|
|
8352
|
+
/* @__PURE__ */ jsxRuntime.jsx(
|
|
8353
|
+
AuthMethodList,
|
|
8354
|
+
{
|
|
8355
|
+
options,
|
|
8356
|
+
setSelectedGroup
|
|
8357
|
+
}
|
|
8358
|
+
)
|
|
8359
|
+
] }),
|
|
8360
|
+
step === 2 /* ExecuteAuthMethod */ && /* @__PURE__ */ jsxRuntime.jsxs(jsxRuntime.Fragment, { children: [
|
|
8361
|
+
/* @__PURE__ */ jsxRuntime.jsx(BackButton, { onClick: () => setSelectedGroup(void 0) }),
|
|
8362
|
+
finalNodes.sort(sortNodes).map((node, k) => /* @__PURE__ */ jsxRuntime.jsx(Node, { node }, k))
|
|
8363
|
+
] })
|
|
8364
|
+
] })
|
|
8365
|
+
}
|
|
8366
|
+
)
|
|
8129
8367
|
] }),
|
|
8130
8368
|
/* @__PURE__ */ jsxRuntime.jsx(OryCardFooter, {})
|
|
8131
8369
|
] });
|
|
8132
8370
|
}
|
|
8371
|
+
function AuthMethodList({ options, setSelectedGroup }) {
|
|
8372
|
+
const { Card } = useComponents();
|
|
8373
|
+
const { setValue } = reactHookForm.useFormContext();
|
|
8374
|
+
const handleClick = (group) => {
|
|
8375
|
+
if (isGroupImmediateSubmit(group)) {
|
|
8376
|
+
setValue("method", group);
|
|
8377
|
+
} else {
|
|
8378
|
+
setSelectedGroup(group);
|
|
8379
|
+
}
|
|
8380
|
+
};
|
|
8381
|
+
return options.map((option) => /* @__PURE__ */ jsxRuntime.jsx(
|
|
8382
|
+
Card.AuthMethodListItem,
|
|
8383
|
+
{
|
|
8384
|
+
group: option,
|
|
8385
|
+
onClick: () => handleClick(option)
|
|
8386
|
+
},
|
|
8387
|
+
option
|
|
8388
|
+
));
|
|
8389
|
+
}
|
|
8133
8390
|
var BackButton = ({ onClick, href }) => {
|
|
8134
8391
|
const {
|
|
8135
8392
|
flow: { ui }
|
|
@@ -8170,6 +8427,319 @@ function OryFormGroupDivider() {
|
|
|
8170
8427
|
}
|
|
8171
8428
|
return null;
|
|
8172
8429
|
}
|
|
8430
|
+
var HeadlessPageHeader = () => {
|
|
8431
|
+
const { Page } = useComponents();
|
|
8432
|
+
return /* @__PURE__ */ jsxRuntime.jsx(Page.Header, {});
|
|
8433
|
+
};
|
|
8434
|
+
var getLinkButtons = (nodes) => nodes.filter(
|
|
8435
|
+
(node) => "name" in node.attributes && node.attributes.name === "link"
|
|
8436
|
+
);
|
|
8437
|
+
var getUnlinkButtons = (nodes) => nodes.filter(
|
|
8438
|
+
(node) => "name" in node.attributes && node.attributes.name === "unlink"
|
|
8439
|
+
);
|
|
8440
|
+
function OrySettingsOidc({ nodes }) {
|
|
8441
|
+
const { Card, Form } = useComponents();
|
|
8442
|
+
const intl = reactIntl.useIntl();
|
|
8443
|
+
const linkButtons = getLinkButtons(nodes);
|
|
8444
|
+
const unlinkButtons = getUnlinkButtons(nodes);
|
|
8445
|
+
return /* @__PURE__ */ jsxRuntime.jsxs(jsxRuntime.Fragment, { children: [
|
|
8446
|
+
/* @__PURE__ */ jsxRuntime.jsx(
|
|
8447
|
+
Card.SettingsSectionContent,
|
|
8448
|
+
{
|
|
8449
|
+
title: intl.formatMessage({ id: "settings.oidc.title" }),
|
|
8450
|
+
description: intl.formatMessage({ id: "settings.oidc.description" }),
|
|
8451
|
+
children: /* @__PURE__ */ jsxRuntime.jsx(
|
|
8452
|
+
Form.OidcSettings,
|
|
8453
|
+
{
|
|
8454
|
+
linkButtons,
|
|
8455
|
+
unlinkButtons
|
|
8456
|
+
}
|
|
8457
|
+
)
|
|
8458
|
+
}
|
|
8459
|
+
),
|
|
8460
|
+
/* @__PURE__ */ jsxRuntime.jsx(Card.SettingsSectionFooter, { children: /* @__PURE__ */ jsxRuntime.jsx("span", { children: intl.formatMessage({ id: "settings.oidc.info" }) }) })
|
|
8461
|
+
] });
|
|
8462
|
+
}
|
|
8463
|
+
var getTriggerNode = (nodes) => nodes.find(
|
|
8464
|
+
(node) => "name" in node.attributes && node.attributes.name === "passkey_register_trigger"
|
|
8465
|
+
);
|
|
8466
|
+
var getSettingsNodes = (nodes) => nodes.filter(
|
|
8467
|
+
(node) => "name" in node.attributes && (node.attributes.name === "passkey_settings_register" || node.attributes.name === "passkey_create_data")
|
|
8468
|
+
);
|
|
8469
|
+
var getRemoveNodes = (nodes) => nodes.filter(
|
|
8470
|
+
(node) => "name" in node.attributes && node.attributes.name === "passkey_remove"
|
|
8471
|
+
);
|
|
8472
|
+
function OrySettingsPasskey({ nodes }) {
|
|
8473
|
+
var _a;
|
|
8474
|
+
const { Card, Form } = useComponents();
|
|
8475
|
+
const intl = reactIntl.useIntl();
|
|
8476
|
+
const { flow } = useOryFlow();
|
|
8477
|
+
const { groups } = useNodesGroups(flow.ui.nodes);
|
|
8478
|
+
const triggerButton = getTriggerNode(nodes);
|
|
8479
|
+
const settingsNodes = getSettingsNodes(nodes);
|
|
8480
|
+
const removeNodes = getRemoveNodes(nodes);
|
|
8481
|
+
if (!triggerButton) {
|
|
8482
|
+
return null;
|
|
8483
|
+
}
|
|
8484
|
+
const {
|
|
8485
|
+
onclick: _onClick,
|
|
8486
|
+
onclickTrigger,
|
|
8487
|
+
...triggerAttributes
|
|
8488
|
+
} = triggerButton.attributes;
|
|
8489
|
+
const onTriggerClick = () => {
|
|
8490
|
+
triggerToWindowCall(onclickTrigger);
|
|
8491
|
+
};
|
|
8492
|
+
return /* @__PURE__ */ jsxRuntime.jsxs(jsxRuntime.Fragment, { children: [
|
|
8493
|
+
/* @__PURE__ */ jsxRuntime.jsxs(
|
|
8494
|
+
Card.SettingsSectionContent,
|
|
8495
|
+
{
|
|
8496
|
+
title: intl.formatMessage({ id: "settings.passkey.title" }),
|
|
8497
|
+
description: intl.formatMessage({
|
|
8498
|
+
id: "settings.passkey.description"
|
|
8499
|
+
}),
|
|
8500
|
+
children: [
|
|
8501
|
+
(_a = groups.default) == null ? void 0 : _a.map((node, i) => /* @__PURE__ */ jsxRuntime.jsx(Node, { node }, `passkey-default-nodes-${i}`)),
|
|
8502
|
+
settingsNodes.map((node, i) => /* @__PURE__ */ jsxRuntime.jsx(Node, { node }, `passkey-settings-nodes-${i}`)),
|
|
8503
|
+
/* @__PURE__ */ jsxRuntime.jsx(
|
|
8504
|
+
Form.PasskeySettings,
|
|
8505
|
+
{
|
|
8506
|
+
triggerButton: {
|
|
8507
|
+
...triggerButton,
|
|
8508
|
+
attributes: triggerAttributes,
|
|
8509
|
+
onClick: onTriggerClick
|
|
8510
|
+
},
|
|
8511
|
+
removeButtons: removeNodes
|
|
8512
|
+
}
|
|
8513
|
+
)
|
|
8514
|
+
]
|
|
8515
|
+
}
|
|
8516
|
+
),
|
|
8517
|
+
/* @__PURE__ */ jsxRuntime.jsx(Card.SettingsSectionFooter, { children: /* @__PURE__ */ jsxRuntime.jsx("span", { children: intl.formatMessage({ id: "settings.passkey.info" }) }) })
|
|
8518
|
+
] });
|
|
8519
|
+
}
|
|
8520
|
+
var getRegenerateNode = (nodes) => nodes.find(
|
|
8521
|
+
(node) => "name" in node.attributes && node.attributes.name === "lookup_secret_regenerate"
|
|
8522
|
+
);
|
|
8523
|
+
var getRevealNode = (nodes) => nodes.find(
|
|
8524
|
+
(node) => "name" in node.attributes && node.attributes.name === "lookup_secret_reveal"
|
|
8525
|
+
);
|
|
8526
|
+
var getRecoveryCodes = (nodes) => nodes.find(
|
|
8527
|
+
(node) => "id" in node.attributes && node.attributes.id === "lookup_secret_codes"
|
|
8528
|
+
);
|
|
8529
|
+
function OrySettingsRecoveryCodes({
|
|
8530
|
+
nodes
|
|
8531
|
+
}) {
|
|
8532
|
+
var _a, _b;
|
|
8533
|
+
const { Card, Form } = useComponents();
|
|
8534
|
+
const intl = reactIntl.useIntl();
|
|
8535
|
+
const codesNode = getRecoveryCodes(nodes);
|
|
8536
|
+
const revealNode = getRevealNode(nodes);
|
|
8537
|
+
const regenerateNode = getRegenerateNode(nodes);
|
|
8538
|
+
const codesContext = (_b = (_a = codesNode == null ? void 0 : codesNode.attributes) == null ? void 0 : _a.text.context) != null ? _b : {};
|
|
8539
|
+
const secrets = codesContext.secrets ? codesContext.secrets.map((i) => i.text) : [];
|
|
8540
|
+
return /* @__PURE__ */ jsxRuntime.jsxs(jsxRuntime.Fragment, { children: [
|
|
8541
|
+
/* @__PURE__ */ jsxRuntime.jsx(
|
|
8542
|
+
Card.SettingsSectionContent,
|
|
8543
|
+
{
|
|
8544
|
+
title: intl.formatMessage({ id: "settings.lookup_secret.title" }),
|
|
8545
|
+
description: intl.formatMessage({
|
|
8546
|
+
id: "settings.lookup_secret.description"
|
|
8547
|
+
}),
|
|
8548
|
+
children: /* @__PURE__ */ jsxRuntime.jsx(
|
|
8549
|
+
Form.RecoveryCodesSettings,
|
|
8550
|
+
{
|
|
8551
|
+
codes: secrets,
|
|
8552
|
+
revealButton: revealNode,
|
|
8553
|
+
regnerateButton: regenerateNode
|
|
8554
|
+
}
|
|
8555
|
+
)
|
|
8556
|
+
}
|
|
8557
|
+
),
|
|
8558
|
+
/* @__PURE__ */ jsxRuntime.jsx(Card.SettingsSectionFooter, { children: nodes.filter(
|
|
8559
|
+
(node) => "type" in node.attributes && node.attributes.type === "submit" && "name" in node.attributes && node.attributes.name !== "lookup_secret_reveal" && node.attributes.name !== "lookup_secret_regenerate"
|
|
8560
|
+
).map((node, k) => /* @__PURE__ */ jsxRuntime.jsx(Node, { node }, k)) })
|
|
8561
|
+
] });
|
|
8562
|
+
}
|
|
8563
|
+
var getQrCodeNode = (nodes) => nodes.find(
|
|
8564
|
+
(node) => "id" in node.attributes && node.attributes.id === "totp_qr"
|
|
8565
|
+
);
|
|
8566
|
+
var getTotpSecretNode = (nodes) => nodes.find(
|
|
8567
|
+
(node) => "id" in node.attributes && node.attributes.id === "totp_secret_key"
|
|
8568
|
+
);
|
|
8569
|
+
var getTotpInputNode = (nodes) => nodes.find(
|
|
8570
|
+
(node) => "name" in node.attributes && node.attributes.name === "totp_code"
|
|
8571
|
+
);
|
|
8572
|
+
var getTotpUnlinkInput = (nodes) => nodes.find(
|
|
8573
|
+
(node) => "name" in node.attributes && node.attributes.name === "totp_unlink"
|
|
8574
|
+
);
|
|
8575
|
+
var getTotpLinkButton = (nodes) => nodes.find(
|
|
8576
|
+
(node) => "name" in node.attributes && node.attributes.name === "method"
|
|
8577
|
+
);
|
|
8578
|
+
function OrySettingsTotp({ nodes }) {
|
|
8579
|
+
const { Card, Form, Node: Node2 } = useComponents();
|
|
8580
|
+
const intl = reactIntl.useIntl();
|
|
8581
|
+
const totpUnlink = getTotpUnlinkInput(nodes);
|
|
8582
|
+
const qrNode = getQrCodeNode(nodes);
|
|
8583
|
+
const secretNode = getTotpSecretNode(nodes);
|
|
8584
|
+
const totpCodeNode = getTotpInputNode(nodes);
|
|
8585
|
+
const totpLinkButton = getTotpLinkButton(nodes);
|
|
8586
|
+
const props = {
|
|
8587
|
+
totpImage: qrNode,
|
|
8588
|
+
totpSecret: secretNode,
|
|
8589
|
+
totpInput: totpCodeNode,
|
|
8590
|
+
totpUnlink
|
|
8591
|
+
};
|
|
8592
|
+
const content = /* @__PURE__ */ jsxRuntime.jsx(Form.TotpSettings, { ...props });
|
|
8593
|
+
return /* @__PURE__ */ jsxRuntime.jsxs(jsxRuntime.Fragment, { children: [
|
|
8594
|
+
/* @__PURE__ */ jsxRuntime.jsx(
|
|
8595
|
+
Card.SettingsSectionContent,
|
|
8596
|
+
{
|
|
8597
|
+
title: intl.formatMessage({ id: "settings.totp.title" }),
|
|
8598
|
+
description: intl.formatMessage({ id: "settings.totp.description" }),
|
|
8599
|
+
children: content
|
|
8600
|
+
}
|
|
8601
|
+
),
|
|
8602
|
+
/* @__PURE__ */ jsxRuntime.jsxs(Card.SettingsSectionFooter, { children: [
|
|
8603
|
+
/* @__PURE__ */ jsxRuntime.jsx("span", { children: totpUnlink ? intl.formatMessage({ id: "settings.totp.info.linked" }) : intl.formatMessage({ id: "settings.totp.info.not-linked" }) }),
|
|
8604
|
+
totpLinkButton && /* @__PURE__ */ jsxRuntime.jsx(
|
|
8605
|
+
Node2.Button,
|
|
8606
|
+
{
|
|
8607
|
+
node: totpLinkButton,
|
|
8608
|
+
attributes: totpLinkButton.attributes
|
|
8609
|
+
}
|
|
8610
|
+
)
|
|
8611
|
+
] })
|
|
8612
|
+
] });
|
|
8613
|
+
}
|
|
8614
|
+
var getInputNode = (nodes) => nodes.find(
|
|
8615
|
+
(node) => "name" in node.attributes && node.attributes.name === "webauthn_register_displayname"
|
|
8616
|
+
);
|
|
8617
|
+
var getTriggerNode2 = (nodes) => nodes.find(
|
|
8618
|
+
(node) => "name" in node.attributes && node.attributes.name === "webauthn_register_trigger"
|
|
8619
|
+
);
|
|
8620
|
+
var getRemoveButtons = (nodes) => nodes.filter(
|
|
8621
|
+
(node) => "name" in node.attributes && node.attributes.name === "webauthn_remove"
|
|
8622
|
+
);
|
|
8623
|
+
var getScriptNode = (nodes) => nodes.find(
|
|
8624
|
+
(node) => "id" in node.attributes && node.attributes.id === "webauthn_script"
|
|
8625
|
+
);
|
|
8626
|
+
var getRegisterNode = (nodes) => nodes.find(
|
|
8627
|
+
(node) => "name" in node.attributes && node.attributes.name === "webauthn_register"
|
|
8628
|
+
);
|
|
8629
|
+
function OrySettingsWebauthn({ nodes }) {
|
|
8630
|
+
var _a;
|
|
8631
|
+
const { Card, Form } = useComponents();
|
|
8632
|
+
const intl = reactIntl.useIntl();
|
|
8633
|
+
const { flow } = useOryFlow();
|
|
8634
|
+
const { groups } = useNodesGroups(flow.ui.nodes);
|
|
8635
|
+
const triggerButton = getTriggerNode2(nodes);
|
|
8636
|
+
const inputNode = getInputNode(nodes);
|
|
8637
|
+
const removeButtons = getRemoveButtons(nodes);
|
|
8638
|
+
const scriptNode = getScriptNode(nodes);
|
|
8639
|
+
const registerNode = getRegisterNode(nodes);
|
|
8640
|
+
if (!inputNode || !triggerButton) {
|
|
8641
|
+
return null;
|
|
8642
|
+
}
|
|
8643
|
+
const {
|
|
8644
|
+
onclick: _onClick,
|
|
8645
|
+
onclickTrigger,
|
|
8646
|
+
...triggerAttributes
|
|
8647
|
+
} = triggerButton.attributes;
|
|
8648
|
+
const onTriggerClick = () => {
|
|
8649
|
+
triggerToWindowCall(onclickTrigger);
|
|
8650
|
+
};
|
|
8651
|
+
return /* @__PURE__ */ jsxRuntime.jsxs(jsxRuntime.Fragment, { children: [
|
|
8652
|
+
/* @__PURE__ */ jsxRuntime.jsxs(
|
|
8653
|
+
Card.SettingsSectionContent,
|
|
8654
|
+
{
|
|
8655
|
+
title: intl.formatMessage({ id: "settings.webauthn.title" }),
|
|
8656
|
+
description: intl.formatMessage({
|
|
8657
|
+
id: "settings.webauthn.description"
|
|
8658
|
+
}),
|
|
8659
|
+
children: [
|
|
8660
|
+
(_a = groups.default) == null ? void 0 : _a.map((node, i) => /* @__PURE__ */ jsxRuntime.jsx(Node, { node }, `webauthn-default-${i}`)),
|
|
8661
|
+
scriptNode && /* @__PURE__ */ jsxRuntime.jsx(Node, { node: scriptNode }),
|
|
8662
|
+
registerNode && /* @__PURE__ */ jsxRuntime.jsx(Node, { node: registerNode }),
|
|
8663
|
+
/* @__PURE__ */ jsxRuntime.jsx(
|
|
8664
|
+
Form.WebauthnSettings,
|
|
8665
|
+
{
|
|
8666
|
+
nameInput: inputNode,
|
|
8667
|
+
triggerButton: {
|
|
8668
|
+
...triggerButton,
|
|
8669
|
+
attributes: triggerAttributes,
|
|
8670
|
+
onClick: onTriggerClick
|
|
8671
|
+
},
|
|
8672
|
+
removeButtons
|
|
8673
|
+
}
|
|
8674
|
+
)
|
|
8675
|
+
]
|
|
8676
|
+
}
|
|
8677
|
+
),
|
|
8678
|
+
/* @__PURE__ */ jsxRuntime.jsx(Card.SettingsSectionFooter, { children: /* @__PURE__ */ jsxRuntime.jsx("span", { children: intl.formatMessage({ id: "settings.webauthn.info" }) }) })
|
|
8679
|
+
] });
|
|
8680
|
+
}
|
|
8681
|
+
function SettingsSectionContent({ group, nodes }) {
|
|
8682
|
+
var _a, _b, _c, _d, _e, _f;
|
|
8683
|
+
const { Card } = useComponents();
|
|
8684
|
+
const intl = reactIntl.useIntl();
|
|
8685
|
+
const { flow } = useOryFlow();
|
|
8686
|
+
const uniqueGroups = useNodesGroups(flow.ui.nodes);
|
|
8687
|
+
if (group === clientFetch.UiNodeGroupEnum.Totp) {
|
|
8688
|
+
return /* @__PURE__ */ jsxRuntime.jsx(OryFormSection, { nodes: uniqueGroups.groups.totp, children: /* @__PURE__ */ jsxRuntime.jsx(OrySettingsTotp, { nodes: (_a = uniqueGroups.groups.totp) != null ? _a : [] }) });
|
|
8689
|
+
}
|
|
8690
|
+
if (group === clientFetch.UiNodeGroupEnum.LookupSecret) {
|
|
8691
|
+
return /* @__PURE__ */ jsxRuntime.jsx(OryFormSection, { nodes: uniqueGroups.groups.lookup_secret, children: /* @__PURE__ */ jsxRuntime.jsx(
|
|
8692
|
+
OrySettingsRecoveryCodes,
|
|
8693
|
+
{
|
|
8694
|
+
nodes: (_b = uniqueGroups.groups.lookup_secret) != null ? _b : []
|
|
8695
|
+
}
|
|
8696
|
+
) });
|
|
8697
|
+
}
|
|
8698
|
+
if (group === clientFetch.UiNodeGroupEnum.Oidc) {
|
|
8699
|
+
return /* @__PURE__ */ jsxRuntime.jsx(OryFormSection, { nodes: uniqueGroups.groups.oidc, children: /* @__PURE__ */ jsxRuntime.jsx(OrySettingsOidc, { nodes: (_c = uniqueGroups.groups.oidc) != null ? _c : [] }) });
|
|
8700
|
+
}
|
|
8701
|
+
if (group === clientFetch.UiNodeGroupEnum.Webauthn) {
|
|
8702
|
+
return /* @__PURE__ */ jsxRuntime.jsx(OryFormSection, { nodes: uniqueGroups.groups.webauthn, children: /* @__PURE__ */ jsxRuntime.jsx(OrySettingsWebauthn, { nodes: (_d = uniqueGroups.groups.webauthn) != null ? _d : [] }) });
|
|
8703
|
+
}
|
|
8704
|
+
if (group === clientFetch.UiNodeGroupEnum.Passkey) {
|
|
8705
|
+
return /* @__PURE__ */ jsxRuntime.jsx(OryFormSection, { nodes: uniqueGroups.groups.passkey, children: /* @__PURE__ */ jsxRuntime.jsx(OrySettingsPasskey, { nodes: (_e = uniqueGroups.groups.passkey) != null ? _e : [] }) });
|
|
8706
|
+
}
|
|
8707
|
+
return /* @__PURE__ */ jsxRuntime.jsxs(OryFormSection, { nodes, children: [
|
|
8708
|
+
/* @__PURE__ */ jsxRuntime.jsxs(
|
|
8709
|
+
Card.SettingsSectionContent,
|
|
8710
|
+
{
|
|
8711
|
+
title: intl.formatMessage({
|
|
8712
|
+
id: `settings.${group}.title`
|
|
8713
|
+
}),
|
|
8714
|
+
description: intl.formatMessage({
|
|
8715
|
+
id: `settings.${group}.description`
|
|
8716
|
+
}),
|
|
8717
|
+
children: [
|
|
8718
|
+
(_f = uniqueGroups.groups.default) == null ? void 0 : _f.map((node, k) => /* @__PURE__ */ jsxRuntime.jsx(Node, { node }, k)),
|
|
8719
|
+
nodes.filter(
|
|
8720
|
+
(node) => "type" in node.attributes && node.attributes.type !== "submit"
|
|
8721
|
+
).map((node, k) => /* @__PURE__ */ jsxRuntime.jsx(Node, { node }, k))
|
|
8722
|
+
]
|
|
8723
|
+
}
|
|
8724
|
+
),
|
|
8725
|
+
/* @__PURE__ */ jsxRuntime.jsx(Card.SettingsSectionFooter, { children: nodes.filter(
|
|
8726
|
+
(node) => "type" in node.attributes && node.attributes.type === "submit"
|
|
8727
|
+
).map((node, k) => /* @__PURE__ */ jsxRuntime.jsx(Node, { node }, k)) })
|
|
8728
|
+
] });
|
|
8729
|
+
}
|
|
8730
|
+
function OrySettingsCard() {
|
|
8731
|
+
const { flow } = useOryFlow();
|
|
8732
|
+
const uniqueGroups = useNodesGroups(flow.ui.nodes);
|
|
8733
|
+
return /* @__PURE__ */ jsxRuntime.jsxs(jsxRuntime.Fragment, { children: [
|
|
8734
|
+
/* @__PURE__ */ jsxRuntime.jsx(OryCardValidationMessages, {}),
|
|
8735
|
+
uniqueGroups.entries.map(([group, nodes]) => {
|
|
8736
|
+
if (group === clientFetch.UiNodeGroupEnum.Default) {
|
|
8737
|
+
return null;
|
|
8738
|
+
}
|
|
8739
|
+
return /* @__PURE__ */ jsxRuntime.jsx(SettingsSectionContent, { group, nodes }, group);
|
|
8740
|
+
})
|
|
8741
|
+
] });
|
|
8742
|
+
}
|
|
8173
8743
|
|
|
8174
8744
|
// src/util/i18n/index.ts
|
|
8175
8745
|
var uiTextToFormattedMessage = ({ id, context = {}, text }, intl) => {
|
|
@@ -8275,6 +8845,7 @@ lodash/lodash.js:
|
|
|
8275
8845
|
*)
|
|
8276
8846
|
*/
|
|
8277
8847
|
|
|
8848
|
+
exports.HeadlessPageHeader = HeadlessPageHeader;
|
|
8278
8849
|
exports.OryCard = OryCard;
|
|
8279
8850
|
exports.OryCardContent = OryCardContent;
|
|
8280
8851
|
exports.OryCardFooter = OryCardFooter;
|
|
@@ -8284,9 +8855,11 @@ exports.OryForm = OryForm;
|
|
|
8284
8855
|
exports.OryFormGroupDivider = OryFormGroupDivider;
|
|
8285
8856
|
exports.OryFormGroups = OryFormGroups;
|
|
8286
8857
|
exports.OryFormOidcButtons = OryFormOidcButtons;
|
|
8858
|
+
exports.OryFormSection = OryFormSection;
|
|
8287
8859
|
exports.OryFormSocialButtonsForm = OryFormSocialButtonsForm;
|
|
8288
8860
|
exports.OryLocales = locales;
|
|
8289
8861
|
exports.OryProvider = OryProvider;
|
|
8862
|
+
exports.OrySettingsCard = OrySettingsCard;
|
|
8290
8863
|
exports.OryTwoStepCard = OryTwoStepCard;
|
|
8291
8864
|
exports.messageTestId = messageTestId;
|
|
8292
8865
|
exports.uiTextToFormattedMessage = uiTextToFormattedMessage;
|