Introduction
Components
- Accordion
- Action Sheet
- Alert
- Audio Player
- Audio Recorder
- Audio Waveform
- Avatar
- AvoidKeyboard
- Badge
- BottomSheet
- Button
- Camera
- Camera Preview
- Card
- Carousel
- Checkbox
- Collapsible
- Color Picker
- Combobox
- Date Picker
- File Picker
- Gallery
- Hello Wave
- Icon
- Image
- Input
- Input OTP
- Link
- MediaPicker
- Mode Toggle
- Onboarding
- ParallaxScrollView
- Picker
- Popover
- Progress
- Radio
- ScrollView
- SearchBar
- Separator
- Share
- Sheet
- Skeleton
- Spinner
- Switch
- Table
- Tabs
- Text
- Toast
- Toggle
- Video
- View
Charts
Installation
pnpm dlx bna-ui add skeleton
Usage
import { Skeleton } from '@/components/ui/skeleton';
<Skeleton width={200} height={20} />
Examples
Default
Different Sizes
Card Layout
Profile Layout
List Items
Custom Shapes
API Reference
Skeleton
A loading placeholder component with animated pulsing effect.
Prop | Type | Default | Description |
---|---|---|---|
width | number | string | 100% | The width of the skeleton. |
height | number | 100 | The height of the skeleton in pixels. |
style | ViewStyle | - | Additional styles to apply to the skeleton. |
Accessibility
The Skeleton component is built with accessibility in mind:
- Uses appropriate color contrast for loading states
- Provides visual feedback during content loading
- Maintains layout stability while content loads
- Compatible with screen readers through proper semantic structure