Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
30 changes: 30 additions & 0 deletions docs/view-style-props.md
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,9 @@ id: view-style-props
title: View Style Props
---

import ExperimentalAPIWarning from './\_experimental-api-warning.mdx';
import {getCoreBranchNameForCurrentVersion} from '@site/src/getCoreBranchNameForCurrentVersion';

### Example

```SnackPlayer name=ViewStyleProps
Expand Down Expand Up @@ -71,6 +74,33 @@ export default App;

---

### `experimental_backgroundImage`

<ExperimentalAPIWarning />

`experimental_backgroundImage` provides the ability to draw a [`linear-gradient()`](https://developer.mozilla.org/en-US/docs/Web/CSS/Reference/Values/gradient/linear-gradient) ([0.76.x+](https://github.com/facebook/react-native/blob/main/CHANGELOG-0.7x.md#v0760)) and [`radial-gradient()`](https://developer.mozilla.org/en-US/docs/Web/CSS/Reference/Values/gradient/radial-gradient) ([0.80.x+](https://github.com/facebook/react-native/blob/main/CHANGELOG.md#v0800)) using a web-like syntax.

```tsx
// Simple usage:
<View style={{
experimental_backgroundImage: 'linear-gradient(45deg, blue, red)'
}} />
<View style={{
experimental_backgroundImage: 'radial-gradient(ellipse farthest-corner at 30% 40%, red, blue)'
}} />
```

More complex examples of usage can be found in the RNTester app (with `PlatformColor` supports):

- <a href={`https://github.com/facebook/react-native/blob/${getCoreBranchNameForCurrentVersion()}/packages/rn-tester/js/examples/LinearGradient/LinearGradientExample.js`}>LinearGradientExample.js</a>
- <a href={`https://github.com/facebook/react-native/blob/${getCoreBranchNameForCurrentVersion()}/packages/rn-tester/js/examples/RadialGradient/RadialGradientExample.js`}>RadialGradientExample.js</a>

| Type |
| -------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- |
| string, array of objects: `{type: 'linear-gradient', direction: string, colorStops: object[] }`, `{type: 'radial-gradient', shape: string, position: object, size: string, colorStops: object[] }` |

---

### `borderBottomColor`

| Type |
Expand Down
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
:::important[Experimental 🧪]

**This API is experimental.** Experimental APIs may contain bugs and are likely to change in a future version of React Native. Don't use them in production.

:::
29 changes: 29 additions & 0 deletions website/versioned_docs/version-0.77/view-style-props.md
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,9 @@ id: view-style-props
title: View Style Props
---

import ExperimentalAPIWarning from './\_experimental-api-warning.mdx';
import {getCoreBranchNameForCurrentVersion} from '@site/src/getCoreBranchNameForCurrentVersion';

### Example

```SnackPlayer name=ViewStyleProps
Expand Down Expand Up @@ -71,6 +74,32 @@ export default App;

---

### `experimental_backgroundImage`

<ExperimentalAPIWarning />

`experimental_backgroundImage` provides the ability to draw a [`linear-gradient()`](https://developer.mozilla.org/en-US/docs/Web/CSS/Reference/Values/gradient/linear-gradient) ([0.76.x+](https://github.com/facebook/react-native/blob/main/CHANGELOG-0.7x.md#v0760)) using a web-like syntax.

```tsx
// Simple usage:
<View
style={{
experimental_backgroundImage:
'linear-gradient(45deg, blue, red)',
}}
/>
```

More complex examples of usage can be found in the RNTester app (with `PlatformColor` supports):

- <a href={`https://github.com/facebook/react-native/blob/${getCoreBranchNameForCurrentVersion()}/packages/rn-tester/js/examples/LinearGradient/LinearGradientExample.js`}>LinearGradientExample.js</a>

| Type |
| ----------------------------------------------------------------------------------------------- |
| string, array of objects: `{type: 'linear-gradient', direction: string, colorStops: object[] }` |

---

### `borderBottomColor`

| Type |
Expand Down
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
:::important[Experimental 🧪]

**This API is experimental.** Experimental APIs may contain bugs and are likely to change in a future version of React Native. Don't use them in production.

:::
29 changes: 29 additions & 0 deletions website/versioned_docs/version-0.78/view-style-props.md
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,9 @@ id: view-style-props
title: View Style Props
---

import ExperimentalAPIWarning from './\_experimental-api-warning.mdx';
import {getCoreBranchNameForCurrentVersion} from '@site/src/getCoreBranchNameForCurrentVersion';

### Example

```SnackPlayer name=ViewStyleProps
Expand Down Expand Up @@ -71,6 +74,32 @@ export default App;

---

### `experimental_backgroundImage`

<ExperimentalAPIWarning />

`experimental_backgroundImage` provides the ability to draw a [`linear-gradient()`](https://developer.mozilla.org/en-US/docs/Web/CSS/Reference/Values/gradient/linear-gradient) ([0.76.x+](https://github.com/facebook/react-native/blob/main/CHANGELOG-0.7x.md#v0760)) using a web-like syntax.

```tsx
// Simple usage:
<View
style={{
experimental_backgroundImage:
'linear-gradient(45deg, blue, red)',
}}
/>
```

More complex examples of usage can be found in the RNTester app (with `PlatformColor` supports):

- <a href={`https://github.com/facebook/react-native/blob/${getCoreBranchNameForCurrentVersion()}/packages/rn-tester/js/examples/LinearGradient/LinearGradientExample.js`}>LinearGradientExample.js</a>

| Type |
| ----------------------------------------------------------------------------------------------- |
| string, array of objects: `{type: 'linear-gradient', direction: string, colorStops: object[] }` |

---

### `borderBottomColor`

| Type |
Expand Down
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
:::important[Experimental 🧪]

**This API is experimental.** Experimental APIs may contain bugs and are likely to change in a future version of React Native. Don't use them in production.

:::
29 changes: 29 additions & 0 deletions website/versioned_docs/version-0.79/view-style-props.md
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,9 @@ id: view-style-props
title: View Style Props
---

import ExperimentalAPIWarning from './\_experimental-api-warning.mdx';
import {getCoreBranchNameForCurrentVersion} from '@site/src/getCoreBranchNameForCurrentVersion';

### Example

```SnackPlayer name=ViewStyleProps
Expand Down Expand Up @@ -71,6 +74,32 @@ export default App;

---

### `experimental_backgroundImage`

<ExperimentalAPIWarning />

`experimental_backgroundImage` provides the ability to draw a [`linear-gradient()`](https://developer.mozilla.org/en-US/docs/Web/CSS/Reference/Values/gradient/linear-gradient) ([0.76.x+](https://github.com/facebook/react-native/blob/main/CHANGELOG-0.7x.md#v0760)) using a web-like syntax.

```tsx
// Simple usage:
<View
style={{
experimental_backgroundImage:
'linear-gradient(45deg, blue, red)',
}}
/>
```

More complex examples of usage can be found in the RNTester app (with `PlatformColor` supports):

- <a href={`https://github.com/facebook/react-native/blob/${getCoreBranchNameForCurrentVersion()}/packages/rn-tester/js/examples/LinearGradient/LinearGradientExample.js`}>LinearGradientExample.js</a>

| Type |
| ----------------------------------------------------------------------------------------------- |
| string, array of objects: `{type: 'linear-gradient', direction: string, colorStops: object[] }` |

---

### `borderBottomColor`

| Type |
Expand Down
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
:::important[Experimental 🧪]

**This API is experimental.** Experimental APIs may contain bugs and are likely to change in a future version of React Native. Don't use them in production.

:::
30 changes: 30 additions & 0 deletions website/versioned_docs/version-0.80/view-style-props.md
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,9 @@ id: view-style-props
title: View Style Props
---

import ExperimentalAPIWarning from './\_experimental-api-warning.mdx';
import {getCoreBranchNameForCurrentVersion} from '@site/src/getCoreBranchNameForCurrentVersion';

### Example

```SnackPlayer name=ViewStyleProps
Expand Down Expand Up @@ -71,6 +74,33 @@ export default App;

---

### `experimental_backgroundImage`

<ExperimentalAPIWarning />

`experimental_backgroundImage` provides the ability to draw a [`linear-gradient()`](https://developer.mozilla.org/en-US/docs/Web/CSS/Reference/Values/gradient/linear-gradient) ([0.76.x+](https://github.com/facebook/react-native/blob/main/CHANGELOG-0.7x.md#v0760)) and [`radial-gradient()`](https://developer.mozilla.org/en-US/docs/Web/CSS/Reference/Values/gradient/radial-gradient) ([0.80.x+](https://github.com/facebook/react-native/blob/main/CHANGELOG.md#v0800)) using a web-like syntax.

```tsx
// Simple usage:
<View style={{
experimental_backgroundImage: 'linear-gradient(45deg, blue, red)'
}} />
<View style={{
experimental_backgroundImage: 'radial-gradient(ellipse farthest-corner at 30% 40%, red, blue)'
}} />
```

More complex examples of usage can be found in the RNTester app (with `PlatformColor` supports):

- <a href={`https://github.com/facebook/react-native/blob/${getCoreBranchNameForCurrentVersion()}/packages/rn-tester/js/examples/LinearGradient/LinearGradientExample.js`}>LinearGradientExample.js</a>
- <a href={`https://github.com/facebook/react-native/blob/${getCoreBranchNameForCurrentVersion()}/packages/rn-tester/js/examples/RadialGradient/RadialGradientExample.js`}>RadialGradientExample.js</a>

| Type |
| -------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- |
| string, array of objects: `{type: 'linear-gradient', direction: string, colorStops: object[] }`, `{type: 'radial-gradient', shape: string, position: object, size: string, colorStops: object[] }` |

---

### `borderBottomColor`

| Type |
Expand Down
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
:::important[Experimental 🧪]

**This API is experimental.** Experimental APIs may contain bugs and are likely to change in a future version of React Native. Don't use them in production.

:::
30 changes: 30 additions & 0 deletions website/versioned_docs/version-0.81/view-style-props.md
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,9 @@ id: view-style-props
title: View Style Props
---

import ExperimentalAPIWarning from './\_experimental-api-warning.mdx';
import {getCoreBranchNameForCurrentVersion} from '@site/src/getCoreBranchNameForCurrentVersion';

### Example

```SnackPlayer name=ViewStyleProps
Expand Down Expand Up @@ -71,6 +74,33 @@ export default App;

---

### `experimental_backgroundImage`

<ExperimentalAPIWarning />

`experimental_backgroundImage` provides the ability to draw a [`linear-gradient()`](https://developer.mozilla.org/en-US/docs/Web/CSS/Reference/Values/gradient/linear-gradient) ([0.76.x+](https://github.com/facebook/react-native/blob/main/CHANGELOG-0.7x.md#v0760)) and [`radial-gradient()`](https://developer.mozilla.org/en-US/docs/Web/CSS/Reference/Values/gradient/radial-gradient) ([0.80.x+](https://github.com/facebook/react-native/blob/main/CHANGELOG.md#v0800)) using a web-like syntax.

```tsx
// Simple usage:
<View style={{
experimental_backgroundImage: 'linear-gradient(45deg, blue, red)'
}} />
<View style={{
experimental_backgroundImage: 'radial-gradient(ellipse farthest-corner at 30% 40%, red, blue)'
}} />
```

More complex examples of usage can be found in the RNTester app (with `PlatformColor` supports):

- <a href={`https://github.com/facebook/react-native/blob/${getCoreBranchNameForCurrentVersion()}/packages/rn-tester/js/examples/LinearGradient/LinearGradientExample.js`}>LinearGradientExample.js</a>
- <a href={`https://github.com/facebook/react-native/blob/${getCoreBranchNameForCurrentVersion()}/packages/rn-tester/js/examples/RadialGradient/RadialGradientExample.js`}>RadialGradientExample.js</a>

| Type |
| -------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- |
| string, array of objects: `{type: 'linear-gradient', direction: string, colorStops: object[] }`, `{type: 'radial-gradient', shape: string, position: object, size: string, colorStops: object[] }` |

---

### `borderBottomColor`

| Type |
Expand Down
30 changes: 30 additions & 0 deletions website/versioned_docs/version-0.82/view-style-props.md
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,9 @@ id: view-style-props
title: View Style Props
---

import ExperimentalAPIWarning from './\_experimental-api-warning.mdx';
import {getCoreBranchNameForCurrentVersion} from '@site/src/getCoreBranchNameForCurrentVersion';

### Example

```SnackPlayer name=ViewStyleProps
Expand Down Expand Up @@ -71,6 +74,33 @@ export default App;

---

### `experimental_backgroundImage`

<ExperimentalAPIWarning />

`experimental_backgroundImage` provides the ability to draw a [`linear-gradient()`](https://developer.mozilla.org/en-US/docs/Web/CSS/Reference/Values/gradient/linear-gradient) ([0.76.x+](https://github.com/facebook/react-native/blob/main/CHANGELOG-0.7x.md#v0760)) and [`radial-gradient()`](https://developer.mozilla.org/en-US/docs/Web/CSS/Reference/Values/gradient/radial-gradient) ([0.80.x+](https://github.com/facebook/react-native/blob/main/CHANGELOG.md#v0800)) using a web-like syntax.

```tsx
// Simple usage:
<View style={{
experimental_backgroundImage: 'linear-gradient(45deg, blue, red)'
}} />
<View style={{
experimental_backgroundImage: 'radial-gradient(ellipse farthest-corner at 30% 40%, red, blue)'
}} />
```

More complex examples of usage can be found in the RNTester app (with `PlatformColor` supports):

- <a href={`https://github.com/facebook/react-native/blob/${getCoreBranchNameForCurrentVersion()}/packages/rn-tester/js/examples/LinearGradient/LinearGradientExample.js`}>LinearGradientExample.js</a>
- <a href={`https://github.com/facebook/react-native/blob/${getCoreBranchNameForCurrentVersion()}/packages/rn-tester/js/examples/RadialGradient/RadialGradientExample.js`}>RadialGradientExample.js</a>

| Type |
| -------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- |
| string, array of objects: `{type: 'linear-gradient', direction: string, colorStops: object[] }`, `{type: 'radial-gradient', shape: string, position: object, size: string, colorStops: object[] }` |

---

### `borderBottomColor`

| Type |
Expand Down
30 changes: 30 additions & 0 deletions website/versioned_docs/version-0.83/view-style-props.md
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,9 @@ id: view-style-props
title: View Style Props
---

import ExperimentalAPIWarning from './\_experimental-api-warning.mdx';
import {getCoreBranchNameForCurrentVersion} from '@site/src/getCoreBranchNameForCurrentVersion';

### Example

```SnackPlayer name=ViewStyleProps
Expand Down Expand Up @@ -71,6 +74,33 @@ export default App;

---

### `experimental_backgroundImage`

<ExperimentalAPIWarning />

`experimental_backgroundImage` provides the ability to draw a [`linear-gradient()`](https://developer.mozilla.org/en-US/docs/Web/CSS/Reference/Values/gradient/linear-gradient) ([0.76.x+](https://github.com/facebook/react-native/blob/main/CHANGELOG-0.7x.md#v0760)) and [`radial-gradient()`](https://developer.mozilla.org/en-US/docs/Web/CSS/Reference/Values/gradient/radial-gradient) ([0.80.x+](https://github.com/facebook/react-native/blob/main/CHANGELOG.md#v0800)) using a web-like syntax.

```tsx
// Simple usage:
<View style={{
experimental_backgroundImage: 'linear-gradient(45deg, blue, red)'
}} />
<View style={{
experimental_backgroundImage: 'radial-gradient(ellipse farthest-corner at 30% 40%, red, blue)'
}} />
```

More complex examples of usage can be found in the RNTester app (with `PlatformColor` supports):

- <a href={`https://github.com/facebook/react-native/blob/${getCoreBranchNameForCurrentVersion()}/packages/rn-tester/js/examples/LinearGradient/LinearGradientExample.js`}>LinearGradientExample.js</a>
- <a href={`https://github.com/facebook/react-native/blob/${getCoreBranchNameForCurrentVersion()}/packages/rn-tester/js/examples/RadialGradient/RadialGradientExample.js`}>RadialGradientExample.js</a>

| Type |
| -------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- |
| string, array of objects: `{type: 'linear-gradient', direction: string, colorStops: object[] }`, `{type: 'radial-gradient', shape: string, position: object, size: string, colorStops: object[] }` |

---

### `borderBottomColor`

| Type |
Expand Down
Loading