From a43a0fabc2e5de0ae96e960b3057bd51845a43fb Mon Sep 17 00:00:00 2001 From: king <2229249788@qq.com> Date: Thu, 14 Sep 2023 18:39:51 +0800 Subject: [PATCH] =?UTF-8?q?2.=E4=BF=AE=E6=94=B9tab=E7=9A=84backMode?= =?UTF-8?q?=E6=A8=A1=E5=BC=8F=E6=A0=B7=E5=BC=8F?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/components/tabs/tabs.scss | 21 ++++++++++++---- src/components/tabs/tabs.tsx | 3 ++- src/pages/index/index.tsx | 2 +- .../manage/courseAdmin/components/search.tsx | 18 ++++---------- .../courseAdmin/courseAdmin.module.scss | 24 +++++++++++++++---- 5 files changed, 44 insertions(+), 24 deletions(-) diff --git a/src/components/tabs/tabs.scss b/src/components/tabs/tabs.scss index dd2ab64..9844d81 100644 --- a/src/components/tabs/tabs.scss +++ b/src/components/tabs/tabs.scss @@ -44,14 +44,18 @@ width: 100%; border-radius: 90rpx; transition: background-color 300ms; + + &:first-child{ + padding: 16rpx 16rpx 16rpx 0; + } + + &:last-child{ + padding: 16rpx 0 16rpx 16rpx; + } } - .current { + .sliding{ position: relative; - font-size: 36rpx; - font-family: PingFang SC-Bold, PingFang SC; - font-weight: bold; - color: #323635; &:after { position: absolute; @@ -69,6 +73,13 @@ transition: all 200ms; } } + + .current { + font-size: 36rpx; + font-family: PingFang SC-Bold, PingFang SC; + font-weight: bold; + color: #323635; + } } @keyframes spread { diff --git a/src/components/tabs/tabs.tsx b/src/components/tabs/tabs.tsx index 4b768c1..1f9f7d4 100644 --- a/src/components/tabs/tabs.tsx +++ b/src/components/tabs/tabs.tsx @@ -23,6 +23,7 @@ interface TabsProps { onChange?: (data: OnChangOpt) => void backMode?: boolean // 块级模式 style?: CSSProperties + hiddenSliding?: boolean // 取消底部滑块 } const Tabs: FC = (opt) => { @@ -55,7 +56,7 @@ const Tabs: FC = (opt) => { {opt.tabList.map((d, index) => onChange(event, index, d)}> {d.title} )} diff --git a/src/pages/index/index.tsx b/src/pages/index/index.tsx index 856f624..a42eb35 100644 --- a/src/pages/index/index.tsx +++ b/src/pages/index/index.tsx @@ -26,7 +26,7 @@ const Index: FC = () => { } + leftNode={} backgroundColor={'transparent'} /> = ({param, setParam}) => { })} /> - setShow(true)}> - 筛选 - + + setShow(true)} className={styles.select}> + 选择部门 + diff --git a/src/pages/manage/courseAdmin/courseAdmin.module.scss b/src/pages/manage/courseAdmin/courseAdmin.module.scss index f35b762..747ed4f 100644 --- a/src/pages/manage/courseAdmin/courseAdmin.module.scss +++ b/src/pages/manage/courseAdmin/courseAdmin.module.scss @@ -1,15 +1,17 @@ +page { + background: #fff !important; +} + .searchBox { - background: #fff; padding: 24rpx 30rpx; - display: flex; - justify-content: space-between; + box-sizing: border-box; position: sticky; top: 0; border-bottom: 1px solid #F5F8F7; } .searchInput { - width: 550rpx; + width: 100%; height: 68rpx; display: flex; align-items: center; @@ -19,6 +21,20 @@ overflow: hidden; } +.select{ + width: 172rpx; + height: 56rpx; + background: #F6F6F6; + border-radius: 28rpx; + display: flex; + align-items: center; + justify-content: center; + font-size: 24rpx; + font-family: PingFang SC-Medium, PingFang SC; + font-weight: 500; + color: #323635; +} + .radioBox { border-bottom: 1px solid #F5F8F7; padding: 20px 0;