forked from Hacker0x01/react-datepicker
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Publish new API docs (automated commit)
- Loading branch information
1 parent
abea7ea
commit 2f4cdfb
Showing
14 changed files
with
283 additions
and
296 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,8 +1,7 @@ | ||
# `calendar_container` (component) | ||
|
||
| name | type | default value | description | | ||
| -------------------- | -------- | ------------- | ----------- | | ||
| `children` | `node` | | | | ||
| `className` | `string` | | | | ||
| `showTime` | `bool` | `false` | | | ||
| `showTimeSelectOnly` | `bool` | `false` | | | ||
| name | type | default value | description | | ||
| -------------------- | ---- | ------------- | ----------- | | ||
| `className` | | | | | ||
| `showTime` | | `false` | | | ||
| `showTimeSelectOnly` | | `false` | | |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,7 +1,25 @@ | ||
# `calendar_icon` (component) | ||
|
||
| name | type | default value | description | | ||
| ----------- | --------------------- | ------------- | ----------- | | ||
| `className` | `string` | `""` | | | ||
| `icon` | `union(string\|node)` | | | | ||
| `onClick` | `func` | | | | ||
`CalendarIcon` is a React component that renders an icon for a calendar. | ||
The icon can be a string representing a CSS class, a React node, or a default SVG icon. | ||
|
||
@component | ||
@prop icon - The icon to be displayed. This can be a string representing a CSS class or a React node. | ||
@prop className - An optional string representing additional CSS classes to be applied to the icon. | ||
@prop onClick - An optional function to be called when the icon is clicked. | ||
|
||
@example | ||
// To use a CSS class as the icon | ||
<CalendarIcon icon="my-icon-class" onClick={myClickHandler} /> | ||
|
||
@example | ||
// To use a React node as the icon | ||
<CalendarIcon icon={<MyIconComponent />} onClick={myClickHandler} /> | ||
|
||
@returns The `CalendarIcon` component. | ||
|
||
| name | type | default value | description | | ||
| ----------- | ---- | ------------- | ----------- | | ||
| `className` | | `""` | | | ||
| `icon` | | | | | ||
| `onClick` | | | | |
Large diffs are not rendered by default.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,24 @@ | ||
# `input_time` (component) | ||
|
||
`InputTime` is a React component that manages time input. | ||
|
||
@component | ||
@example | ||
<InputTime timeString="12:00" /> | ||
|
||
@param props - The properties that define the `InputTime` component. | ||
@param props.onChange - Function that is called when the date changes. | ||
@param props.date - The initial date value. | ||
@param props.timeString - The initial time string value. | ||
@param props.timeInputLabel - The label for the time input. | ||
@param props.customTimeInput - An optional custom time input element. | ||
|
||
@returns The `InputTime` component. | ||
|
||
| name | type | default value | description | | ||
| ----------------- | ---- | ------------- | ----------- | | ||
| `customTimeInput` | | | | | ||
| `date` | | | | | ||
| `onChange` | | | | | ||
| `timeInputLabel` | | | | | ||
| `timeString` | | | | |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,11 +1,8 @@ | ||
`month_dropdown` (component) | ||
============================ | ||
# `month_dropdown` (component) | ||
|
||
|
||
| name | type | default value | description | | ||
|---|---|---|---| | ||
|`dropdownMode` (required)|`enum("scroll"\|"select")`||| | ||
|`locale`|`string`||| | ||
|`month` (required)|`number`||| | ||
|`onChange` (required)|`func`||| | ||
|`useShortMonthInDropdown`|`bool`||| | ||
| name | type | default value | description | | ||
| ------------------------- | ---- | ------------- | ----------- | | ||
| `dropdownMode` (required) | | | | | ||
| `locale` | | | | | ||
| `onChange` (required) | | | | | ||
| `useShortMonthInDropdown` | | | | |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,10 +1,8 @@ | ||
`month_dropdown_options` (component) | ||
==================================== | ||
# `month_dropdown_options` (component) | ||
|
||
|
||
| name | type | default value | description | | ||
|---|---|---|---| | ||
|`month` (required)|`number`||| | ||
|`monthNames` (required)|`arrayOf[object Object]`||| | ||
|`onCancel` (required)|`func`||| | ||
|`onChange` (required)|`func`||| | ||
| name | type | default value | description | | ||
| ----------------------- | ---- | ------------- | ----------- | | ||
| `month` (required) | | | | | ||
| `monthNames` (required) | | | | | ||
| `onCancel` (required) | | | | | ||
| `onChange` (required) | | | | |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,14 +1,7 @@ | ||
`month_year_dropdown` (component) | ||
================================= | ||
# `month_year_dropdown` (component) | ||
|
||
|
||
| name | type | default value | description | | ||
|---|---|---|---| | ||
|`date` (required)|`instanceOfDate`||| | ||
|`dateFormat` (required)|`string`||| | ||
|`dropdownMode` (required)|`enum("scroll"\|"select")`||| | ||
|`locale`|`string`||| | ||
|`maxDate` (required)|`instanceOfDate`||| | ||
|`minDate` (required)|`instanceOfDate`||| | ||
|`onChange` (required)|`func`||| | ||
|`scrollableMonthYearDropdown`|`bool`||| | ||
| name | type | default value | description | | ||
| ------------------------- | ---- | ------------- | ----------- | | ||
| `dropdownMode` (required) | | | | | ||
| `locale` | | | | | ||
| `onChange` (required) | | | | |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,14 +1,12 @@ | ||
`month_year_dropdown_options` (component) | ||
========================================= | ||
# `month_year_dropdown_options` (component) | ||
|
||
|
||
| name | type | default value | description | | ||
|---|---|---|---| | ||
|`date` (required)|`instanceOfDate`||| | ||
|`dateFormat` (required)|`string`||| | ||
|`locale`|`string`||| | ||
|`maxDate` (required)|`instanceOfDate`||| | ||
|`minDate` (required)|`instanceOfDate`||| | ||
|`onCancel` (required)|`func`||| | ||
|`onChange` (required)|`func`||| | ||
|`scrollableMonthYearDropdown`|`bool`||| | ||
| name | type | default value | description | | ||
| ----------------------------- | ---- | ------------- | ----------- | | ||
| `date` (required) | | | | | ||
| `dateFormat` (required) | | | | | ||
| `locale` | | | | | ||
| `maxDate` (required) | | | | | ||
| `minDate` (required) | | | | | ||
| `onCancel` (required) | | | | | ||
| `onChange` (required) | | | | | ||
| `scrollableMonthYearDropdown` | | | | |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,7 +1,16 @@ | ||
# `portal` (component) | ||
|
||
| name | type | default value | description | | ||
| ------------ | ---------------------- | ------------- | ----------- | | ||
| `children` | `any` | | | | ||
| `portalHost` | `instanceOfShadowRoot` | | | | ||
| `portalId` | `string` | | | | ||
`Portal` is a React component that allows you to render children into a DOM node | ||
that exists outside the DOM hierarchy of the parent component. | ||
|
||
@class | ||
@param {PortalProps} props - The properties that define the `Portal` component. | ||
@property {React.ReactNode} props.children - The children to be rendered into the `Portal`. | ||
@property {string} props.portalId - The id of the DOM node into which the `Portal` will render. | ||
@property {ShadowRoot} [props.portalHost] - The DOM node to host the `Portal`. | ||
|
||
| name | type | default value | description | | ||
| --------------------- | ---- | ------------- | ----------- | | ||
| `children` (required) | | | | | ||
| `portalHost` | | | | | ||
| `portalId` (required) | | | | |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,8 +1,23 @@ | ||
`tab_loop` (component) | ||
====================== | ||
# `tab_loop` (component) | ||
|
||
`TabLoop` is a React component that manages tabbing behavior for its children. | ||
|
||
| name | type | default value | description | | ||
|---|---|---|---| | ||
|`children`|`any`||| | ||
|`enableTabLoop`|`bool`|`true`|| | ||
TabLoop prevents the user from tabbing outside of the popper | ||
It creates a tabindex loop so that "Tab" on the last element will focus the first element | ||
and "Shift Tab" on the first element will focus the last element | ||
|
||
@component | ||
@example | ||
<TabLoop enableTabLoop={true}> | ||
<ChildComponent /> | ||
</TabLoop> | ||
|
||
@param props - The properties that define the `TabLoop` component. | ||
@param props.children - The child components. | ||
@param props.enableTabLoop - Whether to enable the tab loop. | ||
|
||
@returns The `TabLoop` component. | ||
|
||
| name | type | default value | description | | ||
| --------------- | ---- | ------------- | ----------- | | ||
| `enableTabLoop` | | `true` | | |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,23 +1,17 @@ | ||
# `time` (component) | ||
|
||
| name | type | default value | description | | ||
| -------------------- | ---------------------- | ------------- | ----------- | | ||
| `excludeTimes` | `array` | | | | ||
| `filterTime` | `func` | | | | ||
| `format` | `string` | | | | ||
| `handleOnKeyDown` | `func` | | | | ||
| `includeTimes` | `array` | | | | ||
| `injectTimes` | `array` | | | | ||
| `intervals` | `number` | `30` | | | ||
| `locale` | `union(string\|shape)` | | | | ||
| `maxTime` | `instanceOfDate` | | | | ||
| `minTime` | `instanceOfDate` | | | | ||
| `monthRef` | `object` | | | | ||
| `onChange` | `func` | | | | ||
| `onTimeChange` | | `() => {}` | | | ||
| `openToDate` | `instanceOfDate` | | | | ||
| `selected` | `instanceOfDate` | | | | ||
| `showTimeSelectOnly` | `bool` | | | | ||
| `timeCaption` | `string` | `"Time"` | | | ||
| `timeClassName` | `func` | | | | ||
| `todayButton` | `node` | `null` | | | ||
| name | type | default value | description | | ||
| -------------------- | ---- | ------------- | ----------- | | ||
| `format` | | | | | ||
| `handleOnKeyDown` | | | | | ||
| `injectTimes` | | | | | ||
| `intervals` | | `30` | | | ||
| `locale` | | | | | ||
| `monthRef` | | | | | ||
| `onChange` | | | | | ||
| `openToDate` | | | | | ||
| `selected` | | | | | ||
| `showTimeSelectOnly` | | | | | ||
| `timeCaption` | | `"Time"` | | | ||
| `timeClassName` | | | | | ||
| `todayButton` | | `null` | | |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,17 +1,18 @@ | ||
# `week_number` (component) | ||
|
||
| name | type | default value | description | | ||
| ---------------------------- | -------------------- | ------------- | ----------- | | ||
| `ariaLabelPrefix` | `string` | `"week "` | | | ||
| `containerRef` | `union(func\|shape)` | | | | ||
| `date` (required) | `instanceOfDate` | | | | ||
| `disabledKeyboardNavigation` | `bool` | | | | ||
| `handleOnKeyDown` | `func` | | | | ||
| `inline` | `bool` | | | | ||
| `onClick` | `func` | | | | ||
| `preSelection` | `instanceOfDate` | | | | ||
| `selected` | `instanceOfDate` | | | | ||
| `shouldFocusDayInline` | `bool` | | | | ||
| `showWeekNumber` | `bool` | | | | ||
| `showWeekPicker` | `bool` | | | | ||
| `weekNumber` (required) | `number` | | | | ||
| name | type | default value | description | | ||
| ---------------------------- | ---- | ------------- | ----------- | | ||
| `ariaLabelPrefix` | | `"week "` | | | ||
| `containerRef` | | | | | ||
| `date` (required) | | | | | ||
| `disabledKeyboardNavigation` | | | | | ||
| `handleOnKeyDown` | | | | | ||
| `inline` | | | | | ||
| `isInputFocused` | | | | | ||
| `onClick` | | | | | ||
| `preSelection` | | | | | ||
| `selected` | | | | | ||
| `shouldFocusDayInline` | | | | | ||
| `showWeekNumber` | | | | | ||
| `showWeekPicker` | | | | | ||
| `weekNumber` (required) | | | | |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,30 +1,44 @@ | ||
# `year` (component) | ||
|
||
| name | type | default value | description | | ||
| ----------------------------- | ------------------------ | ------------- | ----------- | | ||
| `clearSelectingDate` | `func` | | | | ||
| `date` | `instanceOfDate` | | | | ||
| `disabledKeyboardNavigation` | `bool` | | | | ||
| `endDate` | `instanceOfDate` | | | | ||
| `excludeDates` | `arrayOf[object Object]` | | | | ||
| `filterDate` | `func` | | | | ||
| `handleOnKeyDown` | `func` | | | | ||
| `includeDates` | `array` | | | | ||
| `inline` | `bool` | | | | ||
| `maxDate` | `instanceOfDate` | | | | ||
| `minDate` | `instanceOfDate` | | | | ||
| `onDayClick` | `func` | | | | ||
| `onYearMouseEnter` (required) | `func` | | | | ||
| `onYearMouseLeave` (required) | `func` | | | | ||
| `preSelection` | `instanceOfDate` | | | | ||
| `renderYearContent` | `func` | | | | ||
| `selected` | `object` | | | | ||
| `selectingDate` | `instanceOfDate` | | | | ||
| `selectsEnd` | `bool` | | | | ||
| `selectsRange` | `bool` | | | | ||
| `selectsStart` | `bool` | | | | ||
| `setPreSelection` | `func` | | | | ||
| `startDate` | `instanceOfDate` | | | | ||
| `usePointerEvent` | `bool` | | | | ||
| `yearClassName` | `func` | | | | ||
| `yearItemNumber` | `number` | | | | ||
`Year` is a component that represents a year in a date picker. | ||
|
||
@class | ||
@param {YearProps} props - The properties that define the `Year` component. | ||
@property {VoidFunction} [props.clearSelectingDate] - Function to clear the selected date. | ||
@property {Date} [props.date] - The currently selected date. | ||
@property {boolean} [props.disabledKeyboardNavigation] - If true, keyboard navigation is disabled. | ||
@property {Date} [props.endDate] - The end date in a range selection. | ||
@property {(date: Date) => void} props.onDayClick - Function to handle day click events. | ||
@property {Date} props.preSelection - The date that is currently in focus. | ||
@property {(date: Date) => void} props.setPreSelection - Function to set the pre-selected date. | ||
@property {{ [key: string]: any }} props.selected - The selected date(s). | ||
@property {boolean} props.inline - If true, the date picker is displayed inline. | ||
@property {Date} props.maxDate - The maximum selectable date. | ||
@property {Date} props.minDate - The minimum selectable date. | ||
@property {boolean} props.usePointerEvent - If true, pointer events are used instead of mouse events. | ||
@property {(date: Date) => void} props.onYearMouseEnter - Function to handle mouse enter events on a year. | ||
@property {(date: Date) => void} props.onYearMouseLeave - Function to handle mouse leave events on a year. | ||
|
||
| name | type | default value | description | | ||
| ----------------------------- | ---- | ------------- | ----------- | | ||
| `clearSelectingDate` | | | | | ||
| `date` | | | | | ||
| `disabledKeyboardNavigation` | | | | | ||
| `endDate` | | | | | ||
| `handleOnKeyDown` | | | | | ||
| `inline` | | | | | ||
| `onDayClick` | | | | | ||
| `onYearMouseEnter` (required) | | | | | ||
| `onYearMouseLeave` (required) | | | | | ||
| `preSelection` | | | | | ||
| `renderYearContent` | | | | | ||
| `selected` | | | | | ||
| `selectingDate` | | | | | ||
| `selectsEnd` | | | | | ||
| `selectsRange` | | | | | ||
| `selectsStart` | | | | | ||
| `setPreSelection` | | | | | ||
| `startDate` | | | | | ||
| `usePointerEvent` | | | | | ||
| `yearClassName` | | | | | ||
| `yearItemNumber` | | | | |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters