Skip to content

Commit

Permalink
Refactor routes to fix 'search' folder navigation in standalone gitne…
Browse files Browse the repository at this point in the history
…ss (harness#2135)
  • Loading branch information
rkapoor10 authored and Harness committed Jul 1, 2024
1 parent 06a5149 commit baa31cc
Showing 1 changed file with 14 additions and 14 deletions.
28 changes: 14 additions & 14 deletions web/src/RouteDestinations.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -328,20 +328,6 @@ export const RouteDestinations: React.FC = React.memo(function RouteDestinations
</LayoutWithSideNav>
</Route>

<Route
path={[routes.toCODESpaceSearch({ space: pathProps.space }), routes.toCODERepositorySearch({ repoPath })]}
exact>
<LayoutWithSideNav title={getString('search')}>
<CodeSearchPage />
</LayoutWithSideNav>
</Route>

<Route path={routes.toCODESemanticSearch({ repoPath })} exact>
<LayoutWithSideNav title={getString('pageTitle.search')}>
<Search />
</LayoutWithSideNav>
</Route>

<Route
path={routes.toCODEFileEdit({
repoPath,
Expand Down Expand Up @@ -388,6 +374,20 @@ export const RouteDestinations: React.FC = React.memo(function RouteDestinations
<Repository />
</LayoutWithSideNav>
</Route>

<Route
path={[routes.toCODESpaceSearch({ space: pathProps.space }), routes.toCODERepositorySearch({ repoPath })]}
exact>
<LayoutWithSideNav title={getString('search')}>
<CodeSearchPage />
</LayoutWithSideNav>
</Route>

<Route path={routes.toCODESemanticSearch({ repoPath })} exact>
<LayoutWithSideNav title={getString('pageTitle.search')}>
<Search />
</LayoutWithSideNav>
</Route>
</Switch>
</BrowserRouter>
)
Expand Down

0 comments on commit baa31cc

Please sign in to comment.