@exodus/bitcoin-plugin 1.17.3 → 1.18.1
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/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@exodus/bitcoin-plugin",
|
|
3
|
-
"version": "1.
|
|
3
|
+
"version": "1.18.1",
|
|
4
4
|
"description": "Exodus bitcoin-plugin",
|
|
5
5
|
"main": "src/index.js",
|
|
6
6
|
"files": [
|
|
@@ -23,7 +23,7 @@
|
|
|
23
23
|
"@exodus/bip32": "^1.1.2",
|
|
24
24
|
"@exodus/bip44-constants": "^195.0.0",
|
|
25
25
|
"@exodus/bitcoin-api": "^2.15.0",
|
|
26
|
-
"@exodus/bitcoin-lib": "^2.
|
|
26
|
+
"@exodus/bitcoin-lib": "^2.4.0",
|
|
27
27
|
"@exodus/bitcoin-meta": "^1.0.2",
|
|
28
28
|
"@exodus/bitcoinjs-lib": "^6.1.5-exodus.1",
|
|
29
29
|
"@exodus/crypto": "^1.0.0-rc.1",
|
|
@@ -55,5 +55,5 @@
|
|
|
55
55
|
"bip39": "^2.6.0",
|
|
56
56
|
"jest-when": "^3.5.1"
|
|
57
57
|
},
|
|
58
|
-
"gitHead": "
|
|
58
|
+
"gitHead": "f5fed96e366226a8a96f1de8eb2fbf98da98784f"
|
|
59
59
|
}
|
|
@@ -6,6 +6,7 @@ export const ordinals86 = 'ordinals86'
|
|
|
6
6
|
export const trezor = 'trezor'
|
|
7
7
|
export const ledger = 'ledger'
|
|
8
8
|
export const xverse49 = 'xverse49'
|
|
9
|
+
export const xverse49NotMerged = 'xverse49NotMerged'
|
|
9
10
|
|
|
10
11
|
export const getDefaultAddressPath = ({ compatibilityMode } = Object.create(null)) => {
|
|
11
12
|
if ([ordinals84, ordinals86].includes(compatibilityMode)) {
|
|
@@ -40,12 +41,16 @@ export const getSupportedPurposes = ({ compatibilityMode, isMultisig, walletAcco
|
|
|
40
41
|
return [49, 84, 86, 44]
|
|
41
42
|
}
|
|
42
43
|
|
|
44
|
+
if (compatibilityMode === xverse49NotMerged) {
|
|
45
|
+
return [49, 86]
|
|
46
|
+
}
|
|
47
|
+
|
|
43
48
|
return [84, 86, 44]
|
|
44
49
|
}
|
|
45
50
|
|
|
46
51
|
export const createGetSupportedPurposes = ({ omitPurposes = [] } = {}) => {
|
|
47
|
-
return ({ compatibilityMode, walletAccount }) => {
|
|
48
|
-
const purposes = getSupportedPurposes({ compatibilityMode, walletAccount })
|
|
52
|
+
return ({ compatibilityMode, walletAccount, isMultisig }) => {
|
|
53
|
+
const purposes = getSupportedPurposes({ compatibilityMode, walletAccount, isMultisig })
|
|
49
54
|
return without(purposes, ...omitPurposes)
|
|
50
55
|
}
|
|
51
56
|
}
|
package/src/create-asset.js
CHANGED
|
@@ -18,7 +18,6 @@ import {
|
|
|
18
18
|
InsightAPIClient,
|
|
19
19
|
isValidInscription,
|
|
20
20
|
moveFundsFactory,
|
|
21
|
-
parseUnsignedTx,
|
|
22
21
|
signTxFactory,
|
|
23
22
|
signHardwareFactory,
|
|
24
23
|
signMessage,
|
|
@@ -343,8 +342,6 @@ export const createBitcoinAssetFactory =
|
|
|
343
342
|
getSupportedPurposes: createGetSupportedPurposes({ omitPurposes: omitSupportedPurposes }),
|
|
344
343
|
hasFeature: (feature) => !!features[feature], // @deprecated use api.features instead
|
|
345
344
|
createAccountState: () => accountStateClass,
|
|
346
|
-
parseUnsignedTx,
|
|
347
|
-
signUnsignedTx: (unsignedTx, privateKey, opts) => signTx({ unsignedTx, privateKey, ...opts }), // legacy
|
|
348
345
|
sendTx,
|
|
349
346
|
signTx,
|
|
350
347
|
signHardware,
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import assert from 'minimalistic-assert'
|
|
2
2
|
import { getOrdinalsUtxos } from '@exodus/bitcoin-api'
|
|
3
|
-
import { xverse49 } from '../compatibility-modes'
|
|
3
|
+
import { xverse49, xverse49NotMerged } from '../compatibility-modes'
|
|
4
4
|
|
|
5
5
|
export const getInscriptionAddresses = async ({
|
|
6
6
|
assetClientInterface: aci,
|
|
@@ -38,7 +38,8 @@ export const getInscriptionAddresses = async ({
|
|
|
38
38
|
})
|
|
39
39
|
|
|
40
40
|
const specialAddress3 =
|
|
41
|
-
walletAccountInstance.compatibilityMode === xverse49
|
|
41
|
+
walletAccountInstance.compatibilityMode === xverse49 ||
|
|
42
|
+
walletAccountInstance.compatibilityMode === xverse49NotMerged
|
|
42
43
|
? await aci.getAddress({
|
|
43
44
|
// xverse
|
|
44
45
|
assetName,
|
|
@@ -2,7 +2,7 @@ import assert from 'minimalistic-assert'
|
|
|
2
2
|
import * as bitcoinjsLib from '@exodus/bitcoinjs-lib'
|
|
3
3
|
import { TextEncoder } from '@exodus/text-encoding-utf8'
|
|
4
4
|
import { randomBytes } from '@exodus/crypto/randomBytes'
|
|
5
|
-
import secp256k1 from 'tiny-secp256k1'
|
|
5
|
+
import * as secp256k1 from 'tiny-secp256k1'
|
|
6
6
|
import { DEFAULT_BRC20_POSTAGE, DEFAULT_ORDINAL_POSTAGE } from './ordinals-constants'
|
|
7
7
|
|
|
8
8
|
import { witnessStackToScriptWitness } from '@exodus/bitcoinjs-lib/src/psbt/psbtutils'
|