bitwarden-estensione-browser/libs/components/src/async-actions/overview.stories.mdx

27 lines
917 B
Plaintext

import { Meta } from "@storybook/addon-docs";
<Meta title="Component Library/Async Actions/Overview" />
# Async Actions
The directives in this module makes it easier for developers to reflect the progress of async
actions in the UI when using buttons, while also providing robust and standardized error handling.
These buttons can either be standalone (such as Refresh buttons), submit buttons for forms or as
standalone buttons that are part of a form (such as Delete buttons).
These directives are meant to replace the older `appApiAction` directive, providing the option to
use `observables` and reduce clutter inside our view `components`.
## When to use?
When building a button that triggers a long running task in the background eg. server API calls.
## Why?
To better visualize that the application is processing their request.
## What does it do?
It disables buttons and show a spinning animation.