Something went wrong. Try again.
🌿 Collaborative wiki on ATProto forked from juprodh.me/lichen.wiki
Something went wrong. Try again.
123456789101112131415161718192021222324252627import { escapeHtml } from "../lib/html.ts";import type { WikiIdentity } from "../lib/wiki-identity.ts";import { type LayoutOptions, layout } from "./layout.ts";
export function notePage( wiki: WikiIdentity, noteTitle: string, renderedHtml: string, options?: LayoutOptions, wikiLanguage?: string,): string { const langAttr = wikiLanguage ? ` lang="${escapeHtml(wikiLanguage)}"` : ""; const content = ` <article class="prose max-w-none"${langAttr}> ${renderedHtml} </article> `; return layout(noteTitle, content, { ...options, wikiName: wiki.name, wikiSlug: wiki.slug, ownerHandle: wiki.handle, pageTitle: noteTitle, enableSearchShortcut: true, });}