feat: Update auth screens (#11108)

# Pull Request Template

## Description

This PR includes style updates for auth screens

## Type of change

- [x] Bug fix (non-breaking change which fixes an issue)


## Checklist:

- [x] My code follows the style guidelines of this project
- [x] I have performed a self-review of my code
- [x] I have commented on my code, particularly in hard-to-understand
areas
- [ ] I have made corresponding changes to the documentation
- [x] My changes generate no new warnings
- [ ] I have added tests that prove my fix is effective or that my
feature works
- [x] New and existing unit tests pass locally with my changes
- [ ] Any dependent changes have been merged and published in downstream
modules
This commit is contained in:
Sivin Varghese
2025-03-19 15:19:32 +05:30
committed by GitHub
parent 4c26fe5d57
commit c89a2cd672
20 changed files with 262 additions and 257 deletions

View File

@@ -49,6 +49,7 @@ export default {
@tailwind components;
@tailwind utilities;
@import '../dashboard/assets/scss/next-colors';
@import 'shared/assets/stylesheets/colors';
@import 'shared/assets/stylesheets/spacing';
@import 'shared/assets/stylesheets/font-size';

View File

@@ -12,12 +12,10 @@ export default {
<template>
<div class="relative my-4 section-separator">
<div class="absolute inset-0 flex items-center" aria-hidden="true">
<div class="w-full border-t border-slate-200 dark:border-slate-600" />
<div class="w-full border-t border-n-strong" />
</div>
<div v-if="label" class="relative flex justify-center text-sm">
<span
class="bg-white dark:bg-slate-800 px-2 text-slate-500 dark:text-white"
>
<span class="bg-white dark:bg-n-solid-2 px-2 text-n-slate-10">
{{ label }}
</span>
</div>

View File

@@ -7,6 +7,10 @@ defineProps({
type: String,
required: true,
},
type: {
type: String,
default: 'text',
},
icon: {
type: String,
default: '',
@@ -51,9 +55,13 @@ const model = defineModel({
<input
v-bind="$attrs"
v-model="model"
type="text"
:type="type"
class="block w-full border-none rounded-md shadow-sm bg-n-alpha-black2 appearance-none outline outline-1 focus:outline focus:outline-1 text-n-slate-12 placeholder:text-n-slate-10 sm:text-sm sm:leading-6 px-3 py-3"
:class="{
error: hasError,
'error outline-n-ruby-8 dark:outline-n-ruby-8 hover:outline-n-ruby-9 dark:hover:outline-n-ruby-9 disabled:outline-n-ruby-8 dark:disabled:outline-n-ruby-8':
hasError,
'outline-n-weak dark:outline-n-weak hover:outline-n-slate-6 dark:hover:outline-n-slate-6 focus:outline-n-brand dark:focus:outline-n-brand':
!hasError,
'px-3 py-3': spacing === 'base',
'px-3 py-2 mb-0': spacing === 'compact',
'pl-9': icon,

View File

@@ -45,10 +45,10 @@ export default {
<div class="flex flex-col">
<a
:href="getGoogleAuthUrl()"
class="inline-flex justify-center w-full px-4 py-3 bg-white rounded-md shadow-sm ring-1 ring-inset ring-slate-200 dark:ring-slate-600 hover:bg-slate-50 focus:outline-offset-0 dark:bg-slate-700 dark:hover:bg-slate-700"
class="inline-flex justify-center w-full px-4 py-3 bg-n-background dark:bg-n-solid-3 rounded-md shadow-sm ring-1 ring-inset ring-n-container dark:ring-n-container focus:outline-offset-0 hover:bg-n-alpha-2 dark:hover:bg-n-alpha-2"
>
<span class="i-logos-google-icon h-6" />
<span class="ml-2 text-base font-medium text-slate-600 dark:text-white">
<span class="ml-2 text-base font-medium text-n-slate-12">
{{ $t('LOGIN.OAUTH.GOOGLE_LOGIN') }}
</span>
</a>

View File

@@ -30,8 +30,10 @@ export default {
</script>
<template>
<div class="flex items-center justify-center h-full w-full">
<div
class="flex items-center justify-center min-h-screen h-full bg-n-background w-full"
>
<Spinner color-scheme="primary" size="" />
<div class="ml-2">{{ $t('CONFIRM_EMAIL') }}</div>
<div class="ml-2 text-n-slate-11">{{ $t('CONFIRM_EMAIL') }}</div>
</div>
</template>

View File

@@ -87,14 +87,14 @@ export default {
<template>
<div
class="flex flex-col justify-center w-full min-h-screen py-12 bg-woot-25 sm:px-6 lg:px-8 dark:bg-slate-900"
class="flex flex-col justify-center w-full min-h-screen py-12 bg-n-brand/5 dark:bg-n-background sm:px-6 lg:px-8"
>
<form
class="bg-white shadow sm:mx-auto sm:w-full sm:max-w-lg dark:bg-slate-800 p-11 sm:shadow-lg sm:rounded-lg"
class="bg-white shadow sm:mx-auto sm:w-full sm:max-w-lg dark:bg-n-solid-2 p-11 sm:shadow-lg sm:rounded-lg"
@submit.prevent="submitForm"
>
<h1
class="mb-1 text-2xl font-medium tracking-tight text-left text-slate-900 dark:text-white"
class="mb-1 text-2xl font-medium tracking-tight text-left text-n-slate-12"
>
{{ $t('SET_NEW_PASSWORD.TITLE') }}
</h1>

View File

@@ -68,19 +68,19 @@ export default {
<template>
<div
class="flex flex-col justify-center w-full min-h-screen py-12 bg-woot-25 sm:px-6 lg:px-8 dark:bg-slate-900"
class="flex flex-col justify-center w-full min-h-screen py-12 bg-n-brand/5 dark:bg-n-background sm:px-6 lg:px-8"
>
<form
class="bg-white shadow sm:mx-auto sm:w-full sm:max-w-lg dark:bg-slate-800 p-11 sm:shadow-lg sm:rounded-lg"
class="bg-white shadow sm:mx-auto sm:w-full sm:max-w-lg dark:bg-n-solid-2 p-11 sm:shadow-lg sm:rounded-lg"
@submit.prevent="submit"
>
<h1
class="mb-1 text-2xl font-medium tracking-tight text-left text-slate-900 dark:text-white"
class="mb-1 text-2xl font-medium tracking-tight text-left text-n-slate-12"
>
{{ $t('RESET_PASSWORD.TITLE') }}
</h1>
<p
class="mb-4 text-sm font-normal leading-6 tracking-normal text-slate-600 dark:text-woot-50"
class="mb-4 text-sm font-normal leading-6 tracking-normal text-n-slate-11"
>
{{
useInstallationName(
@@ -104,9 +104,9 @@ export default {
:loading="resetPassword.showLoading"
/>
</div>
<p class="mt-4 -mb-1 text-sm text-slate-600 dark:text-woot-50">
<p class="mt-4 -mb-1 text-sm text-n-slate-11">
{{ $t('RESET_PASSWORD.GO_BACK_TO_LOGIN') }}
<router-link to="/auth/login" class="text-link">
<router-link to="/auth/login" class="text-link text-n-brand">
{{ $t('COMMON.CLICK_HERE') }}.
</router-link>
</p>

View File

@@ -33,7 +33,7 @@ export default {
</script>
<template>
<div class="w-full h-full dark:bg-slate-900">
<div class="w-full h-full bg-n-background">
<div v-show="!isLoading" class="flex h-full min-h-screen items-center">
<div
class="flex-1 min-h-[640px] inline-flex items-center h-full justify-center overflow-auto py-6"
@@ -52,15 +52,15 @@ export default {
class="hidden w-auto h-8 dark:block"
/>
<h2
class="mt-6 text-3xl font-medium text-left mb-7 text-slate-900 dark:text-woot-50"
class="mt-6 text-3xl font-medium text-left mb-7 text-n-slate-12"
>
{{ $t('REGISTER.TRY_WOOT') }}
</h2>
</div>
<SignupForm />
<div class="px-1 text-sm text-slate-800 dark:text-woot-50">
<div class="px-1 text-sm text-n-slate-12">
<span>{{ $t('REGISTER.HAVE_AN_ACCOUNT') }}</span>
<router-link class="text-link" to="/app/login">
<router-link class="text-link text-n-brand" to="/app/login">
{{
useInstallationName(
$t('LOGIN.TITLE'),
@@ -79,7 +79,7 @@ export default {
</div>
<div
v-show="isLoading"
class="flex items-center justify-center w-full h-full"
class="flex items-center min-h-screen justify-center w-full h-full"
>
<Spinner color-scheme="primary" size="" />
</div>

View File

@@ -23,12 +23,12 @@ export default {
<template>
<div
class="flex flex-col items-start justify-center p-6 w-80 bg-white rounded-lg drop-shadow-md dark:bg-slate-800"
class="flex flex-col items-start justify-center p-6 w-80 bg-n-background rounded-lg drop-shadow-md"
>
<p class="text-sm text-slate-600 dark:text-woot-50 tracking-normal">
<p class="text-sm text-n-slate-12 tracking-normal">
{{ reviewContent }}
</p>
<div class="flex items-center mt-4 text-slate-700 dark:text-woot-50">
<div class="flex items-center mt-4 text-n-slate-12">
<div class="bg-white rounded-full p-1">
<img :src="authorImage" class="h-8 w-8 rounded-full" />
</div>

View File

@@ -155,7 +155,7 @@ export default {
<template>
<main
class="flex flex-col w-full min-h-screen py-20 bg-woot-25 sm:px-6 lg:px-8 dark:bg-slate-900"
class="flex flex-col w-full min-h-screen py-20 bg-n-brand/5 dark:bg-n-background sm:px-6 lg:px-8"
>
<section class="max-w-5xl mx-auto">
<img
@@ -169,25 +169,20 @@ export default {
:alt="globalConfig.installationName"
class="hidden w-auto h-8 mx-auto dark:block"
/>
<h2
class="mt-6 text-3xl font-medium text-center text-slate-900 dark:text-woot-50"
>
<h2 class="mt-6 text-3xl font-medium text-center text-n-slate-12">
{{
useInstallationName($t('LOGIN.TITLE'), globalConfig.installationName)
}}
</h2>
<p
v-if="showSignupLink"
class="mt-3 text-sm text-center text-slate-600 dark:text-slate-400"
>
<p v-if="showSignupLink" class="mt-3 text-sm text-center text-n-slate-11">
{{ $t('COMMON.OR') }}
<router-link to="auth/signup" class="lowercase text-link">
<router-link to="auth/signup" class="lowercase text-link text-n-brand">
{{ $t('LOGIN.CREATE_NEW_ACCOUNT') }}
</router-link>
</p>
</section>
<section
class="bg-white shadow sm:mx-auto mt-11 sm:w-full sm:max-w-lg dark:bg-slate-800 p-11 sm:shadow-lg sm:rounded-lg"
class="bg-white shadow sm:mx-auto mt-11 sm:w-full sm:max-w-lg dark:bg-n-solid-2 p-11 sm:shadow-lg sm:rounded-lg"
:class="{
'mb-8 mt-15': !showGoogleOAuth,
'animate-wiggle': loginApi.hasErrored,