From ad917419330088c25825a2fa53ac18aa19981990 Mon Sep 17 00:00:00 2001 From: semantic-release-bot Date: Thu, 14 Nov 2024 10:51:14 +0000 Subject: [PATCH 1/3] chore(release): 2.24.4 [skip ci] ## [2.24.4](https://github.com/eeditiones/tei-publisher-components/compare/v2.24.3...v2.24.4) (2024-11-14) ### Bug Fixes * **pb-table-grid:** respect existing search parameter when using included search feature ([7abdd8f](https://github.com/eeditiones/tei-publisher-components/commit/7abdd8fb67368f0a864a14354c98839e527dda94)) --- CHANGELOG.md | 7 +++++++ package-lock.json | 4 ++-- package.json | 2 +- 3 files changed, 10 insertions(+), 3 deletions(-) diff --git a/CHANGELOG.md b/CHANGELOG.md index b7750ada..c7ee5407 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -1,3 +1,10 @@ +## [2.24.4](https://github.com/eeditiones/tei-publisher-components/compare/v2.24.3...v2.24.4) (2024-11-14) + + +### Bug Fixes + +* **pb-table-grid:** respect existing search parameter when using included search feature ([7abdd8f](https://github.com/eeditiones/tei-publisher-components/commit/7abdd8fb67368f0a864a14354c98839e527dda94)) + ## [2.24.3](https://github.com/eeditiones/tei-publisher-components/compare/v2.24.2...v2.24.3) (2024-10-10) diff --git a/package-lock.json b/package-lock.json index dbea0fa6..cff8a927 100644 --- a/package-lock.json +++ b/package-lock.json @@ -1,12 +1,12 @@ { "name": "@teipublisher/pb-components", - "version": "2.24.3", + "version": "2.24.4", "lockfileVersion": 2, "requires": true, "packages": { "": { "name": "@teipublisher/pb-components", - "version": "2.24.3", + "version": "2.24.4", "license": "GPL-3.0-or-later", "dependencies": { "@babel/runtime": "7.11.2", diff --git a/package.json b/package.json index 278870ca..2d35761d 100644 --- a/package.json +++ b/package.json @@ -1,6 +1,6 @@ { "name": "@teipublisher/pb-components", - "version": "2.24.3", + "version": "2.24.4", "description": "Collection of webcomponents underlying TEI Publisher", "repository": "https://github.com/eeditiones/tei-publisher-components.git", "main": "index.html", From b6fdf68040484df01de23ee28f6461f525ce5423 Mon Sep 17 00:00:00 2001 From: raphael-m Date: Tue, 19 Nov 2024 17:21:56 +0100 Subject: [PATCH 2/3] fix(pb-combo-box): Clear items before refetching --- src/pb-combo-box.js | 10 +++++++++- 1 file changed, 9 insertions(+), 1 deletion(-) diff --git a/src/pb-combo-box.js b/src/pb-combo-box.js index fcd0a8d3..3df588ab 100644 --- a/src/pb-combo-box.js +++ b/src/pb-combo-box.js @@ -63,9 +63,11 @@ export class PbComboBox extends pbMixin(LitElement) { }, /** * Preload all items from the remote data source at startup + * Must be of type string because tom-select supports setting + * that property to "focus" (load data on focus) */ preload: { - type: Boolean + type: String }, /** * Name of the event to be emitted when the user leaves the form control @@ -160,6 +162,12 @@ export class PbComboBox extends pbMixin(LitElement) { options.searchField = []; options.preload = this.preload; options.load = (query, callback) => { + if (this._select) { + // The default behaviour of tom-select is to keep existing items when loading + // again from the source. We want to show only items the server provides, so + // we need to clear "stale" items before fetching. + this._select.clearOptions(); + } fetch(`${url}?query=${encodeURIComponent(query)}`, { method: 'GET', mode: 'cors', From 32e3d3d3278c6e94de466815b65feae29791cfa7 Mon Sep 17 00:00:00 2001 From: semantic-release-bot Date: Thu, 21 Nov 2024 09:10:01 +0000 Subject: [PATCH 3/3] chore(release): 2.24.5 [skip ci] ## [2.24.5](https://github.com/eeditiones/tei-publisher-components/compare/v2.24.4...v2.24.5) (2024-11-21) ### Bug Fixes * **pb-combo-box:** Clear items before refetching ([b6fdf68](https://github.com/eeditiones/tei-publisher-components/commit/b6fdf68040484df01de23ee28f6461f525ce5423)) --- CHANGELOG.md | 7 +++++++ package-lock.json | 4 ++-- package.json | 2 +- 3 files changed, 10 insertions(+), 3 deletions(-) diff --git a/CHANGELOG.md b/CHANGELOG.md index c7ee5407..b9815bf7 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -1,3 +1,10 @@ +## [2.24.5](https://github.com/eeditiones/tei-publisher-components/compare/v2.24.4...v2.24.5) (2024-11-21) + + +### Bug Fixes + +* **pb-combo-box:** Clear items before refetching ([b6fdf68](https://github.com/eeditiones/tei-publisher-components/commit/b6fdf68040484df01de23ee28f6461f525ce5423)) + ## [2.24.4](https://github.com/eeditiones/tei-publisher-components/compare/v2.24.3...v2.24.4) (2024-11-14) diff --git a/package-lock.json b/package-lock.json index cff8a927..4955f88b 100644 --- a/package-lock.json +++ b/package-lock.json @@ -1,12 +1,12 @@ { "name": "@teipublisher/pb-components", - "version": "2.24.4", + "version": "2.24.5", "lockfileVersion": 2, "requires": true, "packages": { "": { "name": "@teipublisher/pb-components", - "version": "2.24.4", + "version": "2.24.5", "license": "GPL-3.0-or-later", "dependencies": { "@babel/runtime": "7.11.2", diff --git a/package.json b/package.json index 2d35761d..ff54c919 100644 --- a/package.json +++ b/package.json @@ -1,6 +1,6 @@ { "name": "@teipublisher/pb-components", - "version": "2.24.4", + "version": "2.24.5", "description": "Collection of webcomponents underlying TEI Publisher", "repository": "https://github.com/eeditiones/tei-publisher-components.git", "main": "index.html",