Skip to content

Commit

Permalink
Merge pull request #64 from PNU-AID/dev
Browse files Browse the repository at this point in the history
Dev: 헤더 수정 및 스터디 데이터 수정
  • Loading branch information
yeonddori authored Feb 25, 2024
2 parents 1111bc9 + d7a8e3d commit 174ffda
Show file tree
Hide file tree
Showing 4 changed files with 20 additions and 10 deletions.
6 changes: 3 additions & 3 deletions src/components/common/Header.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -102,7 +102,7 @@ function Header() {
isDropdownExpanded ? '' : 'overflow-hidden',
].join(' ')}
>
<a href={import.meta.env.VITE_AID_NOTION_NEWS_URL} target="_blank">
{/* <a href={import.meta.env.VITE_AID_NOTION_NEWS_URL} target="_blank">
<Button
className={[
!isDarkPage(location.pathname)
Expand All @@ -114,7 +114,7 @@ function Header() {
label="About Us"
size="large"
/>
</a>
</a> */}
{headerData.map((item) => {
if (item.label === 'Login') {
if (authState.isAuthenticated) {
Expand Down Expand Up @@ -182,7 +182,7 @@ function Header() {
: 'text-black',
].join(' ')}
>
Contack Us
About Us
</button>
<IoIosArrowDown
className={[
Expand Down
16 changes: 12 additions & 4 deletions src/components/studypage/Modal.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -38,12 +38,20 @@ export default function Modal({ isOpen, onClose, selectedItem }: ModalProps) {
)}
<div className="mb-4 text-base text-gray-600">
<p>
<AiOutlineCalendar className="inline-block mr-2" /> 시작일:{' '}
{selectedItem.study_start.split('T')[0]}
{selectedItem.study_start && (
<span>
<AiOutlineCalendar className="inline-block mr-2" /> 시작일:{' '}
{selectedItem.study_start.split('T')[0]}
</span>
)}
</p>
<p>
<AiOutlineCalendar className="inline-block mr-2" /> 종료일:{' '}
{selectedItem.study_end.split('T')[0]}
{selectedItem.study_end && (
<span>
<AiOutlineCalendar className="inline-block mr-2" /> 종료일:{' '}
{selectedItem.study_end.split('T')[0]}
</span>
)}
</p>
<p>
<AiOutlineUser className="inline-block mr-2" />
Expand Down
4 changes: 3 additions & 1 deletion src/components/studypage/Posts.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -138,7 +138,9 @@ export default function Posts({ studyList }: { studyList: StudyItem[] }) {
>
<div className="flex justify-between mb-3 text-sm font-bold text-gray-400 border-b-2">
<span>{'study_name' in item ? '스터디' : '프로젝트'}</span>
<span>~{item.study_end.split('T')[0]}</span>
<span>
{item.study_end ? `~${item.study_end.split('T')[0]}` : ''}
</span>
</div>
<div className="flex items-center justify-center h-40 mb-5">
<img
Expand Down
4 changes: 2 additions & 2 deletions src/types/study.ts
Original file line number Diff line number Diff line change
Expand Up @@ -12,8 +12,8 @@ export interface StudyItem {
participants: string[];
img_url: string;
created_at: string;
study_start: string;
study_end: string;
study_start?: string;
study_end?: string;
}

export interface OptionProps {
Expand Down

0 comments on commit 174ffda

Please sign in to comment.