import { Handlers, PageProps } from "$fresh/server.ts"; import { MainLayout } from "@components/layouts/main.tsx"; import { getMovie, Movie } from "@lib/resource/movies.ts"; import { RecipeHero } from "@components/RecipeHero.tsx"; import { HashTags } from "@components/HashTags.tsx"; import { renderMarkdown } from "@lib/documents.ts"; import { KMenu } from "@islands/KMenu.tsx"; import { RedirectSearchHandler } from "@islands/Search.tsx"; export const handler: Handlers = { async GET(_, ctx) { const movie = await getMovie(ctx.params.name); return ctx.render({ movie, session: ctx.state.session }); }, }; export default function Greet( props: PageProps<{ movie: Movie; session: Record }>, ) { const { movie, session } = props.data; const { author = "", date = "" } = movie.meta; const content = renderMarkdown(movie.description || ""); return ( ${movie.name}`} context={movie}> {movie.tags.length > 0 && ( <>
)}
{movie?.description?.length > 80 ?

Review

: <>}
          {content}
        
); }