Chip
Interactive filter, selection, and removable tag chip with selected state and close action.
v0.3.2NativeWindStyleSheetiOSAndroidExpo GoWeb
Preview
Installation
npx nativra-cli add chipWrites Chip.tsx to components/ui, rewrites imports to your aliases and records hashes in nativra.lock.json, along with 1 registry dependency. Existing files are never overwritten without asking.
Want to try it first? Open it in the playground: a real React Native project in your browser, with this item installed by the CLI.
Props
| Prop | Type | Default | Description |
|---|---|---|---|
| label | string | required | Text displayed inside the chip |
| selected | boolean | false | Highlights the chip in active selected state |
| variant | "default" | "primary" | "outline" | "default" | Visual surface style |
| size | "sm" | "md" | "md" | Height and horizontal padding preset |
| onPress | () => void | undefined | Callback fired when chip is tapped |
| onRemove | () => void | undefined | Renders a trailing remove button and fires on press |
Source
Exactly what the CLI writes, before your import aliases are applied.