webdesserts / alchemist-js

The extensible color library
https://webdesserts.gitbooks.io/alchemist-js/
MIT License
11 stars 2 forks source link

Css parser #5

Open webdesserts opened 9 years ago

webdesserts commented 9 years ago

The css parser is weird. We need to figure out if it actually fits into the current plugin architecture or if we need to do something special for it.

webdesserts commented 9 years ago

So ya, it's been awhile since I've made this. A css parser definitely fits into the current plugin system. I've made ColorSpace plugin's generic enough that a plugin like this is easily doable. To be honest though, since a css parser would probably be outputting different types of color spaces (hex, rgb, hsl). It might be better to make this a color method.

ben-eb commented 9 years ago

:+1:

alchemist.css('hsla(196,100%,50%,1)').rgb();

Would be really good.

webdesserts commented 9 years ago

@ben-eb Thanks for the feedback. I'm looking to make some final changes to the plugin system before heading forward, but I realize how important of a feature this is. I might be splitting my current v2 up into two release so I can get this out sooner. We'll see.