Skip to content
Closed
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 5 additions & 1 deletion src/layouts/Layout.astro
Original file line number Diff line number Diff line change
Expand Up @@ -67,7 +67,11 @@ const structuredData = {
<meta property="og:title" content={title} />
<meta property="og:description" content={description} />
<meta property="og:url" content={canonicalURL} />
<meta property="og:image" content={socialImageURL} />
<meta
property="og:image"
content={socialImageURL}
data-pagefind-default-meta="image[content]"
/>

<!-- Article Published/Modified time -->
{
Expand Down
10 changes: 7 additions & 3 deletions src/layouts/PostDetails.astro
Original file line number Diff line number Diff line change
Expand Up @@ -90,9 +90,9 @@ const nextPost =
"mx-auto w-full max-w-app px-4 pb-12",
{ "mt-8": !SITE.showBackButton },
]}
data-pagefind-body
>
<h1
data-pagefind-meta="title"
transition:name={slugifyStr(title)}
class="inline-block text-2xl font-bold text-accent sm:text-3xl"
>
Expand All @@ -102,7 +102,11 @@ const nextPost =
<Datetime {pubDatetime} {modDatetime} {timezone} size="lg" class="my-2" />
<EditPost class="max-sm:hidden" {hideEditPost} {post} />
</div>
<article id="article" class="mx-auto prose mt-8 max-w-app">
<article
id="article"
data-pagefind-body
class="mx-auto prose mt-8 max-w-app"
>
<Content />
</article>

Expand All @@ -121,7 +125,7 @@ const nextPost =
<hr class="my-6 border-dashed" />

<!-- Previous/Next Post Buttons -->
<div data-pagefind-ignore class="grid grid-cols-1 gap-6 sm:grid-cols-2">
<div class="grid grid-cols-1 gap-6 sm:grid-cols-2">
{
prevPost && (
<a
Expand Down
2 changes: 1 addition & 1 deletion src/pages/search.astro
Original file line number Diff line number Diff line change
Expand Up @@ -46,7 +46,7 @@ const backUrl = SITE.showBackButton ? `${Astro.url.pathname}` : "/";
const search = new PagefindUI({
element: "#pagefind-search",
showSubResults: true,
showImages: false,
showImages: true,
processTerm: function (term: string) {
params.set("q", term); // Update the `q` parameter in the URL
history.replaceState(history.state, "", "?" + params.toString()); // Push the new URL without reloading
Expand Down