UNPKG

yyzone

Version:

yyzone vue components and utils

391 lines (333 loc) 9.67 kB
@prefixDatePickerCls: ~"@{yy-css-prefix}date-picker"; @prefixPickerCls: ~"@{yy-css-prefix}picker"; @yy-date-picker-cells-width: 196px; @yy-date-picker-cells-width-with-weeknumbers: 226px; .@{prefixDatePickerCls} { //position: relative; display: inline-block; line-height: normal; font-size: 12px; &-editor { .@{prefixInputCls}[readonly] { background-color: @yy-background-component; cursor: auto; &:hover { background-color: @yy-background-component; border-color: tint(@yy-input-hover-border-color, 20%); } } } &-rel { position: relative; } .@{prefixSelectCls}-dropdown { width: auto; padding: 0; overflow: visible; max-height: none; } &-cells { width: @yy-date-picker-cells-width; margin: 10px; white-space: normal; span { display: inline-block; width: 24px; height: 24px; em { display: inline-block; width: 24px; height: 24px; line-height: 24px; margin: 2px; font-style: normal; border-radius: @yy-btn-border-radius; text-align: center; transition: all @yy-transition-time @yy-ease-in-out; } } &-header span { line-height: 24px; text-align: center; margin: 2px; color: @yy-text-info-color; } &-cell:hover { em { background: @yy-background-color-hover; } } &-week { &-selected, &-selected.yy-date-picker-cells-dbweek + .yy-date-picker-cells-week { background: fade(@yy-skybule-color, 10%); color: @yy-skybule-color; &:hover { background: fade(@yy-skybule-color, 10%); em { background-color: transparent; } } } &:hover { background: @yy-background-color-hover; em { background-color: transparent; } } } &-dbweek { &:hover + .yy-date-picker-cells-week { background: @yy-background-color-hover; em { background-color: transparent; } } } &-cell { span& { width: 28px; height: 28px; cursor: pointer; } &-prev-month, &-next-month { em { color: @yy-text-info-color; } &:hover { em { background: transparent; } } } span&-week-label, span&-week-label:hover, span&-disabled, span&-disabled:hover { .cursor(not-allowed); color: @yy-btn-disable-color; em { color: inherit; background: inherit; } } span&-disabled, span&-disabled:hover { background: @yy-btn-disable-bg; } &-today { em { position: relative; box-sizing: border-box; color: @yy-skybule-color; border: 1px solid @yy-skybule-color; border-radius: 3px; // background-color: @yy-background-body; // &:after { // content: ''; // display: block; // width: 6px; // height: 6px; // border-radius: 3px; // background: @yy-skybule-color; // position: absolute; // top: 1px; // right: 1px; // } } } &-range { position: relative; em { position: relative; z-index: 1; } &:before { content: ''; display: block; background: @yy-background-color-hover; border-radius: 0; border: 0; position: absolute; top: 2px; bottom: 2px; left: 0; right: 0; } } &-selected, &-selected:hover { em { background: fade(@yy-skybule-color, 100%); color: @yy-text-base-color; } } span&-disabled&-selected { em { background: @yy-btn-disable-color; color: @yy-btn-disable-bg; } } } } &-cells-show-week-numbers { width: @yy-date-picker-cells-width-with-weeknumbers; } &-cells-year, &-cells-month { margin-top: 14px; span { width: 40px; height: 28px; line-height: 28px; margin: 10px 12px; border-radius: @yy-btn-border-radius; em { width: 40px; height: 28px; line-height: 28px; margin: 0; } } .@{prefixDatePickerCls}-cells-cell-focused { background-color: fade(@yy-skybule-color, 10%); color: @yy-skybule-color; } } &-header { height: 32px; line-height: 32px; text-align: center; &-label { .cursor; transition: color @yy-transition-time @yy-ease-in-out; &:hover { color: @yy-skybule-color; } } } &-btn-pulse { background-color: tint(@yy-skybule-color, 80%) !important; border-radius: @yy-btn-border-radius; transition: background-color @yy-transition-time @yy-ease-in-out; } &-prev-btn { float: left; &-arrow-double { margin-left: 10px; i { font-size: 14px !important; } } } &-next-btn { float: right; &-arrow-double { margin-right: 10px; i { font-size: 14px !important; } } } &-with-range { .@{prefixPickerCls}-panel { &-body { min-width: (@yy-date-picker-cells-width + 22) * 2; } &-content { float: left; } } .@{prefixPickerCls}-cells-show-week-numbers { min-width: (@yy-date-picker-cells-width-with-weeknumbers + 22) * 2; } } &-with-week-numbers { .@{prefixPickerCls}-panel { &-body-date { min-width: (@yy-date-picker-cells-width-with-weeknumbers + 22) * 2; } } } &-transfer { z-index: 1060; max-height: none; width: auto; } &-focused input { // .active(); } } .@{prefixPickerCls} { &-panel { &-icon-btn { display: inline-block; width: 20px; height: 24px; line-height: 26px; margin-top: 4px; text-align: center; cursor: pointer; color: @yy-text-primary-color; transition: color @yy-transition-time @yy-ease-in-out; &:hover { color: @yy-skybule-color; } i { font-size: 10px; } } &-body-wrapper&-with-sidebar { padding-left: 92px; } &-sidebar { width: 92px; float: left; margin-left: -92px; position: absolute; top: 0; bottom: 0; background: @yy-background-component; border-right: 1px solid @yy-border-color-base; border-radius: @yy-btn-border-radius 0 0 @yy-btn-border-radius; overflow: auto; } &-shortcut { padding: @yy-btn-padding; transition: all @yy-transition-time @yy-ease-in-out; cursor: pointer; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; &:hover { background: @yy-background-color-selected; } } &-body { float: left; } } &-confirm { border-top: 1px solid @yy-border-color-base; text-align: right; padding: 8px; clear: both; &>span { // color: @link-color; cursor: pointer; user-select: none; float: left; padding: 2px 0; transition: all @yy-transition-time @yy-ease-in-out; // &:hover{ // color: @link-hover-color; // } // &:active{ // color: @link-active-color; // } } &-time { float: left; } } }