From 0d608ceff84ec59affd18db1059e5815b7580031 Mon Sep 17 00:00:00 2001 From: Jan Cernik <66427541+jancernik@users.noreply.github.com> Date: Thu, 4 Jul 2024 09:17:07 -0300 Subject: [PATCH] UX: Registration design and validation improvements (#27666) --- .../app/components/modal/create-account.hbs | 103 ++++++++++-------- .../app/components/user-fields/confirm.hbs | 2 +- .../app/components/user-fields/dropdown.hbs | 4 +- .../components/user-fields/multiselect.hbs | 4 +- .../app/components/user-fields/text.hbs | 6 +- .../stylesheets/common/modal/login-modal.scss | 27 ++++- config/locales/client.en.yml | 4 +- spec/system/create_account_spec.rb | 2 +- 8 files changed, 89 insertions(+), 63 deletions(-) diff --git a/app/assets/javascripts/discourse/app/components/modal/create-account.hbs b/app/assets/javascripts/discourse/app/components/modal/create-account.hbs index 5085280e62d..1fc3d985eb8 100644 --- a/app/assets/javascripts/discourse/app/components/modal/create-account.hbs +++ b/app/assets/javascripts/discourse/app/components/modal/create-account.hbs @@ -53,17 +53,16 @@ /> - - {{i18n "user.email.instructions"}} - + {{#unless this.emailValidation.reason}} + + {{i18n "user.email.instructions"}} + + {{/unless}}
@@ -80,47 +79,18 @@ /> - - {{i18n "user.username.instructions"}} - -
+ {{#unless this.usernameValidation.reason}} -
- {{#if this.fullnameRequired}} - - - - - - {{this.nameInstructions}} + + {{i18n "user.username.instructions"}} - {{/if}} + {{/unless}}