mirror of
https://github.com/PlayEdu/backend
synced 2025-07-24 07:00:02 +08:00
路由丢失页添加
This commit is contained in:
parent
0bf57e8b6c
commit
bb7807f87a
@ -1,10 +1,16 @@
|
|||||||
import React, { useEffect } from "react";
|
import React, { useEffect } from "react";
|
||||||
import styles from "./HomePage.module.css";
|
import styles from "./HomePage.module.css";
|
||||||
import { Outlet } from "react-router-dom";
|
import { Outlet, useNavigate } from "react-router-dom";
|
||||||
import { Header, LeftMenu, Footer } from "../../compenents";
|
import { Header, LeftMenu, Footer } from "../../compenents";
|
||||||
import { login } from "../../api/index";
|
import { login } from "../../api/index";
|
||||||
|
import { getToken, clearToken } from "../../utils/index";
|
||||||
|
|
||||||
export const HomePage: React.FC = () => {
|
export const HomePage: React.FC = () => {
|
||||||
|
// const token = getToken();
|
||||||
|
// const navigate = useNavigate();
|
||||||
|
// if (token === "") {
|
||||||
|
// navigate("/login");
|
||||||
|
// }
|
||||||
useEffect(() => {
|
useEffect(() => {
|
||||||
login.login("1@qq.com", "123123", "1", "2");
|
login.login("1@qq.com", "123123", "1", "2");
|
||||||
}, []);
|
}, []);
|
||||||
|
@ -2,12 +2,16 @@
|
|||||||
width: calc(100% - 32px) !important;
|
width: calc(100% - 32px) !important;
|
||||||
margin-left: 16px !important;
|
margin-left: 16px !important;
|
||||||
margin-right: 16px !important;
|
margin-right: 16px !important;
|
||||||
|
margin-top: 8px !important;
|
||||||
|
margin-bottom: 8px !important;
|
||||||
}
|
}
|
||||||
|
|
||||||
.ant-menu-submenu {
|
.ant-menu-submenu {
|
||||||
width: calc(100% - 24px) !important;
|
width: calc(100% - 24px) !important;
|
||||||
margin-left: 12px !important;
|
margin-left: 12px !important;
|
||||||
margin-right: 12px !important;
|
margin-right: 12px !important;
|
||||||
|
margin-top: 6px !important;
|
||||||
|
margin-bottom: 6px !important;
|
||||||
}
|
}
|
||||||
|
|
||||||
.ant-menu,
|
.ant-menu,
|
||||||
|
Loading…
x
Reference in New Issue
Block a user