Skip to content

Components

Import every component from starlight-warcraft/react. Each one passes the usual HTML attributes through to its element, and appends your className after its own.

<Button>Accept quest</Button>
<Button variant="frame" size="sm">Small frame</Button>
<Button asChild>
<a href="/start/">A link styled as a button</a>
</Button>
Prop Values Default
variant "default", "frame" "default"
size "default", "sm" "default"
asChild boolean false

asChild styles the only child (a link, say) instead of rendering a button.

The Old Road
Recommended level 12
Follow the road east to the watchtower and report to the captain.
Small card
size=“sm”
A thinner frame and tighter spacing.
<Card>
<CardHeader>
<CardTitle>The Old Road</CardTitle>
<CardDescription>Recommended level 12</CardDescription>
</CardHeader>
<CardContent>Follow the road east to the watchtower.</CardContent>
<CardFooter>
<Button size="sm">Accept</Button>
</CardFooter>
</Card>

Card takes size: "default" or "sm". CardHeader, CardTitle, CardDescription, CardContent and CardFooter are plain divs with the matching class.

DefaultSecondaryDestructiveOutlineShield

Banner

Small
Prop Values Default
variant "default", "secondary", "destructive", "outline" "default"
size "default", "sm", "lg" "default"
shape "default", "shield", "banner" "default"
<Input placeholder="Search the archives" />

A tooltip-style panel with an item-quality border.

Common
Uncommon
Rare
Epic
Legendary
<Panel quality="epic">Epic</Panel>

quality is "common" (the default), "uncommon", "rare", "epic" or "legendary". panelClassName(quality) returns the same classes for elements you render yourself, such as a hover card.

The card that HoverCards shows when you hover a name in a checked Luau code block, or a link you give it a source for. Its quality picks the border, and error turns the title red.

<HoverCard card={{ title: "CreateFrame", kind: "Function · typed", body: "CreateFrame(frameType: string): Frame", quality: "rare" }} />

Mount <HoverCards client:idle /> once per page to show these on hover. Pass sources for your own anchors.

An unofficial community project. World of Warcraft and Blizzard Entertainment are trademarks of Blizzard Entertainment, Inc.; this site is not affiliated with or endorsed by Blizzard. Code under the MIT licence.

<Disclaimer licence="Code under the MIT licence." />
<Skeleton style={{ height: "4rem" }} />
<Spinner aria-label="Searching" />

The spinner has role="status" and the label “Loading” unless you pass aria-label. It stops animating when the reader prefers reduced motion.