Skip to content

Commit

Permalink
Explicitly specify onChange argument type
Browse files Browse the repository at this point in the history
The v7.12.0 has a more complex type for `SelectNext` and inferring the argument
type for `onChange` now fails.
  • Loading branch information
robertknight committed Jul 10, 2024
1 parent cfe513f commit 0090256
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion src/sidebar/components/ShareDialog/ImportAnnotations.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -165,7 +165,9 @@ function ImportAnnotations({
</label>
<SelectNext
value={selectedUser}
onChange={newValue => setSelectedUserId(newValue?.userid ?? null)}
onChange={(newValue: typeof selectedUser) =>
setSelectedUserId(newValue?.userid ?? null)
}
buttonId={userSelectId}
buttonContent={
selectedUser ? (
Expand Down

0 comments on commit 0090256

Please sign in to comment.