-
Notifications
You must be signed in to change notification settings - Fork 3
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
[Feat] 디자인 시스템 초안 작성
- Loading branch information
Showing
11 changed files
with
164 additions
and
25 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
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
Oops, something went wrong.
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 |
---|---|---|
|
@@ -67,4 +67,4 @@ | |
"msw": { | ||
"workerDirectory": "public" | ||
} | ||
} | ||
} |
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 @@ | ||
import { ComponentStory } from '@storybook/react'; | ||
import React from 'react'; | ||
|
||
import Example from '.'; | ||
|
||
export default { | ||
component: Example, | ||
title: 'Components/Example', | ||
}; | ||
|
||
const Template: ComponentStory<typeof Example> = (args) => <Example {...args} />; | ||
|
||
export const Default = Template.bind({}); | ||
Default.args = { | ||
title: 'Example Word', | ||
}; |
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,25 @@ | ||
import styled from '@emotion/styled'; | ||
|
||
import theme from '../../styles/theme'; | ||
|
||
const StyledButton = styled.button` | ||
background-color: ${theme.color.G8}; | ||
color: ${theme.color.Primary1}; | ||
border: 1px solid ${theme.color.borderPrimary}; | ||
border-radius: ${theme.borderRadius.sm}; | ||
padding: 8px 16px; | ||
line-height: ${theme.lineHeight.B}; | ||
font-size: ${theme.textSize.B2}; | ||
font-weight: ${theme.fontWeight.bold}; | ||
font-family: ${theme.fontFamily.mainTitle}; | ||
cursor: pointer; | ||
transition: all 0.2s ease-in-out; | ||
margin: 10px; | ||
&:hover { | ||
background-color: ${theme.color.Primary2}; | ||
color: ${theme.color.G8}; | ||
} | ||
`; | ||
|
||
export default StyledButton; |
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 React from 'react'; | ||
|
||
import StyledButton from './Example.style'; | ||
|
||
interface MyButtonProps { | ||
title: string; | ||
} | ||
|
||
const MyButton = ({ title }: MyButtonProps) => { | ||
return <StyledButton>{title}</StyledButton>; | ||
}; | ||
|
||
export default MyButton; |
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 { default } from './Example'; |
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,46 @@ | ||
@font-face { | ||
font-family: 'Pretendard-Regular'; | ||
src: url('https://cdn.jsdelivr.net/gh/Project-Noonnu/[email protected]/Pretendard-Regular.woff') format('woff'); | ||
font-weight: 400; | ||
font-style: normal; | ||
} | ||
body { | ||
line-height: 1; | ||
background-color: #101012; | ||
color: #f1f3f5; | ||
} | ||
ol, | ||
ul { | ||
list-style: none; | ||
} | ||
blockquote, | ||
q { | ||
quotes: none; | ||
} | ||
blockquote:before, | ||
blockquote:after, | ||
q:before, | ||
q:after { | ||
content: ''; | ||
content: none; | ||
} | ||
table { | ||
border-collapse: collapse; | ||
border-spacing: 0; | ||
} | ||
h1 { | ||
font-size: 20pt; | ||
font-weight: bold; | ||
} | ||
h2 { | ||
font-size: 18pt; | ||
font-weight: medium; | ||
} | ||
h3 { | ||
font-size: 16pt; | ||
font-weight: regular; | ||
} | ||
p { | ||
font-size: 14pt; | ||
font-weight: regular; | ||
} |
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,57 @@ | ||
const theme = { | ||
color: { | ||
// common color | ||
G8: '#F8F9FA', | ||
G7: '#9C9EA7', | ||
G6: '#6E7178', | ||
G5: '#4E5259', | ||
G4: '#373a40', | ||
G3: '#1E1D23', | ||
G2: '#141517', | ||
G1: '#101012', | ||
Primary1: '#D2FA64', | ||
Primary2: '#b2dd3c', | ||
Secondary1: '#ff3d60', | ||
Secondary2: '#e02d4d', | ||
// specialized color | ||
topicPrimary: '#ff7991', | ||
topicSecondary: '#aef19d', | ||
txtPrimary: '#f1f3f5', | ||
txtSecondary: '#6E7178', | ||
txtDanger: '#ff0000', | ||
borderPrimary: '#f8f9fa', | ||
}, | ||
fontFamily: { | ||
basic: 'Pretendard', | ||
mainTitle: 'Syne', | ||
}, | ||
fontWeight: { | ||
light: 300, | ||
regular: 400, | ||
bold: 700, | ||
}, | ||
textSize: { | ||
H1: '40px', | ||
H2: '24px', | ||
H3: '20px', | ||
T1: '18px', | ||
T2: '16px', // B1과 동일 | ||
T3: '15px', | ||
B2: '14px', | ||
B3: '12px', | ||
B4: '8px', | ||
code: '16px', | ||
}, | ||
lineHeight: { | ||
H: '130%', | ||
B: '150%', | ||
}, | ||
// TODO: 반응형 도입시 재정의 필요. (임시로 기준값 설정한 상태) | ||
responsive: { | ||
sm: '480px', | ||
md: '768px', | ||
lg: '1024px', | ||
}, | ||
} as const; | ||
|
||
export default theme; |