@aurodesignsystem-dev/auro-formkit 0.0.0-pr1475.4 → 0.0.0-pr1475.6

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (81) hide show
  1. package/components/checkbox/demo/customize.min.js +1 -1
  2. package/components/checkbox/demo/getting-started.min.js +1 -1
  3. package/components/checkbox/demo/index.min.js +1 -1
  4. package/components/checkbox/demo/pages.json +1 -1
  5. package/components/checkbox/demo/why-checkbox.html +57 -0
  6. package/components/checkbox/demo/why-checkbox.md +86 -0
  7. package/components/checkbox/dist/index.js +1 -1
  8. package/components/checkbox/dist/registered.js +1 -1
  9. package/components/combobox/demo/customize.min.js +10 -8
  10. package/components/combobox/demo/getting-started.min.js +10 -8
  11. package/components/combobox/demo/index.min.js +10 -8
  12. package/components/combobox/demo/pages.json +1 -1
  13. package/components/combobox/demo/why-combobox.html +57 -0
  14. package/components/combobox/demo/why-combobox.md +113 -0
  15. package/components/combobox/dist/index.js +10 -8
  16. package/components/combobox/dist/registered.js +10 -8
  17. package/components/counter/demo/customize.min.js +9 -7
  18. package/components/counter/demo/index.min.js +9 -7
  19. package/components/counter/demo/pages.json +1 -1
  20. package/components/counter/demo/why-counter.html +57 -0
  21. package/components/counter/demo/why-counter.md +108 -0
  22. package/components/counter/dist/index.js +441 -45
  23. package/components/counter/dist/registered.js +1 -1
  24. package/components/datepicker/demo/api.md +2 -2
  25. package/components/datepicker/demo/customize.min.js +259 -41
  26. package/components/datepicker/demo/index.md +2 -1
  27. package/components/datepicker/demo/index.min.js +259 -41
  28. package/components/datepicker/demo/pages.json +1 -1
  29. package/components/datepicker/demo/voiceover.md +5 -5
  30. package/components/datepicker/demo/why-datepicker.html +57 -0
  31. package/components/datepicker/demo/why-datepicker.md +133 -0
  32. package/components/datepicker/dist/index.js +259 -41
  33. package/components/datepicker/dist/registered.js +259 -41
  34. package/components/datepicker/dist/src/auro-calendar-cell.d.ts +2 -0
  35. package/components/datepicker/dist/src/auro-calendar.d.ts +17 -1
  36. package/components/datepicker/dist/src/auro-datepicker.d.ts +8 -0
  37. package/components/dropdown/demo/customize.min.js +8 -6
  38. package/components/dropdown/demo/getting-started.min.js +8 -6
  39. package/components/dropdown/demo/index.min.js +8 -6
  40. package/components/dropdown/demo/pages.json +1 -1
  41. package/components/dropdown/demo/why-dropdown.html +57 -0
  42. package/components/dropdown/demo/why-dropdown.md +97 -0
  43. package/components/dropdown/dist/auro-dropdown.d.ts +3 -1
  44. package/components/dropdown/dist/index.js +8 -6
  45. package/components/dropdown/dist/registered.js +8 -6
  46. package/components/form/demo/customize.min.js +1218 -994
  47. package/components/form/demo/getting-started.min.js +1218 -994
  48. package/components/form/demo/index.min.js +1218 -994
  49. package/components/form/demo/pages.json +1 -1
  50. package/components/form/demo/registerDemoDeps.min.js +1130 -906
  51. package/components/form/demo/why-form.html +57 -0
  52. package/components/form/demo/why-form.md +101 -0
  53. package/components/input/demo/customize.min.js +1 -1
  54. package/components/input/demo/getting-started.min.js +1 -1
  55. package/components/input/demo/index.min.js +1 -1
  56. package/components/input/demo/pages.json +1 -1
  57. package/components/input/demo/why-input.html +57 -0
  58. package/components/input/demo/why-input.md +121 -0
  59. package/components/input/dist/index.js +1 -1
  60. package/components/input/dist/registered.js +1 -1
  61. package/components/menu/demo/pages.json +1 -1
  62. package/components/menu/demo/why-menu.html +57 -0
  63. package/components/menu/demo/why-menu.md +104 -0
  64. package/components/radio/demo/customize.min.js +1 -1
  65. package/components/radio/demo/getting-started.min.js +1 -1
  66. package/components/radio/demo/index.min.js +1 -1
  67. package/components/radio/demo/pages.json +1 -1
  68. package/components/radio/demo/why-radio.html +57 -0
  69. package/components/radio/demo/why-radio.md +92 -0
  70. package/components/radio/dist/index.js +1 -1
  71. package/components/radio/dist/registered.js +1 -1
  72. package/components/select/demo/customize.min.js +9 -7
  73. package/components/select/demo/getting-started.min.js +9 -7
  74. package/components/select/demo/index.min.js +9 -7
  75. package/components/select/demo/pages.json +1 -1
  76. package/components/select/demo/why-select.html +57 -0
  77. package/components/select/demo/why-select.md +128 -0
  78. package/components/select/dist/index.js +9 -7
  79. package/components/select/dist/registered.js +9 -7
  80. package/custom-elements.json +1521 -1476
  81. package/package.json +2 -2
@@ -5211,7 +5211,7 @@ let AuroHelpText$2 = class AuroHelpText extends LitElement {
5211
5211
  }
5212
5212
  };
5213
5213
 
5214
- var formkitVersion$2 = '202605190056';
5214
+ var formkitVersion$2 = '202605201522';
5215
5215
 
5216
5216
  let AuroElement$2 = class AuroElement extends LitElement {
5217
5217
  static get properties() {
@@ -6208,9 +6208,9 @@ class AuroDropdown extends AuroElement$2 {
6208
6208
  while (current.parentElement) {
6209
6209
  const parent = current.parentElement;
6210
6210
  for (const sibling of parent.children) {
6211
- if (sibling !== current && !sibling.inert) {
6211
+ if (sibling !== current) {
6212
+ this._inertSiblings.push({ element: sibling, wasInert: sibling.inert });
6212
6213
  sibling.inert = true;
6213
- this._inertSiblings.push(sibling);
6214
6214
  }
6215
6215
  }
6216
6216
  current = parent;
@@ -6218,13 +6218,15 @@ class AuroDropdown extends AuroElement$2 {
6218
6218
  }
6219
6219
 
6220
6220
  /**
6221
- * Restores `inert` state on siblings that were made inert by `_setPageInert`.
6221
+ * Restores `inert` state on siblings that were tracked by `_setPageInert`.
6222
+ * Preserves the previous inert state so externally-inerted elements are
6223
+ * not inadvertently re-enabled.
6222
6224
  * @private
6223
6225
  */
6224
6226
  _clearPageInert() {
6225
6227
  if (this._inertSiblings) {
6226
- for (const sibling of this._inertSiblings) {
6227
- sibling.inert = false;
6228
+ for (const entry of this._inertSiblings) {
6229
+ entry.element.inert = entry.wasInert;
6228
6230
  }
6229
6231
  this._inertSiblings = undefined;
6230
6232
  }
@@ -13164,7 +13166,7 @@ let AuroHelpText$1 = class AuroHelpText extends LitElement {
13164
13166
  }
13165
13167
  };
13166
13168
 
13167
- var formkitVersion$1 = '202605190056';
13169
+ var formkitVersion$1 = '202605201522';
13168
13170
 
13169
13171
  // Copyright (c) 2025 Alaska Airlines. All right reserved. Licensed under the Apache-2.0 license
13170
13172
  // See LICENSE in the project root for license information.
@@ -14237,7 +14239,7 @@ class AuroBibtemplate extends LitElement {
14237
14239
  }
14238
14240
  }
14239
14241
 
14240
- var formkitVersion = '202605190056';
14242
+ var formkitVersion = '202605201522';
14241
14243
 
14242
14244
  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}`;
14243
14245
 
@@ -1521,7 +1521,7 @@ let AuroHelpText$1 = class AuroHelpText extends i$2 {
1521
1521
  }
1522
1522
  };
1523
1523
 
1524
- var formkitVersion$1 = '202605190056';
1524
+ var formkitVersion$1 = '202605201522';
1525
1525
 
1526
1526
  // Copyright (c) 2026 Alaska Airlines. All rights reserved. Licensed under the Apache-2.0 license
1527
1527
  // See LICENSE in the project root for license information.
@@ -5867,7 +5867,7 @@ class AuroHelpText extends i$2 {
5867
5867
  }
5868
5868
  }
5869
5869
 
5870
- var formkitVersion = '202605190056';
5870
+ var formkitVersion = '202605201522';
5871
5871
 
5872
5872
  let AuroElement$1 = class AuroElement extends i$2 {
5873
5873
  static get properties() {
@@ -6864,9 +6864,9 @@ class AuroDropdown extends AuroElement$1 {
6864
6864
  while (current.parentElement) {
6865
6865
  const parent = current.parentElement;
6866
6866
  for (const sibling of parent.children) {
6867
- if (sibling !== current && !sibling.inert) {
6867
+ if (sibling !== current) {
6868
+ this._inertSiblings.push({ element: sibling, wasInert: sibling.inert });
6868
6869
  sibling.inert = true;
6869
- this._inertSiblings.push(sibling);
6870
6870
  }
6871
6871
  }
6872
6872
  current = parent;
@@ -6874,13 +6874,15 @@ class AuroDropdown extends AuroElement$1 {
6874
6874
  }
6875
6875
 
6876
6876
  /**
6877
- * Restores `inert` state on siblings that were made inert by `_setPageInert`.
6877
+ * Restores `inert` state on siblings that were tracked by `_setPageInert`.
6878
+ * Preserves the previous inert state so externally-inerted elements are
6879
+ * not inadvertently re-enabled.
6878
6880
  * @private
6879
6881
  */
6880
6882
  _clearPageInert() {
6881
6883
  if (this._inertSiblings) {
6882
- for (const sibling of this._inertSiblings) {
6883
- sibling.inert = false;
6884
+ for (const entry of this._inertSiblings) {
6885
+ entry.element.inert = entry.wasInert;
6884
6886
  }
6885
6887
  this._inertSiblings = undefined;
6886
6888
  }
@@ -1521,7 +1521,7 @@ let AuroHelpText$1 = class AuroHelpText extends i$2 {
1521
1521
  }
1522
1522
  };
1523
1523
 
1524
- var formkitVersion$1 = '202605190056';
1524
+ var formkitVersion$1 = '202605201522';
1525
1525
 
1526
1526
  // Copyright (c) 2026 Alaska Airlines. All rights reserved. Licensed under the Apache-2.0 license
1527
1527
  // See LICENSE in the project root for license information.
@@ -5867,7 +5867,7 @@ class AuroHelpText extends i$2 {
5867
5867
  }
5868
5868
  }
5869
5869
 
5870
- var formkitVersion = '202605190056';
5870
+ var formkitVersion = '202605201522';
5871
5871
 
5872
5872
  let AuroElement$1 = class AuroElement extends i$2 {
5873
5873
  static get properties() {
@@ -6864,9 +6864,9 @@ class AuroDropdown extends AuroElement$1 {
6864
6864
  while (current.parentElement) {
6865
6865
  const parent = current.parentElement;
6866
6866
  for (const sibling of parent.children) {
6867
- if (sibling !== current && !sibling.inert) {
6867
+ if (sibling !== current) {
6868
+ this._inertSiblings.push({ element: sibling, wasInert: sibling.inert });
6868
6869
  sibling.inert = true;
6869
- this._inertSiblings.push(sibling);
6870
6870
  }
6871
6871
  }
6872
6872
  current = parent;
@@ -6874,13 +6874,15 @@ class AuroDropdown extends AuroElement$1 {
6874
6874
  }
6875
6875
 
6876
6876
  /**
6877
- * Restores `inert` state on siblings that were made inert by `_setPageInert`.
6877
+ * Restores `inert` state on siblings that were tracked by `_setPageInert`.
6878
+ * Preserves the previous inert state so externally-inerted elements are
6879
+ * not inadvertently re-enabled.
6878
6880
  * @private
6879
6881
  */
6880
6882
  _clearPageInert() {
6881
6883
  if (this._inertSiblings) {
6882
- for (const sibling of this._inertSiblings) {
6883
- sibling.inert = false;
6884
+ for (const entry of this._inertSiblings) {
6885
+ entry.element.inert = entry.wasInert;
6884
6886
  }
6885
6887
  this._inertSiblings = undefined;
6886
6888
  }
@@ -1 +1 @@
1
- ["accessibility.md","api.md","customize.md","design.md","getting-started.md","index.md","keyboard-behavior.md","voiceover.md","readme.md"]
1
+ ["accessibility.md","api.md","customize.md","design.md","getting-started.md","index.md","keyboard-behavior.md","voiceover.md","why-counter.md","readme.md"]
@@ -0,0 +1,57 @@
1
+ <!--
2
+ Copyright (c) Alaska Air. All right reserved. Licensed under the Apache-2.0 license
3
+ See LICENSE in the project root for license information.
4
+
5
+ HTML in this document is standardized and NOT to be edited.
6
+ All demo code should be added/edited in ./demo/why-counter.md
7
+
8
+ With the exception of adding custom elements if needed for the demo.
9
+
10
+ ----------------------- DO NOT EDIT -----------------------------
11
+
12
+ -->
13
+
14
+ <!DOCTYPE html>
15
+ <html lang="en">
16
+ <head>
17
+ <meta charset="UTF-8" />
18
+ <meta name="viewport" content="width=device-width, initial-scale=1.0" />
19
+ <title>Auro Web Component Demo | auro-counter | Why auro-counter</title>
20
+
21
+ <!-- highlight.js Stylesheet -->
22
+ <link rel="stylesheet" type="text/css" href="https://cdn.jsdelivr.net/gh/highlightjs/cdn-release@11.9.0/build/styles/github.min.css"/>
23
+
24
+ <!-- Legacy reference is still needed to support auro-counter's use of legacy token values at this time -->
25
+ <link rel="stylesheet" type="text/css" href="https://cdn.jsdelivr.net/npm/@aurodesignsystem/design-tokens@latest/dist/legacy/auro-classic/CSSCustomProperties.css"/>
26
+
27
+ <!-- Design Token Alaska Theme -->
28
+ <link rel="stylesheet" type="text/css" href="https://cdn.jsdelivr.net/npm/@aurodesignsystem/design-tokens@latest/dist/themes/alaska/CSSCustomProperties--alaska.min.css"/>
29
+
30
+ <!-- Webcore Stylesheet Alaska Theme -->
31
+ <link rel="stylesheet" type="text/css" href="https://cdn.jsdelivr.net/npm/@aurodesignsystem/webcorestylesheets@latest/dist/bundled/themes/alaska.global.min.css" />
32
+
33
+ <!-- Demo Specific Styles -->
34
+ <link rel="stylesheet" type="text/css" href="./styles.min.css" />
35
+ <style>
36
+ table {
37
+ --ds-color-container-secondary-default: transparent;
38
+ }
39
+
40
+ tr:not(:last-of-type) {
41
+ border-bottom: 1px solid var(--ds-color-border-tertiary-default);
42
+ }
43
+ </style>
44
+ </head>
45
+ <body class="auro-markdown">
46
+ <main></main>
47
+
48
+ <script type="module">
49
+ import { renderPage } from './demo-support.min.js';
50
+ await renderPage('./why-counter.md');
51
+ </script>
52
+
53
+ <!-- If additional elements are needed for the demo, add them here. -->
54
+ <script src="https://cdn.jsdelivr.net/npm/@aurodesignsystem/auro-header@latest/+esm" type="module"></script>
55
+ <script src="https://cdn.jsdelivr.net/npm/@aurodesignsystem/auro-hyperlink@latest/+esm" type="module"></script>
56
+ </body>
57
+ </html>
@@ -0,0 +1,108 @@
1
+ <auro-header level="1" id="overview">Why auro-counter?</auro-header>
2
+ <p>The native <code>&lt;input type="number"&gt;</code> provides a basic numeric input, but it lacks the spinbutton accessibility pattern, has no concept of grouped counters with shared constraints, and renders inconsistently across browsers. <code>auro-counter</code> and <code>auro-counter-group</code> provide an accessible, feature-rich alternative.</p>
3
+ <auro-header level="2" id="accessibility">Accessibility</auro-header>
4
+ <p>Native number inputs have limited screen reader support. The browser-rendered increment/decrement buttons are often small, difficult to interact with, and announced inconsistently.</p>
5
+ <p><code>auro-counter</code> provides:</p>
6
+ <ul>
7
+ <li><strong>ARIA spinbutton pattern</strong> — The component uses <code>role="spinbutton"</code> with <code>aria-valuemin</code>, <code>aria-valuemax</code>, <code>aria-valuenow</code>, and <code>aria-valuetext</code> for complete screen reader semantics.</li>
8
+ <li><strong>Labeled controls</strong> — Increment and decrement buttons have customizable ARIA labels via <code>ariaLabel.plus</code> and <code>ariaLabel.minus</code> slots.</li>
9
+ <li><strong>Keyboard shortcuts</strong> — Arrow Up/Down, Ctrl+Arrow, and +/- keys all increment and decrement the value. These shortcuts go beyond what native number inputs provide.</li>
10
+ <li><strong>Focus delegation</strong> — <code>delegatesFocus</code> ensures focus reaches the interactive control regardless of where the user clicks.</li>
11
+ <li><strong>Description binding</strong> — The <code>description</code> slot content is linked via <code>aria-describedByElements</code> for additional context.</li>
12
+ </ul>
13
+ <auro-header level="2" id="smartButtonState">Smart button state</auro-header>
14
+ <p>Native number inputs allow the user to type or spin past the min/max bounds, then rely on validation to catch the error.</p>
15
+ <p><code>auro-counter</code> takes a proactive approach:</p>
16
+ <ul>
17
+ <li>The decrement button disables automatically at <code>min</code></li>
18
+ <li>The increment button disables automatically at <code>max</code></li>
19
+ <li>In a group, buttons disable based on the aggregate total, preventing any individual counter from pushing the group past its constraints</li>
20
+ </ul>
21
+ <auro-header level="2" id="counterGroups">Counter groups</auro-header>
22
+ <p>HTML has no concept of related numeric inputs with a shared constraint. For example, a passenger selector with "Adults", "Children", and "Infants" that must total no more than 9 requires custom JavaScript.</p>
23
+ <p><code>auro-counter-group</code> handles this with:</p>
24
+ <ul>
25
+ <li>An aggregate <code>total</code> computed from all child counters</li>
26
+ <li>Group-level <code>min</code> and <code>max</code> constraints applied across all children</li>
27
+ <li>A <code>value</code> object with named entries (e.g., <code>{ adults: 2, children: 1 }</code>)</li>
28
+ <li>Dynamic button disabling — when the group total reaches max, all increment buttons disable; when it reaches min, all decrement buttons disable</li>
29
+ <li>Group-level validation that aggregates individual counter errors</li>
30
+ <li>Optional dropdown presentation with <code>isDropdown</code> for compact UI</li>
31
+ </ul>
32
+ <auro-header level="2" id="responsiveLayout">Responsive layout</auro-header>
33
+ <p>Native number inputs have no concept of responsive presentation.</p>
34
+ <p><code>auro-counter-group</code> in dropdown mode adapts to the viewport:</p>
35
+ <ul>
36
+ <li><strong>Desktop</strong> — Counters appear in a positioned dropdown panel</li>
37
+ <li><strong>Mobile</strong> — Counters open in a fullscreen dialog with a configurable breakpoint</li>
38
+ <li>Layout options (classic, snowflake) control visual presentation</li>
39
+ </ul>
40
+ <auro-header level="2" id="validation">Validation</auro-header>
41
+ <p>Native number input validation is limited to <code>min</code>, <code>max</code>, <code>step</code>, and <code>required</code>.</p>
42
+ <p><code>auro-counter</code> integrates with the Auro form validation system:</p>
43
+ <ul>
44
+ <li>Group-level validation aggregates errors from all child counters</li>
45
+ <li><code>touched</code> tracking ensures errors appear only after interaction</li>
46
+ <li>Dispatches <code>auroFormElement-validated</code> events for parent form coordination</li>
47
+ </ul>
48
+ <auro-header level="2" id="designSystemIntegration">Design system integration</auro-header>
49
+ <p>Native number inputs render browser-specific controls that cannot be styled consistently.</p>
50
+ <p><code>auro-counter</code> is built with the Auro Design System:</p>
51
+ <ul>
52
+ <li>Consistent visual language with clearly labeled +/- buttons</li>
53
+ <li>Light and dark theme support (<code>appearance</code>)</li>
54
+ <li>CSS <code>::part()</code> selectors (<code>counterControl</code>, <code>controlPlus</code>, <code>controlMinus</code>, <code>helpText</code>)</li>
55
+ <li>Design token integration for sizing and spacing</li>
56
+ </ul>
57
+ <auro-header level="2" id="summary">Summary</auro-header>
58
+ <table>
59
+ <thead>
60
+ <tr>
61
+ <th>Capability</th>
62
+ <th><code>&lt;input type="number"&gt;</code></th>
63
+ <th><code>auro-counter</code></th>
64
+ </tr>
65
+ </thead>
66
+ <tbody>
67
+ <tr>
68
+ <td>ARIA spinbutton semantics</td>
69
+ <td>No</td>
70
+ <td>Full implementation</td>
71
+ </tr>
72
+ <tr>
73
+ <td>Auto-disable at min/max</td>
74
+ <td>No</td>
75
+ <td>Yes</td>
76
+ </tr>
77
+ <tr>
78
+ <td>Grouped counters with shared max</td>
79
+ <td>Not supported</td>
80
+ <td>Built-in with <code>auro-counter-group</code></td>
81
+ </tr>
82
+ <tr>
83
+ <td>Aggregate value object</td>
84
+ <td>Not supported</td>
85
+ <td><code>{ name: value }</code> pairs</td>
86
+ </tr>
87
+ <tr>
88
+ <td>Keyboard shortcuts</td>
89
+ <td>Arrow keys only</td>
90
+ <td>Arrows, Ctrl+Arrows, +/-</td>
91
+ </tr>
92
+ <tr>
93
+ <td>Mobile fullscreen (group)</td>
94
+ <td>No</td>
95
+ <td>Automatic at breakpoint</td>
96
+ </tr>
97
+ <tr>
98
+ <td>Consistent cross-browser UI</td>
99
+ <td>No</td>
100
+ <td>Yes</td>
101
+ </tr>
102
+ <tr>
103
+ <td>Theming</td>
104
+ <td>Browser-dependent</td>
105
+ <td>Full design system integration</td>
106
+ </tr>
107
+ </tbody>
108
+ </table>