From 4e6a9a79c00246dc4e1c793e9bd88be06137e116 Mon Sep 17 00:00:00 2001 From: Lvyshnevska Date: Sat, 19 Oct 2024 18:01:28 +0200 Subject: [PATCH 01/12] login desktop styles updated --- FrontEnd/src/global.css | 9 +- .../pages/Authorization/AuthorizationPage.jsx | 6 - .../AuthorizationPage.module.css | 36 +--- .../src/pages/Authorization/EyeVisible.jsx | 4 +- .../src/pages/Authorization/LoginPage.jsx | 48 ++--- .../pages/Authorization/LoginPage.module.css | 187 ++++++++---------- .../Authorization/SignUpInvitation.module.css | 19 +- 7 files changed, 133 insertions(+), 176 deletions(-) diff --git a/FrontEnd/src/global.css b/FrontEnd/src/global.css index 18708495a..83d6606ee 100644 --- a/FrontEnd/src/global.css +++ b/FrontEnd/src/global.css @@ -44,10 +44,12 @@ --delete-text-color: #F15831; --notification-text-color: #F34444; --footer-dark-text-color: #A0ABC0; + --link-text-color-new: #000000; + --error-text-color-new: #F15831; /* button color*/ --main-button-color: #1F9A7C; - --button-color-hover: #0b6c61 ; + --button-color-hover: #0b6c61; --light-button-color: #FFFFFF; /* fonts */ @@ -55,10 +57,11 @@ --font-messages: 'Roboto', sans-serif; --font-error: 'Roboto', sans-serif; --font-logo: 'Geologica', sans-serif; + --font-main-new: 'Geologica', sans-serif; --toastify-color-error: #FFF1F0; --toastify-color-success: #F1FFF7; - --toastify-font-family: var(--font-main); + --toastify-font-family: var(--font-main-new); --toastify-close-button: rgba(0, 0, 0, 0.85); --toastify-toast-width: 395px; --toastify-toast-min-height: 22px; @@ -111,7 +114,7 @@ --character-title-85: rgba(0, 0, 0, 0.85); --wf-base-white: #FFF; - + --profile-min-height-block: calc(100vh - 565px); --min-height-block-main: calc(100vh - 305px); --company-card-color: #FFF; diff --git a/FrontEnd/src/pages/Authorization/AuthorizationPage.jsx b/FrontEnd/src/pages/Authorization/AuthorizationPage.jsx index 9631d6b4e..4d9c16315 100644 --- a/FrontEnd/src/pages/Authorization/AuthorizationPage.jsx +++ b/FrontEnd/src/pages/Authorization/AuthorizationPage.jsx @@ -5,12 +5,6 @@ const AuthorizationPage = () => { return (
- dots_7x6.png - dots_7x6.png
); diff --git a/FrontEnd/src/pages/Authorization/AuthorizationPage.module.css b/FrontEnd/src/pages/Authorization/AuthorizationPage.module.css index c7788d9ce..fa3f419a6 100644 --- a/FrontEnd/src/pages/Authorization/AuthorizationPage.module.css +++ b/FrontEnd/src/pages/Authorization/AuthorizationPage.module.css @@ -1,30 +1,8 @@ .auth-page { - display: flex; - width: var(--main-block-size); - min-height: var(--min-height-block-main); - flex-shrink: 0; - background: #f1fff7; - } - - .frame-img-left { - width: 179px; - height: 150px; - display: inline-flex; - flex-direction: column; - align-items: flex-start; - gap: 24px; - margin: 422px 979px 153px 354px; - position: absolute; - } - - .frame-img-right { - width: 179px; - height: 150px; - display: inline-flex; - flex-direction: column; - align-items: flex-start; - gap: 24px; - margin: 102px 354px 473px 979px; - position: absolute; - } - \ No newline at end of file + display: flex; + width: var(--main-block-size); + min-height: var(--min-height-block-main); + flex-shrink: 0; + background: #F9F5EC; + ; +} diff --git a/FrontEnd/src/pages/Authorization/EyeVisible.jsx b/FrontEnd/src/pages/Authorization/EyeVisible.jsx index c8b285549..07c2d5e77 100644 --- a/FrontEnd/src/pages/Authorization/EyeVisible.jsx +++ b/FrontEnd/src/pages/Authorization/EyeVisible.jsx @@ -2,8 +2,8 @@ const EyeVisible = () => { return ( - - + + ); }; diff --git a/FrontEnd/src/pages/Authorization/LoginPage.jsx b/FrontEnd/src/pages/Authorization/LoginPage.jsx index ca91560b6..f2ccdc77d 100644 --- a/FrontEnd/src/pages/Authorization/LoginPage.jsx +++ b/FrontEnd/src/pages/Authorization/LoginPage.jsx @@ -4,6 +4,7 @@ import { useNavigate, Link } from 'react-router-dom'; import axios from 'axios'; import { useStopwatch } from 'react-timer-hook'; import { toast } from 'react-toastify'; +import classNames from 'classnames'; import validator from 'validator'; import EyeVisible from './EyeVisible'; @@ -29,7 +30,7 @@ const LoginContent = () => { const errorMessageTemplates = { required: 'Обов’язкове поле', - email: 'Електронна пошта не відповідає вимогам', + email: 'Введіть адресу електронної пошти у форматі name@example.com', unspecifiedError: 'Електронна пошта чи пароль вказані некоректно', rateError: 'Небезпечні дії на сторінці. Сторінка заблокована на 10 хвилин', blockedUserError: 'Профіль компанії було заблоковано внаслідок розміщення неприйнятного контенту', @@ -137,13 +138,13 @@ const LoginContent = () => { }; useEffect(() => {}, [disabled]); - + console.log('ERRORS', errors); return (

Вхід на платформу

-
+
@@ -157,12 +158,15 @@ const LoginContent = () => { > Електронна пошта -
+
@@ -186,13 +190,17 @@ const LoginContent = () => { > Пароль -
+
{
- - {errors.password && errors.password.message} - {errors.required && errors.required.message} - {errors.unspecifiedError && errors.unspecifiedError.message} - +
+ + {errors.password && errors.password.message} + {errors.required && errors.required.message} + {errors.unspecifiedError && errors.unspecifiedError.message} + + + Забули пароль? + +
- - Забули пароль? -
- - -
-
- - {errors.password && errors.password.message} - {errors.required && errors.required.message} - {errors.unspecifiedError && errors.unspecifiedError.message} - - - Забули пароль? - -
-
-
-
-
-
- + +
+
+

Вперше на нашому сайті?

+ Зареєструйтесь
- - +
); }; diff --git a/FrontEnd/src/pages/Authorization/LoginPage.module.css b/FrontEnd/src/pages/Authorization/LoginPage.module.css index c03bce032..fbd983960 100644 --- a/FrontEnd/src/pages/Authorization/LoginPage.module.css +++ b/FrontEnd/src/pages/Authorization/LoginPage.module.css @@ -1,6 +1,26 @@ +.login-page { + display: flex; + justify-content: center; + width: 100vw; + min-height: var(--min-height-block-main); + flex-shrink: 0; + background: var(--light-seashell-background); + padding: 80px 0; +} + +.login { + display: flex; + align-self: center; + flex-direction: column; + align-items: center; + max-width: 572px; + min-width: 345px; + gap: 24px; +} + .login-basic { display: flex; - width: 572px; + width: 375px; flex-direction: column; align-items: flex-start; border-radius: 2px; @@ -273,8 +293,54 @@ input:-webkit-autofill { -webkit-text-fill-color: var(--main-text-color) !important; } -@media only screen and (max-width: 767px) { +.login-signup-invitation { + display: flex; + align-items: flex-start; + gap: 8px; + background: var(--light-seashell-background); +} + +.login-signup-invitation p { + margin: 0; + color: var(--link-text-color); + font-feature-settings: "calt" off; + font-family: var(--font-main); + font-size: 14px; + font-style: normal; + font-weight: 400; + line-height: 22px; + letter-spacing: -0.14px; +} + +.login-signup-invitation a { + color: var(--link-text-color); + font-feature-settings: "calt" off; + font-family: var(--font-main); + font-size: 14px; + font-style: normal; + font-weight: 600; + line-height: 22px; + letter-spacing: -0.14px; + text-decoration-line: underline; + text-decoration-thickness: 1%; +} + +.login-signup-invitation a:focus { + outline: none; +} + +@media only screen and (min-width: 768px) { + .login-page { + padding: 104px 0; + } + .login-basic { - width: 375px; + width: 572px; + } +} + +@media only screen and (min-width: 1512px) { + .login-page { + padding: 120px 0; } } diff --git a/FrontEnd/src/pages/Authorization/SignUpInvitation.jsx b/FrontEnd/src/pages/Authorization/SignUpInvitation.jsx deleted file mode 100644 index bae4e21ec..000000000 --- a/FrontEnd/src/pages/Authorization/SignUpInvitation.jsx +++ /dev/null @@ -1,13 +0,0 @@ -import { Link } from 'react-router-dom'; -import classes from './SignUpInvitation.module.css'; - -const SignUpInvitation = () => { - return ( -
-

Вперше на нашому сайті?

- Зареєструйтесь -
- ); -}; - -export default SignUpInvitation; diff --git a/FrontEnd/src/pages/Authorization/SignUpInvitation.module.css b/FrontEnd/src/pages/Authorization/SignUpInvitation.module.css deleted file mode 100644 index fd4c4fba8..000000000 --- a/FrontEnd/src/pages/Authorization/SignUpInvitation.module.css +++ /dev/null @@ -1,34 +0,0 @@ -.signup-invitation { - display: flex; - align-items: flex-start; - gap: 8px; -} - -.signup-invitation p { - margin: 0; - color: var(--link-text-color); - font-feature-settings: "calt" off; - font-family: var(--font-main); - font-size: 14px; - font-style: normal; - font-weight: 400; - line-height: 22px; - letter-spacing: -0.14px; -} - -.signup-invitation a { - color: var(--link-text-color); - font-feature-settings: "calt" off; - font-family: var(--font-main); - font-size: 14px; - font-style: normal; - font-weight: 600; - line-height: 22px; - letter-spacing: -0.14px; - text-decoration-line: underline; - text-decoration-thickness: 1%; -} - -.signup-invitation a:focus { - outline: none; -} diff --git a/FrontEnd/src/pages/SignUp/SignUp/ActivateProfilePage.jsx b/FrontEnd/src/pages/SignUp/SignUp/ActivateProfilePage.jsx index de99125a0..c98cf2054 100644 --- a/FrontEnd/src/pages/SignUp/SignUp/ActivateProfilePage.jsx +++ b/FrontEnd/src/pages/SignUp/SignUp/ActivateProfilePage.jsx @@ -1,7 +1,7 @@ import React, { useState, useEffect } from 'react'; import axios from 'axios'; import { useParams } from 'react-router-dom'; -import AuthorizationPage from '../../../pages/Authorization/AuthorizationPage'; +import LoginPage from '../../../pages/Authorization/LoginPage'; import styles from './ActivateProfileModal.module.css'; export function ActivationProfilePage() { @@ -37,7 +37,7 @@ export function ActivationProfilePage() { return (
- + {modalVisible && (
diff --git a/FrontEnd/src/routes/ClientRouter.jsx b/FrontEnd/src/routes/ClientRouter.jsx index 4598d5854..311c4fdce 100644 --- a/FrontEnd/src/routes/ClientRouter.jsx +++ b/FrontEnd/src/routes/ClientRouter.jsx @@ -6,7 +6,7 @@ import { SWRConfig } from 'swr'; import 'react-toastify/dist/ReactToastify.css'; import customTheme from '../pages/CustomThemes/customTheme.js'; -import AuthorizationPage from '../pages/Authorization/AuthorizationPage'; +import LoginPage from '../pages/Authorization/LoginPage'; import CookiesPolicyComponent from '../pages/CookiesPolicyPage/CookiesPolicyComponent'; import Footer from '../components/Footer/Footer'; import Header from '../components/Header/Header'; @@ -68,7 +68,7 @@ function ClientRouter() { {isAuth ? ( } /> ) : ( - } /> + } /> )} {isAuth ? (