@porsche-design-system/components-react
Version:
Porsche Design System is a component library designed to help developers create the best experience for software or services distributed by Dr. Ing. h.c. F. Porsche AG.
35 lines (34 loc) • 2 kB
TypeScript
import type { BaseProps } from '../../BaseProps';
import type { SelectedAriaAttributes, SpinnerAriaAttribute, SpinnerColor, BreakpointCustomizable, SpinnerSize } from '../types';
export type PSpinnerProps = BaseProps & {
/**
* Sets ARIA attributes on the spinner's live region element; use `aria-label` to provide a descriptive loading message for screen readers.
*/
aria?: SelectedAriaAttributes<SpinnerAriaAttribute>;
/**
* Sets the color of the spinning indicator using PDS semantic color tokens (e.g. `primary`, `contrast-high`, `inherit`).
* @default 'primary'
*/
color?: SpinnerColor;
/**
* Sets the size of the spinner using the PDS typographic scale. Use `inherit` to derive the size from the parent element's font-size. Supports responsive breakpoint values.
* @default 'sm'
*/
size?: BreakpointCustomizable<SpinnerSize>;
};
export declare const PSpinner: import("react").ForwardRefExoticComponent<Omit<import("react").DOMAttributes<{}>, "onChange" | "onInput" | "onToggle"> & Pick<import("react").HTMLAttributes<{}>, "suppressHydrationWarning" | "autoFocus" | "className" | "dir" | "hidden" | "id" | "inert" | "inputMode" | "lang" | "slot" | "style" | "tabIndex" | "title" | "translate" | "role"> & {
/**
* Sets ARIA attributes on the spinner's live region element; use `aria-label` to provide a descriptive loading message for screen readers.
*/
aria?: SelectedAriaAttributes<SpinnerAriaAttribute>;
/**
* Sets the color of the spinning indicator using PDS semantic color tokens (e.g. `primary`, `contrast-high`, `inherit`).
* @default 'primary'
*/
color?: SpinnerColor;
/**
* Sets the size of the spinner using the PDS typographic scale. Use `inherit` to derive the size from the parent element's font-size. Supports responsive breakpoint values.
* @default 'sm'
*/
size?: BreakpointCustomizable<SpinnerSize>;
} & import("react").RefAttributes<HTMLElement>>;