Props
| Prop | Type | Default |
|---|---|---|
| value / defaultValue / onChangeText Controlled or uncontrolled query; clear and cancel report ''. | string | — |
| placeholder Placeholder, also the field's accessibility label. | string | labels.search |
| onSubmit Called with the query when the keyboard's search key is pressed. | (text: string) => void | — |
| showCancel A glass cancel button springs in beside the pill while focused or holding text. | boolean | false |
| cancelLabel Text for the cancel button, e.g. "Cancel"; without it the button is a round ✕. | string | — (round ✕) |
| onCancel After cancel clears the query and dismisses the keyboard. | () => void | — |
| leading Replaces the magnifier at the start of the pill. | ReactNode | magnifier |
| trailing Inside the pill at the end, e.g. a mic button. | ReactNode | — |
| autoFocus Focus the field on mount. | boolean | false |
| scheme Force light or dark glass and ink, e.g. 'dark' over a photo. | 'light' | 'dark' | kit theme |
| size 44 / 52pt tall; font, icons and padding scale too. | 'md' | 'lg' | 'md' |
| style Row holding the pill and the cancel button. | StyleProp<ViewStyle> | — |
| className Tailwind classes on the root when using NativeWind or Uniwind. Prefer style for StyleSheet overrides. | string | — |
| …TextInputProps editable, returnKeyType, onFocus, onBlur, onSubmitEditing, … (ref forwards to the TextInput). |
Behaviour & accessibility
- Motion
- The pill swells a touch on focus and a clear button pops in once there is text. With showCancel, a glass cancel button springs in beside it while searching.
- Reduced motion
- The pill no longer swells, and the clear and cancel buttons fade in with a short timing instead of a spring.
- Keyboard
- The return key reads Search and calls onSubmit with the query. Cancel clears the text and dismisses the keyboard.
- Screen readers
- The field has the search role and is labelled by its placeholder. The clear and cancel buttons read "Clear search" and cancelLabel (or "Cancel search").
- Platforms
- Real Liquid Glass on iOS 26, where the pill and cancel button melt together. Blur or frosted glass everywhere else.
Source
FAQ
How do I make a liquid glass search bar in React Native?
Does Glass Search Bar work in Expo Go?
expo-glass-effect, expo-blur, react-native-svg) are all included in Expo Go.How do I add Glass Search Bar to my Expo app?
expo-glass-effect, expo-blur, react-native-svg, so the code is yours to change. The install command is on this page for Pro members.Is Glass Search Bar free?
npx @expokit/cli@latest login) and it installs the full source into your app.