Commit dcb1102c authored by Taddeüs Kroes's avatar Taddeüs Kroes

Added tiny rgba optimization

parent b3315224
......@@ -51,6 +51,10 @@ let rec short = function
| Function ("rgb", Nary (",", [r; g; b])) ->
Function ("rgb", Nary (",", [clip r; clip g; clip b]))
(* rgba(r,g,b,1.0) -> rgb(r,g,b) *)
| Function ("rgba", Nary (",", [r; g; b; Number (1., None)])) ->
short (Function ("rgb", Nary (",", [r; g; b])))
| v -> v
let transform = function
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment