on master help sign in
pages: add next/link imports
commit30609e5c9d8de7a62226e3e4000f021f6b260088 authorMatilde Park <matilde.park@urbit.org> dateSat 23 Apr 2022, 23:29 (4 years ago) parent58d9f02
3 files changed+8−2
pages/grants/[slug].js+1 pages/media/[slug].js+1 pages/updates/[slug].js+6−2
pages/grants/[slug].js+1
@@ -6,6 +6,7 @@ import {
66 getSimilarGrants,
77} from "../../lib/lib";
88import Head from "next/head";
9+import Link from "next/link";
910import Meta from "../../components/Meta";
1011import { decode } from "html-entities";
1112import classnames from "classnames";
pages/media/[slug].js+1
@@ -6,6 +6,7 @@ import {
66 generateDisplayDate,
77} from "../../lib/lib";
88import Head from "next/head";
9+import Link from "next/link";
910import Meta from "../../components/Meta";
1011import ErrorPage from "../404";
1112import Container from "../../components/Container";
pages/updates/[slug].js+6−2
@@ -47,8 +47,12 @@ export default function Post({
4747 {post.author}
4848 </div>
4949 ) : null}
50− {post.ship ? (
51− <div className="type-ui text-wall-500 font-mono">{post.ship}</div>
50+ {post?.extra?.ship ? (
51+ <Link href={`/id/${post.extra.ship}`}>
52+ <a className="type-sub-bold text-wall-500 font-mono">
53+ {post?.extra?.ship}
54+ </a>
55+ </Link>
5256 ) : null}
5357 <div className="type-ui text-wall-500 mt-4 md:mt-8 lg:mt-10">
5458 {formatDate(date)}