@leofcoin/chain 1.3.12 → 1.4.0

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 (48) hide show
  1. package/block-worker.js +1 -1
  2. package/dist/browser/workers/block-worker.js +1977 -5692
  3. package/dist/browser/workers/machine-worker.js +1955 -5670
  4. package/dist/browser/workers/pool-worker.js +1636 -5531
  5. package/dist/browser/workers/transaction-worker.js +1626 -5521
  6. package/dist/chain.js +9865 -1196
  7. package/dist/client-80bc8156.js +491 -0
  8. package/dist/commonjs-7fe3c381.js +270 -0
  9. package/dist/generate-account-445db122.js +46 -0
  10. package/dist/index-57f93805.js +718 -0
  11. package/dist/{messages.browser.js → messages-bce1b91d-81af3b00.js} +26 -39
  12. package/dist/module/chain.js +9821 -1179
  13. package/dist/module/client-8031ec88.js +489 -0
  14. package/dist/module/commonjs-9005d5c0.js +268 -0
  15. package/dist/module/generate-account-489552b6.js +44 -0
  16. package/dist/module/index-ac2285c4.js +688 -0
  17. package/dist/module/messages-bce1b91d-eaf75d83.js +302 -0
  18. package/dist/module/node.js +6833 -2
  19. package/dist/module/workers/block-worker.js +3 -287
  20. package/dist/module/workers/machine-worker.js +3 -287
  21. package/dist/node.js +6845 -8
  22. package/dist/workers/machine-worker.js +1 -1
  23. package/package.json +11 -20
  24. package/src/chain.js +5 -12
  25. package/src/contract.js +2 -2
  26. package/src/machine.js +10 -7
  27. package/src/node.js +2 -2
  28. package/src/transaction.js +5 -5
  29. package/test/chain.js +5 -7
  30. package/test/index.js +1 -3
  31. package/tsconfig.js +15 -0
  32. package/workers/block-worker.js +40 -0
  33. package/workers/machine-worker.js +219 -0
  34. package/workers/pool-worker.js +28 -0
  35. package/workers/transaction-worker.js +20 -0
  36. package/workers/workers.js +9 -0
  37. package/dist/865.browser.js +0 -10
  38. package/dist/chain.browser.js +0 -66842
  39. package/dist/generate-account.browser.js +0 -50
  40. package/dist/multi-wallet.browser.js +0 -15
  41. package/dist/node.browser.js +0 -9858
  42. package/dist/pako.browser.js +0 -6900
  43. package/dist/peernet-swarm.browser.js +0 -839
  44. package/dist/storage.browser.js +0 -3724
  45. package/dist/wrtc.browser.js +0 -28
  46. package/rollup.config.js +0 -229
  47. package/src/standards/initializer.js +0 -10
  48. package/webpack.config.js +0 -109
@@ -1,50 +0,0 @@
1
- (self["webpackChunk_leofcoin_chain"] = self["webpackChunk_leofcoin_chain"] || []).push([[510],{
2
-
3
- /***/ 5162:
4
- /***/ (function(__unused_webpack_module, __webpack_exports__, __webpack_require__) {
5
-
6
- __webpack_require__.r(__webpack_exports__);
7
- /* harmony import */ var _leofcoin_multi_wallet__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(9755);
8
-
9
-
10
- /**
11
- * @params {String} network
12
- * @return {object} { identity, accounts, config }
13
- */
14
- /* harmony default export */ __webpack_exports__["default"] = (async network => {
15
- let wallet = new _leofcoin_multi_wallet__WEBPACK_IMPORTED_MODULE_0__["default"](network);
16
- /**
17
- * @type {string}
18
- */
19
- const mnemonic = await wallet.generate();
20
-
21
- wallet = new _leofcoin_multi_wallet__WEBPACK_IMPORTED_MODULE_0__["default"](network)
22
- await wallet.recover(mnemonic, network)
23
- /**
24
- * @type {object}
25
- */
26
- const account = wallet.account(0)
27
- /**
28
- * @type {object}
29
- */
30
- const external = account.external(0)
31
- const internal = account.internal(0)
32
-
33
- return {
34
- identity: {
35
- mnemonic,
36
- // multiWIF: wallet.export(),
37
- publicKey: external.publicKey,
38
- privateKey: external.privateKey,
39
- walletId: external.id
40
- },
41
- accounts: [['main account', external.address, internal.address]]
42
- // config: {
43
- // }
44
- }
45
- });
46
-
47
-
48
- /***/ })
49
-
50
- }])