From 694feb083d2ec4e9e24aa4a5e3269f54a3b60d22 Mon Sep 17 00:00:00 2001 From: Max Richter Date: Sat, 10 Jan 2026 15:06:43 +0100 Subject: [PATCH] fix: remove all linter errors --- assets/style.css | 2 + client.ts | 2 +- components/Checkbox.tsx | 64 +- components/MetaTags.tsx | 1 + components/Stars.tsx | 4 +- deno.json | 47 +- deno.lock | 567 ++++-------------- lib/image.ts | 8 +- lib/openai.ts | 6 +- lib/promise.ts | 10 +- lib/recommendation.ts | 11 +- lib/thumbhash.ts | 6 +- lib/webScraper.ts | 18 +- lib/youtube.ts | 4 +- routes/_app.tsx | 5 +- routes/_middleware.ts | 2 +- routes/api/articles/create/index.ts | 24 +- static/styles.css | 3 - static/thumbhash.js | 1 + ...timestamp-1768053860058-b3b215439a75c8.mjs | 14 + 20 files changed, 206 insertions(+), 593 deletions(-) delete mode 100644 static/styles.css create mode 100644 vite.config.ts.timestamp-1768053860058-b3b215439a75c8.mjs diff --git a/assets/style.css b/assets/style.css index f1d8c73..9efd3cf 100644 --- a/assets/style.css +++ b/assets/style.css @@ -1 +1,3 @@ @import "tailwindcss"; +@source "../components/*" +@source "../components/**/*" diff --git a/client.ts b/client.ts index 68a8d5a..aac395d 100644 --- a/client.ts +++ b/client.ts @@ -1 +1 @@ -// import "./assets/style.css"; +import "./assets/style.css"; diff --git a/components/Checkbox.tsx b/components/Checkbox.tsx index c35fdc1..3a085ae 100644 --- a/components/Checkbox.tsx +++ b/components/Checkbox.tsx @@ -1,67 +1,5 @@ import { Signal, useSignal } from "@preact/signals"; -import { useId, useState } from "preact/hooks"; - -interface CheckboxProps { - label: string; - isChecked?: boolean; - onChange: (isChecked: boolean) => void; -} - -const Checkbox2: preact.FunctionalComponent = ( - { label, isChecked = false, onChange }, -) => { - const [checked, setChecked] = useState(isChecked); - - const toggleCheckbox = () => { - const newChecked = !checked; - setChecked(newChecked); - onChange(newChecked); - }; - - return ( -
- - {label} - - -
- ); -}; +import { useId } from "preact/hooks"; const Checkbox = ( { label, checked = useSignal(false) }: { diff --git a/components/MetaTags.tsx b/components/MetaTags.tsx index b43aa71..b71255f 100644 --- a/components/MetaTags.tsx +++ b/components/MetaTags.tsx @@ -60,6 +60,7 @@ export function MetaTags({ resource }: { resource: GenericResource }) { />