@vaadin/combo-box 23.0.0-beta4 → 23.0.0-beta5

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.
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@vaadin/combo-box",
3
- "version": "23.0.0-beta4",
3
+ "version": "23.0.0-beta5",
4
4
  "publishConfig": {
5
5
  "access": "public"
6
6
  },
@@ -34,23 +34,23 @@
34
34
  "dependencies": {
35
35
  "@open-wc/dedupe-mixin": "^1.3.0",
36
36
  "@polymer/polymer": "^3.0.0",
37
- "@vaadin/component-base": "23.0.0-beta4",
38
- "@vaadin/field-base": "23.0.0-beta4",
39
- "@vaadin/input-container": "23.0.0-beta4",
40
- "@vaadin/item": "23.0.0-beta4",
41
- "@vaadin/vaadin-lumo-styles": "23.0.0-beta4",
42
- "@vaadin/vaadin-material-styles": "23.0.0-beta4",
43
- "@vaadin/vaadin-overlay": "23.0.0-beta4",
44
- "@vaadin/vaadin-themable-mixin": "23.0.0-beta4"
37
+ "@vaadin/component-base": "23.0.0-beta5",
38
+ "@vaadin/field-base": "23.0.0-beta5",
39
+ "@vaadin/input-container": "23.0.0-beta5",
40
+ "@vaadin/item": "23.0.0-beta5",
41
+ "@vaadin/vaadin-lumo-styles": "23.0.0-beta5",
42
+ "@vaadin/vaadin-material-styles": "23.0.0-beta5",
43
+ "@vaadin/vaadin-overlay": "23.0.0-beta5",
44
+ "@vaadin/vaadin-themable-mixin": "23.0.0-beta5"
45
45
  },
46
46
  "devDependencies": {
47
47
  "@esm-bundle/chai": "^4.3.4",
48
- "@vaadin/dialog": "23.0.0-beta4",
49
- "@vaadin/polymer-legacy-adapter": "23.0.0-beta4",
48
+ "@vaadin/dialog": "23.0.0-beta5",
49
+ "@vaadin/polymer-legacy-adapter": "23.0.0-beta5",
50
50
  "@vaadin/testing-helpers": "^0.3.2",
51
- "@vaadin/text-field": "23.0.0-beta4",
51
+ "@vaadin/text-field": "23.0.0-beta5",
52
52
  "lit": "^2.0.0",
53
53
  "sinon": "^9.2.0"
54
54
  },
55
- "gitHead": "d0b447f1c31ca4256a5e26f2dcd27784447ff79b"
55
+ "gitHead": "4c388aeec6623869c70896c909799804fc95d0f9"
56
56
  }
@@ -708,7 +708,6 @@ export const ComboBoxMixin = (subclass) =>
708
708
  this.selectedItem = null;
709
709
 
710
710
  if (this.allowCustomValue) {
711
- delete this._lastCustomValue;
712
711
  this.value = '';
713
712
  }
714
713
  } else {
@@ -725,27 +724,17 @@ export const ComboBoxMixin = (subclass) =>
725
724
  // to prevent a repetitive input value being saved after pressing ESC and Tab.
726
725
  !itemMatchingByLabel
727
726
  ) {
728
- const customValue = this._inputElementValue;
729
-
730
- // User's logic in `custom-value-set` event listener might cause input to blur,
731
- // which will result in attempting to commit the same custom value once again.
732
- if (this._lastCustomValue === customValue) {
733
- return;
734
- }
735
-
736
- // Store reference to the last custom value for checking it
737
- this._lastCustomValue = customValue;
738
-
739
727
  // An item matching by label was not found, but custom values are allowed.
740
728
  // Dispatch a custom-value-set event with the input value.
741
729
  const e = new CustomEvent('custom-value-set', {
742
- detail: customValue,
730
+ detail: this._inputElementValue,
743
731
  composed: true,
744
732
  cancelable: true,
745
733
  bubbles: true
746
734
  });
747
735
  this.dispatchEvent(e);
748
736
  if (!e.defaultPrevented) {
737
+ const customValue = this._inputElementValue;
749
738
  this._selectItemForValue(customValue);
750
739
  this.value = customValue;
751
740
  }