@vaadin/vaadin-combo-box 21.0.0-beta2 → 21.0.2

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/README.md CHANGED
@@ -1,12 +1,3 @@
1
- [![npm latest version](https://badgen.net/npm/v/@vaadin/vaadin-combo-box/latest)](https://www.npmjs.com/package/@vaadin/vaadin-combo-box)
2
- [![Published on webcomponents.org](https://img.shields.io/badge/webcomponents.org-published-blue.svg)](https://www.webcomponents.org/element/vaadin/vaadin-combo-box)
3
- [![Build Status](https://travis-ci.org/vaadin/vaadin-combo-box.svg?branch=master)](https://travis-ci.org/vaadin/vaadin-combo-box)
4
- [![Coverage Status](https://coveralls.io/repos/github/vaadin/vaadin-combo-box/badge.svg?branch=master)](https://coveralls.io/github/vaadin/vaadin-combo-box?branch=master)
5
- [![Gitter](https://badges.gitter.im/Join%20Chat.svg)](https://gitter.im/vaadin/web-components?utm_source=badge&utm_medium=badge&utm_campaign=pr-badge)
6
-
7
- [![Published on Vaadin Directory](https://img.shields.io/badge/Vaadin%20Directory-published-00b4f0.svg)](https://vaadin.com/directory/component/vaadinvaadin-combo-box)
8
- [![Stars on vaadin.com/directory](https://img.shields.io/vaadin-directory/star/vaadinvaadin-combo-box.svg)](https://vaadin.com/directory/component/vaadinvaadin-combo-box)
9
-
10
1
  # <vaadin-combo-box>
11
2
 
12
3
  [Live Demo ↗](https://vaadin.com/components/vaadin-combo-box/html-examples)
@@ -15,15 +6,24 @@
15
6
 
16
7
  [<vaadin-combo-box>](https://vaadin.com/components/vaadin-combo-box) is a Web Component combining a dropdown list with an input field for filtering the list of items, part of the [Vaadin components](https://vaadin.com/components).
17
8
 
9
+ [![npm version](https://badgen.net/npm/v/@vaadin/vaadin-combo-box)](https://www.npmjs.com/package/@vaadin/vaadin-combo-box)
10
+ [![Published on Vaadin Directory](https://img.shields.io/badge/Vaadin%20Directory-published-00b4f0.svg)](https://vaadin.com/directory/component/vaadinvaadin-combo-box)
11
+ [![Discord](https://img.shields.io/discord/732335336448852018?label=discord)](https://discord.gg/PHmkCKC)
12
+
18
13
  ```html
19
- <vaadin-combo-box label="User" placeholder="Please select" item-value-path="email" item-label-path="email"></vaadin-combo-box>
14
+ <vaadin-combo-box
15
+ label="User"
16
+ placeholder="Please select"
17
+ item-value-path="email"
18
+ item-label-path="email"
19
+ ></vaadin-combo-box>
20
20
 
21
21
  <script>
22
22
  const comboBox = document.querySelector('vaadin-combo-box');
23
23
 
24
24
  fetch('https://randomuser.me/api?results=100&inc=name,email')
25
- .then(res => res.json())
26
- .then(json => comboBox.items = json.results);
25
+ .then((res) => res.json())
26
+ .then((json) => (comboBox.items = json.results));
27
27
  </script>
28
28
  ```
29
29
 
@@ -67,46 +67,9 @@ To use the Material theme, import the correspondent file from the `theme/materia
67
67
  `vaadin-combo-box.js`
68
68
  `vaadin-combo-box-light.js`
69
69
 
70
-
71
- ## Running API docs and tests in a browser
72
-
73
- 1. Fork the `vaadin-combo-box` repository and clone it locally.
74
-
75
- 1. Make sure you have [node.js](https://nodejs.org/) 12.x installed.
76
-
77
- 1. Make sure you have [npm](https://www.npmjs.com/) installed.
78
-
79
- 1. When in the `vaadin-combo-box` directory, run `npm install` to install dependencies.
80
-
81
- 1. Run `npm start`, browser will automatically open the component API documentation.
82
-
83
- 1. You can also open visual tests, for example:
84
-
85
- - http://127.0.0.1:3000/test/visual/default.html
86
-
87
-
88
- ## Running tests from the command line
89
-
90
- 1. When in the `vaadin-combo-box` directory, run `npm test`
91
-
92
- ## Debugging tests in the browser
93
-
94
- 1. Run `npm run debug`, then choose manual mode (M) and open the link in browser.
95
-
96
- ## Following the coding style
97
-
98
- We are using [ESLint](http://eslint.org/) for linting JavaScript code. You can check if your code is following our standards by running `npm run lint`, which will automatically lint all `.js` files.
99
-
100
-
101
- ## Big Thanks
102
-
103
- Cross-browser Testing Platform and Open Source <3 Provided by [Sauce Labs](https://saucelabs.com).
104
-
105
-
106
70
  ## Contributing
107
71
 
108
- To contribute to the component, please read [the guideline](https://github.com/vaadin/vaadin-core/blob/master/CONTRIBUTING.md) first.
109
-
72
+ Read the [contributing guide](https://vaadin.com/docs/latest/guide/contributing/overview) to learn about our development process, how to propose bugfixes and improvements, and how to test your changes to Vaadin components.
110
73
 
111
74
  ## License
112
75
 
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@vaadin/vaadin-combo-box",
3
- "version": "21.0.0-beta2",
3
+ "version": "21.0.2",
4
4
  "description": "Web Component for displaying a list of items with filtering",
5
5
  "main": "vaadin-combo-box.js",
6
6
  "repository": "vaadin/vaadin-combo-box",
@@ -28,26 +28,27 @@
28
28
  "@polymer/iron-list": "^3.0.0",
29
29
  "@polymer/iron-resizable-behavior": "^3.0.0",
30
30
  "@polymer/polymer": "^3.0.0",
31
- "@vaadin/vaadin-control-state-mixin": "^21.0.0-beta2",
32
- "@vaadin/vaadin-element-mixin": "^21.0.0-beta2",
33
- "@vaadin/vaadin-item": "^21.0.0-beta2",
34
- "@vaadin/vaadin-lumo-styles": "^21.0.0-beta2",
35
- "@vaadin/vaadin-material-styles": "^21.0.0-beta2",
36
- "@vaadin/vaadin-overlay": "^21.0.0-beta2",
37
- "@vaadin/vaadin-text-field": "^21.0.0-beta2",
38
- "@vaadin/vaadin-themable-mixin": "^21.0.0-beta2"
31
+ "@vaadin/vaadin-control-state-mixin": "^21.0.2",
32
+ "@vaadin/vaadin-element-mixin": "^21.0.2",
33
+ "@vaadin/vaadin-item": "^21.0.2",
34
+ "@vaadin/vaadin-lumo-styles": "^21.0.2",
35
+ "@vaadin/vaadin-material-styles": "^21.0.2",
36
+ "@vaadin/vaadin-overlay": "^21.0.2",
37
+ "@vaadin/vaadin-text-field": "^21.0.2",
38
+ "@vaadin/vaadin-themable-mixin": "^21.0.2"
39
39
  },
40
40
  "devDependencies": {
41
41
  "@esm-bundle/chai": "4.3.0",
42
42
  "@polymer/iron-input": "^3.0.1",
43
43
  "@polymer/paper-input": "^3.0.0",
44
44
  "@vaadin/testing-helpers": "^0.2.1",
45
- "@vaadin/vaadin-dialog": "^21.0.0-beta2",
46
- "@vaadin/vaadin-template-renderer": "^21.0.0-beta2",
45
+ "@vaadin/vaadin-dialog": "^21.0.2",
46
+ "@vaadin/vaadin-template-renderer": "^21.0.2",
47
+ "lit": "^2.0.0",
47
48
  "sinon": "^9.2.0"
48
49
  },
49
50
  "publishConfig": {
50
51
  "access": "public"
51
52
  },
52
- "gitHead": "85ac717fc9f16941a1593a44d1aec90735a5db54"
53
+ "gitHead": "6d0571bce4ecc084a9c40b9d72d7c7cecaeae196"
53
54
  }
@@ -145,6 +145,10 @@ class ComboBoxItemElement extends ThemableMixin(DirMixin(PolymerElement)) {
145
145
 
146
146
  if (this._oldRenderer !== renderer) {
147
147
  this.$.content.innerHTML = '';
148
+ // Whenever a Lit-based renderer is used, it assigns a Lit part to the node it was rendered into.
149
+ // When clearing the rendered content, this part needs to be manually disposed of.
150
+ // Otherwise, using a Lit-based renderer on the same node will throw an exception or render nothing afterward.
151
+ delete this.$.content._$litPart$;
148
152
  }
149
153
 
150
154
  if (renderer) {
@@ -243,7 +243,7 @@ class ComboBoxElement extends ElementMixin(
243
243
  }
244
244
 
245
245
  static get version() {
246
- return '21.0.0-beta2';
246
+ return '21.0.2';
247
247
  }
248
248
 
249
249
  static get properties() {