Skip to content

Commit

Permalink
fix: 폴더 추가, 링크 검색 글자수 제한 설정
Browse files Browse the repository at this point in the history
  • Loading branch information
sj0724 committed May 28, 2024
1 parent 12719d7 commit 1015c20
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 0 deletions.
1 change: 1 addition & 0 deletions components/Modal/AddFolderModal/AddFolderModal.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -36,6 +36,7 @@ function AddFolderModal({
control={control}
rules={{
required: '내용을 입력해주세요!',
maxLength: { value: 10, message: '10자 이하로 입력해주세요!' },
}}
render={({ field, fieldState: { error } }) => (
<Input
Expand Down
4 changes: 4 additions & 0 deletions components/SearchBar/SearchBar.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -11,6 +11,10 @@ function SearchModal({ setSearchKeyWord }: PropsType) {

const searchLink = (e: ChangeEvent<HTMLFormElement>) => {
e.preventDefault();
if (text.length >= 30) {
alert('30자 이하로 검색가능합니다!');
return;
}
setSearchKeyWord(text);
};

Expand Down

0 comments on commit 1015c20

Please sign in to comment.