Attribut flex-flow CSS

Définition et utilisation

La propriété flex-flow est une propriété abrégée des propriétés suivantes :

Remarque :Si l'élément n'est pas un élément flexible, la propriété flex est invalide.

Voir également :

Tutoriel CSS :Boîtes flexibles CSS

Manuel CSS :Propriété flex

Manuel CSS :Propriété flex-direction

Manuel CSS :Propriété flex-basis

Manuel CSS :Propriété flex-grow

Manuel CSS :Propriété flex-shrink

Manuel CSS :Propriété flex-wrap

Manuel HTML DOM :Propriété flexFlow

Exemple

Affiche les éléments flexibles dans le sens inverse et les retourne si nécessaire :

div {
  display: flex;
  flex-flow: row-reverse wrap;
}

Essayez-le vous-même

Syntaxe CSS

flex-flow: flex-direction flex-wrap|initial|inherit;

Valeur de l'attribut

Valeur Description
flex-direction

Valeurs possibles :

  • row
  • row-reverse
  • column
  • column-reverse
  • initial
  • inherit

La valeur par défaut est "row".

Détermine la direction de l'élément flexible.

flex-wrap

Valeurs possibles :

  • nowrap
  • wrap
  • wrap-reverse
  • initial
  • inherit

La valeur par défaut est "nowrap".

Détermine si l'élément flexible doit être retourné.

initial Set this property to its default value. See initial.
inherit Inherits this property from its parent element. See inherit.

Détails techniques

Valeur par défaut : row nowrap
Héritage : Non
Création d'animation : Non pris en charge. Voir :Propriétés liées aux animations.
Version : CSS3
Syntaxe JavaScript : object.style.flexFlow="column nowrap"

Support du navigateur

Les numéros dans le tableau indiquent la première version du navigateur qui prend en charge cette propriété en totalité.

Les numéros dans le tableau indiquent la première version du navigateur qui prend en charge cette propriété en utilisant les préfixes -webkit-, -ms- ou -moz-.

Chrome IE / Edge Firefox Safari Opera
29.0
21.0 -webkit-
11.0 28.0
18.0 -moz-
9.0
6.1 -webkit-
17.0