This repository has been archived by the owner on Dec 13, 2022. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 240
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
enh(Resources/header): Display the 2 access pictograms logs and repor…
…t on details panel (#11478) * Display the 2 access pictograms logs and report on details panel * Update www/front_src/src/Resources/Details/Header.tsx Co-authored-by: Tom Darneix <tomdar87@outlook.com> * Update www/front_src/src/Resources/Details/Header.tsx Co-authored-by: Tom Darneix <tomdar87@outlook.com> * fixes * fix test * fix eslint * update style * update style * add test * use divider insead of border css * Update www/front_src/src/Resources/Details/Header.tsx Co-authored-by: Tom Darneix <tomdar87@outlook.com> * Update www/front_src/src/Resources/Details/index.test.tsx Co-authored-by: Bruno d'Auria <bdauria@centreon.com> Co-authored-by: Tom Darneix <tomdar87@outlook.com> Co-authored-by: Bruno d'Auria <bdauria@centreon.com>
- Loading branch information
1 parent
d15ee12
commit d30f5cc
Showing
4 changed files
with
101 additions
and
127 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 was deleted.
Oops, something went wrong.
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,16 @@ | ||
interface ReplaceBasename { | ||
endpoint: string; | ||
newWord: string; | ||
} | ||
|
||
export const replaceBasename = ({ | ||
newWord, | ||
endpoint, | ||
}: ReplaceBasename): string => { | ||
const basename = | ||
(document | ||
.getElementsByTagName('base')[0] | ||
?.getAttribute('href') as string) || ''; | ||
|
||
return endpoint.replace(basename, newWord); | ||
}; |