mirror of
https://github.com/PlayEdu/h5.git
synced 2025-07-21 17:11:03 +08:00
登录页面优化
This commit is contained in:
parent
6bc0e443be
commit
8ba02aaaed
@ -1,10 +1,8 @@
|
|||||||
.login-content {
|
.login-content {
|
||||||
position: absolute;
|
position: fixed;
|
||||||
bottom: 0;
|
width: 100%;
|
||||||
left: 0;
|
|
||||||
right: 0;
|
|
||||||
top: 0;
|
|
||||||
background-image: url("../../assets//images/login/bg.png");
|
background-image: url("../../assets//images/login/bg.png");
|
||||||
|
background-repeat: no-repeat;
|
||||||
background-size: 100% 100%;
|
background-size: 100% 100%;
|
||||||
.top-content {
|
.top-content {
|
||||||
width: 100%;
|
width: 100%;
|
||||||
|
@ -22,10 +22,13 @@ const LoginPage = () => {
|
|||||||
const [captchaVal, setCaptchaVal] = useState<string>("");
|
const [captchaVal, setCaptchaVal] = useState<string>("");
|
||||||
const [captchaKey, setCaptchaKey] = useState<string>("");
|
const [captchaKey, setCaptchaKey] = useState<string>("");
|
||||||
const [captchaLoading, setCaptchaLoading] = useState(true);
|
const [captchaLoading, setCaptchaLoading] = useState(true);
|
||||||
|
const [bodyHeight, setBodyHeight] = useState<number>(0);
|
||||||
|
|
||||||
useEffect(() => {
|
useEffect(() => {
|
||||||
fetchImageCaptcha();
|
fetchImageCaptcha();
|
||||||
document.title = "登录";
|
document.title = "登录";
|
||||||
|
let value = document.documentElement.clientHeight;
|
||||||
|
setBodyHeight(value);
|
||||||
}, []);
|
}, []);
|
||||||
|
|
||||||
const fetchImageCaptcha = () => {
|
const fetchImageCaptcha = () => {
|
||||||
@ -123,7 +126,10 @@ const LoginPage = () => {
|
|||||||
};
|
};
|
||||||
|
|
||||||
return (
|
return (
|
||||||
<div className={styles["login-content"]}>
|
<div
|
||||||
|
className={styles["login-content"]}
|
||||||
|
style={{ height: bodyHeight + "px" }}
|
||||||
|
>
|
||||||
<div className={styles["top-content"]}>
|
<div className={styles["top-content"]}>
|
||||||
<div className={styles["title"]}>学员登录</div>
|
<div className={styles["title"]}>学员登录</div>
|
||||||
<Image src={banner} width={150} height={150} />
|
<Image src={banner} width={150} height={150} />
|
||||||
|
Loading…
x
Reference in New Issue
Block a user