From a8cbdf061ddf76989bd548a580bd3c560924d47b Mon Sep 17 00:00:00 2001 From: Tom Moor Date: Thu, 20 Feb 2025 08:52:03 -0500 Subject: [PATCH] fix: Hardcoded max collection description length, closes #8510 --- app/components/CollectionDescription.tsx | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/app/components/CollectionDescription.tsx b/app/components/CollectionDescription.tsx index c3897dca0c..2b76f4dd84 100644 --- a/app/components/CollectionDescription.tsx +++ b/app/components/CollectionDescription.tsx @@ -6,6 +6,7 @@ import { toast } from "sonner"; import styled from "styled-components"; import { richExtensions } from "@shared/editor/nodes"; import { s } from "@shared/styles"; +import { CollectionValidation } from "@shared/validations"; import Collection from "~/models/Collection"; import Editor from "~/components/Editor"; import LoadingIndicator from "~/components/LoadingIndicator"; @@ -61,7 +62,7 @@ function CollectionDescription({ collection }: Props) { onChange={handleSave} placeholder={`${t("Add a description")}…`} extensions={extensions} - maxLength={1000} + maxLength={CollectionValidation.maxDescriptionLength} canUpdate={can.update} readOnly={!can.update} editorStyle={editorStyle}