UNPKG

@fe6/water-pro

Version:

An enterprise-class UI design language and Vue-based implementation

135 lines (131 loc) 3.11 kB
@import '../../style/themes/index'; @import '../../style/mixins/index'; @import '../../input/style/mixin'; @import './monolith'; @color-picker-prefix-cls: ~'@{ant-prefix}-color-picker'; .@{color-picker-prefix-cls} { position: relative; display: inline-block; box-sizing: border-box; min-width: 55px; margin: 0; padding: 0; color: rgba(0, 0, 0, 0.65); font-size: 14px; font-variant: tabular-nums; line-height: 1.5; list-style: none; outline: none; cursor: pointer; transition: opacity 0.3s; font-feature-settings: 'tnum'; .pickr { display: inline-block; transform: translateY(-1px); .pcr-button { width: 18px; height: 18px; margin-left: 7px; border: 1px solid @border-color-base; &:focus { box-shadow: none; } &.clear { background-size: 60%; } } } &.@{color-picker-prefix-cls}-disabled { cursor: not-allowed; .@{color-picker-prefix-cls}-selection { background: @input-disabled-bg; border: @border-width-base @border-style-base @select-border-color; box-shadow: none; &:hover, &:focus, &:active { border: @border-width-base @border-style-base @select-border-color; box-shadow: none; } } &.@{color-picker-prefix-cls}-open { .@{color-picker-prefix-cls}-icon { & svg { transform: none; } } } } &-open { .@{color-picker-prefix-cls}-icon { & svg { transform: rotate(180deg); } } .@{color-picker-prefix-cls}-selection { .active(); } } &-selection { position: relative; display: block; box-sizing: border-box; height: @input-height-base; background-color: @select-background; border: @border-width-base @border-style-base @select-border-color; border-top-width: @border-width-base + 0.02px; border-radius: @border-radius-base; outline: none; cursor: inherit; transition: all 0.3s @ease-in-out; user-select: none; &:hover { .hover(); } } &-icon { .iconfont-mixin(); position: absolute; top: 50%; right: @control-padding-horizontal - 4px; margin-top: (-@font-size-sm / 2); color: @disabled-color; font-size: @font-size-sm; line-height: 1; transform-origin: 50% 50%; & svg { transition: transform 0.3s; } } &-lg { font-size: @font-size-lg; .@{color-picker-prefix-cls}-selection { height: @input-height-lg; line-height: @input-height-lg - 12; } .@{color-picker-prefix-cls}-icon { top: (@input-height-lg / 2); } .pickr { transform: translateY(0); } } &-sm { .@{color-picker-prefix-cls}-selection { height: @input-height-sm; line-height: @input-height-sm - 12; } .pickr .pcr-button { width: 14px; height: 14px; } .@{color-picker-prefix-cls}-icon { top: (@input-height-sm / 2); right: @control-padding-horizontal - 2px; font-size: 10px; } .pickr { transform: translateY(0); } } }