material-inspired-component-library 5.0.0 → 6.0.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.
- package/README.md +15 -1
- package/components/alert/index.scss +4 -4
- package/components/appbar/index.scss +3 -2
- package/components/badge/index.scss +2 -2
- package/components/bottomsheet/index.scss +6 -5
- package/components/button/README.md +9 -1
- package/components/button/index.scss +20 -20
- package/components/button/index.ts +21 -37
- package/components/card/index.scss +10 -9
- package/components/checkbox/index.scss +11 -11
- package/components/datepicker/README.md +146 -0
- package/components/datepicker/index.scss +436 -0
- package/components/datepicker/index.ts +701 -0
- package/components/dialog/README.md +6 -6
- package/components/dialog/index.scss +23 -17
- package/components/divider/index.scss +2 -0
- package/components/iconbutton/README.md +10 -1
- package/components/iconbutton/index.scss +18 -17
- package/components/iconbutton/index.ts +21 -37
- package/components/list/index.scss +10 -10
- package/components/menu/index.scss +2 -1
- package/components/navigationrail/index.scss +10 -9
- package/components/radio/README.md +0 -1
- package/components/radio/index.scss +11 -11
- package/components/select/index.scss +2 -1
- package/components/sidesheet/index.scss +3 -1
- package/components/slider/index.scss +7 -7
- package/components/stepper/index.scss +5 -4
- package/components/switch/README.md +0 -1
- package/components/switch/index.scss +21 -21
- package/components/textfield/index.scss +6 -5
- package/components/textfield/index.ts +63 -6
- package/components/timepicker/README.md +8 -9
- package/components/timepicker/index.scss +9 -8
- package/components/timepicker/index.ts +17 -17
- package/dist/alert.css +1 -1
- package/dist/appbar.css +1 -1
- package/dist/badge.css +1 -1
- package/dist/bottomsheet.css +1 -1
- package/dist/button.css +1 -1
- package/dist/card.css +1 -1
- package/dist/checkbox.css +1 -1
- package/dist/components/button/index.d.ts +2 -1
- package/dist/components/datepicker/index.d.ts +6 -0
- package/dist/components/iconbutton/index.d.ts +2 -1
- package/dist/datepicker.css +1 -0
- package/dist/datepicker.js +1 -0
- package/dist/dialog.css +1 -1
- package/dist/divider.css +1 -1
- package/dist/foundations.css +1 -0
- package/dist/foundations.js +1 -0
- package/dist/iconbutton.css +1 -1
- package/dist/layout.css +1 -1
- package/dist/list.css +1 -1
- package/dist/menu.css +1 -1
- package/dist/micl.css +1 -1
- package/dist/micl.js +1 -1
- package/dist/navigationrail.css +1 -1
- package/dist/radio.css +1 -1
- package/dist/scrollbar.css +1 -0
- package/dist/scrollbar.js +1 -0
- package/dist/select.css +1 -1
- package/dist/sidesheet.css +1 -1
- package/dist/slider.css +1 -1
- package/dist/stepper.css +1 -1
- package/dist/switch.css +1 -1
- package/dist/textfield.css +1 -1
- package/dist/timepicker.css +1 -1
- package/docs/accordion.html +3 -1
- package/docs/alert.html +3 -1
- package/docs/bottomsheet.html +6 -4
- package/docs/button.html +19 -17
- package/docs/card.html +3 -1
- package/docs/checkbox.html +3 -1
- package/docs/datepicker.html +275 -0
- package/docs/dialog.html +24 -10
- package/docs/divider.html +3 -1
- package/docs/docs.js +65 -1
- package/docs/iconbutton.html +9 -9
- package/docs/index.html +6 -3
- package/docs/list.html +3 -1
- package/docs/menu.html +3 -1
- package/docs/micl.css +1 -1
- package/docs/micl.js +1 -1
- package/docs/navigationrail.html +5 -3
- package/docs/radio.html +3 -1
- package/docs/select.html +3 -1
- package/docs/sidesheet.html +6 -4
- package/docs/slider.html +1 -1
- package/docs/stepper.html +3 -1
- package/docs/switch.html +3 -1
- package/docs/textfield.html +3 -1
- package/docs/themes/gray/dark-hc.css +51 -0
- package/docs/themes/gray/dark-mc.css +51 -0
- package/docs/themes/gray/dark.css +51 -0
- package/docs/themes/gray/light-hc.css +51 -0
- package/docs/themes/gray/light-mc.css +51 -0
- package/docs/themes/gray/light.css +51 -0
- package/docs/themes/gray/theme.css +306 -0
- package/docs/themes/greenery/dark-hc.css +51 -0
- package/docs/themes/greenery/dark-mc.css +51 -0
- package/docs/themes/greenery/dark.css +51 -0
- package/docs/themes/greenery/light-hc.css +51 -0
- package/docs/themes/greenery/light-mc.css +51 -0
- package/docs/themes/greenery/light.css +51 -0
- package/docs/themes/greenery/theme.css +306 -0
- package/docs/themes/hermana/dark-hc.css +51 -0
- package/docs/themes/hermana/dark-mc.css +51 -0
- package/docs/themes/hermana/dark.css +51 -0
- package/docs/themes/hermana/light-hc.css +51 -0
- package/docs/themes/hermana/light-mc.css +51 -0
- package/docs/themes/hermana/light.css +51 -0
- package/docs/themes/hermana/theme.css +306 -0
- package/docs/themes/illuminating/dark-hc.css +51 -0
- package/docs/themes/illuminating/dark-mc.css +51 -0
- package/docs/themes/illuminating/dark.css +51 -0
- package/docs/themes/illuminating/light-hc.css +51 -0
- package/docs/themes/illuminating/light-mc.css +51 -0
- package/docs/themes/illuminating/light.css +51 -0
- package/docs/themes/illuminating/theme.css +306 -0
- package/docs/themes/magenta/dark-hc.css +51 -0
- package/docs/themes/magenta/dark-mc.css +51 -0
- package/docs/themes/magenta/dark.css +51 -0
- package/docs/themes/magenta/light-hc.css +51 -0
- package/docs/themes/magenta/light-mc.css +51 -0
- package/docs/themes/magenta/light.css +51 -0
- package/docs/themes/magenta/theme.css +306 -0
- package/docs/themes/mocha/dark-hc.css +51 -0
- package/docs/themes/mocha/dark-mc.css +51 -0
- package/docs/themes/mocha/dark.css +51 -0
- package/docs/themes/mocha/light-hc.css +51 -0
- package/docs/themes/mocha/light-mc.css +51 -0
- package/docs/themes/mocha/light.css +51 -0
- package/docs/themes/mocha/theme.css +306 -0
- package/docs/themes/peri/dark-hc.css +51 -0
- package/docs/themes/peri/dark-mc.css +51 -0
- package/docs/themes/peri/dark.css +51 -0
- package/docs/themes/peri/light-hc.css +51 -0
- package/docs/themes/peri/light-mc.css +51 -0
- package/docs/themes/peri/light.css +51 -0
- package/docs/themes/peri/theme.css +306 -0
- package/docs/timepicker.html +5 -3
- package/foundations/index.scss +102 -0
- package/foundations/layout/index.scss +0 -52
- package/foundations/scrollbar/index.scss +46 -0
- package/intl.d.ts +9 -0
- package/micl.ts +18 -8
- package/package.json +2 -1
- package/styles/README.md +17 -8
- package/styles/motion.scss +3 -0
- package/styles/shapes.scss +23 -18
- package/styles/statelayer.scss +4 -0
- package/styles/typography.scss +2 -2
- package/styles.scss +3 -26
- package/themes/gray/dark-hc.css +51 -0
- package/themes/gray/dark-mc.css +51 -0
- package/themes/gray/dark.css +51 -0
- package/themes/gray/light-hc.css +51 -0
- package/themes/gray/light-mc.css +51 -0
- package/themes/gray/light.css +51 -0
- package/themes/gray/theme.css +306 -0
- package/themes/greenery/dark-hc.css +51 -0
- package/themes/greenery/dark-mc.css +51 -0
- package/themes/greenery/dark.css +51 -0
- package/themes/greenery/light-hc.css +51 -0
- package/themes/greenery/light-mc.css +51 -0
- package/themes/greenery/light.css +51 -0
- package/themes/greenery/theme.css +306 -0
- package/themes/hermana/dark-hc.css +51 -0
- package/themes/hermana/dark-mc.css +51 -0
- package/themes/hermana/dark.css +51 -0
- package/themes/hermana/light-hc.css +51 -0
- package/themes/hermana/light-mc.css +51 -0
- package/themes/hermana/light.css +51 -0
- package/themes/hermana/theme.css +306 -0
- package/themes/illuminating/dark-hc.css +51 -0
- package/themes/illuminating/dark-mc.css +51 -0
- package/themes/illuminating/dark.css +51 -0
- package/themes/illuminating/light-hc.css +51 -0
- package/themes/illuminating/light-mc.css +51 -0
- package/themes/illuminating/light.css +51 -0
- package/themes/illuminating/theme.css +306 -0
- package/themes/magenta/dark-hc.css +51 -0
- package/themes/magenta/dark-mc.css +51 -0
- package/themes/magenta/dark.css +51 -0
- package/themes/magenta/light-hc.css +51 -0
- package/themes/magenta/light-mc.css +51 -0
- package/themes/magenta/light.css +51 -0
- package/themes/magenta/theme.css +306 -0
- package/themes/mocha/dark-hc.css +51 -0
- package/themes/mocha/dark-mc.css +51 -0
- package/themes/mocha/dark.css +51 -0
- package/themes/mocha/light-hc.css +51 -0
- package/themes/mocha/light-mc.css +51 -0
- package/themes/mocha/light.css +51 -0
- package/themes/mocha/theme.css +306 -0
- package/themes/peri/dark-hc.css +51 -0
- package/themes/peri/dark-mc.css +51 -0
- package/themes/peri/dark.css +51 -0
- package/themes/peri/light-hc.css +51 -0
- package/themes/peri/light-mc.css +51 -0
- package/themes/peri/light.css +51 -0
- package/themes/peri/theme.css +306 -0
- package/tsconfig.json +2 -2
|
@@ -0,0 +1,306 @@
|
|
|
1
|
+
.light {
|
|
2
|
+
--md-sys-color-primary: rgb(88 89 146);
|
|
3
|
+
--md-sys-color-surface-tint: rgb(88 89 146);
|
|
4
|
+
--md-sys-color-on-primary: rgb(255 255 255);
|
|
5
|
+
--md-sys-color-primary-container: rgb(225 223 255);
|
|
6
|
+
--md-sys-color-on-primary-container: rgb(64 65 120);
|
|
7
|
+
--md-sys-color-secondary: rgb(93 92 114);
|
|
8
|
+
--md-sys-color-on-secondary: rgb(255 255 255);
|
|
9
|
+
--md-sys-color-secondary-container: rgb(226 224 249);
|
|
10
|
+
--md-sys-color-on-secondary-container: rgb(69 69 89);
|
|
11
|
+
--md-sys-color-tertiary: rgb(121 83 105);
|
|
12
|
+
--md-sys-color-on-tertiary: rgb(255 255 255);
|
|
13
|
+
--md-sys-color-tertiary-container: rgb(255 216 236);
|
|
14
|
+
--md-sys-color-on-tertiary-container: rgb(95 60 81);
|
|
15
|
+
--md-sys-color-error: rgb(186 26 26);
|
|
16
|
+
--md-sys-color-on-error: rgb(255 255 255);
|
|
17
|
+
--md-sys-color-error-container: rgb(255 218 214);
|
|
18
|
+
--md-sys-color-on-error-container: rgb(147 0 10);
|
|
19
|
+
--md-sys-color-background: rgb(252 248 255);
|
|
20
|
+
--md-sys-color-on-background: rgb(27 27 33);
|
|
21
|
+
--md-sys-color-surface: rgb(252 248 255);
|
|
22
|
+
--md-sys-color-on-surface: rgb(27 27 33);
|
|
23
|
+
--md-sys-color-surface-variant: rgb(228 225 236);
|
|
24
|
+
--md-sys-color-on-surface-variant: rgb(71 70 79);
|
|
25
|
+
--md-sys-color-outline: rgb(119 118 128);
|
|
26
|
+
--md-sys-color-outline-variant: rgb(200 197 208);
|
|
27
|
+
--md-sys-color-shadow: rgb(0 0 0);
|
|
28
|
+
--md-sys-color-scrim: rgb(0 0 0);
|
|
29
|
+
--md-sys-color-inverse-surface: rgb(48 48 54);
|
|
30
|
+
--md-sys-color-inverse-on-surface: rgb(243 239 247);
|
|
31
|
+
--md-sys-color-inverse-primary: rgb(193 193 255);
|
|
32
|
+
--md-sys-color-primary-fixed: rgb(225 223 255);
|
|
33
|
+
--md-sys-color-on-primary-fixed: rgb(20 19 74);
|
|
34
|
+
--md-sys-color-primary-fixed-dim: rgb(193 193 255);
|
|
35
|
+
--md-sys-color-on-primary-fixed-variant: rgb(64 65 120);
|
|
36
|
+
--md-sys-color-secondary-fixed: rgb(226 224 249);
|
|
37
|
+
--md-sys-color-on-secondary-fixed: rgb(26 26 44);
|
|
38
|
+
--md-sys-color-secondary-fixed-dim: rgb(198 196 221);
|
|
39
|
+
--md-sys-color-on-secondary-fixed-variant: rgb(69 69 89);
|
|
40
|
+
--md-sys-color-tertiary-fixed: rgb(255 216 236);
|
|
41
|
+
--md-sys-color-on-tertiary-fixed: rgb(47 17 36);
|
|
42
|
+
--md-sys-color-tertiary-fixed-dim: rgb(233 185 211);
|
|
43
|
+
--md-sys-color-on-tertiary-fixed-variant: rgb(95 60 81);
|
|
44
|
+
--md-sys-color-surface-dim: rgb(220 217 224);
|
|
45
|
+
--md-sys-color-surface-bright: rgb(252 248 255);
|
|
46
|
+
--md-sys-color-surface-container-lowest: rgb(255 255 255);
|
|
47
|
+
--md-sys-color-surface-container-low: rgb(246 242 250);
|
|
48
|
+
--md-sys-color-surface-container: rgb(240 236 244);
|
|
49
|
+
--md-sys-color-surface-container-high: rgb(234 231 239);
|
|
50
|
+
--md-sys-color-surface-container-highest: rgb(228 225 233);
|
|
51
|
+
}
|
|
52
|
+
.light-medium-contrast {
|
|
53
|
+
--md-sys-color-primary: rgb(47 48 102);
|
|
54
|
+
--md-sys-color-surface-tint: rgb(88 89 146);
|
|
55
|
+
--md-sys-color-on-primary: rgb(255 255 255);
|
|
56
|
+
--md-sys-color-primary-container: rgb(103 104 162);
|
|
57
|
+
--md-sys-color-on-primary-container: rgb(255 255 255);
|
|
58
|
+
--md-sys-color-secondary: rgb(52 52 72);
|
|
59
|
+
--md-sys-color-on-secondary: rgb(255 255 255);
|
|
60
|
+
--md-sys-color-secondary-container: rgb(108 107 129);
|
|
61
|
+
--md-sys-color-on-secondary-container: rgb(255 255 255);
|
|
62
|
+
--md-sys-color-tertiary: rgb(77 43 64);
|
|
63
|
+
--md-sys-color-on-tertiary: rgb(255 255 255);
|
|
64
|
+
--md-sys-color-tertiary-container: rgb(137 97 120);
|
|
65
|
+
--md-sys-color-on-tertiary-container: rgb(255 255 255);
|
|
66
|
+
--md-sys-color-error: rgb(116 0 6);
|
|
67
|
+
--md-sys-color-on-error: rgb(255 255 255);
|
|
68
|
+
--md-sys-color-error-container: rgb(207 44 39);
|
|
69
|
+
--md-sys-color-on-error-container: rgb(255 255 255);
|
|
70
|
+
--md-sys-color-background: rgb(252 248 255);
|
|
71
|
+
--md-sys-color-on-background: rgb(27 27 33);
|
|
72
|
+
--md-sys-color-surface: rgb(252 248 255);
|
|
73
|
+
--md-sys-color-on-surface: rgb(17 17 22);
|
|
74
|
+
--md-sys-color-surface-variant: rgb(228 225 236);
|
|
75
|
+
--md-sys-color-on-surface-variant: rgb(54 53 62);
|
|
76
|
+
--md-sys-color-outline: rgb(82 81 91);
|
|
77
|
+
--md-sys-color-outline-variant: rgb(109 108 117);
|
|
78
|
+
--md-sys-color-shadow: rgb(0 0 0);
|
|
79
|
+
--md-sys-color-scrim: rgb(0 0 0);
|
|
80
|
+
--md-sys-color-inverse-surface: rgb(48 48 54);
|
|
81
|
+
--md-sys-color-inverse-on-surface: rgb(243 239 247);
|
|
82
|
+
--md-sys-color-inverse-primary: rgb(193 193 255);
|
|
83
|
+
--md-sys-color-primary-fixed: rgb(103 104 162);
|
|
84
|
+
--md-sys-color-on-primary-fixed: rgb(255 255 255);
|
|
85
|
+
--md-sys-color-primary-fixed-dim: rgb(78 79 135);
|
|
86
|
+
--md-sys-color-on-primary-fixed-variant: rgb(255 255 255);
|
|
87
|
+
--md-sys-color-secondary-fixed: rgb(108 107 129);
|
|
88
|
+
--md-sys-color-on-secondary-fixed: rgb(255 255 255);
|
|
89
|
+
--md-sys-color-secondary-fixed-dim: rgb(83 83 104);
|
|
90
|
+
--md-sys-color-on-secondary-fixed-variant: rgb(255 255 255);
|
|
91
|
+
--md-sys-color-tertiary-fixed: rgb(137 97 120);
|
|
92
|
+
--md-sys-color-on-tertiary-fixed: rgb(255 255 255);
|
|
93
|
+
--md-sys-color-tertiary-fixed-dim: rgb(111 73 95);
|
|
94
|
+
--md-sys-color-on-tertiary-fixed-variant: rgb(255 255 255);
|
|
95
|
+
--md-sys-color-surface-dim: rgb(200 197 205);
|
|
96
|
+
--md-sys-color-surface-bright: rgb(252 248 255);
|
|
97
|
+
--md-sys-color-surface-container-lowest: rgb(255 255 255);
|
|
98
|
+
--md-sys-color-surface-container-low: rgb(246 242 250);
|
|
99
|
+
--md-sys-color-surface-container: rgb(234 231 239);
|
|
100
|
+
--md-sys-color-surface-container-high: rgb(223 219 227);
|
|
101
|
+
--md-sys-color-surface-container-highest: rgb(211 208 216);
|
|
102
|
+
}
|
|
103
|
+
.light-high-contrast {
|
|
104
|
+
--md-sys-color-primary: rgb(37 38 92);
|
|
105
|
+
--md-sys-color-surface-tint: rgb(88 89 146);
|
|
106
|
+
--md-sys-color-on-primary: rgb(255 255 255);
|
|
107
|
+
--md-sys-color-primary-container: rgb(67 67 123);
|
|
108
|
+
--md-sys-color-on-primary-container: rgb(255 255 255);
|
|
109
|
+
--md-sys-color-secondary: rgb(42 42 61);
|
|
110
|
+
--md-sys-color-on-secondary: rgb(255 255 255);
|
|
111
|
+
--md-sys-color-secondary-container: rgb(72 71 92);
|
|
112
|
+
--md-sys-color-on-secondary-container: rgb(255 255 255);
|
|
113
|
+
--md-sys-color-tertiary: rgb(66 34 54);
|
|
114
|
+
--md-sys-color-on-tertiary: rgb(255 255 255);
|
|
115
|
+
--md-sys-color-tertiary-container: rgb(98 62 83);
|
|
116
|
+
--md-sys-color-on-tertiary-container: rgb(255 255 255);
|
|
117
|
+
--md-sys-color-error: rgb(96 0 4);
|
|
118
|
+
--md-sys-color-on-error: rgb(255 255 255);
|
|
119
|
+
--md-sys-color-error-container: rgb(152 0 10);
|
|
120
|
+
--md-sys-color-on-error-container: rgb(255 255 255);
|
|
121
|
+
--md-sys-color-background: rgb(252 248 255);
|
|
122
|
+
--md-sys-color-on-background: rgb(27 27 33);
|
|
123
|
+
--md-sys-color-surface: rgb(252 248 255);
|
|
124
|
+
--md-sys-color-on-surface: rgb(0 0 0);
|
|
125
|
+
--md-sys-color-surface-variant: rgb(228 225 236);
|
|
126
|
+
--md-sys-color-on-surface-variant: rgb(0 0 0);
|
|
127
|
+
--md-sys-color-outline: rgb(44 43 52);
|
|
128
|
+
--md-sys-color-outline-variant: rgb(73 72 81);
|
|
129
|
+
--md-sys-color-shadow: rgb(0 0 0);
|
|
130
|
+
--md-sys-color-scrim: rgb(0 0 0);
|
|
131
|
+
--md-sys-color-inverse-surface: rgb(48 48 54);
|
|
132
|
+
--md-sys-color-inverse-on-surface: rgb(255 255 255);
|
|
133
|
+
--md-sys-color-inverse-primary: rgb(193 193 255);
|
|
134
|
+
--md-sys-color-primary-fixed: rgb(67 67 123);
|
|
135
|
+
--md-sys-color-on-primary-fixed: rgb(255 255 255);
|
|
136
|
+
--md-sys-color-primary-fixed-dim: rgb(44 44 99);
|
|
137
|
+
--md-sys-color-on-primary-fixed-variant: rgb(255 255 255);
|
|
138
|
+
--md-sys-color-secondary-fixed: rgb(72 71 92);
|
|
139
|
+
--md-sys-color-on-secondary-fixed: rgb(255 255 255);
|
|
140
|
+
--md-sys-color-secondary-fixed-dim: rgb(49 49 68);
|
|
141
|
+
--md-sys-color-on-secondary-fixed-variant: rgb(255 255 255);
|
|
142
|
+
--md-sys-color-tertiary-fixed: rgb(98 62 83);
|
|
143
|
+
--md-sys-color-on-tertiary-fixed: rgb(255 255 255);
|
|
144
|
+
--md-sys-color-tertiary-fixed-dim: rgb(73 40 60);
|
|
145
|
+
--md-sys-color-on-tertiary-fixed-variant: rgb(255 255 255);
|
|
146
|
+
--md-sys-color-surface-dim: rgb(186 183 191);
|
|
147
|
+
--md-sys-color-surface-bright: rgb(252 248 255);
|
|
148
|
+
--md-sys-color-surface-container-lowest: rgb(255 255 255);
|
|
149
|
+
--md-sys-color-surface-container-low: rgb(243 239 247);
|
|
150
|
+
--md-sys-color-surface-container: rgb(228 225 233);
|
|
151
|
+
--md-sys-color-surface-container-high: rgb(214 211 219);
|
|
152
|
+
--md-sys-color-surface-container-highest: rgb(200 197 205);
|
|
153
|
+
}
|
|
154
|
+
.dark {
|
|
155
|
+
--md-sys-color-primary: rgb(193 193 255);
|
|
156
|
+
--md-sys-color-surface-tint: rgb(193 193 255);
|
|
157
|
+
--md-sys-color-on-primary: rgb(41 42 96);
|
|
158
|
+
--md-sys-color-primary-container: rgb(64 65 120);
|
|
159
|
+
--md-sys-color-on-primary-container: rgb(225 223 255);
|
|
160
|
+
--md-sys-color-secondary: rgb(198 196 221);
|
|
161
|
+
--md-sys-color-on-secondary: rgb(47 47 66);
|
|
162
|
+
--md-sys-color-secondary-container: rgb(69 69 89);
|
|
163
|
+
--md-sys-color-on-secondary-container: rgb(226 224 249);
|
|
164
|
+
--md-sys-color-tertiary: rgb(233 185 211);
|
|
165
|
+
--md-sys-color-on-tertiary: rgb(70 38 58);
|
|
166
|
+
--md-sys-color-tertiary-container: rgb(95 60 81);
|
|
167
|
+
--md-sys-color-on-tertiary-container: rgb(255 216 236);
|
|
168
|
+
--md-sys-color-error: rgb(255 180 171);
|
|
169
|
+
--md-sys-color-on-error: rgb(105 0 5);
|
|
170
|
+
--md-sys-color-error-container: rgb(147 0 10);
|
|
171
|
+
--md-sys-color-on-error-container: rgb(255 218 214);
|
|
172
|
+
--md-sys-color-background: rgb(19 19 24);
|
|
173
|
+
--md-sys-color-on-background: rgb(228 225 233);
|
|
174
|
+
--md-sys-color-surface: rgb(19 19 24);
|
|
175
|
+
--md-sys-color-on-surface: rgb(228 225 233);
|
|
176
|
+
--md-sys-color-surface-variant: rgb(71 70 79);
|
|
177
|
+
--md-sys-color-on-surface-variant: rgb(200 197 208);
|
|
178
|
+
--md-sys-color-outline: rgb(145 143 154);
|
|
179
|
+
--md-sys-color-outline-variant: rgb(71 70 79);
|
|
180
|
+
--md-sys-color-shadow: rgb(0 0 0);
|
|
181
|
+
--md-sys-color-scrim: rgb(0 0 0);
|
|
182
|
+
--md-sys-color-inverse-surface: rgb(228 225 233);
|
|
183
|
+
--md-sys-color-inverse-on-surface: rgb(48 48 54);
|
|
184
|
+
--md-sys-color-inverse-primary: rgb(88 89 146);
|
|
185
|
+
--md-sys-color-primary-fixed: rgb(225 223 255);
|
|
186
|
+
--md-sys-color-on-primary-fixed: rgb(20 19 74);
|
|
187
|
+
--md-sys-color-primary-fixed-dim: rgb(193 193 255);
|
|
188
|
+
--md-sys-color-on-primary-fixed-variant: rgb(64 65 120);
|
|
189
|
+
--md-sys-color-secondary-fixed: rgb(226 224 249);
|
|
190
|
+
--md-sys-color-on-secondary-fixed: rgb(26 26 44);
|
|
191
|
+
--md-sys-color-secondary-fixed-dim: rgb(198 196 221);
|
|
192
|
+
--md-sys-color-on-secondary-fixed-variant: rgb(69 69 89);
|
|
193
|
+
--md-sys-color-tertiary-fixed: rgb(255 216 236);
|
|
194
|
+
--md-sys-color-on-tertiary-fixed: rgb(47 17 36);
|
|
195
|
+
--md-sys-color-tertiary-fixed-dim: rgb(233 185 211);
|
|
196
|
+
--md-sys-color-on-tertiary-fixed-variant: rgb(95 60 81);
|
|
197
|
+
--md-sys-color-surface-dim: rgb(19 19 24);
|
|
198
|
+
--md-sys-color-surface-bright: rgb(57 56 63);
|
|
199
|
+
--md-sys-color-surface-container-lowest: rgb(14 14 19);
|
|
200
|
+
--md-sys-color-surface-container-low: rgb(27 27 33);
|
|
201
|
+
--md-sys-color-surface-container: rgb(31 31 37);
|
|
202
|
+
--md-sys-color-surface-container-high: rgb(42 41 47);
|
|
203
|
+
--md-sys-color-surface-container-highest: rgb(53 52 58);
|
|
204
|
+
}
|
|
205
|
+
.dark-medium-contrast {
|
|
206
|
+
--md-sys-color-primary: rgb(218 217 255);
|
|
207
|
+
--md-sys-color-surface-tint: rgb(193 193 255);
|
|
208
|
+
--md-sys-color-on-primary: rgb(30 31 85);
|
|
209
|
+
--md-sys-color-primary-container: rgb(139 139 200);
|
|
210
|
+
--md-sys-color-on-primary-container: rgb(0 0 0);
|
|
211
|
+
--md-sys-color-secondary: rgb(220 218 243);
|
|
212
|
+
--md-sys-color-on-secondary: rgb(36 36 54);
|
|
213
|
+
--md-sys-color-secondary-container: rgb(144 142 165);
|
|
214
|
+
--md-sys-color-on-secondary-container: rgb(0 0 0);
|
|
215
|
+
--md-sys-color-tertiary: rgb(255 207 232);
|
|
216
|
+
--md-sys-color-on-tertiary: rgb(58 27 47);
|
|
217
|
+
--md-sys-color-tertiary-container: rgb(176 132 156);
|
|
218
|
+
--md-sys-color-on-tertiary-container: rgb(0 0 0);
|
|
219
|
+
--md-sys-color-error: rgb(255 210 204);
|
|
220
|
+
--md-sys-color-on-error: rgb(84 0 3);
|
|
221
|
+
--md-sys-color-error-container: rgb(255 84 73);
|
|
222
|
+
--md-sys-color-on-error-container: rgb(0 0 0);
|
|
223
|
+
--md-sys-color-background: rgb(19 19 24);
|
|
224
|
+
--md-sys-color-on-background: rgb(228 225 233);
|
|
225
|
+
--md-sys-color-surface: rgb(19 19 24);
|
|
226
|
+
--md-sys-color-on-surface: rgb(255 255 255);
|
|
227
|
+
--md-sys-color-surface-variant: rgb(71 70 79);
|
|
228
|
+
--md-sys-color-on-surface-variant: rgb(222 219 230);
|
|
229
|
+
--md-sys-color-outline: rgb(179 176 187);
|
|
230
|
+
--md-sys-color-outline-variant: rgb(145 143 153);
|
|
231
|
+
--md-sys-color-shadow: rgb(0 0 0);
|
|
232
|
+
--md-sys-color-scrim: rgb(0 0 0);
|
|
233
|
+
--md-sys-color-inverse-surface: rgb(228 225 233);
|
|
234
|
+
--md-sys-color-inverse-on-surface: rgb(42 41 47);
|
|
235
|
+
--md-sys-color-inverse-primary: rgb(65 66 122);
|
|
236
|
+
--md-sys-color-primary-fixed: rgb(225 223 255);
|
|
237
|
+
--md-sys-color-on-primary-fixed: rgb(8 6 65);
|
|
238
|
+
--md-sys-color-primary-fixed-dim: rgb(193 193 255);
|
|
239
|
+
--md-sys-color-on-primary-fixed-variant: rgb(47 48 102);
|
|
240
|
+
--md-sys-color-secondary-fixed: rgb(226 224 249);
|
|
241
|
+
--md-sys-color-on-secondary-fixed: rgb(15 15 33);
|
|
242
|
+
--md-sys-color-secondary-fixed-dim: rgb(198 196 221);
|
|
243
|
+
--md-sys-color-on-secondary-fixed-variant: rgb(52 52 72);
|
|
244
|
+
--md-sys-color-tertiary-fixed: rgb(255 216 236);
|
|
245
|
+
--md-sys-color-on-tertiary-fixed: rgb(34 7 26);
|
|
246
|
+
--md-sys-color-tertiary-fixed-dim: rgb(233 185 211);
|
|
247
|
+
--md-sys-color-on-tertiary-fixed-variant: rgb(77 43 64);
|
|
248
|
+
--md-sys-color-surface-dim: rgb(19 19 24);
|
|
249
|
+
--md-sys-color-surface-bright: rgb(69 68 74);
|
|
250
|
+
--md-sys-color-surface-container-lowest: rgb(7 7 12);
|
|
251
|
+
--md-sys-color-surface-container-low: rgb(29 29 35);
|
|
252
|
+
--md-sys-color-surface-container: rgb(40 39 45);
|
|
253
|
+
--md-sys-color-surface-container-high: rgb(51 50 56);
|
|
254
|
+
--md-sys-color-surface-container-highest: rgb(62 61 67);
|
|
255
|
+
}
|
|
256
|
+
.dark-high-contrast {
|
|
257
|
+
--md-sys-color-primary: rgb(241 238 255);
|
|
258
|
+
--md-sys-color-surface-tint: rgb(193 193 255);
|
|
259
|
+
--md-sys-color-on-primary: rgb(0 0 0);
|
|
260
|
+
--md-sys-color-primary-container: rgb(189 189 253);
|
|
261
|
+
--md-sys-color-on-primary-container: rgb(3 0 60);
|
|
262
|
+
--md-sys-color-secondary: rgb(241 238 255);
|
|
263
|
+
--md-sys-color-on-secondary: rgb(0 0 0);
|
|
264
|
+
--md-sys-color-secondary-container: rgb(194 192 217);
|
|
265
|
+
--md-sys-color-on-secondary-container: rgb(9 9 27);
|
|
266
|
+
--md-sys-color-tertiary: rgb(255 235 243);
|
|
267
|
+
--md-sys-color-on-tertiary: rgb(0 0 0);
|
|
268
|
+
--md-sys-color-tertiary-container: rgb(229 181 207);
|
|
269
|
+
--md-sys-color-on-tertiary-container: rgb(27 3 19);
|
|
270
|
+
--md-sys-color-error: rgb(255 236 233);
|
|
271
|
+
--md-sys-color-on-error: rgb(0 0 0);
|
|
272
|
+
--md-sys-color-error-container: rgb(255 174 164);
|
|
273
|
+
--md-sys-color-on-error-container: rgb(34 0 1);
|
|
274
|
+
--md-sys-color-background: rgb(19 19 24);
|
|
275
|
+
--md-sys-color-on-background: rgb(228 225 233);
|
|
276
|
+
--md-sys-color-surface: rgb(19 19 24);
|
|
277
|
+
--md-sys-color-on-surface: rgb(255 255 255);
|
|
278
|
+
--md-sys-color-surface-variant: rgb(71 70 79);
|
|
279
|
+
--md-sys-color-on-surface-variant: rgb(255 255 255);
|
|
280
|
+
--md-sys-color-outline: rgb(242 238 250);
|
|
281
|
+
--md-sys-color-outline-variant: rgb(196 193 204);
|
|
282
|
+
--md-sys-color-shadow: rgb(0 0 0);
|
|
283
|
+
--md-sys-color-scrim: rgb(0 0 0);
|
|
284
|
+
--md-sys-color-inverse-surface: rgb(228 225 233);
|
|
285
|
+
--md-sys-color-inverse-on-surface: rgb(0 0 0);
|
|
286
|
+
--md-sys-color-inverse-primary: rgb(65 66 122);
|
|
287
|
+
--md-sys-color-primary-fixed: rgb(225 223 255);
|
|
288
|
+
--md-sys-color-on-primary-fixed: rgb(0 0 0);
|
|
289
|
+
--md-sys-color-primary-fixed-dim: rgb(193 193 255);
|
|
290
|
+
--md-sys-color-on-primary-fixed-variant: rgb(8 6 65);
|
|
291
|
+
--md-sys-color-secondary-fixed: rgb(226 224 249);
|
|
292
|
+
--md-sys-color-on-secondary-fixed: rgb(0 0 0);
|
|
293
|
+
--md-sys-color-secondary-fixed-dim: rgb(198 196 221);
|
|
294
|
+
--md-sys-color-on-secondary-fixed-variant: rgb(15 15 33);
|
|
295
|
+
--md-sys-color-tertiary-fixed: rgb(255 216 236);
|
|
296
|
+
--md-sys-color-on-tertiary-fixed: rgb(0 0 0);
|
|
297
|
+
--md-sys-color-tertiary-fixed-dim: rgb(233 185 211);
|
|
298
|
+
--md-sys-color-on-tertiary-fixed-variant: rgb(34 7 26);
|
|
299
|
+
--md-sys-color-surface-dim: rgb(19 19 24);
|
|
300
|
+
--md-sys-color-surface-bright: rgb(80 79 86);
|
|
301
|
+
--md-sys-color-surface-container-lowest: rgb(0 0 0);
|
|
302
|
+
--md-sys-color-surface-container-low: rgb(31 31 37);
|
|
303
|
+
--md-sys-color-surface-container: rgb(48 48 54);
|
|
304
|
+
--md-sys-color-surface-container-high: rgb(59 59 65);
|
|
305
|
+
--md-sys-color-surface-container-highest: rgb(71 70 76);
|
|
306
|
+
}
|
package/docs/timepicker.html
CHANGED
|
@@ -5,7 +5,9 @@
|
|
|
5
5
|
<meta name="viewport" content="width=device-width, initial-scale=1.0">
|
|
6
6
|
<meta name="description" content="Demonstrating MICL Time Pickers">
|
|
7
7
|
<title>MICL Time Pickers</title>
|
|
8
|
-
<link rel="
|
|
8
|
+
<link rel="preconnect" href="https://fonts.googleapis.com">
|
|
9
|
+
<link rel="preconnect" href="https://fonts.gstatic.com" crossorigin>
|
|
10
|
+
<link rel="stylesheet" href="https://fonts.googleapis.com/css2?family=Google+Sans:ital,opsz,wght@0,17..18,400..700;1,17..18,400..700&display=swap">
|
|
9
11
|
<link rel="stylesheet" href="https://fonts.googleapis.com/css2?family=Material+Symbols+Outlined:FILL@0..1&icon_names=dark_mode,home,keyboard,schedule&display=block">
|
|
10
12
|
<link rel="stylesheet" href="themes/airblue/theme.css" id="theme-link">
|
|
11
13
|
<link rel="stylesheet" href="micl.css">
|
|
@@ -78,7 +80,7 @@
|
|
|
78
80
|
<p class="md-sys-typescale-body-medium">Time input using a MICL button component that opens the MICL time picker</p>
|
|
79
81
|
<div class="micl-flex--vcenter" style="column-gap:8px">
|
|
80
82
|
<label for="mytime" class="md-sys-typescale-body-large">Start time:</label>
|
|
81
|
-
<button type="button" id="mytime" class="micl-button-text-m"
|
|
83
|
+
<button type="button" id="mytime" class="micl-button-text-m" command="show-modal" commandfor="mytimepicker2" value="07:53">07:53</button>
|
|
82
84
|
</div>
|
|
83
85
|
<dialog id="mytimepicker2" class="micl-dialog micl-timepicker micl-timepicker--horizontal" closedby="closerequest" aria-labelledby="mytitle2">
|
|
84
86
|
<form method="dialog">
|
|
@@ -97,7 +99,7 @@
|
|
|
97
99
|
<div class="micl-dialog__actions">
|
|
98
100
|
<button type="button" class="micl-timepicker__inputmode micl-iconbutton-standard-s micl-button--square material-symbols-outlined" data-alticon="keyboard">schedule</button>
|
|
99
101
|
<div>
|
|
100
|
-
<button class="micl-button-text-s" value="">Cancel</button>
|
|
102
|
+
<button class="micl-button-text-s" value="" command="close" commandfor="mytimepicker2">Cancel</button>
|
|
101
103
|
<button class="micl-button-text-s" value="OK">OK</button>
|
|
102
104
|
</div>
|
|
103
105
|
</div>
|
|
@@ -0,0 +1,102 @@
|
|
|
1
|
+
//
|
|
2
|
+
// Copyright © 2025 Hermana AS
|
|
3
|
+
//
|
|
4
|
+
// Permission is hereby granted, free of charge, to any person obtaining a copy
|
|
5
|
+
// of this software and associated documentation files (the "Software"), to deal
|
|
6
|
+
// in the Software without restriction, including without limitation the rights
|
|
7
|
+
// to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
|
|
8
|
+
// copies of the Software, and to permit persons to whom the Software is
|
|
9
|
+
// furnished to do so, subject to the following conditions:
|
|
10
|
+
//
|
|
11
|
+
// The above copyright notice and this permission notice shall be included in all
|
|
12
|
+
// copies or substantial portions of the Software.
|
|
13
|
+
//
|
|
14
|
+
// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
|
|
15
|
+
// IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
|
|
16
|
+
// FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
|
|
17
|
+
// AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
|
|
18
|
+
// LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
|
|
19
|
+
// OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
|
|
20
|
+
// SOFTWARE.
|
|
21
|
+
|
|
22
|
+
$md-sys-icon-size: 24px;
|
|
23
|
+
|
|
24
|
+
$md-sys-padding-xxs: 4px;
|
|
25
|
+
$md-sys-padding-xs: 8px;
|
|
26
|
+
$md-sys-padding-s: 12px;
|
|
27
|
+
$md-sys-padding-m: 16px;
|
|
28
|
+
$md-sys-padding-l: 20px;
|
|
29
|
+
$md-sys-padding-xl: 24px;
|
|
30
|
+
$md-sys-padding-xxl: 28px;
|
|
31
|
+
|
|
32
|
+
:root {
|
|
33
|
+
--md-sys-icon-size: #{$md-sys-icon-size};
|
|
34
|
+
|
|
35
|
+
--md-sys-padding-xxs: #{$md-sys-padding-xxs};
|
|
36
|
+
--md-sys-padding-xs: #{$md-sys-padding-xs};
|
|
37
|
+
--md-sys-padding-s: #{$md-sys-padding-s};
|
|
38
|
+
--md-sys-padding-m: #{$md-sys-padding-m};
|
|
39
|
+
--md-sys-padding-l: #{$md-sys-padding-l};
|
|
40
|
+
--md-sys-padding-xl: #{$md-sys-padding-xl};
|
|
41
|
+
--md-sys-padding-xxl: #{$md-sys-padding-xxl};
|
|
42
|
+
}
|
|
43
|
+
|
|
44
|
+
.micl-hidden {
|
|
45
|
+
display: none !important;
|
|
46
|
+
}
|
|
47
|
+
.micl-no-transition {
|
|
48
|
+
transition: none !important;
|
|
49
|
+
}
|
|
50
|
+
.micl-flex--vcenter {
|
|
51
|
+
display: flex;
|
|
52
|
+
flex-direction: row;
|
|
53
|
+
align-items: center;
|
|
54
|
+
}
|
|
55
|
+
|
|
56
|
+
.micl-grid-iconfield {
|
|
57
|
+
box-sizing: border-box;
|
|
58
|
+
display: grid;
|
|
59
|
+
grid-template-columns: 48px 1fr;
|
|
60
|
+
row-gap: var(--md-sys-padding-xl, 24px);
|
|
61
|
+
background-color: inherit;
|
|
62
|
+
}
|
|
63
|
+
.micl-grid-iconfield__icon {
|
|
64
|
+
grid-column: 1;
|
|
65
|
+
margin-block-start: 0.6rem;
|
|
66
|
+
}
|
|
67
|
+
.micl-grid-iconfield__field {
|
|
68
|
+
grid-column: 2;
|
|
69
|
+
}
|
|
70
|
+
|
|
71
|
+
.micl-link {
|
|
72
|
+
display: flex;
|
|
73
|
+
align-items: center;
|
|
74
|
+
justify-content: center;
|
|
75
|
+
text-decoration: none;
|
|
76
|
+
}
|
|
77
|
+
|
|
78
|
+
@property --micl-ripple {
|
|
79
|
+
syntax: '<integer>';
|
|
80
|
+
inherits: false;
|
|
81
|
+
initial-value: 0;
|
|
82
|
+
}
|
|
83
|
+
@property --micl-x {
|
|
84
|
+
syntax: '<length>';
|
|
85
|
+
inherits: false;
|
|
86
|
+
initial-value: -100000px;
|
|
87
|
+
}
|
|
88
|
+
@property --micl-y {
|
|
89
|
+
syntax: '<length>';
|
|
90
|
+
inherits: false;
|
|
91
|
+
initial-value: -100000px;
|
|
92
|
+
}
|
|
93
|
+
@property --micl-width {
|
|
94
|
+
syntax: '<length>';
|
|
95
|
+
inherits: true;
|
|
96
|
+
initial-value: 0px;
|
|
97
|
+
}
|
|
98
|
+
@property --micl-height {
|
|
99
|
+
syntax: '<length>';
|
|
100
|
+
inherits: true;
|
|
101
|
+
initial-value: 0px;
|
|
102
|
+
}
|
|
@@ -38,29 +38,9 @@ $md-sys-window-margin-extralarge: 24px;
|
|
|
38
38
|
|
|
39
39
|
$md-sys-pane-spacer: 24px;
|
|
40
40
|
|
|
41
|
-
$md-sys-padding-xxs: 4px;
|
|
42
|
-
$md-sys-padding-xs: 8px;
|
|
43
|
-
$md-sys-padding-s: 12px;
|
|
44
|
-
$md-sys-padding-m: 16px;
|
|
45
|
-
$md-sys-padding-l: 20px;
|
|
46
|
-
$md-sys-padding-xl: 24px;
|
|
47
|
-
$md-sys-padding-xxl: 28px;
|
|
48
|
-
|
|
49
|
-
$md-sys-icon-size: 24px;
|
|
50
|
-
|
|
51
41
|
:root {
|
|
52
42
|
--md-sys-layout-pane-spacer: #{$md-sys-pane-spacer};
|
|
53
43
|
|
|
54
|
-
--md-sys-layout-padding-xxs: #{$md-sys-padding-xxs};
|
|
55
|
-
--md-sys-layout-padding-xs: #{$md-sys-padding-xs};
|
|
56
|
-
--md-sys-layout-padding-s: #{$md-sys-padding-s};
|
|
57
|
-
--md-sys-layout-padding-m: #{$md-sys-padding-m};
|
|
58
|
-
--md-sys-layout-padding-l: #{$md-sys-padding-l};
|
|
59
|
-
--md-sys-layout-padding-xl: #{$md-sys-padding-xl};
|
|
60
|
-
--md-sys-layout-padding-xxl: #{$md-sys-padding-xxl};
|
|
61
|
-
|
|
62
|
-
--md-sys-layout-icon-size: #{$md-sys-icon-size};
|
|
63
|
-
|
|
64
44
|
@media (max-width: $md-sys-window-compact-max) {
|
|
65
45
|
--md-sys-layout-window-margin: #{$md-sys-window-margin-compact};
|
|
66
46
|
}
|
|
@@ -232,35 +212,3 @@ $md-sys-icon-size: 24px;
|
|
|
232
212
|
flex-direction: column;
|
|
233
213
|
}
|
|
234
214
|
}
|
|
235
|
-
|
|
236
|
-
.micl-hidden {
|
|
237
|
-
display: none !important;
|
|
238
|
-
}
|
|
239
|
-
|
|
240
|
-
.micl-flex--vcenter {
|
|
241
|
-
display: flex;
|
|
242
|
-
flex-direction: row;
|
|
243
|
-
align-items: center;
|
|
244
|
-
}
|
|
245
|
-
|
|
246
|
-
.micl-grid-iconfield {
|
|
247
|
-
box-sizing: border-box;
|
|
248
|
-
display: grid;
|
|
249
|
-
grid-template-columns: 48px 1fr;
|
|
250
|
-
row-gap: var(--md-sys-layout-padding-xl, 24px);
|
|
251
|
-
background-color: inherit;
|
|
252
|
-
}
|
|
253
|
-
.micl-grid-iconfield__icon {
|
|
254
|
-
grid-column: 1;
|
|
255
|
-
margin-block-start: 0.6rem;
|
|
256
|
-
}
|
|
257
|
-
.micl-grid-iconfield__field {
|
|
258
|
-
grid-column: 2;
|
|
259
|
-
}
|
|
260
|
-
|
|
261
|
-
.micl-link {
|
|
262
|
-
display: flex;
|
|
263
|
-
align-items: center;
|
|
264
|
-
justify-content: center;
|
|
265
|
-
text-decoration: none;
|
|
266
|
-
}
|
|
@@ -0,0 +1,46 @@
|
|
|
1
|
+
//
|
|
2
|
+
// Copyright © 2025 Hermana AS
|
|
3
|
+
//
|
|
4
|
+
// Permission is hereby granted, free of charge, to any person obtaining a copy
|
|
5
|
+
// of this software and associated documentation files (the "Software"), to deal
|
|
6
|
+
// in the Software without restriction, including without limitation the rights
|
|
7
|
+
// to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
|
|
8
|
+
// copies of the Software, and to permit persons to whom the Software is
|
|
9
|
+
// furnished to do so, subject to the following conditions:
|
|
10
|
+
//
|
|
11
|
+
// The above copyright notice and this permission notice shall be included in all
|
|
12
|
+
// copies or substantial portions of the Software.
|
|
13
|
+
//
|
|
14
|
+
// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
|
|
15
|
+
// IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
|
|
16
|
+
// FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
|
|
17
|
+
// AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
|
|
18
|
+
// LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
|
|
19
|
+
// OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
|
|
20
|
+
// SOFTWARE.
|
|
21
|
+
|
|
22
|
+
$md-sys-scrollbar-width: 8px;
|
|
23
|
+
$md-sys-scrollbar-margin: 2px;
|
|
24
|
+
$md-sys-scrollbar-size: calc(#{$md-sys-scrollbar-width} + 2 * #{$md-sys-scrollbar-margin});
|
|
25
|
+
$md-sys-scrollbar-thumb-color: grey;
|
|
26
|
+
|
|
27
|
+
::-webkit-scrollbar {
|
|
28
|
+
width: #{$md-sys-scrollbar-size};
|
|
29
|
+
height: #{$md-sys-scrollbar-size};
|
|
30
|
+
}
|
|
31
|
+
::-webkit-scrollbar-thumb {
|
|
32
|
+
border-radius: calc(#{$md-sys-scrollbar-size} / 2);
|
|
33
|
+
background-color: var(--md-sys-scrollbar-thumb-color, #{$md-sys-scrollbar-thumb-color});
|
|
34
|
+
background-clip: content-box;
|
|
35
|
+
border: #{$md-sys-scrollbar-margin} solid transparent;
|
|
36
|
+
}
|
|
37
|
+
::-webkit-scrollbar-button {
|
|
38
|
+
display: none;
|
|
39
|
+
}
|
|
40
|
+
|
|
41
|
+
@supports not selector(::-webkit-scrollbar) {
|
|
42
|
+
.micl-scrollbar {
|
|
43
|
+
scrollbar-width: auto;
|
|
44
|
+
scrollbar-color: var(--md-sys-scrollbar-thumb-color, #{$md-sys-scrollbar-thumb-color}) transparent;
|
|
45
|
+
}
|
|
46
|
+
}
|
package/intl.d.ts
ADDED
package/micl.ts
CHANGED
|
@@ -22,6 +22,7 @@
|
|
|
22
22
|
import _bottomsheet, { bottomsheetSelector } from './components/bottomsheet';
|
|
23
23
|
import _button, { buttonSelector } from './components/button';
|
|
24
24
|
import _checkboxgroup, { checkboxGroupSelector } from './components/checkbox';
|
|
25
|
+
import _datepicker, { datepickerSelector } from './components/datepicker';
|
|
25
26
|
import _list, { listSelector } from './components/list';
|
|
26
27
|
import _menu, { menuSelector } from './components/menu';
|
|
27
28
|
import _navigationrail, { navigationrailSelector } from './components/navigationrail';
|
|
@@ -47,6 +48,7 @@ export default (() =>
|
|
|
47
48
|
[bottomsheetSelector] : { component: _bottomsheet, type: HTMLDialogElement },
|
|
48
49
|
[buttonSelector] : { component: _button, type: HTMLButtonElement },
|
|
49
50
|
[checkboxGroupSelector] : { component: _checkboxgroup, type: HTMLElement },
|
|
51
|
+
[datepickerSelector] : { component: _datepicker, type: HTMLDialogElement },
|
|
50
52
|
[listSelector] : { component: _list, type: HTMLElement },
|
|
51
53
|
[menuSelector] : { component: _menu, type: HTMLElement },
|
|
52
54
|
[navigationrailSelector]: { component: _navigationrail, type: HTMLLabelElement },
|
|
@@ -60,6 +62,14 @@ export default (() =>
|
|
|
60
62
|
|
|
61
63
|
const selector = Object.keys(componentMap).join(',');
|
|
62
64
|
|
|
65
|
+
const initializeScrollbars = (): void =>
|
|
66
|
+
{
|
|
67
|
+
document.documentElement.style.setProperty(
|
|
68
|
+
'--md-sys-scrollbar-thumb-color',
|
|
69
|
+
window.getComputedStyle(document.body).getPropertyValue('--md-sys-color-outline').trim()
|
|
70
|
+
);
|
|
71
|
+
};
|
|
72
|
+
|
|
63
73
|
const initializeComponent = (element: HTMLElement): void =>
|
|
64
74
|
{
|
|
65
75
|
for (const [selector, { component, type }] of Object.entries(componentMap)) {
|
|
@@ -94,6 +104,8 @@ export default (() =>
|
|
|
94
104
|
});
|
|
95
105
|
}
|
|
96
106
|
});
|
|
107
|
+
|
|
108
|
+
initializeScrollbars();
|
|
97
109
|
};
|
|
98
110
|
|
|
99
111
|
const cleanupComponent = (element: HTMLElement): void =>
|
|
@@ -118,14 +130,12 @@ export default (() =>
|
|
|
118
130
|
const handleEvent = (event: Event): void =>
|
|
119
131
|
{
|
|
120
132
|
for (const [selector, { component, type }] of Object.entries(componentMap)) {
|
|
121
|
-
if (
|
|
122
|
-
(event.target as Element).
|
|
123
|
-
|
|
124
|
-
|
|
125
|
-
|
|
126
|
-
|
|
127
|
-
component[event.type as ComponentKey]?.(event);
|
|
128
|
-
return;
|
|
133
|
+
if (typeof component[event.type as ComponentKey] === 'function') {
|
|
134
|
+
const e = (event.target as Element).closest(selector);
|
|
135
|
+
if (e instanceof type) {
|
|
136
|
+
component[event.type as ComponentKey]?.(event);
|
|
137
|
+
return;
|
|
138
|
+
}
|
|
129
139
|
}
|
|
130
140
|
}
|
|
131
141
|
};
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "material-inspired-component-library",
|
|
3
|
-
"version": "
|
|
3
|
+
"version": "6.0.0",
|
|
4
4
|
"description": "The Material-Inspired Component Library (MICL) offers a collection of beautifully crafted components leveraging native HTML markup, designed to align with the Material Design 3 guidelines.",
|
|
5
5
|
"author": "MICL Hermana <micl.hermana@proton.me> (https://github.com/henkpb/micl)",
|
|
6
6
|
"license": "MIT",
|
|
@@ -21,6 +21,7 @@
|
|
|
21
21
|
"button",
|
|
22
22
|
"card",
|
|
23
23
|
"checkbox",
|
|
24
|
+
"date picker",
|
|
24
25
|
"dialog",
|
|
25
26
|
"divider",
|
|
26
27
|
"iconbutton",
|