@materializecss/materialize 1.2.2 → 2.0.1-alpha

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 (90) hide show
  1. package/Gruntfile.js +68 -313
  2. package/README.md +26 -14
  3. package/dist/css/materialize.css +1009 -1822
  4. package/dist/css/materialize.min.css +2 -8
  5. package/dist/js/materialize.js +8414 -12299
  6. package/dist/js/materialize.min.js +8968 -2
  7. package/dist/js/materialize.min.js.map +1 -0
  8. package/package.json +13 -9
  9. package/sass/components/_badges.scss +12 -2
  10. package/sass/components/_buttons.scss +16 -11
  11. package/sass/components/_cards.scss +14 -9
  12. package/sass/components/_carousel.scss +5 -2
  13. package/sass/components/_chips.scss +3 -3
  14. package/sass/components/_collapsible.scss +22 -8
  15. package/sass/components/_collection.scss +14 -6
  16. package/sass/components/_datepicker.scss +30 -11
  17. package/sass/components/_dropdown.scss +6 -4
  18. package/sass/components/_global.scss +132 -111
  19. package/sass/components/_grid.scss +119 -98
  20. package/sass/components/_modal.scss +3 -3
  21. package/sass/components/_navbar.scss +31 -17
  22. package/sass/components/_normalize.scss +26 -124
  23. package/sass/components/_sidenav.scss +21 -20
  24. package/sass/components/_slider.scss +27 -7
  25. package/sass/components/_table_of_contents.scss +12 -12
  26. package/sass/components/_tabs.scss +47 -16
  27. package/sass/components/_tapTarget.scss +6 -6
  28. package/sass/components/_theme_variables.scss +98 -0
  29. package/sass/components/_timepicker.scss +54 -46
  30. package/sass/components/_toast.scss +3 -3
  31. package/sass/components/_tooltip.scss +4 -5
  32. package/sass/components/_typography.scss +1 -1
  33. package/sass/components/_variables.scss +185 -120
  34. package/sass/components/forms/_checkboxes.scss +9 -9
  35. package/sass/components/forms/_file-input.scss +9 -7
  36. package/sass/components/forms/_input-fields.scss +173 -234
  37. package/sass/components/forms/_radio-buttons.scss +1 -1
  38. package/sass/components/forms/_range.scss +11 -11
  39. package/sass/components/forms/_select.scss +29 -19
  40. package/sass/components/forms/_switches.scss +22 -18
  41. package/sass/materialize.scss +1 -1
  42. package/src/autocomplete.ts +459 -0
  43. package/src/bounding.ts +6 -0
  44. package/{js/buttons.js → src/buttons.ts} +103 -162
  45. package/src/cards.ts +54 -0
  46. package/{js/carousel.js → src/carousel.ts} +137 -262
  47. package/src/characterCounter.ts +88 -0
  48. package/src/chips.ts +350 -0
  49. package/src/collapsible.ts +184 -0
  50. package/{js/component.js → src/component.ts} +6 -19
  51. package/{js/datepicker.js → src/datepicker.ts} +213 -299
  52. package/{js/dropdown.js → src/dropdown.ts} +140 -254
  53. package/src/edges.ts +6 -0
  54. package/src/forms.ts +120 -0
  55. package/src/global.ts +385 -0
  56. package/src/materialbox.ts +348 -0
  57. package/src/modal.ts +256 -0
  58. package/{js/parallax.js → src/parallax.ts} +47 -60
  59. package/{js/pushpin.js → src/pushpin.ts} +19 -47
  60. package/{js/range.js → src/range.ts} +58 -139
  61. package/{js/scrollspy.js → src/scrollspy.ts} +81 -153
  62. package/src/select.ts +448 -0
  63. package/{js/sidenav.js → src/sidenav.ts} +96 -202
  64. package/src/slider.ts +415 -0
  65. package/src/tabs.ts +293 -0
  66. package/src/tapTarget.ts +240 -0
  67. package/{js/timepicker.js → src/timepicker.ts} +268 -272
  68. package/{js/toasts.js → src/toasts.ts} +75 -134
  69. package/{js/tooltip.js → src/tooltip.ts} +59 -96
  70. package/src/waves.ts +70 -0
  71. package/extras/noUiSlider/nouislider.css +0 -404
  72. package/extras/noUiSlider/nouislider.js +0 -2147
  73. package/extras/noUiSlider/nouislider.min.js +0 -1
  74. package/js/anime.min.js +0 -34
  75. package/js/autocomplete.js +0 -479
  76. package/js/cards.js +0 -40
  77. package/js/cash.js +0 -960
  78. package/js/characterCounter.js +0 -136
  79. package/js/chips.js +0 -486
  80. package/js/collapsible.js +0 -275
  81. package/js/forms.js +0 -285
  82. package/js/global.js +0 -428
  83. package/js/materialbox.js +0 -453
  84. package/js/modal.js +0 -382
  85. package/js/select.js +0 -391
  86. package/js/slider.js +0 -497
  87. package/js/tabs.js +0 -402
  88. package/js/tapTarget.js +0 -315
  89. package/js/waves.js +0 -615
  90. package/sass/components/_waves.scss +0 -187
@@ -1,10 +1,9 @@
1
- //Default styles
2
-
3
1
  html {
4
- box-sizing: border-box;
2
+ box-sizing: border-box;
5
3
  }
4
+
6
5
  *, *:before, *:after {
7
- box-sizing: inherit;
6
+ box-sizing: inherit;
8
7
  }
9
8
 
10
9
  button,
@@ -15,39 +14,24 @@ textarea {
15
14
  font-family: $font-stack;
16
15
  }
17
16
 
18
- ul {
19
- &:not(.browser-default) {
20
- padding-left: 0;
21
- list-style-type: none;
22
-
23
- & > li {
24
- list-style-type: none;
25
- }
26
- }
27
- }
28
-
29
17
  a {
30
- color: $link-color;
31
- text-decoration: none;
32
-
18
+ color: $link-color;
19
+ text-decoration: none;
33
20
  // Gets rid of tap active state
34
21
  -webkit-tap-highlight-color: transparent;
35
22
  }
36
23
 
37
-
38
24
  // Positioning
39
25
  .valign-wrapper {
40
26
  display: flex;
41
27
  align-items: center;
42
28
  }
43
29
 
44
-
45
30
  // classic clearfix
46
31
  .clearfix {
47
32
  clear: both;
48
33
  }
49
34
 
50
-
51
35
  // Z-levels
52
36
  .z-depth-0 {
53
37
  box-shadow: none !important;
@@ -55,40 +39,41 @@ a {
55
39
 
56
40
  /* 2dp elevation modified*/
57
41
  .z-depth-1 {
58
- box-shadow: 0 2px 2px 0 rgba(0,0,0,0.14),
59
- 0 3px 1px -2px rgba(0,0,0,0.12),
60
- 0 1px 5px 0 rgba(0,0,0,0.2);
42
+ box-shadow: 0 2px 2px 0 rgba(0, 0, 0, 0.14),
43
+ 0 3px 1px -2px rgba(0, 0, 0, 0.12),
44
+ 0 1px 5px 0 rgba(0, 0, 0, 0.2);
61
45
  }
46
+
62
47
  .z-depth-1-half {
63
48
  box-shadow: 0 3px 3px 0 rgba(0, 0, 0, 0.14), 0 1px 7px 0 rgba(0, 0, 0, 0.12), 0 3px 1px -1px rgba(0, 0, 0, 0.2);
64
49
  }
65
50
 
66
51
  /* 6dp elevation modified*/
67
52
  .z-depth-2 {
68
- box-shadow: 0 4px 5px 0 rgba(0,0,0,0.14),
69
- 0 1px 10px 0 rgba(0,0,0,0.12),
70
- 0 2px 4px -1px rgba(0,0,0,0.3);
53
+ box-shadow: 0 4px 5px 0 rgba(0, 0, 0, 0.14),
54
+ 0 1px 10px 0 rgba(0, 0, 0, 0.12),
55
+ 0 2px 4px -1px rgba(0, 0, 0, 0.3);
71
56
  }
72
57
 
73
58
  /* 12dp elevation modified*/
74
59
  .z-depth-3 {
75
- box-shadow: 0 8px 17px 2px rgba(0,0,0,0.14),
76
- 0 3px 14px 2px rgba(0,0,0,0.12),
77
- 0 5px 5px -3px rgba(0, 0, 0, 0.2);
60
+ box-shadow: 0 8px 17px 2px rgba(0, 0, 0, 0.14),
61
+ 0 3px 14px 2px rgba(0, 0, 0, 0.12),
62
+ 0 5px 5px -3px rgba(0, 0, 0, 0.2);
78
63
  }
79
64
 
80
65
  /* 16dp elevation */
81
66
  .z-depth-4 {
82
- box-shadow: 0 16px 24px 2px rgba(0,0,0,0.14),
83
- 0 6px 30px 5px rgba(0,0,0,0.12),
84
- 0 8px 10px -7px rgba(0,0,0,0.2);
67
+ box-shadow: 0 16px 24px 2px rgba(0, 0, 0, 0.14),
68
+ 0 6px 30px 5px rgba(0, 0, 0, 0.12),
69
+ 0 8px 10px -7px rgba(0, 0, 0, 0.2);
85
70
  }
86
71
 
87
72
  /* 24dp elevation */
88
73
  .z-depth-5 {
89
- box-shadow: 0 24px 38px 3px rgba(0,0,0,0.14),
90
- 0 9px 46px 8px rgba(0,0,0,0.12),
91
- 0 11px 15px -7px rgba(0,0,0,0.2);
74
+ box-shadow: 0 24px 38px 3px rgba(0, 0, 0, 0.14),
75
+ 0 9px 46px 8px rgba(0, 0, 0, 0.12),
76
+ 0 11px 15px -7px rgba(0, 0, 0, 0.2);
92
77
  }
93
78
 
94
79
  .hoverable {
@@ -100,16 +85,14 @@ a {
100
85
  }
101
86
 
102
87
  // Dividers
103
-
104
88
  .divider {
105
89
  height: 1px;
106
90
  overflow: hidden;
107
- background-color: color("grey", "lighten-2");
91
+ background-color: $divider-color;
108
92
  }
109
93
 
110
94
 
111
95
  // Blockquote
112
-
113
96
  blockquote {
114
97
  margin: 20px 0;
115
98
  padding-left: 1.5rem;
@@ -117,7 +100,6 @@ blockquote {
117
100
  }
118
101
 
119
102
  // Icon Styles
120
-
121
103
  i {
122
104
  line-height: inherit;
123
105
 
@@ -125,19 +107,24 @@ i {
125
107
  float: left;
126
108
  margin-right: 15px;
127
109
  }
110
+
128
111
  &.right {
129
112
  float: right;
130
113
  margin-left: 15px;
131
114
  }
115
+
132
116
  &.tiny {
133
117
  font-size: 1rem;
134
118
  }
119
+
135
120
  &.small {
136
121
  font-size: 2rem;
137
122
  }
123
+
138
124
  &.medium {
139
125
  font-size: 4rem;
140
126
  }
127
+
141
128
  &.large {
142
129
  font-size: 6rem;
143
130
  }
@@ -150,9 +137,7 @@ video.responsive-video {
150
137
  height: auto;
151
138
  }
152
139
 
153
-
154
140
  // Pagination
155
-
156
141
  .pagination {
157
142
 
158
143
  li {
@@ -163,20 +148,29 @@ video.responsive-video {
163
148
  height: 30px;
164
149
 
165
150
  a {
166
- color: #444;
151
+ color: $font-color-medium;
167
152
  display: inline-block;
168
153
  font-size: 1.2rem;
169
154
  padding: 0 10px;
170
155
  line-height: 30px;
171
156
  }
172
157
 
173
- &.active a { color: #fff; }
158
+ &:hover:not(.disabled) {
159
+ background-color: $primary-color-hover-opaque;
160
+ }
161
+
162
+ &.active a {
163
+ color: $font-on-primary-color-main;
164
+ }
174
165
 
175
- &.active { background-color: $primary-color; }
166
+ &.active,
167
+ &.active:hover {
168
+ background-color: $primary-color;
169
+ }
176
170
 
177
171
  &.disabled a {
178
172
  cursor: default;
179
- color: #999;
173
+ color: $font-color-disabled;
180
174
  }
181
175
 
182
176
  i {
@@ -190,6 +184,7 @@ video.responsive-video {
190
184
  float: none;
191
185
  }
192
186
  }
187
+
193
188
  @media #{$medium-and-down} {
194
189
  .pagination {
195
190
  width: 100%;
@@ -211,19 +206,19 @@ video.responsive-video {
211
206
  .breadcrumb {
212
207
  display: inline-block;
213
208
  font-size: 18px;
214
- color: rgba(255,255,255, .7);
209
+ color: $font-on-primary-color-medium;
215
210
 
216
211
  i,
217
212
  [class^="mdi-"], [class*="mdi-"],
218
213
  i.material-icons {
219
- display: inline-block;
214
+ display: block;
220
215
  float: left;
221
216
  font-size: 24px;
222
217
  }
223
218
 
224
219
  &:before {
225
220
  content: '\E5CC';
226
- color: rgba(255,255,255, .7);
221
+ color: $font-on-primary-color-medium;
227
222
  vertical-align: top;
228
223
  display: inline-block;
229
224
  font-family: 'Material Icons';
@@ -240,7 +235,7 @@ video.responsive-video {
240
235
  }
241
236
 
242
237
  &:last-child {
243
- color: #fff;
238
+ color: $font-on-primary-color-main;
244
239
  }
245
240
  }
246
241
 
@@ -265,7 +260,7 @@ video.responsive-video {
265
260
  bottom: 0;
266
261
  min-width: 100%;
267
262
  min-height: 100%;
268
- transform: translate3d(0,0,0);
263
+ transform: translate3d(0, 0, 0);
269
264
  transform: translateX(-50%);
270
265
  }
271
266
  }
@@ -275,6 +270,7 @@ video.responsive-video {
275
270
  .pin-top, .pin-bottom {
276
271
  position: relative;
277
272
  }
273
+
278
274
  .pinned {
279
275
  position: fixed !important;
280
276
  }
@@ -301,56 +297,67 @@ ul.staggered-list li {
301
297
  display: none !important;
302
298
  }
303
299
  }
300
+
304
301
  .hide-on-med-and-down {
305
302
  @media #{$medium-and-down} {
306
303
  display: none !important;
307
304
  }
308
305
  }
306
+
309
307
  .hide-on-med-and-up {
310
308
  @media #{$medium-and-up} {
311
309
  display: none !important;
312
310
  }
313
311
  }
312
+
314
313
  .hide-on-med-only {
315
314
  @media only screen and (min-width: $small-screen-up) and (max-width: $medium-screen) {
316
315
  display: none !important;
317
316
  }
318
317
  }
318
+
319
319
  .hide-on-large-only {
320
320
  @media #{$large-and-up} {
321
321
  display: none !important;
322
322
  }
323
323
  }
324
+
324
325
  .hide-on-extra-large-only {
325
326
  @media #{$extra-large-and-up} {
326
327
  display: none !important;
327
328
  }
328
329
  }
330
+
329
331
  .show-on-extra-large {
330
332
  @media #{$extra-large-and-up} {
331
333
  display: block !important;
332
334
  }
333
335
  }
336
+
334
337
  .show-on-large {
335
338
  @media #{$large-and-up} {
336
339
  display: block !important;
337
340
  }
338
341
  }
342
+
339
343
  .show-on-medium {
340
344
  @media only screen and (min-width: $small-screen-up) and (max-width: $medium-screen) {
341
345
  display: block !important;
342
346
  }
343
347
  }
348
+
344
349
  .show-on-small {
345
350
  @media #{$small-and-down} {
346
351
  display: block !important;
347
352
  }
348
353
  }
354
+
349
355
  .show-on-medium-and-up {
350
356
  @media #{$medium-and-up} {
351
357
  display: block !important;
352
358
  }
353
359
  }
360
+
354
361
  .show-on-medium-and-down {
355
362
  @media #{$medium-and-down} {
356
363
  display: block !important;
@@ -371,7 +378,12 @@ ul.staggered-list li {
371
378
  color: $footer-font-color;
372
379
  background-color: $footer-bg-color;
373
380
 
374
- .footer-copyright {
381
+ a {
382
+ color: $footer-font-color;
383
+ }
384
+
385
+ .footer-copyright,
386
+ .footer-copyright a {
375
387
  overflow: hidden;
376
388
  min-height: 50px;
377
389
  display: flex;
@@ -385,11 +397,11 @@ ul.staggered-list li {
385
397
 
386
398
  // Tables
387
399
  table, th, td {
388
- border: none;
400
+ border: none;
389
401
  }
390
402
 
391
403
  table {
392
- width:100%;
404
+ width: 100%;
393
405
  display: table;
394
406
  border-collapse: collapse;
395
407
  border-spacing: 0;
@@ -398,19 +410,23 @@ table {
398
410
  tr {
399
411
  border-bottom: none;
400
412
  }
401
-
402
- > tbody > tr:nth-child(odd) {
413
+ tbody > tr:nth-child(odd) {
403
414
  background-color: $table-striped-color;
404
415
  }
405
416
  }
406
417
 
407
418
  &.highlight > tbody > tr {
408
419
  transition: background-color .25s ease;
420
+
409
421
  &:hover {
410
- background-color: $table-striped-color;
422
+ background-color: $surface-hover-color-opaque;
411
423
  }
412
424
  }
413
425
 
426
+ thead {
427
+ color: $font-color-medium;
428
+ }
429
+
414
430
  &.centered {
415
431
  thead tr th, tbody tr td {
416
432
  text-align: center;
@@ -422,7 +438,7 @@ tr {
422
438
  border-bottom: 1px solid $table-border-color;
423
439
  }
424
440
 
425
- td, th{
441
+ td, th {
426
442
  padding: 15px 5px;
427
443
  display: table-cell;
428
444
  text-align: left;
@@ -450,7 +466,10 @@ td, th{
450
466
  vertical-align: top;
451
467
  }
452
468
 
453
- th { text-align: left; }
469
+ th {
470
+ text-align: left;
471
+ }
472
+
454
473
  thead {
455
474
  display: block;
456
475
  float: left;
@@ -464,6 +483,7 @@ td, th{
464
483
  }
465
484
  }
466
485
  }
486
+
467
487
  tbody {
468
488
  display: block;
469
489
  width: auto;
@@ -476,15 +496,18 @@ td, th{
476
496
  vertical-align: top;
477
497
  }
478
498
  }
499
+
479
500
  th {
480
501
  display: block;
481
502
  text-align: right;
482
503
  }
504
+
483
505
  td {
484
506
  display: block;
485
507
  min-height: 1.25em;
486
508
  text-align: left;
487
509
  }
510
+
488
511
  tr {
489
512
  border-bottom: none;
490
513
  padding: 0 10px;
@@ -502,30 +525,31 @@ td, th{
502
525
 
503
526
  // Responsive Videos
504
527
  .video-container {
505
- position: relative;
506
- padding-bottom: 56.25%;
507
- height: 0;
508
- overflow: hidden;
528
+ position: relative;
529
+ padding-bottom: 56.25%;
530
+ height: 0;
531
+ overflow: hidden;
509
532
 
510
- iframe, object, embed {
511
- position: absolute;
512
- top: 0;
513
- left: 0;
514
- width: 100%;
515
- height: 100%;
516
- }
533
+ iframe, object, embed {
534
+ position: absolute;
535
+ top: 0;
536
+ left: 0;
537
+ width: 100%;
538
+ height: 100%;
539
+ }
517
540
  }
518
541
 
519
542
  // Progress Bar
520
543
  .progress {
521
- position: relative;
522
- height: 4px;
523
- display: block;
524
- width: 100%;
525
- background-color: lighten($progress-bar-color, 40%);
526
- border-radius: 2px;
527
- margin: $element-top-margin 0 $element-bottom-margin 0;
528
- overflow: hidden;
544
+ position: relative;
545
+ height: 4px;
546
+ display: block;
547
+ width: 100%;
548
+ background-color: $progress-bar-track-color;
549
+ border-radius: 2px;
550
+ margin: $element-top-margin 0 $element-bottom-margin 0;
551
+ overflow: hidden;
552
+
529
553
  .determinate {
530
554
  position: absolute;
531
555
  top: 0;
@@ -534,26 +558,29 @@ td, th{
534
558
  background-color: $progress-bar-color;
535
559
  transition: width .3s linear;
536
560
  }
561
+
537
562
  .indeterminate {
538
563
  background-color: $progress-bar-color;
564
+
539
565
  &:before {
540
566
  content: '';
541
567
  position: absolute;
542
568
  background-color: inherit;
543
569
  top: 0;
544
- left:0;
570
+ left: 0;
545
571
  bottom: 0;
546
572
  will-change: left, right;
547
573
  // Custom bezier
548
574
  animation: indeterminate 2.1s cubic-bezier(0.650, 0.815, 0.735, 0.395) infinite;
549
575
 
550
576
  }
577
+
551
578
  &:after {
552
579
  content: '';
553
580
  position: absolute;
554
581
  background-color: inherit;
555
582
  top: 0;
556
- left:0;
583
+ left: 0;
557
584
  bottom: 0;
558
585
  will-change: left, right;
559
586
  // Custom bezier
@@ -562,34 +589,35 @@ td, th{
562
589
  }
563
590
  }
564
591
  }
592
+
565
593
  @keyframes indeterminate {
566
- 0% {
567
- left: -35%;
568
- right:100%;
569
- }
570
- 60% {
571
- left: 100%;
572
- right: -90%;
573
- }
574
- 100% {
575
- left: 100%;
576
- right: -90%;
577
- }
594
+ 0% {
595
+ left: -35%;
596
+ right: 100%;
597
+ }
598
+ 60% {
599
+ left: 100%;
600
+ right: -90%;
601
+ }
602
+ 100% {
603
+ left: 100%;
604
+ right: -90%;
605
+ }
578
606
  }
579
607
 
580
608
  @keyframes indeterminate-short {
581
- 0% {
582
- left: -200%;
583
- right: 100%;
584
- }
585
- 60% {
586
- left: 107%;
587
- right: -8%;
588
- }
589
- 100% {
590
- left: 107%;
591
- right: -8%;
592
- }
609
+ 0% {
610
+ left: -200%;
611
+ right: 100%;
612
+ }
613
+ 60% {
614
+ left: 107%;
615
+ right: -8%;
616
+ }
617
+ 100% {
618
+ left: 107%;
619
+ right: -8%;
620
+ }
593
621
  }
594
622
 
595
623
 
@@ -600,7 +628,6 @@ td, th{
600
628
  .hide {
601
629
  display: none !important;
602
630
  }
603
-
604
631
  // Text Align
605
632
  .left-align {
606
633
  text-align: left;
@@ -611,36 +638,30 @@ td, th{
611
638
  .center, .center-align {
612
639
  text-align: center;
613
640
  }
614
-
615
641
  .left {
616
642
  float: left !important;
617
643
  }
618
644
  .right {
619
645
  float: right !important;
620
646
  }
621
-
622
647
  // No Text Select
623
648
  .no-select {
624
649
  user-select: none;
625
650
  }
626
-
627
651
  .circle {
628
652
  border-radius: 50%;
629
653
  }
630
-
631
654
  .center-block {
632
655
  display: block;
633
656
  margin-left: auto;
634
657
  margin-right: auto;
635
658
  }
636
-
637
659
  .truncate {
638
660
  display: block;
639
661
  white-space: nowrap;
640
662
  overflow: hidden;
641
663
  text-overflow: ellipsis;
642
664
  }
643
-
644
665
  .no-padding {
645
666
  padding: 0 !important;
646
667
  }