From 0f425f8811174ccb50b2e1485d3de242c23e45c0 Mon Sep 17 00:00:00 2001 From: Eklal Budhathoki Date: Mon, 20 Mar 2023 11:53:25 +0545 Subject: [PATCH] fix: Fixed multiselect component label update (#5352) * Fixed documentation issue in widgets -> table.md (#5226) * [docs] Fixed edit page link (#5253) * [docs]:fixed edit page link * [docs]:fixed edit page link * Update render-preview-deploy.yml (#5282) * fix: Fixed multiselect component label update * Update table.md --------- Co-authored-by: Harsh Mange Co-authored-by: Jittojoyes98 <51293782+Jittojoyes98@users.noreply.github.com> Co-authored-by: Adish M <44204658+adishM98@users.noreply.github.com> Co-authored-by: Kavin Venkatachalam <50441969+kavinvenkatachalam@users.noreply.github.com> --- frontend/src/Editor/Components/Multiselect.jsx | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/frontend/src/Editor/Components/Multiselect.jsx b/frontend/src/Editor/Components/Multiselect.jsx index 84c03098eb..eb24409c97 100644 --- a/frontend/src/Editor/Components/Multiselect.jsx +++ b/frontend/src/Editor/Components/Multiselect.jsx @@ -46,13 +46,13 @@ export const Multiselect = function Multiselect({ setExposedVariable('values', newValues); setSelected(selectOptions.filter((option) => newValues.includes(option.value))); // eslint-disable-next-line react-hooks/exhaustive-deps - }, [JSON.stringify(values)]); + }, [JSON.stringify(values), JSON.stringify(display_values)]); useEffect(() => { setExposedVariable('values', value); setSelected(selectOptions.filter((option) => value.includes(option.value))); // eslint-disable-next-line react-hooks/exhaustive-deps - }, [JSON.stringify(value)]); + }, [JSON.stringify(value), JSON.stringify(display_values)]); useEffect(() => { if (value && !selected) {