import { wwwAPIPath } from "@/utilities/wwwAPI"; import Image from "next/image"; import { ReactNode } from "react"; import { Col } from "reactstrap"; export default function AvatarTitle({ avatarID, avatarName, children, }: { avatarID: string; avatarName: string; children?: ReactNode; }) { return ( <> <Col className="m-1" xs="auto" onClick={(e) => { e.stopPropagation(); }} > <Image alt="" src={`${wwwAPIPath}/avatar/drawing${avatarID ? `/${avatarID}` : ""}`} className="avatar" width={48} height={48} /> </Col> <Col className="m-1"> <span>{avatarName}</span> <br /> {children} </Col> </> ); }