Skip to content

Commit

Permalink
docs(exoflex): add docs for ActivityIndicator component (#74)
Browse files Browse the repository at this point in the history
* add docs for ActivityIndicator component

* add preview image

* remove undefined from default props
  • Loading branch information
darcien authored Sep 11, 2019
1 parent 8575f32 commit d5392ea
Show file tree
Hide file tree
Showing 2 changed files with 27 additions and 0 deletions.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
27 changes: 27 additions & 0 deletions packages/exoflex/docs/components/ActivityIndicator.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,27 @@
# ActivityIndicator

Activity indicator is used to present progress of some activity in the app.

### Preview

![activity_indicator_preview](../assets/activity_indicator_preview.gif)

### Props

| Name | Type | Default | Description |
| ------------------ | :----------------------------: | :-------: | -------------------------------------------------------------------- |
| `animating` | `boolean` | `true` | Whether to show the indicator or hide it. |
| `color` | `string` | | The color of the spinner. Will use the primary color from the theme. |
| `size` | `'small' \| 'large' \| number` | `'small'` | Size of the indicator. |
| `hidesWhenStopped` | `boolean` | `true` | Whether the indicator should hide when not animating. |
| `style` | `StyleProp<ViewStyle>` | | Additional style for the container. |

### Example

```tsx
<Provider>
<ActivityIndicator />

<ActivityIndicator size="large" color="salmon" />
</Provider>
```

0 comments on commit d5392ea

Please sign in to comment.