mirror of
https://github.com/lukin/keywind.git
synced 2025-01-10 18:06:23 +00:00
Prettier
This commit is contained in:
parent
5dad1e2c7f
commit
60792959f3
4 changed files with 142 additions and 123 deletions
|
@ -1,20 +1,21 @@
|
||||||
<#import "template.ftl" as layout>
|
<#import "template.ftl" as layout>
|
||||||
<#import "components/button/primary.ftl" as buttonPrimary>
|
<#import "components/button/primary.ftl" as buttonPrimary>
|
||||||
|
|
||||||
<@layout.registrationLayout; section>
|
<@layout.registrationLayout; section>
|
||||||
<#if section = "header">
|
<#if section="header">
|
||||||
${msg("confirmLinkIdpTitle")}
|
${msg("confirmLinkIdpTitle")}
|
||||||
<#elseif section = "form">
|
<#elseif section="form">
|
||||||
<form action="${url.loginAction}" method="post" class="m-0 space-y-4">
|
<form action="${url.loginAction}" class="m-0 space-y-4" method="post">
|
||||||
<div>
|
<div>
|
||||||
<@buttonPrimary.kw type="submit" name="submitAction" id="updateProfile" value="updateProfile">
|
<@buttonPrimary.kw name="submitAction" type="submit" value="updateProfile">
|
||||||
${msg("confirmLinkIdpReviewProfile")}
|
${msg("confirmLinkIdpReviewProfile")}
|
||||||
</@buttonPrimary.kw>
|
</@buttonPrimary.kw>
|
||||||
</div>
|
</div>
|
||||||
<div>
|
<div>
|
||||||
<@buttonPrimary.kw type="submit" name="submitAction" id="linkAccount" value="linkAccount">
|
<@buttonPrimary.kw name="submitAction" type="submit" value="linkAccount">
|
||||||
${msg("confirmLinkIdpContinue", idpDisplayName)}
|
${msg("confirmLinkIdpContinue", idpDisplayName)}
|
||||||
</@buttonPrimary.kw>
|
</@buttonPrimary.kw>
|
||||||
</div>
|
</div>
|
||||||
</form>
|
</form>
|
||||||
</#if>
|
</#if>
|
||||||
</@layout.registrationLayout>
|
</@layout.registrationLayout>
|
||||||
|
|
|
@ -1,42 +1,53 @@
|
||||||
<#import "template.ftl" as layout>
|
<#import "template.ftl" as layout>
|
||||||
<#import "components/button/primary.ftl" as buttonPrimary>
|
<#import "components/button/primary.ftl" as buttonPrimary>
|
||||||
<#import "components/input/primary.ftl" as inputPrimary>
|
<#import "components/input/primary.ftl" as inputPrimary>
|
||||||
<@layout.registrationLayout displayMessage=!messagesPerField.existsError('password','password-confirm'); section>
|
|
||||||
<#if section = "header">
|
|
||||||
${msg("updatePasswordTitle")}
|
|
||||||
<#elseif section = "form">
|
|
||||||
<form class="m-0 space-y-4" action="${url.loginAction}" method="post">
|
|
||||||
<input type="text" id="username" name="username" value="${username}" autocomplete="username"
|
|
||||||
readonly="readonly" style="display:none;"/>
|
|
||||||
<input type="password" id="password" name="password" autocomplete="current-password" style="display:none;"/>
|
|
||||||
|
|
||||||
<div>
|
<@layout.registrationLayout
|
||||||
<@inputPrimary.kw
|
displayMessage=!messagesPerField.existsError("password", "password-confirm")
|
||||||
autocomplete="new-password"
|
;
|
||||||
invalid=["password", "password-confirm"]
|
section
|
||||||
message=false
|
>
|
||||||
autofocus=true
|
<#if section="header">
|
||||||
name="password-new"
|
${msg("updatePasswordTitle")}
|
||||||
type="password"
|
<#elseif section="form">
|
||||||
>
|
<form action="${url.loginAction}" class="m-0 space-y-4" method="post">
|
||||||
${msg("passwordNew")}
|
<input
|
||||||
</@inputPrimary.kw>
|
autocomplete="username"
|
||||||
</div>
|
name="username"
|
||||||
<div>
|
type="hidden"
|
||||||
<@inputPrimary.kw
|
value="${username}"
|
||||||
autocomplete="new-password"
|
>
|
||||||
invalid=["password-confirm"]
|
<input autocomplete="current-password" name="password" type="hidden">
|
||||||
name="password-confirm"
|
<div>
|
||||||
type="password"
|
<@inputPrimary.kw
|
||||||
>
|
autocomplete="new-password"
|
||||||
${msg("passwordConfirm")}
|
autofocus=true
|
||||||
</@inputPrimary.kw>
|
invalid=["password", "password-confirm"]
|
||||||
</div>
|
message=false
|
||||||
<div>
|
name="password-new"
|
||||||
<@buttonPrimary.kw type="submit">
|
type="password"
|
||||||
${msg("doSubmit")}
|
>
|
||||||
</@buttonPrimary.kw>
|
${msg("passwordNew")}
|
||||||
</div>
|
</@inputPrimary.kw>
|
||||||
</form>
|
</div>
|
||||||
</#if>
|
<div>
|
||||||
</@layout.registrationLayout>
|
<@inputPrimary.kw
|
||||||
|
autocomplete="new-password"
|
||||||
|
invalid=["password-confirm"]
|
||||||
|
name="password-confirm"
|
||||||
|
type="password"
|
||||||
|
>
|
||||||
|
${msg("passwordConfirm")}
|
||||||
|
</@inputPrimary.kw>
|
||||||
|
</div>
|
||||||
|
|
||||||
|
<#-- TODO isAppInitiatedAction -->
|
||||||
|
|
||||||
|
<div>
|
||||||
|
<@buttonPrimary.kw type="submit">
|
||||||
|
${msg("doSubmit")}
|
||||||
|
</@buttonPrimary.kw>
|
||||||
|
</div>
|
||||||
|
</form>
|
||||||
|
</#if>
|
||||||
|
</@layout.registrationLayout>
|
||||||
|
|
|
@ -1,64 +1,71 @@
|
||||||
<#import "template.ftl" as layout>
|
<#import "template.ftl" as layout>
|
||||||
<#import "components/button/primary.ftl" as buttonPrimary>
|
<#import "components/button/primary.ftl" as buttonPrimary>
|
||||||
<#import "components/input/primary.ftl" as inputPrimary>
|
<#import "components/input/primary.ftl" as inputPrimary>
|
||||||
<@layout.registrationLayout displayMessage=!messagesPerField.existsError('username','email','firstName','lastName'); section>
|
|
||||||
<#if section = "header">
|
|
||||||
${msg("loginProfileTitle")}
|
|
||||||
<#elseif section = "form">
|
|
||||||
<form class="m-0 space-y-4" action="${url.loginAction}" method="post">
|
|
||||||
<#if user.editUsernameAllowed>
|
|
||||||
<div>
|
|
||||||
<@inputPrimary.kw
|
|
||||||
autocomplete="username"
|
|
||||||
autofocus=true
|
|
||||||
invalid=["username"]
|
|
||||||
name="username"
|
|
||||||
type="text"
|
|
||||||
value=(user.username)!''
|
|
||||||
>
|
|
||||||
${msg("username")}
|
|
||||||
</@inputPrimary.kw>
|
|
||||||
</div>
|
|
||||||
</#if>
|
|
||||||
<div>
|
|
||||||
<@inputPrimary.kw
|
|
||||||
autocomplete="email"
|
|
||||||
invalid=["email"]
|
|
||||||
name="email"
|
|
||||||
type="email"
|
|
||||||
value=(user.email)!''
|
|
||||||
>
|
|
||||||
${msg("email")}
|
|
||||||
</@inputPrimary.kw>
|
|
||||||
</div>
|
|
||||||
<div>
|
|
||||||
<@inputPrimary.kw
|
|
||||||
autocomplete="given-name"
|
|
||||||
invalid=["firstName"]
|
|
||||||
name="firstName"
|
|
||||||
type="text"
|
|
||||||
value=(user.firstName)!''
|
|
||||||
>
|
|
||||||
${msg("firstName")}
|
|
||||||
</@inputPrimary.kw>
|
|
||||||
</div>
|
|
||||||
<div>
|
|
||||||
<@inputPrimary.kw
|
|
||||||
autocomplete="family-name"
|
|
||||||
invalid=["lastName"]
|
|
||||||
name="lastName"
|
|
||||||
type="text"
|
|
||||||
value=(user.lastName)!''
|
|
||||||
>
|
|
||||||
${msg("lastName")}
|
|
||||||
</@inputPrimary.kw>
|
|
||||||
</div>
|
|
||||||
|
|
||||||
<div>
|
<@layout.registrationLayout
|
||||||
<@buttonPrimary.kw type="submit">
|
displayMessage=!messagesPerField.existsError("email", "firstName", "lastName", "username")
|
||||||
${msg("doSubmit")}
|
;
|
||||||
</@buttonPrimary.kw>
|
section
|
||||||
</div>
|
>
|
||||||
</form>
|
<#if section="header">
|
||||||
</#if>
|
${msg("loginProfileTitle")}
|
||||||
|
<#elseif section="form">
|
||||||
|
<form action="${url.loginAction}" class="m-0 space-y-4" method="post">
|
||||||
|
<#if user.editUsernameAllowed>
|
||||||
|
<div>
|
||||||
|
<@inputPrimary.kw
|
||||||
|
autocomplete="username"
|
||||||
|
autofocus=true
|
||||||
|
invalid=["username"]
|
||||||
|
name="username"
|
||||||
|
type="text"
|
||||||
|
value=(user.username)!''
|
||||||
|
>
|
||||||
|
${msg("username")}
|
||||||
|
</@inputPrimary.kw>
|
||||||
|
</div>
|
||||||
|
</#if>
|
||||||
|
<div>
|
||||||
|
<@inputPrimary.kw
|
||||||
|
autocomplete="email"
|
||||||
|
invalid=["email"]
|
||||||
|
name="email"
|
||||||
|
type="email"
|
||||||
|
value=(user.email)!''
|
||||||
|
>
|
||||||
|
${msg("email")}
|
||||||
|
</@inputPrimary.kw>
|
||||||
|
</div>
|
||||||
|
<div>
|
||||||
|
<@inputPrimary.kw
|
||||||
|
autocomplete="given-name"
|
||||||
|
invalid=["firstName"]
|
||||||
|
name="firstName"
|
||||||
|
type="text"
|
||||||
|
value=(user.firstName)!''
|
||||||
|
>
|
||||||
|
${msg("firstName")}
|
||||||
|
</@inputPrimary.kw>
|
||||||
|
</div>
|
||||||
|
<div>
|
||||||
|
<@inputPrimary.kw
|
||||||
|
autocomplete="family-name"
|
||||||
|
invalid=["lastName"]
|
||||||
|
name="lastName"
|
||||||
|
type="text"
|
||||||
|
value=(user.lastName)!''
|
||||||
|
>
|
||||||
|
${msg("lastName")}
|
||||||
|
</@inputPrimary.kw>
|
||||||
|
</div>
|
||||||
|
|
||||||
|
<#-- TODO isAppInitiatedAction -->
|
||||||
|
|
||||||
|
<div>
|
||||||
|
<@buttonPrimary.kw type="submit">
|
||||||
|
${msg("doSubmit")}
|
||||||
|
</@buttonPrimary.kw>
|
||||||
|
</div>
|
||||||
|
</form>
|
||||||
|
</#if>
|
||||||
</@layout.registrationLayout>
|
</@layout.registrationLayout>
|
||||||
|
|
|
@ -51,16 +51,16 @@
|
||||||
</@inputPrimary.kw>
|
</@inputPrimary.kw>
|
||||||
</div>
|
</div>
|
||||||
<div class="flex items-center justify-between">
|
<div class="flex items-center justify-between">
|
||||||
<#if realm.rememberMe && !usernameEditDisabled??>
|
<#if realm.rememberMe && !usernameEditDisabled??>
|
||||||
<@checkboxPrimary.kw checked=login.rememberMe?? name="rememberMe">
|
<@checkboxPrimary.kw checked=login.rememberMe?? name="rememberMe">
|
||||||
${msg("rememberMe")}
|
${msg("rememberMe")}
|
||||||
</@checkboxPrimary.kw>
|
</@checkboxPrimary.kw>
|
||||||
</#if>
|
</#if>
|
||||||
<#if realm.resetPasswordAllowed>
|
<#if realm.resetPasswordAllowed>
|
||||||
<@linkPrimary.kw href=url.loginResetCredentialsUrl>
|
<@linkPrimary.kw href=url.loginResetCredentialsUrl>
|
||||||
<span class="text-sm">${msg("doForgotPassword")}</span>
|
<span class="text-sm">${msg("doForgotPassword")}</span>
|
||||||
</@linkPrimary.kw>
|
</@linkPrimary.kw>
|
||||||
</#if>
|
</#if>
|
||||||
</div>
|
</div>
|
||||||
<div class="pt-4">
|
<div class="pt-4">
|
||||||
<@buttonPrimary.kw name="login" type="submit">
|
<@buttonPrimary.kw name="login" type="submit">
|
||||||
|
|
Loading…
Reference in a new issue