Skip to content

Commit

Permalink
💄 Design: RetroList 디자인 수정 (#196)
Browse files Browse the repository at this point in the history
  • Loading branch information
yeneua authored Apr 20, 2024
1 parent 7a51745 commit 8d18af4
Show file tree
Hide file tree
Showing 7 changed files with 35 additions and 11 deletions.
Binary file removed src/assets/BookmarkIcon_N.png
Binary file not shown.
Binary file removed src/assets/BookmarkIcon_Y.png
Binary file not shown.
Binary file removed src/assets/Link.png
Binary file not shown.
Binary file removed src/assets/TeamIcon.png
Binary file not shown.
Binary file removed src/assets/UserProfile2.png
Binary file not shown.
26 changes: 15 additions & 11 deletions src/components/RetroList/ContentsList.tsx
Original file line number Diff line number Diff line change
@@ -1,9 +1,6 @@
import { useEffect, useState } from 'react';
import { CgTimelapse } from 'react-icons/cg'; // ing
import { CiStar } from 'react-icons/ci';
import { FaStar } from 'react-icons/fa';
import { FaRegCircleCheck } from 'react-icons/fa6'; // done
import { HiOutlineDotsHorizontal } from 'react-icons/hi';
import { IoMdPerson } from 'react-icons/io';
import { MdPeople } from 'react-icons/md';
import { RxCounterClockwiseClock } from 'react-icons/rx'; //before
Expand Down Expand Up @@ -73,7 +70,14 @@ const ContentList: React.FC<ContentListProps> = ({ data, viewMode, searchData, s
const convertToLocalTime = (dateString: string | number | Date) => {
const date = new Date(dateString);
const localTime = new Date(date.getTime() - date.getTimezoneOffset() * 60000);
return localTime.toLocaleString(); // 로컬 타임존으로 변환하여 문자열로 반환
const options: Intl.DateTimeFormatOptions = {
year: 'numeric',
month: 'numeric',
day: 'numeric',
hour: 'numeric',
minute: 'numeric',
};
return localTime.toLocaleString(undefined, options); // 로컬 타임존으로 변환하여 문자열로 반환
};

useEffect(() => {
Expand Down Expand Up @@ -124,10 +128,10 @@ const ContentList: React.FC<ContentListProps> = ({ data, viewMode, searchData, s
}}
>
{item.isBookmarked && (
<FaStar onClick={() => handleBookmark(item.id)} style={{ color: '#fcea12' }} size="19" />
<S.StyledFaStar onClick={() => handleBookmark(item.id)} style={{ color: '#fcea12' }} size="19" />
)}
{!item.isBookmarked && <CiStar onClick={() => handleBookmark(item.id)} size={20} />}
<HiOutlineDotsHorizontal
{!item.isBookmarked && <S.StyledCiStar onClick={() => handleBookmark(item.id)} size={20} />}
<S.StyledHiOutlineDotsHorizontal
style={{ color: '#33363F' }}
size={20}
// onClick={() => openModalForItem(item.id)}
Expand Down Expand Up @@ -190,13 +194,13 @@ const ContentList: React.FC<ContentListProps> = ({ data, viewMode, searchData, s
</S.ListTimeBox>
<S.ListBookmarkBox>
{item.isBookmarked && (
<FaStar onClick={() => handleBookmark(item.id)} style={{ color: '#fcea12' }} size="19" />
<S.StyledFaStar onClick={() => handleBookmark(item.id)} style={{ color: '#fcea12' }} size="19" />
)}
{!item.isBookmarked && <CiStar onClick={() => handleBookmark(item.id)} size={20} />}
{!item.isBookmarked && <S.StyledCiStar onClick={() => handleBookmark(item.id)} size={20} />}
</S.ListBookmarkBox>
<S.ListProgressBox>
{item.status === 'NOT_STARTED' && (
<FaRegCircleCheck
<RxCounterClockwiseClock
size={20}
style={{ alignItems: 'start', justifySelf: 'end', color: '#5B5B5B' }}
/>
Expand All @@ -212,7 +216,7 @@ const ContentList: React.FC<ContentListProps> = ({ data, viewMode, searchData, s
)}
</S.ListProgressBox>
<S.ListLinkBox>
<HiOutlineDotsHorizontal
<S.StyledHiOutlineDotsHorizontal
style={{ color: '#33363F' }}
size={20}
// onClick={() => openModalForItem(item.id)}
Expand Down
20 changes: 20 additions & 0 deletions src/styles/RetroList/ContentsList.styles.ts
Original file line number Diff line number Diff line change
@@ -1,3 +1,6 @@
import { CiStar } from 'react-icons/ci';
import { FaStar } from 'react-icons/fa';
import { HiOutlineDotsHorizontal } from 'react-icons/hi';
import styled from 'styled-components';

export const BoardContainer = styled.div`
Expand Down Expand Up @@ -134,3 +137,20 @@ export const Icon = styled.img`
cursor: pointer;
}
`;
export const StyledCiStar = styled(CiStar)`
&:hover {
cursor: pointer;
}
`;

export const StyledHiOutlineDotsHorizontal = styled(HiOutlineDotsHorizontal)`
&:hover {
cursor: pointer;
}
`;

export const StyledFaStar = styled(FaStar)`
&:hover {
cursor: pointer;
}
`;

0 comments on commit 8d18af4

Please sign in to comment.