ui
This commit is contained in:
1 parent
0f26648855
commit
a053386f4a
4 files changed
+78
-3
No files matched your search
@@ -0,0 +1,43 @@
|
|||||||
|
import { BaseAuthPage } from "@/Components/v2/design-elements";
|
||||||
|
import { Button, TextField } from "@/Components/v2/inputs";
|
||||||
|
|
||||||
|
import { useTranslation } from "react-i18next";
|
||||||
|
const RegisterPage = () => {
|
||||||
|
const { t } = useTranslation();
|
||||||
|
return (
|
||||||
|
<BaseAuthPage
|
||||||
|
component="form"
|
||||||
|
title={t("pages.auth.register.title")}
|
||||||
|
subtitle={t("pages.auth.register.subtitle")}
|
||||||
|
>
|
||||||
|
<TextField
|
||||||
|
fieldLabel={t("pages.auth.register.form.option.name.label")}
|
||||||
|
placeholder={t("pages.auth.register.form.option.name.placeholder")}
|
||||||
|
/>
|
||||||
|
<TextField
|
||||||
|
fieldLabel={t("pages.auth.register.form.option.surname.label")}
|
||||||
|
placeholder={t("pages.auth.register.form.option.surname.placeholder")}
|
||||||
|
/>
|
||||||
|
<TextField
|
||||||
|
fieldLabel={t("pages.auth.common.form.option.email.label")}
|
||||||
|
placeholder={t("pages.auth.common.form.option.email.placeholder")}
|
||||||
|
/>
|
||||||
|
<TextField
|
||||||
|
fieldLabel={t("pages.auth.common.form.option.password.label")}
|
||||||
|
placeholder={t("pages.auth.common.form.option.password.placeholder")}
|
||||||
|
/>
|
||||||
|
<TextField
|
||||||
|
fieldLabel={t("pages.auth.common.form.option.confirmPassword.label")}
|
||||||
|
placeholder={t("pages.auth.common.form.option.password.placeholder")}
|
||||||
|
/>
|
||||||
|
<Button
|
||||||
|
variant="contained"
|
||||||
|
type="submit"
|
||||||
|
>
|
||||||
|
{t("pages.auth.register.submit")}
|
||||||
|
</Button>
|
||||||
|
</BaseAuthPage>
|
||||||
|
);
|
||||||
|
};
|
||||||
|
|
||||||
|
export default RegisterPage;
|
||||||
File renamed without changes.
@@ -9,7 +9,8 @@ import NotFound from "../Pages/NotFound/index.jsx";
|
|||||||
|
|
||||||
// Auth
|
// Auth
|
||||||
import AuthLogin from "../Pages/Auth/Login";
|
import AuthLogin from "../Pages/Auth/Login";
|
||||||
import AuthRegister from "../Pages/Auth/Register/index.jsx";
|
import AuthRegister from "@/Pages/Auth/Register";
|
||||||
|
import OldAuthRegister from "../Pages/Auth/Register/old.jsx";
|
||||||
import AuthForgotPassword from "@/Pages/Auth/Recovery";
|
import AuthForgotPassword from "@/Pages/Auth/Recovery";
|
||||||
import AuthCheckEmail from "../Pages/Auth/CheckEmail.jsx";
|
import AuthCheckEmail from "../Pages/Auth/CheckEmail.jsx";
|
||||||
import AuthSetNewPassword from "../Pages/Auth/SetNewPassword.jsx";
|
import AuthSetNewPassword from "../Pages/Auth/SetNewPassword.jsx";
|
||||||
@@ -62,7 +63,8 @@ import CreateMonitor from "@/Pages/CreateMonitor";
|
|||||||
|
|
||||||
const Routes = () => {
|
const Routes = () => {
|
||||||
const mode = useSelector((state) => state.ui.mode);
|
const mode = useSelector((state) => state.ui.mode);
|
||||||
const AdminCheckedRegister = withAdminCheck(AuthRegister);
|
// const AdminCheckedRegister = withAdminCheck(AuthRegister);
|
||||||
|
const AdminCheckedRegister = AuthRegister;
|
||||||
const v2theme = mode === "light" ? lightTheme : darkTheme;
|
const v2theme = mode === "light" ? lightTheme : darkTheme;
|
||||||
return (
|
return (
|
||||||
<LibRoutes>
|
<LibRoutes>
|
||||||
@@ -372,7 +374,17 @@ const Routes = () => {
|
|||||||
|
|
||||||
<Route
|
<Route
|
||||||
path="/register"
|
path="/register"
|
||||||
element={<AdminCheckedRegister />}
|
element={
|
||||||
|
<>
|
||||||
|
<ThemeProvider theme={v2theme}>
|
||||||
|
<AdminCheckedRegister />
|
||||||
|
</ThemeProvider>
|
||||||
|
</>
|
||||||
|
}
|
||||||
|
/>
|
||||||
|
<Route
|
||||||
|
path="/register-old"
|
||||||
|
element={<OldAuthRegister />}
|
||||||
/>
|
/>
|
||||||
|
|
||||||
<Route
|
<Route
|
||||||
|
|||||||
@@ -509,6 +509,9 @@
|
|||||||
"password": {
|
"password": {
|
||||||
"label": "Password",
|
"label": "Password",
|
||||||
"placeholder": "********"
|
"placeholder": "********"
|
||||||
|
},
|
||||||
|
"confirmPassword": {
|
||||||
|
"label": "Confirm password"
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@@ -528,6 +531,23 @@
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
|
"register": {
|
||||||
|
"title": "Welcome back to Checkmate!",
|
||||||
|
"subtitle": "Sign up to get started",
|
||||||
|
"submit": "Register",
|
||||||
|
"form": {
|
||||||
|
"option": {
|
||||||
|
"name": {
|
||||||
|
"label": "Name",
|
||||||
|
"placeholder": "Your name"
|
||||||
|
},
|
||||||
|
"surname": {
|
||||||
|
"label": "Surname",
|
||||||
|
"placeholder": "Your surname"
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
},
|
||||||
"forgotPassword": {
|
"forgotPassword": {
|
||||||
"title": "Forgot your password?",
|
"title": "Forgot your password?",
|
||||||
"subtitle": "No worries, we'll send you reset instructions.",
|
"subtitle": "No worries, we'll send you reset instructions.",
|
||||||
|
|||||||
Reference in new issue
Block a user