aboutsummaryrefslogtreecommitdiffstats
path: root/packages/contracts
diff options
context:
space:
mode:
authorLeonid Logvinov <logvinov.leon@gmail.com>2018-03-27 21:19:23 +0800
committerLeonid Logvinov <logvinov.leon@gmail.com>2018-03-27 23:56:21 +0800
commitd72b7299c66ea6d63eb14595b06456c02b2ad99b (patch)
treee026f0af7f779c0c94ddc1261f630dd8ca923af5 /packages/contracts
parent066d13f5b7260d28b13195c4f9aed48b4ae96cc3 (diff)
downloaddexon-sol-tools-d72b7299c66ea6d63eb14595b06456c02b2ad99b.tar
dexon-sol-tools-d72b7299c66ea6d63eb14595b06456c02b2ad99b.tar.gz
dexon-sol-tools-d72b7299c66ea6d63eb14595b06456c02b2ad99b.tar.bz2
dexon-sol-tools-d72b7299c66ea6d63eb14595b06456c02b2ad99b.tar.lz
dexon-sol-tools-d72b7299c66ea6d63eb14595b06456c02b2ad99b.tar.xz
dexon-sol-tools-d72b7299c66ea6d63eb14595b06456c02b2ad99b.tar.zst
dexon-sol-tools-d72b7299c66ea6d63eb14595b06456c02b2ad99b.zip
Move common types out of web3 types
Diffstat (limited to 'packages/contracts')
-rw-r--r--packages/contracts/util/multi_sig_wrapper.ts5
-rw-r--r--packages/contracts/util/types.ts6
2 files changed, 6 insertions, 5 deletions
diff --git a/packages/contracts/util/multi_sig_wrapper.ts b/packages/contracts/util/multi_sig_wrapper.ts
index 3b83ccb7b..9f6dcec52 100644
--- a/packages/contracts/util/multi_sig_wrapper.ts
+++ b/packages/contracts/util/multi_sig_wrapper.ts
@@ -1,3 +1,4 @@
+import { AbiDefinition, MethodAbi } from '@0xproject/types';
import { BigNumber } from '@0xproject/utils';
import ABI = require('ethereumjs-abi');
import ethUtil = require('ethereumjs-util');
@@ -10,8 +11,8 @@ import { TransactionDataParams } from './types';
export class MultiSigWrapper {
private _multiSig: MultiSigWalletContract;
- public static encodeFnArgs(name: string, abi: Web3.AbiDefinition[], args: any[]) {
- const abiEntity = _.find(abi, { name }) as Web3.MethodAbi;
+ public static encodeFnArgs(name: string, abi: AbiDefinition[], args: any[]) {
+ const abiEntity = _.find(abi, { name }) as MethodAbi;
if (_.isUndefined(abiEntity)) {
throw new Error(`Did not find abi entry for name: ${name}`);
}
diff --git a/packages/contracts/util/types.ts b/packages/contracts/util/types.ts
index 61a19acb4..321084c42 100644
--- a/packages/contracts/util/types.ts
+++ b/packages/contracts/util/types.ts
@@ -1,5 +1,5 @@
+import { AbiDefinition, ContractAbi } from '@0xproject/types';
import { BigNumber } from '@0xproject/utils';
-import * as Web3 from 'web3';
export interface BalancesByOwner {
[ownerAddress: string]: {
@@ -51,7 +51,7 @@ export interface DefaultOrderParams {
export interface TransactionDataParams {
name: string;
- abi: Web3.AbiDefinition[];
+ abi: AbiDefinition[];
args: any[];
}
@@ -105,7 +105,7 @@ export interface Artifact {
contract_name: ContractName;
networks: {
[networkId: number]: {
- abi: Web3.ContractAbi;
+ abi: ContractAbi;
solc_version: string;
keccak256: string;
optimizer_enabled: number;