picker-panel.scss 2.9 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131
  1. @use '../mixins/mixins' as *;
  2. @use '../common/var' as *;
  3. @include b(picker-panel) {
  4. color: getCssVar('text-color', 'regular');
  5. background: getCssVar('bg-color', 'overlay');
  6. border-radius: getCssVar('border-radius-base');
  7. line-height: 30px;
  8. .#{$namespace}-time-panel {
  9. margin: 5px 0;
  10. border: solid 1px getCssVar('datepicker-border-color');
  11. background-color: getCssVar('bg-color', 'overlay');
  12. box-shadow: getCssVar('box-shadow-light');
  13. }
  14. @include e((body, body-wrapper)) {
  15. &::after {
  16. content: '';
  17. display: table;
  18. clear: both;
  19. }
  20. }
  21. @include e(content) {
  22. position: relative;
  23. margin: 15px;
  24. }
  25. @include e(footer) {
  26. border-top: 1px solid getCssVar('datepicker-inner-border-color');
  27. padding: 4px 12px;
  28. text-align: right;
  29. background-color: getCssVar('bg-color', 'overlay');
  30. position: relative;
  31. font-size: 0;
  32. }
  33. @include e(shortcut) {
  34. display: block;
  35. width: 100%;
  36. border: 0;
  37. background-color: transparent;
  38. line-height: 28px;
  39. font-size: 14px;
  40. color: getCssVar('datepicker-text-color');
  41. padding-left: 12px;
  42. text-align: left;
  43. outline: none;
  44. cursor: pointer;
  45. &:hover {
  46. color: getCssVar('datepicker-hover-text-color');
  47. }
  48. &.active {
  49. background-color: #e6f1fe;
  50. color: getCssVar('datepicker-active-color');
  51. }
  52. }
  53. @include e(btn) {
  54. border: 1px solid getCssVar('fill-color', 'darker');
  55. color: getCssVar('text-color', 'primary');
  56. line-height: 24px;
  57. border-radius: 2px;
  58. padding: 0 20px;
  59. cursor: pointer;
  60. background-color: transparent;
  61. outline: none;
  62. font-size: 12px;
  63. &[disabled] {
  64. color: getCssVar('text-color', 'disabled');
  65. cursor: not-allowed;
  66. }
  67. }
  68. @include e(icon-btn) {
  69. font-size: 12px;
  70. color: getCssVar('datepicker-icon-color');
  71. border: 0;
  72. background: transparent;
  73. cursor: pointer;
  74. outline: none;
  75. margin-top: 8px;
  76. &:hover {
  77. color: getCssVar('datepicker-hover-text-color');
  78. }
  79. &:focus-visible {
  80. color: getCssVar('datepicker-hover-text-color');
  81. }
  82. @include when(disabled) {
  83. color: getCssVar('text-color-disabled');
  84. &:hover {
  85. cursor: not-allowed;
  86. }
  87. }
  88. & .#{$namespace}-icon {
  89. cursor: pointer;
  90. font-size: inherit;
  91. }
  92. }
  93. @include e(link-btn) {
  94. vertical-align: middle;
  95. }
  96. }
  97. .#{$namespace}-picker-panel *[slot='sidebar'],
  98. .#{$namespace}-picker-panel__sidebar {
  99. position: absolute;
  100. top: 0;
  101. bottom: 0;
  102. width: 110px;
  103. border-right: 1px solid getCssVar('datepicker-inner-border-color');
  104. box-sizing: border-box;
  105. padding-top: 6px;
  106. background-color: getCssVar('bg-color', 'overlay');
  107. overflow: auto;
  108. }
  109. .#{$namespace}-picker-panel
  110. *[slot='sidebar']
  111. + .#{$namespace}-picker-panel__body,
  112. .#{$namespace}-picker-panel__sidebar + .#{$namespace}-picker-panel__body {
  113. margin-left: 110px;
  114. }