Skip to content

Commit 111efad

Browse files
j2ghzMethuselah96
andauthored
Fix types compatibility with React 19 (#5974)
* Fix types compatibility with React 19 * Create tough-hats-help.md --------- Co-authored-by: Nathan Bierema <[email protected]>
1 parent 28251dc commit 111efad

15 files changed

+28
-27
lines changed

.changeset/tough-hats-help.md

+5
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,5 @@
1+
---
2+
'react-select': patch
3+
---
4+
5+
Fix types compatibility with React 19

package.json

+1-1
Original file line numberDiff line numberDiff line change
@@ -34,7 +34,7 @@
3434
"@types/jest-in-case": "^1.0.6",
3535
"@types/node": "^16.11.68",
3636
"@types/pretty-proptypes": "^1.1.0",
37-
"@types/react": "^16.14.2",
37+
"@types/react": "^16.14.60",
3838
"@types/react-dom": "^16.9.10",
3939
"@types/react-transition-group": "^4.4.0",
4040
"@typescript-eslint/eslint-plugin": "^4.14.0",

packages/react-select/src/Select.tsx

+1
Original file line numberDiff line numberDiff line change
@@ -4,6 +4,7 @@ import {
44
Component,
55
FocusEventHandler,
66
FormEventHandler,
7+
JSX,
78
KeyboardEventHandler,
89
MouseEventHandler,
910
ReactNode,

packages/react-select/src/components/Control.tsx

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
/** @jsx jsx */
2-
import { ReactNode, Ref } from 'react';
2+
import { JSX, ReactNode, Ref } from 'react';
33
import { jsx } from '@emotion/react';
44

55
import {

packages/react-select/src/components/Group.tsx

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
/** @jsx jsx */
2-
import { ComponentType, ReactNode } from 'react';
2+
import { ComponentType, JSX, ReactNode } from 'react';
33
import { jsx } from '@emotion/react';
44
import { cleanCommonProps, getStyleProps } from '../utils';
55

packages/react-select/src/components/Menu.tsx

+1
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,7 @@
11
/** @jsx jsx */
22
import {
33
createContext,
4+
JSX,
45
ReactElement,
56
ReactNode,
67
Ref,

packages/react-select/src/components/MultiValue.tsx

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
/** @jsx jsx */
2-
import { ComponentType, ReactNode } from 'react';
2+
import { ComponentType, JSX, ReactNode } from 'react';
33
import { jsx } from '@emotion/react';
44
import { CrossIcon } from './indicators';
55
import {

packages/react-select/src/components/Option.tsx

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
/** @jsx jsx */
2-
import { ReactNode, RefCallback } from 'react';
2+
import { JSX, ReactNode, RefCallback } from 'react';
33
import { jsx } from '@emotion/react';
44

55
import {

packages/react-select/src/components/Placeholder.tsx

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
/** @jsx jsx */
2-
import { ReactNode } from 'react';
2+
import { JSX, ReactNode } from 'react';
33
import { jsx } from '@emotion/react';
44
import {
55
CommonPropsAndClassName,

packages/react-select/src/components/SingleValue.tsx

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
/** @jsx jsx */
2-
import { ReactNode } from 'react';
2+
import { JSX, ReactNode } from 'react';
33
import { jsx } from '@emotion/react';
44
import {
55
CommonPropsAndClassName,

packages/react-select/src/components/containers.tsx

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
/** @jsx jsx */
2-
import { ReactNode } from 'react';
2+
import { JSX, ReactNode } from 'react';
33
import { jsx } from '@emotion/react';
44
import {
55
CommonPropsAndClassName,

packages/react-select/src/components/indicators.tsx

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
/** @jsx jsx */
2-
import { ReactNode } from 'react';
2+
import { JSX, ReactNode } from 'react';
33
import { jsx, keyframes } from '@emotion/react';
44

55
import {

packages/react-select/src/internal/A11yText.tsx

+1
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,5 @@
11
/** @jsx jsx */
2+
import { JSX } from 'react';
23
import { jsx } from '@emotion/react';
34

45
// Assistive text to describe visual elements. Hidden for sighted users.

packages/react-select/src/internal/DummyInput.tsx

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
/** @jsx jsx */
2-
import { Ref } from 'react';
2+
import { JSX, Ref } from 'react';
33
import { jsx } from '@emotion/react';
44
import { removeProps } from '../utils';
55

yarn.lock

+10-17
Original file line numberDiff line numberDiff line change
@@ -3709,14 +3709,7 @@
37093709
dependencies:
37103710
"@types/react" "*"
37113711

3712-
"@types/react-dom@*":
3713-
version "18.0.6"
3714-
resolved "https://registry.yarnpkg.com/@types/react-dom/-/react-dom-18.0.6.tgz#36652900024842b74607a17786b6662dd1e103a1"
3715-
integrity sha512-/5OFZgfIPSwy+YuIBP/FgJnQnsxhZhjjrnxudMddeblOouIodEQ75X14Rr4wGSG/bknL+Omy9iWlLo1u/9GzAA==
3716-
dependencies:
3717-
"@types/react" "*"
3718-
3719-
"@types/react-dom@^16.9.10":
3712+
"@types/react-dom@*", "@types/react-dom@^16.9.10":
37203713
version "16.9.13"
37213714
resolved "https://registry.yarnpkg.com/@types/react-dom/-/react-dom-16.9.13.tgz#5898f0ee68fe200685e6b61d3d7d8828692814d0"
37223715
integrity sha512-34Hr3XnmUSJbUVDxIw/e7dhQn2BJZhJmlAaPyPwfTQyuVS9mV/CeyghFcXyvkJXxI7notQJz8mF8FeCVvloJrA==
@@ -3776,13 +3769,13 @@
37763769
dependencies:
37773770
"@types/react" "*"
37783771

3779-
"@types/react@*", "@types/react@^16", "@types/react@^16.14.2":
3780-
version "16.14.8"
3781-
resolved "https://registry.yarnpkg.com/@types/react/-/react-16.14.8.tgz#4aee3ab004cb98451917c9b7ada3c7d7e52db3fe"
3782-
integrity sha512-QN0/Qhmx+l4moe7WJuTxNiTsjBwlBGHqKGvInSQCBdo7Qio0VtOqwsC0Wq7q3PbJlB0cR4Y4CVo1OOe6BOsOmA==
3772+
"@types/react@*", "@types/react@^16", "@types/react@^16.14.60":
3773+
version "16.14.60"
3774+
resolved "https://registry.yarnpkg.com/@types/react/-/react-16.14.60.tgz#f7ab62a329b82826f12d02bc8031d4ef4b5e0d81"
3775+
integrity sha512-wIFmnczGsTcgwCBeIYOuy2mdXEiKZ5znU/jNOnMZPQyCcIxauMGWlX0TNG4lZ7NxRKj7YUIZRneJQSSdB2jKgg==
37833776
dependencies:
37843777
"@types/prop-types" "*"
3785-
"@types/scheduler" "*"
3778+
"@types/scheduler" "^0.16"
37863779
csstype "^3.0.2"
37873780

37883781
"@types/relateurl@*":
@@ -3797,10 +3790,10 @@
37973790
dependencies:
37983791
"@types/node" "*"
37993792

3800-
"@types/scheduler@*":
3801-
version "0.16.1"
3802-
resolved "https://registry.yarnpkg.com/@types/scheduler/-/scheduler-0.16.1.tgz#18845205e86ff0038517aab7a18a62a6b9f71275"
3803-
integrity sha512-EaCxbanVeyxDRTQBkdLb3Bvl/HK7PBK6UJjsSixB0iHKoWxE5uu2Q/DgtpOhPIojN0Zl1whvOd7PoHs2P0s5eA==
3793+
"@types/scheduler@^0.16":
3794+
version "0.16.8"
3795+
resolved "https://registry.yarnpkg.com/@types/scheduler/-/scheduler-0.16.8.tgz#ce5ace04cfeabe7ef87c0091e50752e36707deff"
3796+
integrity sha512-WZLiwShhwLRmeV6zH+GkbOFT6Z6VklCItrDioxUnv+u4Ll+8vKeFySoFyK/0ctcRpOmwAicELfmys1sDc/Rw+A==
38043797

38053798
"@types/semver@^6.0.0", "@types/semver@^6.0.1":
38063799
version "6.2.3"

0 commit comments

Comments
 (0)