fix: alerts being completely broken
Docker Image CI / build-and-push-image (push) Waiting to run
Maintain Release Merge PR / update-release-pr (push) Waiting to run
release-please / release-please (push) Waiting to run
test / test (18.x) (push) Waiting to run
test / test (20.x) (push) Waiting to run
test / test (22.x) (push) Waiting to run

PR 1175 introduced a bug that wasn't caught where alert messages are not
properly assigned. Additionally, the default alert type was "warning"
which is a regression. This commit makes "info" the default alert type
and ensures options.message is the first candidate for the alert message
contents.
This commit is contained in:
KernelDeimos
2025-03-19 12:37:18 -04:00
parent 5c3f447b4c
commit 33a7811e8f
+2 -2
View File
@@ -50,8 +50,8 @@ function UIAlert(options) {
};
// Set default values
const alertType = alertTypes[options.type] || alertTypes.warning;
options.message = options.title || alertType.title;
const alertType = alertTypes[options.type] || alertTypes.info;
options.message = options.message || options.title || alertType.title;
options.body_icon = options.body_icon ?? window.icons[alertType.icon];
options.color = options.color ?? alertType.color;