@owlmeans/client-auth 0.1.18-rc.6 → 0.1.18-rc.60
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/README.md +283 -37
- package/agent-meta/manifest.json +2 -2
- package/agent-meta/skills/client-auth/SKILL.md +170 -21
- package/build/components/dispatcher/component.d.ts.map +1 -1
- package/build/components/dispatcher/component.js +26 -6
- package/build/components/dispatcher/component.js.map +1 -1
- package/build/components/dispatcher/types.local.d.ts +7 -0
- package/build/components/dispatcher/types.local.d.ts.map +1 -0
- package/build/components/dispatcher/types.local.js +2 -0
- package/build/components/dispatcher/types.local.js.map +1 -0
- package/build/entrypoints.d.ts +7 -0
- package/build/entrypoints.d.ts.map +1 -0
- package/build/entrypoints.js +7 -0
- package/build/entrypoints.js.map +1 -0
- package/build/helper.d.ts +2 -1
- package/build/helper.d.ts.map +1 -1
- package/build/helper.js +28 -5
- package/build/helper.js.map +1 -1
- package/build/index.d.ts +1 -1
- package/build/index.d.ts.map +1 -1
- package/build/index.js +1 -1
- package/build/index.js.map +1 -1
- package/build/login/adopt/types.d.ts +26 -0
- package/build/login/adopt/types.d.ts.map +1 -0
- package/build/login/adopt/types.js +2 -0
- package/build/login/adopt/types.js.map +1 -0
- package/build/login/adopt.d.ts +10 -0
- package/build/login/adopt.d.ts.map +1 -0
- package/build/login/adopt.js +18 -0
- package/build/login/adopt.js.map +1 -0
- package/build/login/consts.d.ts +103 -0
- package/build/login/consts.d.ts.map +1 -0
- package/build/login/consts.js +106 -0
- package/build/login/consts.js.map +1 -0
- package/build/login/consts.local.d.ts +16 -0
- package/build/login/consts.local.d.ts.map +1 -0
- package/build/login/consts.local.js +30 -0
- package/build/login/consts.local.js.map +1 -0
- package/build/login/credit/types.d.ts +7 -0
- package/build/login/credit/types.d.ts.map +1 -0
- package/build/login/credit/types.js +2 -0
- package/build/login/credit/types.js.map +1 -0
- package/build/login/credit.d.ts +19 -0
- package/build/login/credit.d.ts.map +1 -0
- package/build/login/credit.js +58 -0
- package/build/login/credit.js.map +1 -0
- package/build/login/env/types.d.ts +35 -0
- package/build/login/env/types.d.ts.map +1 -0
- package/build/login/env/types.js +2 -0
- package/build/login/env/types.js.map +1 -0
- package/build/login/env.d.ts +8 -0
- package/build/login/env.d.ts.map +1 -0
- package/build/login/env.js +67 -0
- package/build/login/env.js.map +1 -0
- package/build/login/flow.d.ts +20 -0
- package/build/login/flow.d.ts.map +1 -0
- package/build/login/flow.js +39 -0
- package/build/login/flow.js.map +1 -0
- package/build/login/hook.d.ts +52 -0
- package/build/login/hook.d.ts.map +1 -0
- package/build/login/hook.js +89 -0
- package/build/login/hook.js.map +1 -0
- package/build/login/i18n/be.json +41 -0
- package/build/login/i18n/de.json +41 -0
- package/build/login/i18n/en.json +41 -0
- package/build/login/i18n/es.json +41 -0
- package/build/login/i18n/fr.json +41 -0
- package/build/login/i18n/pl.json +41 -0
- package/build/login/i18n/ru.json +41 -0
- package/build/login/i18n/uk.json +41 -0
- package/build/login/i18n.d.ts +2 -0
- package/build/login/i18n.d.ts.map +1 -0
- package/build/login/i18n.js +27 -0
- package/build/login/i18n.js.map +1 -0
- package/build/login/index.d.ts +27 -0
- package/build/login/index.d.ts.map +1 -0
- package/build/login/index.js +18 -0
- package/build/login/index.js.map +1 -0
- package/build/login/land/types.d.ts +52 -0
- package/build/login/land/types.d.ts.map +1 -0
- package/build/login/land/types.js +2 -0
- package/build/login/land/types.js.map +1 -0
- package/build/login/land.d.ts +6 -0
- package/build/login/land.d.ts.map +1 -0
- package/build/login/land.js +122 -0
- package/build/login/land.js.map +1 -0
- package/build/login/methods/types.d.ts +30 -0
- package/build/login/methods/types.d.ts.map +1 -0
- package/build/login/methods/types.js +2 -0
- package/build/login/methods/types.js.map +1 -0
- package/build/login/methods.d.ts +7 -0
- package/build/login/methods.d.ts.map +1 -0
- package/build/login/methods.js +87 -0
- package/build/login/methods.js.map +1 -0
- package/build/login/resume/types.d.ts +24 -0
- package/build/login/resume/types.d.ts.map +1 -0
- package/build/login/resume/types.js +2 -0
- package/build/login/resume/types.js.map +1 -0
- package/build/login/resume.d.ts +9 -0
- package/build/login/resume.d.ts.map +1 -0
- package/build/login/resume.js +38 -0
- package/build/login/resume.js.map +1 -0
- package/build/login/screen.d.ts +17 -0
- package/build/login/screen.d.ts.map +1 -0
- package/build/login/screen.js +66 -0
- package/build/login/screen.js.map +1 -0
- package/build/login/service.d.ts +31 -0
- package/build/login/service.d.ts.map +1 -0
- package/build/login/service.js +210 -0
- package/build/login/service.js.map +1 -0
- package/build/login/start/types.d.ts +29 -0
- package/build/login/start/types.d.ts.map +1 -0
- package/build/login/start/types.js +2 -0
- package/build/login/start/types.js.map +1 -0
- package/build/login/start.d.ts +5 -0
- package/build/login/start.d.ts.map +1 -0
- package/build/login/start.js +36 -0
- package/build/login/start.js.map +1 -0
- package/build/login/surrogate/types.d.ts +9 -0
- package/build/login/surrogate/types.d.ts.map +1 -0
- package/build/login/surrogate/types.js +2 -0
- package/build/login/surrogate/types.js.map +1 -0
- package/build/login/surrogate.d.ts +13 -0
- package/build/login/surrogate.d.ts.map +1 -0
- package/build/login/surrogate.js +33 -0
- package/build/login/surrogate.js.map +1 -0
- package/build/login/terms/types.d.ts +112 -0
- package/build/login/terms/types.d.ts.map +1 -0
- package/build/login/terms/types.js +2 -0
- package/build/login/terms/types.js.map +1 -0
- package/build/login/terms-config.d.ts +65 -0
- package/build/login/terms-config.d.ts.map +1 -0
- package/build/login/terms-config.js +2 -0
- package/build/login/terms-config.js.map +1 -0
- package/build/login/terms.d.ts +21 -0
- package/build/login/terms.d.ts.map +1 -0
- package/build/login/terms.js +235 -0
- package/build/login/terms.js.map +1 -0
- package/build/login/types.d.ts +313 -0
- package/build/login/types.d.ts.map +1 -0
- package/build/login/types.js +2 -0
- package/build/login/types.js.map +1 -0
- package/build/manager/components/authentication/control.js +3 -3
- package/build/manager/components/authentication/control.js.map +1 -1
- package/build/manager/components/authentication/types.d.ts +2 -2
- package/build/manager/components/authentication/types.d.ts.map +1 -1
- package/build/manager/components/tunnel-consumer.js +2 -2
- package/build/manager/components/tunnel-consumer.js.map +1 -1
- package/build/manager/entrypoints.d.ts +11 -0
- package/build/manager/entrypoints.d.ts.map +1 -0
- package/build/manager/entrypoints.js +17 -0
- package/build/manager/entrypoints.js.map +1 -0
- package/build/manager/plugins/basic-ed25519.d.ts.map +1 -1
- package/build/manager/plugins/basic-ed25519.js +5 -0
- package/build/manager/plugins/basic-ed25519.js.map +1 -1
- package/build/manager/plugins/exports.d.ts +3 -0
- package/build/manager/plugins/exports.d.ts.map +1 -1
- package/build/manager/plugins/exports.js +2 -0
- package/build/manager/plugins/exports.js.map +1 -1
- package/build/manager/plugins/index.d.ts +2 -5
- package/build/manager/plugins/index.d.ts.map +1 -1
- package/build/manager/plugins/index.js +9 -1
- package/build/manager/plugins/index.js.map +1 -1
- package/build/manager/plugins/methods.d.ts +6 -0
- package/build/manager/plugins/methods.d.ts.map +1 -0
- package/build/manager/plugins/methods.js +65 -0
- package/build/manager/plugins/methods.js.map +1 -0
- package/build/manager/plugins/re-captcha.d.ts.map +1 -1
- package/build/manager/plugins/re-captcha.js +5 -0
- package/build/manager/plugins/re-captcha.js.map +1 -1
- package/build/manager/plugins/registry/types.d.ts +10 -0
- package/build/manager/plugins/registry/types.d.ts.map +1 -0
- package/build/manager/plugins/registry/types.js +2 -0
- package/build/manager/plugins/registry/types.js.map +1 -0
- package/build/manager/plugins/registry.d.ts +20 -0
- package/build/manager/plugins/registry.d.ts.map +1 -0
- package/build/manager/plugins/registry.js +23 -0
- package/build/manager/plugins/registry.js.map +1 -0
- package/build/manager/plugins/tunnel-consumer.d.ts.map +1 -1
- package/build/manager/plugins/tunnel-consumer.js +10 -3
- package/build/manager/plugins/tunnel-consumer.js.map +1 -1
- package/build/manager/plugins/types.d.ts +53 -0
- package/build/manager/plugins/types.d.ts.map +1 -1
- package/build/service.js +1 -1
- package/build/service.js.map +1 -1
- package/package.json +39 -29
- package/src/components/dispatcher/component.tsx +37 -14
- package/src/components/dispatcher/types.local.ts +7 -0
- package/src/entrypoints.ts +10 -0
- package/src/helper.ts +31 -5
- package/src/index.ts +1 -1
- package/src/login/adopt/types.ts +25 -0
- package/src/login/adopt.ts +26 -0
- package/src/login/consts.local.ts +34 -0
- package/src/login/consts.ts +124 -0
- package/src/login/credit/types.ts +6 -0
- package/src/login/credit.ts +69 -0
- package/src/login/env/types.ts +35 -0
- package/src/login/env.ts +74 -0
- package/src/login/flow.ts +44 -0
- package/src/login/hook.ts +99 -0
- package/src/login/i18n/be.json +41 -0
- package/src/login/i18n/de.json +41 -0
- package/src/login/i18n/en.json +41 -0
- package/src/login/i18n/es.json +41 -0
- package/src/login/i18n/fr.json +41 -0
- package/src/login/i18n/pl.json +41 -0
- package/src/login/i18n/ru.json +41 -0
- package/src/login/i18n/uk.json +41 -0
- package/src/login/i18n.ts +29 -0
- package/src/login/index.ts +27 -0
- package/src/login/land/types.ts +54 -0
- package/src/login/land.ts +149 -0
- package/src/login/methods/types.ts +32 -0
- package/src/login/methods.ts +109 -0
- package/src/login/resume/types.ts +24 -0
- package/src/login/resume.ts +45 -0
- package/src/login/screen.tsx +140 -0
- package/src/login/service.ts +271 -0
- package/src/login/start/types.ts +30 -0
- package/src/login/start.ts +44 -0
- package/src/login/surrogate/types.ts +9 -0
- package/src/login/surrogate.ts +37 -0
- package/src/login/terms/types.ts +126 -0
- package/src/login/terms-config.ts +55 -0
- package/src/login/terms.ts +315 -0
- package/src/login/types.ts +335 -0
- package/src/manager/README.md +37 -80
- package/src/manager/components/authentication/control.ts +3 -3
- package/src/manager/components/authentication/types.ts +2 -2
- package/src/manager/components/tunnel-consumer.tsx +2 -2
- package/src/manager/entrypoints.ts +18 -0
- package/src/manager/plugins/basic-ed25519.tsx +7 -0
- package/src/manager/plugins/exports.ts +3 -0
- package/src/manager/plugins/index.ts +11 -4
- package/src/manager/plugins/methods.ts +74 -0
- package/src/manager/plugins/re-captcha.tsx +7 -0
- package/src/manager/plugins/registry/types.ts +10 -0
- package/src/manager/plugins/registry.ts +33 -0
- package/src/manager/plugins/tunnel-consumer.tsx +12 -3
- package/src/manager/plugins/types.ts +54 -0
- package/src/service.ts +1 -1
- package/tests/context.ts +1 -2
- package/tests/i18n.spec.ts +68 -0
- package/tests/land.spec.ts +292 -0
- package/tests/login.spec.ts +332 -0
- package/tests/target.spec.ts +210 -0
- package/tests/terms-deferred.spec.ts +65 -0
- package/tests/terms.spec.ts +314 -0
- package/build/.gitkeep +0 -0
- package/build/manager/modules.d.ts +0 -2
- package/build/manager/modules.d.ts.map +0 -1
- package/build/manager/modules.js +0 -16
- package/build/manager/modules.js.map +0 -1
- package/build/modules.d.ts +0 -4
- package/build/modules.d.ts.map +0 -1
- package/build/modules.js +0 -9
- package/build/modules.js.map +0 -1
- package/src/manager/modules.ts +0 -18
- package/src/modules.ts +0 -13
|
@@ -0,0 +1,41 @@
|
|
|
1
|
+
{
|
|
2
|
+
"login": {
|
|
3
|
+
"title": "Connexion",
|
|
4
|
+
"subtitle": "Choisissez comment continuer.",
|
|
5
|
+
"busy": "Ouverture de la connexion…",
|
|
6
|
+
"empty": "Aucune méthode de connexion n’est configurée pour cette application.",
|
|
7
|
+
"method": {
|
|
8
|
+
"google": "Continuer avec Google",
|
|
9
|
+
"oidc": "Continuer avec {{provider}}",
|
|
10
|
+
"oidc-default": "Connexion / Inscription",
|
|
11
|
+
"oidc-client": "Continuer avec {{provider}}",
|
|
12
|
+
"basic-ed25519": "Se connecter avec une clé",
|
|
13
|
+
"pk-supervisor": "Clé secrète (opérateur)",
|
|
14
|
+
"wallet-consumer": "Portefeuille d’identité OwlMeans",
|
|
15
|
+
"one-time-token": "Se connecter avec un code e-mail",
|
|
16
|
+
"fallback": "Continuer avec {{method}}"
|
|
17
|
+
},
|
|
18
|
+
"terms": {
|
|
19
|
+
"accept": "J’ai lu et j’accepte {{documents}}.",
|
|
20
|
+
"terms": "conditions générales",
|
|
21
|
+
"privacy": "politique de confidentialité",
|
|
22
|
+
"cookies": "Politique relative aux cookies",
|
|
23
|
+
"billing": "Conditions de facturation",
|
|
24
|
+
"product": "Conditions du produit {{product}}",
|
|
25
|
+
"notice": "Comment nous traitons vos données personnelles : {{notices}}.",
|
|
26
|
+
"revised": "Dernière mise à jour : {{date}}",
|
|
27
|
+
"required": "Confirmez {{documents}} pour continuer."
|
|
28
|
+
},
|
|
29
|
+
"consent": {
|
|
30
|
+
"required": "La connexion enregistre un cookie de session. Acceptez les cookies essentiels pour continuer."
|
|
31
|
+
},
|
|
32
|
+
"credit": {
|
|
33
|
+
"powered": "Propulsé par OwlMeans"
|
|
34
|
+
},
|
|
35
|
+
"error": {
|
|
36
|
+
"failed": "La connexion n’a pas abouti. Réessayez.",
|
|
37
|
+
"blocked": "La fenêtre de connexion a été bloquée. Cliquez sur l’icône de fenêtre contextuelle bloquée dans la barre d’adresse pour l’ouvrir."
|
|
38
|
+
},
|
|
39
|
+
"orphaned": "Vous êtes connecté. Vous pouvez fermer cette fenêtre et continuer dans l’application."
|
|
40
|
+
}
|
|
41
|
+
}
|
|
@@ -0,0 +1,41 @@
|
|
|
1
|
+
{
|
|
2
|
+
"login": {
|
|
3
|
+
"title": "Zaloguj się",
|
|
4
|
+
"subtitle": "Wybierz sposób, w jaki chcesz kontynuować.",
|
|
5
|
+
"busy": "Otwieranie logowania…",
|
|
6
|
+
"empty": "Dla tej aplikacji nie skonfigurowano żadnej metody logowania.",
|
|
7
|
+
"method": {
|
|
8
|
+
"google": "Kontynuuj z Google",
|
|
9
|
+
"oidc": "Kontynuuj z {{provider}}",
|
|
10
|
+
"oidc-default": "Zaloguj się / Zarejestruj się",
|
|
11
|
+
"oidc-client": "Kontynuuj z {{provider}}",
|
|
12
|
+
"basic-ed25519": "Zaloguj się kluczem",
|
|
13
|
+
"pk-supervisor": "Klucz tajny (operator)",
|
|
14
|
+
"wallet-consumer": "Portfel OwlMeans ID",
|
|
15
|
+
"one-time-token": "Zaloguj się kodem e-mail",
|
|
16
|
+
"fallback": "Kontynuuj z {{method}}"
|
|
17
|
+
},
|
|
18
|
+
"terms": {
|
|
19
|
+
"accept": "Przeczytałem(-am) i akceptuję {{documents}}.",
|
|
20
|
+
"terms": "Regulamin",
|
|
21
|
+
"privacy": "Politykę prywatności",
|
|
22
|
+
"cookies": "Politykę plików cookie",
|
|
23
|
+
"billing": "Warunki rozliczeń",
|
|
24
|
+
"product": "Warunki produktu {{product}}",
|
|
25
|
+
"notice": "Jak przetwarzamy Twoje dane osobowe: {{notices}}.",
|
|
26
|
+
"revised": "Ostatnia aktualizacja: {{date}}",
|
|
27
|
+
"required": "Aby kontynuować, potwierdź {{documents}}."
|
|
28
|
+
},
|
|
29
|
+
"consent": {
|
|
30
|
+
"required": "Logowanie zapisuje plik cookie sesji. Zaakceptuj niezbędne pliki cookie, aby kontynuować."
|
|
31
|
+
},
|
|
32
|
+
"credit": {
|
|
33
|
+
"powered": "Napędzane przez OwlMeans"
|
|
34
|
+
},
|
|
35
|
+
"error": {
|
|
36
|
+
"failed": "Logowanie nie zostało ukończone. Spróbuj ponownie.",
|
|
37
|
+
"blocked": "Okno logowania zostało zablokowane. Kliknij ikonę zablokowanego okienka w pasku adresu przeglądarki, aby je otworzyć."
|
|
38
|
+
},
|
|
39
|
+
"orphaned": "Zalogowano. Możesz zamknąć to okno i kontynuować w aplikacji."
|
|
40
|
+
}
|
|
41
|
+
}
|
|
@@ -0,0 +1,41 @@
|
|
|
1
|
+
{
|
|
2
|
+
"login": {
|
|
3
|
+
"title": "Вход",
|
|
4
|
+
"subtitle": "Выберите способ входа.",
|
|
5
|
+
"busy": "Открываем окно входа…",
|
|
6
|
+
"empty": "Для этого приложения не настроен ни один способ входа.",
|
|
7
|
+
"method": {
|
|
8
|
+
"google": "Продолжить с Google",
|
|
9
|
+
"oidc": "Продолжить с {{provider}}",
|
|
10
|
+
"oidc-default": "Войти / Зарегистрироваться",
|
|
11
|
+
"oidc-client": "Продолжить с {{provider}}",
|
|
12
|
+
"basic-ed25519": "Войти с ключом",
|
|
13
|
+
"pk-supervisor": "Секретный ключ (оператор)",
|
|
14
|
+
"wallet-consumer": "Кошелёк OwlMeans ID",
|
|
15
|
+
"one-time-token": "Войти по коду из письма",
|
|
16
|
+
"fallback": "Продолжить с {{method}}"
|
|
17
|
+
},
|
|
18
|
+
"terms": {
|
|
19
|
+
"accept": "Я прочитал(а) и принимаю {{documents}}.",
|
|
20
|
+
"terms": "Условия использования",
|
|
21
|
+
"privacy": "Политику конфиденциальности",
|
|
22
|
+
"cookies": "Политику файлов cookie",
|
|
23
|
+
"billing": "Условия оплаты",
|
|
24
|
+
"product": "Условия использования продукта {{product}}",
|
|
25
|
+
"notice": "Как мы обрабатываем ваши персональные данные: {{notices}}.",
|
|
26
|
+
"revised": "Последнее обновление: {{date}}",
|
|
27
|
+
"required": "Чтобы продолжить, подтвердите {{documents}}."
|
|
28
|
+
},
|
|
29
|
+
"consent": {
|
|
30
|
+
"required": "Вход сохраняет сессионный файл cookie. Примите необходимые файлы cookie, чтобы продолжить."
|
|
31
|
+
},
|
|
32
|
+
"credit": {
|
|
33
|
+
"powered": "Работает на OwlMeans"
|
|
34
|
+
},
|
|
35
|
+
"error": {
|
|
36
|
+
"failed": "Вход не завершён. Попробуйте ещё раз.",
|
|
37
|
+
"blocked": "Окно входа заблокировано. Нажмите на значок заблокированного всплывающего окна в адресной строке браузера, чтобы открыть его."
|
|
38
|
+
},
|
|
39
|
+
"orphaned": "Вход выполнен. Можете закрыть это окно и вернуться в приложение."
|
|
40
|
+
}
|
|
41
|
+
}
|
|
@@ -0,0 +1,41 @@
|
|
|
1
|
+
{
|
|
2
|
+
"login": {
|
|
3
|
+
"title": "Вхід",
|
|
4
|
+
"subtitle": "Оберіть спосіб входу.",
|
|
5
|
+
"busy": "Відкриваємо вікно входу…",
|
|
6
|
+
"empty": "Для цього застосунку не налаштовано жодного способу входу.",
|
|
7
|
+
"method": {
|
|
8
|
+
"google": "Продовжити з Google",
|
|
9
|
+
"oidc": "Продовжити з {{provider}}",
|
|
10
|
+
"oidc-default": "Увійти / Зареєструватися",
|
|
11
|
+
"oidc-client": "Продовжити з {{provider}}",
|
|
12
|
+
"basic-ed25519": "Увійти з ключем",
|
|
13
|
+
"pk-supervisor": "Секретний ключ (оператор)",
|
|
14
|
+
"wallet-consumer": "Гаманець OwlMeans ID",
|
|
15
|
+
"one-time-token": "Увійти за кодом з листа",
|
|
16
|
+
"fallback": "Продовжити з {{method}}"
|
|
17
|
+
},
|
|
18
|
+
"terms": {
|
|
19
|
+
"accept": "Я прочитав(-ла) і приймаю {{documents}}.",
|
|
20
|
+
"terms": "Умови користування",
|
|
21
|
+
"privacy": "Політику конфіденційності",
|
|
22
|
+
"cookies": "Політику файлів cookie",
|
|
23
|
+
"billing": "Умови оплати",
|
|
24
|
+
"product": "Умови продукту {{product}}",
|
|
25
|
+
"notice": "Як ми обробляємо ваші персональні дані: {{notices}}.",
|
|
26
|
+
"revised": "Востаннє оновлено: {{date}}",
|
|
27
|
+
"required": "Щоб продовжити, підтвердьте {{documents}}."
|
|
28
|
+
},
|
|
29
|
+
"consent": {
|
|
30
|
+
"required": "Вхід зберігає сеансовий файл cookie. Прийміть необхідні файли cookie, щоб продовжити."
|
|
31
|
+
},
|
|
32
|
+
"credit": {
|
|
33
|
+
"powered": "Працює на OwlMeans"
|
|
34
|
+
},
|
|
35
|
+
"error": {
|
|
36
|
+
"failed": "Вхід не завершено. Спробуйте ще раз.",
|
|
37
|
+
"blocked": "Вікно входу заблоковано. Натисніть значок заблокованого спливаючого вікна в адресному рядку браузера, щоб відкрити його."
|
|
38
|
+
},
|
|
39
|
+
"orphaned": "Вхід виконано. Можете закрити це вікно й повернутися до застосунку."
|
|
40
|
+
}
|
|
41
|
+
}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"i18n.d.ts","sourceRoot":"","sources":["../../src/login/i18n.ts"],"names":[],"mappings":""}
|
|
@@ -0,0 +1,27 @@
|
|
|
1
|
+
import en from './i18n/en.json' with { type: 'json' };
|
|
2
|
+
import pl from './i18n/pl.json' with { type: 'json' };
|
|
3
|
+
import ru from './i18n/ru.json' with { type: 'json' };
|
|
4
|
+
import be from './i18n/be.json' with { type: 'json' };
|
|
5
|
+
import uk from './i18n/uk.json' with { type: 'json' };
|
|
6
|
+
import es from './i18n/es.json' with { type: 'json' };
|
|
7
|
+
import de from './i18n/de.json' with { type: 'json' };
|
|
8
|
+
import fr from './i18n/fr.json' with { type: 'json' };
|
|
9
|
+
import { i18nHelper } from '@owlmeans/i18n';
|
|
10
|
+
/**
|
|
11
|
+
* The sign-in screen's copy, registered into the `auth` library resource.
|
|
12
|
+
*
|
|
13
|
+
* `_addI18n` PUSHES rather than replaces, so this coexists with `@owlmeans/web-client`'s own
|
|
14
|
+
* `auth` registration (which owns `dispatcher.*` and `surrogate.*`) and the two merge by tier and
|
|
15
|
+
* priority. Registering here rather than in a UI package is what lets the plain fallback screen
|
|
16
|
+
* and every styled one read the same keys — so the seven-language rule holds on every path a user
|
|
17
|
+
* can actually reach, not only the pretty one.
|
|
18
|
+
*/
|
|
19
|
+
i18nHelper.addI18nLib('en', 'auth', en);
|
|
20
|
+
i18nHelper.addI18nLib('pl', 'auth', pl);
|
|
21
|
+
i18nHelper.addI18nLib('ru', 'auth', ru);
|
|
22
|
+
i18nHelper.addI18nLib('be', 'auth', be);
|
|
23
|
+
i18nHelper.addI18nLib('uk', 'auth', uk);
|
|
24
|
+
i18nHelper.addI18nLib('es', 'auth', es);
|
|
25
|
+
i18nHelper.addI18nLib('de', 'auth', de);
|
|
26
|
+
i18nHelper.addI18nLib('fr', 'auth', fr);
|
|
27
|
+
//# sourceMappingURL=i18n.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"i18n.js","sourceRoot":"","sources":["../../src/login/i18n.ts"],"names":[],"mappings":"AAEA,OAAO,EAAE,MAAM,gBAAgB,CAAC,OAAO,IAAI,EAAE,MAAM,EAAE,CAAA;AACrD,OAAO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js';
|
|
3
|
+
export * from './types.js';
|
|
4
|
+
export type * from './env/types.js';
|
|
5
|
+
export type * from './adopt/types.js';
|
|
6
|
+
export type * from './methods/types.js';
|
|
7
|
+
export type * from './resume/types.js';
|
|
8
|
+
export type * from './terms/types.js';
|
|
9
|
+
export type * from './credit/types.js';
|
|
10
|
+
export type * from './surrogate/types.js';
|
|
11
|
+
export type * from './land/types.js';
|
|
12
|
+
export type * from './start/types.js';
|
|
13
|
+
export * from './env.js';
|
|
14
|
+
export * from './adopt.js';
|
|
15
|
+
export * from './methods.js';
|
|
16
|
+
export * from './flow.js';
|
|
17
|
+
export * from './resume.js';
|
|
18
|
+
export * from './terms-config.js';
|
|
19
|
+
export * from './terms.js';
|
|
20
|
+
export * from './credit.js';
|
|
21
|
+
export * from './surrogate.js';
|
|
22
|
+
export * from './screen.js';
|
|
23
|
+
export * from './service.js';
|
|
24
|
+
export * from './start.js';
|
|
25
|
+
export * from './hook.js';
|
|
26
|
+
export * from './land.js';
|
|
27
|
+
//# sourceMappingURL=index.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../src/login/index.ts"],"names":[],"mappings":"AAAA,OAAO,WAAW,CAAA;AAElB,cAAc,aAAa,CAAA;AAC3B,cAAc,YAAY,CAAA;AAC1B,mBAAmB,gBAAgB,CAAA;AACnC,mBAAmB,kBAAkB,CAAA;AACrC,mBAAmB,oBAAoB,CAAA;AACvC,mBAAmB,mBAAmB,CAAA;AACtC,mBAAmB,kBAAkB,CAAA;AACrC,mBAAmB,mBAAmB,CAAA;AACtC,mBAAmB,sBAAsB,CAAA;AACzC,mBAAmB,iBAAiB,CAAA;AACpC,mBAAmB,kBAAkB,CAAA;AACrC,cAAc,UAAU,CAAA;AACxB,cAAc,YAAY,CAAA;AAC1B,cAAc,cAAc,CAAA;AAC5B,cAAc,WAAW,CAAA;AACzB,cAAc,aAAa,CAAA;AAC3B,cAAc,mBAAmB,CAAA;AACjC,cAAc,YAAY,CAAA;AAC1B,cAAc,aAAa,CAAA;AAC3B,cAAc,gBAAgB,CAAA;AAC9B,cAAc,aAAa,CAAA;AAC3B,cAAc,cAAc,CAAA;AAC5B,cAAc,YAAY,CAAA;AAC1B,cAAc,WAAW,CAAA;AACzB,cAAc,WAAW,CAAA"}
|
|
@@ -0,0 +1,18 @@
|
|
|
1
|
+
import './i18n.js';
|
|
2
|
+
export * from './consts.js';
|
|
3
|
+
export * from './types.js';
|
|
4
|
+
export * from './env.js';
|
|
5
|
+
export * from './adopt.js';
|
|
6
|
+
export * from './methods.js';
|
|
7
|
+
export * from './flow.js';
|
|
8
|
+
export * from './resume.js';
|
|
9
|
+
export * from './terms-config.js';
|
|
10
|
+
export * from './terms.js';
|
|
11
|
+
export * from './credit.js';
|
|
12
|
+
export * from './surrogate.js';
|
|
13
|
+
export * from './screen.js';
|
|
14
|
+
export * from './service.js';
|
|
15
|
+
export * from './start.js';
|
|
16
|
+
export * from './hook.js';
|
|
17
|
+
export * from './land.js';
|
|
18
|
+
//# sourceMappingURL=index.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../src/login/index.ts"],"names":[],"mappings":"AAAA,OAAO,WAAW,CAAA;AAElB,cAAc,aAAa,CAAA;AAC3B,cAAc,YAAY,CAAA;AAU1B,cAAc,UAAU,CAAA;AACxB,cAAc,YAAY,CAAA;AAC1B,cAAc,cAAc,CAAA;AAC5B,cAAc,WAAW,CAAA;AACzB,cAAc,aAAa,CAAA;AAC3B,cAAc,mBAAmB,CAAA;AACjC,cAAc,YAAY,CAAA;AAC1B,cAAc,aAAa,CAAA;AAC3B,cAAc,gBAAgB,CAAA;AAC9B,cAAc,aAAa,CAAA;AAC3B,cAAc,cAAc,CAAA;AAC5B,cAAc,YAAY,CAAA;AAC1B,cAAc,WAAW,CAAA;AACzB,cAAc,WAAW,CAAA"}
|
|
@@ -0,0 +1,52 @@
|
|
|
1
|
+
import type { LoginLandingParams } from '../types.js';
|
|
2
|
+
/** Where a finished sign-in (or a pending step) lands. */
|
|
3
|
+
export interface LoginLanding {
|
|
4
|
+
alias: string;
|
|
5
|
+
params?: LoginLandingParams;
|
|
6
|
+
query?: LoginLandingParams;
|
|
7
|
+
/** The step alias this landing came from, when it came from one. */
|
|
8
|
+
step?: string;
|
|
9
|
+
}
|
|
10
|
+
/** Options for {@link LoginService.landAfterLogin}-shaped helpers (./land.js). */
|
|
11
|
+
export interface LandOptions {
|
|
12
|
+
/** Where to land when nothing else claims the flow. Defaults to `{ alias: HOME }`. */
|
|
13
|
+
fallback?: LoginLanding;
|
|
14
|
+
/** `false` skips `resumeSuspendedFlow` — the caller already has its own concrete destination. */
|
|
15
|
+
resume?: boolean;
|
|
16
|
+
/** Skip every step up to and including this alias — the resume point for a step's re-entry. */
|
|
17
|
+
after?: string;
|
|
18
|
+
/**
|
|
19
|
+
* Overrides the step/hook timeout for this call. Mainly for tests; production callers leave it
|
|
20
|
+
* at the default (`LOGIN_STEP_TIMEOUT`).
|
|
21
|
+
*/
|
|
22
|
+
stepTimeout?: number;
|
|
23
|
+
}
|
|
24
|
+
/** Where one context's finished sign-in goes: its pending steps, a suspended flow, or the fallback. */
|
|
25
|
+
export interface LoginLandingHelper {
|
|
26
|
+
/**
|
|
27
|
+
* Where a finished sign-in should go: the first pending step, else a suspended flow, else the
|
|
28
|
+
* fallback (ordinarily `HOME`).
|
|
29
|
+
*
|
|
30
|
+
* Re-checks `env().surrogate` even though {@link landAfterLogin} already did — this function is
|
|
31
|
+
* also called directly (e.g. from `useContinueLogin`, after the surrogate window has already
|
|
32
|
+
* closed), and the check is cheap insurance either way: **no step and no landing hook ever runs
|
|
33
|
+
* inside the surrogate popup.** It has nothing of its own to collect and nowhere to navigate —
|
|
34
|
+
* the popup's own `DispatcherHOC` has no `navigate() → HOME` at all.
|
|
35
|
+
*/
|
|
36
|
+
continueLogin: (opts?: LandOptions) => Promise<LoginLanding>;
|
|
37
|
+
/**
|
|
38
|
+
* The whole post-sign-in landing decision: run any due landing hooks for a freshly seen token,
|
|
39
|
+
* then delegate to {@link continueLogin} for where the flow actually goes.
|
|
40
|
+
*
|
|
41
|
+
* This is what a plugin that just adopted a token calls in place of the old inline
|
|
42
|
+
* "`resumeSuspendedFlow` else `HOME`" — `DispatcherHOC`, the supervisor plugin and both Google
|
|
43
|
+
* plugins all replace their own copy of that logic with this one.
|
|
44
|
+
*/
|
|
45
|
+
landAfterLogin: (opts?: LandOptions) => Promise<LoginLanding>;
|
|
46
|
+
/**
|
|
47
|
+
* The absolute URL a landing resolves to — the same shape the supervisor and Google plugins
|
|
48
|
+
* already build their own `window.location.href` from.
|
|
49
|
+
*/
|
|
50
|
+
landingUrl: (landing: LoginLanding) => Promise<string>;
|
|
51
|
+
}
|
|
52
|
+
//# sourceMappingURL=types.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"types.d.ts","sourceRoot":"","sources":["../../../src/login/land/types.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,kBAAkB,EAAE,MAAM,aAAa,CAAA;AAErD,0DAA0D;AAC1D,MAAM,WAAW,YAAY;IAC3B,KAAK,EAAE,MAAM,CAAA;IACb,MAAM,CAAC,EAAE,kBAAkB,CAAA;IAC3B,KAAK,CAAC,EAAE,kBAAkB,CAAA;IAC1B,oEAAoE;IACpE,IAAI,CAAC,EAAE,MAAM,CAAA;CACd;AAED,kFAAkF;AAClF,MAAM,WAAW,WAAW;IAC1B,sFAAsF;IACtF,QAAQ,CAAC,EAAE,YAAY,CAAA;IACvB,iGAAiG;IACjG,MAAM,CAAC,EAAE,OAAO,CAAA;IAChB,+FAA+F;IAC/F,KAAK,CAAC,EAAE,MAAM,CAAA;IACd;;;OAGG;IACH,WAAW,CAAC,EAAE,MAAM,CAAA;CACrB;AAED,uGAAuG;AACvG,MAAM,WAAW,kBAAkB;IACjC;;;;;;;;;OASG;IACH,aAAa,EAAE,CAAC,IAAI,CAAC,EAAE,WAAW,KAAK,OAAO,CAAC,YAAY,CAAC,CAAA;IAC5D;;;;;;;OAOG;IACH,cAAc,EAAE,CAAC,IAAI,CAAC,EAAE,WAAW,KAAK,OAAO,CAAC,YAAY,CAAC,CAAA;IAC7D;;;OAGG;IACH,UAAU,EAAE,CAAC,OAAO,EAAE,YAAY,KAAK,OAAO,CAAC,MAAM,CAAC,CAAA;CACvD"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"types.js","sourceRoot":"","sources":["../../../src/login/land/types.ts"],"names":[],"mappings":""}
|
|
@@ -0,0 +1,6 @@
|
|
|
1
|
+
import type { LoginContext } from './types.js';
|
|
2
|
+
import type { LoginLandingHelper } from './land/types.js';
|
|
3
|
+
export declare const makeLoginLandingHelper: (ctx: LoginContext) => LoginLandingHelper;
|
|
4
|
+
/** The landing helper of a context — one per context. */
|
|
5
|
+
export declare const loginLandingOf: (target: LoginContext) => LoginLandingHelper;
|
|
6
|
+
//# sourceMappingURL=land.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"land.d.ts","sourceRoot":"","sources":["../../src/login/land.ts"],"names":[],"mappings":"AAOA,OAAO,KAAK,EAAE,YAAY,EAAgB,MAAM,YAAY,CAAA;AAC5D,OAAO,KAAK,EAA6B,kBAAkB,EAAE,MAAM,iBAAiB,CAAA;AA6BpF,eAAO,MAAM,sBAAsB,QAAS,YAAY,KAAG,kBA4G1D,CAAA;AAED,yDAAyD;AACzD,eAAO,MAAM,cAAc,8CAA6C,CAAA"}
|
|
@@ -0,0 +1,122 @@
|
|
|
1
|
+
import { DISPATCHER } from '@owlmeans/auth';
|
|
2
|
+
import { HOME, memoHelper } from '@owlmeans/context';
|
|
3
|
+
import { DEFAULT_ALIAS as AUTH_ALIAS } from '../consts.js';
|
|
4
|
+
import { ensureLoginService } from './service.js';
|
|
5
|
+
import { LOGIN_LANDED_STORAGE, LOGIN_STEP_TIMEOUT } from './consts.js';
|
|
6
|
+
import { flowLandingOf } from '@owlmeans/client-flow';
|
|
7
|
+
/**
|
|
8
|
+
* Race a promise against a bound, resolving to `onTimeout` (never rejecting) if the bound wins.
|
|
9
|
+
*
|
|
10
|
+
* A synchronous throw from the wrapped call is turned into a rejection by the caller before this
|
|
11
|
+
* ever sees it, so the only two outcomes here are "settled in time" and "timed out". `onTimeout`
|
|
12
|
+
* defaults to `undefined` — every existing caller that omits it keeps its old fail-open meaning;
|
|
13
|
+
* `continueLogin` passes a step's own `required` flag through it so a step that hangs is read the
|
|
14
|
+
* same way as one that throws.
|
|
15
|
+
*/
|
|
16
|
+
const withTimeout = async (promise, ms, onTimeout) => {
|
|
17
|
+
let timer;
|
|
18
|
+
try {
|
|
19
|
+
return await Promise.race([
|
|
20
|
+
promise,
|
|
21
|
+
new Promise(resolve => { timer = setTimeout(() => resolve(onTimeout), ms); }),
|
|
22
|
+
]);
|
|
23
|
+
}
|
|
24
|
+
finally {
|
|
25
|
+
if (timer != null) {
|
|
26
|
+
clearTimeout(timer);
|
|
27
|
+
}
|
|
28
|
+
}
|
|
29
|
+
};
|
|
30
|
+
export const makeLoginLandingHelper = (ctx) => {
|
|
31
|
+
/**
|
|
32
|
+
* Run every registered landing hook, once per distinct token.
|
|
33
|
+
*
|
|
34
|
+
* The stored token is overwritten BEFORE the hooks run, not after: a hook that throws or hangs
|
|
35
|
+
* must never make the same token re-run the whole set on the next call, since surviving exactly
|
|
36
|
+
* that is what the bound-and-swallow contract is for. The raw token string is the marker rather
|
|
37
|
+
* than a digest of it — it never leaves the browser, and this package already keeps the terms
|
|
38
|
+
* acceptance marker the same way (`LOGIN_TERMS_STORAGE`).
|
|
39
|
+
*/
|
|
40
|
+
const runLandingHooks = async (login, timeout) => {
|
|
41
|
+
const auth = ctx.service(AUTH_ALIAS);
|
|
42
|
+
const token = await auth.authenticated();
|
|
43
|
+
if (token == null) {
|
|
44
|
+
return;
|
|
45
|
+
}
|
|
46
|
+
let last = null;
|
|
47
|
+
try {
|
|
48
|
+
last = window.localStorage.getItem(LOGIN_LANDED_STORAGE);
|
|
49
|
+
}
|
|
50
|
+
catch {
|
|
51
|
+
// Storage can be unavailable (private modes, blocked cookies). Treated as "never landed",
|
|
52
|
+
// which just re-runs the hooks — the safe direction, same as the terms-acceptance marker.
|
|
53
|
+
}
|
|
54
|
+
if (last === token) {
|
|
55
|
+
return;
|
|
56
|
+
}
|
|
57
|
+
try {
|
|
58
|
+
window.localStorage.setItem(LOGIN_LANDED_STORAGE, token);
|
|
59
|
+
}
|
|
60
|
+
catch { /* nothing to remember if storage was never available */ }
|
|
61
|
+
for (const hook of login.landingHooks()) {
|
|
62
|
+
await withTimeout(Promise.resolve().then(() => hook.landed(ctx)), timeout).catch(() => undefined);
|
|
63
|
+
}
|
|
64
|
+
};
|
|
65
|
+
const continueLogin = async (opts) => {
|
|
66
|
+
const login = ensureLoginService(ctx);
|
|
67
|
+
if (login.env().surrogate) {
|
|
68
|
+
return { alias: DISPATCHER };
|
|
69
|
+
}
|
|
70
|
+
const timeout = opts?.stepTimeout ?? LOGIN_STEP_TIMEOUT;
|
|
71
|
+
const auth = ctx.service(AUTH_ALIAS);
|
|
72
|
+
const token = await auth.authenticated();
|
|
73
|
+
if (token != null) {
|
|
74
|
+
const steps = login.steps();
|
|
75
|
+
let start = 0;
|
|
76
|
+
if (opts?.after != null) {
|
|
77
|
+
const index = steps.findIndex(step => step.alias === opts.after);
|
|
78
|
+
if (index >= 0) {
|
|
79
|
+
start = index + 1;
|
|
80
|
+
}
|
|
81
|
+
}
|
|
82
|
+
for (let i = start; i < steps.length; i++) {
|
|
83
|
+
const step = steps[i];
|
|
84
|
+
// Registration proves only that some module reached the bundle — the step's own screen may
|
|
85
|
+
// not be bound in this tree (an older target, a partial import). Skipped, never thrown.
|
|
86
|
+
if (!ctx.hasEntrypoint(step.entrypoint)) {
|
|
87
|
+
continue;
|
|
88
|
+
}
|
|
89
|
+
// A step that throws or hangs fails OPEN ("not pending") by default — UNLESS it declared
|
|
90
|
+
// itself `required`, in which case a broken read must show the step rather than let the
|
|
91
|
+
// person through it unconfirmed (a Terms box moved here from the sign-in screen).
|
|
92
|
+
const onBroken = step.required === true;
|
|
93
|
+
const pending = await withTimeout(Promise.resolve().then(() => step.pending(ctx)), timeout, onBroken).catch(() => onBroken);
|
|
94
|
+
if (pending === true) {
|
|
95
|
+
return { alias: step.entrypoint, query: await step.query?.(ctx), step: step.alias };
|
|
96
|
+
}
|
|
97
|
+
}
|
|
98
|
+
}
|
|
99
|
+
if (opts?.resume !== false) {
|
|
100
|
+
const landing = await flowLandingOf(ctx).resumeSuspendedFlow();
|
|
101
|
+
if (landing != null) {
|
|
102
|
+
return { alias: landing.entrypoint, query: landing.query };
|
|
103
|
+
}
|
|
104
|
+
}
|
|
105
|
+
return opts?.fallback ?? { alias: HOME };
|
|
106
|
+
};
|
|
107
|
+
const landAfterLogin = async (opts) => {
|
|
108
|
+
const login = ensureLoginService(ctx);
|
|
109
|
+
// Never run a step or a landing hook while THIS document is the surrogate popup — see the note
|
|
110
|
+
// on `continueLogin`.
|
|
111
|
+
if (login.env().surrogate) {
|
|
112
|
+
return { alias: DISPATCHER };
|
|
113
|
+
}
|
|
114
|
+
await runLandingHooks(login, opts?.stepTimeout ?? LOGIN_STEP_TIMEOUT);
|
|
115
|
+
return continueLogin(opts);
|
|
116
|
+
};
|
|
117
|
+
const landingUrl = async (landing) => await ctx.entrypoint(landing.alias).url({ params: landing.params, query: landing.query }, { absolute: true });
|
|
118
|
+
return { continueLogin, landAfterLogin, landingUrl };
|
|
119
|
+
};
|
|
120
|
+
/** The landing helper of a context — one per context. */
|
|
121
|
+
export const loginLandingOf = memoHelper.oncePer(makeLoginLandingHelper);
|
|
122
|
+
//# sourceMappingURL=land.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"land.js","sourceRoot":"","sources":["../../src/login/land.ts"],"names":[],"mappings":"AACA,OAAO,EAAE,UAAU,EAAE,MAAM,g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, LoginMethodContext, LoginMethodSource } from '../types.js';
|
|
3
|
+
/** The sign-in methods on offer: the global source registry and the resolution of a screen's list. */
|
|
4
|
+
export interface LoginMethodsHelper {
|
|
5
|
+
/** Register a source globally — replacing an earlier one of the same alias. */
|
|
6
|
+
registerMethodSource: (source: LoginMethodSource) => void;
|
|
7
|
+
/** The globally registered sources, in registration order. */
|
|
8
|
+
listMethodSources: () => LoginMethodSource[];
|
|
9
|
+
/**
|
|
10
|
+
* Everything the current environment may be offered, in the order it should be offered in.
|
|
11
|
+
*
|
|
12
|
+
* Resolution order matters and is not arbitrary:
|
|
13
|
+
*
|
|
14
|
+
* 1. Sources produce candidates. A source that throws is skipped rather than taking the screen
|
|
15
|
+
* down — a misconfigured provider list must not remove the sign-in method that does work.
|
|
16
|
+
* 2. `restricted` candidates are dropped unless the configuration named them, which is what makes
|
|
17
|
+
* an operator login opt-in rather than merely unadvertised.
|
|
18
|
+
* 3. An explicit `methods` list is both a filter AND the order, because an app that bothered to
|
|
19
|
+
* list them means that list.
|
|
20
|
+
*/
|
|
21
|
+
resolveLoginMethods: (ctx: LoginMethodContext, cfg?: LoginScreenConfig, extra?: LoginMethodSource[]) => LoginMethod[];
|
|
22
|
+
/**
|
|
23
|
+
* The method a screen highlights and focuses.
|
|
24
|
+
*
|
|
25
|
+
* The first `primary` one, else the first offered. It is highlighted, never started: requirement
|
|
26
|
+
* one of this whole feature is that nothing leaves the document without a click.
|
|
27
|
+
*/
|
|
28
|
+
primaryLoginMethod: (methods: LoginMethod[]) => LoginMethod | null;
|
|
29
|
+
}
|
|
30
|
+
//# sourceMappingURL=types.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"types.d.ts","sourceRoot":"","sources":["../../../src/login/methods/types.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,iBAAiB,EAAE,MAAM,kBAAkB,CAAA;AACzD,OAAO,KAAK,EAAE,WAAW,EAAE,kBAAkB,EAAE,iBAAiB,EAAE,MAAM,aAAa,CAAA;AAErF,sGAAsG;AACtG,MAAM,WAAW,kBAAkB;IACjC,+EAA+E;IAC/E,oBAAoB,EAAE,CAAC,MAAM,EAAE,iBAAiB,KAAK,IAAI,CAAA;IACzD,8DAA8D;IAC9D,iBAAiB,EAAE,MAAM,iBAAiB,EAAE,CAAA;IAC5C;;;;;;;;;;;OAWG;IACH,mBAAmB,EAAE,CACnB,GAAG,EAAE,kBAAkB,EAAE,GAAG,CAAC,EAAE,iBAAiB,EAAE,KAAK,CAAC,EAAE,iBAAiB,EAAE,KAC1E,WAAW,EAAE,CAAA;IAClB;;;;;OAKG;IACH,kBAAkB,EAAE,CAAC,OAAO,EAAE,WAAW,EAAE,KAAK,WAAW,GAAG,IAAI,CAAA;CACnE"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"types.js","sourceRoot":"","sources":["../../../src/login/methods/types.ts"],"names":[],"mappings":""}
|
|
@@ -0,0 +1,7 @@
|
|
|
1
|
+
import type { LoginMethod } from './types.js';
|
|
2
|
+
import type { LoginMethodsHelper } from './methods/types.js';
|
|
3
|
+
export declare const createLoginMethodsHelper: () => LoginMethodsHelper;
|
|
4
|
+
export declare const loginMethodsHelper: LoginMethodsHelper;
|
|
5
|
+
/** @deprecated compat:factory-refactor — use `loginMethodsHelper.primaryLoginMethod(…)` */
|
|
6
|
+
export declare const primaryLoginMethod: (methods: LoginMethod[]) => LoginMethod | null;
|
|
7
|
+
//# sourceMappingURL=methods.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"methods.d.ts","sourceRoot":"","sources":["../../src/login/methods.ts"],"names":[],"mappings":"AAEA,OAAO,KAAK,EAAE,WAAW,EAAyC,MAAM,YAAY,CAAA;AACpF,OAAO,KAAK,EAAE,kBAAkB,EAAE,MAAM,oBAAoB,CAAA;AAmB5D,eAAO,MAAM,wBAAwB,QAAO,kBAgF3C,CAAA;AAED,eAAO,MAAM,kBAAkB,oBAA6B,CAAA;AAE5D,2FAA2F;AAC3F,eAAO,MAAM,kBAAkB,YAAa,WAAW,EAAE,KAAG,WAAW,GAAG,IAC1B,CAAA"}
|
|
@@ -0,0 +1,87 @@
|
|
|
1
|
+
import { DEFAULT_METHOD_ORDER } from './consts.js';
|
|
2
|
+
import { logger } from '@owlmeans/log';
|
|
3
|
+
const log = logger('client-auth:login');
|
|
4
|
+
/**
|
|
5
|
+
* The module-global registry of method SOURCES.
|
|
6
|
+
*
|
|
7
|
+
* A source, rather than a method, because the two things that offer sign-in methods answer
|
|
8
|
+
* different questions at different times: the plugin registry knows what code is loaded, and the
|
|
9
|
+
* OIDC configuration knows what an entity is federated with. Both are answered per render — a
|
|
10
|
+
* provider list can arrive from the api-config middleware after the first paint.
|
|
11
|
+
*
|
|
12
|
+
* Global, like the `AuthenticationPlugin` map it mirrors, because a package registers its source
|
|
13
|
+
* from a side-effect import that has no context to hang it on. A context-scoped registry exists
|
|
14
|
+
* alongside it on the login service, and both are merged by `resolveLoginMethods`.
|
|
15
|
+
*/
|
|
16
|
+
const sources = [];
|
|
17
|
+
export const createLoginMethodsHelper = () => {
|
|
18
|
+
const registerMethodSource = (source) => {
|
|
19
|
+
const existing = sources.findIndex(candidate => candidate.alias === source.alias);
|
|
20
|
+
if (existing >= 0) {
|
|
21
|
+
sources.splice(existing, 1);
|
|
22
|
+
}
|
|
23
|
+
sources.push(source);
|
|
24
|
+
};
|
|
25
|
+
const listMethodSources = () => [...sources];
|
|
26
|
+
/** Normalize a config entry, which may be a bare id or a full override object. */
|
|
27
|
+
const asConfig = (entry) => typeof entry === 'string' ? { id: entry } : entry;
|
|
28
|
+
const merge = (method, override) => override == null ? method : {
|
|
29
|
+
...method,
|
|
30
|
+
...(override.label != null ? { label: override.label } : {}),
|
|
31
|
+
...(override.i18nKey != null ? { i18nKey: override.i18nKey } : {}),
|
|
32
|
+
...(override.icon != null ? { icon: override.icon } : {}),
|
|
33
|
+
...(override.order != null ? { order: override.order } : {}),
|
|
34
|
+
...(override.emphasis != null ? { emphasis: override.emphasis } : {}),
|
|
35
|
+
...(override.params != null ? { params: { ...method.params, ...override.params } } : {}),
|
|
36
|
+
};
|
|
37
|
+
const resolveLoginMethods = (ctx, cfg, extra = []) => {
|
|
38
|
+
const candidates = [];
|
|
39
|
+
for (const source of [...sources, ...extra]) {
|
|
40
|
+
try {
|
|
41
|
+
candidates.push(...source.list(ctx));
|
|
42
|
+
}
|
|
43
|
+
catch (e) {
|
|
44
|
+
log.warn('Login method source failed', { source: source.alias, error: e });
|
|
45
|
+
}
|
|
46
|
+
}
|
|
47
|
+
const overrides = cfg?.overrides ?? {};
|
|
48
|
+
const listed = cfg?.methods?.map(asConfig);
|
|
49
|
+
const listedIds = listed?.map(entry => entry.id).filter((id) => id != null);
|
|
50
|
+
const offered = candidates
|
|
51
|
+
.filter(method => {
|
|
52
|
+
const override = overrides[method.id] ?? listed?.find(entry => entry.id === method.id);
|
|
53
|
+
if (override?.enabled === false || override?.hidden === true) {
|
|
54
|
+
return false;
|
|
55
|
+
}
|
|
56
|
+
// A restricted method is offered only where the configuration asked for it — by naming it in
|
|
57
|
+
// `methods`, or by enabling it in `overrides`. Registering the plugin is deliberately not
|
|
58
|
+
// enough: an operator login that appears wherever its code happens to be bundled is an
|
|
59
|
+
// operator login in production.
|
|
60
|
+
if (method.restricted === true
|
|
61
|
+
&& listedIds?.includes(method.id) !== true
|
|
62
|
+
&& override?.enabled !== true) {
|
|
63
|
+
return false;
|
|
64
|
+
}
|
|
65
|
+
return true;
|
|
66
|
+
})
|
|
67
|
+
.map(method => merge(method, overrides[method.id]));
|
|
68
|
+
if (listedIds != null) {
|
|
69
|
+
return listedIds
|
|
70
|
+
.map(id => {
|
|
71
|
+
const method = offered.find(candidate => candidate.id === id);
|
|
72
|
+
return method != null ? merge(method, listed?.find(entry => entry.id === id)) : null;
|
|
73
|
+
})
|
|
74
|
+
.filter((method) => method != null);
|
|
75
|
+
}
|
|
76
|
+
return offered.sort((a, b) => {
|
|
77
|
+
const order = (a.order ?? DEFAULT_METHOD_ORDER) - (b.order ?? DEFAULT_METHOD_ORDER);
|
|
78
|
+
return order !== 0 ? order : a.id.localeCompare(b.id);
|
|
79
|
+
});
|
|
80
|
+
};
|
|
81
|
+
const primaryLoginMethod = (methods) => methods.find(method => method.emphasis === 'primary') ?? methods[0] ?? null;
|
|
82
|
+
return { registerMethodSource, listMethodSources, resolveLoginMethods, primaryLoginMethod };
|
|
83
|
+
};
|
|
84
|
+
export const loginMethodsHelper = createLoginMethodsHelper();
|
|
85
|
+
/** @deprecated compat:factory-refactor — use `loginMethodsHelper.primaryLoginMethod(…)` */
|
|
86
|
+
export const primaryLoginMethod = (methods) => loginMethodsHelper.primaryLoginMethod(methods);
|
|
87
|
+
//# sourceMappingURL=methods.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"methods.js","sourceRoot":"","sources":["../../src/login/methods.ts"],"names":[],"mappings":"AACA,OAAO,EAAE,oBAAoB,EAAE,MAAM,aAAa,CAAA;AAGlD,OAAO,EAAE,MAAM,EAAE,MAAM,eAAe,CAAA;AAEtC,MAAM,GAAG,GAAG,MAAM,CAAC,mBAAmB,CAAC,CAAA;AAEvC;;;;;;;;;;;GAWG;AACH,MAAM,OAAO,GAAwB,EAAE,CAAA;AAEvC,MAAM,CAAC,MAAM,wBAAwB,GAAG,GAAuB,EAAE;IAC/D,MAAM,oBAAoB,GAAG,CAAC,MAAyB,EAAQ,EAAE;QAC/D,MAAM,QAAQ,GAAG,OAAO,CAAC,SAAS,CAAC,SAAS,CAAC,EAAE,CAAC,SAAS,CAAC,KAAK,KAAK,MAAM,CAAC,KAAK,CAAC,CAAA;QACjF,IAAI,QAAQ,IAAI,CAAC,EAAE,CAAC;YAClB,OAAO,CAAC,MAAM,CAAC,QAAQ,EAAE,CAAC,CAAC,CAAA;QAC7B,CAAC;QACD,OAAO,CAAC,IAAI,CAAC,MAAM,CAAC,CAAA;IACtB,CAAC,CAAA;IAED,M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