A platform for community discussion. Free, open, simple.
DEV: Move discourse-login-with-amazon to core (#33570)
Jarek Radosz1cebc0643d59
diff --git a/.github/labeler.yml b/.github/labeler.ymlindex 07d849cd416..9393833f1b6 100644--- a/.github/labeler.yml+++ b/.github/labeler.yml@@ -34,6 +34,10 @@ discourse-apple-auth:- changed-files:- any-glob-to-any-file: plugins/discourse-apple-auth/**/*+discourse-login-with-amazon:+ - changed-files:+ - any-glob-to-any-file: plugins/discourse-login-with-amazon/**/*+discourse-microsoft-auth:- changed-files:- any-glob-to-any-file: plugins/discourse-microsoft-auth/**/*diff --git a/.gitignore b/.gitignoreindex b10bb67d2ff..72b6f940617 100644--- a/.gitignore+++ b/.gitignore@@ -51,6 +51,7 @@!/plugins/footnote!/plugins/discourse-reactions!/plugins/discourse-apple-auth+!/plugins/discourse-login-with-amazon!/plugins/discourse-microsoft-auth/plugins/*/auto_generateddiff --git a/plugins/discourse-login-with-amazon/README.md b/plugins/discourse-login-with-amazon/README.mdnew file mode 100644index 00000000000..14b4199e0fa--- /dev/null+++ b/plugins/discourse-login-with-amazon/README.md@@ -0,0 +1,23 @@+# Login with Amazon Plugin++A plugin that enables authentication via Login with Amazon.++For more information, please see: https://meta.discourse.org/t/login-with-amazon-plugin/117564++#### Setting up Login With Amazon to auth using localhost for development+1. create an account at developer.amazon.com+2. use the Client Id and Client Secret provided on developer.amazon.com to update your `SiteSettings.login_with_amazon_client_id` and `SiteSettings.login_with_amazon_client_secret` on your local discourse instance+3. on developer.amazon.com, Under "Web Settings", set the following settings:+ - Allowed Origins: http://localhost:4200+ - Allowed Return URLs: http://localhost:4200/auth/amazon/callback+4. create and login to an account on amazon.com with the same email you are using locally for your dev instance.+5. optionally set the following site settings on your local discourse instance:+ - `enable_local_logins: false`+ - `login_required: false`+6. start your local rails server as following:+ - ```% REDIRECT_URL_ORIGIN=http://localhost:4200 rails s```+7. at this point, when you go to localhost:4200, you should be redirected to /login and be presented with a "Login With Amazon" button. Clicking on it should+take you to an authentication flow on amazon.com and redirect you in the end, to a logged in session at localhost: 4200.+++diff --git a/plugins/discourse-login-with-amazon/config/locales/client.ar.yml b/plugins/discourse-login-with-amazon/config/locales/client.ar.ymlnew file mode 100644index 00000000000..e44d9a2b06c--- /dev/null+++ b/plugins/discourse-login-with-amazon/config/locales/client.ar.yml@@ -0,0 +1,13 @@+# WARNING: Never edit this file.+# It will be overwritten when translations are pulled from Crowdin.+#+# To work with us on translations, join this project:+# https://translate.discourse.org/++ar:+ js:+ login:+ amazon:+ name: "Amazon"+ title: "تسجيل الدخول من خلال Amazon"+ message: "المصادقة من خلال تسجيل الدخول باستخدام Amazon (تأكَّد من عدم تفعيل أدوات حظر النوافذ المنبثقة)"diff --git a/plugins/discourse-login-with-amazon/config/locales/client.be.yml b/plugins/discourse-login-with-amazon/config/locales/client.be.ymlnew file mode 100644index 00000000000..2ea77a0d350--- /dev/null+++ b/plugins/discourse-login-with-amazon/config/locales/client.be.yml@@ -0,0 +1,7 @@+# WARNING: Never edit this file.+# It will be overwritten when translations are pulled from Crowdin.+#+# To work with us on translations, join this project:+# https://translate.discourse.org/++be:diff --git a/plugins/discourse-login-with-amazon/config/locales/client.bg.yml b/plugins/discourse-login-with-amazon/config/locales/client.bg.ymlnew file mode 100644index 00000000000..52333529d3c--- /dev/null+++ b/plugins/discourse-login-with-amazon/config/locales/client.bg.yml@@ -0,0 +1,7 @@+# WARNING: Never edit this file.+# It will be overwritten when translations are pulled from Crowdin.+#+# To work with us on translations, join this project:+# https://translate.discourse.org/++bg:diff --git a/plugins/discourse-login-with-amazon/config/locales/client.bs_BA.yml b/plugins/discourse-login-with-amazon/config/locales/client.bs_BA.ymlnew file mode 100644index 00000000000..828a7e65af8--- /dev/null+++ b/plugins/discourse-login-with-amazon/config/locales/client.bs_BA.yml@@ -0,0 +1,7 @@+# WARNING: Never edit this file.+# It will be overwritten when translations are pulled from Crowdin.+#+# To work with us on translations, join this project:+# https://translate.discourse.org/++bs_BA:diff --git a/plugins/discourse-login-with-amazon/config/locales/client.ca.yml b/plugins/discourse-login-with-amazon/config/locales/client.ca.ymlnew file mode 100644index 00000000000..ec737bc1a5b--- /dev/null+++ b/plugins/discourse-login-with-amazon/config/locales/client.ca.yml@@ -0,0 +1,7 @@+# WARNING: Never edit this file.+# It will be overwritten when translations are pulled from Crowdin.+#+# To work with us on translations, join this project:+# https://translate.discourse.org/++ca:diff --git a/plugins/discourse-login-with-amazon/config/locales/client.cs.yml b/plugins/discourse-login-with-amazon/config/locales/client.cs.ymlnew file mode 100644index 00000000000..041b2f0bd05--- /dev/null+++ b/plugins/discourse-login-with-amazon/config/locales/client.cs.yml@@ -0,0 +1,7 @@+# WARNING: Never edit this file.+# It will be overwritten when translations are pulled from Crowdin.+#+# To work with us on translations, join this project:+# https://translate.discourse.org/++cs:diff --git a/plugins/discourse-login-with-amazon/config/locales/client.da.yml b/plugins/discourse-login-with-amazon/config/locales/client.da.ymlnew file mode 100644index 00000000000..f39c727c594--- /dev/null+++ b/plugins/discourse-login-with-amazon/config/locales/client.da.yml@@ -0,0 +1,7 @@+# WARNING: Never edit this file.+# It will be overwritten when translations are pulled from Crowdin.+#+# To work with us on translations, join this project:+# https://translate.discourse.org/++da:diff --git a/plugins/discourse-login-with-amazon/config/locales/client.de.yml b/plugins/discourse-login-with-amazon/config/locales/client.de.ymlnew file mode 100644index 00000000000..a6ed309a987--- /dev/null+++ b/plugins/discourse-login-with-amazon/config/locales/client.de.yml@@ -0,0 +1,13 @@+# WARNING: Never edit this file.+# It will be overwritten when translations are pulled from Crowdin.+#+# To work with us on translations, join this project:+# https://translate.discourse.org/++de:+ js:+ login:+ amazon:+ name: "Amazon"+ title: "Mit Amazon anmelden"+ message: "Authentifizierung über „Anmelden mit Amazon“ (stelle sicher, dass Pop-up-Blocker nicht aktiviert sind)"diff --git a/plugins/discourse-login-with-amazon/config/locales/client.el.yml b/plugins/discourse-login-with-amazon/config/locales/client.el.ymlnew file mode 100644index 00000000000..d872d0ecc40--- /dev/null+++ b/plugins/discourse-login-with-amazon/config/locales/client.el.yml@@ -0,0 +1,7 @@+# WARNING: Never edit this file.+# It will be overwritten when translations are pulled from Crowdin.+#+# To work with us on translations, join this project:+# https://translate.discourse.org/++el:diff --git a/plugins/discourse-login-with-amazon/config/locales/client.en.yml b/plugins/discourse-login-with-amazon/config/locales/client.en.ymlnew file mode 100644index 00000000000..e548d38e1c0--- /dev/null+++ b/plugins/discourse-login-with-amazon/config/locales/client.en.yml@@ -0,0 +1,7 @@+en:+ js:+ login:+ amazon:+ name: "Amazon"+ title: "Login with Amazon"+ message: "Authenticating with Login with Amazon (make sure pop up blockers are not enabled)"diff --git a/plugins/discourse-login-with-amazon/config/locales/client.en_GB.yml b/plugins/discourse-login-with-amazon/config/locales/client.en_GB.ymlnew file mode 100644index 00000000000..2d4fa180ec7--- /dev/null+++ b/plugins/discourse-login-with-amazon/config/locales/client.en_GB.yml@@ -0,0 +1,7 @@+# WARNING: Never edit this file.+# It will be overwritten when translations are pulled from Crowdin.+#+# To work with us on translations, join this project:+# https://translate.discourse.org/++en_GB:diff --git a/plugins/discourse-login-with-amazon/config/locales/client.es.yml b/plugins/discourse-login-with-amazon/config/locales/client.es.ymlnew file mode 100644index 00000000000..8e9e3720074--- /dev/null+++ b/plugins/discourse-login-with-amazon/config/locales/client.es.yml@@ -0,0 +1,13 @@+# WARNING: Never edit this file.+# It will be overwritten when translations are pulled from Crowdin.+#+# To work with us on translations, join this project:+# https://translate.discourse.org/++es:+ js:+ login:+ amazon:+ name: "Amazon"+ title: "Iniciar sesión con Amazon"+ message: "Autenticando con inicio de sesión con Amazon (asegúrate de que no haya bloqueadores de ventanas emergentes activados)"diff --git a/plugins/discourse-login-with-amazon/config/locales/client.et.yml b/plugins/discourse-login-with-amazon/config/locales/client.et.ymlnew file mode 100644index 00000000000..0ea0b6d554b--- /dev/null+++ b/plugins/discourse-login-with-amazon/config/locales/client.et.yml@@ -0,0 +1,7 @@+# WARNING: Never edit this file.+# It will be overwritten when translations are pulled from Crowdin.+#+# To work with us on translations, join this project:+# https://translate.discourse.org/++et:diff --git a/plugins/discourse-login-with-amazon/config/locales/client.fa_IR.yml b/plugins/discourse-login-with-amazon/config/locales/client.fa_IR.ymlnew file mode 100644index 00000000000..a7435daa266--- /dev/null+++ b/plugins/discourse-login-with-amazon/config/locales/client.fa_IR.yml@@ -0,0 +1,12 @@+# WARNING: Never edit this file.+# It will be overwritten when translations are pulled from Crowdin.+#+# To work with us on translations, join this project:+# https://translate.discourse.org/++fa_IR:+ js:+ login:+ amazon:+ name: "آمازون"+ title: "ورود با آمازون"diff --git a/plugins/discourse-login-with-amazon/config/locales/client.fi.yml b/plugins/discourse-login-with-amazon/config/locales/client.fi.ymlnew file mode 100644index 00000000000..2e9c6074dde--- /dev/null+++ b/plugins/discourse-login-with-amazon/config/locales/client.fi.yml@@ -0,0 +1,13 @@+# WARNING: Never edit this file.+# It will be overwritten when translations are pulled from Crowdin.+#+# To work with us on translations, join this project:+# https://translate.discourse.org/++fi:+ js:+ login:+ amazon:+ name: "Amazon"+ title: "Kirjaudu sisään Amazon-tilillä"+ message: "Todennus Login with Amazonilla (varmista, että ponnahdusikkunoiden esto ei ole käytössä)"diff --git a/plugins/discourse-login-with-amazon/config/locales/client.fr.yml b/plugins/discourse-login-with-amazon/config/locales/client.fr.ymlnew file mode 100644index 00000000000..56d6ad8b37d--- /dev/null+++ b/plugins/discourse-login-with-amazon/config/locales/client.fr.yml@@ -0,0 +1,13 @@+# WARNING: Never edit this file.+# It will be overwritten when translations are pulled from Crowdin.+#+# To work with us on translations, join this project:+# https://translate.discourse.org/++fr:+ js:+ login:+ amazon:+ name: "Amazon"+ title: "Se connecter avec Amazon"+ message: "Authentification avec la connexion à Amazon (assurez-vous qu'aucun bloqueur de fenêtres contextuelles n'est activé)"diff --git a/plugins/discourse-login-with-amazon/config/locales/client.gl.yml b/plugins/discourse-login-with-amazon/config/locales/client.gl.ymlnew file mode 100644index 00000000000..fb911ce1635--- /dev/null+++ b/plugins/discourse-login-with-amazon/config/locales/client.gl.yml@@ -0,0 +1,7 @@+# WARNING: Never edit this file.+# It will be overwritten when translations are pulled from Crowdin.+#+# To work with us on translations, join this project:+# https://translate.discourse.org/++gl:diff --git a/plugins/discourse-login-with-amazon/config/locales/client.he.yml b/plugins/discourse-login-with-amazon/config/locales/client.he.ymlnew file mode 100644index 00000000000..2d2d3517f6b--- /dev/null+++ b/plugins/discourse-login-with-amazon/config/locales/client.he.yml@@ -0,0 +1,13 @@+# WARNING: Never edit this file.+# It will be overwritten when translations are pulled from Crowdin.+#+# To work with us on translations, join this project:+# https://translate.discourse.org/++he:+ js:+ login:+ amazon:+ name: "Amazon"+ title: "כניסה עם אמזון"+ message: "אימות באמצעות כניסה עם Amazon (נא לוודא שחוסמי חלונות קופצים אינם מופעלים)"diff --git a/plugins/discourse-login-with-amazon/config/locales/client.hr.yml b/plugins/discourse-login-with-amazon/config/locales/client.hr.ymlnew file mode 100644index 00000000000..93343ce6e19--- /dev/null+++ b/plugins/discourse-login-with-amazon/config/locales/client.hr.yml@@ -0,0 +1,7 @@+# WARNING: Never edit this file.+# It will be overwritten when translations are pulled from Crowdin.+#+# To work with us on translations, join this project:+# https://translate.discourse.org/++hr:diff --git a/plugins/discourse-login-with-amazon/config/locales/client.hu.yml b/plugins/discourse-login-with-amazon/config/locales/client.hu.ymlnew file mode 100644index 00000000000..76b6e9d8bcb--- /dev/null+++ b/plugins/discourse-login-with-amazon/config/locales/client.hu.yml@@ -0,0 +1,7 @@+# WARNING: Never edit this file.+# It will be overwritten when translations are pulled from Crowdin.+#+# To work with us on translations, join this project:+# https://translate.discourse.org/++hu:diff --git a/plugins/discourse-login-with-amazon/config/locales/client.hy.yml b/plugins/discourse-login-with-amazon/config/locales/client.hy.ymlnew file mode 100644index 00000000000..cb18f64d356--- /dev/null+++ b/plugins/discourse-login-with-amazon/config/locales/client.hy.yml@@ -0,0 +1,7 @@+# WARNING: Never edit this file.+# It will be overwritten when translations are pulled from Crowdin.+#+# To work with us on translations, join this project:+# https://translate.discourse.org/++hy:diff --git a/plugins/discourse-login-with-amazon/config/locales/client.id.yml b/plugins/discourse-login-with-amazon/config/locales/client.id.ymlnew file mode 100644index 00000000000..596e36b2e13--- /dev/null+++ b/plugins/discourse-login-with-amazon/config/locales/client.id.yml@@ -0,0 +1,7 @@+# WARNING: Never edit this file.+# It will be overwritten when translations are pulled from Crowdin.+#+# To work with us on translations, join this project:+# https://translate.discourse.org/++id:diff --git a/plugins/discourse-login-with-amazon/config/locales/client.it.yml b/plugins/discourse-login-with-amazon/config/locales/client.it.ymlnew file mode 100644index 00000000000..3b9c593ac25--- /dev/null+++ b/plugins/discourse-login-with-amazon/config/locales/client.it.yml@@ -0,0 +1,13 @@+# WARNING: Never edit this file.+# It will be overwritten when translations are pulled from Crowdin.+#+# To work with us on translations, join this project:+# https://translate.discourse.org/++it:+ js:+ login:+ amazon:+ name: "Amazon"+ title: "Accedi con Amazon"+ message: "Autenticazione con Login with Amazon (assicurati che i blocchi di popup non siano abilitati)"diff --git a/plugins/discourse-login-with-amazon/config/locales/client.ja.yml b/plugins/discourse-login-with-amazon/config/locales/client.ja.ymlnew file mode 100644index 00000000000..bb23b655b70--- /dev/null+++ b/plugins/discourse-login-with-amazon/config/locales/client.ja.yml@@ -0,0 +1,13 @@+# WARNING: Never edit this file.+# It will be overwritten when translations are pulled from Crowdin.+#+# To work with us on translations, join this project:+# https://translate.discourse.org/++ja:+ js:+ login:+ amazon:+ name: "Amazon"+ title: "Amazon でログイン"+ message: "Amazon でログインを認証しています(ポップアップブロッカーが有効になっていないことを確認してください)"diff --git a/plugins/discourse-login-with-amazon/config/locales/client.ko.yml b/plugins/discourse-login-with-amazon/config/locales/client.ko.ymlnew file mode 100644index 00000000000..18dd77fd3ec--- /dev/null+++ b/plugins/discourse-login-with-amazon/config/locales/client.ko.yml@@ -0,0 +1,7 @@+# WARNING: Never edit this file.+# It will be overwritten when translations are pulled from Crowdin.+#+# To work with us on translations, join this project:+# https://translate.discourse.org/++ko:diff --git a/plugins/discourse-login-with-amazon/config/locales/client.lt.yml b/plugins/discourse-login-with-amazon/config/locales/client.lt.ymlnew file mode 100644index 00000000000..16bb19758dc--- /dev/null+++ b/plugins/discourse-login-with-amazon/config/locales/client.lt.yml@@ -0,0 +1,7 @@+# WARNING: Never edit this file.+# It will be overwritten when translations are pulled from Crowdin.+#+# To work with us on translations, join this project:+# https://translate.discourse.org/++lt:diff --git a/plugins/discourse-login-with-amazon/config/locales/client.lv.yml b/plugins/discourse-login-with-amazon/config/locales/client.lv.ymlnew file mode 100644index 00000000000..59e0ef6f4ed--- /dev/null+++ b/plugins/discourse-login-with-amazon/config/locales/client.lv.yml@@ -0,0 +1,7 @@+# WARNING: Never edit this file.+# It will be overwritten when translations are pulled from Crowdin.+#+# To work with us on translations, join this project:+# https://translate.discourse.org/++lv:diff --git a/plugins/discourse-login-with-amazon/config/locales/client.nb_NO.yml b/plugins/discourse-login-with-amazon/config/locales/client.nb_NO.ymlnew file mode 100644index 00000000000..2e2224d1472--- /dev/null+++ b/plugins/discourse-login-with-amazon/config/locales/client.nb_NO.yml@@ -0,0 +1,7 @@+# WARNING: Never edit this file.+# It will be overwritten when translations are pulled from Crowdin.+#+# To work with us on translations, join this project:+# https://translate.discourse.org/++nb_NO:diff --git a/plugins/discourse-login-with-amazon/config/locales/client.nl.yml b/plugins/discourse-login-with-amazon/config/locales/client.nl.ymlnew file mode 100644index 00000000000..6abe335a25b--- /dev/null+++ b/plugins/discourse-login-with-amazon/config/locales/client.nl.yml@@ -0,0 +1,13 @@+# WARNING: Never edit this file.+# It will be overwritten when translations are pulled from Crowdin.+#+# To work with us on translations, join this project:+# https://translate.discourse.org/++nl:+ js:+ login:+ amazon:+ name: "Amazon"+ title: "Aanmelden met Amazon"+ message: "Verificatie met Aanmelden met Amazon (zorg dat pop-upblokkeringen niet zijn ingeschakeld)"diff --git a/plugins/discourse-login-with-amazon/config/locales/client.pl_PL.yml b/plugins/discourse-login-with-amazon/config/locales/client.pl_PL.ymlnew file mode 100644index 00000000000..bd903effdc9--- /dev/null+++ b/plugins/discourse-login-with-amazon/config/locales/client.pl_PL.yml@@ -0,0 +1,13 @@+# WARNING: Never edit this file.+# It will be overwritten when translations are pulled from Crowdin.+#+# To work with us on translations, join this project:+# https://translate.discourse.org/++pl_PL:+ js:+ login:+ amazon:+ name: "Amazon"+ title: "Zaloguj się przez Amazon"+ message: "Uwierzytelnianie za pomocą Zaloguj się przez Amazon (upewnij się, że blokowanie wyskakujących okienek nie jest włączone)"diff --git a/plugins/discourse-login-with-amazon/config/locales/client.pt.yml b/plugins/discourse-login-with-amazon/config/locales/client.pt.ymlnew file mode 100644index 00000000000..298ba523c1d--- /dev/null+++ b/plugins/discourse-login-with-amazon/config/locales/client.pt.yml@@ -0,0 +1,7 @@+# WARNING: Never edit this file.+# It will be overwritten when translations are pulled from Crowdin.+#+# To work with us on translations, join this project:+# https://translate.discourse.org/++pt:diff --git a/plugins/discourse-login-with-amazon/config/locales/client.pt_BR.yml b/plugins/discourse-login-with-amazon/config/locales/client.pt_BR.ymlnew file mode 100644index 00000000000..ce996a6b320--- /dev/null+++ b/plugins/discourse-login-with-amazon/config/locales/client.pt_BR.yml@@ -0,0 +1,13 @@+# WARNING: Never edit this file.+# It will be overwritten when translations are pulled from Crowdin.+#+# To work with us on translations, join this project:+# https://translate.discourse.org/++pt_BR:+ js:+ login:+ amazon:+ name: "Amazon"+ title: "Entrar com a Amazon"+ message: "Autenticaçao com login da Amazon (verifique se bloqueadores de pop-up não estão ativos)"diff --git a/plugins/discourse-login-with-amazon/config/locales/client.ro.yml b/plugins/discourse-login-with-amazon/config/locales/client.ro.ymlnew file mode 100644index 00000000000..08a77f812ee--- /dev/null+++ b/plugins/discourse-login-with-amazon/config/locales/client.ro.yml@@ -0,0 +1,7 @@+# WARNING: Never edit this file.+# It will be overwritten when translations are pulled from Crowdin.+#+# To work with us on translations, join this project:+# https://translate.discourse.org/++ro:diff --git a/plugins/discourse-login-with-amazon/config/locales/client.ru.yml b/plugins/discourse-login-with-amazon/config/locales/client.ru.ymlnew file mode 100644index 00000000000..662f74681e6--- /dev/null+++ b/plugins/discourse-login-with-amazon/config/locales/client.ru.yml@@ -0,0 +1,13 @@+# WARNING: Never edit this file.+# It will be overwritten when translations are pulled from Crowdin.+#+# To work with us on translations, join this project:+# https://translate.discourse.org/++ru:+ js:+ login:+ amazon:+ name: "Amazon"+ title: "Вход через Amazon"+ message: "Аутентификация с помощью входа через Amazon (блокировщики всплывающих окон должны быть отключены)"diff --git a/plugins/discourse-login-with-amazon/config/locales/client.sk.yml b/plugins/discourse-login-with-amazon/config/locales/client.sk.ymlnew file mode 100644index 00000000000..6f815624081--- /dev/null+++ b/plugins/discourse-login-with-amazon/config/locales/client.sk.yml@@ -0,0 +1,7 @@+# WARNING: Never edit this file.+# It will be overwritten when translations are pulled from Crowdin.+#+# To work with us on translations, join this project:+# https://translate.discourse.org/++sk:diff --git a/plugins/discourse-login-with-amazon/config/locales/client.sl.yml b/plugins/discourse-login-with-amazon/config/locales/client.sl.ymlnew file mode 100644index 00000000000..23489a48b1f--- /dev/null+++ b/plugins/discourse-login-with-amazon/config/locales/client.sl.yml@@ -0,0 +1,7 @@+# WARNING: Never edit this file.+# It will be overwritten when translations are pulled from Crowdin.+#+# To work with us on translations, join this project:+# https://translate.discourse.org/++sl:diff --git a/plugins/discourse-login-with-amazon/config/locales/client.sq.yml b/plugins/discourse-login-with-amazon/config/locales/client.sq.ymlnew file mode 100644index 00000000000..7f051b7a7cf--- /dev/null+++ b/plugins/discourse-login-with-amazon/config/locales/client.sq.yml@@ -0,0 +1,7 @@+# WARNING: Never edit this file.+# It will be overwritten when translations are pulled from Crowdin.+#+# To work with us on translations, join this project:+# https://translate.discourse.org/++sq:diff --git a/plugins/discourse-login-with-amazon/config/locales/client.sr.yml b/plugins/discourse-login-with-amazon/config/locales/client.sr.ymlnew file mode 100644index 00000000000..88d63d6ae1a--- /dev/null+++ b/plugins/discourse-login-with-amazon/config/locales/client.sr.yml@@ -0,0 +1,7 @@+# WARNING: Never edit this file.+# It will be overwritten when translations are pulled from Crowdin.+#+# To work with us on translations, join this project:+# https://translate.discourse.org/++sr:diff --git a/plugins/discourse-login-with-amazon/config/locales/client.sv.yml b/plugins/discourse-login-with-amazon/config/locales/client.sv.ymlnew file mode 100644index 00000000000..09930c9cd5c--- /dev/null+++ b/plugins/discourse-login-with-amazon/config/locales/client.sv.yml@@ -0,0 +1,13 @@+# WARNING: Never edit this file.+# It will be overwritten when translations are pulled from Crowdin.+#+# To work with us on translations, join this project:+# https://translate.discourse.org/++sv:+ js:+ login:+ amazon:+ name: "Amazon"+ title: "Logga in med Amazon"+ message: "Autentisering av inloggning genom Amazon (se till att popup -blockerare inte är aktiverade)"diff --git a/plugins/discourse-login-with-amazon/config/locales/client.sw.yml b/plugins/discourse-login-with-amazon/config/locales/client.sw.ymlnew file mode 100644index 00000000000..0d7cdd075bf--- /dev/null+++ b/plugins/discourse-login-with-amazon/config/locales/client.sw.yml@@ -0,0 +1,7 @@+# WARNING: Never edit this file.+# It will be overwritten when translations are pulled from Crowdin.+#+# To work with us on translations, join this project:+# https://translate.discourse.org/++sw:diff --git a/plugins/discourse-login-with-amazon/config/locales/client.te.yml b/plugins/discourse-login-with-amazon/config/locales/client.te.ymlnew file mode 100644index 00000000000..03967bdbb07--- /dev/null+++ b/plugins/discourse-login-with-amazon/config/locales/client.te.yml@@ -0,0 +1,7 @@+# WARNING: Never edit this file.+# It will be overwritten when translations are pulled from Crowdin.+#+# To work with us on translations, join this project:+# https://translate.discourse.org/++te:diff --git a/plugins/discourse-login-with-amazon/config/locales/client.th.yml b/plugins/discourse-login-with-amazon/config/locales/client.th.ymlnew file mode 100644index 00000000000..7de85ff91c4--- /dev/null+++ b/plugins/discourse-login-with-amazon/config/locales/client.th.yml@@ -0,0 +1,7 @@+# WARNING: Never edit this file.+# It will be overwritten when translations are pulled from Crowdin.+#+# To work with us on translations, join this project:+# https://translate.discourse.org/++th:diff --git a/plugins/discourse-login-with-amazon/config/locales/client.tr_TR.yml b/plugins/discourse-login-with-amazon/config/locales/client.tr_TR.ymlnew file mode 100644index 00000000000..2d95c21356a--- /dev/null+++ b/plugins/discourse-login-with-amazon/config/locales/client.tr_TR.yml@@ -0,0 +1,13 @@+# WARNING: Never edit this file.+# It will be overwritten when translations are pulled from Crowdin.+#+# To work with us on translations, join this project:+# https://translate.discourse.org/++tr_TR:+ js:+ login:+ amazon:+ name: "Amazon"+ title: "Amazon ile Giriş Yapın"+ message: "Amazon ile Giriş Yapın ile kimlik doğrulanıyor (açılır pencere engelleyicilerinin etkin olmadığından emin olun)"diff --git a/plugins/discourse-login-with-amazon/config/locales/client.ug.yml b/plugins/discourse-login-with-amazon/config/locales/client.ug.ymlnew file mode 100644index 00000000000..a6bf0185ae2--- /dev/null+++ b/plugins/discourse-login-with-amazon/config/locales/client.ug.yml@@ -0,0 +1,7 @@+# WARNING: Never edit this file.+# It will be overwritten when translations are pulled from Crowdin.+#+# To work with us on translations, join this project:+# https://translate.discourse.org/++ug:diff --git a/plugins/discourse-login-with-amazon/config/locales/client.uk.yml b/plugins/discourse-login-with-amazon/config/locales/client.uk.ymlnew file mode 100644index 00000000000..f1390545d1d--- /dev/null+++ b/plugins/discourse-login-with-amazon/config/locales/client.uk.yml@@ -0,0 +1,7 @@+# WARNING: Never edit this file.+# It will be overwritten when translations are pulled from Crowdin.+#+# To work with us on translations, join this project:+# https://translate.discourse.org/++uk:diff --git a/plugins/discourse-login-with-amazon/config/locales/client.ur.yml b/plugins/discourse-login-with-amazon/config/locales/client.ur.ymlnew file mode 100644index 00000000000..b4a9c21ee2f--- /dev/null+++ b/plugins/discourse-login-with-amazon/config/locales/client.ur.yml@@ -0,0 +1,7 @@+# WARNING: Never edit this file.+# It will be overwritten when translations are pulled from Crowdin.+#+# To work with us on translations, join this project:+# https://translate.discourse.org/++ur:diff --git a/plugins/discourse-login-with-amazon/config/locales/client.vi.yml b/plugins/discourse-login-with-amazon/config/locales/client.vi.ymlnew file mode 100644index 00000000000..f629dcf5329--- /dev/null+++ b/plugins/discourse-login-with-amazon/config/locales/client.vi.yml@@ -0,0 +1,7 @@+# WARNING: Never edit this file.+# It will be overwritten when translations are pulled from Crowdin.+#+# To work with us on translations, join this project:+# https://translate.discourse.org/++vi:diff --git a/plugins/discourse-login-with-amazon/config/locales/client.zh_CN.yml b/plugins/discourse-login-with-amazon/config/locales/client.zh_CN.ymlnew file mode 100644index 00000000000..2cccb04d7c8--- /dev/null+++ b/plugins/discourse-login-with-amazon/config/locales/client.zh_CN.yml@@ -0,0 +1,13 @@+# WARNING: Never edit this file.+# It will be overwritten when translations are pulled from Crowdin.+#+# To work with us on translations, join this project:+# https://translate.discourse.org/++zh_CN:+ js:+ login:+ amazon:+ name: "Amazon"+ title: "使用 Amazon 登录"+ message: "使用“使用 Amazon 登录”进行身份验证(确保未启用弹出窗口阻止程序)"diff --git a/plugins/discourse-login-with-amazon/config/locales/client.zh_TW.yml b/plugins/discourse-login-with-amazon/config/locales/client.zh_TW.ymlnew file mode 100644index 00000000000..7e15fab0018--- /dev/null+++ b/plugins/discourse-login-with-amazon/config/locales/client.zh_TW.yml@@ -0,0 +1,7 @@+# WARNING: Never edit this file.+# It will be overwritten when translations are pulled from Crowdin.+#+# To work with us on translations, join this project:+# https://translate.discourse.org/++zh_TW:diff --git a/plugins/discourse-login-with-amazon/config/locales/server.ar.yml b/plugins/discourse-login-with-amazon/config/locales/server.ar.ymlnew file mode 100644index 00000000000..79428fa2869--- /dev/null+++ b/plugins/discourse-login-with-amazon/config/locales/server.ar.yml@@ -0,0 +1,16 @@+# WARNING: Never edit this file.+# It will be overwritten when translations are pulled from Crowdin.+#+# To work with us on translations, join this project:+# https://translate.discourse.org/++ar:+ site_settings:+ enable_login_with_amazon: "تفعيل المصادقة من خلال تسجيل الدخول باستخدام Amazon، يتطلَّب `login with amazon client id` و`login with amazon client secret`."+ login_with_amazon_client_id: "تسجيل الدخول باستخدام معرِّف عميل Amazon"+ login_with_amazon_client_secret: "تسجيل الدخول باستخدام سر عميل Amazon"+ login_with_amazon_scope: "تسجيل الدخول باستخدام نطاقات Amazon OAuth2 (مفصولة بمسافة)"+ login_with_amazon_overrides_email: "يستبدل عنوان البريد الإلكتروني في حساب مستخدم Discourse."+ errors:+ login_with_amazon_client_id_is_blank: "يجب عليك ضبط 'login with amazon client id' قبل تفعيل هذا الإعداد."+ login_with_amazon_client_secret_is_blank: "يجب عليك ضبط 'login with amazon client secret' قبل تفعيل هذا الإعداد."diff --git a/plugins/discourse-login-with-amazon/config/locales/server.be.yml b/plugins/discourse-login-with-amazon/config/locales/server.be.ymlnew file mode 100644index 00000000000..2ea77a0d350--- /dev/null+++ b/plugins/discourse-login-with-amazon/config/locales/server.be.yml@@ -0,0 +1,7 @@+# WARNING: Never edit this file.+# It will be overwritten when translations are pulled from Crowdin.+#+# To work with us on translations, join this project:+# https://translate.discourse.org/++be:diff --git a/plugins/discourse-login-with-amazon/config/locales/server.bg.yml b/plugins/discourse-login-with-amazon/config/locales/server.bg.ymlnew file mode 100644index 00000000000..52333529d3c--- /dev/null+++ b/plugins/discourse-login-with-amazon/config/locales/server.bg.yml@@ -0,0 +1,7 @@+# WARNING: Never edit this file.+# It will be overwritten when translations are pulled from Crowdin.+#+# To work with us on translations, join this project:+# https://translate.discourse.org/++bg:diff --git a/plugins/discourse-login-with-amazon/config/locales/server.bs_BA.yml b/plugins/discourse-login-with-amazon/config/locales/server.bs_BA.ymlnew file mode 100644index 00000000000..828a7e65af8--- /dev/null+++ b/plugins/discourse-login-with-amazon/config/locales/server.bs_BA.yml@@ -0,0 +1,7 @@+# WARNING: Never edit this file.+# It will be overwritten when translations are pulled from Crowdin.+#+# To work with us on translations, join this project:+# https://translate.discourse.org/++bs_BA:diff --git a/plugins/discourse-login-with-amazon/config/locales/server.ca.yml b/plugins/discourse-login-with-amazon/config/locales/server.ca.ymlnew file mode 100644index 00000000000..ec737bc1a5b--- /dev/null+++ b/plugins/discourse-login-with-amazon/config/locales/server.ca.yml@@ -0,0 +1,7 @@+# WARNING: Never edit this file.+# It will be overwritten when translations are pulled from Crowdin.+#+# To work with us on translations, join this project:+# https://translate.discourse.org/++ca:diff --git a/plugins/discourse-login-with-amazon/config/locales/server.cs.yml b/plugins/discourse-login-with-amazon/config/locales/server.cs.ymlnew file mode 100644index 00000000000..041b2f0bd05--- /dev/null+++ b/plugins/discourse-login-with-amazon/config/locales/server.cs.yml@@ -0,0 +1,7 @@+# WARNING: Never edit this file.+# It will be overwritten when translations are pulled from Crowdin.+#+# To work with us on translations, join this project:+# https://translate.discourse.org/++cs:diff --git a/plugins/discourse-login-with-amazon/config/locales/server.da.yml b/plugins/discourse-login-with-amazon/config/locales/server.da.ymlnew file mode 100644index 00000000000..f39c727c594--- /dev/null+++ b/plugins/discourse-login-with-amazon/config/locales/server.da.yml@@ -0,0 +1,7 @@+# WARNING: Never edit this file.+# It will be overwritten when translations are pulled from Crowdin.+#+# To work with us on translations, join this project:+# https://translate.discourse.org/++da:diff --git a/plugins/discourse-login-with-amazon/config/locales/server.de.yml b/plugins/discourse-login-with-amazon/config/locales/server.de.ymlnew file mode 100644index 00000000000..7bfaee6598c--- /dev/null+++ b/plugins/discourse-login-with-amazon/config/locales/server.de.yml@@ -0,0 +1,16 @@+# WARNING: Never edit this file.+# It will be overwritten when translations are pulled from Crowdin.+#+# To work with us on translations, join this project:+# https://translate.discourse.org/++de:+ site_settings:+ enable_login_with_amazon: "Authentifizierung über „Anmelden mit Amazon“ aktivieren, erfordert `login with amazon client id` und `login with amazon client secret`."+ login_with_amazon_client_id: "Client-ID für „Anmelden mit Amazon“"+ login_with_amazon_client_secret: "Client-Geheimnis für „Anmelden mit Amazon“"+ login_with_amazon_scope: "OAuth2-Bereiche für „Anmelden mit Amazon“ (durch Leerzeichen getrennt)"+ login_with_amazon_overrides_email: "Überschreibt die E-Mail-Adresse im Discourse-Benutzerkonto."+ errors:+ login_with_amazon_client_id_is_blank: "Bevor du diese Einstellung aktivierst, musst du „login with amazon client id“ festlegen."+ login_with_amazon_client_secret_is_blank: "Bevor du diese Einstellung aktivierst, musst du „login with amazon client secret“ festlegen."diff --git a/plugins/discourse-login-with-amazon/config/locales/server.el.yml b/plugins/discourse-login-with-amazon/config/locales/server.el.ymlnew file mode 100644index 00000000000..d872d0ecc40--- /dev/null+++ b/plugins/discourse-login-with-amazon/config/locales/server.el.yml@@ -0,0 +1,7 @@+# WARNING: Never edit this file.+# It will be overwritten when translations are pulled from Crowdin.+#+# To work with us on translations, join this project:+# https://translate.discourse.org/++el:diff --git a/plugins/discourse-login-with-amazon/config/locales/server.en.yml b/plugins/discourse-login-with-amazon/config/locales/server.en.ymlnew file mode 100644index 00000000000..e10689a1cb0--- /dev/null+++ b/plugins/discourse-login-with-amazon/config/locales/server.en.yml@@ -0,0 +1,11 @@+en:+ site_settings:+ enable_login_with_amazon: "Enable Login with Amazon authentication, requires `login with amazon client id` and `login with amazon client secret`."+ login_with_amazon_client_id: "Login with Amazon client ID"+ login_with_amazon_client_secret: "Login with Amazon client secret"+ login_with_amazon_scope: "Login with Amazon OAuth2 scopes (space separated)"+ login_with_amazon_overrides_email: "Overrides the email address on the Discourse user account."++ errors:+ login_with_amazon_client_id_is_blank: "You must set 'login with amazon client id' before enabling this setting."+ login_with_amazon_client_secret_is_blank: "You must set 'login with amazon client secret' before enabling this setting."diff --git a/plugins/discourse-login-with-amazon/config/locales/server.en_GB.yml b/plugins/discourse-login-with-amazon/config/locales/server.en_GB.ymlnew file mode 100644index 00000000000..2d4fa180ec7--- /dev/null+++ b/plugins/discourse-login-with-amazon/config/locales/server.en_GB.yml@@ -0,0 +1,7 @@+# WARNING: Never edit this file.+# It will be overwritten when translations are pulled from Crowdin.+#+# To work with us on translations, join this project:+# https://translate.discourse.org/++en_GB:diff --git a/plugins/discourse-login-with-amazon/config/locales/server.es.yml b/plugins/discourse-login-with-amazon/config/locales/server.es.ymlnew file mode 100644index 00000000000..139fc44fcc5--- /dev/null+++ b/plugins/discourse-login-with-amazon/config/locales/server.es.yml@@ -0,0 +1,16 @@+# WARNING: Never edit this file.+# It will be overwritten when translations are pulled from Crowdin.+#+# To work with us on translations, join this project:+# https://translate.discourse.org/++es:+ site_settings:+ enable_login_with_amazon: "Habilitar el inicio de sesión con la autenticación de Amazon, requiere «iniciar sesión con el id de cliente de amazon» e «iniciar sesión con el secreto de cliente de amazon»."+ login_with_amazon_client_id: "Iniciar sesión con el ID de cliente de Amazon"+ login_with_amazon_client_secret: "Iniciar sesión con el secreto de cliente de Amazon"+ login_with_amazon_scope: "Iniciar sesión con los ámbitos de Amazon OAuth2 (separados por espacio)"+ login_with_amazon_overrides_email: "Reemplaza la dirección de correo electrónico en la cuenta de usuario de Discourse."+ errors:+ login_with_amazon_client_id_is_blank: "Debes configurar «iniciar sesión con el ID de cliente de Amazon» antes de habilitar esta configuración."+ login_with_amazon_client_secret_is_blank: "Debes configurar «iniciar sesión con el secreto de cliente de Amazon» antes de habilitar esta configuración."diff --git a/plugins/discourse-login-with-amazon/config/locales/server.et.yml b/plugins/discourse-login-with-amazon/config/locales/server.et.ymlnew file mode 100644index 00000000000..0ea0b6d554b--- /dev/null+++ b/plugins/discourse-login-with-amazon/config/locales/server.et.yml@@ -0,0 +1,7 @@+# WARNING: Never edit this file.+# It will be overwritten when translations are pulled from Crowdin.+#+# To work with us on translations, join this project:+# https://translate.discourse.org/++et:diff --git a/plugins/discourse-login-with-amazon/config/locales/server.fa_IR.yml b/plugins/discourse-login-with-amazon/config/locales/server.fa_IR.ymlnew file mode 100644index 00000000000..56512089fb5--- /dev/null+++ b/plugins/discourse-login-with-amazon/config/locales/server.fa_IR.yml@@ -0,0 +1,7 @@+# WARNING: Never edit this file.+# It will be overwritten when translations are pulled from Crowdin.+#+# To work with us on translations, join this project:+# https://translate.discourse.org/++fa_IR:diff --git a/plugins/discourse-login-with-amazon/config/locales/server.fi.yml b/plugins/discourse-login-with-amazon/config/locales/server.fi.ymlnew file mode 100644index 00000000000..7634617e78b--- /dev/null+++ b/plugins/discourse-login-with-amazon/config/locales/server.fi.yml@@ -0,0 +1,16 @@+# WARNING: Never edit this file.+# It will be overwritten when translations are pulled from Crowdin.+#+# To work with us on translations, join this project:+# https://translate.discourse.org/++fi:+ site_settings:+ enable_login_with_amazon: "Ota käyttöön Login with Amazon -todennus, \"login with amazon client id\" ja \"login with amazon client secret\" vaaditaan."+ login_with_amazon_client_id: "Login with Amazon -asiakastunnus"+ login_with_amazon_client_secret: "Login with Amazonin asiakkaan salatunnus"+ login_with_amazon_scope: "Login with Amazonin OAuth2-alueet (välilyönnillä erotettuna)"+ login_with_amazon_overrides_email: "Ohittaa Discourse-käyttäjätilin sähköpostiosoitteen."+ errors:+ login_with_amazon_client_id_is_blank: "Sinun täytyy asettaa \"login with amazon client id\" ennen kuin otat tämän asetuksen käyttöön."+ login_with_amazon_client_secret_is_blank: "Sinun täytyy asettaa \"login with amazon client secret\" ennen kuin otat tämän asetuksen käyttöön."diff --git a/plugins/discourse-login-with-amazon/config/locales/server.fr.yml b/plugins/discourse-login-with-amazon/config/locales/server.fr.ymlnew file mode 100644index 00000000000..d59e11a838d--- /dev/null+++ b/plugins/discourse-login-with-amazon/config/locales/server.fr.yml@@ -0,0 +1,16 @@+# WARNING: Never edit this file.+# It will be overwritten when translations are pulled from Crowdin.+#+# To work with us on translations, join this project:+# https://translate.discourse.org/++fr:+ site_settings:+ enable_login_with_amazon: "Activez la connexion avec l'authentification Amazon, nécessite « connexion avec l'identifiant client amazon » et « connexion avec le secret client amazon »."+ login_with_amazon_client_id: "Connexion avec l'identifiant client Amazon"+ login_with_amazon_client_secret: "Connexion avec le secret client Amazon"+ login_with_amazon_scope: "Connexion avec les autorisations OAuth2 d'Amazon (séparées par des espaces)"+ login_with_amazon_overrides_email: "Remplace l'adresse e-mail du compte utilisateur Discourse."+ errors:+ login_with_amazon_client_id_is_blank: "Vous devez définir « Connexion avec l'identifiant client Amazon » avant d'activer ce paramètre."+ login_with_amazon_client_secret_is_blank: "Vous devez définir « Connexion avec le secret client Amazon » avant d'activer ce paramètre."diff --git a/plugins/discourse-login-with-amazon/config/locales/server.gl.yml b/plugins/discourse-login-with-amazon/config/locales/server.gl.ymlnew file mode 100644index 00000000000..fb911ce1635--- /dev/null+++ b/plugins/discourse-login-with-amazon/config/locales/server.gl.yml@@ -0,0 +1,7 @@+# WARNING: Never edit this file.+# It will be overwritten when translations are pulled from Crowdin.+#+# To work with us on translations, join this project:+# https://translate.discourse.org/++gl:diff --git a/plugins/discourse-login-with-amazon/config/locales/server.he.yml b/plugins/discourse-login-with-amazon/config/locales/server.he.ymlnew file mode 100644index 00000000000..35c7a639cea--- /dev/null+++ b/plugins/discourse-login-with-amazon/config/locales/server.he.yml@@ -0,0 +1,16 @@+# WARNING: Never edit this file.+# It will be overwritten when translations are pulled from Crowdin.+#+# To work with us on translations, join this project:+# https://translate.discourse.org/++he:+ site_settings:+ enable_login_with_amazon: "הפעלת כניסה עם אימות מול Amazon, דורש את `login with amazon client id` ואת `login with amazon client secret`."+ login_with_amazon_client_id: "כניסה עם מזהה לקוח של Amazon"+ login_with_amazon_client_secret: "כניסה עם סוד לקוח של Amazon"+ login_with_amazon_scope: "כניסה עם scopes של OAuth2 של Amazon (מופרדים ברווחים)"+ login_with_amazon_overrides_email: "דורס את כתובת הדוא״ל בחשבון המשתמש ב־Discourse."+ errors:+ login_with_amazon_client_id_is_blank: "עליך להגדיר את ‚login with amazon client id’ בטרם הפעלת ההגדרה הזאת."+ login_with_amazon_client_secret_is_blank: "עליך להגדיר את ‚login with amazon client secret’ בטרם הפעלת ההגדרה הזאת."diff --git a/plugins/discourse-login-with-amazon/config/locales/server.hr.yml b/plugins/discourse-login-with-amazon/config/locales/server.hr.ymlnew file mode 100644index 00000000000..93343ce6e19--- /dev/null+++ b/plugins/discourse-login-with-amazon/config/locales/server.hr.yml@@ -0,0 +1,7 @@+# WARNING: Never edit this file.+# It will be overwritten when translations are pulled from Crowdin.+#+# To work with us on translations, join this project:+# https://translate.discourse.org/++hr:diff --git a/plugins/discourse-login-with-amazon/config/locales/server.hu.yml b/plugins/discourse-login-with-amazon/config/locales/server.hu.ymlnew file mode 100644index 00000000000..76b6e9d8bcb--- /dev/null+++ b/plugins/discourse-login-with-amazon/config/locales/server.hu.yml@@ -0,0 +1,7 @@+# WARNING: Never edit this file.+# It will be overwritten when translations are pulled from Crowdin.+#+# To work with us on translations, join this project:+# https://translate.discourse.org/++hu:diff --git a/plugins/discourse-login-with-amazon/config/locales/server.hy.yml b/plugins/discourse-login-with-amazon/config/locales/server.hy.ymlnew file mode 100644index 00000000000..cb18f64d356--- /dev/null+++ b/plugins/discourse-login-with-amazon/config/locales/server.hy.yml@@ -0,0 +1,7 @@+# WARNING: Never edit this file.+# It will be overwritten when translations are pulled from Crowdin.+#+# To work with us on translations, join this project:+# https://translate.discourse.org/++hy:diff --git a/plugins/discourse-login-with-amazon/config/locales/server.id.yml b/plugins/discourse-login-with-amazon/config/locales/server.id.ymlnew file mode 100644index 00000000000..596e36b2e13--- /dev/null+++ b/plugins/discourse-login-with-amazon/config/locales/server.id.yml@@ -0,0 +1,7 @@+# WARNING: Never edit this file.+# It will be overwritten when translations are pulled from Crowdin.+#+# To work with us on translations, join this project:+# https://translate.discourse.org/++id:diff --git a/plugins/discourse-login-with-amazon/config/locales/server.it.yml b/plugins/discourse-login-with-amazon/config/locales/server.it.ymlnew file mode 100644index 00000000000..d1231c50fc5--- /dev/null+++ b/plugins/discourse-login-with-amazon/config/locales/server.it.yml@@ -0,0 +1,16 @@+# WARNING: Never edit this file.+# It will be overwritten when translations are pulled from Crowdin.+#+# To work with us on translations, join this project:+# https://translate.discourse.org/++it:+ site_settings:+ enable_login_with_amazon: "Abilita l'autenticazione con Login with Amazon; richiede l'impostazione dei parametri `login with amazon client id` e `login with amazon client secret`."+ login_with_amazon_client_id: "ID del client Login with Amazon"+ login_with_amazon_client_secret: "Segreto del client Login with Amazon"+ login_with_amazon_scope: "Ambiti di Login with Amazon OAuth2 (separati da spazi)"+ login_with_amazon_overrides_email: "Sostituisce l'indirizzo e-mail nell'account dell'utente Discourse."+ errors:+ login_with_amazon_client_id_is_blank: "Prima di abilitare questa impostazione, devi impostare l'opzione 'login with amazon client id'."+ login_with_amazon_client_secret_is_blank: "Prima di abilitare questa impostazione, devi impostare l'opzione 'login with amazon client secret'."diff --git a/plugins/discourse-login-with-amazon/config/locales/server.ja.yml b/plugins/discourse-login-with-amazon/config/locales/server.ja.ymlnew file mode 100644index 00000000000..842e98bb46a--- /dev/null+++ b/plugins/discourse-login-with-amazon/config/locales/server.ja.yml@@ -0,0 +1,16 @@+# WARNING: Never edit this file.+# It will be overwritten when translations are pulled from Crowdin.+#+# To work with us on translations, join this project:+# https://translate.discourse.org/++ja:+ site_settings:+ enable_login_with_amazon: "「Amazon でログイン」認証を有効にします。 `login with amazon client id` と `login with amazon client secret` が必要です。"+ login_with_amazon_client_id: "「Amazon でログイン」クライアント ID"+ login_with_amazon_client_secret: "「Amazon でログイン」クライアントシークレット"+ login_with_amazon_scope: "「Amazon でログイン」OAuth2 スコープ(スペース区切り)"+ login_with_amazon_overrides_email: "Discourse ユーザーアカウントのメールアドレスを上書きします。"+ errors:+ login_with_amazon_client_id_is_blank: "この設定を有効にする前に、'login with amazon client id' を設定する必要があります。"+ login_with_amazon_client_secret_is_blank: "この設定を有効にする前に、'login with amazon client secret' を設定する必要があります。"diff --git a/plugins/discourse-login-with-amazon/config/locales/server.ko.yml b/plugins/discourse-login-with-amazon/config/locales/server.ko.ymlnew file mode 100644index 00000000000..18dd77fd3ec--- /dev/null+++ b/plugins/discourse-login-with-amazon/config/locales/server.ko.yml@@ -0,0 +1,7 @@+# WARNING: Never edit this file.+# It will be overwritten when translations are pulled from Crowdin.+#+# To work with us on translations, join this project:+# https://translate.discourse.org/++ko:diff --git a/plugins/discourse-login-with-amazon/config/locales/server.lt.yml b/plugins/discourse-login-with-amazon/config/locales/server.lt.ymlnew file mode 100644index 00000000000..16bb19758dc--- /dev/null+++ b/plugins/discourse-login-with-amazon/config/locales/server.lt.yml@@ -0,0 +1,7 @@+# WARNING: Never edit this file.+# It will be overwritten when translations are pulled from Crowdin.+#+# To work with us on translations, join this project:+# https://translate.discourse.org/++lt:diff --git a/plugins/discourse-login-with-amazon/config/locales/server.lv.yml b/plugins/discourse-login-with-amazon/config/locales/server.lv.ymlnew file mode 100644index 00000000000..59e0ef6f4ed--- /dev/null+++ b/plugins/discourse-login-with-amazon/config/locales/server.lv.yml@@ -0,0 +1,7 @@+# WARNING: Never edit this file.+# It will be overwritten when translations are pulled from Crowdin.+#+# To work with us on translations, join this project:+# https://translate.discourse.org/++lv:diff --git a/plugins/discourse-login-with-amazon/config/locales/server.nb_NO.yml b/plugins/discourse-login-with-amazon/config/locales/server.nb_NO.ymlnew file mode 100644index 00000000000..2e2224d1472--- /dev/null+++ b/plugins/discourse-login-with-amazon/config/locales/server.nb_NO.yml@@ -0,0 +1,7 @@+# WARNING: Never edit this file.+# It will be overwritten when translations are pulled from Crowdin.+#+# To work with us on translations, join this project:+# https://translate.discourse.org/++nb_NO:diff --git a/plugins/discourse-login-with-amazon/config/locales/server.nl.yml b/plugins/discourse-login-with-amazon/config/locales/server.nl.ymlnew file mode 100644index 00000000000..9d7befb5e76--- /dev/null+++ b/plugins/discourse-login-with-amazon/config/locales/server.nl.yml@@ -0,0 +1,16 @@+# WARNING: Never edit this file.+# It will be overwritten when translations are pulled from Crowdin.+#+# To work with us on translations, join this project:+# https://translate.discourse.org/++nl:+ site_settings:+ enable_login_with_amazon: "Schakel verificatie via Aanmelden met Amazon in, vereist 'login with amazon client id' en 'login with amazon client secret'."+ login_with_amazon_client_id: "Client-ID voor Aanmelden met Amazon"+ login_with_amazon_client_secret: "Clientgeheim voor Aanmelden met Amazon"+ login_with_amazon_scope: "OAuth2-bereiken voor Aanmelden met Amazon (gescheiden door spaties)"+ login_with_amazon_overrides_email: "Overschrijft het e-mailadres van het Discourse-gebruikersaccount."+ errors:+ login_with_amazon_client_id_is_blank: "Je moet 'login with amazon client id' instellen voordat je deze instelling inschakelt."+ login_with_amazon_client_secret_is_blank: "Je moet 'login with amazon client secret' instellen voordat je deze instelling inschakelt."diff --git a/plugins/discourse-login-with-amazon/config/locales/server.pl_PL.yml b/plugins/discourse-login-with-amazon/config/locales/server.pl_PL.ymlnew file mode 100644index 00000000000..1d056eca825--- /dev/null+++ b/plugins/discourse-login-with-amazon/config/locales/server.pl_PL.yml@@ -0,0 +1,16 @@+# WARNING: Never edit this file.+# It will be overwritten when translations are pulled from Crowdin.+#+# To work with us on translations, join this project:+# https://translate.discourse.org/++pl_PL:+ site_settings:+ enable_login_with_amazon: "Włącz logowanie za pomocą uwierzytelniania Amazon, wymaga `login with amazon client id` i `login with amazon client secret`."+ login_with_amazon_client_id: "Zaloguj się przy użyciu ID klienta Amazon"+ login_with_amazon_client_secret: "Zaloguj się za pomocą sekretu klienta Amazon"+ login_with_amazon_scope: "Zaloguj się za pomocą zakresów Amazon OAuth2 (oddzielone spacją)"+ login_with_amazon_overrides_email: "Zastępuje adres e-mail na koncie użytkownika Discourse."+ errors:+ login_with_amazon_client_id_is_blank: "Musisz ustawić 'login with amazon client id' przed włączeniem tego ustawienia."+ login_with_amazon_client_secret_is_blank: "Musisz ustawić 'login with amazon client secret' przed włączeniem tego ustawienia."diff --git a/plugins/discourse-login-with-amazon/config/locales/server.pt.yml b/plugins/discourse-login-with-amazon/config/locales/server.pt.ymlnew file mode 100644index 00000000000..298ba523c1d--- /dev/null+++ b/plugins/discourse-login-with-amazon/config/locales/server.pt.yml@@ -0,0 +1,7 @@+# WARNING: Never edit this file.+# It will be overwritten when translations are pulled from Crowdin.+#+# To work with us on translations, join this project:+# https://translate.discourse.org/++pt:diff --git a/plugins/discourse-login-with-amazon/config/locales/server.pt_BR.yml b/plugins/discourse-login-with-amazon/config/locales/server.pt_BR.ymlnew file mode 100644index 00000000000..b273873343b--- /dev/null+++ b/plugins/discourse-login-with-amazon/config/locales/server.pt_BR.yml@@ -0,0 +1,16 @@+# WARNING: Never edit this file.+# It will be overwritten when translations are pulled from Crowdin.+#+# To work with us on translations, join this project:+# https://translate.discourse.org/++pt_BR:+ site_settings:+ enable_login_with_amazon: "Ative o login com autenticação da Amazon, requer \"login with amazon client id\" and 'login with amazon client secret\"."+ login_with_amazon_client_id: "Entrar com ID de cliente da Amazon"+ login_with_amazon_client_secret: "Entrar com segredo de cliente da Amazon"+ login_with_amazon_scope: "Entrar com escopos do Amazon OAuth2 (espaço separado)"+ login_with_amazon_overrides_email: "Substitui o endereço de e-mail na conta de usuário(a) do Discourse."+ errors:+ login_with_amazon_client_id_is_blank: "É preciso definir \"login with amazon client id\" antes de ativar esta configuração."+ login_with_amazon_client_secret_is_blank: "É preciso definir \"entrar com id de cliente da amazon\" antes de ativar esta configuração."diff --git a/plugins/discourse-login-with-amazon/config/locales/server.ro.yml b/plugins/discourse-login-with-amazon/config/locales/server.ro.ymlnew file mode 100644index 00000000000..08a77f812ee--- /dev/null+++ b/plugins/discourse-login-with-amazon/config/locales/server.ro.yml@@ -0,0 +1,7 @@+# WARNING: Never edit this file.+# It will be overwritten when translations are pulled from Crowdin.+#+# To work with us on translations, join this project:+# https://translate.discourse.org/++ro:diff --git a/plugins/discourse-login-with-amazon/config/locales/server.ru.yml b/plugins/discourse-login-with-amazon/config/locales/server.ru.ymlnew file mode 100644index 00000000000..e9f8f78e25c--- /dev/null+++ b/plugins/discourse-login-with-amazon/config/locales/server.ru.yml@@ -0,0 +1,16 @@+# WARNING: Never edit this file.+# It will be overwritten when translations are pulled from Crowdin.+#+# To work with us on translations, join this project:+# https://translate.discourse.org/++ru:+ site_settings:+ enable_login_with_amazon: "Включите аутентификацию входа через Amazon, требуется «Вход с ID клиента Amazon» и «Вход с ключом клиента Amazon»."+ login_with_amazon_client_id: "Вход с ID клиента Amazon"+ login_with_amazon_client_secret: "Вход с ключом клиента Amazon"+ login_with_amazon_scope: "Вход с помощью Amazon OAuth2 (через пробел)"+ login_with_amazon_overrides_email: "Переопределяет адрес электронной почты в аккаунте пользователя Discourse."+ errors:+ login_with_amazon_client_id_is_blank: "Вы должны установить «Вход с ID клиента amazon» перед включением этой настройки."+ login_with_amazon_client_secret_is_blank: "Вы должны установить «Вход с ключом клиента amazon» перед включением этой настройки."diff --git a/plugins/discourse-login-with-amazon/config/locales/server.sk.yml b/plugins/discourse-login-with-amazon/config/locales/server.sk.ymlnew file mode 100644index 00000000000..6f815624081--- /dev/null+++ b/plugins/discourse-login-with-amazon/config/locales/server.sk.yml@@ -0,0 +1,7 @@+# WARNING: Never edit this file.+# It will be overwritten when translations are pulled from Crowdin.+#+# To work with us on translations, join this project:+# https://translate.discourse.org/++sk:diff --git a/plugins/discourse-login-with-amazon/config/locales/server.sl.yml b/plugins/discourse-login-with-amazon/config/locales/server.sl.ymlnew file mode 100644index 00000000000..23489a48b1f--- /dev/null+++ b/plugins/discourse-login-with-amazon/config/locales/server.sl.yml@@ -0,0 +1,7 @@+# WARNING: Never edit this file.+# It will be overwritten when translations are pulled from Crowdin.+#+# To work with us on translations, join this project:+# https://translate.discourse.org/++sl:diff --git a/plugins/discourse-login-with-amazon/config/locales/server.sq.yml b/plugins/discourse-login-with-amazon/config/locales/server.sq.ymlnew file mode 100644index 00000000000..7f051b7a7cf--- /dev/null+++ b/plugins/discourse-login-with-amazon/config/locales/server.sq.yml@@ -0,0 +1,7 @@+# WARNING: Never edit this file.+# It will be overwritten when translations are pulled from Crowdin.+#+# To work with us on translations, join this project:+# https://translate.discourse.org/++sq:diff --git a/plugins/discourse-login-with-amazon/config/locales/server.sr.yml b/plugins/discourse-login-with-amazon/config/locales/server.sr.ymlnew file mode 100644index 00000000000..88d63d6ae1a--- /dev/null+++ b/plugins/discourse-login-with-amazon/config/locales/server.sr.yml@@ -0,0 +1,7 @@+# WARNING: Never edit this file.+# It will be overwritten when translations are pulled from Crowdin.+#+# To work with us on translations, join this project:+# https://translate.discourse.org/++sr:diff --git a/plugins/discourse-login-with-amazon/config/locales/server.sv.yml b/plugins/discourse-login-with-amazon/config/locales/server.sv.ymlnew file mode 100644index 00000000000..216eb80cba9--- /dev/null+++ b/plugins/discourse-login-with-amazon/config/locales/server.sv.yml@@ -0,0 +1,16 @@+# WARNING: Never edit this file.+# It will be overwritten when translations are pulled from Crowdin.+#+# To work with us on translations, join this project:+# https://translate.discourse.org/++sv:+ site_settings:+ enable_login_with_amazon: "Aktivera inloggning genom Amazon-autentisering, kräver `login with amazon client id` och `login with amazon client secret`."+ login_with_amazon_client_id: "Logga in med Amazons klient-ID"+ login_with_amazon_client_secret: "Logga in med Amazons klienthemlighet"+ login_with_amazon_scope: "Logga in med Amazon OAuth2 scopes (mellanslag separerat)"+ login_with_amazon_overrides_email: "Åsidosätter e-postadressen för användarkontot i Discourse."+ errors:+ login_with_amazon_client_id_is_blank: "Du måste ställa in 'login with amazon client id' innan du aktiverar den här inställningen."+ login_with_amazon_client_secret_is_blank: "Du måste ställa in 'login with amazon client secret' innan du aktiverar den här inställningen."diff --git a/plugins/discourse-login-with-amazon/config/locales/server.sw.yml b/plugins/discourse-login-with-amazon/config/locales/server.sw.ymlnew file mode 100644index 00000000000..0d7cdd075bf--- /dev/null+++ b/plugins/discourse-login-with-amazon/config/locales/server.sw.yml@@ -0,0 +1,7 @@+# WARNING: Never edit this file.+# It will be overwritten when translations are pulled from Crowdin.+#+# To work with us on translations, join this project:+# https://translate.discourse.org/++sw:diff --git a/plugins/discourse-login-with-amazon/config/locales/server.te.yml b/plugins/discourse-login-with-amazon/config/locales/server.te.ymlnew file mode 100644index 00000000000..03967bdbb07--- /dev/null+++ b/plugins/discourse-login-with-amazon/config/locales/server.te.yml@@ -0,0 +1,7 @@+# WARNING: Never edit this file.+# It will be overwritten when translations are pulled from Crowdin.+#+# To work with us on translations, join this project:+# https://translate.discourse.org/++te:diff --git a/plugins/discourse-login-with-amazon/config/locales/server.th.yml b/plugins/discourse-login-with-amazon/config/locales/server.th.ymlnew file mode 100644index 00000000000..7de85ff91c4--- /dev/null+++ b/plugins/discourse-login-with-amazon/config/locales/server.th.yml@@ -0,0 +1,7 @@+# WARNING: Never edit this file.+# It will be overwritten when translations are pulled from Crowdin.+#+# To work with us on translations, join this project:+# https://translate.discourse.org/++th:diff --git a/plugins/discourse-login-with-amazon/config/locales/server.tr_TR.yml b/plugins/discourse-login-with-amazon/config/locales/server.tr_TR.ymlnew file mode 100644index 00000000000..fffcf736a85--- /dev/null+++ b/plugins/discourse-login-with-amazon/config/locales/server.tr_TR.yml@@ -0,0 +1,16 @@+# WARNING: Never edit this file.+# It will be overwritten when translations are pulled from Crowdin.+#+# To work with us on translations, join this project:+# https://translate.discourse.org/++tr_TR:+ site_settings:+ enable_login_with_amazon: "Amazon kimlik doğrulaması ile Giriş'i etkinleştirin, \"login with amazon client id\" ve \"login with amazon client secret\" gerektirir."+ login_with_amazon_client_id: "Amazon istemci kimliği ile giriş yapın"+ login_with_amazon_client_secret: "Amazon istemci sırrı ile giriş yapın"+ login_with_amazon_scope: "Amazon OAuth2 kapsamları ile giriş yapın (boşlukla ayırarak)"+ login_with_amazon_overrides_email: "Discourse kullanıcı hesabındaki e-posta adresini geçersiz kılar."+ errors:+ login_with_amazon_client_id_is_blank: "Bu ayarı etkinleştirmeden önce \"login with amazon client id\" ayarını yapmanız gerekir."+ login_with_amazon_client_secret_is_blank: "Bu ayarı etkinleştirmeden önce \"login with amazon client secret\" ayarını yapmanız gerekir."diff --git a/plugins/discourse-login-with-amazon/config/locales/server.ug.yml b/plugins/discourse-login-with-amazon/config/locales/server.ug.ymlnew file mode 100644index 00000000000..a6bf0185ae2--- /dev/null+++ b/plugins/discourse-login-with-amazon/config/locales/server.ug.yml@@ -0,0 +1,7 @@+# WARNING: Never edit this file.+# It will be overwritten when translations are pulled from Crowdin.+#+# To work with us on translations, join this project:+# https://translate.discourse.org/++ug:diff --git a/plugins/discourse-login-with-amazon/config/locales/server.uk.yml b/plugins/discourse-login-with-amazon/config/locales/server.uk.ymlnew file mode 100644index 00000000000..f1390545d1d--- /dev/null+++ b/plugins/discourse-login-with-amazon/config/locales/server.uk.yml@@ -0,0 +1,7 @@+# WARNING: Never edit this file.+# It will be overwritten when translations are pulled from Crowdin.+#+# To work with us on translations, join this project:+# https://translate.discourse.org/++uk:diff --git a/plugins/discourse-login-with-amazon/config/locales/server.ur.yml b/plugins/discourse-login-with-amazon/config/locales/server.ur.ymlnew file mode 100644index 00000000000..b4a9c21ee2f--- /dev/null+++ b/plugins/discourse-login-with-amazon/config/locales/server.ur.yml@@ -0,0 +1,7 @@+# WARNING: Never edit this file.+# It will be overwritten when translations are pulled from Crowdin.+#+# To work with us on translations, join this project:+# https://translate.discourse.org/++ur:diff --git a/plugins/discourse-login-with-amazon/config/locales/server.vi.yml b/plugins/discourse-login-with-amazon/config/locales/server.vi.ymlnew file mode 100644index 00000000000..f629dcf5329--- /dev/null+++ b/plugins/discourse-login-with-amazon/config/locales/server.vi.yml@@ -0,0 +1,7 @@+# WARNING: Never edit this file.+# It will be overwritten when translations are pulled from Crowdin.+#+# To work with us on translations, join this project:+# https://translate.discourse.org/++vi:diff --git a/plugins/discourse-login-with-amazon/config/locales/server.zh_CN.yml b/plugins/discourse-login-with-amazon/config/locales/server.zh_CN.ymlnew file mode 100644index 00000000000..6144be5a0fc--- /dev/null+++ b/plugins/discourse-login-with-amazon/config/locales/server.zh_CN.yml@@ -0,0 +1,16 @@+# WARNING: Never edit this file.+# It will be overwritten when translations are pulled from Crowdin.+#+# To work with us on translations, join this project:+# https://translate.discourse.org/++zh_CN:+ site_settings:+ enable_login_with_amazon: "启用“使用 Amazon 登录”身份验证,需要 `login with amazon client id` 和 `login with amazon client secret`。"+ login_with_amazon_client_id: "使用 Amazon 客户端 ID 登录"+ login_with_amazon_client_secret: "使用 Amazon 客户端密钥登录"+ login_with_amazon_scope: "使用 Amazon OAuth2 范围登录(空格分隔)"+ login_with_amazon_overrides_email: "覆盖 Discourse 用户帐户上的电子邮件地址。"+ errors:+ login_with_amazon_client_id_is_blank: "在启用此设置之前,您必须设置“使用 Amazon 客户端 ID 登录”。"+ login_with_amazon_client_secret_is_blank: "在启用此设置之前,您必须设置“使用 Amazon 客户端密钥登录”。"diff --git a/plugins/discourse-login-with-amazon/config/locales/server.zh_TW.yml b/plugins/discourse-login-with-amazon/config/locales/server.zh_TW.ymlnew file mode 100644index 00000000000..7e15fab0018--- /dev/null+++ b/plugins/discourse-login-with-amazon/config/locales/server.zh_TW.yml@@ -0,0 +1,7 @@+# WARNING: Never edit this file.+# It will be overwritten when translations are pulled from Crowdin.+#+# To work with us on translations, join this project:+# https://translate.discourse.org/++zh_TW:diff --git a/plugins/discourse-login-with-amazon/config/settings.yml b/plugins/discourse-login-with-amazon/config/settings.ymlnew file mode 100644index 00000000000..99905ea6b2c--- /dev/null+++ b/plugins/discourse-login-with-amazon/config/settings.yml@@ -0,0 +1,17 @@+plugins:+ enable_login_with_amazon:+ default: false+ validator: "EnableLoginWithAmazonValidator"+ login_with_amazon_client_id:+ default: ""+ secret: true+ login_with_amazon_client_secret:+ default: ""+ secret: true+ login_with_amazon_scope:+ default: "profile"+ login_with_amazon_overrides_email:+ default: false+ login_with_amazon_email_verified:+ hidden: true+ default: truediff --git a/plugins/discourse-login-with-amazon/lib/auth/login_with_amazon_authenticator.rb b/plugins/discourse-login-with-amazon/lib/auth/login_with_amazon_authenticator.rbnew file mode 100644index 00000000000..ad0ff2abc39--- /dev/null+++ b/plugins/discourse-login-with-amazon/lib/auth/login_with_amazon_authenticator.rb@@ -0,0 +1,32 @@+# frozen_string_literal: true++class Auth::LoginWithAmazonAuthenticator < ::Auth::ManagedAuthenticator+ def name+ "amazon"+ end++ def enabled?+ SiteSetting.enable_login_with_amazon+ end++ def register_middleware(omniauth)+ omniauth.provider :amazon,+ setup:+ lambda { |env|+ strategy = env["omniauth.strategy"]+ strategy.options[:client_id] = SiteSetting.login_with_amazon_client_id+ strategy.options[+ :client_secret+ ] = SiteSetting.login_with_amazon_client_secret+ strategy.options[:scope] = SiteSetting.login_with_amazon_scope+ }+ end++ def always_update_user_email?+ SiteSetting.login_with_amazon_overrides_email+ end++ def primary_email_verified?(auth)+ SiteSetting.login_with_amazon_email_verified+ end+enddiff --git a/plugins/discourse-login-with-amazon/lib/omniauth/strategies/amazon.rb b/plugins/discourse-login-with-amazon/lib/omniauth/strategies/amazon.rbnew file mode 100644index 00000000000..e49600f4409--- /dev/null+++ b/plugins/discourse-login-with-amazon/lib/omniauth/strategies/amazon.rb@@ -0,0 +1,51 @@+# frozen_string_literal: true++module OmniAuth+ module Strategies+ class Amazon < OmniAuth::Strategies::OAuth2+ option :name, "amazon"++ option :client_options,+ {+ site: "https://www.amazon.com/",+ authorize_url: "https://www.amazon.com/ap/oa",+ token_url: "https://api.amazon.com/auth/o2/token",+ }++ option :access_token_options, { mode: :query }++ option :authorize_params, { scope: "profile postal_code" }++ def build_access_token+ token_params = {+ redirect_uri: callback_url.split("?").first,+ client_id: client.id,+ client_secret: client.secret,+ }+ verifier = request.params["code"]+ client.auth_code.get_token(verifier, token_params)+ end++ uid { raw_info["Profile"]["CustomerId"] }++ info do+ { "email" => raw_info["Profile"]["PrimaryEmail"], "name" => raw_info["Profile"]["Name"] }+ end++ extra { { "postal_code" => raw_info["Profile"]["PostalCode"] } }++ def raw_info+ access_token.options[:parse] = :json++ url = "/ap/user/profile"+ params = { params: { access_token: access_token.token } }+ @raw_info ||= access_token.client.request(:get, url, params).parsed+ end++ def callback_url+ origin = ENV["REDIRECT_URL_ORIGIN"] || full_host+ origin + script_name + callback_path+ end+ end+ end+enddiff --git a/plugins/discourse-login-with-amazon/lib/validators/enable_login_with_amazon_validator.rb b/plugins/discourse-login-with-amazon/lib/validators/enable_login_with_amazon_validator.rbnew file mode 100644index 00000000000..1c5c8d534f0--- /dev/null+++ b/plugins/discourse-login-with-amazon/lib/validators/enable_login_with_amazon_validator.rb@@ -0,0 +1,26 @@+# frozen_string_literal: true++class EnableLoginWithAmazonValidator+ def initialize(opts = {})+ @opts = opts+ end++ def valid_value?(val)+ return true if val == "f"++ if SiteSetting.login_with_amazon_client_id.blank? ||+ SiteSetting.login_with_amazon_client_secret.blank?+ return false+ end++ true+ end++ def error_message+ if SiteSetting.login_with_amazon_client_id.blank?+ I18n.t("site_settings.errors.login_with_amazon_client_id_is_blank")+ elsif SiteSetting.login_with_amazon_client_secret.blank?+ I18n.t("site_settings.errors.login_with_amazon_client_secret_is_blank")+ end+ end+enddiff --git a/plugins/discourse-login-with-amazon/plugin.rb b/plugins/discourse-login-with-amazon/plugin.rbnew file mode 100644index 00000000000..c49d296797c--- /dev/null+++ b/plugins/discourse-login-with-amazon/plugin.rb@@ -0,0 +1,18 @@+# frozen_string_literal: true++# name: discourse-login-with-amazon+# about: Enables login authentication via Login with Amazon+# meta_topic_id: 117564+# version: 0.0.1+# authors: Alan Tan+# url: https://github.com/discourse/discourse/tree/main/plugins/discourse-login-with-amazon++enabled_site_setting :enable_login_with_amazon++register_svg_icon "fab-amazon"++require_relative "lib/auth/login_with_amazon_authenticator"+require_relative "lib/validators/enable_login_with_amazon_validator"+require_relative "lib/omniauth/strategies/amazon"++auth_provider authenticator: Auth::LoginWithAmazonAuthenticator.new, icon: "fab-amazon"diff --git a/plugins/discourse-login-with-amazon/spec/lib/validators/enable_login_with_amazon_validator_spec.rb b/plugins/discourse-login-with-amazon/spec/lib/validators/enable_login_with_amazon_validator_spec.rbnew file mode 100644index 00000000000..8ab63cd3978--- /dev/null+++ b/plugins/discourse-login-with-amazon/spec/lib/validators/enable_login_with_amazon_validator_spec.rb@@ -0,0 +1,46 @@+# frozen_string_literal: true++require "rails_helper"++RSpec.describe EnableLoginWithAmazonValidator do+ subject(:validator) { described_class.new }++ describe "#valid_value?" do+ describe "when login_with_amazon_client_id and login_with_amazon_client_secret has not been set" do+ it "should return true when value is false" do+ expect(validator.valid_value?("f")).to eq(true)+ end++ it "should return false when value is true" do+ expect(validator.valid_value?("t")).to eq(false)++ expect(validator.error_message).to eq(+ I18n.t("site_settings.errors.login_with_amazon_client_id_is_blank"),+ )++ SiteSetting.login_with_amazon_client_id = "somekey"++ expect(validator.valid_value?("t")).to eq(false)++ expect(validator.error_message).to eq(+ I18n.t("site_settings.errors.login_with_amazon_client_secret_is_blank"),+ )+ end+ end++ describe "when login_with_amazon_client_id and login_with_amazon_client_secret has been set" do+ before do+ SiteSetting.login_with_amazon_client_id = "somekey"+ SiteSetting.login_with_amazon_client_secret = "somesecretkey"+ end++ it "should return true when value is false" do+ expect(validator.valid_value?("f")).to eq(true)+ end++ it "should return true when value is true" do+ expect(validator.valid_value?("t")).to eq(true)+ end+ end+ end+enddiff --git a/plugins/discourse-login-with-amazon/spec/system/core_features_spec.rb b/plugins/discourse-login-with-amazon/spec/system/core_features_spec.rbnew file mode 100644index 00000000000..646117e39e3--- /dev/null+++ b/plugins/discourse-login-with-amazon/spec/system/core_features_spec.rb@@ -0,0 +1,11 @@+# frozen_string_literal: true++RSpec.describe "Core features", type: :system do+ before do+ SiteSetting.login_with_amazon_client_id = "somekey"+ SiteSetting.login_with_amazon_client_secret = "somesecretkey"+ enable_current_plugin+ end++ it_behaves_like "having working core features"+enddiff --git a/translator.yml b/translator.ymlindex 473c6c320ff..480ef0c3e09 100644--- a/translator.yml+++ b/translator.yml@@ -123,6 +123,13 @@ files:destination_path: plugins/apple-auth/server.ymllabel: apple-auth+ - source_path: plugins/discourse-login-with-amazon/config/locales/client.en.yml+ destination_path: plugins/login-with-amazon/client.yml+ label: login-with-amazon+ - source_path: plugins/discourse-login-with-amazon/config/locales/server.en.yml+ destination_path: plugins/login-with-amazon/server.yml+ label: login-with-amazon+- source_path: plugins/discourse-microsoft-auth/config/locales/client.en.ymldestination_path: plugins/microsoft-auth/client.ymllabel: microsoft-auth