@stacksjs/stx
Version:
A performant UI Framework. Powered by Bun.
39 lines • 1.17 kB
TypeScript
import type { PwaIconConfig, StxOptions } from '../types';
/**
* Generate PWA icons from a source image
*
* @param options - stx configuration options
* @param outputDir - Output directory for generated icons
* @returns Result object with success status and file paths
*/
export declare function generatePwaIcons(options: StxOptions, outputDir: string): Promise<IconGenerationResult>;
/**
* Get list of icon paths that will be generated
* Useful for manifest generation and cache precaching
*/
export declare function getExpectedIconPaths(config: PwaIconConfig): string[];
/**
* Check if sharp is available
*/
export declare function isSharpAvailable(): Promise<boolean>;
/**
* Default icon sizes for PWA
*/
export declare const DEFAULT_ICON_SIZES: readonly [72, 96, 128, 144, 152, 192, 384, 512];
/**
* Apple touch icon sizes
*/
export declare const APPLE_TOUCH_ICON_SIZES: readonly [120, 152, 167, 180];
/**
* Favicon sizes
*/
export declare const FAVICON_SIZES: readonly [16, 32];
/**
* Icon generation result
*/
export declare interface IconGenerationResult {
success: boolean
generatedFiles: string[]
errors: string[]
warnings: string[]
}