0

I know that the CSS pointer-events: none; makes elements beneath clickable. But it disables clicks on the top element.

How can I have a single click affect the entire "stack" of elements?

Or at least, the element in question, as well as the element immediately below it.

I did a lot of searching but it seems everyone asking about clicking through elements, is not interested in having the top element recognize the click also.

GirkovArpa
  • 4,427
  • 4
  • 14
  • 43
  • 1
    A lazy approach will be to chain the onclick event using JS. So, if the top element on the stack is clicked you can set onclick event to for the top element to perform click on the second element, and for second element you can set on click event to click on thrid element and so on....... – Mike Sep 29 '20 at 04:21
  • That is what I will resort to in absence of a better answer. – GirkovArpa Sep 29 '20 at 04:22
  • Try setting pointer-events: inherit to child elements. – norcal johnny Sep 29 '20 at 04:44

0 Answers0