diff --git a/components/PageHero.tsx b/components/PageHero.tsx index ab0cb74..5304da0 100644 --- a/components/PageHero.tsx +++ b/components/PageHero.tsx @@ -47,29 +47,25 @@ function Title( { children, link }: { children: ComponentChildren; link?: string }, ) { const ctx = useContext(HeroContext); + + const OuterTag = link ? "a" : "div"; + return ( -

{children} {link && - ( - - - - )} + }

-
+ ); } diff --git a/lib/cache/image.ts b/lib/cache/image.ts index 70176b9..8ce5c0f 100644 --- a/lib/cache/image.ts +++ b/lib/cache/image.ts @@ -178,6 +178,6 @@ export async function setImage( ? { suffix: opts.suffix } : { width: opts.width, height: opts.height }), }), - { expires: 60 * 60 * 24 }, + { expires: 60 * 60 * 24 * 7 /* 1 week */ }, ); } diff --git a/routes/_layout.tsx b/routes/_layout.tsx index 89aa89c..6f49c43 100644 --- a/routes/_layout.tsx +++ b/routes/_layout.tsx @@ -1,10 +1,10 @@ -import { LayoutProps } from "$fresh/server.ts"; +import { PageProps } from "$fresh/server.ts"; import { resources } from "@lib/resources.ts"; import { CSS, KATEX_CSS } from "https://deno.land/x/gfm@0.2.5/mod.ts"; -import { Head, Partial } from "$fresh/runtime.ts"; +import { Head } from "$fresh/runtime.ts"; import { Emoji } from "@components/Emoji.tsx"; -export default function MyLayout({ Component }: LayoutProps) { +export default function MyLayout({ Component }: PageProps) { return (
{CSS} -
);