I’m working with an image editor using JavaScript. It has multiple layers of images similar to Photoshop. How can I have a div of grid on top of all the layers and still be able to click and move the bottom layers? I’m using JQuery-ui for draggable and resizable.
Are there any hacks or workaround for this?
2
Answers
Try to use
pointer-events: none
on the grid/ruler element;You can find examples here
It’s been long since the question was originally asked but below solution might help for anyone visiting this question for implementing grid overlay for html/JavaScript canvas application.
Grid Overlay using css
one can easily play with z-index / background color to make element beneath grid overlay clickable.