@vue-solana/core 1.0.0 → 1.2.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 (57) hide show
  1. package/dist/address.d.cts +6 -0
  2. package/dist/address.d.mts +6 -0
  3. package/dist/address.d.ts +6 -0
  4. package/dist/clusters.d.cts +2 -1
  5. package/dist/clusters.d.mts +2 -1
  6. package/dist/clusters.d.ts +2 -1
  7. package/dist/index.cjs +18 -1
  8. package/dist/index.d.cts +5 -1
  9. package/dist/index.d.mts +5 -1
  10. package/dist/index.d.ts +5 -1
  11. package/dist/index.mjs +6 -1
  12. package/dist/ios-wallet.d.cts +2 -1
  13. package/dist/ios-wallet.d.mts +2 -1
  14. package/dist/ios-wallet.d.ts +2 -1
  15. package/dist/kit.cjs +21 -0
  16. package/dist/kit.d.cts +5 -0
  17. package/dist/kit.d.mts +5 -0
  18. package/dist/kit.d.ts +5 -0
  19. package/dist/kit.mjs +18 -0
  20. package/dist/mobile-wallet.d.cts +2 -1
  21. package/dist/mobile-wallet.d.mts +2 -1
  22. package/dist/mobile-wallet.d.ts +2 -1
  23. package/dist/rpc.cjs +5 -1
  24. package/dist/rpc.d.cts +7 -1
  25. package/dist/rpc.d.mts +7 -1
  26. package/dist/rpc.d.ts +7 -1
  27. package/dist/rpc.mjs +5 -1
  28. package/dist/shared/{core.BU9rgxEj.cjs → core.BQoh-5Wu.cjs} +3 -0
  29. package/dist/shared/core.DAUuCWrr.d.cts +98 -0
  30. package/dist/shared/core.DAUuCWrr.d.mts +98 -0
  31. package/dist/shared/core.DAUuCWrr.d.ts +98 -0
  32. package/dist/shared/{core.BBMCTQpw.mjs → core.DjbtrJWl.mjs} +3 -0
  33. package/dist/spl-token.cjs +12 -0
  34. package/dist/spl-token.d.cts +4 -0
  35. package/dist/spl-token.d.mts +4 -0
  36. package/dist/spl-token.d.ts +4 -0
  37. package/dist/spl-token.mjs +1 -0
  38. package/dist/token-accounts.cjs +56 -0
  39. package/dist/token-accounts.d.cts +35 -0
  40. package/dist/token-accounts.d.mts +35 -0
  41. package/dist/token-accounts.d.ts +35 -0
  42. package/dist/token-accounts.mjs +52 -0
  43. package/dist/transaction.d.cts +15 -1
  44. package/dist/transaction.d.mts +15 -1
  45. package/dist/transaction.d.ts +15 -1
  46. package/dist/types.d.cts +3 -78
  47. package/dist/types.d.mts +3 -78
  48. package/dist/types.d.ts +3 -78
  49. package/dist/wallet-standard.cjs +1 -1
  50. package/dist/wallet-standard.d.cts +2 -1
  51. package/dist/wallet-standard.d.mts +2 -1
  52. package/dist/wallet-standard.d.ts +2 -1
  53. package/dist/wallet-standard.mjs +1 -1
  54. package/dist/wallet.d.cts +2 -1
  55. package/dist/wallet.d.mts +2 -1
  56. package/dist/wallet.d.ts +2 -1
  57. package/package.json +20 -2
package/dist/types.d.mts CHANGED
@@ -1,80 +1,5 @@
1
1
  /// <reference path="../types/web3-compat.d.ts" />
2
2
  /// <reference path="../types/buffer.d.ts" />
3
- import { Commitment, SendOptions, Connection, Transaction, VersionedTransaction, PublicKey, TransactionSignature, RpcResponseAndContext, SignatureResult } from '@solana/web3-compat';
4
-
5
- type SolanaCluster = "mainnet-beta" | "testnet" | "devnet" | "localnet";
6
- type SolanaChain = "solana:mainnet" | "solana:testnet" | "solana:devnet" | "solana:localnet";
7
- interface SolanaConfig {
8
- cluster?: SolanaCluster;
9
- endpoint?: string;
10
- wsEndpoint?: string;
11
- commitment?: Commitment;
12
- autoConnect?: boolean;
13
- }
14
- interface SolanaContext {
15
- cluster: SolanaCluster;
16
- endpoint: string;
17
- wsEndpoint: string;
18
- connection: Connection;
19
- }
20
- type SolanaTransaction = Transaction | VersionedTransaction;
21
- interface SolanaSignMessageResult {
22
- signedMessage: Uint8Array;
23
- signature: Uint8Array;
24
- }
25
- interface SolanaWallet {
26
- publicKey: PublicKey | null;
27
- connected: boolean;
28
- connecting?: boolean;
29
- disconnecting?: boolean;
30
- platform?: SolanaWalletInfo["platform"];
31
- source?: SolanaWalletInfo["source"];
32
- connect: () => Promise<void>;
33
- disconnect: () => Promise<void>;
34
- signMessage?: (message: Uint8Array) => Promise<SolanaSignMessageResult>;
35
- signTransaction?: <T extends SolanaTransaction>(transaction: T) => Promise<T>;
36
- signAllTransactions?: <T extends SolanaTransaction>(transactions: T[]) => Promise<T[]>;
37
- signAndSendTransaction?: (transaction: SolanaTransaction, options?: SendOptions) => Promise<{
38
- signature: TransactionSignature;
39
- }>;
40
- }
41
- interface SolanaWalletInfo {
42
- name: string;
43
- icon: string;
44
- chains: readonly string[];
45
- platform?: "browser" | "mobile" | "desktop";
46
- source?: "wallet-standard" | "mobile-wallet-adapter" | "deep-link" | "protocol-link";
47
- appUrl?: string;
48
- installUrl?: string;
49
- callbackUrl?: string;
50
- capabilities?: {
51
- connect?: boolean;
52
- disconnect?: boolean;
53
- signMessage?: boolean;
54
- signTransaction?: boolean;
55
- signAllTransactions?: boolean;
56
- signAndSendTransaction?: boolean;
57
- };
58
- accounts: readonly {
59
- address: string;
60
- publicKey: Uint8Array;
61
- chains: readonly string[];
62
- label?: string;
63
- icon?: string;
64
- }[];
65
- wallet: unknown;
66
- }
67
- interface SendTransactionOptions extends SendOptions {
68
- skipPreflight?: boolean;
69
- }
70
- interface ConfirmTransactionOptions {
71
- commitment?: Commitment;
72
- timeoutMs?: number;
73
- }
74
- interface TransactionConfirmation {
75
- signature: TransactionSignature;
76
- commitment: Commitment;
77
- result: RpcResponseAndContext<SignatureResult>;
78
- }
79
-
80
- export type { ConfirmTransactionOptions, SendTransactionOptions, SolanaChain, SolanaCluster, SolanaConfig, SolanaContext, SolanaSignMessageResult, SolanaTransaction, SolanaWallet, SolanaWalletInfo, TransactionConfirmation };
3
+ import '@solana/web3-compat';
4
+ export { C as ConfirmTransactionOptions, S as SendTransactionOptions, a as SolanaChain, c as SolanaCluster, d as SolanaConfig, e as SolanaContext, f as SolanaSignMessageResult, g as SolanaTransaction, h as SolanaWallet, i as SolanaWalletInfo, T as TransactionConfirmation } from './shared/core.DAUuCWrr.mjs';
5
+ import '@solana/kit';
package/dist/types.d.ts CHANGED
@@ -1,80 +1,5 @@
1
1
  /// <reference path="../types/web3-compat.d.ts" />
2
2
  /// <reference path="../types/buffer.d.ts" />
3
- import { Commitment, SendOptions, Connection, Transaction, VersionedTransaction, PublicKey, TransactionSignature, RpcResponseAndContext, SignatureResult } from '@solana/web3-compat';
4
-
5
- type SolanaCluster = "mainnet-beta" | "testnet" | "devnet" | "localnet";
6
- type SolanaChain = "solana:mainnet" | "solana:testnet" | "solana:devnet" | "solana:localnet";
7
- interface SolanaConfig {
8
- cluster?: SolanaCluster;
9
- endpoint?: string;
10
- wsEndpoint?: string;
11
- commitment?: Commitment;
12
- autoConnect?: boolean;
13
- }
14
- interface SolanaContext {
15
- cluster: SolanaCluster;
16
- endpoint: string;
17
- wsEndpoint: string;
18
- connection: Connection;
19
- }
20
- type SolanaTransaction = Transaction | VersionedTransaction;
21
- interface SolanaSignMessageResult {
22
- signedMessage: Uint8Array;
23
- signature: Uint8Array;
24
- }
25
- interface SolanaWallet {
26
- publicKey: PublicKey | null;
27
- connected: boolean;
28
- connecting?: boolean;
29
- disconnecting?: boolean;
30
- platform?: SolanaWalletInfo["platform"];
31
- source?: SolanaWalletInfo["source"];
32
- connect: () => Promise<void>;
33
- disconnect: () => Promise<void>;
34
- signMessage?: (message: Uint8Array) => Promise<SolanaSignMessageResult>;
35
- signTransaction?: <T extends SolanaTransaction>(transaction: T) => Promise<T>;
36
- signAllTransactions?: <T extends SolanaTransaction>(transactions: T[]) => Promise<T[]>;
37
- signAndSendTransaction?: (transaction: SolanaTransaction, options?: SendOptions) => Promise<{
38
- signature: TransactionSignature;
39
- }>;
40
- }
41
- interface SolanaWalletInfo {
42
- name: string;
43
- icon: string;
44
- chains: readonly string[];
45
- platform?: "browser" | "mobile" | "desktop";
46
- source?: "wallet-standard" | "mobile-wallet-adapter" | "deep-link" | "protocol-link";
47
- appUrl?: string;
48
- installUrl?: string;
49
- callbackUrl?: string;
50
- capabilities?: {
51
- connect?: boolean;
52
- disconnect?: boolean;
53
- signMessage?: boolean;
54
- signTransaction?: boolean;
55
- signAllTransactions?: boolean;
56
- signAndSendTransaction?: boolean;
57
- };
58
- accounts: readonly {
59
- address: string;
60
- publicKey: Uint8Array;
61
- chains: readonly string[];
62
- label?: string;
63
- icon?: string;
64
- }[];
65
- wallet: unknown;
66
- }
67
- interface SendTransactionOptions extends SendOptions {
68
- skipPreflight?: boolean;
69
- }
70
- interface ConfirmTransactionOptions {
71
- commitment?: Commitment;
72
- timeoutMs?: number;
73
- }
74
- interface TransactionConfirmation {
75
- signature: TransactionSignature;
76
- commitment: Commitment;
77
- result: RpcResponseAndContext<SignatureResult>;
78
- }
79
-
80
- export type { ConfirmTransactionOptions, SendTransactionOptions, SolanaChain, SolanaCluster, SolanaConfig, SolanaContext, SolanaSignMessageResult, SolanaTransaction, SolanaWallet, SolanaWalletInfo, TransactionConfirmation };
3
+ import '@solana/web3-compat';
4
+ export { C as ConfirmTransactionOptions, S as SendTransactionOptions, a as SolanaChain, c as SolanaCluster, d as SolanaConfig, e as SolanaContext, f as SolanaSignMessageResult, g as SolanaTransaction, h as SolanaWallet, i as SolanaWalletInfo, T as TransactionConfirmation } from './shared/core.DAUuCWrr.js';
5
+ import '@solana/kit';
@@ -1,6 +1,6 @@
1
1
  'use strict';
2
2
 
3
- const discovery = require('./shared/core.BU9rgxEj.cjs');
3
+ const discovery = require('./shared/core.BQoh-5Wu.cjs');
4
4
  require('@wallet-standard/features');
5
5
  require('@solana/wallet-standard-features');
6
6
  require('@solana/web3-compat');
@@ -1,8 +1,9 @@
1
1
  /// <reference path="../types/web3-compat.d.ts" />
2
2
  /// <reference path="../types/buffer.d.ts" />
3
3
  import { WalletAccount, Wallet } from '@wallet-standard/base';
4
- import { SolanaChain, SolanaWalletInfo, SolanaWallet, SolanaCluster } from './types.cjs';
4
+ import { a as SolanaChain, i as SolanaWalletInfo, h as SolanaWallet, c as SolanaCluster } from './shared/core.DAUuCWrr.cjs';
5
5
  import '@solana/web3-compat';
6
+ import '@solana/kit';
6
7
 
7
8
  interface AdaptSolanaWalletOptions {
8
9
  chain?: SolanaChain;
@@ -1,8 +1,9 @@
1
1
  /// <reference path="../types/web3-compat.d.ts" />
2
2
  /// <reference path="../types/buffer.d.ts" />
3
3
  import { WalletAccount, Wallet } from '@wallet-standard/base';
4
- import { SolanaChain, SolanaWalletInfo, SolanaWallet, SolanaCluster } from './types.mjs';
4
+ import { a as SolanaChain, i as SolanaWalletInfo, h as SolanaWallet, c as SolanaCluster } from './shared/core.DAUuCWrr.mjs';
5
5
  import '@solana/web3-compat';
6
+ import '@solana/kit';
6
7
 
7
8
  interface AdaptSolanaWalletOptions {
8
9
  chain?: SolanaChain;
@@ -1,8 +1,9 @@
1
1
  /// <reference path="../types/web3-compat.d.ts" />
2
2
  /// <reference path="../types/buffer.d.ts" />
3
3
  import { WalletAccount, Wallet } from '@wallet-standard/base';
4
- import { SolanaChain, SolanaWalletInfo, SolanaWallet, SolanaCluster } from './types.js';
4
+ import { a as SolanaChain, i as SolanaWalletInfo, h as SolanaWallet, c as SolanaCluster } from './shared/core.DAUuCWrr.js';
5
5
  import '@solana/web3-compat';
6
+ import '@solana/kit';
6
7
 
7
8
  interface AdaptSolanaWalletOptions {
8
9
  chain?: SolanaChain;
@@ -1,4 +1,4 @@
1
- export { S as SOLANA_CHAINS, a as SOLANA_MOBILE_WALLET_ADAPTER_WALLET_NAME, b as adaptSolanaStandardWallet, g as getRegisteredSolanaWallets, c as getSolanaChain, i as isSolanaStandardWallet, s as subscribeSolanaWallets } from './shared/core.BBMCTQpw.mjs';
1
+ export { S as SOLANA_CHAINS, a as SOLANA_MOBILE_WALLET_ADAPTER_WALLET_NAME, b as adaptSolanaStandardWallet, g as getRegisteredSolanaWallets, c as getSolanaChain, i as isSolanaStandardWallet, s as subscribeSolanaWallets } from './shared/core.DjbtrJWl.mjs';
2
2
  import '@wallet-standard/features';
3
3
  import '@solana/wallet-standard-features';
4
4
  import '@solana/web3-compat';
package/dist/wallet.d.cts CHANGED
@@ -1,8 +1,9 @@
1
1
  /// <reference path="../types/web3-compat.d.ts" />
2
2
  /// <reference path="../types/buffer.d.ts" />
3
- import { SolanaWallet } from './types.cjs';
3
+ import { h as SolanaWallet } from './shared/core.DAUuCWrr.cjs';
4
4
  import { SolanaError } from './errors.cjs';
5
5
  import '@solana/web3-compat';
6
+ import '@solana/kit';
6
7
 
7
8
  type SolanaWalletErrorCode = "NO_WALLET_SELECTED" | "WALLET_NOT_CONNECTED" | "WALLET_FEATURE_UNSUPPORTED";
8
9
  declare class SolanaWalletError extends SolanaError {
package/dist/wallet.d.mts CHANGED
@@ -1,8 +1,9 @@
1
1
  /// <reference path="../types/web3-compat.d.ts" />
2
2
  /// <reference path="../types/buffer.d.ts" />
3
- import { SolanaWallet } from './types.mjs';
3
+ import { h as SolanaWallet } from './shared/core.DAUuCWrr.mjs';
4
4
  import { SolanaError } from './errors.mjs';
5
5
  import '@solana/web3-compat';
6
+ import '@solana/kit';
6
7
 
7
8
  type SolanaWalletErrorCode = "NO_WALLET_SELECTED" | "WALLET_NOT_CONNECTED" | "WALLET_FEATURE_UNSUPPORTED";
8
9
  declare class SolanaWalletError extends SolanaError {
package/dist/wallet.d.ts CHANGED
@@ -1,8 +1,9 @@
1
1
  /// <reference path="../types/web3-compat.d.ts" />
2
2
  /// <reference path="../types/buffer.d.ts" />
3
- import { SolanaWallet } from './types.js';
3
+ import { h as SolanaWallet } from './shared/core.DAUuCWrr.js';
4
4
  import { SolanaError } from './errors.js';
5
5
  import '@solana/web3-compat';
6
+ import '@solana/kit';
6
7
 
7
8
  type SolanaWalletErrorCode = "NO_WALLET_SELECTED" | "WALLET_NOT_CONNECTED" | "WALLET_FEATURE_UNSUPPORTED";
8
9
  declare class SolanaWalletError extends SolanaError {
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@vue-solana/core",
3
- "version": "1.0.0",
3
+ "version": "1.2.0",
4
4
  "description": "Framework-agnostic primitives for Vue Solana libraries.",
5
5
  "license": "MIT",
6
6
  "keywords": [
@@ -60,6 +60,11 @@
60
60
  "import": "./dist/ios-wallet.mjs",
61
61
  "require": "./dist/ios-wallet.cjs"
62
62
  },
63
+ "./kit": {
64
+ "types": "./dist/kit.d.ts",
65
+ "import": "./dist/kit.mjs",
66
+ "require": "./dist/kit.cjs"
67
+ },
63
68
  "./mobile-wallet": {
64
69
  "types": "./dist/mobile-wallet.d.ts",
65
70
  "import": "./dist/mobile-wallet.mjs",
@@ -94,6 +99,16 @@
94
99
  "types": "./dist/web3.d.ts",
95
100
  "import": "./dist/web3.mjs",
96
101
  "require": "./dist/web3.cjs"
102
+ },
103
+ "./spl-token": {
104
+ "types": "./dist/spl-token.d.ts",
105
+ "import": "./dist/spl-token.mjs",
106
+ "require": "./dist/spl-token.cjs"
107
+ },
108
+ "./token-accounts": {
109
+ "types": "./dist/token-accounts.d.ts",
110
+ "import": "./dist/token-accounts.mjs",
111
+ "require": "./dist/token-accounts.cjs"
97
112
  }
98
113
  },
99
114
  "files": [
@@ -105,13 +120,16 @@
105
120
  },
106
121
  "dependencies": {
107
122
  "@solana-mobile/wallet-standard-mobile": "^0.5.3",
123
+ "@solana/kit": "^8.3.0",
124
+ "@solana/kit-plugin-rpc": "^0.19.0",
125
+ "@solana/spl-token": "^0.4.15",
108
126
  "@solana/wallet-standard-features": "^1.3.0",
109
127
  "@solana/web3-compat": "^0.0.21",
110
128
  "@wallet-standard/app": "^1.1.1",
111
129
  "@wallet-standard/base": "^1.1.1",
112
130
  "@wallet-standard/features": "^1.1.1",
113
- "buffer": "^6.0.3",
114
131
  "bs58": "^6.0.0",
132
+ "buffer": "^6.0.3",
115
133
  "tweetnacl": "^1.0.3"
116
134
  },
117
135
  "devDependencies": {