diff --git a/src/scripts/choices.ts b/src/scripts/choices.ts index a4f79e4db..57d3f4b74 100644 --- a/src/scripts/choices.ts +++ b/src/scripts/choices.ts @@ -1227,6 +1227,8 @@ class Choices { this._store.withTxn(() => { // Remove item associated with button this._removeItem(itemToRemove); + const passedElementValueModified = this.passedElement.value.split(",").filter(x=> x !== itemToRemove.value) + this.passedElement.value = passedElementValueModified.join(",") this._triggerChange(itemToRemove.value); if (this._isSelectOneElement && !this._hasNonChoicePlaceholder) {