I have an anchor element that has several children inside. Requirements changed and now anchor might or might not have a link on it. The easiest way to change it would be to disable click events for anchor and keep it for children (they have some functionality that depends on pointer events).
When I apply pointer-events: none
to the anchor parent, everything is fine - the link doesn't work. When I then apply pointer-events: auto
to anchor children, the link becomes active again.
The generated html is like so:
<a href class='no-pointer-events'>
<figure class='pointer-events-auto'></figure>
</a>
How can I solve this?