Is not required anymore since "Link" of react-router-dom is a "<a>" element now anyway. It also caused the following warning "react-dom.development.js:86 Warning: React does not recognize the `directLink` prop on a DOM element. If you intentionally want it to appear in the DOM as a custom attribute, spell it as lowercase `directlink` instead. If you accidentally passed it from a parent component, remove it from the DOM element"
15 lines
512 B
TypeScript
15 lines
512 B
TypeScript
/*
|
|
* Copyright (C) Contributors to the Suwayomi project
|
|
*
|
|
* This Source Code Form is subject to the terms of the Mozilla Public
|
|
* License, v. 2.0. If a copy of the MPL was not distributed with this
|
|
* file, You can obtain one at https://mozilla.org/MPL/2.0/.
|
|
*/
|
|
|
|
import { Link } from 'react-router-dom';
|
|
import { ListItemButton, ListItemButtonProps } from '@mui/material';
|
|
|
|
export function ListItemLink(props: ListItemButtonProps<typeof Link>) {
|
|
return <ListItemButton component={Link} {...props} />;
|
|
}
|