BridgeBeta
  • Brand
  • Digital Assets
    Foundations
    Icons
    Components
    Templates
  • Resources
    Design Tokens
    How-tos
    Best Practices
    Libraries
    Accessibility
    Products List
  • Support
    • Overview
    • Actions
      • Overview
      • Button
      • ContextMenu
      • Link
    • Controls
      • Overview
      • Checkbox
      • Tag
      • Toggle
    • Forms
      • Overview
      • DatePicker
      • FileUploader
      • Input
      • NumberInput
      • RadioButton
      • Search
      • Select
      • Slider
      • TextArea
      • TextInput
    • Hooks
      • useIsomorphicLayoutEffect
      • useMediaQuery
      • useSettings
    • Navigation
      • Overview
      • AnchorNavigation
      • BannerNavigation
      • Breadcrumb
      • Footer
      • InfoBar
      • MainNavigation
      • SecondaryNavigation
      • StepNavigation
      • SubNavigation
    • Overlay
      • Overview
      • Credits
      • Modal
      • ModalWrapper
      • Notification
      • Tooltip
    • Structure
      • Overview
      • Accordion
      • AuthLayout
      • Avatar
      • Callout
      • Card
      • ContentSwitcher
      • Empty
      • Hero
      • InlineLoading
      • Item
      • List
      • Loading
      • mdxComponents
      • Module
      • Pagination
      • ReadMore
      • Story
      • Table
      • Tabs
      • Text
      • Unit
      • User
      • WFPCoreProvider
      • Wrapper
Components
Overlay
Notification

Notification

  • Design
  • Code
  • Props

Notifications provide information about status changes, errors, or other important information that requires user attention.

Import statement

import { ToastNotification, NotificationButton, NotificationActionButton, NotificationTextDetails } from "@wfp/react"

Usage ToastNotification

Editable Example

<ToastNotification
  kind="info"
  role="alert"
  title="Notification title"
  subtitle="Subtitle text goes here."
  iconDescription="describes the close button"
  statusIconDescription="describes the status icon"
  hideCloseButton={false}
  caption="00:00:00 AM"
  style={{ minWidth: "30rem", marginBottom: ".5rem" }}
/>;

Example Types

Expand code

Editable Example

<>
  <ToastNotification
    role="alert"
    title="Notification title"
    subtitle="Subtitle text goes here."
    iconDescription="describes the close button"
    statusIconDescription="describes the status icon"
    hideCloseButton={false}
    caption="00:00:00 AM"
    kind="success"
    style={{
      minWidth: "30rem",
      marginBottom: ".5rem",
    }}
  />
  <ToastNotification
    role="alert"
    title="Notification title"
    subtitle="Subtitle text goes here."
    iconDescription="describes the close button"
    statusIconDescription="describes the status icon"
    hideCloseButton={false}
    caption="00:00:00 AM"
    kind="error"
    style={{
      minWidth: "30rem",
      marginBottom: ".5rem",
    }}
  />
  <ToastNotification
    role="alert"
    title="Notification title"
    subtitle="Subtitle text goes here."
    iconDescription="describes the close button"
    statusIconDescription="describes the status icon"
    hideCloseButton={false}
    caption="00:00:00 AM"
    kind="warning"
    style={{
      minWidth: "30rem",
      marginBottom: ".5rem",
    }}
  />
  <ToastNotification
    kind="info"
    role="alert"
    title="Notification title"
    subtitle="Subtitle text goes here."
    iconDescription="describes the close button"
    statusIconDescription="describes the status icon"
    hideCloseButton={false}
    caption="00:00:00 AM"
    style={{
      minWidth: "30rem",
      marginBottom: ".5rem",
    }}
  />
</>;

On this page

  • Usage ToastNotification
  • Example Types

References

  • Storybook
Storybook
Figma library
Contact us
2025 © World Food Programme