@solana/web3.js 1.50.0 → 1.52.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.
- package/README.md +4 -0
- package/lib/index.browser.cjs.js +22 -4
- package/lib/index.browser.cjs.js.map +1 -1
- package/lib/index.browser.esm.js +22 -4
- package/lib/index.browser.esm.js.map +1 -1
- package/lib/index.cjs.js +22 -4
- package/lib/index.cjs.js.map +1 -1
- package/lib/index.d.ts +17 -2
- package/lib/index.esm.js +22 -4
- package/lib/index.esm.js.map +1 -1
- package/lib/index.iife.js +22 -4
- package/lib/index.iife.js.map +1 -1
- package/lib/index.iife.min.js +1 -1
- package/lib/index.iife.min.js.map +1 -1
- package/lib/index.native.js +22 -4
- package/lib/index.native.js.map +1 -1
- package/package.json +2 -2
- package/src/connection.ts +30 -2
- package/src/fee-calculator.ts +2 -0
package/lib/index.iife.js
CHANGED
|
@@ -13985,6 +13985,8 @@ var solanaWeb3 = (function (exports) {
|
|
|
13985
13985
|
const FeeCalculatorLayout = nu64('lamportsPerSignature');
|
|
13986
13986
|
/**
|
|
13987
13987
|
* Calculator for transaction fees.
|
|
13988
|
+
*
|
|
13989
|
+
* @deprecated Deprecated since Solana v1.8.0.
|
|
13988
13990
|
*/
|
|
13989
13991
|
|
|
13990
13992
|
/**
|
|
@@ -20483,6 +20485,10 @@ var solanaWeb3 = (function (exports) {
|
|
|
20483
20485
|
owner: optional(string()),
|
|
20484
20486
|
uiTokenAmount: TokenAmountResult
|
|
20485
20487
|
});
|
|
20488
|
+
const LoadedAddressesResult = type({
|
|
20489
|
+
writable: array(PublicKeyFromString),
|
|
20490
|
+
readonly: array(PublicKeyFromString)
|
|
20491
|
+
});
|
|
20486
20492
|
/**
|
|
20487
20493
|
* @internal
|
|
20488
20494
|
*/
|
|
@@ -20502,7 +20508,8 @@ var solanaWeb3 = (function (exports) {
|
|
|
20502
20508
|
postBalances: array(number()),
|
|
20503
20509
|
logMessages: optional(nullable(array(string()))),
|
|
20504
20510
|
preTokenBalances: optional(nullable(array(TokenBalanceResult))),
|
|
20505
|
-
postTokenBalances: optional(nullable(array(TokenBalanceResult)))
|
|
20511
|
+
postTokenBalances: optional(nullable(array(TokenBalanceResult))),
|
|
20512
|
+
loadedAddresses: optional(LoadedAddressesResult)
|
|
20506
20513
|
});
|
|
20507
20514
|
/**
|
|
20508
20515
|
* @internal
|
|
@@ -20519,7 +20526,8 @@ var solanaWeb3 = (function (exports) {
|
|
|
20519
20526
|
postBalances: array(number()),
|
|
20520
20527
|
logMessages: optional(nullable(array(string()))),
|
|
20521
20528
|
preTokenBalances: optional(nullable(array(TokenBalanceResult))),
|
|
20522
|
-
postTokenBalances: optional(nullable(array(TokenBalanceResult)))
|
|
20529
|
+
postTokenBalances: optional(nullable(array(TokenBalanceResult))),
|
|
20530
|
+
loadedAddresses: optional(LoadedAddressesResult)
|
|
20523
20531
|
});
|
|
20524
20532
|
/**
|
|
20525
20533
|
* Expected JSON RPC response for the "getBlock" message
|
|
@@ -21115,8 +21123,13 @@ var solanaWeb3 = (function (exports) {
|
|
|
21115
21123
|
*/
|
|
21116
21124
|
|
|
21117
21125
|
|
|
21118
|
-
async getParsedAccountInfo(publicKey,
|
|
21119
|
-
const
|
|
21126
|
+
async getParsedAccountInfo(publicKey, commitmentOrConfig) {
|
|
21127
|
+
const {
|
|
21128
|
+
commitment,
|
|
21129
|
+
config
|
|
21130
|
+
} = extractCommitmentFromConfig(commitmentOrConfig);
|
|
21131
|
+
|
|
21132
|
+
const args = this._buildArgs([publicKey.toBase58()], commitment, 'jsonParsed', config);
|
|
21120
21133
|
|
|
21121
21134
|
const unsafeRes = await this._rpcRequest('getAccountInfo', args);
|
|
21122
21135
|
const res = create(unsafeRes, jsonRpcResultAndContext(nullable(ParsedAccountInfoResult)));
|
|
@@ -22716,6 +22729,11 @@ var solanaWeb3 = (function (exports) {
|
|
|
22716
22729
|
this._rpcWebSocketConnected = false;
|
|
22717
22730
|
this._rpcWebSocketGeneration++;
|
|
22718
22731
|
|
|
22732
|
+
if (this._rpcWebSocketIdleTimeout) {
|
|
22733
|
+
clearTimeout(this._rpcWebSocketIdleTimeout);
|
|
22734
|
+
this._rpcWebSocketIdleTimeout = null;
|
|
22735
|
+
}
|
|
22736
|
+
|
|
22719
22737
|
if (this._rpcWebSocketHeartbeat) {
|
|
22720
22738
|
clearInterval(this._rpcWebSocketHeartbeat);
|
|
22721
22739
|
this._rpcWebSocketHeartbeat = null;
|