aboutsummaryrefslogtreecommitdiffstats
path: root/style-generator/src/Decoder.elm
diff options
context:
space:
mode:
authorPatrick Sier <pjsier@users.noreply.github.com>2019-08-13 03:40:17 -0500
committerJakub Hampl <kopomir@gmail.com>2019-08-13 09:40:17 +0100
commitc3496315f52ae90c9c86a2d72dd8690db67dbd04 (patch)
tree4dc046b7d0f4da9745dccd8cb898500eec598c4a /style-generator/src/Decoder.elm
parent09249b8f3e88e70fc78a7d1f8b91e89c5962661b (diff)
Uses Bool instead of Expression for visibility (#51)
Diffstat (limited to 'style-generator/src/Decoder.elm')
-rw-r--r--style-generator/src/Decoder.elm3
1 files changed, 3 insertions, 0 deletions
diff --git a/style-generator/src/Decoder.elm b/style-generator/src/Decoder.elm
index 1df0a73..ce18306 100644
--- a/style-generator/src/Decoder.elm
+++ b/style-generator/src/Decoder.elm
@@ -194,6 +194,9 @@ decodeAttrs =
"filter" ->
decodeAttr "filter" (D.oneOf [ Decoder.Legacy.filter, Decode.expression ]) attrValue
+ "visibility" ->
+ decodeAttr "visible" (D.map ((==) "visible" >> bool) D.string) attrValue
+
other ->
decodeAttr (toCamelCaseLower attrName) Decode.expression attrValue
)