Меню
×
   ❮     
HTML CSS JAVASCRIPT SQL PYTHON PHP КАК СДЕЛАТЬ
     ❯   

CSS Справочники


CSS Свойства





min-height



Example

Set the minimum height of a <p> element to 200 pixels:

p.ex1 {
  min-height: 200px;
}
Try it Yourself »

Definition min-height

The min-height property defines the minimum height of an element.

If the content is smaller than the minimum height, the minimum height will be applied.

If the content is larger than the minimum height, the min-height property has no effect.

Note: This prevents the value of the height property from becoming smaller than min-height.

Show demo ❯

Default value: 0
Inherited: no
Animatable: yes, see individual properties. Read about animatable Try it
Version: CSS2
JavaScript syntax: object.style.minHeight="400px" Try it

Browser Support min-height

The numbers in the table specify the first browser version that fully supports the property.

Property
min-height 1.0 7.0 3.0 2.0.2 4.0


CSS Syntax min-height

min-height: length|initial|inherit;

Property Values min-height

Value Description Demo
length Default value is 0. Defines the minimum height in px, cm, etc. Read about length units Demo ❯
% Defines the minimum height in percent of the containing block Demo ❯
initial Sets this property to its default value. Read about initial
inherit Inherits this property from its parent element. Read about inherit

Related Pages min-height

CSS tutorial: CSS Height and Width

CSS reference: max-height property

HTML DOM reference: minHeight property



×

Связаться с отделом продаж

Если вы хотите использовать услуги schoolsw3 как образовательное учреждение, команда или предприятие, отправьте нам электронное письмо:
sales@schoolsw3.com

Сообщить об ошибке

Если вы хотите сообщить об ошибке или внести предложение, отправьте нам электронное письмо:
help@schoolsw3.com

Schoolsw3 оптимизирован для обучения и подготовки. Примеры могут быть упрощены для улучшения чтения и обучения. Учебники, ссылки и примеры постоянно проверяются, чтобы избежать ошибок, но мы не можем гарантировать полную правильность всего контента.
При использовании Schoolsw3 вы соглашаетесь прочитать и принять наши условия использования,
политику использования файлов cookie и конфиденциальности.

Авторское право 1999- © Copyright. Все права защищены. Schoolsw3 работает на SW3.CSS.