import { WalletKitError, RelaySponsoredInput, OpContext, RelaySponsoredResponse, SignLsp25Input, SignLsp25Response, SignMessageResponse, SignTransactionInput, SignTransactionResponse, WalletKitClient, Hex, ProfileWithChains, QuotaSnapshot, Wallet } from '@universal-everything/sdk-core'; import { Ref, ComputedRef } from 'vue'; /** * Mutation composable shape. `mutate` returns the Promise so callers * can `await` it inline; `data` / `error` / `isPending` mirror it as * refs for template bindings. */ type MutationState = { mutate: (...args: TArgs) => Promise; data: Ref; error: Ref; isPending: Ref; reset: () => void; }; declare function useSignMessage(): MutationState<[message: string, opts?: { walletId?: string; encoding?: "utf-8" | "hex"; opContext?: OpContext; } | undefined], SignMessageResponse>; declare function useSignTransaction(): MutationState<[input: SignTransactionInput, opts?: { walletId?: string; opContext?: OpContext; } | undefined], SignTransactionResponse>; declare function useSignLsp25(): MutationState<[input: SignLsp25Input, opContext?: OpContext | undefined], SignLsp25Response>; declare function useRelaySponsored(): MutationState<[input: RelaySponsoredInput, opContext?: OpContext | undefined], RelaySponsoredResponse>; declare const WALLET_KIT_KEY: symbol & InjectionKeyBrand; interface InjectionKeyBrand { readonly __injection_brand: unique symbol; } /** * Expose a `WalletKitClient` to descendant components via Vue's * provide/inject. Call this inside the root component's `setup()` * (or an ancestor of every `useWalletKit()` caller). * * ```ts * const client = new WalletKitClient({ * baseUrl: import.meta.env.VITE_RELAYER_URL, * getAccessToken: () => privy.getAccessToken(), * }); * provideWalletKit(client); * ``` * * Deliberately split from a Vue plugin: callers who want * `app.use(...)` can wrap this in three lines. Keeping the package * plugin-free saves a surface-area's worth of docs. */ declare function provideWalletKit(client: WalletKitClient): void; /** Inject the client. Throws if no ancestor called `provideWalletKit`. */ declare function useWalletKit(): WalletKitClient; /** * Minimal query composable shape. Mirrors `sdk-react`'s `QueryState` * but returns Vue refs so template bindings just work. * * No react-query-style cache; consumers who want dedupe / * background revalidation should layer `@tanstack/vue-query` over * `client.listWallets()` et al. */ type QueryState = { data: Ref; error: Ref; isLoading: Ref; isSuccess: ComputedRef; refetch: () => void; }; declare function useWallets(): QueryState; declare function useProfiles(): QueryState; declare function useQuota(): QueryState; /** * Dynamic-input query. Accepts a `Ref` and refetches when * it changes. Matches how Vue templates usually pass reactive inputs * (`const selected = ref(...); useWallet(selected)`). */ declare function useWallet(walletId: Ref | string | null | undefined): QueryState; declare function useProfile(address: Ref | Hex | null | undefined): QueryState; export { type MutationState, type QueryState, WALLET_KIT_KEY, provideWalletKit, useProfile, useProfiles, useQuota, useRelaySponsored, useSignLsp25, useSignMessage, useSignTransaction, useWallet, useWalletKit, useWallets };