diff --git a/.eslintignore b/.eslintignore index e58be97cbaf5..b0c14dbeea5f 100644 --- a/.eslintignore +++ b/.eslintignore @@ -11,10 +11,8 @@ examples/ packages/lqip-loader/lib/ packages/docusaurus/lib/ packages/docusaurus-*/lib/* -packages/docusaurus-*/lib-next/ packages/eslint-plugin/lib/ packages/stylelint-copyright/lib/ -copyUntypedFiles.mjs packages/create-docusaurus/lib/* packages/create-docusaurus/templates/facebook diff --git a/.eslintrc.js b/.eslintrc.js index d8b7a4584e11..4dc985f0d9f9 100644 --- a/.eslintrc.js +++ b/.eslintrc.js @@ -220,7 +220,35 @@ module.exports = { ], }, ], - 'import/order': OFF, + 'import/order': [ + WARNING, + { + groups: [ + 'builtin', + 'external', + 'internal', + ['parent', 'sibling', 'index'], + 'type', + ], + pathGroups: [ + {pattern: '@jest/globals', group: 'builtin', position: 'before'}, + {pattern: 'react', group: 'builtin', position: 'before'}, + {pattern: 'fs-extra', group: 'builtin'}, + {pattern: 'lodash', group: 'external', position: 'before'}, + {pattern: 'clsx', group: 'external', position: 'before'}, + // 'Bit weird to not use the `import/internal-regex` option, but this + // way, we can make `import type { Props } from "@theme/*"` appear + // before `import styles from "styles.module.css"`, which is what we + // always did. This should be removable once we stop using ambient + // module declarations for theme aliases. + {pattern: '@theme/**', group: 'internal'}, + {pattern: '@site/**', group: 'internal'}, + {pattern: '@theme-init/**', group: 'internal'}, + {pattern: '@theme-original/**', group: 'internal'}, + ], + pathGroupsExcludedImportTypes: [], + }, + ], 'import/prefer-default-export': OFF, 'jest/consistent-test-it': WARNING, diff --git a/.gitattributes b/.gitattributes index 4bbe761c210d..6ab8de85c3e5 100644 --- a/.gitattributes +++ b/.gitattributes @@ -31,8 +31,10 @@ # Make GitHub not index certain files in the languages overview # See https://github.com/github/linguist/blob/master/docs/overrides.md # generated files' diff will be minimized -**/__fixtures__/** linguist-generated -.husky/** linguist-vendored -jest/** linguist-vendored -admin/** linguist-documentation -website/** linguist-documentation +**/__fixtures__/** linguist-generated +examples/** linguist-generated +.husky/** linguist-vendored +jest/** linguist-vendored +admin/** linguist-documentation +website/** linguist-documentation +packages/create-docusaurus/templates/** linguist-vendored diff --git a/.github/workflows/build-blog-only.yml b/.github/workflows/build-blog-only.yml index 8b16422415e0..032f8ae3455f 100644 --- a/.github/workflows/build-blog-only.yml +++ b/.github/workflows/build-blog-only.yml @@ -23,7 +23,7 @@ jobs: - name: Checkout uses: actions/checkout@2541b1294d2704b0964813337f33b291d3f8596b # v3 - name: Set up Node - uses: actions/setup-node@56337c425554a6be30cdef71bf441f15be286854 # v3 + uses: actions/setup-node@17f8bd926464a1afa4c6a11669539e9c1ba77048 # v3 with: node-version: '16' cache: yarn diff --git a/.github/workflows/build-perf.yml b/.github/workflows/build-perf.yml index c7c99b0e782f..2fa8b482a7fc 100644 --- a/.github/workflows/build-perf.yml +++ b/.github/workflows/build-perf.yml @@ -35,7 +35,7 @@ jobs: - name: Checkout uses: actions/checkout@2541b1294d2704b0964813337f33b291d3f8596b # v3 - name: Set up Node - uses: actions/setup-node@56337c425554a6be30cdef71bf441f15be286854 # v3 + uses: actions/setup-node@17f8bd926464a1afa4c6a11669539e9c1ba77048 # v3 with: node-version: '16' cache: yarn @@ -55,7 +55,7 @@ jobs: runs-on: ubuntu-latest steps: - uses: actions/checkout@2541b1294d2704b0964813337f33b291d3f8596b # v3 - - uses: actions/setup-node@56337c425554a6be30cdef71bf441f15be286854 # v3 + - uses: actions/setup-node@17f8bd926464a1afa4c6a11669539e9c1ba77048 # v3 with: cache: yarn - name: Installation diff --git a/.github/workflows/canary-release.yml b/.github/workflows/canary-release.yml index f11d805b6461..23353fa1d9e1 100644 --- a/.github/workflows/canary-release.yml +++ b/.github/workflows/canary-release.yml @@ -20,7 +20,7 @@ jobs: with: fetch-depth: 0 # Needed to get the commit number with "git rev-list --count HEAD" - name: Set up Node - uses: actions/setup-node@56337c425554a6be30cdef71bf441f15be286854 # v3 + uses: actions/setup-node@17f8bd926464a1afa4c6a11669539e9c1ba77048 # v3 with: node-version: '16' cache: yarn diff --git a/.github/workflows/codeql-analysis.yml b/.github/workflows/codeql-analysis.yml index 4fb9c9ab407d..91f6c42c4f64 100644 --- a/.github/workflows/codeql-analysis.yml +++ b/.github/workflows/codeql-analysis.yml @@ -34,9 +34,9 @@ jobs: uses: actions/checkout@2541b1294d2704b0964813337f33b291d3f8596b # v3 - name: Initialize CodeQL - uses: github/codeql-action/init@75b4f1c4669133dc294b06c2794e969efa2e5316 # v2 + uses: github/codeql-action/init@2f58583a1b24a7d3c7034f6bf9fa506d23b1183b # v2 with: languages: ${{ matrix.language }} - name: Perform CodeQL Analysis - uses: github/codeql-action/analyze@75b4f1c4669133dc294b06c2794e969efa2e5316 # v2 + uses: github/codeql-action/analyze@2f58583a1b24a7d3c7034f6bf9fa506d23b1183b # v2 diff --git a/.github/workflows/dependency-review.yml b/.github/workflows/dependency-review.yml index a8b388ccc1bd..32fc4d96a997 100644 --- a/.github/workflows/dependency-review.yml +++ b/.github/workflows/dependency-review.yml @@ -15,4 +15,4 @@ jobs: - name: Checkout uses: actions/checkout@2541b1294d2704b0964813337f33b291d3f8596b #v3 - name: Dependency Review - uses: actions/dependency-review-action@3f943b86c9a289f4e632c632695e2e0898d9d67d # v1 + uses: actions/dependency-review-action@39e692fa323107ef86d8fdac0067ce647f239bd7 # v1 diff --git a/.github/workflows/lighthouse-report.yml b/.github/workflows/lighthouse-report.yml index 3f57a9956b14..bbd6692d1e4a 100644 --- a/.github/workflows/lighthouse-report.yml +++ b/.github/workflows/lighthouse-report.yml @@ -36,13 +36,13 @@ jobs: PR_NUMBER: ${{ github.event.pull_request.number}} - name: Format lighthouse score id: format_lighthouse_score - uses: actions/github-script@9ac08808f993958e9de277fe43a64532a609130e # v6 + uses: actions/github-script@7a5c598405937d486b0331594b5da2b14db670da # v6 with: github-token: ${{ secrets.GITHUB_TOKEN }} script: | const results = ${{ steps.lighthouse_audit.outputs.manifest }} const links = ${{ steps.lighthouse_audit.outputs.links }} - const createLighthouseReport = (await import(`${process.env.GITHUB_WORKSPACE}/admin/scripts/format-lighthouse-score.mjs`)).default; + const createLighthouseReport = (await import(`${process.env.GITHUB_WORKSPACE}/admin/scripts/formatLighthouseReport.js`)).default; const comment = createLighthouseReport({ results, links }); core.setOutput("comment", comment); diff --git a/.github/workflows/lint.yml b/.github/workflows/lint.yml index a49bf9c28037..6162382297f6 100644 --- a/.github/workflows/lint.yml +++ b/.github/workflows/lint.yml @@ -21,7 +21,7 @@ jobs: - name: Checkout uses: actions/checkout@2541b1294d2704b0964813337f33b291d3f8596b # v3 - name: Set up Node - uses: actions/setup-node@56337c425554a6be30cdef71bf441f15be286854 # v3 + uses: actions/setup-node@17f8bd926464a1afa4c6a11669539e9c1ba77048 # v3 with: node-version: '16' cache: yarn diff --git a/.github/workflows/showcase-test.yml b/.github/workflows/showcase-test.yml index 8bba764dd61e..0403ea3fa1a2 100644 --- a/.github/workflows/showcase-test.yml +++ b/.github/workflows/showcase-test.yml @@ -23,7 +23,7 @@ jobs: - name: Checkout uses: actions/checkout@2541b1294d2704b0964813337f33b291d3f8596b # v3 - name: Set up Node - uses: actions/setup-node@56337c425554a6be30cdef71bf441f15be286854 # v3 + uses: actions/setup-node@17f8bd926464a1afa4c6a11669539e9c1ba77048 # v3 with: node-version: '16' cache: yarn diff --git a/.github/workflows/tests-e2e.yml b/.github/workflows/tests-e2e.yml index cfaff3b7749b..f10f08f65786 100644 --- a/.github/workflows/tests-e2e.yml +++ b/.github/workflows/tests-e2e.yml @@ -34,7 +34,7 @@ jobs: - name: Checkout uses: actions/checkout@2541b1294d2704b0964813337f33b291d3f8596b # v3 - name: Use Node.js ${{ matrix.node }} - uses: actions/setup-node@56337c425554a6be30cdef71bf441f15be286854 # v3 + uses: actions/setup-node@17f8bd926464a1afa4c6a11669539e9c1ba77048 # v3 with: node-version: ${{ matrix.node }} cache: yarn @@ -73,7 +73,7 @@ jobs: - name: Checkout uses: actions/checkout@2541b1294d2704b0964813337f33b291d3f8596b # v3 - name: Use Node.js 16 - uses: actions/setup-node@56337c425554a6be30cdef71bf441f15be286854 # v3 + uses: actions/setup-node@17f8bd926464a1afa4c6a11669539e9c1ba77048 # v3 with: node-version: '16' cache: yarn @@ -119,7 +119,7 @@ jobs: - name: Checkout uses: actions/checkout@2541b1294d2704b0964813337f33b291d3f8596b # v3 - name: Use Node.js 16 - uses: actions/setup-node@56337c425554a6be30cdef71bf441f15be286854 # v3 + uses: actions/setup-node@17f8bd926464a1afa4c6a11669539e9c1ba77048 # v3 with: node-version: '16' cache: yarn @@ -149,7 +149,7 @@ jobs: - name: Checkout uses: actions/checkout@2541b1294d2704b0964813337f33b291d3f8596b # v3 - name: Use Node.js 16 - uses: actions/setup-node@56337c425554a6be30cdef71bf441f15be286854 # v3 + uses: actions/setup-node@17f8bd926464a1afa4c6a11669539e9c1ba77048 # v3 with: node-version: '16' cache: yarn diff --git a/.github/workflows/tests-swizzle.yml b/.github/workflows/tests-swizzle.yml index 4887565a4eb4..00a7f388a2ac 100644 --- a/.github/workflows/tests-swizzle.yml +++ b/.github/workflows/tests-swizzle.yml @@ -27,7 +27,7 @@ jobs: - name: Checkout uses: actions/checkout@2541b1294d2704b0964813337f33b291d3f8596b # v3 - name: Set up Node - uses: actions/setup-node@56337c425554a6be30cdef71bf441f15be286854 # v3 + uses: actions/setup-node@17f8bd926464a1afa4c6a11669539e9c1ba77048 # v3 with: node-version: '16' cache: yarn diff --git a/.github/workflows/tests-windows.yml b/.github/workflows/tests-windows.yml index ade80a4f646f..186833e7d080 100644 --- a/.github/workflows/tests-windows.yml +++ b/.github/workflows/tests-windows.yml @@ -29,7 +29,7 @@ jobs: - name: Checkout uses: actions/checkout@2541b1294d2704b0964813337f33b291d3f8596b # v3 - name: Use Node.js ${{ matrix.node }} - uses: actions/setup-node@56337c425554a6be30cdef71bf441f15be286854 # v3 + uses: actions/setup-node@17f8bd926464a1afa4c6a11669539e9c1ba77048 # v3 with: node-version: ${{ matrix.node }} - name: Installation diff --git a/.github/workflows/tests.yml b/.github/workflows/tests.yml index 89bb9fa13f00..a078a2bf3639 100644 --- a/.github/workflows/tests.yml +++ b/.github/workflows/tests.yml @@ -27,7 +27,7 @@ jobs: - name: Checkout uses: actions/checkout@2541b1294d2704b0964813337f33b291d3f8596b # v3 - name: Use Node.js ${{ matrix.node }} - uses: actions/setup-node@56337c425554a6be30cdef71bf441f15be286854 # v3 + uses: actions/setup-node@17f8bd926464a1afa4c6a11669539e9c1ba77048 # v3 with: node-version: ${{ matrix.node }} cache: yarn diff --git a/.gitignore b/.gitignore index 0e0bd14648b0..1e612853226b 100644 --- a/.gitignore +++ b/.gitignore @@ -25,7 +25,6 @@ packages/docusaurus/lib/ packages/docusaurus-*/lib/* packages/eslint-plugin/lib/ packages/stylelint-copyright/lib/ -packages/docusaurus-*/lib-next/ website/netlifyDeployPreview/* website/changelog diff --git a/.prettierignore b/.prettierignore index c7aec4e02643..5bfdf4925c04 100644 --- a/.prettierignore +++ b/.prettierignore @@ -7,7 +7,6 @@ coverage packages/lqip-loader/lib/ packages/docusaurus/lib/ packages/docusaurus-*/lib/* -packages/docusaurus-*/lib-next/ packages/create-docusaurus/lib/* packages/create-docusaurus/templates/*/docusaurus.config.js packages/eslint-plugin/lib/ diff --git a/.stylelintignore b/.stylelintignore index 951af3a16ea9..15db7860ba7a 100644 --- a/.stylelintignore +++ b/.stylelintignore @@ -10,7 +10,6 @@ examples/ packages/lqip-loader/lib/ packages/docusaurus/lib/ packages/docusaurus-*/lib/* -packages/docusaurus-*/lib-next/ packages/create-docusaurus/lib/* packages/create-docusaurus/templates/ website/static/katex/katex.min.css diff --git a/__tests__/validate-package-json.test.ts b/__tests__/validate-package-json.test.ts index 8598d7b89247..ef18176ecd92 100644 --- a/__tests__/validate-package-json.test.ts +++ b/__tests__/validate-package-json.test.ts @@ -5,8 +5,8 @@ * LICENSE file in the root directory of this source tree. */ -import {Globby} from '@docusaurus/utils'; import fs from 'fs-extra'; +import {Globby} from '@docusaurus/utils'; type PackageJsonFile = { file: string; @@ -28,7 +28,11 @@ type PackageJsonFile = { async function getPackagesJsonFiles(): Promise { const files = await Globby('packages/*/package.json'); return Promise.all( - files.map((file) => fs.readJSON(file).then((content) => ({file, content}))), + files.map((file) => + fs + .readJSON(file) + .then((content: PackageJsonFile['content']) => ({file, content})), + ), ); } @@ -62,7 +66,9 @@ describe('packages', () => { const packageJsonFiles = await getPackagesJsonFiles(); packageJsonFiles - .filter((packageJsonFile) => packageJsonFile.content.name.startsWith('@')) + .filter((packageJsonFile) => + packageJsonFile.content.name?.startsWith('@'), + ) .forEach((packageJsonFile) => { if (packageJsonFile) { // Unfortunately jest custom message do not exist in loops, diff --git a/__tests__/validate-tsconfig.test.ts b/__tests__/validate-tsconfig.test.ts new file mode 100644 index 000000000000..e69d170502ba --- /dev/null +++ b/__tests__/validate-tsconfig.test.ts @@ -0,0 +1,70 @@ +/** + * Copyright (c) Facebook, Inc. and its affiliates. + * + * This source code is licensed under the MIT license found in the + * LICENSE file in the root directory of this source tree. + */ + +import fs from 'fs-extra'; +import {Globby} from '@docusaurus/utils'; +import {Joi} from '@docusaurus/utils-validation'; + +type TsconfigFile = { + file: string; + content: { + extends?: string; + compilerOptions: { + [key: string]: unknown; + }; + }; +}; + +async function getTsconfigFiles(): Promise { + const files = await Globby('packages/*/tsconfig.*'); + return Promise.all( + files.map((file) => + fs + .readJSON(file) + .then((content: TsconfigFile['content']) => ({file, content})), + ), + ); +} + +const tsconfigSchema = Joi.object({ + extends: '../../tsconfig.json', + compilerOptions: Joi.alternatives().conditional( + Joi.object({noEmit: true}).unknown(), + { + then: Joi.object({ + noEmit: Joi.valid(true).required(), + incremental: Joi.forbidden(), + tsBuildInfoFile: Joi.forbidden(), + outDir: Joi.forbidden(), + module: Joi.valid('commonjs', 'es2020', 'esnext').required(), + }).unknown(), + otherwise: Joi.object({ + noEmit: Joi.valid(false).required(), + incremental: Joi.valid(true).required(), + rootDir: Joi.valid('src').required(), + outDir: Joi.valid('lib').required(), + module: Joi.valid('commonjs', 'es2020', 'esnext').required(), + }).unknown(), + }, + ), +}).unknown(); + +describe('tsconfig files', () => { + it('contain all required fields', async () => { + const tsconfigFiles = await getTsconfigFiles(); + tsconfigFiles.forEach((file) => { + try { + Joi.attempt(file.content, tsconfigSchema); + } catch (e) { + ( + e as Error + ).message += `\n${file.file} does not match the required schema.`; + throw e; + } + }); + }); +}); diff --git a/admin/new.docusaurus.io/functions/codesandbox.ts b/admin/new.docusaurus.io/functions/codesandbox.ts index 365ac26911f4..650c45727e6b 100644 --- a/admin/new.docusaurus.io/functions/codesandbox.ts +++ b/admin/new.docusaurus.io/functions/codesandbox.ts @@ -5,9 +5,8 @@ * LICENSE file in the root directory of this source tree. */ -import type {Handler} from '@netlify/functions'; - import {createPlaygroundResponse} from '../functionUtils/playgroundUtils'; +import type {Handler} from '@netlify/functions'; export const handler: Handler = async function handler() { return createPlaygroundResponse('codesandbox'); diff --git a/admin/new.docusaurus.io/functions/index.ts b/admin/new.docusaurus.io/functions/index.ts index a137fecb41c3..14a9df8c0632 100644 --- a/admin/new.docusaurus.io/functions/index.ts +++ b/admin/new.docusaurus.io/functions/index.ts @@ -5,13 +5,12 @@ * LICENSE file in the root directory of this source tree. */ -import type {Handler} from '@netlify/functions'; - import { readPlaygroundName, createPlaygroundResponse, createPlaygroundDocumentationResponse, } from '../functionUtils/playgroundUtils'; +import type {Handler} from '@netlify/functions'; export const handler: Handler = async (event) => { const playgroundName = readPlaygroundName(event); diff --git a/admin/new.docusaurus.io/functions/stackblitz.ts b/admin/new.docusaurus.io/functions/stackblitz.ts index e7762f20dce0..bc6a84d31f5a 100644 --- a/admin/new.docusaurus.io/functions/stackblitz.ts +++ b/admin/new.docusaurus.io/functions/stackblitz.ts @@ -5,9 +5,8 @@ * LICENSE file in the root directory of this source tree. */ -import type {Handler} from '@netlify/functions'; - import {createPlaygroundResponse} from '../functionUtils/playgroundUtils'; +import type {Handler} from '@netlify/functions'; export const handler: Handler = async function handler() { return createPlaygroundResponse('stackblitz'); diff --git a/admin/scripts/copyUntypedFiles.js b/admin/scripts/copyUntypedFiles.js new file mode 100644 index 000000000000..59178146452a --- /dev/null +++ b/admin/scripts/copyUntypedFiles.js @@ -0,0 +1,36 @@ +/** + * Copyright (c) Facebook, Inc. and its affiliates. + * + * This source code is licensed under the MIT license found in the + * LICENSE file in the root directory of this source tree. + */ + +import fs from 'fs-extra'; +import path from 'path'; +import chokidar from 'chokidar'; + +const srcDir = path.join(process.cwd(), 'src'); +const libDir = path.join(process.cwd(), 'lib'); + +const ignoredPattern = /(?:__tests__|\.tsx?$)/; + +async function copy() { + await fs.copy(srcDir, libDir, { + filter(testedPath) { + return !ignoredPattern.test(testedPath); + }, + }); +} + +if (process.argv.includes('--watch')) { + const watcher = chokidar.watch(srcDir, { + ignored: ignoredPattern, + ignoreInitial: true, + persistent: true, + }); + ['add', 'change', 'unlink', 'addDir', 'unlinkDir'].forEach((event) => + watcher.on(event, copy), + ); +} else { + await copy(); +} diff --git a/admin/scripts/format-lighthouse-score.mjs b/admin/scripts/formatLighthouseReport.js similarity index 100% rename from admin/scripts/format-lighthouse-score.mjs rename to admin/scripts/formatLighthouseReport.js diff --git a/admin/scripts/generateExamples.mjs b/admin/scripts/generateExamples.js similarity index 100% rename from admin/scripts/generateExamples.mjs rename to admin/scripts/generateExamples.js diff --git a/admin/scripts/package.json b/admin/scripts/package.json new file mode 100644 index 000000000000..03df6476e25f --- /dev/null +++ b/admin/scripts/package.json @@ -0,0 +1,7 @@ +{ + "name": "docu-scripts", + "description": "These are the scripts used in various places of Docusaurus maintenance", + "private": true, + "license": "MIT", + "type": "module" +} diff --git a/admin/scripts/image-resize.mjs b/admin/scripts/resizeImage.js similarity index 100% rename from admin/scripts/image-resize.mjs rename to admin/scripts/resizeImage.js index cea298ef8038..ce3d11f97680 100644 --- a/admin/scripts/image-resize.mjs +++ b/admin/scripts/resizeImage.js @@ -5,12 +5,12 @@ * LICENSE file in the root directory of this source tree. */ -import sharp from 'sharp'; import fs from 'fs-extra'; import path from 'path'; -import imageSize from 'image-size'; import {fileURLToPath} from 'url'; import logger from '@docusaurus/logger'; +import sharp from 'sharp'; +import imageSize from 'image-size'; const allImages = ( await fs.readdir(new URL('../../website/src/data/showcase', import.meta.url)) diff --git a/jest.config.mjs b/jest.config.mjs index 39c7f9c7c659..5e7200416b7b 100644 --- a/jest.config.mjs +++ b/jest.config.mjs @@ -23,7 +23,6 @@ const ignorePatterns = [ '/packages/docusaurus-plugin-content-docs/lib', '/packages/docusaurus-plugin-content-pages/lib', '/packages/docusaurus-theme-classic/lib', - '/packages/docusaurus-theme-classic/lib-next', '/packages/docusaurus-theme-common/lib', '/packages/docusaurus-migrate/lib', '/jest', @@ -43,7 +42,18 @@ export default { '/packages/docusaurus-utils/src/index.ts', ], transform: { - '^.+\\.[jt]sx?$': '@swc/jest', + '^.+\\.[jt]sx?$': [ + '@swc/jest', + { + jsc: { + parser: { + syntax: 'typescript', + tsx: true, + }, + target: 'es2020', + }, + }, + ], }, errorOnDeprecated: true, reporters: ['default', 'github-actions'], diff --git a/jest/snapshotPathNormalizer.ts b/jest/snapshotPathNormalizer.ts index 957aef8c40bc..a0e9a3f4d38d 100644 --- a/jest/snapshotPathNormalizer.ts +++ b/jest/snapshotPathNormalizer.ts @@ -8,13 +8,13 @@ // Forked from https://github.com/tribou/jest-serializer-path/blob/master/lib/index.js // Added some project-specific handlers -import _ from 'lodash'; -import {escapePath} from '@docusaurus/utils'; -import stripAnsi from 'strip-ansi'; -import {version} from '@docusaurus/core/package.json'; import os from 'os'; import path from 'path'; import fs from 'fs'; +import _ from 'lodash'; +import {escapePath} from '@docusaurus/utils'; +import {version} from '@docusaurus/core/package.json'; +import stripAnsi from 'strip-ansi'; export function print( val: unknown, diff --git a/package.json b/package.json index 16f2f3be15ba..533f32b71f48 100644 --- a/package.json +++ b/package.json @@ -16,7 +16,7 @@ "start:website:baseUrl": "yarn workspace website start:baseUrl", "start:website:blogOnly": "yarn workspace website start:blogOnly", "start:website:deployPreview": "cross-env NETLIFY=true CONTEXT='deploy-preview' yarn workspace website start", - "examples:generate": "node admin/scripts/generateExamples.mjs", + "examples:generate": "node admin/scripts/generateExamples.js", "build": "yarn build:packages && yarn build:website", "build:packages": "lerna run build --no-private", "build:website": "yarn workspace website build", @@ -54,7 +54,7 @@ "test": "jest", "test:build:website": "./admin/scripts/test-release.sh", "watch": "yarn lerna run --parallel watch", - "clear": "(yarn workspace website clear || echo 'Failure while running docusaurus clear') && yarn lerna exec --ignore docusaurus yarn rimraf lib lib-next", + "clear": "(yarn workspace website clear || echo 'Failure while running docusaurus clear') && yarn lerna exec --ignore docusaurus yarn rimraf lib", "test:baseUrl": "yarn build:website:baseUrl && yarn serve:website:baseUrl", "lock:update": "npx yarn-deduplicate" }, @@ -63,32 +63,31 @@ }, "devDependencies": { "@crowdin/cli": "^3.7.8", - "@swc/core": "^1.2.181", + "@swc/core": "^1.2.189", "@swc/jest": "^0.2.21", "@testing-library/react-hooks": "^8.0.0", "@types/fs-extra": "^9.0.13", - "@types/jest": "^27.5.0", + "@types/jest": "^27.5.1", "@types/lodash": "^4.14.182", - "@types/node": "^17.0.31", + "@types/node": "^17.0.35", "@types/prompts": "^2.0.14", "@types/react": "^18.0.9", - "@types/react-dev-utils": "^9.0.10", + "@types/react-dev-utils": "^9.0.11", "@types/react-test-renderer": "^18.0.0", "@types/semver": "^7.3.9", "@types/shelljs": "^0.8.11", - "@typescript-eslint/eslint-plugin": "^5.23.0", - "@typescript-eslint/parser": "^5.23.0", - "concurrently": "^7.1.0", + "@typescript-eslint/eslint-plugin": "^5.25.0", + "@typescript-eslint/parser": "^5.25.0", "cross-env": "^7.0.3", - "cspell": "^5.20.0", - "eslint": "^8.15.0", + "cspell": "^6.0.0", + "eslint": "^8.16.0", "eslint-config-airbnb": "^19.0.4", "eslint-config-prettier": "^8.5.0", "eslint-plugin-header": "^3.1.1", "eslint-plugin-import": "^2.26.0", - "eslint-plugin-jest": "^26.1.5", + "eslint-plugin-jest": "^26.2.2", "eslint-plugin-jsx-a11y": "^6.5.1", - "eslint-plugin-react": "^7.29.4", + "eslint-plugin-react": "^7.30.0", "eslint-plugin-react-hooks": "^4.5.0", "eslint-plugin-regexp": "^1.7.0", "husky": "^8.0.1", @@ -99,6 +98,7 @@ "lerna": "^4.0.0", "lerna-changelog": "^2.2.0", "lint-staged": "^12.4.1", + "npm-run-all": "^4.1.5", "prettier": "^2.6.2", "react": "^17.0.2", "react-dom": "^17.0.2", @@ -107,7 +107,7 @@ "rimraf": "^3.0.2", "sharp": "^0.30.4", "strip-ansi": "^6.0.1", - "stylelint": "^14.8.2", + "stylelint": "^14.8.3", "stylelint-config-prettier": "^9.0.3", "stylelint-config-standard": "^25.0.0", "typescript": "^4.6.4" diff --git a/packages/create-docusaurus/.npmignore b/packages/create-docusaurus/.npmignore index 1edc83766ff5..1f851e4a70c0 100644 --- a/packages/create-docusaurus/.npmignore +++ b/packages/create-docusaurus/.npmignore @@ -1,5 +1,4 @@ -copyUntypedFiles.mjs -.tsbuildinfo +.tsbuildinfo* __tests__ node_modules diff --git a/packages/create-docusaurus/bin/index.js b/packages/create-docusaurus/bin/index.js index 7673e0025a0f..b4b6d47c5ec9 100755 --- a/packages/create-docusaurus/bin/index.js +++ b/packages/create-docusaurus/bin/index.js @@ -8,11 +8,11 @@ // @ts-check +import path from 'path'; +import {createRequire} from 'module'; import logger from '@docusaurus/logger'; import semver from 'semver'; -import path from 'path'; import {program} from 'commander'; -import {createRequire} from 'module'; const packageJson = createRequire(import.meta.url)('../package.json'); const requiredVersion = packageJson.engines.node; diff --git a/packages/create-docusaurus/package.json b/packages/create-docusaurus/package.json index 8c715fc339e3..d7a60dba1c13 100755 --- a/packages/create-docusaurus/package.json +++ b/packages/create-docusaurus/package.json @@ -13,8 +13,8 @@ }, "scripts": { "create-docusaurus": "create-docusaurus", - "build": "tsc -p tsconfig.build.json", - "watch": "tsc -p tsconfig.build.json --watch" + "build": "tsc --build", + "watch": "tsc --build --watch" }, "bin": "bin/index.js", "publishConfig": { diff --git a/packages/create-docusaurus/src/index.ts b/packages/create-docusaurus/src/index.ts index b35e653b0a81..c1f592cefcd1 100755 --- a/packages/create-docusaurus/src/index.ts +++ b/packages/create-docusaurus/src/index.ts @@ -5,13 +5,13 @@ * LICENSE file in the root directory of this source tree. */ -import logger from '@docusaurus/logger'; import fs from 'fs-extra'; import {fileURLToPath} from 'url'; -import prompts, {type Choice} from 'prompts'; import path from 'path'; -import shell from 'shelljs'; import _ from 'lodash'; +import logger from '@docusaurus/logger'; +import shell from 'shelljs'; +import prompts, {type Choice} from 'prompts'; import supportsColor from 'supports-color'; type CLIOptions = { @@ -65,7 +65,7 @@ async function askForPackageManagerChoice(): Promise { .map((p) => ({title: p, value: p})); return ( - await prompts( + (await prompts( { type: 'select', name: 'packageManager', @@ -77,7 +77,7 @@ async function askForPackageManagerChoice(): Promise { logger.info`Falling back to name=${defaultPackageManager}`; }, }, - ) + )) as {packageManager: PackageManager} ).packageManager; } @@ -203,7 +203,7 @@ async function getGitCommand(gitStrategy: GitStrategy): Promise { case 'copy': return 'git clone --recursive --depth 1'; case 'custom': { - const {command} = await prompts( + const {command} = (await prompts( { type: 'text', name: 'command', @@ -215,7 +215,7 @@ async function getGitCommand(gitStrategy: GitStrategy): Promise { logger.info`Falling back to code=${'git clone'}`; }, }, - ); + )) as {command: string}; return command ?? 'git clone'; } case 'deep': @@ -245,7 +245,7 @@ async function getSiteName( } return reqName; } - const {siteName} = await prompts( + const {siteName} = (await prompts( { type: 'text', name: 'siteName', @@ -259,7 +259,7 @@ async function getSiteName( process.exit(1); }, }, - ); + )) as {siteName: string}; return siteName; } @@ -324,7 +324,7 @@ async function getSource( const template = cliOptions.gitStrategy ? 'Git repository' : ( - await prompts( + (await prompts( { type: 'select', name: 'template', @@ -337,10 +337,10 @@ async function getSource( process.exit(1); }, }, - ) + )) as {template: Template | 'Git repository' | 'Local template'} ).template; if (template === 'Git repository') { - const {gitRepoUrl} = await prompts( + const {gitRepoUrl} = (await prompts( { type: 'text', name: 'gitRepoUrl', @@ -359,7 +359,7 @@ async function getSource( process.exit(1); }, }, - ); + )) as {gitRepoUrl: string}; let strategy = cliOptions.gitStrategy; if (!strategy) { ({strategy} = await prompts( @@ -393,7 +393,7 @@ async function getSource( strategy: strategy ?? 'deep', }; } else if (template === 'Local template') { - const {templateDir} = await prompts( + const {templateDir} = (await prompts( { type: 'text', name: 'templateDir', @@ -418,7 +418,7 @@ async function getSource( process.exit(1); }, }, - ); + )) as {templateDir: string}; return { type: 'local', path: templateDir, @@ -442,7 +442,7 @@ async function getSource( } async function updatePkg(pkgPath: string, obj: {[key: string]: unknown}) { - const pkg = await fs.readJSON(pkgPath); + const pkg = (await fs.readJSON(pkgPath)) as {[key: string]: unknown}; const newPkg = Object.assign(pkg, obj); await fs.outputFile(pkgPath, `${JSON.stringify(newPkg, null, 2)}\n`); diff --git a/packages/create-docusaurus/templates/classic-typescript/package.json b/packages/create-docusaurus/templates/classic-typescript/package.json index 3f98e42c9f79..22520824356d 100644 --- a/packages/create-docusaurus/templates/classic-typescript/package.json +++ b/packages/create-docusaurus/templates/classic-typescript/package.json @@ -19,7 +19,7 @@ "@docusaurus/preset-classic": "2.0.0-beta.20", "@mdx-js/react": "^1.6.22", "clsx": "^1.1.1", - "prism-react-renderer": "^1.3.1", + "prism-react-renderer": "^1.3.3", "react": "^17.0.2", "react-dom": "^17.0.2" }, diff --git a/packages/create-docusaurus/templates/classic-typescript/src/pages/index.tsx b/packages/create-docusaurus/templates/classic-typescript/src/pages/index.tsx index 3408a41e7f23..305139fba009 100644 --- a/packages/create-docusaurus/templates/classic-typescript/src/pages/index.tsx +++ b/packages/create-docusaurus/templates/classic-typescript/src/pages/index.tsx @@ -1,11 +1,12 @@ import React from 'react'; import clsx from 'clsx'; -import Layout from '@theme/Layout'; import Link from '@docusaurus/Link'; import useDocusaurusContext from '@docusaurus/useDocusaurusContext'; -import styles from './index.module.css'; +import Layout from '@theme/Layout'; import HomepageFeatures from '@site/src/components/HomepageFeatures'; +import styles from './index.module.css'; + function HomepageHeader() { const {siteConfig} = useDocusaurusContext(); return ( diff --git a/packages/create-docusaurus/templates/classic/package.json b/packages/create-docusaurus/templates/classic/package.json index bc39e6d4c02b..c7be6e72caaa 100644 --- a/packages/create-docusaurus/templates/classic/package.json +++ b/packages/create-docusaurus/templates/classic/package.json @@ -18,7 +18,7 @@ "@docusaurus/preset-classic": "2.0.0-beta.20", "@mdx-js/react": "^1.6.22", "clsx": "^1.1.1", - "prism-react-renderer": "^1.3.1", + "prism-react-renderer": "^1.3.3", "react": "^17.0.2", "react-dom": "^17.0.2" }, diff --git a/packages/create-docusaurus/templates/classic/src/pages/index.js b/packages/create-docusaurus/templates/classic/src/pages/index.js index a4fc2d3f03e6..affcd9099c28 100644 --- a/packages/create-docusaurus/templates/classic/src/pages/index.js +++ b/packages/create-docusaurus/templates/classic/src/pages/index.js @@ -1,11 +1,12 @@ import React from 'react'; import clsx from 'clsx'; -import Layout from '@theme/Layout'; import Link from '@docusaurus/Link'; import useDocusaurusContext from '@docusaurus/useDocusaurusContext'; -import styles from './index.module.css'; +import Layout from '@theme/Layout'; import HomepageFeatures from '@site/src/components/HomepageFeatures'; +import styles from './index.module.css'; + function HomepageHeader() { const {siteConfig} = useDocusaurusContext(); return ( diff --git a/packages/create-docusaurus/templates/facebook/package.json b/packages/create-docusaurus/templates/facebook/package.json index 2c7a49aa59d8..63b947a05071 100644 --- a/packages/create-docusaurus/templates/facebook/package.json +++ b/packages/create-docusaurus/templates/facebook/package.json @@ -27,16 +27,16 @@ }, "devDependencies": { "@babel/eslint-parser": "^7.17.0", - "eslint": "^8.15.0", + "eslint": "^8.16.0", "eslint-config-airbnb": "^19.0.4", "eslint-config-prettier": "^8.5.0", "eslint-plugin-header": "^3.1.1", "eslint-plugin-import": "^2.26.0", "eslint-plugin-jsx-a11y": "^6.5.1", - "eslint-plugin-react": "^7.29.4", + "eslint-plugin-react": "^7.30.0", "eslint-plugin-react-hooks": "^4.5.0", "prettier": "^2.6.2", - "stylelint": "^14.8.2" + "stylelint": "^14.8.3" }, "browserslist": { "production": [ diff --git a/packages/create-docusaurus/tsconfig.build.json b/packages/create-docusaurus/tsconfig.build.json index 41b40e7cf697..6f46335ae9d0 100644 --- a/packages/create-docusaurus/tsconfig.build.json +++ b/packages/create-docusaurus/tsconfig.build.json @@ -1,12 +1,14 @@ { "extends": "../../tsconfig.json", "compilerOptions": { + "noEmit": false, + "composite": true, "module": "es2020", "incremental": true, "tsBuildInfoFile": "./lib/.tsbuildinfo", "rootDir": "src", "outDir": "lib" }, - "include": ["src/"], - "exclude": ["templates/"] + "include": ["src"], + "exclude": ["templates/", "**/__tests__/**"] } diff --git a/packages/create-docusaurus/tsconfig.json b/packages/create-docusaurus/tsconfig.json index edb2c88e1daf..ef9bff21668e 100644 --- a/packages/create-docusaurus/tsconfig.json +++ b/packages/create-docusaurus/tsconfig.json @@ -1,10 +1,12 @@ -// For editor typechecking; includes bin { - "extends": "./tsconfig.build.json", + "extends": "../../tsconfig.json", + "references": [{"path": "./tsconfig.build.json"}], "compilerOptions": { "noEmit": true, "allowJs": true, + "module": "esnext", "rootDir": "." }, - "include": ["src", "bin"] + "include": ["bin"], + "exclude": ["**/__tests__/**"] } diff --git a/packages/docusaurus-cssnano-preset/.npmignore b/packages/docusaurus-cssnano-preset/.npmignore index c912533dd7d2..03c9ae1e1b54 100644 --- a/packages/docusaurus-cssnano-preset/.npmignore +++ b/packages/docusaurus-cssnano-preset/.npmignore @@ -1 +1,3 @@ +.tsbuildinfo* +tsconfig* __tests__ diff --git a/packages/docusaurus-cssnano-preset/index.js b/packages/docusaurus-cssnano-preset/index.js deleted file mode 100644 index cac7eda8999d..000000000000 --- a/packages/docusaurus-cssnano-preset/index.js +++ /dev/null @@ -1,25 +0,0 @@ -/** - * Copyright (c) Facebook, Inc. and its affiliates. - * - * This source code is licensed under the MIT license found in the - * LICENSE file in the root directory of this source tree. - */ - -const advancedBasePreset = require('cssnano-preset-advanced'); -const postCssSortMediaQueries = require('postcss-sort-media-queries'); -const postCssRemoveOverriddenCustomProperties = require('./src/remove-overridden-custom-properties'); - -module.exports = function docusaurusCssnanoPreset(opts) { - const advancedPreset = advancedBasePreset({ - autoprefixer: {add: false}, - discardComments: {removeAll: true}, - ...opts, - }); - - advancedPreset.plugins.unshift( - [postCssSortMediaQueries], - [postCssRemoveOverriddenCustomProperties], - ); - - return advancedPreset; -}; diff --git a/packages/docusaurus-cssnano-preset/package.json b/packages/docusaurus-cssnano-preset/package.json index 48b9c5697748..6469eba2405a 100644 --- a/packages/docusaurus-cssnano-preset/package.json +++ b/packages/docusaurus-cssnano-preset/package.json @@ -2,20 +2,25 @@ "name": "@docusaurus/cssnano-preset", "version": "2.0.0-beta.20", "description": "Advanced cssnano preset for maximum optimization.", - "main": "index.js", + "main": "lib/index.js", "license": "MIT", "publishConfig": { "access": "public" }, + "scripts": { + "build": "tsc", + "watch": "tsc --watch" + }, "repository": { "type": "git", "url": "https://github.com/facebook/docusaurus.git", "directory": "packages/docusaurus-cssnano-preset" }, "dependencies": { - "cssnano-preset-advanced": "^5.3.3", - "postcss": "^8.4.13", - "postcss-sort-media-queries": "^4.2.1" + "cssnano-preset-advanced": "^5.3.5", + "postcss": "^8.4.14", + "postcss-sort-media-queries": "^4.2.1", + "tslib": "^2.4.0" }, "devDependencies": { "to-vfile": "^6.1.0" diff --git a/packages/docusaurus-cssnano-preset/src/deps.d.ts b/packages/docusaurus-cssnano-preset/src/deps.d.ts new file mode 100644 index 000000000000..f508fb9197d5 --- /dev/null +++ b/packages/docusaurus-cssnano-preset/src/deps.d.ts @@ -0,0 +1,11 @@ +/** + * Copyright (c) Facebook, Inc. and its affiliates. + * + * This source code is licensed under the MIT license found in the + * LICENSE file in the root directory of this source tree. + */ + +declare module 'postcss-sort-media-queries' { + const plugin: import('postcss').PluginCreator; + export default plugin; +} diff --git a/packages/docusaurus-cssnano-preset/src/index.ts b/packages/docusaurus-cssnano-preset/src/index.ts new file mode 100644 index 000000000000..6bae42c6f8c7 --- /dev/null +++ b/packages/docusaurus-cssnano-preset/src/index.ts @@ -0,0 +1,27 @@ +/** + * Copyright (c) Facebook, Inc. and its affiliates. + * + * This source code is licensed under the MIT license found in the + * LICENSE file in the root directory of this source tree. + */ + +import advancedBasePreset from 'cssnano-preset-advanced'; +import postCssSortMediaQueries from 'postcss-sort-media-queries'; +import postCssRemoveOverriddenCustomProperties from './remove-overridden-custom-properties'; + +const preset: typeof advancedBasePreset = function preset(opts) { + const advancedPreset = advancedBasePreset({ + autoprefixer: {add: false}, + discardComments: {removeAll: true}, + ...opts, + }); + + advancedPreset.plugins.unshift( + [postCssSortMediaQueries, undefined], + [postCssRemoveOverriddenCustomProperties, undefined], + ); + + return advancedPreset; +}; + +export = preset; diff --git a/packages/docusaurus-cssnano-preset/src/remove-overridden-custom-properties/__tests__/__snapshots__/index.test.js.snap b/packages/docusaurus-cssnano-preset/src/remove-overridden-custom-properties/__tests__/__snapshots__/index.test.ts.snap similarity index 100% rename from packages/docusaurus-cssnano-preset/src/remove-overridden-custom-properties/__tests__/__snapshots__/index.test.js.snap rename to packages/docusaurus-cssnano-preset/src/remove-overridden-custom-properties/__tests__/__snapshots__/index.test.ts.snap diff --git a/packages/docusaurus-cssnano-preset/src/remove-overridden-custom-properties/__tests__/index.test.js b/packages/docusaurus-cssnano-preset/src/remove-overridden-custom-properties/__tests__/index.test.ts similarity index 78% rename from packages/docusaurus-cssnano-preset/src/remove-overridden-custom-properties/__tests__/index.test.js rename to packages/docusaurus-cssnano-preset/src/remove-overridden-custom-properties/__tests__/index.test.ts index b54446179796..8e50db5a74bd 100644 --- a/packages/docusaurus-cssnano-preset/src/remove-overridden-custom-properties/__tests__/index.test.js +++ b/packages/docusaurus-cssnano-preset/src/remove-overridden-custom-properties/__tests__/index.test.ts @@ -5,12 +5,12 @@ * LICENSE file in the root directory of this source tree. */ -const path = require('path'); -const vfile = require('to-vfile'); -const postcss = require('postcss'); -const postCssRemoveOverriddenCustomProperties = require('../index'); +import path from 'path'; +import vfile from 'to-vfile'; +import postcss from 'postcss'; +import postCssRemoveOverriddenCustomProperties from '../index'; -const processFixture = (name) => { +const processFixture = (name: string) => { const input = vfile.readSync( path.join(__dirname, '__fixtures__', `${name}.css`), 'utf8', diff --git a/packages/docusaurus-cssnano-preset/src/remove-overridden-custom-properties/index.js b/packages/docusaurus-cssnano-preset/src/remove-overridden-custom-properties/index.ts similarity index 69% rename from packages/docusaurus-cssnano-preset/src/remove-overridden-custom-properties/index.js rename to packages/docusaurus-cssnano-preset/src/remove-overridden-custom-properties/index.ts index 51eb53b35327..a7dbba88f3ce 100644 --- a/packages/docusaurus-cssnano-preset/src/remove-overridden-custom-properties/index.js +++ b/packages/docusaurus-cssnano-preset/src/remove-overridden-custom-properties/index.ts @@ -5,6 +5,10 @@ * LICENSE file in the root directory of this source tree. */ +import type {Plugin, Rule, Node} from 'postcss'; + +const isRule = (node: Node | undefined): node is Rule => node?.type === 'rule'; + /** * This PostCSS plugin will remove duplicate/same custom properties (which are * actually overridden ones) **only** from `:root` selector. @@ -17,32 +21,31 @@ * applied). * - If the same custom properties have at least one `!important` rule, then * only those properties that do not have this rule will be removed. - * @returns {import('postcss').Plugin} */ -module.exports = function creator() { +function creator(): Plugin { return { postcssPlugin: 'postcss-remove-overridden-custom-properties', Declaration(decl) { - if (decl.parent.selector !== ':root') { + if (!isRule(decl.parent) || decl.parent.selector !== ':root') { return; } const sameProperties = decl.parent.nodes.filter( - (n) => n.prop === decl.prop, + (n) => 'prop' in n && n.prop === decl.prop, ); - const hasImportantProperties = sameProperties.some((p) => - Object.prototype.hasOwnProperty.call(p, 'important'), + const hasImportantProperties = sameProperties.some( + (p) => 'important' in p, ); const overriddenProperties = hasImportantProperties - ? sameProperties.filter( - (p) => !Object.prototype.hasOwnProperty.call(p, 'important'), - ) + ? sameProperties.filter((p) => !('important' in p)) : sameProperties.slice(0, -1); overriddenProperties.map((p) => p.remove()); }, }; -}; +} + +creator.postcss = true as const; -module.exports.postcss = true; +export default creator; diff --git a/packages/docusaurus-cssnano-preset/tsconfig.json b/packages/docusaurus-cssnano-preset/tsconfig.json new file mode 100644 index 000000000000..80e43e9813ef --- /dev/null +++ b/packages/docusaurus-cssnano-preset/tsconfig.json @@ -0,0 +1,13 @@ +{ + "extends": "../../tsconfig.json", + "compilerOptions": { + "noEmit": false, + "incremental": true, + "tsBuildInfoFile": "./lib/.tsbuildinfo", + "module": "commonjs", + "rootDir": "src", + "outDir": "lib" + }, + "include": ["src"], + "exclude": ["**/__tests__/**"] +} diff --git a/packages/docusaurus-logger/.npmignore b/packages/docusaurus-logger/.npmignore index f2b994d4e359..03c9ae1e1b54 100644 --- a/packages/docusaurus-logger/.npmignore +++ b/packages/docusaurus-logger/.npmignore @@ -1,4 +1,3 @@ -copyUntypedFiles.mjs -.tsbuildinfo +.tsbuildinfo* tsconfig* __tests__ diff --git a/packages/docusaurus-logger/tsconfig.json b/packages/docusaurus-logger/tsconfig.json index aee99fc0f38e..7807612b51a5 100644 --- a/packages/docusaurus-logger/tsconfig.json +++ b/packages/docusaurus-logger/tsconfig.json @@ -1,11 +1,15 @@ { "extends": "../../tsconfig.json", "compilerOptions": { + "noEmit": false, "incremental": true, "tsBuildInfoFile": "./lib/.tsbuildinfo", "sourceMap": true, "declarationMap": true, + "module": "commonjs", "rootDir": "src", "outDir": "lib" - } + }, + "include": ["src"], + "exclude": ["**/__tests__/**"] } diff --git a/packages/docusaurus-mdx-loader/.npmignore b/packages/docusaurus-mdx-loader/.npmignore index f2b994d4e359..03c9ae1e1b54 100644 --- a/packages/docusaurus-mdx-loader/.npmignore +++ b/packages/docusaurus-mdx-loader/.npmignore @@ -1,4 +1,3 @@ -copyUntypedFiles.mjs -.tsbuildinfo +.tsbuildinfo* tsconfig* __tests__ diff --git a/packages/docusaurus-mdx-loader/package.json b/packages/docusaurus-mdx-loader/package.json index c05708cd9f4b..b071b9732ba3 100644 --- a/packages/docusaurus-mdx-loader/package.json +++ b/packages/docusaurus-mdx-loader/package.json @@ -18,8 +18,8 @@ }, "license": "MIT", "dependencies": { - "@babel/parser": "^7.17.10", - "@babel/traverse": "^7.17.10", + "@babel/parser": "^7.18.0", + "@babel/traverse": "^7.18.0", "@docusaurus/logger": "2.0.0-beta.20", "@docusaurus/utils": "2.0.0-beta.20", "@mdx-js/mdx": "^1.6.22", diff --git a/packages/docusaurus-mdx-loader/src/loader.ts b/packages/docusaurus-mdx-loader/src/loader.ts index 68c3f55f904b..88fa1ecd5bdc 100644 --- a/packages/docusaurus-mdx-loader/src/loader.ts +++ b/packages/docusaurus-mdx-loader/src/loader.ts @@ -6,21 +6,23 @@ */ import fs from 'fs-extra'; -import {createCompiler} from '@mdx-js/mdx'; import logger from '@docusaurus/logger'; -import emoji from 'remark-emoji'; import { parseFrontMatter, parseMarkdownContentTitle, escapePath, getFileLoaderUtils, } from '@docusaurus/utils'; +import {createCompiler} from '@mdx-js/mdx'; +import emoji from 'remark-emoji'; import stringifyObject from 'stringify-object'; + import headings from './remark/headings'; import toc from './remark/toc'; import unwrapMdxCodeBlocks from './remark/unwrapMdxCodeBlocks'; import transformImage from './remark/transformImage'; import transformLinks from './remark/transformLinks'; + import type {LoaderContext} from 'webpack'; import type {Processor, Plugin} from 'unified'; @@ -90,8 +92,12 @@ async function readMetadataPath(metadataPath: string) { * * `{image: "./myImage.png"}` => `{image: require("./myImage.png")}` */ -function createAssetsExportCode(assets: {[key: string]: unknown}) { - if (Object.keys(assets).length === 0) { +function createAssetsExportCode(assets: unknown) { + if ( + typeof assets !== 'object' || + !assets || + Object.keys(assets).length === 0 + ) { return 'undefined'; } @@ -99,7 +105,7 @@ function createAssetsExportCode(assets: {[key: string]: unknown}) { function createAssetValueCode(assetValue: unknown): string | undefined { if (Array.isArray(assetValue)) { const arrayItemCodes = assetValue.map( - (item) => createAssetValueCode(item) ?? 'undefined', + (item: unknown) => createAssetValueCode(item) ?? 'undefined', ); return `[${arrayItemCodes.join(', ')}]`; } @@ -117,7 +123,7 @@ function createAssetsExportCode(assets: {[key: string]: unknown}) { const assetEntries = Object.entries(assets); const codeLines = assetEntries - .map(([key, value]) => { + .map(([key, value]: [string, unknown]) => { const assetRequireCode = createAssetValueCode(value); return assetRequireCode ? `"${key}": ${assetRequireCode},` : undefined; }) @@ -225,7 +231,7 @@ ${JSON.stringify(frontMatter, null, 2)}`; : undefined; const metadata = metadataJsonString - ? JSON.parse(metadataJsonString) + ? (JSON.parse(metadataJsonString) as {[key: string]: unknown}) : undefined; const assets = diff --git a/packages/docusaurus-mdx-loader/src/remark/headings/__tests__/index.test.ts b/packages/docusaurus-mdx-loader/src/remark/headings/__tests__/index.test.ts index 2f9683e6e8de..f671d6f517f8 100644 --- a/packages/docusaurus-mdx-loader/src/remark/headings/__tests__/index.test.ts +++ b/packages/docusaurus-mdx-loader/src/remark/headings/__tests__/index.test.ts @@ -13,13 +13,14 @@ import removePosition from 'unist-util-remove-position'; import toString from 'mdast-util-to-string'; import visit from 'unist-util-visit'; import slug from '../index'; +import type {Plugin} from 'unified'; -function process(doc, plugins = []) { +function process(doc: string, plugins: Plugin[] = []) { const processor = remark().use({plugins: [...plugins, slug]}); return removePosition(processor.runSync(processor.parse(doc)), true); } -function heading(label, id) { +function heading(label: string, id: string) { return u( 'heading', {depth: 2, data: {id, hProperties: {id}}}, diff --git a/packages/docusaurus-mdx-loader/src/remark/toc/index.ts b/packages/docusaurus-mdx-loader/src/remark/toc/index.ts index b0a888c0790d..1850a2b9c7a4 100644 --- a/packages/docusaurus-mdx-loader/src/remark/toc/index.ts +++ b/packages/docusaurus-mdx-loader/src/remark/toc/index.ts @@ -6,13 +6,13 @@ */ import {parse, type ParserOptions} from '@babel/parser'; -import type {Identifier} from '@babel/types'; import traverse from '@babel/traverse'; import stringifyObject from 'stringify-object'; import toString from 'mdast-util-to-string'; import visit from 'unist-util-visit'; import {toValue} from '../utils'; +import type {Identifier} from '@babel/types'; import type {TOCItem} from '../..'; import type {Node, Parent} from 'unist'; import type {Heading, Literal} from 'mdast'; diff --git a/packages/docusaurus-mdx-loader/src/remark/transformImage/index.ts b/packages/docusaurus-mdx-loader/src/remark/transformImage/index.ts index 691c42703922..d9608d13ed07 100644 --- a/packages/docusaurus-mdx-loader/src/remark/transformImage/index.ts +++ b/packages/docusaurus-mdx-loader/src/remark/transformImage/index.ts @@ -5,6 +5,11 @@ * LICENSE file in the root directory of this source tree. */ +import path from 'path'; +import url from 'url'; +import fs from 'fs-extra'; +import {promisify} from 'util'; +import logger from '@docusaurus/logger'; import { toMessageRelativeFilePath, posixPath, @@ -13,15 +18,10 @@ import { findAsyncSequential, } from '@docusaurus/utils'; import visit from 'unist-util-visit'; -import path from 'path'; -import url from 'url'; -import fs from 'fs-extra'; import escapeHtml from 'escape-html'; import sizeOf from 'image-size'; -import {promisify} from 'util'; import type {Transformer} from 'unified'; import type {Image, Literal} from 'mdast'; -import logger from '@docusaurus/logger'; const { loaders: {inlineMarkdownImageFileLoader}, diff --git a/packages/docusaurus-mdx-loader/src/remark/transformLinks/index.ts b/packages/docusaurus-mdx-loader/src/remark/transformLinks/index.ts index 24a04805a89b..22d52587e1fb 100644 --- a/packages/docusaurus-mdx-loader/src/remark/transformLinks/index.ts +++ b/packages/docusaurus-mdx-loader/src/remark/transformLinks/index.ts @@ -5,6 +5,9 @@ * LICENSE file in the root directory of this source tree. */ +import path from 'path'; +import url from 'url'; +import fs from 'fs-extra'; import { toMessageRelativeFilePath, posixPath, @@ -13,9 +16,6 @@ import { findAsyncSequential, } from '@docusaurus/utils'; import visit from 'unist-util-visit'; -import path from 'path'; -import url from 'url'; -import fs from 'fs-extra'; import escapeHtml from 'escape-html'; import {stringifyContent} from '../utils'; import type {Transformer} from 'unified'; diff --git a/packages/docusaurus-mdx-loader/tsconfig.json b/packages/docusaurus-mdx-loader/tsconfig.json index 4cc153c7f158..7807612b51a5 100644 --- a/packages/docusaurus-mdx-loader/tsconfig.json +++ b/packages/docusaurus-mdx-loader/tsconfig.json @@ -1,12 +1,15 @@ { "extends": "../../tsconfig.json", "compilerOptions": { + "noEmit": false, "incremental": true, "tsBuildInfoFile": "./lib/.tsbuildinfo", "sourceMap": true, "declarationMap": true, + "module": "commonjs", "rootDir": "src", "outDir": "lib" }, - "include": ["src"] + "include": ["src"], + "exclude": ["**/__tests__/**"] } diff --git a/packages/docusaurus-migrate/.npmignore b/packages/docusaurus-migrate/.npmignore index ba8304029eb7..e4132af42172 100644 --- a/packages/docusaurus-migrate/.npmignore +++ b/packages/docusaurus-migrate/.npmignore @@ -1,5 +1,4 @@ -copyUntypedFiles.mjs -.tsbuildinfo +.tsbuildinfo* tsconfig* __tests__ diff --git a/packages/docusaurus-migrate/bin/index.mjs b/packages/docusaurus-migrate/bin/index.mjs index baf72762aeb7..769c5e9e3c08 100755 --- a/packages/docusaurus-migrate/bin/index.mjs +++ b/packages/docusaurus-migrate/bin/index.mjs @@ -8,11 +8,11 @@ // @ts-check +import path from 'path'; +import {createRequire} from 'module'; import logger from '@docusaurus/logger'; import semver from 'semver'; import cli from 'commander'; -import path from 'path'; -import {createRequire} from 'module'; const moduleRequire = createRequire(import.meta.url); const requiredVersion = moduleRequire('../package.json').engines.node; diff --git a/packages/docusaurus-migrate/package.json b/packages/docusaurus-migrate/package.json index 475dd592c6ad..9d43bdcf7a73 100644 --- a/packages/docusaurus-migrate/package.json +++ b/packages/docusaurus-migrate/package.json @@ -7,8 +7,8 @@ "node": ">=14" }, "scripts": { - "build": "tsc -p tsconfig.build.json", - "watch": "tsc -p tsconfig.build.json --watch" + "build": "tsc --build", + "watch": "tsc --build --watch" }, "repository": { "type": "git", @@ -22,7 +22,7 @@ "docusaurus-migrate": "bin/index.mjs" }, "dependencies": { - "@babel/preset-env": "^7.17.10", + "@babel/preset-env": "^7.18.0", "@docusaurus/logger": "2.0.0-beta.20", "@docusaurus/utils": "2.0.0-beta.20", "@mapbox/hast-util-to-jsx": "^2.0.0", diff --git a/packages/docusaurus-migrate/src/__tests__/index.test.ts b/packages/docusaurus-migrate/src/__tests__/index.test.ts index f4516276d2d9..8eea0cd15849 100644 --- a/packages/docusaurus-migrate/src/__tests__/index.test.ts +++ b/packages/docusaurus-migrate/src/__tests__/index.test.ts @@ -6,10 +6,10 @@ */ import {jest} from '@jest/globals'; -import {migrateDocusaurusProject} from '../index'; import path from 'path'; import fs from 'fs-extra'; import {posixPath} from '@docusaurus/utils'; +import {migrateDocusaurusProject} from '../index'; async function testMigration(siteDir: string, newDir: string) { const writeMock = jest.spyOn(fs, 'outputFile').mockImplementation(() => {}); diff --git a/packages/docusaurus-migrate/src/index.ts b/packages/docusaurus-migrate/src/index.ts index e1e0bcf4d665..81f31e6b874c 100644 --- a/packages/docusaurus-migrate/src/index.ts +++ b/packages/docusaurus-migrate/src/index.ts @@ -5,22 +5,23 @@ * LICENSE file in the root directory of this source tree. */ +import path from 'path'; import fs from 'fs-extra'; -import importFresh from 'import-fresh'; import logger from '@docusaurus/logger'; import {Globby} from '@docusaurus/utils'; +import importFresh from 'import-fresh'; import Color from 'color'; +import extractMetadata, {shouldQuotifyFrontMatter} from './frontMatter'; +import migratePage from './transform'; +import sanitizeMD from './sanitizeMD'; + import type { SidebarEntry, SidebarEntries, VersionOneConfig, VersionTwoConfig, } from './types'; -import extractMetadata, {shouldQuotifyFrontMatter} from './frontMatter'; -import migratePage from './transform'; -import sanitizeMD from './sanitizeMD'; -import path from 'path'; const DOCUSAURUS_VERSION = (importFresh('../package.json') as {version: string}) .version; diff --git a/packages/docusaurus-migrate/tsconfig.build.json b/packages/docusaurus-migrate/tsconfig.build.json index 358fdb6f6e60..e43e58accad2 100644 --- a/packages/docusaurus-migrate/tsconfig.build.json +++ b/packages/docusaurus-migrate/tsconfig.build.json @@ -1,10 +1,14 @@ { "extends": "../../tsconfig.json", "compilerOptions": { + "noEmit": false, + "composite": true, "incremental": true, "tsBuildInfoFile": "./lib/.tsbuildinfo", + "module": "commonjs", "rootDir": "src", "outDir": "lib" }, - "include": ["src"] + "include": ["src"], + "exclude": ["**/__tests__/**"] } diff --git a/packages/docusaurus-migrate/tsconfig.json b/packages/docusaurus-migrate/tsconfig.json index 419de04867a2..4c04aae29fd9 100644 --- a/packages/docusaurus-migrate/tsconfig.json +++ b/packages/docusaurus-migrate/tsconfig.json @@ -1,11 +1,12 @@ -// For editor typechecking; includes bin { - "extends": "./tsconfig.build.json", + "extends": "../../tsconfig.json", + "references": [{"path": "./tsconfig.build.json"}], "compilerOptions": { "noEmit": true, "module": "esnext", "allowJs": true, "rootDir": "." }, - "include": ["src", "bin"] + "include": ["bin"], + "exclude": ["**/__tests__/**"] } diff --git a/packages/docusaurus-module-type-aliases/src/index.d.ts b/packages/docusaurus-module-type-aliases/src/index.d.ts index f1e4a003e097..ccb4bf5706fc 100644 --- a/packages/docusaurus-module-type-aliases/src/index.d.ts +++ b/packages/docusaurus-module-type-aliases/src/index.d.ts @@ -35,9 +35,11 @@ declare module '@generated/registry' { declare module '@generated/routes' { import type {RouteConfig as RRRouteConfig} from 'react-router-config'; + import type Loadable from 'react-loadable'; type RouteConfig = RRRouteConfig & { path: string; + component: ReturnType; }; const routes: RouteConfig[]; export default routes; @@ -136,8 +138,8 @@ declare module '@docusaurus/ErrorBoundary' { } declare module '@docusaurus/Head' { - import type {HelmetProps} from 'react-helmet-async'; import type {ReactNode} from 'react'; + import type {HelmetProps} from 'react-helmet-async'; export type Props = HelmetProps & {children: ReactNode}; diff --git a/packages/docusaurus-plugin-client-redirects/.npmignore b/packages/docusaurus-plugin-client-redirects/.npmignore index f2b994d4e359..03c9ae1e1b54 100644 --- a/packages/docusaurus-plugin-client-redirects/.npmignore +++ b/packages/docusaurus-plugin-client-redirects/.npmignore @@ -1,4 +1,3 @@ -copyUntypedFiles.mjs -.tsbuildinfo +.tsbuildinfo* tsconfig* __tests__ diff --git a/packages/docusaurus-plugin-client-redirects/src/__tests__/collectRedirects.test.ts b/packages/docusaurus-plugin-client-redirects/src/__tests__/collectRedirects.test.ts index 266b36911ee3..fc82c12a37fa 100644 --- a/packages/docusaurus-plugin-client-redirects/src/__tests__/collectRedirects.test.ts +++ b/packages/docusaurus-plugin-client-redirects/src/__tests__/collectRedirects.test.ts @@ -5,12 +5,12 @@ * LICENSE file in the root directory of this source tree. */ -import type {PluginContext} from '../types'; -import collectRedirects from '../collectRedirects'; -import {validateOptions} from '../options'; import {removeTrailingSlash} from '@docusaurus/utils'; import {normalizePluginOptions} from '@docusaurus/utils-validation'; +import collectRedirects from '../collectRedirects'; +import {validateOptions} from '../options'; import type {Options} from '../options'; +import type {PluginContext} from '../types'; function createTestPluginContext( options?: Options, diff --git a/packages/docusaurus-plugin-client-redirects/src/__tests__/options.test.ts b/packages/docusaurus-plugin-client-redirects/src/__tests__/options.test.ts index 3243076acba1..1d526c351b4d 100644 --- a/packages/docusaurus-plugin-client-redirects/src/__tests__/options.test.ts +++ b/packages/docusaurus-plugin-client-redirects/src/__tests__/options.test.ts @@ -5,8 +5,8 @@ * LICENSE file in the root directory of this source tree. */ -import {validateOptions, DEFAULT_OPTIONS} from '../options'; import {normalizePluginOptions} from '@docusaurus/utils-validation'; +import {validateOptions, DEFAULT_OPTIONS} from '../options'; import type {Options} from '../options'; function testValidate(options: Options) { diff --git a/packages/docusaurus-plugin-client-redirects/src/collectRedirects.ts b/packages/docusaurus-plugin-client-redirects/src/collectRedirects.ts index 8a62cae4f4ab..fa4718eca32f 100644 --- a/packages/docusaurus-plugin-client-redirects/src/collectRedirects.ts +++ b/packages/docusaurus-plugin-client-redirects/src/collectRedirects.ts @@ -6,19 +6,18 @@ */ import _ from 'lodash'; -import type {PluginOptions, RedirectOption} from './options'; -import type {PluginContext, RedirectMetadata} from './types'; +import logger from '@docusaurus/logger'; +import { + applyTrailingSlash, + type ApplyTrailingSlashParams, +} from '@docusaurus/utils-common'; import { createFromExtensionsRedirects, createToExtensionsRedirects, } from './extensionRedirects'; import {validateRedirect} from './redirectValidation'; -import { - applyTrailingSlash, - type ApplyTrailingSlashParams, -} from '@docusaurus/utils-common'; - -import logger from '@docusaurus/logger'; +import type {PluginOptions, RedirectOption} from './options'; +import type {PluginContext, RedirectMetadata} from './types'; export default function collectRedirects( pluginContext: PluginContext, diff --git a/packages/docusaurus-plugin-client-redirects/src/createRedirectPageContent.ts b/packages/docusaurus-plugin-client-redirects/src/createRedirectPageContent.ts index b7bdd7f61c6d..b5d0a21141ff 100644 --- a/packages/docusaurus-plugin-client-redirects/src/createRedirectPageContent.ts +++ b/packages/docusaurus-plugin-client-redirects/src/createRedirectPageContent.ts @@ -5,9 +5,9 @@ * LICENSE file in the root directory of this source tree. */ +import _ from 'lodash'; import * as eta from 'eta'; import redirectPageTemplate from './templates/redirectPage.template.html'; -import _ from 'lodash'; const getCompiledRedirectPageTemplate = _.memoize(() => eta.compile(redirectPageTemplate.trim()), diff --git a/packages/docusaurus-plugin-client-redirects/src/index.ts b/packages/docusaurus-plugin-client-redirects/src/index.ts index 9bfac10d9498..78d117c7ca28 100644 --- a/packages/docusaurus-plugin-client-redirects/src/index.ts +++ b/packages/docusaurus-plugin-client-redirects/src/index.ts @@ -5,16 +5,15 @@ * LICENSE file in the root directory of this source tree. */ -import type {LoadContext, Plugin} from '@docusaurus/types'; -import type {PluginContext, RedirectMetadata} from './types'; -import type {PluginOptions, Options} from './options'; - +import {removePrefix, addLeadingSlash} from '@docusaurus/utils'; import collectRedirects from './collectRedirects'; import writeRedirectFiles, { toRedirectFilesMetadata, type RedirectFileMetadata, } from './writeRedirectFiles'; -import {removePrefix, addLeadingSlash} from '@docusaurus/utils'; +import type {LoadContext, Plugin} from '@docusaurus/types'; +import type {PluginContext, RedirectMetadata} from './types'; +import type {PluginOptions, Options} from './options'; export default function pluginClientRedirectsPages( context: LoadContext, diff --git a/packages/docusaurus-plugin-client-redirects/src/options.ts b/packages/docusaurus-plugin-client-redirects/src/options.ts index 34891a1c9b70..72f3da3010bd 100644 --- a/packages/docusaurus-plugin-client-redirects/src/options.ts +++ b/packages/docusaurus-plugin-client-redirects/src/options.ts @@ -5,8 +5,8 @@ * LICENSE file in the root directory of this source tree. */ -import type {OptionValidationContext} from '@docusaurus/types'; import {Joi, PathnameSchema} from '@docusaurus/utils-validation'; +import type {OptionValidationContext} from '@docusaurus/types'; export type RedirectOption = { to: string; diff --git a/packages/docusaurus-plugin-client-redirects/src/redirectValidation.ts b/packages/docusaurus-plugin-client-redirects/src/redirectValidation.ts index 5f0ce5b52b46..334453274b1e 100644 --- a/packages/docusaurus-plugin-client-redirects/src/redirectValidation.ts +++ b/packages/docusaurus-plugin-client-redirects/src/redirectValidation.ts @@ -5,8 +5,8 @@ * LICENSE file in the root directory of this source tree. */ -import type {RedirectMetadata} from './types'; import {Joi, PathnameSchema} from '@docusaurus/utils-validation'; +import type {RedirectMetadata} from './types'; const RedirectSchema = Joi.object({ from: PathnameSchema.required(), diff --git a/packages/docusaurus-plugin-client-redirects/src/writeRedirectFiles.ts b/packages/docusaurus-plugin-client-redirects/src/writeRedirectFiles.ts index 3924f602143c..77a9316c829a 100644 --- a/packages/docusaurus-plugin-client-redirects/src/writeRedirectFiles.ts +++ b/packages/docusaurus-plugin-client-redirects/src/writeRedirectFiles.ts @@ -8,11 +8,12 @@ import fs from 'fs-extra'; import path from 'path'; import _ from 'lodash'; +import logger from '@docusaurus/logger'; +import {normalizeUrl} from '@docusaurus/utils'; -import type {PluginContext, RedirectMetadata} from './types'; import createRedirectPageContent from './createRedirectPageContent'; -import {normalizeUrl} from '@docusaurus/utils'; -import logger from '@docusaurus/logger'; + +import type {PluginContext, RedirectMetadata} from './types'; export type WriteFilesPluginContext = Pick; diff --git a/packages/docusaurus-plugin-client-redirects/tsconfig.json b/packages/docusaurus-plugin-client-redirects/tsconfig.json index 7b696ed3843d..80e43e9813ef 100644 --- a/packages/docusaurus-plugin-client-redirects/tsconfig.json +++ b/packages/docusaurus-plugin-client-redirects/tsconfig.json @@ -1,10 +1,13 @@ { "extends": "../../tsconfig.json", "compilerOptions": { + "noEmit": false, "incremental": true, "tsBuildInfoFile": "./lib/.tsbuildinfo", + "module": "commonjs", "rootDir": "src", - "outDir": "lib", - "typeRoots": ["./types", "./node_modules/@types"] - } + "outDir": "lib" + }, + "include": ["src"], + "exclude": ["**/__tests__/**"] } diff --git a/packages/docusaurus-plugin-content-blog/.npmignore b/packages/docusaurus-plugin-content-blog/.npmignore index f2b994d4e359..03c9ae1e1b54 100644 --- a/packages/docusaurus-plugin-content-blog/.npmignore +++ b/packages/docusaurus-plugin-content-blog/.npmignore @@ -1,4 +1,3 @@ -copyUntypedFiles.mjs -.tsbuildinfo +.tsbuildinfo* tsconfig* __tests__ diff --git a/packages/docusaurus-plugin-content-blog/package.json b/packages/docusaurus-plugin-content-blog/package.json index aaf8a68635f6..5d0dbade229e 100644 --- a/packages/docusaurus-plugin-content-blog/package.json +++ b/packages/docusaurus-plugin-content-blog/package.json @@ -24,7 +24,7 @@ "@docusaurus/utils": "2.0.0-beta.20", "@docusaurus/utils-common": "2.0.0-beta.20", "@docusaurus/utils-validation": "2.0.0-beta.20", - "cheerio": "^1.0.0-rc.10", + "cheerio": "^1.0.0-rc.11", "feed": "^4.2.2", "fs-extra": "^10.1.0", "lodash": "^4.17.21", diff --git a/packages/docusaurus-plugin-content-blog/src/__tests__/authors.test.ts b/packages/docusaurus-plugin-content-blog/src/__tests__/authors.test.ts index 67dd4571eae7..19515459a656 100644 --- a/packages/docusaurus-plugin-content-blog/src/__tests__/authors.test.ts +++ b/packages/docusaurus-plugin-content-blog/src/__tests__/authors.test.ts @@ -5,13 +5,13 @@ * LICENSE file in the root directory of this source tree. */ +import path from 'path'; import { type AuthorsMap, getAuthorsMap, getBlogPostAuthors, validateAuthorsMap, } from '../authors'; -import path from 'path'; describe('getBlogPostAuthors', () => { it('can read no authors', () => { diff --git a/packages/docusaurus-plugin-content-blog/src/__tests__/blogUtils.test.ts b/packages/docusaurus-plugin-content-blog/src/__tests__/blogUtils.test.ts index 5460a4440f9f..1d9cafef920f 100644 --- a/packages/docusaurus-plugin-content-blog/src/__tests__/blogUtils.test.ts +++ b/packages/docusaurus-plugin-content-blog/src/__tests__/blogUtils.test.ts @@ -6,6 +6,8 @@ */ import {jest} from '@jest/globals'; +import fs from 'fs-extra'; +import path from 'path'; import { truncate, parseBlogFileName, @@ -14,13 +16,8 @@ import { paginateBlogPosts, type LinkifyParams, } from '../blogUtils'; -import fs from 'fs-extra'; -import path from 'path'; -import type { - BlogBrokenMarkdownLink, - BlogContentPaths, - BlogPost, -} from '../types'; +import type {BlogBrokenMarkdownLink, BlogContentPaths} from '../types'; +import type {BlogPost} from '@docusaurus/plugin-content-blog'; describe('truncate', () => { it('truncates texts', () => { diff --git a/packages/docusaurus-plugin-content-blog/src/__tests__/feed.test.ts b/packages/docusaurus-plugin-content-blog/src/__tests__/feed.test.ts index f7d31a7dbbb0..48c3395f728b 100644 --- a/packages/docusaurus-plugin-content-blog/src/__tests__/feed.test.ts +++ b/packages/docusaurus-plugin-content-blog/src/__tests__/feed.test.ts @@ -8,11 +8,11 @@ import {jest} from '@jest/globals'; import path from 'path'; import fs from 'fs-extra'; +import {DEFAULT_OPTIONS} from '../options'; +import {generateBlogPosts} from '../blogUtils'; import {createBlogFeedFiles} from '../feed'; import type {LoadContext, I18n} from '@docusaurus/types'; import type {BlogContentPaths} from '../types'; -import {DEFAULT_OPTIONS} from '../options'; -import {generateBlogPosts} from '../blogUtils'; import type {PluginOptions} from '@docusaurus/plugin-content-blog'; const DefaultI18N: I18n = { diff --git a/packages/docusaurus-plugin-content-blog/src/__tests__/frontMatter.test.ts b/packages/docusaurus-plugin-content-blog/src/__tests__/frontMatter.test.ts index cb1020c680ef..36cc680df0e0 100644 --- a/packages/docusaurus-plugin-content-blog/src/__tests__/frontMatter.test.ts +++ b/packages/docusaurus-plugin-content-blog/src/__tests__/frontMatter.test.ts @@ -5,8 +5,8 @@ * LICENSE file in the root directory of this source tree. */ -import {validateBlogPostFrontMatter} from '../frontMatter'; import escapeStringRegexp from 'escape-string-regexp'; +import {validateBlogPostFrontMatter} from '../frontMatter'; import type {BlogPostFrontMatter} from '@docusaurus/plugin-content-blog'; // TODO this abstraction reduce verbosity but it makes it harder to debug diff --git a/packages/docusaurus-plugin-content-blog/src/__tests__/index.test.ts b/packages/docusaurus-plugin-content-blog/src/__tests__/index.test.ts index 7d47e0027ab6..11b33cd2a183 100644 --- a/packages/docusaurus-plugin-content-blog/src/__tests__/index.test.ts +++ b/packages/docusaurus-plugin-content-blog/src/__tests__/index.test.ts @@ -7,13 +7,13 @@ import {jest} from '@jest/globals'; import path from 'path'; -import pluginContentBlog from '../index'; -import type {DocusaurusConfig, LoadContext, I18n} from '@docusaurus/types'; -import {validateOptions} from '../options'; -import type {BlogPost} from '../types'; import {normalizePluginOptions} from '@docusaurus/utils-validation'; import {posixPath, getFileCommitDate} from '@docusaurus/utils'; +import pluginContentBlog from '../index'; +import {validateOptions} from '../options'; +import type {DocusaurusConfig, LoadContext, I18n} from '@docusaurus/types'; import type { + BlogPost, PluginOptions, EditUrlFunction, } from '@docusaurus/plugin-content-blog'; diff --git a/packages/docusaurus-plugin-content-blog/src/__tests__/options.test.ts b/packages/docusaurus-plugin-content-blog/src/__tests__/options.test.ts index 8c8cbf92172c..dd2e562bdabc 100644 --- a/packages/docusaurus-plugin-content-blog/src/__tests__/options.test.ts +++ b/packages/docusaurus-plugin-content-blog/src/__tests__/options.test.ts @@ -5,8 +5,8 @@ * LICENSE file in the root directory of this source tree. */ -import {validateOptions, DEFAULT_OPTIONS} from '../options'; import {normalizePluginOptions} from '@docusaurus/utils-validation'; +import {validateOptions, DEFAULT_OPTIONS} from '../options'; import type {Options} from '@docusaurus/plugin-content-blog'; function testValidate(options: Options) { diff --git a/packages/docusaurus-plugin-content-blog/src/__tests__/translations.test.ts b/packages/docusaurus-plugin-content-blog/src/__tests__/translations.test.ts index 840a3af4d359..62442bbf8151 100644 --- a/packages/docusaurus-plugin-content-blog/src/__tests__/translations.test.ts +++ b/packages/docusaurus-plugin-content-blog/src/__tests__/translations.test.ts @@ -5,11 +5,14 @@ * LICENSE file in the root directory of this source tree. */ -import type {BlogPost, BlogContent} from '../types'; +import {updateTranslationFileMessages} from '@docusaurus/utils'; import {getTranslationFiles, translateContent} from '../translations'; import {DEFAULT_OPTIONS} from '../options'; -import {updateTranslationFileMessages} from '@docusaurus/utils'; -import type {PluginOptions} from '@docusaurus/plugin-content-blog'; +import type { + PluginOptions, + BlogPost, + BlogContent, +} from '@docusaurus/plugin-content-blog'; const sampleBlogOptions: PluginOptions = { ...DEFAULT_OPTIONS, diff --git a/packages/docusaurus-plugin-content-blog/src/authors.ts b/packages/docusaurus-plugin-content-blog/src/authors.ts index e8e2be323127..cf3bbe5c8522 100644 --- a/packages/docusaurus-plugin-content-blog/src/authors.ts +++ b/packages/docusaurus-plugin-content-blog/src/authors.ts @@ -5,9 +5,9 @@ * LICENSE file in the root directory of this source tree. */ -import type {BlogContentPaths} from './types'; import {getDataFileData} from '@docusaurus/utils'; import {Joi, URISchema} from '@docusaurus/utils-validation'; +import type {BlogContentPaths} from './types'; import type { Author, BlogPostFrontMatter, diff --git a/packages/docusaurus-plugin-content-blog/src/blogUtils.ts b/packages/docusaurus-plugin-content-blog/src/blogUtils.ts index 5daf3983e09a..370ddeb50aa3 100644 --- a/packages/docusaurus-plugin-content-blog/src/blogUtils.ts +++ b/packages/docusaurus-plugin-content-blog/src/blogUtils.ts @@ -7,9 +7,9 @@ import fs from 'fs-extra'; import path from 'path'; -import readingTime from 'reading-time'; import _ from 'lodash'; -import type {BlogContentPaths, BlogMarkdownLoaderOptions} from './types'; +import logger from '@docusaurus/logger'; +import readingTime from 'reading-time'; import { parseMarkdownString, normalizeUrl, @@ -24,10 +24,9 @@ import { getFileCommitDate, getContentPathList, } from '@docusaurus/utils'; -import type {LoadContext} from '@docusaurus/types'; import {validateBlogPostFrontMatter} from './frontMatter'; import {type AuthorsMap, getAuthorsMap, getBlogPostAuthors} from './authors'; -import logger from '@docusaurus/logger'; +import type {LoadContext} from '@docusaurus/types'; import type { PluginOptions, ReadingTimeFunction, @@ -35,6 +34,7 @@ import type { BlogTags, BlogPaginated, } from '@docusaurus/plugin-content-blog'; +import type {BlogContentPaths, BlogMarkdownLoaderOptions} from './types'; export function truncate(fileString: string, truncateMarker: RegExp): string { return fileString.split(truncateMarker, 1).shift()!; diff --git a/packages/docusaurus-plugin-content-blog/src/feed.ts b/packages/docusaurus-plugin-content-blog/src/feed.ts index 390d453f480c..222fcb84b2b5 100644 --- a/packages/docusaurus-plugin-content-blog/src/feed.ts +++ b/packages/docusaurus-plugin-content-blog/src/feed.ts @@ -5,20 +5,20 @@ * LICENSE file in the root directory of this source tree. */ +import path from 'path'; +import fs from 'fs-extra'; +import logger from '@docusaurus/logger'; import {Feed, type Author as FeedAuthor, type Item as FeedItem} from 'feed'; import {normalizeUrl, readOutputHTMLFile} from '@docusaurus/utils'; +import {blogPostContainerID} from '@docusaurus/utils-common'; import {load as cheerioLoad} from 'cheerio'; import type {DocusaurusConfig} from '@docusaurus/types'; -import path from 'path'; -import fs from 'fs-extra'; import type { FeedType, PluginOptions, Author, BlogPost, } from '@docusaurus/plugin-content-blog'; -import {blogPostContainerID} from '@docusaurus/utils-common'; -import logger from '@docusaurus/logger'; async function generateBlogFeed({ blogPosts, diff --git a/packages/docusaurus-plugin-content-blog/src/index.ts b/packages/docusaurus-plugin-content-blog/src/index.ts index 3b19b9bbab2e..a3dddc2404f5 100644 --- a/packages/docusaurus-plugin-content-blog/src/index.ts +++ b/packages/docusaurus-plugin-content-blog/src/index.ts @@ -6,8 +6,6 @@ */ import path from 'path'; -import admonitions from 'remark-admonitions'; -import footnoteIDFixer from './remark/footnoteIDFixer'; import { normalizeUrl, docuHash, @@ -23,17 +21,19 @@ import { type TagsListItem, type TagModule, } from '@docusaurus/utils'; -import {translateContent, getTranslationFiles} from './translations'; - -import type {BlogContentPaths, BlogMarkdownLoaderOptions} from './types'; -import type {LoadContext, Plugin, HtmlTags} from '@docusaurus/types'; +import admonitions from 'remark-admonitions'; import { generateBlogPosts, getSourceToPermalink, getBlogTags, paginateBlogPosts, } from './blogUtils'; +import footnoteIDFixer from './remark/footnoteIDFixer'; +import {translateContent, getTranslationFiles} from './translations'; import {createBlogFeedFiles} from './feed'; + +import type {BlogContentPaths, BlogMarkdownLoaderOptions} from './types'; +import type {LoadContext, Plugin, HtmlTags} from '@docusaurus/types'; import type { PluginOptions, BlogPostFrontMatter, diff --git a/packages/docusaurus-plugin-content-blog/src/options.ts b/packages/docusaurus-plugin-content-blog/src/options.ts index baf927b8c671..f6fa74e726bc 100644 --- a/packages/docusaurus-plugin-content-blog/src/options.ts +++ b/packages/docusaurus-plugin-content-blog/src/options.ts @@ -13,7 +13,11 @@ import { URISchema, } from '@docusaurus/utils-validation'; import {GlobExcludeDefault} from '@docusaurus/utils'; -import type {PluginOptions, Options} from '@docusaurus/plugin-content-blog'; +import type { + PluginOptions, + Options, + FeedType, +} from '@docusaurus/plugin-content-blog'; import type {OptionValidationContext} from '@docusaurus/types'; export const DEFAULT_OPTIONS: PluginOptions = { @@ -101,7 +105,7 @@ const PluginOptionSchema = Joi.object({ Joi.alternatives().conditional( Joi.string().equal('all', 'rss', 'atom', 'json'), { - then: Joi.custom((val) => + then: Joi.custom((val: FeedType | 'all') => val === 'all' ? ['rss', 'atom', 'json'] : [val], ), }, diff --git a/packages/docusaurus-plugin-content-blog/src/plugin-content-blog.d.ts b/packages/docusaurus-plugin-content-blog/src/plugin-content-blog.d.ts index d74bba9fc274..e8a8697fa8cd 100644 --- a/packages/docusaurus-plugin-content-blog/src/plugin-content-blog.d.ts +++ b/packages/docusaurus-plugin-content-blog/src/plugin-content-blog.d.ts @@ -538,11 +538,11 @@ declare module '@theme/BlogTagsListPage' { } declare module '@theme/BlogTagsPostsPage' { + import type {Content} from '@theme/BlogPostPage'; import type { BlogSidebar, BlogPaginatedMetadata, } from '@docusaurus/plugin-content-blog'; - import type {Content} from '@theme/BlogPostPage'; import type {TagModule} from '@docusaurus/utils'; export interface Props { diff --git a/packages/docusaurus-plugin-content-blog/tsconfig.json b/packages/docusaurus-plugin-content-blog/tsconfig.json index f5902ba1089b..80e43e9813ef 100644 --- a/packages/docusaurus-plugin-content-blog/tsconfig.json +++ b/packages/docusaurus-plugin-content-blog/tsconfig.json @@ -1,9 +1,13 @@ { "extends": "../../tsconfig.json", "compilerOptions": { + "noEmit": false, "incremental": true, "tsBuildInfoFile": "./lib/.tsbuildinfo", + "module": "commonjs", "rootDir": "src", "outDir": "lib" - } + }, + "include": ["src"], + "exclude": ["**/__tests__/**"] } diff --git a/packages/docusaurus-plugin-content-docs/.npmignore b/packages/docusaurus-plugin-content-docs/.npmignore index f2b994d4e359..03c9ae1e1b54 100644 --- a/packages/docusaurus-plugin-content-docs/.npmignore +++ b/packages/docusaurus-plugin-content-docs/.npmignore @@ -1,4 +1,3 @@ -copyUntypedFiles.mjs -.tsbuildinfo +.tsbuildinfo* tsconfig* __tests__ diff --git a/packages/docusaurus-plugin-content-docs/package.json b/packages/docusaurus-plugin-content-docs/package.json index 697fcf7224ea..bf59cd020096 100644 --- a/packages/docusaurus-plugin-content-docs/package.json +++ b/packages/docusaurus-plugin-content-docs/package.json @@ -12,8 +12,8 @@ }, "types": "src/plugin-content-docs.d.ts", "scripts": { - "build": "tsc", - "watch": "tsc --watch" + "build": "tsc --build", + "watch": "tsc --build --watch" }, "publishConfig": { "access": "public" diff --git a/packages/docusaurus-plugin-content-docs/src/__tests__/cli.test.ts b/packages/docusaurus-plugin-content-docs/src/__tests__/cli.test.ts index bd0db4e0ad5a..ec29bdcf8b87 100644 Binary files a/packages/docusaurus-plugin-content-docs/src/__tests__/cli.test.ts and b/packages/docusaurus-plugin-content-docs/src/__tests__/cli.test.ts differ diff --git a/packages/docusaurus-plugin-content-docs/src/__tests__/docs.test.ts b/packages/docusaurus-plugin-content-docs/src/__tests__/docs.test.ts index bceca516cbfc..3e0f09010925 100644 --- a/packages/docusaurus-plugin-content-docs/src/__tests__/docs.test.ts +++ b/packages/docusaurus-plugin-content-docs/src/__tests__/docs.test.ts @@ -8,6 +8,8 @@ import {jest} from '@jest/globals'; import path from 'path'; import {loadContext} from '@docusaurus/core/src/server/index'; +import {createSlugger, posixPath, DEFAULT_PLUGIN_ID} from '@docusaurus/utils'; +import {createSidebarsUtils} from '../sidebars/utils'; import { processDocMetadata, readVersionDocs, @@ -17,8 +19,9 @@ import { type DocEnv, } from '../docs'; import {loadSidebars} from '../sidebars'; -import type {Sidebars} from '../sidebars/types'; import {readVersionsMetadata} from '../versions'; +import {DEFAULT_OPTIONS} from '../options'; +import type {Sidebars} from '../sidebars/types'; import type {DocFile} from '../types'; import type { MetadataOptions, @@ -29,10 +32,7 @@ import type { PropNavigationLink, } from '@docusaurus/plugin-content-docs'; import type {LoadContext} from '@docusaurus/types'; -import {DEFAULT_OPTIONS} from '../options'; import type {Optional} from 'utility-types'; -import {createSlugger, posixPath, DEFAULT_PLUGIN_ID} from '@docusaurus/utils'; -import {createSidebarsUtils} from '../sidebars/utils'; jest.setTimeout(15000); diff --git a/packages/docusaurus-plugin-content-docs/src/__tests__/frontMatter.test.ts b/packages/docusaurus-plugin-content-docs/src/__tests__/frontMatter.test.ts index 3a0855fe582a..6612927c2d0c 100644 --- a/packages/docusaurus-plugin-content-docs/src/__tests__/frontMatter.test.ts +++ b/packages/docusaurus-plugin-content-docs/src/__tests__/frontMatter.test.ts @@ -5,9 +5,9 @@ * LICENSE file in the root directory of this source tree. */ +import escapeStringRegexp from 'escape-string-regexp'; import {validateDocFrontMatter} from '../frontMatter'; import type {DocFrontMatter} from '@docusaurus/plugin-content-docs'; -import escapeStringRegexp from 'escape-string-regexp'; function testField(params: { prefix: string; diff --git a/packages/docusaurus-plugin-content-docs/src/__tests__/index.test.ts b/packages/docusaurus-plugin-content-docs/src/__tests__/index.test.ts index 0a0627c735a2..0d54d4bc1308 100644 --- a/packages/docusaurus-plugin-content-docs/src/__tests__/index.test.ts +++ b/packages/docusaurus-plugin-content-docs/src/__tests__/index.test.ts @@ -7,32 +7,27 @@ import {jest} from '@jest/globals'; import path from 'path'; +import fs from 'fs-extra'; +import _ from 'lodash'; import {isMatch} from 'picomatch'; import commander from 'commander'; -import _ from 'lodash'; - -import fs from 'fs-extra'; -import pluginContentDocs from '../index'; +import webpack from 'webpack'; import {loadContext} from '@docusaurus/core/src/server/index'; import {applyConfigureWebpack} from '@docusaurus/core/src/webpack/utils'; -import type {RouteConfig} from '@docusaurus/types'; -import {posixPath} from '@docusaurus/utils'; import {sortConfig} from '@docusaurus/core/src/server/plugins/routeConfig'; - -import * as cliDocs from '../cli'; -import {validateOptions} from '../options'; +import {posixPath} from '@docusaurus/utils'; import {normalizePluginOptions} from '@docusaurus/utils-validation'; -import type {LoadedVersion} from '../types'; -import type { - SidebarItem, - SidebarItemsGeneratorOption, - SidebarItemsGeneratorOptionArgs, -} from '../sidebars/types'; -import {toSidebarsProp} from '../props'; -import webpack from 'webpack'; +import pluginContentDocs from '../index'; +import {toSidebarsProp} from '../props'; import {DefaultSidebarItemsGenerator} from '../sidebars/generator'; import {DisabledSidebars} from '../sidebars'; +import * as cliDocs from '../cli'; +import {validateOptions} from '../options'; + +import type {RouteConfig} from '@docusaurus/types'; +import type {LoadedVersion} from '@docusaurus/plugin-content-docs'; +import type {SidebarItem, SidebarItemsGeneratorOption} from '../sidebars/types'; function findDocById(version: LoadedVersion, unversionedId: string) { return version.docs.find((item) => item.unversionedId === unversionedId); @@ -768,14 +763,14 @@ describe('site with custom sidebar items generator', () => { const customSidebarItemsGeneratorMock = jest.fn(async () => []); const {siteDir} = await loadSite(customSidebarItemsGeneratorMock); - const generatorArg: SidebarItemsGeneratorOptionArgs = + const generatorArg: Parameters[0] = customSidebarItemsGeneratorMock.mock.calls[0][0]; // Make test pass even if docs are in different order and paths are // absolutes function makeDeterministic( - arg: SidebarItemsGeneratorOptionArgs, - ): SidebarItemsGeneratorOptionArgs { + arg: Parameters[0], + ): Parameters[0] { return { ...arg, docs: _.orderBy(arg.docs, 'id'), diff --git a/packages/docusaurus-plugin-content-docs/src/__tests__/lastUpdate.test.ts b/packages/docusaurus-plugin-content-docs/src/__tests__/lastUpdate.test.ts index 7f3e41bd195c..47aff760539e 100644 --- a/packages/docusaurus-plugin-content-docs/src/__tests__/lastUpdate.test.ts +++ b/packages/docusaurus-plugin-content-docs/src/__tests__/lastUpdate.test.ts @@ -5,11 +5,11 @@ * LICENSE file in the root directory of this source tree. */ -import {createTempRepo} from '@testing-utils/git'; import {jest} from '@jest/globals'; import fs from 'fs-extra'; import path from 'path'; import shell from 'shelljs'; +import {createTempRepo} from '@testing-utils/git'; import {getFileLastUpdate} from '../lastUpdate'; diff --git a/packages/docusaurus-plugin-content-docs/src/__tests__/options.test.ts b/packages/docusaurus-plugin-content-docs/src/__tests__/options.test.ts index 5d5e330c50c8..bcbaccfe1144 100644 --- a/packages/docusaurus-plugin-content-docs/src/__tests__/options.test.ts +++ b/packages/docusaurus-plugin-content-docs/src/__tests__/options.test.ts @@ -5,14 +5,14 @@ * LICENSE file in the root directory of this source tree. */ -import {validateOptions, DEFAULT_OPTIONS} from '../options'; +import {GlobExcludeDefault} from '@docusaurus/utils'; import {normalizePluginOptions} from '@docusaurus/utils-validation'; +import {validateOptions, DEFAULT_OPTIONS} from '../options'; import {DefaultSidebarItemsGenerator} from '../sidebars/generator'; import { DefaultNumberPrefixParser, DisabledNumberPrefixParser, } from '../numberPrefix'; -import {GlobExcludeDefault} from '@docusaurus/utils'; import type {Options} from '@docusaurus/plugin-content-docs'; // The type of remark/rehype plugins can be function/object diff --git a/packages/docusaurus-plugin-content-docs/src/__tests__/translations.test.ts b/packages/docusaurus-plugin-content-docs/src/__tests__/translations.test.ts index 85af2ef203e0..5d098e355fb7 100644 --- a/packages/docusaurus-plugin-content-docs/src/__tests__/translations.test.ts +++ b/packages/docusaurus-plugin-content-docs/src/__tests__/translations.test.ts @@ -5,14 +5,17 @@ * LICENSE file in the root directory of this source tree. */ -import type {LoadedContent, LoadedVersion} from '../types'; +import {updateTranslationFileMessages} from '@docusaurus/utils'; import {CURRENT_VERSION_NAME} from '../constants'; import { getLoadedContentTranslationFiles, translateLoadedContent, } from '../translations'; -import type {DocMetadata} from '@docusaurus/plugin-content-docs'; -import {updateTranslationFileMessages} from '@docusaurus/utils'; +import type { + DocMetadata, + LoadedContent, + LoadedVersion, +} from '@docusaurus/plugin-content-docs'; function createSampleDoc(doc: Pick): DocMetadata { return { diff --git a/packages/docusaurus-plugin-content-docs/src/categoryGeneratedIndex.ts b/packages/docusaurus-plugin-content-docs/src/categoryGeneratedIndex.ts index 4c87e711a515..6ae97213f155 100644 --- a/packages/docusaurus-plugin-content-docs/src/categoryGeneratedIndex.ts +++ b/packages/docusaurus-plugin-content-docs/src/categoryGeneratedIndex.ts @@ -5,13 +5,13 @@ * LICENSE file in the root directory of this source tree. */ +import {type SidebarsUtils, toNavigationLink} from './sidebars/utils'; +import {createDocsByIdIndex} from './docs'; import type { CategoryGeneratedIndexMetadata, DocMetadataBase, } from '@docusaurus/plugin-content-docs'; import type {SidebarItemCategoryWithGeneratedIndex} from './sidebars/types'; -import {type SidebarsUtils, toNavigationLink} from './sidebars/utils'; -import {createDocsByIdIndex} from './docs'; function getCategoryGeneratedIndexMetadata({ category, diff --git a/packages/docusaurus-plugin-content-docs/src/cli.ts b/packages/docusaurus-plugin-content-docs/src/cli.ts index 4a84ea953089..7156d4c6e49a 100644 --- a/packages/docusaurus-plugin-content-docs/src/cli.ts +++ b/packages/docusaurus-plugin-content-docs/src/cli.ts @@ -5,6 +5,10 @@ * LICENSE file in the root directory of this source tree. */ +import fs from 'fs-extra'; +import path from 'path'; +import logger from '@docusaurus/logger'; +import {DEFAULT_PLUGIN_ID} from '@docusaurus/utils'; import { getVersionsFilePath, getVersionDocsDirPath, @@ -12,13 +16,9 @@ import { getDocsDirPathLocalized, } from './versions/files'; import {validateVersionName} from './versions/validation'; -import fs from 'fs-extra'; -import path from 'path'; -import type {PluginOptions} from '@docusaurus/plugin-content-docs'; import {loadSidebarsFileUnsafe} from './sidebars'; import {CURRENT_VERSION_NAME} from './constants'; -import {DEFAULT_PLUGIN_ID} from '@docusaurus/utils'; -import logger from '@docusaurus/logger'; +import type {PluginOptions} from '@docusaurus/plugin-content-docs'; import type {LoadContext} from '@docusaurus/types'; async function createVersionedSidebarFile({ @@ -53,7 +53,7 @@ async function createVersionedSidebarFile({ // Tests depend on non-default export for mocking. export async function cliDocsVersionCommand( - version: string, + version: unknown, {id: pluginId, path: docsPath, sidebarPath}: PluginOptions, {siteDir, i18n}: LoadContext, ): Promise { @@ -70,7 +70,7 @@ export async function cliDocsVersionCommand( } // Load existing versions. - let versions = []; + let versions: string[] = []; const versionsJSONFile = getVersionsFilePath(siteDir, pluginId); if (await fs.pathExists(versionsJSONFile)) { versions = await fs.readJSON(versionsJSONFile); diff --git a/packages/docusaurus-plugin-content-docs/src/client/__tests__/docsClientUtils.test.ts b/packages/docusaurus-plugin-content-docs/src/client/__tests__/docsClientUtils.test.ts index e663dbd43349..093aaad1db93 100644 --- a/packages/docusaurus-plugin-content-docs/src/client/__tests__/docsClientUtils.test.ts +++ b/packages/docusaurus-plugin-content-docs/src/client/__tests__/docsClientUtils.test.ts @@ -5,6 +5,7 @@ * LICENSE file in the root directory of this source tree. */ +import _ from 'lodash'; import { getActivePlugin, getLatestVersion, @@ -17,7 +18,6 @@ import type { GlobalVersion, ActivePlugin, } from '@docusaurus/plugin-content-docs/client'; -import _ from 'lodash'; describe('docsClientUtils', () => { it('getActivePlugin', () => { diff --git a/packages/docusaurus-plugin-content-docs/src/docs.ts b/packages/docusaurus-plugin-content-docs/src/docs.ts index 7f631f21c781..2ea127f99fbb 100644 --- a/packages/docusaurus-plugin-content-docs/src/docs.ts +++ b/packages/docusaurus-plugin-content-docs/src/docs.ts @@ -19,15 +19,12 @@ import { Globby, normalizeFrontMatterTags, } from '@docusaurus/utils'; -import type {LoadContext} from '@docusaurus/types'; import {getFileLastUpdate} from './lastUpdate'; -import type {DocFile} from './types'; import getSlug from './slug'; import {CURRENT_VERSION_NAME} from './constants'; import {stripPathNumberPrefixes} from './numberPrefix'; import {validateDocFrontMatter} from './frontMatter'; -import type {SidebarsUtils} from './sidebars/utils'; import {toDocNavigationLink, toNavigationLink} from './sidebars/utils'; import type { MetadataOptions, @@ -41,6 +38,9 @@ import type { DocFrontMatter, LoadedVersion, } from '@docusaurus/plugin-content-docs'; +import type {LoadContext} from '@docusaurus/types'; +import type {SidebarsUtils} from './sidebars/utils'; +import type {DocFile} from './types'; type LastUpdateOptions = Pick< PluginOptions, diff --git a/packages/docusaurus-plugin-content-docs/src/globalData.ts b/packages/docusaurus-plugin-content-docs/src/globalData.ts index c688ab2c0098..594e14c0f200 100644 --- a/packages/docusaurus-plugin-content-docs/src/globalData.ts +++ b/packages/docusaurus-plugin-content-docs/src/globalData.ts @@ -6,7 +6,6 @@ */ import _ from 'lodash'; -import type {Sidebars} from './sidebars/types'; import {getMainDocId} from './docs'; import type {FullVersion} from './types'; import type { @@ -18,6 +17,7 @@ import type { GlobalSidebar, GlobalDoc, } from '@docusaurus/plugin-content-docs/client'; +import type {Sidebars} from './sidebars/types'; function toGlobalDataDoc(doc: DocMetadata): GlobalDoc { return { diff --git a/packages/docusaurus-plugin-content-docs/src/index.ts b/packages/docusaurus-plugin-content-docs/src/index.ts index b4c72107f312..982895957382 100644 --- a/packages/docusaurus-plugin-content-docs/src/index.ts +++ b/packages/docusaurus-plugin-content-docs/src/index.ts @@ -6,7 +6,8 @@ */ import path from 'path'; - +import _ from 'lodash'; +import logger from '@docusaurus/logger'; import { normalizeUrl, docuHash, @@ -19,20 +20,15 @@ import { createSlugger, DEFAULT_PLUGIN_ID, } from '@docusaurus/utils'; -import type {LoadContext, Plugin} from '@docusaurus/types'; import {loadSidebars, resolveSidebarPathOption} from './sidebars'; import {CategoryMetadataFilenamePattern} from './sidebars/generator'; -import type {DocEnv} from './docs'; -import {readVersionDocs, processDocMetadata, addDocNavigation} from './docs'; +import { + readVersionDocs, + processDocMetadata, + addDocNavigation, + type DocEnv, +} from './docs'; import {readVersionsMetadata} from './versions'; -import type { - SourceToPermalink, - DocFile, - DocsMarkdownOption, - VersionTag, - FullVersion, -} from './types'; -import type {RuleSetRule} from 'webpack'; import {cliDocsVersionCommand} from './cli'; import {VERSIONS_JSON_FILE} from './constants'; import {toGlobalDataVersion} from './globalData'; @@ -42,9 +38,10 @@ import { translateLoadedContent, getLoadedContentTranslationFiles, } from './translations'; -import logger from '@docusaurus/logger'; import {getVersionTags} from './tags'; import {createVersionRoutes} from './routes'; +import {createSidebarsUtils} from './sidebars/utils'; + import type { PropTagsListPage, PluginOptions, @@ -54,8 +51,15 @@ import type { LoadedContent, LoadedVersion, } from '@docusaurus/plugin-content-docs'; -import {createSidebarsUtils} from './sidebars/utils'; -import _ from 'lodash'; +import type {LoadContext, Plugin} from '@docusaurus/types'; +import type { + SourceToPermalink, + DocFile, + DocsMarkdownOption, + VersionTag, + FullVersion, +} from './types'; +import type {RuleSetRule} from 'webpack'; export default async function pluginContentDocs( context: LoadContext, @@ -96,7 +100,7 @@ export default async function pluginContentDocs( .command(command) .arguments('') .description(commandDescription) - .action((version) => { + .action((version: unknown) => { cliDocsVersionCommand(version, options, context); }); }, diff --git a/packages/docusaurus-plugin-content-docs/src/markdown/__tests__/linkify.test.ts b/packages/docusaurus-plugin-content-docs/src/markdown/__tests__/linkify.test.ts index 0ca367836157..864d5a39c274 100644 --- a/packages/docusaurus-plugin-content-docs/src/markdown/__tests__/linkify.test.ts +++ b/packages/docusaurus-plugin-content-docs/src/markdown/__tests__/linkify.test.ts @@ -9,13 +9,13 @@ import {jest} from '@jest/globals'; import fs from 'fs-extra'; import path from 'path'; import {linkify} from '../linkify'; +import {VERSIONED_DOCS_DIR, CURRENT_VERSION_NAME} from '../../constants'; import type { DocsMarkdownOption, SourceToPermalink, DocBrokenMarkdownLink, } from '../../types'; import type {VersionMetadata} from '@docusaurus/plugin-content-docs'; -import {VERSIONED_DOCS_DIR, CURRENT_VERSION_NAME} from '../../constants'; function createFakeVersion({ versionName, diff --git a/packages/docusaurus-plugin-content-docs/src/markdown/linkify.ts b/packages/docusaurus-plugin-content-docs/src/markdown/linkify.ts index 704bcbd4974f..ae651cb316a0 100644 --- a/packages/docusaurus-plugin-content-docs/src/markdown/linkify.ts +++ b/packages/docusaurus-plugin-content-docs/src/markdown/linkify.ts @@ -5,8 +5,8 @@ * LICENSE file in the root directory of this source tree. */ -import type {DocsMarkdownOption} from '../types'; import {replaceMarkdownLinks, getContentPathList} from '@docusaurus/utils'; +import type {DocsMarkdownOption} from '../types'; function getVersion(filePath: string, options: DocsMarkdownOption) { const versionFound = options.versionsMetadata.find((version) => diff --git a/packages/docusaurus-plugin-content-docs/src/options.ts b/packages/docusaurus-plugin-content-docs/src/options.ts index 258236acaaea..27b9118a718f 100644 --- a/packages/docusaurus-plugin-content-docs/src/options.ts +++ b/packages/docusaurus-plugin-content-docs/src/options.ts @@ -5,7 +5,7 @@ * LICENSE file in the root directory of this source tree. */ -import type {PluginOptions, Options} from '@docusaurus/plugin-content-docs'; +import logger from '@docusaurus/logger'; import { Joi, RemarkPluginsSchema, @@ -14,15 +14,14 @@ import { URISchema, } from '@docusaurus/utils-validation'; import {GlobExcludeDefault} from '@docusaurus/utils'; - -import type {OptionValidationContext} from '@docusaurus/types'; -import logger from '@docusaurus/logger'; import admonitions from 'remark-admonitions'; import {DefaultSidebarItemsGenerator} from './sidebars/generator'; import { DefaultNumberPrefixParser, DisabledNumberPrefixParser, } from './numberPrefix'; +import type {OptionValidationContext} from '@docusaurus/types'; +import type {PluginOptions, Options} from '@docusaurus/plugin-content-docs'; export const DEFAULT_OPTIONS: Omit = { path: 'docs', // Path to data on filesystem, relative to site dir. @@ -99,7 +98,7 @@ const OptionsSchema = Joi.object({ Joi.function(), // Convert boolean values to functions Joi.alternatives().conditional(Joi.boolean(), { - then: Joi.custom((val) => + then: Joi.custom((val: boolean) => val ? DefaultNumberPrefixParser : DisabledNumberPrefixParser, ), }), diff --git a/packages/docusaurus-plugin-content-docs/src/plugin-content-docs.d.ts b/packages/docusaurus-plugin-content-docs/src/plugin-content-docs.d.ts index 412a08cdb08f..1d7784c63fc7 100644 --- a/packages/docusaurus-plugin-content-docs/src/plugin-content-docs.d.ts +++ b/packages/docusaurus-plugin-content-docs/src/plugin-content-docs.d.ts @@ -5,6 +5,8 @@ * LICENSE file in the root directory of this source tree. */ +/// + declare module '@docusaurus/plugin-content-docs' { import type {MDXOptions} from '@docusaurus/mdx-loader'; import type { diff --git a/packages/docusaurus-plugin-content-docs/src/props.ts b/packages/docusaurus-plugin-content-docs/src/props.ts index bf4393c631ff..8505d5de2cd2 100644 --- a/packages/docusaurus-plugin-content-docs/src/props.ts +++ b/packages/docusaurus-plugin-content-docs/src/props.ts @@ -5,6 +5,8 @@ * LICENSE file in the root directory of this source tree. */ +import _ from 'lodash'; +import {createDocsByIdIndex} from './docs'; import type {VersionTag} from './types'; import type { SidebarItemDoc, @@ -24,8 +26,6 @@ import type { DocMetadata, LoadedVersion, } from '@docusaurus/plugin-content-docs'; -import _ from 'lodash'; -import {createDocsByIdIndex} from './docs'; export function toSidebarsProp(loadedVersion: LoadedVersion): PropSidebars { const docsById = createDocsByIdIndex(loadedVersion.docs); diff --git a/packages/docusaurus-plugin-content-docs/src/routes.ts b/packages/docusaurus-plugin-content-docs/src/routes.ts index 57f5722ba1db..9a9205bee1c5 100644 --- a/packages/docusaurus-plugin-content-docs/src/routes.ts +++ b/packages/docusaurus-plugin-content-docs/src/routes.ts @@ -5,15 +5,15 @@ * LICENSE file in the root directory of this source tree. */ -import type {PluginContentLoadedActions, RouteConfig} from '@docusaurus/types'; +import logger from '@docusaurus/logger'; import {docuHash, createSlugger} from '@docusaurus/utils'; +import {toVersionMetadataProp} from './props'; +import type {PluginContentLoadedActions, RouteConfig} from '@docusaurus/types'; import type {FullVersion} from './types'; import type { CategoryGeneratedIndexMetadata, DocMetadata, } from '@docusaurus/plugin-content-docs'; -import {toVersionMetadataProp} from './props'; -import logger from '@docusaurus/logger'; export async function createCategoryGeneratedIndexRoutes({ version, diff --git a/packages/docusaurus-plugin-content-docs/src/sidebars/__tests__/generator.test.ts b/packages/docusaurus-plugin-content-docs/src/sidebars/__tests__/generator.test.ts index 66281f746b68..671c12cfe256 100644 --- a/packages/docusaurus-plugin-content-docs/src/sidebars/__tests__/generator.test.ts +++ b/packages/docusaurus-plugin-content-docs/src/sidebars/__tests__/generator.test.ts @@ -7,9 +7,9 @@ import {jest} from '@jest/globals'; import {DefaultSidebarItemsGenerator} from '../generator'; -import type {SidebarItemsGenerator} from '../types'; import {DefaultNumberPrefixParser} from '../../numberPrefix'; import {isCategoryIndex} from '../../docs'; +import type {SidebarItemsGenerator} from '../types'; describe('DefaultSidebarItemsGenerator', () => { function testDefaultSidebarItemsGenerator( diff --git a/packages/docusaurus-plugin-content-docs/src/sidebars/__tests__/index.test.ts b/packages/docusaurus-plugin-content-docs/src/sidebars/__tests__/index.test.ts index aedcfe0db332..5a1eed4f1d1b 100644 --- a/packages/docusaurus-plugin-content-docs/src/sidebars/__tests__/index.test.ts +++ b/packages/docusaurus-plugin-content-docs/src/sidebars/__tests__/index.test.ts @@ -9,8 +9,8 @@ import {jest} from '@jest/globals'; import path from 'path'; import {createSlugger} from '@docusaurus/utils'; import {loadSidebars, DisabledSidebars} from '../index'; -import type {SidebarProcessorParams} from '../types'; import {DefaultSidebarItemsGenerator} from '../generator'; +import type {SidebarProcessorParams} from '../types'; import type {DocMetadata} from '@docusaurus/plugin-content-docs'; describe('loadSidebars', () => { diff --git a/packages/docusaurus-plugin-content-docs/src/sidebars/__tests__/processor.test.ts b/packages/docusaurus-plugin-content-docs/src/sidebars/__tests__/processor.test.ts index 079040879ac6..d0a530bbd7f2 100644 --- a/packages/docusaurus-plugin-content-docs/src/sidebars/__tests__/processor.test.ts +++ b/packages/docusaurus-plugin-content-docs/src/sidebars/__tests__/processor.test.ts @@ -6,7 +6,11 @@ */ import {jest} from '@jest/globals'; +import {createSlugger} from '@docusaurus/utils'; import {processSidebars} from '../processor'; +import {DefaultSidebarItemsGenerator} from '../generator'; +import {DefaultNumberPrefixParser} from '../../numberPrefix'; +import {isCategoryIndex} from '../../docs'; import type { SidebarItem, SidebarItemsGenerator, @@ -16,11 +20,7 @@ import type { CategoryMetadataFile, ProcessedSidebars, } from '../types'; -import {DefaultSidebarItemsGenerator} from '../generator'; -import {createSlugger} from '@docusaurus/utils'; import type {VersionMetadata} from '@docusaurus/plugin-content-docs'; -import {DefaultNumberPrefixParser} from '../../numberPrefix'; -import {isCategoryIndex} from '../../docs'; describe('processSidebars', () => { function createStaticSidebarItemGenerator( diff --git a/packages/docusaurus-plugin-content-docs/src/sidebars/generator.ts b/packages/docusaurus-plugin-content-docs/src/sidebars/generator.ts index 67320e7888d5..56e0025a81af 100644 --- a/packages/docusaurus-plugin-content-docs/src/sidebars/generator.ts +++ b/packages/docusaurus-plugin-content-docs/src/sidebars/generator.ts @@ -5,6 +5,11 @@ * LICENSE file in the root directory of this source tree. */ +import path from 'path'; +import _ from 'lodash'; +import logger from '@docusaurus/logger'; +import {addTrailingSlash} from '@docusaurus/utils'; +import {createDocsByIdIndex, toCategoryIndexMatcherParam} from '../docs'; import type { SidebarItemDoc, SidebarItemsGenerator, @@ -13,11 +18,6 @@ import type { NormalizedSidebarItem, SidebarItemCategoryLinkConfig, } from './types'; -import _ from 'lodash'; -import {addTrailingSlash} from '@docusaurus/utils'; -import logger from '@docusaurus/logger'; -import path from 'path'; -import {createDocsByIdIndex, toCategoryIndexMatcherParam} from '../docs'; const BreadcrumbSeparator = '/'; diff --git a/packages/docusaurus-plugin-content-docs/src/sidebars/index.ts b/packages/docusaurus-plugin-content-docs/src/sidebars/index.ts index f99b03374a04..36bd576f7f8a 100644 --- a/packages/docusaurus-plugin-content-docs/src/sidebars/index.ts +++ b/packages/docusaurus-plugin-content-docs/src/sidebars/index.ts @@ -6,19 +6,19 @@ */ import fs from 'fs-extra'; +import path from 'path'; +import _ from 'lodash'; +import logger from '@docusaurus/logger'; +import {Globby} from '@docusaurus/utils'; +import Yaml from 'js-yaml'; +import combinePromises from 'combine-promises'; import importFresh from 'import-fresh'; -import type {SidebarsConfig, Sidebars, SidebarProcessorParams} from './types'; import {validateSidebars, validateCategoryMetadataFile} from './validation'; import {normalizeSidebars} from './normalization'; import {processSidebars} from './processor'; import {postProcessSidebars} from './postProcessor'; -import path from 'path'; -import {Globby} from '@docusaurus/utils'; -import logger from '@docusaurus/logger'; import type {PluginOptions} from '@docusaurus/plugin-content-docs'; -import Yaml from 'js-yaml'; -import _ from 'lodash'; -import combinePromises from 'combine-promises'; +import type {SidebarsConfig, Sidebars, SidebarProcessorParams} from './types'; export const DefaultSidebars: SidebarsConfig = { defaultSidebar: [ diff --git a/packages/docusaurus-plugin-content-docs/src/sidebars/normalization.ts b/packages/docusaurus-plugin-content-docs/src/sidebars/normalization.ts index d36be98fcd6a..4d51e254443e 100644 --- a/packages/docusaurus-plugin-content-docs/src/sidebars/normalization.ts +++ b/packages/docusaurus-plugin-content-docs/src/sidebars/normalization.ts @@ -5,6 +5,9 @@ * LICENSE file in the root directory of this source tree. */ +import _ from 'lodash'; +import logger from '@docusaurus/logger'; +import {isCategoriesShorthand} from './utils'; import type { NormalizedSidebarItem, NormalizedSidebar, @@ -16,9 +19,6 @@ import type { SidebarsConfig, NormalizedSidebarItemCategory, } from './types'; -import {isCategoriesShorthand} from './utils'; -import _ from 'lodash'; -import logger from '@docusaurus/logger'; function normalizeCategoriesShorthand( sidebar: SidebarCategoriesShorthand, diff --git a/packages/docusaurus-plugin-content-docs/src/sidebars/postProcessor.ts b/packages/docusaurus-plugin-content-docs/src/sidebars/postProcessor.ts index 717db0860583..307ed9de8675 100644 --- a/packages/docusaurus-plugin-content-docs/src/sidebars/postProcessor.ts +++ b/packages/docusaurus-plugin-content-docs/src/sidebars/postProcessor.ts @@ -5,7 +5,9 @@ * LICENSE file in the root directory of this source tree. */ +import _ from 'lodash'; import {normalizeUrl} from '@docusaurus/utils'; +import {getDocIds} from '../docs'; import type { SidebarItem, Sidebars, @@ -15,8 +17,6 @@ import type { ProcessedSidebars, SidebarItemCategoryLink, } from './types'; -import {getDocIds} from '../docs'; -import _ from 'lodash'; type SidebarPostProcessorParams = SidebarProcessorParams & { draftIds: Set; diff --git a/packages/docusaurus-plugin-content-docs/src/sidebars/processor.ts b/packages/docusaurus-plugin-content-docs/src/sidebars/processor.ts index 7e83dd08a921..7949ad2216fd 100644 --- a/packages/docusaurus-plugin-content-docs/src/sidebars/processor.ts +++ b/packages/docusaurus-plugin-content-docs/src/sidebars/processor.ts @@ -5,6 +5,11 @@ * LICENSE file in the root directory of this source tree. */ +import _ from 'lodash'; +import combinePromises from 'combine-promises'; +import {DefaultSidebarItemsGenerator} from './generator'; +import {validateSidebars} from './validation'; +import {isCategoryIndex} from '../docs'; import type { DocMetadataBase, VersionMetadata, @@ -22,11 +27,6 @@ import type { SidebarProcessorParams, CategoryMetadataFile, } from './types'; -import {DefaultSidebarItemsGenerator} from './generator'; -import {validateSidebars} from './validation'; -import _ from 'lodash'; -import combinePromises from 'combine-promises'; -import {isCategoryIndex} from '../docs'; function toSidebarItemsGeneratorDoc( doc: DocMetadataBase, diff --git a/packages/docusaurus-plugin-content-docs/src/sidebars/utils.ts b/packages/docusaurus-plugin-content-docs/src/sidebars/utils.ts index ee27177c1e4a..a213b2e7dedc 100644 --- a/packages/docusaurus-plugin-content-docs/src/sidebars/utils.ts +++ b/packages/docusaurus-plugin-content-docs/src/sidebars/utils.ts @@ -5,6 +5,8 @@ * LICENSE file in the root directory of this source tree. */ +import _ from 'lodash'; +import {toMessageRelativeFilePath} from '@docusaurus/utils'; import type { Sidebars, Sidebar, @@ -18,9 +20,6 @@ import type { SidebarItemCategoryWithGeneratedIndex, SidebarNavigationItem, } from './types'; - -import _ from 'lodash'; -import {toMessageRelativeFilePath} from '@docusaurus/utils'; import type { DocMetadataBase, PropNavigationLink, diff --git a/packages/docusaurus-plugin-content-docs/src/tags.ts b/packages/docusaurus-plugin-content-docs/src/tags.ts index 1de963d81f56..dfa0e3284587 100644 --- a/packages/docusaurus-plugin-content-docs/src/tags.ts +++ b/packages/docusaurus-plugin-content-docs/src/tags.ts @@ -5,10 +5,10 @@ * LICENSE file in the root directory of this source tree. */ +import _ from 'lodash'; import {groupTaggedItems} from '@docusaurus/utils'; import type {VersionTags} from './types'; import type {DocMetadata} from '@docusaurus/plugin-content-docs'; -import _ from 'lodash'; export function getVersionTags(docs: DocMetadata[]): VersionTags { const groups = groupTaggedItems(docs, (doc) => doc.tags); diff --git a/packages/docusaurus-plugin-content-docs/src/translations.ts b/packages/docusaurus-plugin-content-docs/src/translations.ts index f5f2f7e71916..abc56ac65b93 100644 --- a/packages/docusaurus-plugin-content-docs/src/translations.ts +++ b/packages/docusaurus-plugin-content-docs/src/translations.ts @@ -5,6 +5,14 @@ * LICENSE file in the root directory of this source tree. */ +import _ from 'lodash'; +import {mergeTranslations} from '@docusaurus/utils'; +import {CURRENT_VERSION_NAME} from './constants'; +import { + collectSidebarCategories, + transformSidebarItems, + collectSidebarLinks, +} from './sidebars/utils'; import type { LoadedVersion, LoadedContent, @@ -15,20 +23,11 @@ import type { SidebarItemCategoryLink, Sidebars, } from './sidebars/types'; - -import _ from 'lodash'; -import { - collectSidebarCategories, - transformSidebarItems, - collectSidebarLinks, -} from './sidebars/utils'; import type { TranslationFileContent, TranslationFile, TranslationMessage, } from '@docusaurus/types'; -import {mergeTranslations} from '@docusaurus/utils'; -import {CURRENT_VERSION_NAME} from './constants'; function getVersionFileName(versionName: string): string { if (versionName === CURRENT_VERSION_NAME) { diff --git a/packages/docusaurus-plugin-content-docs/src/types.ts b/packages/docusaurus-plugin-content-docs/src/types.ts index df3579b856d8..cb4506b20d1a 100644 --- a/packages/docusaurus-plugin-content-docs/src/types.ts +++ b/packages/docusaurus-plugin-content-docs/src/types.ts @@ -5,8 +5,6 @@ * LICENSE file in the root directory of this source tree. */ -/// - import type {BrokenMarkdownLink, Tag} from '@docusaurus/utils'; import type { VersionMetadata, diff --git a/packages/docusaurus-plugin-content-docs/src/versions/__tests__/index.test.ts b/packages/docusaurus-plugin-content-docs/src/versions/__tests__/index.test.ts index c019d8a3ae9a..4a3448460a24 100644 --- a/packages/docusaurus-plugin-content-docs/src/versions/__tests__/index.test.ts +++ b/packages/docusaurus-plugin-content-docs/src/versions/__tests__/index.test.ts @@ -7,9 +7,9 @@ import {jest} from '@jest/globals'; import path from 'path'; +import {DEFAULT_PLUGIN_ID} from '@docusaurus/utils'; import {readVersionsMetadata} from '../index'; import {DEFAULT_OPTIONS} from '../../options'; -import {DEFAULT_PLUGIN_ID} from '@docusaurus/utils'; import type {I18n} from '@docusaurus/types'; import type { PluginOptions, diff --git a/packages/docusaurus-plugin-content-docs/src/versions/files.ts b/packages/docusaurus-plugin-content-docs/src/versions/files.ts index 69660f34a9cc..f9ef69c82944 100644 --- a/packages/docusaurus-plugin-content-docs/src/versions/files.ts +++ b/packages/docusaurus-plugin-content-docs/src/versions/files.ts @@ -7,6 +7,7 @@ import path from 'path'; import fs from 'fs-extra'; +import {getPluginI18nPath, DEFAULT_PLUGIN_ID} from '@docusaurus/utils'; import { VERSIONS_JSON_FILE, VERSIONED_DOCS_DIR, @@ -14,7 +15,6 @@ import { CURRENT_VERSION_NAME, } from '../constants'; import {validateVersionNames} from './validation'; -import {getPluginI18nPath, DEFAULT_PLUGIN_ID} from '@docusaurus/utils'; import type { PluginOptions, VersionMetadata, @@ -95,7 +95,7 @@ async function readVersionsFile( ): Promise { const versionsFilePath = getVersionsFilePath(siteDir, pluginId); if (await fs.pathExists(versionsFilePath)) { - const content = await fs.readJSON(versionsFilePath); + const content: unknown = await fs.readJSON(versionsFilePath); validateVersionNames(content); return content; } diff --git a/packages/docusaurus-plugin-content-docs/src/versions/index.ts b/packages/docusaurus-plugin-content-docs/src/versions/index.ts index cd85ddf2137d..369e0fd6efc2 100644 --- a/packages/docusaurus-plugin-content-docs/src/versions/index.ts +++ b/packages/docusaurus-plugin-content-docs/src/versions/index.ts @@ -6,8 +6,8 @@ */ import path from 'path'; -import {CURRENT_VERSION_NAME} from '../constants'; import {normalizeUrl, posixPath} from '@docusaurus/utils'; +import {CURRENT_VERSION_NAME} from '../constants'; import {validateVersionsOptions} from './validation'; import { getDocsDirPathLocalized, diff --git a/packages/docusaurus-plugin-content-docs/tsconfig.client.json b/packages/docusaurus-plugin-content-docs/tsconfig.client.json new file mode 100644 index 000000000000..2741f3ca3890 --- /dev/null +++ b/packages/docusaurus-plugin-content-docs/tsconfig.client.json @@ -0,0 +1,15 @@ +{ + "extends": "../../tsconfig.json", + "compilerOptions": { + "noEmit": false, + "composite": true, + "incremental": true, + "tsBuildInfoFile": "./lib/.tsbuildinfo-client", + "module": "esnext", + "target": "esnext", + "rootDir": "src", + "outDir": "lib" + }, + "include": ["src/client", "src/*.d.ts"], + "exclude": ["**/__tests__/**"] +} diff --git a/packages/docusaurus-plugin-content-docs/tsconfig.json b/packages/docusaurus-plugin-content-docs/tsconfig.json index f5902ba1089b..48e200409e4e 100644 --- a/packages/docusaurus-plugin-content-docs/tsconfig.json +++ b/packages/docusaurus-plugin-content-docs/tsconfig.json @@ -1,9 +1,14 @@ { "extends": "../../tsconfig.json", + "references": [{"path": "./tsconfig.client.json"}], "compilerOptions": { + "noEmit": false, "incremental": true, "tsBuildInfoFile": "./lib/.tsbuildinfo", + "module": "commonjs", "rootDir": "src", "outDir": "lib" - } + }, + "include": ["src"], + "exclude": ["src/client", "**/__tests__/**"] } diff --git a/packages/docusaurus-plugin-content-pages/.npmignore b/packages/docusaurus-plugin-content-pages/.npmignore index f2b994d4e359..03c9ae1e1b54 100644 --- a/packages/docusaurus-plugin-content-pages/.npmignore +++ b/packages/docusaurus-plugin-content-pages/.npmignore @@ -1,4 +1,3 @@ -copyUntypedFiles.mjs -.tsbuildinfo +.tsbuildinfo* tsconfig* __tests__ diff --git a/packages/docusaurus-plugin-content-pages/src/__tests__/index.test.ts b/packages/docusaurus-plugin-content-pages/src/__tests__/index.test.ts index 89221c819bc8..f3b94d2df5f4 100644 --- a/packages/docusaurus-plugin-content-pages/src/__tests__/index.test.ts +++ b/packages/docusaurus-plugin-content-pages/src/__tests__/index.test.ts @@ -7,10 +7,10 @@ import path from 'path'; import {loadContext} from '@docusaurus/core/lib/server'; +import {normalizePluginOptions} from '@docusaurus/utils-validation'; import pluginContentPages from '../index'; import {validateOptions} from '../options'; -import {normalizePluginOptions} from '@docusaurus/utils-validation'; describe('docusaurus-plugin-content-pages', () => { it('loads simple pages', async () => { diff --git a/packages/docusaurus-plugin-content-pages/src/__tests__/options.test.ts b/packages/docusaurus-plugin-content-pages/src/__tests__/options.test.ts index 9365b614cd9f..d92d691e7dc0 100644 --- a/packages/docusaurus-plugin-content-pages/src/__tests__/options.test.ts +++ b/packages/docusaurus-plugin-content-pages/src/__tests__/options.test.ts @@ -5,8 +5,8 @@ * LICENSE file in the root directory of this source tree. */ -import {validateOptions, DEFAULT_OPTIONS} from '../options'; import {normalizePluginOptions} from '@docusaurus/utils-validation'; +import {validateOptions, DEFAULT_OPTIONS} from '../options'; import type {Options} from '@docusaurus/plugin-content-pages'; function testValidate(options: Options) { diff --git a/packages/docusaurus-plugin-content-pages/src/index.ts b/packages/docusaurus-plugin-content-pages/src/index.ts index 5bd819610ba1..66bcb0d15712 100644 --- a/packages/docusaurus-plugin-content-pages/src/index.ts +++ b/packages/docusaurus-plugin-content-pages/src/index.ts @@ -21,10 +21,10 @@ import { DEFAULT_PLUGIN_ID, parseMarkdownString, } from '@docusaurus/utils'; -import type {LoadContext, Plugin} from '@docusaurus/types'; import admonitions from 'remark-admonitions'; import {validatePageFrontMatter} from './frontMatter'; +import type {LoadContext, Plugin} from '@docusaurus/types'; import type {PagesContentPaths} from './types'; import type { PluginOptions, diff --git a/packages/docusaurus-plugin-content-pages/src/options.ts b/packages/docusaurus-plugin-content-pages/src/options.ts index 9713fea810dd..475ed8311060 100644 --- a/packages/docusaurus-plugin-content-pages/src/options.ts +++ b/packages/docusaurus-plugin-content-pages/src/options.ts @@ -5,7 +5,6 @@ * LICENSE file in the root directory of this source tree. */ -import type {PluginOptions, Options} from '@docusaurus/plugin-content-pages'; import { Joi, RemarkPluginsSchema, @@ -14,6 +13,7 @@ import { } from '@docusaurus/utils-validation'; import {GlobExcludeDefault} from '@docusaurus/utils'; import type {OptionValidationContext} from '@docusaurus/types'; +import type {PluginOptions, Options} from '@docusaurus/plugin-content-pages'; export const DEFAULT_OPTIONS: PluginOptions = { path: 'src/pages', // Path to data on filesystem, relative to site dir. diff --git a/packages/docusaurus-plugin-content-pages/tsconfig.json b/packages/docusaurus-plugin-content-pages/tsconfig.json index f5902ba1089b..80e43e9813ef 100644 --- a/packages/docusaurus-plugin-content-pages/tsconfig.json +++ b/packages/docusaurus-plugin-content-pages/tsconfig.json @@ -1,9 +1,13 @@ { "extends": "../../tsconfig.json", "compilerOptions": { + "noEmit": false, "incremental": true, "tsBuildInfoFile": "./lib/.tsbuildinfo", + "module": "commonjs", "rootDir": "src", "outDir": "lib" - } + }, + "include": ["src"], + "exclude": ["**/__tests__/**"] } diff --git a/packages/docusaurus-plugin-debug/.npmignore b/packages/docusaurus-plugin-debug/.npmignore index f2b994d4e359..03c9ae1e1b54 100644 --- a/packages/docusaurus-plugin-debug/.npmignore +++ b/packages/docusaurus-plugin-debug/.npmignore @@ -1,4 +1,3 @@ -copyUntypedFiles.mjs -.tsbuildinfo +.tsbuildinfo* tsconfig* __tests__ diff --git a/packages/docusaurus-plugin-debug/copyUntypedFiles.mjs b/packages/docusaurus-plugin-debug/copyUntypedFiles.mjs deleted file mode 100644 index 8b230152f1af..000000000000 --- a/packages/docusaurus-plugin-debug/copyUntypedFiles.mjs +++ /dev/null @@ -1,20 +0,0 @@ -/** - * Copyright (c) Facebook, Inc. and its affiliates. - * - * This source code is licensed under the MIT license found in the - * LICENSE file in the root directory of this source tree. - */ - -import fs from 'fs-extra'; -import {fileURLToPath} from 'url'; - -/** - * Copy all untyped and static assets files to lib. - */ -const srcDir = fileURLToPath(new URL('src', import.meta.url)); -const libDir = fileURLToPath(new URL('lib', import.meta.url)); -await fs.copy(srcDir, libDir, { - filter(filepath) { - return !/__tests__/.test(filepath) && !/\.tsx?$/.test(filepath); - }, -}); diff --git a/packages/docusaurus-plugin-debug/package.json b/packages/docusaurus-plugin-debug/package.json index 9d3f2fd58a35..3382fcab737a 100644 --- a/packages/docusaurus-plugin-debug/package.json +++ b/packages/docusaurus-plugin-debug/package.json @@ -5,8 +5,10 @@ "main": "lib/index.js", "types": "src/plugin-debug.d.ts", "scripts": { - "build": "tsc && node copyUntypedFiles.mjs", - "watch": "node copyUntypedFiles.mjs && tsc --watch" + "build": "tsc --build && node ../../admin/scripts/copyUntypedFiles.js && prettier --config ../../.prettierrc --write \"lib/theme/**/*.js\"", + "watch": "run-p -c copy:watch build:watch", + "build:watch": "tsc --build --watch", + "copy:watch": "node ../../admin/scripts/copyUntypedFiles.js --watch" }, "publishConfig": { "access": "public" diff --git a/packages/docusaurus-plugin-debug/src/index.ts b/packages/docusaurus-plugin-debug/src/index.ts index 62e650824f93..7ca3680678cb 100644 --- a/packages/docusaurus-plugin-debug/src/index.ts +++ b/packages/docusaurus-plugin-debug/src/index.ts @@ -5,9 +5,9 @@ * LICENSE file in the root directory of this source tree. */ -import type {LoadContext, Plugin} from '@docusaurus/types'; -import {docuHash, normalizeUrl, posixPath} from '@docusaurus/utils'; import path from 'path'; +import {docuHash, normalizeUrl, posixPath} from '@docusaurus/utils'; +import type {LoadContext, Plugin} from '@docusaurus/types'; export default function pluginDebug({ siteConfig: {baseUrl}, diff --git a/packages/docusaurus-plugin-debug/src/theme/DebugConfig/index.tsx b/packages/docusaurus-plugin-debug/src/theme/DebugConfig/index.tsx index 373fd530efff..6b110b8ab198 100644 --- a/packages/docusaurus-plugin-debug/src/theme/DebugConfig/index.tsx +++ b/packages/docusaurus-plugin-debug/src/theme/DebugConfig/index.tsx @@ -6,12 +6,10 @@ */ import React from 'react'; - +import useDocusaurusContext from '@docusaurus/useDocusaurusContext'; import DebugLayout from '@theme/DebugLayout'; import DebugJsonView from '@theme/DebugJsonView'; -import useDocusaurusContext from '@docusaurus/useDocusaurusContext'; - export default function DebugMetadata(): JSX.Element { const {siteConfig} = useDocusaurusContext(); return ( diff --git a/packages/docusaurus-plugin-debug/src/theme/DebugGlobalData/index.tsx b/packages/docusaurus-plugin-debug/src/theme/DebugGlobalData/index.tsx index 2a1b28b73fa8..f66df5b7dd8d 100644 --- a/packages/docusaurus-plugin-debug/src/theme/DebugGlobalData/index.tsx +++ b/packages/docusaurus-plugin-debug/src/theme/DebugGlobalData/index.tsx @@ -6,10 +6,9 @@ */ import React from 'react'; - +import useGlobalData from '@docusaurus/useGlobalData'; import DebugLayout from '@theme/DebugLayout'; import DebugJsonView from '@theme/DebugJsonView'; -import useGlobalData from '@docusaurus/useGlobalData'; export default function DebugMetadata(): JSX.Element { const globalData = useGlobalData(); diff --git a/packages/docusaurus-plugin-debug/src/theme/DebugJsonView/index.tsx b/packages/docusaurus-plugin-debug/src/theme/DebugJsonView/index.tsx index e6d981234dde..d22d4a015b3c 100644 --- a/packages/docusaurus-plugin-debug/src/theme/DebugJsonView/index.tsx +++ b/packages/docusaurus-plugin-debug/src/theme/DebugJsonView/index.tsx @@ -19,8 +19,9 @@ function BrowserOnlyReactJson(props: ReactJsonViewProps) { return ( {() => { - // eslint-disable-next-line global-require, @typescript-eslint/no-var-requires - const ReactJson = require('react-json-view').default; + const {default: ReactJson} = + // eslint-disable-next-line global-require, @typescript-eslint/no-var-requires + require('react-json-view') as typeof import('react-json-view'); return ; }} diff --git a/packages/docusaurus-plugin-debug/src/theme/DebugRegistry/index.tsx b/packages/docusaurus-plugin-debug/src/theme/DebugRegistry/index.tsx index b937bf9040c4..59cd4c7c2145 100644 --- a/packages/docusaurus-plugin-debug/src/theme/DebugRegistry/index.tsx +++ b/packages/docusaurus-plugin-debug/src/theme/DebugRegistry/index.tsx @@ -6,9 +6,8 @@ */ import React from 'react'; - -import DebugLayout from '@theme/DebugLayout'; import registry from '@generated/registry'; +import DebugLayout from '@theme/DebugLayout'; import styles from './styles.module.css'; export default function DebugRegistry(): JSX.Element { diff --git a/packages/docusaurus-plugin-debug/src/theme/DebugRoutes/index.tsx b/packages/docusaurus-plugin-debug/src/theme/DebugRoutes/index.tsx index d9d3c5b5fa08..43b922ba91ac 100644 --- a/packages/docusaurus-plugin-debug/src/theme/DebugRoutes/index.tsx +++ b/packages/docusaurus-plugin-debug/src/theme/DebugRoutes/index.tsx @@ -6,10 +6,9 @@ */ import React from 'react'; - +import routes from '@generated/routes'; import DebugLayout from '@theme/DebugLayout'; import DebugJsonView from '@theme/DebugJsonView'; -import routes from '@generated/routes'; import styles from './styles.module.css'; export default function DebugRoutes(): JSX.Element { diff --git a/packages/docusaurus-plugin-debug/src/theme/DebugSiteMetadata/index.tsx b/packages/docusaurus-plugin-debug/src/theme/DebugSiteMetadata/index.tsx index a30cc3bbc642..64d3954842c5 100644 --- a/packages/docusaurus-plugin-debug/src/theme/DebugSiteMetadata/index.tsx +++ b/packages/docusaurus-plugin-debug/src/theme/DebugSiteMetadata/index.tsx @@ -6,9 +6,8 @@ */ import React from 'react'; - -import DebugLayout from '@theme/DebugLayout'; import useDocusaurusContext from '@docusaurus/useDocusaurusContext'; +import DebugLayout from '@theme/DebugLayout'; import styles from './styles.module.css'; export default function DebugMetadata(): JSX.Element { diff --git a/packages/docusaurus-plugin-debug/tsconfig.client.json b/packages/docusaurus-plugin-debug/tsconfig.client.json new file mode 100644 index 000000000000..2fd5ae7c4d29 --- /dev/null +++ b/packages/docusaurus-plugin-debug/tsconfig.client.json @@ -0,0 +1,15 @@ +{ + "extends": "../../tsconfig.json", + "compilerOptions": { + "noEmit": false, + "composite": true, + "incremental": true, + "tsBuildInfoFile": "./lib/.tsbuildinfo-client", + "module": "esnext", + "target": "esnext", + "rootDir": "src", + "outDir": "lib" + }, + "include": ["src/theme", "src/*.d.ts"], + "exclude": ["**/__tests__/**"] +} diff --git a/packages/docusaurus-plugin-debug/tsconfig.json b/packages/docusaurus-plugin-debug/tsconfig.json index f5902ba1089b..7c1bb85ac462 100644 --- a/packages/docusaurus-plugin-debug/tsconfig.json +++ b/packages/docusaurus-plugin-debug/tsconfig.json @@ -1,9 +1,14 @@ { "extends": "../../tsconfig.json", + "references": [{"path": "./tsconfig.client.json"}], "compilerOptions": { + "noEmit": false, "incremental": true, "tsBuildInfoFile": "./lib/.tsbuildinfo", + "module": "commonjs", "rootDir": "src", "outDir": "lib" - } + }, + "include": ["src"], + "exclude": ["src/theme", "**/__tests__/**"] } diff --git a/packages/docusaurus-plugin-google-analytics/.npmignore b/packages/docusaurus-plugin-google-analytics/.npmignore index f2b994d4e359..03c9ae1e1b54 100644 --- a/packages/docusaurus-plugin-google-analytics/.npmignore +++ b/packages/docusaurus-plugin-google-analytics/.npmignore @@ -1,4 +1,3 @@ -copyUntypedFiles.mjs -.tsbuildinfo +.tsbuildinfo* tsconfig* __tests__ diff --git a/packages/docusaurus-plugin-google-analytics/package.json b/packages/docusaurus-plugin-google-analytics/package.json index 77f5c813de98..f62db432005c 100644 --- a/packages/docusaurus-plugin-google-analytics/package.json +++ b/packages/docusaurus-plugin-google-analytics/package.json @@ -8,8 +8,8 @@ "access": "public" }, "scripts": { - "build": "tsc", - "watch": "tsc --watch" + "build": "tsc --build", + "watch": "tsc --build --watch" }, "repository": { "type": "git", diff --git a/packages/docusaurus-plugin-google-analytics/tsconfig.client.json b/packages/docusaurus-plugin-google-analytics/tsconfig.client.json new file mode 100644 index 000000000000..766ffcc81d67 --- /dev/null +++ b/packages/docusaurus-plugin-google-analytics/tsconfig.client.json @@ -0,0 +1,15 @@ +{ + "extends": "../../tsconfig.json", + "compilerOptions": { + "noEmit": false, + "composite": true, + "incremental": true, + "tsBuildInfoFile": "./lib/.tsbuildinfo-client", + "module": "esnext", + "target": "esnext", + "rootDir": "src", + "outDir": "lib" + }, + "include": ["src/analytics.ts", "src/*.d.ts"], + "exclude": ["**/__tests__/**"] +} diff --git a/packages/docusaurus-plugin-google-analytics/tsconfig.json b/packages/docusaurus-plugin-google-analytics/tsconfig.json index f5902ba1089b..77a4365aedfe 100644 --- a/packages/docusaurus-plugin-google-analytics/tsconfig.json +++ b/packages/docusaurus-plugin-google-analytics/tsconfig.json @@ -1,9 +1,14 @@ { "extends": "../../tsconfig.json", + "references": [{"path": "./tsconfig.client.json"}], "compilerOptions": { + "noEmit": false, "incremental": true, "tsBuildInfoFile": "./lib/.tsbuildinfo", + "module": "commonjs", "rootDir": "src", "outDir": "lib" - } + }, + "include": ["src"], + "exclude": ["src/analytics.ts", "**/__tests__/**"] } diff --git a/packages/docusaurus-plugin-google-gtag/.npmignore b/packages/docusaurus-plugin-google-gtag/.npmignore index f2b994d4e359..03c9ae1e1b54 100644 --- a/packages/docusaurus-plugin-google-gtag/.npmignore +++ b/packages/docusaurus-plugin-google-gtag/.npmignore @@ -1,4 +1,3 @@ -copyUntypedFiles.mjs -.tsbuildinfo +.tsbuildinfo* tsconfig* __tests__ diff --git a/packages/docusaurus-plugin-google-gtag/package.json b/packages/docusaurus-plugin-google-gtag/package.json index 854f6d2e87f8..c353d7a1a28c 100644 --- a/packages/docusaurus-plugin-google-gtag/package.json +++ b/packages/docusaurus-plugin-google-gtag/package.json @@ -5,8 +5,8 @@ "main": "lib/index.js", "types": "lib/index.d.ts", "scripts": { - "build": "tsc", - "watch": "tsc --watch" + "build": "tsc --build", + "watch": "tsc --build --watch" }, "publishConfig": { "access": "public" diff --git a/packages/docusaurus-plugin-google-gtag/tsconfig.client.json b/packages/docusaurus-plugin-google-gtag/tsconfig.client.json new file mode 100644 index 000000000000..985b9a458099 --- /dev/null +++ b/packages/docusaurus-plugin-google-gtag/tsconfig.client.json @@ -0,0 +1,15 @@ +{ + "extends": "../../tsconfig.json", + "compilerOptions": { + "noEmit": false, + "composite": true, + "incremental": true, + "tsBuildInfoFile": "./lib/.tsbuildinfo-client", + "module": "esnext", + "target": "esnext", + "rootDir": "src", + "outDir": "lib" + }, + "include": ["src/gtag.ts", "src/options.ts", "src/*.d.ts"], + "exclude": ["**/__tests__/**"] +} diff --git a/packages/docusaurus-plugin-google-gtag/tsconfig.json b/packages/docusaurus-plugin-google-gtag/tsconfig.json index f5902ba1089b..1b3271a718e6 100644 --- a/packages/docusaurus-plugin-google-gtag/tsconfig.json +++ b/packages/docusaurus-plugin-google-gtag/tsconfig.json @@ -1,9 +1,14 @@ { "extends": "../../tsconfig.json", + "references": [{"path": "./tsconfig.client.json"}], "compilerOptions": { + "noEmit": false, "incremental": true, "tsBuildInfoFile": "./lib/.tsbuildinfo", + "module": "commonjs", "rootDir": "src", "outDir": "lib" - } + }, + "include": ["src"], + "exclude": ["src/gtag.ts", "**/__tests__/**"] } diff --git a/packages/docusaurus-plugin-ideal-image/.npmignore b/packages/docusaurus-plugin-ideal-image/.npmignore index f2b994d4e359..03c9ae1e1b54 100644 --- a/packages/docusaurus-plugin-ideal-image/.npmignore +++ b/packages/docusaurus-plugin-ideal-image/.npmignore @@ -1,4 +1,3 @@ -copyUntypedFiles.mjs -.tsbuildinfo +.tsbuildinfo* tsconfig* __tests__ diff --git a/packages/docusaurus-plugin-ideal-image/copyUntypedFiles.mjs b/packages/docusaurus-plugin-ideal-image/copyUntypedFiles.mjs deleted file mode 100644 index 8b230152f1af..000000000000 --- a/packages/docusaurus-plugin-ideal-image/copyUntypedFiles.mjs +++ /dev/null @@ -1,20 +0,0 @@ -/** - * Copyright (c) Facebook, Inc. and its affiliates. - * - * This source code is licensed under the MIT license found in the - * LICENSE file in the root directory of this source tree. - */ - -import fs from 'fs-extra'; -import {fileURLToPath} from 'url'; - -/** - * Copy all untyped and static assets files to lib. - */ -const srcDir = fileURLToPath(new URL('src', import.meta.url)); -const libDir = fileURLToPath(new URL('lib', import.meta.url)); -await fs.copy(srcDir, libDir, { - filter(filepath) { - return !/__tests__/.test(filepath) && !/\.tsx?$/.test(filepath); - }, -}); diff --git a/packages/docusaurus-plugin-ideal-image/package.json b/packages/docusaurus-plugin-ideal-image/package.json index 6f6c73d117c0..5bda29fd0203 100644 --- a/packages/docusaurus-plugin-ideal-image/package.json +++ b/packages/docusaurus-plugin-ideal-image/package.json @@ -5,11 +5,10 @@ "main": "lib/index.js", "types": "src/plugin-ideal-image.d.ts", "scripts": { - "build": "yarn build:server && yarn build:browser && yarn build:copy && yarn build:format", - "build:server": "tsc --project tsconfig.server.json", - "build:browser": "tsc --project tsconfig.browser.json", - "build:copy": "node copyUntypedFiles.mjs", - "build:format": "prettier --config ../../.prettierrc --write \"lib/**/*.js\"" + "build": "tsc --build && node ../../admin/scripts/copyUntypedFiles.js && prettier --config ../../.prettierrc --write \"lib/theme/**/*.js\"", + "watch": "run-p -c copy:watch build:watch", + "build:watch": "tsc --build --watch", + "copy:watch": "node ../../admin/scripts/copyUntypedFiles.js --watch" }, "publishConfig": { "access": "public" diff --git a/packages/docusaurus-plugin-ideal-image/src/index.ts b/packages/docusaurus-plugin-ideal-image/src/index.ts index 727eb1adc51c..d650e33b1006 100644 --- a/packages/docusaurus-plugin-ideal-image/src/index.ts +++ b/packages/docusaurus-plugin-ideal-image/src/index.ts @@ -5,14 +5,14 @@ * LICENSE file in the root directory of this source tree. */ +import {Joi} from '@docusaurus/utils-validation'; +import {readDefaultCodeTranslationMessages} from '@docusaurus/theme-translations'; import type { LoadContext, Plugin, OptionValidationContext, } from '@docusaurus/types'; import type {PluginOptions} from '@docusaurus/plugin-ideal-image'; -import {Joi} from '@docusaurus/utils-validation'; -import {readDefaultCodeTranslationMessages} from '@docusaurus/theme-translations'; export default function pluginIdealImage( context: LoadContext, diff --git a/packages/docusaurus-plugin-ideal-image/tsconfig.browser.json b/packages/docusaurus-plugin-ideal-image/tsconfig.browser.json deleted file mode 100644 index 3af8257cdf8d..000000000000 --- a/packages/docusaurus-plugin-ideal-image/tsconfig.browser.json +++ /dev/null @@ -1,8 +0,0 @@ -{ - "extends": "./tsconfig.json", - "compilerOptions": { - "module": "esnext", - "jsx": "react-native" - }, - "include": ["src/theme/", "src/*.d.ts"] -} diff --git a/packages/docusaurus-plugin-ideal-image/tsconfig.client.json b/packages/docusaurus-plugin-ideal-image/tsconfig.client.json new file mode 100644 index 000000000000..2fd5ae7c4d29 --- /dev/null +++ b/packages/docusaurus-plugin-ideal-image/tsconfig.client.json @@ -0,0 +1,15 @@ +{ + "extends": "../../tsconfig.json", + "compilerOptions": { + "noEmit": false, + "composite": true, + "incremental": true, + "tsBuildInfoFile": "./lib/.tsbuildinfo-client", + "module": "esnext", + "target": "esnext", + "rootDir": "src", + "outDir": "lib" + }, + "include": ["src/theme", "src/*.d.ts"], + "exclude": ["**/__tests__/**"] +} diff --git a/packages/docusaurus-plugin-ideal-image/tsconfig.json b/packages/docusaurus-plugin-ideal-image/tsconfig.json index 51aec434b257..7c1bb85ac462 100644 --- a/packages/docusaurus-plugin-ideal-image/tsconfig.json +++ b/packages/docusaurus-plugin-ideal-image/tsconfig.json @@ -1,8 +1,14 @@ { "extends": "../../tsconfig.json", + "references": [{"path": "./tsconfig.client.json"}], "compilerOptions": { - "lib": ["DOM", "ES2019"], + "noEmit": false, + "incremental": true, + "tsBuildInfoFile": "./lib/.tsbuildinfo", + "module": "commonjs", "rootDir": "src", "outDir": "lib" - } + }, + "include": ["src"], + "exclude": ["src/theme", "**/__tests__/**"] } diff --git a/packages/docusaurus-plugin-ideal-image/tsconfig.server.json b/packages/docusaurus-plugin-ideal-image/tsconfig.server.json deleted file mode 100644 index 1a463cd83a52..000000000000 --- a/packages/docusaurus-plugin-ideal-image/tsconfig.server.json +++ /dev/null @@ -1,4 +0,0 @@ -{ - "extends": "./tsconfig.json", - "include": ["src/*.ts"] -} diff --git a/packages/docusaurus-plugin-pwa/.npmignore b/packages/docusaurus-plugin-pwa/.npmignore index f2b994d4e359..03c9ae1e1b54 100644 --- a/packages/docusaurus-plugin-pwa/.npmignore +++ b/packages/docusaurus-plugin-pwa/.npmignore @@ -1,4 +1,3 @@ -copyUntypedFiles.mjs -.tsbuildinfo +.tsbuildinfo* tsconfig* __tests__ diff --git a/packages/docusaurus-plugin-pwa/copyUntypedFiles.mjs b/packages/docusaurus-plugin-pwa/copyUntypedFiles.mjs deleted file mode 100644 index 8b230152f1af..000000000000 --- a/packages/docusaurus-plugin-pwa/copyUntypedFiles.mjs +++ /dev/null @@ -1,20 +0,0 @@ -/** - * Copyright (c) Facebook, Inc. and its affiliates. - * - * This source code is licensed under the MIT license found in the - * LICENSE file in the root directory of this source tree. - */ - -import fs from 'fs-extra'; -import {fileURLToPath} from 'url'; - -/** - * Copy all untyped and static assets files to lib. - */ -const srcDir = fileURLToPath(new URL('src', import.meta.url)); -const libDir = fileURLToPath(new URL('lib', import.meta.url)); -await fs.copy(srcDir, libDir, { - filter(filepath) { - return !/__tests__/.test(filepath) && !/\.tsx?$/.test(filepath); - }, -}); diff --git a/packages/docusaurus-plugin-pwa/package.json b/packages/docusaurus-plugin-pwa/package.json index 3f0a4f8201c5..f47075267b29 100644 --- a/packages/docusaurus-plugin-pwa/package.json +++ b/packages/docusaurus-plugin-pwa/package.json @@ -5,10 +5,10 @@ "main": "lib/index.js", "types": "src/plugin-pwa.d.ts", "scripts": { - "build": "yarn build:server && yarn build:browser && yarn build:copy", - "build:server": "tsc --project tsconfig.server.json", - "build:browser": "tsc --project tsconfig.browser.json", - "build:copy": "node copyUntypedFiles.mjs" + "build": "tsc --build && node ../../admin/scripts/copyUntypedFiles.js && prettier --config ../../.prettierrc --write \"lib/theme/**/*.js\"", + "watch": "run-p -c copy:watch build:watch", + "build:watch": "tsc --build --watch", + "copy:watch": "node ../../admin/scripts/copyUntypedFiles.js --watch" }, "publishConfig": { "access": "public" @@ -20,8 +20,8 @@ }, "license": "MIT", "dependencies": { - "@babel/core": "^7.17.10", - "@babel/preset-env": "^7.17.10", + "@babel/core": "^7.18.0", + "@babel/preset-env": "^7.18.0", "@docusaurus/core": "2.0.0-beta.20", "@docusaurus/theme-common": "2.0.0-beta.20", "@docusaurus/theme-translations": "2.0.0-beta.20", diff --git a/packages/docusaurus-plugin-pwa/src/index.ts b/packages/docusaurus-plugin-pwa/src/index.ts index 7150eae5f609..7ec58b25f439 100644 --- a/packages/docusaurus-plugin-pwa/src/index.ts +++ b/packages/docusaurus-plugin-pwa/src/index.ts @@ -5,18 +5,16 @@ * LICENSE file in the root directory of this source tree. */ -import type {HtmlTags, LoadContext, Plugin} from '@docusaurus/types'; -import type {PluginOptions} from '@docusaurus/plugin-pwa'; -import {normalizeUrl} from '@docusaurus/utils'; -import {compile} from '@docusaurus/core/lib/webpack/utils'; -import LogPlugin from '@docusaurus/core/lib/webpack/plugins/LogPlugin'; -import {readDefaultCodeTranslationMessages} from '@docusaurus/theme-translations'; - import path from 'path'; import webpack, {type Configuration} from 'webpack'; import Terser from 'terser-webpack-plugin'; - import {injectManifest} from 'workbox-build'; +import {normalizeUrl} from '@docusaurus/utils'; +import {compile} from '@docusaurus/core/lib/webpack/utils'; +import LogPlugin from '@docusaurus/core/lib/webpack/plugins/LogPlugin'; +import {readDefaultCodeTranslationMessages} from '@docusaurus/theme-translations'; +import type {HtmlTags, LoadContext, Plugin} from '@docusaurus/types'; +import type {PluginOptions} from '@docusaurus/plugin-pwa'; const isProd = process.env.NODE_ENV === 'production'; diff --git a/packages/docusaurus-plugin-pwa/src/registerSw.js b/packages/docusaurus-plugin-pwa/src/registerSw.ts similarity index 92% rename from packages/docusaurus-plugin-pwa/src/registerSw.js rename to packages/docusaurus-plugin-pwa/src/registerSw.ts index 9226d9a6f054..92252cc5177c 100644 --- a/packages/docusaurus-plugin-pwa/src/registerSw.js +++ b/packages/docusaurus-plugin-pwa/src/registerSw.ts @@ -7,6 +7,14 @@ import {createStorageSlot} from '@docusaurus/theme-common'; +declare global { + namespace NodeJS { + interface ProcessEnv { + PWA_OFFLINE_MODE_ACTIVATION_STRATEGIES: (keyof typeof OfflineModeActivationStrategiesImplementations)[]; + } + } +} + // First: read the env variables (provided by Webpack) /* eslint-disable prefer-destructuring */ const PWA_SERVICE_WORKER_URL = process.env.PWA_SERVICE_WORKER_URL; @@ -34,7 +42,7 @@ async function clearRegistrations() { } await Promise.all( registrations.map(async (registration) => { - const result = await registration?.registration?.unregister(); + const result = await registration?.unregister(); if (debug) { console.log( `[Docusaurus-PWA][registerSw]: unregister() service worker registration`, @@ -65,6 +73,14 @@ https://stackoverflow.com/questions/51735869/check-if-user-has-already-installed async function isAppInstalledEventFired() { return AppInstalledEventFiredStorage.get() === 'true'; } + +declare global { + interface Navigator { + getInstalledRelatedApps: () => Promise<{platform: string}[]>; + connection: {saveData: boolean}; + } +} + async function isAppInstalledRelatedApps() { if ('getInstalledRelatedApps' in window.navigator) { const relatedApps = await navigator.getInstalledRelatedApps(); @@ -90,7 +106,9 @@ const OfflineModeActivationStrategiesImplementations = { new URLSearchParams(window.location.search).get('offlineMode') === 'true', }; -async function isStrategyActive(strategyName) { +async function isStrategyActive( + strategyName: keyof typeof OfflineModeActivationStrategiesImplementations, +) { return OfflineModeActivationStrategiesImplementations[strategyName](); } @@ -127,7 +145,7 @@ async function isOfflineModeEnabled() { return enabled; } -function createServiceWorkerUrl(params) { +function createServiceWorkerUrl(params: object) { const paramsQueryString = JSON.stringify(params); const url = `${PWA_SERVICE_WORKER_URL}?params=${encodeURIComponent( paramsQueryString, @@ -173,7 +191,7 @@ async function registerSW() { } }; - if (debug) { + if (debug && registration) { if (registration.active) { console.log( '[Docusaurus-PWA][registerSw]: registration.active', @@ -205,6 +223,7 @@ async function registerSW() { // Update current service worker if the next one finishes installing and // moves to waiting state in another tab. + // @ts-expect-error: not present in the API typings anymore wb.addEventListener('externalwaiting', (event) => { if (debug) { console.log('[Docusaurus-PWA][registerSw]: event externalwaiting', event); @@ -214,7 +233,7 @@ async function registerSW() { // Update service worker if the next one is already in the waiting state. // This happens when the user doesn't click on `reload` in the popup. - if (registration.waiting) { + if (registration?.waiting) { await handleServiceWorkerWaiting(); } } @@ -301,6 +320,6 @@ if (typeof window !== 'undefined') { addLegacyAppInstalledEventsListeners(); // Then try to register the SW using lazy/dynamic imports - registerSW().catch((e) => console.error('registerSW failed', e)); + registerSW().catch((e: unknown) => console.error('registerSW failed', e)); } } diff --git a/packages/docusaurus-plugin-pwa/src/renderReloadPopup.js b/packages/docusaurus-plugin-pwa/src/renderReloadPopup.tsx similarity index 75% rename from packages/docusaurus-plugin-pwa/src/renderReloadPopup.js rename to packages/docusaurus-plugin-pwa/src/renderReloadPopup.tsx index b26202ac3c5b..d4cac3601736 100644 --- a/packages/docusaurus-plugin-pwa/src/renderReloadPopup.js +++ b/packages/docusaurus-plugin-pwa/src/renderReloadPopup.tsx @@ -6,7 +6,7 @@ */ import React from 'react'; -import {render} from 'react-dom'; +import ReactDOM from 'react-dom'; const POPUP_CONTAINER_ID = 'pwa-popup-container'; @@ -19,8 +19,10 @@ const createContainer = () => { return container; }; -export default async function renderReloadPopup(props) { +export default async function renderReloadPopup(props: { + onReload: () => void; +}): Promise { const container = getContainer() || createContainer(); - const {default: ReloadPopup} = await import(process.env.PWA_RELOAD_POPUP); - render(, container); + const {default: ReloadPopup} = await import(process.env.PWA_RELOAD_POPUP!); + ReactDOM.render(, container); } diff --git a/packages/docusaurus-plugin-pwa/src/theme/PwaReloadPopup/index.tsx b/packages/docusaurus-plugin-pwa/src/theme/PwaReloadPopup/index.tsx index 20e8490fb82b..66d63d70e096 100644 --- a/packages/docusaurus-plugin-pwa/src/theme/PwaReloadPopup/index.tsx +++ b/packages/docusaurus-plugin-pwa/src/theme/PwaReloadPopup/index.tsx @@ -8,7 +8,6 @@ import React, {useState} from 'react'; import clsx from 'clsx'; import Translate, {translate} from '@docusaurus/Translate'; - import type {Props} from '@theme/PwaReloadPopup'; import styles from './styles.module.css'; diff --git a/packages/docusaurus-plugin-pwa/tsconfig.browser.json b/packages/docusaurus-plugin-pwa/tsconfig.browser.json deleted file mode 100644 index 3af8257cdf8d..000000000000 --- a/packages/docusaurus-plugin-pwa/tsconfig.browser.json +++ /dev/null @@ -1,8 +0,0 @@ -{ - "extends": "./tsconfig.json", - "compilerOptions": { - "module": "esnext", - "jsx": "react-native" - }, - "include": ["src/theme/", "src/*.d.ts"] -} diff --git a/packages/docusaurus-plugin-pwa/tsconfig.client.json b/packages/docusaurus-plugin-pwa/tsconfig.client.json new file mode 100644 index 000000000000..9404df7cd886 --- /dev/null +++ b/packages/docusaurus-plugin-pwa/tsconfig.client.json @@ -0,0 +1,20 @@ +{ + "extends": "../../tsconfig.json", + "compilerOptions": { + "noEmit": false, + "composite": true, + "incremental": true, + "tsBuildInfoFile": "./lib/.tsbuildinfo-client", + "rootDir": "src", + "outDir": "lib", + "module": "esnext", + "target": "esnext" + }, + "include": [ + "src/theme/", + "src/*.d.ts", + "src/registerSw.ts", + "src/renderReloadPopup.tsx" + ], + "exclude": ["**/__tests__/**"] +} diff --git a/packages/docusaurus-plugin-pwa/tsconfig.json b/packages/docusaurus-plugin-pwa/tsconfig.json index 51aec434b257..5eb9d05af96b 100644 --- a/packages/docusaurus-plugin-pwa/tsconfig.json +++ b/packages/docusaurus-plugin-pwa/tsconfig.json @@ -1,8 +1,19 @@ { "extends": "../../tsconfig.json", + "references": [{"path": "./tsconfig.client.json"}], "compilerOptions": { - "lib": ["DOM", "ES2019"], + "noEmit": false, + "incremental": true, + "tsBuildInfoFile": "./lib/.tsbuildinfo", + "module": "commonjs", "rootDir": "src", "outDir": "lib" - } + }, + "include": ["src"], + "exclude": [ + "src/theme/", + "src/registerSw.ts", + "src/renderReloadPopup.tsx", + "**/__tests__/**" + ] } diff --git a/packages/docusaurus-plugin-pwa/tsconfig.server.json b/packages/docusaurus-plugin-pwa/tsconfig.server.json deleted file mode 100644 index 1a463cd83a52..000000000000 --- a/packages/docusaurus-plugin-pwa/tsconfig.server.json +++ /dev/null @@ -1,4 +0,0 @@ -{ - "extends": "./tsconfig.json", - "include": ["src/*.ts"] -} diff --git a/packages/docusaurus-plugin-sitemap/.npmignore b/packages/docusaurus-plugin-sitemap/.npmignore index f2b994d4e359..03c9ae1e1b54 100644 --- a/packages/docusaurus-plugin-sitemap/.npmignore +++ b/packages/docusaurus-plugin-sitemap/.npmignore @@ -1,4 +1,3 @@ -copyUntypedFiles.mjs -.tsbuildinfo +.tsbuildinfo* tsconfig* __tests__ diff --git a/packages/docusaurus-plugin-sitemap/src/__tests__/createSitemap.test.ts b/packages/docusaurus-plugin-sitemap/src/__tests__/createSitemap.test.ts index c9008bd31004..26fd096caf41 100644 --- a/packages/docusaurus-plugin-sitemap/src/__tests__/createSitemap.test.ts +++ b/packages/docusaurus-plugin-sitemap/src/__tests__/createSitemap.test.ts @@ -6,9 +6,9 @@ */ import React from 'react'; +import {EnumChangefreq} from 'sitemap'; import createSitemap from '../createSitemap'; import type {DocusaurusConfig} from '@docusaurus/types'; -import {EnumChangefreq} from 'sitemap'; describe('createSitemap', () => { it('simple site', async () => { diff --git a/packages/docusaurus-plugin-sitemap/src/__tests__/options.test.ts b/packages/docusaurus-plugin-sitemap/src/__tests__/options.test.ts index c581cbece0ec..8d57746125b9 100644 --- a/packages/docusaurus-plugin-sitemap/src/__tests__/options.test.ts +++ b/packages/docusaurus-plugin-sitemap/src/__tests__/options.test.ts @@ -5,8 +5,8 @@ * LICENSE file in the root directory of this source tree. */ -import {validateOptions, DEFAULT_OPTIONS, type Options} from '../options'; import {normalizePluginOptions} from '@docusaurus/utils-validation'; +import {validateOptions, DEFAULT_OPTIONS, type Options} from '../options'; function testValidate(options: Options) { return validateOptions({validate: normalizePluginOptions, options}); diff --git a/packages/docusaurus-plugin-sitemap/src/createSitemap.ts b/packages/docusaurus-plugin-sitemap/src/createSitemap.ts index 5e1b619d356f..052dee692014 100644 --- a/packages/docusaurus-plugin-sitemap/src/createSitemap.ts +++ b/packages/docusaurus-plugin-sitemap/src/createSitemap.ts @@ -5,13 +5,13 @@ * LICENSE file in the root directory of this source tree. */ +import type {ReactElement} from 'react'; import {SitemapStream, streamToPromise} from 'sitemap'; import {applyTrailingSlash} from '@docusaurus/utils-common'; import {createMatcher} from '@docusaurus/utils'; import type {DocusaurusConfig} from '@docusaurus/types'; import type {HelmetServerState} from 'react-helmet-async'; import type {PluginOptions} from './options'; -import type {ReactElement} from 'react'; export default async function createSitemap( siteConfig: DocusaurusConfig, @@ -35,7 +35,7 @@ export default async function createSitemap( } // https://github.com/staylor/react-helmet-async/pull/167 const meta = head[route]?.meta.toComponent() as unknown as - | ReactElement[] + | ReactElement<{name?: string; content?: string}>[] | undefined; return !meta?.some( (tag) => tag.props.name === 'robots' && tag.props.content === 'noindex', diff --git a/packages/docusaurus-plugin-sitemap/tsconfig.json b/packages/docusaurus-plugin-sitemap/tsconfig.json index f5902ba1089b..80e43e9813ef 100644 --- a/packages/docusaurus-plugin-sitemap/tsconfig.json +++ b/packages/docusaurus-plugin-sitemap/tsconfig.json @@ -1,9 +1,13 @@ { "extends": "../../tsconfig.json", "compilerOptions": { + "noEmit": false, "incremental": true, "tsBuildInfoFile": "./lib/.tsbuildinfo", + "module": "commonjs", "rootDir": "src", "outDir": "lib" - } + }, + "include": ["src"], + "exclude": ["**/__tests__/**"] } diff --git a/packages/docusaurus-preset-classic/.npmignore b/packages/docusaurus-preset-classic/.npmignore index f2b994d4e359..03c9ae1e1b54 100644 --- a/packages/docusaurus-preset-classic/.npmignore +++ b/packages/docusaurus-preset-classic/.npmignore @@ -1,4 +1,3 @@ -copyUntypedFiles.mjs -.tsbuildinfo +.tsbuildinfo* tsconfig* __tests__ diff --git a/packages/docusaurus-preset-classic/tsconfig.json b/packages/docusaurus-preset-classic/tsconfig.json index f5902ba1089b..80e43e9813ef 100644 --- a/packages/docusaurus-preset-classic/tsconfig.json +++ b/packages/docusaurus-preset-classic/tsconfig.json @@ -1,9 +1,13 @@ { "extends": "../../tsconfig.json", "compilerOptions": { + "noEmit": false, "incremental": true, "tsBuildInfoFile": "./lib/.tsbuildinfo", + "module": "commonjs", "rootDir": "src", "outDir": "lib" - } + }, + "include": ["src"], + "exclude": ["**/__tests__/**"] } diff --git a/packages/docusaurus-remark-plugin-npm2yarn/.npmignore b/packages/docusaurus-remark-plugin-npm2yarn/.npmignore index f2b994d4e359..03c9ae1e1b54 100644 --- a/packages/docusaurus-remark-plugin-npm2yarn/.npmignore +++ b/packages/docusaurus-remark-plugin-npm2yarn/.npmignore @@ -1,4 +1,3 @@ -copyUntypedFiles.mjs -.tsbuildinfo +.tsbuildinfo* tsconfig* __tests__ diff --git a/packages/docusaurus-remark-plugin-npm2yarn/src/__tests__/index.test.ts b/packages/docusaurus-remark-plugin-npm2yarn/src/__tests__/index.test.ts index 6c6dc300e176..2ed961332463 100644 --- a/packages/docusaurus-remark-plugin-npm2yarn/src/__tests__/index.test.ts +++ b/packages/docusaurus-remark-plugin-npm2yarn/src/__tests__/index.test.ts @@ -5,11 +5,11 @@ * LICENSE file in the root directory of this source tree. */ -import remark from 'remark'; -import npm2yarn from '../index'; -import vfile from 'to-vfile'; import path from 'path'; +import vfile from 'to-vfile'; import mdx from 'remark-mdx'; +import remark from 'remark'; +import npm2yarn from '../index'; const processFixture = async (name: string, options?: {sync?: boolean}) => { const filePath = path.join(__dirname, '__fixtures__', `${name}.md`); diff --git a/packages/docusaurus-remark-plugin-npm2yarn/src/index.ts b/packages/docusaurus-remark-plugin-npm2yarn/src/index.ts index 0764763e9540..28b4c7e89150 100644 --- a/packages/docusaurus-remark-plugin-npm2yarn/src/index.ts +++ b/packages/docusaurus-remark-plugin-npm2yarn/src/index.ts @@ -5,11 +5,11 @@ * LICENSE file in the root directory of this source tree. */ +import visit from 'unist-util-visit'; +import npmToYarn from 'npm-to-yarn'; import type {Code, Content, Literal} from 'mdast'; import type {Plugin} from 'unified'; import type {Node, Parent} from 'unist'; -import visit from 'unist-util-visit'; -import npmToYarn from 'npm-to-yarn'; type PluginOptions = { sync?: boolean; diff --git a/packages/docusaurus-remark-plugin-npm2yarn/tsconfig.json b/packages/docusaurus-remark-plugin-npm2yarn/tsconfig.json index aee99fc0f38e..7807612b51a5 100644 --- a/packages/docusaurus-remark-plugin-npm2yarn/tsconfig.json +++ b/packages/docusaurus-remark-plugin-npm2yarn/tsconfig.json @@ -1,11 +1,15 @@ { "extends": "../../tsconfig.json", "compilerOptions": { + "noEmit": false, "incremental": true, "tsBuildInfoFile": "./lib/.tsbuildinfo", "sourceMap": true, "declarationMap": true, + "module": "commonjs", "rootDir": "src", "outDir": "lib" - } + }, + "include": ["src"], + "exclude": ["**/__tests__/**"] } diff --git a/packages/docusaurus-theme-classic/.npmignore b/packages/docusaurus-theme-classic/.npmignore index 3e3575db0c5a..03c9ae1e1b54 100644 --- a/packages/docusaurus-theme-classic/.npmignore +++ b/packages/docusaurus-theme-classic/.npmignore @@ -1,10 +1,3 @@ -copyUntypedFiles.mjs -.tsbuildinfo +.tsbuildinfo* tsconfig* __tests__ - -lib/theme -lib-next/** -!lib-next/theme/** - -babel.config.js diff --git a/packages/docusaurus-theme-classic/babel.config.js b/packages/docusaurus-theme-classic/babel.config.js deleted file mode 100644 index 0bbcfe267e45..000000000000 --- a/packages/docusaurus-theme-classic/babel.config.js +++ /dev/null @@ -1,30 +0,0 @@ -/** - * Copyright (c) Facebook, Inc. and its affiliates. - * - * This source code is licensed under the MIT license found in the - * LICENSE file in the root directory of this source tree. - */ - -module.exports = { - env: { - // USED FOR NODE/RUNTIME - // maybe we should differentiate both cases because - // we mostly need to transpile some features so that node does not crash... - lib: { - presets: [ - ['@babel/preset-env', {targets: {node: 14}, modules: 'commonjs'}], - ['@babel/preset-typescript', {isTSX: true, allExtensions: true}], - ], - }, - - // USED FOR JS SWIZZLE - // /lib-next folder is used as source to swizzle JS source code - // This JS code is created from TS source code - // This source code should look clean/human readable to be usable - 'lib-next': { - presets: [ - ['@babel/preset-typescript', {isTSX: true, allExtensions: true}], - ], - }, - }, -}; diff --git a/packages/docusaurus-theme-classic/package.json b/packages/docusaurus-theme-classic/package.json index e2b20b238174..577babee2892 100644 --- a/packages/docusaurus-theme-classic/package.json +++ b/packages/docusaurus-theme-classic/package.json @@ -14,11 +14,10 @@ }, "license": "MIT", "scripts": { - "build": "tsc --noEmit && yarn babel:lib && yarn babel:lib-next && yarn format:lib-next", - "watch": "concurrently --names \"lib,lib-next,tsc\" --kill-others \"yarn babel:lib --watch\" \"yarn babel:lib-next --watch\" \"yarn tsc --watch\"", - "babel:lib": "cross-env BABEL_ENV=lib babel src -d lib --extensions \".tsx,.ts\" --ignore \"**/*.d.ts\" --copy-files", - "babel:lib-next": "cross-env BABEL_ENV=lib-next babel src -d lib-next --extensions \".tsx,.ts\" --ignore \"**/*.d.ts\" --copy-files", - "format:lib-next": "prettier --config ../../.prettierrc --write \"lib-next/**/*.{js,ts,jsx,tsc}\"" + "build": "tsc --build && node ../../admin/scripts/copyUntypedFiles.js && prettier --config ../../.prettierrc --write \"lib/theme/**/*.js\"", + "watch": "run-p -c copy:watch build:watch", + "build:watch": "tsc --build --watch", + "copy:watch": "node ../../admin/scripts/copyUntypedFiles.js --watch" }, "dependencies": { "@docusaurus/core": "2.0.0-beta.20", @@ -36,23 +35,20 @@ "infima": "0.2.0-alpha.39", "lodash": "^4.17.21", "nprogress": "^0.2.0", - "postcss": "^8.4.13", - "prism-react-renderer": "^1.3.1", + "postcss": "^8.4.14", + "prism-react-renderer": "^1.3.3", "prismjs": "^1.28.0", - "react-router-dom": "^5.2.0", - "rtlcss": "^3.5.0" + "react-router-dom": "^5.3.3", + "rtlcss": "^3.5.0", + "tslib": "^2.4.0" }, "devDependencies": { - "@babel/cli": "^7.17.10", - "@babel/core": "^7.17.10", - "@babel/preset-typescript": "^7.16.7", "@docusaurus/module-type-aliases": "2.0.0-beta.20", "@docusaurus/types": "2.0.0-beta.20", "@types/mdx-js__react": "^1.5.5", "@types/nprogress": "^0.2.0", "@types/prismjs": "^1.26.0", - "@types/rtlcss": "^3.1.4", - "cross-env": "^7.0.3", + "@types/rtlcss": "^3.5.0", "fs-extra": "^10.1.0", "react-test-renderer": "^17.0.2", "utility-types": "^3.10.0" diff --git a/packages/docusaurus-theme-classic/src/__tests__/translations.test.ts b/packages/docusaurus-theme-classic/src/__tests__/translations.test.ts index 1c530f978e86..48a2c70f3ff7 100644 --- a/packages/docusaurus-theme-classic/src/__tests__/translations.test.ts +++ b/packages/docusaurus-theme-classic/src/__tests__/translations.test.ts @@ -5,9 +5,9 @@ * LICENSE file in the root directory of this source tree. */ +import {updateTranslationFileMessages} from '@docusaurus/utils'; import {getTranslationFiles, translateThemeConfig} from '../translations'; import type {ThemeConfig} from '@docusaurus/theme-common'; -import {updateTranslationFileMessages} from '@docusaurus/utils'; const ThemeConfigSample: ThemeConfig = { colorMode: {}, diff --git a/packages/docusaurus-theme-classic/src/__tests__/validateThemeConfig.test.ts b/packages/docusaurus-theme-classic/src/__tests__/validateThemeConfig.test.ts index a4ca7e346018..8d85a4d376aa 100644 --- a/packages/docusaurus-theme-classic/src/__tests__/validateThemeConfig.test.ts +++ b/packages/docusaurus-theme-classic/src/__tests__/validateThemeConfig.test.ts @@ -6,11 +6,11 @@ */ import _ from 'lodash'; -import {ThemeConfigSchema, DEFAULT_CONFIG} from '../validateThemeConfig'; import {normalizeThemeConfig} from '@docusaurus/utils-validation'; import theme from 'prism-react-renderer/themes/github'; import darkTheme from 'prism-react-renderer/themes/dracula'; +import {ThemeConfigSchema, DEFAULT_CONFIG} from '../validateThemeConfig'; function testValidateThemeConfig(partialThemeConfig: {[key: string]: unknown}) { return normalizeThemeConfig(ThemeConfigSchema, { diff --git a/packages/docusaurus-theme-classic/src/index.ts b/packages/docusaurus-theme-classic/src/index.ts index 9fd370a2e5f8..a0cb4629cb58 100644 --- a/packages/docusaurus-theme-classic/src/index.ts +++ b/packages/docusaurus-theme-classic/src/index.ts @@ -6,13 +6,13 @@ */ import path from 'path'; -import type {LoadContext, Plugin} from '@docusaurus/types'; -import type {ThemeConfig} from '@docusaurus/theme-common'; -import {getTranslationFiles, translateThemeConfig} from './translations'; import {createRequire} from 'module'; -import type {Plugin as PostCssPlugin} from 'postcss'; import rtlcss from 'rtlcss'; import {readDefaultCodeTranslationMessages} from '@docusaurus/theme-translations'; +import {getTranslationFiles, translateThemeConfig} from './translations'; +import type {LoadContext, Plugin} from '@docusaurus/types'; +import type {ThemeConfig} from '@docusaurus/theme-common'; +import type {Plugin as PostCssPlugin} from 'postcss'; import type {Options} from '@docusaurus/theme-classic'; import type webpack from 'webpack'; @@ -112,7 +112,7 @@ export default function themeClassic( name: 'docusaurus-theme-classic', getThemePath() { - return '../lib-next/theme'; + return '../lib/theme'; }, getTypeScriptThemePath() { diff --git a/packages/docusaurus-theme-classic/src/theme/BlogArchivePage/index.tsx b/packages/docusaurus-theme-classic/src/theme/BlogArchivePage/index.tsx index a05afdf43fe8..763d0661e25f 100644 --- a/packages/docusaurus-theme-classic/src/theme/BlogArchivePage/index.tsx +++ b/packages/docusaurus-theme-classic/src/theme/BlogArchivePage/index.tsx @@ -6,11 +6,11 @@ */ import React from 'react'; -import Layout from '@theme/Layout'; import Link from '@docusaurus/Link'; -import type {ArchiveBlogPost, Props} from '@theme/BlogArchivePage'; import {translate} from '@docusaurus/Translate'; import {PageMetadata} from '@docusaurus/theme-common'; +import Layout from '@theme/Layout'; +import type {ArchiveBlogPost, Props} from '@theme/BlogArchivePage'; type YearProp = { year: string; diff --git a/packages/docusaurus-theme-classic/src/theme/BlogListPage/index.tsx b/packages/docusaurus-theme-classic/src/theme/BlogListPage/index.tsx index 910328b214ce..72270058d99d 100644 --- a/packages/docusaurus-theme-classic/src/theme/BlogListPage/index.tsx +++ b/packages/docusaurus-theme-classic/src/theme/BlogListPage/index.tsx @@ -6,19 +6,19 @@ */ import React from 'react'; +import clsx from 'clsx'; import useDocusaurusContext from '@docusaurus/useDocusaurusContext'; -import BlogLayout from '@theme/BlogLayout'; -import BlogPostItem from '@theme/BlogPostItem'; -import BlogListPaginator from '@theme/BlogListPaginator'; -import type {Props} from '@theme/BlogListPage'; import { PageMetadata, HtmlClassNameProvider, ThemeClassNames, } from '@docusaurus/theme-common'; +import BlogLayout from '@theme/BlogLayout'; +import BlogPostItem from '@theme/BlogPostItem'; +import BlogListPaginator from '@theme/BlogListPaginator'; import SearchMetadata from '@theme/SearchMetadata'; -import clsx from 'clsx'; +import type {Props} from '@theme/BlogListPage'; function BlogListPageMetadata(props: Props): JSX.Element { const {metadata} = props; diff --git a/packages/docusaurus-theme-classic/src/theme/BlogPostAuthors/index.tsx b/packages/docusaurus-theme-classic/src/theme/BlogPostAuthors/index.tsx index 4e36a7142553..99386d4ae900 100644 --- a/packages/docusaurus-theme-classic/src/theme/BlogPostAuthors/index.tsx +++ b/packages/docusaurus-theme-classic/src/theme/BlogPostAuthors/index.tsx @@ -7,8 +7,8 @@ import React from 'react'; import clsx from 'clsx'; -import type {Props} from '@theme/BlogPostAuthors'; import BlogPostAuthor from '@theme/BlogPostAuthor'; +import type {Props} from '@theme/BlogPostAuthors'; import styles from './styles.module.css'; diff --git a/packages/docusaurus-theme-classic/src/theme/BlogPostItem/index.tsx b/packages/docusaurus-theme-classic/src/theme/BlogPostItem/index.tsx index e531b8e9854b..b0fcad3236b4 100644 --- a/packages/docusaurus-theme-classic/src/theme/BlogPostItem/index.tsx +++ b/packages/docusaurus-theme-classic/src/theme/BlogPostItem/index.tsx @@ -14,11 +14,11 @@ import {usePluralForm} from '@docusaurus/theme-common'; import {blogPostContainerID} from '@docusaurus/utils-common'; import MDXContent from '@theme/MDXContent'; import EditThisPage from '@theme/EditThisPage'; +import TagsListInline from '@theme/TagsListInline'; +import BlogPostAuthors from '@theme/BlogPostAuthors'; import type {Props} from '@theme/BlogPostItem'; import styles from './styles.module.css'; -import TagsListInline from '@theme/TagsListInline'; -import BlogPostAuthors from '@theme/BlogPostAuthors'; // Very simple pluralization: probably good enough for now function useReadingTimePlural() { diff --git a/packages/docusaurus-theme-classic/src/theme/BlogPostPage/index.tsx b/packages/docusaurus-theme-classic/src/theme/BlogPostPage/index.tsx index c7b9ec88e5d3..3d47fc4dd379 100644 --- a/packages/docusaurus-theme-classic/src/theme/BlogPostPage/index.tsx +++ b/packages/docusaurus-theme-classic/src/theme/BlogPostPage/index.tsx @@ -6,17 +6,17 @@ */ import React from 'react'; -import BlogLayout from '@theme/BlogLayout'; -import BlogPostItem from '@theme/BlogPostItem'; -import BlogPostPaginator from '@theme/BlogPostPaginator'; -import type {Props} from '@theme/BlogPostPage'; +import clsx from 'clsx'; import { PageMetadata, HtmlClassNameProvider, ThemeClassNames, } from '@docusaurus/theme-common'; +import BlogLayout from '@theme/BlogLayout'; +import BlogPostItem from '@theme/BlogPostItem'; +import BlogPostPaginator from '@theme/BlogPostPaginator'; import TOC from '@theme/TOC'; -import clsx from 'clsx'; +import type {Props} from '@theme/BlogPostPage'; function BlogPostPageMetadata(props: Props): JSX.Element { const {content: BlogPostContents} = props; diff --git a/packages/docusaurus-theme-classic/src/theme/BlogSidebar/Desktop/index.tsx b/packages/docusaurus-theme-classic/src/theme/BlogSidebar/Desktop/index.tsx index ff74637e9ea5..f010d2144836 100644 --- a/packages/docusaurus-theme-classic/src/theme/BlogSidebar/Desktop/index.tsx +++ b/packages/docusaurus-theme-classic/src/theme/BlogSidebar/Desktop/index.tsx @@ -9,9 +9,9 @@ import React from 'react'; import clsx from 'clsx'; import Link from '@docusaurus/Link'; import {translate} from '@docusaurus/Translate'; +import type {Props} from '@theme/BlogSidebar/Desktop'; import styles from './styles.module.css'; -import type {Props} from '@theme/BlogSidebar/Desktop'; export default function BlogSidebarDesktop({sidebar}: Props): JSX.Element { return ( diff --git a/packages/docusaurus-theme-classic/src/theme/BlogSidebar/index.tsx b/packages/docusaurus-theme-classic/src/theme/BlogSidebar/index.tsx index 742f4bd42781..f8458777efdd 100644 --- a/packages/docusaurus-theme-classic/src/theme/BlogSidebar/index.tsx +++ b/packages/docusaurus-theme-classic/src/theme/BlogSidebar/index.tsx @@ -6,9 +6,9 @@ */ import React from 'react'; +import {useWindowSize} from '@docusaurus/theme-common'; import BlogSidebarDesktop from '@theme/BlogSidebar/Desktop'; import BlogSidebarMobile from '@theme/BlogSidebar/Mobile'; -import {useWindowSize} from '@docusaurus/theme-common'; import type {Props} from '@theme/BlogSidebar'; export default function BlogSidebar({sidebar}: Props): JSX.Element | null { diff --git a/packages/docusaurus-theme-classic/src/theme/BlogTagsListPage/index.tsx b/packages/docusaurus-theme-classic/src/theme/BlogTagsListPage/index.tsx index 2f53b6ee41fa..017329d478b1 100644 --- a/packages/docusaurus-theme-classic/src/theme/BlogTagsListPage/index.tsx +++ b/packages/docusaurus-theme-classic/src/theme/BlogTagsListPage/index.tsx @@ -6,18 +6,17 @@ */ import React from 'react'; - -import BlogLayout from '@theme/BlogLayout'; -import TagsListByLetter from '@theme/TagsListByLetter'; -import type {Props} from '@theme/BlogTagsListPage'; +import clsx from 'clsx'; import { PageMetadata, HtmlClassNameProvider, ThemeClassNames, translateTagsPageTitle, } from '@docusaurus/theme-common'; +import BlogLayout from '@theme/BlogLayout'; +import TagsListByLetter from '@theme/TagsListByLetter'; +import type {Props} from '@theme/BlogTagsListPage'; import SearchMetadata from '../SearchMetadata'; -import clsx from 'clsx'; export default function BlogTagsListPage({tags, sidebar}: Props): JSX.Element { const title = translateTagsPageTitle(); diff --git a/packages/docusaurus-theme-classic/src/theme/BlogTagsPostsPage/index.tsx b/packages/docusaurus-theme-classic/src/theme/BlogTagsPostsPage/index.tsx index fddda0795d75..312bc945e107 100644 --- a/packages/docusaurus-theme-classic/src/theme/BlogTagsPostsPage/index.tsx +++ b/packages/docusaurus-theme-classic/src/theme/BlogTagsPostsPage/index.tsx @@ -6,11 +6,7 @@ */ import React from 'react'; - -import Link from '@docusaurus/Link'; -import BlogLayout from '@theme/BlogLayout'; -import BlogPostItem from '@theme/BlogPostItem'; -import type {Props} from '@theme/BlogTagsPostsPage'; +import clsx from 'clsx'; import Translate, {translate} from '@docusaurus/Translate'; import { PageMetadata, @@ -18,9 +14,12 @@ import { ThemeClassNames, usePluralForm, } from '@docusaurus/theme-common'; +import Link from '@docusaurus/Link'; +import BlogLayout from '@theme/BlogLayout'; +import BlogPostItem from '@theme/BlogPostItem'; import BlogListPaginator from '@theme/BlogListPaginator'; import SearchMetadata from '@theme/SearchMetadata'; -import clsx from 'clsx'; +import type {Props} from '@theme/BlogTagsPostsPage'; // Very simple pluralization: probably good enough for now function useBlogPostsPlural() { diff --git a/packages/docusaurus-theme-classic/src/theme/CodeBlock/Content/Element.tsx b/packages/docusaurus-theme-classic/src/theme/CodeBlock/Content/Element.tsx index 3f130e80e6d6..a31cd85731ac 100644 --- a/packages/docusaurus-theme-classic/src/theme/CodeBlock/Content/Element.tsx +++ b/packages/docusaurus-theme-classic/src/theme/CodeBlock/Content/Element.tsx @@ -6,8 +6,8 @@ */ import React from 'react'; -import Container from '@theme/CodeBlock/Container'; import clsx from 'clsx'; +import Container from '@theme/CodeBlock/Container'; import type {Props} from '@theme/CodeBlock/Content/Element'; import styles from './styles.module.css'; diff --git a/packages/docusaurus-theme-classic/src/theme/CodeBlock/Content/String.tsx b/packages/docusaurus-theme-classic/src/theme/CodeBlock/Content/String.tsx index f73819a37f20..5a9384f7b638 100644 --- a/packages/docusaurus-theme-classic/src/theme/CodeBlock/Content/String.tsx +++ b/packages/docusaurus-theme-classic/src/theme/CodeBlock/Content/String.tsx @@ -6,6 +6,7 @@ */ import React from 'react'; +import clsx from 'clsx'; import { useThemeConfig, parseCodeBlockTitle, @@ -15,7 +16,6 @@ import { usePrismTheme, useCodeWordWrap, } from '@docusaurus/theme-common'; -import clsx from 'clsx'; import Highlight, {defaultProps, type Language} from 'prism-react-renderer'; import Line from '@theme/CodeBlock/Line'; import CopyButton from '@theme/CodeBlock/CopyButton'; diff --git a/packages/docusaurus-theme-classic/src/theme/CodeBlock/Line/index.tsx b/packages/docusaurus-theme-classic/src/theme/CodeBlock/Line/index.tsx index e15d70abfa4e..3b6a8a306b0a 100644 --- a/packages/docusaurus-theme-classic/src/theme/CodeBlock/Line/index.tsx +++ b/packages/docusaurus-theme-classic/src/theme/CodeBlock/Line/index.tsx @@ -8,6 +8,7 @@ import React from 'react'; import clsx from 'clsx'; import type {Props} from '@theme/CodeBlock/Line'; + import styles from './styles.module.css'; export default function CodeBlockLine({ diff --git a/packages/docusaurus-theme-classic/src/theme/CodeBlock/index.tsx b/packages/docusaurus-theme-classic/src/theme/CodeBlock/index.tsx index 9565932fafcb..e672185a515f 100644 --- a/packages/docusaurus-theme-classic/src/theme/CodeBlock/index.tsx +++ b/packages/docusaurus-theme-classic/src/theme/CodeBlock/index.tsx @@ -7,9 +7,9 @@ import React, {isValidElement, type ReactNode} from 'react'; import useIsBrowser from '@docusaurus/useIsBrowser'; -import type {Props} from '@theme/CodeBlock'; import ElementContent from '@theme/CodeBlock/Content/Element'; import StringContent from '@theme/CodeBlock/Content/String'; +import type {Props} from '@theme/CodeBlock'; /** * Best attempt to make the children a plain string so it is copyable. If there diff --git a/packages/docusaurus-theme-classic/src/theme/ColorModeToggle/index.tsx b/packages/docusaurus-theme-classic/src/theme/ColorModeToggle/index.tsx index e119f2ae33ed..2b0407a547be 100644 --- a/packages/docusaurus-theme-classic/src/theme/ColorModeToggle/index.tsx +++ b/packages/docusaurus-theme-classic/src/theme/ColorModeToggle/index.tsx @@ -6,13 +6,13 @@ */ import React from 'react'; -import type {Props} from '@theme/ColorModeToggle'; +import clsx from 'clsx'; import useIsBrowser from '@docusaurus/useIsBrowser'; import {translate} from '@docusaurus/Translate'; import IconLightMode from '@theme/IconLightMode'; import IconDarkMode from '@theme/IconDarkMode'; +import type {Props} from '@theme/ColorModeToggle'; -import clsx from 'clsx'; import styles from './styles.module.css'; function ColorModeToggle({className, value, onChange}: Props): JSX.Element { diff --git a/packages/docusaurus-theme-classic/src/theme/Details/index.tsx b/packages/docusaurus-theme-classic/src/theme/Details/index.tsx index 188729351494..b6e7b06f6bd7 100644 --- a/packages/docusaurus-theme-classic/src/theme/Details/index.tsx +++ b/packages/docusaurus-theme-classic/src/theme/Details/index.tsx @@ -9,6 +9,7 @@ import React from 'react'; import clsx from 'clsx'; import {Details as DetailsGeneric} from '@docusaurus/theme-common/Details'; import type {Props} from '@theme/Details'; + import styles from './styles.module.css'; // Should we have a custom details/summary comp in Infima instead of reusing diff --git a/packages/docusaurus-theme-classic/src/theme/DocBreadcrumbs/index.tsx b/packages/docusaurus-theme-classic/src/theme/DocBreadcrumbs/index.tsx index 0ed00dc1f43a..44200b2f329a 100644 --- a/packages/docusaurus-theme-classic/src/theme/DocBreadcrumbs/index.tsx +++ b/packages/docusaurus-theme-classic/src/theme/DocBreadcrumbs/index.tsx @@ -6,18 +6,19 @@ */ import React, {type ReactNode} from 'react'; +import clsx from 'clsx'; import { ThemeClassNames, useSidebarBreadcrumbs, useHomePageRoute, } from '@docusaurus/theme-common'; -import styles from './styles.module.css'; -import clsx from 'clsx'; import Link from '@docusaurus/Link'; import useBaseUrl from '@docusaurus/useBaseUrl'; import {translate} from '@docusaurus/Translate'; import IconHome from '@theme/IconHome'; +import styles from './styles.module.css'; + // TODO move to design system folder function BreadcrumbsItemLink({ children, diff --git a/packages/docusaurus-theme-classic/src/theme/DocCard/index.tsx b/packages/docusaurus-theme-classic/src/theme/DocCard/index.tsx index 15c8ac155d51..fc63f1949f47 100644 --- a/packages/docusaurus-theme-classic/src/theme/DocCard/index.tsx +++ b/packages/docusaurus-theme-classic/src/theme/DocCard/index.tsx @@ -6,17 +6,18 @@ */ import React, {type ReactNode} from 'react'; +import clsx from 'clsx'; import Link from '@docusaurus/Link'; +import {findFirstCategoryLink, useDocById} from '@docusaurus/theme-common'; +import isInternalUrl from '@docusaurus/isInternalUrl'; +import {translate} from '@docusaurus/Translate'; +import type {Props} from '@theme/DocCard'; + +import styles from './styles.module.css'; import type { PropSidebarItemCategory, PropSidebarItemLink, } from '@docusaurus/plugin-content-docs'; -import type {Props} from '@theme/DocCard'; -import {findFirstCategoryLink, useDocById} from '@docusaurus/theme-common'; -import clsx from 'clsx'; -import styles from './styles.module.css'; -import isInternalUrl from '@docusaurus/isInternalUrl'; -import {translate} from '@docusaurus/Translate'; function CardContainer({ href, diff --git a/packages/docusaurus-theme-classic/src/theme/DocCardList/index.tsx b/packages/docusaurus-theme-classic/src/theme/DocCardList/index.tsx index d2e61b8037c4..3c105378ae81 100644 --- a/packages/docusaurus-theme-classic/src/theme/DocCardList/index.tsx +++ b/packages/docusaurus-theme-classic/src/theme/DocCardList/index.tsx @@ -7,11 +7,10 @@ import React from 'react'; import clsx from 'clsx'; - -import DocCard from '@theme/DocCard'; -import type {PropSidebarItem} from '@docusaurus/plugin-content-docs'; import {findFirstCategoryLink} from '@docusaurus/theme-common'; +import DocCard from '@theme/DocCard'; import type {Props} from '@theme/DocCardList'; +import type {PropSidebarItem} from '@docusaurus/plugin-content-docs'; // Filter categories that don't have a link. function filterItems(items: PropSidebarItem[]): PropSidebarItem[] { diff --git a/packages/docusaurus-theme-classic/src/theme/DocCategoryGeneratedIndexPage/index.tsx b/packages/docusaurus-theme-classic/src/theme/DocCategoryGeneratedIndexPage/index.tsx index a1b183f1705b..0058b71596a5 100644 --- a/packages/docusaurus-theme-classic/src/theme/DocCategoryGeneratedIndexPage/index.tsx +++ b/packages/docusaurus-theme-classic/src/theme/DocCategoryGeneratedIndexPage/index.tsx @@ -10,14 +10,14 @@ import { PageMetadata, useCurrentSidebarCategory, } from '@docusaurus/theme-common'; -import type {Props} from '@theme/DocCategoryGeneratedIndexPage'; +import useBaseUrl from '@docusaurus/useBaseUrl'; import DocCardList from '@theme/DocCardList'; import DocPaginator from '@theme/DocPaginator'; import DocVersionBanner from '@theme/DocVersionBanner'; import DocVersionBadge from '@theme/DocVersionBadge'; import DocBreadcrumbs from '@theme/DocBreadcrumbs'; import Heading from '@theme/Heading'; -import useBaseUrl from '@docusaurus/useBaseUrl'; +import type {Props} from '@theme/DocCategoryGeneratedIndexPage'; import styles from './styles.module.css'; diff --git a/packages/docusaurus-theme-classic/src/theme/DocItem/index.tsx b/packages/docusaurus-theme-classic/src/theme/DocItem/index.tsx index 77265efccbd2..fa75f1c162e5 100644 --- a/packages/docusaurus-theme-classic/src/theme/DocItem/index.tsx +++ b/packages/docusaurus-theme-classic/src/theme/DocItem/index.tsx @@ -7,23 +7,24 @@ import React from 'react'; import clsx from 'clsx'; +import { + PageMetadata, + HtmlClassNameProvider, + ThemeClassNames, + useWindowSize, +} from '@docusaurus/theme-common'; import DocPaginator from '@theme/DocPaginator'; import DocVersionBanner from '@theme/DocVersionBanner'; import DocVersionBadge from '@theme/DocVersionBadge'; -import type {Props} from '@theme/DocItem'; import DocItemFooter from '@theme/DocItemFooter'; import TOC from '@theme/TOC'; import TOCCollapsible from '@theme/TOCCollapsible'; import Heading from '@theme/Heading'; -import styles from './styles.module.css'; -import { - PageMetadata, - HtmlClassNameProvider, - ThemeClassNames, - useWindowSize, -} from '@docusaurus/theme-common'; import DocBreadcrumbs from '@theme/DocBreadcrumbs'; import MDXContent from '@theme/MDXContent'; +import type {Props} from '@theme/DocItem'; + +import styles from './styles.module.css'; function DocItemMetadata(props: Props): JSX.Element { const {content: DocContent} = props; diff --git a/packages/docusaurus-theme-classic/src/theme/DocItemFooter/index.tsx b/packages/docusaurus-theme-classic/src/theme/DocItemFooter/index.tsx index 056391687cb0..c6f998cb61c9 100644 --- a/packages/docusaurus-theme-classic/src/theme/DocItemFooter/index.tsx +++ b/packages/docusaurus-theme-classic/src/theme/DocItemFooter/index.tsx @@ -7,16 +7,15 @@ import React from 'react'; import clsx from 'clsx'; - +import {ThemeClassNames} from '@docusaurus/theme-common'; import LastUpdated from '@theme/LastUpdated'; -import type {Props} from '@theme/DocItem'; import EditThisPage from '@theme/EditThisPage'; import TagsListInline, { type Props as TagsListInlineProps, } from '@theme/TagsListInline'; +import type {Props} from '@theme/DocItem'; import styles from './styles.module.css'; -import {ThemeClassNames} from '@docusaurus/theme-common'; function TagsRow(props: TagsListInlineProps) { return ( diff --git a/packages/docusaurus-theme-classic/src/theme/DocPage/Layout/Main/index.tsx b/packages/docusaurus-theme-classic/src/theme/DocPage/Layout/Main/index.tsx index 3cc4f0479e00..61ccdafdb6cc 100644 --- a/packages/docusaurus-theme-classic/src/theme/DocPage/Layout/Main/index.tsx +++ b/packages/docusaurus-theme-classic/src/theme/DocPage/Layout/Main/index.tsx @@ -6,12 +6,11 @@ */ import React from 'react'; - +import clsx from 'clsx'; import {useDocsSidebar} from '@docusaurus/theme-common'; +import type {Props} from '@theme/DocPage/Layout/Main'; -import clsx from 'clsx'; import styles from './styles.module.css'; -import type {Props} from '@theme/DocPage/Layout/Main'; export default function DocPageLayoutMain({ hiddenSidebarContainer, diff --git a/packages/docusaurus-theme-classic/src/theme/DocPage/Layout/Sidebar/ExpandButton/index.tsx b/packages/docusaurus-theme-classic/src/theme/DocPage/Layout/Sidebar/ExpandButton/index.tsx index 7d68031577fa..0cf889639321 100644 --- a/packages/docusaurus-theme-classic/src/theme/DocPage/Layout/Sidebar/ExpandButton/index.tsx +++ b/packages/docusaurus-theme-classic/src/theme/DocPage/Layout/Sidebar/ExpandButton/index.tsx @@ -6,8 +6,8 @@ */ import React from 'react'; -import IconArrow from '@theme/IconArrow'; import {translate} from '@docusaurus/Translate'; +import IconArrow from '@theme/IconArrow'; import type {Props} from '@theme/DocPage/Layout/Sidebar/ExpandButton'; import styles from './styles.module.css'; diff --git a/packages/docusaurus-theme-classic/src/theme/DocPage/Layout/Sidebar/index.tsx b/packages/docusaurus-theme-classic/src/theme/DocPage/Layout/Sidebar/index.tsx index 438d9f814e79..150fd888a3ef 100644 --- a/packages/docusaurus-theme-classic/src/theme/DocPage/Layout/Sidebar/index.tsx +++ b/packages/docusaurus-theme-classic/src/theme/DocPage/Layout/Sidebar/index.tsx @@ -6,15 +6,14 @@ */ import React, {type ReactNode, useState, useCallback} from 'react'; -import DocSidebar from '@theme/DocSidebar'; +import clsx from 'clsx'; +import {ThemeClassNames, useDocsSidebar} from '@docusaurus/theme-common'; import {useLocation} from '@docusaurus/router'; -import type {Props} from '@theme/DocPage/Layout/Sidebar'; +import DocSidebar from '@theme/DocSidebar'; import ExpandButton from '@theme/DocPage/Layout/Sidebar/ExpandButton'; +import type {Props} from '@theme/DocPage/Layout/Sidebar'; -import clsx from 'clsx'; -import styles from './index.module.css'; - -import {ThemeClassNames, useDocsSidebar} from '@docusaurus/theme-common'; +import styles from './styles.module.css'; // Reset sidebar state when sidebar changes // Use React key to unmount/remount the children diff --git a/packages/docusaurus-theme-classic/src/theme/DocPage/Layout/Sidebar/index.module.css b/packages/docusaurus-theme-classic/src/theme/DocPage/Layout/Sidebar/styles.module.css similarity index 100% rename from packages/docusaurus-theme-classic/src/theme/DocPage/Layout/Sidebar/index.module.css rename to packages/docusaurus-theme-classic/src/theme/DocPage/Layout/Sidebar/styles.module.css diff --git a/packages/docusaurus-theme-classic/src/theme/DocPage/Layout/index.tsx b/packages/docusaurus-theme-classic/src/theme/DocPage/Layout/index.tsx index 8f95807481fd..d5a48c1a68b1 100644 --- a/packages/docusaurus-theme-classic/src/theme/DocPage/Layout/index.tsx +++ b/packages/docusaurus-theme-classic/src/theme/DocPage/Layout/index.tsx @@ -6,15 +6,14 @@ */ import React, {useState} from 'react'; +import {useDocsSidebar} from '@docusaurus/theme-common'; import Layout from '@theme/Layout'; import BackToTopButton from '@theme/BackToTopButton'; -import type {Props} from '@theme/DocPage/Layout'; import DocPageLayoutSidebar from '@theme/DocPage/Layout/Sidebar'; import DocPageLayoutMain from '@theme/DocPage/Layout/Main'; +import type {Props} from '@theme/DocPage/Layout'; -import styles from './index.module.css'; - -import {useDocsSidebar} from '@docusaurus/theme-common'; +import styles from './styles.module.css'; export default function DocPageLayout({children}: Props): JSX.Element { const sidebar = useDocsSidebar(); diff --git a/packages/docusaurus-theme-classic/src/theme/DocPage/Layout/index.module.css b/packages/docusaurus-theme-classic/src/theme/DocPage/Layout/styles.module.css similarity index 100% rename from packages/docusaurus-theme-classic/src/theme/DocPage/Layout/index.module.css rename to packages/docusaurus-theme-classic/src/theme/DocPage/Layout/styles.module.css diff --git a/packages/docusaurus-theme-classic/src/theme/DocPage/index.tsx b/packages/docusaurus-theme-classic/src/theme/DocPage/index.tsx index b1404be79846..3e45dbbda399 100644 --- a/packages/docusaurus-theme-classic/src/theme/DocPage/index.tsx +++ b/packages/docusaurus-theme-classic/src/theme/DocPage/index.tsx @@ -6,12 +6,7 @@ */ import React from 'react'; -import NotFound from '@theme/NotFound'; -import type {Props} from '@theme/DocPage'; -import DocPageLayout from '@theme/DocPage/Layout'; - import clsx from 'clsx'; - import { HtmlClassNameProvider, ThemeClassNames, @@ -20,7 +15,10 @@ import { DocsVersionProvider, useDocRouteMetadata, } from '@docusaurus/theme-common'; +import DocPageLayout from '@theme/DocPage/Layout'; +import NotFound from '@theme/NotFound'; import SearchMetadata from '@theme/SearchMetadata'; +import type {Props} from '@theme/DocPage'; export default function DocPage(props: Props): JSX.Element { const {versionMetadata} = props; diff --git a/packages/docusaurus-theme-classic/src/theme/DocSidebar/Desktop/CollapseButton/index.tsx b/packages/docusaurus-theme-classic/src/theme/DocSidebar/Desktop/CollapseButton/index.tsx index c902ac90d6ca..f5d96d16481f 100644 --- a/packages/docusaurus-theme-classic/src/theme/DocSidebar/Desktop/CollapseButton/index.tsx +++ b/packages/docusaurus-theme-classic/src/theme/DocSidebar/Desktop/CollapseButton/index.tsx @@ -7,8 +7,8 @@ import React from 'react'; import clsx from 'clsx'; -import IconArrow from '@theme/IconArrow'; import {translate} from '@docusaurus/Translate'; +import IconArrow from '@theme/IconArrow'; import type {Props} from '@theme/DocSidebar/Desktop/CollapseButton'; import styles from './styles.module.css'; diff --git a/packages/docusaurus-theme-classic/src/theme/DocSidebar/index.tsx b/packages/docusaurus-theme-classic/src/theme/DocSidebar/index.tsx index 5bbd9e2eb710..f057073d60dd 100644 --- a/packages/docusaurus-theme-classic/src/theme/DocSidebar/index.tsx +++ b/packages/docusaurus-theme-classic/src/theme/DocSidebar/index.tsx @@ -7,9 +7,9 @@ import React from 'react'; import {useWindowSize} from '@docusaurus/theme-common'; -import type {Props} from '@theme/DocSidebar'; import DocSidebarDesktop from '@theme/DocSidebar/Desktop'; import DocSidebarMobile from '@theme/DocSidebar/Mobile'; +import type {Props} from '@theme/DocSidebar'; export default function DocSidebar(props: Props): JSX.Element { const windowSize = useWindowSize(); diff --git a/packages/docusaurus-theme-classic/src/theme/DocSidebarItem/Category.tsx b/packages/docusaurus-theme-classic/src/theme/DocSidebarItem/Category/index.tsx similarity index 94% rename from packages/docusaurus-theme-classic/src/theme/DocSidebarItem/Category.tsx rename to packages/docusaurus-theme-classic/src/theme/DocSidebarItem/Category/index.tsx index 7a9a52e0e884..18047a9225ab 100644 --- a/packages/docusaurus-theme-classic/src/theme/DocSidebarItem/Category.tsx +++ b/packages/docusaurus-theme-classic/src/theme/DocSidebarItem/Category/index.tsx @@ -20,30 +20,28 @@ import { } from '@docusaurus/theme-common'; import Link from '@docusaurus/Link'; import {translate} from '@docusaurus/Translate'; - +import useIsBrowser from '@docusaurus/useIsBrowser'; import DocSidebarItems from '@theme/DocSidebarItems'; import type {Props} from '@theme/DocSidebarItem/Category'; -import useIsBrowser from '@docusaurus/useIsBrowser'; - // If we navigate to a category and it becomes active, it should automatically // expand itself function useAutoExpandActiveCategory({ isActive, collapsed, - setCollapsed, + updateCollapsed, }: { isActive: boolean; collapsed: boolean; - setCollapsed: (b: boolean) => void; + updateCollapsed: (b: boolean) => void; }) { const wasActive = usePrevious(isActive); useEffect(() => { const justBecameActive = isActive && !wasActive; if (justBecameActive && collapsed) { - setCollapsed(false); + updateCollapsed(false); } - }, [isActive, wasActive, collapsed, setCollapsed]); + }, [isActive, wasActive, collapsed, updateCollapsed]); } /** @@ -105,6 +103,11 @@ export default function DocSidebarItemCategory({ ...props }: Props): JSX.Element { const {items, label, collapsible, className, href} = item; + const { + docs: { + sidebar: {autoCollapseCategories}, + }, + } = useThemeConfig(); const hrefWithSSRFallback = useCategoryHrefWithSSRFallback(item); const isActive = isActiveSidebarItem(item, activePath); @@ -121,17 +124,13 @@ export default function DocSidebarItemCategory({ }, }); - useAutoExpandActiveCategory({isActive, collapsed, setCollapsed}); const {expandedItem, setExpandedItem} = useDocSidebarItemsExpandedState(); - function updateCollapsed(toCollapsed: boolean = !collapsed) { + // Use this instead of `setCollapsed`, because it is also reactive + const updateCollapsed = (toCollapsed: boolean = !collapsed) => { setExpandedItem(toCollapsed ? null : index); setCollapsed(toCollapsed); - } - const { - docs: { - sidebar: {autoCollapseCategories}, - }, - } = useThemeConfig(); + }; + useAutoExpandActiveCategory({isActive, collapsed, updateCollapsed}); useEffect(() => { if ( collapsible && diff --git a/packages/docusaurus-theme-classic/src/theme/DocSidebarItem/Html.tsx b/packages/docusaurus-theme-classic/src/theme/DocSidebarItem/Html/index.tsx similarity index 95% rename from packages/docusaurus-theme-classic/src/theme/DocSidebarItem/Html.tsx rename to packages/docusaurus-theme-classic/src/theme/DocSidebarItem/Html/index.tsx index 0e97ec27788a..7f6bab8f6cc6 100644 --- a/packages/docusaurus-theme-classic/src/theme/DocSidebarItem/Html.tsx +++ b/packages/docusaurus-theme-classic/src/theme/DocSidebarItem/Html/index.tsx @@ -10,7 +10,7 @@ import clsx from 'clsx'; import {ThemeClassNames} from '@docusaurus/theme-common'; import type {Props} from '@theme/DocSidebarItem/Html'; -import styles from './Html.module.css'; +import styles from './styles.module.css'; export default function DocSidebarItemHtml({ item, diff --git a/packages/docusaurus-theme-classic/src/theme/DocSidebarItem/Html.module.css b/packages/docusaurus-theme-classic/src/theme/DocSidebarItem/Html/styles.module.css similarity index 100% rename from packages/docusaurus-theme-classic/src/theme/DocSidebarItem/Html.module.css rename to packages/docusaurus-theme-classic/src/theme/DocSidebarItem/Html/styles.module.css diff --git a/packages/docusaurus-theme-classic/src/theme/DocSidebarItem/Link.tsx b/packages/docusaurus-theme-classic/src/theme/DocSidebarItem/Link/index.tsx similarity index 97% rename from packages/docusaurus-theme-classic/src/theme/DocSidebarItem/Link.tsx rename to packages/docusaurus-theme-classic/src/theme/DocSidebarItem/Link/index.tsx index 28c481eed42f..fc87268e01f0 100644 --- a/packages/docusaurus-theme-classic/src/theme/DocSidebarItem/Link.tsx +++ b/packages/docusaurus-theme-classic/src/theme/DocSidebarItem/Link/index.tsx @@ -11,10 +11,9 @@ import {isActiveSidebarItem, ThemeClassNames} from '@docusaurus/theme-common'; import Link from '@docusaurus/Link'; import isInternalUrl from '@docusaurus/isInternalUrl'; import IconExternalLink from '@theme/IconExternalLink'; - import type {Props} from '@theme/DocSidebarItem/Link'; -import styles from './Link.module.css'; +import styles from './styles.module.css'; export default function DocSidebarItemLink({ item, diff --git a/packages/docusaurus-theme-classic/src/theme/DocSidebarItem/Link.module.css b/packages/docusaurus-theme-classic/src/theme/DocSidebarItem/Link/styles.module.css similarity index 100% rename from packages/docusaurus-theme-classic/src/theme/DocSidebarItem/Link.module.css rename to packages/docusaurus-theme-classic/src/theme/DocSidebarItem/Link/styles.module.css diff --git a/packages/docusaurus-theme-classic/src/theme/DocSidebarItems/index.tsx b/packages/docusaurus-theme-classic/src/theme/DocSidebarItems/index.tsx index fbced08e1416..041c553f284f 100644 --- a/packages/docusaurus-theme-classic/src/theme/DocSidebarItems/index.tsx +++ b/packages/docusaurus-theme-classic/src/theme/DocSidebarItems/index.tsx @@ -6,8 +6,8 @@ */ import React, {memo} from 'react'; -import DocSidebarItem from '@theme/DocSidebarItem'; import {DocSidebarItemsExpandedStateProvider} from '@docusaurus/theme-common'; +import DocSidebarItem from '@theme/DocSidebarItem'; import type {Props} from '@theme/DocSidebarItems'; diff --git a/packages/docusaurus-theme-classic/src/theme/DocTagDocListPage/index.tsx b/packages/docusaurus-theme-classic/src/theme/DocTagDocListPage/index.tsx index 22cf3ff7ac9b..a928644a9bd6 100644 --- a/packages/docusaurus-theme-classic/src/theme/DocTagDocListPage/index.tsx +++ b/packages/docusaurus-theme-classic/src/theme/DocTagDocListPage/index.tsx @@ -6,8 +6,7 @@ */ import React from 'react'; - -import Layout from '@theme/Layout'; +import clsx from 'clsx'; import Link from '@docusaurus/Link'; import { PageMetadata, @@ -16,9 +15,9 @@ import { usePluralForm, } from '@docusaurus/theme-common'; import Translate, {translate} from '@docusaurus/Translate'; -import type {Props} from '@theme/DocTagDocListPage'; +import Layout from '@theme/Layout'; import SearchMetadata from '@theme/SearchMetadata'; -import clsx from 'clsx'; +import type {Props} from '@theme/DocTagDocListPage'; // Very simple pluralization: probably good enough for now function useNDocsTaggedPlural() { diff --git a/packages/docusaurus-theme-classic/src/theme/DocTagsListPage/index.tsx b/packages/docusaurus-theme-classic/src/theme/DocTagsListPage/index.tsx index 5ab4f5a44db9..e848128fedf0 100644 --- a/packages/docusaurus-theme-classic/src/theme/DocTagsListPage/index.tsx +++ b/packages/docusaurus-theme-classic/src/theme/DocTagsListPage/index.tsx @@ -6,18 +6,17 @@ */ import React from 'react'; - -import Layout from '@theme/Layout'; +import clsx from 'clsx'; import { PageMetadata, HtmlClassNameProvider, ThemeClassNames, translateTagsPageTitle, } from '@docusaurus/theme-common'; +import Layout from '@theme/Layout'; import TagsListByLetter from '@theme/TagsListByLetter'; -import type {Props} from '@theme/DocTagsListPage'; import SearchMetadata from '@theme/SearchMetadata'; -import clsx from 'clsx'; +import type {Props} from '@theme/DocTagsListPage'; export default function DocTagsListPage({tags}: Props): JSX.Element { const title = translateTagsPageTitle(); diff --git a/packages/docusaurus-theme-classic/src/theme/DocVersionBadge/index.tsx b/packages/docusaurus-theme-classic/src/theme/DocVersionBadge/index.tsx index 862a33e5e543..dc4a2c90bbb1 100644 --- a/packages/docusaurus-theme-classic/src/theme/DocVersionBadge/index.tsx +++ b/packages/docusaurus-theme-classic/src/theme/DocVersionBadge/index.tsx @@ -6,9 +6,9 @@ */ import React from 'react'; +import clsx from 'clsx'; import Translate from '@docusaurus/Translate'; import {ThemeClassNames, useDocsVersion} from '@docusaurus/theme-common'; -import clsx from 'clsx'; import type {Props} from '@theme/DocVersionBadge'; export default function DocVersionBadge({ diff --git a/packages/docusaurus-theme-classic/src/theme/DocVersionBanner/index.tsx b/packages/docusaurus-theme-classic/src/theme/DocVersionBanner/index.tsx index dd87a4d3673b..979a4f2b90a7 100644 --- a/packages/docusaurus-theme-classic/src/theme/DocVersionBanner/index.tsx +++ b/packages/docusaurus-theme-classic/src/theme/DocVersionBanner/index.tsx @@ -6,6 +6,7 @@ */ import React, {type ComponentType} from 'react'; +import clsx from 'clsx'; import useDocusaurusContext from '@docusaurus/useDocusaurusContext'; import Link from '@docusaurus/Link'; import Translate from '@docusaurus/Translate'; @@ -21,7 +22,6 @@ import { } from '@docusaurus/theme-common'; import type {Props} from '@theme/DocVersionBanner'; -import clsx from 'clsx'; import type { VersionBanner, PropVersionMetadata, diff --git a/packages/docusaurus-theme-classic/src/theme/EditThisPage/index.tsx b/packages/docusaurus-theme-classic/src/theme/EditThisPage/index.tsx index 5fda42f876b6..f4b55187756f 100644 --- a/packages/docusaurus-theme-classic/src/theme/EditThisPage/index.tsx +++ b/packages/docusaurus-theme-classic/src/theme/EditThisPage/index.tsx @@ -7,10 +7,9 @@ import React from 'react'; import Translate from '@docusaurus/Translate'; - -import type {Props} from '@theme/EditThisPage'; -import IconEdit from '@theme/IconEdit'; import {ThemeClassNames} from '@docusaurus/theme-common'; +import IconEdit from '@theme/IconEdit'; +import type {Props} from '@theme/EditThisPage'; export default function EditThisPage({editUrl}: Props): JSX.Element { return ( diff --git a/packages/docusaurus-theme-classic/src/theme/Footer/Links/MultiColumn/index.tsx b/packages/docusaurus-theme-classic/src/theme/Footer/Links/MultiColumn/index.tsx index a2bad28d8682..01b362e520c0 100644 --- a/packages/docusaurus-theme-classic/src/theme/Footer/Links/MultiColumn/index.tsx +++ b/packages/docusaurus-theme-classic/src/theme/Footer/Links/MultiColumn/index.tsx @@ -6,8 +6,8 @@ */ import React from 'react'; -import type {Props} from '@theme/Footer/Links/MultiColumn'; import LinkItem from '@theme/Footer/LinkItem'; +import type {Props} from '@theme/Footer/Links/MultiColumn'; type ColumnType = Props['columns'][number]; type ColumnItemType = ColumnType['items'][number]; diff --git a/packages/docusaurus-theme-classic/src/theme/Footer/Links/Simple/index.tsx b/packages/docusaurus-theme-classic/src/theme/Footer/Links/Simple/index.tsx index 72fcc0a74a53..e14b77f1f31d 100644 --- a/packages/docusaurus-theme-classic/src/theme/Footer/Links/Simple/index.tsx +++ b/packages/docusaurus-theme-classic/src/theme/Footer/Links/Simple/index.tsx @@ -6,8 +6,8 @@ */ import React from 'react'; -import type {Props} from '@theme/Footer/Links/Simple'; import LinkItem from '@theme/Footer/LinkItem'; +import type {Props} from '@theme/Footer/Links/Simple'; function Separator() { return ·; diff --git a/packages/docusaurus-theme-classic/src/theme/Footer/Links/index.tsx b/packages/docusaurus-theme-classic/src/theme/Footer/Links/index.tsx index 44e553e5390e..a4b0f3354c23 100644 --- a/packages/docusaurus-theme-classic/src/theme/Footer/Links/index.tsx +++ b/packages/docusaurus-theme-classic/src/theme/Footer/Links/index.tsx @@ -8,9 +8,9 @@ import React from 'react'; import {isMultiColumnFooterLinks} from '@docusaurus/theme-common'; -import type {Props} from '@theme/Footer/Links'; import FooterLinksMultiColumn from '@theme/Footer/Links/MultiColumn'; import FooterLinksSimple from '@theme/Footer/Links/Simple'; +import type {Props} from '@theme/Footer/Links'; export default function FooterLinks({links}: Props): JSX.Element { return isMultiColumnFooterLinks(links) ? ( diff --git a/packages/docusaurus-theme-classic/src/theme/Footer/Logo/index.tsx b/packages/docusaurus-theme-classic/src/theme/Footer/Logo/index.tsx index f566555a1791..121e08f758a3 100644 --- a/packages/docusaurus-theme-classic/src/theme/Footer/Logo/index.tsx +++ b/packages/docusaurus-theme-classic/src/theme/Footer/Logo/index.tsx @@ -6,13 +6,13 @@ */ import React from 'react'; - import Link from '@docusaurus/Link'; import {useBaseUrlUtils} from '@docusaurus/useBaseUrl'; -import styles from './styles.module.css'; import ThemedImage from '@theme/ThemedImage'; import type {Props} from '@theme/Footer/Logo'; +import styles from './styles.module.css'; + function LogoImage({logo}: Props) { const {withBaseUrl} = useBaseUrlUtils(); const sources = { diff --git a/packages/docusaurus-theme-classic/src/theme/Heading/index.tsx b/packages/docusaurus-theme-classic/src/theme/Heading/index.tsx index 7f8f80876475..9969fdbb6e55 100644 --- a/packages/docusaurus-theme-classic/src/theme/Heading/index.tsx +++ b/packages/docusaurus-theme-classic/src/theme/Heading/index.tsx @@ -7,9 +7,9 @@ import React from 'react'; import clsx from 'clsx'; -import type {Props} from '@theme/Heading'; import {translate} from '@docusaurus/Translate'; import {useThemeConfig} from '@docusaurus/theme-common'; +import type {Props} from '@theme/Heading'; import styles from './styles.module.css'; diff --git a/packages/docusaurus-theme-classic/src/theme/IconEdit/index.tsx b/packages/docusaurus-theme-classic/src/theme/IconEdit/index.tsx index 76f8a8168b1f..004c12216598 100644 --- a/packages/docusaurus-theme-classic/src/theme/IconEdit/index.tsx +++ b/packages/docusaurus-theme-classic/src/theme/IconEdit/index.tsx @@ -7,7 +7,6 @@ import React from 'react'; import clsx from 'clsx'; - import type {Props} from '@theme/IconEdit'; import styles from './styles.module.css'; diff --git a/packages/docusaurus-theme-classic/src/theme/LastUpdated/index.tsx b/packages/docusaurus-theme-classic/src/theme/LastUpdated/index.tsx index 57937216285f..5ba4c3e2f249 100644 --- a/packages/docusaurus-theme-classic/src/theme/LastUpdated/index.tsx +++ b/packages/docusaurus-theme-classic/src/theme/LastUpdated/index.tsx @@ -7,8 +7,8 @@ import React from 'react'; import Translate from '@docusaurus/Translate'; -import type {Props} from '@theme/LastUpdated'; import {ThemeClassNames} from '@docusaurus/theme-common'; +import type {Props} from '@theme/LastUpdated'; function LastUpdatedAtDate({ lastUpdatedAt, diff --git a/packages/docusaurus-theme-classic/src/theme/Layout/index.tsx b/packages/docusaurus-theme-classic/src/theme/Layout/index.tsx index 47ed451b55d9..c5503edcaaa2 100644 --- a/packages/docusaurus-theme-classic/src/theme/Layout/index.tsx +++ b/packages/docusaurus-theme-classic/src/theme/Layout/index.tsx @@ -8,19 +8,19 @@ import React from 'react'; import clsx from 'clsx'; import ErrorBoundary from '@docusaurus/ErrorBoundary'; -import SkipToContent from '@theme/SkipToContent'; -import AnnouncementBar from '@theme/AnnouncementBar'; -import Navbar from '@theme/Navbar'; -import Footer from '@theme/Footer'; -import LayoutProviders from '@theme/LayoutProviders'; -import type {Props} from '@theme/Layout'; import { PageMetadata, ThemeClassNames, useKeyboardNavigation, } from '@docusaurus/theme-common'; +import SkipToContent from '@theme/SkipToContent'; +import AnnouncementBar from '@theme/AnnouncementBar'; +import Navbar from '@theme/Navbar'; +import Footer from '@theme/Footer'; +import LayoutProviders from '@theme/LayoutProviders'; import ErrorPageContent from '@theme/ErrorPageContent'; import './styles.css'; +import type {Props} from '@theme/Layout'; export default function Layout(props: Props): JSX.Element { const { diff --git a/packages/docusaurus-theme-classic/src/theme/Logo/index.tsx b/packages/docusaurus-theme-classic/src/theme/Logo/index.tsx index eaa89cc1e0cc..13f4126198ed 100644 --- a/packages/docusaurus-theme-classic/src/theme/Logo/index.tsx +++ b/packages/docusaurus-theme-classic/src/theme/Logo/index.tsx @@ -6,13 +6,12 @@ */ import React from 'react'; -import type {Props} from '@theme/Logo'; - import Link from '@docusaurus/Link'; -import ThemedImage from '@theme/ThemedImage'; import useBaseUrl from '@docusaurus/useBaseUrl'; import useDocusaurusContext from '@docusaurus/useDocusaurusContext'; import {useThemeConfig} from '@docusaurus/theme-common'; +import ThemedImage from '@theme/ThemedImage'; +import type {Props} from '@theme/Logo'; export default function Logo(props: Props): JSX.Element { const { diff --git a/packages/docusaurus-theme-classic/src/theme/MDXComponents/Img.tsx b/packages/docusaurus-theme-classic/src/theme/MDXComponents/Img/index.tsx similarity index 93% rename from packages/docusaurus-theme-classic/src/theme/MDXComponents/Img.tsx rename to packages/docusaurus-theme-classic/src/theme/MDXComponents/Img/index.tsx index a97bedc3e028..c3b76dee9fc5 100644 --- a/packages/docusaurus-theme-classic/src/theme/MDXComponents/Img.tsx +++ b/packages/docusaurus-theme-classic/src/theme/MDXComponents/Img/index.tsx @@ -6,9 +6,10 @@ */ import React from 'react'; -import type {Props} from '@theme/MDXComponents/Img'; -import styles from './Img.module.css'; import clsx from 'clsx'; +import type {Props} from '@theme/MDXComponents/Img'; + +import styles from './styles.module.css'; function transformImgClassName(className?: string): string { return clsx(className, styles.img); diff --git a/packages/docusaurus-theme-classic/src/theme/MDXComponents/Img.module.css b/packages/docusaurus-theme-classic/src/theme/MDXComponents/Img/styles.module.css similarity index 100% rename from packages/docusaurus-theme-classic/src/theme/MDXComponents/Img.module.css rename to packages/docusaurus-theme-classic/src/theme/MDXComponents/Img/styles.module.css diff --git a/packages/docusaurus-theme-classic/src/theme/MDXComponents/Ul.tsx b/packages/docusaurus-theme-classic/src/theme/MDXComponents/Ul.tsx index 8a0da274ec2c..080ecaac2a1a 100644 --- a/packages/docusaurus-theme-classic/src/theme/MDXComponents/Ul.tsx +++ b/packages/docusaurus-theme-classic/src/theme/MDXComponents/Ul.tsx @@ -12,8 +12,8 @@ import type {Props} from '@theme/MDXComponents/Ul'; function transformUlClassName(className?: string): string { return clsx( className, - // This class is set globally by GitHub/MDX - // We keep the global class, but add Infima class to get list without styling + // This class is set globally by GitHub/MDX. We keep the global class, and + // add another Infima class to get list without styling // See https://github.com/syntax-tree/mdast-util-to-hast/issues/28 className?.includes('contains-task-list') && 'clean-list', ); diff --git a/packages/docusaurus-theme-classic/src/theme/MDXPage/index.tsx b/packages/docusaurus-theme-classic/src/theme/MDXPage/index.tsx index 44ba2a5c0ffa..64bb180a5634 100644 --- a/packages/docusaurus-theme-classic/src/theme/MDXPage/index.tsx +++ b/packages/docusaurus-theme-classic/src/theme/MDXPage/index.tsx @@ -7,15 +7,15 @@ import React from 'react'; import clsx from 'clsx'; -import Layout from '@theme/Layout'; -import MDXContent from '@theme/MDXContent'; -import type {Props} from '@theme/MDXPage'; -import TOC from '@theme/TOC'; import { PageMetadata, HtmlClassNameProvider, ThemeClassNames, } from '@docusaurus/theme-common'; +import Layout from '@theme/Layout'; +import MDXContent from '@theme/MDXContent'; +import TOC from '@theme/TOC'; +import type {Props} from '@theme/MDXPage'; import styles from './styles.module.css'; diff --git a/packages/docusaurus-theme-classic/src/theme/Navbar/ColorModeToggle/index.tsx b/packages/docusaurus-theme-classic/src/theme/Navbar/ColorModeToggle/index.tsx index 5c33ac4a3bed..d1fc9c3ffba1 100644 --- a/packages/docusaurus-theme-classic/src/theme/Navbar/ColorModeToggle/index.tsx +++ b/packages/docusaurus-theme-classic/src/theme/Navbar/ColorModeToggle/index.tsx @@ -5,10 +5,10 @@ * LICENSE file in the root directory of this source tree. */ +import React from 'react'; import {useColorMode, useThemeConfig} from '@docusaurus/theme-common'; import ColorModeToggle from '@theme/ColorModeToggle'; import type {Props} from '@theme/Navbar/ColorModeToggle'; -import React from 'react'; export default function NavbarColorModeToggle({ className, diff --git a/packages/docusaurus-theme-classic/src/theme/Navbar/Content/index.tsx b/packages/docusaurus-theme-classic/src/theme/Navbar/Content/index.tsx index 9ab92085eca5..89503a675dcb 100644 --- a/packages/docusaurus-theme-classic/src/theme/Navbar/Content/index.tsx +++ b/packages/docusaurus-theme-classic/src/theme/Navbar/Content/index.tsx @@ -6,18 +6,19 @@ */ import React, {type ReactNode} from 'react'; -import type {Props as NavbarItemConfig} from '@theme/NavbarItem'; -import NavbarItem from '@theme/NavbarItem'; -import NavbarColorModeToggle from '@theme/Navbar/ColorModeToggle'; -import SearchBar from '@theme/SearchBar'; import { splitNavbarItems, useNavbarMobileSidebar, useThemeConfig, } from '@docusaurus/theme-common'; +import NavbarItem from '@theme/NavbarItem'; +import NavbarColorModeToggle from '@theme/Navbar/ColorModeToggle'; +import SearchBar from '@theme/SearchBar'; import NavbarMobileSidebarToggle from '@theme/Navbar/MobileSidebar/Toggle'; import NavbarLogo from '@theme/Navbar/Logo'; import NavbarSearch from '@theme/Navbar/Search'; +import type {Props as NavbarItemConfig} from '@theme/NavbarItem'; + import styles from './styles.module.css'; function useNavbarItems() { diff --git a/packages/docusaurus-theme-classic/src/theme/Navbar/Layout/index.tsx b/packages/docusaurus-theme-classic/src/theme/Navbar/Layout/index.tsx index 00e5736bd8fd..b674fe726985 100644 --- a/packages/docusaurus-theme-classic/src/theme/Navbar/Layout/index.tsx +++ b/packages/docusaurus-theme-classic/src/theme/Navbar/Layout/index.tsx @@ -7,13 +7,13 @@ import React, {type ComponentProps} from 'react'; import clsx from 'clsx'; -import NavbarMobileSidebar from '@theme/Navbar/MobileSidebar'; -import type {Props} from '@theme/Navbar/Layout'; import { useThemeConfig, useHideableNavbar, useNavbarMobileSidebar, } from '@docusaurus/theme-common'; +import NavbarMobileSidebar from '@theme/Navbar/MobileSidebar'; +import type {Props} from '@theme/Navbar/Layout'; import styles from './styles.module.css'; diff --git a/packages/docusaurus-theme-classic/src/theme/Navbar/MobileSidebar/Header/index.tsx b/packages/docusaurus-theme-classic/src/theme/Navbar/MobileSidebar/Header/index.tsx index c58b42eb014a..139377115323 100644 --- a/packages/docusaurus-theme-classic/src/theme/Navbar/MobileSidebar/Header/index.tsx +++ b/packages/docusaurus-theme-classic/src/theme/Navbar/MobileSidebar/Header/index.tsx @@ -6,10 +6,10 @@ */ import React from 'react'; +import {useNavbarMobileSidebar} from '@docusaurus/theme-common'; import NavbarColorModeToggle from '@theme/Navbar/ColorModeToggle'; import IconClose from '@theme/IconClose'; import NavbarLogo from '@theme/Navbar/Logo'; -import {useNavbarMobileSidebar} from '@docusaurus/theme-common'; function CloseButton() { const mobileSidebar = useNavbarMobileSidebar(); diff --git a/packages/docusaurus-theme-classic/src/theme/Navbar/MobileSidebar/Layout/index.tsx b/packages/docusaurus-theme-classic/src/theme/Navbar/MobileSidebar/Layout/index.tsx index 4fe7a4f9984c..6d63029dbd31 100644 --- a/packages/docusaurus-theme-classic/src/theme/Navbar/MobileSidebar/Layout/index.tsx +++ b/packages/docusaurus-theme-classic/src/theme/Navbar/MobileSidebar/Layout/index.tsx @@ -7,8 +7,8 @@ import React from 'react'; import clsx from 'clsx'; -import type {Props} from '@theme/Navbar/MobileSidebar/Layout'; import {useNavbarSecondaryMenu} from '@docusaurus/theme-common'; +import type {Props} from '@theme/Navbar/MobileSidebar/Layout'; export default function NavbarMobileSidebarLayout({ header, diff --git a/packages/docusaurus-theme-classic/src/theme/Navbar/MobileSidebar/PrimaryMenu/index.tsx b/packages/docusaurus-theme-classic/src/theme/Navbar/MobileSidebar/PrimaryMenu/index.tsx index dbde63edb558..d8fa6524a6f0 100644 --- a/packages/docusaurus-theme-classic/src/theme/Navbar/MobileSidebar/PrimaryMenu/index.tsx +++ b/packages/docusaurus-theme-classic/src/theme/Navbar/MobileSidebar/PrimaryMenu/index.tsx @@ -7,8 +7,8 @@ import React from 'react'; import {useNavbarMobileSidebar, useThemeConfig} from '@docusaurus/theme-common'; +import NavbarItem from '@theme/NavbarItem'; import type {Props as NavbarItemConfig} from '@theme/NavbarItem'; -import NavbarItem from '../../../NavbarItem'; function useNavbarItems() { // TODO temporary casting until ThemeConfig type is improved diff --git a/packages/docusaurus-theme-classic/src/theme/Navbar/MobileSidebar/Toggle/index.tsx b/packages/docusaurus-theme-classic/src/theme/Navbar/MobileSidebar/Toggle/index.tsx index e4ac62a50584..6ac64154d36c 100644 --- a/packages/docusaurus-theme-classic/src/theme/Navbar/MobileSidebar/Toggle/index.tsx +++ b/packages/docusaurus-theme-classic/src/theme/Navbar/MobileSidebar/Toggle/index.tsx @@ -6,8 +6,8 @@ */ import React from 'react'; -import IconMenu from '@theme/IconMenu'; import {useNavbarMobileSidebar} from '@docusaurus/theme-common'; +import IconMenu from '@theme/IconMenu'; export default function MobileSidebarToggle(): JSX.Element { const mobileSidebar = useNavbarMobileSidebar(); diff --git a/packages/docusaurus-theme-classic/src/theme/Navbar/MobileSidebar/index.tsx b/packages/docusaurus-theme-classic/src/theme/Navbar/MobileSidebar/index.tsx index 4a29c4901525..4ee13c284efc 100644 --- a/packages/docusaurus-theme-classic/src/theme/Navbar/MobileSidebar/index.tsx +++ b/packages/docusaurus-theme-classic/src/theme/Navbar/MobileSidebar/index.tsx @@ -6,12 +6,12 @@ */ import React from 'react'; -import NavbarMobileSidebarLayout from '@theme/Navbar/MobileSidebar/Layout'; -import NavbarMobileSidebarHeader from '@theme/Navbar/MobileSidebar/Header'; import { useLockBodyScroll, useNavbarMobileSidebar, } from '@docusaurus/theme-common'; +import NavbarMobileSidebarLayout from '@theme/Navbar/MobileSidebar/Layout'; +import NavbarMobileSidebarHeader from '@theme/Navbar/MobileSidebar/Header'; import NavbarMobileSidebarPrimaryMenu from '@theme/Navbar/MobileSidebar/PrimaryMenu'; import NavbarMobileSidebarSecondaryMenu from '@theme/Navbar/MobileSidebar/SecondaryMenu'; diff --git a/packages/docusaurus-theme-classic/src/theme/NavbarItem/DefaultNavbarItem.tsx b/packages/docusaurus-theme-classic/src/theme/NavbarItem/DefaultNavbarItem.tsx index 2c5044682012..7036b2b6c12e 100644 --- a/packages/docusaurus-theme-classic/src/theme/NavbarItem/DefaultNavbarItem.tsx +++ b/packages/docusaurus-theme-classic/src/theme/NavbarItem/DefaultNavbarItem.tsx @@ -7,16 +7,13 @@ import React from 'react'; import clsx from 'clsx'; - import NavbarNavLink from '@theme/NavbarItem/NavbarNavLink'; - +import {getInfimaActiveClassName} from '@theme/NavbarItem/utils'; import type { DesktopOrMobileNavBarItemProps, Props, } from '@theme/NavbarItem/DefaultNavbarItem'; -import {getInfimaActiveClassName} from '@theme/NavbarItem/utils'; - function DefaultNavbarItemDesktop({ className, isDropdownItem = false, diff --git a/packages/docusaurus-theme-classic/src/theme/NavbarItem/DocNavbarItem.tsx b/packages/docusaurus-theme-classic/src/theme/NavbarItem/DocNavbarItem.tsx index 1ed30afe4050..797ef1ec2d50 100644 --- a/packages/docusaurus-theme-classic/src/theme/NavbarItem/DocNavbarItem.tsx +++ b/packages/docusaurus-theme-classic/src/theme/NavbarItem/DocNavbarItem.tsx @@ -6,12 +6,12 @@ */ import React from 'react'; -import DefaultNavbarItem from '@theme/NavbarItem/DefaultNavbarItem'; -import {useActiveDocContext} from '@docusaurus/plugin-content-docs/client'; import clsx from 'clsx'; +import {useActiveDocContext} from '@docusaurus/plugin-content-docs/client'; +import {useLayoutDoc} from '@docusaurus/theme-common'; +import DefaultNavbarItem from '@theme/NavbarItem/DefaultNavbarItem'; import {getInfimaActiveClassName} from '@theme/NavbarItem/utils'; import type {Props} from '@theme/NavbarItem/DocNavbarItem'; -import {useLayoutDoc} from '@docusaurus/theme-common'; export default function DocNavbarItem({ docId, diff --git a/packages/docusaurus-theme-classic/src/theme/NavbarItem/DocSidebarNavbarItem.tsx b/packages/docusaurus-theme-classic/src/theme/NavbarItem/DocSidebarNavbarItem.tsx index 965664855603..874605bcf1a1 100644 --- a/packages/docusaurus-theme-classic/src/theme/NavbarItem/DocSidebarNavbarItem.tsx +++ b/packages/docusaurus-theme-classic/src/theme/NavbarItem/DocSidebarNavbarItem.tsx @@ -6,12 +6,11 @@ */ import React from 'react'; -import DefaultNavbarItem from '@theme/NavbarItem/DefaultNavbarItem'; -import {useActiveDocContext} from '@docusaurus/plugin-content-docs/client'; import clsx from 'clsx'; -import {getInfimaActiveClassName} from '@theme/NavbarItem/utils'; +import {useActiveDocContext} from '@docusaurus/plugin-content-docs/client'; import {useLayoutDocsSidebar} from '@docusaurus/theme-common'; - +import DefaultNavbarItem from '@theme/NavbarItem/DefaultNavbarItem'; +import {getInfimaActiveClassName} from '@theme/NavbarItem/utils'; import type {Props} from '@theme/NavbarItem/DocSidebarNavbarItem'; export default function DocSidebarNavbarItem({ diff --git a/packages/docusaurus-theme-classic/src/theme/NavbarItem/DocsVersionDropdownNavbarItem.tsx b/packages/docusaurus-theme-classic/src/theme/NavbarItem/DocsVersionDropdownNavbarItem.tsx index 9624dc3ddedb..b351eeeef1a8 100644 --- a/packages/docusaurus-theme-classic/src/theme/NavbarItem/DocsVersionDropdownNavbarItem.tsx +++ b/packages/docusaurus-theme-classic/src/theme/NavbarItem/DocsVersionDropdownNavbarItem.tsx @@ -6,8 +6,6 @@ */ import React from 'react'; -import DefaultNavbarItem from '@theme/NavbarItem/DefaultNavbarItem'; -import DropdownNavbarItem from '@theme/NavbarItem/DropdownNavbarItem'; import { useVersions, useActiveDocContext, @@ -17,8 +15,10 @@ import { useDocsVersionCandidates, } from '@docusaurus/theme-common'; import {translate} from '@docusaurus/Translate'; -import type {GlobalVersion} from '@docusaurus/plugin-content-docs/client'; +import DefaultNavbarItem from '@theme/NavbarItem/DefaultNavbarItem'; +import DropdownNavbarItem from '@theme/NavbarItem/DropdownNavbarItem'; import type {Props} from '@theme/NavbarItem/DocsVersionDropdownNavbarItem'; +import type {GlobalVersion} from '@docusaurus/plugin-content-docs/client'; const getVersionMainDoc = (version: GlobalVersion) => version.docs.find((doc) => doc.id === version.mainDocId)!; diff --git a/packages/docusaurus-theme-classic/src/theme/NavbarItem/DocsVersionNavbarItem.tsx b/packages/docusaurus-theme-classic/src/theme/NavbarItem/DocsVersionNavbarItem.tsx index db6873764319..aade004e44d4 100644 --- a/packages/docusaurus-theme-classic/src/theme/NavbarItem/DocsVersionNavbarItem.tsx +++ b/packages/docusaurus-theme-classic/src/theme/NavbarItem/DocsVersionNavbarItem.tsx @@ -6,10 +6,10 @@ */ import React from 'react'; -import DefaultNavbarItem from '@theme/NavbarItem/DefaultNavbarItem'; import {useDocsVersionCandidates} from '@docusaurus/theme-common'; -import type {GlobalVersion} from '@docusaurus/plugin-content-docs/client'; +import DefaultNavbarItem from '@theme/NavbarItem/DefaultNavbarItem'; import type {Props} from '@theme/NavbarItem/DocsVersionNavbarItem'; +import type {GlobalVersion} from '@docusaurus/plugin-content-docs/client'; const getVersionMainDoc = (version: GlobalVersion) => version.docs.find((doc) => doc.id === version.mainDocId)!; diff --git a/packages/docusaurus-theme-classic/src/theme/NavbarItem/DropdownNavbarItem.tsx b/packages/docusaurus-theme-classic/src/theme/NavbarItem/DropdownNavbarItem.tsx index 37dd48692452..ca5e03d92f12 100644 --- a/packages/docusaurus-theme-classic/src/theme/NavbarItem/DropdownNavbarItem.tsx +++ b/packages/docusaurus-theme-classic/src/theme/NavbarItem/DropdownNavbarItem.tsx @@ -14,15 +14,14 @@ import { isRegexpStringMatch, useLocalPathname, } from '@docusaurus/theme-common'; +import NavbarNavLink from '@theme/NavbarItem/NavbarNavLink'; +import NavbarItem from '@theme/NavbarItem'; import type { DesktopOrMobileNavBarItemProps, Props, } from '@theme/NavbarItem/DropdownNavbarItem'; import type {LinkLikeNavbarItemProps} from '@theme/NavbarItem'; -import NavbarNavLink from '@theme/NavbarItem/NavbarNavLink'; -import NavbarItem from '@theme/NavbarItem'; - const dropdownLinkActiveClass = 'dropdown__link--active'; function isItemActive( diff --git a/packages/docusaurus-theme-classic/src/theme/NavbarItem/LocaleDropdownNavbarItem/index.tsx b/packages/docusaurus-theme-classic/src/theme/NavbarItem/LocaleDropdownNavbarItem/index.tsx index 620a161b9dee..2bb652c734ac 100644 --- a/packages/docusaurus-theme-classic/src/theme/NavbarItem/LocaleDropdownNavbarItem/index.tsx +++ b/packages/docusaurus-theme-classic/src/theme/NavbarItem/LocaleDropdownNavbarItem/index.tsx @@ -6,13 +6,13 @@ */ import React from 'react'; -import DropdownNavbarItem from '@theme/NavbarItem/DropdownNavbarItem'; -import IconLanguage from '@theme/IconLanguage'; -import type {Props} from '@theme/NavbarItem/LocaleDropdownNavbarItem'; import useDocusaurusContext from '@docusaurus/useDocusaurusContext'; import {useAlternatePageUtils} from '@docusaurus/theme-common'; import {translate} from '@docusaurus/Translate'; +import DropdownNavbarItem from '@theme/NavbarItem/DropdownNavbarItem'; +import IconLanguage from '@theme/IconLanguage'; import type {LinkLikeNavbarItemProps} from '@theme/NavbarItem'; +import type {Props} from '@theme/NavbarItem/LocaleDropdownNavbarItem'; import styles from './styles.module.css'; diff --git a/packages/docusaurus-theme-classic/src/theme/NavbarItem/NavbarNavLink.tsx b/packages/docusaurus-theme-classic/src/theme/NavbarItem/NavbarNavLink.tsx index e19758815f6d..94157e97eec5 100644 --- a/packages/docusaurus-theme-classic/src/theme/NavbarItem/NavbarNavLink.tsx +++ b/packages/docusaurus-theme-classic/src/theme/NavbarItem/NavbarNavLink.tsx @@ -8,10 +8,10 @@ import React from 'react'; import Link from '@docusaurus/Link'; import useBaseUrl from '@docusaurus/useBaseUrl'; -import type {Props} from '@theme/NavbarItem/NavbarNavLink'; -import IconExternalLink from '@theme/IconExternalLink'; import isInternalUrl from '@docusaurus/isInternalUrl'; import {isRegexpStringMatch} from '@docusaurus/theme-common'; +import IconExternalLink from '@theme/IconExternalLink'; +import type {Props} from '@theme/NavbarItem/NavbarNavLink'; const dropdownLinkActiveClass = 'dropdown__link--active'; diff --git a/packages/docusaurus-theme-classic/src/theme/NavbarItem/SearchNavbarItem.tsx b/packages/docusaurus-theme-classic/src/theme/NavbarItem/SearchNavbarItem.tsx index dfefa83dc154..9e95436025b2 100644 --- a/packages/docusaurus-theme-classic/src/theme/NavbarItem/SearchNavbarItem.tsx +++ b/packages/docusaurus-theme-classic/src/theme/NavbarItem/SearchNavbarItem.tsx @@ -6,9 +6,9 @@ */ import React from 'react'; -import type {Props} from '@theme/NavbarItem/SearchNavbarItem'; import SearchBar from '@theme/SearchBar'; import NavbarSearch from '@theme/Navbar/Search'; +import type {Props} from '@theme/NavbarItem/SearchNavbarItem'; export default function SearchNavbarItem({mobile}: Props): JSX.Element | null { if (mobile) { diff --git a/packages/docusaurus-theme-classic/src/theme/NavbarItem/index.tsx b/packages/docusaurus-theme-classic/src/theme/NavbarItem/index.tsx index 7ae0d4990730..ca3253143a16 100644 --- a/packages/docusaurus-theme-classic/src/theme/NavbarItem/index.tsx +++ b/packages/docusaurus-theme-classic/src/theme/NavbarItem/index.tsx @@ -6,11 +6,10 @@ */ import React from 'react'; +import ComponentTypes from '@theme/NavbarItem/ComponentTypes'; import {type Props as DropdownNavbarItemProps} from '@theme/NavbarItem/DropdownNavbarItem'; import type {Types, Props} from '@theme/NavbarItem'; -import ComponentTypes from '@theme/NavbarItem/ComponentTypes'; - const getNavbarItemComponent = (type: NonNullable) => { const component = ComponentTypes[type]; if (!component) { diff --git a/packages/docusaurus-theme-classic/src/theme/NotFound.tsx b/packages/docusaurus-theme-classic/src/theme/NotFound.tsx index 2213158d52a6..e6b9542f3d50 100644 --- a/packages/docusaurus-theme-classic/src/theme/NotFound.tsx +++ b/packages/docusaurus-theme-classic/src/theme/NotFound.tsx @@ -6,9 +6,9 @@ */ import React from 'react'; -import Layout from '@theme/Layout'; import Translate, {translate} from '@docusaurus/Translate'; import {PageMetadata} from '@docusaurus/theme-common'; +import Layout from '@theme/Layout'; export default function NotFound(): JSX.Element { return ( diff --git a/packages/docusaurus-theme-classic/src/theme/SiteMetadata/index.tsx b/packages/docusaurus-theme-classic/src/theme/SiteMetadata/index.tsx index ce53ddf1d9e5..5fa827569181 100644 --- a/packages/docusaurus-theme-classic/src/theme/SiteMetadata/index.tsx +++ b/packages/docusaurus-theme-classic/src/theme/SiteMetadata/index.tsx @@ -9,7 +9,6 @@ import React from 'react'; import Head from '@docusaurus/Head'; import useDocusaurusContext from '@docusaurus/useDocusaurusContext'; import useBaseUrl from '@docusaurus/useBaseUrl'; -import SearchMetadata from '@theme/SearchMetadata'; import { PageMetadata, DEFAULT_SEARCH_TAG, @@ -18,6 +17,7 @@ import { keyboardFocusedClassName, } from '@docusaurus/theme-common'; import {useLocation} from '@docusaurus/router'; +import SearchMetadata from '@theme/SearchMetadata'; // TODO move to SiteMetadataDefaults or theme-common ? // Useful for i18n/SEO diff --git a/packages/docusaurus-theme-classic/src/theme/TOC/index.tsx b/packages/docusaurus-theme-classic/src/theme/TOC/index.tsx index 79ca736645e1..08b2ddb4c10c 100644 --- a/packages/docusaurus-theme-classic/src/theme/TOC/index.tsx +++ b/packages/docusaurus-theme-classic/src/theme/TOC/index.tsx @@ -7,8 +7,9 @@ import React from 'react'; import clsx from 'clsx'; -import type {Props} from '@theme/TOC'; import TOCItems from '@theme/TOCItems'; +import type {Props} from '@theme/TOC'; + import styles from './styles.module.css'; // Using a custom className diff --git a/packages/docusaurus-theme-classic/src/theme/TOCCollapsible/CollapseButton.tsx b/packages/docusaurus-theme-classic/src/theme/TOCCollapsible/CollapseButton/index.tsx similarity index 94% rename from packages/docusaurus-theme-classic/src/theme/TOCCollapsible/CollapseButton.tsx rename to packages/docusaurus-theme-classic/src/theme/TOCCollapsible/CollapseButton/index.tsx index 48eeb3afdb19..54d9bf415518 100644 --- a/packages/docusaurus-theme-classic/src/theme/TOCCollapsible/CollapseButton.tsx +++ b/packages/docusaurus-theme-classic/src/theme/TOCCollapsible/CollapseButton/index.tsx @@ -8,9 +8,10 @@ import React from 'react'; import clsx from 'clsx'; import Translate from '@docusaurus/Translate'; -import styles from './CollapseButton.module.css'; import type {Props} from '@theme/TOCCollapsible/CollapseButton'; +import styles from './styles.module.css'; + export default function TOCCollapsibleCollapseButton({ collapsed, ...props diff --git a/packages/docusaurus-theme-classic/src/theme/TOCCollapsible/CollapseButton.module.css b/packages/docusaurus-theme-classic/src/theme/TOCCollapsible/CollapseButton/styles.module.css similarity index 100% rename from packages/docusaurus-theme-classic/src/theme/TOCCollapsible/CollapseButton.module.css rename to packages/docusaurus-theme-classic/src/theme/TOCCollapsible/CollapseButton/styles.module.css diff --git a/packages/docusaurus-theme-classic/src/theme/TOCCollapsible/index.tsx b/packages/docusaurus-theme-classic/src/theme/TOCCollapsible/index.tsx index de818634329c..19680832c205 100644 --- a/packages/docusaurus-theme-classic/src/theme/TOCCollapsible/index.tsx +++ b/packages/docusaurus-theme-classic/src/theme/TOCCollapsible/index.tsx @@ -8,10 +8,11 @@ import React from 'react'; import clsx from 'clsx'; import {useCollapsible, Collapsible} from '@docusaurus/theme-common'; -import styles from './index.module.css'; import TOCItems from '@theme/TOCItems'; -import type {Props} from '@theme/TOCCollapsible'; import CollapseButton from '@theme/TOCCollapsible/CollapseButton'; +import type {Props} from '@theme/TOCCollapsible'; + +import styles from './styles.module.css'; export default function TOCCollapsible({ toc, diff --git a/packages/docusaurus-theme-classic/src/theme/TOCCollapsible/index.module.css b/packages/docusaurus-theme-classic/src/theme/TOCCollapsible/styles.module.css similarity index 100% rename from packages/docusaurus-theme-classic/src/theme/TOCCollapsible/index.module.css rename to packages/docusaurus-theme-classic/src/theme/TOCCollapsible/styles.module.css diff --git a/packages/docusaurus-theme-classic/src/theme/TOCInline/index.tsx b/packages/docusaurus-theme-classic/src/theme/TOCInline/index.tsx index b0bae1aafbc0..9864572f5359 100644 --- a/packages/docusaurus-theme-classic/src/theme/TOCInline/index.tsx +++ b/packages/docusaurus-theme-classic/src/theme/TOCInline/index.tsx @@ -6,9 +6,10 @@ */ import React from 'react'; +import TOCItems from '@theme/TOCItems'; import type {Props} from '@theme/TOCInline'; + import styles from './styles.module.css'; -import TOCItems from '@theme/TOCItems'; export default function TOCInline({ toc, diff --git a/packages/docusaurus-theme-classic/src/theme/TOCItems/index.tsx b/packages/docusaurus-theme-classic/src/theme/TOCItems/index.tsx index 544df3db72b6..3743706a4462 100644 --- a/packages/docusaurus-theme-classic/src/theme/TOCItems/index.tsx +++ b/packages/docusaurus-theme-classic/src/theme/TOCItems/index.tsx @@ -6,14 +6,14 @@ */ import React, {useMemo} from 'react'; -import type {Props} from '@theme/TOCItems'; -import TOCItemTree from '@theme/TOCItems/Tree'; import { type TOCHighlightConfig, useThemeConfig, useTOCHighlight, useFilteredAndTreeifiedTOC, } from '@docusaurus/theme-common'; +import TOCItemTree from '@theme/TOCItems/Tree'; +import type {Props} from '@theme/TOCItems'; export default function TOCItems({ toc, diff --git a/packages/docusaurus-theme-classic/src/theme/TabItem/index.tsx b/packages/docusaurus-theme-classic/src/theme/TabItem/index.tsx index 7b847dacc89e..b0a6c3cdc0c2 100644 --- a/packages/docusaurus-theme-classic/src/theme/TabItem/index.tsx +++ b/packages/docusaurus-theme-classic/src/theme/TabItem/index.tsx @@ -6,8 +6,8 @@ */ import React from 'react'; -import type {Props} from '@theme/TabItem'; import clsx from 'clsx'; +import type {Props} from '@theme/TabItem'; import styles from './styles.module.css'; diff --git a/packages/docusaurus-theme-classic/src/theme/Tabs/__tests__/index.test.tsx b/packages/docusaurus-theme-classic/src/theme/Tabs/__tests__/index.test.tsx index b609058e80c6..f5d4f2d7f58f 100644 --- a/packages/docusaurus-theme-classic/src/theme/Tabs/__tests__/index.test.tsx +++ b/packages/docusaurus-theme-classic/src/theme/Tabs/__tests__/index.test.tsx @@ -7,12 +7,12 @@ import React from 'react'; import renderer from 'react-test-renderer'; -import Tabs from '../index'; -import TabItem from '../../TabItem'; import { TabGroupChoiceProvider, ScrollControllerProvider, } from '@docusaurus/theme-common'; +import Tabs from '../index'; +import TabItem from '../../TabItem'; describe('Tabs', () => { it('rejects bad Tabs child', () => { diff --git a/packages/docusaurus-theme-classic/src/theme/Tabs/index.tsx b/packages/docusaurus-theme-classic/src/theme/Tabs/index.tsx index 2e64f414607c..e81a01d3fc5b 100644 --- a/packages/docusaurus-theme-classic/src/theme/Tabs/index.tsx +++ b/packages/docusaurus-theme-classic/src/theme/Tabs/index.tsx @@ -11,6 +11,7 @@ import React, { isValidElement, type ReactElement, } from 'react'; +import clsx from 'clsx'; import useIsBrowser from '@docusaurus/useIsBrowser'; import { useScrollPositionBlocker, @@ -20,14 +21,14 @@ import { import type {Props} from '@theme/Tabs'; import type {Props as TabItemProps} from '@theme/TabItem'; -import clsx from 'clsx'; - import styles from './styles.module.css'; // A very rough duck type, but good enough to guard against mistakes while // allowing customization -function isTabItem(comp: ReactElement): comp is ReactElement { - return typeof comp.props.value !== 'undefined'; +function isTabItem( + comp: ReactElement, +): comp is ReactElement { + return 'value' in comp.props; } function TabsComponent(props: Props): JSX.Element { diff --git a/packages/docusaurus-theme-classic/src/theme/TagsListByLetter/index.tsx b/packages/docusaurus-theme-classic/src/theme/TagsListByLetter/index.tsx index c301c12e1ac4..326efa0c7767 100644 --- a/packages/docusaurus-theme-classic/src/theme/TagsListByLetter/index.tsx +++ b/packages/docusaurus-theme-classic/src/theme/TagsListByLetter/index.tsx @@ -6,9 +6,9 @@ */ import React from 'react'; +import {listTagsByLetters, type TagLetterEntry} from '@docusaurus/theme-common'; import Tag from '@theme/Tag'; import type {Props} from '@theme/TagsListByLetter'; -import {listTagsByLetters, type TagLetterEntry} from '@docusaurus/theme-common'; import styles from './styles.module.css'; diff --git a/packages/docusaurus-theme-classic/src/theme/ThemedImage/index.tsx b/packages/docusaurus-theme-classic/src/theme/ThemedImage/index.tsx index 0255e04805bb..b0b938350278 100644 --- a/packages/docusaurus-theme-classic/src/theme/ThemedImage/index.tsx +++ b/packages/docusaurus-theme-classic/src/theme/ThemedImage/index.tsx @@ -7,7 +7,6 @@ import React from 'react'; import clsx from 'clsx'; - import useIsBrowser from '@docusaurus/useIsBrowser'; import {useColorMode} from '@docusaurus/theme-common'; import type {Props} from '@theme/ThemedImage'; diff --git a/packages/docusaurus-theme-classic/src/translations.ts b/packages/docusaurus-theme-classic/src/translations.ts index 8d8bd673b48d..cc087a87d85a 100644 --- a/packages/docusaurus-theme-classic/src/translations.ts +++ b/packages/docusaurus-theme-classic/src/translations.ts @@ -5,6 +5,8 @@ * LICENSE file in the root directory of this source tree. */ +import _ from 'lodash'; +import {mergeTranslations} from '@docusaurus/utils'; import type {TranslationFile, TranslationFileContent} from '@docusaurus/types'; import type { ThemeConfig, @@ -15,9 +17,6 @@ import type { SimpleFooter, } from '@docusaurus/theme-common'; -import _ from 'lodash'; -import {mergeTranslations} from '@docusaurus/utils'; - function getNavbarTranslationFile(navbar: Navbar): TranslationFileContent { // TODO handle properly all the navbar item types here! function flattenNavbarItems(items: NavbarItem[]): NavbarItem[] { diff --git a/packages/docusaurus-theme-classic/tsconfig.client.json b/packages/docusaurus-theme-classic/tsconfig.client.json new file mode 100644 index 000000000000..067fb209a75d --- /dev/null +++ b/packages/docusaurus-theme-classic/tsconfig.client.json @@ -0,0 +1,20 @@ +{ + "extends": "../../tsconfig.json", + "compilerOptions": { + "noEmit": false, + "composite": true, + "incremental": true, + "tsBuildInfoFile": "./lib/.tsbuildinfo-client", + "rootDir": "src", + "outDir": "lib", + "module": "esnext", + "target": "esnext" + }, + "include": [ + "src/nprogress.ts", + "src/prism-include-languages.ts", + "src/theme", + "src/*.d.ts" + ], + "exclude": ["**/__tests__/**"] +} diff --git a/packages/docusaurus-theme-classic/tsconfig.json b/packages/docusaurus-theme-classic/tsconfig.json index 145e89f84a44..9e41ec3ef68c 100644 --- a/packages/docusaurus-theme-classic/tsconfig.json +++ b/packages/docusaurus-theme-classic/tsconfig.json @@ -1,10 +1,19 @@ { "extends": "../../tsconfig.json", + "references": [{"path": "./tsconfig.client.json"}], "compilerOptions": { - "lib": ["DOM", "ES2019"], - "module": "esnext", - "noEmit": true, - "jsx": "react-native" + "noEmit": false, + "incremental": true, + "tsBuildInfoFile": "./lib/.tsbuildinfo", + "module": "commonjs", + "rootDir": "src", + "outDir": "lib" }, - "include": ["src/"] + "include": ["src"], + "exclude": [ + "src/nprogress.ts", + "src/prism-include-languages.ts", + "src/theme", + "**/__tests__/**" + ] } diff --git a/packages/docusaurus-theme-common/.npmignore b/packages/docusaurus-theme-common/.npmignore index f2b994d4e359..03c9ae1e1b54 100644 --- a/packages/docusaurus-theme-common/.npmignore +++ b/packages/docusaurus-theme-common/.npmignore @@ -1,4 +1,3 @@ -copyUntypedFiles.mjs -.tsbuildinfo +.tsbuildinfo* tsconfig* __tests__ diff --git a/packages/docusaurus-theme-common/copyUntypedFiles.mjs b/packages/docusaurus-theme-common/copyUntypedFiles.mjs deleted file mode 100644 index 8b230152f1af..000000000000 --- a/packages/docusaurus-theme-common/copyUntypedFiles.mjs +++ /dev/null @@ -1,20 +0,0 @@ -/** - * Copyright (c) Facebook, Inc. and its affiliates. - * - * This source code is licensed under the MIT license found in the - * LICENSE file in the root directory of this source tree. - */ - -import fs from 'fs-extra'; -import {fileURLToPath} from 'url'; - -/** - * Copy all untyped and static assets files to lib. - */ -const srcDir = fileURLToPath(new URL('src', import.meta.url)); -const libDir = fileURLToPath(new URL('lib', import.meta.url)); -await fs.copy(srcDir, libDir, { - filter(filepath) { - return !/__tests__/.test(filepath) && !/\.tsx?$/.test(filepath); - }, -}); diff --git a/packages/docusaurus-theme-common/package.json b/packages/docusaurus-theme-common/package.json index 7a7244429472..ff097aa08e95 100644 --- a/packages/docusaurus-theme-common/package.json +++ b/packages/docusaurus-theme-common/package.json @@ -13,8 +13,10 @@ "./Details": "./lib/components/Details/index.js" }, "scripts": { - "build": "node copyUntypedFiles.mjs && tsc", - "watch": "node copyUntypedFiles.mjs && tsc --watch" + "build": "tsc && node ../../admin/scripts/copyUntypedFiles.js", + "watch": "run-p -c copy:watch build:watch", + "build:watch": "tsc --watch", + "copy:watch": "node ../../admin/scripts/copyUntypedFiles.js --watch" }, "publishConfig": { "access": "public" @@ -32,7 +34,7 @@ "@docusaurus/plugin-content-pages": "2.0.0-beta.20", "clsx": "^1.1.1", "parse-numeric-range": "^1.3.0", - "prism-react-renderer": "^1.3.1", + "prism-react-renderer": "^1.3.3", "tslib": "^2.4.0", "utility-types": "^3.10.0" }, diff --git a/packages/docusaurus-theme-common/src/components/Collapsible/index.tsx b/packages/docusaurus-theme-common/src/components/Collapsible/index.tsx index 48ff620fbab7..b6210a2b3660 100644 --- a/packages/docusaurus-theme-common/src/components/Collapsible/index.tsx +++ b/packages/docusaurus-theme-common/src/components/Collapsible/index.tsx @@ -5,7 +5,6 @@ * LICENSE file in the root directory of this source tree. */ -import ExecutionEnvironment from '@docusaurus/ExecutionEnvironment'; import React, { useState, useEffect, @@ -17,6 +16,7 @@ import React, { type SetStateAction, type ReactNode, } from 'react'; +import ExecutionEnvironment from '@docusaurus/ExecutionEnvironment'; const DefaultAnimationEasing = 'ease-in-out'; @@ -196,9 +196,7 @@ function CollapsibleBase({ className, disableSSRStyle, }: CollapsibleBaseProps) { - // any because TS is a pain for HTML element refs, see https://twitter.com/sebastienlorber/status/1412784677795110914 - // eslint-disable-next-line @typescript-eslint/no-explicit-any - const collapsibleRef = useRef(null); + const collapsibleRef = useRef(null); useCollapseAnimation({collapsibleRef, collapsed, animation}); @@ -206,7 +204,7 @@ function CollapsibleBase({ } // Refs are contravariant, which is not expressible in TS style={disableSSRStyle ? undefined : getSSRStyle(collapsed)} onTransitionEnd={(e: React.TransitionEvent) => { if (e.propertyName !== 'height') { diff --git a/packages/docusaurus-theme-common/src/components/Details/index.tsx b/packages/docusaurus-theme-common/src/components/Details/index.tsx index 0936ccf9db25..41c34097aa86 100644 --- a/packages/docusaurus-theme-common/src/components/Details/index.tsx +++ b/packages/docusaurus-theme-common/src/components/Details/index.tsx @@ -11,8 +11,8 @@ import React, { type ComponentProps, type ReactElement, } from 'react'; -import useIsBrowser from '@docusaurus/useIsBrowser'; import clsx from 'clsx'; +import useIsBrowser from '@docusaurus/useIsBrowser'; import {useCollapsible, Collapsible} from '../Collapsible'; import styles from './styles.module.css'; diff --git a/packages/docusaurus-theme-common/src/contexts/colorMode.tsx b/packages/docusaurus-theme-common/src/contexts/colorMode.tsx index a2347f1c0141..8d0513278eb7 100644 --- a/packages/docusaurus-theme-common/src/contexts/colorMode.tsx +++ b/packages/docusaurus-theme-common/src/contexts/colorMode.tsx @@ -14,9 +14,8 @@ import React, { useRef, type ReactNode, } from 'react'; -import {ReactContextError} from '../utils/reactUtils'; - import ExecutionEnvironment from '@docusaurus/ExecutionEnvironment'; +import {ReactContextError} from '../utils/reactUtils'; import {createStorageSlot} from '../utils/storageUtils'; import {useThemeConfig} from '../utils/useThemeConfig'; diff --git a/packages/docusaurus-theme-common/src/contexts/docsPreferredVersion.tsx b/packages/docusaurus-theme-common/src/contexts/docsPreferredVersion.tsx index 0922c2c33c89..96e941143ff5 100644 --- a/packages/docusaurus-theme-common/src/contexts/docsPreferredVersion.tsx +++ b/packages/docusaurus-theme-common/src/contexts/docsPreferredVersion.tsx @@ -13,22 +13,20 @@ import React, { useCallback, type ReactNode, } from 'react'; -import { - useThemeConfig, - type DocsVersionPersistence, -} from '../utils/useThemeConfig'; -import {isDocsPluginEnabled} from '../utils/docsUtils'; -import {ReactContextError} from '../utils/reactUtils'; -import {createStorageSlot} from '../utils/storageUtils'; - import { useAllDocsData, useDocsData, type GlobalPluginData, type GlobalVersion, } from '@docusaurus/plugin-content-docs/client'; - import {DEFAULT_PLUGIN_ID} from '@docusaurus/constants'; +import { + useThemeConfig, + type DocsVersionPersistence, +} from '../utils/useThemeConfig'; +import {isDocsPluginEnabled} from '../utils/docsUtils'; +import {ReactContextError} from '../utils/reactUtils'; +import {createStorageSlot} from '../utils/storageUtils'; const storageKey = (pluginId: string) => `docs-preferred-version-${pluginId}`; diff --git a/packages/docusaurus-theme-common/src/contexts/docsSidebar.tsx b/packages/docusaurus-theme-common/src/contexts/docsSidebar.tsx index 6b0aab47622e..43f109bf7698 100644 --- a/packages/docusaurus-theme-common/src/contexts/docsSidebar.tsx +++ b/packages/docusaurus-theme-common/src/contexts/docsSidebar.tsx @@ -6,8 +6,8 @@ */ import React, {useMemo, useContext, type ReactNode} from 'react'; -import type {PropSidebar} from '@docusaurus/plugin-content-docs'; import {ReactContextError} from '../utils/reactUtils'; +import type {PropSidebar} from '@docusaurus/plugin-content-docs'; // Using a Symbol because null is a valid context value (a doc with no sidebar) // Inspired by https://github.com/jamiebuilds/unstated-next/blob/master/src/unstated-next.tsx diff --git a/packages/docusaurus-theme-common/src/contexts/docsVersion.tsx b/packages/docusaurus-theme-common/src/contexts/docsVersion.tsx index efa8ffc147d6..4a3ad576f917 100644 --- a/packages/docusaurus-theme-common/src/contexts/docsVersion.tsx +++ b/packages/docusaurus-theme-common/src/contexts/docsVersion.tsx @@ -6,8 +6,8 @@ */ import React, {type ReactNode, useContext} from 'react'; -import type {PropVersionMetadata} from '@docusaurus/plugin-content-docs'; import {ReactContextError} from '../utils/reactUtils'; +import type {PropVersionMetadata} from '@docusaurus/plugin-content-docs'; const Context = React.createContext(null); diff --git a/packages/docusaurus-theme-common/src/hooks/usePrismTheme.ts b/packages/docusaurus-theme-common/src/hooks/usePrismTheme.ts index b791d3119414..df435eeedafd 100644 --- a/packages/docusaurus-theme-common/src/hooks/usePrismTheme.ts +++ b/packages/docusaurus-theme-common/src/hooks/usePrismTheme.ts @@ -5,9 +5,9 @@ * LICENSE file in the root directory of this source tree. */ -import type {PrismTheme} from 'prism-react-renderer'; import {useColorMode} from '../contexts/colorMode'; import {useThemeConfig} from '../utils/useThemeConfig'; +import type {PrismTheme} from 'prism-react-renderer'; /** * Returns a color-mode-dependent Prism theme: whatever the user specified in diff --git a/packages/docusaurus-theme-common/src/hooks/useSearchPage.ts b/packages/docusaurus-theme-common/src/hooks/useSearchPage.ts index 36c1cdaacf0b..10661b17f0d8 100644 --- a/packages/docusaurus-theme-common/src/hooks/useSearchPage.ts +++ b/packages/docusaurus-theme-common/src/hooks/useSearchPage.ts @@ -5,9 +5,9 @@ * LICENSE file in the root directory of this source tree. */ +import {useCallback, useEffect, useState} from 'react'; import {useHistory} from '@docusaurus/router'; import useDocusaurusContext from '@docusaurus/useDocusaurusContext'; -import {useCallback, useEffect, useState} from 'react'; const SEARCH_PARAM_QUERY = 'q'; diff --git a/packages/docusaurus-theme-common/src/utils/__tests__/docsUtils.test.tsx b/packages/docusaurus-theme-common/src/utils/__tests__/docsUtils.test.tsx index 532fb20a0acf..b8ac8fb9eedd 100644 --- a/packages/docusaurus-theme-common/src/utils/__tests__/docsUtils.test.tsx +++ b/packages/docusaurus-theme-common/src/utils/__tests__/docsUtils.test.tsx @@ -7,6 +7,8 @@ import React from 'react'; import {renderHook} from '@testing-library/react-hooks'; +import {StaticRouter} from 'react-router-dom'; +import {Context} from '@docusaurus/core/src/client/docusaurusContext'; import { findFirstCategoryLink, isActiveSidebarItem, @@ -17,8 +19,6 @@ import { } from '../docsUtils'; import {DocsSidebarProvider} from '../../contexts/docsSidebar'; import {DocsVersionProvider} from '../../contexts/docsVersion'; -import {StaticRouter} from 'react-router-dom'; -import {Context} from '@docusaurus/core/src/client/docusaurusContext'; import type { PropSidebar, PropSidebarItem, diff --git a/packages/docusaurus-theme-common/src/utils/__tests__/generalUtils.test.tsx b/packages/docusaurus-theme-common/src/utils/__tests__/generalUtils.test.tsx index 71c49527abad..6a2680fde148 100644 --- a/packages/docusaurus-theme-common/src/utils/__tests__/generalUtils.test.tsx +++ b/packages/docusaurus-theme-common/src/utils/__tests__/generalUtils.test.tsx @@ -6,9 +6,9 @@ */ import React from 'react'; -import {useTitleFormatter} from '../generalUtils'; import {renderHook} from '@testing-library/react-hooks'; import {Context} from '@docusaurus/core/src/client/docusaurusContext'; +import {useTitleFormatter} from '../generalUtils'; import type {DocusaurusContext} from '@docusaurus/types'; describe('useTitleFormatter', () => { diff --git a/packages/docusaurus-theme-common/src/utils/__tests__/reactUtils.test.ts b/packages/docusaurus-theme-common/src/utils/__tests__/reactUtils.test.ts index 0b3e11fa1d43..3aaec1e34704 100644 --- a/packages/docusaurus-theme-common/src/utils/__tests__/reactUtils.test.ts +++ b/packages/docusaurus-theme-common/src/utils/__tests__/reactUtils.test.ts @@ -5,8 +5,8 @@ * LICENSE file in the root directory of this source tree. */ -import {usePrevious} from '../reactUtils'; import {renderHook} from '@testing-library/react-hooks'; +import {usePrevious} from '../reactUtils'; describe('usePrevious', () => { it('returns the previous value of a variable', () => { diff --git a/packages/docusaurus-theme-common/src/utils/__tests__/routesUtils.test.ts b/packages/docusaurus-theme-common/src/utils/__tests__/routesUtils.test.ts index a226c13f1156..3302107db271 100644 --- a/packages/docusaurus-theme-common/src/utils/__tests__/routesUtils.test.ts +++ b/packages/docusaurus-theme-common/src/utils/__tests__/routesUtils.test.ts @@ -5,8 +5,8 @@ * LICENSE file in the root directory of this source tree. */ -import type {RouteConfig} from 'react-router-config'; import {findHomePageRoute, isSamePath} from '../routesUtils'; +import type {RouteConfig} from 'react-router-config'; describe('isSamePath', () => { it('returns true for compared path without trailing slash', () => { diff --git a/packages/docusaurus-theme-common/src/utils/__tests__/tocUtils.test.ts b/packages/docusaurus-theme-common/src/utils/__tests__/tocUtils.test.ts index 0ae93d7024b6..6424f8d341a9 100644 --- a/packages/docusaurus-theme-common/src/utils/__tests__/tocUtils.test.ts +++ b/packages/docusaurus-theme-common/src/utils/__tests__/tocUtils.test.ts @@ -5,9 +5,9 @@ * LICENSE file in the root directory of this source tree. */ -import type {TOCItem} from '@docusaurus/types'; import {renderHook} from '@testing-library/react-hooks'; import {useFilteredAndTreeifiedTOC, useTreeifiedTOC} from '../tocUtils'; +import type {TOCItem} from '@docusaurus/mdx-loader'; const mockTOC: TOCItem[] = [ { diff --git a/packages/docusaurus-theme-common/src/utils/__tests__/useAlternatePageUtils.test.tsx b/packages/docusaurus-theme-common/src/utils/__tests__/useAlternatePageUtils.test.tsx index 79ebd6cbca7f..e10b938baa4b 100644 --- a/packages/docusaurus-theme-common/src/utils/__tests__/useAlternatePageUtils.test.tsx +++ b/packages/docusaurus-theme-common/src/utils/__tests__/useAlternatePageUtils.test.tsx @@ -6,10 +6,10 @@ */ import React from 'react'; -import {useAlternatePageUtils} from '../useAlternatePageUtils'; import {renderHook} from '@testing-library/react-hooks'; import {StaticRouter} from 'react-router-dom'; import {Context} from '@docusaurus/core/src/client/docusaurusContext'; +import {useAlternatePageUtils} from '../useAlternatePageUtils'; import type {DocusaurusContext} from '@docusaurus/types'; describe('useAlternatePageUtils', () => { diff --git a/packages/docusaurus-theme-common/src/utils/__tests__/useLocalPathname.test.tsx b/packages/docusaurus-theme-common/src/utils/__tests__/useLocalPathname.test.tsx index 163e2f69bdb7..f2f6e189393a 100644 --- a/packages/docusaurus-theme-common/src/utils/__tests__/useLocalPathname.test.tsx +++ b/packages/docusaurus-theme-common/src/utils/__tests__/useLocalPathname.test.tsx @@ -6,10 +6,10 @@ */ import React from 'react'; -import {useLocalPathname} from '../useLocalPathname'; import {renderHook} from '@testing-library/react-hooks'; import {StaticRouter} from 'react-router-dom'; import {Context} from '@docusaurus/core/src/client/docusaurusContext'; +import {useLocalPathname} from '../useLocalPathname'; import type {DocusaurusContext} from '@docusaurus/types'; describe('useLocalPathname', () => { diff --git a/packages/docusaurus-theme-common/src/utils/__tests__/usePluralForm.test.tsx b/packages/docusaurus-theme-common/src/utils/__tests__/usePluralForm.test.tsx index 10c471d2eb1e..f7618dbb258c 100644 --- a/packages/docusaurus-theme-common/src/utils/__tests__/usePluralForm.test.tsx +++ b/packages/docusaurus-theme-common/src/utils/__tests__/usePluralForm.test.tsx @@ -7,9 +7,9 @@ import {jest} from '@jest/globals'; import React from 'react'; -import {usePluralForm} from '../usePluralForm'; import {renderHook} from '@testing-library/react-hooks'; import {Context} from '@docusaurus/core/src/client/docusaurusContext'; +import {usePluralForm} from '../usePluralForm'; import type {DocusaurusContext} from '@docusaurus/types'; describe('usePluralForm', () => { diff --git a/packages/docusaurus-theme-common/src/utils/codeBlockUtils.ts b/packages/docusaurus-theme-common/src/utils/codeBlockUtils.ts index fa091fe7a1b1..97c9056eb297 100644 --- a/packages/docusaurus-theme-common/src/utils/codeBlockUtils.ts +++ b/packages/docusaurus-theme-common/src/utils/codeBlockUtils.ts @@ -5,9 +5,9 @@ * LICENSE file in the root directory of this source tree. */ +import type {CSSProperties} from 'react'; import rangeParser from 'parse-numeric-range'; import type {PrismTheme} from 'prism-react-renderer'; -import type {CSSProperties} from 'react'; const codeBlockTitleRegex = /title=(?["'])(?.*?)\1/; const metastringLinesRangeRegex = /\{(?<range>[\d,-]+)\}/; diff --git a/packages/docusaurus-theme-common/src/utils/docsUtils.tsx b/packages/docusaurus-theme-common/src/utils/docsUtils.tsx index 706504118b35..45d92d093770 100644 --- a/packages/docusaurus-theme-common/src/utils/docsUtils.tsx +++ b/packages/docusaurus-theme-common/src/utils/docsUtils.tsx @@ -6,6 +6,8 @@ */ import {useMemo} from 'react'; +import {matchPath, useLocation} from '@docusaurus/router'; +import renderRoutes from '@docusaurus/renderRoutes'; import { useAllDocsData, useActivePlugin, @@ -15,6 +17,12 @@ import { type GlobalSidebar, type GlobalDoc, } from '@docusaurus/plugin-content-docs/client'; +import type {Props as DocPageProps} from '@theme/DocPage'; +import {useDocsPreferredVersion} from '../contexts/docsPreferredVersion'; +import {useDocsVersion} from '../contexts/docsVersion'; +import {useDocsSidebar} from '../contexts/docsSidebar'; +import {uniq} from './jsUtils'; +import {isSamePath} from './routesUtils'; import type { PropSidebar, PropSidebarItem, @@ -22,14 +30,6 @@ import type { PropVersionDoc, PropSidebarBreadcrumbsItem, } from '@docusaurus/plugin-content-docs'; -import type {Props as DocPageProps} from '@theme/DocPage'; -import {useDocsPreferredVersion} from '../contexts/docsPreferredVersion'; -import {useDocsVersion} from '../contexts/docsVersion'; -import {useDocsSidebar} from '../contexts/docsSidebar'; -import {uniq} from './jsUtils'; -import {isSamePath} from './routesUtils'; -import {matchPath, useLocation} from '@docusaurus/router'; -import renderRoutes from '@docusaurus/renderRoutes'; // TODO not ideal, see also "useDocs" export const isDocsPluginEnabled: boolean = !!useAllDocsData; @@ -318,7 +318,7 @@ export function useDocRouteMetadata({ } // For now, the sidebarName is added as route config: not ideal! - const sidebarName = currentDocRoute.sidebar; + const sidebarName = currentDocRoute.sidebar as string; const sidebarItems = sidebarName ? versionMetadata.docsSidebars[sidebarName] diff --git a/packages/docusaurus-theme-common/src/utils/metadataUtils.tsx b/packages/docusaurus-theme-common/src/utils/metadataUtils.tsx index 9610faa2e40b..af91c55a3a3c 100644 --- a/packages/docusaurus-theme-common/src/utils/metadataUtils.tsx +++ b/packages/docusaurus-theme-common/src/utils/metadataUtils.tsx @@ -6,8 +6,8 @@ */ import React, {type ReactNode} from 'react'; -import Head from '@docusaurus/Head'; import clsx from 'clsx'; +import Head from '@docusaurus/Head'; import useRouteContext from '@docusaurus/useRouteContext'; import {useBaseUrlUtils} from '@docusaurus/useBaseUrl'; import {useTitleFormatter} from './generalUtils'; diff --git a/packages/docusaurus-theme-common/src/utils/scrollUtils.tsx b/packages/docusaurus-theme-common/src/utils/scrollUtils.tsx index 79799c37fc24..32095c3feac3 100644 --- a/packages/docusaurus-theme-common/src/utils/scrollUtils.tsx +++ b/packages/docusaurus-theme-common/src/utils/scrollUtils.tsx @@ -14,9 +14,9 @@ import React, { useRef, type ReactNode, } from 'react'; -import {useDynamicCallback, ReactContextError} from './reactUtils'; import ExecutionEnvironment from '@docusaurus/ExecutionEnvironment'; import useIsBrowser from '@docusaurus/useIsBrowser'; +import {useDynamicCallback, ReactContextError} from './reactUtils'; type ScrollController = { /** A boolean ref tracking whether scroll events are enabled. */ diff --git a/packages/docusaurus-theme-common/src/utils/searchUtils.ts b/packages/docusaurus-theme-common/src/utils/searchUtils.ts index 463c69a90fa6..7f6fe91e48f0 100644 --- a/packages/docusaurus-theme-common/src/utils/searchUtils.ts +++ b/packages/docusaurus-theme-common/src/utils/searchUtils.ts @@ -9,8 +9,8 @@ import { useAllDocsData, useActivePluginAndVersion, } from '@docusaurus/plugin-content-docs/client'; -import {useDocsPreferredVersionByPluginId} from '../contexts/docsPreferredVersion'; import useDocusaurusContext from '@docusaurus/useDocusaurusContext'; +import {useDocsPreferredVersionByPluginId} from '../contexts/docsPreferredVersion'; export const DEFAULT_SEARCH_TAG = 'default'; diff --git a/packages/docusaurus-theme-common/src/utils/useLocationChange.ts b/packages/docusaurus-theme-common/src/utils/useLocationChange.ts index dd8ec1d0249c..515493996e26 100644 --- a/packages/docusaurus-theme-common/src/utils/useLocationChange.ts +++ b/packages/docusaurus-theme-common/src/utils/useLocationChange.ts @@ -7,8 +7,8 @@ import {useEffect} from 'react'; import {useLocation} from '@docusaurus/router'; -import type {Location} from 'history'; import {useDynamicCallback, usePrevious} from './reactUtils'; +import type {Location} from 'history'; /** * Fires an effect when the location changes (which includes hash, query, etc.). diff --git a/packages/docusaurus-theme-common/tsconfig.json b/packages/docusaurus-theme-common/tsconfig.json index 20c3d66f6411..ceffc5496b4b 100644 --- a/packages/docusaurus-theme-common/tsconfig.json +++ b/packages/docusaurus-theme-common/tsconfig.json @@ -1,13 +1,16 @@ { "extends": "../../tsconfig.json", "compilerOptions": { + "noEmit": false, "incremental": true, "tsBuildInfoFile": "./lib/.tsbuildinfo", "module": "esnext", + "target": "esnext", "sourceMap": true, "declarationMap": true, "rootDir": "src", "outDir": "lib" }, - "include": ["src"] + "include": ["src"], + "exclude": ["**/__tests__/**"] } diff --git a/packages/docusaurus-theme-live-codeblock/.npmignore b/packages/docusaurus-theme-live-codeblock/.npmignore index f2b994d4e359..03c9ae1e1b54 100644 --- a/packages/docusaurus-theme-live-codeblock/.npmignore +++ b/packages/docusaurus-theme-live-codeblock/.npmignore @@ -1,4 +1,3 @@ -copyUntypedFiles.mjs -.tsbuildinfo +.tsbuildinfo* tsconfig* __tests__ diff --git a/packages/docusaurus-theme-live-codeblock/copyUntypedFiles.mjs b/packages/docusaurus-theme-live-codeblock/copyUntypedFiles.mjs deleted file mode 100644 index 8b230152f1af..000000000000 --- a/packages/docusaurus-theme-live-codeblock/copyUntypedFiles.mjs +++ /dev/null @@ -1,20 +0,0 @@ -/** - * Copyright (c) Facebook, Inc. and its affiliates. - * - * This source code is licensed under the MIT license found in the - * LICENSE file in the root directory of this source tree. - */ - -import fs from 'fs-extra'; -import {fileURLToPath} from 'url'; - -/** - * Copy all untyped and static assets files to lib. - */ -const srcDir = fileURLToPath(new URL('src', import.meta.url)); -const libDir = fileURLToPath(new URL('lib', import.meta.url)); -await fs.copy(srcDir, libDir, { - filter(filepath) { - return !/__tests__/.test(filepath) && !/\.tsx?$/.test(filepath); - }, -}); diff --git a/packages/docusaurus-theme-live-codeblock/package.json b/packages/docusaurus-theme-live-codeblock/package.json index 2e7974942241..f107b6b8b302 100644 --- a/packages/docusaurus-theme-live-codeblock/package.json +++ b/packages/docusaurus-theme-live-codeblock/package.json @@ -11,11 +11,10 @@ "access": "public" }, "scripts": { - "build": "yarn build:server && yarn build:client && yarn build:copy && yarn build:format", - "build:server": "tsc --project tsconfig.server.json", - "build:client": "tsc --project tsconfig.client.json", - "build:copy": "node copyUntypedFiles.mjs", - "build:format": "prettier --config ../../.prettierrc --write \"lib/**/*.js\"" + "build": "tsc --build && node ../../admin/scripts/copyUntypedFiles.js && prettier --config ../../.prettierrc --write \"lib/theme/**/*.js\"", + "watch": "run-p -c copy:watch build:watch", + "build:watch": "tsc --build --watch", + "copy:watch": "node ../../admin/scripts/copyUntypedFiles.js --watch" }, "repository": { "type": "git", diff --git a/packages/docusaurus-theme-live-codeblock/src/theme/Playground/index.tsx b/packages/docusaurus-theme-live-codeblock/src/theme/Playground/index.tsx index 7ca4c62f326d..64a6cc354517 100644 --- a/packages/docusaurus-theme-live-codeblock/src/theme/Playground/index.tsx +++ b/packages/docusaurus-theme-live-codeblock/src/theme/Playground/index.tsx @@ -6,15 +6,16 @@ */ import React from 'react'; -import {LiveProvider, LiveEditor, LiveError, LivePreview} from 'react-live'; import clsx from 'clsx'; +import useIsBrowser from '@docusaurus/useIsBrowser'; +import {LiveProvider, LiveEditor, LiveError, LivePreview} from 'react-live'; import Translate from '@docusaurus/Translate'; import useDocusaurusContext from '@docusaurus/useDocusaurusContext'; import BrowserOnly from '@docusaurus/BrowserOnly'; import {usePrismTheme} from '@docusaurus/theme-common'; -import styles from './styles.module.css'; -import useIsBrowser from '@docusaurus/useIsBrowser'; import type {Props} from '@theme/Playground'; + +import styles from './styles.module.css'; import type {ThemeConfig} from '@docusaurus/theme-live-codeblock'; function Header({children}: {children: React.ReactNode}) { diff --git a/packages/docusaurus-theme-live-codeblock/tsconfig.client.json b/packages/docusaurus-theme-live-codeblock/tsconfig.client.json index 462a6376e3be..222005186ea5 100644 --- a/packages/docusaurus-theme-live-codeblock/tsconfig.client.json +++ b/packages/docusaurus-theme-live-codeblock/tsconfig.client.json @@ -1,8 +1,15 @@ { - "extends": "./tsconfig.json", + "extends": "../../tsconfig.json", "compilerOptions": { + "noEmit": false, + "composite": true, + "incremental": true, + "tsBuildInfoFile": "./lib/.tsbuildinfo-client", + "rootDir": "src", + "outDir": "lib", "module": "esnext", - "jsx": "react-native" + "target": "esnext" }, - "include": ["src/theme/", "src/*.d.ts", "src/custom-buble.ts"] + "include": ["src/theme", "src/*.d.ts", "src/custom-buble.ts"], + "exclude": ["**/__tests__/**"] } diff --git a/packages/docusaurus-theme-live-codeblock/tsconfig.json b/packages/docusaurus-theme-live-codeblock/tsconfig.json index f5902ba1089b..c0b15f81fcc8 100644 --- a/packages/docusaurus-theme-live-codeblock/tsconfig.json +++ b/packages/docusaurus-theme-live-codeblock/tsconfig.json @@ -1,9 +1,14 @@ { "extends": "../../tsconfig.json", + "references": [{"path": "./tsconfig.client.json"}], "compilerOptions": { + "noEmit": false, "incremental": true, "tsBuildInfoFile": "./lib/.tsbuildinfo", + "module": "commonjs", "rootDir": "src", "outDir": "lib" - } + }, + "include": ["src"], + "exclude": ["src/custom-buble.ts", "src/theme", "**/__tests__/**"] } diff --git a/packages/docusaurus-theme-live-codeblock/tsconfig.server.json b/packages/docusaurus-theme-live-codeblock/tsconfig.server.json deleted file mode 100644 index 2159e2ef8e20..000000000000 --- a/packages/docusaurus-theme-live-codeblock/tsconfig.server.json +++ /dev/null @@ -1,5 +0,0 @@ -{ - "extends": "./tsconfig.json", - "include": ["src/*.ts"], - "exclude": ["src/custom-buble.ts"] -} diff --git a/packages/docusaurus-theme-search-algolia/.npmignore b/packages/docusaurus-theme-search-algolia/.npmignore index f2b994d4e359..03c9ae1e1b54 100644 --- a/packages/docusaurus-theme-search-algolia/.npmignore +++ b/packages/docusaurus-theme-search-algolia/.npmignore @@ -1,4 +1,3 @@ -copyUntypedFiles.mjs -.tsbuildinfo +.tsbuildinfo* tsconfig* __tests__ diff --git a/packages/docusaurus-theme-search-algolia/copyUntypedFiles.mjs b/packages/docusaurus-theme-search-algolia/copyUntypedFiles.mjs deleted file mode 100644 index 8b230152f1af..000000000000 --- a/packages/docusaurus-theme-search-algolia/copyUntypedFiles.mjs +++ /dev/null @@ -1,20 +0,0 @@ -/** - * Copyright (c) Facebook, Inc. and its affiliates. - * - * This source code is licensed under the MIT license found in the - * LICENSE file in the root directory of this source tree. - */ - -import fs from 'fs-extra'; -import {fileURLToPath} from 'url'; - -/** - * Copy all untyped and static assets files to lib. - */ -const srcDir = fileURLToPath(new URL('src', import.meta.url)); -const libDir = fileURLToPath(new URL('lib', import.meta.url)); -await fs.copy(srcDir, libDir, { - filter(filepath) { - return !/__tests__/.test(filepath) && !/\.tsx?$/.test(filepath); - }, -}); diff --git a/packages/docusaurus-theme-search-algolia/package.json b/packages/docusaurus-theme-search-algolia/package.json index f1e3f6db96fb..6ec7ab36203a 100644 --- a/packages/docusaurus-theme-search-algolia/package.json +++ b/packages/docusaurus-theme-search-algolia/package.json @@ -21,14 +21,13 @@ }, "license": "MIT", "scripts": { - "build": "yarn build:server && yarn build:client && yarn build:copy && yarn build:format", - "build:server": "tsc --project tsconfig.server.json", - "build:client": "tsc --project tsconfig.client.json", - "build:copy": "node copyUntypedFiles.mjs", - "build:format": "prettier --config ../../.prettierrc --write \"lib/**/*.js\"" + "build": "tsc --build && node ../../admin/scripts/copyUntypedFiles.js && prettier --config ../../.prettierrc --write \"lib/theme/**/*.js\"", + "watch": "run-p -c copy:watch build:watch", + "build:watch": "tsc --build --watch", + "copy:watch": "node ../../admin/scripts/copyUntypedFiles.js --watch" }, "dependencies": { - "@docsearch/react": "^3.0.0", + "@docsearch/react": "^3.1.0", "@docusaurus/core": "2.0.0-beta.20", "@docusaurus/logger": "2.0.0-beta.20", "@docusaurus/plugin-content-docs": "2.0.0-beta.20", @@ -36,7 +35,7 @@ "@docusaurus/theme-translations": "2.0.0-beta.20", "@docusaurus/utils": "2.0.0-beta.20", "@docusaurus/utils-validation": "2.0.0-beta.20", - "algoliasearch": "^4.13.0", + "algoliasearch": "^4.13.1", "algoliasearch-helper": "^3.8.2", "clsx": "^1.1.1", "eta": "^1.12.3", diff --git a/packages/docusaurus-theme-search-algolia/src/__tests__/validateThemeConfig.test.ts b/packages/docusaurus-theme-search-algolia/src/__tests__/validateThemeConfig.test.ts index 71c13896b4d3..23be336647ec 100644 --- a/packages/docusaurus-theme-search-algolia/src/__tests__/validateThemeConfig.test.ts +++ b/packages/docusaurus-theme-search-algolia/src/__tests__/validateThemeConfig.test.ts @@ -5,8 +5,8 @@ * LICENSE file in the root directory of this source tree. */ -import type {Joi} from '@docusaurus/utils-validation'; import {validateThemeConfig, DEFAULT_CONFIG} from '../validateThemeConfig'; +import type {Joi} from '@docusaurus/utils-validation'; function testValidateThemeConfig(themeConfig: {[key: string]: unknown}) { function validate(schema: Joi.Schema, cfg: {[key: string]: unknown}) { diff --git a/packages/docusaurus-theme-search-algolia/src/index.ts b/packages/docusaurus-theme-search-algolia/src/index.ts index 46f80161652c..dbd2a58db30c 100644 --- a/packages/docusaurus-theme-search-algolia/src/index.ts +++ b/packages/docusaurus-theme-search-algolia/src/index.ts @@ -7,12 +7,12 @@ import path from 'path'; import fs from 'fs-extra'; +import _ from 'lodash'; +import logger from '@docusaurus/logger'; import {defaultConfig, compile} from 'eta'; import {normalizeUrl} from '@docusaurus/utils'; import {readDefaultCodeTranslationMessages} from '@docusaurus/theme-translations'; -import logger from '@docusaurus/logger'; import openSearchTemplate from './templates/opensearch'; -import _ from 'lodash'; import type {LoadContext, Plugin} from '@docusaurus/types'; import type {ThemeConfig} from '@docusaurus/theme-search-algolia'; diff --git a/packages/docusaurus-theme-search-algolia/src/theme/SearchBar/index.tsx b/packages/docusaurus-theme-search-algolia/src/theme/SearchBar/index.tsx index 6217dbf50b41..217555ad316d 100644 --- a/packages/docusaurus-theme-search-algolia/src/theme/SearchBar/index.tsx +++ b/packages/docusaurus-theme-search-algolia/src/theme/SearchBar/index.tsx @@ -14,7 +14,6 @@ import Link from '@docusaurus/Link'; import Head from '@docusaurus/Head'; import {isRegexpStringMatch, useSearchPage} from '@docusaurus/theme-common'; import {DocSearchButton, useDocSearchKeyboardEvents} from '@docsearch/react'; -import type {SearchClient} from 'algoliasearch/lite'; import {useAlgoliaContextualFacetFilters} from '@docusaurus/theme-search-algolia/client'; import Translate, {translate} from '@docusaurus/Translate'; @@ -26,6 +25,7 @@ import type { InternalDocSearchHit, StoredDocSearchHit, } from '@docsearch/react/dist/esm/types'; +import type {SearchClient} from 'algoliasearch/lite'; import type {AutocompleteState} from '@algolia/autocomplete-core'; type DocSearchProps = Omit< diff --git a/packages/docusaurus-theme-search-algolia/src/theme/SearchPage/index.tsx b/packages/docusaurus-theme-search-algolia/src/theme/SearchPage/index.tsx index 5a79ce31050f..7be755278b12 100644 --- a/packages/docusaurus-theme-search-algolia/src/theme/SearchPage/index.tsx +++ b/packages/docusaurus-theme-search-algolia/src/theme/SearchPage/index.tsx @@ -8,10 +8,10 @@ /* eslint-disable jsx-a11y/no-autofocus */ import React, {useEffect, useState, useReducer, useRef} from 'react'; +import clsx from 'clsx'; import algoliaSearch from 'algoliasearch/lite'; import algoliaSearchHelper from 'algoliasearch-helper'; -import clsx from 'clsx'; import Head from '@docusaurus/Head'; import Link from '@docusaurus/Link'; @@ -26,8 +26,9 @@ import { } from '@docusaurus/theme-common'; import useDocusaurusContext from '@docusaurus/useDocusaurusContext'; import {useAllDocsData} from '@docusaurus/plugin-content-docs/client'; -import Layout from '@theme/Layout'; import Translate, {translate} from '@docusaurus/Translate'; +import Layout from '@theme/Layout'; + import styles from './styles.module.css'; import type {ThemeConfig} from '@docusaurus/theme-search-algolia'; diff --git a/packages/docusaurus-theme-search-algolia/tsconfig.client.json b/packages/docusaurus-theme-search-algolia/tsconfig.client.json index 0ea16454ec40..a8c1d3f7de50 100644 --- a/packages/docusaurus-theme-search-algolia/tsconfig.client.json +++ b/packages/docusaurus-theme-search-algolia/tsconfig.client.json @@ -1,8 +1,15 @@ { - "extends": "./tsconfig.json", + "extends": "../../tsconfig.json", "compilerOptions": { + "noEmit": false, + "composite": true, + "incremental": true, + "tsBuildInfoFile": "./lib/.tsbuildinfo-client", + "rootDir": "src", + "outDir": "lib", "module": "esnext", - "jsx": "react-native" + "target": "esnext" }, - "include": ["src/theme/", "src/client/", "src/*.d.ts"] + "include": ["src/theme", "src/client", "src/*.d.ts"], + "exclude": ["**/__tests__/**"] } diff --git a/packages/docusaurus-theme-search-algolia/tsconfig.json b/packages/docusaurus-theme-search-algolia/tsconfig.json index 51aec434b257..3c8737f51c0d 100644 --- a/packages/docusaurus-theme-search-algolia/tsconfig.json +++ b/packages/docusaurus-theme-search-algolia/tsconfig.json @@ -1,8 +1,14 @@ { "extends": "../../tsconfig.json", + "references": [{"path": "./tsconfig.client.json"}], "compilerOptions": { - "lib": ["DOM", "ES2019"], + "noEmit": false, + "incremental": true, + "tsBuildInfoFile": "./lib/.tsbuildinfo", + "module": "commonjs", "rootDir": "src", "outDir": "lib" - } + }, + "include": ["src"], + "exclude": ["src/client", "src/theme", "**/__tests__/**"] } diff --git a/packages/docusaurus-theme-search-algolia/tsconfig.server.json b/packages/docusaurus-theme-search-algolia/tsconfig.server.json deleted file mode 100644 index 3faf6c3e997b..000000000000 --- a/packages/docusaurus-theme-search-algolia/tsconfig.server.json +++ /dev/null @@ -1,4 +0,0 @@ -{ - "extends": "./tsconfig.json", - "include": ["src/*.ts", "src/templates/*.ts"] -} diff --git a/packages/docusaurus-theme-translations/.npmignore b/packages/docusaurus-theme-translations/.npmignore index 1b59b1ca638c..7059569fc57d 100644 --- a/packages/docusaurus-theme-translations/.npmignore +++ b/packages/docusaurus-theme-translations/.npmignore @@ -1,5 +1,4 @@ -copyUntypedFiles.mjs -.tsbuildinfo +.tsbuildinfo* tsconfig* __tests__ diff --git a/packages/docusaurus-theme-translations/locales/__tests__/locales.test.ts b/packages/docusaurus-theme-translations/locales/__tests__/locales.test.ts index 7bf0bf22a430..3b7a611cbcd6 100644 --- a/packages/docusaurus-theme-translations/locales/__tests__/locales.test.ts +++ b/packages/docusaurus-theme-translations/locales/__tests__/locales.test.ts @@ -6,10 +6,10 @@ */ import {jest} from '@jest/globals'; -import {extractThemeCodeMessages} from '../../src/utils'; import path from 'path'; import fs from 'fs-extra'; import _ from 'lodash'; +import {extractThemeCodeMessages} from '../../src/utils'; // Seems the 5s default timeout fails sometimes jest.setTimeout(15000); diff --git a/packages/docusaurus-theme-translations/package.json b/packages/docusaurus-theme-translations/package.json index 5c27fb37c93c..a296a446f3eb 100644 --- a/packages/docusaurus-theme-translations/package.json +++ b/packages/docusaurus-theme-translations/package.json @@ -14,8 +14,8 @@ }, "license": "MIT", "scripts": { - "build": "tsc -p tsconfig.build.json", - "watch": "tsc -p tsconfig.build.json --watch", + "build": "tsc --build", + "watch": "tsc --build --watch", "update": "node ./update.mjs" }, "dependencies": { diff --git a/packages/docusaurus-theme-translations/src/utils.ts b/packages/docusaurus-theme-translations/src/utils.ts index beb1370817e1..95cf7f4ec712 100644 --- a/packages/docusaurus-theme-translations/src/utils.ts +++ b/packages/docusaurus-theme-translations/src/utils.ts @@ -23,12 +23,9 @@ import type {TranslationFileContent} from '@docusaurus/types'; async function getPackageCodePath(packageName: string) { const packagePath = path.join(__dirname, '../..', packageName); const packageJsonPath = path.join(packagePath, 'package.json'); - const {main} = await fs.readJSON(packageJsonPath); + const {main} = (await fs.readJSON(packageJsonPath)) as {main: string}; const packageSrcPath = path.join(packagePath, path.dirname(main)); - const packageLibNextPath = packageSrcPath.replace('lib', 'lib-next'); - return (await fs.pathExists(packageLibNextPath)) - ? packageLibNextPath - : packageSrcPath; + return packageSrcPath; } export async function getThemes(): Promise<{name: string; src: string[]}[]> { diff --git a/packages/docusaurus-theme-translations/tsconfig.build.json b/packages/docusaurus-theme-translations/tsconfig.build.json index aee99fc0f38e..5370e86c56a5 100644 --- a/packages/docusaurus-theme-translations/tsconfig.build.json +++ b/packages/docusaurus-theme-translations/tsconfig.build.json @@ -1,11 +1,16 @@ { "extends": "../../tsconfig.json", "compilerOptions": { + "noEmit": false, + "composite": true, "incremental": true, "tsBuildInfoFile": "./lib/.tsbuildinfo", "sourceMap": true, "declarationMap": true, + "module": "commonjs", "rootDir": "src", "outDir": "lib" - } + }, + "include": ["src"], + "exclude": ["**/__tests__/**"] } diff --git a/packages/docusaurus-theme-translations/tsconfig.json b/packages/docusaurus-theme-translations/tsconfig.json index 59be626a2754..667e74599697 100644 --- a/packages/docusaurus-theme-translations/tsconfig.json +++ b/packages/docusaurus-theme-translations/tsconfig.json @@ -1,10 +1,11 @@ { "extends": "../../tsconfig.json", + "references": [{"path": "./tsconfig.build.json"}], "compilerOptions": { "module": "esnext", "noEmit": true, "checkJs": true, "allowJs": true }, - "include": ["update.mjs", "src"] + "include": ["update.mjs"] } diff --git a/packages/docusaurus-theme-translations/update.mjs b/packages/docusaurus-theme-translations/update.mjs index 85736bf696e4..73fa9c6c5fe1 100644 --- a/packages/docusaurus-theme-translations/update.mjs +++ b/packages/docusaurus-theme-translations/update.mjs @@ -7,11 +7,11 @@ // @ts-check -import logger from '@docusaurus/logger'; import path from 'path'; import {fileURLToPath} from 'url'; import fs from 'fs-extra'; import _ from 'lodash'; +import logger from '@docusaurus/logger'; import {getThemes, extractThemeCodeMessages} from './lib/utils.js'; const LocalesDirPath = fileURLToPath(new URL('locales', import.meta.url)); diff --git a/packages/docusaurus-types/package.json b/packages/docusaurus-types/package.json index b50c2100a5af..051f1625c8ff 100644 --- a/packages/docusaurus-types/package.json +++ b/packages/docusaurus-types/package.json @@ -12,9 +12,6 @@ "directory": "packages/docusaurus-types" }, "license": "MIT", - "scripts": { - "test": "tsc -p ." - }, "dependencies": { "commander": "^5.1.0", "history": "^4.9.0", diff --git a/packages/docusaurus-utils-common/.npmignore b/packages/docusaurus-utils-common/.npmignore index f2b994d4e359..03c9ae1e1b54 100644 --- a/packages/docusaurus-utils-common/.npmignore +++ b/packages/docusaurus-utils-common/.npmignore @@ -1,4 +1,3 @@ -copyUntypedFiles.mjs -.tsbuildinfo +.tsbuildinfo* tsconfig* __tests__ diff --git a/packages/docusaurus-utils-common/tsconfig.json b/packages/docusaurus-utils-common/tsconfig.json index c28192960036..f787010fcd78 100644 --- a/packages/docusaurus-utils-common/tsconfig.json +++ b/packages/docusaurus-utils-common/tsconfig.json @@ -1,12 +1,16 @@ { "extends": "../../tsconfig.json", "compilerOptions": { + "noEmit": false, "incremental": true, "tsBuildInfoFile": "./lib/.tsbuildinfo", "sourceMap": true, "declarationMap": true, + "module": "commonjs", "rootDir": "src", "outDir": "lib", "noEmitHelpers": false - } + }, + "include": ["src"], + "exclude": ["**/__tests__/**"] } diff --git a/packages/docusaurus-utils-validation/.npmignore b/packages/docusaurus-utils-validation/.npmignore index f2b994d4e359..03c9ae1e1b54 100644 --- a/packages/docusaurus-utils-validation/.npmignore +++ b/packages/docusaurus-utils-validation/.npmignore @@ -1,4 +1,3 @@ -copyUntypedFiles.mjs -.tsbuildinfo +.tsbuildinfo* tsconfig* __tests__ diff --git a/packages/docusaurus-utils-validation/src/JoiFrontMatter.ts b/packages/docusaurus-utils-validation/src/JoiFrontMatter.ts index 011bccd8796c..b09f528ec14d 100644 --- a/packages/docusaurus-utils-validation/src/JoiFrontMatter.ts +++ b/packages/docusaurus-utils-validation/src/JoiFrontMatter.ts @@ -11,7 +11,7 @@ const JoiFrontMatterString: Joi.Extension = { type: 'string', base: Joi.string(), // Fix Yaml that tries to auto-convert many things to string out of the box - prepare: (value) => { + prepare: (value: unknown) => { if (typeof value === 'number' || value instanceof Date) { return {value: value.toString()}; } diff --git a/packages/docusaurus-utils-validation/src/validationSchemas.ts b/packages/docusaurus-utils-validation/src/validationSchemas.ts index f8e9a1c36e0c..8c6a10e9c00b 100644 --- a/packages/docusaurus-utils-validation/src/validationSchemas.ts +++ b/packages/docusaurus-utils-validation/src/validationSchemas.ts @@ -5,8 +5,8 @@ * LICENSE file in the root directory of this source tree. */ -import Joi from './Joi'; import {isValidPathname, DEFAULT_PLUGIN_ID, type Tag} from '@docusaurus/utils'; +import Joi from './Joi'; import {JoiFrontMatter} from './JoiFrontMatter'; export const PluginIdSchema = Joi.string() @@ -40,10 +40,10 @@ export const URISchema = Joi.alternatives( Joi.string().uri({allowRelative: true}), // This custom validation logic is required notably because Joi does not // accept paths like /a/b/c ... - Joi.custom((val, helpers) => { + Joi.custom((val: unknown, helpers) => { try { // eslint-disable-next-line no-new - new URL(val); + new URL(String(val)); return val; } catch { return helpers.error('any.invalid'); @@ -55,7 +55,7 @@ export const URISchema = Joi.alternatives( }); export const PathnameSchema = Joi.string() - .custom((val) => { + .custom((val: string) => { if (!isValidPathname(val)) { throw new Error(); } diff --git a/packages/docusaurus-utils-validation/src/validationUtils.ts b/packages/docusaurus-utils-validation/src/validationUtils.ts index 33145624da4d..5d87c1a5e8e4 100644 --- a/packages/docusaurus-utils-validation/src/validationUtils.ts +++ b/packages/docusaurus-utils-validation/src/validationUtils.ts @@ -5,10 +5,10 @@ * LICENSE file in the root directory of this source tree. */ -import type Joi from './Joi'; import logger from '@docusaurus/logger'; import Yaml from 'js-yaml'; import {PluginIdSchema} from './validationSchemas'; +import type Joi from './Joi'; /** Print warnings returned from Joi validation. */ export function printWarning(warning?: Joi.ValidationError): void { diff --git a/packages/docusaurus-utils-validation/tsconfig.json b/packages/docusaurus-utils-validation/tsconfig.json index aee99fc0f38e..7807612b51a5 100644 --- a/packages/docusaurus-utils-validation/tsconfig.json +++ b/packages/docusaurus-utils-validation/tsconfig.json @@ -1,11 +1,15 @@ { "extends": "../../tsconfig.json", "compilerOptions": { + "noEmit": false, "incremental": true, "tsBuildInfoFile": "./lib/.tsbuildinfo", "sourceMap": true, "declarationMap": true, + "module": "commonjs", "rootDir": "src", "outDir": "lib" - } + }, + "include": ["src"], + "exclude": ["**/__tests__/**"] } diff --git a/packages/docusaurus-utils/.npmignore b/packages/docusaurus-utils/.npmignore index f2b994d4e359..03c9ae1e1b54 100644 --- a/packages/docusaurus-utils/.npmignore +++ b/packages/docusaurus-utils/.npmignore @@ -1,4 +1,3 @@ -copyUntypedFiles.mjs -.tsbuildinfo +.tsbuildinfo* tsconfig* __tests__ diff --git a/packages/docusaurus-utils/package.json b/packages/docusaurus-utils/package.json index cdddacda8d11..36dd648ff13d 100644 --- a/packages/docusaurus-utils/package.json +++ b/packages/docusaurus-utils/package.json @@ -42,7 +42,7 @@ "@types/dedent": "^0.7.0", "@types/github-slugger": "^1.3.0", "@types/micromatch": "^4.0.2", - "@types/react-dom": "^18.0.3", + "@types/react-dom": "^18.0.4", "dedent": "^0.7.0" } } diff --git a/packages/docusaurus-utils/src/__tests__/__snapshots__/markdownLinks.test.ts.snap b/packages/docusaurus-utils/src/__tests__/__snapshots__/markdownLinks.test.ts.snap index 56c08fd6f9e1..f42727544ff0 100644 --- a/packages/docusaurus-utils/src/__tests__/__snapshots__/markdownLinks.test.ts.snap +++ b/packages/docusaurus-utils/src/__tests__/__snapshots__/markdownLinks.test.ts.snap @@ -102,10 +102,10 @@ exports[`replaceMarkdownLinks replaces links with same title as URL 1`] = ` { "brokenMarkdownLinks": [], "newContent": " -[/docs/foo](foo.md) -[/docs/foo](./foo.md) [foo.md](/docs/foo) -[.//docs/foo](foo.md) +[./foo.md](/docs/foo) +[foo.md](/docs/foo) +[./foo.md](/docs/foo) ", } `; @@ -135,6 +135,13 @@ The following operations are defined for [URI]s: } `; +exports[`replaceMarkdownLinks replaces two links on the same line 1`] = ` +{ + "brokenMarkdownLinks": [], + "newContent": "[TypeScript](/programming-languages/typescript/) and [Go](/programming-languages/go/)", +} +`; + exports[`replaceMarkdownLinks resolves absolute and relative links differently 1`] = ` { "brokenMarkdownLinks": [ diff --git a/packages/docusaurus-utils/src/__tests__/emitUtils.test.ts b/packages/docusaurus-utils/src/__tests__/emitUtils.test.ts index 236d9c224dc8..0e97013b9ece 100644 --- a/packages/docusaurus-utils/src/__tests__/emitUtils.test.ts +++ b/packages/docusaurus-utils/src/__tests__/emitUtils.test.ts @@ -6,9 +6,9 @@ */ import {jest} from '@jest/globals'; -import {readOutputHTMLFile, generate} from '../emitUtils'; import path from 'path'; import fs from 'fs-extra'; +import {readOutputHTMLFile, generate} from '../emitUtils'; describe('readOutputHTMLFile', () => { it('reads both files with trailing slash undefined', async () => { diff --git a/packages/docusaurus-utils/src/__tests__/gitUtils.test.ts b/packages/docusaurus-utils/src/__tests__/gitUtils.test.ts index 1d4519536cc4..d701b8bca347 100644 --- a/packages/docusaurus-utils/src/__tests__/gitUtils.test.ts +++ b/packages/docusaurus-utils/src/__tests__/gitUtils.test.ts @@ -5,10 +5,10 @@ * LICENSE file in the root directory of this source tree. */ -import {FileNotTrackedError, getFileCommitDate} from '../gitUtils'; import fs from 'fs-extra'; import path from 'path'; import {createTempRepo} from '@testing-utils/git'; +import {FileNotTrackedError, getFileCommitDate} from '../gitUtils'; /* eslint-disable no-restricted-properties */ function initializeTempRepo() { diff --git a/packages/docusaurus-utils/src/__tests__/jsUtils.test.ts b/packages/docusaurus-utils/src/__tests__/jsUtils.test.ts index 6db16ef20f31..ca7218ab02ad 100644 --- a/packages/docusaurus-utils/src/__tests__/jsUtils.test.ts +++ b/packages/docusaurus-utils/src/__tests__/jsUtils.test.ts @@ -6,6 +6,7 @@ */ import {jest} from '@jest/globals'; +import _ from 'lodash'; import { removeSuffix, removePrefix, @@ -13,7 +14,6 @@ import { findAsyncSequential, reportMessage, } from '../jsUtils'; -import _ from 'lodash'; describe('removeSuffix', () => { it("is no-op when suffix doesn't exist", () => { diff --git a/packages/docusaurus-utils/src/__tests__/markdownLinks.test.ts b/packages/docusaurus-utils/src/__tests__/markdownLinks.test.ts index d47b3ab3e2db..46df9f1e6629 100644 --- a/packages/docusaurus-utils/src/__tests__/markdownLinks.test.ts +++ b/packages/docusaurus-utils/src/__tests__/markdownLinks.test.ts @@ -38,6 +38,35 @@ describe('replaceMarkdownLinks', () => { ).toMatchSnapshot(); }); + it('replaces two links on the same line', () => { + // cSpell:ignore Goooooooooo + // This is a very arcane bug: if we continue matching using the previous + // matching index (as is the behavior of RegExp#exec), it will go right over + // the next Markdown link and fail to match the "Go" link. This only happens + // when: (1) the replaced link is much shorter than the Markdown path, (2) + // the next link is very close to the current one (e.g. here if it's not + // "Go" but "Goooooooooo", or if every link has the /docs/ prefix, the bug + // will not trigger because it won't overshoot) + expect( + replaceMarkdownLinks({ + siteDir: '.', + filePath: 'docs/intro.md', + contentPaths: { + contentPath: 'docs', + contentPathLocalized: 'i18n/docs-localized', + }, + sourceToPermalink: { + '@site/docs/intro.md': '/', + '@site/docs/programming-languages/typescript/typescript.md': + '/programming-languages/typescript/', + '@site/docs/programming-languages/go/go.md': + '/programming-languages/go/', + }, + fileString: `[TypeScript](programming-languages/typescript/typescript.md) and [Go](programming-languages/go/go.md)`, + }), + ).toMatchSnapshot(); + }); + it('replaces reference style Markdown links', () => { expect( replaceMarkdownLinks({ @@ -155,7 +184,7 @@ The following operations are defined for [URI]s: ).toMatchSnapshot(); }); - // TODO bad + // FIXME it('ignores links in inline code', () => { expect( replaceMarkdownLinks({ @@ -175,7 +204,6 @@ The following operations are defined for [URI]s: ).toMatchSnapshot(); }); - // TODO bad it('replaces links with same title as URL', () => { expect( replaceMarkdownLinks({ diff --git a/packages/docusaurus-utils/src/__tests__/markdownUtils.test.ts b/packages/docusaurus-utils/src/__tests__/markdownUtils.test.ts index 09488bc4a6c0..2f4baa74ccd6 100644 --- a/packages/docusaurus-utils/src/__tests__/markdownUtils.test.ts +++ b/packages/docusaurus-utils/src/__tests__/markdownUtils.test.ts @@ -5,6 +5,7 @@ * LICENSE file in the root directory of this source tree. */ +import dedent from 'dedent'; import { createExcerpt, parseMarkdownContentTitle, @@ -12,7 +13,6 @@ import { parseMarkdownHeadingId, writeMarkdownHeadingId, } from '../markdownUtils'; -import dedent from 'dedent'; describe('createExcerpt', () => { it('creates excerpt for text-only content', () => { diff --git a/packages/docusaurus-utils/src/__tests__/pathUtils.test.ts b/packages/docusaurus-utils/src/__tests__/pathUtils.test.ts index eaf2b61cd906..eb6cc8d13f07 100644 --- a/packages/docusaurus-utils/src/__tests__/pathUtils.test.ts +++ b/packages/docusaurus-utils/src/__tests__/pathUtils.test.ts @@ -6,6 +6,7 @@ */ import {jest} from '@jest/globals'; +import path from 'path'; import { isNameTooLong, shortName, @@ -15,7 +16,6 @@ import { toMessageRelativeFilePath, addTrailingPathSeparator, } from '../pathUtils'; -import path from 'path'; describe('isNameTooLong', () => { it('works', () => { diff --git a/packages/docusaurus-utils/src/constants.ts b/packages/docusaurus-utils/src/constants.ts index a9a91394f48c..be9405eab9bd 100644 --- a/packages/docusaurus-utils/src/constants.ts +++ b/packages/docusaurus-utils/src/constants.ts @@ -17,8 +17,9 @@ export const NODE_MINOR_VERSION = parseInt( ); /** Docusaurus core version. */ -// eslint-disable-next-line global-require, @typescript-eslint/no-var-requires -export const DOCUSAURUS_VERSION = require('../package.json').version; +export const DOCUSAURUS_VERSION = + // eslint-disable-next-line global-require, @typescript-eslint/no-var-requires + (require('../package.json') as {version: string}).version; /** * Can be overridden with cli option `--out-dir`. Code should generally use diff --git a/packages/docusaurus-utils/src/dataFileUtils.ts b/packages/docusaurus-utils/src/dataFileUtils.ts index 34ed9befeb83..937d22b9cf2b 100644 --- a/packages/docusaurus-utils/src/dataFileUtils.ts +++ b/packages/docusaurus-utils/src/dataFileUtils.ts @@ -6,11 +6,11 @@ */ import fs from 'fs-extra'; -import Yaml from 'js-yaml'; import path from 'path'; +import logger from '@docusaurus/logger'; +import Yaml from 'js-yaml'; import {findAsyncSequential} from './index'; import type {ContentPaths} from './markdownLinks'; -import logger from '@docusaurus/logger'; type DataFileParams = { /** Path to the potential data file, relative to `contentPaths` */ diff --git a/packages/docusaurus-utils/src/globUtils.ts b/packages/docusaurus-utils/src/globUtils.ts index 67af9051eeae..d95fa35b54be 100644 --- a/packages/docusaurus-utils/src/globUtils.ts +++ b/packages/docusaurus-utils/src/globUtils.ts @@ -7,8 +7,8 @@ // Globby/Micromatch are the 2 libs we use in Docusaurus consistently -import Micromatch from 'micromatch'; // Note: Micromatch is used by Globby import path from 'path'; +import Micromatch from 'micromatch'; // Note: Micromatch is used by Globby /** A re-export of the globby instance. */ export {default as Globby} from 'globby'; diff --git a/packages/docusaurus-utils/src/i18nUtils.ts b/packages/docusaurus-utils/src/i18nUtils.ts index e7e29815beb2..a6d08cf83749 100644 --- a/packages/docusaurus-utils/src/i18nUtils.ts +++ b/packages/docusaurus-utils/src/i18nUtils.ts @@ -7,13 +7,13 @@ import path from 'path'; import _ from 'lodash'; +import {DEFAULT_PLUGIN_ID, I18N_DIR_NAME} from './constants'; +import {normalizeUrl} from './urlUtils'; import type { TranslationFileContent, TranslationFile, I18n, } from '@docusaurus/types'; -import {DEFAULT_PLUGIN_ID, I18N_DIR_NAME} from './constants'; -import {normalizeUrl} from './urlUtils'; /** * Takes a list of translation file contents, and shallow-merges them into one. diff --git a/packages/docusaurus-utils/src/jsUtils.ts b/packages/docusaurus-utils/src/jsUtils.ts index 1e2858fe620c..2d1f228f1eb7 100644 --- a/packages/docusaurus-utils/src/jsUtils.ts +++ b/packages/docusaurus-utils/src/jsUtils.ts @@ -5,8 +5,8 @@ * LICENSE file in the root directory of this source tree. */ -import type {ReportingSeverity} from '@docusaurus/types'; import logger from '@docusaurus/logger'; +import type {ReportingSeverity} from '@docusaurus/types'; /** Removes a given string suffix from `str`. */ export function removeSuffix(str: string, suffix: string): string { diff --git a/packages/docusaurus-utils/src/markdownLinks.ts b/packages/docusaurus-utils/src/markdownLinks.ts index 3a7966ad8db7..af322fe840d2 100644 --- a/packages/docusaurus-utils/src/markdownLinks.ts +++ b/packages/docusaurus-utils/src/markdownLinks.ts @@ -137,7 +137,13 @@ export function replaceMarkdownLinks<T extends ContentPaths>({ .split('/') .map((part) => part.replace(/\s/g, '%20')) .join('/'); - modifiedLine = modifiedLine.replace(mdLink, encodedPermalink); + modifiedLine = modifiedLine.replace( + mdMatch[0]!, + mdMatch[0]!.replace(mdLink, encodedPermalink), + ); + // Adjust the lastIndex to avoid passing over the next link if the + // newly replaced URL is shorter. + mdRegex.lastIndex += encodedPermalink.length - mdLink.length; } else { const brokenMarkdownLink: BrokenMarkdownLink<T> = { contentPaths, diff --git a/packages/docusaurus-utils/src/markdownUtils.ts b/packages/docusaurus-utils/src/markdownUtils.ts index a902c6f58fa0..fd11f5e66708 100644 --- a/packages/docusaurus-utils/src/markdownUtils.ts +++ b/packages/docusaurus-utils/src/markdownUtils.ts @@ -280,7 +280,10 @@ This can happen if you use special characters in front matter values (try using } function unwrapMarkdownLinks(line: string): string { - return line.replace(/\[(?<alt>[^\]]+)\]\([^)]+\)/g, (match, p1) => p1); + return line.replace( + /\[(?<alt>[^\]]+)\]\([^)]+\)/g, + (match, p1: string) => p1, + ); } function addHeadingId( diff --git a/packages/docusaurus-utils/src/urlUtils.ts b/packages/docusaurus-utils/src/urlUtils.ts index c6ad13d2d88e..708d50dbfe57 100644 --- a/packages/docusaurus-utils/src/urlUtils.ts +++ b/packages/docusaurus-utils/src/urlUtils.ts @@ -5,8 +5,8 @@ * LICENSE file in the root directory of this source tree. */ -import {removeSuffix} from './jsUtils'; import resolvePathnameUnsafe from 'resolve-pathname'; +import {removeSuffix} from './jsUtils'; /** * Much like `path.join`, but much better. Takes an array of URL segments, and diff --git a/packages/docusaurus-utils/src/webpackUtils.ts b/packages/docusaurus-utils/src/webpackUtils.ts index 4116867c9dff..fa579e06b470 100644 --- a/packages/docusaurus-utils/src/webpackUtils.ts +++ b/packages/docusaurus-utils/src/webpackUtils.ts @@ -5,13 +5,13 @@ * LICENSE file in the root directory of this source tree. */ -import type {RuleSetRule} from 'webpack'; import path from 'path'; import {escapePath} from './pathUtils'; import { WEBPACK_URL_LOADER_LIMIT, OUTPUT_STATIC_ASSETS_DIR_NAME, } from './constants'; +import type {RuleSetRule} from 'webpack'; type AssetFolder = 'images' | 'files' | 'fonts' | 'medias'; diff --git a/packages/docusaurus-utils/tsconfig.json b/packages/docusaurus-utils/tsconfig.json index aee99fc0f38e..7807612b51a5 100644 --- a/packages/docusaurus-utils/tsconfig.json +++ b/packages/docusaurus-utils/tsconfig.json @@ -1,11 +1,15 @@ { "extends": "../../tsconfig.json", "compilerOptions": { + "noEmit": false, "incremental": true, "tsBuildInfoFile": "./lib/.tsbuildinfo", "sourceMap": true, "declarationMap": true, + "module": "commonjs", "rootDir": "src", "outDir": "lib" - } + }, + "include": ["src"], + "exclude": ["**/__tests__/**"] } diff --git a/packages/docusaurus/.npmignore b/packages/docusaurus/.npmignore index ba8304029eb7..e4132af42172 100644 --- a/packages/docusaurus/.npmignore +++ b/packages/docusaurus/.npmignore @@ -1,5 +1,4 @@ -copyUntypedFiles.mjs -.tsbuildinfo +.tsbuildinfo* tsconfig* __tests__ diff --git a/packages/docusaurus/bin/beforeCli.mjs b/packages/docusaurus/bin/beforeCli.mjs index 0c374dba1722..fa4cecdbc77c 100644 --- a/packages/docusaurus/bin/beforeCli.mjs +++ b/packages/docusaurus/bin/beforeCli.mjs @@ -7,13 +7,13 @@ // @ts-check -import logger from '@docusaurus/logger'; import fs from 'fs-extra'; -import semver from 'semver'; import path from 'path'; +import {createRequire} from 'module'; +import logger from '@docusaurus/logger'; +import semver from 'semver'; import updateNotifier from 'update-notifier'; import boxen from 'boxen'; -import {createRequire} from 'module'; import {DOCUSAURUS_VERSION} from '@docusaurus/utils'; const packageJson = createRequire(import.meta.url)('../package.json'); diff --git a/packages/docusaurus/bin/docusaurus.mjs b/packages/docusaurus/bin/docusaurus.mjs index 759aad41cc98..820d26e7de9a 100755 --- a/packages/docusaurus/bin/docusaurus.mjs +++ b/packages/docusaurus/bin/docusaurus.mjs @@ -8,8 +8,8 @@ // @ts-check -import logger from '@docusaurus/logger'; import fs from 'fs-extra'; +import logger from '@docusaurus/logger'; import cli from 'commander'; import {DOCUSAURUS_VERSION} from '@docusaurus/utils'; import { @@ -126,6 +126,10 @@ cli '--poll [interval]', 'use polling rather than watching for reload (default: false). Can specify a poll interval in milliseconds', ) + .option( + '--no-minify', + 'build website without minimizing JS bundles (default: false)', + ) .action(async (siteDir, options) => start(await resolveDir(siteDir), options), ); diff --git a/packages/docusaurus/copyUntypedFiles.mjs b/packages/docusaurus/copyUntypedFiles.mjs deleted file mode 100644 index 8b230152f1af..000000000000 --- a/packages/docusaurus/copyUntypedFiles.mjs +++ /dev/null @@ -1,20 +0,0 @@ -/** - * Copyright (c) Facebook, Inc. and its affiliates. - * - * This source code is licensed under the MIT license found in the - * LICENSE file in the root directory of this source tree. - */ - -import fs from 'fs-extra'; -import {fileURLToPath} from 'url'; - -/** - * Copy all untyped and static assets files to lib. - */ -const srcDir = fileURLToPath(new URL('src', import.meta.url)); -const libDir = fileURLToPath(new URL('lib', import.meta.url)); -await fs.copy(srcDir, libDir, { - filter(filepath) { - return !/__tests__/.test(filepath) && !/\.tsx?$/.test(filepath); - }, -}); diff --git a/packages/docusaurus/package.json b/packages/docusaurus/package.json index 4019070675f0..9c2ead275092 100644 --- a/packages/docusaurus/package.json +++ b/packages/docusaurus/package.json @@ -24,23 +24,25 @@ "docusaurus": "bin/docusaurus.mjs" }, "scripts": { - "build": "tsc -p tsconfig.server.json && tsc -p tsconfig.client.json && node copyUntypedFiles.mjs", - "watch": "node copyUntypedFiles.mjs && concurrently -n \"server,client\" --kill-others \"tsc -p tsconfig.server.json --watch\" \"tsc -p tsconfig.client.json --watch\"" + "build": "tsc --build && node ../../admin/scripts/copyUntypedFiles.js", + "watch": "run-p -c copy:watch build:watch", + "build:watch": "tsc --build --watch", + "copy:watch": "node ../../admin/scripts/copyUntypedFiles.js --watch" }, "bugs": { "url": "https://github.com/facebook/docusaurus/issues" }, "dependencies": { - "@babel/core": "^7.17.10", - "@babel/generator": "^7.17.10", + "@babel/core": "^7.18.0", + "@babel/generator": "^7.18.0", "@babel/plugin-syntax-dynamic-import": "^7.8.3", - "@babel/plugin-transform-runtime": "^7.17.10", - "@babel/preset-env": "^7.17.10", - "@babel/preset-react": "^7.16.7", - "@babel/preset-typescript": "^7.16.7", - "@babel/runtime": "^7.17.9", - "@babel/runtime-corejs3": "^7.17.9", - "@babel/traverse": "^7.17.10", + "@babel/plugin-transform-runtime": "^7.18.0", + "@babel/preset-env": "^7.18.0", + "@babel/preset-react": "^7.17.12", + "@babel/preset-typescript": "^7.17.12", + "@babel/runtime": "^7.18.0", + "@babel/runtime-corejs3": "^7.18.0", + "@babel/traverse": "^7.18.0", "@docusaurus/cssnano-preset": "2.0.0-beta.20", "@docusaurus/logger": "2.0.0-beta.20", "@docusaurus/mdx-loader": "2.0.0-beta.20", @@ -54,6 +56,7 @@ "babel-loader": "^8.2.5", "babel-plugin-dynamic-import-node": "2.3.0", "boxen": "^6.2.1", + "chalk": "^4.1.2", "chokidar": "^3.5.3", "clean-css": "^5.3.0", "cli-table3": "^0.6.2", @@ -63,8 +66,8 @@ "core-js": "^3.22.5", "css-loader": "^6.7.1", "css-minimizer-webpack-plugin": "^3.4.1", - "cssnano": "^5.1.7", - "del": "^6.0.0", + "cssnano": "^5.1.9", + "del": "^6.1.0", "detect-port": "^1.3.0", "escape-html": "^1.0.3", "eta": "^1.12.3", @@ -77,16 +80,16 @@ "leven": "^3.1.0", "lodash": "^4.17.21", "mini-css-extract-plugin": "^2.6.0", - "postcss": "^8.4.13", + "postcss": "^8.4.14", "postcss-loader": "^6.2.1", "prompts": "^2.4.2", "react-dev-utils": "^12.0.1", "react-helmet-async": "^1.3.0", "react-loadable": "npm:@docusaurus/react-loadable@5.5.2", "react-loadable-ssr-addon-v5-slorber": "^1.0.1", - "react-router": "^5.2.0", + "react-router": "^5.3.3", "react-router-config": "^5.1.1", - "react-router-dom": "^5.2.0", + "react-router-dom": "^5.3.3", "remark-admonitions": "^1.2.1", "rtl-detect": "^1.0.4", "semver": "^7.3.7", @@ -107,7 +110,7 @@ "@docusaurus/module-type-aliases": "2.0.0-beta.20", "@docusaurus/types": "2.0.0-beta.20", "@types/detect-port": "^1.3.2", - "@types/react-dom": "^18.0.3", + "@types/react-dom": "^18.0.4", "@types/react-router-config": "^5.0.6", "@types/rtl-detect": "^1.0.0", "@types/serve-handler": "^6.1.1", diff --git a/packages/docusaurus/src/babel/preset.ts b/packages/docusaurus/src/babel/preset.ts index 3dd351ef9ac5..3d842007757e 100644 --- a/packages/docusaurus/src/babel/preset.ts +++ b/packages/docusaurus/src/babel/preset.ts @@ -53,7 +53,8 @@ function getTransformOptions(isServer: boolean): TransformOptions { // better to explicitly specify the version so that it can reuse the // helper better. See https://github.com/babel/babel/issues/10261 // eslint-disable-next-line @typescript-eslint/no-var-requires, global-require - version: require('@babel/runtime/package.json').version, + version: (require('@babel/runtime/package.json') as {version: string}) + .version, regenerator: true, useESModules: true, // Undocumented option that lets us encapsulate our runtime, ensuring diff --git a/packages/docusaurus/src/client/App.tsx b/packages/docusaurus/src/client/App.tsx index c709c2e8515f..da3a1ef22f0a 100644 --- a/packages/docusaurus/src/client/App.tsx +++ b/packages/docusaurus/src/client/App.tsx @@ -10,18 +10,20 @@ import '@generated/client-modules'; import routes from '@generated/routes'; import {useLocation} from '@docusaurus/router'; -import normalizeLocation from './normalizeLocation'; import renderRoutes from '@docusaurus/renderRoutes'; +import Root from '@theme/Root'; +import SiteMetadata from '@theme/SiteMetadata'; +import normalizeLocation from './normalizeLocation'; import {BrowserContextProvider} from './browserContext'; import {DocusaurusContextProvider} from './docusaurusContext'; import PendingNavigation from './PendingNavigation'; import BaseUrlIssueBanner from './BaseUrlIssueBanner'; import SiteMetadataDefaults from './SiteMetadataDefaults'; -import Root from '@theme/Root'; -import SiteMetadata from '@theme/SiteMetadata'; // TODO, quick fix for CSS insertion order +// eslint-disable-next-line import/order import ErrorBoundary from '@docusaurus/ErrorBoundary'; +// eslint-disable-next-line import/order import Error from '@theme/Error'; export default function App(): JSX.Element { diff --git a/packages/docusaurus/src/client/PendingNavigation.tsx b/packages/docusaurus/src/client/PendingNavigation.tsx index 3c2cca17f7b8..24e1e38faa2d 100644 --- a/packages/docusaurus/src/client/PendingNavigation.tsx +++ b/packages/docusaurus/src/client/PendingNavigation.tsx @@ -70,7 +70,7 @@ class PendingNavigation extends React.Component<Props, State> { this.routeUpdateCleanupCb?.(); this.setState({nextRouteHasLoaded: true}); }) - .catch((e) => console.warn(e)); + .catch((e: unknown) => console.warn(e)); return false; } diff --git a/packages/docusaurus/src/client/docusaurusContext.tsx b/packages/docusaurus/src/client/docusaurusContext.tsx index 5023b1eced70..5bed42737f37 100644 --- a/packages/docusaurus/src/client/docusaurusContext.tsx +++ b/packages/docusaurus/src/client/docusaurusContext.tsx @@ -6,13 +6,12 @@ */ import React, {type ReactNode} from 'react'; -import type {DocusaurusContext} from '@docusaurus/types'; - import siteConfig from '@generated/docusaurus.config'; import globalData from '@generated/globalData'; import i18n from '@generated/i18n'; import codeTranslations from '@generated/codeTranslations'; import siteMetadata from '@generated/site-metadata'; +import type {DocusaurusContext} from '@docusaurus/types'; // Static value on purpose: don't make it dynamic! // Using context is still useful for testability reasons. diff --git a/packages/docusaurus/src/client/exports/ComponentCreator.tsx b/packages/docusaurus/src/client/exports/ComponentCreator.tsx index 0caf13bebc39..77439b36425a 100644 --- a/packages/docusaurus/src/client/exports/ComponentCreator.tsx +++ b/packages/docusaurus/src/client/exports/ComponentCreator.tsx @@ -7,9 +7,9 @@ import React from 'react'; import Loadable from 'react-loadable'; -import Loading from '@theme/Loading'; import routesChunkNames from '@generated/routesChunkNames'; import registry from '@generated/registry'; +import Loading from '@theme/Loading'; import flat from '../flat'; import {RouteContextProvider} from '../routeContext'; diff --git a/packages/docusaurus/src/client/exports/ErrorBoundary.tsx b/packages/docusaurus/src/client/exports/ErrorBoundary.tsx index 11880aa67f70..b8dd78fe1a78 100644 --- a/packages/docusaurus/src/client/exports/ErrorBoundary.tsx +++ b/packages/docusaurus/src/client/exports/ErrorBoundary.tsx @@ -6,10 +6,9 @@ */ import React, {type ReactNode} from 'react'; - import ExecutionEnvironment from '@docusaurus/ExecutionEnvironment'; -import type {Props} from '@docusaurus/ErrorBoundary'; import DefaultFallback from '@theme/Error'; +import type {Props} from '@docusaurus/ErrorBoundary'; type State = { error: Error | null; diff --git a/packages/docusaurus/src/client/exports/Link.tsx b/packages/docusaurus/src/client/exports/Link.tsx index 3628e7495439..78a3f91a6b7b 100644 --- a/packages/docusaurus/src/client/exports/Link.tsx +++ b/packages/docusaurus/src/client/exports/Link.tsx @@ -11,15 +11,13 @@ import React, { useRef, type ComponentType, } from 'react'; - import {NavLink, Link as RRLink} from 'react-router-dom'; +import {applyTrailingSlash} from '@docusaurus/utils-common'; import useDocusaurusContext from './useDocusaurusContext'; import isInternalUrl from './isInternalUrl'; import ExecutionEnvironment from './ExecutionEnvironment'; import {useLinksCollector} from '../LinksCollector'; import {useBaseUrlUtils} from './useBaseUrl'; -import {applyTrailingSlash} from '@docusaurus/utils-common'; - import type {Props} from '@docusaurus/Link'; // TODO all this wouldn't be necessary if we used ReactRouter basename feature diff --git a/packages/docusaurus/src/client/exports/Translate.tsx b/packages/docusaurus/src/client/exports/Translate.tsx index 5cfbef7edb5c..b88606563871 100644 --- a/packages/docusaurus/src/client/exports/Translate.tsx +++ b/packages/docusaurus/src/client/exports/Translate.tsx @@ -7,10 +7,9 @@ import React from 'react'; import {interpolate, type InterpolateValues} from '@docusaurus/Interpolate'; -import type {TranslateParam, TranslateProps} from '@docusaurus/Translate'; - // Can't read it from context, due to exposing imperative API import codeTranslations from '@generated/codeTranslations'; +import type {TranslateParam, TranslateProps} from '@docusaurus/Translate'; function getLocalizedMessage({ id, diff --git a/packages/docusaurus/src/client/exports/__tests__/Head.test.tsx b/packages/docusaurus/src/client/exports/__tests__/Head.test.tsx index 847fa52391f7..067fc9ea25ee 100644 --- a/packages/docusaurus/src/client/exports/__tests__/Head.test.tsx +++ b/packages/docusaurus/src/client/exports/__tests__/Head.test.tsx @@ -6,9 +6,9 @@ */ import React from 'react'; -import Head from '../Head'; import {type FilledContext, HelmetProvider} from 'react-helmet-async'; import renderer from 'react-test-renderer'; +import Head from '../Head'; describe('Head', () => { it('does exactly what Helmet does', () => { diff --git a/packages/docusaurus/src/client/exports/useRouteContext.tsx b/packages/docusaurus/src/client/exports/useRouteContext.tsx index 9ba1a1f57039..ea80925c3208 100644 --- a/packages/docusaurus/src/client/exports/useRouteContext.tsx +++ b/packages/docusaurus/src/client/exports/useRouteContext.tsx @@ -6,8 +6,8 @@ */ import React from 'react'; -import type {PluginRouteContext} from '@docusaurus/types'; import {Context} from '../routeContext'; +import type {PluginRouteContext} from '@docusaurus/types'; export default function useRouteContext(): PluginRouteContext { const context = React.useContext(Context); diff --git a/packages/docusaurus/src/client/preload.ts b/packages/docusaurus/src/client/preload.ts index e77ac998f58d..fec374ad4b6b 100644 --- a/packages/docusaurus/src/client/preload.ts +++ b/packages/docusaurus/src/client/preload.ts @@ -19,8 +19,5 @@ import {matchRoutes} from 'react-router-config'; export default function preload(pathname: string): Promise<void[]> { const matches = matchRoutes(routes, pathname); - return Promise.all( - // @ts-expect-error: ComponentCreator injected this method. - matches.map((match) => match.route.component?.preload?.()), - ); + return Promise.all(matches.map((match) => match.route.component.preload?.())); } diff --git a/packages/docusaurus/src/client/serverEntry.tsx b/packages/docusaurus/src/client/serverEntry.tsx index 408bfee0e3dc..9918e4220adb 100644 --- a/packages/docusaurus/src/client/serverEntry.tsx +++ b/packages/docusaurus/src/client/serverEntry.tsx @@ -5,26 +5,25 @@ * LICENSE file in the root directory of this source tree. */ -import * as eta from 'eta'; import React from 'react'; +import path from 'path'; +import fs from 'fs-extra'; +// eslint-disable-next-line no-restricted-imports +import _ from 'lodash'; +import chalk from 'chalk'; +import * as eta from 'eta'; import {StaticRouter} from 'react-router-dom'; import ReactDOMServer from 'react-dom/server'; import {HelmetProvider, type FilledContext} from 'react-helmet-async'; import {getBundles, type Manifest} from 'react-loadable-ssr-addon-v5-slorber'; import Loadable from 'react-loadable'; - import {minify} from 'html-minifier-terser'; -import path from 'path'; -import fs from 'fs-extra'; import preload from './preload'; import App from './App'; import { createStatefulLinksCollector, LinksCollectorProvider, } from './LinksCollector'; -import logger from '@docusaurus/logger'; -// eslint-disable-next-line no-restricted-imports -import _ from 'lodash'; import type {Locals} from '@slorber/static-site-generator-webpack-plugin'; const getCompiledSSRTemplate = _.memoize((template: string) => @@ -44,15 +43,20 @@ export default async function render( try { return await doRender(locals); } catch (err) { - logger.error`Docusaurus server-side rendering could not render static page with path path=${locals.path}.`; + // We are not using logger in this file, because it seems to fail with some + // compilers / some polyfill methods. This is very likely a bug, but in the + // long term, when we output native ES modules in SSR, the bug will be gone. + // prettier-ignore + console.error(chalk.red(`${chalk.bold('[ERROR]')} Docusaurus server-side rendering could not render static page with path ${chalk.cyan.underline(locals.path)}.`)); const isNotDefinedErrorRegex = /(?:window|document|localStorage|navigator|alert|location|buffer|self) is not defined/i; if (isNotDefinedErrorRegex.test((err as Error).message)) { - logger.info`It looks like you are using code that should run on the client-side only. -To get around it, try using code=${'<BrowserOnly>'} (url=${'https://docusaurus.io/docs/docusaurus-core/#browseronly'}) or code=${'ExecutionEnvironment'} (url=${'https://docusaurus.io/docs/docusaurus-core/#executionenvironment'}). -It might also require to wrap your client code in code=${'useEffect'} hook and/or import a third-party library dynamically (if any).`; + // prettier-ignore + console.info(`${chalk.cyan.bold('[INFO]')} It looks like you are using code that should run on the client-side only. +To get around it, try using ${chalk.cyan('`<BrowserOnly>`')} (${chalk.cyan.underline('https://docusaurus.io/docs/docusaurus-core/#browseronly')}) or ${chalk.cyan('`ExecutionEnvironment`')} (${chalk.cyan.underline('https://docusaurus.io/docs/docusaurus-core/#executionenvironment')}). +It might also require to wrap your client code in ${chalk.cyan('`useEffect`')} hook and/or import a third-party library dynamically (if any).`); } throw err; @@ -108,7 +112,12 @@ async function doRender(locals: Locals & {path: string}) { const {generatedFilesDir} = locals; const manifestPath = path.join(generatedFilesDir, 'client-manifest.json'); - const manifest: Manifest = await fs.readJSON(manifestPath); + // Using readJSON seems to fail for users of some plugins, possibly because of + // the eval sandbox having a different `Buffer` instance (native one instead + // of polyfilled one) + const manifest: Manifest = await fs + .readFile(manifestPath, 'utf-8') + .then(JSON.parse); // Get all required assets for this particular page based on client // manifest information. @@ -144,7 +153,8 @@ async function doRender(locals: Locals & {path: string}) { minifyJS: true, }); } catch (err) { - logger.error`Minification of page path=${locals.path} failed.`; + // prettier-ignore + console.error(chalk.red(`${chalk.bold('[ERROR]')} Minification of page ${chalk.cyan.underline(locals.path)} failed.`)); throw err; } } diff --git a/packages/docusaurus/src/client/theme-fallback/Error/index.tsx b/packages/docusaurus/src/client/theme-fallback/Error/index.tsx index 3376d906eaee..513348cce4d7 100644 --- a/packages/docusaurus/src/client/theme-fallback/Error/index.tsx +++ b/packages/docusaurus/src/client/theme-fallback/Error/index.tsx @@ -9,10 +9,10 @@ /* eslint-disable @docusaurus/no-untranslated-text */ import React from 'react'; -import Layout from '@theme/Layout'; +import Head from '@docusaurus/Head'; import ErrorBoundary from '@docusaurus/ErrorBoundary'; +import Layout from '@theme/Layout'; import type {Props} from '@theme/Error'; -import Head from '@docusaurus/Head'; function ErrorDisplay({error, tryAgain}: Props): JSX.Element { return ( diff --git a/packages/docusaurus/src/client/theme-fallback/Loading/index.tsx b/packages/docusaurus/src/client/theme-fallback/Loading/index.tsx index 79a0823c3194..7d47419bb7b3 100644 --- a/packages/docusaurus/src/client/theme-fallback/Loading/index.tsx +++ b/packages/docusaurus/src/client/theme-fallback/Loading/index.tsx @@ -37,7 +37,7 @@ export default function Loading({ maxWidth: '50%', width: '100%', }}> - <p>{error.message}</p> + <p>{String(error)}</p> <div> <button type="button" onClick={retry}> Retry diff --git a/packages/docusaurus/src/client/theme-fallback/NotFound/index.tsx b/packages/docusaurus/src/client/theme-fallback/NotFound/index.tsx index 78f83dcc2c05..b7d5ea8b39ea 100644 --- a/packages/docusaurus/src/client/theme-fallback/NotFound/index.tsx +++ b/packages/docusaurus/src/client/theme-fallback/NotFound/index.tsx @@ -9,8 +9,8 @@ /* eslint-disable @docusaurus/no-untranslated-text */ import React from 'react'; -import Layout from '@theme/Layout'; import Head from '@docusaurus/Head'; +import Layout from '@theme/Layout'; export default function NotFound(): JSX.Element { return ( diff --git a/packages/docusaurus/src/commands/build.ts b/packages/docusaurus/src/commands/build.ts index 555cb76bd66b..d13d7039fec5 100644 --- a/packages/docusaurus/src/commands/build.ts +++ b/packages/docusaurus/src/commands/build.ts @@ -5,18 +5,17 @@ * LICENSE file in the root directory of this source tree. */ -import logger from '@docusaurus/logger'; -import CopyWebpackPlugin from 'copy-webpack-plugin'; import fs from 'fs-extra'; import path from 'path'; +import logger from '@docusaurus/logger'; +import {mapAsyncSequential} from '@docusaurus/utils'; +import CopyWebpackPlugin from 'copy-webpack-plugin'; import ReactLoadableSSRAddon from 'react-loadable-ssr-addon-v5-slorber'; -import type {Configuration} from 'webpack'; import {BundleAnalyzerPlugin} from 'webpack-bundle-analyzer'; import merge from 'webpack-merge'; import {load, loadContext, type LoadContextOptions} from '../server'; import {handleBrokenLinks} from '../server/brokenLinks'; -import type {Props} from '@docusaurus/types'; import createClientConfig from '../webpack/client'; import createServerConfig from '../webpack/server'; import { @@ -26,8 +25,9 @@ import { } from '../webpack/utils'; import CleanWebpackPlugin from '../webpack/plugins/CleanWebpackPlugin'; import {loadI18n} from '../server/i18n'; -import {mapAsyncSequential} from '@docusaurus/utils'; import type {HelmetServerState} from 'react-helmet-async'; +import type {Configuration} from 'webpack'; +import type {Props} from '@docusaurus/types'; export type BuildCLIOptions = Pick< LoadContextOptions, diff --git a/packages/docusaurus/src/commands/deploy.ts b/packages/docusaurus/src/commands/deploy.ts index 485c3940049d..e35783ddb745 100644 --- a/packages/docusaurus/src/commands/deploy.ts +++ b/packages/docusaurus/src/commands/deploy.ts @@ -6,13 +6,13 @@ */ import fs from 'fs-extra'; -import shell from 'shelljs'; +import path from 'path'; +import os from 'os'; import logger from '@docusaurus/logger'; +import shell from 'shelljs'; import {hasSSHProtocol, buildSshUrl, buildHttpsUrl} from '@docusaurus/utils'; import {loadContext, type LoadContextOptions} from '../server'; import {build} from './build'; -import path from 'path'; -import os from 'os'; export type DeployCLIOptions = Pick< LoadContextOptions, diff --git a/packages/docusaurus/src/commands/external.ts b/packages/docusaurus/src/commands/external.ts index eb8c1b94f26b..2a9f67ee288b 100644 --- a/packages/docusaurus/src/commands/external.ts +++ b/packages/docusaurus/src/commands/external.ts @@ -5,9 +5,9 @@ * LICENSE file in the root directory of this source tree. */ -import type {CommanderStatic} from 'commander'; import {loadContext} from '../server'; import {initPlugins} from '../server/plugins/init'; +import type {CommanderStatic} from 'commander'; export async function externalCommand( cli: CommanderStatic, diff --git a/packages/docusaurus/src/commands/serve.ts b/packages/docusaurus/src/commands/serve.ts index 044bd04ee684..da94dc86678d 100644 --- a/packages/docusaurus/src/commands/serve.ts +++ b/packages/docusaurus/src/commands/serve.ts @@ -6,14 +6,14 @@ */ import http from 'http'; -import serveHandler from 'serve-handler'; -import logger from '@docusaurus/logger'; import path from 'path'; -import type {LoadContextOptions} from '../server'; +import logger from '@docusaurus/logger'; +import {DEFAULT_BUILD_DIR_NAME} from '@docusaurus/utils'; +import serveHandler from 'serve-handler'; import {loadSiteConfig} from '../server/config'; import {build} from './build'; import {getHostPort, type HostPortOptions} from '../server/getHostPort'; -import {DEFAULT_BUILD_DIR_NAME} from '@docusaurus/utils'; +import type {LoadContextOptions} from '../server'; export type ServeCLIOptions = HostPortOptions & Pick<LoadContextOptions, 'config'> & { diff --git a/packages/docusaurus/src/commands/start.ts b/packages/docusaurus/src/commands/start.ts index 8dee7788911b..a0cae8416493 100644 --- a/packages/docusaurus/src/commands/start.ts +++ b/packages/docusaurus/src/commands/start.ts @@ -5,12 +5,12 @@ * LICENSE file in the root directory of this source tree. */ -import {normalizeUrl, posixPath} from '@docusaurus/utils'; +import path from 'path'; +import _ from 'lodash'; import logger from '@docusaurus/logger'; +import {normalizeUrl, posixPath} from '@docusaurus/utils'; import chokidar from 'chokidar'; import HtmlWebpackPlugin from 'html-webpack-plugin'; -import path from 'path'; -import _ from 'lodash'; import openBrowser from 'react-dev-utils/openBrowser'; import {prepareUrls} from 'react-dev-utils/WebpackDevServerUtils'; import evalSourceMapMiddleware from 'react-dev-utils/evalSourceMapMiddleware'; @@ -32,6 +32,7 @@ export type StartCLIOptions = HostPortOptions & hotOnly?: boolean; open?: boolean; poll?: boolean | number; + minify?: boolean; }; export async function start( @@ -77,7 +78,7 @@ export async function start( logger.success`Docusaurus website is running at url=${newOpenUrl}.`; } }) - .catch((err) => { + .catch((err: Error) => { logger.error(err.stack); }); }, 500); @@ -121,32 +122,35 @@ export async function start( fsWatcher.on(event, reload), ); - let config: webpack.Configuration = merge(await createClientConfig(props), { - watchOptions: { - ignored: /node_modules\/(?!@docusaurus)/, - poll: cliOptions.poll, - }, - infrastructureLogging: { - // Reduce log verbosity, see https://github.com/facebook/docusaurus/pull/5420#issuecomment-906613105 - level: 'warn', + let config: webpack.Configuration = merge( + await createClientConfig(props, cliOptions.minify), + { + watchOptions: { + ignored: /node_modules\/(?!@docusaurus)/, + poll: cliOptions.poll, + }, + infrastructureLogging: { + // Reduce log verbosity, see https://github.com/facebook/docusaurus/pull/5420#issuecomment-906613105 + level: 'warn', + }, + plugins: [ + // Generates an `index.html` file with the <script> injected. + new HtmlWebpackPlugin({ + template: path.join( + __dirname, + '../webpack/templates/index.html.template.ejs', + ), + // So we can define the position where the scripts are injected. + inject: false, + filename: 'index.html', + title: siteConfig.title, + headTags, + preBodyTags, + postBodyTags, + }), + ], }, - plugins: [ - // Generates an `index.html` file with the <script> injected. - new HtmlWebpackPlugin({ - template: path.join( - __dirname, - '../webpack/templates/index.html.template.ejs', - ), - // So we can define the position where the scripts are injected. - inject: false, - filename: 'index.html', - title: siteConfig.title, - headTags, - preBodyTags, - postBodyTags, - }), - ], - }); + ); // Plugin Lifecycle - configureWebpack and configurePostCss. plugins.forEach((plugin) => { diff --git a/packages/docusaurus/src/commands/swizzle/__tests__/__snapshots__/actions.test.ts.snap b/packages/docusaurus/src/commands/swizzle/__tests__/__snapshots__/actions.test.ts.snap index 3483ffb8a487..2608fd767172 100644 --- a/packages/docusaurus/src/commands/swizzle/__tests__/__snapshots__/actions.test.ts.snap +++ b/packages/docusaurus/src/commands/swizzle/__tests__/__snapshots__/actions.test.ts.snap @@ -44,8 +44,8 @@ export default function FirstLevelComponentWrapper(props) { exports[`wrap TypeScript wrap ComponentInFolder 2`] = ` "import React, {ComponentProps} from 'react'; -import type ComponentInFolderType from '@theme/ComponentInFolder'; import ComponentInFolder from '@theme-original/ComponentInFolder'; +import type ComponentInFolderType from '@theme/ComponentInFolder'; type Props = ComponentProps<typeof ComponentInFolderType>; @@ -61,8 +61,8 @@ export default function ComponentInFolderWrapper(props: Props): JSX.Element { exports[`wrap TypeScript wrap ComponentInFolder/ComponentInSubFolder 2`] = ` "import React, {ComponentProps} from 'react'; -import type ComponentInSubFolderType from '@theme/ComponentInFolder/ComponentInSubFolder'; import ComponentInSubFolder from '@theme-original/ComponentInFolder/ComponentInSubFolder'; +import type ComponentInSubFolderType from '@theme/ComponentInFolder/ComponentInSubFolder'; type Props = ComponentProps<typeof ComponentInSubFolderType>; @@ -78,8 +78,8 @@ export default function ComponentInSubFolderWrapper(props: Props): JSX.Element { exports[`wrap TypeScript wrap FirstLevelComponent 2`] = ` "import React, {ComponentProps} from 'react'; -import type FirstLevelComponentType from '@theme/FirstLevelComponent'; import FirstLevelComponent from '@theme-original/FirstLevelComponent'; +import type FirstLevelComponentType from '@theme/FirstLevelComponent'; type Props = ComponentProps<typeof FirstLevelComponentType>; diff --git a/packages/docusaurus/src/commands/swizzle/__tests__/__snapshots__/index.test.ts.snap b/packages/docusaurus/src/commands/swizzle/__tests__/__snapshots__/index.test.ts.snap index 84e98d772af6..a686e30fae35 100644 --- a/packages/docusaurus/src/commands/swizzle/__tests__/__snapshots__/index.test.ts.snap +++ b/packages/docusaurus/src/commands/swizzle/__tests__/__snapshots__/index.test.ts.snap @@ -274,8 +274,8 @@ exports[`swizzle wrap ComponentInFolder JS: theme dir tree 1`] = ` exports[`swizzle wrap ComponentInFolder TS: ComponentInFolder/index.tsx 1`] = ` "import React, {ComponentProps} from 'react'; -import type ComponentInFolderType from '@theme/ComponentInFolder'; import ComponentInFolder from '@theme-original/ComponentInFolder'; +import type ComponentInFolderType from '@theme/ComponentInFolder'; type Props = ComponentProps<typeof ComponentInFolderType>; @@ -318,8 +318,8 @@ exports[`swizzle wrap ComponentInFolder/ComponentInSubFolder JS: theme dir tree exports[`swizzle wrap ComponentInFolder/ComponentInSubFolder TS: ComponentInFolder/ComponentInSubFolder/index.tsx 1`] = ` "import React, {ComponentProps} from 'react'; -import type ComponentInSubFolderType from '@theme/ComponentInFolder/ComponentInSubFolder'; import ComponentInSubFolder from '@theme-original/ComponentInFolder/ComponentInSubFolder'; +import type ComponentInSubFolderType from '@theme/ComponentInFolder/ComponentInSubFolder'; type Props = ComponentProps<typeof ComponentInSubFolderType>; @@ -362,8 +362,8 @@ exports[`swizzle wrap ComponentInFolder/Sibling JS: theme dir tree 1`] = ` exports[`swizzle wrap ComponentInFolder/Sibling TS: ComponentInFolder/Sibling.tsx 1`] = ` "import React, {ComponentProps} from 'react'; -import type SiblingType from '@theme/ComponentInFolder/Sibling'; import Sibling from '@theme-original/ComponentInFolder/Sibling'; +import type SiblingType from '@theme/ComponentInFolder/Sibling'; type Props = ComponentProps<typeof SiblingType>; @@ -404,8 +404,8 @@ exports[`swizzle wrap FirstLevelComponent JS: theme dir tree 1`] = ` exports[`swizzle wrap FirstLevelComponent TS: FirstLevelComponent.tsx 1`] = ` "import React, {ComponentProps} from 'react'; -import type FirstLevelComponentType from '@theme/FirstLevelComponent'; import FirstLevelComponent from '@theme-original/FirstLevelComponent'; +import type FirstLevelComponentType from '@theme/FirstLevelComponent'; type Props = ComponentProps<typeof FirstLevelComponentType>; diff --git a/packages/docusaurus/src/commands/swizzle/__tests__/actions.test.ts b/packages/docusaurus/src/commands/swizzle/__tests__/actions.test.ts index d73521076160..d73280553085 100644 --- a/packages/docusaurus/src/commands/swizzle/__tests__/actions.test.ts +++ b/packages/docusaurus/src/commands/swizzle/__tests__/actions.test.ts @@ -7,11 +7,11 @@ import path from 'path'; import fs from 'fs-extra'; -import {ThemePath, Components, createTempSiteDir} from './testUtils'; -import type {SwizzleAction} from '@docusaurus/types'; import tree from 'tree-node-cli'; -import {eject, wrap} from '../actions'; import {posixPath} from '@docusaurus/utils'; +import {eject, wrap} from '../actions'; +import {ThemePath, Components, createTempSiteDir} from './testUtils'; +import type {SwizzleAction} from '@docusaurus/types'; // Use relative paths and sort files for tests function stableCreatedFiles( diff --git a/packages/docusaurus/src/commands/swizzle/__tests__/components.test.ts b/packages/docusaurus/src/commands/swizzle/__tests__/components.test.ts index eb0b28445708..c16a7a0d619a 100644 --- a/packages/docusaurus/src/commands/swizzle/__tests__/components.test.ts +++ b/packages/docusaurus/src/commands/swizzle/__tests__/components.test.ts @@ -7,8 +7,8 @@ import path from 'path'; import {getThemeComponents, readComponentNames} from '../components'; -import type {SwizzleConfig} from '@docusaurus/types'; import {Components} from './testUtils'; +import type {SwizzleConfig} from '@docusaurus/types'; const FixtureThemePath = path.join(__dirname, '__fixtures__/theme'); diff --git a/packages/docusaurus/src/commands/swizzle/__tests__/config.test.ts b/packages/docusaurus/src/commands/swizzle/__tests__/config.test.ts index 7dd867a08270..cb924a626ffc 100644 --- a/packages/docusaurus/src/commands/swizzle/__tests__/config.test.ts +++ b/packages/docusaurus/src/commands/swizzle/__tests__/config.test.ts @@ -5,8 +5,8 @@ * LICENSE file in the root directory of this source tree. */ -import type {SwizzleConfig} from '@docusaurus/types'; import {normalizeSwizzleConfig} from '../config'; +import type {SwizzleConfig} from '@docusaurus/types'; describe('normalizeSwizzleConfig', () => { it(`validate no components config`, async () => { diff --git a/packages/docusaurus/src/commands/swizzle/__tests__/index.test.ts b/packages/docusaurus/src/commands/swizzle/__tests__/index.test.ts index 0f55edac837d..c2317cb41c22 100644 --- a/packages/docusaurus/src/commands/swizzle/__tests__/index.test.ts +++ b/packages/docusaurus/src/commands/swizzle/__tests__/index.test.ts @@ -8,10 +8,10 @@ import {jest} from '@jest/globals'; import path from 'path'; import fs from 'fs-extra'; -import {ThemePath, createTempSiteDir, Components} from './testUtils'; import tree from 'tree-node-cli'; -import {swizzle} from '../index'; import {escapePath, Globby, posixPath} from '@docusaurus/utils'; +import {ThemePath, createTempSiteDir, Components} from './testUtils'; +import {swizzle} from '../index'; const FixtureThemeName = 'fixture-theme-name'; diff --git a/packages/docusaurus/src/commands/swizzle/actions.ts b/packages/docusaurus/src/commands/swizzle/actions.ts index d6be9f902731..e295f8c2bd2d 100644 --- a/packages/docusaurus/src/commands/swizzle/actions.ts +++ b/packages/docusaurus/src/commands/swizzle/actions.ts @@ -5,14 +5,14 @@ * LICENSE file in the root directory of this source tree. */ -import logger from '@docusaurus/logger'; import fs from 'fs-extra'; import path from 'path'; import _ from 'lodash'; +import logger from '@docusaurus/logger'; import {Globby, posixPath, THEME_PATH} from '@docusaurus/utils'; +import {askSwizzleAction} from './prompts'; import type {SwizzleAction, SwizzleComponentConfig} from '@docusaurus/types'; import type {SwizzleCLIOptions} from './common'; -import {askSwizzleAction} from './prompts'; export const SwizzleActions: SwizzleAction[] = ['wrap', 'eject']; @@ -122,8 +122,8 @@ export async function wrap({ const content = typescript ? `import React, {ComponentProps} from 'react'; -import type ${componentName}Type from '@theme/${themeComponentName}'; import ${componentName} from '@theme-${importType}/${themeComponentName}'; +import type ${componentName}Type from '@theme/${themeComponentName}'; type Props = ComponentProps<typeof ${componentName}Type>; diff --git a/packages/docusaurus/src/commands/swizzle/common.ts b/packages/docusaurus/src/commands/swizzle/common.ts index 4fdf01e4f2a0..fad472d6b140 100644 --- a/packages/docusaurus/src/commands/swizzle/common.ts +++ b/packages/docusaurus/src/commands/swizzle/common.ts @@ -5,9 +5,9 @@ * LICENSE file in the root directory of this source tree. */ -import leven from 'leven'; import _ from 'lodash'; import logger from '@docusaurus/logger'; +import leven from 'leven'; import type {NormalizedPluginConfig} from '../../server/plugins/configs'; import type { InitializedPlugin, diff --git a/packages/docusaurus/src/commands/swizzle/components.ts b/packages/docusaurus/src/commands/swizzle/components.ts index f9dc0d7beb81..9475ce33dbc9 100644 --- a/packages/docusaurus/src/commands/swizzle/components.ts +++ b/packages/docusaurus/src/commands/swizzle/components.ts @@ -5,21 +5,21 @@ * LICENSE file in the root directory of this source tree. */ -import logger from '@docusaurus/logger'; import fs from 'fs-extra'; import path from 'path'; import _ from 'lodash'; +import logger from '@docusaurus/logger'; +import {posixPath} from '@docusaurus/utils'; +import {askComponentName} from './prompts'; +import {findClosestValue, findStringIgnoringCase} from './common'; +import {helpTables, themeComponentsTable} from './tables'; +import {SwizzleActions} from './actions'; import type { SwizzleAction, SwizzleActionStatus, SwizzleComponentConfig, SwizzleConfig, } from '@docusaurus/types'; -import {posixPath} from '@docusaurus/utils'; -import {askComponentName} from './prompts'; -import {findClosestValue, findStringIgnoringCase} from './common'; -import {helpTables, themeComponentsTable} from './tables'; -import {SwizzleActions} from './actions'; export type ThemeComponents = { themeName: string; diff --git a/packages/docusaurus/src/commands/swizzle/config.ts b/packages/docusaurus/src/commands/swizzle/config.ts index f62b0ad7959e..83f0bbe75101 100644 --- a/packages/docusaurus/src/commands/swizzle/config.ts +++ b/packages/docusaurus/src/commands/swizzle/config.ts @@ -5,12 +5,12 @@ * LICENSE file in the root directory of this source tree. */ +import logger from '@docusaurus/logger'; import {Joi} from '@docusaurus/utils-validation'; -import type {SwizzleComponentConfig, SwizzleConfig} from '@docusaurus/types'; -import type {SwizzlePlugin} from './common'; import {SwizzleActions, SwizzleActionsStatuses} from './common'; import {getPluginByThemeName} from './themes'; -import logger from '@docusaurus/logger'; +import type {SwizzleComponentConfig, SwizzleConfig} from '@docusaurus/types'; +import type {SwizzlePlugin} from './common'; function getModuleSwizzleConfig( swizzlePlugin: SwizzlePlugin, diff --git a/packages/docusaurus/src/commands/swizzle/index.ts b/packages/docusaurus/src/commands/swizzle/index.ts index 0d13d7387aab..9262e7d154f1 100644 --- a/packages/docusaurus/src/commands/swizzle/index.ts +++ b/packages/docusaurus/src/commands/swizzle/index.ts @@ -9,14 +9,14 @@ import logger from '@docusaurus/logger'; import {getThemeName, getThemePath, getThemeNames} from './themes'; import {getThemeComponents, getComponentName} from './components'; import {helpTables, themeComponentsTable} from './tables'; -import type {SwizzleAction, SwizzleComponentConfig} from '@docusaurus/types'; -import type {SwizzleCLIOptions, SwizzlePlugin} from './common'; import {normalizeOptions} from './common'; -import type {ActionResult} from './actions'; import {eject, getAction, wrap} from './actions'; import {getThemeSwizzleConfig} from './config'; import {askSwizzleDangerousComponent} from './prompts'; import {initSwizzleContext} from './context'; +import type {SwizzleAction, SwizzleComponentConfig} from '@docusaurus/types'; +import type {SwizzleCLIOptions, SwizzlePlugin} from './common'; +import type {ActionResult} from './actions'; async function listAllThemeComponents({ themeNames, diff --git a/packages/docusaurus/src/commands/swizzle/prompts.ts b/packages/docusaurus/src/commands/swizzle/prompts.ts index fb6ab4f13db9..35d85e33875d 100644 --- a/packages/docusaurus/src/commands/swizzle/prompts.ts +++ b/packages/docusaurus/src/commands/swizzle/prompts.ts @@ -7,21 +7,21 @@ import logger from '@docusaurus/logger'; import prompts from 'prompts'; +import {actionStatusSuffix, PartiallySafeHint} from './common'; import type {ThemeComponents} from './components'; import type {SwizzleAction, SwizzleComponentConfig} from '@docusaurus/types'; -import {actionStatusSuffix, PartiallySafeHint} from './common'; const ExitTitle = logger.yellow('[Exit]'); export async function askThemeName(themeNames: string[]): Promise<string> { - const {themeName} = await prompts({ + const {themeName} = (await prompts({ type: 'select', name: 'themeName', message: 'Select a theme to swizzle:', choices: themeNames .map((theme) => ({title: theme, value: theme})) .concat({title: ExitTitle, value: '[Exit]'}), - }); + })) as {themeName?: string}; if (!themeName || themeName === '[Exit]') { process.exit(0); } @@ -41,7 +41,7 @@ export async function askComponentName( })}`; } - const {componentName} = await prompts({ + const {componentName} = (await prompts({ type: 'autocomplete', name: 'componentName', message: ` @@ -58,12 +58,12 @@ ${PartiallySafeHint} = not safe for all swizzle actions value: compName, })) .concat({title: ExitTitle, value: '[Exit]'}), - async suggest(input, choices) { + async suggest(input: string, choices) { return choices.filter((choice) => choice.title.toLowerCase().includes(input.toLowerCase()), ); }, - }); + })) as {componentName?: string}; logger.newLine(); if (!componentName || componentName === '[Exit]') { @@ -74,7 +74,7 @@ ${PartiallySafeHint} = not safe for all swizzle actions } export async function askSwizzleDangerousComponent(): Promise<boolean> { - const {switchToDanger} = await prompts({ + const {switchToDanger} = (await prompts({ type: 'select', name: 'switchToDanger', message: `Do you really want to swizzle this unsafe internal component?`, @@ -86,7 +86,7 @@ export async function askSwizzleDangerousComponent(): Promise<boolean> { }, {title: ExitTitle, value: '[Exit]'}, ], - }); + })) as {switchToDanger?: boolean | '[Exit]'}; if (typeof switchToDanger === 'undefined' || switchToDanger === '[Exit]') { return process.exit(0); @@ -98,7 +98,7 @@ export async function askSwizzleDangerousComponent(): Promise<boolean> { export async function askSwizzleAction( componentConfig: SwizzleComponentConfig, ): Promise<SwizzleAction> { - const {action} = await prompts({ + const {action} = (await prompts({ type: 'select', name: 'action', message: `Which swizzle action do you want to do?`, @@ -117,7 +117,7 @@ export async function askSwizzleAction( }, {title: ExitTitle, value: '[Exit]'}, ], - }); + })) as {action?: SwizzleAction | '[Exit]'}; if (typeof action === 'undefined' || action === '[Exit]') { return process.exit(0); diff --git a/packages/docusaurus/src/commands/swizzle/tables.ts b/packages/docusaurus/src/commands/swizzle/tables.ts index 28b9b5188b42..73ccf077d865 100644 --- a/packages/docusaurus/src/commands/swizzle/tables.ts +++ b/packages/docusaurus/src/commands/swizzle/tables.ts @@ -5,13 +5,13 @@ * LICENSE file in the root directory of this source tree. */ +import _ from 'lodash'; import logger from '@docusaurus/logger'; import Table from 'cli-table3'; -import _ from 'lodash'; -import type {ThemeComponents} from './components'; import {SwizzleActions} from './actions'; -import type {SwizzleActionStatus} from '@docusaurus/types'; import {actionStatusColor, actionStatusLabel} from './common'; +import type {SwizzleActionStatus} from '@docusaurus/types'; +import type {ThemeComponents} from './components'; function tableStatusLabel(status: SwizzleActionStatus): string { return actionStatusColor(status, actionStatusLabel(status)); diff --git a/packages/docusaurus/src/commands/swizzle/themes.ts b/packages/docusaurus/src/commands/swizzle/themes.ts index 49381089dd18..c31b0f28dd8b 100644 --- a/packages/docusaurus/src/commands/swizzle/themes.ts +++ b/packages/docusaurus/src/commands/swizzle/themes.ts @@ -5,10 +5,10 @@ * LICENSE file in the root directory of this source tree. */ -import logger from '@docusaurus/logger'; import path from 'path'; -import leven from 'leven'; import _ from 'lodash'; +import logger from '@docusaurus/logger'; +import leven from 'leven'; import {askThemeName} from './prompts'; import {findStringIgnoringCase, type SwizzlePlugin} from './common'; diff --git a/packages/docusaurus/src/commands/writeTranslations.ts b/packages/docusaurus/src/commands/writeTranslations.ts index 606c8447d698..14ae1e64adc6 100644 --- a/packages/docusaurus/src/commands/writeTranslations.ts +++ b/packages/docusaurus/src/commands/writeTranslations.ts @@ -5,11 +5,9 @@ * LICENSE file in the root directory of this source tree. */ -import type {InitializedPlugin} from '@docusaurus/types'; import path from 'path'; import {loadContext, type LoadContextOptions} from '../server'; import {initPlugins} from '../server/plugins/init'; - import { writePluginTranslations, writeCodeTranslations, @@ -22,6 +20,7 @@ import { globSourceCodeFilePaths, } from '../server/translations/translationsExtractor'; import {getCustomBabelConfigFilePath, getBabelOptions} from '../webpack/utils'; +import type {InitializedPlugin} from '@docusaurus/types'; export type WriteTranslationsCLIOptions = Pick< LoadContextOptions, diff --git a/packages/docusaurus/src/server/__tests__/siteMetadata.test.ts b/packages/docusaurus/src/server/__tests__/siteMetadata.test.ts index d33e301382be..30a40bb7521d 100644 --- a/packages/docusaurus/src/server/__tests__/siteMetadata.test.ts +++ b/packages/docusaurus/src/server/__tests__/siteMetadata.test.ts @@ -6,8 +6,8 @@ */ import {jest} from '@jest/globals'; -import {getPluginVersion, loadSiteMetadata} from '../siteMetadata'; import path from 'path'; +import {getPluginVersion, loadSiteMetadata} from '../siteMetadata'; describe('getPluginVersion', () => { it('detects external packages plugins versions', async () => { diff --git a/packages/docusaurus/src/server/__tests__/utils.test.ts b/packages/docusaurus/src/server/__tests__/utils.test.ts index b8ef5b59faaa..646657350522 100644 --- a/packages/docusaurus/src/server/__tests__/utils.test.ts +++ b/packages/docusaurus/src/server/__tests__/utils.test.ts @@ -5,8 +5,8 @@ * LICENSE file in the root directory of this source tree. */ -import type {RouteConfig} from '@docusaurus/types'; import {getAllFinalRoutes} from '../utils'; +import type {RouteConfig} from '@docusaurus/types'; describe('getAllFinalRoutes', () => { it('gets final routes correctly', () => { diff --git a/packages/docusaurus/src/server/brokenLinks.ts b/packages/docusaurus/src/server/brokenLinks.ts index 4ce32b2deaf5..22f466772de5 100644 --- a/packages/docusaurus/src/server/brokenLinks.ts +++ b/packages/docusaurus/src/server/brokenLinks.ts @@ -5,10 +5,12 @@ * LICENSE file in the root directory of this source tree. */ -import {matchRoutes} from 'react-router-config'; import fs from 'fs-extra'; +import path from 'path'; import _ from 'lodash'; -import type {RouteConfig, ReportingSeverity} from '@docusaurus/types'; +import logger from '@docusaurus/logger'; +import combinePromises from 'combine-promises'; +import {matchRoutes} from 'react-router-config'; import { removePrefix, removeSuffix, @@ -16,9 +18,7 @@ import { resolvePathname, } from '@docusaurus/utils'; import {getAllFinalRoutes} from './utils'; -import path from 'path'; -import combinePromises from 'combine-promises'; -import logger from '@docusaurus/logger'; +import type {RouteConfig, ReportingSeverity} from '@docusaurus/types'; type BrokenLink = { link: string; diff --git a/packages/docusaurus/src/server/config.ts b/packages/docusaurus/src/server/config.ts index 84b4975f1249..73cccc613654 100644 --- a/packages/docusaurus/src/server/config.ts +++ b/packages/docusaurus/src/server/config.ts @@ -9,8 +9,8 @@ import path from 'path'; import fs from 'fs-extra'; import importFresh from 'import-fresh'; import {DEFAULT_CONFIG_FILE_NAME} from '@docusaurus/utils'; -import type {LoadContext} from '@docusaurus/types'; import {validateConfig} from './configValidation'; +import type {LoadContext} from '@docusaurus/types'; export async function loadSiteConfig({ siteDir, @@ -30,7 +30,7 @@ export async function loadSiteConfig({ const importedConfig = importFresh(siteConfigPath); - const loadedConfig = + const loadedConfig: unknown = typeof importedConfig === 'function' ? await importedConfig() : await importedConfig; diff --git a/packages/docusaurus/src/server/configValidation.ts b/packages/docusaurus/src/server/configValidation.ts index f8a0985903a8..2820e4b44dc3 100644 --- a/packages/docusaurus/src/server/configValidation.ts +++ b/packages/docusaurus/src/server/configValidation.ts @@ -5,12 +5,12 @@ * LICENSE file in the root directory of this source tree. */ -import type {DocusaurusConfig, I18nConfig} from '@docusaurus/types'; import { DEFAULT_CONFIG_FILE_NAME, DEFAULT_STATIC_DIR_NAME, } from '@docusaurus/utils'; import {Joi, URISchema, printWarning} from '@docusaurus/utils-validation'; +import type {DocusaurusConfig, I18nConfig} from '@docusaurus/types'; const DEFAULT_I18N_LOCALE = 'en'; @@ -144,9 +144,9 @@ const I18N_CONFIG_SCHEMA = Joi.object<I18nConfig>({ .optional() .default(DEFAULT_I18N_CONFIG); -const SiteUrlSchema = URISchema.required().custom((value, helpers) => { +const SiteUrlSchema = URISchema.required().custom((value: unknown, helpers) => { try { - const {pathname} = new URL(value); + const {pathname} = new URL(String(value)); if (pathname !== '/') { helpers.warn('docusaurus.configValidationWarning', { warningMessage: `the url is not supposed to contain a sub-path like '${pathname}', please use the baseUrl field for sub-paths`, @@ -157,7 +157,7 @@ const SiteUrlSchema = URISchema.required().custom((value, helpers) => { }, 'siteUrlCustomValidation'); // TODO move to @docusaurus/utils-validation -export const ConfigSchema = Joi.object({ +export const ConfigSchema = Joi.object<DocusaurusConfig>({ baseUrl: Joi.string() .required() .regex(/\/$/m) @@ -237,9 +237,7 @@ export const ConfigSchema = Joi.object({ }); // TODO move to @docusaurus/utils-validation -export function validateConfig( - config: Partial<DocusaurusConfig>, -): DocusaurusConfig { +export function validateConfig(config: unknown): DocusaurusConfig { const {error, warning, value} = ConfigSchema.validate(config, { abortEarly: false, }); diff --git a/packages/docusaurus/src/server/getHostPort.ts b/packages/docusaurus/src/server/getHostPort.ts index c9792a45ec65..4ae80708704f 100644 --- a/packages/docusaurus/src/server/getHostPort.ts +++ b/packages/docusaurus/src/server/getHostPort.ts @@ -6,8 +6,8 @@ */ import {execSync, type ExecSyncOptionsWithStringEncoding} from 'child_process'; -import detect from 'detect-port'; import logger from '@docusaurus/logger'; +import detect from 'detect-port'; import {DEFAULT_PORT} from '@docusaurus/utils'; import prompts from 'prompts'; @@ -70,7 +70,7 @@ async function choosePort( } clearConsole(); const existingProcess = getProcessForPort(defaultPort); - const {shouldChangePort} = await prompts({ + const {shouldChangePort} = (await prompts({ type: 'confirm', name: 'shouldChangePort', message: logger.yellow(`${logger.bold('[WARNING]')} ${message}${ @@ -79,7 +79,7 @@ async function choosePort( Would you like to run the app on another port instead?`), initial: true, - }); + })) as {shouldChangePort: boolean}; return shouldChangePort ? port : null; } catch (err) { logger.error`Could not find an open port at ${host}.`; diff --git a/packages/docusaurus/src/server/htmlTags.ts b/packages/docusaurus/src/server/htmlTags.ts index c1e67b23c191..81cce416352a 100644 --- a/packages/docusaurus/src/server/htmlTags.ts +++ b/packages/docusaurus/src/server/htmlTags.ts @@ -5,10 +5,10 @@ * LICENSE file in the root directory of this source tree. */ +import _ from 'lodash'; import htmlTags from 'html-tags'; import voidHtmlTags from 'html-tags/void'; import escapeHTML from 'escape-html'; -import _ from 'lodash'; import type { Props, HtmlTagObject, diff --git a/packages/docusaurus/src/server/i18n.ts b/packages/docusaurus/src/server/i18n.ts index 57f639c14098..cd9bbe4990ea 100644 --- a/packages/docusaurus/src/server/i18n.ts +++ b/packages/docusaurus/src/server/i18n.ts @@ -5,8 +5,8 @@ * LICENSE file in the root directory of this source tree. */ -import {getLangDir} from 'rtl-detect'; import logger from '@docusaurus/logger'; +import {getLangDir} from 'rtl-detect'; import type {I18n, DocusaurusConfig, I18nLocaleConfig} from '@docusaurus/types'; import type {LoadContextOptions} from './index'; diff --git a/packages/docusaurus/src/server/index.ts b/packages/docusaurus/src/server/index.ts index 55b2466d11c9..4417f0f7f515 100644 --- a/packages/docusaurus/src/server/index.ts +++ b/packages/docusaurus/src/server/index.ts @@ -5,6 +5,8 @@ * LICENSE file in the root directory of this source tree. */ +import path from 'path'; +import _ from 'lodash'; import { generate, escapePath, @@ -13,8 +15,6 @@ import { DEFAULT_CONFIG_FILE_NAME, GENERATED_FILES_DIR_NAME, } from '@docusaurus/utils'; -import _ from 'lodash'; -import path from 'path'; import {loadSiteConfig} from './config'; import {loadClientModules} from './clientModules'; import {loadPlugins} from './plugins'; diff --git a/packages/docusaurus/src/server/plugins/__tests__/pluginIds.test.ts b/packages/docusaurus/src/server/plugins/__tests__/pluginIds.test.ts index 0c04a3fc03bd..a6315f59a813 100644 --- a/packages/docusaurus/src/server/plugins/__tests__/pluginIds.test.ts +++ b/packages/docusaurus/src/server/plugins/__tests__/pluginIds.test.ts @@ -5,8 +5,8 @@ * LICENSE file in the root directory of this source tree. */ -import type {InitializedPlugin} from '@docusaurus/types'; import {ensureUniquePluginInstanceIds} from '../pluginIds'; +import type {InitializedPlugin} from '@docusaurus/types'; function createTestPlugin(name: string, id?: string): InitializedPlugin { // @ts-expect-error: good enough for tests diff --git a/packages/docusaurus/src/server/plugins/index.ts b/packages/docusaurus/src/server/plugins/index.ts index 93553d18202d..812ea7b2e80e 100644 --- a/packages/docusaurus/src/server/plugins/index.ts +++ b/packages/docusaurus/src/server/plugins/index.ts @@ -5,8 +5,13 @@ * LICENSE file in the root directory of this source tree. */ -import {docuHash, generate} from '@docusaurus/utils'; import path from 'path'; +import _ from 'lodash'; +import {docuHash, generate} from '@docusaurus/utils'; +import {initPlugins} from './init'; +import {createBootstrapPlugin, createMDXFallbackPlugin} from './synthetic'; +import {localizePluginTranslationFile} from '../translations/translations'; +import {applyRouteTrailingSlash, sortConfig} from './routeConfig'; import type { LoadContext, PluginContentLoadedActions, @@ -17,11 +22,6 @@ import type { InitializedPlugin, PluginRouteContext, } from '@docusaurus/types'; -import {initPlugins} from './init'; -import {createBootstrapPlugin, createMDXFallbackPlugin} from './synthetic'; -import _ from 'lodash'; -import {localizePluginTranslationFile} from '../translations/translations'; -import {applyRouteTrailingSlash, sortConfig} from './routeConfig'; /** * Initializes the plugins, runs `loadContent`, `translateContent`, diff --git a/packages/docusaurus/src/server/plugins/init.ts b/packages/docusaurus/src/server/plugins/init.ts index 4bc0aa92da42..771a407cccb5 100644 --- a/packages/docusaurus/src/server/plugins/init.ts +++ b/packages/docusaurus/src/server/plugins/init.ts @@ -7,6 +7,14 @@ import {createRequire} from 'module'; import path from 'path'; +import {DEFAULT_PLUGIN_ID} from '@docusaurus/utils'; +import { + normalizePluginOptions, + normalizeThemeConfig, +} from '@docusaurus/utils-validation'; +import {getPluginVersion} from '../siteMetadata'; +import {ensureUniquePluginInstanceIds} from './pluginIds'; +import {loadPluginConfigs, type NormalizedPluginConfig} from './configs'; import type { PluginVersionInformation, LoadContext, @@ -14,14 +22,6 @@ import type { PluginOptions, InitializedPlugin, } from '@docusaurus/types'; -import {DEFAULT_PLUGIN_ID} from '@docusaurus/utils'; -import {getPluginVersion} from '../siteMetadata'; -import {ensureUniquePluginInstanceIds} from './pluginIds'; -import { - normalizePluginOptions, - normalizeThemeConfig, -} from '@docusaurus/utils-validation'; -import {loadPluginConfigs, type NormalizedPluginConfig} from './configs'; function getOptionValidationFunction( normalizedPluginConfig: NormalizedPluginConfig, diff --git a/packages/docusaurus/src/server/plugins/presets.ts b/packages/docusaurus/src/server/plugins/presets.ts index b45b06915b21..04b73357f38f 100644 --- a/packages/docusaurus/src/server/plugins/presets.ts +++ b/packages/docusaurus/src/server/plugins/presets.ts @@ -7,13 +7,13 @@ import {createRequire} from 'module'; import importFresh from 'import-fresh'; +import {resolveModuleName} from './moduleShorthand'; import type { LoadContext, PluginConfig, PresetModule, DocusaurusConfig, } from '@docusaurus/types'; -import {resolveModuleName} from './moduleShorthand'; type ImportedPresetModule = PresetModule & {default?: PresetModule}; diff --git a/packages/docusaurus/src/server/plugins/routeConfig.ts b/packages/docusaurus/src/server/plugins/routeConfig.ts index e5664dd1693f..e9b7c589408f 100644 --- a/packages/docusaurus/src/server/plugins/routeConfig.ts +++ b/packages/docusaurus/src/server/plugins/routeConfig.ts @@ -5,11 +5,11 @@ * LICENSE file in the root directory of this source tree. */ -import type {RouteConfig} from '@docusaurus/types'; import { applyTrailingSlash, type ApplyTrailingSlashParams, } from '@docusaurus/utils-common'; +import type {RouteConfig} from '@docusaurus/types'; /** Recursively applies trailing slash config to all nested routes. */ export function applyRouteTrailingSlash( diff --git a/packages/docusaurus/src/server/routes.ts b/packages/docusaurus/src/server/routes.ts index 87cfedf87a82..ab97b1a7b9d7 100644 --- a/packages/docusaurus/src/server/routes.ts +++ b/packages/docusaurus/src/server/routes.ts @@ -5,6 +5,8 @@ * LICENSE file in the root directory of this source tree. */ +import query from 'querystring'; +import _ from 'lodash'; import { docuHash, normalizeUrl, @@ -12,8 +14,6 @@ import { escapePath, reportMessage, } from '@docusaurus/utils'; -import _ from 'lodash'; -import query from 'querystring'; import {getAllFinalRoutes} from './utils'; import type { Module, diff --git a/packages/docusaurus/src/server/siteMetadata.ts b/packages/docusaurus/src/server/siteMetadata.ts index bde32ad967c3..affcbf7183ec 100644 --- a/packages/docusaurus/src/server/siteMetadata.ts +++ b/packages/docusaurus/src/server/siteMetadata.ts @@ -5,22 +5,22 @@ * LICENSE file in the root directory of this source tree. */ +import fs from 'fs-extra'; +import path from 'path'; +import logger from '@docusaurus/logger'; +import {DOCUSAURUS_VERSION} from '@docusaurus/utils'; import type { LoadedPlugin, PluginVersionInformation, SiteMetadata, } from '@docusaurus/types'; -import {DOCUSAURUS_VERSION} from '@docusaurus/utils'; -import fs from 'fs-extra'; -import path from 'path'; -import logger from '@docusaurus/logger'; async function getPackageJsonVersion( packageJsonPath: string, ): Promise<string | undefined> { if (await fs.pathExists(packageJsonPath)) { // eslint-disable-next-line @typescript-eslint/no-var-requires, import/no-dynamic-require, global-require - return require(packageJsonPath).version; + return (require(packageJsonPath) as {version?: string}).version; } return undefined; } @@ -29,7 +29,7 @@ async function getPackageJsonName( packageJsonPath: string, ): Promise<string | undefined> { // eslint-disable-next-line @typescript-eslint/no-var-requires, import/no-dynamic-require, global-require - return require(packageJsonPath).name; + return (require(packageJsonPath) as {name?: string}).name; } export async function getPluginVersion( diff --git a/packages/docusaurus/src/server/translations/__tests__/translations.test.ts b/packages/docusaurus/src/server/translations/__tests__/translations.test.ts index 89240e3ea05e..f34318cd4707 100644 --- a/packages/docusaurus/src/server/translations/__tests__/translations.test.ts +++ b/packages/docusaurus/src/server/translations/__tests__/translations.test.ts @@ -6,6 +6,9 @@ */ import {jest} from '@jest/globals'; +import fs from 'fs-extra'; +import path from 'path'; +import tmp from 'tmp-promise'; import { writePluginTranslations, writeCodeTranslations, @@ -15,14 +18,11 @@ import { getPluginsDefaultCodeTranslationMessages, applyDefaultCodeTranslations, } from '../translations'; -import fs from 'fs-extra'; -import tmp from 'tmp-promise'; import type { InitializedPlugin, TranslationFile, TranslationFileContent, } from '@docusaurus/types'; -import path from 'path'; async function createTmpSiteDir() { const {path: siteDirPath} = await tmp.dir({ diff --git a/packages/docusaurus/src/server/translations/__tests__/translationsExtractor.test.ts b/packages/docusaurus/src/server/translations/__tests__/translationsExtractor.test.ts index 5b80021d7043..e06bc5f57d1f 100644 --- a/packages/docusaurus/src/server/translations/__tests__/translationsExtractor.test.ts +++ b/packages/docusaurus/src/server/translations/__tests__/translationsExtractor.test.ts @@ -6,16 +6,16 @@ */ import {jest} from '@jest/globals'; +import path from 'path'; import fs from 'fs-extra'; import tmp from 'tmp-promise'; +import {SRC_DIR_NAME} from '@docusaurus/utils'; import { extractSourceCodeFileTranslations, extractSiteSourceCodeTranslations, } from '../translationsExtractor'; import {getBabelOptions} from '../../../webpack/utils'; -import path from 'path'; import type {InitializedPlugin} from '@docusaurus/types'; -import {SRC_DIR_NAME} from '@docusaurus/utils'; const TestBabelOptions = getBabelOptions({ isServer: true, diff --git a/packages/docusaurus/src/server/translations/translations.ts b/packages/docusaurus/src/server/translations/translations.ts index 3e768b8a9041..fd3fb0305523 100644 --- a/packages/docusaurus/src/server/translations/translations.ts +++ b/packages/docusaurus/src/server/translations/translations.ts @@ -8,6 +8,7 @@ import path from 'path'; import fs from 'fs-extra'; import _ from 'lodash'; +import logger from '@docusaurus/logger'; import { getPluginI18nPath, toMessageRelativeFilePath, @@ -15,7 +16,6 @@ import { CODE_TRANSLATIONS_FILE_NAME, } from '@docusaurus/utils'; import {Joi} from '@docusaurus/utils-validation'; -import logger from '@docusaurus/logger'; import type { TranslationFileContent, TranslationFile, @@ -58,7 +58,7 @@ async function readTranslationFileContent( ): Promise<TranslationFileContent | undefined> { if (await fs.pathExists(filePath)) { try { - const content = await fs.readJSON(filePath); + const content: unknown = await fs.readJSON(filePath); ensureTranslationFileContent(content); return content; } catch (err) { diff --git a/packages/docusaurus/src/server/translations/translationsExtractor.ts b/packages/docusaurus/src/server/translations/translationsExtractor.ts index 73a1a0cbfe7c..6113b23ba933 100644 --- a/packages/docusaurus/src/server/translations/translationsExtractor.ts +++ b/packages/docusaurus/src/server/translations/translationsExtractor.ts @@ -5,23 +5,23 @@ * LICENSE file in the root directory of this source tree. */ +import nodePath from 'path'; import fs from 'fs-extra'; +import logger from '@docusaurus/logger'; import traverse, {type Node} from '@babel/traverse'; import generate from '@babel/generator'; -import logger from '@docusaurus/logger'; import { parse, type types as t, type NodePath, type TransformOptions, } from '@babel/core'; +import {SRC_DIR_NAME} from '@docusaurus/utils'; +import {safeGlobby} from '../utils'; import type { InitializedPlugin, TranslationFileContent, } from '@docusaurus/types'; -import nodePath from 'path'; -import {SRC_DIR_NAME} from '@docusaurus/utils'; -import {safeGlobby} from '../utils'; // We only support extracting source code translations from these kind of files const TranslatableSourceCodeExtension = new Set([ @@ -347,10 +347,12 @@ ${sourceWarningPart(path.node)}`, firstArgEvaluated.confident && typeof firstArgEvaluated.value === 'object' ) { - const {message, id, description} = firstArgEvaluated.value; - translations[id ?? message] = { - message: message ?? id, - ...(description && {description}), + const {message, id, description} = firstArgEvaluated.value as { + [propName: string]: unknown; + }; + translations[String(id ?? message)] = { + message: String(message ?? id), + ...(Boolean(description) && {description: String(description)}), }; } else { warnings.push( diff --git a/packages/docusaurus/src/server/utils.ts b/packages/docusaurus/src/server/utils.ts index e4e22df7d9da..e0e67454c7ea 100644 --- a/packages/docusaurus/src/server/utils.ts +++ b/packages/docusaurus/src/server/utils.ts @@ -5,9 +5,9 @@ * LICENSE file in the root directory of this source tree. */ -import type {RouteConfig} from '@docusaurus/types'; import path from 'path'; import {posixPath, Globby} from '@docusaurus/utils'; +import type {RouteConfig} from '@docusaurus/types'; // Recursively get the final routes (routes with no subroutes) export function getAllFinalRoutes(routeConfig: RouteConfig[]): RouteConfig[] { diff --git a/packages/docusaurus/src/webpack/__tests__/base.test.ts b/packages/docusaurus/src/webpack/__tests__/base.test.ts index 93b1de8c19d8..3e39adfda435 100644 --- a/packages/docusaurus/src/webpack/__tests__/base.test.ts +++ b/packages/docusaurus/src/webpack/__tests__/base.test.ts @@ -7,11 +7,10 @@ import {jest} from '@jest/globals'; import path from 'path'; - -import {excludeJS, clientDir, createBaseConfig} from '../base'; +import _ from 'lodash'; import * as utils from '@docusaurus/utils/lib/webpackUtils'; import {posixPath} from '@docusaurus/utils'; -import _ from 'lodash'; +import {excludeJS, clientDir, createBaseConfig} from '../base'; import type {Props} from '@docusaurus/types'; describe('babel transpilation exclude logic', () => { diff --git a/packages/docusaurus/src/webpack/__tests__/utils.test.ts b/packages/docusaurus/src/webpack/__tests__/utils.test.ts index 664679e3f689..411ed9180469 100644 --- a/packages/docusaurus/src/webpack/__tests__/utils.test.ts +++ b/packages/docusaurus/src/webpack/__tests__/utils.test.ts @@ -5,8 +5,8 @@ * LICENSE file in the root directory of this source tree. */ -import webpack, {type Configuration, type RuleSetRule} from 'webpack'; import path from 'path'; +import webpack, {type Configuration, type RuleSetRule} from 'webpack'; import { getCustomizableJSLoader, diff --git a/packages/docusaurus/src/webpack/aliases/index.ts b/packages/docusaurus/src/webpack/aliases/index.ts index b48184b8ab8b..dbade3a77e36 100644 --- a/packages/docusaurus/src/webpack/aliases/index.ts +++ b/packages/docusaurus/src/webpack/aliases/index.ts @@ -7,6 +7,7 @@ import fs from 'fs-extra'; import path from 'path'; +import _ from 'lodash'; import { THEME_PATH, fileToPath, @@ -14,7 +15,6 @@ import { normalizeUrl, Globby, } from '@docusaurus/utils'; -import _ from 'lodash'; import type {LoadedPlugin} from '@docusaurus/types'; /** diff --git a/packages/docusaurus/src/webpack/base.ts b/packages/docusaurus/src/webpack/base.ts index 45a81c1031a4..4e00fecefaf1 100644 --- a/packages/docusaurus/src/webpack/base.ts +++ b/packages/docusaurus/src/webpack/base.ts @@ -6,10 +6,9 @@ */ import fs from 'fs-extra'; -import MiniCssExtractPlugin from 'mini-css-extract-plugin'; import path from 'path'; -import type {Configuration} from 'webpack'; -import type {Props} from '@docusaurus/types'; +import MiniCssExtractPlugin from 'mini-css-extract-plugin'; +import {md5Hash, getFileLoaderUtils} from '@docusaurus/utils'; import { getCustomizableJSLoader, getStyleLoaders, @@ -17,7 +16,8 @@ import { getMinimizer, } from './utils'; import {loadThemeAliases, loadDocusaurusAliases} from './aliases'; -import {md5Hash, getFileLoaderUtils} from '@docusaurus/utils'; +import type {Configuration} from 'webpack'; +import type {Props} from '@docusaurus/types'; const CSS_REGEX = /\.css$/i; const CSS_MODULE_REGEX = /\.module\.css$/i; diff --git a/packages/docusaurus/src/webpack/client.ts b/packages/docusaurus/src/webpack/client.ts index f7ca7de770b2..cd2d59720a32 100644 --- a/packages/docusaurus/src/webpack/client.ts +++ b/packages/docusaurus/src/webpack/client.ts @@ -5,15 +5,14 @@ * LICENSE file in the root directory of this source tree. */ -import logger from '@docusaurus/logger'; import path from 'path'; -import type {Configuration} from 'webpack'; +import logger from '@docusaurus/logger'; import merge from 'webpack-merge'; - -import type {Props} from '@docusaurus/types'; import {createBaseConfig} from './base'; import ChunkAssetPlugin from './plugins/ChunkAssetPlugin'; import LogPlugin from './plugins/LogPlugin'; +import type {Props} from '@docusaurus/types'; +import type {Configuration} from 'webpack'; export default async function createClientConfig( props: Props, diff --git a/packages/docusaurus/src/webpack/plugins/CleanWebpackPlugin.ts b/packages/docusaurus/src/webpack/plugins/CleanWebpackPlugin.ts index 46b4ca424fde..5a8f4770102a 100644 --- a/packages/docusaurus/src/webpack/plugins/CleanWebpackPlugin.ts +++ b/packages/docusaurus/src/webpack/plugins/CleanWebpackPlugin.ts @@ -29,9 +29,9 @@ // Modified to optimize performance for Docusaurus specific use case // More context: https://github.com/facebook/docusaurus/pull/1839 -import type {Compiler, Stats} from 'webpack'; import path from 'path'; import {sync as delSync} from 'del'; +import type {Compiler, Stats} from 'webpack'; export type Options = { /** diff --git a/packages/docusaurus/src/webpack/plugins/LogPlugin.ts b/packages/docusaurus/src/webpack/plugins/LogPlugin.ts index e8e79b008057..a1703d2bcac6 100644 --- a/packages/docusaurus/src/webpack/plugins/LogPlugin.ts +++ b/packages/docusaurus/src/webpack/plugins/LogPlugin.ts @@ -6,8 +6,8 @@ */ import WebpackBar from 'webpackbar'; -import type {Compiler} from 'webpack'; import formatWebpackMessages from 'react-dev-utils/formatWebpackMessages'; +import type {Compiler} from 'webpack'; function showError(arr: string[]) { console.log(`\n\n${arr.join('\n')}`); diff --git a/packages/docusaurus/src/webpack/server.ts b/packages/docusaurus/src/webpack/server.ts index c0aab9ed99d9..7f93c86a4bb9 100644 --- a/packages/docusaurus/src/webpack/server.ts +++ b/packages/docusaurus/src/webpack/server.ts @@ -6,24 +6,22 @@ */ import path from 'path'; -import type {Configuration} from 'webpack'; import merge from 'webpack-merge'; - -import type {Props} from '@docusaurus/types'; -import {createBaseConfig} from './base'; -import WaitPlugin from './plugins/WaitPlugin'; -import LogPlugin from './plugins/LogPlugin'; import { NODE_MAJOR_VERSION, NODE_MINOR_VERSION, DOCUSAURUS_VERSION, } from '@docusaurus/utils'; -import ssrDefaultTemplate from './templates/ssr.html.template'; - // Forked for Docusaurus: https://github.com/slorber/static-site-generator-webpack-plugin import StaticSiteGeneratorPlugin, { type Locals, } from '@slorber/static-site-generator-webpack-plugin'; +import {createBaseConfig} from './base'; +import WaitPlugin from './plugins/WaitPlugin'; +import LogPlugin from './plugins/LogPlugin'; +import ssrDefaultTemplate from './templates/ssr.html.template'; +import type {Props} from '@docusaurus/types'; +import type {Configuration} from 'webpack'; export default async function createServerConfig({ props, diff --git a/packages/docusaurus/src/webpack/utils.ts b/packages/docusaurus/src/webpack/utils.ts index 8f32ddc27703..79362887679e 100644 --- a/packages/docusaurus/src/webpack/utils.ts +++ b/packages/docusaurus/src/webpack/utils.ts @@ -5,6 +5,11 @@ * LICENSE file in the root directory of this source tree. */ +import fs from 'fs-extra'; +import path from 'path'; +import crypto from 'crypto'; +import logger from '@docusaurus/logger'; +import {BABEL_CONFIG_FILE_NAME} from '@docusaurus/utils'; import MiniCssExtractPlugin from 'mini-css-extract-plugin'; import { mergeWithCustomize, @@ -16,20 +21,15 @@ import webpack, { type RuleSetRule, type WebpackPluginInstance, } from 'webpack'; -import fs from 'fs-extra'; import TerserPlugin from 'terser-webpack-plugin'; -import type {CustomOptions, CssNanoOptions} from 'css-minimizer-webpack-plugin'; import CssMinimizerPlugin from 'css-minimizer-webpack-plugin'; -import path from 'path'; -import crypto from 'crypto'; -import logger from '@docusaurus/logger'; +import type {CustomOptions, CssNanoOptions} from 'css-minimizer-webpack-plugin'; import type {TransformOptions} from '@babel/core'; import type { Plugin, PostCssOptions, ConfigureWebpackUtils, } from '@docusaurus/types'; -import {BABEL_CONFIG_FILE_NAME} from '@docusaurus/utils'; // Utility method to get style loaders export function getStyleLoaders( diff --git a/packages/docusaurus/tsconfig.client.json b/packages/docusaurus/tsconfig.client.json index 66613cf7c22d..2741f3ca3890 100644 --- a/packages/docusaurus/tsconfig.client.json +++ b/packages/docusaurus/tsconfig.client.json @@ -1,13 +1,15 @@ { "extends": "../../tsconfig.json", "compilerOptions": { + "noEmit": false, + "composite": true, "incremental": true, - "lib": ["DOM", "ES2019"], + "tsBuildInfoFile": "./lib/.tsbuildinfo-client", "module": "esnext", - "tsBuildInfoFile": "./lib/client/.tsbuildinfo", - "rootDir": "src/client", - "outDir": "lib/client", - "jsx": "react-native" + "target": "esnext", + "rootDir": "src", + "outDir": "lib" }, - "include": ["src/client", "src/deps.d.ts"] + "include": ["src/client", "src/*.d.ts"], + "exclude": ["**/__tests__/**"] } diff --git a/packages/docusaurus/tsconfig.json b/packages/docusaurus/tsconfig.json index e467cc195592..cf74f4e2b7a6 100644 --- a/packages/docusaurus/tsconfig.json +++ b/packages/docusaurus/tsconfig.json @@ -1,10 +1,16 @@ -// For editor typechecking; includes bin { - "extends": "./tsconfig.server.json", + "extends": "../../tsconfig.json", + "references": [ + {"path": "./tsconfig.server.json"}, + {"path": "./tsconfig.client.json"} + ], "compilerOptions": { "noEmit": true, + "allowJs": true, + "checkJs": true, "rootDir": ".", "module": "esnext" }, - "include": ["src", "bin"] + "include": ["bin"], + "exclude": ["**/__tests__/**"] } diff --git a/packages/docusaurus/tsconfig.server.json b/packages/docusaurus/tsconfig.server.json index cabe532baa26..f800ce6a5fe5 100644 --- a/packages/docusaurus/tsconfig.server.json +++ b/packages/docusaurus/tsconfig.server.json @@ -1,12 +1,14 @@ { "extends": "../../tsconfig.json", "compilerOptions": { + "noEmit": false, + "composite": true, "incremental": true, "tsBuildInfoFile": "./lib/.tsbuildinfo", + "module": "commonjs", "rootDir": "src", - "outDir": "lib", - "allowJs": true + "outDir": "lib" }, "include": ["src"], - "exclude": ["**/__tests__/**/*", "src/client"] + "exclude": ["src/client", "**/__tests__/**"] } diff --git a/packages/eslint-plugin/.npmignore b/packages/eslint-plugin/.npmignore index 5f1c98c31f64..733c0b46e93a 100644 --- a/packages/eslint-plugin/.npmignore +++ b/packages/eslint-plugin/.npmignore @@ -1,5 +1,4 @@ -copyUntypedFiles.mjs -.tsbuildinfo +.tsbuildinfo* tsconfig* __tests__ diff --git a/packages/eslint-plugin/package.json b/packages/eslint-plugin/package.json index e7b1e4b58cfb..8bd7a9494539 100644 --- a/packages/eslint-plugin/package.json +++ b/packages/eslint-plugin/package.json @@ -21,11 +21,11 @@ "build": "tsc" }, "dependencies": { - "@typescript-eslint/utils": "^5.23.0", + "@typescript-eslint/utils": "^5.25.0", "tslib": "^2.4.0" }, "devDependencies": { - "eslint-plugin-eslint-plugin": "^4.1.0" + "eslint-plugin-eslint-plugin": "^4.2.0" }, "peerDependencies": { "eslint": ">=6" diff --git a/packages/eslint-plugin/tsconfig.json b/packages/eslint-plugin/tsconfig.json index f5902ba1089b..80e43e9813ef 100644 --- a/packages/eslint-plugin/tsconfig.json +++ b/packages/eslint-plugin/tsconfig.json @@ -1,9 +1,13 @@ { "extends": "../../tsconfig.json", "compilerOptions": { + "noEmit": false, "incremental": true, "tsBuildInfoFile": "./lib/.tsbuildinfo", + "module": "commonjs", "rootDir": "src", "outDir": "lib" - } + }, + "include": ["src"], + "exclude": ["**/__tests__/**"] } diff --git a/packages/lqip-loader/.npmignore b/packages/lqip-loader/.npmignore index ba8304029eb7..e4132af42172 100644 --- a/packages/lqip-loader/.npmignore +++ b/packages/lqip-loader/.npmignore @@ -1,5 +1,4 @@ -copyUntypedFiles.mjs -.tsbuildinfo +.tsbuildinfo* tsconfig* __tests__ diff --git a/packages/lqip-loader/package.json b/packages/lqip-loader/package.json index b06ff7780520..5e96bac253fe 100644 --- a/packages/lqip-loader/package.json +++ b/packages/lqip-loader/package.json @@ -27,6 +27,7 @@ "node": ">=14" }, "devDependencies": { + "@types/file-loader": "^5.0.1", "@types/sharp": "^0.30.2" } } diff --git a/packages/lqip-loader/src/index.ts b/packages/lqip-loader/src/index.ts index 112851a34c01..6bb0eb526240 100644 --- a/packages/lqip-loader/src/index.ts +++ b/packages/lqip-loader/src/index.ts @@ -38,7 +38,7 @@ export default async function lqipLoader( } else { if (!contentIsFileExport) { // eslint-disable-next-line global-require, @typescript-eslint/no-var-requires - const fileLoader = require('file-loader'); + const fileLoader = require('file-loader') as typeof import('file-loader'); content = fileLoader.call(this, contentBuffer); } source = content.match( diff --git a/packages/lqip-loader/src/lqip.ts b/packages/lqip-loader/src/lqip.ts index b6286872b44d..929e53ba6a9e 100644 --- a/packages/lqip-loader/src/lqip.ts +++ b/packages/lqip-loader/src/lqip.ts @@ -5,12 +5,12 @@ * LICENSE file in the root directory of this source tree. */ -import logger from '@docusaurus/logger'; import path from 'path'; +import logger from '@docusaurus/logger'; import sharp from 'sharp'; -// eslint-disable-next-line @typescript-eslint/no-var-requires -const {version} = require('../package.json'); +// eslint-disable-next-line @typescript-eslint/no-var-requires, global-require +const {version} = require('../package.json') as {version: string}; const ERROR_EXT = `Error: Input file is missing or uses unsupported image format, lqip v${version}`; diff --git a/packages/lqip-loader/tsconfig.json b/packages/lqip-loader/tsconfig.json index f5902ba1089b..80e43e9813ef 100644 --- a/packages/lqip-loader/tsconfig.json +++ b/packages/lqip-loader/tsconfig.json @@ -1,9 +1,13 @@ { "extends": "../../tsconfig.json", "compilerOptions": { + "noEmit": false, "incremental": true, "tsBuildInfoFile": "./lib/.tsbuildinfo", + "module": "commonjs", "rootDir": "src", "outDir": "lib" - } + }, + "include": ["src"], + "exclude": ["**/__tests__/**"] } diff --git a/packages/stylelint-copyright/index.js b/packages/stylelint-copyright/index.js deleted file mode 100644 index fdf2ab794ba9..000000000000 --- a/packages/stylelint-copyright/index.js +++ /dev/null @@ -1,57 +0,0 @@ -/** - * Copyright (c) Facebook, Inc. and its affiliates. - * - * This source code is licensed under the MIT license found in the - * LICENSE file in the root directory of this source tree. - */ - -const stylelint = require('stylelint'); - -const ruleName = 'docusaurus/copyright-header'; -const messages = stylelint.utils.ruleMessages(ruleName, { - rejected: 'Missing copyright in the header comment', -}); - -const plugin = stylelint.createPlugin( - ruleName, - (primaryOption, secondaryOption, context) => (root, result) => { - stylelint.utils.validateOptions( - result, - ruleName, - { - actual: primaryOption, - possible: [true, false], - }, - { - actual: secondaryOption, - possible: (v) => typeof v.header === 'string', - }, - ); - - if ( - root.first && - root.first.type === 'comment' && - root.first.source.start.column === 1 - ) { - const {text} = root.first; - if (text === secondaryOption.header) { - return; - } - } - if (context.fix) { - root.first?.before(`/*${secondaryOption.header}\n */`); - return; - } - - stylelint.utils.report({ - message: messages.rejected, - node: root, - result, - ruleName, - }); - }, -); - -module.exports = plugin; -module.exports.ruleName = ruleName; -module.exports.messages = messages; diff --git a/packages/stylelint-copyright/package.json b/packages/stylelint-copyright/package.json index c1e0c0a11af9..795992466776 100644 --- a/packages/stylelint-copyright/package.json +++ b/packages/stylelint-copyright/package.json @@ -2,14 +2,19 @@ "name": "stylelint-copyright", "version": "2.0.0-beta.20", "description": "Stylelint plugin to check CSS files for a copyright header.", - "main": "index.js", + "main": "lib/index.js", "license": "MIT", + "scripts": { + "build": "tsc", + "watch": "tsc --watch" + }, "repository": { "type": "git", "url": "https://github.com/facebook/docusaurus.git", "directory": "packages/stylelint-copyright" }, "dependencies": { - "stylelint": "^14.8.2" + "stylelint": "^14.8.3", + "tslib": "^2.4.0" } } diff --git a/packages/stylelint-copyright/__tests__/index.test.js b/packages/stylelint-copyright/src/__tests__/index.test.ts similarity index 81% rename from packages/stylelint-copyright/__tests__/index.test.js rename to packages/stylelint-copyright/src/__tests__/index.test.ts index 20de7dbae8f2..f48b0499c67e 100644 --- a/packages/stylelint-copyright/__tests__/index.test.js +++ b/packages/stylelint-copyright/src/__tests__/index.test.ts @@ -6,13 +6,21 @@ */ /* eslint-disable jest/no-conditional-expect */ -const stylelint = require('stylelint'); -const path = require('path'); -const rule = require('..'); +import path from 'path'; +import stylelint, {type LinterResult} from 'stylelint'; +import rule from '../index'; -const {ruleName, messages} = rule; +const {ruleName} = rule; -function getOutputCss(output) { +declare global { + namespace jest { + interface Matchers<R> { + toHaveMessage: () => R; + } + } +} + +function getOutputCss(output: LinterResult) { // eslint-disable-next-line no-underscore-dangle const result = output.results[0]._postcssResult; return result.root.toString(result.opts.syntax); @@ -97,6 +105,8 @@ function testStylelintRule(config, tests) { } return { + message: () => + 'Expected "reject" test case to not have a "message" property', pass: true, }; }, @@ -106,7 +116,7 @@ function testStylelintRule(config, tests) { testStylelintRule( { - plugins: [path.join(__dirname, '..')], + plugins: [path.join(__dirname, '../../lib/index.js')], rules: { [ruleName]: [true, {header: '*\n * Copyright'}], }, @@ -143,7 +153,8 @@ testStylelintRule( * Copyright */ .foo {}`, - message: messages.rejected, + message: + 'Missing copyright in the header comment (docusaurus/copyright-header)', line: 1, column: 1, }, @@ -154,7 +165,8 @@ testStylelintRule( * Copyright */ .foo {}`, - message: messages.rejected, + message: + 'Missing copyright in the header comment (docusaurus/copyright-header)', line: 1, column: 1, }, @@ -173,7 +185,8 @@ testStylelintRule( */ .foo {}`, - message: messages.rejected, + message: + 'Missing copyright in the header comment (docusaurus/copyright-header)', line: 1, column: 1, }, @@ -192,7 +205,8 @@ testStylelintRule( */ .foo {}`, - message: messages.rejected, + message: + 'Missing copyright in the header comment (docusaurus/copyright-header)', line: 1, column: 1, }, @@ -217,7 +231,8 @@ testStylelintRule( * Copyright */ .foo {}`, - message: messages.rejected, + message: + 'Missing copyright in the header comment (docusaurus/copyright-header)', line: 1, column: 1, }, diff --git a/packages/stylelint-copyright/src/index.ts b/packages/stylelint-copyright/src/index.ts new file mode 100644 index 000000000000..a620d184d0a0 --- /dev/null +++ b/packages/stylelint-copyright/src/index.ts @@ -0,0 +1,58 @@ +/** + * Copyright (c) Facebook, Inc. and its affiliates. + * + * This source code is licensed under the MIT license found in the + * LICENSE file in the root directory of this source tree. + */ + +import stylelint from 'stylelint'; + +const ruleName = 'docusaurus/copyright-header'; +const messages = stylelint.utils.ruleMessages(ruleName, { + rejected: 'Missing copyright in the header comment', +}); + +type SecondaryOption = {header?: string}; + +const plugin = stylelint.createPlugin( + ruleName, + (primaryOption: boolean, secondaryOption: SecondaryOption, context) => + (root, result) => { + stylelint.utils.validateOptions( + result, + ruleName, + { + actual: primaryOption, + possible: [true, false], + }, + { + actual: secondaryOption, + possible: (v) => typeof (v as SecondaryOption)?.header === 'string', + }, + ); + + if ( + root.first && + root.first.type === 'comment' && + root.first.source?.start?.column === 1 + ) { + const {text} = root.first; + if (text === secondaryOption.header) { + return; + } + } + if (context.fix) { + root.first?.before(`/*${secondaryOption.header}\n */`); + return; + } + + stylelint.utils.report({ + message: messages.rejected, + node: root, + result, + ruleName, + }); + }, +); + +export = plugin; diff --git a/packages/stylelint-copyright/tsconfig.json b/packages/stylelint-copyright/tsconfig.json new file mode 100644 index 000000000000..80e43e9813ef --- /dev/null +++ b/packages/stylelint-copyright/tsconfig.json @@ -0,0 +1,13 @@ +{ + "extends": "../../tsconfig.json", + "compilerOptions": { + "noEmit": false, + "incremental": true, + "tsBuildInfoFile": "./lib/.tsbuildinfo", + "module": "commonjs", + "rootDir": "src", + "outDir": "lib" + }, + "include": ["src"], + "exclude": ["**/__tests__/**"] +} diff --git a/tsconfig.json b/tsconfig.json index cb10e8a5ccbc..9b4ff3711eb3 100644 --- a/tsconfig.json +++ b/tsconfig.json @@ -2,13 +2,17 @@ "compilerOptions": { /* Emit */ "target": "ES2020", - "module": "commonjs", - "lib": ["ESNext", "DOM"], + "lib": ["ESNext"], "declaration": true, + // These two options will be selectively overridden in each project. + // Utility libraries will have source maps on, but plugins will not. "declarationMap": false, - "jsx": "react", + "sourceMap": false, + "jsx": "react-native", "importHelpers": true, "noEmitHelpers": true, + // Avoid accidentally using this config to build + "noEmit": true, /* Strict Type-Checking Options */ "allowUnreachableCode": false, @@ -44,5 +48,5 @@ "isolatedModules": true, "skipLibCheck": true // @types/webpack and webpack/types.d.ts are not the same thing }, - "exclude": ["node_modules", "**/__tests__/**/*", "**/lib/**/*"] + "exclude": ["node_modules", "**/lib/**/*"] } diff --git a/website/_dogfooding/_pages tests/error-boundary-tests.tsx b/website/_dogfooding/_pages tests/error-boundary-tests.tsx index a669c7f2afb3..100c7e6c0d2f 100644 --- a/website/_dogfooding/_pages tests/error-boundary-tests.tsx +++ b/website/_dogfooding/_pages tests/error-boundary-tests.tsx @@ -6,8 +6,8 @@ */ import React from 'react'; -import Layout from '@theme/Layout'; import Interpolate from '@docusaurus/Interpolate'; +import Layout from '@theme/Layout'; import ErrorBoundaryTestButton from '@site/src/components/ErrorBoundaryTestButton'; diff --git a/website/_dogfooding/_pages tests/link-tests.tsx b/website/_dogfooding/_pages tests/link-tests.tsx index d0afa2ef4f0a..d1c7c448079c 100644 --- a/website/_dogfooding/_pages tests/link-tests.tsx +++ b/website/_dogfooding/_pages tests/link-tests.tsx @@ -6,8 +6,8 @@ */ import React, {useRef} from 'react'; -import Layout from '@theme/Layout'; import Link from '@docusaurus/Link'; +import Layout from '@theme/Layout'; export default function LinkTest(): JSX.Element { const anchorRef = useRef<HTMLAnchorElement>(null); diff --git a/website/_dogfooding/testSwizzleThemeClassic.mjs b/website/_dogfooding/testSwizzleThemeClassic.mjs index b8b4a4cb1a76..ab75a7d1dafb 100644 --- a/website/_dogfooding/testSwizzleThemeClassic.mjs +++ b/website/_dogfooding/testSwizzleThemeClassic.mjs @@ -31,7 +31,7 @@ const classicThemePathBase = path.join( const themePath = swizzleConfig ? path.join(classicThemePathBase, 'src/theme') - : path.join(classicThemePathBase, 'lib-next/theme'); + : path.join(classicThemePathBase, 'lib/theme'); const toPath = path.join(dirname, '_swizzle_theme_tests'); diff --git a/website/community/4-canary/Versions.tsx b/website/community/4-canary/Versions.tsx index 10e1fdd1ec25..c227a9094e7a 100644 --- a/website/community/4-canary/Versions.tsx +++ b/website/community/4-canary/Versions.tsx @@ -8,8 +8,8 @@ import React, {useContext, useEffect, useState, type ReactNode} from 'react'; import {useDocsPreferredVersion} from '@docusaurus/theme-common'; import {useVersions} from '@docusaurus/plugin-content-docs/client'; -import CodeBlock from '@theme/CodeBlock'; import Translate from '@docusaurus/Translate'; +import CodeBlock from '@theme/CodeBlock'; type ContextValue = { name: string; @@ -27,11 +27,13 @@ export function VersionsProvider({ useEffect(() => { fetch('https://registry.npmjs.org/@docusaurus/core') .then((res) => res.json()) - .then((data) => { - const name = Object.keys(data.versions).at(-1)!; - const time = data.time[name]; - setCanaryVersion({name, time}); - }); + .then( + (data: {versions: string[]; time: {[versionName: string]: string}}) => { + const name = Object.keys(data.versions).at(-1)!; + const time = data.time[name]; + setCanaryVersion({name, time}); + }, + ); }, []); return <Context.Provider value={canaryVersion}>{children}</Context.Provider>; } diff --git a/website/docs/cli.md b/website/docs/cli.md index d1bec4d09ce4..e19840601722 100644 --- a/website/docs/cli.md +++ b/website/docs/cli.md @@ -43,6 +43,7 @@ Builds and serves a preview of your site locally with [Webpack Dev Server](https | `--no-open` | `false` | Do not open automatically the page in the browser. | | `--config` | `undefined` | Path to docusaurus config file, default to `[siteDir]/docusaurus.config.js` | | `--poll [optionalIntervalMs]` | `false` | Use polling of files rather than watching for live reload as a fallback in environments where watching doesn't work. More information [here](https://webpack.js.org/configuration/watch/#watchoptionspoll). | +| `--no-minify` | `false` | Build website without minimizing JS/CSS bundles. | :::important diff --git a/website/docs/deployment.mdx b/website/docs/deployment.mdx index 9674693bce28..23ea588caf49 100644 --- a/website/docs/deployment.mdx +++ b/website/docs/deployment.mdx @@ -778,3 +778,7 @@ See [docs](https://docs.quantcdn.io/docs/cli/continuous-integration) and [blog]( ## Deploying to Cloudflare Pages {#deploying-to-cloudflare-pages} [Cloudflare Pages](https://pages.cloudflare.com/) is a Jamstack platform for frontend developers to collaborate and deploy websites. Get started within a few minutes by following [this article](https://dev.to/apidev234/deploying-docusaurus-to-cloudflare-pages-565g). + +## Deploying to Azure Static Web Apps {#deploying-to-azure-static-web-apps} + +[Azure Static Web Apps](https://docs.microsoft.com/en-us/azure/static-web-apps/overview) is a service that automatically builds and deploys full-stack web apps to Azure directly from the code repository, simplifying the developer experience for CI/CD. Static Web Apps separates the web application's static assets from its dynamic (API) endpoints. Static assets are served from globally-distributed content servers, making it faster for clients to retrieve files using servers nearby. Dynamic APIs are scaled with serverless architectures, using an event-driven functions-based approach that is more cost-effective and scales on demand. Get started in a few minutes by following [this step-by-step guide](https://dev.to/azure/11-share-content-with-docusaurus-azure-static-web-apps-30hc). diff --git a/website/docusaurus.config.js b/website/docusaurus.config.js index 4c373b359cd1..27e3b73c556c 100644 --- a/website/docusaurus.config.js +++ b/website/docusaurus.config.js @@ -7,14 +7,14 @@ // @ts-check const path = require('path'); -const versions = require('./versions.json'); const math = require('remark-math'); +const npm2yarn = require('@docusaurus/remark-plugin-npm2yarn'); +const versions = require('./versions.json'); const VersionsArchived = require('./versionsArchived.json'); const { dogfoodingPluginInstances, dogfoodingThemeInstances, } = require('./_dogfooding/dogfooding.config'); -const npm2yarn = require('@docusaurus/remark-plugin-npm2yarn'); const ArchivedVersionsDropdownItems = Object.entries(VersionsArchived).splice( 0, @@ -375,11 +375,7 @@ const config = { content: `⭐️ If you like Docusaurus, give it a star on <a target="_blank" rel="noopener noreferrer" href="https://github.com/facebook/docusaurus">GitHub</a> and follow us on <a target="_blank" rel="noopener noreferrer" href="https://twitter.com/docusaurus">Twitter ${TwitterSvg}</a>`, }, prism: { - // We need to load markdown again so that YAML is loaded before MD - // and the YAML front matter is highlighted correctly. - // TODO after we have forked prism-react-renderer, we should tweak the - // import order and fix it there - additionalLanguages: ['java', 'markdown', 'latex'], + additionalLanguages: ['java', 'latex'], magicComments: [ { className: 'theme-code-block-highlighted-line', diff --git a/website/package.json b/website/package.json index ee7a44bc87d4..8f9c678d1271 100644 --- a/website/package.json +++ b/website/package.json @@ -30,8 +30,7 @@ "netlify:crowdin:downloadTranslationsFailSafe": "yarn netlify:crowdin:wait && (yarn --cwd .. crowdin:download:website || echo 'Crowdin translation download failure (only internal PRs have access to the Crowdin env token)')", "netlify:crowdin:uploadSources": "yarn --cwd .. crowdin:upload:website", "netlify:test": "yarn netlify:build:deployPreview && npx --package netlify-cli netlify dev -- --debug", - "typecheck": "tsc", - "watch": "tsc --watch" + "typecheck": "tsc" }, "dependencies": { "@crowdin/cli": "^3.7.8", @@ -49,7 +48,7 @@ "@docusaurus/utils": "2.0.0-beta.20", "@docusaurus/utils-common": "2.0.0-beta.20", "@popperjs/core": "^2.11.5", - "@swc/core": "^1.2.181", + "@swc/core": "^1.2.189", "clsx": "^1.1.1", "color": "^4.2.3", "fs-extra": "^10.1.0", @@ -58,11 +57,11 @@ "react": "^17.0.2", "react-dom": "^17.0.2", "react-lite-youtube-embed": "^2.2.2", - "react-medium-image-zoom": "^4.3.7", + "react-medium-image-zoom": "^4.4.0", "react-popper": "^2.3.0", "rehype-katex": "^6.0.2", "remark-math": "^3.0.1", - "swc-loader": "^0.2.0", + "swc-loader": "^0.2.1", "unist-util-visit": "^2.0.3", "workbox-routing": "^6.5.3", "workbox-strategies": "^6.5.3" @@ -82,7 +81,7 @@ "devDependencies": { "@docusaurus/eslint-plugin": "2.0.0-beta.20", "@tsconfig/docusaurus": "^1.0.5", - "@types/jest": "^27.5.0", + "@types/jest": "^27.5.1", "cross-env": "^7.0.3", "rimraf": "^3.0.2" } diff --git a/website/src/components/ColorGenerator/index.tsx b/website/src/components/ColorGenerator/index.tsx index 0ce0d508e358..2fba54627f99 100644 --- a/website/src/components/ColorGenerator/index.tsx +++ b/website/src/components/ColorGenerator/index.tsx @@ -8,12 +8,11 @@ import React, {useEffect, useState} from 'react'; import clsx from 'clsx'; import Color from 'color'; -import CodeBlock from '@theme/CodeBlock'; -import Admonition from '@theme/Admonition'; import Link from '@docusaurus/Link'; import Translate from '@docusaurus/Translate'; import {useColorMode} from '@docusaurus/theme-common'; - +import CodeBlock from '@theme/CodeBlock'; +import Admonition from '@theme/Admonition'; import { type ColorState, COLOR_SHADES, diff --git a/website/src/components/Playground/index.tsx b/website/src/components/Playground/index.tsx index 45c4186fa397..a661c965c270 100644 --- a/website/src/components/Playground/index.tsx +++ b/website/src/components/Playground/index.tsx @@ -8,10 +8,10 @@ /* eslint-disable global-require */ import React from 'react'; +import clsx from 'clsx'; import Translate from '@docusaurus/Translate'; import Link from '@docusaurus/Link'; import Image from '@theme/IdealImage'; -import clsx from 'clsx'; const Playgrounds = [ { diff --git a/website/src/components/UpgradeGuide/index.tsx b/website/src/components/UpgradeGuide/index.tsx index 0ba1913aae74..01d1131cc9b5 100644 --- a/website/src/components/UpgradeGuide/index.tsx +++ b/website/src/components/UpgradeGuide/index.tsx @@ -11,11 +11,11 @@ import { useActiveDocContext, useVersions, } from '@docusaurus/plugin-content-docs/client'; -import Admonition from '@theme/Admonition'; import Link from '@docusaurus/Link'; -import CodeBlock from '@theme/CodeBlock'; import useIsBrowser from '@docusaurus/useIsBrowser'; import Translate from '@docusaurus/Translate'; +import Admonition from '@theme/Admonition'; +import CodeBlock from '@theme/CodeBlock'; function PackageJson() { const latestVersion = useLatestVersion(); diff --git a/website/src/data/__tests__/user.test.ts b/website/src/data/__tests__/user.test.ts index 1cd0f4ebe529..06f76b53d1cb 100644 --- a/website/src/data/__tests__/user.test.ts +++ b/website/src/data/__tests__/user.test.ts @@ -5,12 +5,11 @@ * LICENSE file in the root directory of this source tree. */ -import {TagList, sortedUsers, type User} from '../users'; -import {Joi} from '@docusaurus/utils-validation'; - import fs from 'fs-extra'; import path from 'path'; import imageSize from 'image-size'; +import {Joi} from '@docusaurus/utils-validation'; +import {TagList, sortedUsers, type User} from '../users'; declare global { namespace jest { diff --git a/website/src/data/showcase/30-days-swa.png b/website/src/data/showcase/30-days-swa.png new file mode 100644 index 000000000000..06c294bce4f6 Binary files /dev/null and b/website/src/data/showcase/30-days-swa.png differ diff --git a/website/src/data/showcase/avana-wallet.png b/website/src/data/showcase/avana-wallet.png new file mode 100644 index 000000000000..e1437e4d3cb6 Binary files /dev/null and b/website/src/data/showcase/avana-wallet.png differ diff --git a/website/src/data/showcase/codesweetly.png b/website/src/data/showcase/codesweetly.png new file mode 100644 index 000000000000..6d848fee6aad Binary files /dev/null and b/website/src/data/showcase/codesweetly.png differ diff --git a/website/src/data/showcase/fast.png b/website/src/data/showcase/fast.png new file mode 100644 index 000000000000..c69425f7660c Binary files /dev/null and b/website/src/data/showcase/fast.png differ diff --git a/website/src/data/showcase/httpin.png b/website/src/data/showcase/httpin.png new file mode 100644 index 000000000000..97cc4c84e256 Binary files /dev/null and b/website/src/data/showcase/httpin.png differ diff --git a/website/src/data/showcase/yeecord.png b/website/src/data/showcase/yeecord.png new file mode 100644 index 000000000000..52553796b78d Binary files /dev/null and b/website/src/data/showcase/yeecord.png differ diff --git a/website/src/data/users.tsx b/website/src/data/users.tsx index 40be9f49be44..a4ea2447ef0d 100644 --- a/website/src/data/users.tsx +++ b/website/src/data/users.tsx @@ -229,6 +229,15 @@ const Users: User[] = [ source: 'https://github.com/attobot-discord/website', tags: ['opensource'], }, + { + title: 'Avana Wallet', + description: + 'Solana blockchain non-custodial wallet that connects you to Web3 dapps, DeFi, GameFi and NFT marketplaces.', + preview: require('./showcase/avana-wallet.png'), + website: 'https://docs.avanawallet.com/', + source: null, + tags: ['product'], + }, { title: 'AvN Gateway', description: @@ -371,6 +380,14 @@ const Users: User[] = [ source: 'https://github.com/lyft/clutch/tree/main/docs/_website', tags: ['opensource'], }, + { + title: 'CodeSweetly', + description: 'The Home of Simplified Web Development Tutorials', + preview: require('./showcase/codesweetly.png'), + website: 'https://codesweetly.com/', + source: null, + tags: ['personal'], + }, { title: 'CodeYourFuture', description: @@ -631,6 +648,14 @@ const Users: User[] = [ source: 'https://github.com/eta-dev/eta-docs', tags: ['opensource'], }, + { + title: 'FAST', + description: 'The adaptive interface system for modern web experiences.', + preview: require('./showcase/fast.png'), + website: 'https://www.fast.design/docs/introduction/', + source: 'https://github.com/microsoft/fast/tree/master/sites/website', + tags: ['opensource', 'product'], + }, { title: 'FBT', description: 'An internationalization framework', @@ -853,6 +878,14 @@ const Users: User[] = [ source: 'https://github.com/home-assistant/developers.home-assistant', tags: ['opensource'], }, + { + title: 'httpin', + description: 'Decode an HTTP request into a custom struct in Go', + preview: require('./showcase/httpin.png'), + website: 'https://ggicci.github.io/httpin/', + source: 'https://github.com/ggicci/httpin/tree/documentation/docs', + tags: ['opensource'], + }, { title: 'I am Massoud', description: 'The portfolio of Massoud Maboudi, Full Stack Developer', @@ -2077,6 +2110,14 @@ const Users: User[] = [ source: null, tags: ['meta'], }, + { + title: '30 Days Of SWA', + description: 'A 30-Day Developer Guide to Azure Static Web Apps', + preview: require('./showcase/30-days-swa.png'), + website: 'https://www.azurestaticwebapps.dev', + source: 'https://github.com/staticwebdev/30DaysOfSWA/tree/main/www', + tags: ['opensource', 'product'], + }, { title: 'TiDB Community Books', description: 'A website for co-created books by TiDB Community users.', @@ -2245,6 +2286,15 @@ const Users: User[] = [ source: 'https://github.com/woodpecker-ci/woodpecker/tree/master/docs', tags: ['opensource'], }, + { + title: 'Yeecord', + description: + 'A fully Chinese Discord bot with epic features that makes Discord more than just chatting platform.', + website: 'https://yeecord.com/', + preview: require('./showcase/yeecord.png'), + tags: ['product', 'personal'], + source: null + }, { title: 'Zowe', description: diff --git a/website/src/pages/index.tsx b/website/src/pages/index.tsx index d2ccfc69aaca..62363cbbd647 100644 --- a/website/src/pages/index.tsx +++ b/website/src/pages/index.tsx @@ -6,6 +6,9 @@ */ import React from 'react'; +import clsx from 'clsx'; +import LiteYouTubeEmbed from 'react-lite-youtube-embed'; +import 'react-lite-youtube-embed/dist/LiteYouTubeEmbed.css'; import Link from '@docusaurus/Link'; import Translate, {translate} from '@docusaurus/Translate'; import useDocusaurusContext from '@docusaurus/useDocusaurusContext'; @@ -18,10 +21,6 @@ import Tweet from '@site/src/components/Tweet'; import Tweets, {type TweetItem} from '@site/src/data/tweets'; import Quotes from '@site/src/data/quotes'; import Features, {type FeatureItem} from '@site/src/data/features'; -import LiteYouTubeEmbed from 'react-lite-youtube-embed'; -import 'react-lite-youtube-embed/dist/LiteYouTubeEmbed.css'; - -import clsx from 'clsx'; import styles from './styles.module.css'; diff --git a/website/src/pages/showcase/_components/ShowcaseCard/index.tsx b/website/src/pages/showcase/_components/ShowcaseCard/index.tsx index a09b4c5e4909..39c6c07f19dd 100644 --- a/website/src/pages/showcase/_components/ShowcaseCard/index.tsx +++ b/website/src/pages/showcase/_components/ShowcaseCard/index.tsx @@ -7,13 +7,10 @@ import React from 'react'; import clsx from 'clsx'; -import Image from '@theme/IdealImage'; import Link from '@docusaurus/Link'; import Translate from '@docusaurus/Translate'; - -import styles from './styles.module.css'; +import Image from '@theme/IdealImage'; import FavoriteIcon from '@site/src/components/svgIcons/FavoriteIcon'; -import Tooltip from '../ShowcaseTooltip'; import { Tags, TagList, @@ -22,6 +19,8 @@ import { type Tag, } from '@site/src/data/users'; import {sortBy} from '@site/src/utils/jsUtils'; +import Tooltip from '../ShowcaseTooltip'; +import styles from './styles.module.css'; const TagComp = React.forwardRef<HTMLLIElement, Tag>( ({label, color, description}, ref) => ( diff --git a/website/src/pages/showcase/_components/ShowcaseFilterToggle/index.tsx b/website/src/pages/showcase/_components/ShowcaseFilterToggle/index.tsx index 8df064852eec..acb4516d111f 100644 --- a/website/src/pages/showcase/_components/ShowcaseFilterToggle/index.tsx +++ b/website/src/pages/showcase/_components/ShowcaseFilterToggle/index.tsx @@ -6,12 +6,12 @@ */ import React, {useState, useEffect, useCallback} from 'react'; +import clsx from 'clsx'; import {useHistory, useLocation} from '@docusaurus/router'; import {prepareUserState} from '../../index'; import styles from './styles.module.css'; -import clsx from 'clsx'; export type Operator = 'OR' | 'AND'; diff --git a/website/src/pages/showcase/_components/ShowcaseTagSelect/index.tsx b/website/src/pages/showcase/_components/ShowcaseTagSelect/index.tsx index 29ed978841b9..7495cf42eb58 100644 --- a/website/src/pages/showcase/_components/ShowcaseTagSelect/index.tsx +++ b/website/src/pages/showcase/_components/ShowcaseTagSelect/index.tsx @@ -15,9 +15,9 @@ import React, { } from 'react'; import {useHistory, useLocation} from '@docusaurus/router'; import {toggleListItem} from '@site/src/utils/jsUtils'; -import {prepareUserState} from '../../index'; import type {TagType} from '@site/src/data/users'; +import {prepareUserState} from '../../index'; import styles from './styles.module.css'; interface Props extends ComponentProps<'input'> { diff --git a/website/src/pages/showcase/index.tsx b/website/src/pages/showcase/index.tsx index e3a576ca3c1c..0cfd04de3d27 100644 --- a/website/src/pages/showcase/index.tsx +++ b/website/src/pages/showcase/index.tsx @@ -6,11 +6,21 @@ */ import React, {useState, useMemo, useEffect} from 'react'; - -import Layout from '@theme/Layout'; import clsx from 'clsx'; +import ExecutionEnvironment from '@docusaurus/ExecutionEnvironment'; +import Translate, {translate} from '@docusaurus/Translate'; +import {useHistory, useLocation} from '@docusaurus/router'; +import {usePluralForm} from '@docusaurus/theme-common'; +import Layout from '@theme/Layout'; import FavoriteIcon from '@site/src/components/svgIcons/FavoriteIcon'; +import { + sortedUsers, + Tags, + TagList, + type User, + type TagType, +} from '@site/src/data/users'; import ShowcaseTagSelect, { readSearchTags, } from './_components/ShowcaseTagSelect'; @@ -19,20 +29,8 @@ import ShowcaseFilterToggle, { readOperator, } from './_components/ShowcaseFilterToggle'; import ShowcaseCard from './_components/ShowcaseCard'; -import { - sortedUsers, - Tags, - TagList, - type User, - type TagType, -} from '@site/src/data/users'; import ShowcaseTooltip from './_components/ShowcaseTooltip'; -import ExecutionEnvironment from '@docusaurus/ExecutionEnvironment'; -import Translate, {translate} from '@docusaurus/Translate'; -import {useHistory, useLocation} from '@docusaurus/router'; -import {usePluralForm} from '@docusaurus/theme-common'; - import styles from './styles.module.css'; const TITLE = 'Docusaurus Site Showcase'; diff --git a/website/src/pages/versions.tsx b/website/src/pages/versions.tsx index c9239d28edb6..9db0ec5d10ee 100644 --- a/website/src/pages/versions.tsx +++ b/website/src/pages/versions.tsx @@ -8,14 +8,13 @@ import React from 'react'; import useDocusaurusContext from '@docusaurus/useDocusaurusContext'; import Link from '@docusaurus/Link'; -import Layout from '@theme/Layout'; -import Heading from '@theme/Heading'; import Translate from '@docusaurus/Translate'; import { useVersions, useLatestVersion, } from '@docusaurus/plugin-content-docs/client'; - +import Layout from '@theme/Layout'; +import Heading from '@theme/Heading'; import VersionsArchived from '@site/versionsArchived.json'; const VersionsArchivedList = Object.entries(VersionsArchived); diff --git a/website/src/plugins/changelog/theme/ChangelogAuthors/index.tsx b/website/src/plugins/changelog/theme/ChangelogAuthors/index.tsx index 0ca25fbe7cb9..57be25cbd4a0 100644 --- a/website/src/plugins/changelog/theme/ChangelogAuthors/index.tsx +++ b/website/src/plugins/changelog/theme/ChangelogAuthors/index.tsx @@ -7,11 +7,11 @@ import React, {useState} from 'react'; import clsx from 'clsx'; -import type {Props} from '@theme/BlogPostAuthors'; import ChangelogAuthor from '@theme/ChangelogAuthor'; +import IconExpand from '@theme/IconExpand'; +import type {Props} from '@theme/BlogPostAuthors'; import styles from './styles.module.css'; -import IconExpand from '@theme/IconExpand'; // Component responsible for the authors layout export default function BlogPostAuthors({ diff --git a/website/src/plugins/changelog/theme/ChangelogAuthors/styles.module.css b/website/src/plugins/changelog/theme/ChangelogAuthors/styles.module.css index 08d003d4e0e6..19ec3dd69dd2 100644 --- a/website/src/plugins/changelog/theme/ChangelogAuthors/styles.module.css +++ b/website/src/plugins/changelog/theme/ChangelogAuthors/styles.module.css @@ -28,8 +28,8 @@ margin-left: 0.3rem; margin-right: 0.3rem; border-radius: 50%; - width: var(--ifm-avatar-photo-size-md); - height: var(--ifm-avatar-photo-size-md); + width: var(--ifm-avatar-photo-size); + height: var(--ifm-avatar-photo-size); background-color: var(--ifm-color-emphasis-100); } diff --git a/website/src/plugins/changelog/theme/ChangelogItem/index.tsx b/website/src/plugins/changelog/theme/ChangelogItem/index.tsx index fea34d46bcad..fee206306260 100644 --- a/website/src/plugins/changelog/theme/ChangelogItem/index.tsx +++ b/website/src/plugins/changelog/theme/ChangelogItem/index.tsx @@ -12,10 +12,10 @@ import Link from '@docusaurus/Link'; import {useBaseUrlUtils} from '@docusaurus/useBaseUrl'; import {blogPostContainerID} from '@docusaurus/utils-common'; import MDXComponents from '@theme/MDXComponents'; +import ChangelogAuthors from '@theme/ChangelogAuthors'; import type {Props} from '@theme/BlogPostItem'; import styles from './styles.module.css'; -import ChangelogAuthors from '@theme/ChangelogAuthors'; export default function ChangelogItem(props: Props): JSX.Element { const {withBaseUrl} = useBaseUrlUtils(); diff --git a/website/src/plugins/changelog/theme/ChangelogList/index.tsx b/website/src/plugins/changelog/theme/ChangelogList/index.tsx index cf0d7b7297a3..17aceebb6f01 100644 --- a/website/src/plugins/changelog/theme/ChangelogList/index.tsx +++ b/website/src/plugins/changelog/theme/ChangelogList/index.tsx @@ -6,21 +6,21 @@ */ import React from 'react'; -import BlogLayout from '@theme/BlogLayout'; -import BlogListPaginator from '@theme/BlogListPaginator'; +import clsx from 'clsx'; import Translate from '@docusaurus/Translate'; -import type {Props} from '@theme/BlogListPage'; +import Link from '@docusaurus/Link'; import { PageMetadata, HtmlClassNameProvider, ThemeClassNames, } from '@docusaurus/theme-common'; -import Link from '@docusaurus/Link'; +import BlogLayout from '@theme/BlogLayout'; +import BlogListPaginator from '@theme/BlogListPaginator'; +import SearchMetadata from '@theme/SearchMetadata'; import ChangelogItem from '@theme/ChangelogItem'; +import type {Props} from '@theme/BlogListPage'; import styles from './styles.module.css'; -import SearchMetadata from '@theme/SearchMetadata'; -import clsx from 'clsx'; function ChangelogListMetadata(props: Props): JSX.Element { const {metadata} = props; diff --git a/website/src/plugins/changelog/theme/ChangelogPage/index.tsx b/website/src/plugins/changelog/theme/ChangelogPage/index.tsx index ef45aa304e6b..7ce92e1707d2 100644 --- a/website/src/plugins/changelog/theme/ChangelogPage/index.tsx +++ b/website/src/plugins/changelog/theme/ChangelogPage/index.tsx @@ -6,19 +6,19 @@ */ import React from 'react'; +import clsx from 'clsx'; import Translate from '@docusaurus/Translate'; -import BlogLayout from '@theme/BlogLayout'; -import ChangelogItem from '@theme/ChangelogItem'; -import ChangelogPaginator from '@theme/ChangelogPaginator'; -import type {Props} from '@theme/BlogPostPage'; +import Link from '@docusaurus/Link'; import { PageMetadata, HtmlClassNameProvider, ThemeClassNames, } from '@docusaurus/theme-common'; +import BlogLayout from '@theme/BlogLayout'; +import ChangelogItem from '@theme/ChangelogItem'; +import ChangelogPaginator from '@theme/ChangelogPaginator'; import TOC from '@theme/TOC'; -import Link from '@docusaurus/Link'; -import clsx from 'clsx'; +import type {Props} from '@theme/BlogPostPage'; function ChangelogPageMetadata(props: Props): JSX.Element { const {content: BlogPostContents} = props; diff --git a/website/src/plugins/featureRequests/FeatureRequestsPage.tsx b/website/src/plugins/featureRequests/FeatureRequestsPage.tsx index 516f490485d2..f5d836130b53 100644 --- a/website/src/plugins/featureRequests/FeatureRequestsPage.tsx +++ b/website/src/plugins/featureRequests/FeatureRequestsPage.tsx @@ -6,10 +6,10 @@ */ import React, {useEffect} from 'react'; +import clsx from 'clsx'; import Layout from '@theme/Layout'; import cannyScript from './cannyScript'; -import clsx from 'clsx'; import styles from './styles.module.css'; const BOARD_TOKEN = '054e0e53-d951-b14c-7e74-9eb8f9ed2f91'; diff --git a/website/src/theme/CodeBlock/index.tsx b/website/src/theme/CodeBlock/index.tsx index dd5aedfc18de..82dc1b0f5f14 100644 --- a/website/src/theme/CodeBlock/index.tsx +++ b/website/src/theme/CodeBlock/index.tsx @@ -6,8 +6,8 @@ */ import React from 'react'; -import type {Props} from '@theme/CodeBlock'; import CodeBlock from '@theme-original/CodeBlock'; +import type {Props} from '@theme/CodeBlock'; // This component does nothing on purpose // Dogfood: wrapping a theme component already enhanced by another theme diff --git a/website/src/theme/ColorModeToggle.tsx b/website/src/theme/ColorModeToggle.tsx index e9e653d163ab..44f81a00ff66 100644 --- a/website/src/theme/ColorModeToggle.tsx +++ b/website/src/theme/ColorModeToggle.tsx @@ -7,7 +7,6 @@ import React from 'react'; import OriginalToggle from '@theme-original/ColorModeToggle'; -import type {Props} from '@theme/ColorModeToggle'; import { lightStorage, darkStorage, @@ -19,6 +18,7 @@ import { DARK_BACKGROUND_COLOR, COLOR_SHADES, } from '@site/src/utils/colorUtils'; +import type {Props} from '@theme/ColorModeToggle'; // The ColorGenerator modifies the DOM styles. The styles are persisted in // session storage, and we need to apply the same style when toggling modes even diff --git a/website/src/theme/DocSidebar/Desktop/Content/index.js b/website/src/theme/DocSidebar/Desktop/Content/index.js index 0d47b8eec978..19d30bc26001 100644 --- a/website/src/theme/DocSidebar/Desktop/Content/index.js +++ b/website/src/theme/DocSidebar/Desktop/Content/index.js @@ -6,8 +6,8 @@ */ import React from 'react'; -import Content from '@theme-original/DocSidebar/Desktop/Content'; import {useLocation} from '@docusaurus/router'; +import Content from '@theme-original/DocSidebar/Desktop/Content'; function SidebarAd() { return ( diff --git a/website/src/theme/Layout/index.tsx b/website/src/theme/Layout/index.tsx index 78f03a793f88..44034528edcd 100644 --- a/website/src/theme/Layout/index.tsx +++ b/website/src/theme/Layout/index.tsx @@ -6,8 +6,8 @@ */ import React from 'react'; -import type {Props} from '@theme/Layout'; import Layout from '@theme-original/Layout'; +import type {Props} from '@theme/Layout'; // This component is only used to test for CSS insertion order import './styles.module.css'; diff --git a/yarn.lock b/yarn.lock index 5374e67cd0de..4c52edca54a9 100644 --- a/yarn.lock +++ b/yarn.lock @@ -2,133 +2,126 @@ # yarn lockfile v1 -"@algolia/autocomplete-core@1.5.2": - version "1.5.2" - resolved "https://registry.yarnpkg.com/@algolia/autocomplete-core/-/autocomplete-core-1.5.2.tgz#ec0178e07b44fd74a057728ac157291b26cecf37" - integrity sha512-DY0bhyczFSS1b/CqJlTE/nQRtnTAHl6IemIkBy0nEWnhDzRDdtdx4p5Uuk3vwAFxwEEgi1WqKwgSSMx6DpNL4A== - dependencies: - "@algolia/autocomplete-shared" "1.5.2" - -"@algolia/autocomplete-preset-algolia@1.5.2": - version "1.5.2" - resolved "https://registry.yarnpkg.com/@algolia/autocomplete-preset-algolia/-/autocomplete-preset-algolia-1.5.2.tgz#36c5638cc6dba6ea46a86e5a0314637ca40a77ca" - integrity sha512-3MRYnYQFJyovANzSX2CToS6/5cfVjbLLqFsZTKcvF3abhQzxbqwwaMBlJtt620uBUOeMzhdfasKhCc40+RHiZw== +"@algolia/autocomplete-core@1.6.3": + version "1.6.3" + resolved "https://registry.yarnpkg.com/@algolia/autocomplete-core/-/autocomplete-core-1.6.3.tgz#76832fffb6405ac2c87bac5a040b8a31a1cdef80" + integrity sha512-dqQqRt01fX3YuVFrkceHsoCnzX0bLhrrg8itJI1NM68KjrPYQPYsE+kY8EZTCM4y8VDnhqJErR73xe/ZsV+qAA== dependencies: - "@algolia/autocomplete-shared" "1.5.2" + "@algolia/autocomplete-shared" "1.6.3" -"@algolia/autocomplete-shared@1.5.2": - version "1.5.2" - resolved "https://registry.yarnpkg.com/@algolia/autocomplete-shared/-/autocomplete-shared-1.5.2.tgz#e157f9ad624ab8fd940ff28bd2094cdf199cdd79" - integrity sha512-ylQAYv5H0YKMfHgVWX0j0NmL8XBcAeeeVQUmppnnMtzDbDnca6CzhKj3Q8eF9cHCgcdTDdb5K+3aKyGWA0obug== +"@algolia/autocomplete-shared@1.6.3": + version "1.6.3" + resolved "https://registry.yarnpkg.com/@algolia/autocomplete-shared/-/autocomplete-shared-1.6.3.tgz#52085ce89a755977841ed0a463aa31ce8f1dea97" + integrity sha512-UV46bnkTztyADFaETfzFC5ryIdGVb2zpAoYgu0tfcuYWjhg1KbLXveFffZIrGVoboqmAk1b+jMrl6iCja1i3lg== -"@algolia/cache-browser-local-storage@4.13.0": - version "4.13.0" - resolved "https://registry.yarnpkg.com/@algolia/cache-browser-local-storage/-/cache-browser-local-storage-4.13.0.tgz#f8aa4fe31104b19d616ea392f9ed5c2ea847d964" - integrity sha512-nj1vHRZauTqP/bluwkRIgEADEimqojJgoTRCel5f6q8WCa9Y8QeI4bpDQP28FoeKnDRYa3J5CauDlN466jqRhg== +"@algolia/cache-browser-local-storage@4.13.1": + version "4.13.1" + resolved "https://registry.yarnpkg.com/@algolia/cache-browser-local-storage/-/cache-browser-local-storage-4.13.1.tgz#ffacb9230119f77de1a6f163b83680be999110e4" + integrity sha512-UAUVG2PEfwd/FfudsZtYnidJ9eSCpS+LW9cQiesePQLz41NAcddKxBak6eP2GErqyFagSlnVXe/w2E9h2m2ttg== dependencies: - "@algolia/cache-common" "4.13.0" + "@algolia/cache-common" "4.13.1" -"@algolia/cache-common@4.13.0": - version "4.13.0" - resolved "https://registry.yarnpkg.com/@algolia/cache-common/-/cache-common-4.13.0.tgz#27b83fd3939d08d72261b36a07eeafc4cb4d2113" - integrity sha512-f9mdZjskCui/dA/fA/5a+6hZ7xnHaaZI5tM/Rw9X8rRB39SUlF/+o3P47onZ33n/AwkpSbi5QOyhs16wHd55kA== +"@algolia/cache-common@4.13.1": + version "4.13.1" + resolved "https://registry.yarnpkg.com/@algolia/cache-common/-/cache-common-4.13.1.tgz#c933fdec9f73b4f7c69d5751edc92eee4a63d76b" + integrity sha512-7Vaf6IM4L0Jkl3sYXbwK+2beQOgVJ0mKFbz/4qSxKd1iy2Sp77uTAazcX+Dlexekg1fqGUOSO7HS4Sx47ZJmjA== -"@algolia/cache-in-memory@4.13.0": - version "4.13.0" - resolved "https://registry.yarnpkg.com/@algolia/cache-in-memory/-/cache-in-memory-4.13.0.tgz#10801a74550cbabb64b59ff08c56bce9c278ff2d" - integrity sha512-hHdc+ahPiMM92CQMljmObE75laYzNFYLrNOu0Q3/eyvubZZRtY2SUsEEgyUEyzXruNdzrkcDxFYa7YpWBJYHAg== +"@algolia/cache-in-memory@4.13.1": + version "4.13.1" + resolved "https://registry.yarnpkg.com/@algolia/cache-in-memory/-/cache-in-memory-4.13.1.tgz#c19baa67b4597e1a93e987350613ab3b88768832" + integrity sha512-pZzybCDGApfA/nutsFK1P0Sbsq6fYJU3DwIvyKg4pURerlJM4qZbB9bfLRef0FkzfQu7W11E4cVLCIOWmyZeuQ== dependencies: - "@algolia/cache-common" "4.13.0" + "@algolia/cache-common" "4.13.1" -"@algolia/client-account@4.13.0": - version "4.13.0" - resolved "https://registry.yarnpkg.com/@algolia/client-account/-/client-account-4.13.0.tgz#f8646dd40d1e9e3353e10abbd5d6c293ea92a8e2" - integrity sha512-FzFqFt9b0g/LKszBDoEsW+dVBuUe1K3scp2Yf7q6pgHWM1WqyqUlARwVpLxqyc+LoyJkTxQftOKjyFUqddnPKA== +"@algolia/client-account@4.13.1": + version "4.13.1" + resolved "https://registry.yarnpkg.com/@algolia/client-account/-/client-account-4.13.1.tgz#fea591943665477a23922ab31863ad0732e26c66" + integrity sha512-TFLiZ1KqMiir3FNHU+h3b0MArmyaHG+eT8Iojio6TdpeFcAQ1Aiy+2gb3SZk3+pgRJa/BxGmDkRUwE5E/lv3QQ== dependencies: - "@algolia/client-common" "4.13.0" - "@algolia/client-search" "4.13.0" - "@algolia/transporter" "4.13.0" + "@algolia/client-common" "4.13.1" + "@algolia/client-search" "4.13.1" + "@algolia/transporter" "4.13.1" -"@algolia/client-analytics@4.13.0": - version "4.13.0" - resolved "https://registry.yarnpkg.com/@algolia/client-analytics/-/client-analytics-4.13.0.tgz#a00bd02df45d71becb9dd4c5c993d805f2e1786d" - integrity sha512-klmnoq2FIiiMHImkzOm+cGxqRLLu9CMHqFhbgSy9wtXZrqb8BBUIUE2VyBe7azzv1wKcxZV2RUyNOMpFqmnRZA== +"@algolia/client-analytics@4.13.1": + version "4.13.1" + resolved "https://registry.yarnpkg.com/@algolia/client-analytics/-/client-analytics-4.13.1.tgz#5275956b2d0d16997148f2085f1701b6c39ecc32" + integrity sha512-iOS1JBqh7xaL5x00M5zyluZ9+9Uy9GqtYHv/2SMuzNW1qP7/0doz1lbcsP3S7KBbZANJTFHUOfuqyRLPk91iFA== dependencies: - "@algolia/client-common" "4.13.0" - "@algolia/client-search" "4.13.0" - "@algolia/requester-common" "4.13.0" - "@algolia/transporter" "4.13.0" + "@algolia/client-common" "4.13.1" + "@algolia/client-search" "4.13.1" + "@algolia/requester-common" "4.13.1" + "@algolia/transporter" "4.13.1" -"@algolia/client-common@4.13.0": - version "4.13.0" - resolved "https://registry.yarnpkg.com/@algolia/client-common/-/client-common-4.13.0.tgz#8bc373d164dbdcce38b4586912bbe162492bcb86" - integrity sha512-GoXfTp0kVcbgfSXOjfrxx+slSipMqGO9WnNWgeMmru5Ra09MDjrcdunsiiuzF0wua6INbIpBQFTC2Mi5lUNqGA== +"@algolia/client-common@4.13.1": + version "4.13.1" + resolved "https://registry.yarnpkg.com/@algolia/client-common/-/client-common-4.13.1.tgz#3bf9e3586f20ef85bbb56ccca390f7dbe57c8f4f" + integrity sha512-LcDoUE0Zz3YwfXJL6lJ2OMY2soClbjrrAKB6auYVMNJcoKZZ2cbhQoFR24AYoxnGUYBER/8B+9sTBj5bj/Gqbg== dependencies: - "@algolia/requester-common" "4.13.0" - "@algolia/transporter" "4.13.0" + "@algolia/requester-common" "4.13.1" + "@algolia/transporter" "4.13.1" -"@algolia/client-personalization@4.13.0": - version "4.13.0" - resolved "https://registry.yarnpkg.com/@algolia/client-personalization/-/client-personalization-4.13.0.tgz#10fb7af356422551f11a67222b39c52306f1512c" - integrity sha512-KneLz2WaehJmNfdr5yt2HQETpLaCYagRdWwIwkTqRVFCv4DxRQ2ChPVW9jeTj4YfAAhfzE6F8hn7wkQ/Jfj6ZA== +"@algolia/client-personalization@4.13.1": + version "4.13.1" + resolved "https://registry.yarnpkg.com/@algolia/client-personalization/-/client-personalization-4.13.1.tgz#438a1f58576ef19c4ad4addb8417bdacfe2fce2e" + integrity sha512-1CqrOW1ypVrB4Lssh02hP//YxluoIYXAQCpg03L+/RiXJlCs+uIqlzC0ctpQPmxSlTK6h07kr50JQoYH/TIM9w== dependencies: - "@algolia/client-common" "4.13.0" - "@algolia/requester-common" "4.13.0" - "@algolia/transporter" "4.13.0" + "@algolia/client-common" "4.13.1" + "@algolia/requester-common" "4.13.1" + "@algolia/transporter" "4.13.1" -"@algolia/client-search@4.13.0": - version "4.13.0" - resolved "https://registry.yarnpkg.com/@algolia/client-search/-/client-search-4.13.0.tgz#2d8ff8e755c4a37ec89968f3f9b358eed005c7f0" - integrity sha512-blgCKYbZh1NgJWzeGf+caKE32mo3j54NprOf0LZVCubQb3Kx37tk1Hc8SDs9bCAE8hUvf3cazMPIg7wscSxspA== +"@algolia/client-search@4.13.1": + version "4.13.1" + resolved "https://registry.yarnpkg.com/@algolia/client-search/-/client-search-4.13.1.tgz#5501deed01e23c33d4aaa9f9eb96a849f0fce313" + integrity sha512-YQKYA83MNRz3FgTNM+4eRYbSmHi0WWpo019s5SeYcL3HUan/i5R09VO9dk3evELDFJYciiydSjbsmhBzbpPP2A== dependencies: - "@algolia/client-common" "4.13.0" - "@algolia/requester-common" "4.13.0" - "@algolia/transporter" "4.13.0" + "@algolia/client-common" "4.13.1" + "@algolia/requester-common" "4.13.1" + "@algolia/transporter" "4.13.1" "@algolia/events@^4.0.1": version "4.0.1" resolved "https://registry.yarnpkg.com/@algolia/events/-/events-4.0.1.tgz#fd39e7477e7bc703d7f893b556f676c032af3950" integrity sha512-FQzvOCgoFXAbf5Y6mYozw2aj5KCJoA3m4heImceldzPSMbdyS4atVjJzXKMsfX3wnZTFYwkkt8/z8UesLHlSBQ== -"@algolia/logger-common@4.13.0": - version "4.13.0" - resolved "https://registry.yarnpkg.com/@algolia/logger-common/-/logger-common-4.13.0.tgz#be2606e71aae618a1ff1ea9a1b5f5a74284b35a8" - integrity sha512-8yqXk7rMtmQJ9wZiHOt/6d4/JDEg5VCk83gJ39I+X/pwUPzIsbKy9QiK4uJ3aJELKyoIiDT1hpYVt+5ia+94IA== +"@algolia/logger-common@4.13.1": + version "4.13.1" + resolved "https://registry.yarnpkg.com/@algolia/logger-common/-/logger-common-4.13.1.tgz#4221378e701e3f1eacaa051bcd4ba1f25ddfaf4d" + integrity sha512-L6slbL/OyZaAXNtS/1A8SAbOJeEXD5JcZeDCPYDqSTYScfHu+2ePRTDMgUTY4gQ7HsYZ39N1LujOd8WBTmM2Aw== -"@algolia/logger-console@4.13.0": - version "4.13.0" - resolved "https://registry.yarnpkg.com/@algolia/logger-console/-/logger-console-4.13.0.tgz#f28028a760e3d9191e28a10b12925e48f6c9afde" - integrity sha512-YepRg7w2/87L0vSXRfMND6VJ5d6699sFJBRWzZPOlek2p5fLxxK7O0VncYuc/IbVHEgeApvgXx0WgCEa38GVuQ== +"@algolia/logger-console@4.13.1": + version "4.13.1" + resolved "https://registry.yarnpkg.com/@algolia/logger-console/-/logger-console-4.13.1.tgz#423d358e4992dd4bceab0d9a4e99d1fd68107043" + integrity sha512-7jQOTftfeeLlnb3YqF8bNgA2GZht7rdKkJ31OCeSH2/61haO0tWPoNRjZq9XLlgMQZH276pPo0NdiArcYPHjCA== dependencies: - "@algolia/logger-common" "4.13.0" + "@algolia/logger-common" "4.13.1" -"@algolia/requester-browser-xhr@4.13.0": - version "4.13.0" - resolved "https://registry.yarnpkg.com/@algolia/requester-browser-xhr/-/requester-browser-xhr-4.13.0.tgz#e2483f4e8d7f09e27cd0daf6c77711d15c5a919f" - integrity sha512-Dj+bnoWR5MotrnjblzGKZ2kCdQi2cK/VzPURPnE616NU/il7Ypy6U6DLGZ/ZYz+tnwPa0yypNf21uqt84fOgrg== +"@algolia/requester-browser-xhr@4.13.1": + version "4.13.1" + resolved "https://registry.yarnpkg.com/@algolia/requester-browser-xhr/-/requester-browser-xhr-4.13.1.tgz#f8ea79233cf6f0392feaf31e35a6b40d68c5bc9e" + integrity sha512-oa0CKr1iH6Nc7CmU6RE7TnXMjHnlyp7S80pP/LvZVABeJHX3p/BcSCKovNYWWltgTxUg0U1o+2uuy8BpMKljwA== dependencies: - "@algolia/requester-common" "4.13.0" + "@algolia/requester-common" "4.13.1" -"@algolia/requester-common@4.13.0": - version "4.13.0" - resolved "https://registry.yarnpkg.com/@algolia/requester-common/-/requester-common-4.13.0.tgz#47fb3464cfb26b55ba43676d13f295d812830596" - integrity sha512-BRTDj53ecK+gn7ugukDWOOcBRul59C4NblCHqj4Zm5msd5UnHFjd/sGX+RLOEoFMhetILAnmg6wMrRrQVac9vw== +"@algolia/requester-common@4.13.1": + version "4.13.1" + resolved "https://registry.yarnpkg.com/@algolia/requester-common/-/requester-common-4.13.1.tgz#daea143d15ab6ed3909c4c45877f1b6c36a16179" + integrity sha512-eGVf0ID84apfFEuXsaoSgIxbU3oFsIbz4XiotU3VS8qGCJAaLVUC5BUJEkiFENZIhon7hIB4d0RI13HY4RSA+w== -"@algolia/requester-node-http@4.13.0": - version "4.13.0" - resolved "https://registry.yarnpkg.com/@algolia/requester-node-http/-/requester-node-http-4.13.0.tgz#7d981bbd31492f51dd11820a665f9d8906793c37" - integrity sha512-9b+3O4QFU4azLhGMrZAr/uZPydvzOR4aEZfSL8ZrpLZ7fbbqTO0S/5EVko+QIgglRAtVwxvf8UJ1wzTD2jvKxQ== +"@algolia/requester-node-http@4.13.1": + version "4.13.1" + resolved "https://registry.yarnpkg.com/@algolia/requester-node-http/-/requester-node-http-4.13.1.tgz#32c63d4c009f22d97e396406de7af9b66fb8e89d" + integrity sha512-7C0skwtLdCz5heKTVe/vjvrqgL/eJxmiEjHqXdtypcE5GCQCYI15cb+wC4ytYioZDMiuDGeVYmCYImPoEgUGPw== dependencies: - "@algolia/requester-common" "4.13.0" + "@algolia/requester-common" "4.13.1" -"@algolia/transporter@4.13.0": - version "4.13.0" - resolved "https://registry.yarnpkg.com/@algolia/transporter/-/transporter-4.13.0.tgz#f6379e5329efa2127da68c914d1141f5f21dbd07" - integrity sha512-8tSQYE+ykQENAdeZdofvtkOr5uJ9VcQSWgRhQ9h01AehtBIPAczk/b2CLrMsw5yQZziLs5cZ3pJ3478yI+urhA== +"@algolia/transporter@4.13.1": + version "4.13.1" + resolved "https://registry.yarnpkg.com/@algolia/transporter/-/transporter-4.13.1.tgz#509e03e9145102843d5be4a031c521f692d4e8d6" + integrity sha512-pICnNQN7TtrcYJqqPEXByV8rJ8ZRU2hCiIKLTLRyNpghtQG3VAFk6fVtdzlNfdUGZcehSKGarPIZEHlQXnKjgw== dependencies: - "@algolia/cache-common" "4.13.0" - "@algolia/logger-common" "4.13.0" - "@algolia/requester-common" "4.13.0" + "@algolia/cache-common" "4.13.1" + "@algolia/logger-common" "4.13.1" + "@algolia/requester-common" "4.13.1" "@ampproject/remapping@^2.1.0": version "2.2.0" @@ -147,22 +140,6 @@ jsonpointer "^5.0.0" leven "^3.1.0" -"@babel/cli@^7.17.10": - version "7.17.10" - resolved "https://registry.yarnpkg.com/@babel/cli/-/cli-7.17.10.tgz#5ea0bf6298bb78f3b59c7c06954f9bd1c79d5943" - integrity sha512-OygVO1M2J4yPMNOW9pb+I6kFGpQK77HmG44Oz3hg8xQIl5L/2zq+ZohwAdSaqYgVwM0SfmPHZHphH4wR8qzVYw== - dependencies: - "@jridgewell/trace-mapping" "^0.3.8" - commander "^4.0.1" - convert-source-map "^1.1.0" - fs-readdir-recursive "^1.1.0" - glob "^7.0.0" - make-dir "^2.1.0" - slash "^2.0.0" - optionalDependencies: - "@nicolo-ribaudo/chokidar-2" "2.1.8-no-fsevents.3" - chokidar "^3.4.0" - "@babel/code-frame@^7.0.0", "@babel/code-frame@^7.10.4", "@babel/code-frame@^7.12.13", "@babel/code-frame@^7.16.0", "@babel/code-frame@^7.16.7", "@babel/code-frame@^7.8.3": version "7.16.7" resolved "https://registry.yarnpkg.com/@babel/code-frame/-/code-frame-7.16.7.tgz#44416b6bd7624b998f5b1af5d470856c40138789" @@ -170,7 +147,7 @@ dependencies: "@babel/highlight" "^7.16.7" -"@babel/compat-data@^7.13.11", "@babel/compat-data@^7.17.0", "@babel/compat-data@^7.17.10": +"@babel/compat-data@^7.13.11", "@babel/compat-data@^7.17.10": version "7.17.10" resolved "https://registry.yarnpkg.com/@babel/compat-data/-/compat-data-7.17.10.tgz#711dc726a492dfc8be8220028b1b92482362baab" integrity sha512-GZt/TCsG70Ms19gfZO1tM4CVnXsPgEPBCpJu+Qz3L0LUDsY5nZqFZglIoPC1kIYOtNBZlrnFT+klg12vFGZXrw== @@ -197,21 +174,21 @@ semver "^5.4.1" source-map "^0.5.0" -"@babel/core@^7.11.1", "@babel/core@^7.11.6", "@babel/core@^7.12.3", "@babel/core@^7.13.16", "@babel/core@^7.15.5", "@babel/core@^7.17.10": - version "7.17.10" - resolved "https://registry.yarnpkg.com/@babel/core/-/core-7.17.10.tgz#74ef0fbf56b7dfc3f198fc2d927f4f03e12f4b05" - integrity sha512-liKoppandF3ZcBnIYFjfSDHZLKdLHGJRkoWtG8zQyGJBQfIYobpnVGI5+pLBNtS6psFLDzyq8+h5HiVljW9PNA== +"@babel/core@^7.11.1", "@babel/core@^7.11.6", "@babel/core@^7.12.3", "@babel/core@^7.13.16", "@babel/core@^7.15.5", "@babel/core@^7.18.0": + version "7.18.0" + resolved "https://registry.yarnpkg.com/@babel/core/-/core-7.18.0.tgz#c58d04d7c6fbfb58ea7681e2b9145cfb62726756" + integrity sha512-Xyw74OlJwDijToNi0+6BBI5mLLR5+5R3bcSH80LXzjzEGEUlvNzujEE71BaD/ApEZHAvFI/Mlmp4M5lIkdeeWw== dependencies: "@ampproject/remapping" "^2.1.0" "@babel/code-frame" "^7.16.7" - "@babel/generator" "^7.17.10" + "@babel/generator" "^7.18.0" "@babel/helper-compilation-targets" "^7.17.10" - "@babel/helper-module-transforms" "^7.17.7" - "@babel/helpers" "^7.17.9" - "@babel/parser" "^7.17.10" + "@babel/helper-module-transforms" "^7.18.0" + "@babel/helpers" "^7.18.0" + "@babel/parser" "^7.18.0" "@babel/template" "^7.16.7" - "@babel/traverse" "^7.17.10" - "@babel/types" "^7.17.10" + "@babel/traverse" "^7.18.0" + "@babel/types" "^7.18.0" convert-source-map "^1.7.0" debug "^4.1.0" gensync "^1.0.0-beta.2" @@ -227,13 +204,13 @@ eslint-visitor-keys "^2.1.0" semver "^6.3.0" -"@babel/generator@^7.12.5", "@babel/generator@^7.17.10", "@babel/generator@^7.7.2": - version "7.17.10" - resolved "https://registry.yarnpkg.com/@babel/generator/-/generator-7.17.10.tgz#c281fa35b0c349bbe9d02916f4ae08fc85ed7189" - integrity sha512-46MJZZo9y3o4kmhBVc7zW7i8dtR1oIK/sdO5NcfcZRhTGYi+KKJRtHNgsU6c4VUcJmUNV/LQdebD/9Dlv4K+Tg== +"@babel/generator@^7.12.5", "@babel/generator@^7.18.0", "@babel/generator@^7.7.2": + version "7.18.0" + resolved "https://registry.yarnpkg.com/@babel/generator/-/generator-7.18.0.tgz#46d28e8a18fc737b028efb25ab105d74473af43f" + integrity sha512-81YO9gGx6voPXlvYdZBliFXAZU8vZ9AZ6z+CjlmcnaeOcYSFbMTpdeDUO9xD9dh/68Vq03I8ZspfUTPfitcDHg== dependencies: - "@babel/types" "^7.17.10" - "@jridgewell/gen-mapping" "^0.1.0" + "@babel/types" "^7.18.0" + "@jridgewell/gen-mapping" "^0.3.0" jsesc "^2.5.1" "@babel/helper-annotate-as-pure@^7.16.7": @@ -261,10 +238,10 @@ browserslist "^4.20.2" semver "^6.3.0" -"@babel/helper-create-class-features-plugin@^7.16.10", "@babel/helper-create-class-features-plugin@^7.16.7", "@babel/helper-create-class-features-plugin@^7.17.6": - version "7.17.9" - resolved "https://registry.yarnpkg.com/@babel/helper-create-class-features-plugin/-/helper-create-class-features-plugin-7.17.9.tgz#71835d7fb9f38bd9f1378e40a4c0902fdc2ea49d" - integrity sha512-kUjip3gruz6AJKOq5i3nC6CoCEEF/oHH3cp6tOZhB+IyyyPyW0g1Gfsxn3mkk6S08pIA2y8GQh609v9G/5sHVQ== +"@babel/helper-create-class-features-plugin@^7.17.12", "@babel/helper-create-class-features-plugin@^7.18.0": + version "7.18.0" + resolved "https://registry.yarnpkg.com/@babel/helper-create-class-features-plugin/-/helper-create-class-features-plugin-7.18.0.tgz#fac430912606331cb075ea8d82f9a4c145a4da19" + integrity sha512-Kh8zTGR9de3J63e5nS0rQUdRs/kbtwoeQQ0sriS0lItjC96u8XXZN6lKpuyWd2coKSU13py/y+LTmThLuVX0Pg== dependencies: "@babel/helper-annotate-as-pure" "^7.16.7" "@babel/helper-environment-visitor" "^7.16.7" @@ -274,10 +251,10 @@ "@babel/helper-replace-supers" "^7.16.7" "@babel/helper-split-export-declaration" "^7.16.7" -"@babel/helper-create-regexp-features-plugin@^7.16.7", "@babel/helper-create-regexp-features-plugin@^7.17.0": - version "7.17.0" - resolved "https://registry.yarnpkg.com/@babel/helper-create-regexp-features-plugin/-/helper-create-regexp-features-plugin-7.17.0.tgz#1dcc7d40ba0c6b6b25618997c5dbfd310f186fe1" - integrity sha512-awO2So99wG6KnlE+TPs6rn83gCz5WlEePJDTnLEqbchMVrBeAujURVphRdigsk094VhvZehFoNOihSlcBjwsXA== +"@babel/helper-create-regexp-features-plugin@^7.16.7", "@babel/helper-create-regexp-features-plugin@^7.17.12": + version "7.17.12" + resolved "https://registry.yarnpkg.com/@babel/helper-create-regexp-features-plugin/-/helper-create-regexp-features-plugin-7.17.12.tgz#bb37ca467f9694bbe55b884ae7a5cc1e0084e4fd" + integrity sha512-b2aZrV4zvutr9AIa6/gA3wsZKRwTKYoDxYiFKcESS3Ug2GTXzwBEvMuuFLhCQpEnRXs1zng4ISAXSUxxKBIcxw== dependencies: "@babel/helper-annotate-as-pure" "^7.16.7" regexpu-core "^5.0.1" @@ -339,10 +316,10 @@ dependencies: "@babel/types" "^7.16.7" -"@babel/helper-module-transforms@^7.12.1", "@babel/helper-module-transforms@^7.16.7", "@babel/helper-module-transforms@^7.17.7": - version "7.17.7" - resolved "https://registry.yarnpkg.com/@babel/helper-module-transforms/-/helper-module-transforms-7.17.7.tgz#3943c7f777139e7954a5355c815263741a9c1cbd" - integrity sha512-VmZD99F3gNTYB7fJRDTi+u6l/zxY0BE6OIxPSU7a50s6ZUQkHwSDmV92FfM+oCG0pZRVojGYhkR8I0OGeCVREw== +"@babel/helper-module-transforms@^7.12.1", "@babel/helper-module-transforms@^7.18.0": + version "7.18.0" + resolved "https://registry.yarnpkg.com/@babel/helper-module-transforms/-/helper-module-transforms-7.18.0.tgz#baf05dec7a5875fb9235bd34ca18bad4e21221cd" + integrity sha512-kclUYSUBIjlvnzN2++K9f2qzYKFgjmnmjwL4zlmU5f8ZtzgWe8s0rUPSTGy2HmK4P8T52MQsS+HTQAgZd3dMEA== dependencies: "@babel/helper-environment-visitor" "^7.16.7" "@babel/helper-module-imports" "^7.16.7" @@ -350,8 +327,8 @@ "@babel/helper-split-export-declaration" "^7.16.7" "@babel/helper-validator-identifier" "^7.16.7" "@babel/template" "^7.16.7" - "@babel/traverse" "^7.17.3" - "@babel/types" "^7.17.0" + "@babel/traverse" "^7.18.0" + "@babel/types" "^7.18.0" "@babel/helper-optimise-call-expression@^7.16.7": version "7.16.7" @@ -365,10 +342,10 @@ resolved "https://registry.yarnpkg.com/@babel/helper-plugin-utils/-/helper-plugin-utils-7.10.4.tgz#2f75a831269d4f677de49986dff59927533cf375" integrity sha512-O4KCvQA6lLiMU9l2eawBPMf1xPP8xPfB3iEQw150hOVTqj/rfXz0ThTb4HEzqQfs2Bmo5Ay8BzxfzVtBrr9dVg== -"@babel/helper-plugin-utils@^7.0.0", "@babel/helper-plugin-utils@^7.10.4", "@babel/helper-plugin-utils@^7.12.13", "@babel/helper-plugin-utils@^7.13.0", "@babel/helper-plugin-utils@^7.14.5", "@babel/helper-plugin-utils@^7.16.7", "@babel/helper-plugin-utils@^7.8.0", "@babel/helper-plugin-utils@^7.8.3": - version "7.16.7" - resolved "https://registry.yarnpkg.com/@babel/helper-plugin-utils/-/helper-plugin-utils-7.16.7.tgz#aa3a8ab4c3cceff8e65eb9e73d87dc4ff320b2f5" - integrity sha512-Qg3Nk7ZxpgMrsox6HreY1ZNKdBq7K72tDSliA6dCl5f007jR4ne8iD5UzuNnCJH2xBf2BEEVGr+/OL6Gdp7RxA== +"@babel/helper-plugin-utils@^7.0.0", "@babel/helper-plugin-utils@^7.10.4", "@babel/helper-plugin-utils@^7.12.13", "@babel/helper-plugin-utils@^7.13.0", "@babel/helper-plugin-utils@^7.14.5", "@babel/helper-plugin-utils@^7.16.7", "@babel/helper-plugin-utils@^7.17.12", "@babel/helper-plugin-utils@^7.8.0", "@babel/helper-plugin-utils@^7.8.3": + version "7.17.12" + resolved "https://registry.yarnpkg.com/@babel/helper-plugin-utils/-/helper-plugin-utils-7.17.12.tgz#86c2347da5acbf5583ba0a10aed4c9bf9da9cf96" + integrity sha512-JDkf04mqtN3y4iAbO1hv9U2ARpPyPL1zqyWs/2WG1pgSq9llHFjStX5jdxb84himgJm+8Ng+x0oiWF/nw/XQKA== "@babel/helper-remap-async-to-generator@^7.16.8": version "7.16.8" @@ -431,69 +408,69 @@ "@babel/traverse" "^7.16.8" "@babel/types" "^7.16.8" -"@babel/helpers@^7.12.5", "@babel/helpers@^7.17.9": - version "7.17.9" - resolved "https://registry.yarnpkg.com/@babel/helpers/-/helpers-7.17.9.tgz#b2af120821bfbe44f9907b1826e168e819375a1a" - integrity sha512-cPCt915ShDWUEzEp3+UNRktO2n6v49l5RSnG9M5pS24hA+2FAc5si+Pn1i4VVbQQ+jh+bIZhPFQOJOzbrOYY1Q== +"@babel/helpers@^7.12.5", "@babel/helpers@^7.18.0": + version "7.18.0" + resolved "https://registry.yarnpkg.com/@babel/helpers/-/helpers-7.18.0.tgz#aff37c3590de42102b54842446146d0205946370" + integrity sha512-AE+HMYhmlMIbho9nbvicHyxFwhrO+xhKB6AhRxzl8w46Yj0VXTZjEsAoBVC7rB2I0jzX+yWyVybnO08qkfx6kg== dependencies: "@babel/template" "^7.16.7" - "@babel/traverse" "^7.17.9" - "@babel/types" "^7.17.0" + "@babel/traverse" "^7.18.0" + "@babel/types" "^7.18.0" "@babel/highlight@^7.16.7": - version "7.17.9" - resolved "https://registry.yarnpkg.com/@babel/highlight/-/highlight-7.17.9.tgz#61b2ee7f32ea0454612def4fccdae0de232b73e3" - integrity sha512-J9PfEKCbFIv2X5bjTMiZu6Vf341N05QIY+d6FvVKynkG1S7G0j3I0QoRtWIrXhZ+/Nlb5Q0MzqL7TokEJ5BNHg== + version "7.17.12" + resolved "https://registry.yarnpkg.com/@babel/highlight/-/highlight-7.17.12.tgz#257de56ee5afbd20451ac0a75686b6b404257351" + integrity sha512-7yykMVF3hfZY2jsHZEEgLc+3x4o1O+fYyULu11GynEUQNwB6lua+IIQn1FiJxNucd5UlyJryrwsOh8PL9Sn8Qg== dependencies: "@babel/helper-validator-identifier" "^7.16.7" chalk "^2.0.0" js-tokens "^4.0.0" -"@babel/parser@^7.1.0", "@babel/parser@^7.12.7", "@babel/parser@^7.13.16", "@babel/parser@^7.14.7", "@babel/parser@^7.16.7", "@babel/parser@^7.17.10": - version "7.17.10" - resolved "https://registry.yarnpkg.com/@babel/parser/-/parser-7.17.10.tgz#873b16db82a8909e0fbd7f115772f4b739f6ce78" - integrity sha512-n2Q6i+fnJqzOaq2VkdXxy2TCPCWQZHiCo0XqmrCvDWcZQKRyZzYi4Z0yxlBuN0w+r2ZHmre+Q087DSrw3pbJDQ== +"@babel/parser@^7.1.0", "@babel/parser@^7.12.7", "@babel/parser@^7.13.16", "@babel/parser@^7.14.7", "@babel/parser@^7.16.7", "@babel/parser@^7.18.0": + version "7.18.0" + resolved "https://registry.yarnpkg.com/@babel/parser/-/parser-7.18.0.tgz#10a8d4e656bc01128d299a787aa006ce1a91e112" + integrity sha512-AqDccGC+m5O/iUStSJy3DGRIUFu7WbY/CppZYwrEUB4N0tZlnI8CSTsgL7v5fHVFmUbRv2sd+yy27o8Ydt4MGg== -"@babel/plugin-bugfix-safari-id-destructuring-collision-in-function-expression@^7.16.7": - version "7.16.7" - resolved "https://registry.yarnpkg.com/@babel/plugin-bugfix-safari-id-destructuring-collision-in-function-expression/-/plugin-bugfix-safari-id-destructuring-collision-in-function-expression-7.16.7.tgz#4eda6d6c2a0aa79c70fa7b6da67763dfe2141050" - integrity sha512-anv/DObl7waiGEnC24O9zqL0pSuI9hljihqiDuFHC8d7/bjr/4RLGPWuc8rYOff/QPzbEPSkzG8wGG9aDuhHRg== +"@babel/plugin-bugfix-safari-id-destructuring-collision-in-function-expression@^7.17.12": + version "7.17.12" + resolved "https://registry.yarnpkg.com/@babel/plugin-bugfix-safari-id-destructuring-collision-in-function-expression/-/plugin-bugfix-safari-id-destructuring-collision-in-function-expression-7.17.12.tgz#1dca338caaefca368639c9ffb095afbd4d420b1e" + integrity sha512-xCJQXl4EeQ3J9C4yOmpTrtVGmzpm2iSzyxbkZHw7UCnZBftHpF/hpII80uWVyVrc40ytIClHjgWGTG1g/yB+aw== dependencies: - "@babel/helper-plugin-utils" "^7.16.7" + "@babel/helper-plugin-utils" "^7.17.12" -"@babel/plugin-bugfix-v8-spread-parameters-in-optional-chaining@^7.16.7": - version "7.16.7" - resolved "https://registry.yarnpkg.com/@babel/plugin-bugfix-v8-spread-parameters-in-optional-chaining/-/plugin-bugfix-v8-spread-parameters-in-optional-chaining-7.16.7.tgz#cc001234dfc139ac45f6bcf801866198c8c72ff9" - integrity sha512-di8vUHRdf+4aJ7ltXhaDbPoszdkh59AQtJM5soLsuHpQJdFQZOA4uGj0V2u/CZ8bJ/u8ULDL5yq6FO/bCXnKHw== +"@babel/plugin-bugfix-v8-spread-parameters-in-optional-chaining@^7.17.12": + version "7.17.12" + resolved "https://registry.yarnpkg.com/@babel/plugin-bugfix-v8-spread-parameters-in-optional-chaining/-/plugin-bugfix-v8-spread-parameters-in-optional-chaining-7.17.12.tgz#0d498ec8f0374b1e2eb54b9cb2c4c78714c77753" + integrity sha512-/vt0hpIw0x4b6BLKUkwlvEoiGZYYLNZ96CzyHYPbtG2jZGz6LBe7/V+drYrc/d+ovrF9NBi0pmtvmNb/FsWtRQ== dependencies: - "@babel/helper-plugin-utils" "^7.16.7" + "@babel/helper-plugin-utils" "^7.17.12" "@babel/helper-skip-transparent-expression-wrappers" "^7.16.0" - "@babel/plugin-proposal-optional-chaining" "^7.16.7" + "@babel/plugin-proposal-optional-chaining" "^7.17.12" -"@babel/plugin-proposal-async-generator-functions@^7.16.8": - version "7.16.8" - resolved "https://registry.yarnpkg.com/@babel/plugin-proposal-async-generator-functions/-/plugin-proposal-async-generator-functions-7.16.8.tgz#3bdd1ebbe620804ea9416706cd67d60787504bc8" - integrity sha512-71YHIvMuiuqWJQkebWJtdhQTfd4Q4mF76q2IX37uZPkG9+olBxsX+rH1vkhFto4UeJZ9dPY2s+mDvhDm1u2BGQ== +"@babel/plugin-proposal-async-generator-functions@^7.17.12": + version "7.17.12" + resolved "https://registry.yarnpkg.com/@babel/plugin-proposal-async-generator-functions/-/plugin-proposal-async-generator-functions-7.17.12.tgz#094a417e31ce7e692d84bab06c8e2a607cbeef03" + integrity sha512-RWVvqD1ooLKP6IqWTA5GyFVX2isGEgC5iFxKzfYOIy/QEFdxYyCybBDtIGjipHpb9bDWHzcqGqFakf+mVmBTdQ== dependencies: - "@babel/helper-plugin-utils" "^7.16.7" + "@babel/helper-plugin-utils" "^7.17.12" "@babel/helper-remap-async-to-generator" "^7.16.8" "@babel/plugin-syntax-async-generators" "^7.8.4" -"@babel/plugin-proposal-class-properties@^7.13.0", "@babel/plugin-proposal-class-properties@^7.16.7": - version "7.16.7" - resolved "https://registry.yarnpkg.com/@babel/plugin-proposal-class-properties/-/plugin-proposal-class-properties-7.16.7.tgz#925cad7b3b1a2fcea7e59ecc8eb5954f961f91b0" - integrity sha512-IobU0Xme31ewjYOShSIqd/ZGM/r/cuOz2z0MDbNrhF5FW+ZVgi0f2lyeoj9KFPDOAqsYxmLWZte1WOwlvY9aww== +"@babel/plugin-proposal-class-properties@^7.13.0", "@babel/plugin-proposal-class-properties@^7.17.12": + version "7.17.12" + resolved "https://registry.yarnpkg.com/@babel/plugin-proposal-class-properties/-/plugin-proposal-class-properties-7.17.12.tgz#84f65c0cc247d46f40a6da99aadd6438315d80a4" + integrity sha512-U0mI9q8pW5Q9EaTHFPwSVusPMV/DV9Mm8p7csqROFLtIE9rBF5piLqyrBGigftALrBcsBGu4m38JneAe7ZDLXw== dependencies: - "@babel/helper-create-class-features-plugin" "^7.16.7" - "@babel/helper-plugin-utils" "^7.16.7" + "@babel/helper-create-class-features-plugin" "^7.17.12" + "@babel/helper-plugin-utils" "^7.17.12" -"@babel/plugin-proposal-class-static-block@^7.17.6": - version "7.17.6" - resolved "https://registry.yarnpkg.com/@babel/plugin-proposal-class-static-block/-/plugin-proposal-class-static-block-7.17.6.tgz#164e8fd25f0d80fa48c5a4d1438a6629325ad83c" - integrity sha512-X/tididvL2zbs7jZCeeRJ8167U/+Ac135AM6jCAx6gYXDUviZV5Ku9UDvWS2NCuWlFjIRXklYhwo6HhAC7ETnA== +"@babel/plugin-proposal-class-static-block@^7.18.0": + version "7.18.0" + resolved "https://registry.yarnpkg.com/@babel/plugin-proposal-class-static-block/-/plugin-proposal-class-static-block-7.18.0.tgz#7d02253156e3c3793bdb9f2faac3a1c05f0ba710" + integrity sha512-t+8LsRMMDE74c6sV7KShIw13sqbqd58tlqNrsWoWBTIMw7SVQ0cZ905wLNS/FBCy/3PyooRHLFFlfrUNyyz5lA== dependencies: - "@babel/helper-create-class-features-plugin" "^7.17.6" - "@babel/helper-plugin-utils" "^7.16.7" + "@babel/helper-create-class-features-plugin" "^7.18.0" + "@babel/helper-plugin-utils" "^7.17.12" "@babel/plugin-syntax-class-static-block" "^7.14.5" "@babel/plugin-proposal-dynamic-import@^7.16.7": @@ -504,36 +481,36 @@ "@babel/helper-plugin-utils" "^7.16.7" "@babel/plugin-syntax-dynamic-import" "^7.8.3" -"@babel/plugin-proposal-export-namespace-from@^7.16.7": - version "7.16.7" - resolved "https://registry.yarnpkg.com/@babel/plugin-proposal-export-namespace-from/-/plugin-proposal-export-namespace-from-7.16.7.tgz#09de09df18445a5786a305681423ae63507a6163" - integrity sha512-ZxdtqDXLRGBL64ocZcs7ovt71L3jhC1RGSyR996svrCi3PYqHNkb3SwPJCs8RIzD86s+WPpt2S73+EHCGO+NUA== +"@babel/plugin-proposal-export-namespace-from@^7.17.12": + version "7.17.12" + resolved "https://registry.yarnpkg.com/@babel/plugin-proposal-export-namespace-from/-/plugin-proposal-export-namespace-from-7.17.12.tgz#b22864ccd662db9606edb2287ea5fd1709f05378" + integrity sha512-j7Ye5EWdwoXOpRmo5QmRyHPsDIe6+u70ZYZrd7uz+ebPYFKfRcLcNu3Ro0vOlJ5zuv8rU7xa+GttNiRzX56snQ== dependencies: - "@babel/helper-plugin-utils" "^7.16.7" + "@babel/helper-plugin-utils" "^7.17.12" "@babel/plugin-syntax-export-namespace-from" "^7.8.3" -"@babel/plugin-proposal-json-strings@^7.16.7": - version "7.16.7" - resolved "https://registry.yarnpkg.com/@babel/plugin-proposal-json-strings/-/plugin-proposal-json-strings-7.16.7.tgz#9732cb1d17d9a2626a08c5be25186c195b6fa6e8" - integrity sha512-lNZ3EEggsGY78JavgbHsK9u5P3pQaW7k4axlgFLYkMd7UBsiNahCITShLjNQschPyjtO6dADrL24757IdhBrsQ== +"@babel/plugin-proposal-json-strings@^7.17.12": + version "7.17.12" + resolved "https://registry.yarnpkg.com/@babel/plugin-proposal-json-strings/-/plugin-proposal-json-strings-7.17.12.tgz#f4642951792437233216d8c1af370bb0fbff4664" + integrity sha512-rKJ+rKBoXwLnIn7n6o6fulViHMrOThz99ybH+hKHcOZbnN14VuMnH9fo2eHE69C8pO4uX1Q7t2HYYIDmv8VYkg== dependencies: - "@babel/helper-plugin-utils" "^7.16.7" + "@babel/helper-plugin-utils" "^7.17.12" "@babel/plugin-syntax-json-strings" "^7.8.3" -"@babel/plugin-proposal-logical-assignment-operators@^7.16.7": - version "7.16.7" - resolved "https://registry.yarnpkg.com/@babel/plugin-proposal-logical-assignment-operators/-/plugin-proposal-logical-assignment-operators-7.16.7.tgz#be23c0ba74deec1922e639832904be0bea73cdea" - integrity sha512-K3XzyZJGQCr00+EtYtrDjmwX7o7PLK6U9bi1nCwkQioRFVUv6dJoxbQjtWVtP+bCPy82bONBKG8NPyQ4+i6yjg== +"@babel/plugin-proposal-logical-assignment-operators@^7.17.12": + version "7.17.12" + resolved "https://registry.yarnpkg.com/@babel/plugin-proposal-logical-assignment-operators/-/plugin-proposal-logical-assignment-operators-7.17.12.tgz#c64a1bcb2b0a6d0ed2ff674fd120f90ee4b88a23" + integrity sha512-EqFo2s1Z5yy+JeJu7SFfbIUtToJTVlC61/C7WLKDntSw4Sz6JNAIfL7zQ74VvirxpjB5kz/kIx0gCcb+5OEo2Q== dependencies: - "@babel/helper-plugin-utils" "^7.16.7" + "@babel/helper-plugin-utils" "^7.17.12" "@babel/plugin-syntax-logical-assignment-operators" "^7.10.4" -"@babel/plugin-proposal-nullish-coalescing-operator@^7.13.8", "@babel/plugin-proposal-nullish-coalescing-operator@^7.16.7": - version "7.16.7" - resolved "https://registry.yarnpkg.com/@babel/plugin-proposal-nullish-coalescing-operator/-/plugin-proposal-nullish-coalescing-operator-7.16.7.tgz#141fc20b6857e59459d430c850a0011e36561d99" - integrity sha512-aUOrYU3EVtjf62jQrCj63pYZ7k6vns2h/DQvHPWGmsJRYzWXZ6/AsfgpiRy6XiuIDADhJzP2Q9MwSMKauBQ+UQ== +"@babel/plugin-proposal-nullish-coalescing-operator@^7.13.8", "@babel/plugin-proposal-nullish-coalescing-operator@^7.17.12": + version "7.17.12" + resolved "https://registry.yarnpkg.com/@babel/plugin-proposal-nullish-coalescing-operator/-/plugin-proposal-nullish-coalescing-operator-7.17.12.tgz#1e93079bbc2cbc756f6db6a1925157c4a92b94be" + integrity sha512-ws/g3FSGVzv+VH86+QvgtuJL/kR67xaEIF2x0iPqdDfYW6ra6JF3lKVBkWynRLcNtIC1oCTfDRVxmm2mKzy+ag== dependencies: - "@babel/helper-plugin-utils" "^7.16.7" + "@babel/helper-plugin-utils" "^7.17.12" "@babel/plugin-syntax-nullish-coalescing-operator" "^7.8.3" "@babel/plugin-proposal-numeric-separator@^7.16.7": @@ -553,16 +530,16 @@ "@babel/plugin-syntax-object-rest-spread" "^7.8.0" "@babel/plugin-transform-parameters" "^7.12.1" -"@babel/plugin-proposal-object-rest-spread@^7.17.3": - version "7.17.3" - resolved "https://registry.yarnpkg.com/@babel/plugin-proposal-object-rest-spread/-/plugin-proposal-object-rest-spread-7.17.3.tgz#d9eb649a54628a51701aef7e0ea3d17e2b9dd390" - integrity sha512-yuL5iQA/TbZn+RGAfxQXfi7CNLmKi1f8zInn4IgobuCWcAb7i+zj4TYzQ9l8cEzVyJ89PDGuqxK1xZpUDISesw== +"@babel/plugin-proposal-object-rest-spread@^7.18.0": + version "7.18.0" + resolved "https://registry.yarnpkg.com/@babel/plugin-proposal-object-rest-spread/-/plugin-proposal-object-rest-spread-7.18.0.tgz#79f2390c892ba2a68ec112eb0d895cfbd11155e8" + integrity sha512-nbTv371eTrFabDfHLElkn9oyf9VG+VKK6WMzhY2o4eHKaG19BToD9947zzGMO6I/Irstx9d8CwX6njPNIAR/yw== dependencies: - "@babel/compat-data" "^7.17.0" - "@babel/helper-compilation-targets" "^7.16.7" - "@babel/helper-plugin-utils" "^7.16.7" + "@babel/compat-data" "^7.17.10" + "@babel/helper-compilation-targets" "^7.17.10" + "@babel/helper-plugin-utils" "^7.17.12" "@babel/plugin-syntax-object-rest-spread" "^7.8.3" - "@babel/plugin-transform-parameters" "^7.16.7" + "@babel/plugin-transform-parameters" "^7.17.12" "@babel/plugin-proposal-optional-catch-binding@^7.16.7": version "7.16.7" @@ -572,40 +549,40 @@ "@babel/helper-plugin-utils" "^7.16.7" "@babel/plugin-syntax-optional-catch-binding" "^7.8.3" -"@babel/plugin-proposal-optional-chaining@^7.13.12", "@babel/plugin-proposal-optional-chaining@^7.16.7": - version "7.16.7" - resolved "https://registry.yarnpkg.com/@babel/plugin-proposal-optional-chaining/-/plugin-proposal-optional-chaining-7.16.7.tgz#7cd629564724816c0e8a969535551f943c64c39a" - integrity sha512-eC3xy+ZrUcBtP7x+sq62Q/HYd674pPTb/77XZMb5wbDPGWIdUbSr4Agr052+zaUPSb+gGRnjxXfKFvx5iMJ+DA== +"@babel/plugin-proposal-optional-chaining@^7.13.12", "@babel/plugin-proposal-optional-chaining@^7.17.12": + version "7.17.12" + resolved "https://registry.yarnpkg.com/@babel/plugin-proposal-optional-chaining/-/plugin-proposal-optional-chaining-7.17.12.tgz#f96949e9bacace3a9066323a5cf90cfb9de67174" + integrity sha512-7wigcOs/Z4YWlK7xxjkvaIw84vGhDv/P1dFGQap0nHkc8gFKY/r+hXc8Qzf5k1gY7CvGIcHqAnOagVKJJ1wVOQ== dependencies: - "@babel/helper-plugin-utils" "^7.16.7" + "@babel/helper-plugin-utils" "^7.17.12" "@babel/helper-skip-transparent-expression-wrappers" "^7.16.0" "@babel/plugin-syntax-optional-chaining" "^7.8.3" -"@babel/plugin-proposal-private-methods@^7.16.11": - version "7.16.11" - resolved "https://registry.yarnpkg.com/@babel/plugin-proposal-private-methods/-/plugin-proposal-private-methods-7.16.11.tgz#e8df108288555ff259f4527dbe84813aac3a1c50" - integrity sha512-F/2uAkPlXDr8+BHpZvo19w3hLFKge+k75XUprE6jaqKxjGkSYcK+4c+bup5PdW/7W/Rpjwql7FTVEDW+fRAQsw== +"@babel/plugin-proposal-private-methods@^7.17.12": + version "7.17.12" + resolved "https://registry.yarnpkg.com/@babel/plugin-proposal-private-methods/-/plugin-proposal-private-methods-7.17.12.tgz#c2ca3a80beb7539289938da005ad525a038a819c" + integrity sha512-SllXoxo19HmxhDWm3luPz+cPhtoTSKLJE9PXshsfrOzBqs60QP0r8OaJItrPhAj0d7mZMnNF0Y1UUggCDgMz1A== dependencies: - "@babel/helper-create-class-features-plugin" "^7.16.10" - "@babel/helper-plugin-utils" "^7.16.7" + "@babel/helper-create-class-features-plugin" "^7.17.12" + "@babel/helper-plugin-utils" "^7.17.12" -"@babel/plugin-proposal-private-property-in-object@^7.16.7": - version "7.16.7" - resolved "https://registry.yarnpkg.com/@babel/plugin-proposal-private-property-in-object/-/plugin-proposal-private-property-in-object-7.16.7.tgz#b0b8cef543c2c3d57e59e2c611994861d46a3fce" - integrity sha512-rMQkjcOFbm+ufe3bTZLyOfsOUOxyvLXZJCTARhJr+8UMSoZmqTe1K1BgkFcrW37rAchWg57yI69ORxiWvUINuQ== +"@babel/plugin-proposal-private-property-in-object@^7.17.12": + version "7.17.12" + resolved "https://registry.yarnpkg.com/@babel/plugin-proposal-private-property-in-object/-/plugin-proposal-private-property-in-object-7.17.12.tgz#b02efb7f106d544667d91ae97405a9fd8c93952d" + integrity sha512-/6BtVi57CJfrtDNKfK5b66ydK2J5pXUKBKSPD2G1whamMuEnZWgoOIfO8Vf9F/DoD4izBLD/Au4NMQfruzzykg== dependencies: "@babel/helper-annotate-as-pure" "^7.16.7" - "@babel/helper-create-class-features-plugin" "^7.16.7" - "@babel/helper-plugin-utils" "^7.16.7" + "@babel/helper-create-class-features-plugin" "^7.17.12" + "@babel/helper-plugin-utils" "^7.17.12" "@babel/plugin-syntax-private-property-in-object" "^7.14.5" -"@babel/plugin-proposal-unicode-property-regex@^7.16.7", "@babel/plugin-proposal-unicode-property-regex@^7.4.4": - version "7.16.7" - resolved "https://registry.yarnpkg.com/@babel/plugin-proposal-unicode-property-regex/-/plugin-proposal-unicode-property-regex-7.16.7.tgz#635d18eb10c6214210ffc5ff4932552de08188a2" - integrity sha512-QRK0YI/40VLhNVGIjRNAAQkEHws0cswSdFFjpFyt943YmJIU1da9uW63Iu6NFV6CxTZW5eTDCrwZUstBWgp/Rg== +"@babel/plugin-proposal-unicode-property-regex@^7.17.12", "@babel/plugin-proposal-unicode-property-regex@^7.4.4": + version "7.17.12" + resolved "https://registry.yarnpkg.com/@babel/plugin-proposal-unicode-property-regex/-/plugin-proposal-unicode-property-regex-7.17.12.tgz#3dbd7a67bd7f94c8238b394da112d86aaf32ad4d" + integrity sha512-Wb9qLjXf3ZazqXA7IvI7ozqRIXIGPtSo+L5coFmEkhTQK18ao4UDDD0zdTGAarmbLj2urpRwrc6893cu5Bfh0A== dependencies: - "@babel/helper-create-regexp-features-plugin" "^7.16.7" - "@babel/helper-plugin-utils" "^7.16.7" + "@babel/helper-create-regexp-features-plugin" "^7.17.12" + "@babel/helper-plugin-utils" "^7.17.12" "@babel/plugin-syntax-async-generators@^7.8.4": version "7.8.4" @@ -649,12 +626,19 @@ dependencies: "@babel/helper-plugin-utils" "^7.8.3" -"@babel/plugin-syntax-flow@^7.16.7": - version "7.16.7" - resolved "https://registry.yarnpkg.com/@babel/plugin-syntax-flow/-/plugin-syntax-flow-7.16.7.tgz#202b147e5892b8452bbb0bb269c7ed2539ab8832" - integrity sha512-UDo3YGQO0jH6ytzVwgSLv9i/CzMcUjbKenL67dTrAZPPv6GFAtDhe6jqnvmoKzC/7htNTohhos+onPtDMqJwaQ== +"@babel/plugin-syntax-flow@^7.17.12": + version "7.17.12" + resolved "https://registry.yarnpkg.com/@babel/plugin-syntax-flow/-/plugin-syntax-flow-7.17.12.tgz#23d852902acd19f42923fca9d0f196984d124e73" + integrity sha512-B8QIgBvkIG6G2jgsOHQUist7Sm0EBLDCx8sen072IwqNuzMegZNXrYnSv77cYzA8mLDZAfQYqsLIhimiP1s2HQ== dependencies: - "@babel/helper-plugin-utils" "^7.16.7" + "@babel/helper-plugin-utils" "^7.17.12" + +"@babel/plugin-syntax-import-assertions@^7.17.12": + version "7.17.12" + resolved "https://registry.yarnpkg.com/@babel/plugin-syntax-import-assertions/-/plugin-syntax-import-assertions-7.17.12.tgz#58096a92b11b2e4e54b24c6a0cc0e5e607abcedd" + integrity sha512-n/loy2zkq9ZEM8tEOwON9wTQSTNDTDEz6NujPtJGLU7qObzT1N4c4YZZf8E6ATB2AjNQg/Ib2AIpO03EZaCehw== + dependencies: + "@babel/helper-plugin-utils" "^7.17.12" "@babel/plugin-syntax-import-meta@^7.8.3": version "7.10.4" @@ -677,12 +661,12 @@ dependencies: "@babel/helper-plugin-utils" "^7.10.4" -"@babel/plugin-syntax-jsx@^7.16.7": - version "7.16.7" - resolved "https://registry.yarnpkg.com/@babel/plugin-syntax-jsx/-/plugin-syntax-jsx-7.16.7.tgz#50b6571d13f764266a113d77c82b4a6508bbe665" - integrity sha512-Esxmk7YjA8QysKeT3VhTXvF6y77f/a91SIs4pWb4H2eWGQkCKFgQaG6hdoEVZtGsrAcb2K5BW66XsOErD4WU3Q== +"@babel/plugin-syntax-jsx@^7.17.12": + version "7.17.12" + resolved "https://registry.yarnpkg.com/@babel/plugin-syntax-jsx/-/plugin-syntax-jsx-7.17.12.tgz#834035b45061983a491f60096f61a2e7c5674a47" + integrity sha512-spyY3E3AURfxh/RHtjx5j6hs8am5NbUBGfcZ2vB3uShSpZdQyXSf5rR5Mk76vbtlAZOelyVQ71Fg0x9SG4fsog== dependencies: - "@babel/helper-plugin-utils" "^7.16.7" + "@babel/helper-plugin-utils" "^7.17.12" "@babel/plugin-syntax-logical-assignment-operators@^7.10.4", "@babel/plugin-syntax-logical-assignment-operators@^7.8.3": version "7.10.4" @@ -740,27 +724,27 @@ dependencies: "@babel/helper-plugin-utils" "^7.14.5" -"@babel/plugin-syntax-typescript@^7.16.7", "@babel/plugin-syntax-typescript@^7.7.2": - version "7.17.10" - resolved "https://registry.yarnpkg.com/@babel/plugin-syntax-typescript/-/plugin-syntax-typescript-7.17.10.tgz#80031e6042cad6a95ed753f672ebd23c30933195" - integrity sha512-xJefea1DWXW09pW4Tm9bjwVlPDyYA2it3fWlmEjpYz6alPvTUjL0EOzNzI/FEOyI3r4/J7uVH5UqKgl1TQ5hqQ== +"@babel/plugin-syntax-typescript@^7.17.12", "@babel/plugin-syntax-typescript@^7.7.2": + version "7.17.12" + resolved "https://registry.yarnpkg.com/@babel/plugin-syntax-typescript/-/plugin-syntax-typescript-7.17.12.tgz#b54fc3be6de734a56b87508f99d6428b5b605a7b" + integrity sha512-TYY0SXFiO31YXtNg3HtFwNJHjLsAyIIhAhNWkQ5whPPS7HWUFlg9z0Ta4qAQNjQbP1wsSt/oKkmZ/4/WWdMUpw== dependencies: - "@babel/helper-plugin-utils" "^7.16.7" + "@babel/helper-plugin-utils" "^7.17.12" -"@babel/plugin-transform-arrow-functions@^7.16.7": - version "7.16.7" - resolved "https://registry.yarnpkg.com/@babel/plugin-transform-arrow-functions/-/plugin-transform-arrow-functions-7.16.7.tgz#44125e653d94b98db76369de9c396dc14bef4154" - integrity sha512-9ffkFFMbvzTvv+7dTp/66xvZAWASuPD5Tl9LK3Z9vhOmANo6j94rik+5YMBt4CwHVMWLWpMsriIc2zsa3WW3xQ== +"@babel/plugin-transform-arrow-functions@^7.17.12": + version "7.17.12" + resolved "https://registry.yarnpkg.com/@babel/plugin-transform-arrow-functions/-/plugin-transform-arrow-functions-7.17.12.tgz#dddd783b473b1b1537ef46423e3944ff24898c45" + integrity sha512-PHln3CNi/49V+mza4xMwrg+WGYevSF1oaiXaC2EQfdp4HWlSjRsrDXWJiQBKpP7749u6vQ9mcry2uuFOv5CXvA== dependencies: - "@babel/helper-plugin-utils" "^7.16.7" + "@babel/helper-plugin-utils" "^7.17.12" -"@babel/plugin-transform-async-to-generator@^7.16.8": - version "7.16.8" - resolved "https://registry.yarnpkg.com/@babel/plugin-transform-async-to-generator/-/plugin-transform-async-to-generator-7.16.8.tgz#b83dff4b970cf41f1b819f8b49cc0cfbaa53a808" - integrity sha512-MtmUmTJQHCnyJVrScNzNlofQJ3dLFuobYn3mwOTKHnSCMtbNsqvF71GQmJfFjdrXSsAA7iysFmYWw4bXZ20hOg== +"@babel/plugin-transform-async-to-generator@^7.17.12": + version "7.17.12" + resolved "https://registry.yarnpkg.com/@babel/plugin-transform-async-to-generator/-/plugin-transform-async-to-generator-7.17.12.tgz#dbe5511e6b01eee1496c944e35cdfe3f58050832" + integrity sha512-J8dbrWIOO3orDzir57NRsjg4uxucvhby0L/KZuGsWDj0g7twWK3g7JhJhOrXtuXiw8MeiSdJ3E0OW9H8LYEzLQ== dependencies: "@babel/helper-module-imports" "^7.16.7" - "@babel/helper-plugin-utils" "^7.16.7" + "@babel/helper-plugin-utils" "^7.17.12" "@babel/helper-remap-async-to-generator" "^7.16.8" "@babel/plugin-transform-block-scoped-functions@^7.16.7": @@ -770,40 +754,40 @@ dependencies: "@babel/helper-plugin-utils" "^7.16.7" -"@babel/plugin-transform-block-scoping@^7.16.7": - version "7.16.7" - resolved "https://registry.yarnpkg.com/@babel/plugin-transform-block-scoping/-/plugin-transform-block-scoping-7.16.7.tgz#f50664ab99ddeaee5bc681b8f3a6ea9d72ab4f87" - integrity sha512-ObZev2nxVAYA4bhyusELdo9hb3H+A56bxH3FZMbEImZFiEDYVHXQSJ1hQKFlDnlt8G9bBrCZ5ZpURZUrV4G5qQ== +"@babel/plugin-transform-block-scoping@^7.17.12": + version "7.17.12" + resolved "https://registry.yarnpkg.com/@babel/plugin-transform-block-scoping/-/plugin-transform-block-scoping-7.17.12.tgz#68fc3c4b3bb7dfd809d97b7ed19a584052a2725c" + integrity sha512-jw8XW/B1i7Lqwqj2CbrViPcZijSxfguBWZP2aN59NHgxUyO/OcO1mfdCxH13QhN5LbWhPkX+f+brKGhZTiqtZQ== dependencies: - "@babel/helper-plugin-utils" "^7.16.7" + "@babel/helper-plugin-utils" "^7.17.12" -"@babel/plugin-transform-classes@^7.16.7": - version "7.16.7" - resolved "https://registry.yarnpkg.com/@babel/plugin-transform-classes/-/plugin-transform-classes-7.16.7.tgz#8f4b9562850cd973de3b498f1218796eb181ce00" - integrity sha512-WY7og38SFAGYRe64BrjKf8OrE6ulEHtr5jEYaZMwox9KebgqPi67Zqz8K53EKk1fFEJgm96r32rkKZ3qA2nCWQ== +"@babel/plugin-transform-classes@^7.17.12": + version "7.17.12" + resolved "https://registry.yarnpkg.com/@babel/plugin-transform-classes/-/plugin-transform-classes-7.17.12.tgz#da889e89a4d38375eeb24985218edeab93af4f29" + integrity sha512-cvO7lc7pZat6BsvH6l/EGaI8zpl8paICaoGk+7x7guvtfak/TbIf66nYmJOH13EuG0H+Xx3M+9LQDtSvZFKXKw== dependencies: "@babel/helper-annotate-as-pure" "^7.16.7" "@babel/helper-environment-visitor" "^7.16.7" - "@babel/helper-function-name" "^7.16.7" + "@babel/helper-function-name" "^7.17.9" "@babel/helper-optimise-call-expression" "^7.16.7" - "@babel/helper-plugin-utils" "^7.16.7" + "@babel/helper-plugin-utils" "^7.17.12" "@babel/helper-replace-supers" "^7.16.7" "@babel/helper-split-export-declaration" "^7.16.7" globals "^11.1.0" -"@babel/plugin-transform-computed-properties@^7.16.7": - version "7.16.7" - resolved "https://registry.yarnpkg.com/@babel/plugin-transform-computed-properties/-/plugin-transform-computed-properties-7.16.7.tgz#66dee12e46f61d2aae7a73710f591eb3df616470" - integrity sha512-gN72G9bcmenVILj//sv1zLNaPyYcOzUho2lIJBMh/iakJ9ygCo/hEF9cpGb61SCMEDxbbyBoVQxrt+bWKu5KGw== +"@babel/plugin-transform-computed-properties@^7.17.12": + version "7.17.12" + resolved "https://registry.yarnpkg.com/@babel/plugin-transform-computed-properties/-/plugin-transform-computed-properties-7.17.12.tgz#bca616a83679698f3258e892ed422546e531387f" + integrity sha512-a7XINeplB5cQUWMg1E/GI1tFz3LfK021IjV1rj1ypE+R7jHm+pIHmHl25VNkZxtx9uuYp7ThGk8fur1HHG7PgQ== dependencies: - "@babel/helper-plugin-utils" "^7.16.7" + "@babel/helper-plugin-utils" "^7.17.12" -"@babel/plugin-transform-destructuring@^7.17.7": - version "7.17.7" - resolved "https://registry.yarnpkg.com/@babel/plugin-transform-destructuring/-/plugin-transform-destructuring-7.17.7.tgz#49dc2675a7afa9a5e4c6bdee636061136c3408d1" - integrity sha512-XVh0r5yq9sLR4vZ6eVZe8FKfIcSgaTBxVBRSYokRj2qksf6QerYnTxz9/GTuKTH/n/HwLP7t6gtlybHetJ/6hQ== +"@babel/plugin-transform-destructuring@^7.18.0": + version "7.18.0" + resolved "https://registry.yarnpkg.com/@babel/plugin-transform-destructuring/-/plugin-transform-destructuring-7.18.0.tgz#dc4f92587e291b4daa78aa20cc2d7a63aa11e858" + integrity sha512-Mo69klS79z6KEfrLg/1WkmVnB8javh75HX4pi2btjvlIoasuxilEyjtsQW6XPrubNd7AQy0MMaNIaQE4e7+PQw== dependencies: - "@babel/helper-plugin-utils" "^7.16.7" + "@babel/helper-plugin-utils" "^7.17.12" "@babel/plugin-transform-dotall-regex@^7.16.7", "@babel/plugin-transform-dotall-regex@^7.4.4": version "7.16.7" @@ -813,12 +797,12 @@ "@babel/helper-create-regexp-features-plugin" "^7.16.7" "@babel/helper-plugin-utils" "^7.16.7" -"@babel/plugin-transform-duplicate-keys@^7.16.7": - version "7.16.7" - resolved "https://registry.yarnpkg.com/@babel/plugin-transform-duplicate-keys/-/plugin-transform-duplicate-keys-7.16.7.tgz#2207e9ca8f82a0d36a5a67b6536e7ef8b08823c9" - integrity sha512-03DvpbRfvWIXyK0/6QiR1KMTWeT6OcQ7tbhjrXyFS02kjuX/mu5Bvnh5SDSWHxyawit2g5aWhKwI86EE7GUnTw== +"@babel/plugin-transform-duplicate-keys@^7.17.12": + version "7.17.12" + resolved "https://registry.yarnpkg.com/@babel/plugin-transform-duplicate-keys/-/plugin-transform-duplicate-keys-7.17.12.tgz#a09aa709a3310013f8e48e0e23bc7ace0f21477c" + integrity sha512-EA5eYFUG6xeerdabina/xIoB95jJ17mAkR8ivx6ZSu9frKShBjpOGZPn511MTDTkiCO+zXnzNczvUM69YSf3Zw== dependencies: - "@babel/helper-plugin-utils" "^7.16.7" + "@babel/helper-plugin-utils" "^7.17.12" "@babel/plugin-transform-exponentiation-operator@^7.16.7": version "7.16.7" @@ -828,20 +812,20 @@ "@babel/helper-builder-binary-assignment-operator-visitor" "^7.16.7" "@babel/helper-plugin-utils" "^7.16.7" -"@babel/plugin-transform-flow-strip-types@^7.16.7": - version "7.16.7" - resolved "https://registry.yarnpkg.com/@babel/plugin-transform-flow-strip-types/-/plugin-transform-flow-strip-types-7.16.7.tgz#291fb140c78dabbf87f2427e7c7c332b126964b8" - integrity sha512-mzmCq3cNsDpZZu9FADYYyfZJIOrSONmHcop2XEKPdBNMa4PDC4eEvcOvzZaCNcjKu72v0XQlA5y1g58aLRXdYg== +"@babel/plugin-transform-flow-strip-types@^7.17.12": + version "7.17.12" + resolved "https://registry.yarnpkg.com/@babel/plugin-transform-flow-strip-types/-/plugin-transform-flow-strip-types-7.17.12.tgz#5e070f99a4152194bd9275de140e83a92966cab3" + integrity sha512-g8cSNt+cHCpG/uunPQELdq/TeV3eg1OLJYwxypwHtAWo9+nErH3lQx9CSO2uI9lF74A0mR0t4KoMjs1snSgnTw== dependencies: - "@babel/helper-plugin-utils" "^7.16.7" - "@babel/plugin-syntax-flow" "^7.16.7" + "@babel/helper-plugin-utils" "^7.17.12" + "@babel/plugin-syntax-flow" "^7.17.12" -"@babel/plugin-transform-for-of@^7.16.7": - version "7.16.7" - resolved "https://registry.yarnpkg.com/@babel/plugin-transform-for-of/-/plugin-transform-for-of-7.16.7.tgz#649d639d4617dff502a9a158c479b3b556728d8c" - integrity sha512-/QZm9W92Ptpw7sjI9Nx1mbcsWz33+l8kuMIQnDwgQBG5s3fAfQvkRjQ7NqXhtNcKOnPkdICmUHyCaWW06HCsqg== +"@babel/plugin-transform-for-of@^7.17.12": + version "7.18.1" + resolved "https://registry.yarnpkg.com/@babel/plugin-transform-for-of/-/plugin-transform-for-of-7.18.1.tgz#ed14b657e162b72afbbb2b4cdad277bf2bb32036" + integrity sha512-+TTB5XwvJ5hZbO8xvl2H4XaMDOAK57zF4miuC9qQJgysPNEAZZ9Z69rdF5LJkozGdZrjBIUAIyKUWRMmebI7vg== dependencies: - "@babel/helper-plugin-utils" "^7.16.7" + "@babel/helper-plugin-utils" "^7.17.12" "@babel/plugin-transform-function-name@^7.16.7": version "7.16.7" @@ -852,12 +836,12 @@ "@babel/helper-function-name" "^7.16.7" "@babel/helper-plugin-utils" "^7.16.7" -"@babel/plugin-transform-literals@^7.16.7": - version "7.16.7" - resolved "https://registry.yarnpkg.com/@babel/plugin-transform-literals/-/plugin-transform-literals-7.16.7.tgz#254c9618c5ff749e87cb0c0cef1a0a050c0bdab1" - integrity sha512-6tH8RTpTWI0s2sV6uq3e/C9wPo4PTqqZps4uF0kzQ9/xPLFQtipynvmT1g/dOfEJ+0EQsHhkQ/zyRId8J2b8zQ== +"@babel/plugin-transform-literals@^7.17.12": + version "7.17.12" + resolved "https://registry.yarnpkg.com/@babel/plugin-transform-literals/-/plugin-transform-literals-7.17.12.tgz#97131fbc6bbb261487105b4b3edbf9ebf9c830ae" + integrity sha512-8iRkvaTjJciWycPIZ9k9duu663FT7VrBdNqNgxnVXEFwOIp55JWcZd23VBRySYbnS3PwQ3rGiabJBBBGj5APmQ== dependencies: - "@babel/helper-plugin-utils" "^7.16.7" + "@babel/helper-plugin-utils" "^7.17.12" "@babel/plugin-transform-member-expression-literals@^7.16.7": version "7.16.7" @@ -866,57 +850,58 @@ dependencies: "@babel/helper-plugin-utils" "^7.16.7" -"@babel/plugin-transform-modules-amd@^7.16.7": - version "7.16.7" - resolved "https://registry.yarnpkg.com/@babel/plugin-transform-modules-amd/-/plugin-transform-modules-amd-7.16.7.tgz#b28d323016a7daaae8609781d1f8c9da42b13186" - integrity sha512-KaaEtgBL7FKYwjJ/teH63oAmE3lP34N3kshz8mm4VMAw7U3PxjVwwUmxEFksbgsNUaO3wId9R2AVQYSEGRa2+g== +"@babel/plugin-transform-modules-amd@^7.18.0": + version "7.18.0" + resolved "https://registry.yarnpkg.com/@babel/plugin-transform-modules-amd/-/plugin-transform-modules-amd-7.18.0.tgz#7ef1002e67e36da3155edc8bf1ac9398064c02ed" + integrity sha512-h8FjOlYmdZwl7Xm2Ug4iX2j7Qy63NANI+NQVWQzv6r25fqgg7k2dZl03p95kvqNclglHs4FZ+isv4p1uXMA+QA== dependencies: - "@babel/helper-module-transforms" "^7.16.7" - "@babel/helper-plugin-utils" "^7.16.7" + "@babel/helper-module-transforms" "^7.18.0" + "@babel/helper-plugin-utils" "^7.17.12" babel-plugin-dynamic-import-node "^2.3.3" -"@babel/plugin-transform-modules-commonjs@^7.13.8", "@babel/plugin-transform-modules-commonjs@^7.17.9": - version "7.17.9" - resolved "https://registry.yarnpkg.com/@babel/plugin-transform-modules-commonjs/-/plugin-transform-modules-commonjs-7.17.9.tgz#274be1a2087beec0254d4abd4d86e52442e1e5b6" - integrity sha512-2TBFd/r2I6VlYn0YRTz2JdazS+FoUuQ2rIFHoAxtyP/0G3D82SBLaRq9rnUkpqlLg03Byfl/+M32mpxjO6KaPw== +"@babel/plugin-transform-modules-commonjs@^7.13.8", "@babel/plugin-transform-modules-commonjs@^7.18.0": + version "7.18.0" + resolved "https://registry.yarnpkg.com/@babel/plugin-transform-modules-commonjs/-/plugin-transform-modules-commonjs-7.18.0.tgz#3be575e19fbd273d42adbc84566b1fad3582b3db" + integrity sha512-cCeR0VZWtfxWS4YueAK2qtHtBPJRSaJcMlbS8jhSIm/A3E2Kpro4W1Dn4cqJtp59dtWfXjQwK7SPKF8ghs7rlw== dependencies: - "@babel/helper-module-transforms" "^7.17.7" - "@babel/helper-plugin-utils" "^7.16.7" + "@babel/helper-module-transforms" "^7.18.0" + "@babel/helper-plugin-utils" "^7.17.12" "@babel/helper-simple-access" "^7.17.7" babel-plugin-dynamic-import-node "^2.3.3" -"@babel/plugin-transform-modules-systemjs@^7.17.8": - version "7.17.8" - resolved "https://registry.yarnpkg.com/@babel/plugin-transform-modules-systemjs/-/plugin-transform-modules-systemjs-7.17.8.tgz#81fd834024fae14ea78fbe34168b042f38703859" - integrity sha512-39reIkMTUVagzgA5x88zDYXPCMT6lcaRKs1+S9K6NKBPErbgO/w/kP8GlNQTC87b412ZTlmNgr3k2JrWgHH+Bw== +"@babel/plugin-transform-modules-systemjs@^7.18.0": + version "7.18.0" + resolved "https://registry.yarnpkg.com/@babel/plugin-transform-modules-systemjs/-/plugin-transform-modules-systemjs-7.18.0.tgz#50ecdb43de97c8483824402f7125edb94cddb09a" + integrity sha512-vwKpxdHnlM5tIrRt/eA0bzfbi7gUBLN08vLu38np1nZevlPySRe6yvuATJB5F/WPJ+ur4OXwpVYq9+BsxqAQuQ== dependencies: "@babel/helper-hoist-variables" "^7.16.7" - "@babel/helper-module-transforms" "^7.17.7" - "@babel/helper-plugin-utils" "^7.16.7" + "@babel/helper-module-transforms" "^7.18.0" + "@babel/helper-plugin-utils" "^7.17.12" "@babel/helper-validator-identifier" "^7.16.7" babel-plugin-dynamic-import-node "^2.3.3" -"@babel/plugin-transform-modules-umd@^7.16.7": - version "7.16.7" - resolved "https://registry.yarnpkg.com/@babel/plugin-transform-modules-umd/-/plugin-transform-modules-umd-7.16.7.tgz#23dad479fa585283dbd22215bff12719171e7618" - integrity sha512-EMh7uolsC8O4xhudF2F6wedbSHm1HHZ0C6aJ7K67zcDNidMzVcxWdGr+htW9n21klm+bOn+Rx4CBsAntZd3rEQ== +"@babel/plugin-transform-modules-umd@^7.18.0": + version "7.18.0" + resolved "https://registry.yarnpkg.com/@babel/plugin-transform-modules-umd/-/plugin-transform-modules-umd-7.18.0.tgz#56aac64a2c2a1922341129a4597d1fd5c3ff020f" + integrity sha512-d/zZ8I3BWli1tmROLxXLc9A6YXvGK8egMxHp+E/rRwMh1Kip0AP77VwZae3snEJ33iiWwvNv2+UIIhfalqhzZA== dependencies: - "@babel/helper-module-transforms" "^7.16.7" - "@babel/helper-plugin-utils" "^7.16.7" + "@babel/helper-module-transforms" "^7.18.0" + "@babel/helper-plugin-utils" "^7.17.12" -"@babel/plugin-transform-named-capturing-groups-regex@^7.17.10": - version "7.17.10" - resolved "https://registry.yarnpkg.com/@babel/plugin-transform-named-capturing-groups-regex/-/plugin-transform-named-capturing-groups-regex-7.17.10.tgz#715dbcfafdb54ce8bccd3d12e8917296a4ba66a4" - integrity sha512-v54O6yLaJySCs6mGzaVOUw9T967GnH38T6CQSAtnzdNPwu84l2qAjssKzo/WSO8Yi7NF+7ekm5cVbF/5qiIgNA== +"@babel/plugin-transform-named-capturing-groups-regex@^7.17.12": + version "7.17.12" + resolved "https://registry.yarnpkg.com/@babel/plugin-transform-named-capturing-groups-regex/-/plugin-transform-named-capturing-groups-regex-7.17.12.tgz#9c4a5a5966e0434d515f2675c227fd8cc8606931" + integrity sha512-vWoWFM5CKaTeHrdUJ/3SIOTRV+MBVGybOC9mhJkaprGNt5demMymDW24yC74avb915/mIRe3TgNb/d8idvnCRA== dependencies: - "@babel/helper-create-regexp-features-plugin" "^7.17.0" + "@babel/helper-create-regexp-features-plugin" "^7.17.12" + "@babel/helper-plugin-utils" "^7.17.12" -"@babel/plugin-transform-new-target@^7.16.7": - version "7.16.7" - resolved "https://registry.yarnpkg.com/@babel/plugin-transform-new-target/-/plugin-transform-new-target-7.16.7.tgz#9967d89a5c243818e0800fdad89db22c5f514244" - integrity sha512-xiLDzWNMfKoGOpc6t3U+etCE2yRnn3SM09BXqWPIZOBpL2gvVrBWUKnsJx0K/ADi5F5YC5f8APFfWrz25TdlGg== +"@babel/plugin-transform-new-target@^7.17.12": + version "7.17.12" + resolved "https://registry.yarnpkg.com/@babel/plugin-transform-new-target/-/plugin-transform-new-target-7.17.12.tgz#10842cd605a620944e81ea6060e9e65c265742e3" + integrity sha512-CaOtzk2fDYisbjAD4Sd1MTKGVIpRtx9bWLyj24Y/k6p4s4gQ3CqDGJauFJxt8M/LEx003d0i3klVqnN73qvK3w== dependencies: - "@babel/helper-plugin-utils" "^7.16.7" + "@babel/helper-plugin-utils" "^7.17.12" "@babel/plugin-transform-object-super@^7.16.7": version "7.16.7" @@ -926,12 +911,12 @@ "@babel/helper-plugin-utils" "^7.16.7" "@babel/helper-replace-supers" "^7.16.7" -"@babel/plugin-transform-parameters@^7.12.1", "@babel/plugin-transform-parameters@^7.16.7": - version "7.16.7" - resolved "https://registry.yarnpkg.com/@babel/plugin-transform-parameters/-/plugin-transform-parameters-7.16.7.tgz#a1721f55b99b736511cb7e0152f61f17688f331f" - integrity sha512-AT3MufQ7zZEhU2hwOA11axBnExW0Lszu4RL/tAlUJBuNoRak+wehQW8h6KcXOcgjY42fHtDxswuMhMjFEuv/aw== +"@babel/plugin-transform-parameters@^7.12.1", "@babel/plugin-transform-parameters@^7.17.12": + version "7.17.12" + resolved "https://registry.yarnpkg.com/@babel/plugin-transform-parameters/-/plugin-transform-parameters-7.17.12.tgz#eb467cd9586ff5ff115a9880d6fdbd4a846b7766" + integrity sha512-6qW4rWo1cyCdq1FkYri7AHpauchbGLXpdwnYsfxFb+KtddHENfsY5JZb35xUwkK5opOLcJ3BNd2l7PhRYGlwIA== dependencies: - "@babel/helper-plugin-utils" "^7.16.7" + "@babel/helper-plugin-utils" "^7.17.12" "@babel/plugin-transform-property-literals@^7.16.7": version "7.16.7" @@ -941,11 +926,11 @@ "@babel/helper-plugin-utils" "^7.16.7" "@babel/plugin-transform-react-constant-elements@^7.14.5": - version "7.17.6" - resolved "https://registry.yarnpkg.com/@babel/plugin-transform-react-constant-elements/-/plugin-transform-react-constant-elements-7.17.6.tgz#6cc273c2f612a6a50cb657e63ee1303e5e68d10a" - integrity sha512-OBv9VkyyKtsHZiHLoSfCn+h6yU7YKX8nrs32xUmOa1SRSk+t03FosB6fBZ0Yz4BpD1WV7l73Nsad+2Tz7APpqw== + version "7.17.12" + resolved "https://registry.yarnpkg.com/@babel/plugin-transform-react-constant-elements/-/plugin-transform-react-constant-elements-7.17.12.tgz#cc580857696b6dd9e5e3d079e673d060a0657f37" + integrity sha512-maEkX2xs2STuv2Px8QuqxqjhV2LsFobT1elCgyU5704fcyTu9DyD/bJXxD/mrRiVyhpHweOQ00OJ5FKhHq9oEw== dependencies: - "@babel/helper-plugin-utils" "^7.16.7" + "@babel/helper-plugin-utils" "^7.17.12" "@babel/plugin-transform-react-display-name@^7.16.7": version "7.16.7" @@ -961,46 +946,47 @@ dependencies: "@babel/plugin-transform-react-jsx" "^7.16.7" -"@babel/plugin-transform-react-jsx@^7.16.7": - version "7.17.3" - resolved "https://registry.yarnpkg.com/@babel/plugin-transform-react-jsx/-/plugin-transform-react-jsx-7.17.3.tgz#eac1565da176ccb1a715dae0b4609858808008c1" - integrity sha512-9tjBm4O07f7mzKSIlEmPdiE6ub7kfIe6Cd+w+oQebpATfTQMAgW+YOuWxogbKVTulA+MEO7byMeIUtQ1z+z+ZQ== +"@babel/plugin-transform-react-jsx@^7.16.7", "@babel/plugin-transform-react-jsx@^7.17.12": + version "7.17.12" + resolved "https://registry.yarnpkg.com/@babel/plugin-transform-react-jsx/-/plugin-transform-react-jsx-7.17.12.tgz#2aa20022709cd6a3f40b45d60603d5f269586dba" + integrity sha512-Lcaw8bxd1DKht3thfD4A12dqo1X16he1Lm8rIv8sTwjAYNInRS1qHa9aJoqvzpscItXvftKDCfaEQzwoVyXpEQ== dependencies: "@babel/helper-annotate-as-pure" "^7.16.7" "@babel/helper-module-imports" "^7.16.7" - "@babel/helper-plugin-utils" "^7.16.7" - "@babel/plugin-syntax-jsx" "^7.16.7" - "@babel/types" "^7.17.0" + "@babel/helper-plugin-utils" "^7.17.12" + "@babel/plugin-syntax-jsx" "^7.17.12" + "@babel/types" "^7.17.12" "@babel/plugin-transform-react-pure-annotations@^7.16.7": - version "7.16.7" - resolved "https://registry.yarnpkg.com/@babel/plugin-transform-react-pure-annotations/-/plugin-transform-react-pure-annotations-7.16.7.tgz#232bfd2f12eb551d6d7d01d13fe3f86b45eb9c67" - integrity sha512-hs71ToC97k3QWxswh2ElzMFABXHvGiJ01IB1TbYQDGeWRKWz/MPUTh5jGExdHvosYKpnJW5Pm3S4+TA3FyX+GA== + version "7.18.0" + resolved "https://registry.yarnpkg.com/@babel/plugin-transform-react-pure-annotations/-/plugin-transform-react-pure-annotations-7.18.0.tgz#ef82c8e310913f3522462c9ac967d395092f1954" + integrity sha512-6+0IK6ouvqDn9bmEG7mEyF/pwlJXVj5lwydybpyyH3D0A7Hftk+NCTdYjnLNZksn261xaOV5ksmp20pQEmc2RQ== dependencies: "@babel/helper-annotate-as-pure" "^7.16.7" - "@babel/helper-plugin-utils" "^7.16.7" + "@babel/helper-plugin-utils" "^7.17.12" -"@babel/plugin-transform-regenerator@^7.17.9": - version "7.17.9" - resolved "https://registry.yarnpkg.com/@babel/plugin-transform-regenerator/-/plugin-transform-regenerator-7.17.9.tgz#0a33c3a61cf47f45ed3232903683a0afd2d3460c" - integrity sha512-Lc2TfbxR1HOyn/c6b4Y/b6NHoTb67n/IoWLxTu4kC7h4KQnWlhCq2S8Tx0t2SVvv5Uu87Hs+6JEJ5kt2tYGylQ== +"@babel/plugin-transform-regenerator@^7.18.0": + version "7.18.0" + resolved "https://registry.yarnpkg.com/@babel/plugin-transform-regenerator/-/plugin-transform-regenerator-7.18.0.tgz#44274d655eb3f1af3f3a574ba819d3f48caf99d5" + integrity sha512-C8YdRw9uzx25HSIzwA7EM7YP0FhCe5wNvJbZzjVNHHPGVcDJ3Aie+qGYYdS1oVQgn+B3eAIJbWFLrJ4Jipv7nw== dependencies: + "@babel/helper-plugin-utils" "^7.17.12" regenerator-transform "^0.15.0" -"@babel/plugin-transform-reserved-words@^7.16.7": - version "7.16.7" - resolved "https://registry.yarnpkg.com/@babel/plugin-transform-reserved-words/-/plugin-transform-reserved-words-7.16.7.tgz#1d798e078f7c5958eec952059c460b220a63f586" - integrity sha512-KQzzDnZ9hWQBjwi5lpY5v9shmm6IVG0U9pB18zvMu2i4H90xpT4gmqwPYsn8rObiadYe2M0gmgsiOIF5A/2rtg== +"@babel/plugin-transform-reserved-words@^7.17.12": + version "7.17.12" + resolved "https://registry.yarnpkg.com/@babel/plugin-transform-reserved-words/-/plugin-transform-reserved-words-7.17.12.tgz#7dbd349f3cdffba751e817cf40ca1386732f652f" + integrity sha512-1KYqwbJV3Co03NIi14uEHW8P50Md6KqFgt0FfpHdK6oyAHQVTosgPuPSiWud1HX0oYJ1hGRRlk0fP87jFpqXZA== dependencies: - "@babel/helper-plugin-utils" "^7.16.7" + "@babel/helper-plugin-utils" "^7.17.12" -"@babel/plugin-transform-runtime@^7.17.10": - version "7.17.10" - resolved "https://registry.yarnpkg.com/@babel/plugin-transform-runtime/-/plugin-transform-runtime-7.17.10.tgz#b89d821c55d61b5e3d3c3d1d636d8d5a81040ae1" - integrity sha512-6jrMilUAJhktTr56kACL8LnWC5hx3Lf27BS0R0DSyW/OoJfb/iTHeE96V3b1dgKG3FSFdd/0culnYWMkjcKCig== +"@babel/plugin-transform-runtime@^7.18.0": + version "7.18.0" + resolved "https://registry.yarnpkg.com/@babel/plugin-transform-runtime/-/plugin-transform-runtime-7.18.0.tgz#894cdab4b353dcb7639f03fb74c59db1d344f71c" + integrity sha512-7kM/jJ3DD/y1hDPn0jov12DoUIFsxLiItprhNydUSibxaywaxNqKwq+ODk72J9ePn4LWobIc5ik6TAJhVl8IkQ== dependencies: "@babel/helper-module-imports" "^7.16.7" - "@babel/helper-plugin-utils" "^7.16.7" + "@babel/helper-plugin-utils" "^7.17.12" babel-plugin-polyfill-corejs2 "^0.3.0" babel-plugin-polyfill-corejs3 "^0.5.0" babel-plugin-polyfill-regenerator "^0.3.0" @@ -1013,12 +999,12 @@ dependencies: "@babel/helper-plugin-utils" "^7.16.7" -"@babel/plugin-transform-spread@^7.16.7": - version "7.16.7" - resolved "https://registry.yarnpkg.com/@babel/plugin-transform-spread/-/plugin-transform-spread-7.16.7.tgz#a303e2122f9f12e0105daeedd0f30fb197d8ff44" - integrity sha512-+pjJpgAngb53L0iaA5gU/1MLXJIfXcYepLgXB3esVRf4fqmj8f2cxM3/FKaHsZms08hFQJkFccEWuIpm429TXg== +"@babel/plugin-transform-spread@^7.17.12": + version "7.17.12" + resolved "https://registry.yarnpkg.com/@babel/plugin-transform-spread/-/plugin-transform-spread-7.17.12.tgz#c112cad3064299f03ea32afed1d659223935d1f5" + integrity sha512-9pgmuQAtFi3lpNUstvG9nGfk9DkrdmWNp9KeKPFmuZCpEnxRzYlS8JgwPjYj+1AWDOSvoGN0H30p1cBOmT/Svg== dependencies: - "@babel/helper-plugin-utils" "^7.16.7" + "@babel/helper-plugin-utils" "^7.17.12" "@babel/helper-skip-transparent-expression-wrappers" "^7.16.0" "@babel/plugin-transform-sticky-regex@^7.16.7": @@ -1028,28 +1014,28 @@ dependencies: "@babel/helper-plugin-utils" "^7.16.7" -"@babel/plugin-transform-template-literals@^7.16.7": - version "7.16.7" - resolved "https://registry.yarnpkg.com/@babel/plugin-transform-template-literals/-/plugin-transform-template-literals-7.16.7.tgz#f3d1c45d28967c8e80f53666fc9c3e50618217ab" - integrity sha512-VwbkDDUeenlIjmfNeDX/V0aWrQH2QiVyJtwymVQSzItFDTpxfyJh3EVaQiS0rIN/CqbLGr0VcGmuwyTdZtdIsA== +"@babel/plugin-transform-template-literals@^7.17.12": + version "7.17.12" + resolved "https://registry.yarnpkg.com/@babel/plugin-transform-template-literals/-/plugin-transform-template-literals-7.17.12.tgz#4aec0a18f39dd86c442e1d077746df003e362c6e" + integrity sha512-kAKJ7DX1dSRa2s7WN1xUAuaQmkTpN+uig4wCKWivVXIObqGbVTUlSavHyfI2iZvz89GFAMGm9p2DBJ4Y1Tp0hw== dependencies: - "@babel/helper-plugin-utils" "^7.16.7" + "@babel/helper-plugin-utils" "^7.17.12" -"@babel/plugin-transform-typeof-symbol@^7.16.7": - version "7.16.7" - resolved "https://registry.yarnpkg.com/@babel/plugin-transform-typeof-symbol/-/plugin-transform-typeof-symbol-7.16.7.tgz#9cdbe622582c21368bd482b660ba87d5545d4f7e" - integrity sha512-p2rOixCKRJzpg9JB4gjnG4gjWkWa89ZoYUnl9snJ1cWIcTH/hvxZqfO+WjG6T8DRBpctEol5jw1O5rA8gkCokQ== +"@babel/plugin-transform-typeof-symbol@^7.17.12": + version "7.17.12" + resolved "https://registry.yarnpkg.com/@babel/plugin-transform-typeof-symbol/-/plugin-transform-typeof-symbol-7.17.12.tgz#0f12f57ac35e98b35b4ed34829948d42bd0e6889" + integrity sha512-Q8y+Jp7ZdtSPXCThB6zjQ74N3lj0f6TDh1Hnf5B+sYlzQ8i5Pjp8gW0My79iekSpT4WnI06blqP6DT0OmaXXmw== dependencies: - "@babel/helper-plugin-utils" "^7.16.7" + "@babel/helper-plugin-utils" "^7.17.12" -"@babel/plugin-transform-typescript@^7.16.7": - version "7.16.8" - resolved "https://registry.yarnpkg.com/@babel/plugin-transform-typescript/-/plugin-transform-typescript-7.16.8.tgz#591ce9b6b83504903fa9dd3652c357c2ba7a1ee0" - integrity sha512-bHdQ9k7YpBDO2d0NVfkj51DpQcvwIzIusJ7mEUaMlbZq3Kt/U47j24inXZHQ5MDiYpCs+oZiwnXyKedE8+q7AQ== +"@babel/plugin-transform-typescript@^7.17.12": + version "7.18.1" + resolved "https://registry.yarnpkg.com/@babel/plugin-transform-typescript/-/plugin-transform-typescript-7.18.1.tgz#5fd8b86130bad95c4a24377b41ab989a9ccad22d" + integrity sha512-F+RJmL479HJmC0KeqqwEGZMg1P7kWArLGbAKfEi9yPthJyMNjF+DjxFF/halfQvq1Q9GFM4TUbYDNV8xe4Ctqg== dependencies: - "@babel/helper-create-class-features-plugin" "^7.16.7" - "@babel/helper-plugin-utils" "^7.16.7" - "@babel/plugin-syntax-typescript" "^7.16.7" + "@babel/helper-create-class-features-plugin" "^7.18.0" + "@babel/helper-plugin-utils" "^7.17.12" + "@babel/plugin-syntax-typescript" "^7.17.12" "@babel/plugin-transform-unicode-escapes@^7.16.7": version "7.16.7" @@ -1066,37 +1052,38 @@ "@babel/helper-create-regexp-features-plugin" "^7.16.7" "@babel/helper-plugin-utils" "^7.16.7" -"@babel/preset-env@^7.11.0", "@babel/preset-env@^7.15.6", "@babel/preset-env@^7.17.10": - version "7.17.10" - resolved "https://registry.yarnpkg.com/@babel/preset-env/-/preset-env-7.17.10.tgz#a81b093669e3eb6541bb81a23173c5963c5de69c" - integrity sha512-YNgyBHZQpeoBSRBg0xixsZzfT58Ze1iZrajvv0lJc70qDDGuGfonEnMGfWeSY0mQ3JTuCWFbMkzFRVafOyJx4g== +"@babel/preset-env@^7.11.0", "@babel/preset-env@^7.15.6", "@babel/preset-env@^7.18.0": + version "7.18.0" + resolved "https://registry.yarnpkg.com/@babel/preset-env/-/preset-env-7.18.0.tgz#ec7e51f4c6e026816000b230ed7cf74a1530d91d" + integrity sha512-cP74OMs7ECLPeG1reiCQ/D/ypyOxgfm8uR6HRYV23vTJ7Lu1nbgj9DQDo/vH59gnn7GOAwtTDPPYV4aXzsMKHA== dependencies: "@babel/compat-data" "^7.17.10" "@babel/helper-compilation-targets" "^7.17.10" - "@babel/helper-plugin-utils" "^7.16.7" + "@babel/helper-plugin-utils" "^7.17.12" "@babel/helper-validator-option" "^7.16.7" - "@babel/plugin-bugfix-safari-id-destructuring-collision-in-function-expression" "^7.16.7" - "@babel/plugin-bugfix-v8-spread-parameters-in-optional-chaining" "^7.16.7" - "@babel/plugin-proposal-async-generator-functions" "^7.16.8" - "@babel/plugin-proposal-class-properties" "^7.16.7" - "@babel/plugin-proposal-class-static-block" "^7.17.6" + "@babel/plugin-bugfix-safari-id-destructuring-collision-in-function-expression" "^7.17.12" + "@babel/plugin-bugfix-v8-spread-parameters-in-optional-chaining" "^7.17.12" + "@babel/plugin-proposal-async-generator-functions" "^7.17.12" + "@babel/plugin-proposal-class-properties" "^7.17.12" + "@babel/plugin-proposal-class-static-block" "^7.18.0" "@babel/plugin-proposal-dynamic-import" "^7.16.7" - "@babel/plugin-proposal-export-namespace-from" "^7.16.7" - "@babel/plugin-proposal-json-strings" "^7.16.7" - "@babel/plugin-proposal-logical-assignment-operators" "^7.16.7" - "@babel/plugin-proposal-nullish-coalescing-operator" "^7.16.7" + "@babel/plugin-proposal-export-namespace-from" "^7.17.12" + "@babel/plugin-proposal-json-strings" "^7.17.12" + "@babel/plugin-proposal-logical-assignment-operators" "^7.17.12" + "@babel/plugin-proposal-nullish-coalescing-operator" "^7.17.12" "@babel/plugin-proposal-numeric-separator" "^7.16.7" - "@babel/plugin-proposal-object-rest-spread" "^7.17.3" + "@babel/plugin-proposal-object-rest-spread" "^7.18.0" "@babel/plugin-proposal-optional-catch-binding" "^7.16.7" - "@babel/plugin-proposal-optional-chaining" "^7.16.7" - "@babel/plugin-proposal-private-methods" "^7.16.11" - "@babel/plugin-proposal-private-property-in-object" "^7.16.7" - "@babel/plugin-proposal-unicode-property-regex" "^7.16.7" + "@babel/plugin-proposal-optional-chaining" "^7.17.12" + "@babel/plugin-proposal-private-methods" "^7.17.12" + "@babel/plugin-proposal-private-property-in-object" "^7.17.12" + "@babel/plugin-proposal-unicode-property-regex" "^7.17.12" "@babel/plugin-syntax-async-generators" "^7.8.4" "@babel/plugin-syntax-class-properties" "^7.12.13" "@babel/plugin-syntax-class-static-block" "^7.14.5" "@babel/plugin-syntax-dynamic-import" "^7.8.3" "@babel/plugin-syntax-export-namespace-from" "^7.8.3" + "@babel/plugin-syntax-import-assertions" "^7.17.12" "@babel/plugin-syntax-json-strings" "^7.8.3" "@babel/plugin-syntax-logical-assignment-operators" "^7.10.4" "@babel/plugin-syntax-nullish-coalescing-operator" "^7.8.3" @@ -1106,40 +1093,40 @@ "@babel/plugin-syntax-optional-chaining" "^7.8.3" "@babel/plugin-syntax-private-property-in-object" "^7.14.5" "@babel/plugin-syntax-top-level-await" "^7.14.5" - "@babel/plugin-transform-arrow-functions" "^7.16.7" - "@babel/plugin-transform-async-to-generator" "^7.16.8" + "@babel/plugin-transform-arrow-functions" "^7.17.12" + "@babel/plugin-transform-async-to-generator" "^7.17.12" "@babel/plugin-transform-block-scoped-functions" "^7.16.7" - "@babel/plugin-transform-block-scoping" "^7.16.7" - "@babel/plugin-transform-classes" "^7.16.7" - "@babel/plugin-transform-computed-properties" "^7.16.7" - "@babel/plugin-transform-destructuring" "^7.17.7" + "@babel/plugin-transform-block-scoping" "^7.17.12" + "@babel/plugin-transform-classes" "^7.17.12" + "@babel/plugin-transform-computed-properties" "^7.17.12" + "@babel/plugin-transform-destructuring" "^7.18.0" "@babel/plugin-transform-dotall-regex" "^7.16.7" - "@babel/plugin-transform-duplicate-keys" "^7.16.7" + "@babel/plugin-transform-duplicate-keys" "^7.17.12" "@babel/plugin-transform-exponentiation-operator" "^7.16.7" - "@babel/plugin-transform-for-of" "^7.16.7" + "@babel/plugin-transform-for-of" "^7.17.12" "@babel/plugin-transform-function-name" "^7.16.7" - "@babel/plugin-transform-literals" "^7.16.7" + "@babel/plugin-transform-literals" "^7.17.12" "@babel/plugin-transform-member-expression-literals" "^7.16.7" - "@babel/plugin-transform-modules-amd" "^7.16.7" - "@babel/plugin-transform-modules-commonjs" "^7.17.9" - "@babel/plugin-transform-modules-systemjs" "^7.17.8" - "@babel/plugin-transform-modules-umd" "^7.16.7" - "@babel/plugin-transform-named-capturing-groups-regex" "^7.17.10" - "@babel/plugin-transform-new-target" "^7.16.7" + "@babel/plugin-transform-modules-amd" "^7.18.0" + "@babel/plugin-transform-modules-commonjs" "^7.18.0" + "@babel/plugin-transform-modules-systemjs" "^7.18.0" + "@babel/plugin-transform-modules-umd" "^7.18.0" + "@babel/plugin-transform-named-capturing-groups-regex" "^7.17.12" + "@babel/plugin-transform-new-target" "^7.17.12" "@babel/plugin-transform-object-super" "^7.16.7" - "@babel/plugin-transform-parameters" "^7.16.7" + "@babel/plugin-transform-parameters" "^7.17.12" "@babel/plugin-transform-property-literals" "^7.16.7" - "@babel/plugin-transform-regenerator" "^7.17.9" - "@babel/plugin-transform-reserved-words" "^7.16.7" + "@babel/plugin-transform-regenerator" "^7.18.0" + "@babel/plugin-transform-reserved-words" "^7.17.12" "@babel/plugin-transform-shorthand-properties" "^7.16.7" - "@babel/plugin-transform-spread" "^7.16.7" + "@babel/plugin-transform-spread" "^7.17.12" "@babel/plugin-transform-sticky-regex" "^7.16.7" - "@babel/plugin-transform-template-literals" "^7.16.7" - "@babel/plugin-transform-typeof-symbol" "^7.16.7" + "@babel/plugin-transform-template-literals" "^7.17.12" + "@babel/plugin-transform-typeof-symbol" "^7.17.12" "@babel/plugin-transform-unicode-escapes" "^7.16.7" "@babel/plugin-transform-unicode-regex" "^7.16.7" "@babel/preset-modules" "^0.1.5" - "@babel/types" "^7.17.10" + "@babel/types" "^7.18.0" babel-plugin-polyfill-corejs2 "^0.3.0" babel-plugin-polyfill-corejs3 "^0.5.0" babel-plugin-polyfill-regenerator "^0.3.0" @@ -1147,13 +1134,13 @@ semver "^6.3.0" "@babel/preset-flow@^7.13.13": - version "7.16.7" - resolved "https://registry.yarnpkg.com/@babel/preset-flow/-/preset-flow-7.16.7.tgz#7fd831323ab25eeba6e4b77a589f680e30581cbd" - integrity sha512-6ceP7IyZdUYQ3wUVqyRSQXztd1YmFHWI4Xv11MIqAlE4WqxBSd/FZ61V9k+TS5Gd4mkHOtQtPp9ymRpxH4y1Ug== + version "7.17.12" + resolved "https://registry.yarnpkg.com/@babel/preset-flow/-/preset-flow-7.17.12.tgz#664a5df59190260939eee862800a255bef3bd66f" + integrity sha512-7QDz7k4uiaBdu7N89VKjUn807pJRXmdirQu0KyR9LXnQrr5Jt41eIMKTS7ljej+H29erwmMrwq9Io9mJHLI3Lw== dependencies: - "@babel/helper-plugin-utils" "^7.16.7" + "@babel/helper-plugin-utils" "^7.17.12" "@babel/helper-validator-option" "^7.16.7" - "@babel/plugin-transform-flow-strip-types" "^7.16.7" + "@babel/plugin-transform-flow-strip-types" "^7.17.12" "@babel/preset-modules@^0.1.5": version "0.1.5" @@ -1166,26 +1153,26 @@ "@babel/types" "^7.4.4" esutils "^2.0.2" -"@babel/preset-react@^7.14.5", "@babel/preset-react@^7.16.7": - version "7.16.7" - resolved "https://registry.yarnpkg.com/@babel/preset-react/-/preset-react-7.16.7.tgz#4c18150491edc69c183ff818f9f2aecbe5d93852" - integrity sha512-fWpyI8UM/HE6DfPBzD8LnhQ/OcH8AgTaqcqP2nGOXEUV+VKBR5JRN9hCk9ai+zQQ57vtm9oWeXguBCPNUjytgA== +"@babel/preset-react@^7.14.5", "@babel/preset-react@^7.17.12": + version "7.17.12" + resolved "https://registry.yarnpkg.com/@babel/preset-react/-/preset-react-7.17.12.tgz#62adbd2d1870c0de3893095757ed5b00b492ab3d" + integrity sha512-h5U+rwreXtZaRBEQhW1hOJLMq8XNJBQ/9oymXiCXTuT/0uOwpbT0gUt+sXeOqoXBgNuUKI7TaObVwoEyWkpFgA== dependencies: - "@babel/helper-plugin-utils" "^7.16.7" + "@babel/helper-plugin-utils" "^7.17.12" "@babel/helper-validator-option" "^7.16.7" "@babel/plugin-transform-react-display-name" "^7.16.7" - "@babel/plugin-transform-react-jsx" "^7.16.7" + "@babel/plugin-transform-react-jsx" "^7.17.12" "@babel/plugin-transform-react-jsx-development" "^7.16.7" "@babel/plugin-transform-react-pure-annotations" "^7.16.7" -"@babel/preset-typescript@^7.13.0", "@babel/preset-typescript@^7.15.0", "@babel/preset-typescript@^7.16.7": - version "7.16.7" - resolved "https://registry.yarnpkg.com/@babel/preset-typescript/-/preset-typescript-7.16.7.tgz#ab114d68bb2020afc069cd51b37ff98a046a70b9" - integrity sha512-WbVEmgXdIyvzB77AQjGBEyYPZx+8tTsO50XtfozQrkW8QB2rLJpH2lgx0TRw5EJrBxOZQ+wCcyPVQvS8tjEHpQ== +"@babel/preset-typescript@^7.13.0", "@babel/preset-typescript@^7.15.0", "@babel/preset-typescript@^7.17.12": + version "7.17.12" + resolved "https://registry.yarnpkg.com/@babel/preset-typescript/-/preset-typescript-7.17.12.tgz#40269e0a0084d56fc5731b6c40febe1c9a4a3e8c" + integrity sha512-S1ViF8W2QwAKUGJXxP9NAfNaqGDdEBJKpYkxHf5Yy2C4NPPzXGeR3Lhk7G8xJaaLcFTRfNjVbtbVtm8Gb0mqvg== dependencies: - "@babel/helper-plugin-utils" "^7.16.7" + "@babel/helper-plugin-utils" "^7.17.12" "@babel/helper-validator-option" "^7.16.7" - "@babel/plugin-transform-typescript" "^7.16.7" + "@babel/plugin-transform-typescript" "^7.17.12" "@babel/register@^7.13.16": version "7.17.7" @@ -1198,18 +1185,18 @@ pirates "^4.0.5" source-map-support "^0.5.16" -"@babel/runtime-corejs3@^7.10.2", "@babel/runtime-corejs3@^7.17.9": - version "7.17.9" - resolved "https://registry.yarnpkg.com/@babel/runtime-corejs3/-/runtime-corejs3-7.17.9.tgz#3d02d0161f0fbf3ada8e88159375af97690f4055" - integrity sha512-WxYHHUWF2uZ7Hp1K+D1xQgbgkGUfA+5UPOegEXGt2Y5SMog/rYCVaifLZDbw8UkNXozEqqrZTy6bglL7xTaCOw== +"@babel/runtime-corejs3@^7.10.2", "@babel/runtime-corejs3@^7.18.0": + version "7.18.0" + resolved "https://registry.yarnpkg.com/@babel/runtime-corejs3/-/runtime-corejs3-7.18.0.tgz#eed03023c5226b1e2b2ba32b8b6af5cb0518a6c7" + integrity sha512-G5FaGZOWORq9zthDjIrjib5XlcddeqLbIiDO3YQsut6j7aGf76xn0umUC/pA6+nApk3hQJF4JzLzg5PCl6ewJg== dependencies: core-js-pure "^3.20.2" regenerator-runtime "^0.13.4" -"@babel/runtime@^7.1.2", "@babel/runtime@^7.10.2", "@babel/runtime@^7.10.3", "@babel/runtime@^7.11.2", "@babel/runtime@^7.12.1", "@babel/runtime@^7.12.13", "@babel/runtime@^7.12.5", "@babel/runtime@^7.16.3", "@babel/runtime@^7.17.9", "@babel/runtime@^7.8.4": - version "7.17.9" - resolved "https://registry.yarnpkg.com/@babel/runtime/-/runtime-7.17.9.tgz#d19fbf802d01a8cb6cf053a64e472d42c434ba72" - integrity sha512-lSiBBvodq29uShpWGNbgFdKYNiFDo5/HIYsaCEY9ff4sb10x9jizo2+pRrSyF4jKZCXqgzuqBOQKbUm90gQwJg== +"@babel/runtime@^7.1.2", "@babel/runtime@^7.10.2", "@babel/runtime@^7.10.3", "@babel/runtime@^7.11.2", "@babel/runtime@^7.12.1", "@babel/runtime@^7.12.13", "@babel/runtime@^7.12.5", "@babel/runtime@^7.16.3", "@babel/runtime@^7.18.0", "@babel/runtime@^7.8.4": + version "7.18.0" + resolved "https://registry.yarnpkg.com/@babel/runtime/-/runtime-7.18.0.tgz#6d77142a19cb6088f0af662af1ada37a604d34ae" + integrity sha512-YMQvx/6nKEaucl0MY56mwIG483xk8SDNdlUwb2Ts6FUpr7fm85DxEmsY18LXBNhcTz6tO6JwZV8w1W06v8UKeg== dependencies: regenerator-runtime "^0.13.4" @@ -1222,26 +1209,26 @@ "@babel/parser" "^7.16.7" "@babel/types" "^7.16.7" -"@babel/traverse@^7.12.9", "@babel/traverse@^7.13.0", "@babel/traverse@^7.16.7", "@babel/traverse@^7.16.8", "@babel/traverse@^7.17.10", "@babel/traverse@^7.17.3", "@babel/traverse@^7.17.9", "@babel/traverse@^7.7.2": - version "7.17.10" - resolved "https://registry.yarnpkg.com/@babel/traverse/-/traverse-7.17.10.tgz#1ee1a5ac39f4eac844e6cf855b35520e5eb6f8b5" - integrity sha512-VmbrTHQteIdUUQNTb+zE12SHS/xQVIShmBPhlNP12hD5poF2pbITW1Z4172d03HegaQWhLffdkRJYtAzp0AGcw== +"@babel/traverse@^7.12.9", "@babel/traverse@^7.13.0", "@babel/traverse@^7.16.7", "@babel/traverse@^7.16.8", "@babel/traverse@^7.18.0", "@babel/traverse@^7.7.2": + version "7.18.0" + resolved "https://registry.yarnpkg.com/@babel/traverse/-/traverse-7.18.0.tgz#0e5ec6db098660b2372dd63d096bf484e32d27ba" + integrity sha512-oNOO4vaoIQoGjDQ84LgtF/IAlxlyqL4TUuoQ7xLkQETFaHkY1F7yazhB4Kt3VcZGL0ZF/jhrEpnXqUb0M7V3sw== dependencies: "@babel/code-frame" "^7.16.7" - "@babel/generator" "^7.17.10" + "@babel/generator" "^7.18.0" "@babel/helper-environment-visitor" "^7.16.7" "@babel/helper-function-name" "^7.17.9" "@babel/helper-hoist-variables" "^7.16.7" "@babel/helper-split-export-declaration" "^7.16.7" - "@babel/parser" "^7.17.10" - "@babel/types" "^7.17.10" + "@babel/parser" "^7.18.0" + "@babel/types" "^7.18.0" debug "^4.1.0" globals "^11.1.0" -"@babel/types@^7.0.0", "@babel/types@^7.12.7", "@babel/types@^7.15.6", "@babel/types@^7.16.0", "@babel/types@^7.16.7", "@babel/types@^7.16.8", "@babel/types@^7.17.0", "@babel/types@^7.17.10", "@babel/types@^7.3.0", "@babel/types@^7.3.3", "@babel/types@^7.4.4": - version "7.17.10" - resolved "https://registry.yarnpkg.com/@babel/types/-/types-7.17.10.tgz#d35d7b4467e439fcf06d195f8100e0fea7fc82c4" - integrity sha512-9O26jG0mBYfGkUYCYZRnBwbVLd1UZOICEr2Em6InB6jVfsAv1GKgwXHmrSg+WFWDmeKTA6vyTZiN8tCSM5Oo3A== +"@babel/types@^7.0.0", "@babel/types@^7.12.7", "@babel/types@^7.15.6", "@babel/types@^7.16.0", "@babel/types@^7.16.7", "@babel/types@^7.16.8", "@babel/types@^7.17.0", "@babel/types@^7.17.12", "@babel/types@^7.18.0", "@babel/types@^7.3.0", "@babel/types@^7.3.3", "@babel/types@^7.4.4": + version "7.18.0" + resolved "https://registry.yarnpkg.com/@babel/types/-/types-7.18.0.tgz#ef523ea349722849cb4bf806e9342ede4d071553" + integrity sha512-vhAmLPAiC8j9K2GnsnLPCIH5wCrPpYIVBCWRBFDCB7Y/BXLqi/O+1RSTTM2bsmg6U/551+FCf9PNPxjABmxHTw== dependencies: "@babel/helper-validator-identifier" "^7.16.7" to-fast-properties "^2.0.0" @@ -1271,35 +1258,35 @@ dependencies: axios "0.21.3" -"@cspell/cspell-bundled-dicts@^5.20.0": - version "5.20.0" - resolved "https://registry.yarnpkg.com/@cspell/cspell-bundled-dicts/-/cspell-bundled-dicts-5.20.0.tgz#294106a2660baf825494535019a0d2230c3cc0c1" - integrity sha512-tCO32xVSuey4Tg8XuayBzcrCAfrAXL8J1PeYl26+/ZUl5zkAL4AuyL0Cf4e2PpeEomnUWP2y5noZLLbUeOIwnw== +"@cspell/cspell-bundled-dicts@^6.0.0": + version "6.0.0" + resolved "https://registry.yarnpkg.com/@cspell/cspell-bundled-dicts/-/cspell-bundled-dicts-6.0.0.tgz#4238871434bec96a13b76d0a3d499d39b0c42126" + integrity sha512-n6fr7V57og7Sp9Wb2K4W3ag3yvRR/hl0p1lSvA+AMnatDbYm8id/5YUlc+AdXlOb604i1fAmHLQ/1dNvm3PMMw== dependencies: "@cspell/dict-ada" "^2.0.0" "@cspell/dict-aws" "^2.0.0" "@cspell/dict-bash" "^2.0.2" "@cspell/dict-companies" "^2.0.4" - "@cspell/dict-cpp" "^2.0.3" + "@cspell/dict-cpp" "^3.1.0" "@cspell/dict-cryptocurrencies" "^2.0.0" - "@cspell/dict-csharp" "^2.0.1" + "@cspell/dict-csharp" "^3.0.1" "@cspell/dict-css" "^2.0.0" "@cspell/dict-dart" "^1.1.0" "@cspell/dict-django" "^2.0.0" "@cspell/dict-dotnet" "^2.0.1" "@cspell/dict-elixir" "^2.0.1" "@cspell/dict-en-gb" "^1.1.33" - "@cspell/dict-en_us" "^2.2.2" + "@cspell/dict-en_us" "^2.2.5" "@cspell/dict-filetypes" "^2.0.1" "@cspell/dict-fonts" "^2.0.0" "@cspell/dict-fullstack" "^2.0.5" "@cspell/dict-git" "^1.0.1" - "@cspell/dict-golang" "^2.0.0" + "@cspell/dict-golang" "^3.0.1" "@cspell/dict-haskell" "^2.0.0" "@cspell/dict-html" "^3.0.1" - "@cspell/dict-html-symbol-entities" "^2.0.0" + "@cspell/dict-html-symbol-entities" "^3.0.0" "@cspell/dict-java" "^2.0.0" - "@cspell/dict-latex" "^2.0.0" + "@cspell/dict-latex" "^2.0.3" "@cspell/dict-lorem-ipsum" "^2.0.0" "@cspell/dict-lua" "^2.0.0" "@cspell/dict-node" "^2.0.1" @@ -1307,25 +1294,25 @@ "@cspell/dict-php" "^2.0.0" "@cspell/dict-powershell" "^2.0.0" "@cspell/dict-public-licenses" "^1.0.4" - "@cspell/dict-python" "^3.0.3" + "@cspell/dict-python" "^3.0.5" "@cspell/dict-r" "^1.0.2" "@cspell/dict-ruby" "^2.0.1" "@cspell/dict-rust" "^2.0.0" "@cspell/dict-scala" "^2.0.0" - "@cspell/dict-software-terms" "^2.1.5" + "@cspell/dict-software-terms" "^2.1.7" "@cspell/dict-swift" "^1.0.2" "@cspell/dict-typescript" "^2.0.0" "@cspell/dict-vue" "^2.0.2" -"@cspell/cspell-pipe@^5.20.0": - version "5.20.0" - resolved "https://registry.yarnpkg.com/@cspell/cspell-pipe/-/cspell-pipe-5.20.0.tgz#964aa560c89ecdf4eea9145700ccd6ab4c235ed8" - integrity sha512-dGHf4XZgPlGqviYTD+5ZwSk3hpiywsuuDqnoPo9SeQ1xPon7uFVKsMiAAzvhGAkkBaKIBNP/nwPU0feYvLoCJg== +"@cspell/cspell-pipe@^6.0.0": + version "6.0.0" + resolved "https://registry.yarnpkg.com/@cspell/cspell-pipe/-/cspell-pipe-6.0.0.tgz#aad5c6ecfa36f28a75d8b4050d4607d1d77a644b" + integrity sha512-oehpfj8tOoFep34uOCABdpsqisg37Htc+DjOu5pT1gtzozReSdahD5dQUKAp/ND/tttdE4SWQUMUVZq6cxvTvw== -"@cspell/cspell-types@^5.20.0": - version "5.20.0" - resolved "https://registry.yarnpkg.com/@cspell/cspell-types/-/cspell-types-5.20.0.tgz#4c9a47249e1ad534938f2f35fbba1221e7800570" - integrity sha512-p06/HAKgalqyGHfnowJvjO3SQHxuOzKdiJTUlUi8x1CrEk7PmZEHuORlt9tVVZ46Xf2qY9+QLeTtattlWPJ39A== +"@cspell/cspell-types@^6.0.0": + version "6.0.0" + resolved "https://registry.yarnpkg.com/@cspell/cspell-types/-/cspell-types-6.0.0.tgz#a65aea274438cdbba0c0ef24ba52cd80cd89be9a" + integrity sha512-N8wGQU+n64s3cIMC/5WJzo6UT/Jetxz6oSdOr0SksCHO84I6QR1ORwsXM3ej7x6490uoTM+cf11CSYrw6ma+bg== "@cspell/dict-ada@^2.0.0": version "2.0.0" @@ -1347,20 +1334,20 @@ resolved "https://registry.yarnpkg.com/@cspell/dict-companies/-/dict-companies-2.0.4.tgz#2ba11418478d99d67a96004ea782a47a42c501a3" integrity sha512-nLNVddo+iu4q/Mu03nkVTMnSPxBkoLyZ0MgpHJZWCqxVATbBkzoZNNNjsTkJhvkbrUIWydf8YW4U4wYY+kyh7Q== -"@cspell/dict-cpp@^2.0.3": - version "2.0.3" - resolved "https://registry.yarnpkg.com/@cspell/dict-cpp/-/dict-cpp-2.0.3.tgz#551bec166c4520f7ba36f8d263fb885d19f98db0" - integrity sha512-aWRvI3CQW2M3XeJpDVffItw/9n4hxsN5EPwyBa6Po6EnCxZZZLOqpieZk4JNz4pH0/xbnOX+sMMuSeKWr71r/w== +"@cspell/dict-cpp@^3.1.0": + version "3.1.0" + resolved "https://registry.yarnpkg.com/@cspell/dict-cpp/-/dict-cpp-3.1.0.tgz#0b2983dbd942ae77c7cf0b349786344a1ba7974e" + integrity sha512-lav99zUQ+iPq6dkQRnTN0+KE9th0UG6Nwl34afyEGJ8CN5Dcq/RJjCVvOkLw6vPvs505xrvQcZW1huftQK8WVg== "@cspell/dict-cryptocurrencies@^2.0.0": version "2.0.0" resolved "https://registry.yarnpkg.com/@cspell/dict-cryptocurrencies/-/dict-cryptocurrencies-2.0.0.tgz#a74eecb42a46a96d08b6613fdb5c554529d3afff" integrity sha512-nREysmmfOp7L2YCRAUufQahwD5/Punzb5AZ6eyg4zUamdRWHgBFphb5/9h2flt1vgdUfhc6hZcML21Ci7iXjaA== -"@cspell/dict-csharp@^2.0.1": - version "2.0.1" - resolved "https://registry.yarnpkg.com/@cspell/dict-csharp/-/dict-csharp-2.0.1.tgz#86ec4fa42ba9a4cc57df28ec7a335b56bf751c5b" - integrity sha512-ZzAr+WRP2FUtXHZtfhe8f3j9vPjH+5i44Hcr5JqbWxmqciGoTbWBPQXwu9y+J4mbdC69HSWRrVGkNJ8rQk8pSw== +"@cspell/dict-csharp@^3.0.1": + version "3.0.1" + resolved "https://registry.yarnpkg.com/@cspell/dict-csharp/-/dict-csharp-3.0.1.tgz#94a673e02bb7cc03c25bc699bc1b5bd786c2c5fd" + integrity sha512-xkfQu03F388w4sdVQSSjrVMkxAxpTYB2yW7nw0XYtTjl3L/jBgvTr/j1BTjdFbQhdNf10Lg0Ak1kXOjmHodVqA== "@cspell/dict-css@^2.0.0": version "2.0.0" @@ -1392,10 +1379,10 @@ resolved "https://registry.yarnpkg.com/@cspell/dict-en-gb/-/dict-en-gb-1.1.33.tgz#7f1fd90fc364a5cb77111b5438fc9fcf9cc6da0e" integrity sha512-tKSSUf9BJEV+GJQAYGw5e+ouhEe2ZXE620S7BLKe3ZmpnjlNG9JqlnaBhkIMxKnNFkLY2BP/EARzw31AZnOv4g== -"@cspell/dict-en_us@^2.2.2": - version "2.2.4" - resolved "https://registry.yarnpkg.com/@cspell/dict-en_us/-/dict-en_us-2.2.4.tgz#20abce3eabe048aa5d858de7b9475c6c290cdc1e" - integrity sha512-gblsvIPLNAK+pRR/Mn2m2kRQLVFeoORQJeaZKlGHWckA3s0iuTN49hSSTbK66k3aWlzhirtSoux7IdvT2RpgnQ== +"@cspell/dict-en_us@^2.2.5": + version "2.2.5" + resolved "https://registry.yarnpkg.com/@cspell/dict-en_us/-/dict-en_us-2.2.5.tgz#7a1c325d54a7c9b8171da6e61f095ad34395ff68" + integrity sha512-gRHem02ZY83AQUTYBxtiVNmtM6gWFCJKumRoAKLj7vWYelmNLcCBsMA3BOOOJ7cZNKCI04lDEdh0u2f2akKZtQ== "@cspell/dict-filetypes@^2.0.1": version "2.0.1" @@ -1417,20 +1404,20 @@ resolved "https://registry.yarnpkg.com/@cspell/dict-git/-/dict-git-1.0.1.tgz#9de5ab2532abcdc8b10bd83ccb1f5e5dae0b6067" integrity sha512-Rk+eTof/9inF11lvxmkCRK+gODatA3qai8kSASv6OG/JfPvpj7fTHErx/rdgPw/LOTDUafnoTjTYmj7B2MOQXg== -"@cspell/dict-golang@^2.0.0": - version "2.0.0" - resolved "https://registry.yarnpkg.com/@cspell/dict-golang/-/dict-golang-2.0.0.tgz#a392533780c9fc3dc959f1358d09f7a6c6d82656" - integrity sha512-rUeZJR/S/ZjAsOURtxsAO6xDQhL0IzF458ScahaeOqe0zVL3tx7tCLikCgT92NWPs3BNqmsZGqYSDbn/1KsSIA== +"@cspell/dict-golang@^3.0.1": + version "3.0.1" + resolved "https://registry.yarnpkg.com/@cspell/dict-golang/-/dict-golang-3.0.1.tgz#acde95eb340c4512d132586a8326b1b3d971c0f7" + integrity sha512-0KNfXTbxHW2l8iVjxeOf+KFv9Qrw3z5cyKnkuYJWlBTSB5KcUBfeKCb4fsds26VdANqiy6U91b4gDx5kNEmBjQ== "@cspell/dict-haskell@^2.0.0": version "2.0.0" resolved "https://registry.yarnpkg.com/@cspell/dict-haskell/-/dict-haskell-2.0.0.tgz#9e7e58eba2b4633221650dcdcc43f73588b48119" integrity sha512-cjX1Br+gSWqtcmJD/IMHz1UoP3pUaKIIKy/JfhEs7ANtRt6hhfEKe9dl2kQzDkkKt4pXol+YgdYxL/sVc/nLgQ== -"@cspell/dict-html-symbol-entities@^2.0.0": - version "2.0.0" - resolved "https://registry.yarnpkg.com/@cspell/dict-html-symbol-entities/-/dict-html-symbol-entities-2.0.0.tgz#a25d39e62bd2dd7191ca5612714aa0a1b90ca10f" - integrity sha512-71S5wGCe7dq6C+zGDwsEAe5msub/irrLi6SExeG11a/EkpA3RKAEheDGPk0hOY4+vOcIFHaApxOjLTtgQfYWfA== +"@cspell/dict-html-symbol-entities@^3.0.0": + version "3.0.0" + resolved "https://registry.yarnpkg.com/@cspell/dict-html-symbol-entities/-/dict-html-symbol-entities-3.0.0.tgz#55d5d96c37ecbde00492c4238e229908eea9cedb" + integrity sha512-04K7cPTcbYXmHICfiob4gZA1yaj4hpfM+Nl5WIJ1EAZsSGHdqmGEF28GuCjyQ8ZeKiJAsPt/vXuLBbjxkHqZyQ== "@cspell/dict-html@^3.0.1": version "3.0.1" @@ -1442,10 +1429,10 @@ resolved "https://registry.yarnpkg.com/@cspell/dict-java/-/dict-java-2.0.0.tgz#76252cee8f04e099ac6dae0f45f22257088060a7" integrity sha512-9f5LDATlAiXRGqxLxgqbOLlQxuMW2zcN7tBgxwtN+4u90vM03ZUOR/gKIuDV/y0ZuAiWBIjA73cjk8DJ13Q1eA== -"@cspell/dict-latex@^2.0.0": - version "2.0.0" - resolved "https://registry.yarnpkg.com/@cspell/dict-latex/-/dict-latex-2.0.0.tgz#0b13b6522d305f5842833ec0179078d900714f65" - integrity sha512-H6RRwbHhQ9ARoO1R57SDqB+q/J5jUDdVnkdfukJkA+HNlJBhCcDuzGOIJqr+GBkJYDkF3obZ3LEOk2lUfT+Eyg== +"@cspell/dict-latex@^2.0.3": + version "2.0.3" + resolved "https://registry.yarnpkg.com/@cspell/dict-latex/-/dict-latex-2.0.3.tgz#6bbbdef07074256368e76a7c7c56940e91c14acc" + integrity sha512-shNEP20yLLzZ3iURg7241uUKO5vKvoPcd311uiMch0L0qoiC057aV9nawjQIDIgQQZvYT04Mem8N45/jnqg9cA== "@cspell/dict-lorem-ipsum@^2.0.0": version "2.0.0" @@ -1482,10 +1469,10 @@ resolved "https://registry.yarnpkg.com/@cspell/dict-public-licenses/-/dict-public-licenses-1.0.4.tgz#13c2af357e7139bf3896eba58e0feb9f51053b3f" integrity sha512-h4xULfVEDUeWyvp1OO19pcGDqWcBEQ7WGMp3QBHyYpjsamlzsyYYjCRSY2ZvpM7wruDmywSRFmRHJ/+uNFT7nA== -"@cspell/dict-python@^3.0.3": - version "3.0.3" - resolved "https://registry.yarnpkg.com/@cspell/dict-python/-/dict-python-3.0.3.tgz#6c55ee768ffe93a828e607bcab437ccf78c494c6" - integrity sha512-Mt415KczTfqmLvKTgeV8FzMzpms9baTS0P5HfULTW+UxQtZeroviYyRM9TJPJKJSoI0ISu0GiIDgmYlV7+YPog== +"@cspell/dict-python@^3.0.5": + version "3.0.5" + resolved "https://registry.yarnpkg.com/@cspell/dict-python/-/dict-python-3.0.5.tgz#6a384e950353521b8e4fc7e417d8ddd4fbcb9f8f" + integrity sha512-0BRxUndYQ2Iom9ZpN5DjUdF2E5fodw1Th/7rlhxxy45fYXUZmfXDvYoaQaymfHP0ZQhH56MCuOUNa/YMcYJtww== "@cspell/dict-r@^1.0.2": version "1.0.2" @@ -1507,10 +1494,10 @@ resolved "https://registry.yarnpkg.com/@cspell/dict-scala/-/dict-scala-2.0.0.tgz#b8098103bb03a13406c1c79f1769052353aafac4" integrity sha512-MUwA2YKpqaQOSR4V1/CVGRNk8Ii5kf6I8Ch+4/BhRZRQXuwWbi21rDRYWPqdQWps7VNzAbbMA+PQDWsD5YY38g== -"@cspell/dict-software-terms@^2.1.5": - version "2.1.5" - resolved "https://registry.yarnpkg.com/@cspell/dict-software-terms/-/dict-software-terms-2.1.5.tgz#4e2aa08839f37aa933cf1ac5196dbc7005bc8d3e" - integrity sha512-ylXWCsOJlYuucaMoHaHQLVaB8HeDrsCZ42a3jrTC/i6F/SF9I+4tBg4lMivd4w31bXBgILdbIvVHtWzJf+5m0A== +"@cspell/dict-software-terms@^2.1.7": + version "2.1.7" + resolved "https://registry.yarnpkg.com/@cspell/dict-software-terms/-/dict-software-terms-2.1.7.tgz#30d45d23003980e01854d57788c6c134fa0387f5" + integrity sha512-2FW5MlbazmWPFHzMh2xKYFcYnX+E5MdOPRrfYkbVXvWecA0466l54V+op2zlh1CbngMk4eY7AY3qahfWv6gDHA== "@cspell/dict-swift@^1.0.2": version "1.0.2" @@ -1527,19 +1514,18 @@ resolved "https://registry.yarnpkg.com/@cspell/dict-vue/-/dict-vue-2.0.2.tgz#8618b9f4825b3d80e1788082c19ac9c15832463e" integrity sha512-/MB0RS0Gn01s4pgmjy0FvsLfr3RRMrRphEuvTRserNcM8XVtoIVAtrjig/Gg0DPwDrN8Clm0L1j7iQay6S8D0g== -"@docsearch/css@3.0.0": - version "3.0.0" - resolved "https://registry.yarnpkg.com/@docsearch/css/-/css-3.0.0.tgz#fe57b474802ffd706d3246eab25d52fac8aa3698" - integrity sha512-1kkV7tkAsiuEd0shunYRByKJe3xQDG2q7wYg24SOw1nV9/2lwEd4WrUYRJC/ukGTl2/kHeFxsaUvtiOy0y6fFA== +"@docsearch/css@3.1.0": + version "3.1.0" + resolved "https://registry.yarnpkg.com/@docsearch/css/-/css-3.1.0.tgz#6781cad43fc2e034d012ee44beddf8f93ba21f19" + integrity sha512-bh5IskwkkodbvC0FzSg1AxMykfDl95hebEKwxNoq4e5QaGzOXSBgW8+jnMFZ7JU4sTBiB04vZWoUSzNrPboLZA== -"@docsearch/react@^3.0.0": - version "3.0.0" - resolved "https://registry.yarnpkg.com/@docsearch/react/-/react-3.0.0.tgz#d02ebdc67573412185a6a4df13bc254c7c0da491" - integrity sha512-yhMacqS6TVQYoBh/o603zszIb5Bl8MIXuOc6Vy617I74pirisDzzcNh0NEaYQt50fVVR3khUbeEhUEWEWipESg== +"@docsearch/react@^3.1.0": + version "3.1.0" + resolved "https://registry.yarnpkg.com/@docsearch/react/-/react-3.1.0.tgz#da943a64c01ee82b04e53b691806469272f943f7" + integrity sha512-bjB6ExnZzf++5B7Tfoi6UXgNwoUnNOfZ1NyvnvPhWgCMy5V/biAtLL4o7owmZSYdAKeFSvZ5Lxm0is4su/dBWg== dependencies: - "@algolia/autocomplete-core" "1.5.2" - "@algolia/autocomplete-preset-algolia" "1.5.2" - "@docsearch/css" "3.0.0" + "@algolia/autocomplete-core" "1.6.3" + "@docsearch/css" "3.1.0" algoliasearch "^4.0.0" "@docusaurus/react-loadable@5.5.2", "react-loadable@npm:@docusaurus/react-loadable@5.5.2": @@ -1562,15 +1548,15 @@ resolved "https://registry.yarnpkg.com/@endiliey/react-ideal-image/-/react-ideal-image-0.0.11.tgz#dc3803d04e1409cf88efa4bba0f67667807bdf27" integrity sha512-QxMjt/Gvur/gLxSoCy7VIyGGGrGmDN+VHcXkN3R2ApoWX0EYUE+hMgPHSW/PV6VVebZ1Nd4t2UnGRBDihu16JQ== -"@eslint/eslintrc@^1.2.3": - version "1.2.3" - resolved "https://registry.yarnpkg.com/@eslint/eslintrc/-/eslintrc-1.2.3.tgz#fcaa2bcef39e13d6e9e7f6271f4cc7cae1174886" - integrity sha512-uGo44hIwoLGNyduRpjdEpovcbMdd+Nv7amtmJxnKmI8xj6yd5LncmSwDa5NgX/41lIFJtkjD6YdVfgEzPfJ5UA== +"@eslint/eslintrc@^1.3.0": + version "1.3.0" + resolved "https://registry.yarnpkg.com/@eslint/eslintrc/-/eslintrc-1.3.0.tgz#29f92c30bb3e771e4a2048c95fa6855392dfac4f" + integrity sha512-UWW0TMTmk2d7hLcWD1/e2g5HDM/HQ3csaLSqXCfqwh4uNDuNqlaKWXmEsL4Cs41Z0KnILNvwbHAah3C2yt06kw== dependencies: ajv "^6.12.4" debug "^4.3.2" espree "^9.3.2" - globals "^13.9.0" + globals "^13.15.0" ignore "^5.2.0" import-fresh "^3.2.1" js-yaml "^4.1.0" @@ -1847,6 +1833,15 @@ "@jridgewell/set-array" "^1.0.0" "@jridgewell/sourcemap-codec" "^1.4.10" +"@jridgewell/gen-mapping@^0.3.0": + version "0.3.1" + resolved "https://registry.yarnpkg.com/@jridgewell/gen-mapping/-/gen-mapping-0.3.1.tgz#cf92a983c83466b8c0ce9124fadeaf09f7c66ea9" + integrity sha512-GcHwniMlA2z+WFPWuY8lp3fsza0I8xPFMWL5+n8LYyP6PSvPrXf4+n8stDHZY2DM0zy9sVkRDy1jDI4XGzYVqg== + dependencies: + "@jridgewell/set-array" "^1.0.0" + "@jridgewell/sourcemap-codec" "^1.4.10" + "@jridgewell/trace-mapping" "^0.3.9" + "@jridgewell/resolve-uri@^3.0.3": version "3.0.7" resolved "https://registry.yarnpkg.com/@jridgewell/resolve-uri/-/resolve-uri-3.0.7.tgz#30cd49820a962aff48c8fffc5cd760151fca61fe" @@ -1862,10 +1857,10 @@ resolved "https://registry.yarnpkg.com/@jridgewell/sourcemap-codec/-/sourcemap-codec-1.4.13.tgz#b6461fb0c2964356c469e115f504c95ad97ab88c" integrity sha512-GryiOJmNcWbovBxTfZSF71V/mXbgcV3MewDe3kIMCLyIh5e7SKAeUZs+rMnJ8jkMolZ/4/VsdBmMrw3l+VdZ3w== -"@jridgewell/trace-mapping@^0.3.7", "@jridgewell/trace-mapping@^0.3.8", "@jridgewell/trace-mapping@^0.3.9": - version "0.3.10" - resolved "https://registry.yarnpkg.com/@jridgewell/trace-mapping/-/trace-mapping-0.3.10.tgz#db436f0917d655393851bc258918c00226c9b183" - integrity sha512-Q0YbBd6OTsXm8Y21+YUSDXupHnodNC2M4O18jtd3iwJ3+vMZNdKGols0a9G6JOK0dcJ3IdUUHoh908ZI6qhk8Q== +"@jridgewell/trace-mapping@^0.3.7", "@jridgewell/trace-mapping@^0.3.9": + version "0.3.13" + resolved "https://registry.yarnpkg.com/@jridgewell/trace-mapping/-/trace-mapping-0.3.13.tgz#dcfe3e95f224c8fe97a87a5235defec999aa92ea" + integrity sha512-o1xbKhp9qnIAoHJSWd6KlCZfqslL4valSF81H8ImioOAxluWYWOpWkpyktY2vnt4tbrX9XYaxovq6cgowaJp2w== dependencies: "@jridgewell/resolve-uri" "^3.0.3" "@jridgewell/sourcemap-codec" "^1.4.10" @@ -2601,11 +2596,6 @@ dependencies: is-promise "^4.0.0" -"@nicolo-ribaudo/chokidar-2@2.1.8-no-fsevents.3": - version "2.1.8-no-fsevents.3" - resolved "https://registry.yarnpkg.com/@nicolo-ribaudo/chokidar-2/-/chokidar-2-2.1.8-no-fsevents.3.tgz#323d72dd25103d0c4fbdce89dadf574a787b1f9b" - integrity sha512-s88O1aVtXftvp5bCPB7WnmXc5IwOZZ7YPuwNPt+GtOOXpPvad1LfbmjYv+qII7zP6RU2QGnqve27dnLycEnyEQ== - "@nodelib/fs.scandir@2.1.5": version "2.1.5" resolved "https://registry.yarnpkg.com/@nodelib/fs.scandir/-/fs.scandir-2.1.5.tgz#7619c2eb21b25483f6d167548b4cfd5a7488c3d5" @@ -3025,89 +3015,89 @@ "@svgr/plugin-jsx" "^6.2.1" "@svgr/plugin-svgo" "^6.2.0" -"@swc/core-android-arm-eabi@1.2.181": - version "1.2.181" - resolved "https://registry.yarnpkg.com/@swc/core-android-arm-eabi/-/core-android-arm-eabi-1.2.181.tgz#8317b96dbcf43f30bc0a9c139f7dbe2ffea4ce2f" - integrity sha512-H3HNf8j6M13uIbSruef8iMsCElJJDZOhp5qxwm/+P1jAG4eQ4vPfajIlTVdFJes8Adrbr4WQaVvl+m4BQw51JQ== - -"@swc/core-android-arm64@1.2.181": - version "1.2.181" - resolved "https://registry.yarnpkg.com/@swc/core-android-arm64/-/core-android-arm64-1.2.181.tgz#23ee887e08993d26a2b31a5dce5232a5cf4e17b1" - integrity sha512-b1apYKeosBaXl28xE/By4QVHYrXaR2+nOdcP6rsDXg6nyLBArtoiS5YUFikFN/VQbSAQqNeJQ+rovT5zITrgSQ== - -"@swc/core-darwin-arm64@1.2.181": - version "1.2.181" - resolved "https://registry.yarnpkg.com/@swc/core-darwin-arm64/-/core-darwin-arm64-1.2.181.tgz#33d44c0aed28baebc797892d2243a845f5b49905" - integrity sha512-M3/PPeO6NTN7GYa1mOWPNMaAPxEQH8xd+X6FHMa7OBCi+Qxkarafu4DZRfzR88TcS3XikqFLgmmzSP7Z/tye2w== - -"@swc/core-darwin-x64@1.2.181": - version "1.2.181" - resolved "https://registry.yarnpkg.com/@swc/core-darwin-x64/-/core-darwin-x64-1.2.181.tgz#6da604c4c4e85c1baad9c355f25a4e0cceff52cb" - integrity sha512-8Uc6gx7YN5+eSnk3h7aHqp1f3RFoBJPDPeH9cURm4mfE4BTgkVgkctUm0IE5sS5AotazVbrOwhEFrl7TONSfPA== - -"@swc/core-freebsd-x64@1.2.181": - version "1.2.181" - resolved "https://registry.yarnpkg.com/@swc/core-freebsd-x64/-/core-freebsd-x64-1.2.181.tgz#41b26a7fd1214c9947e8a433231bcb3166916a33" - integrity sha512-SbnsbJHGFNY7VSTA5OhBh2PmLgQumIGerAxTCTYO1IgtbADCTL+gCjU0TK0viG/zpH4jnjaL965BI4JTo/bpRg== - -"@swc/core-linux-arm-gnueabihf@1.2.181": - version "1.2.181" - resolved "https://registry.yarnpkg.com/@swc/core-linux-arm-gnueabihf/-/core-linux-arm-gnueabihf-1.2.181.tgz#780f37f6b611ccd5c04d484b7b33e436e2ea8568" - integrity sha512-aWO6Lr9wea96Z7AEagzf4reKgDb3UWXZnClwJK7baScwF8KV+Mh99vVgkSe1nj2gKOZ31pBLp62RDJkc3gdlnA== - -"@swc/core-linux-arm64-gnu@1.2.181": - version "1.2.181" - resolved "https://registry.yarnpkg.com/@swc/core-linux-arm64-gnu/-/core-linux-arm64-gnu-1.2.181.tgz#34a4639fdcf3cf6c30087f719200c2fb1eac8792" - integrity sha512-+7fzDwsvcbhPafKdminMQrU3Ej1NHltXy7k+zgjj8BDPZbfi8hRzQcONeBV7sfl4xvw3d3roNHu2UMmKzLNs0w== - -"@swc/core-linux-arm64-musl@1.2.181": - version "1.2.181" - resolved "https://registry.yarnpkg.com/@swc/core-linux-arm64-musl/-/core-linux-arm64-musl-1.2.181.tgz#c1388644df35ad30b71c0d09fd9a96d31405299f" - integrity sha512-U9k8pv2oCxYYfu9DdOO1ZZgqbmF97NgJzSaIu3PsTedF4RcGIiPcuGOFqrUECsGUW2i6uKejE8onbXPj9UmaZQ== - -"@swc/core-linux-x64-gnu@1.2.181": - version "1.2.181" - resolved "https://registry.yarnpkg.com/@swc/core-linux-x64-gnu/-/core-linux-x64-gnu-1.2.181.tgz#2384b58d35bb2e31521005869acbc6ea2e0700b4" - integrity sha512-9AQXrvZ9BFQJeqYMpKQZRf9h/DEwhfHIR39krehO+g594i+mkkp+UNTToez6Ifn+NBYl58xyEcQGwsYIqtdYVw== - -"@swc/core-linux-x64-musl@1.2.181": - version "1.2.181" - resolved "https://registry.yarnpkg.com/@swc/core-linux-x64-musl/-/core-linux-x64-musl-1.2.181.tgz#4938a87eae011daaf9f360a1452ece8a2e9c5816" - integrity sha512-Pq/aBMj3F4CR4tXq85t7IW3piu76a677nIoo6QtBkAjrQ5QuJqpaez/5aewipG+kIXpiu/DNFIN+cISa1QeC8A== - -"@swc/core-win32-arm64-msvc@1.2.181": - version "1.2.181" - resolved "https://registry.yarnpkg.com/@swc/core-win32-arm64-msvc/-/core-win32-arm64-msvc-1.2.181.tgz#553b16cfb5aa918f191227abe929619263142ea5" - integrity sha512-m24036tVFDE8ZJ3fBVBfsHw4tHd0BG6g3TvT2MLAiW2MezYeTdrGpmvPBz4Woz686I/06cWeSg7cZF1/ZcZMMA== - -"@swc/core-win32-ia32-msvc@1.2.181": - version "1.2.181" - resolved "https://registry.yarnpkg.com/@swc/core-win32-ia32-msvc/-/core-win32-ia32-msvc-1.2.181.tgz#e520b9caa136c283fa789805bfe46966faec6d81" - integrity sha512-OPROzGapmr29qqwvB/aP9SA80r2eIukj+q7gghdQVptJrQU4GrTyzW1TpnGtpzj8rLZz4hEG6KtyPUh54bJZ/g== - -"@swc/core-win32-x64-msvc@1.2.181": - version "1.2.181" - resolved "https://registry.yarnpkg.com/@swc/core-win32-x64-msvc/-/core-win32-x64-msvc-1.2.181.tgz#5cc5843e2aad673abb76231971faca140c711709" - integrity sha512-YrIaS63XsGiQ9AgxUVZ7Irt4pwQc3c2TPN7PyQP7ok9zBZxY5pBTwRTdLctlF4LNsSavlHE5+rvdPzcYAG0ekQ== - -"@swc/core@^1.2.181": - version "1.2.181" - resolved "https://registry.yarnpkg.com/@swc/core/-/core-1.2.181.tgz#87a856be4581be4da5515287a2120544f9d733ba" - integrity sha512-evQX+Br/gC+FYLbUIF1dOQa7hUzBpowrcbgPkIRCEvi4HrCn7pGBZ2ZHBXmwEtBdLfOlyQvN/8USClApQKK4Rw== +"@swc/core-android-arm-eabi@1.2.189": + version "1.2.189" + resolved "https://registry.yarnpkg.com/@swc/core-android-arm-eabi/-/core-android-arm-eabi-1.2.189.tgz#a8060c2ec7bd93bd9907c3059c44a832eda57b6d" + integrity sha512-0kN3Le6QzFFz+Lc6a/tf/RkJXubWwWaHxF4c0bVm4AKIFf4nRlUCEqEkjdVaZvL92rpBMHaEEBuIIz3T8DqTTQ== + +"@swc/core-android-arm64@1.2.189": + version "1.2.189" + resolved "https://registry.yarnpkg.com/@swc/core-android-arm64/-/core-android-arm64-1.2.189.tgz#c9a7ebaecbef4488db3394e660dd5c2abfa5c173" + integrity sha512-smsb+YkDw2OKwg66Z63E/G4NlFApDbsiOPmZXFZbtZbNBD9v+wnk6WVA//XR1bdUI9VbzNKlMPKJxQTE685QDw== + +"@swc/core-darwin-arm64@1.2.189": + version "1.2.189" + resolved "https://registry.yarnpkg.com/@swc/core-darwin-arm64/-/core-darwin-arm64-1.2.189.tgz#883098686504692218e88877b224e06db2a93c86" + integrity sha512-OGjZRkTulKirJMLYbW9etb59lA9ueDXVwYRVD9SrNh8tRMTf0Nq+SUT/C3LVhBBGC4KSdWOzBAYbDTTdsnY++Q== + +"@swc/core-darwin-x64@1.2.189": + version "1.2.189" + resolved "https://registry.yarnpkg.com/@swc/core-darwin-x64/-/core-darwin-x64-1.2.189.tgz#38ba12dc3b07d96761dc895dd43e14ba3323129f" + integrity sha512-BEcxnBHx51514Voe2dn/y1y5H9VNyw7Zpp9+mPekZqx5o/onPD5wZ1ZfAsPrA4UlvM3v16u6ITE/cLawJ/GdAQ== + +"@swc/core-freebsd-x64@1.2.189": + version "1.2.189" + resolved "https://registry.yarnpkg.com/@swc/core-freebsd-x64/-/core-freebsd-x64-1.2.189.tgz#0cee19a1382ee97a7be2ea057cf48f5e08c66038" + integrity sha512-B6g2NWeh2iw6WPOaM19Uj3VE4se6alT265kWibLUshjcofRfnYT1lNhhkrF1D0EVnpC8I96I/xXNQo4Am9z4zQ== + +"@swc/core-linux-arm-gnueabihf@1.2.189": + version "1.2.189" + resolved "https://registry.yarnpkg.com/@swc/core-linux-arm-gnueabihf/-/core-linux-arm-gnueabihf-1.2.189.tgz#612010e31969387de6acde69d8250fd74f784be1" + integrity sha512-6WhPG9pyN5AahQTVQk8MoN1I9Z/Ytfqizuie1wV7mW8FMNmMkiJvBekKtE6ftxu80Hqa34r86WfEwmJKm5MqYw== + +"@swc/core-linux-arm64-gnu@1.2.189": + version "1.2.189" + resolved "https://registry.yarnpkg.com/@swc/core-linux-arm64-gnu/-/core-linux-arm64-gnu-1.2.189.tgz#0fe98d1ca0a3441bfe4033fbe7fc19d87019f640" + integrity sha512-frJTGnxsDe7h2d7BtnBivOdOJTtabkQIIZmHd4JHqafcoekI6teyveIax17axLyimvWl278yTo3hf7ePagD/eg== + +"@swc/core-linux-arm64-musl@1.2.189": + version "1.2.189" + resolved "https://registry.yarnpkg.com/@swc/core-linux-arm64-musl/-/core-linux-arm64-musl-1.2.189.tgz#bb28e598e028745129e0eb9458184eb5b7efe685" + integrity sha512-27K38LoZpME5lojDJIUNo7zdTDwAKLm0BMQ7HXWcYOyiDAekhSidI+SrBWxCfLzfuClhFu6/VE3E7j32VFJsiA== + +"@swc/core-linux-x64-gnu@1.2.189": + version "1.2.189" + resolved "https://registry.yarnpkg.com/@swc/core-linux-x64-gnu/-/core-linux-x64-gnu-1.2.189.tgz#365073c3183e40080be900337987fcc4d2270fff" + integrity sha512-Ha5oJKOyQm9w7+e+WdRm4ypijzEmglWZGtgBR6vV6ViqqHcTBAU4nG87ex7y7AS9p+Cbc6EOSR9X1qIB8KxtbA== + +"@swc/core-linux-x64-musl@1.2.189": + version "1.2.189" + resolved "https://registry.yarnpkg.com/@swc/core-linux-x64-musl/-/core-linux-x64-musl-1.2.189.tgz#1ce88e44952d0d4f525016c7841c1443f91de788" + integrity sha512-/p5yXa9HEzpVEuE4ivkW1IvwyYu6fT+L2OvVEs5oXIba80F0Wjy7InWqaa83gwrdMH+bXV6loG8LzZUZu/lpjA== + +"@swc/core-win32-arm64-msvc@1.2.189": + version "1.2.189" + resolved "https://registry.yarnpkg.com/@swc/core-win32-arm64-msvc/-/core-win32-arm64-msvc-1.2.189.tgz#2ad4d2aacd0032c1f8a859bba963207436a78769" + integrity sha512-o/1ueM6/sifNjYnO6NMEXB895spVfJs5oQIPxQG9vJ/4zWLw8YmAx+u1xJY+XGyK6gnroHt7yPiS87qWdbeF6w== + +"@swc/core-win32-ia32-msvc@1.2.189": + version "1.2.189" + resolved "https://registry.yarnpkg.com/@swc/core-win32-ia32-msvc/-/core-win32-ia32-msvc-1.2.189.tgz#93dee76f59760b8eb516a2e55111fdeaf1e8c6c8" + integrity sha512-YDwRkzykaf+dw5Z7u189cC/Tttkn2NVV84hrGL3LbVuh7wT5PaDhZs4Yz4unZQSlPV12olmZWgNr/i27h5wlpg== + +"@swc/core-win32-x64-msvc@1.2.189": + version "1.2.189" + resolved "https://registry.yarnpkg.com/@swc/core-win32-x64-msvc/-/core-win32-x64-msvc-1.2.189.tgz#eeb127740952e3dd5cae2866c2da60346fed457b" + integrity sha512-Nge8Z/ZkAp5p5No50yBDpBG7+ZYaVWGSuwtPj6OJe7orzvDCEm9GgcVE6J9GEjbclSWlCH8B8lUe17GaKRZHbg== + +"@swc/core@^1.2.189": + version "1.2.189" + resolved "https://registry.yarnpkg.com/@swc/core/-/core-1.2.189.tgz#8db88e809764e5b3b2be3fcac0da9d9d957e1056" + integrity sha512-S5cKX4ECMSfW78DLFgnlilJZgjrFRYwPslrrwpLl3gpwh+Qo72/Mhn71u7G/5xXW+T/xW5GwPccHfCk+k72uUg== optionalDependencies: - "@swc/core-android-arm-eabi" "1.2.181" - "@swc/core-android-arm64" "1.2.181" - "@swc/core-darwin-arm64" "1.2.181" - "@swc/core-darwin-x64" "1.2.181" - "@swc/core-freebsd-x64" "1.2.181" - "@swc/core-linux-arm-gnueabihf" "1.2.181" - "@swc/core-linux-arm64-gnu" "1.2.181" - "@swc/core-linux-arm64-musl" "1.2.181" - "@swc/core-linux-x64-gnu" "1.2.181" - "@swc/core-linux-x64-musl" "1.2.181" - "@swc/core-win32-arm64-msvc" "1.2.181" - "@swc/core-win32-ia32-msvc" "1.2.181" - "@swc/core-win32-x64-msvc" "1.2.181" + "@swc/core-android-arm-eabi" "1.2.189" + "@swc/core-android-arm64" "1.2.189" + "@swc/core-darwin-arm64" "1.2.189" + "@swc/core-darwin-x64" "1.2.189" + "@swc/core-freebsd-x64" "1.2.189" + "@swc/core-linux-arm-gnueabihf" "1.2.189" + "@swc/core-linux-arm64-gnu" "1.2.189" + "@swc/core-linux-arm64-musl" "1.2.189" + "@swc/core-linux-x64-gnu" "1.2.189" + "@swc/core-linux-x64-musl" "1.2.189" + "@swc/core-win32-arm64-msvc" "1.2.189" + "@swc/core-win32-ia32-msvc" "1.2.189" + "@swc/core-win32-x64-msvc" "1.2.189" "@swc/jest@^0.2.21": version "0.2.21" @@ -3318,6 +3308,13 @@ "@types/qs" "*" "@types/serve-static" "*" +"@types/file-loader@^5.0.1": + version "5.0.1" + resolved "https://registry.yarnpkg.com/@types/file-loader/-/file-loader-5.0.1.tgz#300b7c729e4f0c523783b865b287e3459135bf22" + integrity sha512-FHPPuRb/Ts/25qvNU/mQGwRZUp793nBxYqXd/KwApykxATagqrO4+2EEcGDm/DuXyV/EkOa04umS1DQ8tQSomg== + dependencies: + "@types/webpack" "^4" + "@types/fs-extra@^9.0.13": version "9.0.13" resolved "https://registry.yarnpkg.com/@types/fs-extra/-/fs-extra-9.0.13.tgz#7594fbae04fe7f1918ce8b3d213f74ff44ac1f45" @@ -3406,19 +3403,14 @@ dependencies: "@types/istanbul-lib-report" "*" -"@types/jest@^27.5.0": - version "27.5.0" - resolved "https://registry.yarnpkg.com/@types/jest/-/jest-27.5.0.tgz#e04ed1824ca6b1dd0438997ba60f99a7405d4c7b" - integrity sha512-9RBFx7r4k+msyj/arpfaa0WOOEcaAZNmN+j80KFbFCoSqCJGHTz7YMAMGQW9Xmqm5w6l5c25vbSjMwlikJi5+g== +"@types/jest@^27.5.1": + version "27.5.1" + resolved "https://registry.yarnpkg.com/@types/jest/-/jest-27.5.1.tgz#2c8b6dc6ff85c33bcd07d0b62cb3d19ddfdb3ab9" + integrity sha512-fUy7YRpT+rHXto1YlL+J9rs0uLGyiqVt3ZOTQR+4ROc47yNl8WLdVLgUloBRhOxP1PZvguHl44T3H0wAWxahYQ== dependencies: jest-matcher-utils "^27.0.0" pretty-format "^27.0.0" -"@types/js-cookie@^2.2.6": - version "2.2.7" - resolved "https://registry.yarnpkg.com/@types/js-cookie/-/js-cookie-2.2.7.tgz#226a9e31680835a6188e887f3988e60c04d3f6a3" - integrity sha512-aLkWa0C0vO5b4Sr798E26QgOkss68Un0bLjs7u9qxzPT5CG+8DuNTffWES58YzJs3hrVAOs1wonycqEBqNJubA== - "@types/js-yaml@^4.0.5": version "4.0.5" resolved "https://registry.yarnpkg.com/@types/js-yaml/-/js-yaml-4.0.5.tgz#738dd390a6ecc5442f35e7f03fa1431353f7e138" @@ -3497,10 +3489,10 @@ resolved "https://registry.yarnpkg.com/@types/minimist/-/minimist-1.2.2.tgz#ee771e2ba4b3dc5b372935d549fd9617bf345b8c" integrity sha512-jhuKLIRrhvCPLqwPcx6INqmKeiA5EWrsCOPhrlFSrbrmU4ZMPjj5Ul/oLCMDO98XRUIwVm78xICz4EPCektzeQ== -"@types/node@*", "@types/node@^17.0.31", "@types/node@^17.0.5": - version "17.0.31" - resolved "https://registry.yarnpkg.com/@types/node/-/node-17.0.31.tgz#a5bb84ecfa27eec5e1c802c6bbf8139bdb163a5d" - integrity sha512-AR0x5HbXGqkEx9CadRH3EBYx/VkiUgZIhP4wvPn/+5KIsgpNoyFaRlVe0Zlx9gRtg8fA06a9tskE2MSN7TcG4Q== +"@types/node@*", "@types/node@^17.0.35", "@types/node@^17.0.5": + version "17.0.35" + resolved "https://registry.yarnpkg.com/@types/node/-/node-17.0.35.tgz#635b7586086d51fb40de0a2ec9d1014a5283ba4a" + integrity sha512-vu1SrqBjbbZ3J6vwY17jBs8Sr/BKA+/a/WtjRG+whKg1iuLFOosq872EXS0eXWILdO36DHQQeku/ZcL6hz2fpg== "@types/normalize-package-data@^2.4.0": version "2.4.1" @@ -3533,9 +3525,9 @@ integrity sha512-O397rnSS9iQI4OirieAtsDqvCj4+3eY1J+EPdNTKuHuRWIfUoGyzX294o8C4KJYaLqgSrd2o60c5EqCU8Zv02g== "@types/prettier@^2.1.5": - version "2.6.0" - resolved "https://registry.yarnpkg.com/@types/prettier/-/prettier-2.6.0.tgz#efcbd41937f9ae7434c714ab698604822d890759" - integrity sha512-G/AdOadiZhnJp0jXCaBQU449W2h716OW/EoXeYkCytxKL06X1WCXB4DZpp8TpZ8eyIJVS1cw4lrlkkSYU21cDw== + version "2.6.1" + resolved "https://registry.yarnpkg.com/@types/prettier/-/prettier-2.6.1.tgz#76e72d8a775eef7ce649c63c8acae1a0824bbaed" + integrity sha512-XFjFHmaLVifrAKaZ+EKghFHtHSUonyw8P2Qmy2/+osBnrKbH9UYtlK10zg8/kCt47MFilll/DEDKy3DHfJ0URw== "@types/prismjs@^1.26.0": version "1.26.0" @@ -3564,10 +3556,10 @@ resolved "https://registry.yarnpkg.com/@types/range-parser/-/range-parser-1.2.4.tgz#cd667bcfdd025213aafb7ca5915a932590acdcdc" integrity sha512-EEhsLsD6UsDM1yFhAvy0Cjr6VwmpMWqFBCb9w07wVugF7w9nfajxLuVmngTIpgS6svCnm6Vaw+MZhoDCKnOfsw== -"@types/react-dev-utils@^9.0.10": - version "9.0.10" - resolved "https://registry.yarnpkg.com/@types/react-dev-utils/-/react-dev-utils-9.0.10.tgz#92bcfb83b25c9788b124a1598673b6e11727fead" - integrity sha512-kkPY4YbdoEXwf4CZdrEKNEYPHshdRGwHiCixyqaWxmYSj337hMX3YD28+tZkNiV4XUmJ4NevKtgZNbylkLSQ+A== +"@types/react-dev-utils@^9.0.11": + version "9.0.11" + resolved "https://registry.yarnpkg.com/@types/react-dev-utils/-/react-dev-utils-9.0.11.tgz#0dff59c60b5011df0f851e5ec4c831cf07300ba3" + integrity sha512-SdHtle/1hyImI1VzJUp20pthFwHY2O0Pq5QWIbPyku0SboPxqbyfwFwOlrr5d4yiZRr1in7SQ4Z0IiJVrJiJrg== dependencies: "@types/eslint" "*" "@types/express" "*" @@ -3575,10 +3567,10 @@ "@types/webpack" "^4" "@types/webpack-dev-server" "3" -"@types/react-dom@^18.0.3": - version "18.0.3" - resolved "https://registry.yarnpkg.com/@types/react-dom/-/react-dom-18.0.3.tgz#a022ea08c75a476fe5e96b675c3e673363853831" - integrity sha512-1RRW9kst+67gveJRYPxGmVy8eVJ05O43hg77G2j5m76/RFJtMbcfAs2viQ2UNsvvDg8F7OfQZx8qQcl6ymygaQ== +"@types/react-dom@^18.0.4": + version "18.0.4" + resolved "https://registry.yarnpkg.com/@types/react-dom/-/react-dom-18.0.4.tgz#dcbcadb277bcf6c411ceff70069424c57797d375" + integrity sha512-FgTtbqPOCI3dzZPZoC2T/sx3L34qxy99ITWn4eoSA95qPyXDMH0ALoAqUp49ITniiJFsXUVBtalh/KffMpg21Q== dependencies: "@types/react" "*" @@ -3646,10 +3638,10 @@ resolved "https://registry.yarnpkg.com/@types/rtl-detect/-/rtl-detect-1.0.0.tgz#5791e18a111f2b8b5b328160af97f3991a5697a5" integrity sha512-lyYh44YgrejEK9/5rhASghvRUOxrSJyyyQmqK7L6F/V5qs6PY1RfCi1VbjSkY6kuDt7lzQyhd006slhda4Oypg== -"@types/rtlcss@^3.1.4": - version "3.1.4" - resolved "https://registry.yarnpkg.com/@types/rtlcss/-/rtlcss-3.1.4.tgz#8b67938356507f68f1b529396a70f586f6eff2a7" - integrity sha512-R+iDmWdCzCp/6T2vOC3GpCbhPArvShXlStAxcw0UcocS/7GTREHcFyH6+xFlXAXMSgp6F+Ab9Q26Fjdu+2a4ww== +"@types/rtlcss@^3.5.0": + version "3.5.0" + resolved "https://registry.yarnpkg.com/@types/rtlcss/-/rtlcss-3.5.0.tgz#9e51e49fdee6124bb759791be962f9abc6664715" + integrity sha512-ywnxs9c/bRgEYhSs1IEs9oEznP9aAFHV6689JKFDpeeJBFpUY8m1LqFL+RHmCfl7zU8F7S7+Af65UdFMiO06oQ== dependencies: postcss "^8.2.x" @@ -3843,85 +3835,85 @@ dependencies: "@types/yargs-parser" "*" -"@typescript-eslint/eslint-plugin@^5.23.0": - version "5.23.0" - resolved "https://registry.yarnpkg.com/@typescript-eslint/eslint-plugin/-/eslint-plugin-5.23.0.tgz#bc4cbcf91fbbcc2e47e534774781b82ae25cc3d8" - integrity sha512-hEcSmG4XodSLiAp1uxv/OQSGsDY6QN3TcRU32gANp+19wGE1QQZLRS8/GV58VRUoXhnkuJ3ZxNQ3T6Z6zM59DA== +"@typescript-eslint/eslint-plugin@^5.25.0": + version "5.25.0" + resolved "https://registry.yarnpkg.com/@typescript-eslint/eslint-plugin/-/eslint-plugin-5.25.0.tgz#e8ce050990e4d36cc200f2de71ca0d3eb5e77a31" + integrity sha512-icYrFnUzvm+LhW0QeJNKkezBu6tJs9p/53dpPLFH8zoM9w1tfaKzVurkPotEpAqQ8Vf8uaFyL5jHd0Vs6Z0ZQg== dependencies: - "@typescript-eslint/scope-manager" "5.23.0" - "@typescript-eslint/type-utils" "5.23.0" - "@typescript-eslint/utils" "5.23.0" - debug "^4.3.2" + "@typescript-eslint/scope-manager" "5.25.0" + "@typescript-eslint/type-utils" "5.25.0" + "@typescript-eslint/utils" "5.25.0" + debug "^4.3.4" functional-red-black-tree "^1.0.1" - ignore "^5.1.8" + ignore "^5.2.0" regexpp "^3.2.0" - semver "^7.3.5" + semver "^7.3.7" tsutils "^3.21.0" -"@typescript-eslint/parser@^5.23.0": - version "5.23.0" - resolved "https://registry.yarnpkg.com/@typescript-eslint/parser/-/parser-5.23.0.tgz#443778e1afc9a8ff180f91b5e260ac3bec5e2de1" - integrity sha512-V06cYUkqcGqpFjb8ttVgzNF53tgbB/KoQT/iB++DOIExKmzI9vBJKjZKt/6FuV9c+zrDsvJKbJ2DOCYwX91cbw== +"@typescript-eslint/parser@^5.25.0": + version "5.25.0" + resolved "https://registry.yarnpkg.com/@typescript-eslint/parser/-/parser-5.25.0.tgz#fb533487147b4b9efd999a4d2da0b6c263b64f7f" + integrity sha512-r3hwrOWYbNKP1nTcIw/aZoH+8bBnh/Lh1iDHoFpyG4DnCpvEdctrSl6LOo19fZbzypjQMHdajolxs6VpYoChgA== dependencies: - "@typescript-eslint/scope-manager" "5.23.0" - "@typescript-eslint/types" "5.23.0" - "@typescript-eslint/typescript-estree" "5.23.0" - debug "^4.3.2" + "@typescript-eslint/scope-manager" "5.25.0" + "@typescript-eslint/types" "5.25.0" + "@typescript-eslint/typescript-estree" "5.25.0" + debug "^4.3.4" -"@typescript-eslint/scope-manager@5.23.0": - version "5.23.0" - resolved "https://registry.yarnpkg.com/@typescript-eslint/scope-manager/-/scope-manager-5.23.0.tgz#4305e61c2c8e3cfa3787d30f54e79430cc17ce1b" - integrity sha512-EhjaFELQHCRb5wTwlGsNMvzK9b8Oco4aYNleeDlNuL6qXWDF47ch4EhVNPh8Rdhf9tmqbN4sWDk/8g+Z/J8JVw== +"@typescript-eslint/scope-manager@5.25.0": + version "5.25.0" + resolved "https://registry.yarnpkg.com/@typescript-eslint/scope-manager/-/scope-manager-5.25.0.tgz#e78f1484bca7e484c48782075219c82c6b77a09f" + integrity sha512-p4SKTFWj+2VpreUZ5xMQsBMDdQ9XdRvODKXN4EksyBjFp2YvQdLkyHqOffakYZPuWJUDNu3jVXtHALDyTv3cww== dependencies: - "@typescript-eslint/types" "5.23.0" - "@typescript-eslint/visitor-keys" "5.23.0" + "@typescript-eslint/types" "5.25.0" + "@typescript-eslint/visitor-keys" "5.25.0" -"@typescript-eslint/type-utils@5.23.0": - version "5.23.0" - resolved "https://registry.yarnpkg.com/@typescript-eslint/type-utils/-/type-utils-5.23.0.tgz#f852252f2fc27620d5bb279d8fed2a13d2e3685e" - integrity sha512-iuI05JsJl/SUnOTXA9f4oI+/4qS/Zcgk+s2ir+lRmXI+80D8GaGwoUqs4p+X+4AxDolPpEpVUdlEH4ADxFy4gw== +"@typescript-eslint/type-utils@5.25.0": + version "5.25.0" + resolved "https://registry.yarnpkg.com/@typescript-eslint/type-utils/-/type-utils-5.25.0.tgz#5750d26a5db4c4d68d511611e0ada04e56f613bc" + integrity sha512-B6nb3GK3Gv1Rsb2pqalebe/RyQoyG/WDy9yhj8EE0Ikds4Xa8RR28nHz+wlt4tMZk5bnAr0f3oC8TuDAd5CPrw== dependencies: - "@typescript-eslint/utils" "5.23.0" - debug "^4.3.2" + "@typescript-eslint/utils" "5.25.0" + debug "^4.3.4" tsutils "^3.21.0" -"@typescript-eslint/types@5.23.0": - version "5.23.0" - resolved "https://registry.yarnpkg.com/@typescript-eslint/types/-/types-5.23.0.tgz#8733de0f58ae0ed318dbdd8f09868cdbf9f9ad09" - integrity sha512-NfBsV/h4dir/8mJwdZz7JFibaKC3E/QdeMEDJhiAE3/eMkoniZ7MjbEMCGXw6MZnZDMN3G9S0mH/6WUIj91dmw== +"@typescript-eslint/types@5.25.0": + version "5.25.0" + resolved "https://registry.yarnpkg.com/@typescript-eslint/types/-/types-5.25.0.tgz#dee51b1855788b24a2eceeae54e4adb89b088dd8" + integrity sha512-7fWqfxr0KNHj75PFqlGX24gWjdV/FDBABXL5dyvBOWHpACGyveok8Uj4ipPX/1fGU63fBkzSIycEje4XsOxUFA== -"@typescript-eslint/typescript-estree@5.23.0": - version "5.23.0" - resolved "https://registry.yarnpkg.com/@typescript-eslint/typescript-estree/-/typescript-estree-5.23.0.tgz#dca5f10a0a85226db0796e8ad86addc9aee52065" - integrity sha512-xE9e0lrHhI647SlGMl+m+3E3CKPF1wzvvOEWnuE3CCjjT7UiRnDGJxmAcVKJIlFgK6DY9RB98eLr1OPigPEOGg== +"@typescript-eslint/typescript-estree@5.25.0": + version "5.25.0" + resolved "https://registry.yarnpkg.com/@typescript-eslint/typescript-estree/-/typescript-estree-5.25.0.tgz#a7ab40d32eb944e3fb5b4e3646e81b1bcdd63e00" + integrity sha512-MrPODKDych/oWs/71LCnuO7NyR681HuBly2uLnX3r5i4ME7q/yBqC4hW33kmxtuauLTM0OuBOhhkFaxCCOjEEw== dependencies: - "@typescript-eslint/types" "5.23.0" - "@typescript-eslint/visitor-keys" "5.23.0" - debug "^4.3.2" - globby "^11.0.4" + "@typescript-eslint/types" "5.25.0" + "@typescript-eslint/visitor-keys" "5.25.0" + debug "^4.3.4" + globby "^11.1.0" is-glob "^4.0.3" - semver "^7.3.5" + semver "^7.3.7" tsutils "^3.21.0" -"@typescript-eslint/utils@5.23.0", "@typescript-eslint/utils@^5.10.0", "@typescript-eslint/utils@^5.23.0": - version "5.23.0" - resolved "https://registry.yarnpkg.com/@typescript-eslint/utils/-/utils-5.23.0.tgz#4691c3d1b414da2c53d8943310df36ab1c50648a" - integrity sha512-dbgaKN21drqpkbbedGMNPCtRPZo1IOUr5EI9Jrrh99r5UW5Q0dz46RKXeSBoPV+56R6dFKpbrdhgUNSJsDDRZA== +"@typescript-eslint/utils@5.25.0", "@typescript-eslint/utils@^5.10.0", "@typescript-eslint/utils@^5.25.0": + version "5.25.0" + resolved "https://registry.yarnpkg.com/@typescript-eslint/utils/-/utils-5.25.0.tgz#272751fd737733294b4ab95e16c7f2d4a75c2049" + integrity sha512-qNC9bhnz/n9Kba3yI6HQgQdBLuxDoMgdjzdhSInZh6NaDnFpTUlwNGxplUFWfY260Ya0TRPvkg9dd57qxrJI9g== dependencies: "@types/json-schema" "^7.0.9" - "@typescript-eslint/scope-manager" "5.23.0" - "@typescript-eslint/types" "5.23.0" - "@typescript-eslint/typescript-estree" "5.23.0" + "@typescript-eslint/scope-manager" "5.25.0" + "@typescript-eslint/types" "5.25.0" + "@typescript-eslint/typescript-estree" "5.25.0" eslint-scope "^5.1.1" eslint-utils "^3.0.0" -"@typescript-eslint/visitor-keys@5.23.0": - version "5.23.0" - resolved "https://registry.yarnpkg.com/@typescript-eslint/visitor-keys/-/visitor-keys-5.23.0.tgz#057c60a7ca64667a39f991473059377a8067c87b" - integrity sha512-Vd4mFNchU62sJB8pX19ZSPog05B0Y0CE2UxAZPT5k4iqhRYjPnqyY3woMxCd0++t9OTqkgjST+1ydLBi7e2Fvg== +"@typescript-eslint/visitor-keys@5.25.0": + version "5.25.0" + resolved "https://registry.yarnpkg.com/@typescript-eslint/visitor-keys/-/visitor-keys-5.25.0.tgz#33aa5fdcc5cedb9f4c8828c6a019d58548d4474b" + integrity sha512-yd26vFgMsC4h2dgX4+LR+GeicSKIfUvZREFLf3DDjZPtqgLx5AJZr6TetMNwFP9hcKreTTeztQYBTNbNoOycwA== dependencies: - "@typescript-eslint/types" "5.23.0" - eslint-visitor-keys "^3.0.0" + "@typescript-eslint/types" "5.25.0" + eslint-visitor-keys "^3.3.0" "@webassemblyjs/ast@1.11.1": version "1.11.1" @@ -4044,11 +4036,6 @@ "@webassemblyjs/ast" "1.11.1" "@xtuc/long" "4.2.2" -"@xobotyi/scrollbar-width@^1.9.5": - version "1.9.5" - resolved "https://registry.yarnpkg.com/@xobotyi/scrollbar-width/-/scrollbar-width-1.9.5.tgz#80224a6919272f405b87913ca13b92929bdf3c4d" - integrity sha512-N8tkAACJx2ww8vFMneJmaAgmjAG1tnVBZJRLRcx061tmsLRZHSEZSLuGWnwPtunsSLvSqXQ2wfp7Mgqg1I+2dQ== - "@xtuc/ieee754@^1.2.0": version "1.2.0" resolved "https://registry.yarnpkg.com/@xtuc/ieee754/-/ieee754-1.2.0.tgz#eef014a3145ae477a1cbc00cd1e552336dceb790" @@ -4218,25 +4205,25 @@ algoliasearch-helper@^3.8.2: dependencies: "@algolia/events" "^4.0.1" -algoliasearch@^4.0.0, algoliasearch@^4.13.0: - version "4.13.0" - resolved "https://registry.yarnpkg.com/algoliasearch/-/algoliasearch-4.13.0.tgz#e36611fda82b1fc548c156ae7929a7f486e4b663" - integrity sha512-oHv4faI1Vl2s+YC0YquwkK/TsaJs79g2JFg5FDm2rKN12VItPTAeQ7hyJMHarOPPYuCnNC5kixbtcqvb21wchw== - dependencies: - "@algolia/cache-browser-local-storage" "4.13.0" - "@algolia/cache-common" "4.13.0" - "@algolia/cache-in-memory" "4.13.0" - "@algolia/client-account" "4.13.0" - "@algolia/client-analytics" "4.13.0" - "@algolia/client-common" "4.13.0" - "@algolia/client-personalization" "4.13.0" - "@algolia/client-search" "4.13.0" - "@algolia/logger-common" "4.13.0" - "@algolia/logger-console" "4.13.0" - "@algolia/requester-browser-xhr" "4.13.0" - "@algolia/requester-common" "4.13.0" - "@algolia/requester-node-http" "4.13.0" - "@algolia/transporter" "4.13.0" +algoliasearch@^4.0.0, algoliasearch@^4.13.1: + version "4.13.1" + resolved "https://registry.yarnpkg.com/algoliasearch/-/algoliasearch-4.13.1.tgz#54195c41c9e4bd13ed64982248cf49d4576974fe" + integrity sha512-dtHUSE0caWTCE7liE1xaL+19AFf6kWEcyn76uhcitWpntqvicFHXKFoZe5JJcv9whQOTRM6+B8qJz6sFj+rDJA== + dependencies: + "@algolia/cache-browser-local-storage" "4.13.1" + "@algolia/cache-common" "4.13.1" + "@algolia/cache-in-memory" "4.13.1" + "@algolia/client-account" "4.13.1" + "@algolia/client-analytics" "4.13.1" + "@algolia/client-common" "4.13.1" + "@algolia/client-personalization" "4.13.1" + "@algolia/client-search" "4.13.1" + "@algolia/logger-common" "4.13.1" + "@algolia/logger-console" "4.13.1" + "@algolia/requester-browser-xhr" "4.13.1" + "@algolia/requester-common" "4.13.1" + "@algolia/requester-node-http" "4.13.1" + "@algolia/transporter" "4.13.1" ansi-align@^3.0.0, ansi-align@^3.0.1: version "3.0.1" @@ -4387,7 +4374,7 @@ array-ify@^1.0.0: resolved "https://registry.yarnpkg.com/array-ify/-/array-ify-1.0.0.tgz#9e528762b4a9066ad163a6962a364418e9626ece" integrity sha512-c5AMf34bKdvPhQ7tBGhqkgKNUzMr4WUs+WDtC2ZUGOUncbxKMTvqxYctiseW3+L4bA8ec+GcZ6/A/FW4m8ukng== -array-includes@^3.1.4: +array-includes@^3.1.4, array-includes@^3.1.5: version "3.1.5" resolved "https://registry.yarnpkg.com/array-includes/-/array-includes-3.1.5.tgz#2c320010db8d31031fd2a5f6b3bbd4b1aad31bdb" integrity sha512-iSDYZMMyTPkiFasVqfuAQnWAYcvO/SeBSCGKePoEthjp4LEMTe4uLc7b025o4jAZpHhihh8xPo99TNWUWWkGDQ== @@ -4428,7 +4415,7 @@ array.prototype.flat@^1.2.5: es-abstract "^1.19.2" es-shim-unscopables "^1.0.0" -array.prototype.flatmap@^1.2.5: +array.prototype.flatmap@^1.3.0: version "1.3.0" resolved "https://registry.yarnpkg.com/array.prototype.flatmap/-/array.prototype.flatmap-1.3.0.tgz#a7e8ed4225f4788a70cd910abcf0791e76a5534f" integrity sha512-PZC9/8TKAIxcWKdyeb77EzULHPrIX/tIZebLJUQOMR1OwYosT8yggdfWScfTBCDj5utONvOuPQQumYsU2ULbkg== @@ -4438,6 +4425,17 @@ array.prototype.flatmap@^1.2.5: es-abstract "^1.19.2" es-shim-unscopables "^1.0.0" +array.prototype.reduce@^1.0.4: + version "1.0.4" + resolved "https://registry.yarnpkg.com/array.prototype.reduce/-/array.prototype.reduce-1.0.4.tgz#8167e80089f78bff70a99e20bd4201d4663b0a6f" + integrity sha512-WnM+AjG/DvLRLo4DDl+r+SvCzYtD2Jd9oeBYMcEaI7t3fFrHY9M53/wdLcTvmZNQ70IU6Htj0emFkZ5TS+lrdw== + dependencies: + call-bind "^1.0.2" + define-properties "^1.1.3" + es-abstract "^1.19.2" + es-array-method-boxes-properly "^1.0.0" + is-string "^1.0.7" + arrify@^1.0.1: version "1.0.1" resolved "https://registry.yarnpkg.com/arrify/-/arrify-1.0.1.tgz#898508da2226f380df904728456849c1501a4b0d" @@ -4530,9 +4528,9 @@ aws4@^1.8.0: integrity sha512-xh1Rl34h6Fi1DC2WWKfxUTVqRsNnr6LsKz2+hfwDxQJWmrx8+c7ylaqBMcHfl1U1r2dsifOvKX3LQuLNZ+XSvA== axe-core@^4.3.5: - version "4.4.1" - resolved "https://registry.yarnpkg.com/axe-core/-/axe-core-4.4.1.tgz#7dbdc25989298f9ad006645cd396782443757413" - integrity sha512-gd1kmb21kwNuWr6BQz8fv6GNECPBnUasepcoLbekws23NVBLODdsClRZ+bQ8+9Uomf3Sm3+Vwn0oYG9NvwnJCw== + version "4.4.2" + resolved "https://registry.yarnpkg.com/axe-core/-/axe-core-4.4.2.tgz#dcf7fb6dea866166c3eab33d68208afe4d5f670c" + integrity sha512-LVAaGp/wkkgYJcjmHsoKx4juT1aQvJyPcW09MLCjVTh3V2cc6PnyempiLMNH5iMdfIX/zdbjUx2KDjMLCTdPeA== axios@0.21.3: version "0.21.3" @@ -4960,9 +4958,9 @@ buffers@~0.1.1: integrity sha512-9q/rDEGSb/Qsvv2qvzIzdluL5k7AaJOTrw23z9reQthrbF7is4CtlT0DXyO1oei2DCp4uojjzQ7igaSHp1kAEQ== builtin-modules@^3.1.0: - version "3.2.0" - resolved "https://registry.yarnpkg.com/builtin-modules/-/builtin-modules-3.2.0.tgz#45d5db99e7ee5e6bc4f362e008bf917ab5049887" - integrity sha512-lGzLKcioL90C7wMczpkY0n/oART3MbBa8R9OFGE1rJxoVI86u4WAGfEk8Wjv10eKSyTHVGkSo3bvBylCEtk7LA== + version "3.3.0" + resolved "https://registry.yarnpkg.com/builtin-modules/-/builtin-modules-3.3.0.tgz#cae62812b89801e9656336e46223e030386be7b6" + integrity sha512-zhaCDicdLuWN5UbN5IMnFqNMhNfo919sH85y2/ea+5Yg9TsTkeZxpL+JLbp6cgYFS4sRLp3YV4S6yDuqVWHYOw== builtins@^1.0.3: version "1.0.3" @@ -5097,9 +5095,9 @@ caniuse-api@^3.0.0: lodash.uniq "^4.5.0" caniuse-lite@^1.0.0, caniuse-lite@^1.0.30001332, caniuse-lite@^1.0.30001335: - version "1.0.30001339" - resolved "https://registry.yarnpkg.com/caniuse-lite/-/caniuse-lite-1.0.30001339.tgz#f9aece4ea8156071613b27791547ba0b33f176cf" - integrity sha512-Es8PiVqCe+uXdms0Gu5xP5PF2bxLR7OBp3wUzUnuO7OHzhOfCyg3hdiGWVPVxhiuniOzng+hTc1u3fEQ0TlkSQ== + version "1.0.30001341" + resolved "https://registry.yarnpkg.com/caniuse-lite/-/caniuse-lite-1.0.30001341.tgz#59590c8ffa8b5939cf4161f00827b8873ad72498" + integrity sha512-2SodVrFFtvGENGCv0ChVJIDQ0KPaS1cg7/qtfMaICgeMolDdo/Z2OD32F0Aq9yl6F4YFwGPBS5AaPqNYiW4PoA== caseless@~0.12.0: version "0.12.0" @@ -5173,16 +5171,17 @@ chardet@^0.7.0: resolved "https://registry.yarnpkg.com/chardet/-/chardet-0.7.0.tgz#90094849f0937f2eedc2425d0d28a9e5f0cbad9e" integrity sha512-mT8iDcrh03qDGRRmoA2hmBJnxpllMR+0/0qlzjqZES6NdiWDcZkCNAk4rPFZ9Q85r27unkiNNg8ZOiwZXBHwcA== -cheerio-select@^1.5.0: - version "1.6.0" - resolved "https://registry.yarnpkg.com/cheerio-select/-/cheerio-select-1.6.0.tgz#489f36604112c722afa147dedd0d4609c09e1696" - integrity sha512-eq0GdBvxVFbqWgmCm7M3XGs1I8oLy/nExUnh6oLqmBditPO9AqQJrkslDpMun/hZ0yyTs8L0m85OHp4ho6Qm9g== +cheerio-select@^2.1.0: + version "2.1.0" + resolved "https://registry.yarnpkg.com/cheerio-select/-/cheerio-select-2.1.0.tgz#4d8673286b8126ca2a8e42740d5e3c4884ae21b4" + integrity sha512-9v9kG0LvzrlcungtnJtpGNxY+fzECQKhK4EGJX2vByejiMX84MFNQw4UxPJl3bFbTMw+Dfs37XaIkCwTZfLh4g== dependencies: - css-select "^4.3.0" - css-what "^6.0.1" - domelementtype "^2.2.0" - domhandler "^4.3.1" - domutils "^2.8.0" + boolbase "^1.0.0" + css-select "^5.1.0" + css-what "^6.1.0" + domelementtype "^2.3.0" + domhandler "^5.0.3" + domutils "^3.0.1" cheerio@^0.22.0: version "0.22.0" @@ -5206,20 +5205,21 @@ cheerio@^0.22.0: lodash.reject "^4.4.0" lodash.some "^4.4.0" -cheerio@^1.0.0-rc.10: - version "1.0.0-rc.10" - resolved "https://registry.yarnpkg.com/cheerio/-/cheerio-1.0.0-rc.10.tgz#2ba3dcdfcc26e7956fc1f440e61d51c643379f3e" - integrity sha512-g0J0q/O6mW8z5zxQ3A8E8J1hUgp4SMOvEoW/x84OwyHKe/Zccz83PVT4y5Crcr530FV6NgmKI1qvGTKVl9XXVw== - dependencies: - cheerio-select "^1.5.0" - dom-serializer "^1.3.2" - domhandler "^4.2.0" - htmlparser2 "^6.1.0" - parse5 "^6.0.1" - parse5-htmlparser2-tree-adapter "^6.0.1" - tslib "^2.2.0" - -chokidar@^3.4.0, chokidar@^3.4.2, chokidar@^3.5.3: +cheerio@^1.0.0-rc.11: + version "1.0.0-rc.11" + resolved "https://registry.yarnpkg.com/cheerio/-/cheerio-1.0.0-rc.11.tgz#1be84be1a126958366bcc57a11648cd9b30a60c2" + integrity sha512-bQwNaDIBKID5ts/DsdhxrjqFXYfLw4ste+wMKqWA8DyKcS4qwsPP4Bk8ZNaTJjvpiX/qW3BT4sU7d6Bh5i+dag== + dependencies: + cheerio-select "^2.1.0" + dom-serializer "^2.0.0" + domhandler "^5.0.3" + domutils "^3.0.1" + htmlparser2 "^8.0.1" + parse5 "^7.0.0" + parse5-htmlparser2-tree-adapter "^7.0.0" + tslib "^2.4.0" + +chokidar@^3.4.2, chokidar@^3.5.3: version "3.5.3" resolved "https://registry.yarnpkg.com/chokidar/-/chokidar-3.5.3.tgz#1cf37c8707b932bd1af1ae22c0432e2acd1903bd" integrity sha512-Dr3sfKRP6oTcjf2JmUmFJfeVMvXBdegxB0iVQ5eb2V10uFJUCAS8OByZdVAyVb8xXNz3GjjTgj9kLWsZTqE6kw== @@ -5255,9 +5255,9 @@ ci-info@^2.0.0: integrity sha512-5tK7EtrZ0N+OLFMthtqOj4fI2Jeb88C4CAZPu25LDVUgXJ0A3Js4PMGqrn0JU1W0Mh1/Z8wZzYPxqUrXeBboCQ== ci-info@^3.2.0: - version "3.3.0" - resolved "https://registry.yarnpkg.com/ci-info/-/ci-info-3.3.0.tgz#b4ed1fb6818dea4803a55c623041f9165d2066b2" - integrity sha512-riT/3vI5YpVH6/qomlDnJow6TBee2PBKSEpx3O32EGPYbWGIRsIlGRms3Sm74wYE1JMo8RnO04Hb12+v1J5ICw== + version "3.3.1" + resolved "https://registry.yarnpkg.com/ci-info/-/ci-info-3.3.1.tgz#58331f6f472a25fe3a50a351ae3052936c2c7f32" + integrity sha512-SXgeMX9VwDe7iFFaEWkA5AstuER9YKqy4EhHqr4DVqkwmD9rpVimkMKWHdjn30Ja45txyjhSn63lVX69eVCckg== cjs-module-lexer@^1.0.0: version "1.2.2" @@ -5520,11 +5520,6 @@ commander@^2.20.0: resolved "https://registry.yarnpkg.com/commander/-/commander-2.20.3.tgz#fd485e84c03eb4881c20722ba48035e8531aeb33" integrity sha512-GpVkmM8vF2vQUkj2LvZmD35JxeJOLCwJ9cUkugyk2nuhbv3+mJvpLYYt+0+USMxE+oj+ey/lJEnhZw75x/OMcQ== -commander@^4.0.1: - version "4.1.1" - resolved "https://registry.yarnpkg.com/commander/-/commander-4.1.1.tgz#9fd602bd936294e9e9ef46a3f4d6964044b18068" - integrity sha512-NOKm8xhkzAjzFx8B2v5OAHT+u5pRQc2UCa2Vq9jYL/31o2wi9mxBA7LIFs3sV5VSC49z6pEhfbMULvShKj26WA== - commander@^5.0.0, commander@^5.1.0: version "5.1.0" resolved "https://registry.yarnpkg.com/commander/-/commander-5.1.0.tgz#46abbd1652f8e059bddaef99bbdcb2ad9cf179ae" @@ -5629,20 +5624,6 @@ concat-stream@^2.0.0: readable-stream "^3.0.2" typedarray "^0.0.6" -concurrently@^7.1.0: - version "7.1.0" - resolved "https://registry.yarnpkg.com/concurrently/-/concurrently-7.1.0.tgz#477b49b8cfc630bb491f9b02e9ed7fb7bff02942" - integrity sha512-Bz0tMlYKZRUDqJlNiF/OImojMB9ruKUz6GCfmhFnSapXgPe+3xzY4byqoKG9tUZ7L2PGEUjfLPOLfIX3labnmw== - dependencies: - chalk "^4.1.0" - date-fns "^2.16.1" - lodash "^4.17.21" - rxjs "^6.6.3" - spawn-command "^0.0.2-1" - supports-color "^8.1.0" - tree-kill "^1.2.2" - yargs "^16.2.0" - config-chain@^1.1.12: version "1.1.13" resolved "https://registry.yarnpkg.com/config-chain/-/config-chain-1.1.13.tgz#fad0795aa6a6cdaff9ed1b68e9dff94372c232f4" @@ -5787,7 +5768,7 @@ conventional-recommended-bump@^6.1.0: meow "^8.0.0" q "^1.5.1" -convert-source-map@^1.1.0, convert-source-map@^1.4.0, convert-source-map@^1.6.0, convert-source-map@^1.7.0: +convert-source-map@^1.4.0, convert-source-map@^1.6.0, convert-source-map@^1.7.0: version "1.8.0" resolved "https://registry.yarnpkg.com/convert-source-map/-/convert-source-map-1.8.0.tgz#f3373c32d21b4d780dd8004514684fb791ca4369" integrity sha512-+OQdjP49zViI/6i7nIJpA8rAl4sV/JdPfU9nZs3VqOwGIgizICvuN2ru6fMd+4llL0tar18UYJXfZ/TWtmhUjA== @@ -5814,13 +5795,6 @@ copy-text-to-clipboard@^3.0.1: resolved "https://registry.yarnpkg.com/copy-text-to-clipboard/-/copy-text-to-clipboard-3.0.1.tgz#8cbf8f90e0a47f12e4a24743736265d157bce69c" integrity sha512-rvVsHrpFcL4F2P8ihsoLdFHmd404+CMg71S756oRSeQgqk51U3kicGdnvfkrxva0xXH92SjGS62B0XIJsbh+9Q== -copy-to-clipboard@^3.3.1: - version "3.3.1" - resolved "https://registry.yarnpkg.com/copy-to-clipboard/-/copy-to-clipboard-3.3.1.tgz#115aa1a9998ffab6196f93076ad6da3b913662ae" - integrity sha512-i13qo6kIHTTpCm8/Wup+0b1mVWETvu2kIMzKoK8FpkLkFxlt0znUAHcMzox+T8sPlqtZXq3CulEjQHsYiGFJUw== - dependencies: - toggle-selection "^1.0.6" - copy-webpack-plugin@^10.2.4: version "10.2.4" resolved "https://registry.yarnpkg.com/copy-webpack-plugin/-/copy-webpack-plugin-10.2.4.tgz#6c854be3fdaae22025da34b9112ccf81c63308fe" @@ -5902,6 +5876,17 @@ cross-fetch@^3.1.5: dependencies: node-fetch "2.6.7" +cross-spawn@^6.0.5: + version "6.0.5" + resolved "https://registry.yarnpkg.com/cross-spawn/-/cross-spawn-6.0.5.tgz#4a5ec7c64dfae22c3a14124dbacdee846d80cbc4" + integrity sha512-eTVLrBSt7fjbDygz805pMnstIs2VTBNkRm0qxZd+M7A5XDdxVRWO5MxGBXZhjY4cqLYLdtrGqRf8mBPmzwSpWQ== + dependencies: + nice-try "^1.0.4" + path-key "^2.0.1" + semver "^5.5.0" + shebang-command "^1.2.0" + which "^1.2.9" + cross-spawn@^7.0.1, cross-spawn@^7.0.2, cross-spawn@^7.0.3: version "7.0.3" resolved "https://registry.yarnpkg.com/cross-spawn/-/cross-spawn-7.0.3.tgz#f73a85b9d5d41d045551c177e2882d4ac85728a6" @@ -5916,41 +5901,41 @@ crypto-random-string@^2.0.0: resolved "https://registry.yarnpkg.com/crypto-random-string/-/crypto-random-string-2.0.0.tgz#ef2a7a966ec11083388369baa02ebead229b30d5" integrity sha512-v1plID3y9r/lPhviJ1wrXpLeyUIGAZ2SHNYTEapm7/8A9nLPoyvVp3RK/EPFqn5kEznyWgYZNsRtYYIWbuG8KA== -cspell-gitignore@^5.20.0: - version "5.20.0" - resolved "https://registry.yarnpkg.com/cspell-gitignore/-/cspell-gitignore-5.20.0.tgz#0c4f405559383663a9c24fab5cf829e7b19abed5" - integrity sha512-oWzoHcaidX6jFON6vwiH3cA1HqkGmawD1DWt+fPWKrea9/SuTcvFxm+RbqO4DjwXEAMIczyPOWo+SCM0VbcCrA== +cspell-gitignore@^6.0.0: + version "6.0.0" + resolved "https://registry.yarnpkg.com/cspell-gitignore/-/cspell-gitignore-6.0.0.tgz#a98a8f5f20e2c8ccab507c9f2ca3658f05a27a7d" + integrity sha512-VngxI9wdb72CWElxGNJQ24MmEewhXNCEkW2Bx5AMOM/vgmuim8JlslEGYWCdN0XqJ4OtOVzIZ2muMV9/Oy5AvQ== dependencies: - cspell-glob "^5.20.0" + cspell-glob "^6.0.0" find-up "^5.0.0" -cspell-glob@^5.20.0: - version "5.20.0" - resolved "https://registry.yarnpkg.com/cspell-glob/-/cspell-glob-5.20.0.tgz#2bda5cc90bc6694ce2eb1a5aaee54196fc9b37a9" - integrity sha512-eyo8NYH4GapHxfilMarwvf1HIyGWT3gWuFlYkmQjYVx3KjzmfR1Y1x9S068wmwjp9kKCu9T6Vj71EGG+9R59Lw== +cspell-glob@^6.0.0: + version "6.0.0" + resolved "https://registry.yarnpkg.com/cspell-glob/-/cspell-glob-6.0.0.tgz#ccbfcb7f888683afd6453146f42bb848799bf818" + integrity sha512-H0FiYJm5Zv+HzJseRdNwHQMeJBNC8JqAzBw+5dS78RHzDyU8P3XeFEhUEy2baS2od2zxIRPLvL0/8fBXEzxPhQ== dependencies: micromatch "^4.0.5" -cspell-io@^5.20.0: - version "5.20.0" - resolved "https://registry.yarnpkg.com/cspell-io/-/cspell-io-5.20.0.tgz#2f7fc676a068acc641f3bd77ddca7f72985b6ee5" - integrity sha512-wgqqpVIhtMh+/+3YfHt8cDfrD7OLF+xQlStlURj8AJwEJ0xu16zyI9S5zcig+83+0QyzuMdxfZiMgbdQxWEvOg== +cspell-io@^6.0.0: + version "6.0.0" + resolved "https://registry.yarnpkg.com/cspell-io/-/cspell-io-6.0.0.tgz#7895eb184ac475e929950497946cfe73f521ad8e" + integrity sha512-pqrBrb7zW7cIopJ1P+LgHflU1bBg2f1SPmThU+Q8jWPshE3twYfdhwsAy13X/92vZFZa2+qZS4ejSpEC6SO9SQ== -cspell-lib@^5.20.0: - version "5.20.0" - resolved "https://registry.yarnpkg.com/cspell-lib/-/cspell-lib-5.20.0.tgz#0eb5797cb32ce03db7ad7e14649296c434e3d142" - integrity sha512-Fc7+3ExF2pNS8BsQTXSMkhR6ITbpyiMQf+y4ZH/aBml09+O6lrbj4j2tJx/oR4XvDEA8uQkV/5lMGdU+otC1KQ== +cspell-lib@^6.0.0: + version "6.0.0" + resolved "https://registry.yarnpkg.com/cspell-lib/-/cspell-lib-6.0.0.tgz#ff9e2f7cc7ba2289035b423108ef160e5f8c8d3f" + integrity sha512-NuPOO0SPckmRCJy3jWrXc7yVfVFrFM9H/rVWBHK1Z8lPFvAD9Y+/q/+Buw7eYIxpAgX3x/t7HU/Xscf0xIQqsQ== dependencies: - "@cspell/cspell-bundled-dicts" "^5.20.0" - "@cspell/cspell-pipe" "^5.20.0" - "@cspell/cspell-types" "^5.20.0" + "@cspell/cspell-bundled-dicts" "^6.0.0" + "@cspell/cspell-pipe" "^6.0.0" + "@cspell/cspell-types" "^6.0.0" clear-module "^4.1.2" comment-json "^4.2.2" configstore "^5.0.1" cosmiconfig "^7.0.1" - cspell-glob "^5.20.0" - cspell-io "^5.20.0" - cspell-trie-lib "^5.20.0" + cspell-glob "^6.0.0" + cspell-io "^6.0.0" + cspell-trie-lib "^6.0.0" fast-equals "^3.0.2" find-up "^5.0.0" fs-extra "^10.1.0" @@ -5961,31 +5946,31 @@ cspell-lib@^5.20.0: vscode-languageserver-textdocument "^1.0.4" vscode-uri "^3.0.3" -cspell-trie-lib@^5.20.0: - version "5.20.0" - resolved "https://registry.yarnpkg.com/cspell-trie-lib/-/cspell-trie-lib-5.20.0.tgz#3a13ba0477a36ecb16311e85b270bcc2b4300f37" - integrity sha512-ET95dJh+OJ04PdLI9dKqAa+dDu47tXcUxCR6uKiZ+qZ18v1Zl986s8q89m9c+xpo7Leqh0rF6Zsw3M9Cjy6Jhw== +cspell-trie-lib@^6.0.0: + version "6.0.0" + resolved "https://registry.yarnpkg.com/cspell-trie-lib/-/cspell-trie-lib-6.0.0.tgz#2752e1b128bfe17d1b7d0ea4ba9507134b5bd06a" + integrity sha512-vrYgxw9pohpoZxZ6AYtTNmx4RcDfCIw1v2s2BpDmLcs0t3Js333YLqjd/B78OHIYjEBcGQgLO9Xl0O32dHXbdA== dependencies: - "@cspell/cspell-pipe" "^5.20.0" + "@cspell/cspell-pipe" "^6.0.0" fs-extra "^10.1.0" gensequence "^3.1.1" -cspell@^5.20.0: - version "5.20.0" - resolved "https://registry.yarnpkg.com/cspell/-/cspell-5.20.0.tgz#580909fc1283aeda43f1c583188ea046417d340b" - integrity sha512-lXAS14ZlfJfOI3FgoAAfyl/AlTB8T+ayHmKrHxwuRRUvN4IBT4y8d7tdjWDj7/bsM4u5M5WrlAXg6vXH3Fg5bA== +cspell@^6.0.0: + version "6.0.0" + resolved "https://registry.yarnpkg.com/cspell/-/cspell-6.0.0.tgz#358da651b061f25f94e52bb1ceae6bfc49c801ba" + integrity sha512-skfNomVlYXGOe4C9wz0O/B8VlZc9GzpW5QDFHaRMYwWEtuyitN5WevuPMc9bkWbVKV8ghn1sXehBzy85V5PXIQ== dependencies: - "@cspell/cspell-pipe" "^5.20.0" + "@cspell/cspell-pipe" "^6.0.0" chalk "^4.1.2" commander "^9.2.0" - cspell-gitignore "^5.20.0" - cspell-glob "^5.20.0" - cspell-lib "^5.20.0" + cspell-gitignore "^6.0.0" + cspell-glob "^6.0.0" + cspell-lib "^6.0.0" fast-json-stable-stringify "^2.1.0" file-entry-cache "^6.0.1" fs-extra "^10.1.0" get-stdin "^8.0.0" - glob "^8.0.1" + glob "^8.0.3" imurmurhash "^0.1.4" semver "^7.3.7" strip-ansi "^6.0.1" @@ -6001,14 +5986,6 @@ css-functions-list@^3.0.1: resolved "https://registry.yarnpkg.com/css-functions-list/-/css-functions-list-3.0.1.tgz#1460df7fb584d1692c30b105151dbb988c8094f9" integrity sha512-PriDuifDt4u4rkDgnqRCLnjfMatufLmWNfQnGCq34xZwpY3oabwhB9SqRBmuvWUgndbemCFlKqg+nO7C2q0SBw== -css-in-js-utils@^2.0.0: - version "2.0.1" - resolved "https://registry.yarnpkg.com/css-in-js-utils/-/css-in-js-utils-2.0.1.tgz#3b472b398787291b47cfe3e44fecfdd9e914ba99" - integrity sha512-PJF0SpJT+WdbVVt0AOYp9C8GnuruRlL/UFW7932nLWmFLQTaWEzTBQEx7/hn4BuV+WON75iAViSUJLiU3PKbpA== - dependencies: - hyphenate-style-name "^1.0.2" - isobject "^3.0.1" - css-loader@^6.7.1: version "6.7.1" resolved "https://registry.yarnpkg.com/css-loader/-/css-loader-6.7.1.tgz#e98106f154f6e1baf3fc3bc455cb9981c1d5fd2e" @@ -6035,7 +6012,7 @@ css-minimizer-webpack-plugin@^3.4.1: serialize-javascript "^6.0.0" source-map "^0.6.1" -css-select@^4.1.3, css-select@^4.3.0: +css-select@^4.1.3: version "4.3.0" resolved "https://registry.yarnpkg.com/css-select/-/css-select-4.3.0.tgz#db7129b2846662fd8628cfc496abb2b59e41529b" integrity sha512-wPpOYtnsVontu2mODhA19JrqWxNsfdatRKd64kmpRbQgh1KtItko5sTnEpPdpSaJszTOhEMlF/RPz28qj4HqhQ== @@ -6046,6 +6023,17 @@ css-select@^4.1.3, css-select@^4.3.0: domutils "^2.8.0" nth-check "^2.0.1" +css-select@^5.1.0: + version "5.1.0" + resolved "https://registry.yarnpkg.com/css-select/-/css-select-5.1.0.tgz#b8ebd6554c3637ccc76688804ad3f6a6fdaea8a6" + integrity sha512-nwoRF1rvRRnnCqqY7updORDsuqKzqYJ28+oSMaJMMgOauh3fvwHqMS7EZpIPqK8GL+g9mKxF1vP/ZjSeNjEVHg== + dependencies: + boolbase "^1.0.0" + css-what "^6.1.0" + domhandler "^5.0.2" + domutils "^3.0.1" + nth-check "^2.0.1" + css-select@~1.2.0: version "1.2.0" resolved "https://registry.yarnpkg.com/css-select/-/css-select-1.2.0.tgz#2b3a110539c5355f1cd8d314623e870b121ec858" @@ -6069,7 +6057,7 @@ css-what@2.1: resolved "https://registry.yarnpkg.com/css-what/-/css-what-2.1.3.tgz#a6d7604573365fe74686c3f311c56513d88285f2" integrity sha512-a+EPoD+uZiNfh+5fxw2nO9QwFa6nJe2Or35fGY6Ipw1R3R4AGz1d1TEZrCegvw2YTmZ0jXirGYlzxxpYSHwpEg== -css-what@^6.0.1: +css-what@^6.0.1, css-what@^6.1.0: version "6.1.0" resolved "https://registry.yarnpkg.com/css-what/-/css-what-6.1.0.tgz#fb5effcf76f1ddea2c81bdfaa4de44e79bac70f4" integrity sha512-HTUrgRJ7r4dsZKU6GjmpfRK1O76h97Z8MfS1G0FozR+oF2kG6Vfe8JE6zwrkbxigziPHinCJ+gCPjA9EaBDtRw== @@ -6079,37 +6067,37 @@ cssesc@^3.0.0: resolved "https://registry.yarnpkg.com/cssesc/-/cssesc-3.0.0.tgz#37741919903b868565e1c09ea747445cd18983ee" integrity sha512-/Tb/JcjK111nNScGob5MNtsntNM1aCNUDipB/TkwZFhyDrrE47SOx/18wF2bbjgc3ZzCSKW1T5nt5EbFoAz/Vg== -cssnano-preset-advanced@^5.3.3: - version "5.3.3" - resolved "https://registry.yarnpkg.com/cssnano-preset-advanced/-/cssnano-preset-advanced-5.3.3.tgz#848422118d7a62b5b29a53edc160f58c7f7f7539" - integrity sha512-AB9SmTSC2Gd8T7PpKUsXFJ3eNsg7dc4CTZ0+XAJ29MNxyJsrCEk7N1lw31bpHrsQH2PVJr21bbWgGAfA9j0dIA== +cssnano-preset-advanced@^5.3.5: + version "5.3.5" + resolved "https://registry.yarnpkg.com/cssnano-preset-advanced/-/cssnano-preset-advanced-5.3.5.tgz#b01dda0f76ff762b58bccd17c59701176b9be131" + integrity sha512-KgrfLQaTBB4bov/Xsi0+y5iGM5gg5QChP1PTMJ9t7U6p9geKHYcPS9AC6gmfwurm0GKxhTRafDx55E8FKHX8eg== dependencies: autoprefixer "^10.3.7" - cssnano-preset-default "^5.2.7" + cssnano-preset-default "^5.2.9" postcss-discard-unused "^5.1.0" postcss-merge-idents "^5.1.1" postcss-reduce-idents "^5.2.0" postcss-zindex "^5.1.0" -cssnano-preset-default@^5.2.7: - version "5.2.7" - resolved "https://registry.yarnpkg.com/cssnano-preset-default/-/cssnano-preset-default-5.2.7.tgz#791e3603fb8f1b46717ac53b47e3c418e950f5f3" - integrity sha512-JiKP38ymZQK+zVKevphPzNSGHSlTI+AOwlasoSRtSVMUU285O7/6uZyd5NbW92ZHp41m0sSHe6JoZosakj63uA== +cssnano-preset-default@^5.2.9: + version "5.2.9" + resolved "https://registry.yarnpkg.com/cssnano-preset-default/-/cssnano-preset-default-5.2.9.tgz#63f6aa9a9f0b21d9a526371dd308253b656a9784" + integrity sha512-/4qcQcAfFEg+gnXE5NxKmYJ9JcT+8S5SDuJCLYMDN8sM/ymZ+lgLXq5+ohx/7V2brUCkgW2OaoCzOdAN0zvhGw== dependencies: css-declaration-sorter "^6.2.2" cssnano-utils "^3.1.0" postcss-calc "^8.2.3" postcss-colormin "^5.3.0" - postcss-convert-values "^5.1.0" + postcss-convert-values "^5.1.1" postcss-discard-comments "^5.1.1" postcss-discard-duplicates "^5.1.0" postcss-discard-empty "^5.1.1" postcss-discard-overridden "^5.1.0" - postcss-merge-longhand "^5.1.4" + postcss-merge-longhand "^5.1.5" postcss-merge-rules "^5.1.1" postcss-minify-font-values "^5.1.0" postcss-minify-gradients "^5.1.1" - postcss-minify-params "^5.1.2" + postcss-minify-params "^5.1.3" postcss-minify-selectors "^5.2.0" postcss-normalize-charset "^5.1.0" postcss-normalize-display-values "^5.1.0" @@ -6131,12 +6119,12 @@ cssnano-utils@^3.1.0: resolved "https://registry.yarnpkg.com/cssnano-utils/-/cssnano-utils-3.1.0.tgz#95684d08c91511edfc70d2636338ca37ef3a6861" integrity sha512-JQNR19/YZhz4psLX/rQ9M83e3z2Wf/HdJbryzte4a3NSuafyp9w/I4U+hx5C2S9g41qlstH7DEWnZaaj83OuEA== -cssnano@^5.0.6, cssnano@^5.1.7: - version "5.1.7" - resolved "https://registry.yarnpkg.com/cssnano/-/cssnano-5.1.7.tgz#99858bef6c76c9240f0cdc9239570bc7db8368be" - integrity sha512-pVsUV6LcTXif7lvKKW9ZrmX+rGRzxkEdJuVJcp5ftUjWITgwam5LMZOgaTvUrWPkcORBey6he7JKb4XAJvrpKg== +cssnano@^5.0.6, cssnano@^5.1.9: + version "5.1.9" + resolved "https://registry.yarnpkg.com/cssnano/-/cssnano-5.1.9.tgz#e6cb286c4907cbd55678eb315837a21008be21be" + integrity sha512-hctQHIIeDrfMjq0bQhoVmRVaSeNNOGxkvkKVOcKpJzLr09wlRrZWH4GaYudp0aszpW8wJeaO5/yBmID9n7DNCg== dependencies: - cssnano-preset-default "^5.2.7" + cssnano-preset-default "^5.2.9" lilconfig "^2.0.3" yaml "^1.10.2" @@ -6164,10 +6152,10 @@ cssstyle@^2.3.0: dependencies: cssom "~0.3.6" -csstype@^3.0.2, csstype@^3.0.6: - version "3.0.11" - resolved "https://registry.yarnpkg.com/csstype/-/csstype-3.0.11.tgz#d66700c5eacfac1940deb4e3ee5642792d85cd33" - integrity sha512-sa6P2wJ+CAbgyy4KFssIb/JNMLxFvKF1pCYCSXS8ZMuqZnMsrxqI2E5sPyoTpxoPU/gVZMzr2zjOfg8GIZOMsw== +csstype@^3.0.2: + version "3.1.0" + resolved "https://registry.yarnpkg.com/csstype/-/csstype-3.1.0.tgz#4ddcac3718d787cf9df0d1b7d15033925c8f29f2" + integrity sha512-uX1KG+x9h5hIJsaKR9xHUeUraxf8IODOwq9JLNPq6BwB04a/xgpq3rcx47l5BZu5zBPlgD342tdke3Hom/nJRA== damerau-levenshtein@^1.0.7: version "1.0.8" @@ -6195,11 +6183,6 @@ data-urls@^3.0.1: whatwg-mimetype "^3.0.0" whatwg-url "^11.0.0" -date-fns@^2.16.1: - version "2.28.0" - resolved "https://registry.yarnpkg.com/date-fns/-/date-fns-2.28.0.tgz#9570d656f5fc13143e50c975a3b6bbeb46cd08b2" - integrity sha512-8d35hViGYx/QH0icHYCeLmsLmMUheMmTyV9Fcm6gvNwdw31yXXH+O85sOBJ+OLnLQMKZowvpKb6FgMIQjcpvQw== - dateformat@^3.0.0: version "3.0.3" resolved "https://registry.yarnpkg.com/dateformat/-/dateformat-3.0.3.tgz#a6e37499a4d9a9cf85ef5872044d62901c9889ae" @@ -6342,10 +6325,10 @@ define-property@^2.0.2: is-descriptor "^1.0.2" isobject "^3.0.1" -del@^6.0.0: - version "6.0.0" - resolved "https://registry.yarnpkg.com/del/-/del-6.0.0.tgz#0b40d0332cea743f1614f818be4feb717714c952" - integrity sha512-1shh9DQ23L16oXSZKB2JxpL7iMy2E0S9d517ptA1P8iw0alkPtQcrKH7ru31rYtKwF499HkTu+DRzq3TCKDFRQ== +del@^6.1.0: + version "6.1.0" + resolved "https://registry.yarnpkg.com/del/-/del-6.1.0.tgz#aa79a5b0a2a9ecc985c0a075e8ad9a5b23bf949c" + integrity sha512-OpcRktOt7G7HBfyxP0srBH4Djg4824EQORX8E1qvIhIzthNNArxxhrB/Mm7dRMiLi1nvFyUpDhzD2cTtbBhV8A== dependencies: globby "^11.0.1" graceful-fs "^4.2.4" @@ -6508,7 +6491,7 @@ dom-serializer@0: domelementtype "^2.0.1" entities "^2.0.0" -dom-serializer@^1.0.1, dom-serializer@^1.3.2: +dom-serializer@^1.0.1: version "1.4.1" resolved "https://registry.yarnpkg.com/dom-serializer/-/dom-serializer-1.4.1.tgz#de5d41b1aea290215dc45a6dae8adcf1d32e2d30" integrity sha512-VHwB3KfrcOOkelEG2ZOfxqLZdfkil8PtJi4P8N2MMXucZq2yLp75ClViUlOVwyoHEDjYU433Aq+5zWP61+RGag== @@ -6517,6 +6500,15 @@ dom-serializer@^1.0.1, dom-serializer@^1.3.2: domhandler "^4.2.0" entities "^2.0.0" +dom-serializer@^2.0.0: + version "2.0.0" + resolved "https://registry.yarnpkg.com/dom-serializer/-/dom-serializer-2.0.0.tgz#e41b802e1eedf9f6cae183ce5e622d789d7d8e53" + integrity sha512-wIkAryiqt/nV5EQKqQpo3SToSOV9J0DnbJqwK7Wv/Trc92zIAYZ4FlMu+JPFW1DfGFt81ZTCGgDEabffXeLyJg== + dependencies: + domelementtype "^2.3.0" + domhandler "^5.0.2" + entities "^4.2.0" + dom-serializer@~0.1.0: version "0.1.1" resolved "https://registry.yarnpkg.com/dom-serializer/-/dom-serializer-0.1.1.tgz#1ec4059e284babed36eec2941d4a970a189ce7c0" @@ -6530,7 +6522,7 @@ domelementtype@1, domelementtype@^1.3.0, domelementtype@^1.3.1: resolved "https://registry.yarnpkg.com/domelementtype/-/domelementtype-1.3.1.tgz#d048c44b37b0d10a7f2a3d5fee3f4333d790481f" integrity sha512-BSKB+TSpMpFI/HOxCNr1O8aMOTZ8hT3pM3GQ0w/mWRmkhEDSFJkkyzz4XQsBV44BChwGkrDfMyjVD0eA2aFV3w== -domelementtype@^2.0.1, domelementtype@^2.2.0: +domelementtype@^2.0.1, domelementtype@^2.2.0, domelementtype@^2.3.0: version "2.3.0" resolved "https://registry.yarnpkg.com/domelementtype/-/domelementtype-2.3.0.tgz#5c45e8e869952626331d7aab326d01daf65d589d" integrity sha512-OLETBj6w0OsagBwdXnPdN0cnMfF9opN69co+7ZrbfPGrdpPVNBUj02spi6B1N7wChLQiPn4CSH/zJvXw56gmHw== @@ -6556,6 +6548,13 @@ domhandler@^4.0.0, domhandler@^4.2.0, domhandler@^4.3.1: dependencies: domelementtype "^2.2.0" +domhandler@^5.0.1, domhandler@^5.0.2, domhandler@^5.0.3: + version "5.0.3" + resolved "https://registry.yarnpkg.com/domhandler/-/domhandler-5.0.3.tgz#cc385f7f751f1d1fc650c21374804254538c7d31" + integrity sha512-cgwlv/1iFQiFnU96XXgROh8xTeetsnJiDsTc7TYCLFd9+/WNkIqPTxiM/8pSd8VIrhXGTf1Ny1q1hquVqDJB5w== + dependencies: + domelementtype "^2.3.0" + domutils@1.5.1: version "1.5.1" resolved "https://registry.yarnpkg.com/domutils/-/domutils-1.5.1.tgz#dcd8488a26f563d61079e48c9f7b7e32373682cf" @@ -6581,6 +6580,15 @@ domutils@^2.5.2, domutils@^2.8.0: domelementtype "^2.2.0" domhandler "^4.2.0" +domutils@^3.0.1: + version "3.0.1" + resolved "https://registry.yarnpkg.com/domutils/-/domutils-3.0.1.tgz#696b3875238338cb186b6c0612bd4901c89a4f1c" + integrity sha512-z08c1l761iKhDFtfXO04C7kTdPBLi41zwOZl00WS8b5eiaebNpY00HKbztwBq+e3vyqWNwWF3mP9YLUeqIrF+Q== + dependencies: + dom-serializer "^2.0.0" + domelementtype "^2.3.0" + domhandler "^5.0.1" + dot-case@^3.0.4: version "3.0.4" resolved "https://registry.yarnpkg.com/dot-case/-/dot-case-3.0.4.tgz#9b2b670d00a431667a8a75ba29cd1b98809ce751" @@ -6639,9 +6647,9 @@ ee-first@1.1.1: integrity sha512-WMwm9LhRUo+WUaRN+vRuETqG89IgZphVSNkdFgeb6sS/E4OrDIN7t48CAewSHXc6C8lefD8KKfr5vY61brQlow== ejs@^3.1.6: - version "3.1.7" - resolved "https://registry.yarnpkg.com/ejs/-/ejs-3.1.7.tgz#c544d9c7f715783dd92f0bddcf73a59e6962d006" - integrity sha512-BIar7R6abbUxDA3bfXrO4DSgwo8I+fB5/1zgujl3HLLjwd6+9iOnrT+t3grn2qbk9vOgBubXOFwX2m9axoFaGw== + version "3.1.8" + resolved "https://registry.yarnpkg.com/ejs/-/ejs-3.1.8.tgz#758d32910c78047585c7ef1f92f9ee041c1c190b" + integrity sha512-/sXZeMlhS0ArkfX2Aw780gJzXSMPnKjtspYZv+f3NiKLlubezAHDU5+9xz6gd3/NhG3txQCo6xlglmTS+oTGEQ== dependencies: jake "^10.8.5" @@ -6717,6 +6725,11 @@ entities@^3.0.1: resolved "https://registry.yarnpkg.com/entities/-/entities-3.0.1.tgz#2b887ca62585e96db3903482d336c1006c3001d4" integrity sha512-WiyBqoomrwMdFG1e0kqvASYfnlb0lp8M5o5Fw2OFq1hNZxxcNk8Ik0Xm7LxzBhuidnZB/UtBqVCgUz3kBOP51Q== +entities@^4.2.0, entities@^4.3.0: + version "4.3.0" + resolved "https://registry.yarnpkg.com/entities/-/entities-4.3.0.tgz#62915f08d67353bb4eb67e3d62641a4059aec656" + integrity sha512-/iP1rZrSEJ0DTlPiX+jbzlA3eVkY/e8L8SozroF395fIqE3TYF/Nz7YOMAawta+vLmyJ/hkGNNPcSbMADCCXbg== + env-paths@^2.2.0: version "2.2.1" resolved "https://registry.yarnpkg.com/env-paths/-/env-paths-2.2.1.tgz#420399d416ce1fbe9bc0a07c62fa68d67fd0f8f2" @@ -6739,17 +6752,10 @@ error-ex@^1.3.1: dependencies: is-arrayish "^0.2.1" -error-stack-parser@^2.0.6: - version "2.0.7" - resolved "https://registry.yarnpkg.com/error-stack-parser/-/error-stack-parser-2.0.7.tgz#b0c6e2ce27d0495cf78ad98715e0cad1219abb57" - integrity sha512-chLOW0ZGRf4s8raLrDxa5sdkvPec5YdvwbFnqJme4rk0rFajP8mPtrDL1+I+CwrQDCjswDA5sREX7jYQDQs9vA== - dependencies: - stackframe "^1.1.1" - -es-abstract@^1.19.0, es-abstract@^1.19.1, es-abstract@^1.19.2, es-abstract@^1.19.5: - version "1.20.0" - resolved "https://registry.yarnpkg.com/es-abstract/-/es-abstract-1.20.0.tgz#b2d526489cceca004588296334726329e0a6bfb6" - integrity sha512-URbD8tgRthKD3YcC39vbvSDrX23upXnPcnGAjQfgxXF5ID75YcENawc9ZX/9iTP9ptUyfCLIxTTuMYoRfiOVKA== +es-abstract@^1.19.0, es-abstract@^1.19.1, es-abstract@^1.19.2, es-abstract@^1.19.5, es-abstract@^1.20.1: + version "1.20.1" + resolved "https://registry.yarnpkg.com/es-abstract/-/es-abstract-1.20.1.tgz#027292cd6ef44bd12b1913b828116f54787d1814" + integrity sha512-WEm2oBhfoI2sImeM4OF2zE2V3BYdSF+KnSi9Sidz51fQHd7+JuF8Xgcj9/0o+OWeIeIS/MiuNnlruQrJf16GQA== dependencies: call-bind "^1.0.2" es-to-primitive "^1.2.1" @@ -6770,11 +6776,16 @@ es-abstract@^1.19.0, es-abstract@^1.19.1, es-abstract@^1.19.2, es-abstract@^1.19 object-inspect "^1.12.0" object-keys "^1.1.1" object.assign "^4.1.2" - regexp.prototype.flags "^1.4.1" + regexp.prototype.flags "^1.4.3" string.prototype.trimend "^1.0.5" string.prototype.trimstart "^1.0.5" unbox-primitive "^1.0.2" +es-array-method-boxes-properly@^1.0.0: + version "1.0.0" + resolved "https://registry.yarnpkg.com/es-array-method-boxes-properly/-/es-array-method-boxes-properly-1.0.0.tgz#873f3e84418de4ee19c5be752990b2e44718d09e" + integrity sha512-wd6JXUmyHmt8T5a2xreUwKcGPq6f1f+WwIJkijUqiGcJz1qqnZgP6XIK+QyIWU5lT7imeNxUll48bziG+TSYcA== + es-module-lexer@^0.9.0: version "0.9.3" resolved "https://registry.yarnpkg.com/es-module-lexer/-/es-module-lexer-0.9.3.tgz#6f13db00cc38417137daf74366f535c8eb438f19" @@ -6878,10 +6889,10 @@ eslint-module-utils@^2.7.3: debug "^3.2.7" find-up "^2.1.0" -eslint-plugin-eslint-plugin@^4.1.0: - version "4.1.0" - resolved "https://registry.yarnpkg.com/eslint-plugin-eslint-plugin/-/eslint-plugin-eslint-plugin-4.1.0.tgz#40ae944d79e845dc9d4a85328eea3c5bf4ae0f7d" - integrity sha512-QJVw+WYXJuG2469gx5G929bz7crfxySDlK1i569FkuT6dpeHDeP7MmDrKaswCx17snG25LRFD6wmVX+AO5x7Qg== +eslint-plugin-eslint-plugin@^4.2.0: + version "4.2.0" + resolved "https://registry.yarnpkg.com/eslint-plugin-eslint-plugin/-/eslint-plugin-eslint-plugin-4.2.0.tgz#64c5ba82f9b1073c89a79a1c8f451f278be6603a" + integrity sha512-ZDyUUlZJw85hmc9pGciNFiQwojXKxV7KAAVnQtojk1W/I8YYHxYV9JBuzhfAYfVemiQzDPNwj1zwAqQwGN1ROw== dependencies: eslint-utils "^3.0.0" estraverse "^5.2.0" @@ -6910,10 +6921,10 @@ eslint-plugin-import@^2.26.0: resolve "^1.22.0" tsconfig-paths "^3.14.1" -eslint-plugin-jest@^26.1.5: - version "26.1.5" - resolved "https://registry.yarnpkg.com/eslint-plugin-jest/-/eslint-plugin-jest-26.1.5.tgz#6cfca264818d6d6aa120b019dab4d62b6aa8e775" - integrity sha512-su89aDuljL9bTjEufTXmKUMSFe2kZUL9bi7+woq+C2ukHZordhtfPm4Vg+tdioHBaKf8v3/FXW9uV0ksqhYGFw== +eslint-plugin-jest@^26.2.2: + version "26.2.2" + resolved "https://registry.yarnpkg.com/eslint-plugin-jest/-/eslint-plugin-jest-26.2.2.tgz#74e000544259f1ef0462a609a3fc9e5da3768f6c" + integrity sha512-etSFZ8VIFX470aA6kTqDPhIq7YWe0tjBcboFNV3WeiC18PJ/AVonGhuTwlmuz2fBkH8FJHA7JQ4k7GsQIj1Gew== dependencies: "@typescript-eslint/utils" "^5.10.0" @@ -6940,25 +6951,25 @@ eslint-plugin-react-hooks@^4.5.0: resolved "https://registry.yarnpkg.com/eslint-plugin-react-hooks/-/eslint-plugin-react-hooks-4.5.0.tgz#5f762dfedf8b2cf431c689f533c9d3fa5dcf25ad" integrity sha512-8k1gRt7D7h03kd+SAAlzXkQwWK22BnK6GKZG+FJA6BAGy22CFvl8kCIXKpVux0cCxMWDQUPqSok0LKaZ0aOcCw== -eslint-plugin-react@^7.29.4: - version "7.29.4" - resolved "https://registry.yarnpkg.com/eslint-plugin-react/-/eslint-plugin-react-7.29.4.tgz#4717de5227f55f3801a5fd51a16a4fa22b5914d2" - integrity sha512-CVCXajliVh509PcZYRFyu/BoUEz452+jtQJq2b3Bae4v3xBUWPLCmtmBM+ZinG4MzwmxJgJ2M5rMqhqLVn7MtQ== +eslint-plugin-react@^7.30.0: + version "7.30.0" + resolved "https://registry.yarnpkg.com/eslint-plugin-react/-/eslint-plugin-react-7.30.0.tgz#8e7b1b2934b8426ac067a0febade1b13bd7064e3" + integrity sha512-RgwH7hjW48BleKsYyHK5vUAvxtE9SMPDKmcPRQgtRCYaZA0XQPt5FSkrU3nhz5ifzMZcA8opwmRJ2cmOO8tr5A== dependencies: - array-includes "^3.1.4" - array.prototype.flatmap "^1.2.5" + array-includes "^3.1.5" + array.prototype.flatmap "^1.3.0" doctrine "^2.1.0" estraverse "^5.3.0" jsx-ast-utils "^2.4.1 || ^3.0.0" minimatch "^3.1.2" object.entries "^1.1.5" object.fromentries "^2.0.5" - object.hasown "^1.1.0" + object.hasown "^1.1.1" object.values "^1.1.5" prop-types "^15.8.1" resolve "^2.0.0-next.3" semver "^6.3.0" - string.prototype.matchall "^4.0.6" + string.prototype.matchall "^4.0.7" eslint-plugin-regexp@^1.7.0: version "1.7.0" @@ -7002,17 +7013,17 @@ eslint-visitor-keys@^2.0.0, eslint-visitor-keys@^2.1.0: resolved "https://registry.yarnpkg.com/eslint-visitor-keys/-/eslint-visitor-keys-2.1.0.tgz#f65328259305927392c938ed44eb0a5c9b2bd303" integrity sha512-0rSmRBzXgDzIsD6mGdJgevzgezI534Cer5L/vyMX0kHzT/jiB43jRhd9YUlMGYLQy2zprNmoT8qasCGtY+QaKw== -eslint-visitor-keys@^3.0.0, eslint-visitor-keys@^3.3.0: +eslint-visitor-keys@^3.3.0: version "3.3.0" resolved "https://registry.yarnpkg.com/eslint-visitor-keys/-/eslint-visitor-keys-3.3.0.tgz#f6480fa6b1f30efe2d1968aa8ac745b862469826" integrity sha512-mQ+suqKJVyeuwGYHAdjMFqjCyfl8+Ldnxuyp3ldiMBFKkvytrXUZWaiPCEav8qDHKty44bD+qV1IP4T+w+xXRA== -eslint@^8.15.0: - version "8.15.0" - resolved "https://registry.yarnpkg.com/eslint/-/eslint-8.15.0.tgz#fea1d55a7062da48d82600d2e0974c55612a11e9" - integrity sha512-GG5USZ1jhCu8HJkzGgeK8/+RGnHaNYZGrGDzUtigK3BsGESW/rs2az23XqE0WVwDxy1VRvvjSSGu5nB0Bu+6SA== +eslint@^8.16.0: + version "8.16.0" + resolved "https://registry.yarnpkg.com/eslint/-/eslint-8.16.0.tgz#6d936e2d524599f2a86c708483b4c372c5d3bbae" + integrity sha512-MBndsoXY/PeVTDJeWsYj7kLZ5hQpJOfMYLsF6LicLHQWbRDG19lK5jOix4DPl8yY4SUFcE3txy86OzFLWT+yoA== dependencies: - "@eslint/eslintrc" "^1.2.3" + "@eslint/eslintrc" "^1.3.0" "@humanwhocodes/config-array" "^0.9.2" ajv "^6.10.0" chalk "^4.0.0" @@ -7030,7 +7041,7 @@ eslint@^8.15.0: file-entry-cache "^6.0.1" functional-red-black-tree "^1.0.1" glob-parent "^6.0.1" - globals "^13.6.0" + globals "^13.15.0" ignore "^5.2.0" import-fresh "^3.0.0" imurmurhash "^0.1.4" @@ -7308,11 +7319,6 @@ fast-levenshtein@^2.0.6, fast-levenshtein@~2.0.6: resolved "https://registry.yarnpkg.com/fast-levenshtein/-/fast-levenshtein-2.0.6.tgz#3d8a5c66883a16a30ca8643e851f19baa7797917" integrity sha512-DCXu6Ifhqcks7TZKY3Hxp3y6qphY5SJZmrWMDrKcERSOXWQdMhU9Ig/PYrzyw/ul9jOIyh0N4M0tbC5hodg8dw== -fast-shallow-equal@^1.0.0: - version "1.0.0" - resolved "https://registry.yarnpkg.com/fast-shallow-equal/-/fast-shallow-equal-1.0.0.tgz#d4dcaf6472440dcefa6f88b98e3251e27f25628b" - integrity sha512-HPtaa38cPgWvaCFmRNhlc6NG7pv6NUHqjPgVAkWGoB9mQMwYB27/K0CvOM5Czy+qpT3e8XJ6Q4aPAnzpNpzNaw== - fast-url-parser@1.1.3: version "1.1.3" resolved "https://registry.yarnpkg.com/fast-url-parser/-/fast-url-parser-1.1.3.tgz#f4af3ea9f34d8a271cf58ad2b3759f431f0b318d" @@ -7325,11 +7331,6 @@ fastest-levenshtein@^1.0.12: resolved "https://registry.yarnpkg.com/fastest-levenshtein/-/fastest-levenshtein-1.0.12.tgz#9990f7d3a88cc5a9ffd1f1745745251700d497e2" integrity sha512-On2N+BpYJ15xIC974QNVuYGMOlEVt4s0EOI3wwMqOmK1fdDY+FN/zltPV8vosq4ad4c/gJ1KHScUn/6AWIgiow== -fastest-stable-stringify@^2.0.2: - version "2.0.2" - resolved "https://registry.yarnpkg.com/fastest-stable-stringify/-/fastest-stable-stringify-2.0.2.tgz#3757a6774f6ec8de40c4e86ec28ea02417214c76" - integrity sha512-bijHueCGd0LqqNK9b5oCMHc0MluJAx0cwqASgbWMvkO01lCYgIhacVRLcaDz3QnyYIRNJRDwMb41VuT6pHJ91Q== - fastq@^1.6.0: version "1.13.0" resolved "https://registry.yarnpkg.com/fastq/-/fastq-1.13.0.tgz#616760f88a7526bdfc596b7cab8c18938c36b98c" @@ -7413,9 +7414,9 @@ file-loader@^6.2.0: schema-utils "^3.0.0" filelist@^1.0.1: - version "1.0.3" - resolved "https://registry.yarnpkg.com/filelist/-/filelist-1.0.3.tgz#448607750376484932f67ef1b9ff07386b036c83" - integrity sha512-LwjCsruLWQULGYKy7TX0OPtrL9kLpojOFKc5VCTxdFTV7w5zbsgqVKfnkKG7Qgjtq50gKfO56hJv88OfcGb70Q== + version "1.0.4" + resolved "https://registry.yarnpkg.com/filelist/-/filelist-1.0.4.tgz#f78978a1e944775ff9e62e744424f215e58352b5" + integrity sha512-w1cEuf3S+DrLCQL7ET6kz+gmlJdbq9J7yXCSjK/OZCPA+qEN1WyF4ZAf0YYJa4/shHJra2t/d/r8SV4Ji+x+8Q== dependencies: minimatch "^5.0.1" @@ -7521,9 +7522,9 @@ flatted@^3.1.0: integrity sha512-WIWGi2L3DyTUvUrwRKgGi9TwxQMUEqPOPQBVi71R96jZXJdFskXEmf54BoZaS1kknGODoIGASGEzBUYdyMCBJg== flow-parser@0.*: - version "0.177.0" - resolved "https://registry.yarnpkg.com/flow-parser/-/flow-parser-0.177.0.tgz#653092470c8e79ed737cb38e3be1d1de0d25feac" - integrity sha512-Ac1OwHjSoUALrcnHTTD6oaEPITaxYmP34iiEEcuCxeeD+tOKR7/Toaw4RpJKcDmYxLX79ZP9E7z+Q8ze9pESbQ== + version "0.178.1" + resolved "https://registry.yarnpkg.com/flow-parser/-/flow-parser-0.178.1.tgz#4efe62b3c551c615411bd4a75031c881ff53a7da" + integrity sha512-TOvOfZVOhCsKAVU2E4QgFD5vmmF/JWl4bX77H4aYoq8No1mZdtUV8GW6wv03l8N3dmlRqAC5rZcDQ5e8aLDBOg== flux@^4.0.1: version "4.0.3" @@ -7533,10 +7534,10 @@ flux@^4.0.1: fbemitter "^3.0.0" fbjs "^3.0.1" -focus-options-polyfill@1.2.0: - version "1.2.0" - resolved "https://registry.yarnpkg.com/focus-options-polyfill/-/focus-options-polyfill-1.2.0.tgz#9800ffb230bc9db63eea6d27694a62ac2e355946" - integrity sha512-4sgXxV/zU4WHM2IHWpjUmEWazbF6ie+M93/uo8ipfAbQ1GHopn+/V+Ca+PR0ndxswNQbisCNrjbnvWEq14MkTA== +focus-options-polyfill@1.5.1: + version "1.5.1" + resolved "https://registry.yarnpkg.com/focus-options-polyfill/-/focus-options-polyfill-1.5.1.tgz#0f422580d9d1fb65651f2968b547032eb17dab3c" + integrity sha512-7yH20IePROHJLLbJvqqtsG420jE6DuukccapiB/WagtUpnc98r9NzHbX5rnjCDgdZqLgcqlzGjn+8l0Zb8Zf9w== follow-redirects@^1.0.0, follow-redirects@^1.14.0, follow-redirects@^1.14.7: version "1.15.0" @@ -7655,11 +7656,6 @@ fs-monkey@1.0.3: resolved "https://registry.yarnpkg.com/fs-monkey/-/fs-monkey-1.0.3.tgz#ae3ac92d53bb328efe0e9a1d9541f6ad8d48e2d3" integrity sha512-cybjIfiiE+pTWicSCLFHSrXZ6EilF30oh91FDP9S2B051prEa7QWfrVTQm10/dDpswBDXZugPa1Ogu8Yh+HV0Q== -fs-readdir-recursive@^1.1.0: - version "1.1.0" - resolved "https://registry.yarnpkg.com/fs-readdir-recursive/-/fs-readdir-recursive-1.1.0.tgz#e32fc030a2ccee44a6b5371308da54be0b397d27" - integrity sha512-GNanXlVr2pf02+sPN40XN8HG+ePaNcvM0q5mZBd668Obwb0yD5GiUbZOFgwn8kGMY6I3mdyDJzieUy3PTYyTRA== - fs.realpath@^1.0.0: version "1.0.0" resolved "https://registry.yarnpkg.com/fs.realpath/-/fs.realpath-1.0.0.tgz#1504ad2523158caa40db4a2787cb01411994ea4f" @@ -7891,28 +7887,27 @@ glob-to-regexp@^0.4.1: integrity sha512-lkX1HJXwyMcprw/5YUZc2s7DrpAiHB21/V+E1rHUrVNokkvB6bqMzT0VfV6/86ZNabt1k14YOIaT7nDvOX3Iiw== glob@^7.0.0, glob@^7.1.1, glob@^7.1.3, glob@^7.1.4, glob@^7.1.6: - version "7.2.0" - resolved "https://registry.yarnpkg.com/glob/-/glob-7.2.0.tgz#d15535af7732e02e948f4c41628bd910293f6023" - integrity sha512-lmLf6gtyrPq8tTjSmrO94wBeQbFR3HbLHbuyD69wuyQkImp2hWqMGB47OX65FBkPffO641IP9jWa1z4ivqG26Q== + version "7.2.3" + resolved "https://registry.yarnpkg.com/glob/-/glob-7.2.3.tgz#b8df0fb802bbfa8e89bd1d938b4e16578ed44f2b" + integrity sha512-nFR0zLpU2YCaRxwoCJvL6UvCH2JFyFVIvwTLsIf21AuHlMskA1hhTdk+LlYJtOlYt9v6dvszD2BGRqBL+iQK9Q== dependencies: fs.realpath "^1.0.0" inflight "^1.0.4" inherits "2" - minimatch "^3.0.4" + minimatch "^3.1.1" once "^1.3.0" path-is-absolute "^1.0.0" -glob@^8.0.1: - version "8.0.1" - resolved "https://registry.yarnpkg.com/glob/-/glob-8.0.1.tgz#00308f5c035aa0b2a447cd37ead267ddff1577d3" - integrity sha512-cF7FYZZ47YzmCu7dDy50xSRRfO3ErRfrXuLZcNIuyiJEco0XSrGtuilG19L5xp3NcwTx7Gn+X6Tv3fmsUPTbow== +glob@^8.0.3: + version "8.0.3" + resolved "https://registry.yarnpkg.com/glob/-/glob-8.0.3.tgz#415c6eb2deed9e502c68fa44a272e6da6eeca42e" + integrity sha512-ull455NHSHI/Y1FqGaaYFaLGkNMMJbavMrEGFXG/PGrg6y7sutWHUHrz6gy6WEBH6akM1M414dWKCNs+IhKdiQ== dependencies: fs.realpath "^1.0.0" inflight "^1.0.4" inherits "2" minimatch "^5.0.1" once "^1.3.0" - path-is-absolute "^1.0.0" global-dirs@^0.1.1: version "0.1.1" @@ -7949,10 +7944,10 @@ globals@^11.1.0: resolved "https://registry.yarnpkg.com/globals/-/globals-11.12.0.tgz#ab8795338868a0babd8525758018c2a7eb95c42e" integrity sha512-WOBp/EEGUiIsJSp7wcv/y6MO+lV9UoncWqxuFfm8eBwzWNgyfBd6Gz+IeKQ9jCmyhoH99g15M3T+QaVHFjizVA== -globals@^13.6.0, globals@^13.9.0: - version "13.14.0" - resolved "https://registry.yarnpkg.com/globals/-/globals-13.14.0.tgz#daf3ff9b4336527cf56e98330b6f64bea9aff9df" - integrity sha512-ERO68sOYwm5UuLvSJTY7w7NP2c8S4UcXs3X1GBX8cwOr+ShOcDBbCY5mH4zxz0jsYCdJ8ve8Mv9n2YGJMB1aeg== +globals@^13.15.0: + version "13.15.0" + resolved "https://registry.yarnpkg.com/globals/-/globals-13.15.0.tgz#38113218c907d2f7e98658af246cef8b77e90bac" + integrity sha512-bpzcOlgDhMG070Av0Vy5Owklpv1I6+j96GhUI7Rh7IzDCKLzboflLrrfqMu8NquDbiR4EOQk7XzJwqVJxicxog== dependencies: type-fest "^0.20.2" @@ -8418,6 +8413,16 @@ htmlparser2@^6.1.0: domutils "^2.5.2" entities "^2.0.0" +htmlparser2@^8.0.1: + version "8.0.1" + resolved "https://registry.yarnpkg.com/htmlparser2/-/htmlparser2-8.0.1.tgz#abaa985474fcefe269bc761a779b544d7196d010" + integrity sha512-4lVbmc1diZC7GUJQtRQ5yBAeUCL1exyMwmForWkRLnwyzWBFxN633SALPMGYaWZvKe9j1pRZJpauvmxENSp/EA== + dependencies: + domelementtype "^2.3.0" + domhandler "^5.0.2" + domutils "^3.0.1" + entities "^4.3.0" + http-cache-semantics@^4.0.0, http-cache-semantics@^4.1.0: version "4.1.0" resolved "https://registry.yarnpkg.com/http-cache-semantics/-/http-cache-semantics-4.1.0.tgz#49e91c5cbf36c9b94bcfcd71c23d5249ec74e390" @@ -8537,11 +8542,6 @@ husky@^8.0.1: resolved "https://registry.yarnpkg.com/husky/-/husky-8.0.1.tgz#511cb3e57de3e3190514ae49ed50f6bc3f50b3e9" integrity sha512-xs7/chUH/CKdOCs7Zy0Aev9e/dKOMZf3K1Az1nar3tzlv0jfqnYtu235bstsWTmXOR0EfINrPa97yy4Lz6RiKw== -hyphenate-style-name@^1.0.2: - version "1.0.4" - resolved "https://registry.yarnpkg.com/hyphenate-style-name/-/hyphenate-style-name-1.0.4.tgz#691879af8e220aea5750e8827db4ef62a54e361d" - integrity sha512-ygGZLjmXfPHj+ZWh6LwbC37l43MhfztxetbFCoYTM2VjkIUpeHgSNn7QIyVFj7YQ1Wl9Cbw5sholVJPzWvC2MQ== - iconv-lite@0.4.24, iconv-lite@^0.4.24: version "0.4.24" resolved "https://registry.yarnpkg.com/iconv-lite/-/iconv-lite-0.4.24.tgz#2022b4b25fbddc21d2f524974a474aafe733908b" @@ -8578,7 +8578,7 @@ ignore-walk@^3.0.3: dependencies: minimatch "^3.0.4" -ignore@^5.1.8, ignore@^5.1.9, ignore@^5.2.0: +ignore@^5.1.9, ignore@^5.2.0: version "5.2.0" resolved "https://registry.yarnpkg.com/ignore/-/ignore-5.2.0.tgz#6d3bac8fa7fe0d45d9f9be7bac2fc279577e345a" integrity sha512-CmxgYGiEPCLhfLnpPp1MoRmifwEIOgjcHXxOBjv7mY96c+eWScsOP9c112ZyLdWHi0FxHjI+4uVhKYp/gcdRmQ== @@ -8591,9 +8591,9 @@ image-size@^1.0.1: queue "6.0.2" immer@^9.0.7: - version "9.0.12" - resolved "https://registry.yarnpkg.com/immer/-/immer-9.0.12.tgz#2d33ddf3ee1d247deab9d707ca472c8c942a0f20" - integrity sha512-lk7UNmSbAukB5B6dh9fnh5D0bJTOFKxVg2cyJWTYrWRfhLrLMBquONcUs3aFq507hNoIZEDDh8lb8UtOizSMhA== + version "9.0.14" + resolved "https://registry.yarnpkg.com/immer/-/immer-9.0.14.tgz#e05b83b63999d26382bb71676c9d827831248a48" + integrity sha512-ubBeqQutOSLIFCUBN03jGeOS6a3DoYlSYwYJTa+gSKEZKU5redJIqkIdZ3JVv/4RZpfcXdAWH5zCNLWPRv2WDw== import-fresh@^3.0.0, import-fresh@^3.1.0, import-fresh@^3.2.1, import-fresh@^3.3.0: version "3.3.0" @@ -8687,13 +8687,6 @@ inline-style-parser@0.1.1: resolved "https://registry.yarnpkg.com/inline-style-parser/-/inline-style-parser-0.1.1.tgz#ec8a3b429274e9c0a1f1c4ffa9453a7fef72cea1" integrity sha512-7NXolsK4CAS5+xvdj5OMMbI962hU/wvwoxk+LWR9Ek9bVtyuuYScDN6eS0rUm6TxApFpw7CX1o4uJzcd4AyD3Q== -inline-style-prefixer@^6.0.0: - version "6.0.1" - resolved "https://registry.yarnpkg.com/inline-style-prefixer/-/inline-style-prefixer-6.0.1.tgz#c5c0e43ba8831707afc5f5bbfd97edf45c1fa7ae" - integrity sha512-AsqazZ8KcRzJ9YPN1wMH2aNM7lkWQ8tSPrW5uDk1ziYwiAPWSZnUsC7lfZq+BDqLqz0B4Pho5wscWcJzVvRzDQ== - dependencies: - css-in-js-utils "^2.0.0" - inquirer@^7.3.3: version "7.3.3" resolved "https://registry.yarnpkg.com/inquirer/-/inquirer-7.3.3.tgz#04d176b2af04afc157a83fd7c100e98ee0aad003" @@ -8735,9 +8728,9 @@ invariant@^2.2.4: loose-envify "^1.0.0" ip@^1.1.5: - version "1.1.6" - resolved "https://registry.yarnpkg.com/ip/-/ip-1.1.6.tgz#5a651a37644586e18b6ba3b48ca122bf56495f67" - integrity sha512-/dAvCivFs/VexXAtiAoMIqyhkhStNC9CPD0h1noonimOgB1xrCkexF2c5CjlqQ72GgMPjN6tiV+oreoPv3Ft1g== + version "1.1.8" + resolved "https://registry.yarnpkg.com/ip/-/ip-1.1.8.tgz#ae05948f6b075435ed3307acce04629da8cdbf48" + integrity sha512-PuExPYUiu6qMBQb4l06ecm6T6ujzhmh+MeJcW9wa89PoAz5pvd4zPgN5WJV104mb6S2T1AwNIAaB70JNrLQWhg== ipaddr.js@1.9.1: version "1.9.1" @@ -9667,11 +9660,6 @@ joi@^17.6.0: "@sideway/formula" "^3.0.0" "@sideway/pinpoint" "^2.0.0" -js-cookie@^2.2.1: - version "2.2.1" - resolved "https://registry.yarnpkg.com/js-cookie/-/js-cookie-2.2.1.tgz#69e106dc5d5806894562902aa5baec3744e9b2b8" - integrity sha512-HvdH2LzI/EAZcUwA8+0nKNtWHqS+ZmijLA30RwZA0bo7ToCckjK5MkGhjED9KoRcXO6BaGI3I9UIzSA1FKFPOQ== - "js-tokens@^3.0.0 || ^4.0.0", js-tokens@^4.0.0: version "4.0.0" resolved "https://registry.yarnpkg.com/js-tokens/-/js-tokens-4.0.0.tgz#19203fb59991df98e3a287050d4647cdeaf32499" @@ -9860,9 +9848,9 @@ jsprim@^1.2.2: object.assign "^4.1.2" katex@^0.15.0: - version "0.15.3" - resolved "https://registry.yarnpkg.com/katex/-/katex-0.15.3.tgz#08781a7ed26800b20380d959d1ffcd62bca0ec14" - integrity sha512-Al6V7RJsmjklT9QItyHWGaQCt+NYTle1bZwB1e9MR/tLoIT1MXaHy9UpfGSB7eaqDgjjqqRxQOaQGrALCrEyBQ== + version "0.15.6" + resolved "https://registry.yarnpkg.com/katex/-/katex-0.15.6.tgz#c4e2f6ced2ac4de1ef6f737fe7c67d3026baa0e5" + integrity sha512-UpzJy4yrnqnhXvRPhjEuLA4lcPn6eRngixW7Q3TJErjg3Aw2PuLFBzTkdUb89UtumxjhHTqL3a5GDGETMSwgJA== dependencies: commander "^8.0.0" @@ -10476,13 +10464,18 @@ media-typer@0.3.0: resolved "https://registry.yarnpkg.com/media-typer/-/media-typer-0.3.0.tgz#8710d7af0aa626f8fffa1ce00168545263255748" integrity sha512-dq+qelQ9akHpcOl/gUVRTxVIOkAJ1wR3QAvb4RsVjS8oVoFjDGTc679wJYmUmknUF5HwMLOgb5O+a3KxfWapPQ== -memfs@^3.1.2, memfs@^3.4.1: - version "3.4.1" - resolved "https://registry.yarnpkg.com/memfs/-/memfs-3.4.1.tgz#b78092f466a0dce054d63d39275b24c71d3f1305" - integrity sha512-1c9VPVvW5P7I85c35zAdEr1TD5+F11IToIHIlrVIcflfnzPkJa0ZoYEoEdYDP8KgPFoSZ/opDrUsAoZWym3mtw== +memfs@^3.1.2, memfs@^3.4.3: + version "3.4.3" + resolved "https://registry.yarnpkg.com/memfs/-/memfs-3.4.3.tgz#fc08ac32363b6ea6c95381cabb4d67838180d4e1" + integrity sha512-eivjfi7Ahr6eQTn44nvTnR60e4a1Fs1Via2kCR5lHo/kyNoiMWaXCNJ/GpSd0ilXas2JSOl9B5FTIhflXu0hlg== dependencies: fs-monkey "1.0.3" +memorystream@^0.3.1: + version "0.3.1" + resolved "https://registry.yarnpkg.com/memorystream/-/memorystream-0.3.1.tgz#86d7090b30ce455d63fbae12dda51a47ddcaf9b2" + integrity sha512-S3UwM3yj5mtUSEfP41UZmt/0SCoVYUcU1rkXv+BQ5Ig8ndL4sPoJNBUJERafdPb5jjHJGuMgytgKvKIf58XNBw== + meow@^8.0.0: version "8.1.2" resolved "https://registry.yarnpkg.com/meow/-/meow-8.1.2.tgz#bcbe45bda0ee1729d350c03cffc8395a36c4e897" @@ -10641,7 +10634,7 @@ minimatch@3.0.4: dependencies: brace-expansion "^1.1.7" -minimatch@^3.0.2, minimatch@^3.0.4, minimatch@^3.1.2: +minimatch@^3.0.2, minimatch@^3.0.4, minimatch@^3.1.1, minimatch@^3.1.2: version "3.1.2" resolved "https://registry.yarnpkg.com/minimatch/-/minimatch-3.1.2.tgz#19cd194bfd3e428f049a70817c038d89ab4be35b" integrity sha512-J7p63hRiAjw1NDEww1W7i37+ByIrOWO5XQQAzZ3VOcL0PNybwpfmV/N05zFAzwQ9USyEcX6t3UO+K5aqBQOIHw== @@ -10649,9 +10642,9 @@ minimatch@^3.0.2, minimatch@^3.0.4, minimatch@^3.1.2: brace-expansion "^1.1.7" minimatch@^5.0.1: - version "5.0.1" - resolved "https://registry.yarnpkg.com/minimatch/-/minimatch-5.0.1.tgz#fb9022f7528125187c92bd9e9b6366be1cf3415b" - integrity sha512-nLDxIFRyhDblz3qMuq+SoRZED4+miJ/G+tdDrjkkkRnjAsBexeGpgjLEQ0blJy7rHhR2b93rhQY4SvyWu9v03g== + version "5.1.0" + resolved "https://registry.yarnpkg.com/minimatch/-/minimatch-5.1.0.tgz#1717b464f4971b144f6aabe8f2d0b8e4511e09c7" + integrity sha512-9TPBGGak4nHfGZsPBohm9AWg6NoT7QTCehS3BIJABslyZbzxfV78QM2Y6+i741OPZIafFAaiiEMh5OyIrJPgtg== dependencies: brace-expansion "^2.0.1" @@ -10806,9 +10799,9 @@ ms@2.1.3, ms@^2.0.0, ms@^2.1.1: integrity sha512-6FlzubTLZG3J2a/NVCAleEhjzq5oxgHyaCU9yYXvcLsvoVaHJq/s5xXI6/XXP6tz7R9xAOtHnSO/tXtF3WRTlA== multicast-dns@^7.2.4: - version "7.2.4" - resolved "https://registry.yarnpkg.com/multicast-dns/-/multicast-dns-7.2.4.tgz#cf0b115c31e922aeb20b64e6556cbeb34cf0dd19" - integrity sha512-XkCYOU+rr2Ft3LI6w4ye51M3VK31qJXFIxu0XLw169PtKG0Zx47OrXeVW/GCYOfpC9s1yyyf1S+L8/4LY0J9Zw== + version "7.2.5" + resolved "https://registry.yarnpkg.com/multicast-dns/-/multicast-dns-7.2.5.tgz#77eb46057f4d7adbd16d9290fa7299f6fa64cced" + integrity sha512-2eznPJP8z2BFLX50tf0LuODrpINqP1RVIm/CObbTcBRITQgmC/TjcREF1NeTBzIcR5XO/ukWo+YHOjBbFwIupg== dependencies: dns-packet "^5.2.2" thunky "^1.0.2" @@ -10838,21 +10831,7 @@ mz@^2.4.0: object-assign "^4.0.1" thenify-all "^1.0.0" -nano-css@^5.3.1: - version "5.3.4" - resolved "https://registry.yarnpkg.com/nano-css/-/nano-css-5.3.4.tgz#40af6a83a76f84204f346e8ccaa9169cdae9167b" - integrity sha512-wfcviJB6NOxDIDfr7RFn/GlaN7I/Bhe4d39ZRCJ3xvZX60LVe2qZ+rDqM49nm4YT81gAjzS+ZklhKP/Gnfnubg== - dependencies: - css-tree "^1.1.2" - csstype "^3.0.6" - fastest-stable-stringify "^2.0.2" - inline-style-prefixer "^6.0.0" - rtl-css-js "^1.14.0" - sourcemap-codec "^1.4.8" - stacktrace-js "^2.0.2" - stylis "^4.0.6" - -nanoid@^3.3.3: +nanoid@^3.3.4: version "3.3.4" resolved "https://registry.yarnpkg.com/nanoid/-/nanoid-3.3.4.tgz#730b67e3cd09e2deacf03c027c81c9d9dbc5e8ab" integrity sha512-MqBkQh/OHTS2egovRtLk45wEyNXwF+cokD+1YPf9u5VfJiRdAiRwB2froX5Co9Rh20xs4siNPm8naNotSD6RBw== @@ -10899,6 +10878,11 @@ netlify-plugin-cache@^1.0.3: resolved "https://registry.yarnpkg.com/netlify-plugin-cache/-/netlify-plugin-cache-1.0.3.tgz#f60514e259dff2b3286b6d60b570bb1c81206794" integrity sha512-CTOwNWrTOP59T6y6unxQNnp1WX702v2R/faR5peSH94ebrYfyY4zT5IsRcIiHKq57jXeyCrhy0GLuTN8ktzuQg== +nice-try@^1.0.4: + version "1.0.5" + resolved "https://registry.yarnpkg.com/nice-try/-/nice-try-1.0.5.tgz#a3378a7696ce7d223e88fc9b764bd7ef1089e366" + integrity sha512-1nh45deeb5olNY7eX82BkPO7SSxR5SSYJiPTrTdFUVYwAl8CKMA5N9PjTYkHiRjisVcxcQ1HXdLhx2qxxJzLNQ== + njre@^0.2.0: version "0.2.0" resolved "https://registry.yarnpkg.com/njre/-/njre-0.2.0.tgz#e5abfbafafb3db4438fe6b149da9a733fab0bf3d" @@ -11043,11 +11027,6 @@ normalize-range@^0.1.2: resolved "https://registry.yarnpkg.com/normalize-range/-/normalize-range-0.1.2.tgz#2d10c06bdfd312ea9777695a4d28439456b75942" integrity sha512-bdok/XvKII3nUpklnV6P2hxtMNrCboOjAcyBuQnWEhO665FwrSNRxU+AqpsyvO6LgGYPspN+lu5CLtw4jPRKNA== -normalize-selector@^0.2.0: - version "0.2.0" - resolved "https://registry.yarnpkg.com/normalize-selector/-/normalize-selector-0.2.0.tgz#d0b145eb691189c63a78d201dc4fdb1293ef0c03" - integrity sha512-dxvWdI8gw6eAvk9BlPffgEoGfM7AdijoCwOEJge3e3ulT2XLgmU7KvvxprOaCu05Q1uGRHmOhHe1r6emZoKyFw== - normalize-url@^4.1.0: version "4.5.1" resolved "https://registry.yarnpkg.com/normalize-url/-/normalize-url-4.5.1.tgz#0dd90cf1288ee1d1313b87081c9a5932ee48518a" @@ -11146,6 +11125,21 @@ npm-registry-fetch@^9.0.0: minizlib "^2.0.0" npm-package-arg "^8.0.0" +npm-run-all@^4.1.5: + version "4.1.5" + resolved "https://registry.yarnpkg.com/npm-run-all/-/npm-run-all-4.1.5.tgz#04476202a15ee0e2e214080861bff12a51d98fba" + integrity sha512-Oo82gJDAVcaMdi3nuoKFavkIHBRVqQ1qvMb+9LHk/cF4P6B2m8aP04hGf7oL6wZ9BuGwX1onlLhpuoofSyoQDQ== + dependencies: + ansi-styles "^3.2.1" + chalk "^2.4.1" + cross-spawn "^6.0.5" + memorystream "^0.3.1" + minimatch "^3.0.4" + pidtree "^0.3.0" + read-pkg "^3.0.0" + shell-quote "^1.6.1" + string.prototype.padend "^3.0.0" + npm-run-path@^4.0.1: version "4.0.1" resolved "https://registry.yarnpkg.com/npm-run-path/-/npm-run-path-4.0.1.tgz#b7ecd1e5ed53da8e37a55e1c2269e0b97ed748ea" @@ -11217,9 +11211,9 @@ object-copy@^0.1.0: kind-of "^3.0.3" object-inspect@^1.12.0, object-inspect@^1.9.0: - version "1.12.0" - resolved "https://registry.yarnpkg.com/object-inspect/-/object-inspect-1.12.0.tgz#6e2c120e868fd1fd18cb4f18c31741d0d6e776f0" - integrity sha512-Ho2z80bVIvJloH+YzRmpZVQe87+qASmBUKZDWgx9cu+KDrX2ZDH/3tMy+gXbZETVGs2M8YdxObOh7XAtim9Y0g== + version "1.12.1" + resolved "https://registry.yarnpkg.com/object-inspect/-/object-inspect-1.12.1.tgz#28a661153bad7e470e4b01479ef1cb91ce511191" + integrity sha512-Y/jF6vnvEtOPGiKD1+q+X0CiUYRQtEHp89MLLUJ7TUivtH8Ugn2+3A7Rynqk7BRsAoqeOQWnFnjpDrKSxDgIGA== object-keys@^1.1.1: version "1.1.1" @@ -11262,15 +11256,16 @@ object.fromentries@^2.0.5: es-abstract "^1.19.1" object.getownpropertydescriptors@^2.0.3: - version "2.1.3" - resolved "https://registry.yarnpkg.com/object.getownpropertydescriptors/-/object.getownpropertydescriptors-2.1.3.tgz#b223cf38e17fefb97a63c10c91df72ccb386df9e" - integrity sha512-VdDoCwvJI4QdC6ndjpqFmoL3/+HxffFBbcJzKi5hwLLqqx3mdbedRpfZDdK0SrOSauj8X4GzBvnDZl4vTN7dOw== + version "2.1.4" + resolved "https://registry.yarnpkg.com/object.getownpropertydescriptors/-/object.getownpropertydescriptors-2.1.4.tgz#7965e6437a57278b587383831a9b829455a4bc37" + integrity sha512-sccv3L/pMModT6dJAYF3fzGMVcb38ysQ0tEE6ixv2yXJDtEIPph268OlAdJj5/qZMZDq2g/jqvwppt36uS/uQQ== dependencies: + array.prototype.reduce "^1.0.4" call-bind "^1.0.2" - define-properties "^1.1.3" - es-abstract "^1.19.1" + define-properties "^1.1.4" + es-abstract "^1.20.1" -object.hasown@^1.1.0: +object.hasown@^1.1.1: version "1.1.1" resolved "https://registry.yarnpkg.com/object.hasown/-/object.hasown-1.1.1.tgz#ad1eecc60d03f49460600430d97f23882cf592a3" integrity sha512-LYLe4tivNQzq4JdaWW6WO3HMZZJWzkkH8fnI6EebWl0VZth2wL2Lovm74ep2/gZzlaTdV62JZHEqHQ2yVn8Q/A== @@ -11621,13 +11616,21 @@ parse-url@^6.0.0: parse-path "^4.0.0" protocols "^1.4.0" -parse5-htmlparser2-tree-adapter@^6.0.0, parse5-htmlparser2-tree-adapter@^6.0.1: +parse5-htmlparser2-tree-adapter@^6.0.0: version "6.0.1" resolved "https://registry.yarnpkg.com/parse5-htmlparser2-tree-adapter/-/parse5-htmlparser2-tree-adapter-6.0.1.tgz#2cdf9ad823321140370d4dbf5d3e92c7c8ddc6e6" integrity sha512-qPuWvbLgvDGilKc5BoicRovlT4MtYT6JfJyBOMDsKoiT+GiuP5qyrPCnR9HcPECIJJmZh5jRndyNThnhhb/vlA== dependencies: parse5 "^6.0.1" +parse5-htmlparser2-tree-adapter@^7.0.0: + version "7.0.0" + resolved "https://registry.yarnpkg.com/parse5-htmlparser2-tree-adapter/-/parse5-htmlparser2-tree-adapter-7.0.0.tgz#23c2cc233bcf09bb7beba8b8a69d46b08c62c2f1" + integrity sha512-B77tOZrqqfUfnVcOrUvfdLbz4pu4RopLD/4vmu3HUPswwTA8OH0EMW9BlWR2B0RCoiZRAHEUu7IxeP1Pd1UU+g== + dependencies: + domhandler "^5.0.2" + parse5 "^7.0.0" + parse5@6.0.1, parse5@^6.0.0, parse5@^6.0.1: version "6.0.1" resolved "https://registry.yarnpkg.com/parse5/-/parse5-6.0.1.tgz#e1a1c085c569b3dc08321184f19a39cc27f7c30b" @@ -11638,6 +11641,13 @@ parse5@^5.0.0, parse5@^5.1.1: resolved "https://registry.yarnpkg.com/parse5/-/parse5-5.1.1.tgz#f68e4e5ba1852ac2cadc00f4555fff6c2abb6178" integrity sha512-ugq4DFI0Ptb+WWjAdOK16+u/nHfiIrcE+sh8kZMaM0WllQKLI9rOUq6c2b7cwPkXdzfQESqvoqK6ug7U/Yyzug== +parse5@^7.0.0: + version "7.0.0" + resolved "https://registry.yarnpkg.com/parse5/-/parse5-7.0.0.tgz#51f74a5257f5fcc536389e8c2d0b3802e1bfa91a" + integrity sha512-y/t8IXSPWTuRZqXc0ajH/UwDj4mnqLEbSttNbThcFhGrZuOyoyvNBO85PBp2jQa55wY9d07PBNjsK8ZP3K5U6g== + dependencies: + entities "^4.3.0" + parseurl@~1.3.2, parseurl@~1.3.3: version "1.3.3" resolved "https://registry.yarnpkg.com/parseurl/-/parseurl-1.3.3.tgz#9da19e7bee8d12dff0513ed5b76957793bc2e8d4" @@ -11676,6 +11686,11 @@ path-is-inside@1.0.2: resolved "https://registry.yarnpkg.com/path-is-inside/-/path-is-inside-1.0.2.tgz#365417dede44430d1c11af61027facf074bdfc53" integrity sha512-DUWJr3+ULp4zXmol/SZkFf3JGsS9/SIv+Y3Rt93/UjPpDpklB5f1er4O3POIbUuUJ3FXgqte2Q7SrU6zAqwk8w== +path-key@^2.0.1: + version "2.0.1" + resolved "https://registry.yarnpkg.com/path-key/-/path-key-2.0.1.tgz#411cadb574c5a140d3a4b1910d40d80cc9f40b40" + integrity sha512-fEHGKCSmUSDPv4uoj8AlD+joPlq3peND+HRYyxFz4KPw4z926S/b8rIuFs2FYJg3BwsxJf6A9/3eIdLaYC+9Dw== + path-key@^3.0.0, path-key@^3.1.0: version "3.1.1" resolved "https://registry.yarnpkg.com/path-key/-/path-key-3.1.1.tgz#581f6ade658cbba65a0d3380de7753295054f375" @@ -11740,6 +11755,11 @@ picomatch@^2.0.4, picomatch@^2.2.1, picomatch@^2.2.2, picomatch@^2.2.3, picomatc resolved "https://registry.yarnpkg.com/picomatch/-/picomatch-2.3.1.tgz#3ba3833733646d9d3e4995946c1365a67fb07a42" integrity sha512-JU3teHTNjmE2VCGFzuY8EXzCDVwEqB2a8fsIvwaStHhAWJEeVd1o1QD80CU6+ZdEXXSLbSsuLwJjkCBWqRQUVA== +pidtree@^0.3.0: + version "0.3.1" + resolved "https://registry.yarnpkg.com/pidtree/-/pidtree-0.3.1.tgz#ef09ac2cc0533df1f3250ccf2c4d366b0d12114a" + integrity sha512-qQbW94hLHEqCg7nhby4yRC7G2+jYHY4Rguc2bjw7Uug4GIJuu1tvf2uHaZv5Q8zdt+WKJ6qK1FOI6amaWUo5FA== + pidtree@^0.5.0: version "0.5.0" resolved "https://registry.yarnpkg.com/pidtree/-/pidtree-0.5.0.tgz#ad5fbc1de78b8a5f99d6fbdd4f6e4eee21d1aca1" @@ -11814,11 +11834,12 @@ postcss-colormin@^5.3.0: colord "^2.9.1" postcss-value-parser "^4.2.0" -postcss-convert-values@^5.1.0: - version "5.1.0" - resolved "https://registry.yarnpkg.com/postcss-convert-values/-/postcss-convert-values-5.1.0.tgz#f8d3abe40b4ce4b1470702a0706343eac17e7c10" - integrity sha512-GkyPbZEYJiWtQB0KZ0X6qusqFHUepguBCNFi9t5JJc7I2OTXG7C0twbTLvCfaKOLl3rSXmpAwV7W5txd91V84g== +postcss-convert-values@^5.1.1: + version "5.1.1" + resolved "https://registry.yarnpkg.com/postcss-convert-values/-/postcss-convert-values-5.1.1.tgz#31c8ffba650e86dc750631cafcf1db022c5bb6f1" + integrity sha512-UjcYfl3wJJdcabGKk8lgetPvhi1Et7VDc3sYr9EyhNBeB00YD4vHgPBp+oMVoG/dDWCc6ASbmzPNV6jADTwh8Q== dependencies: + browserslist "^4.20.3" postcss-value-parser "^4.2.0" postcss-discard-comments@^5.1.1: @@ -11878,10 +11899,10 @@ postcss-merge-idents@^5.1.1: cssnano-utils "^3.1.0" postcss-value-parser "^4.2.0" -postcss-merge-longhand@^5.1.4: - version "5.1.4" - resolved "https://registry.yarnpkg.com/postcss-merge-longhand/-/postcss-merge-longhand-5.1.4.tgz#0f46f8753989a33260efc47de9a0cdc571f2ec5c" - integrity sha512-hbqRRqYfmXoGpzYKeW0/NCZhvNyQIlQeWVSao5iKWdyx7skLvCfQFGIUsP9NUs3dSbPac2IC4Go85/zG+7MlmA== +postcss-merge-longhand@^5.1.5: + version "5.1.5" + resolved "https://registry.yarnpkg.com/postcss-merge-longhand/-/postcss-merge-longhand-5.1.5.tgz#b0e03bee3b964336f5f33c4fc8eacae608e91c05" + integrity sha512-NOG1grw9wIO+60arKa2YYsrbgvP6tp+jqc7+ZD5/MalIw234ooH2C6KlR6FEn4yle7GqZoBxSK1mLBE9KPur6w== dependencies: postcss-value-parser "^4.2.0" stylehacks "^5.1.0" @@ -11912,10 +11933,10 @@ postcss-minify-gradients@^5.1.1: cssnano-utils "^3.1.0" postcss-value-parser "^4.2.0" -postcss-minify-params@^5.1.2: - version "5.1.2" - resolved "https://registry.yarnpkg.com/postcss-minify-params/-/postcss-minify-params-5.1.2.tgz#77e250780c64198289c954884ebe3ee4481c3b1c" - integrity sha512-aEP+p71S/urY48HWaRHasyx4WHQJyOYaKpQ6eXl8k0kxg66Wt/30VR6/woh8THgcpRbonJD5IeD+CzNhPi1L8g== +postcss-minify-params@^5.1.3: + version "5.1.3" + resolved "https://registry.yarnpkg.com/postcss-minify-params/-/postcss-minify-params-5.1.3.tgz#ac41a6465be2db735099bbd1798d85079a6dc1f9" + integrity sha512-bkzpWcjykkqIujNL+EVEPOlLYi/eZ050oImVtHU7b4lFS82jPnsCb44gvC6pxaNt38Els3jWYDHTjHKf0koTgg== dependencies: browserslist "^4.16.6" cssnano-utils "^3.1.0" @@ -12107,12 +12128,12 @@ postcss@^7.0.18, postcss@^7.0.39: picocolors "^0.2.1" source-map "^0.6.1" -postcss@^8.2.x, postcss@^8.3.11, postcss@^8.3.5, postcss@^8.4.13, postcss@^8.4.7: - version "8.4.13" - resolved "https://registry.yarnpkg.com/postcss/-/postcss-8.4.13.tgz#7c87bc268e79f7f86524235821dfdf9f73e5d575" - integrity sha512-jtL6eTBrza5MPzy8oJLFuUscHDXTV5KcLlqAWHl5q5WYRfnNRGSmOZmOZ1T6Gy7A99mOZfqungmZMpMmCVJ8ZA== +postcss@^8.2.x, postcss@^8.3.11, postcss@^8.3.5, postcss@^8.4.13, postcss@^8.4.14, postcss@^8.4.7: + version "8.4.14" + resolved "https://registry.yarnpkg.com/postcss/-/postcss-8.4.14.tgz#ee9274d5622b4858c1007a74d76e42e56fd21caf" + integrity sha512-E398TUmfAYFPBSdzgeieK2Y1+1cpdxJx8yXbK/m57nRhKSmk1GB2tO4lbLBtlkfPQTDKfe4Xqv1ASWPpayPEig== dependencies: - nanoid "^3.3.3" + nanoid "^3.3.4" picocolors "^1.0.0" source-map-js "^1.0.2" @@ -12192,10 +12213,10 @@ pretty-time@^1.1.0: resolved "https://registry.yarnpkg.com/pretty-time/-/pretty-time-1.1.0.tgz#ffb7429afabb8535c346a34e41873adf3d74dd0e" integrity sha512-28iF6xPQrP8Oa6uxE6a1biz+lWeTOAPKggvjB8HAs6nVMKZwf5bG++632Dx614hIWgUPkgivRfG+a8uAXGTIbA== -prism-react-renderer@^1.0.1, prism-react-renderer@^1.3.1: - version "1.3.1" - resolved "https://registry.yarnpkg.com/prism-react-renderer/-/prism-react-renderer-1.3.1.tgz#88fc9d0df6bed06ca2b9097421349f8c2f24e30d" - integrity sha512-xUeDMEz074d0zc5y6rxiMp/dlC7C+5IDDlaEUlcBOFE2wddz7hz5PNupb087mPwTt7T9BrFmewObfCBuf/LKwQ== +prism-react-renderer@^1.0.1, prism-react-renderer@^1.3.3: + version "1.3.3" + resolved "https://registry.yarnpkg.com/prism-react-renderer/-/prism-react-renderer-1.3.3.tgz#9b5a4211a6756eee3c96fee9a05733abc0b0805c" + integrity sha512-Viur/7tBTCH2HmYzwCHmt2rEFn+rdIWNIINXyg0StiISbDiIhHKhrFuEK8eMkKgvsIYSjgGqy/hNyucHp6FpoQ== prismjs@^1.28.0: version "1.28.0" @@ -12547,14 +12568,13 @@ react-loadable-ssr-addon-v5-slorber@^1.0.1: dependencies: "@babel/runtime" "^7.10.3" -react-medium-image-zoom@^4.3.7: - version "4.3.7" - resolved "https://registry.yarnpkg.com/react-medium-image-zoom/-/react-medium-image-zoom-4.3.7.tgz#06c0771401c6de312a85843d1feebd15641a969b" - integrity sha512-Vg1M8CIX1EfhfSsmNc2tHP+8KjPDo9e5/zEDaSsfeTBHI82wjEvW3Lgb4k3jdWILPZVOWhM+7QHyDaAzghlvaQ== +react-medium-image-zoom@^4.4.0: + version "4.4.0" + resolved "https://registry.yarnpkg.com/react-medium-image-zoom/-/react-medium-image-zoom-4.4.0.tgz#aa9f63dc08ffc2c2c919f16f3918f13951998a41" + integrity sha512-Y+1enQKyeM/ASAmvlKkLw0USbHePP5dbdjNSclHDBvzGLD8+tUqgxjjtTS54tMvvll7OSxTThVaXxrvO0uYO6A== dependencies: - focus-options-polyfill "1.2.0" - react-use "^17.2.1" - tslib "^2.1.0" + focus-options-polyfill "1.5.1" + tslib "^2.4.0" react-popper@^2.3.0: version "2.3.0" @@ -12571,23 +12591,23 @@ react-router-config@^5.1.1: dependencies: "@babel/runtime" "^7.1.2" -react-router-dom@^5.2.0: - version "5.3.1" - resolved "https://registry.yarnpkg.com/react-router-dom/-/react-router-dom-5.3.1.tgz#0151baf2365c5fcd8493f6ec9b9b31f34d0f8ae1" - integrity sha512-f0pj/gMAbv9e8gahTmCEY20oFhxhrmHwYeIwH5EO5xu0qme+wXtsdB8YfUOAZzUz4VaXmb58m3ceiLtjMhqYmQ== +react-router-dom@^5.3.3: + version "5.3.3" + resolved "https://registry.yarnpkg.com/react-router-dom/-/react-router-dom-5.3.3.tgz#8779fc28e6691d07afcaf98406d3812fe6f11199" + integrity sha512-Ov0tGPMBgqmbu5CDmN++tv2HQ9HlWDuWIIqn4b88gjlAN5IHI+4ZUZRcpz9Hl0azFIwihbLDYw1OiHGRo7ZIng== dependencies: "@babel/runtime" "^7.12.13" history "^4.9.0" loose-envify "^1.3.1" prop-types "^15.6.2" - react-router "5.3.1" + react-router "5.3.3" tiny-invariant "^1.0.2" tiny-warning "^1.0.0" -react-router@5.3.1, react-router@^5.2.0: - version "5.3.1" - resolved "https://registry.yarnpkg.com/react-router/-/react-router-5.3.1.tgz#b13e84a016c79b9e80dde123ca4112c4f117e3cf" - integrity sha512-v+zwjqb7bakqgF+wMVKlAPTca/cEmPOvQ9zt7gpSNyPXau1+0qvuYZ5BWzzNDP1y6s15zDwgb9rPN63+SIniRQ== +react-router@5.3.3, react-router@^5.3.3: + version "5.3.3" + resolved "https://registry.yarnpkg.com/react-router/-/react-router-5.3.3.tgz#8e3841f4089e728cf82a429d92cdcaa5e4a3a288" + integrity sha512-mzQGUvS3bM84TnbtMYR8ZjKnuPJ71IjSzR+DE6UkUqvN4czWIqEs17yLL8xkAycv4ev0AiN+IGrWu88vJs/p2w== dependencies: "@babel/runtime" "^7.12.13" history "^4.9.0" @@ -12624,38 +12644,13 @@ react-test-renderer@^17.0.2: scheduler "^0.20.2" react-textarea-autosize@^8.3.2: - version "8.3.3" - resolved "https://registry.yarnpkg.com/react-textarea-autosize/-/react-textarea-autosize-8.3.3.tgz#f70913945369da453fd554c168f6baacd1fa04d8" - integrity sha512-2XlHXK2TDxS6vbQaoPbMOfQ8GK7+irc2fVK6QFIcC8GOnH3zI/v481n+j1L0WaPVvKxwesnY93fEfH++sus2rQ== + version "8.3.4" + resolved "https://registry.yarnpkg.com/react-textarea-autosize/-/react-textarea-autosize-8.3.4.tgz#270a343de7ad350534141b02c9cb78903e553524" + integrity sha512-CdtmP8Dc19xL8/R6sWvtknD/eCXkQr30dtvC4VmGInhRsfF8X/ihXCq6+9l9qbxmKRiq407/7z5fxE7cVWQNgQ== dependencies: "@babel/runtime" "^7.10.2" - use-composed-ref "^1.0.0" - use-latest "^1.0.0" - -react-universal-interface@^0.6.2: - version "0.6.2" - resolved "https://registry.yarnpkg.com/react-universal-interface/-/react-universal-interface-0.6.2.tgz#5e8d438a01729a4dbbcbeeceb0b86be146fe2b3b" - integrity sha512-dg8yXdcQmvgR13RIlZbTRQOoUrDciFVoSBZILwjE2LFISxZZ8loVJKAkuzswl5js8BHda79bIb2b84ehU8IjXw== - -react-use@^17.2.1: - version "17.3.2" - resolved "https://registry.yarnpkg.com/react-use/-/react-use-17.3.2.tgz#448abf515f47c41c32455024db28167cb6e53be8" - integrity sha512-bj7OD0/1wL03KyWmzFXAFe425zziuTf7q8olwCYBfOeFHY1qfO1FAMjROQLsLZYwG4Rx63xAfb7XAbBrJsZmEw== - dependencies: - "@types/js-cookie" "^2.2.6" - "@xobotyi/scrollbar-width" "^1.9.5" - copy-to-clipboard "^3.3.1" - fast-deep-equal "^3.1.3" - fast-shallow-equal "^1.0.0" - js-cookie "^2.2.1" - nano-css "^5.3.1" - react-universal-interface "^0.6.2" - resize-observer-polyfill "^1.5.1" - screenfull "^5.1.0" - set-harmonic-interval "^1.0.1" - throttle-debounce "^3.0.1" - ts-easing "^0.2.0" - tslib "^2.1.0" + use-composed-ref "^1.3.0" + use-latest "^1.2.1" react-waypoint@^10.1.0: version "10.1.0" @@ -12908,7 +12903,7 @@ regexp-ast-analysis@^0.5.1: refa "^0.9.0" regexpp "^3.2.0" -regexp.prototype.flags@^1.4.1: +regexp.prototype.flags@^1.4.1, regexp.prototype.flags@^1.4.3: version "1.4.3" resolved "https://registry.yarnpkg.com/regexp.prototype.flags/-/regexp.prototype.flags-1.4.3.tgz#87cab30f80f66660181a3bb7bf5981a872b367ac" integrity sha512-fjggEOO3slI6Wvgjwflkc4NFRCTZAu5CnNfBd5qOMYhWdn67nJBBu34/TkD++eeFmd8C9r9jfXJ27+nSiRkSUA== @@ -13197,11 +13192,6 @@ requires-port@^1.0.0: resolved "https://registry.yarnpkg.com/requires-port/-/requires-port-1.0.0.tgz#925d2601d39ac485e091cf0da5c6e694dc3dcaff" integrity sha512-KigOCHcocU3XODJxsu8i/j8T9tzT4adHiecwORRQ0ZZFcp7ahwXuRU1m+yuO90C5ZUyGeGfocHDI14M3L3yDAQ== -resize-observer-polyfill@^1.5.1: - version "1.5.1" - resolved "https://registry.yarnpkg.com/resize-observer-polyfill/-/resize-observer-polyfill-1.5.1.tgz#0e9020dd3d21024458d4ebd27e23e40269810464" - integrity sha512-LwZrotdHOo12nQuZlHEmtuXdqGoOD0OhaxopaNFxWzInpEgaLWoVuAMbTzixuosCx2nEG58ngzW3vxdWoxIgdg== - resolve-cwd@^3.0.0: version "3.0.0" resolved "https://registry.yarnpkg.com/resolve-cwd/-/resolve-cwd-3.0.0.tgz#0f0075f1bb2544766cf73ba6a6e2adfebcb13f2d" @@ -13330,19 +13320,12 @@ rollup-plugin-terser@^7.0.0: terser "^5.0.0" rollup@^2.43.1: - version "2.72.1" - resolved "https://registry.yarnpkg.com/rollup/-/rollup-2.72.1.tgz#861c94790537b10008f0ca0fbc60e631aabdd045" - integrity sha512-NTc5UGy/NWFGpSqF1lFY8z9Adri6uhyMLI6LvPAXdBKoPRFhIIiBUpt+Qg2awixqO3xvzSijjhnb4+QEZwJmxA== + version "2.74.1" + resolved "https://registry.yarnpkg.com/rollup/-/rollup-2.74.1.tgz#4fba0ff1c312cc4ee82691b154eee69a0d01929f" + integrity sha512-K2zW7kV8Voua5eGkbnBtWYfMIhYhT9Pel2uhBk2WO5eMee161nPze/XRfvEQPFYz7KgrCCnmh2Wy0AMFLGGmMA== optionalDependencies: fsevents "~2.3.2" -rtl-css-js@^1.14.0: - version "1.15.0" - resolved "https://registry.yarnpkg.com/rtl-css-js/-/rtl-css-js-1.15.0.tgz#680ed816e570a9ebccba9e1cd0f202c6a8bb2dc0" - integrity sha512-99Cu4wNNIhrI10xxUaABHsdDqzalrSRTie4GeCmbGVuehm4oj+fIy8fTzB+16pmKe8Bv9rl+hxIBez6KxExTew== - dependencies: - "@babel/runtime" "^7.1.2" - rtl-detect@^1.0.4: version "1.0.4" resolved "https://registry.yarnpkg.com/rtl-detect/-/rtl-detect-1.0.4.tgz#40ae0ea7302a150b96bc75af7d749607392ecac6" @@ -13370,7 +13353,7 @@ run-parallel@^1.1.9: dependencies: queue-microtask "^1.2.2" -rxjs@^6.6.0, rxjs@^6.6.3: +rxjs@^6.6.0: version "6.6.7" resolved "https://registry.yarnpkg.com/rxjs/-/rxjs-6.6.7.tgz#90ac018acabf491bf65044235d5863c4dab804c9" integrity sha512-hTdwr+7yYNIT5n4AMYp85KA6yw2Va0FLa3Rguvbpa4W3I5xynaBZo41cM3XM+4Q6fRMj3sBYIR1VAmZMXYJvRQ== @@ -13463,11 +13446,6 @@ schema-utils@^4.0.0: ajv-formats "^2.1.1" ajv-keywords "^5.0.0" -screenfull@^5.1.0: - version "5.2.0" - resolved "https://registry.yarnpkg.com/screenfull/-/screenfull-5.2.0.tgz#6533d524d30621fc1283b9692146f3f13a93d1ba" - integrity sha512-9BakfsO2aUQN2K9Fdbj87RJIEZ82Q9IGim7FqM5OsebfoFC6ZHXgDq/KvniuLTPdeM8wY2o6Dj3WQ7KeQCj3cA== - scslre@^0.1.6: version "0.1.6" resolved "https://registry.yarnpkg.com/scslre/-/scslre-0.1.6.tgz#71a2832e4bf3a9254973a04fbed90aec94f75757" @@ -13504,7 +13482,7 @@ semver-diff@^3.1.1: dependencies: semver "^6.3.0" -"semver@2 || 3 || 4 || 5", semver@^5.4.1, semver@^5.6.0, semver@^5.7.1: +"semver@2 || 3 || 4 || 5", semver@^5.4.1, semver@^5.5.0, semver@^5.6.0, semver@^5.7.1: version "5.7.1" resolved "https://registry.yarnpkg.com/semver/-/semver-5.7.1.tgz#a954f931aeba508d307bbf069eff0c01c96116f7" integrity sha512-sauaDf/PZdVgrLTNYHRtpXa1iRiKcaebiKQ1BJdpQlWH2lCvexQdX55snPFyK7QzpudqbCI0qXFfOasHdyNDGQ== @@ -13601,11 +13579,6 @@ set-blocking@~2.0.0: resolved "https://registry.yarnpkg.com/set-blocking/-/set-blocking-2.0.0.tgz#045f9782d011ae9a6803ddd382b24392b3d890f7" integrity sha512-KiKBS8AnWGEyLzofFfmvKwpdPzqiy16LvQfK3yv/fVH7Bj13/wl3JSR1J+rfgRE9q7xUJK4qvgS8raSOeLUehw== -set-harmonic-interval@^1.0.1: - version "1.0.1" - resolved "https://registry.yarnpkg.com/set-harmonic-interval/-/set-harmonic-interval-1.0.1.tgz#e1773705539cdfb80ce1c3d99e7f298bb3995249" - integrity sha512-AhICkFV84tBP1aWqPwLZqFvAwqEoVA9kxNMniGEUvzOlm4vLmOFLiTT3UZ6bziJTy4bOVpzWGTfSCbmaayGx8g== - set-value@^2.0.0, set-value@^2.0.1: version "2.0.1" resolved "https://registry.yarnpkg.com/set-value/-/set-value-2.0.1.tgz#a18d40530e6f07de4228c7defe4227af8cad005b" @@ -13657,6 +13630,13 @@ sharp@^0.30.4: tar-fs "^2.1.1" tunnel-agent "^0.6.0" +shebang-command@^1.2.0: + version "1.2.0" + resolved "https://registry.yarnpkg.com/shebang-command/-/shebang-command-1.2.0.tgz#44aac65b695b03398968c39f363fee5deafdf1ea" + integrity sha512-EV3L1+UQWGor21OmnvojK36mhg+TyIKDh3iFBKBohr5xeXIhNBcx8oWdgkTEEQ+BEFFYdLRuqMfd5L84N1V5Vg== + dependencies: + shebang-regex "^1.0.0" + shebang-command@^2.0.0: version "2.0.0" resolved "https://registry.yarnpkg.com/shebang-command/-/shebang-command-2.0.0.tgz#ccd0af4f8835fbdc265b82461aaf0c36663f34ea" @@ -13664,12 +13644,17 @@ shebang-command@^2.0.0: dependencies: shebang-regex "^3.0.0" +shebang-regex@^1.0.0: + version "1.0.0" + resolved "https://registry.yarnpkg.com/shebang-regex/-/shebang-regex-1.0.0.tgz#da42f49740c0b42db2ca9728571cb190c98efea3" + integrity sha512-wpoSFAxys6b2a2wHZ1XpDSgD7N9iVjg29Ph9uV/uaP9Ex/KXlkTZTeddxDPSYQpgvzKLGJke2UU0AzoGCjNIvQ== + shebang-regex@^3.0.0: version "3.0.0" resolved "https://registry.yarnpkg.com/shebang-regex/-/shebang-regex-3.0.0.tgz#ae16f1644d873ecad843b0307b143362d4c42172" integrity sha512-7++dFhtcx3353uBaq8DDR4NuxBetBzC7ZQOhmTQInHEd6bSrXdiEyzCvG07Z44UYdLShWUyXt5M/yhz8ekcb1A== -shell-quote@^1.7.3: +shell-quote@^1.6.1, shell-quote@^1.7.3: version "1.7.3" resolved "https://registry.yarnpkg.com/shell-quote/-/shell-quote-1.7.3.tgz#aa40edac170445b9a431e17bb62c0b881b9c4123" integrity sha512-Vpfqwm4EnqGdlsBFNmHhxhElJYrdfcxPThu+ryKS5J8L/fhAwLazFZtq+S+TWZ9ANj2piSQLGj6NQg+lKPmxrw== @@ -13742,11 +13727,6 @@ sitemap@^7.1.1: arg "^5.0.0" sax "^1.2.4" -slash@^2.0.0: - version "2.0.0" - resolved "https://registry.yarnpkg.com/slash/-/slash-2.0.0.tgz#de552851a1759df3a8f206535442f5ec4ddeab44" - integrity sha512-ZYKh3Wh2z1PpEXWr0MpSBZ0V6mZHAQfYevttO11c51CaWjGTaadiKZ+wVt1PbMlDV5qhMFslpZCemhwOK7C89A== - slash@^3.0.0: version "3.0.0" resolved "https://registry.yarnpkg.com/slash/-/slash-3.0.0.tgz#6539be870c165adbd5240220dbe361f1bc4d4634" @@ -13919,11 +13899,6 @@ source-map-url@^0.4.0: resolved "https://registry.yarnpkg.com/source-map-url/-/source-map-url-0.4.1.tgz#0af66605a745a5a2f91cf1bbf8a7afbc283dec56" integrity sha512-cPiFOTLUKvJFIg4SKVScy4ilPPW6rFgMgfuZJPNoDuMs3nC1HbMUycBoJw77xFIp6z1UJQJOfx6C9GMH80DiTw== -source-map@0.5.6: - version "0.5.6" - resolved "https://registry.yarnpkg.com/source-map/-/source-map-0.5.6.tgz#75ce38f52bf0733c5a7f0c118d81334a2bb5f412" - integrity sha512-MjZkVp0NHr5+TPihLcadqnlVoGIoWo4IBHptutGh9wI3ttUYvCG26HkSuDi+K6lsZ25syXJXcctwgyVCt//xqA== - source-map@^0.5.0, source-map@^0.5.6: version "0.5.7" resolved "https://registry.yarnpkg.com/source-map/-/source-map-0.5.7.tgz#8a039d2d1021d22d1ea14c80d8ea468ba2ef3fcc" @@ -13961,11 +13936,6 @@ space-separated-tokens@^2.0.0: resolved "https://registry.yarnpkg.com/space-separated-tokens/-/space-separated-tokens-2.0.1.tgz#43193cec4fb858a2ce934b7f98b7f2c18107098b" integrity sha512-ekwEbFp5aqSPKaqeY1PGrlGQxPNaq+Cnx4+bE2D8sciBQrHpbwoBbawqTN2+6jPs9IdWxxiUcN0K2pkczD3zmw== -spawn-command@^0.0.2-1: - version "0.0.2-1" - resolved "https://registry.yarnpkg.com/spawn-command/-/spawn-command-0.0.2-1.tgz#62f5e9466981c1b796dc5929937e11c9c6921bd0" - integrity sha512-n98l9E2RMSJ9ON1AKisHzz7V42VDiBQGY6PB1BwRglz99wpVsSuGzQ+jOi6lFXBGVTCrRpltvjm+/XA+tpeJrg== - spdx-correct@^3.0.0: version "3.1.1" resolved "https://registry.yarnpkg.com/spdx-correct/-/spdx-correct-3.1.1.tgz#dece81ac9c1e6713e5f7d1b6f17d468fa53d89a9" @@ -14078,13 +14048,6 @@ stable@^0.1.8: resolved "https://registry.yarnpkg.com/stable/-/stable-0.1.8.tgz#836eb3c8382fe2936feaf544631017ce7d47a3cf" integrity sha512-ji9qxRnOVfcuLDySj9qzhGSEFVobyt1kIOSkj1qZzYLzq7Tos/oUUWvotUPQLlrsidqsK6tBH89Bc9kL5zHA6w== -stack-generator@^2.0.5: - version "2.0.5" - resolved "https://registry.yarnpkg.com/stack-generator/-/stack-generator-2.0.5.tgz#fb00e5b4ee97de603e0773ea78ce944d81596c36" - integrity sha512-/t1ebrbHkrLrDuNMdeAcsvynWgoH/i4o8EGGfX7dEYDoTXOYVAkEpFdtshlvabzc6JlJ8Kf9YdFEoz7JkzGN9Q== - dependencies: - stackframe "^1.1.1" - stack-utils@^2.0.3: version "2.0.5" resolved "https://registry.yarnpkg.com/stack-utils/-/stack-utils-2.0.5.tgz#d25265fca995154659dbbfba3b49254778d2fdd5" @@ -14092,28 +14055,6 @@ stack-utils@^2.0.3: dependencies: escape-string-regexp "^2.0.0" -stackframe@^1.1.1: - version "1.2.1" - resolved "https://registry.yarnpkg.com/stackframe/-/stackframe-1.2.1.tgz#1033a3473ee67f08e2f2fc8eba6aef4f845124e1" - integrity sha512-h88QkzREN/hy8eRdyNhhsO7RSJ5oyTqxxmmn0dzBIMUclZsjpfmrsg81vp8mjjAs2vAZ72nyWxRUwSwmh0e4xg== - -stacktrace-gps@^3.0.4: - version "3.0.4" - resolved "https://registry.yarnpkg.com/stacktrace-gps/-/stacktrace-gps-3.0.4.tgz#7688dc2fc09ffb3a13165ebe0dbcaf41bcf0c69a" - integrity sha512-qIr8x41yZVSldqdqe6jciXEaSCKw1U8XTXpjDuy0ki/apyTn/r3w9hDAAQOhZdxvsC93H+WwwEu5cq5VemzYeg== - dependencies: - source-map "0.5.6" - stackframe "^1.1.1" - -stacktrace-js@^2.0.2: - version "2.0.2" - resolved "https://registry.yarnpkg.com/stacktrace-js/-/stacktrace-js-2.0.2.tgz#4ca93ea9f494752d55709a081d400fdaebee897b" - integrity sha512-Je5vBeY4S1r/RnLydLl0TBTi3F2qdfWmYsGvtfZgEI+SCprPppaIhQf5nGcal4gI4cGpCV/duLcAzT1np6sQqg== - dependencies: - error-stack-parser "^2.0.6" - stack-generator "^2.0.5" - stacktrace-gps "^3.0.4" - state-toggle@^1.0.0: version "1.0.3" resolved "https://registry.yarnpkg.com/state-toggle/-/state-toggle-1.0.3.tgz#e123b16a88e143139b09c6852221bc9815917dfe" @@ -14187,7 +14128,7 @@ string-width@^5.0.0, string-width@^5.0.1: emoji-regex "^9.2.2" strip-ansi "^7.0.1" -string.prototype.matchall@^4.0.6: +string.prototype.matchall@^4.0.6, string.prototype.matchall@^4.0.7: version "4.0.7" resolved "https://registry.yarnpkg.com/string.prototype.matchall/-/string.prototype.matchall-4.0.7.tgz#8e6ecb0d8a1fb1fda470d81acecb2dba057a481d" integrity sha512-f48okCX7JiwVi1NXCVWcFnZgADDC/n2vePlQ/KUCNqCikLLilQvwjMO8+BHVKvgzH0JB0J9LEPgxOGT02RoETg== @@ -14201,6 +14142,15 @@ string.prototype.matchall@^4.0.6: regexp.prototype.flags "^1.4.1" side-channel "^1.0.4" +string.prototype.padend@^3.0.0: + version "3.1.3" + resolved "https://registry.yarnpkg.com/string.prototype.padend/-/string.prototype.padend-3.1.3.tgz#997a6de12c92c7cb34dc8a201a6c53d9bd88a5f1" + integrity sha512-jNIIeokznm8SD/TZISQsZKYu7RJyheFNt84DUPrh482GC8RVp2MKqm2O5oBRdGxbDQoXrhhWtPIWQOiy20svUg== + dependencies: + call-bind "^1.0.2" + define-properties "^1.1.3" + es-abstract "^1.19.1" + string.prototype.trimend@^1.0.5: version "1.0.5" resolved "https://registry.yarnpkg.com/string.prototype.trimend/-/string.prototype.trimend-1.0.5.tgz#914a65baaab25fbdd4ee291ca7dde57e869cb8d0" @@ -14360,10 +14310,10 @@ stylelint-config-standard@^25.0.0: dependencies: stylelint-config-recommended "^7.0.0" -stylelint@^14.8.2: - version "14.8.2" - resolved "https://registry.yarnpkg.com/stylelint/-/stylelint-14.8.2.tgz#801eef74fe6020611e6a515abb9fc7caeb125793" - integrity sha512-tjDfexCYfoPdl/xcDJ9Fv+Ko9cvzbDnmdiaqEn3ovXHXasi/hbkt5tSjsiReQ+ENqnz0eltaX/AOO+AlzVdcNA== +stylelint@^14.8.3: + version "14.8.3" + resolved "https://registry.yarnpkg.com/stylelint/-/stylelint-14.8.3.tgz#25d2df1e010cda52ff56327059d1ce25319109be" + integrity sha512-aLpskXwSgFEBYbFRKA/BfuyYMGuXNtn2t5GqoffNPSezvw97x/vVNWcZNF0+cwt+LBjfvyq9/MRE3OjInGRgNA== dependencies: balanced-match "^2.0.0" colord "^2.9.2" @@ -14388,7 +14338,6 @@ stylelint@^14.8.2: meow "^9.0.0" micromatch "^4.0.5" normalize-path "^3.0.0" - normalize-selector "^0.2.0" picocolors "^1.0.0" postcss "^8.4.13" postcss-media-query-parser "^0.2.3" @@ -14407,11 +14356,6 @@ stylelint@^14.8.2: v8-compile-cache "^2.3.0" write-file-atomic "^4.0.1" -stylis@^4.0.6: - version "4.1.1" - resolved "https://registry.yarnpkg.com/stylis/-/stylis-4.1.1.tgz#e46c6a9bbf7c58db1e65bb730be157311ae1fe12" - integrity sha512-lVrM/bNdhVX2OgBFNa2YJ9Lxj7kPzylieHd3TNjuGE0Re9JB7joL5VUKOVH1kdNNJTgGPpT8hmwIAPLaSyEVFQ== - supports-color@^5.3.0: version "5.5.0" resolved "https://registry.yarnpkg.com/supports-color/-/supports-color-5.5.0.tgz#e2e69a44ac8772f78a1ec0b35b689df6530efc8f" @@ -14426,7 +14370,7 @@ supports-color@^7.0.0, supports-color@^7.1.0: dependencies: has-flag "^4.0.0" -supports-color@^8.0.0, supports-color@^8.1.0: +supports-color@^8.0.0: version "8.1.1" resolved "https://registry.yarnpkg.com/supports-color/-/supports-color-8.1.1.tgz#cd6fc17e28500cff56c1b86c0a7fd4a54a73005c" integrity sha512-MpUEN2OodtUzxvKQl72cUF7RQ5EiHsGvSsVG0ia9c5RbWGL2CI4C7EpPS8UTBIplnlzZiNuV56w+FuNxy3ty2Q== @@ -14474,10 +14418,10 @@ svgo@^2.5.0, svgo@^2.7.0: picocolors "^1.0.0" stable "^0.1.8" -swc-loader@^0.2.0: - version "0.2.0" - resolved "https://registry.yarnpkg.com/swc-loader/-/swc-loader-0.2.0.tgz#c26621f9fdeb5e28ba4a8ec19e25b1f3d03791c6" - integrity sha512-HefatIgiOaAekVcUPwT5hRNrWF3nULGv5nqGuXeHR7wz1HNN/VGlgmJE830yhIA7X3dHPln4yUTPnZ3ws7B5Fg== +swc-loader@^0.2.1: + version "0.2.1" + resolved "https://registry.yarnpkg.com/swc-loader/-/swc-loader-0.2.1.tgz#43f2d1a746cf985476ca75ecac6234c7314fd9f8" + integrity sha512-opJG9R5Dl+Fa0QihOZO9v6vueB+JzRhJZw+c4ZRCqUHG2RZL10eHZRHMdQoDz6bvLp7XWe7XBIMUkuWtoGfMJw== symbol-tree@^3.2.4: version "3.2.4" @@ -14661,11 +14605,6 @@ throat@^6.0.1: resolved "https://registry.yarnpkg.com/throat/-/throat-6.0.1.tgz#d514fedad95740c12c2d7fc70ea863eb51ade375" integrity sha512-8hmiGIJMDlwjg7dlJ4yKGLK8EsYqKgPWbG3b4wjJddKNwc7N7Dpn08Df4szr/sZdMVeOstrdYSsqzX6BYbcB+w== -throttle-debounce@^3.0.1: - version "3.0.1" - resolved "https://registry.yarnpkg.com/throttle-debounce/-/throttle-debounce-3.0.1.tgz#32f94d84dfa894f786c9a1f290e7a645b6a19abb" - integrity sha512-dTEWWNu6JmeVXY0ZYoPuH5cRIwc0MeGbJwah9KUNYSJwommQpCzTySTpEe8Gs1J23aeWEuAobe4Ag7EHVt/LOg== - through2@^2.0.0: version "2.0.5" resolved "https://registry.yarnpkg.com/through2/-/through2-2.0.5.tgz#01c1e39eb31d07cb7d03a96a70823260b23132cd" @@ -14777,11 +14716,6 @@ to-vfile@^6.1.0: is-buffer "^2.0.0" vfile "^4.0.0" -toggle-selection@^1.0.6: - version "1.0.6" - resolved "https://registry.yarnpkg.com/toggle-selection/-/toggle-selection-1.0.6.tgz#6e45b1263f2017fa0acc7d89d78b15b8bf77da32" - integrity sha512-BiZS+C1OS8g/q2RRbJmy59xpyghNBqrr6k5L/uKBGRsTfxmu3ffiRnd8mlGPUVayg8pvfi5urfnu8TU7DVOkLQ== - toidentifier@1.0.1: version "1.0.1" resolved "https://registry.yarnpkg.com/toidentifier/-/toidentifier-1.0.1.tgz#3be34321a88a820ed1bd80dfaa33e479fbb8dd35" @@ -14840,11 +14774,6 @@ tr46@~0.0.3: resolved "https://registry.yarnpkg.com/traverse/-/traverse-0.3.9.tgz#717b8f220cc0bb7b44e40514c22b2e8bbc70d8b9" integrity sha512-iawgk0hLP3SxGKDfnDJf8wTz4p2qImnyihM5Hh/sGvQ3K37dPi/w8sRhdNIxYA1TwFwc5mDhIJq+O0RsvXBKdQ== -tree-kill@^1.2.2: - version "1.2.2" - resolved "https://registry.yarnpkg.com/tree-kill/-/tree-kill-1.2.2.tgz#4ca09a9092c88b73a7cdc5e8a01b507b0790a0cc" - integrity sha512-L0Orpi8qGpRG//Nd+H90vFB+3iHnue1zSSGmNOOCh1GLJ7rUKVwV2HvijphGQS2UmhUZewS9VgvxYIdgr+fG1A== - tree-node-cli@^1.5.2: version "1.5.2" resolved "https://registry.yarnpkg.com/tree-node-cli/-/tree-node-cli-1.5.2.tgz#c684fb9e7c2b9b29aa023eebaa9a095b6f93bf93" @@ -14879,11 +14808,6 @@ trough@^2.0.0: resolved "https://registry.yarnpkg.com/trough/-/trough-2.1.0.tgz#0f7b511a4fde65a46f18477ab38849b22c554876" integrity sha512-AqTiAOLcj85xS7vQ8QkAV41hPDIJ71XJB4RCUrzo/1GM2CQwhkJGaf9Hgr7BOugMRpgGUrqRg/DrBDl4H40+8g== -ts-easing@^0.2.0: - version "0.2.0" - resolved "https://registry.yarnpkg.com/ts-easing/-/ts-easing-0.2.0.tgz#c8a8a35025105566588d87dbda05dd7fbfa5a4ec" - integrity sha512-Z86EW+fFFh/IFB1fqQ3/+7Zpf9t2ebOAxNI/V6Wo7r5gqiqtxmgTlQ1qbqQcjLKYeSHPTsEmvlJUDg/EuL0uHQ== - tsconfig-paths@^3.14.1: version "3.14.1" resolved "https://registry.yarnpkg.com/tsconfig-paths/-/tsconfig-paths-3.14.1.tgz#ba0734599e8ea36c862798e920bcf163277b137a" @@ -14899,7 +14823,7 @@ tslib@^1.8.1, tslib@^1.9.0: resolved "https://registry.yarnpkg.com/tslib/-/tslib-1.14.1.tgz#cf2d38bdc34a134bcaf1091c41f6619e2f672d00" integrity sha512-Xni35NKzjgMrwevysHTCArtLDpPvye8zV/0E4EyYn43P7/7qvQwPh9BGkHewbMulVntbigmcT7rdX3BNo9wRJg== -tslib@^2.0.1, tslib@^2.0.3, tslib@^2.1.0, tslib@^2.2.0, tslib@^2.4.0: +tslib@^2.0.1, tslib@^2.0.3, tslib@^2.1.0, tslib@^2.4.0: version "2.4.0" resolved "https://registry.yarnpkg.com/tslib/-/tslib-2.4.0.tgz#7cecaa7f073ce680a05847aa77be941098f36dc3" integrity sha512-d6xOpEDfsi2CZVlPQzGeux8XMwLT9hssAsaPYExaQMuYskwb+x1x7J371tWlbBdWHroy99KnVB6qIkUbs5X3UQ== @@ -15013,9 +14937,9 @@ ua-parser-js@^0.7.30: integrity sha512-qLK/Xe9E2uzmYI3qLeOmI0tEOt+TBBQyUIAh4aAgU05FVYzeZrKUdkAZfBNVGRaHVgV0TDkdEngJSw/SyQchkQ== uglify-js@^3.1.4: - version "3.15.4" - resolved "https://registry.yarnpkg.com/uglify-js/-/uglify-js-3.15.4.tgz#fa95c257e88f85614915b906204b9623d4fa340d" - integrity sha512-vMOPGDuvXecPs34V74qDKk4iJ/SN4vL3Ow/23ixafENYvtrNvtbcgUeugTcUGRGsOF/5fU8/NYSL5Hyb3l1OJA== + version "3.15.5" + resolved "https://registry.yarnpkg.com/uglify-js/-/uglify-js-3.15.5.tgz#2b10f9e0bfb3f5c15a8e8404393b6361eaeb33b3" + integrity sha512-hNM5q5GbBRB5xB+PMqVRcgYe4c8jbyZ1pzZhS6jbq54/4F2gFK869ZheiE5A8/t+W5jtTNpWef/5Q9zk639FNQ== uid-number@0.0.6: version "0.0.6" @@ -15366,7 +15290,7 @@ url-parse-lax@^3.0.0: dependencies: prepend-http "^2.0.0" -use-composed-ref@^1.0.0: +use-composed-ref@^1.3.0: version "1.3.0" resolved "https://registry.yarnpkg.com/use-composed-ref/-/use-composed-ref-1.3.0.tgz#3d8104db34b7b264030a9d916c5e94fbe280dbda" integrity sha512-GLMG0Jc/jiKov/3Ulid1wbv3r54K9HlMW29IWcDFPEqFkSO2nS0MuefWgMJpeHQ9YJeXDL3ZUF+P3jdXlZX/cQ== @@ -15376,7 +15300,7 @@ use-isomorphic-layout-effect@^1.1.1: resolved "https://registry.yarnpkg.com/use-isomorphic-layout-effect/-/use-isomorphic-layout-effect-1.1.2.tgz#497cefb13d863d687b08477d9e5a164ad8c1a6fb" integrity sha512-49L8yCO3iGT/ZF9QttjwLF/ZD9Iwto5LnH5LmEdk/6cFmXddqi2ulF0edxTwjj+7mqvpVVGQWvbXZdn32wRSHA== -use-latest@^1.0.0: +use-latest@^1.2.1: version "1.2.1" resolved "https://registry.yarnpkg.com/use-latest/-/use-latest-1.2.1.tgz#d13dfb4b08c28e3e33991546a2cee53e14038cf2" integrity sha512-xA+AVm/Wlg3e2P/JiItTziwS7FK92LWrDB0p+hgXloIMuVCeJJ8v6f0eeHyPZaJrM+usM1FkFfbNCrJGs8A/zw== @@ -15644,12 +15568,12 @@ webpack-bundle-analyzer@^4.5.0: ws "^7.3.1" webpack-dev-middleware@^5.3.1: - version "5.3.1" - resolved "https://registry.yarnpkg.com/webpack-dev-middleware/-/webpack-dev-middleware-5.3.1.tgz#aa079a8dedd7e58bfeab358a9af7dab304cee57f" - integrity sha512-81EujCKkyles2wphtdrnPg/QqegC/AtqNH//mQkBYSMqwFVCQrxM6ktB2O/SPlZy7LqeEfTbV3cZARGQz6umhg== + version "5.3.3" + resolved "https://registry.yarnpkg.com/webpack-dev-middleware/-/webpack-dev-middleware-5.3.3.tgz#efae67c2793908e7311f1d9b06f2a08dcc97e51f" + integrity sha512-hj5CYrY0bZLB+eTO+x/j67Pkrquiy7kWepMHmUMoPsmcUaeEnQJqFzHJOyxgWlq746/wUuA64p9ta34Kyb01pA== dependencies: colorette "^2.0.10" - memfs "^3.4.1" + memfs "^3.4.3" mime-types "^2.1.31" range-parser "^1.2.1" schema-utils "^4.0.0" @@ -15828,7 +15752,7 @@ which-boxed-primitive@^1.0.2: is-string "^1.0.5" is-symbol "^1.0.3" -which@^1.3.1: +which@^1.2.9, which@^1.3.1: version "1.3.1" resolved "https://registry.yarnpkg.com/which/-/which-1.3.1.tgz#a45043d54f5805316da8d62f9f50918d3da70b0a" integrity sha512-HxJdYWq1MTIQbJ3nw0cqssHoTNU267KlrDuGZ1WYlxDStUtKUhOaJmh112/TZmHxxUfuJqPXSOm7tDyas0OSIQ== @@ -16214,9 +16138,9 @@ yargs@^16.0.0, yargs@^16.2.0: yargs-parser "^20.2.2" yargs@^17.1.0, yargs@^17.3.1: - version "17.4.1" - resolved "https://registry.yarnpkg.com/yargs/-/yargs-17.4.1.tgz#ebe23284207bb75cee7c408c33e722bfb27b5284" - integrity sha512-WSZD9jgobAg3ZKuCQZSa3g9QOJeCCqLoLAykiWgmXnDo9EPnn4RPf5qVTtzgOx66o6/oqhcA5tHtJXpG8pMt3g== + version "17.5.1" + resolved "https://registry.yarnpkg.com/yargs/-/yargs-17.5.1.tgz#e109900cab6fcb7fd44b1d8249166feb0b36e58e" + integrity sha512-t6YAJcxDkNX7NFYiVtKvWUz8l+PaKTLiL63mJYWR2GnHq2gjEWISzsLp9wg3aY36dY1j+gfIEL3pIF+XlJJfbA== dependencies: cliui "^7.0.2" escalade "^3.1.1"