@taquito/beacon-wallet 23.0.3 → 23.1.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.
@@ -176,6 +176,20 @@ class BeaconWallet {
176
176
  return this.removeDefaultParams(walletParams, yield (0, taquito_1.createSetDelegateOperation)(this.formatParameters(walletParams)));
177
177
  });
178
178
  }
179
+ mapRegisterGlobalConstantParamsToWalletParams(params) {
180
+ return __awaiter(this, void 0, void 0, function* () {
181
+ let walletParams;
182
+ yield this.client.showPrepare();
183
+ try {
184
+ walletParams = yield params();
185
+ }
186
+ catch (err) {
187
+ yield this.client.hideUI(['alert']);
188
+ throw err;
189
+ }
190
+ return this.removeDefaultParams(walletParams, yield (0, taquito_1.createRegisterGlobalConstantOperation)(this.formatParameters(walletParams)));
191
+ });
192
+ }
179
193
  formatParameters(params) {
180
194
  if (params.fee) {
181
195
  params.fee = params.fee.toString();
@@ -3,6 +3,6 @@ Object.defineProperty(exports, "__esModule", { value: true });
3
3
  exports.VERSION = void 0;
4
4
  // IMPORTANT: THIS FILE IS AUTO GENERATED! DO NOT MANUALLY EDIT OR CHECKIN!
5
5
  exports.VERSION = {
6
- "commitHash": "42048d039f6d4345fc59d04b03650bcb8e27bb62",
7
- "version": "23.0.3"
6
+ "commitHash": "c77fe4b0989665d8b5cfd15a7cc977499021f6fd",
7
+ "version": "23.1.0"
8
8
  };
@@ -1,7 +1,7 @@
1
1
  import { getDAppClientInstance, SigningType, PermissionScope } from '@airgap/beacon-dapp';
2
2
  import { PermissionDeniedError, UnsupportedActionError } from '@taquito/core';
3
3
  import toBuffer from 'typedarray-to-buffer';
4
- import { createTransferOperation, createTransferTicketOperation, createIncreasePaidStorageOperation, createOriginationOperation, createSetDelegateOperation } from '@taquito/taquito';
4
+ import { createTransferOperation, createTransferTicketOperation, createIncreasePaidStorageOperation, createOriginationOperation, createSetDelegateOperation, createRegisterGlobalConstantOperation } from '@taquito/taquito';
5
5
  import { hex2buf, mergebuf, buf2hex } from '@taquito/utils';
6
6
 
7
7
  /******************************************************************************
@@ -63,8 +63,8 @@ class MissingRequiredScopes extends PermissionDeniedError {
63
63
 
64
64
  // IMPORTANT: THIS FILE IS AUTO GENERATED! DO NOT MANUALLY EDIT OR CHECKIN!
65
65
  const VERSION = {
66
- "commitHash": "42048d039f6d4345fc59d04b03650bcb8e27bb62",
67
- "version": "23.0.3"
66
+ "commitHash": "c77fe4b0989665d8b5cfd15a7cc977499021f6fd",
67
+ "version": "23.1.0"
68
68
  };
69
69
 
70
70
  /**
@@ -222,6 +222,20 @@ class BeaconWallet {
222
222
  return this.removeDefaultParams(walletParams, yield createSetDelegateOperation(this.formatParameters(walletParams)));
223
223
  });
224
224
  }
225
+ mapRegisterGlobalConstantParamsToWalletParams(params) {
226
+ return __awaiter(this, void 0, void 0, function* () {
227
+ let walletParams;
228
+ yield this.client.showPrepare();
229
+ try {
230
+ walletParams = yield params();
231
+ }
232
+ catch (err) {
233
+ yield this.client.hideUI(['alert']);
234
+ throw err;
235
+ }
236
+ return this.removeDefaultParams(walletParams, yield createRegisterGlobalConstantOperation(this.formatParameters(walletParams)));
237
+ });
238
+ }
225
239
  formatParameters(params) {
226
240
  if (params.fee) {
227
241
  params.fee = params.fee.toString();
@@ -1 +1 @@
1
- {"version":3,"file":"taquito-beacon-wallet.es6.js","sources":[],"sourcesContent":[],"names":[],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;"}
1
+ {"version":3,"file":"taquito-beacon-wallet.es6.js","sources":[],"sourcesContent":[],"names":[],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;"}
@@ -1,7 +1,7 @@
1
1
  (function (global, factory) {
2
2
  typeof exports === 'object' && typeof module !== 'undefined' ? factory(exports, require('@airgap/beacon-dapp'), require('@taquito/core'), require('typedarray-to-buffer'), require('@taquito/taquito'), require('@taquito/utils')) :
3
3
  typeof define === 'function' && define.amd ? define(['exports', '@airgap/beacon-dapp', '@taquito/core', 'typedarray-to-buffer', '@taquito/taquito', '@taquito/utils'], factory) :
4
- (global = typeof globalThis !== 'undefined' ? globalThis : global || self, factory(global.taquitoBeaconWallet = {}, global.beaconDapp, global.core, global.toBuffer, global.taquito, global.utils));
4
+ (global = typeof globalThis !== 'undefined' ? globalThis : global || self, factory(global.taquitoBeaconWallet = {}, global.beaconDapp, global.taquitoCore, global.typedarrayToBuffer, global.taquito, global.taquitoUtils));
5
5
  })(this, (function (exports, beaconDapp, core, toBuffer, taquito, utils) { 'use strict';
6
6
 
7
7
  /******************************************************************************
@@ -63,8 +63,8 @@
63
63
 
64
64
  // IMPORTANT: THIS FILE IS AUTO GENERATED! DO NOT MANUALLY EDIT OR CHECKIN!
65
65
  const VERSION = {
66
- "commitHash": "42048d039f6d4345fc59d04b03650bcb8e27bb62",
67
- "version": "23.0.3"
66
+ "commitHash": "c77fe4b0989665d8b5cfd15a7cc977499021f6fd",
67
+ "version": "23.1.0"
68
68
  };
69
69
 
70
70
  /**
@@ -222,6 +222,20 @@
222
222
  return this.removeDefaultParams(walletParams, yield taquito.createSetDelegateOperation(this.formatParameters(walletParams)));
223
223
  });
224
224
  }
225
+ mapRegisterGlobalConstantParamsToWalletParams(params) {
226
+ return __awaiter(this, void 0, void 0, function* () {
227
+ let walletParams;
228
+ yield this.client.showPrepare();
229
+ try {
230
+ walletParams = yield params();
231
+ }
232
+ catch (err) {
233
+ yield this.client.hideUI(['alert']);
234
+ throw err;
235
+ }
236
+ return this.removeDefaultParams(walletParams, yield taquito.createRegisterGlobalConstantOperation(this.formatParameters(walletParams)));
237
+ });
238
+ }
225
239
  formatParameters(params) {
226
240
  if (params.fee) {
227
241
  params.fee = params.fee.toString();
@@ -1 +1 @@
1
- {"version":3,"file":"taquito-beacon-wallet.umd.js","sources":[],"sourcesContent":[],"names":[],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;"}
1
+ {"version":3,"file":"taquito-beacon-wallet.umd.js","sources":[],"sourcesContent":[],"names":[],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;"}
@@ -3,9 +3,14 @@
3
3
  * @module @taquito/beacon-wallet
4
4
  */
5
5
  import { DAppClient, DAppClientOptions, RequestPermissionInput } from '@airgap/beacon-dapp';
6
- import { WalletDelegateParams, WalletIncreasePaidStorageParams, WalletOriginateParams, WalletProvider, WalletTransferParams, WalletStakeParams, WalletUnstakeParams, WalletFinalizeUnstakeParams, WalletTransferTicketParams } from '@taquito/taquito';
6
+ import { WalletDelegateParams, WalletIncreasePaidStorageParams, WalletOriginateParams, WalletProvider, WalletTransferParams, WalletStakeParams, WalletUnstakeParams, WalletFinalizeUnstakeParams, WalletTransferTicketParams, WalletRegisterGlobalConstantParams, ParamsWithOptionalFees } from '@taquito/taquito';
7
7
  export { VERSION } from './version';
8
8
  export { BeaconWalletNotInitialized, MissingRequiredScopes } from './errors';
9
+ type RPCOperationWithLimits = {
10
+ fee?: number | string;
11
+ gas_limit?: number | string;
12
+ storage_limit?: number | string;
13
+ };
9
14
  export declare class BeaconWallet implements WalletProvider {
10
15
  client: DAppClient;
11
16
  constructor(options: DAppClientOptions);
@@ -13,16 +18,17 @@ export declare class BeaconWallet implements WalletProvider {
13
18
  requestPermissions(request?: RequestPermissionInput): Promise<void>;
14
19
  getPKH(): Promise<string>;
15
20
  getPK(): Promise<string>;
16
- mapTransferParamsToWalletParams(params: () => Promise<WalletTransferParams>): Promise<any>;
17
- mapTransferTicketParamsToWalletParams(params: () => Promise<WalletTransferTicketParams>): Promise<any>;
18
- mapStakeParamsToWalletParams(params: () => Promise<WalletStakeParams>): Promise<any>;
19
- mapUnstakeParamsToWalletParams(params: () => Promise<WalletUnstakeParams>): Promise<any>;
20
- mapFinalizeUnstakeParamsToWalletParams(params: () => Promise<WalletFinalizeUnstakeParams>): Promise<any>;
21
- mapIncreasePaidStorageWalletParams(params: () => Promise<WalletIncreasePaidStorageParams>): Promise<any>;
22
- mapOriginateParamsToWalletParams(params: () => Promise<WalletOriginateParams>): Promise<any>;
23
- mapDelegateParamsToWalletParams(params: () => Promise<WalletDelegateParams>): Promise<any>;
24
- formatParameters(params: any): any;
25
- removeDefaultParams(params: WalletTransferParams | WalletStakeParams | WalletUnstakeParams | WalletFinalizeUnstakeParams | WalletOriginateParams | WalletDelegateParams, operatedParams: any): any;
21
+ mapTransferParamsToWalletParams(params: () => Promise<WalletTransferParams>): Promise<RPCOperationWithLimits>;
22
+ mapTransferTicketParamsToWalletParams(params: () => Promise<WalletTransferTicketParams>): Promise<RPCOperationWithLimits>;
23
+ mapStakeParamsToWalletParams(params: () => Promise<WalletStakeParams>): Promise<RPCOperationWithLimits>;
24
+ mapUnstakeParamsToWalletParams(params: () => Promise<WalletUnstakeParams>): Promise<RPCOperationWithLimits>;
25
+ mapFinalizeUnstakeParamsToWalletParams(params: () => Promise<WalletFinalizeUnstakeParams>): Promise<RPCOperationWithLimits>;
26
+ mapIncreasePaidStorageWalletParams(params: () => Promise<WalletIncreasePaidStorageParams>): Promise<RPCOperationWithLimits>;
27
+ mapOriginateParamsToWalletParams(params: () => Promise<WalletOriginateParams>): Promise<RPCOperationWithLimits>;
28
+ mapDelegateParamsToWalletParams(params: () => Promise<WalletDelegateParams>): Promise<RPCOperationWithLimits>;
29
+ mapRegisterGlobalConstantParamsToWalletParams(params: () => Promise<WalletRegisterGlobalConstantParams>): Promise<RPCOperationWithLimits>;
30
+ formatParameters<T extends ParamsWithOptionalFees>(params: T): T;
31
+ removeDefaultParams(params: WalletTransferParams | WalletStakeParams | WalletUnstakeParams | WalletFinalizeUnstakeParams | WalletOriginateParams | WalletDelegateParams | WalletRegisterGlobalConstantParams | WalletTransferTicketParams | WalletIncreasePaidStorageParams, operatedParams: RPCOperationWithLimits): RPCOperationWithLimits;
26
32
  sendOperations(params: any[]): Promise<string>;
27
33
  /**
28
34
  *
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@taquito/beacon-wallet",
3
- "version": "23.0.3",
3
+ "version": "23.1.0",
4
4
  "description": "Beacon wallet provider",
5
5
  "keywords": [
6
6
  "tezos",
@@ -24,7 +24,7 @@
24
24
  },
25
25
  "license": "Apache-2.0",
26
26
  "engines": {
27
- "node": ">=18"
27
+ "node": ">=20"
28
28
  },
29
29
  "scripts": {
30
30
  "test": "jest --coverage",
@@ -100,9 +100,9 @@
100
100
  ]
101
101
  },
102
102
  "dependencies": {
103
- "@airgap/beacon-dapp": "^4.6.2",
104
- "@taquito/core": "^23.0.3",
105
- "@taquito/taquito": "^23.0.3",
103
+ "@airgap/beacon-dapp": "^4.6.4",
104
+ "@taquito/core": "^23.1.0",
105
+ "@taquito/taquito": "^23.1.0",
106
106
  "crypto-browserify": "^3.12.1",
107
107
  "util": "^0.12.5"
108
108
  },
@@ -110,7 +110,7 @@
110
110
  "@types/bluebird": "^3.5.42",
111
111
  "@types/chrome": "0.0.269",
112
112
  "@types/jest": "^29.5.12",
113
- "@types/node": "^18",
113
+ "@types/node": "^20",
114
114
  "@types/ws": "^8.5.12",
115
115
  "@typescript-eslint/eslint-plugin": "^6.21.0",
116
116
  "@typescript-eslint/parser": "^6.21.0",
@@ -129,6 +129,7 @@
129
129
  "rimraf": "^6.0.1",
130
130
  "rollup": "^4.22.4",
131
131
  "rollup-plugin-json": "^4.0.0",
132
+ "rollup-plugin-polyfill-node": "^0.13.0",
132
133
  "rollup-plugin-typescript2": "^0.36.0",
133
134
  "shelljs": "^0.8.5",
134
135
  "ts-jest": "^29.2.3",
@@ -138,5 +139,5 @@
138
139
  "webpack": "^5.94.0",
139
140
  "webpack-cli": "^5.1.4"
140
141
  },
141
- "gitHead": "2abf349e97af45f11210b3121078b9d96699d5da"
142
+ "gitHead": "bcf60513cade1e3272cd50c47a786d4bd45f70c8"
142
143
  }