// Icon.jsx — Lucide icon wrapper.
// Usage:
// Renders and triggers lucide.createIcons() after mount.
function Icon({ name, size = 20, strokeWidth = 1.75, color, style = {}, className = "" }) {
const ref = React.useRef(null);
React.useEffect(() => {
if (window.lucide && ref.current) {
ref.current.innerHTML = "";
const i = document.createElement("i");
i.setAttribute("data-lucide", name);
ref.current.appendChild(i);
window.lucide.createIcons({ attrs: { width: size, height: size, "stroke-width": strokeWidth } });
}
}, [name, size, strokeWidth]);
return (
);
}
window.Icon = Icon;