Compare commits

..
12 Commits
13 changed files with 132 additions and 335 deletions
+109 -153
View File
@@ -116,28 +116,28 @@
}
},
"@nodelib/fs.scandir": {
"version": "2.1.3",
"resolved": "https://registry.npmjs.org/@nodelib/fs.scandir/-/fs.scandir-2.1.3.tgz",
"integrity": "sha512-eGmwYQn3gxo4r7jdQnkrrN6bY478C3P+a/y72IJukF8LjB6ZHeB3c+Ehacj3sYeSmUXGlnA67/PmbM9CVwL7Dw==",
"version": "2.1.4",
"resolved": "https://registry.npmjs.org/@nodelib/fs.scandir/-/fs.scandir-2.1.4.tgz",
"integrity": "sha512-33g3pMJk3bg5nXbL/+CY6I2eJDzZAni49PfJnL5fghPTggPvBd/pFNSgJsdAgWptuFu7qq/ERvOYFlhvsLTCKA==",
"dev": true,
"requires": {
"@nodelib/fs.stat": "2.0.3",
"@nodelib/fs.stat": "2.0.4",
"run-parallel": "^1.1.9"
}
},
"@nodelib/fs.stat": {
"version": "2.0.3",
"resolved": "https://registry.npmjs.org/@nodelib/fs.stat/-/fs.stat-2.0.3.tgz",
"integrity": "sha512-bQBFruR2TAwoevBEd/NWMoAAtNGzTRgdrqnYCc7dhzfoNvqPzLyqlEQnzZ3kVnNrSp25iyxE00/3h2fqGAGArA==",
"version": "2.0.4",
"resolved": "https://registry.npmjs.org/@nodelib/fs.stat/-/fs.stat-2.0.4.tgz",
"integrity": "sha512-IYlHJA0clt2+Vg7bccq+TzRdJvv19c2INqBSsoOLp1je7xjtr7J26+WXR72MCdvU9q1qTzIWDfhMf+DRvQJK4Q==",
"dev": true
},
"@nodelib/fs.walk": {
"version": "1.2.4",
"resolved": "https://registry.npmjs.org/@nodelib/fs.walk/-/fs.walk-1.2.4.tgz",
"integrity": "sha512-1V9XOY4rDW0rehzbrcqAmHnz8e7SKvX27gh8Gt2WgB0+pdzdiLV83p72kZPU+jvMbS1qU5mauP2iOvO8rhmurQ==",
"version": "1.2.6",
"resolved": "https://registry.npmjs.org/@nodelib/fs.walk/-/fs.walk-1.2.6.tgz",
"integrity": "sha512-8Broas6vTtW4GIXTAHDoE32hnN2M5ykgCpWGbuXHQ15vEMqr23pB76e/GZcYsZCHALv50ktd24qhEyKr6wBtow==",
"dev": true,
"requires": {
"@nodelib/fs.scandir": "2.1.3",
"@nodelib/fs.scandir": "2.1.4",
"fastq": "^1.6.0"
}
},
@@ -187,9 +187,9 @@
}
},
"@octokit/openapi-types": {
"version": "2.0.0",
"resolved": "https://registry.npmjs.org/@octokit/openapi-types/-/openapi-types-2.0.0.tgz",
"integrity": "sha512-J4bfM7lf8oZvEAdpS71oTvC1ofKxfEZgU5vKVwzZKi4QPiL82udjpseJwxPid9Pu2FNmyRQOX4iEj6W1iOSnPw==",
"version": "2.0.1",
"resolved": "https://registry.npmjs.org/@octokit/openapi-types/-/openapi-types-2.0.1.tgz",
"integrity": "sha512-9AuC04PUnZrjoLiw3uPtwGh9FE4Q3rTqs51oNlQ0rkwgE8ftYsOC+lsrQyvCvWm85smBbSc0FNRKKumvGyb44Q==",
"dev": true
},
"@octokit/plugin-paginate-rest": {
@@ -257,15 +257,77 @@
}
},
"@octokit/types": {
"version": "6.1.1",
"resolved": "https://registry.npmjs.org/@octokit/types/-/types-6.1.1.tgz",
"integrity": "sha512-btm3D6S7VkRrgyYF31etUtVY/eQ1KzrNRqhFt25KSe2mKlXuLXJilglRC6eDA2P6ou94BUnk/Kz5MPEolXgoiw==",
"version": "6.1.2",
"resolved": "https://registry.npmjs.org/@octokit/types/-/types-6.1.2.tgz",
"integrity": "sha512-LPCpcLbcky7fWfHCTuc7tMiSHFpFlrThJqVdaHgowBTMS0ijlZFfonQC/C1PrZOjD4xRCYgBqH9yttEATGE/nw==",
"dev": true,
"requires": {
"@octokit/openapi-types": "^2.0.0",
"@octokit/openapi-types": "^2.0.1",
"@types/node": ">= 8"
}
},
"@psf/bip21": {
"version": "2.0.1",
"resolved": "https://registry.npmjs.org/@psf/bip21/-/bip21-2.0.1.tgz",
"integrity": "sha512-U9c8xBV31n+D7qxOPBO0vQ015DNvKskWCUbVgoMfH5AUNHLYrSDWIrCx4P7v9etfdu6LpPdsYr53KDSAIk0b7Q==",
"requires": {
"qs": "^6.3.0"
}
},
"@psf/bip32-utils": {
"version": "0.13.1",
"resolved": "https://registry.npmjs.org/@psf/bip32-utils/-/bip32-utils-0.13.1.tgz",
"integrity": "sha512-5yM2o4TXW3gWKI3zxUFj9eeYqMYbA4Q1w+ptcfb+XnGpSZLrmwGtX48q8rApIKtikRceMEFXp1Jq6ed+bS+1nA==",
"requires": {
"keccak": "^1.3.0",
"nyc": "*",
"standard": "^11.0.1",
"tape": "*"
}
},
"@psf/bitcoincash-ops": {
"version": "2.0.0",
"resolved": "https://registry.npmjs.org/@psf/bitcoincash-ops/-/bitcoincash-ops-2.0.0.tgz",
"integrity": "sha512-M3PWqRpeJq6rli2NqWGbas76z9TrdGOmNuDFACBWBMctPucEAsFQY2AmyFHRSa7hEwythwvrPh9AG/n6ehmEog=="
},
"@psf/bitcoincashjs-lib": {
"version": "4.0.2",
"resolved": "https://registry.npmjs.org/@psf/bitcoincashjs-lib/-/bitcoincashjs-lib-4.0.2.tgz",
"integrity": "sha512-fTy9mW4H0NkQ+dojGtf+nPduA27F3V2YpBi5licYUVjdVRD/xpUCTgEN1cYRAupOaeDH/AYOWT0MWLkbQSTxAQ==",
"requires": {
"@psf/bitcoincash-ops": "^2.0.0",
"@psf/pushdata-bitcoin": "^1.2.2",
"bech32": "^1.1.2",
"bigi": "^1.4.0",
"bip66": "^1.1.0",
"bs58check": "^2.0.0",
"create-hash": "^1.1.0",
"create-hmac": "^1.1.3",
"ecurve": "^1.0.0",
"merkle-lib": "^2.0.10",
"randombytes": "^2.0.1",
"safe-buffer": "^5.0.1",
"typeforce": "^1.18.0",
"varuint-bitcoin": "^1.0.4",
"wif": "^2.0.1"
}
},
"@psf/coininfo": {
"version": "4.0.0",
"resolved": "https://registry.npmjs.org/@psf/coininfo/-/coininfo-4.0.0.tgz",
"integrity": "sha512-RwBc09790kbaOt8uZJMyvLqf1UziTd20FXu78bM8bMlkClnZQTJyNDdLCsFSBkJQYAJtGMkjdQ/o3/UaSC7c2Q==",
"requires": {
"safe-buffer": "^5.1.1"
}
},
"@psf/pushdata-bitcoin": {
"version": "1.2.2",
"resolved": "https://registry.npmjs.org/@psf/pushdata-bitcoin/-/pushdata-bitcoin-1.2.2.tgz",
"integrity": "sha512-e1qkZLJFU6Ldg7TMBgSkiR5U1NfpRgSIr2ppk8BeED/Q9wUc9DEVAjXfPMD65xgXdqnlyFEtLbpPMWwyydMVUQ==",
"requires": {
"@psf/bitcoincash-ops": "^2.0.0"
}
},
"@semantic-release/commit-analyzer": {
"version": "8.0.1",
"resolved": "https://registry.npmjs.org/@semantic-release/commit-analyzer/-/commit-analyzer-8.0.1.tgz",
@@ -362,9 +424,9 @@
}
},
"mime": {
"version": "2.4.6",
"resolved": "https://registry.npmjs.org/mime/-/mime-2.4.6.tgz",
"integrity": "sha512-RZKhC3EmpBchfTGBVb8fb+RL2cWyw/32lshnsETttkBAyAUXSGHxbEJWWRXc751DrIxG1q04b8QwMbAwkRPpUA==",
"version": "2.4.7",
"resolved": "https://registry.npmjs.org/mime/-/mime-2.4.7.tgz",
"integrity": "sha512-dhNd1uA2u397uQk3Nv5LM4lm93WYDUXFn3Fu291FJerns4jyTudqhIWe4W04YLy7Uk1tm1Ore04NpjRvQp/NPA==",
"dev": true
},
"universalify": {
@@ -1154,39 +1216,6 @@
"resolved": "https://registry.npmjs.org/bc-bip68/-/bc-bip68-1.0.5.tgz",
"integrity": "sha512-GzaMlN7pNthrY5BhReVhnfr4Ixx+GUSfyNRHYh0QiMUF0d0+0YaD8MpEdv6AjFBksg/zlqL1fVCBBm6PpTt2Rg=="
},
"bch-wallet-bridge-provider-interface": {
"version": "0.1.1",
"resolved": "https://registry.npmjs.org/bch-wallet-bridge-provider-interface/-/bch-wallet-bridge-provider-interface-0.1.1.tgz",
"integrity": "sha512-m8Mq/aJhZN11aoa91YyYs/B1GxWfpT5IIp64IU5VRgNxGXBuUiIfvybk4XQR+zrHaMW4SLrD1tI9n59ogmEw/A=="
},
"bch-wallet-bridge.js": {
"version": "github:web3bch/bch-wallet-bridge.js#f73558eaf3a98ba2a23de3c9cbbd582b30ff19eb",
"from": "github:web3bch/bch-wallet-bridge.js#master",
"requires": {
"bch-wallet-bridge-provider-interface": "^0.1.1",
"bchaddrjs": "^0.2.2",
"bitcoincashjs": "^0.1.10"
}
},
"bchaddrjs": {
"version": "0.2.3",
"resolved": "https://registry.npmjs.org/bchaddrjs/-/bchaddrjs-0.2.3.tgz",
"integrity": "sha512-0DVW8q3UFQFhrvt8Fowpkk+WvkYTZTSD1vGCQHrtMHZjRL6G/SoW0mgrREmgO1F/8TJ+Julri4UBWA8Gr7C5Yw==",
"requires": {
"bs58check": "^2.1.2",
"cashaddrjs": "^0.2.9"
},
"dependencies": {
"cashaddrjs": {
"version": "0.2.9",
"resolved": "https://registry.npmjs.org/cashaddrjs/-/cashaddrjs-0.2.9.tgz",
"integrity": "sha512-DhJF4iAH0/RM3UjHDHKRxzs09YGL9px+oTyizzydanhC7jTyM2aJ+aLKA96vZGTTWayvvr2iDF2l13lpqXiRFg==",
"requires": {
"big-integer": "^1.6.34"
}
}
}
},
"bchaddrjs-slp": {
"version": "0.2.8",
"resolved": "https://registry.npmjs.org/bchaddrjs-slp/-/bchaddrjs-slp-0.2.8.tgz",
@@ -1263,23 +1292,6 @@
"safe-buffer": "^5.0.1"
}
},
"bip21": {
"version": "github:Bitcoin-com/bip21#28f8d03a3a16ed11eb5b963248ed1be8c46c6d6f",
"from": "github:Bitcoin-com/bip21",
"requires": {
"qs": "^6.3.0"
}
},
"bip32-utils": {
"version": "github:Bitcoin-com/bip32-utils#b8a33ebd0a0ac39de7cd987e5c3f77a8c5d84e58",
"from": "github:Bitcoin-com/bip32-utils#0.13.1",
"requires": {
"keccak": "^1.3.0",
"nyc": "*",
"standard": "^11.0.1",
"tape": "*"
}
},
"bip38": {
"version": "2.0.3",
"resolved": "https://registry.npmjs.org/bip38/-/bip38-2.0.3.tgz",
@@ -1313,42 +1325,6 @@
"safe-buffer": "^5.0.1"
}
},
"bitcoincash-ops": {
"version": "github:christroutner/bitcoincash-ops#0041f2d945aa0e893fbbb5c2ebdf6254f6ff0555",
"from": "github:christroutner/bitcoincash-ops"
},
"bitcoincashjs": {
"version": "0.1.14",
"resolved": "https://registry.npmjs.org/bitcoincashjs/-/bitcoincashjs-0.1.14.tgz",
"integrity": "sha512-x0wMVSCZ56ZQnSQ+Xim7XfS0IYiOyOwo0pdMCmR+cDNB7zRhICFuH5i3lNdLSgUw1e7Pc3FmUlC9wruQNlYMnA=="
},
"bitcoincashjs-lib": {
"version": "github:christroutner/bitcoincashjs-lib#84dbcbce600af727a6f8b3eb23ebf6571651f367",
"from": "github:christroutner/bitcoincashjs-lib#master",
"requires": {
"bech32": "^1.1.2",
"bigi": "^1.4.0",
"bip66": "^1.1.0",
"bitcoincash-ops": "github:christroutner/bitcoincash-ops",
"bs58check": "^2.0.0",
"create-hash": "^1.1.0",
"create-hmac": "^1.1.3",
"ecurve": "^1.0.0",
"merkle-lib": "^2.0.10",
"pushdata-bitcoin": "github:Bitcoin-com/pushdata-bitcoin#1.2.1",
"randombytes": "^2.0.1",
"safe-buffer": "^5.0.1",
"typeforce": "^1.18.0",
"varuint-bitcoin": "^1.0.4",
"wif": "^2.0.1"
},
"dependencies": {
"bitcoincash-ops": {
"version": "github:christroutner/bitcoincash-ops#0041f2d945aa0e893fbbb5c2ebdf6254f6ff0555",
"from": "github:christroutner/bitcoincash-ops"
}
}
},
"bitcoinjs-message": {
"version": "2.1.0",
"resolved": "https://registry.npmjs.org/bitcoinjs-message/-/bitcoinjs-message-2.1.0.tgz",
@@ -1658,13 +1634,6 @@
"resolved": "https://registry.npmjs.org/co/-/co-4.6.0.tgz",
"integrity": "sha1-bqa989hTrlTMuOR7+gvz+QMfsYQ="
},
"coininfo": {
"version": "github:Bitcoin-com/coininfo#eece2c6141d08c3e7783929f2a1e1e681aa1a82c",
"from": "github:Bitcoin-com/coininfo",
"requires": {
"safe-buffer": "^5.1.1"
}
},
"color": {
"version": "3.0.0",
"resolved": "https://registry.npmjs.org/color/-/color-3.0.0.tgz",
@@ -1834,9 +1803,9 @@
}
},
"conventional-changelog-writer": {
"version": "4.0.18",
"resolved": "https://registry.npmjs.org/conventional-changelog-writer/-/conventional-changelog-writer-4.0.18.tgz",
"integrity": "sha512-mAQDCKyB9HsE8Ko5cCM1Jn1AWxXPYV0v8dFPabZRkvsiWUul2YyAqbIaoMKF88Zf2ffnOPSvKhboLf3fnjo5/A==",
"version": "4.1.0",
"resolved": "https://registry.npmjs.org/conventional-changelog-writer/-/conventional-changelog-writer-4.1.0.tgz",
"integrity": "sha512-WwKcUp7WyXYGQmkLsX4QmU42AZ1lqlvRW9mqoyiQzdD+rJWbTepdWoKJuwXTS+yq79XKnQNa93/roViPQrAQgw==",
"dev": true,
"requires": {
"compare-func": "^2.0.0",
@@ -3269,9 +3238,9 @@
"integrity": "sha512-Utm6CdzT+6xsDk2m8S6uL8VHxNwI6Jub+e9NYTcAms28T84pTa25GJQV9j0CY0N1rM8hK4x6grpF2BQf+2qwVA=="
},
"fastq": {
"version": "1.9.0",
"resolved": "https://registry.npmjs.org/fastq/-/fastq-1.9.0.tgz",
"integrity": "sha512-i7FVWL8HhVY+CTkwFxkN2mk3h+787ixS5S63eb78diVRc1MCssarHq3W5cj0av7YDSwmaV928RNag+U1etRQ7w==",
"version": "1.10.0",
"resolved": "https://registry.npmjs.org/fastq/-/fastq-1.10.0.tgz",
"integrity": "sha512-NL2Qc5L3iQEsyYzweq7qfgy5OtXCmGzGvhElGEd/SoFWEMOEczNh5s5ocaF01HDetxz+p8ecjNPA6cZxxIHmzA==",
"dev": true,
"requires": {
"reusify": "^1.0.4"
@@ -3334,12 +3303,12 @@
}
},
"find-versions": {
"version": "3.2.0",
"resolved": "https://registry.npmjs.org/find-versions/-/find-versions-3.2.0.tgz",
"integrity": "sha512-P8WRou2S+oe222TOCHitLy8zj+SIsVJh52VP4lvXkaFVnOFFdoWv1H1Jjvel1aI6NCFOAaeAVm8qrI0odiLcww==",
"version": "4.0.0",
"resolved": "https://registry.npmjs.org/find-versions/-/find-versions-4.0.0.tgz",
"integrity": "sha512-wgpWy002tA+wgmO27buH/9KzyEOQnKsG/R0yrcjPT9BOFm0zRBVQbZ95nRGXWMywS8YR5knRbpohio0bcJABxQ==",
"dev": true,
"requires": {
"semver-regex": "^2.0.0"
"semver-regex": "^3.1.2"
}
},
"flat": {
@@ -4637,9 +4606,9 @@
}
},
"marked": {
"version": "1.2.5",
"resolved": "https://registry.npmjs.org/marked/-/marked-1.2.5.tgz",
"integrity": "sha512-2AlqgYnVPOc9WDyWu7S5DJaEZsfk6dNh/neatQ3IHUW4QLutM/VPSH9lG7bif+XjFWc9K9XR3QvR+fXuECmfdA==",
"version": "1.2.7",
"resolved": "https://registry.npmjs.org/marked/-/marked-1.2.7.tgz",
"integrity": "sha512-No11hFYcXr/zkBvL6qFmAp1z6BKY3zqLMHny/JN/ey+al7qwCM2+CMBL9BOgqMxZU36fz4cCWfn2poWIf7QRXA==",
"dev": true
},
"marked-terminal": {
@@ -4744,9 +4713,9 @@
"dev": true
},
"meow": {
"version": "8.0.0",
"resolved": "https://registry.npmjs.org/meow/-/meow-8.0.0.tgz",
"integrity": "sha512-nbsTRz2fwniJBFgUkcdISq8y/q9n9VbiHYbfwklFh5V4V2uAcxtKQkDc0yCLPM/kP0d+inZBewn3zJqewHE7kg==",
"version": "8.1.0",
"resolved": "https://registry.npmjs.org/meow/-/meow-8.1.0.tgz",
"integrity": "sha512-fNWkgM1UVMey2kf24yLiccxLihc5W+6zVus3/N0b+VfnJgxV99E9u04X6NAiKdg6ED7DAQBX5sy36NM0QJZkWA==",
"dev": true,
"requires": {
"@types/minimist": "^1.2.0",
@@ -10021,19 +9990,6 @@
"integrity": "sha512-XRsRjdf+j5ml+y/6GKHPZbrF/8p2Yga0JPtdqTIY2Xe5ohJPD9saDJJLPvp9+NSBprVvevdXZybnj2cv8OEd0A==",
"dev": true
},
"pushdata-bitcoin": {
"version": "github:Bitcoin-com/pushdata-bitcoin#9b75eebe597853c6eeaec3e6c44b6d9c9cd7ee86",
"from": "github:Bitcoin-com/pushdata-bitcoin#1.2.1",
"requires": {
"bitcoincash-ops": "github:Bitcoin-com/bitcoincash-ops#2.0.0"
},
"dependencies": {
"bitcoincash-ops": {
"version": "github:Bitcoin-com/bitcoincash-ops#6ab82cc7326c67236f3b2d9d0457258ac2ef48e3",
"from": "github:Bitcoin-com/bitcoincash-ops#2.0.0"
}
}
},
"q": {
"version": "1.5.1",
"resolved": "https://registry.npmjs.org/q/-/q-1.5.1.tgz",
@@ -10554,9 +10510,9 @@
}
},
"semantic-release": {
"version": "17.3.0",
"resolved": "https://registry.npmjs.org/semantic-release/-/semantic-release-17.3.0.tgz",
"integrity": "sha512-enhDayMZRP4nWcWAMBFHHB7THRaIcRdUAZv3lxd65pXs2ttzay7IeCvRRrGayRWExtnY0ulwRz5Ycp88Dv/UeQ==",
"version": "17.3.1",
"resolved": "https://registry.npmjs.org/semantic-release/-/semantic-release-17.3.1.tgz",
"integrity": "sha512-NSdxvnBTklrRBYRexVUx44Hri9sTu9b8x+1HfWDGIWemDTFQfWOTbT1N3oy5l8WcZHodhRvtyI7gm50SfAa3Fg==",
"dev": true,
"requires": {
"@semantic-release/commit-analyzer": "^8.0.0",
@@ -10570,7 +10526,7 @@
"env-ci": "^5.0.0",
"execa": "^4.0.0",
"figures": "^3.0.0",
"find-versions": "^3.0.0",
"find-versions": "^4.0.0",
"get-stream": "^5.0.0",
"git-log-parser": "^1.2.0",
"hook-std": "^2.0.0",
@@ -10714,9 +10670,9 @@
}
},
"semver-regex": {
"version": "2.0.0",
"resolved": "https://registry.npmjs.org/semver-regex/-/semver-regex-2.0.0.tgz",
"integrity": "sha512-mUdIBBvdn0PLOeP3TEkMH7HHeUP3GjsXCwKarjv/kGmUFOYg1VqEemKhoQpWMu6X2I8kHeuVdGibLGkVK+/5Qw==",
"version": "3.1.2",
"resolved": "https://registry.npmjs.org/semver-regex/-/semver-regex-3.1.2.tgz",
"integrity": "sha512-bXWyL6EAKOJa81XG1OZ/Yyuq+oT0b2YLlxx7c+mrdYPaPbnj6WgVULXhinMIeZGufuUBu/eVRqXEhiv4imfwxA==",
"dev": true
},
"set-blocking": {
@@ -11664,9 +11620,9 @@
"integrity": "sha512-8Y75pvTYkLJW2hWQHXxoqRgV7qb9B+9vFEtidML+7koHUFapnVJAZ6cKs+Qjz5Aw3aZWHMC6u0wJE3At+nSGwA=="
},
"uglify-js": {
"version": "3.12.1",
"resolved": "https://registry.npmjs.org/uglify-js/-/uglify-js-3.12.1.tgz",
"integrity": "sha512-o8lHP20KjIiQe5b/67Rh68xEGRrc2SRsCuuoYclXXoC74AfSRGblU1HKzJWH3HxPZ+Ort85fWHpSX7KwBUC9CQ==",
"version": "3.12.4",
"resolved": "https://registry.npmjs.org/uglify-js/-/uglify-js-3.12.4.tgz",
"integrity": "sha512-L5i5jg/SHkEqzN18gQMTWsZk3KelRsfD1wUVNqtq0kzqWQqcJjyL8yc1o8hJgRrWqrAl2mUFbhfznEIoi7zi2A==",
"dev": true,
"optional": true
},
+6 -7
View File
@@ -35,25 +35,24 @@
"assert": "^2.0.0",
"axios": "^0.19.0",
"bc-bip68": "^1.0.5",
"bch-wallet-bridge.js": "github:web3bch/bch-wallet-bridge.js#master",
"bchaddrjs-slp": "^0.2.5",
"bigi": "^1.4.2",
"bignumber.js": "^9.0.0",
"bip-schnorr": "^0.3.0",
"bip21": "Bitcoin-com/bip21",
"bip32-utils": "Bitcoin-com/bip32-utils#0.13.1",
"@psf/bip21": "^2.0.1",
"@psf/bip32-utils": "^0.13.1",
"bip38": "^2.0.2",
"bip39": "^3.0.2",
"bip66": "^1.1.5",
"bitcoincash-ops": "christroutner/bitcoincash-ops",
"bitcoincashjs-lib": "christroutner/bitcoincashjs-lib#master",
"@psf/bitcoincash-ops": "^2.0.0",
"@psf/bitcoincashjs-lib": "^4.0.2",
"bitcoinjs-message": "^2.0.0",
"bs58": "^4.0.1",
"buffer": "^5.1.0",
"cashaddrjs": "^0.3.3",
"chalk": "^2.3.0",
"clear": "0.1.0",
"coininfo": "Bitcoin-com/coininfo",
"@psf/coininfo": "^4.0.0",
"commander": "^3.0.0",
"cp-file": "^7.0.0",
"ecurve": "^1.0.6",
@@ -88,7 +87,7 @@
"node-mocks-http": "^1.7.0",
"nyc": "^14.1.0",
"prettier": "^1.18.2",
"semantic-release": "^17.3.0",
"semantic-release": "^17.3.1",
"sinon": "^7.3.2"
},
"apidoc": {
+2 -2
View File
@@ -1,7 +1,7 @@
//const axios = require("axios")
const Bitcoin = require("bitcoincashjs-lib")
const Bitcoin = require("@psf/bitcoincashjs-lib")
const cashaddr = require("cashaddrjs")
const coininfo = require("coininfo")
const coininfo = require("@psf/coininfo")
class Address {
constructor(config) {
-81
View File
@@ -27,7 +27,6 @@ const ECPair = require("./ecpair")
const Script = require("./script")
const Price = require("./price")
const Socket = require("./socket")
const Wallet = require("./wallet")
const Schnorr = require("./schnorr")
const SLP = require("./slp/slp")
const IPFS = require("./ipfs")
@@ -110,7 +109,6 @@ class BCHJS {
this.TransactionBuilder.setAddress(this.Address)
this.Util = new Util(libConfig)
this.Socket = Socket
this.Wallet = Wallet
this.Schnorr = new Schnorr(libConfig)
this.SLP = new SLP(libConfig)
@@ -118,85 +116,6 @@ class BCHJS {
this.IPFS = new IPFS()
}
static BitboxShim() {
return BitboxShim
}
}
// Creat a shim so that all the endpoints match BITBOX SDK and this library
// can be used as a drop-in replacement for BITBOX.
class BitboxShim {
constructor(config) {
// Try to retrieve the REST API URL from different sources.
if (config && config.restURL && config.restURL !== "")
this.restURL = config.restURL
else if (process.env.RESTURL && process.env.RESTURL !== "")
this.restURL = process.env.RESTURL
else this.restURL = DEFAULT_REST_API
// Retrieve the apiToken
this.apiToken = "" // default value.
if (config && config.apiToken && config.apiToken !== "")
this.apiToken = config.apiToken
else if (process.env.BCHJSTOKEN && process.env.BCHJSTOKEN !== "")
this.apiToken = process.env.BCHJSTOKEN
const libConfig = {
restURL: this.restURL,
apiToken: this.apiToken
}
// Populate utility functions
this.Address = new Address(libConfig)
this.BitcoinCash = new BitcoinCash(this.Address)
this.Blockchain = new Blockchain(libConfig)
this.Crypto = Crypto
this.ECPair = ECPair
this.ECPair.setAddress(this.Address)
this.Generating = new Generating(libConfig)
this.HDNode = new HDNode(this.Address)
this.Mnemonic = new Mnemonic(this.Address)
this.Price = new Price()
this.Script = new Script()
this.TransactionBuilder = TransactionBuilder
this.TransactionBuilder.setAddress(this.Address)
this.Util = new Util(libConfig)
this.Socket = Socket
this.Wallet = Wallet
this.Schnorr = new Schnorr(libConfig)
// Populate the SLP endpoints.
this.SLP = new SLP(libConfig)
this.Address = this.SLP.Address
this.ECPair.toSLPAddress = this.SLP.ECPair.toSLPAddress
this.Util.list = this.SLP.Utils.list
this.Util.balancesForAddress = this.SLP.Utils.balancesForAddress
this.Util.balancesForToken = this.SLP.Utils.balancesForToken
this.Util.balance = this.SLP.Utils.balance
this.Util.validateTxid = this.SLP.Utils.validateTxid
this.Util.tokenStats = this.SLP.Utils.tokenStats
this.Util.transactions = this.SLP.Utils.transactions
this.Util.burnTotal = this.SLP.Utils.burnTotal
this.Util.decodeOpReturn = this.SLP.Utils.decodeOpReturn
this.Util.isTokenUtxo = this.SLP.Utils.isTokenUtxo
this.Util.tokenUtxoDetails = this.SLP.Utils.tokenUtxoDetails
this.Util.txDetails = this.SLP.Utils.txDetails
// Populate Full Node
this.Control = new Control(libConfig)
this.Mining = new Mining(libConfig)
this.RawTransactions = new RawTransactions(libConfig)
// Populate OpenBazaar endpoints
this.OpenBazaar = new OpenBazaar(libConfig)
// Bitcoin.com Ninsight indexer
this.Ninsight = new Ninsight()
this.Electrumx = new Electrumx(libConfig)
}
}
module.exports = BCHJS
+3 -3
View File
@@ -1,9 +1,9 @@
const Bitcoin = require("bitcoincashjs-lib")
const Bitcoin = require("@psf/bitcoincashjs-lib")
const sb = require("satoshi-bitcoin")
const bitcoinMessage = require("bitcoinjs-message")
const bs58 = require("bs58")
const bip21 = require("bip21")
const coininfo = require("coininfo")
const bip21 = require("@psf/bip21")
const coininfo = require("@psf/coininfo")
const bip38 = require("bip38")
const wif = require("wif")
+1 -1
View File
@@ -1,5 +1,5 @@
const randomBytes = require("randombytes")
const Bitcoin = require("bitcoincashjs-lib")
const Bitcoin = require("@psf/bitcoincashjs-lib")
class Crypto {
/**
+2 -2
View File
@@ -1,5 +1,5 @@
const Bitcoin = require("bitcoincashjs-lib")
const coininfo = require("coininfo")
const Bitcoin = require("@psf/bitcoincashjs-lib")
const coininfo = require("@psf/coininfo")
class ECPair {
static setAddress(address) {
+3 -3
View File
@@ -1,6 +1,6 @@
const Bitcoin = require("bitcoincashjs-lib")
const coininfo = require("coininfo")
const bip32utils = require("bip32-utils")
const Bitcoin = require("@psf/bitcoincashjs-lib")
const coininfo = require("@psf/coininfo")
const bip32utils = require("@psf/bip32-utils")
const bchaddrjs = require("bchaddrjs-slp")
class HDNode {
+1 -1
View File
@@ -1,6 +1,6 @@
const BIP39 = require("bip39")
const randomBytes = require("randombytes")
const Bitcoin = require("bitcoincashjs-lib")
const Bitcoin = require("@psf/bitcoincashjs-lib")
const Buffer = require("safe-buffer").Buffer
const wif = require("wif")
+2 -2
View File
@@ -1,5 +1,5 @@
const Bitcoin = require("bitcoincashjs-lib")
const opcodes = require("bitcoincash-ops")
const Bitcoin = require("@psf/bitcoincashjs-lib")
const opcodes = require("@psf/bitcoincash-ops")
class Script {
constructor() {
+2 -2
View File
@@ -1,5 +1,5 @@
const Bitcoin = require("bitcoincashjs-lib")
const coininfo = require("coininfo")
const Bitcoin = require("@psf/bitcoincashjs-lib")
const coininfo = require("@psf/coininfo")
const bip66 = require("bip66")
const bip68 = require("bc-bip68")
-77
View File
@@ -1,77 +0,0 @@
// import BCHWalletBridge from "bch-wallet-bridge.js"
class Wallet {
constructor(walletProvider) {
// this.bchWalletBridge = new BCHWalletBridge(walletProvider)
}
setWalletProvider(walletProvider) {
this.bchWalletBridge.walletProvider = walletProvider
}
getAddress(changeType, index, dAppId) {
return this.bchWalletBridge.getAddress(changeType, index, dAppId)
}
getAddressIndex(changeType, dAppId) {
return this.bchWalletBridge.getAddressIndex(changeType, dAppId)
}
getAddresses(changeType, startIndex, size, dAppId) {
return this.bchWalletBridge.getAddresses(
changeType,
startIndex,
size,
dAppId
)
}
getRedeemScript(p2shAddress, dAppId) {
return this.bchWalletBridge.getRedeemScript(p2shAddress, dAppId)
}
getRedeemScripts(dAppId) {
return this.bchWalletBridge.getRedeemScripts(dAppId)
}
addRedeemScript(redeemScript, dAppId) {
return this.bchWalletBridge.addRedeemScript(redeemScript, dAppId)
}
getUtxos(dAppId) {
return this.bchWalletBridge.getUtxos(dAppId)
}
getBalance(dAppId) {
return this.bchWalletBridge.getBalance(dAppId)
}
sign(address, dataToSign) {
return this.bchWalletBridge.sign(address, dataToSign)
}
buildTransaction(outputs, dAppId) {
return this.bchWalletBridge.buildTransaction(outputs, dAppId)
}
getProtocolVersion() {
return this.bchWalletBridge.getProtocolVersion()
}
getNetwork() {
return this.bchWalletBridge.getNetwork()
}
getFeePerByte() {
return this.bchWalletBridge.getFeePerByte()
}
getDefaultDAppId() {
return this.bchWalletBridge.getDefaultDAppId()
}
setDefaultDAppId(dAppId) {
return this.bchWalletBridge.setDefaultDAppId(dAppId)
}
}
module.exports = Wallet
+1 -1
View File
@@ -1,6 +1,6 @@
// Public npm libraries.
const assert = require("assert")
const Bitcoin = require("bitcoincashjs-lib")
const Bitcoin = require("@psf/bitcoincashjs-lib")
// Mocks
const fixtures = require("./fixtures/address.json")