Skip to content

Commit e3d2840

Browse files
author
Adam
authored
Update README.MD
1 parent 1ac57f8 commit e3d2840

File tree

1 file changed

+22
-14
lines changed

1 file changed

+22
-14
lines changed

README.MD

Lines changed: 22 additions & 14 deletions
Original file line numberDiff line numberDiff line change
@@ -2,30 +2,38 @@ Flex Attributes
22
=============
33

44
This library allows you to compose layout with flexbox in html. Containers
5-
are composed by combining `flex-column`|`flex-row` with `flex-flow`.
5+
are composed by combining `flex`, `column` or `row`, and `layout`.
66

7-
`flex-column` or `flex-row` sets the element to be a flex container and sets the direction, `flex-flow` defines how children align on the main, and secondary axis.
8-
```
9-
flex-column="reverse nowrap" flex-flow="space-between baseline"
10-
```
7+
`layout` accepts 1 or 2 arguments, main axis (justify-content), then secondary axis (align-items).
118

12-
`flex-row` and `flex-column` can be shorthanded and default to the flexbox defaults
9+
`flex row layout="space-between stretch"`
1310

14-
```
15-
flex-row flex-flow="start baseline"
16-
```
11+
Grids are composed by using `grid-lg-*` etc.
1712

18-
`flex-flow` can be shorthanded to just the main axis
19-
```
20-
flex-row flex-flow="space-between"
21-
```
13+
Children are grown and shrunk with `grow="3"` or `shrink="4"`
14+
15+
`column` and `row`, as well as `grid-*` can be declared with a breakpoints
16+
17+
`flex column row-md layout="space-between"` (will render a column on screens smaller than 970px)
18+
19+
`grid-md-6` (will render a column with flex-basis of 50%, on devices larger than 970px)
20+
21+
Breakpoints (Bootstrap)
22+
------------
23+
24+
`xs` screens greater than 0px
25+
26+
`sm` screens greater than 750px
27+
28+
`md` screens greater than 970px
29+
30+
`lg` screens greater than 1170px
2231

2332
Installation
2433
------------
2534

2635
```
2736
npm install flex-attributes
28-
bower install flex-attributes
2937
```
3038

3139
Add, import, or require `flex-attributes/dist/flex-attributes.css` into your project.

0 commit comments

Comments
 (0)