Files
sage-home/components/mdx/Aside.tsx
砂糖 70f337bb92 init
2026-01-24 16:54:44 +08:00

30 lines
660 B
TypeScript

import { cn } from "@/lib/utils";
interface AsideProps {
icon?: string;
children?: React.ReactNode;
type?: "default" | "warning" | "danger";
}
export function Aside({
children,
icon,
type = "default",
...props
}: AsideProps) {
return (
<div
className={cn(
"flex border-5 py-3 px-4 ms-2 ms-md-0 my-10 rounded rounded-1 shadow",
"bg-[#6edff633] border-[#6edff633] border-l-[#f6ef6e]"
)}
{...props}
>
<div className="rounded rounded-1 text-center h-8 w-8 bg-[#6edff6] text-2xl relative top-[-30px] left-[-30px]">
{icon || "💡"}
</div>
<div>{children}</div>
</div>
);
}