UNPKG

react-payline

Version:
37 lines (36 loc) 1.33 kB
/// <reference types="jquery" /> declare type PaylineApi = { endToken: (additionnalData: any, callback: () => void, spinner: any, handledByMerchant: boolean) => void; finalizeShortCut: () => void; getBuyerShortCut: () => Record<string, unknown>; getCancelAndReturnUrls: () => { returnUrl: string; cancelUrl: string; }; getContextInfo: (key: string) => Record<string, unknown>; getCssIframeWhiteList: () => string[]; getFragmentedPaymentInfo: () => Record<string, unknown>; getLanguage: () => string; getOrderInfos: () => Record<string, unknown>; getRecurringDetails: () => Record<string, unknown>; getToken: () => string; getTokenStatus: (token: string, callback: (tokenStatus: 'ALIVE' | 'EXPIRED' | 'UNKNOWN') => void) => void; hide: () => void; init: () => void; isSandBox: () => boolean; reset: (token?: string, template?: string) => void; show: () => void; toggle: () => void; updateWebpaymentData: (token: string, data: any) => void; }; declare global { interface Window { Payline?: { Api: PaylineApi; jQuery: JQuery; }; } } export declare const usePaylineApi: () => PaylineApi | undefined; export declare const usePaylineJQuery: () => JQuery<HTMLElement> | undefined; export {};