import Image from "next/future/image";
export default function ResolvedIcon({ icon }) {
// direct or relative URLs
if (icon.startsWith("http") || icon.startsWith("/")) {
return ;
}
// mdi- prefixed, material design icons
if (icon.startsWith("mdi-")) {
const iconName = icon.replace("mdi-", "").replace(".svg", "");
return (
);
}
// fallback to dashboard-icons
const iconName = icon.replace(".png", "");
return (
);
}