From 4df2f622db86400aa74735c82f198fb11439c2fe Mon Sep 17 00:00:00 2001 From: melohagan <101575380+melohagan@users.noreply.github.com> Date: Tue, 3 Oct 2023 20:55:53 +0100 Subject: [PATCH 1/2] Do not re-initialise options if changed (#11964) * Do not re-initialise options if changed * Init options onMount --- .../bbui/src/OptionSelectDnD/OptionSelectDnD.svelte | 13 +++++-------- 1 file changed, 5 insertions(+), 8 deletions(-) diff --git a/packages/bbui/src/OptionSelectDnD/OptionSelectDnD.svelte b/packages/bbui/src/OptionSelectDnD/OptionSelectDnD.svelte index f64a51ade4..8b13135b33 100644 --- a/packages/bbui/src/OptionSelectDnD/OptionSelectDnD.svelte +++ b/packages/bbui/src/OptionSelectDnD/OptionSelectDnD.svelte @@ -21,14 +21,6 @@ "hsla(240, 90%, 75%, 0.3)", "hsla(320, 90%, 75%, 0.3)", ] - $: { - if (constraints.inclusion.length) { - options = constraints.inclusion.map(value => ({ - name: value, - id: Math.random(), - })) - } - } const removeInput = idx => { delete optionColors[options[idx].name] constraints.inclusion = constraints.inclusion.filter((e, i) => i !== idx) @@ -80,6 +72,11 @@ // Initialize anchor arrays on mount, assuming 'options' is already populated colorPopovers = constraints.inclusion.map(() => undefined) anchors = constraints.inclusion.map(() => undefined) + + options = constraints.inclusion.map(value => ({ + name: value, + id: Math.random(), + })) }) From 96b077f8a51ba95449924b2a06fe08412c091b5f Mon Sep 17 00:00:00 2001 From: Budibase Staging Release Bot <> Date: Tue, 3 Oct 2023 19:56:13 +0000 Subject: [PATCH 2/2] Bump version to 2.11.9 --- lerna.json | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/lerna.json b/lerna.json index a41c7cf2d9..8e9e1c548a 100644 --- a/lerna.json +++ b/lerna.json @@ -1,5 +1,5 @@ { - "version": "2.11.8", + "version": "2.11.9", "npmClient": "yarn", "packages": [ "packages/*"