跳到主要内容

lucideToSvgElement()

function lucideToSvgElement(
icon,
color,
size?
): SVGSVGElement;

Defined in: packages/rxdb-model/src/entity-table/editors/lucide-svg.ts:55

将 LucideIconData 转为内联 SVG 元素(DOM API 构造,免疫标记注入)

Parameters​

ParameterTypeDefault valueDescription
iconIconDataundefinedlucide 图标数据
colorstringundefinedstroke 颜色(不合法时回退 currentColor)
sizenumber13宽高像素,默认 13

Returns​

SVGSVGElement

内联 SVG 元素