| 342 | 'escapeHtml': true, | 342 | 'escapeHtml': true, |
| 343 | }; | 343 | }; |
| 344 | | 344 | |
| | 345 | |
| 345 | toastr.options.onHidden = () => { | 346 | toastr.options.onHidden = () => { |
| 346 | // If we have any dialog still open, the last "hidden" toastr will remove the toastr-container. We need to keep it alive inside the dialog though | 347 | // If we have any dialog still open, the last "hidden" toastr will remove the toastr-container. We need to keep it alive inside the dialog though |
| 347 | // so the toasts still show up inside there. | 348 | // so the toasts still show up inside there. |
| 348 | fixToastrForDialogs(); | 349 | fixToastrForDialogs(); |
| 349 | }; | 350 | }; |
| 350 | | 351 | |
| | 352 | toastr.options.onShown = function () { |
| | 353 | const $toast = $(this); // 'this' refers to the toast element |
| | 354 | const message = 'Click/Tap to close'; |
| | 355 | $toast.attr('title', message); // Set tooltip to the notification message |
| | 356 | }; |
| | 357 | |
| 351 | // Allow target="_blank" in links | 358 | // Allow target="_blank" in links |
| 352 | DOMPurify.addHook('afterSanitizeAttributes', function (node) { | 359 | DOMPurify.addHook('afterSanitizeAttributes', function (node) { |
| 353 | if ('target' in node) { | 360 | if ('target' in node) { |