time-picker.scss 1.7 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990
  1. @use '../mixins/mixins' as *;
  2. @use '../common/var' as *;
  3. @include b(time-panel) {
  4. border-radius: 2px;
  5. position: relative;
  6. width: 180px;
  7. left: 0;
  8. z-index: getCssVar('index-top');
  9. user-select: none;
  10. box-sizing: content-box;
  11. @include e(content) {
  12. font-size: 0;
  13. position: relative;
  14. overflow: hidden;
  15. &::after,
  16. &::before {
  17. content: '';
  18. top: 50%;
  19. position: absolute;
  20. margin-top: -16px;
  21. height: 32px;
  22. z-index: -1;
  23. left: 0;
  24. right: 0;
  25. box-sizing: border-box;
  26. padding-top: 6px;
  27. text-align: left;
  28. }
  29. &::after {
  30. left: 50%;
  31. margin-left: 12%;
  32. margin-right: 12%;
  33. }
  34. &::before {
  35. padding-left: 50%;
  36. margin-right: 12%;
  37. margin-left: 12%;
  38. border-top: 1px solid getCssVar('border-color-light');
  39. border-bottom: 1px solid getCssVar('border-color-light');
  40. }
  41. &.has-seconds {
  42. &::after {
  43. left: calc(100% / 3 * 2);
  44. }
  45. &::before {
  46. padding-left: calc(100% / 3);
  47. }
  48. }
  49. }
  50. @include e(footer) {
  51. border-top: 1px solid
  52. var(
  53. #{getCssVarName('timepicker-inner-border-color')},
  54. #{getCssVar('border-color-light')}
  55. );
  56. padding: 4px;
  57. height: 36px;
  58. line-height: 25px;
  59. text-align: right;
  60. box-sizing: border-box;
  61. }
  62. @include e(btn) {
  63. border: none;
  64. line-height: 28px;
  65. padding: 0 5px;
  66. margin: 0 5px;
  67. cursor: pointer;
  68. background-color: transparent;
  69. outline: none;
  70. font-size: 12px;
  71. color: getCssVar('text-color', 'primary');
  72. &.confirm {
  73. font-weight: 800;
  74. color: var(
  75. #{getCssVarName('timepicker-active-color')},
  76. #{getCssVar('color-primary')}
  77. );
  78. }
  79. }
  80. }