fix: Improved model validation for Collection (#3749)
* fix: Added improved model validation for Collection attributes * sp * fix: Enforce title length in UI
This commit is contained in:
@@ -3,6 +3,7 @@ import { observer } from "mobx-react";
|
||||
import { useState } from "react";
|
||||
import * as React from "react";
|
||||
import { Trans, useTranslation } from "react-i18next";
|
||||
import { MAX_TITLE_LENGTH } from "@shared/constants";
|
||||
import Button from "~/components/Button";
|
||||
import Flex from "~/components/Flex";
|
||||
import IconPicker from "~/components/IconPicker";
|
||||
@@ -93,6 +94,7 @@ const CollectionEdit = ({ collectionId, onSubmit }: Props) => {
|
||||
type="text"
|
||||
label={t("Name")}
|
||||
onChange={handleNameChange}
|
||||
maxLength={MAX_TITLE_LENGTH}
|
||||
value={name}
|
||||
required
|
||||
autoFocus
|
||||
|
||||
Reference in New Issue
Block a user