mirror of
https://github.com/typeable/elm-ui.git
synced 2024-11-23 01:50:11 +03:00
Fix readme example
This commit is contained in:
parent
9554991b6d
commit
a8eb7e3d78
17
README.md
17
README.md
@ -15,18 +15,19 @@ This means:
|
||||
|
||||
|
||||
```elm
|
||||
import Element exposing (Element, el, text, row, alignRight, fill, width, rgb)
|
||||
import Element exposing (Element, el, text, row, alignRight, fill, width, rgb255, spacing, centerY, padding)
|
||||
import Element.Background as Background
|
||||
import Element.Border as Border
|
||||
import Element.Font as Font
|
||||
|
||||
|
||||
main =
|
||||
Element.layout []
|
||||
myElement
|
||||
|
||||
myRowOfStuff
|
||||
|
||||
myRowOfStuff : Element msg
|
||||
myRowOfStuff =
|
||||
row [ width fill ]
|
||||
row [ width fill, centerY, spacing 30 ]
|
||||
[ myElement
|
||||
, myElement
|
||||
, el [ alignRight ] myElement
|
||||
@ -36,10 +37,12 @@ myRowOfStuff =
|
||||
myElement : Element msg
|
||||
myElement =
|
||||
el
|
||||
[ Background.color (rgb 0.2 0.3 0.3)
|
||||
, Border.color (rgb 0.2 0.4 0.3)
|
||||
[ Background.color (rgb255 240 0 245)
|
||||
, Font.color (rgb255 255 255 255)
|
||||
, Border.rounded 3
|
||||
, padding 30
|
||||
]
|
||||
(text "You've made a stylish element!")
|
||||
(text "stylish!")
|
||||
```
|
||||
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user