@mysten/signers 0.2.6 → 0.2.7
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/CHANGELOG.md +6 -0
- package/README.md +5 -5
- package/dist/cjs/ledger/index.js +5 -1
- package/dist/cjs/ledger/index.js.map +3 -3
- package/dist/esm/ledger/index.js +5 -1
- package/dist/esm/ledger/index.js.map +2 -2
- package/dist/tsconfig.esm.tsbuildinfo +1 -1
- package/dist/tsconfig.tsbuildinfo +1 -1
- package/package.json +1 -1
- package/src/ledger/index.ts +5 -1
package/package.json
CHANGED
package/src/ledger/index.ts
CHANGED
|
@@ -10,6 +10,7 @@ import { Transaction } from '@mysten/sui/transactions';
|
|
|
10
10
|
import { toBase64 } from '@mysten/sui/utils';
|
|
11
11
|
|
|
12
12
|
import { SuiMoveObject } from './bcs.js';
|
|
13
|
+
import { bcs } from '@mysten/sui/bcs';
|
|
13
14
|
|
|
14
15
|
/**
|
|
15
16
|
* Configuration options for initializing the LedgerSigner.
|
|
@@ -92,7 +93,10 @@ export class LedgerSigner extends Signer {
|
|
|
92
93
|
* @returns The signed message bytes and signature.
|
|
93
94
|
*/
|
|
94
95
|
override async signPersonalMessage(bytes: Uint8Array): Promise<SignatureWithBytes> {
|
|
95
|
-
const intentMessage = messageWithIntent(
|
|
96
|
+
const intentMessage = messageWithIntent(
|
|
97
|
+
'PersonalMessage',
|
|
98
|
+
bcs.byteVector().serialize(bytes).toBytes(),
|
|
99
|
+
);
|
|
96
100
|
const { signature } = await this.#ledgerClient.signTransaction(
|
|
97
101
|
this.#derivationPath,
|
|
98
102
|
intentMessage,
|