Skip to content

Commit

Permalink
add burger icon to show collapsed navbar when on mobile
Browse files Browse the repository at this point in the history
  • Loading branch information
garbas committed Jul 2, 2020
1 parent 1f8939b commit 2662f52
Showing 1 changed file with 15 additions and 2 deletions.
17 changes: 15 additions & 2 deletions src/Main.elm
Expand Up @@ -8,6 +8,7 @@ import Html
exposing
( Html
, a
, button
, div
, footer
, header
Expand All @@ -19,11 +20,13 @@ import Html
)
import Html.Attributes
exposing
( class
( attribute
, class
, classList
, href
, id
, src
, type_
)
import Page.Home
import Page.Options
Expand Down Expand Up @@ -278,7 +281,17 @@ view model =
[ div [ class "navbar navbar-static-top" ]
[ div [ class "navbar-inner" ]
[ div [ class "container" ]
[ a [ class "brand", href "https://nixos.org" ]
[ button
[ type_ "button"
, class "btn btn-navbar"
, attribute "data-toggle" "collapse"
, attribute "data-target" ".nav-collapse"
]
[ span [ class "icon-bar" ] []
, span [ class "icon-bar" ] []
, span [ class "icon-bar" ] []
]
, a [ class "brand", href "https://nixos.org" ]
[ img [ src "https://nixos.org/logo/nix-wiki.png", class "logo" ] []
]
, div [ class "nav-collapse collapse" ]
Expand Down

0 comments on commit 2662f52

Please sign in to comment.