@liquid-js/qr-code-styling
Version:
Generate styled QR codes on web or in Node
19 lines (18 loc) • 751 B
TypeScript
import { QRCodeStyling } from '../core/qr-code-styling.js';
import { RecursivePartial } from '../types/helper.js';
import { CanvasOptions } from '../utils/canvas-options.js';
export declare enum FileExtension {
svg = "svg",
png = "png",
jpeg = "jpeg",
webp = "webp"
}
export declare function drawToCanvas(qrCode: QRCodeStyling, options?: RecursivePartial<CanvasOptions>): {
canvas: HTMLCanvasElement;
canvasDrawingPromise: Promise<void> | undefined;
} | undefined;
export declare function download(qrCode: QRCodeStyling, downloadOptions?: {
name?: string;
extension: `${FileExtension}`;
}, options?: RecursivePartial<CanvasOptions>): Promise<void>;
export declare function downloadURI(uri: string, name: string): void;