Message Bar

Message bars are nonmodal semantic dialogs that can be displayed at the top of the page or contextually within a task flow.

Status

PublishedElement can be used in production
PublishedElement can be used in production
Angular
Angular
PublishedElement can be used in production
React
React
In backlogElement is in backlog
Documentation
PublishedElement can be used in production

What's new

The message bar component was previously named “Informational Alert” and was featured in the “Notifications" section of DDS v1. This component has been completely redesigned and now includes semantic background colors and icons, as well as link and text styling that matches the updated font ramp and color palette. Additionally, a timer is included as an optional feature to allow an auto-dismiss behavior.

When to use

ComponentUse cases
Message barGlobal message bars display nonmodal messages that inform users of updates or changes to system status. Contextual message bars are most often used in task flows and forms, providing users additional context or information about a task. Either can be used for critical system alerts or passive feedback.
NotificationA notification is a nonmodal, passive dialog that keeps users informed without blocking access to the base page. The user can continue with the experience, regardless if the notification is still on screen. Use for interactions that aren’t critical.
ModalModals display important information that users need to acknowledge before moving ahead. They appear over the interface and block further interactions on the base page until an action is completed. Use in cases where a user’s action is critical.

Anatomy

Message bars can consist of seven primary elements. The only elements that are required are the message background and body text.

  1. Message background: color-coded, depending on the semantic context.
  2. Icon: optional visual representation of the semantic type of message.
  3. Body text: content that relays the intent of the message.
  4. Link: optional link to provide more context or prompt user action.
  5. Timer: optional countdown that auto-dismisses the message. It is not intended for use with messages that include actions, warnings, errors, or critical information.
  6. Dismiss icon: optional icon to close the message.
  7. Elevation: for global message bars only, shadow-bottom/elevation-2 effect is applied.

Articles

Indicators, validations, and notifications

Read the Nielsen Norman Group's article on notifications.

Feedback