import React, { ReactElement, ReactNode } from "react";
import {
LightBulbIcon,
ExclamationIcon,
ExclamationCircleIcon,
InformationCircleIcon,
} from "@heroicons/react/solid";
const THEMES = {
info: {
classes:
"bg-blue-100 text-blue-800 dark:text-blue-300 dark:bg-blue-200 dark:bg-opacity-10",
icon: ,
},
idea: {
classes:
"bg-gray-100 text-gray-800 dark:text-gray-300 dark:bg-gray-200 dark:bg-opacity-10",
icon: ,
},
error: {
classes:
"bg-red-200 text-red-900 dark:text-red-200 dark:bg-red-600 dark:bg-opacity-30",
icon: ,
},
default: {
classes:
"bg-orange-100 text-orange-800 dark:text-orange-300 dark:bg-orange-200 dark:bg-opacity-10",
icon: ,
},
};
export default function Callout({
children,
type = "default",
icon,
}: {
children: ReactNode;
type: keyof typeof THEMES;
icon?: ReactElement;
}) {
return (
{icon || THEMES[type].icon}
{children}
);
}