UNPKG

crapifyme

Version:

Ultra-fast developer productivity CLI tools - remove comments, logs, and more

115 lines 3.09 kB
export interface SvgStats { filesProcessed: number; filesSkipped: number; bytesProcessed: number; bytesOriginal: number; bytesOptimized: number; bytesSaved: number; avgCompressionRatio: number; operationsCompleted: number; processingTime: number; errors: Array<{ file: string; operation?: string; error: string; }>; warnings: Array<{ file: string; warning: string; }>; } export interface SvgOptimizationResult { inputPath: string; outputPath: string; originalSize: number; optimizedSize: number; compressionRatio: number; bytesSaved: number; pluginsApplied: string[]; processingTime: number; originalContent: string; optimizedContent: string; errors?: string[]; warnings?: string[]; } export interface SvgBatchResult { results: SvgOptimizationResult[]; stats: SvgStats; skippedFiles: string[]; failedFiles: Array<{ file: string; error: string; }>; } export interface SvgOptions { inPlace?: boolean; copy?: boolean; backup?: boolean; stdout?: boolean; outputDir?: string; preset?: 'minimal' | 'balanced' | 'aggressive'; config?: string; plugins?: string[] | string; precision?: number; keepIds?: boolean; keepTitles?: boolean; multipass?: boolean; glob?: string; recursive?: boolean; extensions?: string[] | string; exclude?: string[] | string; dryRun?: boolean; force?: boolean; parallel?: boolean; maxConcurrency?: number; watch?: boolean; verbose?: boolean; quiet?: boolean; json?: boolean; report?: string; sizeInfo?: boolean; inlineStyles?: boolean; removeViewbox?: boolean; sortAttrs?: boolean; removeXmlns?: boolean; minifyStyles?: boolean; convertColors?: boolean; validateInput?: boolean; validateOutput?: boolean; skipValidation?: boolean; } export interface SvgPreset { name: string; description: string; plugins: any[]; multipass?: boolean; precision?: number; options?: Record<string, any>; } export interface SvgValidationResult { isValid: boolean; errors: string[]; warnings: string[]; fileSize: number; hasViewBox: boolean; hasTitle: boolean; hasDesc: boolean; elementCount: number; } export interface SvgProcessingConfig { preset: SvgPreset; customPlugins: any[]; precision: number; multipass: boolean; keepIds: boolean; keepTitles: boolean; validateInput: boolean; validateOutput: boolean; } export declare const DEFAULT_SVG_EXTENSIONS: readonly ["svg"]; export type SupportedSvgExtension = (typeof DEFAULT_SVG_EXTENSIONS)[number]; export declare const SVG_PRESETS: Record<string, SvgPreset>; export declare function isSupportedSvgExtension(ext: string): ext is SupportedSvgExtension; export declare function getSvgPreset(name: string): SvgPreset; export declare function createProcessingConfig(options: SvgOptions): SvgProcessingConfig; //# sourceMappingURL=types.d.ts.map