Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

#7308 fix : use "hidden" css property to toggle b/w Login & Forgot Password #7323

Merged
merged 4 commits into from
May 7, 2024
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
21 changes: 9 additions & 12 deletions src/Components/Auth/Login.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -13,6 +13,7 @@ import ReactMarkdown from "react-markdown";
import rehypeRaw from "rehype-raw";
import { useAuthContext } from "../../Common/hooks/useAuthUser";
import FiltersCache from "../../Utils/FiltersCache";
import { classNames } from "../../Utils/utils";

export const Login = (props: { forgot?: boolean }) => {
const { signIn } = useAuthContext();
Expand Down Expand Up @@ -276,12 +277,10 @@ export const Login = (props: { forgot?: boolean }) => {

<div className="relative flex h-full w-full items-center">
<div
className={
"w-full transition-all " +
(!forgotPassword
? "visible -translate-x-0 opacity-100"
: "invisible -translate-x-5 opacity-0")
}
className={classNames(
"w-full transition-all",
forgotPassword && "hidden",
)}
>
<div className="mb-8 w-[300px] text-4xl font-black text-primary-600">
{t("auth_login_title")}
Expand Down Expand Up @@ -353,12 +352,10 @@ export const Login = (props: { forgot?: boolean }) => {
</div>

<div
className={
"absolute w-full transition-all " +
(forgotPassword
? "visible translate-x-0 opacity-100"
: "invisible translate-x-5 opacity-0")
}
className={classNames(
"w-full transition-all",
!forgotPassword && "hidden",
)}
>
<button
onClick={() => {
Expand Down
Loading