-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
* style: 채팅이 투표 아래로 지나가는 오류 수정 * feat: storybook에 tailwind 적용 * refactor: 채팅 메세지 컴포넌트 분리 * design: 스트리밍 컴포넌트 배경 이미지 구현 * design: 커스텀한 gray 로 변경 * feat: 스트리밍 컴포넌트 구현
- Loading branch information
1 parent
43e2a4d
commit 3355402
Showing
18 changed files
with
116 additions
and
23 deletions.
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
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
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,8 @@ | ||
export interface Album { | ||
coverImage: string; | ||
tags: string[]; | ||
title: string; | ||
artist: string; | ||
currentTime: string; | ||
trackName: string; | ||
} |
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
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,13 @@ | ||
import type { Meta, StoryObj } from '@storybook/react'; | ||
|
||
import { Message } from './Message'; | ||
|
||
const meta = { | ||
component: Message, | ||
} satisfies Meta<typeof Message>; | ||
|
||
export default meta; | ||
|
||
type Story = StoryObj<typeof meta>; | ||
|
||
export const Default: Story = {}; |
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,8 @@ | ||
export function Message() { | ||
return ( | ||
<div className="text-sm pb-4"> | ||
<span className="text-brand mr-4">코난못난코</span> | ||
<span className="text-grayscale-100">안녕하세요</span> | ||
</div> | ||
); | ||
} |
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 |
---|---|---|
@@ -1 +1,2 @@ | ||
export { Message } from './Message'; | ||
export { Chatting } from './Chatting'; |
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,16 @@ | ||
interface AlbumBackgroundProps { | ||
coverImage: string; | ||
} | ||
|
||
export function AlbumBackground({ coverImage }: AlbumBackgroundProps) { | ||
return ( | ||
<> | ||
<img | ||
src={coverImage} | ||
className="absolute inset-0 w-full h-full object-cover scale-150 blur-lg" | ||
alt="Album Cover" | ||
/> | ||
<div className="absolute inset-0 bg-grayscale-900 opacity-70"></div> | ||
</> | ||
); | ||
} |
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,27 @@ | ||
import { Album } from '@/entities/album/type'; | ||
|
||
interface AlbumInfoProps { | ||
album: Album; | ||
} | ||
|
||
export function AlbumInfo({ album }: AlbumInfoProps) { | ||
return ( | ||
<div className="flex flex-col items-center w-1/2 relative"> | ||
<div className="text-center mb-32 w-full"> | ||
<p className="text-gray-300 mb-4">#{album.tags.join(' #')}</p> | ||
<p className="text-4xl font-bold mb-4">{album.title}</p> | ||
<p>{album.artist}</p> | ||
</div> | ||
<div className="flex flex-col items-center"> | ||
<p className="text-sm mb-3">{album.currentTime}</p> | ||
<img | ||
src={album.coverImage} | ||
alt="Album Cover" | ||
className="w-52 h-52 object-cover rounded-lg mb-4" | ||
/> | ||
<p className="text-2xl font-bold">{album.trackName}</p> | ||
</div> | ||
<div className="absolute bottom-0 bg-grayscale-900 w-full h-52"></div> | ||
</div> | ||
); | ||
} |
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,24 @@ | ||
import { AlbumBackground } from './AlbumBackground'; | ||
import { AlbumInfo } from './AlbumInfo'; | ||
import { Album } from '@/entities/album/type'; | ||
import SampleAlbumCover from '@/assets/sample-album-cover-1.png'; | ||
|
||
const SAMPLE_ALBUM: Album = { | ||
coverImage: SampleAlbumCover, | ||
tags: ['밴드', '국내'], | ||
title: '코난못난코코난못난코코난못난코코난못난코', | ||
artist: 'TOUCHED', | ||
currentTime: '00:00', | ||
trackName: '불시', | ||
}; | ||
|
||
export function Streaming() { | ||
return ( | ||
<div className="bg-grayscale-400 w-3/4 relative overflow-hidden"> | ||
<AlbumBackground coverImage={SAMPLE_ALBUM.coverImage} /> | ||
<div className="absolute inset-0 flex justify-center pt-36 text-grayscale-100 z-10"> | ||
<AlbumInfo album={SAMPLE_ALBUM} /> | ||
</div> | ||
</div> | ||
); | ||
} |
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 @@ | ||
export { Streaming } from './Streaming'; |
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