Fired when the user dismisses the alert.
Show a dismiss (×) button. Accepts a bare attribute (Dismissible) or [Dismissible]="expr".
Font Awesome icon class (e.g. "fa-solid fa-key"). When omitted, a sensible
default is chosen from Variant. Set to '' to render no icon.
ProtectedisBody text. For rich content, project default <ng-content> instead.
ARIA live role on the host. When unset, defaults from Variant:
error/warning → 'alert' (assertive), info/success → 'status'
(polite), so a dynamically-shown alert announces itself. Pass '' to opt out.
Density — 'sm' tightens padding/font for inline/dense placements.
Optional bold lead line.
Visual intent — drives color + default icon. Defaults to 'info'.
Live-region role applied to the host. Explicit Role wins ('' ⇒ no role);
otherwise error/warning are an assertive alert, info/success a polite status.
Icon actually rendered: the explicit Icon when provided (including ""
to suppress the icon), otherwise the per-variant default.
mj-alert — Canonical inline alert / banner. The persistent, in-flow message box (info / success / warning / error) — NOT the transient corner toast (that's
NotificationServicefrom@memberjunction/ng-notifications).Replaces the ~50 hand-rolled
.error-message/.alert/.warning-banner<div>s that pages each style themselves, e.g.:Usage:
Colors come from the
--mj-status-*design tokens, so it's dark-mode-safe and themeable. The host gets an ARIA live role (alertfor error/warning,statusfor info/success) so dynamically-shown alerts announce themselves.