Realised that it would be incredibly useful to be able to respond to the inbuilt Trongate Modal closing, but in order to do that it needs to emit an event. This change provides that event and does so for people using both the public and or admin templates.
It requires that you actively subscribe to the event as early as possible. Below is a good example of how to do so;
document.addEventListener('DOMContentLoaded', function () {
document.addEventListener('modalClosed', function (event) {
// Place your additional logic here
});
});
This means that you can now trigger additional functionality when a modal is closed. Useful for anyone who needs it and will have zero impact on anyone who doesn't.
… app.js
Realised that it would be incredibly useful to be able to respond to the inbuilt Trongate Modal closing, but in order to do that it needs to emit an event. This change provides that event and does so for people using both the public and or admin templates.
It requires that you actively subscribe to the event as early as possible. Below is a good example of how to do so;
This means that you can now trigger additional functionality when a modal is closed. Useful for anyone who needs it and will have zero impact on anyone who doesn't.