Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[Style] CSS 스타일 개선 #1571

Merged
merged 22 commits into from
Oct 7, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
22 commits
Select commit Hold shift + click to select a range
b129bc1
Merge pull request #1413 from 42organization/main
izone00 Apr 16, 2024
c7a59c2
Merge pull request #1423 from 42organization/main
izone00 Apr 25, 2024
8f8e131
Merge pull request #1511 from 42organization/agenda
JeongRon Aug 30, 2024
8e11e6b
Merge pull request #1567 from 42organization/agenda
cweedlee Sep 9, 2024
a37f1f8
Chore: console.log제거, width 조절
irenee-14 Sep 9, 2024
54d59e5
Fix: index 페이지 select 항목 공백 제거
irenee-14 Sep 9, 2024
960683d
style: agendaList 깨짐
cweedlee Sep 9, 2024
b12f478
fix: 공지사항 선택 오류
cweedlee Sep 9, 2024
bb1bf91
style: MyAgendaList 깨짐
cweedlee Sep 9, 2024
09798c1
Merge pull request #1568 from 42organization/test-deploy
cweedlee Sep 10, 2024
cbe3498
Update main-deploy.yml
cweedlee Sep 10, 2024
04a7800
Merge pull request #1569 from 42organization/siwolee-patch-1
cweedlee Sep 10, 2024
9d62a60
Style: agendaDetail / 대회 설명 텍스트 개행 처리
JeongRon Sep 21, 2024
0092bd8
Fix: 첫 페이지 AGENDA -> Agenda
JeongRon Oct 2, 2024
a23053e
Style: 공지사항 내용 개행처리
JeongRon Oct 2, 2024
f30707f
Style: index 첫 페이지 버튼 클릭 모션 개선
JeongRon Oct 2, 2024
241ac21
Style: index페이지 / 모집 중 아젠다 없을 시 UI 개선
JeongRon Oct 2, 2024
3f8be73
Fix: 프로필 페이지 / 업적 이미지 hover 효과 적용
JeongRon Oct 2, 2024
0972f8c
Style: index 첫 페이지 텍스트 단어 변경
JeongRon Oct 2, 2024
0fd92fd
Style: 프로필 페이지 / 프로필 카드, 리스트 height 조절
JeongRon Oct 2, 2024
af3a744
Fix: 프로필 페이지 / AGENDA LIST UI 개선
JeongRon Oct 3, 2024
af33e89
Style: Agenda list 페이지 / 버튼 클릭 커서 style 추가
JeongRon Oct 5, 2024
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 1 addition & 0 deletions .github/workflows/main-deploy.yml
Original file line number Diff line number Diff line change
Expand Up @@ -20,6 +20,7 @@ jobs:
- name: Build
env:
NEXT_PUBLIC_SERVER_ENDPOINT: ${{ secrets.NEXT_PUBLIC_SERVER_ENDPOINT }}
NEXT_PUBLIC_AGENDA_SERVER_ENDPOINT: ${{ secrets.NEXT_PUBLIC_AGENDA_SERVER_ENDPOINT }}
NEXT_PUBLIC_CLIENT_ENDPOINT: ${{ secrets.NEXT_PUBLIC_CLIENT_ENDPOINT }}
NEXT_PUBLIC_MANAGE_SERVER_ENDPOINT: ${{ secrets.NEXT_PUBLIC_MANAGE_SERVER_ENDPOINT }}
NEXT_PUBLIC_PARTY_MANAGE_SERVER_ENDPOINT: ${{ secrets.NEXT_PUBLIC_PARTY_MANAGE_SERVER_ENDPOINT }}
Expand Down
11 changes: 10 additions & 1 deletion components/agenda/Home/AgendaInfo.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,7 @@ import { AgendaDataProps } from 'types/agenda/agendaDetail/agendaTypes';
import { showPeriod } from 'utils/handleTime';
import AgendaTags from 'components/agenda/utils/AgendaTags';
import StartDate from 'components/agenda/utils/StartDate';
import RightArrow from 'public/image/agenda/ChevronRight.svg';
import styles from 'styles/agenda/Home/AgendaInfo.module.scss';

// Props: API data
Expand All @@ -14,7 +15,15 @@ const AgendaInfo = ({
idx: number;
}) => {
if (!agendaInfo) {
return <div>There is no agenda</div>;
return (
<div className={styles.emptyContainer}>
<div>현재 모집 중인 행사가 없습니다.</div>
<div className={styles.emptyContent}>
<div>Agenda 페이지 이동</div>
<RightArrow className={styles.arrowIcon} />
</div>
</div>
);
}
const startDate = new Date(agendaInfo.agendaStartTime);
const endDate = new Date(agendaInfo.agendaEndTime);
Expand Down
2 changes: 1 addition & 1 deletion components/agenda/Home/AgendaTitle.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@ const AgendaTitle = () => {
return (
<>
<div className={styles.agendaTitleContainer}>
<div className={`${styles.agendaTitle}`}>AGENDA</div>
<div className={`${styles.agendaTitle}`}>Agenda</div>
<div className={styles.agendaTitleButton}>
<Link href={`/agenda/create`}>
<button className={styles.agendaCreateBtn}>
Expand Down
1 change: 0 additions & 1 deletion components/agenda/Layout/AgendaHeader.tsx
Original file line number Diff line number Diff line change
@@ -1,5 +1,4 @@
import Link from 'next/link';
import { useRouter } from 'next/router';
import { createContext, Dispatch, SetStateAction, useState } from 'react';
import { FiMenu } from 'react-icons/fi';
import Logo from 'public/image/main-logo.svg';
Expand Down
4 changes: 3 additions & 1 deletion components/agenda/Profile/CurrentList.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,9 @@ const CurrentList = ({
</div>
))
) : (
<div className={styles.currentTeamEmpty}>참여중 아젠다가 없습니다.</div>
<div className={styles.currentTeamEmpty}>
아젠다 목록이 비어있습니다. 새로운 아젠다를 시작해보세요!
</div>
)}
</div>
);
Expand Down
4 changes: 3 additions & 1 deletion components/agenda/Profile/HistoryList.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -110,7 +110,9 @@ const HistoryList = ({ historyListData }: HistoryListProps) => {
}
)
) : (
<div className={styles.historyEmpty}>아젠다 기록이 없습니다.</div>
<div className={styles.historyEmpty}>
아젠다 기록이 없습니다. 새로운 아젠다를 시작해보세요!
</div>
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

멘트 사소하지만 좋네여...

)}
</div>
</>
Expand Down
7 changes: 6 additions & 1 deletion components/agenda/Profile/ProfileCard.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -217,7 +217,12 @@ const ProfileCard = ({
key={index}
className={styles.acheivementImageWrapper}
>
<CustomImage src={parsedUrl} alt='achievement' />
<CustomImage
src={parsedUrl}
alt='achievement'
name={data.name}
description={data.description}
/>
</div>
);
}
Expand Down
2 changes: 1 addition & 1 deletion components/agenda/Ticket/Ticket.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@ interface TicketProps {
const Ticket = ({ type }: { type: string }) => {
const { data } = useFetchGet<TicketProps>({ url: '/ticket' });
const { openModal } = useModal();
console.log(data);

return (
<>
{type === 'page' ? (
Expand Down
29 changes: 20 additions & 9 deletions components/agenda/agendaDetail/tabs/AgendaAnnouncements.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -17,6 +17,10 @@ export default function AgendaAnnouncements() {
size: 5,
isReady: Boolean(agendaKey),
});
const newHandler = (page: number) => {
setSelected(0);
return PagaNationElementProps.pageChangeHandler(page);
};

if (!agendaKey || !content) {
return (
Expand All @@ -41,16 +45,23 @@ export default function AgendaAnnouncements() {
setSelected={() => setSelected(idx)}
/>
))}
<PageNation {...PagaNationElementProps} />
<PageNation
{...PagaNationElementProps}
pageChangeHandler={newHandler}
/>
</div>
<AnnouncementItem
key={content[selected].id}
id={content[selected].id}
title={content[selected].title}
content={content[selected].content}
createdAt={content[selected].createdAt}
isSelected={true}
/>
{content[selected] ? (
<AnnouncementItem
key={content[selected].id}
id={content[selected].id}
title={content[selected].title}
content={content[selected].content}
createdAt={content[selected].createdAt}
isSelected={true}
/>
) : (
''
)}
</>
) : (
<div className={styles.emptyContainer}>공지사항이 없습니다.</div>
Expand Down
2 changes: 1 addition & 1 deletion components/agenda/agendaDetail/tabs/AgendaDescription.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -37,7 +37,7 @@ export default function AgendaDescription({ agendaData }: AgendaProps) {
<div className={styles.midContainer}>
<div className={styles.descriptionItem}>
<h3>대회 설명</h3>
<span>{agendaContent}</span>
<span className={styles.preWrap}>{agendaContent}</span>
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

굿굿

</div>
<div className={styles.descriptionItem}>
<h3>모집 완료 기간</h3>
Expand Down
50 changes: 39 additions & 11 deletions components/agenda/utils/CustomImage.tsx
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
import Image from 'next/image';
import classNames from 'classnames';
import { useState } from 'react';
import { MouseEvent, useState } from 'react';
import { CustomImageProps } from 'types/agenda/utils/customImageTypes';
import styles from 'styles/agenda/utils/CustomImage.module.scss';

Expand All @@ -10,26 +10,54 @@ const CustomImage = ({
alt,
addClass,
isProfileImage,
name,
description,
}: CustomImageProps) => {
const [imgSrc, setImgSrc] = useState(src);
const [isHovered, setIsHovered] = useState(false);
const [mousePosition, setMousePosition] = useState({ x: 0, y: 0 });

const handleError = () => {
isProfileImage
? setImgSrc('/image/agenda/default-profile.svg')
: setImgSrc('/image/agenda/42-icon.svg');
};

const handleMouseEnter = (e: MouseEvent<HTMLDivElement>) => {
setIsHovered(true);
setMousePosition({
x: e.clientX,
y: e.clientY,
});
};

const handleMouseLeave = () => {
setIsHovered(false);
};

return src ? (
<Image
src={imgSrc}
key={imgSrc}
alt={alt}
width={30}
height={30}
className={classNames(styles.customImage, addClass)}
priority={true}
onError={handleError}
/>
<div
className={styles.imageContainer}
onMouseEnter={handleMouseEnter}
onMouseLeave={handleMouseLeave}
>
<Image
src={imgSrc}
key={imgSrc}
alt={alt}
width={30}
height={30}
className={classNames(styles.customImage, addClass)}
priority={true}
onError={handleError}
/>
{isHovered && (
<div className={styles.hoverContainer}>
<div className={styles.hoverName}>{name}</div>
<div className={styles.hoverDescription}>{description}</div>
</div>
)}
</div>
) : null;
};

Expand Down
2 changes: 1 addition & 1 deletion components/agenda/utils/PageController.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -99,7 +99,7 @@ const PageController = ({
? handleNavigation(
'/agenda/detail?agenda_key=' + data[current].agendaKey
)
: null;
: handleNavigation('/agenda');
}}
className={styles.toClick}
/>
Expand Down
6 changes: 3 additions & 3 deletions pages/agenda/index.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -29,7 +29,7 @@ const Agenda: NextPage = () => {
<AgendaTitle />
<div className={styles.agendaContainer}>
<div className={listStyles.agendaListTextWrapper}>
<h2>AGENDA LIST</h2>
<h2 className={listStyles.web}>AGENDA LIST</h2>
<div>
<button
className={`${listStyles.agendaListStatus}
Expand All @@ -39,7 +39,7 @@ const Agenda: NextPage = () => {
>
모집중
</button>
{' | '}
{'|'}
<button
className={`${listStyles.agendaListStatus}
${showCurrent === 'current' ? listStyles.selectedStatus : ''}`}
Expand All @@ -48,7 +48,7 @@ const Agenda: NextPage = () => {
>
진행중
</button>
{' | '}
{'|'}
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

기존 deploy된 부분이 merge가 안 된것 같습니다! 확인부탁드려요~

<button
className={`${listStyles.agendaListStatus}
${showCurrent === 'history' ? listStyles.selectedStatus : ''}`}
Expand Down
Loading
Loading