@tari-project/metamask-signer 0.6.0 → 0.9.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 (2) hide show
  1. package/dist/index.js +2 -8
  2. package/package.json +4 -4
package/dist/index.js CHANGED
@@ -70,13 +70,7 @@ export class MetamaskTariSigner {
70
70
  return res;
71
71
  }
72
72
  async submitTransaction(req) {
73
- const params = {
74
- instructions: req.instructions,
75
- fee_instructions: req.fee_instructions,
76
- input_refs: req.input_refs,
77
- required_substates: req.required_substates || [],
78
- is_dry_run: req.is_dry_run,
79
- };
73
+ const params = req.transaction;
80
74
  const resp = await this.metamaskRequest("sendTransaction", params);
81
75
  if (!resp) {
82
76
  throw new Error("Failed to submit transaction to metamask snap: empty response");
@@ -157,7 +151,7 @@ export class MetamaskTariSigner {
157
151
  }
158
152
  }
159
153
  function convertToStatus(result) {
160
- // Ref: https://github.com/tari-project/tari-dan/blob/bb0b31139b770aacd7bb49af865543aa4a9e2de4/dan_layer/wallet/sdk/src/apis/transaction.rs
154
+ // Ref: https://github.com/tari-project/tari-ootle/blob/bb0b31139b770aacd7bb49af865543aa4a9e2de4/dan_layer/wallet/sdk/src/apis/transaction.rs
161
155
  if (result.final_decision !== "Commit") {
162
156
  return TransactionStatus.Rejected;
163
157
  }
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@tari-project/metamask-signer",
3
- "version": "0.6.0",
3
+ "version": "0.9.0",
4
4
  "description": "",
5
5
  "type": "module",
6
6
  "publishConfig": {
@@ -11,9 +11,9 @@
11
11
  "license": "ISC",
12
12
  "dependencies": {
13
13
  "@metamask/providers": "^18.2.0",
14
- "@tari-project/typescript-bindings": "^1.5.5",
15
- "@tari-project/tarijs-types": "^0.6.0",
16
- "@tari-project/tari-signer": "^0.6.0"
14
+ "@tari-project/typescript-bindings": ">=1.9.1",
15
+ "@tari-project/tari-signer": "^0.9.0",
16
+ "@tari-project/tarijs-types": "^0.9.0"
17
17
  },
18
18
  "devDependencies": {
19
19
  "@types/node": "^22.13.1",