import { DeviceModelId } from "@ledgerhq/devices"; export type SolanaAddress = { address: Buffer; }; export type SolanaSignature = { signature: Buffer; }; /** * Enum for user input type in transaction resolution. * Values are compatible with the UserInputType enum from @ledgerhq/device-signer-kit-solana. */ export enum UserInputType { SOL = "sol", ATA = "ata", } export type Resolution = { deviceModelId?: DeviceModelId | undefined; certificateSignatureKind?: "prod" | "test" | undefined; tokenAddress?: string; tokenInternalId?: string; createATA?: { address: string; mintAddress: string; }; userInputType?: UserInputType; templateId?: string; delayed?: boolean; solanaRPCURL?: string; fetchBlockhash?: () => Promise; }; export enum PubKeyDisplayMode { LONG, SHORT, } export type AppConfig = { blindSigningEnabled: boolean; pubKeyDisplayMode: PubKeyDisplayMode; version: string; }; export interface SolanaSigner { getAppConfiguration(): Promise; getAddress(path: string, display?: boolean): Promise; signTransaction( path: string, txBuffer: Buffer, resolution?: Resolution, ): Promise; signMessage(path: string, messageHex: string): Promise; }