@expressivecss/expressive 0.1.0-alpha.3 → 0.2.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (154) hide show
  1. package/LICENSE +82 -2
  2. package/README.md +153 -43
  3. package/dist/css/expressive.css +7121 -9658
  4. package/dist/css/expressive.css.map +1 -0
  5. package/dist/css/expressive.min.css +1 -1
  6. package/dist/css/expressive.min.css.map +1 -0
  7. package/dist/js/expressive.cjs +7521 -0
  8. package/dist/js/expressive.cjs.map +7 -0
  9. package/dist/js/expressive.js +7383 -8099
  10. package/dist/js/expressive.js.map +7 -1
  11. package/dist/js/expressive.min.js +75 -1
  12. package/dist/js/expressive.min.js.map +7 -1
  13. package/dist/js/expressive.mjs +7292 -7998
  14. package/dist/js/expressive.mjs.map +7 -1
  15. package/dist/types/behaviors/dialogs.d.ts +25 -0
  16. package/dist/{js → types}/components/autocomplete.d.ts +10 -1
  17. package/dist/{js → types}/components/buttons.d.ts +11 -1
  18. package/dist/{js → types}/components/cards.d.ts +10 -1
  19. package/dist/{js → types}/components/carousel.d.ts +4 -5
  20. package/dist/{js/forms/character-counter.d.ts → types/components/characterCounter.d.ts} +1 -1
  21. package/dist/{js → types}/components/chips.d.ts +1 -1
  22. package/dist/{js → types}/components/collapsible.d.ts +1 -1
  23. package/dist/{js → types}/components/datepicker.d.ts +63 -2
  24. package/dist/{js → types}/components/dropdown.d.ts +3 -3
  25. package/dist/types/components/index.d.ts +23 -0
  26. package/dist/{js/components/materialbox.d.ts → types/components/lightbox.d.ts} +21 -21
  27. package/dist/{js → types}/components/modal.d.ts +1 -1
  28. package/dist/{js → types}/components/parallax.d.ts +11 -5
  29. package/dist/{js → types}/components/pushpin.d.ts +1 -1
  30. package/dist/{js/forms → types/components}/range.d.ts +3 -3
  31. package/dist/types/components/registry.d.ts +107 -0
  32. package/dist/{js → types}/components/scrollspy.d.ts +6 -9
  33. package/dist/{js/forms → types/components}/select.d.ts +11 -2
  34. package/dist/{js → types}/components/sidenav.d.ts +1 -1
  35. package/dist/{js → types}/components/slider.d.ts +3 -2
  36. package/dist/{js → types}/components/tabs.d.ts +3 -2
  37. package/dist/{js/components/tap-target.d.ts → types/components/tapTarget.d.ts} +2 -2
  38. package/dist/{js → types}/components/timepicker.d.ts +13 -5
  39. package/dist/{js/components/toast.d.ts → types/components/toasts.d.ts} +28 -4
  40. package/dist/{js → types}/components/tooltip.d.ts +2 -2
  41. package/dist/types/core/bounding.d.ts +6 -0
  42. package/dist/{js/foundation → types/core}/component.d.ts +1 -1
  43. package/dist/types/core/edges.d.ts +6 -0
  44. package/dist/{js/foundation → types/core}/utils.d.ts +21 -14
  45. package/dist/types/index.d.ts +7 -0
  46. package/dist/{js/plugins/docked-display.d.ts → types/plugins/dockedDisplayPlugin.d.ts} +7 -0
  47. package/package.json +60 -36
  48. package/src/sass/README.md +200 -0
  49. package/src/sass/abstracts/_breakpoints.scss +69 -0
  50. package/src/sass/abstracts/_elevation.scss +34 -0
  51. package/src/sass/abstracts/_index.scss +7 -0
  52. package/src/sass/abstracts/_mixins.scss +171 -0
  53. package/src/sass/abstracts/_variables.scss +57 -0
  54. package/src/{scss/layout/_table.scss → sass/base/_global.scss} +64 -2
  55. package/src/{scss/layout → sass/base}/_grid.scss +6 -6
  56. package/src/sass/base/_index.scss +6 -0
  57. package/src/{scss/foundation → sass/base}/_normalize.scss +51 -139
  58. package/src/sass/base/_typography.scss +90 -0
  59. package/src/sass/components/_badges.scss +77 -0
  60. package/src/{scss → sass}/components/_breadcrumb.scss +2 -0
  61. package/src/sass/components/_buttons.scss +407 -0
  62. package/src/sass/components/_cards.scss +328 -0
  63. package/src/{scss → sass}/components/_carousel.scss +5 -3
  64. package/src/sass/components/_chips.scss +140 -0
  65. package/src/sass/components/_collapsible.scss +81 -0
  66. package/src/{scss → sass}/components/_collection.scss +2 -2
  67. package/src/{scss/components/_date-picker.scss → sass/components/_datepicker.scss} +51 -44
  68. package/src/sass/components/_docked-display.scss +11 -0
  69. package/src/sass/components/_dropdown.scss +129 -0
  70. package/src/{scss/components/_material-icons.scss → sass/components/_icons-material-design.scss} +2 -0
  71. package/src/sass/components/_index.scss +35 -0
  72. package/src/{scss/components/_material-box.scss → sass/components/_lightbox.scss} +6 -4
  73. package/src/sass/components/_modal.scss +208 -0
  74. package/src/sass/components/_navbar.scss +345 -0
  75. package/src/{scss/layout/_footer.scss → sass/components/_page-footer.scss} +7 -6
  76. package/src/{scss → sass}/components/_pagination.scss +4 -3
  77. package/src/{scss → sass}/components/_parallax.scss +4 -1
  78. package/src/{scss → sass}/components/_preloader.scss +19 -97
  79. package/src/{scss → sass}/components/_pulse.scss +2 -0
  80. package/src/sass/components/_pushpin.scss +11 -0
  81. package/src/{scss → sass}/components/_sidenav.scss +99 -82
  82. package/src/{scss → sass}/components/_slider.scss +3 -1
  83. package/src/{scss/components/_table-of-contents.scss → sass/components/_table_of_contents.scss} +2 -0
  84. package/src/sass/components/_tabs.scss +232 -0
  85. package/src/{scss/components/_tap-target.scss → sass/components/_tapTarget.scss} +24 -22
  86. package/src/{scss/components/_time-picker.scss → sass/components/_timepicker.scss} +56 -56
  87. package/src/sass/components/_toast.scss +260 -0
  88. package/src/sass/components/_toolbar.scss +192 -0
  89. package/src/sass/components/_tooltip.scss +166 -0
  90. package/src/{scss → sass}/components/_transitions.scss +4 -4
  91. package/src/sass/components/forms/_checkboxes.scss +288 -0
  92. package/src/sass/components/forms/_fieldset.scss +128 -0
  93. package/src/{scss → sass/components}/forms/_file-input.scss +11 -9
  94. package/src/{scss → sass/components}/forms/_index.scss +2 -0
  95. package/src/sass/components/forms/_input-fields.scss +326 -0
  96. package/src/sass/components/forms/_radio-buttons.scss +190 -0
  97. package/src/sass/components/forms/_range.scss +310 -0
  98. package/src/sass/components/forms/_select.scss +103 -0
  99. package/src/sass/components/forms/_switches.scss +239 -0
  100. package/src/sass/expressive.scss +60 -0
  101. package/src/sass/tokens/_index.scss +4 -0
  102. package/src/sass/tokens/_reference.scss +265 -0
  103. package/src/sass/tokens/_theme.scss +49 -0
  104. package/src/sass/utilities/_helpers.scss +63 -0
  105. package/src/sass/utilities/_index.scss +8 -0
  106. package/src/{scss → sass}/utilities/_spacing.scss +4 -3
  107. package/src/sass/utilities/_typescale.scss +45 -0
  108. package/src/sass/utilities/_visibility.scss +63 -0
  109. package/src/sass/utilities/_z-depth.scss +18 -0
  110. package/dist/js/components/index.d.ts +0 -21
  111. package/dist/js/forms/index.d.ts +0 -4
  112. package/dist/js/foundation/index.d.ts +0 -2
  113. package/dist/js/index.d.ts +0 -52
  114. package/dist/js/plugins/index.d.ts +0 -1
  115. package/src/scss/components/_appbar.scss +0 -454
  116. package/src/scss/components/_badges.scss +0 -77
  117. package/src/scss/components/_buttons.scss +0 -412
  118. package/src/scss/components/_cards.scss +0 -267
  119. package/src/scss/components/_chips.scss +0 -147
  120. package/src/scss/components/_collapsible.scss +0 -84
  121. package/src/scss/components/_dropdown.scss +0 -98
  122. package/src/scss/components/_index.scss +0 -28
  123. package/src/scss/components/_modal.scss +0 -84
  124. package/src/scss/components/_tabs.scss +0 -176
  125. package/src/scss/components/_toast.scss +0 -70
  126. package/src/scss/components/_tooltip.scss +0 -49
  127. package/src/scss/components/_video.scss +0 -15
  128. package/src/scss/expressive.scss +0 -7
  129. package/src/scss/forms/_checkboxes.scss +0 -199
  130. package/src/scss/forms/_input-fields.scss +0 -360
  131. package/src/scss/forms/_radio-buttons.scss +0 -114
  132. package/src/scss/forms/_range.scss +0 -148
  133. package/src/scss/forms/_select.scss +0 -108
  134. package/src/scss/forms/_switches.scss +0 -127
  135. package/src/scss/foundation/_base.scss +0 -71
  136. package/src/scss/foundation/_color-palette.scss +0 -402
  137. package/src/scss/foundation/_index.scss +0 -10
  138. package/src/scss/foundation/_mixins.scss +0 -198
  139. package/src/scss/foundation/_motion.scss +0 -70
  140. package/src/scss/foundation/_shape.scss +0 -30
  141. package/src/scss/foundation/_state-layers.scss +0 -68
  142. package/src/scss/foundation/_theme.scss +0 -238
  143. package/src/scss/foundation/_tokens.scss +0 -511
  144. package/src/scss/foundation/_variables.scss +0 -57
  145. package/src/scss/layout/_index.scss +0 -3
  146. package/src/scss/utilities/_a11y.scss +0 -77
  147. package/src/scss/utilities/_elevation.scss +0 -63
  148. package/src/scss/utilities/_helpers.scss +0 -50
  149. package/src/scss/utilities/_index.scss +0 -7
  150. package/src/scss/utilities/_responsive.scss +0 -62
  151. package/src/scss/utilities/_typography.scss +0 -115
  152. /package/dist/{js/forms → types/behaviors}/forms.d.ts +0 -0
  153. /package/dist/{js/components → types/behaviors}/waves.d.ts +0 -0
  154. /package/src/{scss → sass}/utilities/_colors.scss +0 -0
@@ -1,12 +1,11 @@
1
- @use '../foundation/variables' as *;
2
- @use '../utilities/colors' as *;
1
+ @use "../abstracts" as *;
3
2
 
4
3
  .progress {
5
4
  position: relative;
6
5
  height: 4px;
7
6
  display: block;
8
7
  width: 100%;
9
- @extend .surface-variant;
8
+ background-color: var(--md-sys-color-surface-variant);
10
9
  border-radius: 4px;
11
10
  margin: $element-top-margin 0 $element-bottom-margin 0;
12
11
  overflow: hidden;
@@ -131,15 +130,10 @@
131
130
 
132
131
  &.active {
133
132
  /* duration: 360 * ARCTIME / (ARCSTARTROT + (360-ARCSIZE)) */
134
- -webkit-animation: container-rotate 1568ms linear infinite;
135
133
  animation: container-rotate 1568ms linear infinite;
136
134
  }
137
135
  }
138
136
 
139
- @-webkit-keyframes container-rotate {
140
- to { -webkit-transform: rotate(360deg) }
141
- }
142
-
143
137
  @keyframes container-rotate {
144
138
  to { transform: rotate(360deg) }
145
139
  }
@@ -173,39 +167,37 @@
173
167
  }
174
168
 
175
169
  /**
176
- * IMPORTANT NOTE ABOUT CSS ANIMATION PROPERTIES (keanulee):
170
+ * NOTE ABOUT CSS ANIMATION PROPERTIES (keanulee):
177
171
  *
178
172
  * iOS Safari (tested on iOS 8.1) does not handle animation-delay very well - it doesn't
179
173
  * guarantee that the animation will start _exactly_ after that value. So we avoid using
180
174
  * animation-delay and instead set custom keyframes for each color (as redundant as it
181
175
  * seems).
182
176
  *
183
- * We write out each animation in full (instead of separating animation-name,
184
- * animation-duration, etc.) because under the polyfill, Safari does not recognize those
185
- * specific properties properly, treats them as -webkit-animation, and overrides the
186
- * other animation rules. See https://github.com/Polymer/platform/issues/53.
177
+ * The second half of this note explained why each animation is written as the
178
+ * `animation` shorthand rather than as separate animation-name/-duration
179
+ * longhands: the Web Animations polyfill on old Safari mistook the longhands
180
+ * for -webkit-animation. That polyfill is long gone, and the prefixed
181
+ * declarations it was about have been removed - the shorthand is kept only
182
+ * because it is shorter here. See github.com/Polymer/platform/issues/53.
187
183
  */
188
184
  .active .spinner-layer.spinner-blue {
189
185
  /* durations: 4 * ARCTIME */
190
- -webkit-animation: fill-unfill-rotate 5332ms cubic-bezier(0.4, 0.0, 0.2, 1) infinite both, blue-fade-in-out 5332ms cubic-bezier(0.4, 0.0, 0.2, 1) infinite both;
191
186
  animation: fill-unfill-rotate 5332ms cubic-bezier(0.4, 0.0, 0.2, 1) infinite both, blue-fade-in-out 5332ms cubic-bezier(0.4, 0.0, 0.2, 1) infinite both;
192
187
  }
193
188
 
194
189
  .active .spinner-layer.spinner-red {
195
190
  /* durations: 4 * ARCTIME */
196
- -webkit-animation: fill-unfill-rotate 5332ms cubic-bezier(0.4, 0.0, 0.2, 1) infinite both, red-fade-in-out 5332ms cubic-bezier(0.4, 0.0, 0.2, 1) infinite both;
197
191
  animation: fill-unfill-rotate 5332ms cubic-bezier(0.4, 0.0, 0.2, 1) infinite both, red-fade-in-out 5332ms cubic-bezier(0.4, 0.0, 0.2, 1) infinite both;
198
192
  }
199
193
 
200
194
  .active .spinner-layer.spinner-yellow {
201
195
  /* durations: 4 * ARCTIME */
202
- -webkit-animation: fill-unfill-rotate 5332ms cubic-bezier(0.4, 0.0, 0.2, 1) infinite both, yellow-fade-in-out 5332ms cubic-bezier(0.4, 0.0, 0.2, 1) infinite both;
203
196
  animation: fill-unfill-rotate 5332ms cubic-bezier(0.4, 0.0, 0.2, 1) infinite both, yellow-fade-in-out 5332ms cubic-bezier(0.4, 0.0, 0.2, 1) infinite both;
204
197
  }
205
198
 
206
199
  .active .spinner-layer.spinner-green {
207
200
  /* durations: 4 * ARCTIME */
208
- -webkit-animation: fill-unfill-rotate 5332ms cubic-bezier(0.4, 0.0, 0.2, 1) infinite both, green-fade-in-out 5332ms cubic-bezier(0.4, 0.0, 0.2, 1) infinite both;
209
201
  animation: fill-unfill-rotate 5332ms cubic-bezier(0.4, 0.0, 0.2, 1) infinite both, green-fade-in-out 5332ms cubic-bezier(0.4, 0.0, 0.2, 1) infinite both;
210
202
  }
211
203
 
@@ -216,21 +208,9 @@
216
208
  .active .spinner-layer.spinner-green-only {
217
209
  /* durations: 4 * ARCTIME */
218
210
  opacity: 1;
219
- -webkit-animation: fill-unfill-rotate 5332ms cubic-bezier(0.4, 0.0, 0.2, 1) infinite both;
220
211
  animation: fill-unfill-rotate 5332ms cubic-bezier(0.4, 0.0, 0.2, 1) infinite both;
221
212
  }
222
213
 
223
- @-webkit-keyframes fill-unfill-rotate {
224
- 12.5% { -webkit-transform: rotate(135deg); } /* 0.5 * ARCSIZE */
225
- 25% { -webkit-transform: rotate(270deg); } /* 1 * ARCSIZE */
226
- 37.5% { -webkit-transform: rotate(405deg); } /* 1.5 * ARCSIZE */
227
- 50% { -webkit-transform: rotate(540deg); } /* 2 * ARCSIZE */
228
- 62.5% { -webkit-transform: rotate(675deg); } /* 2.5 * ARCSIZE */
229
- 75% { -webkit-transform: rotate(810deg); } /* 3 * ARCSIZE */
230
- 87.5% { -webkit-transform: rotate(945deg); } /* 3.5 * ARCSIZE */
231
- to { -webkit-transform: rotate(1080deg); } /* 4 * ARCSIZE */
232
- }
233
-
234
214
  @keyframes fill-unfill-rotate {
235
215
  12.5% { transform: rotate(135deg); } /* 0.5 * ARCSIZE */
236
216
  25% { transform: rotate(270deg); } /* 1 * ARCSIZE */
@@ -242,15 +222,6 @@
242
222
  to { transform: rotate(1080deg); } /* 4 * ARCSIZE */
243
223
  }
244
224
 
245
- @-webkit-keyframes blue-fade-in-out {
246
- from { opacity: 1; }
247
- 25% { opacity: 1; }
248
- 26% { opacity: 0; }
249
- 89% { opacity: 0; }
250
- 90% { opacity: 1; }
251
- 100% { opacity: 1; }
252
- }
253
-
254
225
  @keyframes blue-fade-in-out {
255
226
  from { opacity: 1; }
256
227
  25% { opacity: 1; }
@@ -260,14 +231,6 @@
260
231
  100% { opacity: 1; }
261
232
  }
262
233
 
263
- @-webkit-keyframes red-fade-in-out {
264
- from { opacity: 0; }
265
- 15% { opacity: 0; }
266
- 25% { opacity: 1; }
267
- 50% { opacity: 1; }
268
- 51% { opacity: 0; }
269
- }
270
-
271
234
  @keyframes red-fade-in-out {
272
235
  from { opacity: 0; }
273
236
  15% { opacity: 0; }
@@ -276,14 +239,6 @@
276
239
  51% { opacity: 0; }
277
240
  }
278
241
 
279
- @-webkit-keyframes yellow-fade-in-out {
280
- from { opacity: 0; }
281
- 40% { opacity: 0; }
282
- 50% { opacity: 1; }
283
- 75% { opacity: 1; }
284
- 76% { opacity: 0; }
285
- }
286
-
287
242
  @keyframes yellow-fade-in-out {
288
243
  from { opacity: 0; }
289
244
  40% { opacity: 0; }
@@ -292,14 +247,6 @@
292
247
  76% { opacity: 0; }
293
248
  }
294
249
 
295
- @-webkit-keyframes green-fade-in-out {
296
- from { opacity: 0; }
297
- 65% { opacity: 0; }
298
- 75% { opacity: 1; }
299
- 90% { opacity: 1; }
300
- 100% { opacity: 0; }
301
- }
302
-
303
250
  @keyframes green-fade-in-out {
304
251
  from { opacity: 0; }
305
252
  65% { opacity: 0; }
@@ -320,11 +267,11 @@
320
267
  height: 100%;
321
268
  overflow: hidden;
322
269
  border-color: inherit;
270
+ }
323
271
 
324
- .circle {
325
- width: 1000%;
326
- left: -450%;
327
- }
272
+ .gap-patch .circle {
273
+ width: 1000%;
274
+ left: -450%;
328
275
  }
329
276
 
330
277
  .circle-clipper {
@@ -343,7 +290,6 @@
343
290
  border-color: inherit;
344
291
  border-bottom-color: transparent !important;
345
292
  border-radius: 50%;
346
- -webkit-animation: none;
347
293
  animation: none;
348
294
  position: absolute;
349
295
  top: 0;
@@ -354,37 +300,25 @@
354
300
  &.left .circle {
355
301
  left: 0;
356
302
  border-right-color: transparent !important;
357
- -webkit-transform: rotate(129deg);
358
303
  transform: rotate(129deg);
359
304
  }
360
305
  &.right .circle {
361
306
  left: -100%;
362
307
  border-left-color: transparent !important;
363
- -webkit-transform: rotate(-129deg);
364
308
  transform: rotate(-129deg);
365
309
  }
366
310
  }
367
311
 
368
312
 
369
313
 
370
- .active .circle-clipper {
371
- &.left .circle {
372
- /* duration: ARCTIME */
373
- -webkit-animation: left-spin 1333ms cubic-bezier(0.4, 0.0, 0.2, 1) infinite both;
374
- animation: left-spin 1333ms cubic-bezier(0.4, 0.0, 0.2, 1) infinite both;
375
- }
376
-
377
- &.right .circle {
378
- /* duration: ARCTIME */
379
- -webkit-animation: right-spin 1333ms cubic-bezier(0.4, 0.0, 0.2, 1) infinite both;
380
- animation: right-spin 1333ms cubic-bezier(0.4, 0.0, 0.2, 1) infinite both;
381
- }
314
+ .active .circle-clipper.left .circle {
315
+ /* duration: ARCTIME */
316
+ animation: left-spin 1333ms cubic-bezier(0.4, 0.0, 0.2, 1) infinite both;
382
317
  }
383
318
 
384
- @-webkit-keyframes left-spin {
385
- from { -webkit-transform: rotate(130deg); }
386
- 50% { -webkit-transform: rotate(-5deg); }
387
- to { -webkit-transform: rotate(130deg); }
319
+ .active .circle-clipper.right .circle {
320
+ /* duration: ARCTIME */
321
+ animation: right-spin 1333ms cubic-bezier(0.4, 0.0, 0.2, 1) infinite both;
388
322
  }
389
323
 
390
324
  @keyframes left-spin {
@@ -393,12 +327,6 @@
393
327
  to { transform: rotate(130deg); }
394
328
  }
395
329
 
396
- @-webkit-keyframes right-spin {
397
- from { -webkit-transform: rotate(-130deg); }
398
- 50% { -webkit-transform: rotate(5deg); }
399
- to { -webkit-transform: rotate(-130deg); }
400
- }
401
-
402
330
  @keyframes right-spin {
403
331
  from { transform: rotate(-130deg); }
404
332
  50% { transform: rotate(5deg); }
@@ -407,15 +335,9 @@
407
335
 
408
336
  #spinnerContainer.cooldown {
409
337
  /* duration: SHRINK_TIME */
410
- -webkit-animation: container-rotate 1568ms linear infinite, fade-out 400ms cubic-bezier(0.4, 0.0, 0.2, 1);
411
338
  animation: container-rotate 1568ms linear infinite, fade-out 400ms cubic-bezier(0.4, 0.0, 0.2, 1);
412
339
  }
413
340
 
414
- @-webkit-keyframes fade-out {
415
- from { opacity: 1; }
416
- to { opacity: 0; }
417
- }
418
-
419
341
  @keyframes fade-out {
420
342
  from { opacity: 1; }
421
343
  to { opacity: 0; }
@@ -1,3 +1,5 @@
1
+ @use "../abstracts" as *;
2
+
1
3
  .pulse {
2
4
  overflow: visible;
3
5
  position: relative;
@@ -0,0 +1,11 @@
1
+ @use "../abstracts" as *;
2
+
3
+ // Paired with components/pushpin.ts, which swaps these classes on scroll.
4
+
5
+ .pin-top, .pin-bottom {
6
+ position: relative;
7
+ }
8
+
9
+ .pinned {
10
+ position: fixed !important;
11
+ }
@@ -1,9 +1,6 @@
1
- @use '../foundation/variables' as *;
2
- @use '../utilities/elevation' as *;
1
+ @use "../abstracts" as *;
3
2
 
4
- // M3 Expressive: Navigation Drawer is the M3 alias for Sidenav
5
- .sidenav,
6
- .navigation-drawer {
3
+ .sidenav {
7
4
  --sidenav-width: 300px;
8
5
  --sidenav-font-size: 14px;
9
6
  --sidenav-padding: 16px;
@@ -22,12 +19,12 @@
22
19
  overflow-y: auto;
23
20
  will-change: transform;
24
21
  backface-visibility: hidden;
25
- transform: translateX(-105%);
22
+ transform: translateX(-105%);
26
23
  user-select: none;
27
-
24
+
28
25
  color: var(--md-sys-color-on-secondary-container);
29
- background-color: var(--md-sys-color-surface-container, var(--md-sys-color-surface));
30
- @extend .elevation-1;
26
+ background-color: var(--md-sys-color-surface);
27
+ @include z-depth("1");
31
28
 
32
29
  // Right Align
33
30
  &.right-aligned {
@@ -41,54 +38,70 @@
41
38
  margin: 0;
42
39
  }
43
40
 
41
+ /* Hover only on top row */
42
+ /*a:hover {
43
+ //color: red;
44
+ //background-color: var(--md-sys-color-on-secondary-container);
45
+ //md.sys.color.on-secondary-container
46
+ }*/
44
47
  a:focus {
45
- background-color: color-mix(in srgb, var(--md-sys-color-on-surface) 12%, transparent);
48
+ background-color: rgba(0, 0, 0, 0.12);
46
49
  }
47
50
 
48
51
  li.active > a:not(.collapsible-header):not(.btn):not(.btn-large):not(.btn-small):not(.btn-flat):not(.btn-large):not(.btn-floating) {
49
- background-color: color-mix(in srgb, var(--md-sys-color-secondary) 10%, transparent);
52
+ //color: var(--md-sys-color-on-secondary-container); //var(--md-sys-color-on-secondary-container);
53
+ //background-color: var(--md-sys-color-secondary-container);
54
+ background-color: color-mix(in oklab, var(--md-sys-color-secondary) 10%, transparent);
50
55
  }
51
56
 
52
- .collapsible-body {
53
- padding: 0;
54
-
55
- & > ul { padding-left: 10px; }
56
- }
57
+ .collapsible-body > ul { padding-left: 10px; }
57
58
 
58
- li {
59
+ li {
59
60
  list-style: none;
60
61
  display: grid;
61
62
  align-content: center;
63
+ }
64
+ li > a {
65
+ /* https://stackoverflow.com/questions/5848090/full-width-hover-background-for-nested-lists */
66
+ //padding-left: calc(100% + var(--sidenav-padding));
67
+ //margin-left: -100%;
68
+ margin: 0 12px;
69
+ padding: 0 var(--sidenav-padding);
70
+ //padding-left: var(--sidenav-padding);
71
+ // Truncate too long text
72
+ /*
73
+ min-width: 0;
74
+ white-space: nowrap;
75
+ overflow: hidden;
76
+ text-overflow: ellipsis;
77
+ */
78
+ display: flex;
79
+ height: var(--sidenav-item-height);
80
+ font-size: var(--sidenav-font-size);
81
+ font-weight: 500;
82
+ align-items: center;
83
+ overflow: hidden;
84
+ border-radius: 100px;
62
85
 
63
- & > a {
64
- margin: 0 12px;
65
- padding: 0 var(--sidenav-padding);
66
- display: flex;
67
- height: var(--sidenav-item-height);
68
- font-size: var(--sidenav-font-size);
69
- font-weight: 500;
70
- align-items: center;
71
- overflow: hidden;
72
- border-radius: var(--md-sys-shape-corner-full, 100px);
73
-
74
- &:not(.btn):not(.btn-flat):not(.btn-large):not(.btn-floating) {
75
- color: var(--md-sys-color-on-secondary-container);
76
- &:hover {
77
- background-color: color-mix(in srgb, var(--md-sys-color-on-surface) 8%, transparent);
78
- }
86
+ &:not(.btn):not(.button):not(.btn-flat):not(.btn-large):not(.btn-floating) {
87
+ color: var(--md-sys-color-on-secondary-container);
88
+ &:hover {
89
+ //color: var(--md-sys-color-on-secondary-container);
90
+ //md.sys.color.on-secondary-container
91
+ background-color: color-mix(in oklab, var(--md-sys-color-on-surface) 8%, transparent);
79
92
  }
93
+ }
80
94
 
81
- &.btn, &.btn-large, &.btn-flat, &.btn-floating {
82
- margin: 10px 15px;
83
- }
95
+ &.btn, &.button, &.btn-large, &.btn-flat, &.btn-floating {
96
+ margin: 10px 15px;
97
+ }
84
98
 
85
- /* TODO: Use special class in future like "mw-icon" */
86
- & > .material-icons, & > .material-symbols-outlined,
87
- & > .material-symbols-rounded, & > .material-symbols-sharp {
88
- display: inline-flex;
89
- vertical-align: middle;
90
- margin-right: 12px;
91
- }
99
+ /* TODO: Use special class in future like "mw-icon" */
100
+ & > .material-icons, & > .material-symbols-outlined,
101
+ & > .material-symbols-rounded, & > .material-symbols-sharp {
102
+ display: inline-flex;
103
+ vertical-align: middle;
104
+ margin-right: 12px;
92
105
  }
93
106
  }
94
107
 
@@ -155,38 +168,37 @@
155
168
  font-weight: 400;
156
169
  }
157
170
  }
171
+ }
158
172
 
159
- // Fixed Sidenav shown
160
- &.sidenav-fixed,
161
- &.navigation-drawer-fixed {
162
- left: 0;
163
- transform: translateX(0);
164
- position: fixed;
173
+ // Touch interaction
174
+ .drag-target {
175
+ height: 100%;
176
+ position: fixed;
177
+ top: 0;
178
+ left: 0;
179
+ z-index: 998;
165
180
 
166
- &.right-aligned {
167
- right: 0;
168
- left: auto;
169
- }
181
+ &.right-aligned {
182
+ right: 0;
170
183
  }
184
+ }
171
185
 
172
- // Sidenav collapsible styling (Taken from Collapsible.scss)
173
- &, &.sidenav-fixed, &.navigation-drawer-fixed {
174
- .collapsible {
175
- border: none;
176
- box-shadow: none;
177
- }
178
- .collapsible-header {
179
- border: none;
180
- }
181
- .collapsible-body {
182
- border: none;
183
- }
186
+ // Fixed Sidenav shown
187
+ .sidenav.sidenav-fixed {
188
+ left: 0;
189
+ transform: translateX(0);
190
+ position: fixed;
191
+
192
+ &.right-aligned {
193
+ right: 0;
194
+ left: auto;
184
195
  }
196
+ }
185
197
 
186
- // Fixed Sidenav hide on smaller
187
- @media #{$medium-and-down} {
188
- &.sidenav-fixed,
189
- &.navigation-drawer-fixed {
198
+ // Fixed Sidenav hide on smaller
199
+ @include bp-down("large") {
200
+ .sidenav {
201
+ &.sidenav-fixed {
190
202
  transform: translateX(-105%);
191
203
 
192
204
  &.right-aligned {
@@ -202,21 +214,11 @@
202
214
  }
203
215
  }
204
216
 
205
- // Touch interaction
206
- .drag-target {
207
- height: 100%;
208
- position: fixed;
209
- top: 0;
210
- left: 0;
211
- z-index: 998;
212
-
213
- &.right-aligned {
214
- right: 0;
215
- }
217
+ .sidenav .collapsible-body {
218
+ padding: 0;
216
219
  }
217
220
 
218
- .sidenav-overlay,
219
- .navigation-drawer-overlay {
221
+ .sidenav-overlay {
220
222
  position: fixed;
221
223
  top: 0;
222
224
  left: 0;
@@ -227,3 +229,18 @@
227
229
  z-index: 997;
228
230
  display: none;
229
231
  }
232
+
233
+ // Sidenav collapsible styling (Taken from Collapsible.scss)
234
+ .sidenav,
235
+ .sidenav.sidenav-fixed {
236
+ .collapsible {
237
+ border: none;
238
+ box-shadow: none;
239
+ }
240
+ .collapsible-header {
241
+ border: none;
242
+ }
243
+ .collapsible-body {
244
+ border: none;
245
+ }
246
+ }
@@ -1,3 +1,5 @@
1
+ @use "../abstracts" as *;
2
+
1
3
  .slider {
2
4
  position: relative;
3
5
  height: 400px;
@@ -106,7 +108,7 @@
106
108
  width: 100%;
107
109
  height: 100%;
108
110
  cursor: pointer;
109
- background-color: var(--md-sys-color-shadow-light);
111
+ background-color: var(--md-sys-color-shadow);
110
112
  transition: background-color .3s;
111
113
  border-radius: 50%;
112
114
  border-width: 0;
@@ -1,3 +1,5 @@
1
+ @use "../abstracts" as *;
2
+
1
3
  .table-of-contents {
2
4
  list-style: none;
3
5