-
Notifications
You must be signed in to change notification settings - Fork 3
프로필 이미지 컴포넌트 #11
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
Merged
Merged
프로필 이미지 컴포넌트 #11
Changes from all commits
Commits
Show all changes
8 commits
Select commit
Hold shift + click to select a range
ee7641c
feat: 프로필 이미지 컴포넌트 추가
8e4877f
chore: profile image props 설명 주석 추가
HWAN0218 a038502
refactor: 프로필 이미지 컴포넌트 코드 리팩토링
HWAN0218 00286c1
refactor: 이미지 컴포넌트 코드 리팩토링
HWAN0218 4bb1ef6
refactor: 불필요한 코드 제거
HWAN0218 f004607
refactor: page.tsx 파일 불필요한 코드 제거
HWAN0218 694815a
refactor: 불필요한 삭제못한 코드 제거
HWAN0218 acfc6e1
refactor: api 분리 및 색상수정
HWAN0218 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 hidden or 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 |
|---|---|---|
|
|
@@ -4,4 +4,4 @@ export default function Home() { | |
| <h1>프로젝트 준비</h1> | ||
| </main> | ||
| ); | ||
| } | ||
| } | ||
This file contains hidden or 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,197 @@ | ||
| .frame { | ||
| display: inline-block; | ||
| } | ||
|
|
||
| .outer { | ||
| position: relative; | ||
| overflow: visible; | ||
| display: inline-block; | ||
| } | ||
|
|
||
| .box { | ||
| width: var(--pi-box-base); | ||
| height: var(--pi-box-base); | ||
|
|
||
| display: flex; | ||
| align-items: center; | ||
| justify-content: center; | ||
|
|
||
| position: relative; | ||
|
|
||
| border: 0; | ||
| outline: 0; | ||
| box-shadow: none; | ||
|
|
||
| overflow: visible; | ||
| } | ||
|
|
||
| .mask { | ||
| width: 100%; | ||
| height: 100%; | ||
|
|
||
| display: flex; | ||
| align-items: center; | ||
| justify-content: center; | ||
|
|
||
| overflow: hidden; | ||
| border-radius: inherit; | ||
| } | ||
|
|
||
| /* avatar */ | ||
| .avatar { | ||
| width: var(--pi-img-base); | ||
| height: var(--pi-img-base); | ||
|
|
||
| position: relative; | ||
| overflow: hidden; | ||
|
|
||
| background: inherit; | ||
| border-radius: inherit; | ||
| } | ||
|
|
||
| .clickable { | ||
| cursor: pointer; | ||
| } | ||
|
|
||
| /* border: breakpoint별 var로 대응 */ | ||
| .avatarBorder { | ||
| border-style: solid; | ||
| border-color: #e2e8f0; | ||
| border-width: var(--pi-border-base); | ||
| box-sizing: border-box; | ||
| } | ||
|
|
||
| .img { | ||
| display: block; | ||
| border-radius: inherit; | ||
| } | ||
|
|
||
| .cover { | ||
| object-fit: cover; | ||
| } | ||
|
|
||
| .contain { | ||
| object-fit: contain; | ||
| } | ||
|
|
||
| /* radius */ | ||
| .r8 { | ||
| border-radius: 8px; | ||
| } | ||
| .r12 { | ||
| border-radius: 12px; | ||
| } | ||
| .r20 { | ||
| border-radius: 20px; | ||
| } | ||
| .r32 { | ||
| border-radius: 32px; | ||
| } | ||
|
|
||
| /* edit 버튼 */ | ||
| .editButton { | ||
| position: absolute; | ||
| right: 3px; | ||
| bottom: 6px; | ||
|
|
||
| background: var(--color-background-tertiary); | ||
| border-radius: 50%; | ||
| border: none; | ||
| padding: 0; | ||
| cursor: pointer; | ||
|
|
||
| width: 18px; | ||
| height: 18px; | ||
|
|
||
| display: flex; | ||
| align-items: center; | ||
| justify-content: center; | ||
| } | ||
|
|
||
| /* 아이콘 표시 제어 */ | ||
| .pencilSmall { | ||
| display: inline-flex; | ||
| } | ||
| .pencilLarge { | ||
| display: none; | ||
| } | ||
|
|
||
| /* breakpoint: sm */ | ||
| @media (min-width: 640px) { | ||
| .box { | ||
| width: var(--pi-box-sm); | ||
| height: var(--pi-box-sm); | ||
| } | ||
| .avatar { | ||
| width: var(--pi-img-sm); | ||
| height: var(--pi-img-sm); | ||
| } | ||
| .avatarBorder { | ||
| border-width: var(--pi-border-sm); | ||
| } | ||
| } | ||
|
|
||
| @media (max-width: 767px) { | ||
| .r32 { | ||
| border-radius: 20px; | ||
| } | ||
| } | ||
|
|
||
| /* md 이상 */ | ||
| @media (min-width: 768px) { | ||
| .box { | ||
| width: var(--pi-box-md); | ||
| height: var(--pi-box-md); | ||
| } | ||
| .avatar { | ||
| width: var(--pi-img-md); | ||
| height: var(--pi-img-md); | ||
| } | ||
| .avatarBorder { | ||
| border-width: var(--pi-border-md); | ||
| } | ||
|
|
||
| .editButton { | ||
| right: 0; | ||
| width: 32px; | ||
| height: 32px; | ||
|
|
||
| /* ✅ md 버전에서만 흰색 보더 */ | ||
| border: 1px solid var(--color-background-inverse); | ||
| } | ||
|
|
||
| .pencilSmall { | ||
| display: none; | ||
| } | ||
| .pencilLarge { | ||
| display: inline-flex; | ||
| } | ||
| } | ||
|
|
||
| @media (min-width: 1024px) { | ||
| .box { | ||
| width: var(--pi-box-lg); | ||
| height: var(--pi-box-lg); | ||
| } | ||
| .avatar { | ||
| width: var(--pi-img-lg); | ||
| height: var(--pi-img-lg); | ||
| } | ||
| .avatarBorder { | ||
| border-width: var(--pi-border-lg); | ||
| } | ||
| } | ||
|
|
||
| @media (min-width: 1280px) { | ||
| .box { | ||
| width: var(--pi-box-xl); | ||
| height: var(--pi-box-xl); | ||
| } | ||
| .avatar { | ||
| width: var(--pi-img-xl); | ||
| height: var(--pi-img-xl); | ||
| } | ||
| .avatarBorder { | ||
| border-width: var(--pi-border-xl); | ||
| } | ||
| } |
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.
해당 컴포넌트 테스트를 위해서 작성하셨던 코드인 것 같아서 지우고 머지하는게 좋을 것 같습니다!