Skip to content

Alert component for errors and notifications #8933

Open
@jldec

Description

@jldec

There are places where the dashboard client uses alert() or console.error().

  • console.error() messages obscure the error instead of alerting the user in a visble way in the UI.
  • alert() is blocking and not stylistically consistent with other dashboard UI.
  • Other scenario-specific notification mechanisms (like [dashboard] display warning for latest IDE versions #8783) are are not suitable for general purpose use.

It would be better to show notifications and errors in a simple, consistent way that does not demand interaction, but nevertheless makes it visible in a clear but non-surprising way.

GitHub uses a banner at the top of the page for notifications and errors. The banner can be dismissed but also disappears automatically after navigating. See also Bootstrap examples here.

Requirements

  • not modal - do not cover or block other interations
  • dismissable
  • allow multiple notifications (ok to overlay, and view one by one)
  • works across admin dashboard, regular dashboard, and start-workspace UI
  • loud (red?) notification for errors
  • less-loud (orange?) notifications for non-error alerts
  • visible on small screens (top of page, not bottom)

Typical use cases

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    Status

    No status

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions