@bounded-sh/client 0.0.16 → 0.0.17
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/dist/index.js +5395 -17344
- package/dist/index.js.map +1 -1
- package/dist/index.mjs +5191 -17160
- package/dist/index.mjs.map +1 -1
- package/dist/index.native-DlMO7aHv.mjs +8041 -0
- package/dist/index.native-DlMO7aHv.mjs.map +1 -0
- package/dist/index.native-DoiNBZlU.js +8102 -0
- package/dist/index.native-DoiNBZlU.js.map +1 -0
- package/dist/index.native.js +89 -68
- package/dist/index.native.js.map +1 -1
- package/dist/index.native.mjs +4 -3
- package/dist/index.native.mjs.map +1 -1
- package/dist/{phantom-wallet-provider-MW2H0SFY.js → phantom-wallet-provider-DUdnFoyb.js} +18 -18
- package/dist/{phantom-wallet-provider-MW2H0SFY.js.map → phantom-wallet-provider-DUdnFoyb.js.map} +1 -1
- package/dist/{phantom-wallet-provider-DU4WPFPM.mjs → phantom-wallet-provider-DWG1LVJf.mjs} +3 -3
- package/dist/{phantom-wallet-provider-DU4WPFPM.mjs.map → phantom-wallet-provider-DWG1LVJf.mjs.map} +1 -1
- package/dist/{privy-wallet-provider-D5Kdp3Qp.mjs → privy-wallet-provider-CyNLekvY.mjs} +4 -4
- package/dist/{privy-wallet-provider-D5Kdp3Qp.mjs.map → privy-wallet-provider-CyNLekvY.mjs.map} +1 -1
- package/dist/{privy-wallet-provider-dFxuvDf4.js → privy-wallet-provider-Kv6H3xcS.js} +21 -21
- package/dist/{privy-wallet-provider-dFxuvDf4.js.map → privy-wallet-provider-Kv6H3xcS.js.map} +1 -1
- package/dist/{solana-mobile-wallet-provider-DAR0BLTQ.js → solana-mobile-wallet-provider-BfHBucO0.js} +19 -19
- package/dist/{solana-mobile-wallet-provider-DAR0BLTQ.js.map → solana-mobile-wallet-provider-BfHBucO0.js.map} +1 -1
- package/dist/{solana-mobile-wallet-provider-CLiflgPj.mjs → solana-mobile-wallet-provider-CKOSbLRd.mjs} +3 -3
- package/dist/{solana-mobile-wallet-provider-CLiflgPj.mjs.map → solana-mobile-wallet-provider-CKOSbLRd.mjs.map} +1 -1
- package/package.json +2 -2
- package/dist/index.native-CAygEkU7.mjs +0 -20012
- package/dist/index.native-CAygEkU7.mjs.map +0 -1
- package/dist/index.native-zD2ZzCLO.js +0 -20137
- package/dist/index.native-zD2ZzCLO.js.map +0 -1
package/dist/index.native.js
CHANGED
|
@@ -1,105 +1,126 @@
|
|
|
1
1
|
'use strict';
|
|
2
2
|
|
|
3
|
-
var index_native = require('./index.native-
|
|
4
|
-
require('
|
|
3
|
+
var index_native = require('./index.native-DoiNBZlU.js');
|
|
4
|
+
var core = require('@bounded-sh/core');
|
|
5
5
|
require('@solana/web3.js');
|
|
6
|
-
require('@coral-xyz/anchor');
|
|
7
6
|
require('react');
|
|
7
|
+
require('@coral-xyz/anchor');
|
|
8
8
|
|
|
9
9
|
|
|
10
10
|
|
|
11
11
|
exports.DEFAULT_TEST_ADDRESS = index_native.DEFAULT_TEST_ADDRESS;
|
|
12
|
-
exports.EFFECT_INTENT_ADDRESS = index_native.EFFECT_INTENT_ADDRESS;
|
|
13
|
-
exports.FunctionInvokeError = index_native.FunctionInvokeError;
|
|
14
|
-
exports.InsufficientBalanceError = index_native.InsufficientBalanceError;
|
|
15
|
-
exports.LiveIntentError = index_native.LiveIntentError;
|
|
16
12
|
exports.MockAuthProvider = index_native.MockAuthProvider;
|
|
17
13
|
exports.OffchainAuthProvider = index_native.OffchainAuthProvider;
|
|
18
14
|
exports.PrivyExpoProvider = index_native.PrivyExpoProvider;
|
|
19
|
-
exports.ReactNativeSessionManager = index_native.ReactNativeSessionManager;
|
|
20
|
-
exports.RealtimeStore = index_native.RealtimeStore;
|
|
21
|
-
exports.ServerSessionManager = index_native.ServerSessionManager;
|
|
22
|
-
exports.WebSessionManager = index_native.WebSessionManager;
|
|
23
|
-
exports.aggregate = index_native.aggregate;
|
|
24
|
-
exports.buildSetDocumentsTransaction = index_native.buildSetDocumentsTransaction;
|
|
25
|
-
exports.clearCache = index_native.clearCache;
|
|
26
|
-
exports.closeAllSubscriptions = index_native.closeAllSubscriptions;
|
|
27
15
|
exports.completeLoginFromRedirect = index_native.completeLoginFromRedirect;
|
|
28
16
|
exports.completeLoginInPopup = index_native.completeLoginInPopup;
|
|
29
|
-
exports.convertRemainingAccounts = index_native.convertRemainingAccounts;
|
|
30
|
-
exports.count = index_native.count;
|
|
31
|
-
exports.createSessionWithSignature = index_native.createSessionWithSignature;
|
|
32
|
-
exports.defineLiveModule = index_native.defineLiveModule;
|
|
33
|
-
exports.deriveUserIdentityFromIdToken = index_native.deriveUserIdentityFromIdToken;
|
|
34
17
|
exports.deserializeTransaction = index_native.deserializeTransaction;
|
|
35
|
-
exports.docId = index_native.docId;
|
|
36
|
-
exports.functions = index_native.functions;
|
|
37
|
-
exports.genAuthNonce = index_native.genAuthNonce;
|
|
38
|
-
exports.genSolanaMessage = index_native.genSolanaMessage;
|
|
39
|
-
exports.get = index_native.get;
|
|
40
|
-
exports.getActiveSessionManager = index_native.getActiveSessionManager;
|
|
41
18
|
exports.getAuthLoading = index_native.getAuthLoading;
|
|
42
19
|
exports.getAuthProvider = index_native.getAuthProvider;
|
|
43
|
-
exports.getCachedData = index_native.getCachedData;
|
|
44
|
-
exports.getConfig = index_native.getConfig;
|
|
45
20
|
exports.getCurrentUser = index_native.getCurrentUser;
|
|
46
|
-
exports.getFiles = index_native.getFiles;
|
|
47
21
|
exports.getIdToken = index_native.getIdToken;
|
|
48
|
-
exports.getMany = index_native.getMany;
|
|
49
22
|
exports.getPlatform = index_native.getPlatform;
|
|
50
|
-
exports.getRealtimeStore = index_native.getRealtimeStore;
|
|
51
|
-
exports.getWebhookKeysUrl = index_native.getWebhookKeysUrl;
|
|
52
|
-
exports.hasActiveConnection = index_native.hasActiveConnection;
|
|
53
|
-
exports.increment = index_native.increment;
|
|
54
23
|
exports.init = index_native.init;
|
|
55
|
-
exports.invokeFunction = index_native.invoke;
|
|
56
|
-
exports.isEffectResult = index_native.isEffectResult;
|
|
57
24
|
exports.linkEmail = index_native.linkEmail;
|
|
58
25
|
exports.linkWithRedirect = index_native.linkWithRedirect;
|
|
59
|
-
exports.live = index_native.live;
|
|
60
|
-
exports.liveIntent = index_native.intent;
|
|
61
|
-
exports.liveStatus = index_native.status;
|
|
62
26
|
exports.login = index_native.login;
|
|
63
27
|
exports.loginWithPopup = index_native.loginWithPopup;
|
|
64
28
|
exports.loginWithPrivy = index_native.loginWithPrivy;
|
|
65
29
|
exports.loginWithRedirect = index_native.loginWithRedirect;
|
|
66
30
|
exports.logout = index_native.logout;
|
|
67
|
-
exports.now = index_native.now;
|
|
68
31
|
exports.onAuthLoadingChanged = index_native.onAuthLoadingChanged;
|
|
69
32
|
exports.onAuthStateChanged = index_native.onAuthStateChanged;
|
|
70
|
-
exports.queryAggregate = index_native.queryAggregate;
|
|
71
|
-
exports.reconnectWithNewAuth = index_native.reconnectWithNewAuth;
|
|
72
|
-
exports.refreshSession = index_native.refreshSession;
|
|
73
|
-
exports.resetRealtimeStore = index_native.resetRealtimeStore;
|
|
74
|
-
exports.revokeSession = index_native.revokeSession;
|
|
75
|
-
exports.runExpression = index_native.runExpression;
|
|
76
|
-
exports.runExpressionMany = index_native.runExpressionMany;
|
|
77
|
-
exports.runQuery = index_native.runQuery;
|
|
78
|
-
exports.runQueryMany = index_native.runQueryMany;
|
|
79
|
-
exports.search = index_native.search;
|
|
80
33
|
exports.sendEmailOtp = index_native.sendEmailOtp;
|
|
81
34
|
exports.sendTextOtp = index_native.sendTextOtp;
|
|
82
|
-
exports.serverTimestamp = index_native.serverTimestamp;
|
|
83
|
-
exports.set = index_native.set;
|
|
84
|
-
exports.setFile = index_native.setFile;
|
|
85
|
-
exports.setMany = index_native.setMany;
|
|
86
35
|
exports.setPlatform = index_native.setPlatform;
|
|
87
|
-
exports.signAndSubmitTransaction = index_native.signAndSubmitTransaction;
|
|
88
36
|
exports.signInAnonymously = index_native.signInAnonymously;
|
|
89
|
-
exports.signMessage = index_native.signMessage;
|
|
90
|
-
exports.signSessionCreateMessage = index_native.signSessionCreateMessage;
|
|
91
|
-
exports.signTransaction = index_native.signTransaction;
|
|
92
|
-
exports.subscribe = index_native.subscribe;
|
|
93
|
-
exports.subscribeLiveView = index_native.subscribeView;
|
|
94
|
-
exports.toMillis = index_native.toMillis;
|
|
95
|
-
exports.toSeconds = index_native.toSeconds;
|
|
96
37
|
exports.useAuth = index_native.useAuth;
|
|
97
38
|
exports.verifyEmailOtp = index_native.verifyEmailOtp;
|
|
98
39
|
exports.verifyTextOtp = index_native.verifyTextOtp;
|
|
99
|
-
exports
|
|
100
|
-
|
|
101
|
-
|
|
102
|
-
|
|
103
|
-
exports
|
|
104
|
-
|
|
40
|
+
Object.defineProperty(exports, "aggregate", {
|
|
41
|
+
enumerable: true,
|
|
42
|
+
get: function () { return core.aggregate; }
|
|
43
|
+
});
|
|
44
|
+
Object.defineProperty(exports, "count", {
|
|
45
|
+
enumerable: true,
|
|
46
|
+
get: function () { return core.count; }
|
|
47
|
+
});
|
|
48
|
+
Object.defineProperty(exports, "docId", {
|
|
49
|
+
enumerable: true,
|
|
50
|
+
get: function () { return core.docId; }
|
|
51
|
+
});
|
|
52
|
+
Object.defineProperty(exports, "get", {
|
|
53
|
+
enumerable: true,
|
|
54
|
+
get: function () { return core.get; }
|
|
55
|
+
});
|
|
56
|
+
Object.defineProperty(exports, "getConfig", {
|
|
57
|
+
enumerable: true,
|
|
58
|
+
get: function () { return core.getConfig; }
|
|
59
|
+
});
|
|
60
|
+
Object.defineProperty(exports, "getFiles", {
|
|
61
|
+
enumerable: true,
|
|
62
|
+
get: function () { return core.getFiles; }
|
|
63
|
+
});
|
|
64
|
+
Object.defineProperty(exports, "getMany", {
|
|
65
|
+
enumerable: true,
|
|
66
|
+
get: function () { return core.getMany; }
|
|
67
|
+
});
|
|
68
|
+
Object.defineProperty(exports, "queryAggregate", {
|
|
69
|
+
enumerable: true,
|
|
70
|
+
get: function () { return core.queryAggregate; }
|
|
71
|
+
});
|
|
72
|
+
Object.defineProperty(exports, "runExpression", {
|
|
73
|
+
enumerable: true,
|
|
74
|
+
get: function () { return core.runExpression; }
|
|
75
|
+
});
|
|
76
|
+
Object.defineProperty(exports, "runExpressionMany", {
|
|
77
|
+
enumerable: true,
|
|
78
|
+
get: function () { return core.runExpressionMany; }
|
|
79
|
+
});
|
|
80
|
+
Object.defineProperty(exports, "runQuery", {
|
|
81
|
+
enumerable: true,
|
|
82
|
+
get: function () { return core.runQuery; }
|
|
83
|
+
});
|
|
84
|
+
Object.defineProperty(exports, "runQueryMany", {
|
|
85
|
+
enumerable: true,
|
|
86
|
+
get: function () { return core.runQueryMany; }
|
|
87
|
+
});
|
|
88
|
+
Object.defineProperty(exports, "search", {
|
|
89
|
+
enumerable: true,
|
|
90
|
+
get: function () { return core.search; }
|
|
91
|
+
});
|
|
92
|
+
Object.defineProperty(exports, "set", {
|
|
93
|
+
enumerable: true,
|
|
94
|
+
get: function () { return core.set; }
|
|
95
|
+
});
|
|
96
|
+
Object.defineProperty(exports, "setFile", {
|
|
97
|
+
enumerable: true,
|
|
98
|
+
get: function () { return core.setFile; }
|
|
99
|
+
});
|
|
100
|
+
Object.defineProperty(exports, "setMany", {
|
|
101
|
+
enumerable: true,
|
|
102
|
+
get: function () { return core.setMany; }
|
|
103
|
+
});
|
|
104
|
+
Object.defineProperty(exports, "signAndSubmitTransaction", {
|
|
105
|
+
enumerable: true,
|
|
106
|
+
get: function () { return core.signAndSubmitTransaction; }
|
|
107
|
+
});
|
|
108
|
+
Object.defineProperty(exports, "signMessage", {
|
|
109
|
+
enumerable: true,
|
|
110
|
+
get: function () { return core.signMessage; }
|
|
111
|
+
});
|
|
112
|
+
Object.defineProperty(exports, "signTransaction", {
|
|
113
|
+
enumerable: true,
|
|
114
|
+
get: function () { return core.signTransaction; }
|
|
115
|
+
});
|
|
116
|
+
Object.defineProperty(exports, "subscribe", {
|
|
117
|
+
enumerable: true,
|
|
118
|
+
get: function () { return core.subscribe; }
|
|
119
|
+
});
|
|
120
|
+
Object.keys(core).forEach(function (k) {
|
|
121
|
+
if (k !== 'default' && !Object.prototype.hasOwnProperty.call(exports, k)) Object.defineProperty(exports, k, {
|
|
122
|
+
enumerable: true,
|
|
123
|
+
get: function () { return core[k]; }
|
|
124
|
+
});
|
|
125
|
+
});
|
|
105
126
|
//# sourceMappingURL=index.native.js.map
|
package/dist/index.native.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.native.js","sources":[],"sourcesContent":[],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"index.native.js","sources":[],"sourcesContent":[],"names":[],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;"}
|
package/dist/index.native.mjs
CHANGED
|
@@ -1,6 +1,7 @@
|
|
|
1
|
-
export {
|
|
2
|
-
|
|
1
|
+
export { I as DEFAULT_TEST_ADDRESS, M as MockAuthProvider, O as OffchainAuthProvider, P as PrivyExpoProvider, B as completeLoginFromRedirect, D as completeLoginInPopup, F as deserializeTransaction, m as getAuthLoading, q as getAuthProvider, k as getCurrentUser, G as getIdToken, g as getPlatform, j as init, x as linkEmail, A as linkWithRedirect, n as login, C as loginWithPopup, y as loginWithPrivy, z as loginWithRedirect, p as logout, l as onAuthLoadingChanged, o as onAuthStateChanged, t as sendEmailOtp, u as sendTextOtp, H as setPlatform, r as signInAnonymously, E as useAuth, v as verifyEmailOtp, w as verifyTextOtp } from './index.native-DlMO7aHv.mjs';
|
|
2
|
+
export * from '@bounded-sh/core';
|
|
3
|
+
export { aggregate, count, docId, get, getConfig, getFiles, getMany, queryAggregate, runExpression, runExpressionMany, runQuery, runQueryMany, search, set, setFile, setMany, signAndSubmitTransaction, signMessage, signTransaction, subscribe } from '@bounded-sh/core';
|
|
3
4
|
import '@solana/web3.js';
|
|
4
|
-
import '@coral-xyz/anchor';
|
|
5
5
|
import 'react';
|
|
6
|
+
import '@coral-xyz/anchor';
|
|
6
7
|
//# sourceMappingURL=index.native.mjs.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.native.mjs","sources":[],"sourcesContent":[],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"index.native.mjs","sources":[],"sourcesContent":[],"names":[],"mappings":";;;;;"}
|
|
@@ -1,9 +1,9 @@
|
|
|
1
1
|
'use strict';
|
|
2
2
|
|
|
3
|
-
var index_native = require('./index.native-
|
|
3
|
+
var index_native = require('./index.native-DoiNBZlU.js');
|
|
4
|
+
var core = require('@bounded-sh/core');
|
|
4
5
|
var web3_js = require('@solana/web3.js');
|
|
5
6
|
var anchor = require('@coral-xyz/anchor');
|
|
6
|
-
require('axios');
|
|
7
7
|
require('react');
|
|
8
8
|
|
|
9
9
|
function _interopNamespaceDefault(e) {
|
|
@@ -313,7 +313,7 @@ class PhantomWalletProvider {
|
|
|
313
313
|
}
|
|
314
314
|
const publicKey = solAddress.address;
|
|
315
315
|
// Check if we already have a valid session for this address
|
|
316
|
-
const existingSession = await
|
|
316
|
+
const existingSession = await core.WebSessionManager.getSession();
|
|
317
317
|
if (existingSession && existingSession.address === publicKey) {
|
|
318
318
|
// Already have a valid session, just set user
|
|
319
319
|
index_native.setCurrentUser({ provider: that, address: publicKey });
|
|
@@ -323,14 +323,14 @@ class PhantomWalletProvider {
|
|
|
323
323
|
that.autoLoginInProgress = true;
|
|
324
324
|
index_native.setAuthLoading(true);
|
|
325
325
|
try {
|
|
326
|
-
const nonce = await
|
|
327
|
-
const messageText = await
|
|
326
|
+
const nonce = await core.genAuthNonce();
|
|
327
|
+
const messageText = await core.genSolanaMessage(publicKey, nonce);
|
|
328
328
|
// signMessage returns { signature: Uint8Array, publicKey: string }
|
|
329
329
|
const signResult = await solana.signMessage(messageText);
|
|
330
330
|
// Convert Uint8Array signature to base64 string
|
|
331
331
|
const signatureBytes = signResult.signature;
|
|
332
332
|
const signature = index_native.bufferExports.Buffer.from(signatureBytes).toString('base64');
|
|
333
|
-
const createSessionResult = await
|
|
333
|
+
const createSessionResult = await core.createSessionWithSignature(publicKey, messageText, signature);
|
|
334
334
|
// Pre-write guard: MWA may have started a login while we were
|
|
335
335
|
// in flight. If MWA owns the auth method now, abort before we
|
|
336
336
|
// overwrite its session (or its in-flight session).
|
|
@@ -340,7 +340,7 @@ class PhantomWalletProvider {
|
|
|
340
340
|
}
|
|
341
341
|
}
|
|
342
342
|
catch (_c) { }
|
|
343
|
-
await
|
|
343
|
+
await core.WebSessionManager.storeSession(publicKey, createSessionResult.accessToken, createSessionResult.idToken, createSessionResult.refreshToken);
|
|
344
344
|
// Mark auth method so clearIncompatibleSession() doesn't wipe this session
|
|
345
345
|
try {
|
|
346
346
|
index_native.getPlatform().storage.setItem('bounded_last_auth_method', 'phantom');
|
|
@@ -421,7 +421,7 @@ class PhantomWalletProvider {
|
|
|
421
421
|
}
|
|
422
422
|
const publicKey = solAddress.address;
|
|
423
423
|
// Check if we already have a valid session
|
|
424
|
-
const existingSession = await
|
|
424
|
+
const existingSession = await core.WebSessionManager.getSession();
|
|
425
425
|
if (existingSession && existingSession.address === publicKey) {
|
|
426
426
|
const user = { provider: that, address: publicKey };
|
|
427
427
|
index_native.setCurrentUser(user);
|
|
@@ -430,15 +430,15 @@ class PhantomWalletProvider {
|
|
|
430
430
|
return;
|
|
431
431
|
}
|
|
432
432
|
// Create new session with signature
|
|
433
|
-
const nonce = await
|
|
434
|
-
const messageText = await
|
|
433
|
+
const nonce = await core.genAuthNonce();
|
|
434
|
+
const messageText = await core.genSolanaMessage(publicKey, nonce);
|
|
435
435
|
// signMessage returns { signature: Uint8Array, publicKey: string }
|
|
436
436
|
const signResult = await solana.signMessage(messageText);
|
|
437
437
|
// Convert Uint8Array signature to base64 string
|
|
438
438
|
const signatureBytes = signResult.signature;
|
|
439
439
|
const signature = index_native.bufferExports.Buffer.from(signatureBytes).toString('base64');
|
|
440
|
-
const createSessionResult = await
|
|
441
|
-
await
|
|
440
|
+
const createSessionResult = await core.createSessionWithSignature(publicKey, messageText, signature);
|
|
441
|
+
await core.WebSessionManager.storeSession(publicKey, createSessionResult.accessToken, createSessionResult.idToken, createSessionResult.refreshToken);
|
|
442
442
|
// Mark auth method so clearIncompatibleSession() doesn't wipe this session
|
|
443
443
|
try {
|
|
444
444
|
index_native.getPlatform().storage.setItem('bounded_last_auth_method', 'phantom');
|
|
@@ -919,7 +919,7 @@ class PhantomWalletProvider {
|
|
|
919
919
|
if (((_a = this.phantomMethods) === null || _a === void 0 ? void 0 : _a.isConnected) && ((_b = this.phantomMethods.addresses) === null || _b === void 0 ? void 0 : _b.length) > 0) {
|
|
920
920
|
const solAddress = this.phantomMethods.addresses.find((addr) => addr.addressType === phantomReactSdk.AddressType.solana);
|
|
921
921
|
if (solAddress) {
|
|
922
|
-
const session = await
|
|
922
|
+
const session = await core.WebSessionManager.getSession();
|
|
923
923
|
if (session && session.address === solAddress.address) {
|
|
924
924
|
const user = { provider: this, address: solAddress.address };
|
|
925
925
|
index_native.setCurrentUser(user);
|
|
@@ -954,7 +954,7 @@ class PhantomWalletProvider {
|
|
|
954
954
|
}
|
|
955
955
|
async restoreSession() {
|
|
956
956
|
await this.ensureReady();
|
|
957
|
-
const session = await
|
|
957
|
+
const session = await core.WebSessionManager.getSession();
|
|
958
958
|
if (session) {
|
|
959
959
|
return { provider: this, address: session.address };
|
|
960
960
|
}
|
|
@@ -1054,7 +1054,7 @@ class PhantomWalletProvider {
|
|
|
1054
1054
|
const connection = new web3_js.Connection(rpcUrl, 'confirmed');
|
|
1055
1055
|
const isSurfnet = rpcUrl === index_native.SURFNET_RPC_URL;
|
|
1056
1056
|
try {
|
|
1057
|
-
const remainingAccounts =
|
|
1057
|
+
const remainingAccounts = core.convertRemainingAccounts(solTransactionData.txArgs[0].remainingAccounts);
|
|
1058
1058
|
const app_id = solTransactionData.appId;
|
|
1059
1059
|
if (!app_id) {
|
|
1060
1060
|
throw new Error("App ID is required");
|
|
@@ -1096,7 +1096,7 @@ class PhantomWalletProvider {
|
|
|
1096
1096
|
tx = web3_js.VersionedTransaction.deserialize(index_native.bufferExports.Buffer.from(solTransactionData.signedTransaction, 'base64'));
|
|
1097
1097
|
}
|
|
1098
1098
|
else {
|
|
1099
|
-
const result = await
|
|
1099
|
+
const result = await core.buildSetDocumentsTransaction(connection, solTransactionData.txArgs[0].idl, anchorProvider, publicKey, {
|
|
1100
1100
|
app_id,
|
|
1101
1101
|
documents: solTransactionData.txArgs[0].setDocumentData,
|
|
1102
1102
|
delete_paths: solTransactionData.txArgs[0].deletePaths,
|
|
@@ -1396,7 +1396,7 @@ class PhantomWalletProvider {
|
|
|
1396
1396
|
console.error('Failed to disconnect from Phantom wallet', error);
|
|
1397
1397
|
}
|
|
1398
1398
|
// Always clear local state
|
|
1399
|
-
|
|
1399
|
+
core.WebSessionManager.clearSession();
|
|
1400
1400
|
index_native.setCurrentUser(null);
|
|
1401
1401
|
}
|
|
1402
1402
|
async getNativeMethods() {
|
|
@@ -1460,4 +1460,4 @@ class PhantomWalletProvider {
|
|
|
1460
1460
|
PhantomWalletProvider.instance = null;
|
|
1461
1461
|
|
|
1462
1462
|
exports.PhantomWalletProvider = PhantomWalletProvider;
|
|
1463
|
-
//# sourceMappingURL=phantom-wallet-provider-
|
|
1463
|
+
//# sourceMappingURL=phantom-wallet-provider-DUdnFoyb.js.map
|