min-width

The min-width property constrains the width of an element to a minimum range.

CSS2

Syntax

min-width: <length> | <percentage> | inherit
Initial: 0
Applies To: all elements but non-replaced inline elements, table rows, and row groups
Inherited: no
Percentages: refer to width of containing block
Media: visual

Values

min-width: value
Value Description
length Fixed minimum width
percentage Width percentage calculated with respect to the width of the containing block

DOM

[window.]document.getElementById("element-id").style.minWidth = "min-width";

Example | length

Example | percentage

Example | DOM

External

W3C Cascading Style Sheets Level 2 Revision 1 (CSS 2.1) Specification