Firefox Tomorrow

css property

`-moz-float-edge` CSS property

View on MDN ↗

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: unset;

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

Interactive exampleOpen the canonical MDN source to run this embedded demo.

Specifications

Not part of any standard.

Browser compatibility

Browser compatibilityCompatibility data is available on the canonical MDN page.

See also