-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #13 from RaphaelEscrig/feat/enhance-ux
Enhance ux
- Loading branch information
Showing
12 changed files
with
82 additions
and
5 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
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 |
---|---|---|
@@ -0,0 +1,13 @@ | ||
/** MODELS */ | ||
import type { LayoutHeader } from "@/modules/layout/core/domain/models"; | ||
|
||
export const HEADER_NAVIGATION_LINKS: LayoutHeader.NavigationItem[] = [ | ||
{ | ||
href: "/specialties", | ||
translation: "go-to-specialties", | ||
}, | ||
{ | ||
href: "/specialties/simulations", | ||
translation: "go-to-simulations", | ||
}, | ||
]; |
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 |
---|---|---|
@@ -0,0 +1,4 @@ | ||
export type NavigationItem = { | ||
readonly href: string; | ||
readonly translation: string; | ||
}; |
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 |
---|---|---|
@@ -0,0 +1,2 @@ | ||
/** MODELS */ | ||
export * as LayoutHeader from "@/modules/layout/core/domain/models/header.model"; |
18 changes: 16 additions & 2 deletions
18
src/modules/layout/react/components/header/header.component.tsx
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 |
---|---|---|
@@ -0,0 +1,11 @@ | ||
import { usePathname } from "next/navigation"; | ||
|
||
export const useActivePath = (): ((path: string) => boolean) => { | ||
const pathname = usePathname(); | ||
|
||
const checkActivePath = (path: string) => { | ||
return path === pathname; | ||
}; | ||
|
||
return checkActivePath; | ||
}; |
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,7 +1,7 @@ | ||
export const SPECIALTIES_LISTING_MAX_YEAR = 2023; | ||
export const SPECIALTIES_LISTING_MIN_YEAR = 2019; | ||
|
||
export const SPECIALTIES_SIMULATION_MAX_STAGE = 1; | ||
export const SPECIALTIES_SIMULATION_MIN_STAGE = 1; | ||
export const SPECIALTIES_SIMULATION_MAX_STAGE = 3; | ||
|
||
export const SPECIALTIES_YEARS = [2023, 2022, 2021, 2020, 2019]; |