| 314 | }); | 314 | }); |
| 315 | | 315 | |
| 316 | // Configure toast library: | 316 | // Configure toast library: |
| 317 | toastr.options.escapeHtml = true; // Prevent raw HTML inserts | 317 | /* toastr.options.escapeHtml = true; // Prevent raw HTML inserts |
| 318 | toastr.options.timeOut = 4000; // How long the toast will display without user interaction | 318 | toastr.options.timeOut = 4000; // How long the toast will display without user interaction |
| 319 | toastr.options.extendedTimeOut = 10000; // How long the toast will display after a user hovers over it | 319 | toastr.options.extendedTimeOut = 10000; // How long the toast will display after a user hovers over it |
| 320 | toastr.options.progressBar = true; // Visually indicate how long before a toast expires. | 320 | toastr.options.progressBar = false; // Visually indicate how long before a toast expires. |
| 321 | toastr.options.closeButton = true; // enable a close button | 321 | toastr.options.closeButton = false; // enable a close button |
| | 322 | toastr.options.hideEasing = 'linear'; |
| | 323 | toastr.options.showEasing = 'linear'; |
| | 324 | toastr.options.showMethod = 'fadeIn'; |
| | 325 | toastr.options.hideMethod = 'fadeOut'; |
| | 326 | toastr.options.showDuration = 1000; |
| | 327 | toastr.options.hideDuration = 1000; */ |
| 322 | //toastr.options.positionClass = power_user.toastr_position; // Where to position the toast container | 328 | //toastr.options.positionClass = power_user.toastr_position; // Where to position the toast container |
| | 329 | |
| | 330 | |
| | 331 | toastr.options = { |
| | 332 | 'closeButton': false, |
| | 333 | 'progressBar': false, |
| | 334 | 'showDuration': 250, |
| | 335 | 'hideDuration': 250, |
| | 336 | 'timeOut': 4000, |
| | 337 | 'extendedTimeOut': 10000, |
| | 338 | 'showEasing': 'linear', |
| | 339 | 'hideEasing': 'linear', |
| | 340 | 'showMethod': 'fadeIn', |
| | 341 | 'hideMethod': 'fadeOut', |
| | 342 | }; |
| | 343 | |
| 323 | toastr.options.onHidden = () => { | 344 | toastr.options.onHidden = () => { |
| 324 | // 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 | 345 | // 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 |
| 325 | // so the toasts still show up inside there. | 346 | // so the toasts still show up inside there. |