Skip to content

Commit 1870d0a

Browse files
committed
Fixed ItemAction type for next router
1 parent cdc6ad3 commit 1870d0a

2 files changed

Lines changed: 3 additions & 3 deletions

File tree

packages/lib/src/base-menu/ItemAction.tsx

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@ import DxcIcon from "../icon/Icon";
55
import { TooltipWrapper } from "../tooltip/Tooltip";
66
import { useItemAction } from "./useItemAction";
77

8-
const Action = styled.button<{
8+
const Action = styled.a<{
99
depthLevel: ItemActionProps["depthLevel"];
1010
selected: ItemActionProps["selected"];
1111
displayGroupLines: boolean;
@@ -79,7 +79,7 @@ const Control = styled.span`
7979
`;
8080

8181
const ItemAction = memo(
82-
forwardRef<HTMLButtonElement, ItemActionProps>((props, ref) => {
82+
forwardRef<HTMLAnchorElement, ItemActionProps>((props, ref) => {
8383
const {
8484
hasTooltip,
8585
modifiedBadge,

packages/lib/src/base-menu/types.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -61,7 +61,7 @@ type MenuItemProps = {
6161
item: ItemWithId | GroupItemWithId;
6262
depthLevel?: number;
6363
};
64-
type ItemActionProps = ButtonHTMLAttributes<HTMLButtonElement> & {
64+
type ItemActionProps = ButtonHTMLAttributes<HTMLAnchorElement> & {
6565
badge?: Item["badge"];
6666
collapseIcon?: ReactNode;
6767
depthLevel: number;

0 commit comments

Comments
 (0)