height
CSS 서술자(descriptor)는 뷰포트의 min-height
및 max-height
둘 다 설정하기 위한 단축(shorthand) 설명자입니다. 뷰포트 길이 값 하나를 주어 최소 높이 및 최대 높이 둘 다를 주어진 값으로 설정합니다.
뷰포트 값이 두 개 주어진 경우, 첫 번째 값은 최소 높이로 두 번째 값은 최대 높이로 설정합니다.
Related at-rule | @viewport |
---|---|
초기값 | as each of the properties of the shorthand:
|
Percentages | as each of the properties of the shorthand:
|
Computed value | as each of the properties of the shorthand:
|
구문
/* 한 값 */
height: auto;
height: 320px;
height: 15em;
/* 두 값 */
height: 320px 200px;
값
auto
- 다른 CSS 설명자의 값에서 계산된 사용값(used value).
<length>
- 음이 아닌 절대 또는 상대 길이.
<percentage>
- 가로 및 세로 길이 각각을 위한 줌 배율(factor) 1.0에서 초기 뷰포트의 너비 또는 높이에 대한 퍼센트 값. 음이 아니어야 합니다.
형식 구문
<viewport-length>{1,2}where
<viewport-length> = auto | <length-percentage>
where
<length-percentage> = <length> | <percentage>
예제
@viewport {
height: 500px;
}
명세
명세 | 상태 | 설명 |
---|---|---|
CSS Device Adaptation The definition of '"height" descriptor' in that specification. |
Working Draft | 초기 정의 |
The compatibility table on this page is generated from structured data. If you'd like to contribute to the data, please check out https://github.com/mdn/browser-compat-data and send us a pull request.