import { Observable } from "rxjs"; import type { ConnectAppEvent, Input as ConnectAppInput } from "../connectApp"; import type { Action, Device } from "./types"; import type { AppState } from "./app"; import { ExchangeType } from "@ledgerhq/live-app-sdk"; export type StartExchangeSuccessResult = { nonce: string; device: Device; }; export type StartExchangeErrorResult = { error: Error; device?: Device; }; type State = { startExchangeResult: StartExchangeSuccessResult | null | undefined; startExchangeError: StartExchangeErrorResult | null | undefined; freezeReduxDevice: boolean; isLoading: boolean; error?: Error; }; type StartExchangeState = AppState & State; export type Result = { startExchangeResult: StartExchangeSuccessResult; } | { startExchangeError: StartExchangeErrorResult; }; type StartExchangeAction = Action; export type ExchangeRequestEvent = { type: "start-exchange"; } | { type: "start-exchange-error"; startExchangeError: StartExchangeErrorResult; } | { type: "start-exchange-result"; startExchangeResult: StartExchangeSuccessResult; }; export declare const createAction: (connectAppExec: (arg0: ConnectAppInput) => Observable, startExchangeExec: (arg0: { device: Device; exchangeType: ExchangeType; appVersion?: string; provider?: string; }) => Observable) => StartExchangeAction; export {}; //# sourceMappingURL=startExchange.d.ts.map