UNPKG

react-girocode

Version:

A react component for displaying an EPC-QR-Code

25 lines (24 loc) 762 B
import { Encoding, Identification, ServiceTag, StringOfLength, Version } from "."; interface BasicEpcQrCode { serviceTag: ServiceTag; version: Version; encoding: Encoding; identification: Identification; bic?: string; recipient: StringOfLength<70>; iban: string; amount?: number; purpose?: StringOfLength<4>; information?: StringOfLength<70>; } interface EpcQrCodeWithReference extends BasicEpcQrCode { reference?: StringOfLength<25>; text?: never; } interface EpcQrCodeWithText extends BasicEpcQrCode { reference?: never; text?: StringOfLength<140>; } export type EpcQrCode = EpcQrCodeWithReference | EpcQrCodeWithText; export declare const epcQrCodeToString: (epcQrCode: EpcQrCode) => string; export {};