import type React from 'react'; export type OakIconLibraryPlatform = 'web' | 'wechatMp'; export type OakIconFontLibraryConfig = { name: string; type?: 'font'; fontFamily?: string; fontFamilyClass?: string; classPrefix?: string; style?: string | string[]; fontUrl?: string | string[]; fontFormat?: 'woff2' | 'woff' | 'truetype' | 'opentype' | string; icons?: Record; styleText?: string; subset?: boolean | 'auto'; platforms?: OakIconLibraryPlatform[]; }; export type OakIconReactLibraryConfig = { name: string; type: 'react'; icons?: Record; resolveIcon?: (name: string) => OakIconReactComponent | undefined; loadIcon?: (name: string) => Promise; packageName?: string; importPath?: string; platforms?: Extract[]; }; export type OakIconImageLibraryConfig = { name: string; type: 'image'; platforms?: OakIconLibraryPlatform[]; }; export type OakIconLibraryConfig = OakIconFontLibraryConfig | OakIconReactLibraryConfig | OakIconImageLibraryConfig; export type OakIconReactComponent = React.ElementType<{ className?: string; style?: React.CSSProperties; }>; export type OakIconReactModule = { default?: OakIconReactComponent | OakIconReactModule; };