surprisetalk/elm-material-icons

Material Design icons, helpers, and constructors.


Install
elm-package install surprisetalk/elm-material-icons 1.0.0

Documentation

Elm-Material-Icons

This package has a really easy-to-use API, with plenty of options!

It comes with a stylesheet and icons helpers:

import MaterialIcons
  exposing ( stylesheet
           , wrench
           , accountKey
           , briefcase
           )

view : model -> Html msg
view _
  = div []
    [ stylesheet
    , wrench
    , accountKey
    , briefcase
    ]

Customization

This package also has tools for making custom icons:

import MaterialIcons
  exposing ( stylesheet
           , i
           , Icon(Wrench,AccountKey,Briefcase)
           )

view : model -> Html msg
view _
    = div []
    [ stylesheet
    , i [] Wrench
    , i [] AccountKey
    , i [] Briefcase
    ]

Styling

Some styling shortcuts are included:

stylishFish : Html Msg
stylishFish
  = i [ light
      , flipV
      , size X48 
      ] 
    Fish

The styling helpers are also included as a record:

stylishFish : Html msg
stylishFish
  = i [ style 
        { shade    = Just Dark
        , inactive = False
        , size     = Just X36
        , flipH    = True
        , flipV    = False
        , rotation = Just Rotate135
        }
      ]
    Fish

Elm-Icon Family

Contributions