react-day-picker 9.0.4 → 9.0.6
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +1 -1
- package/dist/cjs/DayPicker.js +2 -6
- package/dist/cjs/DayPicker.js.map +1 -1
- package/dist/cjs/package.json +1 -0
- package/dist/cjs/selection/useRange.js +3 -19
- package/dist/cjs/selection/useRange.js.map +1 -1
- package/dist/cjs/utils/addToRange.d.ts +6 -2
- package/dist/cjs/utils/addToRange.js +68 -24
- package/dist/cjs/utils/addToRange.js.map +1 -1
- package/dist/esm/DayPicker.js +2 -6
- package/dist/esm/DayPicker.js.map +1 -1
- package/dist/esm/selection/useRange.js +3 -19
- package/dist/esm/selection/useRange.js.map +1 -1
- package/dist/esm/utils/addToRange.d.ts +6 -2
- package/dist/esm/utils/addToRange.js +68 -24
- package/dist/esm/utils/addToRange.js.map +1 -1
- package/examples/MultipleRequired.tsx +7 -0
- package/examples/RangeMinMax.test.tsx +5 -16
- package/examples/RangeMinMax.tsx +5 -6
- package/examples/RangeRequired.tsx +30 -0
- package/examples/RangeShiftKey.tsx +1 -3
- package/examples/__snapshots__/Range.test.tsx.snap +26 -0
- package/examples/__snapshots__/StylingCssModules.test.tsx.snap +11 -0
- package/examples/index.ts +2 -0
- package/package.json +7 -7
- package/src/DayPicker.tsx +12 -7
- package/src/selection/useRange.test.tsx +2 -2
- package/src/selection/useRange.tsx +3 -25
- package/src/style.css +11 -5
- package/src/style.module.css +12 -6
- package/src/utils/addToRange.test.ts +95 -97
- package/src/utils/addToRange.ts +64 -28
- package/website/docs/docs/accessibility.mdx +1 -1
- package/website/docs/docs/selection-modes.mdx +51 -75
- package/website/docs/guides/custom-components.mdx +16 -88
- package/website/docs/intro.mdx +1 -1
- package/website/docs/upgrading.mdx +4 -9
- package/website/README.md +0 -25
|
@@ -6,12 +6,9 @@ sidebar_position: 5
|
|
|
6
6
|
|
|
7
7
|
This release includes important updates related to accessibility, styles, internationalization and performance. See the [changelog](./changelog.mdx) for the full list of changes.
|
|
8
8
|
|
|
9
|
-
|
|
10
|
-
<summary>**Upgrading from v7**</summary>
|
|
11
|
-
|
|
12
|
-
If you are upgrading from v7, this guide is still valid for you. Read first the [migration guide from v7 to v8](#upgrade-from-v7-to-v8) and then follow the steps below.
|
|
9
|
+
#### Upgrading from v7
|
|
13
10
|
|
|
14
|
-
|
|
11
|
+
If you are upgrading from v7, this guide is still valid for you. Read first the [migration guide from v7 to v8](../versioned_docs/version-8.10.1/upgrading.mdx) and then follow the steps below.
|
|
15
12
|
|
|
16
13
|
## Checklist
|
|
17
14
|
|
|
@@ -21,12 +18,10 @@ If you are upgrading from v7, this guide is still valid for you. Read first the
|
|
|
21
18
|
npm install react-day-picker@latest
|
|
22
19
|
```
|
|
23
20
|
|
|
24
|
-
Remove `date-fns` from your dependencies if you are not using it directly in your code.
|
|
25
|
-
|
|
26
|
-
- Note: You still need `date-fns` if you need to use a [different locale](./docs/localization.mdx).
|
|
21
|
+
Remove `date-fns` from your dependencies if you are not using it directly in your code, like when using a [different locale](./docs/localization.mdx).
|
|
27
22
|
|
|
28
23
|
```bash npm2yarn
|
|
29
|
-
npm
|
|
24
|
+
npm remove date-fns
|
|
30
25
|
```
|
|
31
26
|
|
|
32
27
|
### 2. Update your custom styles
|
package/website/README.md
DELETED
|
@@ -1,25 +0,0 @@
|
|
|
1
|
-
# DayPicker Website
|
|
2
|
-
|
|
3
|
-
The DayPicker website hosted at https://daypicker.dev is built using [Docusaurus](https://docusaurus.io/), a modern static website generator.
|
|
4
|
-
|
|
5
|
-
### Installation
|
|
6
|
-
|
|
7
|
-
```
|
|
8
|
-
$ npm
|
|
9
|
-
```
|
|
10
|
-
|
|
11
|
-
### Local Development
|
|
12
|
-
|
|
13
|
-
```
|
|
14
|
-
$ npm start
|
|
15
|
-
```
|
|
16
|
-
|
|
17
|
-
This command starts a local development server and opens up a browser window. Most changes are reflected live without having to restart the server.
|
|
18
|
-
|
|
19
|
-
### Build
|
|
20
|
-
|
|
21
|
-
```
|
|
22
|
-
$ npm build
|
|
23
|
-
```
|
|
24
|
-
|
|
25
|
-
This command generates static content into the `build` directory and can be served using any static contents hosting service.
|