diff options
author | Jacob Evans <jacob@dekz.net> | 2018-03-06 10:05:30 +0800 |
---|---|---|
committer | Jacob Evans <jacob@dekz.net> | 2018-03-06 10:05:30 +0800 |
commit | 8521775389b2e7ddefec20f1d06331e4bc3d0540 (patch) | |
tree | b1e040548183f51e52ffdaa7f593e95311d4829b /packages/subproviders/src/globals.d.ts | |
parent | 994935b5da0b15796958a32c5bab0a25b9430b5a (diff) | |
download | dexon-sol-tools-8521775389b2e7ddefec20f1d06331e4bc3d0540.tar.gz dexon-sol-tools-8521775389b2e7ddefec20f1d06331e4bc3d0540.tar.zst dexon-sol-tools-8521775389b2e7ddefec20f1d06331e4bc3d0540.zip |
Update ledgerco packages
Diffstat (limited to 'packages/subproviders/src/globals.d.ts')
-rw-r--r-- | packages/subproviders/src/globals.d.ts | 22 |
1 files changed, 22 insertions, 0 deletions
diff --git a/packages/subproviders/src/globals.d.ts b/packages/subproviders/src/globals.d.ts index 6f344dcd3..0c8b3fed3 100644 --- a/packages/subproviders/src/globals.d.ts +++ b/packages/subproviders/src/globals.d.ts @@ -32,6 +32,28 @@ interface ECSignature { r: string; s: string; } + +interface LedgerTransport { + close(): Promise<void> +} + +declare module '@ledgerhq/hw-app-eth' { + export class Eth { + constructor(transport: LedgerTransport); + public getAddress(path: string, boolDisplay?: boolean, boolChaincode?: boolean): Promise<{ publicKey: string; address: string; chainCode: string }>; + public signTransaction(path: string, rawTxHex: string): Promise<ECSignatureString>; + public getAppConfiguration(): Promise<{ arbitraryDataEnabled: number; version: string; }>; + public signPersonalMessage(path: string, messageHex: string): Promise<ECSignature>; + transport: LedgerTransport; + } +} +declare module '@ledgerhq/hw-transport-u2f' { + export class TransportU2F implements LedgerTransport { + public static create(): Promise<TransportU2F>; + public close(): Promise<void>; + } +} + declare module 'ledgerco' { interface comm { close_async(): Promise<void>; |