From 5f37fc66b04289ff827eca91d7a3ac1338be194d Mon Sep 17 00:00:00 2001 From: Noa Virellia Date: Tue, 27 Jan 2026 16:25:02 +0800 Subject: [PATCH] style: apply Biome config and normalize quotes Signed-off-by: Noa Virellia --- .zed/settings.json | 3 + astro.config.mjs | 8 +- biome.json | 35 ++++++ package.json | 1 + pnpm-lock.yaml | 91 ++++++++++++++ src/components/AboutPage.tsx | 12 +- src/components/ContactPage.tsx | 22 ++-- src/components/ExplorePage.tsx | 216 ++++++++++++++++----------------- src/components/FaqPage.tsx | 48 ++++---- src/components/GuidePage.tsx | 42 +++---- src/components/HomePage.tsx | 108 ++++++++++------- src/components/JoinPage.tsx | 30 ++--- src/components/PrivacyPage.tsx | 4 +- src/layouts/Layout.astro | 10 +- src/lib/canvas-nest.d.ts | 2 +- src/lib/utils.ts | 4 +- src/pages/about.astro | 4 +- src/pages/contact.astro | 4 +- src/pages/explore.astro | 4 +- src/pages/faq.astro | 4 +- src/pages/guide.astro | 4 +- src/pages/index.astro | 4 +- src/pages/join.astro | 4 +- src/pages/privacy.astro | 4 +- 24 files changed, 407 insertions(+), 261 deletions(-) create mode 100644 .zed/settings.json create mode 100644 biome.json diff --git a/.zed/settings.json b/.zed/settings.json new file mode 100644 index 0000000..4ceb63a --- /dev/null +++ b/.zed/settings.json @@ -0,0 +1,3 @@ +{ + "tab_size": 2, +} diff --git a/astro.config.mjs b/astro.config.mjs index d73c778..b937b29 100644 --- a/astro.config.mjs +++ b/astro.config.mjs @@ -1,12 +1,12 @@ -import { defineConfig } from 'astro/config'; -import react from '@astrojs/react'; -import tailwindcss from '@tailwindcss/vite'; +import { defineConfig } from "astro/config"; +import react from "@astrojs/react"; +import tailwindcss from "@tailwindcss/vite"; export default defineConfig({ integrations: [react()], vite: { plugins: [tailwindcss()] }, server: { - host: '0.0.0.0', + host: "0.0.0.0", port: 5000, allowedHosts: true, }, diff --git a/biome.json b/biome.json new file mode 100644 index 0000000..76e5a5a --- /dev/null +++ b/biome.json @@ -0,0 +1,35 @@ +{ + "$schema": "https://biomejs.dev/schemas/2.3.13/schema.json", + "vcs": { + "enabled": true, + "clientKind": "git", + "useIgnoreFile": true + }, + "files": { + "ignoreUnknown": false + }, + "formatter": { + "enabled": true, + "indentStyle": "space", + "indentWidth": 2 + }, + "linter": { + "enabled": true, + "rules": { + "recommended": true + } + }, + "javascript": { + "formatter": { + "quoteStyle": "double" + } + }, + "assist": { + "enabled": true, + "actions": { + "source": { + "organizeImports": "on" + } + } + } +} diff --git a/package.json b/package.json index f8032bb..5785ae5 100644 --- a/package.json +++ b/package.json @@ -40,6 +40,7 @@ "tailwind-merge": "^3.4.0" }, "devDependencies": { + "@biomejs/biome": "2.3.13", "@tailwindcss/vite": "^4.1.18", "@types/node": "^25.0.8", "@types/react": "^19.2.8", diff --git a/pnpm-lock.yaml b/pnpm-lock.yaml index bb56d40..62fafe0 100644 --- a/pnpm-lock.yaml +++ b/pnpm-lock.yaml @@ -39,6 +39,9 @@ importers: specifier: ^3.4.0 version: 3.4.0 devDependencies: + '@biomejs/biome': + specifier: 2.3.13 + version: 2.3.13 '@tailwindcss/vite': specifier: ^4.1.18 version: 4.1.18(vite@6.4.1(@types/node@25.0.8)(jiti@2.6.1)(lightningcss@1.30.2)(sass@1.97.2)) @@ -178,6 +181,59 @@ packages: resolution: {integrity: sha512-0ZrskXVEHSWIqZM/sQZ4EV3jZJXRkio/WCxaqKZP1g//CEWEPSfeZFcms4XeKBCHU0ZKnIkdJeU/kF+eRp5lBg==} engines: {node: '>=6.9.0'} + '@biomejs/biome@2.3.13': + resolution: {integrity: sha512-Fw7UsV0UAtWIBIm0M7g5CRerpu1eKyKAXIazzxhbXYUyMkwNrkX/KLkGI7b+uVDQ5cLUMfOC9vR60q9IDYDstA==} + engines: {node: '>=14.21.3'} + hasBin: true + + '@biomejs/cli-darwin-arm64@2.3.13': + resolution: {integrity: sha512-0OCwP0/BoKzyJHnFdaTk/i7hIP9JHH9oJJq6hrSCPmJPo8JWcJhprK4gQlhFzrwdTBAW4Bjt/RmCf3ZZe59gwQ==} + engines: {node: '>=14.21.3'} + cpu: [arm64] + os: [darwin] + + '@biomejs/cli-darwin-x64@2.3.13': + resolution: {integrity: sha512-AGr8OoemT/ejynbIu56qeil2+F2WLkIjn2d8jGK1JkchxnMUhYOfnqc9sVzcRxpG9Ycvw4weQ5sprRvtb7Yhcw==} + engines: {node: '>=14.21.3'} + cpu: [x64] + os: [darwin] + + '@biomejs/cli-linux-arm64-musl@2.3.13': + resolution: {integrity: sha512-TUdDCSY+Eo/EHjhJz7P2GnWwfqet+lFxBZzGHldrvULr59AgahamLs/N85SC4+bdF86EhqDuuw9rYLvLFWWlXA==} + engines: {node: '>=14.21.3'} + cpu: [arm64] + os: [linux] + + '@biomejs/cli-linux-arm64@2.3.13': + resolution: {integrity: sha512-xvOiFkrDNu607MPMBUQ6huHmBG1PZLOrqhtK6pXJW3GjfVqJg0Z/qpTdhXfcqWdSZHcT+Nct2fOgewZvytESkw==} + engines: {node: '>=14.21.3'} + cpu: [arm64] + os: [linux] + + '@biomejs/cli-linux-x64-musl@2.3.13': + resolution: {integrity: sha512-0bdwFVSbbM//Sds6OjtnmQGp4eUjOTt6kHvR/1P0ieR9GcTUAlPNvPC3DiavTqq302W34Ae2T6u5VVNGuQtGlQ==} + engines: {node: '>=14.21.3'} + cpu: [x64] + os: [linux] + + '@biomejs/cli-linux-x64@2.3.13': + resolution: {integrity: sha512-s+YsZlgiXNq8XkgHs6xdvKDFOj/bwTEevqEY6rC2I3cBHbxXYU1LOZstH3Ffw9hE5tE1sqT7U23C00MzkXztMw==} + engines: {node: '>=14.21.3'} + cpu: [x64] + os: [linux] + + '@biomejs/cli-win32-arm64@2.3.13': + resolution: {integrity: sha512-QweDxY89fq0VvrxME+wS/BXKmqMrOTZlN9SqQ79kQSIc3FrEwvW/PvUegQF6XIVaekncDykB5dzPqjbwSKs9DA==} + engines: {node: '>=14.21.3'} + cpu: [arm64] + os: [win32] + + '@biomejs/cli-win32-x64@2.3.13': + resolution: {integrity: sha512-trDw2ogdM2lyav9WFQsdsfdVy1dvZALymRpgmWsvSez0BJzBjulhOT/t+wyKeh3pZWvwP3VMs1SoOKwO3wecMQ==} + engines: {node: '>=14.21.3'} + cpu: [x64] + os: [win32] + '@capsizecss/unpack@4.0.0': resolution: {integrity: sha512-VERIM64vtTP1C4mxQ5thVT9fK0apjPFobqybMtA1UdUujWka24ERHbRHFGmpbbhp73MhV+KSsHQH9C6uOTdEQA==} engines: {node: '>=18'} @@ -2310,6 +2366,41 @@ snapshots: '@babel/helper-string-parser': 7.27.1 '@babel/helper-validator-identifier': 7.28.5 + '@biomejs/biome@2.3.13': + optionalDependencies: + '@biomejs/cli-darwin-arm64': 2.3.13 + '@biomejs/cli-darwin-x64': 2.3.13 + '@biomejs/cli-linux-arm64': 2.3.13 + '@biomejs/cli-linux-arm64-musl': 2.3.13 + '@biomejs/cli-linux-x64': 2.3.13 + '@biomejs/cli-linux-x64-musl': 2.3.13 + '@biomejs/cli-win32-arm64': 2.3.13 + '@biomejs/cli-win32-x64': 2.3.13 + + '@biomejs/cli-darwin-arm64@2.3.13': + optional: true + + '@biomejs/cli-darwin-x64@2.3.13': + optional: true + + '@biomejs/cli-linux-arm64-musl@2.3.13': + optional: true + + '@biomejs/cli-linux-arm64@2.3.13': + optional: true + + '@biomejs/cli-linux-x64-musl@2.3.13': + optional: true + + '@biomejs/cli-linux-x64@2.3.13': + optional: true + + '@biomejs/cli-win32-arm64@2.3.13': + optional: true + + '@biomejs/cli-win32-x64@2.3.13': + optional: true + '@capsizecss/unpack@4.0.0': dependencies: fontkitten: 1.0.1 diff --git a/src/components/AboutPage.tsx b/src/components/AboutPage.tsx index a336618..a659e89 100644 --- a/src/components/AboutPage.tsx +++ b/src/components/AboutPage.tsx @@ -1,5 +1,5 @@ -import { motion } from 'framer-motion'; -import { ArrowLeft, Heart, Network } from 'lucide-react'; +import { motion } from "framer-motion"; +import { ArrowLeft, Heart, Network } from "lucide-react"; export default function About() { return ( @@ -78,10 +78,10 @@ export default function About() {