Skip to content

Support arrays in background styles - #2982

Merged
zoontek merged 4 commits into
masterfrom
background-style-array
Nov 27, 2026
Merged

zoontek merged 4 commits into
masterfrom
background-style-array

Conversation

@zoontek

@zoontek zoontek commented Nov 26, 2026

Copy link
Copy Markdown
Collaborator
  • backgroundImage, backgroundPosition, backgroundRepeat, and backgroundSize now accept arrays of objects, like React Native. Strings still work.
  • backgroundImage supports linear-gradient and radial-gradient objects.
  • Multi-value backgroundPosition strings (e.g. left 10px top 20%) no longer log a validation error.

@github-actions

github-actions Bot commented Nov 26, 2026 •

Copy link
Copy Markdown

Size Change: +383 B (+0.39%)

Total Size: 98.2 kB

📦 View Changed
Filename Size Change
packages/react-native-web/dist/exports/StyleSheet/preprocess.js 1.93 kB +388 B (+25.13%) 🚨
packages/react-native-web/dist/exports/StyleSheet/validate.js 610 B -5 B (-0.81%)

compressed-size-action

@zoontek
zoontek requested review from Kudo and hassankhan November 26, 2026 11:12
@zoontek
zoontek merged commit 14c66cc into master Nov 27, 2026
5 checks passed
@zoontek
zoontek deleted the background-style-array branch November 27, 2026 13:51
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants