diff options
Diffstat (limited to 'packages/types')
-rw-r--r-- | packages/types/CHANGELOG.md | 3 | ||||
-rw-r--r-- | packages/types/package.json | 10 | ||||
-rw-r--r-- | packages/types/src/index.ts | 28 |
3 files changed, 35 insertions, 6 deletions
diff --git a/packages/types/CHANGELOG.md b/packages/types/CHANGELOG.md index 55dc2d560..11d703211 100644 --- a/packages/types/CHANGELOG.md +++ b/packages/types/CHANGELOG.md @@ -1,8 +1,9 @@ # CHANGELOG -## v0.4.0 - _TBD, 2018_ +## v0.4.0 - _March 18, 2018_ * Remove `JSONRPCPayload` (#426) + * Consolidate `Order`, `SignedOrder`, and `ECSignature` into the `@0xproject/types` package (#456) ## v0.3.1 - _March 8, 2018_ diff --git a/packages/types/package.json b/packages/types/package.json index 8dc03892e..e664b06ae 100644 --- a/packages/types/package.json +++ b/packages/types/package.json @@ -1,6 +1,6 @@ { "name": "@0xproject/types", - "version": "0.3.1", + "version": "0.4.1", "description": "0x types", "main": "lib/index.js", "types": "lib/index.d.ts", @@ -20,8 +20,8 @@ }, "homepage": "https://github.com/0xProject/0x-monorepo/packages/types/README.md", "devDependencies": { - "@0xproject/monorepo-scripts": "^0.1.12", - "@0xproject/tslint-config": "^0.4.10", + "@0xproject/monorepo-scripts": "^0.1.14", + "@0xproject/tslint-config": "^0.4.12", "copyfiles": "^1.2.0", "shx": "^0.2.2", "tslint": "5.8.0", @@ -30,9 +30,9 @@ "dependencies": { "bignumber.js": "~4.1.0", "web3": "^0.20.0", - "web3-typescript-typings": "^0.10.0" + "web3-typescript-typings": "^0.10.2" }, "publishConfig": { - "access": "public" + "access": "public" } } diff --git a/packages/types/src/index.ts b/packages/types/src/index.ts index 149aaca8a..2147a3edb 100644 --- a/packages/types/src/index.ts +++ b/packages/types/src/index.ts @@ -73,3 +73,31 @@ export interface RawLogEntry { data: string; topics: string[]; } + +export interface Order { + maker: string; + taker: string; + makerFee: BigNumber; + takerFee: BigNumber; + makerTokenAmount: BigNumber; + takerTokenAmount: BigNumber; + makerTokenAddress: string; + takerTokenAddress: string; + salt: BigNumber; + exchangeContractAddress: string; + feeRecipient: string; + expirationUnixTimestampSec: BigNumber; +} + +export interface SignedOrder extends Order { + ecSignature: ECSignature; +} + +/** + * Elliptic Curve signature + */ +export interface ECSignature { + v: number; + r: string; + s: string; +} |