css.properties

max-block-size

The max-block-size property sets the maximum size of a block in the block direction.

Formal Syntax

<'max-width'>

See specification

JavaScript Access

// Access via element.style
element.style.maxBlockSize = 'none';

Logical Property Group

This property belongs to the max-size logical property group, which includes:

Browser Support

standard | MDN · Spec · Spec

FeatureChromeFirefoxSafariEdge
max-block-size574112.179
anchor-size12514726125
fit-content579412.179
fit-content_function91
max-content576612.179
min-content576612.179
none574112.179
stretch138138

Behind a Flag

Some browsers require enabling a flag or preference:

  • max-block-size: fit-content_function — firefox: #layout.css.fit-content-function.enabled (since 91)

Related Properties