variables.scss 3.4 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177
  1. $font--role-default: 'Lato', sans-serif;
  2. $font--role-emphasis: 'Montserrat', sans-serif;
  3. $color__text--primary: rgba(0, 0, 0, 0.87);
  4. $color__text--secondary: rgba(0, 0, 0, 0.54);
  5. $color__lightgray--primary: #F5F5F5;
  6. $color__lightgray--darker: #EEEEEE;
  7. $color__lightgray--darkest: #E0E0E0;
  8. $color__gray--primary: #EEEEEE;
  9. $color__gray--darker: #E0E0E0;
  10. $color__gray--darkest: #BDBDBD;
  11. $color__darkgray--primary: #757575;
  12. $color__darkgray--darker: #525252;
  13. $color__darkgray--darkest: #424242;
  14. $color__orange--primary: #F57C00;
  15. $color__orange--darker: #EF6C00;
  16. $color__orange--darkest: #de621c;
  17. $color__green--primary: rgba(76, 175, 80, 0.86);
  18. $color__green--darker: #349238;
  19. $color__green--darkest: #1B5E20;
  20. $color__blue--primary: #1E88E5;
  21. $color__blue--darker: #1565C0;
  22. $color__blue--darkest: #0D47A1;
  23. $color__red--primary: #e74860;
  24. $color__red--darker: #B71C1C;
  25. $color__lightblue--primary: #03A9F4;
  26. @keyframes flash {
  27. 0% {
  28. background-color: $color__gray--darker;
  29. }
  30. 50% {
  31. background-color: $color__lightgray--darkest;
  32. }
  33. 75% {
  34. background-color: $color__gray--primary;
  35. }
  36. to {
  37. background-color: $color__gray--darker;
  38. }
  39. }
  40. @mixin flash {
  41. animation-name: flash;
  42. animation-duration: 1s;
  43. animation-iteration-count: infinite;
  44. animation-timing-function: linear;
  45. }
  46. @mixin loading-overlay($background-color: #fff, $border-radius: 0.25rem) {
  47. width: 100%;
  48. height: 100%;
  49. position: absolute;
  50. background-color: $background-color;
  51. z-index: 1;
  52. top: 0;
  53. position: absolute;
  54. display: flex;
  55. align-items: center;
  56. justify-content: center;
  57. opacity: 0;
  58. pointer-events: none;
  59. transition: all 0.2s;
  60. @include user-select(none);
  61. cursor: default;
  62. border-radius: $border-radius;
  63. @at-root #{&}--show {
  64. opacity: 1;
  65. pointer-events: all;
  66. }
  67. @at-root #{&}__message {
  68. font-size: 1.5rem;
  69. color: #fff;
  70. font-style: italic;
  71. }
  72. }
  73. @mixin text($family: $font--role-default, $size: 1rem, $weight: 300) {
  74. font-family: $family;
  75. font-size: $size;
  76. font-weight: $weight;
  77. }
  78. @mixin optional-at-root($sel) {
  79. @at-root #{if(not &, $sel, selector-append(&, $sel))} {
  80. @content;
  81. }
  82. }
  83. @mixin placeholder {
  84. @include optional-at-root('::-webkit-input-placeholder') {
  85. @content;
  86. }
  87. @include optional-at-root(':-moz-placeholder') {
  88. @content;
  89. }
  90. @include optional-at-root('::-moz-placeholder') {
  91. @content;
  92. }
  93. @include optional-at-root(':-ms-input-placeholder') {
  94. @content;
  95. }
  96. }
  97. @mixin user-select($select) {
  98. @each $pre in -webkit-, -moz-, -ms-, -o- {
  99. #{$pre + user-select}: #{$select};
  100. }
  101. #{user-select}: #{$select};
  102. }
  103. .shadow_border {
  104. box-shadow: 0 0 0.3rem rgba(175, 175, 175, 0.25);
  105. }
  106. .shadow_border--hover {
  107. box-shadow: 0 0 0.3rem rgba(175, 175, 175, 0.25), 0 0.2rem 0.35rem rgba(175, 175, 175, 0.25);
  108. }
  109. .tab_button {
  110. padding: 0.5rem 0.75rem;
  111. border-radius: 3rem;
  112. cursor: pointer;
  113. transition: all 0.2s;
  114. margin-right: 0.5rem;
  115. display: inline-block;
  116. position: relative;
  117. top: -0.1rem;
  118. @include user-select(none);
  119. &:hover {
  120. background-color: $color__lightgray--darker;
  121. }
  122. &:active {
  123. background-color: #dcdcdc;
  124. }
  125. &::after {
  126. content: '';
  127. position: absolute;
  128. background-color: $color__blue--primary;
  129. width: calc(100% - 1rem);
  130. left: 0.5rem;
  131. bottom: -0.3rem;
  132. height: 0.2rem;
  133. opacity: 0;
  134. transition: opacity 0.2s;
  135. }
  136. @at-root #{&}--selected {
  137. cursor: default;
  138. font-weight: bold;
  139. &:active, &:hover {
  140. background-color: transparent;
  141. }
  142. &::after {
  143. opacity: 1;
  144. }
  145. }
  146. }