Skip to content

Spinner

Used to provide a visual cue that an action is processing.

// Import component
import { Spinner } from '@fintech-sandpit/ui/react';
// Import styles (optional)
import '@fintech-sandpit/ui/style/components/spinner.css';
return (
<Spinner
colorScheme="success"
size="lg"
variant="dual-ring"
/>
);
NameTypeDefaultDescription
variantSpinnerVariantringSpinner variant
sizeSpinnerSizemdSpinner size
colorSchemeColorScheme—Spinner color scheme 1
boxSizeCssUnit—Spinner box size 2
thicknessCssUnit—Spinner thickness 3
  1. If not provided, the spinner will inherit the text color of its parent element.
  2. If provided, the size prop will be ignored.
  3. Makes sense only if boxSize is provided.
export type SpinnerColorScheme = 'primary' | 'secondary' | 'success' | 'danger' | 'warning'
export type SpinnerSize = 'sm' | 'md' | 'lg'
export type SpinnerVariant = 'ring' | 'dual-ring'
export type CssUnit = `${number}${'px' | 'em' | 'rem' | 'vw' | 'vh' | 'vmin' | 'vmax' | '%'}`