From 9742012f40973be5c5d107b6e45add8c84ba159a Mon Sep 17 00:00:00 2001 From: Drjingfubo <50685476+Drjingfubo@users.noreply.github.com> Date: Tue, 30 Mar 2021 19:50:10 +0800 Subject: [PATCH] =?UTF-8?q?upd(tabbar):=20=E4=B8=BB=E9=A2=98=E5=AE=9A?= =?UTF-8?q?=E5=88=B6=E5=8A=9F=E8=83=BD=E6=94=AF=E6=8C=81=20(#420)?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit * upd: drag,shortpassword * upd: tabbar,shortpassword,actionsheet * upd: shortpassword新增方法 * upd: shortpassword按钮颜色抽离 * upd: tabbar的props样式抽离 Co-authored-by: richard1015 <51844712@qq.com> --- src/packages/tabbar/index.vue | 2 +- src/packages/tabbaritem/index.scss | 90 +++++++++++++++--------------- src/packages/tabbaritem/index.vue | 32 ++++++++--- 3 files changed, 71 insertions(+), 53 deletions(-) diff --git a/src/packages/tabbar/index.vue b/src/packages/tabbar/index.vue index 84bbd4afd..b22d2447b 100644 --- a/src/packages/tabbar/index.vue +++ b/src/packages/tabbar/index.vue @@ -34,7 +34,7 @@ export default create({ }, activeColor: { type: String, - default: '#fa2c19' + default: '' } }, emits: ['tab-switch', 'update:show'], diff --git a/src/packages/tabbaritem/index.scss b/src/packages/tabbaritem/index.scss index 8efadcf3b..be2e51584 100644 --- a/src/packages/tabbaritem/index.scss +++ b/src/packages/tabbaritem/index.scss @@ -1,58 +1,60 @@ -.tabbar-item { +.nut-tabbar-item { flex: 1; text-align: center; text-decoration: none; - color: $text-color; + color: $primary-color; height: 100%; display: flex; justify-content: center; align-items: center; -} -.icon-box { - padding: 0px; - display: inline-block; - position: relative; - - .tips { - position: absolute; - background: $tabbar-active-color; - border: 1px solid $white; - border-radius: 7px; - text-align: center; - top: -2px; - right: -7px; - box-shadow: 0 0 0 1px $white; - font-size: $font-size-1; - color: $white; + &__icon--unactive { + color: $black; } - .num { - line-height: 1; - font-size: $font-size-0; - color: $white; - padding: 1px 2px 2px 3px; - } - .nums { - line-height: 1; - font-size: $font-size-0; - color: $white; - padding: 2px 1px 2px 2px; - } -} + &_icon-box { + padding: 0px; + display: inline-block; + position: relative; -.icon-box .icon { - display: block; - background-size: 100% 100%; - background-position: center center; -} + &_tips { + position: absolute; + background: $tabbar-active-color; + border: 1px solid $white; + border-radius: 7px; + text-align: center; + top: -2px; + right: -7px; + box-shadow: 0 0 0 1px $white; + font-size: $font-size-1; + color: $white; + } -.icon-box .tabbar-nav-word { - font-size: $font-size-0; - display: block; -} + &_num { + line-height: 1; + font-size: $font-size-0; + color: $white; + padding: 1px 2px 2px 3px; + } -.icon-box .big-word { - font-size: $font-size-large; - line-height: 1; + &_nums { + line-height: 1; + font-size: $font-size-0; + color: $white; + padding: 2px 1px 2px 2px; + } + &_icon { + display: block; + background-size: 100% 100%; + background-position: center center; + } + &_nav-word { + font-size: $font-size-0; + display: block; + } + &_big-word { + font-size: $font-size-large; + line-height: 1; + } + } } diff --git a/src/packages/tabbaritem/index.vue b/src/packages/tabbaritem/index.vue index 68baf9c32..79d65b278 100644 --- a/src/packages/tabbaritem/index.vue +++ b/src/packages/tabbaritem/index.vue @@ -1,23 +1,39 @@ -- GitLab