diff --git a/docs/src/modules/components/overview/CommunityOrPro.tsx b/docs/src/modules/components/overview/CommunityOrPro.tsx
index 7e6dcbf3de21..3e6dc197bf71 100644
--- a/docs/src/modules/components/overview/CommunityOrPro.tsx
+++ b/docs/src/modules/components/overview/CommunityOrPro.tsx
@@ -40,7 +40,7 @@ export default function CommunityOrPro() {
}
sx={{ width: 'fit-content' }}
>
@@ -60,7 +60,7 @@ export default function CommunityOrPro() {
'Free forever under an MIT license. Includes Date Pickers, Time Pickers, and Date Time Pickers.',
]}
backgroundColor="subtle"
- link="/pricing"
+ link="https://mui.com/pricing/"
/>
@@ -71,7 +71,7 @@ export default function CommunityOrPro() {
'Requires a commercial license. Includes all Community components plus the Date and Time Range Pickers.',
]}
backgroundColor="subtle"
- link="/pricing"
+ link="https://mui.com/pricing/"
/>
diff --git a/docs/src/modules/components/overview/InfoCard.tsx b/docs/src/modules/components/overview/InfoCard.tsx
index aaaebb419a61..c13bbfec8cd4 100644
--- a/docs/src/modules/components/overview/InfoCard.tsx
+++ b/docs/src/modules/components/overview/InfoCard.tsx
@@ -6,23 +6,24 @@ import Stack from '@mui/material/Stack';
import Paper from '@mui/material/Paper';
type InfoCardProps = {
- title: string;
- description?: string | string[];
- icon?: React.ReactNode;
- onClick?: () => void;
active?: boolean;
backgroundColor?: 'gradient' | 'subtle';
+ description?: string | string[];
+ icon?: React.ReactNode;
link?: string;
+ onClick?: () => void;
+ title: string;
};
-export default function InfoCard({
- title,
- description,
- icon: Icon,
- onClick,
- active,
- backgroundColor = 'gradient',
- link,
-}: InfoCardProps) {
+export default function InfoCard(props: InfoCardProps) {
+ const {
+ active,
+ backgroundColor = 'gradient',
+ description,
+ icon: Icon,
+ link,
+ onClick,
+ title,
+ } = props;
const clickable = Boolean(onClick);
return (
@@ -78,7 +79,11 @@ export default function InfoCard({
}),
})}
>
-
+
{Icon}
-
+
}
- link="/x/react-date-pickers/localization"
+ link="/x/react-date-pickers/localization/"
>
-
+
{
+ onMouseDown={(event) => {
if (shouldSelect) {
- e.preventDefault();
+ event.preventDefault();
- handleKeySelection(e, {
+ handleKeySelection(event, {
key: label,
location: location || 0,
code: code || label,
@@ -328,9 +328,9 @@ export function KeyboardSvg({ selectedKey, handleKeySelection }: KeyboardSvgProp
});
}
}}
- onMouseUp={(e) => {
+ onMouseUp={(event) => {
if (shouldSelect) {
- handleKeySelection(e, null);
+ handleKeySelection(event, null);
}
}}
>
@@ -370,12 +370,12 @@ export function KeyboardSvg({ selectedKey, handleKeySelection }: KeyboardSvgProp
className={clsx(key, 'key-root', {
selected: selectedKey && selectedKey.key.toLowerCase() === key.toLowerCase(),
})}
- onMouseDown={(e) => {
- e.preventDefault();
- handleKeySelection(e, { key, location, code, keyCode });
+ onMouseDown={(event) => {
+ event.preventDefault();
+ handleKeySelection(event, { key, location, code, keyCode });
}}
- onMouseUp={(e) => {
- handleKeySelection(e, null);
+ onMouseUp={(event) => {
+ handleKeySelection(event, null);
}}
>
void;
+type HandleKeySelection = (event: React.SyntheticEvent, key: SelectedKey | null) => void;
export default function Keyboard() {
const [selectedKey, setSelectedKey] = React.useState(null);
@@ -463,10 +463,9 @@ export default function Keyboard() {
}
description="The MUI X Date Pickers feature advanced keyboard support that's compliant with WCAG and WAI-ARIA standards, so users who require assistive technology can navigate your interface with ease."
/>
-
}
sx={{ width: 'fit-content' }}
>
@@ -478,11 +477,11 @@ export default function Keyboard() {
{
+ onKeyDown={(event: React.KeyboardEvent) => {
setSelectedKey({
- key: e.key,
- code: e.code,
- location: e.location,
+ key: event.key,
+ code: event.code,
+ location: event.location,
});
}}
onKeyUp={() => {