MDN self-hosted library · e01.org

`-moz-float-edge` CSS property

The non-standard -moz-float-edge CSS property specifies whether the height and width properties of the element include the margin, border, or padding thickness.

The non-standard -moz-float-edge CSS property specifies whether the height and width properties of the element include the margin, border, or padding thickness.

Syntax

/* Keyword values */
-moz-float-edge: content-box;
-moz-float-edge: margin-box;

/* Global values */
-moz-float-edge: inherit;
-moz-float-edge: initial;
-moz-float-edge: revert;
-moz-float-edge: revert-layer;
-moz-float-edge: unset;

Values

This property is specified as one of the following keyword values:

  • content-box
  • : The height and width properties include the content, but not the padding, border or margin.
  • margin-box
  • : The height and width properties include the content, padding, border and margin.

Formal definition

Formal syntax

-moz-float-edge = content-box | margin-box

Examples

HTML

<div class="box">
  <p>Lorem ipsum dolor sit amet, consectetur adipiscing elit.</p>
</div>

CSS

.box {
  display: block;
  height: 5px;
  margin: 0.5em auto;
  color: gray;
  -moz-float-edge: margin-box;
  box-sizing: border-box;
}

Result

Examples

Specifications

Not part of any standard.

Browser compatibility

See also