Вы находите это?
Использовать jQuery.colorfy
Код: https://github.com/cheunghy/jquery.colorfy
Демо: http://cheunghy.github.io/jquery.colorfy/
Screencast: https://www.youtube.com/ смотреть? v = b1Lu_qKrLZ0