Since the recent UI update, I have a site that has changed its functionality.
I have some modals on the site, that I was previously using hash toggles in order to use buttons to open the modals. You used to be able to click once to activate the hash toggle, but now you have to click twice to trigger the modal.
I attempted to alter the functionality and disconnect the hash toggle form the button, and instead use JS to trigger a click on the modal toggle. I used the following code:
jQuery(document).ready(function($){
$("#teams_button").click(function(e) {
e.preventDefault();
$("#teams_modal-anchor-toggle").click();
});
})
According to other articles on the forum, this has worked for people, however my button does not activate the modal. I have verified that the button is indeed being clicked (I used a console log to check), and I can see both the toggle element and the modal element flashing in the inspector as if they were being clicked. When I made the toggle visible again (I have it sized to 0em), it animates as if it is going to toggle, and then immediately reverts.
Did something change in the recent update that would alter both the toggle has functionality, and that would negate the JS manual click of the toggle?