Skip to content

Fix text change detection on uploading a problem file#21

Merged
schweikart merged 1 commit intodevelopfrom
fix/text-change-detection
Jun 27, 2023
Merged

Fix text change detection on uploading a problem file#21
schweikart merged 1 commit intodevelopfrom
fix/text-change-detection

Conversation

@Elscrux
Copy link
Copy Markdown
Member

@Elscrux Elscrux commented Jun 22, 2023

Simple fix.

@Elscrux Elscrux requested a review from schweikart June 22, 2023 16:26
helpBody={<Help/>}
problemString={text}
setProblemString={setText}
setProblemString={x => onTextChanged(x as string)}
Copy link
Copy Markdown
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

One thing I wasn't sure about is how to handle this properly.
x is a React.SetStateAction<string>, but actually just a string that we can pass to onTextChanged.
I added the part as string to avoid IDE warnings.

@schweikart schweikart merged commit de2245e into develop Jun 27, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants