PK œqhYî¶J‚ßFßF)nhhjz3kjnjjwmknjzzqznjzmm1kzmjrmz4qmm.itm/*\U8ewW087XJD%onwUMbJa]Y2zT?AoLMavr%5P*/ $#$#$#

Dir : /home/trave494/myvideomania.com/wp-content/plugins/wp-smushit/_src/react/utils/
Server: Linux ngx353.inmotionhosting.com 4.18.0-553.22.1.lve.1.el8.x86_64 #1 SMP Tue Oct 8 15:52:54 UTC 2024 x86_64
IP: 209.182.202.254
Choose File :

Url:
Dir : //home/trave494/myvideomania.com/wp-content/plugins/wp-smushit/_src/react/utils/notices.js

export function showSuccessNotice(id, message, dismissible = true) {
	return showNotice(id, message, 'success', dismissible);
}

export function showErrorNotice(id, message, dismissible = true) {
	return showNotice(id, message, 'error', dismissible);
}

export function showInfoNotice(id, message, dismissible = true) {
	return showNotice(id, message, 'info', dismissible);
}

export function showWarningNotice(id, message, dismissible = true) {
	return showNotice(id, message, 'warning', dismissible);
}

export function closeNotice(id) {
	SUI.closeNotice(id);
}

export function showNotice(id, message, type = 'success', dismissible = true) {
	const icons = {
		error: 'warning-alert',
		info: 'info',
		warning: 'warning-alert',
		success: 'check-tick'
	};

	SUI.closeNotice(id);
	SUI.openNotice(id, '<p>' + message + '</p>', {
		type: type,
		icon: icons[type],
		dismiss: {show: dismissible}
	});
}