@airgap/ethereum 0.13.13-beta.5 → 0.13.13
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/index.d.ts +1 -1
- package/index.js +1 -1
- package/package.json +5 -5
- package/v1/block-explorer/EtherscanBlockExplorer.d.ts +1 -1
- package/v1/block-explorer/EtherscanBlockExplorer.js +2 -0
- package/v1/block-explorer/EtherscanBlockExplorer.js.map +1 -1
- package/v1/index.d.ts +1 -6
- package/v1/index.js +1 -3
- package/v1/index.js.map +1 -1
- package/v1/module/EthereumModule.d.ts +3 -6
- package/v1/module/EthereumModule.js +8 -10
- package/v1/module/EthereumModule.js.map +1 -1
- package/v1/protocol/EthereumProtocol.d.ts +2 -4
- package/v1/protocol/EthereumProtocol.js +0 -59
- package/v1/protocol/EthereumProtocol.js.map +1 -1
- package/v1/protocol/erc20/ERC20Token.d.ts +2 -2
- package/v1/protocol/erc20/ERC20Token.js +2 -2
- package/v1/protocol/erc20/ERC20Token.js.map +1 -1
package/index.d.ts
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
export * from './
|
|
1
|
+
export * from './v0';
|
package/index.js
CHANGED
|
@@ -14,5 +14,5 @@ var __exportStar = (this && this.__exportStar) || function(m, exports) {
|
|
|
14
14
|
for (var p in m) if (p !== "default" && !Object.prototype.hasOwnProperty.call(exports, p)) __createBinding(exports, m, p);
|
|
15
15
|
};
|
|
16
16
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
17
|
-
__exportStar(require("./
|
|
17
|
+
__exportStar(require("./v0"), exports);
|
|
18
18
|
//# sourceMappingURL=index.js.map
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@airgap/ethereum",
|
|
3
|
-
"version": "0.13.13
|
|
3
|
+
"version": "0.13.13",
|
|
4
4
|
"description": "The @airgap/ethereum is an Ethereum implementation of the ICoinProtocol interface from @airgap/coinlib-core.",
|
|
5
5
|
"keywords": [
|
|
6
6
|
"airgap",
|
|
@@ -30,10 +30,10 @@
|
|
|
30
30
|
},
|
|
31
31
|
"author": "Papers AG <contact@papers.ch> (https://papers.ch)",
|
|
32
32
|
"dependencies": {
|
|
33
|
-
"@airgap/coinlib-core": "
|
|
34
|
-
"@airgap/crypto": "
|
|
35
|
-
"@airgap/module-kit": "
|
|
36
|
-
"@airgap/serializer": "
|
|
33
|
+
"@airgap/coinlib-core": "*",
|
|
34
|
+
"@airgap/crypto": "*",
|
|
35
|
+
"@airgap/module-kit": "*",
|
|
36
|
+
"@airgap/serializer": "*",
|
|
37
37
|
"@ethereumjs/common": "2.6.0",
|
|
38
38
|
"@ethereumjs/tx": "3.4.0",
|
|
39
39
|
"@metamask/eth-sig-util": "4.0.0"
|
|
@@ -2,7 +2,7 @@ import { AirGapBlockExplorer, BlockExplorerMetadata } from '@airgap/module-kit';
|
|
|
2
2
|
export declare class EtherscanBlockExplorer implements AirGapBlockExplorer {
|
|
3
3
|
private readonly url;
|
|
4
4
|
private readonly metadata;
|
|
5
|
-
constructor(url
|
|
5
|
+
constructor(url?: string);
|
|
6
6
|
getMetadata(): Promise<BlockExplorerMetadata>;
|
|
7
7
|
createAddressUrl(address: string): Promise<string>;
|
|
8
8
|
createTransactionUrl(transactionId: string): Promise<string>;
|
|
@@ -37,8 +37,10 @@ var __generator = (this && this.__generator) || function (thisArg, body) {
|
|
|
37
37
|
};
|
|
38
38
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
39
39
|
exports.EtherscanBlockExplorer = void 0;
|
|
40
|
+
var BLOCK_EXPLORER_URL = 'https://etherscan.io';
|
|
40
41
|
var EtherscanBlockExplorer = /** @class */ (function () {
|
|
41
42
|
function EtherscanBlockExplorer(url) {
|
|
43
|
+
if (url === void 0) { url = BLOCK_EXPLORER_URL; }
|
|
42
44
|
this.url = url;
|
|
43
45
|
this.metadata = {
|
|
44
46
|
name: 'Etherscan',
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"EtherscanBlockExplorer.js","sourceRoot":"","sources":["../../../src/v1/block-explorer/EtherscanBlockExplorer.ts"],"names":[],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AAEA;IAME,gCAAoC,
|
|
1
|
+
{"version":3,"file":"EtherscanBlockExplorer.js","sourceRoot":"","sources":["../../../src/v1/block-explorer/EtherscanBlockExplorer.ts"],"names":[],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AAEA,IAAM,kBAAkB,GAAW,sBAAsB,CAAA;AAEzD;IAME,gCAAoC,GAAgC;QAAhC,oBAAA,EAAA,wBAAgC;QAAhC,QAAG,GAAH,GAAG,CAA6B;QALnD,aAAQ,GAA0B;YACjD,IAAI,EAAE,WAAW;YACjB,GAAG,EAAE,IAAI,CAAC,GAAG;SACd,CAAA;IAEsE,CAAC;IAE3D,4CAAW,GAAxB;;;gBACE,sBAAO,IAAI,CAAC,QAAQ,EAAA;;;KACrB;IAEY,iDAAgB,GAA7B,UAA8B,OAAe;;;gBAC3C,sBAAO,UAAG,IAAI,CAAC,GAAG,sBAAY,OAAO,CAAE,EAAA;;;KACxC;IAEY,qDAAoB,GAAjC,UAAkC,aAAqB;;;gBACrD,sBAAO,UAAG,IAAI,CAAC,GAAG,iBAAO,aAAa,CAAE,EAAA;;;KACzC;IACH,6BAAC;AAAD,CAAC,AAnBD,IAmBC;AAnBY,wDAAsB"}
|
package/v1/index.d.ts
CHANGED
|
@@ -1,16 +1,11 @@
|
|
|
1
1
|
import { EtherscanBlockExplorer } from './block-explorer/EtherscanBlockExplorer';
|
|
2
|
-
import { erc20Tokens } from './module/ERC20Tokens';
|
|
3
2
|
import { EthereumModule } from './module/EthereumModule';
|
|
4
3
|
import { createERC20Token, ERC20Token } from './protocol/erc20/ERC20Token';
|
|
5
4
|
import { createEthereumProtocol, createEthereumProtocolOptions, EthereumProtocol } from './protocol/EthereumProtocol';
|
|
6
|
-
import { EthereumTransactionSignRequest } from './serializer/v3/schemas/definitions/transaction-sign-request-ethereum';
|
|
7
|
-
import { EthereumTypedTransactionSignRequest } from './serializer/v3/schemas/definitions/transaction-sign-request-ethereum-typed';
|
|
8
|
-
import { EthereumTransactionSignResponse } from './serializer/v3/schemas/definitions/transaction-sign-response-ethereum';
|
|
9
5
|
import { EthereumCryptoConfiguration } from './types/crypto';
|
|
10
6
|
import { ERC20TokenMetadata, EthereumProtocolNetwork, EthereumProtocolOptions, EthereumUnits } from './types/protocol';
|
|
11
7
|
import { EthereumRawUnsignedTransaction, EthereumSignedTransaction, EthereumTransactionCursor, EthereumTypedUnsignedTransaction, EthereumUnsignedTransaction } from './types/transaction';
|
|
12
8
|
export { EthereumModule };
|
|
13
9
|
export { EthereumProtocol, createEthereumProtocol, createEthereumProtocolOptions, ERC20Token, createERC20Token };
|
|
14
10
|
export { EtherscanBlockExplorer };
|
|
15
|
-
export { EthereumCryptoConfiguration, EthereumUnits, EthereumProtocolNetwork, EthereumProtocolOptions, ERC20TokenMetadata, EthereumUnsignedTransaction, EthereumTypedUnsignedTransaction, EthereumRawUnsignedTransaction, EthereumSignedTransaction,
|
|
16
|
-
export { erc20Tokens };
|
|
11
|
+
export { EthereumCryptoConfiguration, EthereumUnits, EthereumProtocolNetwork, EthereumProtocolOptions, ERC20TokenMetadata, EthereumUnsignedTransaction, EthereumTypedUnsignedTransaction, EthereumRawUnsignedTransaction, EthereumSignedTransaction, EthereumTransactionCursor };
|
package/v1/index.js
CHANGED
|
@@ -1,10 +1,8 @@
|
|
|
1
1
|
"use strict";
|
|
2
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
-
exports.
|
|
3
|
+
exports.EtherscanBlockExplorer = exports.createERC20Token = exports.createEthereumProtocolOptions = exports.createEthereumProtocol = exports.EthereumModule = void 0;
|
|
4
4
|
var EtherscanBlockExplorer_1 = require("./block-explorer/EtherscanBlockExplorer");
|
|
5
5
|
Object.defineProperty(exports, "EtherscanBlockExplorer", { enumerable: true, get: function () { return EtherscanBlockExplorer_1.EtherscanBlockExplorer; } });
|
|
6
|
-
var ERC20Tokens_1 = require("./module/ERC20Tokens");
|
|
7
|
-
Object.defineProperty(exports, "erc20Tokens", { enumerable: true, get: function () { return ERC20Tokens_1.erc20Tokens; } });
|
|
8
6
|
var EthereumModule_1 = require("./module/EthereumModule");
|
|
9
7
|
Object.defineProperty(exports, "EthereumModule", { enumerable: true, get: function () { return EthereumModule_1.EthereumModule; } });
|
|
10
8
|
var ERC20Token_1 = require("./protocol/erc20/ERC20Token");
|
package/v1/index.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../src/v1/index.ts"],"names":[],"mappings":";;;AAAA,kFAAgF;
|
|
1
|
+
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../src/v1/index.ts"],"names":[],"mappings":";;;AAAA,kFAAgF;AAwBvE,uGAxBA,+CAAsB,OAwBA;AAvB/B,0DAAwD;AAe/C,+FAfA,+BAAc,OAeA;AAdvB,0DAA0E;AAkBoB,iGAlBrF,6BAAgB,OAkBqF;AAjB9G,gEAAqH;AAiB1F,uGAjBlB,yCAAsB,OAiBkB;AAAE,8GAjBlB,gDAA6B,OAiBkB"}
|
|
@@ -1,16 +1,13 @@
|
|
|
1
1
|
import { AirGapModule, AirGapV3SerializerCompanion, ProtocolConfiguration } from '@airgap/module-kit';
|
|
2
2
|
import { BlockExplorer } from '@airgap/module-kit/block-explorer/block-explorer';
|
|
3
3
|
import { OfflineProtocol, OnlineProtocol } from '@airgap/module-kit/protocol/protocol';
|
|
4
|
-
|
|
5
|
-
export declare class EthereumModule implements AirGapModule<{
|
|
6
|
-
ProtocolNetwork: EthereumProtocolNetwork;
|
|
7
|
-
}> {
|
|
4
|
+
export declare class EthereumModule implements AirGapModule {
|
|
8
5
|
private readonly networkRegistries;
|
|
9
6
|
readonly supportedProtocols: Record<string, ProtocolConfiguration>;
|
|
10
7
|
constructor();
|
|
11
8
|
createOfflineProtocol(identifier: string): Promise<OfflineProtocol | undefined>;
|
|
12
|
-
createOnlineProtocol(identifier: string,
|
|
13
|
-
createBlockExplorer(identifier: string,
|
|
9
|
+
createOnlineProtocol(identifier: string, networkId?: string): Promise<OnlineProtocol | undefined>;
|
|
10
|
+
createBlockExplorer(identifier: string, networkId?: string): Promise<BlockExplorer | undefined>;
|
|
14
11
|
createV3SerializerCompanion(): Promise<AirGapV3SerializerCompanion>;
|
|
15
12
|
private createProtocol;
|
|
16
13
|
}
|
|
@@ -78,12 +78,11 @@ var EthereumModule = /** @class */ (function () {
|
|
|
78
78
|
});
|
|
79
79
|
});
|
|
80
80
|
};
|
|
81
|
-
EthereumModule.prototype.createOnlineProtocol = function (identifier,
|
|
82
|
-
var _a;
|
|
81
|
+
EthereumModule.prototype.createOnlineProtocol = function (identifier, networkId) {
|
|
83
82
|
return __awaiter(this, void 0, void 0, function () {
|
|
84
83
|
var network;
|
|
85
|
-
return __generator(this, function (
|
|
86
|
-
network =
|
|
84
|
+
return __generator(this, function (_a) {
|
|
85
|
+
network = this.networkRegistries[identifier].findNetwork(networkId);
|
|
87
86
|
if (network === undefined) {
|
|
88
87
|
throw new errors_1.ConditionViolationError(coinlib_core_1.Domain.ETHEREUM, 'Protocol network type not supported.');
|
|
89
88
|
}
|
|
@@ -91,16 +90,15 @@ var EthereumModule = /** @class */ (function () {
|
|
|
91
90
|
});
|
|
92
91
|
});
|
|
93
92
|
};
|
|
94
|
-
EthereumModule.prototype.createBlockExplorer = function (identifier,
|
|
95
|
-
var _a;
|
|
93
|
+
EthereumModule.prototype.createBlockExplorer = function (identifier, networkId) {
|
|
96
94
|
return __awaiter(this, void 0, void 0, function () {
|
|
97
95
|
var network;
|
|
98
|
-
return __generator(this, function (
|
|
99
|
-
network =
|
|
96
|
+
return __generator(this, function (_a) {
|
|
97
|
+
network = this.networkRegistries[identifier].findNetwork(networkId);
|
|
100
98
|
if (network === undefined) {
|
|
101
99
|
throw new errors_1.ConditionViolationError(coinlib_core_1.Domain.ETHEREUM, 'Block Explorer network type not supported.');
|
|
102
100
|
}
|
|
103
|
-
return [2 /*return*/, new EtherscanBlockExplorer_1.EtherscanBlockExplorer(
|
|
101
|
+
return [2 /*return*/, new EtherscanBlockExplorer_1.EtherscanBlockExplorer()];
|
|
104
102
|
});
|
|
105
103
|
});
|
|
106
104
|
};
|
|
@@ -117,7 +115,7 @@ var EthereumModule = /** @class */ (function () {
|
|
|
117
115
|
}
|
|
118
116
|
if (ERC20Tokens_1.erc20Tokens[identifier] !== undefined) {
|
|
119
117
|
var tokenMetadata = ERC20Tokens_1.erc20Tokens[identifier];
|
|
120
|
-
return (0, ERC20Token_1.createERC20Token)(tokenMetadata
|
|
118
|
+
return (0, ERC20Token_1.createERC20Token)(tokenMetadata);
|
|
121
119
|
}
|
|
122
120
|
throw new errors_1.ConditionViolationError(coinlib_core_1.Domain.ETHEREUM, "Protocol ".concat(identifier, " not supported."));
|
|
123
121
|
};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"EthereumModule.js","sourceRoot":"","sources":["../../../src/v1/module/EthereumModule.ts"],"names":[],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AAAA,qDAAkE;AAClE,sDAAqE;AACrE,iDAO2B;AAI3B,mFAAiF;AACjF,2DAAwG;AACxG,iEAAwG;AACxG,8EAAqF;AAGrF,6CAAmE;AAEnE;IAIE;;QACE,IAAM,eAAe,GAA0B,IAAI,kCAAqB,CAAC;YACvE,iBAAiB,EAAE,CAAC,oDAAiC,CAAC;SACvD,CAAC,CAAA;QACF,IAAM,oBAAoB,GAA0B,IAAI,kCAAqB,CAAC;YAC5E,iBAAiB,EAAE,CAAC,oDAAuC,CAAC;SAC7D,CAAC,CAAA;QAEF,IAAI,CAAC,iBAAiB,yBACnB,kCAAmB,CAAC,GAAG,IAAG,eAAe,OACvC,oCAAsB,CAAC,MAAM,CAC9B,UAAC,GAA0C,EAA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,CAAC,CAAA;IAC7F,CAAC;IACH,qBAAC;AAAD,CAAC,AA7DD,IA6DC;AA7DY,wCAAc"}
|
|
@@ -1,9 +1,7 @@
|
|
|
1
|
-
import {
|
|
2
|
-
import { EthereumProtocolNetwork, EthereumProtocolOptions
|
|
1
|
+
import { RecursivePartial } from '@airgap/module-kit';
|
|
2
|
+
import { EthereumProtocolNetwork, EthereumProtocolOptions } from '../types/protocol';
|
|
3
3
|
import { EthereumBaseProtocol } from './EthereumBaseProtocol';
|
|
4
4
|
export interface EthereumProtocol extends EthereumBaseProtocol {
|
|
5
|
-
getGasPrice(): Promise<Amount<EthereumUnits>>;
|
|
6
|
-
fetchTransactionCountForAddress(address: string): Promise<number>;
|
|
7
5
|
}
|
|
8
6
|
export declare function createEthereumProtocol(options?: RecursivePartial<EthereumProtocolOptions>): EthereumProtocol;
|
|
9
7
|
export declare const ETHEREUM_MAINNET_PROTOCOL_NETWORK: EthereumProtocolNetwork;
|
|
@@ -25,45 +25,8 @@ var __assign = (this && this.__assign) || function () {
|
|
|
25
25
|
};
|
|
26
26
|
return __assign.apply(this, arguments);
|
|
27
27
|
};
|
|
28
|
-
var __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, generator) {
|
|
29
|
-
function adopt(value) { return value instanceof P ? value : new P(function (resolve) { resolve(value); }); }
|
|
30
|
-
return new (P || (P = Promise))(function (resolve, reject) {
|
|
31
|
-
function fulfilled(value) { try { step(generator.next(value)); } catch (e) { reject(e); } }
|
|
32
|
-
function rejected(value) { try { step(generator["throw"](value)); } catch (e) { reject(e); } }
|
|
33
|
-
function step(result) { result.done ? resolve(result.value) : adopt(result.value).then(fulfilled, rejected); }
|
|
34
|
-
step((generator = generator.apply(thisArg, _arguments || [])).next());
|
|
35
|
-
});
|
|
36
|
-
};
|
|
37
|
-
var __generator = (this && this.__generator) || function (thisArg, body) {
|
|
38
|
-
var _ = { label: 0, sent: function() { if (t[0] & 1) throw t[1]; return t[1]; }, trys: [], ops: [] }, f, y, t, g;
|
|
39
|
-
return g = { next: verb(0), "throw": verb(1), "return": verb(2) }, typeof Symbol === "function" && (g[Symbol.iterator] = function() { return this; }), g;
|
|
40
|
-
function verb(n) { return function (v) { return step([n, v]); }; }
|
|
41
|
-
function step(op) {
|
|
42
|
-
if (f) throw new TypeError("Generator is already executing.");
|
|
43
|
-
while (_) try {
|
|
44
|
-
if (f = 1, y && (t = op[0] & 2 ? y["return"] : op[0] ? y["throw"] || ((t = y["return"]) && t.call(y), 0) : y.next) && !(t = t.call(y, op[1])).done) return t;
|
|
45
|
-
if (y = 0, t) op = [op[0] & 2, t.value];
|
|
46
|
-
switch (op[0]) {
|
|
47
|
-
case 0: case 1: t = op; break;
|
|
48
|
-
case 4: _.label++; return { value: op[1], done: false };
|
|
49
|
-
case 5: _.label++; y = op[1]; op = [0]; continue;
|
|
50
|
-
case 7: op = _.ops.pop(); _.trys.pop(); continue;
|
|
51
|
-
default:
|
|
52
|
-
if (!(t = _.trys, t = t.length > 0 && t[t.length - 1]) && (op[0] === 6 || op[0] === 2)) { _ = 0; continue; }
|
|
53
|
-
if (op[0] === 3 && (!t || (op[1] > t[0] && op[1] < t[3]))) { _.label = op[1]; break; }
|
|
54
|
-
if (op[0] === 6 && _.label < t[1]) { _.label = t[1]; t = op; break; }
|
|
55
|
-
if (t && _.label < t[2]) { _.label = t[2]; _.ops.push(op); break; }
|
|
56
|
-
if (t[2]) _.ops.pop();
|
|
57
|
-
_.trys.pop(); continue;
|
|
58
|
-
}
|
|
59
|
-
op = body.call(thisArg, _);
|
|
60
|
-
} catch (e) { op = [6, e]; y = 0; } finally { f = t = 0; }
|
|
61
|
-
if (op[0] & 5) throw op[1]; return { value: op[0] ? op[1] : void 0, done: true };
|
|
62
|
-
}
|
|
63
|
-
};
|
|
64
28
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
65
29
|
exports.createEthereumProtocolOptions = exports.ETHEREUM_MAINNET_PROTOCOL_NETWORK = exports.createEthereumProtocol = void 0;
|
|
66
|
-
var module_kit_1 = require("@airgap/module-kit");
|
|
67
30
|
var EtherscanInfoClient_1 = require("../clients/info/EtherscanInfoClient");
|
|
68
31
|
var AirGapNodeClient_1 = require("../clients/node/AirGapNodeClient");
|
|
69
32
|
var EthereumBaseProtocol_1 = require("./EthereumBaseProtocol");
|
|
@@ -75,27 +38,6 @@ var EthereumProtocolImpl = /** @class */ (function (_super) {
|
|
|
75
38
|
var completeOptions = createEthereumProtocolOptions(options.network);
|
|
76
39
|
return _super.call(this, new AirGapNodeClient_1.AirGapNodeClient(completeOptions.network.rpcUrl), new EtherscanInfoClient_1.EtherscanInfoClient(completeOptions.network.blockExplorerApi), completeOptions) || this;
|
|
77
40
|
}
|
|
78
|
-
// Custom
|
|
79
|
-
EthereumProtocolImpl.prototype.getGasPrice = function () {
|
|
80
|
-
return __awaiter(this, void 0, void 0, function () {
|
|
81
|
-
var gasPrice;
|
|
82
|
-
return __generator(this, function (_a) {
|
|
83
|
-
switch (_a.label) {
|
|
84
|
-
case 0: return [4 /*yield*/, this.nodeClient.getGasPrice()];
|
|
85
|
-
case 1:
|
|
86
|
-
gasPrice = _a.sent();
|
|
87
|
-
return [2 /*return*/, (0, module_kit_1.newAmount)(gasPrice, 'blockchain')];
|
|
88
|
-
}
|
|
89
|
-
});
|
|
90
|
-
});
|
|
91
|
-
};
|
|
92
|
-
EthereumProtocolImpl.prototype.fetchTransactionCountForAddress = function (address) {
|
|
93
|
-
return __awaiter(this, void 0, void 0, function () {
|
|
94
|
-
return __generator(this, function (_a) {
|
|
95
|
-
return [2 /*return*/, this.nodeClient.fetchTransactionCount(address)];
|
|
96
|
-
});
|
|
97
|
-
});
|
|
98
|
-
};
|
|
99
41
|
return EthereumProtocolImpl;
|
|
100
42
|
}(EthereumBaseProtocol_1.DefaultEthereumBaseProtocolImpl));
|
|
101
43
|
// Factory
|
|
@@ -108,7 +50,6 @@ exports.ETHEREUM_MAINNET_PROTOCOL_NETWORK = {
|
|
|
108
50
|
name: 'Mainnet',
|
|
109
51
|
type: 'mainnet',
|
|
110
52
|
rpcUrl: 'https://eth-rpc-proxy.airgap.prod.gke.papers.tech',
|
|
111
|
-
blockExplorerUrl: 'https://etherscan.io',
|
|
112
53
|
chainId: 1,
|
|
113
54
|
blockExplorerApi: 'https://api.etherscan.io'
|
|
114
55
|
};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"EthereumProtocol.js","sourceRoot":"","sources":["../../../src/v1/protocol/EthereumProtocol.ts"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"EthereumProtocol.js","sourceRoot":"","sources":["../../../src/v1/protocol/EthereumProtocol.ts"],"names":[],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;AAIA,2EAAyE;AACzE,qEAAmE;AAGnE,+DAA8F;AAO9F,iBAAiB;AAEjB;IAAmC,wCAA+B;IAChE,8BAAmB,OAAuD;QAAvD,wBAAA,EAAA,YAAuD;QACxE,IAAM,eAAe,GAA4B,6BAA6B,CAAC,OAAO,CAAC,OAAO,CAAC,CAAA;eAE/F,kBACE,IAAI,mCAAgB,CAAC,eAAe,CAAC,OAAO,CAAC,MAAM,CAAC,EACpD,IAAI,yCAAmB,CAAC,eAAe,CAAC,OAAO,CAAC,gBAAgB,CAAC,EACjE,eAAe,CAChB;IACH,CAAC;IACH,2BAAC;AAAD,CAAC,AAVD,CAAmC,sDAA+B,GAUjE;AAED,UAAU;AAEV,SAAgB,sBAAsB,CAAC,OAAuD;IAAvD,wBAAA,EAAA,YAAuD;IAC5F,OAAO,IAAI,oBAAoB,CAAC,OAAO,CAAC,CAAA;AAC1C,CAAC;AAFD,wDAEC;AAEY,QAAA,iCAAiC,GAA4B;IACxE,IAAI,EAAE,SAAS;IACf,IAAI,EAAE,SAAS;IACf,MAAM,EAAE,mDAAmD;IAC3D,OAAO,EAAE,CAAC;IACV,gBAAgB,EAAE,0BAA0B;CAC7C,CAAA;AAED,IAAM,iCAAiC,GAA4B,yCAAiC,CAAA;AAEpG,SAAgB,6BAA6B,CAAC,OAA8C;IAA9C,wBAAA,EAAA,YAA8C;IAC1F,OAAO;QACL,OAAO,wBAAO,iCAAiC,GAAK,OAAO,CAAE;KAC9D,CAAA;AACH,CAAC;AAJD,sEAIC"}
|
|
@@ -1,8 +1,8 @@
|
|
|
1
|
-
import { AirGapInterface
|
|
1
|
+
import { AirGapInterface } from '@airgap/module-kit';
|
|
2
2
|
import { ERC20TokenMetadata, EthereumProtocolNetwork, EthereumProtocolOptions } from '../../types/protocol';
|
|
3
3
|
import { EthereumBaseProtocol } from '../EthereumBaseProtocol';
|
|
4
4
|
export interface ERC20Token extends AirGapInterface<EthereumBaseProtocol<string>, 'SingleTokenSubProtocol'> {
|
|
5
5
|
}
|
|
6
|
-
export declare function createERC20Token(metadata: ERC20TokenMetadata
|
|
6
|
+
export declare function createERC20Token(metadata: ERC20TokenMetadata): ERC20Token;
|
|
7
7
|
export declare const ETHEREUM_ERC20_MAINNET_PROTOCOL_NETWORK: EthereumProtocolNetwork;
|
|
8
8
|
export declare function createERC20TokenOptions(network?: Partial<EthereumProtocolNetwork>): EthereumProtocolOptions;
|
|
@@ -397,9 +397,9 @@ var ERC20TokenImpl = /** @class */ (function (_super) {
|
|
|
397
397
|
return ERC20TokenImpl;
|
|
398
398
|
}(EthereumBaseProtocol_1.EthereumBaseProtocolImpl));
|
|
399
399
|
// Factory
|
|
400
|
-
function createERC20Token(metadata
|
|
400
|
+
function createERC20Token(metadata) {
|
|
401
401
|
var _a;
|
|
402
|
-
var protocolOptions = createERC20TokenOptions(
|
|
402
|
+
var protocolOptions = createERC20TokenOptions();
|
|
403
403
|
var tokenOptions = __assign(__assign({}, protocolOptions), { name: metadata.name, identifier: metadata.identifier, contractAddress: metadata.contractAddress, units: (_a = {},
|
|
404
404
|
_a[metadata.symbol] = {
|
|
405
405
|
symbol: { value: metadata.symbol, market: metadata.marketSymbol },
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"ERC20Token.js","sourceRoot":"","sources":["../../../../src/v1/protocol/erc20/ERC20Token.ts"],"names":[],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AAAA,qDAA+E;AAC/E,iHAA0F;AAC1F,aAAa;AACb,mGAAsF;AACtF,sDAAqG;AACrG,sDAAsD;AACtD,
|
|
1
|
+
{"version":3,"file":"ERC20Token.js","sourceRoot":"","sources":["../../../../src/v1/protocol/erc20/ERC20Token.ts"],"names":[],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AAAA,qDAA+E;AAC/E,iHAA0F;AAC1F,aAAa;AACb,mGAAsF;AACtF,sDAAqG;AACrG,sDAAsD;AACtD,iDAc2B;AAC3B,qCAAgF;AAGhF,8EAA4E;AAC5E,wEAA+F;AAe/F,2DAAyD;AACzD,gEAAwF;AACxF,wDAAuE;AAEvE,IAAM,mBAAmB,GAAG,OAAO,CAAC,iEAAiE,CAAC,CAAA;AAMtG,iBAAiB;AAEjB;IAA6B,kCAAgC;IAG3D,wBAAmB,UAA8B,EAAE,UAA8B,EAAE,OAA0B;QAA7G,YACE,kBAAM,UAAU,EAAE,UAAU,EAAE;YAC5B,OAAO,EAAE,OAAO,CAAC,OAAO;YAExB,IAAI,EAAE,OAAO,CAAC,IAAI;YAClB,UAAU,EAAE,OAAO,CAAC,UAAU;YAE9B,KAAK,EAAE,OAAO,CAAC,KAAK;YACpB,QAAQ,EAAE,OAAO,CAAC,QAAQ;SAC3B,CAAC,SAEH;QADC,KAAI,CAAC,eAAe,GAAG,OAAO,CAAC,eAAe,CAAA;;IAChD,CAAC;IAED,cAAc;IAED,gCAAO,GAApB;;;gBACE,sBAAO,OAAO,EAAA;;;KACf;IAEY,qCAAY,GAAzB;;;gBACE,sBAAO,kCAAmB,CAAC,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