Skip to content

Commit

Permalink
[MDS-6012] Adjust comment editor max character limit to 500 (#3363)
Browse files Browse the repository at this point in the history
adjust comment editor max character limit to 500:
  • Loading branch information
asinn134 authored Jan 7, 2025
1 parent 9362cc8 commit ed4353e
Show file tree
Hide file tree
Showing 4 changed files with 5 additions and 3 deletions.
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
ALTER TABLE mine_incident_note ALTER COLUMN content TYPE character varying(500);

ALTER TABLE mine_report_comment ALTER COLUMN report_comment TYPE character varying(500);
2 changes: 1 addition & 1 deletion services/common/src/components/comments/CommentEditor.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@ interface CommentEditorProps {
export const CommentEditor: FC<CommentEditorProps> = ({
onSubmit,
addCommentPermission,
maxLength = 300,
maxLength = 500,
}) => {
const [submitting, setSubmitting] = React.useState(false);
const [comment, setComment] = React.useState("");
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -150,7 +150,6 @@ export const ProjectManagement: FC = () => {
renderEditor={true}
onSubmit={submitComment}
loading={false}
maxLength={500}
comments={ministryComments?.map((comment: IProjectSummaryMinistryComment) => ({
key: comment.project_summary_ministry_comment_guid,
author: comment.update_user,
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,7 @@ exports[`Comment renders properly 1`] = `
>
<div
class="ant-input-textarea ant-input-textarea-show-count ant-input-textarea-in-form-item"
data-count="0 / 300"
data-count="0 / 500"
>
<textarea
class="ant-input"
Expand Down

0 comments on commit ed4353e

Please sign in to comment.