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
chore(toast): fix button alignment if no title & make buttons full-width
Elian Doran055dd9cd01eb
diff --git a/apps/client/src/widgets/Toast.tsx b/apps/client/src/widgets/Toast.tsxindex f0321345a2..c251b900a3 100644--- a/apps/client/src/widgets/Toast.tsx+++ b/apps/client/src/widgets/Toast.tsx@@ -42,21 +42,24 @@ function Toast({ id, title, timeout, progress, message, icon, buttons }: ToastOpid={`toast-${id}`}>{title ? (- <div class="toast-header">- <strong class="me-auto">- {toastIcon}- <span class="toast-title">{title}</span>- </strong>- {closeButton}- </div>+ <>+ <div class="toast-header">+ <strong class="me-auto">+ {toastIcon}+ <span class="toast-title">{title}</span>+ </strong>+ {closeButton}+ </div>+ <div className="toast-body">{message}</div>+ </>) : (- <div class="toast-icon">{toastIcon}</div>+ <div class="toast-main-row">+ <div class="toast-icon">{toastIcon}</div>+ <div className="toast-body">{message}</div>+ <div class="toast-close">{closeButton}</div>+ </div>)}- <div className="toast-body">{message}</div>-- {!title && <div class="toast-header">{closeButton}</div>}-{buttons && (<div class="toast-buttons">{buttons.map(({ text, onClick }) => (