@aurodesignsystem-dev/auro-formkit 0.0.0-pr1430.0 → 0.0.0-pr1430.1

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 (60) hide show
  1. package/components/checkbox/demo/api.min.js +3 -3
  2. package/components/checkbox/demo/index.min.js +3 -3
  3. package/components/checkbox/dist/index.js +3 -3
  4. package/components/checkbox/dist/registered.js +3 -3
  5. package/components/combobox/demo/api.html +1 -0
  6. package/components/combobox/demo/api.js +3 -1
  7. package/components/combobox/demo/api.md +75 -0
  8. package/components/combobox/demo/api.min.js +44 -96
  9. package/components/combobox/demo/index.min.js +31 -95
  10. package/components/combobox/dist/comboboxKeyboardStrategy.d.ts +1 -1
  11. package/components/combobox/dist/index.js +21 -95
  12. package/components/combobox/dist/registered.js +21 -95
  13. package/components/counter/demo/api.html +3 -0
  14. package/components/counter/demo/api.js +4 -0
  15. package/components/counter/demo/api.md +130 -0
  16. package/components/counter/demo/api.min.js +63 -104
  17. package/components/counter/demo/index.min.js +43 -104
  18. package/components/counter/dist/counterGroupKeyboardStrategy.d.ts +3 -0
  19. package/components/counter/dist/index.js +43 -104
  20. package/components/counter/dist/registered.js +43 -104
  21. package/components/datepicker/demo/api.html +1 -0
  22. package/components/datepicker/demo/api.js +2 -0
  23. package/components/datepicker/demo/api.md +57 -0
  24. package/components/datepicker/demo/api.min.js +106 -95
  25. package/components/datepicker/demo/index.min.js +94 -95
  26. package/components/datepicker/dist/datepickerKeyboardStrategy.d.ts +3 -1
  27. package/components/datepicker/dist/index.js +94 -95
  28. package/components/datepicker/dist/registered.js +94 -95
  29. package/components/dropdown/demo/api.html +1 -0
  30. package/components/dropdown/demo/api.js +2 -0
  31. package/components/dropdown/demo/api.md +95 -0
  32. package/components/dropdown/demo/api.min.js +25 -88
  33. package/components/dropdown/demo/index.min.js +5 -88
  34. package/components/dropdown/dist/index.js +5 -88
  35. package/components/dropdown/dist/registered.js +5 -88
  36. package/components/form/demo/api.min.js +230 -435
  37. package/components/form/demo/index.min.js +230 -435
  38. package/components/input/demo/api.min.js +1 -1
  39. package/components/input/demo/index.min.js +1 -1
  40. package/components/input/dist/index.js +1 -1
  41. package/components/input/dist/registered.js +1 -1
  42. package/components/menu/demo/api.md +1 -0
  43. package/components/menu/demo/api.min.js +10 -0
  44. package/components/menu/demo/index.min.js +10 -0
  45. package/components/menu/dist/auro-menuoption.d.ts +9 -0
  46. package/components/menu/dist/index.js +10 -0
  47. package/components/menu/dist/registered.js +10 -0
  48. package/components/radio/demo/api.min.js +2 -2
  49. package/components/radio/demo/index.min.js +2 -2
  50. package/components/radio/dist/index.js +2 -2
  51. package/components/radio/dist/registered.js +2 -2
  52. package/components/select/demo/api.html +1 -0
  53. package/components/select/demo/api.js +2 -0
  54. package/components/select/demo/api.md +76 -0
  55. package/components/select/demo/api.min.js +45 -101
  56. package/components/select/demo/index.min.js +32 -101
  57. package/components/select/dist/index.js +18 -97
  58. package/components/select/dist/registered.js +18 -97
  59. package/custom-elements.json +48 -3
  60. package/package.json +4 -3
@@ -1301,10 +1301,19 @@ const comboboxKeyboardStrategy = {
1301
1301
  }
1302
1302
  },
1303
1303
 
1304
- Escape(component, _evt, ctx) {
1305
- if (ctx.isExpanded && ctx.isModal) {
1304
+ Escape(component, evt, ctx) {
1305
+ if (!ctx.isExpanded) {
1306
+ return;
1307
+ }
1308
+
1309
+ // Prevent the Escape key from bubbling up and closing any parent dialogs / drawers / popups
1310
+ evt.stopPropagation();
1311
+
1312
+ if (ctx.isModal) {
1306
1313
  component.setTriggerInputFocus();
1307
1314
  }
1315
+
1316
+ component.hideBib();
1308
1317
  },
1309
1318
 
1310
1319
  Home(component, evt, ctx) {
@@ -1341,7 +1350,7 @@ const comboboxKeyboardStrategy = {
1341
1350
 
1342
1351
  /* eslint-disable line-comment-position, no-inline-comments, no-confusing-arrow, no-nested-ternary, implicit-arrow-linebreak */
1343
1352
 
1344
- let AuroLibraryRuntimeUtils$2$1 = class AuroLibraryRuntimeUtils {
1353
+ let AuroLibraryRuntimeUtils$1$2 = class AuroLibraryRuntimeUtils {
1345
1354
 
1346
1355
  /* eslint-disable jsdoc/require-param */
1347
1356
 
@@ -4382,89 +4391,6 @@ let p$3 = class p{registerComponent(t,a){customElements.get(t)||customElements.d
4382
4391
 
4383
4392
  var iconVersion$2 = '9.1.2';
4384
4393
 
4385
- // Copyright (c) Alaska Air. All right reserved. Licensed under the Apache-2.0 license
4386
- // See LICENSE in the project root for license information.
4387
-
4388
- // ---------------------------------------------------------------------
4389
-
4390
- /* eslint-disable line-comment-position, no-inline-comments, no-confusing-arrow, no-nested-ternary, implicit-arrow-linebreak */
4391
-
4392
- let AuroLibraryRuntimeUtils$1$2 = class AuroLibraryRuntimeUtils {
4393
-
4394
- /* eslint-disable jsdoc/require-param */
4395
-
4396
- /**
4397
- * This will register a new custom element with the browser.
4398
- * @param {String} name - The name of the custom element.
4399
- * @param {Object} componentClass - The class to register as a custom element.
4400
- * @returns {void}
4401
- */
4402
- registerComponent(name, componentClass) {
4403
- if (!customElements.get(name)) {
4404
- customElements.define(name, class extends componentClass {});
4405
- }
4406
- }
4407
-
4408
- /**
4409
- * Finds and returns the closest HTML Element based on a selector.
4410
- * @returns {void}
4411
- */
4412
- closestElement(
4413
- selector, // selector like in .closest()
4414
- base = this, // extra functionality to skip a parent
4415
- __Closest = (el, found = el && el.closest(selector)) =>
4416
- !el || el === document || el === window
4417
- ? null // standard .closest() returns null for non-found selectors also
4418
- : found
4419
- ? found // found a selector INside this element
4420
- : __Closest(el.getRootNode().host) // recursion!! break out to parent DOM
4421
- ) {
4422
- return __Closest(base);
4423
- }
4424
- /* eslint-enable jsdoc/require-param */
4425
-
4426
- /**
4427
- * If the element passed is registered with a different tag name than what is passed in, the tag name is added as an attribute to the element.
4428
- * @param {Object} elem - The element to check.
4429
- * @param {String} tagName - The name of the Auro component to check for or add as an attribute.
4430
- * @returns {void}
4431
- */
4432
- handleComponentTagRename(elem, tagName) {
4433
- const tag = tagName.toLowerCase();
4434
- const elemTag = elem.tagName.toLowerCase();
4435
-
4436
- if (elemTag !== tag) {
4437
- elem.setAttribute(tag, true);
4438
- }
4439
- }
4440
-
4441
- /**
4442
- * Validates if an element is a specific Auro component.
4443
- * @param {Object} elem - The element to validate.
4444
- * @param {String} tagName - The name of the Auro component to check against.
4445
- * @returns {Boolean} - Returns true if the element is the specified Auro component.
4446
- */
4447
- elementMatch(elem, tagName) {
4448
- const tag = tagName.toLowerCase();
4449
- const elemTag = elem.tagName.toLowerCase();
4450
-
4451
- return elemTag === tag || elem.hasAttribute(tag);
4452
- }
4453
-
4454
- /**
4455
- * Gets the text content of a named slot.
4456
- * @returns {String}
4457
- * @private
4458
- */
4459
- getSlotText(elem, name) {
4460
- const slot = elem.shadowRoot?.querySelector(`slot[name="${name}"]`);
4461
- const nodes = slot?.assignedNodes({ flatten: true }) || [];
4462
- const text = nodes.map(n => n.textContent?.trim()).join(' ').trim();
4463
-
4464
- return text || null;
4465
- }
4466
- };
4467
-
4468
4394
  /**
4469
4395
  * Computes display state once per keydown event.
4470
4396
  * Centralizes null-safety checks and makes the shared/modal/popover branching explicit.
@@ -5147,7 +5073,7 @@ let AuroHelpText$2 = class AuroHelpText extends LitElement {
5147
5073
  }
5148
5074
  };
5149
5075
 
5150
- var formkitVersion$2 = '202604082129';
5076
+ var formkitVersion$2 = '202604091756';
5151
5077
 
5152
5078
  let AuroElement$2 = class AuroElement extends LitElement {
5153
5079
  static get properties() {
@@ -5253,7 +5179,7 @@ let AuroElement$2 = class AuroElement extends LitElement {
5253
5179
  }
5254
5180
  };
5255
5181
 
5256
- // Copyright (c) 2026 Alaska Airlines. All right reserved. Licensed under the Apache-2.0 license
5182
+ // Copyright (c) 2026 Alaska Airlines. All rights reserved. Licensed under the Apache-2.0 license
5257
5183
  // See LICENSE in the project root for license information.
5258
5184
 
5259
5185
 
@@ -5358,7 +5284,7 @@ class AuroDropdown extends AuroElement$2 {
5358
5284
  /**
5359
5285
  * @private
5360
5286
  */
5361
- this.runtimeUtils = new AuroLibraryRuntimeUtils$2$1();
5287
+ this.runtimeUtils = new AuroLibraryRuntimeUtils$1$2();
5362
5288
 
5363
5289
  /**
5364
5290
  * @private
@@ -5776,7 +5702,7 @@ class AuroDropdown extends AuroElement$2 {
5776
5702
  *
5777
5703
  */
5778
5704
  static register(name = "auro-dropdown") {
5779
- AuroLibraryRuntimeUtils$2$1.prototype.registerComponent(name, AuroDropdown);
5705
+ AuroLibraryRuntimeUtils$1$2.prototype.registerComponent(name, AuroDropdown);
5780
5706
  }
5781
5707
 
5782
5708
  /**
@@ -12904,7 +12830,7 @@ let AuroHelpText$1 = class AuroHelpText extends LitElement {
12904
12830
  }
12905
12831
  };
12906
12832
 
12907
- var formkitVersion$1 = '202604082129';
12833
+ var formkitVersion$1 = '202604091756';
12908
12834
 
12909
12835
  // Copyright (c) 2025 Alaska Airlines. All right reserved. Licensed under the Apache-2.0 license
12910
12836
  // See LICENSE in the project root for license information.
@@ -13969,7 +13895,7 @@ class AuroBibtemplate extends LitElement {
13969
13895
  }
13970
13896
  }
13971
13897
 
13972
- var formkitVersion = '202604082129';
13898
+ var formkitVersion = '202604091756';
13973
13899
 
13974
13900
  var styleCss$1 = 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}:host{display:block;text-align:left}:host [auro-dropdown]{--ds-auro-dropdown-trigger-background-color: transparent}:host #inputInBib::part(wrapper){box-shadow:none}:host #inputInBib::part(accent-left){display:none}:host([layout*=classic]) [auro-input]{width:100%}:host([layout*=classic]) [auro-input]::part(helpText){display:none}:host([layout*=classic]) #slotHolder{display:none}`;
13975
13901
 
@@ -14309,7 +14235,7 @@ class AuroHelpText extends LitElement {
14309
14235
  }
14310
14236
  }
14311
14237
 
14312
- // Copyright (c) 2026 Alaska Airlines. All right reserved. Licensed under the Apache-2.0 license
14238
+ // Copyright (c) 2026 Alaska Airlines. All rights reserved. Licensed under the Apache-2.0 license
14313
14239
  // See LICENSE in the project root for license information.
14314
14240
 
14315
14241
 
@@ -14832,7 +14758,7 @@ class AuroCombobox extends AuroElement {
14832
14758
  * @returns {void}
14833
14759
  */
14834
14760
  activateFirstEnabledAvailableOption() {
14835
- const firstEnabledOptionIndex = this.availableOptions.findIndex((opt) => !opt.disabled);
14761
+ const firstEnabledOptionIndex = this.availableOptions.findIndex((opt) => !opt.disabled && !opt.hasAttribute('nomatch'));
14836
14762
  this.updateActiveOption(firstEnabledOptionIndex);
14837
14763
  }
14838
14764
 
@@ -14846,7 +14772,7 @@ class AuroCombobox extends AuroElement {
14846
14772
 
14847
14773
  // Work backwards through the available options array to find the last enabled option
14848
14774
  for (let index = this.availableOptions.length - 1; index >= 0; index -= 1) {
14849
- if (!this.availableOptions[index].disabled) {
14775
+ if (!this.availableOptions[index].disabled && !this.availableOptions[index].hasAttribute('nomatch')) {
14850
14776
  lastEnabledOptionIndex = index;
14851
14777
  break;
14852
14778
  }
@@ -1301,10 +1301,19 @@ const comboboxKeyboardStrategy = {
1301
1301
  }
1302
1302
  },
1303
1303
 
1304
- Escape(component, _evt, ctx) {
1305
- if (ctx.isExpanded && ctx.isModal) {
1304
+ Escape(component, evt, ctx) {
1305
+ if (!ctx.isExpanded) {
1306
+ return;
1307
+ }
1308
+
1309
+ // Prevent the Escape key from bubbling up and closing any parent dialogs / drawers / popups
1310
+ evt.stopPropagation();
1311
+
1312
+ if (ctx.isModal) {
1306
1313
  component.setTriggerInputFocus();
1307
1314
  }
1315
+
1316
+ component.hideBib();
1308
1317
  },
1309
1318
 
1310
1319
  Home(component, evt, ctx) {
@@ -1341,7 +1350,7 @@ const comboboxKeyboardStrategy = {
1341
1350
 
1342
1351
  /* eslint-disable line-comment-position, no-inline-comments, no-confusing-arrow, no-nested-ternary, implicit-arrow-linebreak */
1343
1352
 
1344
- let AuroLibraryRuntimeUtils$2$1 = class AuroLibraryRuntimeUtils {
1353
+ let AuroLibraryRuntimeUtils$1$2 = class AuroLibraryRuntimeUtils {
1345
1354
 
1346
1355
  /* eslint-disable jsdoc/require-param */
1347
1356
 
@@ -4382,89 +4391,6 @@ let p$3 = class p{registerComponent(t,a){customElements.get(t)||customElements.d
4382
4391
 
4383
4392
  var iconVersion$2 = '9.1.2';
4384
4393
 
4385
- // Copyright (c) Alaska Air. All right reserved. Licensed under the Apache-2.0 license
4386
- // See LICENSE in the project root for license information.
4387
-
4388
- // ---------------------------------------------------------------------
4389
-
4390
- /* eslint-disable line-comment-position, no-inline-comments, no-confusing-arrow, no-nested-ternary, implicit-arrow-linebreak */
4391
-
4392
- let AuroLibraryRuntimeUtils$1$2 = class AuroLibraryRuntimeUtils {
4393
-
4394
- /* eslint-disable jsdoc/require-param */
4395
-
4396
- /**
4397
- * This will register a new custom element with the browser.
4398
- * @param {String} name - The name of the custom element.
4399
- * @param {Object} componentClass - The class to register as a custom element.
4400
- * @returns {void}
4401
- */
4402
- registerComponent(name, componentClass) {
4403
- if (!customElements.get(name)) {
4404
- customElements.define(name, class extends componentClass {});
4405
- }
4406
- }
4407
-
4408
- /**
4409
- * Finds and returns the closest HTML Element based on a selector.
4410
- * @returns {void}
4411
- */
4412
- closestElement(
4413
- selector, // selector like in .closest()
4414
- base = this, // extra functionality to skip a parent
4415
- __Closest = (el, found = el && el.closest(selector)) =>
4416
- !el || el === document || el === window
4417
- ? null // standard .closest() returns null for non-found selectors also
4418
- : found
4419
- ? found // found a selector INside this element
4420
- : __Closest(el.getRootNode().host) // recursion!! break out to parent DOM
4421
- ) {
4422
- return __Closest(base);
4423
- }
4424
- /* eslint-enable jsdoc/require-param */
4425
-
4426
- /**
4427
- * If the element passed is registered with a different tag name than what is passed in, the tag name is added as an attribute to the element.
4428
- * @param {Object} elem - The element to check.
4429
- * @param {String} tagName - The name of the Auro component to check for or add as an attribute.
4430
- * @returns {void}
4431
- */
4432
- handleComponentTagRename(elem, tagName) {
4433
- const tag = tagName.toLowerCase();
4434
- const elemTag = elem.tagName.toLowerCase();
4435
-
4436
- if (elemTag !== tag) {
4437
- elem.setAttribute(tag, true);
4438
- }
4439
- }
4440
-
4441
- /**
4442
- * Validates if an element is a specific Auro component.
4443
- * @param {Object} elem - The element to validate.
4444
- * @param {String} tagName - The name of the Auro component to check against.
4445
- * @returns {Boolean} - Returns true if the element is the specified Auro component.
4446
- */
4447
- elementMatch(elem, tagName) {
4448
- const tag = tagName.toLowerCase();
4449
- const elemTag = elem.tagName.toLowerCase();
4450
-
4451
- return elemTag === tag || elem.hasAttribute(tag);
4452
- }
4453
-
4454
- /**
4455
- * Gets the text content of a named slot.
4456
- * @returns {String}
4457
- * @private
4458
- */
4459
- getSlotText(elem, name) {
4460
- const slot = elem.shadowRoot?.querySelector(`slot[name="${name}"]`);
4461
- const nodes = slot?.assignedNodes({ flatten: true }) || [];
4462
- const text = nodes.map(n => n.textContent?.trim()).join(' ').trim();
4463
-
4464
- return text || null;
4465
- }
4466
- };
4467
-
4468
4394
  /**
4469
4395
  * Computes display state once per keydown event.
4470
4396
  * Centralizes null-safety checks and makes the shared/modal/popover branching explicit.
@@ -5147,7 +5073,7 @@ let AuroHelpText$2 = class AuroHelpText extends LitElement {
5147
5073
  }
5148
5074
  };
5149
5075
 
5150
- var formkitVersion$2 = '202604082129';
5076
+ var formkitVersion$2 = '202604091756';
5151
5077
 
5152
5078
  let AuroElement$2 = class AuroElement extends LitElement {
5153
5079
  static get properties() {
@@ -5253,7 +5179,7 @@ let AuroElement$2 = class AuroElement extends LitElement {
5253
5179
  }
5254
5180
  };
5255
5181
 
5256
- // Copyright (c) 2026 Alaska Airlines. All right reserved. Licensed under the Apache-2.0 license
5182
+ // Copyright (c) 2026 Alaska Airlines. All rights reserved. Licensed under the Apache-2.0 license
5257
5183
  // See LICENSE in the project root for license information.
5258
5184
 
5259
5185
 
@@ -5358,7 +5284,7 @@ class AuroDropdown extends AuroElement$2 {
5358
5284
  /**
5359
5285
  * @private
5360
5286
  */
5361
- this.runtimeUtils = new AuroLibraryRuntimeUtils$2$1();
5287
+ this.runtimeUtils = new AuroLibraryRuntimeUtils$1$2();
5362
5288
 
5363
5289
  /**
5364
5290
  * @private
@@ -5776,7 +5702,7 @@ class AuroDropdown extends AuroElement$2 {
5776
5702
  *
5777
5703
  */
5778
5704
  static register(name = "auro-dropdown") {
5779
- AuroLibraryRuntimeUtils$2$1.prototype.registerComponent(name, AuroDropdown);
5705
+ AuroLibraryRuntimeUtils$1$2.prototype.registerComponent(name, AuroDropdown);
5780
5706
  }
5781
5707
 
5782
5708
  /**
@@ -12904,7 +12830,7 @@ let AuroHelpText$1 = class AuroHelpText extends LitElement {
12904
12830
  }
12905
12831
  };
12906
12832
 
12907
- var formkitVersion$1 = '202604082129';
12833
+ var formkitVersion$1 = '202604091756';
12908
12834
 
12909
12835
  // Copyright (c) 2025 Alaska Airlines. All right reserved. Licensed under the Apache-2.0 license
12910
12836
  // See LICENSE in the project root for license information.
@@ -13969,7 +13895,7 @@ class AuroBibtemplate extends LitElement {
13969
13895
  }
13970
13896
  }
13971
13897
 
13972
- var formkitVersion = '202604082129';
13898
+ var formkitVersion = '202604091756';
13973
13899
 
13974
13900
  var styleCss$1 = 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}:host{display:block;text-align:left}:host [auro-dropdown]{--ds-auro-dropdown-trigger-background-color: transparent}:host #inputInBib::part(wrapper){box-shadow:none}:host #inputInBib::part(accent-left){display:none}:host([layout*=classic]) [auro-input]{width:100%}:host([layout*=classic]) [auro-input]::part(helpText){display:none}:host([layout*=classic]) #slotHolder{display:none}`;
13975
13901
 
@@ -14309,7 +14235,7 @@ class AuroHelpText extends LitElement {
14309
14235
  }
14310
14236
  }
14311
14237
 
14312
- // Copyright (c) 2026 Alaska Airlines. All right reserved. Licensed under the Apache-2.0 license
14238
+ // Copyright (c) 2026 Alaska Airlines. All rights reserved. Licensed under the Apache-2.0 license
14313
14239
  // See LICENSE in the project root for license information.
14314
14240
 
14315
14241
 
@@ -14832,7 +14758,7 @@ class AuroCombobox extends AuroElement {
14832
14758
  * @returns {void}
14833
14759
  */
14834
14760
  activateFirstEnabledAvailableOption() {
14835
- const firstEnabledOptionIndex = this.availableOptions.findIndex((opt) => !opt.disabled);
14761
+ const firstEnabledOptionIndex = this.availableOptions.findIndex((opt) => !opt.disabled && !opt.hasAttribute('nomatch'));
14836
14762
  this.updateActiveOption(firstEnabledOptionIndex);
14837
14763
  }
14838
14764
 
@@ -14846,7 +14772,7 @@ class AuroCombobox extends AuroElement {
14846
14772
 
14847
14773
  // Work backwards through the available options array to find the last enabled option
14848
14774
  for (let index = this.availableOptions.length - 1; index >= 0; index -= 1) {
14849
- if (!this.availableOptions[index].disabled) {
14775
+ if (!this.availableOptions[index].disabled && !this.availableOptions[index].hasAttribute('nomatch')) {
14850
14776
  lastEnabledOptionIndex = index;
14851
14777
  break;
14852
14778
  }
@@ -56,5 +56,8 @@
56
56
 
57
57
  <!-- If additional elements are needed for the demo, add them here. -->
58
58
  <script src="https://cdn.jsdelivr.net/npm/@aurodesignsystem/auro-accordion@latest/+esm" type="module"></script>
59
+ <script src="https://cdn.jsdelivr.net/npm/@aurodesignsystem/auro-button@latest/+esm" type="module"></script>
60
+ <script src="https://cdn.jsdelivr.net/npm/@aurodesignsystem/auro-dialog@latest/+esm" type="module"></script>
61
+ <script src="https://cdn.jsdelivr.net/npm/@aurodesignsystem/auro-drawer@latest/+esm" type="module"></script>
59
62
  </body>
60
63
  </html>
@@ -2,12 +2,16 @@
2
2
  import '../src/registered.js';
3
3
  // import { dropdownCounterExample } from "../apiExamples/dropdown-mobile-properties.js";
4
4
  import { eventCounterExample } from "../apiExamples/events.js";
5
+ import { inDialogExample } from "../apiExamples/in-dialog.js";
6
+ import { inDrawerExample } from "../apiExamples/in-drawer.js";
5
7
 
6
8
  export function initExamples(initialCount = 0) {
7
9
  try {
8
10
  // javascript example function calls to be added here upon creation to test examples
9
11
  // dropdownCounterExample();
10
12
  eventCounterExample();
13
+ inDialogExample();
14
+ inDrawerExample();
11
15
 
12
16
  } catch (err) {
13
17
  if (initialCount <= 20) {
@@ -1232,6 +1232,136 @@ All available slots for both components.
1232
1232
  <!-- AURO-GENERATED-CONTENT:END -->
1233
1233
  </auro-accordion>
1234
1234
 
1235
+ ### Counter Group in Dialog
1236
+
1237
+ The element used within an `auro-dialog`.
1238
+
1239
+ <div class="exampleWrapper">
1240
+ <!-- AURO-GENERATED-CONTENT:START (FILE:src=./../apiExamples/in-dialog.html) -->
1241
+ <!-- The below content is automatically added from ./../apiExamples/in-dialog.html -->
1242
+ <div>
1243
+ <auro-button id="counter-dialog-opener">Counter Group in Dialog</auro-button>
1244
+ <auro-dialog id="counter-dialog">
1245
+ <span slot="header">Counter Group in Dialog</span>
1246
+ <div slot="content">
1247
+ <auro-counter-group isDropdown>
1248
+ <span slot="ariaLabel.bib.close">Close Popup</span>
1249
+ <div slot="bib.fullscreen.headline">Group fullscreen label</div>
1250
+ <div slot="label">Counter Group</div>
1251
+ <div slot="helpText">Select a value</div>
1252
+ <auro-counter>Counter 1</auro-counter>
1253
+ <auro-counter>Counter 2</auro-counter>
1254
+ </auro-counter-group>
1255
+ </div>
1256
+ </auro-dialog>
1257
+ </div>
1258
+ <!-- AURO-GENERATED-CONTENT:END -->
1259
+ </div>
1260
+ <auro-accordion alignRight>
1261
+ <span slot="trigger">See code</span>
1262
+ <!-- AURO-GENERATED-CONTENT:START (CODE:src=./../apiExamples/in-dialog.html) -->
1263
+ <!-- The below code snippet is automatically added from ./../apiExamples/in-dialog.html -->
1264
+
1265
+ ```html
1266
+ <div>
1267
+ <auro-button id="counter-dialog-opener">Counter Group in Dialog</auro-button>
1268
+ <auro-dialog id="counter-dialog">
1269
+ <span slot="header">Counter Group in Dialog</span>
1270
+ <div slot="content">
1271
+ <auro-counter-group isDropdown>
1272
+ <span slot="ariaLabel.bib.close">Close Popup</span>
1273
+ <div slot="bib.fullscreen.headline">Group fullscreen label</div>
1274
+ <div slot="label">Counter Group</div>
1275
+ <div slot="helpText">Select a value</div>
1276
+ <auro-counter>Counter 1</auro-counter>
1277
+ <auro-counter>Counter 2</auro-counter>
1278
+ </auro-counter-group>
1279
+ </div>
1280
+ </auro-dialog>
1281
+ </div>
1282
+ ```
1283
+ <!-- AURO-GENERATED-CONTENT:END -->
1284
+ <!-- AURO-GENERATED-CONTENT:START (CODE:src=./../apiExamples/in-dialog.js) -->
1285
+ <!-- The below code snippet is automatically added from ./../apiExamples/in-dialog.js -->
1286
+
1287
+ ```js
1288
+ export function inDialogExample() {
1289
+ document.querySelector("#counter-dialog-opener").addEventListener("click", () => {
1290
+ const dialog = document.querySelector("#counter-dialog");
1291
+ dialog.open = true;
1292
+ });
1293
+ };
1294
+ ```
1295
+ <!-- AURO-GENERATED-CONTENT:END -->
1296
+ </auro-accordion>
1297
+
1298
+ ### Counter Group in Drawer
1299
+
1300
+ The element used within an `auro-drawer`.
1301
+
1302
+ <div class="exampleWrapper">
1303
+ <!-- AURO-GENERATED-CONTENT:START (FILE:src=./../apiExamples/in-drawer.html) -->
1304
+ <!-- The below content is automatically added from ./../apiExamples/in-drawer.html -->
1305
+ <div>
1306
+ <auro-button id="counter-drawer-opener">Counter Group in Drawer</auro-button>
1307
+ <auro-drawer id="counter-drawer">
1308
+ <span slot="header">Counter Group in Drawer</span>
1309
+ <div slot="content">
1310
+ <auro-counter-group isDropdown>
1311
+ <span slot="ariaLabel.bib.close">Close Popup</span>
1312
+ <div slot="bib.fullscreen.headline">Group fullscreen label</div>
1313
+ <div slot="label">Counter Group</div>
1314
+ <div slot="helpText">Select a value</div>
1315
+ <auro-counter>Counter 1</auro-counter>
1316
+ <auro-counter>Counter 2</auro-counter>
1317
+ </auro-counter-group>
1318
+ </div>
1319
+ </auro-drawer>
1320
+ </div>
1321
+ <!-- AURO-GENERATED-CONTENT:END -->
1322
+ </div>
1323
+ <auro-accordion alignRight>
1324
+ <span slot="trigger">See code</span>
1325
+ <!-- AURO-GENERATED-CONTENT:START (CODE:src=./../apiExamples/in-drawer.html) -->
1326
+ <!-- The below code snippet is automatically added from ./../apiExamples/in-drawer.html -->
1327
+
1328
+ ```html
1329
+ <div>
1330
+ <auro-button id="counter-drawer-opener">Counter Group in Drawer</auro-button>
1331
+ <auro-drawer id="counter-drawer">
1332
+ <span slot="header">Counter Group in Drawer</span>
1333
+ <div slot="content">
1334
+ <auro-counter-group isDropdown>
1335
+ <span slot="ariaLabel.bib.close">Close Popup</span>
1336
+ <div slot="bib.fullscreen.headline">Group fullscreen label</div>
1337
+ <div slot="label">Counter Group</div>
1338
+ <div slot="helpText">Select a value</div>
1339
+ <auro-counter>Counter 1</auro-counter>
1340
+ <auro-counter>Counter 2</auro-counter>
1341
+ </auro-counter-group>
1342
+ </div>
1343
+ </auro-drawer>
1344
+ </div>
1345
+ ```
1346
+ <!-- AURO-GENERATED-CONTENT:END -->
1347
+ <!-- AURO-GENERATED-CONTENT:START (CODE:src=./../apiExamples/in-drawer.js) -->
1348
+ <!-- The below code snippet is automatically added from ./../apiExamples/in-drawer.js -->
1349
+
1350
+ ```js
1351
+ export function inDrawerExample() {
1352
+ document.querySelector("#counter-drawer-opener").addEventListener("click", () => {
1353
+ const drawer = document.querySelector("#counter-drawer");
1354
+ if (drawer.hasAttribute('open')) {
1355
+ drawer.removeAttribute('open');
1356
+ } else {
1357
+ drawer.setAttribute('open', true);
1358
+ }
1359
+ });
1360
+ };
1361
+ ```
1362
+ <!-- AURO-GENERATED-CONTENT:END -->
1363
+ </auro-accordion>
1364
+
1235
1365
  ## Restyle Component with CSS Variables
1236
1366
 
1237
1367
  The component may be restyled by changing the values of the following token(s).