weui
Version:
A UI library by WeChat official design team, includes the most useful widgets/modules in mobile web applications.
184 lines (163 loc) • 4 kB
text/less
/*
* Tencent is pleased to support the open source community by making WeUI available.
*
* Copyright (C) 2017 THL A29 Limited, a Tencent company. All rights reserved.
*
* Licensed under the MIT License (the "License"); you may not use this file except in compliance
* with the License. You may obtain a copy of the License at
*
* http://opensource.org/licenses/MIT
*
* Unless required by applicable law or agreed to in writing, software distributed under the License is
* distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND,
* either express or implied. See the License for the specific language governing permissions and
* limitations under the License.
*/
@import "../../base/fn";
.weui-cells__group{
border:0;
}
.weui-cells__group_form {
&:first-child {
.weui-cells__title {
margin-top: 0;
}
}
.weui-cells__title {
margin-top: 24px;
margin-bottom: 8px;
padding: 0 32px;
}
.weui-cells,
.weui-cell {
&:before {
left: 32px;
right: 32px;
}
}
.weui-cells_checkbox {
.weui-check__label {
&:before { left: 72px; }
}
}
.weui-cells {
&:after {
left: 32px;
right: 32px;
}
}
.weui-cell {
padding: 16px 32px;
&:not(.weui-cell_link) {
color: @weuiTextColorTitle;
}
}
.weui-cell__hd {
padding-right: 16px;
}
.weui-cell__ft {
padding-left: 16px;
}
.weui-cell_warn {
input {
color: @weuiColorWarn;
}
}
.weui-label {
max-width: 5em;
margin-right: 8px;
}
.weui-cells__tips {
margin-top: 8px;
padding: 0 32px;
color: var(--weui-FG-2);
a {
font-weight: 700;
}
}
.weui-cells__tips_warn{
color: var(--weui-RED);
}
.weui-cell_select {
padding: 0;
.weui-select {
padding: 0 32px;
}
.weui-cell__bd:after {
right: 32px;
}
}
.weui-cell_select-before {
.weui-label {
margin-right: 24px;
}
.weui-select {
padding-right: 24px;
box-sizing: initial;
}
}
.weui-cell_select-after {
padding-left: 32px;
.weui-select {
padding-left: 0;
}
}
.weui-cell_switch {
padding: 12px 32px;
}
// 适老化下表单项折行,适用高度不大于默认cell内容高度的元素并排
// 默认cell内容高度:cell默认高度56px,除去上下padding各16px,默认内容高度为行高1.4(24px)
.weui-cell_wrap{
align-items: initial;
padding-top:8px;
padding-bottom:8px;
.weui-cell__hd{
padding-right:0;
}
.weui-label{
margin-top:8px;
}
.weui-cell__bd{
display: flex;
flex-wrap: wrap;
align-items:center;
}
}
.weui-cell__control{
margin:8px 0 8px 16px;
}
.weui-cell__control_flex{
flex: 1;
min-width: 30vw;
}
// 验证码
.weui-vcode-btn {
font-size: 16px;
padding: 0 12px;
height: auto;
width: auto;
line-height: 2em;
color: @weuiBtnDefaultFontColor;
background-color: @weuiBtnDefaultBg;
&:before {
display: none;
}
}
// 验证码cell适老化:由于小按钮高度32px大于默认内容高度,所以需要把cell的padding改小以保持cell默认高度56px的规范
.weui-cell_vcode{
&.weui-cell_wrap{
padding-top:4px;
padding-bottom:4px;
.weui-label{
margin-top:12px;
}
.weui-input{
font-size:17px;
min-height:unit(32/17,em);
}
.weui-btn_reset{
margin-right:12px;
}
}
}
}