mithril-materialized 1.4.2 → 2.0.0-beta.10
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 +286 -306
- package/dist/advanced.css +1888 -0
- package/dist/autocomplete.d.ts +12 -4
- package/dist/breadcrumb.d.ts +53 -0
- package/dist/button.d.ts +10 -10
- package/dist/carousel.d.ts +26 -7
- package/dist/chip.d.ts +2 -2
- package/dist/code-block.d.ts +2 -3
- package/dist/collapsible.d.ts +12 -7
- package/dist/collection.d.ts +8 -8
- package/dist/components.css +2310 -0
- package/dist/core.css +3402 -0
- package/dist/datepicker.d.ts +66 -0
- package/dist/dropdown.d.ts +5 -5
- package/dist/file-upload.d.ts +34 -0
- package/dist/floating-action-button.d.ts +9 -5
- package/dist/forms.css +2284 -0
- package/dist/icon.d.ts +2 -2
- package/dist/index.css +9284 -2
- package/dist/index.d.ts +13 -3
- package/dist/index.esm.js +6188 -2
- package/dist/index.js +6263 -2
- package/dist/index.min.css +8 -0
- package/dist/index.umd.js +6267 -2
- package/dist/input-options.d.ts +3 -1
- package/dist/input.d.ts +17 -12
- package/dist/label.d.ts +6 -5
- package/dist/material-box.d.ts +22 -4
- package/dist/material-icon.d.ts +14 -0
- package/dist/modal.d.ts +23 -7
- package/dist/option.d.ts +12 -11
- package/dist/pagination.d.ts +5 -9
- package/dist/parallax.d.ts +8 -6
- package/dist/pickers.css +487 -0
- package/dist/pushpin.d.ts +32 -0
- package/dist/radio.d.ts +10 -6
- package/dist/select.d.ts +5 -5
- package/dist/sidenav.d.ts +76 -0
- package/dist/switch.d.ts +4 -5
- package/dist/tabs.d.ts +18 -7
- package/dist/theme-switcher.d.ts +49 -0
- package/dist/timepicker.d.ts +42 -0
- package/dist/toast.d.ts +45 -0
- package/dist/tooltip.d.ts +59 -0
- package/dist/utilities.css +3197 -0
- package/dist/utils.d.ts +17 -0
- package/dist/wizard.d.ts +58 -0
- package/package.json +47 -14
- package/sass/components/_badges.scss +59 -0
- package/sass/components/_breadcrumb.scss +248 -0
- package/sass/components/_buttons.scss +327 -0
- package/sass/components/_cards.scss +197 -0
- package/sass/components/_carousel.scss +92 -0
- package/sass/components/_chips.scss +92 -0
- package/sass/components/_collapsible.scss +94 -0
- package/sass/components/_color-classes.scss +34 -0
- package/sass/components/_color-variables.scss +371 -0
- package/sass/components/_datepicker.scss +282 -0
- package/sass/components/_dropdown.scss +90 -0
- package/sass/components/_file-upload.scss +228 -0
- package/sass/components/_global.scss +777 -0
- package/sass/components/_grid.scss +160 -0
- package/sass/components/_icons-material-design.scss +5 -0
- package/sass/components/_materialbox.scss +43 -0
- package/sass/components/_modal.scss +100 -0
- package/sass/components/_navbar.scss +219 -0
- package/sass/components/_normalize.scss +447 -0
- package/sass/components/_preloader.scss +336 -0
- package/sass/components/_pulse.scss +34 -0
- package/sass/components/_sidenav.scss +370 -0
- package/sass/components/_slider.scss +94 -0
- package/sass/components/_table_of_contents.scss +36 -0
- package/sass/components/_tabs.scss +103 -0
- package/sass/components/_tapTarget.scss +105 -0
- package/sass/components/_theme-switcher.scss +120 -0
- package/sass/components/_theme-variables.scss +205 -0
- package/sass/components/_timepicker.scss +262 -0
- package/sass/components/_toast.scss +61 -0
- package/sass/components/_tooltip.scss +32 -0
- package/sass/components/_transitions.scss +13 -0
- package/sass/components/_typography.scss +61 -0
- package/sass/components/_variables.scss +352 -0
- package/sass/components/_waves.scss +114 -0
- package/sass/components/_wizard.scss +416 -0
- package/sass/components/forms/_checkboxes.scss +203 -0
- package/sass/components/forms/_file-input.scss +50 -0
- package/sass/components/forms/_form-groups.scss +28 -0
- package/sass/components/forms/_forms.scss +24 -0
- package/sass/components/forms/_input-fields.scss +383 -0
- package/sass/components/forms/_radio-buttons.scss +118 -0
- package/sass/components/forms/_range.scss +164 -0
- package/sass/components/forms/_select.scss +193 -0
- package/sass/components/forms/_switches.scss +92 -0
- package/sass/materialize.scss +48 -0
- package/dist/index.css.map +0 -1
- package/dist/index.esm.js.map +0 -1
- package/dist/index.js.map +0 -1
- package/dist/index.modern.js +0 -2
- package/dist/index.modern.js.map +0 -1
- package/dist/index.umd.js.map +0 -1
- package/dist/map-editor.d.ts +0 -63
- package/dist/pickers.d.ts +0 -6
- package/dist/timeline.d.ts +0 -24
package/dist/pickers.css
ADDED
|
@@ -0,0 +1,487 @@
|
|
|
1
|
+
/* Modal */
|
|
2
|
+
.datepicker-modal {
|
|
3
|
+
max-width: 325px;
|
|
4
|
+
min-width: 300px;
|
|
5
|
+
max-height: none;
|
|
6
|
+
overflow: visible;
|
|
7
|
+
}
|
|
8
|
+
|
|
9
|
+
.datepicker-container.modal-content {
|
|
10
|
+
display: flex;
|
|
11
|
+
flex-direction: column;
|
|
12
|
+
padding: 0;
|
|
13
|
+
overflow: visible;
|
|
14
|
+
background-color: var(--mm-surface-color, #ffffff);
|
|
15
|
+
color: var(--mm-text-primary, rgba(0, 0, 0, 0.87));
|
|
16
|
+
}
|
|
17
|
+
|
|
18
|
+
.datepicker-controls {
|
|
19
|
+
display: flex;
|
|
20
|
+
justify-content: space-between;
|
|
21
|
+
width: 280px;
|
|
22
|
+
margin: 0 auto;
|
|
23
|
+
overflow: visible;
|
|
24
|
+
}
|
|
25
|
+
.datepicker-controls .selects-container {
|
|
26
|
+
display: flex;
|
|
27
|
+
overflow: visible;
|
|
28
|
+
}
|
|
29
|
+
.datepicker-controls .select-wrapper {
|
|
30
|
+
position: relative;
|
|
31
|
+
overflow: visible;
|
|
32
|
+
}
|
|
33
|
+
.datepicker-controls .select-wrapper input {
|
|
34
|
+
border-bottom: none;
|
|
35
|
+
text-align: center;
|
|
36
|
+
margin: 0;
|
|
37
|
+
cursor: pointer;
|
|
38
|
+
}
|
|
39
|
+
.datepicker-controls .select-wrapper input:focus {
|
|
40
|
+
border-bottom: none;
|
|
41
|
+
}
|
|
42
|
+
.datepicker-controls .select-wrapper .caret {
|
|
43
|
+
position: absolute;
|
|
44
|
+
right: 0;
|
|
45
|
+
top: 50%;
|
|
46
|
+
transform: translateY(-50%);
|
|
47
|
+
cursor: pointer;
|
|
48
|
+
width: 16px;
|
|
49
|
+
height: 16px;
|
|
50
|
+
fill: var(--mm-text-secondary, rgba(0, 0, 0, 0.54));
|
|
51
|
+
}
|
|
52
|
+
.datepicker-controls .select-wrapper .dropdown-content {
|
|
53
|
+
position: absolute;
|
|
54
|
+
top: 100%;
|
|
55
|
+
left: 0;
|
|
56
|
+
right: 0;
|
|
57
|
+
background-color: var(--mm-surface-color, white);
|
|
58
|
+
box-shadow: 0 4px 20px var(--mm-shadow-color, rgba(0, 0, 0, 0.3));
|
|
59
|
+
z-index: 20000;
|
|
60
|
+
border: 1px solid var(--mm-border-color, #ddd);
|
|
61
|
+
border-radius: 2px;
|
|
62
|
+
display: block;
|
|
63
|
+
opacity: 1;
|
|
64
|
+
}
|
|
65
|
+
.datepicker-controls .select-wrapper .dropdown-content .dropdown-item {
|
|
66
|
+
padding: 8px 16px;
|
|
67
|
+
cursor: pointer;
|
|
68
|
+
white-space: nowrap;
|
|
69
|
+
transition: background-color 0.2s;
|
|
70
|
+
}
|
|
71
|
+
.datepicker-controls .select-wrapper .dropdown-content .dropdown-item:hover {
|
|
72
|
+
background-color: var(--mm-border-color, #f5f5f5);
|
|
73
|
+
}
|
|
74
|
+
.datepicker-controls .select-wrapper .dropdown-content .dropdown-item.selected {
|
|
75
|
+
background-color: var(--mm-border-color, #f5f5f5);
|
|
76
|
+
}
|
|
77
|
+
.datepicker-controls .select-year input {
|
|
78
|
+
width: 50px;
|
|
79
|
+
}
|
|
80
|
+
.datepicker-controls .select-year .dropdown-content {
|
|
81
|
+
max-height: 60vh;
|
|
82
|
+
overflow-y: auto;
|
|
83
|
+
}
|
|
84
|
+
.datepicker-controls .select-month input {
|
|
85
|
+
width: 80px;
|
|
86
|
+
}
|
|
87
|
+
.datepicker-controls .select-month .dropdown-content {
|
|
88
|
+
width: auto;
|
|
89
|
+
min-width: 120px;
|
|
90
|
+
left: auto;
|
|
91
|
+
right: 0;
|
|
92
|
+
}
|
|
93
|
+
|
|
94
|
+
.month-prev, .month-next {
|
|
95
|
+
margin-top: 4px;
|
|
96
|
+
cursor: pointer;
|
|
97
|
+
background-color: transparent;
|
|
98
|
+
border: none;
|
|
99
|
+
}
|
|
100
|
+
|
|
101
|
+
/* Date Display */
|
|
102
|
+
.datepicker-date-display {
|
|
103
|
+
flex: 1 auto;
|
|
104
|
+
background-color: #26a69a;
|
|
105
|
+
color: #fff;
|
|
106
|
+
padding: 20px 22px;
|
|
107
|
+
font-weight: 500;
|
|
108
|
+
}
|
|
109
|
+
.datepicker-date-display .year-text {
|
|
110
|
+
display: block;
|
|
111
|
+
font-size: 1.5rem;
|
|
112
|
+
line-height: 25px;
|
|
113
|
+
color: rgba(255, 255, 255, 0.7);
|
|
114
|
+
}
|
|
115
|
+
.datepicker-date-display .date-text {
|
|
116
|
+
display: block;
|
|
117
|
+
font-size: 2.8rem;
|
|
118
|
+
line-height: 47px;
|
|
119
|
+
font-weight: 500;
|
|
120
|
+
}
|
|
121
|
+
|
|
122
|
+
/* Calendar */
|
|
123
|
+
.datepicker-calendar-container {
|
|
124
|
+
flex: 2.5 auto;
|
|
125
|
+
}
|
|
126
|
+
|
|
127
|
+
.datepicker-table {
|
|
128
|
+
width: 280px;
|
|
129
|
+
font-size: 1rem;
|
|
130
|
+
margin: 0 auto;
|
|
131
|
+
}
|
|
132
|
+
.datepicker-table.with-week-numbers {
|
|
133
|
+
width: 310px;
|
|
134
|
+
}
|
|
135
|
+
.datepicker-table thead {
|
|
136
|
+
border-bottom: none;
|
|
137
|
+
}
|
|
138
|
+
.datepicker-table th {
|
|
139
|
+
padding: 10px 5px;
|
|
140
|
+
text-align: center;
|
|
141
|
+
}
|
|
142
|
+
.datepicker-table th.datepicker-week-header {
|
|
143
|
+
color: var(--mm-text-hint, rgba(0, 0, 0, 0.38));
|
|
144
|
+
font-size: 0.8rem;
|
|
145
|
+
font-weight: 600;
|
|
146
|
+
width: 30px;
|
|
147
|
+
padding: 10px 2px;
|
|
148
|
+
}
|
|
149
|
+
.datepicker-table tr {
|
|
150
|
+
border: none;
|
|
151
|
+
}
|
|
152
|
+
.datepicker-table abbr {
|
|
153
|
+
text-decoration: none;
|
|
154
|
+
color: var(--mm-text-secondary, rgba(0, 0, 0, 0.54));
|
|
155
|
+
}
|
|
156
|
+
.datepicker-table td {
|
|
157
|
+
border-radius: 50%;
|
|
158
|
+
padding: 0;
|
|
159
|
+
}
|
|
160
|
+
.datepicker-table td.is-today {
|
|
161
|
+
color: var(--mm-primary-color, #26a69a);
|
|
162
|
+
}
|
|
163
|
+
.datepicker-table td.is-selected {
|
|
164
|
+
background-color: var(--mm-primary-color, #26a69a);
|
|
165
|
+
color: var(--mm-button-text, #fff);
|
|
166
|
+
}
|
|
167
|
+
.datepicker-table td.is-outside-current-month, .datepicker-table td.is-disabled {
|
|
168
|
+
color: var(--mm-text-disabled, rgba(0, 0, 0, 0.3));
|
|
169
|
+
pointer-events: none;
|
|
170
|
+
}
|
|
171
|
+
.datepicker-table td.datepicker-week-number {
|
|
172
|
+
color: var(--mm-text-hint, rgba(0, 0, 0, 0.38));
|
|
173
|
+
font-size: 0.8rem;
|
|
174
|
+
font-weight: 600;
|
|
175
|
+
text-align: center;
|
|
176
|
+
vertical-align: middle;
|
|
177
|
+
border-radius: 0;
|
|
178
|
+
width: 30px;
|
|
179
|
+
padding: 5px 2px;
|
|
180
|
+
background-color: var(--mm-border-color, rgba(0, 0, 0, 0.02));
|
|
181
|
+
border-right: 1px solid var(--mm-border-color, rgba(0, 0, 0, 0.05));
|
|
182
|
+
}
|
|
183
|
+
|
|
184
|
+
.datepicker-day-button {
|
|
185
|
+
background-color: transparent;
|
|
186
|
+
border: none;
|
|
187
|
+
line-height: 38px;
|
|
188
|
+
display: block;
|
|
189
|
+
width: 100%;
|
|
190
|
+
border-radius: 50%;
|
|
191
|
+
padding: 0 5px;
|
|
192
|
+
cursor: pointer;
|
|
193
|
+
color: inherit;
|
|
194
|
+
}
|
|
195
|
+
|
|
196
|
+
/* Footer */
|
|
197
|
+
.datepicker-footer {
|
|
198
|
+
width: 280px;
|
|
199
|
+
margin: 0 auto;
|
|
200
|
+
padding-bottom: 5px;
|
|
201
|
+
display: flex;
|
|
202
|
+
justify-content: space-between;
|
|
203
|
+
}
|
|
204
|
+
|
|
205
|
+
.datepicker-cancel,
|
|
206
|
+
.datepicker-clear,
|
|
207
|
+
.datepicker-today,
|
|
208
|
+
.datepicker-done {
|
|
209
|
+
color: #26a69a;
|
|
210
|
+
padding: 0 1rem;
|
|
211
|
+
}
|
|
212
|
+
|
|
213
|
+
.datepicker-clear {
|
|
214
|
+
color: #f44336;
|
|
215
|
+
}
|
|
216
|
+
|
|
217
|
+
/* Media Queries */
|
|
218
|
+
@media only screen and (min-width: 601px) {
|
|
219
|
+
.datepicker-modal {
|
|
220
|
+
max-width: 625px;
|
|
221
|
+
}
|
|
222
|
+
.datepicker-container.modal-content {
|
|
223
|
+
flex-direction: row;
|
|
224
|
+
}
|
|
225
|
+
.datepicker-date-display {
|
|
226
|
+
flex: 0 1 270px;
|
|
227
|
+
}
|
|
228
|
+
.datepicker-controls,
|
|
229
|
+
.datepicker-table,
|
|
230
|
+
.datepicker-footer {
|
|
231
|
+
width: 320px;
|
|
232
|
+
}
|
|
233
|
+
.datepicker-table.with-week-numbers {
|
|
234
|
+
width: 350px;
|
|
235
|
+
}
|
|
236
|
+
.datepicker-day-button {
|
|
237
|
+
line-height: 44px;
|
|
238
|
+
}
|
|
239
|
+
}
|
|
240
|
+
/* Enhanced TimePicker Styles */
|
|
241
|
+
.input-field.timepicker input[disabled] {
|
|
242
|
+
cursor: not-allowed;
|
|
243
|
+
}
|
|
244
|
+
|
|
245
|
+
.timepicker-actions {
|
|
246
|
+
display: flex;
|
|
247
|
+
gap: 8px;
|
|
248
|
+
margin-top: 4px;
|
|
249
|
+
font-size: 12px;
|
|
250
|
+
}
|
|
251
|
+
.timepicker-actions .btn-flat {
|
|
252
|
+
padding: 2px 8px;
|
|
253
|
+
min-width: auto;
|
|
254
|
+
height: 24px;
|
|
255
|
+
line-height: 20px;
|
|
256
|
+
font-size: 11px;
|
|
257
|
+
text-transform: none;
|
|
258
|
+
}
|
|
259
|
+
.timepicker-actions .btn-flat i.material-icons {
|
|
260
|
+
font-size: 14px;
|
|
261
|
+
margin-right: 4px;
|
|
262
|
+
}
|
|
263
|
+
|
|
264
|
+
.inline-time-controls {
|
|
265
|
+
display: flex;
|
|
266
|
+
align-items: center;
|
|
267
|
+
gap: 8px;
|
|
268
|
+
margin-top: 8px;
|
|
269
|
+
padding: 12px;
|
|
270
|
+
background-color: var(--mm-border-color, #f5f5f5);
|
|
271
|
+
border-radius: 4px;
|
|
272
|
+
font-size: 14px;
|
|
273
|
+
}
|
|
274
|
+
.inline-time-controls .time-controls-12h {
|
|
275
|
+
display: flex;
|
|
276
|
+
align-items: center;
|
|
277
|
+
gap: 4px;
|
|
278
|
+
}
|
|
279
|
+
.inline-time-controls .time-controls-12h input[type=number] {
|
|
280
|
+
width: 50px;
|
|
281
|
+
text-align: center;
|
|
282
|
+
padding: 4px;
|
|
283
|
+
border: 1px solid var(--mm-border-color, #ccc);
|
|
284
|
+
border-radius: 4px;
|
|
285
|
+
}
|
|
286
|
+
.inline-time-controls .time-controls-12h select {
|
|
287
|
+
padding: 4px;
|
|
288
|
+
border: 1px solid var(--mm-border-color, #ccc);
|
|
289
|
+
border-radius: 4px;
|
|
290
|
+
margin-left: 4px;
|
|
291
|
+
}
|
|
292
|
+
.inline-time-controls input[type=time] {
|
|
293
|
+
font-size: 16px;
|
|
294
|
+
padding: 4px 8px;
|
|
295
|
+
border: 1px solid var(--mm-border-color, #ccc);
|
|
296
|
+
border-radius: 4px;
|
|
297
|
+
min-width: 120px;
|
|
298
|
+
}
|
|
299
|
+
.inline-time-controls .btn-flat {
|
|
300
|
+
padding: 4px 8px;
|
|
301
|
+
font-size: 11px;
|
|
302
|
+
background-color: var(--mm-border-color, #e0e0e0);
|
|
303
|
+
border-radius: 4px;
|
|
304
|
+
min-width: auto;
|
|
305
|
+
}
|
|
306
|
+
|
|
307
|
+
/* Timepicker Containers */
|
|
308
|
+
.timepicker-modal {
|
|
309
|
+
max-width: 325px;
|
|
310
|
+
max-height: none;
|
|
311
|
+
}
|
|
312
|
+
|
|
313
|
+
.timepicker-container.modal-content {
|
|
314
|
+
display: flex;
|
|
315
|
+
flex-direction: column;
|
|
316
|
+
padding: 0;
|
|
317
|
+
}
|
|
318
|
+
|
|
319
|
+
.text-primary {
|
|
320
|
+
color: rgb(255, 255, 255);
|
|
321
|
+
}
|
|
322
|
+
|
|
323
|
+
/* Clock Digital Display */
|
|
324
|
+
.timepicker-digital-display {
|
|
325
|
+
flex: 1 auto;
|
|
326
|
+
background-color: #26a69a;
|
|
327
|
+
padding: 10px;
|
|
328
|
+
font-weight: 300;
|
|
329
|
+
}
|
|
330
|
+
|
|
331
|
+
.timepicker-text-container {
|
|
332
|
+
font-size: 4rem;
|
|
333
|
+
font-weight: bold;
|
|
334
|
+
text-align: center;
|
|
335
|
+
color: rgba(255, 255, 255, 0.6);
|
|
336
|
+
font-weight: 400;
|
|
337
|
+
position: relative;
|
|
338
|
+
user-select: none;
|
|
339
|
+
}
|
|
340
|
+
|
|
341
|
+
.timepicker-span-hours,
|
|
342
|
+
.timepicker-span-minutes,
|
|
343
|
+
.timepicker-span-am-pm div {
|
|
344
|
+
cursor: pointer;
|
|
345
|
+
}
|
|
346
|
+
|
|
347
|
+
.timepicker-span-hours {
|
|
348
|
+
margin-right: 3px;
|
|
349
|
+
}
|
|
350
|
+
|
|
351
|
+
.timepicker-span-minutes {
|
|
352
|
+
margin-left: 3px;
|
|
353
|
+
}
|
|
354
|
+
|
|
355
|
+
.timepicker-display-am-pm {
|
|
356
|
+
font-size: 1.3rem;
|
|
357
|
+
position: absolute;
|
|
358
|
+
right: 1rem;
|
|
359
|
+
bottom: 1rem;
|
|
360
|
+
font-weight: 400;
|
|
361
|
+
}
|
|
362
|
+
|
|
363
|
+
/* Analog Clock Display */
|
|
364
|
+
.timepicker-analog-display {
|
|
365
|
+
flex: 2.5 auto;
|
|
366
|
+
}
|
|
367
|
+
|
|
368
|
+
.timepicker-plate {
|
|
369
|
+
background-color: #eee;
|
|
370
|
+
border-radius: 50%;
|
|
371
|
+
width: 270px;
|
|
372
|
+
height: 270px;
|
|
373
|
+
overflow: visible;
|
|
374
|
+
position: relative;
|
|
375
|
+
margin: auto;
|
|
376
|
+
margin-top: 25px;
|
|
377
|
+
margin-bottom: 5px;
|
|
378
|
+
user-select: none;
|
|
379
|
+
}
|
|
380
|
+
|
|
381
|
+
.timepicker-canvas,
|
|
382
|
+
.timepicker-dial {
|
|
383
|
+
position: absolute;
|
|
384
|
+
left: 0;
|
|
385
|
+
right: 0;
|
|
386
|
+
top: 0;
|
|
387
|
+
bottom: 0;
|
|
388
|
+
}
|
|
389
|
+
|
|
390
|
+
.timepicker-minutes {
|
|
391
|
+
visibility: hidden;
|
|
392
|
+
}
|
|
393
|
+
|
|
394
|
+
.timepicker-tick {
|
|
395
|
+
border-radius: 50%;
|
|
396
|
+
color: rgba(0, 0, 0, 0.87);
|
|
397
|
+
line-height: 40px;
|
|
398
|
+
text-align: center;
|
|
399
|
+
width: 40px;
|
|
400
|
+
height: 40px;
|
|
401
|
+
position: absolute;
|
|
402
|
+
cursor: pointer;
|
|
403
|
+
font-size: 15px;
|
|
404
|
+
}
|
|
405
|
+
|
|
406
|
+
.timepicker-tick.active,
|
|
407
|
+
.timepicker-tick:hover {
|
|
408
|
+
background-color: rgba(38, 166, 154, 0.25);
|
|
409
|
+
}
|
|
410
|
+
|
|
411
|
+
.timepicker-dial {
|
|
412
|
+
transition: transform 350ms, opacity 350ms;
|
|
413
|
+
}
|
|
414
|
+
|
|
415
|
+
.timepicker-dial-out {
|
|
416
|
+
opacity: 0;
|
|
417
|
+
}
|
|
418
|
+
.timepicker-dial-out.timepicker-hours {
|
|
419
|
+
transform: scale(1.1, 1.1);
|
|
420
|
+
}
|
|
421
|
+
.timepicker-dial-out.timepicker-minutes {
|
|
422
|
+
transform: scale(0.8, 0.8);
|
|
423
|
+
}
|
|
424
|
+
|
|
425
|
+
.timepicker-canvas {
|
|
426
|
+
transition: opacity 175ms;
|
|
427
|
+
}
|
|
428
|
+
.timepicker-canvas line {
|
|
429
|
+
stroke: #26a69a;
|
|
430
|
+
stroke-width: 4;
|
|
431
|
+
stroke-linecap: round;
|
|
432
|
+
}
|
|
433
|
+
|
|
434
|
+
.timepicker-canvas-out {
|
|
435
|
+
opacity: 0.25;
|
|
436
|
+
}
|
|
437
|
+
|
|
438
|
+
.timepicker-canvas-bearing {
|
|
439
|
+
stroke: none;
|
|
440
|
+
fill: #26a69a;
|
|
441
|
+
}
|
|
442
|
+
|
|
443
|
+
.timepicker-canvas-bg {
|
|
444
|
+
stroke: none;
|
|
445
|
+
fill: #26a69a;
|
|
446
|
+
}
|
|
447
|
+
|
|
448
|
+
/* Footer */
|
|
449
|
+
.timepicker-footer {
|
|
450
|
+
margin: 0 auto;
|
|
451
|
+
padding: 5px 1rem;
|
|
452
|
+
display: flex;
|
|
453
|
+
justify-content: space-between;
|
|
454
|
+
}
|
|
455
|
+
|
|
456
|
+
.timepicker-clear {
|
|
457
|
+
color: #F44336;
|
|
458
|
+
}
|
|
459
|
+
|
|
460
|
+
.timepicker-close {
|
|
461
|
+
color: #26a69a;
|
|
462
|
+
}
|
|
463
|
+
|
|
464
|
+
.timepicker-clear,
|
|
465
|
+
.timepicker-close {
|
|
466
|
+
padding: 0 20px;
|
|
467
|
+
}
|
|
468
|
+
|
|
469
|
+
/* Media Queries */
|
|
470
|
+
@media only screen and (min-width : 601px) {
|
|
471
|
+
.timepicker-modal {
|
|
472
|
+
max-width: 600px;
|
|
473
|
+
}
|
|
474
|
+
.timepicker-container.modal-content {
|
|
475
|
+
flex-direction: row;
|
|
476
|
+
}
|
|
477
|
+
.timepicker-text-container {
|
|
478
|
+
top: 32%;
|
|
479
|
+
}
|
|
480
|
+
.timepicker-display-am-pm {
|
|
481
|
+
position: relative;
|
|
482
|
+
right: auto;
|
|
483
|
+
bottom: auto;
|
|
484
|
+
text-align: center;
|
|
485
|
+
margin-top: 1.2rem;
|
|
486
|
+
}
|
|
487
|
+
}
|
|
@@ -0,0 +1,32 @@
|
|
|
1
|
+
import { FactoryComponent, Attributes } from 'mithril';
|
|
2
|
+
export interface PushpinOptions {
|
|
3
|
+
/** Distance from top of page where element becomes fixed */
|
|
4
|
+
top?: number;
|
|
5
|
+
/** Distance from bottom of page where element stops being fixed */
|
|
6
|
+
bottom?: number;
|
|
7
|
+
/** Offset for calculations */
|
|
8
|
+
offset?: number;
|
|
9
|
+
/** Called when pushpin position changes */
|
|
10
|
+
onPositionChange?: (position: 'pin-top' | 'pinned' | 'pin-bottom') => void;
|
|
11
|
+
}
|
|
12
|
+
export declare class Pushpin {
|
|
13
|
+
el: HTMLElement;
|
|
14
|
+
options: Required<PushpinOptions>;
|
|
15
|
+
private state;
|
|
16
|
+
private static defaults;
|
|
17
|
+
private _updateElementPositionBound;
|
|
18
|
+
constructor(el: HTMLElement, options?: PushpinOptions);
|
|
19
|
+
static getInstance(el: HTMLElement): Pushpin | undefined;
|
|
20
|
+
destroy(): void;
|
|
21
|
+
_setupEventHandlers(): void;
|
|
22
|
+
_removeEventHandlers(): void;
|
|
23
|
+
_updateElementPosition(): void;
|
|
24
|
+
_removePinClasses(): void;
|
|
25
|
+
_updatePosition(): void;
|
|
26
|
+
}
|
|
27
|
+
export interface PushpinAttrs extends Attributes, PushpinOptions {
|
|
28
|
+
/** Element selector or reference to attach pushpin to */
|
|
29
|
+
targetSelector?: string;
|
|
30
|
+
}
|
|
31
|
+
export declare const PushpinComponent: FactoryComponent<PushpinAttrs>;
|
|
32
|
+
export declare const initPushpins: (selector?: string, options?: PushpinOptions) => Pushpin[];
|
package/dist/radio.d.ts
CHANGED
|
@@ -1,12 +1,12 @@
|
|
|
1
1
|
import { Attributes, Component } from 'mithril';
|
|
2
|
-
import {
|
|
3
|
-
export interface
|
|
2
|
+
import { InputOption } from './option';
|
|
3
|
+
export interface RadioButtonsAttrs<T extends string | number> extends Attributes {
|
|
4
4
|
/** Element ID */
|
|
5
5
|
id?: string;
|
|
6
6
|
/** Optional title or label */
|
|
7
7
|
label?: string;
|
|
8
8
|
/** The options that you have */
|
|
9
|
-
options:
|
|
9
|
+
options: InputOption<T>[];
|
|
10
10
|
/** Event handler that is called when an option is changed */
|
|
11
11
|
onchange: (id: T) => void;
|
|
12
12
|
/** Selected id (in oninit lifecycle) */
|
|
@@ -23,15 +23,19 @@ export interface IRadioButtons<T extends string | number> extends Attributes {
|
|
|
23
23
|
checkboxClass?: string;
|
|
24
24
|
/** Disable the button */
|
|
25
25
|
disabled?: boolean;
|
|
26
|
+
/** Layout for the options: 'vertical' (default) or 'horizontal' */
|
|
27
|
+
layout?: 'vertical' | 'horizontal';
|
|
26
28
|
}
|
|
27
|
-
export interface
|
|
29
|
+
export interface RadioButtonAttrs<T extends string | number> extends Attributes {
|
|
28
30
|
id: T;
|
|
29
31
|
checked?: boolean;
|
|
30
32
|
onchange: (id: T) => void;
|
|
31
33
|
label: string;
|
|
32
34
|
groupId: string;
|
|
33
35
|
disabled?: boolean;
|
|
36
|
+
/** Optional input id for the radio button */
|
|
37
|
+
inputId?: string;
|
|
34
38
|
}
|
|
35
|
-
export declare const RadioButton: <T extends string | number>() => Component<
|
|
39
|
+
export declare const RadioButton: <T extends string | number>() => Component<RadioButtonAttrs<T>>;
|
|
36
40
|
/** Component to show a list of radio buttons, from which you can choose one. */
|
|
37
|
-
export declare const RadioButtons: <T extends string | number>() => Component<
|
|
41
|
+
export declare const RadioButtons: <T extends string | number>() => Component<RadioButtonsAttrs<T>>;
|
package/dist/select.d.ts
CHANGED
|
@@ -1,8 +1,8 @@
|
|
|
1
1
|
import { Attributes, Component } from 'mithril';
|
|
2
|
-
import {
|
|
3
|
-
export interface
|
|
2
|
+
import { InputOption } from './option';
|
|
3
|
+
export interface SelectAttrs<T extends string | number> extends Attributes {
|
|
4
4
|
/** Options to select from */
|
|
5
|
-
options:
|
|
5
|
+
options: InputOption<T>[];
|
|
6
6
|
/** Called when the value is changed, either contains a single or all selected (checked) ids */
|
|
7
7
|
onchange: (checkedIds: T[]) => void;
|
|
8
8
|
/**
|
|
@@ -42,5 +42,5 @@ export interface ISelectOptions<T extends string | number> extends Attributes, P
|
|
|
42
42
|
/** Enable the clear icon */
|
|
43
43
|
showClearButton?: boolean;
|
|
44
44
|
}
|
|
45
|
-
/**
|
|
46
|
-
export declare const Select: <T extends string | number>() => Component<
|
|
45
|
+
/** Select component */
|
|
46
|
+
export declare const Select: <T extends string | number>() => Component<SelectAttrs<T>>;
|
|
@@ -0,0 +1,76 @@
|
|
|
1
|
+
import { FactoryComponent, Attributes } from 'mithril';
|
|
2
|
+
export interface SidenavAttrs extends Attributes {
|
|
3
|
+
/** Unique ID for the sidenav */
|
|
4
|
+
id?: string;
|
|
5
|
+
/** Whether the sidenav is open */
|
|
6
|
+
isOpen?: boolean;
|
|
7
|
+
/** Callback when sidenav open state changes */
|
|
8
|
+
onToggle?: (isOpen: boolean) => void;
|
|
9
|
+
/** Position of the sidenav */
|
|
10
|
+
position?: 'left' | 'right';
|
|
11
|
+
/** Whether sidenav should overlay content or push it */
|
|
12
|
+
mode?: 'overlay' | 'push';
|
|
13
|
+
/** Width of the sidenav in pixels */
|
|
14
|
+
width?: number;
|
|
15
|
+
/** Custom class for the sidenav */
|
|
16
|
+
className?: string;
|
|
17
|
+
/** Whether to show backdrop overlay */
|
|
18
|
+
showBackdrop?: boolean;
|
|
19
|
+
/** Close sidenav when backdrop is clicked */
|
|
20
|
+
closeOnBackdropClick?: boolean;
|
|
21
|
+
/** Close sidenav when escape key is pressed */
|
|
22
|
+
closeOnEscape?: boolean;
|
|
23
|
+
/** Animation duration in milliseconds */
|
|
24
|
+
animationDuration?: number;
|
|
25
|
+
/** Fixed sidenav (always visible on larger screens) */
|
|
26
|
+
fixed?: boolean;
|
|
27
|
+
/** Breakpoint for responsive behavior (in pixels) */
|
|
28
|
+
breakpoint?: number;
|
|
29
|
+
}
|
|
30
|
+
export interface SidenavItemAttrs {
|
|
31
|
+
/** Text content of the item */
|
|
32
|
+
text?: string;
|
|
33
|
+
/** Icon name (material icons) */
|
|
34
|
+
icon?: string;
|
|
35
|
+
/** Whether this item is active */
|
|
36
|
+
active?: boolean;
|
|
37
|
+
/** Whether this item is disabled */
|
|
38
|
+
disabled?: boolean;
|
|
39
|
+
/** Click handler */
|
|
40
|
+
onclick?: (e: Event) => void;
|
|
41
|
+
/** Href for link items */
|
|
42
|
+
href?: string;
|
|
43
|
+
/** Custom class */
|
|
44
|
+
className?: string;
|
|
45
|
+
/** Whether this is a divider */
|
|
46
|
+
divider?: boolean;
|
|
47
|
+
/** Whether this is a subheader */
|
|
48
|
+
subheader?: boolean;
|
|
49
|
+
}
|
|
50
|
+
/**
|
|
51
|
+
* Sidenav Component
|
|
52
|
+
* A responsive navigation drawer that slides in from the side
|
|
53
|
+
*/
|
|
54
|
+
export declare const Sidenav: FactoryComponent<SidenavAttrs>;
|
|
55
|
+
/**
|
|
56
|
+
* Sidenav Item Component
|
|
57
|
+
* Individual items for the sidenav menu
|
|
58
|
+
*/
|
|
59
|
+
export declare const SidenavItem: FactoryComponent<SidenavItemAttrs>;
|
|
60
|
+
/**
|
|
61
|
+
* Sidenav utilities for programmatic control
|
|
62
|
+
*/
|
|
63
|
+
export declare class SidenavManager {
|
|
64
|
+
/**
|
|
65
|
+
* Open a sidenav by ID
|
|
66
|
+
*/
|
|
67
|
+
static open(id: string): void;
|
|
68
|
+
/**
|
|
69
|
+
* Close a sidenav by ID
|
|
70
|
+
*/
|
|
71
|
+
static close(id: string): void;
|
|
72
|
+
/**
|
|
73
|
+
* Toggle a sidenav by ID
|
|
74
|
+
*/
|
|
75
|
+
static toggle(id: string): void;
|
|
76
|
+
}
|
package/dist/switch.d.ts
CHANGED
|
@@ -1,13 +1,12 @@
|
|
|
1
1
|
import { FactoryComponent } from 'mithril';
|
|
2
|
-
import {
|
|
3
|
-
|
|
4
|
-
export interface ISwitchOptions extends Partial<IInputOptions<boolean>> {
|
|
2
|
+
import { InputAttrs } from './input-options';
|
|
3
|
+
export interface SwitchOptions extends Partial<InputAttrs<boolean>> {
|
|
5
4
|
/** Left text label */
|
|
6
5
|
left?: string;
|
|
7
6
|
/** Right text label */
|
|
8
7
|
right?: string;
|
|
9
|
-
/** If checked is true, the switch is set in the right position. */
|
|
8
|
+
/** If checked is true, the switch is set in the right position. Only processed in oninit. */
|
|
10
9
|
checked?: boolean;
|
|
11
10
|
}
|
|
12
11
|
/** Component to display a switch with two values. */
|
|
13
|
-
export declare const Switch: FactoryComponent<
|
|
12
|
+
export declare const Switch: FactoryComponent<SwitchOptions>;
|