2019-06-25 09:02:44 +00:00
|
|
|
# ContextMenuButton
|
2019-06-24 13:50:54 +00:00
|
|
|
|
|
|
|
#### Description
|
|
|
|
|
2019-06-25 09:02:44 +00:00
|
|
|
ContextMenuButton is used for displaying context menu actions on a list's item
|
2019-06-24 13:50:54 +00:00
|
|
|
|
|
|
|
#### Usage
|
|
|
|
|
|
|
|
```js
|
2019-06-25 09:02:44 +00:00
|
|
|
import { ContextMenuButton } from 'asc-web-components';
|
|
|
|
|
|
|
|
<ContextMenuButton
|
|
|
|
title="Actions"
|
|
|
|
getData={() => [{key: 'key', label: 'label', onClick: () => alert('label')}]}
|
|
|
|
/>
|
2019-06-24 13:50:54 +00:00
|
|
|
```
|
|
|
|
|
2019-06-25 09:02:44 +00:00
|
|
|
#### Properties
|
|
|
|
|
2019-06-26 14:29:18 +00:00
|
|
|
| Props | Type | Required | Values | Default | Description |
|
|
|
|
| ---------- | ----------- | :------: | --------------------------------- | ------------------ | ------------------------ |
|
|
|
|
| `title` | `string` | | | - | Specifies the icon title |
|
|
|
|
| `iconName` | `string` | | | `VerticalDotsIcon` | Specifies the icon name |
|
|
|
|
| `size` | `string` | | `small`, `medium`, `big` ,`scale` | `medium` | Specifies the icon size |
|
|
|
|
| `color` | `string` | | | - | Specifies the icon color |
|