on master help sign in
components: wrap event patps in links to id pages
commit25cc2c64cbcdbf82943d1a81fa0c895b35b2d965 authorMatilde Park <matilde.park@urbit.org> dateWed 15 Jun 2022, 13:31 (4 years ago) parent3055056
1 file changed+8−1
components/Snippets.js+8−1
components/Snippets.js+8−1
@@ -1,3 +1,4 @@
1+import Link from "next/link";
12import {
23 getAllEvents,
34 generateDisplayDate,
@@ -12,7 +13,13 @@ export function Name({ children, className }) {
1213}
1314
1415export function Patp({ children, className }) {
15− return <code className={`font-mono ${className || ""}`}>{children}</code>;
16+ return (
17+ <Link href={`/ids/${children}`} passHref>
18+ <a>
19+ <code className={`font-mono ${className || ""}`}>{children}</code>
20+ </a>
21+ </Link>
22+ );
1623}
1724
1825// Used to render a human name alongside their @p