mirror of
https://git.mirrors.martin98.com/https://github.com/SigNoz/signoz
synced 2025-08-12 20:38:59 +08:00
fix: global time navigation is fixed (#2533)
This commit is contained in:
parent
61a1d04252
commit
20b1f96c19
@ -29,7 +29,6 @@ function SideNav(): JSX.Element {
|
|||||||
const [collapsed, setCollapsed] = useState<boolean>(
|
const [collapsed, setCollapsed] = useState<boolean>(
|
||||||
getLocalStorageKey(IS_SIDEBAR_COLLAPSED) === 'true',
|
getLocalStorageKey(IS_SIDEBAR_COLLAPSED) === 'true',
|
||||||
);
|
);
|
||||||
const { search } = useLocation();
|
|
||||||
const { currentVersion, latestVersion, isCurrentVersionError } = useSelector<
|
const { currentVersion, latestVersion, isCurrentVersionError } = useSelector<
|
||||||
AppState,
|
AppState,
|
||||||
AppReducer
|
AppReducer
|
||||||
@ -48,15 +47,11 @@ function SideNav(): JSX.Element {
|
|||||||
|
|
||||||
const onClickHandler = useCallback(
|
const onClickHandler = useCallback(
|
||||||
(to: string) => {
|
(to: string) => {
|
||||||
const queryParams = new URLSearchParams(search);
|
|
||||||
|
|
||||||
const url = queryParams.toString();
|
|
||||||
|
|
||||||
if (pathname !== to) {
|
if (pathname !== to) {
|
||||||
history.push(`${to}?${url}`);
|
history.push(`${to}`);
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
[pathname, search],
|
[pathname],
|
||||||
);
|
);
|
||||||
|
|
||||||
const onClickSlackHandler = (): void => {
|
const onClickSlackHandler = (): void => {
|
||||||
|
Loading…
x
Reference in New Issue
Block a user