HTML DOM style commander propriété
Exemples
Flexible fixé l'ordre des éléments:
document.getElementById("myBlueDIV").style.order = "3";
document.getElementById("myGreenDIV").style.order = "1";
document.getElementById("myPinkDIV").style.order = "2";
Essayez »
Définition et utilisation
attribut de commande spécifie un projet flexible par rapport à l'ordre du même conteneur flexible pour d'autres articles.
Remarque: Si l'élémentest pas projet flexible, la propriété de commande ne fonctionne pas.
support du navigateur
Firefox, Opera et Chrome propriété de commande de support.
grammaire
Renvoie l'ordre des attributs:
Définissez les attributs d'ordre:
Valeur de la propriété
值 | 描述 |
---|---|
number | 默认值是 0。规定灵活项目的顺序。 |
initial | 设置该属性为它的默认值。请参阅 initial 。 |
inherit | 从父元素继承该属性。请参阅 inherit 。 |
détails techniques
Par défaut: | 0 |
---|---|
Retours: | Chaîne représentant l'attribut de commande de l'élément. |
CSS version | CSS3 |
articles connexes
CSS Manuel de référence: la propriété Ordre
HTML DOM STYLE Référence: propriété alignContent
HTML DOM STYLE Référence: propriété alignItems
HTML DOM STYLE Référence: propriété alignSelf
HTML DOM STYLE Référence: Propriétés Flex
HTML DOM STYLE Référence: propriété flexBasis
HTML DOM STYLE Référence: propriété flexDirection
HTML DOM STYLE Référence: propriété FlexFlow
HTML DOM STYLE Référence: propriété flexGrow
HTML DOM STYLE Référence: propriété flexShrink
HTML DOM STYLE Référence: propriété flexWrap