Skip to content

Commit

Permalink
[Feat] : 공지사항이 없어도 공지사항이 없다는 프리뷰를 보여주도록 수정 #677
Browse files Browse the repository at this point in the history
  • Loading branch information
raehy19 committed Feb 27, 2023
1 parent ea4d998 commit 7ba7785
Show file tree
Hide file tree
Showing 2 changed files with 15 additions and 6 deletions.
14 changes: 8 additions & 6 deletions components/admin/announcement/AnnounceEdit.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -19,11 +19,11 @@ export default function AnnounceEdit() {
const announceCreateResponse: { [key: string]: string } = {
SUCCESS: '공지사항이 성공적으로 등록되었습니다.',
AC001:
'이미 활성화된 공지사항이 있습니다 새로운 공지사항을 등록하시려면 활성화된 공지사항을 삭제해 주세요.',
'이미 활성화된 공지사항이 있습니다. 새로운 공지사항을 등록하시려면 활성화된 공지사항을 삭제해 주세요.',
};
const announceDeleteResponse: { [key: string]: string } = {
SUCCESS: '공지사항이 성공적으로 삭제되었습니다.',
AD001: '삭제할 활성화된 공지사항이 없습니다',
AD001: '삭제 할 활성화된 공지사항이 없습니다.',
};

useEffect(() => {
Expand Down Expand Up @@ -66,8 +66,8 @@ export default function AnnounceEdit() {

return (
<div className={styles.container}>
{content && (
<div className={styles.announceModal}>
<div className={styles.announceModal}>
{content ? (
<div className={styles.announceModalContainer}>
<div className={styles.modalTitle}>Notice!</div>
<Quill
Expand All @@ -89,8 +89,10 @@ export default function AnnounceEdit() {
</div>
</div>
</div>
</div>
)}
) : (
<div className={styles.noActive}>활성화된 공지사항이 없습니다 !</div>
)}
</div>
<div className={styles.editorContainer}>
<Quill
className={styles.quillEditor}
Expand Down
7 changes: 7 additions & 0 deletions styles/admin/announcement/AnnounceEdit.module.scss
Original file line number Diff line number Diff line change
Expand Up @@ -101,6 +101,13 @@
}
}

.noActive {
@include modal-container;
margin: 1.5rem;
font-size: $big-font;
color: black;
}

.editorContainer {
display: flex;
flex-direction: column;
Expand Down

0 comments on commit 7ba7785

Please sign in to comment.