From c5c39ab61cdbbc286fdf2dfde7beb74e0e1302a9 Mon Sep 17 00:00:00 2001 From: Imamah-Zafar <88320460+Imamah-Zafar@users.noreply.github.com> Date: Tue, 6 Dec 2022 11:40:44 +0500 Subject: [PATCH 1/2] fix browser tx pop up scroll and navigation --- src/app/screens/login/index.tsx | 2 +- src/background/legacy-external-message-handler.ts | 4 ++-- src/background/popup-center.ts | 2 +- src/pages/Popup/index.css | 4 ++++ 4 files changed, 8 insertions(+), 4 deletions(-) diff --git a/src/app/screens/login/index.tsx b/src/app/screens/login/index.tsx index a0f3cc33b..4884b3739 100644 --- a/src/app/screens/login/index.tsx +++ b/src/app/screens/login/index.tsx @@ -125,7 +125,7 @@ function Login(): JSX.Element { try { await unlockWallet(password); setIsVerifying(false); - navigate('/'); + navigate(-1); } catch (err) { setIsVerifying(false); setError(t('VERIFY_PASSWORD_ERROR')); diff --git a/src/background/legacy-external-message-handler.ts b/src/background/legacy-external-message-handler.ts index 5c9e386b6..ca94eb89b 100644 --- a/src/background/legacy-external-message-handler.ts +++ b/src/background/legacy-external-message-handler.ts @@ -83,8 +83,8 @@ function listenForOriginTabClose({ tabId }: ListenForOriginTabCloseArgs) { async function triggerRequstWindowOpen(path: RequestsRoutes, urlParams: URLSearchParams) { // if (IS_TEST_ENV) return openRequestInFullPage(path, urlParams); - console.log(`/options.html#${path}?${urlParams.toString()}`); - return popupCenter({ url: `/options.html#${path}?${urlParams.toString()}` }); + console.log(`/popup.html#${path}?${urlParams.toString()}`); + return popupCenter({ url: `/popup.html#${path}?${urlParams.toString()}` }); } export async function handleLegacyExternalMethodFormat( diff --git a/src/background/popup-center.ts b/src/background/popup-center.ts index df9fe3dde..78b3fd753 100644 --- a/src/background/popup-center.ts +++ b/src/background/popup-center.ts @@ -8,7 +8,7 @@ interface PopupOptions { skipPopupFallback?: boolean; } export default function popupCenter(options: PopupOptions): Promise { - const { url, w = 400, h = 690 } = options; + const { url, w = 360, h = 600 } = options; return new Promise((resolve) => { chrome.windows.getCurrent(async (win) => { // the farthest left/top sides of all displays diff --git a/src/pages/Popup/index.css b/src/pages/Popup/index.css index be080b8c7..89e162382 100644 --- a/src/pages/Popup/index.css +++ b/src/pages/Popup/index.css @@ -7,4 +7,8 @@ body { #app { width: 360px; height: 600px; +} + +::-webkit-scrollbar { + display: none; } \ No newline at end of file From 25c395ff61dc6ca351de2c458fa7a958491b4d94 Mon Sep 17 00:00:00 2001 From: Imamah-Zafar <88320460+Imamah-Zafar@users.noreply.github.com> Date: Tue, 6 Dec 2022 18:00:16 +0500 Subject: [PATCH 2/2] change version number --- package.json | 2 +- src/app/screens/landing/index.tsx | 9 +++++++++ src/app/screens/login/index.tsx | 2 +- src/app/screens/settings/index.tsx | 2 +- 4 files changed, 12 insertions(+), 3 deletions(-) diff --git a/package.json b/package.json index 765cee770..b12c0c7db 100644 --- a/package.json +++ b/package.json @@ -1,7 +1,7 @@ { "name": "xverse-web-extension", "description": "A Bitcoin wallet for Web3", - "version": "0.0.1", + "version": "0.1.0", "private": true, "dependencies": { "@secretkeylabs/xverse-core": "github:secretkeylabs/xverse-core", diff --git a/src/app/screens/landing/index.tsx b/src/app/screens/landing/index.tsx index 5598e016a..a0d5bded3 100644 --- a/src/app/screens/landing/index.tsx +++ b/src/app/screens/landing/index.tsx @@ -46,6 +46,14 @@ const CreateButton = styled.button((props) => ({ height: 44, })); +const AppVersion = styled.p((props) => ({ + ...props.theme.body_xs, + color: props.theme.colors.white['0'], + textAlign: 'right', + marginRight: props.theme.spacing(9), + marginTop: props.theme.spacing(8), +})); + const RestoreButton = styled.button((props) => ({ display: 'flex', ...props.theme.body_xs, @@ -94,6 +102,7 @@ function Landing(): JSX.Element { }; return ( <> + Beta version logo {t('SCREEN_TITLE')} diff --git a/src/app/screens/login/index.tsx b/src/app/screens/login/index.tsx index 4884b3739..1c20434ca 100644 --- a/src/app/screens/login/index.tsx +++ b/src/app/screens/login/index.tsx @@ -138,7 +138,7 @@ function Login(): JSX.Element { return ( - {VERSION} + Beta version logo {t('WELCOME_MESSAGE_FIRST_LOGIN')} diff --git a/src/app/screens/settings/index.tsx b/src/app/screens/settings/index.tsx index 489c18e8d..175f18e2c 100644 --- a/src/app/screens/settings/index.tsx +++ b/src/app/screens/settings/index.tsx @@ -186,7 +186,7 @@ function Setting() { icon={ArrowSquareOut} showDivider /> - +