mirror of
https://github.com/youzan/vant.git
synced 2025-10-20 18:54:24 +00:00
[bugfix] Tabbar: info not work when use icon slot (#1705)
This commit is contained in:
@@ -41,19 +41,12 @@
|
||||
}
|
||||
|
||||
&__info {
|
||||
position: absolute;
|
||||
top: 2px;
|
||||
right: 2px;
|
||||
color: $white;
|
||||
font-size: 10px;
|
||||
font-weight: normal;
|
||||
transform: scale(0.8);
|
||||
text-align: center;
|
||||
box-sizing: border-box;
|
||||
padding: 0 6px;
|
||||
min-width: 18px;
|
||||
line-height: 18px;
|
||||
border-radius: 9px;
|
||||
background-color: $red;
|
||||
left: auto;
|
||||
top: 4px;
|
||||
right: 4px;
|
||||
font-size: 12px;
|
||||
min-width: 1.5em;
|
||||
line-height: 1.5em;
|
||||
transform: scale(0.7);
|
||||
}
|
||||
}
|
||||
|
@@ -8,6 +8,7 @@
|
||||
@import "./common/clearfix.css";
|
||||
@import "./common/hairline.css";
|
||||
@import "./common/animation.css";
|
||||
@import './info.css';
|
||||
@import './icon.css';
|
||||
@import './loading.css';
|
||||
@import './button.css';
|
||||
|
@@ -14,23 +14,6 @@
|
||||
font-size: inherit;
|
||||
text-rendering: auto;
|
||||
|
||||
&__info {
|
||||
color: #fff;
|
||||
left: 100%;
|
||||
top: -.5em;
|
||||
font-size: .5em;
|
||||
padding: 0 .3em;
|
||||
text-align: center;
|
||||
min-width: 1.2em;
|
||||
line-height: 1.2;
|
||||
position: absolute;
|
||||
border-radius: .6em;
|
||||
box-sizing: border-box;
|
||||
background-color: $red;
|
||||
transform: translateX(-50%);
|
||||
font-family: PingFang SC, Helvetica Neue, Arial, sans-serif;
|
||||
}
|
||||
|
||||
&::before {
|
||||
display: inline-block;
|
||||
}
|
||||
|
18
packages/vant-css/src/info.css
Normal file
18
packages/vant-css/src/info.css
Normal file
@@ -0,0 +1,18 @@
|
||||
@import './common/var.css';
|
||||
|
||||
.van-info {
|
||||
color: #fff;
|
||||
left: 100%;
|
||||
top: -.5em;
|
||||
font-size: .5em;
|
||||
padding: 0 .3em;
|
||||
text-align: center;
|
||||
min-width: 1.2em;
|
||||
line-height: 1.2;
|
||||
position: absolute;
|
||||
border-radius: .6em;
|
||||
box-sizing: border-box;
|
||||
background-color: $red;
|
||||
transform: translateX(-50%);
|
||||
font-family: PingFang SC, Helvetica Neue, Arial, sans-serif;
|
||||
}
|
@@ -24,8 +24,8 @@
|
||||
|
||||
&__icon {
|
||||
font-size: 18px;
|
||||
margin-bottom: 5px;
|
||||
position: relative;
|
||||
margin-bottom: 5px;
|
||||
|
||||
.van-icon {
|
||||
display: block;
|
||||
@@ -46,6 +46,7 @@
|
||||
|
||||
img {
|
||||
height: 18px;
|
||||
display: block;
|
||||
}
|
||||
}
|
||||
|
||||
|
Reference in New Issue
Block a user