-
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: add responsive style AnnounceMessageBox
- Loading branch information
Showing
5 changed files
with
51 additions
and
44 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
20 changes: 20 additions & 0 deletions
20
app/ui/view/molecule/announce-message-box/announce-massage-box.stories.tsx
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,20 @@ | ||
import type { Meta, StoryObj } from '@storybook/react'; | ||
import AnnounceMessageBox from './announce-massage-box'; | ||
|
||
const meta = { | ||
title: 'ui/view/molecule/AnnounceMessageBox', | ||
component: AnnounceMessageBox, | ||
} satisfies Meta<typeof AnnounceMessageBox>; | ||
|
||
export default meta; | ||
|
||
interface AnnounceMessageBoxProp { | ||
message: string; | ||
} | ||
|
||
export const Default: StoryObj<typeof meta> = { | ||
args: { | ||
message: '해당 파트의 졸업요건을 충족하셨습니다!', | ||
}, | ||
render: (args: AnnounceMessageBoxProp) => <AnnounceMessageBox {...args} />, | ||
}; |
29 changes: 29 additions & 0 deletions
29
app/ui/view/molecule/announce-message-box/announce-massage-box.tsx
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,29 @@ | ||
import React from 'react'; | ||
import CompletedImage from '@/public/assets/completed-category.png'; | ||
import CheckImage from '@/public/assets/check.svg'; | ||
import Image from 'next/image'; | ||
import { cn } from '@/app/utils/shadcn/utils'; | ||
|
||
interface AnnounceMessageBoxProp { | ||
message: string; | ||
} | ||
|
||
function AnnounceMessageBox({ message }: AnnounceMessageBoxProp) { | ||
return ( | ||
<div className="relative flex justify-center items-center p-2 bg-yellow-5 min-h-fit"> | ||
<Image src={CompletedImage} width={1200} height={270} alt="category-fullfill-image" className="min-h-20" /> | ||
<div className="absolute"> | ||
<Image | ||
className={cn('m-auto w-[30px]', 'md:w-[50px]')} | ||
src={CheckImage} | ||
width={50} | ||
height={36} | ||
alt="category-fullfill-image" | ||
/> | ||
<p className={cn('zIndex-1 text-sm', 'md:text-lg')}>{message}</p> | ||
</div> | ||
</div> | ||
); | ||
} | ||
|
||
export default AnnounceMessageBox; |
20 changes: 0 additions & 20 deletions
20
app/ui/view/molecule/announce-message/announce-massage.stories.tsx
This file was deleted.
Oops, something went wrong.
22 changes: 0 additions & 22 deletions
22
app/ui/view/molecule/announce-message/announce-massage.tsx
This file was deleted.
Oops, something went wrong.