PropertyBaseline: widely availablesince January 2018
MDN The clearCSS property sets whether an element must be moved below (cleared) floating elements that precede it. The clear property applies to floating and non-floating elements.
<section class="default-example" id="default-example"> <div class="example-container"> <div class="floated-left">Left</div> <div class="floated-right">Right</div> <div class="transition-all" id="example-element"> As much mud in the streets as if the waters had but newly retired from the face of the earth, and it would not be wonderful to meet a Megalosaurus, forty feet long or so, waddling like an elephantine lizard up Holborn Hill. </div> </div></section>
Syntax
inline-start | inline-end | block-start | block-end | left | right | top | bottom | both-inline | both-block | both | none
Formal grammar from the specification, as webref extracts it: the latest level's definition, sometimes ahead of what browsers implement.
Definition
Initial
none
Applies to
block-level elements, floats, regions, pages
Inherited
no
Percentages
N/A
Computed value
specified keyword
Canonical order
per grammar
Animation type
discrete
Browser support
First browser version supporting clear
Chrome
1
Edge
12
Firefox
1
Safari
1
Chrome Android
18
Safari iOS
1
First version with support, from MDN browser-compat-data.
PropertyBaseline: widely availablesince January 2018
MDN The floatCSS property places an element on the left or right side of its container, allowing text and inline elements to wrap around it. The element is removed from the normal flow of the page, though still remaining a part of the flow (in contrast to absolute positioning).
<section class="default-example" id="default-example"> <div class="example-container"> <div class="transition-all" id="example-element">Float me</div> As much mud in the streets as if the waters had but newly retired from the face of the earth, and it would not be wonderful to meet a Megalosaurus, forty feet long or so, waddling like an elephantine lizard up Holborn Hill. </div></section>
Syntax
block-start | block-end | inline-start | inline-end | snap-block | <snap-block()> | snap-inline | <snap-inline()> | left | right | top | bottom | none | footnote
Formal grammar from the specification, as webref extracts it: the latest level's definition, sometimes ahead of what browsers implement.
Definition
Initial
none
Applies to
all elements.
Inherited
no
Percentages
N/A
Computed value
as specified
Canonical order
per grammar
Animation type
by computed value type
Browser support
First browser version supporting float
Chrome
1
Edge
12
Firefox
1
Safari
1
Chrome Android
18
Safari iOS
1
First version with support, from MDN browser-compat-data.