diff --git a/.github/workflows/ci.yaml b/.github/workflows/ci.yaml new file mode 100644 index 0000000..0c7b1be --- /dev/null +++ b/.github/workflows/ci.yaml @@ -0,0 +1,43 @@ +name: CI + +on: + pull_request: + push: + branches: + - main + +concurrency: + group: ${{ github.workflow }}-${{ github.ref }} + cancel-in-progress: true + +jobs: + check: + name: Lint, format, typecheck, build + runs-on: ubuntu-latest + steps: + - name: Checkout + uses: actions/checkout@v6 + + - name: Setup Node.js + uses: actions/setup-node@v6 + with: + node-version: 24 + cache: npm + + - name: Install dependencies + run: npm ci + + - name: Format check + run: npm run format:check + + - name: Lint + run: npm run lint:ci + + - name: Workspace consistency + run: npm run sherif + + - name: Typecheck + run: npm run typecheck + + - name: Build + run: npm run build diff --git a/astro-alt-text-toolkit/__example__/package.json b/astro-alt-text-toolkit/__example__/package.json index b8704e0..66da55c 100644 --- a/astro-alt-text-toolkit/__example__/package.json +++ b/astro-alt-text-toolkit/__example__/package.json @@ -1,8 +1,8 @@ { "name": "example", - "type": "module", "version": "0.0.1", "private": "true", + "type": "module", "scripts": { "dev": "astro dev", "build": "astro build", diff --git a/astro-alt-text-toolkit/__example__/src/components/ImageWithAlt.astro b/astro-alt-text-toolkit/__example__/src/components/ImageWithAlt.astro index 5e0b967..3b2e65f 100644 --- a/astro-alt-text-toolkit/__example__/src/components/ImageWithAlt.astro +++ b/astro-alt-text-toolkit/__example__/src/components/ImageWithAlt.astro @@ -33,7 +33,7 @@ const getPathToAltTextMap = ( }, altTextModules: { [originalPath: string]: string; - } + }, ) => { const pathToAltTextMap = new Map(); for (const [originalPath, module] of Object.entries(imageModules)) { @@ -58,7 +58,7 @@ const getFinalSrc = async (image: typeof Astro.props.src) => { const finalPathToAltTextMap = getPathToAltTextMap( imageModules as any, - altTextModules as any + altTextModules as any, ); const alt = diff --git a/astro-alt-text-toolkit/package.json b/astro-alt-text-toolkit/package.json index 2fcc6bd..4bc71b0 100644 --- a/astro-alt-text-toolkit/package.json +++ b/astro-alt-text-toolkit/package.json @@ -1,10 +1,31 @@ { "name": "@fujocoded/astro-alt-text-toolkit", "version": "0.0.1", + "private": true, "description": "", - "main": "dist/index.js", + "keywords": [ + "astro", + "astro-integration", + "withastro" + ], + "homepage": "https://github.com/FujoWebDev/fujocoded-plugins#readme", + "bugs": { + "url": "https://github.com/FujoWebDev/fujocoded-plugins/issues" + }, + "license": "MIT", + "author": "FujoCoded LLC", + "repository": { + "type": "git", + "url": "git+https://github.com/FujoWebDev/fujocoded-plugins.git" + }, + "files": [ + "dist", + "LICENSE", + "README.md", + "package.json" + ], "type": "module", - "private": true, + "main": "dist/index.js", "exports": { ".": { "import": { @@ -13,33 +34,13 @@ } } }, - "files": [ - "dist", - "LICENSE", - "README.md", - "package.json" - ], "scripts": { "build": "tsdown", "dev": "tsdown --watch", "validate": "npx publint", - "test": "vitest" + "test": "vitest", + "typecheck": "tsc --noEmit" }, - "repository": { - "type": "git", - "url": "git+https://github.com/FujoWebDev/fujocoded-plugins.git" - }, - "keywords": [ - "astro", - "withastro", - "astro-integration" - ], - "author": "FujoCoded LLC", - "license": "MIT", - "bugs": { - "url": "https://github.com/FujoWebDev/fujocoded-plugins/issues" - }, - "homepage": "https://github.com/FujoWebDev/fujocoded-plugins#readme", "dependencies": {}, "devDependencies": { "tsdown": "^0.14.1" diff --git a/astro-alt-text-toolkit/src/_image-service.ts b/astro-alt-text-toolkit/src/_image-service.ts index 3fb7db7..a7c4646 100644 --- a/astro-alt-text-toolkit/src/_image-service.ts +++ b/astro-alt-text-toolkit/src/_image-service.ts @@ -34,12 +34,14 @@ const imageService: LocalImageService = { }; Object.entries(params).forEach(([param, key]) => { - options[key] && searchParams.append(param, options[key].toString()); + if (options[key]) { + searchParams.append(param, options[key].toString()); + } }); const imageEndpoint = path.join( import.meta.env.BASE_URL, - imageConfig.endpoint.route + imageConfig.endpoint.route, ); return `${imageEndpoint}?${searchParams}`; }, diff --git a/astro-alt-text-toolkit/src/index.ts b/astro-alt-text-toolkit/src/index.ts index 895577b..ec16132 100644 --- a/astro-alt-text-toolkit/src/index.ts +++ b/astro-alt-text-toolkit/src/index.ts @@ -32,7 +32,7 @@ const showAltTextPopup = (image: HTMLElement) => { dialog.open = false; } }, - { signal } + { signal }, ); dialog.addEventListener( "close", @@ -40,12 +40,12 @@ const showAltTextPopup = (image: HTMLElement) => { dialog.remove(); controller.abort(); }, - { signal } + { signal }, ); }; const images = Array.from( - document.querySelectorAll(`img[alt]:not(img[alt=""])`) + document.querySelectorAll(`img[alt]:not(img[alt=""])`), ); for (const image of images) { addBadgeToImage(image); diff --git a/astro-alt-text-toolkit/tsconfig.json b/astro-alt-text-toolkit/tsconfig.json index fe81cd7..8e07e0c 100644 --- a/astro-alt-text-toolkit/tsconfig.json +++ b/astro-alt-text-toolkit/tsconfig.json @@ -20,8 +20,8 @@ "declaration": true, "allowImportingTsExtensions": true, "noEmit": true, - "types": ["./src/types.d.ts"] + "types": ["vite/client"] }, - "include": ["./src/types.d.ts"], + "include": ["./src/**/*"], "exclude": ["node_modules"] } diff --git a/astro-ao3-loader/__examples__/works-list/astro.config.mjs b/astro-ao3-loader/__examples__/works-list/astro.config.mjs index e762ba5..17f6a62 100644 --- a/astro-ao3-loader/__examples__/works-list/astro.config.mjs +++ b/astro-ao3-loader/__examples__/works-list/astro.config.mjs @@ -1,5 +1,5 @@ // @ts-check -import { defineConfig } from 'astro/config'; +import { defineConfig } from "astro/config"; // https://astro.build/config export default defineConfig({}); diff --git a/astro-ao3-loader/__examples__/works-list/package.json b/astro-ao3-loader/__examples__/works-list/package.json index 291d329..ea607b5 100644 --- a/astro-ao3-loader/__examples__/works-list/package.json +++ b/astro-ao3-loader/__examples__/works-list/package.json @@ -1,7 +1,7 @@ { "name": "astro-5", - "type": "module", "version": "0.0.1", + "type": "module", "scripts": { "dev": "astro dev", "build": "astro build", @@ -9,7 +9,7 @@ "astro": "astro" }, "dependencies": { - "astro": "^5.16.9", - "@fujocoded/astro-ao3-loader": "file:../.." + "@fujocoded/astro-ao3-loader": "file:../..", + "astro": "^5.16.9" } -} \ No newline at end of file +} diff --git a/astro-ao3-loader/__examples__/works-list/src/content/ao3/series.yaml b/astro-ao3-loader/__examples__/works-list/src/content/ao3/series.yaml index 258cd15..a640618 100644 --- a/astro-ao3-loader/__examples__/works-list/src/content/ao3/series.yaml +++ b/astro-ao3-loader/__examples__/works-list/src/content/ao3/series.yaml @@ -1 +1 @@ -- 1728802 \ No newline at end of file +- 1728802 diff --git a/astro-ao3-loader/__examples__/works-list/src/content/ao3/works.yaml b/astro-ao3-loader/__examples__/works-list/src/content/ao3/works.yaml index 5cd7674..02864ab 100644 --- a/astro-ao3-loader/__examples__/works-list/src/content/ao3/works.yaml +++ b/astro-ao3-loader/__examples__/works-list/src/content/ao3/works.yaml @@ -4,4 +4,4 @@ - 41160522 - 11728554 - 12928950 -- 58869805 \ No newline at end of file +- 58869805 diff --git a/astro-ao3-loader/package.json b/astro-ao3-loader/package.json index dca2241..afadc9a 100644 --- a/astro-ao3-loader/package.json +++ b/astro-ao3-loader/package.json @@ -1,8 +1,24 @@ { "name": "@fujocoded/astro-ao3-loader", - "type": "module", "version": "0.0.4", "description": "Allows loading a series of AO3 works for the Astro Content Layer", + "keywords": [ + "astro-loader", + "withastro" + ], + "license": "MIT", + "author": "FujoCoded LLC", + "repository": { + "type": "git", + "url": "git+https://github.com/FujoWebDev/fujocoded-plugins.git" + }, + "files": [ + "dist", + "LICENSE", + "README.md", + "package.json" + ], + "type": "module", "module": "dist/index.mjs", "exports": { ".": { @@ -12,26 +28,14 @@ } } }, - "files": [ - "dist", - "LICENSE", - "README.md", - "package.json" - ], + "publishConfig": { + "access": "public" + }, "scripts": { "build": "tsdown", "dev": "tsdown --watch src/", - "validate": "npx publint" - }, - "keywords": [ - "withastro", - "astro-loader" - ], - "author": "FujoCoded LLC", - "license": "MIT", - "repository": { - "type": "git", - "url": "git+https://github.com/FujoWebDev/fujocoded-plugins.git" + "validate": "npx publint", + "typecheck": "tsc --noEmit" }, "dependencies": { "@fujocoded/ao3.js": "^0.23.1", @@ -46,8 +50,5 @@ "peerDependencies": { "astro": "^5.0.0", "zod": "^3.0.0 || ^4.0.0" - }, - "publishConfig": { - "access": "public" } } diff --git a/astro-ao3-loader/src/fetcher.ts b/astro-ao3-loader/src/fetcher.ts index 5f7a661..8708edc 100644 --- a/astro-ao3-loader/src/fetcher.ts +++ b/astro-ao3-loader/src/fetcher.ts @@ -98,8 +98,9 @@ const createFetcher = (logger: LoaderContext["logger"]) => { init?: RequestInit, ): Promise => { // We skip the queue if the response is already cached - if (RESPONSE_CACHE.has(input.toString())) { - return RESPONSE_CACHE.get(input.toString())!; + const cacheKey = JSON.stringify(input); + if (RESPONSE_CACHE.has(cacheKey)) { + return RESPONSE_CACHE.get(cacheKey)!; } return await queue.add(async () => await client(input, init)); }; diff --git a/astro-ao3-loader/src/index.ts b/astro-ao3-loader/src/index.ts index 8f597ac..7e9f2c2 100644 --- a/astro-ao3-loader/src/index.ts +++ b/astro-ao3-loader/src/index.ts @@ -5,12 +5,12 @@ import { parse } from "yaml"; import type { Loader, LoaderContext } from "astro/loaders"; import { z } from "zod"; import { getFetcher } from "./fetcher.ts"; -import { getProgressTracker} from "./logger.ts"; +import { getProgressTracker } from "./logger.ts"; /** * Loads items of the given "type" from the specified file ("yamlPath"). This uses the "itemFetcher" * function to fetch items from Archive of Our Own. -**/ + **/ const loadItems = async ( { store, logger }: LoaderContext, config: { diff --git a/astro-ao3-loader/src/logger.ts b/astro-ao3-loader/src/logger.ts index 6806734..c7eeee4 100644 --- a/astro-ao3-loader/src/logger.ts +++ b/astro-ao3-loader/src/logger.ts @@ -1,4 +1,3 @@ - import type { LoaderContext } from "astro/loaders"; const PROGRESS_INTERVAL_MS = 15 * 1000; // 15 seconds @@ -64,7 +63,7 @@ export const getProgressTracker = ({ failCount++; log(); logger.error( - `${prefix} Failed to fetch ${itemsType.slice(0, -1)} ${id}: ${error}`, + `${prefix} Failed to fetch ${itemsType.slice(0, -1)} ${id}: ${String(error)}`, ); }, finish: () => { diff --git a/astro-ao3-loader/tsconfig.json b/astro-ao3-loader/tsconfig.json index 2408617..0f62a6a 100644 --- a/astro-ao3-loader/tsconfig.json +++ b/astro-ao3-loader/tsconfig.json @@ -20,5 +20,7 @@ "declaration": true, "allowImportingTsExtensions": true, "noEmit": true - } + }, + "include": ["src/**/*"], + "exclude": ["node_modules", "dist", "__examples__", "__tests__"] } diff --git a/astro-atproto-loader/__examples__/01-static-loaders/package.json b/astro-atproto-loader/__examples__/01-static-loaders/package.json index 2b484f2..b971948 100644 --- a/astro-atproto-loader/__examples__/01-static-loaders/package.json +++ b/astro-atproto-loader/__examples__/01-static-loaders/package.json @@ -1,7 +1,7 @@ { "name": "examples-atproto-static-posts", - "type": "module", "version": "0.0.1", + "type": "module", "scripts": { "dev": "astro dev", "build": "astro build", diff --git a/astro-atproto-loader/__examples__/01-static-loaders/src/content.config.ts b/astro-atproto-loader/__examples__/01-static-loaders/src/content.config.ts index 22a74b2..166cafc 100644 --- a/astro-atproto-loader/__examples__/01-static-loaders/src/content.config.ts +++ b/astro-atproto-loader/__examples__/01-static-loaders/src/content.config.ts @@ -11,9 +11,7 @@ const fetchBlueskyPost = async ( uri: string, ): Promise => { const res = await fetch( - `https://public.api.bsky.app/xrpc/app.bsky.feed.getPosts?uris=${encodeURIComponent( - uri, - )}`, + `https://public.api.bsky.app/xrpc/app.bsky.feed.getPosts?uris=${encodeURIComponent(uri)}`, ); if (!res.ok) return undefined; diff --git a/astro-atproto-loader/__examples__/02-live-loaders/package.json b/astro-atproto-loader/__examples__/02-live-loaders/package.json index e591f25..3902e1d 100644 --- a/astro-atproto-loader/__examples__/02-live-loaders/package.json +++ b/astro-atproto-loader/__examples__/02-live-loaders/package.json @@ -1,7 +1,7 @@ { "name": "examples-atproto-live-events", - "type": "module", "version": "0.0.1", + "type": "module", "scripts": { "dev": "astro dev --host 127.0.0.1", "build": "astro build", diff --git a/astro-atproto-loader/__examples__/02-live-loaders/src/live.config.ts b/astro-atproto-loader/__examples__/02-live-loaders/src/live.config.ts index ffa0e5b..164659b 100644 --- a/astro-atproto-loader/__examples__/02-live-loaders/src/live.config.ts +++ b/astro-atproto-loader/__examples__/02-live-loaders/src/live.config.ts @@ -11,9 +11,7 @@ const fetchBlueskyPost = async ( uri: string, ): Promise => { const res = await fetch( - `https://public.api.bsky.app/xrpc/app.bsky.feed.getPosts?uris=${encodeURIComponent( - uri, - )}`, + `https://public.api.bsky.app/xrpc/app.bsky.feed.getPosts?uris=${encodeURIComponent(uri)}`, ); if (!res.ok) return undefined; diff --git a/astro-atproto-loader/package.json b/astro-atproto-loader/package.json index 6de2032..dc952c6 100644 --- a/astro-atproto-loader/package.json +++ b/astro-atproto-loader/package.json @@ -1,8 +1,33 @@ { "name": "@fujocoded/astro-atproto-loader", - "type": "module", "version": "0.1.1", "description": "Astro loaders (live and static) for reading AtProto records into Astro content collections.", + "keywords": [ + "astro", + "astro-content", + "astro-loader", + "atproto", + "bluesky", + "content-loader", + "withastro" + ], + "homepage": "https://github.com/FujoWebDev/fujocoded-plugins#readme", + "bugs": { + "url": "https://github.com/FujoWebDev/fujocoded-plugins/issues" + }, + "license": "MIT", + "author": "FujoCoded LLC", + "repository": { + "type": "git", + "url": "git+https://github.com/FujoWebDev/fujocoded-plugins.git" + }, + "files": [ + "dist", + "LICENSE", + "README.md", + "package.json" + ], + "type": "module", "module": "dist/index.js", "exports": { ".": { @@ -12,36 +37,15 @@ } } }, - "files": [ - "dist", - "LICENSE", - "README.md", - "package.json" - ], + "publishConfig": { + "access": "public" + }, "scripts": { "build": "tsdown", "dev": "tsdown --watch src/", - "validate": "npx publint" + "validate": "npx publint", + "typecheck": "tsc --noEmit" }, - "keywords": [ - "astro", - "withastro", - "astro-loader", - "astro-content", - "content-loader", - "atproto", - "bluesky" - ], - "repository": { - "type": "git", - "url": "git+https://github.com/FujoWebDev/fujocoded-plugins.git" - }, - "author": "FujoCoded LLC", - "license": "MIT", - "bugs": { - "url": "https://github.com/FujoWebDev/fujocoded-plugins/issues" - }, - "homepage": "https://github.com/FujoWebDev/fujocoded-plugins#readme", "dependencies": { "@atproto/api": "^0.17.3", "@atproto/identity": "^0.4.8", @@ -56,8 +60,5 @@ }, "peerDependencies": { "astro": "^5.13.0 || ^6.0.0" - }, - "publishConfig": { - "access": "public" } } diff --git a/astro-atproto-loader/src/live-loader.ts b/astro-atproto-loader/src/live-loader.ts index 19b962c..9d7a79d 100644 --- a/astro-atproto-loader/src/live-loader.ts +++ b/astro-atproto-loader/src/live-loader.ts @@ -260,9 +260,7 @@ export const atProtoLiveLoader = < return { error: toError( error, - `Failed to load the AtProto record from ${getCollectionsLabel( - sources, - )}`, + `Failed to load the AtProto record from ${getCollectionsLabel(sources)}`, ), }; } diff --git a/astro-atproto-loader/src/records.ts b/astro-atproto-loader/src/records.ts index 13c32d5..57b2aeb 100644 --- a/astro-atproto-loader/src/records.ts +++ b/astro-atproto-loader/src/records.ts @@ -50,8 +50,9 @@ export type AtProtoRecordTransform = ( args: AtProtoRecordCallbackArgs, ) => MaybePromise; -export interface AtProtoRecordCallbacks - extends AtProtoRecordFilterOptions { +export interface AtProtoRecordCallbacks< + TEntry, +> extends AtProtoRecordFilterOptions { /** * Convert a raw AtProto record into an Astro entry. */ diff --git a/astro-atproto-loader/src/utils.ts b/astro-atproto-loader/src/utils.ts index ca995b0..257db1e 100644 --- a/astro-atproto-loader/src/utils.ts +++ b/astro-atproto-loader/src/utils.ts @@ -24,7 +24,9 @@ export const normalizeSources = < return options.sources; } - throw new Error("AtProto record loaders require either `source` or `sources`."); + throw new Error( + "AtProto record loaders require either `source` or `sources`.", + ); }; export const getCollectionsLabel = (sources: AtProtoLoaderSource[]) => { diff --git a/astro-atproto-loader/tsconfig.json b/astro-atproto-loader/tsconfig.json index 085d28e..dc64719 100644 --- a/astro-atproto-loader/tsconfig.json +++ b/astro-atproto-loader/tsconfig.json @@ -17,5 +17,7 @@ "declaration": true, "allowImportingTsExtensions": true, "noEmit": true - } + }, + "include": ["src/**/*"], + "exclude": ["node_modules", "dist", "__examples__", "__tests__"] } diff --git a/astro-authproto/__examples__/01-login-logout/package.json b/astro-authproto/__examples__/01-login-logout/package.json index 99e0467..3ffe8de 100644 --- a/astro-authproto/__examples__/01-login-logout/package.json +++ b/astro-authproto/__examples__/01-login-logout/package.json @@ -1,7 +1,7 @@ { "name": "login-logout", - "type": "module", "version": "0.0.1", + "type": "module", "scripts": { "dev": "astro dev --host 127.0.0.1", "build": "astro build", diff --git a/astro-authproto/__examples__/02-read-bsky-profile/astro.config.mjs b/astro-authproto/__examples__/02-read-bsky-profile/astro.config.mjs index c39b63b..af19be3 100644 --- a/astro-authproto/__examples__/02-read-bsky-profile/astro.config.mjs +++ b/astro-authproto/__examples__/02-read-bsky-profile/astro.config.mjs @@ -1,5 +1,5 @@ // @ts-check -import { defineConfig } from 'astro/config'; +import { defineConfig } from "astro/config"; import authProto from "@fujocoded/authproto"; import node from "@astrojs/node"; @@ -11,14 +11,14 @@ export default defineConfig({ }), integrations: [ authProto({ - applicationName: "Read Bluesky Profile", - applicationDomain: "localhost:4321", - driver: { - name: "fs", - options: { - base: "./tmp" - }, - }, + applicationName: "Read Bluesky Profile", + applicationDomain: "localhost:4321", + driver: { + name: "fs", + options: { + base: "./tmp", + }, + }, }), - ], + ], }); diff --git a/astro-authproto/__examples__/02-read-bsky-profile/package.json b/astro-authproto/__examples__/02-read-bsky-profile/package.json index c92d681..01f001e 100644 --- a/astro-authproto/__examples__/02-read-bsky-profile/package.json +++ b/astro-authproto/__examples__/02-read-bsky-profile/package.json @@ -1,7 +1,7 @@ { "name": "examples-read-bsky-profile", - "type": "module", "version": "0.0.1", + "type": "module", "scripts": { "dev": "astro dev --host 127.0.0.1", "build": "astro build", diff --git a/astro-authproto/__examples__/02-read-bsky-profile/src/styles/bsky_table.css b/astro-authproto/__examples__/02-read-bsky-profile/src/styles/bsky_table.css index 3768f30..239a8b7 100644 --- a/astro-authproto/__examples__/02-read-bsky-profile/src/styles/bsky_table.css +++ b/astro-authproto/__examples__/02-read-bsky-profile/src/styles/bsky_table.css @@ -1,16 +1,16 @@ table { - max-width: 50%; - border-spacing: 5px 10px; + max-width: 50%; + border-spacing: 5px 10px; } tr { } td:first-child { - font-weight: bold; - white-space: nowrap; - vertical-align: text-top; + font-weight: bold; + white-space: nowrap; + vertical-align: text-top; } table td + td { - border-left: 1px solid #ddd; - padding-left: 5px; - white-space: pre-line; + border-left: 1px solid #ddd; + padding-left: 5px; + white-space: pre-line; } diff --git a/astro-authproto/__examples__/03-read-write-records/README.md b/astro-authproto/__examples__/03-read-write-records/README.md index 0a00291..5bb2de2 100644 --- a/astro-authproto/__examples__/03-read-write-records/README.md +++ b/astro-authproto/__examples__/03-read-write-records/README.md @@ -3,6 +3,7 @@ This will involve: + - Use the ATproto agent to [list records from a collection](./src/components/ListStatuses.astro). - Pairing the ATproto agent with Astro actions to [create new records in a collections](./src/actions/index.ts). diff --git a/astro-authproto/__examples__/03-read-write-records/package.json b/astro-authproto/__examples__/03-read-write-records/package.json index 115b0b7..2333e53 100644 --- a/astro-authproto/__examples__/03-read-write-records/package.json +++ b/astro-authproto/__examples__/03-read-write-records/package.json @@ -1,8 +1,8 @@ { "name": "example_with_status", - "type": "module", "version": "0.0.1", "private": "true", + "type": "module", "scripts": { "dev": "astro dev", "build": "astro build", diff --git a/astro-authproto/__examples__/03-read-write-records/src/actions/index.ts b/astro-authproto/__examples__/03-read-write-records/src/actions/index.ts index fcc3c96..d815325 100644 --- a/astro-authproto/__examples__/03-read-write-records/src/actions/index.ts +++ b/astro-authproto/__examples__/03-read-write-records/src/actions/index.ts @@ -11,7 +11,7 @@ export const server = { }), handler: async (input, context) => { const loggedInUser = context.locals.loggedInUser; - + // users who are not logged in shouldn't be able to post a record if (!loggedInUser) { throw new ActionError({ @@ -24,19 +24,19 @@ export const server = { // using the PDS for the `loggedInUser` provided by @fujocoded/authproto const agent = await getPdsAgent({ loggedInUser }); - if (!agent) { - throw new ActionError({ - code: "INTERNAL_SERVER_ERROR", - message: "Something went wrong when connecting to your PDS.", - }); - } - - try { + if (!agent) { + throw new ActionError({ + code: "INTERNAL_SERVER_ERROR", + message: "Something went wrong when connecting to your PDS.", + }); + } + + try { const statusRecord = { - status: input.status, - createdAt: new Date().toISOString(), + status: input.status, + createdAt: new Date().toISOString(), }; - + // we'll construct a record and post it with the "createRecord()" method const result = await agent.com.atproto.repo.createRecord({ repo: loggedInUser.did, // a repo will be a user's did or handle @@ -46,7 +46,7 @@ export const server = { }); // this will return the data as a string - return {recordAtUri: result.data.uri}; + return { recordAtUri: result.data.uri }; } catch (error) { console.error(error); throw new ActionError({ @@ -54,7 +54,7 @@ export const server = { message: "Something went wrong with posting your status to your PDS!", }); } - } + }, }), deleteStatus: defineAction({ input: z.object({ @@ -62,7 +62,7 @@ export const server = { }), handler: async (input, context) => { const loggedInUser = context.locals.loggedInUser; - + // users who are not logged in shouldn't be able to delete a record if (!loggedInUser) { throw new ActionError({ @@ -75,16 +75,15 @@ export const server = { // using the PDS for the `loggedInUser` provided by @fujocoded/authproto const agent = await getPdsAgent({ loggedInUser }); - if (!agent) { - throw new ActionError({ - code: "INTERNAL_SERVER_ERROR", - message: "Something went wrong when connecting to your PDS.", - }); - } - - try { - - // we'll delete the passed record + if (!agent) { + throw new ActionError({ + code: "INTERNAL_SERVER_ERROR", + message: "Something went wrong when connecting to your PDS.", + }); + } + + try { + // we'll delete the passed record const result = await agent.com.atproto.repo.deleteRecord({ repo: loggedInUser.did, // a repo will be a user's did or handle collection: "xyz.statuscity.status", // see NSID: https://atproto.com/specs/nsid @@ -92,14 +91,15 @@ export const server = { }); // this will return the data as a string - return {response: result.data.commit }; + return { response: result.data.commit }; } catch (error) { console.error(error); throw new ActionError({ code: "BAD_REQUEST", - message: "Something went wrong with deleting your status from your PDS!", + message: + "Something went wrong with deleting your status from your PDS!", }); } }, }), -} +}; diff --git a/astro-authproto/__examples__/03-read-write-records/src/components/BlueskyProfile.astro b/astro-authproto/__examples__/03-read-write-records/src/components/BlueskyProfile.astro index 8e1be0e..2c8f065 100644 --- a/astro-authproto/__examples__/03-read-write-records/src/components/BlueskyProfile.astro +++ b/astro-authproto/__examples__/03-read-write-records/src/components/BlueskyProfile.astro @@ -2,7 +2,7 @@ import { getBlueskyAgent } from "@fujocoded/authproto/helpers"; interface Props { - handle: string; + handle: string; } const handle = Astro.props.handle; @@ -13,32 +13,31 @@ const profile = response?.data; ---
- -
- {profile?.displayName} -
-
- {profile?.description} -
+ +
+ {profile?.displayName} +
+
+ {profile?.description} +
diff --git a/astro-authproto/__examples__/03-read-write-records/src/components/ListStatuses.astro b/astro-authproto/__examples__/03-read-write-records/src/components/ListStatuses.astro index 87c7ad3..c8bf76f 100644 --- a/astro-authproto/__examples__/03-read-write-records/src/components/ListStatuses.astro +++ b/astro-authproto/__examples__/03-read-write-records/src/components/ListStatuses.astro @@ -1,9 +1,9 @@ --- import { getPdsAgent, getDid } from "@fujocoded/authproto/helpers"; -import '../styles/status_table.css' +import "../styles/status_table.css"; const FUJOCODED_HANDLE = "fujocoded.bsky.social"; -const FUJOCODED_DID = await getDid({didOrHandle: FUJOCODED_HANDLE}); +const FUJOCODED_DID = await getDid({ didOrHandle: FUJOCODED_HANDLE }); if (!FUJOCODED_DID) { throw new Error("Something has gone horribly wrong with this demo."); } @@ -13,7 +13,9 @@ const loggedInUser = Astro.locals.loggedInUser; // To grab all the statuses that the user has posted, we first create // an Agent to do those request on the users' behalf. Then we ask it to list // the records in their "xyz.statuscity.status" data collection. -const agent = await getPdsAgent(loggedInUser ? {loggedInUser} : {didOrHandle: FUJOCODED_HANDLE}); +const agent = await getPdsAgent( + loggedInUser ? { loggedInUser } : { didOrHandle: FUJOCODED_HANDLE }, +); const response = await agent?.com.atproto.repo.listRecords({ repo: loggedInUser ? loggedInUser.did : FUJOCODED_DID, // Whose data do we want to fetch? collection: "xyz.statuscity.status", // What type of data do we want? @@ -25,66 +27,79 @@ const statuses = response?.data.records ?? []; //console.log(statuses) --- -

{loggedInUser ? "Your" : `${FUJOCODED_HANDLE}'s`} Statusphere Status(es)

+

+ {loggedInUser ? "Your" : `${FUJOCODED_HANDLE}'s`} Statusphere Status(es) +

{statuses.length == 0 &&

No statuses yet!

} { statuses.map(({ uri, cid, value }) => (
- - - - - - - - - - - - - - - {loggedInUser && - - - - } -
Record
{uri}
Status

{value.status}

Date - -
- - {} -
+ {/* TODO: Put this in a way where it's clear what this is */} + + + + + + + + + + + + + + {loggedInUser && ( + + + + )} +
Record + +
{uri}
+
+
Status +

{value.status}

+
Date + +
+ +
)) } diff --git a/astro-authproto/__examples__/03-read-write-records/src/components/UserAvatar.astro b/astro-authproto/__examples__/03-read-write-records/src/components/UserAvatar.astro index b04e4cd..766b4a1 100644 --- a/astro-authproto/__examples__/03-read-write-records/src/components/UserAvatar.astro +++ b/astro-authproto/__examples__/03-read-write-records/src/components/UserAvatar.astro @@ -2,15 +2,15 @@ import { getBlueskyAgent } from "@fujocoded/authproto/helpers"; if (!Astro.locals.loggedInUser) { - return null; + return null; } const agent = await getBlueskyAgent({ - loggedInUser: Astro.locals.loggedInUser, + loggedInUser: Astro.locals.loggedInUser, }); const response = await agent?.app.bsky.actor.getProfile({ - actor: Astro.locals.loggedInUser.handle, + actor: Astro.locals.loggedInUser.handle, }); const profile = response?.data; --- @@ -18,9 +18,9 @@ const profile = response?.data; diff --git a/astro-authproto/__examples__/03-read-write-records/src/pages/index.astro b/astro-authproto/__examples__/03-read-write-records/src/pages/index.astro index 3bccc1d..d68d049 100644 --- a/astro-authproto/__examples__/03-read-write-records/src/pages/index.astro +++ b/astro-authproto/__examples__/03-read-write-records/src/pages/index.astro @@ -30,7 +30,7 @@ const loggedInUser = Astro.locals.loggedInUser; {loggedInUser ? : "You must be logged in to post a status."}
- A project by: + A project by:
diff --git a/astro-authproto/__examples__/03-read-write-records/src/styles/status_table.css b/astro-authproto/__examples__/03-read-write-records/src/styles/status_table.css index c9fe7da..8319172 100644 --- a/astro-authproto/__examples__/03-read-write-records/src/styles/status_table.css +++ b/astro-authproto/__examples__/03-read-write-records/src/styles/status_table.css @@ -1,8 +1,8 @@ table { - max-width: 50%; - border-spacing: 5px 10px; - border-top: 1px solid #ddd; - border-bottom: 1px solid #ddd; + max-width: 50%; + border-spacing: 5px 10px; + border-top: 1px solid #ddd; + border-bottom: 1px solid #ddd; } /* @@ -12,16 +12,16 @@ table.deleted tbody tr td { */ span.delete_response { - opacity: 1.0 !important; - text-decoration: none !important; - color: red; + opacity: 1 !important; + text-decoration: none !important; + color: red; } td:first-child { - font-weight: bold; + font-weight: bold; } table td + td { - border-left: 1px solid #ddd; - padding-left: 5px; - white-space: pre-line; + border-left: 1px solid #ddd; + padding-left: 5px; + white-space: pre-line; } diff --git a/astro-authproto/__examples__/04-auth-only-pages/package.json b/astro-authproto/__examples__/04-auth-only-pages/package.json index 42865ec..3b16e6b 100644 --- a/astro-authproto/__examples__/04-auth-only-pages/package.json +++ b/astro-authproto/__examples__/04-auth-only-pages/package.json @@ -1,8 +1,8 @@ { "name": "example", - "type": "module", "version": "0.0.1", "private": "true", + "type": "module", "scripts": { "dev": "astro dev", "build": "astro build", diff --git a/astro-authproto/__examples__/04-auth-only-pages/src/middleware.ts b/astro-authproto/__examples__/04-auth-only-pages/src/middleware.ts index 15272a1..e40f163 100644 --- a/astro-authproto/__examples__/04-auth-only-pages/src/middleware.ts +++ b/astro-authproto/__examples__/04-auth-only-pages/src/middleware.ts @@ -30,13 +30,12 @@ export const onRequest = defineMiddleware(async (context, next) => { "followedBy" in usersRelationship && Boolean(usersRelationship.followedBy); // True if target follows the current user - const following = + const _following = usersRelationship && "following" in usersRelationship && Boolean(usersRelationship.following); // True if this is a mutual relationship - const mutuals = follower && following; - + const _mutuals = follower && _following; // This is where we redirect. Change the condition according to which // relationships give access to the page. if (!self && !follower) { diff --git a/astro-authproto/__examples__/05-redirects/package.json b/astro-authproto/__examples__/05-redirects/package.json index 91c5983..e332ece 100644 --- a/astro-authproto/__examples__/05-redirects/package.json +++ b/astro-authproto/__examples__/05-redirects/package.json @@ -1,8 +1,8 @@ { "name": "example", - "type": "module", "version": "0.0.1", "private": "true", + "type": "module", "scripts": { "dev": "astro dev --host", "build": "astro build", diff --git a/astro-authproto/package.json b/astro-authproto/package.json index c0ffd9e..22501b1 100644 --- a/astro-authproto/package.json +++ b/astro-authproto/package.json @@ -2,8 +2,32 @@ "name": "@fujocoded/authproto", "version": "0.3.0", "description": "Astro integration to easily authenticateyour site visitors using ATproto. For Bluesky and beyond.", - "main": "dist/index.js", + "keywords": [ + "astro", + "astro-integration", + "atproto", + "authentication", + "bluesky", + "withastro" + ], + "homepage": "https://github.com/FujoWebDev/fujocoded-plugins#readme", + "bugs": { + "url": "https://github.com/FujoWebDev/fujocoded-plugins/issues" + }, + "license": "MIT", + "author": "FujoCoded LLC", + "repository": { + "type": "git", + "url": "git+https://github.com/FujoWebDev/fujocoded-plugins.git" + }, + "files": [ + "dist", + "LICENSE", + "README.md", + "package.json" + ], "type": "module", + "main": "dist/index.js", "exports": { ".": { "import": { @@ -36,36 +60,13 @@ } } }, - "files": [ - "dist", - "LICENSE", - "README.md", - "package.json" - ], "scripts": { "build": "tsdown", "dev": "tsdown --watch src/", "validate": "npx publint", - "test": "vitest" - }, - "repository": { - "type": "git", - "url": "git+https://github.com/FujoWebDev/fujocoded-plugins.git" + "test": "vitest", + "typecheck": "tsc --noEmit" }, - "keywords": [ - "astro", - "withastro", - "astro-integration", - "atproto", - "bluesky", - "authentication" - ], - "author": "FujoCoded LLC", - "license": "MIT", - "bugs": { - "url": "https://github.com/FujoWebDev/fujocoded-plugins/issues" - }, - "homepage": "https://github.com/FujoWebDev/fujocoded-plugins#readme", "dependencies": { "@atproto/api": "^0.17.3", "@atproto/identity": "^0.4.8", @@ -75,6 +76,7 @@ "unstorage": "^1.16.1" }, "devDependencies": { + "@astrojs/db": "^0.17.1", "drizzle-orm": "^0.42.0", "glob": "^13.0.6", "tsdown": "^0.17.2" diff --git a/astro-authproto/src/config-module.d.ts b/astro-authproto/src/config-module.d.ts index daca962..f35344f 100644 --- a/astro-authproto/src/config-module.d.ts +++ b/astro-authproto/src/config-module.d.ts @@ -35,6 +35,11 @@ declare module "fujocoded:authproto/stores" { } from "@fujocoded/authproto/stores/unstorage"; } +declare module "*.astro" { + const Component: import("astro/runtime/server/index.js").AstroComponentFactory; + export default Component; +} + // astro:db types - @astrojs/db is an optional peer dependency declare module "astro:db" { export const db: any; diff --git a/astro-authproto/src/helpers.ts b/astro-authproto/src/helpers.ts index f808564..6bf5a07 100644 --- a/astro-authproto/src/helpers.ts +++ b/astro-authproto/src/helpers.ts @@ -1,7 +1,6 @@ import { AtpBaseClient } from "@atproto/api"; import { IdResolver } from "@atproto/identity"; - const IDENTITY_RESOLVER = new IdResolver({}); export const getDid = async ({ didOrHandle }: { didOrHandle: string }) => { if (didOrHandle.startsWith("did:")) { @@ -19,16 +18,17 @@ const getPdsUrl = async ({ didOrHandle }: { didOrHandle: string }) => { return atprotoData.pds; }; - /** * Sends requests through the PDS of the logged in user. This means they will * have authentication status. */ -export async function getLoggedInAgent(loggedInUser: NonNullable) { +export async function getLoggedInAgent( + loggedInUser: NonNullable, +) { try { const agent = new AtpBaseClient(loggedInUser.fetchHandler); return agent; - } catch (error) { + } catch { return null; } } @@ -41,9 +41,13 @@ export async function getLoggedInAgent(loggedInUser: NonNullable }) { +export async function getPdsAgent( + pdsOwner: + | { didOrHandle: string } + | { loggedInUser: NonNullable }, +) { if ("loggedInUser" in pdsOwner) { - return getLoggedInAgent(pdsOwner.loggedInUser) + return getLoggedInAgent(pdsOwner.loggedInUser); } try { const destination = await getPdsUrl({ didOrHandle: pdsOwner.didOrHandle }); @@ -52,7 +56,7 @@ export async function getPdsAgent(pdsOwner: { didOrHandle: string } | { loggedIn } const agent = new AtpBaseClient(destination); return agent; - } catch (error) { + } catch { return null; } } @@ -62,11 +66,15 @@ export async function getPdsAgent(pdsOwner: { didOrHandle: string } | { loggedIn * present then it will send them through the users' PDS first to validate * authentication status. */ -export async function getBlueskyAgent(user?: { loggedInUser: NonNullable }) { +export async function getBlueskyAgent(user?: { + loggedInUser: NonNullable; +}) { try { - const agent = new AtpBaseClient(user ? user.loggedInUser.fetchHandler : "https://public.api.bsky.app/"); + const agent = new AtpBaseClient( + user ? user.loggedInUser.fetchHandler : "https://public.api.bsky.app/", + ); return agent; - } catch (error) { + } catch { return null; } -} \ No newline at end of file +} diff --git a/astro-authproto/src/index.ts b/astro-authproto/src/index.ts index ef497dc..e105b4f 100644 --- a/astro-authproto/src/index.ts +++ b/astro-authproto/src/index.ts @@ -1,7 +1,11 @@ import type { AstroIntegration, InjectedRoute } from "astro"; import path from "node:path"; import { addVirtualImports } from "astro-integration-kit"; -import { getConfig, getStoresImport, type ConfigOptions } from "./lib/config.js"; +import { + getConfig, + getStoresImport, + type ConfigOptions, +} from "./lib/config.js"; import { readFile } from "node:fs/promises"; export const LOGGED_IN_DID_TEMPLATE = "{loggedInUser.did}"; @@ -43,7 +47,7 @@ const addAtProtoRoutes = (injectRoute: (_: InjectedRoute) => void) => { pattern: "/oauth-client-metadata.json", entrypoint: path.join( import.meta.dirname, - "./routes/oauth-client-metadata.json.js" + "./routes/oauth-client-metadata.json.js", ), prerender: false, }); @@ -58,13 +62,12 @@ export default ( configOptions: ConfigOptions = { applicationName: "AuthProto Application", applicationDomain: "http://localhost:4321", - } + }, ): AstroIntegration => ({ name: "fujocoded:authproto", hooks: { "astro:config:setup": (setupParams) => { - const { injectRoute, addMiddleware, createCodegenDir } = setupParams; - const codegenDir = createCodegenDir(); + const { injectRoute, addMiddleware } = setupParams; addOAuthRoutes(injectRoute); addAtProtoRoutes(injectRoute); @@ -99,30 +102,30 @@ export default ( "astro:config:done": async ({ injectTypes, config, logger }) => { if (!config.session?.driver && !config.adapter) { logger.error( - "The ATproto OAuth integration uses Astro's session storage, which requires a session driver or an adapter. You have neither set. For more information, see https://docs.astro.build/en/guides/sessions/" + "The ATproto OAuth integration uses Astro's session storage, which requires a session driver or an adapter. You have neither set. For more information, see https://docs.astro.build/en/guides/sessions/", ); } if (!configOptions.driver) { if (process.env.NODE_ENV === "development") { logger.warn( - "The ATproto OAuth integration requires a configured session driver in production. This will be ok for dev mode." + "The ATproto OAuth integration requires a configured session driver in production. This will be ok for dev mode.", ); } else { throw new Error( - "The ATproto OAuth integration requires a configured session driver in production." + "The ATproto OAuth integration requires a configured session driver in production.", ); } } if (!config.server.host && process.env.NODE_ENV === "development") { logger.error( - "ATproto requires the local redirect URL to be 127.0.0.1 (not localhost) but your site is not running on a network address. Run `astro dev --host` to fix this." + "ATproto requires the local redirect URL to be 127.0.0.1 (not localhost) but your site is not running on a network address. Run `astro dev --host` to fix this.", ); } if (config.output === "static") { // TODO: check if a static site with some routes marked as dynamic // works. logger.warn( - `Your Astro output config is "static". The login status is only available on dynamically rendered pages.` + `Your Astro output config is "static". The login status is only available on dynamically rendered pages.`, ); } injectTypes({ @@ -131,7 +134,7 @@ export default ( path.join(import.meta.dirname, "./types.d.ts"), { encoding: "utf-8", - } + }, ), }); }, diff --git a/astro-authproto/src/lib/auth.ts b/astro-authproto/src/lib/auth.ts index 4c6580a..9605f94 100644 --- a/astro-authproto/src/lib/auth.ts +++ b/astro-authproto/src/lib/auth.ts @@ -24,7 +24,7 @@ const REDIRECT_PATH = "/oauth/callback"; * This is used both by the OAuth client and the client-metadata.json endpoint. */ export const createClientMetadata = ( - domain: string + domain: string, ): NodeOAuthClientOptions["clientMetadata"] => { const DOMAIN_URL = new URL(domain); const IS_LOCALHOST = @@ -47,7 +47,7 @@ export const createClientMetadata = ( CLIENT_ID.searchParams.set("scope", scopes.join(" ")); CLIENT_ID.searchParams.set( "redirect_uri", - new URL(REDIRECT_PATH, ENDPOINT_URL).toString() + new URL(REDIRECT_PATH, ENDPOINT_URL).toString(), ); } @@ -71,7 +71,7 @@ export const createClientMetadata = ( const createClient = async (domain: string) => { return new NodeOAuthClient({ clientMetadata: createClientMetadata(domain), - keyset: await Promise.all([JoseKey.generate()]), + keyset: [await JoseKey.generate()], stateStore: new Stores.StateStore(), sessionStore: new Stores.SessionStore(), }); @@ -86,8 +86,8 @@ export const didToHandle = async (did: string) => { }; export const extractAuthError = ( - e: unknown -): { code: string | "UNKNOWN"; description: string | undefined } => { + e: unknown, +): { code: "UNKNOWN" | (string & {}); description: string | undefined } => { if (e instanceof Error) { return { code: e.name ?? "UNKNOWN", diff --git a/astro-authproto/src/lib/config.ts b/astro-authproto/src/lib/config.ts index ae705bd..894e2bc 100644 --- a/astro-authproto/src/lib/config.ts +++ b/astro-authproto/src/lib/config.ts @@ -31,7 +31,7 @@ export type OAuthScope = /** * Additional scopes not covered by the others. */ - | string; + | (string & {}); export interface ConfigOptions { applicationName: string; @@ -70,13 +70,21 @@ export const getStoresImport = (driverName?: string) => { return `export { StateStore, SessionStore } from "@fujocoded/authproto/stores/unstorage";`; }; -export const getConfig = ({ options, isDev }: { options: ConfigOptions, isDev: boolean }) => { +export const getConfig = ({ + options, + isDev, +}: { + options: ConfigOptions; + isDev: boolean; +}) => { const finalDriver = options.driver ?? { name: "memory", options: undefined, }; - const externalDomain = options.externalDomain ?? (isDev ? "http://127.0.0.1:4321/" : options.applicationDomain); + const externalDomain = + options.externalDomain ?? + (isDev ? "http://127.0.0.1:4321/" : options.applicationDomain); const scopes: OAuthScope[] = ["atproto"]; if (Array.isArray(options.scopes)) { @@ -116,17 +124,11 @@ export const getConfig = ({ options, isDev }: { options: ConfigOptions, isDev: b export const applicationName = "${options.applicationName}"; export const applicationDomain = "${options.applicationDomain}"; - export const defaultDevUser = ${JSON.stringify( - options.defaultDevUser ?? null - )}; + export const defaultDevUser = ${JSON.stringify(options.defaultDevUser ?? null)}; export const scopes = ${JSON.stringify(scopes)}; export const driverName = "${finalDriver.name}"; - export const redirectAfterLogin = ${JSON.stringify( - options.redirects?.afterLogin ?? "/" - )}; - export const redirectAfterLogout = ${JSON.stringify( - options.redirects?.afterLogout ?? "/" - )}; + export const redirectAfterLogin = ${JSON.stringify(options.redirects?.afterLogin ?? "/")}; + export const redirectAfterLogout = ${JSON.stringify(options.redirects?.afterLogout ?? "/")}; export const externalDomain = ${JSON.stringify(externalDomain)}; export const clientMetadataDomain = process.env.AUTHPROTO_EXTERNAL_DOMAIN ?? ${JSON.stringify(externalDomain)} ?? "${options.applicationDomain}"; `; diff --git a/astro-authproto/src/lib/redirects.ts b/astro-authproto/src/lib/redirects.ts index fae0ae2..b91b97d 100644 --- a/astro-authproto/src/lib/redirects.ts +++ b/astro-authproto/src/lib/redirects.ts @@ -7,10 +7,10 @@ import { didToHandle } from "./auth.js"; const substituteRefererTemplate = ( redirectToBase: string, - referer: string + referer: string, ): string => { - const [basePath, baseParams] = redirectToBase.split("?"); - const [refererBasePath, refererParams] = referer.split("?"); + const [basePath = "", baseParams] = redirectToBase.split("?"); + const [refererBasePath = "", refererParams] = referer.split("?"); // Replace the referer template with the actual referer in the base path // of the redirectToBase @@ -28,7 +28,7 @@ const substituteRefererTemplate = ( const processedValue = value.includes(REDIRECT_TO_REFERER_TEMPLATE) ? value.replaceAll( REDIRECT_TO_REFERER_TEMPLATE, - encodeURIComponent(referer) + encodeURIComponent(referer), ) : value; finalParams.set(key, processedValue); @@ -44,7 +44,7 @@ const substituteRefererTemplate = ( const substituteUserTemplates = async ( url: string, - did: string + did: string, ): Promise => { let result = url; diff --git a/astro-authproto/src/routes/jwks.json.ts b/astro-authproto/src/routes/jwks.json.ts index d446729..8ea33f9 100644 --- a/astro-authproto/src/routes/jwks.json.ts +++ b/astro-authproto/src/routes/jwks.json.ts @@ -1,7 +1,7 @@ import type { APIRoute } from "astro"; import { oauthClient } from "../lib/auth.js"; -export const GET: APIRoute = async ({}) => { +export const GET: APIRoute = async () => { return new Response(JSON.stringify(oauthClient.jwks), { status: 200, headers: { diff --git a/astro-authproto/src/routes/middleware.ts b/astro-authproto/src/routes/middleware.ts index 71ee221..71664e9 100644 --- a/astro-authproto/src/routes/middleware.ts +++ b/astro-authproto/src/routes/middleware.ts @@ -17,8 +17,8 @@ export const onRequest: MiddlewareHandler = async ( errorCode, errorDescription, }; - await session?.delete(AUTHPROTO_ERROR_CODE); - await session?.delete(AUTHPROTO_ERROR_DESCRIPTION); + session?.delete(AUTHPROTO_ERROR_CODE); + session?.delete(AUTHPROTO_ERROR_DESCRIPTION); } if (!session || !userDid) { @@ -39,8 +39,8 @@ export const onRequest: MiddlewareHandler = async ( }; locals.loggedInClient = loggedInClient; } - } catch (e) { - await session.delete("atproto-did"); + } catch { + session.delete("atproto-did"); locals.loggedInUser = null; locals.loggedInClient = null; } diff --git a/astro-authproto/src/routes/oauth-client-metadata.json.ts b/astro-authproto/src/routes/oauth-client-metadata.json.ts index 480bc29..0133363 100644 --- a/astro-authproto/src/routes/oauth-client-metadata.json.ts +++ b/astro-authproto/src/routes/oauth-client-metadata.json.ts @@ -2,7 +2,7 @@ import type { APIRoute } from "astro"; import { clientMetadataDomain } from "fujocoded:authproto/config"; import { createClientMetadata } from "../lib/auth.js"; -export const GET: APIRoute = async ({}) => { +export const GET: APIRoute = async () => { return new Response( JSON.stringify(createClientMetadata(clientMetadataDomain)), { @@ -10,6 +10,6 @@ export const GET: APIRoute = async ({}) => { headers: { "Content-Type": "application/json", }, - } + }, ); }; diff --git a/astro-authproto/src/routes/oauth/callback.ts b/astro-authproto/src/routes/oauth/callback.ts index 23a10dd..7322e5f 100644 --- a/astro-authproto/src/routes/oauth/callback.ts +++ b/astro-authproto/src/routes/oauth/callback.ts @@ -8,13 +8,7 @@ import { } from "../middleware.ts"; import { type OAuthSession } from "@atproto/oauth-client-node"; -export const GET: APIRoute = async ({ - params, - request, - redirect, - session, - locals, -}) => { +export const GET: APIRoute = async ({ request, redirect, session }) => { const requestUrl = new URL(request.url); let oauthSession: OAuthSession | null; diff --git a/astro-authproto/src/routes/oauth/login.ts b/astro-authproto/src/routes/oauth/login.ts index 4d815a7..9c3145b 100644 --- a/astro-authproto/src/routes/oauth/login.ts +++ b/astro-authproto/src/routes/oauth/login.ts @@ -9,8 +9,12 @@ import { export const POST: APIRoute = async ({ redirect, request, session }) => { const body = await request.formData(); - const atprotoId = body.get("atproto-id")?.toString(); - const customRedirect = body.get("redirect")?.toString(); + const atprotoIdValue = body.get("atproto-id"); + const atprotoId = + typeof atprotoIdValue === "string" ? atprotoIdValue : undefined; + const redirectValue = body.get("redirect"); + const customRedirect = + typeof redirectValue === "string" ? redirectValue : undefined; // Get the referer to redirect back to the same page after login // if the developer asked us to do so diff --git a/astro-authproto/src/routes/oauth/logout.ts b/astro-authproto/src/routes/oauth/logout.ts index 83eaf92..fea0a40 100644 --- a/astro-authproto/src/routes/oauth/logout.ts +++ b/astro-authproto/src/routes/oauth/logout.ts @@ -17,7 +17,9 @@ export const POST: APIRoute = async ({ redirect, session, request }) => { // Check if a custom redirect was passed in the form data const body = await request.formData(); - const customRedirect = body.get("redirect")?.toString(); + const redirectValue = body.get("redirect"); + const customRedirect = + typeof redirectValue === "string" ? redirectValue : undefined; const referer = request.headers.get("referer"); const redirectTo = await getRedirectUrl({ redirectToBase: customRedirect ?? redirectAfterLogout ?? "/", diff --git a/astro-authproto/src/stores/db.ts b/astro-authproto/src/stores/db.ts index bff230d..47e2535 100644 --- a/astro-authproto/src/stores/db.ts +++ b/astro-authproto/src/stores/db.ts @@ -6,19 +6,13 @@ import { } from "@atproto/oauth-client-node"; import { asDrizzleTable } from "@astrojs/db/utils"; import { db, eq } from "astro:db"; -import { - AtProtoChallengesTable, - AtProtoSessionsTable, -} from "../db/tables.js"; +import { AtProtoChallengesTable, AtProtoSessionsTable } from "../db/tables.js"; const AtProtoChallenges = asDrizzleTable( "AtProtoChallenges", - AtProtoChallengesTable -); -const AtProtoSessions = asDrizzleTable( - "AtProtoSessions", - AtProtoSessionsTable + AtProtoChallengesTable, ); +const AtProtoSessions = asDrizzleTable("AtProtoSessions", AtProtoSessionsTable); /** * The StateStore saves the challenge token issued before an OAuth request to diff --git a/astro-authproto/src/stores/unstorage.ts b/astro-authproto/src/stores/unstorage.ts index 68539f8..bdaf9db 100644 --- a/astro-authproto/src/stores/unstorage.ts +++ b/astro-authproto/src/stores/unstorage.ts @@ -17,19 +17,19 @@ export class StateStore implements NodeSavedStateStore { /* Fulfills a request for the token */ async get(key: string): Promise { try { - const result = await storage.getItem(`authproto:state:${key}`); + const result = await storage?.getItem(`authproto:state:${key}`); return result as NodeSavedState; - } catch (e) { + } catch { return undefined; } } /* Fulfills a request to set the token */ async set(key: string, val: NodeSavedState) { - await storage.setItem(`authproto:state:${key}`, val); + await storage?.setItem(`authproto:state:${key}`, val); } /* Fulfills a request to delete the token */ async del(key: string) { - await storage.del(`authproto:state:${key}`); + await storage?.del(`authproto:state:${key}`); } } @@ -40,15 +40,15 @@ export class StateStore implements NodeSavedStateStore { export class SessionStore implements NodeSavedSessionStore { /* Fulfills a request to get the credential of the user, given a DID */ async get(did: string): Promise { - const result = await storage.getItem(`authproto:session:${did}`); + const result = await storage?.getItem(`authproto:session:${did}`); return result as NodeSavedSession; } /* Fulfills a request to set the credential of the user, given a DID */ async set(did: string, val: NodeSavedSession) { - await storage.setItem(`authproto:session:${did}`, val); + await storage?.setItem(`authproto:session:${did}`, val); } /* Fulfills a request to delete the credential of the user, given a DID */ async del(did: string) { - await storage.del(`authproto:session:${did}`); + await storage?.del(`authproto:session:${did}`); } } diff --git a/astro-authproto/src/types.d.ts b/astro-authproto/src/types.d.ts index b256fb6..9c772ec 100644 --- a/astro-authproto/src/types.d.ts +++ b/astro-authproto/src/types.d.ts @@ -1,4 +1,7 @@ -import { AUTHPROTO_ERROR_CODE, AUTHPROTO_ERROR_DESCRIPTION } from "./routes/middleware.ts"; +import { + AUTHPROTO_ERROR_CODE, + AUTHPROTO_ERROR_DESCRIPTION, +} from "./routes/middleware.ts"; declare global { namespace App { interface SessionData { diff --git a/astro-dev-only/example/astro.config.mjs b/astro-dev-only/example/astro.config.mjs index 1c87b48..6ce22b4 100644 --- a/astro-dev-only/example/astro.config.mjs +++ b/astro-dev-only/example/astro.config.mjs @@ -1,6 +1,5 @@ // @ts-check import { defineConfig } from "astro/config"; -import node from "@astrojs/node"; import devOnly from "@fujocoded/astro-dev-only"; // https://astro.build/config diff --git a/astro-dev-only/example/package.json b/astro-dev-only/example/package.json index 2d05c41..c8cd264 100644 --- a/astro-dev-only/example/package.json +++ b/astro-dev-only/example/package.json @@ -1,7 +1,7 @@ { "name": "example", - "type": "module", "version": "0.0.1", + "type": "module", "scripts": { "dev": "astro dev", "build": "astro build", diff --git a/astro-dev-only/example/src/pages/index.astro b/astro-dev-only/example/src/pages/index.astro index 2d14107..7ec71a5 100644 --- a/astro-dev-only/example/src/pages/index.astro +++ b/astro-dev-only/example/src/pages/index.astro @@ -3,14 +3,14 @@ --- - - - - - - Astro - - -

Astro

- + + + + + + Astro + + +

Astro

+ diff --git a/astro-dev-only/index.ts b/astro-dev-only/index.ts index 055f311..31126f9 100644 --- a/astro-dev-only/index.ts +++ b/astro-dev-only/index.ts @@ -21,7 +21,7 @@ type AstroIntegration = AstroIntegrationV4 & AstroIntegrationV5; const getDevOnlyStaticRoutes = ( allRoutes: RouteData[], - routePatterns: Pattern[] + routePatterns: Pattern[], ) => { const matchesPattern = (route: RouteData, pattern: Pattern) => { if (typeof pattern === "string") { @@ -32,7 +32,7 @@ const getDevOnlyStaticRoutes = ( return allRoutes.filter( (route) => route.prerender && - routePatterns.some((pattern) => matchesPattern(route, pattern)) + routePatterns.some((pattern) => matchesPattern(route, pattern)), ); }; @@ -44,7 +44,7 @@ const throwIfNotInsideDist = (path: string | URL) => { if (!isWithinCwd) { throw new Error( - `Attempt to remove dangerous path: ${path} (${resolvedPath})` + `Attempt to remove dangerous path: ${path} (${resolvedPath})`, ); } }; @@ -66,7 +66,7 @@ export const passRoutePatternsToMiddleware = (routePatterns: Pattern[]) => { if (id === "\0fujocoded:dev-only-routes") { return `export const excludedPatterns = [${routePatterns .map((route) => - typeof route === "string" ? `"${route}"` : route.toString() + typeof route === "string" ? `"${route}"` : route.toString(), ) .join(", ")}];`; } @@ -75,7 +75,7 @@ export const passRoutePatternsToMiddleware = (routePatterns: Pattern[]) => { }; export default function devOnlyRoutesIntegration({ - routePatterns = [], + routePatterns, dryRun = false, }: { routePatterns: Pattern[]; @@ -122,14 +122,14 @@ export default function devOnlyRoutesIntegration({ Array.isArray(route.distURL) ? route.distURL : ([route.distURL] as URL[]), - ] as const + ] as const, ); for (const [route, filePaths] of devOnlyRoutesAndPaths) { logger.info( dryRun ? `DRY RUN: ❌ (NOT) Removing file(s) for "src/pages${route}":` - : `❌ Removing files for "src/pages${route}" from final build` + : `❌ Removing files for "src/pages${route}" from final build`, ); for (const filePath of filePaths) { const relativePath = relative(process.cwd(), filePath.pathname); diff --git a/astro-dev-only/middleware.ts b/astro-dev-only/middleware.ts index 88d932b..3d7d859 100644 --- a/astro-dev-only/middleware.ts +++ b/astro-dev-only/middleware.ts @@ -13,7 +13,7 @@ const matchesPattern = (route: APIContext, pattern: Pattern) => { export const onRequest: MiddlewareHandler = async (context, next) => { if (context.isPrerendered) { // Route is pre-rendered, we've already done what we need to do - next(); + return next(); } if (excludedPatterns.some((pattern) => matchesPattern(context, pattern))) { return new Response(null, { status: 404 }); diff --git a/astro-dev-only/package.json b/astro-dev-only/package.json index ac84aea..7e86293 100644 --- a/astro-dev-only/package.json +++ b/astro-dev-only/package.json @@ -1,8 +1,24 @@ { "name": "@fujocoded/astro-dev-only", - "type": "module", "version": "0.0.4", "description": "An Astro integration for development-only pages", + "keywords": [ + "astro-integration", + "withastro" + ], + "license": "MIT", + "author": "FujoCoded LLC", + "repository": { + "type": "git", + "url": "git+https://github.com/fujowebdev/fujocoded-plugins.git" + }, + "files": [ + "dist", + "LICENSE", + "README.md", + "package.json" + ], + "type": "module", "main": "dist/index.cjs", "module": "dist/index.js", "exports": { @@ -27,31 +43,16 @@ } } }, - "files": [ - "dist", - "LICENSE", - "README.md", - "package.json" - ], + "publishConfig": { + "access": "public" + }, "scripts": { "build": "tsup index.ts middleware.ts --format cjs,esm --dts --clean --external 'fujocoded:dev-only-routes'", - "validate": " npx publint" - }, - "keywords": [ - "withastro", - "astro-integration" - ], - "repository": { - "type": "git", - "url": "git+https://github.com/fujowebdev/fujocoded-plugins.git" + "validate": " npx publint", + "typecheck": "tsc --noEmit" }, - "author": "FujoCoded LLC", - "license": "MIT", "devDependencies": { "astro-types-v4": "npm:astro@^4.0.0", "astro-types-v5": "npm:astro@^5.0.0" - }, - "publishConfig": { - "access": "public" } } diff --git a/astro-dev-only/tsconfig.json b/astro-dev-only/tsconfig.json index 314f553..ccc77a7 100644 --- a/astro-dev-only/tsconfig.json +++ b/astro-dev-only/tsconfig.json @@ -21,5 +21,7 @@ "allowImportingTsExtensions": true, "noEmit": true, "types": ["./types.d.ts"] - } + }, + "include": ["*.ts"], + "exclude": ["node_modules", "dist", "example"] } diff --git a/astro-rehype-html-headings/index.ts b/astro-rehype-html-headings/index.ts index 2cf77f8..f4ee7f7 100644 --- a/astro-rehype-html-headings/index.ts +++ b/astro-rehype-html-headings/index.ts @@ -29,7 +29,7 @@ export const astroRehypeHtmlHeadings: Plugin< return (tree, file) => { if (!file.data.astro) { throw new Error( - `[astro-rehype-html-headings]: Plugin can only be used within Astro context` + `[astro-rehype-html-headings]: Plugin can only be used within Astro context`, ); } diff --git a/astro-rehype-html-headings/package.json b/astro-rehype-html-headings/package.json index b82ed99..2f6ee74 100644 --- a/astro-rehype-html-headings/package.json +++ b/astro-rehype-html-headings/package.json @@ -1,8 +1,24 @@ { "name": "@fujocoded/astro-rehype-html-headings", - "type": "module", "version": "0.0.2", "description": "Adds a list of headings to Astro's frontmatter that include rendered HTML code", + "keywords": [ + "astro", + "rehype" + ], + "license": "MIT", + "author": "FujoCoded LLC", + "repository": { + "type": "git", + "url": "git+https://github.com/FujoWebDev/fujocoded-plugins.git" + }, + "files": [ + "dist", + "LICENSE", + "README.md", + "package.json" + ], + "type": "module", "main": "dist/index.cjs", "module": "dist/index.js", "exports": { @@ -17,25 +33,13 @@ } } }, - "files": [ - "dist", - "LICENSE", - "README.md", - "package.json" - ], + "publishConfig": { + "access": "public" + }, "scripts": { "build": "tsup index.ts --format cjs,esm --dts --clean", - "validate": " npx publint" - }, - "keywords": [ - "rehype", - "astro" - ], - "author": "FujoCoded LLC", - "license": "MIT", - "repository": { - "type": "git", - "url": "git+https://github.com/FujoWebDev/fujocoded-plugins.git" + "validate": " npx publint", + "typecheck": "tsc --noEmit" }, "dependencies": { "hast-util-heading-rank": "^3.0.0", @@ -47,8 +51,5 @@ "tsup": "^8.1.0", "typescript": "^5.6.2", "unified": "^11.0.4" - }, - "publishConfig": { - "access": "public" } } diff --git a/astro-remark-collect-components/index.ts b/astro-remark-collect-components/index.ts index 09f5668..6d86d6e 100644 --- a/astro-remark-collect-components/index.ts +++ b/astro-remark-collect-components/index.ts @@ -17,13 +17,13 @@ type PluginArgs = { | { components: Omit[]; frontmatterName: string; - } + }, ]; }; const getConfigWithNodeName = ( configs: PluginArgs["configs"], - nodeName: string + nodeName: string, ) => { return configs .map((componentConfig) => { @@ -32,7 +32,7 @@ const getConfigWithNodeName = ( } // Check if component has config for node const config = componentConfig.components.find( - (component) => component.name == nodeName + (component) => component.name == nodeName, ); if (!config) { return null; @@ -49,12 +49,12 @@ export const astroRemarkCollectComponents: Plugin = ({ configs, }: PluginArgs): Transformer => { const componentNames = configs.flatMap((config) => - "components" in config ? config.components.map((c) => c.name) : config.name + "components" in config ? config.components.map((c) => c.name) : config.name, ); return (tree, file) => { if (!(file.data.astro as any)) { throw new Error( - `[astro-remark-collect-components]: Plugin can only be used within Astro context` + `[astro-remark-collect-components]: Plugin can only be used within Astro context`, ); } configs.forEach((c) => { @@ -73,39 +73,42 @@ export const astroRemarkCollectComponents: Plugin = ({ (node) => { if (!node.name) { throw new Error( - `[astro-remark-collect-components]: Trying to process node with undefined name.` + `[astro-remark-collect-components]: Trying to process node with undefined name.`, ); } const configsWithNode = getConfigWithNodeName(configs, node.name); if (!configsWithNode.length) { throw new Error( - `[astro-remark-collect-components]: No config found for ${node.name}` + `[astro-remark-collect-components]: No config found for ${node.name}`, ); } for (const config of configsWithNode) { - const values = config.attributes.reduce((aggregate, current) => { - aggregate[current] = node.attributes.find( - (attribute) => - "name" in attribute && - attribute.name == current && - typeof attribute.value == "string" - )?.value as unknown as string | undefined; + const values = config.attributes.reduce( + (aggregate, current) => { + aggregate[current] = node.attributes.find( + (attribute) => + "name" in attribute && + attribute.name == current && + typeof attribute.value == "string", + )?.value as unknown as string | undefined; - // If the value of the attribute wasn't found, we get the default from the component defaults, - // assuming that such default exists; - if (!aggregate[current]) { - aggregate[current] = config.defaults?.[current]; - } + // If the value of the attribute wasn't found, we get the default from the component defaults, + // assuming that such default exists; + if (!aggregate[current]) { + aggregate[current] = config.defaults?.[current]; + } - return aggregate; - }, {} as Record); + return aggregate; + }, + {} as Record, + ); (file.data.astro as any).frontmatter[config.frontmatterName].push( - values + values, ); } - } + }, ); }; }; diff --git a/astro-remark-collect-components/package.json b/astro-remark-collect-components/package.json index 271c60c..ecf0e70 100644 --- a/astro-remark-collect-components/package.json +++ b/astro-remark-collect-components/package.json @@ -1,8 +1,23 @@ { "name": "@fujocoded/astro-remark-collect-components", - "type": "module", "version": "0.0.6", "description": "Allows adding a list of components and attributes in an MDX file to Astro's frontmatter", + "keywords": [ + "remark" + ], + "license": "MIT", + "author": "FujoCoded LLC", + "repository": { + "type": "git", + "url": "git+https://github.com/FujoWebDev/fujocoded-plugins.git" + }, + "files": [ + "dist", + "LICENSE", + "README.md", + "package.json" + ], + "type": "module", "main": "dist/index.cjs", "module": "dist/index.js", "exports": { @@ -17,24 +32,13 @@ } } }, - "files": [ - "dist", - "LICENSE", - "README.md", - "package.json" - ], + "publishConfig": { + "access": "public" + }, "scripts": { "build": "tsup index.ts --format cjs,esm --dts --clean", - "validate": " npx publint" - }, - "keywords": [ - "remark" - ], - "author": "FujoCoded LLC", - "license": "MIT", - "repository": { - "type": "git", - "url": "git+https://github.com/FujoWebDev/fujocoded-plugins.git" + "validate": " npx publint", + "typecheck": "tsc --noEmit" }, "dependencies": { "unist-util-visit": "^5.0.0" @@ -46,8 +50,5 @@ "tsup": "^8.1.0", "typescript": "^5.5.2", "unified": "^11.0.4" - }, - "publishConfig": { - "access": "public" } } diff --git a/astro-smooth-actions/package.json b/astro-smooth-actions/package.json index a903575..a4fca65 100644 --- a/astro-smooth-actions/package.json +++ b/astro-smooth-actions/package.json @@ -1,11 +1,27 @@ { "name": "@fujocoded/astro-smooth-action", - "type": "module", "version": "0.0.1", + "private": true, "description": "An Astro integration for smooth action handling", + "keywords": [ + "astro-integration", + "withastro" + ], + "license": "MIT", + "author": "FujoCoded LLC", + "repository": { + "type": "git", + "url": "git+https://github.com/fujowebdev/fujocoded-plugins.git" + }, + "files": [ + "dist", + "LICENSE", + "README.md", + "package.json" + ], + "type": "module", "main": "dist/index.cjs", "module": "dist/index.js", - "private": true, "exports": { ".": { "import": { @@ -14,32 +30,17 @@ } } }, - "files": [ - "dist", - "LICENSE", - "README.md", - "package.json" - ], + "publishConfig": { + "access": "public" + }, "scripts": { "build": "tsdown", + "typecheck": "tsc --noEmit", "validate": " npx publint" }, - "keywords": [ - "withastro", - "astro-integration" - ], - "repository": { - "type": "git", - "url": "git+https://github.com/fujowebdev/fujocoded-plugins.git" - }, - "author": "FujoCoded LLC", - "license": "MIT", "devDependencies": { "astro": "^5.0.0", "glob": "^13.0.6", "tsdown": "^0.14.1" - }, - "publishConfig": { - "access": "public" } } diff --git a/astro-smooth-actions/src/index.ts b/astro-smooth-actions/src/index.ts index 32ea411..d35f4b8 100644 --- a/astro-smooth-actions/src/index.ts +++ b/astro-smooth-actions/src/index.ts @@ -16,7 +16,7 @@ export default function astroActionSessions(): AstroIntegration { "astro:config:done": ({ config, logger }) => { if (!config.session?.driver && !config.adapter) { logger.warn( - "The astro-smooth-actions integration uses Astro's session storage, which requires a session driver or an adapter. You have neither set. For more information, see https://docs.astro.build/en/guides/sessions/" + "The astro-smooth-actions integration uses Astro's session storage, which requires a session driver or an adapter. You have neither set. For more information, see https://docs.astro.build/en/guides/sessions/", ); } }, diff --git a/astro-smooth-actions/src/middleware.ts b/astro-smooth-actions/src/middleware.ts index eec747e..a1c6a33 100644 --- a/astro-smooth-actions/src/middleware.ts +++ b/astro-smooth-actions/src/middleware.ts @@ -2,11 +2,11 @@ import { getActionContext } from "astro:actions"; import { type MiddlewareHandler } from "astro"; export const onRequest: MiddlewareHandler = async (context, next) => { - const { action, setActionResult, serializeActionResult } = - getActionContext(context); + const actionContext = getActionContext(context); + const { action } = actionContext; const latestAction = await context.session?.get( - `smooth-actions:latest-astro-action` + `smooth-actions:latest-astro-action`, ); if (latestAction) { @@ -14,8 +14,8 @@ export const onRequest: MiddlewareHandler = async (context, next) => { // for this request and then delete the session entry. This makes it look // like the action was executed on this request, and there was no magic // redirect happening behind the scenes. - setActionResult(latestAction.name, latestAction.result); - await context.session?.delete(`smooth-actions:latest-astro-action`); + actionContext.setActionResult(latestAction.name, latestAction.result); + context.session?.delete(`smooth-actions:latest-astro-action`); return next(); } @@ -31,7 +31,7 @@ export const onRequest: MiddlewareHandler = async (context, next) => { const result = await action.handler(); context.session?.set(`smooth-actions:latest-astro-action`, { name: action.name, - result: serializeActionResult(result), + result: actionContext.serializeActionResult(result), }); if (result.error) { diff --git a/astro-smooth-actions/src/types.d.ts b/astro-smooth-actions/src/types.d.ts new file mode 100644 index 0000000..45e91ce --- /dev/null +++ b/astro-smooth-actions/src/types.d.ts @@ -0,0 +1,3 @@ +declare module "astro:actions" { + export * from "astro/actions/runtime/server.js"; +} diff --git a/astro-smooth-actions/tsconfig.json b/astro-smooth-actions/tsconfig.json new file mode 100644 index 0000000..8e0ad0f --- /dev/null +++ b/astro-smooth-actions/tsconfig.json @@ -0,0 +1,23 @@ +{ + "compilerOptions": { + "esModuleInterop": true, + "skipLibCheck": true, + "target": "es2022", + "lib": ["es2022", "DOM"], + "allowJs": true, + "resolveJsonModule": true, + "moduleDetection": "force", + "isolatedModules": true, + "strict": true, + "noUncheckedIndexedAccess": true, + "moduleResolution": "NodeNext", + "module": "NodeNext", + "outDir": "dist", + "sourceMap": true, + "declaration": true, + "allowImportingTsExtensions": true, + "noEmit": true + }, + "include": ["src/**/*"], + "exclude": ["node_modules", "dist"] +} diff --git a/astro-smooth-actions/tsdown.config.ts b/astro-smooth-actions/tsdown.config.ts index ea1725d..3636142 100644 --- a/astro-smooth-actions/tsdown.config.ts +++ b/astro-smooth-actions/tsdown.config.ts @@ -1,5 +1,4 @@ -import { defineConfig, type UserConfig } from "tsdown"; -import { glob } from "glob"; +import { defineConfig } from "tsdown"; export default defineConfig([ { diff --git a/expressive-code-caption/index.ts b/expressive-code-caption/index.ts index 94d815a..5f1db0c 100644 --- a/expressive-code-caption/index.ts +++ b/expressive-code-caption/index.ts @@ -2,7 +2,6 @@ import { definePlugin, AttachedPluginData } from "@expressive-code/core"; import { h } from "@expressive-code/core/hast"; import { fromMarkdown } from "mdast-util-from-markdown"; import { toHast } from "mdast-util-to-hast"; -import { pluginFrames } from "@expressive-code/plugin-frames"; interface CaptionData { caption?: string; @@ -49,7 +48,7 @@ export function pluginCodeCaption() { ]; if (lastLine && lastLine.text.trim() === "") { context.codeBlock.deleteLine( - context.codeBlock.getLines().length - 1 + context.codeBlock.getLines().length - 1, ); } } @@ -59,10 +58,10 @@ export function pluginCodeCaption() { const captionBlock = context.renderedGroupContents.find( (groupContent) => { const blockData = captionData.getOrCreateFor( - groupContent.codeBlock + groupContent.codeBlock, ); return !!blockData.caption; - } + }, ); if (!captionBlock) { return; @@ -76,10 +75,10 @@ export function pluginCodeCaption() { "figcaption", toHast( fromMarkdown( - captionData.getOrCreateFor(captionBlock.codeBlock).caption! - ) - ) - ) + captionData.getOrCreateFor(captionBlock.codeBlock).caption!, + ), + ), + ), ); }, }, diff --git a/expressive-code-caption/package.json b/expressive-code-caption/package.json index cddf83a..e748dd4 100644 --- a/expressive-code-caption/package.json +++ b/expressive-code-caption/package.json @@ -1,8 +1,23 @@ { "name": "@fujocoded/expressive-code-caption", - "type": "module", "version": "0.0.3", "description": "Allow adding caption at the end of expressive code blocks.", + "keywords": [ + "remark" + ], + "license": "MIT", + "author": "FujoCoded LLC", + "repository": { + "type": "git", + "url": "git+https://github.com/FujoWebDev/fujocoded-plugins.git" + }, + "files": [ + "dist", + "LICENSE", + "README.md", + "package.json" + ], + "type": "module", "main": "dist/index.cjs", "module": "dist/index.js", "exports": { @@ -17,24 +32,13 @@ } } }, - "files": [ - "dist", - "LICENSE", - "README.md", - "package.json" - ], + "publishConfig": { + "access": "public" + }, "scripts": { "build": "tsup index.ts --format cjs,esm --dts --clean", - "validate": " npx publint" - }, - "keywords": [ - "remark" - ], - "author": "FujoCoded LLC", - "license": "MIT", - "repository": { - "type": "git", - "url": "git+https://github.com/FujoWebDev/fujocoded-plugins.git" + "validate": " npx publint", + "typecheck": "tsc --noEmit" }, "dependencies": { "mdast-util-to-hast": "^13.2.0" @@ -43,9 +47,6 @@ "tsup": "^8.1.0", "typescript": "^5.5.2" }, - "publishConfig": { - "access": "public" - }, "peerDependencies": { "@expressive-code/core": "^0.35.3" } diff --git a/expressive-code-output/__tests__/index.test.ts b/expressive-code-output/__tests__/index.test.ts index a837b31..fad824a 100644 --- a/expressive-code-output/__tests__/index.test.ts +++ b/expressive-code-output/__tests__/index.test.ts @@ -98,7 +98,7 @@ test("Code with copy button", async () => { const copyButton = select("div.copy button", result.renderedGroupAst); // Note this shouldn't have the output in it expect(copyButton?.properties.dataCode).toBe( - `def foo():\x7F for i in range(5):\x7F print("This is the index ", i)\x7Ffoo()` + `def foo():\x7F for i in range(5):\x7F print("This is the index ", i)\x7Ffoo()`, ); }); diff --git a/expressive-code-output/__tests__/utils.ts b/expressive-code-output/__tests__/utils.ts index efe9a6e..945bc15 100644 --- a/expressive-code-output/__tests__/utils.ts +++ b/expressive-code-output/__tests__/utils.ts @@ -25,7 +25,7 @@ const formatHtml = (html: string) => { !part.startsWith("") && !["br", "img", "input", "meta", "link"].some((tag) => - part.includes(tag) + part.includes(tag), ) ) { indent++; @@ -78,14 +78,14 @@ export const extractCodeBlockAndOutput = (element: Element) => { throw new Error("Figure element has no children in code output"); } const codeBlockIndex = figureElement.children.findIndex( - (child) => child.type === "element" && child.tagName === "pre" + (child) => child.type === "element" && child.tagName === "pre", ); const outputIndex = figureElement.children.findIndex( (child, index) => child.type === "element" && child.tagName === "pre" && index > codeBlockIndex, - codeBlockIndex + codeBlockIndex, ); return { codeBlock: figureElement.children[codeBlockIndex] ?? null, diff --git a/expressive-code-output/index.ts b/expressive-code-output/index.ts index e8634b6..c571fe8 100644 --- a/expressive-code-output/index.ts +++ b/expressive-code-output/index.ts @@ -56,7 +56,7 @@ export function pluginCodeOutput() { if (!blockData.output.length) return; const lastPre = context.renderData.blockAst.children.findLastIndex( - (child) => child.type === "element" && child.tagName === "pre" + (child) => child.type === "element" && child.tagName === "pre", ); if (lastPre === -1) return; @@ -66,7 +66,7 @@ export function pluginCodeOutput() { ...currentChildren.slice(0, lastPre + 1), h( "pre.output", - blockData.output.map((line) => h("div", line)) + blockData.output.map((line) => h("div", line)), ), ...currentChildren.slice(lastPre + 1), ]; diff --git a/expressive-code-output/package.json b/expressive-code-output/package.json index ceb22dd..f938f93 100644 --- a/expressive-code-output/package.json +++ b/expressive-code-output/package.json @@ -1,8 +1,23 @@ { "name": "@fujocoded/expressive-code-output", - "type": "module", "version": "0.1.0", "description": "Allow adding output for expressive code blocks.", + "keywords": [ + "remark" + ], + "license": "MIT", + "author": "FujoCoded LLC", + "repository": { + "type": "git", + "url": "git+https://github.com/FujoWebDev/fujocoded-plugins.git" + }, + "files": [ + "dist", + "LICENSE", + "README.md", + "package.json" + ], + "type": "module", "main": "dist/index.cjs", "module": "dist/index.js", "exports": { @@ -17,25 +32,14 @@ } } }, - "files": [ - "dist", - "LICENSE", - "README.md", - "package.json" - ], + "publishConfig": { + "access": "public" + }, "scripts": { "build": "tsup index.ts --format cjs,esm --dts --clean", "validate": " npx publint", - "test": "vitest --no-watch" - }, - "keywords": [ - "remark" - ], - "author": "FujoCoded LLC", - "license": "MIT", - "repository": { - "type": "git", - "url": "git+https://github.com/FujoWebDev/fujocoded-plugins.git" + "test": "vitest --no-watch", + "typecheck": "tsc --noEmit" }, "dependencies": { "mdast-util-to-hast": "^13.2.0" @@ -48,8 +52,5 @@ "tsup": "^8.1.0", "typescript": "^5.5.2", "vitest": "^3.2.4" - }, - "publishConfig": { - "access": "public" } } diff --git a/expressive-code-output/tsconfig.json b/expressive-code-output/tsconfig.json index db7f3c0..e2be389 100644 --- a/expressive-code-output/tsconfig.json +++ b/expressive-code-output/tsconfig.json @@ -20,5 +20,7 @@ "declaration": true, "allowImportingTsExtensions": true, "noEmit": true - } + }, + "include": ["**/*.ts"], + "exclude": ["node_modules", "dist", "__examples__", "__tests__"] } diff --git a/oxfmt.config.ts b/oxfmt.config.ts new file mode 100644 index 0000000..d4834cc --- /dev/null +++ b/oxfmt.config.ts @@ -0,0 +1,5 @@ +import { defineConfig } from "oxfmt"; + +export default defineConfig({ + printWidth: 80, +}); diff --git a/package-lock.json b/package-lock.json index f042ba3..60d6d26 100644 --- a/package-lock.json +++ b/package-lock.json @@ -9,8 +9,13 @@ "*/", "!.*/" ], - "dependencies": { - "@changesets/cli": "^2.29.8" + "devDependencies": { + "@changesets/cli": "^2.29.8", + "oxfmt": "^0.46.0", + "oxlint": "^1.61.0", + "oxlint-tsgolint": "^0.21.1", + "prettier": "^3.8.3", + "prettier-plugin-astro": "^0.14.1" } }, "astro-alt-text-toolkit": { @@ -483,6 +488,7 @@ "unstorage": "^1.16.1" }, "devDependencies": { + "@astrojs/db": "^0.17.1", "drizzle-orm": "^0.42.0", "glob": "^13.0.6", "tsdown": "^0.17.2" @@ -1052,20 +1058,6 @@ "unist-util-visit-parents": "^6.0.1" } }, - "expressive-code-output/node_modules/prettier": { - "version": "3.7.4", - "dev": true, - "license": "MIT", - "bin": { - "prettier": "bin/prettier.cjs" - }, - "engines": { - "node": ">=14" - }, - "funding": { - "url": "https://github.com/prettier/prettier?sponsor=1" - } - }, "node_modules/@astrojs/compiler": { "version": "2.13.0", "resolved": "https://registry.npmjs.org/@astrojs/compiler/-/compiler-2.13.0.tgz", @@ -1076,8 +1068,7 @@ "version": "0.17.1", "resolved": "https://registry.npmjs.org/@astrojs/db/-/db-0.17.1.tgz", "integrity": "sha512-QL09xZf5Om8AshIlt+YhLDYf6M1QSzv+kfuljsPrhEXJ8U/tuKnbWs2M3wimFaLG3/fU0prFix8lWt7zU8ytfA==", - "optional": true, - "peer": true, + "dev": true, "dependencies": { "@libsql/client": "^0.15.2", "deep-diff": "^1.0.2", @@ -1093,8 +1084,7 @@ "version": "0.42.0", "resolved": "https://registry.npmjs.org/drizzle-orm/-/drizzle-orm-0.42.0.tgz", "integrity": "sha512-pS8nNJm2kBNZwrOjTHJfdKkaU+KuUQmV/vk5D57NojDq4FG+0uAYGMulXtYT///HfgsMF0hnFFvu1ezI3OwOkg==", - "optional": true, - "peer": true, + "dev": true, "peerDependencies": { "@aws-sdk/client-rds-data": ">=3", "@cloudflare/workers-types": ">=4", @@ -1215,14 +1205,13 @@ "version": "5.1.5", "resolved": "https://registry.npmjs.org/nanoid/-/nanoid-5.1.5.tgz", "integrity": "sha512-Ir/+ZpE9fDsNH0hQ3C68uyThDXzYcim2EqcZ8zn8Chtt1iylPT9xXJB0kPCnqzgcEGikO9RxSrh63MsmVCU7Fw==", + "dev": true, "funding": [ { "type": "github", "url": "https://github.com/sponsors/ai" } ], - "optional": true, - "peer": true, "bin": { "nanoid": "bin/nanoid.js" }, @@ -1953,6 +1942,7 @@ "version": "7.0.14", "resolved": "https://registry.npmjs.org/@changesets/apply-release-plan/-/apply-release-plan-7.0.14.tgz", "integrity": "sha512-ddBvf9PHdy2YY0OUiEl3TV78mH9sckndJR14QAt87KLEbIov81XO0q0QAmvooBxXlqRRP8I9B7XOzZwQG7JkWA==", + "dev": true, "license": "MIT", "dependencies": { "@changesets/config": "^3.1.2", @@ -1970,10 +1960,27 @@ "semver": "^7.5.3" } }, + "node_modules/@changesets/apply-release-plan/node_modules/prettier": { + "version": "2.8.8", + "resolved": "https://registry.npmjs.org/prettier/-/prettier-2.8.8.tgz", + "integrity": "sha512-tdN8qQGvNjw4CHbY+XXk0JgCXn9QiF21a55rBe5LJAU+kDyC4WQn4+awm2Xfk2lQMk5fKup9XgzTZtGkjBdP9Q==", + "dev": true, + "license": "MIT", + "bin": { + "prettier": "bin-prettier.js" + }, + "engines": { + "node": ">=10.13.0" + }, + "funding": { + "url": "https://github.com/prettier/prettier?sponsor=1" + } + }, "node_modules/@changesets/assemble-release-plan": { "version": "6.0.9", "resolved": "https://registry.npmjs.org/@changesets/assemble-release-plan/-/assemble-release-plan-6.0.9.tgz", "integrity": "sha512-tPgeeqCHIwNo8sypKlS3gOPmsS3wP0zHt67JDuL20P4QcXiw/O4Hl7oXiuLnP9yg+rXLQ2sScdV1Kkzde61iSQ==", + "dev": true, "license": "MIT", "dependencies": { "@changesets/errors": "^0.2.0", @@ -1988,6 +1995,7 @@ "version": "0.2.1", "resolved": "https://registry.npmjs.org/@changesets/changelog-git/-/changelog-git-0.2.1.tgz", "integrity": "sha512-x/xEleCFLH28c3bQeQIyeZf8lFXyDFVn1SgcBiR2Tw/r4IAWlk1fzxCEZ6NxQAjF2Nwtczoen3OA2qR+UawQ8Q==", + "dev": true, "license": "MIT", "dependencies": { "@changesets/types": "^6.1.0" @@ -1997,6 +2005,7 @@ "version": "2.29.8", "resolved": "https://registry.npmjs.org/@changesets/cli/-/cli-2.29.8.tgz", "integrity": "sha512-1weuGZpP63YWUYjay/E84qqwcnt5yJMM0tep10Up7Q5cS/DGe2IZ0Uj3HNMxGhCINZuR7aO9WBMdKnPit5ZDPA==", + "dev": true, "license": "MIT", "dependencies": { "@changesets/apply-release-plan": "^7.0.14", @@ -2036,6 +2045,7 @@ "version": "3.1.2", "resolved": "https://registry.npmjs.org/@changesets/config/-/config-3.1.2.tgz", "integrity": "sha512-CYiRhA4bWKemdYi/uwImjPxqWNpqGPNbEBdX1BdONALFIDK7MCUj6FPkzD+z9gJcvDFUQJn9aDVf4UG7OT6Kog==", + "dev": true, "license": "MIT", "dependencies": { "@changesets/errors": "^0.2.0", @@ -2051,6 +2061,7 @@ "version": "0.2.0", "resolved": "https://registry.npmjs.org/@changesets/errors/-/errors-0.2.0.tgz", "integrity": "sha512-6BLOQUscTpZeGljvyQXlWOItQyU71kCdGz7Pi8H8zdw6BI0g3m43iL4xKUVPWtG+qrrL9DTjpdn8eYuCQSRpow==", + "dev": true, "license": "MIT", "dependencies": { "extendable-error": "^0.1.5" @@ -2060,6 +2071,7 @@ "version": "2.1.3", "resolved": "https://registry.npmjs.org/@changesets/get-dependents-graph/-/get-dependents-graph-2.1.3.tgz", "integrity": "sha512-gphr+v0mv2I3Oxt19VdWRRUxq3sseyUpX9DaHpTUmLj92Y10AGy+XOtV+kbM6L/fDcpx7/ISDFK6T8A/P3lOdQ==", + "dev": true, "license": "MIT", "dependencies": { "@changesets/types": "^6.1.0", @@ -2072,6 +2084,7 @@ "version": "4.0.14", "resolved": "https://registry.npmjs.org/@changesets/get-release-plan/-/get-release-plan-4.0.14.tgz", "integrity": "sha512-yjZMHpUHgl4Xl5gRlolVuxDkm4HgSJqT93Ri1Uz8kGrQb+5iJ8dkXJ20M2j/Y4iV5QzS2c5SeTxVSKX+2eMI0g==", + "dev": true, "license": "MIT", "dependencies": { "@changesets/assemble-release-plan": "^6.0.9", @@ -2086,12 +2099,14 @@ "version": "0.4.0", "resolved": "https://registry.npmjs.org/@changesets/get-version-range-type/-/get-version-range-type-0.4.0.tgz", "integrity": "sha512-hwawtob9DryoGTpixy1D3ZXbGgJu1Rhr+ySH2PvTLHvkZuQ7sRT4oQwMh0hbqZH1weAooedEjRsbrWcGLCeyVQ==", + "dev": true, "license": "MIT" }, "node_modules/@changesets/git": { "version": "3.0.4", "resolved": "https://registry.npmjs.org/@changesets/git/-/git-3.0.4.tgz", "integrity": "sha512-BXANzRFkX+XcC1q/d27NKvlJ1yf7PSAgi8JG6dt8EfbHFHi4neau7mufcSca5zRhwOL8j9s6EqsxmT+s+/E6Sw==", + "dev": true, "license": "MIT", "dependencies": { "@changesets/errors": "^0.2.0", @@ -2105,6 +2120,7 @@ "version": "0.1.1", "resolved": "https://registry.npmjs.org/@changesets/logger/-/logger-0.1.1.tgz", "integrity": "sha512-OQtR36ZlnuTxKqoW4Sv6x5YIhOmClRd5pWsjZsddYxpWs517R0HkyiefQPIytCVh4ZcC5x9XaG8KTdd5iRQUfg==", + "dev": true, "license": "MIT", "dependencies": { "picocolors": "^1.1.0" @@ -2114,6 +2130,7 @@ "version": "0.4.2", "resolved": "https://registry.npmjs.org/@changesets/parse/-/parse-0.4.2.tgz", "integrity": "sha512-Uo5MC5mfg4OM0jU3up66fmSn6/NE9INK+8/Vn/7sMVcdWg46zfbvvUSjD9EMonVqPi9fbrJH9SXHn48Tr1f2yA==", + "dev": true, "license": "MIT", "dependencies": { "@changesets/types": "^6.1.0", @@ -2124,6 +2141,7 @@ "version": "2.0.2", "resolved": "https://registry.npmjs.org/@changesets/pre/-/pre-2.0.2.tgz", "integrity": "sha512-HaL/gEyFVvkf9KFg6484wR9s0qjAXlZ8qWPDkTyKF6+zqjBe/I2mygg3MbpZ++hdi0ToqNUF8cjj7fBy0dg8Ug==", + "dev": true, "license": "MIT", "dependencies": { "@changesets/errors": "^0.2.0", @@ -2136,6 +2154,7 @@ "version": "0.6.6", "resolved": "https://registry.npmjs.org/@changesets/read/-/read-0.6.6.tgz", "integrity": "sha512-P5QaN9hJSQQKJShzzpBT13FzOSPyHbqdoIBUd2DJdgvnECCyO6LmAOWSV+O8se2TaZJVwSXjL+v9yhb+a9JeJg==", + "dev": true, "license": "MIT", "dependencies": { "@changesets/git": "^3.0.4", @@ -2151,6 +2170,7 @@ "version": "0.1.2", "resolved": "https://registry.npmjs.org/@changesets/should-skip-package/-/should-skip-package-0.1.2.tgz", "integrity": "sha512-qAK/WrqWLNCP22UDdBTMPH5f41elVDlsNyat180A33dWxuUDyNpg6fPi/FyTZwRriVjg0L8gnjJn2F9XAoF0qw==", + "dev": true, "license": "MIT", "dependencies": { "@changesets/types": "^6.1.0", @@ -2161,12 +2181,14 @@ "version": "6.1.0", "resolved": "https://registry.npmjs.org/@changesets/types/-/types-6.1.0.tgz", "integrity": "sha512-rKQcJ+o1nKNgeoYRHKOS07tAMNd3YSN0uHaJOZYjBAgxfV7TUE7JE+z4BzZdQwb5hKaYbayKN5KrYV7ODb2rAA==", + "dev": true, "license": "MIT" }, "node_modules/@changesets/write": { "version": "0.4.0", "resolved": "https://registry.npmjs.org/@changesets/write/-/write-0.4.0.tgz", "integrity": "sha512-CdTLvIOPiCNuH71pyDu3rA+Q0n65cmAbXnwWH84rKGiFumFzkmHNT8KHTMEchcxN+Kl8I54xGUhJ7l3E7X396Q==", + "dev": true, "license": "MIT", "dependencies": { "@changesets/types": "^6.1.0", @@ -2175,6 +2197,22 @@ "prettier": "^2.7.1" } }, + "node_modules/@changesets/write/node_modules/prettier": { + "version": "2.8.8", + "resolved": "https://registry.npmjs.org/prettier/-/prettier-2.8.8.tgz", + "integrity": "sha512-tdN8qQGvNjw4CHbY+XXk0JgCXn9QiF21a55rBe5LJAU+kDyC4WQn4+awm2Xfk2lQMk5fKup9XgzTZtGkjBdP9Q==", + "dev": true, + "license": "MIT", + "bin": { + "prettier": "bin-prettier.js" + }, + "engines": { + "node": ">=10.13.0" + }, + "funding": { + "url": "https://github.com/prettier/prettier?sponsor=1" + } + }, "node_modules/@ctrl/tinycolor": { "version": "4.2.0", "resolved": "https://registry.npmjs.org/@ctrl/tinycolor/-/tinycolor-4.2.0.tgz", @@ -3424,6 +3462,7 @@ "version": "1.0.3", "resolved": "https://registry.npmjs.org/@inquirer/external-editor/-/external-editor-1.0.3.tgz", "integrity": "sha512-RWbSrDiYmO4LbejWY7ttpxczuwQyZLBUyygsA9Nsv95hpzUWwnNTVQmAq3xuh7vNwCp07UTmE5i11XAEExx4RA==", + "dev": true, "license": "MIT", "dependencies": { "chardet": "^2.1.1", @@ -3639,6 +3678,7 @@ "version": "1.1.0", "resolved": "https://registry.npmjs.org/@manypkg/find-root/-/find-root-1.1.0.tgz", "integrity": "sha512-mki5uBvhHzO8kYYix/WRy2WX8S3B5wdVSc9D6KcU5lQNglP2yt58/VfLuAK49glRXChosY8ap2oJ1qgma3GUVA==", + "dev": true, "license": "MIT", "dependencies": { "@babel/runtime": "^7.5.5", @@ -3651,12 +3691,14 @@ "version": "12.20.55", "resolved": "https://registry.npmjs.org/@types/node/-/node-12.20.55.tgz", "integrity": "sha512-J8xLz7q2OFulZ2cyGTLE1TbbZcjpno7FaN6zdJNrgAdrJ+DZzh/uFR6YrTb4C+nXakvud8Q4+rbhoIWlYQbUFQ==", + "dev": true, "license": "MIT" }, "node_modules/@manypkg/find-root/node_modules/fs-extra": { "version": "8.1.0", "resolved": "https://registry.npmjs.org/fs-extra/-/fs-extra-8.1.0.tgz", "integrity": "sha512-yhlQgA6mnOJUKOsRUFsgJdQCvkKhcz8tlZG5HBQfReYZy46OwLcY+Zia0mtdHsOo9y/hP+CxMN0TU9QxoOtG4g==", + "dev": true, "license": "MIT", "dependencies": { "graceful-fs": "^4.2.0", @@ -3671,6 +3713,7 @@ "version": "1.1.3", "resolved": "https://registry.npmjs.org/@manypkg/get-packages/-/get-packages-1.1.3.tgz", "integrity": "sha512-fo+QhuU3qE/2TQMQmbVMqaQ6EWbMhi4ABWP+O4AM1NqPBuy0OrApV5LO6BrrgnhtAHS2NH6RrVk9OL181tTi8A==", + "dev": true, "license": "MIT", "dependencies": { "@babel/runtime": "^7.5.5", @@ -3685,12 +3728,14 @@ "version": "4.1.0", "resolved": "https://registry.npmjs.org/@changesets/types/-/types-4.1.0.tgz", "integrity": "sha512-LDQvVDv5Kb50ny2s25Fhm3d9QSZimsoUGBsUioj6MC3qbMUCuC8GPIvk/M6IvXx3lYhAs0lwWUQLb+VIEUCECw==", + "dev": true, "license": "MIT" }, "node_modules/@manypkg/get-packages/node_modules/fs-extra": { "version": "8.1.0", "resolved": "https://registry.npmjs.org/fs-extra/-/fs-extra-8.1.0.tgz", "integrity": "sha512-yhlQgA6mnOJUKOsRUFsgJdQCvkKhcz8tlZG5HBQfReYZy46OwLcY+Zia0mtdHsOo9y/hP+CxMN0TU9QxoOtG4g==", + "dev": true, "license": "MIT", "dependencies": { "graceful-fs": "^4.2.0", @@ -3751,98 +3796,831 @@ "@noble/hashes": "1.8.0" }, "engines": { - "node": "^14.21.3 || >=16" - }, - "funding": { - "url": "https://paulmillr.com/funding/" + "node": "^14.21.3 || >=16" + }, + "funding": { + "url": "https://paulmillr.com/funding/" + } + }, + "node_modules/@noble/hashes": { + "version": "1.8.0", + "resolved": "https://registry.npmjs.org/@noble/hashes/-/hashes-1.8.0.tgz", + "integrity": "sha512-jCs9ldd7NwzpgXDIf6P3+NrHh9/sD6CQdxHyjQI+h/6rDNo88ypBxxz45UDuZHz9r3tNz7N/VInSVoVdtXEI4A==", + "license": "MIT", + "engines": { + "node": "^14.21.3 || >=16" + }, + "funding": { + "url": "https://paulmillr.com/funding/" + } + }, + "node_modules/@nodelib/fs.scandir": { + "version": "2.1.5", + "resolved": "https://registry.npmjs.org/@nodelib/fs.scandir/-/fs.scandir-2.1.5.tgz", + "integrity": "sha512-vq24Bq3ym5HEQm2NKCr3yXDwjc7vTsEThRDnkp2DK9p1uqLR+DHurm/NOTo0KG7HYHU7eppKZj3MyqYuMBf62g==", + "dev": true, + "license": "MIT", + "dependencies": { + "@nodelib/fs.stat": "2.0.5", + "run-parallel": "^1.1.9" + }, + "engines": { + "node": ">= 8" + } + }, + "node_modules/@nodelib/fs.stat": { + "version": "2.0.5", + "resolved": "https://registry.npmjs.org/@nodelib/fs.stat/-/fs.stat-2.0.5.tgz", + "integrity": "sha512-RkhPPp2zrqDAQA/2jNhnztcPAlv64XdhIp7a7454A5ovI7Bukxgt7MX7udwAu3zg1DcpPU0rz3VV1SeaqvY4+A==", + "dev": true, + "license": "MIT", + "engines": { + "node": ">= 8" + } + }, + "node_modules/@nodelib/fs.walk": { + "version": "1.2.8", + "resolved": "https://registry.npmjs.org/@nodelib/fs.walk/-/fs.walk-1.2.8.tgz", + "integrity": "sha512-oGB+UxlgWcgQkgwo8GcEGwemoTFt3FIO9ababBmaGwXIoBKZ+GTy0pP185beGg7Llih/NSHSV2XAs1lnznocSg==", + "dev": true, + "license": "MIT", + "dependencies": { + "@nodelib/fs.scandir": "2.1.5", + "fastq": "^1.6.0" + }, + "engines": { + "node": ">= 8" + } + }, + "node_modules/@open-draft/deferred-promise": { + "version": "3.0.0", + "resolved": "https://registry.npmjs.org/@open-draft/deferred-promise/-/deferred-promise-3.0.0.tgz", + "integrity": "sha512-XW375UK8/9SqUVNVa6M0yEy8+iTi4QN5VZ7aZuRFQmy76LRwI9wy5F4YIBU6T+eTe2/DNDo8tqu8RHlwLHM6RA==", + "dev": true, + "license": "MIT" + }, + "node_modules/@open-draft/logger": { + "version": "0.3.0", + "resolved": "https://registry.npmjs.org/@open-draft/logger/-/logger-0.3.0.tgz", + "integrity": "sha512-X2g45fzhxH238HKO4xbSr7+wBS8Fvw6ixhTDuvLd5mqh6bJJCFAPwU9mPDxbcrRtfxv4u5IHCEH77BmxvXmmxQ==", + "dev": true, + "license": "MIT", + "dependencies": { + "is-node-process": "^1.2.0", + "outvariant": "^1.4.0" + } + }, + "node_modules/@open-draft/until": { + "version": "2.1.0", + "resolved": "https://registry.npmjs.org/@open-draft/until/-/until-2.1.0.tgz", + "integrity": "sha512-U69T3ItWHvLwGg5eJ0n3I62nWuE6ilHlmz7zM0npLBRvPRd7e6NYmg54vvRtP5mZG7kZqZCFVdsTWo7BPtBujg==", + "dev": true, + "license": "MIT" + }, + "node_modules/@oslojs/encoding": { + "version": "1.1.0", + "resolved": "https://registry.npmjs.org/@oslojs/encoding/-/encoding-1.1.0.tgz", + "integrity": "sha512-70wQhgYmndg4GCPxPPxPGevRKqTIJ2Nh4OkiMWmDAVYsTQ+Ta7Sq+rPevXyXGdzr30/qZBnyOalCszoMxlyldQ==", + "license": "MIT" + }, + "node_modules/@oxc-project/types": { + "version": "0.102.0", + "resolved": "https://registry.npmjs.org/@oxc-project/types/-/types-0.102.0.tgz", + "integrity": "sha512-8Skrw405g+/UJPKWJ1twIk3BIH2nXdiVlVNtYT23AXVwpsd79es4K+KYt06Fbnkc5BaTvk/COT2JuCLYdwnCdA==", + "dev": true, + "license": "MIT", + "funding": { + "url": "https://github.com/sponsors/Boshen" + } + }, + "node_modules/@oxfmt/binding-android-arm-eabi": { + "version": "0.46.0", + "resolved": "https://registry.npmjs.org/@oxfmt/binding-android-arm-eabi/-/binding-android-arm-eabi-0.46.0.tgz", + "integrity": "sha512-b1doV4WRcJU+BESSlCvCjV+5CEr/T6h0frArAdV26Nir+gGNFNaylvDiiMPfF1pxeV0txZEs38ojzJaxBYg+ng==", + "cpu": [ + "arm" + ], + "dev": true, + "license": "MIT", + "optional": true, + "os": [ + "android" + ], + "engines": { + "node": "^20.19.0 || >=22.12.0" + } + }, + "node_modules/@oxfmt/binding-android-arm64": { + "version": "0.46.0", + "resolved": "https://registry.npmjs.org/@oxfmt/binding-android-arm64/-/binding-android-arm64-0.46.0.tgz", + "integrity": "sha512-v6+HhjsoV3GO0u2u9jLSAZrvWfTraDxKofUIQ7/ktS7tzS+epVsxdHmeM+XxuNcAY/nWxxU1Sg4JcGTNRXraBA==", + "cpu": [ + "arm64" + ], + "dev": true, + "license": "MIT", + "optional": true, + "os": [ + "android" + ], + "engines": { + "node": "^20.19.0 || >=22.12.0" + } + }, + "node_modules/@oxfmt/binding-darwin-arm64": { + "version": "0.46.0", + "resolved": "https://registry.npmjs.org/@oxfmt/binding-darwin-arm64/-/binding-darwin-arm64-0.46.0.tgz", + "integrity": "sha512-3eeooJGrqGIlI5MyryDZsAcKXSmKIgAD4yYtfRrRJzXZ0UTFZtiSveIur56YPrGMYZwT4XyVhHsMqrNwr1XeFA==", + "cpu": [ + "arm64" + ], + "dev": true, + "license": "MIT", + "optional": true, + "os": [ + "darwin" + ], + "engines": { + "node": "^20.19.0 || >=22.12.0" + } + }, + "node_modules/@oxfmt/binding-darwin-x64": { + "version": "0.46.0", + "resolved": "https://registry.npmjs.org/@oxfmt/binding-darwin-x64/-/binding-darwin-x64-0.46.0.tgz", + "integrity": "sha512-QG8BDM0CXWbu84k2SKmCqfEddPQPFiBicwtYnLqHRWZZl57HbtOLRMac/KTq2NO4AEc4ICCBpFxJIV9zcqYfkQ==", + "cpu": [ + "x64" + ], + "dev": true, + "license": "MIT", + "optional": true, + "os": [ + "darwin" + ], + "engines": { + "node": "^20.19.0 || >=22.12.0" + } + }, + "node_modules/@oxfmt/binding-freebsd-x64": { + "version": "0.46.0", + "resolved": "https://registry.npmjs.org/@oxfmt/binding-freebsd-x64/-/binding-freebsd-x64-0.46.0.tgz", + "integrity": "sha512-9DdCqS/n2ncu/Chazvt3cpgAjAmIGQDz7hFKSrNItMApyV/Ja9mz3hD4JakIE3nS8PW9smEbPWnb389QLBY4nw==", + "cpu": [ + "x64" + ], + "dev": true, + "license": "MIT", + "optional": true, + "os": [ + "freebsd" + ], + "engines": { + "node": "^20.19.0 || >=22.12.0" + } + }, + "node_modules/@oxfmt/binding-linux-arm-gnueabihf": { + "version": "0.46.0", + "resolved": "https://registry.npmjs.org/@oxfmt/binding-linux-arm-gnueabihf/-/binding-linux-arm-gnueabihf-0.46.0.tgz", + "integrity": "sha512-Dgs7VeE2jT0LHMhw6tPEt0xQYe54kBqHEovmWsv4FVQlegCOvlIJNx0S8n4vj8WUtpT+Z6BD2HhKJPLglLxvZg==", + "cpu": [ + "arm" + ], + "dev": true, + "license": "MIT", + "optional": true, + "os": [ + "linux" + ], + "engines": { + "node": "^20.19.0 || >=22.12.0" + } + }, + "node_modules/@oxfmt/binding-linux-arm-musleabihf": { + "version": "0.46.0", + "resolved": "https://registry.npmjs.org/@oxfmt/binding-linux-arm-musleabihf/-/binding-linux-arm-musleabihf-0.46.0.tgz", + "integrity": "sha512-Zxn3adhTH13JKnU4xXJj8FeEfF680XjXh3gSShKl57HCMBRde2tUJTgogV/1MSHA80PJEVrDa7r66TLVq3Ia7Q==", + "cpu": [ + "arm" + ], + "dev": true, + "license": "MIT", + "optional": true, + "os": [ + "linux" + ], + "engines": { + "node": "^20.19.0 || >=22.12.0" + } + }, + "node_modules/@oxfmt/binding-linux-arm64-gnu": { + "version": "0.46.0", + "resolved": "https://registry.npmjs.org/@oxfmt/binding-linux-arm64-gnu/-/binding-linux-arm64-gnu-0.46.0.tgz", + "integrity": "sha512-+TWipjrgVM8D7aIdDD0tlr3teLTTvQTn7QTE5BpT10H1Fj82gfdn9X6nn2sDgx/MepuSCfSnzFNJq2paLL0OiA==", + "cpu": [ + "arm64" + ], + "dev": true, + "license": "MIT", + "optional": true, + "os": [ + "linux" + ], + "engines": { + "node": "^20.19.0 || >=22.12.0" + } + }, + "node_modules/@oxfmt/binding-linux-arm64-musl": { + "version": "0.46.0", + "resolved": "https://registry.npmjs.org/@oxfmt/binding-linux-arm64-musl/-/binding-linux-arm64-musl-0.46.0.tgz", + "integrity": "sha512-aAUPBWJ1lGwwnxZUEDLJ94+Iy6MuwJwPxUgO4sCA5mEEyDk7b+cDQ+JpX1VR150Zoyd+D49gsrUzpUK5h587Eg==", + "cpu": [ + "arm64" + ], + "dev": true, + "license": "MIT", + "optional": true, + "os": [ + "linux" + ], + "engines": { + "node": "^20.19.0 || >=22.12.0" + } + }, + "node_modules/@oxfmt/binding-linux-ppc64-gnu": { + "version": "0.46.0", + "resolved": "https://registry.npmjs.org/@oxfmt/binding-linux-ppc64-gnu/-/binding-linux-ppc64-gnu-0.46.0.tgz", + "integrity": "sha512-ufBCJukyFX/UDrokP/r6BGDoTInnsDs7bxyzKAgMiZlt2Qu8GPJSJ6Zm6whIiJzKk0naxA8ilwmbO1LMw6Htxw==", + "cpu": [ + "ppc64" + ], + "dev": true, + "license": "MIT", + "optional": true, + "os": [ + "linux" + ], + "engines": { + "node": "^20.19.0 || >=22.12.0" + } + }, + "node_modules/@oxfmt/binding-linux-riscv64-gnu": { + "version": "0.46.0", + "resolved": "https://registry.npmjs.org/@oxfmt/binding-linux-riscv64-gnu/-/binding-linux-riscv64-gnu-0.46.0.tgz", + "integrity": "sha512-eqtlC2YmPqjun76R1gVfGLuKWx7NuEnLEAudZ7n6ipSKbCZTqIKSs1b5Y8K/JHZsRpLkeSmAAjig5HOIg8fQzQ==", + "cpu": [ + "riscv64" + ], + "dev": true, + "license": "MIT", + "optional": true, + "os": [ + "linux" + ], + "engines": { + "node": "^20.19.0 || >=22.12.0" + } + }, + "node_modules/@oxfmt/binding-linux-riscv64-musl": { + "version": "0.46.0", + "resolved": "https://registry.npmjs.org/@oxfmt/binding-linux-riscv64-musl/-/binding-linux-riscv64-musl-0.46.0.tgz", + "integrity": "sha512-yccVOO2nMXkQLGgy0He3EQEwKD7NF0zEk+/OWmroznkqXyJdN6bfK0LtNnr6/14Bh3FjpYq7bP33l/VloCnxpA==", + "cpu": [ + "riscv64" + ], + "dev": true, + "license": "MIT", + "optional": true, + "os": [ + "linux" + ], + "engines": { + "node": "^20.19.0 || >=22.12.0" + } + }, + "node_modules/@oxfmt/binding-linux-s390x-gnu": { + "version": "0.46.0", + "resolved": "https://registry.npmjs.org/@oxfmt/binding-linux-s390x-gnu/-/binding-linux-s390x-gnu-0.46.0.tgz", + "integrity": "sha512-aAf7fG23OQCey6VRPj9IeCraoYtpgtx0ZyJ1CXkPyT1wjzBE7c3xtuxHe/AdHaJfVVb/SXpSk8Gl1LzyQupSqw==", + "cpu": [ + "s390x" + ], + "dev": true, + "license": "MIT", + "optional": true, + "os": [ + "linux" + ], + "engines": { + "node": "^20.19.0 || >=22.12.0" + } + }, + "node_modules/@oxfmt/binding-linux-x64-gnu": { + "version": "0.46.0", + "resolved": "https://registry.npmjs.org/@oxfmt/binding-linux-x64-gnu/-/binding-linux-x64-gnu-0.46.0.tgz", + "integrity": "sha512-q0JPsTMyJNjYrBvYFDz4WbVsafNZaPCZv4RnFypRotLqpKROtBZcEaXQW4eb9YmvLU3NckVemLJnzkSZSdmOxw==", + "cpu": [ + "x64" + ], + "dev": true, + "license": "MIT", + "optional": true, + "os": [ + "linux" + ], + "engines": { + "node": "^20.19.0 || >=22.12.0" + } + }, + "node_modules/@oxfmt/binding-linux-x64-musl": { + "version": "0.46.0", + "resolved": "https://registry.npmjs.org/@oxfmt/binding-linux-x64-musl/-/binding-linux-x64-musl-0.46.0.tgz", + "integrity": "sha512-7LsLY9Cw57GPkhSR+duI3mt9baRczK/DtHYSldQ4BEU92da9igBQNl4z7Vq5U9NNPsh1FmpKvv1q9WDtiUQR1A==", + "cpu": [ + "x64" + ], + "dev": true, + "license": "MIT", + "optional": true, + "os": [ + "linux" + ], + "engines": { + "node": "^20.19.0 || >=22.12.0" + } + }, + "node_modules/@oxfmt/binding-openharmony-arm64": { + "version": "0.46.0", + "resolved": "https://registry.npmjs.org/@oxfmt/binding-openharmony-arm64/-/binding-openharmony-arm64-0.46.0.tgz", + "integrity": "sha512-lHiBOz8Duaku7JtRNLlps3j++eOaICPZSd8FCVmTDM4DFOPT71Bjn7g6iar1z7StXlKRweUKxWUs4sA+zWGDXg==", + "cpu": [ + "arm64" + ], + "dev": true, + "license": "MIT", + "optional": true, + "os": [ + "openharmony" + ], + "engines": { + "node": "^20.19.0 || >=22.12.0" + } + }, + "node_modules/@oxfmt/binding-win32-arm64-msvc": { + "version": "0.46.0", + "resolved": "https://registry.npmjs.org/@oxfmt/binding-win32-arm64-msvc/-/binding-win32-arm64-msvc-0.46.0.tgz", + "integrity": "sha512-/5ktYUliP89RhgC37DBH1x20U5zPSZMy3cMEcO0j3793rbHP9MWsknBwQB6eozRzWmYrh0IFM/p20EbPvDlYlg==", + "cpu": [ + "arm64" + ], + "dev": true, + "license": "MIT", + "optional": true, + "os": [ + "win32" + ], + "engines": { + "node": "^20.19.0 || >=22.12.0" + } + }, + "node_modules/@oxfmt/binding-win32-ia32-msvc": { + "version": "0.46.0", + "resolved": "https://registry.npmjs.org/@oxfmt/binding-win32-ia32-msvc/-/binding-win32-ia32-msvc-0.46.0.tgz", + "integrity": "sha512-3WTnoiuIr8XvV0DIY7SN+1uJSwKf4sPpcbHfobcRT9JutGcLaef/miyBB87jxd3aqH+mS0+G5lsgHuXLUwjjpQ==", + "cpu": [ + "ia32" + ], + "dev": true, + "license": "MIT", + "optional": true, + "os": [ + "win32" + ], + "engines": { + "node": "^20.19.0 || >=22.12.0" + } + }, + "node_modules/@oxfmt/binding-win32-x64-msvc": { + "version": "0.46.0", + "resolved": "https://registry.npmjs.org/@oxfmt/binding-win32-x64-msvc/-/binding-win32-x64-msvc-0.46.0.tgz", + "integrity": "sha512-IXxiQpkYnOwNfP23vzwSfhdpxJzyiPTY7eTn6dn3DsriKddESzM8i6kfq9R7CD/PUJwCvQT22NgtygBeug3KoA==", + "cpu": [ + "x64" + ], + "dev": true, + "license": "MIT", + "optional": true, + "os": [ + "win32" + ], + "engines": { + "node": "^20.19.0 || >=22.12.0" + } + }, + "node_modules/@oxlint-tsgolint/darwin-arm64": { + "version": "0.21.1", + "resolved": "https://registry.npmjs.org/@oxlint-tsgolint/darwin-arm64/-/darwin-arm64-0.21.1.tgz", + "integrity": "sha512-7TLjyWe4wG9saJc992VWmaHq2hwKfOEEVTjheReXJXaDhavMZI4X9a6nKhbEng4IVkYtzjD2jw16vw2WFXLYLw==", + "cpu": [ + "arm64" + ], + "dev": true, + "license": "MIT", + "optional": true, + "os": [ + "darwin" + ] + }, + "node_modules/@oxlint-tsgolint/darwin-x64": { + "version": "0.21.1", + "resolved": "https://registry.npmjs.org/@oxlint-tsgolint/darwin-x64/-/darwin-x64-0.21.1.tgz", + "integrity": "sha512-7wf9Wf75nTzA7zpL9myhFe2RKvfuqGUOADNvUooCjEWvh7hmPz3lSEqTMh5Z/VQhzsG04mM9ACyghxhRzq7zFw==", + "cpu": [ + "x64" + ], + "dev": true, + "license": "MIT", + "optional": true, + "os": [ + "darwin" + ] + }, + "node_modules/@oxlint-tsgolint/linux-arm64": { + "version": "0.21.1", + "resolved": "https://registry.npmjs.org/@oxlint-tsgolint/linux-arm64/-/linux-arm64-0.21.1.tgz", + "integrity": "sha512-IPuQN/Vd0Rjklg/cCGBbQyUuRBp2f6LQXpZYwk5ivOR6V/+CgiYsv8pn/PVY7gjeyoNvPQrXB7xMjHUO2YZbdw==", + "cpu": [ + "arm64" + ], + "dev": true, + "license": "MIT", + "optional": true, + "os": [ + "linux" + ] + }, + "node_modules/@oxlint-tsgolint/linux-x64": { + "version": "0.21.1", + "resolved": "https://registry.npmjs.org/@oxlint-tsgolint/linux-x64/-/linux-x64-0.21.1.tgz", + "integrity": "sha512-d1niGuTbh2qiv7dR7tqkbOcM5cIR63of0lMBFdEQavL1KrJV8zuRdwdi68K7MNGdgoR+J5A9ajpGGvsHwp1bPg==", + "cpu": [ + "x64" + ], + "dev": true, + "license": "MIT", + "optional": true, + "os": [ + "linux" + ] + }, + "node_modules/@oxlint-tsgolint/win32-arm64": { + "version": "0.21.1", + "resolved": "https://registry.npmjs.org/@oxlint-tsgolint/win32-arm64/-/win32-arm64-0.21.1.tgz", + "integrity": "sha512-ICu9y2JLnFPvFqstnWPPNqBM8LK8BWw2OTeaR0UgEMm4hOSbrZAKv1/hwZYyiLqnCNjBL87AGSQIgTHCYlsipw==", + "cpu": [ + "arm64" + ], + "dev": true, + "license": "MIT", + "optional": true, + "os": [ + "win32" + ] + }, + "node_modules/@oxlint-tsgolint/win32-x64": { + "version": "0.21.1", + "resolved": "https://registry.npmjs.org/@oxlint-tsgolint/win32-x64/-/win32-x64-0.21.1.tgz", + "integrity": "sha512-cTEFCFjCj6iXfrSHcvajSPNqhEA4TxSzU3gFxbdGSAUTNXGToU99IbdhWAPSbhcucoym0XE4Zl7E41NiSkNTug==", + "cpu": [ + "x64" + ], + "dev": true, + "license": "MIT", + "optional": true, + "os": [ + "win32" + ] + }, + "node_modules/@oxlint/binding-android-arm-eabi": { + "version": "1.61.0", + "resolved": "https://registry.npmjs.org/@oxlint/binding-android-arm-eabi/-/binding-android-arm-eabi-1.61.0.tgz", + "integrity": "sha512-6eZBPgiigK5txqoVgRqxbaxiom4lM8AP8CyKPPvpzKnQ3iFRFOIDc+0AapF+qsUSwjOzr5SGk4SxQDpQhkSJMQ==", + "cpu": [ + "arm" + ], + "dev": true, + "license": "MIT", + "optional": true, + "os": [ + "android" + ], + "engines": { + "node": "^20.19.0 || >=22.12.0" + } + }, + "node_modules/@oxlint/binding-android-arm64": { + "version": "1.61.0", + "resolved": "https://registry.npmjs.org/@oxlint/binding-android-arm64/-/binding-android-arm64-1.61.0.tgz", + "integrity": "sha512-CkwLR69MUnyv5wjzebvbbtTSUwqLxM35CXE79bHqDIK+NtKmPEUpStTcLQRZMCo4MP0qRT6TXIQVpK0ZVScnMA==", + "cpu": [ + "arm64" + ], + "dev": true, + "license": "MIT", + "optional": true, + "os": [ + "android" + ], + "engines": { + "node": "^20.19.0 || >=22.12.0" + } + }, + "node_modules/@oxlint/binding-darwin-arm64": { + "version": "1.61.0", + "resolved": "https://registry.npmjs.org/@oxlint/binding-darwin-arm64/-/binding-darwin-arm64-1.61.0.tgz", + "integrity": "sha512-8JbefTkbmvqkqWjmQrHke+MdpgT2UghhD/ktM4FOQSpGeCgbMToJEKdl9zwhr/YWTl92i4QI1KiTwVExpcUN8A==", + "cpu": [ + "arm64" + ], + "dev": true, + "license": "MIT", + "optional": true, + "os": [ + "darwin" + ], + "engines": { + "node": "^20.19.0 || >=22.12.0" + } + }, + "node_modules/@oxlint/binding-darwin-x64": { + "version": "1.61.0", + "resolved": "https://registry.npmjs.org/@oxlint/binding-darwin-x64/-/binding-darwin-x64-1.61.0.tgz", + "integrity": "sha512-uWpoxDT47hTnDLcdEh5jVbso8rlTTu5o0zuqa9J8E0JAKmIWn7kGFEIB03Pycn2hd2vKxybPGLhjURy/9We5FQ==", + "cpu": [ + "x64" + ], + "dev": true, + "license": "MIT", + "optional": true, + "os": [ + "darwin" + ], + "engines": { + "node": "^20.19.0 || >=22.12.0" + } + }, + "node_modules/@oxlint/binding-freebsd-x64": { + "version": "1.61.0", + "resolved": "https://registry.npmjs.org/@oxlint/binding-freebsd-x64/-/binding-freebsd-x64-1.61.0.tgz", + "integrity": "sha512-K/o4hEyW7flfMel0iBVznmMBt7VIMHGdjADocHKpK1DUF9erpWnJ+BSSWd2W0c8K3mPtpph+CuHzRU6CI3l9jQ==", + "cpu": [ + "x64" + ], + "dev": true, + "license": "MIT", + "optional": true, + "os": [ + "freebsd" + ], + "engines": { + "node": "^20.19.0 || >=22.12.0" + } + }, + "node_modules/@oxlint/binding-linux-arm-gnueabihf": { + "version": "1.61.0", + "resolved": "https://registry.npmjs.org/@oxlint/binding-linux-arm-gnueabihf/-/binding-linux-arm-gnueabihf-1.61.0.tgz", + "integrity": "sha512-P6040ZkcyweJ0Po9yEFqJCdvZnf3VNCGs1SIHgXDf8AAQNC6ID/heXQs9iSgo2FH7gKaKq32VWc59XZwL34C5Q==", + "cpu": [ + "arm" + ], + "dev": true, + "license": "MIT", + "optional": true, + "os": [ + "linux" + ], + "engines": { + "node": "^20.19.0 || >=22.12.0" + } + }, + "node_modules/@oxlint/binding-linux-arm-musleabihf": { + "version": "1.61.0", + "resolved": "https://registry.npmjs.org/@oxlint/binding-linux-arm-musleabihf/-/binding-linux-arm-musleabihf-1.61.0.tgz", + "integrity": "sha512-bwxrGCzTZkuB+THv2TQ1aTkVEfv5oz8sl+0XZZCpoYzErJD8OhPQOTA0ENPd1zJz8QsVdSzSrS2umKtPq4/JXg==", + "cpu": [ + "arm" + ], + "dev": true, + "license": "MIT", + "optional": true, + "os": [ + "linux" + ], + "engines": { + "node": "^20.19.0 || >=22.12.0" + } + }, + "node_modules/@oxlint/binding-linux-arm64-gnu": { + "version": "1.61.0", + "resolved": "https://registry.npmjs.org/@oxlint/binding-linux-arm64-gnu/-/binding-linux-arm64-gnu-1.61.0.tgz", + "integrity": "sha512-vkhb9/wKguMkLlrm3FoJW/Xmdv31GgYAE+x8lxxQ+7HeOxXUySI0q36a3NTVIuQUdLzxCI1zzMGsk1o37FOe3w==", + "cpu": [ + "arm64" + ], + "dev": true, + "license": "MIT", + "optional": true, + "os": [ + "linux" + ], + "engines": { + "node": "^20.19.0 || >=22.12.0" + } + }, + "node_modules/@oxlint/binding-linux-arm64-musl": { + "version": "1.61.0", + "resolved": "https://registry.npmjs.org/@oxlint/binding-linux-arm64-musl/-/binding-linux-arm64-musl-1.61.0.tgz", + "integrity": "sha512-bl1dQh8LnVqsj6oOQAcxwbuOmNJkwc4p6o//HTBZhNTzJy21TLDwAviMqUFNUxDHkPGpmdKTSN4tWTjLryP8xg==", + "cpu": [ + "arm64" + ], + "dev": true, + "license": "MIT", + "optional": true, + "os": [ + "linux" + ], + "engines": { + "node": "^20.19.0 || >=22.12.0" + } + }, + "node_modules/@oxlint/binding-linux-ppc64-gnu": { + "version": "1.61.0", + "resolved": "https://registry.npmjs.org/@oxlint/binding-linux-ppc64-gnu/-/binding-linux-ppc64-gnu-1.61.0.tgz", + "integrity": "sha512-QoOX6KB2IiEpyOj/HKqaxi+NQHPnOgNgnr22n9N4ANJCzXkUlj1UmeAbFb4PpqdlHIzvGDM5xZ0OKtcLq9RhiQ==", + "cpu": [ + "ppc64" + ], + "dev": true, + "license": "MIT", + "optional": true, + "os": [ + "linux" + ], + "engines": { + "node": "^20.19.0 || >=22.12.0" + } + }, + "node_modules/@oxlint/binding-linux-riscv64-gnu": { + "version": "1.61.0", + "resolved": "https://registry.npmjs.org/@oxlint/binding-linux-riscv64-gnu/-/binding-linux-riscv64-gnu-1.61.0.tgz", + "integrity": "sha512-1TGcTerjY6p152wCof3oKElccq3xHljS/Mucp04gV/4ATpP6nO7YNnp7opEg6SHkv2a57/b4b8Ndm9znJ1/qAw==", + "cpu": [ + "riscv64" + ], + "dev": true, + "license": "MIT", + "optional": true, + "os": [ + "linux" + ], + "engines": { + "node": "^20.19.0 || >=22.12.0" + } + }, + "node_modules/@oxlint/binding-linux-riscv64-musl": { + "version": "1.61.0", + "resolved": "https://registry.npmjs.org/@oxlint/binding-linux-riscv64-musl/-/binding-linux-riscv64-musl-1.61.0.tgz", + "integrity": "sha512-65wXEmZIrX2ADwC8i/qFL4EWLSbeuBpAm3suuX1vu4IQkKd+wLT/HU/BOl84kp91u2SxPkPDyQgu4yrqp8vwVA==", + "cpu": [ + "riscv64" + ], + "dev": true, + "license": "MIT", + "optional": true, + "os": [ + "linux" + ], + "engines": { + "node": "^20.19.0 || >=22.12.0" + } + }, + "node_modules/@oxlint/binding-linux-s390x-gnu": { + "version": "1.61.0", + "resolved": "https://registry.npmjs.org/@oxlint/binding-linux-s390x-gnu/-/binding-linux-s390x-gnu-1.61.0.tgz", + "integrity": "sha512-TVvhgMvor7Qa6COeXxCJ7ENOM+lcAOGsQ0iUdPSCv2hxb9qSHLQ4XF1h50S6RE1gBOJ0WV3rNukg4JJJP1LWRA==", + "cpu": [ + "s390x" + ], + "dev": true, + "license": "MIT", + "optional": true, + "os": [ + "linux" + ], + "engines": { + "node": "^20.19.0 || >=22.12.0" } }, - "node_modules/@noble/hashes": { - "version": "1.8.0", - "resolved": "https://registry.npmjs.org/@noble/hashes/-/hashes-1.8.0.tgz", - "integrity": "sha512-jCs9ldd7NwzpgXDIf6P3+NrHh9/sD6CQdxHyjQI+h/6rDNo88ypBxxz45UDuZHz9r3tNz7N/VInSVoVdtXEI4A==", + "node_modules/@oxlint/binding-linux-x64-gnu": { + "version": "1.61.0", + "resolved": "https://registry.npmjs.org/@oxlint/binding-linux-x64-gnu/-/binding-linux-x64-gnu-1.61.0.tgz", + "integrity": "sha512-SjpS5uYuFoDnDdZPwZE59ndF95AsY47R5MliuneTWR1pDm2CxGJaYXbKULI71t5TVfLQUWmrHEGRL9xvuq6dnA==", + "cpu": [ + "x64" + ], + "dev": true, "license": "MIT", + "optional": true, + "os": [ + "linux" + ], "engines": { - "node": "^14.21.3 || >=16" - }, - "funding": { - "url": "https://paulmillr.com/funding/" + "node": "^20.19.0 || >=22.12.0" } }, - "node_modules/@nodelib/fs.scandir": { - "version": "2.1.5", - "resolved": "https://registry.npmjs.org/@nodelib/fs.scandir/-/fs.scandir-2.1.5.tgz", - "integrity": "sha512-vq24Bq3ym5HEQm2NKCr3yXDwjc7vTsEThRDnkp2DK9p1uqLR+DHurm/NOTo0KG7HYHU7eppKZj3MyqYuMBf62g==", + "node_modules/@oxlint/binding-linux-x64-musl": { + "version": "1.61.0", + "resolved": "https://registry.npmjs.org/@oxlint/binding-linux-x64-musl/-/binding-linux-x64-musl-1.61.0.tgz", + "integrity": "sha512-gGfAeGD4sNJGILZbc/yKcIimO9wQnPMoYp9swAaKeEtwsSQAbU+rsdQze5SBtIP6j0QDzeYd4XSSUCRCF+LIeQ==", + "cpu": [ + "x64" + ], + "dev": true, "license": "MIT", - "dependencies": { - "@nodelib/fs.stat": "2.0.5", - "run-parallel": "^1.1.9" - }, + "optional": true, + "os": [ + "linux" + ], "engines": { - "node": ">= 8" + "node": "^20.19.0 || >=22.12.0" } }, - "node_modules/@nodelib/fs.stat": { - "version": "2.0.5", - "resolved": "https://registry.npmjs.org/@nodelib/fs.stat/-/fs.stat-2.0.5.tgz", - "integrity": "sha512-RkhPPp2zrqDAQA/2jNhnztcPAlv64XdhIp7a7454A5ovI7Bukxgt7MX7udwAu3zg1DcpPU0rz3VV1SeaqvY4+A==", + "node_modules/@oxlint/binding-openharmony-arm64": { + "version": "1.61.0", + "resolved": "https://registry.npmjs.org/@oxlint/binding-openharmony-arm64/-/binding-openharmony-arm64-1.61.0.tgz", + "integrity": "sha512-OlVT0LrG/ct33EVtWRyR+B/othwmDWeRxfi13wUdPeb3lAT5TgTcFDcfLfarZtzB4W1nWF/zICMgYdkggX2WmQ==", + "cpu": [ + "arm64" + ], + "dev": true, "license": "MIT", + "optional": true, + "os": [ + "openharmony" + ], "engines": { - "node": ">= 8" + "node": "^20.19.0 || >=22.12.0" } }, - "node_modules/@nodelib/fs.walk": { - "version": "1.2.8", - "resolved": "https://registry.npmjs.org/@nodelib/fs.walk/-/fs.walk-1.2.8.tgz", - "integrity": "sha512-oGB+UxlgWcgQkgwo8GcEGwemoTFt3FIO9ababBmaGwXIoBKZ+GTy0pP185beGg7Llih/NSHSV2XAs1lnznocSg==", + "node_modules/@oxlint/binding-win32-arm64-msvc": { + "version": "1.61.0", + "resolved": "https://registry.npmjs.org/@oxlint/binding-win32-arm64-msvc/-/binding-win32-arm64-msvc-1.61.0.tgz", + "integrity": "sha512-vI//NZPJk6DToiovPtaiwD4iQ7kO1r5ReWQD0sOOyKRtP3E2f6jxin4uvwi3OvDzHA2EFfd7DcZl5dtkQh7g1w==", + "cpu": [ + "arm64" + ], + "dev": true, "license": "MIT", - "dependencies": { - "@nodelib/fs.scandir": "2.1.5", - "fastq": "^1.6.0" - }, + "optional": true, + "os": [ + "win32" + ], "engines": { - "node": ">= 8" + "node": "^20.19.0 || >=22.12.0" } }, - "node_modules/@open-draft/deferred-promise": { - "version": "3.0.0", - "resolved": "https://registry.npmjs.org/@open-draft/deferred-promise/-/deferred-promise-3.0.0.tgz", - "integrity": "sha512-XW375UK8/9SqUVNVa6M0yEy8+iTi4QN5VZ7aZuRFQmy76LRwI9wy5F4YIBU6T+eTe2/DNDo8tqu8RHlwLHM6RA==", - "dev": true, - "license": "MIT" - }, - "node_modules/@open-draft/logger": { - "version": "0.3.0", - "resolved": "https://registry.npmjs.org/@open-draft/logger/-/logger-0.3.0.tgz", - "integrity": "sha512-X2g45fzhxH238HKO4xbSr7+wBS8Fvw6ixhTDuvLd5mqh6bJJCFAPwU9mPDxbcrRtfxv4u5IHCEH77BmxvXmmxQ==", + "node_modules/@oxlint/binding-win32-ia32-msvc": { + "version": "1.61.0", + "resolved": "https://registry.npmjs.org/@oxlint/binding-win32-ia32-msvc/-/binding-win32-ia32-msvc-1.61.0.tgz", + "integrity": "sha512-0ySj4/4zd2XjePs3XAQq7IigIstN4LPQZgCyigX5/ERMLjdWAJfnxcTsrtxZxuij8guJW8foXuHmhGxW0H4dDA==", + "cpu": [ + "ia32" + ], "dev": true, "license": "MIT", - "dependencies": { - "is-node-process": "^1.2.0", - "outvariant": "^1.4.0" + "optional": true, + "os": [ + "win32" + ], + "engines": { + "node": "^20.19.0 || >=22.12.0" } }, - "node_modules/@open-draft/until": { - "version": "2.1.0", - "resolved": "https://registry.npmjs.org/@open-draft/until/-/until-2.1.0.tgz", - "integrity": "sha512-U69T3ItWHvLwGg5eJ0n3I62nWuE6ilHlmz7zM0npLBRvPRd7e6NYmg54vvRtP5mZG7kZqZCFVdsTWo7BPtBujg==", - "dev": true, - "license": "MIT" - }, - "node_modules/@oslojs/encoding": { - "version": "1.1.0", - "resolved": "https://registry.npmjs.org/@oslojs/encoding/-/encoding-1.1.0.tgz", - "integrity": "sha512-70wQhgYmndg4GCPxPPxPGevRKqTIJ2Nh4OkiMWmDAVYsTQ+Ta7Sq+rPevXyXGdzr30/qZBnyOalCszoMxlyldQ==", - "license": "MIT" - }, - "node_modules/@oxc-project/types": { - "version": "0.102.0", - "resolved": "https://registry.npmjs.org/@oxc-project/types/-/types-0.102.0.tgz", - "integrity": "sha512-8Skrw405g+/UJPKWJ1twIk3BIH2nXdiVlVNtYT23AXVwpsd79es4K+KYt06Fbnkc5BaTvk/COT2JuCLYdwnCdA==", + "node_modules/@oxlint/binding-win32-x64-msvc": { + "version": "1.61.0", + "resolved": "https://registry.npmjs.org/@oxlint/binding-win32-x64-msvc/-/binding-win32-x64-msvc-1.61.0.tgz", + "integrity": "sha512-0xgSiyeqDLDZxXoe9CVJrOx3TUVsfyoOY7cNi03JbItNcC9WCZqrSNdrAbHONxhSPaVh/lzfnDcON1RqSUMhHw==", + "cpu": [ + "x64" + ], "dev": true, "license": "MIT", - "funding": { - "url": "https://github.com/sponsors/Boshen" + "optional": true, + "os": [ + "win32" + ], + "engines": { + "node": "^20.19.0 || >=22.12.0" } }, "node_modules/@parcel/watcher": { @@ -5982,6 +6760,7 @@ "version": "4.1.3", "resolved": "https://registry.npmjs.org/ansi-colors/-/ansi-colors-4.1.3.tgz", "integrity": "sha512-/6w/C21Pm1A7aZitlI5Ni/2J6FFQN8i1Cvz3kHABAAbw93v/NlvKdVOqz7CCWz/3iv/JplRSEEZ83XION15ovw==", + "dev": true, "license": "MIT", "engines": { "node": ">=6" @@ -6084,6 +6863,7 @@ "version": "2.1.0", "resolved": "https://registry.npmjs.org/array-union/-/array-union-2.1.0.tgz", "integrity": "sha512-HGyxoOTYUyCM6stUe6EJgnd4EoewAI7zMdfqO+kGjnlZmBDz/cR5pf8r/cR4Wq60sL/p0IkcjUEEPwS3GFrIyw==", + "dev": true, "license": "MIT", "engines": { "node": ">=8" @@ -9065,6 +9845,7 @@ "version": "1.0.0", "resolved": "https://registry.npmjs.org/better-path-resolve/-/better-path-resolve-1.0.0.tgz", "integrity": "sha512-pbnl5XzGBdrFU/wT4jqmJVPn2B6UHPBOhzMQkY/SPUPB6QtUXtmBHBIwCbXJol93mOpGMnQyP/+BB19q04xj7g==", + "dev": true, "license": "MIT", "dependencies": { "is-windows": "^1.0.0" @@ -9383,6 +10164,7 @@ "version": "2.1.1", "resolved": "https://registry.npmjs.org/chardet/-/chardet-2.1.1.tgz", "integrity": "sha512-PsezH1rqdV9VvyNhxxOW32/d75r01NY7TQCmOqomRo15ZSOKbpTFVsfjghxo6JloQUCGnH4k1LGu0R4yCLlWQQ==", + "dev": true, "license": "MIT" }, "node_modules/check-error": { @@ -9475,6 +10257,7 @@ "version": "3.9.0", "resolved": "https://registry.npmjs.org/ci-info/-/ci-info-3.9.0.tgz", "integrity": "sha512-NIxF55hv4nSqQswkAeiOi1r83xy8JldOFDTWiug55KBu9Jnblncd2U6ViHmYgHf01TPZS77NJBhBMKdWj9HQMQ==", + "dev": true, "funding": [ { "type": "github", @@ -10384,8 +11167,7 @@ "version": "1.0.2", "resolved": "https://registry.npmjs.org/deep-diff/-/deep-diff-1.0.2.tgz", "integrity": "sha512-aWS3UIVH+NPGCD1kki+DCU9Dua032iSsO43LqQpcs4R3+dVv7tX0qBGjiVHJHjplsoUM2XRO/KB92glqc68awg==", - "optional": true, - "peer": true + "dev": true }, "node_modules/deep-eql": { "version": "5.0.2", @@ -10431,6 +11213,7 @@ "version": "6.1.0", "resolved": "https://registry.npmjs.org/detect-indent/-/detect-indent-6.1.0.tgz", "integrity": "sha512-reYkTUJAZb9gUuZ2RvVCNhVHdg62RHnJ7WJl8ftMi4diZ6NWlciOzQN88pUhSELEwflJht4oQDv0F0BMlwaYtA==", + "dev": true, "license": "MIT", "engines": { "node": ">=8" @@ -10503,6 +11286,7 @@ "version": "3.0.1", "resolved": "https://registry.npmjs.org/dir-glob/-/dir-glob-3.0.1.tgz", "integrity": "sha512-WkrWp9GR4KXfKGYzOLmTuGVi1UWFfws377n9cc55/tb6DuqyF6pcQ5AbiHEshaDpY9v6oaSr2XCDidGmMwdzIA==", + "dev": true, "license": "MIT", "dependencies": { "path-type": "^4.0.0" @@ -10684,6 +11468,7 @@ "version": "2.4.1", "resolved": "https://registry.npmjs.org/enquirer/-/enquirer-2.4.1.tgz", "integrity": "sha512-rRqJg/6gd538VHvR3PSrdRBb/1Vy2YfzHqzvbhGIQpDRKIa4FgV/54b5Q1xYSxOOwKvjXweS26E0Q+nAMwp2pQ==", + "dev": true, "license": "MIT", "dependencies": { "ansi-colors": "^4.1.1", @@ -10697,6 +11482,7 @@ "version": "5.0.1", "resolved": "https://registry.npmjs.org/ansi-regex/-/ansi-regex-5.0.1.tgz", "integrity": "sha512-quJQXlTSUGL2LH9SUXo8VwsY4soanhgo6LNSm84E1LBcE8s3O0wpdiRzyR9z/ZZJMlMWv37qOOb9pdJlMUEKFQ==", + "dev": true, "license": "MIT", "engines": { "node": ">=8" @@ -10706,6 +11492,7 @@ "version": "6.0.1", "resolved": "https://registry.npmjs.org/strip-ansi/-/strip-ansi-6.0.1.tgz", "integrity": "sha512-Y38VPSHcqkFrCpFnQ9vuSXmquuv5oXOKpGeT6aGrr3o3Gc9AlVa6JBfUSOCnbxGGZF+/0ooI7KrPuUSztUdU5A==", + "dev": true, "license": "MIT", "dependencies": { "ansi-regex": "^5.0.1" @@ -10824,6 +11611,7 @@ "version": "4.0.1", "resolved": "https://registry.npmjs.org/esprima/-/esprima-4.0.1.tgz", "integrity": "sha512-eGuFFw7Upda+g4p+QHvnW0RyTX/SVeJBDM/gCtMARO0cLuT2HcEKnTPvhjV6aGeqrCB/sbNop0Kszm0jsaWU4A==", + "dev": true, "license": "BSD-2-Clause", "bin": { "esparse": "bin/esparse.js", @@ -10945,6 +11733,7 @@ "version": "0.1.7", "resolved": "https://registry.npmjs.org/extendable-error/-/extendable-error-0.1.7.tgz", "integrity": "sha512-UOiS2in6/Q0FK0R0q6UY9vYpQ21mr/Qn1KOnte7vsACuNJf514WvCCUHSRCPcgjPT2bAhNIJdlE6bVap1GKmeg==", + "dev": true, "license": "MIT" }, "node_modules/fast-deep-equal": { @@ -10958,6 +11747,7 @@ "version": "3.3.3", "resolved": "https://registry.npmjs.org/fast-glob/-/fast-glob-3.3.3.tgz", "integrity": "sha512-7MptL8U0cqcFdzIzwOTHoilX9x5BrNqye7Z/LuC7kCMRio1EMSyqRK3BEAUD7sXRq4iT4AzTVuZdhgQ2TCvYLg==", + "dev": true, "license": "MIT", "dependencies": { "@nodelib/fs.stat": "^2.0.2", @@ -11001,6 +11791,7 @@ "version": "1.19.1", "resolved": "https://registry.npmjs.org/fastq/-/fastq-1.19.1.tgz", "integrity": "sha512-GwLTyxkCXjXbxqIhTsMI2Nui8huMPtnxg7krajPJAjnEG/iiOS7i+zCtWGZR9G0NBKbXKh6X9m9UIsYX/N6vvQ==", + "dev": true, "license": "ISC", "dependencies": { "reusify": "^1.0.4" @@ -11039,6 +11830,7 @@ "version": "4.1.0", "resolved": "https://registry.npmjs.org/find-up/-/find-up-4.1.0.tgz", "integrity": "sha512-PpOwAdQ/YlXQ2vj8a3h8IipDuYRi3wceVQQGYWxNINccq40Anw7BlsEXCMbt1Zt+OLA6Fq9suIpIWD0OsnISlw==", + "dev": true, "license": "MIT", "dependencies": { "locate-path": "^5.0.0", @@ -11147,6 +11939,7 @@ "version": "7.0.1", "resolved": "https://registry.npmjs.org/fs-extra/-/fs-extra-7.0.1.tgz", "integrity": "sha512-YJDaCJZEnBmcbw13fvdAM9AwNOJwOzrE4pqMqBq5nFiEqXUqHwlK4B+3pUw6JNvfSPtX05xFHtYy/1ni01eGCw==", + "dev": true, "license": "MIT", "dependencies": { "graceful-fs": "^4.1.2", @@ -11301,6 +12094,7 @@ "version": "11.1.0", "resolved": "https://registry.npmjs.org/globby/-/globby-11.1.0.tgz", "integrity": "sha512-jhIXaOzy1sb8IyocaruWSn1TjmnBVs8Ayhcy83rmxNJ8q2uWKCAj3CnJY+KpGSXCueAPc0i05kVvVKtP1t9S3g==", + "dev": true, "license": "MIT", "dependencies": { "array-union": "^2.1.0", @@ -11327,6 +12121,7 @@ "version": "4.2.11", "resolved": "https://registry.npmjs.org/graceful-fs/-/graceful-fs-4.2.11.tgz", "integrity": "sha512-RbJ5/jmFcNNCcDV5o9eTnBLJ/HszWV0P73bc+Ff4nS/rJj+YaS6IGyiOL0VoBYX+l1Wrl3k63h/KrH+nhJ0XvQ==", + "dev": true, "license": "ISC" }, "node_modules/graphql": { @@ -11746,6 +12541,7 @@ "version": "4.1.3", "resolved": "https://registry.npmjs.org/human-id/-/human-id-4.1.3.tgz", "integrity": "sha512-tsYlhAYpjCKa//8rXZ9DqKEawhPoSytweBC2eNvcaDK+57RZLHGqNs3PZTQO6yekLFSuvA6AlnAfrw1uBvtb+Q==", + "dev": true, "license": "MIT", "bin": { "human-id": "dist/cli.js" @@ -11774,6 +12570,7 @@ "version": "0.7.1", "resolved": "https://registry.npmjs.org/iconv-lite/-/iconv-lite-0.7.1.tgz", "integrity": "sha512-2Tth85cXwGFHfvRgZWszZSvdo+0Xsqmw8k8ZwxScfcBneNUraK+dxRxRm24nszx80Y0TVio8kKLt5sLE7ZCLlw==", + "dev": true, "license": "MIT", "dependencies": { "safer-buffer": ">= 2.1.2 < 3.0.0" @@ -11790,6 +12587,7 @@ "version": "5.3.2", "resolved": "https://registry.npmjs.org/ignore/-/ignore-5.3.2.tgz", "integrity": "sha512-hsBTNUqQTDwkWtcdYI2i06Y/nUBEsNEDJKjWdigLvegy8kDuJAS8uRlpkkcQpyEXL0Z/pjDy5HBmMjRCJ2gq+g==", + "dev": true, "license": "MIT", "engines": { "node": ">= 4" @@ -12063,6 +12861,7 @@ "version": "1.2.0", "resolved": "https://registry.npmjs.org/is-subdir/-/is-subdir-1.2.0.tgz", "integrity": "sha512-2AT6j+gXe/1ueqbW6fLZJiIw3F8iXGJtt0yDrZaBhAZEG1raiTxKWU+IPqMCzQAXOUCKdA4UDMgacKH25XG2Cw==", + "dev": true, "license": "MIT", "dependencies": { "better-path-resolve": "1.0.0" @@ -12088,6 +12887,7 @@ "version": "1.0.2", "resolved": "https://registry.npmjs.org/is-windows/-/is-windows-1.0.2.tgz", "integrity": "sha512-eXK1UInq2bPmjyX6e3VHIzMLobc4J94i4AWn+Hpq3OU5KkrRC96OAcR3PRJ/pGu6m8TRnBHP9dkXQVsT/COVIA==", + "dev": true, "license": "MIT", "engines": { "node": ">=0.10.0" @@ -12242,6 +13042,7 @@ "version": "4.0.0", "resolved": "https://registry.npmjs.org/jsonfile/-/jsonfile-4.0.0.tgz", "integrity": "sha512-m6F1R3z8jjlf2imQHS2Qez5sjKWQzbuuhuJ/FKYFRZvPE3PuHcSMVZzfsLhGVOkfd20obL5SWEBew5ShlquNxg==", + "dev": true, "license": "MIT", "optionalDependencies": { "graceful-fs": "^4.1.6" @@ -12388,6 +13189,7 @@ "version": "5.0.0", "resolved": "https://registry.npmjs.org/locate-path/-/locate-path-5.0.0.tgz", "integrity": "sha512-t7hw9pI+WvuwNJXwk5zVHpyhIqzg2qTlklJOf0mVxGSbe3Fp2VieZcduNYjaLDoy6p9uGpQEGWG87WpMKlNq8g==", + "dev": true, "license": "MIT", "dependencies": { "p-locate": "^4.1.0" @@ -12412,6 +13214,7 @@ "version": "4.4.0", "resolved": "https://registry.npmjs.org/lodash.startcase/-/lodash.startcase-4.4.0.tgz", "integrity": "sha512-+WKqsK294HMSc2jEbNgpHpd0JfIBhp7rEV4aqXWqFr6AlXov+SlcgB1Fv01y2kGe3Gc8nMW7VA0SrGuSkRfIEg==", + "dev": true, "license": "MIT" }, "node_modules/lodash.throttle": { @@ -12866,6 +13669,7 @@ "version": "1.4.1", "resolved": "https://registry.npmjs.org/merge2/-/merge2-1.4.1.tgz", "integrity": "sha512-8q7VEgMJW4J8tcfVPy8g09NcQwZdbwFEqhe/WZkoIzjn/3TGDwtOCYtXGxA3O8tPzpczCCDgv+P2P5y00ZJOOg==", + "dev": true, "license": "MIT", "engines": { "node": ">= 8" @@ -14134,6 +14938,7 @@ "version": "4.0.8", "resolved": "https://registry.npmjs.org/micromatch/-/micromatch-4.0.8.tgz", "integrity": "sha512-PXwfBhYu0hBCPw8Dn0E+WDYb7af3dSLVWKi3HGv84IdF4TyFoC0ysxFd0Goxw7nSv4T/PzEJQxsYsEiFCKo2BA==", + "dev": true, "license": "MIT", "dependencies": { "braces": "^3.0.3", @@ -14147,6 +14952,7 @@ "version": "2.3.1", "resolved": "https://registry.npmjs.org/picomatch/-/picomatch-2.3.1.tgz", "integrity": "sha512-JU3teHTNjmE2VCGFzuY8EXzCDVwEqB2a8fsIvwaStHhAWJEeVd1o1QD80CU6+ZdEXXSLbSsuLwJjkCBWqRQUVA==", + "dev": true, "engines": { "node": ">=8.6" }, @@ -14627,6 +15433,7 @@ "version": "0.5.0", "resolved": "https://registry.npmjs.org/outdent/-/outdent-0.5.0.tgz", "integrity": "sha512-/jHxFIzoMXdqPzTaCpFzAAWhpkSjZPF4Vsn6jAfNpmbH/ymsmd7Qc6VE9BGn0L6YMj6uwpQLxCECpus4ukKS9Q==", + "dev": true, "license": "MIT" }, "node_modules/outvariant": { @@ -14636,10 +15443,124 @@ "dev": true, "license": "MIT" }, + "node_modules/oxfmt": { + "version": "0.46.0", + "resolved": "https://registry.npmjs.org/oxfmt/-/oxfmt-0.46.0.tgz", + "integrity": "sha512-CopwJOwPAjZ9p76fCvz+mSOJTw9/NY3cSksZK3VO/bUQ8UoEcketNgUuYS0UB3p+R9XnXe7wGGXUmyFxc7QxJA==", + "dev": true, + "license": "MIT", + "dependencies": { + "tinypool": "2.1.0" + }, + "bin": { + "oxfmt": "bin/oxfmt" + }, + "engines": { + "node": "^20.19.0 || >=22.12.0" + }, + "funding": { + "url": "https://github.com/sponsors/Boshen" + }, + "optionalDependencies": { + "@oxfmt/binding-android-arm-eabi": "0.46.0", + "@oxfmt/binding-android-arm64": "0.46.0", + "@oxfmt/binding-darwin-arm64": "0.46.0", + "@oxfmt/binding-darwin-x64": "0.46.0", + "@oxfmt/binding-freebsd-x64": "0.46.0", + "@oxfmt/binding-linux-arm-gnueabihf": "0.46.0", + "@oxfmt/binding-linux-arm-musleabihf": "0.46.0", + "@oxfmt/binding-linux-arm64-gnu": "0.46.0", + "@oxfmt/binding-linux-arm64-musl": "0.46.0", + "@oxfmt/binding-linux-ppc64-gnu": "0.46.0", + "@oxfmt/binding-linux-riscv64-gnu": "0.46.0", + "@oxfmt/binding-linux-riscv64-musl": "0.46.0", + "@oxfmt/binding-linux-s390x-gnu": "0.46.0", + "@oxfmt/binding-linux-x64-gnu": "0.46.0", + "@oxfmt/binding-linux-x64-musl": "0.46.0", + "@oxfmt/binding-openharmony-arm64": "0.46.0", + "@oxfmt/binding-win32-arm64-msvc": "0.46.0", + "@oxfmt/binding-win32-ia32-msvc": "0.46.0", + "@oxfmt/binding-win32-x64-msvc": "0.46.0" + } + }, + "node_modules/oxfmt/node_modules/tinypool": { + "version": "2.1.0", + "resolved": "https://registry.npmjs.org/tinypool/-/tinypool-2.1.0.tgz", + "integrity": "sha512-Pugqs6M0m7Lv1I7FtxN4aoyToKg1C4tu+/381vH35y8oENM/Ai7f7C4StcoK4/+BSw9ebcS8jRiVrORFKCALLw==", + "dev": true, + "license": "MIT", + "engines": { + "node": "^20.0.0 || >=22.0.0" + } + }, + "node_modules/oxlint": { + "version": "1.61.0", + "resolved": "https://registry.npmjs.org/oxlint/-/oxlint-1.61.0.tgz", + "integrity": "sha512-ZC0ALuhDZ6ivOFG+sy0D0pEDN49EvsId98zVlmYdkcXHsEM14m/qTNUEsUpiFiCVbpIxYtVBmmLE87nsbUHohQ==", + "dev": true, + "license": "MIT", + "bin": { + "oxlint": "bin/oxlint" + }, + "engines": { + "node": "^20.19.0 || >=22.12.0" + }, + "funding": { + "url": "https://github.com/sponsors/Boshen" + }, + "optionalDependencies": { + "@oxlint/binding-android-arm-eabi": "1.61.0", + "@oxlint/binding-android-arm64": "1.61.0", + "@oxlint/binding-darwin-arm64": "1.61.0", + "@oxlint/binding-darwin-x64": "1.61.0", + "@oxlint/binding-freebsd-x64": "1.61.0", + "@oxlint/binding-linux-arm-gnueabihf": "1.61.0", + "@oxlint/binding-linux-arm-musleabihf": "1.61.0", + "@oxlint/binding-linux-arm64-gnu": "1.61.0", + "@oxlint/binding-linux-arm64-musl": "1.61.0", + "@oxlint/binding-linux-ppc64-gnu": "1.61.0", + "@oxlint/binding-linux-riscv64-gnu": "1.61.0", + "@oxlint/binding-linux-riscv64-musl": "1.61.0", + "@oxlint/binding-linux-s390x-gnu": "1.61.0", + "@oxlint/binding-linux-x64-gnu": "1.61.0", + "@oxlint/binding-linux-x64-musl": "1.61.0", + "@oxlint/binding-openharmony-arm64": "1.61.0", + "@oxlint/binding-win32-arm64-msvc": "1.61.0", + "@oxlint/binding-win32-ia32-msvc": "1.61.0", + "@oxlint/binding-win32-x64-msvc": "1.61.0" + }, + "peerDependencies": { + "oxlint-tsgolint": ">=0.18.0" + }, + "peerDependenciesMeta": { + "oxlint-tsgolint": { + "optional": true + } + } + }, + "node_modules/oxlint-tsgolint": { + "version": "0.21.1", + "resolved": "https://registry.npmjs.org/oxlint-tsgolint/-/oxlint-tsgolint-0.21.1.tgz", + "integrity": "sha512-O2hxiT14C2HJkwzBU6CQBFPoagSd/IcV+Tt3e3UUaXFwbW4BO5DSDPSSboc3UM5MIDY+MLyepvtQwBQafNxWdw==", + "dev": true, + "license": "MIT", + "bin": { + "tsgolint": "bin/tsgolint.js" + }, + "optionalDependencies": { + "@oxlint-tsgolint/darwin-arm64": "0.21.1", + "@oxlint-tsgolint/darwin-x64": "0.21.1", + "@oxlint-tsgolint/linux-arm64": "0.21.1", + "@oxlint-tsgolint/linux-x64": "0.21.1", + "@oxlint-tsgolint/win32-arm64": "0.21.1", + "@oxlint-tsgolint/win32-x64": "0.21.1" + } + }, "node_modules/p-filter": { "version": "2.1.0", "resolved": "https://registry.npmjs.org/p-filter/-/p-filter-2.1.0.tgz", "integrity": "sha512-ZBxxZ5sL2HghephhpGAQdoskxplTwr7ICaehZwLIlfL6acuVgZPm8yBNuRAFBGEqtD/hmUeq9eqLg2ys9Xr/yw==", + "dev": true, "license": "MIT", "dependencies": { "p-map": "^2.0.0" @@ -14652,6 +15573,7 @@ "version": "2.3.0", "resolved": "https://registry.npmjs.org/p-limit/-/p-limit-2.3.0.tgz", "integrity": "sha512-//88mFWSJx8lxCzwdAABTJL2MyWB12+eIY7MDL2SqLmAkeKU9qxRvWuSyTjm3FUmpBEMuFfckAIqEaVGUDxb6w==", + "dev": true, "license": "MIT", "dependencies": { "p-try": "^2.0.0" @@ -14667,6 +15589,7 @@ "version": "4.1.0", "resolved": "https://registry.npmjs.org/p-locate/-/p-locate-4.1.0.tgz", "integrity": "sha512-R79ZZ/0wAxKGu3oYMlz8jy/kbhsNrS7SKZ7PxEHBgJ5+F2mtFW2fK2cOtBh1cHYkQsbzFV7I+EoRKe6Yt0oK7A==", + "dev": true, "license": "MIT", "dependencies": { "p-limit": "^2.2.0" @@ -14679,6 +15602,7 @@ "version": "2.3.0", "resolved": "https://registry.npmjs.org/p-limit/-/p-limit-2.3.0.tgz", "integrity": "sha512-//88mFWSJx8lxCzwdAABTJL2MyWB12+eIY7MDL2SqLmAkeKU9qxRvWuSyTjm3FUmpBEMuFfckAIqEaVGUDxb6w==", + "dev": true, "dependencies": { "p-try": "^2.0.0" }, @@ -14693,6 +15617,7 @@ "version": "2.1.0", "resolved": "https://registry.npmjs.org/p-map/-/p-map-2.1.0.tgz", "integrity": "sha512-y3b8Kpd8OAN444hxfBbFfj1FY/RjtTd8tzYwhUqNYXx0fXx2iX4maP4Qr6qhIKbQXI02wTLAda4fYUbDagTUFw==", + "dev": true, "license": "MIT", "engines": { "node": ">=6" @@ -14730,6 +15655,7 @@ "version": "2.2.0", "resolved": "https://registry.npmjs.org/p-try/-/p-try-2.2.0.tgz", "integrity": "sha512-R4nPAVTAU0B9D35/Gk3uJf/7XYbQcyohSKdvAxIRSNghFl4e71hVoGnBNQz9cWaXxO2I10KTC+3jMdvvoKw6dQ==", + "dev": true, "license": "MIT", "engines": { "node": ">=6" @@ -14739,6 +15665,7 @@ "version": "0.2.11", "resolved": "https://registry.npmjs.org/package-manager-detector/-/package-manager-detector-0.2.11.tgz", "integrity": "sha512-BEnLolu+yuz22S56CU1SUKq3XC3PkwD5wv4ikR4MfGvnRVcmzXR9DwSlW2fEamyTPyXHomBJRzgapeuBvRNzJQ==", + "dev": true, "license": "MIT", "dependencies": { "quansync": "^0.2.7" @@ -14854,6 +15781,7 @@ "version": "4.0.0", "resolved": "https://registry.npmjs.org/path-exists/-/path-exists-4.0.0.tgz", "integrity": "sha512-ak9Qy5Q7jYb2Wwcey5Fpvg2KoAc/ZIhLSLOSBmRmygPsGwkVVt0fZa0qrtMz+m6tJTAHfZQ8FnmB4MG4LWy7/w==", + "dev": true, "license": "MIT", "engines": { "node": ">=8" @@ -14906,6 +15834,7 @@ "version": "4.0.0", "resolved": "https://registry.npmjs.org/path-type/-/path-type-4.0.0.tgz", "integrity": "sha512-gDKb8aZMDeD/tZWs9P6+q0J9Mwkdl6xMV8TjnGP3qJVJ06bdMgkbBlLU8IdfOsIsFz2BW1rNVT3XuNEl8zPAvw==", + "dev": true, "license": "MIT", "engines": { "node": ">=8" @@ -14974,6 +15903,7 @@ "version": "4.0.1", "resolved": "https://registry.npmjs.org/pify/-/pify-4.0.1.tgz", "integrity": "sha512-uB80kBFb/tfd68bVleG9T5GGsGPjJrLAUpR5PZIrhBnIaRTQRjqdJSsIKkOP6OAIFbj7GOrcudc5pNjZ+geV2g==", + "dev": true, "license": "MIT", "engines": { "node": ">=6" @@ -15204,20 +16134,36 @@ } }, "node_modules/prettier": { - "version": "2.8.8", - "resolved": "https://registry.npmjs.org/prettier/-/prettier-2.8.8.tgz", - "integrity": "sha512-tdN8qQGvNjw4CHbY+XXk0JgCXn9QiF21a55rBe5LJAU+kDyC4WQn4+awm2Xfk2lQMk5fKup9XgzTZtGkjBdP9Q==", + "version": "3.8.3", + "resolved": "https://registry.npmjs.org/prettier/-/prettier-3.8.3.tgz", + "integrity": "sha512-7igPTM53cGHMW8xWuVTydi2KO233VFiTNyF5hLJqpilHfmn8C8gPf+PS7dUT64YcXFbiMGZxS9pCSxL/Dxm/Jw==", + "dev": true, "license": "MIT", "bin": { - "prettier": "bin-prettier.js" + "prettier": "bin/prettier.cjs" }, "engines": { - "node": ">=10.13.0" + "node": ">=14" }, "funding": { "url": "https://github.com/prettier/prettier?sponsor=1" } }, + "node_modules/prettier-plugin-astro": { + "version": "0.14.1", + "resolved": "https://registry.npmjs.org/prettier-plugin-astro/-/prettier-plugin-astro-0.14.1.tgz", + "integrity": "sha512-RiBETaaP9veVstE4vUwSIcdATj6dKmXljouXc/DDNwBSPTp8FRkLGDSGFClKsAFeeg+13SB0Z1JZvbD76bigJw==", + "dev": true, + "license": "MIT", + "dependencies": { + "@astrojs/compiler": "^2.9.1", + "prettier": "^3.0.0", + "sass-formatter": "^0.7.6" + }, + "engines": { + "node": "^14.15.0 || >=16.0.0" + } + }, "node_modules/prismjs": { "version": "1.30.0", "resolved": "https://registry.npmjs.org/prismjs/-/prismjs-1.30.0.tgz", @@ -15269,6 +16215,7 @@ "version": "0.2.11", "resolved": "https://registry.npmjs.org/quansync/-/quansync-0.2.11.tgz", "integrity": "sha512-AifT7QEbW9Nri4tAwR5M/uzpBuqfZf+zwaEM/QkzEjj7NBuFD2rBuy0K3dE+8wltbezDV7JMA0WfnCPYRSYbXA==", + "dev": true, "funding": [ { "type": "individual", @@ -15285,6 +16232,7 @@ "version": "1.2.3", "resolved": "https://registry.npmjs.org/queue-microtask/-/queue-microtask-1.2.3.tgz", "integrity": "sha512-NuaNSa6flKT5JaSYQzJok04JzTL1CA6aGhv5rfLW3PgqA+M2ChpZQnAC8h8i4ZFkBS8X5RqkDBHA7r4hej3K9A==", + "dev": true, "funding": [ { "type": "github", @@ -15407,6 +16355,7 @@ "version": "1.1.0", "resolved": "https://registry.npmjs.org/read-yaml-file/-/read-yaml-file-1.1.0.tgz", "integrity": "sha512-VIMnQi/Z4HT2Fxuwg5KrY174U1VdUIASQVWXXyqtNRtxSr9IYkn1rsI6Tb6HsrHCmB7gVpNwX6JxPTHcH6IoTA==", + "dev": true, "license": "MIT", "dependencies": { "graceful-fs": "^4.1.5", @@ -15422,6 +16371,7 @@ "version": "1.0.10", "resolved": "https://registry.npmjs.org/argparse/-/argparse-1.0.10.tgz", "integrity": "sha512-o5Roy6tNG4SL/FOkCAN6RzjiakZS25RLYFrcMttJqbdd8BWrnA+fGz57iN5Pb06pvBGvl5gQ0B48dJlslXvoTg==", + "dev": true, "license": "MIT", "dependencies": { "sprintf-js": "~1.0.2" @@ -15431,6 +16381,7 @@ "version": "3.14.2", "resolved": "https://registry.npmjs.org/js-yaml/-/js-yaml-3.14.2.tgz", "integrity": "sha512-PMSmkqxr106Xa156c2M265Z+FTrPl+oxd/rgOQy2tijQeK5TxQ43psO1ZCwhVOSdnn+RzkzlRz/eY4BgJBYVpg==", + "dev": true, "license": "MIT", "dependencies": { "argparse": "^1.0.7", @@ -15668,6 +16619,7 @@ "version": "5.0.0", "resolved": "https://registry.npmjs.org/resolve-from/-/resolve-from-5.0.0.tgz", "integrity": "sha512-qYg9KP24dD5qka9J47d0aVky0N+b4fTU89LN9iDnjB5waksiC49rvMB0PrUJQGoTmH50XPiqOvAjDfaijGxYZw==", + "dev": true, "license": "MIT", "engines": { "node": ">=8" @@ -15778,6 +16730,7 @@ "version": "1.1.0", "resolved": "https://registry.npmjs.org/reusify/-/reusify-1.1.0.tgz", "integrity": "sha512-g6QUff04oZpHs0eG5p83rFLhHeV00ug/Yf9nZM6fLeUrPguBTkTQOdpAWWspMh55TZfVQDPaN3NQJfbVRAxdIw==", + "dev": true, "license": "MIT", "engines": { "iojs": ">=1.0.0", @@ -15930,6 +16883,7 @@ "version": "1.2.0", "resolved": "https://registry.npmjs.org/run-parallel/-/run-parallel-1.2.0.tgz", "integrity": "sha512-5l4VyZR86LZ/lDxZTR6jqL8AFE2S0IFLMP26AbjsLVADxHdhB/c0GUsH+y39UfCi3dzz8OlQuPmnaJOMoDHQBA==", + "dev": true, "funding": [ { "type": "github", @@ -15955,6 +16909,13 @@ "integrity": "sha512-PdhdWy89SiZogBLaw42zdeqtRJ//zFd2PgQavcICDUgJT5oW10QCRKbJ6bg4r0/UY2M6BWd5tkxuGFRvCkgfHQ==", "license": "BSD-3-Clause" }, + "node_modules/s.color": { + "version": "0.0.15", + "resolved": "https://registry.npmjs.org/s.color/-/s.color-0.0.15.tgz", + "integrity": "sha512-AUNrbEUHeKY8XsYr/DYpl+qk5+aM+DChopnWOPEzn8YKzOhv4l2zH6LzZms3tOZP3wwdOyc0RmTciyi46HLIuA==", + "dev": true, + "license": "MIT" + }, "node_modules/sade": { "version": "1.8.1", "resolved": "https://registry.npmjs.org/sade/-/sade-1.8.1.tgz", @@ -15990,6 +16951,16 @@ "node": ">=12.0.0" } }, + "node_modules/sass-formatter": { + "version": "0.7.9", + "resolved": "https://registry.npmjs.org/sass-formatter/-/sass-formatter-0.7.9.tgz", + "integrity": "sha512-CWZ8XiSim+fJVG0cFLStwDvft1VI7uvXdCNJYXhDvowiv+DsbD1nXLiQ4zrE5UBvj5DWZJ93cwN0NX5PMsr1Pw==", + "dev": true, + "license": "MIT", + "dependencies": { + "suf-log": "^2.5.3" + } + }, "node_modules/sass/node_modules/chokidar": { "version": "3.6.0", "resolved": "https://registry.npmjs.org/chokidar/-/chokidar-3.6.0.tgz", @@ -16203,6 +17174,7 @@ "version": "3.0.0", "resolved": "https://registry.npmjs.org/slash/-/slash-3.0.0.tgz", "integrity": "sha512-g9Q1haeby36OSStwb4ntCGGGaKsaVSjQ68fBxoQcutl5fS1vuY18H3wSt3jFyFtrkx+Kz0V1G85A4MyAdDMi2Q==", + "dev": true, "license": "MIT", "engines": { "node": ">=8" @@ -16265,6 +17237,7 @@ "version": "3.0.1", "resolved": "https://registry.npmjs.org/spawndamnit/-/spawndamnit-3.0.1.tgz", "integrity": "sha512-MmnduQUuHCoFckZoWnXsTg7JaiLBJrKFj9UI2MbRPGaJeVpsLcVBu6P/IGZovziM/YBsellCmsprgNA+w0CzVg==", + "dev": true, "license": "SEE LICENSE IN LICENSE", "dependencies": { "cross-spawn": "^7.0.5", @@ -16275,6 +17248,7 @@ "version": "1.0.3", "resolved": "https://registry.npmjs.org/sprintf-js/-/sprintf-js-1.0.3.tgz", "integrity": "sha512-D9cPgkvLlV3t3IzL0D0YLvGA9Ahk4PcvVwUbN0dSGr1aP0Nrt4AEnTUbuGvquEC0mA64Gqt1fzirlRs5ibXx8g==", + "dev": true, "license": "BSD-3-Clause" }, "node_modules/stackback": { @@ -16365,6 +17339,7 @@ "version": "3.0.0", "resolved": "https://registry.npmjs.org/strip-bom/-/strip-bom-3.0.0.tgz", "integrity": "sha512-vavAMRXOgBVNF6nyEEmL3DBK19iRpDcoIwW+swQ+CbGiu7lju6t+JklA1MHweoWtadgt4ISVUsXLyDq34ddcwA==", + "dev": true, "license": "MIT", "engines": { "node": ">=4" @@ -16451,6 +17426,16 @@ "node": ">= 6" } }, + "node_modules/suf-log": { + "version": "2.5.3", + "resolved": "https://registry.npmjs.org/suf-log/-/suf-log-2.5.3.tgz", + "integrity": "sha512-KvC8OPjzdNOe+xQ4XWJV2whQA0aM1kGVczMQ8+dStAO6KfEB140JEVQ9dE76ONZ0/Ylf67ni4tILPJB41U0eow==", + "dev": true, + "license": "MIT", + "dependencies": { + "s.color": "0.0.15" + } + }, "node_modules/svgo": { "version": "4.0.0", "resolved": "https://registry.npmjs.org/svgo/-/svgo-4.0.0.tgz", @@ -16514,6 +17499,7 @@ "version": "2.2.1", "resolved": "https://registry.npmjs.org/term-size/-/term-size-2.2.1.tgz", "integrity": "sha512-wK0Ri4fOGjv/XPy8SBHZChl8CM7uMc5VML7SqiQ0zG7+J5Vr+RMQDoHa2CNT6KHUnTGIXH34UDMkPzAUyapBZg==", + "dev": true, "license": "MIT", "engines": { "node": ">=8" @@ -17427,6 +18413,7 @@ "version": "0.1.2", "resolved": "https://registry.npmjs.org/universalify/-/universalify-0.1.2.tgz", "integrity": "sha512-rBJeI5CXAlmy1pV+617WB9J63U6XcazHHF2f2dbJix4XzpUF0RS3Zbj0FGIOCAva5P/d/GBOYaACQ1w+0azUkg==", + "dev": true, "license": "MIT", "engines": { "node": ">= 4.0.0" @@ -18750,7 +19737,8 @@ "remark": "^15.0.1", "tsup": "^8.1.0", "typescript": "^5.5.2", - "unified": "^11.0.4" + "unified": "^11.0.4", + "vitest": "^3.0.5" } }, "remark-excalidraw": { diff --git a/package.json b/package.json index 671e4f1..472c9cb 100644 --- a/package.json +++ b/package.json @@ -1,17 +1,29 @@ { "name": "fujocoded-plugins", "private": true, - "scripts": { - "build": "npm run build --workspaces --if-present", - "release": "npm run build && changeset publish --provenance", - "sherif": "npx sherif@latest" - }, "workspaces": [ "*/", "!.*/" ], - "packageManager": "npm@11.5.1", - "dependencies": { - "@changesets/cli": "^2.29.8" - } + "type": "module", + "scripts": { + "build": "npm run build --workspaces --if-present", + "typecheck": "npm run typecheck --workspaces --if-present", + "release": "npm run build && changeset publish --provenance", + "sherif": "npx sherif@latest --ignore-rule non-existant-packages --fail-on-warnings", + "lint": "oxlint --type-aware", + "lint:fix": "oxlint --type-aware --fix", + "lint:ci": "oxlint --type-aware --deny-warnings", + "format": "oxfmt && prettier --write \"**/*.astro\"", + "format:check": "oxfmt --check && prettier --check \"**/*.astro\"" + }, + "devDependencies": { + "@changesets/cli": "^2.29.8", + "oxfmt": "^0.46.0", + "oxlint": "^1.61.0", + "oxlint-tsgolint": "^0.21.1", + "prettier": "^3.8.3", + "prettier-plugin-astro": "^0.14.1" + }, + "packageManager": "npm@11.5.1" } diff --git a/prettier.config.ts b/prettier.config.ts new file mode 100644 index 0000000..c49baea --- /dev/null +++ b/prettier.config.ts @@ -0,0 +1,8 @@ +import type { Config } from "prettier"; + +const config: Config = { + plugins: ["prettier-plugin-astro"], + overrides: [{ files: "*.astro", options: { parser: "astro" } }], +}; + +export default config; diff --git a/rehype-code-params/index.ts b/rehype-code-params/index.ts index f4d9f73..0ad3157 100644 --- a/rehype-code-params/index.ts +++ b/rehype-code-params/index.ts @@ -13,9 +13,9 @@ const PARAMETER_REGEX = /(\[[a-z0-9_\- ]+\])/gi; const isCodeWithSingleText = < T extends hast.Element & { children: [hast.Text]; - } + }, >( - node: hast.Node + node: hast.Node, ): node is T => { return ( isElement(node) && @@ -28,7 +28,7 @@ const isCodeWithSingleText = < export const rehypeCodeParams: Plugin< PluginArgs[], hast.Root -> = ({}: PluginArgs = {}): Transformer => { +> = (): Transformer => { return (tree) => { return visit( tree, @@ -63,8 +63,7 @@ export const rehypeCodeParams: Plugin< // @ts-expect-error We narrowed the type of children with isCodeWithSingleText, but newChildren is valid here. node.children = newChildren; - } + }, ); }; - ``; }; diff --git a/rehype-code-params/package.json b/rehype-code-params/package.json index 7d1f05e..89ff278 100644 --- a/rehype-code-params/package.json +++ b/rehype-code-params/package.json @@ -1,8 +1,23 @@ { "name": "@fujocoded/rehype-code-params", - "type": "module", "version": "0.0.5", "description": "Make params stylable in code commands", + "keywords": [ + "remark" + ], + "license": "MIT", + "author": "FujoCoded LLC", + "repository": { + "type": "git", + "url": "git+https://github.com/FujoWebDev/fujocoded-plugins.git" + }, + "files": [ + "dist", + "LICENSE", + "README.md", + "package.json" + ], + "type": "module", "main": "dist/index.cjs", "module": "dist/index.js", "exports": { @@ -17,24 +32,13 @@ } } }, - "files": [ - "dist", - "LICENSE", - "README.md", - "package.json" - ], + "publishConfig": { + "access": "public" + }, "scripts": { "build": "tsup index.ts --format cjs,esm --dts --clean", - "validate": " npx publint" - }, - "keywords": [ - "remark" - ], - "author": "FujoCoded LLC", - "license": "MIT", - "repository": { - "type": "git", - "url": "git+https://github.com/FujoWebDev/fujocoded-plugins.git" + "validate": " npx publint", + "typecheck": "tsc --noEmit" }, "dependencies": { "hastscript": "^9.0.0", @@ -48,8 +52,5 @@ "tsup": "^8.1.0", "typescript": "^5.5.2", "unified": "^11.0.4" - }, - "publishConfig": { - "access": "public" } } diff --git a/remark-alt-text-files/index.ts b/remark-alt-text-files/index.ts index 80c302d..91aa90a 100644 --- a/remark-alt-text-files/index.ts +++ b/remark-alt-text-files/index.ts @@ -33,9 +33,9 @@ const getFilePath = ({ options.root ? options.root : vfile.history[0] - ? dirname(vfile.history[0]) - : process.cwd(), - filePath + ? dirname(vfile.history[0]) + : process.cwd(), + filePath, ); }; @@ -55,10 +55,10 @@ const plugin: Plugin = options: { pathPrefix, root }, }); loadingAltText.push( - readFile(filePath, "utf8").then((text) => (node.alt = text.trim())) + readFile(filePath, "utf8").then((text) => (node.alt = text.trim())), ); loadingAltFiles.push( - `${node.alt.replace(pathPrefix, "")} (as ${filePath})` + `${node.alt.replace(pathPrefix, "")} (as ${filePath})`, ); }); @@ -71,10 +71,10 @@ const plugin: Plugin = throw new Error( `Failed to load alt text from files: ${results .map((result, index) => - result.status === "rejected" ? loadingAltFiles[index] : null + result.status === "rejected" ? loadingAltFiles[index] : null, ) .filter((file) => file !== null) - .join(", ")}` + .join(", ")}`, ); }; diff --git a/remark-alt-text-files/package.json b/remark-alt-text-files/package.json index d620fab..970b9d1 100644 --- a/remark-alt-text-files/package.json +++ b/remark-alt-text-files/package.json @@ -2,10 +2,29 @@ "name": "@fujocoded/remark-alt-text-files", "version": "0.0.2", "description": "Add alt text to your images directly from your filesystem", + "keywords": [ + "accessibility", + "remark" + ], + "homepage": "https://github.com/FujoWebDev/fujocoded-plugins#readme", + "bugs": { + "url": "https://github.com/FujoWebDev/fujocoded-plugins/issues" + }, + "license": "MIT", + "author": "FujoCoded LLC", + "repository": { + "type": "git", + "url": "git+https://github.com/FujoWebDev/fujocoded-plugins.git" + }, + "files": [ + "dist", + "LICENSE", + "README.md", + "package.json" + ], "type": "module", "main": "dist/index.cjs", "module": "dist/index.js", - "prefix": "./", "exports": { ".": { "import": { @@ -18,34 +37,15 @@ } } }, - "files": [ - "dist", - "LICENSE", - "README.md", - "package.json" - ], "publishConfig": { "access": "public" }, "scripts": { "build": "tsup index.ts --format cjs,esm --dts --clean", "validate": " npx publint", - "test": "vitest" - }, - "repository": { - "type": "git", - "url": "git+https://github.com/FujoWebDev/fujocoded-plugins.git" + "test": "vitest", + "typecheck": "tsc --noEmit" }, - "keywords": [ - "remark", - "accessibility" - ], - "author": "FujoCoded LLC", - "license": "MIT", - "bugs": { - "url": "https://github.com/FujoWebDev/fujocoded-plugins/issues" - }, - "homepage": "https://github.com/FujoWebDev/fujocoded-plugins#readme", "dependencies": { "unist-util-visit": "^5.0.0" }, @@ -54,5 +54,6 @@ "remark": "^15.0.1", "tsup": "^8.3.6", "vitest": "^3.0.5" - } + }, + "prefix": "./" } diff --git a/remark-alt-text-files/tests/index.test.ts b/remark-alt-text-files/tests/index.test.ts index c64bef2..79718e7 100644 --- a/remark-alt-text-files/tests/index.test.ts +++ b/remark-alt-text-files/tests/index.test.ts @@ -38,7 +38,7 @@ beforeEach(() => { "./root/directory/path/to/image.alt.txt": "This is the alt text for /path/to/image.png, relative to root/directory", }, - process.cwd() + process.cwd(), ); }); @@ -84,7 +84,7 @@ test("should load specific file when path is provided, from given root", async ( ![file:./path/to/image.alt.txt](/path/to/image.png)`, { root: `${process.cwd()}/root/directory`, - } + }, ); expect(result).toBe(`# Hello, world! @@ -107,9 +107,9 @@ test("should fail when file does not exist", async () => { async () => await processMarkdown(`# Hello, world! - ![file:does-not-exist.txt](/path/to/image.png)`) + ![file:does-not-exist.txt](/path/to/image.png)`), ).rejects.toThrowError( - `Failed to load alt text from files: does-not-exist.txt (as ${process.cwd()}/does-not-exist.txt)` + `Failed to load alt text from files: does-not-exist.txt (as ${process.cwd()}/does-not-exist.txt)`, ); }); diff --git a/remark-capitalize-titles/index.ts b/remark-capitalize-titles/index.ts index 0d7c1ec..9269428 100644 --- a/remark-capitalize-titles/index.ts +++ b/remark-capitalize-titles/index.ts @@ -18,14 +18,14 @@ const title = (...params: Parameters) => { type PluginArgs = { special: string[]; componentNames: string[] }; // We match command parameters of the form --flag [parameter_name] -const CODE_REGEX = /(\`[a-z0-9_\-\s]+\`)/gi; +const CODE_REGEX = /(`[a-z0-9_\-\s]+`)/gi; const plugin: Plugin = ( - { special, componentNames = [] }: PluginArgs = { + { special, componentNames }: PluginArgs = { special: DEFAULT_CAPITALIZATIONS_, componentNames: [], - } + }, ) => (tree) => { visit(tree, "heading", (node) => { @@ -45,14 +45,14 @@ const plugin: Plugin = }, (node) => { const titleAttribute = node.attributes.find( - (attribute) => "name" in attribute && attribute.name == "title" + (attribute) => "name" in attribute && attribute.name == "title", ); if (titleAttribute) { const titleWithSplitCode = (titleAttribute.value as string).split( - new RegExp(CODE_REGEX) + new RegExp(CODE_REGEX), ); titleAttribute.value = titleWithSplitCode - .map((part, index) => { + .map((part) => { if (part.startsWith("`") && part.endsWith("`")) { return part; // } else if (index > 0) { @@ -69,7 +69,7 @@ const plugin: Plugin = }) .join(""); } - } + }, ); } }; diff --git a/remark-capitalize-titles/package.json b/remark-capitalize-titles/package.json index f5b7d61..17983e4 100644 --- a/remark-capitalize-titles/package.json +++ b/remark-capitalize-titles/package.json @@ -1,8 +1,23 @@ { "name": "@fujocoded/remark-capitalize-titles", - "type": "module", "version": "0.0.13", "description": "Make titles consistent with remark", + "keywords": [ + "remark" + ], + "license": "MIT", + "author": "FujoCoded LLC", + "repository": { + "type": "git", + "url": "git+https://github.com/FujoWebDev/fujocoded-plugins.git" + }, + "files": [ + "dist", + "LICENSE", + "README.md", + "package.json" + ], + "type": "module", "main": "dist/index.cjs", "module": "dist/index.js", "exports": { @@ -17,24 +32,13 @@ } } }, - "files": [ - "dist", - "LICENSE", - "README.md", - "package.json" - ], + "publishConfig": { + "access": "public" + }, "scripts": { "build": "tsup index.ts --format cjs,esm --dts --clean", - "validate": " npx publint" - }, - "keywords": [ - "remark" - ], - "author": "FujoCoded LLC", - "license": "MIT", - "repository": { - "type": "git", - "url": "git+https://github.com/FujoWebDev/fujocoded-plugins.git" + "validate": " npx publint", + "typecheck": "tsc --noEmit" }, "dependencies": { "title": "^4.0.1", @@ -48,8 +52,5 @@ "tsup": "^8.1.0", "typescript": "^5.5.2", "unified": "^11.0.4" - }, - "publishConfig": { - "access": "public" } } diff --git a/remark-excalidraw/__example__/astro.config.mjs b/remark-excalidraw/__example__/astro.config.mjs index 763b564..6134ff8 100644 --- a/remark-excalidraw/__example__/astro.config.mjs +++ b/remark-excalidraw/__example__/astro.config.mjs @@ -13,7 +13,10 @@ export default defineConfig({ mode: "standalone", }), - integrations: [mdx({ - remarkPlugins: [remarkExcalidraw], - }), react()], -}); \ No newline at end of file + integrations: [ + mdx({ + remarkPlugins: [remarkExcalidraw], + }), + react(), + ], +}); diff --git a/remark-excalidraw/__example__/package.json b/remark-excalidraw/__example__/package.json index 43d24fe..55a73a8 100644 --- a/remark-excalidraw/__example__/package.json +++ b/remark-excalidraw/__example__/package.json @@ -1,8 +1,8 @@ { "name": "example", - "type": "module", "version": "0.0.1", "private": "true", + "type": "module", "scripts": { "dev": "astro dev", "build": "astro build", diff --git a/remark-excalidraw/__example__/tsconfig.json b/remark-excalidraw/__example__/tsconfig.json index 69c1600..92a18df 100644 --- a/remark-excalidraw/__example__/tsconfig.json +++ b/remark-excalidraw/__example__/tsconfig.json @@ -1,14 +1,9 @@ { "extends": "astro/tsconfigs/strict", - "include": [ - ".astro/types.d.ts", - "**/*" - ], - "exclude": [ - "dist" - ], + "include": [".astro/types.d.ts", "**/*"], + "exclude": ["dist"], "compilerOptions": { "jsx": "react-jsx", "jsxImportSource": "react" } -} \ No newline at end of file +} diff --git a/remark-excalidraw/index.ts b/remark-excalidraw/index.ts index f0375f6..bfcf346 100644 --- a/remark-excalidraw/index.ts +++ b/remark-excalidraw/index.ts @@ -1,8 +1,7 @@ import { visitParents } from "unist-util-visit-parents"; import type { Plugin } from "unified"; import { readFile } from "node:fs/promises"; -import path, { join, dirname } from "node:path"; -import { exportToSvg } from "@excalidraw/excalidraw"; +import path, { dirname } from "node:path"; import type mdast from "mdast"; @@ -53,17 +52,17 @@ const plugin: Plugin = () => async (tree, vfile) => { ? dirname(vfile.history[0]) : process.cwd(); loadingFilePromises.push( - readFile(path.join(rootPath, node.url), "utf-8") + readFile(path.join(rootPath, node.url), "utf-8"), ); attributeNodes.push(contentAttribute); - } + }, ); const fileContents = await Promise.all(loadingFilePromises); await Promise.all( fileContents.map(async (fileContent, index) => { attributeNodes[index]!.value = fileContent; - }) + }), ); if (fileContents.length > 0) { diff --git a/remark-excalidraw/package.json b/remark-excalidraw/package.json index 3e3f5cd..04bda72 100644 --- a/remark-excalidraw/package.json +++ b/remark-excalidraw/package.json @@ -2,10 +2,29 @@ "name": "@fujocoded/remark-excalidraw", "version": "0.0.2", "description": "Load excalidraw diagrams via remark", + "keywords": [ + "excalidraw", + "remark" + ], + "homepage": "https://github.com/FujoWebDev/fujocoded-plugins#readme", + "bugs": { + "url": "https://github.com/FujoWebDev/fujocoded-plugins/issues" + }, + "license": "MIT", + "author": "FujoCoded, LLC", + "repository": { + "type": "git", + "url": "git+https://github.com/FujoWebDev/fujocoded-plugins.git" + }, + "files": [ + "dist", + "LICENSE", + "README.md", + "package.json" + ], "type": "module", "main": "dist/index.cjs", "module": "dist/index.js", - "prefix": "./", "exports": { ".": { "import": { @@ -28,12 +47,6 @@ } } }, - "files": [ - "dist", - "LICENSE", - "README.md", - "package.json" - ], "publishConfig": { "access": "public" }, @@ -42,22 +55,9 @@ "build:component": "tsup component.tsx --format cjs,esm --dts --external react", "validate": " npx publint", "test": "vitest", - "publish:patch": "npm run build && npm run build:component && npm version patch && npm publish" - }, - "repository": { - "type": "git", - "url": "git+https://github.com/FujoWebDev/fujocoded-plugins.git" + "publish:patch": "npm run build && npm run build:component && npm version patch && npm publish", + "typecheck": "tsc --noEmit" }, - "keywords": [ - "remark", - "excalidraw" - ], - "author": "FujoCoded, LLC", - "license": "MIT", - "bugs": { - "url": "https://github.com/FujoWebDev/fujocoded-plugins/issues" - }, - "homepage": "https://github.com/FujoWebDev/fujocoded-plugins#readme", "dependencies": { "@excalidraw/excalidraw": "^0.18.0", "unist-util-visit-parents": "^6.0.1" @@ -68,5 +68,6 @@ "remark-mdx": "^3.1.0", "tsup": "^8.3.6", "vitest": "^3.0.5" - } + }, + "prefix": "./" } diff --git a/remark-excalidraw/tests/index.test.ts b/remark-excalidraw/tests/index.test.ts index a31f95d..f56713c 100644 --- a/remark-excalidraw/tests/index.test.ts +++ b/remark-excalidraw/tests/index.test.ts @@ -23,7 +23,7 @@ beforeEach(() => { { "./tests/test-image.excalidraw": `{ image: excalidraw }`, }, - process.cwd() + process.cwd(), ); }); diff --git a/remark-excalidraw/tsconfig.json b/remark-excalidraw/tsconfig.json index 1c639f8..9b64e5b 100644 --- a/remark-excalidraw/tsconfig.json +++ b/remark-excalidraw/tsconfig.json @@ -21,5 +21,13 @@ "noEmit": true, "jsx": "react-jsx", "types": ["remark-mdx", "node"] - } + }, + "include": ["**/*.ts", "**/*.tsx"], + "exclude": [ + "node_modules", + "dist", + "__example__", + "__examples__", + "__tests__" + ] } diff --git a/remark-jsx-auto-slug/index.ts b/remark-jsx-auto-slug/index.ts index 0629f1c..8a8ad4f 100644 --- a/remark-jsx-auto-slug/index.ts +++ b/remark-jsx-auto-slug/index.ts @@ -26,7 +26,7 @@ export const remarkJsxAutoSlug: Plugin = ({ }, (node) => { const slug = node.attributes.find( - (attribute: any) => "name" in attribute && attribute.name == "slug" + (attribute: any) => "name" in attribute && attribute.name == "slug", )?.value as string; if (slug) { @@ -34,12 +34,12 @@ export const remarkJsxAutoSlug: Plugin = ({ } const title = node.attributes.find( - (attribute) => "name" in attribute && attribute.name == "title" + (attribute) => "name" in attribute && attribute.name == "title", )?.value as string; if (!title) { throw new Error( - `[remark-jsx-auto-slug]: ${node.name} should have title property` + `[remark-jsx-auto-slug]: ${node.name} should have title property`, ); } @@ -53,7 +53,7 @@ export const remarkJsxAutoSlug: Plugin = ({ .replace(new RegExp(TITLE_REGEX), ""), }); } - } + }, ); }; }; diff --git a/remark-jsx-auto-slug/package.json b/remark-jsx-auto-slug/package.json index 4347eb2..b0333e1 100644 --- a/remark-jsx-auto-slug/package.json +++ b/remark-jsx-auto-slug/package.json @@ -1,8 +1,23 @@ { "name": "@fujocoded/remark-jsx-auto-slug", - "type": "module", "version": "0.0.1", "description": "Allow auto-adding slug attribute from components with title attribute", + "keywords": [ + "remark" + ], + "license": "MIT", + "author": "FujoCoded LLC", + "repository": { + "type": "git", + "url": "git+https://github.com/FujoWebDev/fujocoded-plugins.git" + }, + "files": [ + "dist", + "LICENSE", + "README.md", + "package.json" + ], + "type": "module", "main": "dist/index.cjs", "module": "dist/index.js", "exports": { @@ -17,24 +32,13 @@ } } }, - "files": [ - "dist", - "LICENSE", - "README.md", - "package.json" - ], + "publishConfig": { + "access": "public" + }, "scripts": { "build": "tsup index.ts --format cjs,esm --dts --clean", - "validate": " npx publint" - }, - "keywords": [ - "remark" - ], - "author": "FujoCoded LLC", - "license": "MIT", - "repository": { - "type": "git", - "url": "git+https://github.com/FujoWebDev/fujocoded-plugins.git" + "validate": " npx publint", + "typecheck": "tsc --noEmit" }, "dependencies": { "unist-util-visit": "^5.0.0" @@ -46,8 +50,5 @@ "tsup": "^8.1.0", "typescript": "^5.5.2", "unified": "^11.0.4" - }, - "publishConfig": { - "access": "public" } } diff --git a/zod-transform-socials/package.json b/zod-transform-socials/package.json index cd646da..27cf881 100644 --- a/zod-transform-socials/package.json +++ b/zod-transform-socials/package.json @@ -1,8 +1,23 @@ { "name": "@fujocoded/zod-transform-socials", - "type": "module", "version": "0.0.14", "description": "A Zod schema + transformer for social URLs", + "keywords": [ + "zod" + ], + "license": "MIT", + "author": "FujoCoded LLC", + "repository": { + "type": "git", + "url": "git+https://github.com/FujoWebDev/fujocoded-plugins.git" + }, + "files": [ + "dist", + "LICENSE", + "README.md", + "package.json" + ], + "type": "module", "main": "dist/index.cjs", "module": "dist/index.js", "exports": { @@ -17,34 +32,20 @@ } } }, - "files": [ - "dist", - "LICENSE", - "README.md", - "package.json" - ], - "scripts": { - "build": "tsup index.ts --format cjs,esm --dts --clean", - "validate": " npx publint" - }, - "keywords": [ - "zod" - ], - "author": "FujoCoded LLC", - "license": "MIT", - "repository": { - "type": "git", - "url": "git+https://github.com/FujoWebDev/fujocoded-plugins.git" - }, "publishConfig": { "access": "public" }, - "devDependencies": { - "tsup": "^8.1.0", - "typescript": "^5.5.2" + "scripts": { + "build": "tsup index.ts --format cjs,esm --dts --clean", + "validate": " npx publint", + "typecheck": "tsc --noEmit" }, "dependencies": { "social-links": "^1.14.0", "zod": "^3.23.8" + }, + "devDependencies": { + "tsup": "^8.1.0", + "typescript": "^5.5.2" } } diff --git a/zod-transform-socials/socials.ts b/zod-transform-socials/socials.ts index 1e06ce1..89ed3aa 100644 --- a/zod-transform-socials/socials.ts +++ b/zod-transform-socials/socials.ts @@ -1,5 +1,8 @@ import type { SocialLinks as SocialLinksLib } from "social-links"; -import { SOCIAL_TYPES, socialLinks as defaultSocialLinks } from "./social-links.ts"; +import { + SOCIAL_TYPES, + socialLinks as defaultSocialLinks, +} from "./social-links.ts"; export const getSocialIcon = (platform: SOCIAL_TYPES) => { if (platform === "inprnt") { @@ -21,7 +24,9 @@ export const createExtractSocialData = (socialLinks: SocialLinksLib) => ({ url }: { url: string }) => { const lowerUrl = url.toLowerCase(); - const socialLinkAttempt = socialLinks.detectProfile(lowerUrl) as SOCIAL_TYPES; + const socialLinkAttempt = socialLinks.detectProfile( + lowerUrl, + ) as SOCIAL_TYPES; if (socialLinkAttempt) { return { url,