Propriété de style flexWrap
Exemple
Faire emballer les éléments souples si nécessaire :
document.getElementById("main".style.flexWrap = "wrap";
Définition et utilisation
La propriété flexWrap spécifie si les éléments flexibles doivent être renvoyés à la ligne ou non.
Remarque : Si les éléments ne sont pas des éléments flexibles, la propriété flexWrap n'a aucun effet.
Prise en charge du navigateur
Property | |||||
---|---|---|---|---|---|
flexWrap | Yes | 11.0 | Yes | 9.0 | Yes |
Syntaxe
Renvoyez la propriété flexWrap :
object.style.flexWrap
Définissez la propriété flexWrap :
object.style.flexWrap = "nowrap|wrap|wrap-reverse|initial|inherit"
Valeurs de propriété
Value | Description |
---|---|
nowrap | Default value. Specifies that the flexible items will not wrap |
wrap | Specifies that the flexible items will wrap if necessary |
wrap-reverse | Specifies that the flexible items will wrap, if necessary, in reverse order |
initial | Sets this property to its default value. Read about initial |
inherit | Inherits this property from its parent element. Read about inherit |
Détails techniques
Valeur par défaut: | maintenant |
---|---|
Valeur de retour : | Une chaîne, représentant la propriété flex-wrap d'un élément |
Version CSS | CSS3 |
Pages connexes
Référence CSS : propriété flex-wrap
Référence HTML DOM STYLE : propriété flex
Référence HTML DOM STYLE : propriété flexBasis
Référence HTML DOM STYLE : propriété flexDirection
Référence HTML DOM STYLE : propriété flexFlow
Référence HTML DOM STYLE : propriété flexGrow
Référence HTML DOM STYLE : propriété flexShrink
❮ Objet de style