@aurodesignsystem-dev/auro-formkit 0.0.0-pr1489.0 → 0.0.0-pr1489.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/components/checkbox/demo/customize.min.js +249 -125
- package/components/checkbox/demo/getting-started.min.js +249 -125
- package/components/checkbox/demo/index.min.js +249 -125
- package/components/checkbox/demo/styles.min.css +1 -1
- package/components/checkbox/dist/index.js +249 -125
- package/components/checkbox/dist/registered.js +249 -125
- package/components/combobox/demo/customize.min.js +523 -259
- package/components/combobox/demo/getting-started.min.js +523 -259
- package/components/combobox/demo/index.min.js +523 -259
- package/components/combobox/demo/styles.min.css +1 -1
- package/components/combobox/dist/index.js +523 -259
- package/components/combobox/dist/registered.js +523 -259
- package/components/counter/demo/customize.min.js +271 -131
- package/components/counter/demo/index.min.js +271 -131
- package/components/counter/demo/styles.min.css +1 -1
- package/components/counter/dist/index.js +249 -125
- package/components/counter/dist/registered.js +249 -125
- package/components/datepicker/demo/accessibility.md +12 -9
- package/components/datepicker/demo/api.md +1 -1
- package/components/datepicker/demo/customize.md +4 -0
- package/components/datepicker/demo/customize.min.js +1638 -654
- package/components/datepicker/demo/index.md +35 -5
- package/components/datepicker/demo/index.min.js +1654 -659
- package/components/datepicker/demo/keyboard-behavior.md +16 -16
- package/components/datepicker/demo/styles.min.css +1 -1
- package/components/datepicker/demo/voiceover.md +5 -3
- package/components/datepicker/demo/why-datepicker.md +2 -2
- package/components/datepicker/dist/index.js +1642 -658
- package/components/datepicker/dist/registered.js +1642 -658
- package/components/datepicker/dist/src/auro-calendar-cell.d.ts +52 -17
- package/components/datepicker/dist/src/auro-calendar-month.d.ts +12 -4
- package/components/datepicker/dist/src/auro-calendar.d.ts +161 -8
- package/components/datepicker/dist/src/auro-datepicker.d.ts +77 -79
- package/components/dropdown/demo/customize.min.js +22 -6
- package/components/dropdown/demo/getting-started.min.js +22 -6
- package/components/dropdown/demo/index.min.js +22 -6
- package/components/dropdown/demo/styles.min.css +1 -1
- package/components/dropdown/dist/auro-dropdown.d.ts +3 -2
- package/components/dropdown/dist/index.js +22 -6
- package/components/dropdown/dist/registered.js +22 -6
- package/components/form/demo/customize.min.js +3461 -1561
- package/components/form/demo/getting-started.min.js +3461 -1561
- package/components/form/demo/index.min.js +3461 -1561
- package/components/form/demo/registerDemoDeps.min.js +3461 -1561
- package/components/form/demo/styles.min.css +1 -1
- package/components/input/demo/customize.min.js +249 -125
- package/components/input/demo/getting-started.min.js +249 -125
- package/components/input/demo/index.min.js +249 -125
- package/components/input/demo/styles.min.css +1 -1
- package/components/input/dist/index.js +249 -125
- package/components/input/dist/registered.js +249 -125
- package/components/menu/demo/styles.min.css +1 -1
- package/components/radio/demo/customize.min.js +249 -125
- package/components/radio/demo/getting-started.min.js +249 -125
- package/components/radio/demo/index.min.js +249 -125
- package/components/radio/demo/styles.min.css +1 -1
- package/components/radio/dist/index.js +249 -125
- package/components/radio/dist/registered.js +249 -125
- package/components/select/demo/customize.min.js +271 -131
- package/components/select/demo/getting-started.min.js +271 -131
- package/components/select/demo/index.min.js +271 -131
- package/components/select/demo/styles.min.css +1 -1
- package/components/select/dist/index.js +271 -131
- package/components/select/dist/registered.js +271 -131
- package/custom-elements.json +1936 -1614
- package/package.json +8 -8
|
@@ -25,109 +25,236 @@ const t$2={ATTRIBUTE:1,CHILD:2},e$5=t=>(...e)=>({_$litDirective$:t,values:e});le
|
|
|
25
25
|
* SPDX-License-Identifier: BSD-3-Clause
|
|
26
26
|
*/const e$4=e$5(class extends i$4{constructor(t){if(super(t),t.type!==t$2.ATTRIBUTE||"class"!==t.name||t.strings?.length>2)throw Error("`classMap()` can only be used in the `class` attribute and must be the only part in the attribute.")}render(t){return " "+Object.keys(t).filter(s=>t[s]).join(" ")+" "}update(s,[i]){if(void 0===this.st){this.st=new Set,void 0!==s.strings&&(this.nt=new Set(s.strings.join(" ").split(/\s/).filter(t=>""!==t)));for(const t in i)i[t]&&!this.nt?.has(t)&&this.st.add(t);return this.render(i)}const r=s.element.classList;for(const t of this.st)t in i||(r.remove(t),this.st.delete(t));for(const t in i){const s=!!i[t];s===this.st.has(t)||this.nt?.has(t)||(s?(r.add(t),this.st.add(t)):(r.remove(t),this.st.delete(t)));}return E$1}});
|
|
27
27
|
|
|
28
|
-
|
|
28
|
+
/**
|
|
29
|
+
* @description Splits a date string into its parts according to the provided format. Does NOT validate that the result is a real calendar date — use `parseDate` when validation is required.
|
|
30
|
+
* @param {string} dateStr - Date string to parse.
|
|
31
|
+
* @param {string} format - Date format to parse.
|
|
32
|
+
* @returns {{ month?: string, day?: string, year?: string }|undefined}
|
|
33
|
+
*/
|
|
34
|
+
function getDateParts$1(dateStr, format) {
|
|
35
|
+
if (!dateStr) {
|
|
36
|
+
return undefined;
|
|
37
|
+
}
|
|
29
38
|
|
|
30
|
-
|
|
39
|
+
const formatSeparatorMatch = format.match(/[/.-]/);
|
|
40
|
+
let valueParts;
|
|
41
|
+
let formatParts;
|
|
31
42
|
|
|
32
|
-
|
|
33
|
-
|
|
34
|
-
|
|
35
|
-
|
|
36
|
-
|
|
37
|
-
|
|
38
|
-
|
|
43
|
+
if (formatSeparatorMatch) {
|
|
44
|
+
const separator = formatSeparatorMatch[0];
|
|
45
|
+
valueParts = dateStr.split(separator);
|
|
46
|
+
formatParts = format.split(separator);
|
|
47
|
+
} else {
|
|
48
|
+
if (dateStr.match(/[/.-]/)) {
|
|
49
|
+
throw new Error(
|
|
50
|
+
"AuroDatepickerUtilities | parseDate: Date string has no separators",
|
|
51
|
+
);
|
|
52
|
+
}
|
|
39
53
|
|
|
40
|
-
|
|
41
|
-
|
|
42
|
-
|
|
43
|
-
|
|
54
|
+
if (dateStr.length !== format.length) {
|
|
55
|
+
throw new Error(
|
|
56
|
+
"AuroDatepickerUtilities | parseDate: Date string and format length do not match",
|
|
57
|
+
);
|
|
58
|
+
}
|
|
44
59
|
|
|
45
|
-
|
|
46
|
-
|
|
60
|
+
valueParts = [dateStr];
|
|
61
|
+
formatParts = [format];
|
|
62
|
+
}
|
|
47
63
|
|
|
48
|
-
|
|
49
|
-
|
|
50
|
-
|
|
64
|
+
if (valueParts.length !== formatParts.length) {
|
|
65
|
+
throw new Error(
|
|
66
|
+
`AuroDatepickerUtilities | parseDate: Date string and format do not match : ${dateStr} vs ${format}`,
|
|
67
|
+
);
|
|
68
|
+
}
|
|
51
69
|
|
|
52
|
-
|
|
53
|
-
|
|
54
|
-
throw new Error('AuroDatepickerUtilities | parseDate: Date string and format length do not match');
|
|
55
|
-
}
|
|
70
|
+
const result = formatParts.reduce((acc, part, index) => {
|
|
71
|
+
const value = valueParts[index];
|
|
56
72
|
|
|
57
|
-
|
|
58
|
-
|
|
59
|
-
|
|
73
|
+
if (/m/iu.test(part) && part.length === value.length) {
|
|
74
|
+
acc.month = value;
|
|
75
|
+
} else if (/d/iu.test(part) && part.length === value.length) {
|
|
76
|
+
acc.day = value;
|
|
77
|
+
} else if (/y/iu.test(part) && part.length === value.length) {
|
|
78
|
+
acc.year = value;
|
|
79
|
+
}
|
|
60
80
|
|
|
61
|
-
|
|
62
|
-
|
|
63
|
-
} else if ((/d/iu).test(part)) {
|
|
64
|
-
acc.day = value;
|
|
65
|
-
} else if ((/y/iu).test(part)) {
|
|
66
|
-
acc.year = value;
|
|
67
|
-
}
|
|
81
|
+
return acc;
|
|
82
|
+
}, {});
|
|
68
83
|
|
|
69
|
-
|
|
70
|
-
|
|
84
|
+
if (!result.month && !result.day && !result.year) {
|
|
85
|
+
throw new Error(
|
|
86
|
+
"AuroDatepickerUtilities | parseDate: Unable to parse date string",
|
|
87
|
+
);
|
|
88
|
+
}
|
|
71
89
|
|
|
72
|
-
|
|
73
|
-
|
|
74
|
-
return result;
|
|
75
|
-
}
|
|
90
|
+
return result;
|
|
91
|
+
}
|
|
76
92
|
|
|
77
|
-
|
|
78
|
-
|
|
79
|
-
|
|
93
|
+
function isCalendarDate$1(year, month, day) {
|
|
94
|
+
let yearNumber = Number(year);
|
|
95
|
+
const monthNumber = Number(month);
|
|
96
|
+
const dayNumber = Number(day);
|
|
80
97
|
|
|
81
|
-
|
|
82
|
-
|
|
83
|
-
|
|
84
|
-
|
|
85
|
-
|
|
86
|
-
|
|
87
|
-
|
|
88
|
-
year: "numeric",
|
|
89
|
-
month: "2-digit",
|
|
90
|
-
day: "2-digit",
|
|
91
|
-
});
|
|
98
|
+
if (
|
|
99
|
+
!Number.isInteger(yearNumber) ||
|
|
100
|
+
!Number.isInteger(monthNumber) ||
|
|
101
|
+
!Number.isInteger(dayNumber)
|
|
102
|
+
) {
|
|
103
|
+
return false;
|
|
104
|
+
}
|
|
92
105
|
|
|
93
|
-
|
|
94
|
-
|
|
95
|
-
|
|
96
|
-
|
|
97
|
-
|
|
98
|
-
|
|
99
|
-
this.toNorthAmericanFormat = (dateStr, format) => {
|
|
106
|
+
// Handle 2-digit years by converting them to 4-digit years based on a cutoff. This allows for parsing of 2-digit year formats while still validating the resulting date.
|
|
107
|
+
if (yearNumber < 100 && yearNumber >= 50) {
|
|
108
|
+
yearNumber += 1900;
|
|
109
|
+
} else if (yearNumber < 50) {
|
|
110
|
+
yearNumber += 2000;
|
|
111
|
+
}
|
|
100
112
|
|
|
101
|
-
|
|
102
|
-
|
|
103
|
-
}
|
|
113
|
+
const stringified = `${String(yearNumber).padStart(4, "0")}-${String(monthNumber).padStart(2, "0")}-${String(dayNumber).padStart(2, "0")}`;
|
|
114
|
+
const date = new Date(stringified.replace(/[.-]/g, "/"));
|
|
104
115
|
|
|
105
|
-
|
|
116
|
+
return (
|
|
117
|
+
!Number.isNaN(date.getTime()) && toISOFormatString$1(date) === stringified
|
|
118
|
+
);
|
|
119
|
+
}
|
|
106
120
|
|
|
107
|
-
|
|
108
|
-
|
|
109
|
-
|
|
121
|
+
/**
|
|
122
|
+
* @description Parses a date string into its components and validates that the result is a real calendar date. Use `getDateParts` instead when raw splitting without validation is needed (e.g. for in-progress input).
|
|
123
|
+
*
|
|
124
|
+
* Partial formats are supported: components absent from `format` default to `year → "0"`,
|
|
125
|
+
* `month → "01"`, `day → "01"` for calendar validation only. The returned object contains
|
|
126
|
+
* only the fields actually present in the format string — missing fields are never injected.
|
|
127
|
+
* @param {string} dateStr - Date string to parse.
|
|
128
|
+
* @param {string} format - Date format to parse.
|
|
129
|
+
* @returns {{ month?: string, day?: string, year?: string }|undefined}
|
|
130
|
+
* @throws {Error} Throws when the parsed result does not represent a valid calendar date.
|
|
131
|
+
*/
|
|
132
|
+
function parseDate$1(dateStr, format = "mm/dd/yyyy") {
|
|
133
|
+
if (!dateStr || !format) {
|
|
134
|
+
return undefined;
|
|
135
|
+
}
|
|
136
|
+
const result = getDateParts$1(dateStr.trim(), format);
|
|
110
137
|
|
|
111
|
-
|
|
138
|
+
if (!result) {
|
|
139
|
+
return undefined;
|
|
140
|
+
}
|
|
112
141
|
|
|
113
|
-
|
|
114
|
-
|
|
115
|
-
|
|
116
|
-
|
|
142
|
+
const lowerFormat = format.toLowerCase();
|
|
143
|
+
const year = lowerFormat.includes("yy") ? result.year : "0";
|
|
144
|
+
const month = lowerFormat.includes("mm") ? result.month : "01";
|
|
145
|
+
const day = lowerFormat.includes("dd") ? result.day : "01";
|
|
117
146
|
|
|
118
|
-
|
|
119
|
-
|
|
120
|
-
|
|
147
|
+
if (isCalendarDate$1(year, month, day)) {
|
|
148
|
+
return result;
|
|
149
|
+
}
|
|
121
150
|
|
|
122
|
-
|
|
123
|
-
|
|
124
|
-
|
|
151
|
+
throw new Error(
|
|
152
|
+
`AuroDatepickerUtilities | parseDate: Date string is not a valid date ${JSON.stringify(result)} with format ${format}`,
|
|
153
|
+
);
|
|
154
|
+
}
|
|
125
155
|
|
|
126
|
-
|
|
127
|
-
|
|
156
|
+
/**
|
|
157
|
+
* Convert a date object to string format.
|
|
158
|
+
* @param {Object} date - Date to convert to string.
|
|
159
|
+
* @param {String} locale - Optional locale to use for the date string. Defaults to user's locale.
|
|
160
|
+
* @returns {String} Returns the date as a string.
|
|
161
|
+
*/
|
|
162
|
+
function getDateAsString$1(date, locale = undefined) {
|
|
163
|
+
return date.toLocaleDateString(locale, {
|
|
164
|
+
year: "numeric",
|
|
165
|
+
month: "2-digit",
|
|
166
|
+
day: "2-digit",
|
|
167
|
+
});
|
|
168
|
+
}
|
|
169
|
+
|
|
170
|
+
/**
|
|
171
|
+
* Converts a date string to a North American date format.
|
|
172
|
+
* @param {String} dateStr - Date to validate.
|
|
173
|
+
* @param {String} format - Date format to validate against.
|
|
174
|
+
* @returns {String}
|
|
175
|
+
*/
|
|
176
|
+
function toNorthAmericanFormat$3(dateStr, format) {
|
|
177
|
+
if (format === "mm/dd/yyyy") {
|
|
178
|
+
return dateStr;
|
|
179
|
+
}
|
|
180
|
+
|
|
181
|
+
const parsedDate = parseDate$1(dateStr, format);
|
|
182
|
+
|
|
183
|
+
if (!parsedDate) {
|
|
184
|
+
throw new Error(
|
|
185
|
+
"AuroDatepickerUtilities | toNorthAmericanFormat: Unable to parse date string",
|
|
186
|
+
);
|
|
187
|
+
}
|
|
188
|
+
|
|
189
|
+
const { month, day, year } = parsedDate;
|
|
190
|
+
|
|
191
|
+
return [month, day, year].filter(Boolean).join("/");
|
|
192
|
+
}
|
|
193
|
+
|
|
194
|
+
/**
|
|
195
|
+
* Validates that a date string matches the provided format and represents a real calendar date.
|
|
196
|
+
*
|
|
197
|
+
* @param {string} dateStr - Date string to validate.
|
|
198
|
+
* @param {string} [format="yyyy-mm-dd"] - Format of the date string.
|
|
199
|
+
* @returns {boolean} True when the date string is valid for the provided format, otherwise false.
|
|
200
|
+
*/
|
|
201
|
+
function isValidDate$1(dateStr, format = "yyyy-mm-dd") {
|
|
202
|
+
try {
|
|
203
|
+
if (typeof dateStr !== "string" || !dateStr || format?.length < 8) {
|
|
204
|
+
return false;
|
|
205
|
+
}
|
|
206
|
+
|
|
207
|
+
if (parseDate$1(dateStr, format)) {
|
|
208
|
+
return true;
|
|
209
|
+
}
|
|
210
|
+
} catch (error) {
|
|
211
|
+
return false;
|
|
212
|
+
}
|
|
213
|
+
return false;
|
|
214
|
+
}
|
|
215
|
+
|
|
216
|
+
/**
|
|
217
|
+
* Converts a JavaScript Date instance to a simple ISO-like date string. This returns only the calendar date portion without any time or timezone information.
|
|
218
|
+
*
|
|
219
|
+
* @param {Date} date - Date instance to convert to an ISO-like string.
|
|
220
|
+
* @returns {string} A string in the format "yyyy-mm-dd" representing the provided date.
|
|
221
|
+
* @throws {Error} Throws an error when the input is not a valid Date instance.
|
|
222
|
+
*/
|
|
223
|
+
function toISOFormatString$1(date) {
|
|
224
|
+
if (!(date instanceof Date) || Number.isNaN(date.getTime())) {
|
|
225
|
+
throw new Error(
|
|
226
|
+
"AuroDatepickerUtilities | toISOFormatString: Input must be a valid Date instance",
|
|
227
|
+
);
|
|
228
|
+
}
|
|
229
|
+
return `${String(date.getFullYear()).padStart(4, "0")}-${String(date.getMonth() + 1).padStart(2, "0")}-${String(date.getDate()).padStart(2, "0")}`;
|
|
230
|
+
}
|
|
231
|
+
|
|
232
|
+
/**
|
|
233
|
+
* Converts a date string into a JavaScript Date instance. This method supports ISO formatted strings and other formats that can be parsed by the formatter.
|
|
234
|
+
*
|
|
235
|
+
* @param {String} dateStr - Date string to convert into a Date object.
|
|
236
|
+
* @param {String} format - Date format used to parse the string when it is not in ISO format.
|
|
237
|
+
* @returns {Date|null} Returns a Date instance for valid input or null for non-string input.
|
|
238
|
+
* @throws {Error} Throws when parsing fails for non-ISO string input.
|
|
239
|
+
*/
|
|
240
|
+
function stringToDateInstance$1(dateStr, format = "yyyy-mm-dd") {
|
|
241
|
+
if (typeof dateStr !== "string") {
|
|
242
|
+
return null;
|
|
128
243
|
}
|
|
244
|
+
|
|
245
|
+
const { month, day, year } = parseDate$1(dateStr, format);
|
|
246
|
+
return new Date(`${year}/${month}/${day}`);
|
|
247
|
+
}
|
|
248
|
+
|
|
249
|
+
const dateFormatter$1 = {
|
|
250
|
+
parseDate: parseDate$1,
|
|
251
|
+
getDateParts: getDateParts$1,
|
|
252
|
+
getDateAsString: getDateAsString$1,
|
|
253
|
+
toNorthAmericanFormat: toNorthAmericanFormat$3,
|
|
254
|
+
isValidDate: isValidDate$1,
|
|
255
|
+
toISOFormatString: toISOFormatString$1,
|
|
256
|
+
stringToDateInstance: stringToDateInstance$1,
|
|
129
257
|
};
|
|
130
|
-
const dateFormatter$1 = new DateFormatter$1();
|
|
131
258
|
|
|
132
259
|
// filepath: dateConstraints.mjs
|
|
133
260
|
const DATE_UTIL_CONSTRAINTS$1 = {
|
|
@@ -199,12 +326,11 @@ let AuroDateUtilitiesBase$1 = class AuroDateUtilitiesBase {
|
|
|
199
326
|
/* eslint-disable no-magic-numbers */
|
|
200
327
|
|
|
201
328
|
let AuroDateUtilities$1 = class AuroDateUtilities extends AuroDateUtilitiesBase$1 {
|
|
202
|
-
|
|
203
329
|
/**
|
|
204
330
|
* Returns the current century.
|
|
205
331
|
* @returns {String} The current century.
|
|
206
332
|
*/
|
|
207
|
-
getCentury
|
|
333
|
+
getCentury() {
|
|
208
334
|
return String(new Date().getFullYear()).slice(0, 2);
|
|
209
335
|
}
|
|
210
336
|
|
|
@@ -213,14 +339,12 @@ let AuroDateUtilities$1 = class AuroDateUtilities extends AuroDateUtilitiesBase$
|
|
|
213
339
|
* @param {String} year - The year to convert to four digits.
|
|
214
340
|
* @returns {String} The four digit year.
|
|
215
341
|
*/
|
|
216
|
-
getFourDigitYear
|
|
217
|
-
|
|
342
|
+
getFourDigitYear(year) {
|
|
218
343
|
const strYear = String(year).trim();
|
|
219
344
|
return strYear.length <= 2 ? this.getCentury() + strYear : strYear;
|
|
220
345
|
}
|
|
221
346
|
|
|
222
347
|
constructor() {
|
|
223
|
-
|
|
224
348
|
super();
|
|
225
349
|
|
|
226
350
|
/**
|
|
@@ -229,7 +353,8 @@ let AuroDateUtilities$1 = class AuroDateUtilities extends AuroDateUtilitiesBase$
|
|
|
229
353
|
* @param {Object} date2 - Second date to compare.
|
|
230
354
|
* @returns {Boolean} Returns true if the dates match.
|
|
231
355
|
*/
|
|
232
|
-
this.datesMatch = (date1, date2) =>
|
|
356
|
+
this.datesMatch = (date1, date2) =>
|
|
357
|
+
new Date(date1).getTime() === new Date(date2).getTime();
|
|
233
358
|
|
|
234
359
|
/**
|
|
235
360
|
* Returns true if value passed in is a valid date.
|
|
@@ -238,53 +363,41 @@ let AuroDateUtilities$1 = class AuroDateUtilities extends AuroDateUtilitiesBase$
|
|
|
238
363
|
* @returns {Boolean}
|
|
239
364
|
*/
|
|
240
365
|
this.validDateStr = (date, format) => {
|
|
241
|
-
|
|
242
366
|
// The length we expect the date string to be
|
|
243
|
-
const dateStrLength = format
|
|
367
|
+
const dateStrLength = format?.length || 0;
|
|
244
368
|
|
|
245
369
|
// Guard Clause: Date and format are defined
|
|
246
370
|
if (typeof date === "undefined" || typeof format === "undefined") {
|
|
247
|
-
throw new Error(
|
|
371
|
+
throw new Error(
|
|
372
|
+
"AuroDatepickerUtilities | validateDateStr: Date and format are required",
|
|
373
|
+
);
|
|
248
374
|
}
|
|
249
375
|
|
|
250
376
|
// Guard Clause: Date should be of type string
|
|
251
377
|
if (typeof date !== "string") {
|
|
252
|
-
throw new Error(
|
|
378
|
+
throw new Error(
|
|
379
|
+
"AuroDatepickerUtilities | validateDateStr: Date must be a string",
|
|
380
|
+
);
|
|
253
381
|
}
|
|
254
382
|
|
|
255
383
|
// Guard Clause: Format should be of type string
|
|
256
384
|
if (typeof format !== "string") {
|
|
257
|
-
throw new Error(
|
|
385
|
+
throw new Error(
|
|
386
|
+
"AuroDatepickerUtilities | validateDateStr: Format must be a string",
|
|
387
|
+
);
|
|
258
388
|
}
|
|
259
389
|
|
|
260
390
|
// Guard Clause: Length is what we expect it to be
|
|
261
391
|
if (date.length !== dateStrLength) {
|
|
262
392
|
return false;
|
|
263
393
|
}
|
|
264
|
-
// Get a formatted date string and parse it
|
|
265
|
-
const dateParts = dateFormatter$1.parseDate(date, format);
|
|
266
|
-
|
|
267
|
-
// Guard Clause: Date parse succeeded
|
|
268
|
-
if (!dateParts) {
|
|
269
|
-
return false;
|
|
270
|
-
}
|
|
271
|
-
|
|
272
|
-
// Create the expected date string based on the date parts
|
|
273
|
-
const expectedDateStr = `${dateParts.month}/${dateParts.day || "01"}/${this.getFourDigitYear(dateParts.year)}`;
|
|
274
|
-
|
|
275
|
-
// Generate a date object that we will extract a string date from to compare to the passed in date string
|
|
276
|
-
const dateObj = new Date(this.getFourDigitYear(dateParts.year), dateParts.month - 1, dateParts.day || 1);
|
|
277
|
-
|
|
278
|
-
// Get the date string of the date object we created from the string date
|
|
279
|
-
const actualDateStr = dateFormatter$1.getDateAsString(dateObj, "en-US");
|
|
280
394
|
|
|
281
|
-
//
|
|
282
|
-
|
|
395
|
+
// Get a formatted date string and parse and validate it
|
|
396
|
+
try {
|
|
397
|
+
return Boolean(dateFormatter$1.parseDate(date, format));
|
|
398
|
+
} catch (error) {
|
|
283
399
|
return false;
|
|
284
400
|
}
|
|
285
|
-
|
|
286
|
-
// If we passed all other checks, we can assume the date is valid
|
|
287
|
-
return true;
|
|
288
401
|
};
|
|
289
402
|
|
|
290
403
|
/**
|
|
@@ -294,10 +407,11 @@ let AuroDateUtilities$1 = class AuroDateUtilities extends AuroDateUtilitiesBase$
|
|
|
294
407
|
* @returns {boolean}
|
|
295
408
|
*/
|
|
296
409
|
this.dateAndFormatMatch = (value, format) => {
|
|
297
|
-
|
|
298
410
|
// Ensure we have both values we need to do the comparison
|
|
299
411
|
if (!value || !format) {
|
|
300
|
-
throw new Error(
|
|
412
|
+
throw new Error(
|
|
413
|
+
"AuroFormValidation | dateFormatMatch: value and format are required",
|
|
414
|
+
);
|
|
301
415
|
}
|
|
302
416
|
|
|
303
417
|
// If the lengths are different, they cannot match
|
|
@@ -306,11 +420,10 @@ let AuroDateUtilities$1 = class AuroDateUtilities extends AuroDateUtilitiesBase$
|
|
|
306
420
|
}
|
|
307
421
|
|
|
308
422
|
// Get the parts of the date
|
|
309
|
-
const dateParts = dateFormatter$1.
|
|
423
|
+
const dateParts = dateFormatter$1.getDateParts(value, format);
|
|
310
424
|
|
|
311
425
|
// Validator for day
|
|
312
426
|
const dayValueIsValid = (day) => {
|
|
313
|
-
|
|
314
427
|
// Guard clause: if there is no day in the dateParts, we can ignore this check.
|
|
315
428
|
if (!dateParts.day) {
|
|
316
429
|
return true;
|
|
@@ -326,7 +439,9 @@ let AuroDateUtilities$1 = class AuroDateUtilities extends AuroDateUtilitiesBase$
|
|
|
326
439
|
|
|
327
440
|
// Guard clause: ensure day is a valid integer
|
|
328
441
|
if (Number.isNaN(numDay)) {
|
|
329
|
-
throw new Error(
|
|
442
|
+
throw new Error(
|
|
443
|
+
"AuroDatepickerUtilities | dayValueIsValid: Unable to parse day value integer",
|
|
444
|
+
);
|
|
330
445
|
}
|
|
331
446
|
|
|
332
447
|
// Guard clause: ensure day is within the valid range
|
|
@@ -340,6 +455,10 @@ let AuroDateUtilities$1 = class AuroDateUtilities extends AuroDateUtilitiesBase$
|
|
|
340
455
|
|
|
341
456
|
// Validator for month
|
|
342
457
|
const monthValueIsValid = (month) => {
|
|
458
|
+
// Guard clause: if there is no month in the dateParts, we can ignore this check.
|
|
459
|
+
if (!dateParts.month) {
|
|
460
|
+
return true;
|
|
461
|
+
}
|
|
343
462
|
|
|
344
463
|
// Guard clause: ensure month exists.
|
|
345
464
|
if (!month) {
|
|
@@ -351,7 +470,9 @@ let AuroDateUtilities$1 = class AuroDateUtilities extends AuroDateUtilitiesBase$
|
|
|
351
470
|
|
|
352
471
|
// Guard clause: ensure month is a valid integer
|
|
353
472
|
if (Number.isNaN(numMonth)) {
|
|
354
|
-
throw new Error(
|
|
473
|
+
throw new Error(
|
|
474
|
+
"AuroDatepickerUtilities | monthValueIsValid: Unable to parse month value integer",
|
|
475
|
+
);
|
|
355
476
|
}
|
|
356
477
|
|
|
357
478
|
// Guard clause: ensure month is within the valid range
|
|
@@ -365,6 +486,10 @@ let AuroDateUtilities$1 = class AuroDateUtilities extends AuroDateUtilitiesBase$
|
|
|
365
486
|
|
|
366
487
|
// Validator for year
|
|
367
488
|
const yearIsValid = (_year) => {
|
|
489
|
+
// Guard clause: if there is no year in the dateParts, we can ignore this check.
|
|
490
|
+
if (!dateParts.year) {
|
|
491
|
+
return true;
|
|
492
|
+
}
|
|
368
493
|
|
|
369
494
|
// Guard clause: ensure year exists.
|
|
370
495
|
if (!_year) {
|
|
@@ -379,7 +504,9 @@ let AuroDateUtilities$1 = class AuroDateUtilities extends AuroDateUtilitiesBase$
|
|
|
379
504
|
|
|
380
505
|
// Guard clause: ensure year is a valid integer
|
|
381
506
|
if (Number.isNaN(numYear)) {
|
|
382
|
-
throw new Error(
|
|
507
|
+
throw new Error(
|
|
508
|
+
"AuroDatepickerUtilities | yearValueIsValid: Unable to parse year value integer",
|
|
509
|
+
);
|
|
383
510
|
}
|
|
384
511
|
|
|
385
512
|
// Guard clause: ensure year is within the valid range
|
|
@@ -395,7 +522,7 @@ let AuroDateUtilities$1 = class AuroDateUtilities extends AuroDateUtilitiesBase$
|
|
|
395
522
|
const checks = [
|
|
396
523
|
monthValueIsValid(dateParts.month),
|
|
397
524
|
dayValueIsValid(dateParts.day),
|
|
398
|
-
yearIsValid(dateParts.year)
|
|
525
|
+
yearIsValid(dateParts.year),
|
|
399
526
|
];
|
|
400
527
|
|
|
401
528
|
// If any of the checks failed, the date format does not match and the result is invalid
|
|
@@ -429,10 +556,7 @@ const {
|
|
|
429
556
|
} = dateUtilities$1;
|
|
430
557
|
|
|
431
558
|
const {
|
|
432
|
-
toNorthAmericanFormat: toNorthAmericanFormat$1
|
|
433
|
-
parseDate: parseDate$1,
|
|
434
|
-
getDateAsString: getDateAsString$1
|
|
435
|
-
} = dateFormatter$1;
|
|
559
|
+
toNorthAmericanFormat: toNorthAmericanFormat$2} = dateFormatter$1;
|
|
436
560
|
|
|
437
561
|
// Copyright (c) Alaska Air. All right reserved. Licensed under the Apache-2.0 license
|
|
438
562
|
// See LICENSE in the project root for license information.
|
|
@@ -752,13 +876,13 @@ let AuroFormValidation$1 = class AuroFormValidation {
|
|
|
752
876
|
}
|
|
753
877
|
|
|
754
878
|
// Perform the rest of the validation
|
|
755
|
-
const formattedValue = toNorthAmericanFormat$
|
|
879
|
+
const formattedValue = toNorthAmericanFormat$2(elem.value, elem.format);
|
|
756
880
|
const valueDate = new Date(formattedValue);
|
|
757
881
|
|
|
758
882
|
// // Validate max date
|
|
759
883
|
if (elem.max?.length === elem.lengthForType) {
|
|
760
884
|
|
|
761
|
-
const maxDate = new Date(toNorthAmericanFormat$
|
|
885
|
+
const maxDate = new Date(toNorthAmericanFormat$2(elem.max, elem.format));
|
|
762
886
|
|
|
763
887
|
if (valueDate > maxDate) {
|
|
764
888
|
elem.validity = 'rangeOverflow';
|
|
@@ -769,7 +893,7 @@ let AuroFormValidation$1 = class AuroFormValidation {
|
|
|
769
893
|
|
|
770
894
|
// Validate min date
|
|
771
895
|
if (elem.min?.length === elem.lengthForType) {
|
|
772
|
-
const minDate = new Date(toNorthAmericanFormat$
|
|
896
|
+
const minDate = new Date(toNorthAmericanFormat$2(elem.min, elem.format));
|
|
773
897
|
|
|
774
898
|
if (valueDate < minDate) {
|
|
775
899
|
elem.validity = 'rangeUnderflow';
|
|
@@ -1325,13 +1449,10 @@ class UtilitiesCalendarRender {
|
|
|
1325
1449
|
// 2. Start by assuming we can render the max number of months.
|
|
1326
1450
|
let calendarCount = maxRenderableMonths;
|
|
1327
1451
|
|
|
1328
|
-
// 3. If
|
|
1452
|
+
// 3. If maximumRenderableMonths() returns 0 (e.g. an invalid/empty defined range),
|
|
1453
|
+
// fall back to the min/max date range so something is rendered.
|
|
1329
1454
|
if (!calendarCount && elem.minDate && elem.maxDate) {
|
|
1330
|
-
|
|
1331
|
-
|
|
1332
|
-
if (monthsInRange < maxRenderableMonths) {
|
|
1333
|
-
calendarCount = monthsInRange;
|
|
1334
|
-
}
|
|
1455
|
+
calendarCount = this.util.monthDiff(new Date(elem.minDate), new Date(elem.maxDate));
|
|
1335
1456
|
}
|
|
1336
1457
|
|
|
1337
1458
|
if (elem.numCalendars !== calendarCount) {
|
|
@@ -1379,7 +1500,6 @@ class UtilitiesCalendarRender {
|
|
|
1379
1500
|
.max="${elem.max}"
|
|
1380
1501
|
?noRange="${elem.noRange}"
|
|
1381
1502
|
.monthFirst="${elem.monthFirst}"
|
|
1382
|
-
.hoveredDate="${elem.hoveredDate}"
|
|
1383
1503
|
.dateTo="${elem.dateTo}"
|
|
1384
1504
|
.dateFrom="${elem.dateFrom}"
|
|
1385
1505
|
.locale="${elem.locale}"
|
|
@@ -1411,49 +1531,6 @@ var snowflakeStyle = i$3`:host([layout*=snowflake]) [auro-input]{flex:1;text-ali
|
|
|
1411
1531
|
|
|
1412
1532
|
var snowflakeColors = i$3`:host([layout=snowflake]) [auro-dropdown]:not(:is([error],.hasFocus)){--ds-auro-dropdown-trigger-border-color: transparent}`;
|
|
1413
1533
|
|
|
1414
|
-
var styleCss$7 = i$3`.body-default{font-family:var(--wcss-body-family, "AS Circular"),system-ui,-apple-system,BlinkMacSystemFont,"Segoe UI",Roboto,"Helvetica Neue",Arial,sans-serif;font-weight:var(--wcss-body-default-weight, );letter-spacing:var(--wcss-body-letter-spacing, 0);font-size:var(--wcss-body-default-font-size, 1rem);line-height:var(--wcss-body-default-line-height, 1.5rem)}.body-default-emphasized{font-family:var(--wcss-body-family, "AS Circular"),system-ui,-apple-system,BlinkMacSystemFont,"Segoe UI",Roboto,"Helvetica Neue",Arial,sans-serif;font-weight:var(--wcss-body-default-emphasized-weight, );letter-spacing:var(--wcss-body-letter-spacing, 0);font-size:var(--wcss-body-default-emphasized-font-size, 1rem);line-height:var(--wcss-body-default-emphasized-line-height, 1.5rem)}.body-lg{font-family:var(--wcss-body-family, "AS Circular"),system-ui,-apple-system,BlinkMacSystemFont,"Segoe UI",Roboto,"Helvetica Neue",Arial,sans-serif;font-weight:var(--wcss-body-lg-weight, );letter-spacing:var(--wcss-body-letter-spacing, 0);font-size:var(--wcss-body-lg-font-size, 1.125rem);line-height:var(--wcss-body-lg-line-height, 1.625rem)}.body-lg-emphasized{font-family:var(--wcss-body-family, "AS Circular"),system-ui,-apple-system,BlinkMacSystemFont,"Segoe UI",Roboto,"Helvetica Neue",Arial,sans-serif;font-weight:var(--wcss-body-lg-emphasized-weight, );letter-spacing:var(--wcss-body-letter-spacing, 0);font-size:var(--wcss-body-lg-emphasized-font-size, 1.125rem);line-height:var(--wcss-body-lg-emphasized-line-height, 1.625rem)}.body-sm{font-family:var(--wcss-body-family, "AS Circular"),system-ui,-apple-system,BlinkMacSystemFont,"Segoe UI",Roboto,"Helvetica Neue",Arial,sans-serif;font-weight:var(--wcss-body-sm-weight, );letter-spacing:var(--wcss-body-letter-spacing, 0);font-size:var(--wcss-body-sm-font-size, 0.875rem);line-height:var(--wcss-body-sm-line-height, 1.25rem)}.body-sm-emphasized{font-family:var(--wcss-body-family, "AS Circular"),system-ui,-apple-system,BlinkMacSystemFont,"Segoe UI",Roboto,"Helvetica Neue",Arial,sans-serif;font-weight:var(--wcss-body-sm-emphasized-weight, );letter-spacing:var(--wcss-body-letter-spacing, 0);font-size:var(--wcss-body-sm-emphasized-font-size, 0.875rem);line-height:var(--wcss-body-sm-emphasized-line-height, 1.25rem)}.body-xs{font-family:var(--wcss-body-family, "AS Circular"),system-ui,-apple-system,BlinkMacSystemFont,"Segoe UI",Roboto,"Helvetica Neue",Arial,sans-serif;font-weight:var(--wcss-body-xs-weight, );letter-spacing:var(--wcss-body-letter-spacing, 0);font-size:var(--wcss-body-xs-font-size, 0.75rem);line-height:var(--wcss-body-xs-line-height, 1rem)}.body-xs-emphasized{font-family:var(--wcss-body-family, "AS Circular"),system-ui,-apple-system,BlinkMacSystemFont,"Segoe UI",Roboto,"Helvetica Neue",Arial,sans-serif;font-weight:var(--wcss-body-xs-emphasized-weight, );letter-spacing:var(--wcss-body-letter-spacing, 0);font-size:var(--wcss-body-xs-emphasized-font-size, 0.75rem);line-height:var(--wcss-body-xs-emphasized-line-height, 1rem)}.body-2xs{font-family:var(--wcss-body-family, "AS Circular"),system-ui,-apple-system,BlinkMacSystemFont,"Segoe UI",Roboto,"Helvetica Neue",Arial,sans-serif;font-weight:var(--wcss-body-2xs-weight, );letter-spacing:var(--wcss-body-letter-spacing, 0);font-size:var(--wcss-body-2xs-font-size, 0.625rem);line-height:var(--wcss-body-2xs-line-height, 0.875rem)}.body-2xs-emphasized{font-family:var(--wcss-body-family, "AS Circular"),system-ui,-apple-system,BlinkMacSystemFont,"Segoe UI",Roboto,"Helvetica Neue",Arial,sans-serif;font-weight:var(--wcss-body-2xs-emphasized-weight, );letter-spacing:var(--wcss-body-letter-spacing, 0);font-size:var(--wcss-body-2xs-emphasized-font-size, 0.625rem);line-height:var(--wcss-body-2xs-emphasized-line-height, 0.875rem)}.display-2xl{font-family:var(--wcss-display-2xl-family, "AS Circular"),var(--wcss-display-2xl-family-fallback, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif);font-weight:var(--wcss-display-2xl-weight, 300);line-height:var(--wcss-display-2xl-line-height, 1.3);font-size:var(--wcss-display-2xl-font-size, clamp(3.5rem, 6vw, 5.375rem));letter-spacing:var(--wcss-display-2xl-letter-spacing, 0)}.display-xl{font-family:var(--wcss-display-xl-family, "AS Circular"),var(--wcss-display-xl-family-fallback, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif);font-weight:var(--wcss-display-xl-weight, 300);line-height:var(--wcss-display-xl-line-height, 1.3);font-size:var(--wcss-display-xl-font-size, clamp(3rem, 5.3333333333vw, 4.5rem));letter-spacing:var(--wcss-display-xl-letter-spacing, 0)}.display-lg{font-family:var(--wcss-display-lg-family, "AS Circular"),var(--wcss-display-lg-family-fallback, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif);font-weight:var(--wcss-display-lg-weight, 300);line-height:var(--wcss-display-lg-line-height, 1.3);font-size:var(--wcss-display-lg-font-size, clamp(2.75rem, 4.6666666667vw, 4rem));letter-spacing:var(--wcss-display-lg-letter-spacing, 0)}.display-md{font-family:var(--wcss-display-md-family, "AS Circular"),var(--wcss-display-md-family-fallback, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif);font-weight:var(--wcss-display-md-weight, 300);line-height:var(--wcss-display-md-line-height, 1.3);font-size:var(--wcss-display-md-font-size, clamp(2.5rem, 4vw, 3.5rem));letter-spacing:var(--wcss-display-md-letter-spacing, 0)}.display-sm{font-family:var(--wcss-display-sm-family, "AS Circular"),var(--wcss-display-sm-family-fallback, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif);font-weight:var(--wcss-display-sm-weight, 300);line-height:var(--wcss-display-sm-line-height, 1.3);font-size:var(--wcss-display-sm-font-size, clamp(2rem, 3.6666666667vw, 3rem));letter-spacing:var(--wcss-display-sm-letter-spacing, 0)}.display-xs{font-family:var(--wcss-display-xs-family, "AS Circular"),var(--wcss-display-xs-family-fallback, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif);font-weight:var(--wcss-display-xs-weight, 300);line-height:var(--wcss-display-xs-line-height, 1.3);font-size:var(--wcss-display-xs-font-size, clamp(1.75rem, 3vw, 2.375rem));letter-spacing:var(--wcss-display-xs-letter-spacing, 0)}.heading-xl{font-family:var(--wcss-heading-xl-family, "AS Circular"),var(--wcss-heading-xl-family-fallback, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif);font-weight:var(--wcss-heading-xl-weight, 300);line-height:var(--wcss-heading-xl-line-height, 1.3);font-size:var(--wcss-heading-xl-font-size, clamp(2rem, 3vw, 2.5rem));letter-spacing:var(--wcss-heading-xl-letter-spacing, 0)}.heading-lg{font-family:var(--wcss-heading-lg-family, "AS Circular"),var(--wcss-heading-lg-family-fallback, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif);font-weight:var(--wcss-heading-lg-weight, 300);line-height:var(--wcss-heading-lg-line-height, 1.3);font-size:var(--wcss-heading-lg-font-size, clamp(1.75rem, 2.6666666667vw, 2.25rem));letter-spacing:var(--wcss-heading-lg-letter-spacing, 0)}.heading-md{font-family:var(--wcss-heading-md-family, "AS Circular"),var(--wcss-heading-md-family-fallback, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif);font-weight:var(--wcss-heading-md-weight, 300);line-height:var(--wcss-heading-md-line-height, 1.3);font-size:var(--wcss-heading-md-font-size, clamp(1.625rem, 2.3333333333vw, 1.75rem));letter-spacing:var(--wcss-heading-md-letter-spacing, 0)}.heading-sm{font-family:var(--wcss-heading-sm-family, "AS Circular"),var(--wcss-heading-sm-family-fallback, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif);font-weight:var(--wcss-heading-sm-weight, 300);line-height:var(--wcss-heading-sm-line-height, 1.3);font-size:var(--wcss-heading-sm-font-size, clamp(1.375rem, 2vw, 1.5rem));letter-spacing:var(--wcss-heading-sm-letter-spacing, 0)}.heading-xs{font-family:var(--wcss-heading-xs-family, "AS Circular"),var(--wcss-heading-xs-family-fallback, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif);font-weight:var(--wcss-heading-xs-weight, 300);line-height:var(--wcss-heading-xs-line-height, 1.3);font-size:var(--wcss-heading-xs-font-size, clamp(1.25rem, 1.6666666667vw, 1.25rem));letter-spacing:var(--wcss-heading-xs-letter-spacing, 0)}.heading-2xs{font-family:var(--wcss-heading-2xs-family, "AS Circular"),var(--wcss-heading-2xs-family-fallback, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif);font-weight:var(--wcss-heading-2xs-weight, 300);line-height:var(--wcss-heading-2xs-line-height, 1.3);font-size:var(--wcss-heading-2xs-font-size, clamp(1.125rem, 1.5vw, 1.125rem));letter-spacing:var(--wcss-heading-2xs-letter-spacing, 0)}.accent-2xl{font-family:var(--wcss-accent-2xl-family, "Good OT"),var(--wcss-accent-2xl-family-fallback, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif);font-weight:var(--wcss-accent-2xl-weight, 450);line-height:var(--wcss-accent-2xl-line-height, 1);font-size:var(--wcss-accent-2xl-font-size, clamp(2rem, 3.1666666667vw, 2.375rem));letter-spacing:var(--wcss-accent-2xl-letter-spacing, 0.05em);text-transform:uppercase}.accent-xl{font-family:var(--wcss-accent-xl-family, "Good OT"),var(--wcss-accent-xl-family-fallback, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif);font-weight:var(--wcss-accent-xl-weight, 450);line-height:var(--wcss-accent-xl-line-height, 1.3);font-size:var(--wcss-accent-xl-font-size, clamp(1.625rem, 2.3333333333vw, 2rem));letter-spacing:var(--wcss-accent-xl-letter-spacing, 0.05em);text-transform:uppercase}.accent-lg{font-family:var(--wcss-accent-lg-family, "Good OT"),var(--wcss-accent-lg-family-fallback, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif);font-weight:var(--wcss-accent-lg-weight, 450);line-height:var(--wcss-accent-lg-line-height, 1.3);font-size:var(--wcss-accent-lg-font-size, clamp(1.5rem, 2.1666666667vw, 1.75rem));letter-spacing:var(--wcss-accent-lg-letter-spacing, 0.05em);text-transform:uppercase}.accent-md{font-family:var(--wcss-accent-md-family, "Good OT"),var(--wcss-accent-md-family-fallback, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif);font-weight:var(--wcss-accent-md-weight, 500);line-height:var(--wcss-accent-md-line-height, 1.3);font-size:var(--wcss-accent-md-font-size, clamp(1.375rem, 1.8333333333vw, 1.5rem));letter-spacing:var(--wcss-accent-md-letter-spacing, 0.05em);text-transform:uppercase}.accent-sm{font-family:var(--wcss-accent-sm-family, "Good OT"),var(--wcss-accent-sm-family-fallback, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif);font-weight:var(--wcss-accent-sm-weight, 500);line-height:var(--wcss-accent-sm-line-height, 1.3);font-size:var(--wcss-accent-sm-font-size, clamp(1.125rem, 1.5vw, 1.25rem));letter-spacing:var(--wcss-accent-sm-letter-spacing, 0.05em);text-transform:uppercase}.accent-xs{font-family:var(--wcss-accent-xs-family, "Good OT"),var(--wcss-accent-xs-family-fallback, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif);font-weight:var(--wcss-accent-xs-weight, 500);line-height:var(--wcss-accent-xs-line-height, 1.3);font-size:var(--wcss-accent-xs-font-size, clamp(1rem, 1.3333333333vw, 1rem));letter-spacing:var(--wcss-accent-xs-letter-spacing, 0.1em);text-transform:uppercase}.accent-2xs{font-family:var(--wcss-accent-2xs-family, "Good OT"),var(--wcss-accent-2xs-family-fallback, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif);font-weight:var(--wcss-accent-2xs-weight, 450);line-height:var(--wcss-accent-2xs-line-height, 1.3);font-size:var(--wcss-accent-2xs-font-size, clamp(0.875rem, 1.1666666667vw, 0.875rem));letter-spacing:var(--wcss-accent-2xs-letter-spacing, 0.1em);text-transform:uppercase}:host{--calendar-width: 336px;--mobile-footer-height: 150px;--mobile-header-height: 68px;--desktop-footer-height: 80px;height:100vh;height:100dvh}.calendars{display:flex;flex-direction:row}.calendarNavButtons{position:absolute;z-index:1;top:var(--ds-size-200, 1rem);right:var(--ds-size-50, 0.25rem);left:var(--ds-size-50, 0.25rem)}.calendarNavBtn{display:flex;width:var(--ds-size-500, 2.5rem);height:var(--ds-size-500, 2.5rem);align-items:center;justify-content:center;border-width:1px;border-style:solid;border-radius:50%;cursor:pointer}.prevMonth,.nextMonth{position:absolute;top:0}.prevMonth{left:0}.nextMonth{right:0}.headerActions{padding:0 var(--ds-size-200, 1rem)}.mobileHeader{width:100%;height:var(--mobile-header-height);z-index:1;align-items:center;flex-direction:row}.headerDateFrom,.headerDateTo{display:flex;height:var(--mobile-header-height);flex:1;flex-direction:column;justify-content:center;padding:0 var(--ds-size-150, 0.75rem) 0 var(--ds-size-200, 1rem)}.mobileDateLabel{padding:var(--ds-size-25, 0.125rem) 0}.mobileFooter{display:none;width:100%;align-items:flex-end;flex-direction:column;justify-content:flex-end}.mobileFooterActions{position:relative;bottom:0;left:50%;display:none;width:calc(100% - var(--ds-size-200, 1rem)*2);align-items:flex-end;flex-direction:column;justify-content:flex-end;padding:var(--ds-size-150) calc(var(--ds-size-200, 1rem));transform:translateX(-50%)}.mobileFooterActions auro-button{width:100%}.calendarWrapper.hasFooter{padding-bottom:var(--desktop-footer-height)}:host([isfullscreen]){width:100%;max-height:100dvh;overflow:hidden}:host([isfullscreen]) .prevMonth,:host([isfullscreen]) .nextMonth{display:none}:host([isfullscreen]) .mobileHeader,:host([isfullscreen]) .mobileFooter,:host([isfullscreen]) .mobileFooterActions{display:flex}:host([isfullscreen]) .calendarWrapper{display:flex;flex-direction:column}:host([isfullscreen]) .calendars{display:flex;flex-direction:column;flex:1;align-items:center;width:100%;overscroll-behavior:contain}:host([isfullscreen]) .calendars:after{display:block;width:100%;height:var(--mobile-footer-height);content:""}.sr-only{position:absolute;overflow:hidden;clip:rect(0, 0, 0, 0);width:1px;height:1px;margin:-1px;padding:0;border:0;white-space:nowrap}`;
|
|
1415
|
-
|
|
1416
|
-
var colorCss$7 = i$3`.calendarNavBtn{border-color:var(--ds-auro-calendar-nav-btn-border-color);background-color:var(--ds-auro-calendar-nav-btn-container-color);color:var(--ds-auro-calendar-nav-btn-chevron-color)}.calendarNavBtn:hover{--ds-auro-calendar-nav-btn-container-color: var(--ds-advanced-color-state-background-hover, #f2f2f2);--ds-auro-calendar-nav-btn-border-color: var(--ds-basic-color-brand-primary, #01426a)}.calendarNavBtn:focus{--ds-auro-calendar-nav-btn-border-color: var(--ds-basic-color-brand-primary, #01426a)}.calendarNavBtn:active{--ds-auro-calendar-nav-btn-border-color: var(--ds-basic-color-brand-primary, #01426a);box-shadow:inset 0 0 0 1px var(--ds-auro-calendar-nav-btn-border-color)}.mobileHeader{background-color:var(--ds-auro-calendar-mobile-header-container-color)}.mobileDateLabel{color:var(--ds-auro-calendar-mobile-header-text-color)}:host(:not([noRange])) .headerDateTo:after{background-color:var(--ds-auro-calendar-mobile-header-divider-color)}::slotted([slot="bib.fullscreen.fromStr"]),::slotted([slot=mobileDateToStr]){color:var(--ds-auro-datepicker-placeholder-color)}@media screen and (max-width: 576px){.calendarNavBtn{--ds-auro-calendar-nav-btn-border-color: var(--ds-basic-color-brand-primary, #01426a)}}`;
|
|
1417
|
-
|
|
1418
|
-
var styleCss$6 = i$3`:focus:not(:focus-visible){outline:3px solid transparent}.body-default{font-family:var(--wcss-body-family, "AS Circular"),system-ui,-apple-system,BlinkMacSystemFont,"Segoe UI",Roboto,"Helvetica Neue",Arial,sans-serif;font-weight:var(--wcss-body-default-weight, );letter-spacing:var(--wcss-body-letter-spacing, 0);font-size:var(--wcss-body-default-font-size, 1rem);line-height:var(--wcss-body-default-line-height, 1.5rem)}.body-default-emphasized{font-family:var(--wcss-body-family, "AS Circular"),system-ui,-apple-system,BlinkMacSystemFont,"Segoe UI",Roboto,"Helvetica Neue",Arial,sans-serif;font-weight:var(--wcss-body-default-emphasized-weight, );letter-spacing:var(--wcss-body-letter-spacing, 0);font-size:var(--wcss-body-default-emphasized-font-size, 1rem);line-height:var(--wcss-body-default-emphasized-line-height, 1.5rem)}.body-lg{font-family:var(--wcss-body-family, "AS Circular"),system-ui,-apple-system,BlinkMacSystemFont,"Segoe UI",Roboto,"Helvetica Neue",Arial,sans-serif;font-weight:var(--wcss-body-lg-weight, );letter-spacing:var(--wcss-body-letter-spacing, 0);font-size:var(--wcss-body-lg-font-size, 1.125rem);line-height:var(--wcss-body-lg-line-height, 1.625rem)}.body-lg-emphasized{font-family:var(--wcss-body-family, "AS Circular"),system-ui,-apple-system,BlinkMacSystemFont,"Segoe UI",Roboto,"Helvetica Neue",Arial,sans-serif;font-weight:var(--wcss-body-lg-emphasized-weight, );letter-spacing:var(--wcss-body-letter-spacing, 0);font-size:var(--wcss-body-lg-emphasized-font-size, 1.125rem);line-height:var(--wcss-body-lg-emphasized-line-height, 1.625rem)}.body-sm{font-family:var(--wcss-body-family, "AS Circular"),system-ui,-apple-system,BlinkMacSystemFont,"Segoe UI",Roboto,"Helvetica Neue",Arial,sans-serif;font-weight:var(--wcss-body-sm-weight, );letter-spacing:var(--wcss-body-letter-spacing, 0);font-size:var(--wcss-body-sm-font-size, 0.875rem);line-height:var(--wcss-body-sm-line-height, 1.25rem)}.body-sm-emphasized{font-family:var(--wcss-body-family, "AS Circular"),system-ui,-apple-system,BlinkMacSystemFont,"Segoe UI",Roboto,"Helvetica Neue",Arial,sans-serif;font-weight:var(--wcss-body-sm-emphasized-weight, );letter-spacing:var(--wcss-body-letter-spacing, 0);font-size:var(--wcss-body-sm-emphasized-font-size, 0.875rem);line-height:var(--wcss-body-sm-emphasized-line-height, 1.25rem)}.body-xs{font-family:var(--wcss-body-family, "AS Circular"),system-ui,-apple-system,BlinkMacSystemFont,"Segoe UI",Roboto,"Helvetica Neue",Arial,sans-serif;font-weight:var(--wcss-body-xs-weight, );letter-spacing:var(--wcss-body-letter-spacing, 0);font-size:var(--wcss-body-xs-font-size, 0.75rem);line-height:var(--wcss-body-xs-line-height, 1rem)}.body-xs-emphasized{font-family:var(--wcss-body-family, "AS Circular"),system-ui,-apple-system,BlinkMacSystemFont,"Segoe UI",Roboto,"Helvetica Neue",Arial,sans-serif;font-weight:var(--wcss-body-xs-emphasized-weight, );letter-spacing:var(--wcss-body-letter-spacing, 0);font-size:var(--wcss-body-xs-emphasized-font-size, 0.75rem);line-height:var(--wcss-body-xs-emphasized-line-height, 1rem)}.body-2xs{font-family:var(--wcss-body-family, "AS Circular"),system-ui,-apple-system,BlinkMacSystemFont,"Segoe UI",Roboto,"Helvetica Neue",Arial,sans-serif;font-weight:var(--wcss-body-2xs-weight, );letter-spacing:var(--wcss-body-letter-spacing, 0);font-size:var(--wcss-body-2xs-font-size, 0.625rem);line-height:var(--wcss-body-2xs-line-height, 0.875rem)}.body-2xs-emphasized{font-family:var(--wcss-body-family, "AS Circular"),system-ui,-apple-system,BlinkMacSystemFont,"Segoe UI",Roboto,"Helvetica Neue",Arial,sans-serif;font-weight:var(--wcss-body-2xs-emphasized-weight, );letter-spacing:var(--wcss-body-letter-spacing, 0);font-size:var(--wcss-body-2xs-emphasized-font-size, 0.625rem);line-height:var(--wcss-body-2xs-emphasized-line-height, 0.875rem)}.display-2xl{font-family:var(--wcss-display-2xl-family, "AS Circular"),var(--wcss-display-2xl-family-fallback, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif);font-weight:var(--wcss-display-2xl-weight, 300);line-height:var(--wcss-display-2xl-line-height, 1.3);font-size:var(--wcss-display-2xl-font-size, clamp(3.5rem, 6vw, 5.375rem));letter-spacing:var(--wcss-display-2xl-letter-spacing, 0)}.display-xl{font-family:var(--wcss-display-xl-family, "AS Circular"),var(--wcss-display-xl-family-fallback, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif);font-weight:var(--wcss-display-xl-weight, 300);line-height:var(--wcss-display-xl-line-height, 1.3);font-size:var(--wcss-display-xl-font-size, clamp(3rem, 5.3333333333vw, 4.5rem));letter-spacing:var(--wcss-display-xl-letter-spacing, 0)}.display-lg{font-family:var(--wcss-display-lg-family, "AS Circular"),var(--wcss-display-lg-family-fallback, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif);font-weight:var(--wcss-display-lg-weight, 300);line-height:var(--wcss-display-lg-line-height, 1.3);font-size:var(--wcss-display-lg-font-size, clamp(2.75rem, 4.6666666667vw, 4rem));letter-spacing:var(--wcss-display-lg-letter-spacing, 0)}.display-md{font-family:var(--wcss-display-md-family, "AS Circular"),var(--wcss-display-md-family-fallback, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif);font-weight:var(--wcss-display-md-weight, 300);line-height:var(--wcss-display-md-line-height, 1.3);font-size:var(--wcss-display-md-font-size, clamp(2.5rem, 4vw, 3.5rem));letter-spacing:var(--wcss-display-md-letter-spacing, 0)}.display-sm{font-family:var(--wcss-display-sm-family, "AS Circular"),var(--wcss-display-sm-family-fallback, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif);font-weight:var(--wcss-display-sm-weight, 300);line-height:var(--wcss-display-sm-line-height, 1.3);font-size:var(--wcss-display-sm-font-size, clamp(2rem, 3.6666666667vw, 3rem));letter-spacing:var(--wcss-display-sm-letter-spacing, 0)}.display-xs{font-family:var(--wcss-display-xs-family, "AS Circular"),var(--wcss-display-xs-family-fallback, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif);font-weight:var(--wcss-display-xs-weight, 300);line-height:var(--wcss-display-xs-line-height, 1.3);font-size:var(--wcss-display-xs-font-size, clamp(1.75rem, 3vw, 2.375rem));letter-spacing:var(--wcss-display-xs-letter-spacing, 0)}.heading-xl{font-family:var(--wcss-heading-xl-family, "AS Circular"),var(--wcss-heading-xl-family-fallback, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif);font-weight:var(--wcss-heading-xl-weight, 300);line-height:var(--wcss-heading-xl-line-height, 1.3);font-size:var(--wcss-heading-xl-font-size, clamp(2rem, 3vw, 2.5rem));letter-spacing:var(--wcss-heading-xl-letter-spacing, 0)}.heading-lg{font-family:var(--wcss-heading-lg-family, "AS Circular"),var(--wcss-heading-lg-family-fallback, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif);font-weight:var(--wcss-heading-lg-weight, 300);line-height:var(--wcss-heading-lg-line-height, 1.3);font-size:var(--wcss-heading-lg-font-size, clamp(1.75rem, 2.6666666667vw, 2.25rem));letter-spacing:var(--wcss-heading-lg-letter-spacing, 0)}.heading-md{font-family:var(--wcss-heading-md-family, "AS Circular"),var(--wcss-heading-md-family-fallback, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif);font-weight:var(--wcss-heading-md-weight, 300);line-height:var(--wcss-heading-md-line-height, 1.3);font-size:var(--wcss-heading-md-font-size, clamp(1.625rem, 2.3333333333vw, 1.75rem));letter-spacing:var(--wcss-heading-md-letter-spacing, 0)}.heading-sm{font-family:var(--wcss-heading-sm-family, "AS Circular"),var(--wcss-heading-sm-family-fallback, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif);font-weight:var(--wcss-heading-sm-weight, 300);line-height:var(--wcss-heading-sm-line-height, 1.3);font-size:var(--wcss-heading-sm-font-size, clamp(1.375rem, 2vw, 1.5rem));letter-spacing:var(--wcss-heading-sm-letter-spacing, 0)}.heading-xs{font-family:var(--wcss-heading-xs-family, "AS Circular"),var(--wcss-heading-xs-family-fallback, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif);font-weight:var(--wcss-heading-xs-weight, 300);line-height:var(--wcss-heading-xs-line-height, 1.3);font-size:var(--wcss-heading-xs-font-size, clamp(1.25rem, 1.6666666667vw, 1.25rem));letter-spacing:var(--wcss-heading-xs-letter-spacing, 0)}.heading-2xs{font-family:var(--wcss-heading-2xs-family, "AS Circular"),var(--wcss-heading-2xs-family-fallback, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif);font-weight:var(--wcss-heading-2xs-weight, 300);line-height:var(--wcss-heading-2xs-line-height, 1.3);font-size:var(--wcss-heading-2xs-font-size, clamp(1.125rem, 1.5vw, 1.125rem));letter-spacing:var(--wcss-heading-2xs-letter-spacing, 0)}.accent-2xl{font-family:var(--wcss-accent-2xl-family, "Good OT"),var(--wcss-accent-2xl-family-fallback, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif);font-weight:var(--wcss-accent-2xl-weight, 450);line-height:var(--wcss-accent-2xl-line-height, 1);font-size:var(--wcss-accent-2xl-font-size, clamp(2rem, 3.1666666667vw, 2.375rem));letter-spacing:var(--wcss-accent-2xl-letter-spacing, 0.05em);text-transform:uppercase}.accent-xl{font-family:var(--wcss-accent-xl-family, "Good OT"),var(--wcss-accent-xl-family-fallback, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif);font-weight:var(--wcss-accent-xl-weight, 450);line-height:var(--wcss-accent-xl-line-height, 1.3);font-size:var(--wcss-accent-xl-font-size, clamp(1.625rem, 2.3333333333vw, 2rem));letter-spacing:var(--wcss-accent-xl-letter-spacing, 0.05em);text-transform:uppercase}.accent-lg{font-family:var(--wcss-accent-lg-family, "Good OT"),var(--wcss-accent-lg-family-fallback, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif);font-weight:var(--wcss-accent-lg-weight, 450);line-height:var(--wcss-accent-lg-line-height, 1.3);font-size:var(--wcss-accent-lg-font-size, clamp(1.5rem, 2.1666666667vw, 1.75rem));letter-spacing:var(--wcss-accent-lg-letter-spacing, 0.05em);text-transform:uppercase}.accent-md{font-family:var(--wcss-accent-md-family, "Good OT"),var(--wcss-accent-md-family-fallback, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif);font-weight:var(--wcss-accent-md-weight, 500);line-height:var(--wcss-accent-md-line-height, 1.3);font-size:var(--wcss-accent-md-font-size, clamp(1.375rem, 1.8333333333vw, 1.5rem));letter-spacing:var(--wcss-accent-md-letter-spacing, 0.05em);text-transform:uppercase}.accent-sm{font-family:var(--wcss-accent-sm-family, "Good OT"),var(--wcss-accent-sm-family-fallback, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif);font-weight:var(--wcss-accent-sm-weight, 500);line-height:var(--wcss-accent-sm-line-height, 1.3);font-size:var(--wcss-accent-sm-font-size, clamp(1.125rem, 1.5vw, 1.25rem));letter-spacing:var(--wcss-accent-sm-letter-spacing, 0.05em);text-transform:uppercase}.accent-xs{font-family:var(--wcss-accent-xs-family, "Good OT"),var(--wcss-accent-xs-family-fallback, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif);font-weight:var(--wcss-accent-xs-weight, 500);line-height:var(--wcss-accent-xs-line-height, 1.3);font-size:var(--wcss-accent-xs-font-size, clamp(1rem, 1.3333333333vw, 1rem));letter-spacing:var(--wcss-accent-xs-letter-spacing, 0.1em);text-transform:uppercase}.accent-2xs{font-family:var(--wcss-accent-2xs-family, "Good OT"),var(--wcss-accent-2xs-family-fallback, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif);font-weight:var(--wcss-accent-2xs-weight, 450);line-height:var(--wcss-accent-2xs-line-height, 1.3);font-size:var(--wcss-accent-2xs-font-size, clamp(0.875rem, 1.1666666667vw, 0.875rem));letter-spacing:var(--wcss-accent-2xs-letter-spacing, 0.1em);text-transform:uppercase}:host{position:relative;display:block;width:calc(100% - var(--ds-size-200, 1rem) - var(--ds-size-200, 1rem));margin:0 var(--ds-size-200, 1rem)}@media screen and (min-width: 576px){:host{width:336px;padding:var(--ds-size-200, 1rem)}}@media screen and (min-width: 576px){:host(:not(:last-of-type)):after{position:absolute;top:var(--ds-size-200, 1rem);right:calc(-1*var(--ds-size-200, 1rem));height:calc(100% - var(--ds-size-200, 1rem) - var(--ds-size-200, 1rem));display:block;width:1px;content:""}}.header{display:flex;height:var(--ds-size-500, 2.5rem);margin-bottom:var(--ds-size-150, 0.75rem);align-items:center;flex-direction:row;text-align:center}.headerTitle{display:flex;align-items:center;flex:1;flex-direction:row;justify-content:center}.headerTitle div:first-child{margin-right:var(--ds-size-100, 0.5rem)}.calendarNavBtn{position:relative;display:flex;width:var(--ds-size-500, 2.5rem);height:var(--ds-size-500, 2.5rem);align-items:center;justify-content:center;border-width:1px;border-style:solid;border-radius:50%;cursor:pointer}.table{width:100%;border-collapse:collapse}.thead{margin-bottom:var(--ds-size-100, 0.5rem)}.th{display:flex;flex:1;align-items:center;justify-content:center}.th abbr{text-decoration:none}.tbody{width:100%;transition:all 0ms;transform:translateX(0)}@media screen and (min-width: 576px){.tbody{height:384px}}.td{flex:1;margin:0;padding:0}.tr{display:flex;flex-direction:row;width:100%}`;
|
|
1419
|
-
|
|
1420
|
-
var colorCss$6 = i$3`:focus:not(:focus-visible){outline:3px solid transparent}:host{background-color:var(--ds-auro-calendar-month-container-color)}@media screen and (min-width: 576px){:host(:not(:last-of-type)):after{background-color:var(--ds-auro-calendar-month-divider-color)}}.header{color:var(--ds-auro-calendar-month-header-color)}`;
|
|
1421
|
-
|
|
1422
|
-
/******************************************************************************
|
|
1423
|
-
Copyright (c) Microsoft Corporation.
|
|
1424
|
-
|
|
1425
|
-
Permission to use, copy, modify, and/or distribute this software for any
|
|
1426
|
-
purpose with or without fee is hereby granted.
|
|
1427
|
-
|
|
1428
|
-
THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES WITH
|
|
1429
|
-
REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY
|
|
1430
|
-
AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY SPECIAL, DIRECT,
|
|
1431
|
-
INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM
|
|
1432
|
-
LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE OR
|
|
1433
|
-
OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR
|
|
1434
|
-
PERFORMANCE OF THIS SOFTWARE.
|
|
1435
|
-
***************************************************************************** */
|
|
1436
|
-
/* global Reflect, Promise, SuppressedError, Symbol, Iterator */
|
|
1437
|
-
|
|
1438
|
-
|
|
1439
|
-
function __decorate(decorators, target, key, desc) {
|
|
1440
|
-
var c = arguments.length, r = c < 3 ? target : desc === null ? desc = Object.getOwnPropertyDescriptor(target, key) : desc, d;
|
|
1441
|
-
if (typeof Reflect === "object" && typeof Reflect.decorate === "function") r = Reflect.decorate(decorators, target, key, desc);
|
|
1442
|
-
else for (var i = decorators.length - 1; i >= 0; i--) if (d = decorators[i]) r = (c < 3 ? d(r) : c > 3 ? d(target, key, r) : d(target, key)) || r;
|
|
1443
|
-
return c > 3 && r && Object.defineProperty(target, key, r), r;
|
|
1444
|
-
}
|
|
1445
|
-
|
|
1446
|
-
typeof SuppressedError === "function" ? SuppressedError : function (error, suppressed, message) {
|
|
1447
|
-
var e = new Error(message);
|
|
1448
|
-
return e.name = "SuppressedError", e.error = error, e.suppressed = suppressed, e;
|
|
1449
|
-
};
|
|
1450
|
-
|
|
1451
|
-
/**
|
|
1452
|
-
* @license
|
|
1453
|
-
* Copyright 2017 Google LLC
|
|
1454
|
-
* SPDX-License-Identifier: BSD-3-Clause
|
|
1455
|
-
*/const o$4={attribute:true,type:String,converter:u$9,reflect:false,hasChanged:f$8},r$4=(t=o$4,e,r)=>{const{kind:n,metadata:i}=r;let s=globalThis.litPropertyMetadata.get(i);if(void 0===s&&globalThis.litPropertyMetadata.set(i,s=new Map),"setter"===n&&((t=Object.create(t)).wrapped=true),s.set(r.name,t),"accessor"===n){const{name:o}=r;return {set(r){const n=e.get.call(this);e.set.call(this,r),this.requestUpdate(o,n,t,true,r);},init(e){return void 0!==e&&this.C(o,void 0,t,e),e}}}if("setter"===n){const{name:o}=r;return function(r){const n=this[o];e.call(this,r),this.requestUpdate(o,n,t,true,r);}}throw Error("Unsupported decorator location: "+n)};function n$4(t){return (e,o)=>"object"==typeof o?r$4(t,e,o):((t,e,o)=>{const r=e.hasOwnProperty(o);return e.constructor.createProperty(o,t),r?Object.getOwnPropertyDescriptor(e,o):void 0})(t,e,o)}
|
|
1456
|
-
|
|
1457
1534
|
/**
|
|
1458
1535
|
* @module constants
|
|
1459
1536
|
* @summary Useful constants
|
|
@@ -7208,6 +7285,49 @@ function subYears(date, amount, options) {
|
|
|
7208
7285
|
return addYears(date, -1, options);
|
|
7209
7286
|
}
|
|
7210
7287
|
|
|
7288
|
+
var styleCss$7 = i$3`.body-default{font-family:var(--wcss-body-family, "AS Circular"),system-ui,-apple-system,BlinkMacSystemFont,"Segoe UI",Roboto,"Helvetica Neue",Arial,sans-serif;font-weight:var(--wcss-body-default-weight, );letter-spacing:var(--wcss-body-letter-spacing, 0);font-size:var(--wcss-body-default-font-size, 1rem);line-height:var(--wcss-body-default-line-height, 1.5rem)}.body-default-emphasized{font-family:var(--wcss-body-family, "AS Circular"),system-ui,-apple-system,BlinkMacSystemFont,"Segoe UI",Roboto,"Helvetica Neue",Arial,sans-serif;font-weight:var(--wcss-body-default-emphasized-weight, );letter-spacing:var(--wcss-body-letter-spacing, 0);font-size:var(--wcss-body-default-emphasized-font-size, 1rem);line-height:var(--wcss-body-default-emphasized-line-height, 1.5rem)}.body-lg{font-family:var(--wcss-body-family, "AS Circular"),system-ui,-apple-system,BlinkMacSystemFont,"Segoe UI",Roboto,"Helvetica Neue",Arial,sans-serif;font-weight:var(--wcss-body-lg-weight, );letter-spacing:var(--wcss-body-letter-spacing, 0);font-size:var(--wcss-body-lg-font-size, 1.125rem);line-height:var(--wcss-body-lg-line-height, 1.625rem)}.body-lg-emphasized{font-family:var(--wcss-body-family, "AS Circular"),system-ui,-apple-system,BlinkMacSystemFont,"Segoe UI",Roboto,"Helvetica Neue",Arial,sans-serif;font-weight:var(--wcss-body-lg-emphasized-weight, );letter-spacing:var(--wcss-body-letter-spacing, 0);font-size:var(--wcss-body-lg-emphasized-font-size, 1.125rem);line-height:var(--wcss-body-lg-emphasized-line-height, 1.625rem)}.body-sm{font-family:var(--wcss-body-family, "AS Circular"),system-ui,-apple-system,BlinkMacSystemFont,"Segoe UI",Roboto,"Helvetica Neue",Arial,sans-serif;font-weight:var(--wcss-body-sm-weight, );letter-spacing:var(--wcss-body-letter-spacing, 0);font-size:var(--wcss-body-sm-font-size, 0.875rem);line-height:var(--wcss-body-sm-line-height, 1.25rem)}.body-sm-emphasized{font-family:var(--wcss-body-family, "AS Circular"),system-ui,-apple-system,BlinkMacSystemFont,"Segoe UI",Roboto,"Helvetica Neue",Arial,sans-serif;font-weight:var(--wcss-body-sm-emphasized-weight, );letter-spacing:var(--wcss-body-letter-spacing, 0);font-size:var(--wcss-body-sm-emphasized-font-size, 0.875rem);line-height:var(--wcss-body-sm-emphasized-line-height, 1.25rem)}.body-xs{font-family:var(--wcss-body-family, "AS Circular"),system-ui,-apple-system,BlinkMacSystemFont,"Segoe UI",Roboto,"Helvetica Neue",Arial,sans-serif;font-weight:var(--wcss-body-xs-weight, );letter-spacing:var(--wcss-body-letter-spacing, 0);font-size:var(--wcss-body-xs-font-size, 0.75rem);line-height:var(--wcss-body-xs-line-height, 1rem)}.body-xs-emphasized{font-family:var(--wcss-body-family, "AS Circular"),system-ui,-apple-system,BlinkMacSystemFont,"Segoe UI",Roboto,"Helvetica Neue",Arial,sans-serif;font-weight:var(--wcss-body-xs-emphasized-weight, );letter-spacing:var(--wcss-body-letter-spacing, 0);font-size:var(--wcss-body-xs-emphasized-font-size, 0.75rem);line-height:var(--wcss-body-xs-emphasized-line-height, 1rem)}.body-2xs{font-family:var(--wcss-body-family, "AS Circular"),system-ui,-apple-system,BlinkMacSystemFont,"Segoe UI",Roboto,"Helvetica Neue",Arial,sans-serif;font-weight:var(--wcss-body-2xs-weight, );letter-spacing:var(--wcss-body-letter-spacing, 0);font-size:var(--wcss-body-2xs-font-size, 0.625rem);line-height:var(--wcss-body-2xs-line-height, 0.875rem)}.body-2xs-emphasized{font-family:var(--wcss-body-family, "AS Circular"),system-ui,-apple-system,BlinkMacSystemFont,"Segoe UI",Roboto,"Helvetica Neue",Arial,sans-serif;font-weight:var(--wcss-body-2xs-emphasized-weight, );letter-spacing:var(--wcss-body-letter-spacing, 0);font-size:var(--wcss-body-2xs-emphasized-font-size, 0.625rem);line-height:var(--wcss-body-2xs-emphasized-line-height, 0.875rem)}.display-2xl{font-family:var(--wcss-display-2xl-family, "AS Circular"),var(--wcss-display-2xl-family-fallback, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif);font-weight:var(--wcss-display-2xl-weight, 300);line-height:var(--wcss-display-2xl-line-height, 1.3);font-size:var(--wcss-display-2xl-font-size, clamp(3.5rem, 6vw, 5.375rem));letter-spacing:var(--wcss-display-2xl-letter-spacing, 0)}.display-xl{font-family:var(--wcss-display-xl-family, "AS Circular"),var(--wcss-display-xl-family-fallback, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif);font-weight:var(--wcss-display-xl-weight, 300);line-height:var(--wcss-display-xl-line-height, 1.3);font-size:var(--wcss-display-xl-font-size, clamp(3rem, 5.3333333333vw, 4.5rem));letter-spacing:var(--wcss-display-xl-letter-spacing, 0)}.display-lg{font-family:var(--wcss-display-lg-family, "AS Circular"),var(--wcss-display-lg-family-fallback, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif);font-weight:var(--wcss-display-lg-weight, 300);line-height:var(--wcss-display-lg-line-height, 1.3);font-size:var(--wcss-display-lg-font-size, clamp(2.75rem, 4.6666666667vw, 4rem));letter-spacing:var(--wcss-display-lg-letter-spacing, 0)}.display-md{font-family:var(--wcss-display-md-family, "AS Circular"),var(--wcss-display-md-family-fallback, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif);font-weight:var(--wcss-display-md-weight, 300);line-height:var(--wcss-display-md-line-height, 1.3);font-size:var(--wcss-display-md-font-size, clamp(2.5rem, 4vw, 3.5rem));letter-spacing:var(--wcss-display-md-letter-spacing, 0)}.display-sm{font-family:var(--wcss-display-sm-family, "AS Circular"),var(--wcss-display-sm-family-fallback, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif);font-weight:var(--wcss-display-sm-weight, 300);line-height:var(--wcss-display-sm-line-height, 1.3);font-size:var(--wcss-display-sm-font-size, clamp(2rem, 3.6666666667vw, 3rem));letter-spacing:var(--wcss-display-sm-letter-spacing, 0)}.display-xs{font-family:var(--wcss-display-xs-family, "AS Circular"),var(--wcss-display-xs-family-fallback, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif);font-weight:var(--wcss-display-xs-weight, 300);line-height:var(--wcss-display-xs-line-height, 1.3);font-size:var(--wcss-display-xs-font-size, clamp(1.75rem, 3vw, 2.375rem));letter-spacing:var(--wcss-display-xs-letter-spacing, 0)}.heading-xl{font-family:var(--wcss-heading-xl-family, "AS Circular"),var(--wcss-heading-xl-family-fallback, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif);font-weight:var(--wcss-heading-xl-weight, 300);line-height:var(--wcss-heading-xl-line-height, 1.3);font-size:var(--wcss-heading-xl-font-size, clamp(2rem, 3vw, 2.5rem));letter-spacing:var(--wcss-heading-xl-letter-spacing, 0)}.heading-lg{font-family:var(--wcss-heading-lg-family, "AS Circular"),var(--wcss-heading-lg-family-fallback, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif);font-weight:var(--wcss-heading-lg-weight, 300);line-height:var(--wcss-heading-lg-line-height, 1.3);font-size:var(--wcss-heading-lg-font-size, clamp(1.75rem, 2.6666666667vw, 2.25rem));letter-spacing:var(--wcss-heading-lg-letter-spacing, 0)}.heading-md{font-family:var(--wcss-heading-md-family, "AS Circular"),var(--wcss-heading-md-family-fallback, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif);font-weight:var(--wcss-heading-md-weight, 300);line-height:var(--wcss-heading-md-line-height, 1.3);font-size:var(--wcss-heading-md-font-size, clamp(1.625rem, 2.3333333333vw, 1.75rem));letter-spacing:var(--wcss-heading-md-letter-spacing, 0)}.heading-sm{font-family:var(--wcss-heading-sm-family, "AS Circular"),var(--wcss-heading-sm-family-fallback, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif);font-weight:var(--wcss-heading-sm-weight, 300);line-height:var(--wcss-heading-sm-line-height, 1.3);font-size:var(--wcss-heading-sm-font-size, clamp(1.375rem, 2vw, 1.5rem));letter-spacing:var(--wcss-heading-sm-letter-spacing, 0)}.heading-xs{font-family:var(--wcss-heading-xs-family, "AS Circular"),var(--wcss-heading-xs-family-fallback, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif);font-weight:var(--wcss-heading-xs-weight, 300);line-height:var(--wcss-heading-xs-line-height, 1.3);font-size:var(--wcss-heading-xs-font-size, clamp(1.25rem, 1.6666666667vw, 1.25rem));letter-spacing:var(--wcss-heading-xs-letter-spacing, 0)}.heading-2xs{font-family:var(--wcss-heading-2xs-family, "AS Circular"),var(--wcss-heading-2xs-family-fallback, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif);font-weight:var(--wcss-heading-2xs-weight, 300);line-height:var(--wcss-heading-2xs-line-height, 1.3);font-size:var(--wcss-heading-2xs-font-size, clamp(1.125rem, 1.5vw, 1.125rem));letter-spacing:var(--wcss-heading-2xs-letter-spacing, 0)}.accent-2xl{font-family:var(--wcss-accent-2xl-family, "Good OT"),var(--wcss-accent-2xl-family-fallback, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif);font-weight:var(--wcss-accent-2xl-weight, 450);line-height:var(--wcss-accent-2xl-line-height, 1);font-size:var(--wcss-accent-2xl-font-size, clamp(2rem, 3.1666666667vw, 2.375rem));letter-spacing:var(--wcss-accent-2xl-letter-spacing, 0.05em);text-transform:uppercase}.accent-xl{font-family:var(--wcss-accent-xl-family, "Good OT"),var(--wcss-accent-xl-family-fallback, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif);font-weight:var(--wcss-accent-xl-weight, 450);line-height:var(--wcss-accent-xl-line-height, 1.3);font-size:var(--wcss-accent-xl-font-size, clamp(1.625rem, 2.3333333333vw, 2rem));letter-spacing:var(--wcss-accent-xl-letter-spacing, 0.05em);text-transform:uppercase}.accent-lg{font-family:var(--wcss-accent-lg-family, "Good OT"),var(--wcss-accent-lg-family-fallback, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif);font-weight:var(--wcss-accent-lg-weight, 450);line-height:var(--wcss-accent-lg-line-height, 1.3);font-size:var(--wcss-accent-lg-font-size, clamp(1.5rem, 2.1666666667vw, 1.75rem));letter-spacing:var(--wcss-accent-lg-letter-spacing, 0.05em);text-transform:uppercase}.accent-md{font-family:var(--wcss-accent-md-family, "Good OT"),var(--wcss-accent-md-family-fallback, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif);font-weight:var(--wcss-accent-md-weight, 500);line-height:var(--wcss-accent-md-line-height, 1.3);font-size:var(--wcss-accent-md-font-size, clamp(1.375rem, 1.8333333333vw, 1.5rem));letter-spacing:var(--wcss-accent-md-letter-spacing, 0.05em);text-transform:uppercase}.accent-sm{font-family:var(--wcss-accent-sm-family, "Good OT"),var(--wcss-accent-sm-family-fallback, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif);font-weight:var(--wcss-accent-sm-weight, 500);line-height:var(--wcss-accent-sm-line-height, 1.3);font-size:var(--wcss-accent-sm-font-size, clamp(1.125rem, 1.5vw, 1.25rem));letter-spacing:var(--wcss-accent-sm-letter-spacing, 0.05em);text-transform:uppercase}.accent-xs{font-family:var(--wcss-accent-xs-family, "Good OT"),var(--wcss-accent-xs-family-fallback, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif);font-weight:var(--wcss-accent-xs-weight, 500);line-height:var(--wcss-accent-xs-line-height, 1.3);font-size:var(--wcss-accent-xs-font-size, clamp(1rem, 1.3333333333vw, 1rem));letter-spacing:var(--wcss-accent-xs-letter-spacing, 0.1em);text-transform:uppercase}.accent-2xs{font-family:var(--wcss-accent-2xs-family, "Good OT"),var(--wcss-accent-2xs-family-fallback, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif);font-weight:var(--wcss-accent-2xs-weight, 450);line-height:var(--wcss-accent-2xs-line-height, 1.3);font-size:var(--wcss-accent-2xs-font-size, clamp(0.875rem, 1.1666666667vw, 0.875rem));letter-spacing:var(--wcss-accent-2xs-letter-spacing, 0.1em);text-transform:uppercase}:host{--calendar-width: 336px;--mobile-footer-height: 150px;--mobile-header-height: 68px;--desktop-footer-height: 80px;height:100vh;height:100dvh}.calendars{display:flex;flex-direction:row}.calendars:focus{outline:none}.calendarNavButtons{position:absolute;z-index:1;top:var(--ds-size-200, 1rem);right:var(--ds-size-50, 0.25rem);left:var(--ds-size-50, 0.25rem)}.calendarNavBtn{display:flex;width:var(--ds-size-500, 2.5rem);height:var(--ds-size-500, 2.5rem);align-items:center;justify-content:center;border-width:1px;border-style:solid;border-radius:50%;cursor:pointer}.prevMonth,.nextMonth{position:absolute;top:0}.prevMonth{left:0}.nextMonth{right:0}.headerActions{padding:0 var(--ds-size-200, 1rem)}.mobileHeader{width:100%;height:var(--mobile-header-height);z-index:1;align-items:center;flex-direction:row}.headerDateFrom,.headerDateTo{display:flex;height:var(--mobile-header-height);flex:1;flex-direction:column;justify-content:center;padding:0 var(--ds-size-150, 0.75rem) 0 var(--ds-size-200, 1rem)}.mobileDateLabel{padding:var(--ds-size-25, 0.125rem) 0}.mobileFooter{display:none;width:100%;align-items:flex-end;flex-direction:column;justify-content:flex-end}.mobileFooterActions{position:relative;bottom:0;left:50%;display:none;width:calc(100% - var(--ds-size-200, 1rem)*2);align-items:flex-end;flex-direction:column;justify-content:flex-end;padding:var(--ds-size-150) calc(var(--ds-size-200, 1rem));transform:translateX(-50%)}.mobileFooterActions auro-button{width:100%}.calendarWrapper.hasFooter{padding-bottom:var(--desktop-footer-height)}:host([isfullscreen]){width:100%;max-height:100dvh;overflow:hidden}:host([isfullscreen]) .prevMonth,:host([isfullscreen]) .nextMonth{display:none}:host([isfullscreen]) .mobileHeader,:host([isfullscreen]) .mobileFooter,:host([isfullscreen]) .mobileFooterActions{display:flex}:host([isfullscreen]) .calendarWrapper{display:flex;flex-direction:column}:host([isfullscreen]) .calendars{display:flex;flex-direction:column;flex:1;align-items:center;width:100%;overscroll-behavior:contain}:host([isfullscreen]) .calendars:after{display:block;width:100%;height:var(--mobile-footer-height);content:""}.sr-only{position:absolute;overflow:hidden;clip:rect(0, 0, 0, 0);width:1px;height:1px;margin:-1px;padding:0;border:0;white-space:nowrap}`;
|
|
7289
|
+
|
|
7290
|
+
var colorCss$7 = i$3`.calendarNavBtn{border-color:var(--ds-auro-calendar-nav-btn-border-color);background-color:var(--ds-auro-calendar-nav-btn-container-color);color:var(--ds-auro-calendar-nav-btn-chevron-color)}.calendarNavBtn:hover{--ds-auro-calendar-nav-btn-container-color: var(--ds-advanced-color-state-background-hover, #f2f2f2);--ds-auro-calendar-nav-btn-border-color: var(--ds-basic-color-brand-primary, #01426a)}.calendarNavBtn:focus{--ds-auro-calendar-nav-btn-border-color: var(--ds-basic-color-brand-primary, #01426a)}.calendarNavBtn:active{--ds-auro-calendar-nav-btn-border-color: var(--ds-basic-color-brand-primary, #01426a);box-shadow:inset 0 0 0 1px var(--ds-auro-calendar-nav-btn-border-color)}.mobileHeader{background-color:var(--ds-auro-calendar-mobile-header-container-color)}.mobileDateLabel{color:var(--ds-auro-calendar-mobile-header-text-color)}:host(:not([noRange])) .headerDateTo:after{background-color:var(--ds-auro-calendar-mobile-header-divider-color)}::slotted([slot="bib.fullscreen.fromStr"]),::slotted([slot=mobileDateToStr]){color:var(--ds-auro-datepicker-placeholder-color)}@media screen and (max-width: 576px){.calendarNavBtn{--ds-auro-calendar-nav-btn-border-color: var(--ds-basic-color-brand-primary, #01426a)}}`;
|
|
7291
|
+
|
|
7292
|
+
var styleCss$6 = i$3`:focus:not(:focus-visible){outline:3px solid transparent}.body-default{font-family:var(--wcss-body-family, "AS Circular"),system-ui,-apple-system,BlinkMacSystemFont,"Segoe UI",Roboto,"Helvetica Neue",Arial,sans-serif;font-weight:var(--wcss-body-default-weight, );letter-spacing:var(--wcss-body-letter-spacing, 0);font-size:var(--wcss-body-default-font-size, 1rem);line-height:var(--wcss-body-default-line-height, 1.5rem)}.body-default-emphasized{font-family:var(--wcss-body-family, "AS Circular"),system-ui,-apple-system,BlinkMacSystemFont,"Segoe UI",Roboto,"Helvetica Neue",Arial,sans-serif;font-weight:var(--wcss-body-default-emphasized-weight, );letter-spacing:var(--wcss-body-letter-spacing, 0);font-size:var(--wcss-body-default-emphasized-font-size, 1rem);line-height:var(--wcss-body-default-emphasized-line-height, 1.5rem)}.body-lg{font-family:var(--wcss-body-family, "AS Circular"),system-ui,-apple-system,BlinkMacSystemFont,"Segoe UI",Roboto,"Helvetica Neue",Arial,sans-serif;font-weight:var(--wcss-body-lg-weight, );letter-spacing:var(--wcss-body-letter-spacing, 0);font-size:var(--wcss-body-lg-font-size, 1.125rem);line-height:var(--wcss-body-lg-line-height, 1.625rem)}.body-lg-emphasized{font-family:var(--wcss-body-family, "AS Circular"),system-ui,-apple-system,BlinkMacSystemFont,"Segoe UI",Roboto,"Helvetica Neue",Arial,sans-serif;font-weight:var(--wcss-body-lg-emphasized-weight, );letter-spacing:var(--wcss-body-letter-spacing, 0);font-size:var(--wcss-body-lg-emphasized-font-size, 1.125rem);line-height:var(--wcss-body-lg-emphasized-line-height, 1.625rem)}.body-sm{font-family:var(--wcss-body-family, "AS Circular"),system-ui,-apple-system,BlinkMacSystemFont,"Segoe UI",Roboto,"Helvetica Neue",Arial,sans-serif;font-weight:var(--wcss-body-sm-weight, );letter-spacing:var(--wcss-body-letter-spacing, 0);font-size:var(--wcss-body-sm-font-size, 0.875rem);line-height:var(--wcss-body-sm-line-height, 1.25rem)}.body-sm-emphasized{font-family:var(--wcss-body-family, "AS Circular"),system-ui,-apple-system,BlinkMacSystemFont,"Segoe UI",Roboto,"Helvetica Neue",Arial,sans-serif;font-weight:var(--wcss-body-sm-emphasized-weight, );letter-spacing:var(--wcss-body-letter-spacing, 0);font-size:var(--wcss-body-sm-emphasized-font-size, 0.875rem);line-height:var(--wcss-body-sm-emphasized-line-height, 1.25rem)}.body-xs{font-family:var(--wcss-body-family, "AS Circular"),system-ui,-apple-system,BlinkMacSystemFont,"Segoe UI",Roboto,"Helvetica Neue",Arial,sans-serif;font-weight:var(--wcss-body-xs-weight, );letter-spacing:var(--wcss-body-letter-spacing, 0);font-size:var(--wcss-body-xs-font-size, 0.75rem);line-height:var(--wcss-body-xs-line-height, 1rem)}.body-xs-emphasized{font-family:var(--wcss-body-family, "AS Circular"),system-ui,-apple-system,BlinkMacSystemFont,"Segoe UI",Roboto,"Helvetica Neue",Arial,sans-serif;font-weight:var(--wcss-body-xs-emphasized-weight, );letter-spacing:var(--wcss-body-letter-spacing, 0);font-size:var(--wcss-body-xs-emphasized-font-size, 0.75rem);line-height:var(--wcss-body-xs-emphasized-line-height, 1rem)}.body-2xs{font-family:var(--wcss-body-family, "AS Circular"),system-ui,-apple-system,BlinkMacSystemFont,"Segoe UI",Roboto,"Helvetica Neue",Arial,sans-serif;font-weight:var(--wcss-body-2xs-weight, );letter-spacing:var(--wcss-body-letter-spacing, 0);font-size:var(--wcss-body-2xs-font-size, 0.625rem);line-height:var(--wcss-body-2xs-line-height, 0.875rem)}.body-2xs-emphasized{font-family:var(--wcss-body-family, "AS Circular"),system-ui,-apple-system,BlinkMacSystemFont,"Segoe UI",Roboto,"Helvetica Neue",Arial,sans-serif;font-weight:var(--wcss-body-2xs-emphasized-weight, );letter-spacing:var(--wcss-body-letter-spacing, 0);font-size:var(--wcss-body-2xs-emphasized-font-size, 0.625rem);line-height:var(--wcss-body-2xs-emphasized-line-height, 0.875rem)}.display-2xl{font-family:var(--wcss-display-2xl-family, "AS Circular"),var(--wcss-display-2xl-family-fallback, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif);font-weight:var(--wcss-display-2xl-weight, 300);line-height:var(--wcss-display-2xl-line-height, 1.3);font-size:var(--wcss-display-2xl-font-size, clamp(3.5rem, 6vw, 5.375rem));letter-spacing:var(--wcss-display-2xl-letter-spacing, 0)}.display-xl{font-family:var(--wcss-display-xl-family, "AS Circular"),var(--wcss-display-xl-family-fallback, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif);font-weight:var(--wcss-display-xl-weight, 300);line-height:var(--wcss-display-xl-line-height, 1.3);font-size:var(--wcss-display-xl-font-size, clamp(3rem, 5.3333333333vw, 4.5rem));letter-spacing:var(--wcss-display-xl-letter-spacing, 0)}.display-lg{font-family:var(--wcss-display-lg-family, "AS Circular"),var(--wcss-display-lg-family-fallback, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif);font-weight:var(--wcss-display-lg-weight, 300);line-height:var(--wcss-display-lg-line-height, 1.3);font-size:var(--wcss-display-lg-font-size, clamp(2.75rem, 4.6666666667vw, 4rem));letter-spacing:var(--wcss-display-lg-letter-spacing, 0)}.display-md{font-family:var(--wcss-display-md-family, "AS Circular"),var(--wcss-display-md-family-fallback, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif);font-weight:var(--wcss-display-md-weight, 300);line-height:var(--wcss-display-md-line-height, 1.3);font-size:var(--wcss-display-md-font-size, clamp(2.5rem, 4vw, 3.5rem));letter-spacing:var(--wcss-display-md-letter-spacing, 0)}.display-sm{font-family:var(--wcss-display-sm-family, "AS Circular"),var(--wcss-display-sm-family-fallback, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif);font-weight:var(--wcss-display-sm-weight, 300);line-height:var(--wcss-display-sm-line-height, 1.3);font-size:var(--wcss-display-sm-font-size, clamp(2rem, 3.6666666667vw, 3rem));letter-spacing:var(--wcss-display-sm-letter-spacing, 0)}.display-xs{font-family:var(--wcss-display-xs-family, "AS Circular"),var(--wcss-display-xs-family-fallback, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif);font-weight:var(--wcss-display-xs-weight, 300);line-height:var(--wcss-display-xs-line-height, 1.3);font-size:var(--wcss-display-xs-font-size, clamp(1.75rem, 3vw, 2.375rem));letter-spacing:var(--wcss-display-xs-letter-spacing, 0)}.heading-xl{font-family:var(--wcss-heading-xl-family, "AS Circular"),var(--wcss-heading-xl-family-fallback, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif);font-weight:var(--wcss-heading-xl-weight, 300);line-height:var(--wcss-heading-xl-line-height, 1.3);font-size:var(--wcss-heading-xl-font-size, clamp(2rem, 3vw, 2.5rem));letter-spacing:var(--wcss-heading-xl-letter-spacing, 0)}.heading-lg{font-family:var(--wcss-heading-lg-family, "AS Circular"),var(--wcss-heading-lg-family-fallback, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif);font-weight:var(--wcss-heading-lg-weight, 300);line-height:var(--wcss-heading-lg-line-height, 1.3);font-size:var(--wcss-heading-lg-font-size, clamp(1.75rem, 2.6666666667vw, 2.25rem));letter-spacing:var(--wcss-heading-lg-letter-spacing, 0)}.heading-md{font-family:var(--wcss-heading-md-family, "AS Circular"),var(--wcss-heading-md-family-fallback, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif);font-weight:var(--wcss-heading-md-weight, 300);line-height:var(--wcss-heading-md-line-height, 1.3);font-size:var(--wcss-heading-md-font-size, clamp(1.625rem, 2.3333333333vw, 1.75rem));letter-spacing:var(--wcss-heading-md-letter-spacing, 0)}.heading-sm{font-family:var(--wcss-heading-sm-family, "AS Circular"),var(--wcss-heading-sm-family-fallback, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif);font-weight:var(--wcss-heading-sm-weight, 300);line-height:var(--wcss-heading-sm-line-height, 1.3);font-size:var(--wcss-heading-sm-font-size, clamp(1.375rem, 2vw, 1.5rem));letter-spacing:var(--wcss-heading-sm-letter-spacing, 0)}.heading-xs{font-family:var(--wcss-heading-xs-family, "AS Circular"),var(--wcss-heading-xs-family-fallback, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif);font-weight:var(--wcss-heading-xs-weight, 300);line-height:var(--wcss-heading-xs-line-height, 1.3);font-size:var(--wcss-heading-xs-font-size, clamp(1.25rem, 1.6666666667vw, 1.25rem));letter-spacing:var(--wcss-heading-xs-letter-spacing, 0)}.heading-2xs{font-family:var(--wcss-heading-2xs-family, "AS Circular"),var(--wcss-heading-2xs-family-fallback, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif);font-weight:var(--wcss-heading-2xs-weight, 300);line-height:var(--wcss-heading-2xs-line-height, 1.3);font-size:var(--wcss-heading-2xs-font-size, clamp(1.125rem, 1.5vw, 1.125rem));letter-spacing:var(--wcss-heading-2xs-letter-spacing, 0)}.accent-2xl{font-family:var(--wcss-accent-2xl-family, "Good OT"),var(--wcss-accent-2xl-family-fallback, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif);font-weight:var(--wcss-accent-2xl-weight, 450);line-height:var(--wcss-accent-2xl-line-height, 1);font-size:var(--wcss-accent-2xl-font-size, clamp(2rem, 3.1666666667vw, 2.375rem));letter-spacing:var(--wcss-accent-2xl-letter-spacing, 0.05em);text-transform:uppercase}.accent-xl{font-family:var(--wcss-accent-xl-family, "Good OT"),var(--wcss-accent-xl-family-fallback, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif);font-weight:var(--wcss-accent-xl-weight, 450);line-height:var(--wcss-accent-xl-line-height, 1.3);font-size:var(--wcss-accent-xl-font-size, clamp(1.625rem, 2.3333333333vw, 2rem));letter-spacing:var(--wcss-accent-xl-letter-spacing, 0.05em);text-transform:uppercase}.accent-lg{font-family:var(--wcss-accent-lg-family, "Good OT"),var(--wcss-accent-lg-family-fallback, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif);font-weight:var(--wcss-accent-lg-weight, 450);line-height:var(--wcss-accent-lg-line-height, 1.3);font-size:var(--wcss-accent-lg-font-size, clamp(1.5rem, 2.1666666667vw, 1.75rem));letter-spacing:var(--wcss-accent-lg-letter-spacing, 0.05em);text-transform:uppercase}.accent-md{font-family:var(--wcss-accent-md-family, "Good OT"),var(--wcss-accent-md-family-fallback, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif);font-weight:var(--wcss-accent-md-weight, 500);line-height:var(--wcss-accent-md-line-height, 1.3);font-size:var(--wcss-accent-md-font-size, clamp(1.375rem, 1.8333333333vw, 1.5rem));letter-spacing:var(--wcss-accent-md-letter-spacing, 0.05em);text-transform:uppercase}.accent-sm{font-family:var(--wcss-accent-sm-family, "Good OT"),var(--wcss-accent-sm-family-fallback, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif);font-weight:var(--wcss-accent-sm-weight, 500);line-height:var(--wcss-accent-sm-line-height, 1.3);font-size:var(--wcss-accent-sm-font-size, clamp(1.125rem, 1.5vw, 1.25rem));letter-spacing:var(--wcss-accent-sm-letter-spacing, 0.05em);text-transform:uppercase}.accent-xs{font-family:var(--wcss-accent-xs-family, "Good OT"),var(--wcss-accent-xs-family-fallback, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif);font-weight:var(--wcss-accent-xs-weight, 500);line-height:var(--wcss-accent-xs-line-height, 1.3);font-size:var(--wcss-accent-xs-font-size, clamp(1rem, 1.3333333333vw, 1rem));letter-spacing:var(--wcss-accent-xs-letter-spacing, 0.1em);text-transform:uppercase}.accent-2xs{font-family:var(--wcss-accent-2xs-family, "Good OT"),var(--wcss-accent-2xs-family-fallback, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif);font-weight:var(--wcss-accent-2xs-weight, 450);line-height:var(--wcss-accent-2xs-line-height, 1.3);font-size:var(--wcss-accent-2xs-font-size, clamp(0.875rem, 1.1666666667vw, 0.875rem));letter-spacing:var(--wcss-accent-2xs-letter-spacing, 0.1em);text-transform:uppercase}:host{position:relative;display:block;width:calc(100% - var(--ds-size-200, 1rem) - var(--ds-size-200, 1rem));margin:0 var(--ds-size-200, 1rem)}@media screen and (min-width: 576px){:host{width:336px;padding:var(--ds-size-200, 1rem) var(--ds-size-200, 1rem) 0}}@media screen and (min-width: 576px){:host(:not(:last-of-type)):after{position:absolute;top:var(--ds-size-200, 1rem);right:calc(-1*var(--ds-size-200, 1rem));height:calc(100% - var(--ds-size-200, 1rem) - var(--ds-size-200, 1rem));display:block;width:1px;content:""}}.header{display:flex;height:var(--ds-size-500, 2.5rem);margin-bottom:var(--ds-size-150, 0.75rem);align-items:center;flex-direction:row;text-align:center}.headerTitle{display:flex;align-items:center;flex:1;flex-direction:row;justify-content:center}.headerTitle div:first-child{margin-right:var(--ds-size-100, 0.5rem)}.calendarNavBtn{position:relative;display:flex;width:var(--ds-size-500, 2.5rem);height:var(--ds-size-500, 2.5rem);align-items:center;justify-content:center;border-width:1px;border-style:solid;border-radius:50%;cursor:pointer}.table{width:100%;border-collapse:collapse}.thead{margin-bottom:var(--ds-size-100, 0.5rem)}.th{display:flex;flex:1;align-items:center;justify-content:center}.th abbr{text-decoration:none}.tbody{width:100%;transition:all 0ms;transform:translateX(0)}@media screen and (min-width: 576px){.tbody{height:336px}}.td{flex:1;margin:0;padding:0}.tr{display:flex;flex-direction:row;width:100%;border-radius:10px;overflow:hidden}.tr:not(:last-of-type){margin-bottom:var(--ds-size-100, 0.5rem)}`;
|
|
7293
|
+
|
|
7294
|
+
var colorCss$6 = i$3`:focus:not(:focus-visible){outline:3px solid transparent}:host{background-color:var(--ds-auro-calendar-month-container-color)}@media screen and (min-width: 576px){:host(:not(:last-of-type)):after{background-color:var(--ds-auro-calendar-month-divider-color)}}.header{color:var(--ds-auro-calendar-month-header-color)}`;
|
|
7295
|
+
|
|
7296
|
+
/******************************************************************************
|
|
7297
|
+
Copyright (c) Microsoft Corporation.
|
|
7298
|
+
|
|
7299
|
+
Permission to use, copy, modify, and/or distribute this software for any
|
|
7300
|
+
purpose with or without fee is hereby granted.
|
|
7301
|
+
|
|
7302
|
+
THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES WITH
|
|
7303
|
+
REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY
|
|
7304
|
+
AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY SPECIAL, DIRECT,
|
|
7305
|
+
INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM
|
|
7306
|
+
LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE OR
|
|
7307
|
+
OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR
|
|
7308
|
+
PERFORMANCE OF THIS SOFTWARE.
|
|
7309
|
+
***************************************************************************** */
|
|
7310
|
+
/* global Reflect, Promise, SuppressedError, Symbol, Iterator */
|
|
7311
|
+
|
|
7312
|
+
|
|
7313
|
+
function __decorate(decorators, target, key, desc) {
|
|
7314
|
+
var c = arguments.length, r = c < 3 ? target : desc === null ? desc = Object.getOwnPropertyDescriptor(target, key) : desc, d;
|
|
7315
|
+
if (typeof Reflect === "object" && typeof Reflect.decorate === "function") r = Reflect.decorate(decorators, target, key, desc);
|
|
7316
|
+
else for (var i = decorators.length - 1; i >= 0; i--) if (d = decorators[i]) r = (c < 3 ? d(r) : c > 3 ? d(target, key, r) : d(target, key)) || r;
|
|
7317
|
+
return c > 3 && r && Object.defineProperty(target, key, r), r;
|
|
7318
|
+
}
|
|
7319
|
+
|
|
7320
|
+
typeof SuppressedError === "function" ? SuppressedError : function (error, suppressed, message) {
|
|
7321
|
+
var e = new Error(message);
|
|
7322
|
+
return e.name = "SuppressedError", e.error = error, e.suppressed = suppressed, e;
|
|
7323
|
+
};
|
|
7324
|
+
|
|
7325
|
+
/**
|
|
7326
|
+
* @license
|
|
7327
|
+
* Copyright 2017 Google LLC
|
|
7328
|
+
* SPDX-License-Identifier: BSD-3-Clause
|
|
7329
|
+
*/const o$4={attribute:true,type:String,converter:u$9,reflect:false,hasChanged:f$8},r$4=(t=o$4,e,r)=>{const{kind:n,metadata:i}=r;let s=globalThis.litPropertyMetadata.get(i);if(void 0===s&&globalThis.litPropertyMetadata.set(i,s=new Map),"setter"===n&&((t=Object.create(t)).wrapped=true),s.set(r.name,t),"accessor"===n){const{name:o}=r;return {set(r){const n=e.get.call(this);e.set.call(this,r),this.requestUpdate(o,n,t,true,r);},init(e){return void 0!==e&&this.C(o,void 0,t,e),e}}}if("setter"===n){const{name:o}=r;return function(r){const n=this[o];e.call(this,r),this.requestUpdate(o,n,t,true,r);}}throw Error("Unsupported decorator location: "+n)};function n$4(t){return (e,o)=>"object"==typeof o?r$4(t,e,o):((t,e,o)=>{const r=e.hasOwnProperty(o);return e.constructor.createProperty(o,t),r?Object.getOwnPropertyDescriptor(e,o):void 0})(t,e,o)}
|
|
7330
|
+
|
|
7211
7331
|
class RangeDatepickerCell extends i$1 {
|
|
7212
7332
|
constructor() {
|
|
7213
7333
|
super(...arguments);
|
|
@@ -7930,9 +8050,9 @@ __decorate([n$4({ type: Array })], RangeDatepickerCalendar.prototype, "dayNamesO
|
|
|
7930
8050
|
__decorate([n$4({ type: Array })], RangeDatepickerCalendar.prototype, "daysOfMonth", void 0);
|
|
7931
8051
|
AuroLibraryRuntimeUtils$5.prototype.registerComponent('wc-range-datepicker-calendar', RangeDatepickerCalendar);
|
|
7932
8052
|
|
|
7933
|
-
var styleCss$5 = i$3`.body-default{font-family:var(--wcss-body-family, "AS Circular"),system-ui,-apple-system,BlinkMacSystemFont,"Segoe UI",Roboto,"Helvetica Neue",Arial,sans-serif;font-weight:var(--wcss-body-default-weight, );letter-spacing:var(--wcss-body-letter-spacing, 0);font-size:var(--wcss-body-default-font-size, 1rem);line-height:var(--wcss-body-default-line-height, 1.5rem)}.body-default-emphasized{font-family:var(--wcss-body-family, "AS Circular"),system-ui,-apple-system,BlinkMacSystemFont,"Segoe UI",Roboto,"Helvetica Neue",Arial,sans-serif;font-weight:var(--wcss-body-default-emphasized-weight, );letter-spacing:var(--wcss-body-letter-spacing, 0);font-size:var(--wcss-body-default-emphasized-font-size, 1rem);line-height:var(--wcss-body-default-emphasized-line-height, 1.5rem)}.body-lg{font-family:var(--wcss-body-family, "AS Circular"),system-ui,-apple-system,BlinkMacSystemFont,"Segoe UI",Roboto,"Helvetica Neue",Arial,sans-serif;font-weight:var(--wcss-body-lg-weight, );letter-spacing:var(--wcss-body-letter-spacing, 0);font-size:var(--wcss-body-lg-font-size, 1.125rem);line-height:var(--wcss-body-lg-line-height, 1.625rem)}.body-lg-emphasized{font-family:var(--wcss-body-family, "AS Circular"),system-ui,-apple-system,BlinkMacSystemFont,"Segoe UI",Roboto,"Helvetica Neue",Arial,sans-serif;font-weight:var(--wcss-body-lg-emphasized-weight, );letter-spacing:var(--wcss-body-letter-spacing, 0);font-size:var(--wcss-body-lg-emphasized-font-size, 1.125rem);line-height:var(--wcss-body-lg-emphasized-line-height, 1.625rem)}.body-sm{font-family:var(--wcss-body-family, "AS Circular"),system-ui,-apple-system,BlinkMacSystemFont,"Segoe UI",Roboto,"Helvetica Neue",Arial,sans-serif;font-weight:var(--wcss-body-sm-weight, );letter-spacing:var(--wcss-body-letter-spacing, 0);font-size:var(--wcss-body-sm-font-size, 0.875rem);line-height:var(--wcss-body-sm-line-height, 1.25rem)}.body-sm-emphasized{font-family:var(--wcss-body-family, "AS Circular"),system-ui,-apple-system,BlinkMacSystemFont,"Segoe UI",Roboto,"Helvetica Neue",Arial,sans-serif;font-weight:var(--wcss-body-sm-emphasized-weight, );letter-spacing:var(--wcss-body-letter-spacing, 0);font-size:var(--wcss-body-sm-emphasized-font-size, 0.875rem);line-height:var(--wcss-body-sm-emphasized-line-height, 1.25rem)}.body-xs{font-family:var(--wcss-body-family, "AS Circular"),system-ui,-apple-system,BlinkMacSystemFont,"Segoe UI",Roboto,"Helvetica Neue",Arial,sans-serif;font-weight:var(--wcss-body-xs-weight, );letter-spacing:var(--wcss-body-letter-spacing, 0);font-size:var(--wcss-body-xs-font-size, 0.75rem);line-height:var(--wcss-body-xs-line-height, 1rem)}.body-xs-emphasized{font-family:var(--wcss-body-family, "AS Circular"),system-ui,-apple-system,BlinkMacSystemFont,"Segoe UI",Roboto,"Helvetica Neue",Arial,sans-serif;font-weight:var(--wcss-body-xs-emphasized-weight, );letter-spacing:var(--wcss-body-letter-spacing, 0);font-size:var(--wcss-body-xs-emphasized-font-size, 0.75rem);line-height:var(--wcss-body-xs-emphasized-line-height, 1rem)}.body-2xs{font-family:var(--wcss-body-family, "AS Circular"),system-ui,-apple-system,BlinkMacSystemFont,"Segoe UI",Roboto,"Helvetica Neue",Arial,sans-serif;font-weight:var(--wcss-body-2xs-weight, );letter-spacing:var(--wcss-body-letter-spacing, 0);font-size:var(--wcss-body-2xs-font-size, 0.625rem);line-height:var(--wcss-body-2xs-line-height, 0.875rem)}.body-2xs-emphasized{font-family:var(--wcss-body-family, "AS Circular"),system-ui,-apple-system,BlinkMacSystemFont,"Segoe UI",Roboto,"Helvetica Neue",Arial,sans-serif;font-weight:var(--wcss-body-2xs-emphasized-weight, );letter-spacing:var(--wcss-body-letter-spacing, 0);font-size:var(--wcss-body-2xs-emphasized-font-size, 0.625rem);line-height:var(--wcss-body-2xs-emphasized-line-height, 0.875rem)}.display-2xl{font-family:var(--wcss-display-2xl-family, "AS Circular"),var(--wcss-display-2xl-family-fallback, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif);font-weight:var(--wcss-display-2xl-weight, 300);line-height:var(--wcss-display-2xl-line-height, 1.3);font-size:var(--wcss-display-2xl-font-size, clamp(3.5rem, 6vw, 5.375rem));letter-spacing:var(--wcss-display-2xl-letter-spacing, 0)}.display-xl{font-family:var(--wcss-display-xl-family, "AS Circular"),var(--wcss-display-xl-family-fallback, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif);font-weight:var(--wcss-display-xl-weight, 300);line-height:var(--wcss-display-xl-line-height, 1.3);font-size:var(--wcss-display-xl-font-size, clamp(3rem, 5.3333333333vw, 4.5rem));letter-spacing:var(--wcss-display-xl-letter-spacing, 0)}.display-lg{font-family:var(--wcss-display-lg-family, "AS Circular"),var(--wcss-display-lg-family-fallback, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif);font-weight:var(--wcss-display-lg-weight, 300);line-height:var(--wcss-display-lg-line-height, 1.3);font-size:var(--wcss-display-lg-font-size, clamp(2.75rem, 4.6666666667vw, 4rem));letter-spacing:var(--wcss-display-lg-letter-spacing, 0)}.display-md{font-family:var(--wcss-display-md-family, "AS Circular"),var(--wcss-display-md-family-fallback, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif);font-weight:var(--wcss-display-md-weight, 300);line-height:var(--wcss-display-md-line-height, 1.3);font-size:var(--wcss-display-md-font-size, clamp(2.5rem, 4vw, 3.5rem));letter-spacing:var(--wcss-display-md-letter-spacing, 0)}.display-sm{font-family:var(--wcss-display-sm-family, "AS Circular"),var(--wcss-display-sm-family-fallback, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif);font-weight:var(--wcss-display-sm-weight, 300);line-height:var(--wcss-display-sm-line-height, 1.3);font-size:var(--wcss-display-sm-font-size, clamp(2rem, 3.6666666667vw, 3rem));letter-spacing:var(--wcss-display-sm-letter-spacing, 0)}.display-xs{font-family:var(--wcss-display-xs-family, "AS Circular"),var(--wcss-display-xs-family-fallback, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif);font-weight:var(--wcss-display-xs-weight, 300);line-height:var(--wcss-display-xs-line-height, 1.3);font-size:var(--wcss-display-xs-font-size, clamp(1.75rem, 3vw, 2.375rem));letter-spacing:var(--wcss-display-xs-letter-spacing, 0)}.heading-xl{font-family:var(--wcss-heading-xl-family, "AS Circular"),var(--wcss-heading-xl-family-fallback, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif);font-weight:var(--wcss-heading-xl-weight, 300);line-height:var(--wcss-heading-xl-line-height, 1.3);font-size:var(--wcss-heading-xl-font-size, clamp(2rem, 3vw, 2.5rem));letter-spacing:var(--wcss-heading-xl-letter-spacing, 0)}.heading-lg{font-family:var(--wcss-heading-lg-family, "AS Circular"),var(--wcss-heading-lg-family-fallback, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif);font-weight:var(--wcss-heading-lg-weight, 300);line-height:var(--wcss-heading-lg-line-height, 1.3);font-size:var(--wcss-heading-lg-font-size, clamp(1.75rem, 2.6666666667vw, 2.25rem));letter-spacing:var(--wcss-heading-lg-letter-spacing, 0)}.heading-md{font-family:var(--wcss-heading-md-family, "AS Circular"),var(--wcss-heading-md-family-fallback, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif);font-weight:var(--wcss-heading-md-weight, 300);line-height:var(--wcss-heading-md-line-height, 1.3);font-size:var(--wcss-heading-md-font-size, clamp(1.625rem, 2.3333333333vw, 1.75rem));letter-spacing:var(--wcss-heading-md-letter-spacing, 0)}.heading-sm{font-family:var(--wcss-heading-sm-family, "AS Circular"),var(--wcss-heading-sm-family-fallback, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif);font-weight:var(--wcss-heading-sm-weight, 300);line-height:var(--wcss-heading-sm-line-height, 1.3);font-size:var(--wcss-heading-sm-font-size, clamp(1.375rem, 2vw, 1.5rem));letter-spacing:var(--wcss-heading-sm-letter-spacing, 0)}.heading-xs{font-family:var(--wcss-heading-xs-family, "AS Circular"),var(--wcss-heading-xs-family-fallback, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif);font-weight:var(--wcss-heading-xs-weight, 300);line-height:var(--wcss-heading-xs-line-height, 1.3);font-size:var(--wcss-heading-xs-font-size, clamp(1.25rem, 1.6666666667vw, 1.25rem));letter-spacing:var(--wcss-heading-xs-letter-spacing, 0)}.heading-2xs{font-family:var(--wcss-heading-2xs-family, "AS Circular"),var(--wcss-heading-2xs-family-fallback, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif);font-weight:var(--wcss-heading-2xs-weight, 300);line-height:var(--wcss-heading-2xs-line-height, 1.3);font-size:var(--wcss-heading-2xs-font-size, clamp(1.125rem, 1.5vw, 1.125rem));letter-spacing:var(--wcss-heading-2xs-letter-spacing, 0)}.accent-2xl{font-family:var(--wcss-accent-2xl-family, "Good OT"),var(--wcss-accent-2xl-family-fallback, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif);font-weight:var(--wcss-accent-2xl-weight, 450);line-height:var(--wcss-accent-2xl-line-height, 1);font-size:var(--wcss-accent-2xl-font-size, clamp(2rem, 3.1666666667vw, 2.375rem));letter-spacing:var(--wcss-accent-2xl-letter-spacing, 0.05em);text-transform:uppercase}.accent-xl{font-family:var(--wcss-accent-xl-family, "Good OT"),var(--wcss-accent-xl-family-fallback, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif);font-weight:var(--wcss-accent-xl-weight, 450);line-height:var(--wcss-accent-xl-line-height, 1.3);font-size:var(--wcss-accent-xl-font-size, clamp(1.625rem, 2.3333333333vw, 2rem));letter-spacing:var(--wcss-accent-xl-letter-spacing, 0.05em);text-transform:uppercase}.accent-lg{font-family:var(--wcss-accent-lg-family, "Good OT"),var(--wcss-accent-lg-family-fallback, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif);font-weight:var(--wcss-accent-lg-weight, 450);line-height:var(--wcss-accent-lg-line-height, 1.3);font-size:var(--wcss-accent-lg-font-size, clamp(1.5rem, 2.1666666667vw, 1.75rem));letter-spacing:var(--wcss-accent-lg-letter-spacing, 0.05em);text-transform:uppercase}.accent-md{font-family:var(--wcss-accent-md-family, "Good OT"),var(--wcss-accent-md-family-fallback, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif);font-weight:var(--wcss-accent-md-weight, 500);line-height:var(--wcss-accent-md-line-height, 1.3);font-size:var(--wcss-accent-md-font-size, clamp(1.375rem, 1.8333333333vw, 1.5rem));letter-spacing:var(--wcss-accent-md-letter-spacing, 0.05em);text-transform:uppercase}.accent-sm{font-family:var(--wcss-accent-sm-family, "Good OT"),var(--wcss-accent-sm-family-fallback, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif);font-weight:var(--wcss-accent-sm-weight, 500);line-height:var(--wcss-accent-sm-line-height, 1.3);font-size:var(--wcss-accent-sm-font-size, clamp(1.125rem, 1.5vw, 1.25rem));letter-spacing:var(--wcss-accent-sm-letter-spacing, 0.05em);text-transform:uppercase}.accent-xs{font-family:var(--wcss-accent-xs-family, "Good OT"),var(--wcss-accent-xs-family-fallback, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif);font-weight:var(--wcss-accent-xs-weight, 500);line-height:var(--wcss-accent-xs-line-height, 1.3);font-size:var(--wcss-accent-xs-font-size, clamp(1rem, 1.3333333333vw, 1rem));letter-spacing:var(--wcss-accent-xs-letter-spacing, 0.1em);text-transform:uppercase}.accent-2xs{font-family:var(--wcss-accent-2xs-family, "Good OT"),var(--wcss-accent-2xs-family-fallback, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif);font-weight:var(--wcss-accent-2xs-weight, 450);line-height:var(--wcss-accent-2xs-line-height, 1.3);font-size:var(--wcss-accent-2xs-font-size, clamp(0.875rem, 1.1666666667vw, 0.875rem));letter-spacing:var(--wcss-accent-2xs-letter-spacing, 0.1em);text-transform:uppercase}@media screen and (max-width: 576px){:host{display:flex;justify-content:center}}.day{position:relative;width:var(--ds-size-500, 2.5rem);height:calc(var(--ds-size-700, 3.5rem) - 2px);padding:0;border-width:1px;border-style:solid;border-radius:var(--ds-size-300, 1.5rem);cursor:pointer;user-select:none}.day:focus-visible{outline:2px solid var(--ds-basic-color-border-default, #959595);outline-offset:2px}.day.disabled{cursor:default !important;pointer-events:none}.day.blackout{cursor:default}.day.reference{box-shadow:inset 0 0 0 2px var(--ds-advanced-color-shared-background, #ffffff)}.day.inRange::before{position:absolute;z-index:-1;top:50%;left:50%;display:block;width:14.2857142857vw;height:var(--ds-size-600, 3rem);content:"";transform:translate(-50%, -50%)}@media screen and (min-width: 576px){.day.inRange::before{width:var(--ds-size-600, 3rem)}}.day.rangeDepartDate::before{position:absolute;z-index:-1;top:50%;left:50%;display:block;width:14.2857142857vw;height:var(--ds-size-600, 3rem);content:"";transform:translate(-50%, -50%);width:7.1428571429vw;transform:translate(0%, -50%)}@media screen and (min-width: 576px){.day.rangeDepartDate::before{width:calc(var(--ds-size-600, 3rem)/2)}}.day.rangeReturnDate::before,.day.lastHoveredDate::before{position:absolute;z-index:-1;top:50%;left:50%;display:block;width:14.2857142857vw;height:var(--ds-size-600, 3rem);content:"";transform:translate(-50%, -50%);width:7.1428571429vw;transform:translate(-100%, -50%)}@media screen and (min-width: 576px){.day.rangeReturnDate::before,.day.lastHoveredDate::before{width:calc(var(--ds-size-600, 3rem)/2)}}.dateSlot{display:flex;flex-direction:column}.srOnly{position:absolute;overflow:hidden;width:1px;height:1px;padding:0;border:0;clip:rect(0, 0, 0, 0);white-space:nowrap}::slotted([slot^=date_]){position:absolute;top:80%;left:50%;width:100%;white-space:nowrap;transform:translate(-50%, -50%)}::slotted(auro-icon){max-height:24px;max-width:24px}:host([renderForDateSlot]) .buttonWrapper{position:relative;width:100%;top:5px}:host([renderForDateSlot]) .currentDayMarker{position:relative;padding-bottom:5px;top:-8px}@media screen and (min-width: 576px){.day{width:var(--ds-size-600, 3rem);height:var(--ds-size-800, 4rem)}.day:hover{cursor:pointer}}`;
|
|
8053
|
+
var styleCss$5 = i$3`.body-default{font-family:var(--wcss-body-family, "AS Circular"),system-ui,-apple-system,BlinkMacSystemFont,"Segoe UI",Roboto,"Helvetica Neue",Arial,sans-serif;font-weight:var(--wcss-body-default-weight, );letter-spacing:var(--wcss-body-letter-spacing, 0);font-size:var(--wcss-body-default-font-size, 1rem);line-height:var(--wcss-body-default-line-height, 1.5rem)}.body-default-emphasized{font-family:var(--wcss-body-family, "AS Circular"),system-ui,-apple-system,BlinkMacSystemFont,"Segoe UI",Roboto,"Helvetica Neue",Arial,sans-serif;font-weight:var(--wcss-body-default-emphasized-weight, );letter-spacing:var(--wcss-body-letter-spacing, 0);font-size:var(--wcss-body-default-emphasized-font-size, 1rem);line-height:var(--wcss-body-default-emphasized-line-height, 1.5rem)}.body-lg{font-family:var(--wcss-body-family, "AS Circular"),system-ui,-apple-system,BlinkMacSystemFont,"Segoe UI",Roboto,"Helvetica Neue",Arial,sans-serif;font-weight:var(--wcss-body-lg-weight, );letter-spacing:var(--wcss-body-letter-spacing, 0);font-size:var(--wcss-body-lg-font-size, 1.125rem);line-height:var(--wcss-body-lg-line-height, 1.625rem)}.body-lg-emphasized{font-family:var(--wcss-body-family, "AS Circular"),system-ui,-apple-system,BlinkMacSystemFont,"Segoe UI",Roboto,"Helvetica Neue",Arial,sans-serif;font-weight:var(--wcss-body-lg-emphasized-weight, );letter-spacing:var(--wcss-body-letter-spacing, 0);font-size:var(--wcss-body-lg-emphasized-font-size, 1.125rem);line-height:var(--wcss-body-lg-emphasized-line-height, 1.625rem)}.body-sm{font-family:var(--wcss-body-family, "AS Circular"),system-ui,-apple-system,BlinkMacSystemFont,"Segoe UI",Roboto,"Helvetica Neue",Arial,sans-serif;font-weight:var(--wcss-body-sm-weight, );letter-spacing:var(--wcss-body-letter-spacing, 0);font-size:var(--wcss-body-sm-font-size, 0.875rem);line-height:var(--wcss-body-sm-line-height, 1.25rem)}.body-sm-emphasized{font-family:var(--wcss-body-family, "AS Circular"),system-ui,-apple-system,BlinkMacSystemFont,"Segoe UI",Roboto,"Helvetica Neue",Arial,sans-serif;font-weight:var(--wcss-body-sm-emphasized-weight, );letter-spacing:var(--wcss-body-letter-spacing, 0);font-size:var(--wcss-body-sm-emphasized-font-size, 0.875rem);line-height:var(--wcss-body-sm-emphasized-line-height, 1.25rem)}.body-xs{font-family:var(--wcss-body-family, "AS Circular"),system-ui,-apple-system,BlinkMacSystemFont,"Segoe UI",Roboto,"Helvetica Neue",Arial,sans-serif;font-weight:var(--wcss-body-xs-weight, );letter-spacing:var(--wcss-body-letter-spacing, 0);font-size:var(--wcss-body-xs-font-size, 0.75rem);line-height:var(--wcss-body-xs-line-height, 1rem)}.body-xs-emphasized{font-family:var(--wcss-body-family, "AS Circular"),system-ui,-apple-system,BlinkMacSystemFont,"Segoe UI",Roboto,"Helvetica Neue",Arial,sans-serif;font-weight:var(--wcss-body-xs-emphasized-weight, );letter-spacing:var(--wcss-body-letter-spacing, 0);font-size:var(--wcss-body-xs-emphasized-font-size, 0.75rem);line-height:var(--wcss-body-xs-emphasized-line-height, 1rem)}.body-2xs{font-family:var(--wcss-body-family, "AS Circular"),system-ui,-apple-system,BlinkMacSystemFont,"Segoe UI",Roboto,"Helvetica Neue",Arial,sans-serif;font-weight:var(--wcss-body-2xs-weight, );letter-spacing:var(--wcss-body-letter-spacing, 0);font-size:var(--wcss-body-2xs-font-size, 0.625rem);line-height:var(--wcss-body-2xs-line-height, 0.875rem)}.body-2xs-emphasized{font-family:var(--wcss-body-family, "AS Circular"),system-ui,-apple-system,BlinkMacSystemFont,"Segoe UI",Roboto,"Helvetica Neue",Arial,sans-serif;font-weight:var(--wcss-body-2xs-emphasized-weight, );letter-spacing:var(--wcss-body-letter-spacing, 0);font-size:var(--wcss-body-2xs-emphasized-font-size, 0.625rem);line-height:var(--wcss-body-2xs-emphasized-line-height, 0.875rem)}.display-2xl{font-family:var(--wcss-display-2xl-family, "AS Circular"),var(--wcss-display-2xl-family-fallback, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif);font-weight:var(--wcss-display-2xl-weight, 300);line-height:var(--wcss-display-2xl-line-height, 1.3);font-size:var(--wcss-display-2xl-font-size, clamp(3.5rem, 6vw, 5.375rem));letter-spacing:var(--wcss-display-2xl-letter-spacing, 0)}.display-xl{font-family:var(--wcss-display-xl-family, "AS Circular"),var(--wcss-display-xl-family-fallback, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif);font-weight:var(--wcss-display-xl-weight, 300);line-height:var(--wcss-display-xl-line-height, 1.3);font-size:var(--wcss-display-xl-font-size, clamp(3rem, 5.3333333333vw, 4.5rem));letter-spacing:var(--wcss-display-xl-letter-spacing, 0)}.display-lg{font-family:var(--wcss-display-lg-family, "AS Circular"),var(--wcss-display-lg-family-fallback, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif);font-weight:var(--wcss-display-lg-weight, 300);line-height:var(--wcss-display-lg-line-height, 1.3);font-size:var(--wcss-display-lg-font-size, clamp(2.75rem, 4.6666666667vw, 4rem));letter-spacing:var(--wcss-display-lg-letter-spacing, 0)}.display-md{font-family:var(--wcss-display-md-family, "AS Circular"),var(--wcss-display-md-family-fallback, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif);font-weight:var(--wcss-display-md-weight, 300);line-height:var(--wcss-display-md-line-height, 1.3);font-size:var(--wcss-display-md-font-size, clamp(2.5rem, 4vw, 3.5rem));letter-spacing:var(--wcss-display-md-letter-spacing, 0)}.display-sm{font-family:var(--wcss-display-sm-family, "AS Circular"),var(--wcss-display-sm-family-fallback, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif);font-weight:var(--wcss-display-sm-weight, 300);line-height:var(--wcss-display-sm-line-height, 1.3);font-size:var(--wcss-display-sm-font-size, clamp(2rem, 3.6666666667vw, 3rem));letter-spacing:var(--wcss-display-sm-letter-spacing, 0)}.display-xs{font-family:var(--wcss-display-xs-family, "AS Circular"),var(--wcss-display-xs-family-fallback, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif);font-weight:var(--wcss-display-xs-weight, 300);line-height:var(--wcss-display-xs-line-height, 1.3);font-size:var(--wcss-display-xs-font-size, clamp(1.75rem, 3vw, 2.375rem));letter-spacing:var(--wcss-display-xs-letter-spacing, 0)}.heading-xl{font-family:var(--wcss-heading-xl-family, "AS Circular"),var(--wcss-heading-xl-family-fallback, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif);font-weight:var(--wcss-heading-xl-weight, 300);line-height:var(--wcss-heading-xl-line-height, 1.3);font-size:var(--wcss-heading-xl-font-size, clamp(2rem, 3vw, 2.5rem));letter-spacing:var(--wcss-heading-xl-letter-spacing, 0)}.heading-lg{font-family:var(--wcss-heading-lg-family, "AS Circular"),var(--wcss-heading-lg-family-fallback, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif);font-weight:var(--wcss-heading-lg-weight, 300);line-height:var(--wcss-heading-lg-line-height, 1.3);font-size:var(--wcss-heading-lg-font-size, clamp(1.75rem, 2.6666666667vw, 2.25rem));letter-spacing:var(--wcss-heading-lg-letter-spacing, 0)}.heading-md{font-family:var(--wcss-heading-md-family, "AS Circular"),var(--wcss-heading-md-family-fallback, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif);font-weight:var(--wcss-heading-md-weight, 300);line-height:var(--wcss-heading-md-line-height, 1.3);font-size:var(--wcss-heading-md-font-size, clamp(1.625rem, 2.3333333333vw, 1.75rem));letter-spacing:var(--wcss-heading-md-letter-spacing, 0)}.heading-sm{font-family:var(--wcss-heading-sm-family, "AS Circular"),var(--wcss-heading-sm-family-fallback, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif);font-weight:var(--wcss-heading-sm-weight, 300);line-height:var(--wcss-heading-sm-line-height, 1.3);font-size:var(--wcss-heading-sm-font-size, clamp(1.375rem, 2vw, 1.5rem));letter-spacing:var(--wcss-heading-sm-letter-spacing, 0)}.heading-xs{font-family:var(--wcss-heading-xs-family, "AS Circular"),var(--wcss-heading-xs-family-fallback, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif);font-weight:var(--wcss-heading-xs-weight, 300);line-height:var(--wcss-heading-xs-line-height, 1.3);font-size:var(--wcss-heading-xs-font-size, clamp(1.25rem, 1.6666666667vw, 1.25rem));letter-spacing:var(--wcss-heading-xs-letter-spacing, 0)}.heading-2xs{font-family:var(--wcss-heading-2xs-family, "AS Circular"),var(--wcss-heading-2xs-family-fallback, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif);font-weight:var(--wcss-heading-2xs-weight, 300);line-height:var(--wcss-heading-2xs-line-height, 1.3);font-size:var(--wcss-heading-2xs-font-size, clamp(1.125rem, 1.5vw, 1.125rem));letter-spacing:var(--wcss-heading-2xs-letter-spacing, 0)}.accent-2xl{font-family:var(--wcss-accent-2xl-family, "Good OT"),var(--wcss-accent-2xl-family-fallback, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif);font-weight:var(--wcss-accent-2xl-weight, 450);line-height:var(--wcss-accent-2xl-line-height, 1);font-size:var(--wcss-accent-2xl-font-size, clamp(2rem, 3.1666666667vw, 2.375rem));letter-spacing:var(--wcss-accent-2xl-letter-spacing, 0.05em);text-transform:uppercase}.accent-xl{font-family:var(--wcss-accent-xl-family, "Good OT"),var(--wcss-accent-xl-family-fallback, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif);font-weight:var(--wcss-accent-xl-weight, 450);line-height:var(--wcss-accent-xl-line-height, 1.3);font-size:var(--wcss-accent-xl-font-size, clamp(1.625rem, 2.3333333333vw, 2rem));letter-spacing:var(--wcss-accent-xl-letter-spacing, 0.05em);text-transform:uppercase}.accent-lg{font-family:var(--wcss-accent-lg-family, "Good OT"),var(--wcss-accent-lg-family-fallback, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif);font-weight:var(--wcss-accent-lg-weight, 450);line-height:var(--wcss-accent-lg-line-height, 1.3);font-size:var(--wcss-accent-lg-font-size, clamp(1.5rem, 2.1666666667vw, 1.75rem));letter-spacing:var(--wcss-accent-lg-letter-spacing, 0.05em);text-transform:uppercase}.accent-md{font-family:var(--wcss-accent-md-family, "Good OT"),var(--wcss-accent-md-family-fallback, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif);font-weight:var(--wcss-accent-md-weight, 500);line-height:var(--wcss-accent-md-line-height, 1.3);font-size:var(--wcss-accent-md-font-size, clamp(1.375rem, 1.8333333333vw, 1.5rem));letter-spacing:var(--wcss-accent-md-letter-spacing, 0.05em);text-transform:uppercase}.accent-sm{font-family:var(--wcss-accent-sm-family, "Good OT"),var(--wcss-accent-sm-family-fallback, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif);font-weight:var(--wcss-accent-sm-weight, 500);line-height:var(--wcss-accent-sm-line-height, 1.3);font-size:var(--wcss-accent-sm-font-size, clamp(1.125rem, 1.5vw, 1.25rem));letter-spacing:var(--wcss-accent-sm-letter-spacing, 0.05em);text-transform:uppercase}.accent-xs{font-family:var(--wcss-accent-xs-family, "Good OT"),var(--wcss-accent-xs-family-fallback, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif);font-weight:var(--wcss-accent-xs-weight, 500);line-height:var(--wcss-accent-xs-line-height, 1.3);font-size:var(--wcss-accent-xs-font-size, clamp(1rem, 1.3333333333vw, 1rem));letter-spacing:var(--wcss-accent-xs-letter-spacing, 0.1em);text-transform:uppercase}.accent-2xs{font-family:var(--wcss-accent-2xs-family, "Good OT"),var(--wcss-accent-2xs-family-fallback, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif);font-weight:var(--wcss-accent-2xs-weight, 450);line-height:var(--wcss-accent-2xs-line-height, 1.3);font-size:var(--wcss-accent-2xs-font-size, clamp(0.875rem, 1.1666666667vw, 0.875rem));letter-spacing:var(--wcss-accent-2xs-letter-spacing, 0.1em);text-transform:uppercase}@media screen and (max-width: 576px){:host{display:flex;justify-content:center}}.day{position:relative;width:48px;height:56px;padding:0;border-width:2px;border-style:solid;border-radius:10px;cursor:pointer;user-select:none}.day:focus-visible{outline:none;background-color:unset}.day.activeCell{outline-width:2px;outline-style:solid;outline-offset:-4px}.day.disabled{cursor:default !important;pointer-events:none}.day.blackout{cursor:pointer}.day.reference:after{position:absolute;top:-2px;left:-2px;display:block;width:calc(100% + 2px);height:calc(100% + 2px);box-sizing:content-box;border-radius:10px;border-style:solid;border-width:1px;content:""}.day.inRange::before{position:absolute;z-index:-1;top:-2px;left:-2px;display:block;width:calc(100% + 4px);height:calc(100% + 4px);box-sizing:content-box;content:""}.day.rangeDepartDate::before{position:absolute;z-index:-1;top:-2px;left:-2px;display:block;width:calc(100% + 4px);height:calc(100% + 4px);box-sizing:content-box;content:""}.day.rangeReturnDate::before,.day.lastHoveredDate::before{position:absolute;z-index:-1;top:-2px;left:-2px;display:block;width:calc(100% + 4px);height:calc(100% + 4px);box-sizing:content-box;content:"";border-radius:0 10px 10px 0;overflow:hidden}.day.firstDayOfMonth::before{border-radius:10px 0 0 10px;overflow:hidden}.day.lastDayOfMonth::before{border-radius:0 10px 10px 0;overflow:hidden}.buttonWrapper{display:flex;flex-direction:column;align-items:center;justify-content:center;height:100%}.dateSlot{display:block}::slotted([slot^=date_]){width:100%;white-space:nowrap}::slotted(auro-icon){max-height:24px;max-width:24px}:host([renderForDateSlot]) .buttonWrapper{position:relative;width:100%;height:100%}:host([renderForDateSlot]) .currentDayMarker{position:relative}`;
|
|
7934
8054
|
|
|
7935
|
-
var colorCss$5 = i$3`:host ::slotted([slot^=date_]){color:var(--ds-auro-calendar-cell-price-text-color)}:host ::slotted([slot^=date_][highlight]){--ds-auro-calendar-cell-price-text-color: var(--ds-basic-color-status-success, #447a1f)}:host .day{border-color:var(--ds-auro-calendar-cell-border-color);background-color:var(--ds-auro-calendar-cell-container-color);color:var(--ds-auro-calendar-cell-text-color)}:host .day:
|
|
8055
|
+
var colorCss$5 = i$3`:host ::slotted([slot^=date_]){color:var(--ds-auro-calendar-cell-price-text-color)}:host ::slotted([slot^=date_][highlight]){--ds-auro-calendar-cell-price-text-color: var(--ds-basic-color-status-success, #447a1f)}:host .day{border-color:var(--ds-auro-calendar-cell-border-color);background-color:var(--ds-auro-calendar-cell-container-color);color:var(--ds-auro-calendar-cell-text-color)}:host .day.activeCell:not(.selected){--ds-auro-calendar-cell-container-color: var(--ds-auro-calendar-cell-in-range-color);border-color:var(--ds-advanced-color-state-selected);outline-color:var(--ds-auro-calendar-cell-container-color)}:host .day.selected{--ds-auro-calendar-cell-container-color: var(--ds-advanced-color-state-selected, #01426a);--ds-auro-calendar-cell-text-color: var(--ds-basic-color-texticon-inverse, #ffffff);--ds-auro-calendar-cell-price-text-color: var(--ds-basic-color-texticon-inverse, #ffffff)}:host .day.selected ::slotted([slot^=date_][highlight]){--ds-auro-calendar-cell-price-text-color: var(--ds-basic-color-status-success-subtle, #d6eac7)}:host .day.selected:hover{--ds-auro-calendar-cell-container-color: var(--ds-advanced-color-state-selected-hover, #00274a);--ds-auro-calendar-cell-text-color: var(--ds-basic-color-texticon-inverse, #ffffff)}:host .day.reference:after{border-color:var(--ds-basic-color-border-default, #959595);box-shadow:inset 0 0 0 2px var(--ds-basic-color-surface-default, #ffffff)}:host .day.reference:hover::after{box-shadow:inset 0 0 0 2px var(--ds-advanced-color-shared-background-muted, #f7f7f7)}:host .day:hover{--ds-auro-calendar-cell-container-color: var(--ds-advanced-color-state-background-hover, #f2f2f2);--ds-auro-calendar-cell-text-color: var(--ds-basic-color-texticon-default, #2a2a2a)}:host .day.disabled{--ds-auro-calendar-cell-container-color: transparent;--ds-auro-calendar-cell-text-color: var(--ds-basic-color-texticon-disabled, #d0d0d0);--ds-auro-calendar-cell-price-text-color: var(--ds-basic-color-texticon-disabled, #d0d0d0)}:host .day.blackout{--ds-auro-calendar-cell-container-color: transparent;--ds-auro-calendar-cell-text-color: var(--ds-basic-color-texticon-disabled, #d0d0d0);--ds-auro-calendar-cell-price-text-color: var(--ds-basic-color-texticon-disabled, #d0d0d0)}:host .day.inRange:before,:host .day.rangeDepartDate:before,:host .day.rangeReturnDate:before,:host .day.lastHoveredDate:before{background-color:var(--ds-auro-calendar-cell-in-range-color)}:host .day.sameDateTrip:before{--ds-auro-calendar-cell-in-range-color: transparent}`;
|
|
7936
8056
|
|
|
7937
8057
|
let s$2 = class s{registerComponent(e,t){customElements.get(e)||customElements.define(e,class extends t{});}closestElement(e,t=this,i=(t,s=t&&t.closest(e))=>t&&t!==document&&t!==window?s||i(t.getRootNode().host):null){return i(t)}handleComponentTagRename(e,t){const i=t.toLowerCase();e.tagName.toLowerCase()!==i&&e.setAttribute(i,true);}elementMatch(e,t){const i=t.toLowerCase();return e.tagName.toLowerCase()===i||e.hasAttribute(i)}getSlotText(e,t){const i=e.shadowRoot?.querySelector(`slot[name="${t}"]`);return (i?.assignedNodes({flatten:true})||[]).map(e=>e.textContent?.trim()).join(" ").trim()||null}};var r$3="top",o$3="bottom",n$3="right",a="left",l$3="auto",c$5=[r$3,o$3,n$3,a],p$7="start",d$3="end",f$7="viewport",h$6="popper",u$8=c$5.reduce(function(e,t){return e.concat([t+"-"+p$7,t+"-"+d$3])},[]),m$7=[].concat(c$5,[l$3]).reduce(function(e,t){return e.concat([t,t+"-"+p$7,t+"-"+d$3])},[]),g$6=["beforeRead","read","afterRead","beforeMain","main","afterMain","beforeWrite","write","afterWrite"];function v$4(e){return e?(e.nodeName||"").toLowerCase():null}function y$6(e){if(null==e)return window;if("[object Window]"!==e.toString()){var t=e.ownerDocument;return t&&t.defaultView||window}return e}function w$6(e){return e instanceof y$6(e).Element||e instanceof Element}function b$3(e){return e instanceof y$6(e).HTMLElement||e instanceof HTMLElement}function x$3(e){return "undefined"!=typeof ShadowRoot&&(e instanceof y$6(e).ShadowRoot||e instanceof ShadowRoot)}var S$3={name:"applyStyles",enabled:true,phase:"write",fn:function(e){var t=e.state;Object.keys(t.elements).forEach(function(e){var i=t.styles[e]||{},s=t.attributes[e]||{},r=t.elements[e];b$3(r)&&v$4(r)&&(Object.assign(r.style,i),Object.keys(s).forEach(function(e){var t=s[e];false===t?r.removeAttribute(e):r.setAttribute(e,true===t?"":t);}));});},effect:function(e){var t=e.state,i={popper:{position:t.options.strategy,left:"0",top:"0",margin:"0"},arrow:{position:"absolute"},reference:{}};return Object.assign(t.elements.popper.style,i.popper),t.styles=i,t.elements.arrow&&Object.assign(t.elements.arrow.style,i.arrow),function(){Object.keys(t.elements).forEach(function(e){var s=t.elements[e],r=t.attributes[e]||{},o=Object.keys(t.styles.hasOwnProperty(e)?t.styles[e]:i[e]).reduce(function(e,t){return e[t]="",e},{});b$3(s)&&v$4(s)&&(Object.assign(s.style,o),Object.keys(r).forEach(function(e){s.removeAttribute(e);}));});}},requires:["computeStyles"]};function _$4(e){return e.split("-")[0]}var A$3=Math.max,O=Math.min,k$6=Math.round;function T$3(){var e=navigator.userAgentData;return null!=e&&e.brands&&Array.isArray(e.brands)?e.brands.map(function(e){return e.brand+"/"+e.version}).join(" "):navigator.userAgent}function z$6(){return !/^((?!chrome|android).)*safari/i.test(T$3())}function E(e,t,i){ void 0===t&&(t=false),void 0===i&&(i=false);var s=e.getBoundingClientRect(),r=1,o=1;t&&b$3(e)&&(r=e.offsetWidth>0&&k$6(s.width)/e.offsetWidth||1,o=e.offsetHeight>0&&k$6(s.height)/e.offsetHeight||1);var n=(w$6(e)?y$6(e):window).visualViewport,a=!z$6()&&i,l=(s.left+(a&&n?n.offsetLeft:0))/r,c=(s.top+(a&&n?n.offsetTop:0))/o,p=s.width/r,d=s.height/o;return {width:p,height:d,top:c,right:l+p,bottom:c+d,left:l,x:l,y:c}}function M$7(e){var t=E(e),i=e.offsetWidth,s=e.offsetHeight;return Math.abs(t.width-i)<=1&&(i=t.width),Math.abs(t.height-s)<=1&&(s=t.height),{x:e.offsetLeft,y:e.offsetTop,width:i,height:s}}function B$3(e,t){var i=t.getRootNode&&t.getRootNode();if(e.contains(t))return true;if(i&&x$3(i)){var s=t;do{if(s&&e.isSameNode(s))return true;s=s.parentNode||s.host;}while(s)}return false}function L(e){return y$6(e).getComputedStyle(e)}function R$3(e){return ["table","td","th"].indexOf(v$4(e))>=0}function H$3(e){return ((w$6(e)?e.ownerDocument:e.document)||window.document).documentElement}function C$3(e){return "html"===v$4(e)?e:e.assignedSlot||e.parentNode||(x$3(e)?e.host:null)||H$3(e)}function D(e){return b$3(e)&&"fixed"!==L(e).position?e.offsetParent:null}function N$3(e){for(var t=y$6(e),i=D(e);i&&R$3(i)&&"static"===L(i).position;)i=D(i);return i&&("html"===v$4(i)||"body"===v$4(i)&&"static"===L(i).position)?t:i||function(e){var t=/firefox/i.test(T$3());if(/Trident/i.test(T$3())&&b$3(e)&&"fixed"===L(e).position)return null;var i=C$3(e);for(x$3(i)&&(i=i.host);b$3(i)&&["html","body"].indexOf(v$4(i))<0;){var s=L(i);if("none"!==s.transform||"none"!==s.perspective||"paint"===s.contain||-1!==["transform","perspective"].indexOf(s.willChange)||t&&"filter"===s.willChange||t&&s.filter&&"none"!==s.filter)return i;i=i.parentNode;}return null}(e)||t}function P(e){return ["top","bottom"].indexOf(e)>=0?"x":"y"}function j(e,t,i){return A$3(e,O(t,i))}function I(e){return Object.assign({},{top:0,right:0,bottom:0,left:0},e)}function q$3(e,t){return t.reduce(function(t,i){return t[i]=e,t},{})}var F={name:"arrow",enabled:true,phase:"main",fn:function(e){var t,i=e.state,s=e.name,l=e.options,p=i.elements.arrow,d=i.modifiersData.popperOffsets,f=_$4(i.placement),h=P(f),u=[a,n$3].indexOf(f)>=0?"height":"width";if(p&&d){var m=function(e,t){return I("number"!=typeof(e="function"==typeof e?e(Object.assign({},t.rects,{placement:t.placement})):e)?e:q$3(e,c$5))}(l.padding,i),g=M$7(p),v="y"===h?r$3:a,y="y"===h?o$3:n$3,w=i.rects.reference[u]+i.rects.reference[h]-d[h]-i.rects.popper[u],b=d[h]-i.rects.reference[h],x=N$3(p),S=x?"y"===h?x.clientHeight||0:x.clientWidth||0:0,A=w/2-b/2,O=m[v],k=S-g[u]-m[y],T=S/2-g[u]/2+A,z=j(O,T,k),E=h;i.modifiersData[s]=((t={})[E]=z,t.centerOffset=z-T,t);}},effect:function(e){var t=e.state,i=e.options.element,s=void 0===i?"[data-popper-arrow]":i;null!=s&&("string"!=typeof s||(s=t.elements.popper.querySelector(s)))&&B$3(t.elements.popper,s)&&(t.elements.arrow=s);},requires:["popperOffsets"],requiresIfExists:["preventOverflow"]};function U$3(e){return e.split("-")[1]}var V={top:"auto",right:"auto",bottom:"auto",left:"auto"};function W(e){var t,i=e.popper,s=e.popperRect,l=e.placement,c=e.variation,p=e.offsets,f=e.position,h=e.gpuAcceleration,u=e.adaptive,m=e.roundOffsets,g=e.isFixed,v=p.x,w=void 0===v?0:v,b=p.y,x=void 0===b?0:b,S="function"==typeof m?m({x:w,y:x}):{x:w,y:x};w=S.x,x=S.y;var _=p.hasOwnProperty("x"),A=p.hasOwnProperty("y"),O=a,T=r$3,z=window;if(u){var E=N$3(i),M="clientHeight",B="clientWidth";if(E===y$6(i)&&"static"!==L(E=H$3(i)).position&&"absolute"===f&&(M="scrollHeight",B="scrollWidth"),l===r$3||(l===a||l===n$3)&&c===d$3)T=o$3,x-=(g&&E===z&&z.visualViewport?z.visualViewport.height:E[M])-s.height,x*=h?1:-1;if(l===a||(l===r$3||l===o$3)&&c===d$3)O=n$3,w-=(g&&E===z&&z.visualViewport?z.visualViewport.width:E[B])-s.width,w*=h?1:-1;}var R,C=Object.assign({position:f},u&&V),D=true===m?function(e,t){var i=e.x,s=e.y,r=t.devicePixelRatio||1;return {x:k$6(i*r)/r||0,y:k$6(s*r)/r||0}}({x:w,y:x},y$6(i)):{x:w,y:x};return w=D.x,x=D.y,h?Object.assign({},C,((R={})[T]=A?"0":"",R[O]=_?"0":"",R.transform=(z.devicePixelRatio||1)<=1?"translate("+w+"px, "+x+"px)":"translate3d("+w+"px, "+x+"px, 0)",R)):Object.assign({},C,((t={})[T]=A?x+"px":"",t[O]=_?w+"px":"",t.transform="",t))}var X={passive:true};var $={left:"right",right:"left",bottom:"top",top:"bottom"};function G(e){return e.replace(/left|right|bottom|top/g,function(e){return $[e]})}var K={start:"end",end:"start"};function Y(e){return e.replace(/start|end/g,function(e){return K[e]})}function J(e){var t=y$6(e);return {scrollLeft:t.pageXOffset,scrollTop:t.pageYOffset}}function Q(e){return E(H$3(e)).left+J(e).scrollLeft}function Z(e){var t=L(e),i=t.overflow,s=t.overflowX,r=t.overflowY;return /auto|scroll|overlay|hidden/.test(i+r+s)}function ee(e){return ["html","body","#document"].indexOf(v$4(e))>=0?e.ownerDocument.body:b$3(e)&&Z(e)?e:ee(C$3(e))}function te(e,t){var i;void 0===t&&(t=[]);var s=ee(e),r=s===(null==(i=e.ownerDocument)?void 0:i.body),o=y$6(s),n=r?[o].concat(o.visualViewport||[],Z(s)?s:[]):s,a=t.concat(n);return r?a:a.concat(te(C$3(n)))}function ie(e){return Object.assign({},e,{left:e.x,top:e.y,right:e.x+e.width,bottom:e.y+e.height})}function se(e,t,i){return t===f$7?ie(function(e,t){var i=y$6(e),s=H$3(e),r=i.visualViewport,o=s.clientWidth,n=s.clientHeight,a=0,l=0;if(r){o=r.width,n=r.height;var c=z$6();(c||!c&&"fixed"===t)&&(a=r.offsetLeft,l=r.offsetTop);}return {width:o,height:n,x:a+Q(e),y:l}}(e,i)):w$6(t)?function(e,t){var i=E(e,false,"fixed"===t);return i.top=i.top+e.clientTop,i.left=i.left+e.clientLeft,i.bottom=i.top+e.clientHeight,i.right=i.left+e.clientWidth,i.width=e.clientWidth,i.height=e.clientHeight,i.x=i.left,i.y=i.top,i}(t,i):ie(function(e){var t,i=H$3(e),s=J(e),r=null==(t=e.ownerDocument)?void 0:t.body,o=A$3(i.scrollWidth,i.clientWidth,r?r.scrollWidth:0,r?r.clientWidth:0),n=A$3(i.scrollHeight,i.clientHeight,r?r.scrollHeight:0,r?r.clientHeight:0),a=-s.scrollLeft+Q(e),l=-s.scrollTop;return "rtl"===L(r||i).direction&&(a+=A$3(i.clientWidth,r?r.clientWidth:0)-o),{width:o,height:n,x:a,y:l}}(H$3(e)))}function re(e,t,i,s){var r="clippingParents"===t?function(e){var t=te(C$3(e)),i=["absolute","fixed"].indexOf(L(e).position)>=0&&b$3(e)?N$3(e):e;return w$6(i)?t.filter(function(e){return w$6(e)&&B$3(e,i)&&"body"!==v$4(e)}):[]}(e):[].concat(t),o=[].concat(r,[i]),n=o[0],a=o.reduce(function(t,i){var r=se(e,i,s);return t.top=A$3(r.top,t.top),t.right=O(r.right,t.right),t.bottom=O(r.bottom,t.bottom),t.left=A$3(r.left,t.left),t},se(e,n,s));return a.width=a.right-a.left,a.height=a.bottom-a.top,a.x=a.left,a.y=a.top,a}function oe(e){var t,i=e.reference,s=e.element,l=e.placement,c=l?_$4(l):null,f=l?U$3(l):null,h=i.x+i.width/2-s.width/2,u=i.y+i.height/2-s.height/2;switch(c){case r$3:t={x:h,y:i.y-s.height};break;case o$3:t={x:h,y:i.y+i.height};break;case n$3:t={x:i.x+i.width,y:u};break;case a:t={x:i.x-s.width,y:u};break;default:t={x:i.x,y:i.y};}var m=c?P(c):null;if(null!=m){var g="y"===m?"height":"width";switch(f){case p$7:t[m]=t[m]-(i[g]/2-s[g]/2);break;case d$3:t[m]=t[m]+(i[g]/2-s[g]/2);}}return t}function ne(e,t){ void 0===t&&(t={});var i=t,s=i.placement,a=void 0===s?e.placement:s,l=i.strategy,p=void 0===l?e.strategy:l,d=i.boundary,u=void 0===d?"clippingParents":d,m=i.rootBoundary,g=void 0===m?f$7:m,v=i.elementContext,y=void 0===v?h$6:v,b=i.altBoundary,x=void 0!==b&&b,S=i.padding,_=void 0===S?0:S,A=I("number"!=typeof _?_:q$3(_,c$5)),O=y===h$6?"reference":h$6,k=e.rects.popper,T=e.elements[x?O:y],z=re(w$6(T)?T:T.contextElement||H$3(e.elements.popper),u,g,p),M=E(e.elements.reference),B=oe({reference:M,element:k,placement:a}),L=ie(Object.assign({},k,B)),R=y===h$6?L:M,C={top:z.top-R.top+A.top,bottom:R.bottom-z.bottom+A.bottom,left:z.left-R.left+A.left,right:R.right-z.right+A.right},D=e.modifiersData.offset;if(y===h$6&&D){var N=D[a];Object.keys(C).forEach(function(e){var t=[n$3,o$3].indexOf(e)>=0?1:-1,i=[r$3,o$3].indexOf(e)>=0?"y":"x";C[e]+=N[i]*t;});}return C}function ae(e,t){ void 0===t&&(t={});var i=t,s=i.placement,r=i.boundary,o=i.rootBoundary,n=i.padding,a=i.flipVariations,l=i.allowedAutoPlacements,p=void 0===l?m$7:l,d=U$3(s),f=d?a?u$8:u$8.filter(function(e){return U$3(e)===d}):c$5,h=f.filter(function(e){return p.indexOf(e)>=0});0===h.length&&(h=f);var g=h.reduce(function(t,i){return t[i]=ne(e,{placement:i,boundary:r,rootBoundary:o,padding:n})[_$4(i)],t},{});return Object.keys(g).sort(function(e,t){return g[e]-g[t]})}var le={name:"flip",enabled:true,phase:"main",fn:function(e){var t=e.state,i=e.options,s=e.name;if(!t.modifiersData[s]._skip){for(var c=i.mainAxis,d=void 0===c||c,f=i.altAxis,h=void 0===f||f,u=i.fallbackPlacements,m=i.padding,g=i.boundary,v=i.rootBoundary,y=i.altBoundary,w=i.flipVariations,b=void 0===w||w,x=i.allowedAutoPlacements,S=t.options.placement,A=_$4(S),O=u||(A===S||!b?[G(S)]:function(e){if(_$4(e)===l$3)return [];var t=G(e);return [Y(e),t,Y(t)]}(S)),k=[S].concat(O).reduce(function(e,i){return e.concat(_$4(i)===l$3?ae(t,{placement:i,boundary:g,rootBoundary:v,padding:m,flipVariations:b,allowedAutoPlacements:x}):i)},[]),T=t.rects.reference,z=t.rects.popper,E=new Map,M=true,B=k[0],L=0;L<k.length;L++){var R=k[L],H=_$4(R),C=U$3(R)===p$7,D=[r$3,o$3].indexOf(H)>=0,N=D?"width":"height",P=ne(t,{placement:R,boundary:g,rootBoundary:v,altBoundary:y,padding:m}),j=D?C?n$3:a:C?o$3:r$3;T[N]>z[N]&&(j=G(j));var I=G(j),q=[];if(d&&q.push(P[H]<=0),h&&q.push(P[j]<=0,P[I]<=0),q.every(function(e){return e})){B=R,M=false;break}E.set(R,q);}if(M)for(var F=function(e){var t=k.find(function(t){var i=E.get(t);if(i)return i.slice(0,e).every(function(e){return e})});if(t)return B=t,"break"},V=b?3:1;V>0;V--){if("break"===F(V))break}t.placement!==B&&(t.modifiersData[s]._skip=true,t.placement=B,t.reset=true);}},requiresIfExists:["offset"],data:{_skip:false}};function ce(e,t,i){return void 0===i&&(i={x:0,y:0}),{top:e.top-t.height-i.y,right:e.right-t.width+i.x,bottom:e.bottom-t.height+i.y,left:e.left-t.width-i.x}}function pe(e){return [r$3,n$3,o$3,a].some(function(t){return e[t]>=0})}var de={name:"offset",enabled:true,phase:"main",requires:["popperOffsets"],fn:function(e){var t=e.state,i=e.options,s=e.name,o=i.offset,l=void 0===o?[0,0]:o,c=m$7.reduce(function(e,i){return e[i]=function(e,t,i){var s=_$4(e),o=[a,r$3].indexOf(s)>=0?-1:1,l="function"==typeof i?i(Object.assign({},t,{placement:e})):i,c=l[0],p=l[1];return c=c||0,p=(p||0)*o,[a,n$3].indexOf(s)>=0?{x:p,y:c}:{x:c,y:p}}(i,t.rects,l),e},{}),p=c[t.placement],d=p.x,f=p.y;null!=t.modifiersData.popperOffsets&&(t.modifiersData.popperOffsets.x+=d,t.modifiersData.popperOffsets.y+=f),t.modifiersData[s]=c;}};var fe={name:"preventOverflow",enabled:true,phase:"main",fn:function(e){var t=e.state,i=e.options,s=e.name,l=i.mainAxis,c=void 0===l||l,d=i.altAxis,f=void 0!==d&&d,h=i.boundary,u=i.rootBoundary,m=i.altBoundary,g=i.padding,v=i.tether,y=void 0===v||v,w=i.tetherOffset,b=void 0===w?0:w,x=ne(t,{boundary:h,rootBoundary:u,padding:g,altBoundary:m}),S=_$4(t.placement),k=U$3(t.placement),T=!k,z=P(S),E="x"===z?"y":"x",B=t.modifiersData.popperOffsets,L=t.rects.reference,R=t.rects.popper,H="function"==typeof b?b(Object.assign({},t.rects,{placement:t.placement})):b,C="number"==typeof H?{mainAxis:H,altAxis:H}:Object.assign({mainAxis:0,altAxis:0},H),D=t.modifiersData.offset?t.modifiersData.offset[t.placement]:null,I={x:0,y:0};if(B){if(c){var q,F="y"===z?r$3:a,V="y"===z?o$3:n$3,W="y"===z?"height":"width",X=B[z],$=X+x[F],G=X-x[V],K=y?-R[W]/2:0,Y=k===p$7?L[W]:R[W],J=k===p$7?-R[W]:-L[W],Q=t.elements.arrow,Z=y&&Q?M$7(Q):{width:0,height:0},ee=t.modifiersData["arrow#persistent"]?t.modifiersData["arrow#persistent"].padding:{top:0,right:0,bottom:0,left:0},te=ee[F],ie=ee[V],se=j(0,L[W],Z[W]),re=T?L[W]/2-K-se-te-C.mainAxis:Y-se-te-C.mainAxis,oe=T?-L[W]/2+K+se+ie+C.mainAxis:J+se+ie+C.mainAxis,ae=t.elements.arrow&&N$3(t.elements.arrow),le=ae?"y"===z?ae.clientTop||0:ae.clientLeft||0:0,ce=null!=(q=null==D?void 0:D[z])?q:0,pe=X+oe-ce,de=j(y?O($,X+re-ce-le):$,X,y?A$3(G,pe):G);B[z]=de,I[z]=de-X;}if(f){var fe,he="x"===z?r$3:a,ue="x"===z?o$3:n$3,me=B[E],ge="y"===E?"height":"width",ve=me+x[he],ye=me-x[ue],we=-1!==[r$3,a].indexOf(S),be=null!=(fe=null==D?void 0:D[E])?fe:0,xe=we?ve:me-L[ge]-R[ge]-be+C.altAxis,Se=we?me+L[ge]+R[ge]-be-C.altAxis:ye,_e=y&&we?function(e,t,i){var s=j(e,t,i);return s>i?i:s}(xe,me,Se):j(y?xe:ve,me,y?Se:ye);B[E]=_e,I[E]=_e-me;}t.modifiersData[s]=I;}},requiresIfExists:["offset"]};function he(e,t,i){ void 0===i&&(i=false);var s,r,o=b$3(t),n=b$3(t)&&function(e){var t=e.getBoundingClientRect(),i=k$6(t.width)/e.offsetWidth||1,s=k$6(t.height)/e.offsetHeight||1;return 1!==i||1!==s}(t),a=H$3(t),l=E(e,n,i),c={scrollLeft:0,scrollTop:0},p={x:0,y:0};return (o||!o&&!i)&&(("body"!==v$4(t)||Z(a))&&(c=(s=t)!==y$6(s)&&b$3(s)?{scrollLeft:(r=s).scrollLeft,scrollTop:r.scrollTop}:J(s)),b$3(t)?((p=E(t,true)).x+=t.clientLeft,p.y+=t.clientTop):a&&(p.x=Q(a))),{x:l.left+c.scrollLeft-p.x,y:l.top+c.scrollTop-p.y,width:l.width,height:l.height}}function ue(e){var t=new Map,i=new Set,s=[];function r(e){i.add(e.name),[].concat(e.requires||[],e.requiresIfExists||[]).forEach(function(e){if(!i.has(e)){var s=t.get(e);s&&r(s);}}),s.push(e);}return e.forEach(function(e){t.set(e.name,e);}),e.forEach(function(e){i.has(e.name)||r(e);}),s}var me={placement:"bottom",modifiers:[],strategy:"absolute"};function ge(){for(var e=arguments.length,t=new Array(e),i=0;i<e;i++)t[i]=arguments[i];return !t.some(function(e){return !(e&&"function"==typeof e.getBoundingClientRect)})}function ve(e){ void 0===e&&(e={});var t=e,i=t.defaultModifiers,s=void 0===i?[]:i,r=t.defaultOptions,o=void 0===r?me:r;return function(e,t,i){ void 0===i&&(i=o);var r,n,a={placement:"bottom",orderedModifiers:[],options:Object.assign({},me,o),modifiersData:{},elements:{reference:e,popper:t},attributes:{},styles:{}},l=[],c=false,p={state:a,setOptions:function(i){var r="function"==typeof i?i(a.options):i;d(),a.options=Object.assign({},o,a.options,r),a.scrollParents={reference:w$6(e)?te(e):e.contextElement?te(e.contextElement):[],popper:te(t)};var n,c,f=function(e){var t=ue(e);return g$6.reduce(function(e,i){return e.concat(t.filter(function(e){return e.phase===i}))},[])}((n=[].concat(s,a.options.modifiers),c=n.reduce(function(e,t){var i=e[t.name];return e[t.name]=i?Object.assign({},i,t,{options:Object.assign({},i.options,t.options),data:Object.assign({},i.data,t.data)}):t,e},{}),Object.keys(c).map(function(e){return c[e]})));return a.orderedModifiers=f.filter(function(e){return e.enabled}),a.orderedModifiers.forEach(function(e){var t=e.name,i=e.options,s=void 0===i?{}:i,r=e.effect;if("function"==typeof r){var o=r({state:a,name:t,instance:p,options:s}),n=function(){};l.push(o||n);}}),p.update()},forceUpdate:function(){if(!c){var e=a.elements,t=e.reference,i=e.popper;if(ge(t,i)){a.rects={reference:he(t,N$3(i),"fixed"===a.options.strategy),popper:M$7(i)},a.reset=false,a.placement=a.options.placement,a.orderedModifiers.forEach(function(e){return a.modifiersData[e.name]=Object.assign({},e.data)});for(var s=0;s<a.orderedModifiers.length;s++)if(true!==a.reset){var r=a.orderedModifiers[s],o=r.fn,n=r.options,l=void 0===n?{}:n,d=r.name;"function"==typeof o&&(a=o({state:a,options:l,name:d,instance:p})||a);}else a.reset=false,s=-1;}}},update:(r=function(){return new Promise(function(e){p.forceUpdate(),e(a);})},function(){return n||(n=new Promise(function(e){Promise.resolve().then(function(){n=void 0,e(r());});})),n}),destroy:function(){d(),c=true;}};if(!ge(e,t))return p;function d(){l.forEach(function(e){return e()}),l=[];}return p.setOptions(i).then(function(e){!c&&i.onFirstUpdate&&i.onFirstUpdate(e);}),p}}var ye=ve({defaultModifiers:[{name:"eventListeners",enabled:true,phase:"write",fn:function(){},effect:function(e){var t=e.state,i=e.instance,s=e.options,r=s.scroll,o=void 0===r||r,n=s.resize,a=void 0===n||n,l=y$6(t.elements.popper),c=[].concat(t.scrollParents.reference,t.scrollParents.popper);return o&&c.forEach(function(e){e.addEventListener("scroll",i.update,X);}),a&&l.addEventListener("resize",i.update,X),function(){o&&c.forEach(function(e){e.removeEventListener("scroll",i.update,X);}),a&&l.removeEventListener("resize",i.update,X);}},data:{}},{name:"popperOffsets",enabled:true,phase:"read",fn:function(e){var t=e.state,i=e.name;t.modifiersData[i]=oe({reference:t.rects.reference,element:t.rects.popper,placement:t.placement});},data:{}},{name:"computeStyles",enabled:true,phase:"beforeWrite",fn:function(e){var t=e.state,i=e.options,s=i.gpuAcceleration,r=void 0===s||s,o=i.adaptive,n=void 0===o||o,a=i.roundOffsets,l=void 0===a||a,c={placement:_$4(t.placement),variation:U$3(t.placement),popper:t.elements.popper,popperRect:t.rects.popper,gpuAcceleration:r,isFixed:"fixed"===t.options.strategy};null!=t.modifiersData.popperOffsets&&(t.styles.popper=Object.assign({},t.styles.popper,W(Object.assign({},c,{offsets:t.modifiersData.popperOffsets,position:t.options.strategy,adaptive:n,roundOffsets:l})))),null!=t.modifiersData.arrow&&(t.styles.arrow=Object.assign({},t.styles.arrow,W(Object.assign({},c,{offsets:t.modifiersData.arrow,position:"absolute",adaptive:false,roundOffsets:l})))),t.attributes.popper=Object.assign({},t.attributes.popper,{"data-popper-placement":t.placement});},data:{}},S$3,de,le,fe,F,{name:"hide",enabled:true,phase:"main",requiresIfExists:["preventOverflow"],fn:function(e){var t=e.state,i=e.name,s=t.rects.reference,r=t.rects.popper,o=t.modifiersData.preventOverflow,n=ne(t,{elementContext:"reference"}),a=ne(t,{altBoundary:true}),l=ce(n,s),c=ce(a,r,o),p=pe(l),d=pe(c);t.modifiersData[i]={referenceClippingOffsets:l,popperEscapeOffsets:c,isReferenceHidden:p,hasPopperEscaped:d},t.attributes.popper=Object.assign({},t.attributes.popper,{"data-popper-reference-hidden":p,"data-popper-escaped":d});}}]});class we{constructor(e,t,i,s){this.anchor=e,this.popover=t,this.boundaryElement=this.setBoundary(s),this.options={placement:i,visibleClass:"data-show"},this.popover.classList.remove(this.options.visibleClass);}setBoundary(e){return "string"==typeof e?document.querySelector(e)||document.body:e||document.body}show(){this.popper&&this.popper.destroy(),this.popper=ye(this.anchor,this.popover,{tooltip:this.anchor,placement:this.options.placement,modifiers:[{name:"offset",options:{offset:[0,18]}},{name:"preventOverflow",options:{mainAxis:true,boundary:this.boundaryElement,rootBoundary:"document",padding:16}}]});}triggerUpdate(){this.popper.update();}hide(){this.popover.classList.remove(this.options.visibleClass);}}var be=i$3`::slotted(*):not([onDark]),::slotted(*):not([appearance=inverse]){color:var(--ds-auro-popover-text-color)}.popover{background-color:var(--ds-auro-popover-container-color);box-shadow:var(--ds-auro-popover-boxshadow-color)}.arrow:before{background-color:var(--ds-auro-popover-container-color);box-shadow:2px 2px 1px 0 var(--ds-auro-popover-boxshadow-color)}
|
|
7938
8058
|
`,xe=i$3`.body-default{font-size:var(--wcss-body-default-font-size, 1rem);line-height:var(--wcss-body-default-line-height, 1.5rem)}.body-default,.body-lg{font-family:var(--wcss-body-family, "AS Circular"),system-ui,-apple-system,BlinkMacSystemFont,"Segoe UI",Roboto,"Helvetica Neue",Arial,sans-serif;font-weight:var(--wcss-body-weight, 450);letter-spacing:var(--wcss-body-letter-spacing, 0)}.body-lg{font-size:var(--wcss-body-lg-font-size, 1.125rem);line-height:var(--wcss-body-lg-line-height, 1.625rem)}.body-sm{font-size:var(--wcss-body-sm-font-size, .875rem);line-height:var(--wcss-body-sm-line-height, 1.25rem)}.body-sm,.body-xs{font-family:var(--wcss-body-family, "AS Circular"),system-ui,-apple-system,BlinkMacSystemFont,"Segoe UI",Roboto,"Helvetica Neue",Arial,sans-serif;font-weight:var(--wcss-body-weight, 450);letter-spacing:var(--wcss-body-letter-spacing, 0)}.body-xs{font-size:var(--wcss-body-xs-font-size, .75rem);line-height:var(--wcss-body-xs-line-height, 1rem)}.body-2xs{font-family:var(--wcss-body-family, "AS Circular"),system-ui,-apple-system,BlinkMacSystemFont,"Segoe UI",Roboto,"Helvetica Neue",Arial,sans-serif;font-size:var(--wcss-body-2xs-font-size, .625rem);font-weight:var(--wcss-body-weight, 450);letter-spacing:var(--wcss-body-letter-spacing, 0);line-height:var(--wcss-body-2xs-line-height, .875rem)}.display-2xl{font-family:var(--wcss-display-2xl-family, "AS Circular"),var(--wcss-display-2xl-family-fallback, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif);font-size:var(--wcss-display-2xl-font-size, clamp(3.5rem, 6vw, 5.375rem));font-weight:var(--wcss-display-2xl-weight, 300);letter-spacing:var(--wcss-display-2xl-letter-spacing, 0);line-height:var(--wcss-display-2xl-line-height, 1.3)}.display-xl{font-family:var(--wcss-display-xl-family, "AS Circular"),var(--wcss-display-xl-family-fallback, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif);font-size:var(--wcss-display-xl-font-size, clamp(3rem, 5.3333333333vw, 4.5rem));font-weight:var(--wcss-display-xl-weight, 300);letter-spacing:var(--wcss-display-xl-letter-spacing, 0);line-height:var(--wcss-display-xl-line-height, 1.3)}.display-lg{font-family:var(--wcss-display-lg-family, "AS Circular"),var(--wcss-display-lg-family-fallback, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif);font-size:var(--wcss-display-lg-font-size, clamp(2.75rem, 4.6666666667vw, 4rem));font-weight:var(--wcss-display-lg-weight, 300);letter-spacing:var(--wcss-display-lg-letter-spacing, 0);line-height:var(--wcss-display-lg-line-height, 1.3)}.display-md{font-family:var(--wcss-display-md-family, "AS Circular"),var(--wcss-display-md-family-fallback, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif);font-size:var(--wcss-display-md-font-size, clamp(2.5rem, 4vw, 3.5rem));font-weight:var(--wcss-display-md-weight, 300);letter-spacing:var(--wcss-display-md-letter-spacing, 0);line-height:var(--wcss-display-md-line-height, 1.3)}.display-sm{font-family:var(--wcss-display-sm-family, "AS Circular"),var(--wcss-display-sm-family-fallback, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif);font-size:var(--wcss-display-sm-font-size, clamp(2rem, 3.6666666667vw, 3rem));font-weight:var(--wcss-display-sm-weight, 300);letter-spacing:var(--wcss-display-sm-letter-spacing, 0);line-height:var(--wcss-display-sm-line-height, 1.3)}.display-xs{font-family:var(--wcss-display-xs-family, "AS Circular"),var(--wcss-display-xs-family-fallback, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif);font-size:var(--wcss-display-xs-font-size, clamp(1.75rem, 3vw, 2.375rem));font-weight:var(--wcss-display-xs-weight, 300);letter-spacing:var(--wcss-display-xs-letter-spacing, 0);line-height:var(--wcss-display-xs-line-height, 1.3)}.heading-xl{font-family:var(--wcss-heading-xl-family, "AS Circular"),var(--wcss-heading-xl-family-fallback, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif);font-size:var(--wcss-heading-xl-font-size, clamp(2rem, 3vw, 2.5rem));font-weight:var(--wcss-heading-xl-weight, 300);letter-spacing:var(--wcss-heading-xl-letter-spacing, 0);line-height:var(--wcss-heading-xl-line-height, 1.3)}.heading-lg{font-family:var(--wcss-heading-lg-family, "AS Circular"),var(--wcss-heading-lg-family-fallback, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif);font-size:var(--wcss-heading-lg-font-size, clamp(1.75rem, 2.6666666667vw, 2.25rem));font-weight:var(--wcss-heading-lg-weight, 300);letter-spacing:var(--wcss-heading-lg-letter-spacing, 0);line-height:var(--wcss-heading-lg-line-height, 1.3)}.heading-md{font-family:var(--wcss-heading-md-family, "AS Circular"),var(--wcss-heading-md-family-fallback, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif);font-size:var(--wcss-heading-md-font-size, clamp(1.625rem, 2.3333333333vw, 1.75rem));font-weight:var(--wcss-heading-md-weight, 300);letter-spacing:var(--wcss-heading-md-letter-spacing, 0);line-height:var(--wcss-heading-md-line-height, 1.3)}.heading-sm{font-family:var(--wcss-heading-sm-family, "AS Circular"),var(--wcss-heading-sm-family-fallback, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif);font-size:var(--wcss-heading-sm-font-size, clamp(1.375rem, 2vw, 1.5rem));font-weight:var(--wcss-heading-sm-weight, 300);letter-spacing:var(--wcss-heading-sm-letter-spacing, 0);line-height:var(--wcss-heading-sm-line-height, 1.3)}.heading-xs{font-family:var(--wcss-heading-xs-family, "AS Circular"),var(--wcss-heading-xs-family-fallback, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif);font-size:var(--wcss-heading-xs-font-size, clamp(1.25rem, 1.6666666667vw, 1.25rem));font-weight:var(--wcss-heading-xs-weight, 450);letter-spacing:var(--wcss-heading-xs-letter-spacing, 0);line-height:var(--wcss-heading-xs-line-height, 1.3)}.heading-2xs{font-family:var(--wcss-heading-2xs-family, "AS Circular"),var(--wcss-heading-2xs-family-fallback, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif);font-size:var(--wcss-heading-2xs-font-size, clamp(1.125rem, 1.5vw, 1.125rem));font-weight:var(--wcss-heading-2xs-weight, 450);letter-spacing:var(--wcss-heading-2xs-letter-spacing, 0);line-height:var(--wcss-heading-2xs-line-height, 1.3)}.accent-2xl{font-family:var(--wcss-accent-2xl-family, "Good OT"),var(--wcss-accent-2xl-family-fallback, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif);font-size:var(--wcss-accent-2xl-font-size, clamp(2rem, 3.1666666667vw, 2.375rem));font-weight:var(--wcss-accent-2xl-weight, 450);letter-spacing:var(--wcss-accent-2xl-letter-spacing, .05em);line-height:var(--wcss-accent-2xl-line-height, 1)}.accent-2xl,.accent-xl{text-transform:uppercase}.accent-xl{font-family:var(--wcss-accent-xl-family, "Good OT"),var(--wcss-accent-xl-family-fallback, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif);font-size:var(--wcss-accent-xl-font-size, clamp(1.625rem, 2.3333333333vw, 2rem));font-weight:var(--wcss-accent-xl-weight, 450);letter-spacing:var(--wcss-accent-xl-letter-spacing, .05em);line-height:var(--wcss-accent-xl-line-height, 1.3)}.accent-lg{font-family:var(--wcss-accent-lg-family, "Good OT"),var(--wcss-accent-lg-family-fallback, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif);font-size:var(--wcss-accent-lg-font-size, clamp(1.5rem, 2.1666666667vw, 1.75rem));font-weight:var(--wcss-accent-lg-weight, 450);letter-spacing:var(--wcss-accent-lg-letter-spacing, .05em);line-height:var(--wcss-accent-lg-line-height, 1.3)}.accent-lg,.accent-md{text-transform:uppercase}.accent-md{font-family:var(--wcss-accent-md-family, "Good OT"),var(--wcss-accent-md-family-fallback, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif);font-size:var(--wcss-accent-md-font-size, clamp(1.375rem, 1.8333333333vw, 1.5rem));font-weight:var(--wcss-accent-md-weight, 500);letter-spacing:var(--wcss-accent-md-letter-spacing, .05em);line-height:var(--wcss-accent-md-line-height, 1.3)}.accent-sm{font-family:var(--wcss-accent-sm-family, "Good OT"),var(--wcss-accent-sm-family-fallback, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif);font-size:var(--wcss-accent-sm-font-size, clamp(1.125rem, 1.5vw, 1.25rem));font-weight:var(--wcss-accent-sm-weight, 500);letter-spacing:var(--wcss-accent-sm-letter-spacing, .05em);line-height:var(--wcss-accent-sm-line-height, 1.3)}.accent-sm,.accent-xs{text-transform:uppercase}.accent-xs{font-family:var(--wcss-accent-xs-family, "Good OT"),var(--wcss-accent-xs-family-fallback, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif);font-size:var(--wcss-accent-xs-font-size, clamp(1rem, 1.3333333333vw, 1rem));font-weight:var(--wcss-accent-xs-weight, 500);letter-spacing:var(--wcss-accent-xs-letter-spacing, .1em);line-height:var(--wcss-accent-xs-line-height, 1.3)}.accent-2xs{font-family:var(--wcss-accent-2xs-family, "Good OT"),var(--wcss-accent-2xs-family-fallback, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif);font-size:var(--wcss-accent-2xs-font-size, clamp(.875rem, 1.1666666667vw, .875rem));font-weight:var(--wcss-accent-2xs-weight, 450);letter-spacing:var(--wcss-accent-2xs-letter-spacing, .1em);line-height:var(--wcss-accent-2xs-line-height, 1.3);text-transform:uppercase}:focus:not(:focus-visible){outline:3px solid transparent}.util_displayInline{display:inline}.util_displayInlineBlock{display:inline-block}.util_displayBlock{display:block}.util_displayFlex{display:flex}.util_displayHidden,:host(:not([data-show])) .popover,:host([disabled]) .popover,:host([addSpace]) :host(:not([data-show])) .popover{display:none}.util_displayHiddenVisually{position:absolute;overflow:hidden;clip:rect(1px,1px,1px,1px);width:1px;height:1px;padding:0;border:0}.util_insetNone{padding:0}.util_insetXxxs{padding:.125rem}.util_insetXxxs--stretch{padding:.25rem .125rem}.util_insetXxxs--squish{padding:0 .125rem}.util_insetXxs{padding:.25rem}.util_insetXxs--stretch{padding:.375rem .25rem}.util_insetXxs--squish{padding:.125rem .25rem}.util_insetXs{padding:.5rem}.util_insetXs--stretch{padding:.75rem .5rem}.util_insetXs--squish{padding:.25rem .5rem}.util_insetSm{padding:.75rem}.util_insetSm--stretch{padding:1.125rem .75rem}.util_insetSm--squish{padding:.375rem .75rem}.util_insetMd{padding:1rem}.util_insetMd--stretch{padding:1.5rem 1rem}.util_insetMd--squish{padding:.5rem 1rem}.util_insetLg{padding:1.5rem}.util_insetLg--stretch{padding:2.25rem 1.5rem}.util_insetLg--squish{padding:.75rem 1.5rem}.util_insetXl{padding:2rem}.util_insetXl--stretch{padding:3rem 2rem}.util_insetXl--squish{padding:1rem 2rem}.util_insetXxl{padding:3rem}.util_insetXxl--stretch{padding:4.5rem 3rem}.util_insetXxl--squish{padding:1.5rem 3rem}.util_insetXxxl{padding:4rem}.util_insetXxxl--stretch{padding:6rem 4rem}.util_insetXxxl--squish{padding:2rem 4rem}::slotted(*){white-space:normal}::slotted(*:hover){cursor:pointer}[data-trigger-placement]::slotted(*:hover){position:relative}[data-trigger-placement]::slotted(*:hover):before{position:absolute;left:0;display:block;width:100%;height:calc(var(--ds-size-200, 1rem) + var(--ds-size-50, .25rem));content:""}[data-trigger-placement^=top]::slotted(*:hover):before{top:calc(-1 * (var(--ds-size-200, 1rem) + var(--ds-size-50, .25rem)))}[data-trigger-placement^=bottom]::slotted(*:hover):before{bottom:calc(-1 * (var(--ds-size-200, 1rem) + var(--ds-size-50, .25rem)))}:host([data-show]) .popover{z-index:var(--ds-depth-tooltip, 400)}:host([removeSpace]) .popover{margin:calc(-1 * (var(--ds-size-50, .25rem) + 1px)) 0!important}:host([addSpace]) .popover{margin:var(--ds-size-200, 1rem) 0!important}:host([addSpace]) [data-trigger-placement]::slotted(*:hover):before{height:var(--ds-size-500, 2.5rem)}:host([addSpace]) [data-trigger-placement^=top]::slotted(*:hover):before{top:calc(-1 * var(--ds-size-500, 2.5rem))}:host([addSpace]) [data-trigger-placement^=bottom]::slotted(*:hover):before{bottom:calc(-1 * var(--ds-size-500, 2.5rem))}.popover{display:inline-block;max-width:calc(100% - var(--ds-size-400, 2rem));border-radius:var(--ds-border-radius, .375rem)}@media screen and (min-width:576px){.popover{max-width:50%}}@media screen and (min-width:768px){.popover{max-width:40%}}@media screen and (min-width:1024px){.popover{max-width:27rem}}[data-popper-placement^=top]>.arrow{bottom:calc(-1 * (var(--ds-size-100, .5rem) + var(--ds-size-25, .125rem)))}[data-popper-placement^=top]>.arrow:before{top:calc(-1 * var(--ds-size-200, 1rem));left:calc(-1 * var(--ds-size-75, .375rem));transform:rotate(45deg)}[data-popper-placement^=bottom]>.arrow{top:calc(-1 * (var(--ds-size-100, .5rem) + var(--ds-size-25, .125rem)))}[data-popper-placement^=bottom]>.arrow:before{top:var(--ds-size-50, .25rem);right:calc(-1 * var(--ds-size-200, 1rem));transform:rotate(-135deg)}.arrow{position:relative;margin-top:-var(--ds-size-100,.5rem)}.arrow:before{position:absolute;width:var(--ds-size-150, .75rem);height:var(--ds-size-150, .75rem);content:""}
|
|
@@ -7955,7 +8075,7 @@ let s$2 = class s{registerComponent(e,t){customElements.get(e)||customElements.d
|
|
|
7955
8075
|
|
|
7956
8076
|
var popoverVersion = '6.0.1';
|
|
7957
8077
|
|
|
7958
|
-
/* eslint-disable curly, max-lines, no-underscore-dangle, no-magic-numbers, no-underscore-dangle, max-params, no-
|
|
8078
|
+
/* eslint-disable curly, max-lines, no-underscore-dangle, no-magic-numbers, no-underscore-dangle, max-params, no-extra-parens, arrow-parens, max-lines, line-comment-position, no-inline-comments, lit/binding-positions, lit/no-invalid-html */
|
|
7959
8079
|
|
|
7960
8080
|
class AuroCalendarCell extends i$1 {
|
|
7961
8081
|
constructor() {
|
|
@@ -7963,7 +8083,6 @@ class AuroCalendarCell extends i$1 {
|
|
|
7963
8083
|
|
|
7964
8084
|
this.day = null;
|
|
7965
8085
|
this.selected = false;
|
|
7966
|
-
this.hovered = false;
|
|
7967
8086
|
this.dateTo = null;
|
|
7968
8087
|
this.dateFrom = null;
|
|
7969
8088
|
this.month = null;
|
|
@@ -7971,7 +8090,6 @@ class AuroCalendarCell extends i$1 {
|
|
|
7971
8090
|
this.max = null;
|
|
7972
8091
|
this.disabled = false;
|
|
7973
8092
|
this.disabledDays = [];
|
|
7974
|
-
this.hoveredDate = null;
|
|
7975
8093
|
this.isCurrentDate = false;
|
|
7976
8094
|
this._locale = null;
|
|
7977
8095
|
this.dateStr = null;
|
|
@@ -7996,7 +8114,6 @@ class AuroCalendarCell extends i$1 {
|
|
|
7996
8114
|
// ...super.properties,
|
|
7997
8115
|
day: { type: Object },
|
|
7998
8116
|
selected: { type: Boolean },
|
|
7999
|
-
hovered: { type: Boolean },
|
|
8000
8117
|
dateTo: { type: String },
|
|
8001
8118
|
dateFrom: { type: String },
|
|
8002
8119
|
month: { type: String },
|
|
@@ -8007,15 +8124,10 @@ class AuroCalendarCell extends i$1 {
|
|
|
8007
8124
|
reflect: true
|
|
8008
8125
|
},
|
|
8009
8126
|
disabledDays: { type: Array },
|
|
8010
|
-
hoveredDate: { type: String },
|
|
8011
8127
|
isCurrentDate: { type: Boolean },
|
|
8012
8128
|
locale: { type: Object },
|
|
8013
8129
|
dateStr: { type: String },
|
|
8014
8130
|
renderForDateSlot: { type: Boolean },
|
|
8015
|
-
active: {
|
|
8016
|
-
type: Boolean,
|
|
8017
|
-
reflect: true
|
|
8018
|
-
},
|
|
8019
8131
|
hasPopoverContent: { type: Boolean }
|
|
8020
8132
|
};
|
|
8021
8133
|
}
|
|
@@ -8040,17 +8152,17 @@ class AuroCalendarCell extends i$1 {
|
|
|
8040
8152
|
}
|
|
8041
8153
|
|
|
8042
8154
|
/**
|
|
8043
|
-
* Handles selected
|
|
8155
|
+
* Handles selected state of the calendar cell when the selection changes.
|
|
8156
|
+
* Also clears any imperative range preview classes so classMap is the
|
|
8157
|
+
* sole source of truth after a selection update.
|
|
8044
8158
|
* @private
|
|
8045
8159
|
* @param {Number} dateFrom - Depart date.
|
|
8046
8160
|
* @param {Number} dateTo - Return date.
|
|
8047
|
-
* @param {Number} hoveredDate - Hovered date.
|
|
8048
8161
|
* @param {Object} day - An object containing the dateFrom and day of month values.
|
|
8049
8162
|
* @returns {void}
|
|
8050
8163
|
*/
|
|
8051
|
-
dateChanged(dateFrom, dateTo,
|
|
8164
|
+
dateChanged(dateFrom, dateTo, day) {
|
|
8052
8165
|
this.selected = false;
|
|
8053
|
-
this.hovered = false;
|
|
8054
8166
|
|
|
8055
8167
|
const parsedDateFrom = parseInt(dateFrom, 10);
|
|
8056
8168
|
const parsedDateTo = parseInt(dateTo, 10);
|
|
@@ -8062,10 +8174,6 @@ class AuroCalendarCell extends i$1 {
|
|
|
8062
8174
|
if (day.date === departTimestamp || day.date === returnTimestamp) {
|
|
8063
8175
|
this.selected = true;
|
|
8064
8176
|
}
|
|
8065
|
-
|
|
8066
|
-
if (((hoveredDate === day.date || day.date < hoveredDate) && day.date > parsedDateFrom && !parsedDateTo && !Number.isNaN(parsedDateFrom) && parsedDateFrom !== undefined && !this.selected) || (day.date > parsedDateFrom && day.date < parsedDateTo)) {
|
|
8067
|
-
this.hovered = true;
|
|
8068
|
-
}
|
|
8069
8177
|
}
|
|
8070
8178
|
}
|
|
8071
8179
|
|
|
@@ -8091,16 +8199,30 @@ class AuroCalendarCell extends i$1 {
|
|
|
8091
8199
|
|
|
8092
8200
|
/**
|
|
8093
8201
|
* Handles user hover events and dispatches a custom event.
|
|
8094
|
-
*
|
|
8202
|
+
* Does NOT set any reactive properties — the range preview is handled
|
|
8203
|
+
* imperatively by the calendar component to avoid O(N) re-renders.
|
|
8095
8204
|
* @private
|
|
8096
8205
|
* @returns {void}
|
|
8097
8206
|
*/
|
|
8098
8207
|
handleHover() {
|
|
8099
|
-
this.hovered = true;
|
|
8100
|
-
|
|
8101
|
-
let _a;
|
|
8102
8208
|
this.dispatchEvent(new CustomEvent('date-is-hovered', {
|
|
8103
|
-
detail: { date:
|
|
8209
|
+
detail: { date: this.day?.date },
|
|
8210
|
+
}));
|
|
8211
|
+
}
|
|
8212
|
+
|
|
8213
|
+
/**
|
|
8214
|
+
* Handles focus events on the cell button.
|
|
8215
|
+
* Dispatches a lightweight event for the calendar to handle SR
|
|
8216
|
+
* announcements and range preview updates without triggering
|
|
8217
|
+
* any Lit lifecycle updates.
|
|
8218
|
+
* @private
|
|
8219
|
+
* @returns {void}
|
|
8220
|
+
*/
|
|
8221
|
+
handleFocus() {
|
|
8222
|
+
this.dispatchEvent(new CustomEvent('calendar-cell-focused', {
|
|
8223
|
+
bubbles: true,
|
|
8224
|
+
composed: true,
|
|
8225
|
+
detail: { date: this.day?.date },
|
|
8104
8226
|
}));
|
|
8105
8227
|
}
|
|
8106
8228
|
|
|
@@ -8114,7 +8236,7 @@ class AuroCalendarCell extends i$1 {
|
|
|
8114
8236
|
* @returns {Boolean} - True if the date is out of range.
|
|
8115
8237
|
*/
|
|
8116
8238
|
isOutOfRange(day, min, max) {
|
|
8117
|
-
if (day && day.date
|
|
8239
|
+
if (day && day.date !== null && day.date !== undefined) {
|
|
8118
8240
|
return day.date < min || day.date > max;
|
|
8119
8241
|
}
|
|
8120
8242
|
return false;
|
|
@@ -8127,13 +8249,13 @@ class AuroCalendarCell extends i$1 {
|
|
|
8127
8249
|
* @returns {Boolean} - True if the date is a blackout date.
|
|
8128
8250
|
*/
|
|
8129
8251
|
isBlackout() {
|
|
8130
|
-
if (!this.day || this.day.date
|
|
8252
|
+
if (!this.day || this.day.date === null || this.day.date === undefined || this.isOutOfRange(this.day, this.min, this.max)) {
|
|
8131
8253
|
return false;
|
|
8132
8254
|
}
|
|
8133
8255
|
|
|
8134
8256
|
// Check against disabledDays timestamps (legacy path)
|
|
8135
8257
|
if (Array.isArray(this.disabledDays) && this.disabledDays.length > 0) {
|
|
8136
|
-
if (this.disabledDays.findIndex(
|
|
8258
|
+
if (this.disabledDays.findIndex(dd => parseInt(dd, 10) === this.day.date) !== -1) {
|
|
8137
8259
|
return true;
|
|
8138
8260
|
}
|
|
8139
8261
|
}
|
|
@@ -8215,12 +8337,26 @@ class AuroCalendarCell extends i$1 {
|
|
|
8215
8337
|
|
|
8216
8338
|
let label = dateFormatter.format(date);
|
|
8217
8339
|
|
|
8340
|
+
// Append date slot content (e.g. prices) so it is announced with the date.
|
|
8341
|
+
if (this.renderForDateSlot) {
|
|
8342
|
+
const dateSlotEl = this.querySelector(`[slot="date_${this.dateStr}"]`);
|
|
8343
|
+
if (dateSlotEl) {
|
|
8344
|
+
const text = dateSlotEl.innerText?.trim();
|
|
8345
|
+
if (text) {
|
|
8346
|
+
label += `, ${text}`;
|
|
8347
|
+
}
|
|
8348
|
+
}
|
|
8349
|
+
}
|
|
8350
|
+
|
|
8218
8351
|
// appending popover content here so that it gets read in a logical order with the other date content.
|
|
8219
8352
|
if (this.hasPopoverContent) {
|
|
8220
|
-
|
|
8353
|
+
const popoverEl = this.querySelector(`[slot="popover_${this.dateStr}"]`);
|
|
8354
|
+
if (popoverEl) {
|
|
8355
|
+
label += `, ${popoverEl.innerText.trim()}`;
|
|
8356
|
+
}
|
|
8221
8357
|
}
|
|
8222
8358
|
|
|
8223
|
-
// Append range position
|
|
8359
|
+
// Append range position label for range datepickers
|
|
8224
8360
|
const rangePosition = this.getRangePosition();
|
|
8225
8361
|
if (rangePosition) {
|
|
8226
8362
|
label += `, ${rangePosition}`;
|
|
@@ -8331,12 +8467,12 @@ class AuroCalendarCell extends i$1 {
|
|
|
8331
8467
|
}
|
|
8332
8468
|
|
|
8333
8469
|
/**
|
|
8334
|
-
* Checks if the current date is a
|
|
8470
|
+
* Checks if the current date is a referenced date.
|
|
8335
8471
|
* @param {Object} dateStr - The date string in MM_DD_YYYY format.
|
|
8336
|
-
* @returns Boolean - True if the date is a
|
|
8472
|
+
* @returns Boolean - True if the date is a referenced date.
|
|
8337
8473
|
*/
|
|
8338
8474
|
isReferenceDate(dateStr) {
|
|
8339
|
-
// If the datepicker has
|
|
8475
|
+
// If the datepicker has referenced dates specified
|
|
8340
8476
|
if (this.datepicker && this.datepicker.hasAttribute('referenceDates')) {
|
|
8341
8477
|
|
|
8342
8478
|
// Get the referenceDates attribute from the datepicker
|
|
@@ -8450,6 +8586,11 @@ class AuroCalendarCell extends i$1 {
|
|
|
8450
8586
|
};
|
|
8451
8587
|
this.datepicker.addEventListener('auroDatePicker-newSlotContent', this._slotContentHandler);
|
|
8452
8588
|
|
|
8589
|
+
// Cache button reference for imperative class manipulation.
|
|
8590
|
+
this.updateComplete.then(() => {
|
|
8591
|
+
this._cachedButton = this.shadowRoot.querySelector('button.day');
|
|
8592
|
+
});
|
|
8593
|
+
|
|
8453
8594
|
// Trigger an initial update now that `this.datepicker` is assigned so
|
|
8454
8595
|
// cells reflect blackout/slot state that was configured before first render.
|
|
8455
8596
|
this.requestUpdate();
|
|
@@ -8481,13 +8622,26 @@ class AuroCalendarCell extends i$1 {
|
|
|
8481
8622
|
}
|
|
8482
8623
|
|
|
8483
8624
|
updated(properties) {
|
|
8484
|
-
if (properties.has('dateFrom') || properties.has('dateTo') || properties.has('
|
|
8485
|
-
this.dateChanged(this.dateFrom, this.dateTo, this.
|
|
8625
|
+
if (properties.has('dateFrom') || properties.has('dateTo') || properties.has('day')) {
|
|
8626
|
+
this.dateChanged(this.dateFrom, this.dateTo, this.day);
|
|
8486
8627
|
}
|
|
8487
8628
|
|
|
8488
|
-
if (this.day) {
|
|
8629
|
+
if (properties.has('day') && this.day) {
|
|
8489
8630
|
this.setDateSlotName();
|
|
8490
8631
|
this.handleSlotContent();
|
|
8632
|
+
|
|
8633
|
+
// Re-cache button reference when the day changes (cell may have re-rendered).
|
|
8634
|
+
this.updateComplete.then(() => {
|
|
8635
|
+
this._cachedButton = this.shadowRoot.querySelector('button.day');
|
|
8636
|
+
});
|
|
8637
|
+
|
|
8638
|
+
// Update host-level aria attributes for ariaActiveDescendantElement.
|
|
8639
|
+
this.updateHostAria();
|
|
8640
|
+
}
|
|
8641
|
+
|
|
8642
|
+
// Update host aria when selection changes (aria-selected, range labels)
|
|
8643
|
+
if (properties.has('dateFrom') || properties.has('dateTo') || properties.has('selected')) {
|
|
8644
|
+
this.updateHostAria();
|
|
8491
8645
|
}
|
|
8492
8646
|
|
|
8493
8647
|
// Configure popover when it first becomes rendered
|
|
@@ -8497,64 +8651,165 @@ class AuroCalendarCell extends i$1 {
|
|
|
8497
8651
|
}
|
|
8498
8652
|
|
|
8499
8653
|
/**
|
|
8500
|
-
*
|
|
8654
|
+
* Updates ARIA attributes on the host element so that
|
|
8655
|
+
* ariaActiveDescendantElement can expose cell info to the SR.
|
|
8656
|
+
* @private
|
|
8657
|
+
* @returns {void}
|
|
8658
|
+
*/
|
|
8659
|
+
updateHostAria() {
|
|
8660
|
+
if (!this.day || this.day.date === undefined) return;
|
|
8661
|
+
|
|
8662
|
+
const outOfRange = this.isOutOfRange(this.day, this.min, this.max);
|
|
8663
|
+
if (outOfRange) {
|
|
8664
|
+
this.removeAttribute('role');
|
|
8665
|
+
this.removeAttribute('aria-label');
|
|
8666
|
+
return;
|
|
8667
|
+
}
|
|
8668
|
+
|
|
8669
|
+
// The host acts as the gridcell for ariaActiveDescendantElement.
|
|
8670
|
+
this.setAttribute('role', 'gridcell');
|
|
8671
|
+
this.setAttribute('aria-label', this.getAriaLabel());
|
|
8672
|
+
this.setAttribute('aria-selected', this.selected ? 'true' : 'false');
|
|
8673
|
+
|
|
8674
|
+
if (this.isBlackout()) {
|
|
8675
|
+
this.setAttribute('aria-disabled', 'true');
|
|
8676
|
+
} else {
|
|
8677
|
+
this.removeAttribute('aria-disabled');
|
|
8678
|
+
}
|
|
8679
|
+
}
|
|
8680
|
+
|
|
8681
|
+
/**
|
|
8682
|
+
* Programmatically focuses the cell's interactive button element.
|
|
8683
|
+
* Uses focusVisible: true so the :focus-visible ring appears even when
|
|
8684
|
+
* the bib was opened via mouse click (which sets mouse input modality).
|
|
8501
8685
|
* @returns {void}
|
|
8502
8686
|
*/
|
|
8503
8687
|
focusButton() {
|
|
8504
|
-
const button = this.shadowRoot.querySelector('button:not([aria-hidden])');
|
|
8688
|
+
const button = this._cachedButton || this.shadowRoot.querySelector('button:not([aria-hidden])');
|
|
8505
8689
|
if (button) {
|
|
8506
|
-
button.focus();
|
|
8690
|
+
button.focus({ focusVisible: true });
|
|
8691
|
+
}
|
|
8692
|
+
}
|
|
8693
|
+
|
|
8694
|
+
/**
|
|
8695
|
+
* Imperatively marks this cell as active without triggering a Lit re-render.
|
|
8696
|
+
* Note: buttons stay tabindex="-1" because the grid uses aria-activedescendant.
|
|
8697
|
+
* @returns {void}
|
|
8698
|
+
*/
|
|
8699
|
+
setActive() {
|
|
8700
|
+
this.active = true;
|
|
8701
|
+
|
|
8702
|
+
// Show the popover when this cell becomes active via keyboard navigation.
|
|
8703
|
+
if (this.auroPopover) {
|
|
8704
|
+
this.auroPopover.toggleShow();
|
|
8705
|
+
}
|
|
8706
|
+
}
|
|
8707
|
+
|
|
8708
|
+
/**
|
|
8709
|
+
* Imperatively marks this cell as inactive without triggering a Lit re-render.
|
|
8710
|
+
* @returns {void}
|
|
8711
|
+
*/
|
|
8712
|
+
clearActive() {
|
|
8713
|
+
this.active = false;
|
|
8714
|
+
const btn = this._cachedButton || this.shadowRoot.querySelector('button.day');
|
|
8715
|
+
if (btn) {
|
|
8716
|
+
btn.classList.remove('activeCell');
|
|
8717
|
+
}
|
|
8718
|
+
|
|
8719
|
+
// Hide the popover when this cell loses active state.
|
|
8720
|
+
if (this.auroPopover) {
|
|
8721
|
+
this.auroPopover.toggleHide();
|
|
8507
8722
|
}
|
|
8508
8723
|
}
|
|
8509
8724
|
|
|
8725
|
+
/**
|
|
8726
|
+
* Updates range preview classes imperatively (no Lit re-render).
|
|
8727
|
+
* Called by the calendar component when the hovered date changes
|
|
8728
|
+
* during range selection (dateFrom set, dateTo not yet set).
|
|
8729
|
+
* @param {Number} hoveredDate - Unix timestamp of the currently hovered/focused date.
|
|
8730
|
+
* @param {Number} dateFrom - Unix timestamp of the selected departure date.
|
|
8731
|
+
* @returns {void}
|
|
8732
|
+
*/
|
|
8733
|
+
updateRangePreviewClasses(hoveredDate, dateFrom) {
|
|
8734
|
+
const btn = this._cachedButton;
|
|
8735
|
+
if (!btn || !this.day) return;
|
|
8736
|
+
|
|
8737
|
+
const dayDate = this.day.date;
|
|
8738
|
+
const departTimestamp = startOfDay(dateFrom * 1000) / 1000;
|
|
8739
|
+
const isInRange = dayDate > departTimestamp && dayDate < hoveredDate;
|
|
8740
|
+
const isLastHovered = dayDate === hoveredDate && hoveredDate > departTimestamp;
|
|
8741
|
+
const isDepartWithPreview = dayDate === departTimestamp && hoveredDate > departTimestamp;
|
|
8742
|
+
|
|
8743
|
+
btn.classList.toggle('inRange', isInRange);
|
|
8744
|
+
btn.classList.toggle('lastHoveredDate', isLastHovered);
|
|
8745
|
+
btn.classList.toggle('rangeDepartDate', isDepartWithPreview);
|
|
8746
|
+
}
|
|
8747
|
+
|
|
8748
|
+
/**
|
|
8749
|
+
* Clears all imperative range preview classes from the cell button.
|
|
8750
|
+
* Called when a selection occurs so classMap becomes the sole source of truth.
|
|
8751
|
+
* @returns {void}
|
|
8752
|
+
*/
|
|
8753
|
+
clearRangePreviewClasses() {
|
|
8754
|
+
const btn = this._cachedButton;
|
|
8755
|
+
if (!btn) return;
|
|
8756
|
+
|
|
8757
|
+
btn.classList.remove('inRange', 'lastHoveredDate', 'rangeDepartDate');
|
|
8758
|
+
}
|
|
8759
|
+
|
|
8510
8760
|
renderCellButton() {
|
|
8511
8761
|
const outOfRange = this.isOutOfRange(this.day, this.min, this.max);
|
|
8512
|
-
const role = outOfRange ? 'presentation' : 'gridcell';
|
|
8513
8762
|
const blackout = this.isBlackout();
|
|
8514
8763
|
|
|
8764
|
+
// Static and selection-driven classes only. Hover-driven classes
|
|
8765
|
+
// (inRange, lastHoveredDate, rangeDepartDate during preview) are
|
|
8766
|
+
// managed imperatively via updateRangePreviewClasses() to avoid
|
|
8767
|
+
// O(N) Lit re-renders on every focus/hover event.
|
|
8768
|
+
const isFirstDay = this.day?.title === 1;
|
|
8769
|
+
const isLastDay = this.day?.date && (() => {
|
|
8770
|
+
const dt = new Date(this.day.date * 1000);
|
|
8771
|
+
return dt.getDate() === new Date(dt.getFullYear(), dt.getMonth() + 1, 0).getDate();
|
|
8772
|
+
})();
|
|
8773
|
+
|
|
8515
8774
|
const buttonClasses = {
|
|
8516
8775
|
'day': true,
|
|
8517
|
-
'body-
|
|
8776
|
+
'body-default': true,
|
|
8518
8777
|
'currentDate': this.isCurrentDate,
|
|
8519
8778
|
'selected': this.selected,
|
|
8520
|
-
'inRange': this.datepicker?.hasAttribute('range') && this.
|
|
8521
|
-
'lastHoveredDate': this.isLastHoveredDate(this.day, this.dateFrom, this.dateTo, this.hoveredDate) && this.datepicker && this.datepicker.hasAttribute('range'),
|
|
8779
|
+
'inRange': this.datepicker?.hasAttribute('range') && this.dateTo && this.isInRange(this.day, this.dateFrom, this.dateTo),
|
|
8522
8780
|
'disabled': outOfRange,
|
|
8523
|
-
|
|
8524
|
-
'rangeDepartDate': this.datepicker?.hasAttribute('range') && this.isDepartDate(this.day, this.dateFrom) &&
|
|
8781
|
+
blackout,
|
|
8782
|
+
'rangeDepartDate': this.datepicker?.hasAttribute('range') && this.isDepartDate(this.day, this.dateFrom) && this.dateTo,
|
|
8525
8783
|
'rangeReturnDate': this.datepicker?.hasAttribute('range') && this.isReturnDate(this.day, this.dateFrom, this.dateTo),
|
|
8526
8784
|
'reference': this.isReferenceDate(this.dateStr),
|
|
8527
|
-
'sameDateTrip': this.datepicker?.hasAttribute('range') && this.dateFrom === this.dateTo
|
|
8785
|
+
'sameDateTrip': this.datepicker?.hasAttribute('range') && this.dateFrom === this.dateTo,
|
|
8786
|
+
'firstDayOfMonth': isFirstDay,
|
|
8787
|
+
'lastDayOfMonth': isLastDay,
|
|
8528
8788
|
};
|
|
8529
8789
|
|
|
8530
8790
|
return u$a`
|
|
8531
8791
|
<button
|
|
8532
8792
|
slot="trigger"
|
|
8533
8793
|
id="${this.getCellId()}"
|
|
8534
|
-
role="${role}"
|
|
8535
8794
|
@click="${outOfRange ? undefined : this.handleTap}"
|
|
8536
8795
|
@mouseover="${outOfRange ? undefined : this.handleHover}"
|
|
8537
|
-
@focus="${outOfRange ? undefined : this.
|
|
8796
|
+
@focus="${outOfRange ? undefined : this.handleFocus}"
|
|
8538
8797
|
class="${e$4(buttonClasses)}"
|
|
8539
8798
|
?disabled="${outOfRange}"
|
|
8540
|
-
aria-disabled="${blackout ? 'true' : A$4}"
|
|
8541
8799
|
aria-hidden="${outOfRange ? 'true' : A$4}"
|
|
8542
|
-
|
|
8543
|
-
aria-current="${this.isCurrentDate ? 'date' : A$4}"
|
|
8544
|
-
tabindex="${this.active ? '0' : '-1'}">
|
|
8545
|
-
<span class="srOnly">${this.getAriaLabel()}</span>
|
|
8800
|
+
tabindex="-1">
|
|
8546
8801
|
<div class="buttonWrapper" aria-hidden="true">
|
|
8547
8802
|
<div class="currentDayMarker">${this.day?.title || A$4}</div>
|
|
8548
|
-
|
|
8549
|
-
|
|
8550
|
-
|
|
8803
|
+
<div class="dateSlot body-2xs" part="dateSlot" aria-hidden="true" ?hidden="${!this.renderForDateSlot}">
|
|
8804
|
+
<slot name="date_${this.dateStr}"></slot>
|
|
8805
|
+
</div>
|
|
8551
8806
|
</div>
|
|
8552
8807
|
</button>
|
|
8553
8808
|
`;
|
|
8554
8809
|
}
|
|
8555
8810
|
|
|
8556
8811
|
render() {
|
|
8557
|
-
const hasPopoverContent = this
|
|
8812
|
+
const { hasPopoverContent } = this;
|
|
8558
8813
|
|
|
8559
8814
|
if (hasPopoverContent) {
|
|
8560
8815
|
return u$a`
|
|
@@ -8684,7 +8939,7 @@ class AuroCalendarMonth extends RangeDatepickerCalendar {
|
|
|
8684
8939
|
*/
|
|
8685
8940
|
renderDayOfWeek(dayOfWeek, index) {
|
|
8686
8941
|
const fullName = this.dayFullNames ? this.dayFullNames[index] : dayOfWeek;
|
|
8687
|
-
return b$5`<div class="th body-default"
|
|
8942
|
+
return b$5`<div class="th body-default"><abbr title="${fullName}">${dayOfWeek}</abbr></div>`;
|
|
8688
8943
|
}
|
|
8689
8944
|
|
|
8690
8945
|
/**
|
|
@@ -8693,92 +8948,39 @@ class AuroCalendarMonth extends RangeDatepickerCalendar {
|
|
|
8693
8948
|
*/
|
|
8694
8949
|
getFocusableCells() {
|
|
8695
8950
|
const cells = Array.from(this.shadowRoot.querySelectorAll('auro-formkit-calendar-cell'));
|
|
8696
|
-
return cells.filter(cell => {
|
|
8697
|
-
if (!cell.day)
|
|
8951
|
+
return cells.filter((cell) => {
|
|
8952
|
+
if (!cell.day) {
|
|
8953
|
+
return false;
|
|
8954
|
+
}
|
|
8698
8955
|
return !cell.isOutOfRange(cell.day, cell.min, cell.max);
|
|
8699
8956
|
});
|
|
8700
8957
|
}
|
|
8701
8958
|
|
|
8702
8959
|
/**
|
|
8703
|
-
*
|
|
8704
|
-
*
|
|
8960
|
+
* Overrides the base class handler to prevent setting `this.hoveredDate`
|
|
8961
|
+
* as a reactive property. Instead, just dispatches the event upward so
|
|
8962
|
+
* the calendar can handle range preview imperatively.
|
|
8705
8963
|
* @private
|
|
8706
|
-
* @param {
|
|
8964
|
+
* @param {CustomEvent} event - The date-is-hovered event from a cell.
|
|
8707
8965
|
* @returns {void}
|
|
8708
8966
|
*/
|
|
8709
|
-
|
|
8710
|
-
|
|
8711
|
-
|
|
8712
|
-
|
|
8713
|
-
|
|
8714
|
-
|
|
8715
|
-
event.preventDefault();
|
|
8716
|
-
|
|
8717
|
-
const focusableCells = this.getFocusableCells();
|
|
8718
|
-
if (focusableCells.length === 0) return;
|
|
8719
|
-
|
|
8720
|
-
// Find the currently active cell within this month
|
|
8721
|
-
const activeCell = focusableCells.find(cell => cell.active);
|
|
8722
|
-
if (!activeCell) return;
|
|
8723
|
-
|
|
8724
|
-
const activeIndex = focusableCells.indexOf(activeCell);
|
|
8725
|
-
let targetCell = null;
|
|
8726
|
-
|
|
8727
|
-
if (key === 'ArrowRight') {
|
|
8728
|
-
if (activeIndex < focusableCells.length - 1) {
|
|
8729
|
-
targetCell = focusableCells[activeIndex + 1];
|
|
8730
|
-
} else {
|
|
8731
|
-
// At end of month, request cross-month navigation
|
|
8732
|
-
this.dispatchEvent(new CustomEvent('calendar-month-boundary', {
|
|
8733
|
-
bubbles: true,
|
|
8734
|
-
composed: true,
|
|
8735
|
-
detail: { direction: 'next', fromDate: activeCell.day.date, key }
|
|
8736
|
-
}));
|
|
8737
|
-
return;
|
|
8738
|
-
}
|
|
8739
|
-
} else if (key === 'ArrowLeft') {
|
|
8740
|
-
if (activeIndex > 0) {
|
|
8741
|
-
targetCell = focusableCells[activeIndex - 1];
|
|
8742
|
-
} else {
|
|
8743
|
-
// At start of month, request cross-month navigation
|
|
8744
|
-
this.dispatchEvent(new CustomEvent('calendar-month-boundary', {
|
|
8745
|
-
bubbles: true,
|
|
8746
|
-
composed: true,
|
|
8747
|
-
detail: { direction: 'prev', fromDate: activeCell.day.date, key }
|
|
8748
|
-
}));
|
|
8749
|
-
return;
|
|
8750
|
-
}
|
|
8751
|
-
} else if (key === 'ArrowDown' || key === 'ArrowUp') {
|
|
8752
|
-
// Find the target day (same day-of-week, +/- 7 days)
|
|
8753
|
-
// Use Date arithmetic instead of fixed seconds to handle DST correctly
|
|
8754
|
-
const increment = key === 'ArrowDown' ? 7 : -7;
|
|
8755
|
-
const currentDate = new Date(activeCell.day.date * 1000);
|
|
8756
|
-
currentDate.setDate(currentDate.getDate() + increment);
|
|
8757
|
-
currentDate.setHours(0, 0, 0, 0);
|
|
8758
|
-
const targetDate = Math.floor(currentDate.getTime() / 1000);
|
|
8759
|
-
|
|
8760
|
-
// Look for the target date in this month's focusable cells
|
|
8761
|
-
targetCell = focusableCells.find(cell => cell.day.date === targetDate);
|
|
8762
|
-
|
|
8763
|
-
if (!targetCell) {
|
|
8764
|
-
// Target is in another month or all cells in that direction are disabled
|
|
8765
|
-
const direction = key === 'ArrowDown' ? 'next' : 'prev';
|
|
8766
|
-
this.dispatchEvent(new CustomEvent('calendar-month-boundary', {
|
|
8767
|
-
bubbles: true,
|
|
8768
|
-
composed: true,
|
|
8769
|
-
detail: { direction, fromDate: activeCell.day.date, key }
|
|
8770
|
-
}));
|
|
8771
|
-
return;
|
|
8772
|
-
}
|
|
8773
|
-
}
|
|
8967
|
+
handleDateHovered(event) {
|
|
8968
|
+
this.dispatchEvent(new CustomEvent('hovered-date-changed', {
|
|
8969
|
+
detail: { value: event.detail.date },
|
|
8970
|
+
}));
|
|
8971
|
+
}
|
|
8774
8972
|
|
|
8775
|
-
|
|
8776
|
-
|
|
8777
|
-
|
|
8778
|
-
|
|
8779
|
-
|
|
8780
|
-
|
|
8781
|
-
|
|
8973
|
+
/**
|
|
8974
|
+
* Dispatches a bubbling event when the mouse leaves the date grid body
|
|
8975
|
+
* so the parent calendar can clear the range hover preview.
|
|
8976
|
+
* @private
|
|
8977
|
+
* @returns {void}
|
|
8978
|
+
*/
|
|
8979
|
+
handleTbodyMouseLeave() {
|
|
8980
|
+
this.dispatchEvent(new CustomEvent('calendar-month-mouseleave', {
|
|
8981
|
+
bubbles: true,
|
|
8982
|
+
composed: true,
|
|
8983
|
+
}));
|
|
8782
8984
|
}
|
|
8783
8985
|
|
|
8784
8986
|
renderWeek(week) {
|
|
@@ -8797,7 +8999,6 @@ class AuroCalendarMonth extends RangeDatepickerCalendar {
|
|
|
8797
8999
|
.min="${this.min}"
|
|
8798
9000
|
.max="${this.max}"
|
|
8799
9001
|
.month="${this.month}"
|
|
8800
|
-
.hoveredDate="${this.hoveredDate}"
|
|
8801
9002
|
.dateTo="${this.dateTo}"
|
|
8802
9003
|
.dateFrom="${this.dateFrom}"
|
|
8803
9004
|
.locale="${this.locale}"
|
|
@@ -8819,10 +9020,10 @@ class AuroCalendarMonth extends RangeDatepickerCalendar {
|
|
|
8819
9020
|
var _a, _b;
|
|
8820
9021
|
|
|
8821
9022
|
return b$5 `
|
|
8822
|
-
<div
|
|
9023
|
+
<div>
|
|
8823
9024
|
<div class="header">
|
|
8824
9025
|
${this.renderPrevButton()}
|
|
8825
|
-
<div class="headerTitle heading-xs" id="${this.getHeadingId()}" aria-
|
|
9026
|
+
<div class="headerTitle heading-xs" id="${this.getHeadingId()}" aria-hidden="true">
|
|
8826
9027
|
${this.monthFirst ? b$5`
|
|
8827
9028
|
<div>${this.computeCurrentMonthName(this.month)}</div>
|
|
8828
9029
|
<div>${this.renderYear()}</div>
|
|
@@ -8834,13 +9035,13 @@ class AuroCalendarMonth extends RangeDatepickerCalendar {
|
|
|
8834
9035
|
${this.renderNextButton()}
|
|
8835
9036
|
</div>
|
|
8836
9037
|
|
|
8837
|
-
<div class="table" role="grid"
|
|
8838
|
-
<div class="thead"
|
|
8839
|
-
<div class="tr"
|
|
9038
|
+
<div class="table" role="grid">
|
|
9039
|
+
<div class="thead" aria-hidden="true">
|
|
9040
|
+
<div class="tr">
|
|
8840
9041
|
${(_a = this.dayNamesOfTheWeek) === null || _a === void 0 ? void 0 : _a.map((dayNameOfWeek, index) => this.renderDayOfWeek(dayNameOfWeek, index))}
|
|
8841
9042
|
</div>
|
|
8842
9043
|
</div>
|
|
8843
|
-
<div class="tbody" role="rowgroup">
|
|
9044
|
+
<div class="tbody" role="rowgroup" @mouseleave="${this.handleTbodyMouseLeave}">
|
|
8844
9045
|
${(_b = this.daysOfMonth) === null || _b === void 0 ? void 0 : _b.map(week => this.renderWeek(week))}
|
|
8845
9046
|
</div>
|
|
8846
9047
|
</div>
|
|
@@ -9658,7 +9859,7 @@ class AuroBibtemplate extends i$1 {
|
|
|
9658
9859
|
}
|
|
9659
9860
|
}
|
|
9660
9861
|
|
|
9661
|
-
var formkitVersion$2 = '
|
|
9862
|
+
var formkitVersion$2 = '202606030033';
|
|
9662
9863
|
|
|
9663
9864
|
let l$1 = class l{generateElementName(t,e){let o=t;return o+="-",o+=e.replace(/[.]/g,"_"),o}generateTag(o,s,a){const r=this.generateElementName(o,s),i=i$5`${s$5(r)}`;return customElements.get(r)||customElements.define(r,class extends a{}),i}};let d$1 = class d{registerComponent(t,e){customElements.get(t)||customElements.define(t,class extends e{});}closestElement(t,e=this,o=(e,s=e&&e.closest(t))=>e&&e!==document&&e!==window?s||o(e.getRootNode().host):null){return o(e)}handleComponentTagRename(t,e){const o=e.toLowerCase();t.tagName.toLowerCase()!==o&&t.setAttribute(o,true);}elementMatch(t,e){const o=e.toLowerCase();return t.tagName.toLowerCase()===o||t.hasAttribute(o)}getSlotText(t,e){const o=t.shadowRoot?.querySelector(`slot[name="${e}"]`),s=(o?.assignedNodes({flatten:true})||[]).map(t=>t.textContent?.trim()).join(" ").trim();return s||null}};let h$4 = class h{registerComponent(t,e){customElements.get(t)||customElements.define(t,class extends e{});}closestElement(t,e=this,o=(e,s=e&&e.closest(t))=>e&&e!==document&&e!==window?s||o(e.getRootNode().host):null){return o(e)}handleComponentTagRename(t,e){const o=e.toLowerCase();t.tagName.toLowerCase()!==o&&t.setAttribute(o,true);}elementMatch(t,e){const o=e.toLowerCase();return t.tagName.toLowerCase()===o||t.hasAttribute(o)}};var c$3=i$3`:host{color:var(--ds-auro-loader-color)}:host>span{background-color:var(--ds-auro-loader-background-color);border-color:var(--ds-auro-loader-border-color)}:host([onlight]),:host([appearance=brand]){--ds-auro-loader-color: var(--ds-basic-color-brand-primary, #01426a)}:host([ondark]),:host([appearance=inverse]){--ds-auro-loader-color: var(--ds-basic-color-texticon-inverse, #ffffff)}:host([orbit])>span{--ds-auro-loader-background-color: transparent}:host([orbit])>span:nth-child(1){--ds-auro-loader-border-color: currentcolor;opacity:.25}:host([orbit])>span:nth-child(2){--ds-auro-loader-border-color: currentcolor;border-right-color:transparent;border-bottom-color:transparent;border-left-color:transparent}
|
|
9664
9865
|
`,u$6=i$3`.body-default{font-size:var(--wcss-body-default-font-size, 1rem);line-height:var(--wcss-body-default-line-height, 1.5rem)}.body-default,.body-lg{font-family:var(--wcss-body-family, "AS Circular"),system-ui,-apple-system,BlinkMacSystemFont,"Segoe UI",Roboto,"Helvetica Neue",Arial,sans-serif;font-weight:var(--wcss-body-weight, 450);letter-spacing:var(--wcss-body-letter-spacing, 0)}.body-lg{font-size:var(--wcss-body-lg-font-size, 1.125rem);line-height:var(--wcss-body-lg-line-height, 1.625rem)}.body-sm{font-size:var(--wcss-body-sm-font-size, .875rem);line-height:var(--wcss-body-sm-line-height, 1.25rem)}.body-sm,.body-xs{font-family:var(--wcss-body-family, "AS Circular"),system-ui,-apple-system,BlinkMacSystemFont,"Segoe UI",Roboto,"Helvetica Neue",Arial,sans-serif;font-weight:var(--wcss-body-weight, 450);letter-spacing:var(--wcss-body-letter-spacing, 0)}.body-xs{font-size:var(--wcss-body-xs-font-size, .75rem);line-height:var(--wcss-body-xs-line-height, 1rem)}.body-2xs{font-family:var(--wcss-body-family, "AS Circular"),system-ui,-apple-system,BlinkMacSystemFont,"Segoe UI",Roboto,"Helvetica Neue",Arial,sans-serif;font-size:var(--wcss-body-2xs-font-size, .625rem);font-weight:var(--wcss-body-weight, 450);letter-spacing:var(--wcss-body-letter-spacing, 0);line-height:var(--wcss-body-2xs-line-height, .875rem)}.display-2xl{font-family:var(--wcss-display-2xl-family, "AS Circular"),var(--wcss-display-2xl-family-fallback, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif);font-size:var(--wcss-display-2xl-font-size, clamp(3.5rem, 6vw, 5.375rem));font-weight:var(--wcss-display-2xl-weight, 300);letter-spacing:var(--wcss-display-2xl-letter-spacing, 0);line-height:var(--wcss-display-2xl-line-height, 1.3)}.display-xl{font-family:var(--wcss-display-xl-family, "AS Circular"),var(--wcss-display-xl-family-fallback, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif);font-size:var(--wcss-display-xl-font-size, clamp(3rem, 5.3333333333vw, 4.5rem));font-weight:var(--wcss-display-xl-weight, 300);letter-spacing:var(--wcss-display-xl-letter-spacing, 0);line-height:var(--wcss-display-xl-line-height, 1.3)}.display-lg{font-family:var(--wcss-display-lg-family, "AS Circular"),var(--wcss-display-lg-family-fallback, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif);font-size:var(--wcss-display-lg-font-size, clamp(2.75rem, 4.6666666667vw, 4rem));font-weight:var(--wcss-display-lg-weight, 300);letter-spacing:var(--wcss-display-lg-letter-spacing, 0);line-height:var(--wcss-display-lg-line-height, 1.3)}.display-md{font-family:var(--wcss-display-md-family, "AS Circular"),var(--wcss-display-md-family-fallback, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif);font-size:var(--wcss-display-md-font-size, clamp(2.5rem, 4vw, 3.5rem));font-weight:var(--wcss-display-md-weight, 300);letter-spacing:var(--wcss-display-md-letter-spacing, 0);line-height:var(--wcss-display-md-line-height, 1.3)}.display-sm{font-family:var(--wcss-display-sm-family, "AS Circular"),var(--wcss-display-sm-family-fallback, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif);font-size:var(--wcss-display-sm-font-size, clamp(2rem, 3.6666666667vw, 3rem));font-weight:var(--wcss-display-sm-weight, 300);letter-spacing:var(--wcss-display-sm-letter-spacing, 0);line-height:var(--wcss-display-sm-line-height, 1.3)}.display-xs{font-family:var(--wcss-display-xs-family, "AS Circular"),var(--wcss-display-xs-family-fallback, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif);font-size:var(--wcss-display-xs-font-size, clamp(1.75rem, 3vw, 2.375rem));font-weight:var(--wcss-display-xs-weight, 300);letter-spacing:var(--wcss-display-xs-letter-spacing, 0);line-height:var(--wcss-display-xs-line-height, 1.3)}.heading-xl{font-family:var(--wcss-heading-xl-family, "AS Circular"),var(--wcss-heading-xl-family-fallback, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif);font-size:var(--wcss-heading-xl-font-size, clamp(2rem, 3vw, 2.5rem));font-weight:var(--wcss-heading-xl-weight, 300);letter-spacing:var(--wcss-heading-xl-letter-spacing, 0);line-height:var(--wcss-heading-xl-line-height, 1.3)}.heading-lg{font-family:var(--wcss-heading-lg-family, "AS Circular"),var(--wcss-heading-lg-family-fallback, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif);font-size:var(--wcss-heading-lg-font-size, clamp(1.75rem, 2.6666666667vw, 2.25rem));font-weight:var(--wcss-heading-lg-weight, 300);letter-spacing:var(--wcss-heading-lg-letter-spacing, 0);line-height:var(--wcss-heading-lg-line-height, 1.3)}.heading-md{font-family:var(--wcss-heading-md-family, "AS Circular"),var(--wcss-heading-md-family-fallback, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif);font-size:var(--wcss-heading-md-font-size, clamp(1.625rem, 2.3333333333vw, 1.75rem));font-weight:var(--wcss-heading-md-weight, 300);letter-spacing:var(--wcss-heading-md-letter-spacing, 0);line-height:var(--wcss-heading-md-line-height, 1.3)}.heading-sm{font-family:var(--wcss-heading-sm-family, "AS Circular"),var(--wcss-heading-sm-family-fallback, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif);font-size:var(--wcss-heading-sm-font-size, clamp(1.375rem, 2vw, 1.5rem));font-weight:var(--wcss-heading-sm-weight, 300);letter-spacing:var(--wcss-heading-sm-letter-spacing, 0);line-height:var(--wcss-heading-sm-line-height, 1.3)}.heading-xs{font-family:var(--wcss-heading-xs-family, "AS Circular"),var(--wcss-heading-xs-family-fallback, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif);font-size:var(--wcss-heading-xs-font-size, clamp(1.25rem, 1.6666666667vw, 1.25rem));font-weight:var(--wcss-heading-xs-weight, 450);letter-spacing:var(--wcss-heading-xs-letter-spacing, 0);line-height:var(--wcss-heading-xs-line-height, 1.3)}.heading-2xs{font-family:var(--wcss-heading-2xs-family, "AS Circular"),var(--wcss-heading-2xs-family-fallback, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif);font-size:var(--wcss-heading-2xs-font-size, clamp(1.125rem, 1.5vw, 1.125rem));font-weight:var(--wcss-heading-2xs-weight, 450);letter-spacing:var(--wcss-heading-2xs-letter-spacing, 0);line-height:var(--wcss-heading-2xs-line-height, 1.3)}.accent-2xl{font-family:var(--wcss-accent-2xl-family, "Good OT"),var(--wcss-accent-2xl-family-fallback, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif);font-size:var(--wcss-accent-2xl-font-size, clamp(2rem, 3.1666666667vw, 2.375rem));font-weight:var(--wcss-accent-2xl-weight, 450);letter-spacing:var(--wcss-accent-2xl-letter-spacing, .05em);line-height:var(--wcss-accent-2xl-line-height, 1)}.accent-2xl,.accent-xl{text-transform:uppercase}.accent-xl{font-family:var(--wcss-accent-xl-family, "Good OT"),var(--wcss-accent-xl-family-fallback, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif);font-size:var(--wcss-accent-xl-font-size, clamp(1.625rem, 2.3333333333vw, 2rem));font-weight:var(--wcss-accent-xl-weight, 450);letter-spacing:var(--wcss-accent-xl-letter-spacing, .05em);line-height:var(--wcss-accent-xl-line-height, 1.3)}.accent-lg{font-family:var(--wcss-accent-lg-family, "Good OT"),var(--wcss-accent-lg-family-fallback, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif);font-size:var(--wcss-accent-lg-font-size, clamp(1.5rem, 2.1666666667vw, 1.75rem));font-weight:var(--wcss-accent-lg-weight, 450);letter-spacing:var(--wcss-accent-lg-letter-spacing, .05em);line-height:var(--wcss-accent-lg-line-height, 1.3)}.accent-lg,.accent-md{text-transform:uppercase}.accent-md{font-family:var(--wcss-accent-md-family, "Good OT"),var(--wcss-accent-md-family-fallback, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif);font-size:var(--wcss-accent-md-font-size, clamp(1.375rem, 1.8333333333vw, 1.5rem));font-weight:var(--wcss-accent-md-weight, 500);letter-spacing:var(--wcss-accent-md-letter-spacing, .05em);line-height:var(--wcss-accent-md-line-height, 1.3)}.accent-sm{font-family:var(--wcss-accent-sm-family, "Good OT"),var(--wcss-accent-sm-family-fallback, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif);font-size:var(--wcss-accent-sm-font-size, clamp(1.125rem, 1.5vw, 1.25rem));font-weight:var(--wcss-accent-sm-weight, 500);letter-spacing:var(--wcss-accent-sm-letter-spacing, .05em);line-height:var(--wcss-accent-sm-line-height, 1.3)}.accent-sm,.accent-xs{text-transform:uppercase}.accent-xs{font-family:var(--wcss-accent-xs-family, "Good OT"),var(--wcss-accent-xs-family-fallback, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif);font-size:var(--wcss-accent-xs-font-size, clamp(1rem, 1.3333333333vw, 1rem));font-weight:var(--wcss-accent-xs-weight, 500);letter-spacing:var(--wcss-accent-xs-letter-spacing, .1em);line-height:var(--wcss-accent-xs-line-height, 1.3)}.accent-2xs{font-family:var(--wcss-accent-2xs-family, "Good OT"),var(--wcss-accent-2xs-family-fallback, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif);font-size:var(--wcss-accent-2xs-font-size, clamp(.875rem, 1.1666666667vw, .875rem));font-weight:var(--wcss-accent-2xs-weight, 450);letter-spacing:var(--wcss-accent-2xs-letter-spacing, .1em);line-height:var(--wcss-accent-2xs-line-height, 1.3);text-transform:uppercase}:focus:not(:focus-visible){outline:3px solid transparent}:host,:host>span{position:relative}:host{width:2rem;height:2rem;display:inline-block;font-size:0}:host>span{position:absolute;display:inline-block;float:none;top:0;left:0;width:2rem;height:2rem;border-radius:100%;border-style:solid;border-width:0;box-sizing:border-box}:host([xs]),:host([xs])>span{width:1.2rem;height:1.2rem}:host([sm]),:host([sm])>span{width:3rem;height:3rem}:host([md]),:host([md])>span{width:5rem;height:5rem}:host([lg]),:host([lg])>span{width:8rem;height:8rem}:host{--margin: .375rem;--margin-xs: .2rem;--margin-sm: .5rem;--margin-md: .75rem;--margin-lg: 1rem}:host([pulse]),:host([pulse])>span{position:relative}:host([pulse]){width:calc(3rem + var(--margin) * 6);height:calc(1rem + var(--margin) * 2)}:host([pulse])>span{width:1rem;height:1rem;margin:var(--margin);animation:pulse 1.5s ease infinite}:host([pulse][xs]){width:calc(1.95rem + var(--margin-xs) * 6);height:calc(.65rem + var(--margin-xs) * 2)}:host([pulse][xs])>span{margin:var(--margin-xs);width:.65rem;height:.65rem}:host([pulse][sm]){width:calc(6rem + var(--margin-sm) * 6);height:calc(2rem + var(--margin-sm) * 2)}:host([pulse][sm])>span{margin:var(--margin-sm);width:2rem;height:2rem}:host([pulse][md]){width:calc(9rem + var(--margin-md) * 6);height:calc(3rem + var(--margin-md) * 2)}:host([pulse][md])>span{margin:var(--margin-md);width:3rem;height:3rem}:host([pulse][lg]){width:calc(15rem + var(--margin-lg) * 6);height:calc(5rem + var(--margin-lg) * 2)}:host([pulse][lg])>span{margin:var(--margin-lg);width:5rem;height:5rem}:host([pulse])>span:nth-child(1){animation-delay:-.4s}:host([pulse])>span:nth-child(2){animation-delay:-.2s}:host([pulse])>span:nth-child(3){animation-delay:0ms}@keyframes pulse{0%,to{opacity:.1;transform:scale(.9)}50%{opacity:1;transform:scale(1.1)}}:host([orbit]),:host([orbit])>span{opacity:1}:host([orbit])>span{border-width:5px}:host([orbit])>span:nth-child(2){animation:orbit 2s linear infinite}:host([orbit][sm])>span{border-width:8px}:host([orbit][md])>span{border-width:13px}:host([orbit][lg])>span{border-width:21px}@keyframes orbit{0%{transform:rotate(0)}to{transform:rotate(360deg)}}:host([ringworm])>svg{animation:rotate 2s linear infinite;height:100%;width:100%;stroke:currentcolor;stroke-width:8}:host([ringworm]) .path{stroke-dashoffset:0;animation:ringworm 1.5s ease-in-out infinite;stroke-linecap:round}@keyframes rotate{to{transform:rotate(360deg)}}@keyframes ringworm{0%{stroke-dasharray:1,200;stroke-dashoffset:0}50%{stroke-dasharray:89,200;stroke-dashoffset:-35px}to{stroke-dasharray:89,200;stroke-dashoffset:-124px}}:host([laser]){position:static;width:100%;display:block;height:0;overflow:hidden;font-size:unset}:host([laser])>span{position:fixed;width:100%;height:.25rem;border-radius:0;z-index:100}:host([laser])>span:nth-child(1){border-color:currentcolor;opacity:.25}:host([laser])>span:nth-child(2){border-color:currentcolor;animation:laser 2s linear infinite;opacity:1;width:50%}:host([laser][sm])>span:nth-child(2){width:20%}:host([laser][md])>span:nth-child(2){width:30%}:host([laser][lg])>span:nth-child(2){width:50%;animation-duration:1.5s}:host([laser][xl])>span:nth-child(2){width:80%;animation-duration:1.5s}@keyframes laser{0%{left:-100%}to{left:110%}}:host>.no-animation{display:none}@media (prefers-reduced-motion: reduce){:host{display:flex;align-items:center;justify-content:center}:host>span{opacity:1}:host>.loader{display:none}:host>svg{display:none}:host>.no-animation{display:block}}
|
|
@@ -9719,7 +9920,7 @@ let l$1 = class l{generateElementName(t,e){let o=t;return o+="-",o+=e.replace(/[
|
|
|
9719
9920
|
|
|
9720
9921
|
var buttonVersion$1 = '12.3.2';
|
|
9721
9922
|
|
|
9722
|
-
/* eslint-disable no-magic-numbers, no-undef-init, max-lines, lit/binding-positions, lit/no-invalid-html */
|
|
9923
|
+
/* eslint-disable no-magic-numbers, complexity, line-comment-position, no-undef-init, max-lines, line-comment-position, no-underscore-dangle, lit/binding-positions, lit/no-invalid-html, no-inline-comments */
|
|
9723
9924
|
|
|
9724
9925
|
|
|
9725
9926
|
// See https://git.io/JJ6SJ for "How to document your components using JSDoc"
|
|
@@ -9763,6 +9964,13 @@ class AuroCalendar extends RangeDatepicker {
|
|
|
9763
9964
|
*/
|
|
9764
9965
|
this.activeCellDate = null;
|
|
9765
9966
|
|
|
9967
|
+
/**
|
|
9968
|
+
* Whether the #calendarGrid wrapper currently has focus.
|
|
9969
|
+
* Used to determine whether the visualFocus ring should be shown.
|
|
9970
|
+
* @private
|
|
9971
|
+
*/
|
|
9972
|
+
this._gridHasFocus = false;
|
|
9973
|
+
|
|
9766
9974
|
/**
|
|
9767
9975
|
* @private
|
|
9768
9976
|
*/
|
|
@@ -9773,6 +9981,12 @@ class AuroCalendar extends RangeDatepicker {
|
|
|
9773
9981
|
*/
|
|
9774
9982
|
this.calendarRangeMonths = null;
|
|
9775
9983
|
|
|
9984
|
+
/**
|
|
9985
|
+
* Legacy array of disabled-date timestamps.
|
|
9986
|
+
* @private
|
|
9987
|
+
*/
|
|
9988
|
+
this.disabledDays = [];
|
|
9989
|
+
|
|
9776
9990
|
/**
|
|
9777
9991
|
* @private
|
|
9778
9992
|
*/
|
|
@@ -9796,6 +10010,12 @@ class AuroCalendar extends RangeDatepicker {
|
|
|
9796
10010
|
this.buttonTag = versioning.generateTag('auro-formkit-datepicker-button', buttonVersion$1, T$1);
|
|
9797
10011
|
|
|
9798
10012
|
this.dropdown = undefined;
|
|
10013
|
+
|
|
10014
|
+
/**
|
|
10015
|
+
* Unique instance ID for the live region element.
|
|
10016
|
+
* @private
|
|
10017
|
+
*/
|
|
10018
|
+
this._calendarInstanceId = Date.now().toString(36);
|
|
9799
10019
|
}
|
|
9800
10020
|
|
|
9801
10021
|
static get styles() {
|
|
@@ -9808,6 +10028,7 @@ class AuroCalendar extends RangeDatepicker {
|
|
|
9808
10028
|
|
|
9809
10029
|
static get properties() {
|
|
9810
10030
|
return {
|
|
10031
|
+
|
|
9811
10032
|
/**
|
|
9812
10033
|
* The last month that may be displayed in the calendar.
|
|
9813
10034
|
*/
|
|
@@ -9924,22 +10145,36 @@ class AuroCalendar extends RangeDatepicker {
|
|
|
9924
10145
|
/**
|
|
9925
10146
|
* Updates the month and year when the user navigates to the previous calendar month.
|
|
9926
10147
|
* @private
|
|
10148
|
+
* @param {Object} [options] - Optional settings.
|
|
10149
|
+
* @param {boolean} [options.skipActiveUpdate=false] - When true, skip the active cell
|
|
10150
|
+
* recomputation. Used by arrow key handlers that manage the active cell themselves.
|
|
9927
10151
|
* @returns {void}
|
|
9928
10152
|
*/
|
|
9929
|
-
handlePrevMonth() {
|
|
10153
|
+
handlePrevMonth(options) {
|
|
10154
|
+
const opts = options instanceof Event ? {} : options || {};
|
|
10155
|
+
this.clearRangePreview();
|
|
9930
10156
|
this.utilCal.handleMonthChange(this, 'prev');
|
|
9931
|
-
|
|
10157
|
+
if (!opts.skipActiveUpdate) {
|
|
10158
|
+
this.updateActiveCellForVisibleMonth();
|
|
10159
|
+
}
|
|
9932
10160
|
this.announceMonthChange();
|
|
9933
10161
|
}
|
|
9934
10162
|
|
|
9935
10163
|
/**
|
|
9936
10164
|
* Updates the month and year when the user navigates to the next calendar month.
|
|
9937
10165
|
* @private
|
|
10166
|
+
* @param {Object} [options] - Optional settings.
|
|
10167
|
+
* @param {boolean} [options.skipActiveUpdate=false] - When true, skip the active cell
|
|
10168
|
+
* recomputation. Used by arrow key handlers that manage the active cell themselves.
|
|
9938
10169
|
* @returns {void}
|
|
9939
10170
|
*/
|
|
9940
|
-
handleNextMonth() {
|
|
10171
|
+
handleNextMonth(options) {
|
|
10172
|
+
const opts = options instanceof Event ? {} : options || {};
|
|
10173
|
+
this.clearRangePreview();
|
|
9941
10174
|
this.utilCal.handleMonthChange(this, 'next');
|
|
9942
|
-
|
|
10175
|
+
if (!opts.skipActiveUpdate) {
|
|
10176
|
+
this.updateActiveCellForVisibleMonth();
|
|
10177
|
+
}
|
|
9943
10178
|
this.announceMonthChange();
|
|
9944
10179
|
}
|
|
9945
10180
|
|
|
@@ -9949,27 +10184,39 @@ class AuroCalendar extends RangeDatepicker {
|
|
|
9949
10184
|
* @returns {void}
|
|
9950
10185
|
*/
|
|
9951
10186
|
announceMonthChange() {
|
|
10187
|
+
// Cancel any pending debounced cell announcement so it does not
|
|
10188
|
+
// overwrite this month navigation announcement.
|
|
10189
|
+
if (this._focusAnnounceTimer) {
|
|
10190
|
+
clearTimeout(this._focusAnnounceTimer);
|
|
10191
|
+
this._focusAnnounceTimer = null;
|
|
10192
|
+
}
|
|
10193
|
+
|
|
9952
10194
|
const date = new Date(this.centralDate);
|
|
9953
10195
|
const localeCode = this.locale?.code || undefined;
|
|
9954
|
-
const formatter = new Intl.DateTimeFormat(localeCode, { month: 'long',
|
|
10196
|
+
const formatter = new Intl.DateTimeFormat(localeCode, { month: 'long',
|
|
10197
|
+
year: 'numeric' });
|
|
9955
10198
|
this.announceSelection(formatter.format(date));
|
|
9956
10199
|
}
|
|
9957
10200
|
|
|
9958
10201
|
/**
|
|
9959
|
-
*
|
|
9960
|
-
*
|
|
9961
|
-
*
|
|
10202
|
+
* Updates the active cell after month navigation (prev/next buttons).
|
|
10203
|
+
* Always moves the active cell to the first enabled date in the newly
|
|
10204
|
+
* visible months so that tabbing back to the grid lands on an enabled cell.
|
|
9962
10205
|
* @private
|
|
9963
10206
|
* @returns {void}
|
|
9964
10207
|
*/
|
|
9965
10208
|
updateActiveCellForVisibleMonth() {
|
|
9966
|
-
//
|
|
9967
|
-
//
|
|
9968
|
-
|
|
9969
|
-
|
|
9970
|
-
|
|
9971
|
-
|
|
9972
|
-
|
|
10209
|
+
// Use double-rAF to ensure child month/cell components have fully
|
|
10210
|
+
// rendered and cached their button references before we set tabindex.
|
|
10211
|
+
requestAnimationFrame(() => {
|
|
10212
|
+
requestAnimationFrame(() => {
|
|
10213
|
+
const newDate = this.computeActiveDate({ skipDateFrom: true });
|
|
10214
|
+
|
|
10215
|
+
if (newDate !== null && newDate !== undefined) {
|
|
10216
|
+
this.activeCellDate = newDate;
|
|
10217
|
+
this.setActiveCell(this.activeCellDate);
|
|
10218
|
+
}
|
|
10219
|
+
});
|
|
9973
10220
|
});
|
|
9974
10221
|
}
|
|
9975
10222
|
|
|
@@ -10066,7 +10313,9 @@ class AuroCalendar extends RangeDatepicker {
|
|
|
10066
10313
|
*/
|
|
10067
10314
|
focusCloseButton() {
|
|
10068
10315
|
const bibtemplate = this.shadowRoot.querySelector(this.bibtemplateTag._$litStatic$);
|
|
10069
|
-
if (bibtemplate)
|
|
10316
|
+
if (bibtemplate) {
|
|
10317
|
+
bibtemplate.focusCloseButton();
|
|
10318
|
+
}
|
|
10070
10319
|
}
|
|
10071
10320
|
|
|
10072
10321
|
/**
|
|
@@ -10095,7 +10344,7 @@ class AuroCalendar extends RangeDatepicker {
|
|
|
10095
10344
|
getAllFocusableCells() {
|
|
10096
10345
|
const months = this.getMonthComponents();
|
|
10097
10346
|
let cells = [];
|
|
10098
|
-
months.forEach(month => {
|
|
10347
|
+
months.forEach((month) => {
|
|
10099
10348
|
cells = cells.concat(month.getFocusableCells());
|
|
10100
10349
|
});
|
|
10101
10350
|
return cells;
|
|
@@ -10103,39 +10352,89 @@ class AuroCalendar extends RangeDatepicker {
|
|
|
10103
10352
|
|
|
10104
10353
|
/**
|
|
10105
10354
|
* Sets the active cell across all months. Only one cell has tabindex="0" at a time.
|
|
10355
|
+
* Uses imperative DOM manipulation — no Lit re-render triggered.
|
|
10356
|
+
* Also updates ariaActiveDescendantElement on the grid wrapper so
|
|
10357
|
+
* screen readers announce the active cell without moving DOM focus.
|
|
10106
10358
|
* @param {Number} date - Unix timestamp of the cell to activate.
|
|
10107
10359
|
* @returns {void}
|
|
10108
10360
|
*/
|
|
10109
10361
|
setActiveCell(date) {
|
|
10110
10362
|
const allCells = this.getAllFocusableCells();
|
|
10111
10363
|
|
|
10112
|
-
|
|
10113
|
-
|
|
10364
|
+
let newActiveCell = null;
|
|
10365
|
+
allCells.forEach((cell) => {
|
|
10366
|
+
if (cell.day && cell.day.date === date) {
|
|
10367
|
+
cell.setActive();
|
|
10368
|
+
newActiveCell = cell;
|
|
10369
|
+
} else if (cell.active) {
|
|
10370
|
+
cell.clearActive();
|
|
10371
|
+
}
|
|
10114
10372
|
});
|
|
10115
10373
|
|
|
10116
10374
|
this.activeCellDate = date;
|
|
10375
|
+
|
|
10376
|
+
// Apply activeCell ring only when the grid currently has focus.
|
|
10377
|
+
if (newActiveCell && this._gridHasFocus) {
|
|
10378
|
+
const btn = newActiveCell._cachedButton || newActiveCell.shadowRoot.querySelector('button.day');
|
|
10379
|
+
if (btn) {
|
|
10380
|
+
btn.classList.add('activeCell');
|
|
10381
|
+
}
|
|
10382
|
+
}
|
|
10117
10383
|
}
|
|
10118
10384
|
|
|
10119
10385
|
/**
|
|
10120
|
-
* Focuses the
|
|
10121
|
-
*
|
|
10122
|
-
*
|
|
10386
|
+
* Focuses the calendar grid wrapper and sets the active cell.
|
|
10387
|
+
* DOM focus stays on the grid wrapper; the aria-live region
|
|
10388
|
+
* tells the screen reader which cell is "active".
|
|
10123
10389
|
* @returns {void}
|
|
10124
10390
|
*/
|
|
10125
10391
|
focusActiveCell() {
|
|
10126
|
-
if (this.activeCellDate
|
|
10392
|
+
if (this.activeCellDate !== null && this.activeCellDate !== undefined) {
|
|
10127
10393
|
this.setActiveCell(this.activeCellDate);
|
|
10128
10394
|
}
|
|
10129
10395
|
|
|
10130
|
-
const
|
|
10131
|
-
|
|
10396
|
+
const gridWrapper = this.shadowRoot.querySelector('#calendarGrid');
|
|
10397
|
+
if (gridWrapper) {
|
|
10398
|
+
gridWrapper.focus({ preventScroll: true,
|
|
10399
|
+
focusVisible: true });
|
|
10400
|
+
}
|
|
10401
|
+
}
|
|
10402
|
+
|
|
10403
|
+
/**
|
|
10404
|
+
* Shows the activeCell ring when the grid gains focus.
|
|
10405
|
+
* @private
|
|
10406
|
+
* @returns {void}
|
|
10407
|
+
*/
|
|
10408
|
+
handleGridFocusIn() {
|
|
10409
|
+
this._gridHasFocus = true;
|
|
10410
|
+
const activeCell = this.getAllFocusableCells().find((cell) => cell.active);
|
|
10132
10411
|
if (activeCell) {
|
|
10133
|
-
activeCell.
|
|
10134
|
-
|
|
10135
|
-
|
|
10412
|
+
const btn = activeCell._cachedButton || activeCell.shadowRoot.querySelector('button.day');
|
|
10413
|
+
if (btn) {
|
|
10414
|
+
btn.classList.add('activeCell');
|
|
10415
|
+
}
|
|
10136
10416
|
}
|
|
10137
10417
|
}
|
|
10138
10418
|
|
|
10419
|
+
/**
|
|
10420
|
+
* Hides the activeCell ring when the grid loses focus.
|
|
10421
|
+
* @private
|
|
10422
|
+
* @returns {void}
|
|
10423
|
+
*/
|
|
10424
|
+
handleGridFocusOut() {
|
|
10425
|
+
this._gridHasFocus = false;
|
|
10426
|
+
// Remove activeCell from ALL cells to prevent stale rings.
|
|
10427
|
+
const allCells = this.getAllFocusableCells();
|
|
10428
|
+
for (const cell of allCells) {
|
|
10429
|
+
const btn = cell._cachedButton || cell.shadowRoot.querySelector('button.day');
|
|
10430
|
+
if (btn) {
|
|
10431
|
+
btn.classList.remove('activeCell');
|
|
10432
|
+
}
|
|
10433
|
+
}
|
|
10434
|
+
// Clear range hover preview so no highlight lingers after focus leaves the grid.
|
|
10435
|
+
this.clearRangePreview();
|
|
10436
|
+
}
|
|
10437
|
+
|
|
10139
10438
|
/**
|
|
10140
10439
|
* Computes the initial active date from data properties alone — no DOM required.
|
|
10141
10440
|
* Priority:
|
|
@@ -10147,7 +10446,7 @@ class AuroCalendar extends RangeDatepicker {
|
|
|
10147
10446
|
* 5b. First enabled date scanning forward from finite min (unbounded max)
|
|
10148
10447
|
* 5c. First enabled date scanning backward from finite max (unbounded min)
|
|
10149
10448
|
* 6. First in-range date (even if blackout) so focus can land somewhere
|
|
10150
|
-
* 7.
|
|
10449
|
+
* 7. Undefined — no valid target.
|
|
10151
10450
|
*
|
|
10152
10451
|
* @private
|
|
10153
10452
|
* @param {Object} [options] - Optional settings.
|
|
@@ -10162,12 +10461,15 @@ class AuroCalendar extends RangeDatepicker {
|
|
|
10162
10461
|
/**
|
|
10163
10462
|
* Adds days to a timestamp using Date arithmetic to handle DST correctly.
|
|
10164
10463
|
* Returns a local-midnight-aligned timestamp in seconds.
|
|
10464
|
+
* @param {Number} ts - Unix timestamp in seconds.
|
|
10465
|
+
* @param {Number} days - Number of days to add.
|
|
10466
|
+
* @returns {Number} The adjusted timestamp in seconds.
|
|
10165
10467
|
*/
|
|
10166
10468
|
const addDays = (ts, days) => {
|
|
10167
|
-
const
|
|
10168
|
-
|
|
10169
|
-
|
|
10170
|
-
return Math.floor(
|
|
10469
|
+
const date = new Date(ts * 1000);
|
|
10470
|
+
date.setDate(date.getDate() + days);
|
|
10471
|
+
date.setHours(0, 0, 0, 0);
|
|
10472
|
+
return Math.floor(date.getTime() / 1000);
|
|
10171
10473
|
};
|
|
10172
10474
|
|
|
10173
10475
|
const rawMin = Number(this.min);
|
|
@@ -10178,9 +10480,7 @@ class AuroCalendar extends RangeDatepicker {
|
|
|
10178
10480
|
const maxTs = Number.isFinite(rawMax) ? rawMax : Infinity;
|
|
10179
10481
|
|
|
10180
10482
|
// Build a Set of blackout timestamps for O(1) lookup.
|
|
10181
|
-
const blackoutSet = new Set(
|
|
10182
|
-
(this.disabledDays || []).map(d => parseInt(d, 10))
|
|
10183
|
-
);
|
|
10483
|
+
const blackoutSet = new Set(this.disabledDays.map((day) => parseInt(day, 10)));
|
|
10184
10484
|
|
|
10185
10485
|
// Also include ISO-format blackoutDates from the datepicker if available.
|
|
10186
10486
|
// Parse YYYY-MM-DD as local date to avoid UTC shift issues.
|
|
@@ -10189,19 +10489,25 @@ class AuroCalendar extends RangeDatepicker {
|
|
|
10189
10489
|
for (const isoStr of isoBlackouts) {
|
|
10190
10490
|
const parts = isoStr.split('-');
|
|
10191
10491
|
const ts = Math.floor(new Date(parseInt(parts[0], 10), parseInt(parts[1], 10) - 1, parseInt(parts[2], 10)).getTime() / 1000);
|
|
10192
|
-
if (Number.isFinite(ts))
|
|
10492
|
+
if (Number.isFinite(ts)) {
|
|
10493
|
+
blackoutSet.add(ts);
|
|
10494
|
+
}
|
|
10193
10495
|
}
|
|
10194
10496
|
}
|
|
10195
10497
|
|
|
10196
10498
|
/**
|
|
10197
10499
|
* A date (unix timestamp in seconds, midnight-aligned) is "enabled" when
|
|
10198
10500
|
* it is within [min, max] AND not a blackout day.
|
|
10501
|
+
* @param {Number} ts - Unix timestamp in seconds.
|
|
10502
|
+
* @returns {boolean} True if the date is enabled.
|
|
10199
10503
|
*/
|
|
10200
10504
|
const isEnabled = (ts) => ts >= minTs && ts <= maxTs && !blackoutSet.has(ts);
|
|
10201
10505
|
|
|
10202
10506
|
/**
|
|
10203
10507
|
* A date is "in range" (focusable in the grid) when it is within [min, max].
|
|
10204
10508
|
* Blackout dates are focusable but not selectable.
|
|
10509
|
+
* @param {Number} ts - Unix timestamp in seconds.
|
|
10510
|
+
* @returns {boolean} True if the date is in range.
|
|
10205
10511
|
*/
|
|
10206
10512
|
const isInRange = (ts) => ts >= minTs && ts <= maxTs;
|
|
10207
10513
|
|
|
@@ -10210,7 +10516,9 @@ class AuroCalendar extends RangeDatepicker {
|
|
|
10210
10516
|
// the newly visible month rather than the (possibly off-screen) selection.
|
|
10211
10517
|
if (!options.skipDateFrom && this.dateFrom) {
|
|
10212
10518
|
const parsedFrom = parseInt(this.dateFrom, 10);
|
|
10213
|
-
if (Number.isFinite(parsedFrom) && isInRange(parsedFrom))
|
|
10519
|
+
if (Number.isFinite(parsedFrom) && isInRange(parsedFrom)) {
|
|
10520
|
+
return parsedFrom;
|
|
10521
|
+
}
|
|
10214
10522
|
}
|
|
10215
10523
|
|
|
10216
10524
|
// 2. Today's date (midnight-aligned) if enabled.
|
|
@@ -10237,32 +10545,35 @@ class AuroCalendar extends RangeDatepicker {
|
|
|
10237
10545
|
const visibleEnd = new Date(centralYear, centralMonth + 1, 0); // last day of month
|
|
10238
10546
|
visibleEnd.setHours(0, 0, 0, 0);
|
|
10239
10547
|
const startTs = Math.floor(visibleStart.getTime() / 1000);
|
|
10240
|
-
const endTs = Math.floor(visibleEnd.getTime() / 1000);
|
|
10241
10548
|
const daysInMonth = visibleEnd.getDate();
|
|
10242
10549
|
|
|
10243
|
-
for (let idx = 0; idx < daysInMonth; idx
|
|
10550
|
+
for (let idx = 0; idx < daysInMonth; idx += 1) {
|
|
10244
10551
|
const ts = addDays(startTs, idx);
|
|
10245
|
-
if (ts
|
|
10246
|
-
|
|
10552
|
+
if (isEnabled(ts)) {
|
|
10553
|
+
return ts;
|
|
10554
|
+
}
|
|
10247
10555
|
}
|
|
10248
10556
|
|
|
10249
10557
|
// No enabled date in the visible month — fall back to first in-range
|
|
10250
10558
|
// date in the month so focus still lands on a focusable cell.
|
|
10251
|
-
for (let idx = 0; idx < daysInMonth; idx
|
|
10559
|
+
for (let idx = 0; idx < daysInMonth; idx += 1) {
|
|
10252
10560
|
const ts = addDays(startTs, idx);
|
|
10253
|
-
if (ts
|
|
10254
|
-
|
|
10561
|
+
if (isInRange(ts)) {
|
|
10562
|
+
return ts;
|
|
10563
|
+
}
|
|
10255
10564
|
}
|
|
10256
10565
|
}
|
|
10257
10566
|
}
|
|
10258
10567
|
|
|
10259
|
-
if (isEnabled(now))
|
|
10568
|
+
if (isEnabled(now)) {
|
|
10569
|
+
return now;
|
|
10570
|
+
}
|
|
10260
10571
|
|
|
10261
10572
|
// When a centralDate is configured (or inferred), constrain the scan to the
|
|
10262
10573
|
// rendered month(s) first so a single-month calendar does not pick a date
|
|
10263
10574
|
// that has no DOM cell. Determine the visible range based on centralDate and
|
|
10264
10575
|
// the number of rendered months.
|
|
10265
|
-
const renderedMonths = this.numCalendars
|
|
10576
|
+
const renderedMonths = Math.max(this.numCalendars, 1);
|
|
10266
10577
|
const visibleAnchor = centralDateValue && !isNaN(centralDateValue.getTime())
|
|
10267
10578
|
? centralDateValue
|
|
10268
10579
|
: new Date(now * 1000);
|
|
@@ -10275,40 +10586,52 @@ class AuroCalendar extends RangeDatepicker {
|
|
|
10275
10586
|
const visDays = Math.round((visEndTs - visStartTs) / 86400) + 1;
|
|
10276
10587
|
|
|
10277
10588
|
// Scan visible months for an enabled date.
|
|
10278
|
-
for (let idx = 0; idx < visDays; idx
|
|
10589
|
+
for (let idx = 0; idx < visDays; idx += 1) {
|
|
10279
10590
|
const ts = addDays(visStartTs, idx);
|
|
10280
|
-
if (ts
|
|
10281
|
-
|
|
10591
|
+
if (isEnabled(ts)) {
|
|
10592
|
+
return ts;
|
|
10593
|
+
}
|
|
10282
10594
|
}
|
|
10283
10595
|
|
|
10284
10596
|
// No enabled date in visible months — try an in-range (focusable) date so
|
|
10285
10597
|
// keyboard focus still has a tabindex="0" target.
|
|
10286
|
-
for (let idx = 0; idx < visDays; idx
|
|
10598
|
+
for (let idx = 0; idx < visDays; idx += 1) {
|
|
10287
10599
|
const ts = addDays(visStartTs, idx);
|
|
10288
|
-
if (ts
|
|
10289
|
-
|
|
10600
|
+
if (isInRange(ts)) {
|
|
10601
|
+
return ts;
|
|
10602
|
+
}
|
|
10290
10603
|
}
|
|
10291
10604
|
|
|
10292
10605
|
// 3. First future enabled date (scan forward from tomorrow, capped by max and MAX_SCAN_DAYS).
|
|
10293
|
-
for (let idx = 1; idx <= MAX_SCAN_DAYS; idx
|
|
10606
|
+
for (let idx = 1; idx <= MAX_SCAN_DAYS; idx += 1) {
|
|
10294
10607
|
const ts = addDays(now, idx);
|
|
10295
|
-
if (Number.isFinite(maxTs) && ts > maxTs)
|
|
10296
|
-
|
|
10608
|
+
if (Number.isFinite(maxTs) && ts > maxTs) {
|
|
10609
|
+
break;
|
|
10610
|
+
}
|
|
10611
|
+
if (isEnabled(ts)) {
|
|
10612
|
+
return ts;
|
|
10613
|
+
}
|
|
10297
10614
|
}
|
|
10298
10615
|
|
|
10299
10616
|
// 4. First previous enabled date (scan backward from yesterday, capped by min and MAX_SCAN_DAYS).
|
|
10300
|
-
for (let idx = 1; idx <= MAX_SCAN_DAYS; idx
|
|
10617
|
+
for (let idx = 1; idx <= MAX_SCAN_DAYS; idx += 1) {
|
|
10301
10618
|
const ts = addDays(now, -idx);
|
|
10302
|
-
if (Number.isFinite(minTs) && ts < minTs)
|
|
10303
|
-
|
|
10619
|
+
if (Number.isFinite(minTs) && ts < minTs) {
|
|
10620
|
+
break;
|
|
10621
|
+
}
|
|
10622
|
+
if (isEnabled(ts)) {
|
|
10623
|
+
return ts;
|
|
10624
|
+
}
|
|
10304
10625
|
}
|
|
10305
10626
|
|
|
10306
10627
|
// 5. If scans missed (e.g. min/max range is far from today), fall back to
|
|
10307
10628
|
// the first enabled date in the [min, max] range.
|
|
10308
10629
|
if (Number.isFinite(minTs) && Number.isFinite(maxTs)) {
|
|
10309
10630
|
let ts = minTs;
|
|
10310
|
-
for (let idx = 0; ts <= maxTs; idx
|
|
10311
|
-
if (isEnabled(ts))
|
|
10631
|
+
for (let idx = 0; ts <= maxTs; idx += 1) {
|
|
10632
|
+
if (isEnabled(ts)) {
|
|
10633
|
+
return ts;
|
|
10634
|
+
}
|
|
10312
10635
|
ts = addDays(minTs, idx + 1);
|
|
10313
10636
|
}
|
|
10314
10637
|
}
|
|
@@ -10316,29 +10639,191 @@ class AuroCalendar extends RangeDatepicker {
|
|
|
10316
10639
|
// 5b. Finite min with unbounded max (e.g. minDate far in the future):
|
|
10317
10640
|
// scan forward from min for up to MAX_SCAN_DAYS.
|
|
10318
10641
|
if (Number.isFinite(minTs) && !Number.isFinite(maxTs)) {
|
|
10319
|
-
for (let idx = 0; idx <= MAX_SCAN_DAYS; idx
|
|
10642
|
+
for (let idx = 0; idx <= MAX_SCAN_DAYS; idx += 1) {
|
|
10320
10643
|
const ts = addDays(minTs, idx);
|
|
10321
|
-
if (isEnabled(ts))
|
|
10644
|
+
if (isEnabled(ts)) {
|
|
10645
|
+
return ts;
|
|
10646
|
+
}
|
|
10322
10647
|
}
|
|
10323
10648
|
}
|
|
10324
10649
|
|
|
10325
10650
|
// 5c. Unbounded min with a finite max far in the past (e.g. birth-date picker):
|
|
10326
10651
|
// scan backward from max for up to MAX_SCAN_DAYS.
|
|
10327
10652
|
if (!Number.isFinite(minTs) && Number.isFinite(maxTs)) {
|
|
10328
|
-
for (let idx = 0; idx <= MAX_SCAN_DAYS; idx
|
|
10653
|
+
for (let idx = 0; idx <= MAX_SCAN_DAYS; idx += 1) {
|
|
10329
10654
|
const ts = addDays(maxTs, -idx);
|
|
10330
|
-
if (isEnabled(ts))
|
|
10655
|
+
if (isEnabled(ts)) {
|
|
10656
|
+
return ts;
|
|
10657
|
+
}
|
|
10331
10658
|
}
|
|
10332
10659
|
}
|
|
10333
10660
|
|
|
10334
10661
|
// 6. All dates are blackout — fall back to the first in-range date so focus
|
|
10335
10662
|
// still lands on a focusable (but not selectable) cell.
|
|
10336
|
-
if (Number.isFinite(minTs) && isInRange(minTs))
|
|
10337
|
-
|
|
10663
|
+
if (Number.isFinite(minTs) && isInRange(minTs)) {
|
|
10664
|
+
return minTs;
|
|
10665
|
+
}
|
|
10666
|
+
if (isInRange(now)) {
|
|
10667
|
+
return now;
|
|
10668
|
+
}
|
|
10338
10669
|
|
|
10339
10670
|
return undefined;
|
|
10340
10671
|
}
|
|
10341
10672
|
|
|
10673
|
+
/**
|
|
10674
|
+
* Checks if a target date (unix seconds) is within the configured [min, max] range.
|
|
10675
|
+
* Returns false if the date falls outside the range, preventing navigation
|
|
10676
|
+
* to months where all dates are disabled.
|
|
10677
|
+
* @private
|
|
10678
|
+
* @param {Number} targetTs - Unix timestamp in seconds.
|
|
10679
|
+
* @returns {Boolean} True if the date is within range.
|
|
10680
|
+
*/
|
|
10681
|
+
isDateInRange(targetTs) {
|
|
10682
|
+
const rawMin = Number(this.min);
|
|
10683
|
+
const rawMax = Number(this.max);
|
|
10684
|
+
if (Number.isFinite(rawMin) && targetTs < rawMin) {
|
|
10685
|
+
return false;
|
|
10686
|
+
}
|
|
10687
|
+
if (Number.isFinite(rawMax) && targetTs > rawMax) {
|
|
10688
|
+
return false;
|
|
10689
|
+
}
|
|
10690
|
+
return true;
|
|
10691
|
+
}
|
|
10692
|
+
|
|
10693
|
+
/**
|
|
10694
|
+
* Handles arrow key navigation on the calendar grid wrapper.
|
|
10695
|
+
* Focus stays on the grid wrapper; only ariaActiveDescendantElement
|
|
10696
|
+
* and the visual active-cell indicator change.
|
|
10697
|
+
* @private
|
|
10698
|
+
* @param {KeyboardEvent} event - The keyboard event.
|
|
10699
|
+
* @returns {void}
|
|
10700
|
+
*/
|
|
10701
|
+
handleGridKeyDown(event) {
|
|
10702
|
+
const { key } = event;
|
|
10703
|
+
const actionKeys = [
|
|
10704
|
+
'ArrowRight',
|
|
10705
|
+
'ArrowLeft',
|
|
10706
|
+
'ArrowDown',
|
|
10707
|
+
'ArrowUp',
|
|
10708
|
+
'Enter',
|
|
10709
|
+
' '
|
|
10710
|
+
];
|
|
10711
|
+
|
|
10712
|
+
if (!actionKeys.includes(key)) {
|
|
10713
|
+
return;
|
|
10714
|
+
}
|
|
10715
|
+
|
|
10716
|
+
event.preventDefault();
|
|
10717
|
+
|
|
10718
|
+
const allCells = this.getAllFocusableCells();
|
|
10719
|
+
if (allCells.length === 0) {
|
|
10720
|
+
return;
|
|
10721
|
+
}
|
|
10722
|
+
|
|
10723
|
+
const activeCell = allCells.find((cell) => cell.active);
|
|
10724
|
+
if (!activeCell) {
|
|
10725
|
+
return;
|
|
10726
|
+
}
|
|
10727
|
+
|
|
10728
|
+
// Handle Enter/Space to select the active cell
|
|
10729
|
+
if (key === 'Enter' || key === ' ') {
|
|
10730
|
+
activeCell.handleTap();
|
|
10731
|
+
return;
|
|
10732
|
+
}
|
|
10733
|
+
|
|
10734
|
+
const activeIndex = allCells.indexOf(activeCell);
|
|
10735
|
+
|
|
10736
|
+
if (key === 'ArrowRight' || key === 'ArrowLeft') {
|
|
10737
|
+
const direction = key === 'ArrowRight' ? 1 : -1;
|
|
10738
|
+
const targetIndex = activeIndex + direction;
|
|
10739
|
+
|
|
10740
|
+
if (targetIndex >= 0 && targetIndex < allCells.length) {
|
|
10741
|
+
// Target cell exists in rendered months
|
|
10742
|
+
this.setActiveCell(allCells[targetIndex].day.date);
|
|
10743
|
+
this.scrollToActiveCell();
|
|
10744
|
+
// Dispatch focus event for the cell so live region + range preview update
|
|
10745
|
+
this.handleCellFocused({ detail: { date: allCells[targetIndex].day.date } });
|
|
10746
|
+
} else {
|
|
10747
|
+
// At boundary — need to navigate to next/prev month
|
|
10748
|
+
const navDir = direction === 1 ? 'next' : 'prev';
|
|
10749
|
+
const targetDate = new Date(activeCell.day.date * 1000);
|
|
10750
|
+
targetDate.setDate(targetDate.getDate() + direction);
|
|
10751
|
+
targetDate.setHours(0, 0, 0, 0);
|
|
10752
|
+
const targetTs = Math.floor(targetDate.getTime() / 1000);
|
|
10753
|
+
|
|
10754
|
+
if (this.isDateInRange(targetTs) && ((navDir === 'next' && this.showNextMonthBtn) || (navDir === 'prev' && this.showPrevMonthBtn))) { // eslint-disable-line no-extra-parens
|
|
10755
|
+
|
|
10756
|
+
if (navDir === 'next') {
|
|
10757
|
+
this.handleNextMonth({ skipActiveUpdate: true });
|
|
10758
|
+
} else {
|
|
10759
|
+
this.handlePrevMonth({ skipActiveUpdate: true });
|
|
10760
|
+
}
|
|
10761
|
+
requestAnimationFrame(() => {
|
|
10762
|
+
requestAnimationFrame(() => {
|
|
10763
|
+
const cells = this.getAllFocusableCells();
|
|
10764
|
+
const target = cells.find((cell) => cell.day && cell.day.date === targetTs);
|
|
10765
|
+
if (target) {
|
|
10766
|
+
this.setActiveCell(target.day.date);
|
|
10767
|
+
this.handleCellFocused({ detail: { date: target.day.date } });
|
|
10768
|
+
} else if (cells.length > 0) {
|
|
10769
|
+
const fallback = navDir === 'next' ? cells[cells.length - 1] : cells[0];
|
|
10770
|
+
this.setActiveCell(fallback.day.date);
|
|
10771
|
+
this.handleCellFocused({ detail: { date: fallback.day.date } });
|
|
10772
|
+
}
|
|
10773
|
+
// Re-focus grid wrapper after month change re-render
|
|
10774
|
+
this.focusActiveCell();
|
|
10775
|
+
});
|
|
10776
|
+
});
|
|
10777
|
+
}
|
|
10778
|
+
}
|
|
10779
|
+
} else if (key === 'ArrowDown' || key === 'ArrowUp') {
|
|
10780
|
+
const increment = key === 'ArrowDown' ? 7 : -7;
|
|
10781
|
+
const currentDate = new Date(activeCell.day.date * 1000);
|
|
10782
|
+
currentDate.setDate(currentDate.getDate() + increment);
|
|
10783
|
+
currentDate.setHours(0, 0, 0, 0);
|
|
10784
|
+
const targetDate = Math.floor(currentDate.getTime() / 1000);
|
|
10785
|
+
|
|
10786
|
+
const targetCell = allCells.find((cell) => cell.day && cell.day.date === targetDate);
|
|
10787
|
+
|
|
10788
|
+
if (targetCell) {
|
|
10789
|
+
this.setActiveCell(targetCell.day.date);
|
|
10790
|
+
this.scrollToActiveCell();
|
|
10791
|
+
this.handleCellFocused({ detail: { date: targetCell.day.date } });
|
|
10792
|
+
} else if (this.isDateInRange(targetDate)) {
|
|
10793
|
+
// Target might be in an unrendered month
|
|
10794
|
+
const navDirection = key === 'ArrowDown' ? 'next' : 'prev';
|
|
10795
|
+
if ((navDirection === 'next' && this.showNextMonthBtn) || (navDirection === 'prev' && this.showPrevMonthBtn)) { // eslint-disable-line no-extra-parens
|
|
10796
|
+
if (navDirection === 'next') {
|
|
10797
|
+
this.handleNextMonth({ skipActiveUpdate: true });
|
|
10798
|
+
} else {
|
|
10799
|
+
this.handlePrevMonth({ skipActiveUpdate: true });
|
|
10800
|
+
}
|
|
10801
|
+
requestAnimationFrame(() => {
|
|
10802
|
+
requestAnimationFrame(() => {
|
|
10803
|
+
const cells = this.getAllFocusableCells();
|
|
10804
|
+
const target = cells.find((cell) => cell.day && cell.day.date === targetDate);
|
|
10805
|
+
if (target) {
|
|
10806
|
+
this.setActiveCell(target.day.date);
|
|
10807
|
+
this.handleCellFocused({ detail: { date: target.day.date } });
|
|
10808
|
+
} else if (cells.length > 0) {
|
|
10809
|
+
let nearest = null;
|
|
10810
|
+
|
|
10811
|
+
if (navDirection === 'next') {
|
|
10812
|
+
[nearest] = cells;
|
|
10813
|
+
} else {
|
|
10814
|
+
nearest = cells[cells.length - 1];
|
|
10815
|
+
}
|
|
10816
|
+
this.setActiveCell(nearest.day.date);
|
|
10817
|
+
this.handleCellFocused({ detail: { date: nearest.day.date } });
|
|
10818
|
+
}
|
|
10819
|
+
this.focusActiveCell();
|
|
10820
|
+
});
|
|
10821
|
+
});
|
|
10822
|
+
}
|
|
10823
|
+
}
|
|
10824
|
+
}
|
|
10825
|
+
}
|
|
10826
|
+
|
|
10342
10827
|
/**
|
|
10343
10828
|
* Handles cross-month boundary navigation events from month components.
|
|
10344
10829
|
* @private
|
|
@@ -10351,15 +10836,15 @@ class AuroCalendar extends RangeDatepicker {
|
|
|
10351
10836
|
if (key === 'ArrowRight' || key === 'ArrowLeft') {
|
|
10352
10837
|
// Linear navigation: find adjacent focusable cell across months
|
|
10353
10838
|
const allCells = this.getAllFocusableCells();
|
|
10354
|
-
const currentIndex = allCells.findIndex(cell => cell.day && cell.day.date === fromDate);
|
|
10839
|
+
const currentIndex = allCells.findIndex((cell) => cell.day && cell.day.date === fromDate);
|
|
10355
10840
|
|
|
10356
|
-
if (currentIndex === -1)
|
|
10841
|
+
if (currentIndex === -1) {
|
|
10842
|
+
return;
|
|
10843
|
+
}
|
|
10357
10844
|
|
|
10358
|
-
let targetIndex;
|
|
10845
|
+
let targetIndex = -1;
|
|
10359
10846
|
if (direction === 'next') {
|
|
10360
10847
|
targetIndex = currentIndex + 1;
|
|
10361
|
-
} else {
|
|
10362
|
-
targetIndex = currentIndex - 1;
|
|
10363
10848
|
}
|
|
10364
10849
|
|
|
10365
10850
|
if (targetIndex >= 0 && targetIndex < allCells.length) {
|
|
@@ -10377,11 +10862,15 @@ class AuroCalendar extends RangeDatepicker {
|
|
|
10377
10862
|
nextDate.setHours(0, 0, 0, 0);
|
|
10378
10863
|
const nextTs = Math.floor(nextDate.getTime() / 1000);
|
|
10379
10864
|
|
|
10380
|
-
this.
|
|
10865
|
+
if (!this.isDateInRange(nextTs)) {
|
|
10866
|
+
return;
|
|
10867
|
+
}
|
|
10868
|
+
|
|
10869
|
+
this.handleNextMonth({ skipActiveUpdate: true });
|
|
10381
10870
|
requestAnimationFrame(() => {
|
|
10382
10871
|
requestAnimationFrame(() => {
|
|
10383
10872
|
const cells = this.getAllFocusableCells();
|
|
10384
|
-
const target = cells.find(cell => cell.day && cell.day.date === nextTs);
|
|
10873
|
+
const target = cells.find((cell) => cell.day && cell.day.date === nextTs);
|
|
10385
10874
|
if (target) {
|
|
10386
10875
|
this.setActiveCell(target.day.date);
|
|
10387
10876
|
this.focusActiveCell();
|
|
@@ -10399,11 +10888,15 @@ class AuroCalendar extends RangeDatepicker {
|
|
|
10399
10888
|
prevDate.setHours(0, 0, 0, 0);
|
|
10400
10889
|
const prevTs = Math.floor(prevDate.getTime() / 1000);
|
|
10401
10890
|
|
|
10402
|
-
this.
|
|
10891
|
+
if (!this.isDateInRange(prevTs)) {
|
|
10892
|
+
return;
|
|
10893
|
+
}
|
|
10894
|
+
|
|
10895
|
+
this.handlePrevMonth({ skipActiveUpdate: true });
|
|
10403
10896
|
requestAnimationFrame(() => {
|
|
10404
10897
|
requestAnimationFrame(() => {
|
|
10405
10898
|
const cells = this.getAllFocusableCells();
|
|
10406
|
-
const target = cells.find(cell => cell.day && cell.day.date === prevTs);
|
|
10899
|
+
const target = cells.find((cell) => cell.day && cell.day.date === prevTs);
|
|
10407
10900
|
if (target) {
|
|
10408
10901
|
this.setActiveCell(target.day.date);
|
|
10409
10902
|
this.focusActiveCell();
|
|
@@ -10425,25 +10918,25 @@ class AuroCalendar extends RangeDatepicker {
|
|
|
10425
10918
|
const targetDate = Math.floor(currentDate.getTime() / 1000);
|
|
10426
10919
|
|
|
10427
10920
|
const allCells = this.getAllFocusableCells();
|
|
10428
|
-
|
|
10921
|
+
const targetCell = allCells.find((cell) => cell.day && cell.day.date === targetDate);
|
|
10429
10922
|
|
|
10430
10923
|
if (targetCell) {
|
|
10431
10924
|
this.setActiveCell(targetCell.day.date);
|
|
10432
10925
|
this.scrollToActiveCell();
|
|
10433
10926
|
this.focusActiveCell();
|
|
10434
|
-
} else {
|
|
10927
|
+
} else if (this.isDateInRange(targetDate)) {
|
|
10435
10928
|
// Target might be in an unrendered month, navigate there
|
|
10436
10929
|
const navDirection = key === 'ArrowDown' ? 'next' : 'prev';
|
|
10437
|
-
if ((navDirection === 'next' && this.showNextMonthBtn) || (navDirection === 'prev' && this.showPrevMonthBtn)) {
|
|
10930
|
+
if ((navDirection === 'next' && this.showNextMonthBtn) || (navDirection === 'prev' && this.showPrevMonthBtn)) { // eslint-disable-line no-extra-parens
|
|
10438
10931
|
if (navDirection === 'next') {
|
|
10439
|
-
this.handleNextMonth();
|
|
10932
|
+
this.handleNextMonth({ skipActiveUpdate: true });
|
|
10440
10933
|
} else {
|
|
10441
|
-
this.handlePrevMonth();
|
|
10934
|
+
this.handlePrevMonth({ skipActiveUpdate: true });
|
|
10442
10935
|
}
|
|
10443
10936
|
requestAnimationFrame(() => {
|
|
10444
10937
|
requestAnimationFrame(() => {
|
|
10445
10938
|
const cells = this.getAllFocusableCells();
|
|
10446
|
-
const target = cells.find(cell => cell.day && cell.day.date === targetDate);
|
|
10939
|
+
const target = cells.find((cell) => cell.day && cell.day.date === targetDate);
|
|
10447
10940
|
if (target) {
|
|
10448
10941
|
this.setActiveCell(target.day.date);
|
|
10449
10942
|
this.focusActiveCell();
|
|
@@ -10469,7 +10962,195 @@ class AuroCalendar extends RangeDatepicker {
|
|
|
10469
10962
|
handleCellActivate(event) {
|
|
10470
10963
|
const { date } = event.detail;
|
|
10471
10964
|
this.setActiveCell(date);
|
|
10472
|
-
|
|
10965
|
+
|
|
10966
|
+
// Don't call focusActiveCell() here. The tap/click already placed
|
|
10967
|
+
// focus on the cell button, and moving it to #calendarGrid would
|
|
10968
|
+
// trigger focusout on the button, closing any open popover on the
|
|
10969
|
+
// cell. Keyboard events are composed and still bubble through
|
|
10970
|
+
// shadow DOM boundaries to the grid's @keydown handler, so
|
|
10971
|
+
// subsequent keyboard navigation continues to work.
|
|
10972
|
+
}
|
|
10973
|
+
|
|
10974
|
+
/**
|
|
10975
|
+
* Handles focus events from calendar cells.
|
|
10976
|
+
* Updates the live region with an SR announcement and triggers
|
|
10977
|
+
* the imperative range preview if applicable.
|
|
10978
|
+
* @private
|
|
10979
|
+
* @param {CustomEvent} event - The calendar-cell-focused event.
|
|
10980
|
+
* @returns {void}
|
|
10981
|
+
*/
|
|
10982
|
+
handleCellFocused(event) {
|
|
10983
|
+
const { date } = event.detail;
|
|
10984
|
+
if (date === null) {
|
|
10985
|
+
return;
|
|
10986
|
+
}
|
|
10987
|
+
|
|
10988
|
+
// With aria-activedescendant, the button no longer receives native focus,
|
|
10989
|
+
// so we use the debounced live region for the full context announcement.
|
|
10990
|
+
const announcement = this.buildFocusAnnouncement(date);
|
|
10991
|
+
this.announceFocusDebounced(announcement);
|
|
10992
|
+
|
|
10993
|
+
// Update the range preview imperatively if in range-preview mode.
|
|
10994
|
+
this.updateRangePreview(date);
|
|
10995
|
+
}
|
|
10996
|
+
|
|
10997
|
+
/**
|
|
10998
|
+
* Builds a full SR announcement string for a focused cell date.
|
|
10999
|
+
* Includes the localized date, range position, popover content,
|
|
11000
|
+
* and blackout status.
|
|
11001
|
+
* @private
|
|
11002
|
+
* @param {Number} date - Unix timestamp (seconds) of the focused cell.
|
|
11003
|
+
* @returns {String} The announcement string.
|
|
11004
|
+
*/
|
|
11005
|
+
buildFocusAnnouncement(date) {
|
|
11006
|
+
let label = this.formatAnnouncementDate(date);
|
|
11007
|
+
|
|
11008
|
+
// Append date slot content (e.g. prices) if present.
|
|
11009
|
+
const dateObj = new Date(date * 1000);
|
|
11010
|
+
const mm = String(dateObj.getMonth() + 1).padStart(2, '0');
|
|
11011
|
+
const dd = String(dateObj.getDate()).padStart(2, '0');
|
|
11012
|
+
const yyyy = dateObj.getFullYear();
|
|
11013
|
+
const dateStr = `${mm}_${dd}_${yyyy}`;
|
|
11014
|
+
const dateSlotEl = this.datepicker?.querySelector(`[slot="date_${dateStr}"]`);
|
|
11015
|
+
if (dateSlotEl) {
|
|
11016
|
+
const text = dateSlotEl.innerText?.trim();
|
|
11017
|
+
if (text) {
|
|
11018
|
+
label += `, ${text}`;
|
|
11019
|
+
}
|
|
11020
|
+
}
|
|
11021
|
+
|
|
11022
|
+
// Append popover content if present.
|
|
11023
|
+
const popoverEl = this.datepicker?.querySelector(`[slot="popover_${dateStr}"]`);
|
|
11024
|
+
if (popoverEl) {
|
|
11025
|
+
const text = popoverEl.innerText?.trim();
|
|
11026
|
+
if (text) {
|
|
11027
|
+
label += `, ${text}`;
|
|
11028
|
+
}
|
|
11029
|
+
}
|
|
11030
|
+
|
|
11031
|
+
// Append range position context.
|
|
11032
|
+
if (this.datepicker?.hasAttribute('range')) {
|
|
11033
|
+
const rangeLabel = this.getRangePositionLabel(date);
|
|
11034
|
+
if (rangeLabel) {
|
|
11035
|
+
label += `, ${rangeLabel}`;
|
|
11036
|
+
}
|
|
11037
|
+
}
|
|
11038
|
+
|
|
11039
|
+
// Append blackout label.
|
|
11040
|
+
if (this.isDateBlackout(date)) {
|
|
11041
|
+
label += `, ${this.datepicker?.blackoutLabel || 'unavailable'}`;
|
|
11042
|
+
}
|
|
11043
|
+
|
|
11044
|
+
return label;
|
|
11045
|
+
}
|
|
11046
|
+
|
|
11047
|
+
/**
|
|
11048
|
+
* Determines the range position label for a given date.
|
|
11049
|
+
* @private
|
|
11050
|
+
* @param {Number} date - Unix timestamp (seconds).
|
|
11051
|
+
* @returns {String|null} The range position label, or null.
|
|
11052
|
+
*/
|
|
11053
|
+
getRangePositionLabel(date) {
|
|
11054
|
+
const parsedFrom = Number.parseInt(this.dateFrom, 10);
|
|
11055
|
+
if (!Number.isFinite(parsedFrom)) {
|
|
11056
|
+
return null;
|
|
11057
|
+
}
|
|
11058
|
+
|
|
11059
|
+
const departTs = startOfDay(parsedFrom * 1000) / 1000;
|
|
11060
|
+
const parsedTo = Number.parseInt(this.dateTo, 10);
|
|
11061
|
+
const hasTo = Number.isFinite(parsedTo);
|
|
11062
|
+
const returnTs = hasTo ? startOfDay(parsedTo * 1000) / 1000 : null;
|
|
11063
|
+
|
|
11064
|
+
if (date === departTs) {
|
|
11065
|
+
return this.datepicker.rangeLabelStart || 'range start';
|
|
11066
|
+
}
|
|
11067
|
+
if (hasTo && date === returnTs) {
|
|
11068
|
+
return this.datepicker.rangeLabelEnd || 'range end';
|
|
11069
|
+
}
|
|
11070
|
+
if (date < departTs) {
|
|
11071
|
+
return this.datepicker.rangeLabelBeforeRange || 'before range';
|
|
11072
|
+
}
|
|
11073
|
+
if (hasTo && date > departTs && date < returnTs) {
|
|
11074
|
+
return this.datepicker.rangeLabelInRange || 'in range';
|
|
11075
|
+
}
|
|
11076
|
+
return this.datepicker.rangeLabelAfterRange || 'after range';
|
|
11077
|
+
}
|
|
11078
|
+
|
|
11079
|
+
/**
|
|
11080
|
+
* Checks whether a given date is a blackout date.
|
|
11081
|
+
* @private
|
|
11082
|
+
* @param {Number} dateTs - Unix timestamp (seconds).
|
|
11083
|
+
* @returns {Boolean} True if the date is blacked out.
|
|
11084
|
+
*/
|
|
11085
|
+
isDateBlackout(dateTs) {
|
|
11086
|
+
// Check legacy disabledDays.
|
|
11087
|
+
if (Array.isArray(this.disabledDays) && this.disabledDays.length > 0) {
|
|
11088
|
+
if (this.disabledDays.findIndex((day) => parseInt(day, 10) === dateTs) !== -1) {
|
|
11089
|
+
return true;
|
|
11090
|
+
}
|
|
11091
|
+
}
|
|
11092
|
+
|
|
11093
|
+
// Check ISO blackoutDates.
|
|
11094
|
+
const blackoutDates = this.datepicker?.blackoutDates;
|
|
11095
|
+
if (Array.isArray(blackoutDates) && blackoutDates.length > 0) {
|
|
11096
|
+
const date = new Date(dateTs * 1000);
|
|
11097
|
+
const yyyy = date.getFullYear();
|
|
11098
|
+
const mm = String(date.getMonth() + 1).padStart(2, '0');
|
|
11099
|
+
const dd = String(date.getDate()).padStart(2, '0');
|
|
11100
|
+
if (blackoutDates.includes(`${yyyy}-${mm}-${dd}`)) {
|
|
11101
|
+
return true;
|
|
11102
|
+
}
|
|
11103
|
+
}
|
|
11104
|
+
|
|
11105
|
+
return false;
|
|
11106
|
+
}
|
|
11107
|
+
|
|
11108
|
+
/**
|
|
11109
|
+
* Updates the range preview classes imperatively across all cells.
|
|
11110
|
+
* Only active when in range mode with dateFrom set and dateTo not yet set.
|
|
11111
|
+
* @private
|
|
11112
|
+
* @param {Number} hoveredDate - Unix timestamp of the hovered/focused date.
|
|
11113
|
+
* @returns {void}
|
|
11114
|
+
*/
|
|
11115
|
+
updateRangePreview(hoveredDate) {
|
|
11116
|
+
if (this.noRange || !this.dateFrom || this.dateTo) {
|
|
11117
|
+
return;
|
|
11118
|
+
}
|
|
11119
|
+
|
|
11120
|
+
const parsedDateFrom = parseInt(this.dateFrom, 10);
|
|
11121
|
+
const allCells = this.getAllFocusableCells();
|
|
11122
|
+
|
|
11123
|
+
allCells.forEach((cell) => {
|
|
11124
|
+
cell.updateRangePreviewClasses(hoveredDate, parsedDateFrom);
|
|
11125
|
+
});
|
|
11126
|
+
}
|
|
11127
|
+
|
|
11128
|
+
/**
|
|
11129
|
+
* Clears range preview classes from all cells.
|
|
11130
|
+
* @private
|
|
11131
|
+
* @returns {void}
|
|
11132
|
+
*/
|
|
11133
|
+
clearRangePreview() {
|
|
11134
|
+
if (this.dateFrom && this.dateTo) {
|
|
11135
|
+
return;
|
|
11136
|
+
}
|
|
11137
|
+
|
|
11138
|
+
const allCells = this.getAllFocusableCells();
|
|
11139
|
+
allCells.forEach((cell) => {
|
|
11140
|
+
cell.clearRangePreviewClasses();
|
|
11141
|
+
});
|
|
11142
|
+
}
|
|
11143
|
+
|
|
11144
|
+
/**
|
|
11145
|
+
* Overrides the base class handler to prevent setting `this.hoveredDate`
|
|
11146
|
+
* as a reactive property. Instead, handles the range preview imperatively.
|
|
11147
|
+
* @private
|
|
11148
|
+
* @param {CustomEvent} event - The hovered-date-changed event from a month.
|
|
11149
|
+
* @returns {void}
|
|
11150
|
+
*/
|
|
11151
|
+
hoveredDateChanged(event) {
|
|
11152
|
+
const hoveredDate = event.detail.value;
|
|
11153
|
+
this.updateRangePreview(hoveredDate);
|
|
10473
11154
|
}
|
|
10474
11155
|
|
|
10475
11156
|
/**
|
|
@@ -10478,7 +11159,9 @@ class AuroCalendar extends RangeDatepicker {
|
|
|
10478
11159
|
* @returns {void}
|
|
10479
11160
|
*/
|
|
10480
11161
|
scrollToActiveCell() {
|
|
10481
|
-
if (this.activeCellDate
|
|
11162
|
+
if (this.activeCellDate === null || this.activeCellDate === undefined) {
|
|
11163
|
+
return;
|
|
11164
|
+
}
|
|
10482
11165
|
|
|
10483
11166
|
const date = new Date(this.activeCellDate * 1000);
|
|
10484
11167
|
const month = date.getMonth() + 1;
|
|
@@ -10488,25 +11171,138 @@ class AuroCalendar extends RangeDatepicker {
|
|
|
10488
11171
|
|
|
10489
11172
|
if (monthElem) {
|
|
10490
11173
|
const prefersReducedMotion = window.matchMedia('(prefers-reduced-motion: reduce)').matches;
|
|
10491
|
-
monthElem.scrollIntoView({ block: 'nearest',
|
|
11174
|
+
monthElem.scrollIntoView({ block: 'nearest',
|
|
11175
|
+
behavior: prefersReducedMotion ? 'instant' : 'smooth' });
|
|
10492
11176
|
}
|
|
10493
11177
|
}
|
|
10494
11178
|
|
|
10495
11179
|
/**
|
|
10496
|
-
*
|
|
11180
|
+
* Returns (and lazily creates) an aria-live region inside the dropdown's
|
|
11181
|
+
* <dialog> element. This placement is critical for two reasons:
|
|
11182
|
+
*
|
|
11183
|
+
* 1. Inside the dialog's accessible scope — dialog.showModal() makes
|
|
11184
|
+
* everything outside the top-layer dialog inert, and desktop modal
|
|
11185
|
+
* mode uses _setPageInert() on document.body siblings. A live region
|
|
11186
|
+
* on document.body would be invisible to screen readers in both cases.
|
|
11187
|
+
*
|
|
11188
|
+
* 2. Not nested in shadow DOM — Chrome inconsistently observes aria-live
|
|
11189
|
+
* mutations inside shadow DOM across machines and versions. The dialog
|
|
11190
|
+
* element is only one shadow root deep (the dropdown bib's shadow DOM),
|
|
11191
|
+
* which Chrome handles reliably. The calendar's own shadow DOM (nested
|
|
11192
|
+
* inside the bib via slotting) is two+ levels deep and unreliable.
|
|
11193
|
+
*
|
|
11194
|
+
* @private
|
|
11195
|
+
* @returns {HTMLElement} The live region element.
|
|
11196
|
+
*/
|
|
11197
|
+
getOrCreateLiveRegion() {
|
|
11198
|
+
if (this._liveRegion && this._liveRegion.isConnected) {
|
|
11199
|
+
return this._liveRegion;
|
|
11200
|
+
}
|
|
11201
|
+
|
|
11202
|
+
// Access the dialog element inside the dropdown bib's shadow DOM.
|
|
11203
|
+
const dialog = this.dropdown?.bibContent?.shadowRoot?.querySelector('dialog');
|
|
11204
|
+
if (!dialog) {
|
|
11205
|
+
return null;
|
|
11206
|
+
}
|
|
11207
|
+
|
|
11208
|
+
// Check if we already created one for this calendar instance.
|
|
11209
|
+
const regionId = `auro-calendar-live-${this._calendarInstanceId}`;
|
|
11210
|
+
const existing = dialog.querySelector(`#${regionId}`);
|
|
11211
|
+
if (existing) {
|
|
11212
|
+
this._liveRegion = existing;
|
|
11213
|
+
return existing;
|
|
11214
|
+
}
|
|
11215
|
+
|
|
11216
|
+
const el = document.createElement('div');
|
|
11217
|
+
el.id = regionId;
|
|
11218
|
+
el.setAttribute('aria-live', 'assertive');
|
|
11219
|
+
el.setAttribute('aria-atomic', 'true');
|
|
11220
|
+
el.style.cssText = 'position:absolute;width:1px;height:1px;padding:0;margin:-1px;overflow:hidden;clip:rect(0,0,0,0);white-space:nowrap;border:0;';
|
|
11221
|
+
dialog.appendChild(el);
|
|
11222
|
+
|
|
11223
|
+
this._liveRegion = el;
|
|
11224
|
+
return el;
|
|
11225
|
+
}
|
|
11226
|
+
|
|
11227
|
+
/**
|
|
11228
|
+
* Removes the live region when this calendar is disconnected.
|
|
11229
|
+
* @private
|
|
11230
|
+
* @returns {void}
|
|
11231
|
+
*/
|
|
11232
|
+
disconnectedCallback() {
|
|
11233
|
+
super.disconnectedCallback();
|
|
11234
|
+
|
|
11235
|
+
// Cancel any pending announcements so they don't fire after teardown.
|
|
11236
|
+
if (this._announceRafId) {
|
|
11237
|
+
cancelAnimationFrame(this._announceRafId);
|
|
11238
|
+
this._announceRafId = null;
|
|
11239
|
+
}
|
|
11240
|
+
if (this._focusAnnounceTimer) {
|
|
11241
|
+
clearTimeout(this._focusAnnounceTimer);
|
|
11242
|
+
this._focusAnnounceTimer = null;
|
|
11243
|
+
}
|
|
11244
|
+
|
|
11245
|
+
if (this._liveRegion && this._liveRegion.isConnected) {
|
|
11246
|
+
this._liveRegion.remove();
|
|
11247
|
+
}
|
|
11248
|
+
this._liveRegion = null;
|
|
11249
|
+
}
|
|
11250
|
+
|
|
11251
|
+
/**
|
|
11252
|
+
* Announces a date selection or focus change via the live region.
|
|
11253
|
+
* Uses requestAnimationFrame to ensure the clear and set happen in
|
|
11254
|
+
* separate rendering frames — Chrome may coalesce synchronous or
|
|
11255
|
+
* microtask-deferred mutations into a single accessibility tree update.
|
|
10497
11256
|
* @private
|
|
10498
11257
|
* @param {String} dateStr - The localized date string to announce.
|
|
10499
11258
|
* @returns {void}
|
|
10500
11259
|
*/
|
|
10501
11260
|
announceSelection(dateStr) {
|
|
10502
|
-
|
|
10503
|
-
|
|
10504
|
-
|
|
10505
|
-
|
|
10506
|
-
|
|
11261
|
+
// Cancel any previously queued rAF announcement so a rapid
|
|
11262
|
+
// sequence of calls (e.g. bib open → month nav) only announces
|
|
11263
|
+
// the last one.
|
|
11264
|
+
if (this._announceRafId) {
|
|
11265
|
+
cancelAnimationFrame(this._announceRafId);
|
|
11266
|
+
}
|
|
11267
|
+
const liveRegion = this.getOrCreateLiveRegion();
|
|
11268
|
+
if (!liveRegion) {
|
|
11269
|
+
return;
|
|
11270
|
+
}
|
|
11271
|
+
|
|
11272
|
+
// Double-rAF: clear in frame N, set in frame N+1. Chrome batches
|
|
11273
|
+
// accessibility tree mutations within a single animation frame, so
|
|
11274
|
+
// a same-frame clear+set can be coalesced into a no-op if the new
|
|
11275
|
+
// value matches a recently announced string. Splitting across two
|
|
11276
|
+
// frames guarantees Chrome sees two distinct tree states and fires
|
|
11277
|
+
// a new accessibility event for the content change.
|
|
11278
|
+
liveRegion.textContent = '';
|
|
11279
|
+
this._announceRafId = requestAnimationFrame(() => {
|
|
11280
|
+
this._announceRafId = requestAnimationFrame(() => {
|
|
10507
11281
|
liveRegion.textContent = dateStr;
|
|
11282
|
+
this._announceRafId = null;
|
|
10508
11283
|
});
|
|
11284
|
+
});
|
|
11285
|
+
}
|
|
11286
|
+
|
|
11287
|
+
/**
|
|
11288
|
+
* Debounced version of announceSelection for focus navigation.
|
|
11289
|
+
* Uses the assertive live region with a 150ms debounce so only the
|
|
11290
|
+
* final cell after rapid arrow-key traversal is announced. We
|
|
11291
|
+
* originally tried aria-live="polite" here, but VoiceOver treats
|
|
11292
|
+
* polite as "wait until idle" — which never happens during active
|
|
11293
|
+
* keyboard navigation — so the announcements were silently dropped.
|
|
11294
|
+
* @private
|
|
11295
|
+
* @param {String} dateStr - The localized date string to announce.
|
|
11296
|
+
* @returns {void}
|
|
11297
|
+
*/
|
|
11298
|
+
announceFocusDebounced(dateStr) {
|
|
11299
|
+
if (this._focusAnnounceTimer) {
|
|
11300
|
+
clearTimeout(this._focusAnnounceTimer);
|
|
10509
11301
|
}
|
|
11302
|
+
this._focusAnnounceTimer = setTimeout(() => {
|
|
11303
|
+
this.announceSelection(dateStr);
|
|
11304
|
+
this._focusAnnounceTimer = null;
|
|
11305
|
+
}, 150);
|
|
10510
11306
|
}
|
|
10511
11307
|
|
|
10512
11308
|
/**
|
|
@@ -10519,12 +11315,16 @@ class AuroCalendar extends RangeDatepicker {
|
|
|
10519
11315
|
const date = new Date(parseInt(timestamp, 10) * 1000);
|
|
10520
11316
|
const localeCode = this.locale?.code || undefined;
|
|
10521
11317
|
const formatter = new Intl.DateTimeFormat(localeCode, {
|
|
10522
|
-
weekday: 'long',
|
|
11318
|
+
weekday: 'long',
|
|
11319
|
+
year: 'numeric',
|
|
11320
|
+
month: 'long',
|
|
11321
|
+
day: 'numeric'
|
|
10523
11322
|
});
|
|
10524
11323
|
return formatter.format(date);
|
|
10525
11324
|
}
|
|
10526
11325
|
|
|
10527
11326
|
firstUpdated() {
|
|
11327
|
+
|
|
10528
11328
|
this.addEventListener('date-from-changed', () => {
|
|
10529
11329
|
this.dispatchEvent(new CustomEvent('auroCalendar-dateSelected', {
|
|
10530
11330
|
bubbles: true,
|
|
@@ -10553,6 +11353,11 @@ class AuroCalendar extends RangeDatepicker {
|
|
|
10553
11353
|
this.addEventListener('calendar-cell-activate', (event) => {
|
|
10554
11354
|
this.handleCellActivate(event);
|
|
10555
11355
|
});
|
|
11356
|
+
|
|
11357
|
+
// Listen for cell focus events (SR announcements + range preview)
|
|
11358
|
+
this.addEventListener('calendar-cell-focused', (event) => {
|
|
11359
|
+
this.handleCellFocused(event);
|
|
11360
|
+
});
|
|
10556
11361
|
}
|
|
10557
11362
|
|
|
10558
11363
|
injectSlot(slotName, nodes) {
|
|
@@ -10579,7 +11384,7 @@ class AuroCalendar extends RangeDatepicker {
|
|
|
10579
11384
|
if (changedProperties.has('visible')) {
|
|
10580
11385
|
if (this.visible) {
|
|
10581
11386
|
// Compute the active date eagerly from data — no DOM needed.
|
|
10582
|
-
if (this.activeCellDate == null) {
|
|
11387
|
+
if (this.activeCellDate == null) { // eslint-disable-line no-eq-null, eqeqeq
|
|
10583
11388
|
this.activeCellDate = this.computeActiveDate();
|
|
10584
11389
|
}
|
|
10585
11390
|
|
|
@@ -10647,7 +11452,7 @@ class AuroCalendar extends RangeDatepicker {
|
|
|
10647
11452
|
</button>
|
|
10648
11453
|
` : undefined}
|
|
10649
11454
|
</div>
|
|
10650
|
-
<div class="calendars">
|
|
11455
|
+
<div id="calendarGrid" class="calendars" role="group" tabindex="0" @keydown="${this.handleGridKeyDown}" @focusin="${this.handleGridFocusIn}" @focusout="${this.handleGridFocusOut}" @calendar-month-mouseleave="${this.clearRangePreview}">
|
|
10651
11456
|
${this.renderAllCalendars()}
|
|
10652
11457
|
</div>
|
|
10653
11458
|
</div>
|
|
@@ -14556,7 +15361,7 @@ let AuroHelpText$2 = class AuroHelpText extends i$1 {
|
|
|
14556
15361
|
}
|
|
14557
15362
|
};
|
|
14558
15363
|
|
|
14559
|
-
var formkitVersion$1 = '
|
|
15364
|
+
var formkitVersion$1 = '202606030033';
|
|
14560
15365
|
|
|
14561
15366
|
let AuroElement$2 = class AuroElement extends i$1 {
|
|
14562
15367
|
static get properties() {
|
|
@@ -15549,13 +16354,20 @@ class AuroDropdown extends AuroElement$2 {
|
|
|
15549
16354
|
|
|
15550
16355
|
// Walk up the ancestor chain, inerting siblings at each level
|
|
15551
16356
|
// to ensure the entire page outside the host subtree is inert.
|
|
16357
|
+
// Uses a reference counter (data-auro-inert-count) so multiple
|
|
16358
|
+
// simultaneous modal dropdowns share inert state safely.
|
|
15552
16359
|
let current = host;
|
|
15553
16360
|
while (current.parentElement) {
|
|
15554
16361
|
const parent = current.parentElement;
|
|
15555
16362
|
for (const sibling of parent.children) {
|
|
15556
16363
|
if (sibling !== current) {
|
|
15557
|
-
|
|
16364
|
+
const count = parseInt(sibling.dataset.auroInertCount || '0', 10);
|
|
16365
|
+
if (count === 0) {
|
|
16366
|
+
sibling.dataset.auroInertWas = sibling.inert ? 'true' : 'false';
|
|
16367
|
+
}
|
|
16368
|
+
sibling.dataset.auroInertCount = String(count + 1);
|
|
15558
16369
|
sibling.inert = true;
|
|
16370
|
+
this._inertSiblings.push(sibling);
|
|
15559
16371
|
}
|
|
15560
16372
|
}
|
|
15561
16373
|
current = parent;
|
|
@@ -15564,14 +16376,23 @@ class AuroDropdown extends AuroElement$2 {
|
|
|
15564
16376
|
|
|
15565
16377
|
/**
|
|
15566
16378
|
* Restores `inert` state on siblings that were tracked by `_setPageInert`.
|
|
15567
|
-
*
|
|
15568
|
-
*
|
|
16379
|
+
* Uses reference counting so inert is only cleared when the last modal
|
|
16380
|
+
* dropdown releases a given element. Preserves the original inert state
|
|
16381
|
+
* so externally-inerted elements are not inadvertently re-enabled.
|
|
15569
16382
|
* @private
|
|
15570
16383
|
*/
|
|
15571
16384
|
_clearPageInert() {
|
|
15572
16385
|
if (this._inertSiblings) {
|
|
15573
|
-
for (const
|
|
15574
|
-
|
|
16386
|
+
for (const sibling of this._inertSiblings) {
|
|
16387
|
+
const count = parseInt(sibling.dataset.auroInertCount || '1', 10) - 1;
|
|
16388
|
+
if (count <= 0) {
|
|
16389
|
+
const wasInert = sibling.dataset.auroInertWas === 'true';
|
|
16390
|
+
delete sibling.dataset.auroInertCount;
|
|
16391
|
+
delete sibling.dataset.auroInertWas;
|
|
16392
|
+
sibling.inert = wasInert;
|
|
16393
|
+
} else {
|
|
16394
|
+
sibling.dataset.auroInertCount = String(count);
|
|
16395
|
+
}
|
|
15575
16396
|
}
|
|
15576
16397
|
this._inertSiblings = undefined;
|
|
15577
16398
|
}
|
|
@@ -19896,109 +20717,236 @@ class AuroInputUtilities {
|
|
|
19896
20717
|
}
|
|
19897
20718
|
}
|
|
19898
20719
|
|
|
19899
|
-
|
|
20720
|
+
/**
|
|
20721
|
+
* @description Splits a date string into its parts according to the provided format. Does NOT validate that the result is a real calendar date — use `parseDate` when validation is required.
|
|
20722
|
+
* @param {string} dateStr - Date string to parse.
|
|
20723
|
+
* @param {string} format - Date format to parse.
|
|
20724
|
+
* @returns {{ month?: string, day?: string, year?: string }|undefined}
|
|
20725
|
+
*/
|
|
20726
|
+
function getDateParts(dateStr, format) {
|
|
20727
|
+
if (!dateStr) {
|
|
20728
|
+
return undefined;
|
|
20729
|
+
}
|
|
19900
20730
|
|
|
19901
|
-
|
|
20731
|
+
const formatSeparatorMatch = format.match(/[/.-]/);
|
|
20732
|
+
let valueParts;
|
|
20733
|
+
let formatParts;
|
|
19902
20734
|
|
|
19903
|
-
|
|
19904
|
-
|
|
19905
|
-
|
|
19906
|
-
|
|
19907
|
-
|
|
19908
|
-
|
|
19909
|
-
|
|
20735
|
+
if (formatSeparatorMatch) {
|
|
20736
|
+
const separator = formatSeparatorMatch[0];
|
|
20737
|
+
valueParts = dateStr.split(separator);
|
|
20738
|
+
formatParts = format.split(separator);
|
|
20739
|
+
} else {
|
|
20740
|
+
if (dateStr.match(/[/.-]/)) {
|
|
20741
|
+
throw new Error(
|
|
20742
|
+
"AuroDatepickerUtilities | parseDate: Date string has no separators",
|
|
20743
|
+
);
|
|
20744
|
+
}
|
|
19910
20745
|
|
|
19911
|
-
|
|
19912
|
-
|
|
19913
|
-
|
|
19914
|
-
|
|
20746
|
+
if (dateStr.length !== format.length) {
|
|
20747
|
+
throw new Error(
|
|
20748
|
+
"AuroDatepickerUtilities | parseDate: Date string and format length do not match",
|
|
20749
|
+
);
|
|
20750
|
+
}
|
|
19915
20751
|
|
|
19916
|
-
|
|
19917
|
-
|
|
20752
|
+
valueParts = [dateStr];
|
|
20753
|
+
formatParts = [format];
|
|
20754
|
+
}
|
|
19918
20755
|
|
|
19919
|
-
|
|
19920
|
-
|
|
19921
|
-
|
|
20756
|
+
if (valueParts.length !== formatParts.length) {
|
|
20757
|
+
throw new Error(
|
|
20758
|
+
`AuroDatepickerUtilities | parseDate: Date string and format do not match : ${dateStr} vs ${format}`,
|
|
20759
|
+
);
|
|
20760
|
+
}
|
|
19922
20761
|
|
|
19923
|
-
|
|
19924
|
-
|
|
19925
|
-
throw new Error('AuroDatepickerUtilities | parseDate: Date string and format length do not match');
|
|
19926
|
-
}
|
|
20762
|
+
const result = formatParts.reduce((acc, part, index) => {
|
|
20763
|
+
const value = valueParts[index];
|
|
19927
20764
|
|
|
19928
|
-
|
|
19929
|
-
|
|
19930
|
-
|
|
20765
|
+
if (/m/iu.test(part) && part.length === value.length) {
|
|
20766
|
+
acc.month = value;
|
|
20767
|
+
} else if (/d/iu.test(part) && part.length === value.length) {
|
|
20768
|
+
acc.day = value;
|
|
20769
|
+
} else if (/y/iu.test(part) && part.length === value.length) {
|
|
20770
|
+
acc.year = value;
|
|
20771
|
+
}
|
|
19931
20772
|
|
|
19932
|
-
|
|
19933
|
-
|
|
19934
|
-
} else if ((/d/iu).test(part)) {
|
|
19935
|
-
acc.day = value;
|
|
19936
|
-
} else if ((/y/iu).test(part)) {
|
|
19937
|
-
acc.year = value;
|
|
19938
|
-
}
|
|
20773
|
+
return acc;
|
|
20774
|
+
}, {});
|
|
19939
20775
|
|
|
19940
|
-
|
|
19941
|
-
|
|
20776
|
+
if (!result.month && !result.day && !result.year) {
|
|
20777
|
+
throw new Error(
|
|
20778
|
+
"AuroDatepickerUtilities | parseDate: Unable to parse date string",
|
|
20779
|
+
);
|
|
20780
|
+
}
|
|
19942
20781
|
|
|
19943
|
-
|
|
19944
|
-
|
|
19945
|
-
return result;
|
|
19946
|
-
}
|
|
20782
|
+
return result;
|
|
20783
|
+
}
|
|
19947
20784
|
|
|
19948
|
-
|
|
19949
|
-
|
|
19950
|
-
|
|
20785
|
+
function isCalendarDate(year, month, day) {
|
|
20786
|
+
let yearNumber = Number(year);
|
|
20787
|
+
const monthNumber = Number(month);
|
|
20788
|
+
const dayNumber = Number(day);
|
|
19951
20789
|
|
|
19952
|
-
|
|
19953
|
-
|
|
19954
|
-
|
|
19955
|
-
|
|
19956
|
-
|
|
19957
|
-
|
|
19958
|
-
|
|
19959
|
-
year: "numeric",
|
|
19960
|
-
month: "2-digit",
|
|
19961
|
-
day: "2-digit",
|
|
19962
|
-
});
|
|
20790
|
+
if (
|
|
20791
|
+
!Number.isInteger(yearNumber) ||
|
|
20792
|
+
!Number.isInteger(monthNumber) ||
|
|
20793
|
+
!Number.isInteger(dayNumber)
|
|
20794
|
+
) {
|
|
20795
|
+
return false;
|
|
20796
|
+
}
|
|
19963
20797
|
|
|
19964
|
-
|
|
19965
|
-
|
|
19966
|
-
|
|
19967
|
-
|
|
19968
|
-
|
|
19969
|
-
|
|
19970
|
-
|
|
20798
|
+
// Handle 2-digit years by converting them to 4-digit years based on a cutoff. This allows for parsing of 2-digit year formats while still validating the resulting date.
|
|
20799
|
+
if (yearNumber < 100 && yearNumber >= 50) {
|
|
20800
|
+
yearNumber += 1900;
|
|
20801
|
+
} else if (yearNumber < 50) {
|
|
20802
|
+
yearNumber += 2000;
|
|
20803
|
+
}
|
|
20804
|
+
|
|
20805
|
+
const stringified = `${String(yearNumber).padStart(4, "0")}-${String(monthNumber).padStart(2, "0")}-${String(dayNumber).padStart(2, "0")}`;
|
|
20806
|
+
const date = new Date(stringified.replace(/[.-]/g, "/"));
|
|
20807
|
+
|
|
20808
|
+
return (
|
|
20809
|
+
!Number.isNaN(date.getTime()) && toISOFormatString(date) === stringified
|
|
20810
|
+
);
|
|
20811
|
+
}
|
|
20812
|
+
|
|
20813
|
+
/**
|
|
20814
|
+
* @description Parses a date string into its components and validates that the result is a real calendar date. Use `getDateParts` instead when raw splitting without validation is needed (e.g. for in-progress input).
|
|
20815
|
+
*
|
|
20816
|
+
* Partial formats are supported: components absent from `format` default to `year → "0"`,
|
|
20817
|
+
* `month → "01"`, `day → "01"` for calendar validation only. The returned object contains
|
|
20818
|
+
* only the fields actually present in the format string — missing fields are never injected.
|
|
20819
|
+
* @param {string} dateStr - Date string to parse.
|
|
20820
|
+
* @param {string} format - Date format to parse.
|
|
20821
|
+
* @returns {{ month?: string, day?: string, year?: string }|undefined}
|
|
20822
|
+
* @throws {Error} Throws when the parsed result does not represent a valid calendar date.
|
|
20823
|
+
*/
|
|
20824
|
+
function parseDate(dateStr, format = "mm/dd/yyyy") {
|
|
20825
|
+
if (!dateStr || !format) {
|
|
20826
|
+
return undefined;
|
|
20827
|
+
}
|
|
20828
|
+
const result = getDateParts(dateStr.trim(), format);
|
|
20829
|
+
|
|
20830
|
+
if (!result) {
|
|
20831
|
+
return undefined;
|
|
20832
|
+
}
|
|
20833
|
+
|
|
20834
|
+
const lowerFormat = format.toLowerCase();
|
|
20835
|
+
const year = lowerFormat.includes("yy") ? result.year : "0";
|
|
20836
|
+
const month = lowerFormat.includes("mm") ? result.month : "01";
|
|
20837
|
+
const day = lowerFormat.includes("dd") ? result.day : "01";
|
|
20838
|
+
|
|
20839
|
+
if (isCalendarDate(year, month, day)) {
|
|
20840
|
+
return result;
|
|
20841
|
+
}
|
|
20842
|
+
|
|
20843
|
+
throw new Error(
|
|
20844
|
+
`AuroDatepickerUtilities | parseDate: Date string is not a valid date ${JSON.stringify(result)} with format ${format}`,
|
|
20845
|
+
);
|
|
20846
|
+
}
|
|
20847
|
+
|
|
20848
|
+
/**
|
|
20849
|
+
* Convert a date object to string format.
|
|
20850
|
+
* @param {Object} date - Date to convert to string.
|
|
20851
|
+
* @param {String} locale - Optional locale to use for the date string. Defaults to user's locale.
|
|
20852
|
+
* @returns {String} Returns the date as a string.
|
|
20853
|
+
*/
|
|
20854
|
+
function getDateAsString(date, locale = undefined) {
|
|
20855
|
+
return date.toLocaleDateString(locale, {
|
|
20856
|
+
year: "numeric",
|
|
20857
|
+
month: "2-digit",
|
|
20858
|
+
day: "2-digit",
|
|
20859
|
+
});
|
|
20860
|
+
}
|
|
20861
|
+
|
|
20862
|
+
/**
|
|
20863
|
+
* Converts a date string to a North American date format.
|
|
20864
|
+
* @param {String} dateStr - Date to validate.
|
|
20865
|
+
* @param {String} format - Date format to validate against.
|
|
20866
|
+
* @returns {String}
|
|
20867
|
+
*/
|
|
20868
|
+
function toNorthAmericanFormat$1(dateStr, format) {
|
|
20869
|
+
if (format === "mm/dd/yyyy") {
|
|
20870
|
+
return dateStr;
|
|
20871
|
+
}
|
|
19971
20872
|
|
|
19972
|
-
|
|
19973
|
-
return dateStr;
|
|
19974
|
-
}
|
|
20873
|
+
const parsedDate = parseDate(dateStr, format);
|
|
19975
20874
|
|
|
19976
|
-
|
|
20875
|
+
if (!parsedDate) {
|
|
20876
|
+
throw new Error(
|
|
20877
|
+
"AuroDatepickerUtilities | toNorthAmericanFormat: Unable to parse date string",
|
|
20878
|
+
);
|
|
20879
|
+
}
|
|
19977
20880
|
|
|
19978
|
-
|
|
19979
|
-
throw new Error('AuroDatepickerUtilities | toNorthAmericanFormat: Unable to parse date string');
|
|
19980
|
-
}
|
|
20881
|
+
const { month, day, year } = parsedDate;
|
|
19981
20882
|
|
|
19982
|
-
|
|
20883
|
+
return [month, day, year].filter(Boolean).join("/");
|
|
20884
|
+
}
|
|
19983
20885
|
|
|
19984
|
-
|
|
19985
|
-
|
|
19986
|
-
|
|
19987
|
-
|
|
20886
|
+
/**
|
|
20887
|
+
* Validates that a date string matches the provided format and represents a real calendar date.
|
|
20888
|
+
*
|
|
20889
|
+
* @param {string} dateStr - Date string to validate.
|
|
20890
|
+
* @param {string} [format="yyyy-mm-dd"] - Format of the date string.
|
|
20891
|
+
* @returns {boolean} True when the date string is valid for the provided format, otherwise false.
|
|
20892
|
+
*/
|
|
20893
|
+
function isValidDate(dateStr, format = "yyyy-mm-dd") {
|
|
20894
|
+
try {
|
|
20895
|
+
if (typeof dateStr !== "string" || !dateStr || format?.length < 8) {
|
|
20896
|
+
return false;
|
|
20897
|
+
}
|
|
19988
20898
|
|
|
19989
|
-
|
|
19990
|
-
|
|
19991
|
-
|
|
20899
|
+
if (parseDate(dateStr, format)) {
|
|
20900
|
+
return true;
|
|
20901
|
+
}
|
|
20902
|
+
} catch (error) {
|
|
20903
|
+
return false;
|
|
20904
|
+
}
|
|
20905
|
+
return false;
|
|
20906
|
+
}
|
|
19992
20907
|
|
|
19993
|
-
|
|
19994
|
-
|
|
19995
|
-
|
|
20908
|
+
/**
|
|
20909
|
+
* Converts a JavaScript Date instance to a simple ISO-like date string. This returns only the calendar date portion without any time or timezone information.
|
|
20910
|
+
*
|
|
20911
|
+
* @param {Date} date - Date instance to convert to an ISO-like string.
|
|
20912
|
+
* @returns {string} A string in the format "yyyy-mm-dd" representing the provided date.
|
|
20913
|
+
* @throws {Error} Throws an error when the input is not a valid Date instance.
|
|
20914
|
+
*/
|
|
20915
|
+
function toISOFormatString(date) {
|
|
20916
|
+
if (!(date instanceof Date) || Number.isNaN(date.getTime())) {
|
|
20917
|
+
throw new Error(
|
|
20918
|
+
"AuroDatepickerUtilities | toISOFormatString: Input must be a valid Date instance",
|
|
20919
|
+
);
|
|
20920
|
+
}
|
|
20921
|
+
return `${String(date.getFullYear()).padStart(4, "0")}-${String(date.getMonth() + 1).padStart(2, "0")}-${String(date.getDate()).padStart(2, "0")}`;
|
|
20922
|
+
}
|
|
19996
20923
|
|
|
19997
|
-
|
|
19998
|
-
|
|
20924
|
+
/**
|
|
20925
|
+
* Converts a date string into a JavaScript Date instance. This method supports ISO formatted strings and other formats that can be parsed by the formatter.
|
|
20926
|
+
*
|
|
20927
|
+
* @param {String} dateStr - Date string to convert into a Date object.
|
|
20928
|
+
* @param {String} format - Date format used to parse the string when it is not in ISO format.
|
|
20929
|
+
* @returns {Date|null} Returns a Date instance for valid input or null for non-string input.
|
|
20930
|
+
* @throws {Error} Throws when parsing fails for non-ISO string input.
|
|
20931
|
+
*/
|
|
20932
|
+
function stringToDateInstance(dateStr, format = "yyyy-mm-dd") {
|
|
20933
|
+
if (typeof dateStr !== "string") {
|
|
20934
|
+
return null;
|
|
19999
20935
|
}
|
|
20936
|
+
|
|
20937
|
+
const { month, day, year } = parseDate(dateStr, format);
|
|
20938
|
+
return new Date(`${year}/${month}/${day}`);
|
|
20000
20939
|
}
|
|
20001
|
-
|
|
20940
|
+
|
|
20941
|
+
const dateFormatter = {
|
|
20942
|
+
parseDate,
|
|
20943
|
+
getDateParts,
|
|
20944
|
+
getDateAsString,
|
|
20945
|
+
toNorthAmericanFormat: toNorthAmericanFormat$1,
|
|
20946
|
+
isValidDate,
|
|
20947
|
+
toISOFormatString,
|
|
20948
|
+
stringToDateInstance,
|
|
20949
|
+
};
|
|
20002
20950
|
|
|
20003
20951
|
// filepath: dateConstraints.mjs
|
|
20004
20952
|
const DATE_UTIL_CONSTRAINTS = {
|
|
@@ -20070,12 +21018,11 @@ class AuroDateUtilitiesBase {
|
|
|
20070
21018
|
/* eslint-disable no-magic-numbers */
|
|
20071
21019
|
|
|
20072
21020
|
class AuroDateUtilities extends AuroDateUtilitiesBase {
|
|
20073
|
-
|
|
20074
21021
|
/**
|
|
20075
21022
|
* Returns the current century.
|
|
20076
21023
|
* @returns {String} The current century.
|
|
20077
21024
|
*/
|
|
20078
|
-
getCentury
|
|
21025
|
+
getCentury() {
|
|
20079
21026
|
return String(new Date().getFullYear()).slice(0, 2);
|
|
20080
21027
|
}
|
|
20081
21028
|
|
|
@@ -20084,14 +21031,12 @@ class AuroDateUtilities extends AuroDateUtilitiesBase {
|
|
|
20084
21031
|
* @param {String} year - The year to convert to four digits.
|
|
20085
21032
|
* @returns {String} The four digit year.
|
|
20086
21033
|
*/
|
|
20087
|
-
getFourDigitYear
|
|
20088
|
-
|
|
21034
|
+
getFourDigitYear(year) {
|
|
20089
21035
|
const strYear = String(year).trim();
|
|
20090
21036
|
return strYear.length <= 2 ? this.getCentury() + strYear : strYear;
|
|
20091
21037
|
}
|
|
20092
21038
|
|
|
20093
21039
|
constructor() {
|
|
20094
|
-
|
|
20095
21040
|
super();
|
|
20096
21041
|
|
|
20097
21042
|
/**
|
|
@@ -20100,7 +21045,8 @@ class AuroDateUtilities extends AuroDateUtilitiesBase {
|
|
|
20100
21045
|
* @param {Object} date2 - Second date to compare.
|
|
20101
21046
|
* @returns {Boolean} Returns true if the dates match.
|
|
20102
21047
|
*/
|
|
20103
|
-
this.datesMatch = (date1, date2) =>
|
|
21048
|
+
this.datesMatch = (date1, date2) =>
|
|
21049
|
+
new Date(date1).getTime() === new Date(date2).getTime();
|
|
20104
21050
|
|
|
20105
21051
|
/**
|
|
20106
21052
|
* Returns true if value passed in is a valid date.
|
|
@@ -20109,53 +21055,41 @@ class AuroDateUtilities extends AuroDateUtilitiesBase {
|
|
|
20109
21055
|
* @returns {Boolean}
|
|
20110
21056
|
*/
|
|
20111
21057
|
this.validDateStr = (date, format) => {
|
|
20112
|
-
|
|
20113
21058
|
// The length we expect the date string to be
|
|
20114
|
-
const dateStrLength = format
|
|
21059
|
+
const dateStrLength = format?.length || 0;
|
|
20115
21060
|
|
|
20116
21061
|
// Guard Clause: Date and format are defined
|
|
20117
21062
|
if (typeof date === "undefined" || typeof format === "undefined") {
|
|
20118
|
-
throw new Error(
|
|
21063
|
+
throw new Error(
|
|
21064
|
+
"AuroDatepickerUtilities | validateDateStr: Date and format are required",
|
|
21065
|
+
);
|
|
20119
21066
|
}
|
|
20120
21067
|
|
|
20121
21068
|
// Guard Clause: Date should be of type string
|
|
20122
21069
|
if (typeof date !== "string") {
|
|
20123
|
-
throw new Error(
|
|
21070
|
+
throw new Error(
|
|
21071
|
+
"AuroDatepickerUtilities | validateDateStr: Date must be a string",
|
|
21072
|
+
);
|
|
20124
21073
|
}
|
|
20125
21074
|
|
|
20126
21075
|
// Guard Clause: Format should be of type string
|
|
20127
21076
|
if (typeof format !== "string") {
|
|
20128
|
-
throw new Error(
|
|
21077
|
+
throw new Error(
|
|
21078
|
+
"AuroDatepickerUtilities | validateDateStr: Format must be a string",
|
|
21079
|
+
);
|
|
20129
21080
|
}
|
|
20130
21081
|
|
|
20131
21082
|
// Guard Clause: Length is what we expect it to be
|
|
20132
21083
|
if (date.length !== dateStrLength) {
|
|
20133
21084
|
return false;
|
|
20134
21085
|
}
|
|
20135
|
-
// Get a formatted date string and parse it
|
|
20136
|
-
const dateParts = dateFormatter.parseDate(date, format);
|
|
20137
|
-
|
|
20138
|
-
// Guard Clause: Date parse succeeded
|
|
20139
|
-
if (!dateParts) {
|
|
20140
|
-
return false;
|
|
20141
|
-
}
|
|
20142
21086
|
|
|
20143
|
-
//
|
|
20144
|
-
|
|
20145
|
-
|
|
20146
|
-
|
|
20147
|
-
const dateObj = new Date(this.getFourDigitYear(dateParts.year), dateParts.month - 1, dateParts.day || 1);
|
|
20148
|
-
|
|
20149
|
-
// Get the date string of the date object we created from the string date
|
|
20150
|
-
const actualDateStr = dateFormatter.getDateAsString(dateObj, "en-US");
|
|
20151
|
-
|
|
20152
|
-
// Guard Clause: Generated date matches date string input
|
|
20153
|
-
if (expectedDateStr !== actualDateStr) {
|
|
21087
|
+
// Get a formatted date string and parse and validate it
|
|
21088
|
+
try {
|
|
21089
|
+
return Boolean(dateFormatter.parseDate(date, format));
|
|
21090
|
+
} catch (error) {
|
|
20154
21091
|
return false;
|
|
20155
21092
|
}
|
|
20156
|
-
|
|
20157
|
-
// If we passed all other checks, we can assume the date is valid
|
|
20158
|
-
return true;
|
|
20159
21093
|
};
|
|
20160
21094
|
|
|
20161
21095
|
/**
|
|
@@ -20165,10 +21099,11 @@ class AuroDateUtilities extends AuroDateUtilitiesBase {
|
|
|
20165
21099
|
* @returns {boolean}
|
|
20166
21100
|
*/
|
|
20167
21101
|
this.dateAndFormatMatch = (value, format) => {
|
|
20168
|
-
|
|
20169
21102
|
// Ensure we have both values we need to do the comparison
|
|
20170
21103
|
if (!value || !format) {
|
|
20171
|
-
throw new Error(
|
|
21104
|
+
throw new Error(
|
|
21105
|
+
"AuroFormValidation | dateFormatMatch: value and format are required",
|
|
21106
|
+
);
|
|
20172
21107
|
}
|
|
20173
21108
|
|
|
20174
21109
|
// If the lengths are different, they cannot match
|
|
@@ -20177,11 +21112,10 @@ class AuroDateUtilities extends AuroDateUtilitiesBase {
|
|
|
20177
21112
|
}
|
|
20178
21113
|
|
|
20179
21114
|
// Get the parts of the date
|
|
20180
|
-
const dateParts = dateFormatter.
|
|
21115
|
+
const dateParts = dateFormatter.getDateParts(value, format);
|
|
20181
21116
|
|
|
20182
21117
|
// Validator for day
|
|
20183
21118
|
const dayValueIsValid = (day) => {
|
|
20184
|
-
|
|
20185
21119
|
// Guard clause: if there is no day in the dateParts, we can ignore this check.
|
|
20186
21120
|
if (!dateParts.day) {
|
|
20187
21121
|
return true;
|
|
@@ -20197,7 +21131,9 @@ class AuroDateUtilities extends AuroDateUtilitiesBase {
|
|
|
20197
21131
|
|
|
20198
21132
|
// Guard clause: ensure day is a valid integer
|
|
20199
21133
|
if (Number.isNaN(numDay)) {
|
|
20200
|
-
throw new Error(
|
|
21134
|
+
throw new Error(
|
|
21135
|
+
"AuroDatepickerUtilities | dayValueIsValid: Unable to parse day value integer",
|
|
21136
|
+
);
|
|
20201
21137
|
}
|
|
20202
21138
|
|
|
20203
21139
|
// Guard clause: ensure day is within the valid range
|
|
@@ -20211,6 +21147,10 @@ class AuroDateUtilities extends AuroDateUtilitiesBase {
|
|
|
20211
21147
|
|
|
20212
21148
|
// Validator for month
|
|
20213
21149
|
const monthValueIsValid = (month) => {
|
|
21150
|
+
// Guard clause: if there is no month in the dateParts, we can ignore this check.
|
|
21151
|
+
if (!dateParts.month) {
|
|
21152
|
+
return true;
|
|
21153
|
+
}
|
|
20214
21154
|
|
|
20215
21155
|
// Guard clause: ensure month exists.
|
|
20216
21156
|
if (!month) {
|
|
@@ -20222,7 +21162,9 @@ class AuroDateUtilities extends AuroDateUtilitiesBase {
|
|
|
20222
21162
|
|
|
20223
21163
|
// Guard clause: ensure month is a valid integer
|
|
20224
21164
|
if (Number.isNaN(numMonth)) {
|
|
20225
|
-
throw new Error(
|
|
21165
|
+
throw new Error(
|
|
21166
|
+
"AuroDatepickerUtilities | monthValueIsValid: Unable to parse month value integer",
|
|
21167
|
+
);
|
|
20226
21168
|
}
|
|
20227
21169
|
|
|
20228
21170
|
// Guard clause: ensure month is within the valid range
|
|
@@ -20236,6 +21178,10 @@ class AuroDateUtilities extends AuroDateUtilitiesBase {
|
|
|
20236
21178
|
|
|
20237
21179
|
// Validator for year
|
|
20238
21180
|
const yearIsValid = (_year) => {
|
|
21181
|
+
// Guard clause: if there is no year in the dateParts, we can ignore this check.
|
|
21182
|
+
if (!dateParts.year) {
|
|
21183
|
+
return true;
|
|
21184
|
+
}
|
|
20239
21185
|
|
|
20240
21186
|
// Guard clause: ensure year exists.
|
|
20241
21187
|
if (!_year) {
|
|
@@ -20250,7 +21196,9 @@ class AuroDateUtilities extends AuroDateUtilitiesBase {
|
|
|
20250
21196
|
|
|
20251
21197
|
// Guard clause: ensure year is a valid integer
|
|
20252
21198
|
if (Number.isNaN(numYear)) {
|
|
20253
|
-
throw new Error(
|
|
21199
|
+
throw new Error(
|
|
21200
|
+
"AuroDatepickerUtilities | yearValueIsValid: Unable to parse year value integer",
|
|
21201
|
+
);
|
|
20254
21202
|
}
|
|
20255
21203
|
|
|
20256
21204
|
// Guard clause: ensure year is within the valid range
|
|
@@ -20266,7 +21214,7 @@ class AuroDateUtilities extends AuroDateUtilitiesBase {
|
|
|
20266
21214
|
const checks = [
|
|
20267
21215
|
monthValueIsValid(dateParts.month),
|
|
20268
21216
|
dayValueIsValid(dateParts.day),
|
|
20269
|
-
yearIsValid(dateParts.year)
|
|
21217
|
+
yearIsValid(dateParts.year),
|
|
20270
21218
|
];
|
|
20271
21219
|
|
|
20272
21220
|
// If any of the checks failed, the date format does not match and the result is invalid
|
|
@@ -20300,10 +21248,7 @@ const {
|
|
|
20300
21248
|
} = dateUtilities;
|
|
20301
21249
|
|
|
20302
21250
|
const {
|
|
20303
|
-
toNorthAmericanFormat
|
|
20304
|
-
parseDate,
|
|
20305
|
-
getDateAsString
|
|
20306
|
-
} = dateFormatter;
|
|
21251
|
+
toNorthAmericanFormat} = dateFormatter;
|
|
20307
21252
|
|
|
20308
21253
|
// Copyright (c) Alaska Air. All right reserved. Licensed under the Apache-2.0 license
|
|
20309
21254
|
// See LICENSE in the project root for license information.
|
|
@@ -22518,7 +23463,7 @@ let AuroHelpText$1 = class AuroHelpText extends i$1 {
|
|
|
22518
23463
|
}
|
|
22519
23464
|
};
|
|
22520
23465
|
|
|
22521
|
-
var formkitVersion = '
|
|
23466
|
+
var formkitVersion = '202606030033';
|
|
22522
23467
|
|
|
22523
23468
|
// Copyright (c) 2025 Alaska Airlines. All right reserved. Licensed under the Apache-2.0 license
|
|
22524
23469
|
// See LICENSE in the project root for license information.
|
|
@@ -23874,6 +24819,7 @@ class AuroDatePicker extends AuroElement {
|
|
|
23874
24819
|
delegatesFocus: true,
|
|
23875
24820
|
};
|
|
23876
24821
|
}
|
|
24822
|
+
|
|
23877
24823
|
constructor() {
|
|
23878
24824
|
super();
|
|
23879
24825
|
|
|
@@ -24041,7 +24987,7 @@ class AuroDatePicker extends AuroElement {
|
|
|
24041
24987
|
|
|
24042
24988
|
/**
|
|
24043
24989
|
* Defines whether the component will be on lighter or darker backgrounds.
|
|
24044
|
-
* @
|
|
24990
|
+
* @type {'default' | 'inverse'}
|
|
24045
24991
|
* @default 'default'
|
|
24046
24992
|
*/
|
|
24047
24993
|
appearance: {
|
|
@@ -24058,6 +25004,22 @@ class AuroDatePicker extends AuroElement {
|
|
|
24058
25004
|
reflect: true
|
|
24059
25005
|
},
|
|
24060
25006
|
|
|
25007
|
+
/**
|
|
25008
|
+
* Array of dates that cannot be selected. Dates should be in ISO format (YYYY-MM-DD).
|
|
25009
|
+
*/
|
|
25010
|
+
blackoutDates: {
|
|
25011
|
+
type: Array,
|
|
25012
|
+
reflect: true
|
|
25013
|
+
},
|
|
25014
|
+
|
|
25015
|
+
/**
|
|
25016
|
+
* Label announced for blackout (disabled but in-range) date cells.
|
|
25017
|
+
*/
|
|
25018
|
+
blackoutLabel: {
|
|
25019
|
+
type: String,
|
|
25020
|
+
reflect: true
|
|
25021
|
+
},
|
|
25022
|
+
|
|
24061
25023
|
/**
|
|
24062
25024
|
* The last date that may be displayed in the calendar.
|
|
24063
25025
|
*/
|
|
@@ -24113,27 +25075,6 @@ class AuroDatePicker extends AuroElement {
|
|
|
24113
25075
|
reflect: true
|
|
24114
25076
|
},
|
|
24115
25077
|
|
|
24116
|
-
hasFocus: {
|
|
24117
|
-
type: Boolean,
|
|
24118
|
-
reflect: false,
|
|
24119
|
-
},
|
|
24120
|
-
|
|
24121
|
-
/**
|
|
24122
|
-
* @private
|
|
24123
|
-
*/
|
|
24124
|
-
hasValue: {
|
|
24125
|
-
type: Boolean,
|
|
24126
|
-
reflect: false,
|
|
24127
|
-
},
|
|
24128
|
-
|
|
24129
|
-
/**
|
|
24130
|
-
* @private
|
|
24131
|
-
*/
|
|
24132
|
-
hasAllValues: {
|
|
24133
|
-
type: Boolean,
|
|
24134
|
-
reflect: false
|
|
24135
|
-
},
|
|
24136
|
-
|
|
24137
25078
|
/**
|
|
24138
25079
|
* Specifies the date format. The default is `mm/dd/yyyy`.
|
|
24139
25080
|
*/
|
|
@@ -24155,6 +25096,27 @@ class AuroDatePicker extends AuroElement {
|
|
|
24155
25096
|
reflect: true
|
|
24156
25097
|
},
|
|
24157
25098
|
|
|
25099
|
+
/**
|
|
25100
|
+
* @private
|
|
25101
|
+
*/
|
|
25102
|
+
hasAllValues: {
|
|
25103
|
+
type: Boolean,
|
|
25104
|
+
reflect: false
|
|
25105
|
+
},
|
|
25106
|
+
|
|
25107
|
+
hasFocus: {
|
|
25108
|
+
type: Boolean,
|
|
25109
|
+
reflect: false,
|
|
25110
|
+
},
|
|
25111
|
+
|
|
25112
|
+
/**
|
|
25113
|
+
* @private
|
|
25114
|
+
*/
|
|
25115
|
+
hasValue: {
|
|
25116
|
+
type: Boolean,
|
|
25117
|
+
reflect: false,
|
|
25118
|
+
},
|
|
25119
|
+
|
|
24158
25120
|
/** Exposes inputmode attribute for input. */
|
|
24159
25121
|
inputmode: {
|
|
24160
25122
|
type: String,
|
|
@@ -24197,6 +25159,13 @@ class AuroDatePicker extends AuroElement {
|
|
|
24197
25159
|
reflect: true
|
|
24198
25160
|
},
|
|
24199
25161
|
|
|
25162
|
+
/**
|
|
25163
|
+
* @private
|
|
25164
|
+
*/
|
|
25165
|
+
monthFirst: {
|
|
25166
|
+
type: Boolean
|
|
25167
|
+
},
|
|
25168
|
+
|
|
24200
25169
|
/**
|
|
24201
25170
|
* Names of all 12 months to render in the calendar, used for localization of date string in mobile layout.
|
|
24202
25171
|
*/
|
|
@@ -24205,25 +25174,26 @@ class AuroDatePicker extends AuroElement {
|
|
|
24205
25174
|
},
|
|
24206
25175
|
|
|
24207
25176
|
/**
|
|
24208
|
-
*
|
|
25177
|
+
* Accessible label for the next month navigation button.
|
|
24209
25178
|
*/
|
|
24210
|
-
|
|
24211
|
-
type:
|
|
25179
|
+
navLabelNextMonth: {
|
|
25180
|
+
type: String,
|
|
25181
|
+
reflect: true
|
|
24212
25182
|
},
|
|
24213
25183
|
|
|
24214
25184
|
/**
|
|
24215
|
-
*
|
|
24216
|
-
* when there isn't enough space in the specified `placement`.
|
|
25185
|
+
* Accessible label for the previous month navigation button.
|
|
24217
25186
|
*/
|
|
24218
|
-
|
|
24219
|
-
type:
|
|
25187
|
+
navLabelPrevMonth: {
|
|
25188
|
+
type: String,
|
|
24220
25189
|
reflect: true
|
|
24221
25190
|
},
|
|
24222
25191
|
|
|
24223
25192
|
/**
|
|
24224
|
-
* If declared, the
|
|
25193
|
+
* If declared, the bib will NOT flip to an alternate position
|
|
25194
|
+
* when there isn't enough space in the specified `placement`.
|
|
24225
25195
|
*/
|
|
24226
|
-
|
|
25196
|
+
noFlip: {
|
|
24227
25197
|
type: Boolean,
|
|
24228
25198
|
reflect: true
|
|
24229
25199
|
},
|
|
@@ -24290,17 +25260,9 @@ class AuroDatePicker extends AuroElement {
|
|
|
24290
25260
|
},
|
|
24291
25261
|
|
|
24292
25262
|
/**
|
|
24293
|
-
* Label announced for the range start
|
|
24294
|
-
*/
|
|
24295
|
-
rangeLabelStart: {
|
|
24296
|
-
type: String,
|
|
24297
|
-
reflect: true
|
|
24298
|
-
},
|
|
24299
|
-
|
|
24300
|
-
/**
|
|
24301
|
-
* Label announced for the range end date cell.
|
|
25263
|
+
* Label announced for cells after the range (or after start when no end is selected).
|
|
24302
25264
|
*/
|
|
24303
|
-
|
|
25265
|
+
rangeLabelAfterRange: {
|
|
24304
25266
|
type: String,
|
|
24305
25267
|
reflect: true
|
|
24306
25268
|
},
|
|
@@ -24314,49 +25276,25 @@ class AuroDatePicker extends AuroElement {
|
|
|
24314
25276
|
},
|
|
24315
25277
|
|
|
24316
25278
|
/**
|
|
24317
|
-
* Label announced for
|
|
24318
|
-
*/
|
|
24319
|
-
rangeLabelInRange: {
|
|
24320
|
-
type: String,
|
|
24321
|
-
reflect: true
|
|
24322
|
-
},
|
|
24323
|
-
|
|
24324
|
-
/**
|
|
24325
|
-
* Label announced for cells after the range (or after start when no end is selected).
|
|
24326
|
-
*/
|
|
24327
|
-
rangeLabelAfterRange: {
|
|
24328
|
-
type: String,
|
|
24329
|
-
reflect: true
|
|
24330
|
-
},
|
|
24331
|
-
|
|
24332
|
-
/**
|
|
24333
|
-
* Array of dates that cannot be selected. Dates should be in ISO format (YYYY-MM-DD).
|
|
24334
|
-
*/
|
|
24335
|
-
blackoutDates: {
|
|
24336
|
-
type: Array,
|
|
24337
|
-
reflect: true
|
|
24338
|
-
},
|
|
24339
|
-
|
|
24340
|
-
/**
|
|
24341
|
-
* Label announced for blackout (disabled but in-range) date cells.
|
|
25279
|
+
* Label announced for the range end date cell.
|
|
24342
25280
|
*/
|
|
24343
|
-
|
|
25281
|
+
rangeLabelEnd: {
|
|
24344
25282
|
type: String,
|
|
24345
25283
|
reflect: true
|
|
24346
25284
|
},
|
|
24347
25285
|
|
|
24348
25286
|
/**
|
|
24349
|
-
*
|
|
25287
|
+
* Label announced for cells within the selected range.
|
|
24350
25288
|
*/
|
|
24351
|
-
|
|
25289
|
+
rangeLabelInRange: {
|
|
24352
25290
|
type: String,
|
|
24353
25291
|
reflect: true
|
|
24354
25292
|
},
|
|
24355
25293
|
|
|
24356
25294
|
/**
|
|
24357
|
-
*
|
|
25295
|
+
* Label announced for the range start date cell.
|
|
24358
25296
|
*/
|
|
24359
|
-
|
|
25297
|
+
rangeLabelStart: {
|
|
24360
25298
|
type: String,
|
|
24361
25299
|
reflect: true
|
|
24362
25300
|
},
|
|
@@ -24414,6 +25352,14 @@ class AuroDatePicker extends AuroElement {
|
|
|
24414
25352
|
type: String
|
|
24415
25353
|
},
|
|
24416
25354
|
|
|
25355
|
+
/**
|
|
25356
|
+
* If declared, the dropdown will shift its position to avoid being cut off by the viewport.
|
|
25357
|
+
*/
|
|
25358
|
+
shift: {
|
|
25359
|
+
type: Boolean,
|
|
25360
|
+
reflect: true
|
|
25361
|
+
},
|
|
25362
|
+
|
|
24417
25363
|
/**
|
|
24418
25364
|
* Set true to make datepicker stacked style.
|
|
24419
25365
|
*/
|
|
@@ -24422,6 +25368,16 @@ class AuroDatePicker extends AuroElement {
|
|
|
24422
25368
|
reflect: true
|
|
24423
25369
|
},
|
|
24424
25370
|
|
|
25371
|
+
/**
|
|
25372
|
+
* Indicates whether the datepicker is in a dirty state (has been interacted with).
|
|
25373
|
+
* @private
|
|
25374
|
+
*/
|
|
25375
|
+
touched: {
|
|
25376
|
+
type: Boolean,
|
|
25377
|
+
reflect: true,
|
|
25378
|
+
attribute: false
|
|
25379
|
+
},
|
|
25380
|
+
|
|
24425
25381
|
/**
|
|
24426
25382
|
* Specifies the `validityState` this element is in.
|
|
24427
25383
|
*/
|
|
@@ -24442,16 +25398,6 @@ class AuroDatePicker extends AuroElement {
|
|
|
24442
25398
|
*/
|
|
24443
25399
|
valueEnd: {
|
|
24444
25400
|
type: String
|
|
24445
|
-
},
|
|
24446
|
-
|
|
24447
|
-
/**
|
|
24448
|
-
* Indicates whether the datepicker is in a dirty state (has been interacted with).
|
|
24449
|
-
* @private
|
|
24450
|
-
*/
|
|
24451
|
-
touched: {
|
|
24452
|
-
type: Boolean,
|
|
24453
|
-
reflect: true,
|
|
24454
|
-
attribute: false
|
|
24455
25401
|
}
|
|
24456
25402
|
};
|
|
24457
25403
|
}
|
|
@@ -24560,8 +25506,9 @@ class AuroDatePicker extends AuroElement {
|
|
|
24560
25506
|
}
|
|
24561
25507
|
|
|
24562
25508
|
/**
|
|
24563
|
-
* @private
|
|
24564
25509
|
* Common display value wrapper classes.
|
|
25510
|
+
* @private
|
|
25511
|
+
* @returns {Object} Class map for Lit's classMap directive.
|
|
24565
25512
|
*/
|
|
24566
25513
|
get commonDisplayValueWrapperClasses() {
|
|
24567
25514
|
return {
|
|
@@ -24729,7 +25676,7 @@ class AuroDatePicker extends AuroElement {
|
|
|
24729
25676
|
}
|
|
24730
25677
|
|
|
24731
25678
|
// Compute and mark the active cell
|
|
24732
|
-
if (this.calendar.activeCellDate
|
|
25679
|
+
if (this.calendar.activeCellDate === null || this.calendar.activeCellDate === undefined) {
|
|
24733
25680
|
this.calendar.activeCellDate = this.calendar.computeActiveDate();
|
|
24734
25681
|
}
|
|
24735
25682
|
if (this.calendar.activeCellDate !== undefined) {
|
|
@@ -24738,29 +25685,37 @@ class AuroDatePicker extends AuroElement {
|
|
|
24738
25685
|
|
|
24739
25686
|
// If no cell matched (e.g. centralDate month differs from the rendered
|
|
24740
25687
|
// range on mobile), fall back to the first rendered enabled cell.
|
|
24741
|
-
let activeCell = allCells.find(cell => cell.active);
|
|
25688
|
+
let activeCell = allCells.find((cell) => cell.active);
|
|
24742
25689
|
if (!activeCell && allCells.length) {
|
|
24743
|
-
const fallback = allCells
|
|
25690
|
+
const [fallback] = allCells;
|
|
24744
25691
|
if (fallback.day) {
|
|
24745
25692
|
this.calendar.activeCellDate = fallback.day.date;
|
|
24746
25693
|
this.calendar.setActiveCell(this.calendar.activeCellDate);
|
|
24747
|
-
activeCell = allCells.find(cell => cell.active);
|
|
25694
|
+
activeCell = allCells.find((cell) => cell.active);
|
|
24748
25695
|
}
|
|
24749
25696
|
}
|
|
24750
25697
|
|
|
24751
|
-
//
|
|
24752
|
-
//
|
|
25698
|
+
// Focus the calendar grid wrapper (aria-activedescendant handles
|
|
25699
|
+
// the SR announcement for the active cell).
|
|
24753
25700
|
if (activeCell) {
|
|
24754
|
-
|
|
24755
|
-
|
|
24756
|
-
|
|
24757
|
-
|
|
24758
|
-
|
|
24759
|
-
|
|
24760
|
-
|
|
24761
|
-
|
|
24762
|
-
|
|
24763
|
-
|
|
25701
|
+
this.calendar.focusActiveCell();
|
|
25702
|
+
|
|
25703
|
+
// Announce the initial active cell via the live region.
|
|
25704
|
+
// Delay the announcement so it arrives after VoiceOver finishes
|
|
25705
|
+
// speaking the focus-change announcement for the grid wrapper.
|
|
25706
|
+
// Without this delay, VoiceOver drops the live region update
|
|
25707
|
+
// because it's already mid-announcement from the focus move.
|
|
25708
|
+
const announcement = this.calendar.buildFocusAnnouncement(activeCell.day.date);
|
|
25709
|
+
setTimeout(() => {
|
|
25710
|
+
this.calendar.announceSelection(announcement);
|
|
25711
|
+
}, 500);
|
|
25712
|
+
|
|
25713
|
+
// On mobile fullscreen, scroll the month list so the active cell's
|
|
25714
|
+
// month is visible. Without this, the list stays scrolled to the
|
|
25715
|
+
// calendarStartDate month which may be far from the active cell.
|
|
25716
|
+
if (this.dropdown.isBibFullscreen) {
|
|
25717
|
+
this.calendar.scrollToActiveCell();
|
|
25718
|
+
}
|
|
24764
25719
|
} else if (attempts < MAX_ATTEMPTS) {
|
|
24765
25720
|
requestAnimationFrame(tryFocus);
|
|
24766
25721
|
}
|
|
@@ -24910,14 +25865,35 @@ class AuroDatePicker extends AuroElement {
|
|
|
24910
25865
|
if (bibEl && this.dropdown.isPopoverVisible) {
|
|
24911
25866
|
bibEl.close();
|
|
24912
25867
|
bibEl.open(true);
|
|
25868
|
+
}
|
|
25869
|
+
|
|
25870
|
+
// Re-render the calendar with the new fullscreen layout,
|
|
25871
|
+
// then restore focus after the re-render completes.
|
|
25872
|
+
this.calendar.isFullscreen = true;
|
|
25873
|
+
this.calendar.updateComplete.then(() => {
|
|
24913
25874
|
doubleRaf(() => {
|
|
24914
25875
|
this.focusActiveCellWhenReady();
|
|
24915
25876
|
});
|
|
24916
|
-
}
|
|
25877
|
+
});
|
|
24917
25878
|
});
|
|
24918
25879
|
} else if (!this.dropdown.isBibFullscreen) {
|
|
24919
|
-
// Switching from fullscreen to floating — restore trigger accessibility
|
|
24920
|
-
|
|
25880
|
+
// Switching from fullscreen to floating — only restore trigger accessibility
|
|
25881
|
+
// when the bib is closed or the desktop layout is not a modal. A desktopModal
|
|
25882
|
+
// dropdown keeps the trigger inert while open, matching the desktop-open path.
|
|
25883
|
+
if (!this.dropdown.isPopoverVisible || !this.dropdown.desktopModal) {
|
|
25884
|
+
this.dropdown.trigger.inert = false;
|
|
25885
|
+
}
|
|
25886
|
+
|
|
25887
|
+
// Re-render the calendar with the desktop layout,
|
|
25888
|
+
// then restore focus after the re-render completes.
|
|
25889
|
+
this.dropdown.updateComplete.then(() => {
|
|
25890
|
+
this.calendar.isFullscreen = false;
|
|
25891
|
+
this.calendar.updateComplete.then(() => {
|
|
25892
|
+
doubleRaf(() => {
|
|
25893
|
+
this.focusActiveCellWhenReady();
|
|
25894
|
+
});
|
|
25895
|
+
});
|
|
25896
|
+
});
|
|
24921
25897
|
}
|
|
24922
25898
|
});
|
|
24923
25899
|
}
|
|
@@ -25159,12 +26135,14 @@ class AuroDatePicker extends AuroElement {
|
|
|
25159
26135
|
}
|
|
25160
26136
|
|
|
25161
26137
|
const formatted = this.util.toNorthAmericanFormat(dateStr, this.format);
|
|
25162
|
-
if (!this.util.validDateStr(dateStr, this.format))
|
|
26138
|
+
if (!this.util.validDateStr(dateStr, this.format)) {
|
|
26139
|
+
return false;
|
|
26140
|
+
}
|
|
25163
26141
|
|
|
25164
|
-
const
|
|
25165
|
-
const yyyy =
|
|
25166
|
-
const mm = String(
|
|
25167
|
-
const dd = String(
|
|
26142
|
+
const dt = new Date(formatted);
|
|
26143
|
+
const yyyy = dt.getFullYear();
|
|
26144
|
+
const mm = String(dt.getMonth() + 1).padStart(2, '0');
|
|
26145
|
+
const dd = String(dt.getDate()).padStart(2, '0');
|
|
25168
26146
|
return this.blackoutDates.includes(`${yyyy}-${mm}-${dd}`);
|
|
25169
26147
|
}
|
|
25170
26148
|
|
|
@@ -25182,7 +26160,7 @@ class AuroDatePicker extends AuroElement {
|
|
|
25182
26160
|
|
|
25183
26161
|
// After standard validation, check blackout dates for typed input
|
|
25184
26162
|
if (this.validity !== 'customError') {
|
|
25185
|
-
if (this.isBlackoutDate(this.value) || (this.range && this.isBlackoutDate(this.valueEnd))) {
|
|
26163
|
+
if (this.isBlackoutDate(this.value) || (this.range && this.isBlackoutDate(this.valueEnd))) { // eslint-disable-line no-extra-parens
|
|
25186
26164
|
const msg = this.setCustomValidityCustomError || 'Selected date is unavailable';
|
|
25187
26165
|
this.validity = 'customError';
|
|
25188
26166
|
this.errorMessage = msg;
|
|
@@ -25228,7 +26206,13 @@ class AuroDatePicker extends AuroElement {
|
|
|
25228
26206
|
// backward compatibility for old format of referenceDates which is a stringified array with - instead of / as separator, e.g. ["10-22-2025","10-23-2025"]
|
|
25229
26207
|
const stringfiedDates = JSON.stringify(this.referenceDates);
|
|
25230
26208
|
if (stringfiedDates.includes('-')) {
|
|
25231
|
-
this.referenceDates = this.referenceDates.map(date => date.replace(/-/gu, '/'
|
|
26209
|
+
this.referenceDates = this.referenceDates.map((date) => date.replace(/-/gu, '/'));
|
|
26210
|
+
}
|
|
26211
|
+
|
|
26212
|
+
// Force calendar cells to re-render with updated reference date state.
|
|
26213
|
+
if (this.calendar) {
|
|
26214
|
+
this.calendar.requestUpdate();
|
|
26215
|
+
this.dispatchEvent(new CustomEvent('auroDatePicker-newSlotContent'));
|
|
25232
26216
|
}
|
|
25233
26217
|
}
|
|
25234
26218
|
|
|
@@ -25817,7 +26801,7 @@ class AuroDatePicker extends AuroElement {
|
|
|
25817
26801
|
/**
|
|
25818
26802
|
* Handles click on the clear button.
|
|
25819
26803
|
* @private
|
|
25820
|
-
* @param {MouseEvent} event
|
|
26804
|
+
* @param {MouseEvent} event - The mouse event from the clear button click.
|
|
25821
26805
|
* @returns {void}
|
|
25822
26806
|
*/
|
|
25823
26807
|
handleClearClick(event) {
|