Skeleton
A pulse-animated loading placeholder. Compose a named region with decorative bones sized by CSS lengths.
Show codeHide code
Installation
import { Skeleton, SkeletonItem } from "@makeplane/propel/components/skeleton";Usage
import { Skeleton, SkeletonItem } from "@makeplane/propel/components/skeleton";
export default function BasicDemo() {
return (
<div className="w-80">
<Skeleton aria-label="Loading">
<SkeletonItem blockSize="40px" />
<SkeletonItem blockSize="40px" inlineSize="60%" />
</Skeleton>
</div>
);
}Examples
Stretch
stretch="full" (the default) takes the parent’s inline size; stretch="auto" fits the region to its widest sized bone. A bone is full width unless you pass inlineSize for a percentage or fixed length.
Show codeHide code
Layout
layout="stack" (the default) is a column; layout="row" places bones on one line.
Show codeHide code
Circle
variant="circle" is a disc. A lone blockSize is the diameter.
Show codeHide code
Fill slot
Size the region with blockSize and omit size on the item so the bone fills the slot. In a region without a blockSize, an unsized bone is one text line tall rather than invisible.
Show codeHide code
API Reference
Skeleton
A pulse-animated loading region that groups placeholder bones. Grafts role="status" onto the
styled elements Skeleton and requires an aria-label so the region is never unnamed. Compose
SkeletonItem children for the bones.
layout and stretch own the region's flex axis and inline size. Exact geometry uses
blockSize / inlineSize (not height / width).
SkeletonItem
One decorative placeholder bone. variant="bar" (default) is a rounded-md block;
variant="circle" is a disc. Full width unless inlineSize narrows it. Bakes aria-hidden —
the enclosing Skeleton names the loading region.