w-ui
Version:
A Vue.js 2.0 UI Toolkit for mobile
83 lines (73 loc) • 1.65 kB
text/less
@import '../../../src/styles/variables.less';
@import '../../../src/styles/mixins.less';
.wui {
&-tab {
&-nav {
display: flex;
position: relative;
z-index: 0;
&:after {
.bottom-line('#B2B2B2', 3);
}
&-item {
width: 1%;
flex: 1;
position: relative;
text-align: center;
color: #585858;
font-size: .28rem;
line-height: .85rem;
display: block;
.tap-color(#fff, .97);
a {
display: inherit;
color: inherit;
}
&:not(:last-child):after {
position: absolute;
top: 35%;
right: 0;
content: '';
width: 1px;
height: 30%;
transform: scaleX(.5);
border-right: 1px solid #D9D9D9;
}
}
.wui-tab-active {
color: #FF5E53;
.tap-color(#fff, 1);
&:before {
content: '';
width: 70%;
height: 2px;
position: absolute;
left: 50%;
bottom: 0;
margin-left: -35%;
z-index: 4;
background-color: currentColor;
}
}
}
&-panel {
position: relative;
overflow: auto;
background-color: #FFF;
&-item {
width: 100%;
position: absolute;
top: 0;
transform: translateX(-100%);
&.wui-tab-active {
position: relative;
transition: transform .15s;
transform: translateX(0);
& ~ .wui-tab-panel-item {
transform: translateX(100%);
}
}
}
}
}
}