From d48a513f2960a6164d9376ec1d290123a5bf3d5b Mon Sep 17 00:00:00 2001 From: krishna2323 Date: Tue, 20 Aug 2024 16:51:11 +0530 Subject: [PATCH] fix: Workspace - ESC key does not dismiss popup in Distance rates. Signed-off-by: krishna2323 --- src/pages/settings/AboutPage/ConsolePage.tsx | 1 + .../workspace/distanceRates/PolicyDistanceRateDetailsPage.tsx | 1 + src/pages/workspace/distanceRates/PolicyDistanceRatesPage.tsx | 1 + 3 files changed, 3 insertions(+) diff --git a/src/pages/settings/AboutPage/ConsolePage.tsx b/src/pages/settings/AboutPage/ConsolePage.tsx index eb9b13608039..21ce3a7907cc 100644 --- a/src/pages/settings/AboutPage/ConsolePage.tsx +++ b/src/pages/settings/AboutPage/ConsolePage.tsx @@ -215,6 +215,7 @@ function ConsolePage({capturedLogs, shouldStoreLogs}: ConsolePageProps) { title={translate('initialSettingsPage.debugConsole.shareLog')} isVisible={isLimitModalVisible} onConfirm={() => setIsLimitModalVisible(false)} + onCancel={() => setIsLimitModalVisible(false)} prompt={translate('initialSettingsPage.debugConsole.logSizeTooLarge', { size: CONST.API_ATTACHMENT_VALIDATIONS.MAX_SIZE / 1024 / 1024, })} diff --git a/src/pages/workspace/distanceRates/PolicyDistanceRateDetailsPage.tsx b/src/pages/workspace/distanceRates/PolicyDistanceRateDetailsPage.tsx index 00204d1e40c7..8f4e274b3d86 100644 --- a/src/pages/workspace/distanceRates/PolicyDistanceRateDetailsPage.tsx +++ b/src/pages/workspace/distanceRates/PolicyDistanceRateDetailsPage.tsx @@ -183,6 +183,7 @@ function PolicyDistanceRateDetailsPage({policy, route}: PolicyDistanceRateDetail /> setIsWarningModalVisible(false)} + onCancel={() => setIsWarningModalVisible(false)} isVisible={isWarningModalVisible} title={translate('workspace.distanceRates.oopsNotSoFast')} prompt={translate('workspace.distanceRates.workspaceNeeds')} diff --git a/src/pages/workspace/distanceRates/PolicyDistanceRatesPage.tsx b/src/pages/workspace/distanceRates/PolicyDistanceRatesPage.tsx index c13538d45d4c..0b2e83f458ff 100644 --- a/src/pages/workspace/distanceRates/PolicyDistanceRatesPage.tsx +++ b/src/pages/workspace/distanceRates/PolicyDistanceRatesPage.tsx @@ -338,6 +338,7 @@ function PolicyDistanceRatesPage({ )} setIsWarningModalVisible(false)} + onCancel={() => setIsWarningModalVisible(false)} isVisible={isWarningModalVisible} title={translate('workspace.distanceRates.oopsNotSoFast')} prompt={translate('workspace.distanceRates.workspaceNeeds')}