@aurodesignsystem-dev/auro-formkit 0.0.0-pr1483.1 → 0.0.0-pr1483.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.
Files changed (52) 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/dist/index.js +1 -1
  5. package/components/checkbox/dist/registered.js +1 -1
  6. package/components/combobox/demo/customize.min.js +5 -5
  7. package/components/combobox/demo/getting-started.min.js +5 -5
  8. package/components/combobox/demo/index.min.js +5 -5
  9. package/components/combobox/demo/keyboard-behavior.md +68 -8
  10. package/components/combobox/dist/index.js +5 -5
  11. package/components/combobox/dist/registered.js +5 -5
  12. package/components/counter/demo/customize.min.js +2 -2
  13. package/components/counter/demo/index.min.js +2 -2
  14. package/components/counter/dist/index.js +1 -1
  15. package/components/counter/dist/registered.js +1 -1
  16. package/components/datepicker/demo/api.md +52 -51
  17. package/components/datepicker/demo/customize.md +52 -15
  18. package/components/datepicker/demo/index.md +23 -0
  19. package/components/datepicker/demo/index.min.js +5067 -1043
  20. package/components/datepicker/dist/index.js +4585 -561
  21. package/components/datepicker/dist/registered.js +4585 -561
  22. package/components/datepicker/dist/src/auro-calendar-cell.d.ts +3 -1
  23. package/components/datepicker/dist/src/auro-calendar-month.d.ts +23 -0
  24. package/components/datepicker/dist/src/auro-calendar.d.ts +15 -0
  25. package/components/datepicker/dist/src/auro-datepicker.d.ts +27 -13
  26. package/components/datepicker/dist/src/utilities.d.ts +0 -20
  27. package/components/datepicker/dist/src/utilitiesCalendar.d.ts +0 -1
  28. package/components/dropdown/demo/customize.min.js +1 -1
  29. package/components/dropdown/demo/getting-started.min.js +1 -1
  30. package/components/dropdown/demo/index.min.js +1 -1
  31. package/components/dropdown/dist/index.js +1 -1
  32. package/components/dropdown/dist/registered.js +1 -1
  33. package/components/form/demo/customize.min.js +5145 -1119
  34. package/components/form/demo/getting-started.min.js +5145 -1119
  35. package/components/form/demo/index.min.js +5145 -1119
  36. package/components/form/demo/registerDemoDeps.min.js +5145 -1119
  37. package/components/input/demo/customize.min.js +1 -1
  38. package/components/input/demo/getting-started.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/radio/demo/index.min.js +1 -1
  43. package/components/radio/dist/index.js +1 -1
  44. package/components/radio/dist/registered.js +1 -1
  45. package/components/select/demo/customize.min.js +20 -18
  46. package/components/select/demo/getting-started.min.js +20 -18
  47. package/components/select/demo/index.min.js +20 -18
  48. package/components/select/demo/keyboard-behavior.md +54 -8
  49. package/components/select/dist/index.js +20 -18
  50. package/components/select/dist/registered.js +20 -18
  51. package/custom-elements.json +131 -116
  52. package/package.json +3 -3
@@ -19,7 +19,7 @@
19
19
  <auro-anchorlink fluid href="#customValidation" class="level2 body-xs">Custom Validation</auro-anchorlink>
20
20
  <auro-anchorlink fluid href="#noValidate" class="level2 body-xs">No Validation</auro-anchorlink>
21
21
  <auro-anchorlink fluid href="#minMaxDate" class="level2 body-xs">Min/Max Date</auro-anchorlink>
22
- <auro-anchorlink fluid href="#localization" class="level2 body-xs">Localization</auro-anchorlink>
22
+ <auro-anchorlink fluid href="#regionalDate" class="level2 body-xs">Regional Date</auro-anchorlink>
23
23
  </auro-nav>
24
24
  </nav>
25
25
  <div class="mainContent">
@@ -694,27 +694,64 @@
694
694
  <!-- AURO-GENERATED-CONTENT:END -->
695
695
  </auro-accordion>
696
696
  <auro-header level="3" id="localization">Localization</auro-header>
697
- <p>Use the <code>centralDate</code>, locale, and related attributes to configure the datepicker for different regions and languages.</p>
697
+ <auro-header level="4" id="regionalDate">Regional Date</auro-header>
698
+ <p>When the <code>locale</code> attribute is set, the component automatically derives the correct date format for that region — no need to set <code>format</code> manually. For example, <code>locale="en-US"</code> produces <code>mm/dd/yyyy</code>, <code>locale="de-DE"</code> produces <code>dd.mm.yyyy</code>, and <code>locale="ja-JP"</code> produces <code>yyyy/mm/dd</code>.</p>
699
+ <p>If <code>format</code> is explicitly set alongside <code>locale</code>, <code>format</code> always wins. Use this when a specific format is required regardless of region.</p>
700
+ <p>If no <code>locale</code> attribute is set on the element, the component walks up the DOM looking for the nearest ancestor with a <code>data-locale</code> attribute and uses that value. If none is found, it defaults to <code>en-US</code>.</p>
698
701
  <div class="exampleWrapper">
699
- <!-- AURO-GENERATED-CONTENT:START (FILE:src=./../apiExamples/localization.html) -->
700
- <!-- The below content is automatically added from ./../apiExamples/localization.html -->
701
- <auro-datepicker format="yyyy/mm/dd" id="localizationExample">
702
- <span slot="bib.fullscreen.headline">Localization Headline</span>
703
- <span slot="fromLabel">Choose a date</span>
704
- <span slot="bib.fullscreen.fromLabel">Choose a date</span>
702
+ <!-- AURO-GENERATED-CONTENT:START (FILE:src=./../apiExamples/locale.html) -->
703
+ <!-- The below content is automatically added from ./../apiExamples/locale.html -->
704
+ <div data-locale="de-DE">
705
+ <auro-datepicker locale="en-US">
706
+ <span slot="fromLabel">en-US Date</span>
707
+ <span slot="helpText">Help Text</span>
708
+ </auro-datepicker>
709
+ <auro-datepicker locale="de-DE">
710
+ <span slot="fromLabel">de-DE Date</span>
711
+ <span slot="helpText">Help Text</span>
712
+ </auro-datepicker>
713
+ <auro-datepicker locale="zh-CN">
714
+ <span slot="fromLabel">zh-CN Date</span>
715
+ <span slot="helpText">Help Text</span>
716
+ </auro-datepicker>
717
+ <auro-datepicker>
718
+ <span slot="fromLabel">Nearest `data-locale` attribute format (`de-DE` in this case)</span>
719
+ <span slot="helpText">Help Text</span>
720
+ </auro-datepicker>
721
+ <auro-datepicker locale="ja-JP" format="mm/dd/yyyy">
722
+ <span slot="fromLabel">ja-JP locale with explicit mm/dd/yyyy format</span>
723
+ <span slot="helpText">Help Text</span>
705
724
  </auro-datepicker>
725
+ </div>
706
726
  <!-- AURO-GENERATED-CONTENT:END -->
707
727
  </div>
708
728
  <auro-accordion alignRight>
709
729
  <span slot="trigger">See code</span>
710
- <!-- AURO-GENERATED-CONTENT:START (CODE:src=./../apiExamples/localization.html) -->
711
- <!-- The below code snippet is automatically added from ./../apiExamples/localization.html -->
730
+ <!-- AURO-GENERATED-CONTENT:START (CODE:src=./../apiExamples/locale.html) -->
731
+ <!-- The below code snippet is automatically added from ./../apiExamples/locale.html -->
712
732
 
713
- <pre class="language-html"><code class="language-html">&lt;auro-datepicker format="yyyy/mm/dd" id="localizationExample"&gt;
714
- &lt;span slot="bib.fullscreen.headline"&gt;Localization Headline&lt;/span&gt;
715
- &lt;span slot="fromLabel"&gt;Choose a date&lt;/span&gt;
716
- &lt;span slot="bib.fullscreen.fromLabel"&gt;Choose a date&lt;/span&gt;
717
- &lt;/auro-datepicker&gt;</code></pre>
733
+ <pre class="language-html"><code class="language-html">&lt;div data-locale="de-DE"&gt;
734
+ &lt;auro-datepicker locale="en-US"&gt;
735
+ &lt;span slot="fromLabel"&gt;en-US Date&lt;/span&gt;
736
+ &lt;span slot="helpText"&gt;Help Text&lt;/span&gt;
737
+ &lt;/auro-datepicker&gt;
738
+ &lt;auro-datepicker locale="de-DE"&gt;
739
+ &lt;span slot="fromLabel"&gt;de-DE Date&lt;/span&gt;
740
+ &lt;span slot="helpText"&gt;Help Text&lt;/span&gt;
741
+ &lt;/auro-datepicker&gt;
742
+ &lt;auro-datepicker locale="zh-CN"&gt;
743
+ &lt;span slot="fromLabel"&gt;zh-CN Date&lt;/span&gt;
744
+ &lt;span slot="helpText"&gt;Help Text&lt;/span&gt;
745
+ &lt;/auro-datepicker&gt;
746
+ &lt;auro-datepicker&gt;
747
+ &lt;span slot="fromLabel"&gt;Nearest `data-locale` attribute format (`de-DE` in this case)&lt;/span&gt;
748
+ &lt;span slot="helpText"&gt;Help Text&lt;/span&gt;
749
+ &lt;/auro-datepicker&gt;
750
+ &lt;auro-datepicker locale="ja-JP" format="mm/dd/yyyy"&gt;
751
+ &lt;span slot="fromLabel"&gt;ja-JP locale with explicit mm/dd/yyyy format&lt;/span&gt;
752
+ &lt;span slot="helpText"&gt;Help Text&lt;/span&gt;
753
+ &lt;/auro-datepicker&gt;
754
+ &lt;/div&gt;</code></pre>
718
755
  <!-- AURO-GENERATED-CONTENT:END -->
719
756
  </auro-accordion>
720
757
  </section>
@@ -10,6 +10,7 @@
10
10
  <auro-anchorlink fluid href="#selectRange" class="level2 body-xs">Select a Range</auro-anchorlink>
11
11
  <auro-anchorlink fluid href="#presetValue" class="level2 body-xs">Preset Value</auro-anchorlink>
12
12
  <auro-anchorlink fluid href="#skipSelection" class="level2 body-xs">Skip Selection</auro-anchorlink>
13
+ <auro-anchorlink fluid href="#regionalDateFormat" class="level2 body-xs">Regional Date</auro-anchorlink>
13
14
  <auro-anchorlink fluid href="#viewportSize" class="level2 body-xs">Viewport Size</auro-anchorlink>
14
15
  </auro-nav>
15
16
  </nav>
@@ -167,6 +168,28 @@
167
168
  <auro-header level="3" id="skipSelection">Skip selection</auro-header>
168
169
  <p>The datepicker does not force the user to select a date. If no selection is made and the field is not <code>required</code>, the user can move past the datepicker without entering a value.</p>
169
170
  <p>If the field is <code>required</code>, moving focus away without selecting a date triggers validation and renders the <code>valueMissing</code> error state.</p>
171
+ <auro-header level="3" id="regionalDateFormat">Regional date format support</auro-header>
172
+ <p>People around the world write dates differently. A traveler in the United States expects to see <strong>12/25/2025</strong>, while someone in Germany expects <strong>25.12.2025</strong>, and someone in Japan expects <strong>2025/12/25</strong>. Showing the wrong format causes confusion and mistakes.</p>
173
+ <p>When the datepicker knows the user's region via the <code>locale</code> attribute, it automatically displays dates in the format that looks natural to them — no extra setup required.</p>
174
+ <div class="exampleWrapper">
175
+ <!-- AURO-GENERATED-CONTENT:START (FILE:src=./../apiExamples/locale-single.html) -->
176
+ <!-- The below content is automatically added from ./../apiExamples/locale-single.html -->
177
+ <auro-datepicker locale="zh-CN">
178
+ <span slot="fromLabel">zh-CN Date</span>
179
+ <span slot="helpText">Help Text</span>
180
+ </auro-datepicker>
181
+ <!-- AURO-GENERATED-CONTENT:END -->
182
+ </div>
183
+ <auro-accordion alignRight>
184
+ <span slot="trigger">See code</span>
185
+ <!-- AURO-GENERATED-CONTENT:START (CODE:src=./../apiExamples/locale-single.html) -->
186
+ <!-- The below code snippet is automatically added from ./../apiExamples/locale-single.html -->
187
+ <pre class="language-html"><code class="language-html">&lt;auro-datepicker locale="zh-CN"&gt;
188
+ &lt;span slot="fromLabel"&gt;zh-CN Date&lt;/span&gt;
189
+ &lt;span slot="helpText"&gt;Help Text&lt;/span&gt;
190
+ &lt;/auro-datepicker&gt;</code></pre>
191
+ <!-- AURO-GENERATED-CONTENT:END -->
192
+ </auro-accordion>
170
193
  <auro-header level="3" id="viewportSize">Viewport size</auro-header>
171
194
  <p>The datepicker automatically adapts its presentation based on viewport size. On larger screens, the calendar opens in a floating popover anchored to the trigger. On smaller screens, the calendar opens in a fullscreen dialog.</p>
172
195
  <p>The breakpoint at which the fullscreen behavior activates is controlled by the <code>fullscreenBreakpoint</code> attribute. The default value is <code>sm</code>. Supported values are <code>xs</code>, <code>sm</code>, <code>md</code>, <code>lg</code>, <code>xl</code>, and <code>disabled</code>.</p>