- Modernize the Searchbar to the latest specs: https://m3.material.io/components/search/
- Reuse newly introduced tokens (shape, motion, typography, color etc)
- Extract component specific tokens for easier maintenance.
- Get inspired from TextInput/TextField, Switch, Checkbox, FAB components which have gone through modernization.
Current State
Searchbar
MD3 spec: Search
Specs link: https://m3.material.io/components/search/specs
Color tokens
Spacing / sizing
- Bar height:
minHeight: 56 ✅
- Bar border radius:
7 * roundness = 28dp (corner.extra-large) ✅ for baseline style
- View mode border radius: 0 (
corner.none) ✅ for divided style
- Input font:
bodyLarge (16sp, overrides fontSize: 18 in StyleSheet) ✅
Behavior
Notes
- Should be moved to its own directory
- The
divided style is deprecated in M3 Expressive in favor of contained; mode="view" implements the divided style
- Result grouping with gaps (M3 Expressive) is a consumer-level concern and does not need to be part of the component itself
Current State
Searchbar
MD3 spec: Search
Specs link: https://m3.material.io/components/search/specs
Color tokens
surfaceContainerHigh✅onSurfaceVariant✅onSurfaceVariant✅primary✅onSurfaceVariant; should beonSurfaceonSurface; should beonSurfaceVariant– these two are swapped ❌Spacing / sizing
minHeight: 56✅7 * roundness= 28dp (corner.extra-large) ✅ for baseline stylecorner.none) ✅ for divided stylebodyLarge(16sp, overridesfontSize: 18inStyleSheet) ✅Behavior
rightrender prop ✅mode="bar"maps to divided/baseline style with elevation ✅mode="view"maps to divided search view with bottomDivider✅IconButton+TouchableRipple✅modevalues ("bar"/"view") do not align with M3 spec terminology ("contained"/"divided (baseline)")Notes
dividedstyle is deprecated in M3 Expressive in favor ofcontained;mode="view"implements the divided style