I hope you are having a nice day. I am working with the following menu:
The site with which I am working is a Single Page, I need that when clicking any of the buttons that work as anchors to different sections (referenced by ID) they also close this popup. Any idea how to do it? I can work perfectly with JS and jQuery, I know these technologies a lot.
Thanks for reading and giving me your time. I await your responses. Greetings.
I have this working for me:
give the buttons on your popup an additional class of 'close-popup'
add an HMTL widget to your popup with the following
<script>
jQuery( document ).ready( function( $ ) {
$( document ).on( 'click', '.close-popup', function( event ) {
elementorProFrontend.modules.popup.closePopup( {}, event );
} );
} );
</script>
I'd like to be able to claim the credit for this, but it goes to shilo-ey