@finapi/finapi-js-loader
Version:
finAPI JS Loader
72 lines (71 loc) • 3.28 kB
TypeScript
import { Widget } from '../Widget';
import { ModBaseWidgetCallbacks, ModBaseWidgetProperties } from '../mods/modBaseWidget';
import { ModImportProperties } from '../mods/modImport';
import { ModLanguageProperties } from '../mods/modLanguage';
import { ModProcessctlProperties } from '../mods/modProcessctl';
export interface GiroIdentProperties extends ModBaseWidgetProperties, ModProcessctlProperties, ModImportProperties, ModLanguageProperties {
/**
* User's first name.
*/
firstName: string;
/**
* User's last name
*/
lastName: string;
/**
* Optional company name. The company name does not contribute to the name
* similarity evaluation. It may stored with the check e.g. for compliance
* reasons.
*/
companyName?: string;
/**
* If you provide the `iban`, the account import will begin with the
* predefined IBAN, and the user will not be able to select any other
* account.
*/
iban?: string;
/**
* The `startButtonLabel` property enables you to customize the label of the
* button displayed on the initial view, which initiates the evaluation
* process.
*/
startButtonLabel?: string;
/**
* With `skipResults` set to true, the view displaying the evaluation result
* will not be shown.
*/
skipResults?: boolean;
}
export interface GiroIdentCallbacks extends ModBaseWidgetCallbacks {
/**
* If the end-user aborts the account import step, the `onAbort` event will
* be triggered.
*/
onAbort?: () => void;
/**
* The `onResolved` event is triggered after successful evaluation. The
* payload of this event is an object containing the results of the
* evaluation.
*/
onResolved?: (params: Pick<GiroIdentProperties, 'firstName' | 'lastName' | 'companyName'> & {
nameEquality?: boolean;
nameEqualityScore?: number;
}) => void;
}
export declare class GiroIdentBasis extends Widget<GiroIdentProperties, GiroIdentCallbacks> {
/**
* # GiroIdent Basis
* Checking and verifying the name. In the basic version, the given name is
* compared in real time with the first name and surname of the account holder.
*
* ## styleOverrides
* - `.startButton` - enables you to customize the button displayed on the
* initial view, which initiates the evaluation process
*
* @param container - parent HTML element where the widget will be injected
* @param target - URL of the environment from which the widget's JS bundle will be fetched. Use this, for example, when testing features that are only released to the sandbox environment. By default, `https://widget-library-finapi-general-live.finapi.io` is used.
* @param ownerDocument - parent Document where the widget will be injected. For example, shadow root or document fragment. By default, the default top-level document is used.
* @param customBundleFileName - allows modifying the filename of the widget's JS bundle that will be fetched. This property is useful during dev mode when widgets are generated together into one `main.js` file.
*/
constructor(container: HTMLElement, target?: string, ownerDocument?: Document, customBundleFileName?: string);
}