Skip to content

Commit

Permalink
[pickers] Add reference links to calendar components (#10644)
Browse files Browse the repository at this point in the history
Signed-off-by: Michel Engelen <[email protected]>
Co-authored-by: Lukas <[email protected]>
  • Loading branch information
michelengelen and LukasTy authored Nov 1, 2023
1 parent 35ac35c commit f1ef162
Show file tree
Hide file tree
Showing 7 changed files with 34 additions and 5 deletions.
2 changes: 1 addition & 1 deletion docs/data/date-pickers/date-picker/date-picker.md
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
---
productId: x-date-pickers
title: React Date Picker component
components: DatePicker, DesktopDatePicker, MobileDatePicker, StaticDatePicker
components: DatePicker, DesktopDatePicker, MobileDatePicker, StaticDatePicker, DateCalendar
githubLabel: 'component: DatePicker'
packageName: '@mui/x-date-pickers'
materialDesign: https://m2.material.io/components/date-pickers
Expand Down
2 changes: 1 addition & 1 deletion docs/data/date-pickers/validation/validation.md
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
---
productId: x-date-pickers
components: DatePicker, DesktopDatePicker, MobileDatePicker, StaticDatePicker, TimePicker, DesktopTimePicker, MobileTimePicker, StaticTimePicker, DateTimePicker, DesktopDateTimePicker, MobileDateTimePicker, StaticDateTimePicker, DateRangePicker, DesktopDateRangePicker, MobileDateRangePicker, StaticDateRangePicker
components: DatePicker, DesktopDatePicker, MobileDatePicker, StaticDatePicker, TimePicker, DesktopTimePicker, MobileTimePicker, StaticTimePicker, DateTimePicker, DesktopDateTimePicker, MobileDateTimePicker, StaticDateTimePicker, DateRangePicker, DesktopDateRangePicker, MobileDateRangePicker, StaticDateRangePicker, DateCalendar
githubLabel: 'component: pickers'
packageName: '@mui/x-date-pickers'
---
Expand Down
2 changes: 1 addition & 1 deletion docs/pages/x/api/date-pickers/date-calendar.json
Original file line number Diff line number Diff line change
Expand Up @@ -214,5 +214,5 @@
"forwardsRefTo": "HTMLDivElement",
"filename": "/packages/x-date-pickers/src/DateCalendar/DateCalendar.tsx",
"inheritance": null,
"demos": "<ul><li><a href=\"/x/react-date-pickers/date-calendar/\">Date Calendar</a></li></ul>"
"demos": "<ul><li><a href=\"/x/react-date-pickers/date-calendar/\">Date Calendar</a></li>\n<li><a href=\"/x/react-date-pickers/date-picker/\">Date Picker</a></li>\n<li><a href=\"/x/react-date-pickers/validation/\">Validation</a></li></ul>"
}
Original file line number Diff line number Diff line change
Expand Up @@ -155,6 +155,16 @@ type DateRangeCalendarComponent = (<TDate>(
props: DateRangeCalendarProps<TDate> & React.RefAttributes<HTMLDivElement>,
) => React.JSX.Element) & { propTypes?: any };

/**
* Demos:
*
* - [DateRangePicker](https://mui.com/x/react-date-pickers/date-range-picker/)
* - [DateRangeCalendar](https://mui.com/x/react-date-pickers/date-range-calendar/)
*
* API:
*
* - [DateRangeCalendar API](https://mui.com/x/api/date-pickers/date-range-calendar/)
*/
const DateRangeCalendar = React.forwardRef(function DateRangeCalendar<TDate>(
inProps: DateRangeCalendarProps<TDate>,
ref: React.Ref<HTMLDivElement>,
Expand Down
5 changes: 3 additions & 2 deletions packages/x-date-pickers/src/DateCalendar/DateCalendar.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -88,10 +88,11 @@ type DateCalendarComponent = (<TDate>(
) => React.JSX.Element) & { propTypes?: any };

/**
*
* Demos:
*
* - [Date Picker](https://mui.com/x/react-date-pickers/date-picker/)
* - [DatePicker](https://mui.com/x/react-date-pickers/date-picker/)
* - [DateCalendar](https://mui.com/x/react-date-pickers/date-calendar/)
* - [Validation](https://mui.com/x/react-date-pickers/validation/)
*
* API:
*
Expand Down
9 changes: 9 additions & 0 deletions packages/x-date-pickers/src/MonthCalendar/MonthCalendar.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -70,6 +70,15 @@ type MonthCalendarComponent = (<TDate>(
props: MonthCalendarProps<TDate> & React.RefAttributes<HTMLDivElement>,
) => React.JSX.Element) & { propTypes?: any };

/**
* Demos:
*
* - [DateCalendar](https://mui.com/x/react-date-pickers/date-calendar/)
*
* API:
*
* - [MonthCalendar API](https://mui.com/x/api/date-pickers/month-calendar/)
*/
export const MonthCalendar = React.forwardRef(function MonthCalendar<TDate>(
inProps: MonthCalendarProps<TDate>,
ref: React.Ref<HTMLDivElement>,
Expand Down
9 changes: 9 additions & 0 deletions packages/x-date-pickers/src/YearCalendar/YearCalendar.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -76,6 +76,15 @@ type YearCalendarComponent = (<TDate>(props: YearCalendarProps<TDate>) => React.
propTypes?: any;
};

/**
* Demos:
*
* - [DateCalendar](https://mui.com/x/react-date-pickers/date-calendar/)
*
* API:
*
* - [YearCalendar API](https://mui.com/x/api/date-pickers/year-calendar/)
*/
export const YearCalendar = React.forwardRef(function YearCalendar<TDate>(
inProps: YearCalendarProps<TDate>,
ref: React.Ref<HTMLDivElement>,
Expand Down

0 comments on commit f1ef162

Please sign in to comment.