CoCalc Logo Icon
StoreFeaturesDocsShareSupportNewsAboutSign UpSign In
sagemathinc

Real-time collaboration for Jupyter Notebooks, Linux Terminals, LaTeX, VS Code, R IDE, and more,
all in one place.

GitHub Repository: sagemathinc/cocalc
Path: blob/master/src/packages/next/components/share/user.tsx
Views: 687
1
import Link from "next/link";
2
import { trunc } from "lib/share/util";
3
import Avatar from "components/account/avatar";
4
5
interface Props {
6
account_id: string;
7
first_name?: string;
8
last_name?: string;
9
}
10
11
export default function User({ account_id, first_name, last_name }: Props) {
12
return (
13
<Link href={`/share/accounts/${account_id}`}>
14
<Avatar account_id={account_id} style={{ marginRight: "5px" }} />
15
{trunc(`${first_name} ${last_name}`, 50)}
16
</Link>
17
);
18
}
19
20