Conversation
4300a1e to
f8ba6a5
Compare
f8ba6a5 to
dff13e4
Compare
| --minWidth: 700px; | ||
| --minHeight: 300px; |
There was a problem hiding this comment.
why do you need those --
| border: 1px solid ${({ theme }) => theme.colorCancel}; | ||
| background-color: ${({ theme }) => theme.colorCancel}; | ||
| transition: ${({ theme }) => theme.btnTransition}; |
There was a problem hiding this comment.
you also can use a function with the theme here, if you need to return three styles in one func
${({ theme }) =>border: 1px solid ${theme.colorCancel};
background-color: ${theme.colorCancel};
transition: ${theme.btnTransition}};
|
|
||
|
|
||
|
|
||
| return ( |
| <Wrapper> | ||
| <Root> | ||
| <BtnWrapper> | ||
| {location.pathname !== paths.newUser && <BackButton onClick={() => navigate(-1)} > back</BackButton>} |
There was a problem hiding this comment.
it's better to use goBack()
|
|
||
| &:hover { | ||
| transition: ${({ theme }) => theme.btnTransition}; | ||
| background-color: ${({ color, theme }) => color === 'cancel' ? theme.colorError : theme.colorAcceptLight}; |
There was a problem hiding this comment.
do you have a line characters limit? like 80?
| <> | ||
| { | ||
| isAuth ? ( | ||
| <Navigate to={paths.todos} /> |
| const navigate = useNavigate(); | ||
|
|
||
| if (isAuth) { | ||
| navigate('/todos'); |
There was a problem hiding this comment.
here you can use path variable too
| const docSnap = await getDocs(collection(db, 'todos')); | ||
| const data: ITodo[] = []; | ||
| docSnap.forEach(doc => { | ||
| // @ts-ignore |
There was a problem hiding this comment.
why you need to ignore smth here
There was a problem hiding this comment.
I think you can add types for getDocs or docSnap
| }); | ||
|
|
||
|
|
||
| // export const { } = todoSlice.actions; |
| ? await createUserWithEmailAndPassword(auth, uEmail, uPassword) | ||
| : await signInWithEmailAndPassword(auth, uEmail, uPassword); | ||
|
|
||
| // @ts-ignore |
There was a problem hiding this comment.
why? I think you can add some checker here (google TypeGuard)
No description provided.