Compare commits

..

No commits in common. "65d4be56adf358c50184e7b996a9483af7aab1a6" and "d33b2be49e982b4fa2dfadc3ff93427792119eba" have entirely different histories.

7 changed files with 9 additions and 10 deletions

View file

@ -60,7 +60,7 @@
const html = results const html = results
.map(result => ` .map(result => `
<div class="search-result"> <div class="search-result">
<a href="/post/${result.item.slug}"> <a href="/blog/${result.item.slug}">
<span class="result-title">${result.item.title}</span> <span class="result-title">${result.item.title}</span>
<span class="result-date">${new Date(result.item.pubDate).toISOString().split('T')[0]}</span> <span class="result-date">${new Date(result.item.pubDate).toISOString().split('T')[0]}</span>
</a> </a>

View file

@ -18,13 +18,11 @@ const formattedRootPath = defaultTitle.toLowerCase().replace(/\s+/g, '-');
const relativePath = Astro.url.pathname const relativePath = Astro.url.pathname
const path = formattedRootPath + (relativePath === '/' ? '' : relativePath) const path = formattedRootPath + (relativePath === '/' ? '' : relativePath)
const pageTitle = (relativePath === '/' ? defaultTitle : `${Astro.props.title} - ${defaultTitle}`)
const navBarItems = siteConfig.navBarItems const navBarItems = siteConfig.navBarItems
const customFooter = siteConfig.customFooter const customFooter = siteConfig.customFooter
const nekoType = siteConfig.neko?.type const nekoType = siteConfig.neko?.type
const { title = pageTitle, description = siteConfig.description, ogImage = "" } = Astro.props; const { title, description = siteConfig.description, ogImage = "" } = Astro.props;
--- ---
<!doctype html> <!doctype html>
@ -34,8 +32,8 @@ const { title = pageTitle, description = siteConfig.description, ogImage = "" }
<meta name="viewport" content="width=device-width" /> <meta name="viewport" content="width=device-width" />
<link rel="icon" type="image/svg+xml" href="/favicon.svg" /> <link rel="icon" type="image/svg+xml" href="/favicon.svg" />
<meta name="generator" content={Astro.generator} /> <meta name="generator" content={Astro.generator} />
<Meta title={pageTitle} description={description} ogImage={ogImage} /> <Meta title={title} description={description} ogImage={ogImage} />
<title>{pageTitle}</title> <title>{title}</title>
</head> </head>
<body> <body>
<main> <main>

View file

@ -4,7 +4,7 @@ import Layout from '../layouts/Layout.astro';
const url = Astro.url.pathname const url = Astro.url.pathname
--- ---
<Layout title="404" description="Page not found"> <Layout title="404 | Terminal Blog" description="Page not found">
<h1 class="title">command not found.</h1> <h1 class="title">command not found.</h1>
<div class="content"> <div class="content">

View file

@ -13,7 +13,7 @@ const { Content } = await entry.render();
--- ---
<Layout title={entry.data.title} description={entry.data.description} > <Layout title={`${entry.data.title} | Terminal Blog`} path={`/var/log/${entry.slug}`} description={entry.data.description} >
<h1 class="title">{entry.data.title}</h1> <h1 class="title">{entry.data.title}</h1>
<div class="content"> <div class="content">
<Content/> <Content/>

View file

@ -6,7 +6,7 @@ const posts = await getCollection('posts');
posts.sort((a, b) => new Date(b.data.pubDate).getTime() - new Date(a.data.pubDate).getTime()); posts.sort((a, b) => new Date(b.data.pubDate).getTime() - new Date(a.data.pubDate).getTime());
--- ---
<Layout title="Blog Posts" description="List all files and folders in the directory."> <Layout title="Blog | Terminal Blog" description="List all files and folders in the directory.">
<h1 class="title">~/blog</h1> <h1 class="title">~/blog</h1>
<div class="content"> <div class="content">

View file

@ -3,7 +3,7 @@ import Layout from '../layouts/Layout.astro';
--- ---
<Layout description="That a good start."> <Layout title="Home | Terminal Blog" description="That a good start.">
<h1 class="title">~/</h1> <h1 class="title">~/</h1>
<div class="content"> <div class="content">
<h3>Welcome!</h3> <h3>Welcome!</h3>

View file

@ -35,6 +35,7 @@ const cover = customFeaturedImage || matchedImage_src?.src || `/post/${slug}/fea
<Layout <Layout
title={entry.data.title} title={entry.data.title}
path={`~/grassblock/micr0blog/blog/${slug}`}
description={entry.data.description} description={entry.data.description}
ogImage={cover} ogImage={cover}
> >