Add Vaults as dapp
This commit is contained in:
parent
c044534d6a
commit
262169c8a4
@ -4,7 +4,7 @@
|
||||
"url": "home",
|
||||
"src": "Home",
|
||||
"name": "Home",
|
||||
"description": "Display a status of the node, recently accessed applications, accounts and news",
|
||||
"description": "Display the status of the node, recently accessed applications, accounts and news",
|
||||
"author": "Parity Team <admin@ethcore.io>",
|
||||
"version": "2.0.0",
|
||||
"visible": true,
|
||||
@ -15,7 +15,18 @@
|
||||
"url": "status",
|
||||
"src": "Status",
|
||||
"name": "Status",
|
||||
"description": "Display an overview of the node including settings, logs and connections",
|
||||
"description": "Displays an overview of the node including settings, logs and connections",
|
||||
"author": "Parity Team <admin@ethcore.io>",
|
||||
"version": "2.0.0",
|
||||
"visible": true,
|
||||
"secure": true
|
||||
},
|
||||
{
|
||||
"id": "vaults",
|
||||
"url": "vaults",
|
||||
"src": "Vaults",
|
||||
"name": "Vaults",
|
||||
"description": "Allows the management of the Account Vaults, including creation, locking and account assignment",
|
||||
"author": "Parity Team <admin@ethcore.io>",
|
||||
"version": "2.0.0",
|
||||
"visible": true,
|
||||
|
@ -20,7 +20,7 @@ import {
|
||||
Contract, Contracts, Dapp, Dapps,
|
||||
Settings, SettingsBackground, SettingsParity, SettingsProxy,
|
||||
SettingsViews, Signer,
|
||||
Vaults, Wallet, Web, WriteContract
|
||||
Wallet, Web, WriteContract
|
||||
} from '~/views';
|
||||
import builtinDapps from '~/config/dappsBuiltin.json';
|
||||
import viewsDapps from '~/config/dappsViews.json';
|
||||
@ -61,7 +61,6 @@ const accountsRoutes = [
|
||||
accountsHistory.add(params.address, 'account');
|
||||
}
|
||||
},
|
||||
{ path: '/vaults', component: Vaults },
|
||||
{
|
||||
path: '/wallet/:address',
|
||||
component: Wallet,
|
||||
|
@ -20,13 +20,12 @@ import { uniq, isEqual, pickBy } from 'lodash';
|
||||
import React, { Component, PropTypes } from 'react';
|
||||
import { FormattedMessage } from 'react-intl';
|
||||
import { connect } from 'react-redux';
|
||||
import { Link } from 'react-router';
|
||||
import { bindActionCreators } from 'redux';
|
||||
|
||||
import HardwareStore from '~/mobx/hardwareStore';
|
||||
import { CreateAccount, CreateWallet } from '~/modals';
|
||||
import { Actionbar, ActionbarExport, ActionbarSearch, ActionbarSort, Button, Page, Tooltip } from '~/ui';
|
||||
import { AddIcon, KeyIcon } from '~/ui/Icons';
|
||||
import { AddIcon } from '~/ui/Icons';
|
||||
import { setVisibleAccounts } from '~/redux/providers/personalActions';
|
||||
|
||||
import List from './List';
|
||||
@ -247,21 +246,6 @@ class Accounts extends Component {
|
||||
const { accounts } = this.props;
|
||||
|
||||
const buttons = [
|
||||
<Link
|
||||
to='/vaults'
|
||||
key='vaults'
|
||||
>
|
||||
<Button
|
||||
icon={ <KeyIcon /> }
|
||||
label={
|
||||
<FormattedMessage
|
||||
id='accounts.button.vaults'
|
||||
defaultMessage='vaults'
|
||||
/>
|
||||
}
|
||||
onClick={ this.onVaultsClick }
|
||||
/>
|
||||
</Link>,
|
||||
<Button
|
||||
key='newAccount'
|
||||
icon={ <AddIcon /> }
|
||||
|
@ -14,4 +14,34 @@
|
||||
// You should have received a copy of the GNU General Public License
|
||||
// along with Parity. If not, see <http://www.gnu.org/licenses/>.
|
||||
|
||||
export default from './vaults';
|
||||
import ReactDOM from 'react-dom';
|
||||
import React from 'react';
|
||||
import { hashHistory } from 'react-router';
|
||||
|
||||
import injectTapEventPlugin from 'react-tap-event-plugin';
|
||||
injectTapEventPlugin();
|
||||
|
||||
import { api } from './parity';
|
||||
|
||||
import ContractInstances from '~/contracts';
|
||||
import { initStore } from '~/redux';
|
||||
import ContextProvider from '~/ui/ContextProvider';
|
||||
import muiTheme from '~/ui/Theme';
|
||||
|
||||
import Vaults from './vaults';
|
||||
|
||||
import '~/../assets/fonts/Roboto/font.css';
|
||||
import '~/../assets/fonts/RobotoMono/font.css';
|
||||
|
||||
import './vaults.css';
|
||||
|
||||
ContractInstances.get(api);
|
||||
|
||||
const store = initStore(api, hashHistory);
|
||||
|
||||
ReactDOM.render(
|
||||
<ContextProvider api={ api } muiTheme={ muiTheme } store={ store }>
|
||||
<Vaults />
|
||||
</ContextProvider>,
|
||||
document.querySelector('#container')
|
||||
);
|
||||
|
19
js/src/views/Vaults/package.json
Normal file
19
js/src/views/Vaults/package.json
Normal file
@ -0,0 +1,19 @@
|
||||
{
|
||||
"name": "@parity/view-vaults",
|
||||
"description": "Parity default Vaults view",
|
||||
"version": "0.0.0",
|
||||
"main": "index.js",
|
||||
"author": "Parity Team <admin@parity.io>",
|
||||
"maintainers": [],
|
||||
"contributors": [],
|
||||
"license": "GPL-3.0",
|
||||
"repository": {
|
||||
"type": "git",
|
||||
"url": "git+https://github.com/paritytech/parity.git"
|
||||
},
|
||||
"keywords": [],
|
||||
"scripts": {},
|
||||
"devDependencies": {},
|
||||
"dependencies": {},
|
||||
"peerDependencies": {}
|
||||
}
|
21
js/src/views/Vaults/parity.js
Normal file
21
js/src/views/Vaults/parity.js
Normal file
@ -0,0 +1,21 @@
|
||||
// Copyright 2015-2017 Parity Technologies (UK) Ltd.
|
||||
// This file is part of Parity.
|
||||
|
||||
// Parity is free software: you can redistribute it and/or modify
|
||||
// it under the terms of the GNU General Public License as published by
|
||||
// the Free Software Foundation, either version 3 of the License, or
|
||||
// (at your option) any later version.
|
||||
|
||||
// Parity is distributed in the hope that it will be useful,
|
||||
// but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||
// GNU General Public License for more details.
|
||||
|
||||
// You should have received a copy of the GNU General Public License
|
||||
// along with Parity. If not, see <http://www.gnu.org/licenses/>.
|
||||
|
||||
const api = window.parent.secureApi;
|
||||
|
||||
export {
|
||||
api
|
||||
};
|
@ -26,7 +26,6 @@ export Dapps from './Dapps';
|
||||
export ParityBar from './ParityBar';
|
||||
export Settings, { SettingsBackground, SettingsParity, SettingsProxy, SettingsViews } from './Settings';
|
||||
export Signer from './Signer';
|
||||
export Vaults from './Vaults';
|
||||
export Wallet from './Wallet';
|
||||
export Web from './Web';
|
||||
export WriteContract from './WriteContract';
|
||||
|
Loading…
Reference in New Issue
Block a user