Search
MaterialComponentsDocs
Components overviewApp barBadgeButtonsButton groupButtonExtended FABFAB menuFABIcon buttonSplit buttonCardCarouselCheckboxChipsDate & time pickersDate pickerTime pickerDialogDividerListLoading & progressLoading indicatorProgressMenuNavigationNavigation barNavigation drawerNavigation railRadio buttonsSearchSelectSheetsBottom sheetSide sheetSliderSnackbarSwitchTabsText fieldToolbarTooltip

Snackbar

Confirm an action without interrupting. Show a message, offer an undo, and try dismissal behavior.

FactoryWeb ComponentsReactVueSvelteSolidJS

Accessibility

  • A status live region: its message is announced politely, and focus is not moved to it.
  • Pressing focusShortcut (F8 by default, with no modifiers held; stamped on the action button as aria-keyshortcuts) moves focus to an actionable snackbar's action button, pauses the auto-dismiss timer while focus stays inside (focusin / focusout), and restores focus on close() to the element that had focus when the key was pressed. On macOS the platform may require the Fn key: press Fn+F8 unless function keys are set as standard keys.
  • Escape closes it while focus is inside it. If focus was inside when it closed, it goes back where it came from.
  • Its countdown pauses while the pointer is over it or focus is inside it. With an action, it stays until it is used or dismissed.
  • The close button is named by closeLabel.