From e4a1f356b3fdd45fb53dd6590513189f4b202a4e Mon Sep 17 00:00:00 2001 From: Mel O'Hagan Date: Tue, 16 Aug 2022 13:36:48 +0100 Subject: [PATCH 01/19] Only allow bindings type for Is In Conditional UI --- .../_components/settings/ConditionalUIDrawer.svelte | 11 +++++++++-- packages/frontend-core/src/utils/lucene.js | 2 +- 2 files changed, 10 insertions(+), 3 deletions(-) diff --git a/packages/builder/src/pages/builder/app/[application]/design/[screenId]/components/[componentId]/_components/settings/ConditionalUIDrawer.svelte b/packages/builder/src/pages/builder/app/[application]/design/[screenId]/components/[componentId]/_components/settings/ConditionalUIDrawer.svelte index b40b33744f..524b712755 100644 --- a/packages/builder/src/pages/builder/app/[application]/design/[screenId]/components/[componentId]/_components/settings/ConditionalUIDrawer.svelte +++ b/packages/builder/src/pages/builder/app/[application]/design/[screenId]/components/[componentId]/_components/settings/ConditionalUIDrawer.svelte @@ -112,7 +112,7 @@ Constants.OperatorOptions.NotEmpty.value, ] condition.noValue = noValueOptions.includes(newOperator) - if (condition.noValue) { + if (condition.noValue || condition.operator === "oneOf") { condition.referenceValue = null condition.valueType = "string" } @@ -207,7 +207,14 @@ /> Date: Wed, 17 Aug 2022 16:44:48 +0100 Subject: [PATCH 03/19] Refactors --- .../_components/settings/ConditionalUIDrawer.svelte | 11 ++--------- 1 file changed, 2 insertions(+), 9 deletions(-) diff --git a/packages/builder/src/pages/builder/app/[application]/design/[screenId]/components/[componentId]/_components/settings/ConditionalUIDrawer.svelte b/packages/builder/src/pages/builder/app/[application]/design/[screenId]/components/[componentId]/_components/settings/ConditionalUIDrawer.svelte index 7589507b21..c386a52cb7 100644 --- a/packages/builder/src/pages/builder/app/[application]/design/[screenId]/components/[componentId]/_components/settings/ConditionalUIDrawer.svelte +++ b/packages/builder/src/pages/builder/app/[application]/design/[screenId]/components/[componentId]/_components/settings/ConditionalUIDrawer.svelte @@ -112,7 +112,7 @@ Constants.OperatorOptions.NotEmpty.value, ] condition.noValue = noValueOptions.includes(newOperator) - if (condition.noValue || condition.operator === "oneOf") { + if (condition.noValue || newOperator === "oneOf") { condition.referenceValue = null condition.valueType = "string" } @@ -207,14 +207,7 @@ />