From 8892ad420fe36ec3a900a500e69c5990e5b5b26d Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Pablo=20Andr=C3=A9s=20V=C3=A9lez=20Vidal?= Date: Sun, 10 Nov 2024 15:29:56 +0100 Subject: [PATCH] GH-262 - fix issue gui unresponsive when adding a todo --- webapp/src/components/add_issue/add_issue.jsx | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/webapp/src/components/add_issue/add_issue.jsx b/webapp/src/components/add_issue/add_issue.jsx index 5d7fe7f..a7835d7 100644 --- a/webapp/src/components/add_issue/add_issue.jsx +++ b/webapp/src/components/add_issue/add_issue.jsx @@ -44,10 +44,14 @@ export default class AddIssue extends React.PureComponent { attachToThread: false, previewMarkdown: false, assigneeModal: false, + isTyping: false, }; } static getDerivedStateFromProps(props, state) { + if (state.isTyping) { + return null; + } if (props.visible && (props.message !== state.message || props.postPermalink !== state.postPermalink)) { return { message: props.message, @@ -88,6 +92,7 @@ export default class AddIssue extends React.PureComponent { message: '', description: '', postPermalink: '', + isTyping: false, }); if (attachToThread) { @@ -123,6 +128,7 @@ export default class AddIssue extends React.PureComponent { handleInputChange = (e, field) => { this.setState({ [field]: e.target.value, + isTyping: true, }); }