From 18259d70235fd894ab911b8e6c5d41b5e3160d31 Mon Sep 17 00:00:00 2001 From: Sibtain Ali Date: Tue, 5 Sep 2023 15:53:35 +0500 Subject: [PATCH 1/2] fix: download app modal hide permanently when clicked on download --- src/components/DownloadAppModal.js | 2 ++ 1 file changed, 2 insertions(+) diff --git a/src/components/DownloadAppModal.js b/src/components/DownloadAppModal.js index ffa933708e4c..831f0b5554e8 100644 --- a/src/components/DownloadAppModal.js +++ b/src/components/DownloadAppModal.js @@ -44,6 +44,8 @@ function DownloadAppModal({isAuthenticated, showDownloadAppBanner}) { } const handleOpenAppStore = () => { + setShowDownloadAppModal(false); + setshouldShowBanner(false); Link.openExternalLink(link, true); }; From c698c08ebdbe7932a82eb8a3822e4d03cf406883 Mon Sep 17 00:00:00 2001 From: Sibtain Ali Date: Tue, 5 Sep 2023 16:23:23 +0500 Subject: [PATCH 2/2] fix: set state typo in the download app modal component --- src/components/DownloadAppModal.js | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/src/components/DownloadAppModal.js b/src/components/DownloadAppModal.js index 831f0b5554e8..c96c6b3d28c0 100644 --- a/src/components/DownloadAppModal.js +++ b/src/components/DownloadAppModal.js @@ -26,13 +26,13 @@ const defaultProps = { }; function DownloadAppModal({isAuthenticated, showDownloadAppBanner}) { - const [shouldShowBanner, setshouldShowBanner] = useState(Browser.isMobile() && isAuthenticated && showDownloadAppBanner); + const [shouldShowBanner, setShouldShowBanner] = useState(Browser.isMobile() && isAuthenticated && showDownloadAppBanner); const {translate} = useLocalize(); const handleCloseBanner = () => { setShowDownloadAppModal(false); - setshouldShowBanner(false); + setShouldShowBanner(false); }; let link = ''; @@ -45,7 +45,7 @@ function DownloadAppModal({isAuthenticated, showDownloadAppBanner}) { const handleOpenAppStore = () => { setShowDownloadAppModal(false); - setshouldShowBanner(false); + setShouldShowBanner(false); Link.openExternalLink(link, true); };