mirror of
https://github.com/andwati/zitadel.git
synced 2026-11-16 10:45:12 +00:00
feat: login success page (#1849)
* feat: login success page * fix: script import on mfa verify
This commit is contained in:
@@ -200,6 +200,11 @@ ExternalNotFoundOption:
|
||||
Link: Verlinken
|
||||
AutoRegister: Automatisches registrieren
|
||||
|
||||
LoginSuccess:
|
||||
Title: Erfolgreich eingeloggt
|
||||
AutoRedirect: Du wirst automatisch zurück in die Applikation geleitet. Danach kannst du diese Fenster schliessen.
|
||||
Redirected: Du kannst diese Fenster nun schliessen.
|
||||
|
||||
LogoutDone:
|
||||
Title: Ausgeloggt
|
||||
Description: Du wurdest erfolgreich ausgeloggt.
|
||||
|
||||
@@ -190,6 +190,11 @@ RegistrationOrg:
|
||||
PrivacyLinkText: privacy policy
|
||||
PrivacyLink: https://zitadel.ch/pdf/privacy.pdf
|
||||
|
||||
LoginSuccess:
|
||||
Title: Login successful
|
||||
AutoRedirect: You will be directed back to your application automatically. If not, click on the button below. You can close the window afterwards.
|
||||
Redirected: You can now close this window.
|
||||
|
||||
LogoutDone:
|
||||
Title: Logged out
|
||||
Description: You have logged out successfully.
|
||||
|
||||
@@ -0,0 +1,17 @@
|
||||
document.addEventListener('DOMContentLoaded', function () {
|
||||
autoSubmit();
|
||||
});
|
||||
|
||||
function autoSubmit() {
|
||||
let form = document.getElementsByTagName('form')[0];
|
||||
if (form) {
|
||||
let button = document.getElementById("redirect-button");
|
||||
if (button) {
|
||||
button.addEventListener("click", function (event) {
|
||||
location.reload();
|
||||
event.preventDefault();
|
||||
});
|
||||
}
|
||||
form.submit();
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,32 @@
|
||||
{{template "main-top" .}}
|
||||
|
||||
|
||||
<div class="lgn-head">
|
||||
<h1>{{t "LoginSuccess.Title"}}</h1>
|
||||
|
||||
{{ template "user-profile" . }}
|
||||
|
||||
{{if .RedirectURI}}
|
||||
<p>{{t "LoginSuccess.AutoRedirect"}}</p>
|
||||
</div>
|
||||
|
||||
<form action="{{ .RedirectURI }}" method="GET">
|
||||
|
||||
<input type="hidden" name="id" value="{{ .AuthReqID }}" />
|
||||
|
||||
{{ template "error-message" .}}
|
||||
|
||||
<div class="lgn-actions">
|
||||
<span class="fill-space"></span>
|
||||
<button id="redirect-button" class="lgn-raised-button lgn-primary">{{t "Actions.Next"}}</button>
|
||||
</div>
|
||||
|
||||
</form>
|
||||
|
||||
<script src="{{ resourceUrl "scripts/login_success.js" }}"></script>
|
||||
{{else}}
|
||||
<p>{{t "LoginSuccess.Redirected"}}</p>
|
||||
</div>
|
||||
{{end}}
|
||||
|
||||
{{template "main-bottom" .}}
|
||||
@@ -43,6 +43,6 @@
|
||||
{{ end }}
|
||||
</form>
|
||||
|
||||
<script src="{{ resourceUrl " scripts/form_submit.js" }}"></script>
|
||||
<script src="{{ resourceUrl " scripts/default_form_validation.js" }}"></script>
|
||||
<script src="{{ resourceUrl "scripts/form_submit.js" }}"></script>
|
||||
<script src="{{ resourceUrl "scripts/default_form_validation.js" }}"></script>
|
||||
{{template "main-bottom" .}}
|
||||
Reference in New Issue
Block a user