From fddf1e21f3dea46d63cd8a2d5eef0019f11ec402 Mon Sep 17 00:00:00 2001 From: Paul Mineev Date: Mon, 11 Jul 2022 11:56:17 -0700 Subject: [PATCH] prettier --- frontend/.prettierignore | 1 + .../app/components/comment-form/comment-form.tsx | 13 ++++++------- 2 files changed, 7 insertions(+), 7 deletions(-) diff --git a/frontend/.prettierignore b/frontend/.prettierignore index 79ee3f7b..4db5191c 100644 --- a/frontend/.prettierignore +++ b/frontend/.prettierignore @@ -1,4 +1,5 @@ node_modules public +coverage package.json package-lock.json \ No newline at end of file diff --git a/frontend/app/components/comment-form/comment-form.tsx b/frontend/app/components/comment-form/comment-form.tsx index 7f96fc57..bdc8f011 100644 --- a/frontend/app/components/comment-form/comment-form.tsx +++ b/frontend/app/components/comment-form/comment-form.tsx @@ -20,7 +20,6 @@ import { MarkdownToolbar } from './markdown-toolbar'; import { TextExpander } from './text-expander'; import { updatePersistedComments, getPersistedComment, removePersistedComment } from './comment-form.persist'; - export type Props = { id: string; user: User | null; @@ -115,7 +114,7 @@ export class CommentForm extends Component { const { value } = e.target as HTMLInputElement; const text = value.substr(0, StaticStore.config.max_comment_size); - updatePersistedComments(this.props.id, value) + updatePersistedComments(this.props.id, value); if (this.state.errorLock) { this.setState({ @@ -166,7 +165,7 @@ export class CommentForm extends Component { return; } - removePersistedComment(this.props.id) + removePersistedComment(this.props.id); this.setState({ isDisabled: false, preview: null, text: '' }); }; @@ -322,8 +321,8 @@ export class CommentForm extends Component { continue; } - this.setState({ text: replaceSelection(this.state.text, selection, uploadPlaceholder) }, () => { - updatePersistedComments(this.props.id, this.state.text); + this.setState({ text: replaceSelection(this.state.text, selection, uploadPlaceholder) }, () => { + updatePersistedComments(this.props.id, this.state.text); }); !isFirst && (await sleep(uploadDelay)); @@ -345,8 +344,8 @@ export class CommentForm extends Component { markdownString ), }, - () => { - updatePersistedComments(this.props.id, this.state.text); + () => { + updatePersistedComments(this.props.id, this.state.text); } ); /** sleeping awhile so textarea catch state change and its selection */