@vaadin/multi-select-combo-box 23.3.0-alpha3 → 23.3.0-alpha5

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/multi-select-combo-box",
3
- "version": "23.3.0-alpha3",
3
+ "version": "23.3.0-alpha5",
4
4
  "publishConfig": {
5
5
  "access": "public"
6
6
  },
@@ -37,23 +37,24 @@
37
37
  ],
38
38
  "dependencies": {
39
39
  "@polymer/polymer": "^3.0.0",
40
- "@vaadin/combo-box": "23.3.0-alpha3",
41
- "@vaadin/component-base": "23.3.0-alpha3",
42
- "@vaadin/field-base": "23.3.0-alpha3",
43
- "@vaadin/input-container": "23.3.0-alpha3",
44
- "@vaadin/lit-renderer": "23.3.0-alpha3",
45
- "@vaadin/vaadin-lumo-styles": "23.3.0-alpha3",
46
- "@vaadin/vaadin-material-styles": "23.3.0-alpha3",
47
- "@vaadin/vaadin-themable-mixin": "23.3.0-alpha3"
40
+ "@vaadin/combo-box": "23.3.0-alpha5",
41
+ "@vaadin/component-base": "23.3.0-alpha5",
42
+ "@vaadin/field-base": "23.3.0-alpha5",
43
+ "@vaadin/input-container": "23.3.0-alpha5",
44
+ "@vaadin/lit-renderer": "23.3.0-alpha5",
45
+ "@vaadin/vaadin-lumo-styles": "23.3.0-alpha5",
46
+ "@vaadin/vaadin-material-styles": "23.3.0-alpha5",
47
+ "@vaadin/vaadin-themable-mixin": "23.3.0-alpha5"
48
48
  },
49
49
  "devDependencies": {
50
50
  "@esm-bundle/chai": "^4.3.4",
51
51
  "@vaadin/testing-helpers": "^0.3.2",
52
+ "lit": "^2.0.0",
52
53
  "sinon": "^13.0.2"
53
54
  },
54
55
  "web-types": [
55
56
  "web-types.json",
56
57
  "web-types.lit.json"
57
58
  ],
58
- "gitHead": "e86cd2abf3e28bade37711291331415d92c454ec"
59
+ "gitHead": "0b6fdcf444683e97e3efb433d603e1274d5bcd66"
59
60
  }
@@ -969,10 +969,10 @@ class MultiSelectComboBox extends ResizeMixin(InputControlMixin(ThemableMixin(El
969
969
  this._onBackSpace(chips);
970
970
  break;
971
971
  case 'ArrowLeft':
972
- this._onArrowLeft(chips);
972
+ this._onArrowLeft(chips, event);
973
973
  break;
974
974
  case 'ArrowRight':
975
- this._onArrowRight(chips);
975
+ this._onArrowRight(chips, event);
976
976
  break;
977
977
  default:
978
978
  this._focusedChipIndex = -1;
@@ -982,12 +982,15 @@ class MultiSelectComboBox extends ResizeMixin(InputControlMixin(ThemableMixin(El
982
982
  }
983
983
 
984
984
  /** @private */
985
- _onArrowLeft(chips) {
986
- if (this.inputElement.value !== '' || this.opened) {
985
+ _onArrowLeft(chips, event) {
986
+ if (this.inputElement.selectionStart !== 0) {
987
987
  return;
988
988
  }
989
989
 
990
990
  const idx = this._focusedChipIndex;
991
+ if (idx !== -1) {
992
+ event.preventDefault();
993
+ }
991
994
  let newIdx;
992
995
 
993
996
  if (this.getAttribute('dir') !== 'rtl') {
@@ -1012,12 +1015,15 @@ class MultiSelectComboBox extends ResizeMixin(InputControlMixin(ThemableMixin(El
1012
1015
  }
1013
1016
 
1014
1017
  /** @private */
1015
- _onArrowRight(chips) {
1016
- if (this.inputElement.value !== '' || this.opened) {
1018
+ _onArrowRight(chips, event) {
1019
+ if (this.inputElement.selectionStart !== 0) {
1017
1020
  return;
1018
1021
  }
1019
1022
 
1020
1023
  const idx = this._focusedChipIndex;
1024
+ if (idx !== -1) {
1025
+ event.preventDefault();
1026
+ }
1021
1027
  let newIdx;
1022
1028
 
1023
1029
  if (this.getAttribute('dir') === 'rtl') {
@@ -1043,7 +1049,7 @@ class MultiSelectComboBox extends ResizeMixin(InputControlMixin(ThemableMixin(El
1043
1049
 
1044
1050
  /** @private */
1045
1051
  _onBackSpace(chips) {
1046
- if (this.inputElement.value !== '' || this.opened) {
1052
+ if (this.inputElement.selectionStart !== 0) {
1047
1053
  return;
1048
1054
  }
1049
1055
 
package/web-types.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "$schema": "https://json.schemastore.org/web-types",
3
3
  "name": "@vaadin/multi-select-combo-box",
4
- "version": "23.3.0-alpha3",
4
+ "version": "23.3.0-alpha5",
5
5
  "description-markup": "markdown",
6
6
  "contributions": {
7
7
  "html": {
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "$schema": "https://json.schemastore.org/web-types",
3
3
  "name": "@vaadin/multi-select-combo-box",
4
- "version": "23.3.0-alpha3",
4
+ "version": "23.3.0-alpha5",
5
5
  "description-markup": "markdown",
6
6
  "framework": "lit",
7
7
  "framework-config": {