   (green  [n] (green (int->color n)))
   (blue   [n] (blue (int->color n)))
   (alpha  [n] (alpha (int->color n)))
-  (coerce [n] (to-color n)))
+  (coerce [n] (int->color n)))
 
 (extend-type java.lang.String
   IColor

    #"rgb\((.*),(.*),(.*)\)" :>> color-vec
    #"rgba\((.*),(.*),(.*),(.*)\)" :>> color-vec))

(extend-type ^{:cljs cljs.core.PersistentVector} clojure.lang.PersistentVector
  IColor
  (red    [[r _ _ _]] r)

          sum (->>
                (map scale colors proportions)
                (reduce (partial map +)))]
      (coerce (mapv #(int (/ % cnt)) sum)))))