@aurodesignsystem-dev/auro-formkit 0.0.0-pr1483.2 → 0.0.0-pr1488.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (59) hide show
  1. package/components/checkbox/demo/customize.min.js +436 -14
  2. package/components/checkbox/demo/getting-started.min.js +436 -14
  3. package/components/checkbox/demo/index.min.js +436 -14
  4. package/components/checkbox/dist/index.js +436 -14
  5. package/components/checkbox/dist/registered.js +436 -14
  6. package/components/combobox/demo/customize.min.js +1482 -6618
  7. package/components/combobox/demo/getting-started.min.js +1482 -6618
  8. package/components/combobox/demo/index.min.js +1482 -6618
  9. package/components/combobox/demo/keyboard-behavior.md +68 -8
  10. package/components/combobox/dist/index.js +1489 -6625
  11. package/components/combobox/dist/registered.js +1489 -6625
  12. package/components/counter/demo/customize.min.js +437 -15
  13. package/components/counter/demo/index.min.js +437 -15
  14. package/components/counter/dist/index.js +436 -14
  15. package/components/counter/dist/registered.js +436 -14
  16. package/components/datepicker/demo/api.md +3 -10
  17. package/components/datepicker/demo/customize.md +6 -6
  18. package/components/datepicker/demo/index.md +4 -4
  19. package/components/datepicker/demo/index.min.js +2319 -7650
  20. package/components/datepicker/dist/index.js +2319 -7650
  21. package/components/datepicker/dist/registered.js +2319 -7650
  22. package/components/datepicker/dist/src/auro-calendar.d.ts +0 -6
  23. package/components/datepicker/dist/src/auro-datepicker.d.ts +11 -24
  24. package/components/datepicker/dist/src/utilities.d.ts +40 -14
  25. package/components/datepicker/dist/src/utilitiesCalendar.d.ts +1 -1
  26. package/components/dropdown/demo/customize.min.js +1 -1
  27. package/components/dropdown/demo/getting-started.min.js +1 -1
  28. package/components/dropdown/demo/index.min.js +1 -1
  29. package/components/dropdown/dist/index.js +1 -1
  30. package/components/dropdown/dist/registered.js +1 -1
  31. package/components/form/demo/customize.min.js +44181 -58516
  32. package/components/form/demo/getting-started.min.js +44181 -58516
  33. package/components/form/demo/index.min.js +44181 -58516
  34. package/components/form/demo/registerDemoDeps.min.js +44181 -58516
  35. package/components/input/demo/api.md +51 -57
  36. package/components/input/demo/customize.md +0 -160
  37. package/components/input/demo/customize.min.js +1011 -6565
  38. package/components/input/demo/getting-started.md +0 -11
  39. package/components/input/demo/getting-started.min.js +1010 -6564
  40. package/components/input/demo/index.md +3 -28
  41. package/components/input/demo/index.min.js +1010 -6564
  42. package/components/input/dist/auro-input.d.ts +6 -25
  43. package/components/input/dist/base-input.d.ts +69 -82
  44. package/components/input/dist/index.d.ts +1 -2
  45. package/components/input/dist/index.js +1003 -6599
  46. package/components/input/dist/registered.js +1010 -6564
  47. package/components/input/dist/utilities.d.ts +9 -68
  48. package/components/radio/demo/index.min.js +436 -14
  49. package/components/radio/dist/index.js +436 -14
  50. package/components/radio/dist/registered.js +436 -14
  51. package/components/select/demo/customize.min.js +455 -31
  52. package/components/select/demo/getting-started.min.js +455 -31
  53. package/components/select/demo/index.min.js +455 -31
  54. package/components/select/demo/keyboard-behavior.md +54 -8
  55. package/components/select/dist/index.js +455 -31
  56. package/components/select/dist/registered.js +455 -31
  57. package/custom-elements.json +2117 -2625
  58. package/package.json +4 -4
  59. package/components/input/dist/auro-input-util.d.ts +0 -17
@@ -115,6 +115,415 @@ var shapeSizeCss$1 = css`.shape-classic-xl,.shape-classic-lg,.shape-classic-md,.
115
115
 
116
116
  var tokensCss$3 = css`:host(:not([ondark])),:host(:not([appearance=inverse])){--ds-auro-select-border-color: var(--ds-basic-color-border-bold, #585e67);--ds-auro-select-background-color: var(--ds-basic-color-surface-default, #ffffff);--ds-auro-select-label-text-color: var(--ds-basic-color-texticon-muted, #676767);--ds-auro-select-placeholder-text-color: var(--ds-basic-color-texticon-default, #2a2a2a);--ds-auro-select-text-color: var(--ds-basic-color-texticon-default, #2a2a2a);--ds-auro-select-error-icon-color: var(--ds-basic-color-status-error, #e31f26);--ds-auro-select-outline-color: transparent}:host([ondark]),:host([appearance=inverse]){--ds-auro-select-border-color: var(--ds-basic-color-border-inverse, #ffffff);--ds-auro-select-background-color: var(--ds-advanced-color-shared-background-inverse, rgba(255, 255, 255, 0.15));--ds-auro-select-label-text-color: var(--ds-basic-color-texticon-inverse-muted, #ccd2db);--ds-auro-select-placeholder-text-color: var(--ds-basic-color-texticon-inverse, #ffffff);--ds-auro-select-text-color: var(--ds-basic-color-texticon-inverse, #ffffff);--ds-auro-select-error-icon-color: var(--ds-advanced-color-state-error-inverse, #f9a4a8);--ds-auro-select-outline-color: transparent}`;
117
117
 
118
+ class DateFormatter {
119
+
120
+ constructor() {
121
+
122
+ /**
123
+ * @description Parses a date string into its components.
124
+ * @param {string} dateStr - Date string to parse.
125
+ * @param {string} format - Date format to parse.
126
+ * @returns {Object<key["month" | "day" | "year"]: number>|undefined}
127
+ */
128
+ this.parseDate = (dateStr, format = 'mm/dd/yyyy') => {
129
+
130
+ // Guard Clause: Date string is defined
131
+ if (!dateStr) {
132
+ return undefined;
133
+ }
134
+
135
+ // Assume the separator is a "/" a defined in our code base
136
+ const separator = '/';
137
+
138
+ // Get the parts of the date and format
139
+ const valueParts = dateStr.split(separator);
140
+ const formatParts = format.split(separator);
141
+
142
+ // Check if the value and format have the correct number of parts
143
+ if (valueParts.length !== formatParts.length) {
144
+ throw new Error('AuroDatepickerUtilities | parseDate: Date string and format length do not match');
145
+ }
146
+
147
+ // Holds the result to be returned
148
+ const result = formatParts.reduce((acc, part, index) => {
149
+ const value = valueParts[index];
150
+
151
+ if ((/m/iu).test(part)) {
152
+ acc.month = value;
153
+ } else if ((/d/iu).test(part)) {
154
+ acc.day = value;
155
+ } else if ((/y/iu).test(part)) {
156
+ acc.year = value;
157
+ }
158
+
159
+ return acc;
160
+ }, {});
161
+
162
+ // If we found all the parts, return the result
163
+ if (result.month && result.year) {
164
+ return result;
165
+ }
166
+
167
+ // Throw an error to let the dev know we were unable to parse the date string
168
+ throw new Error('AuroDatepickerUtilities | parseDate: Unable to parse date string');
169
+ };
170
+
171
+ /**
172
+ * Convert a date object to string format.
173
+ * @param {Object} date - Date to convert to string.
174
+ * @param {String} locale - Optional locale to use for the date string. Defaults to user's locale.
175
+ * @returns {String} Returns the date as a string.
176
+ */
177
+ this.getDateAsString = (date, locale = undefined) => date.toLocaleDateString(locale, {
178
+ year: "numeric",
179
+ month: "2-digit",
180
+ day: "2-digit",
181
+ });
182
+
183
+ /**
184
+ * Converts a date string to a North American date format.
185
+ * @param {String} dateStr - Date to validate.
186
+ * @param {String} format - Date format to validate against.
187
+ * @returns {Boolean}
188
+ */
189
+ this.toNorthAmericanFormat = (dateStr, format) => {
190
+
191
+ if (format === 'mm/dd/yyyy') {
192
+ return dateStr;
193
+ }
194
+
195
+ const parsedDate = this.parseDate(dateStr, format);
196
+
197
+ if (!parsedDate) {
198
+ throw new Error('AuroDatepickerUtilities | toNorthAmericanFormat: Unable to parse date string');
199
+ }
200
+
201
+ const { month, day, year } = parsedDate;
202
+
203
+ const dateParts = [];
204
+ if (month) {
205
+ dateParts.push(month);
206
+ }
207
+
208
+ if (day) {
209
+ dateParts.push(day);
210
+ }
211
+
212
+ if (year) {
213
+ dateParts.push(year);
214
+ }
215
+
216
+ return dateParts.join('/');
217
+ };
218
+ }
219
+ }
220
+ const dateFormatter = new DateFormatter();
221
+
222
+ // filepath: dateConstraints.mjs
223
+ const DATE_UTIL_CONSTRAINTS = {
224
+ maxDay: 31,
225
+ maxMonth: 12,
226
+ maxYear: 2400,
227
+ minDay: 1,
228
+ minMonth: 1,
229
+ minYear: 1900,
230
+ };
231
+
232
+ class AuroDateUtilitiesBase {
233
+
234
+ /**
235
+ * @description The maximum day value allowed by the various utilities in this class.
236
+ * @readonly
237
+ * @type {Number}
238
+ */
239
+ get maxDay() {
240
+ return DATE_UTIL_CONSTRAINTS.maxDay;
241
+ }
242
+
243
+ /**
244
+ * @description The maximum month value allowed by the various utilities in this class.
245
+ * @readonly
246
+ * @type {Number}
247
+ */
248
+ get maxMonth() {
249
+ return DATE_UTIL_CONSTRAINTS.maxMonth;
250
+ }
251
+
252
+ /**
253
+ * @description The maximum year value allowed by the various utilities in this class.
254
+ * @readonly
255
+ * @type {Number}
256
+ */
257
+ get maxYear() {
258
+ return DATE_UTIL_CONSTRAINTS.maxYear;
259
+ }
260
+
261
+ /**
262
+ * @description The minimum day value allowed by the various utilities in this class.
263
+ * @readonly
264
+ * @type {Number}
265
+ */
266
+ get minDay() {
267
+ return DATE_UTIL_CONSTRAINTS.minDay;
268
+ }
269
+
270
+ /**
271
+ * @description The minimum month value allowed by the various utilities in this class.
272
+ * @readonly
273
+ * @type {Number}
274
+ */
275
+ get minMonth() {
276
+ return DATE_UTIL_CONSTRAINTS.minMonth;
277
+ }
278
+
279
+ /**
280
+ * @description The minimum year value allowed by the various utilities in this class.
281
+ * @readonly
282
+ * @type {Number}
283
+ */
284
+ get minYear() {
285
+ return DATE_UTIL_CONSTRAINTS.minYear;
286
+ }
287
+ }
288
+
289
+ /* eslint-disable no-magic-numbers */
290
+
291
+ class AuroDateUtilities extends AuroDateUtilitiesBase {
292
+
293
+ /**
294
+ * Returns the current century.
295
+ * @returns {String} The current century.
296
+ */
297
+ getCentury () {
298
+ return String(new Date().getFullYear()).slice(0, 2);
299
+ }
300
+
301
+ /**
302
+ * Returns a four digit year.
303
+ * @param {String} year - The year to convert to four digits.
304
+ * @returns {String} The four digit year.
305
+ */
306
+ getFourDigitYear (year) {
307
+
308
+ const strYear = String(year).trim();
309
+ return strYear.length <= 2 ? this.getCentury() + strYear : strYear;
310
+ }
311
+
312
+ constructor() {
313
+
314
+ super();
315
+
316
+ /**
317
+ * Compares two dates to see if they match.
318
+ * @param {Object} date1 - First date to compare.
319
+ * @param {Object} date2 - Second date to compare.
320
+ * @returns {Boolean} Returns true if the dates match.
321
+ */
322
+ this.datesMatch = (date1, date2) => new Date(date1).getTime() === new Date(date2).getTime();
323
+
324
+ /**
325
+ * Returns true if value passed in is a valid date.
326
+ * @param {String} date - Date to validate.
327
+ * @param {String} format - Date format to validate against.
328
+ * @returns {Boolean}
329
+ */
330
+ this.validDateStr = (date, format) => {
331
+
332
+ // The length we expect the date string to be
333
+ const dateStrLength = format.length;
334
+
335
+ // Guard Clause: Date and format are defined
336
+ if (typeof date === "undefined" || typeof format === "undefined") {
337
+ throw new Error('AuroDatepickerUtilities | validateDateStr: Date and format are required');
338
+ }
339
+
340
+ // Guard Clause: Date should be of type string
341
+ if (typeof date !== "string") {
342
+ throw new Error('AuroDatepickerUtilities | validateDateStr: Date must be a string');
343
+ }
344
+
345
+ // Guard Clause: Format should be of type string
346
+ if (typeof format !== "string") {
347
+ throw new Error('AuroDatepickerUtilities | validateDateStr: Format must be a string');
348
+ }
349
+
350
+ // Guard Clause: Length is what we expect it to be
351
+ if (date.length !== dateStrLength) {
352
+ return false;
353
+ }
354
+ // Get a formatted date string and parse it
355
+ const dateParts = dateFormatter.parseDate(date, format);
356
+
357
+ // Guard Clause: Date parse succeeded
358
+ if (!dateParts) {
359
+ return false;
360
+ }
361
+
362
+ // Create the expected date string based on the date parts
363
+ const expectedDateStr = `${dateParts.month}/${dateParts.day || "01"}/${this.getFourDigitYear(dateParts.year)}`;
364
+
365
+ // Generate a date object that we will extract a string date from to compare to the passed in date string
366
+ const dateObj = new Date(this.getFourDigitYear(dateParts.year), dateParts.month - 1, dateParts.day || 1);
367
+
368
+ // Get the date string of the date object we created from the string date
369
+ const actualDateStr = dateFormatter.getDateAsString(dateObj, "en-US");
370
+
371
+ // Guard Clause: Generated date matches date string input
372
+ if (expectedDateStr !== actualDateStr) {
373
+ return false;
374
+ }
375
+
376
+ // If we passed all other checks, we can assume the date is valid
377
+ return true;
378
+ };
379
+
380
+ /**
381
+ * Determines if a string date value matches the format provided.
382
+ * @param {string} value = The date string value.
383
+ * @param { string} format = The date format to match against.
384
+ * @returns {boolean}
385
+ */
386
+ this.dateAndFormatMatch = (value, format) => {
387
+
388
+ // Ensure we have both values we need to do the comparison
389
+ if (!value || !format) {
390
+ throw new Error('AuroFormValidation | dateFormatMatch: value and format are required');
391
+ }
392
+
393
+ // If the lengths are different, they cannot match
394
+ if (value.length !== format.length) {
395
+ return false;
396
+ }
397
+
398
+ // Get the parts of the date
399
+ const dateParts = dateFormatter.parseDate(value, format);
400
+
401
+ // Validator for day
402
+ const dayValueIsValid = (day) => {
403
+
404
+ // Guard clause: if there is no day in the dateParts, we can ignore this check.
405
+ if (!dateParts.day) {
406
+ return true;
407
+ }
408
+
409
+ // Guard clause: ensure day exists.
410
+ if (!day) {
411
+ return false;
412
+ }
413
+
414
+ // Convert day to number
415
+ const numDay = Number.parseInt(day, 10);
416
+
417
+ // Guard clause: ensure day is a valid integer
418
+ if (Number.isNaN(numDay)) {
419
+ throw new Error('AuroDatepickerUtilities | dayValueIsValid: Unable to parse day value integer');
420
+ }
421
+
422
+ // Guard clause: ensure day is within the valid range
423
+ if (numDay < this.minDay || numDay > this.maxDay) {
424
+ return false;
425
+ }
426
+
427
+ // Default return
428
+ return true;
429
+ };
430
+
431
+ // Validator for month
432
+ const monthValueIsValid = (month) => {
433
+
434
+ // Guard clause: ensure month exists.
435
+ if (!month) {
436
+ return false;
437
+ }
438
+
439
+ // Convert month to number
440
+ const numMonth = Number.parseInt(month, 10);
441
+
442
+ // Guard clause: ensure month is a valid integer
443
+ if (Number.isNaN(numMonth)) {
444
+ throw new Error('AuroDatepickerUtilities | monthValueIsValid: Unable to parse month value integer');
445
+ }
446
+
447
+ // Guard clause: ensure month is within the valid range
448
+ if (numMonth < this.minMonth || numMonth > this.maxMonth) {
449
+ return false;
450
+ }
451
+
452
+ // Default return
453
+ return true;
454
+ };
455
+
456
+ // Validator for year
457
+ const yearIsValid = (_year) => {
458
+
459
+ // Guard clause: ensure year exists.
460
+ if (!_year) {
461
+ return false;
462
+ }
463
+
464
+ // Get the full year
465
+ const year = this.getFourDigitYear(_year);
466
+
467
+ // Convert year to number
468
+ const numYear = Number.parseInt(year, 10);
469
+
470
+ // Guard clause: ensure year is a valid integer
471
+ if (Number.isNaN(numYear)) {
472
+ throw new Error('AuroDatepickerUtilities | yearValueIsValid: Unable to parse year value integer');
473
+ }
474
+
475
+ // Guard clause: ensure year is within the valid range
476
+ if (numYear < this.minYear || numYear > this.maxYear) {
477
+ return false;
478
+ }
479
+
480
+ // Default return
481
+ return true;
482
+ };
483
+
484
+ // Self-contained checks for month, day, and year
485
+ const checks = [
486
+ monthValueIsValid(dateParts.month),
487
+ dayValueIsValid(dateParts.day),
488
+ yearIsValid(dateParts.year)
489
+ ];
490
+
491
+ // If any of the checks failed, the date format does not match and the result is invalid
492
+ const isValid = checks.every((check) => check === true);
493
+
494
+ // If the check is invalid, return false
495
+ if (!isValid) {
496
+ return false;
497
+ }
498
+
499
+ // Default case
500
+ return true;
501
+ };
502
+ }
503
+ }
504
+
505
+ // Export a class instance
506
+ const dateUtilities = new AuroDateUtilities();
507
+
508
+ // Export the class instance methods individually
509
+ const {
510
+ datesMatch,
511
+ validDateStr,
512
+ dateAndFormatMatch,
513
+ minDay,
514
+ minMonth,
515
+ minYear,
516
+ maxDay,
517
+ maxMonth,
518
+ maxYear
519
+ } = dateUtilities;
520
+
521
+ const {
522
+ toNorthAmericanFormat,
523
+ parseDate,
524
+ getDateAsString
525
+ } = dateFormatter;
526
+
118
527
  // Copyright (c) Alaska Air. All right reserved. Licensed under the Apache-2.0 license
119
528
  // See LICENSE in the project root for license information.
120
529
 
@@ -339,7 +748,7 @@ class AuroFormValidation {
339
748
  validity: 'valueMissing',
340
749
  message: e => e.getAttribute('setCustomValidityValueMissingFilter') || e.setCustomValidity || ''
341
750
  }
342
- ]
751
+ ]
343
752
  }
344
753
  };
345
754
 
@@ -404,12 +813,12 @@ class AuroFormValidation {
404
813
 
405
814
  // Guard Clause: if the value is too short
406
815
  if (elem.value?.length < elem.lengthForType) {
407
-
816
+
408
817
  elem.validity = 'tooShort';
409
818
  elem.errorMessage = elem.setCustomValidityForType || elem.setCustomValidity || '';
410
819
  return;
411
- }
412
-
820
+ }
821
+
413
822
  // Guard Clause: If the value is too long for the type
414
823
  if (elem.value?.length > elem.lengthForType) {
415
824
 
@@ -417,20 +826,31 @@ class AuroFormValidation {
417
826
  elem.errorMessage = elem.setCustomValidityForType || elem.setCustomValidity || '';
418
827
  return;
419
828
  }
420
-
421
- // Validate that the date passed was the correct format and is a valid date
422
- if (elem.value && !elem.valueObject) {
829
+
830
+ // Validate that the date passed was the correct format
831
+ if (!dateAndFormatMatch(elem.value, elem.format)) {
423
832
  elem.validity = 'patternMismatch';
424
- elem.errorMessage = elem.setCustomValidityPatternMismatch || elem.setCustomValidity || 'Invalid Date Format Entered';
833
+ elem.errorMessage = elem.setCustomValidityForType || elem.setCustomValidity || 'Invalid Date Format Entered';
834
+ return;
835
+ }
836
+
837
+ // Validate that the date passed was a valid date
838
+ if (!validDateStr(elem.value, elem.format)) {
839
+ elem.validity = 'invalidDate';
840
+ elem.errorMessage = elem.setCustomValidityInvalidDate || elem.setCustomValidity || 'Invalid Date Entered';
425
841
  return;
426
842
  }
427
843
 
428
844
  // Perform the rest of the validation
845
+ const formattedValue = toNorthAmericanFormat(elem.value, elem.format);
846
+ const valueDate = new Date(formattedValue);
429
847
 
430
848
  // // Validate max date
431
849
  if (elem.max?.length === elem.lengthForType) {
432
850
 
433
- if (elem.valueObject > elem.maxObject) {
851
+ const maxDate = new Date(toNorthAmericanFormat(elem.max, elem.format));
852
+
853
+ if (valueDate > maxDate) {
434
854
  elem.validity = 'rangeOverflow';
435
855
  elem.errorMessage = elem.setCustomValidityRangeOverflow || elem.setCustomValidity || '';
436
856
  return;
@@ -439,7 +859,9 @@ class AuroFormValidation {
439
859
 
440
860
  // Validate min date
441
861
  if (elem.min?.length === elem.lengthForType) {
442
- if (elem.valueObject < elem.minObject) {
862
+ const minDate = new Date(toNorthAmericanFormat(elem.min, elem.format));
863
+
864
+ if (valueDate < minDate) {
443
865
  elem.validity = 'rangeUnderflow';
444
866
  elem.errorMessage = elem.setCustomValidityRangeUnderflow || elem.setCustomValidity || '';
445
867
  return;
@@ -499,7 +921,7 @@ class AuroFormValidation {
499
921
  if (typeof elem.value === "string") {
500
922
  hasValue = elem.value && elem.value.length > 0;
501
923
  }
502
-
924
+
503
925
  if (typeof elem.value === "boolean") {
504
926
  hasValue = elem.value || elem.value === false;
505
927
  }
@@ -524,7 +946,7 @@ class AuroFormValidation {
524
946
  }
525
947
 
526
948
  const isCombobox = this.runtimeUtils.elementMatch(elem, 'auro-combobox');
527
-
949
+
528
950
  if (isCombobox) {
529
951
 
530
952
  if (!elem.persistInput || elem.behavior === "filter") {
@@ -564,7 +986,7 @@ class AuroFormValidation {
564
986
  }
565
987
 
566
988
  // multiple input in one components (datepicker)
567
- // combobox has 2 inputs but no need to check validity on the 2nd one which is in fullscreen bib.
989
+ // combobox has 2 inputs but no need to check validity on the 2nd one which is in fullscreen bib.
568
990
  if (elem.validity === 'valid' && this.auroInputElements.length > 1 && !isCombobox) {
569
991
  elem.validity = this.auroInputElements[1].validity;
570
992
  elem.errorMessage = this.auroInputElements[1].errorMessage;
@@ -840,28 +1262,30 @@ function navigateArrow(component, direction, options = {}) {
840
1262
  const selectKeyboardStrategy = {
841
1263
  ArrowDown(component, evt, ctx) {
842
1264
  evt.preventDefault();
843
- if (evt.altKey || evt.metaKey) {
844
- // navigate to last enabled option
845
- selectKeyboardStrategy.End(component, evt, ctx);
846
- return;
1265
+ if (ctx.isExpanded) {
1266
+ if (evt.altKey || evt.ctrlKey || evt.metaKey) {
1267
+ // navigate to last enabled option
1268
+ selectKeyboardStrategy.End(component, evt, ctx);
1269
+ } else {
1270
+ navigateArrow(component, 'down', { ctx });
1271
+ }
1272
+ } else {
1273
+ component.dropdown.show();
847
1274
  }
848
- navigateArrow(component, 'down', {
849
- ctx,
850
- showFn: () => component.dropdown.show(),
851
- });
852
1275
  },
853
1276
 
854
1277
  ArrowUp(component, evt, ctx) {
855
1278
  evt.preventDefault();
856
- if (evt.altKey || evt.metaKey) {
857
- // navigate to first enabled option
858
- selectKeyboardStrategy.Home(component, evt, ctx);
859
- return;
1279
+ if (ctx.isExpanded) {
1280
+ if (evt.altKey || evt.ctrlKey || evt.metaKey) {
1281
+ // navigate to first enabled option
1282
+ selectKeyboardStrategy.Home(component, evt, ctx);
1283
+ } else {
1284
+ navigateArrow(component, 'up', { ctx });
1285
+ }
1286
+ } else {
1287
+ component.dropdown.show();
860
1288
  }
861
- navigateArrow(component, 'up', {
862
- ctx,
863
- showFn: () => component.dropdown.show(),
864
- });
865
1289
  },
866
1290
 
867
1291
  Escape(component, evt, ctx) {
@@ -4844,7 +5268,7 @@ let AuroHelpText$1 = class AuroHelpText extends LitElement {
4844
5268
  }
4845
5269
  };
4846
5270
 
4847
- var formkitVersion$1 = '202605271836';
5271
+ var formkitVersion$1 = '202605292307';
4848
5272
 
4849
5273
  class AuroElement extends LitElement {
4850
5274
  static get properties() {
@@ -6597,7 +7021,7 @@ class AuroHelpText extends LitElement {
6597
7021
  }
6598
7022
  }
6599
7023
 
6600
- var formkitVersion = '202605271836';
7024
+ var formkitVersion = '202605292307';
6601
7025
 
6602
7026
  var styleCss = css`.util_displayInline{display:inline}.util_displayInlineBlock{display:inline-block}.util_displayBlock{display:block}.util_displayFlex{display:flex}.util_displayHidden{display:none}.util_displayHiddenVisually{position:absolute;overflow:hidden;clip:rect(1px, 1px, 1px, 1px);width:1px;height:1px;padding:0;border:0}.body-default{font-size:var(--wcss-body-default-font-size, 1rem);font-weight:var(--wcss-body-default-weight, );line-height:var(--wcss-body-default-line-height, 1.5rem)}.body-default,.body-default-emphasized{font-family:var(--wcss-body-family, "AS Circular"),system-ui,-apple-system,BlinkMacSystemFont,"Segoe UI",Roboto,"Helvetica Neue",Arial,sans-serif;letter-spacing:var(--wcss-body-letter-spacing, 0)}.body-default-emphasized{font-size:var(--wcss-body-default-emphasized-font-size, 1rem);font-weight:var(--wcss-body-default-emphasized-weight, );line-height:var(--wcss-body-default-emphasized-line-height, 1.5rem)}.body-lg{font-size:var(--wcss-body-lg-font-size, 1.125rem);font-weight:var(--wcss-body-lg-weight, );line-height:var(--wcss-body-lg-line-height, 1.625rem)}.body-lg,.body-lg-emphasized{font-family:var(--wcss-body-family, "AS Circular"),system-ui,-apple-system,BlinkMacSystemFont,"Segoe UI",Roboto,"Helvetica Neue",Arial,sans-serif;letter-spacing:var(--wcss-body-letter-spacing, 0)}.body-lg-emphasized{font-size:var(--wcss-body-lg-emphasized-font-size, 1.125rem);font-weight:var(--wcss-body-lg-emphasized-weight, );line-height:var(--wcss-body-lg-emphasized-line-height, 1.625rem)}.body-sm{font-size:var(--wcss-body-sm-font-size, 0.875rem);font-weight:var(--wcss-body-sm-weight, );line-height:var(--wcss-body-sm-line-height, 1.25rem)}.body-sm,.body-sm-emphasized{font-family:var(--wcss-body-family, "AS Circular"),system-ui,-apple-system,BlinkMacSystemFont,"Segoe UI",Roboto,"Helvetica Neue",Arial,sans-serif;letter-spacing:var(--wcss-body-letter-spacing, 0)}.body-sm-emphasized{font-size:var(--wcss-body-sm-emphasized-font-size, 0.875rem);font-weight:var(--wcss-body-sm-emphasized-weight, );line-height:var(--wcss-body-sm-emphasized-line-height, 1.25rem)}.body-xs{font-size:var(--wcss-body-xs-font-size, 0.75rem);font-weight:var(--wcss-body-xs-weight, );line-height:var(--wcss-body-xs-line-height, 1rem)}.body-xs,.body-xs-emphasized{font-family:var(--wcss-body-family, "AS Circular"),system-ui,-apple-system,BlinkMacSystemFont,"Segoe UI",Roboto,"Helvetica Neue",Arial,sans-serif;letter-spacing:var(--wcss-body-letter-spacing, 0)}.body-xs-emphasized{font-size:var(--wcss-body-xs-emphasized-font-size, 0.75rem);font-weight:var(--wcss-body-xs-emphasized-weight, );line-height:var(--wcss-body-xs-emphasized-line-height, 1rem)}.body-2xs{font-size:var(--wcss-body-2xs-font-size, 0.625rem);font-weight:var(--wcss-body-2xs-weight, );line-height:var(--wcss-body-2xs-line-height, 0.875rem)}.body-2xs,.body-2xs-emphasized{font-family:var(--wcss-body-family, "AS Circular"),system-ui,-apple-system,BlinkMacSystemFont,"Segoe UI",Roboto,"Helvetica Neue",Arial,sans-serif;letter-spacing:var(--wcss-body-letter-spacing, 0)}.body-2xs-emphasized{font-size:var(--wcss-body-2xs-emphasized-font-size, 0.625rem);font-weight:var(--wcss-body-2xs-emphasized-weight, );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-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, 300);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, 300);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, 0.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, 0.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, 0.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, 0.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, 0.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, 0.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(0.875rem, 1.1666666667vw, 0.875rem));font-weight:var(--wcss-accent-2xs-weight, 450);letter-spacing:var(--wcss-accent-2xs-letter-spacing, 0.1em);line-height:var(--wcss-accent-2xs-line-height, 1.3);text-transform:uppercase}[auro-dropdown]{--ds-auro-dropdown-trigger-border-color: var(--ds-auro-select-border-color);--ds-auro-dropdown-trigger-background-color: var(--ds-auro-select-background-color);--ds-auro-dropdown-trigger-container-color: var(--ds-auro-select-background-color);--ds-auro-dropdown-trigger-outline-color: var(--ds-auro-select-outline-color)}:host{display:inline-block;text-align:left;vertical-align:top}:host([layout*=emphasized]) [auro-dropdown],:host([layout*=snowflake]) [auro-dropdown]{--ds-auro-select-border-color: transparent}:host([layout*=emphasized]) .mainContent,:host([layout*=snowflake]) .mainContent{text-align:center}.mainContent{position:relative;display:flex;overflow:hidden;flex:1;flex-direction:column;align-items:center;justify-content:center}.valueContainer [slot=displayValue]{display:none}.accents{display:flex;flex-direction:row;align-items:center;justify-content:center}::slotted([slot=typeIcon]){margin-right:var(--ds-size-100, 0.5rem)}.displayValue{display:block}.displayValue:not(.force){display:none}.displayValue:not(.force).hasContent:is(.withValue):not(.hasFocus){display:block}.triggerContent{display:flex;width:100%;align-items:center;justify-content:center}:host([layout*=emphasized]) .triggerContent{padding:0 var(--ds-size-100, 0.5rem) 0 var(--ds-size-300, 1.5rem)}:host([layout*=snowflake]) .triggerContent{padding:0 var(--ds-size-100, 0.5rem) 0 var(--ds-size-200, 1rem)}:host([layout*=snowflake]) label{padding-block:var(--ds-size-25, 0.125rem)}:host([layout*=classic]) .triggerContent{padding:0 var(--ds-size-100, 0.5rem)}:host([layout*=classic]) .mainContent{align-items:start}:host([layout*=classic]) label{overflow:hidden;cursor:text;text-overflow:ellipsis;white-space:nowrap}:host([layout*=classic]) .value{height:auto}label{color:var(--ds-auro-select-label-text-color)}:host(:is([validity]:not([validity=valid]))) [auro-dropdown]{--ds-auro-select-border-color: var(--ds-basic-color-status-error, #e31f26);--ds-auro-select-outline-color: var(--ds-basic-color-status-error, #e31f26);--ds-auro-dropdown-helptext-text-color: var(--ds-basic-color-texticon-default, #2a2a2a)}:host([ondark]:is([validity]:not([validity=valid]))) [auro-dropdown],:host([appearance=inverse]:is([validity]:not([validity=valid]))) [auro-dropdown]{--ds-auro-select-border-color: var(--ds-advanced-color-state-error-inverse, #f9a4a8);--ds-auro-select-outline-color: var(--ds-advanced-color-state-error-inverse, #f9a4a8);--ds-auro-dropdown-helptext-text-color: var(--ds-basic-color-texticon-inverse, #ffffff)}#slotHolder{display:none}:host([fluid]){width:100%}:host([disabled]){pointer-events:none;user-select:none}:host([disabled]:not([ondark])) [auro-dropdown],:host([disabled]:not([appearance=inverse])) [auro-dropdown]{--ds-auro-select-border-color: var(--ds-basic-color-border-subtle, #dddddd)}:host(:not([layout*=classic])[disabled][ondark]) [auro-dropdown],:host(:not([layout*=classic])[disabled][appearance=inverse]) [auro-dropdown]{--ds-auro-select-border-color: transparent}`;
6603
7027