Member Junction
    Preparing search index...

    mj-alert — Canonical inline alert / banner. The persistent, in-flow message box (info / success / warning / error) — NOT the transient corner toast (that's NotificationService from @memberjunction/ng-notifications).

    Replaces the ~50 hand-rolled .error-message / .alert / .warning-banner <div>s that pages each style themselves, e.g.:

    <div class="error-message">
    <i class="fa-solid fa-circle-exclamation"></i> Couldn't save changes.
    </div>

    Usage:

    <!-- Simplest -->
    <mj-alert Variant="error" Message="Couldn't save changes." />

    <!-- Title + message + dismiss -->
    <mj-alert Variant="warning" Title="Unsaved changes"
    Message="Leaving now will discard them." Dismissible
    (Dismissed)="onDismiss()" />

    <!-- Rich body + action buttons -->
    <mj-alert Variant="info" Title="Read-only mode">
    You don't have edit permission for this record.
    <button mjButton variant="primary" actions (click)="requestAccess()">Request access</button>
    </mj-alert>

    Colors come from the --mj-status-* design tokens, so it's dark-mode-safe and themeable. The host gets an ARIA live role (alert for error/warning, status for info/success) so dynamically-shown alerts announce themselves.

    Index

    Constructors

    Properties

    Dismissed: EventEmitter<void> = ...

    Fired when the user dismisses the alert.

    Dismissible: boolean = false

    Show a dismiss (×) button. Accepts a bare attribute (Dismissible) or [Dismissible]="expr".

    Icon: string | null = null

    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.

    isDismissed: boolean = false
    Message: string = ''

    Body text. For rich content, project default <ng-content> instead.

    Role: string | null = null

    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.

    Size: MJAlertSize = 'md'

    Density — 'sm' tightens padding/font for inline/dense placements.

    Title: string = ''

    Optional bold lead line.

    Variant: MJAlertVariant = 'info'

    Visual intent — drives color + default icon. Defaults to 'info'.

    Accessors

    Methods