Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[MDS-6012] Adjust comment editor max character limit to 500 #3363

Merged
merged 1 commit into from
Jan 7, 2025
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
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
Loading