import React from "react"; import { IEcomExternalProps, IEcomStore } from "./types"; import { IOrderOptionsResponse, IInsuranceOptionsResponse, IVehicleLookupResponse, IAddressLookupResponse, IPaymentLookupResponse, IBankIdAuthResponse, IBankIdCollectResponse, ICreditAssessmentStatusResponse, ICreditAssessmentCase, ICreditAssessmentSignResponse } from "@wayke-se/ecom"; import { IDealerOption } from "@wayke-se/ecom/dist-types/orders/types"; export interface IEcomContextProps extends IEcomExternalProps, IEcomStore { } interface IState { isWaitingForResponse: boolean; dealer?: string; orderOptions: IOrderOptionsResponse | null; insuranceOptions: IInsuranceOptionsResponse | null; vehicleLookup: IVehicleLookupResponse | null; addressLookup: IAddressLookupResponse | null; paymentLookup: IPaymentLookupResponse | null; bankIdAuth: IBankIdAuthResponse | null; pendingBankIdAuthRequest: boolean; bankIdCollect: IBankIdCollectResponse | null; hasBankIdError: boolean; hasCreditAssessmentError: boolean; pendingCreateCreditAssessmentCase: boolean; creditAssessmentCase: ICreditAssessmentCase | null; creditAssessmentStatus: ICreditAssessmentStatusResponse | null; creditAssessmentSigning: ICreditAssessmentSignResponse | null; pendingCreditAssessmentSignRequest: boolean; vehicleUnavailable: boolean; } declare class EcomContext extends React.Component { constructor(props: IEcomContextProps); resolveVehicleUnavailable(err: Error): void; componentDidMount(): void; getAddress(): import("@wayke-se/ecom").IAddress; handleDealerSelection(dealer: IDealerOption): void; handleFetchVehicleInformation(callback: (isSuccessful: boolean) => void): void; handleFetchInsuranceOptions(callback: (isSuccessful: boolean) => void): void; handleFetchAddressInformation(callback: (isSuccessful: boolean) => void): void; handleFetchPaymentInformation(callback: (isSuccessful: boolean) => void): void; handleCreateOrder(callback: (isSuccessful: boolean) => void): void; handleBankIdQrCodeAuth(): void; handleBankIdSameDeviceAuth(): void; handleBankIdCollect(): void; handleBankIdCancel(callback: (response: boolean) => void): void; handleBankIdReset(): void; createCreditAssessmentCase(): void; declineCreditAssessmentCase(): void; acceptCreditAssessmentCase(): void; signCreditAssessmentWithQrCode(): void; signCreditAssessmentWithSameDevice(): void; cancelCreditAssessmentSigning(callback: (response: boolean) => void): void; resetCreditAssessmentSigning(): void; getCreditAssessmentStatus(): void; makeRequest(callback: () => void): void; saveResponse(responseState: any, callback?: () => void): void; render(): JSX.Element; } export default EcomContext;