Components
Skeleton
A decorative placeholder shaped like the content that is loading.
Ombelle · light
Loading
Installation
Run in a project initialized with an Ombelle preset (see Get started). The component uses the saved project preset. Run the command from your app folder; it shows the changes and asks before writing.
pnpm dlx @ombelle-ui/cli@1.1.2 add skeletonAdds components/ui/skeleton.tsx and installs react, clsx, tailwind-merge with lifecycle scripts disabled.
In a liquid glass project the plan adds a notice that accessibility is not guaranteed, because text contrast depends on the background behind the glass.
Usage
example.tsx
import { Skeleton } from '@/components/ui/skeleton'
export function LoadingProject() {
return (
<div aria-busy="true" aria-label="Loading project">
<Skeleton shape="circle" />
<Skeleton style={{ inlineSize: '60%' }} />
<Skeleton />
</div>
)
}API and states
- API
- shape (text, circle, block), className, style
- Minimum states
- Pulsing, static under reduced motion
- Native basis
- <div aria-hidden> inside a region marked aria-busy
- Styles
- Stable in Ombelle, Papier, Organic, Retro futurism, minimalist, neo-brutalism and flat, light and dark. Liquid glass: stable, accessibility not guaranteed.