Skip to content

v1.0.2 — cross-platform Button fixes

Choose a tag to compare

@0xNeit 0xNeit released this 19 May 15:38
· 95 commits to main since this release
bb72880

A patch release: the cross-platform Button fixes from #22. Every package ships at 1.0.2.

Merged via #23.

Fixed

  • Native Button crashed on text labels. A string or number label rendered bare inside <Pressable> threw React Native's "Text strings must be rendered within a <Text> component". String / number labels are now wrapped in <Text>; element children pass through unchanged. (#22)
  • Native Button label styles were unwired. The label's text styles (color, fontSize, fontWeight) were spread onto the <Pressable>, where React Native silently drops text-style props on a View. They now land on the label <Text>. (#22)
  • Button intent="neutral" assumed a gray token scale. Both renderers referenced $colors.gray.*, which only @usemotif/tokens guarantees — a hand-authored createTheme theme need not define one. Button now falls back to literal greys when the active theme defines no gray scale. (#22)