From 42fc798fc6499b34a0db37d5698c4d9d9fae4f1a Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E7=A6=BA=E7=8B=A8?= <18119604035@163.com> Date: Mon, 3 Jul 2023 11:29:14 +0800 Subject: [PATCH] =?UTF-8?q?=E6=A0=B7=E5=BC=8F=E4=BC=98=E5=8C=96?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/components/bar-footer/index.module.scss | 8 +- src/main.scss | 14 +++ src/pages/index/compenents/courses-model.tsx | 103 ++++++++++--------- src/pages/index/index.module.scss | 11 +- src/pages/member/index.module.scss | 8 +- src/pages/study/index.module.scss | 8 +- 6 files changed, 97 insertions(+), 55 deletions(-) diff --git a/src/components/bar-footer/index.module.scss b/src/components/bar-footer/index.module.scss index 42605f1..f051303 100644 --- a/src/components/bar-footer/index.module.scss +++ b/src/components/bar-footer/index.module.scss @@ -3,8 +3,14 @@ bottom: 0; left: 0; right: 0; - height: 55px; + min-height: 55px; box-shadow: 0px -1px 4px 0px rgba(0, 0, 0, 0.04); background: #ffffff; z-index: 100; + box-sizing: border-box; +} +@media only screen and (device-width: 375px) and (device-height: 812px) and (-webkit-device-pixel-ratio: 3) { + .footer { + padding-bottom: 34px !important; + } } diff --git a/src/main.scss b/src/main.scss index dec3679..3ecbd11 100644 --- a/src/main.scss +++ b/src/main.scss @@ -137,3 +137,17 @@ code { .adm-tab-bar-item-icon { height: 28px !important; } + +.sp-line { + width: 200%; + height: 1px; + height: 1px; + background: rgba(0, 0, 0, 0.05); + transform: scale(0.5); + -ms-transform: scale(0.5); + -o-transform: scale(0.5); + -webkit-transform: scale(0.5); + -moz-transform: scale(0.5); + transform-origin: top left; + margin-top: 30px; +} diff --git a/src/pages/index/compenents/courses-model.tsx b/src/pages/index/compenents/courses-model.tsx index cede355..54df993 100644 --- a/src/pages/index/compenents/courses-model.tsx +++ b/src/pages/index/compenents/courses-model.tsx @@ -21,29 +21,45 @@ export const CoursesModel: React.FC = ({ }) => { const navigate = useNavigate(); return ( -
{ - navigate(`/course/${id}`); - }} - > - -
-
{title}
-
- {isRequired === 1 &&
必修课
} - {isRequired === 0 && ( -
选修课
- )} - {progress == 0 && ( - <> + <> +
{ + navigate(`/course/${id}`); + }} + > + +
+
{title}
+
+ {isRequired === 1 &&
必修课
} + {isRequired === 0 && ( +
选修课
+ )} + {progress == 0 && ( + <> + + 未学习 + + )} + {progress > 0 && progress < 100 && ( = ({ "--text-width": "27px", }} /> - 未学习 - - )} - {progress > 0 && progress < 100 && ( - - )} - {progress >= 100 && ( -
- - 恭喜你学完此课程! -
- )} + )} + {progress >= 100 && ( +
+ + 恭喜你学完此课程! +
+ )} +
-
+
+ ); }; diff --git a/src/pages/index/index.module.scss b/src/pages/index/index.module.scss index f5733a3..c29869e 100644 --- a/src/pages/index/index.module.scss +++ b/src/pages/index/index.module.scss @@ -121,13 +121,20 @@ overflow-y: auto; .item { width: 100%; + float: left; height: auto; box-sizing: border-box; padding-top: 30px; - padding-bottom: 30px; - border-bottom: 1px solid rgba(0, 0, 0, 0.05); + display: flex; + flex-direction: column; &:first-child { padding-top: 20px; } } } + +@media only screen and (device-width: 375px) and (device-height: 812px) and (-webkit-device-pixel-ratio: 3) { + .list-box { + padding-bottom: 89px !important; + } +} diff --git a/src/pages/member/index.module.scss b/src/pages/member/index.module.scss index 3d5e064..a70e56b 100644 --- a/src/pages/member/index.module.scss +++ b/src/pages/member/index.module.scss @@ -22,7 +22,7 @@ float: left; height: auto; box-sizing: border-box; - padding: 20px 20px; + padding: 20px 20px 75px 20px; .top-content { width: 100%; display: flex; @@ -189,3 +189,9 @@ margin-top: 10px; } } + +@media only screen and (device-width: 375px) and (device-height: 812px) and (-webkit-device-pixel-ratio: 3) { + .content-box { + padding-bottom: 109px !important; + } +} diff --git a/src/pages/study/index.module.scss b/src/pages/study/index.module.scss index ab37fe3..9d7a44d 100644 --- a/src/pages/study/index.module.scss +++ b/src/pages/study/index.module.scss @@ -13,7 +13,7 @@ float: left; height: auto; box-sizing: border-box; - padding: 0px 20px; + padding: 0px 20px 55px 20px; text-align: left; overflow-x: hidden; overflow-y: auto; @@ -93,3 +93,9 @@ } } } + +@media only screen and (device-width: 375px) and (device-height: 812px) and (-webkit-device-pixel-ratio: 3) { + .list-box { + padding-bottom: 89px !important; + } +}