mithril-materialized 2.0.0-beta.9 → 2.0.0-rc.2
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 +353 -10
- package/dist/advanced.css +6 -6
- package/dist/button.d.ts +56 -11
- package/dist/components.css +1674 -6
- package/dist/core.css +13 -13
- package/dist/datatable.d.ts +291 -0
- package/dist/datepicker.d.ts +12 -2
- package/dist/file-upload.d.ts +23 -0
- package/dist/floating-action-button.d.ts +1 -1
- package/dist/forms.css +344 -13
- package/dist/icon.d.ts +2 -2
- package/dist/image-list.d.ts +70 -0
- package/dist/index.css +1940 -20
- package/dist/index.d.ts +8 -0
- package/dist/index.esm.js +2736 -659
- package/dist/index.js +2746 -658
- package/dist/index.min.css +2 -2
- package/dist/index.umd.js +2746 -658
- package/dist/input-options.d.ts +18 -4
- package/dist/input.d.ts +0 -1
- package/dist/masonry.d.ts +17 -0
- package/dist/material-icon.d.ts +3 -0
- package/dist/pickers.css +45 -0
- package/dist/range-slider.d.ts +42 -0
- package/dist/theme-switcher.d.ts +23 -0
- package/dist/timeline.d.ts +43 -0
- package/dist/treeview.d.ts +39 -0
- package/dist/types.d.ts +226 -0
- package/dist/utilities.css +16 -9
- package/package.json +12 -9
- package/sass/components/_cards.scss +10 -3
- package/sass/components/_datatable.scss +417 -0
- package/sass/components/_datepicker.scss +57 -0
- package/sass/components/_global.scss +6 -6
- package/sass/components/_image-list.scss +421 -0
- package/sass/components/_masonry.scss +241 -0
- package/sass/components/_timeline.scss +452 -0
- package/sass/components/_treeview.scss +353 -0
- package/sass/components/forms/_forms.scss +1 -1
- package/sass/components/forms/_range-enhanced.scss +406 -0
- package/sass/components/forms/_range.scss +5 -5
- package/sass/components/forms/_select.scss +1 -1
- package/sass/materialize.scss +6 -0
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "mithril-materialized",
|
|
3
|
-
"version": "2.0.0-
|
|
3
|
+
"version": "2.0.0-rc.2",
|
|
4
4
|
"description": "A materialize library for mithril.",
|
|
5
5
|
"main": "dist/index.js",
|
|
6
6
|
"module": "dist/index.esm.js",
|
|
@@ -36,9 +36,9 @@
|
|
|
36
36
|
],
|
|
37
37
|
"scripts": {
|
|
38
38
|
"build": "rollup -c rollup.config.mjs && npm run build:css-min",
|
|
39
|
-
"build:css-min": "sass --no-source-map --style=compressed ./src/index.scss ./dist/index.min.css && npm run build:css-modules",
|
|
39
|
+
"build:css-min": "sass --no-source-map --style=compressed --no-charset ./src/index.scss ./dist/index.min.css && npm run build:css-modules",
|
|
40
40
|
"build:css-modules": "sass --no-source-map ./src/core.scss ./dist/core.css && sass --no-source-map ./src/components.scss ./dist/components.css && sass --no-source-map ./src/forms.scss ./dist/forms.css && sass --no-source-map ./src/pickers.scss ./dist/pickers.css && sass --no-source-map ./src/advanced.scss ./dist/advanced.css && sass --no-source-map ./src/utilities.scss ./dist/utilities.css",
|
|
41
|
-
"dev": "rollup -c rollup.config.mjs -w",
|
|
41
|
+
"dev": "concurrently \"rollup -c rollup.config.mjs -w\" \"npm run css:watch\"",
|
|
42
42
|
"start": "npm run dev",
|
|
43
43
|
"clean": "rimraf dist node_modules/.cache",
|
|
44
44
|
"test": "jest",
|
|
@@ -54,6 +54,8 @@
|
|
|
54
54
|
"build:domain": "npm run clean && npm run build && typedoc --out ../../docs/typedoc src",
|
|
55
55
|
"dry-run": "npm publish --dry-run",
|
|
56
56
|
"sass:watch": "sass --watch ./sass/materialize.scss ./dist/index.css",
|
|
57
|
+
"css:watch": "sass --watch --no-source-map --style=compressed --no-charset ./src/index.scss ./dist/index.min.css",
|
|
58
|
+
"dev:full": "npm run dev & npm run css:watch",
|
|
57
59
|
"patch-release": "npm run clean && npm run build && npm version patch --force -m \"Patch release\" && npm publish && git push --follow-tags",
|
|
58
60
|
"minor-release": "npm run clean && npm run build && npm version minor --force -m \"Minor release\" && npm publish && git push --follow-tags",
|
|
59
61
|
"major-release": "npm run clean && npm run build && npm version major --force -m \"Major release\" && npm publish && git push --follow-tags"
|
|
@@ -69,29 +71,30 @@
|
|
|
69
71
|
"author": "Erik Vullings <erik.vullings@gmail.com> (http://www.tno.nl)",
|
|
70
72
|
"license": "MIT",
|
|
71
73
|
"dependencies": {
|
|
72
|
-
"mithril": "^2.3.
|
|
74
|
+
"mithril": "^2.3.5"
|
|
73
75
|
},
|
|
74
76
|
"devDependencies": {
|
|
75
|
-
"@playwright/test": "^1.
|
|
77
|
+
"@playwright/test": "^1.55.0",
|
|
76
78
|
"@rollup/plugin-typescript": "^12.1.4",
|
|
77
79
|
"@testing-library/dom": "^10.4.1",
|
|
78
|
-
"@testing-library/jest-dom": "^6.
|
|
80
|
+
"@testing-library/jest-dom": "^6.8.0",
|
|
79
81
|
"@testing-library/user-event": "^14.6.1",
|
|
80
82
|
"@types/jest": "^30.0.0",
|
|
81
83
|
"@types/mithril": "^2.2.7",
|
|
82
84
|
"autoprefixer": "^10.4.21",
|
|
85
|
+
"concurrently": "^9.2.1",
|
|
83
86
|
"express": "^5.1.0",
|
|
84
87
|
"identity-obj-proxy": "^3.0.0",
|
|
85
88
|
"jest": "^30.0.5",
|
|
86
89
|
"jest-environment-jsdom": "^30.0.5",
|
|
87
90
|
"js-yaml": "^4.1.0",
|
|
88
91
|
"rimraf": "^6.0.1",
|
|
89
|
-
"rollup": "^4.
|
|
92
|
+
"rollup": "^4.48.1",
|
|
90
93
|
"rollup-plugin-postcss": "^4.0.2",
|
|
91
|
-
"sass": "^1.
|
|
94
|
+
"sass": "^1.91.0",
|
|
92
95
|
"ts-jest": "^29.4.1",
|
|
93
96
|
"tslib": "^2.8.1",
|
|
94
|
-
"typedoc": "^0.28.
|
|
97
|
+
"typedoc": "^0.28.11",
|
|
95
98
|
"typescript": "^5.9.2"
|
|
96
99
|
}
|
|
97
100
|
}
|
|
@@ -8,13 +8,15 @@
|
|
|
8
8
|
margin: variables.$element-top-margin 0 variables.$element-bottom-margin 0;
|
|
9
9
|
border-radius: 2px;
|
|
10
10
|
@extend .z-depth-1 !optional;
|
|
11
|
-
background-color: variables.$card-bg-color;
|
|
11
|
+
background-color: var(--mm-card-background, variables.$card-bg-color);
|
|
12
|
+
color: var(--mm-text-primary);
|
|
12
13
|
}
|
|
13
14
|
|
|
14
15
|
.card {
|
|
15
16
|
position: relative;
|
|
16
17
|
margin: variables.$element-top-margin 0 variables.$element-bottom-margin 0;
|
|
17
|
-
background-color: variables.$card-bg-color;
|
|
18
|
+
background-color: var(--mm-card-background, variables.$card-bg-color);
|
|
19
|
+
color: var(--mm-text-primary);
|
|
18
20
|
transition: box-shadow .25s;
|
|
19
21
|
border-radius: 2px;
|
|
20
22
|
@extend .z-depth-1 !optional;
|
|
@@ -143,6 +145,8 @@
|
|
|
143
145
|
.card-content {
|
|
144
146
|
padding: variables.$card-padding;
|
|
145
147
|
border-radius: 0 0 2px 2px;
|
|
148
|
+
background-color: var(--mm-card-background, variables.$card-bg-color);
|
|
149
|
+
color: var(--mm-text-primary);
|
|
146
150
|
|
|
147
151
|
p {
|
|
148
152
|
margin: 0;
|
|
@@ -151,6 +155,7 @@
|
|
|
151
155
|
display: block;
|
|
152
156
|
line-height: 32px;
|
|
153
157
|
margin-bottom: 8px;
|
|
158
|
+
color: var(--mm-text-primary);
|
|
154
159
|
|
|
155
160
|
i {
|
|
156
161
|
line-height: 32px;
|
|
@@ -180,7 +185,8 @@
|
|
|
180
185
|
.card-reveal {
|
|
181
186
|
padding: variables.$card-padding;
|
|
182
187
|
position: absolute;
|
|
183
|
-
background-color: variables.$card-bg-color;
|
|
188
|
+
background-color: var(--mm-card-background, variables.$card-bg-color);
|
|
189
|
+
color: var(--mm-text-primary);
|
|
184
190
|
width: 100%;
|
|
185
191
|
overflow-y: auto;
|
|
186
192
|
left: 0;
|
|
@@ -192,6 +198,7 @@
|
|
|
192
198
|
.card-title {
|
|
193
199
|
cursor: pointer;
|
|
194
200
|
display: block;
|
|
201
|
+
color: var(--mm-text-primary);
|
|
195
202
|
}
|
|
196
203
|
}
|
|
197
204
|
}
|
|
@@ -0,0 +1,417 @@
|
|
|
1
|
+
@use "variables";
|
|
2
|
+
|
|
3
|
+
// DataTable Container
|
|
4
|
+
.datatable-container {
|
|
5
|
+
background: var(--mm-card-background);
|
|
6
|
+
color: var(--mm-text-primary);
|
|
7
|
+
border-radius: 4px;
|
|
8
|
+
|
|
9
|
+
.datatable-title {
|
|
10
|
+
color: var(--mm-text-primary);
|
|
11
|
+
font-weight: 400;
|
|
12
|
+
margin-bottom: 1rem;
|
|
13
|
+
}
|
|
14
|
+
|
|
15
|
+
.datatable-global-search {
|
|
16
|
+
padding-top: .5rem;
|
|
17
|
+
}
|
|
18
|
+
|
|
19
|
+
.datatable-wrapper {
|
|
20
|
+
position: relative;
|
|
21
|
+
background: var(--mm-card-background);
|
|
22
|
+
border-radius: 4px;
|
|
23
|
+
overflow: hidden;
|
|
24
|
+
}
|
|
25
|
+
|
|
26
|
+
.table-wrapper {
|
|
27
|
+
overflow-x: auto;
|
|
28
|
+
width: 100%;
|
|
29
|
+
-webkit-overflow-scrolling: touch; // Smooth scrolling on iOS
|
|
30
|
+
background: var(--mm-card-background);
|
|
31
|
+
}
|
|
32
|
+
|
|
33
|
+
// Loading State
|
|
34
|
+
.datatable-loading {
|
|
35
|
+
padding: 2rem;
|
|
36
|
+
text-align: center;
|
|
37
|
+
color: var(--mm-text-secondary);
|
|
38
|
+
background: var(--mm-card-background);
|
|
39
|
+
|
|
40
|
+
.preloader-wrapper {
|
|
41
|
+
margin-bottom: 1rem;
|
|
42
|
+
}
|
|
43
|
+
}
|
|
44
|
+
|
|
45
|
+
// Empty State
|
|
46
|
+
.datatable-empty {
|
|
47
|
+
padding: 3rem 2rem;
|
|
48
|
+
text-align: center;
|
|
49
|
+
color: var(--mm-text-secondary);
|
|
50
|
+
font-style: italic;
|
|
51
|
+
background: var(--mm-card-background);
|
|
52
|
+
}
|
|
53
|
+
}
|
|
54
|
+
|
|
55
|
+
// DataTable Specific Enhancements
|
|
56
|
+
.datatable {
|
|
57
|
+
background: var(--mm-card-background);
|
|
58
|
+
color: var(--mm-text-primary);
|
|
59
|
+
border-collapse: collapse;
|
|
60
|
+
width: 100%;
|
|
61
|
+
|
|
62
|
+
// Table headers
|
|
63
|
+
thead {
|
|
64
|
+
background: var(--mm-card-background);
|
|
65
|
+
|
|
66
|
+
th {
|
|
67
|
+
background: var(--mm-card-background);
|
|
68
|
+
color: var(--mm-text-primary);
|
|
69
|
+
border-bottom: 1px solid var(--mm-border-color);
|
|
70
|
+
font-weight: 500;
|
|
71
|
+
padding: 12px 16px;
|
|
72
|
+
text-align: left;
|
|
73
|
+
}
|
|
74
|
+
}
|
|
75
|
+
|
|
76
|
+
// Table body
|
|
77
|
+
tbody {
|
|
78
|
+
background: var(--mm-card-background);
|
|
79
|
+
|
|
80
|
+
td {
|
|
81
|
+
background: var(--mm-card-background);
|
|
82
|
+
color: var(--mm-text-primary);
|
|
83
|
+
border-bottom: 1px solid var(--mm-border-color);
|
|
84
|
+
padding: 12px 16px;
|
|
85
|
+
}
|
|
86
|
+
}
|
|
87
|
+
|
|
88
|
+
// Sortable column headers
|
|
89
|
+
thead th.sortable {
|
|
90
|
+
cursor: pointer;
|
|
91
|
+
user-select: none;
|
|
92
|
+
position: relative;
|
|
93
|
+
transition: background-color 0.2s ease;
|
|
94
|
+
|
|
95
|
+
&:hover {
|
|
96
|
+
background-color: var(--mm-dropdown-hover);
|
|
97
|
+
}
|
|
98
|
+
|
|
99
|
+
.sort-indicators {
|
|
100
|
+
position: absolute;
|
|
101
|
+
right: 8px;
|
|
102
|
+
top: 50%;
|
|
103
|
+
transform: translateY(-50%);
|
|
104
|
+
display: flex;
|
|
105
|
+
flex-direction: column;
|
|
106
|
+
line-height: 1;
|
|
107
|
+
|
|
108
|
+
.sort-icon {
|
|
109
|
+
font-size: 16px;
|
|
110
|
+
color: var(--mm-text-disabled);
|
|
111
|
+
transition: color 0.2s ease;
|
|
112
|
+
|
|
113
|
+
&.active {
|
|
114
|
+
color: var(--mm-primary-color);
|
|
115
|
+
}
|
|
116
|
+
}
|
|
117
|
+
|
|
118
|
+
.sort-asc {
|
|
119
|
+
margin-bottom: 0px;
|
|
120
|
+
}
|
|
121
|
+
|
|
122
|
+
.sort-desc {
|
|
123
|
+
margin-top: 0px;
|
|
124
|
+
}
|
|
125
|
+
}
|
|
126
|
+
|
|
127
|
+
// Add padding for sort icons
|
|
128
|
+
padding-right: 32px;
|
|
129
|
+
}
|
|
130
|
+
|
|
131
|
+
// Column alignment classes
|
|
132
|
+
.align-left {
|
|
133
|
+
text-align: left;
|
|
134
|
+
}
|
|
135
|
+
|
|
136
|
+
.align-center {
|
|
137
|
+
text-align: center;
|
|
138
|
+
}
|
|
139
|
+
|
|
140
|
+
.align-right {
|
|
141
|
+
text-align: right;
|
|
142
|
+
}
|
|
143
|
+
|
|
144
|
+
// Row hover effects
|
|
145
|
+
tbody tr {
|
|
146
|
+
transition: background-color 0.2s ease;
|
|
147
|
+
cursor: pointer;
|
|
148
|
+
|
|
149
|
+
&:hover {
|
|
150
|
+
background-color: var(--mm-dropdown-hover);
|
|
151
|
+
|
|
152
|
+
td {
|
|
153
|
+
background-color: var(--mm-dropdown-hover);
|
|
154
|
+
}
|
|
155
|
+
}
|
|
156
|
+
}
|
|
157
|
+
|
|
158
|
+
// Enhanced striped rows for dark theme
|
|
159
|
+
&.striped tbody tr:nth-child(odd) {
|
|
160
|
+
background-color: var(--mm-dropdown-focus);
|
|
161
|
+
|
|
162
|
+
td {
|
|
163
|
+
background-color: var(--mm-dropdown-focus);
|
|
164
|
+
}
|
|
165
|
+
|
|
166
|
+
&:hover {
|
|
167
|
+
background-color: var(--mm-dropdown-hover);
|
|
168
|
+
|
|
169
|
+
td {
|
|
170
|
+
background-color: var(--mm-dropdown-hover);
|
|
171
|
+
}
|
|
172
|
+
}
|
|
173
|
+
}
|
|
174
|
+
|
|
175
|
+
// Selection styles
|
|
176
|
+
.selection-checkbox {
|
|
177
|
+
width: 40px;
|
|
178
|
+
text-align: center;
|
|
179
|
+
padding: 0 8px !important;
|
|
180
|
+
|
|
181
|
+
label {
|
|
182
|
+
margin: 0;
|
|
183
|
+
height: 100%;
|
|
184
|
+
display: flex;
|
|
185
|
+
align-items: center;
|
|
186
|
+
justify-content: center;
|
|
187
|
+
}
|
|
188
|
+
|
|
189
|
+
input[type="checkbox"] {
|
|
190
|
+
opacity: 1;
|
|
191
|
+
position: relative;
|
|
192
|
+
left: auto;
|
|
193
|
+
top: auto;
|
|
194
|
+
transform: none;
|
|
195
|
+
margin-right: 0;
|
|
196
|
+
}
|
|
197
|
+
}
|
|
198
|
+
|
|
199
|
+
// Selected row styles
|
|
200
|
+
tbody tr.selected {
|
|
201
|
+
background-color: var(--mm-dropdown-selected) !important;
|
|
202
|
+
|
|
203
|
+
td {
|
|
204
|
+
background-color: var(--mm-dropdown-selected) !important;
|
|
205
|
+
}
|
|
206
|
+
|
|
207
|
+
&:hover {
|
|
208
|
+
background-color: var(--mm-dropdown-selected) !important;
|
|
209
|
+
opacity: 0.9;
|
|
210
|
+
|
|
211
|
+
td {
|
|
212
|
+
background-color: var(--mm-dropdown-selected) !important;
|
|
213
|
+
opacity: 0.9;
|
|
214
|
+
}
|
|
215
|
+
}
|
|
216
|
+
}
|
|
217
|
+
|
|
218
|
+
// Fixed header styles
|
|
219
|
+
&.fixed-header {
|
|
220
|
+
thead th {
|
|
221
|
+
position: sticky;
|
|
222
|
+
top: 0;
|
|
223
|
+
background: var(--mm-card-background);
|
|
224
|
+
z-index: 10;
|
|
225
|
+
box-shadow: 0 2px 4px rgba(0,0,0,0.1);
|
|
226
|
+
}
|
|
227
|
+
}
|
|
228
|
+
}
|
|
229
|
+
|
|
230
|
+
// Pagination Component
|
|
231
|
+
.datatable-pagination {
|
|
232
|
+
margin-top: 1rem;
|
|
233
|
+
display: flex;
|
|
234
|
+
justify-content: space-between;
|
|
235
|
+
align-items: center;
|
|
236
|
+
flex-wrap: wrap;
|
|
237
|
+
gap: 1rem;
|
|
238
|
+
background: var(--mm-card-background);
|
|
239
|
+
color: var(--mm-text-primary);
|
|
240
|
+
padding: 1rem;
|
|
241
|
+
border-top: 1px solid var(--mm-border-color);
|
|
242
|
+
|
|
243
|
+
.pagination-info {
|
|
244
|
+
color: var(--mm-text-secondary);
|
|
245
|
+
font-size: 0.9rem;
|
|
246
|
+
flex: 1;
|
|
247
|
+
min-width: 200px;
|
|
248
|
+
}
|
|
249
|
+
|
|
250
|
+
.pagination-controls {
|
|
251
|
+
display: flex;
|
|
252
|
+
align-items: center;
|
|
253
|
+
gap: 0.5rem;
|
|
254
|
+
|
|
255
|
+
button.btn-flat {
|
|
256
|
+
min-width: 40px;
|
|
257
|
+
height: 40px;
|
|
258
|
+
padding: 0;
|
|
259
|
+
display: flex;
|
|
260
|
+
align-items: center;
|
|
261
|
+
justify-content: center;
|
|
262
|
+
border-radius: 50%;
|
|
263
|
+
transition: background-color 0.2s ease;
|
|
264
|
+
background: transparent;
|
|
265
|
+
color: var(--mm-text-primary);
|
|
266
|
+
border: 1px solid var(--mm-border-color);
|
|
267
|
+
|
|
268
|
+
&:hover:not(:disabled) {
|
|
269
|
+
background-color: var(--mm-dropdown-hover);
|
|
270
|
+
}
|
|
271
|
+
|
|
272
|
+
&:disabled {
|
|
273
|
+
color: var(--mm-text-disabled);
|
|
274
|
+
cursor: not-allowed;
|
|
275
|
+
border-color: var(--mm-text-disabled);
|
|
276
|
+
opacity: 0.6;
|
|
277
|
+
}
|
|
278
|
+
|
|
279
|
+
i {
|
|
280
|
+
font-size: 20px;
|
|
281
|
+
}
|
|
282
|
+
}
|
|
283
|
+
|
|
284
|
+
.page-info {
|
|
285
|
+
margin: 0 0.5rem;
|
|
286
|
+
color: var(--mm-text-secondary);
|
|
287
|
+
font-weight: 500;
|
|
288
|
+
white-space: nowrap;
|
|
289
|
+
}
|
|
290
|
+
}
|
|
291
|
+
}
|
|
292
|
+
|
|
293
|
+
// Responsive enhancements
|
|
294
|
+
@media #{variables.$medium-and-down} {
|
|
295
|
+
.datatable-container {
|
|
296
|
+
.datatable-search {
|
|
297
|
+
max-width: 100%;
|
|
298
|
+
}
|
|
299
|
+
|
|
300
|
+
.datatable-pagination {
|
|
301
|
+
flex-direction: column;
|
|
302
|
+
align-items: stretch;
|
|
303
|
+
text-align: center;
|
|
304
|
+
|
|
305
|
+
.pagination-info {
|
|
306
|
+
order: 2;
|
|
307
|
+
margin-top: 0.5rem;
|
|
308
|
+
text-align: center;
|
|
309
|
+
}
|
|
310
|
+
|
|
311
|
+
.pagination-controls {
|
|
312
|
+
order: 1;
|
|
313
|
+
justify-content: center;
|
|
314
|
+
}
|
|
315
|
+
}
|
|
316
|
+
}
|
|
317
|
+
|
|
318
|
+
// Enhanced responsive table
|
|
319
|
+
.datatable.responsive-table {
|
|
320
|
+
// Hide certain columns on mobile if needed
|
|
321
|
+
&.mobile-hide-secondary {
|
|
322
|
+
th:nth-child(n+4),
|
|
323
|
+
td:nth-child(n+4) {
|
|
324
|
+
display: none;
|
|
325
|
+
}
|
|
326
|
+
}
|
|
327
|
+
|
|
328
|
+
// Stack table cells on very small screens
|
|
329
|
+
@media #{variables.$small-and-down} {
|
|
330
|
+
&.mobile-stack {
|
|
331
|
+
thead {
|
|
332
|
+
display: none;
|
|
333
|
+
}
|
|
334
|
+
|
|
335
|
+
tbody tr {
|
|
336
|
+
display: block;
|
|
337
|
+
border: 1px solid var(--mm-border-color);
|
|
338
|
+
margin-bottom: 1rem;
|
|
339
|
+
padding: 1rem;
|
|
340
|
+
border-radius: 4px;
|
|
341
|
+
background: var(--mm-card-background);
|
|
342
|
+
}
|
|
343
|
+
|
|
344
|
+
tbody td {
|
|
345
|
+
display: block;
|
|
346
|
+
text-align: left !important;
|
|
347
|
+
padding: 0.5rem 0;
|
|
348
|
+
border: none;
|
|
349
|
+
|
|
350
|
+
&::before {
|
|
351
|
+
content: attr(data-label) ": ";
|
|
352
|
+
font-weight: bold;
|
|
353
|
+
color: var(--mm-text-secondary);
|
|
354
|
+
display: inline-block;
|
|
355
|
+
min-width: 100px;
|
|
356
|
+
}
|
|
357
|
+
}
|
|
358
|
+
}
|
|
359
|
+
}
|
|
360
|
+
}
|
|
361
|
+
}
|
|
362
|
+
|
|
363
|
+
// Dark theme specific adjustments
|
|
364
|
+
@media (prefers-color-scheme: dark) {
|
|
365
|
+
:root:not([data-theme]) .datatable-container,
|
|
366
|
+
[data-theme="dark"] .datatable-container {
|
|
367
|
+
.datatable thead th.sortable:hover {
|
|
368
|
+
background-color: var(--mm-dropdown-hover);
|
|
369
|
+
}
|
|
370
|
+
|
|
371
|
+
.datatable tbody tr:hover {
|
|
372
|
+
background-color: var(--mm-dropdown-hover);
|
|
373
|
+
}
|
|
374
|
+
|
|
375
|
+
.datatable.striped tbody tr:nth-child(odd) {
|
|
376
|
+
background-color: rgba(255, 255, 255, 0.05);
|
|
377
|
+
}
|
|
378
|
+
|
|
379
|
+
.datatable.fixed-header thead th {
|
|
380
|
+
border-bottom: 1px solid var(--mm-border-color);
|
|
381
|
+
}
|
|
382
|
+
}
|
|
383
|
+
}
|
|
384
|
+
|
|
385
|
+
// Future: Virtual scrolling styles will be added in Phase 2
|
|
386
|
+
|
|
387
|
+
// Performance optimizations
|
|
388
|
+
.datatable {
|
|
389
|
+
// Use contain for better performance
|
|
390
|
+
contain: layout style paint;
|
|
391
|
+
|
|
392
|
+
// Enable hardware acceleration for smooth scrolling
|
|
393
|
+
&.virtual-table {
|
|
394
|
+
transform: translateZ(0);
|
|
395
|
+
backface-visibility: hidden;
|
|
396
|
+
}
|
|
397
|
+
|
|
398
|
+
// Optimize row rendering
|
|
399
|
+
tbody tr {
|
|
400
|
+
// Use transform3d for better performance
|
|
401
|
+
transform: translateZ(0);
|
|
402
|
+
|
|
403
|
+
// Optimize paint operations
|
|
404
|
+
will-change: transform;
|
|
405
|
+
}
|
|
406
|
+
|
|
407
|
+
// Optimize table layout
|
|
408
|
+
&.fixed-layout {
|
|
409
|
+
table-layout: fixed;
|
|
410
|
+
|
|
411
|
+
th, td {
|
|
412
|
+
overflow: hidden;
|
|
413
|
+
text-overflow: ellipsis;
|
|
414
|
+
white-space: nowrap;
|
|
415
|
+
}
|
|
416
|
+
}
|
|
417
|
+
}
|
|
@@ -135,6 +135,37 @@
|
|
|
135
135
|
font-size: 2.8rem;
|
|
136
136
|
line-height: 47px;
|
|
137
137
|
font-weight: 500;
|
|
138
|
+
|
|
139
|
+
&.placeholder {
|
|
140
|
+
font-size: 1.8rem;
|
|
141
|
+
line-height: 30px;
|
|
142
|
+
color: rgba(255, 255, 255, 0.7);
|
|
143
|
+
font-weight: 400;
|
|
144
|
+
}
|
|
145
|
+
|
|
146
|
+
.range-separator {
|
|
147
|
+
color: rgba(255, 255, 255, 0.8);
|
|
148
|
+
font-size: 1.5rem;
|
|
149
|
+
font-weight: 400;
|
|
150
|
+
}
|
|
151
|
+
|
|
152
|
+
.end-date.placeholder {
|
|
153
|
+
color: rgba(255, 255, 255, 0.5);
|
|
154
|
+
font-style: italic;
|
|
155
|
+
font-size: 1.2rem;
|
|
156
|
+
font-weight: 300;
|
|
157
|
+
}
|
|
158
|
+
}
|
|
159
|
+
|
|
160
|
+
&.range-display {
|
|
161
|
+
.date-text {
|
|
162
|
+
font-size: 1.6rem;
|
|
163
|
+
line-height: 28px;
|
|
164
|
+
|
|
165
|
+
.start-date, .end-date {
|
|
166
|
+
display: inline-block;
|
|
167
|
+
}
|
|
168
|
+
}
|
|
138
169
|
}
|
|
139
170
|
}
|
|
140
171
|
|
|
@@ -189,6 +220,32 @@
|
|
|
189
220
|
color: var(--mm-button-text, #fff);
|
|
190
221
|
}
|
|
191
222
|
|
|
223
|
+
// Range selection states
|
|
224
|
+
&.is-range-start {
|
|
225
|
+
background-color: var(--mm-primary-color, #26a69a);
|
|
226
|
+
color: var(--mm-button-text, #fff);
|
|
227
|
+
border-top-right-radius: 0;
|
|
228
|
+
border-bottom-right-radius: 0;
|
|
229
|
+
}
|
|
230
|
+
|
|
231
|
+
&.is-range-end {
|
|
232
|
+
background-color: var(--mm-primary-color, #26a69a);
|
|
233
|
+
color: var(--mm-button-text, #fff);
|
|
234
|
+
border-top-left-radius: 0;
|
|
235
|
+
border-bottom-left-radius: 0;
|
|
236
|
+
}
|
|
237
|
+
|
|
238
|
+
&.is-in-range {
|
|
239
|
+
background-color: var(--mm-primary-color-alpha-20, rgba(38, 166, 154, 0.2));
|
|
240
|
+
color: var(--mm-text-primary, rgba(0, 0, 0, 0.87));
|
|
241
|
+
border-radius: 0;
|
|
242
|
+
}
|
|
243
|
+
|
|
244
|
+
&.is-range-preview {
|
|
245
|
+
background-color: var(--mm-primary-color-alpha-10, rgba(38, 166, 154, 0.1));
|
|
246
|
+
color: var(--mm-text-primary, rgba(0, 0, 0, 0.87));
|
|
247
|
+
}
|
|
248
|
+
|
|
192
249
|
&.is-outside-current-month,
|
|
193
250
|
&.is-disabled {
|
|
194
251
|
color: var(--mm-text-disabled, rgba(0, 0, 0, 0.3));
|
|
@@ -177,20 +177,20 @@ video.responsive-video {
|
|
|
177
177
|
height: 30px;
|
|
178
178
|
|
|
179
179
|
a {
|
|
180
|
-
color: #444;
|
|
180
|
+
color: var(--mm-text-primary, #444);
|
|
181
181
|
display: inline-block;
|
|
182
182
|
font-size: 1.2rem;
|
|
183
183
|
padding: 0 10px;
|
|
184
184
|
line-height: 30px;
|
|
185
185
|
}
|
|
186
186
|
|
|
187
|
-
&.active a { color: #fff; }
|
|
187
|
+
&.active a { color: var(--mm-text-on-primary, #fff); }
|
|
188
188
|
|
|
189
189
|
&.active { background-color: variables.$primary-color; }
|
|
190
190
|
|
|
191
191
|
&.disabled a {
|
|
192
192
|
cursor: default;
|
|
193
|
-
color: #999;
|
|
193
|
+
color: var(--mm-text-disabled, #999);
|
|
194
194
|
}
|
|
195
195
|
|
|
196
196
|
i {
|
|
@@ -556,8 +556,8 @@ td, th{
|
|
|
556
556
|
i.circle {
|
|
557
557
|
font-size: 18px;
|
|
558
558
|
line-height: 42px;
|
|
559
|
-
color: #fff;
|
|
560
|
-
background-color: #999;
|
|
559
|
+
color: var(--mm-text-on-primary, #fff);
|
|
560
|
+
background-color: var(--mm-text-disabled, #999);
|
|
561
561
|
text-align: center;
|
|
562
562
|
}
|
|
563
563
|
|
|
@@ -588,7 +588,7 @@ td, th{
|
|
|
588
588
|
color: variables.$collection-active-color;
|
|
589
589
|
|
|
590
590
|
.secondary-content {
|
|
591
|
-
color: #fff;
|
|
591
|
+
color: var(--mm-text-on-primary, #fff);
|
|
592
592
|
}
|
|
593
593
|
}
|
|
594
594
|
}
|