Closed fikryrmdhna closed 2 years ago
Sorry this has taken so long to respond to.
If I understand you have two different elements that are being triggered by click
but one is nested in the other, so when you click the inner object, both trigger.
The solution here would be to use the event filter on triggers and check the event.target
in the outer element, and ensure it isn't the inner element.
I have a product detail card where the whole card can be clicked and then a details popup will appear and it is triggered by htmx. Then on the card there is a Pesan Ulang button which triggered by htmx.
Currently, when I click Pesan Ulang, the htmx to display the details popup is also triggered.
My question is, how I do that when I click Pesan Ulang, only htmx for Pesan Ulang is triggered, not product detail popup?
I've tried to handle it with javascript but it's still triggered. Is there a way in htmx to handle this?
Javascript