import { type LinearGradientOrientationConfig } from "../style/QrColor"; import { type IQrShape } from "../style/shapes/QrShape"; import { QrTimingLineShape } from "../style/shapes/QrTimingLineShape"; import { QrShapes } from "../options/QrShapes"; export interface QrShapesConfig { qrCode?: QrShapeConfig; matrixPixel?: QrMatrixPixelShapeConfig; eye?: QrEyeShapeConfig; eyeFrame?: QrEyeFrameShapeConfig; logo?: QrLogoShapeConfig; timingLine?: QrTimingLineShapeConfig; background?: QrBackgroundConfig; alignmentPattern?: QrAlignmentPatternShapeConfig; } export declare function createQrShapesFromConfig(config: QrShapesConfig): QrShapes; export interface QrAlignmentPatternShapeConfig { type: "Square" | "Circle"; pixelShape: QrPixelShapeConfig; color?: QrColorConfig; } export interface QrBackgroundConfig { image?: string; color?: QrColorConfig; } export interface QrEyeFrameShapeConfig { type: "Square" | "Circle"; pixelShape: QrPixelShapeConfig; color?: QrColorConfig; } type QrEyeShapeType = "Square" | "Circle" | "Rhombus"; interface QrEyeShapeBaseConfig { type: QrEyeShapeType; color?: QrColorConfig; } interface QrEyeShapeClassicConfig extends QrEyeShapeBaseConfig { type: "Circle" | "Rhombus"; } interface QrEyeShapeRoundedConfig extends QrEyeShapeBaseConfig { type: "Square"; cornerRadius?: number; } export type QrEyeShapeConfig = QrEyeShapeClassicConfig | QrEyeShapeRoundedConfig; export interface QrLogoShapeConfig { type: "Circle" | "Square" | "Rhombus"; image?: string | null; sizeRatio?: number; padding?: number; color?: QrColorConfig; } export interface QrMatrixPixelShapeConfig { pixelShape?: QrPixelShapeConfig; color?: QrColorConfig; } type QrPixelShapeType = "Square" | "Circle" | "RoundCorners" | "StickyCorners" | "Rhombus" | "Star" | "RoundCornersVertical" | "RoundCornersHorizontal" | "Hexagon" | "Octagon"; interface QrPixelShapeBase { type: QrPixelShapeType; sizeRatio?: number; } interface QrPixelShapeBasic extends QrPixelShapeBase { type: "Circle" | "Square" | "Rhombus" | "Star" | "Hexagon" | "Octagon"; } interface QrPixelShapeWithRadius extends QrPixelShapeBase { type: "RoundCorners" | "StickyCorners" | "RoundCornersVertical" | "RoundCornersHorizontal"; cornerRadius?: number; } export type QrPixelShapeConfig = QrPixelShapeBasic | QrPixelShapeWithRadius; export type QrShapeType = "Circle" | "Square"; export interface QrShapeConfig { type: QrShapeType; seed?: number; } export declare function createQrShape(config: QrShapeConfig): IQrShape; export interface QrTimingLineShapeConfig { pixelShape: QrPixelShapeConfig; color?: QrColorConfig; } export declare function createQrTimingLineShape(config: QrTimingLineShapeConfig): QrTimingLineShape; export type QrColorConfig = { type: "Solid"; value: string; } | { type: "LinearGradient"; colors: Array<[number, string]>; orientation: LinearGradientOrientationConfig; } | { type: "RadialGradient"; colors: Array<[number, string]>; radius?: number; } | { type: "SweepGradient"; colors: Array<[number, string]>; }; export {};