From 5246e6e83b07fc975a4183a430f73361260d8ffd Mon Sep 17 00:00:00 2001 From: wearrrrr Date: Tue, 20 Feb 2024 13:58:27 -0600 Subject: [PATCH] Fix long standing bug with settings and lint. --- index.js | 15 ++- src/components/Footer.astro | 65 ++++++------ src/components/SettingsTablist.astro | 32 +++--- src/pages/[lang]/index.astro | 153 ++++++++++++++------------- tsconfig.json | 2 +- 5 files changed, 130 insertions(+), 137 deletions(-) diff --git a/index.js b/index.js index db577c2..278b6ec 100644 --- a/index.js +++ b/index.js @@ -42,7 +42,7 @@ const rammerheadScopes = [ const rammerheadSession = /^\/[a-z0-9]{32}/; function shouldRouteRh(req) { - const url = new URL(req.url, 'http://0.0.0.0'); + const url = new URL(req.url, "http://0.0.0.0"); return rammerheadScopes.includes(url.pathname) || rammerheadSession.test(url.pathname); } @@ -91,20 +91,19 @@ app.get("/search", async (req, res) => { try { const { query } = req.query; - const response = await fetch( - `http://api.duckduckgo.com/ac?q=${query}&format=json` - ).then((apiRes) => apiRes.json()); - + const response = await fetch(`http://api.duckduckgo.com/ac?q=${query}&format=json`).then( + (apiRes) => apiRes.json() + ); + res.send(response); } catch (err) { res.redirect(302, "/404.html"); } }); -app.get('*', function(req, res){ - res.redirect(302, '/404.html'); +app.get("*", function (req, res) { + res.redirect(302, "/404.html"); }); - console.log(chalk.gray("Starting Alu...")); console.log(chalk.green("Alu started successfully!")); server.on("listening", () => { diff --git a/src/components/Footer.astro b/src/components/Footer.astro index a55f681..a887a3f 100644 --- a/src/components/Footer.astro +++ b/src/components/Footer.astro @@ -29,40 +29,39 @@ const t = useTranslations(lang); - - + a { + color: var(--text-color); + } + diff --git a/src/components/SettingsTablist.astro b/src/components/SettingsTablist.astro index a3c70c3..fddd17b 100644 --- a/src/components/SettingsTablist.astro +++ b/src/components/SettingsTablist.astro @@ -47,14 +47,14 @@ const t = useTranslations(lang);