chore: cleanup and refactor
This commit is contained in:
parent
b6fb54ab98
commit
5295a6eacc
37 changed files with 285 additions and 356 deletions
37
src/pages/search.html
Normal file
37
src/pages/search.html
Normal file
|
@ -0,0 +1,37 @@
|
|||
---
|
||||
title: /Search
|
||||
layout: default
|
||||
permalink: /search.html
|
||||
---
|
||||
|
||||
<link href="https://coryd.dev/pagefind/pagefind-ui.css" rel="stylesheet" />
|
||||
<style>
|
||||
:root {
|
||||
--pagefind-ui-font: silka, Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont,
|
||||
Segoe UI, Roboto, Helvetica Neue, Arial, Noto Sans, sans-serif, Apple Color Emoji,
|
||||
Segoe UI Emoji, Segoe UI Symbol, Noto Color Emoji;
|
||||
--pagefind-ui-primary: #374151;
|
||||
--pagefind-ui-text: #374151;
|
||||
}
|
||||
@media (prefers-color-scheme: dark) {
|
||||
:root {
|
||||
--pagefind-ui-primary: #e5e7eb;
|
||||
--pagefind-ui-text: #e5e7eb;
|
||||
--pagefind-ui-background: #152028;
|
||||
--pagefind-ui-border: #152028;
|
||||
--pagefind-ui-tag: #152028;
|
||||
}
|
||||
}
|
||||
</style>
|
||||
<div id="/search" class="/search"></div>
|
||||
<script
|
||||
src="https://coryd.dev/_pagefind/pagefind-ui.js"
|
||||
onload="new PagefindUI({ element: '#/search', showImages: false, processTerm: (term) => {
|
||||
try{
|
||||
plausible('/Search', {props: {method: 'Text', term}});
|
||||
} catch(e){};
|
||||
return term;
|
||||
}
|
||||
});"
|
||||
></script>
|
||||
{% render "partials/popular-posts.liquid", posts: collections.posts, analytics: analytics %}
|
Reference in a new issue