Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

extract skin variable #677

Open
wants to merge 1 commit into
base: master
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
68 changes: 34 additions & 34 deletions dist/style/weui.css

Large diffs are not rendered by default.

2 changes: 1 addition & 1 deletion dist/style/weui.min.css

Large diffs are not rendered by default.

14 changes: 9 additions & 5 deletions src/style/base/variable/color.less
Original file line number Diff line number Diff line change
Expand Up @@ -15,11 +15,15 @@
*/

// color
@weuiColorPrimary: #1AAD19;
@weuiThemeColor: #1AAD19;
@weuiColorWarn: #E64340;

// link
@weuiLinkColorDefault: #586C94;
@weuiLinkColorPrimary: #09BB07;

// icon
@weuiIconThemeColor: #09BB07;

// background
@weuiBgColorDefault: #EFEFF4;
Expand All @@ -30,10 +34,10 @@
@weuiLineColorDark: #BCBAB6;

// text
@weuiTextColorTitle: #000000;
@weuiTextColorTips: #B2B2B2;
@weuiTextColorWarn: @weuiColorWarn;
@weuiTextColorGray: #999999;
@weuiGlobalColor: #000000;
@weuiDescColor: #353535;
@weuiTipsColor: #B2B2B2;
@weuiGrayColor: #808080;



Expand Down
1 change: 0 additions & 1 deletion src/style/base/variable/weui-dialog.less
Original file line number Diff line number Diff line change
Expand Up @@ -16,6 +16,5 @@

@weuiDialogBackgroundColor: #FFFFFF;
@weuiDialogLineColor: #D5D5D6;
@weuiDialogLinkColor: #3CC51F;
@weuiDialogLinkActiveBc: #EEEEEE;
@weuiDialogGapWidth: 1.6em;
12 changes: 6 additions & 6 deletions src/style/icon/weui-icon_font.less
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,7 @@
}
.weui-icon-success {
font-size: 23px;
color: #09BB07;
color: @weuiIconThemeColor;
}
.weui-icon-waiting {
font-size: 23px;
Expand All @@ -38,11 +38,11 @@

.weui-icon-success-circle {
font-size: 23px;
color: #09BB07;
color: @weuiIconThemeColor;
}
.weui-icon-success-no-circle {
font-size: 23px;
color: #09BB07;
color: @weuiIconThemeColor;
}
.weui-icon-waiting-circle {
font-size: 23px;
Expand All @@ -54,16 +54,16 @@
}
.weui-icon-download {
font-size: 23px;
color: #09BB07;
color: @weuiIconThemeColor;
}

.weui-icon-info-circle {
font-size: 23px;
color: #09BB07;
color: @weuiIconThemeColor;
}

.weui-icon-safe-success {
color: #09BB07;
color: @weuiIconThemeColor;
}
.weui-icon-safe-warn {
color: #FFBE00;
Expand Down
4 changes: 2 additions & 2 deletions src/style/widget/weui-agree/weui-agree.less
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,7 @@
}
}
.weui-agree__text{
color: @weuiTextColorGray;
color: @weuiGrayColor;
}
.weui-agree__checkbox{
appearance: none;
Expand Down Expand Up @@ -56,7 +56,7 @@
vertical-align: middle;
text-decoration: inherit;
content: "\EA08";
color: #09BB07;
color: @weuiIconThemeColor;
font-size: 13px;

position: absolute;
Expand Down
2 changes: 1 addition & 1 deletion src/style/widget/weui-cell/weui-access.less
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,7 @@
.setTapColor();
color: inherit;
&:active {
background-color: #ECECEC;
background-color: @weuiBgColorActive;
}
.weui-cell__ft {
padding-right: 13px;
Expand Down
6 changes: 3 additions & 3 deletions src/style/widget/weui-cell/weui-cell_global.less
Original file line number Diff line number Diff line change
Expand Up @@ -48,7 +48,7 @@ z-index:
margin-bottom: .3em; // 8px - 行高
padding-left: @weuiCellGapH;
padding-right: @weuiCellGapH;
color: @weuiTextColorGray;
color: @weuiGrayColor;
font-size: @weuiCellTipsFontSize;

& + .weui-cells {
Expand All @@ -58,7 +58,7 @@ z-index:

.weui-cells__tips {
margin-top: .3em; // 8px - 行高
color: @weuiTextColorGray;
color: @weuiGrayColor;
padding-left: @weuiCellGapH;
padding-right: @weuiCellGapH;
font-size: @weuiCellTipsFontSize;
Expand Down Expand Up @@ -88,5 +88,5 @@ z-index:
}
.weui-cell__ft {
text-align: right;
color: @weuiTextColorGray;
color: @weuiGrayColor;
}
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,7 @@
.weui-check__label {
.setTapColor();
&:active {
background-color: #ECECEC;
background-color: @weuiBgColorActive;
}
}

Expand Down
2 changes: 1 addition & 1 deletion src/style/widget/weui-cell/weui-check/weui-checkbox.less
Original file line number Diff line number Diff line change
Expand Up @@ -38,7 +38,7 @@
& + .weui-icon-checked {
&:before {
content: '\EA06';
color: #09BB07;
color: @weuiIconThemeColor;
}
}
}
Expand Down
2 changes: 1 addition & 1 deletion src/style/widget/weui-cell/weui-check/weui-radio.less
Original file line number Diff line number Diff line change
Expand Up @@ -30,7 +30,7 @@
&:before {
display: block;
content: '\EA08';
color: #09BB07;
color: @weuiIconThemeColor;
font-size: 16px;
}
}
Expand Down
10 changes: 5 additions & 5 deletions src/style/widget/weui-cell/weui-form/weui-form-preview.less
Original file line number Diff line number Diff line change
Expand Up @@ -44,7 +44,7 @@
padding: @weuiCellGapV @weuiCellGapH;
font-size: .9em;
text-align: right;
color: @weuiTextColorGray;
color: @weuiGrayColor;
line-height: 2;
}
.weui-form-preview__ft{
Expand All @@ -62,7 +62,7 @@
float: left;
margin-right: 1em;
min-width: 4em;
color: @weuiTextColorGray;
color: @weuiGrayColor;
text-align: justify;
text-align-last: justify;
}
Expand All @@ -76,7 +76,7 @@
position: relative;
display: block;
flex: 1;
color: @weuiDialogLinkColor;
color: @weuiLinkColorPrimary;
text-align: center;
.setTapColor();
button&{
Expand All @@ -99,8 +99,8 @@
}
}
.weui-form-preview__btn_default {
color: @weuiTextColorGray;
color: @weuiGrayColor;
}
.weui-form-preview__btn_primary {
color: #0BB20C;
color: @weuiLinkColorPrimary;
}
6 changes: 3 additions & 3 deletions src/style/widget/weui-cell/weui-form/weui-form_common.less
Original file line number Diff line number Diff line change
Expand Up @@ -50,10 +50,10 @@
}

.weui-textarea-counter{
color: @weuiTextColorTips;
color: @weuiTipsColor;
text-align: right;
.weui-cell_warn &{
color: @weuiTextColorWarn;
color: @weuiColorWarn;
}
}

Expand Down Expand Up @@ -86,6 +86,6 @@
}
}
.weui-cell_warn{
color:@weuiTextColorWarn;
color: @weuiColorWarn;
.weui-icon-warn{display:inline-block;}
}
4 changes: 2 additions & 2 deletions src/style/widget/weui-cell/weui-form/weui-vcode.less
Original file line number Diff line number Diff line change
Expand Up @@ -36,7 +36,7 @@
line-height: @weuiCellHeight;
vertical-align: middle;
font-size: @weuiCellFontSize;
color: @weuiDialogLinkColor;
color: @weuiLinkColorPrimary;
button&{
background-color: transparent;
border-top: 0;
Expand All @@ -45,6 +45,6 @@
outline: 0;
}
&:active {
color: desaturate(@weuiDialogLinkColor, 30%);
color: desaturate(@weuiLinkColorPrimary, 30%);
}
}
4 changes: 2 additions & 2 deletions src/style/widget/weui-cell/weui-switch.less
Original file line number Diff line number Diff line change
Expand Up @@ -61,8 +61,8 @@
}
.weui-switch:checked,
.weui-switch-cp__input:checked ~ .weui-switch-cp__box{
border-color: #04BE02;
background-color: #04BE02;
border-color: @weuiThemeColor;
background-color: @weuiThemeColor;
&:before {
transform: scale(0);
}
Expand Down
2 changes: 1 addition & 1 deletion src/style/widget/weui-cell/weui-uploader.less
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,7 @@
flex: 1;
}
.weui-uploader__info{
color: @weuiTextColorTips;
color: @weuiTipsColor;
}

.weui-uploader__bd{
Expand Down
2 changes: 1 addition & 1 deletion src/style/widget/weui-footer/weui-footer.less
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@
@import "../../base/fn";

.weui-footer {
color: @weuiTextColorGray;
color: @weuiGrayColor;
font-size: 14px;
text-align: center;
a{
Expand Down
2 changes: 1 addition & 1 deletion src/style/widget/weui-grid/weui-grid.less
Original file line number Diff line number Diff line change
Expand Up @@ -66,7 +66,7 @@
.weui-grid__label {
display: block;
text-align: center;
color: @weuiTextColorTitle;
color: @weuiGlobalColor;
font-size: @weuiGridFontSize;
white-space: nowrap;
text-overflow: ellipsis;
Expand Down
4 changes: 2 additions & 2 deletions src/style/widget/weui-media-box/weui-media-box.less
Original file line number Diff line number Diff line change
Expand Up @@ -33,7 +33,7 @@
color:#000000;
.setTapColor();
&:active{
background-color:#ECECEC;
background-color: @weuiBgColorActive;
}
}
}
Expand All @@ -45,7 +45,7 @@
word-break: break-all;
}
.weui-media-box__desc {
color: @weuiTextColorGray;
color: @weuiGrayColor;
font-size: 13px;
line-height: 1.2;
.ellipsisLn(2);
Expand Down
4 changes: 2 additions & 2 deletions src/style/widget/weui-page/weui-msg.less
Original file line number Diff line number Diff line change
Expand Up @@ -38,15 +38,15 @@
}
.weui-msg__desc {
font-size: 14px;
color: @weuiTextColorGray;
color: @weuiGrayColor;
}
.weui-msg__opr-area {
margin-bottom: @weuiMsgOprGap;
}
.weui-msg__extra-area {
margin-bottom: @weuiMsgExtraAreaGap;
font-size: 14px;
color: @weuiTextColorGray;
color: @weuiGrayColor;
a{color: @weuiLinkColorDefault;}
}

Expand Down
2 changes: 1 addition & 1 deletion src/style/widget/weui-panel/weui-panel.less
Original file line number Diff line number Diff line change
Expand Up @@ -36,7 +36,7 @@

.weui-panel__hd {
padding: 14px 15px 10px;
color: @weuiTextColorGray;
color: @weuiGrayColor;
font-size: 13px;
position: relative;
&:after {
Expand Down
6 changes: 3 additions & 3 deletions src/style/widget/weui-picker/weui-picker.less
Original file line number Diff line number Diff line change
Expand Up @@ -44,7 +44,7 @@
.weui-picker__action {
display: block;
flex: 1;
color: @weuiColorPrimary;
color: @weuiThemeColor;

&:first-child {
text-align: left;
Expand Down Expand Up @@ -112,12 +112,12 @@
height: @pickerItemHeight;
line-height: @pickerItemHeight;
text-align: center;
color: #000;
color: @weuiGlobalColor;
text-overflow: ellipsis;
white-space: nowrap;
overflow: hidden;
}

.weui-picker__item_disabled {
color: @weuiTextColorGray;
color: @weuiGrayColor;
}
4 changes: 2 additions & 2 deletions src/style/widget/weui-searchbar/weui-searchbar.less
Original file line number Diff line number Diff line change
Expand Up @@ -99,7 +99,7 @@
z-index: 2;
border-radius: 3px;
text-align: center;
color: #9B9B9B;
color: @weuiGrayColor;
background: #FFFFFF;
span {
display: inline-block;
Expand All @@ -114,7 +114,7 @@
display: none;
margin-left: 10px;
line-height: 28px;
color: #09BB07;
color: @weuiLinkColorPrimary;
white-space: nowrap;
}
.weui-search-bar__input:not(:valid) ~ .weui-icon-clear {
Expand Down
4 changes: 2 additions & 2 deletions src/style/widget/weui-slider/weui-slider.less
Original file line number Diff line number Diff line change
Expand Up @@ -29,7 +29,7 @@

.weui-slider__track {
height: 2px;
background-color: @weuiColorPrimary;
background-color: @weuiThemeColor;
width: 0;
}

Expand Down Expand Up @@ -57,7 +57,7 @@
.weui-slider-box__value {
margin-left: .5em;
min-width: 24px;
color: #888888;
color: @weuiGrayColor;
text-align: center;
font-size: 14px;
}
4 changes: 2 additions & 2 deletions src/style/widget/weui-tab/weui-navbar.less
Original file line number Diff line number Diff line change
Expand Up @@ -44,11 +44,11 @@
.setTapColor();

&:active {
background-color: #EDEDED;
background-color: @weuiBgColorActive;
}

&.weui-bar__item_on {
background-color: #EAEAEA;
background-color: @weuiBgColorActive;
}

&:after {
Expand Down
Loading