mirror of
https://github.com/TriliumNext/Trilium.git
synced 2025-12-10 03:53:37 -06:00
fix(toast): add fallback if icon doesn't start with bx-
This commit is contained in:
parent
888ff33be1
commit
eb8f2021cb
@ -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
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user