Build your personal knowledge base with Trilium Notes
TypeScript electronelectron-appknowledge-baseknowledge-graphknowledge-managementknowledge-management-graphlocal-firstnote-managmentnote-takernote-takingnotebooknotesnotes-apppersonal-knowledge-basepersonal-wikiscriptableself-hostedself-hostingwiki
fix(toast): add fallback if icon doesn't start with bx-
Elian Doraneb8f2021cbdb
diff --git a/apps/client/src/widgets/Toast.tsx b/apps/client/src/widgets/Toast.tsxindex 643cad551b..02ed6d3971 100644--- a/apps/client/src/widgets/Toast.tsx+++ b/apps/client/src/widgets/Toast.tsx@@ -26,7 +26,7 @@ function Toast({ id, title, autohide, delay, progress, message, icon }: ToastOpt}, [ autohide, id, delay ]);const closeButton = <button type="button" class="btn-close" data-bs-dismiss="toast" aria-label="Close" />;- const toastIcon = <Icon icon={icon} />;+ const toastIcon = <Icon icon={icon.startsWith("bx ") ? icon : `bx bx-${icon}`} />;return (<div