Spin
Used for the loading status of a page or a block.
When to use
When part of the page is waiting for asynchronous data or during a rendering process, an appropriate loading animation can effectively alleviate users' inquietude.
Examples
API
Spin are exported from @ceebee/ui/client.
Spin
| Property | Description | Type | Default | Version |
|---|---|---|---|---|
classNames | Customize class for each semantic structure inside the component. Supports object or function. | Record<SemanticDOM, string> | (info: { props }) => Record<SemanticDOM, string> | - | — |
delay | Specifies a delay in milliseconds for loading state (prevent flush) | number (milliseconds) | - | — |
description | Customize description content | ReactNode | - | 6.3.0 |
fullscreen | Display a backdrop with the Spin component | boolean | false | 5.11.0 |
indicator | React node of the spinning indicator | ReactNode | - | — |
percent | The progress percentage, when set to auto, it will be an indeterminate progress | number | 'auto' | - | 5.18.0 |
size | The size of Spin, options: small, medium and large | string | medium | — |
spinning | Whether Spin is visible | boolean | true | — |
styles | Customize inline style for each semantic structure inside the component. Supports object or function. | Record<SemanticDOM, CSSProperties> | (info: { props }) => Record<SemanticDOM, CSSProperties> | - | — |
tip | Customize description content when Spin has children. Deprecated, use description instead | ReactNode | - | — |
wrapperClassName | The className of wrapper when Spin has children. Deprecated, use classNames.root instead | string | - | — |