From 341a58e68f30110e832dd5d9473f91ce26f68bc5 Mon Sep 17 00:00:00 2001 From: Pawan Kumar Date: Tue, 11 Jun 2024 12:47:17 +0530 Subject: [PATCH] chore: fix Read only widget incorrectly triggers configured actions that are hidden because of the toggle (#34134) MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Fixes #34000 /ok-to-test tags="@tag.Anvil" > [!TIP] > 🟢 🟢 🟢 All cypress tests have passed! 🎉 🎉 🎉 > Workflow run: > Commit: fd17eacb6f9edee8905fb5cf1054b56822f2c3cd > Cypress dashboard url: Click here! Co-authored-by: Pawan Kumar --- app/client/src/widgets/wds/WDSInputWidget/widget/index.tsx | 2 ++ 1 file changed, 2 insertions(+) diff --git a/app/client/src/widgets/wds/WDSInputWidget/widget/index.tsx b/app/client/src/widgets/wds/WDSInputWidget/widget/index.tsx index 9de9d5da8d..35823822eb 100644 --- a/app/client/src/widgets/wds/WDSInputWidget/widget/index.tsx +++ b/app/client/src/widgets/wds/WDSInputWidget/widget/index.tsx @@ -83,6 +83,8 @@ class WDSInputWidget extends WDSBaseInputWidget { } onFocusChange = (focusState: boolean) => { + if (this.props.isReadOnly) return; + if (focusState) { this.props.updateWidgetMetaProperty("isFocused", focusState, { triggerPropertyName: "onFocus",