Skip to content

Commit a7b1a28

Browse files
authored
chore: Update react types (#8461)
* chore: update react types * Show useContextProps type issue * remove dead file
1 parent 07bc3b4 commit a7b1a28

File tree

3 files changed

+17
-17
lines changed

3 files changed

+17
-17
lines changed

package.json

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -129,8 +129,8 @@
129129
"@testing-library/jest-dom": "^5.16.5",
130130
"@testing-library/react": "^16.0.0",
131131
"@testing-library/user-event": "patch:@testing-library/user-event@npm%3A14.6.1#~/.yarn/patches/@testing-library-user-event-npm-14.6.1-5da7e1d4e2.patch",
132-
"@types/react": "npm:types-react@19.0.0-rc.0",
133-
"@types/react-dom": "npm:types-react-dom@19.0.0-rc.0",
132+
"@types/react": "^19.0.0",
133+
"@types/react-dom": "^19.0.0",
134134
"@yarnpkg/types": "^4.0.0",
135135
"autoprefixer": "^9.6.0",
136136
"axe-core": "^4.6.3",
@@ -231,8 +231,8 @@
231231
"react-refresh": "0.9.0",
232232
"browserslist": "4.24.0",
233233
"caniuse-lite": "1.0.30001563",
234-
"@types/react": "npm:types-react@19.0.0-rc.0",
235-
"@types/react-dom": "npm:types-react-dom@19.0.0-rc.0",
234+
"@types/react": "19.1.8",
235+
"@types/react-dom": "19.1.6",
236236
"recast": "0.23.6",
237237
"ast-types": "0.16.1",
238238
"svgo": "^3",

packages/react-aria-components/src/utils.tsx

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -185,7 +185,7 @@ export function useSlottedContext<T>(context: Context<SlottedContextValue<T>>, s
185185
return ctx;
186186
}
187187

188-
export function useContextProps<T, U extends SlotProps, E extends Element>(props: T & SlotProps, ref: ForwardedRef<E>, context: Context<ContextValue<U, E>>): [T, RefObject<E | null>] {
188+
export function useContextProps<T, U extends SlotProps, E extends Element>(props: T & SlotProps, ref: ForwardedRef<E> | undefined, context: Context<ContextValue<U, E>>): [T, RefObject<E | null>] {
189189
let ctx = useSlottedContext(context, props.slot) || {};
190190
// @ts-ignore - TS says "Type 'unique symbol' cannot be used as an index type." but not sure why.
191191
let {ref: contextRef, ...contextProps} = ctx as any;

yarn.lock

Lines changed: 12 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -10588,21 +10588,21 @@ __metadata:
1058810588
languageName: node
1058910589
linkType: hard
1059010590

10591-
"@types/react-dom@npm:types-react-dom@19.0.0-rc.0":
10592-
version: 19.0.0-rc.0
10593-
resolution: "types-react-dom@npm:19.0.0-rc.0"
10594-
dependencies:
10595-
"@types/react": "npm:*"
10596-
checksum: 10c0/a05f48aec358142f167f4765ed25e4a8185926fe24421c6f0e9af7bbd3029055e01198a300543621c7dd0c045ac84a536e71a74b3ad6d5d95300e4584ab8a0aa
10591+
"@types/react-dom@npm:19.1.6":
10592+
version: 19.1.6
10593+
resolution: "@types/react-dom@npm:19.1.6"
10594+
peerDependencies:
10595+
"@types/react": ^19.0.0
10596+
checksum: 10c0/7ba74eee2919e3f225e898b65fdaa16e54952aaf9e3472a080ddc82ca54585e46e60b3c52018d21d4b7053f09d27b8293e9f468b85f9932ff452cd290cc131e8
1059710597
languageName: node
1059810598
linkType: hard
1059910599

10600-
"@types/react@npm:types-react@19.0.0-rc.0":
10601-
version: 19.0.0-rc.0
10602-
resolution: "types-react@npm:19.0.0-rc.0"
10600+
"@types/react@npm:19.1.8":
10601+
version: 19.1.8
10602+
resolution: "@types/react@npm:19.1.8"
1060310603
dependencies:
1060410604
csstype: "npm:^3.0.2"
10605-
checksum: 10c0/b8c035f3f6354b2b1e24473ec2fb981afab9db726177755cdc6a610f607e8d89ca2297f4a80be1464013aa073a5496627fa0a0125f60af12daa769ad508cf3ea
10605+
checksum: 10c0/4908772be6dc941df276931efeb0e781777fa76e4d5d12ff9f75eb2dcc2db3065e0100efde16fde562c5bafa310cc8f50c1ee40a22640459e066e72cd342143e
1060610606
languageName: node
1060710607
linkType: hard
1060810608

@@ -26179,8 +26179,8 @@ __metadata:
2617926179
"@testing-library/jest-dom": "npm:^5.16.5"
2618026180
"@testing-library/react": "npm:^16.0.0"
2618126181
"@testing-library/user-event": "patch:@testing-library/user-event@npm%3A14.6.1#~/.yarn/patches/@testing-library-user-event-npm-14.6.1-5da7e1d4e2.patch"
26182-
"@types/react": "npm:types-react@19.0.0-rc.0"
26183-
"@types/react-dom": "npm:types-react-dom@19.0.0-rc.0"
26182+
"@types/react": "npm:^19.0.0"
26183+
"@types/react-dom": "npm:^19.0.0"
2618426184
"@yarnpkg/types": "npm:^4.0.0"
2618526185
autoprefixer: "npm:^9.6.0"
2618626186
axe-core: "npm:^4.6.3"

0 commit comments

Comments
 (0)