From a84908b7e8a0e2423afd6b836eccf27a420270b4 Mon Sep 17 00:00:00 2001 From: nsfisis Date: Wed, 20 Sep 2023 19:56:52 +0900 Subject: feat(blog/nuldoc): change content format from DocBook to NulDoc --- vhosts/blog/nuldoc-src/pages/post.ts | 10 +++++----- vhosts/blog/nuldoc-src/pages/slide.ts | 2 +- 2 files changed, 6 insertions(+), 6 deletions(-) (limited to 'vhosts/blog/nuldoc-src/pages') diff --git a/vhosts/blog/nuldoc-src/pages/post.ts b/vhosts/blog/nuldoc-src/pages/post.ts index 24a6d5f5..ade0916a 100644 --- a/vhosts/blog/nuldoc-src/pages/post.ts +++ b/vhosts/blog/nuldoc-src/pages/post.ts @@ -4,13 +4,13 @@ import { globalHeader } from "../components/global_header.ts"; import { pageLayout } from "../components/page_layout.ts"; import { Config, getTagLabel } from "../config.ts"; import { el, Element, text } from "../dom.ts"; -import { Document } from "../docbook/document.ts"; +import { Document } from "../ndoc/document.ts"; import { Page } from "../page.ts"; import { Date, dateToString, Revision } from "../revision.ts"; export interface PostPage extends Page { title: string; - summary: string; + description: string; tags: string[]; revisions: Revision[]; } @@ -112,7 +112,7 @@ export async function generatePostPage( const html = await pageLayout( { metaCopyrightYear: getPostCreatedDate(doc).year, - metaDescription: doc.summary, + metaDescription: doc.description, metaKeywords: doc.tags.map((slug) => getTagLabel(config, slug)), metaTitle: `${doc.title} | ${config.blog.siteName}`, requiresSyntaxHighlight: true, @@ -124,7 +124,7 @@ export async function generatePostPage( const cwd = Deno.cwd(); const contentDir = join(cwd, config.locations.contentDir); const destFilePath = join( - doc.sourceFilePath.replace(contentDir, "").replace(".xml", ""), + doc.sourceFilePath.replace(contentDir, "").replace(".ndoc", ""), "index.html", ); return { @@ -133,7 +133,7 @@ export async function generatePostPage( destFilePath: destFilePath, href: destFilePath.replace("index.html", ""), title: doc.title, - summary: doc.summary, + description: doc.description, tags: doc.tags, revisions: doc.revisions, }; diff --git a/vhosts/blog/nuldoc-src/pages/slide.ts b/vhosts/blog/nuldoc-src/pages/slide.ts index a75aeb68..ad56fee3 100644 --- a/vhosts/blog/nuldoc-src/pages/slide.ts +++ b/vhosts/blog/nuldoc-src/pages/slide.ts @@ -122,7 +122,7 @@ export async function generateSlidePage( const cwd = Deno.cwd(); const contentDir = join(cwd, config.locations.contentDir); const destFilePath = join( - slide.sourceFilePath.replace(contentDir, "").replace(".xml", ""), + slide.sourceFilePath.replace(contentDir, "").replace(".toml", ""), "index.html", ); return { -- cgit v1.2.3-70-g09d2