- _data: switch to cachedFetch wrapper (10s timeout + 4h watch cache) - js/webmentions.js: owner reply threading, platform provenance badges, DOM dedup, Micropub reply support - js/comments.js: owner detection, reply system, Alpine.store integration - _includes/components/webmentions.njk: data-wm-* attrs, provenance badge slots, reply buttons - _includes/components/comments.njk: owner-aware comment form, threaded replies - widgets/toc.njk: Alpine.js tocScanner upgrade (replaces is-land/inline-JS) - lib/og.js + og-cli.js: OG card v3 (light theme, avatar, batched spawn, DESIGN_VERSION=3) - eleventy.config.js: hasOgImage cache, memoized date filters, batched OG/unfurl, post-build GC, YouTube check opt - base.njk: Inter font preloads + toc-scanner.js script - critical.css: font-face declarations (font-display:optional) - tailwind.css: font-display swap→optional - tailwind.config.js: prose link colors -700→-600 - Color design system: accent-700/300 → accent-600/400 across components Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
43 lines
1.7 KiB
Plaintext
43 lines
1.7 KiB
Plaintext
---
|
|
layout: layouts/base.njk
|
|
title: Search
|
|
permalink: /search/
|
|
eleventyExcludeFromCollections: true
|
|
pagefindIgnore: true
|
|
---
|
|
<div class="page-header mb-6 sm:mb-8">
|
|
<h1 class="text-2xl sm:text-3xl font-bold text-surface-900 dark:text-surface-100 mb-2">Search</h1>
|
|
<p class="text-surface-600 dark:text-surface-400">Search across all posts, articles, notes, and pages.</p>
|
|
</div>
|
|
|
|
<div id="search"></div>
|
|
<noscript>
|
|
<div class="p-6 bg-surface-100 dark:bg-surface-800 rounded-lg mt-4">
|
|
<p class="text-surface-700 dark:text-surface-300">Search requires JavaScript to be enabled. Please enable JavaScript in your browser settings to use the search feature.</p>
|
|
<p class="text-surface-600 dark:text-surface-400 text-sm mt-2">Alternatively, you can browse content via the <a href="/blog/" class="text-accent-600 dark:text-accent-400 hover:underline">blog archive</a> or <a href="/categories/" class="text-accent-600 dark:text-accent-400 hover:underline">categories</a>.</p>
|
|
</div>
|
|
</noscript>
|
|
|
|
<script>
|
|
initPagefind("#search", { showSubResults: true, showEmptyFilters: false });
|
|
|
|
// Support ?q= query parameter and auto-focus
|
|
window.addEventListener("DOMContentLoaded", () => {
|
|
const input = document.querySelector("#search input[type='text']");
|
|
if (input) {
|
|
// Pagefind generates the input without a label — add one
|
|
input.setAttribute("aria-label", "Search all content");
|
|
}
|
|
const params = new URLSearchParams(window.location.search);
|
|
const query = params.get("q");
|
|
if (query) {
|
|
if (input) {
|
|
input.value = query;
|
|
input.dispatchEvent(new Event("input", { bubbles: true }));
|
|
}
|
|
} else {
|
|
if (input) input.focus();
|
|
}
|
|
});
|
|
</script>
|