Added Export Component in Actionbar => export Addressbook (#2153) (#2847)

This commit is contained in:
Nicolas Gotchac
2016-10-24 18:27:35 +02:00
committed by Gav Wood
parent bc81ae0407
commit 1b42e9a9af
5 changed files with 85 additions and 1 deletions

View File

@@ -22,7 +22,7 @@ import { uniq } from 'lodash';
import List from '../Accounts/List';
import { AddAddress } from '../../modals';
import { Actionbar, ActionbarSearch, ActionbarSort, Button, Page } from '../../ui';
import { Actionbar, ActionbarExport, ActionbarSearch, ActionbarSort, Button, Page } from '../../ui';
import styles from './addresses.css';
@@ -93,6 +93,8 @@ class Addresses extends Component {
}
renderActionbar () {
const { contacts } = this.props;
const buttons = [
<Button
key='newAddress'
@@ -100,6 +102,11 @@ class Addresses extends Component {
label='new address'
onClick={ this.onOpenAdd } />,
<ActionbarExport
key='exportAddressbook'
content={ contacts }
filename='addressbook.json' />,
this.renderSearchButton(),
this.renderSortButton()
];