From 129f5369a6cb27c2b464fa30a88d068accea849a Mon Sep 17 00:00:00 2001 From: Nursoltan Saipolda Date: Wed, 10 Nov 2021 02:08:48 +0800 Subject: [PATCH 1/2] hide home link on onboarding flow --- src/components/NavBar/index.jsx | 24 +++++++++++------------- 1 file changed, 11 insertions(+), 13 deletions(-) diff --git a/src/components/NavBar/index.jsx b/src/components/NavBar/index.jsx index 60e1be6..1ec82bd 100644 --- a/src/components/NavBar/index.jsx +++ b/src/components/NavBar/index.jsx @@ -3,7 +3,7 @@ * * Shows global top navigation bar with all apps menu, logo and user menu. */ -import React, { + import React, { useState, useCallback, Fragment, @@ -51,6 +51,12 @@ const NavBar = ({ hideSwitchTools }) => { [setActiveApp] ); + const renderTopcoderLogo = hideSwitchTools ? null : ( + + Topcoder Logo + + ); + return (
@@ -60,10 +66,8 @@ const NavBar = ({ hideSwitchTools }) => { ) ) : ( - - Topcoder Logo - -
+ {renderTopcoderLogo} + {hideSwitchTools ? null :
}
{activeApp ? activeApp.title : ""}
@@ -72,13 +76,7 @@ const NavBar = ({ hideSwitchTools }) => {
- {isMobile ? ( - - Topcoder Logo - - ) : ( - - )} + {isMobile ? renderTopcoderLogo : } {process.env.NODE_ENV === "test" && (

Navbar App Test

)} @@ -107,7 +105,7 @@ const NavBar = ({ hideSwitchTools }) => { ) : ( {hideSwitchTools ? null : } -
+ {hideSwitchTools ? null :
} {auth.isInitialized && (auth.tokenV3 ? ( auth.profile && ( From bf67cb845652659f53c3f7dceb2464a82dbd4ac2 Mon Sep 17 00:00:00 2001 From: Nursoltan Saipolda Date: Wed, 10 Nov 2021 02:18:23 +0800 Subject: [PATCH 2/2] change link --- src/components/NavBar/index.jsx | 8 +++++--- 1 file changed, 5 insertions(+), 3 deletions(-) diff --git a/src/components/NavBar/index.jsx b/src/components/NavBar/index.jsx index 1ec82bd..48a50f4 100644 --- a/src/components/NavBar/index.jsx +++ b/src/components/NavBar/index.jsx @@ -51,7 +51,9 @@ const NavBar = ({ hideSwitchTools }) => { [setActiveApp] ); - const renderTopcoderLogo = hideSwitchTools ? null : ( + const renderTopcoderLogo = hideSwitchTools ? ( + Topcoder Logo + ) : ( Topcoder Logo @@ -67,7 +69,7 @@ const NavBar = ({ hideSwitchTools }) => { ) : ( {renderTopcoderLogo} - {hideSwitchTools ? null :
} +
{activeApp ? activeApp.title : ""}
@@ -105,7 +107,7 @@ const NavBar = ({ hideSwitchTools }) => { ) : ( {hideSwitchTools ? null : } - {hideSwitchTools ? null :
} +
{auth.isInitialized && (auth.tokenV3 ? ( auth.profile && (