mdbassit / Coloris

A lightweight and elegant JavaScript color picker. Written in vanilla ES6, no dependencies. Accessible.
https://coloris.js.org/examples.html
MIT License
443 stars 58 forks source link

Materializecss compatibility #125

Closed hoesman closed 7 months ago

hoesman commented 9 months ago

Could you make it compatible with materializecss? It kinda works with some problems, the inputs are buggin, the input where the color should be displayed is just showing the hex code and the input on the picker itself is misaligned and bugged

Here pictures, the second one is the desired square with the color https://imgur.com/a/HO0smPU

mdbassit commented 9 months ago

Ah, another overzealous CSS framework!!

If you are using the latest version of Coloris, add this code after you initialize it:

Coloris.ready(() => {
  document.getElementById('clr-color-value').classList.add('browser-default');
});
hoesman commented 9 months ago

Thanks will give it a try, meanwhile i have been using the html type="color" which isnt that bad except for firefox using the ugly windows color picker, this is nicer and same across browsers