Search code examples
androidreact-native

How to set elevation color?


We have the proptype elevationin react-native (doc), but how can I set the color of the "android-shadow" it's producing?


Solution

  • Unfortunately, the color of the shadow produced by Android's setElevation cannot be changed. Also, their Material Design guidelines around the web like here don't seem to indicate that you can change the color.

    https://developer.android.com/training/material/shadows-clipping.html

    In addition, box shadows in React Native are also not supported on Android, based on this.