Skip to content

Commit db56602

Browse files
committed
client: fixed code, added storybook, fixed auth forms
1 parent df685a9 commit db56602

File tree

13 files changed

+47
-53
lines changed

13 files changed

+47
-53
lines changed

client/src/app/styles/scss/vars.scss

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -23,7 +23,7 @@
2323
--z-index-modal: 10;
2424

2525
/* Цвета */
26-
--overlay: rgb(0 0 0 / 0.5);
26+
--overlay: rgba(0 0 0 / 0.5);
2727
--red-light: #ff0000;
2828
--red-dark: #c50a0a;
2929
--color-error: #ff0000;

client/src/features/auth/ui/LoginForm/LoginForm.module.scss

Whitespace-only changes.

client/src/features/auth/ui/RegisterForm/RegisterForm.module.scss

Whitespace-only changes.

client/src/features/auth/ui/RegisterForm/RegisterForm.tsx

Lines changed: 1 addition & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -3,8 +3,6 @@ import { memo } from 'react';
33
import { useRegisterForm } from '@/features/auth/model/hooks/useRegisterForm.ts';
44
import { Button, Checkbox, Form, Input, Typography } from '@/shared/ui';
55

6-
import styles from './RegisterForm.module.scss';
7-
86
interface RegisterFormProps {
97
onSwap: () => void;
108
}
@@ -17,7 +15,7 @@ export const RegisterForm = memo(({ onSwap }: RegisterFormProps) => {
1715
} = form;
1816

1917
return (
20-
<Form onSubmit={onSubmit} className={styles.form}>
18+
<Form onSubmit={onSubmit}>
2119
<Typography tag='h2' variant='bold_24'>
2220
Registration
2321
</Typography>

client/src/features/journey/ui/Journey.module.scss

Whitespace-only changes.

client/src/pages/ErrorPage/ui/ErrorPage/ErrorPage.module.scss

Lines changed: 0 additions & 3 deletions
This file was deleted.
Lines changed: 1 addition & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,5 @@
1-
import styles from './ErrorPage.module.scss';
2-
31
const ErrorPage = () => {
4-
return <div className={styles.error}>404</div>;
2+
return <div>404</div>;
53
};
64

75
export default ErrorPage;

client/src/shared/ui/Checkbox/Checkbox.module.scss

Lines changed: 22 additions & 21 deletions
Original file line numberDiff line numberDiff line change
@@ -12,27 +12,6 @@
1212
cursor: pointer;
1313
opacity: 0;
1414
}
15-
16-
input[type='checkbox']:checked + .checkmark {
17-
border-color: var(--color-primary);
18-
background-color: var(--color-primary);
19-
}
20-
21-
input[type='checkbox']:checked + .checkmark:after {
22-
display: block;
23-
}
24-
25-
&.disabled {
26-
cursor: not-allowed;
27-
28-
.checkmark {
29-
background-color: var(--color-primary-light);
30-
}
31-
32-
.text {
33-
color: rgb(0 0 0 / 0.25);
34-
}
35-
}
3615
}
3716

3817
.checkmark {
@@ -91,3 +70,25 @@
9170
.text {
9271
margin-left: 5px;
9372
}
73+
74+
75+
.wrapper .disabled {
76+
cursor: not-allowed;
77+
78+
.checkmark {
79+
background-color: var(--color-primary-light);
80+
}
81+
82+
.text {
83+
color: rgba(0 0 0 / 0.25);
84+
}
85+
}
86+
87+
input[type='checkbox']:checked + .checkmark {
88+
border-color: var(--color-primary);
89+
background-color: var(--color-primary);
90+
}
91+
92+
input[type='checkbox']:checked + .checkmark:after {
93+
display: block;
94+
}

client/src/shared/ui/Input/Input.module.scss

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
.inputWrapper {
1+
.input_wrapper {
22
display: flex;
33
flex-direction: column;
44
gap: 4px;
@@ -36,7 +36,7 @@
3636

3737
.input:focus {
3838
border-color: #2563eb;
39-
box-shadow: 0 0 0 2px rgb(37 99 235 / 0.2);
39+
box-shadow: 0 0 0 2px rgba(37 99 235 / 0.2);
4040
}
4141

4242

client/src/shared/ui/Input/Input.tsx

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -16,7 +16,7 @@ export const Input = memo((props: InputProps) => {
1616
const id = useId();
1717

1818
return (
19-
<div className={clsx(styles.inputWrapper, className)}>
19+
<div className={clsx(styles.input_wrapper, className)}>
2020
{label && (
2121
<label htmlFor={id} className={styles.label}>
2222
{label}

0 commit comments

Comments
 (0)