From e8843ded5bf1f3d97b735ffe8f8553de46f9b18b Mon Sep 17 00:00:00 2001 From: Paul Frazee Date: Fri, 2 Jun 2023 15:01:04 -0500 Subject: Fix a bunch of type errors and add a type-check to the github workflows (#837) * Add yarn type-check * Rename to yarn typecheck * Fix a collection of type errors * Add typecheck to automated tests * add `dist` to exluded folders tsconfig --------- Co-authored-by: Ansh Nanda --- src/view/shell/desktop/LeftNav.tsx | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) (limited to 'src/view/shell/desktop/LeftNav.tsx') diff --git a/src/view/shell/desktop/LeftNav.tsx b/src/view/shell/desktop/LeftNav.tsx index 8c701ea4e..9f047418b 100644 --- a/src/view/shell/desktop/LeftNav.tsx +++ b/src/view/shell/desktop/LeftNav.tsx @@ -34,7 +34,7 @@ import { SatelliteDishIconSolid, } from 'lib/icons' import {getCurrentRoute, isTab, isStateAtTabRoot} from 'lib/routes/helpers' -import {NavigationProp} from 'lib/routes/types' +import {NavigationProp, CommonNavigatorParams} from 'lib/routes/types' import {router} from '../../../routes' const ProfileCard = observer(() => { @@ -100,7 +100,8 @@ const NavItem = observer( let isCurrent = currentRouteInfo.name === 'Profile' ? isTab(currentRouteInfo.name, pathName) && - currentRouteInfo.params.name === store.me.handle + (currentRouteInfo.params as CommonNavigatorParams['Profile']).name === + store.me.handle : isTab(currentRouteInfo.name, pathName) const {onPress} = useLinkProps({to: href}) const onPressWrapped = React.useCallback( @@ -122,6 +123,7 @@ const NavItem = observer(