From 73376613052b9e898626974de206dee76b18823a Mon Sep 17 00:00:00 2001 From: Dessalines Date: Wed, 26 Jul 2023 14:51:45 -0400 Subject: [PATCH] Fixing lints. --- .../components/comment/comment-node.tsx | 100 +++++++++--------- 1 file changed, 50 insertions(+), 50 deletions(-) diff --git a/src/shared/components/comment/comment-node.tsx b/src/shared/components/comment/comment-node.tsx index a4a932a3..4bfd6231 100644 --- a/src/shared/components/comment/comment-node.tsx +++ b/src/shared/components/comment/comment-node.tsx @@ -198,7 +198,7 @@ export class CommentNode extends Component { } componentWillReceiveProps( - nextProps: Readonly<{ children?: InfernoNode } & CommentNodeProps>, + nextProps: Readonly<{ children?: InfernoNode } & CommentNodeProps> ): void { if (!deepEqual(this.props, nextProps)) { this.setState({ @@ -250,27 +250,27 @@ export class CommentNode extends Component { const canMod_ = canMod( cv.creator.id, this.props.moderators, - this.props.admins, + this.props.admins ); const canModOnSelf = canMod( cv.creator.id, this.props.moderators, this.props.admins, UserService.Instance.myUserInfo, - true, + true ); const canAdmin_ = canAdmin(cv.creator.id, this.props.admins); const canAdminOnSelf = canAdmin( cv.creator.id, this.props.admins, UserService.Instance.myUserInfo, - true, + true ); const isMod_ = isMod(cv.creator.id, this.props.moderators); const isAdmin_ = isAdmin(cv.creator.id, this.props.admins); const amCommunityCreator_ = amCommunityCreator( cv.creator.id, - this.props.moderators, + this.props.moderators ); const moreRepliesBorderColor = this.props.node.depth @@ -337,7 +337,7 @@ export class CommentNode extends Component { { this.props.allLanguages.find( - lang => lang.id === cv.comment.language_id, + lang => lang.id === cv.comment.language_id )?.name } @@ -374,7 +374,7 @@ export class CommentNode extends Component { onReplyCancel={this.handleReplyCancel} disabled={this.props.locked} finished={this.props.finished.get( - this.props.node.comment_view.comment.id, + this.props.node.comment_view.comment.id )} focus allLanguages={this.props.allLanguages} @@ -472,13 +472,13 @@ export class CommentNode extends Component { className="btn btn-link btn-animate text-muted" onClick={linkEvent( this, - this.handleShowReportDialog, + this.handleShowReportDialog )} data-tippy-content={I18NextService.i18n.t( - "show_report_dialog", + "show_report_dialog" )} aria-label={I18NextService.i18n.t( - "show_report_dialog", + "show_report_dialog" )} > @@ -487,10 +487,10 @@ export class CommentNode extends Component { className="btn btn-link btn-animate text-muted" onClick={linkEvent( this, - this.handleBlockPerson, + this.handleBlockPerson )} data-tippy-content={I18NextService.i18n.t( - "block_user", + "block_user" )} aria-label={I18NextService.i18n.t("block_user")} > @@ -531,7 +531,7 @@ export class CommentNode extends Component { className="btn btn-link btn-animate text-muted" onClick={linkEvent(this, this.handleViewSource)} data-tippy-content={I18NextService.i18n.t( - "view_source", + "view_source" )} aria-label={I18NextService.i18n.t("view_source")} > @@ -548,7 +548,7 @@ export class CommentNode extends Component { className="btn btn-link btn-animate text-muted" onClick={linkEvent(this, this.handleEditClick)} data-tippy-content={I18NextService.i18n.t( - "edit", + "edit" )} aria-label={I18NextService.i18n.t("edit")} > @@ -558,7 +558,7 @@ export class CommentNode extends Component { className="btn btn-link btn-animate text-muted" onClick={linkEvent( this, - this.handleDeleteComment, + this.handleDeleteComment )} data-tippy-content={ !cv.comment.deleted @@ -588,7 +588,7 @@ export class CommentNode extends Component { className="btn btn-link btn-animate text-muted" onClick={linkEvent( this, - this.handleDistinguishComment, + this.handleDistinguishComment )} data-tippy-content={ !cv.comment.distinguished @@ -619,7 +619,7 @@ export class CommentNode extends Component { className="btn btn-link btn-animate text-muted" onClick={linkEvent( this, - this.handleModRemoveShow, + this.handleModRemoveShow )} aria-label={I18NextService.i18n.t("remove")} > @@ -630,7 +630,7 @@ export class CommentNode extends Component { className="btn btn-link btn-animate text-muted" onClick={linkEvent( this, - this.handleRemoveComment, + this.handleRemoveComment )} aria-label={I18NextService.i18n.t("restore")} > @@ -652,14 +652,14 @@ export class CommentNode extends Component { className="btn btn-link btn-animate text-muted" onClick={linkEvent( this, - this.handleModBanFromCommunityShow, + this.handleModBanFromCommunityShow )} aria-label={I18NextService.i18n.t( - "ban_from_community", + "ban_from_community" )} > {I18NextService.i18n.t( - "ban_from_community", + "ban_from_community" )} ) : ( @@ -667,7 +667,7 @@ export class CommentNode extends Component { className="btn btn-link btn-animate text-muted" onClick={linkEvent( this, - this.handleBanPersonFromCommunity, + this.handleBanPersonFromCommunity )} aria-label={I18NextService.i18n.t("unban")} > @@ -684,13 +684,13 @@ export class CommentNode extends Component { className="btn btn-link btn-animate text-muted" onClick={linkEvent( this, - this.handleShowConfirmAppointAsMod, + this.handleShowConfirmAppointAsMod )} aria-label={ isMod_ ? I18NextService.i18n.t("remove_as_mod") : I18NextService.i18n.t( - "appoint_as_mod", + "appoint_as_mod" ) } > @@ -703,7 +703,7 @@ export class CommentNode extends Component { ) : ( @@ -887,7 +887,7 @@ export class CommentNode extends Component { className="btn btn-link btn-animate text-muted" onClick={linkEvent( this, - this.handleAddAdmin, + this.handleAddAdmin )} aria-label={I18NextService.i18n.t("yes")} > @@ -901,7 +901,7 @@ export class CommentNode extends Component { className="btn btn-link btn-animate text-muted" onClick={linkEvent( this, - this.handleCancelConfirmAppointAsAdmin, + this.handleCancelConfirmAppointAsAdmin )} aria-label={I18NextService.i18n.t("no")} > @@ -939,7 +939,7 @@ export class CommentNode extends Component { {I18NextService.i18n.t("x_more_replies", { count: node.comment_view.counts.child_count, formattedCount: numToSI( - node.comment_view.counts.child_count, + node.comment_view.counts.child_count ), })}{" "} ➔ @@ -1114,7 +1114,7 @@ export class CommentNode extends Component { onReplyCancel={this.handleReplyCancel} disabled={this.props.locked} finished={this.props.finished.get( - this.props.node.comment_view.comment.id, + this.props.node.comment_view.comment.id )} focus allLanguages={this.props.allLanguages} @@ -1299,13 +1299,13 @@ export class CommentNode extends Component { } isPersonMentionType( - item: CommentView | PersonMentionView | CommentReplyView, + item: CommentView | PersonMentionView | CommentReplyView ): item is PersonMentionView { return (item as PersonMentionView).person_mention?.id !== undefined; } isCommentReplyType( - item: CommentView | PersonMentionView | CommentReplyView, + item: CommentView | PersonMentionView | CommentReplyView ): item is CommentReplyView { return (item as CommentReplyView).comment_reply?.id !== undefined; }