Skip to content

Commit

Permalink
formatting, typo fix
Browse files Browse the repository at this point in the history
  • Loading branch information
Simek committed Apr 16, 2020
1 parent 23079dc commit 03ba1ec
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 4 deletions.
4 changes: 2 additions & 2 deletions docs/dynamiccolorios.md
Original file line number Diff line number Diff line change
Expand Up @@ -9,11 +9,11 @@ The `DynamicColorIOS` function is a platform color type specific to iOS.
DynamicColorIOS({light: color, dark: color});
```

`DynamicColorIOS` takes a single argument as an object with two keys: `light` and `dark`. These correspond to the colors you want to use for "light mode" and "dark mode".
`DynamicColorIOS` takes a single argument as an object with two keys: `dark` and `light`. These correspond to the colors you want to use for "light mode" and "dark mode" on iOS.

> In the future, more keys might become available for different user preferences, like high contrast.
At runtime, the system will chose which of the two colors to display depending on the current system appearance settings. Dynamic colors are useful for branding colors or other app specific colors that still respond automatically to system setting changes.
At runtime, the system will choose which of the two colors to display depending on the current system appearance settings. Dynamic colors are useful for branding colors or other app specific colors that still respond automatically to system setting changes.

<div class="toggler">
<span>Developer Notes</span>
Expand Down
4 changes: 2 additions & 2 deletions docs/platformcolor.md
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@ id: platformcolor
title: PlatformColor
---

```
```js
PlatformColor(color1, [color2, ...colorN])
```

Expand Down Expand Up @@ -56,4 +56,4 @@ const styles = StyleSheet.create({

The string value provided to the `PlatformColor` function must match and agree with the same string as it exists on the native platform the app is being run on. This means to avoid runtime errors the function should be wrapped in a platform check, either through a `Platform.OS === 'platform'` or a `Platform.Select()`.

You can find a complete example that demonstrates proper, intended use of PlatformColor in [PlatformColorExample.js](https://github.com/facebook/react-native/blob/master/RNTester/js/examples/PlatformColor/PlatformColorExample.js).
> **Note:** You can find a complete example that demonstrates proper, intended use of `PlatformColor` in [PlatformColorExample.js](https://github.com/facebook/react-native/blob/master/RNTester/js/examples/PlatformColor/PlatformColorExample.js).

0 comments on commit 03ba1ec

Please sign in to comment.