_timepicker.scss 2.8 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183
  1. /* Timepicker Containers */
  2. .timepicker-modal {
  3. max-width: 325px;
  4. max-height: none;
  5. }
  6. .timepicker-container.modal-content {
  7. display: flex;
  8. flex-direction: column;
  9. padding: 0;
  10. }
  11. .text-primary {
  12. color: rgba(255, 255, 255, 1);
  13. }
  14. /* Clock Digital Display */
  15. .timepicker-digital-display {
  16. flex: 1 auto;
  17. background-color: $secondary-color;
  18. padding: 10px;
  19. font-weight: 300;
  20. }
  21. .timepicker-text-container {
  22. font-size: 4rem;
  23. font-weight: bold;
  24. text-align: center;
  25. color: rgba(255, 255, 255, 0.6);
  26. font-weight: 400;
  27. position: relative;
  28. user-select: none;
  29. }
  30. .timepicker-span-hours,
  31. .timepicker-span-minutes,
  32. .timepicker-span-am-pm div {
  33. cursor: pointer;
  34. }
  35. .timepicker-span-hours {
  36. margin-right: 3px;
  37. }
  38. .timepicker-span-minutes {
  39. margin-left: 3px;
  40. }
  41. .timepicker-display-am-pm {
  42. font-size: 1.3rem;
  43. position: absolute;
  44. right: 1rem;
  45. bottom: 1rem;
  46. font-weight: 400;
  47. }
  48. /* Analog Clock Display */
  49. .timepicker-analog-display {
  50. flex: 2.5 auto;
  51. }
  52. .timepicker-plate {
  53. background-color: $timepicker-clock-plate-bg;
  54. border-radius: 50%;
  55. width: 270px;
  56. height: 270px;
  57. overflow: visible;
  58. position: relative;
  59. margin: auto;
  60. margin-top: 25px;
  61. margin-bottom: 5px;
  62. user-select: none;
  63. }
  64. .timepicker-canvas,
  65. .timepicker-dial {
  66. position: absolute;
  67. left: 0;
  68. right: 0;
  69. top: 0;
  70. bottom: 0;
  71. }
  72. .timepicker-minutes {
  73. visibility: hidden;
  74. }
  75. .timepicker-tick {
  76. border-radius: 50%;
  77. color: $timepicker-clock-color;
  78. line-height: 40px;
  79. text-align: center;
  80. width: 40px;
  81. height: 40px;
  82. position: absolute;
  83. cursor: pointer;
  84. font-size: 15px;
  85. }
  86. .timepicker-tick.active,
  87. .timepicker-tick:hover {
  88. background-color: transparentize($secondary-color, .75);
  89. }
  90. .timepicker-dial {
  91. transition: transform 350ms, opacity 350ms;
  92. }
  93. .timepicker-dial-out {
  94. &.timepicker-hours {
  95. transform: scale(1.1, 1.1);
  96. }
  97. &.timepicker-minutes {
  98. transform: scale(.8, .8);
  99. }
  100. opacity: 0;
  101. }
  102. .timepicker-canvas {
  103. transition: opacity 175ms;
  104. line {
  105. stroke: $secondary-color;
  106. stroke-width: 4;
  107. stroke-linecap: round;
  108. }
  109. }
  110. .timepicker-canvas-out {
  111. opacity: 0.25;
  112. }
  113. .timepicker-canvas-bearing {
  114. stroke: none;
  115. fill: $secondary-color;
  116. }
  117. .timepicker-canvas-bg {
  118. stroke: none;
  119. fill: $secondary-color;
  120. }
  121. /* Footer */
  122. .timepicker-footer {
  123. margin: 0 auto;
  124. padding: 5px 1rem;
  125. display: flex;
  126. justify-content: space-between;
  127. }
  128. .timepicker-clear {
  129. color: $error-color;
  130. }
  131. .timepicker-close {
  132. color: $secondary-color;
  133. }
  134. .timepicker-clear,
  135. .timepicker-close {
  136. padding: 0 20px;
  137. }
  138. /* Media Queries */
  139. @media #{$medium-and-up} {
  140. .timepicker-modal {
  141. max-width: 600px;
  142. }
  143. .timepicker-container.modal-content {
  144. flex-direction: row;
  145. }
  146. .timepicker-text-container {
  147. top: 32%;
  148. }
  149. .timepicker-display-am-pm {
  150. position: relative;
  151. right: auto;
  152. bottom: auto;
  153. text-align: center;
  154. margin-top: 1.2rem;
  155. }
  156. }