Skip to content

Commit

Permalink
Merge pull request #6 from keepkey/fix-revert-develop-commits
Browse files Browse the repository at this point in the history
fix(common): revert develop commits
  • Loading branch information
pastaghost authored Mar 5, 2024
2 parents ff18916 + fadbeef commit 356ec44
Show file tree
Hide file tree
Showing 17 changed files with 43 additions and 170 deletions.
6 changes: 0 additions & 6 deletions examples/sandbox/index.html
Original file line number Diff line number Diff line change
Expand Up @@ -363,12 +363,6 @@ <h4>DigiByte</h4>
<button class="button button-outline" id="dgbTx">Tx</button>
<input type="text" id="dgbResults" />
</div>
<div class="container">
<h4>Zcash</h4>
<button class="button button-outline" id="zecAddr">Address</button>
<button class="button button-outline" id="zecTx">Tx</button>
<input type="text" id="zecResults" />
</div>

<div id="#pinModal" class="modal" aria-hidden="true">
<div class="modal-dialog">
Expand Down
105 changes: 0 additions & 105 deletions examples/sandbox/index.ts
Original file line number Diff line number Diff line change
Expand Up @@ -3172,111 +3172,6 @@ $dgbTx.on("click", async (e) => {
await wallet.loadDevice({ mnemonic });
});

/*
Zcash
* segwit: false
* multisig: true
*/
const $zecAddr = $("#zecAddr");
const $zecTx = $("#zecTx");
const $zecResults = $("#zecResults");

const zecBip44 = {
scriptType: core.BTCInputScriptType.SpendAddress,
addressNList: [0x80000000 + 44, 0x80000000 + 133, 0x80000000 + 0],
};

$zecAddr.on("click", async (e) => {
e.preventDefault();
if (!wallet) {
$zecResults.val("No wallet?");
return;
}
if (core.supportsBTC(wallet)) {
const res = await wallet.btcGetAddress({
addressNList: zecBip44.addressNList.concat([0, 0]),
coin: "Zcash",
scriptType: zecBip44.scriptType,
showDisplay: true,
});
$zecResults.val(res);
} else {
const label = await wallet.getLabel();
$zecResults.val(label + " does not support Dash");
}
});

$zecTx.on("click", async (e) => {
e.preventDefault();
if (!wallet) {
$zecResults.val("No wallet?");
return;
}

// use all mnemonic as there is no valid tx on alcohol abuse to use for Native signing
await wallet.loadDevice({
mnemonic: "all all all all all all all all all all all all",
});

if (core.supportsBTC(wallet)) {
const inputs = [
{
addressNList: zecBip44.addressNList.concat([0, 0]),
scriptType: core.BTCInputScriptType.SpendAddress,
amount: String(480000000),
vout: 15,
txid: "be150359df4123b379f1f12de978bfced92644645da17b97c7613879f4306a90",
tx: null,
hex: "01000000010b89406fd53f648dbf5cc7a46443794487684833c4bb7a067c86bdcf88362d4b010000006b4830450221009b38f01ca6b06c9fddb5d17ecaf306b140181074e06d50d38b4f61bc81c34d0202200eb9d37f551f6599a3488a8215cf53a347ced76b1dfb1c171855390a5576cd5a012102ee6d4720bc42ae172a1b1fbd1c0fccf4b9f364054f5ba1681f5e206c3b3a4d65ffffffff14486b9e7e750000001976a914f972645c9db830433fe9672b55452b4310c9501288ac0066a957160000001976a914584df25dff6f9eff9a86f2a49807249417913de288ac00bb4547170000001976a914cf934b123f7d1d0e6ecceff45dd881c6b3a1a7c588ac0020bcbe000000001976a91445ef856d2aa149ad66c4f98b115cd53ac88bcbbe88ac0063fe4e090000001976a91464d0c1a15eedb75f74a05b7282bbfc425e9a41ef88ac008b10e72e0300001976a91423cacb5aa41a375e057a38920396e889dd431e4d88ac6b884a1e0f0000001976a9149a32a47d48569012e3539a4be52c9436af9337a788ac003d7bc1210000001976a9147ba2fcb7d0d1321d8501019c2d9f68848e70bf7a88ac00389c1c0000000017a914d3b07c1aaea886f8ceddedec440623f812e49ddc87599e220afc0000001976a914e05ed2af3b5e20f3481e17fa26ef220a70237d7f88ac5475e2d91c0000001976a9147403f2f35e9c9e1f465a34d03afb7ff85f50770588acc9a9ce043c0000001976a914510fffca0668d410aea742e95a2fefa7952f695e88acf8f71c55890000001976a914916014ab503133671da74cfa18570debc332d63888acdfdeae45000000001976a9149cfc24e08cb9189839b0b5c973dec6cc1e1e662488ac8d10f92b954000001976a91433eed4c1b486b6c51824eab5a5d25dc47e0acc7e88ac00389c1c000000001976a914a4b8f22d44a76f96e035a75e01d55fc4cad081e188ac855ed4696f0000001976a9148d18463cb1e415242e49dfd3154a0edfcf16f25988ac439d5ff7180000001976a9144227b8ea4d92a707402bc96378a19ff5d83c5f9088ac9d2724980e0000001976a914b721f681fdbf9541cc5e2aed31a1fbb16a727fdf88ac893d1cf2e20000001976a91442f1d1103b1e9e10efdb5a0b1b88dfe627467dc288ac00000000",
},
{
addressNList: zecBip44.addressNList.concat([0, 0]),
scriptType: core.BTCInputScriptType.SpendAddress,
amount: String(10000000),
vout: 0,
txid: "528ec23eaf123282e9bce297ebb3edfb05e8b4d5875cbc9c271a98d72a202340",
tx: null,
hex: "0100000001442377be8a2c1d8769dd417382f8ac1a35f33c86de89e2dcf997522e7ae9e6b7000000006a473044022004f4072085e7a9e1f84cb77653f02f7a5b301b3d3514fe750e86d42f617c429a0220338f779601a38ff18c7adfd1a1ccd8f723de12ff4f9c41b7b72f1c0f6f4738ac012103723d91852ec39078fb9d167fe2c4e86be1325057d707ab69ce625699d86a537fffffffff0280969800000000001976a914a4b8f22d44a76f96e035a75e01d55fc4cad081e188ac66e00c16000000001976a9144afe51fbe5fb6cd4814ce74b31d7535a5f4a63bc88ac00000000",
},
];

const outputs = [
{
address: "t1Lxv5Qw3aKPkvB7v1GK65uqsTYErRr8nY2",
addressType: null,
scriptType: core.BTCOutputScriptType.PayToMultisig,
amount: String(400000000),
isChange: false,
},
{
address: "t1Lxv5Qw3aKPkvB7v1GK65uqsTYErRr8nY2",
addressType: null,
scriptType: core.BTCOutputScriptType.PayToAddress,
relpath: "1/9",
amount: String(90000000),
isChange: true,
index: 9,
},
];

const res = await wallet.btcSignTx({
coin: "Zcash",
inputs,
outputs,
version: 1,
locktime: 0,
});
$zecResults.val(res.serializedTx);
} else {
const label = await wallet.getLabel();
$zecResults.val(label + " does not support Dash");
}

// set mnemonic back to alcohol abuse
await wallet.loadDevice({ mnemonic });
});

/*
Bitcoin (segwit)
* segwit: true
Expand Down
10 changes: 5 additions & 5 deletions examples/sandbox/package.json
Original file line number Diff line number Diff line change
@@ -1,10 +1,10 @@
{
"browserslist": "> 0.5%, last 2 versions, not dead",
"dependencies": {
"@keepkey/hdwallet-core": "1.53.12",
"@keepkey/hdwallet-keepkey-tcp": "1.53.12",
"@keepkey/hdwallet-keepkey-webusb": "1.53.12",
"@keepkey/hdwallet-native": "1.53.12",
"@keepkey/hdwallet-core": "1.53.9",
"@keepkey/hdwallet-keepkey-tcp": "1.53.9",
"@keepkey/hdwallet-keepkey-webusb": "1.53.9",
"@keepkey/hdwallet-native": "1.53.9",
"@metamask/eth-sig-util": "^7.0.0",
"bip32": "^2.0.4",
"eip-712": "^1.0.0",
Expand All @@ -31,5 +31,5 @@
"clean": "rm -rf dist node_modules public .parcel-cache",
"dev": "yarn parcel index.html"
},
"version": "1.53.12"
"version": "1.53.13"
}
10 changes: 5 additions & 5 deletions integration/package.json
Original file line number Diff line number Diff line change
@@ -1,9 +1,9 @@
{
"dependencies": {
"@keepkey/hdwallet-core": "1.53.12",
"@keepkey/hdwallet-keepkey": "1.53.12",
"@keepkey/hdwallet-keepkey-nodewebusb": "1.53.12",
"@keepkey/hdwallet-keepkey-tcp": "1.53.12",
"@keepkey/hdwallet-core": "1.53.13",
"@keepkey/hdwallet-keepkey": "1.53.13",
"@keepkey/hdwallet-keepkey-nodewebusb": "1.53.13",
"@keepkey/hdwallet-keepkey-tcp": "1.53.13",
"@keepkey/hdwallet-native": "1.53.9",
"fast-json-stable-stringify": "^2.1.0",
"msw": "^0.27.1",
Expand All @@ -18,5 +18,5 @@
"dev": "lerna run test --scope integration --parallel --include-filtered-dependencies",
"test": "yarn jest --verbose"
},
"version": "1.53.12"
"version": "1.53.13"
}
2 changes: 1 addition & 1 deletion lerna.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"lerna": "5.2.0",
"version": "1.53.12",
"version": "1.53.13",
"npmClient": "yarn",
"useWorkspaces": true,
"command": {
Expand Down
1 change: 0 additions & 1 deletion package.json
Original file line number Diff line number Diff line change
Expand Up @@ -53,7 +53,6 @@
"jest-junit": "^12.0.0",
"lerna": "^5.2.0",
"prettier": "^2.0.5",
"punycode": "^1.4.1",
"stream-browserify": "^3.0.0",
"ts-jest": "^26.5.5",
"typescript": "^5.2.2",
Expand Down
5 changes: 2 additions & 3 deletions packages/hdwallet-core/package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "@keepkey/hdwallet-core",
"version": "1.53.12",
"version": "1.53.13",
"license": "MIT",
"publishConfig": {
"access": "public"
Expand All @@ -24,6 +24,5 @@
"devDependencies": {
"@types/google-protobuf": "^3.15.1",
"@types/lodash": "^4.14.168"
},
"gitHead": "56ddebbaf88004facedb7bb78e5f4bdb954931d0"
}
}
9 changes: 4 additions & 5 deletions packages/hdwallet-keepkey-chromeusb/package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "@keepkey/hdwallet-keepkey-chromeusb",
"version": "1.53.12",
"version": "1.53.13",
"license": "MIT",
"publishConfig": {
"access": "public"
Expand All @@ -14,8 +14,7 @@
"prepublishOnly": "yarn clean && yarn build"
},
"dependencies": {
"@keepkey/hdwallet-core": "1.53.12",
"@keepkey/hdwallet-keepkey": "1.53.12"
},
"gitHead": "56ddebbaf88004facedb7bb78e5f4bdb954931d0"
"@keepkey/hdwallet-core": "1.53.13",
"@keepkey/hdwallet-keepkey": "1.53.13"
}
}
7 changes: 3 additions & 4 deletions packages/hdwallet-keepkey-electron/package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "@keepkey/hdwallet-keepkey-electron",
"version": "1.53.12",
"version": "1.53.13",
"license": "MIT",
"publishConfig": {
"access": "public"
Expand All @@ -14,7 +14,7 @@
"prepublishOnly": "yarn clean && yarn build"
},
"dependencies": {
"@keepkey/hdwallet-keepkey": "1.53.12",
"@keepkey/hdwallet-keepkey": "1.53.13",
"uuid": "^8.3.2"
},
"peerDependencies": {
Expand All @@ -23,6 +23,5 @@
"devDependencies": {
"@types/uuid": "^8.3.0",
"electron": "^12.0.9"
},
"gitHead": "56ddebbaf88004facedb7bb78e5f4bdb954931d0"
}
}
7 changes: 3 additions & 4 deletions packages/hdwallet-keepkey-nodehid/package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "@keepkey/hdwallet-keepkey-nodehid",
"version": "1.53.12",
"version": "1.53.13",
"license": "MIT",
"publishConfig": {
"access": "public"
Expand All @@ -14,13 +14,12 @@
"prepublishOnly": "yarn clean && yarn build"
},
"dependencies": {
"@keepkey/hdwallet-keepkey": "1.53.12"
"@keepkey/hdwallet-keepkey": "1.53.13"
},
"peerDependencies": {
"node-hid": "^2.1.1"
},
"devDependencies": {
"@types/node-hid": "^1.3.1"
},
"gitHead": "56ddebbaf88004facedb7bb78e5f4bdb954931d0"
}
}
9 changes: 4 additions & 5 deletions packages/hdwallet-keepkey-nodewebusb/package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "@keepkey/hdwallet-keepkey-nodewebusb",
"version": "1.53.12",
"version": "1.53.13",
"license": "MIT",
"publishConfig": {
"access": "public"
Expand All @@ -14,14 +14,13 @@
"prepublishOnly": "yarn clean && yarn build"
},
"dependencies": {
"@keepkey/hdwallet-core": "1.53.12",
"@keepkey/hdwallet-keepkey": "1.53.12"
"@keepkey/hdwallet-core": "1.53.13",
"@keepkey/hdwallet-keepkey": "1.53.13"
},
"peerDependencies": {
"usb": "^2.3.1"
},
"devDependencies": {
"usb": "^2.3.1"
},
"gitHead": "56ddebbaf88004facedb7bb78e5f4bdb954931d0"
}
}
9 changes: 4 additions & 5 deletions packages/hdwallet-keepkey-tcp/package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "@keepkey/hdwallet-keepkey-tcp",
"version": "1.53.12",
"version": "1.53.13",
"license": "MIT",
"publishConfig": {
"access": "public"
Expand All @@ -14,9 +14,8 @@
"prepublishOnly": "yarn clean && yarn build"
},
"dependencies": {
"@keepkey/hdwallet-core": "1.53.12",
"@keepkey/hdwallet-keepkey": "1.53.12",
"@keepkey/hdwallet-core": "1.53.13",
"@keepkey/hdwallet-keepkey": "1.53.13",
"axios": "^0.21.1"
},
"gitHead": "56ddebbaf88004facedb7bb78e5f4bdb954931d0"
}
}
9 changes: 4 additions & 5 deletions packages/hdwallet-keepkey-webusb/package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "@keepkey/hdwallet-keepkey-webusb",
"version": "1.53.12",
"version": "1.53.13",
"license": "MIT",
"publishConfig": {
"access": "public"
Expand All @@ -14,11 +14,10 @@
"prepublishOnly": "yarn clean && yarn build"
},
"dependencies": {
"@keepkey/hdwallet-core": "1.53.12",
"@keepkey/hdwallet-keepkey": "1.53.12"
"@keepkey/hdwallet-core": "1.53.13",
"@keepkey/hdwallet-keepkey": "1.53.13"
},
"devDependencies": {
"@types/w3c-web-usb": "^1.0.4"
},
"gitHead": "56ddebbaf88004facedb7bb78e5f4bdb954931d0"
}
}
7 changes: 3 additions & 4 deletions packages/hdwallet-keepkey/package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "@keepkey/hdwallet-keepkey",
"version": "1.53.12",
"version": "1.53.13",
"license": "MIT",
"publishConfig": {
"access": "public"
Expand All @@ -18,7 +18,7 @@
"@ethereumjs/common": "^2.4.0",
"@ethereumjs/tx": "^3.3.0",
"@keepkey/device-protocol": "^7.13.2",
"@keepkey/hdwallet-core": "1.53.12",
"@keepkey/hdwallet-core": "1.53.9",
"@keepkey/proto-tx-builder": "^0.9.0",
"@metamask/eth-sig-util": "^7.0.0",
"@shapeshiftoss/bitcoinjs-lib": "5.2.0-shapeshift.2",
Expand All @@ -45,6 +45,5 @@
"@types/semver": "^6.2.2",
"@types/tiny-secp256k1": "^1.0.0",
"typedoc": "^0.20.36"
},
"gitHead": "56ddebbaf88004facedb7bb78e5f4bdb954931d0"
}
}
5 changes: 2 additions & 3 deletions packages/hdwallet-native-vault/package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "@keepkey/hdwallet-native-vault",
"version": "1.53.12",
"version": "1.53.13",
"license": "MIT",
"publishConfig": {
"access": "public"
Expand All @@ -27,6 +27,5 @@
"devDependencies": {
"@types/tiny-secp256k1": "^1.0.0",
"fake-indexeddb": "^3.1.7"
},
"gitHead": "56ddebbaf88004facedb7bb78e5f4bdb954931d0"
}
}
Loading

0 comments on commit 356ec44

Please sign in to comment.