@aurodesignsystem/auro-formkit 2.0.0-beta.6 → 2.0.0-beta.8

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 (146) hide show
  1. package/.turbo/cache/06845874cc82b186-meta.json +1 -1
  2. package/.turbo/cache/06845874cc82b186.tar.zst +0 -0
  3. package/.turbo/cache/0a96f136af026d57-meta.json +1 -1
  4. package/.turbo/cache/0a96f136af026d57.tar.zst +0 -0
  5. package/.turbo/cache/0c8124a987c1cc05-meta.json +1 -1
  6. package/.turbo/cache/0c9ee13a7c863709-meta.json +1 -0
  7. package/.turbo/cache/0c9ee13a7c863709.tar.zst +0 -0
  8. package/.turbo/cache/0ca9c5ccf3e90704-meta.json +1 -1
  9. package/.turbo/cache/0ca9c5ccf3e90704.tar.zst +0 -0
  10. package/.turbo/cache/18129dba20f51b6b-meta.json +1 -1
  11. package/.turbo/cache/1a8d6e4cab38121a-meta.json +1 -1
  12. package/.turbo/cache/1ce32edb29492636-meta.json +1 -0
  13. package/.turbo/cache/{66e9cca767930b1d.tar.zst → 1ce32edb29492636.tar.zst} +0 -0
  14. package/.turbo/cache/2787020e69f50af2-meta.json +1 -1
  15. package/.turbo/cache/2ec1b6d23563659e-meta.json +1 -1
  16. package/.turbo/cache/3afc5b2ea7c1bf51-meta.json +1 -1
  17. package/.turbo/cache/3afc5b2ea7c1bf51.tar.zst +0 -0
  18. package/.turbo/cache/3cd8fc5f388323db-meta.json +1 -1
  19. package/.turbo/cache/4006a206400d5c7b-meta.json +1 -1
  20. package/.turbo/cache/40de011abc31c0cf-meta.json +1 -1
  21. package/.turbo/cache/40de011abc31c0cf.tar.zst +0 -0
  22. package/.turbo/cache/426c825f57054f5f-meta.json +1 -1
  23. package/.turbo/cache/4524aae614598308-meta.json +1 -1
  24. package/.turbo/cache/4524aae614598308.tar.zst +0 -0
  25. package/.turbo/cache/45ea3e30ae949d53-meta.json +1 -0
  26. package/.turbo/cache/45ea3e30ae949d53.tar.zst +0 -0
  27. package/.turbo/cache/492dda333b8d15f1-meta.json +1 -1
  28. package/.turbo/cache/50993de942ec15a9-meta.json +1 -1
  29. package/.turbo/cache/51eaa58d5c167de8-meta.json +1 -1
  30. package/.turbo/cache/577d86e4072c01f5-meta.json +1 -1
  31. package/.turbo/cache/577d86e4072c01f5.tar.zst +0 -0
  32. package/.turbo/cache/5aadae8d3f94202e-meta.json +1 -1
  33. package/.turbo/cache/5d770c787aa78d4d-meta.json +1 -1
  34. package/.turbo/cache/5d770c787aa78d4d.tar.zst +0 -0
  35. package/.turbo/cache/60ad74320c682a2b-meta.json +1 -1
  36. package/.turbo/cache/61e218aba69cff58-meta.json +1 -1
  37. package/.turbo/cache/624bf5350aacae42-meta.json +1 -1
  38. package/.turbo/cache/68060c79df03f45a-meta.json +1 -1
  39. package/.turbo/cache/68060c79df03f45a.tar.zst +0 -0
  40. package/.turbo/cache/68e3afb31feab4e9-meta.json +1 -1
  41. package/.turbo/cache/6a1c28febca6163f-meta.json +1 -1
  42. package/.turbo/cache/6bc4e2d881af6ffb-meta.json +1 -1
  43. package/.turbo/cache/6c8ea74dc3b07640-meta.json +1 -1
  44. package/.turbo/cache/71dbeaf0706c12fe-meta.json +1 -1
  45. package/.turbo/cache/7445df6e7feed2a7-meta.json +1 -1
  46. package/.turbo/cache/77da375a012de9d0-meta.json +1 -1
  47. package/.turbo/cache/7a6ef918375d4010-meta.json +1 -1
  48. package/.turbo/cache/7a6ef918375d4010.tar.zst +0 -0
  49. package/.turbo/cache/7bf2b06a479d0b30-meta.json +1 -1
  50. package/.turbo/cache/7da23884069695e6-meta.json +1 -0
  51. package/.turbo/cache/{ad2b775dd9172ae8.tar.zst → 7da23884069695e6.tar.zst} +0 -0
  52. package/.turbo/cache/7f3b42ddf36d0158-meta.json +1 -1
  53. package/.turbo/cache/83e1029b14af6545-meta.json +1 -1
  54. package/.turbo/cache/8410cd8eeadc3af7-meta.json +1 -0
  55. package/.turbo/cache/8410cd8eeadc3af7.tar.zst +0 -0
  56. package/.turbo/cache/98936c69a55361fc-meta.json +1 -1
  57. package/.turbo/cache/9a9b4e449cd84be4-meta.json +1 -1
  58. package/.turbo/cache/9ae99e8e7bd83d06-meta.json +1 -1
  59. package/.turbo/cache/a275406512608e45-meta.json +1 -1
  60. package/.turbo/cache/a3db8f78e018a955-meta.json +1 -1
  61. package/.turbo/cache/a3db8f78e018a955.tar.zst +0 -0
  62. package/.turbo/cache/b5e6dc7fb9ae1a2f-meta.json +1 -1
  63. package/.turbo/cache/b6a202cc85cb61a0-meta.json +1 -1
  64. package/.turbo/cache/b91d2888e699c76a-meta.json +1 -1
  65. package/.turbo/cache/bdc6aadfdbb6feb9-meta.json +1 -1
  66. package/.turbo/cache/c114d428251f56a5-meta.json +1 -1
  67. package/.turbo/cache/c114d428251f56a5.tar.zst +0 -0
  68. package/.turbo/cache/c44efc9e4ddd8a0e-meta.json +1 -1
  69. package/.turbo/cache/c6c6411199b68170-meta.json +1 -1
  70. package/.turbo/cache/c7338727efbc457a-meta.json +1 -1
  71. package/.turbo/cache/c7338727efbc457a.tar.zst +0 -0
  72. package/.turbo/cache/cf235df1ef8d90b0-meta.json +1 -1
  73. package/.turbo/cache/d1d1a072ee099992-meta.json +1 -0
  74. package/.turbo/cache/d1d1a072ee099992.tar.zst +0 -0
  75. package/.turbo/cache/d3a05e38449c9b24-meta.json +1 -1
  76. package/.turbo/cache/d5db503b2eaf239c-meta.json +1 -1
  77. package/.turbo/cache/d9331772756d3d94-meta.json +1 -1
  78. package/.turbo/cache/d9331772756d3d94.tar.zst +0 -0
  79. package/.turbo/cache/db4ea5071b44ee8c-meta.json +1 -1
  80. package/.turbo/cache/dc6fbe2a8d5b9d9b-meta.json +1 -1
  81. package/.turbo/cache/dc6fbe2a8d5b9d9b.tar.zst +0 -0
  82. package/.turbo/cache/df28a5ee199e995d-meta.json +1 -0
  83. package/.turbo/cache/df28a5ee199e995d.tar.zst +0 -0
  84. package/.turbo/cache/e1e2582a7131011f-meta.json +1 -1
  85. package/.turbo/cache/e6271174c00888fe-meta.json +1 -1
  86. package/.turbo/cache/e62cfee068e3ef36-meta.json +1 -1
  87. package/.turbo/cache/e8485d2a584b5f08-meta.json +1 -0
  88. package/.turbo/cache/e8485d2a584b5f08.tar.zst +0 -0
  89. package/.turbo/cache/e86451b8f88594b2-meta.json +1 -1
  90. package/.turbo/cache/e86451b8f88594b2.tar.zst +0 -0
  91. package/.turbo/cache/e9872ba002963dd3-meta.json +1 -1
  92. package/CHANGELOG.md +15 -0
  93. package/components/checkbox/.turbo/turbo-build.log +2 -2
  94. package/components/checkbox/.turbo/turbo-bundler.log +2 -2
  95. package/components/checkbox/README.md +1 -1
  96. package/components/combobox/.turbo/turbo-build.log +2 -2
  97. package/components/combobox/.turbo/turbo-bundler.log +5 -4
  98. package/components/combobox/README.md +4 -4
  99. package/components/combobox/demo/api.min.js +51 -54
  100. package/components/combobox/demo/index.min.js +51 -54
  101. package/components/combobox/dist/auro-combobox.d.ts.map +1 -1
  102. package/components/combobox/dist/index.js +51 -54
  103. package/components/combobox/src/auro-combobox.js +51 -54
  104. package/components/counter/.turbo/turbo-build.log +3 -3
  105. package/components/counter/.turbo/turbo-bundler.log +3 -3
  106. package/components/datepicker/.turbo/turbo-build.log +2 -2
  107. package/components/datepicker/.turbo/turbo-bundler.log +3 -3
  108. package/components/datepicker/README.md +4 -4
  109. package/components/datepicker/demo/api.min.js +2 -1
  110. package/components/datepicker/demo/index.min.js +2 -1
  111. package/components/datepicker/dist/auro-datepicker.d.ts.map +1 -1
  112. package/components/datepicker/dist/index.js +2 -1
  113. package/components/datepicker/src/auro-datepicker.js +2 -1
  114. package/components/dropdown/.turbo/turbo-build.log +2 -2
  115. package/components/dropdown/.turbo/turbo-bundler.log +2 -2
  116. package/components/dropdown/README.md +1 -1
  117. package/components/form/.turbo/turbo-build.log +3 -3
  118. package/components/form/.turbo/turbo-bundler.log +3 -3
  119. package/components/form/README.md +1 -1
  120. package/components/input/.turbo/turbo-build.log +2 -2
  121. package/components/input/.turbo/turbo-bundler.log +3 -3
  122. package/components/input/README.md +1 -1
  123. package/components/menu/.turbo/turbo-build.log +3 -3
  124. package/components/menu/.turbo/turbo-bundler.log +3 -3
  125. package/components/menu/README.md +1 -1
  126. package/components/radio/.turbo/turbo-build.log +3 -3
  127. package/components/radio/.turbo/turbo-bundler.log +3 -3
  128. package/components/radio/README.md +1 -1
  129. package/components/select/.turbo/turbo-build.log +3 -3
  130. package/components/select/.turbo/turbo-bundler.log +3 -6
  131. package/components/select/README.md +3 -3
  132. package/package.json +1 -1
  133. package/.turbo/cache/14f6c585a8504aed-meta.json +0 -1
  134. package/.turbo/cache/14f6c585a8504aed.tar.zst +0 -0
  135. package/.turbo/cache/66333b75c8f57565-meta.json +0 -1
  136. package/.turbo/cache/66333b75c8f57565.tar.zst +0 -0
  137. package/.turbo/cache/66e9cca767930b1d-meta.json +0 -1
  138. package/.turbo/cache/a50fe73cdcf0b30b-meta.json +0 -1
  139. package/.turbo/cache/a50fe73cdcf0b30b.tar.zst +0 -0
  140. package/.turbo/cache/ad2b775dd9172ae8-meta.json +0 -1
  141. package/.turbo/cache/be128506a9bcaa65-meta.json +0 -1
  142. package/.turbo/cache/be128506a9bcaa65.tar.zst +0 -0
  143. package/.turbo/cache/e3214a79be4093fc-meta.json +0 -1
  144. package/.turbo/cache/e3214a79be4093fc.tar.zst +0 -0
  145. package/.turbo/cache/ed18f3189ffb1fae-meta.json +0 -1
  146. package/.turbo/cache/ed18f3189ffb1fae.tar.zst +0 -0
@@ -8017,9 +8017,6 @@ class AuroCombobox extends r$6 {
8017
8017
 
8018
8018
  // handle the menu event for an option selection
8019
8019
  this.menu.addEventListener('auroMenu-selectedOption', () => {
8020
- // dropdown bib should hide when making a selection
8021
- this.hideBib();
8022
-
8023
8020
  if (this.menu.optionSelected) {
8024
8021
  if (this.optionSelected !== this.menu.optionSelected) {
8025
8022
  this.optionSelected = this.menu.optionSelected;
@@ -8048,6 +8045,9 @@ class AuroCombobox extends r$6 {
8048
8045
  composed: true,
8049
8046
  }));
8050
8047
  }
8048
+
8049
+ // dropdown bib should hide when making a selection
8050
+ this.hideBib();
8051
8051
  });
8052
8052
 
8053
8053
  this.menu.addEventListener('auroMenu-customEventFired', () => {
@@ -8092,54 +8092,6 @@ class AuroCombobox extends r$6 {
8092
8092
  }
8093
8093
  });
8094
8094
 
8095
- this.input.addEventListener('input', () => {
8096
- this.menu.matchWord = this.input.value;
8097
- this.optionActive = null;
8098
-
8099
- if (this.value !== this.input.value) {
8100
- this.value = this.input.value;
8101
- }
8102
-
8103
- if (this.value !== this.menu.value) {
8104
- this.menu.value = this.value;
8105
- }
8106
-
8107
- if (this.optionSelected && this.input.value !== this.optionSelected.textContent) {
8108
- this.optionSelected = undefined;
8109
- }
8110
-
8111
- this.menu.resetOptionsStates();
8112
-
8113
- this.handleMenuOptions();
8114
-
8115
- this.handleInputValueChange();
8116
- // validate only if the value was set programmatically
8117
- if (document.activeElement !== this) {
8118
- this.validation.validate(this);
8119
- }
8120
-
8121
- // hide the menu if the value is empty otherwise show if there are available suggestions
8122
- if (this.input.value && this.input.value.length === 0) {
8123
- this.hideBib();
8124
- this.classList.remove('combobox-filled');
8125
- } else if (!this.dropdown.isPopoverVisible && this.availableOptions) {
8126
- const hasFocus = this.contains(document.activeElement);
8127
-
8128
- // if the focus is within the combobox, then show the bib
8129
- // this will prevent the bib from being shown while loading & presetting the value
8130
- if (hasFocus) {
8131
- this.showBib();
8132
- }
8133
-
8134
- this.classList.add('combobox-filled');
8135
- }
8136
-
8137
- // force the dropdown bib to hide if the input value has no matching suggestions
8138
- if (!this.availableOptions || this.availableOptions.length === 0) {
8139
- this.hideBib();
8140
- }
8141
- });
8142
-
8143
8095
  this.input.addEventListener('auroFormElement-validated', (evt) => {
8144
8096
  this.errorMessage = evt.detail.message;
8145
8097
  });
@@ -8174,8 +8126,14 @@ class AuroCombobox extends r$6 {
8174
8126
  * @returns {void}
8175
8127
  */
8176
8128
  handleInputValueChange() {
8129
+ this.menu.matchWord = this.input.value;
8130
+ this.optionActive = null;
8131
+
8132
+ let hasChange = false;
8133
+
8177
8134
  if (this.value !== this.input.value) {
8178
8135
  this.value = this.input.value;
8136
+ hasChange = true;
8179
8137
 
8180
8138
  this.dispatchEvent(new CustomEvent('auroCombobox-valueSet', {
8181
8139
  bubbles: true,
@@ -8184,10 +8142,48 @@ class AuroCombobox extends r$6 {
8184
8142
  }));
8185
8143
  }
8186
8144
 
8187
- // This check prevents the component showing an error when a required datepicker is first rendered
8188
- if (this.input.value) {
8145
+ if (this.value !== this.menu.value) {
8146
+ this.menu.value = this.value;
8147
+ hasChange = true;
8148
+ }
8149
+
8150
+ if (this.optionSelected && this.input.value !== this.optionSelected.textContent) {
8151
+ this.optionSelected = undefined;
8152
+ hasChange = true;
8153
+ }
8154
+
8155
+ if (!hasChange) {
8156
+ return;
8157
+ }
8158
+
8159
+ this.menu.resetOptionsStates();
8160
+ this.handleMenuOptions();
8161
+
8162
+ // validate if the value was set programmatically
8163
+ if (document.activeElement !== this) {
8189
8164
  this.validation.validate(this);
8190
8165
  }
8166
+
8167
+ // hide the menu if the value is empty otherwise show if there are available suggestions
8168
+ if (this.input.value && this.input.value.length === 0) {
8169
+ this.hideBib();
8170
+ this.classList.remove('combobox-filled');
8171
+ } else if (!this.dropdown.isPopoverVisible && this.availableOptions) {
8172
+ const hasFocus = this.contains(document.activeElement);
8173
+
8174
+ // if the focus is within the combobox, then show the bib
8175
+ // this will prevent the bib from being shown while loading & presetting the value
8176
+ if (hasFocus) {
8177
+ this.showBib();
8178
+ }
8179
+
8180
+ this.classList.add('combobox-filled');
8181
+ }
8182
+
8183
+ // force the dropdown bib to hide if the input value has no matching suggestions
8184
+ if (!this.availableOptions || this.availableOptions.length === 0) {
8185
+ this.hideBib();
8186
+ }
8191
8187
  }
8192
8188
 
8193
8189
  /**
@@ -8373,7 +8369,8 @@ class AuroCombobox extends r$6 {
8373
8369
  setCustomValidity="${this.setCustomValidity}"
8374
8370
  setCustomValidityValueMissing="${this.setCustomValidityValueMissing}"
8375
8371
  setCustomValidityCustomError="${this.setCustomValidityCustomError}"
8376
- .type="${this.type}">
8372
+ .type="${this.type}"
8373
+ @input="${this.handleInputValueChange}">
8377
8374
  <slot name="label" slot="label"></slot>
8378
8375
  </${this.inputTag}>
8379
8376
  <div class="menuWrapper">
@@ -7875,9 +7875,6 @@ class AuroCombobox extends r$6 {
7875
7875
 
7876
7876
  // handle the menu event for an option selection
7877
7877
  this.menu.addEventListener('auroMenu-selectedOption', () => {
7878
- // dropdown bib should hide when making a selection
7879
- this.hideBib();
7880
-
7881
7878
  if (this.menu.optionSelected) {
7882
7879
  if (this.optionSelected !== this.menu.optionSelected) {
7883
7880
  this.optionSelected = this.menu.optionSelected;
@@ -7906,6 +7903,9 @@ class AuroCombobox extends r$6 {
7906
7903
  composed: true,
7907
7904
  }));
7908
7905
  }
7906
+
7907
+ // dropdown bib should hide when making a selection
7908
+ this.hideBib();
7909
7909
  });
7910
7910
 
7911
7911
  this.menu.addEventListener('auroMenu-customEventFired', () => {
@@ -7950,54 +7950,6 @@ class AuroCombobox extends r$6 {
7950
7950
  }
7951
7951
  });
7952
7952
 
7953
- this.input.addEventListener('input', () => {
7954
- this.menu.matchWord = this.input.value;
7955
- this.optionActive = null;
7956
-
7957
- if (this.value !== this.input.value) {
7958
- this.value = this.input.value;
7959
- }
7960
-
7961
- if (this.value !== this.menu.value) {
7962
- this.menu.value = this.value;
7963
- }
7964
-
7965
- if (this.optionSelected && this.input.value !== this.optionSelected.textContent) {
7966
- this.optionSelected = undefined;
7967
- }
7968
-
7969
- this.menu.resetOptionsStates();
7970
-
7971
- this.handleMenuOptions();
7972
-
7973
- this.handleInputValueChange();
7974
- // validate only if the value was set programmatically
7975
- if (document.activeElement !== this) {
7976
- this.validation.validate(this);
7977
- }
7978
-
7979
- // hide the menu if the value is empty otherwise show if there are available suggestions
7980
- if (this.input.value && this.input.value.length === 0) {
7981
- this.hideBib();
7982
- this.classList.remove('combobox-filled');
7983
- } else if (!this.dropdown.isPopoverVisible && this.availableOptions) {
7984
- const hasFocus = this.contains(document.activeElement);
7985
-
7986
- // if the focus is within the combobox, then show the bib
7987
- // this will prevent the bib from being shown while loading & presetting the value
7988
- if (hasFocus) {
7989
- this.showBib();
7990
- }
7991
-
7992
- this.classList.add('combobox-filled');
7993
- }
7994
-
7995
- // force the dropdown bib to hide if the input value has no matching suggestions
7996
- if (!this.availableOptions || this.availableOptions.length === 0) {
7997
- this.hideBib();
7998
- }
7999
- });
8000
-
8001
7953
  this.input.addEventListener('auroFormElement-validated', (evt) => {
8002
7954
  this.errorMessage = evt.detail.message;
8003
7955
  });
@@ -8032,8 +7984,14 @@ class AuroCombobox extends r$6 {
8032
7984
  * @returns {void}
8033
7985
  */
8034
7986
  handleInputValueChange() {
7987
+ this.menu.matchWord = this.input.value;
7988
+ this.optionActive = null;
7989
+
7990
+ let hasChange = false;
7991
+
8035
7992
  if (this.value !== this.input.value) {
8036
7993
  this.value = this.input.value;
7994
+ hasChange = true;
8037
7995
 
8038
7996
  this.dispatchEvent(new CustomEvent('auroCombobox-valueSet', {
8039
7997
  bubbles: true,
@@ -8042,10 +8000,48 @@ class AuroCombobox extends r$6 {
8042
8000
  }));
8043
8001
  }
8044
8002
 
8045
- // This check prevents the component showing an error when a required datepicker is first rendered
8046
- if (this.input.value) {
8003
+ if (this.value !== this.menu.value) {
8004
+ this.menu.value = this.value;
8005
+ hasChange = true;
8006
+ }
8007
+
8008
+ if (this.optionSelected && this.input.value !== this.optionSelected.textContent) {
8009
+ this.optionSelected = undefined;
8010
+ hasChange = true;
8011
+ }
8012
+
8013
+ if (!hasChange) {
8014
+ return;
8015
+ }
8016
+
8017
+ this.menu.resetOptionsStates();
8018
+ this.handleMenuOptions();
8019
+
8020
+ // validate if the value was set programmatically
8021
+ if (document.activeElement !== this) {
8047
8022
  this.validation.validate(this);
8048
8023
  }
8024
+
8025
+ // hide the menu if the value is empty otherwise show if there are available suggestions
8026
+ if (this.input.value && this.input.value.length === 0) {
8027
+ this.hideBib();
8028
+ this.classList.remove('combobox-filled');
8029
+ } else if (!this.dropdown.isPopoverVisible && this.availableOptions) {
8030
+ const hasFocus = this.contains(document.activeElement);
8031
+
8032
+ // if the focus is within the combobox, then show the bib
8033
+ // this will prevent the bib from being shown while loading & presetting the value
8034
+ if (hasFocus) {
8035
+ this.showBib();
8036
+ }
8037
+
8038
+ this.classList.add('combobox-filled');
8039
+ }
8040
+
8041
+ // force the dropdown bib to hide if the input value has no matching suggestions
8042
+ if (!this.availableOptions || this.availableOptions.length === 0) {
8043
+ this.hideBib();
8044
+ }
8049
8045
  }
8050
8046
 
8051
8047
  /**
@@ -8231,7 +8227,8 @@ class AuroCombobox extends r$6 {
8231
8227
  setCustomValidity="${this.setCustomValidity}"
8232
8228
  setCustomValidityValueMissing="${this.setCustomValidityValueMissing}"
8233
8229
  setCustomValidityCustomError="${this.setCustomValidityCustomError}"
8234
- .type="${this.type}">
8230
+ .type="${this.type}"
8231
+ @input="${this.handleInputValueChange}">
8235
8232
  <slot name="label" slot="label"></slot>
8236
8233
  </${this.inputTag}>
8237
8234
  <div class="menuWrapper">
@@ -1 +1 @@
1
- {"version":3,"file":"auro-combobox.d.ts","sourceRoot":"","sources":["../src/auro-combobox.js"],"names":[],"mappings":"AAyBA;;;;;;;;;;;;;;;;;;;;GAoBG;AAGH;IA+CE;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;QAkDI;;WAEG;;;;QAGH;;WAEG;;;;QAGH;;WAEG;;;;QAGH;;WAEG;;;;QAGH;;WAEG;;;;QAGH;;WAEG;;;;QAGH;;WAEG;;;;MAGN;IAED,+CAEC;IAED;;;;;;;OAOG;IACH,uBANW,MAAM,QAQhB;IAhJC,kBAAqB;IACrB,cAAyB;IACzB,WAAiB;IACjB,oBAA0B;IAI1B;;OAEG;IACH,mBAA0C;IAE1C;;OAEG;IACH,qBAAiD;IAEjD;;OAEG;IACH,6BAAiC;IAMjC,iBAAyF;IACzF,cAA6E;IAG/E;;;OAGG;IACH,wBAIC;IAHC,wBAA0B;IAC1B,kBAAwB;IACxB,4BAAqD;IA6GvD;;;;OAIG;IACH,0BAiDC;IA1CG,mBAA8B;IA4ClC;;;;OAIG;IACH,6BAMC;IAJG,qCAA+E;IAMnF;;;;OAIG;IACH,gBAIC;IAED;;;;OAIG;IACH,gBAcC;IAED;;;;OAIG;IACH,0BAaC;IAZC,iBAA8D;IAchE;;;;OAIG;IACH,sBAuEC;IAtEC,cAAwD;IAwE1D;;;;OAIG;IACH,uBAuEC;IAFG,kBAAsC;IAI1C;;;;;;;;;;;;;OAaG;IACH,gCAOC;IAED;;;;OAIG;IACH,+BAeC;IAED;;;;OAIG;IACH,0BAqCC;IAWC,iBAAiE;IAWnE,qBAgBC;IAZC,cAA4E;IAC5E,WAAoE;IAatE;;;OAGG;IACH,SAFa,IAAI,CAIhB;IAED;;;OAGG;IACH,SAFa,IAAI,CAKhB;IAED,sCA4BC;IAED;;;;;OAKG;IACH,yBAcC;IAGD,4CAkDC;CACF;2BA3sB0B,KAAK"}
1
+ {"version":3,"file":"auro-combobox.d.ts","sourceRoot":"","sources":["../src/auro-combobox.js"],"names":[],"mappings":"AAyBA;;;;;;;;;;;;;;;;;;;;GAoBG;AAGH;IA+CE;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;QAkDI;;WAEG;;;;QAGH;;WAEG;;;;QAGH;;WAEG;;;;QAGH;;WAEG;;;;QAGH;;WAEG;;;;QAGH;;WAEG;;;;QAGH;;WAEG;;;;MAGN;IAED,+CAEC;IAED;;;;;;;OAOG;IACH,uBANW,MAAM,QAQhB;IAhJC,kBAAqB;IACrB,cAAyB;IACzB,WAAiB;IACjB,oBAA0B;IAI1B;;OAEG;IACH,mBAA0C;IAE1C;;OAEG;IACH,qBAAiD;IAEjD;;OAEG;IACH,6BAAiC;IAMjC,iBAAyF;IACzF,cAA6E;IAG/E;;;OAGG;IACH,wBAIC;IAHC,wBAA0B;IAC1B,kBAAwB;IACxB,4BAAqD;IA6GvD;;;;OAIG;IACH,0BAiDC;IA1CG,mBAA8B;IA4ClC;;;;OAIG;IACH,6BAMC;IAJG,qCAA+E;IAMnF;;;;OAIG;IACH,gBAIC;IAED;;;;OAIG;IACH,gBAcC;IAED;;;;OAIG;IACH,0BAaC;IAZC,iBAA8D;IAchE;;;;OAIG;IACH,sBAuEC;IAtEC,cAAwD;IAwE1D;;;;OAIG;IACH,uBAuBC;IAFG,kBAAsC;IAI1C;;;;;;;;;;;;;OAaG;IACH,gCAOC;IAED;;;;OAIG;IACH,+BA2DC;IAED;;;;OAIG;IACH,0BAqCC;IAWC,iBAAiE;IAWnE,qBAgBC;IAZC,cAA4E;IAC5E,WAAoE;IAatE;;;OAGG;IACH,SAFa,IAAI,CAIhB;IAED;;;OAGG;IACH,SAFa,IAAI,CAKhB;IAED,sCA4BC;IAED;;;;;OAKG;IACH,yBAcC;IAGD,4CAmDC;CACF;2BAxsB0B,KAAK"}
@@ -7852,9 +7852,6 @@ class AuroCombobox extends r$6 {
7852
7852
 
7853
7853
  // handle the menu event for an option selection
7854
7854
  this.menu.addEventListener('auroMenu-selectedOption', () => {
7855
- // dropdown bib should hide when making a selection
7856
- this.hideBib();
7857
-
7858
7855
  if (this.menu.optionSelected) {
7859
7856
  if (this.optionSelected !== this.menu.optionSelected) {
7860
7857
  this.optionSelected = this.menu.optionSelected;
@@ -7883,6 +7880,9 @@ class AuroCombobox extends r$6 {
7883
7880
  composed: true,
7884
7881
  }));
7885
7882
  }
7883
+
7884
+ // dropdown bib should hide when making a selection
7885
+ this.hideBib();
7886
7886
  });
7887
7887
 
7888
7888
  this.menu.addEventListener('auroMenu-customEventFired', () => {
@@ -7927,54 +7927,6 @@ class AuroCombobox extends r$6 {
7927
7927
  }
7928
7928
  });
7929
7929
 
7930
- this.input.addEventListener('input', () => {
7931
- this.menu.matchWord = this.input.value;
7932
- this.optionActive = null;
7933
-
7934
- if (this.value !== this.input.value) {
7935
- this.value = this.input.value;
7936
- }
7937
-
7938
- if (this.value !== this.menu.value) {
7939
- this.menu.value = this.value;
7940
- }
7941
-
7942
- if (this.optionSelected && this.input.value !== this.optionSelected.textContent) {
7943
- this.optionSelected = undefined;
7944
- }
7945
-
7946
- this.menu.resetOptionsStates();
7947
-
7948
- this.handleMenuOptions();
7949
-
7950
- this.handleInputValueChange();
7951
- // validate only if the value was set programmatically
7952
- if (document.activeElement !== this) {
7953
- this.validation.validate(this);
7954
- }
7955
-
7956
- // hide the menu if the value is empty otherwise show if there are available suggestions
7957
- if (this.input.value && this.input.value.length === 0) {
7958
- this.hideBib();
7959
- this.classList.remove('combobox-filled');
7960
- } else if (!this.dropdown.isPopoverVisible && this.availableOptions) {
7961
- const hasFocus = this.contains(document.activeElement);
7962
-
7963
- // if the focus is within the combobox, then show the bib
7964
- // this will prevent the bib from being shown while loading & presetting the value
7965
- if (hasFocus) {
7966
- this.showBib();
7967
- }
7968
-
7969
- this.classList.add('combobox-filled');
7970
- }
7971
-
7972
- // force the dropdown bib to hide if the input value has no matching suggestions
7973
- if (!this.availableOptions || this.availableOptions.length === 0) {
7974
- this.hideBib();
7975
- }
7976
- });
7977
-
7978
7930
  this.input.addEventListener('auroFormElement-validated', (evt) => {
7979
7931
  this.errorMessage = evt.detail.message;
7980
7932
  });
@@ -8009,8 +7961,14 @@ class AuroCombobox extends r$6 {
8009
7961
  * @returns {void}
8010
7962
  */
8011
7963
  handleInputValueChange() {
7964
+ this.menu.matchWord = this.input.value;
7965
+ this.optionActive = null;
7966
+
7967
+ let hasChange = false;
7968
+
8012
7969
  if (this.value !== this.input.value) {
8013
7970
  this.value = this.input.value;
7971
+ hasChange = true;
8014
7972
 
8015
7973
  this.dispatchEvent(new CustomEvent('auroCombobox-valueSet', {
8016
7974
  bubbles: true,
@@ -8019,10 +7977,48 @@ class AuroCombobox extends r$6 {
8019
7977
  }));
8020
7978
  }
8021
7979
 
8022
- // This check prevents the component showing an error when a required datepicker is first rendered
8023
- if (this.input.value) {
7980
+ if (this.value !== this.menu.value) {
7981
+ this.menu.value = this.value;
7982
+ hasChange = true;
7983
+ }
7984
+
7985
+ if (this.optionSelected && this.input.value !== this.optionSelected.textContent) {
7986
+ this.optionSelected = undefined;
7987
+ hasChange = true;
7988
+ }
7989
+
7990
+ if (!hasChange) {
7991
+ return;
7992
+ }
7993
+
7994
+ this.menu.resetOptionsStates();
7995
+ this.handleMenuOptions();
7996
+
7997
+ // validate if the value was set programmatically
7998
+ if (document.activeElement !== this) {
8024
7999
  this.validation.validate(this);
8025
8000
  }
8001
+
8002
+ // hide the menu if the value is empty otherwise show if there are available suggestions
8003
+ if (this.input.value && this.input.value.length === 0) {
8004
+ this.hideBib();
8005
+ this.classList.remove('combobox-filled');
8006
+ } else if (!this.dropdown.isPopoverVisible && this.availableOptions) {
8007
+ const hasFocus = this.contains(document.activeElement);
8008
+
8009
+ // if the focus is within the combobox, then show the bib
8010
+ // this will prevent the bib from being shown while loading & presetting the value
8011
+ if (hasFocus) {
8012
+ this.showBib();
8013
+ }
8014
+
8015
+ this.classList.add('combobox-filled');
8016
+ }
8017
+
8018
+ // force the dropdown bib to hide if the input value has no matching suggestions
8019
+ if (!this.availableOptions || this.availableOptions.length === 0) {
8020
+ this.hideBib();
8021
+ }
8026
8022
  }
8027
8023
 
8028
8024
  /**
@@ -8208,7 +8204,8 @@ class AuroCombobox extends r$6 {
8208
8204
  setCustomValidity="${this.setCustomValidity}"
8209
8205
  setCustomValidityValueMissing="${this.setCustomValidityValueMissing}"
8210
8206
  setCustomValidityCustomError="${this.setCustomValidityCustomError}"
8211
- .type="${this.type}">
8207
+ .type="${this.type}"
8208
+ @input="${this.handleInputValueChange}">
8212
8209
  <slot name="label" slot="label"></slot>
8213
8210
  </${this.inputTag}>
8214
8211
  <div class="menuWrapper">
@@ -345,9 +345,6 @@ export class AuroCombobox extends LitElement {
345
345
 
346
346
  // handle the menu event for an option selection
347
347
  this.menu.addEventListener('auroMenu-selectedOption', () => {
348
- // dropdown bib should hide when making a selection
349
- this.hideBib();
350
-
351
348
  if (this.menu.optionSelected) {
352
349
  if (this.optionSelected !== this.menu.optionSelected) {
353
350
  this.optionSelected = this.menu.optionSelected;
@@ -376,6 +373,9 @@ export class AuroCombobox extends LitElement {
376
373
  composed: true,
377
374
  }));
378
375
  }
376
+
377
+ // dropdown bib should hide when making a selection
378
+ this.hideBib();
379
379
  });
380
380
 
381
381
  this.menu.addEventListener('auroMenu-customEventFired', () => {
@@ -420,54 +420,6 @@ export class AuroCombobox extends LitElement {
420
420
  }
421
421
  });
422
422
 
423
- this.input.addEventListener('input', () => {
424
- this.menu.matchWord = this.input.value;
425
- this.optionActive = null;
426
-
427
- if (this.value !== this.input.value) {
428
- this.value = this.input.value;
429
- }
430
-
431
- if (this.value !== this.menu.value) {
432
- this.menu.value = this.value;
433
- }
434
-
435
- if (this.optionSelected && this.input.value !== this.optionSelected.textContent) {
436
- this.optionSelected = undefined;
437
- }
438
-
439
- this.menu.resetOptionsStates();
440
-
441
- this.handleMenuOptions();
442
-
443
- this.handleInputValueChange();
444
- // validate only if the value was set programmatically
445
- if (document.activeElement !== this) {
446
- this.validation.validate(this);
447
- }
448
-
449
- // hide the menu if the value is empty otherwise show if there are available suggestions
450
- if (this.input.value && this.input.value.length === 0) {
451
- this.hideBib();
452
- this.classList.remove('combobox-filled');
453
- } else if (!this.dropdown.isPopoverVisible && this.availableOptions) {
454
- const hasFocus = this.contains(document.activeElement);
455
-
456
- // if the focus is within the combobox, then show the bib
457
- // this will prevent the bib from being shown while loading & presetting the value
458
- if (hasFocus) {
459
- this.showBib();
460
- }
461
-
462
- this.classList.add('combobox-filled');
463
- }
464
-
465
- // force the dropdown bib to hide if the input value has no matching suggestions
466
- if (!this.availableOptions || this.availableOptions.length === 0) {
467
- this.hideBib();
468
- }
469
- });
470
-
471
423
  this.input.addEventListener('auroFormElement-validated', (evt) => {
472
424
  this.errorMessage = evt.detail.message;
473
425
  });
@@ -502,8 +454,14 @@ export class AuroCombobox extends LitElement {
502
454
  * @returns {void}
503
455
  */
504
456
  handleInputValueChange() {
457
+ this.menu.matchWord = this.input.value;
458
+ this.optionActive = null;
459
+
460
+ let hasChange = false;
461
+
505
462
  if (this.value !== this.input.value) {
506
463
  this.value = this.input.value;
464
+ hasChange = true;
507
465
 
508
466
  this.dispatchEvent(new CustomEvent('auroCombobox-valueSet', {
509
467
  bubbles: true,
@@ -512,10 +470,48 @@ export class AuroCombobox extends LitElement {
512
470
  }));
513
471
  }
514
472
 
515
- // This check prevents the component showing an error when a required datepicker is first rendered
516
- if (this.input.value) {
473
+ if (this.value !== this.menu.value) {
474
+ this.menu.value = this.value;
475
+ hasChange = true;
476
+ }
477
+
478
+ if (this.optionSelected && this.input.value !== this.optionSelected.textContent) {
479
+ this.optionSelected = undefined;
480
+ hasChange = true;
481
+ }
482
+
483
+ if (!hasChange) {
484
+ return;
485
+ }
486
+
487
+ this.menu.resetOptionsStates();
488
+ this.handleMenuOptions();
489
+
490
+ // validate if the value was set programmatically
491
+ if (document.activeElement !== this) {
517
492
  this.validation.validate(this);
518
493
  }
494
+
495
+ // hide the menu if the value is empty otherwise show if there are available suggestions
496
+ if (this.input.value && this.input.value.length === 0) {
497
+ this.hideBib();
498
+ this.classList.remove('combobox-filled');
499
+ } else if (!this.dropdown.isPopoverVisible && this.availableOptions) {
500
+ const hasFocus = this.contains(document.activeElement);
501
+
502
+ // if the focus is within the combobox, then show the bib
503
+ // this will prevent the bib from being shown while loading & presetting the value
504
+ if (hasFocus) {
505
+ this.showBib();
506
+ }
507
+
508
+ this.classList.add('combobox-filled');
509
+ }
510
+
511
+ // force the dropdown bib to hide if the input value has no matching suggestions
512
+ if (!this.availableOptions || this.availableOptions.length === 0) {
513
+ this.hideBib();
514
+ }
519
515
  }
520
516
 
521
517
  /**
@@ -701,7 +697,8 @@ export class AuroCombobox extends LitElement {
701
697
  setCustomValidity="${this.setCustomValidity}"
702
698
  setCustomValidityValueMissing="${this.setCustomValidityValueMissing}"
703
699
  setCustomValidityCustomError="${this.setCustomValidityCustomError}"
704
- .type="${this.type}">
700
+ .type="${this.type}"
701
+ @input="${this.handleInputValueChange}">
705
702
  <slot name="label" slot="label"></slot>
706
703
  </${this.inputTag}>
707
704
  <div class="menuWrapper">
@@ -74,13 +74,13 @@ More info and automated migrator: https://sass-lang.com/d/import
74
74
 
75
75
  
76
76
  ./src/index.js → dist...
77
- created dist in 531ms
77
+ created dist in 882ms
78
78
  
79
79
  ./demo/index.js → ./demo/...
80
- created ./demo/ in 309ms
80
+ created ./demo/ in 363ms
81
81
  
82
82
  ./demo/api.js → ./demo/...
83
- created ./demo/ in 354ms
83
+ created ./demo/ in 253ms
84
84
 
85
85
  > @aurodesignsystem/auro-counter@1.0.0 types
86
86
  > tsc --project tsconfig.json
@@ -4,10 +4,10 @@
4
4
 
5
5
  
6
6
  ./src/index.js → dist...
7
- created dist in 1.2s
7
+ created dist in 942ms
8
8
  
9
9
  ./demo/index.js → ./demo/...
10
- created ./demo/ in 427ms
10
+ created ./demo/ in 513ms
11
11
  
12
12
  ./demo/api.js → ./demo/...
13
- created ./demo/ in 577ms
13
+ created ./demo/ in 400ms
@@ -373,10 +373,10 @@ More info and automated migrator: https://sass-lang.com/d/import
373
373
 
374
374
  
375
375
  ./src/index.js → dist...
376
- created dist in 3.7s
376
+ created dist in 3.8s
377
377
  
378
378
  ./demo/index.js → ./demo/...
379
- created ./demo/ in 3.3s
379
+ created ./demo/ in 3.4s
380
380
  
381
381
  ./demo/api.js → ./demo/...
382
382
  created ./demo/ in 3.3s
@@ -8,10 +8,10 @@
8
8
  https://rollupjs.org/troubleshooting/#warning-treating-module-as-external-dependency
9
9
  @auro-formkit/auro-dropdown (imported by "src/auro-datepicker.js")
10
10
  @auro-formkit/auro-input (imported by "src/auro-datepicker.js")
11
- created dist in 20.1s
11
+ created dist in 22.7s
12
12
  
13
13
  ./demo/index.js → ./demo/...
14
- created ./demo/ in 12.9s
14
+ created ./demo/ in 9.3s
15
15
  
16
16
  ./demo/api.js → ./demo/...
17
- created ./demo/ in 3.4s
17
+ created ./demo/ in 3.3s
@@ -93,10 +93,10 @@ In cases where the project is not able to process JS assets, there are pre-proce
93
93
  <!-- The below content is automatically added from ../../docs/templates/componentBundleUseModBrowsers.md -->
94
94
  <link rel="stylesheet" href="https://cdn.jsdelivr.net/npm/@aurodesignsystem/design-tokens@4.12.1/dist/tokens/CSSCustomProperties.css" />
95
95
  <link rel="stylesheet" href="https://cdn.jsdelivr.net/npm/@aurodesignsystem/webcorestylesheets@5.1.2/dist/bundled/essentials.css" />
96
- <script src="https://cdn.jsdelivr.net/npm/@aurodesignsystem/auro-formkit/auro-dropdown@2.0.0-beta.5/dist/auro-dropdown__bundled.js" type="module"></script>
97
- <script src="https://cdn.jsdelivr.net/npm/@aurodesignsystem/auro-formkit/auro-input@2.0.0-beta.5/dist/auro-input__bundled.js" type="module"></script>
98
- <script src="https://cdn.jsdelivr.net/npm/@aurodesignsystem/auro-formkit/auro-popover@2.0.0-beta.5/dist/auro-popover__bundled.js" type="module"></script>
99
- <script src="https://cdn.jsdelivr.net/npm/@aurodesignsystem/auro-formkit/auro-datepicker@2.0.0-beta.5/dist/auro-datepicker__bundled.js" type="module"></script>
96
+ <script src="https://cdn.jsdelivr.net/npm/@aurodesignsystem/auro-formkit/auro-dropdown@2.0.0-beta.7/dist/auro-dropdown__bundled.js" type="module"></script>
97
+ <script src="https://cdn.jsdelivr.net/npm/@aurodesignsystem/auro-formkit/auro-input@2.0.0-beta.7/dist/auro-input__bundled.js" type="module"></script>
98
+ <script src="https://cdn.jsdelivr.net/npm/@aurodesignsystem/auro-formkit/auro-popover@2.0.0-beta.7/dist/auro-popover__bundled.js" type="module"></script>
99
+ <script src="https://cdn.jsdelivr.net/npm/@aurodesignsystem/auro-formkit/auro-datepicker@2.0.0-beta.7/dist/auro-datepicker__bundled.js" type="module"></script>
100
100
  <!-- AURO-GENERATED-CONTENT:END -->
101
101
 
102
102
  ## auro-datepicker use cases