mirror of
https://github.com/hanzoai/o11y-components.git
synced 2026-10-30 14:54:15 +00:00
* fix(package): better compatibility with cjs/esm * refactor(components): try optimize bundle output * refactor(index): use tailwind config * feat(vite): migrate from tsdown * feat(biome): migrate from eslint * fix(vite): last config to correct d.ts of cjs
24 lines
613 B
TypeScript
24 lines
613 B
TypeScript
interface IconProps extends React.SVGProps<SVGSVGElement> {
|
|
size?: number | string;
|
|
strokeWidth?: number;
|
|
className?: string;
|
|
}
|
|
|
|
export interface IconManifest {
|
|
name: string;
|
|
component: React.ComponentType<IconProps>;
|
|
category: string;
|
|
tags: string[];
|
|
}
|
|
|
|
// Import all icons
|
|
import * as Icons from '@signozhq/icons';
|
|
|
|
// Create manifest
|
|
export const iconsManifest: IconManifest[] = Object.entries(Icons).map(([name, component]) => ({
|
|
name,
|
|
component: component as React.ComponentType<IconProps>,
|
|
category: name.includes('Solid') ? 'Solid' : 'Outline',
|
|
tags: name.toLowerCase().split(/(?=[A-Z])/),
|
|
}));
|