-
Notifications
You must be signed in to change notification settings - Fork 0
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
[Feat] Home 페이지 퍼블리싱 #128
Merged
Merged
[Feat] Home 페이지 퍼블리싱 #128
Changes from all commits
Commits
Show all changes
12 commits
Select commit
Hold shift + click to select a range
e361ea9
chore: 기존 컴포넌트 test 페이지로 이동
kongnayeon 95a0021
fix: 로고 이미지 svg로 변경
kongnayeon 6885c05
fix: AccountItem 컴포넌트
kongnayeon ecf756d
feat: 계정 사이드바
kongnayeon 26a2b88
Merge remote-tracking branch 'origin/develop' into feat/#1992106a0
kongnayeon 494d16c
fix(packages/ui): Button 컴포넌트 width 수정
kongnayeon 7912748
fix(apps/web): AccountSidebar 스타일 수정
kongnayeon d75f6de
feat(apps/web): 홈 화면 card 컴포넌트들 추가
kongnayeon 535a49a
feat(apps/web): Home 페이지 퍼블리싱
kongnayeon 48ac142
fix: 코드 리뷰 반영
kongnayeon f3ac5e9
fix: tokens를 vars로 변경
kongnayeon 8eb4132
fix: 로고 svg import 방식으로 변경
kongnayeon File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
4 changes: 2 additions & 2 deletions
4
...rompt)/edit/[agentId]/[postGroupId]/log/[postId]/_components/LogSidebar/LogSidebar.css.ts
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,212 @@ | ||
'use client'; | ||
|
||
import { MainBreadcrumbItem, NavBar } from '@web/components/common'; | ||
import { AccountSidebar } from './_components/AccountSidebar/AccountSidebar'; | ||
import { useScroll } from '@web/hooks'; | ||
import { ROUTES } from '@web/routes'; | ||
import { Breadcrumb } from '@repo/ui/Breadcrumb'; | ||
import { | ||
animatedText, | ||
background, | ||
cardContent, | ||
content, | ||
dropdownItem, | ||
image, | ||
cardColumn, | ||
cardRow, | ||
flexColumn, | ||
} from './page.css'; | ||
import { Dropdown } from '@repo/ui/Dropdown'; | ||
import Image from 'next/image'; | ||
import { Icon } from '@repo/ui/Icon'; | ||
import { Text } from '@repo/ui/Text'; | ||
import { isNil } from '@repo/ui/utils'; | ||
import { GradientAnimatedText } from '@repo/ui/GradientAnimatedText'; | ||
import CreateImage from '@web/assets/images/createImage.webp'; | ||
import { CTACard } from './_components/CTACard/CTACard'; | ||
import { PersonalCard } from './_components/PersonalCard/PersonalCard'; | ||
import { UploadContentCard } from './_components/UploadContentCard/UploadContentCard'; | ||
import { ContentGroupCard } from './_components/ContentGroupCard/ContentGroupCard'; | ||
import { Spacing } from '@repo/ui/Spacing'; | ||
|
||
export default function Home() { | ||
const [scrollRef, isScrolled] = useScroll<HTMLDivElement>({ | ||
threshold: 100, | ||
}); | ||
|
||
const profileImageUrl = ''; | ||
return ( | ||
<div className={background} ref={scrollRef}> | ||
<NavBar | ||
leftAddon={ | ||
<Breadcrumb> | ||
<Breadcrumb.Item> | ||
<MainBreadcrumbItem href={ROUTES.HOME} /> | ||
</Breadcrumb.Item> | ||
</Breadcrumb> | ||
} | ||
rightAddon={ | ||
<Dropdown> | ||
<Dropdown.Trigger> | ||
{isNil(profileImageUrl) ? ( | ||
<div className={image} /> | ||
) : ( | ||
<Image | ||
className={image} | ||
width={40} | ||
height={40} | ||
src={profileImageUrl} | ||
alt={''} | ||
/> | ||
)} | ||
</Dropdown.Trigger> | ||
<Dropdown.Content align="right"> | ||
<Dropdown.Item value="option1" className={dropdownItem}> | ||
<Icon name="clock" size="2.4rem" color="grey400" /> | ||
<Text fontSize={18} fontWeight="medium" color="grey1000"> | ||
수정하기 | ||
</Text> | ||
</Dropdown.Item> | ||
</Dropdown.Content> | ||
</Dropdown> | ||
} | ||
isScrolled={isScrolled} | ||
/> | ||
<div className={content}> | ||
<AccountSidebar /> | ||
<div className={cardContent}> | ||
<GradientAnimatedText className={animatedText}> | ||
한 번의 설정으로 끝없이 흘러가는 콘텐츠 | ||
</GradientAnimatedText> | ||
|
||
<div className={cardColumn}> | ||
<div className={cardRow}> | ||
<div className={flexColumn}> | ||
{/* 주제 생성 카드 */} | ||
<CTACard | ||
text={'자동으로 글을 만들어보세요'} | ||
buttonText={'주제 생성하기'} | ||
onButtonClick={function (): void { | ||
throw new Error('Function not implemented.'); | ||
}} | ||
kongnayeon marked this conversation as resolved.
Show resolved
Hide resolved
|
||
imageSrc={CreateImage} | ||
/> | ||
<Spacing size={16} /> | ||
{/* 개인화 설정 카드 */} | ||
<PersonalCard | ||
text={'개인화 설정'} | ||
domain="활동 분야" | ||
tone="CASUAL" | ||
introduction="글을 생성할 때 계정과 관련된 업데이트나 소식을 참고하고 | ||
특정 활동 분야에 집중하거나, 특정 말투를 사용하여 글을 만들 수 있어요" | ||
onIconClick={function (): void { | ||
throw new Error('Function not implemented.'); | ||
}} | ||
/> | ||
</div> | ||
|
||
{/* 업로드 예약 일정 카드 */} | ||
<UploadContentCard | ||
text={'업로드 예약 일정'} | ||
onMoreButtonClick={function (): void { | ||
throw new Error('Function not implemented.'); | ||
}} | ||
onItemClick={(id) => { | ||
console.log('클릭한 아이템 id:', id); | ||
}} | ||
items={[ | ||
{ | ||
id: 1, | ||
createdAt: '2025-01-01T00:00:00.000Z', | ||
updatedAt: '2025-01-01T00:00:00.000Z', | ||
displayOrder: 1, | ||
summary: '오늘 점심 메뉴는 두부김치', | ||
content: '엄청나게 긴 본문', | ||
postImages: [ | ||
{ | ||
id: 1, | ||
postId: 1, | ||
url: 'https://~', | ||
}, | ||
], | ||
status: 'GENERATED', | ||
uploadTime: '2025-01-01T00:00:00.000Z', | ||
}, | ||
kongnayeon marked this conversation as resolved.
Show resolved
Hide resolved
|
||
{ | ||
id: 2, | ||
createdAt: '2025-01-01T00:00:00.000Z', | ||
updatedAt: '2025-01-01T00:00:00.000Z', | ||
displayOrder: 2, | ||
summary: '오늘 점심 메뉴는 두부김치2', | ||
content: '엄청나게 긴 본문2', | ||
postImages: [ | ||
{ | ||
id: 2, | ||
postId: 2, | ||
url: 'https://~', | ||
}, | ||
], | ||
status: 'GENERATED', | ||
uploadTime: '2025-01-01T00:00:00.000Z', | ||
}, | ||
]} | ||
/> | ||
</div> | ||
|
||
{/* 생성된 주제 카드 */} | ||
<ContentGroupCard | ||
text="생성된 주제" | ||
postGroups={[ | ||
{ | ||
id: 1, | ||
topic: '점심 메뉴 추천', | ||
purpose: 'OPINION', | ||
reference: 'NONE', | ||
newsCategory: 'ENVIRONMENT', | ||
thumbnailImageUrl: | ||
'https://instead-dev.s3.ap-northeast-2.amazonaws.com/post-group/019504d8-92ee-713e-aea0-347ce4d7bebf', | ||
length: 'SHORT', | ||
content: "'이런 메뉴는 어떨까?'와 같은 마무리 멘트", | ||
eof: false, | ||
createdAt: '2025-01-01T00:00:00.000Z', | ||
}, | ||
{ | ||
id: 2, | ||
topic: '점심 메뉴 추천 2', | ||
purpose: 'HUMOR', | ||
reference: 'NONE', | ||
newsCategory: 'GAME', | ||
thumbnailImageUrl: | ||
'https://instead-dev.s3.ap-northeast-2.amazonaws.com/post-group/019504d8-92ee-713e-aea0-347ce4d7bebf', | ||
length: 'SHORT', | ||
content: "'이런 메뉴는 어떨까?'와 같은 마무리 멘트", | ||
eof: false, | ||
createdAt: '2025-01-01T00:00:00.000Z', | ||
}, | ||
{ | ||
id: 3, | ||
topic: '점심 메뉴 추천 3', | ||
purpose: 'HUMOR', | ||
reference: 'NONE', | ||
newsCategory: 'GAME', | ||
thumbnailImageUrl: | ||
'https://instead-dev.s3.ap-northeast-2.amazonaws.com/post-group/019504d8-92ee-713e-aea0-347ce4d7bebf', | ||
length: 'SHORT', | ||
content: "'이런 메뉴는 어떨까?'와 같은 마무리 멘트", | ||
eof: false, | ||
createdAt: '2025-01-01T00:00:00.000Z', | ||
}, | ||
]} | ||
onItemClick={function (id: number | string): void { | ||
throw new Error('Function not implemented.'); | ||
}} | ||
onItemRemove={function (id: number | string): void { | ||
throw new Error('Function not implemented.'); | ||
}} | ||
/> | ||
</div> | ||
</div> | ||
</div> | ||
</div> | ||
); | ||
} |
44 changes: 44 additions & 0 deletions
44
apps/web/src/app/home/_components/AccountItem/AccountItem.css.ts
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,44 @@ | ||
import { vars } from '@repo/theme'; | ||
import { style } from '@vanilla-extract/css'; | ||
|
||
export const wrapper = style({ | ||
display: 'flex', | ||
gap: '2rem', | ||
alignItems: 'center', | ||
padding: '1.6rem 1.2rem', | ||
cursor: 'pointer', | ||
':hover': { | ||
marginLeft: '0.8rem', | ||
}, | ||
}); | ||
|
||
export const image = style({ | ||
borderRadius: '100%', | ||
width: '6rem', | ||
height: '6rem', | ||
backgroundColor: vars.colors.grey25, | ||
border: `0.1rem solid ${vars.colors.grey200}`, | ||
objectFit: 'cover', | ||
}); | ||
|
||
export const emptyImage = style({ | ||
borderRadius: '100%', | ||
width: '6rem', | ||
height: '6rem', | ||
border: `0.1rem solid ${vars.colors.grey200}`, | ||
backgroundColor: vars.colors.grey25, | ||
flexShrink: 0, | ||
}); | ||
|
||
export const agentPlanBadge = style({ | ||
display: 'flex', | ||
justifyContent: 'center', | ||
alignItems: 'center', | ||
gap: '0.4rem', | ||
}); | ||
|
||
export const textWrapper = style({ | ||
display: 'flex', | ||
flexDirection: 'column', | ||
alignItems: 'flex-start', | ||
}); |
Oops, something went wrong.
Oops, something went wrong.
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
💡 Verification agent
🧩 Analysis chain
커스텀 폰트 변수가 정의되어 있는지 확인이 필요합니다.
--font-pretendard
변수가 올바르게 정의되어 있는지 확인해주세요.🏁 Script executed:
Length of output: 171
커스텀 폰트 변수 정의 추가 필요
현재
apps/web/src/app/globals.css
(라인 27)에서 아래와 같이 변수--font-pretendard
를 사용하고 있습니다.검증 스크립트 결과, 동일한 변수가
apps/web/src/app/page.module.css
와globals.css
에서 사용되는 것으로 확인되었으나, 해당 변수를 정의하는 코드(예::root { --font-pretendard: ...; }
)는 검색되지 않았습니다.--font-pretendard
변수가 전역 또는 관련 CSS 파일(예::root
블록 내)에서 올바르게 정의되어 있는지 재검토해 주세요.