// Inline SVG-Icons für Stack-Items. Klein, theme-aware (currentColor),
// monospace-friendly. Keine externe Library, kein CDN, keine Hydration.
import type { ReactNode } from "react";
type IconProps = { className?: string; title?: string };
function S({ children, title, className }: { children: ReactNode; title?: string; className?: string }) {
return (
);
}
export const StackIcons = {
typescript: (p: IconProps) => (
),
node: (p: IconProps) => (
),
python: (p: IconProps) => (
),
rust: (p: IconProps) => (
),
sqlite: (p: IconProps) => (
),
tailwind: (p: IconProps) => (
),
react: (p: IconProps) => (
),
docker: (p: IconProps) => (
),
gitea: (p: IconProps) => (
),
next: (p: IconProps) => (
),
nix: (p: IconProps) => (
),
hermes: (p: IconProps) => (
),
shell: (p: IconProps) => (
),
selfhost: (p: IconProps) => (
),
};
// Mapping: Token-Name → Icon-Komponente. Fallback: shell-icon.
export function StackIcon({ name, className, title }: { name: string; className?: string; title?: string }) {
const key = name.toLowerCase().trim();
for (const [k, c] of Object.entries(StackIcons)) {
if (key.includes(k)) return c({ className, title });
}
return StackIcons.shell({ className, title });
}