-
Notifications
You must be signed in to change notification settings - Fork 901
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
fix(core): Improve navigation terminology (#8370)
* fix(core): Improve navigation terminology * fix(core): Improve navigation terminology
- Loading branch information
1 parent
049cceb
commit 9c418d5
Showing
7 changed files
with
47 additions
and
47 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,22 +1,22 @@ | ||
import React from 'react'; | ||
import { useIsActive, useSrefActive } from '@uirouter/react'; | ||
|
||
import { NavCategory } from './NavCategory'; | ||
import { NavItem } from './NavItem'; | ||
import { ApplicationDataSource } from '../service/applicationDataSource'; | ||
import { Application } from '../../application'; | ||
|
||
export interface INavRouteProps { | ||
category: ApplicationDataSource; | ||
dataSource: ApplicationDataSource; | ||
app: Application; | ||
} | ||
|
||
export const NavRoute = ({ app, category }: INavRouteProps) => { | ||
const sref = useSrefActive(category.sref, null, 'active'); | ||
const isActive = useIsActive(category.activeState); | ||
export const NavRoute = ({ app, dataSource }: INavRouteProps) => { | ||
const sref = useSrefActive(dataSource.sref, null, 'active'); | ||
const isActive = useIsActive(dataSource.activeState); | ||
|
||
return ( | ||
<a {...sref}> | ||
<NavCategory app={app} category={category} isActive={isActive} /> | ||
<NavItem app={app} dataSource={dataSource} isActive={isActive} /> | ||
</a> | ||
); | ||
}; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters