Fixed formatting in toastHandler
This commit is contained in:
parent
a8b0374d5e
commit
37649ec98e
@ -12,7 +12,7 @@ function createNewToast(message, colorSelector, autoHideTime = 3000, autoReload
|
|||||||
const targetContainer = document.getElementById('toastMainController');
|
const targetContainer = document.getElementById('toastMainController');
|
||||||
const masterToast = document.getElementById('masterToast');
|
const masterToast = document.getElementById('masterToast');
|
||||||
const newToast = masterToast.cloneNode(true);
|
const newToast = masterToast.cloneNode(true);
|
||||||
newToast.classList.add(colorSelector)
|
newToast.classList.add(colorSelector);
|
||||||
newToast.id = `toast-${currentToasts.length}`;
|
newToast.id = `toast-${currentToasts.length}`;
|
||||||
console.log(newToast.childNodes[1]);
|
console.log(newToast.childNodes[1]);
|
||||||
newToast.childNodes[1].childNodes[1].innerHTML = message;
|
newToast.childNodes[1].childNodes[1].innerHTML = message;
|
||||||
@ -41,7 +41,7 @@ function destroyToast(id){
|
|||||||
|
|
||||||
// Moved here
|
// Moved here
|
||||||
function normalizeToast() {
|
function normalizeToast() {
|
||||||
console.warn("Something is using the deprecated function normalizeToast(). Please use createNewToast() instead.")
|
console.warn('Something is using the deprecated function normalizeToast(). Please use createNewToast() instead.');
|
||||||
$('#generalToast').removeClass('text-bg-primary');
|
$('#generalToast').removeClass('text-bg-primary');
|
||||||
$('#generalToast').removeClass('text-bg-success');
|
$('#generalToast').removeClass('text-bg-success');
|
||||||
$('#generalToast').removeClass('text-bg-danger');
|
$('#generalToast').removeClass('text-bg-danger');
|
||||||
|
Loading…
Reference in New Issue
Block a user