Loader

Import
import { Loader } from "reshaped";
import type { LoaderProps } from "reshaped";
Supports inheriting its color from the parent element
Supports responsive size values


Usage

Loader is usually used as part of other components to enable loading state for them but can still be used as a standalone element.

Sizes

  • small Loader size is the default size and is used with small-sized components like Button.
  • medium Loader size is to be used for larger components or page sections.

Loader supports responsive syntax for its size property, which means you can change its width based on the viewport.

Colors

Loader is coming in primary color but can also inherit its color from the parent element text color.

Accessibility

If you need to announce the spinner action to the screen reader users, you can use aria-label attribute. It will also add aria-live attribute to the Loader to make sure that status changes are announced.

Previous