Skip to content

Commit

Permalink
Add @switch-color to control switch colors (#8940)
Browse files Browse the repository at this point in the history
  • Loading branch information
megawac authored and afc163 committed Jan 12, 2018
1 parent 88e0c9b commit b9b5aba
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 3 deletions.
1 change: 1 addition & 0 deletions components/style/themes/default.less
Expand Up @@ -393,6 +393,7 @@
@switch-height: 22px;
@switch-sm-height: 16px;
@switch-disabled-opacity: 0.4;
@switch-color: @primary-color;

// Pagination
// ---
Expand Down
6 changes: 3 additions & 3 deletions components/switch/style/index.less
Expand Up @@ -68,11 +68,11 @@
}

&-checked&-loading:before {
color: @primary-color;
color: @switch-color;
}

&:focus {
box-shadow: 0 0 0 2px fade(@primary-color, 20%);
box-shadow: 0 0 0 2px fade(@switch-color, 20%);
outline: 0;
}

Expand Down Expand Up @@ -127,7 +127,7 @@
}

&-checked {
background-color: @primary-color;
background-color: @switch-color;

.@{switch-prefix-cls}-inner {
margin-left: 6px;
Expand Down

0 comments on commit b9b5aba

Please sign in to comment.