ion-spinner
The Spinner component provides a variety of animated SVG spinners. Spinners are visual indicators that the app is loading content or performing another process that the user needs to wait on.
Basic Usageâ
The default spinner is based on the mode. When the mode is ios
the spinner will be "lines"
, and when the mode is md
the spinner will be "circular"
. If the name
property is set, then that spinner will be used instead of the mode specific spinner.
Themingâ
Colorsâ
Stylingâ
You may use custom CSS to style the spinner. For example, you can resize the spinner by setting the width and height.
CSS Custom Propertiesâ
Propertiesâ
colorâ
Description | The color to use from your application's color palette. Default options are: "primary" , "secondary" , "tertiary" , "success" , "warning" , "danger" , "light" , "medium" , and "dark" . For more information on colors, see theming. |
Attribute | color |
Type | "danger" īŊ "dark" īŊ "light" īŊ "medium" īŊ "primary" īŊ "secondary" īŊ "success" īŊ "tertiary" īŊ "warning" īŊ string īŊ undefined |
Default | undefined |
durationâ
Description | Duration of the spinner animation in milliseconds. The default varies based on the spinner. |
Attribute | duration |
Type | number īŊ undefined |
Default | undefined |
nameâ
Description | The name of the SVG spinner to use. If a name is not provided, the platform's default spinner will be used. |
Attribute | name |
Type | "bubbles" īŊ "circles" īŊ "circular" īŊ "crescent" īŊ "dots" īŊ "lines" īŊ "lines-sharp" īŊ "lines-sharp-small" īŊ "lines-small" īŊ undefined |
Default | undefined |
pausedâ
Description | If true , the spinner's animation will be paused. |
Attribute | paused |
Type | boolean |
Default | false |
Eventsâ
No events available for this component.
Methodsâ
No public methods available for this component.
CSS Shadow Partsâ
No CSS shadow parts available for this component.
CSS Custom Propertiesâ
Name | Description |
---|---|
--color | Color of the spinner |
Slotsâ
No slots available for this component.