From a6df7d3cfe183cd22d9c884053ad71948ba82f3b Mon Sep 17 00:00:00 2001 From: NguyenTranHoangSym Date: Fri, 17 Mar 2023 11:36:04 +0700 Subject: [PATCH] SDA-4101: Welcome screen does not focus after launch the SDA --- spec/__snapshots__/welcome.spec.ts.snap | 2 ++ src/app/window-handler.ts | 1 + src/renderer/components/welcome.tsx | 2 ++ 3 files changed, 5 insertions(+) diff --git a/spec/__snapshots__/welcome.spec.ts.snap b/spec/__snapshots__/welcome.spec.ts.snap index f7b6c0fd..91f5d8ad 100644 --- a/spec/__snapshots__/welcome.spec.ts.snap +++ b/spec/__snapshots__/welcome.spec.ts.snap @@ -118,6 +118,7 @@ exports[`welcome should render correctly 1`] = ` className="Welcome-main-container-podurl-box" data-testid="Welcome-main-container-podurl-box" onChange={[Function]} + tabIndex={0} type="url" value="https://[POD].symphony.com" /> @@ -134,6 +135,7 @@ exports[`welcome should render correctly 1`] = ` disabled={true} onClick={[Function]} style={Object {}} + tabIndex={1} > log in diff --git a/src/app/window-handler.ts b/src/app/window-handler.ts index 99fe0689..7b4f138b 100644 --- a/src/app/window-handler.ts +++ b/src/app/window-handler.ts @@ -569,6 +569,7 @@ export class WindowHandler { isSeamlessLoginEnabled: this.config.enableBrowserLogin, }); this.didShowWelcomeScreen = true; + this.mainWebContents.focus(); } // Injects custom title bar and snack bar css into the webContents diff --git a/src/renderer/components/welcome.tsx b/src/renderer/components/welcome.tsx index 33e3b1f8..b97056c5 100644 --- a/src/renderer/components/welcome.tsx +++ b/src/renderer/components/welcome.tsx @@ -76,6 +76,7 @@ export default class Welcome extends React.Component<{}, IState> { { return (