From 071b07463ab3f6894928b13553e98cd47c9ccb18 Mon Sep 17 00:00:00 2001 From: Joris Date: Tue, 28 Jun 2016 00:32:37 +0200 Subject: Add tooltips --- src/client/elm/Model/Size.elm | 17 +++++++++++++++++ 1 file changed, 17 insertions(+) create mode 100644 src/client/elm/Model/Size.elm (limited to 'src/client/elm/Model') diff --git a/src/client/elm/Model/Size.elm b/src/client/elm/Model/Size.elm new file mode 100644 index 0000000..b29e90b --- /dev/null +++ b/src/client/elm/Model/Size.elm @@ -0,0 +1,17 @@ +module Model.Size exposing + ( Size + , sizeDecoder + ) + +import Json.Decode as Json exposing ((:=)) + +type alias Size = + { width: Int + , height: Int + } + +sizeDecoder : Json.Decoder Size +sizeDecoder = + Json.object2 Size + ("width" := Json.int) + ("height" := Json.int) -- cgit v1.2.3