Can dmx-on:click
be used on the <option>
element in a dropdown? I had tried using a dmx-on:click
event to close a modal right after an <option>
in a dropdown is selected, but it does not seem to work. In order to test, I tried using different dmx-on:click
expressions that do different things, but it just doesnt seem to work when applied to an <option>
element in a <select>
dropdown. Is this expected?
What are you trying to achieve exactly?
I think i mentioned above. I want to close a modal when a dropdown selection has been clicked.
There are other ways around this, but I created this topic just to get clarity on the general question of if <dmx-on:click>
expressions do or do not work when applied to <option>
elements in a <select>
dropdown.
Just use the value changed dynamic event on the select.
So the answer to my specific question then is “no, <dmx-on:click>
does not work when applied to <option>
elements in a <select>
dropdown” - is that correct?
I’m not trying to be pedantic here and I appreciate the alternative solution, but like I mentioned I am aware there are other solutions including the one you mentioned. I just want a clear answer on whether <dmx-on:click>
expressions do or do not work when applied to <option>
elements in a <select>
dropdown.
That’s correct