mirror of
https://github.com/scm-manager/scm-manager.git
synced 2025-11-09 23:15:43 +01:00
fixed missing default value for activeOnlyWhenExact on NavLink
This commit is contained in:
@@ -26,8 +26,7 @@ import classNames from "classnames";
|
||||
import { Link, useRouteMatch } from "react-router-dom";
|
||||
import { RoutingProps } from "./RoutingProps";
|
||||
import { FC } from "react";
|
||||
import { useContext } from "react";
|
||||
import useMenuContext, { MenuContext } from "./MenuContext";
|
||||
import useMenuContext from "./MenuContext";
|
||||
|
||||
type Props = RoutingProps & {
|
||||
label: string;
|
||||
@@ -63,4 +62,8 @@ const NavLink: FC<Props> = ({ to, activeOnlyWhenExact, icon, label, title }) =>
|
||||
);
|
||||
};
|
||||
|
||||
NavLink.defaultProps = {
|
||||
activeOnlyWhenExact: true
|
||||
};
|
||||
|
||||
export default NavLink;
|
||||
|
||||
Reference in New Issue
Block a user