Source

Flote

Aktivite flote sou nenpòt eleman, atravè nenpòt ki pwen rupture, lè l sèvi avèk sèvis piblik flote reponn nou yo.

Apèsi sou lekòl la

Klas sèvis piblik sa yo flote yon eleman a goch oswa adwat, oswa enfim k ap flote, baze sou gwosè pòtay aktyèl la lè l sèvi avèk pwopriyete CSSfloat la . !importantenkli pou evite pwoblèm espesifik. Sa yo sèvi ak menm pwen rupture viewport kòm sistèm kadriyaj nou an. Tanpri sonje sèvis piblik flote pa gen okenn efè sou atik flex.

Klas

Chanje yon flote ak yon klas:

Flote kite sou tout gwosè viewport

Flote dwat sou tout gwosè viewport

Pa flote sou tout gwosè viewport
<div class="float-left">Float left on all viewport sizes</div><br>
<div class="float-right">Float right on all viewport sizes</div><br>
<div class="float-none">Don't float on all viewport sizes</div>

Mixins

Oswa pa Sass mixin:

.element {
  @include float-left;
}
.another-element {
  @include float-right;
}
.one-more {
  @include float-none;
}

Reponn

Varyasyon repons egziste tou pou chak floatvalè.

Flote kite sou fenèt gwosè SM (ti) oswa pi laj

Flote kite sou pòtay gwosè MD (mwayen) oswa pi laj

Flote kite sou pòtay gwosè LG (gwo) oswa pi laj

Flote kite sou pòtay gwosè XL (siplemantè) oswa pi laj

<div class="float-sm-left">Float left on viewports sized SM (small) or wider</div><br>
<div class="float-md-left">Float left on viewports sized MD (medium) or wider</div><br>
<div class="float-lg-left">Float left on viewports sized LG (large) or wider</div><br>
<div class="float-xl-left">Float left on viewports sized XL (extra-large) or wider</div><br>

Men tout klas sipò yo;

  • .float-left
  • .float-right
  • .float-none
  • .float-sm-left
  • .float-sm-right
  • .float-sm-none
  • .float-md-left
  • .float-md-right
  • .float-md-none
  • .float-lg-left
  • .float-lg-right
  • .float-lg-none
  • .float-xl-left
  • .float-xl-right
  • .float-xl-none