@aurodesignsystem-dev/auro-formkit 0.0.0-pr1554.8 → 0.0.0-pr1555.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 (45) 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 +45 -150
  7. package/components/combobox/demo/getting-started.min.js +45 -150
  8. package/components/combobox/demo/index.min.js +45 -150
  9. package/components/combobox/dist/index.js +45 -150
  10. package/components/combobox/dist/registered.js +45 -150
  11. package/components/counter/demo/customize.min.js +6 -47
  12. package/components/counter/demo/index.min.js +6 -47
  13. package/components/counter/dist/index.js +6 -47
  14. package/components/counter/dist/registered.js +6 -47
  15. package/components/datepicker/demo/customize.min.js +20 -89
  16. package/components/datepicker/demo/index.min.js +20 -89
  17. package/components/datepicker/dist/index.js +20 -89
  18. package/components/datepicker/dist/registered.js +20 -89
  19. package/components/dropdown/demo/customize.min.js +5 -46
  20. package/components/dropdown/demo/getting-started.min.js +5 -46
  21. package/components/dropdown/demo/index.min.js +5 -46
  22. package/components/dropdown/dist/auro-dropdown.d.ts +1 -8
  23. package/components/dropdown/dist/index.js +5 -46
  24. package/components/dropdown/dist/registered.js +5 -46
  25. package/components/form/demo/customize.min.js +90 -374
  26. package/components/form/demo/getting-started.min.js +90 -374
  27. package/components/form/demo/index.min.js +90 -374
  28. package/components/form/demo/registerDemoDeps.min.js +90 -374
  29. package/components/input/demo/customize.min.js +11 -39
  30. package/components/input/demo/getting-started.min.js +11 -39
  31. package/components/input/demo/index.min.js +11 -39
  32. package/components/input/dist/index.js +11 -39
  33. package/components/input/dist/registered.js +11 -39
  34. package/components/radio/demo/customize.min.js +1 -1
  35. package/components/radio/demo/getting-started.min.js +1 -1
  36. package/components/radio/demo/index.min.js +1 -1
  37. package/components/radio/dist/index.js +1 -1
  38. package/components/radio/dist/registered.js +1 -1
  39. package/components/select/demo/customize.min.js +6 -47
  40. package/components/select/demo/getting-started.min.js +6 -47
  41. package/components/select/demo/index.min.js +6 -47
  42. package/components/select/dist/index.js +6 -47
  43. package/components/select/dist/registered.js +6 -47
  44. package/custom-elements.json +1504 -1510
  45. package/package.json +1 -1
@@ -3709,7 +3709,7 @@ class AuroHelpText extends LitElement {
3709
3709
  }
3710
3710
  }
3711
3711
 
3712
- var formkitVersion = '202607160645';
3712
+ var formkitVersion = '202607152222';
3713
3713
 
3714
3714
  class AuroElement extends LitElement {
3715
3715
  static get properties() {
@@ -3838,6 +3838,7 @@ class AuroDropdown extends AuroElement {
3838
3838
  static get shadowRootOptions() {
3839
3839
  return {
3840
3840
  ...AuroElement.shadowRootOptions,
3841
+ delegatesFocus: true,
3841
3842
  };
3842
3843
  }
3843
3844
 
@@ -4004,47 +4005,7 @@ class AuroDropdown extends AuroElement {
4004
4005
  focusables[0].focus();
4005
4006
  }
4006
4007
  } else {
4007
- this.focusTrigger();
4008
- }
4009
- }
4010
-
4011
- /**
4012
- * Focus the trigger content. When the trigger wrapper itself is focusable
4013
- * (has tabindex), focus it directly. Otherwise, focus the first focusable
4014
- * element slotted into the trigger slot (e.g. the auro-input).
4015
- * @private
4016
- */
4017
- focusTrigger() {
4018
- if (this.trigger.hasAttribute('tabindex')) {
4019
4008
  this.trigger.focus();
4020
- } else {
4021
- // Slotted content isn't a DOM child of the trigger div, so
4022
- // getFocusableElements can't find it. Query assigned nodes directly.
4023
- const slot = this.trigger.querySelector('slot[name="trigger"]');
4024
- if (slot) {
4025
- const assigned = slot.assignedElements();
4026
- for (const el of assigned) {
4027
- if (el.hasAttribute('disabled')) {
4028
- continue;
4029
- }
4030
- // Try finding a focusable descendant first (handles non-focusable
4031
- // wrappers like <div> containing a <button>). If none found, try
4032
- // focusing the element directly (works for custom elements like
4033
- // auro-input that have delegatesFocus or a custom focus() method).
4034
- const descendants = getFocusableElements(el);
4035
- if (descendants.length > 0) {
4036
- descendants[0].focus();
4037
- return;
4038
- }
4039
- el.focus();
4040
- return;
4041
- }
4042
- }
4043
- // Fallback: try DOM children (non-slotted content)
4044
- const focusables = getFocusableElements(this.trigger);
4045
- if (focusables.length > 0) {
4046
- focusables[0].focus();
4047
- }
4048
4009
  }
4049
4010
  }
4050
4011
 
@@ -4498,16 +4459,14 @@ class AuroDropdown extends AuroElement {
4498
4459
 
4499
4460
  const eventType = event.detail.eventType || "unknown";
4500
4461
  if (!this.isPopoverVisible && this.hasFocus && eventType === "keydown") {
4501
- this.focusTrigger();
4462
+ this.trigger.focus();
4502
4463
  }
4503
4464
 
4504
4465
 
4505
4466
  // On Tab-driven close (eventType "focusloss"), let focus advance naturally
4506
4467
  // — restoring to the trigger would trap the user on this dropdown, forcing
4507
4468
  // an extra Tab to move on. Escape and outside-click still restore.
4508
- // When noHideOnThisFocusLoss is true, the consumer (e.g. combobox) manages
4509
- // its own focus restoration — skip the generic trigger focus to avoid races.
4510
- if (!this.isPopoverVisible && eventType !== "focusloss" && !this.noHideOnThisFocusLoss) {
4469
+ if (!this.isPopoverVisible && eventType !== "focusloss") {
4511
4470
  // wait til the bib gets fully closed and rendered
4512
4471
  setTimeout(() => {
4513
4472
  // Skip if the bib re-opened, or if focus moved intentionally outside the dropdown (not to body).
@@ -4519,7 +4478,7 @@ class AuroDropdown extends AuroElement {
4519
4478
  return;
4520
4479
  }
4521
4480
  // Restore focus to the trigger.
4522
- this.focusTrigger();
4481
+ this.trigger.focus();
4523
4482
  });
4524
4483
  }
4525
4484
  }
@@ -3709,7 +3709,7 @@ class AuroHelpText extends LitElement {
3709
3709
  }
3710
3710
  }
3711
3711
 
3712
- var formkitVersion = '202607160645';
3712
+ var formkitVersion = '202607152222';
3713
3713
 
3714
3714
  class AuroElement extends LitElement {
3715
3715
  static get properties() {
@@ -3838,6 +3838,7 @@ class AuroDropdown extends AuroElement {
3838
3838
  static get shadowRootOptions() {
3839
3839
  return {
3840
3840
  ...AuroElement.shadowRootOptions,
3841
+ delegatesFocus: true,
3841
3842
  };
3842
3843
  }
3843
3844
 
@@ -4004,47 +4005,7 @@ class AuroDropdown extends AuroElement {
4004
4005
  focusables[0].focus();
4005
4006
  }
4006
4007
  } else {
4007
- this.focusTrigger();
4008
- }
4009
- }
4010
-
4011
- /**
4012
- * Focus the trigger content. When the trigger wrapper itself is focusable
4013
- * (has tabindex), focus it directly. Otherwise, focus the first focusable
4014
- * element slotted into the trigger slot (e.g. the auro-input).
4015
- * @private
4016
- */
4017
- focusTrigger() {
4018
- if (this.trigger.hasAttribute('tabindex')) {
4019
4008
  this.trigger.focus();
4020
- } else {
4021
- // Slotted content isn't a DOM child of the trigger div, so
4022
- // getFocusableElements can't find it. Query assigned nodes directly.
4023
- const slot = this.trigger.querySelector('slot[name="trigger"]');
4024
- if (slot) {
4025
- const assigned = slot.assignedElements();
4026
- for (const el of assigned) {
4027
- if (el.hasAttribute('disabled')) {
4028
- continue;
4029
- }
4030
- // Try finding a focusable descendant first (handles non-focusable
4031
- // wrappers like <div> containing a <button>). If none found, try
4032
- // focusing the element directly (works for custom elements like
4033
- // auro-input that have delegatesFocus or a custom focus() method).
4034
- const descendants = getFocusableElements(el);
4035
- if (descendants.length > 0) {
4036
- descendants[0].focus();
4037
- return;
4038
- }
4039
- el.focus();
4040
- return;
4041
- }
4042
- }
4043
- // Fallback: try DOM children (non-slotted content)
4044
- const focusables = getFocusableElements(this.trigger);
4045
- if (focusables.length > 0) {
4046
- focusables[0].focus();
4047
- }
4048
4009
  }
4049
4010
  }
4050
4011
 
@@ -4498,16 +4459,14 @@ class AuroDropdown extends AuroElement {
4498
4459
 
4499
4460
  const eventType = event.detail.eventType || "unknown";
4500
4461
  if (!this.isPopoverVisible && this.hasFocus && eventType === "keydown") {
4501
- this.focusTrigger();
4462
+ this.trigger.focus();
4502
4463
  }
4503
4464
 
4504
4465
 
4505
4466
  // On Tab-driven close (eventType "focusloss"), let focus advance naturally
4506
4467
  // — restoring to the trigger would trap the user on this dropdown, forcing
4507
4468
  // an extra Tab to move on. Escape and outside-click still restore.
4508
- // When noHideOnThisFocusLoss is true, the consumer (e.g. combobox) manages
4509
- // its own focus restoration — skip the generic trigger focus to avoid races.
4510
- if (!this.isPopoverVisible && eventType !== "focusloss" && !this.noHideOnThisFocusLoss) {
4469
+ if (!this.isPopoverVisible && eventType !== "focusloss") {
4511
4470
  // wait til the bib gets fully closed and rendered
4512
4471
  setTimeout(() => {
4513
4472
  // Skip if the bib re-opened, or if focus moved intentionally outside the dropdown (not to body).
@@ -4519,7 +4478,7 @@ class AuroDropdown extends AuroElement {
4519
4478
  return;
4520
4479
  }
4521
4480
  // Restore focus to the trigger.
4522
- this.focusTrigger();
4481
+ this.trigger.focus();
4523
4482
  });
4524
4483
  }
4525
4484
  }