chore: add automation page and improve lists

This commit is contained in:
Lio 2025-12-19 13:29:52 +01:00
parent 155b2bc649
commit 8af07f8071
7 changed files with 70 additions and 22 deletions

View file

@ -18,6 +18,9 @@ export default defineConfig({
adapter: bun(),
output: "server",
prefetch: true,
server: {
allowedHosts: ['callisto', 'callisto.end-fahrenheit.ts.net']
},
site: "https://lio.cat",
markdown: {
remarkRehype: {},

View file

@ -15,9 +15,9 @@ import { formatDate } from "~/utils"
class="my-3 flex flex-col visited:text-purple-500/90 md:my-2 md:flex-row"
>
<p
class={`flex ${dateWidth} flex-shrink-0 truncate text-sm text-gray-500 dark:text-gray-400 md:text-base`}
class={`flex ${dateWidth} shrink-0 truncate text-sm text-gray-500 dark:text-gray-400 md:text-base`}
>
<time>{formatDate(post.data.pubDate, dateFormat, lang)}</time>
<time>{formatDate(post.data.pubDate, "YYYY-MM-DD")}</time>
</p>
<p class="line-clamp-2 text-lg hover:underline">{post.data.title}</p>
</a>

View file

@ -33,8 +33,11 @@ const { Content } = await render(post)
<MainLayout post={{ ...post.data }}>
<article class="prose dark:prose-invert w-full max-w-3xl overflow-hidden">
<div class="flex flex-col gap-2">
<h2 class="!my-0 text-3xl font-semibold">{post.data.title}</h2>
<div class="my-3 text-gray-500 dark:text-white/80">
<h2 class="my-0! text-3xl font-semibold">{post.data.title}</h2>
<p class="my-0! text-md text-gray-700 dark:text-white/80">
{post.data.description}
</p>
<div class="text-sm text-gray-500 dark:text-white/80">
{formatDate(post.data.pubDate, "locale", lang)}
</div>
</div>
@ -47,7 +50,7 @@ const { Content } = await render(post)
{
post.data.tags.map((tag: string) => (
<a href={`/${lang}/tags/${tag}`} class="no-underline">
<p class="inline-block hover:scale-105">#{tag}</p>
<p class="inline-block hover:scale-105 bg-amber-500 dark:bg-amber-400 dark:text-black p-1">#{tag}</p>
</a>
))
}

32
src/pages/automation.mdx Normal file
View file

@ -0,0 +1,32 @@
---
layout: ../layouts/main.astro
title: Automations
description: Details about my Automations
---
# Automations
Welcome!
You're likely here because you followed a custom User-Agent from my various Automations/Projects.
<br/>
Here's a list of User-Agents I currently use when requesting content:
- `fangmarks/stasher (lio.to/stasher)`
- `fangmarks/stasher (lio.to)` (deprecated)
- `killswitch/v{version} (yiff.click)`
- `yiff/v{version} (wrwlf.de/yiff)`
<br/>
Requests may originate from the following Domains (and/or their Subdomains):
- `lio.to`
- `lio.cat`
- `lio.systems`
- `lio.gallery`
- `lio.domains`
- `himbo.cat`
<br/>
Detailed Deployment Domains/IPs may be provided [upon request](mailto:automations@lio.cat)

View file

@ -9,6 +9,30 @@ body {
font-family: "JetBrains Mono Variable", monospace;
}
@layer base { h1 { font-size: var(--text-2xl); } h2 { font-size: var(--text-xl); }}
code {
border-radius: 0.25rem;
background-color: rgba(249, 115, 22, 0.5);
padding-left: 0.25rem;
padding-right: 0.25rem;
}
.dark code {
background-color: rgba(249, 115, 22, 0.8);
}
code::before,
code::after {
content: none !important;
}
ol, ul {
list-style-type: "- ";
}
.nav-links,
.markdown-link {
text-decoration: none;
@ -27,6 +51,7 @@ body {
display: inline-block;
}
a:hover {
.nav-links:hover, .markdown-link:hover {
text-decoration: underline;
}

View file

@ -1,15 +0,0 @@
article code {
border-radius: 0.25rem;
background-color: rgba(249, 115, 22, 0.5);
padding-left: 0.25rem;
padding-right: 0.25rem;
}
.dark article code {
background-color: rgba(249, 115, 22, 0.8);
}
article code::before,
article code::after {
content: none !important;
}

View file

@ -38,7 +38,7 @@ export const getPostsByLocale = async (locale: string) => {
posts.forEach((post: any) => {
post.data.lang = locale
})
const filtered = posts.filter((p) => p.data.published)
const filtered = import.meta.env.MODE === 'development'? posts : posts.filter((p) => p.data.published)
return filtered.sort(
(a: any, b: any) => b.data.pubDate.valueOf() - a.data.pubDate.valueOf(),
)