_components.scss 4.8 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292
  1. @use "sass:string";
  2. @use "mixins";
  3. @use "variables";
  4. /*=== COMPONENTS */
  5. /*===============*/
  6. /*=== Forms */
  7. // parti dans _forms.scss
  8. /*=== Horizontal-list */
  9. .horizontal-list {
  10. padding: 0.1rem 0;
  11. & > .item {
  12. &:first-child {
  13. padding-left: 0.5rem;
  14. }
  15. }
  16. }
  17. /*=== Dropdown */
  18. .dropdown {
  19. .dropdown-target:target + .btn {
  20. background-color: variables.$grey-medium-light;
  21. }
  22. }
  23. .dropdown-menu {
  24. margin: 9px 0 0 0;
  25. padding: 0.5rem 0 1rem 0;
  26. background: variables.$grey-lighter;
  27. font-size: 1rem;
  28. border: none;
  29. border-radius: 3px;
  30. box-shadow: 0px 6px 8px 0px rgba(0,0,0,0.35);
  31. text-align: left;
  32. &::after {
  33. border: none;
  34. right: 17px;
  35. }
  36. .dropdown-header,
  37. .dropdown-section .dropdown-section-title {
  38. padding: 1rem 1.5rem;
  39. font-weight: bold;
  40. text-align: left;
  41. color: variables.$grey-dark;
  42. text-transform: uppercase;
  43. letter-spacing: 1px;
  44. }
  45. .item {
  46. @include mixins.transition(all, 0.075s, ease-in-out);
  47. > a,
  48. > span,
  49. > .as-link {
  50. padding: 0 2rem;
  51. color: variables.$main-font-color;
  52. font-size: inherit;
  53. line-height: 2.5em;
  54. span.icon {
  55. padding: 0 0.25rem !important;
  56. }
  57. }
  58. > a,
  59. > .as-link {
  60. &:not(.addItem):hover {
  61. background: variables.$main-first;
  62. color: variables.$white;
  63. .icon {
  64. filter: grayscale(100%) brightness(2.5);
  65. }
  66. }
  67. }
  68. &.dropdown-section {
  69. margin-top: 0.75rem;
  70. ~ .dropdown-section {
  71. border-top-color: variables.$grey-light;
  72. }
  73. .item {
  74. a, .as-link {
  75. padding-left: 2rem;
  76. }
  77. }
  78. }
  79. &:not(.addItem) {
  80. > a:hover,
  81. button:hover {
  82. background: variables.$main-first;
  83. color: variables.$white;
  84. .icon {
  85. filter: brightness(3);
  86. }
  87. }
  88. }
  89. &[aria-checked="true"] {
  90. a::before {
  91. margin: 0 0 0 -14px;
  92. font-weight: bold;
  93. }
  94. }
  95. ~ .dropdown-header {
  96. margin-top: 0.75rem;
  97. padding-top: 1.75rem;
  98. border-top-color: variables.$grey-light;
  99. }
  100. &.separator {
  101. margin-top: 0.75rem;
  102. border-top-color: variables.$grey-light;
  103. }
  104. }
  105. .input {
  106. select, input {
  107. margin: 0 auto 5px;
  108. padding: 2px 5px;
  109. border-radius: 3px;
  110. }
  111. }
  112. }
  113. .tree .tree-folder .tree-folder-items .dropdown-menu {
  114. // to reset the appearance of the dropdown in the case of a dark sidebar
  115. .item {
  116. padding: 0;
  117. a,
  118. button {
  119. color: variables.$main-font-color;
  120. &:hover {
  121. color: variables.$white;
  122. }
  123. }
  124. &:hover {
  125. background: variables.$main-first;
  126. }
  127. }
  128. }
  129. /*=== Alerts */
  130. .alert {
  131. background: variables.$grey-lighter;
  132. color: variables.$grey-dark;
  133. font-size: 1rem;
  134. border: 1px solid variables.$grey-medium;
  135. border-radius: 3px;
  136. text-shadow: 0 0 1px variables.$grey-light;
  137. }
  138. .alert-head {
  139. font-size: 1.15em;
  140. }
  141. .alert > a {
  142. text-decoration: underline;
  143. color: inherit;
  144. }
  145. .alert-warn {
  146. background: variables.$warning-light;
  147. color: variables.$warning-text;
  148. border: 1px solid string.unquote(variables.$warning-text + '33'); // on ajoute l’opacité à la fin
  149. }
  150. .alert-success {
  151. background: variables.$success-light;
  152. color: variables.$success-text;
  153. border: 1px solid string.unquote(variables.$success-text + '33');
  154. }
  155. .alert-error {
  156. background: variables.$alert-light;
  157. color: variables.$alert-text;
  158. border: 1px solid string.unquote(variables.$alert-text + '33');
  159. }
  160. /*=== Pagination */
  161. .pagination {
  162. background: variables.$grey-light;
  163. color: variables.$main-font-color;
  164. .item a {
  165. color: variables.$main-font-color;
  166. }
  167. }
  168. #load_more.loading,
  169. #load_more.loading:hover {
  170. background: url("loader.gif") center center no-repeat #34495e;
  171. }
  172. /*=== Boxes */
  173. .box {
  174. background: variables.$white;
  175. // border: 1px solid #ddd;
  176. border: none;
  177. border-radius: 3px;
  178. box-shadow: 0px 2px 2px 0px rgba(0,0,0,0.25);
  179. .box-title {
  180. background: variables.$grey-light;
  181. color: variables.$main-font-color;
  182. border-radius: 2px 2px 0 0;
  183. }
  184. .box-content {
  185. padding-left: 30px;
  186. .item {
  187. padding: 0.5rem 0;
  188. color: variables.$main-font-color;
  189. font-size: 1rem;
  190. border-bottom: 1px solid variables.$grey-light;
  191. line-height: 1.7em;
  192. }
  193. .item:last-child {
  194. border-bottom: none;
  195. }
  196. }
  197. .configure {
  198. margin-right: 0.5rem;
  199. padding: 0.25rem;
  200. border-radius: 3px;
  201. .icon {
  202. vertical-align: middle;
  203. }
  204. &:hover {
  205. border-radius: 2px;
  206. background-color: variables.$main-first;
  207. .icon {
  208. filter: brightness(3);
  209. }
  210. }
  211. }
  212. }
  213. /*=== "Load more" part */
  214. #bigMarkAsRead.big {
  215. text-align: center;
  216. text-decoration: none;
  217. background: variables.$main-first-light;
  218. color: variables.$main-first;
  219. @include mixins.transition(all, 0.15s, ease-in-out);
  220. &:hover {
  221. background: variables.$main-first;
  222. color: #fff;
  223. .bigTick {
  224. filter: brightness(7);
  225. }
  226. }
  227. .bigTick {
  228. margin: 0.5rem 0;
  229. background: url(icons/tick-color.svg) center no-repeat;
  230. display: inline-block;
  231. width: 64px;
  232. height: 64px;
  233. text-indent: -9999px;
  234. white-space: nowrap;
  235. }
  236. }