diff --git a/packages/core/src/index.ts b/packages/core/src/index.ts index b418067..40b1922 100644 --- a/packages/core/src/index.ts +++ b/packages/core/src/index.ts @@ -248,9 +248,29 @@ declare module "@monicon/icon-loader" { export type MoniconIconName = ${iconNamesAsCode}; export type MoniconProps = { + /** + * The name of the icon to render. + * + * @example "mdi:home" + * + * For TypeScript users, you must check https://monicon-docs.vercel.app/troubleshooting/typescript for more information. + */ name: MoniconIconName; + /** + * The size of the icon. + * + * @default icon collection size + */ size?: number; + /** + * The color of the icon. + * + * @default "currentColor" + */ color?: string; + /** + * The stroke width of the icon. This feature is only available for limited icon collections. + */ strokeWidth?: number; }; } diff --git a/packages/icon-loader/src/index.ts b/packages/icon-loader/src/index.ts index 422951c..d3e6ce8 100644 --- a/packages/icon-loader/src/index.ts +++ b/packages/icon-loader/src/index.ts @@ -4,9 +4,29 @@ import { parseSync, stringify } from "svgson"; import icons from "@monicon/runtime"; export type MoniconProps = { + /** + * The name of the icon to render. + * + * @example "mdi:home" + * + * For TypeScript users, you must check https://monicon-docs.vercel.app/troubleshooting/typescript for more information. + */ name: string; + /** + * The size of the icon. + * + * @default icon collection size + */ size?: number; + /** + * The color of the icon. + * + * @default "currentColor" + */ color?: string; + /** + * The stroke width of the icon. This feature is only available for limited icon collections. + */ strokeWidth?: number; };