Skip to content
Chat & AI

Loader

Spinning glyph for in-flight generation.

Import

tsx
import { Loader } from "@cronus-ui/ui";
bash
npx cronus-ui add loader

Examples

.cronus

The same component declared in Cronus. Emitted at build time from the audit fixtures — the kernel renders it as HTML with no React.

PortedParity: MatchGeometry 2/2Pixel diff 0 pxLogic 1/1Parity scoreboard
default.cronus
app "audit-fixtures" {
  port 5176
}

style {
  preset aurora
  theme dark
}

component LoaderDefault layout:inline style:loader {
  label "default"
}

page "/audit/loader/default" type:custom {
  use LoaderDefault
}
large.cronus
app "audit-fixtures" {
  port 5176
}

style {
  preset aurora
  theme dark
}

component LoaderLarge layout:inline style:loader {
  size:32
  aria-label:"Saving"
  label "Saving"
}

page "/audit/loader/large" type:custom {
  use LoaderLarge
}

API Reference

Generated from the component's exported types.

LoaderLabels

Skip LoaderLabels props table
PropTypeDefaultDescription
loading*
string——

LoaderProps

Extends HTMLAttributes<HTMLDivElement>

Skip LoaderProps props table
PropTypeDefaultDescription
ref
Ref<HTMLDivElement>—Ref forwarded to the underlying DOM node.
size
number16Pixel size of the spinner glyph.
labels
Partial<LoaderLabels>—Override default English strings.
className
string—Additional class names merged onto the root.
children
ReactNode—Contents of the component.
id
string—DOM id of the root element.