From 882498637b47d0726ac16e16873de6f0292ba437 Mon Sep 17 00:00:00 2001 From: mehrzadghdev Date: Wed, 20 Aug 2025 23:28:18 +0330 Subject: [PATCH 1/2] feat: layout padding and scroll added --- src/components/Layout/Layout.tsx | 10 +++++++++- .../api/authorizationAPI.ts | 0 .../api/identityAPI.ts | 0 .../api/userCompletion.ts | 0 .../components/AccountCreated/AccountCreated.tsx | 0 .../AccountCreated/AccountCreatedClubBanner.tsx | 0 .../AccountCreated/AccountCreatedRedirectButton.tsx | 0 .../components/AuthenticationCard.tsx | 0 .../AuthenticationSteps/AuthenticationSteps.tsx | 0 .../AuthenticationSteps/CompleteSignUp.tsx | 0 .../AuthenticationSteps/EnterPasswordForm.tsx | 0 .../AuthenticationSteps/GoogleAuthentication.tsx | 0 .../AuthenticationSteps/LoginRegiserForm.tsx | 0 .../components/AuthenticationSteps/OtpVerifyForm.tsx | 0 .../AuthenticationSteps/VerifyPhoneNumber.tsx | 0 .../components/CountryCodeSelector.tsx | 0 .../components/ForgetPassword/ChangePassword.tsx | 0 .../ForgetPassword/ForgetPasswordContainer.tsx | 0 .../components/ForgetPassword/ForgetPasswordOtp.tsx | 0 .../ForgetPassword/ForgettedPasswordInfo.tsx | 0 .../components/UserCompletionForm/DateOfBirth.tsx | 0 .../components/UserCompletionForm/EmailSection.tsx | 0 .../UserCompletionForm/PasswordSection.tsx | 0 .../UserCompletionForm/PasswordValidation.tsx | 0 .../UserCompletionForm/PersonalInfoFields.tsx | 0 .../components/UserCompletionForm/SubmitSection.tsx | 0 .../{authorization => authentication}/index.ts | 1 + .../routes/AccountCreatedPage.tsx | 0 .../routes/AuthenticationPage.tsx | 0 .../routes/ForgetPasswordPage.tsx | 0 .../routes/UserCompletionPage.tsx | 0 .../types/authTypes.ts | 0 .../types/completionFormApiTypes.ts | 0 .../types/settingForm.ts | 0 .../types/userTypes.ts | 0 src/providers/AuthProvider.tsx | 2 +- src/routes/config.tsx | 12 ++++++++---- 37 files changed, 19 insertions(+), 6 deletions(-) rename src/features/{authorization => authentication}/api/authorizationAPI.ts (100%) rename src/features/{authorization => authentication}/api/identityAPI.ts (100%) rename src/features/{authorization => authentication}/api/userCompletion.ts (100%) rename src/features/{authorization => authentication}/components/AccountCreated/AccountCreated.tsx (100%) rename src/features/{authorization => authentication}/components/AccountCreated/AccountCreatedClubBanner.tsx (100%) rename src/features/{authorization => authentication}/components/AccountCreated/AccountCreatedRedirectButton.tsx (100%) rename src/features/{authorization => authentication}/components/AuthenticationCard.tsx (100%) rename src/features/{authorization => authentication}/components/AuthenticationSteps/AuthenticationSteps.tsx (100%) rename src/features/{authorization => authentication}/components/AuthenticationSteps/CompleteSignUp.tsx (100%) rename src/features/{authorization => authentication}/components/AuthenticationSteps/EnterPasswordForm.tsx (100%) rename src/features/{authorization => authentication}/components/AuthenticationSteps/GoogleAuthentication.tsx (100%) rename src/features/{authorization => authentication}/components/AuthenticationSteps/LoginRegiserForm.tsx (100%) rename src/features/{authorization => authentication}/components/AuthenticationSteps/OtpVerifyForm.tsx (100%) rename src/features/{authorization => authentication}/components/AuthenticationSteps/VerifyPhoneNumber.tsx (100%) rename src/features/{authorization => authentication}/components/CountryCodeSelector.tsx (100%) rename src/features/{authorization => authentication}/components/ForgetPassword/ChangePassword.tsx (100%) rename src/features/{authorization => authentication}/components/ForgetPassword/ForgetPasswordContainer.tsx (100%) rename src/features/{authorization => authentication}/components/ForgetPassword/ForgetPasswordOtp.tsx (100%) rename src/features/{authorization => authentication}/components/ForgetPassword/ForgettedPasswordInfo.tsx (100%) rename src/features/{authorization => authentication}/components/UserCompletionForm/DateOfBirth.tsx (100%) rename src/features/{authorization => authentication}/components/UserCompletionForm/EmailSection.tsx (100%) rename src/features/{authorization => authentication}/components/UserCompletionForm/PasswordSection.tsx (100%) rename src/features/{authorization => authentication}/components/UserCompletionForm/PasswordValidation.tsx (100%) rename src/features/{authorization => authentication}/components/UserCompletionForm/PersonalInfoFields.tsx (100%) rename src/features/{authorization => authentication}/components/UserCompletionForm/SubmitSection.tsx (100%) rename src/features/{authorization => authentication}/index.ts (75%) rename src/features/{authorization => authentication}/routes/AccountCreatedPage.tsx (100%) rename src/features/{authorization => authentication}/routes/AuthenticationPage.tsx (100%) rename src/features/{authorization => authentication}/routes/ForgetPasswordPage.tsx (100%) rename src/features/{authorization => authentication}/routes/UserCompletionPage.tsx (100%) rename src/features/{authorization => authentication}/types/authTypes.ts (100%) rename src/features/{authorization => authentication}/types/completionFormApiTypes.ts (100%) rename src/features/{authorization => authentication}/types/settingForm.ts (100%) rename src/features/{authorization => authentication}/types/userTypes.ts (100%) diff --git a/src/components/Layout/Layout.tsx b/src/components/Layout/Layout.tsx index 55d15b2..befcc88 100644 --- a/src/components/Layout/Layout.tsx +++ b/src/components/Layout/Layout.tsx @@ -44,7 +44,15 @@ export const Layout = () => { setSideNavOpen={setSideNavOpen} user={userInfo} /> - + diff --git a/src/features/authorization/api/authorizationAPI.ts b/src/features/authentication/api/authorizationAPI.ts similarity index 100% rename from src/features/authorization/api/authorizationAPI.ts rename to src/features/authentication/api/authorizationAPI.ts diff --git a/src/features/authorization/api/identityAPI.ts b/src/features/authentication/api/identityAPI.ts similarity index 100% rename from src/features/authorization/api/identityAPI.ts rename to src/features/authentication/api/identityAPI.ts diff --git a/src/features/authorization/api/userCompletion.ts b/src/features/authentication/api/userCompletion.ts similarity index 100% rename from src/features/authorization/api/userCompletion.ts rename to src/features/authentication/api/userCompletion.ts diff --git a/src/features/authorization/components/AccountCreated/AccountCreated.tsx b/src/features/authentication/components/AccountCreated/AccountCreated.tsx similarity index 100% rename from src/features/authorization/components/AccountCreated/AccountCreated.tsx rename to src/features/authentication/components/AccountCreated/AccountCreated.tsx diff --git a/src/features/authorization/components/AccountCreated/AccountCreatedClubBanner.tsx b/src/features/authentication/components/AccountCreated/AccountCreatedClubBanner.tsx similarity index 100% rename from src/features/authorization/components/AccountCreated/AccountCreatedClubBanner.tsx rename to src/features/authentication/components/AccountCreated/AccountCreatedClubBanner.tsx diff --git a/src/features/authorization/components/AccountCreated/AccountCreatedRedirectButton.tsx b/src/features/authentication/components/AccountCreated/AccountCreatedRedirectButton.tsx similarity index 100% rename from src/features/authorization/components/AccountCreated/AccountCreatedRedirectButton.tsx rename to src/features/authentication/components/AccountCreated/AccountCreatedRedirectButton.tsx diff --git a/src/features/authorization/components/AuthenticationCard.tsx b/src/features/authentication/components/AuthenticationCard.tsx similarity index 100% rename from src/features/authorization/components/AuthenticationCard.tsx rename to src/features/authentication/components/AuthenticationCard.tsx diff --git a/src/features/authorization/components/AuthenticationSteps/AuthenticationSteps.tsx b/src/features/authentication/components/AuthenticationSteps/AuthenticationSteps.tsx similarity index 100% rename from src/features/authorization/components/AuthenticationSteps/AuthenticationSteps.tsx rename to src/features/authentication/components/AuthenticationSteps/AuthenticationSteps.tsx diff --git a/src/features/authorization/components/AuthenticationSteps/CompleteSignUp.tsx b/src/features/authentication/components/AuthenticationSteps/CompleteSignUp.tsx similarity index 100% rename from src/features/authorization/components/AuthenticationSteps/CompleteSignUp.tsx rename to src/features/authentication/components/AuthenticationSteps/CompleteSignUp.tsx diff --git a/src/features/authorization/components/AuthenticationSteps/EnterPasswordForm.tsx b/src/features/authentication/components/AuthenticationSteps/EnterPasswordForm.tsx similarity index 100% rename from src/features/authorization/components/AuthenticationSteps/EnterPasswordForm.tsx rename to src/features/authentication/components/AuthenticationSteps/EnterPasswordForm.tsx diff --git a/src/features/authorization/components/AuthenticationSteps/GoogleAuthentication.tsx b/src/features/authentication/components/AuthenticationSteps/GoogleAuthentication.tsx similarity index 100% rename from src/features/authorization/components/AuthenticationSteps/GoogleAuthentication.tsx rename to src/features/authentication/components/AuthenticationSteps/GoogleAuthentication.tsx diff --git a/src/features/authorization/components/AuthenticationSteps/LoginRegiserForm.tsx b/src/features/authentication/components/AuthenticationSteps/LoginRegiserForm.tsx similarity index 100% rename from src/features/authorization/components/AuthenticationSteps/LoginRegiserForm.tsx rename to src/features/authentication/components/AuthenticationSteps/LoginRegiserForm.tsx diff --git a/src/features/authorization/components/AuthenticationSteps/OtpVerifyForm.tsx b/src/features/authentication/components/AuthenticationSteps/OtpVerifyForm.tsx similarity index 100% rename from src/features/authorization/components/AuthenticationSteps/OtpVerifyForm.tsx rename to src/features/authentication/components/AuthenticationSteps/OtpVerifyForm.tsx diff --git a/src/features/authorization/components/AuthenticationSteps/VerifyPhoneNumber.tsx b/src/features/authentication/components/AuthenticationSteps/VerifyPhoneNumber.tsx similarity index 100% rename from src/features/authorization/components/AuthenticationSteps/VerifyPhoneNumber.tsx rename to src/features/authentication/components/AuthenticationSteps/VerifyPhoneNumber.tsx diff --git a/src/features/authorization/components/CountryCodeSelector.tsx b/src/features/authentication/components/CountryCodeSelector.tsx similarity index 100% rename from src/features/authorization/components/CountryCodeSelector.tsx rename to src/features/authentication/components/CountryCodeSelector.tsx diff --git a/src/features/authorization/components/ForgetPassword/ChangePassword.tsx b/src/features/authentication/components/ForgetPassword/ChangePassword.tsx similarity index 100% rename from src/features/authorization/components/ForgetPassword/ChangePassword.tsx rename to src/features/authentication/components/ForgetPassword/ChangePassword.tsx diff --git a/src/features/authorization/components/ForgetPassword/ForgetPasswordContainer.tsx b/src/features/authentication/components/ForgetPassword/ForgetPasswordContainer.tsx similarity index 100% rename from src/features/authorization/components/ForgetPassword/ForgetPasswordContainer.tsx rename to src/features/authentication/components/ForgetPassword/ForgetPasswordContainer.tsx diff --git a/src/features/authorization/components/ForgetPassword/ForgetPasswordOtp.tsx b/src/features/authentication/components/ForgetPassword/ForgetPasswordOtp.tsx similarity index 100% rename from src/features/authorization/components/ForgetPassword/ForgetPasswordOtp.tsx rename to src/features/authentication/components/ForgetPassword/ForgetPasswordOtp.tsx diff --git a/src/features/authorization/components/ForgetPassword/ForgettedPasswordInfo.tsx b/src/features/authentication/components/ForgetPassword/ForgettedPasswordInfo.tsx similarity index 100% rename from src/features/authorization/components/ForgetPassword/ForgettedPasswordInfo.tsx rename to src/features/authentication/components/ForgetPassword/ForgettedPasswordInfo.tsx diff --git a/src/features/authorization/components/UserCompletionForm/DateOfBirth.tsx b/src/features/authentication/components/UserCompletionForm/DateOfBirth.tsx similarity index 100% rename from src/features/authorization/components/UserCompletionForm/DateOfBirth.tsx rename to src/features/authentication/components/UserCompletionForm/DateOfBirth.tsx diff --git a/src/features/authorization/components/UserCompletionForm/EmailSection.tsx b/src/features/authentication/components/UserCompletionForm/EmailSection.tsx similarity index 100% rename from src/features/authorization/components/UserCompletionForm/EmailSection.tsx rename to src/features/authentication/components/UserCompletionForm/EmailSection.tsx diff --git a/src/features/authorization/components/UserCompletionForm/PasswordSection.tsx b/src/features/authentication/components/UserCompletionForm/PasswordSection.tsx similarity index 100% rename from src/features/authorization/components/UserCompletionForm/PasswordSection.tsx rename to src/features/authentication/components/UserCompletionForm/PasswordSection.tsx diff --git a/src/features/authorization/components/UserCompletionForm/PasswordValidation.tsx b/src/features/authentication/components/UserCompletionForm/PasswordValidation.tsx similarity index 100% rename from src/features/authorization/components/UserCompletionForm/PasswordValidation.tsx rename to src/features/authentication/components/UserCompletionForm/PasswordValidation.tsx diff --git a/src/features/authorization/components/UserCompletionForm/PersonalInfoFields.tsx b/src/features/authentication/components/UserCompletionForm/PersonalInfoFields.tsx similarity index 100% rename from src/features/authorization/components/UserCompletionForm/PersonalInfoFields.tsx rename to src/features/authentication/components/UserCompletionForm/PersonalInfoFields.tsx diff --git a/src/features/authorization/components/UserCompletionForm/SubmitSection.tsx b/src/features/authentication/components/UserCompletionForm/SubmitSection.tsx similarity index 100% rename from src/features/authorization/components/UserCompletionForm/SubmitSection.tsx rename to src/features/authentication/components/UserCompletionForm/SubmitSection.tsx diff --git a/src/features/authorization/index.ts b/src/features/authentication/index.ts similarity index 75% rename from src/features/authorization/index.ts rename to src/features/authentication/index.ts index 7f380b6..ae0aa8e 100644 --- a/src/features/authorization/index.ts +++ b/src/features/authentication/index.ts @@ -1,3 +1,4 @@ export * from './routes/AuthenticationPage'; export * from './routes/ForgetPasswordPage'; export * from './routes/UserCompletionPage'; +export * from './routes/AccountCreatedPage'; diff --git a/src/features/authorization/routes/AccountCreatedPage.tsx b/src/features/authentication/routes/AccountCreatedPage.tsx similarity index 100% rename from src/features/authorization/routes/AccountCreatedPage.tsx rename to src/features/authentication/routes/AccountCreatedPage.tsx diff --git a/src/features/authorization/routes/AuthenticationPage.tsx b/src/features/authentication/routes/AuthenticationPage.tsx similarity index 100% rename from src/features/authorization/routes/AuthenticationPage.tsx rename to src/features/authentication/routes/AuthenticationPage.tsx diff --git a/src/features/authorization/routes/ForgetPasswordPage.tsx b/src/features/authentication/routes/ForgetPasswordPage.tsx similarity index 100% rename from src/features/authorization/routes/ForgetPasswordPage.tsx rename to src/features/authentication/routes/ForgetPasswordPage.tsx diff --git a/src/features/authorization/routes/UserCompletionPage.tsx b/src/features/authentication/routes/UserCompletionPage.tsx similarity index 100% rename from src/features/authorization/routes/UserCompletionPage.tsx rename to src/features/authentication/routes/UserCompletionPage.tsx diff --git a/src/features/authorization/types/authTypes.ts b/src/features/authentication/types/authTypes.ts similarity index 100% rename from src/features/authorization/types/authTypes.ts rename to src/features/authentication/types/authTypes.ts diff --git a/src/features/authorization/types/completionFormApiTypes.ts b/src/features/authentication/types/completionFormApiTypes.ts similarity index 100% rename from src/features/authorization/types/completionFormApiTypes.ts rename to src/features/authentication/types/completionFormApiTypes.ts diff --git a/src/features/authorization/types/settingForm.ts b/src/features/authentication/types/settingForm.ts similarity index 100% rename from src/features/authorization/types/settingForm.ts rename to src/features/authentication/types/settingForm.ts diff --git a/src/features/authorization/types/userTypes.ts b/src/features/authentication/types/userTypes.ts similarity index 100% rename from src/features/authorization/types/userTypes.ts rename to src/features/authentication/types/userTypes.ts diff --git a/src/providers/AuthProvider.tsx b/src/providers/AuthProvider.tsx index 7add190..24bf1e2 100644 --- a/src/providers/AuthProvider.tsx +++ b/src/providers/AuthProvider.tsx @@ -1,6 +1,6 @@ // useAuth.tsx import { AuthContext, type UserInfo } from '@/contexts/AuthContext'; -import type { GenerateTokenResponse } from '@/features/authorization/api/identityAPI'; +import type { GenerateTokenResponse } from '@/features/authentication/api/identityAPI'; import axios from 'axios'; import { useEffect, useState, type ReactNode } from 'react'; import { jwtDecode } from 'jwt-decode'; diff --git a/src/routes/config.tsx b/src/routes/config.tsx index e1e0e01..ca878f5 100644 --- a/src/routes/config.tsx +++ b/src/routes/config.tsx @@ -1,6 +1,5 @@ import { Layout } from '@/components'; import { NavigateWithToast } from '@/components/NavigateWithToast'; -import { AccountCreatedPage } from '@/features/authorization/routes/AccountCreatedPage'; import { Calendar, Devices, @@ -18,17 +17,22 @@ import { lazy, type ReactNode } from 'react'; import { Navigate } from 'react-router-dom'; const AuthenticationPage = lazy(() => - import('@/features/authorization').then((module) => ({ + import('@/features/authentication').then((module) => ({ default: module.AuthenticationPage, })), ); +const AccountCreatedPage = lazy(() => + import('@/features/authentication').then((module) => ({ + default: module.AccountCreatedPage, + })), +); const UserCompletionPage = lazy(() => - import('@/features/authorization').then((module) => ({ + import('@/features/authentication').then((module) => ({ default: module.UserCompletionPage, })), ); const ForgetPasswordPage = lazy(() => - import('@/features/authorization').then((module) => ({ + import('@/features/authentication').then((module) => ({ default: module.ForgetPasswordPage, })), ); From d56eb2e4ffa6a790caddac8c65d2faa84859dc2b Mon Sep 17 00:00:00 2001 From: mehrzadghdev Date: Wed, 20 Aug 2025 23:39:21 +0330 Subject: [PATCH 2/2] fix: recent timer button removed --- .../AuthenticationSteps/OtpVerifyForm.tsx | 24 ++++++++++++------- .../AuthenticationSteps/VerifyPhoneNumber.tsx | 24 ++++++++++++------- .../ForgetPassword/ForgetPasswordOtp.tsx | 24 ++++++++++++------- 3 files changed, 48 insertions(+), 24 deletions(-) diff --git a/src/features/authentication/components/AuthenticationSteps/OtpVerifyForm.tsx b/src/features/authentication/components/AuthenticationSteps/OtpVerifyForm.tsx index 9ea59d9..006e0c5 100644 --- a/src/features/authentication/components/AuthenticationSteps/OtpVerifyForm.tsx +++ b/src/features/authentication/components/AuthenticationSteps/OtpVerifyForm.tsx @@ -213,20 +213,28 @@ export function OtpVerifyForm({ sx={{ justifyContent: 'center', alignItems: 'center', - mt: 1.5, + mt: 2.5, }} > {t('verify.resendCodeIn')} - + + + {canResend && ( + + )} ); diff --git a/src/features/authentication/components/AuthenticationSteps/VerifyPhoneNumber.tsx b/src/features/authentication/components/AuthenticationSteps/VerifyPhoneNumber.tsx index d58553f..c629924 100644 --- a/src/features/authentication/components/AuthenticationSteps/VerifyPhoneNumber.tsx +++ b/src/features/authentication/components/AuthenticationSteps/VerifyPhoneNumber.tsx @@ -140,20 +140,28 @@ export function VerifyPhoneNumber({ sx={{ justifyContent: 'center', alignItems: 'center', - mt: 1.5, + mt: 2.5, }} > {t('verify.resendCodeIn')} - + + + {canResend && ( + + )} ); diff --git a/src/features/authentication/components/ForgetPassword/ForgetPasswordOtp.tsx b/src/features/authentication/components/ForgetPassword/ForgetPasswordOtp.tsx index bd1afea..34596d4 100644 --- a/src/features/authentication/components/ForgetPassword/ForgetPasswordOtp.tsx +++ b/src/features/authentication/components/ForgetPassword/ForgetPasswordOtp.tsx @@ -171,20 +171,28 @@ export function ForgetPasswordOtp({ sx={{ justifyContent: 'center', alignItems: 'center', - mt: 1.5, + mt: 2.5, }} > {t('verify.resendCodeIn')} - + + + {canResend && ( + + )} );