@bounded-sh/client 0.0.18 → 0.0.20
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/auth/providers/offchain-auth-provider.d.ts +2 -5
- package/dist/index.d.ts +0 -1
- package/dist/index.js +29 -2638
- package/dist/index.js.map +1 -1
- package/dist/index.mjs +30 -2637
- package/dist/index.mjs.map +1 -1
- package/dist/{index.native-Dr3FOz16.js → index.native-BtM38BVP.js} +33 -2642
- package/dist/index.native-BtM38BVP.js.map +1 -0
- package/dist/{index.native-DahSrHrM.mjs → index.native-w12aoVNW.mjs} +34 -2641
- package/dist/index.native-w12aoVNW.mjs.map +1 -0
- package/dist/index.native.d.ts +0 -1
- package/dist/index.native.js +2 -4
- package/dist/index.native.js.map +1 -1
- package/dist/index.native.mjs +2 -2
- package/dist/{phantom-wallet-provider-CeLJEdcL.js → phantom-wallet-provider-BJWelaiH.js} +2 -2
- package/dist/{phantom-wallet-provider-CeLJEdcL.js.map → phantom-wallet-provider-BJWelaiH.js.map} +1 -1
- package/dist/{phantom-wallet-provider-l-CNnHPs.mjs → phantom-wallet-provider-BT2V4EU5.mjs} +2 -2
- package/dist/{phantom-wallet-provider-l-CNnHPs.mjs.map → phantom-wallet-provider-BT2V4EU5.mjs.map} +1 -1
- package/dist/{privy-wallet-provider-BSwx78fY.js → privy-wallet-provider-BSh0aZVL.js} +3 -3
- package/dist/{privy-wallet-provider-BSwx78fY.js.map → privy-wallet-provider-BSh0aZVL.js.map} +1 -1
- package/dist/{privy-wallet-provider-BWM8TNO9.mjs → privy-wallet-provider-LV1X7hZe.mjs} +3 -3
- package/dist/{privy-wallet-provider-BWM8TNO9.mjs.map → privy-wallet-provider-LV1X7hZe.mjs.map} +1 -1
- package/dist/{solana-mobile-wallet-provider-BvCrAgk8.js → solana-mobile-wallet-provider-CKsfiyDd.js} +2 -2
- package/dist/{solana-mobile-wallet-provider-BvCrAgk8.js.map → solana-mobile-wallet-provider-CKsfiyDd.js.map} +1 -1
- package/dist/{solana-mobile-wallet-provider-C78VWmM-.mjs → solana-mobile-wallet-provider-NLe9_mEn.mjs} +2 -2
- package/dist/{solana-mobile-wallet-provider-C78VWmM-.mjs.map → solana-mobile-wallet-provider-NLe9_mEn.mjs.map} +1 -1
- package/package.json +2 -2
- package/dist/auth/providers/mock-auth-provider.d.ts +0 -50
- package/dist/index.native-DahSrHrM.mjs.map +0 -1
- package/dist/index.native-Dr3FOz16.js.map +0 -1
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@bounded-sh/client",
|
|
3
|
-
"version": "0.0.
|
|
3
|
+
"version": "0.0.20",
|
|
4
4
|
"description": "JavaScript SDK for Tarobase API",
|
|
5
5
|
"main": "./dist/index.js",
|
|
6
6
|
"react-native": "./dist/index.native.js",
|
|
@@ -97,7 +97,7 @@
|
|
|
97
97
|
"typescript": "5.9.3"
|
|
98
98
|
},
|
|
99
99
|
"dependencies": {
|
|
100
|
-
"@bounded-sh/core": "0.0.
|
|
100
|
+
"@bounded-sh/core": "0.0.20",
|
|
101
101
|
"@coral-xyz/anchor": "0.31.1",
|
|
102
102
|
"@solana/web3.js": "1.98.4",
|
|
103
103
|
"bs58": "6.0.0",
|
|
@@ -1,50 +0,0 @@
|
|
|
1
|
-
import { AuthProvider, User, TransactionResult, SolTransaction, EVMTransaction } from '@bounded-sh/core';
|
|
2
|
-
import { SetOptions } from '@bounded-sh/core';
|
|
3
|
-
import { Transaction, VersionedTransaction } from '@solana/web3.js';
|
|
4
|
-
export declare const DEFAULT_TEST_ADDRESS = "HKbZbRR7jWWR5VRN8KFjvTCHEzJQgameYxKQxh2gPoof";
|
|
5
|
-
/**
|
|
6
|
-
* MockAuthProvider bypasses real wallet authentication for testing purposes.
|
|
7
|
-
* Uses session storage to simulate logged-in user, with fallback to default test address.
|
|
8
|
-
*
|
|
9
|
-
* This is enabled by passing mockAuth: true to init()
|
|
10
|
-
*/
|
|
11
|
-
export declare class MockAuthProvider implements AuthProvider {
|
|
12
|
-
/**
|
|
13
|
-
* Mock login - reads user from session storage or uses default test address
|
|
14
|
-
*/
|
|
15
|
-
login(): Promise<User | null>;
|
|
16
|
-
/**
|
|
17
|
-
* Mock transaction - returns fake signature without actual blockchain interaction
|
|
18
|
-
* The real transaction will be handled by the backend using test headers
|
|
19
|
-
*/
|
|
20
|
-
runTransaction(evmTransactionData?: EVMTransaction, solTransactionData?: SolTransaction, options?: SetOptions): Promise<TransactionResult>;
|
|
21
|
-
/**
|
|
22
|
-
* Mock message signing
|
|
23
|
-
*/
|
|
24
|
-
signMessage(message: string): Promise<string>;
|
|
25
|
-
signMessageMock(message: string): Promise<string>;
|
|
26
|
-
private generateOffchainSignature;
|
|
27
|
-
/**
|
|
28
|
-
* Mock transaction signing - returns the transaction as-is (no actual signing)
|
|
29
|
-
*/
|
|
30
|
-
signTransaction(transaction: Transaction | VersionedTransaction): Promise<Transaction | VersionedTransaction>;
|
|
31
|
-
/**
|
|
32
|
-
* Sign and submit transaction - not supported in mock environment.
|
|
33
|
-
* See the real providers (PhantomWalletProvider, SolanaKeypairProvider)
|
|
34
|
-
* for the full implementation with blockhash handling and feePayer support.
|
|
35
|
-
*/
|
|
36
|
-
signAndSubmitTransaction(_transaction: Transaction | VersionedTransaction, _feePayer?: any): Promise<string>;
|
|
37
|
-
/**
|
|
38
|
-
* Restore session - only restores if user previously called login() explicitly.
|
|
39
|
-
* This prevents auto-login on first page load, but allows session persistence after login.
|
|
40
|
-
*/
|
|
41
|
-
restoreSession(): Promise<User | null>;
|
|
42
|
-
/**
|
|
43
|
-
* Mock logout - clears test user from session storage
|
|
44
|
-
*/
|
|
45
|
-
logout(): Promise<void>;
|
|
46
|
-
/**
|
|
47
|
-
* Get native wallet methods (not needed for mock auth)
|
|
48
|
-
*/
|
|
49
|
-
getNativeMethods(): Promise<any>;
|
|
50
|
-
}
|