Skip to content

Commit cf3d4c6

Browse files
authored
chore(docs): add clarification to order and order-{breakpoint} section (bootstrap-vue#3888)
1 parent 2302b31 commit cf3d4c6

File tree

1 file changed

+13
-5
lines changed

1 file changed

+13
-5
lines changed

src/components/layout/README.md

Lines changed: 13 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -454,20 +454,28 @@ Use flexbox alignment utilities to vertically and horizontally align columns.
454454

455455
Use `order-*` props for controlling the visual order of your content. These props are responsive, so
456456
you can set the order by breakpoint (e.g., `order="1" order-md="2"`). Includes support for 1 through
457-
12 across all five grid tiers.
457+
12 across all five grid tiers. `<b-col>` defaults to an order value of `0`.
458458

459459
```html
460460
<b-container fluid class="bv-example-row">
461-
<b-row>
462-
<b-col>First, but unordered</b-col>
463-
<b-col order="12">Second, but last</b-col>
464-
<b-col order="1">Third, but first</b-col>
461+
<b-row class="mb-3">
462+
<b-col>First in DOM, no order applied</b-col>
463+
<b-col order="5">Second in DOM, with a larger order</b-col>
464+
<b-col order="1">Third in DOM, with an order of 1</b-col>
465+
</b-row>
466+
467+
<b-row class="mb-3">
468+
<b-col order="6">First in DOM, with order of 6</b-col>
469+
<b-col order="1">Second in DOM, with an order of 1</b-col>
470+
<b-col>Third in DOM, no order applied</b-col>
465471
</b-row>
466472
</b-container>
467473

468474
<!-- b-grid-order.vue -->
469475
```
470476

477+
Ordering is controlled by flexbox's CSS style `order`.
478+
471479
### Offsetting columns
472480

473481
You can offset grid columns in two ways: our responsive `offset-*` props or the

0 commit comments

Comments
 (0)