open-consul/ui-v2/app/components/consul-token-list
Kenia 689d1375a3
ui: Add sorting to ACLs tokens with tests (#8359)
* Add sorting to ACLs tokens with tests

* Create token comparator and implement in template

* Upgrade @hashicorp/consul-api-double to 3.1.6

* Add navigation test to acls tokens
2020-07-29 09:41:40 -04:00
..
README.mdx ui: Add some missed spaces in component README files (#8335) 2020-07-20 17:43:10 +01:00
index.hbs ui: Add sorting to ACLs tokens with tests (#8359) 2020-07-29 09:41:40 -04:00
index.js ui: Token listing redesign (#8117) 2020-06-17 10:25:54 +01:00
pageobject.js ui: Add sorting to ACLs tokens with tests (#8359) 2020-07-29 09:41:40 -04:00

README.mdx

## ConsulTokenList

```
<ConsulTokenList
  @items={{items}}
  @token={{userToken}}
  @onuse={{action 'use'}}
  @ondelete={{action 'delete'}}
  @onlogout={{action 'logout'}}
  @onclone={{action 'clone'}}
/>
```

A presentational component for rendering Consul ACL tokens

### Arguments

| Argument/Attribute | Type | Default | Description |
| --- | --- | --- | --- |
| `items` | `array` |  | An array of ACL tokens |
| `token` | `Token` |  | A token object to use for comparision for current token, usually the users current token |
| `onuse` | `function` |  | An action to execute when the `Use` action is clicked |
| `ondelete` | `function` |  | An action to execute when the `Delete` action is clicked |
| `onlogout` | `function` |  | An action to execute when the `Logout` action is clicked |
| `onclone` | `function` |  | An action to execute when the `Clone/Duplicate` action is clicked |

### See

- [Component Source Code](./index.js)
- [Template Source Code](./index.hbs)

---