@mezzanine-ui/core 1.0.0-beta.4 → 1.0.0-beta.6

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 (96) hide show
  1. package/_styles.scss +3 -5
  2. package/autocomplete/_autocomplete-styles.scss +9 -0
  3. package/autocomplete/autocomplete.d.ts +1 -0
  4. package/autocomplete/autocomplete.js +1 -0
  5. package/breadcrumb/_breadcrumb-styles.scss +4 -2
  6. package/calendar/_calendar-styles.scss +82 -43
  7. package/calendar/calendar.d.ts +6 -1
  8. package/calendar/calendar.js +10 -3
  9. package/calendar/typings.d.ts +6 -0
  10. package/calendarMethodsDayjs/index.js +9 -0
  11. package/calendarMethodsLuxon/index.js +5 -0
  12. package/calendarMethodsMoment/index.js +9 -0
  13. package/date-time-range-picker/_date-time-range-picker-styles.scss +25 -0
  14. package/date-time-range-picker/_date-time-range-picker.scss +1 -0
  15. package/date-time-range-picker/_index.scss +1 -0
  16. package/date-time-range-picker/dateTimeRangePicker.d.ts +7 -0
  17. package/date-time-range-picker/dateTimeRangePicker.js +9 -0
  18. package/date-time-range-picker/index.d.ts +1 -0
  19. package/date-time-range-picker/index.js +1 -0
  20. package/drawer/_drawer-styles.scss +15 -7
  21. package/drawer/drawer.d.ts +2 -0
  22. package/drawer/drawer.js +2 -0
  23. package/filter-area/_filter-area-styles.scss +7 -0
  24. package/form/_form-field-styles.scss +27 -0
  25. package/form/formField.d.ts +10 -0
  26. package/form/formField.js +13 -1
  27. package/form/index.js +1 -1
  28. package/modal/_modal-styles.scss +8 -8
  29. package/modal/modal.d.ts +1 -0
  30. package/modal/modal.js +1 -0
  31. package/multiple-date-picker/_index.scss +1 -0
  32. package/multiple-date-picker/_multiple-date-picker-styles.scss +77 -0
  33. package/multiple-date-picker/_multiple-date-picker.scss +1 -0
  34. package/multiple-date-picker/index.d.ts +1 -0
  35. package/multiple-date-picker/index.js +1 -0
  36. package/multiple-date-picker/multipleDatePicker.d.ts +20 -0
  37. package/multiple-date-picker/multipleDatePicker.js +19 -0
  38. package/notification-center/_notification-center-styles.scss +6 -2
  39. package/package.json +3 -3
  40. package/picker/_picker-styles.scss +1 -2
  41. package/scrollbar/_scrollbar-styles.scss +0 -3
  42. package/section/_index.scss +1 -0
  43. package/section/_section-styles.scss +18 -0
  44. package/section/_section.scss +1 -0
  45. package/section/index.d.ts +1 -0
  46. package/section/index.js +1 -0
  47. package/section/section.d.ts +4 -0
  48. package/section/section.js +6 -0
  49. package/select/_select-styles.scss +9 -27
  50. package/select/_select.scss +0 -1
  51. package/select/select.d.ts +3 -5
  52. package/select/select.js +1 -3
  53. package/time-panel/_time-panel-styles.scss +3 -13
  54. package/time-panel/timePanel.d.ts +0 -1
  55. package/time-panel/timePanel.js +0 -1
  56. package/app-bar/_app-bar-styles.scss +0 -125
  57. package/app-bar/_app-bar.scss +0 -5
  58. package/app-bar/_index.scss +0 -1
  59. package/app-bar/appBar.d.ts +0 -8
  60. package/app-bar/appBar.js +0 -8
  61. package/app-bar/appBarBrand.d.ts +0 -4
  62. package/app-bar/appBarBrand.js +0 -8
  63. package/app-bar/appBarMain.d.ts +0 -4
  64. package/app-bar/appBarMain.js +0 -8
  65. package/app-bar/appBarSupport.d.ts +0 -4
  66. package/app-bar/appBarSupport.js +0 -8
  67. package/app-bar/index.d.ts +0 -4
  68. package/app-bar/index.js +0 -4
  69. package/date-range-picker/_date-range-picker-styles.scss +0 -21
  70. package/date-range-picker/_date-range-picker.scss +0 -5
  71. package/date-range-picker/_index.scss +0 -1
  72. package/date-range-picker/dateRangePicker.d.ts +0 -11
  73. package/date-range-picker/dateRangePicker.js +0 -13
  74. package/date-range-picker/index.d.ts +0 -1
  75. package/date-range-picker/index.js +0 -1
  76. package/date-time-picker/_date-time-picker-styles.scss +0 -15
  77. package/date-time-picker/_date-time-picker.scss +0 -2
  78. package/date-time-picker/_index.scss +0 -1
  79. package/date-time-picker/dateTimePicker.d.ts +0 -9
  80. package/date-time-picker/dateTimePicker.js +0 -11
  81. package/date-time-picker/index.d.ts +0 -1
  82. package/date-time-picker/index.js +0 -1
  83. package/popconfirm/_index.scss +0 -1
  84. package/popconfirm/_popconfirm-styles.scss +0 -31
  85. package/popconfirm/_popconfirm.scss +0 -1
  86. package/popconfirm/index.d.ts +0 -1
  87. package/popconfirm/index.js +0 -1
  88. package/popconfirm/popconfirm.d.ts +0 -5
  89. package/popconfirm/popconfirm.js +0 -7
  90. package/popover/_index.scss +0 -1
  91. package/popover/_popover-styles.scss +0 -27
  92. package/popover/_popover.scss +0 -1
  93. package/popover/index.d.ts +0 -1
  94. package/popover/index.js +0 -1
  95. package/popover/popover.d.ts +0 -6
  96. package/popover/popover.js +0 -8
package/_styles.scss CHANGED
@@ -28,7 +28,6 @@
28
28
 
29
29
  // Utility
30
30
  @include _load-styles($options, backdrop);
31
- @include _load-styles($options, popover);
32
31
  @include _load-styles($options, tooltip);
33
32
  @include _load-styles($options, calendar);
34
33
  @include _load-styles($options, time-panel);
@@ -49,7 +48,6 @@
49
48
  @include _load-styles($options, pagination);
50
49
  @include _load-styles($options, drawer);
51
50
  @include _load-styles($options, navigation);
52
- @include _load-styles($options, app-bar);
53
51
  @include _load-styles($options, page-footer);
54
52
  @include _load-styles($options, page-header);
55
53
  @include _load-styles($options, content-header);
@@ -65,6 +63,7 @@
65
63
  @include _load-styles($options, tree);
66
64
  @include _load-styles($options, table);
67
65
  @include _load-styles($options, inline-message);
66
+ @include _load-styles($options, section);
68
67
 
69
68
  // Data Entry
70
69
  @include _load-styles($options, checkbox);
@@ -80,8 +79,8 @@
80
79
  @include _load-styles($options, upload, upload-item);
81
80
  @include _load-styles($options, upload, upload-picture-card);
82
81
  @include _load-styles($options, picker);
83
- @include _load-styles($options, date-range-picker);
84
- @include _load-styles($options, date-time-picker);
82
+ @include _load-styles($options, multiple-date-picker);
83
+ @include _load-styles($options, date-time-range-picker);
85
84
  @include _load-styles($options, slider);
86
85
  @include _load-styles($options, dropdown);
87
86
 
@@ -95,7 +94,6 @@
95
94
  @include _load-styles($options, message);
96
95
  @include _load-styles($options, modal);
97
96
  @include _load-styles($options, notification-center);
98
- @include _load-styles($options, popconfirm);
99
97
  @include _load-styles($options, progress);
100
98
  @include _load-styles($options, spin);
101
99
  @include _load-styles($options, skeleton);
@@ -1,9 +1,18 @@
1
1
  @use '../select/select' as select;
2
2
  @use './autocomplete' as *;
3
+ @use '~@mezzanine-ui/system/spacing' as spacing;
3
4
 
4
5
  .#{$prefix} {
5
6
  position: relative;
6
7
 
8
+ &--single {
9
+ min-width: spacing.semantic-variable(size, container, snug);
10
+ }
11
+
12
+ &--multiple {
13
+ min-width: spacing.semantic-variable(size, container, slim);
14
+ }
15
+
7
16
  &--full-width {
8
17
  width: 100%;
9
18
  }
@@ -8,4 +8,5 @@ export declare const autocompleteClasses: {
8
8
  readonly host: "mzn-autocomplete";
9
9
  readonly hostFullWidth: "mzn-autocomplete--full-width";
10
10
  readonly hostInsideClosed: "mzn-autocomplete--inside-closed";
11
+ readonly hostMode: (mode: AutoCompleteMode) => string;
11
12
  };
@@ -3,6 +3,7 @@ const autocompleteClasses = {
3
3
  host: autocompletePrefix,
4
4
  hostFullWidth: `${autocompletePrefix}--full-width`,
5
5
  hostInsideClosed: `${autocompletePrefix}--inside-closed`,
6
+ hostMode: (mode) => `${autocompletePrefix}--${mode}`,
6
7
  };
7
8
 
8
9
  export { autocompleteClasses, autocompletePrefix };
@@ -45,9 +45,7 @@
45
45
  width: spacing.semantic-variable(size, container, tight);
46
46
 
47
47
  &__content {
48
- margin: spacing.semantic-variable(padding, vertical, tight) 0;
49
48
  background-color: palette.semantic-variable('background', base);
50
- padding: 0 spacing.semantic-variable(padding, horizontal, tight);
51
49
  width: 100%;
52
50
  display: grid;
53
51
  }
@@ -119,6 +117,10 @@
119
117
  &:focus-visible {
120
118
  box-shadow: effect.variable(focus, primary);
121
119
  }
120
+
121
+ &:hover {
122
+ background-color: palette.semantic-variable('background', neutral-faint);
123
+ }
122
124
  }
123
125
 
124
126
  &__icon {
@@ -8,19 +8,6 @@
8
8
  @use '../button/utils' as btn-utils;
9
9
  @use './calendar' as *;
10
10
 
11
- // Todo: width fixed?
12
- @mixin mode-width {
13
- @each $mode in $modes {
14
- .#{$prefix}--#{$mode} & {
15
- @if $mode == week {
16
- width: 292px;
17
- } @else {
18
- width: 260px;
19
- }
20
- }
21
- }
22
- }
23
-
24
11
  .#{$prefix} {
25
12
  display: inline-flex;
26
13
  box-sizing: border-box;
@@ -39,8 +26,6 @@
39
26
  }
40
27
 
41
28
  .#{$main-prefix} {
42
- @include mode-width();
43
-
44
29
  padding: spacing.semantic-variable(padding, vertical, comfort) spacing.semantic-variable(padding, horizontal, comfort);
45
30
 
46
31
  &-with-footer {
@@ -60,16 +45,14 @@
60
45
  }
61
46
 
62
47
  .#{$week-prefix} {
63
- width: 32px;
64
48
  height: 100%;
65
- padding-top: 34px;
49
+ padding-top: 40px;
66
50
  display: flex;
67
51
  flex-flow: column;
68
52
 
69
53
  &__row {
70
- width: 100%;
71
- aspect-ratio: 1 / 1;
72
- padding: spacing.semantic-variable(padding, vertical, micro) 0;
54
+ width: spacing.semantic-variable(size, element, loose);
55
+ height: spacing.semantic-variable(size, element, loose);
73
56
  position: relative;
74
57
 
75
58
  &::after {
@@ -86,6 +69,9 @@
86
69
 
87
70
  .#{$days-grid-prefix} {
88
71
  flex: 1;
72
+ display: grid;
73
+ grid-auto-flow: row;
74
+ gap: spacing.semantic-variable(padding, vertical, micro);
89
75
  }
90
76
 
91
77
  .#{$button-prefix} {
@@ -96,7 +82,7 @@
96
82
  align-items: center;
97
83
  justify-content: center;
98
84
  gap: 0;
99
- border: 1px solid transparent;
85
+ border: none;
100
86
  border-radius: radius.variable(base);
101
87
  transition: transition.standard(background-color) transition.standard(color) transition.standard(border);
102
88
 
@@ -117,15 +103,13 @@
117
103
  background-color: palette.semantic-variable("background", neutral-faint);
118
104
  }
119
105
 
120
- .#{$cell-prefix}--today & {
121
- border: 1px solid palette.semantic-variable(border, brand);
122
- }
123
-
124
106
  &--inRange {
107
+ border-radius: 0;
125
108
  background-color: palette.semantic-variable("background", brand-faint);
126
109
  }
127
110
 
128
111
  &--active {
112
+ border-radius: radius.variable(base);
129
113
  color: palette.semantic-variable(text, fixed-light);
130
114
  background-color: palette.semantic-variable("background", brand);
131
115
 
@@ -146,20 +130,19 @@
146
130
 
147
131
  &:focus-visible {
148
132
  outline: none;
149
- box-shadow: effect.variable(focus, primary);
133
+ box-shadow: effect.variable(focus, inner);
134
+
135
+ &:not(.#{$button-prefix}--active):not(.#{$button-prefix}--inRange) {
136
+ background-color: palette.semantic-variable("background", neutral-faint);
137
+ }
150
138
  }
151
139
  }
152
140
 
153
141
  .#{$row-prefix} {
154
142
  display: grid;
155
143
  grid-template-columns: repeat(7, minmax(0, 1fr));
156
- column-gap: spacing.semantic-variable(gap, tiny);
144
+ column-gap: 0;
157
145
  width: 100%;
158
- padding: spacing.semantic-variable(padding, vertical, micro) 0;
159
-
160
- &:first-child {
161
- padding-top: 0;
162
- }
163
146
 
164
147
  .#{$prefix}--quarter & {
165
148
  padding: spacing.semantic-variable(padding, vertical, tiny) 0;
@@ -179,16 +162,35 @@
179
162
  }
180
163
 
181
164
  .#{$cell-prefix} {
165
+ --today-dot-color: #{palette.semantic-variable(icon, brand)};
182
166
  --#{$cell-prefix}-text-color: #{palette.semantic-variable(text, neutral-solid)};
183
167
 
184
168
  position: relative;
185
- width: 100%;
186
- padding-top: 100%;
169
+ width: spacing.semantic-variable(size, element, loose);
170
+ height: spacing.semantic-variable(size, element, loose);
187
171
  color: var(--#{$cell-prefix}-text-color);
188
172
  user-select: none;
189
173
  transition: transition.standard(color);
190
174
 
191
- @include typography.semantic-variable(label-primary);
175
+ @include typography.semantic-variable(input);
176
+
177
+ &--mode-day,
178
+ &--mode-week {
179
+ width: spacing.semantic-variable(size, element, loose);
180
+ height: spacing.semantic-variable(size, element, loose);
181
+ }
182
+
183
+ &--mode-month,
184
+ &--mode-half-year,
185
+ &--mode-year {
186
+ width: spacing.semantic-variable(size, element, extra);
187
+ height: spacing.semantic-variable(size, element, loose);
188
+ }
189
+
190
+ &--mode-quarter {
191
+ width: spacing.semantic-variable(size, element, wide-expanded);
192
+ height: spacing.semantic-variable(size, element, loose);
193
+ }
192
194
 
193
195
  button {
194
196
  width: 100%;
@@ -206,7 +208,22 @@
206
208
  height: 100%;
207
209
  }
208
210
 
211
+ &--weekend {
212
+ --#{$cell-prefix}-text-color: #{palette.semantic-variable(text, brand)};
213
+ }
214
+
215
+ &--range-start {
216
+ border-radius: radius.variable(base) 0 0 radius.variable(base);
217
+ background-color: palette.semantic-variable("background", brand-faint);
218
+ }
219
+
220
+ &--range-end {
221
+ border-radius: 0 radius.variable(base) radius.variable(base) 0;
222
+ background-color: palette.semantic-variable("background", brand-faint);
223
+ }
224
+
209
225
  &--active {
226
+ --today-dot-color: #{palette.semantic-variable(icon, fixed-light)};
210
227
  --#{$cell-prefix}-text-color: #{palette.semantic-variable(text, neutral-solid)};
211
228
  }
212
229
 
@@ -218,28 +235,47 @@
218
235
  .#{$prefix}--half-year & {
219
236
  padding-top: 32px;
220
237
  }
238
+
239
+ &--today {
240
+ &::after {
241
+ position: absolute;
242
+ bottom: 7px;
243
+ left: 50%;
244
+ z-index: 1;
245
+ transform: translateX(-50%);
246
+ content: '';
247
+ width: spacing.semantic-variable(size, element, micro);
248
+ height: spacing.semantic-variable(size, element, micro);
249
+ border-radius: 1px;
250
+ background-color: var(--today-dot-color);
251
+ pointer-events: none;
252
+ }
253
+
254
+ &.#{$cell-prefix}--with-annotation::after {
255
+ bottom: 3px;
256
+ }
257
+ }
221
258
  }
222
259
 
223
260
  .#{$twelve-grid-prefix} {
224
261
  display: grid;
225
- grid-template-columns: repeat(3, minmax(0, 1fr));
226
- grid-auto-rows: 32px;
227
- gap: calc(#{spacing.semantic-variable(padding, vertical, micro)} * 2) spacing.semantic-variable(gap, tiny);
262
+ grid-template-columns: repeat(4, minmax(0, 1fr));
263
+ gap: calc(#{spacing.semantic-variable(padding, vertical, micro)} * 2) 0;
228
264
  width: 100%;
229
265
 
230
- @include typography.semantic-variable(label-primary);
266
+ @include typography.semantic-variable(input);
231
267
 
232
268
  color: palette.semantic-variable(text, neutral-solid);
233
269
  }
234
270
 
235
271
  .#{$controls-prefix} {
236
- padding: spacing.semantic-variable(padding, vertical, tiny) spacing.semantic-variable(padding, horizontal, relaxed);
272
+ padding: 0;
273
+ margin: 0;
237
274
  display: flex;
238
275
  justify-content: space-between;
239
276
  gap: spacing.semantic-variable(gap, tiny);
240
277
  position: relative;
241
278
  width: 100%;
242
- margin: 0 0 spacing.semantic-variable(gap, tight);
243
279
  box-sizing: border-box;
244
280
 
245
281
  &__actions {
@@ -252,7 +288,9 @@
252
288
  @include btn-utils.reset();
253
289
 
254
290
  line-height: 0;
255
- padding: spacing.semantic-variable(padding, vertical, micro) 0;
291
+ width: spacing.semantic-variable(size, element, roomy);
292
+ height: spacing.semantic-variable(size, element, roomy);
293
+ padding: 0;
256
294
  border-radius: radius.variable(base);
257
295
  color: palette.semantic-variable(icon, neutral);
258
296
 
@@ -290,7 +328,7 @@
290
328
 
291
329
  &:focus-visible {
292
330
  outline: none;
293
- box-shadow: effect.variable(focus, primary);
331
+ box-shadow: effect.variable(focus, inner);
294
332
  }
295
333
 
296
334
  &:disabled {
@@ -312,6 +350,7 @@
312
350
  }
313
351
 
314
352
  .#{$footer-actions-prefix} {
353
+ box-sizing: border-box;
315
354
  width: 100%;
316
355
  border-top: 1px solid palette.semantic-variable(separator, neutral-faint);
317
356
  padding: spacing.semantic-variable(padding, vertical, base) spacing.semantic-variable(padding, horizontal, comfort);
@@ -39,10 +39,15 @@ export declare const calendarClasses: {
39
39
  rowWithBorder: string;
40
40
  /** Cell classes */
41
41
  cell: string;
42
+ cellMode: (mode: CalendarMode) => string;
42
43
  cellInner: string;
44
+ cellWeekend: string;
43
45
  cellToday: string;
44
46
  cellActive: string;
45
47
  cellDisabled: string;
48
+ cellWithAnnotation: string;
49
+ cellRangeStart: string;
50
+ cellRangeEnd: string;
46
51
  /** Twelve grid classes */
47
52
  twelveGrid: string;
48
53
  /** Controls classes */
@@ -60,7 +65,7 @@ export declare const calendarClasses: {
60
65
  };
61
66
  /** Constants */
62
67
  export declare const calendarYearsBase: number[];
63
- export declare const calendarYearModuler = 10;
68
+ export declare const calendarYearModuler = 20;
64
69
  export declare const calendarMonths: number[];
65
70
  export declare const calendarQuarters: number[];
66
71
  export declare const calendarQuarterYearsCount = 5;
@@ -35,10 +35,15 @@ const calendarClasses = {
35
35
  rowWithBorder: `${calendarRowPrefix}--with-border`,
36
36
  /** Cell classes */
37
37
  cell: calendarCellPrefix,
38
+ cellMode: (mode) => `${calendarCellPrefix}--mode-${mode}`,
38
39
  cellInner: `${calendarCellPrefix}__inner`,
40
+ cellWeekend: `${calendarCellPrefix}--weekend`,
39
41
  cellToday: `${calendarCellPrefix}--today`,
40
42
  cellActive: `${calendarCellPrefix}--active`,
41
43
  cellDisabled: `${calendarCellPrefix}--disabled`,
44
+ cellWithAnnotation: `${calendarCellPrefix}--with-annotation`,
45
+ cellRangeStart: `${calendarCellPrefix}--range-start`,
46
+ cellRangeEnd: `${calendarCellPrefix}--range-end`,
42
47
  /** Twelve grid classes */
43
48
  twelveGrid: calendarTwelveGridPrefix,
44
49
  /** Controls classes */
@@ -55,8 +60,10 @@ const calendarClasses = {
55
60
  quickSelectButtonActive: `${calendarQuickSelectPrefix}__button--active`,
56
61
  };
57
62
  /** Constants */
58
- const calendarYearsBase = [0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11];
59
- const calendarYearModuler = 10;
63
+ const calendarYearsBase = [
64
+ 0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15, 16, 17, 18, 19,
65
+ ];
66
+ const calendarYearModuler = 20;
60
67
  const calendarMonths = [0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11];
61
68
  const calendarQuarters = [1, 2, 3, 4];
62
69
  const calendarQuarterYearsCount = 5;
@@ -71,7 +78,7 @@ function getYearRange(year, mod) {
71
78
  }
72
79
  function getCalendarYearRange(year) {
73
80
  const [start, end] = getYearRange(year, calendarYearModuler);
74
- return [start - 1, end + 1];
81
+ return [start, end];
75
82
  }
76
83
  /**
77
84
  * Locales that use ISO week (Monday as first day of week).
@@ -39,6 +39,12 @@ export type CalendarMethods<TDateType = DateType> = {
39
39
  * Check if locale uses ISO week (Monday as first day)
40
40
  */
41
41
  isISOWeekLocale: (locale: string) => boolean;
42
+ /**
43
+ * Get a boolean array indicating which positions in the week are weekends.
44
+ * For Monday-first locales: [false, false, false, false, false, true, true] (Sat, Sun at positions 5, 6)
45
+ * For Sunday-first locales: [true, false, false, false, false, false, true] (Sun at 0, Sat at 6)
46
+ */
47
+ getWeekends: (locale: string) => boolean[];
42
48
  /** Manipulate */
43
49
  addHour: (value: TDateType, diff: number) => TDateType;
44
50
  addMinute: (value: TDateType, diff: number) => TDateType;
@@ -198,6 +198,15 @@ const CalendarMethodsDayjs = {
198
198
  getMonthShortNames: (locale) => {
199
199
  return dayjs().locale(localeMapping(locale)).localeData().monthsShort();
200
200
  },
201
+ getWeekends: (locale) => {
202
+ // Saturday and Sunday are always weekends
203
+ // For Monday-first: [Mon, Tue, Wed, Thu, Fri, Sat, Sun] → positions 5, 6 are weekends
204
+ // For Sunday-first: [Sun, Mon, Tue, Wed, Thu, Fri, Sat] → positions 0, 6 are weekends
205
+ if (isMondayFirst(locale)) {
206
+ return [false, false, false, false, false, true, true];
207
+ }
208
+ return [true, false, false, false, false, false, true];
209
+ },
201
210
  /** Manipulate */
202
211
  addHour: (date, diff) => dayjs(date).add(diff, 'hour').toISOString(),
203
212
  addMinute: (date, diff) => dayjs(date).add(diff, 'minute').toISOString(),
@@ -35,6 +35,11 @@ const CalendarMethodsLuxon = {
35
35
  return names[month];
36
36
  },
37
37
  getMonthShortNames: (locale) => Info.months('short', { locale }),
38
+ getWeekends: () => {
39
+ // Luxon always uses ISO week (Monday-first)
40
+ // [Mon, Tue, Wed, Thu, Fri, Sat, Sun] → positions 5, 6 are weekends
41
+ return [false, false, false, false, false, true, true];
42
+ },
38
43
  /** Manipulate */
39
44
  addHour: (date, diff) => DateTime.fromISO(date).plus({ hour: diff }).toISO(),
40
45
  addMinute: (date, diff) => DateTime.fromISO(date).plus({ minute: diff }).toISO(),
@@ -63,6 +63,15 @@ const CalendarMethodsMoment = {
63
63
  },
64
64
  getFirstDayOfWeek: (locale) => getActualFirstDayOfWeek(locale),
65
65
  isISOWeekLocale,
66
+ getWeekends: (locale) => {
67
+ // Saturday and Sunday are always weekends
68
+ // For Monday-first: [Mon, Tue, Wed, Thu, Fri, Sat, Sun] → positions 5, 6 are weekends
69
+ // For Sunday-first: [Sun, Mon, Tue, Wed, Thu, Fri, Sat] → positions 0, 6 are weekends
70
+ if (isMondayFirst(locale)) {
71
+ return [false, false, false, false, false, true, true];
72
+ }
73
+ return [true, false, false, false, false, false, true];
74
+ },
66
75
  /** Manipulate */
67
76
  addHour: (date, diff) => {
68
77
  const clone = moment(date);
@@ -0,0 +1,25 @@
1
+ @use 'sass:map';
2
+ @use '~@mezzanine-ui/system/spacing';
3
+ @use '~@mezzanine-ui/system/palette';
4
+ @use './date-time-range-picker' as *;
5
+
6
+ .#{$prefix} {
7
+ display: inline-flex;
8
+ align-items: center;
9
+ gap: spacing.semantic-variable(gap, base);
10
+
11
+ &--row {
12
+ flex-direction: row;
13
+ }
14
+
15
+ &--column {
16
+ flex-direction: column;
17
+ }
18
+
19
+ &__arrow {
20
+ display: flex;
21
+ align-items: center;
22
+ justify-content: center;
23
+ color: palette.semantic-variable(icon, neutral-light);
24
+ }
25
+ }
@@ -0,0 +1 @@
1
+ $prefix: mzn-date-time-range-picker;
@@ -0,0 +1 @@
1
+ @forward './date-time-range-picker';
@@ -0,0 +1,7 @@
1
+ export declare const dateTimeRangePickerPrefix = "mzn-date-time-range-picker";
2
+ export declare const dateTimeRangePickerClasses: {
3
+ readonly host: "mzn-date-time-range-picker";
4
+ readonly row: "mzn-date-time-range-picker--row";
5
+ readonly column: "mzn-date-time-range-picker--column";
6
+ readonly arrow: "mzn-date-time-range-picker__arrow";
7
+ };
@@ -0,0 +1,9 @@
1
+ const dateTimeRangePickerPrefix = 'mzn-date-time-range-picker';
2
+ const dateTimeRangePickerClasses = {
3
+ host: dateTimeRangePickerPrefix,
4
+ row: `${dateTimeRangePickerPrefix}--row`,
5
+ column: `${dateTimeRangePickerPrefix}--column`,
6
+ arrow: `${dateTimeRangePickerPrefix}__arrow`,
7
+ };
8
+
9
+ export { dateTimeRangePickerClasses, dateTimeRangePickerPrefix };
@@ -0,0 +1 @@
1
+ export { dateTimeRangePickerPrefix, dateTimeRangePickerClasses, } from './dateTimeRangePicker';
@@ -0,0 +1 @@
1
+ export { dateTimeRangePickerClasses, dateTimeRangePickerPrefix } from './dateTimeRangePicker.js';
@@ -5,7 +5,6 @@
5
5
  @use '~@mezzanine-ui/system/spacing';
6
6
  @use '~@mezzanine-ui/system/radius';
7
7
 
8
- @use '../app-bar';
9
8
  @use './drawer' as *;
10
9
 
11
10
  $drawer-size: 256px !default;
@@ -70,11 +69,24 @@ $drawer-size-config: (
70
69
  }
71
70
  }
72
71
 
72
+ &__control-bar {
73
+ align-items: center;
74
+ border-block-end: 1px solid palette.semantic-variable(separator, neutral-faint);
75
+ display: flex;
76
+ justify-content: space-between;
77
+ padding-block: spacing.semantic-variable(padding, vertical, base) spacing.semantic-variable(padding, vertical, comfort);
78
+ padding-inline: spacing.semantic-variable(padding, horizontal, spacious);
79
+
80
+ &--button-only {
81
+ justify-content: flex-end;
82
+ }
83
+ }
84
+
73
85
  &__content {
86
+ flex-grow: 1;
87
+ overflow: auto;
74
88
  padding-block: spacing.semantic-variable(padding, vertical, comfort);
75
89
  padding-inline: spacing.semantic-variable(padding, horizontal, spacious);
76
- overflow: auto;
77
- flex-grow: 1;
78
90
  }
79
91
 
80
92
  &__bottom {
@@ -94,10 +106,6 @@ $drawer-size-config: (
94
106
  }
95
107
  }
96
108
 
97
- .#{app-bar.$prefix} {
98
- border: none;
99
- }
100
-
101
109
  &__overlay {
102
110
  z-index: z-index.get(drawer);
103
111
  }
@@ -14,4 +14,6 @@ export declare const drawerClasses: {
14
14
  readonly bottom__actions: "mzn-drawer__bottom__actions";
15
15
  readonly size: (size: DrawerSize) => string;
16
16
  readonly content: "mzn-drawer__content";
17
+ readonly controlBar: "mzn-drawer__control-bar";
18
+ readonly controlBarButtonOnly: "mzn-drawer__control-bar--button-only";
17
19
  };
package/drawer/drawer.js CHANGED
@@ -8,6 +8,8 @@ const drawerClasses = {
8
8
  bottom__actions: `${drawerPrefix}__bottom__actions`,
9
9
  size: (size) => `${drawerPrefix}--${size}`,
10
10
  content: `${drawerPrefix}__content`,
11
+ controlBar: `${drawerPrefix}__control-bar`,
12
+ controlBarButtonOnly: `${drawerPrefix}__control-bar--button-only`,
11
13
  };
12
14
 
13
15
  export { drawerClasses, drawerPrefix };
@@ -3,6 +3,7 @@
3
3
  @use '~@mezzanine-ui/system/radius' as radius;
4
4
  @use '~@mezzanine-ui/system/transition' as transition;
5
5
  @use './filter-area' as *;
6
+ @use '../form/form-field' as formField;
6
7
 
7
8
  // Actions alignment configs
8
9
  $actions-align-configs: (
@@ -135,6 +136,12 @@ $layout-configs: (
135
136
  min-width: 0;
136
137
  grid-column: span var(--#{$prefix}-filter-span);
137
138
 
139
+ .#{formField.$prefix}__data-entry {
140
+ max-width: none;
141
+ min-width: 0;
142
+ width: 100%;
143
+ }
144
+
138
145
  @include _apply-filter-align(stretch);
139
146
 
140
147
  @each $span, $value in $filter-span-configs {
@@ -64,6 +64,23 @@ $form-field-counter-colors: (
64
64
  .#{$prefix}__label-area {
65
65
  padding-top: spacing.semantic-variable(padding, vertical, calm);
66
66
  padding-bottom: spacing.semantic-variable(padding, vertical, calm);
67
+ box-sizing: border-box;
68
+ display: flex;
69
+ align-items: center;
70
+
71
+ &--horizontal-main {
72
+ padding-top: spacing.semantic-variable(padding, vertical, calm);
73
+ min-height: spacing.semantic-variable(size, container, micro);
74
+ }
75
+
76
+ &--horizontal-sub {
77
+ padding-top: spacing.semantic-variable(padding, vertical, tight);
78
+ min-height: spacing.semantic-variable(size, container, atomic);
79
+ }
80
+
81
+ &--vertical {
82
+ padding-top: spacing.semantic-variable(padding, vertical, tiny);
83
+ }
67
84
  }
68
85
 
69
86
  @each $size in $form-field-sizes {
@@ -174,6 +191,16 @@ $form-field-counter-colors: (
174
191
  gap: spacing.semantic-variable(gap, slim);
175
192
  }
176
193
 
194
+ .#{$prefix}__control-field-slot {
195
+ &--main {
196
+ min-height: spacing.semantic-variable(size, container, micro);
197
+ }
198
+
199
+ &--sub {
200
+ min-height: spacing.semantic-variable(size, container, atomic);
201
+ }
202
+ }
203
+
177
204
  .#{$prefix}__hint-text-and-counter-area {
178
205
  display: flex;
179
206
  flex-flow: row nowrap;