@lxlib/theme
Version:
This library was generated with [Angular CLI](https://github.com/angular/angular-cli) version 9.1.1.
62 lines (50 loc) • 3.34 kB
text/less
// color
.bg-white { background-color: #fff ; }
.bg-transparent { background-color: transparent ; }
.text-white { color: #fff ; }
.text-hover {
cursor: pointer;
&:hover { color: @primary-color ; }
}
.for-each(@colors, {
.bg-@{adKey}-light { background-color: extract(@adItem, @color-light-position) ; }
.bg-@{adKey} { background-color: extract(@adItem, @color-basic-position) ; }
.bg-@{adKey}-dark { background-color: extract(@adItem, @color-dark-position) ; }
.bg-@{adKey}-light-h { transition: background-color 300ms; &:hover { background-color: extract(@adItem, @color-light-position) ; } }
.bg-@{adKey}-h { transition: background-color 300ms; &:hover { background-color: extract(@adItem, @color-basic-position) ; } }
.bg-@{adKey}-dark-h { transition: background-color 300ms; &:hover { background-color: extract(@adItem, @color-dark-position) ; } }
.text-@{adKey}-light { color: extract(@adItem, @color-light-position) ; }
.text-@{adKey} { color: extract(@adItem, @color-basic-position) ; }
.text-@{adKey}-dark { color: extract(@adItem, @color-dark-position) ; }
});
.for-each(@aliasColors, {
.bg-@{adKey}-light { background-color: ~`getColor("@{colors}", "@{adValue}", @{color-light-position})` ; }
.bg-@{adKey} { background-color: ~`getColor("@{colors}", "@{adValue}", @{color-basic-position})` ; }
.bg-@{adKey}-dark { background-color: ~`getColor("@{colors}", "@{adValue}", @{color-dark-position})` ; }
.bg-@{adKey}-light-h { transition: background-color 300ms; &:hover { background-color: ~`getColor("@{colors}", "@{adValue}", @{color-light-position})` ; } }
.bg-@{adKey}-h { transition: background-color 300ms; &:hover { background-color: ~`getColor("@{colors}", "@{adValue}", @{color-basic-position})` ; } }
.bg-@{adKey}-dark-h { transition: background-color 300ms; &:hover { background-color: ~`getColor("@{colors}", "@{adValue}", @{color-dark-position})` ; } }
.text-@{adKey}-light { color: ~`getColor("@{colors}", "@{adValue}", @{color-light-position})` ; }
.text-@{adKey} { color: ~`getColor("@{colors}", "@{adValue}", @{color-basic-position})` ; }
.text-@{adKey}-dark { color: ~`getColor("@{colors}", "@{adValue}", @{color-dark-position})` ; }
});
// grey
.for-each(@greyColorer, {
.bg-grey-@{adKey} { background-color: @adValue ; }
.bg-grey-@{adKey}-h { &:hover { background-color: @adValue ; } }
.text-grey-@{adKey} { color: @adValue ; }
});
.all-colors-minin(@enabled) when (@enabled = true) {
.loop-no(@adKey, @adValue, @i: 1) when (@i =< length(@color-no-list)) {
// @color-no-list
@name: "@{adKey}-@{i}";
.bg-@{adKey}-@{i} { background-color: @@name ; }
.bg-@{adKey}-@{i}-h { transition: background-color 300ms; &:hover { background-color: @@name ; } }
.text-@{adKey}-@{i} { color: @@name ; }
.loop-no(@adKey, @adValue, @i + 1);
}
.for-each(@colors, {
.loop-no(@adKey, @adValue, 1);
});
}
.all-colors-minin(@enable-all-colors);