fannypack-v5
Version:
An accessible, composable, and friendly React UI Kit
22 lines (21 loc) • 691 B
TypeScript
import { IconDefinition } from '@fortawesome/fontawesome-common-types';
export declare type FontAwesomeIconStandalone = {
iconName?: string;
width?: number;
height?: number;
svgPathData?: string;
};
export declare type ParsedIcon = IconDefinition | {
viewBoxHeight: number;
viewBoxWidth: number;
paths: Array<string>;
};
export declare type ParsedIcons = {
[key: string]: ParsedIcon;
};
export declare type Opts = {
prefix?: string;
type?: 'font-awesome' | 'font-awesome-standalone';
};
export declare type Icons = IconDefinition[] | FontAwesomeIconStandalone[];
export declare function parseIcons(icons: Icons, { prefix, type }?: Opts): ParsedIcons;