강의

멘토링

커뮤니티

Inflearn Community Q&A

kjw22980857's profile image
kjw22980857

asked

Learn HTML, CSS, and web standards properly to get a job as a publisher

Explore background styles

cover 의미 질문있습니다. !

Written on

·

303

0

cover 로 주면

박스 크기가 세로로 길면 이미지를 세로에 맞추고

 

가로로 길면 이미지를 가로에 맞춰주는건가요 ??? 

 

좀 헷갈려서 질문드렸습니다. !

HTML/CSS웹 디자인

Answer 1

1

Dongho Lee님의 프로필 이미지
Dongho Lee
Instructor

네 맞습니다.
background-size: cover 는 박스가 세로로 길면 세로에 배경 이미지를 맞추고 가로는 잘려 나갑니다. 가로가 길면 가로에 맞추고 세로는 잘려 나가게 됩니다. 

Rain D님의 프로필 이미지
Rain D
Questioner

네 감사합니다 !!

kjw22980857's profile image
kjw22980857

asked

Ask a question