@docknetwork/wallet-sdk-wasm 1.5.8 → 1.5.10

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.
Files changed (322) hide show
  1. package/lib/core/format-utils.js +0 -28
  2. package/lib/core/format-utils.mjs +1 -24
  3. package/lib/core/validation.js +1 -24
  4. package/lib/core/validation.mjs +2 -21
  5. package/lib/index.js +13 -32
  6. package/lib/index.mjs +13 -32
  7. package/lib/rpc-server.js +13 -32
  8. package/lib/rpc-server.mjs +13 -32
  9. package/lib/rpc-util.js +14 -0
  10. package/lib/rpc-util.mjs +14 -0
  11. package/lib/services/blockchain/index.js +3 -8
  12. package/lib/services/blockchain/index.mjs +3 -8
  13. package/lib/services/blockchain/service.js +37 -80
  14. package/lib/services/blockchain/service.mjs +38 -81
  15. package/lib/services/credential/bbs-revocation.js +4 -9
  16. package/lib/services/credential/bbs-revocation.mjs +3 -8
  17. package/lib/services/credential/bound-check.js +9 -4
  18. package/lib/services/credential/bound-check.mjs +9 -4
  19. package/lib/services/credential/index.js +11 -15
  20. package/lib/services/credential/index.mjs +11 -15
  21. package/lib/services/credential/service.js +18 -20
  22. package/lib/services/credential/service.mjs +15 -17
  23. package/lib/services/credential/utils.js +65 -28
  24. package/lib/services/credential/utils.mjs +62 -32
  25. package/lib/services/dids/index.js +11 -16
  26. package/lib/services/dids/index.mjs +11 -16
  27. package/lib/services/dids/keypair-utils.js +142 -0
  28. package/lib/services/dids/keypair-utils.mjs +113 -0
  29. package/lib/services/dids/service.js +16 -37
  30. package/lib/services/dids/service.mjs +16 -37
  31. package/lib/services/edv/index.js +8 -16
  32. package/lib/services/edv/index.mjs +8 -16
  33. package/lib/services/edv/service.js +10 -24
  34. package/lib/services/edv/service.mjs +10 -24
  35. package/lib/services/index.js +13 -37
  36. package/lib/services/index.mjs +13 -37
  37. package/lib/services/pex/service.js +2 -1
  38. package/lib/services/pex/service.mjs +2 -1
  39. package/lib/services/relay-service/configs.js +0 -1
  40. package/lib/services/relay-service/configs.mjs +0 -1
  41. package/lib/services/relay-service/index.android.js +0 -1
  42. package/lib/services/relay-service/index.android.mjs +0 -1
  43. package/lib/services/relay-service/index.ios.js +0 -1
  44. package/lib/services/relay-service/index.ios.mjs +0 -1
  45. package/lib/services/relay-service/index.js +0 -1
  46. package/lib/services/relay-service/index.mjs +0 -1
  47. package/lib/services/relay-service/service-rpc.js +0 -1
  48. package/lib/services/relay-service/service-rpc.mjs +0 -1
  49. package/lib/services/relay-service/service.js +0 -1
  50. package/lib/services/relay-service/service.mjs +0 -1
  51. package/lib/services/test-utils.js +0 -239
  52. package/lib/services/test-utils.mjs +1 -234
  53. package/lib/services/util-crypto/configs.js +0 -12
  54. package/lib/services/util-crypto/configs.mjs +0 -12
  55. package/lib/services/util-crypto/index.android.js +0 -3
  56. package/lib/services/util-crypto/index.android.mjs +0 -3
  57. package/lib/services/util-crypto/index.ios.js +0 -3
  58. package/lib/services/util-crypto/index.ios.mjs +0 -3
  59. package/lib/services/util-crypto/index.js +4 -7
  60. package/lib/services/util-crypto/index.mjs +4 -7
  61. package/lib/services/util-crypto/service-rpc.js +0 -23
  62. package/lib/services/util-crypto/service-rpc.mjs +0 -23
  63. package/lib/services/util-crypto/service.js +68 -61
  64. package/lib/services/util-crypto/service.mjs +50 -59
  65. package/lib/services/wallet/configs.js +0 -63
  66. package/lib/services/wallet/configs.mjs +1 -64
  67. package/lib/services/wallet/index.android.js +0 -1
  68. package/lib/services/wallet/index.android.mjs +0 -1
  69. package/lib/services/wallet/index.ios.js +0 -1
  70. package/lib/services/wallet/index.ios.mjs +0 -1
  71. package/lib/services/wallet/index.js +2 -12
  72. package/lib/services/wallet/index.mjs +2 -12
  73. package/lib/services/wallet/service-rpc.js +0 -77
  74. package/lib/services/wallet/service-rpc.mjs +0 -77
  75. package/lib/services/wallet/service.js +1 -215
  76. package/lib/services/wallet/service.mjs +1 -211
  77. package/lib/setup-nodejs.js +13 -32
  78. package/lib/setup-nodejs.mjs +13 -32
  79. package/lib/setup-tests.js +13 -32
  80. package/lib/setup-tests.mjs +13 -32
  81. package/lib/src/core/format-utils.d.ts +0 -5
  82. package/lib/src/core/format-utils.d.ts.map +1 -1
  83. package/lib/src/core/validation.d.ts +0 -3
  84. package/lib/src/core/validation.d.ts.map +1 -1
  85. package/lib/src/rpc-util.d.ts.map +1 -1
  86. package/lib/src/services/blockchain/service.d.ts +7 -3
  87. package/lib/src/services/blockchain/service.d.ts.map +1 -1
  88. package/lib/src/services/credential/bbs-revocation.d.ts.map +1 -1
  89. package/lib/src/services/credential/bound-check.d.ts +1 -1
  90. package/lib/src/services/credential/bound-check.d.ts.map +1 -1
  91. package/lib/src/services/credential/service.d.ts.map +1 -1
  92. package/lib/src/services/credential/utils.d.ts +2 -1
  93. package/lib/src/services/credential/utils.d.ts.map +1 -1
  94. package/lib/src/services/dids/keypair-utils.d.ts +15 -0
  95. package/lib/src/services/dids/keypair-utils.d.ts.map +1 -0
  96. package/lib/src/services/dids/service.d.ts +6 -6
  97. package/lib/src/services/dids/service.d.ts.map +1 -1
  98. package/lib/src/services/edv/service.d.ts.map +1 -1
  99. package/lib/src/services/pex/service.d.ts.map +1 -1
  100. package/lib/src/services/util-crypto/configs.d.ts +0 -3
  101. package/lib/src/services/util-crypto/configs.d.ts.map +1 -1
  102. package/lib/src/services/util-crypto/service.d.ts +3 -8
  103. package/lib/src/services/util-crypto/service.d.ts.map +1 -1
  104. package/lib/src/services/wallet/configs.d.ts +13 -0
  105. package/lib/src/services/wallet/configs.d.ts.map +1 -0
  106. package/lib/src/services/wallet/service.d.ts +1 -44
  107. package/lib/src/services/wallet/service.d.ts.map +1 -1
  108. package/lib/test-utils.js +0 -4
  109. package/lib/test-utils.mjs +1 -4
  110. package/lib/tsconfig.tsbuildinfo +1 -1
  111. package/package.json +6 -27
  112. package/readme.md +0 -61
  113. package/src/core/format-utils.test.js +1 -28
  114. package/src/core/format-utils.ts +0 -33
  115. package/src/core/validation.test.js +1 -33
  116. package/src/core/validation.ts +1 -25
  117. package/src/rpc-server.test.js +2 -9
  118. package/src/rpc-util.js +14 -0
  119. package/src/services/blockchain/index.test.js +4 -15
  120. package/src/services/blockchain/service.ts +39 -98
  121. package/src/services/credential/bbs-revocation.ts +2 -1
  122. package/src/services/credential/bound-check.test.ts +6 -6
  123. package/src/services/credential/bound-check.ts +4 -4
  124. package/src/services/credential/index.test.js +0 -2
  125. package/src/services/credential/service.ts +5 -2
  126. package/src/services/credential/utils.js +65 -23
  127. package/src/services/dids/index.test.js +9 -20
  128. package/src/services/dids/keypair-utils.js +111 -0
  129. package/src/services/dids/service.ts +7 -26
  130. package/src/services/edv/service.ts +2 -9
  131. package/src/services/index.js +0 -8
  132. package/src/services/pex/service.ts +7 -1
  133. package/src/services/test-utils.js +0 -207
  134. package/src/services/util-crypto/configs.ts +0 -12
  135. package/src/services/util-crypto/index.test.js +6 -83
  136. package/src/services/util-crypto/service-rpc.js +0 -20
  137. package/src/services/util-crypto/service.ts +62 -75
  138. package/src/services/wallet/configs.ts +1 -113
  139. package/src/services/wallet/index.test.js +0 -159
  140. package/src/services/wallet/service-rpc.js +1 -88
  141. package/src/services/wallet/service.ts +0 -258
  142. package/src/test-utils.js +0 -13
  143. package/lib/account-8fa95046.js +0 -774
  144. package/lib/account-e7156c51.js +0 -764
  145. package/lib/core/polkadot-utils.js +0 -119
  146. package/lib/core/polkadot-utils.mjs +0 -94
  147. package/lib/core/realm-schemas.js +0 -50
  148. package/lib/core/realm-schemas.mjs +0 -44
  149. package/lib/core/subscan.js +0 -75
  150. package/lib/core/subscan.mjs +0 -64
  151. package/lib/fixtures.js +0 -56
  152. package/lib/fixtures.mjs +0 -52
  153. package/lib/modules/account.js +0 -55
  154. package/lib/modules/account.mjs +0 -47
  155. package/lib/modules/accounts.js +0 -56
  156. package/lib/modules/accounts.mjs +0 -47
  157. package/lib/modules/data-migration.js +0 -72
  158. package/lib/modules/data-migration.mjs +0 -68
  159. package/lib/modules/wallet-backup.js +0 -82
  160. package/lib/modules/wallet-backup.mjs +0 -71
  161. package/lib/modules/wallet.js +0 -56
  162. package/lib/modules/wallet.mjs +0 -47
  163. package/lib/services/example/configs.js +0 -21
  164. package/lib/services/example/configs.mjs +0 -13
  165. package/lib/services/example/index.js +0 -18
  166. package/lib/services/example/index.mjs +0 -14
  167. package/lib/services/example/service-rpc.js +0 -25
  168. package/lib/services/example/service-rpc.mjs +0 -21
  169. package/lib/services/example/service.js +0 -25
  170. package/lib/services/example/service.mjs +0 -20
  171. package/lib/services/keyring/configs.js +0 -70
  172. package/lib/services/keyring/configs.mjs +0 -61
  173. package/lib/services/keyring/index.android.js +0 -22
  174. package/lib/services/keyring/index.android.mjs +0 -18
  175. package/lib/services/keyring/index.ios.js +0 -22
  176. package/lib/services/keyring/index.ios.mjs +0 -18
  177. package/lib/services/keyring/index.js +0 -16
  178. package/lib/services/keyring/index.mjs +0 -8
  179. package/lib/services/keyring/service-rpc.js +0 -65
  180. package/lib/services/keyring/service-rpc.mjs +0 -61
  181. package/lib/services/keyring/service.js +0 -84
  182. package/lib/services/keyring/service.mjs +0 -74
  183. package/lib/services/polkadot/configs.js +0 -17
  184. package/lib/services/polkadot/configs.mjs +0 -13
  185. package/lib/services/polkadot/index.android.js +0 -22
  186. package/lib/services/polkadot/index.android.mjs +0 -18
  187. package/lib/services/polkadot/index.ios.js +0 -22
  188. package/lib/services/polkadot/index.ios.mjs +0 -18
  189. package/lib/services/polkadot/index.js +0 -15
  190. package/lib/services/polkadot/index.mjs +0 -7
  191. package/lib/services/polkadot/service-rpc.js +0 -30
  192. package/lib/services/polkadot/service-rpc.mjs +0 -26
  193. package/lib/services/polkadot/service.js +0 -28
  194. package/lib/services/polkadot/service.mjs +0 -23
  195. package/lib/services/substrate/api-utils.js +0 -85
  196. package/lib/services/substrate/api-utils.mjs +0 -74
  197. package/lib/services/substrate/configs.js +0 -30
  198. package/lib/services/substrate/configs.mjs +0 -21
  199. package/lib/services/substrate/index.android.js +0 -22
  200. package/lib/services/substrate/index.android.mjs +0 -18
  201. package/lib/services/substrate/index.ios.js +0 -22
  202. package/lib/services/substrate/index.ios.mjs +0 -18
  203. package/lib/services/substrate/index.js +0 -37
  204. package/lib/services/substrate/index.mjs +0 -29
  205. package/lib/services/substrate/service-rpc.js +0 -37
  206. package/lib/services/substrate/service-rpc.mjs +0 -33
  207. package/lib/services/substrate/service.js +0 -115
  208. package/lib/services/substrate/service.mjs +0 -102
  209. package/lib/services/trust-registry/configs.js +0 -25
  210. package/lib/services/trust-registry/configs.mjs +0 -16
  211. package/lib/services/trust-registry/index.android.js +0 -19
  212. package/lib/services/trust-registry/index.android.mjs +0 -15
  213. package/lib/services/trust-registry/index.ios.js +0 -19
  214. package/lib/services/trust-registry/index.ios.mjs +0 -15
  215. package/lib/services/trust-registry/index.js +0 -33
  216. package/lib/services/trust-registry/index.mjs +0 -25
  217. package/lib/services/trust-registry/service-rpc.js +0 -29
  218. package/lib/services/trust-registry/service-rpc.mjs +0 -25
  219. package/lib/services/trust-registry/service.js +0 -89
  220. package/lib/services/trust-registry/service.mjs +0 -85
  221. package/lib/src/core/polkadot-utils.d.ts +0 -11
  222. package/lib/src/core/polkadot-utils.d.ts.map +0 -1
  223. package/lib/src/modules/account.d.ts +0 -60
  224. package/lib/src/modules/account.d.ts.map +0 -1
  225. package/lib/src/modules/accounts.d.ts +0 -49
  226. package/lib/src/modules/accounts.d.ts.map +0 -1
  227. package/lib/src/modules/data-migration.d.ts +0 -7
  228. package/lib/src/modules/data-migration.d.ts.map +0 -1
  229. package/lib/src/modules/wallet-backup.d.ts +0 -12
  230. package/lib/src/modules/wallet-backup.d.ts.map +0 -1
  231. package/lib/src/modules/wallet.d.ts +0 -134
  232. package/lib/src/modules/wallet.d.ts.map +0 -1
  233. package/lib/src/services/blockchain/index.d.ts +0 -2
  234. package/lib/src/services/blockchain/index.d.ts.map +0 -1
  235. package/lib/src/services/example/configs.d.ts +0 -9
  236. package/lib/src/services/example/configs.d.ts.map +0 -1
  237. package/lib/src/services/example/service.d.ts +0 -8
  238. package/lib/src/services/example/service.d.ts.map +0 -1
  239. package/lib/src/services/keyring/configs.d.ts +0 -39
  240. package/lib/src/services/keyring/configs.d.ts.map +0 -1
  241. package/lib/src/services/keyring/index.d.ts +0 -2
  242. package/lib/src/services/keyring/index.d.ts.map +0 -1
  243. package/lib/src/services/polkadot/configs.d.ts +0 -8
  244. package/lib/src/services/polkadot/configs.d.ts.map +0 -1
  245. package/lib/src/services/polkadot/index.d.ts +0 -2
  246. package/lib/src/services/polkadot/index.d.ts.map +0 -1
  247. package/lib/src/services/polkadot/service.d.ts +0 -8
  248. package/lib/src/services/polkadot/service.d.ts.map +0 -1
  249. package/lib/src/services/substrate/api-utils.d.ts +0 -14
  250. package/lib/src/services/substrate/api-utils.d.ts.map +0 -1
  251. package/lib/src/services/substrate/configs.d.ts +0 -16
  252. package/lib/src/services/substrate/configs.d.ts.map +0 -1
  253. package/lib/src/services/substrate/index.d.ts +0 -2
  254. package/lib/src/services/substrate/index.d.ts.map +0 -1
  255. package/lib/src/services/substrate/service.d.ts +0 -13
  256. package/lib/src/services/substrate/service.d.ts.map +0 -1
  257. package/lib/src/services/trust-registry/configs.d.ts +0 -6
  258. package/lib/src/services/trust-registry/configs.d.ts.map +0 -1
  259. package/lib/src/services/trust-registry/service.d.ts +0 -25
  260. package/lib/src/services/trust-registry/service.d.ts.map +0 -1
  261. package/lib/src/services/wallet/index.d.ts +0 -2
  262. package/lib/src/services/wallet/index.d.ts.map +0 -1
  263. package/lib/test/axiosMocks.js +0 -431
  264. package/lib/test/axiosMocks.mjs +0 -420
  265. package/lib/test/setup-test-state.js +0 -93
  266. package/lib/test/setup-test-state.mjs +0 -85
  267. package/src/core/polkadot-utils.js +0 -99
  268. package/src/core/realm-schemas.js +0 -42
  269. package/src/core/subscan.js +0 -62
  270. package/src/core/subscan.test.js +0 -56
  271. package/src/fixtures.js +0 -43
  272. package/src/modules/account.test.js +0 -56
  273. package/src/modules/account.ts +0 -128
  274. package/src/modules/accounts.test.js +0 -88
  275. package/src/modules/accounts.ts +0 -264
  276. package/src/modules/data-migration.test.js +0 -72
  277. package/src/modules/data-migration.ts +0 -86
  278. package/src/modules/wallet-backup.test.js +0 -24
  279. package/src/modules/wallet-backup.ts +0 -68
  280. package/src/modules/wallet.test.js +0 -227
  281. package/src/modules/wallet.ts +0 -424
  282. package/src/services/example/configs.js +0 -14
  283. package/src/services/example/index.js +0 -3
  284. package/src/services/example/index.test.js +0 -28
  285. package/src/services/example/service-rpc.js +0 -11
  286. package/src/services/example/service.ts +0 -18
  287. package/src/services/keyring/configs.ts +0 -110
  288. package/src/services/keyring/index.android.js +0 -3
  289. package/src/services/keyring/index.ios.js +0 -3
  290. package/src/services/keyring/index.js +0 -1
  291. package/src/services/keyring/index.test.js +0 -48
  292. package/src/services/keyring/service-rpc.js +0 -56
  293. package/src/services/keyring/service.ts +0 -111
  294. package/src/services/polkadot/configs.ts +0 -13
  295. package/src/services/polkadot/index.android.js +0 -3
  296. package/src/services/polkadot/index.ios.js +0 -3
  297. package/src/services/polkadot/index.js +0 -1
  298. package/src/services/polkadot/index.test.js +0 -52
  299. package/src/services/polkadot/service-rpc.js +0 -13
  300. package/src/services/polkadot/service.ts +0 -21
  301. package/src/services/substrate/api-utils.test.js +0 -73
  302. package/src/services/substrate/api-utils.ts +0 -66
  303. package/src/services/substrate/configs.ts +0 -34
  304. package/src/services/substrate/index.android.js +0 -3
  305. package/src/services/substrate/index.ios.js +0 -3
  306. package/src/services/substrate/index.js +0 -1
  307. package/src/services/substrate/index.test.js +0 -116
  308. package/src/services/substrate/service-rpc.js +0 -24
  309. package/src/services/substrate/service.ts +0 -117
  310. package/src/services/trust-registry/configs.ts +0 -14
  311. package/src/services/trust-registry/index.android.js +0 -3
  312. package/src/services/trust-registry/index.ios.js +0 -3
  313. package/src/services/trust-registry/index.js +0 -1
  314. package/src/services/trust-registry/index.test.js +0 -67
  315. package/src/services/trust-registry/service-rpc.js +0 -15
  316. package/src/services/trust-registry/service.ts +0 -94
  317. package/src/test/axiosMocks.js +0 -20
  318. package/src/test/fixtures/subscan-failure.json +0 -5
  319. package/src/test/fixtures/subscan-success.json +0 -370
  320. package/src/test/fixtures/subscan-too-many-requests.json +0 -9
  321. package/src/test/setup-test-state.js +0 -37
  322. package/src/test/test-wallet.test.js +0 -15
@@ -1,102 +0,0 @@
1
- import assert from 'assert';
2
- import BigNumber from 'bignumber.js';
3
- import BN from 'bn.js';
4
- import { DOCK_TOKEN_UNIT, getPlainDockAmount } from '../../core/format-utils.mjs';
5
- import { blockchainService } from '../blockchain/service.mjs';
6
- import { signAndSend } from './api-utils.mjs';
7
- import { serviceName, validation } from './configs.mjs';
8
- import { keyringService } from '../keyring/service.mjs';
9
- import '../../core/validation.mjs';
10
- import '../../types.mjs';
11
- import '@cosmjs/proto-signing';
12
- import '@docknetwork/cheqd-blockchain-api';
13
- import '@docknetwork/cheqd-blockchain-modules';
14
- import '@docknetwork/credential-sdk/modules';
15
- import '@docknetwork/credential-sdk/resolver';
16
- import '@docknetwork/crypto-wasm-ts/lib/index';
17
- import '@docknetwork/dock-blockchain-api';
18
- import '@docknetwork/dock-blockchain-modules';
19
- import 'events';
20
- import '../../core/logger.mjs';
21
- import '../../modules/event-manager.mjs';
22
- import '../util-crypto/service.mjs';
23
- import '@polkadot/keyring';
24
- import '@polkadot/util';
25
- import '@polkadot/util-crypto';
26
- import '../util-crypto/configs.mjs';
27
- import '@docknetwork/credential-sdk/types';
28
- import '../keyring/configs.mjs';
29
-
30
- // @ts-nocheck
31
- const FEE_ESTIMATION_BUFFER = 1.1;
32
- function getFeeWithBuffer(paymentFee) {
33
- assert(!!paymentFee, 'paymentFee is required');
34
- return new BigNumber(paymentFee).multipliedBy(FEE_ESTIMATION_BUFFER);
35
- }
36
- class SubstrateService {
37
- rpcMethods = [
38
- SubstrateService.prototype.getAccountBalance,
39
- SubstrateService.prototype.getFeeAmount,
40
- SubstrateService.prototype.sendTokens,
41
- ];
42
- constructor() {
43
- this.name = serviceName;
44
- }
45
- async getAccountBalance(params) {
46
- validation.getAccountBalance(params);
47
- console.log('ensure dock ready');
48
- await blockchainService.ensureBlockchainReady();
49
- console.log('ensure dock ready done');
50
- const { data: { free }, } = await blockchainService.dock.api.query.system.account(params.address);
51
- return free.toNumber() / DOCK_TOKEN_UNIT;
52
- }
53
- async getFeeAmount(params) {
54
- validation.getFeeAmount(params);
55
- const { toAddress, keyPair } = params;
56
- const amount = getPlainDockAmount(params.amount).toNumber();
57
- const account = keyringService.decryptKeyPair({
58
- jsonData: keyPair,
59
- password: '',
60
- });
61
- blockchainService.dock.setAccount(account);
62
- const extrinsic = blockchainService.dock.api.tx.balances.transfer(toAddress, amount);
63
- const paymentInfo = await extrinsic.paymentInfo(account);
64
- const fee = getFeeWithBuffer(paymentInfo.partialFee)
65
- .dividedBy(DOCK_TOKEN_UNIT)
66
- .toNumber();
67
- return fee;
68
- }
69
- async sendTokens(params) {
70
- validation.sendTokens(params);
71
- let { toAddress, fromAddress, keyPair } = params;
72
- let amount = getPlainDockAmount(params.amount).toNumber();
73
- const account = keyringService.decryptKeyPair({
74
- jsonData: keyPair,
75
- password: '',
76
- });
77
- const { dock } = blockchainService;
78
- dock.setAccount(account);
79
- if (params.transferAll) {
80
- const api = dock.api;
81
- const balances = await api.derive.balances.all(account.address);
82
- await api.tx.balances
83
- .transfer(fromAddress, balances.availableBalance)
84
- .paymentInfo(account)
85
- .then(async ({ partialFee }) => {
86
- const adjFee = getFeeWithBuffer(partialFee);
87
- let maxTransfer = balances.availableBalance.sub(new BN(adjFee.toNumber()));
88
- if (!maxTransfer.gt(api.consts.balances.existentialDeposit)) {
89
- throw new Error('balance too low');
90
- }
91
- amount = maxTransfer;
92
- });
93
- }
94
- return new Promise((resolve, reject) => {
95
- const extrinsic = dock.api.tx.balances.transfer(toAddress, amount);
96
- signAndSend(account, extrinsic).on('done', resolve).on('error', reject);
97
- });
98
- }
99
- }
100
- const substrateService = new SubstrateService();
101
-
102
- export { FEE_ESTIMATION_BUFFER, SubstrateService, getFeeWithBuffer, substrateService };
@@ -1,25 +0,0 @@
1
- 'use strict';
2
-
3
- Object.defineProperty(exports, '__esModule', { value: true });
4
-
5
- var assert = require('assert');
6
-
7
- function _interopDefaultLegacy (e) { return e && typeof e === 'object' && 'default' in e ? e : { 'default': e }; }
8
-
9
- var assert__default = /*#__PURE__*/_interopDefaultLegacy(assert);
10
-
11
- // @ts-nocheck
12
- const serviceName = 'trust-registry';
13
- const validation = {
14
- getTrustRegistries: params => {
15
- const { schemaId, issuerDID, verifierDID } = params;
16
- assert__default["default"](!!schemaId || !!issuerDID || !!verifierDID, 'no query option provider');
17
- },
18
- getTrustRegistryVerifiers: params => {
19
- const { trustRegistryId } = params;
20
- assert__default["default"](!!trustRegistryId, 'trustRegistryId is required');
21
- },
22
- };
23
-
24
- exports.serviceName = serviceName;
25
- exports.validation = validation;
@@ -1,16 +0,0 @@
1
- import assert from 'assert';
2
-
3
- // @ts-nocheck
4
- const serviceName = 'trust-registry';
5
- const validation = {
6
- getTrustRegistries: params => {
7
- const { schemaId, issuerDID, verifierDID } = params;
8
- assert(!!schemaId || !!issuerDID || !!verifierDID, 'no query option provider');
9
- },
10
- getTrustRegistryVerifiers: params => {
11
- const { trustRegistryId } = params;
12
- assert(!!trustRegistryId, 'trustRegistryId is required');
13
- },
14
- };
15
-
16
- export { serviceName, validation };
@@ -1,19 +0,0 @@
1
- 'use strict';
2
-
3
- Object.defineProperty(exports, '__esModule', { value: true });
4
-
5
- var services_trustRegistry_serviceRpc = require('./service-rpc.js');
6
- require('../rpc-service-client.js');
7
- require('assert');
8
- require('../../rpc-client.js');
9
- require('json-rpc-2.0');
10
- require('../../core/crypto.js');
11
- require('crypto');
12
- require('../../core/logger.js');
13
- require('../../logger.js');
14
- require('../../rpc-util.js');
15
- require('./configs.js');
16
-
17
- const trustRegistryService = new services_trustRegistry_serviceRpc.TrustRegistryServiceRpc();
18
-
19
- exports.trustRegistryService = trustRegistryService;
@@ -1,15 +0,0 @@
1
- import { TrustRegistryServiceRpc } from './service-rpc.mjs';
2
- import '../rpc-service-client.mjs';
3
- import 'assert';
4
- import '../../rpc-client.mjs';
5
- import 'json-rpc-2.0';
6
- import '../../core/crypto.mjs';
7
- import 'crypto';
8
- import '../../core/logger.mjs';
9
- import '../../logger.mjs';
10
- import '../../rpc-util.mjs';
11
- import './configs.mjs';
12
-
13
- const trustRegistryService = new TrustRegistryServiceRpc();
14
-
15
- export { trustRegistryService };
@@ -1,19 +0,0 @@
1
- 'use strict';
2
-
3
- Object.defineProperty(exports, '__esModule', { value: true });
4
-
5
- var services_trustRegistry_serviceRpc = require('./service-rpc.js');
6
- require('../rpc-service-client.js');
7
- require('assert');
8
- require('../../rpc-client.js');
9
- require('json-rpc-2.0');
10
- require('../../core/crypto.js');
11
- require('crypto');
12
- require('../../core/logger.js');
13
- require('../../logger.js');
14
- require('../../rpc-util.js');
15
- require('./configs.js');
16
-
17
- const trustRegistryService = new services_trustRegistry_serviceRpc.TrustRegistryServiceRpc();
18
-
19
- exports.trustRegistryService = trustRegistryService;
@@ -1,15 +0,0 @@
1
- import { TrustRegistryServiceRpc } from './service-rpc.mjs';
2
- import '../rpc-service-client.mjs';
3
- import 'assert';
4
- import '../../rpc-client.mjs';
5
- import 'json-rpc-2.0';
6
- import '../../core/crypto.mjs';
7
- import 'crypto';
8
- import '../../core/logger.mjs';
9
- import '../../logger.mjs';
10
- import '../../rpc-util.mjs';
11
- import './configs.mjs';
12
-
13
- const trustRegistryService = new TrustRegistryServiceRpc();
14
-
15
- export { trustRegistryService };
@@ -1,33 +0,0 @@
1
- 'use strict';
2
-
3
- Object.defineProperty(exports, '__esModule', { value: true });
4
-
5
- var services_trustRegistry_service = require('./service.js');
6
- require('./configs.js');
7
- require('assert');
8
- require('crypto');
9
- require('../blockchain/service.js');
10
- require('@cosmjs/proto-signing');
11
- require('@docknetwork/cheqd-blockchain-api');
12
- require('@docknetwork/cheqd-blockchain-modules');
13
- require('@docknetwork/credential-sdk/modules');
14
- require('@docknetwork/credential-sdk/resolver');
15
- require('@docknetwork/crypto-wasm-ts/lib/index');
16
- require('@docknetwork/dock-blockchain-api');
17
- require('@docknetwork/dock-blockchain-modules');
18
- require('events');
19
- require('../../core/logger.js');
20
- require('../../modules/event-manager.js');
21
- require('../util-crypto/service.js');
22
- require('@polkadot/keyring');
23
- require('@polkadot/util');
24
- require('@polkadot/util-crypto');
25
- require('../util-crypto/configs.js');
26
- require('../../core/validation.js');
27
- require('bignumber.js');
28
- require('../../types.js');
29
- require('@docknetwork/credential-sdk/types');
30
-
31
-
32
-
33
- exports.trustRegistryService = services_trustRegistry_service.trustRegistryService;
@@ -1,25 +0,0 @@
1
- export { trustRegistryService } from './service.mjs';
2
- import './configs.mjs';
3
- import 'assert';
4
- import 'crypto';
5
- import '../blockchain/service.mjs';
6
- import '@cosmjs/proto-signing';
7
- import '@docknetwork/cheqd-blockchain-api';
8
- import '@docknetwork/cheqd-blockchain-modules';
9
- import '@docknetwork/credential-sdk/modules';
10
- import '@docknetwork/credential-sdk/resolver';
11
- import '@docknetwork/crypto-wasm-ts/lib/index';
12
- import '@docknetwork/dock-blockchain-api';
13
- import '@docknetwork/dock-blockchain-modules';
14
- import 'events';
15
- import '../../core/logger.mjs';
16
- import '../../modules/event-manager.mjs';
17
- import '../util-crypto/service.mjs';
18
- import '@polkadot/keyring';
19
- import '@polkadot/util';
20
- import '@polkadot/util-crypto';
21
- import '../util-crypto/configs.mjs';
22
- import '../../core/validation.mjs';
23
- import 'bignumber.js';
24
- import '../../types.mjs';
25
- import '@docknetwork/credential-sdk/types';
@@ -1,29 +0,0 @@
1
- 'use strict';
2
-
3
- Object.defineProperty(exports, '__esModule', { value: true });
4
-
5
- var services_rpcServiceClient = require('../rpc-service-client.js');
6
- var services_trustRegistry_configs = require('./configs.js');
7
- require('assert');
8
- require('../../rpc-client.js');
9
- require('json-rpc-2.0');
10
- require('../../core/crypto.js');
11
- require('crypto');
12
- require('../../core/logger.js');
13
- require('../../logger.js');
14
- require('../../rpc-util.js');
15
-
16
- class TrustRegistryServiceRpc extends services_rpcServiceClient.RpcService {
17
- constructor() {
18
- super(services_trustRegistry_configs.serviceName);
19
- }
20
-
21
- async getTrustRegistries(params) {
22
- return this.call('getTrustRegistries', params);
23
- }
24
- async getTrustRegistryVerifiers(params) {
25
- return this.call('getTrustRegistryVerifiers', params);
26
- }
27
- }
28
-
29
- exports.TrustRegistryServiceRpc = TrustRegistryServiceRpc;
@@ -1,25 +0,0 @@
1
- import { RpcService } from '../rpc-service-client.mjs';
2
- import { serviceName } from './configs.mjs';
3
- import 'assert';
4
- import '../../rpc-client.mjs';
5
- import 'json-rpc-2.0';
6
- import '../../core/crypto.mjs';
7
- import 'crypto';
8
- import '../../core/logger.mjs';
9
- import '../../logger.mjs';
10
- import '../../rpc-util.mjs';
11
-
12
- class TrustRegistryServiceRpc extends RpcService {
13
- constructor() {
14
- super(serviceName);
15
- }
16
-
17
- async getTrustRegistries(params) {
18
- return this.call('getTrustRegistries', params);
19
- }
20
- async getTrustRegistryVerifiers(params) {
21
- return this.call('getTrustRegistryVerifiers', params);
22
- }
23
- }
24
-
25
- export { TrustRegistryServiceRpc };
@@ -1,89 +0,0 @@
1
- 'use strict';
2
-
3
- Object.defineProperty(exports, '__esModule', { value: true });
4
-
5
- var services_trustRegistry_configs = require('./configs.js');
6
- var crypto = require('crypto');
7
- var services_blockchain_service = require('../blockchain/service.js');
8
- require('assert');
9
- require('@cosmjs/proto-signing');
10
- require('@docknetwork/cheqd-blockchain-api');
11
- require('@docknetwork/cheqd-blockchain-modules');
12
- require('@docknetwork/credential-sdk/modules');
13
- require('@docknetwork/credential-sdk/resolver');
14
- require('@docknetwork/crypto-wasm-ts/lib/index');
15
- require('@docknetwork/dock-blockchain-api');
16
- require('@docknetwork/dock-blockchain-modules');
17
- require('events');
18
- require('../../core/logger.js');
19
- require('../../modules/event-manager.js');
20
- require('../util-crypto/service.js');
21
- require('@polkadot/keyring');
22
- require('@polkadot/util');
23
- require('@polkadot/util-crypto');
24
- require('../util-crypto/configs.js');
25
- require('../../core/validation.js');
26
- require('bignumber.js');
27
- require('../../types.js');
28
- require('@docknetwork/credential-sdk/types');
29
-
30
- // @ts-nocheck
31
- // TODO: Implement this function when the Trust Registry support is added to the SDK
32
- function typedHexDID(resolver, issuerDID) {
33
- return issuerDID;
34
- }
35
- // Trust Registry Service is not supported in the current version of the SDK
36
- class TrustRegistryService {
37
- constructor() {
38
- this.name = services_trustRegistry_configs.serviceName;
39
- }
40
- rpcMethods = [
41
- TrustRegistryService.prototype.getTrustRegistries,
42
- TrustRegistryService.prototype.getTrustRegistryVerifiers,
43
- ];
44
- async getTrustRegistries({ schemaId, issuerDID, verifierDID, }) {
45
- services_trustRegistry_configs.validation.getTrustRegistries({ schemaId, issuerDID, verifierDID });
46
- const queryOptions = {};
47
- if (schemaId) {
48
- const hashedId = crypto.createHash('sha256').update(schemaId).digest('hex');
49
- const schemaIdHex = '0x' + hashedId;
50
- queryOptions.schemaIds = {
51
- AnyOf: [schemaIdHex],
52
- };
53
- }
54
- if (issuerDID) {
55
- const issuerDIDMethodKey = typedHexDID(services_blockchain_service.blockchainService.dock.api, issuerDID);
56
- queryOptions.issuers = {
57
- AnyOf: [issuerDIDMethodKey],
58
- };
59
- }
60
- if (verifierDID) {
61
- const verifierDIDMethodKey = typedHexDID(services_blockchain_service.blockchainService.dock.api, verifierDID);
62
- queryOptions.verifiers = {
63
- AnyOf: [verifierDIDMethodKey],
64
- };
65
- }
66
- const registryInfo = await services_blockchain_service.blockchainService.dock.trustRegistry?.registriesInfo(queryOptions);
67
- return registryInfo;
68
- }
69
- async getTrustRegistryVerifiers({ schemaId, trustRegistryId, issuerDID }) {
70
- services_trustRegistry_configs.validation.getTrustRegistryVerifiers({ schemaId, trustRegistryId });
71
- const hashedId = crypto.createHash('sha256').update(schemaId).digest('hex');
72
- const schemaIdHex = '0x' + hashedId;
73
- const issuerDIDMethodKey = issuerDID
74
- ? typedHexDID(services_blockchain_service.blockchainService.dock.api, issuerDID)
75
- : null;
76
- const metadata = await services_blockchain_service.blockchainService.dock.trustRegistry.registrySchemasMetadata({
77
- schemaIds: [schemaIdHex],
78
- ...(issuerDIDMethodKey && {
79
- issuers: {
80
- AnyOf: [issuerDIDMethodKey],
81
- },
82
- }),
83
- }, trustRegistryId);
84
- return metadata[schemaIdHex]?.verifiers;
85
- }
86
- }
87
- const trustRegistryService = new TrustRegistryService();
88
-
89
- exports.trustRegistryService = trustRegistryService;
@@ -1,85 +0,0 @@
1
- import { serviceName, validation } from './configs.mjs';
2
- import { createHash } from 'crypto';
3
- import { blockchainService } from '../blockchain/service.mjs';
4
- import 'assert';
5
- import '@cosmjs/proto-signing';
6
- import '@docknetwork/cheqd-blockchain-api';
7
- import '@docknetwork/cheqd-blockchain-modules';
8
- import '@docknetwork/credential-sdk/modules';
9
- import '@docknetwork/credential-sdk/resolver';
10
- import '@docknetwork/crypto-wasm-ts/lib/index';
11
- import '@docknetwork/dock-blockchain-api';
12
- import '@docknetwork/dock-blockchain-modules';
13
- import 'events';
14
- import '../../core/logger.mjs';
15
- import '../../modules/event-manager.mjs';
16
- import '../util-crypto/service.mjs';
17
- import '@polkadot/keyring';
18
- import '@polkadot/util';
19
- import '@polkadot/util-crypto';
20
- import '../util-crypto/configs.mjs';
21
- import '../../core/validation.mjs';
22
- import 'bignumber.js';
23
- import '../../types.mjs';
24
- import '@docknetwork/credential-sdk/types';
25
-
26
- // @ts-nocheck
27
- // TODO: Implement this function when the Trust Registry support is added to the SDK
28
- function typedHexDID(resolver, issuerDID) {
29
- return issuerDID;
30
- }
31
- // Trust Registry Service is not supported in the current version of the SDK
32
- class TrustRegistryService {
33
- constructor() {
34
- this.name = serviceName;
35
- }
36
- rpcMethods = [
37
- TrustRegistryService.prototype.getTrustRegistries,
38
- TrustRegistryService.prototype.getTrustRegistryVerifiers,
39
- ];
40
- async getTrustRegistries({ schemaId, issuerDID, verifierDID, }) {
41
- validation.getTrustRegistries({ schemaId, issuerDID, verifierDID });
42
- const queryOptions = {};
43
- if (schemaId) {
44
- const hashedId = createHash('sha256').update(schemaId).digest('hex');
45
- const schemaIdHex = '0x' + hashedId;
46
- queryOptions.schemaIds = {
47
- AnyOf: [schemaIdHex],
48
- };
49
- }
50
- if (issuerDID) {
51
- const issuerDIDMethodKey = typedHexDID(blockchainService.dock.api, issuerDID);
52
- queryOptions.issuers = {
53
- AnyOf: [issuerDIDMethodKey],
54
- };
55
- }
56
- if (verifierDID) {
57
- const verifierDIDMethodKey = typedHexDID(blockchainService.dock.api, verifierDID);
58
- queryOptions.verifiers = {
59
- AnyOf: [verifierDIDMethodKey],
60
- };
61
- }
62
- const registryInfo = await blockchainService.dock.trustRegistry?.registriesInfo(queryOptions);
63
- return registryInfo;
64
- }
65
- async getTrustRegistryVerifiers({ schemaId, trustRegistryId, issuerDID }) {
66
- validation.getTrustRegistryVerifiers({ schemaId, trustRegistryId });
67
- const hashedId = createHash('sha256').update(schemaId).digest('hex');
68
- const schemaIdHex = '0x' + hashedId;
69
- const issuerDIDMethodKey = issuerDID
70
- ? typedHexDID(blockchainService.dock.api, issuerDID)
71
- : null;
72
- const metadata = await blockchainService.dock.trustRegistry.registrySchemasMetadata({
73
- schemaIds: [schemaIdHex],
74
- ...(issuerDIDMethodKey && {
75
- issuers: {
76
- AnyOf: [issuerDIDMethodKey],
77
- },
78
- }),
79
- }, trustRegistryId);
80
- return metadata[schemaIdHex]?.verifiers;
81
- }
82
- }
83
- const trustRegistryService = new TrustRegistryService();
84
-
85
- export { trustRegistryService };
@@ -1,11 +0,0 @@
1
- export function getKeyPairType(key: any): any;
2
- export function polkadotToKeydoc(polkadotKeys: any, controller?: any, keyPassphrase?: string): {
3
- id: string;
4
- controller: any;
5
- type: any;
6
- publicKeyBase58: any;
7
- privateKeyBase58: any;
8
- publicKeyMultibase: string;
9
- privateKeyMultibase: string;
10
- };
11
- //# sourceMappingURL=polkadot-utils.d.ts.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"polkadot-utils.d.ts","sourceRoot":"","sources":["../../../src/core/polkadot-utils.js"],"names":[],"mappings":"AAoBA,8CAWC;AAUD;;;;;;;;EAyDC"}
@@ -1,60 +0,0 @@
1
- import { Accounts } from './accounts';
2
- import { KeypairType } from '../types';
3
- export type AccountDetails = {
4
- id: string;
5
- name: string;
6
- type: KeypairType;
7
- address: string;
8
- correlations: any[];
9
- balance?: number;
10
- readonly?: boolean;
11
- meta?: {
12
- keypairNotFoundWarning: boolean;
13
- name: string;
14
- keypairType: KeypairType;
15
- derivationPath: string;
16
- };
17
- };
18
- /**
19
- * Account
20
- */
21
- export declare class Account {
22
- details: AccountDetails;
23
- address: string;
24
- name: string;
25
- accounts: Accounts;
26
- constructor(address: string, accounts: Accounts);
27
- /**
28
- * Get account for a given address
29
- * The account needs to exist in the wallet
30
- *
31
- * @example
32
- * const accounts = Account.with('some-address')
33
- * @param {string} address
34
- * @returns
35
- */
36
- static with(address: any, accounts: any): Account;
37
- /**
38
- *
39
- * @param {string} address
40
- * @returns
41
- */
42
- static withAsync(address: any, accounts: any): Promise<Account>;
43
- /**
44
- * @returns {Promise<void>}
45
- */
46
- loadDetails(): Promise<void>;
47
- getAddress(): string;
48
- getDetails(): AccountDetails;
49
- getBalance(skipFetch?: any): Promise<any>;
50
- export(password: string): Promise<any>;
51
- remove(): Promise<void>;
52
- update({ name }: {
53
- name: any;
54
- }): Promise<void>;
55
- getMnemonic(): Promise<any>;
56
- getKeyPair(): Promise<any>;
57
- getName(): string;
58
- getIcon(isAlternative?: boolean): Promise<any>;
59
- }
60
- //# sourceMappingURL=account.d.ts.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"account.d.ts","sourceRoot":"","sources":["../../../src/modules/account.ts"],"names":[],"mappings":"AAGA,OAAO,EAAC,QAAQ,EAAC,MAAM,YAAY,CAAC;AACpC,OAAO,EAAE,WAAW,EAAE,MAAM,UAAU,CAAC;AAEvC,MAAM,MAAM,cAAc,GAAG;IAC3B,EAAE,EAAE,MAAM,CAAC;IACX,IAAI,EAAE,MAAM,CAAC;IACb,IAAI,EAAE,WAAW,CAAC;IAClB,OAAO,EAAE,MAAM,CAAC;IAChB,YAAY,EAAE,GAAG,EAAE,CAAC;IACpB,OAAO,CAAC,EAAE,MAAM,CAAC;IACjB,QAAQ,CAAC,EAAE,OAAO,CAAC;IACnB,IAAI,CAAC,EAAE;QACL,sBAAsB,EAAE,OAAO,CAAC;QAChC,IAAI,EAAE,MAAM,CAAC;QACb,WAAW,EAAE,WAAW,CAAC;QACzB,cAAc,EAAE,MAAM,CAAC;KACxB,CAAA;CACF,CAAC;AAEF;;GAEG;AACH,qBAAa,OAAO;IAClB,OAAO,EAAE,cAAc,CAAC;IACxB,OAAO,EAAE,MAAM,CAAC;IAChB,IAAI,EAAE,MAAM,CAAC;IACb,QAAQ,EAAE,QAAQ,CAAC;gBAEP,OAAO,EAAE,MAAM,EAAE,QAAQ,EAAE,QAAQ;IAM/C;;;;;;;;OAQG;IACH,MAAM,CAAC,IAAI,CAAC,OAAO,KAAA,EAAE,QAAQ,KAAA;IAU7B;;;;OAIG;WACU,SAAS,CAAC,OAAO,KAAA,EAAE,QAAQ,KAAA;IAQxC;;OAEG;IACG,WAAW;IAKjB,UAAU;IAIV,UAAU,IAAI,cAAc;IAItB,UAAU,CAAC,SAAS,CAAC,KAAA;IAI3B,MAAM,CAAC,QAAQ,EAAE,MAAM;IAIvB,MAAM;IAIN,MAAM,CAAC,EAAC,IAAI,EAAC;;KAAA;IAOP,WAAW;IAQX,UAAU;IAQhB,OAAO,IAAI,MAAM;IAIjB,OAAO,CAAC,aAAa,CAAC,EAAE,OAAO,GAAG,OAAO,CAAC,GAAG,CAAC;CAG/C"}
@@ -1,49 +0,0 @@
1
- import { Wallet } from './wallet';
2
- import { KeypairType, WalletDocument, DocumentType } from '../types';
3
- import { EventManager } from './event-manager';
4
- import { AccountDetails, Account } from './account';
5
- export declare const AccountsEvents: {
6
- loaded: string;
7
- accountCreated: string;
8
- accountUpdated: string;
9
- accountRemoved: string;
10
- };
11
- export type CreateAccountParams = {
12
- name: string;
13
- type?: KeypairType;
14
- derivationPath?: string;
15
- mnemonic?: string;
16
- json?: string;
17
- password?: string;
18
- getIfExists?: boolean;
19
- hasBackup?: boolean;
20
- };
21
- export declare class Accounts {
22
- accounts: AccountDetails[];
23
- wallet: Wallet;
24
- eventManager: EventManager;
25
- static DocumentFilters: {
26
- mnemonicType: (item: WalletDocument) => boolean;
27
- currencyType: (item: WalletDocument) => boolean;
28
- };
29
- constructor({ wallet, walletService }?: {
30
- wallet: any;
31
- walletService: any;
32
- });
33
- load(): Promise<AccountDetails[]>;
34
- exportAccount(address: any, password: any): Promise<any>;
35
- importAccount(json: any, password: any): Promise<Account>;
36
- fetchBalance(address: any): Promise<any>;
37
- getBalance(address: any, skipFetch?: any): Promise<any>;
38
- getAccounts(): AccountDetails[];
39
- getAccountIcon(address: string, isAlternative: boolean): Promise<any>;
40
- getByAddress(address: string): Promise<AccountDetails>;
41
- findCorrelationByType(address: string, type: DocumentType, assertResult: boolean): Promise<any>;
42
- generateMnemonic(): Promise<string>;
43
- update(account: AccountDetails): Promise<void>;
44
- getOrCreate(params: CreateAccountParams): Promise<Account>;
45
- create(params: CreateAccountParams): Promise<Account>;
46
- remove(accountId: any): Promise<void>;
47
- static getInstance(options: any): Accounts;
48
- }
49
- //# sourceMappingURL=accounts.d.ts.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"accounts.d.ts","sourceRoot":"","sources":["../../../src/modules/accounts.ts"],"names":[],"mappings":"AAOA,OAAO,EAAC,MAAM,EAAe,MAAM,UAAU,CAAC;AAE9C,OAAO,EACL,WAAW,EACX,cAAc,EACd,YAAY,EAEb,MAAM,UAAU,CAAC;AAClB,OAAO,EAAC,YAAY,EAAC,MAAM,iBAAiB,CAAC;AAC7C,OAAO,EAAC,cAAc,EAAE,OAAO,EAAC,MAAM,WAAW,CAAC;AAGlD,eAAO,MAAM,cAAc;;;;;CAK1B,CAAC;AAEF,MAAM,MAAM,mBAAmB,GAAG;IAChC,IAAI,EAAE,MAAM,CAAC;IACb,IAAI,CAAC,EAAE,WAAW,CAAC;IACnB,cAAc,CAAC,EAAE,MAAM,CAAC;IACxB,QAAQ,CAAC,EAAE,MAAM,CAAC;IAClB,IAAI,CAAC,EAAE,MAAM,CAAC;IACd,QAAQ,CAAC,EAAE,MAAM,CAAC;IAClB,WAAW,CAAC,EAAE,OAAO,CAAC;IACtB,SAAS,CAAC,EAAE,OAAO,CAAC;CACrB,CAAC;AAEF,qBAAa,QAAQ;IACnB,QAAQ,EAAE,cAAc,EAAE,CAAC;IAC3B,MAAM,EAAE,MAAM,CAAC;IACf,YAAY,EAAE,YAAY,CAAC;IAC3B,MAAM,CAAC,eAAe;6BACC,cAAc;6BACd,cAAc;MACnC;gBAEU,EAAC,MAAM,EAAE,aAAa,EAAC;;;KAAK;IAOlC,IAAI;IAQJ,aAAa,CAAC,OAAO,KAAA,EAAE,QAAQ,KAAA;IAI/B,aAAa,CAAC,IAAI,KAAA,EAAE,QAAQ,KAAA;IAO5B,YAAY,CAAC,OAAO,KAAA;IAgCpB,UAAU,CAAC,OAAO,KAAA,EAAE,SAAS,CAAC,KAAA;IAgBpC,WAAW;IAIX,cAAc,CAAC,OAAO,EAAE,MAAM,EAAE,aAAa,EAAE,OAAO,GAAG,OAAO,CAAC,GAAG,CAAC;IAI/D,YAAY,CAAC,OAAO,EAAE,MAAM,GAAG,OAAO,CAAC,cAAc,CAAC;IAItD,qBAAqB,CACzB,OAAO,EAAE,MAAM,EACf,IAAI,EAAE,YAAY,EAClB,YAAY,EAAE,OAAO;IAcvB,gBAAgB,IAAI,OAAO,CAAC,MAAM,CAAC;IAI7B,MAAM,CAAC,OAAO,EAAE,cAAc;IAQ9B,WAAW,CAAC,MAAM,EAAE,mBAAmB;IAOvC,MAAM,CAAC,MAAM,EAAE,mBAAmB,GAAG,OAAO,CAAC,OAAO,CAAC;IA6ErD,MAAM,CAAC,SAAS,KAAA;IAWtB,MAAM,CAAC,WAAW,CAAC,OAAO,KAAA,GAAG,QAAQ;CAOtC"}
@@ -1,7 +0,0 @@
1
- import { Wallet } from './wallet';
2
- type MigrateParams = {
3
- wallet: Wallet;
4
- };
5
- export declare function migrate({ wallet }: MigrateParams): Promise<boolean>;
6
- export {};
7
- //# sourceMappingURL=data-migration.d.ts.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"data-migration.d.ts","sourceRoot":"","sources":["../../../src/modules/data-migration.ts"],"names":[],"mappings":"AAGA,OAAO,EAAC,MAAM,EAAC,MAAM,UAAU,CAAC;AAEhC,KAAK,aAAa,GAAG;IACnB,MAAM,EAAE,MAAM,CAAC;CAChB,CAAC;AAIF,wBAAsB,OAAO,CAAC,EAAC,MAAM,EAAC,EAAE,aAAa,oBA0EpD"}