viclafouch / mui-color-input

📌 A color input designed for MUI (Material ui) V6 built with TinyColor
https://viclafouch.github.io/mui-color-input/
60 stars 20 forks source link

fix color selection with touch screen #9

Closed DorianRudolph closed 1 year ago

DorianRudolph commented 1 year ago

Currently you cannot drag the circle in the ColorSpace with touch. I fix this by using pointer events instead of mouse events to receive touch move events. I also add touch-action:none to ColorSpace to receive pointermove events. Otherwise the browser would assume a scroll gesture takes place and stop sending pointermove events after the first few.

viclafouch commented 1 year ago

Thanks a lot @DorianRudolph !

viclafouch commented 1 year ago

Deployed in https://github.com/viclafouch/mui-color-input/releases/tag/v1.0.5