9 files changed
+122
-124
No files matched your search
Binary file not shown.
|
After Width: | Height: | Size: 2.8 MiB |
Binary file not shown.
|
Before Width: | Height: | Size: 89 KiB |
@@ -114,7 +114,7 @@ const QuickConnectButton = (props: LoadingButtonProps) => {
|
|||||||
style={{ flex: 1 }}
|
style={{ flex: 1 }}
|
||||||
onClick={initQuickConnect.mutate}
|
onClick={initQuickConnect.mutate}
|
||||||
>
|
>
|
||||||
Quick Connect
|
Use Quick Connect
|
||||||
</LoadingButton>
|
</LoadingButton>
|
||||||
<Dialog
|
<Dialog
|
||||||
open={Boolean(quickConnectCode)}
|
open={Boolean(quickConnectCode)}
|
||||||
|
|||||||
@@ -262,8 +262,8 @@ export const Route = createRootRouteWithContext<ApiContext>()({
|
|||||||
<AppBar />
|
<AppBar />
|
||||||
<AudioPlayer />
|
<AudioPlayer />
|
||||||
<Outlet />
|
<Outlet />
|
||||||
{/* <ReactQueryDevtools /> */}
|
<ReactQueryDevtools />
|
||||||
{/* <TanStackRouterDevtools /> */}
|
<TanStackRouterDevtools />
|
||||||
</SnackbarProvider>
|
</SnackbarProvider>
|
||||||
</ThemeProvider>
|
</ThemeProvider>
|
||||||
</Suspense>
|
</Suspense>
|
||||||
|
|||||||
+10
-14
@@ -1,6 +1,6 @@
|
|||||||
|
import { AppBarBackOnly } from "@/components/appBar/backOnly";
|
||||||
import { getUserApi } from "@jellyfin/sdk/lib/utils/api/user-api";
|
import { getUserApi } from "@jellyfin/sdk/lib/utils/api/user-api";
|
||||||
import { CircularProgress, Typography } from "@mui/material";
|
import { Outlet, createFileRoute, redirect } from "@tanstack/react-router";
|
||||||
import { createFileRoute, redirect } from "@tanstack/react-router";
|
|
||||||
import React from "react";
|
import React from "react";
|
||||||
|
|
||||||
export const Route = createFileRoute("/_api/login")({
|
export const Route = createFileRoute("/_api/login")({
|
||||||
@@ -19,16 +19,12 @@ export const Route = createFileRoute("/_api/login")({
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
// component: () => {
|
component: () => {
|
||||||
// const data = Route.useRouteContext();
|
return (
|
||||||
// console.log(data);
|
<>
|
||||||
// return (
|
<AppBarBackOnly />
|
||||||
// <div style={{ height: "100vh" }} className="flex flex-column flex-center">
|
<Outlet />
|
||||||
// <CircularProgress size={86} thickness={2} />
|
</>
|
||||||
// <Typography mt={4} align="center">
|
);
|
||||||
// Fetching users...
|
},
|
||||||
// </Typography>
|
|
||||||
// </div>
|
|
||||||
// );
|
|
||||||
// },
|
|
||||||
});
|
});
|
||||||
@@ -1,46 +1,63 @@
|
|||||||
import LoadingButton from "@mui/lab/LoadingButton";
|
import LoadingButton from "@mui/lab/LoadingButton";
|
||||||
import { OutlinedInput, Paper, Typography } from "@mui/material";
|
import { OutlinedInput, Typography } from "@mui/material";
|
||||||
import Checkbox from "@mui/material/Checkbox";
|
import Checkbox from "@mui/material/Checkbox";
|
||||||
import FormControl from "@mui/material/FormControl";
|
import FormControl from "@mui/material/FormControl";
|
||||||
import FormControlLabel from "@mui/material/FormControlLabel";
|
import FormControlLabel from "@mui/material/FormControlLabel";
|
||||||
import FormGroup from "@mui/material/FormGroup";
|
|
||||||
import IconButton from "@mui/material/IconButton";
|
import IconButton from "@mui/material/IconButton";
|
||||||
import InputAdornment from "@mui/material/InputAdornment";
|
import InputAdornment from "@mui/material/InputAdornment";
|
||||||
import InputLabel from "@mui/material/InputLabel";
|
import InputLabel from "@mui/material/InputLabel";
|
||||||
|
|
||||||
import { useSnackbar } from "notistack";
|
import { useSnackbar } from "notistack";
|
||||||
|
|
||||||
import { AppBarBackOnly } from "@/components/appBar/backOnly.jsx";
|
|
||||||
import { AvatarImage } from "@/components/avatar/avatar.jsx";
|
import { AvatarImage } from "@/components/avatar/avatar.jsx";
|
||||||
import "./login.scss";
|
import "./login.scss";
|
||||||
|
|
||||||
import { saveUser } from "@/utils/storage/user";
|
import { saveUser } from "@/utils/storage/user";
|
||||||
import { useApiInContext } from "@/utils/store/api";
|
import { useApiInContext } from "@/utils/store/api";
|
||||||
import { setBackdrop } from "@/utils/store/backdrop.js";
|
import { useBackdropStore } from "@/utils/store/backdrop.js";
|
||||||
import { createFileRoute, useNavigate } from "@tanstack/react-router";
|
import { useMutation } from "@tanstack/react-query";
|
||||||
import React, { useLayoutEffect, useState } from "react";
|
import {
|
||||||
|
createFileRoute,
|
||||||
|
useNavigate,
|
||||||
|
useRouter,
|
||||||
|
} from "@tanstack/react-router";
|
||||||
|
import React, {
|
||||||
|
type ChangeEvent,
|
||||||
|
type FormEvent,
|
||||||
|
useEffect,
|
||||||
|
useState,
|
||||||
|
} from "react";
|
||||||
|
|
||||||
export const Route = createFileRoute("/_api/login/$userId/$userName")({
|
export const Route = createFileRoute("/_api/login/$userId/$userName")({
|
||||||
component: LoginUser,
|
component: LoginUser,
|
||||||
});
|
});
|
||||||
|
|
||||||
|
type PasswordState = {
|
||||||
|
showpass: boolean;
|
||||||
|
password: string | undefined;
|
||||||
|
};
|
||||||
|
|
||||||
function LoginUser() {
|
function LoginUser() {
|
||||||
const { userName, userId } = Route.useParams();
|
const { userName, userId } = Route.useParams();
|
||||||
|
|
||||||
|
const router = useRouter();
|
||||||
|
|
||||||
const api = useApiInContext((s) => s.api);
|
const api = useApiInContext((s) => s.api);
|
||||||
const createApi = useApiInContext((s) => s.createApi);
|
const createApi = useApiInContext((s) => s.createApi);
|
||||||
|
|
||||||
const [password, setPassword] = useState({
|
const [password, setPassword] = useState<PasswordState>({
|
||||||
showpass: false,
|
showpass: false,
|
||||||
|
password: undefined,
|
||||||
});
|
});
|
||||||
const [loading, setLoading] = useState(false);
|
|
||||||
const [rememberMe, setRememberMe] = useState(true);
|
const [rememberMe, setRememberMe] = useState(true);
|
||||||
|
|
||||||
const navigate = useNavigate({ from: "/login/$userId/$userName" });
|
const navigate = useNavigate({ from: "/login/$userId/$userName" });
|
||||||
|
|
||||||
const { enqueueSnackbar } = useSnackbar();
|
const { enqueueSnackbar } = useSnackbar();
|
||||||
|
|
||||||
const handlePassword = (prop) => (event) => {
|
const handlePassword =
|
||||||
|
(prop: "password" | "showPassord") =>
|
||||||
|
(event: ChangeEvent<HTMLInputElement | HTMLTextAreaElement>) => {
|
||||||
setPassword({
|
setPassword({
|
||||||
...password,
|
...password,
|
||||||
[prop]: event.target.value,
|
[prop]: event.target.value,
|
||||||
@@ -54,50 +71,57 @@ function LoginUser() {
|
|||||||
});
|
});
|
||||||
};
|
};
|
||||||
|
|
||||||
const authUser = async () => {
|
const setBackdrop = useBackdropStore((state) => state.setBackdrop);
|
||||||
try {
|
|
||||||
const auth = await api.authenticateUserByName(
|
|
||||||
userName,
|
|
||||||
password.password,
|
|
||||||
);
|
|
||||||
return auth;
|
|
||||||
} catch (error) {
|
|
||||||
if (error.response?.status === 500) {
|
|
||||||
enqueueSnackbar(
|
|
||||||
"Unable to connect to server. Please try again after some time.",
|
|
||||||
{ variant: "error" },
|
|
||||||
);
|
|
||||||
} else {
|
|
||||||
enqueueSnackbar("Incorrect Password.", { variant: "error" });
|
|
||||||
}
|
|
||||||
setLoading(false);
|
|
||||||
console.error(error);
|
|
||||||
}
|
|
||||||
};
|
|
||||||
|
|
||||||
const handleLogin = async () => {
|
useEffect(() => {
|
||||||
setLoading(true);
|
if (!api) {
|
||||||
const user = await authUser();
|
return;
|
||||||
sessionStorage.setItem("accessToken", user.data.AccessToken);
|
|
||||||
createApi(api.basePath, user.data.AccessToken);
|
|
||||||
if (rememberMe === true) {
|
|
||||||
await saveUser(userName, user.data.AccessToken);
|
|
||||||
}
|
}
|
||||||
setLoading(false);
|
|
||||||
navigate({ to: "/home" });
|
|
||||||
};
|
|
||||||
|
|
||||||
useLayoutEffect(() => {
|
|
||||||
setBackdrop("", "");
|
setBackdrop("", "");
|
||||||
}, []);
|
}, []);
|
||||||
|
|
||||||
const handleCheckRememberMe = (event) => {
|
const handleCheckRememberMe = (
|
||||||
setRememberMe(event.target.checked);
|
_: ChangeEvent<HTMLInputElement>,
|
||||||
|
checked: boolean,
|
||||||
|
) => {
|
||||||
|
setRememberMe(checked);
|
||||||
};
|
};
|
||||||
|
|
||||||
|
const handleLoginFn = async (event: FormEvent<HTMLFormElement>) => {
|
||||||
|
event.preventDefault();
|
||||||
|
try {
|
||||||
|
if (!api) {
|
||||||
|
throw new Error("API not initialized");
|
||||||
|
}
|
||||||
|
const authenticate = await api.authenticateUserByName(
|
||||||
|
userName,
|
||||||
|
password.password,
|
||||||
|
);
|
||||||
|
if (!authenticate.data.AccessToken) {
|
||||||
|
throw new Error("No access token received");
|
||||||
|
}
|
||||||
|
createApi(api.basePath, authenticate.data?.AccessToken);
|
||||||
|
|
||||||
|
if (rememberMe) await saveUser(userName, authenticate.data.AccessToken);
|
||||||
|
|
||||||
|
router.invalidate().finally(() => {
|
||||||
|
navigate({ to: "/home", replace: true });
|
||||||
|
});
|
||||||
|
} catch (err) {
|
||||||
|
console.error(err);
|
||||||
|
enqueueSnackbar("Unable to authenticate! Please check your password", {
|
||||||
|
variant: "error",
|
||||||
|
});
|
||||||
|
}
|
||||||
|
return;
|
||||||
|
};
|
||||||
|
|
||||||
|
const handleLogin = useMutation({
|
||||||
|
mutationKey: ["login", "authenticate"],
|
||||||
|
mutationFn: handleLoginFn,
|
||||||
|
});
|
||||||
|
|
||||||
return (
|
return (
|
||||||
<>
|
|
||||||
<AppBarBackOnly />
|
|
||||||
<div
|
<div
|
||||||
style={{
|
style={{
|
||||||
height: "100vh",
|
height: "100vh",
|
||||||
@@ -108,29 +132,14 @@ function LoginUser() {
|
|||||||
width: "30vw",
|
width: "30vw",
|
||||||
margin: "auto",
|
margin: "auto",
|
||||||
}}
|
}}
|
||||||
>
|
|
||||||
<div
|
|
||||||
style={{
|
|
||||||
marginBottom: "-4em",
|
|
||||||
boxShadow: "1em 0 hsl(256, 100%, 6%)",
|
|
||||||
}}
|
|
||||||
>
|
>
|
||||||
<AvatarImage userId={userId} />
|
<AvatarImage userId={userId} />
|
||||||
</div>
|
|
||||||
<Paper
|
|
||||||
sx={{
|
|
||||||
width: "100%",
|
|
||||||
padding: "1em",
|
|
||||||
paddingTop: "5em",
|
|
||||||
borderRadius: "10px",
|
|
||||||
}}
|
|
||||||
elevation={2}
|
|
||||||
>
|
|
||||||
<Typography
|
<Typography
|
||||||
textAlign="center"
|
textAlign="center"
|
||||||
variant="h5"
|
variant="h5"
|
||||||
sx={{ opacity: 0.8 }}
|
sx={{ opacity: 0.8 }}
|
||||||
mb={2}
|
mb={2}
|
||||||
|
mt={2}
|
||||||
>
|
>
|
||||||
Login as{" "}
|
Login as{" "}
|
||||||
<Typography
|
<Typography
|
||||||
@@ -144,11 +153,7 @@ function LoginUser() {
|
|||||||
{userName}
|
{userName}
|
||||||
</Typography>
|
</Typography>
|
||||||
</Typography>
|
</Typography>
|
||||||
<FormGroup
|
<form onSubmit={(e) => handleLogin.mutate(e)}>
|
||||||
sx={{
|
|
||||||
width: "100%",
|
|
||||||
}}
|
|
||||||
>
|
|
||||||
<FormControl
|
<FormControl
|
||||||
variant="outlined"
|
variant="outlined"
|
||||||
style={{
|
style={{
|
||||||
@@ -159,7 +164,6 @@ function LoginUser() {
|
|||||||
<OutlinedInput
|
<OutlinedInput
|
||||||
id="user-password"
|
id="user-password"
|
||||||
type={password.showpass ? "text" : "password"}
|
type={password.showpass ? "text" : "password"}
|
||||||
variant="outlined"
|
|
||||||
onChange={handlePassword("password")}
|
onChange={handlePassword("password")}
|
||||||
label="Password:"
|
label="Password:"
|
||||||
endAdornment={
|
endAdornment={
|
||||||
@@ -169,9 +173,7 @@ function LoginUser() {
|
|||||||
aria-label="toggle password visibility"
|
aria-label="toggle password visibility"
|
||||||
>
|
>
|
||||||
{password.showpass ? (
|
{password.showpass ? (
|
||||||
<span className="material-symbols-rounded">
|
<span className="material-symbols-rounded">visibility</span>
|
||||||
visibility
|
|
||||||
</span>
|
|
||||||
) : (
|
) : (
|
||||||
<span className="material-symbols-rounded">
|
<span className="material-symbols-rounded">
|
||||||
visibility_off
|
visibility_off
|
||||||
@@ -184,29 +186,24 @@ function LoginUser() {
|
|||||||
</FormControl>
|
</FormControl>
|
||||||
<FormControlLabel
|
<FormControlLabel
|
||||||
control={
|
control={
|
||||||
<Checkbox
|
<Checkbox checked={rememberMe} onChange={handleCheckRememberMe} />
|
||||||
checked={rememberMe}
|
|
||||||
onChange={handleCheckRememberMe}
|
|
||||||
/>
|
|
||||||
}
|
}
|
||||||
label="Remember me"
|
label="Remember me"
|
||||||
/>
|
/>
|
||||||
</FormGroup>
|
|
||||||
<LoadingButton
|
<LoadingButton
|
||||||
variant="contained"
|
variant="contained"
|
||||||
endIcon={
|
endIcon={
|
||||||
<span className="material-symbols-rounded">chevron_right</span>
|
<span className="material-symbols-rounded">chevron_right</span>
|
||||||
}
|
}
|
||||||
onClick={handleLogin}
|
type="submit"
|
||||||
loading={loading}
|
loading={handleLogin.isPending}
|
||||||
loadingPosition="end"
|
loadingPosition="end"
|
||||||
size="large"
|
size="large"
|
||||||
fullWidth
|
fullWidth
|
||||||
>
|
>
|
||||||
Login
|
Login
|
||||||
</LoadingButton>
|
</LoadingButton>
|
||||||
</Paper>
|
</form>
|
||||||
</div>
|
</div>
|
||||||
</>
|
|
||||||
);
|
);
|
||||||
}
|
}
|
||||||
@@ -74,8 +74,6 @@ function LoginPublicUsersList() {
|
|||||||
}, []);
|
}, []);
|
||||||
if (users.isSuccess) {
|
if (users.isSuccess) {
|
||||||
return (
|
return (
|
||||||
<>
|
|
||||||
<AppBarBackOnly />
|
|
||||||
<div className="login-container">
|
<div className="login-container">
|
||||||
<Typography variant="h4" align="center">
|
<Typography variant="h4" align="center">
|
||||||
Users
|
Users
|
||||||
@@ -109,7 +107,6 @@ function LoginPublicUsersList() {
|
|||||||
}
|
}
|
||||||
/>
|
/>
|
||||||
</div>
|
</div>
|
||||||
</>
|
|
||||||
);
|
);
|
||||||
}
|
}
|
||||||
if (users.isError) {
|
if (users.isError) {
|
||||||
|
|||||||
@@ -66,7 +66,7 @@
|
|||||||
}
|
}
|
||||||
|
|
||||||
&-form {
|
&-form {
|
||||||
width: 28em;
|
width: 24em;
|
||||||
display: flex;
|
display: flex;
|
||||||
flex-direction: column;
|
flex-direction: column;
|
||||||
justify-content: center;
|
justify-content: center;
|
||||||
@@ -81,7 +81,7 @@
|
|||||||
background: rgb(255 255 255 / 0.05);
|
background: rgb(255 255 255 / 0.05);
|
||||||
padding: 2em;
|
padding: 2em;
|
||||||
border-radius: 20px;
|
border-radius: 20px;
|
||||||
border: 1px solid rgb(255 255 255 / 0.1);
|
// border: 1px solid rgb(255 255 255 / 0.1);
|
||||||
&.padded-top {
|
&.padded-top {
|
||||||
margin-top: 25vh;
|
margin-top: 25vh;
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -1,5 +1,10 @@
|
|||||||
import { useMutation, useQuery } from "@tanstack/react-query";
|
import { skipToken, useMutation, useQuery } from "@tanstack/react-query";
|
||||||
import React, { type FormEvent, useLayoutEffect, useState } from "react";
|
import React, {
|
||||||
|
type ChangeEvent,
|
||||||
|
type FormEvent,
|
||||||
|
useEffect,
|
||||||
|
useState,
|
||||||
|
} from "react";
|
||||||
|
|
||||||
import { saveUser } from "@/utils/storage/user.js";
|
import { saveUser } from "@/utils/storage/user.js";
|
||||||
|
|
||||||
@@ -15,19 +20,19 @@ import InputLabel from "@mui/material/InputLabel";
|
|||||||
|
|
||||||
import { useSnackbar } from "notistack";
|
import { useSnackbar } from "notistack";
|
||||||
|
|
||||||
import { AppBarBackOnly } from "@/components/appBar/backOnly.jsx";
|
import { useApiInContext } from "@/utils/store/api.js";
|
||||||
import { axiosClient, useApiInContext } from "@/utils/store/api.js";
|
|
||||||
import { getBrandingApi } from "@jellyfin/sdk/lib/utils/api/branding-api";
|
import { getBrandingApi } from "@jellyfin/sdk/lib/utils/api/branding-api";
|
||||||
import "./login.scss";
|
import "./login.scss";
|
||||||
|
|
||||||
import QuickConnectButton from "@/components/buttons/quickConnectButton";
|
import QuickConnectButton from "@/components/buttons/quickConnectButton";
|
||||||
import { setBackdrop } from "@/utils/store/backdrop.js";
|
import { useBackdropStore } from "@/utils/store/backdrop.js";
|
||||||
import { blue } from "@mui/material/colors";
|
import { blue } from "@mui/material/colors";
|
||||||
import {
|
import {
|
||||||
createFileRoute,
|
createFileRoute,
|
||||||
useNavigate,
|
useNavigate,
|
||||||
useRouter,
|
useRouter,
|
||||||
} from "@tanstack/react-router";
|
} from "@tanstack/react-router";
|
||||||
|
import axios from "axios";
|
||||||
|
|
||||||
export const Route = createFileRoute("/_api/login/manual")({
|
export const Route = createFileRoute("/_api/login/manual")({
|
||||||
component: UserLoginManual,
|
component: UserLoginManual,
|
||||||
@@ -43,15 +48,15 @@ function UserLoginManual() {
|
|||||||
|
|
||||||
const server = useQuery({
|
const server = useQuery({
|
||||||
queryKey: ["login", "manual", "serverInfo"],
|
queryKey: ["login", "manual", "serverInfo"],
|
||||||
queryFn: async () => {
|
queryFn: async () =>
|
||||||
return (await getBrandingApi(api).getBrandingOptions()).data;
|
api ? (await getBrandingApi(api).getBrandingOptions()).data : skipToken,
|
||||||
},
|
|
||||||
});
|
});
|
||||||
|
|
||||||
const ssoProviders = useQuery({
|
const ssoProviders = useQuery({
|
||||||
queryKey: ["login", "manual", "ssoProviders"],
|
queryKey: ["login", "manual", "ssoProviders"],
|
||||||
queryFn: async () => {
|
queryFn: async () => {
|
||||||
return axiosClient.get(
|
if (!api?.accessToken) return;
|
||||||
|
return axios.get(
|
||||||
`${api.basePath}/sso/SAML/Get?api_key=${api.accessToken}`,
|
`${api.basePath}/sso/SAML/Get?api_key=${api.accessToken}`,
|
||||||
);
|
);
|
||||||
},
|
},
|
||||||
@@ -69,7 +74,7 @@ function UserLoginManual() {
|
|||||||
password: "",
|
password: "",
|
||||||
});
|
});
|
||||||
|
|
||||||
const handlePassword = (prop) => (event) => {
|
const handlePassword = (prop: "password" | "showpass") => (event) => {
|
||||||
setPassword({
|
setPassword({
|
||||||
...password,
|
...password,
|
||||||
[prop]: event.target.value,
|
[prop]: event.target.value,
|
||||||
@@ -86,14 +91,19 @@ function UserLoginManual() {
|
|||||||
const handleLoginFn = async (event: FormEvent<HTMLFormElement>) => {
|
const handleLoginFn = async (event: FormEvent<HTMLFormElement>) => {
|
||||||
event.preventDefault();
|
event.preventDefault();
|
||||||
try {
|
try {
|
||||||
|
if (!api) {
|
||||||
|
throw new Error("Api is not available");
|
||||||
|
}
|
||||||
const authenticate = await api.authenticateUserByName(
|
const authenticate = await api.authenticateUserByName(
|
||||||
username,
|
username,
|
||||||
password.password,
|
password.password,
|
||||||
);
|
);
|
||||||
|
if (!authenticate.data?.AccessToken) {
|
||||||
|
throw new Error("Access token not available");
|
||||||
|
}
|
||||||
createApi(api.basePath, authenticate.data?.AccessToken);
|
createApi(api.basePath, authenticate.data?.AccessToken);
|
||||||
|
|
||||||
if (rememberMe) await saveUser(username, authenticate.data.AccessToken);
|
if (rememberMe) await saveUser(username, authenticate.data.AccessToken);
|
||||||
|
|
||||||
router.invalidate().finally(() => {
|
router.invalidate().finally(() => {
|
||||||
navigate({ to: searchParams.redirect || "/home", replace: true });
|
navigate({ to: searchParams.redirect || "/home", replace: true });
|
||||||
});
|
});
|
||||||
@@ -112,24 +122,26 @@ function UserLoginManual() {
|
|||||||
mutationFn: handleLoginFn,
|
mutationFn: handleLoginFn,
|
||||||
});
|
});
|
||||||
|
|
||||||
const handleCheckRememberMe = (event) => {
|
const handleCheckRememberMe = (
|
||||||
setRememberMe(event.target.checked);
|
_: ChangeEvent<HTMLInputElement>,
|
||||||
|
checked: boolean,
|
||||||
|
) => {
|
||||||
|
setRememberMe(checked);
|
||||||
};
|
};
|
||||||
|
|
||||||
useLayoutEffect(() => {
|
const setBackdrop = useBackdropStore((state) => state.setBackdrop);
|
||||||
|
useEffect(() => {
|
||||||
setBackdrop("", "");
|
setBackdrop("", "");
|
||||||
}, []);
|
}, []);
|
||||||
|
|
||||||
return (
|
return (
|
||||||
<>
|
|
||||||
<AppBarBackOnly />
|
|
||||||
<div className="login scrollY">
|
<div className="login scrollY">
|
||||||
<div
|
<div
|
||||||
className={`login-form-container ${
|
className={`login-form-container ${
|
||||||
server.data?.LoginDisclaimer && "padded-top"
|
server.data?.LoginDisclaimer && "padded-top"
|
||||||
}`}
|
}`}
|
||||||
>
|
>
|
||||||
<Typography variant="h3" color="textPrimary">
|
<Typography variant="h4" color="textPrimary">
|
||||||
Login
|
Login
|
||||||
</Typography>
|
</Typography>
|
||||||
<form className="login-form" onSubmit={(e) => handleLogin.mutate(e)}>
|
<form className="login-form" onSubmit={(e) => handleLogin.mutate(e)}>
|
||||||
@@ -168,10 +180,7 @@ function UserLoginManual() {
|
|||||||
</FormControl>
|
</FormControl>
|
||||||
<FormControlLabel
|
<FormControlLabel
|
||||||
control={
|
control={
|
||||||
<Checkbox
|
<Checkbox checked={rememberMe} onChange={handleCheckRememberMe} />
|
||||||
checked={rememberMe}
|
|
||||||
onChange={handleCheckRememberMe}
|
|
||||||
/>
|
|
||||||
}
|
}
|
||||||
label="Remember me"
|
label="Remember me"
|
||||||
/>
|
/>
|
||||||
@@ -187,7 +196,6 @@ function UserLoginManual() {
|
|||||||
>
|
>
|
||||||
Login
|
Login
|
||||||
</LoadingButton>
|
</LoadingButton>
|
||||||
<QuickConnectButton />
|
|
||||||
<Button
|
<Button
|
||||||
color="secondary"
|
color="secondary"
|
||||||
variant="contained"
|
variant="contained"
|
||||||
@@ -219,6 +227,7 @@ function UserLoginManual() {
|
|||||||
className="material-symbols-rounded"
|
className="material-symbols-rounded"
|
||||||
style={{
|
style={{
|
||||||
color: blue[700],
|
color: blue[700],
|
||||||
|
//@ts-ignore
|
||||||
"--fill": 1,
|
"--fill": 1,
|
||||||
}}
|
}}
|
||||||
>
|
>
|
||||||
@@ -232,6 +241,5 @@ function UserLoginManual() {
|
|||||||
</Paper>
|
</Paper>
|
||||||
)}
|
)}
|
||||||
</div>
|
</div>
|
||||||
</>
|
|
||||||
);
|
);
|
||||||
}
|
}
|
||||||
Reference in new issue
Block a user