SnakeLoader
Loading animation inspired by terminals with Unicode block characters.
SnakeLoader
Design lines
Decoding...
█▄█▄█▄█▄█▄█▄█▄█▄█▄█▄█▄█▄█▄█▄█▄█▄
vue
1<Tabs defaultValue="tuix">2 <TabsList>3 <Tab value="tuix">TUIX</Tab>4 <Tab value="rubik">Rubik</Tab>5 </TabsList>6 <TabPanel value="tuix">7 <SnakeLoader design="tuix" />8 </TabPanel>9 <TabPanel value="rubik">10 <SnakeLoader design="rubik" />11 </TabPanel>12</Tabs>Demo
Basic (progress)
Basic loader with different colors and speeds around the default slot text.
Primary
█▄█▄█▄█▄█▄█▄█▄█▄█▄█▄█▄█▄█▄█▄█▄█▄
Secondary
█▄█▄█▄█▄█▄█▄█▄█▄█▄█▄█▄█▄█▄█▄█▄█▄
Success
█▄█▄█▄█▄█▄█▄█▄█▄█▄█▄█▄█▄█▄█▄█▄█▄
vue
1<SnakeLoader speed="1.2s" color="primary">Loading...</SnakeLoader>2<SnakeLoader speed="0.8s" color="secondary">Secondary</SnakeLoader>3<SnakeLoader speed="1.4s" color="success">Success</SnakeLoader>Speed (speed)
Overrides the CSS animation duration through the speed prop.
Fast
█▄█▄█▄█▄█▄█▄█▄█▄█▄█▄█▄█▄█▄█▄█▄█▄
Normal
█▄█▄█▄█▄█▄█▄█▄█▄█▄█▄█▄█▄█▄█▄█▄█▄
Slow
█▄█▄█▄█▄█▄█▄█▄█▄█▄█▄█▄█▄█▄█▄█▄█▄
vue
1<SnakeLoader speed="0.6s" color="primary">Fast</SnakeLoader>2<SnakeLoader speed="1.2s" color="primary">Normal</SnakeLoader>3<SnakeLoader speed="2s" color="primary">Slow</SnakeLoader>Color (color)
Sets the color of the animated block through the color prop.
P
█▄█▄█▄█▄█▄█▄█▄█▄█▄█▄█▄█▄█▄█▄█▄█▄
S
█▄█▄█▄█▄█▄█▄█▄█▄█▄█▄█▄█▄█▄█▄█▄█▄
W
█▄█▄█▄█▄█▄█▄█▄█▄█▄█▄█▄█▄█▄█▄█▄█▄
D
█▄█▄█▄█▄█▄█▄█▄█▄█▄█▄█▄█▄█▄█▄█▄█▄
vue
1<SnakeLoader color="primary">P</SnakeLoader>2<SnakeLoader color="success">S</SnakeLoader>3<SnakeLoader color="warning">W</SnakeLoader>4<SnakeLoader color="danger">D</SnakeLoader>Props
speed
Duration of the CSS animation.
| Type | Default | Required |
|---|---|---|
string | '1.2s' | ❌ |
color
Color of the animated block.
| Type | Default | Required |
|---|---|---|
'primary' | 'secondary' | 'tertiary' | 'success' | 'warning' | 'danger' | 'light' | 'medium' | 'dark' | 'primary' | ❌ |
design
Design line (or inherit from data-design).
| Type | Default | Required |
|---|---|---|
'tuix' | 'rubik' | — (inherits from data-design) | ❌ |
Slots
| Slot | Description |
|---|---|
default | Text to show next to the animation |
CSS Custom Properties
| Token | Default | Description |
|---|---|---|
--font-mono | "JetBrains Mono", ui-monospace, monospace | Monospace font stack for code-like content (key labels, log lines, chips). |
--accent | from theme (--ctp-latte-mauve / --ctp-mocha-mauve) | Accent color, mapped from the active semantic color. |
--bg-panel | from theme (--ctp-latte-surface1 / --ctp-mocha-surface1) | Background of panel-like raised surfaces (cards, accordions). |
--border | from theme (--ctp-latte-surface0 / --ctp-mocha-surface0) | Outline and divider color for surfaces. |
--text | from theme (--ctp-latte-text / --ctp-mocha-text) | Primary text color used inside the component. |
--text-muted | from theme (--ctp-latte-subtext1 / --ctp-mocha-subtext1) | Secondary text for hints, annotations and disabled state. |
--color-primary | from theme (--ctp-latte-mauve / --ctp-mocha-mauve) | Primary semantic color (mauve in Catppuccin). |
--loader-speed | var(--loader-speed, 1.6s) | Animation speed (one full loop) of the SnakeLoader. |
Ver Theming para la convención completa.