diff --git a/.eslintrc.js b/.eslintrc.js index c24b8215bd2d..6708ef87f1f9 100644 --- a/.eslintrc.js +++ b/.eslintrc.js @@ -191,6 +191,7 @@ module.exports = { 'no-template-curly-in-string': WARNING, 'no-unused-expressions': [WARNING, {allowTaggedTemplates: true}], 'no-useless-escape': WARNING, + 'no-void': [ERROR, {allowAsStatement: true}], 'prefer-destructuring': WARNING, 'prefer-named-capture-group': WARNING, 'prefer-template': WARNING, @@ -210,10 +211,12 @@ module.exports = { ], 'import/extensions': OFF, - // Ignore certain webpack aliases because they can't be resolved + // This rule doesn't yet support resolving .js imports when the actual file + // is .ts. Plus it's not all that useful when our code is fully TS-covered. 'import/no-unresolved': [ - ERROR, + OFF, { + // Ignore certain webpack aliases because they can't be resolved ignore: [ '^@theme', '^@docusaurus', diff --git a/.github/workflows/build-blog-only.yml b/.github/workflows/build-blog-only.yml index 032f8ae3455f..2726d079cc25 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@17f8bd926464a1afa4c6a11669539e9c1ba77048 # v3 + uses: actions/setup-node@eeb10cff27034e7acf239c5d29f62154018672fd # v3 with: node-version: '16' cache: yarn diff --git a/.github/workflows/build-perf.yml b/.github/workflows/build-perf.yml index 2fa8b482a7fc..1f95d812cd3d 100644 --- a/.github/workflows/build-perf.yml +++ b/.github/workflows/build-perf.yml @@ -10,6 +10,8 @@ on: branches: - main paths: + - package.json + - yarn.lock - packages/** - website/** - '!website/docs/**' @@ -35,7 +37,7 @@ jobs: - name: Checkout uses: actions/checkout@2541b1294d2704b0964813337f33b291d3f8596b # v3 - name: Set up Node - uses: actions/setup-node@17f8bd926464a1afa4c6a11669539e9c1ba77048 # v3 + uses: actions/setup-node@eeb10cff27034e7acf239c5d29f62154018672fd # v3 with: node-version: '16' cache: yarn @@ -55,7 +57,7 @@ jobs: runs-on: ubuntu-latest steps: - uses: actions/checkout@2541b1294d2704b0964813337f33b291d3f8596b # v3 - - uses: actions/setup-node@17f8bd926464a1afa4c6a11669539e9c1ba77048 # v3 + - uses: actions/setup-node@eeb10cff27034e7acf239c5d29f62154018672fd # v3 with: cache: yarn - name: Installation diff --git a/.github/workflows/canary-release.yml b/.github/workflows/canary-release.yml index 23353fa1d9e1..0e01eeb93d81 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@17f8bd926464a1afa4c6a11669539e9c1ba77048 # v3 + uses: actions/setup-node@eeb10cff27034e7acf239c5d29f62154018672fd # v3 with: node-version: '16' cache: yarn diff --git a/.github/workflows/codeql-analysis.yml b/.github/workflows/codeql-analysis.yml index 639230777941..4d486c9022bb 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@a3a6c128d771b6b9bdebb1c9d0583ebd2728a108 # v2 + uses: github/codeql-action/init@27ea8f8fe5977c00f5b37e076ab846c5bd783b96 # v2 with: languages: ${{ matrix.language }} - name: Perform CodeQL Analysis - uses: github/codeql-action/analyze@a3a6c128d771b6b9bdebb1c9d0583ebd2728a108 # v2 + uses: github/codeql-action/analyze@27ea8f8fe5977c00f5b37e076ab846c5bd783b96 # v2 diff --git a/.github/workflows/lint.yml b/.github/workflows/lint.yml index 6162382297f6..b6a1e10cbab2 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@17f8bd926464a1afa4c6a11669539e9c1ba77048 # v3 + uses: actions/setup-node@eeb10cff27034e7acf239c5d29f62154018672fd # v3 with: node-version: '16' cache: yarn diff --git a/.github/workflows/showcase-test.yml b/.github/workflows/showcase-test.yml index 0403ea3fa1a2..a78dfcb543d6 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@17f8bd926464a1afa4c6a11669539e9c1ba77048 # v3 + uses: actions/setup-node@eeb10cff27034e7acf239c5d29f62154018672fd # v3 with: node-version: '16' cache: yarn diff --git a/.github/workflows/tests-e2e.yml b/.github/workflows/tests-e2e.yml index 6005d73be8c8..5b2a13e48ab8 100644 --- a/.github/workflows/tests-e2e.yml +++ b/.github/workflows/tests-e2e.yml @@ -5,12 +5,18 @@ on: branches: - main paths: + - package.json + - yarn.lock + - jest.config.mjs - packages/** - tsconfig.json pull_request: branches: - main paths: + - package.json + - yarn.lock + - jest.config.mjs - packages/** - tsconfig.json - .github/workflows/tests-e2e.yml @@ -34,7 +40,7 @@ jobs: - name: Checkout uses: actions/checkout@2541b1294d2704b0964813337f33b291d3f8596b # v3 - name: Use Node.js ${{ matrix.node }} - uses: actions/setup-node@17f8bd926464a1afa4c6a11669539e9c1ba77048 # v3 + uses: actions/setup-node@eeb10cff27034e7acf239c5d29f62154018672fd # v3 with: node-version: ${{ matrix.node }} cache: yarn @@ -68,7 +74,7 @@ jobs: - name: Checkout uses: actions/checkout@2541b1294d2704b0964813337f33b291d3f8596b # v3 - name: Use Node.js 16 - uses: actions/setup-node@17f8bd926464a1afa4c6a11669539e9c1ba77048 # v3 + uses: actions/setup-node@eeb10cff27034e7acf239c5d29f62154018672fd # v3 with: node-version: '16' cache: yarn @@ -118,7 +124,7 @@ jobs: - name: Checkout uses: actions/checkout@2541b1294d2704b0964813337f33b291d3f8596b # v3 - name: Use Node.js 16 - uses: actions/setup-node@17f8bd926464a1afa4c6a11669539e9c1ba77048 # v3 + uses: actions/setup-node@eeb10cff27034e7acf239c5d29f62154018672fd # v3 with: node-version: '16' cache: yarn @@ -148,7 +154,7 @@ jobs: - name: Checkout uses: actions/checkout@2541b1294d2704b0964813337f33b291d3f8596b # v3 - name: Use Node.js 16 - uses: actions/setup-node@17f8bd926464a1afa4c6a11669539e9c1ba77048 # v3 + uses: actions/setup-node@eeb10cff27034e7acf239c5d29f62154018672fd # v3 with: node-version: '16' cache: yarn diff --git a/.github/workflows/tests-swizzle.yml b/.github/workflows/tests-swizzle.yml index 00a7f388a2ac..bacc02928909 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@17f8bd926464a1afa4c6a11669539e9c1ba77048 # v3 + uses: actions/setup-node@eeb10cff27034e7acf239c5d29f62154018672fd # v3 with: node-version: '16' cache: yarn diff --git a/.github/workflows/tests-windows.yml b/.github/workflows/tests-windows.yml index d4dbaef8da9f..8baeff8294cb 100644 --- a/.github/workflows/tests-windows.yml +++ b/.github/workflows/tests-windows.yml @@ -5,6 +5,9 @@ on: branches: - main paths: + - package.json + - yarn.lock + - jest.config.mjs - packages/** - tsconfig.json @@ -29,7 +32,7 @@ jobs: - name: Checkout uses: actions/checkout@2541b1294d2704b0964813337f33b291d3f8596b # v3 - name: Use Node.js ${{ matrix.node }} - uses: actions/setup-node@17f8bd926464a1afa4c6a11669539e9c1ba77048 # v3 + uses: actions/setup-node@eeb10cff27034e7acf239c5d29f62154018672fd # v3 with: node-version: ${{ matrix.node }} - name: Installation diff --git a/.github/workflows/tests.yml b/.github/workflows/tests.yml index 502a4812fd64..f60d708e46a3 100644 --- a/.github/workflows/tests.yml +++ b/.github/workflows/tests.yml @@ -5,6 +5,9 @@ on: branches: - main paths: + - package.json + - yarn.lock + - jest.config.mjs - packages/** - tsconfig.json @@ -27,7 +30,7 @@ jobs: - name: Checkout uses: actions/checkout@2541b1294d2704b0964813337f33b291d3f8596b # v3 - name: Use Node.js ${{ matrix.node }} - uses: actions/setup-node@17f8bd926464a1afa4c6a11669539e9c1ba77048 # v3 + uses: actions/setup-node@eeb10cff27034e7acf239c5d29f62154018672fd # v3 with: node-version: ${{ matrix.node }} cache: yarn diff --git a/__tests__/validate-tsconfig.test.ts b/__tests__/validate-tsconfig.test.ts index e69d170502ba..8038a04ae824 100644 --- a/__tests__/validate-tsconfig.test.ts +++ b/__tests__/validate-tsconfig.test.ts @@ -40,14 +40,12 @@ const tsconfigSchema = Joi.object({ 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(), }, ), diff --git a/admin/publish.md b/admin/publish.md index def8c7fc6eda..48e563f8cdec 100644 --- a/admin/publish.md +++ b/admin/publish.md @@ -121,7 +121,7 @@ Test running the website with the new version locally. To keep versions number small, delete the oldest version and add a link to it in `archivedVersions.json`. -Check [Netlify site deployments](https://app.netlify.com/sites/docusaurus-2/deploys) to pick a recent immutable deployment url. +Check [Netlify site deployments](https://app.netlify.com/sites/docusaurus-2/deploys) to pick a recent immutable deployment URL. ### 5. Create a Pull Request diff --git a/jest/deps.d.ts b/jest/deps.d.ts index 16ad1b75fdbd..965ca69039cc 100644 --- a/jest/deps.d.ts +++ b/jest/deps.d.ts @@ -20,6 +20,10 @@ declare module 'remark-mdx' { export = mdx; } +declare module 'remark-rehype'; + +declare module 'rehype-stringify'; + declare module '@testing-utils/git' { const createTempRepo: typeof import('./utils/git').createTempRepo; export {createTempRepo}; diff --git a/package.json b/package.json index 1d449484aa38..f77d8f05c928 100644 --- a/package.json +++ b/package.json @@ -56,48 +56,48 @@ "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", "test:baseUrl": "yarn build:website:baseUrl && yarn serve:website:baseUrl", - "lock:update": "npx yarn-deduplicate" + "lock:update": "npx --yes yarn-deduplicate" }, "dependencies": { "unified": "^9.2.2" }, "devDependencies": { "@crowdin/cli": "^3.7.8", - "@swc/core": "^1.2.194", + "@swc/core": "^1.2.197", "@swc/jest": "^0.2.21", "@testing-library/react-hooks": "^8.0.0", "@types/fs-extra": "^9.0.13", - "@types/jest": "^27.5.1", + "@types/jest": "^28.1.1", "@types/lodash": "^4.14.182", - "@types/node": "^17.0.35", + "@types/node": "^17.0.42", "@types/prompts": "^2.0.14", - "@types/react": "^18.0.9", + "@types/react": "^18.0.12", "@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.26.0", - "@typescript-eslint/parser": "^5.26.0", + "@typescript-eslint/eslint-plugin": "^5.27.1", + "@typescript-eslint/parser": "^5.27.1", "cross-env": "^7.0.3", - "cspell": "^6.0.0", - "eslint": "^8.16.0", + "cspell": "^6.1.2", + "eslint": "^8.17.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.2.2", + "eslint-plugin-jest": "^26.5.3", "eslint-plugin-jsx-a11y": "^6.5.1", "eslint-plugin-react": "^7.30.0", "eslint-plugin-react-hooks": "^4.5.0", "eslint-plugin-regexp": "^1.7.0", "husky": "^8.0.1", "image-size": "^1.0.1", - "jest": "^28.1.0", - "jest-environment-jsdom": "^28.1.0", + "jest": "^28.1.1", + "jest-environment-jsdom": "^28.1.1", "jest-serializer-react-helmet-async": "^1.0.21", - "lerna": "^5.0.0", + "lerna": "^5.1.1", "lerna-changelog": "^2.2.0", - "lint-staged": "^12.4.2", + "lint-staged": "^13.0.1", "npm-run-all": "^4.1.5", "prettier": "^2.6.2", "react": "^17.0.2", @@ -106,11 +106,11 @@ "react-test-renderer": "^17.0.2", "remark-parse": "^8.0.2", "rimraf": "^3.0.2", - "sharp": "^0.30.5", + "sharp": "^0.30.6", "strip-ansi": "^6.0.1", - "stylelint": "^14.8.3", + "stylelint": "^14.9.1", "stylelint-config-prettier": "^9.0.3", - "stylelint-config-standard": "^25.0.0", - "typescript": "~4.6.4" + "stylelint-config-standard": "^26.0.0", + "typescript": "~4.7.3" } } diff --git a/packages/create-docusaurus/templates/classic-typescript/package.json b/packages/create-docusaurus/templates/classic-typescript/package.json index 8bea006c5ee2..c15db8dc3072 100644 --- a/packages/create-docusaurus/templates/classic-typescript/package.json +++ b/packages/create-docusaurus/templates/classic-typescript/package.json @@ -30,7 +30,7 @@ "@tsconfig/docusaurus": "^1.0.5", "@types/node": "^16", "@types/react": "^17", - "typescript": "^4.6.4" + "typescript": "^4.7.3" }, "resolutions": { "@types/react": "^17" @@ -46,5 +46,8 @@ "last 1 firefox version", "last 1 safari version" ] + }, + "engines": { + "node": ">=16.14" } } diff --git a/packages/create-docusaurus/templates/classic/package.json b/packages/create-docusaurus/templates/classic/package.json index 4676a35511ef..f6648a6990bb 100644 --- a/packages/create-docusaurus/templates/classic/package.json +++ b/packages/create-docusaurus/templates/classic/package.json @@ -37,5 +37,8 @@ "last 1 firefox version", "last 1 safari version" ] + }, + "engines": { + "node": ">=16.14" } } diff --git a/packages/create-docusaurus/templates/facebook/.eslintrc.js b/packages/create-docusaurus/templates/facebook/.eslintrc.js index e9cf75b4fea9..8ccf3b17bdf7 100644 --- a/packages/create-docusaurus/templates/facebook/.eslintrc.js +++ b/packages/create-docusaurus/templates/facebook/.eslintrc.js @@ -1,5 +1,5 @@ /** - * Copyright (c) Facebook, Inc. and its affiliates. + * Copyright (c) Meta Platforms, Inc. and affiliates. * * This source code is licensed under the MIT license found in the * LICENSE file in the root directory of this source tree. @@ -38,7 +38,7 @@ module.exports = { [ '*', - ' * Copyright (c) Facebook, Inc. and its affiliates.', + ' * Copyright (c) Meta Platforms, Inc. and affiliates.', ' *', ' * This source code is licensed under the MIT license found in the', ' * LICENSE file in the root directory of this source tree.', diff --git a/packages/create-docusaurus/templates/facebook/.stylelintrc.js b/packages/create-docusaurus/templates/facebook/.stylelintrc.js index efbe9b7be166..11b6ffb3234a 100644 --- a/packages/create-docusaurus/templates/facebook/.stylelintrc.js +++ b/packages/create-docusaurus/templates/facebook/.stylelintrc.js @@ -1,5 +1,5 @@ /** - * Copyright (c) Facebook, Inc. and its affiliates. + * Copyright (c) Meta Platforms, Inc. and affiliates. * * This source code is licensed under the MIT license found in the * LICENSE file in the root directory of this source tree. diff --git a/packages/create-docusaurus/templates/facebook/babel.config.js b/packages/create-docusaurus/templates/facebook/babel.config.js index 81604ce8ec2e..84ad45acbd0e 100644 --- a/packages/create-docusaurus/templates/facebook/babel.config.js +++ b/packages/create-docusaurus/templates/facebook/babel.config.js @@ -1,5 +1,5 @@ /** - * Copyright (c) Facebook, Inc. and its affiliates. + * Copyright (c) Meta Platforms, Inc. and affiliates. * * This source code is licensed under the MIT license found in the * LICENSE file in the root directory of this source tree. diff --git a/packages/create-docusaurus/templates/facebook/docusaurus.config.js b/packages/create-docusaurus/templates/facebook/docusaurus.config.js index d140034e07f5..34ce59f52aa8 100644 --- a/packages/create-docusaurus/templates/facebook/docusaurus.config.js +++ b/packages/create-docusaurus/templates/facebook/docusaurus.config.js @@ -1,5 +1,5 @@ /** - * Copyright (c) Facebook, Inc. and its affiliates. + * Copyright (c) Meta Platforms, Inc. and affiliates. * * This source code is licensed under the MIT license found in the * LICENSE file in the root directory of this source tree. @@ -54,9 +54,9 @@ const config = { /** @type {import('@docusaurus/preset-classic').ThemeConfig} */ ({ navbar: { - title: 'My Facebook Project', + title: 'My Meta Project', logo: { - alt: 'My Facebook Project Logo', + alt: 'My Meta Project Logo', src: 'img/logo.svg', }, items: [ @@ -127,30 +127,32 @@ const config = { items: [ { label: 'Privacy', - href: 'https://opensource.facebook.com/legal/privacy/', + href: 'https://opensource.fb.com/legal/privacy/', }, { label: 'Terms', - href: 'https://opensource.facebook.com/legal/terms/', + href: 'https://opensource.fb.com/legal/terms/', }, { label: 'Data Policy', - href: 'https://opensource.facebook.com/legal/data-policy/', + href: 'https://opensource.fb.com/legal/data-policy/', }, { label: 'Cookie Policy', - href: 'https://opensource.facebook.com/legal/cookie-policy/', + href: 'https://opensource.fb.com/legal/cookie-policy/', }, ], }, ], logo: { - alt: 'Facebook Open Source Logo', - src: 'img/oss_logo.png', - href: 'https://opensource.facebook.com', + alt: 'Meta Open Source Logo', + // This default includes a positive & negative version, allowing for + // appropriate use depending on your site's style. + src: 'img/meta_opensource_logo_negative.png', + href: 'https://opensource.fb.com', }, // Please do not remove the credits, help to publicize Docusaurus :) - copyright: `Copyright © ${new Date().getFullYear()} Facebook, Inc. Built with Docusaurus.`, + copyright: `Copyright © ${new Date().getFullYear()} Meta Platforms, Inc. Built with Docusaurus.`, }, }), }; diff --git a/packages/create-docusaurus/templates/facebook/package.json b/packages/create-docusaurus/templates/facebook/package.json index 95e6962243ae..d1569612d719 100644 --- a/packages/create-docusaurus/templates/facebook/package.json +++ b/packages/create-docusaurus/templates/facebook/package.json @@ -27,7 +27,7 @@ }, "devDependencies": { "@babel/eslint-parser": "^7.18.2", - "eslint": "^8.16.0", + "eslint": "^8.17.0", "eslint-config-airbnb": "^19.0.4", "eslint-config-prettier": "^8.5.0", "eslint-plugin-header": "^3.1.1", @@ -36,7 +36,7 @@ "eslint-plugin-react": "^7.30.0", "eslint-plugin-react-hooks": "^4.5.0", "prettier": "^2.6.2", - "stylelint": "^14.8.5" + "stylelint": "^14.9.1" }, "browserslist": { "production": [ @@ -49,5 +49,8 @@ "last 1 firefox version", "last 1 safari version" ] + }, + "engines": { + "node": ">=16.14" } } diff --git a/packages/create-docusaurus/templates/facebook/sidebars.js b/packages/create-docusaurus/templates/facebook/sidebars.js index 5449fd4f81fe..be7a480ce62a 100644 --- a/packages/create-docusaurus/templates/facebook/sidebars.js +++ b/packages/create-docusaurus/templates/facebook/sidebars.js @@ -1,5 +1,5 @@ /** - * Copyright (c) Facebook, Inc. and its affiliates. + * Copyright (c) Meta Platforms, Inc. and affiliates. * * This source code is licensed under the MIT license found in the * LICENSE file in the root directory of this source tree. diff --git a/packages/create-docusaurus/templates/facebook/src/css/custom.css b/packages/create-docusaurus/templates/facebook/src/css/custom.css index c11ab1671663..2396bcccdbb8 100644 --- a/packages/create-docusaurus/templates/facebook/src/css/custom.css +++ b/packages/create-docusaurus/templates/facebook/src/css/custom.css @@ -1,5 +1,5 @@ /** - * Copyright (c) Facebook, Inc. and its affiliates. + * Copyright (c) Meta Platforms, Inc. and affiliates. * * This source code is licensed under the MIT license found in the * LICENSE file in the root directory of this source tree. diff --git a/packages/create-docusaurus/templates/facebook/src/pages/index.js b/packages/create-docusaurus/templates/facebook/src/pages/index.js index 9ad8a8389c43..6b378cd9d9cc 100644 --- a/packages/create-docusaurus/templates/facebook/src/pages/index.js +++ b/packages/create-docusaurus/templates/facebook/src/pages/index.js @@ -1,5 +1,5 @@ /** - * Copyright (c) Facebook, Inc. and its affiliates. + * Copyright (c) Meta Platforms, Inc. and affiliates. * * This source code is licensed under the MIT license found in the * LICENSE file in the root directory of this source tree. diff --git a/packages/create-docusaurus/templates/facebook/src/pages/styles.module.css b/packages/create-docusaurus/templates/facebook/src/pages/styles.module.css index da1454b3f3b5..e74559a80617 100644 --- a/packages/create-docusaurus/templates/facebook/src/pages/styles.module.css +++ b/packages/create-docusaurus/templates/facebook/src/pages/styles.module.css @@ -1,5 +1,5 @@ /** - * Copyright (c) Facebook, Inc. and its affiliates. + * Copyright (c) Meta Platforms, Inc. and affiliates. * * This source code is licensed under the MIT license found in the * LICENSE file in the root directory of this source tree. diff --git a/packages/create-docusaurus/templates/facebook/static/img/meta_opensource_logo.svg b/packages/create-docusaurus/templates/facebook/static/img/meta_opensource_logo.svg new file mode 100644 index 000000000000..83a217548497 --- /dev/null +++ b/packages/create-docusaurus/templates/facebook/static/img/meta_opensource_logo.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/packages/create-docusaurus/templates/facebook/static/img/meta_opensource_logo_negative.svg b/packages/create-docusaurus/templates/facebook/static/img/meta_opensource_logo_negative.svg new file mode 100644 index 000000000000..b36a423e3bff --- /dev/null +++ b/packages/create-docusaurus/templates/facebook/static/img/meta_opensource_logo_negative.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/packages/create-docusaurus/templates/facebook/static/img/oss_logo.png b/packages/create-docusaurus/templates/facebook/static/img/oss_logo.png deleted file mode 100644 index 81923fc56250..000000000000 Binary files a/packages/create-docusaurus/templates/facebook/static/img/oss_logo.png and /dev/null differ diff --git a/packages/create-docusaurus/templates/shared/docs/intro.md b/packages/create-docusaurus/templates/shared/docs/intro.md index 500260230bfc..8a2e69d95f9f 100644 --- a/packages/create-docusaurus/templates/shared/docs/intro.md +++ b/packages/create-docusaurus/templates/shared/docs/intro.md @@ -14,7 +14,7 @@ Or **try Docusaurus immediately** with **[docusaurus.new](https://docusaurus.new ### What you'll need -- [Node.js](https://nodejs.org/en/download/) version 14 or above: +- [Node.js](https://nodejs.org/en/download/) version 16.14 or above: - When installing Node.js, you are recommended to check all checkboxes related to dependencies. ## Generate a new site diff --git a/packages/create-docusaurus/templates/shared/docs/tutorial-basics/create-a-blog-post.md b/packages/create-docusaurus/templates/shared/docs/tutorial-basics/create-a-blog-post.md index 0d50aaf31631..ea472bbaf871 100644 --- a/packages/create-docusaurus/templates/shared/docs/tutorial-basics/create-a-blog-post.md +++ b/packages/create-docusaurus/templates/shared/docs/tutorial-basics/create-a-blog-post.md @@ -31,4 +31,4 @@ Congratulations, you have made your first post! Feel free to play around and edit this post as much you like. ``` -A new blog post is now available at `http://localhost:3000/blog/greetings`. +A new blog post is now available at [http://localhost:3000/blog/greetings](http://localhost:3000/blog/greetings). diff --git a/packages/create-docusaurus/templates/shared/docs/tutorial-basics/create-a-document.md b/packages/create-docusaurus/templates/shared/docs/tutorial-basics/create-a-document.md index a9bb9a4140b1..3c92695c517e 100644 --- a/packages/create-docusaurus/templates/shared/docs/tutorial-basics/create-a-document.md +++ b/packages/create-docusaurus/templates/shared/docs/tutorial-basics/create-a-document.md @@ -12,7 +12,7 @@ Documents are **groups of pages** connected through: ## Create your first Doc -Create a markdown file at `docs/hello.md`: +Create a Markdown file at `docs/hello.md`: ```md title="docs/hello.md" # Hello @@ -20,7 +20,7 @@ Create a markdown file at `docs/hello.md`: This is my **first Docusaurus document**! ``` -A new document is now available at `http://localhost:3000/docs/hello`. +A new document is now available at [http://localhost:3000/docs/hello](http://localhost:3000/docs/hello). ## Configure the Sidebar diff --git a/packages/create-docusaurus/templates/shared/docs/tutorial-basics/create-a-page.md b/packages/create-docusaurus/templates/shared/docs/tutorial-basics/create-a-page.md index e112b0059c26..20e2ac300556 100644 --- a/packages/create-docusaurus/templates/shared/docs/tutorial-basics/create-a-page.md +++ b/packages/create-docusaurus/templates/shared/docs/tutorial-basics/create-a-page.md @@ -6,9 +6,9 @@ sidebar_position: 1 Add **Markdown or React** files to `src/pages` to create a **standalone page**: -- `src/pages/index.js` -> `localhost:3000/` -- `src/pages/foo.md` -> `localhost:3000/foo` -- `src/pages/foo/bar.js` -> `localhost:3000/foo/bar` +- `src/pages/index.js` → `localhost:3000/` +- `src/pages/foo.md` → `localhost:3000/foo` +- `src/pages/foo/bar.js` → `localhost:3000/foo/bar` ## Create your first React Page @@ -28,7 +28,7 @@ export default function MyReactPage() { } ``` -A new page is now available at `http://localhost:3000/my-react-page`. +A new page is now available at [http://localhost:3000/my-react-page](http://localhost:3000/my-react-page). ## Create your first Markdown Page @@ -40,4 +40,4 @@ Create a file at `src/pages/my-markdown-page.md`: This is a Markdown page ``` -A new page is now available at `http://localhost:3000/my-markdown-page`. +A new page is now available at [http://localhost:3000/my-markdown-page](http://localhost:3000/my-markdown-page). diff --git a/packages/create-docusaurus/templates/shared/docs/tutorial-basics/deploy-your-site.md b/packages/create-docusaurus/templates/shared/docs/tutorial-basics/deploy-your-site.md index 492eae0276b4..1c50ee063ef4 100644 --- a/packages/create-docusaurus/templates/shared/docs/tutorial-basics/deploy-your-site.md +++ b/packages/create-docusaurus/templates/shared/docs/tutorial-basics/deploy-your-site.md @@ -26,6 +26,6 @@ Test your production build locally: npm run serve ``` -The `build` folder is now served at `http://localhost:3000/`. +The `build` folder is now served at [http://localhost:3000/](http://localhost:3000/). You can now deploy the `build` folder **almost anywhere** easily, **for free** or very small cost (read the **[Deployment Guide](https://docusaurus.io/docs/deployment)**). diff --git a/packages/create-docusaurus/templates/shared/docs/tutorial-extras/translate-your-site.md b/packages/create-docusaurus/templates/shared/docs/tutorial-extras/translate-your-site.md index da2b8a365f48..caeaffb05548 100644 --- a/packages/create-docusaurus/templates/shared/docs/tutorial-extras/translate-your-site.md +++ b/packages/create-docusaurus/templates/shared/docs/tutorial-extras/translate-your-site.md @@ -39,7 +39,7 @@ Start your site on the French locale: npm run start -- --locale fr ``` -Your localized site is accessible at `http://localhost:3000/fr/` and the `Getting Started` page is translated. +Your localized site is accessible at [http://localhost:3000/fr/](http://localhost:3000/fr/) and the `Getting Started` page is translated. :::caution diff --git a/packages/create-docusaurus/tsconfig.build.json b/packages/create-docusaurus/tsconfig.build.json index 6f46335ae9d0..36377cdd0cbe 100644 --- a/packages/create-docusaurus/tsconfig.build.json +++ b/packages/create-docusaurus/tsconfig.build.json @@ -3,7 +3,6 @@ "compilerOptions": { "noEmit": false, "composite": true, - "module": "es2020", "incremental": true, "tsBuildInfoFile": "./lib/.tsbuildinfo", "rootDir": "src", diff --git a/packages/create-docusaurus/tsconfig.json b/packages/create-docusaurus/tsconfig.json index 5c73d3ac4eca..13e35c5a957c 100644 --- a/packages/create-docusaurus/tsconfig.json +++ b/packages/create-docusaurus/tsconfig.json @@ -3,7 +3,6 @@ "references": [{"path": "./tsconfig.build.json"}], "compilerOptions": { "noEmit": true, - "module": "esnext", "rootDir": "." }, "include": ["bin"], diff --git a/packages/docusaurus-cssnano-preset/package.json b/packages/docusaurus-cssnano-preset/package.json index 7e92802bbc20..9822774d4e4d 100644 --- a/packages/docusaurus-cssnano-preset/package.json +++ b/packages/docusaurus-cssnano-preset/package.json @@ -17,7 +17,7 @@ "directory": "packages/docusaurus-cssnano-preset" }, "dependencies": { - "cssnano-preset-advanced": "^5.3.5", + "cssnano-preset-advanced": "^5.3.6", "postcss": "^8.4.14", "postcss-sort-media-queries": "^4.2.1", "tslib": "^2.4.0" diff --git a/packages/docusaurus-cssnano-preset/src/index.ts b/packages/docusaurus-cssnano-preset/src/index.ts index 6bae42c6f8c7..ddea9fc0ed9c 100644 --- a/packages/docusaurus-cssnano-preset/src/index.ts +++ b/packages/docusaurus-cssnano-preset/src/index.ts @@ -13,6 +13,8 @@ const preset: typeof advancedBasePreset = function preset(opts) { const advancedPreset = advancedBasePreset({ autoprefixer: {add: false}, discardComments: {removeAll: true}, + /* cSpell:ignore zindex */ + zindex: false, ...opts, }); diff --git a/packages/docusaurus-cssnano-preset/tsconfig.json b/packages/docusaurus-cssnano-preset/tsconfig.json index 80e43e9813ef..e16d5c2c5d33 100644 --- a/packages/docusaurus-cssnano-preset/tsconfig.json +++ b/packages/docusaurus-cssnano-preset/tsconfig.json @@ -4,7 +4,6 @@ "noEmit": false, "incremental": true, "tsBuildInfoFile": "./lib/.tsbuildinfo", - "module": "commonjs", "rootDir": "src", "outDir": "lib" }, diff --git a/packages/docusaurus-logger/tsconfig.json b/packages/docusaurus-logger/tsconfig.json index 7807612b51a5..69bd9341b47e 100644 --- a/packages/docusaurus-logger/tsconfig.json +++ b/packages/docusaurus-logger/tsconfig.json @@ -6,7 +6,6 @@ "tsBuildInfoFile": "./lib/.tsbuildinfo", "sourceMap": true, "declarationMap": true, - "module": "commonjs", "rootDir": "src", "outDir": "lib" }, diff --git a/packages/docusaurus-mdx-loader/package.json b/packages/docusaurus-mdx-loader/package.json index 1efcee5eaf0e..5f8492f35f6e 100644 --- a/packages/docusaurus-mdx-loader/package.json +++ b/packages/docusaurus-mdx-loader/package.json @@ -18,7 +18,7 @@ }, "license": "MIT", "dependencies": { - "@babel/parser": "^7.18.3", + "@babel/parser": "^7.18.4", "@babel/traverse": "^7.18.2", "@docusaurus/logger": "2.0.0-beta.21", "@docusaurus/utils": "2.0.0-beta.21", @@ -34,7 +34,7 @@ "unified": "^9.2.2", "unist-util-visit": "^2.0.3", "url-loader": "^4.1.1", - "webpack": "^5.72.1" + "webpack": "^5.73.0" }, "devDependencies": { "@docusaurus/types": "2.0.0-beta.21", @@ -44,6 +44,8 @@ "@types/unist": "^2.0.6", "remark": "^12.0.1", "remark-mdx": "^1.6.21", + "rehype-stringify": "^8.0.0", + "remark-rehype": "^8.1.0", "to-vfile": "^6.1.0", "unist-builder": "^2.0.3", "unist-util-remove-position": "^3.0.0" diff --git a/packages/docusaurus-mdx-loader/src/loader.ts b/packages/docusaurus-mdx-loader/src/loader.ts index 638a62566724..764d62c2bdc5 100644 --- a/packages/docusaurus-mdx-loader/src/loader.ts +++ b/packages/docusaurus-mdx-loader/src/loader.ts @@ -23,8 +23,10 @@ import unwrapMdxCodeBlocks from './remark/unwrapMdxCodeBlocks'; import transformImage from './remark/transformImage'; import transformLinks from './remark/transformLinks'; +import transformAdmonitions from './remark/admonitions'; import type {LoaderContext} from 'webpack'; import type {Processor, Plugin} from 'unified'; +import type {AdmonitionOptions} from './remark/admonitions'; const { loaders: {inlineMarkdownImageFileLoader}, @@ -37,6 +39,7 @@ const pragma = ` `; const DEFAULT_OPTIONS: MDXOptions = { + admonitions: true, rehypePlugins: [], remarkPlugins: [unwrapMdxCodeBlocks, emoji, headings, toc], beforeDefaultRemarkPlugins: [], @@ -48,7 +51,9 @@ const compilerCache = new Map(); export type MDXPlugin = // eslint-disable-next-line @typescript-eslint/no-explicit-any [Plugin, any] | Plugin; + export type MDXOptions = { + admonitions: boolean | AdmonitionOptions; remarkPlugins: MDXPlugin[]; rehypePlugins: MDXPlugin[]; beforeDefaultRemarkPlugins: MDXPlugin[]; @@ -132,6 +137,19 @@ function createAssetsExportCode(assets: unknown) { return `{\n${codeLines.join('\n')}\n}`; } +function getAdmonitionsPlugins( + admonitionsOption: MDXOptions['admonitions'], +): MDXPlugin[] { + if (admonitionsOption) { + const plugin: MDXPlugin = + admonitionsOption === true + ? transformAdmonitions + : [transformAdmonitions, admonitionsOption]; + return [plugin]; + } + return []; +} + export async function mdxLoader( this: LoaderContext, fileString: string, @@ -149,32 +167,37 @@ export async function mdxLoader( const hasFrontMatter = Object.keys(frontMatter).length > 0; if (!compilerCache.has(this.query)) { - const options: Options = { - ...reqOptions, - remarkPlugins: [ - ...(reqOptions.beforeDefaultRemarkPlugins ?? []), - ...DEFAULT_OPTIONS.remarkPlugins, - [ - transformImage, - { - staticDirs: reqOptions.staticDirs, - siteDir: reqOptions.siteDir, - }, - ], - [ - transformLinks, - { - staticDirs: reqOptions.staticDirs, - siteDir: reqOptions.siteDir, - }, - ], - ...(reqOptions.remarkPlugins ?? []), + const remarkPlugins: MDXPlugin[] = [ + ...(reqOptions.beforeDefaultRemarkPlugins ?? []), + ...getAdmonitionsPlugins(reqOptions.admonitions ?? false), + ...DEFAULT_OPTIONS.remarkPlugins, + [ + transformImage, + { + staticDirs: reqOptions.staticDirs, + siteDir: reqOptions.siteDir, + }, ], - rehypePlugins: [ - ...(reqOptions.beforeDefaultRehypePlugins ?? []), - ...DEFAULT_OPTIONS.rehypePlugins, - ...(reqOptions.rehypePlugins ?? []), + [ + transformLinks, + { + staticDirs: reqOptions.staticDirs, + siteDir: reqOptions.siteDir, + }, ], + ...(reqOptions.remarkPlugins ?? []), + ]; + + const rehypePlugins: MDXPlugin[] = [ + ...(reqOptions.beforeDefaultRehypePlugins ?? []), + ...DEFAULT_OPTIONS.rehypePlugins, + ...(reqOptions.rehypePlugins ?? []), + ]; + + const options: Options = { + ...reqOptions, + remarkPlugins, + rehypePlugins, }; compilerCache.set(this.query, [createCompiler(options), options]); } diff --git a/packages/docusaurus-mdx-loader/src/remark/admonitions/LICENSE b/packages/docusaurus-mdx-loader/src/remark/admonitions/LICENSE new file mode 100644 index 000000000000..faa2221713df --- /dev/null +++ b/packages/docusaurus-mdx-loader/src/remark/admonitions/LICENSE @@ -0,0 +1,45 @@ +MIT License + +Copyright (c) 2020 Elvis Wolcott + +Permission is hereby granted, free of charge, to any person obtaining a copy +of this software and associated documentation files (the "Software"), to deal +in the Software without restriction, including without limitation the rights +to use, copy, modify, merge, publish, distribute, sublicense, and/or sell +copies of the Software, and to permit persons to whom the Software is +furnished to do so, subject to the following conditions: + +The above copyright notice and this permission notice shall be included in all +copies or substantial portions of the Software. + +THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR +IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, +FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE +AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER +LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, +OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE +SOFTWARE. + +--- + +MIT License + +Copyright (c) Facebook, Inc. and its affiliates. + +Permission is hereby granted, free of charge, to any person obtaining a copy +of this software and associated documentation files (the "Software"), to deal +in the Software without restriction, including without limitation the rights +to use, copy, modify, merge, publish, distribute, sublicense, and/or sell +copies of the Software, and to permit persons to whom the Software is +furnished to do so, subject to the following conditions: + +The above copyright notice and this permission notice shall be included in all +copies or substantial portions of the Software. + +THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR +IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, +FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE +AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER +LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, +OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE +SOFTWARE. diff --git a/packages/docusaurus-mdx-loader/src/remark/admonitions/README.md b/packages/docusaurus-mdx-loader/src/remark/admonitions/README.md new file mode 100644 index 000000000000..3add9f4f32a4 --- /dev/null +++ b/packages/docusaurus-mdx-loader/src/remark/admonitions/README.md @@ -0,0 +1,3 @@ +# Docusaurus admonitions + +Code from [remark-admonitions](https://github.com/remarkjs/remark-directive) (MIT license) has been copied to this folder, and highly customized for Docusaurus needs. diff --git a/packages/docusaurus-mdx-loader/src/remark/admonitions/__tests__/__fixtures__/base.md b/packages/docusaurus-mdx-loader/src/remark/admonitions/__tests__/__fixtures__/base.md new file mode 100644 index 000000000000..a9d3e4159661 --- /dev/null +++ b/packages/docusaurus-mdx-loader/src/remark/admonitions/__tests__/__fixtures__/base.md @@ -0,0 +1,25 @@ +The blog feature enables you to deploy in no time a full-featured blog. + +:::info Sample Title + +Check the [Blog Plugin API Reference documentation](./api/plugins/plugin-content-blog.md) for an exhaustive list of options. + +::: + +## Initial setup {#initial-setup} + +To set up your site's blog, start by creating a `blog` directory. + +:::tip + +Use the **[Fast Track](introduction.md#fast-track)** to understand Docusaurus in **5 minutes ⏱**! + +Use **[docusaurus.new](https://docusaurus.new)** to test Docusaurus immediately in your browser! + +::: + +++++tip + +Admonition with different syntax + +++++ diff --git a/packages/docusaurus-mdx-loader/src/remark/admonitions/__tests__/__fixtures__/interpolation.md b/packages/docusaurus-mdx-loader/src/remark/admonitions/__tests__/__fixtures__/interpolation.md new file mode 100644 index 000000000000..a20e62976bf7 --- /dev/null +++ b/packages/docusaurus-mdx-loader/src/remark/admonitions/__tests__/__fixtures__/interpolation.md @@ -0,0 +1,7 @@ +Test admonition with interpolated title/body + +:::tip My `interpolated` **title** + +`body` **interpolated** + +::: diff --git a/packages/docusaurus-mdx-loader/src/remark/admonitions/__tests__/__snapshots__/index.test.ts.snap b/packages/docusaurus-mdx-loader/src/remark/admonitions/__tests__/__snapshots__/index.test.ts.snap new file mode 100644 index 000000000000..227eb28b3370 --- /dev/null +++ b/packages/docusaurus-mdx-loader/src/remark/admonitions/__tests__/__snapshots__/index.test.ts.snap @@ -0,0 +1,44 @@ +// Jest Snapshot v1, https://goo.gl/fbAQLP + +exports[`admonitions remark plugin base 1`] = ` +"

The blog feature enables you to deploy in no time a full-featured blog.

+

Check the Blog Plugin API Reference documentation for an exhaustive list of options.

+

Initial setup {#initial-setup}

+

To set up your site's blog, start by creating a blog directory.

+

Use the Fast Track to understand Docusaurus in 5 minutes ⏱!

Use docusaurus.new to test Docusaurus immediately in your browser!

+

++++tip

+

Admonition with different syntax

+

++++

" +`; + +exports[`admonitions remark plugin custom keywords 1`] = ` +"

The blog feature enables you to deploy in no time a full-featured blog.

+

:::info Sample Title

+

Check the Blog Plugin API Reference documentation for an exhaustive list of options.

+

:::

+

Initial setup {#initial-setup}

+

To set up your site's blog, start by creating a blog directory.

+

Use the Fast Track to understand Docusaurus in 5 minutes ⏱!

Use docusaurus.new to test Docusaurus immediately in your browser!

+

++++tip

+

Admonition with different syntax

+

++++

" +`; + +exports[`admonitions remark plugin custom tag 1`] = ` +"

The blog feature enables you to deploy in no time a full-featured blog.

+

:::info Sample Title

+

Check the Blog Plugin API Reference documentation for an exhaustive list of options.

+

:::

+

Initial setup {#initial-setup}

+

To set up your site's blog, start by creating a blog directory.

+

:::tip

+

Use the Fast Track to understand Docusaurus in 5 minutes ⏱!

+

Use docusaurus.new to test Docusaurus immediately in your browser!

+

:::

+

Admonition with different syntax

" +`; + +exports[`admonitions remark plugin interpolation 1`] = ` +"

Test admonition with interpolated title/body

+My interpolated title <button style={{color: "red"}} onClick={() => alert("click")}>test

body interpolated content

" +`; diff --git a/packages/docusaurus-mdx-loader/src/remark/admonitions/__tests__/index.test.ts b/packages/docusaurus-mdx-loader/src/remark/admonitions/__tests__/index.test.ts new file mode 100644 index 000000000000..3794562bb16d --- /dev/null +++ b/packages/docusaurus-mdx-loader/src/remark/admonitions/__tests__/index.test.ts @@ -0,0 +1,53 @@ +/** + * 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 path from 'path'; +import remark from 'remark'; +import remark2rehype from 'remark-rehype'; +import stringify from 'rehype-stringify'; + +import vfile from 'to-vfile'; +import plugin from '../index'; +import type {AdmonitionOptions} from '../index'; + +const processFixture = async ( + name: string, + options?: Partial, +) => { + const filePath = path.join(__dirname, '__fixtures__', `${name}.md`); + const file = await vfile.read(filePath); + + const result = await remark() + .use(plugin, options) + .use(remark2rehype) + .use(stringify) + .process(file); + + return result.toString(); +}; + +describe('admonitions remark plugin', () => { + it('base', async () => { + const result = await processFixture('base'); + expect(result).toMatchSnapshot(); + }); + + it('custom keywords', async () => { + const result = await processFixture('base', {keywords: ['tip']}); + expect(result).toMatchSnapshot(); + }); + + it('custom tag', async () => { + const result = await processFixture('base', {tag: '++++'}); + expect(result).toMatchSnapshot(); + }); + + it('interpolation', async () => { + const result = await processFixture('interpolation'); + expect(result).toMatchSnapshot(); + }); +}); diff --git a/packages/docusaurus-mdx-loader/src/remark/admonitions/index.ts b/packages/docusaurus-mdx-loader/src/remark/admonitions/index.ts new file mode 100644 index 000000000000..d6393b8c4529 --- /dev/null +++ b/packages/docusaurus-mdx-loader/src/remark/admonitions/index.ts @@ -0,0 +1,186 @@ +/** + * 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 visit from 'unist-util-visit'; +import type {Transformer, Processor, Plugin} from 'unified'; +import type {Literal} from 'mdast'; + +const NEWLINE = '\n'; + +export type AdmonitionOptions = { + tag: string; + keywords: string[]; +}; + +export const DefaultAdmonitionOptions: AdmonitionOptions = { + tag: ':::', + keywords: [ + 'secondary', + 'info', + 'success', + 'danger', + 'note', + 'tip', + 'warning', + 'important', + 'caution', + ], +}; + +function escapeRegExp(s: string): string { + return s.replace(/[-[\]{}()*+?.\\^$|/]/g, '\\$&'); +} + +function normalizeOptions( + options: Partial, +): AdmonitionOptions { + return {...DefaultAdmonitionOptions, ...options}; +} + +// This string value does not matter much +// It is ignored because nodes are using hName/hProperties coming from HAST +const admonitionNodeType = 'admonitionHTML'; + +const plugin: Plugin = function plugin( + this: Processor, + optionsInput: Partial = {}, +): Transformer { + const options = normalizeOptions(optionsInput); + + const keywords = Object.values(options.keywords).map(escapeRegExp).join('|'); + const tag = escapeRegExp(options.tag); + const regex = new RegExp(`${tag}(${keywords})(?: *(.*))?\n`); + const escapeTag = new RegExp(escapeRegExp(`\\${options.tag}`), 'g'); + + // The tokenizer is called on blocks to determine if there is an admonition + // present and create tags for it + function blockTokenizer(this: any, eat: any, value: string, silent: boolean) { + // Stop if no match or match does not start at beginning of line + const match = regex.exec(value); + if (!match || match.index !== 0) { + return false; + } + // If silent return the match + if (silent) { + return true; + } + + const now = eat.now(); + const [opening, keyword, title] = match as string[] as [ + string, + string, + string, + ]; + const food = []; + const content = []; + + let newValue = value; + // consume lines until a closing tag + let idx = newValue.indexOf(NEWLINE); + while (idx !== -1) { + // grab this line and eat it + const next = newValue.indexOf(NEWLINE, idx + 1); + const line = + next !== -1 ? newValue.slice(idx + 1, next) : newValue.slice(idx + 1); + food.push(line); + newValue = newValue.slice(idx + 1); + // the closing tag is NOT part of the content + if (line.startsWith(options.tag)) { + break; + } + content.push(line); + idx = newValue.indexOf(NEWLINE); + } + + // consume the processed tag and replace escape sequences + const contentString = content.join(NEWLINE).replace(escapeTag, options.tag); + const add = eat(opening + food.join(NEWLINE)); + + // parse the content in block mode + const exit = this.enterBlock(); + const contentNodes = this.tokenizeBlock(contentString, now); + exit(); + + const titleNodes = this.tokenizeInline(title, now); + + const isSimpleTextTitle = + titleNodes.length === 1 && titleNodes[0].type === 'text'; + + const element = { + type: admonitionNodeType, + data: { + // hName/hProperties come from HAST + // See https://github.com/syntax-tree/mdast-util-to-hast#fields-on-nodes + hName: 'admonition', + hProperties: { + ...(title && isSimpleTextTitle && {title}), + type: keyword, + }, + }, + children: [ + // For titles containing MDX syntax: create a custom element. The theme + // component will extract it and render it nicely. + // + // Temporary workaround, because it's complex in MDX v1 to emit + // interpolated JSX prop syntax (title={<>my title}). + // For this reason, we use children instead of the title prop. + title && + !isSimpleTextTitle && { + type: admonitionNodeType, + data: { + hName: 'mdxAdmonitionTitle', + hProperties: {}, + }, + children: titleNodes, + }, + ...contentNodes, + ].filter(Boolean), + }; + + return add(element); + } + + // add tokenizer to parser after fenced code blocks + const Parser = this.Parser.prototype; + Parser.blockTokenizers.admonition = blockTokenizer; + Parser.blockMethods.splice( + Parser.blockMethods.indexOf('fencedCode') + 1, + 0, + 'admonition', + ); + Parser.interruptParagraph.splice( + Parser.interruptParagraph.indexOf('fencedCode') + 1, + 0, + ['admonition'], + ); + Parser.interruptList.splice( + Parser.interruptList.indexOf('fencedCode') + 1, + 0, + ['admonition'], + ); + Parser.interruptBlockquote.splice( + Parser.interruptBlockquote.indexOf('fencedCode') + 1, + 0, + ['admonition'], + ); + + return (root) => { + // escape everything except admonitionHTML nodes + visit( + root, + (node: unknown): node is Literal => + (node as Literal | undefined)?.type !== admonitionNodeType, + (node: Literal) => { + if (node.value) { + node.value = node.value.replace(escapeTag, options.tag); + } + }, + ); + }; +}; + +export default plugin; diff --git a/packages/docusaurus-mdx-loader/src/remark/transformImage/index.ts b/packages/docusaurus-mdx-loader/src/remark/transformImage/index.ts index d6988b71ef4d..06892e3ed0b9 100644 --- a/packages/docusaurus-mdx-loader/src/remark/transformImage/index.ts +++ b/packages/docusaurus-mdx-loader/src/remark/transformImage/index.ts @@ -21,6 +21,7 @@ import visit from 'unist-util-visit'; import escapeHtml from 'escape-html'; import sizeOf from 'image-size'; import type {Transformer} from 'unified'; +import type {Parent} from 'unist'; import type {Image, Literal} from 'mdast'; const { @@ -36,12 +37,13 @@ type Context = PluginOptions & { filePath: string; }; +type Target = [node: Image, index: number, parent: Parent]; + async function toImageRequireNode( - node: Image, + [node, index, parent]: Target, imagePath: string, filePath: string, ) { - const jsxNode = node as Literal & Partial; let relativeImagePath = posixPath( path.relative(path.dirname(filePath), imagePath), ); @@ -75,12 +77,12 @@ ${(err as Error).message}`; } } - Object.keys(jsxNode).forEach( - (key) => delete jsxNode[key as keyof typeof jsxNode], - ); + const jsxNode: Literal = { + type: 'jsx', + value: ``, + }; - (jsxNode as Literal).type = 'jsx'; - jsxNode.value = ``; + parent.children.splice(index, 1, jsxNode); } async function ensureImageFileExist(imagePath: string, sourceFilePath: string) { @@ -129,7 +131,8 @@ async function getImageAbsolutePath( return imageFilePath; } -async function processImageNode(node: Image, context: Context) { +async function processImageNode(target: Target, context: Context) { + const [node] = target; if (!node.url) { throw new Error( `Markdown image URL is mandatory in "${toMessageRelativeFilePath( @@ -151,15 +154,18 @@ async function processImageNode(node: Image, context: Context) { // We try to convert image urls without protocol to images with require calls // going through webpack ensures that image assets exist at build time const imagePath = await getImageAbsolutePath(parsedUrl.pathname, context); - await toImageRequireNode(node, imagePath, context.filePath); + await toImageRequireNode(target, imagePath, context.filePath); } export default function plugin(options: PluginOptions): Transformer { return async (root, vfile) => { const promises: Promise[] = []; - visit(root, 'image', (node: Image) => { + visit(root, 'image', (node: Image, index, parent) => { promises.push( - processImageNode(node, {...options, filePath: vfile.path!}), + processImageNode([node, index, parent!], { + ...options, + filePath: vfile.path!, + }), ); }); await Promise.all(promises); diff --git a/packages/docusaurus-mdx-loader/src/remark/transformLinks/__tests__/__fixtures__/asset.md b/packages/docusaurus-mdx-loader/src/remark/transformLinks/__tests__/__fixtures__/asset.md index a23a16a92832..6a8a0e44abcb 100644 --- a/packages/docusaurus-mdx-loader/src/remark/transformLinks/__tests__/__fixtures__/asset.md +++ b/packages/docusaurus-mdx-loader/src/remark/transformLinks/__tests__/__fixtures__/asset.md @@ -38,6 +38,6 @@ [Stylized link to asset file](./asset.pdf) -[json](./data.json) +[JSON](./data.json) -[static json](/static-json.json) +[static JSON](/static-json.json) diff --git a/packages/docusaurus-mdx-loader/src/remark/transformLinks/__tests__/__snapshots__/index.test.ts.snap b/packages/docusaurus-mdx-loader/src/remark/transformLinks/__tests__/__snapshots__/index.test.ts.snap index 0daf646c0574..2e6d8d8648a4 100644 --- a/packages/docusaurus-mdx-loader/src/remark/transformLinks/__tests__/__snapshots__/index.test.ts.snap +++ b/packages/docusaurus-mdx-loader/src/remark/transformLinks/__tests__/__snapshots__/index.test.ts.snap @@ -50,8 +50,8 @@ exports[`transformAsset plugin transform md links to 1`] = ` /node_modules/file-loader/dist/cjs.js?name=assets/files/[name]-[contenthash].[ext]!./asset.pdf').default}>Stylized link to asset file -/node_modules/file-loader/dist/cjs.js?name=assets/files/[name]-[contenthash].[ext]!./data.json').default}>json +/node_modules/file-loader/dist/cjs.js?name=assets/files/[name]-[contenthash].[ext]!./data.json').default}>JSON -/node_modules/file-loader/dist/cjs.js?name=assets/files/[name]-[contenthash].[ext]!./static/static-json.json').default}>static json +/node_modules/file-loader/dist/cjs.js?name=assets/files/[name]-[contenthash].[ext]!./static/static-json.json').default}>static JSON " `; diff --git a/packages/docusaurus-mdx-loader/src/remark/transformLinks/index.ts b/packages/docusaurus-mdx-loader/src/remark/transformLinks/index.ts index 59e1b4117bf5..33602c0d26f4 100644 --- a/packages/docusaurus-mdx-loader/src/remark/transformLinks/index.ts +++ b/packages/docusaurus-mdx-loader/src/remark/transformLinks/index.ts @@ -19,6 +19,7 @@ import visit from 'unist-util-visit'; import escapeHtml from 'escape-html'; import {stringifyContent} from '../utils'; import type {Transformer} from 'unified'; +import type {Parent} from 'unist'; import type {Link, Literal} from 'mdast'; const { @@ -34,16 +35,20 @@ type Context = PluginOptions & { filePath: string; }; +type Target = [node: Link, index: number, parent: Parent]; + /** * Transforms the link node to a JSX `` element with a `require()` call. */ -function toAssetRequireNode(node: Link, assetPath: string, filePath: string) { - const jsxNode = node as Literal & Partial; - let relativeAssetPath = posixPath( - path.relative(path.dirname(filePath), assetPath), - ); +function toAssetRequireNode( + [node, index, parent]: Target, + assetPath: string, + filePath: string, +) { // require("assets/file.pdf") means requiring from a package called assets - relativeAssetPath = `./${relativeAssetPath}`; + const relativeAssetPath = `./${posixPath( + path.relative(path.dirname(filePath), assetPath), + )}`; const parsedUrl = url.parse(node.url); const hash = parsedUrl.hash ?? ''; @@ -60,12 +65,12 @@ function toAssetRequireNode(node: Link, assetPath: string, filePath: string) { const children = stringifyContent(node); const title = node.title ? ` title="${escapeHtml(node.title)}"` : ''; - Object.keys(jsxNode).forEach( - (key) => delete jsxNode[key as keyof typeof jsxNode], - ); + const jsxNode: Literal = { + type: 'jsx', + value: `${children}`, + }; - (jsxNode as Literal).type = 'jsx'; - jsxNode.value = `${children}`; + parent.children.splice(index, 1, jsxNode); } async function ensureAssetFileExist(assetPath: string, sourceFilePath: string) { @@ -106,7 +111,8 @@ async function getAssetAbsolutePath( return null; } -async function processLinkNode(node: Link, context: Context) { +async function processLinkNode(target: Target, context: Context) { + const [node] = target; if (!node.url) { // Try to improve error feedback // see https://github.com/facebook/docusaurus/issues/3309#issuecomment-690371675 @@ -138,15 +144,20 @@ async function processLinkNode(node: Link, context: Context) { context, ); if (assetPath) { - toAssetRequireNode(node, assetPath, context.filePath); + toAssetRequireNode(target, assetPath, context.filePath); } } export default function plugin(options: PluginOptions): Transformer { return async (root, vfile) => { const promises: Promise[] = []; - visit(root, 'link', (node: Link) => { - promises.push(processLinkNode(node, {...options, filePath: vfile.path!})); + visit(root, 'link', (node: Link, index, parent) => { + promises.push( + processLinkNode([node, index, parent!], { + ...options, + filePath: vfile.path!, + }), + ); }); await Promise.all(promises); }; diff --git a/packages/docusaurus-mdx-loader/tsconfig.json b/packages/docusaurus-mdx-loader/tsconfig.json index 3cdfe2a88c91..670db9ce9168 100644 --- a/packages/docusaurus-mdx-loader/tsconfig.json +++ b/packages/docusaurus-mdx-loader/tsconfig.json @@ -6,7 +6,6 @@ "tsBuildInfoFile": "./lib/.tsbuildinfo", "sourceMap": true, "declarationMap": true, - "module": "commonjs", "rootDir": "src", "outDir": "lib", "types": [] diff --git a/packages/docusaurus-migrate/bin/index.mjs b/packages/docusaurus-migrate/bin/index.mjs index 0ace2050c1ca..8be0d9d3bc9d 100755 --- a/packages/docusaurus-migrate/bin/index.mjs +++ b/packages/docusaurus-migrate/bin/index.mjs @@ -34,19 +34,19 @@ cli .option('--mdx', 'try to migrate MD to MDX too') .option('--page', 'try to migrate pages too') .description('Migrate between versions of Docusaurus website.') - .action((siteDir = '.', newDir = '.', {mdx, page} = {}) => { + .action(async (siteDir = '.', newDir = '.', {mdx, page} = {}) => { const sitePath = path.resolve(siteDir); const newSitePath = path.resolve(newDir); - migrateDocusaurusProject(sitePath, newSitePath, mdx, page); + await migrateDocusaurusProject(sitePath, newSitePath, mdx, page); }); cli .command('mdx [siteDir] [newDir]') .description('Migrate markdown files to MDX.') - .action((siteDir = '.', newDir = '.') => { + .action(async (siteDir = '.', newDir = '.') => { const sitePath = path.resolve(siteDir); const newSitePath = path.resolve(newDir); - migrateMDToMDX(sitePath, newSitePath); + await migrateMDToMDX(sitePath, newSitePath); }); cli.parse(process.argv); diff --git a/packages/docusaurus-migrate/tsconfig.build.json b/packages/docusaurus-migrate/tsconfig.build.json index e43e58accad2..bc03b5edf231 100644 --- a/packages/docusaurus-migrate/tsconfig.build.json +++ b/packages/docusaurus-migrate/tsconfig.build.json @@ -5,7 +5,6 @@ "composite": true, "incremental": true, "tsBuildInfoFile": "./lib/.tsbuildinfo", - "module": "commonjs", "rootDir": "src", "outDir": "lib" }, diff --git a/packages/docusaurus-migrate/tsconfig.json b/packages/docusaurus-migrate/tsconfig.json index 5c73d3ac4eca..13e35c5a957c 100644 --- a/packages/docusaurus-migrate/tsconfig.json +++ b/packages/docusaurus-migrate/tsconfig.json @@ -3,7 +3,6 @@ "references": [{"path": "./tsconfig.build.json"}], "compilerOptions": { "noEmit": true, - "module": "esnext", "rootDir": "." }, "include": ["bin"], diff --git a/packages/docusaurus-plugin-client-redirects/src/__tests__/__snapshots__/writeRedirectFiles.test.ts.snap b/packages/docusaurus-plugin-client-redirects/src/__tests__/__snapshots__/writeRedirectFiles.test.ts.snap index 1405eefda432..a344a553cc34 100644 --- a/packages/docusaurus-plugin-client-redirects/src/__tests__/__snapshots__/writeRedirectFiles.test.ts.snap +++ b/packages/docusaurus-plugin-client-redirects/src/__tests__/__snapshots__/writeRedirectFiles.test.ts.snap @@ -1,6 +1,6 @@ // Jest Snapshot v1, https://goo.gl/fbAQLP -exports[`toRedirectFilesMetadata creates appropriate metadata for empty baseUrl: fileContent baseUrl=empty 1`] = ` +exports[`toRedirectFiles creates appropriate metadata for empty baseUrl: fileContent baseUrl=empty 1`] = ` [ " @@ -16,7 +16,7 @@ exports[`toRedirectFilesMetadata creates appropriate metadata for empty baseUrl: ] `; -exports[`toRedirectFilesMetadata creates appropriate metadata for root baseUrl: fileContent baseUrl=/ 1`] = ` +exports[`toRedirectFiles creates appropriate metadata for root baseUrl: fileContent baseUrl=/ 1`] = ` [ " @@ -32,7 +32,7 @@ exports[`toRedirectFilesMetadata creates appropriate metadata for root baseUrl: ] `; -exports[`toRedirectFilesMetadata creates appropriate metadata trailingSlash=false: fileContent 1`] = ` +exports[`toRedirectFiles creates appropriate metadata trailingSlash=false: fileContent 1`] = ` [ " @@ -70,7 +70,7 @@ exports[`toRedirectFilesMetadata creates appropriate metadata trailingSlash=fals ] `; -exports[`toRedirectFilesMetadata creates appropriate metadata trailingSlash=true: fileContent 1`] = ` +exports[`toRedirectFiles creates appropriate metadata trailingSlash=true: fileContent 1`] = ` [ " @@ -108,7 +108,7 @@ exports[`toRedirectFilesMetadata creates appropriate metadata trailingSlash=true ] `; -exports[`toRedirectFilesMetadata creates appropriate metadata trailingSlash=undefined: fileContent 1`] = ` +exports[`toRedirectFiles creates appropriate metadata trailingSlash=undefined: fileContent 1`] = ` [ " diff --git a/packages/docusaurus-plugin-client-redirects/src/__tests__/writeRedirectFiles.test.ts b/packages/docusaurus-plugin-client-redirects/src/__tests__/writeRedirectFiles.test.ts index 32b992c08650..f6cf9476f92f 100644 --- a/packages/docusaurus-plugin-client-redirects/src/__tests__/writeRedirectFiles.test.ts +++ b/packages/docusaurus-plugin-client-redirects/src/__tests__/writeRedirectFiles.test.ts @@ -9,7 +9,7 @@ import fs from 'fs-extra'; import path from 'path'; import writeRedirectFiles, { - toRedirectFilesMetadata, + toRedirectFiles, createToUrl, } from '../writeRedirectFiles'; @@ -42,14 +42,14 @@ describe('createToUrl', () => { }); }); -describe('toRedirectFilesMetadata', () => { +describe('toRedirectFiles', () => { it('creates appropriate metadata trailingSlash=undefined', () => { const pluginContext = { outDir: '/tmp/someFixedOutDir', baseUrl: 'https://docusaurus.io', }; - const redirectFiles = toRedirectFilesMetadata( + const redirectFiles = toRedirectFiles( [ {from: '/abc.html', to: '/abc'}, {from: '/def', to: '/def.html'}, @@ -76,7 +76,7 @@ describe('toRedirectFilesMetadata', () => { baseUrl: 'https://docusaurus.io', }; - const redirectFiles = toRedirectFilesMetadata( + const redirectFiles = toRedirectFiles( [ {from: '/abc.html', to: '/abc'}, {from: '/def', to: '/def.html'}, @@ -103,7 +103,7 @@ describe('toRedirectFilesMetadata', () => { baseUrl: 'https://docusaurus.io', }; - const redirectFiles = toRedirectFilesMetadata( + const redirectFiles = toRedirectFiles( [ {from: '/abc.html', to: '/abc'}, {from: '/def', to: '/def.html'}, @@ -132,7 +132,7 @@ describe('toRedirectFilesMetadata', () => { outDir: '/tmp/someFixedOutDir', baseUrl: '/', }; - const redirectFiles = toRedirectFilesMetadata( + const redirectFiles = toRedirectFiles( [{from: '/abc.html', to: '/abc'}], pluginContext, undefined, @@ -147,7 +147,7 @@ describe('toRedirectFilesMetadata', () => { outDir: '/tmp/someFixedOutDir', baseUrl: '', }; - const redirectFiles = toRedirectFilesMetadata( + const redirectFiles = toRedirectFiles( [{from: '/abc.html', to: '/abc'}], pluginContext, undefined, diff --git a/packages/docusaurus-plugin-client-redirects/src/collectRedirects.ts b/packages/docusaurus-plugin-client-redirects/src/collectRedirects.ts index fa4718eca32f..3cd0db4096cd 100644 --- a/packages/docusaurus-plugin-client-redirects/src/collectRedirects.ts +++ b/packages/docusaurus-plugin-client-redirects/src/collectRedirects.ts @@ -7,52 +7,57 @@ import _ from 'lodash'; import logger from '@docusaurus/logger'; -import { - applyTrailingSlash, - type ApplyTrailingSlashParams, -} from '@docusaurus/utils-common'; +import {applyTrailingSlash} from '@docusaurus/utils-common'; import { createFromExtensionsRedirects, createToExtensionsRedirects, } from './extensionRedirects'; import {validateRedirect} from './redirectValidation'; import type {PluginOptions, RedirectOption} from './options'; -import type {PluginContext, RedirectMetadata} from './types'; +import type {PluginContext, RedirectItem} from './types'; export default function collectRedirects( pluginContext: PluginContext, trailingSlash: boolean | undefined, -): RedirectMetadata[] { - let redirects = doCollectRedirects(pluginContext); - - redirects = applyRedirectsTrailingSlash(redirects, { - trailingSlash, - baseUrl: pluginContext.baseUrl, - }); +): RedirectItem[] { + // For each plugin config option, create the appropriate redirects + const redirects = [ + ...createFromExtensionsRedirects( + pluginContext.relativeRoutesPaths, + pluginContext.options.fromExtensions, + ), + ...createToExtensionsRedirects( + pluginContext.relativeRoutesPaths, + pluginContext.options.toExtensions, + ), + ...createRedirectsOptionRedirects(pluginContext.options.redirects), + ...createCreateRedirectsOptionRedirects( + pluginContext.relativeRoutesPaths, + pluginContext.options.createRedirects, + ), + ].map((redirect) => ({ + ...redirect, + // Given a redirect with `to: "/abc"` and `trailingSlash` enabled: + // + // - We don't want to reject `to: "/abc"`, as that unambiguously points to + // `/abc/` now; + // - We want to redirect `to: /abc/` without the user having to change all + // her redirect plugin options + // + // It should be easy to toggle `trailingSlash` option without having to + // change other configs + to: applyTrailingSlash(redirect.to, { + trailingSlash, + baseUrl: pluginContext.baseUrl, + }), + })); validateCollectedRedirects(redirects, pluginContext); return filterUnwantedRedirects(redirects, pluginContext); } -// If users wants to redirect to=/abc and they enable trailingSlash=true then -// => we don't want to reject the to=/abc (as only /abc/ is an existing/valid -// path now) -// => we want to redirect to=/abc/ without the user having to change all its -// redirect plugin options -// It should be easy to toggle siteConfig.trailingSlash option without having to -// change other configs -function applyRedirectsTrailingSlash( - redirects: RedirectMetadata[], - params: ApplyTrailingSlashParams, -) { - return redirects.map((redirect) => ({ - ...redirect, - to: applyTrailingSlash(redirect.to, params), - })); -} - function validateCollectedRedirects( - redirects: RedirectMetadata[], + redirects: RedirectItem[], pluginContext: PluginContext, ) { const redirectValidationErrors = redirects @@ -89,9 +94,9 @@ Valid paths you can redirect to: } function filterUnwantedRedirects( - redirects: RedirectMetadata[], + redirects: RedirectItem[], pluginContext: PluginContext, -): RedirectMetadata[] { +): RedirectItem[] { // We don't want to create the same redirect twice, since that would lead to // writing the same html redirection file twice. Object.entries(_.groupBy(redirects, (redirect) => redirect.from)).forEach( @@ -120,37 +125,15 @@ It is not possible to redirect the same pathname to multiple destinations: ${gro ); } -// For each plugin config option, create the appropriate redirects -function doCollectRedirects(pluginContext: PluginContext): RedirectMetadata[] { - return [ - ...createFromExtensionsRedirects( - pluginContext.relativeRoutesPaths, - pluginContext.options.fromExtensions, - ), - ...createToExtensionsRedirects( - pluginContext.relativeRoutesPaths, - pluginContext.options.toExtensions, - ), - ...createRedirectsOptionRedirects(pluginContext.options.redirects), - ...createCreateRedirectsOptionRedirects( - pluginContext.relativeRoutesPaths, - pluginContext.options.createRedirects, - ), - ]; -} - function createRedirectsOptionRedirects( redirectsOption: PluginOptions['redirects'], -): RedirectMetadata[] { +): RedirectItem[] { // For convenience, user can use a string or a string[] - function optionToRedirects(option: RedirectOption): RedirectMetadata[] { + function optionToRedirects(option: RedirectOption): RedirectItem[] { if (typeof option.from === 'string') { return [{from: option.from, to: option.to}]; } - return option.from.map((from) => ({ - from, - to: option.to, - })); + return option.from.map((from) => ({from, to: option.to})); } return redirectsOption.flatMap(optionToRedirects); @@ -160,17 +143,14 @@ function createRedirectsOptionRedirects( function createCreateRedirectsOptionRedirects( paths: string[], createRedirects: PluginOptions['createRedirects'], -): RedirectMetadata[] { - function createPathRedirects(path: string): RedirectMetadata[] { +): RedirectItem[] { + function createPathRedirects(path: string): RedirectItem[] { const fromsMixed: string | string[] = createRedirects?.(path) ?? []; const froms: string[] = typeof fromsMixed === 'string' ? [fromsMixed] : fromsMixed; - return froms.map((from) => ({ - from, - to: path, - })); + return froms.map((from) => ({from, to: path})); } return paths.flatMap(createPathRedirects); diff --git a/packages/docusaurus-plugin-client-redirects/src/deps.d.ts b/packages/docusaurus-plugin-client-redirects/src/deps.d.ts new file mode 100644 index 000000000000..90ace5ffd5e8 --- /dev/null +++ b/packages/docusaurus-plugin-client-redirects/src/deps.d.ts @@ -0,0 +1,16 @@ +/** + * 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. + */ + +// TODO incompatible declaration file +declare module 'eta' { + export const defaultConfig: object; + + export function compile( + template: string, + options?: object, + ): (data: object, config: object) => string; +} diff --git a/packages/docusaurus-plugin-client-redirects/src/extensionRedirects.ts b/packages/docusaurus-plugin-client-redirects/src/extensionRedirects.ts index a72452a7528c..86fa4aeb48de 100644 --- a/packages/docusaurus-plugin-client-redirects/src/extensionRedirects.ts +++ b/packages/docusaurus-plugin-client-redirects/src/extensionRedirects.ts @@ -10,7 +10,7 @@ import { removeSuffix, removeTrailingSlash, } from '@docusaurus/utils'; -import type {RedirectMetadata} from './types'; +import type {RedirectItem} from './types'; const ExtensionAdditionalMessage = 'If the redirect extension system is not good enough for your use case, you can create redirects yourself with the "createRedirects" plugin option.'; @@ -40,23 +40,21 @@ const validateExtension = (ext: string) => { const addLeadingDot = (extension: string) => `.${extension}`; -// Create new /path that redirects to existing an /path.html +/** + * Create new `/path` that redirects to existing an `/path.html` + */ export function createToExtensionsRedirects( paths: string[], extensions: string[], -): RedirectMetadata[] { +): RedirectItem[] { extensions.forEach(validateExtension); const dottedExtensions = extensions.map(addLeadingDot); - const createPathRedirects = (path: string): RedirectMetadata[] => { + const createPathRedirects = (path: string): RedirectItem[] => { const extensionFound = dottedExtensions.find((ext) => path.endsWith(ext)); if (extensionFound) { - const routePathWithoutExtension = removeSuffix(path, extensionFound); - return [routePathWithoutExtension].map((from) => ({ - from, - to: path, - })); + return [{from: removeSuffix(path, extensionFound), to: path}]; } return []; }; @@ -64,12 +62,15 @@ export function createToExtensionsRedirects( return paths.flatMap(createPathRedirects); } -// Create new /path.html/index.html that redirects to existing an /path -// The filename pattern might look weird but it's on purpose (see https://github.com/facebook/docusaurus/issues/5055) +/** + * Create new `/path.html/index.html` that redirects to existing an `/path` + * The filename pattern might look weird but it's on purpose (see + * https://github.com/facebook/docusaurus/issues/5055) + */ export function createFromExtensionsRedirects( paths: string[], extensions: string[], -): RedirectMetadata[] { +): RedirectItem[] { extensions.forEach(validateExtension); const dottedExtensions = extensions.map(addLeadingDot); @@ -77,7 +78,7 @@ export function createFromExtensionsRedirects( const alreadyEndsWithAnExtension = (str: string) => dottedExtensions.some((ext) => str.endsWith(ext)); - const createPathRedirects = (path: string): RedirectMetadata[] => { + const createPathRedirects = (path: string): RedirectItem[] => { if (path === '' || path === '/' || alreadyEndsWithAnExtension(path)) { return []; } diff --git a/packages/docusaurus-plugin-client-redirects/src/index.ts b/packages/docusaurus-plugin-client-redirects/src/index.ts index 237f3f099e9e..fa96902d19e5 100644 --- a/packages/docusaurus-plugin-client-redirects/src/index.ts +++ b/packages/docusaurus-plugin-client-redirects/src/index.ts @@ -8,11 +8,11 @@ import {removePrefix, addLeadingSlash} from '@docusaurus/utils'; import collectRedirects from './collectRedirects'; import writeRedirectFiles, { - toRedirectFilesMetadata, - type RedirectFileMetadata, + toRedirectFiles, + type RedirectFile, } from './writeRedirectFiles'; import type {LoadContext, Plugin} from '@docusaurus/types'; -import type {PluginContext, RedirectMetadata} from './types'; +import type {PluginContext, RedirectItem} from './types'; import type {PluginOptions, Options} from './options'; export default function pluginClientRedirectsPages( @@ -33,12 +33,12 @@ export default function pluginClientRedirectsPages( options, }; - const redirects: RedirectMetadata[] = collectRedirects( + const redirects: RedirectItem[] = collectRedirects( pluginContext, trailingSlash, ); - const redirectFiles: RedirectFileMetadata[] = toRedirectFilesMetadata( + const redirectFiles: RedirectFile[] = toRedirectFiles( redirects, pluginContext, trailingSlash, diff --git a/packages/docusaurus-plugin-client-redirects/src/options.ts b/packages/docusaurus-plugin-client-redirects/src/options.ts index 389e90b958aa..675e38902898 100644 --- a/packages/docusaurus-plugin-client-redirects/src/options.ts +++ b/packages/docusaurus-plugin-client-redirects/src/options.ts @@ -9,7 +9,9 @@ import {Joi, PathnameSchema} from '@docusaurus/utils-validation'; import type {OptionValidationContext} from '@docusaurus/types'; export type RedirectOption = { + /** Pathname of an existing Docusaurus page */ to: string; + /** Pathname of the new page(s) we should create */ from: string | string[]; }; @@ -23,7 +25,9 @@ export type PluginOptions = { /** The list of redirect rules, each one with multiple `from`s → one `to`. */ redirects: RedirectOption[]; /** - * A callback to create a redirect rule. + * A callback to create a redirect rule. Docusaurus query this callback + * against every path it has created, and use its return value to output more + * paths. * @returns All the paths from which we should redirect to `path` */ createRedirects?: ( diff --git a/packages/docusaurus-plugin-client-redirects/src/redirectValidation.ts b/packages/docusaurus-plugin-client-redirects/src/redirectValidation.ts index 334453274b1e..7b7a471f4b6f 100644 --- a/packages/docusaurus-plugin-client-redirects/src/redirectValidation.ts +++ b/packages/docusaurus-plugin-client-redirects/src/redirectValidation.ts @@ -6,14 +6,14 @@ */ import {Joi, PathnameSchema} from '@docusaurus/utils-validation'; -import type {RedirectMetadata} from './types'; +import type {RedirectItem} from './types'; -const RedirectSchema = Joi.object({ +const RedirectSchema = Joi.object({ from: PathnameSchema.required(), to: PathnameSchema.required(), }); -export function validateRedirect(redirect: RedirectMetadata): void { +export function validateRedirect(redirect: RedirectItem): void { const {error} = RedirectSchema.validate(redirect, { abortEarly: true, convert: false, diff --git a/packages/docusaurus-plugin-client-redirects/src/types.ts b/packages/docusaurus-plugin-client-redirects/src/types.ts index 8ad61ae06c47..110e189c2f48 100644 --- a/packages/docusaurus-plugin-client-redirects/src/types.ts +++ b/packages/docusaurus-plugin-client-redirects/src/types.ts @@ -21,7 +21,7 @@ export type PluginContext = Pick & { * /!\ easy to be confused: "from" is the new page we should create, * that redirects to "to": the existing Docusaurus page */ -export type RedirectMetadata = { +export type RedirectItem = { /** Pathname of the new page we should create */ from: string; /** Pathname of an existing Docusaurus page */ diff --git a/packages/docusaurus-plugin-client-redirects/src/writeRedirectFiles.ts b/packages/docusaurus-plugin-client-redirects/src/writeRedirectFiles.ts index 77a9316c829a..4f70e064ce02 100644 --- a/packages/docusaurus-plugin-client-redirects/src/writeRedirectFiles.ts +++ b/packages/docusaurus-plugin-client-redirects/src/writeRedirectFiles.ts @@ -13,11 +13,11 @@ import {normalizeUrl} from '@docusaurus/utils'; import createRedirectPageContent from './createRedirectPageContent'; -import type {PluginContext, RedirectMetadata} from './types'; +import type {PluginContext, RedirectItem} from './types'; export type WriteFilesPluginContext = Pick; -export type RedirectFileMetadata = { +export type RedirectFile = { fileAbsolutePath: string; fileContent: string; }; @@ -57,11 +57,11 @@ function getRedirectFilePath( return path.join(filePath, `${fileName}/index.html`); } -export function toRedirectFilesMetadata( - redirects: RedirectMetadata[], +export function toRedirectFiles( + redirects: RedirectItem[], pluginContext: WriteFilesPluginContext, trailingSlash: boolean | undefined, -): RedirectFileMetadata[] { +): RedirectFile[] { // Perf: avoid rendering the template twice with the exact same "props" // We might create multiple redirect pages for the same destination url // note: the first fn arg is the cache key! @@ -69,7 +69,7 @@ export function toRedirectFilesMetadata( createRedirectPageContent({toUrl}), ); - const createFileMetadata = (redirect: RedirectMetadata) => { + const createFileMetadata = (redirect: RedirectItem) => { const fileRelativePath = getRedirectFilePath(redirect.from, trailingSlash); const fileAbsolutePath = path.join(pluginContext.outDir, fileRelativePath); const toUrl = createToUrl(pluginContext.baseUrl, redirect.to); @@ -84,9 +84,7 @@ export function toRedirectFilesMetadata( return redirects.map(createFileMetadata); } -export async function writeRedirectFile( - file: RedirectFileMetadata, -): Promise { +export async function writeRedirectFile(file: RedirectFile): Promise { try { // User-friendly security to prevent file overrides if (await fs.pathExists(file.fileAbsolutePath)) { @@ -108,7 +106,7 @@ export async function writeRedirectFile( } export default async function writeRedirectFiles( - redirectFiles: RedirectFileMetadata[], + redirectFiles: RedirectFile[], ): Promise { await Promise.all(redirectFiles.map(writeRedirectFile)); } diff --git a/packages/docusaurus-plugin-client-redirects/tsconfig.json b/packages/docusaurus-plugin-client-redirects/tsconfig.json index 80e43e9813ef..e16d5c2c5d33 100644 --- a/packages/docusaurus-plugin-client-redirects/tsconfig.json +++ b/packages/docusaurus-plugin-client-redirects/tsconfig.json @@ -4,7 +4,6 @@ "noEmit": false, "incremental": true, "tsBuildInfoFile": "./lib/.tsbuildinfo", - "module": "commonjs", "rootDir": "src", "outDir": "lib" }, diff --git a/packages/docusaurus-plugin-content-blog/package.json b/packages/docusaurus-plugin-content-blog/package.json index f5bfcff31857..e00c5e5b8517 100644 --- a/packages/docusaurus-plugin-content-blog/package.json +++ b/packages/docusaurus-plugin-content-blog/package.json @@ -30,11 +30,10 @@ "fs-extra": "^10.1.0", "lodash": "^4.17.21", "reading-time": "^1.5.0", - "remark-admonitions": "^1.2.1", "tslib": "^2.4.0", "unist-util-visit": "^2.0.3", "utility-types": "^3.10.0", - "webpack": "^5.72.1" + "webpack": "^5.73.0" }, "devDependencies": { "@docusaurus/types": "2.0.0-beta.21", 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 d7747d16300c..b02b620456c4 100644 --- a/packages/docusaurus-plugin-content-blog/src/__tests__/feed.test.ts +++ b/packages/docusaurus-plugin-content-blog/src/__tests__/feed.test.ts @@ -19,12 +19,14 @@ const DefaultI18N: I18n = { currentLocale: 'en', locales: ['en'], defaultLocale: 'en', + path: '1i8n', localeConfigs: { en: { label: 'English', direction: 'ltr', htmlLang: 'en', calendar: 'gregory', + path: 'en', }, }, }; 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 47d4b98fd4e0..5107dc2f88df 100644 --- a/packages/docusaurus-plugin-content-blog/src/__tests__/index.test.ts +++ b/packages/docusaurus-plugin-content-blog/src/__tests__/index.test.ts @@ -47,12 +47,14 @@ function getI18n(locale: string): I18n { currentLocale: locale, locales: [locale], defaultLocale: locale, + path: 'i18n', localeConfigs: { [locale]: { calendar: 'gregory', label: locale, htmlLang: locale, direction: 'ltr', + path: locale, }, }, }; @@ -70,6 +72,11 @@ const getPlugin = async ( i18n: I18n = DefaultI18N, ) => { const generatedFilesDir: string = path.resolve(siteDir, '.docusaurus'); + const localizationDir = path.join( + siteDir, + i18n.path, + i18n.localeConfigs[i18n.currentLocale]!.path, + ); const siteConfig = { title: 'Hello', baseUrl: '/', @@ -81,6 +88,7 @@ const getPlugin = async ( siteConfig, generatedFilesDir, i18n, + localizationDir, } as LoadContext, validateOptions({ validate: normalizePluginOptions as Validate< diff --git a/packages/docusaurus-plugin-content-blog/src/deps.d.ts b/packages/docusaurus-plugin-content-blog/src/deps.d.ts deleted file mode 100644 index 6b8b33906b54..000000000000 --- a/packages/docusaurus-plugin-content-blog/src/deps.d.ts +++ /dev/null @@ -1,13 +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. - */ - -declare module 'remark-admonitions' { - type Options = {[key: string]: unknown}; - - const plugin: (options?: Options) => void; - export = plugin; -} diff --git a/packages/docusaurus-plugin-content-blog/src/index.ts b/packages/docusaurus-plugin-content-blog/src/index.ts index 2b0355a0f3f1..c4073e49274d 100644 --- a/packages/docusaurus-plugin-content-blog/src/index.ts +++ b/packages/docusaurus-plugin-content-blog/src/index.ts @@ -21,7 +21,6 @@ import { type TagsListItem, type TagModule, } from '@docusaurus/utils'; -import admonitions from 'remark-admonitions'; import { generateBlogPosts, getSourceToPermalink, @@ -49,16 +48,11 @@ export default async function pluginContentBlog( context: LoadContext, options: PluginOptions, ): Promise> { - if (options.admonitions) { - options.remarkPlugins = options.remarkPlugins.concat([ - [admonitions, options.admonitions], - ]); - } - const { siteDir, siteConfig, generatedFilesDir, + localizationDir, i18n: {currentLocale}, } = context; const {onBrokenMarkdownLinks, baseUrl} = siteConfig; @@ -66,8 +60,7 @@ export default async function pluginContentBlog( const contentPaths: BlogContentPaths = { contentPath: path.resolve(siteDir, options.path), contentPathLocalized: getPluginI18nPath({ - siteDir, - locale: currentLocale, + localizationDir, pluginName: 'docusaurus-plugin-content-blog', pluginId: options.id, }), @@ -381,6 +374,7 @@ export default async function pluginContentBlog( configureWebpack(_config, isServer, {getJSLoader}, content) { const { + admonitions, rehypePlugins, remarkPlugins, truncateMarker, @@ -423,6 +417,7 @@ export default async function pluginContentBlog( { loader: require.resolve('@docusaurus/mdx-loader'), options: { + admonitions, remarkPlugins, rehypePlugins, beforeDefaultRemarkPlugins: [ diff --git a/packages/docusaurus-plugin-content-blog/src/options.ts b/packages/docusaurus-plugin-content-blog/src/options.ts index 0375aba578e3..99c4067a9ad8 100644 --- a/packages/docusaurus-plugin-content-blog/src/options.ts +++ b/packages/docusaurus-plugin-content-blog/src/options.ts @@ -24,7 +24,7 @@ export const DEFAULT_OPTIONS: PluginOptions = { feedOptions: {type: ['rss', 'atom'], copyright: ''}, beforeDefaultRehypePlugins: [], beforeDefaultRemarkPlugins: [], - admonitions: {}, + admonitions: true, truncateMarker: //, rehypePlugins: [], remarkPlugins: [], 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 e8a8697fa8cd..ae87a218105b 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 @@ -377,7 +377,6 @@ declare module '@docusaurus/plugin-content-blog' { * unlocalized file. Ignored when `editUrl` is a function. */ editLocalizedFiles?: boolean; - admonitions: {[key: string]: unknown}; /** Path to the authors map file, relative to the blog content directory. */ authorsMapPath: string; /** A callback to customize the reading time number displayed. */ diff --git a/packages/docusaurus-plugin-content-blog/tsconfig.json b/packages/docusaurus-plugin-content-blog/tsconfig.json index 80e43e9813ef..e16d5c2c5d33 100644 --- a/packages/docusaurus-plugin-content-blog/tsconfig.json +++ b/packages/docusaurus-plugin-content-blog/tsconfig.json @@ -4,7 +4,6 @@ "noEmit": false, "incremental": true, "tsBuildInfoFile": "./lib/.tsbuildinfo", - "module": "commonjs", "rootDir": "src", "outDir": "lib" }, diff --git a/packages/docusaurus-plugin-content-docs/package.json b/packages/docusaurus-plugin-content-docs/package.json index bc6a154f51b4..28d79211769a 100644 --- a/packages/docusaurus-plugin-content-docs/package.json +++ b/packages/docusaurus-plugin-content-docs/package.json @@ -6,9 +6,18 @@ "sideEffects": false, "exports": { "./src/*": "./src/*", - "./client": "./lib/client/index.js", - "./server": "./lib/server-export.js", - ".": "./lib/index.js" + "./client": { + "type": "./lib/client/index.d.ts", + "default": "./lib/client/index.js" + }, + "./server": { + "type": "./lib/server-export.d.ts", + "default": "./lib/server-export.js" + }, + ".": { + "types": "./src/plugin-content-docs.d.ts", + "default": "./lib/index.js" + } }, "types": "src/plugin-content-docs.d.ts", "scripts": { @@ -38,10 +47,9 @@ "import-fresh": "^3.3.0", "js-yaml": "^4.1.0", "lodash": "^4.17.21", - "remark-admonitions": "^1.2.1", "tslib": "^2.4.0", "utility-types": "^3.10.0", - "webpack": "^5.72.1" + "webpack": "^5.73.0" }, "devDependencies": { "@docusaurus/types": "2.0.0-beta.21", diff --git a/packages/docusaurus-plugin-content-docs/src/__tests__/__fixtures__/simple-site/docs/customLastUpdate.md b/packages/docusaurus-plugin-content-docs/src/__tests__/__fixtures__/simple-site/docs/customLastUpdate.md new file mode 100644 index 000000000000..b8e37d4f8a9e --- /dev/null +++ b/packages/docusaurus-plugin-content-docs/src/__tests__/__fixtures__/simple-site/docs/customLastUpdate.md @@ -0,0 +1,8 @@ +--- +title: Custom Last Update +last_update: + author: Custom Author + date: 1/1/2000 +--- + +Custom last update \ No newline at end of file diff --git a/packages/docusaurus-plugin-content-docs/src/__tests__/__fixtures__/simple-site/docs/foo/baz.md b/packages/docusaurus-plugin-content-docs/src/__tests__/__fixtures__/simple-site/docs/foo/baz.md index 3407ccd1b033..c3f676e276ad 100644 --- a/packages/docusaurus-plugin-content-docs/src/__tests__/__fixtures__/simple-site/docs/foo/baz.md +++ b/packages/docusaurus-plugin-content-docs/src/__tests__/__fixtures__/simple-site/docs/foo/baz.md @@ -10,7 +10,7 @@ tags: permalink: tag2-custom-permalink --- -# Baz markdown title +# Baz Markdown title ## Images diff --git a/packages/docusaurus-plugin-content-docs/src/__tests__/__fixtures__/simple-site/docs/lastUpdateAuthorOnly.md b/packages/docusaurus-plugin-content-docs/src/__tests__/__fixtures__/simple-site/docs/lastUpdateAuthorOnly.md new file mode 100644 index 000000000000..4929ed91a9c5 --- /dev/null +++ b/packages/docusaurus-plugin-content-docs/src/__tests__/__fixtures__/simple-site/docs/lastUpdateAuthorOnly.md @@ -0,0 +1,7 @@ +--- +title: Last Update Author Only +last_update: + author: Custom Author +--- + +Only custom author, so it will still use the date from Git \ No newline at end of file diff --git a/packages/docusaurus-plugin-content-docs/src/__tests__/__fixtures__/simple-site/docs/lastUpdateDateOnly.md b/packages/docusaurus-plugin-content-docs/src/__tests__/__fixtures__/simple-site/docs/lastUpdateDateOnly.md new file mode 100644 index 000000000000..f9bfeb9759d9 --- /dev/null +++ b/packages/docusaurus-plugin-content-docs/src/__tests__/__fixtures__/simple-site/docs/lastUpdateDateOnly.md @@ -0,0 +1,7 @@ +--- +title: Last Update Date Only +last_update: + date: 1/1/2000 +--- + +Only custom date, so it will still use the author from Git \ No newline at end of file diff --git a/packages/docusaurus-plugin-content-docs/src/__tests__/__fixtures__/site-with-custom-i18n-path/docs/category1/doc1.md b/packages/docusaurus-plugin-content-docs/src/__tests__/__fixtures__/site-with-custom-i18n-path/docs/category1/doc1.md new file mode 100644 index 000000000000..e69de29bb2d1 diff --git a/packages/docusaurus-plugin-content-docs/src/__tests__/__fixtures__/site-with-custom-i18n-path/docs/category2/doc2.md b/packages/docusaurus-plugin-content-docs/src/__tests__/__fixtures__/site-with-custom-i18n-path/docs/category2/doc2.md new file mode 100644 index 000000000000..e69de29bb2d1 diff --git a/packages/docusaurus-plugin-content-docs/src/__tests__/__fixtures__/site-with-custom-i18n-path/i18n-custom/zh-Hans-custom/docusaurus-plugin-content-docs/current/category1/doc1.md b/packages/docusaurus-plugin-content-docs/src/__tests__/__fixtures__/site-with-custom-i18n-path/i18n-custom/zh-Hans-custom/docusaurus-plugin-content-docs/current/category1/doc1.md new file mode 100644 index 000000000000..e69de29bb2d1 diff --git a/packages/docusaurus-plugin-content-docs/src/__tests__/__fixtures__/site-with-custom-i18n-path/i18n-custom/zh-Hans-custom/docusaurus-plugin-content-docs/current/category2/doc2.md b/packages/docusaurus-plugin-content-docs/src/__tests__/__fixtures__/site-with-custom-i18n-path/i18n-custom/zh-Hans-custom/docusaurus-plugin-content-docs/current/category2/doc2.md new file mode 100644 index 000000000000..e69de29bb2d1 diff --git a/packages/docusaurus-plugin-content-docs/src/__tests__/__fixtures__/site-with-custom-i18n-path/sidebars.json b/packages/docusaurus-plugin-content-docs/src/__tests__/__fixtures__/site-with-custom-i18n-path/sidebars.json new file mode 100644 index 000000000000..9441eff999e7 --- /dev/null +++ b/packages/docusaurus-plugin-content-docs/src/__tests__/__fixtures__/site-with-custom-i18n-path/sidebars.json @@ -0,0 +1 @@ +[{ "type": "autogenerated", "dirName": "." }] diff --git a/packages/docusaurus-plugin-content-docs/src/__tests__/__snapshots__/cli.test.ts.snap b/packages/docusaurus-plugin-content-docs/src/__tests__/__snapshots__/cli.test.ts.snap index 668d5277e941..edff61da5b8b 100644 --- a/packages/docusaurus-plugin-content-docs/src/__tests__/__snapshots__/cli.test.ts.snap +++ b/packages/docusaurus-plugin-content-docs/src/__tests__/__snapshots__/cli.test.ts.snap @@ -66,3 +66,12 @@ exports[`docsVersion second docs instance versioning 1`] = ` ], } `; + +exports[`docsVersion works with custom i18n paths 1`] = ` +[ + { + "dirName": ".", + "type": "autogenerated", + }, +] +`; diff --git a/packages/docusaurus-plugin-content-docs/src/__tests__/__snapshots__/docs.test.ts.snap b/packages/docusaurus-plugin-content-docs/src/__tests__/__snapshots__/docs.test.ts.snap index f05c66e2aa21..69401a06a04c 100644 --- a/packages/docusaurus-plugin-content-docs/src/__tests__/__snapshots__/docs.test.ts.snap +++ b/packages/docusaurus-plugin-content-docs/src/__tests__/__snapshots__/docs.test.ts.snap @@ -3,13 +3,24 @@ exports[`simple site custom pagination 1`] = ` { "pagination": [ + { + "id": "customLastUpdate", + "next": { + "permalink": "/docs/doc with space", + "title": "Hoo hoo, if this path tricks you...", + }, + "prev": undefined, + }, { "id": "doc with space", "next": { "permalink": "/docs/doc-draft", "title": "doc-draft", }, - "prev": undefined, + "prev": { + "permalink": "/docs/customLastUpdate", + "title": "Custom Last Update", + }, }, { "id": "doc-draft", @@ -63,14 +74,36 @@ exports[`simple site custom pagination 1`] = ` { "id": "ipsum", "next": { - "permalink": "/docs/lorem", - "title": "lorem", + "permalink": "/docs/lastUpdateAuthorOnly", + "title": "Last Update Author Only", }, "prev": { "permalink": "/docs/", "title": "Hello sidebar_label", }, }, + { + "id": "lastUpdateAuthorOnly", + "next": { + "permalink": "/docs/lastUpdateDateOnly", + "title": "Last Update Date Only", + }, + "prev": { + "permalink": "/docs/ipsum", + "title": "ipsum", + }, + }, + { + "id": "lastUpdateDateOnly", + "next": { + "permalink": "/docs/lorem", + "title": "lorem", + }, + "prev": { + "permalink": "/docs/lastUpdateAuthorOnly", + "title": "Last Update Author Only", + }, + }, { "id": "lorem", "next": { @@ -78,8 +111,8 @@ exports[`simple site custom pagination 1`] = ` "title": "rootAbsoluteSlug", }, "prev": { - "permalink": "/docs/ipsum", - "title": "ipsum", + "permalink": "/docs/lastUpdateDateOnly", + "title": "Last Update Date Only", }, }, { @@ -170,6 +203,10 @@ exports[`simple site custom pagination 1`] = ` ], "sidebars": { "defaultSidebar": [ + { + "id": "customLastUpdate", + "type": "doc", + }, { "id": "doc with space", "type": "doc", @@ -208,6 +245,14 @@ exports[`simple site custom pagination 1`] = ` "id": "ipsum", "type": "doc", }, + { + "id": "lastUpdateAuthorOnly", + "type": "doc", + }, + { + "id": "lastUpdateDateOnly", + "type": "doc", + }, { "id": "lorem", "type": "doc", diff --git a/packages/docusaurus-plugin-content-docs/src/__tests__/__snapshots__/index.test.ts.snap b/packages/docusaurus-plugin-content-docs/src/__tests__/__snapshots__/index.test.ts.snap index c8b0408c5ee1..c428a6c55e86 100644 --- a/packages/docusaurus-plugin-content-docs/src/__tests__/__snapshots__/index.test.ts.snap +++ b/packages/docusaurus-plugin-content-docs/src/__tests__/__snapshots__/index.test.ts.snap @@ -22,6 +22,7 @@ These sidebar document ids do not exist: - nonExistent Available document ids are: +- customLastUpdate - doc with space - doc-draft - foo/bar @@ -29,6 +30,8 @@ Available document ids are: - headingAsTitle - hello - ipsum +- lastUpdateAuthorOnly +- lastUpdateDateOnly - lorem - rootAbsoluteSlug - rootRelativeSlug @@ -267,6 +270,11 @@ exports[`simple website content 5`] = ` "versions": [ { "docs": [ + { + "id": "customLastUpdate", + "path": "/docs/customLastUpdate", + "sidebar": undefined, + }, { "id": "doc with space", "path": "/docs/doc with space", @@ -302,6 +310,16 @@ exports[`simple website content 5`] = ` "path": "/docs/ipsum", "sidebar": undefined, }, + { + "id": "lastUpdateAuthorOnly", + "path": "/docs/lastUpdateAuthorOnly", + "sidebar": undefined, + }, + { + "id": "lastUpdateDateOnly", + "path": "/docs/lastUpdateDateOnly", + "sidebar": undefined, + }, { "id": "lorem", "path": "/docs/lorem", @@ -390,6 +408,26 @@ exports[`simple website content: data 1`] = ` "permalink": "/docs/rootAbsoluteSlug" } } +}", + "site-docs-custom-last-update-md-b8d.json": "{ + "unversionedId": "customLastUpdate", + "id": "customLastUpdate", + "title": "Custom Last Update", + "description": "Custom last update", + "source": "@site/docs/customLastUpdate.md", + "sourceDirName": ".", + "slug": "/customLastUpdate", + "permalink": "/docs/customLastUpdate", + "draft": false, + "tags": [], + "version": "current", + "frontMatter": { + "title": "Custom Last Update", + "last_update": { + "author": "Custom Author", + "date": "1/1/2000" + } + } }", "site-docs-doc-draft-md-584.json": "{ "unversionedId": "doc-draft", @@ -563,6 +601,44 @@ exports[`simple website content: data 1`] = ` "frontMatter": { "custom_edit_url": null } +}", + "site-docs-last-update-author-only-md-352.json": "{ + "unversionedId": "lastUpdateAuthorOnly", + "id": "lastUpdateAuthorOnly", + "title": "Last Update Author Only", + "description": "Only custom author, so it will still use the date from Git", + "source": "@site/docs/lastUpdateAuthorOnly.md", + "sourceDirName": ".", + "slug": "/lastUpdateAuthorOnly", + "permalink": "/docs/lastUpdateAuthorOnly", + "draft": false, + "tags": [], + "version": "current", + "frontMatter": { + "title": "Last Update Author Only", + "last_update": { + "author": "Custom Author" + } + } +}", + "site-docs-last-update-date-only-md-987.json": "{ + "unversionedId": "lastUpdateDateOnly", + "id": "lastUpdateDateOnly", + "title": "Last Update Date Only", + "description": "Only custom date, so it will still use the author from Git", + "source": "@site/docs/lastUpdateDateOnly.md", + "sourceDirName": ".", + "slug": "/lastUpdateDateOnly", + "permalink": "/docs/lastUpdateDateOnly", + "draft": false, + "tags": [], + "version": "current", + "frontMatter": { + "title": "Last Update Date Only", + "last_update": { + "date": "1/1/2000" + } + } }", "site-docs-lorem-md-b27.json": "{ "unversionedId": "lorem", @@ -924,6 +1000,11 @@ exports[`simple website content: data 1`] = ` ] }, "docs": { + "customLastUpdate": { + "id": "customLastUpdate", + "title": "Custom Last Update", + "description": "Custom last update" + }, "doc with space": { "id": "doc with space", "title": "Hoo hoo, if this path tricks you...", @@ -963,6 +1044,16 @@ exports[`simple website content: data 1`] = ` "title": "ipsum", "description": "Lorem ipsum." }, + "lastUpdateAuthorOnly": { + "id": "lastUpdateAuthorOnly", + "title": "Last Update Author Only", + "description": "Only custom author, so it will still use the date from Git" + }, + "lastUpdateDateOnly": { + "id": "lastUpdateDateOnly", + "title": "Last Update Date Only", + "description": "Only custom date, so it will still use the author from Git" + }, "lorem": { "id": "lorem", "title": "lorem", @@ -1026,6 +1117,11 @@ exports[`simple website content: global data 1`] = ` "versions": [ { "docs": [ + { + "id": "customLastUpdate", + "path": "/docs/customLastUpdate", + "sidebar": undefined, + }, { "id": "doc with space", "path": "/docs/doc with space", @@ -1061,6 +1157,16 @@ exports[`simple website content: global data 1`] = ` "path": "/docs/ipsum", "sidebar": undefined, }, + { + "id": "lastUpdateAuthorOnly", + "path": "/docs/lastUpdateAuthorOnly", + "sidebar": undefined, + }, + { + "id": "lastUpdateDateOnly", + "path": "/docs/lastUpdateDateOnly", + "sidebar": undefined, + }, { "id": "lorem", "path": "/docs/lorem", @@ -1202,6 +1308,14 @@ exports[`simple website content: route config 1`] = ` "path": "/docs/category/slugs", "sidebar": "docs", }, + { + "component": "@theme/DocItem", + "exact": true, + "modules": { + "content": "@site/docs/customLastUpdate.md", + }, + "path": "/docs/customLastUpdate", + }, { "component": "@theme/DocItem", "exact": true, @@ -1262,6 +1376,22 @@ exports[`simple website content: route config 1`] = ` }, "path": "/docs/ipsum", }, + { + "component": "@theme/DocItem", + "exact": true, + "modules": { + "content": "@site/docs/lastUpdateAuthorOnly.md", + }, + "path": "/docs/lastUpdateAuthorOnly", + }, + { + "component": "@theme/DocItem", + "exact": true, + "modules": { + "content": "@site/docs/lastUpdateDateOnly.md", + }, + "path": "/docs/lastUpdateDateOnly", + }, { "component": "@theme/DocItem", "exact": true, diff --git a/packages/docusaurus-plugin-content-docs/src/__tests__/__snapshots__/translations.test.ts.snap b/packages/docusaurus-plugin-content-docs/src/__tests__/__snapshots__/translations.test.ts.snap index 4098aeb59399..bd51f4568621 100644 --- a/packages/docusaurus-plugin-content-docs/src/__tests__/__snapshots__/translations.test.ts.snap +++ b/packages/docusaurus-plugin-content-docs/src/__tests__/__snapshots__/translations.test.ts.snap @@ -16,10 +16,18 @@ exports[`getLoadedContentTranslationFiles returns translation files 1`] = ` "description": "The generated-index page title for category Getting started in sidebar docs", "message": "Getting started index title", }, + "sidebar.docs.doc.Second doc translatable": { + "description": "The label for the doc item Second doc translatable in sidebar docs, linking to the doc doc2", + "message": "Second doc translatable", + }, "sidebar.docs.link.Link label": { "description": "The label for link Link label in sidebar docs, linking to https://facebook.com", "message": "Link label", }, + "sidebar.otherSidebar.doc.Fifth doc translatable": { + "description": "The label for the doc item Fifth doc translatable in sidebar otherSidebar, linking to the doc doc5", + "message": "Fifth doc translatable", + }, "version.label": { "description": "The label for version current", "message": "current label", @@ -41,10 +49,18 @@ exports[`getLoadedContentTranslationFiles returns translation files 1`] = ` "description": "The generated-index page title for category Getting started in sidebar docs", "message": "Getting started index title", }, + "sidebar.docs.doc.Second doc translatable": { + "description": "The label for the doc item Second doc translatable in sidebar docs, linking to the doc doc2", + "message": "Second doc translatable", + }, "sidebar.docs.link.Link label": { "description": "The label for link Link label in sidebar docs, linking to https://facebook.com", "message": "Link label", }, + "sidebar.otherSidebar.doc.Fifth doc translatable": { + "description": "The label for the doc item Fifth doc translatable in sidebar otherSidebar, linking to the doc doc5", + "message": "Fifth doc translatable", + }, "version.label": { "description": "The label for version 2.0.0", "message": "2.0.0 label", @@ -66,10 +82,18 @@ exports[`getLoadedContentTranslationFiles returns translation files 1`] = ` "description": "The generated-index page title for category Getting started in sidebar docs", "message": "Getting started index title", }, + "sidebar.docs.doc.Second doc translatable": { + "description": "The label for the doc item Second doc translatable in sidebar docs, linking to the doc doc2", + "message": "Second doc translatable", + }, "sidebar.docs.link.Link label": { "description": "The label for link Link label in sidebar docs, linking to https://facebook.com", "message": "Link label", }, + "sidebar.otherSidebar.doc.Fifth doc translatable": { + "description": "The label for the doc item Fifth doc translatable in sidebar otherSidebar, linking to the doc doc5", + "message": "Fifth doc translatable", + }, "version.label": { "description": "The label for version 1.0.0", "message": "1.0.0 label", @@ -214,6 +238,8 @@ exports[`translateLoadedContent returns translated loaded content 1`] = ` }, { "id": "doc2", + "label": "Second doc translatable (translated)", + "translatable": true, "type": "doc", }, { @@ -248,7 +274,9 @@ exports[`translateLoadedContent returns translated loaded content 1`] = ` }, { "id": "doc5", - "type": "doc", + "label": "Fifth doc translatable (translated)", + "translatable": true, + "type": "ref", }, ], }, @@ -386,6 +414,8 @@ exports[`translateLoadedContent returns translated loaded content 1`] = ` }, { "id": "doc2", + "label": "Second doc translatable (translated)", + "translatable": true, "type": "doc", }, { @@ -420,7 +450,9 @@ exports[`translateLoadedContent returns translated loaded content 1`] = ` }, { "id": "doc5", - "type": "doc", + "label": "Fifth doc translatable (translated)", + "translatable": true, + "type": "ref", }, ], }, @@ -558,6 +590,8 @@ exports[`translateLoadedContent returns translated loaded content 1`] = ` }, { "id": "doc2", + "label": "Second doc translatable (translated)", + "translatable": true, "type": "doc", }, { @@ -592,7 +626,9 @@ exports[`translateLoadedContent returns translated loaded content 1`] = ` }, { "id": "doc5", - "type": "doc", + "label": "Fifth doc translatable (translated)", + "translatable": true, + "type": "ref", }, ], }, 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 194ce3c4e46e..643642b76163 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 9a338c5bf9d2..88b74733f7ce 100644 --- a/packages/docusaurus-plugin-content-docs/src/__tests__/docs.test.ts +++ b/packages/docusaurus-plugin-content-docs/src/__tests__/docs.test.ts @@ -57,7 +57,6 @@ ${markdown} return { source, content, - lastUpdate: {}, contentPath: 'docs', filePath: source, }; @@ -79,7 +78,7 @@ function createTestUtils({ env = 'production', }: TestUtilsArg) { async function readDoc(docFileSource: string) { - return readDocFile(versionMetadata, docFileSource, options); + return readDocFile(versionMetadata, docFileSource); } async function processDocFile(docFileArg: DocFile | string) { const docFile: DocFile = @@ -119,7 +118,7 @@ function createTestUtils({ async function testSlug(docFileSource: string, expectedPermalink: string) { const docFile = await readDoc(docFileSource); - const metadata = processDocMetadata({ + const metadata = await processDocMetadata({ docFile, versionMetadata, context, @@ -137,14 +136,16 @@ function createTestUtils({ }[]; sidebars: Sidebars; }> { - const rawDocs = docFiles.map((docFile) => - processDocMetadata({ - docFile, - versionMetadata, - context, - options, - env: 'production', - }), + const rawDocs = await Promise.all( + docFiles.map(async (docFile) => + processDocMetadata({ + docFile, + versionMetadata, + context, + options, + env: 'production', + }), + ), ); const sidebars = await loadSidebars(versionMetadata.sidebarFilePath, { sidebarItemsGenerator: ({defaultSidebarItemsGenerator, ...args}) => @@ -230,6 +231,9 @@ describe('simple site', () => { 'headingAsTitle.md', 'doc with space.md', 'doc-draft.md', + 'customLastUpdate.md', + 'lastUpdateAuthorOnly.md', + 'lastUpdateDateOnly.md', 'foo/bar.md', 'foo/baz.md', 'slugs/absoluteSlug.md', @@ -481,6 +485,164 @@ describe('simple site', () => { }); }); + it('docs with last_update front matter', async () => { + const {siteDir, context, options, currentVersion, createTestUtilsPartial} = + await loadSite({ + options: { + showLastUpdateAuthor: true, + showLastUpdateTime: true, + }, + }); + + const testUtilsLocal = createTestUtilsPartial({ + siteDir, + context, + options, + versionMetadata: currentVersion, + }); + + await testUtilsLocal.testMeta('customLastUpdate.md', { + version: 'current', + id: 'customLastUpdate', + unversionedId: 'customLastUpdate', + sourceDirName: '.', + permalink: '/docs/customLastUpdate', + slug: '/customLastUpdate', + title: 'Custom Last Update', + description: 'Custom last update', + frontMatter: { + last_update: { + author: 'Custom Author', + date: '1/1/2000', + }, + title: 'Custom Last Update', + }, + lastUpdatedAt: new Date('1/1/2000').getTime() / 1000, + formattedLastUpdatedAt: '1/1/2000', + lastUpdatedBy: 'Custom Author', + sidebarPosition: undefined, + tags: [], + }); + }); + + it('docs with only last_update author front matter', async () => { + const {siteDir, context, options, currentVersion, createTestUtilsPartial} = + await loadSite({ + options: { + showLastUpdateAuthor: true, + showLastUpdateTime: true, + }, + }); + + const testUtilsLocal = createTestUtilsPartial({ + siteDir, + context, + options, + versionMetadata: currentVersion, + }); + + await testUtilsLocal.testMeta('lastUpdateAuthorOnly.md', { + version: 'current', + id: 'lastUpdateAuthorOnly', + unversionedId: 'lastUpdateAuthorOnly', + sourceDirName: '.', + permalink: '/docs/lastUpdateAuthorOnly', + slug: '/lastUpdateAuthorOnly', + title: 'Last Update Author Only', + description: 'Only custom author, so it will still use the date from Git', + frontMatter: { + last_update: { + author: 'Custom Author', + }, + title: 'Last Update Author Only', + }, + lastUpdatedAt: 1539502055, + formattedLastUpdatedAt: '10/14/2018', + lastUpdatedBy: 'Custom Author', + sidebarPosition: undefined, + tags: [], + }); + }); + + it('docs with only last_update date front matter', async () => { + const {siteDir, context, options, currentVersion, createTestUtilsPartial} = + await loadSite({ + options: { + showLastUpdateAuthor: true, + showLastUpdateTime: true, + }, + }); + + const testUtilsLocal = createTestUtilsPartial({ + siteDir, + context, + options, + versionMetadata: currentVersion, + }); + + await testUtilsLocal.testMeta('lastUpdateDateOnly.md', { + version: 'current', + id: 'lastUpdateDateOnly', + unversionedId: 'lastUpdateDateOnly', + sourceDirName: '.', + permalink: '/docs/lastUpdateDateOnly', + slug: '/lastUpdateDateOnly', + title: 'Last Update Date Only', + description: 'Only custom date, so it will still use the author from Git', + frontMatter: { + last_update: { + date: '1/1/2000', + }, + title: 'Last Update Date Only', + }, + lastUpdatedAt: new Date('1/1/2000').getTime() / 1000, + formattedLastUpdatedAt: '1/1/2000', + lastUpdatedBy: 'Author', + sidebarPosition: undefined, + tags: [], + }); + }); + + it('docs with last_update front matter disabled', async () => { + const {siteDir, context, options, currentVersion, createTestUtilsPartial} = + await loadSite({ + options: { + showLastUpdateAuthor: false, + showLastUpdateTime: false, + }, + }); + + const testUtilsLocal = createTestUtilsPartial({ + siteDir, + context, + options, + versionMetadata: currentVersion, + }); + + await testUtilsLocal.testMeta('customLastUpdate.md', { + version: 'current', + id: 'customLastUpdate', + unversionedId: 'customLastUpdate', + sourceDirName: '.', + permalink: '/docs/customLastUpdate', + slug: '/customLastUpdate', + title: 'Custom Last Update', + description: 'Custom last update', + frontMatter: { + last_update: { + author: 'Custom Author', + date: '1/1/2000', + }, + title: 'Custom Last Update', + }, + lastUpdatedAt: undefined, + formattedLastUpdatedAt: undefined, + lastUpdatedBy: undefined, + sidebarPosition: undefined, + tags: [], + }); + }); + it('docs with slugs', async () => { const {defaultTestUtils} = await loadSite(); 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 81eedbf13b9a..55da1682c725 100644 --- a/packages/docusaurus-plugin-content-docs/src/__tests__/frontMatter.test.ts +++ b/packages/docusaurus-plugin-content-docs/src/__tests__/frontMatter.test.ts @@ -396,3 +396,52 @@ describe('validateDocFrontMatter draft', () => { ], }); }); + +describe('validateDocFrontMatter last_update', () => { + testField({ + prefix: 'last_update', + validFrontMatters: [ + {last_update: undefined}, + {last_update: {author: 'test author', date: undefined}}, + {last_update: {author: undefined, date: '1/1/2000'}}, + {last_update: {author: undefined, date: new Date('1/1/2000')}}, + {last_update: {author: 'test author', date: '1/1/2000'}}, + {last_update: {author: 'test author', date: '1995-12-17T03:24:00'}}, + {last_update: {author: undefined, date: 'December 17, 1995 03:24:00'}}, + ], + invalidFrontMatters: [ + [ + {last_update: null}, + 'does not look like a valid front matter FileChange object. Please use a FileChange object (with an author and/or date).', + ], + [ + {last_update: {}}, + 'does not look like a valid front matter FileChange object. Please use a FileChange object (with an author and/or date).', + ], + [ + {last_update: ''}, + 'does not look like a valid front matter FileChange object. Please use a FileChange object (with an author and/or date).', + ], + [ + {last_update: {invalid: 'key'}}, + 'does not look like a valid front matter FileChange object. Please use a FileChange object (with an author and/or date).', + ], + [ + {last_update: {author: 'test author', date: 'I am not a date :('}}, + 'must be a valid date', + ], + [ + {last_update: {author: 'test author', date: '2011-10-45'}}, + 'must be a valid date', + ], + [ + {last_update: {author: 'test author', date: '2011-0-10'}}, + 'must be a valid date', + ], + [ + {last_update: {author: 'test author', date: ''}}, + 'must be a valid date', + ], + ], + }); +}); 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 47aff760539e..53f2827f2dc7 100644 --- a/packages/docusaurus-plugin-content-docs/src/__tests__/lastUpdate.test.ts +++ b/packages/docusaurus-plugin-content-docs/src/__tests__/lastUpdate.test.ts @@ -22,7 +22,7 @@ describe('getFileLastUpdate', () => { const lastUpdateData = await getFileLastUpdate(existingFilePath); expect(lastUpdateData).not.toBeNull(); - const {author, timestamp} = lastUpdateData; + const {author, timestamp} = lastUpdateData!; expect(author).not.toBeNull(); expect(typeof author).toBe('string'); @@ -38,7 +38,7 @@ describe('getFileLastUpdate', () => { const lastUpdateData = await getFileLastUpdate(filePathWithSpace); expect(lastUpdateData).not.toBeNull(); - const {author, timestamp} = lastUpdateData; + const {author, timestamp} = lastUpdateData!; expect(author).not.toBeNull(); expect(typeof author).toBe('string'); @@ -61,8 +61,6 @@ describe('getFileLastUpdate', () => { expect(consoleMock).toHaveBeenLastCalledWith( expect.stringMatching(/because the file does not exist./), ); - await expect(getFileLastUpdate(null)).resolves.toBeNull(); - await expect(getFileLastUpdate(undefined)).resolves.toBeNull(); consoleMock.mockRestore(); }); 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 534eb3712000..69ce0b9a597e 100644 --- a/packages/docusaurus-plugin-content-docs/src/__tests__/options.test.ts +++ b/packages/docusaurus-plugin-content-docs/src/__tests__/options.test.ts @@ -63,7 +63,7 @@ describe('normalizeDocsPluginOptions', () => { breadcrumbs: true, showLastUpdateTime: true, showLastUpdateAuthor: true, - admonitions: {}, + admonitions: false, includeCurrentVersion: false, disableVersioning: true, editCurrentVersion: true, @@ -84,7 +84,6 @@ describe('normalizeDocsPluginOptions', () => { expect(testValidate(userOptions)).toEqual({ ...defaultOptions, ...userOptions, - remarkPlugins: [...userOptions.remarkPlugins!, expect.any(Array)], }); }); @@ -102,7 +101,6 @@ describe('normalizeDocsPluginOptions', () => { expect(testValidate(userOptions)).toEqual({ ...defaultOptions, ...userOptions, - remarkPlugins: [...userOptions.remarkPlugins!, expect.any(Array)], }); }); @@ -116,14 +114,14 @@ describe('normalizeDocsPluginOptions', () => { }); }); - it('rejects admonitions true', () => { - const admonitionsTrue: Options = { - admonitions: true, - }; + it('rejects admonitions array', () => { expect(() => - testValidate(admonitionsTrue), + testValidate({ + // @ts-expect-error: rejected value + admonitions: [], + }), ).toThrowErrorMatchingInlineSnapshot( - `""admonitions" contains an invalid value"`, + `""admonitions" does not look like a valid admonitions config"`, ); }); 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 fb099e8eb63d..4c5392e28301 100644 --- a/packages/docusaurus-plugin-content-docs/src/__tests__/translations.test.ts +++ b/packages/docusaurus-plugin-content-docs/src/__tests__/translations.test.ts @@ -86,6 +86,8 @@ function createSampleVersion( { type: 'doc', id: 'doc2', + label: 'Second doc translatable', + translatable: true, }, { type: 'link', @@ -109,8 +111,10 @@ function createSampleVersion( id: 'doc4', }, { - type: 'doc', + type: 'ref', id: 'doc5', + label: 'Fifth doc translatable', + translatable: true, }, ], }, diff --git a/packages/docusaurus-plugin-content-docs/src/cli.ts b/packages/docusaurus-plugin-content-docs/src/cli.ts index 65e4984affa0..23cd26e7e461 100644 --- a/packages/docusaurus-plugin-content-docs/src/cli.ts +++ b/packages/docusaurus-plugin-content-docs/src/cli.ts @@ -85,13 +85,17 @@ export async function cliDocsVersionCommand( await Promise.all( i18n.locales.map(async (locale) => { + const localizationDir = path.resolve( + siteDir, + i18n.path, + i18n.localeConfigs[locale]!.path, + ); // Copy docs files. const docsDir = locale === i18n.defaultLocale ? path.resolve(siteDir, docsPath) : getDocsDirPathLocalized({ - siteDir, - locale, + localizationDir, pluginId, versionName: CURRENT_VERSION_NAME, }); @@ -114,8 +118,7 @@ export async function cliDocsVersionCommand( locale === i18n.defaultLocale ? getVersionDocsDirPath(siteDir, pluginId, version) : getDocsDirPathLocalized({ - siteDir, - locale, + localizationDir, pluginId, versionName: version, }); diff --git a/packages/docusaurus-plugin-content-docs/src/client/index.ts b/packages/docusaurus-plugin-content-docs/src/client/index.ts index bfc2bfd78cb0..bf475ee00e9d 100644 --- a/packages/docusaurus-plugin-content-docs/src/client/index.ts +++ b/packages/docusaurus-plugin-content-docs/src/client/index.ts @@ -18,15 +18,60 @@ import { getActiveDocContext, getDocVersionSuggestions, } from './docsClientUtils'; -import type { - GlobalPluginData, - GlobalVersion, - ActivePlugin, - ActiveDocContext, - DocVersionSuggestions, -} from '@docusaurus/plugin-content-docs/client'; import type {UseDataOptions} from '@docusaurus/types'; +export type ActivePlugin = { + pluginId: string; + pluginData: GlobalPluginData; +}; +export type ActiveDocContext = { + activeVersion?: GlobalVersion; + activeDoc?: GlobalDoc; + alternateDocVersions: {[versionName: string]: GlobalDoc}; +}; +export type GlobalDoc = { + /** + * For generated index pages, this is the `slug`, **not** `permalink` + * (without base URL). Because slugs have leading slashes but IDs don't, + * there won't be clashes. + */ + id: string; + path: string; + sidebar: string | undefined; +}; + +export type GlobalVersion = { + name: string; + label: string; + isLast: boolean; + path: string; + /** The doc with `slug: /`, or first doc in first sidebar */ + mainDocId: string; + docs: GlobalDoc[]; + /** Unversioned IDs. In development, this list is empty. */ + draftIds: string[]; + sidebars?: {[sidebarId: string]: GlobalSidebar}; +}; + +export type GlobalSidebar = { + link?: { + label: string; + path: string; + }; + // ... we may add other things here later +}; +export type GlobalPluginData = { + path: string; + versions: GlobalVersion[]; + breadcrumbs: boolean; +}; +export type DocVersionSuggestions = { + /** Suggest the latest version */ + latestVersionSuggestion: GlobalVersion; + /** Suggest the same doc, in latest version (if one exists) */ + latestDocSuggestion?: GlobalDoc; +}; + // Important to use a constant object to avoid React useEffect executions etc. // see https://github.com/facebook/docusaurus/issues/5089 const StableEmptyObject = {}; @@ -71,6 +116,7 @@ export function useActivePluginAndVersion( }; } +/** Versions are returned ordered (most recent first). */ export function useVersions(pluginId: string | undefined): GlobalVersion[] { const data = useDocsData(pluginId); return data.versions; @@ -81,6 +127,10 @@ export function useLatestVersion(pluginId: string | undefined): GlobalVersion { return getLatestVersion(data); } +/** + * Returns `undefined` on doc-unrelated pages, because there's no version + * currently considered as active. + */ export function useActiveVersion( pluginId: string | undefined, ): GlobalVersion | undefined { @@ -96,7 +146,9 @@ export function useActiveDocContext( const {pathname} = useLocation(); return getActiveDocContext(data, pathname); } - +/** + * Useful to say "hey, you are not on the latest docs version, please switch" + */ export function useDocVersionSuggestions( pluginId: string | undefined, ): DocVersionSuggestions { diff --git a/packages/docusaurus-plugin-content-docs/src/deps.d.ts b/packages/docusaurus-plugin-content-docs/src/deps.d.ts deleted file mode 100644 index 6b8b33906b54..000000000000 --- a/packages/docusaurus-plugin-content-docs/src/deps.d.ts +++ /dev/null @@ -1,13 +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. - */ - -declare module 'remark-admonitions' { - type Options = {[key: string]: unknown}; - - const plugin: (options?: Options) => void; - export = plugin; -} diff --git a/packages/docusaurus-plugin-content-docs/src/docs.ts b/packages/docusaurus-plugin-content-docs/src/docs.ts index 2ea127f99fbb..580d90101740 100644 --- a/packages/docusaurus-plugin-content-docs/src/docs.ts +++ b/packages/docusaurus-plugin-content-docs/src/docs.ts @@ -37,6 +37,7 @@ import type { VersionMetadata, DocFrontMatter, LoadedVersion, + FileChange, } from '@docusaurus/plugin-content-docs'; import type {LoadContext} from '@docusaurus/types'; import type {SidebarsUtils} from './sidebars/utils'; @@ -50,9 +51,21 @@ type LastUpdateOptions = Pick< async function readLastUpdateData( filePath: string, options: LastUpdateOptions, + lastUpdateFrontMatter: FileChange | undefined, ): Promise { const {showLastUpdateAuthor, showLastUpdateTime} = options; if (showLastUpdateAuthor || showLastUpdateTime) { + const frontMatterTimestamp = lastUpdateFrontMatter?.date + ? new Date(lastUpdateFrontMatter.date).getTime() / 1000 + : undefined; + + if (lastUpdateFrontMatter?.author && lastUpdateFrontMatter.date) { + return { + lastUpdatedAt: frontMatterTimestamp, + lastUpdatedBy: lastUpdateFrontMatter.author, + }; + } + // Use fake data in dev for faster development. const fileLastUpdateData = process.env.NODE_ENV === 'production' @@ -61,14 +74,16 @@ async function readLastUpdateData( author: 'Author', timestamp: 1539502055, }; - - if (fileLastUpdateData) { - const {author, timestamp} = fileLastUpdateData; - return { - lastUpdatedAt: showLastUpdateTime ? timestamp : undefined, - lastUpdatedBy: showLastUpdateAuthor ? author : undefined, - }; - } + const {author, timestamp} = fileLastUpdateData ?? {}; + + return { + lastUpdatedBy: showLastUpdateAuthor + ? lastUpdateFrontMatter?.author ?? author + : undefined, + lastUpdatedAt: showLastUpdateTime + ? frontMatterTimestamp ?? timestamp + : undefined, + }; } return {}; @@ -80,7 +95,6 @@ export async function readDocFile( 'contentPath' | 'contentPathLocalized' >, source: string, - options: LastUpdateOptions, ): Promise { const contentPath = await getFolderContainingFile( getContentPathList(versionMetadata), @@ -89,11 +103,8 @@ export async function readDocFile( const filePath = path.join(contentPath, source); - const [content, lastUpdate] = await Promise.all([ - fs.readFile(filePath, 'utf-8'), - readLastUpdateData(filePath, options), - ]); - return {source, content, lastUpdate, contentPath, filePath}; + const content = await fs.readFile(filePath, 'utf-8'); + return {source, content, contentPath, filePath}; } export async function readVersionDocs( @@ -108,7 +119,7 @@ export async function readVersionDocs( ignore: options.exclude, }); return Promise.all( - sources.map((source) => readDocFile(versionMetadata, source, options)), + sources.map((source) => readDocFile(versionMetadata, source)), ); } @@ -125,7 +136,7 @@ function isDraftForEnvironment({ return (env === 'production' && frontMatter.draft) ?? false; } -function doProcessDocMetadata({ +async function doProcessDocMetadata({ docFile, versionMetadata, context, @@ -137,8 +148,8 @@ function doProcessDocMetadata({ context: LoadContext; options: MetadataOptions; env: DocEnv; -}): DocMetadataBase { - const {source, content, lastUpdate, contentPath, filePath} = docFile; +}): Promise { + const {source, content, contentPath, filePath} = docFile; const {siteDir, i18n} = context; const { @@ -155,8 +166,15 @@ function doProcessDocMetadata({ // (01-MyFolder/01-MyDoc.md => MyFolder/MyDoc) // but allow to disable this behavior with front matter parse_number_prefixes: parseNumberPrefixes = true, + last_update: lastUpdateFrontMatter, } = frontMatter; + const lastUpdate = await readLastUpdateData( + filePath, + options, + lastUpdateFrontMatter, + ); + // E.g. api/plugins/myDoc -> myDoc; myDoc -> myDoc const sourceFileNameWithoutExtension = path.basename( source, @@ -287,7 +305,7 @@ export function processDocMetadata(args: { context: LoadContext; options: MetadataOptions; env: DocEnv; -}): DocMetadataBase { +}): Promise { try { return doProcessDocMetadata(args); } catch (err) { diff --git a/packages/docusaurus-plugin-content-docs/src/frontMatter.ts b/packages/docusaurus-plugin-content-docs/src/frontMatter.ts index de944a6b1716..9d210a831b25 100644 --- a/packages/docusaurus-plugin-content-docs/src/frontMatter.ts +++ b/packages/docusaurus-plugin-content-docs/src/frontMatter.ts @@ -14,6 +14,9 @@ import { } from '@docusaurus/utils-validation'; import type {DocFrontMatter} from '@docusaurus/plugin-content-docs'; +const FrontMatterLastUpdateErrorMessage = + '{{#label}} does not look like a valid front matter FileChange object. Please use a FileChange object (with an author and/or date).'; + // NOTE: we don't add any default value on purpose here // We don't want default values to magically appear in doc metadata and props // While the user did not provide those values explicitly @@ -42,6 +45,15 @@ const DocFrontMatterSchema = Joi.object({ pagination_prev: Joi.string().allow(null), draft: Joi.boolean(), ...FrontMatterTOCHeadingLevels, + last_update: Joi.object({ + author: Joi.string(), + date: Joi.date().raw(), + }) + .or('author', 'date') + .messages({ + 'object.missing': FrontMatterLastUpdateErrorMessage, + 'object.base': FrontMatterLastUpdateErrorMessage, + }), }).unknown(); export function validateDocFrontMatter(frontMatter: { diff --git a/packages/docusaurus-plugin-content-docs/src/index.ts b/packages/docusaurus-plugin-content-docs/src/index.ts index a8557542430f..c9ce6d8decd0 100644 --- a/packages/docusaurus-plugin-content-docs/src/index.ts +++ b/packages/docusaurus-plugin-content-docs/src/index.ts @@ -352,6 +352,7 @@ export default async function pluginContentDocs( { loader: require.resolve('@docusaurus/mdx-loader'), options: { + admonitions: options.admonitions, remarkPlugins, rehypePlugins, beforeDefaultRehypePlugins, diff --git a/packages/docusaurus-plugin-content-docs/src/lastUpdate.ts b/packages/docusaurus-plugin-content-docs/src/lastUpdate.ts index a0eb4d775997..110dff5ab7a1 100644 --- a/packages/docusaurus-plugin-content-docs/src/lastUpdate.ts +++ b/packages/docusaurus-plugin-content-docs/src/lastUpdate.ts @@ -16,7 +16,7 @@ let showedGitRequirementError = false; let showedFileNotTrackedError = false; export async function getFileLastUpdate( - filePath?: string, + filePath: string, ): Promise<{timestamp: number; author: string} | null> { if (!filePath) { return null; diff --git a/packages/docusaurus-plugin-content-docs/src/options.ts b/packages/docusaurus-plugin-content-docs/src/options.ts index bd1cd5d70732..f81479baff7a 100644 --- a/packages/docusaurus-plugin-content-docs/src/options.ts +++ b/packages/docusaurus-plugin-content-docs/src/options.ts @@ -14,7 +14,6 @@ import { URISchema, } from '@docusaurus/utils-validation'; import {GlobExcludeDefault} from '@docusaurus/utils'; -import admonitions from 'remark-admonitions'; import {DefaultSidebarItemsGenerator} from './sidebars/generator'; import { DefaultNumberPrefixParser, @@ -42,7 +41,7 @@ export const DEFAULT_OPTIONS: Omit = { beforeDefaultRehypePlugins: [], showLastUpdateTime: false, showLastUpdateAuthor: false, - admonitions: {}, + admonitions: true, includeCurrentVersion: true, disableVersioning: false, lastVersion: undefined, @@ -123,9 +122,7 @@ const OptionsSchema = Joi.object({ beforeDefaultRehypePlugins: RehypePluginsSchema.default( DEFAULT_OPTIONS.beforeDefaultRehypePlugins, ), - admonitions: Joi.alternatives() - .try(AdmonitionsSchema, Joi.boolean().invalid(true)) - .default(DEFAULT_OPTIONS.admonitions), + admonitions: AdmonitionsSchema.default(DEFAULT_OPTIONS.admonitions), showLastUpdateTime: Joi.bool().default(DEFAULT_OPTIONS.showLastUpdateTime), showLastUpdateAuthor: Joi.bool().default( DEFAULT_OPTIONS.showLastUpdateAuthor, @@ -167,11 +164,5 @@ export function validateOptions({ const normalizedOptions = validate(OptionsSchema, options); - if (normalizedOptions.admonitions) { - normalizedOptions.remarkPlugins = normalizedOptions.remarkPlugins.concat([ - [admonitions, normalizedOptions.admonitions], - ]); - } - return normalizedOptions; } 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 1d7be06b74dc..8622b55543ac 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 @@ -23,6 +23,14 @@ declare module '@docusaurus/plugin-content-docs' { image?: string; }; + export type FileChange = { + author?: string; + /** Date can be any + * [parsable date string](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Date/parse). + */ + date?: Date | string; + }; + /** * Custom callback for parsing number prefixes from file/folder names. */ @@ -198,7 +206,6 @@ declare module '@docusaurus/plugin-content-docs' { docTagsListComponent: string; /** Root component of the generated category index page. */ docCategoryGeneratedIndexComponent: string; - admonitions: {[key: string]: unknown}; sidebarItemsGenerator: import('./sidebars/types').SidebarItemsGeneratorOption; /** * URL route for the tags section of your doc version. Will be appended to @@ -371,6 +378,8 @@ declare module '@docusaurus/plugin-content-docs' { pagination_prev?: string | null; /** Should this doc be excluded from production builds? */ draft?: boolean; + /** Allows overriding the last updated author and/or date. */ + last_update?: FileChange; }; export type LastUpdateData = { @@ -607,89 +616,3 @@ declare module '@theme/DocPage' { export default function DocPage(props: Props): JSX.Element; } - -// TODO TS only supports reading `exports` in 4.7. We will need to merge the -// type defs (and JSDoc) here with the implementation after that -declare module '@docusaurus/plugin-content-docs/client' { - import type {UseDataOptions} from '@docusaurus/types'; - - export type ActivePlugin = { - pluginId: string; - pluginData: GlobalPluginData; - }; - export type ActiveDocContext = { - activeVersion?: GlobalVersion; - activeDoc?: GlobalDoc; - alternateDocVersions: {[versionName: string]: GlobalDoc}; - }; - export type GlobalDoc = { - /** - * For generated index pages, this is the `slug`, **not** `permalink` - * (without base URL). Because slugs have leading slashes but IDs don't, - * there won't be clashes. - */ - id: string; - path: string; - sidebar: string | undefined; - }; - - export type GlobalVersion = { - name: string; - label: string; - isLast: boolean; - path: string; - /** The doc with `slug: /`, or first doc in first sidebar */ - mainDocId: string; - docs: GlobalDoc[]; - /** Unversioned IDs. In development, this list is empty. */ - draftIds: string[]; - sidebars?: {[sidebarId: string]: GlobalSidebar}; - }; - - export type GlobalSidebar = { - link?: { - label: string; - path: string; - }; - // ... we may add other things here later - }; - export type GlobalPluginData = { - path: string; - versions: GlobalVersion[]; - breadcrumbs: boolean; - }; - export type DocVersionSuggestions = { - /** Suggest the latest version */ - latestVersionSuggestion: GlobalVersion; - /** Suggest the same doc, in latest version (if one exists) */ - latestDocSuggestion?: GlobalDoc; - }; - - export const useAllDocsData: () => {[pluginId: string]: GlobalPluginData}; - export const useDocsData: (pluginId?: string) => GlobalPluginData; - export const useActivePlugin: ( - options?: UseDataOptions, - ) => ActivePlugin | undefined; - export const useActivePluginAndVersion: ( - options?: UseDataOptions, - ) => - | {activePlugin: ActivePlugin; activeVersion: GlobalVersion | undefined} - | undefined; - /** Versions are returned ordered (most recent first). */ - export const useVersions: (pluginId?: string) => GlobalVersion[]; - export const useLatestVersion: (pluginId?: string) => GlobalVersion; - /** - * Returns `undefined` on doc-unrelated pages, because there's no version - * currently considered as active. - */ - export const useActiveVersion: ( - pluginId?: string, - ) => GlobalVersion | undefined; - export const useActiveDocContext: (pluginId?: string) => ActiveDocContext; - /** - * Useful to say "hey, you are not on the latest docs version, please switch" - */ - export const useDocVersionSuggestions: ( - pluginId?: string, - ) => DocVersionSuggestions; -} diff --git a/packages/docusaurus-plugin-content-docs/src/props.ts b/packages/docusaurus-plugin-content-docs/src/props.ts index 7d27cebaa9b4..d279e13f1f4c 100644 --- a/packages/docusaurus-plugin-content-docs/src/props.ts +++ b/packages/docusaurus-plugin-content-docs/src/props.ts @@ -73,10 +73,28 @@ Available document ids are: } } + function getCategoryLinkCustomProps( + link: SidebarItemCategoryLink | undefined, + ) { + switch (link?.type) { + case 'doc': + return getDocById(link.id).frontMatter.sidebar_custom_props; + default: + return undefined; + } + } + function convertCategory(item: SidebarItemCategory): PropSidebarItemCategory { const {link, ...rest} = item; const href = getCategoryLinkHref(link); - return {...rest, items: item.items.map(normalizeItem), ...(href && {href})}; + const customProps = item.customProps ?? getCategoryLinkCustomProps(link); + + return { + ...rest, + items: item.items.map(normalizeItem), + ...(href && {href}), + ...(customProps && {customProps}), + }; } function normalizeItem(item: SidebarItem): PropSidebarItem { diff --git a/packages/docusaurus-plugin-content-docs/src/sidebars/__tests__/__snapshots__/normalization.test.ts.snap b/packages/docusaurus-plugin-content-docs/src/sidebars/__tests__/__snapshots__/normalization.test.ts.snap index f847163c3050..f2c320506640 100644 --- a/packages/docusaurus-plugin-content-docs/src/sidebars/__tests__/__snapshots__/normalization.test.ts.snap +++ b/packages/docusaurus-plugin-content-docs/src/sidebars/__tests__/__snapshots__/normalization.test.ts.snap @@ -1,5 +1,52 @@ // Jest Snapshot v1, https://goo.gl/fbAQLP +exports[`normalization adds a translatable marker for labels defined in sidebars.js 1`] = ` +{ + "sidebar": [ + { + "id": "google", + "label": "Google", + "translatable": true, + "type": "doc", + }, + { + "items": [ + { + "id": "doc1", + "type": "doc", + }, + { + "id": "doc2", + "type": "doc", + }, + ], + "label": "Category 1", + "type": "category", + }, + { + "items": [ + { + "id": "doc3", + "type": "doc", + }, + { + "id": "doc4", + "type": "doc", + }, + { + "id": "msft", + "label": "Microsoft", + "translatable": true, + "type": "ref", + }, + ], + "label": "Category 2", + "type": "category", + }, + ], +} +`; + exports[`normalization normalizes shorthands 1`] = ` { "sidebar": [ diff --git a/packages/docusaurus-plugin-content-docs/src/sidebars/__tests__/normalization.test.ts b/packages/docusaurus-plugin-content-docs/src/sidebars/__tests__/normalization.test.ts index f7f9ad2ee2e8..6ab358ad30b6 100644 --- a/packages/docusaurus-plugin-content-docs/src/sidebars/__tests__/normalization.test.ts +++ b/packages/docusaurus-plugin-content-docs/src/sidebars/__tests__/normalization.test.ts @@ -91,4 +91,30 @@ describe('normalization', () => { `"Invalid sidebar items collection \`"item"\` in sidebar sidebar: it must either be an array of sidebar items or a shorthand notation (which doesn't contain a \`type\` property). See https://docusaurus.io/docs/sidebar/items for all valid syntaxes."`, ); }); + + it('adds a translatable marker for labels defined in sidebars.js', () => { + expect( + normalizeSidebars({ + sidebar: [ + { + type: 'doc', + id: 'google', + label: 'Google', + }, + { + 'Category 1': ['doc1', 'doc2'], + 'Category 2': [ + 'doc3', + 'doc4', + { + type: 'ref', + id: 'msft', + label: 'Microsoft', + }, + ], + }, + ], + }), + ).toMatchSnapshot(); + }); }); diff --git a/packages/docusaurus-plugin-content-docs/src/sidebars/normalization.ts b/packages/docusaurus-plugin-content-docs/src/sidebars/normalization.ts index 4d51e254443e..dad0f7c86c1c 100644 --- a/packages/docusaurus-plugin-content-docs/src/sidebars/normalization.ts +++ b/packages/docusaurus-plugin-content-docs/src/sidebars/normalization.ts @@ -44,6 +44,12 @@ export function normalizeItem( // This will never throw anyways return normalizeSidebar(item, 'sidebar items slice'); } + if ( + (item.type === 'doc' || item.type === 'ref') && + typeof item.label === 'string' + ) { + return [{...item, translatable: true}]; + } if (item.type === 'category') { const normalizedCategory: NormalizedSidebarItemCategory = { ...item, diff --git a/packages/docusaurus-plugin-content-docs/src/sidebars/types.ts b/packages/docusaurus-plugin-content-docs/src/sidebars/types.ts index 8d038f417537..1a8746574a5e 100644 --- a/packages/docusaurus-plugin-content-docs/src/sidebars/types.ts +++ b/packages/docusaurus-plugin-content-docs/src/sidebars/types.ts @@ -27,6 +27,11 @@ export type SidebarItemDoc = SidebarItemBase & { type: 'doc' | 'ref'; label?: string; id: string; + /** + * This is an internal marker. Items with labels defined in the config needs + * to be translated with JSON + */ + translatable?: true; }; export type SidebarItemHtml = SidebarItemBase & { @@ -94,7 +99,7 @@ export type SidebarCategoriesShorthand = { }; export type SidebarItemConfig = - | SidebarItemDoc + | Omit | SidebarItemHtml | SidebarItemLink | SidebarItemAutogenerated diff --git a/packages/docusaurus-plugin-content-docs/src/sidebars/utils.ts b/packages/docusaurus-plugin-content-docs/src/sidebars/utils.ts index 0c743f42d537..1ac140cd627b 100644 --- a/packages/docusaurus-plugin-content-docs/src/sidebars/utils.ts +++ b/packages/docusaurus-plugin-content-docs/src/sidebars/utils.ts @@ -81,6 +81,9 @@ export function collectSidebarCategories( export function collectSidebarLinks(sidebar: Sidebar): SidebarItemLink[] { return collectSidebarItemsOfType('link', sidebar); } +export function collectSidebarRefs(sidebar: Sidebar): SidebarItemDoc[] { + return collectSidebarItemsOfType('ref', sidebar); +} // /!\ docId order matters for navigation! export function collectSidebarDocIds(sidebar: Sidebar): string[] { diff --git a/packages/docusaurus-plugin-content-docs/src/sidebars/validation.ts b/packages/docusaurus-plugin-content-docs/src/sidebars/validation.ts index b9b1bfae007e..f1cc5a168e3c 100644 --- a/packages/docusaurus-plugin-content-docs/src/sidebars/validation.ts +++ b/packages/docusaurus-plugin-content-docs/src/sidebars/validation.ts @@ -47,6 +47,7 @@ const sidebarItemDocSchema = sidebarItemBaseSchema.append({ type: Joi.string().valid('doc', 'ref').required(), id: Joi.string().required(), label: Joi.string(), + translatable: Joi.boolean(), }); const sidebarItemHtmlSchema = sidebarItemBaseSchema.append({ diff --git a/packages/docusaurus-plugin-content-docs/src/translations.ts b/packages/docusaurus-plugin-content-docs/src/translations.ts index abc56ac65b93..e0d824cd9c75 100644 --- a/packages/docusaurus-plugin-content-docs/src/translations.ts +++ b/packages/docusaurus-plugin-content-docs/src/translations.ts @@ -12,6 +12,8 @@ import { collectSidebarCategories, transformSidebarItems, collectSidebarLinks, + collectSidebarDocItems, + collectSidebarRefs, } from './sidebars/utils'; import type { LoadedVersion, @@ -111,7 +113,22 @@ function getSidebarTranslationFileContent( ]), ); - return mergeTranslations([categoryContent, linksContent]); + const docs = collectSidebarDocItems(sidebar) + .concat(collectSidebarRefs(sidebar)) + .filter((item) => item.translatable); + const docLinksContent: TranslationFileContent = Object.fromEntries( + docs.map((doc) => [ + `sidebar.${sidebarName}.doc.${doc.label!}`, + { + message: doc.label!, + description: `The label for the doc item ${doc.label!} in sidebar ${sidebarName}, linking to the doc ${ + doc.id + }`, + }, + ]), + ); + + return mergeTranslations([categoryContent, linksContent, docLinksContent]); } function translateSidebar({ @@ -166,6 +183,14 @@ function translateSidebar({ ?.message ?? item.label, }; } + if ((item.type === 'doc' || item.type === 'ref') && item.translatable) { + return { + ...item, + label: + sidebarsTranslations[`sidebar.${sidebarName}.doc.${item.label!}`] + ?.message ?? item.label, + }; + } return item; }); } diff --git a/packages/docusaurus-plugin-content-docs/src/types.ts b/packages/docusaurus-plugin-content-docs/src/types.ts index cb4506b20d1a..4c4568517fbb 100644 --- a/packages/docusaurus-plugin-content-docs/src/types.ts +++ b/packages/docusaurus-plugin-content-docs/src/types.ts @@ -8,7 +8,6 @@ import type {BrokenMarkdownLink, Tag} from '@docusaurus/utils'; import type { VersionMetadata, - LastUpdateData, LoadedVersion, CategoryGeneratedIndexMetadata, } from '@docusaurus/plugin-content-docs'; @@ -19,7 +18,6 @@ export type DocFile = { filePath: string; // /!\ may be localized source: string; content: string; - lastUpdate: LastUpdateData; }; export type SourceToPermalink = { 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 15bb3d06d720..a52ba1b7d186 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 @@ -17,6 +17,7 @@ import type { } from '@docusaurus/plugin-content-docs'; const DefaultI18N: I18n = { + path: 'i18n', currentLocale: 'en', locales: ['en'], defaultLocale: 'en', @@ -37,6 +38,7 @@ describe('readVersionsMetadata', () => { siteDir: simpleSiteDir, baseUrl: '/', i18n: DefaultI18N, + localizationDir: path.join(simpleSiteDir, 'i18n/en'), } as LoadContext; const vCurrent: VersionMetadata = { @@ -198,6 +200,7 @@ describe('readVersionsMetadata', () => { siteDir: versionedSiteDir, baseUrl: '/', i18n: DefaultI18N, + localizationDir: path.join(versionedSiteDir, 'i18n/en'), } as LoadContext; const vCurrent: VersionMetadata = { @@ -636,6 +639,7 @@ describe('readVersionsMetadata', () => { siteDir: versionedSiteDir, baseUrl: '/', i18n: DefaultI18N, + localizationDir: path.join(versionedSiteDir, 'i18n/en'), } as LoadContext; const vCurrent: VersionMetadata = { diff --git a/packages/docusaurus-plugin-content-docs/src/versions/files.ts b/packages/docusaurus-plugin-content-docs/src/versions/files.ts index 04c97efaebaa..2f045717c29e 100644 --- a/packages/docusaurus-plugin-content-docs/src/versions/files.ts +++ b/packages/docusaurus-plugin-content-docs/src/versions/files.ts @@ -55,19 +55,16 @@ export function getVersionSidebarsPath( } export function getDocsDirPathLocalized({ - siteDir, - locale, + localizationDir, pluginId, versionName, }: { - siteDir: string; - locale: string; + localizationDir: string; pluginId: string; versionName: string; }): string { return getPluginI18nPath({ - siteDir, - locale, + localizationDir, pluginName: 'docusaurus-plugin-content-docs', pluginId, subPaths: [ @@ -175,8 +172,7 @@ export async function getVersionMetadataPaths({ > { const isCurrent = versionName === CURRENT_VERSION_NAME; const contentPathLocalized = getDocsDirPathLocalized({ - siteDir: context.siteDir, - locale: context.i18n.currentLocale, + localizationDir: context.localizationDir, pluginId: options.id, versionName, }); diff --git a/packages/docusaurus-plugin-content-docs/src/versions/index.ts b/packages/docusaurus-plugin-content-docs/src/versions/index.ts index 369e0fd6efc2..d39bee56198d 100644 --- a/packages/docusaurus-plugin-content-docs/src/versions/index.ts +++ b/packages/docusaurus-plugin-content-docs/src/versions/index.ts @@ -49,8 +49,7 @@ function getVersionEditUrls({ const editDirPath = options.editCurrentVersion ? options.path : contentPath; const editDirPathLocalized = options.editCurrentVersion ? getDocsDirPathLocalized({ - siteDir: context.siteDir, - locale: context.i18n.currentLocale, + localizationDir: context.localizationDir, versionName: CURRENT_VERSION_NAME, pluginId: options.id, }) diff --git a/packages/docusaurus-plugin-content-docs/tsconfig.json b/packages/docusaurus-plugin-content-docs/tsconfig.json index 48e200409e4e..3936df64b7e4 100644 --- a/packages/docusaurus-plugin-content-docs/tsconfig.json +++ b/packages/docusaurus-plugin-content-docs/tsconfig.json @@ -5,7 +5,6 @@ "noEmit": false, "incremental": true, "tsBuildInfoFile": "./lib/.tsbuildinfo", - "module": "commonjs", "rootDir": "src", "outDir": "lib" }, diff --git a/packages/docusaurus-plugin-content-pages/package.json b/packages/docusaurus-plugin-content-pages/package.json index c9167e386d3a..1222fe058539 100644 --- a/packages/docusaurus-plugin-content-pages/package.json +++ b/packages/docusaurus-plugin-content-pages/package.json @@ -24,9 +24,8 @@ "@docusaurus/utils": "2.0.0-beta.21", "@docusaurus/utils-validation": "2.0.0-beta.21", "fs-extra": "^10.1.0", - "remark-admonitions": "^1.2.1", "tslib": "^2.4.0", - "webpack": "^5.72.1" + "webpack": "^5.73.0" }, "devDependencies": { "@docusaurus/types": "2.0.0-beta.21" diff --git a/packages/docusaurus-plugin-content-pages/src/__tests__/__fixtures__/website/i18n/fr/docusaurus-plugin-content-pages/hello/translatedMd.md b/packages/docusaurus-plugin-content-pages/src/__tests__/__fixtures__/website/i18n/fr/docusaurus-plugin-content-pages/hello/translatedMd.md index 51a19b7d482d..23291b31bb37 100644 --- a/packages/docusaurus-plugin-content-pages/src/__tests__/__fixtures__/website/i18n/fr/docusaurus-plugin-content-pages/hello/translatedMd.md +++ b/packages/docusaurus-plugin-content-pages/src/__tests__/__fixtures__/website/i18n/fr/docusaurus-plugin-content-pages/hello/translatedMd.md @@ -1 +1 @@ -translated markdown page (fr) +translated Markdown page (fr) diff --git a/packages/docusaurus-plugin-content-pages/src/__tests__/__fixtures__/website/src/pages/hello/mdxPage.mdx b/packages/docusaurus-plugin-content-pages/src/__tests__/__fixtures__/website/src/pages/hello/mdxPage.mdx index 54ce38beb5ce..27b0b9f9bea7 100644 --- a/packages/docusaurus-plugin-content-pages/src/__tests__/__fixtures__/website/src/pages/hello/mdxPage.mdx +++ b/packages/docusaurus-plugin-content-pages/src/__tests__/__fixtures__/website/src/pages/hello/mdxPage.mdx @@ -1,5 +1,5 @@ --- -title: mdx page -description: my mdx page +title: MDX page +description: my MDX page --- MDX page diff --git a/packages/docusaurus-plugin-content-pages/src/__tests__/__fixtures__/website/src/pages/hello/translatedMd.md b/packages/docusaurus-plugin-content-pages/src/__tests__/__fixtures__/website/src/pages/hello/translatedMd.md index d39c88c732e2..9e232d95ab2f 100644 --- a/packages/docusaurus-plugin-content-pages/src/__tests__/__fixtures__/website/src/pages/hello/translatedMd.md +++ b/packages/docusaurus-plugin-content-pages/src/__tests__/__fixtures__/website/src/pages/hello/translatedMd.md @@ -1 +1 @@ -translated markdown page +translated Markdown page diff --git a/packages/docusaurus-plugin-content-pages/src/__tests__/__snapshots__/index.test.ts.snap b/packages/docusaurus-plugin-content-pages/src/__tests__/__snapshots__/index.test.ts.snap index 818f94da35f5..c4c22e849260 100644 --- a/packages/docusaurus-plugin-content-pages/src/__tests__/__snapshots__/index.test.ts.snap +++ b/packages/docusaurus-plugin-content-pages/src/__tests__/__snapshots__/index.test.ts.snap @@ -21,14 +21,14 @@ exports[`docusaurus-plugin-content-pages loads simple pages 1`] = ` "type": "mdx", }, { - "description": "my mdx page", + "description": "my MDX page", "frontMatter": { - "description": "my mdx page", - "title": "mdx page", + "description": "my MDX page", + "title": "MDX page", }, "permalink": "/hello/mdxPage", "source": "@site/src/pages/hello/mdxPage.mdx", - "title": "mdx page", + "title": "MDX page", "type": "mdx", }, { @@ -37,7 +37,7 @@ exports[`docusaurus-plugin-content-pages loads simple pages 1`] = ` "type": "jsx", }, { - "description": "translated markdown page", + "description": "translated Markdown page", "frontMatter": {}, "permalink": "/hello/translatedMd", "source": "@site/src/pages/hello/translatedMd.md", @@ -55,49 +55,49 @@ exports[`docusaurus-plugin-content-pages loads simple pages 1`] = ` exports[`docusaurus-plugin-content-pages loads simple pages with french translations 1`] = ` [ { - "permalink": "/", + "permalink": "/fr/", "source": "@site/src/pages/index.js", "type": "jsx", }, { - "permalink": "/typescript", + "permalink": "/fr/typescript", "source": "@site/src/pages/typescript.tsx", "type": "jsx", }, { "description": "Markdown index page", "frontMatter": {}, - "permalink": "/hello/", + "permalink": "/fr/hello/", "source": "@site/src/pages/hello/index.md", "title": "Index", "type": "mdx", }, { - "description": "my mdx page", + "description": "my MDX page", "frontMatter": { - "description": "my mdx page", - "title": "mdx page", + "description": "my MDX page", + "title": "MDX page", }, - "permalink": "/hello/mdxPage", + "permalink": "/fr/hello/mdxPage", "source": "@site/src/pages/hello/mdxPage.mdx", - "title": "mdx page", + "title": "MDX page", "type": "mdx", }, { - "permalink": "/hello/translatedJs", + "permalink": "/fr/hello/translatedJs", "source": "@site/i18n/fr/docusaurus-plugin-content-pages/hello/translatedJs.js", "type": "jsx", }, { - "description": "translated markdown page (fr)", + "description": "translated Markdown page (fr)", "frontMatter": {}, - "permalink": "/hello/translatedMd", + "permalink": "/fr/hello/translatedMd", "source": "@site/i18n/fr/docusaurus-plugin-content-pages/hello/translatedMd.md", "title": undefined, "type": "mdx", }, { - "permalink": "/hello/world", + "permalink": "/fr/hello/world", "source": "@site/src/pages/hello/world.js", "type": "jsx", }, 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 31706d3a4cd4..dd570260a417 100644 --- a/packages/docusaurus-plugin-content-pages/src/__tests__/index.test.ts +++ b/packages/docusaurus-plugin-content-pages/src/__tests__/index.test.ts @@ -32,15 +32,9 @@ describe('docusaurus-plugin-content-pages', () => { it('loads simple pages with french translations', async () => { const siteDir = path.join(__dirname, '__fixtures__', 'website'); - const context = await loadContext({siteDir}); + const context = await loadContext({siteDir, locale: 'fr'}); const plugin = pluginContentPages( - { - ...context, - i18n: { - ...context.i18n, - currentLocale: 'fr', - }, - }, + context, validateOptions({ validate: normalizePluginOptions, options: { diff --git a/packages/docusaurus-plugin-content-pages/src/deps.d.ts b/packages/docusaurus-plugin-content-pages/src/deps.d.ts deleted file mode 100644 index 6b8b33906b54..000000000000 --- a/packages/docusaurus-plugin-content-pages/src/deps.d.ts +++ /dev/null @@ -1,13 +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. - */ - -declare module 'remark-admonitions' { - type Options = {[key: string]: unknown}; - - const plugin: (options?: Options) => void; - export = plugin; -} diff --git a/packages/docusaurus-plugin-content-pages/src/index.ts b/packages/docusaurus-plugin-content-pages/src/index.ts index a9051e4545e6..bf6b0c73041b 100644 --- a/packages/docusaurus-plugin-content-pages/src/index.ts +++ b/packages/docusaurus-plugin-content-pages/src/index.ts @@ -21,7 +21,6 @@ import { DEFAULT_PLUGIN_ID, parseMarkdownString, } from '@docusaurus/utils'; -import admonitions from 'remark-admonitions'; import {validatePageFrontMatter} from './frontMatter'; import type {LoadContext, Plugin} from '@docusaurus/types'; @@ -43,23 +42,12 @@ export default function pluginContentPages( context: LoadContext, options: PluginOptions, ): Plugin { - if (options.admonitions) { - options.remarkPlugins = options.remarkPlugins.concat([ - [admonitions, options.admonitions], - ]); - } - const { - siteConfig, - siteDir, - generatedFilesDir, - i18n: {currentLocale}, - } = context; + const {siteConfig, siteDir, generatedFilesDir, localizationDir} = context; const contentPaths: PagesContentPaths = { contentPath: path.resolve(siteDir, options.path), contentPathLocalized: getPluginI18nPath({ - siteDir, - locale: currentLocale, + localizationDir, pluginName: 'docusaurus-plugin-content-pages', pluginId: options.id, }), @@ -176,6 +164,7 @@ export default function pluginContentPages( configureWebpack(config, isServer, {getJSLoader}) { const { + admonitions, rehypePlugins, remarkPlugins, beforeDefaultRehypePlugins, @@ -200,6 +189,7 @@ export default function pluginContentPages( { loader: require.resolve('@docusaurus/mdx-loader'), options: { + admonitions, remarkPlugins, rehypePlugins, beforeDefaultRehypePlugins, diff --git a/packages/docusaurus-plugin-content-pages/src/options.ts b/packages/docusaurus-plugin-content-pages/src/options.ts index 2c1f38201c30..cce458f71d45 100644 --- a/packages/docusaurus-plugin-content-pages/src/options.ts +++ b/packages/docusaurus-plugin-content-pages/src/options.ts @@ -25,7 +25,7 @@ export const DEFAULT_OPTIONS: PluginOptions = { rehypePlugins: [], beforeDefaultRehypePlugins: [], beforeDefaultRemarkPlugins: [], - admonitions: {}, + admonitions: true, }; const PluginOptionSchema = Joi.object({ diff --git a/packages/docusaurus-plugin-content-pages/src/plugin-content-pages.d.ts b/packages/docusaurus-plugin-content-pages/src/plugin-content-pages.d.ts index dd754b175940..f60623c7de65 100644 --- a/packages/docusaurus-plugin-content-pages/src/plugin-content-pages.d.ts +++ b/packages/docusaurus-plugin-content-pages/src/plugin-content-pages.d.ts @@ -16,7 +16,6 @@ declare module '@docusaurus/plugin-content-pages' { include: string[]; exclude: string[]; mdxPageComponent: string; - admonitions: {[key: string]: unknown}; }; export type Options = Partial; diff --git a/packages/docusaurus-plugin-content-pages/tsconfig.json b/packages/docusaurus-plugin-content-pages/tsconfig.json index 80e43e9813ef..e16d5c2c5d33 100644 --- a/packages/docusaurus-plugin-content-pages/tsconfig.json +++ b/packages/docusaurus-plugin-content-pages/tsconfig.json @@ -4,7 +4,6 @@ "noEmit": false, "incremental": true, "tsBuildInfoFile": "./lib/.tsbuildinfo", - "module": "commonjs", "rootDir": "src", "outDir": "lib" }, diff --git a/packages/docusaurus-plugin-debug/tsconfig.json b/packages/docusaurus-plugin-debug/tsconfig.json index 7c1bb85ac462..18b9536626ad 100644 --- a/packages/docusaurus-plugin-debug/tsconfig.json +++ b/packages/docusaurus-plugin-debug/tsconfig.json @@ -5,7 +5,6 @@ "noEmit": false, "incremental": true, "tsBuildInfoFile": "./lib/.tsbuildinfo", - "module": "commonjs", "rootDir": "src", "outDir": "lib" }, diff --git a/packages/docusaurus-plugin-google-analytics/src/analytics.ts b/packages/docusaurus-plugin-google-analytics/src/analytics.ts index 82e957701c3a..b127d3c43c81 100644 --- a/packages/docusaurus-plugin-google-analytics/src/analytics.ts +++ b/packages/docusaurus-plugin-google-analytics/src/analytics.ts @@ -9,10 +9,19 @@ import type {ClientModule} from '@docusaurus/types'; const clientModule: ClientModule = { onRouteDidUpdate({location, previousLocation}) { - if (previousLocation && location.pathname !== previousLocation.pathname) { + if ( + previousLocation && + (location.pathname !== previousLocation.pathname || + location.search !== previousLocation.search || + location.hash !== previousLocation.hash) + ) { // Set page so that subsequent hits on this page are attributed // to this page. This is recommended for Single-page Applications. - window.ga('set', 'page', location.pathname); + window.ga( + 'set', + 'page', + location.pathname + location.search + location.hash, + ); // Always refer to the variable on window in-case it gets // overridden elsewhere. window.ga('send', 'pageview'); diff --git a/packages/docusaurus-plugin-google-analytics/tsconfig.json b/packages/docusaurus-plugin-google-analytics/tsconfig.json index 77a4365aedfe..c7fda37effc4 100644 --- a/packages/docusaurus-plugin-google-analytics/tsconfig.json +++ b/packages/docusaurus-plugin-google-analytics/tsconfig.json @@ -5,7 +5,6 @@ "noEmit": false, "incremental": true, "tsBuildInfoFile": "./lib/.tsbuildinfo", - "module": "commonjs", "rootDir": "src", "outDir": "lib" }, diff --git a/packages/docusaurus-plugin-google-gtag/src/gtag.ts b/packages/docusaurus-plugin-google-gtag/src/gtag.ts index 2122511126a8..4092fa8f0fcd 100644 --- a/packages/docusaurus-plugin-google-gtag/src/gtag.ts +++ b/packages/docusaurus-plugin-google-gtag/src/gtag.ts @@ -5,16 +5,16 @@ * LICENSE file in the root directory of this source tree. */ -import globalData from '@generated/globalData'; -import type {PluginOptions} from './options'; import type {ClientModule} from '@docusaurus/types'; -const {trackingID} = globalData['docusaurus-plugin-google-gtag']! - .default as PluginOptions; - const clientModule: ClientModule = { onRouteDidUpdate({location, previousLocation}) { - if (previousLocation && location.pathname !== previousLocation.pathname) { + if ( + previousLocation && + (location.pathname !== previousLocation.pathname || + location.search !== previousLocation.search || + location.hash !== previousLocation.hash) + ) { // Normally, the document title is updated in the next tick due to how // `react-helmet-async` updates it. We want to send the current document's // title to gtag instead of the old one's, so we use `setTimeout` to defer @@ -23,14 +23,10 @@ const clientModule: ClientModule = { setTimeout(() => { // Always refer to the variable on window in case it gets overridden // elsewhere. - window.gtag('config', trackingID, { - page_path: location.pathname, - page_title: document.title, - }); window.gtag('event', 'page_view', { page_title: document.title, page_location: window.location.href, - page_path: location.pathname, + page_path: location.pathname + location.search + location.hash, }); }); } diff --git a/packages/docusaurus-plugin-google-gtag/tsconfig.json b/packages/docusaurus-plugin-google-gtag/tsconfig.json index 1b3271a718e6..fe656511f355 100644 --- a/packages/docusaurus-plugin-google-gtag/tsconfig.json +++ b/packages/docusaurus-plugin-google-gtag/tsconfig.json @@ -5,7 +5,6 @@ "noEmit": false, "incremental": true, "tsBuildInfoFile": "./lib/.tsbuildinfo", - "module": "commonjs", "rootDir": "src", "outDir": "lib" }, diff --git a/packages/docusaurus-plugin-ideal-image/package.json b/packages/docusaurus-plugin-ideal-image/package.json index cf79146b19ee..2e234aa7a0bc 100644 --- a/packages/docusaurus-plugin-ideal-image/package.json +++ b/packages/docusaurus-plugin-ideal-image/package.json @@ -27,10 +27,10 @@ "@docusaurus/types": "2.0.0-beta.21", "@docusaurus/utils-validation": "2.0.0-beta.21", "@endiliey/react-ideal-image": "^0.0.11", - "react-waypoint": "^10.1.0", - "sharp": "^0.30.5", + "react-waypoint": "^10.3.0", + "sharp": "^0.30.6", "tslib": "^2.4.0", - "webpack": "^5.72.1" + "webpack": "^5.73.0" }, "devDependencies": { "@docusaurus/module-type-aliases": "2.0.0-beta.21", diff --git a/packages/docusaurus-plugin-ideal-image/tsconfig.json b/packages/docusaurus-plugin-ideal-image/tsconfig.json index 7c1bb85ac462..18b9536626ad 100644 --- a/packages/docusaurus-plugin-ideal-image/tsconfig.json +++ b/packages/docusaurus-plugin-ideal-image/tsconfig.json @@ -5,7 +5,6 @@ "noEmit": false, "incremental": true, "tsBuildInfoFile": "./lib/.tsbuildinfo", - "module": "commonjs", "rootDir": "src", "outDir": "lib" }, diff --git a/packages/docusaurus-plugin-pwa/package.json b/packages/docusaurus-plugin-pwa/package.json index 9048db7d4d0a..b8f08f74f011 100644 --- a/packages/docusaurus-plugin-pwa/package.json +++ b/packages/docusaurus-plugin-pwa/package.json @@ -30,10 +30,10 @@ "@docusaurus/utils-validation": "2.0.0-beta.21", "babel-loader": "^8.2.5", "clsx": "^1.1.1", - "core-js": "^3.22.7", - "terser-webpack-plugin": "^5.3.1", + "core-js": "^3.22.8", + "terser-webpack-plugin": "^5.3.3", "tslib": "^2.4.0", - "webpack": "^5.72.1", + "webpack": "^5.73.0", "webpack-merge": "^5.8.0", "workbox-build": "^6.5.3", "workbox-precaching": "^6.5.3", diff --git a/packages/docusaurus-plugin-pwa/src/deps.d.ts b/packages/docusaurus-plugin-pwa/src/deps.d.ts new file mode 100644 index 000000000000..104a45712162 --- /dev/null +++ b/packages/docusaurus-plugin-pwa/src/deps.d.ts @@ -0,0 +1,15 @@ +/** + * 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. + */ + +// TODO incompatible declaration file: https://github.com/unjs/webpackbar/pull/108 +declare module 'webpackbar' { + import webpack from 'webpack'; + + export default class WebpackBarPlugin extends webpack.ProgressPlugin { + constructor(options: {name: string; color?: string}); + } +} diff --git a/packages/docusaurus-plugin-pwa/src/registerSw.ts b/packages/docusaurus-plugin-pwa/src/registerSw.ts index 7ccb4a56a233..1c834d3be843 100644 --- a/packages/docusaurus-plugin-pwa/src/registerSw.ts +++ b/packages/docusaurus-plugin-pwa/src/registerSw.ts @@ -5,6 +5,7 @@ * LICENSE file in the root directory of this source tree. */ +import ExecutionEnvironment from '@docusaurus/ExecutionEnvironment'; import {createStorageSlot} from '@docusaurus/theme-common'; // First: read the env variables (provided by Webpack) @@ -15,40 +16,42 @@ const PWA_OFFLINE_MODE_ACTIVATION_STRATEGIES = process.env const PWA_DEBUG = process.env.PWA_DEBUG; /* eslint-enable prefer-destructuring */ -const debug = PWA_DEBUG; // Shortcut - -const MAX_MOBILE_WIDTH = 940; +const MAX_MOBILE_WIDTH = 996; const AppInstalledEventFiredStorage = createStorageSlot( 'docusaurus.pwa.event.appInstalled.fired', ); +declare global { + interface Navigator { + getInstalledRelatedApps: () => Promise<{platform: string}[]>; + connection?: {effectiveType: string; saveData: boolean}; + } +} + +function debugLog(msg: string, obj?: unknown) { + if (PWA_DEBUG) { + if (typeof obj === 'undefined') { + console.log(`[Docusaurus-PWA][registerSw]: ${msg}`); + } else { + console.log(`[Docusaurus-PWA][registerSw]: ${msg}`, obj); + } + } +} + async function clearRegistrations() { const registrations = await navigator.serviceWorker.getRegistrations(); - if (debug) { - console.log( - `[Docusaurus-PWA][registerSw]: will unregister all service worker registrations`, - registrations, - ); - } + debugLog('will unregister all service workers', {registrations}); await Promise.all( - registrations.map(async (registration) => { - const result = await registration.unregister(); - if (debug) { - console.log( - `[Docusaurus-PWA][registerSw]: unregister() service worker registration`, - registrations, - result, - ); - } - }), + registrations.map((registration) => + registration + .unregister() + .then((result) => + debugLog('unregister service worker', {registration, result}), + ), + ), ); - if (debug) { - console.log( - `[Docusaurus-PWA][registerSw]: unregistered all service worker registrations`, - registrations, - ); - } + debugLog('unregistered all service workers', {registrations}); window.location.reload(); } @@ -61,23 +64,16 @@ https://stackoverflow.com/questions/51735869/check-if-user-has-already-installed - getInstalledRelatedApps() is only supported in recent Chrome and does not seem to reliable either https://github.com/WICG/get-installed-related-apps - display-mode: standalone is not exactly the same concept, but looks like a decent fallback https://petelepage.com/blog/2019/07/is-my-pwa-installed/ */ -async function isAppInstalledEventFired() { +function getIsAppInstalledEventFired() { return AppInstalledEventFiredStorage.get() === 'true'; } -declare global { - interface Navigator { - getInstalledRelatedApps: () => Promise<{platform: string}[]>; - connection?: {effectiveType: string; saveData: boolean}; - } -} - -async function isAppInstalledRelatedApps() { - if ('getInstalledRelatedApps' in window.navigator) { - const relatedApps = await navigator.getInstalledRelatedApps(); - return relatedApps.some((app) => app.platform === 'webapp'); +async function getIsAppInstalledRelatedApps() { + if (!('getInstalledRelatedApps' in window.navigator)) { + return false; } - return false; + const relatedApps = await navigator.getInstalledRelatedApps(); + return relatedApps.some((app) => app.platform === 'webapp'); } function isStandaloneDisplayMode() { return window.matchMedia('(display-mode: standalone)').matches; @@ -87,52 +83,36 @@ const OfflineModeActivationStrategiesImplementations = { always: () => true, mobile: () => window.innerWidth <= MAX_MOBILE_WIDTH, saveData: () => !!navigator.connection?.saveData, - appInstalled: async () => { - const installedEventFired = await isAppInstalledEventFired(); - const installedRelatedApps = await isAppInstalledRelatedApps(); - return installedEventFired || installedRelatedApps; - }, + appInstalled: () => + getIsAppInstalledEventFired() || getIsAppInstalledRelatedApps(), standalone: () => isStandaloneDisplayMode(), queryString: () => new URLSearchParams(window.location.search).get('offlineMode') === 'true', }; -async function isStrategyActive( - strategyName: keyof typeof OfflineModeActivationStrategiesImplementations, -) { - return OfflineModeActivationStrategiesImplementations[strategyName](); -} - async function getActiveStrategies() { const activeStrategies = await Promise.all( - PWA_OFFLINE_MODE_ACTIVATION_STRATEGIES.map(async (strategyName) => { - const isActive = await isStrategyActive(strategyName); - return isActive ? strategyName : undefined; - }), + PWA_OFFLINE_MODE_ACTIVATION_STRATEGIES.map((strategyName) => + Promise.resolve( + OfflineModeActivationStrategiesImplementations[strategyName](), + ).then((isActive) => (isActive ? strategyName : undefined)), + ), ); return activeStrategies.filter(Boolean); } -async function isOfflineModeEnabled() { +async function getIsOfflineModeEnabled() { const activeStrategies = await getActiveStrategies(); const enabled = activeStrategies.length > 0; - if (debug) { - const logObject = { + debugLog( + enabled + ? 'offline mode enabled, because of activation strategies' + : 'offline mode disabled, because none of the offlineModeActivationStrategies could be used', + { activeStrategies, availableStrategies: PWA_OFFLINE_MODE_ACTIVATION_STRATEGIES, - }; - if (enabled) { - console.log( - '[Docusaurus-PWA][registerSw]: offline mode enabled, because of activation strategies', - logObject, - ); - } else { - console.log( - '[Docusaurus-PWA][registerSw]: offline mode disabled, because none of the offlineModeActivationStrategies could be used', - logObject, - ); - } - } + }, + ); return enabled; } @@ -141,170 +121,111 @@ function createServiceWorkerUrl(params: object) { const url = `${PWA_SERVICE_WORKER_URL}?params=${encodeURIComponent( paramsQueryString, )}`; - if (debug) { - console.log(`[Docusaurus-PWA][registerSw]: service worker url`, { - url, - params, - }); - } + debugLog('service worker url', {url, params}); return url; } async function registerSW() { - const {Workbox} = await import('workbox-window'); - - const offlineMode = await isOfflineModeEnabled(); - - const url = createServiceWorkerUrl({offlineMode, debug}); + const [{Workbox}, offlineMode] = await Promise.all([ + import('workbox-window'), + getIsOfflineModeEnabled(), + ]); + const url = createServiceWorkerUrl({offlineMode, debug: PWA_DEBUG}); const wb = new Workbox(url); - - const registration = await wb.register(); - const sendSkipWaiting = () => wb.messageSW({type: 'SKIP_WAITING'}); - - const handleServiceWorkerWaiting = async () => { - if (debug) { - console.log('[Docusaurus-PWA][registerSw]: handleServiceWorkerWaiting'); - } + const handleServiceWorkerWaiting = () => { + debugLog('handleServiceWorkerWaiting'); // Immediately load new service worker when files aren't cached if (!offlineMode) { - sendSkipWaiting(); - } else { - const renderReloadPopup = (await import('./renderReloadPopup')).default; - await renderReloadPopup({ + return sendSkipWaiting(); + } + return import('./renderReloadPopup.js').then(({renderReloadPopup}) => + renderReloadPopup({ onReload() { wb.addEventListener('controlling', () => { window.location.reload(); }); sendSkipWaiting(); }, - }); - } + }), + ); }; - - if (debug && registration) { - if (registration.active) { - console.log( - '[Docusaurus-PWA][registerSw]: registration.active', - registration, - ); - } - if (registration.installing) { - console.log( - '[Docusaurus-PWA][registerSw]: registration.installing', - registration, - ); - } - if (registration.waiting) { - console.log( - '[Docusaurus-PWA][registerSw]: registration.waiting', - registration, - ); - } - } - // Update the current service worker when the next one has finished // installing and transitions to waiting state. wb.addEventListener('waiting', (event) => { - if (debug) { - console.log('[Docusaurus-PWA][registerSw]: event waiting', event); - } - handleServiceWorkerWaiting(); + debugLog('event waiting', {event}); + void handleServiceWorkerWaiting(); }); - // 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); - } - handleServiceWorkerWaiting(); + debugLog('event externalwaiting', {event}); + void handleServiceWorkerWaiting(); }); - - // 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) { - await handleServiceWorkerWaiting(); + const registration = await wb.register(); + if (registration) { + if (registration.active) { + debugLog('registration.active', {registration}); + } + if (registration.installing) { + debugLog('registration.installing', {registration}); + } + if (registration.waiting) { + debugLog('registration.waiting', {registration}); + // 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. + await handleServiceWorkerWaiting(); + } } } // TODO these events still works in chrome but have been removed from the spec // in 2019! See https://github.com/w3c/manifest/pull/836 function addLegacyAppInstalledEventsListeners() { - if (typeof window !== 'undefined') { - if (debug) { - console.log( - '[Docusaurus-PWA][registerSw]: addLegacyAppInstalledEventsListeners', - ); - } - - window.addEventListener('appinstalled', async (event) => { - if (debug) { - console.log('[Docusaurus-PWA][registerSw]: event appinstalled', event); - } - - AppInstalledEventFiredStorage.set('true'); - if (debug) { - console.log( - "[Docusaurus-PWA][registerSw]: AppInstalledEventFiredStorage.set('true')", - ); - } - - // After the app is installed, we register a service worker with the path - // `/sw?enabled`. Since the previous service worker was `/sw`, it'll be - // treated as a new one. The previous registration will need to be - // cleared, otherwise the reload popup will show. - await clearRegistrations(); - }); - - // TODO this event still works in chrome but has been removed from the spec - // in 2019!!! - window.addEventListener('beforeinstallprompt', async (event) => { - if (debug) { - console.log( - '[Docusaurus-PWA][registerSw]: event beforeinstallprompt', - event, - ); - } - // TODO instead of default browser install UI, show custom docusaurus - // prompt? - // event.preventDefault(); - if (debug) { - console.log( - '[Docusaurus-PWA][registerSw]: AppInstalledEventFiredStorage.get()', - AppInstalledEventFiredStorage.get(), - ); - } - if (AppInstalledEventFiredStorage.get()) { - AppInstalledEventFiredStorage.del(); - if (debug) { - console.log( - '[Docusaurus-PWA][registerSw]: AppInstalledEventFiredStorage.del()', - ); - } - // After uninstalling the app, if the user doesn't clear all data, then - // the previous service worker will continue serving cached files. We - // need to clear registrations and reload, otherwise the popup shows. - await clearRegistrations(); - } - }); + debugLog('addLegacyAppInstalledEventsListeners'); + + window.addEventListener('appinstalled', (event) => { + debugLog('event appinstalled', {event}); + AppInstalledEventFiredStorage.set('true'); + debugLog("AppInstalledEventFiredStorage.set('true')"); + // After the app is installed, we register a service worker with the path + // `/sw?enabled`. Since the previous service worker was `/sw`, it'll be + // treated as a new one. The previous registration will need to be + // cleared, otherwise the reload popup will show. + void clearRegistrations(); + }); - if (debug) { - console.log( - '[Docusaurus-PWA][registerSw]: legacy appinstalled and beforeinstallprompt event listeners installed', - ); + // TODO this event still works in chrome but has been removed from the spec + // in 2019!!! + window.addEventListener('beforeinstallprompt', (event) => { + debugLog('event beforeinstallprompt', {event}); + // TODO instead of default browser install UI, show custom docusaurus + // prompt? + // event.preventDefault(); + const appInstalledEventFired = AppInstalledEventFiredStorage.get(); + debugLog('AppInstalledEventFiredStorage.get()', {appInstalledEventFired}); + if (appInstalledEventFired) { + AppInstalledEventFiredStorage.del(); + debugLog('AppInstalledEventFiredStorage.del()'); + // After uninstalling the app, if the user doesn't clear all data, then + // the previous service worker will continue serving cached files. We + // need to clear registrations and reload, otherwise the popup shows. + void clearRegistrations(); } - } + }); + + debugLog( + 'legacy appinstalled and beforeinstallprompt event listeners installed', + ); } /* Init code to run on the client! */ -if (typeof window !== 'undefined') { - if (debug) { - console.log('[Docusaurus-PWA][registerSw]: debug mode enabled'); - } +if (ExecutionEnvironment.canUseDOM) { + debugLog('debug mode enabled'); if ('serviceWorker' in navigator) { // First: add the listeners asap/synchronously diff --git a/packages/docusaurus-plugin-pwa/src/renderReloadPopup.tsx b/packages/docusaurus-plugin-pwa/src/renderReloadPopup.tsx index 2958a7dee833..89a8cd984890 100644 --- a/packages/docusaurus-plugin-pwa/src/renderReloadPopup.tsx +++ b/packages/docusaurus-plugin-pwa/src/renderReloadPopup.tsx @@ -20,8 +20,9 @@ const createContainer = () => { return container; }; -export default async function renderReloadPopup(props: Props): Promise { +export function renderReloadPopup(props: Props): Promise { const container = getContainer() ?? createContainer(); - const ReloadPopup = (await import('@theme/PwaReloadPopup')).default; - ReactDOM.render(, container); + return import('@theme/PwaReloadPopup').then(({default: ReloadPopup}) => { + ReactDOM.render(, container); + }); } diff --git a/packages/docusaurus-plugin-pwa/tsconfig.json b/packages/docusaurus-plugin-pwa/tsconfig.json index 9da13f25341a..0bef8e601656 100644 --- a/packages/docusaurus-plugin-pwa/tsconfig.json +++ b/packages/docusaurus-plugin-pwa/tsconfig.json @@ -8,7 +8,6 @@ "noEmit": false, "incremental": true, "tsBuildInfoFile": "./lib/.tsbuildinfo", - "module": "commonjs", "rootDir": "src", "outDir": "lib" }, diff --git a/packages/docusaurus-plugin-sitemap/tsconfig.json b/packages/docusaurus-plugin-sitemap/tsconfig.json index 80e43e9813ef..e16d5c2c5d33 100644 --- a/packages/docusaurus-plugin-sitemap/tsconfig.json +++ b/packages/docusaurus-plugin-sitemap/tsconfig.json @@ -4,7 +4,6 @@ "noEmit": false, "incremental": true, "tsBuildInfoFile": "./lib/.tsbuildinfo", - "module": "commonjs", "rootDir": "src", "outDir": "lib" }, diff --git a/packages/docusaurus-preset-classic/tsconfig.json b/packages/docusaurus-preset-classic/tsconfig.json index 80e43e9813ef..e16d5c2c5d33 100644 --- a/packages/docusaurus-preset-classic/tsconfig.json +++ b/packages/docusaurus-preset-classic/tsconfig.json @@ -4,7 +4,6 @@ "noEmit": false, "incremental": true, "tsBuildInfoFile": "./lib/.tsbuildinfo", - "module": "commonjs", "rootDir": "src", "outDir": "lib" }, diff --git a/packages/docusaurus-remark-plugin-npm2yarn/README.md b/packages/docusaurus-remark-plugin-npm2yarn/README.md index 6b2902ade5b0..5fc6a1705e15 100644 --- a/packages/docusaurus-remark-plugin-npm2yarn/README.md +++ b/packages/docusaurus-remark-plugin-npm2yarn/README.md @@ -62,4 +62,4 @@ module.exports = { | Property | Type | Default | Description | | --- | --- | --- | --- | -| `sync` | `boolean` | `false` | Syncing tab choices (yarn and npm). See https://docusaurus.io/docs/markdown-features/#syncing-tab-choices for details. | +| `sync` | `boolean` | `false` | Syncing tab choices (Yarn and npm). See https://docusaurus.io/docs/markdown-features/#syncing-tab-choices for details. | diff --git a/packages/docusaurus-remark-plugin-npm2yarn/tsconfig.json b/packages/docusaurus-remark-plugin-npm2yarn/tsconfig.json index 7807612b51a5..69bd9341b47e 100644 --- a/packages/docusaurus-remark-plugin-npm2yarn/tsconfig.json +++ b/packages/docusaurus-remark-plugin-npm2yarn/tsconfig.json @@ -6,7 +6,6 @@ "tsBuildInfoFile": "./lib/.tsbuildinfo", "sourceMap": true, "declarationMap": true, - "module": "commonjs", "rootDir": "src", "outDir": "lib" }, diff --git a/packages/docusaurus-theme-classic/src/__tests__/validateThemeConfig.test.ts b/packages/docusaurus-theme-classic/src/__tests__/validateThemeConfig.test.ts index 850eeb044255..9c8bb7a79e60 100644 --- a/packages/docusaurus-theme-classic/src/__tests__/validateThemeConfig.test.ts +++ b/packages/docusaurus-theme-classic/src/__tests__/validateThemeConfig.test.ts @@ -102,6 +102,7 @@ describe('themeConfig', () => { alt: 'Facebook Open Source Logo', src: 'img/oss_logo.png', href: 'https://opensource.facebook.com', + target: '_self', }, copyright: `Copyright © ${new Date().getFullYear()} Facebook, Inc. Built with Docusaurus.`, }, diff --git a/packages/docusaurus-theme-classic/src/index.ts b/packages/docusaurus-theme-classic/src/index.ts index b52f14d98b57..d005e7e6e731 100644 --- a/packages/docusaurus-theme-classic/src/index.ts +++ b/packages/docusaurus-theme-classic/src/index.ts @@ -139,7 +139,6 @@ export default function themeClassic( const modules = [ require.resolve(getInfimaCSSFile(direction)), './prism-include-languages', - './admonitions.css', './nprogress', ]; diff --git a/packages/docusaurus-theme-classic/src/theme-classic.d.ts b/packages/docusaurus-theme-classic/src/theme-classic.d.ts index f182ba6470ac..69be740d60ae 100644 --- a/packages/docusaurus-theme-classic/src/theme-classic.d.ts +++ b/packages/docusaurus-theme-classic/src/theme-classic.d.ts @@ -42,7 +42,7 @@ declare module '@theme/Admonition' { readonly children: ReactNode; readonly type: 'note' | 'tip' | 'danger' | 'info' | 'caution'; readonly icon?: ReactNode; - readonly title?: string; + readonly title?: ReactNode; } export default function Admonition(props: Props): JSX.Element; } @@ -675,6 +675,7 @@ declare module '@theme/MDXComponents' { import type MDXDetails from '@theme/MDXComponents/Details'; import type MDXUl from '@theme/MDXComponents/Ul'; import type MDXImg from '@theme/MDXComponents/Img'; + import type Admonition from '@theme/Admonition'; export type MDXComponentsObject = { readonly head: typeof MDXHead; @@ -690,6 +691,7 @@ declare module '@theme/MDXComponents' { readonly h4: (props: ComponentProps<'h4'>) => JSX.Element; readonly h5: (props: ComponentProps<'h5'>) => JSX.Element; readonly h6: (props: ComponentProps<'h6'>) => JSX.Element; + readonly admonition: typeof Admonition; // eslint-disable-next-line @typescript-eslint/no-explicit-any [tagName: string]: ComponentType; }; diff --git a/packages/docusaurus-theme-classic/src/theme/Admonition/index.tsx b/packages/docusaurus-theme-classic/src/theme/Admonition/index.tsx index 045effa48e98..aa64d0461842 100644 --- a/packages/docusaurus-theme-classic/src/theme/Admonition/index.tsx +++ b/packages/docusaurus-theme-classic/src/theme/Admonition/index.tsx @@ -5,102 +5,205 @@ * LICENSE file in the root directory of this source tree. */ -import React from 'react'; +import React, {type ReactNode} from 'react'; import clsx from 'clsx'; +import {ThemeClassNames} from '@docusaurus/theme-common'; +import Translate from '@docusaurus/Translate'; import type {Props} from '@theme/Admonition'; -const icons = { - note: ( - +import styles from './styles.module.css'; + +function NoteIcon() { + return ( + - ), - tip: ( - + ); +} + +function TipIcon() { + return ( + - ), - danger: ( - + ); +} + +function DangerIcon() { + return ( + - ), - info: ( - + ); +} + +function InfoIcon() { + return ( + - ), - caution: ( - + ); +} + +function CautionIcon() { + return ( + - ), + ); +} + +type AdmonitionConfig = { + iconComponent: React.ComponentType; + infimaClassName: string; + label: ReactNode; }; -const ifmClassNames = { - note: 'secondary', - tip: 'success', - danger: 'danger', - info: 'info', - caution: 'warning', +// eslint-disable-next-line @typescript-eslint/consistent-indexed-object-style +const AdmonitionConfigs: Record = { + note: { + infimaClassName: 'secondary', + iconComponent: NoteIcon, + label: ( + + note + + ), + }, + tip: { + infimaClassName: 'success', + iconComponent: TipIcon, + label: ( + + tip + + ), + }, + danger: { + infimaClassName: 'danger', + iconComponent: DangerIcon, + label: ( + + danger + + ), + }, + info: { + infimaClassName: 'info', + iconComponent: InfoIcon, + label: ( + + info + + ), + }, + caution: { + infimaClassName: 'warning', + iconComponent: CautionIcon, + label: ( + + caution + + ), + }, }; -export default function Admonition({ - children, - type, - title = type, - icon = icons[type], -}: Props): JSX.Element { +// Legacy aliases, undocumented but kept for retro-compatibility +const aliases = { + secondary: 'note', + important: 'info', + success: 'tip', + warning: 'danger', +} as const; + +function getAdmonitionConfig(unsafeType: string): AdmonitionConfig { + const type = + (aliases as {[key: string]: Props['type']})[unsafeType] ?? unsafeType; + const config = (AdmonitionConfigs as {[key: string]: AdmonitionConfig})[type]; + if (config) { + return config; + } + console.warn( + `No admonition config found for admonition type "${type}". Using Info as fallback.`, + ); + return AdmonitionConfigs.info; +} + +// Workaround because it's difficult in MDX v1 to provide a MDX title as props +// See https://github.com/facebook/docusaurus/pull/7152#issuecomment-1145779682 +function extractMDXAdmonitionTitle(children: ReactNode): { + mdxAdmonitionTitle: ReactNode | undefined; + rest: ReactNode; +} { + const items = React.Children.toArray(children); + const mdxAdmonitionTitle = items.find( + (item) => + React.isValidElement(item) && + (item.props as {mdxType: string} | null)?.mdxType === + 'mdxAdmonitionTitle', + ); + const rest = <>{items.filter((item) => item !== mdxAdmonitionTitle)}; + return { + mdxAdmonitionTitle, + rest, + }; +} + +function processAdmonitionProps(props: Props): Props { + const {mdxAdmonitionTitle, rest} = extractMDXAdmonitionTitle(props.children); + return { + ...props, + title: props.title ?? mdxAdmonitionTitle, + children: rest, + }; +} + +export default function Admonition(props: Props): JSX.Element { + const {children, type, title, icon: iconProp} = processAdmonitionProps(props); + + const typeConfig = getAdmonitionConfig(type); + const titleLabel = title ?? typeConfig.label; + const {iconComponent: IconComponent} = typeConfig; + const icon = iconProp ?? ; return (
-
-
- {icon} - {title} -
+
+ {icon} + {titleLabel}
-
{children}
+
{children}
); } diff --git a/packages/docusaurus-theme-classic/src/admonitions.css b/packages/docusaurus-theme-classic/src/theme/Admonition/styles.module.css similarity index 59% rename from packages/docusaurus-theme-classic/src/admonitions.css rename to packages/docusaurus-theme-classic/src/theme/Admonition/styles.module.css index 2b5ac012d3e2..2580873f11e3 100644 --- a/packages/docusaurus-theme-classic/src/admonitions.css +++ b/packages/docusaurus-theme-classic/src/theme/Admonition/styles.module.css @@ -5,35 +5,34 @@ * LICENSE file in the root directory of this source tree. */ -.admonition h5 { - margin-top: 0; - margin-bottom: 8px; +.admonition { + margin-bottom: 1em; +} + +.admonitionHeading { + font: var(--ifm-heading-font-weight) var(--ifm-h5-font-size) / + var(--ifm-heading-line-height) var(--ifm-heading-font-family); text-transform: uppercase; + margin-bottom: 0.3rem; } -.admonition h5 code { +.admonitionHeading code { text-transform: none; } -.admonition-icon { +.admonitionIcon { display: inline-block; vertical-align: middle; margin-right: 0.4em; } -.admonition-icon svg { +.admonitionIcon svg { display: inline-block; - width: 22px; - height: 22px; - stroke-width: 0; + height: 1.6em; + width: 1.6em; fill: var(--ifm-alert-foreground-color); - stroke: var(--ifm-alert-foreground-color); } -.admonition-content > :last-child { +.admonitionContent > :last-child { margin-bottom: 0; } - -.admonition { - margin-bottom: 1em; -} diff --git a/packages/docusaurus-theme-classic/src/theme/CodeBlock/Container/index.tsx b/packages/docusaurus-theme-classic/src/theme/CodeBlock/Container/index.tsx index 293d700dad35..3e3961027373 100644 --- a/packages/docusaurus-theme-classic/src/theme/CodeBlock/Container/index.tsx +++ b/packages/docusaurus-theme-classic/src/theme/CodeBlock/Container/index.tsx @@ -23,7 +23,7 @@ export default function CodeBlockContainer({ return ( + ) : ( diff --git a/packages/docusaurus-theme-classic/src/theme/MDXComponents/index.tsx b/packages/docusaurus-theme-classic/src/theme/MDXComponents/index.tsx index 82e7c5ac6b12..8b6141f5e2bc 100644 --- a/packages/docusaurus-theme-classic/src/theme/MDXComponents/index.tsx +++ b/packages/docusaurus-theme-classic/src/theme/MDXComponents/index.tsx @@ -14,6 +14,7 @@ import MDXDetails from '@theme/MDXComponents/Details'; import MDXHeading from '@theme/MDXComponents/Heading'; import MDXUl from '@theme/MDXComponents/Ul'; import MDXImg from '@theme/MDXComponents/Img'; +import Admonition from '@theme/Admonition'; import type {MDXComponentsObject} from '@theme/MDXComponents'; @@ -31,6 +32,7 @@ const MDXComponents: MDXComponentsObject = { h4: (props) => , h5: (props) => , h6: (props) => , + admonition: Admonition, }; export default MDXComponents; diff --git a/packages/docusaurus-theme-classic/src/theme/MDXPage/index.tsx b/packages/docusaurus-theme-classic/src/theme/MDXPage/index.tsx index e0fbca8fcf8d..a8090301129c 100644 --- a/packages/docusaurus-theme-classic/src/theme/MDXPage/index.tsx +++ b/packages/docusaurus-theme-classic/src/theme/MDXPage/index.tsx @@ -38,9 +38,11 @@ export default function MDXPage(props: Props): JSX.Element {
- - - +
+ + + +
{!hideTableOfContents && MDXPageContent.toc.length > 0 && (
diff --git a/packages/docusaurus-theme-classic/src/theme/NavbarItem/index.tsx b/packages/docusaurus-theme-classic/src/theme/NavbarItem/index.tsx index 0096e2bdb1e3..e2d90b1102d5 100644 --- a/packages/docusaurus-theme-classic/src/theme/NavbarItem/index.tsx +++ b/packages/docusaurus-theme-classic/src/theme/NavbarItem/index.tsx @@ -24,5 +24,5 @@ export default function NavbarItem({type, ...props}: Props): JSX.Element { if (!NavbarItemComponent) { throw new Error(`No NavbarItem component found for type "${type}".`); } - return ; + return ; } diff --git a/packages/docusaurus-theme-classic/src/validateThemeConfig.ts b/packages/docusaurus-theme-classic/src/validateThemeConfig.ts index d64b671f0270..3ce3c618d7a5 100644 --- a/packages/docusaurus-theme-classic/src/validateThemeConfig.ts +++ b/packages/docusaurus-theme-classic/src/validateThemeConfig.ts @@ -364,6 +364,7 @@ export const ThemeConfigSchema = Joi.object({ width: Joi.alternatives().try(Joi.string(), Joi.number()), height: Joi.alternatives().try(Joi.string(), Joi.number()), href: Joi.string(), + target: Joi.string(), }), copyright: Joi.string(), links: Joi.alternatives( diff --git a/packages/docusaurus-theme-classic/tsconfig.json b/packages/docusaurus-theme-classic/tsconfig.json index 9e41ec3ef68c..8aa1157eefbc 100644 --- a/packages/docusaurus-theme-classic/tsconfig.json +++ b/packages/docusaurus-theme-classic/tsconfig.json @@ -5,7 +5,6 @@ "noEmit": false, "incremental": true, "tsBuildInfoFile": "./lib/.tsbuildinfo", - "module": "commonjs", "rootDir": "src", "outDir": "lib" }, diff --git a/packages/docusaurus-theme-common/Details.d.ts b/packages/docusaurus-theme-common/Details.d.ts deleted file mode 100644 index 61dab97e7363..000000000000 --- a/packages/docusaurus-theme-common/Details.d.ts +++ /dev/null @@ -1,14 +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. - */ - -// `Details` is a separate export entry because of side-effects messing with CSS -// insertion order. See https://github.com/facebook/docusaurus/pull/7085. -// However, because TS doesn't recognize `exports` (also a problem in -// `content-docs`), we have to manually create a stub. - -// eslint-disable-next-line import/named -export {Details, type DetailsProps} from './lib/components/Details'; diff --git a/packages/docusaurus-theme-common/src/contexts/navbarSecondaryMenu/content.tsx b/packages/docusaurus-theme-common/src/contexts/navbarSecondaryMenu/content.tsx index 1183362b2349..6972947a81a9 100644 --- a/packages/docusaurus-theme-common/src/contexts/navbarSecondaryMenu/content.tsx +++ b/packages/docusaurus-theme-common/src/contexts/navbarSecondaryMenu/content.tsx @@ -9,11 +9,10 @@ import React, { useState, useContext, useEffect, - useMemo, type ReactNode, type ComponentType, } from 'react'; -import {ReactContextError} from '../../utils/reactUtils'; +import {ReactContextError, useShallowMemoObject} from '../../utils/reactUtils'; // This context represents a "global layout store". A component (usually a // layout component) can request filling this store through @@ -61,15 +60,6 @@ export function useNavbarSecondaryMenuContent(): Content { return value[0]; } -function useShallowMemoizedObject(obj: O) { - return useMemo( - () => obj, - // Is this safe? - // eslint-disable-next-line react-hooks/exhaustive-deps - [...Object.keys(obj), ...Object.values(obj)], - ); -} - /** * This component renders nothing by itself, but it fills the placeholder in the * generic secondary menu layout. This reduces coupling between the main layout @@ -94,7 +84,7 @@ export function NavbarSecondaryMenuFiller

({ const [, setContent] = context; // To avoid useless context re-renders, props are memoized shallowly - const memoizedProps = useShallowMemoizedObject(props); + const memoizedProps = useShallowMemoObject(props); useEffect(() => { // @ts-expect-error: this context is hard to type diff --git a/packages/docusaurus-theme-common/src/hooks/useCodeWordWrap.ts b/packages/docusaurus-theme-common/src/hooks/useCodeWordWrap.ts index 2bffde55c4cf..12cf2eff4c8d 100644 --- a/packages/docusaurus-theme-common/src/hooks/useCodeWordWrap.ts +++ b/packages/docusaurus-theme-common/src/hooks/useCodeWordWrap.ts @@ -4,9 +4,53 @@ * This source code is licensed under the MIT license found in the * LICENSE file in the root directory of this source tree. */ - import type {RefObject} from 'react'; import {useState, useCallback, useEffect, useRef} from 'react'; +import {useMutationObserver} from './useMutationObserver'; + +// Callback fires when the "hidden" attribute of a tabpanel changes +// See https://github.com/facebook/docusaurus/pull/7485 +function useTabBecameVisibleCallback( + codeBlockRef: RefObject, + callback: () => void, +) { + const [hiddenTabElement, setHiddenTabElement] = useState< + Element | null | undefined + >(); + + const updateHiddenTabElement = useCallback(() => { + // No need to observe non-hidden tabs + // + we want to force a re-render when a tab becomes visible + setHiddenTabElement( + codeBlockRef.current?.closest('[role=tabpanel][hidden]'), + ); + }, [codeBlockRef, setHiddenTabElement]); + + useEffect(() => { + updateHiddenTabElement(); + }, [updateHiddenTabElement]); + + useMutationObserver( + hiddenTabElement, + (mutations: MutationRecord[]) => { + mutations.forEach((mutation) => { + if ( + mutation.type === 'attributes' && + mutation.attributeName === 'hidden' + ) { + callback(); + updateHiddenTabElement(); + } + }); + }, + { + attributes: true, + characterData: false, + childList: false, + subtree: false, + }, + ); +} export function useCodeWordWrap(): { readonly codeBlockRef: RefObject; @@ -25,6 +69,9 @@ export function useCodeWordWrap(): { codeElement.removeAttribute('style'); } else { codeElement.style.whiteSpace = 'pre-wrap'; + // When code wrap is enabled, we want to avoid a scrollbar in any case + // Ensure that very very long words/strings/tokens still wrap + codeElement.style.overflowWrap = 'anywhere'; } setIsEnabled((value) => !value); @@ -38,6 +85,8 @@ export function useCodeWordWrap(): { setIsCodeScrollable(isScrollable); }, [codeBlockRef]); + useTabBecameVisibleCallback(codeBlockRef, updateCodeIsScrollable); + useEffect(() => { updateCodeIsScrollable(); }, [isEnabled, updateCodeIsScrollable]); diff --git a/packages/docusaurus-theme-common/src/hooks/useMutationObserver.ts b/packages/docusaurus-theme-common/src/hooks/useMutationObserver.ts new file mode 100644 index 000000000000..fc11277a02b5 --- /dev/null +++ b/packages/docusaurus-theme-common/src/hooks/useMutationObserver.ts @@ -0,0 +1,38 @@ +/** + * 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 {useEffect} from 'react'; +import {useDynamicCallback, useShallowMemoObject} from '../utils/reactUtils'; + +type Options = MutationObserverInit; + +const DefaultOptions: Options = { + attributes: true, + characterData: true, + childList: true, + subtree: true, +}; + +export function useMutationObserver( + target: Element | undefined | null, + callback: MutationCallback, + options: Options = DefaultOptions, +): void { + const stableCallback = useDynamicCallback(callback); + + // MutationObserver options are not nested much + // so this should be to memo options in 99% + // TODO handle options.attributeFilter array + const stableOptions: Options = useShallowMemoObject(options); + + useEffect(() => { + const observer = new MutationObserver(stableCallback); + if (target) { + observer.observe(target, stableOptions); + } + return () => observer.disconnect(); + }, [target, stableCallback, stableOptions]); +} diff --git a/packages/docusaurus-theme-common/src/utils/ThemeClassNames.ts b/packages/docusaurus-theme-common/src/utils/ThemeClassNames.ts index ec3ffc11a969..9b4623214b6f 100644 --- a/packages/docusaurus-theme-common/src/utils/ThemeClassNames.ts +++ b/packages/docusaurus-theme-common/src/utils/ThemeClassNames.ts @@ -31,19 +31,22 @@ export const ThemeClassNames = { docsPages: 'docs-wrapper', mdxPages: 'mdx-wrapper', }, - - /** - * Follows the naming convention "theme-{blog,doc,version,page}?-" - */ common: { editThisPage: 'theme-edit-this-page', lastUpdated: 'theme-last-updated', backToTopButton: 'theme-back-to-top-button', codeBlock: 'theme-code-block', + admonition: 'theme-admonition', + admonitionType: (type: 'note' | 'tip' | 'danger' | 'info' | 'caution') => + `theme-admonition-${type}`, }, layout: { // TODO add other stable classNames here }, + + /** + * Follows the naming convention "theme-{blog,doc,version,page}?-" + */ docs: { docVersionBanner: 'theme-doc-version-banner', docVersionBadge: 'theme-doc-version-badge', 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 3aaec1e34704..df6e985d01fa 100644 --- a/packages/docusaurus-theme-common/src/utils/__tests__/reactUtils.test.ts +++ b/packages/docusaurus-theme-common/src/utils/__tests__/reactUtils.test.ts @@ -6,7 +6,7 @@ */ import {renderHook} from '@testing-library/react-hooks'; -import {usePrevious} from '../reactUtils'; +import {usePrevious, useShallowMemoObject} from '../reactUtils'; describe('usePrevious', () => { it('returns the previous value of a variable', () => { @@ -20,3 +20,37 @@ describe('usePrevious', () => { expect(result.current).toBe(2); }); }); + +describe('useShallowMemoObject', () => { + it('can memoize object', () => { + const someObj = {hello: 'world'}; + const someArray = ['hello', 'world']; + + const obj1 = {a: 1, b: '2', someObj, someArray}; + const {result, rerender} = renderHook((val) => useShallowMemoObject(val), { + initialProps: obj1, + }); + expect(result.current).toBe(obj1); + + const obj2 = {a: 1, b: '2', someObj, someArray}; + rerender(obj2); + expect(result.current).toBe(obj1); + + const obj3 = {a: 1, b: '2', someObj, someArray}; + rerender(obj3); + expect(result.current).toBe(obj1); + + // Current implementation is basic and sensitive to order + const obj4 = {b: '2', a: 1, someObj, someArray}; + rerender(obj4); + expect(result.current).toBe(obj4); + + const obj5 = {b: '2', a: 1, someObj, someArray}; + rerender(obj5); + expect(result.current).toBe(obj4); + + const obj6 = {b: '2', a: 1, someObj: {...someObj}, someArray}; + rerender(obj6); + expect(result.current).toBe(obj6); + }); +}); diff --git a/packages/docusaurus-theme-common/src/utils/reactUtils.tsx b/packages/docusaurus-theme-common/src/utils/reactUtils.tsx index 4e0982807121..e03d3c8de609 100644 --- a/packages/docusaurus-theme-common/src/utils/reactUtils.tsx +++ b/packages/docusaurus-theme-common/src/utils/reactUtils.tsx @@ -5,7 +5,7 @@ * LICENSE file in the root directory of this source tree. */ -import {useCallback, useEffect, useLayoutEffect, useRef} from 'react'; +import {useCallback, useEffect, useLayoutEffect, useMemo, useRef} from 'react'; import ExecutionEnvironment from '@docusaurus/ExecutionEnvironment'; /** @@ -74,3 +74,23 @@ export class ReactContextError extends Error { } is called outside the <${providerName}>. ${additionalInfo ?? ''}`; } } + +/** + * Shallow-memoize an object + * + * This means the returned object will be the same as the previous render + * if the attribute names and identities did not change. + * + * This works for simple cases: when attributes are primitives or stable objects + * + * @param obj + */ +export function useShallowMemoObject(obj: O): O { + return useMemo( + () => obj, + // Is this safe? + // TODO make this implementation not order-dependent? + // eslint-disable-next-line react-hooks/exhaustive-deps + [...Object.keys(obj), ...Object.values(obj)], + ); +} diff --git a/packages/docusaurus-theme-common/src/utils/useThemeConfig.ts b/packages/docusaurus-theme-common/src/utils/useThemeConfig.ts index b160bf307c84..400b520bf502 100644 --- a/packages/docusaurus-theme-common/src/utils/useThemeConfig.ts +++ b/packages/docusaurus-theme-common/src/utils/useThemeConfig.ts @@ -75,6 +75,7 @@ export type FooterLogo = { srcDark?: string; width?: string | number; height?: string | number; + target?: string; href?: string; }; diff --git a/packages/docusaurus-theme-live-codeblock/src/theme-live-codeblock.d.ts b/packages/docusaurus-theme-live-codeblock/src/theme-live-codeblock.d.ts index 5bb5e51d2d26..b4dd299705cd 100644 --- a/packages/docusaurus-theme-live-codeblock/src/theme-live-codeblock.d.ts +++ b/packages/docusaurus-theme-live-codeblock/src/theme-live-codeblock.d.ts @@ -5,6 +5,9 @@ * LICENSE file in the root directory of this source tree. */ +/// +/// + declare module '@docusaurus/theme-live-codeblock' { export type ThemeConfig = { liveCodeBlock: { @@ -14,9 +17,12 @@ declare module '@docusaurus/theme-live-codeblock' { } declare module '@theme/Playground' { + import type {Props as BaseProps} from '@theme/CodeBlock'; import type {LiveProviderProps} from 'react-live'; - export interface Props extends LiveProviderProps { + type CodeBlockProps = Omit; + + export interface Props extends CodeBlockProps, LiveProviderProps { children: string; } export default function Playground(props: LiveProviderProps): JSX.Element; 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 ef5c0f0f4ff9..81fa2ea65b0a 100644 --- a/packages/docusaurus-theme-live-codeblock/src/theme/Playground/index.tsx +++ b/packages/docusaurus-theme-live-codeblock/src/theme/Playground/index.tsx @@ -93,11 +93,14 @@ export default function Playground({ } = themeConfig as ThemeConfig; const prismTheme = usePrismTheme(); + const noInline = props.metastring?.includes('noInline') ?? false; + return (

{/* @ts-expect-error: type incompatibility with refs */} `${code};`)} theme={prismTheme} {...props}> diff --git a/packages/docusaurus-theme-live-codeblock/tsconfig.json b/packages/docusaurus-theme-live-codeblock/tsconfig.json index c0b15f81fcc8..a6dc07deeeee 100644 --- a/packages/docusaurus-theme-live-codeblock/tsconfig.json +++ b/packages/docusaurus-theme-live-codeblock/tsconfig.json @@ -5,7 +5,6 @@ "noEmit": false, "incremental": true, "tsBuildInfoFile": "./lib/.tsbuildinfo", - "module": "commonjs", "rootDir": "src", "outDir": "lib" }, diff --git a/packages/docusaurus-theme-search-algolia/package.json b/packages/docusaurus-theme-search-algolia/package.json index 0a397b2ffc26..d1ae4db8ca9e 100644 --- a/packages/docusaurus-theme-search-algolia/package.json +++ b/packages/docusaurus-theme-search-algolia/package.json @@ -7,8 +7,14 @@ "*.css" ], "exports": { - "./client": "./lib/client/index.js", - ".": "./lib/index.js" + "./client": { + "types": "./lib/client/index.d.ts", + "default": "./lib/client/index.js" + }, + ".": { + "types": "./src/theme-search-algolia.d.ts", + "default": "./lib/index.js" + } }, "types": "src/theme-search-algolia.d.ts", "publishConfig": { diff --git a/packages/docusaurus-theme-search-algolia/src/deps.d.ts b/packages/docusaurus-theme-search-algolia/src/deps.d.ts index 1b69f16b7850..fd64b8228382 100644 --- a/packages/docusaurus-theme-search-algolia/src/deps.d.ts +++ b/packages/docusaurus-theme-search-algolia/src/deps.d.ts @@ -8,3 +8,13 @@ declare module '@docsearch/react/modal'; declare module '@docsearch/react/style'; + +// TODO incompatible declaration file +declare module 'eta' { + export const defaultConfig: object; + + export function compile( + template: string, + options?: object, + ): (data: object, config: object) => string; +} diff --git a/packages/docusaurus-theme-search-algolia/tsconfig.json b/packages/docusaurus-theme-search-algolia/tsconfig.json index 3c8737f51c0d..4eb745d80ce7 100644 --- a/packages/docusaurus-theme-search-algolia/tsconfig.json +++ b/packages/docusaurus-theme-search-algolia/tsconfig.json @@ -5,7 +5,6 @@ "noEmit": false, "incremental": true, "tsBuildInfoFile": "./lib/.tsbuildinfo", - "module": "commonjs", "rootDir": "src", "outDir": "lib" }, diff --git a/packages/docusaurus-theme-translations/locales/ar/theme-common.json b/packages/docusaurus-theme-translations/locales/ar/theme-common.json index 521762273a79..17ec4d109128 100644 --- a/packages/docusaurus-theme-translations/locales/ar/theme-common.json +++ b/packages/docusaurus-theme-translations/locales/ar/theme-common.json @@ -12,6 +12,11 @@ "theme.NotFound.p2": "يرجى الاتصال بمالك الموقع الذي ربطك بعنوان URL الأصلي وإخباره بأن الارتباط الخاص به معطل.", "theme.NotFound.title": "الصفحة غير موجودة", "theme.TOCCollapsible.toggleButtonLabel": "محتويات هذه الصفحة", + "theme.admonition.caution": "caution", + "theme.admonition.danger": "danger", + "theme.admonition.info": "info", + "theme.admonition.note": "note", + "theme.admonition.tip": "tip", "theme.blog.archive.description": "Archive", "theme.blog.archive.title": "Archive", "theme.blog.paginator.navAriaLabel": "التنقل في صفحة قائمة المدونة", diff --git a/packages/docusaurus-theme-translations/locales/base/theme-common.json b/packages/docusaurus-theme-translations/locales/base/theme-common.json index ce9fc1ad1f04..95743ca04339 100644 --- a/packages/docusaurus-theme-translations/locales/base/theme-common.json +++ b/packages/docusaurus-theme-translations/locales/base/theme-common.json @@ -25,6 +25,16 @@ "theme.NotFound.title___DESCRIPTION": "The title of the 404 page", "theme.TOCCollapsible.toggleButtonLabel": "On this page", "theme.TOCCollapsible.toggleButtonLabel___DESCRIPTION": "The label used by the button on the collapsible TOC component", + "theme.admonition.caution": "caution", + "theme.admonition.caution___DESCRIPTION": "The default label used for the Caution admonition (:::caution)", + "theme.admonition.danger": "danger", + "theme.admonition.danger___DESCRIPTION": "The default label used for the Danger admonition (:::danger)", + "theme.admonition.info": "info", + "theme.admonition.info___DESCRIPTION": "The default label used for the Info admonition (:::info)", + "theme.admonition.note": "note", + "theme.admonition.note___DESCRIPTION": "The default label used for the Note admonition (:::note)", + "theme.admonition.tip": "tip", + "theme.admonition.tip___DESCRIPTION": "The default label used for the Tip admonition (:::tip)", "theme.blog.archive.description": "Archive", "theme.blog.archive.description___DESCRIPTION": "The page & hero description of the blog archive page", "theme.blog.archive.title": "Archive", diff --git a/packages/docusaurus-theme-translations/locales/bn/theme-common.json b/packages/docusaurus-theme-translations/locales/bn/theme-common.json index cb95a3ab12ed..9db8b9de8c09 100644 --- a/packages/docusaurus-theme-translations/locales/bn/theme-common.json +++ b/packages/docusaurus-theme-translations/locales/bn/theme-common.json @@ -12,6 +12,11 @@ "theme.NotFound.p2": "দয়া করে সাইটের মালিকের সাথে যোগাযোগ করুন যা আপনাকে মূল URL এর সাথে যুক্ত করেছে এবং তাদের লিঙ্কটি ভাঙ্গা রয়েছে তা তাদের জানান।", "theme.NotFound.title": "পেজটি খুঁজে পাওয়া যায়নি", "theme.TOCCollapsible.toggleButtonLabel": "এই পেজ এ রয়েছে", + "theme.admonition.caution": "caution", + "theme.admonition.danger": "danger", + "theme.admonition.info": "info", + "theme.admonition.note": "note", + "theme.admonition.tip": "tip", "theme.blog.archive.description": "Archive", "theme.blog.archive.title": "Archive", "theme.blog.paginator.navAriaLabel": "ব্লগ তালিকা পেজ নেভিগেশন", diff --git a/packages/docusaurus-theme-translations/locales/cs/theme-common.json b/packages/docusaurus-theme-translations/locales/cs/theme-common.json index acf608eb62b0..2256473958d4 100644 --- a/packages/docusaurus-theme-translations/locales/cs/theme-common.json +++ b/packages/docusaurus-theme-translations/locales/cs/theme-common.json @@ -12,6 +12,11 @@ "theme.NotFound.p2": "Kontaktujte prosím vlastníka webu, který vás odkázal na původní URL a upozorněte ho, že jejich odkaz nefunguje.", "theme.NotFound.title": "Stránka nenalezena", "theme.TOCCollapsible.toggleButtonLabel": "Na této stránce", + "theme.admonition.caution": "caution", + "theme.admonition.danger": "danger", + "theme.admonition.info": "info", + "theme.admonition.note": "note", + "theme.admonition.tip": "tip", "theme.blog.archive.description": "Archive", "theme.blog.archive.title": "Archive", "theme.blog.paginator.navAriaLabel": "Stránkování článků na blogu", diff --git a/packages/docusaurus-theme-translations/locales/da/theme-common.json b/packages/docusaurus-theme-translations/locales/da/theme-common.json index f085952d1f13..a96ad330cde4 100644 --- a/packages/docusaurus-theme-translations/locales/da/theme-common.json +++ b/packages/docusaurus-theme-translations/locales/da/theme-common.json @@ -12,6 +12,11 @@ "theme.NotFound.p2": "Venligst kontakt ejeren til webstedet, som førte dig frem denne URL, og informer dem om at linket ikke virker.", "theme.NotFound.title": "Siden blev ikke fundet", "theme.TOCCollapsible.toggleButtonLabel": "On this page", + "theme.admonition.caution": "caution", + "theme.admonition.danger": "danger", + "theme.admonition.info": "info", + "theme.admonition.note": "note", + "theme.admonition.tip": "tip", "theme.blog.archive.description": "Archive", "theme.blog.archive.title": "Archive", "theme.blog.paginator.navAriaLabel": "Blogoversigt navigation", diff --git a/packages/docusaurus-theme-translations/locales/de/theme-common.json b/packages/docusaurus-theme-translations/locales/de/theme-common.json index 610211f625e2..d302ecd4a0f6 100644 --- a/packages/docusaurus-theme-translations/locales/de/theme-common.json +++ b/packages/docusaurus-theme-translations/locales/de/theme-common.json @@ -12,6 +12,11 @@ "theme.NotFound.p2": "Bitte kontaktieren Sie den Besitzer der Seite, die Sie mit der ursprünglichen URL verlinkt hat, und teilen Sie ihm mit, dass der Link nicht mehr funktioniert.", "theme.NotFound.title": "Seite nicht gefunden", "theme.TOCCollapsible.toggleButtonLabel": "Auf dieser Seite", + "theme.admonition.caution": "caution", + "theme.admonition.danger": "danger", + "theme.admonition.info": "info", + "theme.admonition.note": "note", + "theme.admonition.tip": "tip", "theme.blog.archive.description": "Archiv", "theme.blog.archive.title": "Archiv", "theme.blog.paginator.navAriaLabel": "Navigation der Blog-Listenseite", diff --git a/packages/docusaurus-theme-translations/locales/es/theme-common.json b/packages/docusaurus-theme-translations/locales/es/theme-common.json index a20306646f00..a90504a2e1b9 100644 --- a/packages/docusaurus-theme-translations/locales/es/theme-common.json +++ b/packages/docusaurus-theme-translations/locales/es/theme-common.json @@ -12,6 +12,11 @@ "theme.NotFound.p2": "Comuníquese con el dueño del sitio que lo vinculó a la URL original y hágale saber que su vínculo está roto.", "theme.NotFound.title": "Página No Encontrada", "theme.TOCCollapsible.toggleButtonLabel": "En esta página", + "theme.admonition.caution": "caution", + "theme.admonition.danger": "danger", + "theme.admonition.info": "info", + "theme.admonition.note": "note", + "theme.admonition.tip": "tip", "theme.blog.archive.description": "Archivo", "theme.blog.archive.title": "Archivo", "theme.blog.paginator.navAriaLabel": "Navegación por la página de la lista de blogs ", diff --git a/packages/docusaurus-theme-translations/locales/fa/theme-common.json b/packages/docusaurus-theme-translations/locales/fa/theme-common.json index 7a49fae6a45c..7f5783d75a4a 100644 --- a/packages/docusaurus-theme-translations/locales/fa/theme-common.json +++ b/packages/docusaurus-theme-translations/locales/fa/theme-common.json @@ -12,6 +12,11 @@ "theme.NotFound.p2": "لطفا با صاحب وبسایت تماس بگیرید و ایشان را از مشکل پیش آمده مطلع کنید.", "theme.NotFound.title": "صفحه ای که دنبال آن بودید پیدا نشد.", "theme.TOCCollapsible.toggleButtonLabel": "مطالب این صفحه", + "theme.admonition.caution": "caution", + "theme.admonition.danger": "danger", + "theme.admonition.info": "info", + "theme.admonition.note": "note", + "theme.admonition.tip": "tip", "theme.blog.archive.description": "آرشیو", "theme.blog.archive.title": "آرشیو", "theme.blog.paginator.navAriaLabel": "کنترل لیست مطالب وبلاگ", diff --git a/packages/docusaurus-theme-translations/locales/fil/theme-common.json b/packages/docusaurus-theme-translations/locales/fil/theme-common.json index b0394d752120..49cb94da5ac9 100644 --- a/packages/docusaurus-theme-translations/locales/fil/theme-common.json +++ b/packages/docusaurus-theme-translations/locales/fil/theme-common.json @@ -12,6 +12,11 @@ "theme.NotFound.p2": "Mangyaring makipag-ugnayan sa may-ari ng site na nag-link sa iyo sa orihinal na URL at sabihin sa kanila na ang kanilang link ay putol.", "theme.NotFound.title": "Hindi Nahanap ang Pahina", "theme.TOCCollapsible.toggleButtonLabel": "On this page", + "theme.admonition.caution": "caution", + "theme.admonition.danger": "danger", + "theme.admonition.info": "info", + "theme.admonition.note": "note", + "theme.admonition.tip": "tip", "theme.blog.archive.description": "Archive", "theme.blog.archive.title": "Archive", "theme.blog.paginator.navAriaLabel": "Nabegasyón para sa pahina na listahan ng blog", diff --git a/packages/docusaurus-theme-translations/locales/fr/theme-common.json b/packages/docusaurus-theme-translations/locales/fr/theme-common.json index 72038899c7ec..2154533905dd 100644 --- a/packages/docusaurus-theme-translations/locales/fr/theme-common.json +++ b/packages/docusaurus-theme-translations/locales/fr/theme-common.json @@ -12,6 +12,11 @@ "theme.NotFound.p2": "Veuillez contacter le propriétaire du site qui vous a lié à l'URL d'origine et leur faire savoir que leur lien est cassé.", "theme.NotFound.title": "Page introuvable", "theme.TOCCollapsible.toggleButtonLabel": "Sur cette page", + "theme.admonition.caution": "attention", + "theme.admonition.danger": "danger", + "theme.admonition.info": "info", + "theme.admonition.note": "remarque", + "theme.admonition.tip": "astuce", "theme.blog.archive.description": "Archive", "theme.blog.archive.title": "Archive", "theme.blog.paginator.navAriaLabel": "Pagination de la liste des articles du blog", diff --git a/packages/docusaurus-theme-translations/locales/he/theme-common.json b/packages/docusaurus-theme-translations/locales/he/theme-common.json index 343bfd9cb701..f658c83b6534 100644 --- a/packages/docusaurus-theme-translations/locales/he/theme-common.json +++ b/packages/docusaurus-theme-translations/locales/he/theme-common.json @@ -12,6 +12,11 @@ "theme.NotFound.p2": "הקישור אינו תקין, אנא פנה למנהל האתר ממנו קיבלת קישור זה.", "theme.NotFound.title": "דף לא נמצא", "theme.TOCCollapsible.toggleButtonLabel": "בעמוד זה", + "theme.admonition.caution": "caution", + "theme.admonition.danger": "danger", + "theme.admonition.info": "info", + "theme.admonition.note": "note", + "theme.admonition.tip": "tip", "theme.blog.archive.description": "Archive", "theme.blog.archive.title": "Archive", "theme.blog.paginator.navAriaLabel": "רשימת דפי הבלוג", diff --git a/packages/docusaurus-theme-translations/locales/hi/theme-common.json b/packages/docusaurus-theme-translations/locales/hi/theme-common.json index 0bdb5ea4f2f4..ff35a0df2af5 100644 --- a/packages/docusaurus-theme-translations/locales/hi/theme-common.json +++ b/packages/docusaurus-theme-translations/locales/hi/theme-common.json @@ -12,6 +12,11 @@ "theme.NotFound.p2": "कृपया उस साइट के मालिक से संपर्क करें जिसने आपको मूल URL से जोड़ा है और उन्हें बताएं कि उनका लिंक टूट गया है।", "theme.NotFound.title": "पेज नहीं मिला", "theme.TOCCollapsible.toggleButtonLabel": "इस पेज पर", + "theme.admonition.caution": "caution", + "theme.admonition.danger": "danger", + "theme.admonition.info": "info", + "theme.admonition.note": "note", + "theme.admonition.tip": "tip", "theme.blog.archive.description": "Archive", "theme.blog.archive.title": "Archive", "theme.blog.paginator.navAriaLabel": "ब्लॉग सूची पेज नेविगेशन", diff --git a/packages/docusaurus-theme-translations/locales/it/theme-common.json b/packages/docusaurus-theme-translations/locales/it/theme-common.json index 1e23d07651f7..4c69f66091fd 100644 --- a/packages/docusaurus-theme-translations/locales/it/theme-common.json +++ b/packages/docusaurus-theme-translations/locales/it/theme-common.json @@ -12,6 +12,11 @@ "theme.NotFound.p2": "Contatta il proprietario del sito che ti ha collegato all'URL originale e fagli sapere che il loro collegamento è interrotto.", "theme.NotFound.title": "Pagina non trovata", "theme.TOCCollapsible.toggleButtonLabel": "Su questa pagina", + "theme.admonition.caution": "caution", + "theme.admonition.danger": "danger", + "theme.admonition.info": "info", + "theme.admonition.note": "note", + "theme.admonition.tip": "tip", "theme.blog.archive.description": "Archivio", "theme.blog.archive.title": "Archivio", "theme.blog.paginator.navAriaLabel": "Navigazione nella pagina dei post del blog ", diff --git a/packages/docusaurus-theme-translations/locales/ja/theme-common.json b/packages/docusaurus-theme-translations/locales/ja/theme-common.json index 66f9309ce407..42a6a06af877 100644 --- a/packages/docusaurus-theme-translations/locales/ja/theme-common.json +++ b/packages/docusaurus-theme-translations/locales/ja/theme-common.json @@ -12,6 +12,11 @@ "theme.NotFound.p2": "このページにリンクしているサイトの所有者に連絡をしてリンクが壊れていることを伝えてください。", "theme.NotFound.title": "ページが見つかりません", "theme.TOCCollapsible.toggleButtonLabel": "On this page", + "theme.admonition.caution": "caution", + "theme.admonition.danger": "danger", + "theme.admonition.info": "info", + "theme.admonition.note": "note", + "theme.admonition.tip": "tip", "theme.blog.archive.description": "Archive", "theme.blog.archive.title": "Archive", "theme.blog.paginator.navAriaLabel": "ブログ記事一覧のナビゲーション", diff --git a/packages/docusaurus-theme-translations/locales/ko/plugin-ideal-image.json b/packages/docusaurus-theme-translations/locales/ko/plugin-ideal-image.json index 3576b692c08d..09944226ecb7 100644 --- a/packages/docusaurus-theme-translations/locales/ko/plugin-ideal-image.json +++ b/packages/docusaurus-theme-translations/locales/ko/plugin-ideal-image.json @@ -1,7 +1,7 @@ { - "theme.IdealImageMessage.404error": "404. Image not found", - "theme.IdealImageMessage.error": "Error. Click to reload", - "theme.IdealImageMessage.load": "Click to load{sizeMessage}", - "theme.IdealImageMessage.loading": "Loading...", - "theme.IdealImageMessage.offline": "Your browser is offline. Image not loaded" + "theme.IdealImageMessage.404error": "404. 이미지를 찾을 수 없습니다", + "theme.IdealImageMessage.error": "에러. 클릭해서 새로고치기", + "theme.IdealImageMessage.load": "클릭하여 {sizeMessage} 로드하기", + "theme.IdealImageMessage.loading": "로딩", + "theme.IdealImageMessage.offline": "오프라인 상태. 이미지를 로드하지 않았습니다." } diff --git a/packages/docusaurus-theme-translations/locales/ko/theme-common.json b/packages/docusaurus-theme-translations/locales/ko/theme-common.json index 16ffecaeae75..4b4f50e8bd81 100644 --- a/packages/docusaurus-theme-translations/locales/ko/theme-common.json +++ b/packages/docusaurus-theme-translations/locales/ko/theme-common.json @@ -4,7 +4,7 @@ "theme.CodeBlock.copied": "복사했습니다", "theme.CodeBlock.copy": "복사", "theme.CodeBlock.copyButtonAriaLabel": "클립보드에 코드 복사", - "theme.CodeBlock.wordWrapToggle": "Toggle word wrap", + "theme.CodeBlock.wordWrapToggle": "줄 바꿈 전환", "theme.DocSidebarItem.toggleCollapsedCategoryAriaLabel": "접을 수 있는 사이드바 분류 '{label}' 접기(펼치기)", "theme.ErrorPageContent.title": "페이지에 오류가 발생하였습니다.", "theme.ErrorPageContent.tryAgain": "다시 시도해 보세요", @@ -12,6 +12,11 @@ "theme.NotFound.p2": "사이트 관리자에게 링크가 깨진 것을 알려주세요.", "theme.NotFound.title": "페이지를 찾을 수 없습니다.", "theme.TOCCollapsible.toggleButtonLabel": "이 페이지에서", + "theme.admonition.caution": "주의", + "theme.admonition.danger": "위험", + "theme.admonition.info": "정보", + "theme.admonition.note": "노트", + "theme.admonition.tip": "팁", "theme.blog.archive.description": "게시물 목록", "theme.blog.archive.title": "게시물 목록", "theme.blog.paginator.navAriaLabel": "블로그 게시물 목록 탐색", @@ -33,7 +38,7 @@ "theme.common.headingLinkTitle": "제목으로 바로 가기", "theme.common.skipToMainContent": "본문으로 건너뛰기", "theme.docs.DocCard.categoryDescription": "{count} 항목", - "theme.docs.breadcrumbs.home": "Home page", + "theme.docs.breadcrumbs.home": "홈", "theme.docs.breadcrumbs.navAriaLabel": "Breadcrumbs", "theme.docs.paginator.navAriaLabel": "문서 탐색", "theme.docs.paginator.next": "다음", @@ -43,16 +48,16 @@ "theme.docs.sidebar.expandButtonAriaLabel": "사이드바 열기", "theme.docs.sidebar.expandButtonTitle": "사이드바 열기", "theme.docs.tagDocListPageTitle": "{nDocsTagged} \"{tagName}\" 태그에 분류되었습니다", - "theme.docs.tagDocListPageTitle.nDocsTagged": "{count} 개 문서가", - "theme.docs.versionBadge.label": "Version: {versionLabel}", + "theme.docs.tagDocListPageTitle.nDocsTagged": "{count}개 문서가", + "theme.docs.versionBadge.label": "버전: {versionLabel}", "theme.docs.versions.latestVersionLinkLabel": "최신 버전", "theme.docs.versions.latestVersionSuggestionLabel": "최신 문서는 {latestVersionLink} ({versionLabel})을 확인하세요.", "theme.docs.versions.unmaintainedVersionLabel": "{siteTitle} {versionLabel} 문서는 더 이상 업데이트되지 않습니다.", "theme.docs.versions.unreleasedVersionLabel": "{siteTitle} {versionLabel} 문서는 아직 정식 공개되지 않았습니다.", "theme.lastUpdated.atDate": " {date}에", "theme.lastUpdated.byUser": " {user}가", - "theme.lastUpdated.lastUpdatedAtBy": "최종 수정 : {atDate}{byUser}", - "theme.navbar.mobileLanguageDropdown.label": "Languages", + "theme.lastUpdated.lastUpdatedAtBy": "최종 수정: {atDate}{byUser}", + "theme.navbar.mobileLanguageDropdown.label": "언어", "theme.navbar.mobileSidebarSecondaryMenu.backButtonLabel": "← 메인 메뉴로 돌아가기", "theme.navbar.mobileVersionsDropdown.label": "버전", "theme.tags.tagsListLabel": "태그:", diff --git a/packages/docusaurus-theme-translations/locales/ko/theme-search-algolia.json b/packages/docusaurus-theme-translations/locales/ko/theme-search-algolia.json index 149d93d623cc..345a288abbf0 100644 --- a/packages/docusaurus-theme-translations/locales/ko/theme-search-algolia.json +++ b/packages/docusaurus-theme-translations/locales/ko/theme-search-algolia.json @@ -1,11 +1,11 @@ { "theme.SearchBar.label": "검색", - "theme.SearchBar.seeAll": "See all {count} results", - "theme.SearchPage.algoliaLabel": "Search by Algolia", + "theme.SearchBar.seeAll": "{count}개의 결과 확인하기", + "theme.SearchPage.algoliaLabel": "Algolia로 검색", "theme.SearchPage.documentsFound.plurals": "{count}개 문서를 찾았습니다.", "theme.SearchPage.emptyResultsTitle": "문서를 검색합니다.", "theme.SearchPage.existingResultsTitle": "\"{query}\"개 검색 결과가 있습니다.", - "theme.SearchPage.fetchingNewResults": "새로운 검색 결과를 얻을 수 있습니다...", + "theme.SearchPage.fetchingNewResults": "새로운 검색 결과를 불러오는 중 입니다...", "theme.SearchPage.inputLabel": "검색", "theme.SearchPage.inputPlaceholder": "여기에 검색할 키워드를 입력하세요.", "theme.SearchPage.noResultsText": "검색 결과가 없습니다." diff --git a/packages/docusaurus-theme-translations/locales/pl/theme-common.json b/packages/docusaurus-theme-translations/locales/pl/theme-common.json index 551d28dcc558..a28dedf0c9f5 100644 --- a/packages/docusaurus-theme-translations/locales/pl/theme-common.json +++ b/packages/docusaurus-theme-translations/locales/pl/theme-common.json @@ -12,6 +12,11 @@ "theme.NotFound.p2": "Proszę skontaktuj się z właścielem strony, z której link doprowadził Cię tutaj i poinformuj go, że link jest nieprawidłowy.", "theme.NotFound.title": "Strona nie została znaleziona", "theme.TOCCollapsible.toggleButtonLabel": "Na tej stronie", + "theme.admonition.caution": "caution", + "theme.admonition.danger": "danger", + "theme.admonition.info": "info", + "theme.admonition.note": "note", + "theme.admonition.tip": "tip", "theme.blog.archive.description": "Archiwum", "theme.blog.archive.title": "Archiwum", "theme.blog.paginator.navAriaLabel": "Nawigacja na stronie listy wpisów na blogu", diff --git a/packages/docusaurus-theme-translations/locales/pt-BR/theme-common.json b/packages/docusaurus-theme-translations/locales/pt-BR/theme-common.json index 1d106dc059b4..7f9ec716fedd 100644 --- a/packages/docusaurus-theme-translations/locales/pt-BR/theme-common.json +++ b/packages/docusaurus-theme-translations/locales/pt-BR/theme-common.json @@ -12,6 +12,11 @@ "theme.NotFound.p2": "Entre em contato com o proprietário do site que lhe trouxe para cá e lhe informe que o link está quebrado.", "theme.NotFound.title": "Página não encontrada", "theme.TOCCollapsible.toggleButtonLabel": "Nessa página", + "theme.admonition.caution": "caution", + "theme.admonition.danger": "danger", + "theme.admonition.info": "info", + "theme.admonition.note": "note", + "theme.admonition.tip": "tip", "theme.blog.archive.description": "Arquivo", "theme.blog.archive.title": "Arquivo", "theme.blog.paginator.navAriaLabel": "Navegação da página de listagem do blog", diff --git a/packages/docusaurus-theme-translations/locales/pt-PT/theme-common.json b/packages/docusaurus-theme-translations/locales/pt-PT/theme-common.json index e751770beb70..11788c591cb4 100644 --- a/packages/docusaurus-theme-translations/locales/pt-PT/theme-common.json +++ b/packages/docusaurus-theme-translations/locales/pt-PT/theme-common.json @@ -12,6 +12,11 @@ "theme.NotFound.p2": "Por favor, contacte o proprietário do site que o trouxe aqui e informe-lhe que o link está partido.", "theme.NotFound.title": "Página não encontrada", "theme.TOCCollapsible.toggleButtonLabel": "On this page", + "theme.admonition.caution": "caution", + "theme.admonition.danger": "danger", + "theme.admonition.info": "info", + "theme.admonition.note": "note", + "theme.admonition.tip": "tip", "theme.blog.archive.description": "Archive", "theme.blog.archive.title": "Archive", "theme.blog.paginator.navAriaLabel": "Navegação da página de listagem do blog", diff --git a/packages/docusaurus-theme-translations/locales/ru/theme-common.json b/packages/docusaurus-theme-translations/locales/ru/theme-common.json index 18fa1dd8b3db..97b38b8532dc 100644 --- a/packages/docusaurus-theme-translations/locales/ru/theme-common.json +++ b/packages/docusaurus-theme-translations/locales/ru/theme-common.json @@ -12,6 +12,11 @@ "theme.NotFound.p2": "Пожалуйста, обратитесь к владельцу сайта, с которого вы перешли на эту ссылку, чтобы сообщить ему, что ссылка не работает.", "theme.NotFound.title": "Страница не найдена", "theme.TOCCollapsible.toggleButtonLabel": "Содержание этой страницы", + "theme.admonition.caution": "caution", + "theme.admonition.danger": "danger", + "theme.admonition.info": "info", + "theme.admonition.note": "note", + "theme.admonition.tip": "tip", "theme.blog.archive.description": "Архив", "theme.blog.archive.title": "Архив", "theme.blog.paginator.navAriaLabel": "Навигация по странице списка блогов", diff --git a/packages/docusaurus-theme-translations/locales/sr/theme-common.json b/packages/docusaurus-theme-translations/locales/sr/theme-common.json index 4fe255281bf4..152b345efef0 100644 --- a/packages/docusaurus-theme-translations/locales/sr/theme-common.json +++ b/packages/docusaurus-theme-translations/locales/sr/theme-common.json @@ -12,6 +12,11 @@ "theme.NotFound.p2": "Молимо вас да контактирате власника сајта који вас је упутио овде и обавестите га да је њихова веза нетачна.", "theme.NotFound.title": "Страница није пронађена", "theme.TOCCollapsible.toggleButtonLabel": "На овој страници", + "theme.admonition.caution": "caution", + "theme.admonition.danger": "danger", + "theme.admonition.info": "info", + "theme.admonition.note": "note", + "theme.admonition.tip": "tip", "theme.blog.archive.description": "Архива", "theme.blog.archive.title": "Архива", "theme.blog.paginator.navAriaLabel": "Навигација за странице блога", diff --git a/packages/docusaurus-theme-translations/locales/tr/theme-common.json b/packages/docusaurus-theme-translations/locales/tr/theme-common.json index b397fc548346..2131b5f45bca 100644 --- a/packages/docusaurus-theme-translations/locales/tr/theme-common.json +++ b/packages/docusaurus-theme-translations/locales/tr/theme-common.json @@ -12,6 +12,11 @@ "theme.NotFound.p2": "Lütfen sizi orijinal URL'ye yönlendiren sitenin sahibiyle iletişime geçin ve bağlantısının bozuk olduğunu bildirin.", "theme.NotFound.title": "Sayfa Bulunamadı", "theme.TOCCollapsible.toggleButtonLabel": "Bu sayfada", + "theme.admonition.caution": "caution", + "theme.admonition.danger": "danger", + "theme.admonition.info": "info", + "theme.admonition.note": "note", + "theme.admonition.tip": "tip", "theme.blog.archive.description": "Arşiv", "theme.blog.archive.title": "Arşiv", "theme.blog.paginator.navAriaLabel": "Blog gönderi sayfası navigasyonu", diff --git a/packages/docusaurus-theme-translations/locales/vi/theme-common.json b/packages/docusaurus-theme-translations/locales/vi/theme-common.json index 82bc3e3a413d..b22334a7cc11 100644 --- a/packages/docusaurus-theme-translations/locales/vi/theme-common.json +++ b/packages/docusaurus-theme-translations/locales/vi/theme-common.json @@ -12,6 +12,11 @@ "theme.NotFound.p2": "Vui lòng liên hệ với trang web đã dẫn bạn tới đây và thông báo cho họ biết rằng đường dẫn này bị hỏng.", "theme.NotFound.title": "Không tìm thấy trang", "theme.TOCCollapsible.toggleButtonLabel": "Trên trang này", + "theme.admonition.caution": "caution", + "theme.admonition.danger": "danger", + "theme.admonition.info": "info", + "theme.admonition.note": "note", + "theme.admonition.tip": "tip", "theme.blog.archive.description": "Lưu trữ", "theme.blog.archive.title": "Lưu trữ", "theme.blog.paginator.navAriaLabel": "Thanh điều hướng của trang danh sách bài viết", diff --git a/packages/docusaurus-theme-translations/locales/zh-Hans/theme-common.json b/packages/docusaurus-theme-translations/locales/zh-Hans/theme-common.json index f2ed51faaed3..9475f7e3ba39 100644 --- a/packages/docusaurus-theme-translations/locales/zh-Hans/theme-common.json +++ b/packages/docusaurus-theme-translations/locales/zh-Hans/theme-common.json @@ -12,6 +12,11 @@ "theme.NotFound.p2": "请联系原始链接来源网站的所有者,并告知他们链接已损坏。", "theme.NotFound.title": "找不到页面", "theme.TOCCollapsible.toggleButtonLabel": "本页总览", + "theme.admonition.caution": "警告", + "theme.admonition.danger": "危险", + "theme.admonition.info": "信息", + "theme.admonition.note": "备注", + "theme.admonition.tip": "提示", "theme.blog.archive.description": "历史博文", "theme.blog.archive.title": "历史博文", "theme.blog.paginator.navAriaLabel": "博文列表分页导航", diff --git a/packages/docusaurus-theme-translations/locales/zh-Hant/theme-common.json b/packages/docusaurus-theme-translations/locales/zh-Hant/theme-common.json index 835d08b21a6f..a90342715415 100644 --- a/packages/docusaurus-theme-translations/locales/zh-Hant/theme-common.json +++ b/packages/docusaurus-theme-translations/locales/zh-Hant/theme-common.json @@ -12,6 +12,11 @@ "theme.NotFound.p2": "請聯絡原始連結來源網站的所有者,並通知他們連結已毀損。", "theme.NotFound.title": "找不到頁面", "theme.TOCCollapsible.toggleButtonLabel": "本頁導覽", + "theme.admonition.caution": "警告", + "theme.admonition.danger": "危險", + "theme.admonition.info": "信息", + "theme.admonition.note": "備註", + "theme.admonition.tip": "提示", "theme.blog.archive.description": "歷史文章", "theme.blog.archive.title": "歷史文章", "theme.blog.paginator.navAriaLabel": "部落格文章列表分頁導覽", diff --git a/packages/docusaurus-theme-translations/tsconfig.build.json b/packages/docusaurus-theme-translations/tsconfig.build.json index 5370e86c56a5..912de0a933a8 100644 --- a/packages/docusaurus-theme-translations/tsconfig.build.json +++ b/packages/docusaurus-theme-translations/tsconfig.build.json @@ -7,7 +7,6 @@ "tsBuildInfoFile": "./lib/.tsbuildinfo", "sourceMap": true, "declarationMap": true, - "module": "commonjs", "rootDir": "src", "outDir": "lib" }, diff --git a/packages/docusaurus-theme-translations/tsconfig.json b/packages/docusaurus-theme-translations/tsconfig.json index 2a44c196c440..6ba7dee96bcd 100644 --- a/packages/docusaurus-theme-translations/tsconfig.json +++ b/packages/docusaurus-theme-translations/tsconfig.json @@ -2,7 +2,6 @@ "extends": "../../tsconfig.json", "references": [{"path": "./tsconfig.build.json"}], "compilerOptions": { - "module": "esnext", "noEmit": true, "checkJs": true }, diff --git a/packages/docusaurus-types/package.json b/packages/docusaurus-types/package.json index 4415cf4a1c37..a029043b5181 100644 --- a/packages/docusaurus-types/package.json +++ b/packages/docusaurus-types/package.json @@ -14,11 +14,12 @@ "license": "MIT", "dependencies": { "@types/history": "^4.7.11", + "@types/react": "*", "commander": "^5.1.0", "joi": "^17.6.0", "react-helmet-async": "^1.3.0", "utility-types": "^3.10.0", - "webpack": "^5.72.1", + "webpack": "^5.73.0", "webpack-merge": "^5.8.0" }, "peerDependencies": { diff --git a/packages/docusaurus-types/src/index.d.ts b/packages/docusaurus-types/src/index.d.ts index ee4151930eee..3b74be40730f 100644 --- a/packages/docusaurus-types/src/index.d.ts +++ b/packages/docusaurus-types/src/index.d.ts @@ -5,6 +5,7 @@ * LICENSE file in the root directory of this source tree. */ +import type {JSXElementConstructor} from 'react'; import type {RuleSetRule, Configuration as WebpackConfiguration} from 'webpack'; import type {CustomizeRuleString} from 'webpack-merge/dist/types'; import type {CommanderStatic} from 'commander'; @@ -60,6 +61,12 @@ export type I18nLocaleConfig = { * or `en-US` (`en` means `en-US`). */ calendar: string; + /** + * Root folder that all plugin localization folders of this locale are + * relative to. Will be resolved against `i18n.path`. Defaults to the locale's + * name. + */ + path: string; }; export type I18nConfig = { @@ -70,6 +77,11 @@ export type I18nConfig = { * 3. Will be used for the `` tag */ defaultLocale: string; + /** + * Root folder which all locale folders are relative to. Can be absolute or + * relative to the config file. e.g. `i18n` + */ + path: string; /** List of locales deployed on your site. Must contain `defaultLocale`. */ locales: [string, ...string[]]; /** Individual options for each locale. */ @@ -416,6 +428,12 @@ export type LoadContext = { siteConfig: DocusaurusConfig; siteConfigPath: string; outDir: string; + /** + * Directory where all source translations for the current locale can be found + * in. Constructed with `i18n.path` + `i18n.currentLocale.path` (e.g. + * `/i18n/en`) + */ + localizationDir: string; /** * Duplicated from `siteConfig.baseUrl`, but probably worth keeping. We mutate * `siteConfig` to make `baseUrl` there localized as well, but that's mostly @@ -747,3 +765,24 @@ export type UseDataOptions = { */ failfast?: boolean; }; + +/** + * This type is almost the same as `React.ComponentProps`, but with one minor + * fix: when the component is a function with no parameters, it produces `{}` + * instead of `unknown`, allowing us to spread the props derived from another + * component. This is useful for wrap swizzling. + * + * @see https://github.com/DefinitelyTyped/DefinitelyTyped/discussions/60766 + */ +export type WrapperProps< + // eslint-disable-next-line @typescript-eslint/no-explicit-any + T extends keyof JSX.IntrinsicElements | JSXElementConstructor, +> = T extends JSXElementConstructor + ? unknown extends P + ? // eslint-disable-next-line @typescript-eslint/ban-types + {} + : P + : T extends keyof JSX.IntrinsicElements + ? JSX.IntrinsicElements[T] + : // eslint-disable-next-line @typescript-eslint/ban-types + {}; diff --git a/packages/docusaurus-utils-common/tsconfig.json b/packages/docusaurus-utils-common/tsconfig.json index f787010fcd78..0e5365a3c1e8 100644 --- a/packages/docusaurus-utils-common/tsconfig.json +++ b/packages/docusaurus-utils-common/tsconfig.json @@ -6,7 +6,6 @@ "tsBuildInfoFile": "./lib/.tsbuildinfo", "sourceMap": true, "declarationMap": true, - "module": "commonjs", "rootDir": "src", "outDir": "lib", "noEmitHelpers": false diff --git a/packages/docusaurus-utils-validation/src/__tests__/__snapshots__/validationSchemas.test.ts.snap b/packages/docusaurus-utils-validation/src/__tests__/__snapshots__/validationSchemas.test.ts.snap index bfa30ac7873e..d49280b4147d 100644 --- a/packages/docusaurus-utils-validation/src/__tests__/__snapshots__/validationSchemas.test.ts.snap +++ b/packages/docusaurus-utils-validation/src/__tests__/__snapshots__/validationSchemas.test.ts.snap @@ -1,12 +1,32 @@ // Jest Snapshot v1, https://goo.gl/fbAQLP -exports[`validation schemas admonitionsSchema: for value=[] 1`] = `""value" must be of type object"`; +exports[`validation schemas admonitionsSchema: for value=[] 1`] = `""value" does not look like a valid admonitions config"`; -exports[`validation schemas admonitionsSchema: for value=3 1`] = `""value" must be of type object"`; +exports[`validation schemas admonitionsSchema: for value={"customTypes":{"myKeyword":{"keyword":"myKeyword","infima":true,"svg":""}}} 1`] = ` +"The Docusaurus admonitions system has changed, and the option "customTypes" does not exist anymore. +You now need to swizzle the admonitions component to provide UI customizations such as icons. +Please refer to https://github.com/facebook/docusaurus/pull/7152 for detailed upgrade instructions." +`; + +exports[`validation schemas admonitionsSchema: for value={"icons":"emoji"} 1`] = ` +"The Docusaurus admonitions system has changed, and the option "icons" does not exist anymore. +You now need to swizzle the admonitions component to provide UI customizations such as icons. +Please refer to https://github.com/facebook/docusaurus/pull/7152 for detailed upgrade instructions." +`; + +exports[`validation schemas admonitionsSchema: for value={"infima":true} 1`] = ` +"The Docusaurus admonitions system has changed, and the option "infima" does not exist anymore. +You now need to swizzle the admonitions component to provide UI customizations such as icons. +Please refer to https://github.com/facebook/docusaurus/pull/7152 for detailed upgrade instructions." +`; + +exports[`validation schemas admonitionsSchema: for value={"keywords":[]} 1`] = `""keywords" does not contain 1 required value(s)"`; + +exports[`validation schemas admonitionsSchema: for value={"tag":""} 1`] = `""tag" is not allowed to be empty"`; -exports[`validation schemas admonitionsSchema: for value=null 1`] = `""value" must be of type object"`; +exports[`validation schemas admonitionsSchema: for value={"unknownAttribute":"val"} 1`] = `""unknownAttribute" is not allowed"`; -exports[`validation schemas admonitionsSchema: for value=true 1`] = `""value" must be of type object"`; +exports[`validation schemas admonitionsSchema: for value=3 1`] = `""value" does not look like a valid admonitions config"`; exports[`validation schemas pathnameSchema: for value="foo" 1`] = `""value" is not a valid pathname. Pathname should start with slash and not contain any domain or query string."`; diff --git a/packages/docusaurus-utils-validation/src/__tests__/validationSchemas.test.ts b/packages/docusaurus-utils-validation/src/__tests__/validationSchemas.test.ts index 534ac218fd94..ad66dede975e 100644 --- a/packages/docusaurus-utils-validation/src/__tests__/validationSchemas.test.ts +++ b/packages/docusaurus-utils-validation/src/__tests__/validationSchemas.test.ts @@ -87,17 +87,39 @@ describe('validation schemas', () => { it('admonitionsSchema', () => { const {testOK, testFail} = createTestHelpers({ schema: AdmonitionsSchema, - defaultValue: {}, + defaultValue: true, }); testOK(undefined); + testOK(true); + testOK(false); testOK({}); - testOK({attr: 'val'}); + testOK({tag: '+++'}); + testOK({keywords: ['info', 'tip']}); + testOK({tag: '+++', keywords: ['info', 'tip']}); - testFail(null); testFail(3); - testFail(true); testFail([]); + testFail({unknownAttribute: 'val'}); + testFail({tag: ''}); + testFail({keywords: []}); + + // Legacy types + testFail({ + infima: true, + }); + testFail({ + icons: 'emoji', + }); + testFail({ + customTypes: { + myKeyword: { + keyword: `myKeyword`, + infima: true, + svg: '', + }, + }, + }); }); it('remarkPluginsSchema', () => { diff --git a/packages/docusaurus-utils-validation/src/validationSchemas.ts b/packages/docusaurus-utils-validation/src/validationSchemas.ts index 8c6a10e9c00b..f6bd54d6f3d8 100644 --- a/packages/docusaurus-utils-validation/src/validationSchemas.ts +++ b/packages/docusaurus-utils-validation/src/validationSchemas.ts @@ -32,7 +32,31 @@ const MarkdownPluginsSchema = Joi.array() export const RemarkPluginsSchema = MarkdownPluginsSchema; export const RehypePluginsSchema = MarkdownPluginsSchema; -export const AdmonitionsSchema = Joi.object().default({}); +const LegacyAdmonitionConfigSchema = Joi.forbidden().messages({ + 'any.unknown': `The Docusaurus admonitions system has changed, and the option {#label} does not exist anymore. +You now need to swizzle the admonitions component to provide UI customizations such as icons. +Please refer to https://github.com/facebook/docusaurus/pull/7152 for detailed upgrade instructions.`, +}); + +export const AdmonitionsSchema = JoiFrontMatter.alternatives() + .try( + JoiFrontMatter.boolean().required(), + JoiFrontMatter.object({ + tag: JoiFrontMatter.string(), + keywords: JoiFrontMatter.array().items( + JoiFrontMatter.string().required(), + ), + // TODO Remove before 2023 + customTypes: LegacyAdmonitionConfigSchema, + icons: LegacyAdmonitionConfigSchema, + infima: LegacyAdmonitionConfigSchema, + }).required(), + ) + .default(true) + .messages({ + 'alternatives.types': + '{{#label}} does not look like a valid admonitions config', + }); // TODO how can we make this emit a custom error message :'( // Joi is such a pain, good luck to annoying trying to improve this diff --git a/packages/docusaurus-utils-validation/tsconfig.json b/packages/docusaurus-utils-validation/tsconfig.json index 7807612b51a5..69bd9341b47e 100644 --- a/packages/docusaurus-utils-validation/tsconfig.json +++ b/packages/docusaurus-utils-validation/tsconfig.json @@ -6,7 +6,6 @@ "tsBuildInfoFile": "./lib/.tsbuildinfo", "sourceMap": true, "declarationMap": true, - "module": "commonjs", "rootDir": "src", "outDir": "lib" }, diff --git a/packages/docusaurus-utils/package.json b/packages/docusaurus-utils/package.json index f4c1f954d68a..f378e85e118c 100644 --- a/packages/docusaurus-utils/package.json +++ b/packages/docusaurus-utils/package.json @@ -32,7 +32,7 @@ "shelljs": "^0.8.5", "tslib": "^2.4.0", "url-loader": "^4.1.1", - "webpack": "^5.72.1" + "webpack": "^5.73.0" }, "engines": { "node": ">=16.14" diff --git a/packages/docusaurus-utils/src/__tests__/i18nUtils.test.ts b/packages/docusaurus-utils/src/__tests__/i18nUtils.test.ts index c0a458d3a8ec..55c0b52e7c47 100644 --- a/packages/docusaurus-utils/src/__tests__/i18nUtils.test.ts +++ b/packages/docusaurus-utils/src/__tests__/i18nUtils.test.ts @@ -65,34 +65,33 @@ describe('getPluginI18nPath', () => { it('gets correct path', () => { expect( getPluginI18nPath({ - siteDir: __dirname, - locale: 'zh-Hans', + localizationDir: '/i18n/zh-Hans', pluginName: 'plugin-content-docs', pluginId: 'community', subPaths: ['foo'], }), ).toMatchInlineSnapshot( - `"/packages/docusaurus-utils/src/__tests__/i18n/zh-Hans/plugin-content-docs-community/foo"`, + `"/i18n/zh-Hans/plugin-content-docs-community/foo"`, ); }); it('gets correct path for default plugin', () => { expect( getPluginI18nPath({ - siteDir: __dirname, - locale: 'zh-Hans', + localizationDir: '/i18n/zh-Hans', pluginName: 'plugin-content-docs', subPaths: ['foo'], - }).replace(__dirname, ''), - ).toMatchInlineSnapshot(`"/i18n/zh-Hans/plugin-content-docs/foo"`); + }), + ).toMatchInlineSnapshot( + `"/i18n/zh-Hans/plugin-content-docs/foo"`, + ); }); it('gets correct path when no sub-paths', () => { expect( getPluginI18nPath({ - siteDir: __dirname, - locale: 'zh-Hans', + localizationDir: '/i18n/zh-Hans', pluginName: 'plugin-content-docs', - }).replace(__dirname, ''), - ).toMatchInlineSnapshot(`"/i18n/zh-Hans/plugin-content-docs"`); + }), + ).toMatchInlineSnapshot(`"/i18n/zh-Hans/plugin-content-docs"`); }); }); @@ -104,6 +103,7 @@ describe('localizePath', () => { path: '/baseUrl', i18n: { defaultLocale: 'en', + path: 'i18n', locales: ['en', 'fr'], currentLocale: 'fr', localeConfigs: {}, @@ -120,9 +120,10 @@ describe('localizePath', () => { path: '/baseFsPath', i18n: { defaultLocale: 'en', + path: 'i18n', locales: ['en', 'fr'], currentLocale: 'fr', - localeConfigs: {}, + localeConfigs: {fr: {path: 'fr'}, en: {path: 'en'}}, }, options: {localizePath: true}, }), @@ -136,9 +137,10 @@ describe('localizePath', () => { path: '/baseUrl/', i18n: { defaultLocale: 'en', + path: 'i18n', locales: ['en', 'fr'], currentLocale: 'en', - localeConfigs: {}, + localeConfigs: {fr: {path: 'fr'}, en: {path: 'en'}}, }, options: {localizePath: true}, }), @@ -152,9 +154,10 @@ describe('localizePath', () => { path: '/baseUrl/', i18n: { defaultLocale: 'en', + path: 'i18n', locales: ['en', 'fr'], currentLocale: 'en', - localeConfigs: {}, + localeConfigs: {fr: {path: 'fr'}, en: {path: 'en'}}, }, }), ).toBe('/baseUrl/'); @@ -167,9 +170,10 @@ describe('localizePath', () => { path: '/baseUrl/', i18n: { defaultLocale: 'en', + path: 'i18n', locales: ['en', 'fr'], currentLocale: 'en', - localeConfigs: {}, + localeConfigs: {fr: {path: 'fr'}, en: {path: 'en'}}, }, }), ).toBe('/baseUrl/'); diff --git a/packages/docusaurus-utils/src/__tests__/markdownUtils.test.ts b/packages/docusaurus-utils/src/__tests__/markdownUtils.test.ts index 2f4baa74ccd6..42df2a38d4f1 100644 --- a/packages/docusaurus-utils/src/__tests__/markdownUtils.test.ts +++ b/packages/docusaurus-utils/src/__tests__/markdownUtils.test.ts @@ -833,6 +833,53 @@ describe('parseMarkdownHeadingId', () => { id: 'id', }); }); + + it('does not parse empty id', () => { + expect(parseMarkdownHeadingId('## a {#}')).toEqual({ + text: '## a {#}', + id: undefined, + }); + }); + + it('can parse id with more characters', () => { + expect(parseMarkdownHeadingId('## a {#你好}')).toEqual({ + text: '## a', + id: '你好', + }); + + expect(parseMarkdownHeadingId('## a {#2022.1.1}')).toEqual({ + text: '## a', + id: '2022.1.1', + }); + + expect(parseMarkdownHeadingId('## a {#a#b}')).toEqual({ + text: '## a', + id: 'a#b', + }); + }); + + // The actual behavior is unspecified, just need to ensure it stays consistent + it('handles unmatched boundaries', () => { + expect(parseMarkdownHeadingId('## a {# a {#bcd}')).toEqual({ + text: '## a {# a', + id: 'bcd', + }); + + expect(parseMarkdownHeadingId('## a {#bcd}}')).toEqual({ + text: '## a {#bcd}}', + id: undefined, + }); + + expect(parseMarkdownHeadingId('## a {#b{cd}')).toEqual({ + text: '## a', + id: 'b{cd', + }); + + expect(parseMarkdownHeadingId('## a {#b{#b}')).toEqual({ + text: '## a {#b', + id: 'b', + }); + }); }); describe('writeMarkdownHeadingId', () => { diff --git a/packages/docusaurus-utils/src/constants.ts b/packages/docusaurus-utils/src/constants.ts index 9f8c452669bb..6ecba7aea0f5 100644 --- a/packages/docusaurus-utils/src/constants.ts +++ b/packages/docusaurus-utils/src/constants.ts @@ -75,7 +75,7 @@ export const THEME_PATH = `${SRC_DIR_NAME}/theme`; * All translation-related data live here, relative to site directory. Content * will be namespaced by locale. */ -export const I18N_DIR_NAME = 'i18n'; +export const DEFAULT_I18N_DIR_NAME = 'i18n'; /** * Translations for React code. diff --git a/packages/docusaurus-utils/src/i18nUtils.ts b/packages/docusaurus-utils/src/i18nUtils.ts index a6d08cf83749..15723648d72a 100644 --- a/packages/docusaurus-utils/src/i18nUtils.ts +++ b/packages/docusaurus-utils/src/i18nUtils.ts @@ -7,7 +7,7 @@ import path from 'path'; import _ from 'lodash'; -import {DEFAULT_PLUGIN_ID, I18N_DIR_NAME} from './constants'; +import {DEFAULT_PLUGIN_ID} from './constants'; import {normalizeUrl} from './urlUtils'; import type { TranslationFileContent, @@ -46,24 +46,18 @@ export function updateTranslationFileMessages( * expect everything it needs for translations to be found under this path. */ export function getPluginI18nPath({ - siteDir, - locale, + localizationDir, pluginName, pluginId = DEFAULT_PLUGIN_ID, subPaths = [], }: { - siteDir: string; - locale: string; + localizationDir: string; pluginName: string; pluginId?: string | undefined; subPaths?: string[]; }): string { return path.join( - siteDir, - I18N_DIR_NAME, - // Namespace first by locale: convenient to work in a single folder for a - // translator - locale, + localizationDir, // Make it convenient to use for single-instance // ie: return "docs", not "docs-default" nor "docs/default" `${pluginName}${pluginId === DEFAULT_PLUGIN_ID ? '' : `-${pluginId}`}`, @@ -74,6 +68,9 @@ export function getPluginI18nPath({ /** * Takes a path and returns a localized a version (which is basically `path + * i18n.currentLocale`). + * + * This is used to resolve the `outDir` and `baseUrl` of each locale; it is NOT + * used to determine plugin localization file locations. */ export function localizePath({ pathType, @@ -100,13 +97,15 @@ export function localizePath({ }; }): string { const shouldLocalizePath: boolean = - // options.localizePath ?? i18n.currentLocale !== i18n.defaultLocale; if (!shouldLocalizePath) { return originalPath; } - // FS paths need special care, for Windows support + // FS paths need special care, for Windows support. Note: we don't use the + // locale config's `path` here, because this function is used for resolving + // outDir, which must be the same as baseUrl. When we have the baseUrl config, + // we need to sync the two. if (pathType === 'fs') { return path.join(originalPath, i18n.currentLocale); } diff --git a/packages/docusaurus-utils/src/index.ts b/packages/docusaurus-utils/src/index.ts index 520f5f73aab2..30549ba99c03 100644 --- a/packages/docusaurus-utils/src/index.ts +++ b/packages/docusaurus-utils/src/index.ts @@ -17,7 +17,7 @@ export { DEFAULT_STATIC_DIR_NAME, OUTPUT_STATIC_ASSETS_DIR_NAME, THEME_PATH, - I18N_DIR_NAME, + DEFAULT_I18N_DIR_NAME, CODE_TRANSLATIONS_FILE_NAME, DEFAULT_PORT, DEFAULT_PLUGIN_ID, diff --git a/packages/docusaurus-utils/src/markdownUtils.ts b/packages/docusaurus-utils/src/markdownUtils.ts index fd11f5e66708..512a09bf916d 100644 --- a/packages/docusaurus-utils/src/markdownUtils.ts +++ b/packages/docusaurus-utils/src/markdownUtils.ts @@ -14,8 +14,8 @@ import {createSlugger, type Slugger, type SluggerOptions} from './slugger'; // content. Most parsing is still done in MDX through the mdx-loader. /** - * Parses custom ID from a heading. The ID must be composed of letters, - * underscores, and dashes only. + * Parses custom ID from a heading. The ID can contain any characters except + * `{#` and `}`. * * @param heading e.g. `## Some heading {#some-heading}` where the last * character must be `}` for the ID to be recognized @@ -26,9 +26,9 @@ export function parseMarkdownHeadingId(heading: string): { */ text: string; /** The heading ID. e.g. `some-heading` */ - id?: string; + id: string | undefined; } { - const customHeadingIdRegex = /\s*\{#(?[\w-]+)\}$/; + const customHeadingIdRegex = /\s*\{#(?(?:.(?!\{#|\}))*.)\}$/; const matches = customHeadingIdRegex.exec(heading); if (matches) { return { diff --git a/packages/docusaurus-utils/tsconfig.json b/packages/docusaurus-utils/tsconfig.json index 7807612b51a5..69bd9341b47e 100644 --- a/packages/docusaurus-utils/tsconfig.json +++ b/packages/docusaurus-utils/tsconfig.json @@ -6,7 +6,6 @@ "tsBuildInfoFile": "./lib/.tsbuildinfo", "sourceMap": true, "declarationMap": true, - "module": "commonjs", "rootDir": "src", "outDir": "lib" }, diff --git a/packages/docusaurus/README.md b/packages/docusaurus/README.md index e69de29bb2d1..d86354231163 100644 --- a/packages/docusaurus/README.md +++ b/packages/docusaurus/README.md @@ -0,0 +1 @@ +# Docusaurus core diff --git a/packages/docusaurus/bin/docusaurus.mjs b/packages/docusaurus/bin/docusaurus.mjs index 8ae3d348ecf6..928dbe9c8f02 100755 --- a/packages/docusaurus/bin/docusaurus.mjs +++ b/packages/docusaurus/bin/docusaurus.mjs @@ -8,7 +8,6 @@ // @ts-check -import fs from 'fs-extra'; import logger from '@docusaurus/logger'; import cli from 'commander'; import {DOCUSAURUS_VERSION} from '@docusaurus/utils'; @@ -27,8 +26,6 @@ import beforeCli from './beforeCli.mjs'; await beforeCli(); -const resolveDir = (dir = '.') => fs.realpath(dir); - cli.version(DOCUSAURUS_VERSION).usage(' [options]'); cli @@ -54,9 +51,9 @@ cli '--no-minify', 'build website without minimizing JS bundles (default: false)', ) - .action(async (siteDir, options) => { - build(await resolveDir(siteDir), options); - }); + // @ts-expect-error: Promise is not assignable to Promise... but + // good enough here. + .action(build); cli .command('swizzle [themeName] [componentName] [siteDir]') @@ -80,9 +77,7 @@ cli 'copy TypeScript theme files when possible (default: false)', ) .option('--danger', 'enable swizzle for unsafe component of themes') - .action(async (themeName, componentName, siteDir, options) => - swizzle(await resolveDir(siteDir), themeName, componentName, options), - ); + .action(swizzle); cli .command('deploy [siteDir]') @@ -103,9 +98,7 @@ cli '--skip-build', 'skip building website before deploy it (default: false)', ) - .action(async (siteDir, options) => - deploy(await resolveDir(siteDir), options), - ); + .action(deploy); cli .command('start [siteDir]') @@ -130,9 +123,7 @@ cli '--no-minify', 'build website without minimizing JS bundles (default: false)', ) - .action(async (siteDir, options) => - start(await resolveDir(siteDir), options), - ); + .action(start); cli .command('serve [siteDir]') @@ -152,14 +143,12 @@ cli '--no-open', 'do not open page in the browser (default: false, or true in CI)', ) - .action(async (siteDir, options) => - serve(await resolveDir(siteDir), options), - ); + .action(serve); cli .command('clear [siteDir]') .description('Remove build artifacts.') - .action(async (siteDir) => clear(await resolveDir(siteDir))); + .action(clear); cli .command('write-translations [siteDir]') @@ -180,9 +169,7 @@ cli '--messagePrefix ', 'Allows to init new written messages with a given prefix. This might help you to highlight untranslated message by making them stand out in the UI (default: "")', ) - .action(async (siteDir, options) => - writeTranslations(await resolveDir(siteDir), options), - ); + .action(writeTranslations); cli .command('write-heading-ids [siteDir] [files...]') @@ -192,9 +179,7 @@ cli "keep the headings' casing, otherwise make all lowercase (default: false)", ) .option('--overwrite', 'overwrite existing heading IDs (default: false)') - .action(async (siteDir, files, options) => - writeHeadingIds(await resolveDir(siteDir), files, options), - ); + .action(writeHeadingIds); cli.arguments('').action((cmd) => { cli.outputHelp(); @@ -221,7 +206,7 @@ function isInternalCommand(command) { } if (!isInternalCommand(process.argv.slice(2)[0])) { - await externalCommand(cli, await resolveDir('.')); + await externalCommand(cli); } if (!process.argv.slice(2).length) { diff --git a/packages/docusaurus/package.json b/packages/docusaurus/package.json index 40218c38797a..0a332500b798 100644 --- a/packages/docusaurus/package.json +++ b/packages/docusaurus/package.json @@ -50,7 +50,7 @@ "@docusaurus/utils": "2.0.0-beta.21", "@docusaurus/utils-common": "2.0.0-beta.21", "@docusaurus/utils-validation": "2.0.0-beta.21", - "@slorber/static-site-generator-webpack-plugin": "^4.0.4", + "@slorber/static-site-generator-webpack-plugin": "^4.0.7", "@svgr/webpack": "^6.2.1", "autoprefixer": "^10.4.7", "babel-loader": "^8.2.5", @@ -63,10 +63,10 @@ "combine-promises": "^1.1.0", "commander": "^5.1.0", "copy-webpack-plugin": "^11.0.0", - "core-js": "^3.22.7", + "core-js": "^3.22.8", "css-loader": "^6.7.1", "css-minimizer-webpack-plugin": "^4.0.0", - "cssnano": "^5.1.9", + "cssnano": "^5.1.11", "del": "^6.1.1", "detect-port": "^1.3.0", "escape-html": "^1.0.3", @@ -90,19 +90,18 @@ "react-router": "^5.3.3", "react-router-config": "^5.1.1", "react-router-dom": "^5.3.3", - "remark-admonitions": "^1.2.1", "rtl-detect": "^1.0.4", "semver": "^7.3.7", "serve-handler": "^6.1.3", "shelljs": "^0.8.5", - "terser-webpack-plugin": "^5.3.1", + "terser-webpack-plugin": "^5.3.3", "tslib": "^2.4.0", "update-notifier": "^5.1.0", "url-loader": "^4.1.1", "wait-on": "^6.0.1", - "webpack": "^5.72.1", + "webpack": "^5.73.0", "webpack-bundle-analyzer": "^4.5.0", - "webpack-dev-server": "^4.9.0", + "webpack-dev-server": "^4.9.2", "webpack-merge": "^5.8.0", "webpackbar": "^5.0.2" }, diff --git a/packages/docusaurus/src/client/PendingNavigation.tsx b/packages/docusaurus/src/client/PendingNavigation.tsx index e1e38f40f817..3c1eaaf0dae3 100644 --- a/packages/docusaurus/src/client/PendingNavigation.tsx +++ b/packages/docusaurus/src/client/PendingNavigation.tsx @@ -70,7 +70,13 @@ class PendingNavigation extends React.Component { this.routeUpdateCleanupCb(); this.setState({nextRouteHasLoaded: true}); }) - .catch((e: unknown) => console.warn(e)); + .catch((e: unknown) => { + console.warn(e); + // If chunk loading failed, it could be because the path to a chunk + // no longer exists due to a new deployment. Force refresh the page + // instead of just not navigating. + window.location.reload(); + }); return false; } diff --git a/packages/docusaurus/src/client/exports/ComponentCreator.tsx b/packages/docusaurus/src/client/exports/ComponentCreator.tsx index 476d73febcf9..33c0f4c90a6d 100644 --- a/packages/docusaurus/src/client/exports/ComponentCreator.tsx +++ b/packages/docusaurus/src/client/exports/ComponentCreator.tsx @@ -132,7 +132,7 @@ export default function ComponentCreator( // Is there any way to put this RouteContextProvider upper in the tree? return ( - + ); }, diff --git a/packages/docusaurus/src/client/serverEntry.tsx b/packages/docusaurus/src/client/serverEntry.tsx index 528a0a96e3a8..f353c05bfdbd 100644 --- a/packages/docusaurus/src/client/serverEntry.tsx +++ b/packages/docusaurus/src/client/serverEntry.tsx @@ -142,6 +142,10 @@ async function doRender(locals: Locals & {path: string}) { }); try { + if (process.env.SKIP_HTML_MINIFICATION === 'true') { + return renderedHtml; + } + // Minify html with https://github.com/DanielRuf/html-minifier-terser return await minify(renderedHtml, { removeComments: false, diff --git a/packages/docusaurus/src/commands/build.ts b/packages/docusaurus/src/commands/build.ts index d13d7039fec5..92c20e6398d2 100644 --- a/packages/docusaurus/src/commands/build.ts +++ b/packages/docusaurus/src/commands/build.ts @@ -38,14 +38,16 @@ export type BuildCLIOptions = Pick< }; export async function build( - siteDir: string, - cliOptions: Partial, + siteDirParam: string = '.', + cliOptions: Partial = {}, // When running build, we force terminate the process to prevent async // operations from never returning. However, if run as part of docusaurus // deploy, we have to let deploy finish. // See https://github.com/facebook/docusaurus/pull/2496 forceTerminate: boolean = true, ): Promise { + const siteDir = await fs.realpath(siteDirParam); + ['SIGINT', 'SIGTERM'].forEach((sig) => { process.on(sig, () => process.exit()); }); diff --git a/packages/docusaurus/src/commands/clear.ts b/packages/docusaurus/src/commands/clear.ts index 450b2f9e8751..1b8b7169c66a 100644 --- a/packages/docusaurus/src/commands/clear.ts +++ b/packages/docusaurus/src/commands/clear.ts @@ -26,7 +26,9 @@ async function removePath(entry: {path: string; description: string}) { } } -export async function clear(siteDir: string): Promise { +export async function clear(siteDirParam: string = '.'): Promise { + const siteDir = await fs.realpath(siteDirParam); + const generatedFolder = { path: path.join(siteDir, GENERATED_FILES_DIR_NAME), description: 'generated folder', diff --git a/packages/docusaurus/src/commands/deploy.ts b/packages/docusaurus/src/commands/deploy.ts index 9b5f233f5bf4..90d6f9cc5ee7 100644 --- a/packages/docusaurus/src/commands/deploy.ts +++ b/packages/docusaurus/src/commands/deploy.ts @@ -41,9 +41,11 @@ function shellExecLog(cmd: string) { } export async function deploy( - siteDir: string, - cliOptions: Partial, + siteDirParam: string = '.', + cliOptions: Partial = {}, ): Promise { + const siteDir = await fs.realpath(siteDirParam); + const {outDir, siteConfig, siteConfigPath} = await loadContext({ siteDir, config: cliOptions.config, diff --git a/packages/docusaurus/src/commands/external.ts b/packages/docusaurus/src/commands/external.ts index 2a9f67ee288b..45ae8d55d11c 100644 --- a/packages/docusaurus/src/commands/external.ts +++ b/packages/docusaurus/src/commands/external.ts @@ -5,14 +5,13 @@ * LICENSE file in the root directory of this source tree. */ +import fs from 'fs-extra'; import {loadContext} from '../server'; import {initPlugins} from '../server/plugins/init'; import type {CommanderStatic} from 'commander'; -export async function externalCommand( - cli: CommanderStatic, - siteDir: string, -): Promise { +export async function externalCommand(cli: CommanderStatic): Promise { + const siteDir = await fs.realpath('.'); const context = await loadContext({siteDir}); const plugins = await initPlugins(context); diff --git a/packages/docusaurus/src/commands/serve.ts b/packages/docusaurus/src/commands/serve.ts index 0eb24b677f1b..19f4f322a8bd 100644 --- a/packages/docusaurus/src/commands/serve.ts +++ b/packages/docusaurus/src/commands/serve.ts @@ -5,6 +5,7 @@ * LICENSE file in the root directory of this source tree. */ +import fs from 'fs-extra'; import http from 'http'; import path from 'path'; import logger from '@docusaurus/logger'; @@ -24,9 +25,11 @@ export type ServeCLIOptions = HostPortOptions & }; export async function serve( - siteDir: string, - cliOptions: Partial, + siteDirParam: string = '.', + cliOptions: Partial = {}, ): Promise { + const siteDir = await fs.realpath(siteDirParam); + const buildDir = cliOptions.dir ?? DEFAULT_BUILD_DIR_NAME; let dir = path.resolve(siteDir, buildDir); diff --git a/packages/docusaurus/src/commands/start.ts b/packages/docusaurus/src/commands/start.ts index f49874839d68..849ee610bf4f 100644 --- a/packages/docusaurus/src/commands/start.ts +++ b/packages/docusaurus/src/commands/start.ts @@ -5,6 +5,7 @@ * LICENSE file in the root directory of this source tree. */ +import fs from 'fs-extra'; import path from 'path'; import _ from 'lodash'; import logger from '@docusaurus/logger'; @@ -25,7 +26,6 @@ import { getHttpsConfig, } from '../webpack/utils'; import {getHostPort, type HostPortOptions} from '../server/getHostPort'; -import {getTranslationsLocaleDirPath} from '../server/translations/translations'; export type StartCLIOptions = HostPortOptions & Pick & { @@ -36,9 +36,11 @@ export type StartCLIOptions = HostPortOptions & }; export async function start( - siteDir: string, - cliOptions: Partial, + siteDirParam: string = '.', + cliOptions: Partial = {}, ): Promise { + const siteDir = await fs.realpath(siteDirParam); + process.env.NODE_ENV = 'development'; process.env.BABEL_ENV = 'development'; logger.info('Starting the development server...'); @@ -82,7 +84,7 @@ export async function start( logger.error(err.stack); }); }, 500); - const {siteConfig, plugins} = props; + const {siteConfig, plugins, localizationDir} = props; const normalizeToSiteDir = (filepath: string) => { if (filepath && path.isAbsolute(filepath)) { @@ -96,14 +98,7 @@ export async function start( .filter(Boolean) .map(normalizeToSiteDir); - const pathsToWatch = [ - ...pluginPaths, - props.siteConfigPath, - getTranslationsLocaleDirPath({ - siteDir, - locale: props.i18n.currentLocale, - }), - ]; + const pathsToWatch = [...pluginPaths, props.siteConfigPath, localizationDir]; const pollingOptions = { usePolling: !!cliOptions.poll, 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 2608fd767172..a6aa55acc13b 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 @@ -43,11 +43,12 @@ export default function FirstLevelComponentWrapper(props) { `; exports[`wrap TypeScript wrap ComponentInFolder 2`] = ` -"import React, {ComponentProps} from 'react'; +"import React from 'react'; import ComponentInFolder from '@theme-original/ComponentInFolder'; import type ComponentInFolderType from '@theme/ComponentInFolder'; +import type {WrapperProps} from '@docusaurus/types'; -type Props = ComponentProps; +type Props = WrapperProps; export default function ComponentInFolderWrapper(props: Props): JSX.Element { return ( @@ -60,11 +61,12 @@ export default function ComponentInFolderWrapper(props: Props): JSX.Element { `; exports[`wrap TypeScript wrap ComponentInFolder/ComponentInSubFolder 2`] = ` -"import React, {ComponentProps} from 'react'; +"import React from 'react'; import ComponentInSubFolder from '@theme-original/ComponentInFolder/ComponentInSubFolder'; import type ComponentInSubFolderType from '@theme/ComponentInFolder/ComponentInSubFolder'; +import type {WrapperProps} from '@docusaurus/types'; -type Props = ComponentProps; +type Props = WrapperProps; export default function ComponentInSubFolderWrapper(props: Props): JSX.Element { return ( @@ -77,11 +79,12 @@ export default function ComponentInSubFolderWrapper(props: Props): JSX.Element { `; exports[`wrap TypeScript wrap FirstLevelComponent 2`] = ` -"import React, {ComponentProps} from 'react'; +"import React from 'react'; import FirstLevelComponent from '@theme-original/FirstLevelComponent'; import type FirstLevelComponentType from '@theme/FirstLevelComponent'; +import type {WrapperProps} from '@docusaurus/types'; -type Props = ComponentProps; +type Props = WrapperProps; export default function FirstLevelComponentWrapper(props: Props): JSX.Element { return ( 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 a686e30fae35..31fa888fe07c 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 @@ -273,11 +273,12 @@ exports[`swizzle wrap ComponentInFolder JS: theme dir tree 1`] = ` `; exports[`swizzle wrap ComponentInFolder TS: ComponentInFolder/index.tsx 1`] = ` -"import React, {ComponentProps} from 'react'; +"import React from 'react'; import ComponentInFolder from '@theme-original/ComponentInFolder'; import type ComponentInFolderType from '@theme/ComponentInFolder'; +import type {WrapperProps} from '@docusaurus/types'; -type Props = ComponentProps; +type Props = WrapperProps; export default function ComponentInFolderWrapper(props: Props): JSX.Element { return ( @@ -317,11 +318,12 @@ 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 React from 'react'; import ComponentInSubFolder from '@theme-original/ComponentInFolder/ComponentInSubFolder'; import type ComponentInSubFolderType from '@theme/ComponentInFolder/ComponentInSubFolder'; +import type {WrapperProps} from '@docusaurus/types'; -type Props = ComponentProps; +type Props = WrapperProps; export default function ComponentInSubFolderWrapper(props: Props): JSX.Element { return ( @@ -361,11 +363,12 @@ 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 React from 'react'; import Sibling from '@theme-original/ComponentInFolder/Sibling'; import type SiblingType from '@theme/ComponentInFolder/Sibling'; +import type {WrapperProps} from '@docusaurus/types'; -type Props = ComponentProps; +type Props = WrapperProps; export default function SiblingWrapper(props: Props): JSX.Element { return ( @@ -403,11 +406,12 @@ exports[`swizzle wrap FirstLevelComponent JS: theme dir tree 1`] = ` `; exports[`swizzle wrap FirstLevelComponent TS: FirstLevelComponent.tsx 1`] = ` -"import React, {ComponentProps} from 'react'; +"import React from 'react'; import FirstLevelComponent from '@theme-original/FirstLevelComponent'; import type FirstLevelComponentType from '@theme/FirstLevelComponent'; +import type {WrapperProps} from '@docusaurus/types'; -type Props = ComponentProps; +type Props = WrapperProps; export default function FirstLevelComponentWrapper(props: Props): JSX.Element { return ( diff --git a/packages/docusaurus/src/commands/swizzle/__tests__/index.test.ts b/packages/docusaurus/src/commands/swizzle/__tests__/index.test.ts index 462c44c1a09e..ee57ee4bfd25 100644 --- a/packages/docusaurus/src/commands/swizzle/__tests__/index.test.ts +++ b/packages/docusaurus/src/commands/swizzle/__tests__/index.test.ts @@ -111,7 +111,7 @@ async function createTestSite() { component: string; typescript?: boolean; }) { - return swizzleWithExit(siteDir, FixtureThemeName, component, { + return swizzleWithExit(FixtureThemeName, component, siteDir, { wrap: true, danger: true, typescript, @@ -125,7 +125,7 @@ async function createTestSite() { component: string; typescript?: boolean; }) { - return swizzleWithExit(siteDir, FixtureThemeName, component, { + return swizzleWithExit(FixtureThemeName, component, siteDir, { eject: true, danger: true, typescript, diff --git a/packages/docusaurus/src/commands/swizzle/actions.ts b/packages/docusaurus/src/commands/swizzle/actions.ts index 44aba75cca13..3bc38febcd75 100644 --- a/packages/docusaurus/src/commands/swizzle/actions.ts +++ b/packages/docusaurus/src/commands/swizzle/actions.ts @@ -121,11 +121,12 @@ export async function wrap({ const toPath = path.resolve(siteDir, THEME_PATH, wrapperFileName); const content = typescript - ? `import React, {ComponentProps} from 'react'; + ? `import React from 'react'; import ${componentName} from '@theme-${importType}/${themeComponentName}'; import type ${componentName}Type from '@theme/${themeComponentName}'; +import type {WrapperProps} from '@docusaurus/types'; -type Props = ComponentProps; +type Props = WrapperProps; export default function ${wrapperComponentName}(props: Props): JSX.Element { return ( diff --git a/packages/docusaurus/src/commands/swizzle/index.ts b/packages/docusaurus/src/commands/swizzle/index.ts index 9262e7d154f1..df5e06605511 100644 --- a/packages/docusaurus/src/commands/swizzle/index.ts +++ b/packages/docusaurus/src/commands/swizzle/index.ts @@ -5,6 +5,7 @@ * LICENSE file in the root directory of this source tree. */ +import fs from 'fs-extra'; import logger from '@docusaurus/logger'; import {getThemeName, getThemePath, getThemeNames} from './themes'; import {getThemeComponents, getComponentName} from './components'; @@ -87,11 +88,13 @@ If you want to swizzle it, use the code=${'--danger'} flag, or confirm that you } export async function swizzle( - siteDir: string, - themeNameParam: string | undefined, - componentNameParam: string | undefined, - optionsParam: Partial, + themeNameParam: string | undefined = undefined, + componentNameParam: string | undefined = undefined, + siteDirParam: string = '.', + optionsParam: Partial = {}, ): Promise { + const siteDir = await fs.realpath(siteDirParam); + const options = normalizeOptions(optionsParam); const {list, danger, typescript} = options; diff --git a/packages/docusaurus/src/commands/writeHeadingIds.ts b/packages/docusaurus/src/commands/writeHeadingIds.ts index 73bc699c25b3..864708620780 100644 --- a/packages/docusaurus/src/commands/writeHeadingIds.ts +++ b/packages/docusaurus/src/commands/writeHeadingIds.ts @@ -41,10 +41,12 @@ async function getPathsToWatch(siteDir: string): Promise { } export async function writeHeadingIds( - siteDir: string, - files: string[] | undefined, - options: WriteHeadingIDOptions, + siteDirParam: string = '.', + files: string[] = [], + options: WriteHeadingIDOptions = {}, ): Promise { + const siteDir = await fs.realpath(siteDirParam); + const markdownFiles = await safeGlobby( files ?? (await getPathsToWatch(siteDir)), { diff --git a/packages/docusaurus/src/commands/writeTranslations.ts b/packages/docusaurus/src/commands/writeTranslations.ts index 14ae1e64adc6..6bda39cd5776 100644 --- a/packages/docusaurus/src/commands/writeTranslations.ts +++ b/packages/docusaurus/src/commands/writeTranslations.ts @@ -5,6 +5,7 @@ * LICENSE file in the root directory of this source tree. */ +import fs from 'fs-extra'; import path from 'path'; import {loadContext, type LoadContextOptions} from '../server'; import {initPlugins} from '../server/plugins/init'; @@ -47,14 +48,12 @@ async function getExtraSourceCodeFilePaths(): Promise { } async function writePluginTranslationFiles({ - siteDir, + localizationDir, plugin, - locale, options, }: { - siteDir: string; + localizationDir: string; plugin: InitializedPlugin; - locale: string; options: WriteTranslationsOptions; }) { if (plugin.getTranslationFiles) { @@ -66,10 +65,9 @@ async function writePluginTranslationFiles({ await Promise.all( translationFiles.map(async (translationFile) => { await writePluginTranslations({ - siteDir, + localizationDir, plugin, translationFile, - locale, options, }); }), @@ -78,14 +76,17 @@ async function writePluginTranslationFiles({ } export async function writeTranslations( - siteDir: string, - options: Partial, + siteDirParam: string = '.', + options: Partial = {}, ): Promise { + const siteDir = await fs.realpath(siteDirParam); + const context = await loadContext({ siteDir, config: options.config, locale: options.locale, }); + const {localizationDir} = context; const plugins = await initPlugins(context); const locale = options.locale ?? context.i18n.defaultLocale; @@ -116,11 +117,11 @@ Available locales are: ${context.i18n.locales.join(',')}.`, defaultCodeMessages, }); - await writeCodeTranslations({siteDir, locale}, codeTranslations, options); + await writeCodeTranslations({localizationDir}, codeTranslations, options); await Promise.all( plugins.map(async (plugin) => { - await writePluginTranslationFiles({siteDir, plugin, locale, options}); + await writePluginTranslationFiles({localizationDir, plugin, options}); }), ); } diff --git a/packages/docusaurus/src/deps.d.ts b/packages/docusaurus/src/deps.d.ts index 57de485ea0ce..49bca18d06f9 100644 --- a/packages/docusaurus/src/deps.d.ts +++ b/packages/docusaurus/src/deps.d.ts @@ -5,8 +5,6 @@ * LICENSE file in the root directory of this source tree. */ -declare module 'remark-admonitions'; - declare module 'react-loadable-ssr-addon-v5-slorber' { import type {WebpackPluginInstance, Compiler} from 'webpack'; @@ -64,6 +62,7 @@ declare module '@slorber/static-site-generator-webpack-plugin' { paths: string[]; preferFoldersOutput?: boolean; globals: {[key: string]: unknown}; + concurrency?: number; }); apply(compiler: Compiler): void; } @@ -74,3 +73,22 @@ declare module 'webpack/lib/HotModuleReplacementPlugin' { export default HotModuleReplacementPlugin; } + +// TODO incompatible declaration file: https://github.com/unjs/webpackbar/pull/108 +declare module 'webpackbar' { + import webpack from 'webpack'; + + export default class WebpackBarPlugin extends webpack.ProgressPlugin { + constructor(options: {name: string; color?: string}); + } +} + +// TODO incompatible declaration file +declare module 'eta' { + export const defaultConfig: object; + + export function compile( + template: string, + options?: object, + ): (data: object, config: object) => string; +} diff --git a/packages/docusaurus/src/server/__tests__/__fixtures__/custom-i18n-site/docusaurus.config.js b/packages/docusaurus/src/server/__tests__/__fixtures__/custom-i18n-site/docusaurus.config.js new file mode 100644 index 000000000000..4fea46c9bf0d --- /dev/null +++ b/packages/docusaurus/src/server/__tests__/__fixtures__/custom-i18n-site/docusaurus.config.js @@ -0,0 +1,17 @@ +module.exports = { + title: 'Site', + url: 'https://example.com', + baseUrl: '/', + i18n: { + locales: ['en', 'zh-Hans'], + defaultLocale: 'en', + localeConfigs: { + en: { + path: 'en-custom' + }, + 'zh-Hans': { + path: 'zh-Hans-custom' + } + } + } +}; diff --git a/packages/docusaurus/src/server/__tests__/__snapshots__/config.test.ts.snap b/packages/docusaurus/src/server/__tests__/__snapshots__/config.test.ts.snap index 2c20bb59c885..64dfeff98eea 100644 --- a/packages/docusaurus/src/server/__tests__/__snapshots__/config.test.ts.snap +++ b/packages/docusaurus/src/server/__tests__/__snapshots__/config.test.ts.snap @@ -13,6 +13,7 @@ exports[`loadSiteConfig website with .cjs siteConfig 1`] = ` "locales": [ "en", ], + "path": "i18n", }, "noIndex": false, "onBrokenLinks": "throw", @@ -49,6 +50,7 @@ exports[`loadSiteConfig website with valid async config 1`] = ` "locales": [ "en", ], + "path": "i18n", }, "noIndex": false, "onBrokenLinks": "throw", @@ -87,6 +89,7 @@ exports[`loadSiteConfig website with valid async config creator function 1`] = ` "locales": [ "en", ], + "path": "i18n", }, "noIndex": false, "onBrokenLinks": "throw", @@ -125,6 +128,7 @@ exports[`loadSiteConfig website with valid config creator function 1`] = ` "locales": [ "en", ], + "path": "i18n", }, "noIndex": false, "onBrokenLinks": "throw", @@ -166,6 +170,7 @@ exports[`loadSiteConfig website with valid siteConfig 1`] = ` "locales": [ "en", ], + "path": "i18n", }, "noIndex": false, "onBrokenLinks": "throw", diff --git a/packages/docusaurus/src/server/__tests__/__snapshots__/index.test.ts.snap b/packages/docusaurus/src/server/__tests__/__snapshots__/index.test.ts.snap new file mode 100644 index 000000000000..fb73309cd272 --- /dev/null +++ b/packages/docusaurus/src/server/__tests__/__snapshots__/index.test.ts.snap @@ -0,0 +1,118 @@ +// Jest Snapshot v1, https://goo.gl/fbAQLP + +exports[`load loads props for site with custom i18n path 1`] = ` +{ + "baseUrl": "/", + "codeTranslations": {}, + "generatedFilesDir": "/packages/docusaurus/src/server/__tests__/__fixtures__/custom-i18n-site/.docusaurus", + "headTags": "", + "i18n": { + "currentLocale": "en", + "defaultLocale": "en", + "localeConfigs": { + "en": { + "calendar": "gregory", + "direction": "ltr", + "htmlLang": "en", + "label": "English", + "path": "en-custom", + }, + "zh-Hans": { + "calendar": "gregory", + "direction": "ltr", + "htmlLang": "zh-Hans", + "label": "简体中文", + "path": "zh-Hans-custom", + }, + }, + "locales": [ + "en", + "zh-Hans", + ], + "path": "i18n", + }, + "localizationDir": "/packages/docusaurus/src/server/__tests__/__fixtures__/custom-i18n-site/i18n/en-custom", + "outDir": "/packages/docusaurus/src/server/__tests__/__fixtures__/custom-i18n-site/build", + "plugins": [ + { + "content": undefined, + "getClientModules": [Function], + "injectHtmlTags": [Function], + "name": "docusaurus-bootstrap-plugin", + "options": { + "id": "default", + }, + "path": "/packages/docusaurus/src/server/__tests__/__fixtures__/custom-i18n-site", + "version": { + "type": "synthetic", + }, + }, + { + "configureWebpack": [Function], + "content": undefined, + "name": "docusaurus-mdx-fallback-plugin", + "options": { + "id": "default", + }, + "path": ".", + "version": { + "type": "synthetic", + }, + }, + ], + "postBodyTags": "", + "preBodyTags": "", + "routes": [], + "routesPaths": [ + "/404.html", + ], + "siteConfig": { + "baseUrl": "/", + "baseUrlIssueBanner": true, + "clientModules": [], + "customFields": {}, + "i18n": { + "defaultLocale": "en", + "localeConfigs": { + "en": { + "direction": "ltr", + "path": "en-custom", + }, + "zh-Hans": { + "direction": "ltr", + "path": "zh-Hans-custom", + }, + }, + "locales": [ + "en", + "zh-Hans", + ], + "path": "i18n", + }, + "noIndex": false, + "onBrokenLinks": "throw", + "onBrokenMarkdownLinks": "warn", + "onDuplicateRoutes": "warn", + "plugins": [], + "presets": [], + "scripts": [], + "staticDirectories": [ + "static", + ], + "stylesheets": [], + "tagline": "", + "themeConfig": {}, + "themes": [], + "title": "Site", + "titleDelimiter": "|", + "url": "https://example.com", + }, + "siteConfigPath": "/packages/docusaurus/src/server/__tests__/__fixtures__/custom-i18n-site/docusaurus.config.js", + "siteDir": "/packages/docusaurus/src/server/__tests__/__fixtures__/custom-i18n-site", + "siteMetadata": { + "docusaurusVersion": "", + "pluginVersions": {}, + "siteVersion": undefined, + }, +} +`; diff --git a/packages/docusaurus/src/server/__tests__/i18n.test.ts b/packages/docusaurus/src/server/__tests__/i18n.test.ts index 84e1e83ada2d..e846f942f527 100644 --- a/packages/docusaurus/src/server/__tests__/i18n.test.ts +++ b/packages/docusaurus/src/server/__tests__/i18n.test.ts @@ -8,7 +8,7 @@ import {jest} from '@jest/globals'; import {loadI18n, getDefaultLocaleConfig} from '../i18n'; import {DEFAULT_I18N_CONFIG} from '../configValidation'; -import type {I18nConfig} from '@docusaurus/types'; +import type {DocusaurusConfig, I18nConfig} from '@docusaurus/types'; function testLocaleConfigsFor(locales: string[]) { return Object.fromEntries( @@ -18,10 +18,9 @@ function testLocaleConfigsFor(locales: string[]) { function loadI18nTest(i18nConfig: I18nConfig, locale?: string) { return loadI18n( - // @ts-expect-error: enough for this test { i18n: i18nConfig, - }, + } as DocusaurusConfig, {locale}, ); } @@ -33,42 +32,49 @@ describe('defaultLocaleConfig', () => { direction: 'ltr', htmlLang: 'fr', calendar: 'gregory', + path: 'fr', }); expect(getDefaultLocaleConfig('fr-FR')).toEqual({ label: 'Français (France)', direction: 'ltr', htmlLang: 'fr-FR', calendar: 'gregory', + path: 'fr-FR', }); expect(getDefaultLocaleConfig('en')).toEqual({ label: 'English', direction: 'ltr', htmlLang: 'en', calendar: 'gregory', + path: 'en', }); expect(getDefaultLocaleConfig('en-US')).toEqual({ label: 'American English', direction: 'ltr', htmlLang: 'en-US', calendar: 'gregory', + path: 'en-US', }); expect(getDefaultLocaleConfig('zh')).toEqual({ label: '中文', direction: 'ltr', htmlLang: 'zh', calendar: 'gregory', + path: 'zh', }); expect(getDefaultLocaleConfig('zh-CN')).toEqual({ label: '中文(中国)', direction: 'ltr', htmlLang: 'zh-CN', calendar: 'gregory', + path: 'zh-CN', }); expect(getDefaultLocaleConfig('en-US')).toEqual({ label: 'American English', direction: 'ltr', htmlLang: 'en-US', calendar: 'gregory', + path: 'en-US', }); expect(getDefaultLocaleConfig('fa')).toEqual({ // cSpell:ignore فارسی @@ -76,6 +82,7 @@ describe('defaultLocaleConfig', () => { direction: 'rtl', htmlLang: 'fa', calendar: 'gregory', + path: 'fa', }); expect(getDefaultLocaleConfig('fa-IR')).toEqual({ // cSpell:ignore ایران فارسیا @@ -83,12 +90,14 @@ describe('defaultLocaleConfig', () => { direction: 'rtl', htmlLang: 'fa-IR', calendar: 'gregory', + path: 'fa-IR', }); expect(getDefaultLocaleConfig('en-US-u-ca-buddhist')).toEqual({ label: 'American English', direction: 'ltr', htmlLang: 'en-US-u-ca-buddhist', calendar: 'buddhist', + path: 'en-US-u-ca-buddhist', }); }); }); @@ -101,6 +110,7 @@ describe('loadI18n', () => { it('loads I18n for default config', async () => { await expect(loadI18nTest(DEFAULT_I18N_CONFIG)).resolves.toEqual({ + path: 'i18n', defaultLocale: 'en', locales: ['en'], currentLocale: 'en', @@ -111,12 +121,14 @@ describe('loadI18n', () => { it('loads I18n for multi-lang config', async () => { await expect( loadI18nTest({ + path: 'i18n', defaultLocale: 'fr', locales: ['en', 'fr', 'de'], localeConfigs: {}, }), ).resolves.toEqual({ defaultLocale: 'fr', + path: 'i18n', locales: ['en', 'fr', 'de'], currentLocale: 'fr', localeConfigs: testLocaleConfigsFor(['en', 'fr', 'de']), @@ -127,6 +139,7 @@ describe('loadI18n', () => { await expect( loadI18nTest( { + path: 'i18n', defaultLocale: 'fr', locales: ['en', 'fr', 'de'], localeConfigs: {}, @@ -135,6 +148,7 @@ describe('loadI18n', () => { ), ).resolves.toEqual({ defaultLocale: 'fr', + path: 'i18n', locales: ['en', 'fr', 'de'], currentLocale: 'de', localeConfigs: testLocaleConfigsFor(['en', 'fr', 'de']), @@ -145,6 +159,7 @@ describe('loadI18n', () => { await expect( loadI18nTest( { + path: 'i18n', defaultLocale: 'fr', locales: ['en', 'fr', 'de'], localeConfigs: { @@ -156,6 +171,7 @@ describe('loadI18n', () => { ), ).resolves.toEqual({ defaultLocale: 'fr', + path: 'i18n', locales: ['en', 'fr', 'de'], currentLocale: 'de', localeConfigs: { @@ -164,6 +180,7 @@ describe('loadI18n', () => { direction: 'ltr', htmlLang: 'fr', calendar: 'gregory', + path: 'fr', }, en: getDefaultLocaleConfig('en'), de: getDefaultLocaleConfig('de'), @@ -174,6 +191,7 @@ describe('loadI18n', () => { it('warns when trying to load undeclared locale', async () => { await loadI18nTest( { + path: 'i18n', defaultLocale: 'fr', locales: ['en', 'fr', 'de'], localeConfigs: {}, diff --git a/packages/docusaurus/src/server/__tests__/index.test.ts b/packages/docusaurus/src/server/__tests__/index.test.ts new file mode 100644 index 000000000000..28bdc3f265e3 --- /dev/null +++ b/packages/docusaurus/src/server/__tests__/index.test.ts @@ -0,0 +1,45 @@ +/** + * 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 path from 'path'; +import {mergeWithCustomize} from 'webpack-merge'; +import {loadSetup} from './testUtils'; +import type {Props} from '@docusaurus/types'; +import type {DeepPartial} from 'utility-types'; + +describe('load', () => { + it('loads props for site with custom i18n path', async () => { + const props = await loadSetup('custom-i18n-site'); + expect(props).toMatchSnapshot(); + const props2 = await loadSetup('custom-i18n-site', {locale: 'zh-Hans'}); + expect(props2).toEqual( + mergeWithCustomize>({ + customizeArray(a, b, key) { + return ['routesPaths', 'plugins'].includes(key) ? b : undefined; + }, + })(props, { + baseUrl: '/zh-Hans/', + i18n: { + currentLocale: 'zh-Hans', + }, + localizationDir: path.join( + __dirname, + '__fixtures__/custom-i18n-site/i18n/zh-Hans-custom', + ), + outDir: path.join( + __dirname, + '__fixtures__/custom-i18n-site/build/zh-Hans', + ), + routesPaths: ['/zh-Hans/404.html'], + siteConfig: { + baseUrl: '/zh-Hans/', + }, + plugins: props2.plugins, + }), + ); + }); +}); diff --git a/packages/docusaurus/src/server/__tests__/testUtils.ts b/packages/docusaurus/src/server/__tests__/testUtils.ts index 1d42d255f9e8..c295f05dad51 100644 --- a/packages/docusaurus/src/server/__tests__/testUtils.ts +++ b/packages/docusaurus/src/server/__tests__/testUtils.ts @@ -6,20 +6,14 @@ */ import path from 'path'; -import {load} from '../index'; +import {load, type LoadContextOptions} from '../index'; import type {Props} from '@docusaurus/types'; // Helper methods to setup dummy/fake projects. -export default async function loadSetup(name: string): Promise { +export async function loadSetup( + name: string, + options?: Partial, +): Promise { const fixtures = path.join(__dirname, '__fixtures__'); - const simpleSite = path.join(fixtures, 'simple-site'); - const customSite = path.join(fixtures, 'custom-site'); - - switch (name) { - case 'custom': - return load({siteDir: customSite}); - case 'simple': - default: - return load({siteDir: simpleSite}); - } + return load({siteDir: path.join(fixtures, name), ...options}); } diff --git a/packages/docusaurus/src/server/configValidation.ts b/packages/docusaurus/src/server/configValidation.ts index 15a66776b19d..d63749680487 100644 --- a/packages/docusaurus/src/server/configValidation.ts +++ b/packages/docusaurus/src/server/configValidation.ts @@ -5,7 +5,10 @@ * LICENSE file in the root directory of this source tree. */ -import {DEFAULT_STATIC_DIR_NAME} from '@docusaurus/utils'; +import { + DEFAULT_STATIC_DIR_NAME, + DEFAULT_I18N_DIR_NAME, +} from '@docusaurus/utils'; import {Joi, URISchema, printWarning} from '@docusaurus/utils-validation'; import type {DocusaurusConfig, I18nConfig} from '@docusaurus/types'; @@ -13,6 +16,7 @@ const DEFAULT_I18N_LOCALE = 'en'; export const DEFAULT_I18N_CONFIG: I18nConfig = { defaultLocale: DEFAULT_I18N_LOCALE, + path: DEFAULT_I18N_DIR_NAME, locales: [DEFAULT_I18N_LOCALE], localeConfigs: {}, }; @@ -131,10 +135,12 @@ const LocaleConfigSchema = Joi.object({ htmlLang: Joi.string(), direction: Joi.string().equal('ltr', 'rtl').default('ltr'), calendar: Joi.string(), + path: Joi.string(), }); const I18N_CONFIG_SCHEMA = Joi.object({ defaultLocale: Joi.string().required(), + path: Joi.string().default(DEFAULT_I18N_CONFIG.path), locales: Joi.array().items().min(1).items(Joi.string().required()).required(), localeConfigs: Joi.object() .pattern(/.*/, LocaleConfigSchema) diff --git a/packages/docusaurus/src/server/i18n.ts b/packages/docusaurus/src/server/i18n.ts index cd9bbe4990ea..92292f2ec5f7 100644 --- a/packages/docusaurus/src/server/i18n.ts +++ b/packages/docusaurus/src/server/i18n.ts @@ -26,6 +26,7 @@ export function getDefaultLocaleConfig(locale: string): I18nLocaleConfig { htmlLang: locale, // If the locale name includes -u-ca-xxx the calendar will be defined calendar: new Intl.Locale(locale).calendar ?? 'gregory', + path: locale, }; } @@ -60,6 +61,7 @@ Note: Docusaurus only support running one locale at a time.`; return { defaultLocale: i18nConfig.defaultLocale, locales, + path: i18nConfig.path, currentLocale, localeConfigs, }; diff --git a/packages/docusaurus/src/server/index.ts b/packages/docusaurus/src/server/index.ts index 90908237b04f..914752004715 100644 --- a/packages/docusaurus/src/server/index.ts +++ b/packages/docusaurus/src/server/index.ts @@ -85,11 +85,14 @@ export async function loadContext( const siteConfig: DocusaurusConfig = {...initialSiteConfig, baseUrl}; + const localizationDir = path.resolve( + siteDir, + i18n.path, + i18n.localeConfigs[i18n.currentLocale]!.path, + ); + const codeTranslationFileContent = - (await readCodeTranslationFileContent({ - siteDir, - locale: i18n.currentLocale, - })) ?? {}; + (await readCodeTranslationFileContent({localizationDir})) ?? {}; // We only need key->message for code translations const codeTranslations = _.mapValues( @@ -100,6 +103,7 @@ export async function loadContext( return { siteDir, generatedFilesDir, + localizationDir, siteConfig, siteConfigPath, outDir, @@ -125,6 +129,7 @@ export async function load(options: LoadContextOptions): Promise { outDir, baseUrl, i18n, + localizationDir, codeTranslations: siteCodeTranslations, } = context; const {plugins, pluginsRouteConfigs, globalData} = await loadPlugins(context); @@ -145,6 +150,7 @@ export async function load(options: LoadContextOptions): Promise { const genWarning = generate( generatedFilesDir, + // cSpell:ignore DONT 'DONT-EDIT-THIS-FOLDER', `This folder stores temp files that Docusaurus' client bundler accesses. @@ -246,6 +252,7 @@ ${Object.entries(registry) outDir, baseUrl, i18n, + localizationDir, generatedFilesDir, routes: pluginsRouteConfigs, routesPaths, diff --git a/packages/docusaurus/src/server/plugins/index.ts b/packages/docusaurus/src/server/plugins/index.ts index 5a8dbb98d095..73fba212b289 100644 --- a/packages/docusaurus/src/server/plugins/index.ts +++ b/packages/docusaurus/src/server/plugins/index.ts @@ -56,8 +56,7 @@ export async function loadPlugins(context: LoadContext): Promise<{ const translationFiles = await Promise.all( rawTranslationFiles.map((translationFile) => localizePluginTranslationFile({ - locale: context.i18n.currentLocale, - siteDir: context.siteDir, + localizationDir: context.localizationDir, translationFile, plugin, }), diff --git a/packages/docusaurus/src/server/plugins/synthetic.ts b/packages/docusaurus/src/server/plugins/synthetic.ts index 5d4fe38b4d01..10425a29478d 100644 --- a/packages/docusaurus/src/server/plugins/synthetic.ts +++ b/packages/docusaurus/src/server/plugins/synthetic.ts @@ -6,7 +6,6 @@ */ import path from 'path'; -import admonitions from 'remark-admonitions'; import type {RuleSetRule} from 'webpack'; import type {HtmlTagObject, LoadedPlugin, LoadContext} from '@docusaurus/types'; @@ -97,6 +96,7 @@ export function createMDXFallbackPlugin({ }); } const mdxLoaderOptions = { + admonitions: true, staticDirs: siteConfig.staticDirectories.map((dir) => path.resolve(siteDir, dir), ), @@ -105,7 +105,6 @@ export function createMDXFallbackPlugin({ isMDXPartial: () => true, // External MDX files might have front matter, just disable the warning isMDXPartialFrontMatterWarningDisabled: true, - remarkPlugins: [admonitions], }; return { diff --git a/packages/docusaurus/src/server/translations/__tests__/translations.test.ts b/packages/docusaurus/src/server/translations/__tests__/translations.test.ts index 1e1b59aad85f..a62aae849802 100644 --- a/packages/docusaurus/src/server/translations/__tests__/translations.test.ts +++ b/packages/docusaurus/src/server/translations/__tests__/translations.test.ts @@ -44,8 +44,10 @@ async function createTmpTranslationFile( } return { - siteDir, - readFile: () => fs.readJSON(filePath), + localizationDir: path.join(siteDir, 'i18n/en'), + readFile() { + return fs.readJSON(filePath); + }, }; } @@ -58,9 +60,9 @@ describe('writeCodeTranslations', () => { }); it('creates new translation file', async () => { - const {siteDir, readFile} = await createTmpTranslationFile(null); + const {localizationDir, readFile} = await createTmpTranslationFile(null); await writeCodeTranslations( - {siteDir, locale: 'en'}, + {localizationDir}, { key1: {message: 'key1 message'}, key2: {message: 'key2 message'}, @@ -80,9 +82,9 @@ describe('writeCodeTranslations', () => { }); it('creates new translation file with prefix', async () => { - const {siteDir, readFile} = await createTmpTranslationFile(null); + const {localizationDir, readFile} = await createTmpTranslationFile(null); await writeCodeTranslations( - {siteDir, locale: 'en'}, + {localizationDir}, { key1: {message: 'key1 message'}, key2: {message: 'key2 message'}, @@ -104,14 +106,14 @@ describe('writeCodeTranslations', () => { }); it('appends missing translations', async () => { - const {siteDir, readFile} = await createTmpTranslationFile({ + const {localizationDir, readFile} = await createTmpTranslationFile({ key1: {message: 'key1 message'}, key2: {message: 'key2 message'}, key3: {message: 'key3 message'}, }); await writeCodeTranslations( - {siteDir, locale: 'en'}, + {localizationDir}, { key1: {message: 'key1 message new'}, key2: {message: 'key2 message new'}, @@ -133,12 +135,12 @@ describe('writeCodeTranslations', () => { }); it('appends missing.* translations with prefix', async () => { - const {siteDir, readFile} = await createTmpTranslationFile({ + const {localizationDir, readFile} = await createTmpTranslationFile({ key1: {message: 'key1 message'}, }); await writeCodeTranslations( - {siteDir, locale: 'en'}, + {localizationDir}, { key1: {message: 'key1 message new'}, key2: {message: 'key2 message new'}, @@ -158,12 +160,12 @@ describe('writeCodeTranslations', () => { }); it('overrides missing translations', async () => { - const {siteDir, readFile} = await createTmpTranslationFile({ + const {localizationDir, readFile} = await createTmpTranslationFile({ key1: {message: 'key1 message'}, }); await writeCodeTranslations( - {siteDir, locale: 'en'}, + {localizationDir}, { key1: {message: 'key1 message new'}, key2: {message: 'key2 message new'}, @@ -183,12 +185,12 @@ describe('writeCodeTranslations', () => { }); it('overrides missing translations with prefix', async () => { - const {siteDir, readFile} = await createTmpTranslationFile({ + const {localizationDir, readFile} = await createTmpTranslationFile({ key1: {message: 'key1 message'}, }); await writeCodeTranslations( - {siteDir, locale: 'en'}, + {localizationDir}, { key1: {message: 'key1 message new'}, key2: {message: 'key2 message new'}, @@ -209,14 +211,14 @@ describe('writeCodeTranslations', () => { }); it('always overrides message description', async () => { - const {siteDir, readFile} = await createTmpTranslationFile({ + const {localizationDir, readFile} = await createTmpTranslationFile({ key1: {message: 'key1 message', description: 'key1 desc'}, key2: {message: 'key2 message', description: 'key2 desc'}, key3: {message: 'key3 message', description: undefined}, }); await writeCodeTranslations( - {siteDir, locale: 'en'}, + {localizationDir}, { key1: {message: 'key1 message new', description: undefined}, key2: {message: 'key2 message new', description: 'key2 desc new'}, @@ -236,9 +238,9 @@ describe('writeCodeTranslations', () => { }); it('does not create empty translation files', async () => { - const {siteDir, readFile} = await createTmpTranslationFile(null); + const {localizationDir, readFile} = await createTmpTranslationFile(null); - await writeCodeTranslations({siteDir, locale: 'en'}, {}, {}); + await writeCodeTranslations({localizationDir}, {}, {}); await expect(readFile()).rejects.toThrowError( /ENOENT: no such file or directory, open /, @@ -247,14 +249,14 @@ describe('writeCodeTranslations', () => { }); it('throws for invalid content', async () => { - const {siteDir} = await createTmpTranslationFile( + const {localizationDir} = await createTmpTranslationFile( // @ts-expect-error: bad content on purpose {bad: 'content'}, ); await expect(() => writeCodeTranslations( - {siteDir, locale: 'en'}, + {localizationDir}, { key1: {message: 'key1 message'}, }, @@ -269,19 +271,16 @@ describe('writeCodeTranslations', () => { describe('writePluginTranslations', () => { it('writes plugin translations', async () => { - const siteDir = await createTmpSiteDir(); + const localizationDir = await createTmpSiteDir(); const filePath = path.join( - siteDir, - 'i18n', - 'fr', + localizationDir, 'my-plugin-name', 'my/translation/file.json', ); await writePluginTranslations({ - siteDir, - locale: 'fr', + localizationDir, translationFile: { path: 'my/translation/file', content: { @@ -306,12 +305,10 @@ describe('writePluginTranslations', () => { }); it('writes plugin translations consecutively with different options', async () => { - const siteDir = await createTmpSiteDir(); + const localizationDir = await createTmpSiteDir(); const filePath = path.join( - siteDir, - 'i18n', - 'fr', + localizationDir, 'my-plugin-name-my-plugin-id', 'my/translation/file.json', ); @@ -321,7 +318,7 @@ describe('writePluginTranslations', () => { options?: WriteTranslationsOptions, ) { return writePluginTranslations({ - siteDir, + localizationDir, locale: 'fr', translationFile: { path: 'my/translation/file', @@ -381,12 +378,11 @@ describe('writePluginTranslations', () => { }); it('throws with explicit extension', async () => { - const siteDir = await createTmpSiteDir(); + const localizationDir = await createTmpSiteDir(); await expect(() => writePluginTranslations({ - siteDir, - locale: 'fr', + localizationDir, translationFile: { path: 'my/translation/file.json', content: {}, @@ -409,7 +405,7 @@ describe('writePluginTranslations', () => { describe('localizePluginTranslationFile', () => { it('does not localize if localized file does not exist', async () => { - const siteDir = await createTmpSiteDir(); + const localizationDir = await createTmpSiteDir(); const translationFile: TranslationFile = { path: 'my/translation/file', @@ -421,8 +417,7 @@ describe('localizePluginTranslationFile', () => { }; const localizedTranslationFile = await localizePluginTranslationFile({ - siteDir, - locale: 'fr', + localizationDir, translationFile, plugin: { name: 'my-plugin-name', @@ -434,16 +429,10 @@ describe('localizePluginTranslationFile', () => { }); it('normalizes partially localized translation files', async () => { - const siteDir = await createTmpSiteDir(); + const localizationDir = await createTmpSiteDir(); await fs.outputJSON( - path.join( - siteDir, - 'i18n', - 'fr', - 'my-plugin-name', - 'my/translation/file.json', - ), + path.join(localizationDir, 'my-plugin-name', 'my/translation/file.json'), { key2: {message: 'key2 message localized'}, key4: {message: 'key4 message localized'}, @@ -460,8 +449,7 @@ describe('localizePluginTranslationFile', () => { }; const localizedTranslationFile = await localizePluginTranslationFile({ - siteDir, - locale: 'fr', + localizationDir, translationFile, plugin: { name: 'my-plugin-name', @@ -486,13 +474,13 @@ describe('localizePluginTranslationFile', () => { describe('readCodeTranslationFileContent', () => { async function testReadTranslation(val: TranslationFileContent) { - const {siteDir} = await createTmpTranslationFile(val); - return readCodeTranslationFileContent({siteDir, locale: 'en'}); + const {localizationDir} = await createTmpTranslationFile(val); + return readCodeTranslationFileContent({localizationDir}); } it("returns undefined if file does't exist", async () => { await expect( - readCodeTranslationFileContent({siteDir: 'foo', locale: 'en'}), + readCodeTranslationFileContent({localizationDir: 'foo'}), ).resolves.toBeUndefined(); }); diff --git a/packages/docusaurus/src/server/translations/translations.ts b/packages/docusaurus/src/server/translations/translations.ts index fd3fb0305523..83d19495bffc 100644 --- a/packages/docusaurus/src/server/translations/translations.ts +++ b/packages/docusaurus/src/server/translations/translations.ts @@ -12,7 +12,6 @@ import logger from '@docusaurus/logger'; import { getPluginI18nPath, toMessageRelativeFilePath, - I18N_DIR_NAME, CODE_TRANSLATIONS_FILE_NAME, } from '@docusaurus/utils'; import {Joi} from '@docusaurus/utils-validation'; @@ -29,8 +28,7 @@ export type WriteTranslationsOptions = { }; type TranslationContext = { - siteDir: string; - locale: string; + localizationDir: string; }; const TranslationFileContentSchema = Joi.object() @@ -143,18 +141,8 @@ Maybe you should remove them? ${unknownKeys}`; } } -// Should we make this configurable? -export function getTranslationsLocaleDirPath( - context: TranslationContext, -): string { - return path.join(context.siteDir, I18N_DIR_NAME, context.locale); -} - function getCodeTranslationsFilePath(context: TranslationContext): string { - return path.join( - getTranslationsLocaleDirPath(context), - CODE_TRANSLATIONS_FILE_NAME, - ); + return path.join(context.localizationDir, CODE_TRANSLATIONS_FILE_NAME); } export async function readCodeTranslationFileContent( @@ -187,17 +175,15 @@ function addTranslationFileExtension(translationFilePath: string) { } function getPluginTranslationFilePath({ - siteDir, + localizationDir, plugin, - locale, translationFilePath, }: TranslationContext & { plugin: InitializedPlugin; translationFilePath: string; }): string { const dirPath = getPluginI18nPath({ - siteDir, - locale, + localizationDir, pluginName: plugin.name, pluginId: plugin.options.id, }); @@ -206,9 +192,8 @@ function getPluginTranslationFilePath({ } export async function writePluginTranslations({ - siteDir, + localizationDir, plugin, - locale, translationFile, options, }: TranslationContext & { @@ -218,8 +203,7 @@ export async function writePluginTranslations({ }): Promise { const filePath = getPluginTranslationFilePath({ plugin, - siteDir, - locale, + localizationDir, translationFilePath: translationFile.path, }); await writeTranslationFileContent({ @@ -230,9 +214,8 @@ export async function writePluginTranslations({ } export async function localizePluginTranslationFile({ - siteDir, + localizationDir, plugin, - locale, translationFile, }: TranslationContext & { plugin: InitializedPlugin; @@ -240,8 +223,7 @@ export async function localizePluginTranslationFile({ }): Promise { const filePath = getPluginTranslationFilePath({ plugin, - siteDir, - locale, + localizationDir, translationFilePath: translationFile.path, }); diff --git a/packages/docusaurus/src/webpack/__tests__/client.test.ts b/packages/docusaurus/src/webpack/__tests__/client.test.ts index 87c825eb9802..f4dd21733779 100644 --- a/packages/docusaurus/src/webpack/__tests__/client.test.ts +++ b/packages/docusaurus/src/webpack/__tests__/client.test.ts @@ -8,18 +8,18 @@ import webpack from 'webpack'; import createClientConfig from '../client'; -import loadSetup from '../../server/__tests__/testUtils'; +import {loadSetup} from '../../server/__tests__/testUtils'; describe('webpack dev config', () => { it('simple', async () => { - const props = await loadSetup('simple'); + const props = await loadSetup('simple-site'); const config = await createClientConfig(props); const errors = webpack.validate(config); expect(errors).toBeUndefined(); }); it('custom', async () => { - const props = await loadSetup('custom'); + const props = await loadSetup('custom-site'); const config = await createClientConfig(props); const errors = webpack.validate(config); expect(errors).toBeUndefined(); diff --git a/packages/docusaurus/src/webpack/__tests__/server.test.ts b/packages/docusaurus/src/webpack/__tests__/server.test.ts index f3207fdc2fe2..7d7c57cfab48 100644 --- a/packages/docusaurus/src/webpack/__tests__/server.test.ts +++ b/packages/docusaurus/src/webpack/__tests__/server.test.ts @@ -9,12 +9,12 @@ import {jest} from '@jest/globals'; import webpack from 'webpack'; import createServerConfig from '../server'; -import loadSetup from '../../server/__tests__/testUtils'; +import {loadSetup} from '../../server/__tests__/testUtils'; describe('webpack production config', () => { it('simple', async () => { jest.spyOn(console, 'log').mockImplementation(() => {}); - const props = await loadSetup('simple'); + const props = await loadSetup('simple-site'); const config = await createServerConfig({ props, onHeadTagsCollected: () => {}, @@ -26,7 +26,7 @@ describe('webpack production config', () => { it('custom', async () => { jest.spyOn(console, 'log').mockImplementation(() => {}); - const props = await loadSetup('custom'); + const props = await loadSetup('custom-site'); const config = await createServerConfig({ props, onHeadTagsCollected: () => {}, diff --git a/packages/docusaurus/src/webpack/server.ts b/packages/docusaurus/src/webpack/server.ts index 7f93c86a4bb9..4942ed5c0c76 100644 --- a/packages/docusaurus/src/webpack/server.ts +++ b/packages/docusaurus/src/webpack/server.ts @@ -90,6 +90,12 @@ export default async function createServerConfig({ // has any importance for this plugin, just using an empty string to // avoid the error. See https://github.com/facebook/docusaurus/issues/4922 globals: {__filename: ''}, + + // Secret way to set SSR plugin concurrency option + // Waiting for feedback before documenting this officially? + concurrency: process.env.DOCUSAURUS_SSR_CONCURRENCY + ? parseInt(process.env.DOCUSAURUS_SSR_CONCURRENCY, 10) + : undefined, }), // Show compilation progress bar. diff --git a/packages/docusaurus/tsconfig.json b/packages/docusaurus/tsconfig.json index f547aea00fff..80dfc91440a4 100644 --- a/packages/docusaurus/tsconfig.json +++ b/packages/docusaurus/tsconfig.json @@ -7,8 +7,7 @@ "compilerOptions": { "noEmit": true, "checkJs": true, - "rootDir": ".", - "module": "esnext" + "rootDir": "." }, "include": ["bin"], "exclude": ["**/__tests__/**"] diff --git a/packages/docusaurus/tsconfig.server.json b/packages/docusaurus/tsconfig.server.json index f800ce6a5fe5..e26c376455c3 100644 --- a/packages/docusaurus/tsconfig.server.json +++ b/packages/docusaurus/tsconfig.server.json @@ -5,7 +5,6 @@ "composite": true, "incremental": true, "tsBuildInfoFile": "./lib/.tsbuildinfo", - "module": "commonjs", "rootDir": "src", "outDir": "lib" }, diff --git a/packages/eslint-plugin/package.json b/packages/eslint-plugin/package.json index f8a2e7e1c7cf..27f1c12b52f6 100644 --- a/packages/eslint-plugin/package.json +++ b/packages/eslint-plugin/package.json @@ -21,7 +21,7 @@ "build": "tsc" }, "dependencies": { - "@typescript-eslint/utils": "^5.26.0", + "@typescript-eslint/utils": "^5.27.1", "tslib": "^2.4.0" }, "devDependencies": { diff --git a/packages/eslint-plugin/tsconfig.json b/packages/eslint-plugin/tsconfig.json index 80e43e9813ef..e16d5c2c5d33 100644 --- a/packages/eslint-plugin/tsconfig.json +++ b/packages/eslint-plugin/tsconfig.json @@ -4,7 +4,6 @@ "noEmit": false, "incremental": true, "tsBuildInfoFile": "./lib/.tsbuildinfo", - "module": "commonjs", "rootDir": "src", "outDir": "lib" }, diff --git a/packages/lqip-loader/package.json b/packages/lqip-loader/package.json index 1ada06e07f96..dd190a10d634 100644 --- a/packages/lqip-loader/package.json +++ b/packages/lqip-loader/package.json @@ -20,7 +20,7 @@ "@docusaurus/logger": "2.0.0-beta.21", "file-loader": "^6.2.0", "lodash": "^4.17.21", - "sharp": "^0.30.5", + "sharp": "^0.30.6", "tslib": "^2.4.0" }, "engines": { @@ -28,6 +28,6 @@ }, "devDependencies": { "@types/file-loader": "^5.0.1", - "@types/sharp": "^0.30.2" + "@types/sharp": "^0.30.4" } } diff --git a/packages/lqip-loader/tsconfig.json b/packages/lqip-loader/tsconfig.json index 80e43e9813ef..e16d5c2c5d33 100644 --- a/packages/lqip-loader/tsconfig.json +++ b/packages/lqip-loader/tsconfig.json @@ -4,7 +4,6 @@ "noEmit": false, "incremental": true, "tsBuildInfoFile": "./lib/.tsbuildinfo", - "module": "commonjs", "rootDir": "src", "outDir": "lib" }, diff --git a/packages/stylelint-copyright/package.json b/packages/stylelint-copyright/package.json index b859ae13d44a..18aa9afe6e48 100644 --- a/packages/stylelint-copyright/package.json +++ b/packages/stylelint-copyright/package.json @@ -14,7 +14,7 @@ "directory": "packages/stylelint-copyright" }, "dependencies": { - "stylelint": "^14.8.5", + "stylelint": "^14.9.1", "tslib": "^2.4.0" } } diff --git a/packages/stylelint-copyright/tsconfig.json b/packages/stylelint-copyright/tsconfig.json index 80e43e9813ef..e16d5c2c5d33 100644 --- a/packages/stylelint-copyright/tsconfig.json +++ b/packages/stylelint-copyright/tsconfig.json @@ -4,7 +4,6 @@ "noEmit": false, "incremental": true, "tsBuildInfoFile": "./lib/.tsbuildinfo", - "module": "commonjs", "rootDir": "src", "outDir": "lib" }, diff --git a/project-words.txt b/project-words.txt index 9ca37195ee29..1267e271832b 100644 --- a/project-words.txt +++ b/project-words.txt @@ -50,6 +50,7 @@ contravariance corejs crawlable creativecommons +cssnano csvg customizability daishi @@ -196,6 +197,7 @@ nuxt onboarded opensearch opensearchdescription +opensource optimizt optind orta @@ -227,6 +229,7 @@ prefetch prefetching preloads prepended +preprocess preprocessors prerendered prerendering diff --git a/tsconfig.json b/tsconfig.json index 5a379450a1b0..f0b893d74fb8 100644 --- a/tsconfig.json +++ b/tsconfig.json @@ -11,8 +11,8 @@ "jsx": "react-native", "importHelpers": true, "noEmitHelpers": true, - // Will be overridden in every project - "module": "esnext", + // Will be overridden in client projects + "module": "NodeNext", // Avoid accidentally using this config to build "noEmit": true, @@ -42,7 +42,7 @@ "importsNotUsedAsValues": "remove", /* Module Resolution */ - "moduleResolution": "node", + "moduleResolution": "NodeNext", "resolveJsonModule": true, "allowSyntheticDefaultImports": true, "esModuleInterop": true, diff --git a/website/_dogfooding/README.md b/website/_dogfooding/README.md index 8acadfac2e9b..f0a8a5719c4f 100644 --- a/website/_dogfooding/README.md +++ b/website/_dogfooding/README.md @@ -15,4 +15,4 @@ Fancy things we can test for here: - \_ prefix convention - Huge sidebars impact - Using folders with spaces on purpose -- Importing md docs that are out of content plugin folders as partials (such as this README file!) +- Importing MD docs that are out of content plugin folders as partials (such as this README file!) diff --git a/website/_dogfooding/_docs tests/doc-with-last-update.md b/website/_dogfooding/_docs tests/doc-with-last-update.md new file mode 100644 index 000000000000..34c1cb0c7cb6 --- /dev/null +++ b/website/_dogfooding/_docs tests/doc-with-last-update.md @@ -0,0 +1,7 @@ +--- +last_update: + author: custom author + date: 1/1/2000 +--- + +# Doc With Last Update Front Matter diff --git a/website/_dogfooding/_docs tests/toc/toc-test-bad.mdx b/website/_dogfooding/_docs tests/toc/toc-test-bad.mdx index b894a0a17ec3..8f91e5217c31 100644 --- a/website/_dogfooding/_docs tests/toc/toc-test-bad.mdx +++ b/website/_dogfooding/_docs tests/toc/toc-test-bad.mdx @@ -3,7 +3,7 @@ toc_min_heading_level: 2 toc_max_heading_level: 6 --- -Test the TOC behavior of a real-world md doc with invalid headings +Test the TOC behavior of a real-world MD doc with invalid headings --- diff --git a/website/_dogfooding/_docs tests/toc/toc-test-good.mdx b/website/_dogfooding/_docs tests/toc/toc-test-good.mdx index 6f85a62fea2a..c8f9f4534224 100644 --- a/website/_dogfooding/_docs tests/toc/toc-test-good.mdx +++ b/website/_dogfooding/_docs tests/toc/toc-test-good.mdx @@ -3,7 +3,7 @@ toc_min_heading_level: 2 toc_max_heading_level: 6 --- -Test the TOC behavior of a real-world md doc with valid headings +Test the TOC behavior of a real-world MD doc with valid headings --- diff --git a/website/_dogfooding/_pages tests/code-block-tests.mdx b/website/_dogfooding/_pages tests/code-block-tests.mdx index d6f7c0816c20..44db91d49094 100644 --- a/website/_dogfooding/_pages tests/code-block-tests.mdx +++ b/website/_dogfooding/_pages tests/code-block-tests.mdx @@ -1,5 +1,7 @@ import CodeBlock from '@theme/CodeBlock'; import BrowserWindow from '@site/src/components/BrowserWindow'; +import Tabs from '@theme/Tabs'; +import TabItem from '@theme/TabItem'; # Code block tests @@ -190,3 +192,60 @@ function PageLayout(props) { ); } ``` + +## Code block wrapping tests + +[// spell-checker:disable]: # + +```bash +mkdir this_is_a_loooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooong_string_to_test_code_block_wrapping +echo "this is a long string made up of many separate words that should be broken between words when possible" +curl https://docusaurus.io/tests/pages/code-block-tests +``` + + + + + +```bash +echo "hi" +``` + + + + +```bash +echo this will test whether a long string that is initially hidden will have the option to wrap when made visible +``` + + + + + +```bash +rm short_initially_hidden_string +``` + + + + + + + + +```bash +echo medium_length_string_will_have_the_option_to_wrap_after_window_resized_while_it_is_hidden +``` + + + + + +```bash +echo "short_initially_hidden_string" +``` + + + + +[// spell-checker:enable]: # diff --git a/website/_dogfooding/_pages tests/index.md b/website/_dogfooding/_pages tests/index.md index cf94300fb891..d54f03fcd3f6 100644 --- a/website/_dogfooding/_pages tests/index.md +++ b/website/_dogfooding/_pages tests/index.md @@ -28,3 +28,4 @@ import Readme from "../README.md" - [General Markdown tests](/tests/pages/markdownPageTests) - [TOC tests](/tests/pages/page-toc-tests) - [Tabs tests](/tests/pages/tabs-tests) +- [z-index tests](/tests/pages/z-index-tests) diff --git a/website/_dogfooding/_pages tests/markdown-tests.md b/website/_dogfooding/_pages tests/markdown-tests.md index 80d9ea8bade0..48420cb718de 100644 --- a/website/_dogfooding/_pages tests/markdown-tests.md +++ b/website/_dogfooding/_pages tests/markdown-tests.md @@ -1,6 +1,6 @@ # Markdown tests -This is a test page to see if Docusaurus markdown features are working properly +This is a test page to see if Docusaurus Markdown features are working properly ## Linking to assets diff --git a/website/_dogfooding/_pages tests/markdownPageTests.md b/website/_dogfooding/_pages tests/markdownPageTests.md index dc8695b11179..323c741ee3e2 100644 --- a/website/_dogfooding/_pages tests/markdownPageTests.md +++ b/website/_dogfooding/_pages tests/markdownPageTests.md @@ -6,7 +6,7 @@ wrapperClassName: docusaurus-markdown-example # Markdown page tests -This is a page generated from markdown to illustrate the Markdown page feature and test some edge cases. +This is a page generated from Markdown to illustrate the Markdown page feature and test some edge cases. :::info @@ -160,7 +160,17 @@ function Clock(props) { } ``` -## Custom heading id {#custom} +## Custom heading ID {#custom} + +### Weird heading {#你好} + +### Weird heading {#2022.1.1} + +### Weird heading {#a#b} + +### Weird heading {#a b} + +### Weird heading {#a{b} ## Pipe @@ -221,3 +231,11 @@ Can be arbitrarily nested: - [ ] Task - [ ] Task - [ ] Task + +## Admonitions + +:::caution Interpolated `title` with a + +Admonition body + +::: diff --git a/website/_dogfooding/_pages tests/z-index-tests.tsx b/website/_dogfooding/_pages tests/z-index-tests.tsx new file mode 100644 index 000000000000..d1d076b89495 --- /dev/null +++ b/website/_dogfooding/_pages tests/z-index-tests.tsx @@ -0,0 +1,17 @@ +/** + * 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 React from 'react'; +import Layout from '@theme/Layout'; + +export default function zIndexTest(): JSX.Element { + return ( + +

This should have a z-index of 100

+
+ ); +} diff --git a/website/_dogfooding/clientModuleExample.ts b/website/_dogfooding/clientModuleExample.ts index cd61e5a99e81..e7b673e74e94 100644 --- a/website/_dogfooding/clientModuleExample.ts +++ b/website/_dogfooding/clientModuleExample.ts @@ -18,8 +18,8 @@ function logPage( prevLocation: previousLocation, heading: document.getElementsByTagName('h1')[0]?.innerText, title: document.title, - description: ( - document.querySelector('meta[name="description"]') as HTMLMetaElement + description: document.querySelector( + 'meta[name="description"]', )?.content, htmlClassName: document.getElementsByTagName('html')[0]?.className, }); diff --git a/website/_dogfooding/docs-tests-sidebars.js b/website/_dogfooding/docs-tests-sidebars.js index e7ebb55ce1a5..0c2783feeda3 100644 --- a/website/_dogfooding/docs-tests-sidebars.js +++ b/website/_dogfooding/docs-tests-sidebars.js @@ -22,6 +22,7 @@ const sidebars = { 'test-draft', 'doc-without-sidebar', 'doc-with-another-sidebar', + 'doc-with-last-update', { type: 'category', label: 'Tests', diff --git a/website/_dogfooding/dogfooding.config.js b/website/_dogfooding/dogfooding.config.js index b6239f787b42..f8a4e7007f0e 100644 --- a/website/_dogfooding/dogfooding.config.js +++ b/website/_dogfooding/dogfooding.config.js @@ -30,6 +30,7 @@ const dogfoodingPluginInstances = [ // Using a _ prefix to test against an edge case regarding MDX partials: https://github.com/facebook/docusaurus/discussions/5181#discussioncomment-1018079 path: '_dogfooding/_docs tests', showLastUpdateTime: true, + showLastUpdateAuthor: true, sidebarItemsGenerator(args) { return args.defaultSidebarItemsGenerator({ ...args, diff --git a/website/_dogfooding/dogfooding.css b/website/_dogfooding/dogfooding.css index be6cf970b6f9..f1864ef8fb82 100644 --- a/website/_dogfooding/dogfooding.css +++ b/website/_dogfooding/dogfooding.css @@ -20,3 +20,7 @@ html.plugin-blog.plugin-id-blog-tests .navbar { html.plugin-pages.plugin-id-pages-tests .navbar { border-bottom: solid thin yellow; } + +#z-index-test { + z-index: 100; +} diff --git a/website/blog/2017-12-14-introducing-docusaurus.md b/website/blog/2017-12-14-introducing-docusaurus.md index 309a8ba2c310..a882e2352a0e 100644 --- a/website/blog/2017-12-14-introducing-docusaurus.md +++ b/website/blog/2017-12-14-introducing-docusaurus.md @@ -17,7 +17,7 @@ We created [Docusaurus](https://docusaurus.io) for the following reasons: -Docusaurus is a tool designed to make it easy for teams to publish documentation websites without having to worry about the infrastructure and design details. At its core, all a user has to provide are documentation files written in markdown, customization of a provided home page written in React, and a few configuration modifications. Docusaurus handles the rest by providing default styles, site formatting, and simple document navigation. Getting started is easy, as users can [install](https://v1.docusaurus.io/docs/en/installation.html) it using `npm` or `yarn` via a simple initialization script that [creates a working example website out of the box](https://v1.docusaurus.io/docs/en/site-preparation.html). +Docusaurus is a tool designed to make it easy for teams to publish documentation websites without having to worry about the infrastructure and design details. At its core, all a user has to provide are documentation files written in Markdown, customization of a provided home page written in React, and a few configuration modifications. Docusaurus handles the rest by providing default styles, site formatting, and simple document navigation. Getting started is easy, as users can [install](https://v1.docusaurus.io/docs/en/installation.html) it using `npm` or `yarn` via a simple initialization script that [creates a working example website out of the box](https://v1.docusaurus.io/docs/en/site-preparation.html). Docusaurus also provides core website and documentation features out-of-the-box including [blog support](https://v1.docusaurus.io/docs/en/blog.html), [internationalization](https://v1.docusaurus.io/docs/en/translation.html), [search](https://v1.docusaurus.io/docs/en/search.html), and [versioning](https://v1.docusaurus.io/docs/en/versioning.html). While some projects may not require any of these features, enabling them is generally a matter of updating configuration options instead of having to add the infrastructure from the ground up. As more features get added to Docusaurus, users just can easily update to the latest version. This can be done by simply running npm or yarn update and updating configuration options. Users or teams will no longer need to manually rework their entire website infrastructure each time a new feature gets added. @@ -67,11 +67,11 @@ root-of-repo │ └── static ``` -With the exception of node_modules and package.json, all the directories and files you see are where you customize and add content to your Docusaurus-based website. The docs folder is where you add your markdown that represents your documentation; the blog folder is where you add your markdown for your [blog posts](https://v1.docusaurus.io/docs/en/blog.html); `siteConfig.js` is where you make most of the [customizations](https://v1.docusaurus.io/docs/en/site-config.html) for your site; `sidebars.json` is where you maintain the layout and content of the [sidebar](https://v1.docusaurus.io/docs/en/navigation.html) for your documentation; the `pages` folder is where you add [custom](https://v1.docusaurus.io/docs/en/custom-pages.html) pages for your site; the `static` folder is where all of your static assets go (e.g., CSS stylesheets and images); and the `core` folder is where you can customize core components of the site, in this case the footer. +With the exception of node_modules and package.json, all the directories and files you see are where you customize and add content to your Docusaurus-based website. The docs folder is where you add your Markdown that represents your documentation; the blog folder is where you add your Markdown for your [blog posts](https://v1.docusaurus.io/docs/en/blog.html); `siteConfig.js` is where you make most of the [customizations](https://v1.docusaurus.io/docs/en/site-config.html) for your site; `sidebars.json` is where you maintain the layout and content of the [sidebar](https://v1.docusaurus.io/docs/en/navigation.html) for your documentation; the `pages` folder is where you add [custom](https://v1.docusaurus.io/docs/en/custom-pages.html) pages for your site; the `static` folder is where all of your static assets go (e.g., CSS stylesheets and images); and the `core` folder is where you can customize core components of the site, in this case the footer. ## How does Docusaurus work? -Docusaurus is written primarily in JavaScript and [React](https://facebook.github.io/react), replacing Jekyll which we used in the old template. We use [Remarkable](https://github.com/jonschlinkert/remarkable) for our markdown rendering and [highlight.js](https://highlightjs.org/) for our code block syntax highlighting. The core of Docusaurus' functionality is in the [lib directory](https://github.com/facebookexperimental/Docusaurus/tree/master/lib) of the [Docusaurus repo](https://github.com/facebook/docusaurus/). The general structure looks like: +Docusaurus is written primarily in JavaScript and [React](https://facebook.github.io/react), replacing Jekyll which we used in the old template. We use [Remarkable](https://github.com/jonschlinkert/remarkable) for our Markdown rendering and [highlight.js](https://highlightjs.org/) for our code block syntax highlighting. The core of Docusaurus' functionality is in the [lib directory](https://github.com/facebookexperimental/Docusaurus/tree/master/lib) of the [Docusaurus repo](https://github.com/facebook/docusaurus/). The general structure looks like: ```bash root-of-Docusaurus @@ -92,12 +92,12 @@ root-of-Docusaurus │ └── write-translations.js ``` -The key files here are build-files.js and start-server.js. There are many similarities between these two files: `build-files.js` is used to build the physical artifacts for serving by an external web server. `start-server.js` is used to run the Docusaurus server and locally test your site. Both go through the following general process to take all of the markdown and configuration to create a runnable website: +The key files here are build-files.js and start-server.js. There are many similarities between these two files: `build-files.js` is used to build the physical artifacts for serving by an external web server. `start-server.js` is used to run the Docusaurus server and locally test your site. Both go through the following general process to take all of the Markdown and configuration to create a runnable website: 1. Process your website settings in `siteConfig.js` -1. Read the document metadata that exists in all the markdown files in your docs directory. -1. Create a table of contents for your documents based upon the ids extracted from the metadata. -1. Convert the markdown to HTML, including doing link replacement. +1. Read the document metadata that exists in all the Markdown files in your docs directory. +1. Create a table of contents for your documents based upon the IDs extracted from the metadata. +1. Convert the Markdown to HTML, including doing link replacement. 1. These files will go in a build/docs directory of the compiled site, and any translated versions will go into a language specific folder within the build/docs folder. 1. Repeat 1-3 for blog posts. 1. The blog file will go in a build/blog directory of the compiled site. diff --git a/website/blog/2018-04-30-How-I-Converted-Profilo-To-Docusaurus.md b/website/blog/2018-04-30-How-I-Converted-Profilo-To-Docusaurus.md index cf42f021b678..bb2022089f75 100644 --- a/website/blog/2018-04-30-How-I-Converted-Profilo-To-Docusaurus.md +++ b/website/blog/2018-04-30-How-I-Converted-Profilo-To-Docusaurus.md @@ -7,7 +7,7 @@ authorTwitter: abernathyca tags: [profilo, adoption] --- -> _“Joel and I were discussing having a website and how it would have been great to launch with it. So I challenged myself to add Docusaurus support. It took just over an hour and a half. I'm going to send you a PR with the addition so you can take a look and see if you like it. Your workflow for adding docs wouldn't be much different from editing those markdown files.”_ +> _“Joel and I were discussing having a website and how it would have been great to launch with it. So I challenged myself to add Docusaurus support. It took just over an hour and a half. I'm going to send you a PR with the addition so you can take a look and see if you like it. Your workflow for adding docs wouldn't be much different from editing those Markdown files.”_ > > _— Note sent to the Profilo team_ diff --git a/website/blog/2018-09-11-Towards-Docusaurus-2.md b/website/blog/2018-09-11-Towards-Docusaurus-2.md index 8f9c5c13553a..0472a926b88d 100644 --- a/website/blog/2018-09-11-Towards-Docusaurus-2.md +++ b/website/blog/2018-09-11-Towards-Docusaurus-2.md @@ -83,9 +83,9 @@ For Docusaurus 2, **layout and styling should be controlled by the user**. Docus ### Markdown -Our markdown parsing is currently powered by [Remarkable](https://github.com/jonschlinkert/remarkable). What if the user wants to use [markdown-it](https://github.com/markdown-it/markdown-it) or even [MDX](https://github.com/mdx-js/mdx)? And then there is an issue of which syntax highlighter to use, (e.g: [Prism](https://prismjs.com/) vs [Highlight.js](https://highlightjs.org/)). We should leave these choices open to the user. +Our Markdown parsing is currently powered by [Remarkable](https://github.com/jonschlinkert/remarkable). What if the user wants to use [Markdown-it](https://github.com/Markdown-it/Markdown-it) or even [MDX](https://github.com/mdx-js/mdx)? And then there is an issue of which syntax highlighter to use, (e.g: [Prism](https://prismjs.com/) vs [Highlight.js](https://highlightjs.org/)). We should leave these choices open to the user. -For Docusaurus 2, **users can eject and choose their own markdown parser**. It does not matter if they want to use another markdown parser such as [Remark](https://github.com/remarkjs/remark), or even their own in-house markdown parser. As a rule of thumb, the user has to provide a React component, in which we will provide a children props containing the _RAW string of markdown_. By default, we will use Remarkable for the markdown parser and Highlight.js for the syntax highlighting. The default parser could still change in the future as we're still experimenting with different markdown parsers. +For Docusaurus 2, **users can eject and choose their own Markdown parser**. It does not matter if they want to use another Markdown parser such as [Remark](https://github.com/remarkjs/remark), or even their own in-house Markdown parser. As a rule of thumb, the user has to provide a React component, in which we will provide a children props containing the _RAW string of Markdown_. By default, we will use Remarkable for the Markdown parser and Highlight.js for the syntax highlighting. The default parser could still change in the future as we're still experimenting with different Markdown parsers. ### Search diff --git a/website/blog/2019-12-30-docusaurus-2019-recap.md b/website/blog/2019-12-30-docusaurus-2019-recap.md index fb1cba3bbc75..709f28702c58 100644 --- a/website/blog/2019-12-30-docusaurus-2019-recap.md +++ b/website/blog/2019-12-30-docusaurus-2019-recap.md @@ -18,9 +18,9 @@ Last but not least, we implemented a plugins architecture and turned the repo in ## GitHub Activity -- Stars: 10050 -> 14632 (+45.6% y/y) -- Total Contributors: 182 -> 303 (+66.4% y/y). Most of which are non-Facebook contributors -- Daily npm Downloads: 728 -> 2320 (+218.7% y/y). The peak was in November +- Stars: 10050 → 14632 (+45.6% y/y) +- Total Contributors: 182 → 303 (+66.4% y/y). Most of which are non-Facebook contributors +- Daily npm Downloads: 728 → 2320 (+218.7% y/y). The peak was in November - D1 is currently used by 3872 projects on GitHub while D2 is used by 247 projects on GitHub - We now have 4 active core contributors! (+100% y/y) diff --git a/website/blog/2021-01-19-docusaurus-2020-recap.md b/website/blog/2021-01-19-docusaurus-2020-recap.md index 85d252681f66..2fbcb3014be9 100644 --- a/website/blog/2021-01-19-docusaurus-2020-recap.md +++ b/website/blog/2021-01-19-docusaurus-2020-recap.md @@ -69,9 +69,9 @@ We also saw the **[first right-to-left](https://datagit.ir/)** Docusaurus 2 site ## GitHub Activity -- **Stars**: 14632 -> 20946 (+43.2% y/y) -- **Total Contributors**: 303 -> 512 (+68.9% y/y). Most of which are non-Facebook contributors -- **Weekly npm Downloads**: 2356 -> 25592 (+986% y/y) +- **Stars**: 14632 → 20946 (+43.2% y/y) +- **Total Contributors**: 303 → 512 (+68.9% y/y). Most of which are non-Facebook contributors +- **Weekly npm Downloads**: 2356 → 25592 (+986% y/y) - **On GitHub**, Docusaurus 1 is used by 6311 projects (+62.9% y/y) while Docusaurus 2 is used by 5039 projects (+1940% y/y) ## Collaboration with Major League Hacking diff --git a/website/community/4-canary/index.md b/website/community/4-canary.md similarity index 98% rename from website/community/4-canary/index.md rename to website/community/4-canary.md index ed20512a9275..07e092907f6e 100644 --- a/website/community/4-canary/index.md +++ b/website/community/4-canary.md @@ -9,7 +9,7 @@ import { InsertIfCanaryVersionKnown, PackageJSONDiff, PublishTime, -} from "./Versions.tsx"; +} from "@site/src/components/Versions"; ``` diff --git a/website/docs/advanced/routing.md b/website/docs/advanced/routing.md index 82c85b7aae12..9ee8294b1b1a 100644 --- a/website/docs/advanced/routing.md +++ b/website/docs/advanced/routing.md @@ -81,7 +81,7 @@ When writing links in Markdown, you could either mean a _file path_, or a _URL p - If the path has an `.md(x)` extension, Docusaurus would try to resolve that Markdown file to a URL, and replace the file path with a URL path. - If the path has any other extension, Docusaurus would treat it as [an asset](../guides/markdown-features/markdown-features-assets.mdx) and bundle it. -The following directory structure may help you visualize this file -> URL mapping. Assume that there's no slug customization in any page. +The following directory structure may help you visualize this file → URL mapping. Assume that there's no slug customization in any page.
diff --git a/website/docs/advanced/ssg.md b/website/docs/advanced/ssg.md index dbd104d78a95..09fb981e6dfc 100644 --- a/website/docs/advanced/ssg.md +++ b/website/docs/advanced/ssg.md @@ -36,9 +36,10 @@ ReferenceError: window is not defined This is because during server-side rendering, the Docusaurus app isn't actually run in browser, and it doesn't know what `window` is. +```mdx-code-block
- What about process.env.NODE_ENV? +``` One exception to the "no Node globals" rule is `process.env.NODE_ENV`. In fact, you can use it in React, because Webpack injects this variable as a global: @@ -58,8 +59,10 @@ During Webpack build, the `process.env.NODE_ENV` will be replaced with the value import Tabs from '@theme/Tabs'; import TabItem from '@theme/TabItem'; +```mdx-code-block +``` ```diff import React from 'react'; @@ -74,8 +77,10 @@ export default function expensiveComp() { } ``` +```mdx-code-block +``` ```diff import React from 'react'; @@ -90,9 +95,11 @@ export default function expensiveComp() { } ``` +```mdx-code-block
+``` ## Understanding SSR {#understanding-ssr} diff --git a/website/docs/api/docusaurus.config.js.md b/website/docs/api/docusaurus.config.js.md index 0b0a6ecf8832..82a9275ad598 100644 --- a/website/docs/api/docusaurus.config.js.md +++ b/website/docs/api/docusaurus.config.js.md @@ -63,7 +63,7 @@ module.exports = { - Type: `string` -URL for your website. This can also be considered the top-level hostname. For example, `https://facebook.github.io` is the URL of https://facebook.github.io/metro/, and `https://docusaurus.io` is the URL for https://docusaurus.io. This field is related to the [baseUrl](#baseurl) field. +URL for your website. This can also be considered the top-level hostname. For example, `https://facebook.github.io` is the URL of https://facebook.github.io/metro/, and `https://docusaurus.io` is the URL for https://docusaurus.io. This field is related to the [`baseUrl`](#baseUrl) field. ```js title="docusaurus.config.js" module.exports = { @@ -75,7 +75,7 @@ module.exports = { - Type: `string` -Base URL for your site. Can be considered as the path after the host. For example, `/metro/` is the base URL of https://facebook.github.io/metro/. For URLs that have no path, the baseUrl should be set to `/`. This field is related to the [url](#url) field. Always has both leading and trailing slash. +Base URL for your site. Can be considered as the path after the host. For example, `/metro/` is the base URL of https://facebook.github.io/metro/. For URLs that have no path, the baseUrl should be set to `/`. This field is related to the [`url`](#url) field. Always has both leading and trailing slash. ```js title="docusaurus.config.js" module.exports = { @@ -130,18 +130,21 @@ module.exports = { i18n: { defaultLocale: 'en', locales: ['en', 'fa'], + path: 'i18n', localeConfigs: { en: { label: 'English', direction: 'ltr', htmlLang: 'en-US', calendar: 'gregory', + path: 'en', }, fa: { label: 'فارسی', direction: 'rtl', htmlLang: 'fa-IR', calendar: 'persian', + path: 'fa', }, }, }, @@ -150,11 +153,13 @@ module.exports = { - `defaultLocale`: The locale that (1) does not have its name in the base URL (2) gets started with `docusaurus start` without `--locale` option (3) will be used for the `` tag - `locales`: List of locales deployed on your site. Must contain `defaultLocale`. +- `path`: Root folder which all locale folders are relative to. Can be absolute or relative to the config file. Defaults to `i18n`. - `localeConfigs`: Individual options for each locale. - `label`: The label displayed for this locale in the locales dropdown. - - `direction`: `ltr` (default) or `rtl` (for [right-to-left languages](https://developer.mozilla.org/en-US/docs/Glossary/rtl) like Farsi, Arabic, Hebrew, etc.). Used to select the locale's CSS and html meta attribute. + - `direction`: `ltr` (default) or `rtl` (for [right-to-left languages](https://developer.mozilla.org/en-US/docs/Glossary/rtl) like Farsi, Arabic, Hebrew, etc.). Used to select the locale's CSS and HTML meta attribute. - `htmlLang`: BCP 47 language tag to use in `` and in `` - `calendar`: the [calendar](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Intl/Locale/calendar) used to calculate the date era. Note that it doesn't control the actual string displayed: `MM/DD/YYYY` and `DD/MM/YYYY` are both `gregory`. To choose the format (`DD/MM/YYYY` or `MM/DD/YYYY`), set your locale name to `en-GB` or `en-US` (`en` means `en-US`). + - `path`: Root folder that all plugin localization folders of this locale are relative to. Will be resolved against `i18n.path`. Defaults to the locale's name. Note: this has no effect on the locale's `baseUrl`—customization of base URL is a work-in-progress. ### `noIndex` {#noIndex} @@ -188,9 +193,9 @@ The broken links detection is only available for a production build (`docusaurus - Type: `'ignore' | 'log' | 'warn' | 'error' | 'throw'` -The behavior of Docusaurus when it detects any broken markdown link. +The behavior of Docusaurus when it detects any broken Markdown link. -By default, it prints a warning, to let you know about your broken markdown link, but you can change this security if needed. +By default, it prints a warning, to let you know about your broken Markdown link, but you can change this security if needed. ### `onDuplicateRoutes` {#onDuplicateRoutes} @@ -547,7 +552,7 @@ module.exports = { }; ``` -### `baseUrlIssueBanner` {#baseurlIssueBanner} +### `baseUrlIssueBanner` {#baseUrlIssueBanner} - Type: `boolean` diff --git a/website/docs/api/misc/eslint-plugin/no-untranslated-text.md b/website/docs/api/misc/eslint-plugin/no-untranslated-text.md index b8b282b9cbbc..3829a915bad9 100644 --- a/website/docs/api/misc/eslint-plugin/no-untranslated-text.md +++ b/website/docs/api/misc/eslint-plugin/no-untranslated-text.md @@ -32,13 +32,17 @@ Examples of **correct** code for this rule: Accepted fields: +```mdx-code-block +``` | Option | Type | Default | Description | | --- | --- | --- | --- | | `ignoredStrings` | `string[]` | `[]` | Text labels that only contain strings in this list will not be reported. | +```mdx-code-block +``` ## When Not To Use It {#when-not-to-use} diff --git a/website/docs/api/plugin-methods/i18n-lifecycles.md b/website/docs/api/plugin-methods/i18n-lifecycles.md index 83f1087cc4c8..1002dd74a344 100644 --- a/website/docs/api/plugin-methods/i18n-lifecycles.md +++ b/website/docs/api/plugin-methods/i18n-lifecycles.md @@ -103,7 +103,7 @@ module.exports = function (context, options) { Themes using the `` API can provide default code translation messages. -It should return messages in `Record`, where keys are translation ids and values are messages (without the description) localized using the site's current locale. +It should return messages in `Record`, where keys are translation IDs and values are messages (without the description) localized using the site's current locale. Example: diff --git a/website/docs/api/plugin-methods/lifecycle-apis.md b/website/docs/api/plugin-methods/lifecycle-apis.md index bc583e8d38e0..739b902d07de 100644 --- a/website/docs/api/plugin-methods/lifecycle-apis.md +++ b/website/docs/api/plugin-methods/lifecycle-apis.md @@ -178,7 +178,7 @@ The API of `configureWebpack` will be modified in the future to accept an object - `getStyleLoaders(isServer: boolean, cssOptions: {[key: string]: any}): Loader[]` - `getJSLoader(isServer: boolean, cacheOptions?: {}): Loader | null` -You may use them to return your webpack configures conditionally. +You may use them to return your webpack configuration conditionally. For example, this plugin below modify the webpack config to transpile `.foo` files. diff --git a/website/docs/api/plugins/plugin-client-redirects.md b/website/docs/api/plugins/plugin-client-redirects.md index a97122b36dbb..8a1f161d1ccf 100644 --- a/website/docs/api/plugins/plugin-client-redirects.md +++ b/website/docs/api/plugins/plugin-client-redirects.md @@ -35,16 +35,20 @@ npm install --save @docusaurus/plugin-client-redirects Accepted fields: +```mdx-code-block +``` | Option | Type | Default | Description | | --- | --- | --- | --- | | `fromExtensions` | `string[]` | `[]` | The extensions to be removed from the route after redirecting. | | `toExtensions` | `string[]` | `[]` | The extensions to be appended to the route after redirecting. | | `redirects` | RedirectRule[] | `[]` | The list of redirect rules. | -| `createRedirects` | CreateRedirectsFn | `undefined` | A callback to create a redirect rule. | +| `createRedirects` | CreateRedirectsFn | `undefined` | A callback to create a redirect rule. Docusaurus query this callback against every path it has created, and use its return value to output more paths. | +```mdx-code-block +``` ### Types {#types} @@ -57,9 +61,20 @@ type RedirectRule = { }; ``` +:::note + +The idea of "from" and "to" is central in this plugin. "From" means a path that you want to _create_, i.e. an extra HTML file that will be written; "to" means a path to want to redirect _to_, usually a route that Docusaurus already knows about. + +This is why you can have multiple "from" for the same "to": we will create multiple HTML files that all redirect to the same destination. On the other hand, one "from" can never have more than one "to": the written HTML file needs to have a determinate destination. + +::: + #### `CreateRedirectsFn` {#CreateRedirectsFn} ```ts +// The parameter `path` is a route that Docusaurus has already created. It can +// be seen as the "to", and your return value is the "from". Returning a falsy +// value will not create any redirect pages for this particular path. type CreateRedirectsFn = (path: string) => string[] | string | null | undefined; ``` diff --git a/website/docs/api/plugins/plugin-content-blog.md b/website/docs/api/plugins/plugin-content-blog.md index 52806b016873..696b4102858d 100644 --- a/website/docs/api/plugins/plugin-content-blog.md +++ b/website/docs/api/plugins/plugin-content-blog.md @@ -33,7 +33,9 @@ You can configure this plugin through the [preset options](#ex-config-preset). Accepted fields: +```mdx-code-block +``` | Name | Type | Default | Description | | --- | --- | --- | --- | @@ -71,7 +73,9 @@ Accepted fields: | `feedOptions.language` | `string` (See [documentation](http://www.w3.org/TR/REC-html40/struct/dirlang.html#langcodes) for possible values) | `undefined` | Language metadata of the feed. | | `sortPosts` | 'descending' \| 'ascending' | `'descending'` | Governs the direction of blog post sorting. | +```mdx-code-block +``` ### Types {#types} @@ -174,7 +178,9 @@ Markdown documents can use the following Markdown front matter metadata fields, Accepted fields: +```mdx-code-block +``` | Name | Type | Default | Description | | --- | --- | --- | --- | @@ -193,9 +199,11 @@ Accepted fields: | `keywords` | `string[]` | `undefined` | Keywords meta tag, which will become the `` in ``, used by search engines. | | `description` | `string` | The first line of Markdown content | The description of your document, which will become the `` and `` in ``, used by search engines. | | `image` | `string` | `undefined` | Cover or thumbnail image that will be used when displaying the link to your post. | -| `slug` | `string` | File path | Allows to customize the blog post url (`//`). Support multiple patterns: `slug: my-blog-post`, `slug: /my/path/to/blog/post`, slug: `/`. | +| `slug` | `string` | File path | Allows to customize the blog post URL (`//`). Support multiple patterns: `slug: my-blog-post`, `slug: /my/path/to/blog/post`, slug: `/`. | +```mdx-code-block +``` ```ts type Tag = string | {label: string; permalink: string}; diff --git a/website/docs/api/plugins/plugin-content-docs.md b/website/docs/api/plugins/plugin-content-docs.md index 4b7deaff16d6..d645f726738f 100644 --- a/website/docs/api/plugins/plugin-content-docs.md +++ b/website/docs/api/plugins/plugin-content-docs.md @@ -27,7 +27,9 @@ You can configure this plugin through the preset options. Accepted fields: +```mdx-code-block +``` | Name | Type | Default | Description | | --- | --- | --- | --- | @@ -62,7 +64,9 @@ Accepted fields: | `onlyIncludeVersions` | `string[]` | All versions available | Only include a subset of all available versions. | | `versions` | VersionsConfig | `{}` | Independent customization of each version's properties. | +```mdx-code-block +``` ### Types {#types} @@ -257,16 +261,19 @@ Markdown documents can use the following Markdown front matter metadata fields, Accepted fields: +```mdx-code-block +``` | Name | Type | Default | Description | | --- | --- | --- | --- | -| `id` | `string` | file path (including folders, without the extension) | A unique document id. | +| `id` | `string` | file path (including folders, without the extension) | A unique document ID. | | `title` | `string` | Markdown title or `id` | The text title of your document. Used for the page metadata and as a fallback value in multiple places (sidebar, next/previous buttons...). Automatically added at the top of your doc if it does not contain any Markdown title. | | `pagination_label` | `string` | `sidebar_label` or `title` | The text used in the document next/previous buttons for this document. | | `sidebar_label` | `string` | `title` | The text shown in the document sidebar for this document. | | `sidebar_position` | `number` | Default ordering | Controls the position of a doc inside the generated sidebar slice when using `autogenerated` sidebar items. See also [Autogenerated sidebar metadata](/docs/sidebar#autogenerated-sidebar-metadata). | | `sidebar_class_name` | `string` | `undefined` | Gives the corresponding sidebar label a special class name when using autogenerated sidebars. | +| `sidebar_custom_props` | `string` | `undefined` | Assign custom metadata to the sidebar item referencing this doc. | | `hide_title` | `boolean` | `false` | Whether to hide the title at the top of the doc. It only hides a title declared through the front matter, and have no effect on a Markdown title at the top of your document. | | `hide_table_of_contents` | `boolean` | `false` | Whether to hide the table of contents to the right. | | `toc_min_heading_level` | `number` | `2` | The minimum heading level shown in the table of contents. Must be between 2 and 6 and lower or equal to the max value. | @@ -278,16 +285,23 @@ Accepted fields: | `keywords` | `string[]` | `undefined` | Keywords meta tag for the document page, for search engines. | | `description` | `string` | The first line of Markdown content | The description of your document, which will become the `` and `` in ``, used by search engines. | | `image` | `string` | `undefined` | Cover or thumbnail image that will be used when displaying the link to your post. | -| `slug` | `string` | File path | Allows to customize the document url (`//`). Support multiple patterns: `slug: my-doc`, `slug: /my/path/myDoc`, `slug: /`. | +| `slug` | `string` | File path | Allows to customize the document URL (`//`). Support multiple patterns: `slug: my-doc`, `slug: /my/path/myDoc`, `slug: /`. | | `tags` | `Tag[]` | `undefined` | A list of strings or objects of two string fields `label` and `permalink` to tag to your docs. | | `draft` | `boolean` | `false` | A boolean flag to indicate that a document is a work-in-progress. Draft documents will only be displayed during development. | +| `last_update` | `FileChange` | `undefined` | Allows overriding the last updated author and/or date. Date can be any [parsable date string](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Date/parse). | +```mdx-code-block +``` ```ts type Tag = string | {label: string; permalink: string}; ``` +```ts +type FileChange = {date: string; author: string}; +``` + Example: ```md @@ -306,6 +320,9 @@ keywords: - docusaurus image: https://i.imgur.com/mErPwqL.png slug: /myDoc +last_update: + date: 1/1/2000 + author: custom author name --- # Markdown Features diff --git a/website/docs/api/plugins/plugin-content-pages.md b/website/docs/api/plugins/plugin-content-pages.md index 23dff9c2a799..b6334f5af7ca 100644 --- a/website/docs/api/plugins/plugin-content-pages.md +++ b/website/docs/api/plugins/plugin-content-pages.md @@ -27,7 +27,9 @@ You can configure this plugin through the preset options. Accepted fields: +```mdx-code-block +``` | Name | Type | Default | Description | | --- | --- | --- | --- | @@ -41,7 +43,9 @@ Accepted fields: | `beforeDefaultRemarkPlugins` | `any[]` | `[]` | Custom Remark plugins passed to MDX before the default Docusaurus Remark plugins. | | `beforeDefaultRehypePlugins` | `any[]` | `[]` | Custom Rehype plugins passed to MDX before the default Docusaurus Rehype plugins. | +```mdx-code-block +``` ### Example configuration {#ex-config} diff --git a/website/docs/api/plugins/plugin-debug.md b/website/docs/api/plugins/plugin-debug.md index e8c79044d945..bca9ac69192e 100644 --- a/website/docs/api/plugins/plugin-debug.md +++ b/website/docs/api/plugins/plugin-debug.md @@ -67,8 +67,10 @@ Most Docusaurus users configure this plugin through the preset options. ::: - - +```mdx-code-block + + +``` If you use a preset, configure this plugin through the [preset options](../../using-plugins.md#docusauruspreset-classic): @@ -86,8 +88,10 @@ module.exports = { }; ``` +```mdx-code-block - + +``` If you are using a standalone plugin, provide options directly to the plugin: @@ -98,5 +102,7 @@ module.exports = { }; ``` +```mdx-code-block +``` diff --git a/website/docs/api/plugins/plugin-google-analytics.md b/website/docs/api/plugins/plugin-google-analytics.md index 5e6403652e90..1426e6265a1c 100644 --- a/website/docs/api/plugins/plugin-google-analytics.md +++ b/website/docs/api/plugins/plugin-google-analytics.md @@ -33,14 +33,18 @@ You can configure this plugin through the preset options. Accepted fields: +```mdx-code-block +``` | Name | Type | Default | Description | | --- | --- | --- | --- | | `trackingID` | `string` | **Required** | The tracking ID of your analytics service. | | `anonymizeIP` | `boolean` | `false` | Whether the IP should be anonymized when sending requests. | +```mdx-code-block +``` ### Example configuration {#ex-config} diff --git a/website/docs/api/plugins/plugin-google-gtag.md b/website/docs/api/plugins/plugin-google-gtag.md index df65941b537b..db414c4d0f21 100644 --- a/website/docs/api/plugins/plugin-google-gtag.md +++ b/website/docs/api/plugins/plugin-google-gtag.md @@ -39,14 +39,18 @@ You can configure this plugin through the preset options. Accepted fields: +```mdx-code-block +``` | Name | Type | Default | Description | | --- | --- | --- | --- | | `trackingID` | `string` | **Required** | The tracking ID of your gtag service. | | `anonymizeIP` | `boolean` | `false` | Whether the IP should be anonymized when sending requests. | +```mdx-code-block +``` ### Example configuration {#ex-config} diff --git a/website/docs/api/plugins/plugin-ideal-image.md b/website/docs/api/plugins/plugin-ideal-image.md index 900c54e627e7..e682c3943a75 100644 --- a/website/docs/api/plugins/plugin-ideal-image.md +++ b/website/docs/api/plugins/plugin-ideal-image.md @@ -40,7 +40,9 @@ import thumbnail from './path/to/img.png'; Accepted fields: +```mdx-code-block +``` | Option | Type | Default | Description | | --- | --- | --- | --- | @@ -53,7 +55,9 @@ Accepted fields: | `quality` | `number` | `85` | JPEG compression quality | | `disableInDev` | `boolean` | `true` | You can test ideal image behavior in dev mode by setting this to `false`. **Tip**: use [network throttling](https://www.browserstack.com/guide/how-to-perform-network-throttling-in-chrome) in your browser to simulate slow networks. | +```mdx-code-block +``` ### Example configuration {#ex-config} diff --git a/website/docs/api/plugins/plugin-pwa.md b/website/docs/api/plugins/plugin-pwa.md index a9647173182a..71f63febc643 100644 --- a/website/docs/api/plugins/plugin-pwa.md +++ b/website/docs/api/plugins/plugin-pwa.md @@ -70,7 +70,7 @@ If your browser supports it, you should be able to install a Docusaurus site as :::note -App installation requires the https protocol and a valid manifest. +App installation requires the HTTPS protocol and a valid manifest. ::: @@ -120,7 +120,7 @@ Strategies used to turn the offline mode on: - `appInstalled`: activates for users having installed the site as an app (not 100% reliable) - `standalone`: activates for users running the app as standalone (often the case once a PWA is installed) - `queryString`: activates if queryString contains `offlineMode=true` (convenient for PWA debugging) -- `mobile`: activates for mobile users (width <= 940px) +- `mobile`: activates for mobile users (width <= 996px) - `saveData`: activates for users with `navigator.connection.saveData === true` - `always`: activates for all users @@ -160,7 +160,7 @@ module.exports = { modifyURLPrefix: { //... }, - // We already add regular static assets (html, images...) to be available offline + // We already add regular static assets (HTML, images...) to be available offline // You can add more files according to your needs globPatterns: ['**/*.{pdf,docx,xlsx}'], // ... diff --git a/website/docs/api/plugins/plugin-sitemap.md b/website/docs/api/plugins/plugin-sitemap.md index b1d18e2f1e78..5bfdc50f2b18 100644 --- a/website/docs/api/plugins/plugin-sitemap.md +++ b/website/docs/api/plugins/plugin-sitemap.md @@ -33,7 +33,9 @@ You can configure this plugin through the [preset options](#ex-config-preset). Accepted fields: +```mdx-code-block +``` | Name | Type | Default | Description | | --- | --- | --- | --- | @@ -42,7 +44,9 @@ Accepted fields: | `ignorePatterns` | `string[]` | `[]` | A list of glob patterns; matching route paths will be filtered from the sitemap. Note that you may need to include the base URL in here. | | `filename` | `string` | `sitemap.xml` | The path to the created sitemap file, relative to the output directory. Useful if you have two plugin instances outputting two files. | +```mdx-code-block +``` :::info diff --git a/website/docs/api/themes/theme-configuration.md b/website/docs/api/themes/theme-configuration.md index 7936ae6f5f21..356d61f62a10 100644 --- a/website/docs/api/themes/theme-configuration.md +++ b/website/docs/api/themes/theme-configuration.md @@ -21,7 +21,9 @@ It is possible to customize the color mode support within the `colorMode` object Accepted fields: +```mdx-code-block +``` | Name | Type | Default | Description | | --- | --- | --- | --- | @@ -29,7 +31,9 @@ Accepted fields: | `disableSwitch` | `boolean` | `false` | Hides the switch in the navbar. Useful if you want to support a single color mode. | | `respectPrefersColorScheme` | `boolean` | `false` | Whether to use the `prefers-color-scheme` media-query, using user system preferences, instead of the hardcoded `defaultMode`. | +```mdx-code-block +``` Example configuration: @@ -61,13 +65,17 @@ You can configure a default image that will be used for your meta tag, in partic Accepted fields: +```mdx-code-block +``` | Name | Type | Default | Description | | --- | --- | --- | --- | | `image` | `string` | `undefined` | The meta image URL for the site. Relative to your site's "static" directory. Cannot be SVGs. Can be external URLs too. | +```mdx-code-block +``` Example configuration: @@ -82,17 +90,21 @@ module.exports = { ### Metadata {#metadata} -You can configure additional html metadata (and override existing ones). +You can configure additional HTML metadata (and override existing ones). Accepted fields: +```mdx-code-block +``` | Name | Type | Default | Description | | --- | --- | --- | --- | | `metadata` | `Metadata[]` | `[]` | Any field will be directly passed to the `` tag. Possible fields include `id`, `name`, `property`, `content`, `itemprop`, etc. | +```mdx-code-block +``` Example configuration: @@ -111,7 +123,9 @@ Sometimes you want to announce something in your website. Just for such a case, Accepted fields: +```mdx-code-block +``` | Name | Type | Default | Description | | --- | --- | --- | --- | @@ -121,7 +135,9 @@ Accepted fields: | `textColor` | `string` | `'#000'` | Announcement text color. | | `isCloseable` | `boolean` | `true` | Whether this announcement can be dismissed with a '×' button. | +```mdx-code-block +``` Example configuration: @@ -146,7 +162,9 @@ module.exports = { Accepted fields: +```mdx-code-block +``` | Name | Type | Default | Description | | --- | --- | --- | --- | @@ -156,7 +174,9 @@ Accepted fields: | `hideOnScroll` | `boolean` | `false` | Whether the navbar is hidden when the user scrolls down. | | `style` | 'primary' \| 'dark' | Same as theme | Sets the navbar style, ignoring the dark/light theme. | +```mdx-code-block +``` ### Navbar logo {#navbar-logo} @@ -166,7 +186,9 @@ To improve dark mode support, you can also set a different logo for this mode. Accepted fields: +```mdx-code-block +``` | Name | Type | Default | Description | | --- | --- | --- | --- | @@ -178,7 +200,9 @@ Accepted fields: | `height` | string \| number | `undefined` | Specifies the `height` attribute. | | `target` | `string` | Calculated based on `href` (external links will open in a new tab, all others in the current one). | The `target` attribute of the link; controls whether the link is opened in a new tab, the current one, or otherwise. | +```mdx-code-block +``` Example configuration: @@ -253,7 +277,9 @@ Outbound (external) links automatically get `target="_blank" rel="noopener noref Accepted fields: +```mdx-code-block +``` | Name | Type | Default | Description | | --- | --- | --- | --- | @@ -268,7 +294,9 @@ Accepted fields: | `activeBaseRegex` | `string` | `undefined` | Alternative to `activeBasePath` if required. | | `className` | `string` | `''` | Custom CSS class (for styling any item). | +```mdx-code-block +``` :::note @@ -318,7 +346,9 @@ Note that the dropdown base item is a clickable link as well, so this item can r Accepted fields: +```mdx-code-block +``` | Name | Type | Default | Description | | --- | --- | --- | --- | @@ -327,7 +357,9 @@ Accepted fields: | `items` | [LinkLikeItem](#navbar-dropdown)[] | **Required** | The items to be contained in the dropdown. | | `position` | 'left' \| 'right' | `'left'` | The side of the navbar this item should appear on. | +```mdx-code-block +``` Example configuration: @@ -367,7 +399,9 @@ If you want to link to a specific doc, this special navbar item type will render Accepted fields: +```mdx-code-block +``` | Name | Type | Default | Description | | --- | --- | --- | --- | @@ -377,7 +411,9 @@ Accepted fields: | `position` | 'left' \| 'right' | `'left'` | The side of the navbar this item should appear on. | | `docsPluginId` | `string` | `'default'` | The ID of the docs plugin that the doc belongs to. | +```mdx-code-block +``` Example configuration: @@ -406,7 +442,9 @@ You can link a navbar item to the first document link (which can be a doc link o Accepted fields: +```mdx-code-block +``` | Name | Type | Default | Description | | --- | --- | --- | --- | @@ -416,7 +454,9 @@ Accepted fields: | `position` | 'left' \| 'right' | `'left'` | The side of the navbar this item should appear on. | | `docsPluginId` | `string` | `'default'` | The ID of the docs plugin that the sidebar belongs to. | +```mdx-code-block +``` :::tip @@ -469,11 +509,13 @@ module.exports = { If you use docs with versioning, this special navbar item type that will render a dropdown with all your site's available versions. -The user will be able to switch from one version to another, while staying on the same doc (as long as the doc id is constant across versions). +The user will be able to switch from one version to another, while staying on the same doc (as long as the doc ID is constant across versions). Accepted fields: +```mdx-code-block +``` | Name | Type | Default | Description | | --- | --- | --- | --- | @@ -484,7 +526,9 @@ Accepted fields: | `docsPluginId` | `string` | `'default'` | The ID of the docs plugin that the doc versioning belongs to. | | `dropdownActiveClassDisabled` | `boolean` | `false` | Do not add the link active class when browsing docs. | +```mdx-code-block +``` Example configuration: @@ -513,7 +557,9 @@ If you use docs with versioning, this special navbar item type will link to the Accepted fields: +```mdx-code-block +``` | Name | Type | Default | Description | | --- | --- | --- | --- | @@ -523,7 +569,9 @@ Accepted fields: | `position` | 'left' \| 'right' | `'left'` | The side of the navbar this item should appear on. | | `docsPluginId` | `string` | `'default'` | The ID of the docs plugin that the doc versioning belongs to. | +```mdx-code-block +``` Example configuration: @@ -554,7 +602,9 @@ The user will be able to switch from one locale to another, while staying on the Accepted fields: +```mdx-code-block +``` | Name | Type | Default | Description | | --- | --- | --- | --- | @@ -563,7 +613,9 @@ Accepted fields: | `dropdownItemsBefore` | [LinkLikeItem](#navbar-dropdown)[] | `[]` | Add additional dropdown items at the beginning of the dropdown. | | `dropdownItemsAfter` | [LinkLikeItem](#navbar-dropdown)[] | `[]` | Add additional dropdown items at the end of the dropdown. | +```mdx-code-block +``` Example configuration: @@ -596,7 +648,9 @@ If you use the [search](../../search.md), the search bar will be the rightmost e However, with this special navbar item type, you can change the default location. +```mdx-code-block +``` | Name | Type | Default | Description | | --- | --- | --- | --- | @@ -604,7 +658,9 @@ However, with this special navbar item type, you can change the default location | `position` | 'left' \| 'right' | `'left'` | The side of the navbar this item should appear on. | | `className` | `string` | / | Custom CSS class for this navbar item. | +```mdx-code-block +``` ```js title="docusaurus.config.js" module.exports = { @@ -627,7 +683,9 @@ module.exports = { You can also render your own HTML markup inside a navbar item using this navbar item type. +```mdx-code-block +``` | Name | Type | Default | Description | | --- | --- | --- | --- | @@ -636,7 +694,9 @@ You can also render your own HTML markup inside a navbar item using this navbar | `className` | `string` | `''` | Custom CSS class for this navbar item. | | `value` | `string` | `''` | Custom HTML to be rendered inside this navbar item. | +```mdx-code-block +``` ```js title="docusaurus.config.js" module.exports = { @@ -694,7 +754,9 @@ Docusaurus uses [Prism React Renderer](https://github.com/FormidableLabs/prism-r Accepted fields: +```mdx-code-block +``` | Name | Type | Default | Description | | --- | --- | --- | --- | @@ -703,7 +765,9 @@ Accepted fields: | `defaultLanguage` | `string` | `undefined` | The side of the navbar this item should appear on. | | `magicComments` | `MagicCommentConfig[]` | _see below_ | The list of [magic comments](../../guides/markdown-features/markdown-features-code-blocks.mdx#custom-magic-comments). | +```mdx-code-block +``` ```ts type MagicCommentConfig = { @@ -771,7 +835,9 @@ You can add logo and a copyright to the footer via `themeConfig.footer`. Logo ca Accepted fields: +```mdx-code-block +``` | Name | Type | Default | Description | | --- | --- | --- | --- | @@ -780,7 +846,9 @@ Accepted fields: | `style` | 'dark' \| 'light' | `'light'` | The color theme of the footer component. | | `links` | (Column \| FooterLink)[] | `[]` | The link groups to be present. | +```mdx-code-block +``` Example configuration: @@ -809,27 +877,35 @@ You can add links to the footer via `themeConfig.footer.links`. There are two ty Multi-column footer links have a `title` and a list of `FooterItem`s for each column. +```mdx-code-block +``` | Name | Type | Default | Description | | --- | --- | --- | --- | | `title` | `string` | `undefined` | Label of the section of these links. | | `items` | `FooterItem[]` | `[]` | Links in this section. | +```mdx-code-block +``` Accepted fields of each `FooterItem`: +```mdx-code-block +``` | Name | Type | Default | Description | | --- | --- | --- | --- | | `label` | `string` | **Required** | Text to be displayed for this link. | | `to` | `string` | **Required** | Client-side routing, used for navigating within the website. The baseUrl will be automatically prepended to this value. | | `href` | `string` | **Required** | A full-page navigation, used for navigating outside of the website. **Only one of `to` or `href` should be used.** | -| `html` | `string` | `undefined` | Renders the html pass-through instead of a simple link. In case `html` is used, no other options should be provided. | +| `html` | `string` | `undefined` | Renders the HTML pass-through instead of a simple link. In case `html` is used, no other options should be provided. | +```mdx-code-block +``` Example multi-column configuration: @@ -919,14 +995,18 @@ module.exports = { You can adjust the default table of contents via `themeConfig.tableOfContents`. +```mdx-code-block +``` | Name | Type | Default | Description | | --- | --- | --- | --- | | `minHeadingLevel` | `number` | `2` | The minimum heading level shown in the table of contents. Must be between 2 and 6 and lower or equal to the max value. | | `maxHeadingLevel` | `number` | `3` | Max heading level displayed in the TOC. Should be an integer between 2 and 6. | +```mdx-code-block +``` Example configuration: diff --git a/website/docs/api/themes/theme-search-algolia.md b/website/docs/api/themes/theme-search-algolia.md index 1b5ce68a74bf..a7dd47d2a054 100644 --- a/website/docs/api/themes/theme-search-algolia.md +++ b/website/docs/api/themes/theme-search-algolia.md @@ -11,7 +11,7 @@ This theme provides a `@theme/SearchBar` component that integrates with Algolia npm install --save @docusaurus/theme-search-algolia ``` -This theme also adds search page available at `/search` (as swizzlable `SearchPage` component) path with OpenSearch support. You can this default path via `themeConfig.algolia.searchPagePath`. Use `false` to disable search page. +This theme also adds search page available at `/search` (as swizzlable `SearchPage` component) path with OpenSearch support. You can change this default path via `themeConfig.algolia.searchPagePath`. Use `false` to disable search page. :::tip diff --git a/website/docs/blog.mdx b/website/docs/blog.mdx index 26ef286377b6..780a07dbca87 100644 --- a/website/docs/blog.mdx +++ b/website/docs/blog.mdx @@ -192,9 +192,10 @@ Use the `authors` front matter field to declare blog post authors. An author sho Blog post authors can be declared directly inside the front matter: -````mdx-code-block +```mdx-code-block - + +``` ```md title="my-blog-post.md" --- @@ -207,8 +208,10 @@ authors: --- ``` - - +```mdx-code-block + + +``` ```md title="my-blog-post.md" --- @@ -225,9 +228,10 @@ authors: --- ``` - +```mdx-code-block + -```` +``` :::tip @@ -279,9 +283,10 @@ Use the `authorsMapPath` plugin option to configure the path. JSON is also suppo In blog posts front matter, you can reference the authors declared in the global configuration file: -````mdx-code-block +```mdx-code-block - + +``` ```md title="my-blog-post.md" --- @@ -289,8 +294,10 @@ authors: jmarcey --- ``` - - +```mdx-code-block + + +``` ```md title="my-blog-post.md" --- @@ -298,9 +305,10 @@ authors: [jmarcey, slorber] --- ``` - +```mdx-code-block + -```` +``` :::info @@ -394,9 +402,10 @@ The default reading time is able to accept additional options: `wordsPerMinute` Use the callback for all your customization needs: -````mdx-code-block +```mdx-code-block +``` **Disable reading time on one page:** @@ -410,7 +419,9 @@ module.exports = { showReadingTime: true, // highlight-start readingTime: ({content, frontMatter, defaultReadingTime}) => - frontMatter.hide_reading_time ? undefined : defaultReadingTime({content}), + frontMatter.hide_reading_time + ? undefined + : defaultReadingTime({content}), // highlight-end }, }, @@ -429,8 +440,10 @@ hide_reading_time: true This page will no longer display the reading time stats! ``` +```mdx-code-block +``` **Pass options to the default reading time function:** @@ -452,8 +465,10 @@ module.exports = { }; ``` +```mdx-code-block +``` **Use a custom implementation of reading time:** @@ -475,9 +490,10 @@ module.exports = { }; ``` +```mdx-code-block -```` +``` ::: @@ -592,7 +608,7 @@ By default, the classic theme assumes only one blog per website and hence includ Set the `routeBasePath` to the URL route that you want your second blog to be accessed on. Note that the `routeBasePath` here has to be different from the first blog or else there could be a collision of paths! Also, set `path` to the path to the directory containing your second blog's entries. -As documented for [multi-instance plugins](./using-plugins.md#multi-instance-plugins-and-plugin-ids), you need to assign a unique id to the plugins. +As documented for [multi-instance plugins](./using-plugins.md#multi-instance-plugins-and-plugin-ids), you need to assign a unique ID to the plugins. ```js title="docusaurus.config.js" module.exports = { diff --git a/website/docs/browser-support.md b/website/docs/browser-support.md index a4098122e2c4..404601d8f45e 100644 --- a/website/docs/browser-support.md +++ b/website/docs/browser-support.md @@ -71,7 +71,7 @@ And browsers used in development are: - The latest version of Chrome _or_ Firefox _or_ Safari. -You can "evaluate" any config with the `browserslist` cli to obtain the actual list: +You can "evaluate" any config with the `browserslist` CLI to obtain the actual list: ```bash npx browserslist --env="production" diff --git a/website/docs/cli.md b/website/docs/cli.md index 92bf71a80633..2f4f68d85cdf 100644 --- a/website/docs/cli.md +++ b/website/docs/cli.md @@ -41,7 +41,7 @@ Builds and serves a preview of your site locally with [Webpack Dev Server](https | `--host` | `localhost` | Specify a host to use. For example, if you want your server to be accessible externally, you can use `--host 0.0.0.0`. | | `--hot-only` | `false` | Enables Hot Module Replacement without page refresh as a fallback in case of build failures. More information [here](https://webpack.js.org/configuration/dev-server/#devserverhotonly). | | `--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` | +| `--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. | @@ -87,13 +87,15 @@ Compiles your site for production. | --- | --- | --- | | `--bundle-analyzer` | `false` | Analyze your bundle with the [webpack bundle analyzer](https://github.com/webpack-contrib/webpack-bundle-analyzer). | | `--out-dir` | `build` | The full path for the new output directory, relative to the current workspace. | -| `--config` | `undefined` | Path to docusaurus config file, default to `[siteDir]/docusaurus.config.js` | +| `--config` | `undefined` | Path to Docusaurus config file, default to `[siteDir]/docusaurus.config.js` | | `--no-minify` | `false` | Build website without minimizing JS/CSS bundles. | :::info For advanced minification of CSS bundle, we use the [advanced cssnano preset](https://github.com/cssnano/cssnano/tree/master/packages/cssnano-preset-advanced) (along with additional several PostCSS plugins) and [level 2 optimization of clean-css](https://github.com/jakubpawlowicz/clean-css#level-2-optimizations). If as a result of this advanced CSS minification you find broken CSS, build your website with the environment variable `USE_SIMPLE_CSS_MINIFIER=true` to minify CSS with the [default cssnano preset](https://github.com/cssnano/cssnano/tree/master/packages/cssnano-preset-default). **Please [fill out an issue](https://github.com/facebook/docusaurus/issues/new?labels=bug%2C+needs+triage&template=bug.md) if you experience CSS minification bugs.** +You can skip the HTML minification with the environment variable `SKIP_HTML_MINIFICATION=true`. + ::: ### `docusaurus swizzle [themeName] [componentName] [siteDir]` {#docusaurus-swizzle} @@ -137,7 +139,7 @@ Deploys your site with [GitHub Pages](https://pages.github.com/). Check out the | --- | --- | --- | | `--out-dir` | `build` | The full path for the new output directory, relative to the current workspace. | | `--skip-build` | `false` | Deploy website without building it. This may be useful when using a custom deploy script. | -| `--config` | `undefined` | Path to docusaurus config file, default to `[siteDir]/docusaurus.config.js` | +| `--config` | `undefined` | Path to Docusaurus config file, default to `[siteDir]/docusaurus.config.js` | ### `docusaurus serve [siteDir]` {#docusaurus-serve-sitedir} @@ -148,7 +150,7 @@ Serve your built website locally. | `--port` | `3000` | Use specified port | | `--dir` | `build` | The full path for the output directory, relative to the current workspace | | `--build` | `false` | Build website before serving | -| `--config` | `undefined` | Path to docusaurus config file, default to `[siteDir]/docusaurus.config.js` | +| `--config` | `undefined` | Path to Docusaurus config file, default to `[siteDir]/docusaurus.config.js` | | `--host` | `localhost` | Specify a host to use. For example, if you want your server to be accessible externally, you can use `--host 0.0.0.0`. | | `--no-open` | `false` locally, `true` in CI | Do not open a browser window to the server location. | @@ -168,12 +170,12 @@ By default, the files are written in `website/i18n//...`. | --- | --- | --- | | `--locale` | `` | Define which locale folder you want to write translations the JSON files in | | `--override` | `false` | Override existing translation messages | -| `--config` | `undefined` | Path to docusaurus config file, default to `[siteDir]/docusaurus.config.js` | +| `--config` | `undefined` | Path to Docusaurus config file, default to `[siteDir]/docusaurus.config.js` | | `--messagePrefix` | `''` | Allows adding a prefix to each translation message, to help you highlight untranslated strings | ### `docusaurus write-heading-ids [siteDir] [files]` {#docusaurus-write-heading-ids-sitedir} -Add [explicit heading ids](./guides/markdown-features/markdown-features-toc.mdx#explicit-ids) to the Markdown documents of your site. +Add [explicit heading IDs](./guides/markdown-features/markdown-features-toc.mdx#explicit-ids) to the Markdown documents of your site. | Name | Default | Description | | --- | --- | --- | diff --git a/website/docs/configuration.md b/website/docs/configuration.md index fcfc92e0bc17..eb192c6f9201 100644 --- a/website/docs/configuration.md +++ b/website/docs/configuration.md @@ -179,4 +179,4 @@ module.exports = { }; ``` -Most of the time, this configuration will work just fine. If you want to customize your babel configuration (e.g. to add support for Flow), you can directly edit this file. For your changes to take effect, you need to restart the Docusaurus dev server. +Most of the time, this configuration will work just fine. If you want to customize your Babel configuration (e.g. to add support for Flow), you can directly edit this file. For your changes to take effect, you need to restart the Docusaurus dev server. diff --git a/website/docs/deployment.mdx b/website/docs/deployment.mdx index ded6aca33f88..f951d73d7b4f 100644 --- a/website/docs/deployment.mdx +++ b/website/docs/deployment.mdx @@ -183,8 +183,8 @@ Some Docusaurus sites put the `docs` folder outside of `website` (most likely fo ```bash repo # git root -├── docs # md files -└── website # docusaurus root +├── docs # MD files +└── website # Docusaurus root ``` If you decide to use the `website` folder as Netlify's base directory, Netlify will not trigger builds when you update the `docs` folder, and you need to configure a [custom `ignore` command](https://docs.netlify.com/configure-builds/common-configurations/ignore-builds/): @@ -302,31 +302,37 @@ GitHub enterprise installations should work in the same manner as github.com; yo Finally, to deploy your site to GitHub Pages, run: -````mdx-code-block +```mdx-code-block +``` ```bash GIT_USER= yarn deploy ``` +```mdx-code-block +``` ```batch cmd /C "set "GIT_USER=" && yarn deploy" ``` +````mdx-code-block +```mdx-code-block ```powershell cmd /C 'set "GIT_USER=" && yarn deploy' -``` +```` +```mdx-code-block -```` +``` :::caution @@ -352,23 +358,23 @@ Here are two approaches to deploying your docs with GitHub Actions. Based on the - Source repo and deployment repo are the **same** repository. - The deployment repo is a **remote** repository, different from the source. -````mdx-code-block +```mdx-code-block +``` While you can have both jobs defined in the same workflow file, the original `deploy` workflow will always be listed as skipped in the PR check suite status, which is not communicative of the actual status and provides no value to the review process. We therefore propose to manage them as separate workflows instead. We will use a popular third-party deployment action: [peaceiris/actions-gh-pages](https://github.com/peaceiris/actions-gh-pages#%EF%B8%8F-docusaurus).
- GitHub action files Add these two workflow files: :::warning Tweak the parameters for your setup -These files assume you are using yarn. If you use npm, change `cache: yarn`, `yarn install --frozen-lockfile`, `yarn build` to `cache: npm`, `npm ci`, `npm run build` accordingly. +These files assume you are using Yarn. If you use npm, change `cache: yarn`, `yarn install --frozen-lockfile`, `yarn build` to `cache: npm`, `npm ci`, `npm run build` accordingly. If your Docusaurus project is not at the root of your repo, you may need to configure a [default working directory](https://docs.github.com/en/actions/using-workflows/workflow-syntax-for-github-actions#example-set-the-default-shell-and-working-directory), and adjust the paths accordingly. @@ -392,7 +398,7 @@ jobs: - uses: actions/checkout@v2 - uses: actions/setup-node@v3 with: - node-version: 16.x + node-version: 18 cache: yarn - name: Install dependencies @@ -435,7 +441,7 @@ jobs: - uses: actions/checkout@v2 - uses: actions/setup-node@v3 with: - node-version: 16.x + node-version: 18 cache: yarn - name: Install dependencies @@ -446,8 +452,10 @@ jobs:
+```mdx-code-block
+``` A cross-repo publish is more difficult to set up, because you need to push to another repo with permission checks. We will be using SSH to do the authentication. @@ -466,7 +474,7 @@ A cross-repo publish is more difficult to set up, because you need to push to an Please make sure that you replace `actions@github.com` with your GitHub email and `gh-actions` with your name. -This file assumes you are using yarn. If you use npm, change `cache: yarn`, `yarn install --frozen-lockfile`, `yarn build` to `cache: npm`, `npm ci`, `npm run build` accordingly. +This file assumes you are using Yarn. If you use npm, change `cache: yarn`, `yarn install --frozen-lockfile`, `yarn build` to `cache: npm`, `npm ci`, `npm run build` accordingly. ::: @@ -487,7 +495,7 @@ jobs: - uses: actions/checkout@v2 - uses: actions/setup-node@v3 with: - node-version: 16.x + node-version: 18 cache: yarn - name: Install dependencies run: yarn install --frozen-lockfile @@ -500,7 +508,7 @@ jobs: - uses: actions/checkout@v2 - uses: actions/setup-node@v3 with: - node-version: 16.x + node-version: 18 cache: yarn - uses: webfactory/ssh-agent@v0.5.0 with: @@ -517,9 +525,10 @@ jobs:
+```mdx-code-block -```` +``` ### Triggering deployment with Travis CI {#triggering-deployment-with-travis-ci} @@ -534,7 +543,7 @@ Continuous integration (CI) services are typically used to perform routine tasks ```yml title=".travis.yml" language: node_js node_js: - - '14.15.0' + - 18 branches: only: - main @@ -576,9 +585,9 @@ After creating this simple pipeline, each new commit pushed to the branch you se ### Using Azure Pipelines {#using-azure-pipelines} 1. Sign Up at [Azure Pipelines](https://azure.microsoft.com/en-us/services/devops/pipelines/) if you haven't already. -2. Create an organization and within the organization create a project and connect your repository from GitHub. +2. Create an organization. Within the organization, create a project and connect your repository from GitHub. 3. Go to https://github.com/settings/tokens and generate a new [personal access token](https://help.github.com/articles/creating-a-personal-access-token-for-the-command-line/) with the `repo` scope. -4. In the project page (which looks like `https://dev.azure.com/ORG_NAME/REPO_NAME/_build` create a new pipeline with the following text. Also, click on edit and add a new environment variable named `GH_TOKEN` with your newly generated token as its value, then `GH_EMAIL` (your email address) and `GH_NAME` (your GitHub username). Make sure to mark them as secret. Alternatively, you can also add a file named `azure-pipelines.yml` at your repository root. +4. In the project page (which looks like `https://dev.azure.com/ORG_NAME/REPO_NAME/_build`), create a new pipeline with the following text. Also, click on edit and add a new environment variable named `GH_TOKEN` with your newly generated token as its value, then `GH_EMAIL` (your email address) and `GH_NAME` (your GitHub username). Make sure to mark them as secret. Alternatively, you can also add a file named `azure-pipelines.yml` at your repository root. ```yml title="azure-pipelines.yml" trigger: @@ -593,7 +602,7 @@ steps: - task: NodeTool@0 inputs: - versionSpec: 14.x + versionSpec: '18' displayName: Install Node.js - script: | @@ -612,8 +621,8 @@ steps: ### Using Drone {#using-drone} -1. Create a new ssh key that will be the [deploy key](https://docs.github.com/en/free-pro-team@latest/developers/overview/managing-deploy-keys#deploy-keys) for your project. -2. Name your private and public keys to be specific and so that it does not overwrite your other [ssh keys](https://docs.github.com/en/free-pro-team@latest/github/authenticating-to-github/generating-a-new-ssh-key-and-adding-it-to-the-ssh-agent). +1. Create a new SSH key that will be the [deploy key](https://docs.github.com/en/free-pro-team@latest/developers/overview/managing-deploy-keys#deploy-keys) for your project. +2. Name your private and public keys to be specific and so that it does not overwrite your other [SSH keys](https://docs.github.com/en/free-pro-team@latest/github/authenticating-to-github/generating-a-new-ssh-key-and-adding-it-to-the-ssh-agent). 3. Go to `https://github.com/USERNAME/REPO/settings/keys` and add a new deploy key by pasting in the public key you just generated. 4. Open your Drone.io dashboard and log in. The URL looks like `https://cloud.drone.io/USERNAME/REPO`. 5. Click on the repository, click on activate repository, and add a secret called `git_deploy_private_key` with your private key value that you just generated. diff --git a/website/docs/docusaurus-core.md b/website/docs/docusaurus-core.md index 807727872e16..ee932f0eed6e 100644 --- a/website/docs/docusaurus-core.md +++ b/website/docs/docusaurus-core.md @@ -479,7 +479,7 @@ Prefer a `require()` call for [assets](./guides/markdown-features/markdown-featu ### `useBaseUrlUtils` {#useBaseUrlUtils} -Sometimes `useBaseUrl` is not good enough. This hook return additional utils related to your site's base url. +Sometimes `useBaseUrl` is not good enough. This hook return additional utils related to your site's base URL. - `withBaseUrl`: useful if you need to add base URLs to multiple URLs at once. diff --git a/website/docs/guides/creating-pages.md b/website/docs/guides/creating-pages.md index 0f5839213a5c..fbc89e20d6ce 100644 --- a/website/docs/guides/creating-pages.md +++ b/website/docs/guides/creating-pages.md @@ -51,7 +51,7 @@ export default function Hello() { } ``` -Once you save the file, the development server will automatically reload the changes. Now open `http://localhost:3000/helloReact` and you will see the new page you just created. +Once you save the file, the development server will automatically reload the changes. Now open [http://localhost:3000/helloReact](http://localhost:3000/helloReact) and you will see the new page you just created. Each page doesn't come with any styling. You will need to import the `Layout` component from `@theme/Layout` and wrap your contents within that component if you want the navbar and/or footer to appear. @@ -77,7 +77,7 @@ hide_table_of_contents: true How are you? ``` -In the same way, a page will be created at `http://localhost:3000/helloMarkdown`. +In the same way, a page will be created at [http://localhost:3000/helloMarkdown](http://localhost:3000/helloMarkdown). Markdown pages are less flexible than React pages because it always uses the theme layout. diff --git a/website/docs/guides/docs/docs-create-doc.mdx b/website/docs/guides/docs/docs-create-doc.mdx index c683f2894e74..5221a2a0e37d 100644 --- a/website/docs/guides/docs/docs-create-doc.mdx +++ b/website/docs/guides/docs/docs-create-doc.mdx @@ -45,9 +45,9 @@ The headers are well-spaced so that the hierarchy is clear. - and you may nest them - multiple times -## Custom id headers {#custom-id} +## Custom ID headers {#custom-id} -With `{#custom-id}` syntax you can set your own header id. +With `{#custom-id}` syntax you can set your own header ID. ``` :::note @@ -92,7 +92,7 @@ How the Markdown files are arranged under the `docs` folder can have multiple im Every document has a unique `id`. By default, a document `id` is the name of the document (without the extension) relative to the root docs directory. -For example, `greeting.md` id is `greeting` and `guide/hello.md` id is `guide/hello`. +For example, the ID of `greeting.md` is `greeting`, and the ID of `guide/hello.md` is `guide/hello`. ```bash website # Root directory of your site diff --git a/website/docs/guides/docs/docs-multi-instance.mdx b/website/docs/guides/docs/docs-multi-instance.mdx index 0f267fcbe174..69a1a1656ce2 100644 --- a/website/docs/guides/docs/docs-multi-instance.mdx +++ b/website/docs/guides/docs/docs-multi-instance.mdx @@ -135,7 +135,7 @@ Don't forget to assign a unique `id` attribute to plugin instances. :::note -We consider that the `product` instance is the most important one, and make it the "default" instance by not assigning any id. +We consider that the `product` instance is the most important one, and make it the "default" instance by not assigning any ID. ::: @@ -165,7 +165,7 @@ The instance paths will be simpler, and retro-compatible with a single-instance ## Tagging new versions {#tagging-new-versions} -Each plugin instance will have its own cli command to tag a new version. They will be displayed if you run: +Each plugin instance will have its own CLI command to tag a new version. They will be displayed if you run: ```bash npm2yarn npm run docusaurus -- --help diff --git a/website/docs/guides/docs/sidebar/autogenerated.md b/website/docs/guides/docs/sidebar/autogenerated.md index a8268f45813c..88361f969dcc 100644 --- a/website/docs/guides/docs/sidebar/autogenerated.md +++ b/website/docs/guides/docs/sidebar/autogenerated.md @@ -411,7 +411,7 @@ By default, Docusaurus will **remove the number prefix** from the doc id, title, **Prefer using [additional metadata](#autogenerated-sidebar-metadata)**. -Updating a number prefix can be annoying, as it can require **updating multiple existing markdown links**: +Updating a number prefix can be annoying, as it can require **updating multiple existing Markdown links**: ```diff title="docs/02-Tutorial Easy/01-First Part.md" - Check the [Tutorial End](../04-End.md); diff --git a/website/docs/guides/docs/sidebar/index.md b/website/docs/guides/docs/sidebar/index.md index 74d601cb9256..06eb5a91b3b9 100644 --- a/website/docs/guides/docs/sidebar/index.md +++ b/website/docs/guides/docs/sidebar/index.md @@ -198,7 +198,7 @@ A real-world example from the Docusaurus site: ```mdx-code-block import CodeBlock from '@theme/CodeBlock'; - + {require('!!raw-loader!@site/sidebars.js') .default .split('\n') diff --git a/website/docs/guides/docs/sidebar/items.md b/website/docs/guides/docs/sidebar/items.md index 04faf577a7e7..6a67d8ee5898 100644 --- a/website/docs/guides/docs/sidebar/items.md +++ b/website/docs/guides/docs/sidebar/items.md @@ -60,7 +60,7 @@ module.exports = { }; ``` -If you use the doc shorthand or [autogenerated](#sidebar-item-autogenerated) sidebar, you would lose the ability to customize the sidebar label through item definition. You can, however, use the `sidebar_label` markdown front matter within that doc, which has higher precedence over the `label` key in the sidebar item. Similarly, you can use `sidebar_custom_props` to declare custom metadata for a doc page. +If you use the doc shorthand or [autogenerated](#sidebar-item-autogenerated) sidebar, you would lose the ability to customize the sidebar label through item definition. You can, however, use the `sidebar_label` Markdown front matter within that doc, which has higher precedence over the `label` key in the sidebar item. Similarly, you can use `sidebar_custom_props` to declare custom metadata for a doc page. :::note @@ -404,8 +404,10 @@ You can express typical sidebar items without much customization more concisely An item with type `doc` can be simply a string representing its ID: +```mdx-code-block +``` ```js title="sidebars.js" module.exports = { @@ -420,8 +422,10 @@ module.exports = { }; ``` +```mdx-code-block +``` ```js title="sidebars.js" module.exports = { @@ -433,8 +437,10 @@ module.exports = { }; ``` +```mdx-code-block +``` So it's possible to simplify the example above to: @@ -472,8 +478,10 @@ module.exports = { A category item can be represented by an object whose key is its label, and the value is an array of subitems. +```mdx-code-block +``` ```js title="sidebars.js" module.exports = { @@ -489,8 +497,10 @@ module.exports = { }; ``` +```mdx-code-block +``` ```js title="sidebars.js" module.exports = { @@ -504,8 +514,10 @@ module.exports = { }; ``` +```mdx-code-block +``` This permits us to simplify that example to: @@ -553,8 +565,10 @@ Note how the two consecutive category shorthands are compressed into one object Wherever you have an array of items that is reduced to one category shorthand, you can omit that enclosing array as well. +```mdx-code-block +``` ```js title="sidebars.js" module.exports = { @@ -572,8 +586,10 @@ module.exports = { }; ``` +```mdx-code-block +``` ```js title="sidebars.js" module.exports = { @@ -587,5 +603,7 @@ module.exports = { }; ``` +```mdx-code-block +``` diff --git a/website/docs/guides/docs/versioning.md b/website/docs/guides/docs/versioning.md index 082b6ffb3d51..d2b3cd4f0a34 100644 --- a/website/docs/guides/docs/versioning.md +++ b/website/docs/guides/docs/versioning.md @@ -102,8 +102,10 @@ When tagging a new version, the document versioning mechanism will: 1. Place the new file into the corresponding version folder. 2. Include the reference to the new file in the corresponding sidebar file according to the version number. +```mdx-code-block +``` ```bash # The new file. @@ -113,8 +115,10 @@ docs/new.md sidebars.js ``` +```mdx-code-block +``` ```bash # The new file. @@ -124,8 +128,10 @@ versioned_docs/version-1.0.0/new.md versioned_sidebars/version-1.0.0-sidebars.json ``` +```mdx-code-block +``` ### Updating an existing version {#updating-an-existing-version} diff --git a/website/docs/guides/markdown-features/markdown-features-admonitions.mdx b/website/docs/guides/markdown-features/markdown-features-admonitions.mdx index a864fe0d4f50..719dd371c93b 100644 --- a/website/docs/guides/markdown-features/markdown-features-admonitions.mdx +++ b/website/docs/guides/markdown-features/markdown-features-admonitions.mdx @@ -18,68 +18,70 @@ Example: ```md :::note -Some **content** with _markdown_ `syntax`. Check [this `api`](#). +Some **content** with _Markdown_ `syntax`. Check [this `api`](#). ::: :::tip -Some **content** with _markdown_ `syntax`. Check [this `api`](#). +Some **content** with _Markdown_ `syntax`. Check [this `api`](#). ::: :::info -Some **content** with _markdown_ `syntax`. Check [this `api`](#). +Some **content** with _Markdown_ `syntax`. Check [this `api`](#). ::: :::caution -Some **content** with _markdown_ `syntax`. Check [this `api`](#). +Some **content** with _Markdown_ `syntax`. Check [this `api`](#). ::: :::danger -Some **content** with _markdown_ `syntax`. Check [this `api`](#). +Some **content** with _Markdown_ `syntax`. Check [this `api`](#). ::: ``` +```mdx-code-block :::note -Some **content** with _markdown_ `syntax`. Check [this `api`](#). +Some **content** with _Markdown_ `syntax`. Check [this `api`](#). ::: :::tip -Some **content** with _markdown_ `syntax`. Check [this `api`](#). +Some **content** with _Markdown_ `syntax`. Check [this `api`](#). ::: :::info -Some **content** with _markdown_ `syntax`. Check [this `api`](#). +Some **content** with _Markdown_ `syntax`. Check [this `api`](#). ::: :::caution -Some **content** with _markdown_ `syntax`. Check [this `api`](#). +Some **content** with _Markdown_ `syntax`. Check [this `api`](#). ::: :::danger -Some **content** with _markdown_ `syntax`. Check [this `api`](#). +Some **content** with _Markdown_ `syntax`. Check [this `api`](#). ::: +``` ## Usage with Prettier {#usage-with-prettier} @@ -110,20 +112,22 @@ You may also specify an optional title ```md :::note Your Title -Some **content** with _markdown_ `syntax`. +Some **content** with _Markdown_ `syntax`. ::: ``` +```mdx-code-block :::note Your Title -Some **content** with _markdown_ `syntax`. +Some **content** with _Markdown_ `syntax`. ::: +``` ## Admonitions with MDX {#admonitions-with-mdx} @@ -145,21 +149,21 @@ import TabItem from '@theme/TabItem'; ::: ``` +```mdx-code-block :::tip Use tabs in admonitions -```mdx-code-block This is an apple 🍎 This is an orange 🍊 This is a banana 🍌 -``` ::: +``` ## Usage in JSX {#usage-in-jsx} @@ -190,6 +194,7 @@ The types that are accepted are the same as above: `note`, `tip`, `danger`, `inf ``` +```mdx-code-block

@@ -198,3 +203,4 @@ The types that are accepted are the same as above: `note`, `tip`, `danger`, `inf

+``` diff --git a/website/docs/guides/markdown-features/markdown-features-assets.mdx b/website/docs/guides/markdown-features/markdown-features-assets.mdx index c4ba65dfa6e2..58c875c810ef 100644 --- a/website/docs/guides/markdown-features/markdown-features-assets.mdx +++ b/website/docs/guides/markdown-features/markdown-features-assets.mdx @@ -27,8 +27,10 @@ Let's imagine the following file structure: You can display images in three different ways: Markdown syntax, CJS require, or ES imports syntax. +```mdx-code-block +``` Display images using simple Markdown syntax: @@ -36,8 +38,10 @@ Display images using simple Markdown syntax: ![Example banner](./assets/docusaurus-asset-example-banner.png) ``` +```mdx-code-block +``` Display images using inline CommonJS `require` in JSX image tag: @@ -48,8 +52,10 @@ Display images using inline CommonJS `require` in JSX image tag: /> ``` +```mdx-code-block +``` Display images using ES `import` syntax and JSX image tag: @@ -59,8 +65,10 @@ import myImageUrl from './assets/docusaurus-asset-example-banner.png'; Example banner; ``` +```mdx-code-block +``` All of the above result in displaying the image: @@ -102,7 +110,7 @@ or -:::info markdown links are always file paths +:::info Markdown links are always file paths If you use the Markdown image or link syntax, all asset paths will be resolved as file paths by Docusaurus and automatically converted to `require()` calls. You don't need to use `require()` in Markdown unless you use the JSX syntax, which you do have to handle yourself. diff --git a/website/docs/guides/markdown-features/markdown-features-code-blocks.mdx b/website/docs/guides/markdown-features/markdown-features-code-blocks.mdx index 3661393dea7e..92d3f540b0ff 100644 --- a/website/docs/guides/markdown-features/markdown-features-code-blocks.mdx +++ b/website/docs/guides/markdown-features/markdown-features-code-blocks.mdx @@ -23,7 +23,9 @@ function HelloCodeTitle(props) { ``` ```` +```mdx-code-block +``` ```jsx title="/src/components/HelloCodeTitle.js" function HelloCodeTitle(props) { @@ -31,7 +33,9 @@ function HelloCodeTitle(props) { } ``` +```mdx-code-block +``` ## Syntax highlighting {#syntax-highlighting} @@ -161,8 +165,9 @@ function HighlightMoreText(highlight) { ``` ```` -````mdx-code-block +```mdx-code-block +``` ```js function HighlightSomeText(highlight) { @@ -185,8 +190,9 @@ function HighlightMoreText(highlight) { } ``` +```mdx-code-block -```` +``` Supported commenting syntax: @@ -235,8 +241,9 @@ export default MyComponent; ``` ```` -````mdx-code-block +```mdx-code-block +``` ```jsx {1,4-6,11} import React from 'react'; @@ -252,8 +259,9 @@ function MyComponent(props) { export default MyComponent; ``` +```mdx-code-block -```` +``` :::tip prefer comments @@ -347,8 +355,9 @@ console.log(name.toUpperCase()); ``` -````mdx-code-block +```mdx-code-block +``` In JavaScript, trying to access properties on `null` will error. @@ -359,8 +368,9 @@ console.log(name.toUpperCase()); // Uncaught TypeError: Cannot read properties of null (reading 'toUpperCase') ``` +```mdx-code-block -```` +``` If you use number ranges in metastring (the `{1,3-4}` syntax), Docusaurus will apply the **first `magicComments` entry**'s class name. This, by default, is `theme-code-block-highlighted-line`, but if you change the `magicComments` config and use a different entry as the first one, the meaning of the metastring range will change as well. @@ -396,8 +406,9 @@ export default MyComponent; ``` ```` -````mdx-code-block +```mdx-code-block +``` ```jsx {1,4-6,11} showLineNumbers import React from 'react'; @@ -413,8 +424,9 @@ function MyComponent(props) { export default MyComponent; ``` +```mdx-code-block -```` +``` ## Interactive code editor {#interactive-code-editor} @@ -443,7 +455,7 @@ To use the plugin, create a code block with `live` attached to the language meta function Clock(props) { const [date, setDate] = useState(new Date()); useEffect(() => { - var timerID = setInterval(() => tick(), 1000); + const timerID = setInterval(() => tick(), 1000); return function cleanup() { clearInterval(timerID); @@ -465,14 +477,15 @@ function Clock(props) { The code block will be rendered as an interactive editor. Changes to the code will reflect on the result panel live. -````mdx-code-block +```mdx-code-block +``` ```jsx live function Clock(props) { const [date, setDate] = useState(new Date()); useEffect(() => { - var timerID = setInterval(() => tick(), 1000); + const timerID = setInterval(() => tick(), 1000); return function cleanup() { clearInterval(timerID); @@ -491,8 +504,9 @@ function Clock(props) { } ``` +```mdx-code-block -```` +``` ### Imports {#imports} @@ -541,8 +555,9 @@ export default ReactLiveScope; The `ButtonExample` component is now available to use: -````mdx-code-block +```mdx-code-block +``` ```jsx live function MyPlayground(props) { @@ -554,6 +569,43 @@ function MyPlayground(props) { } ``` +```mdx-code-block + +``` + +### Imperative Rendering (noInline) + +The `noInline` option should be used to avoid errors when your code spans multiple components or variables. + +````md +```jsx live noInline +const project = 'Docusaurus'; + +const Greeting = () =>

Hello {project}!

; + +render(); +``` +```` + +Unlike an ordinary interactive code block, when using `noInline` React Live won't wrap your code in an inline function to render it. + +You will need to explicitly call `render()` at the end of your code to display the output. + +````mdx-code-block + + +```jsx live noInline +const project = "Docusaurus"; + +const Greeting = () => ( +

Hello {project}!

+); + +render( + +); +``` +
```` @@ -646,10 +698,11 @@ class HelloWorld { And you will get the following: -````mdx-code-block +```mdx-code-block +``` ```js function helloWorld() { @@ -657,16 +710,20 @@ function helloWorld() { } ``` +```mdx-code-block +``` ```py def hello_world(): print("Hello, world!") ``` +```mdx-code-block +``` ```java class HelloWorld { @@ -676,10 +733,11 @@ class HelloWorld { } ``` +```mdx-code-block -```` +``` If you have multiple of these multi-language code tabs, and you want to sync the selection across the tab instances, refer to the [Syncing tab choices section](markdown-features-tabs.mdx#syncing-tab-choices). @@ -755,6 +813,7 @@ export default function MyReactPage() { } ``` +```mdx-code-block +``` The props accepted are `language`, `title` and `showLineNumbers`, in the same way as you write Markdown code blocks. diff --git a/website/docs/guides/markdown-features/markdown-features-math-equations.mdx b/website/docs/guides/markdown-features/markdown-features-math-equations.mdx index 1f6e32282518..631a9dbaa5d3 100644 --- a/website/docs/guides/markdown-features/markdown-features-math-equations.mdx +++ b/website/docs/guides/markdown-features/markdown-features-math-equations.mdx @@ -132,7 +132,7 @@ module.exports = { ## Self-hosting KaTeX assets {#self-hosting-katex-assets} -Loading stylesheets, fonts, and javascript libraries from CDN sources is a good practice for popular libraries and assets, since it reduces the amount of assets you have to host. In case you prefer to self-host the `katex.min.css` (along with required KaTeX fonts), you can download the latest version from [KaTeX GitHub releases](https://github.com/KaTeX/KaTeX/releases), extract and copy `katex.min.css` and `fonts` directory (only `.woff2` font types should be enough) to your site's `static` directory, and in `docusaurus.config.js`, replace the stylesheet's `href` from the CDN url to your local path (say, `/katex/katex.min.css`). +Loading stylesheets, fonts, and JavaScript libraries from CDN sources is a good practice for popular libraries and assets, since it reduces the amount of assets you have to host. In case you prefer to self-host the `katex.min.css` (along with required KaTeX fonts), you can download the latest version from [KaTeX GitHub releases](https://github.com/KaTeX/KaTeX/releases), extract and copy `katex.min.css` and `fonts` directory (only `.woff2` font types should be enough) to your site's `static` directory, and in `docusaurus.config.js`, replace the stylesheet's `href` from the CDN URL to your local path (say, `/katex/katex.min.css`). ```js title="docusaurus.config.js" module.exports = { diff --git a/website/docs/guides/markdown-features/markdown-features-react.mdx b/website/docs/guides/markdown-features/markdown-features-react.mdx index 0a3e31ba6dd4..5c6b8a5a904f 100644 --- a/website/docs/guides/markdown-features/markdown-features-react.mdx +++ b/website/docs/guides/markdown-features/markdown-features-react.mdx @@ -204,21 +204,22 @@ We use lower-case tag names like `highlight` to "pretend" that they are intrinsi Docusaurus v2 is using MDX v1, which has a lot of known cases where the content fails to be correctly parsed as Markdown. Use the **[MDX playground](https://mdx-git-renovate-babel-monorepo-mdx.vercel.app/playground)** to ensure that your syntax is valid MDX. -````mdx-code-block
- Samples of parsing failures **A paragraph starting with a JSX tag will be seen entirely as a JSX string:** +```mdx-code-block
+``` ```jsx Highlighted text but afterwards _Markdown_ **doesn't work** ``` +```mdx-code-block
@@ -233,6 +234,7 @@ Docusaurus v2 is using MDX v1, which has a lot of known cases where the content Use JSX for the rest of the line, or prefix the line with some plain text:
+``` ```jsx Use JSX for the paragraph to stop worrying about Markdown @@ -240,6 +242,7 @@ Use JSX for the rest of the line, or prefix the line with some plain text: ​← This is a zero-width space and afterwards Markdown works ``` +```mdx-code-block
@@ -258,11 +261,13 @@ Use JSX for the rest of the line, or prefix the line with some plain text:
+``` ```jsx **Bold doesn't work** ``` +```mdx-code-block
@@ -278,6 +283,7 @@ Use JSX for the rest of the line, or prefix the line with some plain text: Use JSX within JSX tag, or move the Markdown to the outer layer:
+``` ```jsx Bold now works @@ -285,6 +291,7 @@ Use JSX within JSX tag, or move the Markdown to the outer layer: **Bold now works** ``` +```mdx-code-block
@@ -303,13 +310,16 @@ Use JSX within JSX tag, or move the Markdown to the outer layer:
+``` + ```jsx
**Bold still doesn't work**
``` +```mdx-code-block
@@ -326,7 +336,9 @@ Use JSX within JSX tag, or move the Markdown to the outer layer: Add an empty new line:
+``` + ```jsx
@@ -335,6 +347,7 @@ Add an empty new line:
``` +```mdx-code-block
@@ -353,7 +366,9 @@ Add an empty new line:
+``` + ```jsx
@@ -362,6 +377,7 @@ Add an empty new line:
``` +```mdx-code-block
@@ -380,7 +396,9 @@ Add an empty new line: Don't indent:
+``` + ```jsx
@@ -389,6 +407,7 @@ Now I'm actually just text
``` +```mdx-code-block
@@ -402,7 +421,7 @@ Now I'm actually just text
-```` +``` ## Importing code snippets {#importing-code-snippets} @@ -452,7 +471,7 @@ This feature is experimental and might be subject to breaking API changes in the You can use Markdown files as components and import them elsewhere, either in Markdown files or in React pages. -By convention, using the **`_` filename prefix** will not create any doc page and means the markdown file is a **"partial"**, to be imported by other files. +By convention, using the **`_` filename prefix** will not create any doc page and means the Markdown file is a **"partial"**, to be imported by other files. ```md title="_markdown-partial-example.mdx" Hello {props.name} diff --git a/website/docs/guides/markdown-features/markdown-features-toc.mdx b/website/docs/guides/markdown-features/markdown-features-toc.mdx index 1cc1ed43d27c..b31e0418225b 100644 --- a/website/docs/guides/markdown-features/markdown-features-toc.mdx +++ b/website/docs/guides/markdown-features/markdown-features-toc.mdx @@ -34,7 +34,7 @@ Each heading has an ID that can be automatically generated or explicitly specifi link ``` -By default, Docusaurus will generate heading IDs for you, based on the heading text. For example, `### Hello World` will have id `hello-world`. +By default, Docusaurus will generate heading IDs for you, based on the heading text. For example, `### Hello World` will have ID `hello-world`. Generated IDs have **some limitations**: @@ -49,7 +49,7 @@ A special Markdown syntax lets you set an **explicit heading id**: :::tip -Use the **[write-heading-ids](../../cli.md#docusaurus-write-heading-ids-sitedir)** CLI command to add explicit ids to all your Markdown documents. +Use the **[write-heading-ids](../../cli.md#docusaurus-write-heading-ids-sitedir)** CLI command to add explicit IDs to all your Markdown documents. ::: @@ -61,7 +61,7 @@ Generated heading IDs will be guaranteed to be unique on each page, but if you u ## Inline table of contents {#inline-table-of-contents} -Each Markdown document displays a table of contents on the top-right corner. But it is also possible to display an inline table of contents directly inside a markdown document, thanks to MDX. +Each Markdown document displays a table of contents on the top-right corner. But it is also possible to display an inline table of contents directly inside a Markdown document, thanks to MDX. The `toc` variable is available in any MDX document and contains all the headings of an MDX document. By default, only `h2` and `h3` headings are displayed in the TOC. You can change which heading levels are visible by setting `minHeadingLevel` or `maxHeadingLevel` for individual `TOCInline` components. @@ -121,7 +121,7 @@ The table-of-contents is generated by parsing the Markdown source with a [Remark Markdown headings within hideable areas will still show up in the TOC. For example, headings within [`Tabs`](./markdown-features-tabs.mdx) and [`details`](./markdown-features-intro.mdx#details) will not be excluded. -Non-markdown headings will not show up in the TOC. This can be used to your advantage to tackle the aforementioned issue. +Non-Markdown headings will not show up in the TOC. This can be used to your advantage to tackle the aforementioned issue. ```md
diff --git a/website/docs/i18n/i18n-crowdin.mdx b/website/docs/i18n/i18n-crowdin.mdx index c7f0ca21930b..b8b1270e9baf 100644 --- a/website/docs/i18n/i18n-crowdin.mdx +++ b/website/docs/i18n/i18n-crowdin.mdx @@ -288,7 +288,7 @@ Start your site on the French locale: npm run start -- --locale fr ``` -Make sure that your website is now translated in French at `http://localhost:3000/fr/`. +Make sure that your website is now translated in French at [http://localhost:3000/fr/](http://localhost:3000/fr/). ### Automate with CI {#automate-with-ci} @@ -444,7 +444,7 @@ Crowdin has an [In-Context localization](https://support.crowdin.com/in-context- Unfortunately, it does not work yet for technical reasons, but we have good hope it can be solved. -Crowdin replaces markdown strings with technical ids such as `crowdin:id12345`, but it does so too aggressively, including hidden strings, and messes up with front matter, admonitions, JSX... +Crowdin replaces Markdown strings with technical IDs such as `crowdin:id12345`, but it does so too aggressively, including hidden strings, and messes up with front matter, admonitions, JSX... ::: diff --git a/website/docs/i18n/i18n-tutorial.md b/website/docs/i18n/i18n-tutorial.md index d04b61744bec..b7914e87b4e0 100644 --- a/website/docs/i18n/i18n-tutorial.md +++ b/website/docs/i18n/i18n-tutorial.md @@ -76,7 +76,7 @@ Start your localized site in dev mode, using the locale of your choice: npm run start -- --locale fr ``` -Your site is accessible at **`http://localhost:3000/fr/`**. +Your site is accessible at [http://localhost:3000/fr/](http://localhost:3000/fr/). We haven't provided any translation yet, so the site is mostly untranslated. @@ -115,8 +115,10 @@ Locate all text labels in your React code that will be visible to your users, an Use the one that better fits the context semantically. For example, the `` can be used as React children, while for props that expect a string, the callback can be used. +```mdx-code-block +``` ```jsx title="src/pages/index.js" import React from 'react'; @@ -144,8 +146,10 @@ export default function Home() { } ``` +```mdx-code-block +``` ```jsx title="src/pages/index.js" import React from 'react'; @@ -199,8 +203,10 @@ export default function Home() { } ``` +```mdx-code-block +``` :::info @@ -414,18 +420,18 @@ We only copy `.md` and `.mdx` files, as React pages are translated through JSON ::: -:::tip Use explicit heading ids +:::tip Use explicit heading IDs -By default, a Markdown heading `### Hello World` will have a generated id `hello-world`. Other documents can link it with `[link](#hello-world)`. However, after translation, the heading becomes `### Bonjour le Monde`, with id `bonjour-le-monde`. +By default, a Markdown heading `### Hello World` will have a generated ID `hello-world`. Other documents can link it with `[link](#hello-world)`. However, after translation, the heading becomes `### Bonjour le Monde`, with ID `bonjour-le-monde`. -Generated ids are not always a good fit for localized sites, as it requires you to localize all the anchor links: +Generated IDs are not always a good fit for localized sites, as it requires you to localize all the anchor links: ```diff - [link](#hello-world). + [link](#bonjour-le-monde) ``` -For localized sites, it is recommended to use **[explicit heading ids](../guides/markdown-features/markdown-features-toc.mdx#explicit-ids)**. +For localized sites, it is recommended to use **[explicit heading IDs](../guides/markdown-features/markdown-features-toc.mdx#explicit-ids)**. ::: diff --git a/website/docs/introduction.md b/website/docs/introduction.md index c5f4d0106f42..894f88e8269a 100644 --- a/website/docs/introduction.md +++ b/website/docs/introduction.md @@ -36,7 +36,7 @@ cd my-website npx docusaurus start ``` -Open `http://localhost:3000` and follow the tutorial. +Open [http://localhost:3000](http://localhost:3000) and follow the tutorial. :::tip @@ -108,7 +108,7 @@ Our shared goal—to help your users quickly find what they need and understand - HTML files are statically generated for every possible path. - Page-specific SEO to help your users land on your official docs directly relating their problems at hand. - 📝 **Powered by MDX**: - - Write interactive components via JSX and React embedded in markdown. + - Write interactive components via JSX and React embedded in Markdown. - Share your code in live editors to get your users to love your products on the spot. - 🔍 **Search**: Your full site is searchable. - 💾 **Document Versioning**: Helps you keep documentation in sync with project releases. diff --git a/website/docs/migration/migration-manual.md b/website/docs/migration/migration-manual.md index aa641852976a..804a3ca52a86 100644 --- a/website/docs/migration/migration-manual.md +++ b/website/docs/migration/migration-manual.md @@ -15,7 +15,7 @@ This manual migration process should be run after the [automated migration proce In Docusaurus 2, we use scoped package names: -- `docusaurus` -> `@docusaurus/core` +- `docusaurus` → `@docusaurus/core` This provides a clear distinction between Docusaurus' official packages and community maintained packages. In another words, all Docusaurus' official packages are namespaced under `@docusaurus/`. @@ -418,8 +418,8 @@ The following fields are all deprecated, you may remove from your configuration - `facebookPixelId` - `fonts` - `highlight` - We now use [Prism](https://prismjs.com/) instead of [highlight.js](https://highlightjs.org/). -- `markdownOptions` - We use MDX in v2 instead of Remarkable. Your markdown options have to be converted to Remark/Rehype plugins. -- `markdownPlugins` - We use MDX in v2 instead of Remarkable. Your markdown plugins have to be converted to Remark/Rehype plugins. +- `markdownOptions` - We use MDX in v2 instead of Remarkable. Your Markdown options have to be converted to Remark/Rehype plugins. +- `markdownPlugins` - We use MDX in v2 instead of Remarkable. Your Markdown plugins have to be converted to Remark/Rehype plugins. - `manifest` - `onPageNav` - This is turned on by default now. - `separateCss` - It can imported in the same manner as `custom.css` mentioned above. @@ -470,13 +470,13 @@ module.exports = { }; ``` -If you want to keep the `.html` extension as the canonical url of a page, docs can declare a `slug: installation.html` front matter. +If you want to keep the `.html` extension as the canonical URL of a page, docs can declare a `slug: installation.html` front matter. ## Components {#components} ### Sidebar {#sidebar} -In previous version, nested sidebar category is not allowed and sidebar category can only contain doc id. However, v2 allows infinite nested sidebar and we have many types of [Sidebar Item](../guides/docs/sidebar/items.md) other than document. +In previous version, nested sidebar category is not allowed and sidebar category can only contain doc ID. However, v2 allows infinite nested sidebar and we have many types of [Sidebar Item](../guides/docs/sidebar/items.md) other than document. You'll have to migrate your sidebar if it contains category type. Rename `subcategory` to `category` and `ids` to `items`. @@ -577,9 +577,9 @@ This feature is replaced by [inline table of content](../guides/markdown-feature ### Update Markdown syntax to be MDX-compatible {#update-markdown-syntax-to-be-mdx-compatible} -In Docusaurus 2, the markdown syntax has been changed to [MDX](https://mdxjs.com/). Hence there might be some broken syntax in the existing docs which you would have to update. A common example is self-closing tags like `` and `
` which are valid in HTML would have to be explicitly closed now ( `` and `
`). All tags in MDX documents have to be valid JSX. +In Docusaurus 2, the Markdown syntax has been changed to [MDX](https://mdxjs.com/). Hence there might be some broken syntax in the existing docs which you would have to update. A common example is self-closing tags like `` and `
` which are valid in HTML would have to be explicitly closed now ( `` and `
`). All tags in MDX documents have to be valid JSX. -Front matter is parsed by [gray-matter](https://github.com/jonschlinkert/gray-matter). If your front matter use special characters like `:`, you now need to quote it: `title: Part 1: my part1 title` -> `title: Part 1: "my part1 title"`. +Front matter is parsed by [gray-matter](https://github.com/jonschlinkert/gray-matter). If your front matter use special characters like `:`, you now need to quote it: `title: Part 1: my part1 title` → `title: "Part 1: my part1 title"`. **Tips**: You might want to use some online tools like [HTML to JSX](https://transform.tools/html-to-jsx) to make the migration easier. diff --git a/website/docs/migration/migration-overview.md b/website/docs/migration/migration-overview.md index efed50c1acd8..1c450ea03a57 100644 --- a/website/docs/migration/migration-overview.md +++ b/website/docs/migration/migration-overview.md @@ -6,7 +6,7 @@ slug: /migration This doc guides you through migrating an existing Docusaurus 1 site to Docusaurus 2. -We try to make this as easy as possible, and provide a migration cli. +We try to make this as easy as possible, and provide a migration CLI. ## Main differences {#main-differences} @@ -66,9 +66,9 @@ You are free to put the `/docs` folder anywhere you want after having migrated t There are multiple things to migrate to obtain a fully functional Docusaurus 2 website: - packages -- cli commands +- CLI commands - site configuration -- markdown files +- Markdown files - sidebars file - pages, components and CSS - versioned docs @@ -76,13 +76,13 @@ There are multiple things to migrate to obtain a fully functional Docusaurus 2 w ## Automated migration process {#automated-migration-process} -The [migration cli](./migration-automated.md) will handle many things of the migration for you. +The [migration CLI](./migration-automated.md) will handle many things of the migration for you. However, some parts can't easily be automated, and you will have to fallback to the manual process. :::note -We recommend running the migration cli, and complete the missing parts thanks to the manual migration process. +We recommend running the migration CLI, and complete the missing parts thanks to the manual migration process. ::: diff --git a/website/docs/migration/migration-translated-sites.md b/website/docs/migration/migration-translated-sites.md index 9964943f16e2..e8ed65a0d0a4 100644 --- a/website/docs/migration/migration-translated-sites.md +++ b/website/docs/migration/migration-translated-sites.md @@ -110,21 +110,21 @@ Unfortunately, Crowdin does not have any "Duplicate/clone Project" feature, whic - Download the Crowdin translations locally - Try to run/build your site and see if there are any errors -You will likely have errors on your first-try: the pre-translation might try to translate things that it should not be translated (front matter, admonition, code blocks...), and the translated md files might be invalid for the MDX parser. +You will likely have errors on your first-try: the pre-translation might try to translate things that it should not be translated (front matter, admonition, code blocks...), and the translated MD files might be invalid for the MDX parser. -You will have to fix all the errors until your site builds. You can do that by modifying the translated md files locally, and fix your site for one locale at a time using `docusaurus build --locale fr`. +You will have to fix all the errors until your site builds. You can do that by modifying the translated MD files locally, and fix your site for one locale at a time using `docusaurus build --locale fr`. There is no ultimate guide we could write to fix these errors, but common errors are due to: - Not marking enough strings as "hidden strings" in Crowdin, leading to pre-translation trying to translate these strings. -- Having bad v1 translations, leading to invalid markup in v2: bad html elements inside translations and unclosed tags +- Having bad v1 translations, leading to invalid markup in v2: bad HTML elements inside translations and unclosed tags - Anything rejected by the MDX parser, like using HTML elements instead of JSX elements (use the [MDX playground](https://mdxjs.com/playground/) for debugging) You might want to repeat this pre-translation process, eventually trying the "Perfect" option and limiting pre-translation only some languages/files. :::tip -Use [`mdx-code-block`](../i18n/i18n-crowdin.mdx#mdx-solutions) around problematic markdown elements: Crowdin is less likely mess things up with code blocks. +Use [`mdx-code-block`](../i18n/i18n-crowdin.mdx#mdx-solutions) around problematic Markdown elements: Crowdin is less likely mess things up with code blocks. ::: @@ -136,7 +136,7 @@ The Crowdin Markdown parser is evolving other time and each Crowdin project has This parser version is undocumented, and you will have to ask the Crowdin support to know your project's parser version and fix one specific version. -Using the same cli version and parser version across the 2 Crowdin projects might give better results. +Using the same CLI version and parser version across the 2 Crowdin projects might give better results. ::: diff --git a/website/docs/migration/migration-versioned-sites.md b/website/docs/migration/migration-versioned-sites.md index e21dc802fb06..ff9a412271a7 100644 --- a/website/docs/migration/migration-versioned-sites.md +++ b/website/docs/migration/migration-versioned-sites.md @@ -14,7 +14,7 @@ The versioned docs should normally be migrated correctly by the [migration CLI]( ## Migrate your `versioned_docs` front matter {#migrate-your-versioned_docs-front-matter} -Unlike v1, The markdown header for each versioned doc is no longer altered by using `version-${version}-${original_id}` as the value for the actual id field. See scenario below for better explanation. +Unlike v1, The Markdown header for each versioned doc is no longer altered by using `version-${version}-${original_id}` as the value for the actual ID field. See scenario below for better explanation. For example, if you have a `docs/hello.md`. @@ -66,9 +66,9 @@ Hi, Endilie here :) ## Migrate your `versioned_sidebars` {#migrate-your-versioned_sidebars} -- Refer to `versioned_docs` id as `version-${version}/${id}` (v2) instead of `version-${version}-${original_id}` (v1). +- Refer to `versioned_docs` ID as `version-${version}/${id}` (v2) instead of `version-${version}-${original_id}` (v1). -Because in v1 there is a good chance someone created a new file with front matter id `"version-${version}-${id}"` that can conflict with `versioned_docs` id. +Because in v1 there is a good chance someone created a new file with front matter ID `"version-${version}-${id}"` that can conflict with `versioned_docs` ID. For example, Docusaurus 1 can't differentiate `docs/xxx.md` @@ -139,7 +139,7 @@ website │ └── version-1.0.0-sidebars.json ``` -In v2, you have to populate the missing `versioned_docs` and `versioned_sidebars` (with the right front matter and id reference too). +In v2, you have to populate the missing `versioned_docs` and `versioned_sidebars` (with the right front matter and ID reference too). ```bash {3-5,12} website diff --git a/website/docs/static-assets.md b/website/docs/static-assets.md index 08fbacb9e58e..eb9d319b3c87 100644 --- a/website/docs/static-assets.md +++ b/website/docs/static-assets.md @@ -69,7 +69,7 @@ You write a link like this: [Download this document](/files/note.docx) Docusaurus changes that to: Download this document ``` -:::caution use markdown syntax +:::caution use Markdown syntax Docusaurus will only parse links that are in Markdown syntax. If your asset references are using the JSX tag `` / ``, nothing will be done. diff --git a/website/docs/swizzling.md b/website/docs/swizzling.md index d1cf3347a6ae..daa0aa62aa05 100644 --- a/website/docs/swizzling.md +++ b/website/docs/swizzling.md @@ -41,9 +41,10 @@ npm run swizzle It will generate a new component your `src/theme` directory, which should look like this example: -````mdx-code-block +```mdx-code-block +``` ```jsx title="src/theme/SomeComponent.js" import React from 'react'; @@ -60,8 +61,10 @@ export default function SomeComponent(props) { } ``` +```mdx-code-block +``` ```jsx title="src/theme/SomeComponent.js" import React from 'react'; @@ -78,9 +81,10 @@ export default function SomeComponentWrapper(props) { } ``` +```mdx-code-block -```` +``` To get an overview of all the themes and components available to swizzle, run: @@ -237,7 +241,7 @@ Moreover, internal components may simply disappear. If a component is called `Si For each theme component, the swizzle CLI will indicate **3 different levels of safety** declared by theme authors: - **Safe**: this component is safe to be swizzled, its public API is considered stable, and no breaking changes should happen within a theme **major version** -- **Unsafe**: this component is a theme implementation detail, not safe to be swizzled, and breaking changes might happen withing a theme **minor version** +- **Unsafe**: this component is a theme implementation detail, not safe to be swizzled, and breaking changes might happen within a theme **minor version** - **Forbidden**: the swizzle CLI will prevent you from swizzling this component, because it is not designed to be swizzled at all :::note diff --git a/website/docs/using-plugins.md b/website/docs/using-plugins.md index d845e4bbe6f2..e6f83f13e130 100644 --- a/website/docs/using-plugins.md +++ b/website/docs/using-plugins.md @@ -79,9 +79,9 @@ module.exports = { }; ``` -## Multi-instance plugins and plugin ids {#multi-instance-plugins-and-plugin-ids} +## Multi-instance plugins and plugin IDs {#multi-instance-plugins-and-plugin-ids} -All Docusaurus content plugins can support multiple plugin instances. For example, it may be useful to have [multiple docs plugin instances](./guides/docs/docs-multi-instance.mdx) or [multiple blogs](./blog.mdx#multiple-blogs). It is required to assign a unique id to each plugin instance, and by default, the plugin id is `default`. +All Docusaurus content plugins can support multiple plugin instances. For example, it may be useful to have [multiple docs plugin instances](./guides/docs/docs-multi-instance.mdx) or [multiple blogs](./blog.mdx#multiple-blogs). It is required to assign a unique ID to each plugin instance, and by default, the plugin ID is `default`. ```js title="docusaurus.config.js" module.exports = { @@ -224,7 +224,7 @@ Preset paths can be relative to the config file: module.exports = { // ... // highlight-next-line - presets: ['./src/presets/docusaurus-local-preset')], + presets: ['./src/presets/docusaurus-local-preset'], }; ``` diff --git a/website/package.json b/website/package.json index bff9305dd8a1..df7a4b325a23 100644 --- a/website/package.json +++ b/website/package.json @@ -48,7 +48,7 @@ "@docusaurus/utils": "2.0.0-beta.21", "@docusaurus/utils-common": "2.0.0-beta.21", "@popperjs/core": "^2.11.5", - "@swc/core": "^1.2.194", + "@swc/core": "^1.2.197", "clsx": "^1.1.1", "color": "^4.2.3", "fs-extra": "^10.1.0", @@ -61,9 +61,9 @@ "react-popper": "^2.3.0", "rehype-katex": "^6.0.2", "remark-math": "^3.0.1", - "swc-loader": "^0.2.1", + "swc-loader": "^0.2.3", "unist-util-visit": "^2.0.3", - "webpack": "^5.72.1", + "webpack": "^5.73.0", "workbox-routing": "^6.5.3", "workbox-strategies": "^6.5.3" }, @@ -82,7 +82,7 @@ "devDependencies": { "@docusaurus/eslint-plugin": "2.0.0-beta.21", "@tsconfig/docusaurus": "^1.0.5", - "@types/jest": "^27.5.1", + "@types/jest": "^28.1.1", "cross-env": "^7.0.3", "rimraf": "^3.0.2" } diff --git a/website/src/components/ConfigTabs.tsx b/website/src/components/ConfigTabs.tsx new file mode 100644 index 000000000000..4a0622a95e60 --- /dev/null +++ b/website/src/components/ConfigTabs.tsx @@ -0,0 +1,91 @@ +/** + * 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 React from 'react'; +import Link from '@docusaurus/Link'; +import {useActiveVersion} from '@docusaurus/plugin-content-docs/client'; +import Translate, {translate} from '@docusaurus/Translate'; +import Tabs from '@theme/Tabs'; +import TabItem from '@theme/TabItem'; +import CodeBlock from '@theme/CodeBlock'; + +type Props = { + code: string; + pluginName: string; + presetOptionName: string; +}; + +const docsPluginId = undefined; // Default docs plugin instance + +export default function ConfigTabs({ + code, + pluginName, + presetOptionName, +}: Props): JSX.Element { + const versionPath = useActiveVersion(docsPluginId)!.path; + + return ( + + +

+ + preset options + + ), + }}> + { + 'If you use a preset, configure this plugin through the {presetLink}:' + } + +

+

+ + {`module.exports = { + presets: [ + [ + '@docusaurus/preset-classic', + { + // highlight-start + ${presetOptionName}: ${code.replace(/\n/g, '\n ')}, + // highlight-end + }, + ], + ], +};`} + +

+
+ +

+ + If you are using a standalone plugin, provide options directly to + the plugin: + +

+

+ + {`module.exports = { + plugins: [ + [ + '${pluginName}', + // highlight-start + ${code.replace(/\n/g, '\n ')}, + // highlight-end + ], + ], +};`} + +

+
+
+ ); +} diff --git a/website/src/components/UpgradeGuide/index.tsx b/website/src/components/UpgradeGuide/index.tsx index 2d96203d095e..5cb2f118f1f6 100644 --- a/website/src/components/UpgradeGuide/index.tsx +++ b/website/src/components/UpgradeGuide/index.tsx @@ -17,9 +17,11 @@ import Translate from '@docusaurus/Translate'; import Admonition from '@theme/Admonition'; import CodeBlock from '@theme/CodeBlock'; +const docsPluginId = undefined; // Default docs plugin instance + function PackageJson() { - const latestVersion = useLatestVersion(); - const allVersions = useVersions(); + const latestVersion = useLatestVersion(docsPluginId); + const allVersions = useVersions(docsPluginId); // Only happens in deploy preview / local dev, but still nice const versionName = latestVersion.name === 'current' && allVersions.length > 1 @@ -37,8 +39,8 @@ function PackageJson() { } function VersionNotice() { - const latestVersion = useLatestVersion(); - const activeVersion = useActiveDocContext().activeVersion!; + const latestVersion = useLatestVersion(docsPluginId); + const activeVersion = useActiveDocContext(docsPluginId).activeVersion!; const isBrowser = useIsBrowser(); // It's possible that the user is browsing a snapshot version // which is only detectable once we are in the browser diff --git a/website/community/4-canary/Versions.tsx b/website/src/components/Versions.tsx similarity index 91% rename from website/community/4-canary/Versions.tsx rename to website/src/components/Versions.tsx index 3448563166d9..9542c88a8328 100644 --- a/website/community/4-canary/Versions.tsx +++ b/website/src/components/Versions.tsx @@ -5,7 +5,13 @@ * LICENSE file in the root directory of this source tree. */ -import React, {useContext, useEffect, useState, type ReactNode} from 'react'; +import React, { + useContext, + useEffect, + useState, + useRef, + type ReactNode, +} from 'react'; import {useDocsPreferredVersion} from '@docusaurus/theme-common'; import {useVersions} from '@docusaurus/plugin-content-docs/client'; import Translate from '@docusaurus/Translate'; @@ -24,11 +30,21 @@ export function VersionsProvider({ children: ReactNode; }): JSX.Element { const [canaryVersion, setCanaryVersion] = useState(null); + const mounted = useRef(true); + useEffect(() => { + mounted.current = true; + return () => { + mounted.current = false; + }; + }, []); useEffect(() => { fetch('https://registry.npmjs.org/@docusaurus/core') .then((res) => res.json()) .then( (data: {versions: string[]; time: {[versionName: string]: string}}) => { + if (!mounted.current) { + return; + } const name = Object.keys(data.versions).at(-1)!; const time = data.time[name]; setCanaryVersion({name, time}); diff --git a/website/src/data/showcase/brainboard.png b/website/src/data/showcase/brainboard.png new file mode 100644 index 000000000000..8dabed5f8ded Binary files /dev/null and b/website/src/data/showcase/brainboard.png differ diff --git a/website/src/data/showcase/charles-ancheta.png b/website/src/data/showcase/charles-ancheta.png new file mode 100644 index 000000000000..9be464e35e6c Binary files /dev/null and b/website/src/data/showcase/charles-ancheta.png differ diff --git a/website/src/data/showcase/difranca-technotes.png b/website/src/data/showcase/difranca-technotes.png new file mode 100644 index 000000000000..0e42fdfe4fc6 Binary files /dev/null and b/website/src/data/showcase/difranca-technotes.png differ diff --git a/website/src/data/showcase/metalyoung.png b/website/src/data/showcase/metalyoung.png new file mode 100644 index 000000000000..da8445857cf3 Binary files /dev/null and b/website/src/data/showcase/metalyoung.png differ diff --git a/website/src/data/showcase/nhost.png b/website/src/data/showcase/nhost.png new file mode 100644 index 000000000000..243692c12d00 Binary files /dev/null and b/website/src/data/showcase/nhost.png differ diff --git a/website/src/data/showcase/outerbounds.png b/website/src/data/showcase/outerbounds.png new file mode 100644 index 000000000000..094f7e913a2c Binary files /dev/null and b/website/src/data/showcase/outerbounds.png differ diff --git a/website/src/data/showcase/peradaban.png b/website/src/data/showcase/peradaban.png new file mode 100644 index 000000000000..1792fa251a0f Binary files /dev/null and b/website/src/data/showcase/peradaban.png differ diff --git a/website/src/data/showcase/react-chat-elements.png b/website/src/data/showcase/react-chat-elements.png new file mode 100644 index 000000000000..2affcd00f4a3 Binary files /dev/null and b/website/src/data/showcase/react-chat-elements.png differ diff --git a/website/src/data/showcase/reactnativeboilerplate.png b/website/src/data/showcase/reactnativeboilerplate.png index 6513e67841e9..ce93a1f61fd5 100644 Binary files a/website/src/data/showcase/reactnativeboilerplate.png and b/website/src/data/showcase/reactnativeboilerplate.png differ diff --git a/website/src/data/showcase/sado0823.png b/website/src/data/showcase/sado0823.png new file mode 100644 index 000000000000..b4e62a2a22cc Binary files /dev/null and b/website/src/data/showcase/sado0823.png differ diff --git a/website/src/data/users.tsx b/website/src/data/users.tsx index 01d5fcb82643..3c74778c606c 100644 --- a/website/src/data/users.tsx +++ b/website/src/data/users.tsx @@ -7,6 +7,7 @@ /* eslint-disable global-require */ +import {translate} from '@docusaurus/Translate'; import {sortBy} from '@site/src/utils/jsUtils'; /* @@ -79,72 +80,102 @@ export type User = { export const Tags: {[type in TagType]: Tag} = { // DO NOT USE THIS TAG: we choose sites to add to favorites favorite: { - label: 'Favorite', - description: - 'Our favorite Docusaurus sites that you must absolutely check-out!', + label: translate({message: 'Favorite'}), + description: translate({ + message: + 'Our favorite Docusaurus sites that you must absolutely check out!', + id: 'showcase.tag.favorite.description', + }), color: '#e9669e', }, // For open-source sites, a link to the source code is required // The source should be your *website's* source, not your project's source! opensource: { - label: 'Open-Source', - description: 'Open-Source Docusaurus sites can be useful for inspiration!', + label: translate({message: 'Open-Source'}), + description: translate({ + message: 'Open-Source Docusaurus sites can be useful for inspiration!', + id: 'showcase.tag.opensource.description', + }), color: '#39ca30', }, product: { - label: 'Product', - description: 'Docusaurus sites associated to a commercial product!', + label: translate({message: 'Product'}), + description: translate({ + message: 'Docusaurus sites associated to a commercial product!', + id: 'showcase.tag.product.description', + }), color: '#dfd545', }, design: { - label: 'Design', - description: - 'Beautiful Docusaurus sites, polished and standing out from the initial template!', + label: translate({message: 'Design'}), + description: translate({ + message: + 'Beautiful Docusaurus sites, polished and standing out from the initial template!', + id: 'showcase.tag.design.description', + }), color: '#a44fb7', }, i18n: { - label: 'I18n', - description: - 'Translated Docusaurus sites using the internationalization support with more than 1 locale.', + label: translate({message: 'I18n'}), + description: translate({ + message: + 'Translated Docusaurus sites using the internationalization support with more than 1 locale.', + id: 'showcase.tag.i18n.description', + }), color: '#127f82', }, versioning: { - label: 'Versioning', - description: - 'Docusaurus sites using the versioning feature of the docs plugin to manage multiple versions.', + label: translate({message: 'Versioning'}), + description: translate({ + message: + 'Docusaurus sites using the versioning feature of the docs plugin to manage multiple versions.', + id: 'showcase.tag.versioning.description', + }), color: '#fe6829', }, // Large sites, with a lot of content (> 200 pages, excluding versions) large: { - label: 'Large', - description: - 'Very large Docusaurus sites, including many more pages than the average!', + label: translate({message: 'Large'}), + description: translate({ + message: + 'Very large Docusaurus sites, including many more pages than the average!', + id: 'showcase.tag.large.description', + }), color: '#8c2f00', }, meta: { - label: 'Meta', - description: 'Docusaurus sites of Meta (formerly Facebook) projects', + label: translate({message: 'Meta'}), + description: translate({ + message: 'Docusaurus sites of Meta (formerly Facebook) projects', + id: 'showcase.tag.meta.description', + }), color: '#4267b2', // Facebook blue }, personal: { - label: 'Personal', - description: - 'Personal websites, blogs and digital gardens built with Docusaurus', + label: translate({message: 'Personal'}), + description: translate({ + message: + 'Personal websites, blogs and digital gardens built with Docusaurus', + id: 'showcase.tag.personal.description', + }), color: '#14cfc3', }, rtl: { - label: 'RTL Direction', - description: - 'Docusaurus sites using the right-to-left reading direction support.', + label: translate({message: 'RTL Direction'}), + description: translate({ + message: + 'Docusaurus sites using the right-to-left reading direction support.', + id: 'showcase.tag.rtl.description', + }), color: '#ffcfc3', }, }; @@ -330,6 +361,14 @@ const Users: User[] = [ source: 'https://github.com/boxyhq/website', tags: ['opensource'], }, + { + title: 'Brainboard IDE', + description: 'The new way to operate & manage your Cloud: visually.', + preview: require('./showcase/brainboard.png'), + website: 'https://docs.brainboard.co/start/cloud-use-cases', + source: null, + tags: ['product', 'design'], + }, { title: 'Build Tracker', description: @@ -355,6 +394,14 @@ const Users: User[] = [ source: 'https://github.com/chaos-mesh/website', tags: ['opensource', 'product', 'i18n'], }, + { + title: 'Charles Ancheta', + description: "Charles Ancheta's Blog and Portfolio Website", + preview: require('./showcase/charles-ancheta.png'), + website: 'https://charlesancheta.com', + source: 'https://github.com/cbebe/my-website', + tags: ['opensource', 'personal'], + }, { title: 'ChatKitty', description: 'A full suite of developer tools for any chat use-case.', @@ -501,6 +548,14 @@ const Users: User[] = [ source: 'https://github.com/loft-sh/devspace/tree/master/docs', tags: ['opensource'], }, + { + title: 'difranca | Tech-Notes', + description: 'This documentation aims to comprise my learning notes on various tech subjects.', + preview: require('./showcase/difranca-technotes.png'), + website: 'https://difranca.github.io/', + source: 'https://github.com/difranca/difranca.github.io', + tags: ['opensource', 'personal'], + }, { title: 'Dime.Scheduler', description: @@ -1172,6 +1227,15 @@ const Users: User[] = [ source: 'https://github.com/cxOrz/meoo.space', tags: ['opensource', 'personal'], }, + { + title: 'Metalyoung Blog', + description: + 'A personal blog to record open source community contributions and open source projects', + preview: require('./showcase/metalyoung.png'), + website: 'https://www.metalyoung.com', + source: null, + tags: ['personal'], + }, { title: 'Metro', description: 'The JavaScript bundler for React Native', @@ -1276,6 +1340,14 @@ const Users: User[] = [ source: 'https://github.com/nextauthjs/next-auth/tree/main/docs', tags: ['opensource', 'design'], }, + { + title: 'Nhost', + description: 'The Open Source Firebase Alternative with GraphQL', + preview: require('./showcase/nhost.png'), + website: 'https://docs.nhost.io', + source: 'https://github.com/nhost/nhost/tree/main/docs', + tags: ['opensource', 'product', 'design'], + }, { title: 'Nocalhost', description: @@ -1336,6 +1408,15 @@ const Users: User[] = [ source: 'https://github.com/pingcap/ossinsight', tags: ['opensource', 'design'], }, + { + title: 'Outerbounds', + description: + 'Resources for data scientists and engineers, authored in jupyter notebooks using nbdoc and docusaurus.', + preview: require('./showcase/outerbounds.png'), + website: 'https://outerbounds.com', + source: null, + tags: ['favorite', 'product', 'design'], + }, { title: 'Oxidizer', description: 'A Rust ORM based on tokio-postgres and refinery', @@ -1397,6 +1478,15 @@ const Users: User[] = [ 'https://github.com/agrawal-rohit/pearl-ui/tree/main/documentationwebsite', tags: ['opensource', 'design', 'product'], }, + { + title: 'Peradaban', + description: + 'Peradaban is a Discord Server Bots made with NAFF designed only for Warung International Discord Server', + preview: require('./showcase/peradaban.png'), + website: 'https://docs.warunginternational.eu.org/', + source: 'https://github.com/warung-international/docs', + tags: ['opensource'], + }, { title: 'Pglet', description: @@ -1560,6 +1650,14 @@ const Users: User[] = [ source: 'https://github.com/rivalis/rivalis.github.io', tags: ['opensource', 'design', 'product'], }, + { + title: 'react-chat-elements', + description: 'Chat UI package for React', + preview: require('./showcase/react-chat-elements.png'), + website: 'https://detaysoft.github.io/docs-react-chat-elements/', + source: 'https://github.com/Detaysoft/react-chat-elements', + tags: ['opensource'], + }, { title: 'React Complex Tree', description: @@ -2058,6 +2156,14 @@ const Users: User[] = [ source: 'https://github.com/lukasbach/synergies/tree/main/packages/docs', tags: ['opensource', 'design'], }, + { + title: 'Sado0823', + description: "Sado0823's Blog and Portfolio Website", + preview: require('./showcase/sado0823.png'), + website: 'https://sado0823.github.io', + source: 'https://github.com/sado0823/sado0823.github.io', + tags: ['opensource', 'personal'], + }, { title: 'T-Regx', description: 'Programmer-oriented Regular Expressions library for PHP', @@ -2301,7 +2407,7 @@ const Users: User[] = [ website: 'https://yeecord.com/', preview: require('./showcase/yeecord.png'), tags: ['product', 'personal'], - source: null + source: null, }, { title: 'Zowe', diff --git a/website/src/pages/showcase/index.tsx b/website/src/pages/showcase/index.tsx index 0cfd04de3d27..c1a6d7b67fb1 100644 --- a/website/src/pages/showcase/index.tsx +++ b/website/src/pages/showcase/index.tsx @@ -33,8 +33,10 @@ import ShowcaseTooltip from './_components/ShowcaseTooltip'; import styles from './styles.module.css'; -const TITLE = 'Docusaurus Site Showcase'; -const DESCRIPTION = 'List of websites people are building with Docusaurus'; +const TITLE = translate({message: 'Docusaurus Site Showcase'}); +const DESCRIPTION = translate({ + message: 'List of websites people are building with Docusaurus', +}); const EDIT_URL = 'https://github.com/facebook/docusaurus/edit/main/website/src/data/users.tsx'; diff --git a/website/src/pages/versions.tsx b/website/src/pages/versions.tsx index 12d042e92eda..5e748d6571c4 100644 --- a/website/src/pages/versions.tsx +++ b/website/src/pages/versions.tsx @@ -17,6 +17,8 @@ import Layout from '@theme/Layout'; import Heading from '@theme/Heading'; import VersionsArchived from '@site/versionsArchived.json'; +const docsPluginId = undefined; // Default docs plugin instance + const VersionsArchivedList = Object.entries(VersionsArchived); function DocumentationLabel() { @@ -37,8 +39,8 @@ export default function Version(): JSX.Element { const { siteConfig: {organizationName, projectName}, } = useDocusaurusContext(); - const versions = useVersions(); - const latestVersion = useLatestVersion(); + const versions = useVersions(docsPluginId); + const latestVersion = useLatestVersion(docsPluginId); const currentVersion = versions.find( (version) => version.name === 'current', )!; diff --git a/website/src/remark/configTabs.mjs b/website/src/remark/configTabs.mjs index 3da56b4ba85b..7b893cf92480 100644 --- a/website/src/remark/configTabs.mjs +++ b/website/src/remark/configTabs.mjs @@ -12,159 +12,51 @@ import visit from 'unist-util-visit'; * options" tab */ export default function plugin() { + /** @type {import("unified").Transformer} */ const transformer = (root) => { - let tabsImported = false; - let codeBlockImported = false; - let transformed = false; - visit(root, ['code', 'import'], (node, index, parent) => { - if (node.type === 'import') { - if (node.value.includes('@theme/Tabs')) { - tabsImported = true; - } else if (node.value.includes('@theme/CodeBlock')) { - codeBlockImported = true; - } - } else if (node.meta?.includes('config-tabs')) { - transformed = true; - const {value} = node; - const [presetMeta, pluginMeta] = value.split('\n'); - const { - groups: {presetOptionName, presetOptionText}, - } = presetMeta.match( - /\/\/(?.*?): (?[A-Z]+)/i, - ) ?? { - groups: { - presetOptionName: '[translation failure]', - presetOptionText: 'Preset Options', - }, - }; - const { - groups: {pluginName, pluginText}, - } = pluginMeta.match( - /\/\/(?.*?): (?[A-Z@/-]+)/i, - ) ?? { - groups: { - pluginName: '[translation failure]', - pluginText: 'Plugin Options', - }, - }; - // Replace leading "const config = " and trailing semi - const config = value - .replace(presetMeta, '') - .replace(pluginMeta, '') - .trim() - .replace(/^.*?= /, '') - .replace(/;$/, '') - .replace(/`/g, '\\`') - .replace(/\$/g, '\\$'); - const newNodes = [ - { - type: 'jsx', - value: `\n`, - }, - { - type: 'paragraph', - children: [ - { - type: 'text', - value: - 'If you use a preset, configure this plugin through the ', - }, - { - type: 'link', - title: null, - // TODO make this version-aware; maybe we need a - // useVersionedLink() hook - url: '/docs/using-plugins#docusauruspreset-classic', - children: [ - { - type: 'text', - value: 'preset options', - }, - ], - }, - { - type: 'text', - value: ':', - }, - ], - }, - { - type: 'jsx', - value: ` -{\`module.exports = { - presets: [ - [ - '@docusaurus/preset-classic', - { - // highlight-start - ${presetOptionName.trim()}: ${config - .split('\n') - .map((line) => ` ${line}`) - .join('\n') - .trim()}, - // highlight-end - }, - ], - ], -};\`} -`, - }, - { - type: 'jsx', - value: `\n`, - }, - { - type: 'paragraph', - children: [ - { - type: 'text', - value: - 'If you are using a standalone plugin, provide options directly to the plugin:', - }, - ], - }, - { - type: 'jsx', - value: ` -{\`module.exports = { - plugins: [ - [ - '${pluginName.trim()}', - // highlight-start - ${config - .split('\n') - .map((line) => ` ${line}`) - .join('\n') - .trim()}, - // highlight-end - ], - ], -};\`} -`, - }, - { - type: 'jsx', - value: '\n', - }, - ]; - parent.children.splice(index, 1, ...newNodes); + visit(root, 'code', (node, index, parent) => { + if (!node.meta?.includes('config-tabs')) { + return; } - }); - if (transformed) { - if (!tabsImported) { - root.children.unshift({ - type: 'import', - value: - "import Tabs from '@theme/Tabs';\nimport TabItem from '@theme/TabItem';", - }); - } - if (!codeBlockImported) { - root.children.unshift({ + const {value} = node; + const [presetMeta, pluginMeta] = value.split('\n'); + const { + groups: {presetOptionName}, + } = presetMeta.match(/\/\/.*?: (?[A-Z]+)/i) ?? { + groups: {presetOptionName: '[translation failure]'}, + }; + const { + groups: {pluginName}, + } = pluginMeta.match(/\/\/.*?: (?[A-Z@/-]+)/i) ?? { + groups: {pluginName: '[translation failure]'}, + }; + // Replace pragma comments + const config = value + .replace(presetMeta, '') + .replace(pluginMeta, '') + .trim() + .replace(/^.*?= /, '') + .replace(/;$/, '') + // eslint-disable-next-line prefer-named-capture-group + .replace(/([`$\\])/g, '\\$1'); + + parent.children.splice( + index, + 1, + { type: 'import', - value: "import CodeBlock from '@theme/CodeBlock';", - }); - } - } + value: `import ConfigTabs from "@site/src/components/ConfigTabs";`, + }, + { + type: 'jsx', + value: ``, + }, + ); + }); }; return transformer; } diff --git a/website/static/katex/katex.min.css b/website/static/katex/katex.min.css index aadf4476d8b3..a0df3e8ceb40 100644 --- a/website/static/katex/katex.min.css +++ b/website/static/katex/katex.min.css @@ -1 +1 @@ -@font-face{font-family:KaTeX_AMS;font-style:normal;font-weight:400;src:url(fonts/KaTeX_AMS-Regular.woff2) format("woff2"),url(fonts/KaTeX_AMS-Regular.woff) format("woff"),url(fonts/KaTeX_AMS-Regular.ttf) format("truetype")}@font-face{font-family:KaTeX_Caligraphic;font-style:normal;font-weight:700;src:url(fonts/KaTeX_Caligraphic-Bold.woff2) format("woff2"),url(fonts/KaTeX_Caligraphic-Bold.woff) format("woff"),url(fonts/KaTeX_Caligraphic-Bold.ttf) format("truetype")}@font-face{font-family:KaTeX_Caligraphic;font-style:normal;font-weight:400;src:url(fonts/KaTeX_Caligraphic-Regular.woff2) format("woff2"),url(fonts/KaTeX_Caligraphic-Regular.woff) format("woff"),url(fonts/KaTeX_Caligraphic-Regular.ttf) format("truetype")}@font-face{font-family:KaTeX_Fraktur;font-style:normal;font-weight:700;src:url(fonts/KaTeX_Fraktur-Bold.woff2) format("woff2"),url(fonts/KaTeX_Fraktur-Bold.woff) format("woff"),url(fonts/KaTeX_Fraktur-Bold.ttf) format("truetype")}@font-face{font-family:KaTeX_Fraktur;font-style:normal;font-weight:400;src:url(fonts/KaTeX_Fraktur-Regular.woff2) format("woff2"),url(fonts/KaTeX_Fraktur-Regular.woff) format("woff"),url(fonts/KaTeX_Fraktur-Regular.ttf) format("truetype")}@font-face{font-family:KaTeX_Main;font-style:normal;font-weight:700;src:url(fonts/KaTeX_Main-Bold.woff2) format("woff2"),url(fonts/KaTeX_Main-Bold.woff) format("woff"),url(fonts/KaTeX_Main-Bold.ttf) format("truetype")}@font-face{font-family:KaTeX_Main;font-style:italic;font-weight:700;src:url(fonts/KaTeX_Main-BoldItalic.woff2) format("woff2"),url(fonts/KaTeX_Main-BoldItalic.woff) format("woff"),url(fonts/KaTeX_Main-BoldItalic.ttf) format("truetype")}@font-face{font-family:KaTeX_Main;font-style:italic;font-weight:400;src:url(fonts/KaTeX_Main-Italic.woff2) format("woff2"),url(fonts/KaTeX_Main-Italic.woff) format("woff"),url(fonts/KaTeX_Main-Italic.ttf) format("truetype")}@font-face{font-family:KaTeX_Main;font-style:normal;font-weight:400;src:url(fonts/KaTeX_Main-Regular.woff2) format("woff2"),url(fonts/KaTeX_Main-Regular.woff) format("woff"),url(fonts/KaTeX_Main-Regular.ttf) format("truetype")}@font-face{font-family:KaTeX_Math;font-style:italic;font-weight:700;src:url(fonts/KaTeX_Math-BoldItalic.woff2) format("woff2"),url(fonts/KaTeX_Math-BoldItalic.woff) format("woff"),url(fonts/KaTeX_Math-BoldItalic.ttf) format("truetype")}@font-face{font-family:KaTeX_Math;font-style:italic;font-weight:400;src:url(fonts/KaTeX_Math-Italic.woff2) format("woff2"),url(fonts/KaTeX_Math-Italic.woff) format("woff"),url(fonts/KaTeX_Math-Italic.ttf) format("truetype")}@font-face{font-family:"KaTeX_SansSerif";font-style:normal;font-weight:700;src:url(fonts/KaTeX_SansSerif-Bold.woff2) format("woff2"),url(fonts/KaTeX_SansSerif-Bold.woff) format("woff"),url(fonts/KaTeX_SansSerif-Bold.ttf) format("truetype")}@font-face{font-family:"KaTeX_SansSerif";font-style:italic;font-weight:400;src:url(fonts/KaTeX_SansSerif-Italic.woff2) format("woff2"),url(fonts/KaTeX_SansSerif-Italic.woff) format("woff"),url(fonts/KaTeX_SansSerif-Italic.ttf) format("truetype")}@font-face{font-family:"KaTeX_SansSerif";font-style:normal;font-weight:400;src:url(fonts/KaTeX_SansSerif-Regular.woff2) format("woff2"),url(fonts/KaTeX_SansSerif-Regular.woff) format("woff"),url(fonts/KaTeX_SansSerif-Regular.ttf) format("truetype")}@font-face{font-family:KaTeX_Script;font-style:normal;font-weight:400;src:url(fonts/KaTeX_Script-Regular.woff2) format("woff2"),url(fonts/KaTeX_Script-Regular.woff) format("woff"),url(fonts/KaTeX_Script-Regular.ttf) format("truetype")}@font-face{font-family:KaTeX_Size1;font-style:normal;font-weight:400;src:url(fonts/KaTeX_Size1-Regular.woff2) format("woff2"),url(fonts/KaTeX_Size1-Regular.woff) format("woff"),url(fonts/KaTeX_Size1-Regular.ttf) format("truetype")}@font-face{font-family:KaTeX_Size2;font-style:normal;font-weight:400;src:url(fonts/KaTeX_Size2-Regular.woff2) format("woff2"),url(fonts/KaTeX_Size2-Regular.woff) format("woff"),url(fonts/KaTeX_Size2-Regular.ttf) format("truetype")}@font-face{font-family:KaTeX_Size3;font-style:normal;font-weight:400;src:url(fonts/KaTeX_Size3-Regular.woff2) format("woff2"),url(fonts/KaTeX_Size3-Regular.woff) format("woff"),url(fonts/KaTeX_Size3-Regular.ttf) format("truetype")}@font-face{font-family:KaTeX_Size4;font-style:normal;font-weight:400;src:url(fonts/KaTeX_Size4-Regular.woff2) format("woff2"),url(fonts/KaTeX_Size4-Regular.woff) format("woff"),url(fonts/KaTeX_Size4-Regular.ttf) format("truetype")}@font-face{font-family:KaTeX_Typewriter;font-style:normal;font-weight:400;src:url(fonts/KaTeX_Typewriter-Regular.woff2) format("woff2"),url(fonts/KaTeX_Typewriter-Regular.woff) format("woff"),url(fonts/KaTeX_Typewriter-Regular.ttf) format("truetype")}.katex{text-rendering:auto;font:normal 1.21em KaTeX_Main,Times New Roman,serif;line-height:1.2;text-indent:0}.katex *{-ms-high-contrast-adjust:none!important;border-color:currentColor}.katex .katex-version:after{content:"0.15.2"}.katex .katex-mathml{clip:rect(1px,1px,1px,1px);border:0;height:1px;overflow:hidden;padding:0;position:absolute;width:1px}.katex .katex-html>.newline{display:block}.katex .base{position:relative;white-space:nowrap;width:-webkit-min-content;width:-moz-min-content;width:min-content}.katex .base,.katex .strut{display:inline-block}.katex .textbf{font-weight:700}.katex .textit{font-style:italic}.katex .textrm{font-family:KaTeX_Main}.katex .textsf{font-family:KaTeX_SansSerif}.katex .texttt{font-family:KaTeX_Typewriter}.katex .mathnormal{font-family:KaTeX_Math;font-style:italic}.katex .mathit{font-family:KaTeX_Main;font-style:italic}.katex .mathrm{font-style:normal}.katex .mathbf{font-family:KaTeX_Main;font-weight:700}.katex .boldsymbol{font-family:KaTeX_Math;font-style:italic;font-weight:700}.katex .amsrm,.katex .mathbb,.katex .textbb{font-family:KaTeX_AMS}.katex .mathcal{font-family:KaTeX_Caligraphic}.katex .mathfrak,.katex .textfrak{font-family:KaTeX_Fraktur}.katex .mathtt{font-family:KaTeX_Typewriter}.katex .mathscr,.katex .textscr{font-family:KaTeX_Script}.katex .mathsf,.katex .textsf{font-family:KaTeX_SansSerif}.katex .mathboldsf,.katex .textboldsf{font-family:KaTeX_SansSerif;font-weight:700}.katex .mathitsf,.katex .textitsf{font-family:KaTeX_SansSerif;font-style:italic}.katex .mainrm{font-family:KaTeX_Main;font-style:normal}.katex .vlist-t{border-collapse:collapse;display:inline-table;table-layout:fixed}.katex .vlist-r{display:table-row}.katex .vlist{display:table-cell;position:relative;vertical-align:bottom}.katex .vlist>span{display:block;height:0;position:relative}.katex .vlist>span>span{display:inline-block}.katex .vlist>span>.pstrut{overflow:hidden;width:0}.katex .vlist-t2{margin-right:-2px}.katex .vlist-s{display:table-cell;font-size:1px;min-width:2px;vertical-align:bottom;width:2px}.katex .vbox{align-items:baseline;display:inline-flex;flex-direction:column}.katex .hbox{width:100%}.katex .hbox,.katex .thinbox{display:inline-flex;flex-direction:row}.katex .thinbox{max-width:0;width:0}.katex .msupsub{text-align:left}.katex .mfrac>span>span{text-align:center}.katex .mfrac .frac-line{border-bottom-style:solid;display:inline-block;width:100%}.katex .hdashline,.katex .hline,.katex .mfrac .frac-line,.katex .overline .overline-line,.katex .rule,.katex .underline .underline-line{min-height:1px}.katex .mspace{display:inline-block}.katex .clap,.katex .llap,.katex .rlap{position:relative;width:0}.katex .clap>.inner,.katex .llap>.inner,.katex .rlap>.inner{position:absolute}.katex .clap>.fix,.katex .llap>.fix,.katex .rlap>.fix{display:inline-block}.katex .llap>.inner{right:0}.katex .clap>.inner,.katex .rlap>.inner{left:0}.katex .clap>.inner>span{margin-left:-50%;margin-right:50%}.katex .rule{border:0 solid;display:inline-block;position:relative}.katex .hline,.katex .overline .overline-line,.katex .underline .underline-line{border-bottom-style:solid;display:inline-block;width:100%}.katex .hdashline{border-bottom-style:dashed;display:inline-block;width:100%}.katex .sqrt>.root{margin-left:.27777778em;margin-right:-.55555556em}.katex .fontsize-ensurer.reset-size1.size1,.katex .sizing.reset-size1.size1{font-size:1em}.katex .fontsize-ensurer.reset-size1.size2,.katex .sizing.reset-size1.size2{font-size:1.2em}.katex .fontsize-ensurer.reset-size1.size3,.katex .sizing.reset-size1.size3{font-size:1.4em}.katex .fontsize-ensurer.reset-size1.size4,.katex .sizing.reset-size1.size4{font-size:1.6em}.katex .fontsize-ensurer.reset-size1.size5,.katex .sizing.reset-size1.size5{font-size:1.8em}.katex .fontsize-ensurer.reset-size1.size6,.katex .sizing.reset-size1.size6{font-size:2em}.katex .fontsize-ensurer.reset-size1.size7,.katex .sizing.reset-size1.size7{font-size:2.4em}.katex .fontsize-ensurer.reset-size1.size8,.katex .sizing.reset-size1.size8{font-size:2.88em}.katex .fontsize-ensurer.reset-size1.size9,.katex .sizing.reset-size1.size9{font-size:3.456em}.katex .fontsize-ensurer.reset-size1.size10,.katex .sizing.reset-size1.size10{font-size:4.148em}.katex .fontsize-ensurer.reset-size1.size11,.katex .sizing.reset-size1.size11{font-size:4.976em}.katex .fontsize-ensurer.reset-size2.size1,.katex .sizing.reset-size2.size1{font-size:.83333333em}.katex .fontsize-ensurer.reset-size2.size2,.katex .sizing.reset-size2.size2{font-size:1em}.katex .fontsize-ensurer.reset-size2.size3,.katex .sizing.reset-size2.size3{font-size:1.16666667em}.katex .fontsize-ensurer.reset-size2.size4,.katex .sizing.reset-size2.size4{font-size:1.33333333em}.katex .fontsize-ensurer.reset-size2.size5,.katex .sizing.reset-size2.size5{font-size:1.5em}.katex .fontsize-ensurer.reset-size2.size6,.katex .sizing.reset-size2.size6{font-size:1.66666667em}.katex .fontsize-ensurer.reset-size2.size7,.katex .sizing.reset-size2.size7{font-size:2em}.katex .fontsize-ensurer.reset-size2.size8,.katex .sizing.reset-size2.size8{font-size:2.4em}.katex .fontsize-ensurer.reset-size2.size9,.katex .sizing.reset-size2.size9{font-size:2.88em}.katex .fontsize-ensurer.reset-size2.size10,.katex .sizing.reset-size2.size10{font-size:3.45666667em}.katex .fontsize-ensurer.reset-size2.size11,.katex .sizing.reset-size2.size11{font-size:4.14666667em}.katex .fontsize-ensurer.reset-size3.size1,.katex .sizing.reset-size3.size1{font-size:.71428571em}.katex .fontsize-ensurer.reset-size3.size2,.katex .sizing.reset-size3.size2{font-size:.85714286em}.katex .fontsize-ensurer.reset-size3.size3,.katex .sizing.reset-size3.size3{font-size:1em}.katex .fontsize-ensurer.reset-size3.size4,.katex .sizing.reset-size3.size4{font-size:1.14285714em}.katex .fontsize-ensurer.reset-size3.size5,.katex .sizing.reset-size3.size5{font-size:1.28571429em}.katex .fontsize-ensurer.reset-size3.size6,.katex .sizing.reset-size3.size6{font-size:1.42857143em}.katex .fontsize-ensurer.reset-size3.size7,.katex .sizing.reset-size3.size7{font-size:1.71428571em}.katex .fontsize-ensurer.reset-size3.size8,.katex .sizing.reset-size3.size8{font-size:2.05714286em}.katex .fontsize-ensurer.reset-size3.size9,.katex .sizing.reset-size3.size9{font-size:2.46857143em}.katex .fontsize-ensurer.reset-size3.size10,.katex .sizing.reset-size3.size10{font-size:2.96285714em}.katex .fontsize-ensurer.reset-size3.size11,.katex .sizing.reset-size3.size11{font-size:3.55428571em}.katex .fontsize-ensurer.reset-size4.size1,.katex .sizing.reset-size4.size1{font-size:.625em}.katex .fontsize-ensurer.reset-size4.size2,.katex .sizing.reset-size4.size2{font-size:.75em}.katex .fontsize-ensurer.reset-size4.size3,.katex .sizing.reset-size4.size3{font-size:.875em}.katex .fontsize-ensurer.reset-size4.size4,.katex .sizing.reset-size4.size4{font-size:1em}.katex .fontsize-ensurer.reset-size4.size5,.katex .sizing.reset-size4.size5{font-size:1.125em}.katex .fontsize-ensurer.reset-size4.size6,.katex .sizing.reset-size4.size6{font-size:1.25em}.katex .fontsize-ensurer.reset-size4.size7,.katex .sizing.reset-size4.size7{font-size:1.5em}.katex .fontsize-ensurer.reset-size4.size8,.katex .sizing.reset-size4.size8{font-size:1.8em}.katex .fontsize-ensurer.reset-size4.size9,.katex .sizing.reset-size4.size9{font-size:2.16em}.katex .fontsize-ensurer.reset-size4.size10,.katex .sizing.reset-size4.size10{font-size:2.5925em}.katex .fontsize-ensurer.reset-size4.size11,.katex .sizing.reset-size4.size11{font-size:3.11em}.katex .fontsize-ensurer.reset-size5.size1,.katex .sizing.reset-size5.size1{font-size:.55555556em}.katex .fontsize-ensurer.reset-size5.size2,.katex .sizing.reset-size5.size2{font-size:.66666667em}.katex .fontsize-ensurer.reset-size5.size3,.katex .sizing.reset-size5.size3{font-size:.77777778em}.katex .fontsize-ensurer.reset-size5.size4,.katex .sizing.reset-size5.size4{font-size:.88888889em}.katex .fontsize-ensurer.reset-size5.size5,.katex .sizing.reset-size5.size5{font-size:1em}.katex .fontsize-ensurer.reset-size5.size6,.katex .sizing.reset-size5.size6{font-size:1.11111111em}.katex .fontsize-ensurer.reset-size5.size7,.katex .sizing.reset-size5.size7{font-size:1.33333333em}.katex .fontsize-ensurer.reset-size5.size8,.katex .sizing.reset-size5.size8{font-size:1.6em}.katex .fontsize-ensurer.reset-size5.size9,.katex .sizing.reset-size5.size9{font-size:1.92em}.katex .fontsize-ensurer.reset-size5.size10,.katex .sizing.reset-size5.size10{font-size:2.30444444em}.katex .fontsize-ensurer.reset-size5.size11,.katex .sizing.reset-size5.size11{font-size:2.76444444em}.katex .fontsize-ensurer.reset-size6.size1,.katex .sizing.reset-size6.size1{font-size:.5em}.katex .fontsize-ensurer.reset-size6.size2,.katex .sizing.reset-size6.size2{font-size:.6em}.katex .fontsize-ensurer.reset-size6.size3,.katex .sizing.reset-size6.size3{font-size:.7em}.katex .fontsize-ensurer.reset-size6.size4,.katex .sizing.reset-size6.size4{font-size:.8em}.katex .fontsize-ensurer.reset-size6.size5,.katex .sizing.reset-size6.size5{font-size:.9em}.katex .fontsize-ensurer.reset-size6.size6,.katex .sizing.reset-size6.size6{font-size:1em}.katex .fontsize-ensurer.reset-size6.size7,.katex .sizing.reset-size6.size7{font-size:1.2em}.katex .fontsize-ensurer.reset-size6.size8,.katex .sizing.reset-size6.size8{font-size:1.44em}.katex .fontsize-ensurer.reset-size6.size9,.katex .sizing.reset-size6.size9{font-size:1.728em}.katex .fontsize-ensurer.reset-size6.size10,.katex .sizing.reset-size6.size10{font-size:2.074em}.katex .fontsize-ensurer.reset-size6.size11,.katex .sizing.reset-size6.size11{font-size:2.488em}.katex .fontsize-ensurer.reset-size7.size1,.katex .sizing.reset-size7.size1{font-size:.41666667em}.katex .fontsize-ensurer.reset-size7.size2,.katex .sizing.reset-size7.size2{font-size:.5em}.katex .fontsize-ensurer.reset-size7.size3,.katex .sizing.reset-size7.size3{font-size:.58333333em}.katex .fontsize-ensurer.reset-size7.size4,.katex .sizing.reset-size7.size4{font-size:.66666667em}.katex .fontsize-ensurer.reset-size7.size5,.katex .sizing.reset-size7.size5{font-size:.75em}.katex .fontsize-ensurer.reset-size7.size6,.katex .sizing.reset-size7.size6{font-size:.83333333em}.katex .fontsize-ensurer.reset-size7.size7,.katex .sizing.reset-size7.size7{font-size:1em}.katex .fontsize-ensurer.reset-size7.size8,.katex .sizing.reset-size7.size8{font-size:1.2em}.katex .fontsize-ensurer.reset-size7.size9,.katex .sizing.reset-size7.size9{font-size:1.44em}.katex .fontsize-ensurer.reset-size7.size10,.katex .sizing.reset-size7.size10{font-size:1.72833333em}.katex .fontsize-ensurer.reset-size7.size11,.katex .sizing.reset-size7.size11{font-size:2.07333333em}.katex .fontsize-ensurer.reset-size8.size1,.katex .sizing.reset-size8.size1{font-size:.34722222em}.katex .fontsize-ensurer.reset-size8.size2,.katex .sizing.reset-size8.size2{font-size:.41666667em}.katex .fontsize-ensurer.reset-size8.size3,.katex .sizing.reset-size8.size3{font-size:.48611111em}.katex .fontsize-ensurer.reset-size8.size4,.katex .sizing.reset-size8.size4{font-size:.55555556em}.katex .fontsize-ensurer.reset-size8.size5,.katex .sizing.reset-size8.size5{font-size:.625em}.katex .fontsize-ensurer.reset-size8.size6,.katex .sizing.reset-size8.size6{font-size:.69444444em}.katex .fontsize-ensurer.reset-size8.size7,.katex .sizing.reset-size8.size7{font-size:.83333333em}.katex .fontsize-ensurer.reset-size8.size8,.katex .sizing.reset-size8.size8{font-size:1em}.katex .fontsize-ensurer.reset-size8.size9,.katex .sizing.reset-size8.size9{font-size:1.2em}.katex .fontsize-ensurer.reset-size8.size10,.katex .sizing.reset-size8.size10{font-size:1.44027778em}.katex .fontsize-ensurer.reset-size8.size11,.katex .sizing.reset-size8.size11{font-size:1.72777778em}.katex .fontsize-ensurer.reset-size9.size1,.katex .sizing.reset-size9.size1{font-size:.28935185em}.katex .fontsize-ensurer.reset-size9.size2,.katex .sizing.reset-size9.size2{font-size:.34722222em}.katex .fontsize-ensurer.reset-size9.size3,.katex .sizing.reset-size9.size3{font-size:.40509259em}.katex .fontsize-ensurer.reset-size9.size4,.katex .sizing.reset-size9.size4{font-size:.46296296em}.katex .fontsize-ensurer.reset-size9.size5,.katex .sizing.reset-size9.size5{font-size:.52083333em}.katex .fontsize-ensurer.reset-size9.size6,.katex .sizing.reset-size9.size6{font-size:.5787037em}.katex .fontsize-ensurer.reset-size9.size7,.katex .sizing.reset-size9.size7{font-size:.69444444em}.katex .fontsize-ensurer.reset-size9.size8,.katex .sizing.reset-size9.size8{font-size:.83333333em}.katex .fontsize-ensurer.reset-size9.size9,.katex .sizing.reset-size9.size9{font-size:1em}.katex .fontsize-ensurer.reset-size9.size10,.katex .sizing.reset-size9.size10{font-size:1.20023148em}.katex .fontsize-ensurer.reset-size9.size11,.katex .sizing.reset-size9.size11{font-size:1.43981481em}.katex .fontsize-ensurer.reset-size10.size1,.katex .sizing.reset-size10.size1{font-size:.24108004em}.katex .fontsize-ensurer.reset-size10.size2,.katex .sizing.reset-size10.size2{font-size:.28929605em}.katex .fontsize-ensurer.reset-size10.size3,.katex .sizing.reset-size10.size3{font-size:.33751205em}.katex .fontsize-ensurer.reset-size10.size4,.katex .sizing.reset-size10.size4{font-size:.38572806em}.katex .fontsize-ensurer.reset-size10.size5,.katex .sizing.reset-size10.size5{font-size:.43394407em}.katex .fontsize-ensurer.reset-size10.size6,.katex .sizing.reset-size10.size6{font-size:.48216008em}.katex .fontsize-ensurer.reset-size10.size7,.katex .sizing.reset-size10.size7{font-size:.57859209em}.katex .fontsize-ensurer.reset-size10.size8,.katex .sizing.reset-size10.size8{font-size:.69431051em}.katex .fontsize-ensurer.reset-size10.size9,.katex .sizing.reset-size10.size9{font-size:.83317261em}.katex .fontsize-ensurer.reset-size10.size10,.katex .sizing.reset-size10.size10{font-size:1em}.katex .fontsize-ensurer.reset-size10.size11,.katex .sizing.reset-size10.size11{font-size:1.19961427em}.katex .fontsize-ensurer.reset-size11.size1,.katex .sizing.reset-size11.size1{font-size:.20096463em}.katex .fontsize-ensurer.reset-size11.size2,.katex .sizing.reset-size11.size2{font-size:.24115756em}.katex .fontsize-ensurer.reset-size11.size3,.katex .sizing.reset-size11.size3{font-size:.28135048em}.katex .fontsize-ensurer.reset-size11.size4,.katex .sizing.reset-size11.size4{font-size:.32154341em}.katex .fontsize-ensurer.reset-size11.size5,.katex .sizing.reset-size11.size5{font-size:.36173633em}.katex .fontsize-ensurer.reset-size11.size6,.katex .sizing.reset-size11.size6{font-size:.40192926em}.katex .fontsize-ensurer.reset-size11.size7,.katex .sizing.reset-size11.size7{font-size:.48231511em}.katex .fontsize-ensurer.reset-size11.size8,.katex .sizing.reset-size11.size8{font-size:.57877814em}.katex .fontsize-ensurer.reset-size11.size9,.katex .sizing.reset-size11.size9{font-size:.69453376em}.katex .fontsize-ensurer.reset-size11.size10,.katex .sizing.reset-size11.size10{font-size:.83360129em}.katex .fontsize-ensurer.reset-size11.size11,.katex .sizing.reset-size11.size11{font-size:1em}.katex .delimsizing.size1{font-family:KaTeX_Size1}.katex .delimsizing.size2{font-family:KaTeX_Size2}.katex .delimsizing.size3{font-family:KaTeX_Size3}.katex .delimsizing.size4{font-family:KaTeX_Size4}.katex .delimsizing.mult .delim-size1>span{font-family:KaTeX_Size1}.katex .delimsizing.mult .delim-size4>span{font-family:KaTeX_Size4}.katex .nulldelimiter{display:inline-block;width:.12em}.katex .delimcenter,.katex .op-symbol{position:relative}.katex .op-symbol.small-op{font-family:KaTeX_Size1}.katex .op-symbol.large-op{font-family:KaTeX_Size2}.katex .accent>.vlist-t,.katex .op-limits>.vlist-t{text-align:center}.katex .accent .accent-body{position:relative}.katex .accent .accent-body:not(.accent-full){width:0}.katex .overlay{display:block}.katex .mtable .vertical-separator{display:inline-block;min-width:1px}.katex .mtable .arraycolsep{display:inline-block}.katex .mtable .col-align-c>.vlist-t{text-align:center}.katex .mtable .col-align-l>.vlist-t{text-align:left}.katex .mtable .col-align-r>.vlist-t{text-align:right}.katex .svg-align{text-align:left}.katex svg{fill:currentColor;stroke:currentColor;fill-rule:nonzero;fill-opacity:1;stroke-width:1;stroke-linecap:butt;stroke-linejoin:miter;stroke-miterlimit:4;stroke-dasharray:none;stroke-dashoffset:0;stroke-opacity:1;display:block;height:inherit;position:absolute;width:100%}.katex svg path{stroke:none}.katex img{border-style:none;max-height:none;max-width:none;min-height:0;min-width:0}.katex .stretchy{display:block;overflow:hidden;position:relative;width:100%}.katex .stretchy:after,.katex .stretchy:before{content:""}.katex .hide-tail{overflow:hidden;position:relative;width:100%}.katex .halfarrow-left{left:0;overflow:hidden;position:absolute;width:50.2%}.katex .halfarrow-right{overflow:hidden;position:absolute;right:0;width:50.2%}.katex .brace-left{left:0;overflow:hidden;position:absolute;width:25.1%}.katex .brace-center{left:25%;overflow:hidden;position:absolute;width:50%}.katex .brace-right{overflow:hidden;position:absolute;right:0;width:25.1%}.katex .x-arrow-pad{padding:0 .5em}.katex .cd-arrow-pad{padding:0 .55556em 0 .27778em}.katex .mover,.katex .munder,.katex .x-arrow{text-align:center}.katex .boxpad{padding:0 .3em}.katex .fbox,.katex .fcolorbox{border:.04em solid;box-sizing:border-box}.katex .cancel-pad{padding:0 .2em}.katex .cancel-lap{margin-left:-.2em;margin-right:-.2em}.katex .sout{border-bottom-style:solid;border-bottom-width:.08em}.katex .angl{border-right:.049em solid;border-top:.049em solid;box-sizing:border-box;margin-right:.03889em}.katex .anglpad{padding:0 .03889em}.katex .eqn-num:before{content:"(" counter(katexEqnNo) ")";counter-increment:katexEqnNo}.katex .mml-eqn-num:before{content:"(" counter(mmlEqnNo) ")";counter-increment:mmlEqnNo}.katex .mtr-glue{width:50%}.katex .cd-vert-arrow{display:inline-block;position:relative}.katex .cd-label-left{display:inline-block;position:absolute;right:calc(50% + .3em);text-align:left}.katex .cd-label-right{display:inline-block;left:calc(50% + .3em);position:absolute;text-align:right}.katex-display{display:block;margin:1em 0;text-align:center}.katex-display>.katex{display:block;text-align:center;white-space:nowrap}.katex-display>.katex>.katex-html{display:block;position:relative}.katex-display>.katex>.katex-html>.tag{position:absolute;right:0}.katex-display.leqno>.katex>.katex-html>.tag{left:0;right:auto}.katex-display.fleqn>.katex{padding-left:2em;text-align:left}body{counter-reset:katexEqnNo mmlEqnNo} +@font-face{font-family:KaTeX_AMS;font-style:normal;font-weight:400;src:url(/katex/fonts/KaTeX_AMS-Regular.woff2) format("woff2"),url(/katex/fonts/KaTeX_AMS-Regular.woff) format("woff"),url(/katex/fonts/KaTeX_AMS-Regular.ttf) format("truetype")}@font-face{font-family:KaTeX_Caligraphic;font-style:normal;font-weight:700;src:url(/katex/fonts/KaTeX_Caligraphic-Bold.woff2) format("woff2"),url(/katex/fonts/KaTeX_Caligraphic-Bold.woff) format("woff"),url(/katex/fonts/KaTeX_Caligraphic-Bold.ttf) format("truetype")}@font-face{font-family:KaTeX_Caligraphic;font-style:normal;font-weight:400;src:url(/katex/fonts/KaTeX_Caligraphic-Regular.woff2) format("woff2"),url(/katex/fonts/KaTeX_Caligraphic-Regular.woff) format("woff"),url(/katex/fonts/KaTeX_Caligraphic-Regular.ttf) format("truetype")}@font-face{font-family:KaTeX_Fraktur;font-style:normal;font-weight:700;src:url(/katex/fonts/KaTeX_Fraktur-Bold.woff2) format("woff2"),url(/katex/fonts/KaTeX_Fraktur-Bold.woff) format("woff"),url(/katex/fonts/KaTeX_Fraktur-Bold.ttf) format("truetype")}@font-face{font-family:KaTeX_Fraktur;font-style:normal;font-weight:400;src:url(/katex/fonts/KaTeX_Fraktur-Regular.woff2) format("woff2"),url(/katex/fonts/KaTeX_Fraktur-Regular.woff) format("woff"),url(/katex/fonts/KaTeX_Fraktur-Regular.ttf) format("truetype")}@font-face{font-family:KaTeX_Main;font-style:normal;font-weight:700;src:url(/katex/fonts/KaTeX_Main-Bold.woff2) format("woff2"),url(/katex/fonts/KaTeX_Main-Bold.woff) format("woff"),url(/katex/fonts/KaTeX_Main-Bold.ttf) format("truetype")}@font-face{font-family:KaTeX_Main;font-style:italic;font-weight:700;src:url(/katex/fonts/KaTeX_Main-BoldItalic.woff2) format("woff2"),url(/katex/fonts/KaTeX_Main-BoldItalic.woff) format("woff"),url(/katex/fonts/KaTeX_Main-BoldItalic.ttf) format("truetype")}@font-face{font-family:KaTeX_Main;font-style:italic;font-weight:400;src:url(/katex/fonts/KaTeX_Main-Italic.woff2) format("woff2"),url(/katex/fonts/KaTeX_Main-Italic.woff) format("woff"),url(/katex/fonts/KaTeX_Main-Italic.ttf) format("truetype")}@font-face{font-family:KaTeX_Main;font-style:normal;font-weight:400;src:url(/katex/fonts/KaTeX_Main-Regular.woff2) format("woff2"),url(/katex/fonts/KaTeX_Main-Regular.woff) format("woff"),url(/katex/fonts/KaTeX_Main-Regular.ttf) format("truetype")}@font-face{font-family:KaTeX_Math;font-style:italic;font-weight:700;src:url(/katex/fonts/KaTeX_Math-BoldItalic.woff2) format("woff2"),url(/katex/fonts/KaTeX_Math-BoldItalic.woff) format("woff"),url(/katex/fonts/KaTeX_Math-BoldItalic.ttf) format("truetype")}@font-face{font-family:KaTeX_Math;font-style:italic;font-weight:400;src:url(/katex/fonts/KaTeX_Math-Italic.woff2) format("woff2"),url(/katex/fonts/KaTeX_Math-Italic.woff) format("woff"),url(/katex/fonts/KaTeX_Math-Italic.ttf) format("truetype")}@font-face{font-family:"KaTeX_SansSerif";font-style:normal;font-weight:700;src:url(/katex/fonts/KaTeX_SansSerif-Bold.woff2) format("woff2"),url(/katex/fonts/KaTeX_SansSerif-Bold.woff) format("woff"),url(/katex/fonts/KaTeX_SansSerif-Bold.ttf) format("truetype")}@font-face{font-family:"KaTeX_SansSerif";font-style:italic;font-weight:400;src:url(/katex/fonts/KaTeX_SansSerif-Italic.woff2) format("woff2"),url(/katex/fonts/KaTeX_SansSerif-Italic.woff) format("woff"),url(/katex/fonts/KaTeX_SansSerif-Italic.ttf) format("truetype")}@font-face{font-family:"KaTeX_SansSerif";font-style:normal;font-weight:400;src:url(/katex/fonts/KaTeX_SansSerif-Regular.woff2) format("woff2"),url(/katex/fonts/KaTeX_SansSerif-Regular.woff) format("woff"),url(/katex/fonts/KaTeX_SansSerif-Regular.ttf) format("truetype")}@font-face{font-family:KaTeX_Script;font-style:normal;font-weight:400;src:url(/katex/fonts/KaTeX_Script-Regular.woff2) format("woff2"),url(/katex/fonts/KaTeX_Script-Regular.woff) format("woff"),url(/katex/fonts/KaTeX_Script-Regular.ttf) format("truetype")}@font-face{font-family:KaTeX_Size1;font-style:normal;font-weight:400;src:url(/katex/fonts/KaTeX_Size1-Regular.woff2) format("woff2"),url(/katex/fonts/KaTeX_Size1-Regular.woff) format("woff"),url(/katex/fonts/KaTeX_Size1-Regular.ttf) format("truetype")}@font-face{font-family:KaTeX_Size2;font-style:normal;font-weight:400;src:url(/katex/fonts/KaTeX_Size2-Regular.woff2) format("woff2"),url(/katex/fonts/KaTeX_Size2-Regular.woff) format("woff"),url(/katex/fonts/KaTeX_Size2-Regular.ttf) format("truetype")}@font-face{font-family:KaTeX_Size3;font-style:normal;font-weight:400;src:url(/katex/fonts/KaTeX_Size3-Regular.woff2) format("woff2"),url(/katex/fonts/KaTeX_Size3-Regular.woff) format("woff"),url(/katex/fonts/KaTeX_Size3-Regular.ttf) format("truetype")}@font-face{font-family:KaTeX_Size4;font-style:normal;font-weight:400;src:url(/katex/fonts/KaTeX_Size4-Regular.woff2) format("woff2"),url(/katex/fonts/KaTeX_Size4-Regular.woff) format("woff"),url(/katex/fonts/KaTeX_Size4-Regular.ttf) format("truetype")}@font-face{font-family:KaTeX_Typewriter;font-style:normal;font-weight:400;src:url(/katex/fonts/KaTeX_Typewriter-Regular.woff2) format("woff2"),url(/katex/fonts/KaTeX_Typewriter-Regular.woff) format("woff"),url(/katex/fonts/KaTeX_Typewriter-Regular.ttf) format("truetype")}.katex{text-rendering:auto;font:normal 1.21em KaTeX_Main,Times New Roman,serif;line-height:1.2;text-indent:0}.katex *{-ms-high-contrast-adjust:none!important;border-color:currentColor}.katex .katex-version:after{content:"0.15.2"}.katex .katex-mathml{clip:rect(1px,1px,1px,1px);border:0;height:1px;overflow:hidden;padding:0;position:absolute;width:1px}.katex .katex-html>.newline{display:block}.katex .base{position:relative;white-space:nowrap;width:-webkit-min-content;width:-moz-min-content;width:min-content}.katex .base,.katex .strut{display:inline-block}.katex .textbf{font-weight:700}.katex .textit{font-style:italic}.katex .textrm{font-family:KaTeX_Main}.katex .textsf{font-family:KaTeX_SansSerif}.katex .texttt{font-family:KaTeX_Typewriter}.katex .mathnormal{font-family:KaTeX_Math;font-style:italic}.katex .mathit{font-family:KaTeX_Main;font-style:italic}.katex .mathrm{font-style:normal}.katex .mathbf{font-family:KaTeX_Main;font-weight:700}.katex .boldsymbol{font-family:KaTeX_Math;font-style:italic;font-weight:700}.katex .amsrm,.katex .mathbb,.katex .textbb{font-family:KaTeX_AMS}.katex .mathcal{font-family:KaTeX_Caligraphic}.katex .mathfrak,.katex .textfrak{font-family:KaTeX_Fraktur}.katex .mathtt{font-family:KaTeX_Typewriter}.katex .mathscr,.katex .textscr{font-family:KaTeX_Script}.katex .mathsf,.katex .textsf{font-family:KaTeX_SansSerif}.katex .mathboldsf,.katex .textboldsf{font-family:KaTeX_SansSerif;font-weight:700}.katex .mathitsf,.katex .textitsf{font-family:KaTeX_SansSerif;font-style:italic}.katex .mainrm{font-family:KaTeX_Main;font-style:normal}.katex .vlist-t{border-collapse:collapse;display:inline-table;table-layout:fixed}.katex .vlist-r{display:table-row}.katex .vlist{display:table-cell;position:relative;vertical-align:bottom}.katex .vlist>span{display:block;height:0;position:relative}.katex .vlist>span>span{display:inline-block}.katex .vlist>span>.pstrut{overflow:hidden;width:0}.katex .vlist-t2{margin-right:-2px}.katex .vlist-s{display:table-cell;font-size:1px;min-width:2px;vertical-align:bottom;width:2px}.katex .vbox{align-items:baseline;display:inline-flex;flex-direction:column}.katex .hbox{width:100%}.katex .hbox,.katex .thinbox{display:inline-flex;flex-direction:row}.katex .thinbox{max-width:0;width:0}.katex .msupsub{text-align:left}.katex .mfrac>span>span{text-align:center}.katex .mfrac .frac-line{border-bottom-style:solid;display:inline-block;width:100%}.katex .hdashline,.katex .hline,.katex .mfrac .frac-line,.katex .overline .overline-line,.katex .rule,.katex .underline .underline-line{min-height:1px}.katex .mspace{display:inline-block}.katex .clap,.katex .llap,.katex .rlap{position:relative;width:0}.katex .clap>.inner,.katex .llap>.inner,.katex .rlap>.inner{position:absolute}.katex .clap>.fix,.katex .llap>.fix,.katex .rlap>.fix{display:inline-block}.katex .llap>.inner{right:0}.katex .clap>.inner,.katex .rlap>.inner{left:0}.katex .clap>.inner>span{margin-left:-50%;margin-right:50%}.katex .rule{border:0 solid;display:inline-block;position:relative}.katex .hline,.katex .overline .overline-line,.katex .underline .underline-line{border-bottom-style:solid;display:inline-block;width:100%}.katex .hdashline{border-bottom-style:dashed;display:inline-block;width:100%}.katex .sqrt>.root{margin-left:.27777778em;margin-right:-.55555556em}.katex .fontsize-ensurer.reset-size1.size1,.katex .sizing.reset-size1.size1{font-size:1em}.katex .fontsize-ensurer.reset-size1.size2,.katex .sizing.reset-size1.size2{font-size:1.2em}.katex .fontsize-ensurer.reset-size1.size3,.katex .sizing.reset-size1.size3{font-size:1.4em}.katex .fontsize-ensurer.reset-size1.size4,.katex .sizing.reset-size1.size4{font-size:1.6em}.katex .fontsize-ensurer.reset-size1.size5,.katex .sizing.reset-size1.size5{font-size:1.8em}.katex .fontsize-ensurer.reset-size1.size6,.katex .sizing.reset-size1.size6{font-size:2em}.katex .fontsize-ensurer.reset-size1.size7,.katex .sizing.reset-size1.size7{font-size:2.4em}.katex .fontsize-ensurer.reset-size1.size8,.katex .sizing.reset-size1.size8{font-size:2.88em}.katex .fontsize-ensurer.reset-size1.size9,.katex .sizing.reset-size1.size9{font-size:3.456em}.katex .fontsize-ensurer.reset-size1.size10,.katex .sizing.reset-size1.size10{font-size:4.148em}.katex .fontsize-ensurer.reset-size1.size11,.katex .sizing.reset-size1.size11{font-size:4.976em}.katex .fontsize-ensurer.reset-size2.size1,.katex .sizing.reset-size2.size1{font-size:.83333333em}.katex .fontsize-ensurer.reset-size2.size2,.katex .sizing.reset-size2.size2{font-size:1em}.katex .fontsize-ensurer.reset-size2.size3,.katex .sizing.reset-size2.size3{font-size:1.16666667em}.katex .fontsize-ensurer.reset-size2.size4,.katex .sizing.reset-size2.size4{font-size:1.33333333em}.katex .fontsize-ensurer.reset-size2.size5,.katex .sizing.reset-size2.size5{font-size:1.5em}.katex .fontsize-ensurer.reset-size2.size6,.katex .sizing.reset-size2.size6{font-size:1.66666667em}.katex .fontsize-ensurer.reset-size2.size7,.katex .sizing.reset-size2.size7{font-size:2em}.katex .fontsize-ensurer.reset-size2.size8,.katex .sizing.reset-size2.size8{font-size:2.4em}.katex .fontsize-ensurer.reset-size2.size9,.katex .sizing.reset-size2.size9{font-size:2.88em}.katex .fontsize-ensurer.reset-size2.size10,.katex .sizing.reset-size2.size10{font-size:3.45666667em}.katex .fontsize-ensurer.reset-size2.size11,.katex .sizing.reset-size2.size11{font-size:4.14666667em}.katex .fontsize-ensurer.reset-size3.size1,.katex .sizing.reset-size3.size1{font-size:.71428571em}.katex .fontsize-ensurer.reset-size3.size2,.katex .sizing.reset-size3.size2{font-size:.85714286em}.katex .fontsize-ensurer.reset-size3.size3,.katex .sizing.reset-size3.size3{font-size:1em}.katex .fontsize-ensurer.reset-size3.size4,.katex .sizing.reset-size3.size4{font-size:1.14285714em}.katex .fontsize-ensurer.reset-size3.size5,.katex .sizing.reset-size3.size5{font-size:1.28571429em}.katex .fontsize-ensurer.reset-size3.size6,.katex .sizing.reset-size3.size6{font-size:1.42857143em}.katex .fontsize-ensurer.reset-size3.size7,.katex .sizing.reset-size3.size7{font-size:1.71428571em}.katex .fontsize-ensurer.reset-size3.size8,.katex .sizing.reset-size3.size8{font-size:2.05714286em}.katex .fontsize-ensurer.reset-size3.size9,.katex .sizing.reset-size3.size9{font-size:2.46857143em}.katex .fontsize-ensurer.reset-size3.size10,.katex .sizing.reset-size3.size10{font-size:2.96285714em}.katex .fontsize-ensurer.reset-size3.size11,.katex .sizing.reset-size3.size11{font-size:3.55428571em}.katex .fontsize-ensurer.reset-size4.size1,.katex .sizing.reset-size4.size1{font-size:.625em}.katex .fontsize-ensurer.reset-size4.size2,.katex .sizing.reset-size4.size2{font-size:.75em}.katex .fontsize-ensurer.reset-size4.size3,.katex .sizing.reset-size4.size3{font-size:.875em}.katex .fontsize-ensurer.reset-size4.size4,.katex .sizing.reset-size4.size4{font-size:1em}.katex .fontsize-ensurer.reset-size4.size5,.katex .sizing.reset-size4.size5{font-size:1.125em}.katex .fontsize-ensurer.reset-size4.size6,.katex .sizing.reset-size4.size6{font-size:1.25em}.katex .fontsize-ensurer.reset-size4.size7,.katex .sizing.reset-size4.size7{font-size:1.5em}.katex .fontsize-ensurer.reset-size4.size8,.katex .sizing.reset-size4.size8{font-size:1.8em}.katex .fontsize-ensurer.reset-size4.size9,.katex .sizing.reset-size4.size9{font-size:2.16em}.katex .fontsize-ensurer.reset-size4.size10,.katex .sizing.reset-size4.size10{font-size:2.5925em}.katex .fontsize-ensurer.reset-size4.size11,.katex .sizing.reset-size4.size11{font-size:3.11em}.katex .fontsize-ensurer.reset-size5.size1,.katex .sizing.reset-size5.size1{font-size:.55555556em}.katex .fontsize-ensurer.reset-size5.size2,.katex .sizing.reset-size5.size2{font-size:.66666667em}.katex .fontsize-ensurer.reset-size5.size3,.katex .sizing.reset-size5.size3{font-size:.77777778em}.katex .fontsize-ensurer.reset-size5.size4,.katex .sizing.reset-size5.size4{font-size:.88888889em}.katex .fontsize-ensurer.reset-size5.size5,.katex .sizing.reset-size5.size5{font-size:1em}.katex .fontsize-ensurer.reset-size5.size6,.katex .sizing.reset-size5.size6{font-size:1.11111111em}.katex .fontsize-ensurer.reset-size5.size7,.katex .sizing.reset-size5.size7{font-size:1.33333333em}.katex .fontsize-ensurer.reset-size5.size8,.katex .sizing.reset-size5.size8{font-size:1.6em}.katex .fontsize-ensurer.reset-size5.size9,.katex .sizing.reset-size5.size9{font-size:1.92em}.katex .fontsize-ensurer.reset-size5.size10,.katex .sizing.reset-size5.size10{font-size:2.30444444em}.katex .fontsize-ensurer.reset-size5.size11,.katex .sizing.reset-size5.size11{font-size:2.76444444em}.katex .fontsize-ensurer.reset-size6.size1,.katex .sizing.reset-size6.size1{font-size:.5em}.katex .fontsize-ensurer.reset-size6.size2,.katex .sizing.reset-size6.size2{font-size:.6em}.katex .fontsize-ensurer.reset-size6.size3,.katex .sizing.reset-size6.size3{font-size:.7em}.katex .fontsize-ensurer.reset-size6.size4,.katex .sizing.reset-size6.size4{font-size:.8em}.katex .fontsize-ensurer.reset-size6.size5,.katex .sizing.reset-size6.size5{font-size:.9em}.katex .fontsize-ensurer.reset-size6.size6,.katex .sizing.reset-size6.size6{font-size:1em}.katex .fontsize-ensurer.reset-size6.size7,.katex .sizing.reset-size6.size7{font-size:1.2em}.katex .fontsize-ensurer.reset-size6.size8,.katex .sizing.reset-size6.size8{font-size:1.44em}.katex .fontsize-ensurer.reset-size6.size9,.katex .sizing.reset-size6.size9{font-size:1.728em}.katex .fontsize-ensurer.reset-size6.size10,.katex .sizing.reset-size6.size10{font-size:2.074em}.katex .fontsize-ensurer.reset-size6.size11,.katex .sizing.reset-size6.size11{font-size:2.488em}.katex .fontsize-ensurer.reset-size7.size1,.katex .sizing.reset-size7.size1{font-size:.41666667em}.katex .fontsize-ensurer.reset-size7.size2,.katex .sizing.reset-size7.size2{font-size:.5em}.katex .fontsize-ensurer.reset-size7.size3,.katex .sizing.reset-size7.size3{font-size:.58333333em}.katex .fontsize-ensurer.reset-size7.size4,.katex .sizing.reset-size7.size4{font-size:.66666667em}.katex .fontsize-ensurer.reset-size7.size5,.katex .sizing.reset-size7.size5{font-size:.75em}.katex .fontsize-ensurer.reset-size7.size6,.katex .sizing.reset-size7.size6{font-size:.83333333em}.katex .fontsize-ensurer.reset-size7.size7,.katex .sizing.reset-size7.size7{font-size:1em}.katex .fontsize-ensurer.reset-size7.size8,.katex .sizing.reset-size7.size8{font-size:1.2em}.katex .fontsize-ensurer.reset-size7.size9,.katex .sizing.reset-size7.size9{font-size:1.44em}.katex .fontsize-ensurer.reset-size7.size10,.katex .sizing.reset-size7.size10{font-size:1.72833333em}.katex .fontsize-ensurer.reset-size7.size11,.katex .sizing.reset-size7.size11{font-size:2.07333333em}.katex .fontsize-ensurer.reset-size8.size1,.katex .sizing.reset-size8.size1{font-size:.34722222em}.katex .fontsize-ensurer.reset-size8.size2,.katex .sizing.reset-size8.size2{font-size:.41666667em}.katex .fontsize-ensurer.reset-size8.size3,.katex .sizing.reset-size8.size3{font-size:.48611111em}.katex .fontsize-ensurer.reset-size8.size4,.katex .sizing.reset-size8.size4{font-size:.55555556em}.katex .fontsize-ensurer.reset-size8.size5,.katex .sizing.reset-size8.size5{font-size:.625em}.katex .fontsize-ensurer.reset-size8.size6,.katex .sizing.reset-size8.size6{font-size:.69444444em}.katex .fontsize-ensurer.reset-size8.size7,.katex .sizing.reset-size8.size7{font-size:.83333333em}.katex .fontsize-ensurer.reset-size8.size8,.katex .sizing.reset-size8.size8{font-size:1em}.katex .fontsize-ensurer.reset-size8.size9,.katex .sizing.reset-size8.size9{font-size:1.2em}.katex .fontsize-ensurer.reset-size8.size10,.katex .sizing.reset-size8.size10{font-size:1.44027778em}.katex .fontsize-ensurer.reset-size8.size11,.katex .sizing.reset-size8.size11{font-size:1.72777778em}.katex .fontsize-ensurer.reset-size9.size1,.katex .sizing.reset-size9.size1{font-size:.28935185em}.katex .fontsize-ensurer.reset-size9.size2,.katex .sizing.reset-size9.size2{font-size:.34722222em}.katex .fontsize-ensurer.reset-size9.size3,.katex .sizing.reset-size9.size3{font-size:.40509259em}.katex .fontsize-ensurer.reset-size9.size4,.katex .sizing.reset-size9.size4{font-size:.46296296em}.katex .fontsize-ensurer.reset-size9.size5,.katex .sizing.reset-size9.size5{font-size:.52083333em}.katex .fontsize-ensurer.reset-size9.size6,.katex .sizing.reset-size9.size6{font-size:.5787037em}.katex .fontsize-ensurer.reset-size9.size7,.katex .sizing.reset-size9.size7{font-size:.69444444em}.katex .fontsize-ensurer.reset-size9.size8,.katex .sizing.reset-size9.size8{font-size:.83333333em}.katex .fontsize-ensurer.reset-size9.size9,.katex .sizing.reset-size9.size9{font-size:1em}.katex .fontsize-ensurer.reset-size9.size10,.katex .sizing.reset-size9.size10{font-size:1.20023148em}.katex .fontsize-ensurer.reset-size9.size11,.katex .sizing.reset-size9.size11{font-size:1.43981481em}.katex .fontsize-ensurer.reset-size10.size1,.katex .sizing.reset-size10.size1{font-size:.24108004em}.katex .fontsize-ensurer.reset-size10.size2,.katex .sizing.reset-size10.size2{font-size:.28929605em}.katex .fontsize-ensurer.reset-size10.size3,.katex .sizing.reset-size10.size3{font-size:.33751205em}.katex .fontsize-ensurer.reset-size10.size4,.katex .sizing.reset-size10.size4{font-size:.38572806em}.katex .fontsize-ensurer.reset-size10.size5,.katex .sizing.reset-size10.size5{font-size:.43394407em}.katex .fontsize-ensurer.reset-size10.size6,.katex .sizing.reset-size10.size6{font-size:.48216008em}.katex .fontsize-ensurer.reset-size10.size7,.katex .sizing.reset-size10.size7{font-size:.57859209em}.katex .fontsize-ensurer.reset-size10.size8,.katex .sizing.reset-size10.size8{font-size:.69431051em}.katex .fontsize-ensurer.reset-size10.size9,.katex .sizing.reset-size10.size9{font-size:.83317261em}.katex .fontsize-ensurer.reset-size10.size10,.katex .sizing.reset-size10.size10{font-size:1em}.katex .fontsize-ensurer.reset-size10.size11,.katex .sizing.reset-size10.size11{font-size:1.19961427em}.katex .fontsize-ensurer.reset-size11.size1,.katex .sizing.reset-size11.size1{font-size:.20096463em}.katex .fontsize-ensurer.reset-size11.size2,.katex .sizing.reset-size11.size2{font-size:.24115756em}.katex .fontsize-ensurer.reset-size11.size3,.katex .sizing.reset-size11.size3{font-size:.28135048em}.katex .fontsize-ensurer.reset-size11.size4,.katex .sizing.reset-size11.size4{font-size:.32154341em}.katex .fontsize-ensurer.reset-size11.size5,.katex .sizing.reset-size11.size5{font-size:.36173633em}.katex .fontsize-ensurer.reset-size11.size6,.katex .sizing.reset-size11.size6{font-size:.40192926em}.katex .fontsize-ensurer.reset-size11.size7,.katex .sizing.reset-size11.size7{font-size:.48231511em}.katex .fontsize-ensurer.reset-size11.size8,.katex .sizing.reset-size11.size8{font-size:.57877814em}.katex .fontsize-ensurer.reset-size11.size9,.katex .sizing.reset-size11.size9{font-size:.69453376em}.katex .fontsize-ensurer.reset-size11.size10,.katex .sizing.reset-size11.size10{font-size:.83360129em}.katex .fontsize-ensurer.reset-size11.size11,.katex .sizing.reset-size11.size11{font-size:1em}.katex .delimsizing.size1{font-family:KaTeX_Size1}.katex .delimsizing.size2{font-family:KaTeX_Size2}.katex .delimsizing.size3{font-family:KaTeX_Size3}.katex .delimsizing.size4{font-family:KaTeX_Size4}.katex .delimsizing.mult .delim-size1>span{font-family:KaTeX_Size1}.katex .delimsizing.mult .delim-size4>span{font-family:KaTeX_Size4}.katex .nulldelimiter{display:inline-block;width:.12em}.katex .delimcenter,.katex .op-symbol{position:relative}.katex .op-symbol.small-op{font-family:KaTeX_Size1}.katex .op-symbol.large-op{font-family:KaTeX_Size2}.katex .accent>.vlist-t,.katex .op-limits>.vlist-t{text-align:center}.katex .accent .accent-body{position:relative}.katex .accent .accent-body:not(.accent-full){width:0}.katex .overlay{display:block}.katex .mtable .vertical-separator{display:inline-block;min-width:1px}.katex .mtable .arraycolsep{display:inline-block}.katex .mtable .col-align-c>.vlist-t{text-align:center}.katex .mtable .col-align-l>.vlist-t{text-align:left}.katex .mtable .col-align-r>.vlist-t{text-align:right}.katex .svg-align{text-align:left}.katex svg{fill:currentColor;stroke:currentColor;fill-rule:nonzero;fill-opacity:1;stroke-width:1;stroke-linecap:butt;stroke-linejoin:miter;stroke-miterlimit:4;stroke-dasharray:none;stroke-dashoffset:0;stroke-opacity:1;display:block;height:inherit;position:absolute;width:100%}.katex svg path{stroke:none}.katex img{border-style:none;max-height:none;max-width:none;min-height:0;min-width:0}.katex .stretchy{display:block;overflow:hidden;position:relative;width:100%}.katex .stretchy:after,.katex .stretchy:before{content:""}.katex .hide-tail{overflow:hidden;position:relative;width:100%}.katex .halfarrow-left{left:0;overflow:hidden;position:absolute;width:50.2%}.katex .halfarrow-right{overflow:hidden;position:absolute;right:0;width:50.2%}.katex .brace-left{left:0;overflow:hidden;position:absolute;width:25.1%}.katex .brace-center{left:25%;overflow:hidden;position:absolute;width:50%}.katex .brace-right{overflow:hidden;position:absolute;right:0;width:25.1%}.katex .x-arrow-pad{padding:0 .5em}.katex .cd-arrow-pad{padding:0 .55556em 0 .27778em}.katex .mover,.katex .munder,.katex .x-arrow{text-align:center}.katex .boxpad{padding:0 .3em}.katex .fbox,.katex .fcolorbox{border:.04em solid;box-sizing:border-box}.katex .cancel-pad{padding:0 .2em}.katex .cancel-lap{margin-left:-.2em;margin-right:-.2em}.katex .sout{border-bottom-style:solid;border-bottom-width:.08em}.katex .angl{border-right:.049em solid;border-top:.049em solid;box-sizing:border-box;margin-right:.03889em}.katex .anglpad{padding:0 .03889em}.katex .eqn-num:before{content:"(" counter(katexEqnNo) ")";counter-increment:katexEqnNo}.katex .mml-eqn-num:before{content:"(" counter(mmlEqnNo) ")";counter-increment:mmlEqnNo}.katex .mtr-glue{width:50%}.katex .cd-vert-arrow{display:inline-block;position:relative}.katex .cd-label-left{display:inline-block;position:absolute;right:calc(50% + .3em);text-align:left}.katex .cd-label-right{display:inline-block;left:calc(50% + .3em);position:absolute;text-align:right}.katex-display{display:block;margin:1em 0;text-align:center}.katex-display>.katex{display:block;text-align:center;white-space:nowrap}.katex-display>.katex>.katex-html{display:block;position:relative}.katex-display>.katex>.katex-html>.tag{position:absolute;right:0}.katex-display.leqno>.katex>.katex-html>.tag{left:0;right:auto}.katex-display.fleqn>.katex{padding-left:2em;text-align:left}body{counter-reset:katexEqnNo mmlEqnNo} diff --git a/website/tsconfig.json b/website/tsconfig.json index 40130b894da3..0fcd0946a271 100644 --- a/website/tsconfig.json +++ b/website/tsconfig.json @@ -28,6 +28,8 @@ "noUnusedParameters": false, "importsNotUsedAsValues": "remove", + "moduleResolution": "NodeNext", + // This is important. We run `yarn tsc` in website so we can catch issues // with our declaration files (mostly names that are forgotten to be // imported, invalid semantics...). Because we don't have end-to-end type diff --git a/website/versioned_docs/version-2.0.0-beta.20/api/misc/eslint-plugin/no-untranslated-text.md b/website/versioned_docs/version-2.0.0-beta.20/api/misc/eslint-plugin/no-untranslated-text.md index 346c021fe8ea..85242bc31ef3 100644 --- a/website/versioned_docs/version-2.0.0-beta.20/api/misc/eslint-plugin/no-untranslated-text.md +++ b/website/versioned_docs/version-2.0.0-beta.20/api/misc/eslint-plugin/no-untranslated-text.md @@ -4,6 +4,8 @@ slug: '/api/misc/@docusaurus/eslint-plugin/no-untranslated-text' # no-untranslated-text +import APITable from '@site/src/components/APITable'; + Enforce text labels in JSX to be wrapped by translate calls. When the [i18n feature](../../../i18n/i18n-introduction.md) is used, this rule ensures that all labels appearing on the website are translatable, so no string accidentally slips through untranslated. diff --git a/website/versioned_docs/version-2.0.0-beta.20/guides/creating-pages.md b/website/versioned_docs/version-2.0.0-beta.20/guides/creating-pages.md index cdf100cdf9a9..a5ddaa304b9b 100644 --- a/website/versioned_docs/version-2.0.0-beta.20/guides/creating-pages.md +++ b/website/versioned_docs/version-2.0.0-beta.20/guides/creating-pages.md @@ -51,7 +51,7 @@ export default function Hello() { } ``` -Once you save the file, the development server will automatically reload the changes. Now open `http://localhost:3000/helloReact` and you will see the new page you just created. +Once you save the file, the development server will automatically reload the changes. Now open [http://localhost:3000/helloReact](http://localhost:3000/helloReact) and you will see the new page you just created. Each page doesn't come with any styling. You will need to import the `Layout` component from `@theme/Layout` and wrap your contents within that component if you want the navbar and/or footer to appear. @@ -77,7 +77,7 @@ hide_table_of_contents: true How are you? ``` -In the same way, a page will be created at `http://localhost:3000/helloMarkdown`. +In the same way, a page will be created at [http://localhost:3000/helloMarkdown](http://localhost:3000/helloMarkdown). Markdown pages are less flexible than React pages because it always uses the theme layout. diff --git a/website/versioned_docs/version-2.0.0-beta.20/i18n/i18n-crowdin.mdx b/website/versioned_docs/version-2.0.0-beta.20/i18n/i18n-crowdin.mdx index 60afe1f10b22..17c318e1bcf9 100644 --- a/website/versioned_docs/version-2.0.0-beta.20/i18n/i18n-crowdin.mdx +++ b/website/versioned_docs/version-2.0.0-beta.20/i18n/i18n-crowdin.mdx @@ -287,7 +287,7 @@ Start your site on the French locale: npm run start -- --locale fr ``` -Make sure that your website is now translated in French at `http://localhost:3000/fr/`. +Make sure that your website is now translated in French at [http://localhost:3000/fr/](http://localhost:3000/fr/). ### Automate with CI {#automate-with-ci} diff --git a/website/versioned_docs/version-2.0.0-beta.20/i18n/i18n-tutorial.md b/website/versioned_docs/version-2.0.0-beta.20/i18n/i18n-tutorial.md index c8e051ab3258..1612c02e47ac 100644 --- a/website/versioned_docs/version-2.0.0-beta.20/i18n/i18n-tutorial.md +++ b/website/versioned_docs/version-2.0.0-beta.20/i18n/i18n-tutorial.md @@ -74,7 +74,7 @@ Start your localized site in dev mode, using the locale of your choice: npm run start -- --locale fr ``` -Your site is accessible at **`http://localhost:3000/fr/`**. +Your site is accessible at [http://localhost:3000/fr/](http://localhost:3000/fr/). We haven't provided any translation yet, so the site is mostly untranslated. diff --git a/website/versioned_docs/version-2.0.0-beta.20/introduction.md b/website/versioned_docs/version-2.0.0-beta.20/introduction.md index de877f623891..6685515b99b5 100644 --- a/website/versioned_docs/version-2.0.0-beta.20/introduction.md +++ b/website/versioned_docs/version-2.0.0-beta.20/introduction.md @@ -36,7 +36,7 @@ cd my-website npx docusaurus start ``` -Open `http://localhost:3000` and follow the tutorial. +Open [http://localhost:3000](http://localhost:3000) and follow the tutorial. :::tip diff --git a/website/versioned_docs/version-2.0.0-beta.20/search.md b/website/versioned_docs/version-2.0.0-beta.20/search.md index d3b27ec96cab..e4a066e4ffd0 100644 --- a/website/versioned_docs/version-2.0.0-beta.20/search.md +++ b/website/versioned_docs/version-2.0.0-beta.20/search.md @@ -1,5 +1,4 @@ --- -id: search title: Search keywords: - algolia diff --git a/website/versioned_docs/version-2.0.0-beta.21/api/misc/eslint-plugin/no-untranslated-text.md b/website/versioned_docs/version-2.0.0-beta.21/api/misc/eslint-plugin/no-untranslated-text.md index 346c021fe8ea..85242bc31ef3 100644 --- a/website/versioned_docs/version-2.0.0-beta.21/api/misc/eslint-plugin/no-untranslated-text.md +++ b/website/versioned_docs/version-2.0.0-beta.21/api/misc/eslint-plugin/no-untranslated-text.md @@ -4,6 +4,8 @@ slug: '/api/misc/@docusaurus/eslint-plugin/no-untranslated-text' # no-untranslated-text +import APITable from '@site/src/components/APITable'; + Enforce text labels in JSX to be wrapped by translate calls. When the [i18n feature](../../../i18n/i18n-introduction.md) is used, this rule ensures that all labels appearing on the website are translatable, so no string accidentally slips through untranslated. diff --git a/website/versioned_docs/version-2.0.0-beta.21/guides/creating-pages.md b/website/versioned_docs/version-2.0.0-beta.21/guides/creating-pages.md index cdf100cdf9a9..a5ddaa304b9b 100644 --- a/website/versioned_docs/version-2.0.0-beta.21/guides/creating-pages.md +++ b/website/versioned_docs/version-2.0.0-beta.21/guides/creating-pages.md @@ -51,7 +51,7 @@ export default function Hello() { } ``` -Once you save the file, the development server will automatically reload the changes. Now open `http://localhost:3000/helloReact` and you will see the new page you just created. +Once you save the file, the development server will automatically reload the changes. Now open [http://localhost:3000/helloReact](http://localhost:3000/helloReact) and you will see the new page you just created. Each page doesn't come with any styling. You will need to import the `Layout` component from `@theme/Layout` and wrap your contents within that component if you want the navbar and/or footer to appear. @@ -77,7 +77,7 @@ hide_table_of_contents: true How are you? ``` -In the same way, a page will be created at `http://localhost:3000/helloMarkdown`. +In the same way, a page will be created at [http://localhost:3000/helloMarkdown](http://localhost:3000/helloMarkdown). Markdown pages are less flexible than React pages because it always uses the theme layout. diff --git a/website/versioned_docs/version-2.0.0-beta.21/i18n/i18n-crowdin.mdx b/website/versioned_docs/version-2.0.0-beta.21/i18n/i18n-crowdin.mdx index 60afe1f10b22..17c318e1bcf9 100644 --- a/website/versioned_docs/version-2.0.0-beta.21/i18n/i18n-crowdin.mdx +++ b/website/versioned_docs/version-2.0.0-beta.21/i18n/i18n-crowdin.mdx @@ -287,7 +287,7 @@ Start your site on the French locale: npm run start -- --locale fr ``` -Make sure that your website is now translated in French at `http://localhost:3000/fr/`. +Make sure that your website is now translated in French at [http://localhost:3000/fr/](http://localhost:3000/fr/). ### Automate with CI {#automate-with-ci} diff --git a/website/versioned_docs/version-2.0.0-beta.21/i18n/i18n-tutorial.md b/website/versioned_docs/version-2.0.0-beta.21/i18n/i18n-tutorial.md index c8e051ab3258..1612c02e47ac 100644 --- a/website/versioned_docs/version-2.0.0-beta.21/i18n/i18n-tutorial.md +++ b/website/versioned_docs/version-2.0.0-beta.21/i18n/i18n-tutorial.md @@ -74,7 +74,7 @@ Start your localized site in dev mode, using the locale of your choice: npm run start -- --locale fr ``` -Your site is accessible at **`http://localhost:3000/fr/`**. +Your site is accessible at [http://localhost:3000/fr/](http://localhost:3000/fr/). We haven't provided any translation yet, so the site is mostly untranslated. diff --git a/website/versioned_docs/version-2.0.0-beta.21/introduction.md b/website/versioned_docs/version-2.0.0-beta.21/introduction.md index cec5f22c2e08..ea5797cec9c6 100644 --- a/website/versioned_docs/version-2.0.0-beta.21/introduction.md +++ b/website/versioned_docs/version-2.0.0-beta.21/introduction.md @@ -36,7 +36,7 @@ cd my-website npx docusaurus start ``` -Open `http://localhost:3000` and follow the tutorial. +Open [http://localhost:3000](http://localhost:3000) and follow the tutorial. :::tip diff --git a/website/versioned_docs/version-2.0.0-beta.21/search.md b/website/versioned_docs/version-2.0.0-beta.21/search.md index d3b27ec96cab..e4a066e4ffd0 100644 --- a/website/versioned_docs/version-2.0.0-beta.21/search.md +++ b/website/versioned_docs/version-2.0.0-beta.21/search.md @@ -1,5 +1,4 @@ --- -id: search title: Search keywords: - algolia diff --git a/yarn.lock b/yarn.lock index 7483121c936e..528b7a5adfe4 100644 --- a/yarn.lock +++ b/yarn.lock @@ -354,7 +354,7 @@ "@babel/helper-wrap-function" "^7.16.8" "@babel/types" "^7.16.8" -"@babel/helper-replace-supers@^7.16.7": +"@babel/helper-replace-supers@^7.16.7", "@babel/helper-replace-supers@^7.18.2": version "7.18.2" resolved "https://registry.yarnpkg.com/@babel/helper-replace-supers/-/helper-replace-supers-7.18.2.tgz#41fdfcc9abaf900e18ba6e5931816d9062a7b2e0" integrity sha512-XzAIyxx+vFnrOxiQrToSUOzUOn0e1J2Li40ntddek1Y69AXUTXoDJ40/D5RdjFu7s7qHiaeoTiempZcbuVXh2Q== @@ -424,10 +424,10 @@ 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.18.0", "@babel/parser@^7.18.3": - version "7.18.3" - resolved "https://registry.yarnpkg.com/@babel/parser/-/parser-7.18.3.tgz#39e99c7b0c4c56cef4d1eed8de9f506411c2ebc2" - integrity sha512-rL50YcEuHbbauAFAysNsJA4/f89fGTOBRNs9P81sniKnKAr4xULe5AecolcsKbi88xu0ByWYDj/S1AJ3FSFuSQ== +"@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", "@babel/parser@^7.18.4": + version "7.18.4" + resolved "https://registry.yarnpkg.com/@babel/parser/-/parser-7.18.4.tgz#6774231779dd700e0af29f6ad8d479582d7ce5ef" + integrity sha512-FDge0dFazETFcxGw/EXzOkN8uJp0PC7Qbm+Pe9T+av2zlBpOgunFHkQPPn+eRuClU73JF+98D531UgayY89tow== "@babel/plugin-bugfix-safari-id-destructuring-collision-in-function-expression@^7.17.12": version "7.17.12" @@ -753,23 +753,23 @@ "@babel/helper-plugin-utils" "^7.16.7" "@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== + version "7.18.4" + resolved "https://registry.yarnpkg.com/@babel/plugin-transform-block-scoping/-/plugin-transform-block-scoping-7.18.4.tgz#7988627b3e9186a13e4d7735dc9c34a056613fb9" + integrity sha512-+Hq10ye+jlvLEogSOtq4mKvtk7qwcUQ1f0Mrueai866C82f844Yom2cttfJdMdqRLTxWpsbfbkIkOIfovyUQXw== dependencies: "@babel/helper-plugin-utils" "^7.17.12" "@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== + version "7.18.4" + resolved "https://registry.yarnpkg.com/@babel/plugin-transform-classes/-/plugin-transform-classes-7.18.4.tgz#51310b812a090b846c784e47087fa6457baef814" + integrity sha512-e42NSG2mlKWgxKUAD9EJJSkZxR67+wZqzNxLSpc51T8tRU5SLFHsPmgYR5yr7sdgX4u+iHA1C5VafJ6AyImV3A== dependencies: "@babel/helper-annotate-as-pure" "^7.16.7" - "@babel/helper-environment-visitor" "^7.16.7" + "@babel/helper-environment-visitor" "^7.18.2" "@babel/helper-function-name" "^7.17.9" "@babel/helper-optimise-call-expression" "^7.16.7" "@babel/helper-plugin-utils" "^7.17.12" - "@babel/helper-replace-supers" "^7.16.7" + "@babel/helper-replace-supers" "^7.18.2" "@babel/helper-split-export-declaration" "^7.16.7" globals "^11.1.0" @@ -868,9 +868,9 @@ babel-plugin-dynamic-import-node "^2.3.3" "@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== + version "7.18.4" + resolved "https://registry.yarnpkg.com/@babel/plugin-transform-modules-systemjs/-/plugin-transform-modules-systemjs-7.18.4.tgz#3d6fd9868c735cce8f38d6ae3a407fb7e61e6d46" + integrity sha512-lH2UaQaHVOAeYrUUuZ8i38o76J/FnO8vu21OE+tD1MyP9lxdZoSfz+pDbWkq46GogUrdrMz3tiz/FYGB+bVThg== dependencies: "@babel/helper-hoist-variables" "^7.16.7" "@babel/helper-module-transforms" "^7.18.0" @@ -1027,9 +1027,9 @@ "@babel/helper-plugin-utils" "^7.17.12" "@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== + version "7.18.4" + resolved "https://registry.yarnpkg.com/@babel/plugin-transform-typescript/-/plugin-transform-typescript-7.18.4.tgz#587eaf6a39edb8c06215e550dc939faeadd750bf" + integrity sha512-l4vHuSLUajptpHNEOUDEGsnpl9pfRLsN1XUoDQDD/YBuXTM+v37SHGS+c6n4jdcZy96QtuUuSvZYMLSSsjH8Mw== dependencies: "@babel/helper-create-class-features-plugin" "^7.18.0" "@babel/helper-plugin-utils" "^7.17.12" @@ -1224,9 +1224,9 @@ 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.12", "@babel/types@^7.18.0", "@babel/types@^7.18.2", "@babel/types@^7.3.0", "@babel/types@^7.3.3", "@babel/types@^7.4.4": - version "7.18.2" - resolved "https://registry.yarnpkg.com/@babel/types/-/types-7.18.2.tgz#191abfed79ebe6f4242f643a9a5cbaa36b10b091" - integrity sha512-0On6B8A4/+mFUto5WERt3EEuG1NznDirvwca1O8UwXQHVY8g3R7OzYgxXdOfMwLO08UrpUD/2+3Bclyq+/C94Q== + version "7.18.4" + resolved "https://registry.yarnpkg.com/@babel/types/-/types-7.18.4.tgz#27eae9b9fd18e9dccc3f9d6ad051336f307be354" + integrity sha512-ThN1mBcMq5pG/Vm2IcBmPPfyPXbd8S02rS+OBIDENdufvqC7Z/jHPCv9IcP01277aKtDI8g/2XysBN4hA8niiw== dependencies: "@babel/helper-validator-identifier" "^7.16.7" to-fast-properties "^2.0.0" @@ -1256,61 +1256,62 @@ dependencies: axios "0.21.3" -"@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== +"@cspell/cspell-bundled-dicts@^6.1.2": + version "6.1.2" + resolved "https://registry.yarnpkg.com/@cspell/cspell-bundled-dicts/-/cspell-bundled-dicts-6.1.2.tgz#40a2af61152f5e68097be206dbb0dfc512f79e32" + integrity sha512-vMS15jKPNH93Fv0bu/lrTSmXKt6hDCEEwOIyajO84cJMuKRVuR9Vw0ZtkFsVAwHyTNZ8mGxposQ20TbAL/SUlw== 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-bash" "^2.0.3" + "@cspell/dict-companies" "^2.0.5" "@cspell/dict-cpp" "^3.1.0" "@cspell/dict-cryptocurrencies" "^2.0.0" "@cspell/dict-csharp" "^3.0.1" "@cspell/dict-css" "^2.0.0" - "@cspell/dict-dart" "^1.1.0" + "@cspell/dict-dart" "^1.1.1" "@cspell/dict-django" "^2.0.0" + "@cspell/dict-docker" "^1.1.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.5" "@cspell/dict-filetypes" "^2.0.1" "@cspell/dict-fonts" "^2.0.0" - "@cspell/dict-fullstack" "^2.0.5" + "@cspell/dict-fullstack" "^2.0.6" "@cspell/dict-git" "^1.0.1" "@cspell/dict-golang" "^3.0.1" "@cspell/dict-haskell" "^2.0.0" "@cspell/dict-html" "^3.0.1" "@cspell/dict-html-symbol-entities" "^3.0.0" - "@cspell/dict-java" "^2.0.0" - "@cspell/dict-latex" "^2.0.3" + "@cspell/dict-java" "^3.0.2" + "@cspell/dict-latex" "^2.0.5" "@cspell/dict-lorem-ipsum" "^2.0.0" "@cspell/dict-lua" "^2.0.0" - "@cspell/dict-node" "^2.0.1" - "@cspell/dict-npm" "^2.0.3" + "@cspell/dict-node" "^3.0.1" + "@cspell/dict-npm" "^3.0.1" "@cspell/dict-php" "^2.0.0" "@cspell/dict-powershell" "^2.0.0" - "@cspell/dict-public-licenses" "^1.0.4" - "@cspell/dict-python" "^3.0.5" - "@cspell/dict-r" "^1.0.2" + "@cspell/dict-public-licenses" "^1.0.5" + "@cspell/dict-python" "^3.0.6" + "@cspell/dict-r" "^1.0.3" "@cspell/dict-ruby" "^2.0.1" "@cspell/dict-rust" "^2.0.0" "@cspell/dict-scala" "^2.0.0" - "@cspell/dict-software-terms" "^2.1.7" - "@cspell/dict-swift" "^1.0.2" + "@cspell/dict-software-terms" "^2.1.8" + "@cspell/dict-swift" "^1.0.3" "@cspell/dict-typescript" "^2.0.0" "@cspell/dict-vue" "^2.0.2" -"@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-pipe@^6.1.2": + version "6.1.2" + resolved "https://registry.yarnpkg.com/@cspell/cspell-pipe/-/cspell-pipe-6.1.2.tgz#8c2cc03c5e146a0eec4b03f936d6598f6509680e" + integrity sha512-QPbRsumSbu2h6Sdls2bv6FeLFBvs+XSSOmBwVXTaRu6Vl0hEi3P69BiHIWTYQqWTe2NYZnW8lpXUh5/J8/nolw== -"@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/cspell-types@^6.1.2": + version "6.1.2" + resolved "https://registry.yarnpkg.com/@cspell/cspell-types/-/cspell-types-6.1.2.tgz#5689a6656160052d5a9d60f0d2316c894e885a09" + integrity sha512-EENGQ469e3mTpSWfMF/GS29eOAAONiavdVF/uiV8kcxf8SqfkMJvVjFZ1w0KgC80pnCVUzRzMBO4HKmXPj6Ncg== "@cspell/dict-ada@^2.0.0": version "2.0.0" @@ -1322,15 +1323,15 @@ resolved "https://registry.yarnpkg.com/@cspell/dict-aws/-/dict-aws-2.0.0.tgz#9af72af4e59e96029dd4335271d87784843cb7dd" integrity sha512-NKz7pDZ7pwj/b33i3f4WLpC1rOOUMmENwYgftxU+giU2YBeKM2wZbMTSEIzsrel56r0UlQYmdIVlP/B4nnVaoQ== -"@cspell/dict-bash@^2.0.2": - version "2.0.2" - resolved "https://registry.yarnpkg.com/@cspell/dict-bash/-/dict-bash-2.0.2.tgz#8bc3e0a6c1b9c0df1bd9a1b7694c58d9843fd16b" - integrity sha512-ASIgI/LmV2TYrD4mtk+gm4XmUSTRomOyRt7NDWyBpEww/AeawC2O2NH6FosyUT6dUU3GaXt2wgJRN7R78n1SGg== +"@cspell/dict-bash@^2.0.3": + version "2.0.3" + resolved "https://registry.yarnpkg.com/@cspell/dict-bash/-/dict-bash-2.0.3.tgz#a54d6b8899569e348fcd33c95daaeef42075d75b" + integrity sha512-iw78lmxm49q2LhHTQCSu9zs85E8Sm6ui82OvxajU9rdhckFzZoj/KCQi9P0gFuL+w3WmQObHqdH2/sxK4oi2wA== -"@cspell/dict-companies@^2.0.4": - version "2.0.4" - resolved "https://registry.yarnpkg.com/@cspell/dict-companies/-/dict-companies-2.0.4.tgz#2ba11418478d99d67a96004ea782a47a42c501a3" - integrity sha512-nLNVddo+iu4q/Mu03nkVTMnSPxBkoLyZ0MgpHJZWCqxVATbBkzoZNNNjsTkJhvkbrUIWydf8YW4U4wYY+kyh7Q== +"@cspell/dict-companies@^2.0.5": + version "2.0.5" + resolved "https://registry.yarnpkg.com/@cspell/dict-companies/-/dict-companies-2.0.5.tgz#0365e74a55b43d4493d44ea1071998bab16d6227" + integrity sha512-H8+LU+gDUeJ8RcV1kMSIiHa5PE/8tYyA2tg/s6ssHtsgsJ206I+cRFV8yAlu0mUUCXD617+KKXmclZ0eZ7ku4w== "@cspell/dict-cpp@^3.1.0": version "3.1.0" @@ -1352,7 +1353,7 @@ resolved "https://registry.yarnpkg.com/@cspell/dict-css/-/dict-css-2.0.0.tgz#91dca013f16b51144eaea160e144b830f2dad027" integrity sha512-MrFyswFHnPh4H0u6IlV4eHy+ZCUrrHzeL161LyTOqCvaKpbZavMgNYXzZqTF9xafO0iLgwKrl+Gkclu1KVBg0Q== -"@cspell/dict-dart@^1.1.0": +"@cspell/dict-dart@^1.1.1": version "1.1.1" resolved "https://registry.yarnpkg.com/@cspell/dict-dart/-/dict-dart-1.1.1.tgz#d4da9cf72e5df369b6d9ebe588f9c1474adf3556" integrity sha512-XBOCpezXrgFN18kGEwqMpTUGZdw4BjCoJrNOo6qBdcdZySCrEHLwELraLOkcSba2kM4stmTp0t59FkwtP8TKOA== @@ -1362,6 +1363,11 @@ resolved "https://registry.yarnpkg.com/@cspell/dict-django/-/dict-django-2.0.0.tgz#a5f5f693a686e5873f9dfb547ee3b3142ef760b1" integrity sha512-GkJdJv6cmzrKcmq2/oxTXjKF5uv71r4eTqnFmgPbNBW1t+G4VYpzOf0QrVQrhx2RC4DdW5XfcTf+iS0FxHOTmw== +"@cspell/dict-docker@^1.1.0": + version "1.1.0" + resolved "https://registry.yarnpkg.com/@cspell/dict-docker/-/dict-docker-1.1.0.tgz#16d4a6c0c27f402060fe8223a85d9eae517f08c7" + integrity sha512-2OI5srKxeoiOnAD34jGK2pDGbgeQDnBCuE64bM04Uct7QxPjIv1RDpWLa3VMWhFIzeoyNSNWwDB+x5ufVc6VXA== + "@cspell/dict-dotnet@^2.0.1": version "2.0.1" resolved "https://registry.yarnpkg.com/@cspell/dict-dotnet/-/dict-dotnet-2.0.1.tgz#8ef56df758b63f0a2ba4d8681a427a6861ed34d5" @@ -1392,10 +1398,10 @@ resolved "https://registry.yarnpkg.com/@cspell/dict-fonts/-/dict-fonts-2.0.0.tgz#76e7781b44cdda6933144e15cba80e978c29bd15" integrity sha512-AgkTalphfDPtKFPYmEExDcj8rRCh86xlOSXco8tehOEkYVYbksOk9XH0YVH34RFpy93YBd2nnVGLgyGVwagcPw== -"@cspell/dict-fullstack@^2.0.5": - version "2.0.5" - resolved "https://registry.yarnpkg.com/@cspell/dict-fullstack/-/dict-fullstack-2.0.5.tgz#ffe416f90b0b30f1586e75432c0bc09b4c1faf96" - integrity sha512-jnLnHZ4HcCFNUfN+q7m0CUDtISNKat0Jahe1GgnAdEwzcozqKBhlGAjV7mQWPtKpqfJU61JakDnrxzqefAfZHw== +"@cspell/dict-fullstack@^2.0.6": + version "2.0.6" + resolved "https://registry.yarnpkg.com/@cspell/dict-fullstack/-/dict-fullstack-2.0.6.tgz#0bec93306cba070ed6aa0b619d8080c86310ab5d" + integrity sha512-R2E2xvbHvvRwwurxfpBJDRIJjXBMfEPF5WNV3LTOEMRqkZtoYCeJK9aqc8LHlmJMtAbnN1cx//BCDIyTJ0rO0A== "@cspell/dict-git@^1.0.1": version "1.0.1" @@ -1422,15 +1428,15 @@ resolved "https://registry.yarnpkg.com/@cspell/dict-html/-/dict-html-3.0.1.tgz#d5d10ef9b62361d8250cf9fe8564606993faa9df" integrity sha512-sbuFd+nSjgbrGf5eYwSddFhm1eLLePKWyH6Zn8Zb0OODrBK5e4vGn1/scI/MOH5a2IvNs8W9wp84uMBFJcQZtw== -"@cspell/dict-java@^2.0.0": - version "2.0.0" - resolved "https://registry.yarnpkg.com/@cspell/dict-java/-/dict-java-2.0.0.tgz#76252cee8f04e099ac6dae0f45f22257088060a7" - integrity sha512-9f5LDATlAiXRGqxLxgqbOLlQxuMW2zcN7tBgxwtN+4u90vM03ZUOR/gKIuDV/y0ZuAiWBIjA73cjk8DJ13Q1eA== +"@cspell/dict-java@^3.0.2": + version "3.0.2" + resolved "https://registry.yarnpkg.com/@cspell/dict-java/-/dict-java-3.0.2.tgz#796e1ab947c00b21871f66edd74e3fb181fd5de8" + integrity sha512-OUhtLruqN+ztDEViEQDw22L883xaignSZHyl7CnD8rTwcuhcaumdAhu4c3mygIDnFGtk/a+pk4ZaXk1ZINvK7g== -"@cspell/dict-latex@^2.0.3": - version "2.0.4" - resolved "https://registry.yarnpkg.com/@cspell/dict-latex/-/dict-latex-2.0.4.tgz#b201fa2cc25ab8753b0a09f3c32ee0e068c5d20e" - integrity sha512-uqnfQiDQwHL4QTtXQyJdTx6Ol9WDu4c2jMSsL20BIe1wXGaGuGNSIwHEiJyGv7VEBpZTpqx38I4mpKdAERG+gw== +"@cspell/dict-latex@^2.0.5": + version "2.0.5" + resolved "https://registry.yarnpkg.com/@cspell/dict-latex/-/dict-latex-2.0.5.tgz#4702ee23a4cb5bbbc694553858cbb38b5eb0df5d" + integrity sha512-r6aOaLWzvH3lZteVo/TiS6Ee2vng2qDwtvHLEHrzsq/SaIeHb6FoKJxnMpaNE1H85G/LMkG0LA1tMtl0C3JxsQ== "@cspell/dict-lorem-ipsum@^2.0.0": version "2.0.0" @@ -1442,15 +1448,15 @@ resolved "https://registry.yarnpkg.com/@cspell/dict-lua/-/dict-lua-2.0.0.tgz#b96d0363a28ac7e0483ad03edb21705c4f951459" integrity sha512-7WUEBEspSKtsq104WdIys1+DLqAxpJPzw74Py1TuE3fI5GvlzeSZkRFP2ya54GB2lCO4C3mq4M8EnitpibVDfw== -"@cspell/dict-node@^2.0.1": - version "2.0.1" - resolved "https://registry.yarnpkg.com/@cspell/dict-node/-/dict-node-2.0.1.tgz#eda891ebdbce83f20829cb6c85cd209da8cf5cdd" - integrity sha512-ztBWzhvI+YaMehICSJ65cohhjQqoztxf9vrS3YckOiVGBFvUMaFVNdX9klQkvrLcS/O4+2PzoGeIEkmf99amLA== +"@cspell/dict-node@^3.0.1": + version "3.0.1" + resolved "https://registry.yarnpkg.com/@cspell/dict-node/-/dict-node-3.0.1.tgz#a6ee043f5dc044391e5ecc4f293497f9d96d48e1" + integrity sha512-sK2cpuV0EAc43Amd5xeQXkI9MeRTECMw+yjap06gKSModbgI7BqJUHeKZed+0Hii+LpaJ4TYpLGiRVsO+qSk0w== -"@cspell/dict-npm@^2.0.3": - version "2.0.5" - resolved "https://registry.yarnpkg.com/@cspell/dict-npm/-/dict-npm-2.0.5.tgz#d5b77025fcb46db843091e002409faffcfccade0" - integrity sha512-KuPL5fKaqyG9ACrrinNt84FhVdh23VRtxDLO8MtGUdStca9tjfjPdmP2YF/5VkEKmpKYkfFKVcBUk9RgVkx5bw== +"@cspell/dict-npm@^3.0.1": + version "3.0.1" + resolved "https://registry.yarnpkg.com/@cspell/dict-npm/-/dict-npm-3.0.1.tgz#91cf3e263d17e0ef80117e76936559e2d16613f3" + integrity sha512-ZfuzFwE03WwyShwvQfXhhKIrFxgAkOtA/N1KdEwfP//nVDgysJfGueBhJJfI6vjUSr1IA+u5DXrSV0nowLAEhg== "@cspell/dict-php@^2.0.0": version "2.0.0" @@ -1462,17 +1468,17 @@ resolved "https://registry.yarnpkg.com/@cspell/dict-powershell/-/dict-powershell-2.0.0.tgz#6e8ae7381b1928dfaf8f5a625f8fae6e8d93f224" integrity sha512-6uvEhLiGmG3u9TFkM1TYcky6aL9Yk7Sk3KJwoTYBaQJY2KqrprgyQtW6yxIw9oU52VRHlq3KKvSAA9Q26+SIkQ== -"@cspell/dict-public-licenses@^1.0.4": +"@cspell/dict-public-licenses@^1.0.5": version "1.0.5" resolved "https://registry.yarnpkg.com/@cspell/dict-public-licenses/-/dict-public-licenses-1.0.5.tgz#b4eeb08107b83966913689fcb09f495da249233d" integrity sha512-N9bttzzhmCq/BN/TeP43075kj9TeaR8l9v0SPre05BRWsChVrWuMM1UvsT4ADXnsYJNl1xcn+q191S/fIzQhBg== -"@cspell/dict-python@^3.0.5": +"@cspell/dict-python@^3.0.6": version "3.0.6" resolved "https://registry.yarnpkg.com/@cspell/dict-python/-/dict-python-3.0.6.tgz#884f398e053a5d500adc9de47d1f1049a7afcc9c" integrity sha512-tzxJ4sd9ZGhAUKg/WJJpQGDNtoHvM8Wn+iS2+PnQj2/LTHBW4mnaCogsGsBtYu8C4b2+BEQs+tc5808AeEfLug== -"@cspell/dict-r@^1.0.2": +"@cspell/dict-r@^1.0.3": version "1.0.3" resolved "https://registry.yarnpkg.com/@cspell/dict-r/-/dict-r-1.0.3.tgz#1480016695ee119cf63fa8c71b161d033bbb9029" integrity sha512-u2qeXd4cx/TvTVcmkvA+sK6f4K1uMAMO6QPMSr1pSvqGElPRP1mIBXmuiSuBzLO3LbsJuUEHw5Cp3/bxIB6rNA== @@ -1492,12 +1498,12 @@ 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.7": +"@cspell/dict-software-terms@^2.1.8": version "2.1.8" resolved "https://registry.yarnpkg.com/@cspell/dict-software-terms/-/dict-software-terms-2.1.8.tgz#2db1d3ce7c125552e86503bb09379041787e1a07" integrity sha512-D9ECefkdbr5B0yLimy7nmEBl3AHPsweMG1wHatlCIT9uFwwqaq5e+ngbYrntEhMa6afkYY+LGOLbZ1L1dfpLVg== -"@cspell/dict-swift@^1.0.2": +"@cspell/dict-swift@^1.0.3": version "1.0.3" resolved "https://registry.yarnpkg.com/@cspell/dict-swift/-/dict-swift-1.0.3.tgz#b819da0ca2c5dfecdd61bec55181636a06d23677" integrity sha512-yOBLSaRD0AnkkkndJ8PuB82Evp6lA2xItf2AWsnPfCCgxp5Ojk6uUBC/WQBSkzkCAOGbXyHsu9D97tsOx2c6cw== @@ -1512,6 +1518,11 @@ resolved "https://registry.yarnpkg.com/@cspell/dict-vue/-/dict-vue-2.0.2.tgz#8618b9f4825b3d80e1788082c19ac9c15832463e" integrity sha512-/MB0RS0Gn01s4pgmjy0FvsLfr3RRMrRphEuvTRserNcM8XVtoIVAtrjig/Gg0DPwDrN8Clm0L1j7iQay6S8D0g== +"@csstools/selector-specificity@^2.0.1": + version "2.0.1" + resolved "https://registry.yarnpkg.com/@csstools/selector-specificity/-/selector-specificity-2.0.1.tgz#b6b8d81780b9a9f6459f4bfe9226ac6aefaefe87" + integrity sha512-aG20vknL4/YjQF9BSV7ts4EWm/yrjagAN7OWBNmlbEOUiu0llj4OGrFoOKK3g2vey4/p2omKCoHrWtPxSwV3HA== + "@docsearch/css@3.1.0": version "3.1.0" resolved "https://registry.yarnpkg.com/@docsearch/css/-/css-3.1.0.tgz#6781cad43fc2e034d012ee44beddf8f93ba21f19" @@ -1618,28 +1629,28 @@ resolved "https://registry.yarnpkg.com/@istanbuljs/schema/-/schema-0.1.3.tgz#e45e384e4b8ec16bce2fd903af78450f6bf7ec98" integrity sha512-ZXRY4jNvVgSVQ8DL3LTcakaAtXwTVUxE81hslsyD2AtoXW/wVob10HkOJ1X/pAlcI7D+2YoZKg5do8G/w6RYgA== -"@jest/console@^28.1.0": - version "28.1.0" - resolved "https://registry.yarnpkg.com/@jest/console/-/console-28.1.0.tgz#db78222c3d3b0c1db82f1b9de51094c2aaff2176" - integrity sha512-tscn3dlJFGay47kb4qVruQg/XWlmvU0xp3EJOjzzY+sBaI+YgwKcvAmTcyYU7xEiLLIY5HCdWRooAL8dqkFlDA== +"@jest/console@^28.1.1": + version "28.1.1" + resolved "https://registry.yarnpkg.com/@jest/console/-/console-28.1.1.tgz#305f8ca50b6e70413839f54c0e002b60a0f2fd7d" + integrity sha512-0RiUocPVFEm3WRMOStIHbRWllG6iW6E3/gUPnf4lkrVFyXIIDeCe+vlKeYyFOMhB2EPE6FLFCNADSOOQMaqvyA== dependencies: - "@jest/types" "^28.1.0" + "@jest/types" "^28.1.1" "@types/node" "*" chalk "^4.0.0" - jest-message-util "^28.1.0" - jest-util "^28.1.0" + jest-message-util "^28.1.1" + jest-util "^28.1.1" slash "^3.0.0" -"@jest/core@^28.1.0": - version "28.1.0" - resolved "https://registry.yarnpkg.com/@jest/core/-/core-28.1.0.tgz#784a1e6ce5358b46fcbdcfbbd93b1b713ed4ea80" - integrity sha512-/2PTt0ywhjZ4NwNO4bUqD9IVJfmFVhVKGlhvSpmEfUCuxYf/3NHcKmRFI+I71lYzbTT3wMuYpETDCTHo81gC/g== +"@jest/core@^28.1.1": + version "28.1.1" + resolved "https://registry.yarnpkg.com/@jest/core/-/core-28.1.1.tgz#086830bec6267accf9af5ca76f794858e9f9f092" + integrity sha512-3pYsBoZZ42tXMdlcFeCc/0j9kOlK7MYuXs2B1QbvDgMoW1K9NJ4G/VYvIbMb26iqlkTfPHo7SC2JgjDOk/mxXw== dependencies: - "@jest/console" "^28.1.0" - "@jest/reporters" "^28.1.0" - "@jest/test-result" "^28.1.0" - "@jest/transform" "^28.1.0" - "@jest/types" "^28.1.0" + "@jest/console" "^28.1.1" + "@jest/reporters" "^28.1.1" + "@jest/test-result" "^28.1.1" + "@jest/transform" "^28.1.1" + "@jest/types" "^28.1.1" "@types/node" "*" ansi-escapes "^4.2.1" chalk "^4.0.0" @@ -1647,20 +1658,20 @@ exit "^0.1.2" graceful-fs "^4.2.9" jest-changed-files "^28.0.2" - jest-config "^28.1.0" - jest-haste-map "^28.1.0" - jest-message-util "^28.1.0" + jest-config "^28.1.1" + jest-haste-map "^28.1.1" + jest-message-util "^28.1.1" jest-regex-util "^28.0.2" - jest-resolve "^28.1.0" - jest-resolve-dependencies "^28.1.0" - jest-runner "^28.1.0" - jest-runtime "^28.1.0" - jest-snapshot "^28.1.0" - jest-util "^28.1.0" - jest-validate "^28.1.0" - jest-watcher "^28.1.0" + jest-resolve "^28.1.1" + jest-resolve-dependencies "^28.1.1" + jest-runner "^28.1.1" + jest-runtime "^28.1.1" + jest-snapshot "^28.1.1" + jest-util "^28.1.1" + jest-validate "^28.1.1" + jest-watcher "^28.1.1" micromatch "^4.0.4" - pretty-format "^28.1.0" + pretty-format "^28.1.1" rimraf "^3.0.0" slash "^3.0.0" strip-ansi "^6.0.0" @@ -1672,62 +1683,62 @@ dependencies: "@jest/types" "^27.5.1" -"@jest/environment@^28.1.0": - version "28.1.0" - resolved "https://registry.yarnpkg.com/@jest/environment/-/environment-28.1.0.tgz#dedf7d59ec341b9292fcf459fd0ed819eb2e228a" - integrity sha512-S44WGSxkRngzHslhV6RoAExekfF7Qhwa6R5+IYFa81mpcj0YgdBnRSmvHe3SNwOt64yXaE5GG8Y2xM28ii5ssA== +"@jest/environment@^28.1.1": + version "28.1.1" + resolved "https://registry.yarnpkg.com/@jest/environment/-/environment-28.1.1.tgz#c4cbf85283278d768f816ebd1a258ea6f9e39d4f" + integrity sha512-9auVQ2GzQ7nrU+lAr8KyY838YahElTX9HVjbQPPS2XjlxQ+na18G113OoBhyBGBtD6ZnO/SrUy5WR8EzOj1/Uw== dependencies: - "@jest/fake-timers" "^28.1.0" - "@jest/types" "^28.1.0" + "@jest/fake-timers" "^28.1.1" + "@jest/types" "^28.1.1" "@types/node" "*" - jest-mock "^28.1.0" + jest-mock "^28.1.1" -"@jest/expect-utils@^28.1.0": - version "28.1.0" - resolved "https://registry.yarnpkg.com/@jest/expect-utils/-/expect-utils-28.1.0.tgz#a5cde811195515a9809b96748ae8bcc331a3538a" - integrity sha512-5BrG48dpC0sB80wpeIX5FU6kolDJI4K0n5BM9a5V38MGx0pyRvUBSS0u2aNTdDzmOrCjhOg8pGs6a20ivYkdmw== +"@jest/expect-utils@^28.1.1": + version "28.1.1" + resolved "https://registry.yarnpkg.com/@jest/expect-utils/-/expect-utils-28.1.1.tgz#d84c346025b9f6f3886d02c48a6177e2b0360587" + integrity sha512-n/ghlvdhCdMI/hTcnn4qV57kQuV9OTsZzH1TTCVARANKhl6hXJqLKUkwX69ftMGpsbpt96SsDD8n8LD2d9+FRw== dependencies: jest-get-type "^28.0.2" -"@jest/expect@^28.1.0": - version "28.1.0" - resolved "https://registry.yarnpkg.com/@jest/expect/-/expect-28.1.0.tgz#2e5a31db692597070932366a1602b5157f0f217c" - integrity sha512-be9ETznPLaHOmeJqzYNIXv1ADEzENuQonIoobzThOYPuK/6GhrWNIJDVTgBLCrz3Am73PyEU2urQClZp0hLTtA== +"@jest/expect@^28.1.1": + version "28.1.1" + resolved "https://registry.yarnpkg.com/@jest/expect/-/expect-28.1.1.tgz#ea4fcc8504b45835029221c0dc357c622a761326" + integrity sha512-/+tQprrFoT6lfkMj4mW/mUIfAmmk/+iQPmg7mLDIFOf2lyf7EBHaS+x3RbeR0VZVMe55IvX7QRoT/2aK3AuUXg== dependencies: - expect "^28.1.0" - jest-snapshot "^28.1.0" + expect "^28.1.1" + jest-snapshot "^28.1.1" -"@jest/fake-timers@^28.1.0": - version "28.1.0" - resolved "https://registry.yarnpkg.com/@jest/fake-timers/-/fake-timers-28.1.0.tgz#ea77878aabd5c5d50e1fc53e76d3226101e33064" - integrity sha512-Xqsf/6VLeAAq78+GNPzI7FZQRf5cCHj1qgQxCjws9n8rKw8r1UYoeaALwBvyuzOkpU3c1I6emeMySPa96rxtIg== +"@jest/fake-timers@^28.1.1": + version "28.1.1" + resolved "https://registry.yarnpkg.com/@jest/fake-timers/-/fake-timers-28.1.1.tgz#47ce33296ab9d680c76076d51ddbe65ceb3337f1" + integrity sha512-BY/3+TyLs5+q87rGWrGUY5f8e8uC3LsVHS9Diz8+FV3ARXL4sNnkLlIB8dvDvRrp+LUCGM+DLqlsYubizGUjIA== dependencies: - "@jest/types" "^28.1.0" + "@jest/types" "^28.1.1" "@sinonjs/fake-timers" "^9.1.1" "@types/node" "*" - jest-message-util "^28.1.0" - jest-mock "^28.1.0" - jest-util "^28.1.0" + jest-message-util "^28.1.1" + jest-mock "^28.1.1" + jest-util "^28.1.1" -"@jest/globals@^28.1.0": - version "28.1.0" - resolved "https://registry.yarnpkg.com/@jest/globals/-/globals-28.1.0.tgz#a4427d2eb11763002ff58e24de56b84ba79eb793" - integrity sha512-3m7sTg52OTQR6dPhsEQSxAvU+LOBbMivZBwOvKEZ+Rb+GyxVnXi9HKgOTYkx/S99T8yvh17U4tNNJPIEQmtwYw== +"@jest/globals@^28.1.1": + version "28.1.1" + resolved "https://registry.yarnpkg.com/@jest/globals/-/globals-28.1.1.tgz#c0a7977f85e26279cc090d9adcdf82b8a34c4061" + integrity sha512-dEgl/6v7ToB4vXItdvcltJBgny0xBE6xy6IYQrPJAJggdEinGxCDMivNv7sFzPcTITGquXD6UJwYxfJ/5ZwDSg== dependencies: - "@jest/environment" "^28.1.0" - "@jest/expect" "^28.1.0" - "@jest/types" "^28.1.0" + "@jest/environment" "^28.1.1" + "@jest/expect" "^28.1.1" + "@jest/types" "^28.1.1" -"@jest/reporters@^28.1.0": - version "28.1.0" - resolved "https://registry.yarnpkg.com/@jest/reporters/-/reporters-28.1.0.tgz#5183a28b9b593b6000fa9b89b031c7216b58a9a0" - integrity sha512-qxbFfqap/5QlSpIizH9c/bFCDKsQlM4uAKSOvZrP+nIdrjqre3FmKzpTtYyhsaVcOSNK7TTt2kjm+4BJIjysFA== +"@jest/reporters@^28.1.1": + version "28.1.1" + resolved "https://registry.yarnpkg.com/@jest/reporters/-/reporters-28.1.1.tgz#9389f4bb3cce4d9b586f6195f83c79cd2a1c8662" + integrity sha512-597Zj4D4d88sZrzM4atEGLuO7SdA/YrOv9SRXHXRNC+/FwPCWxZhBAEzhXoiJzfRwn8zes/EjS8Lo6DouGN5Gg== dependencies: "@bcoe/v8-coverage" "^0.2.3" - "@jest/console" "^28.1.0" - "@jest/test-result" "^28.1.0" - "@jest/transform" "^28.1.0" - "@jest/types" "^28.1.0" + "@jest/console" "^28.1.1" + "@jest/test-result" "^28.1.1" + "@jest/transform" "^28.1.1" + "@jest/types" "^28.1.1" "@jridgewell/trace-mapping" "^0.3.7" "@types/node" "*" chalk "^4.0.0" @@ -1740,8 +1751,9 @@ istanbul-lib-report "^3.0.0" istanbul-lib-source-maps "^4.0.0" istanbul-reports "^3.1.3" - jest-util "^28.1.0" - jest-worker "^28.1.0" + jest-message-util "^28.1.1" + jest-util "^28.1.1" + jest-worker "^28.1.1" slash "^3.0.0" string-length "^4.0.1" strip-ansi "^6.0.0" @@ -1764,42 +1776,42 @@ callsites "^3.0.0" graceful-fs "^4.2.9" -"@jest/test-result@^28.1.0": - version "28.1.0" - resolved "https://registry.yarnpkg.com/@jest/test-result/-/test-result-28.1.0.tgz#fd149dee123510dd2fcadbbf5f0020f98ad7f12c" - integrity sha512-sBBFIyoPzrZho3N+80P35A5oAkSKlGfsEFfXFWuPGBsW40UAjCkGakZhn4UQK4iQlW2vgCDMRDOob9FGKV8YoQ== +"@jest/test-result@^28.1.1": + version "28.1.1" + resolved "https://registry.yarnpkg.com/@jest/test-result/-/test-result-28.1.1.tgz#c6f18d1bbb01aa88925dd687872a75f8414b317a" + integrity sha512-hPmkugBktqL6rRzwWAtp1JtYT4VHwv8OQ+9lE5Gymj6dHzubI/oJHMUpPOt8NrdVWSrz9S7bHjJUmv2ggFoUNQ== dependencies: - "@jest/console" "^28.1.0" - "@jest/types" "^28.1.0" + "@jest/console" "^28.1.1" + "@jest/types" "^28.1.1" "@types/istanbul-lib-coverage" "^2.0.0" collect-v8-coverage "^1.0.0" -"@jest/test-sequencer@^28.1.0": - version "28.1.0" - resolved "https://registry.yarnpkg.com/@jest/test-sequencer/-/test-sequencer-28.1.0.tgz#ce7294bbe986415b9a30e218c7e705e6ebf2cdf2" - integrity sha512-tZCEiVWlWNTs/2iK9yi6o3AlMfbbYgV4uuZInSVdzZ7ftpHZhCMuhvk2HLYhCZzLgPFQ9MnM1YaxMnh3TILFiQ== +"@jest/test-sequencer@^28.1.1": + version "28.1.1" + resolved "https://registry.yarnpkg.com/@jest/test-sequencer/-/test-sequencer-28.1.1.tgz#f594ee2331df75000afe0d1ae3237630ecec732e" + integrity sha512-nuL+dNSVMcWB7OOtgb0EGH5AjO4UBCt68SLP08rwmC+iRhyuJWS9MtZ/MpipxFwKAlHFftbMsydXqWre8B0+XA== dependencies: - "@jest/test-result" "^28.1.0" + "@jest/test-result" "^28.1.1" graceful-fs "^4.2.9" - jest-haste-map "^28.1.0" + jest-haste-map "^28.1.1" slash "^3.0.0" -"@jest/transform@^28.1.0": - version "28.1.0" - resolved "https://registry.yarnpkg.com/@jest/transform/-/transform-28.1.0.tgz#224a3c9ba4cc98e2ff996c0a89a2d59db15c74ce" - integrity sha512-omy2xe5WxlAfqmsTjTPxw+iXRTRnf+NtX0ToG+4S0tABeb4KsKmPUHq5UBuwunHg3tJRwgEQhEp0M/8oiatLEA== +"@jest/transform@^28.1.1": + version "28.1.1" + resolved "https://registry.yarnpkg.com/@jest/transform/-/transform-28.1.1.tgz#83541f2a3f612077c8501f49cc4e205d4e4a6b27" + integrity sha512-PkfaTUuvjUarl1EDr5ZQcCA++oXkFCP9QFUkG0yVKVmNObjhrqDy0kbMpMebfHWm3CCDHjYNem9eUSH8suVNHQ== dependencies: "@babel/core" "^7.11.6" - "@jest/types" "^28.1.0" + "@jest/types" "^28.1.1" "@jridgewell/trace-mapping" "^0.3.7" babel-plugin-istanbul "^6.1.1" chalk "^4.0.0" convert-source-map "^1.4.0" fast-json-stable-stringify "^2.0.0" graceful-fs "^4.2.9" - jest-haste-map "^28.1.0" + jest-haste-map "^28.1.1" jest-regex-util "^28.0.2" - jest-util "^28.1.0" + jest-util "^28.1.1" micromatch "^4.0.4" pirates "^4.0.4" slash "^3.0.0" @@ -1816,10 +1828,10 @@ "@types/yargs" "^16.0.0" chalk "^4.0.0" -"@jest/types@^28.1.0": - version "28.1.0" - resolved "https://registry.yarnpkg.com/@jest/types/-/types-28.1.0.tgz#508327a89976cbf9bd3e1cc74641a29fd7dfd519" - integrity sha512-xmEggMPr317MIOjjDoZ4ejCSr9Lpbt/u34+dvc99t7DS8YirW5rwZEhzKPC2BMUFkUhI48qs6qLUSGw5FuL0GA== +"@jest/types@^28.1.1": + version "28.1.1" + resolved "https://registry.yarnpkg.com/@jest/types/-/types-28.1.1.tgz#d059bbc80e6da6eda9f081f293299348bd78ee0b" + integrity sha512-vRXVqSg1VhDnB8bWcmvLzmg0Bt9CRKVgHPXqYwvWMX3TvAjeO+nRuK6+VdTKCtWOvYlmkF/HqNAL/z+N3B53Kw== dependencies: "@jest/schemas" "^28.0.2" "@types/istanbul-lib-coverage" "^2.0.0" @@ -1855,6 +1867,14 @@ resolved "https://registry.yarnpkg.com/@jridgewell/set-array/-/set-array-1.1.1.tgz#36a6acc93987adcf0ba50c66908bd0b70de8afea" integrity sha512-Ct5MqZkLGEXTVmQYbGtx9SVqD2fqwvdubdps5D3djjAkgkKwT918VNOz65pEHFaYTeWcukmJmH5SwsA9Tn2ObQ== +"@jridgewell/source-map@^0.3.2": + version "0.3.2" + resolved "https://registry.yarnpkg.com/@jridgewell/source-map/-/source-map-0.3.2.tgz#f45351aaed4527a298512ec72f81040c998580fb" + integrity sha512-m7O9o2uR8k2ObDysZYzdfhb08VuEml5oWGiosa1VdaPZ/A6QyPkAJuwN0Q1lhULOf6B7MtQmHENS743hWtCrgw== + dependencies: + "@jridgewell/gen-mapping" "^0.3.0" + "@jridgewell/trace-mapping" "^0.3.9" + "@jridgewell/sourcemap-codec@^1.4.10": version "1.4.13" resolved "https://registry.yarnpkg.com/@jridgewell/sourcemap-codec/-/sourcemap-codec-1.4.13.tgz#b6461fb0c2964356c469e115f504c95ad97ab88c" @@ -1873,39 +1893,39 @@ resolved "https://registry.yarnpkg.com/@leichtgewicht/ip-codec/-/ip-codec-2.0.4.tgz#b2ac626d6cb9c8718ab459166d4bb405b8ffa78b" integrity sha512-Hcv+nVC0kZnQ3tD9GVu5xSMR4VVYOteQIr/hwFPVEvPdlXqgGEuRjiheChHgdM+JyqdgNcmzZOX/tnl0JOiI7A== -"@lerna/add@5.0.0": - version "5.0.0" - resolved "https://registry.yarnpkg.com/@lerna/add/-/add-5.0.0.tgz#0545e2eef157c142d82ba765467c27b36fe53ce8" - integrity sha512-KdIOQL+88iHU9zuAU8Be1AL4cOVmm77nlckylsNaVVTiomNipr/h7lStiBO52BoMkwKzNwOH6He5HGY0Yo7s2w== - dependencies: - "@lerna/bootstrap" "5.0.0" - "@lerna/command" "5.0.0" - "@lerna/filter-options" "5.0.0" - "@lerna/npm-conf" "5.0.0" - "@lerna/validation-error" "5.0.0" +"@lerna/add@5.1.1": + version "5.1.1" + resolved "https://registry.yarnpkg.com/@lerna/add/-/add-5.1.1.tgz#dda0e188b787263517239ec6c42e681b07c43d5c" + integrity sha512-0tUT/ohLLxpz1TYuRBXdsYDIZAgAHPpoF+MOcscADdH9+nIzA+TLr6B4fD/D/7i+IrspXkZEo29+yq31HpPHTQ== + dependencies: + "@lerna/bootstrap" "5.1.1" + "@lerna/command" "5.1.1" + "@lerna/filter-options" "5.1.1" + "@lerna/npm-conf" "5.1.1" + "@lerna/validation-error" "5.1.1" dedent "^0.7.0" npm-package-arg "^8.1.0" p-map "^4.0.0" pacote "^13.4.1" semver "^7.3.4" -"@lerna/bootstrap@5.0.0": - version "5.0.0" - resolved "https://registry.yarnpkg.com/@lerna/bootstrap/-/bootstrap-5.0.0.tgz#624b67a4631c7455b98cfed4dbb2e38b27025a7a" - integrity sha512-2m1BxKbYwDABy+uE/Da3EQM61R58bI3YQ0o1rsFQq1u0ltL9CJxw1o0lMg84hwMsBb4D+kLIXLqetYlLVgbr0Q== - dependencies: - "@lerna/command" "5.0.0" - "@lerna/filter-options" "5.0.0" - "@lerna/has-npm-version" "5.0.0" - "@lerna/npm-install" "5.0.0" - "@lerna/package-graph" "5.0.0" - "@lerna/pulse-till-done" "5.0.0" - "@lerna/rimraf-dir" "5.0.0" - "@lerna/run-lifecycle" "5.0.0" - "@lerna/run-topologically" "5.0.0" - "@lerna/symlink-binary" "5.0.0" - "@lerna/symlink-dependencies" "5.0.0" - "@lerna/validation-error" "5.0.0" +"@lerna/bootstrap@5.1.1": + version "5.1.1" + resolved "https://registry.yarnpkg.com/@lerna/bootstrap/-/bootstrap-5.1.1.tgz#92be03fe97c8457ac0f0d031be171ca438179bf8" + integrity sha512-V9SjAsQtmDJExQPwVlVVnTDHfA1xW0zThjbvFZ25D/HpyQ+P1HttYUcE7Xsm0enU7xRKy+T2SXzQauIEWL7Nzg== + dependencies: + "@lerna/command" "5.1.1" + "@lerna/filter-options" "5.1.1" + "@lerna/has-npm-version" "5.1.1" + "@lerna/npm-install" "5.1.1" + "@lerna/package-graph" "5.1.1" + "@lerna/pulse-till-done" "5.1.1" + "@lerna/rimraf-dir" "5.1.1" + "@lerna/run-lifecycle" "5.1.1" + "@lerna/run-topologically" "5.1.1" + "@lerna/symlink-binary" "5.1.1" + "@lerna/symlink-dependencies" "5.1.1" + "@lerna/validation-error" "5.1.1" "@npmcli/arborist" "5.2.0" dedent "^0.7.0" get-port "^5.1.1" @@ -1917,100 +1937,100 @@ p-waterfall "^2.1.1" semver "^7.3.4" -"@lerna/changed@5.0.0": - version "5.0.0" - resolved "https://registry.yarnpkg.com/@lerna/changed/-/changed-5.0.0.tgz#fb3cdd5f281683a461c3099cbcf0978e23b33140" - integrity sha512-A24MHipPGODmzQBH1uIMPPUUOc1Zm7Qe/eSYzm52bFHtVxWH0nIVXfunadoMX32NhzKQH3Sw8X2rWHPQSRoUvA== +"@lerna/changed@5.1.1": + version "5.1.1" + resolved "https://registry.yarnpkg.com/@lerna/changed/-/changed-5.1.1.tgz#e641120ca81d316c5d780de45a82c579828531a1" + integrity sha512-YUSAdwwL66b7KGDo5oPsRSDofv+UczA/FvjYlW+s1PhhHoKbFR4/os5Rm0hlRJcG86kKzB0X1jeFBM8/GtMkVg== dependencies: - "@lerna/collect-updates" "5.0.0" - "@lerna/command" "5.0.0" - "@lerna/listable" "5.0.0" - "@lerna/output" "5.0.0" + "@lerna/collect-updates" "5.1.1" + "@lerna/command" "5.1.1" + "@lerna/listable" "5.1.1" + "@lerna/output" "5.1.1" -"@lerna/check-working-tree@5.0.0": - version "5.0.0" - resolved "https://registry.yarnpkg.com/@lerna/check-working-tree/-/check-working-tree-5.0.0.tgz#e7b653b78c3bb96db7a00f6a74018e2bb88ec088" - integrity sha512-PnUMdpT2qS4o+vs+7l5fFIizstGdqSkhLG+Z9ZiY5OMtnGd+pmAFQFlbLSZSmdvQSOSobl9fhB1St8qhPD60xQ== +"@lerna/check-working-tree@5.1.1": + version "5.1.1" + resolved "https://registry.yarnpkg.com/@lerna/check-working-tree/-/check-working-tree-5.1.1.tgz#ae839904af0bc09475543ab781b529442a7de744" + integrity sha512-rGXNuPIUjPuzwIOYDLio4Il0tLiIqDpd981peKnuCjbocUGJaXncfUf1isazl3LNojsb5dKBoG/O3eJhGoaO4w== dependencies: - "@lerna/collect-uncommitted" "5.0.0" - "@lerna/describe-ref" "5.0.0" - "@lerna/validation-error" "5.0.0" + "@lerna/collect-uncommitted" "5.1.1" + "@lerna/describe-ref" "5.1.1" + "@lerna/validation-error" "5.1.1" -"@lerna/child-process@5.0.0": - version "5.0.0" - resolved "https://registry.yarnpkg.com/@lerna/child-process/-/child-process-5.0.0.tgz#1c7663d2910431f6c25543fd53998ae95b2dac19" - integrity sha512-cFVNkedrlU8XTt15EvUtQ84hqtV4oToQW/elKNv//mhCz06HY8Y+Ia6XevK2zrIhZjS6DT576F/7SmTk3vnpmg== +"@lerna/child-process@5.1.1": + version "5.1.1" + resolved "https://registry.yarnpkg.com/@lerna/child-process/-/child-process-5.1.1.tgz#a22764ab030fb0121f244f14e7c5ed62d5163fc1" + integrity sha512-hPBDbqZws2d3GehCuYZ0vZwd/SRthwDIPWGkd74xevdoLxka3Y/y5IdogZz3V9cc6p6bdP6ZHbBSumEX+VIhxA== dependencies: chalk "^4.1.0" execa "^5.0.0" strong-log-transformer "^2.1.0" -"@lerna/clean@5.0.0": - version "5.0.0" - resolved "https://registry.yarnpkg.com/@lerna/clean/-/clean-5.0.0.tgz#2b5cf202ab3eca18a075b292c55e6641d18b1b8f" - integrity sha512-7B+0Nx6MEPmCfnEa1JFyZwJsC7qlGrikWXyLglLb/wcbapYVsuDauOl9AT1iOFoXKw82P77HWYUKWeD9DQgw/w== - dependencies: - "@lerna/command" "5.0.0" - "@lerna/filter-options" "5.0.0" - "@lerna/prompt" "5.0.0" - "@lerna/pulse-till-done" "5.0.0" - "@lerna/rimraf-dir" "5.0.0" +"@lerna/clean@5.1.1": + version "5.1.1" + resolved "https://registry.yarnpkg.com/@lerna/clean/-/clean-5.1.1.tgz#194b53f0ea681a3e69e75722c665f60ef6fc53ac" + integrity sha512-3hI6CG/pxVmbU1xZoDLtORTivAky/AdYt5biafxXGUbcMBbHekYkSf+bUojVkSLZ4hn43aiLzbMCKhHYd+vdIA== + dependencies: + "@lerna/command" "5.1.1" + "@lerna/filter-options" "5.1.1" + "@lerna/prompt" "5.1.1" + "@lerna/pulse-till-done" "5.1.1" + "@lerna/rimraf-dir" "5.1.1" p-map "^4.0.0" p-map-series "^2.1.0" p-waterfall "^2.1.1" -"@lerna/cli@5.0.0": - version "5.0.0" - resolved "https://registry.yarnpkg.com/@lerna/cli/-/cli-5.0.0.tgz#f440f6664aa6c22bb58e69aacfde655c831de2f9" - integrity sha512-g8Nifko8XNySOl8u2molSHVl+fk/E1e5FSn/W2ekeijmc3ezktp+xbPWofNq71N/d297+KPQpLBfwzXSo9ufIQ== +"@lerna/cli@5.1.1": + version "5.1.1" + resolved "https://registry.yarnpkg.com/@lerna/cli/-/cli-5.1.1.tgz#21b0290583d765f7b9d33815bb74eb2603e4a55e" + integrity sha512-0smc8pA12D0DUhXI32DES1F/TRleLyN+xkqOqvKGdbD2IA33O1eYVI93vAOmTmEc3ATqKiBwvxoZulqS/ybMFg== dependencies: - "@lerna/global-options" "5.0.0" + "@lerna/global-options" "5.1.1" dedent "^0.7.0" npmlog "^4.1.2" yargs "^16.2.0" -"@lerna/collect-uncommitted@5.0.0": - version "5.0.0" - resolved "https://registry.yarnpkg.com/@lerna/collect-uncommitted/-/collect-uncommitted-5.0.0.tgz#2843f98995c8bcc1d783d1d9739122c79378f3c5" - integrity sha512-mga/2S9rK0TP5UCulWiCTrC/uKaiIlOro1n8R3oCw6eRw9eupCSRx5zGI7pdh8CPD82MDL7w0a6OTep3WBSBVA== +"@lerna/collect-uncommitted@5.1.1": + version "5.1.1" + resolved "https://registry.yarnpkg.com/@lerna/collect-uncommitted/-/collect-uncommitted-5.1.1.tgz#23fef743d20bdb5439871080dee09b1ee7d2ef06" + integrity sha512-u6cYLZhBvZEwoFbYMDwlB3ZB0RJ7ny5fXOCW3SkP0HIGKwzAciL8SPZ++9bsc4+ud6ds60FRyHH79UQLtEiPLg== dependencies: - "@lerna/child-process" "5.0.0" + "@lerna/child-process" "5.1.1" chalk "^4.1.0" npmlog "^4.1.2" -"@lerna/collect-updates@5.0.0": - version "5.0.0" - resolved "https://registry.yarnpkg.com/@lerna/collect-updates/-/collect-updates-5.0.0.tgz#cce16b9e8136e1e7bc33fe0fb12b283e538fa658" - integrity sha512-X82i8SVgBXLCk8vbKWfQPRLTAXROCANL8Z/bU1l6n7yycsHKdjrrlNi1+KprFdfRsMvSm10R4qPNcl9jgsp/IA== +"@lerna/collect-updates@5.1.1": + version "5.1.1" + resolved "https://registry.yarnpkg.com/@lerna/collect-updates/-/collect-updates-5.1.1.tgz#084c5a6fc68939f7399dc1693c8dc8fe817622b1" + integrity sha512-JBxE5vP9HT2EXd/eggu9nmLSAgSnYFXviz25XjaDqSqljnEW0u1NRAcsETIWAllJ0TaTctsqA+jRDXLWhfEtfQ== dependencies: - "@lerna/child-process" "5.0.0" - "@lerna/describe-ref" "5.0.0" + "@lerna/child-process" "5.1.1" + "@lerna/describe-ref" "5.1.1" minimatch "^3.0.4" npmlog "^4.1.2" slash "^3.0.0" -"@lerna/command@5.0.0": - version "5.0.0" - resolved "https://registry.yarnpkg.com/@lerna/command/-/command-5.0.0.tgz#cdc9f32a6b1c7153fe7150d642d2a420a3d0797d" - integrity sha512-j7/apU5d/nhSc1qIZgcV03KyO5jz3y7cwSum3IuK8/XF6rKwt3FVnbue1V3l9sJ6IRJjsRGKyViB1IdP5nSX4Q== - dependencies: - "@lerna/child-process" "5.0.0" - "@lerna/package-graph" "5.0.0" - "@lerna/project" "5.0.0" - "@lerna/validation-error" "5.0.0" - "@lerna/write-log-file" "5.0.0" +"@lerna/command@5.1.1": + version "5.1.1" + resolved "https://registry.yarnpkg.com/@lerna/command/-/command-5.1.1.tgz#a71fd0e4122f96f735531da03403faad3e3a5bd2" + integrity sha512-q59dISdpE6a4/iQn6DGhqVefqkgs2gRcf7ehfJ6Yg41CugqAS0n6CdeTboqFIf2/O9naPKd71t0QBd3/4HXd4A== + dependencies: + "@lerna/child-process" "5.1.1" + "@lerna/package-graph" "5.1.1" + "@lerna/project" "5.1.1" + "@lerna/validation-error" "5.1.1" + "@lerna/write-log-file" "5.1.1" clone-deep "^4.0.1" dedent "^0.7.0" execa "^5.0.0" is-ci "^2.0.0" npmlog "^4.1.2" -"@lerna/conventional-commits@5.0.0": - version "5.0.0" - resolved "https://registry.yarnpkg.com/@lerna/conventional-commits/-/conventional-commits-5.0.0.tgz#7f9c16fda074c9ed897cb695f5ae23678dd441eb" - integrity sha512-tUCRTAycDCtSlCEI0hublq4uKHeV0UHpwIb3Fdt6iv2AoTSPBSX/Dwu/6VqguysOSEkkR4M2JCOLvJCl4IMxwg== +"@lerna/conventional-commits@5.1.1": + version "5.1.1" + resolved "https://registry.yarnpkg.com/@lerna/conventional-commits/-/conventional-commits-5.1.1.tgz#a853ae2f5ef50b95757bf3b3ed26acec8feac0aa" + integrity sha512-VL2ppoKA5XKrCwF6U7nhnGWM9PNFrXWjetC7Okd7sjpDt33GaTsida1n7owXMTJrVolHZweHHWypROzy+LUTtw== dependencies: - "@lerna/validation-error" "5.0.0" + "@lerna/validation-error" "5.1.1" conventional-changelog-angular "^5.0.12" conventional-changelog-core "^4.2.2" conventional-recommended-bump "^6.1.0" @@ -2022,24 +2042,24 @@ pify "^5.0.0" semver "^7.3.4" -"@lerna/create-symlink@5.0.0": - version "5.0.0" - resolved "https://registry.yarnpkg.com/@lerna/create-symlink/-/create-symlink-5.0.0.tgz#eccef7f89fdc4d7cd904694d9e2eb0b582073b5e" - integrity sha512-nHYNacrh15Y0yEofVlUVu9dhf4JjIn9hY7v7rOUXzUeQ91iXY5Q3PVHkBeRUigyT5CWP5qozZwraCMwp+lDWYg== +"@lerna/create-symlink@5.1.1": + version "5.1.1" + resolved "https://registry.yarnpkg.com/@lerna/create-symlink/-/create-symlink-5.1.1.tgz#42263fdfcd65ed51e990a6fc3eb695729ebbe7e0" + integrity sha512-QyLlXDx0AuN/INXhJxfOHX+a0RaJwCuKbcWv7rqXoVSofDYBYE5EXEx2kn1d4BZg2ozQtfqhNzzKKHU2IyPAKw== dependencies: cmd-shim "^4.1.0" fs-extra "^9.1.0" npmlog "^4.1.2" -"@lerna/create@5.0.0": - version "5.0.0" - resolved "https://registry.yarnpkg.com/@lerna/create/-/create-5.0.0.tgz#4aac3d1f2c1f6d7fadde49d3663b318fcdd39b06" - integrity sha512-sdFTVTLOVuhHpzIYhFAwK0Ry3p4d7uMe9ZG/Ii128/pB9kEEfCth+1WBq6mBpYZ5mOLLgxJbWalbiJFl0toQRw== +"@lerna/create@5.1.1": + version "5.1.1" + resolved "https://registry.yarnpkg.com/@lerna/create/-/create-5.1.1.tgz#5139c6d57a63818adc9523442d9d3388dc3b7274" + integrity sha512-nGtFCd16xswCupIxP+3ecHeU3O2+hkh0ghYMBZZWxC1mU/LFWKNa5Ofc2tWFiXhFqADgLCxaBuqaxW/sYq4JAA== dependencies: - "@lerna/child-process" "5.0.0" - "@lerna/command" "5.0.0" - "@lerna/npm-conf" "5.0.0" - "@lerna/validation-error" "5.0.0" + "@lerna/child-process" "5.1.1" + "@lerna/command" "5.1.1" + "@lerna/npm-conf" "5.1.1" + "@lerna/validation-error" "5.1.1" dedent "^0.7.0" fs-extra "^9.1.0" globby "^11.0.2" @@ -2055,217 +2075,217 @@ whatwg-url "^8.4.0" yargs-parser "20.2.4" -"@lerna/describe-ref@5.0.0": - version "5.0.0" - resolved "https://registry.yarnpkg.com/@lerna/describe-ref/-/describe-ref-5.0.0.tgz#f0676843642e8880133783a9f059e6cb4c027fe1" - integrity sha512-iLvMHp3nl4wcMR3/lVkz0ng7pAHfLQ7yvz2HsYBq7wllCcEzpchzPgyVzyvbpJ+Ke/MKjQTsrHE/yOGOH67GVw== +"@lerna/describe-ref@5.1.1": + version "5.1.1" + resolved "https://registry.yarnpkg.com/@lerna/describe-ref/-/describe-ref-5.1.1.tgz#70701bf98a024077a97c19cfd97b81baad1a841f" + integrity sha512-bxNZiH2JK4uCnuUmJUcLdZFAR8NEXPCf3oxHpGzSGjr1gSE43ZPsZs5Hz9/46CEvSA+z4p1MeQs2KRTR1Wa0oQ== dependencies: - "@lerna/child-process" "5.0.0" + "@lerna/child-process" "5.1.1" npmlog "^4.1.2" -"@lerna/diff@5.0.0": - version "5.0.0" - resolved "https://registry.yarnpkg.com/@lerna/diff/-/diff-5.0.0.tgz#844333f5478fc4993c4389fee1e0cd8eff9114fe" - integrity sha512-S4XJ6i9oP77cSmJ3oRUJGMgrI+jOTmkYWur2nqgSdyJBE1J2eClgTJknb3WAHg2cHALT18WzFqNghFOGM+9dRA== +"@lerna/diff@5.1.1": + version "5.1.1" + resolved "https://registry.yarnpkg.com/@lerna/diff/-/diff-5.1.1.tgz#80eafe8131cf1b52537c871376d55b76e9eeb2cf" + integrity sha512-pwc5hAk6l3Z+nfpRLnijbTl5gN0hdCWM9YRWRxnjum05GoRwFveqMJRSeznDYl05JI7kYBtI/l3lj/5Hf1TzCw== dependencies: - "@lerna/child-process" "5.0.0" - "@lerna/command" "5.0.0" - "@lerna/validation-error" "5.0.0" + "@lerna/child-process" "5.1.1" + "@lerna/command" "5.1.1" + "@lerna/validation-error" "5.1.1" npmlog "^4.1.2" -"@lerna/exec@5.0.0": - version "5.0.0" - resolved "https://registry.yarnpkg.com/@lerna/exec/-/exec-5.0.0.tgz#a59dd094e456ea46cfa8f713da0ea3334a7ec9ac" - integrity sha512-g5i+2RclCGWLsl88m11j99YM2Gqnwa2lxZ5tDeqqWZFno6Dlvop17Yl6/MFH42EgM2DQHUUCammvcLIAJ2XwEA== - dependencies: - "@lerna/child-process" "5.0.0" - "@lerna/command" "5.0.0" - "@lerna/filter-options" "5.0.0" - "@lerna/profiler" "5.0.0" - "@lerna/run-topologically" "5.0.0" - "@lerna/validation-error" "5.0.0" +"@lerna/exec@5.1.1": + version "5.1.1" + resolved "https://registry.yarnpkg.com/@lerna/exec/-/exec-5.1.1.tgz#eec7dbe167803f8509bd239e2f9ed91841c017a8" + integrity sha512-kTKquC0BfFmxXKmkwCq2uYh2ZK0QRa7bQeIRJH8MON8T82D+mU9FHH8UUObx6Aa6sl9lwg04TVnEoUbOJjZxvg== + dependencies: + "@lerna/child-process" "5.1.1" + "@lerna/command" "5.1.1" + "@lerna/filter-options" "5.1.1" + "@lerna/profiler" "5.1.1" + "@lerna/run-topologically" "5.1.1" + "@lerna/validation-error" "5.1.1" p-map "^4.0.0" -"@lerna/filter-options@5.0.0": - version "5.0.0" - resolved "https://registry.yarnpkg.com/@lerna/filter-options/-/filter-options-5.0.0.tgz#1d2606e1d2ed106689b43cc5d41a77b239afb837" - integrity sha512-un73aYkXlzKlnDPx2AlqNW+ArCZ20XaX+Y6C0F+av9VZriiBsCgZTnflhih9fiSMnXjN5r9CA8YdWvZqa3oAcQ== +"@lerna/filter-options@5.1.1": + version "5.1.1" + resolved "https://registry.yarnpkg.com/@lerna/filter-options/-/filter-options-5.1.1.tgz#b96788c38a26d6f4c5c2987dd7bb39690ee46f24" + integrity sha512-yFidZ2dJF5CNjnGfXFfcvvfqE2z6hPAk5cxwukPPvoJrQ3O4ebymgGNlRSziCM/D7N+Xm9byj5P0ogaIHCZ9iw== dependencies: - "@lerna/collect-updates" "5.0.0" - "@lerna/filter-packages" "5.0.0" + "@lerna/collect-updates" "5.1.1" + "@lerna/filter-packages" "5.1.1" dedent "^0.7.0" npmlog "^4.1.2" -"@lerna/filter-packages@5.0.0": - version "5.0.0" - resolved "https://registry.yarnpkg.com/@lerna/filter-packages/-/filter-packages-5.0.0.tgz#9aae543ab5e45a1b0c3f7ad33e0686ceb8d92c88" - integrity sha512-+EIjVVaMPDZ05F/gZa+kcXjBOLXqEamcEIDr+2ZXRgJmnrLx9BBY1B7sBEFHg7JXbeOKS+fKtMGVveV0SzgH3Q== +"@lerna/filter-packages@5.1.1": + version "5.1.1" + resolved "https://registry.yarnpkg.com/@lerna/filter-packages/-/filter-packages-5.1.1.tgz#963ab75a162f6eae98908ac83335db8dfd6c9543" + integrity sha512-AekgZk72hPiOBg+xVx3OJK+6wdHINBJSkQxOQ9DjVzIAdXDkFREE6JvF6fmCzX0QbyFaqvTXJ+Yl9TXoav+R4g== dependencies: - "@lerna/validation-error" "5.0.0" + "@lerna/validation-error" "5.1.1" multimatch "^5.0.0" npmlog "^4.1.2" -"@lerna/get-npm-exec-opts@5.0.0": - version "5.0.0" - resolved "https://registry.yarnpkg.com/@lerna/get-npm-exec-opts/-/get-npm-exec-opts-5.0.0.tgz#25c1cd7d2b6c1fe903cd144d9f6e2d5cae47429b" - integrity sha512-ZOg3kc5FXYA1kVFD2hfJOl64hNASWD6panwD0HlyzXgfKKTDRm/P/qtAqS8WGCzQWgEdx4wvsDe/58Lzzh6QzQ== +"@lerna/get-npm-exec-opts@5.1.1": + version "5.1.1" + resolved "https://registry.yarnpkg.com/@lerna/get-npm-exec-opts/-/get-npm-exec-opts-5.1.1.tgz#c808151e4b02f79e09d960866d405c066aeabd12" + integrity sha512-c2DpM4ONDJ54AQ/caONF832APkDJf/VgRjlt9/fTNxn9CB4+bsB631MiV7F+qisHFk2KNAssuWn73B7rVkNDGQ== dependencies: npmlog "^4.1.2" -"@lerna/get-packed@5.0.0": - version "5.0.0" - resolved "https://registry.yarnpkg.com/@lerna/get-packed/-/get-packed-5.0.0.tgz#4de7f66184232c805dfca07b9a8c577f6ef02351" - integrity sha512-fks7Tg7DvcCZxRWPS3JAWVuLnwjPC/hLlNsdYmK9nN3+RtPhmYQgBjLSONcENw1E46t4Aph72lA9nLcYBLksqw== +"@lerna/get-packed@5.1.1": + version "5.1.1" + resolved "https://registry.yarnpkg.com/@lerna/get-packed/-/get-packed-5.1.1.tgz#55c4c0baceca80ca5db78b4e980146079556c020" + integrity sha512-QWeOAoB5GGWnDkXtIcme8X1bHhkxOXw42UNp4h+wpXc8JzKiBdWcUVcLhKvS4fCmsRtq202UB6hPR+lYvCDz8w== dependencies: fs-extra "^9.1.0" ssri "^8.0.1" tar "^6.1.0" -"@lerna/github-client@5.0.0": - version "5.0.0" - resolved "https://registry.yarnpkg.com/@lerna/github-client/-/github-client-5.0.0.tgz#65c984a393b1cbe35c2a707059c645bb9a03395e" - integrity sha512-NoEyRkQ8XgBnrjRfC9ph1npfg1/4OdYG+r8lG/1WkJbdt1Wlym4VNZU2BYPMWwSQYMJuppoEr0LL2uuVcS4ZUw== +"@lerna/github-client@5.1.1": + version "5.1.1" + resolved "https://registry.yarnpkg.com/@lerna/github-client/-/github-client-5.1.1.tgz#db40150ddb296b54fa0af5f369e51f68d8e98e47" + integrity sha512-1kU/S9B/AleUetbRFQr+8xQNVXsOQp4ya/L2R7/3ALRmWfCDAtAKzGdtn0YtcPGEvWPb0xNgx9TeGQOj5nwDjw== dependencies: - "@lerna/child-process" "5.0.0" + "@lerna/child-process" "5.1.1" "@octokit/plugin-enterprise-rest" "^6.0.1" "@octokit/rest" "^18.1.0" git-url-parse "^11.4.4" npmlog "^4.1.2" -"@lerna/gitlab-client@5.0.0": - version "5.0.0" - resolved "https://registry.yarnpkg.com/@lerna/gitlab-client/-/gitlab-client-5.0.0.tgz#c4e3d16566a3b07908ee604ce681a09c418481de" - integrity sha512-WREAT7qzta9hxNxktTX0x1/sEMpBP+4Gc00QSJYXt+ZzxY0t5RUx/ZK5pQl+IDhtkajrvXT6fSfZjMxxyE8hhQ== +"@lerna/gitlab-client@5.1.1": + version "5.1.1" + resolved "https://registry.yarnpkg.com/@lerna/gitlab-client/-/gitlab-client-5.1.1.tgz#0db3a36c087b2a7fe3dd130e5eb8cce37f0514ff" + integrity sha512-tuy81UW2JhG/wnjiTV20kI8q3RlCHkOrYyiynnd4RPOX5i6DwG3/BGwt5FJ2avFvi9+AkalU1vIKPSqwwj9xTA== dependencies: node-fetch "^2.6.1" npmlog "^4.1.2" whatwg-url "^8.4.0" -"@lerna/global-options@5.0.0": - version "5.0.0" - resolved "https://registry.yarnpkg.com/@lerna/global-options/-/global-options-5.0.0.tgz#02505c9e468188e3a254c262d58739092de93d8d" - integrity sha512-PZYy/3mTZwtA9lNmHHRCc/Ty1W20qGJ/BdDIo4bw/Bk0AOcoBCLT9b3Mjijkl4AbC9+eSGk3flUYapCGVuS32Q== +"@lerna/global-options@5.1.1": + version "5.1.1" + resolved "https://registry.yarnpkg.com/@lerna/global-options/-/global-options-5.1.1.tgz#0bddf25989c314c5f9c1639f64b306946f6692aa" + integrity sha512-jKLqwiS3EwNbmMu5HbWciModK6/5FyxeSwENVIqPLplWIkAMbSNWjXa9BxNDzvsSU0G6TPpQmfgZ3ZS1bMamyA== -"@lerna/has-npm-version@5.0.0": - version "5.0.0" - resolved "https://registry.yarnpkg.com/@lerna/has-npm-version/-/has-npm-version-5.0.0.tgz#ed62c6ef857f068209663aae9f156f06a93dc1bd" - integrity sha512-zJPgcml86nhJFJTpT+kjkcafuCFvK7PSq3oDC2KJxwB1bhlYwy+SKtAEypHSsHQ2DwP0YgPITcy1pvtHkie1SA== +"@lerna/has-npm-version@5.1.1": + version "5.1.1" + resolved "https://registry.yarnpkg.com/@lerna/has-npm-version/-/has-npm-version-5.1.1.tgz#361d0673817d44b961d68d6d4be8233b667ae82b" + integrity sha512-MkDhYbdNugXUE7bEY8j2DGE1RUg/SJR613b1HPUTdEWpPg13PupsTKqiKOzoURAzUWN6tZoOR7OAxbvR3w8jnw== dependencies: - "@lerna/child-process" "5.0.0" + "@lerna/child-process" "5.1.1" semver "^7.3.4" -"@lerna/import@5.0.0": - version "5.0.0" - resolved "https://registry.yarnpkg.com/@lerna/import/-/import-5.0.0.tgz#11cd83ef0fe854c512146fd4165f33519364b97a" - integrity sha512-cD+Is7eV/I+ZU0Wlg+yAgKaZbOvfzA7kBj2Qu1HtxeLhc7joTR8PFW1gNjEsvrWOTiaHAtObbo1A+MKYQ/T12g== - dependencies: - "@lerna/child-process" "5.0.0" - "@lerna/command" "5.0.0" - "@lerna/prompt" "5.0.0" - "@lerna/pulse-till-done" "5.0.0" - "@lerna/validation-error" "5.0.0" +"@lerna/import@5.1.1": + version "5.1.1" + resolved "https://registry.yarnpkg.com/@lerna/import/-/import-5.1.1.tgz#4e09d2cddc17e525826c8464f79d12274308ac3d" + integrity sha512-VUgZn7QdsAYy8Joe6ZT8hKANxizzU0aUH93Pfg2YfjohxvyTlmx5TCSgnZ39P2jwmL2hHyI+Bs3t+9NOYPfoWg== + dependencies: + "@lerna/child-process" "5.1.1" + "@lerna/command" "5.1.1" + "@lerna/prompt" "5.1.1" + "@lerna/pulse-till-done" "5.1.1" + "@lerna/validation-error" "5.1.1" dedent "^0.7.0" fs-extra "^9.1.0" p-map-series "^2.1.0" -"@lerna/info@5.0.0": - version "5.0.0" - resolved "https://registry.yarnpkg.com/@lerna/info/-/info-5.0.0.tgz#649566474d0d133c22bb821f88e7d062a2beace5" - integrity sha512-k9TMK81apTjxxpnjfFOABKXndTtHBPgB8UO+I6zKhsfRqVb9FCz2MHOx8cQiSyolvNyGSQdSylSo4p7EBBomQQ== +"@lerna/info@5.1.1": + version "5.1.1" + resolved "https://registry.yarnpkg.com/@lerna/info/-/info-5.1.1.tgz#d53229bbb010fa5cf156fd7a5d8cb6a394de0e36" + integrity sha512-w2g369KYpPOKFkqZ5p2I76VnQMmOnMnAfWfy7YhNIaomYN0sUZQYA7QPu8bcEj2qKFieddx/UW497m7hY6CXsg== dependencies: - "@lerna/command" "5.0.0" - "@lerna/output" "5.0.0" + "@lerna/command" "5.1.1" + "@lerna/output" "5.1.1" envinfo "^7.7.4" -"@lerna/init@5.0.0": - version "5.0.0" - resolved "https://registry.yarnpkg.com/@lerna/init/-/init-5.0.0.tgz#e35d95a4882aafb4600abf9b32fd1a0056e73ed9" - integrity sha512-2n68x7AIqVa+Vev9xF3NV9ba0C599KYf7JsIrQ5ESv4593ftInJpwgMwjroLT3X/Chi4BK7y2/xGmrfFVwgILg== +"@lerna/init@5.1.1": + version "5.1.1" + resolved "https://registry.yarnpkg.com/@lerna/init/-/init-5.1.1.tgz#cdd88fa6d49be6e8361f548b1b09c4ad6e22d8b0" + integrity sha512-j7qgWV2zmYL+LPZ4Tqc9PO0qHUS/ZugHqVPzrnEBhlQz0ye4kPqWg2QCWId8Xmoiu6U5nGuOJINME7T8rySrDQ== dependencies: - "@lerna/child-process" "5.0.0" - "@lerna/command" "5.0.0" + "@lerna/child-process" "5.1.1" + "@lerna/command" "5.1.1" fs-extra "^9.1.0" p-map "^4.0.0" write-json-file "^4.3.0" -"@lerna/link@5.0.0": - version "5.0.0" - resolved "https://registry.yarnpkg.com/@lerna/link/-/link-5.0.0.tgz#dbd5aefa0bb22f2fd9d61ee82009fb34eb946298" - integrity sha512-00YxQ06TVhQJthOjcuxCCJRjkAM+qM/8Lv0ckdCzBBCSr4RdAGBp6QcAX/gjLNasgmNpyiza3ADet7mCH7uodw== +"@lerna/link@5.1.1": + version "5.1.1" + resolved "https://registry.yarnpkg.com/@lerna/link/-/link-5.1.1.tgz#6a77d26de859bf52b7dd40c834c72cc1ac82a6a1" + integrity sha512-31qGweCG51ZAp8u2+o4fkqGWS2pFFDmzISjkE2tkrrgb2ypjuIDQOxF38+2gdBLbWBYdZxwcBePp5/fk20cStg== dependencies: - "@lerna/command" "5.0.0" - "@lerna/package-graph" "5.0.0" - "@lerna/symlink-dependencies" "5.0.0" + "@lerna/command" "5.1.1" + "@lerna/package-graph" "5.1.1" + "@lerna/symlink-dependencies" "5.1.1" p-map "^4.0.0" slash "^3.0.0" -"@lerna/list@5.0.0": - version "5.0.0" - resolved "https://registry.yarnpkg.com/@lerna/list/-/list-5.0.0.tgz#0a979dc9c24ca176c7b4b58de80cab2dac2dcb8a" - integrity sha512-+B0yFil2AFdiYO8hyU1bFbKXGBAUUQQ43/fp2XS2jBFCipLme4eTILL5gMKOhr2Xg9AsfYPXRMRer5VW7qTeeQ== +"@lerna/list@5.1.1": + version "5.1.1" + resolved "https://registry.yarnpkg.com/@lerna/list/-/list-5.1.1.tgz#d85bb8d6f2e2fbefca3c4bc705a2ceb9cdabde43" + integrity sha512-iCinA5RuG85CY/6SCsUXAcFCDD1uauh/8Bb96qDo/Q3TZyoQSW6Gu/O6luuUXlhWGLzqlNcP+cr4uykJpGvlkQ== dependencies: - "@lerna/command" "5.0.0" - "@lerna/filter-options" "5.0.0" - "@lerna/listable" "5.0.0" - "@lerna/output" "5.0.0" + "@lerna/command" "5.1.1" + "@lerna/filter-options" "5.1.1" + "@lerna/listable" "5.1.1" + "@lerna/output" "5.1.1" -"@lerna/listable@5.0.0": - version "5.0.0" - resolved "https://registry.yarnpkg.com/@lerna/listable/-/listable-5.0.0.tgz#c1753d9375932b15c4c84cc767fffb3447b8f213" - integrity sha512-Rd5sE7KTbqA8u048qThH5IyBuJIwMcUnEObjFyJyKpc1SEWSumo4yAYmcEeN/9z62tcdud5wHYPSbVgfXJq37g== +"@lerna/listable@5.1.1": + version "5.1.1" + resolved "https://registry.yarnpkg.com/@lerna/listable/-/listable-5.1.1.tgz#254878547e75fdc079295afa389f7e539464808f" + integrity sha512-BpzYhM/9kPx13hsLdJOgNrcW1E2/WeADB0zDO1zt1ffSKWEQnsupvVd+isax7O0sAFV/ZJLXiEDEjPeg8TVvJQ== dependencies: - "@lerna/query-graph" "5.0.0" + "@lerna/query-graph" "5.1.1" chalk "^4.1.0" columnify "^1.5.4" -"@lerna/log-packed@5.0.0": - version "5.0.0" - resolved "https://registry.yarnpkg.com/@lerna/log-packed/-/log-packed-5.0.0.tgz#afa35bb6a5736038d7dde039e09828ac1c4945a2" - integrity sha512-0TxKX+XnlEYj0du9U2kg3HEyIb/0QsM0Slt8utuCxALUnXRHTEKohjqVKsBdvh1QmJpnUbL5I+vfoYqno4Y42w== +"@lerna/log-packed@5.1.1": + version "5.1.1" + resolved "https://registry.yarnpkg.com/@lerna/log-packed/-/log-packed-5.1.1.tgz#062f04460a0f6f056e69df733bf5d56281458832" + integrity sha512-wGDcal05EZh6/JCnIiPEHJmZuwizqUn5ReC5wN8hEdGc17A59JXiqYSG7h+Hj52evN2ZgDCdLj8n59paEvYhlQ== dependencies: byte-size "^7.0.0" columnify "^1.5.4" has-unicode "^2.0.1" npmlog "^4.1.2" -"@lerna/npm-conf@5.0.0": - version "5.0.0" - resolved "https://registry.yarnpkg.com/@lerna/npm-conf/-/npm-conf-5.0.0.tgz#1364270d231d0df5ac079a9a9733ba0dd7f8c2f9" - integrity sha512-KSftxtMNVhLol1JNwFFNgh5jiCG010pewM+uKeSrUe0BCB3lnidiEDzu2CCn8JYYfIXqAiou/pScUiOxVLpcAA== +"@lerna/npm-conf@5.1.1": + version "5.1.1" + resolved "https://registry.yarnpkg.com/@lerna/npm-conf/-/npm-conf-5.1.1.tgz#c4f013968f897dc854cc6dba429c99a516f26b5d" + integrity sha512-cHc26cTvXAFJj5Y6ScBYzVpJHbYxcIA0rE+bh8VfqR4UeJMll2BiFmCycIZYUnL7p27sVN05/eifkUTG6tAORg== dependencies: config-chain "^1.1.12" pify "^5.0.0" -"@lerna/npm-dist-tag@5.0.0": - version "5.0.0" - resolved "https://registry.yarnpkg.com/@lerna/npm-dist-tag/-/npm-dist-tag-5.0.0.tgz#becd7fb0bd963357818c8d4fae955cc9f8885cba" - integrity sha512-ccUFhp9Wu/FHW5/5fL+vLiSTcUZXtKQ7c0RMXtNRzIdTXBxPBkVi1k5QAnBAAffsz6Owc/K++cb+/zQ/asrG3g== +"@lerna/npm-dist-tag@5.1.1": + version "5.1.1" + resolved "https://registry.yarnpkg.com/@lerna/npm-dist-tag/-/npm-dist-tag-5.1.1.tgz#15cf727aaeefb37774e1aa81b5d8063ea3ca33d2" + integrity sha512-kmGS0uH1YZ4XDj52HKxDj863Vim7CNUy1R92/rpKyv97fkALR+DDA9XyWDl/YOf4JYyVrnQqA53CKWKuZO3jMg== dependencies: - "@lerna/otplease" "5.0.0" + "@lerna/otplease" "5.1.1" npm-package-arg "^8.1.0" npm-registry-fetch "^9.0.0" npmlog "^4.1.2" -"@lerna/npm-install@5.0.0": - version "5.0.0" - resolved "https://registry.yarnpkg.com/@lerna/npm-install/-/npm-install-5.0.0.tgz#0ee1750bb26eae3c2b4d742d5c1f055e46d534df" - integrity sha512-72Jf05JCIdeSBWXAiNjd/y2AQH4Ojgas55ojV2sAcEYz2wgyR7wSpiI6fHBRlRP+3XPjV9MXKxI3ZwOnznQxqQ== +"@lerna/npm-install@5.1.1": + version "5.1.1" + resolved "https://registry.yarnpkg.com/@lerna/npm-install/-/npm-install-5.1.1.tgz#d27bc53bd61f82703a87102169a9e355baa71aad" + integrity sha512-HXyODWaes0Wvt6Ni8Cpjvgj7VAbUEWv+MAwCZixDwKWFY6LCjY0uG4DYmMfRM5miCfP5LRdK4fDcwrF3+9bzcg== dependencies: - "@lerna/child-process" "5.0.0" - "@lerna/get-npm-exec-opts" "5.0.0" + "@lerna/child-process" "5.1.1" + "@lerna/get-npm-exec-opts" "5.1.1" fs-extra "^9.1.0" npm-package-arg "^8.1.0" npmlog "^4.1.2" signal-exit "^3.0.3" write-pkg "^4.0.0" -"@lerna/npm-publish@5.0.0": - version "5.0.0" - resolved "https://registry.yarnpkg.com/@lerna/npm-publish/-/npm-publish-5.0.0.tgz#a1a06e47e45e56999c85086a40f9b77f801b5a00" - integrity sha512-jnapZ2jRajSzshSfd1Y3rHH5R7QC+JJlYST04FBebIH3VePwDT7uAglDCI4um2THvxkW4420EzE4BUMUwKlnXA== +"@lerna/npm-publish@5.1.1": + version "5.1.1" + resolved "https://registry.yarnpkg.com/@lerna/npm-publish/-/npm-publish-5.1.1.tgz#9e468629351fddc5353aa124887b298ef564ce0f" + integrity sha512-zt+g+/Gkr8OlF8vjRd8y1UuoA4qNeZNi/JDzL3OsbiRja2SX85hU8veTGoEcJOeJowl/x+L+ENfp6E+FTZiToQ== dependencies: - "@lerna/otplease" "5.0.0" - "@lerna/run-lifecycle" "5.0.0" + "@lerna/otplease" "5.1.1" + "@lerna/run-lifecycle" "5.1.1" fs-extra "^9.1.0" libnpmpublish "^4.0.0" npm-package-arg "^8.1.0" @@ -2273,85 +2293,85 @@ pify "^5.0.0" read-package-json "^3.0.0" -"@lerna/npm-run-script@5.0.0": - version "5.0.0" - resolved "https://registry.yarnpkg.com/@lerna/npm-run-script/-/npm-run-script-5.0.0.tgz#114374b89f228c9719bbfacf9f08d6aac2739fb2" - integrity sha512-qgGf0Wc/E2YxPwIiF8kC/OB9ffPf0/HVtPVkqrblVuNE9XVP80WilOH966PIDiXzwXaCo/cTswFoBeseccYRGw== +"@lerna/npm-run-script@5.1.1": + version "5.1.1" + resolved "https://registry.yarnpkg.com/@lerna/npm-run-script/-/npm-run-script-5.1.1.tgz#6d0ef161b34e9b1b6861b39e8e39c080ef65303d" + integrity sha512-g36mFksO+5gh3xGh3N+Ni92rWBJ8bI177bhs//ot3rivyHgUKauBvR6XbWEyOYCdmnPWvMt9dlYSuzTdn2vCxg== dependencies: - "@lerna/child-process" "5.0.0" - "@lerna/get-npm-exec-opts" "5.0.0" + "@lerna/child-process" "5.1.1" + "@lerna/get-npm-exec-opts" "5.1.1" npmlog "^4.1.2" -"@lerna/otplease@5.0.0": - version "5.0.0" - resolved "https://registry.yarnpkg.com/@lerna/otplease/-/otplease-5.0.0.tgz#5b0419f64908d7ad840c2735e0284d67cd37095b" - integrity sha512-QLLkEy1DPN1XFRAAZDHxAD26MHFQDHfzB6KKSzRYxbHc6lH/YbDaMH1RloSWIm7Hwkxl/3NgpokgN4Lj5XFuzg== +"@lerna/otplease@5.1.1": + version "5.1.1" + resolved "https://registry.yarnpkg.com/@lerna/otplease/-/otplease-5.1.1.tgz#2ecdf0951e1bab7e5f94dbe16cb55307a02aee12" + integrity sha512-xCGGmB6iInFecvl+/n0Yf164rrEa8nHdbbcmcl5coe9ngu878SQKaUGSuI7J15cxy3z/yYrPjw0eSAcFCOzAbw== dependencies: - "@lerna/prompt" "5.0.0" + "@lerna/prompt" "5.1.1" -"@lerna/output@5.0.0": - version "5.0.0" - resolved "https://registry.yarnpkg.com/@lerna/output/-/output-5.0.0.tgz#f3712f0cad3e9ef73c803fe368f6a9ac20403868" - integrity sha512-/7sUJQWPcvnLudjVIdN7t9MlfBLuP4JCDAWgQMqZe+wpQRuKNyKQ5dLBH5NHU/ElJCjAwMPfWuk3mh3GuvuiGA== +"@lerna/output@5.1.1": + version "5.1.1" + resolved "https://registry.yarnpkg.com/@lerna/output/-/output-5.1.1.tgz#25bb617f9cfb8cadbbd5d917081789d0e2220f1b" + integrity sha512-QHWk9l2SAtWFyImcNrcdy5m3Ojmwvt27G3YTGT1tmMnJCNHwCDl4HKO8PBnOAxYbglujpFlXzseNHc46JSJ6xQ== dependencies: npmlog "^4.1.2" -"@lerna/pack-directory@5.0.0": - version "5.0.0" - resolved "https://registry.yarnpkg.com/@lerna/pack-directory/-/pack-directory-5.0.0.tgz#f277418545786ca68ca15647bab52ad29bd57f59" - integrity sha512-E1SNDS7xSWhJrTSmRzJK7DibneljrymviKcsZW3mRl4TmF4CpYJmNXCMlhEtKEy6ghnGQvnl3/4+eslHDJ5J/w== +"@lerna/pack-directory@5.1.1": + version "5.1.1" + resolved "https://registry.yarnpkg.com/@lerna/pack-directory/-/pack-directory-5.1.1.tgz#6fe79f9f168a216a8d1c4e3860e9673779012d3f" + integrity sha512-kMz9AQJyl9tz2RNWeUR04O2oGirS+1l3tBVV0RDdpC2wOYAOSlFp3eDgbOsKdw1vwau+J7JgfBpmiYnPwIUF9w== dependencies: - "@lerna/get-packed" "5.0.0" - "@lerna/package" "5.0.0" - "@lerna/run-lifecycle" "5.0.0" - "@lerna/temp-write" "5.0.0" + "@lerna/get-packed" "5.1.1" + "@lerna/package" "5.1.1" + "@lerna/run-lifecycle" "5.1.1" + "@lerna/temp-write" "5.1.0" npm-packlist "^2.1.4" npmlog "^4.1.2" tar "^6.1.0" -"@lerna/package-graph@5.0.0": - version "5.0.0" - resolved "https://registry.yarnpkg.com/@lerna/package-graph/-/package-graph-5.0.0.tgz#53e88ef46359ef7a2f6e3b7c5bab82302a10653f" - integrity sha512-Z3QeUQVjux0Blo64rA3/NivoLDlsQBjsZRIgGLbcQh7l7pJrqLK1WyNCBbPJ0KQNljQqUXthCKzdefnEWe37Ew== +"@lerna/package-graph@5.1.1": + version "5.1.1" + resolved "https://registry.yarnpkg.com/@lerna/package-graph/-/package-graph-5.1.1.tgz#470aac5e8ae507bcde29f83035bf8b431b50f650" + integrity sha512-2/CFYmiDbHjYPsQcT3yG8S0lG19FPIh8BqOy+cuOKNU0LZDEfI4xhQpGaZ1N6pxUjDz3CyaslwKWv/Ef5ZO8MA== dependencies: - "@lerna/prerelease-id-from-version" "5.0.0" - "@lerna/validation-error" "5.0.0" + "@lerna/prerelease-id-from-version" "5.1.1" + "@lerna/validation-error" "5.1.1" npm-package-arg "^8.1.0" npmlog "^4.1.2" semver "^7.3.4" -"@lerna/package@5.0.0": - version "5.0.0" - resolved "https://registry.yarnpkg.com/@lerna/package/-/package-5.0.0.tgz#4beeb3a1e8eed6e7ae9cebca283c7684278cdd28" - integrity sha512-/JiUU88bhbYEUTzPqoGLGwrrdWWTIVMlBb1OPxCGNGDEqYYNySX+OTTSs3zGMcmJnRNI0UyQALiEd0sh3JFN5w== +"@lerna/package@5.1.1": + version "5.1.1" + resolved "https://registry.yarnpkg.com/@lerna/package/-/package-5.1.1.tgz#f775a59e1e8abe8cbf6bd70438a42926d311cebe" + integrity sha512-1Re5wMPux4kTzuCI4WSSXaN9zERdhFoU/hHOoyDYjAnNsWy8ee9qkLEEGl8p1IVW8YSJTDDHS0RA9rg35Vd8lA== dependencies: load-json-file "^6.2.0" npm-package-arg "^8.1.0" write-pkg "^4.0.0" -"@lerna/prerelease-id-from-version@5.0.0": - version "5.0.0" - resolved "https://registry.yarnpkg.com/@lerna/prerelease-id-from-version/-/prerelease-id-from-version-5.0.0.tgz#3edb90ba9ceace97708d03ff9f650d177f973184" - integrity sha512-bUZwyx6evRn2RxogOQXaiYxRK1U/1Mh/KLO4n49wUhqb8S8Vb9aG3+7lLOgg4ZugHpj9KAlD3YGEKvwYQiWzhg== +"@lerna/prerelease-id-from-version@5.1.1": + version "5.1.1" + resolved "https://registry.yarnpkg.com/@lerna/prerelease-id-from-version/-/prerelease-id-from-version-5.1.1.tgz#e5f57577cda44569af413958ba2bd420276e2b46" + integrity sha512-z4h1oP5PeuZV7+b4BSxm43DeUeE1DCZ7pPhTlHRAZRma2TBOfy2zzfEltWQZhOrrvkO67MR16W8x0xvwZV5odA== dependencies: semver "^7.3.4" -"@lerna/profiler@5.0.0": - version "5.0.0" - resolved "https://registry.yarnpkg.com/@lerna/profiler/-/profiler-5.0.0.tgz#e1b74d17dbd6172b5ce9c80426b336bf6ab2e8e9" - integrity sha512-hFX+ZtoH7BdDoGI+bqOYaSptJTFI58wNK9qq/pHwL5ksV7vOhxP2cQAuo1SjgBKHGl0Ex/9ZT080YVV4jP1ehw== +"@lerna/profiler@5.1.1": + version "5.1.1" + resolved "https://registry.yarnpkg.com/@lerna/profiler/-/profiler-5.1.1.tgz#1f42f40199e637e50d29fea9cee3f994d1a76520" + integrity sha512-K93NXEvGIQNGcA1DGcB7W+Ff4GUzXkG5JlNRCDl/WUoaePL43Y5BXOO9yC/Qod7HR9joJkvC4nF9BTN68EL0lw== dependencies: fs-extra "^9.1.0" npmlog "^4.1.2" upath "^2.0.1" -"@lerna/project@5.0.0": - version "5.0.0" - resolved "https://registry.yarnpkg.com/@lerna/project/-/project-5.0.0.tgz#31672891236696b2a70226388de0300c6086d75f" - integrity sha512-+izHk7D/Di2b0s69AzKzAa/qBz32H9s67oN9aKntrjNylpY7iN5opU157l60Kh4TprYHU5bLisqzFLZsHHADGw== +"@lerna/project@5.1.1": + version "5.1.1" + resolved "https://registry.yarnpkg.com/@lerna/project/-/project-5.1.1.tgz#772f299ec1ed880f5171af4f5cf2cd389c404ed5" + integrity sha512-3WkJUOMWNquYshA7wFW9vMHJK8DaIOFmS7fs/XYnWGXWKEt6Mrc/+BqVDweUDK4gi/mT2nuwSH4GEB/TGNuSBg== dependencies: - "@lerna/package" "5.0.0" - "@lerna/validation-error" "5.0.0" + "@lerna/package" "5.1.1" + "@lerna/validation-error" "5.1.1" cosmiconfig "^7.0.0" dedent "^0.7.0" dot-prop "^6.0.1" @@ -2363,38 +2383,38 @@ resolve-from "^5.0.0" write-json-file "^4.3.0" -"@lerna/prompt@5.0.0": - version "5.0.0" - resolved "https://registry.yarnpkg.com/@lerna/prompt/-/prompt-5.0.0.tgz#31d3d82ecd17e863f8b7cc7944accff4f3de3395" - integrity sha512-cq2k04kOPY1yuJNHJn4qfBDDrCi9PF4Q228JICa6bxaONRf/C/TRsEQXHVIdlax8B3l53LnlGv5GECwRuvkQbA== +"@lerna/prompt@5.1.1": + version "5.1.1" + resolved "https://registry.yarnpkg.com/@lerna/prompt/-/prompt-5.1.1.tgz#903d1a5cd4c6a877e68532e39d6061ef724e24b1" + integrity sha512-+T0zgPTPCeFT81f8IGhyEH6M8y0zrgTBN+GyT0doKXPYYvL2d+zgJMv2BAerg1Iw1q0QAQhkTAGDem+SgF4bRA== dependencies: inquirer "^7.3.3" npmlog "^4.1.2" -"@lerna/publish@5.0.0": - version "5.0.0" - resolved "https://registry.yarnpkg.com/@lerna/publish/-/publish-5.0.0.tgz#27c4c469e6abd5b52e977568d328632929e859b1" - integrity sha512-QEWFtN8fW1M+YXEQOWb2XBBCT137CrwHYK29ojMXW9HShvSZezf8Q/niH91nZ4kIhWdpOGz4w3rKopsumAM5SA== - dependencies: - "@lerna/check-working-tree" "5.0.0" - "@lerna/child-process" "5.0.0" - "@lerna/collect-updates" "5.0.0" - "@lerna/command" "5.0.0" - "@lerna/describe-ref" "5.0.0" - "@lerna/log-packed" "5.0.0" - "@lerna/npm-conf" "5.0.0" - "@lerna/npm-dist-tag" "5.0.0" - "@lerna/npm-publish" "5.0.0" - "@lerna/otplease" "5.0.0" - "@lerna/output" "5.0.0" - "@lerna/pack-directory" "5.0.0" - "@lerna/prerelease-id-from-version" "5.0.0" - "@lerna/prompt" "5.0.0" - "@lerna/pulse-till-done" "5.0.0" - "@lerna/run-lifecycle" "5.0.0" - "@lerna/run-topologically" "5.0.0" - "@lerna/validation-error" "5.0.0" - "@lerna/version" "5.0.0" +"@lerna/publish@5.1.1": + version "5.1.1" + resolved "https://registry.yarnpkg.com/@lerna/publish/-/publish-5.1.1.tgz#f022c535bb6e3d12f4aa834d84b71c80fa86a718" + integrity sha512-3HGQuXWjLKr6mpjsbRrftDhlMHS8IeAA8RMW7shSPWVKl28R9HEXBoI6IRYUfAb8shtS47NFeTX+hxPUDF2cbg== + dependencies: + "@lerna/check-working-tree" "5.1.1" + "@lerna/child-process" "5.1.1" + "@lerna/collect-updates" "5.1.1" + "@lerna/command" "5.1.1" + "@lerna/describe-ref" "5.1.1" + "@lerna/log-packed" "5.1.1" + "@lerna/npm-conf" "5.1.1" + "@lerna/npm-dist-tag" "5.1.1" + "@lerna/npm-publish" "5.1.1" + "@lerna/otplease" "5.1.1" + "@lerna/output" "5.1.1" + "@lerna/pack-directory" "5.1.1" + "@lerna/prerelease-id-from-version" "5.1.1" + "@lerna/prompt" "5.1.1" + "@lerna/pulse-till-done" "5.1.1" + "@lerna/run-lifecycle" "5.1.1" + "@lerna/run-topologically" "5.1.1" + "@lerna/validation-error" "5.1.1" + "@lerna/version" "5.1.1" fs-extra "^9.1.0" libnpmaccess "^4.0.1" npm-package-arg "^8.1.0" @@ -2405,97 +2425,97 @@ pacote "^13.4.1" semver "^7.3.4" -"@lerna/pulse-till-done@5.0.0": - version "5.0.0" - resolved "https://registry.yarnpkg.com/@lerna/pulse-till-done/-/pulse-till-done-5.0.0.tgz#df3c32c2d7457362956d997da366f5c060953eef" - integrity sha512-qFeVybGIZbQSWKasWIzZmHsvCQMC/AwTz5B44a0zTt5eSNQuI65HRpKKUgmFFu/Jzd7u+yp7eP+NQ53gjOcQlQ== +"@lerna/pulse-till-done@5.1.1": + version "5.1.1" + resolved "https://registry.yarnpkg.com/@lerna/pulse-till-done/-/pulse-till-done-5.1.1.tgz#4618c461a1efc30be233f25ca603c3ce9b9a8e49" + integrity sha512-Q/efE5vkUhdKYJTH5QV3uSdZwUEIrbSa6H/wDJu+v9KqR1vdXecYK3HNjo7iQnddqJV3EsLSE9CEKEkEboRUdQ== dependencies: npmlog "^4.1.2" -"@lerna/query-graph@5.0.0": - version "5.0.0" - resolved "https://registry.yarnpkg.com/@lerna/query-graph/-/query-graph-5.0.0.tgz#76c45f648915ef5c884c32c3d35daa3ebb53440b" - integrity sha512-C/HXssBI8DVsZ/7IDW6JG9xhoHtWywi3L5oZB9q84MBYpQ9otUv6zbB+K4JCj7w9WHcuFWe2T/mc9wsaFuvB5g== +"@lerna/query-graph@5.1.1": + version "5.1.1" + resolved "https://registry.yarnpkg.com/@lerna/query-graph/-/query-graph-5.1.1.tgz#59249d3de1c5411098a6cbcff69e2ac5315a40f3" + integrity sha512-g1BWC6ckx0Prs5h54hfD7/dyALE1icE7Zi2aUkJDbUhsZoWjk+Vb9Pir6GU4HF8kzBuracz3nwq7B7GV1OY0Zg== dependencies: - "@lerna/package-graph" "5.0.0" + "@lerna/package-graph" "5.1.1" -"@lerna/resolve-symlink@5.0.0": - version "5.0.0" - resolved "https://registry.yarnpkg.com/@lerna/resolve-symlink/-/resolve-symlink-5.0.0.tgz#edff89908e90a390791ab762305d34aa95e7bdbe" - integrity sha512-O1EMQh3O3nKjLyI2guCCaxmi9xzZXpiMZhrz2ki5ENEDB2N1+f7cZ2THT0lEOIkLRuADI6hrzoN1obJ+TTk+KQ== +"@lerna/resolve-symlink@5.1.1": + version "5.1.1" + resolved "https://registry.yarnpkg.com/@lerna/resolve-symlink/-/resolve-symlink-5.1.1.tgz#dbb28105d319c25234b9a30fd3021d513e778daf" + integrity sha512-a6ZV8ysdP1ePiUG8sfcrTOrMbM9EbHO9terFVMxop7m7pekLDeOmMfWl9iGdqT36xS7S9Dlg9r+/2UsWIqH+aA== dependencies: fs-extra "^9.1.0" npmlog "^4.1.2" read-cmd-shim "^2.0.0" -"@lerna/rimraf-dir@5.0.0": - version "5.0.0" - resolved "https://registry.yarnpkg.com/@lerna/rimraf-dir/-/rimraf-dir-5.0.0.tgz#9e7689610415e6d68c9e766a462c8acfdbf04b9a" - integrity sha512-hWJg/13CiSUrWWEek3B/A1mkvBbcPvG5z69/Ugyerdpzlw44ubf02MAZ0/kXPJjkICI2hMrS07YotQ60LdYpCw== +"@lerna/rimraf-dir@5.1.1": + version "5.1.1" + resolved "https://registry.yarnpkg.com/@lerna/rimraf-dir/-/rimraf-dir-5.1.1.tgz#8b1e4d94ad63aab3f15a402482974834a033b6d4" + integrity sha512-9DtL728viAQnthKjSC/lmY/bgIDlZnBc+YHFy+f+8DEJaMP+2W8PaYsoEKPLAE/JRCmmaRi9rDQ7du373evJcg== dependencies: - "@lerna/child-process" "5.0.0" + "@lerna/child-process" "5.1.1" npmlog "^4.1.2" path-exists "^4.0.0" rimraf "^3.0.2" -"@lerna/run-lifecycle@5.0.0": - version "5.0.0" - resolved "https://registry.yarnpkg.com/@lerna/run-lifecycle/-/run-lifecycle-5.0.0.tgz#0f62c2faebc19e4ee247bdfa1e05b2a9f51b0637" - integrity sha512-36mAm9rC5DSliFShI0Y4ICjgrJXdIIVt7VW9rdbdJ8/XYjRHDzhGPB9Sc1neJOVlGL4DmaArvh5tGgo62KPJYQ== +"@lerna/run-lifecycle@5.1.1": + version "5.1.1" + resolved "https://registry.yarnpkg.com/@lerna/run-lifecycle/-/run-lifecycle-5.1.1.tgz#61151b3ff2836e6dc0d43991ed788550f7d16b2a" + integrity sha512-IZkd0U6uXysPrmPJrEtxAlGj3ytDRpSLNATVd5GCAKHdGQJ8ipQLDSIlNX5Jwlnvvkc/WpCg8FWgFK9z3piopw== dependencies: - "@lerna/npm-conf" "5.0.0" + "@lerna/npm-conf" "5.1.1" "@npmcli/run-script" "^3.0.2" npmlog "^4.1.2" -"@lerna/run-topologically@5.0.0": - version "5.0.0" - resolved "https://registry.yarnpkg.com/@lerna/run-topologically/-/run-topologically-5.0.0.tgz#0b0156e3ebe2bf768b9ba1339e02e947e70d1dd1" - integrity sha512-B2s1N/+r3sfPOLRA2svNk+C52JpXQleMuGap0yhOx5mZzR1M2Lo4vpe9Ody4hCvXQjfdLx/U342fxVmgugUtfQ== +"@lerna/run-topologically@5.1.1": + version "5.1.1" + resolved "https://registry.yarnpkg.com/@lerna/run-topologically/-/run-topologically-5.1.1.tgz#09a9ded67ec8c0022382422d928c35c1ff94adad" + integrity sha512-BQCjuKDB264dFakIpNT+FQPzRhrkMhyVgyeK55vZEXrJK/bPDx3XJ4ES5e54gvDpHEwr1MvA6J25ce8OVYJEIQ== dependencies: - "@lerna/query-graph" "5.0.0" + "@lerna/query-graph" "5.1.1" p-queue "^6.6.2" -"@lerna/run@5.0.0": - version "5.0.0" - resolved "https://registry.yarnpkg.com/@lerna/run/-/run-5.0.0.tgz#3af69d1a787866cf85072a0ae9571b9c3bf262e7" - integrity sha512-8nBZstqKSO+7wHlKk1g+iexSYRVVNJq/u5ZbAzBiHNrABtqA6/0G7q9vsAEMsnPZ8ARAUYpwvbfKTipjpWH0VA== - dependencies: - "@lerna/command" "5.0.0" - "@lerna/filter-options" "5.0.0" - "@lerna/npm-run-script" "5.0.0" - "@lerna/output" "5.0.0" - "@lerna/profiler" "5.0.0" - "@lerna/run-topologically" "5.0.0" - "@lerna/timer" "5.0.0" - "@lerna/validation-error" "5.0.0" +"@lerna/run@5.1.1": + version "5.1.1" + resolved "https://registry.yarnpkg.com/@lerna/run/-/run-5.1.1.tgz#3ebc07c82b7c37dd955f278aa51619ece024b2b0" + integrity sha512-d/N8/XzDab5JnNCNJW444AArtZ9/43NZHrAnhzbs6jHajmVx2lA1WV5tD93khd2Z2NnIBY2i7m9X/SIkyksfbA== + dependencies: + "@lerna/command" "5.1.1" + "@lerna/filter-options" "5.1.1" + "@lerna/npm-run-script" "5.1.1" + "@lerna/output" "5.1.1" + "@lerna/profiler" "5.1.1" + "@lerna/run-topologically" "5.1.1" + "@lerna/timer" "5.1.1" + "@lerna/validation-error" "5.1.1" p-map "^4.0.0" -"@lerna/symlink-binary@5.0.0": - version "5.0.0" - resolved "https://registry.yarnpkg.com/@lerna/symlink-binary/-/symlink-binary-5.0.0.tgz#f9da5673ed3a44570fa4d2e691759f82bd7ad057" - integrity sha512-uYyiiNjkdL1tWf8MDXIIyCa/a2gmYaUxagqMgEZ4wRtOk+PDypDwMUFVop/EQtUWZqG5CAJBJYOztG3DdapTbA== +"@lerna/symlink-binary@5.1.1": + version "5.1.1" + resolved "https://registry.yarnpkg.com/@lerna/symlink-binary/-/symlink-binary-5.1.1.tgz#4ca2fcdfc2dfbedd0717d5fbdffc8b6e57112d20" + integrity sha512-GrLj9zhA1e811o9F2pLKXDuhcdx1j3HCh/mmibyHMM9ZpCiwdKUqXDZdH1lVmbGa0sxzytjdsNSvJqRd+dyJRA== dependencies: - "@lerna/create-symlink" "5.0.0" - "@lerna/package" "5.0.0" + "@lerna/create-symlink" "5.1.1" + "@lerna/package" "5.1.1" fs-extra "^9.1.0" p-map "^4.0.0" -"@lerna/symlink-dependencies@5.0.0": - version "5.0.0" - resolved "https://registry.yarnpkg.com/@lerna/symlink-dependencies/-/symlink-dependencies-5.0.0.tgz#878b0f52737f82bb7014e13afda8efc606fc071c" - integrity sha512-wlZGOOB87XMy278hpF4fOwGNnjTXf1vJ/cFHIdKsJAiDipyhtnuCiJLBDPh4NzEGb02o4rhaqt8Nl5yWRu9CNA== +"@lerna/symlink-dependencies@5.1.1": + version "5.1.1" + resolved "https://registry.yarnpkg.com/@lerna/symlink-dependencies/-/symlink-dependencies-5.1.1.tgz#427ec95532c6c957cd4d91fbcf0a8b7778bd8531" + integrity sha512-IoECQdh0J2JkkEa0ozg7TO3+uTX6jSEoVLoQ9sBW1Qr8rm14jcjjg8LiuV9XPEXdonVU9SJmo2G3U+6bSx1SXA== dependencies: - "@lerna/create-symlink" "5.0.0" - "@lerna/resolve-symlink" "5.0.0" - "@lerna/symlink-binary" "5.0.0" + "@lerna/create-symlink" "5.1.1" + "@lerna/resolve-symlink" "5.1.1" + "@lerna/symlink-binary" "5.1.1" fs-extra "^9.1.0" p-map "^4.0.0" p-map-series "^2.1.0" -"@lerna/temp-write@5.0.0": - version "5.0.0" - resolved "https://registry.yarnpkg.com/@lerna/temp-write/-/temp-write-5.0.0.tgz#44f8c7c82f498e15db33c166d063be117b819162" - integrity sha512-JOkRR6xyASuBy1udyS/VD52Wgywnz7cSKppD+QKIDseNzTq27I9mNmb702BSXNXIdD19lLVQ7q6WoAlpnelnZg== +"@lerna/temp-write@5.1.0": + version "5.1.0" + resolved "https://registry.yarnpkg.com/@lerna/temp-write/-/temp-write-5.1.0.tgz#3bcecf96fca04b3d91faa01ba89540c8f1a53031" + integrity sha512-IvtYcrnWISEe9nBjhvq+o1mfn85Kup6rd+/PHb3jFmxx7E6ON4BnuqGPOOjmEjboMIRaopWQrkuCoIVotP+sDw== dependencies: graceful-fs "^4.1.15" is-stream "^2.0.0" @@ -2503,37 +2523,37 @@ temp-dir "^1.0.0" uuid "^8.3.2" -"@lerna/timer@5.0.0": - version "5.0.0" - resolved "https://registry.yarnpkg.com/@lerna/timer/-/timer-5.0.0.tgz#ab8fba29f90de21b0eb02406916269122deb2e41" - integrity sha512-p2vevkpB6V/b0aR8VyMLDfg0Arp9VvMxcZOEu+IfZ9XKTtnbwjWPHKUOS34x/VGa6bnOIWjE046ixWymOs/fTw== +"@lerna/timer@5.1.1": + version "5.1.1" + resolved "https://registry.yarnpkg.com/@lerna/timer/-/timer-5.1.1.tgz#4cd47757c5f254c2f34aac09d9cee0bccdbe91ea" + integrity sha512-c+v2xoxVpKcgjJEtiEw/J3lrBCsVxhQL9lrE1+emoV/GcxOxk6rWQKIJ6WQOhuaR/BsoHBEKF8C+xRlX/qt29g== -"@lerna/validation-error@5.0.0": - version "5.0.0" - resolved "https://registry.yarnpkg.com/@lerna/validation-error/-/validation-error-5.0.0.tgz#3d3557023e3eb2fd3d8fc9c89f7352a1b6e5bd3e" - integrity sha512-fu/MhqRXiRQM2cirP/HoSkfwc5XtJ21G60WHv74RnanKBqWEZAUALWa3MQN2sYhVV/FpDW3GLkO008IW5NWzdg== +"@lerna/validation-error@5.1.1": + version "5.1.1" + resolved "https://registry.yarnpkg.com/@lerna/validation-error/-/validation-error-5.1.1.tgz#3e4bb27452022bf9d621bc8c4c6712d67c332d49" + integrity sha512-6mwvlaMxu03ydKCvKeK8XvbCDCHM0UURvJpgtVo/0ghu8kQOICHo3qwkJNf7lzbUIPojTLrdfWNCZ5M4CT43Dg== dependencies: npmlog "^4.1.2" -"@lerna/version@5.0.0": - version "5.0.0" - resolved "https://registry.yarnpkg.com/@lerna/version/-/version-5.0.0.tgz#36a808e8b4458febd58a6b76852f2ce30e740ca1" - integrity sha512-M8KvdyG5kR/d3wgg5S46Q2YMf0L9iw9MiumTvlDP4ckysTt+04kS74Vp4+aClgPM4xaoI5OuMrs6wy5ICcd3Pw== - dependencies: - "@lerna/check-working-tree" "5.0.0" - "@lerna/child-process" "5.0.0" - "@lerna/collect-updates" "5.0.0" - "@lerna/command" "5.0.0" - "@lerna/conventional-commits" "5.0.0" - "@lerna/github-client" "5.0.0" - "@lerna/gitlab-client" "5.0.0" - "@lerna/output" "5.0.0" - "@lerna/prerelease-id-from-version" "5.0.0" - "@lerna/prompt" "5.0.0" - "@lerna/run-lifecycle" "5.0.0" - "@lerna/run-topologically" "5.0.0" - "@lerna/temp-write" "5.0.0" - "@lerna/validation-error" "5.0.0" +"@lerna/version@5.1.1": + version "5.1.1" + resolved "https://registry.yarnpkg.com/@lerna/version/-/version-5.1.1.tgz#4e938573a690b4e490a9f199327bddf0568b83c8" + integrity sha512-kUsqFYGKNKYWXfMu+q6EJhWhxvk41ihQbxpZhC4pPWwy30xetjNc2i+0O+QTlEaaFabtAUOCLYWG1V1RoL5N4A== + dependencies: + "@lerna/check-working-tree" "5.1.1" + "@lerna/child-process" "5.1.1" + "@lerna/collect-updates" "5.1.1" + "@lerna/command" "5.1.1" + "@lerna/conventional-commits" "5.1.1" + "@lerna/github-client" "5.1.1" + "@lerna/gitlab-client" "5.1.1" + "@lerna/output" "5.1.1" + "@lerna/prerelease-id-from-version" "5.1.1" + "@lerna/prompt" "5.1.1" + "@lerna/run-lifecycle" "5.1.1" + "@lerna/run-topologically" "5.1.1" + "@lerna/temp-write" "5.1.0" + "@lerna/validation-error" "5.1.1" chalk "^4.1.0" dedent "^0.7.0" load-json-file "^6.2.0" @@ -2547,10 +2567,10 @@ slash "^3.0.0" write-json-file "^4.3.0" -"@lerna/write-log-file@5.0.0": - version "5.0.0" - resolved "https://registry.yarnpkg.com/@lerna/write-log-file/-/write-log-file-5.0.0.tgz#ad3d33d6153b962beef48442ab6472233b5d5197" - integrity sha512-kpPNxe9xm36QbCWY7DwO96Na6FpCHzZinJtw6ttBHslIcdR38lZuCp+/2KfJcVsRIPNOsp1VvgP7EZIKiBhgjw== +"@lerna/write-log-file@5.1.1": + version "5.1.1" + resolved "https://registry.yarnpkg.com/@lerna/write-log-file/-/write-log-file-5.1.1.tgz#859e7ba1ab419dad45f30af13dfd9c8e6002cbe1" + integrity sha512-cOfGlnZlFhP/5PZABJ98bI9UgCIHNJtlKyO8T24Uz647XZMoX/fwD+E/DVVuVyxjv7vYDvCrrX1tPYFq8ePfNA== dependencies: npmlog "^4.1.2" write-file-atomic "^3.0.3" @@ -2994,15 +3014,14 @@ dependencies: "@sinonjs/commons" "^1.7.0" -"@slorber/static-site-generator-webpack-plugin@^4.0.4": - version "4.0.4" - resolved "https://registry.yarnpkg.com/@slorber/static-site-generator-webpack-plugin/-/static-site-generator-webpack-plugin-4.0.4.tgz#2bf4a2545e027830d2aa5eb950437c26a289b0f1" - integrity sha512-FvMavoWEIePps6/JwGCOLYKCRhuwIHhMtmbKpBFgzNkxwpa/569LfTkrbRk1m1I3n+ezJK4on9E1A6cjuZmD9g== +"@slorber/static-site-generator-webpack-plugin@^4.0.7": + version "4.0.7" + resolved "https://registry.yarnpkg.com/@slorber/static-site-generator-webpack-plugin/-/static-site-generator-webpack-plugin-4.0.7.tgz#fc1678bddefab014e2145cbe25b3ce4e1cfc36f3" + integrity sha512-Ug7x6z5lwrz0WqdnNFOMYrDQNTPAprvHLSh6+/fmml3qUiz6l5eq+2MzLKWtn/q5K5NpSiFsZTP/fck/3vjSxA== dependencies: - bluebird "^3.7.1" - cheerio "^0.22.0" eval "^0.1.8" - webpack-sources "^1.4.3" + p-map "^4.0.0" + webpack-sources "^3.2.2" "@surma/rollup-plugin-off-main-thread@^2.2.3": version "2.2.3" @@ -3118,89 +3137,89 @@ "@svgr/plugin-jsx" "^6.2.1" "@svgr/plugin-svgo" "^6.2.0" -"@swc/core-android-arm-eabi@1.2.194": - version "1.2.194" - resolved "https://registry.yarnpkg.com/@swc/core-android-arm-eabi/-/core-android-arm-eabi-1.2.194.tgz#27a92ac4ce3bb036da95b376ba88f0a364430ab2" - integrity sha512-Hv/k9KN2Aab8jO/SmSlzKpzS941IXfdr9XEQRl/rc5Nj4neVW8AWS4+AJnl4u7MiJrfM0No6ZRQx32Ke+APmLQ== - -"@swc/core-android-arm64@1.2.194": - version "1.2.194" - resolved "https://registry.yarnpkg.com/@swc/core-android-arm64/-/core-android-arm64-1.2.194.tgz#3ac858368ed86894c2b9d288382dc438dacd68f4" - integrity sha512-/r2iah0khiv3xUbOT6upf1fdeGdKrVa8sghyTI0jPRpQ5GKD01nuEq+FlmieTwkQ0pQbgVKun0zyriAOXjLqWA== - -"@swc/core-darwin-arm64@1.2.194": - version "1.2.194" - resolved "https://registry.yarnpkg.com/@swc/core-darwin-arm64/-/core-darwin-arm64-1.2.194.tgz#dfd25234bd49a3195c1e2ad5e8ebcc10f9af2de9" - integrity sha512-pLsxgi985iSu+wqskJAO+kr0QwNqYQSyfdQEjCtWi5oYp3wIBPHLccIPVcIUfD6YAqXdqnQJg9RtA4scpdrQNg== - -"@swc/core-darwin-x64@1.2.194": - version "1.2.194" - resolved "https://registry.yarnpkg.com/@swc/core-darwin-x64/-/core-darwin-x64-1.2.194.tgz#1e60ffcb7b3b959da9aa192c7d6cc9b96e6890b2" - integrity sha512-WLFhotRbGqMKg9HwB0RF0Ycz6B6uSMEHcblAdBhiyL4fIp+CMUhkvC8jTs0xij/yJj96B6Xf9UH/Q5MFUQrJEw== - -"@swc/core-freebsd-x64@1.2.194": - version "1.2.194" - resolved "https://registry.yarnpkg.com/@swc/core-freebsd-x64/-/core-freebsd-x64-1.2.194.tgz#31551c68724a942b59122774cf522ebde911ec6e" - integrity sha512-UNG8G5TlYWvfyB7+Fc1h5hoSwEY1LLLth7V8DFMljd0dm2hcSpukuWaQk/GE3EANCE40nq3y4THEAlSu4lauSg== - -"@swc/core-linux-arm-gnueabihf@1.2.194": - version "1.2.194" - resolved "https://registry.yarnpkg.com/@swc/core-linux-arm-gnueabihf/-/core-linux-arm-gnueabihf-1.2.194.tgz#471d8a3d23d4338969e74dad1889781b0f0e4461" - integrity sha512-mbk4MMgBf9BWFV0yqvReT29xZ6N6CLNgiG2UFnmXkLrrEBrAz5c3W8so5VqdyK52yWMS5Vs0a6VOvlimh057KA== - -"@swc/core-linux-arm64-gnu@1.2.194": - version "1.2.194" - resolved "https://registry.yarnpkg.com/@swc/core-linux-arm64-gnu/-/core-linux-arm64-gnu-1.2.194.tgz#49da5e1f92a9566442fc8e9bd67a699f35096049" - integrity sha512-vdr2zUJnd67oQfXn1Ix0ueND+iEnCTwA4dobT4s0KsZCusJKuJlkm97p7rgk3Cxn2sHm/8BBQX4KpdXwNEL3Tw== - -"@swc/core-linux-arm64-musl@1.2.194": - version "1.2.194" - resolved "https://registry.yarnpkg.com/@swc/core-linux-arm64-musl/-/core-linux-arm64-musl-1.2.194.tgz#29c309bf7ac484baa8ba105e6f6acaaaaede4336" - integrity sha512-wocEG55mu/KAFs1B9l1E0FbfU9nKaY3ULuT/isELHqDNZB23nNFRa+ymez/NqBhqVPhX4B0L+7j2r4tipXiI2A== - -"@swc/core-linux-x64-gnu@1.2.194": - version "1.2.194" - resolved "https://registry.yarnpkg.com/@swc/core-linux-x64-gnu/-/core-linux-x64-gnu-1.2.194.tgz#6f091d74ef58354410c9bcba7285546579008b54" - integrity sha512-PA7kudCtpGy1m40LKTeIsSse0zkmMyHthYjfn7q8pUWlo2b9o9RxO5zsnLxLsgATsoPwfMmVl9m3+1xSkxJp+g== - -"@swc/core-linux-x64-musl@1.2.194": - version "1.2.194" - resolved "https://registry.yarnpkg.com/@swc/core-linux-x64-musl/-/core-linux-x64-musl-1.2.194.tgz#41c110bb30cd38d1fd61e29698166d59b3fda3aa" - integrity sha512-2CdLXLpdKqtZmFgcEOyw9Gu/24ku5/4NabSdYg58XGarrPS96lQk80rzaMYxs6AzfsfhHGmsp3se07jnLwSlXQ== - -"@swc/core-win32-arm64-msvc@1.2.194": - version "1.2.194" - resolved "https://registry.yarnpkg.com/@swc/core-win32-arm64-msvc/-/core-win32-arm64-msvc-1.2.194.tgz#be4eb6826f4665fc67c170b485ec92f01f509c05" - integrity sha512-7NpBJ1fgeP8Y2H0aCTZR8nx0BEHXdSuFwBAwKrb4kaP0d2qVAVIv/rOk7L/MwsuXmlsISQ13JnUtQYjYPGJsUg== - -"@swc/core-win32-ia32-msvc@1.2.194": - version "1.2.194" - resolved "https://registry.yarnpkg.com/@swc/core-win32-ia32-msvc/-/core-win32-ia32-msvc-1.2.194.tgz#f5a3311f8368e6299e53e350ee6b41f00f2ebeb0" - integrity sha512-1TP+kS32uFSgBHOJGmLNfxcqU7e85FZZTKAVAQgEPmHH0lJ/9BcViMDhMOdnyEWjIluD5aj6WdPdeAz1YlXDng== - -"@swc/core-win32-x64-msvc@1.2.194": - version "1.2.194" - resolved "https://registry.yarnpkg.com/@swc/core-win32-x64-msvc/-/core-win32-x64-msvc-1.2.194.tgz#39cd340c6c2e0e6221f92d64f6c30ca749bcf0cc" - integrity sha512-c3tiShCGY03XbJqXpliHRHMBBB/KGWS1kcbKn2GhaZN4fY8UgD5kZk3XJDwDJ6oqwlgkBdWXRAgD5Td2aAKMRg== - -"@swc/core@^1.2.194": - version "1.2.194" - resolved "https://registry.yarnpkg.com/@swc/core/-/core-1.2.194.tgz#698d9ea07fd0b55273e7651e3f95b1c5cf4b61ae" - integrity sha512-+Jg3qxad32CqnFmw4pqwm/5JCVWGkoM8P5pqPlyj5sokHFUJluMkCeaikuvIZhJCabR9q84lEnXlIjMu42ZfKA== +"@swc/core-android-arm-eabi@1.2.197": + version "1.2.197" + resolved "https://registry.yarnpkg.com/@swc/core-android-arm-eabi/-/core-android-arm-eabi-1.2.197.tgz#fdc58468a4c8599cdb33b262ff8377e04d68c3e4" + integrity sha512-BNIexULLlBCU7jIbXA/+BpMUwraFbyifPkOlyC8MriyoR7wfW5cau56yOUztxrr7VdxcByMK+nO70WkVydUV3w== + +"@swc/core-android-arm64@1.2.197": + version "1.2.197" + resolved "https://registry.yarnpkg.com/@swc/core-android-arm64/-/core-android-arm64-1.2.197.tgz#fcf60c7773ad7529cd3606a211c0fbac283c8c1c" + integrity sha512-H1AJfQkojk+INurBwiHJf4iRpRwTI2I43TWUVbxXCyfAc9K9hfKNJFzp5Xapka5nLSgSD2ZNZgseMbfwUcYq6A== + +"@swc/core-darwin-arm64@1.2.197": + version "1.2.197" + resolved "https://registry.yarnpkg.com/@swc/core-darwin-arm64/-/core-darwin-arm64-1.2.197.tgz#091ce5b565c2295d49d872ebc684d89bbe7e756a" + integrity sha512-JIfXS1HHKKwZlVoKhVTllvD0m0sXiIneaw9TwXtUrHe6K95wJ53q82sqJyqBOWimh9ulCcB2M+XuqK4zDGbosA== + +"@swc/core-darwin-x64@1.2.197": + version "1.2.197" + resolved "https://registry.yarnpkg.com/@swc/core-darwin-x64/-/core-darwin-x64-1.2.197.tgz#fa78db11674fbffb86c2346de2212f806377d67f" + integrity sha512-Ml7MXJgrNuSGVNvEbeB1BoWFZ2rPhRBSa7IyvfTMmB/oDEvIKIkWH/5hEYdCy99s8XQ6ufqdMjPVqOFRuRXfig== + +"@swc/core-freebsd-x64@1.2.197": + version "1.2.197" + resolved "https://registry.yarnpkg.com/@swc/core-freebsd-x64/-/core-freebsd-x64-1.2.197.tgz#c83c03368c748bd7e87c2f8013cb3d1861732ebb" + integrity sha512-Ae6aDvBS/VGAHP3szmampFDzNZ/fOKVAhI1qqQauShzyIqXGL83GZ2zhC1FA94oC5Kora7VHz43DPqUuYRQPtg== + +"@swc/core-linux-arm-gnueabihf@1.2.197": + version "1.2.197" + resolved "https://registry.yarnpkg.com/@swc/core-linux-arm-gnueabihf/-/core-linux-arm-gnueabihf-1.2.197.tgz#d59ffb35eab9372c126009642b392a0e4efbe80c" + integrity sha512-cqIeaBzVVfsCW4CvJdxPwz9EHqnJZ+0K6gfTuHDa6Fp6ThWZtqKQhK4zL4hV3L4nWj7bqbOYKSUbdR79p4v92Q== + +"@swc/core-linux-arm64-gnu@1.2.197": + version "1.2.197" + resolved "https://registry.yarnpkg.com/@swc/core-linux-arm64-gnu/-/core-linux-arm64-gnu-1.2.197.tgz#789739ae412f0d13dbf560f0b9d48b05d7d4cd9d" + integrity sha512-1HHSnImnLAvuBpiDi7kJwyPEbAfSkLpL5IEMSQas90jDrIrSwgmnPLE5qBJwPasyrT8hJ/3n297tR+SlcudT/Q== + +"@swc/core-linux-arm64-musl@1.2.197": + version "1.2.197" + resolved "https://registry.yarnpkg.com/@swc/core-linux-arm64-musl/-/core-linux-arm64-musl-1.2.197.tgz#d38b6394d24fa6c2627aed173d69325816ed8907" + integrity sha512-C2GTIN5XgN/3zvwZITQnEuBMsPE2gQ5kkFjTFF9sKqG8tNUI8V+FP6AV4h7IkLccT1CgSWM7GCP4LsL2OC2iBA== + +"@swc/core-linux-x64-gnu@1.2.197": + version "1.2.197" + resolved "https://registry.yarnpkg.com/@swc/core-linux-x64-gnu/-/core-linux-x64-gnu-1.2.197.tgz#39ca0bd48b0b2b7b5bcebb48bd27fac3edc37cce" + integrity sha512-AHEHo9/u9GIBPUqsCkGWWe6WqGWAk07UklHm0k6Z99Z3OgsDfyDRECMVZGIAgMr1HqPPzsJCP5AmQ6WKZNBrfQ== + +"@swc/core-linux-x64-musl@1.2.197": + version "1.2.197" + resolved "https://registry.yarnpkg.com/@swc/core-linux-x64-musl/-/core-linux-x64-musl-1.2.197.tgz#673a86c7de79b405f675b14710d29cd81c23e37b" + integrity sha512-ZnawXY/s0YJnUqWZCN91VkPzTcH1hImOzUvwJ8f7uCIIYOLHYdjUa5S6xPVNHqOEanNYaeCq354LxBytYIo83g== + +"@swc/core-win32-arm64-msvc@1.2.197": + version "1.2.197" + resolved "https://registry.yarnpkg.com/@swc/core-win32-arm64-msvc/-/core-win32-arm64-msvc-1.2.197.tgz#73a4d89530985a7b784c8037a297f3bcce19bb98" + integrity sha512-jYnc5c2fn2z0oyy8mJkxstc4qxjZnQsf6YmCM32bm4un05MQg+4y4VxWxY7NMCPRaf8zWojcAy1wltuidbIe/A== + +"@swc/core-win32-ia32-msvc@1.2.197": + version "1.2.197" + resolved "https://registry.yarnpkg.com/@swc/core-win32-ia32-msvc/-/core-win32-ia32-msvc-1.2.197.tgz#a3cca42555d43636665ea0b3c60d29a41657492e" + integrity sha512-l8wa+2brxw8UUCNn65wBtUECVCs3w4WBOiTpT/+rPJF9vYVL7gt2rds73a+yB6rSIhOZqEseazIHi2aQ1S9bxQ== + +"@swc/core-win32-x64-msvc@1.2.197": + version "1.2.197" + resolved "https://registry.yarnpkg.com/@swc/core-win32-x64-msvc/-/core-win32-x64-msvc-1.2.197.tgz#611d4f6c490bfa0503c8a5567bfbef70c78cb7b3" + integrity sha512-uYf+Zch1rhNK3nAYL9C5a5WjtlffLkRf4Dh1OmuqNGmm7EI+AdwTECZX3cT1iICGb2J3GHUJlfPsNdllG8L9qA== + +"@swc/core@^1.2.197": + version "1.2.197" + resolved "https://registry.yarnpkg.com/@swc/core/-/core-1.2.197.tgz#b22eb441429b37913fb7872ecfd2d9fb6a8d1be6" + integrity sha512-W7gUaNCrm4i26ZUMilPZjHiQck8mOMfOuZuXj1YrISMR20orACgEHz4kJHbqfXzHhqeS4CGwBkzi9h1lHrwKtw== optionalDependencies: - "@swc/core-android-arm-eabi" "1.2.194" - "@swc/core-android-arm64" "1.2.194" - "@swc/core-darwin-arm64" "1.2.194" - "@swc/core-darwin-x64" "1.2.194" - "@swc/core-freebsd-x64" "1.2.194" - "@swc/core-linux-arm-gnueabihf" "1.2.194" - "@swc/core-linux-arm64-gnu" "1.2.194" - "@swc/core-linux-arm64-musl" "1.2.194" - "@swc/core-linux-x64-gnu" "1.2.194" - "@swc/core-linux-x64-musl" "1.2.194" - "@swc/core-win32-arm64-msvc" "1.2.194" - "@swc/core-win32-ia32-msvc" "1.2.194" - "@swc/core-win32-x64-msvc" "1.2.194" + "@swc/core-android-arm-eabi" "1.2.197" + "@swc/core-android-arm64" "1.2.197" + "@swc/core-darwin-arm64" "1.2.197" + "@swc/core-darwin-x64" "1.2.197" + "@swc/core-freebsd-x64" "1.2.197" + "@swc/core-linux-arm-gnueabihf" "1.2.197" + "@swc/core-linux-arm64-gnu" "1.2.197" + "@swc/core-linux-arm64-musl" "1.2.197" + "@swc/core-linux-x64-gnu" "1.2.197" + "@swc/core-linux-x64-musl" "1.2.197" + "@swc/core-win32-arm64-msvc" "1.2.197" + "@swc/core-win32-ia32-msvc" "1.2.197" + "@swc/core-win32-x64-msvc" "1.2.197" "@swc/jest@^0.2.21": version "0.2.21" @@ -3240,9 +3259,9 @@ integrity sha512-L7z9BgrNEcYyUYtF+HaEfiS5ebkh9jXqbszz7pC0hRBPaatV0XjSD3+eHrpqFemQfgwiFF0QPIarnIihIDn7OA== "@tsconfig/docusaurus@^1.0.5": - version "1.0.5" - resolved "https://registry.yarnpkg.com/@tsconfig/docusaurus/-/docusaurus-1.0.5.tgz#5298c5b0333c6263f06c3149b38ebccc9f169a4e" - integrity sha512-KM/TuJa9fugo67dTGx+ktIqf3fVc077J6jwHu845Hex4EQf7LABlNonP/mohDKT0cmncdtlYVHHF74xR/YpThg== + version "1.0.6" + resolved "https://registry.yarnpkg.com/@tsconfig/docusaurus/-/docusaurus-1.0.6.tgz#7305a7fa590decc0d5968500234e95fd68788978" + integrity sha512-1QxDaP54hpzM6bq9E+yFEo4F9WbWHhsDe4vktZXF/iDlc9FqGr9qlg+3X/nuKQXx8QxHV7ue8NXFazzajsxFBA== "@types/babel__core@^7.1.14": version "7.1.19" @@ -3375,9 +3394,9 @@ "@types/estree" "*" "@types/eslint@*": - version "8.4.2" - resolved "https://registry.yarnpkg.com/@types/eslint/-/eslint-8.4.2.tgz#48f2ac58ab9c631cb68845c3d956b28f79fad575" - integrity sha512-Z1nseZON+GEnFjJc04sv4NSALGjhFwy6K0HXt7qsn5ArfAKtb63dXNJHf+1YW6IpOIYRBGUbu3GwJdj8DGnCjA== + version "8.4.3" + resolved "https://registry.yarnpkg.com/@types/eslint/-/eslint-8.4.3.tgz#5c92815a3838b1985c90034cd85f26f59d9d0ece" + integrity sha512-YP1S7YJRMPs+7KZKDb9G63n8YejIwW9BALq7a5j2+H4yl6iOv9CB29edho+cuFRrvmJbbaH2yiVChKLJVysDGw== dependencies: "@types/estree" "*" "@types/json-schema" "*" @@ -3506,10 +3525,10 @@ dependencies: "@types/istanbul-lib-report" "*" -"@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== +"@types/jest@^28.1.1": + version "28.1.1" + resolved "https://registry.yarnpkg.com/@types/jest/-/jest-28.1.1.tgz#8c9ba63702a11f8c386ee211280e8b68cb093cd1" + integrity sha512-C2p7yqleUKtCkVjlOur9BWVA4HgUQmEj/HWCt5WzZ5mLXrWnyIfl0wGuArc+kBXsy0ZZfLp+7dywB4HtSVYGVA== dependencies: jest-matcher-utils "^27.0.0" pretty-format "^27.0.0" @@ -3592,10 +3611,10 @@ resolved "https://registry.yarnpkg.com/@types/minimist/-/minimist-1.2.2.tgz#ee771e2ba4b3dc5b372935d549fd9617bf345b8c" integrity sha512-jhuKLIRrhvCPLqwPcx6INqmKeiA5EWrsCOPhrlFSrbrmU4ZMPjj5Ul/oLCMDO98XRUIwVm78xICz4EPCektzeQ== -"@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/node@*", "@types/node@^17.0.42", "@types/node@^17.0.5": + version "17.0.42" + resolved "https://registry.yarnpkg.com/@types/node/-/node-17.0.42.tgz#d7e8f22700efc94d125103075c074396b5f41f9b" + integrity sha512-Q5BPGyGKcvQgAMbsr7qEGN/kIPN6zZecYYABeTDBizOsau+2NMdSVTar9UQw21A2+JyA2KRNDYaYrPB0Rpk2oQ== "@types/node@^16": version "16.11.36" @@ -3633,9 +3652,9 @@ integrity sha512-O397rnSS9iQI4OirieAtsDqvCj4+3eY1J+EPdNTKuHuRWIfUoGyzX294o8C4KJYaLqgSrd2o60c5EqCU8Zv02g== "@types/prettier@^2.1.5": - version "2.6.1" - resolved "https://registry.yarnpkg.com/@types/prettier/-/prettier-2.6.1.tgz#76e72d8a775eef7ce649c63c8acae1a0824bbaed" - integrity sha512-XFjFHmaLVifrAKaZ+EKghFHtHSUonyw8P2Qmy2/+osBnrKbH9UYtlK10zg8/kCt47MFilll/DEDKy3DHfJ0URw== + version "2.6.3" + resolved "https://registry.yarnpkg.com/@types/prettier/-/prettier-2.6.3.tgz#68ada76827b0010d0db071f739314fa429943d0a" + integrity sha512-ymZk3LEC/fsut+/Q5qejp6R9O1rMxz3XaRHDV6kX8MrGAhOSPqVARbDi+EZvInBpw+BnCX3TD240byVkOfQsHg== "@types/prismjs@^1.26.0": version "1.26.0" @@ -3715,10 +3734,10 @@ dependencies: "@types/react" "*" -"@types/react@*", "@types/react@^18.0.9": - version "18.0.9" - resolved "https://registry.yarnpkg.com/@types/react/-/react-18.0.9.tgz#d6712a38bd6cd83469603e7359511126f122e878" - integrity sha512-9bjbg1hJHUm4De19L1cHiW0Jvx3geel6Qczhjd0qY5VKVE2X5+x77YxAepuCwVh4vrgZJdgEJw48zrhRIeF4Nw== +"@types/react@*", "@types/react@^18.0.12": + version "18.0.12" + resolved "https://registry.yarnpkg.com/@types/react/-/react-18.0.12.tgz#cdaa209d0a542b3fcf69cf31a03976ec4cdd8840" + integrity sha512-duF1OTASSBQtcigUvhuiTB1Ya3OvSy+xORCiEf20H0P0lzx+/KeVsA99U5UjLXSbyo1DRJDlLKqTeM1ngosqtg== dependencies: "@types/prop-types" "*" "@types/scheduler" "*" @@ -3793,7 +3812,7 @@ dependencies: "@types/express" "*" -"@types/serve-static@*": +"@types/serve-static@*", "@types/serve-static@^1.13.10": version "1.13.10" resolved "https://registry.yarnpkg.com/@types/serve-static/-/serve-static-1.13.10.tgz#f5e0ce8797d2d7cc5ebeda48a52c96c4fa47a8d9" integrity sha512-nCkHGI4w7ZgAdNkrEu0bv+4xNV/XDqW+DydknebMOQwkpDGx8G+HTlj7R7ABI8i8nKxVw0wtKPi1D+lPOkh4YQ== @@ -3801,10 +3820,10 @@ "@types/mime" "^1" "@types/node" "*" -"@types/sharp@^0.30.2": - version "0.30.2" - resolved "https://registry.yarnpkg.com/@types/sharp/-/sharp-0.30.2.tgz#df5ff34140b3bad165482e6f3d26b08e42a0503a" - integrity sha512-uLCBwjDg/BTcQit0dpNGvkIjvH3wsb8zpaJePCjvONBBSfaKHoxXBIuq1MT8DMQEfk2fKYnpC9QExCgFhkGkMQ== +"@types/sharp@^0.30.4": + version "0.30.4" + resolved "https://registry.yarnpkg.com/@types/sharp/-/sharp-0.30.4.tgz#7430b5fcf37f35dd860112c4cf6dcd6a1ba0011b" + integrity sha512-6oJEzKt7wZeS7e+6x9QFEOWGs0T/6of00+0onZGN1zSmcSjcTDZKgIGZ6YWJnHowpaKUCFBPH52mYljWqU32Eg== dependencies: "@types/node" "*" @@ -3859,9 +3878,9 @@ integrity sha512-F5DIZ36YVLE+PN+Zwws4kJogq47hNgX3Nx6WyDJ3kcplxyke3XIzB8uK5n/Lpm1HBsbGzd6nmGehL8cPekP+Tg== "@types/uglify-js@*": - version "3.13.2" - resolved "https://registry.yarnpkg.com/@types/uglify-js/-/uglify-js-3.13.2.tgz#1044c1713fb81cb1ceef29ad8a9ee1ce08d690ef" - integrity sha512-/xFrPIo+4zOeNGtVMbf9rUm0N+i4pDf1ynExomqtokIJmVzR3962lJ1UE+MmexMkA0cmN9oTzg5Xcbwge0Ij2Q== + version "3.16.0" + resolved "https://registry.yarnpkg.com/@types/uglify-js/-/uglify-js-3.16.0.tgz#2cf74a0e6ebb6cd54c0d48e509d5bd91160a9602" + integrity sha512-0yeUr92L3r0GLRnBOvtYK1v2SjqMIqQDHMl7GLb+l2L8+6LSFWEEWEIgVsPdMn5ImLM8qzWT8xFPtQYpp8co0g== dependencies: source-map "^0.6.1" @@ -3952,14 +3971,14 @@ dependencies: "@types/yargs-parser" "*" -"@typescript-eslint/eslint-plugin@^5.26.0": - version "5.26.0" - resolved "https://registry.yarnpkg.com/@typescript-eslint/eslint-plugin/-/eslint-plugin-5.26.0.tgz#c1f98ccba9d345e38992975d3ca56ed6260643c2" - integrity sha512-oGCmo0PqnRZZndr+KwvvAUvD3kNE4AfyoGCwOZpoCncSh4MVD06JTE8XQa2u9u+NX5CsyZMBTEc2C72zx38eYA== +"@typescript-eslint/eslint-plugin@^5.27.1": + version "5.27.1" + resolved "https://registry.yarnpkg.com/@typescript-eslint/eslint-plugin/-/eslint-plugin-5.27.1.tgz#fdf59c905354139046b41b3ed95d1609913d0758" + integrity sha512-6dM5NKT57ZduNnJfpY81Phe9nc9wolnMCnknb1im6brWi1RYv84nbMS3olJa27B6+irUVV1X/Wb+Am0FjJdGFw== dependencies: - "@typescript-eslint/scope-manager" "5.26.0" - "@typescript-eslint/type-utils" "5.26.0" - "@typescript-eslint/utils" "5.26.0" + "@typescript-eslint/scope-manager" "5.27.1" + "@typescript-eslint/type-utils" "5.27.1" + "@typescript-eslint/utils" "5.27.1" debug "^4.3.4" functional-red-black-tree "^1.0.1" ignore "^5.2.0" @@ -3967,69 +3986,69 @@ semver "^7.3.7" tsutils "^3.21.0" -"@typescript-eslint/parser@^5.26.0": - version "5.26.0" - resolved "https://registry.yarnpkg.com/@typescript-eslint/parser/-/parser-5.26.0.tgz#a61b14205fe2ab7533deb4d35e604add9a4ceee2" - integrity sha512-n/IzU87ttzIdnAH5vQ4BBDnLPly7rC5VnjN3m0xBG82HK6rhRxnCb3w/GyWbNDghPd+NktJqB/wl6+YkzZ5T5Q== +"@typescript-eslint/parser@^5.27.1": + version "5.27.1" + resolved "https://registry.yarnpkg.com/@typescript-eslint/parser/-/parser-5.27.1.tgz#3a4dcaa67e45e0427b6ca7bb7165122c8b569639" + integrity sha512-7Va2ZOkHi5NP+AZwb5ReLgNF6nWLGTeUJfxdkVUAPPSaAdbWNnFZzLZ4EGGmmiCTg+AwlbE1KyUYTBglosSLHQ== dependencies: - "@typescript-eslint/scope-manager" "5.26.0" - "@typescript-eslint/types" "5.26.0" - "@typescript-eslint/typescript-estree" "5.26.0" + "@typescript-eslint/scope-manager" "5.27.1" + "@typescript-eslint/types" "5.27.1" + "@typescript-eslint/typescript-estree" "5.27.1" debug "^4.3.4" -"@typescript-eslint/scope-manager@5.26.0": - version "5.26.0" - resolved "https://registry.yarnpkg.com/@typescript-eslint/scope-manager/-/scope-manager-5.26.0.tgz#44209c7f649d1a120f0717e0e82da856e9871339" - integrity sha512-gVzTJUESuTwiju/7NiTb4c5oqod8xt5GhMbExKsCTp6adU3mya6AGJ4Pl9xC7x2DX9UYFsjImC0mA62BCY22Iw== +"@typescript-eslint/scope-manager@5.27.1": + version "5.27.1" + resolved "https://registry.yarnpkg.com/@typescript-eslint/scope-manager/-/scope-manager-5.27.1.tgz#4d1504392d01fe5f76f4a5825991ec78b7b7894d" + integrity sha512-fQEOSa/QroWE6fAEg+bJxtRZJTH8NTskggybogHt4H9Da8zd4cJji76gA5SBlR0MgtwF7rebxTbDKB49YUCpAg== dependencies: - "@typescript-eslint/types" "5.26.0" - "@typescript-eslint/visitor-keys" "5.26.0" + "@typescript-eslint/types" "5.27.1" + "@typescript-eslint/visitor-keys" "5.27.1" -"@typescript-eslint/type-utils@5.26.0": - version "5.26.0" - resolved "https://registry.yarnpkg.com/@typescript-eslint/type-utils/-/type-utils-5.26.0.tgz#937dee97702361744a3815c58991acf078230013" - integrity sha512-7ccbUVWGLmcRDSA1+ADkDBl5fP87EJt0fnijsMFTVHXKGduYMgienC/i3QwoVhDADUAPoytgjbZbCOMj4TY55A== +"@typescript-eslint/type-utils@5.27.1": + version "5.27.1" + resolved "https://registry.yarnpkg.com/@typescript-eslint/type-utils/-/type-utils-5.27.1.tgz#369f695199f74c1876e395ebea202582eb1d4166" + integrity sha512-+UC1vVUWaDHRnC2cQrCJ4QtVjpjjCgjNFpg8b03nERmkHv9JV9X5M19D7UFMd+/G7T/sgFwX2pGmWK38rqyvXw== dependencies: - "@typescript-eslint/utils" "5.26.0" + "@typescript-eslint/utils" "5.27.1" debug "^4.3.4" tsutils "^3.21.0" -"@typescript-eslint/types@5.26.0": - version "5.26.0" - resolved "https://registry.yarnpkg.com/@typescript-eslint/types/-/types-5.26.0.tgz#cb204bb154d3c103d9cc4d225f311b08219469f3" - integrity sha512-8794JZFE1RN4XaExLWLI2oSXsVImNkl79PzTOOWt9h0UHROwJedNOD2IJyfL0NbddFllcktGIO2aOu10avQQyA== +"@typescript-eslint/types@5.27.1": + version "5.27.1" + resolved "https://registry.yarnpkg.com/@typescript-eslint/types/-/types-5.27.1.tgz#34e3e629501349d38be6ae97841298c03a6ffbf1" + integrity sha512-LgogNVkBhCTZU/m8XgEYIWICD6m4dmEDbKXESCbqOXfKZxRKeqpiJXQIErv66sdopRKZPo5l32ymNqibYEH/xg== -"@typescript-eslint/typescript-estree@5.26.0": - version "5.26.0" - resolved "https://registry.yarnpkg.com/@typescript-eslint/typescript-estree/-/typescript-estree-5.26.0.tgz#16cbceedb0011c2ed4f607255f3ee1e6e43b88c3" - integrity sha512-EyGpw6eQDsfD6jIqmXP3rU5oHScZ51tL/cZgFbFBvWuCwrIptl+oueUZzSmLtxFuSOQ9vDcJIs+279gnJkfd1w== +"@typescript-eslint/typescript-estree@5.27.1": + version "5.27.1" + resolved "https://registry.yarnpkg.com/@typescript-eslint/typescript-estree/-/typescript-estree-5.27.1.tgz#7621ee78607331821c16fffc21fc7a452d7bc808" + integrity sha512-DnZvvq3TAJ5ke+hk0LklvxwYsnXpRdqUY5gaVS0D4raKtbznPz71UJGnPTHEFo0GDxqLOLdMkkmVZjSpET1hFw== dependencies: - "@typescript-eslint/types" "5.26.0" - "@typescript-eslint/visitor-keys" "5.26.0" + "@typescript-eslint/types" "5.27.1" + "@typescript-eslint/visitor-keys" "5.27.1" debug "^4.3.4" globby "^11.1.0" is-glob "^4.0.3" semver "^7.3.7" tsutils "^3.21.0" -"@typescript-eslint/utils@5.26.0", "@typescript-eslint/utils@^5.10.0", "@typescript-eslint/utils@^5.26.0": - version "5.26.0" - resolved "https://registry.yarnpkg.com/@typescript-eslint/utils/-/utils-5.26.0.tgz#896b8480eb124096e99c8b240460bb4298afcfb4" - integrity sha512-PJFwcTq2Pt4AMOKfe3zQOdez6InIDOjUJJD3v3LyEtxHGVVRK3Vo7Dd923t/4M9hSH2q2CLvcTdxlLPjcIk3eg== +"@typescript-eslint/utils@5.27.1", "@typescript-eslint/utils@^5.10.0", "@typescript-eslint/utils@^5.27.1": + version "5.27.1" + resolved "https://registry.yarnpkg.com/@typescript-eslint/utils/-/utils-5.27.1.tgz#b4678b68a94bc3b85bf08f243812a6868ac5128f" + integrity sha512-mZ9WEn1ZLDaVrhRaYgzbkXBkTPghPFsup8zDbbsYTxC5OmqrFE7skkKS/sraVsLP3TcT3Ki5CSyEFBRkLH/H/w== dependencies: "@types/json-schema" "^7.0.9" - "@typescript-eslint/scope-manager" "5.26.0" - "@typescript-eslint/types" "5.26.0" - "@typescript-eslint/typescript-estree" "5.26.0" + "@typescript-eslint/scope-manager" "5.27.1" + "@typescript-eslint/types" "5.27.1" + "@typescript-eslint/typescript-estree" "5.27.1" eslint-scope "^5.1.1" eslint-utils "^3.0.0" -"@typescript-eslint/visitor-keys@5.26.0": - version "5.26.0" - resolved "https://registry.yarnpkg.com/@typescript-eslint/visitor-keys/-/visitor-keys-5.26.0.tgz#7195f756e367f789c0e83035297c45b417b57f57" - integrity sha512-wei+ffqHanYDOQgg/fS6Hcar6wAWv0CUPQ3TZzOWd2BLfgP539rb49bwua8WRAs7R6kOSLn82rfEu2ro6Llt8Q== +"@typescript-eslint/visitor-keys@5.27.1": + version "5.27.1" + resolved "https://registry.yarnpkg.com/@typescript-eslint/visitor-keys/-/visitor-keys-5.27.1.tgz#05a62666f2a89769dac2e6baa48f74e8472983af" + integrity sha512-xYs6ffo01nhdJgPieyk7HAOpjhTsx7r/oB9LWEhwAXgwn33tkr+W8DI2ChboqhZlC4q3TC6geDYPoiX8ROqyOQ== dependencies: - "@typescript-eslint/types" "5.26.0" + "@typescript-eslint/types" "5.27.1" eslint-visitor-keys "^3.3.0" "@webassemblyjs/ast@1.11.1": @@ -4440,9 +4459,9 @@ are-we-there-yet@~1.1.2: readable-stream "^2.0.6" arg@^5.0.0: - version "5.0.1" - resolved "https://registry.yarnpkg.com/arg/-/arg-5.0.1.tgz#eb0c9a8f77786cad2af8ff2b862899842d7b6adb" - integrity sha512-e0hDa9H2Z9AwFkk2qDlwhoMYE4eToKarchkQHovNdLTCYMHZHeRjI71crOh+dio4K6u1IcwubQqo79Ga4CyAQA== + version "5.0.2" + resolved "https://registry.yarnpkg.com/arg/-/arg-5.0.2.tgz#c81433cc427c92c4dcf4865142dbca6f15acd59c" + integrity sha512-PYjyFOLKQ9y57JvQ6QLo8dAgNqswh8M1RMJYdQduT6xbWSgK36P/Z/v+p888pM69jMMfS8Xd8F6I1kQ/I9HUGg== argparse@^1.0.7: version "1.0.10" @@ -4583,9 +4602,9 @@ astral-regex@^2.0.0: integrity sha512-Z7tMw1ytTXt5jqMcOP+OQteU1VuNK9Y02uuJtKQ1Sv69jXQKKg5cibLwGJow8yzZP+eAc18EmLGPal0bp36rvQ== async@^3.2.3: - version "3.2.3" - resolved "https://registry.yarnpkg.com/async/-/async-3.2.3.tgz#ac53dafd3f4720ee9e8a160628f18ea91df196c9" - integrity sha512-spZRyzKL5l5BZQrr/6m/SqFdBN0q3OCI0f9rjfBzCMBIP4p75P620rR3gTmaksNOhmzgdxcaxdNfMy6anrbM0g== + version "3.2.4" + resolved "https://registry.yarnpkg.com/async/-/async-3.2.4.tgz#2d22e00f8cddeb5fde5dd33522b56d1cf569a81c" + integrity sha512-iAB+JbDEGXhyIUavoDl9WP/Jj106Kz9DEn1DPgYw5ruDn0e3Wgi3sKFm55sASdGBNOQB8F59d9qQ7deqrHA8wQ== asynckit@^0.4.0: version "0.4.0" @@ -4643,15 +4662,15 @@ babel-core@^7.0.0-bridge.0: resolved "https://registry.yarnpkg.com/babel-core/-/babel-core-7.0.0-bridge.0.tgz#95a492ddd90f9b4e9a4a1da14eb335b87b634ece" integrity sha512-poPX9mZH/5CSanm50Q+1toVci6pv5KSRv/5TWCwtzQS5XEwn40BcCrgIeMFWP9CKKIniKXNxoIOnOq4VVlGXhg== -babel-jest@^28.1.0: - version "28.1.0" - resolved "https://registry.yarnpkg.com/babel-jest/-/babel-jest-28.1.0.tgz#95a67f8e2e7c0042e7b3ad3951b8af41a533b5ea" - integrity sha512-zNKk0yhDZ6QUwfxh9k07GII6siNGMJWVUU49gmFj5gfdqDKLqa2RArXOF2CODp4Dr7dLxN2cvAV+667dGJ4b4w== +babel-jest@^28.1.1: + version "28.1.1" + resolved "https://registry.yarnpkg.com/babel-jest/-/babel-jest-28.1.1.tgz#2a3a4ae50964695b2d694ccffe4bec537c5a3586" + integrity sha512-MEt0263viUdAkTq5D7upHPNxvt4n9uLUGa6pPz3WviNBMtOmStb1lIXS3QobnoqM+qnH+vr4EKlvhe8QcmxIYw== dependencies: - "@jest/transform" "^28.1.0" + "@jest/transform" "^28.1.1" "@types/babel__core" "^7.1.14" babel-plugin-istanbul "^6.1.1" - babel-preset-jest "^28.0.2" + babel-preset-jest "^28.1.1" chalk "^4.0.0" graceful-fs "^4.2.9" slash "^3.0.0" @@ -4699,10 +4718,10 @@ babel-plugin-istanbul@^6.1.1: istanbul-lib-instrument "^5.0.4" test-exclude "^6.0.0" -babel-plugin-jest-hoist@^28.0.2: - version "28.0.2" - resolved "https://registry.yarnpkg.com/babel-plugin-jest-hoist/-/babel-plugin-jest-hoist-28.0.2.tgz#9307d03a633be6fc4b1a6bc5c3a87e22bd01dd3b" - integrity sha512-Kizhn/ZL+68ZQHxSnHyuvJv8IchXD62KQxV77TBDV/xoBFBOfgRAk97GNs6hXdTTCiVES9nB2I6+7MXXrk5llQ== +babel-plugin-jest-hoist@^28.1.1: + version "28.1.1" + resolved "https://registry.yarnpkg.com/babel-plugin-jest-hoist/-/babel-plugin-jest-hoist-28.1.1.tgz#5e055cdcc47894f28341f87f5e35aad2df680b11" + integrity sha512-NovGCy5Hn25uMJSAU8FaHqzs13cFoOI4lhIujiepssjCKRsAo3TA734RDWSGxuFTsUJXerYOqQQodlxgmtqbzw== dependencies: "@babel/template" "^7.3.3" "@babel/types" "^7.3.3" @@ -4751,12 +4770,12 @@ babel-preset-current-node-syntax@^1.0.0: "@babel/plugin-syntax-optional-chaining" "^7.8.3" "@babel/plugin-syntax-top-level-await" "^7.8.3" -babel-preset-jest@^28.0.2: - version "28.0.2" - resolved "https://registry.yarnpkg.com/babel-preset-jest/-/babel-preset-jest-28.0.2.tgz#d8210fe4e46c1017e9fa13d7794b166e93aa9f89" - integrity sha512-sYzXIdgIXXroJTFeB3S6sNDWtlJ2dllCdTEsnZ65ACrMojj3hVNFRmnJ1HZtomGi+Be7aqpY/HJ92fr8OhKVkQ== +babel-preset-jest@^28.1.1: + version "28.1.1" + resolved "https://registry.yarnpkg.com/babel-preset-jest/-/babel-preset-jest-28.1.1.tgz#5b6e5e69f963eb2d70f739c607b8f723c0ee75e4" + integrity sha512-FCq9Oud0ReTeWtcneYf/48981aTfXYuB9gbU4rBNNJVBSQ6ssv7E6v/qvbBxtOWwZFXjLZwpg+W3q7J6vhH25g== dependencies: - babel-plugin-jest-hoist "^28.0.2" + babel-plugin-jest-hoist "^28.1.1" babel-preset-current-node-syntax "^1.0.0" bail@^1.0.0: @@ -4856,11 +4875,6 @@ bl@^4.0.3: inherits "^2.0.4" readable-stream "^3.4.0" -bluebird@^3.7.1: - version "3.7.2" - resolved "https://registry.yarnpkg.com/bluebird/-/bluebird-3.7.2.tgz#9f229c15be272454ffa973ace0dbee79a1b0c36f" - integrity sha512-XpNj6GDQzdfW+r2Wnn7xiSAd7TM3jzkxGXBGTtWKuSXv1xUV+azxAm8jdWZN06QTQk+2N2XB9jRDkvbmQmcRtg== - bluebird@~3.4.1: version "3.4.7" resolved "https://registry.yarnpkg.com/bluebird/-/bluebird-3.4.7.tgz#f72d760be09b7f76d08ed8fae98b289a8d05fab3" @@ -4885,16 +4899,16 @@ body-parser@1.20.0: unpipe "1.0.0" bonjour-service@^1.0.11: - version "1.0.12" - resolved "https://registry.yarnpkg.com/bonjour-service/-/bonjour-service-1.0.12.tgz#28fbd4683f5f2e36feedb833e24ba661cac960c3" - integrity sha512-pMmguXYCu63Ug37DluMKEHdxc+aaIf/ay4YbF8Gxtba+9d3u+rmEWy61VK3Z3hp8Rskok3BunHYnG0dUHAsblw== + version "1.0.13" + resolved "https://registry.yarnpkg.com/bonjour-service/-/bonjour-service-1.0.13.tgz#4ac003dc1626023252d58adf2946f57e5da450c1" + integrity sha512-LWKRU/7EqDUC9CTAQtuZl5HzBALoCYwtLhffW3et7vZMwv3bWLpJf8bRYlMD5OCcDpTfnPgNCV4yo9ZIaJGMiA== dependencies: array-flatten "^2.1.2" dns-equal "^1.0.0" fast-deep-equal "^3.1.3" - multicast-dns "^7.2.4" + multicast-dns "^7.2.5" -boolbase@^1.0.0, boolbase@~1.0.0: +boolbase@^1.0.0: version "1.0.0" resolved "https://registry.yarnpkg.com/boolbase/-/boolbase-1.0.0.tgz#68dff5fbe60c51eb37725ea9e3ed310dcc1e776e" integrity sha512-JZOSA7Mo9sNGB8+UjSgzdLtokWAky1zbztM3WRLCbZ70/3cTANmQmOdR7y2g+J0e2WXywy1yS468tY+IruqEww== @@ -4985,14 +4999,14 @@ browser-process-hrtime@^1.0.0: integrity sha512-9o5UecI3GhkpM6DrXr69PblIuWxPKk9Y0jHBRhdocZ2y7YECBFCsHm79Pr3OyR2AvjhDkabFJaDJMYRazHgsow== browserslist@^4.0.0, browserslist@^4.14.5, browserslist@^4.16.6, browserslist@^4.18.1, browserslist@^4.20.2, browserslist@^4.20.3: - version "4.20.3" - resolved "https://registry.yarnpkg.com/browserslist/-/browserslist-4.20.3.tgz#eb7572f49ec430e054f56d52ff0ebe9be915f8bf" - integrity sha512-NBhymBQl1zM0Y5dQT/O+xiLP9/rzOIQdKM/eMJBAq7yBgaB6krIYLGejrwVYnSHZdqjscB1SPuAjHwxjvN6Wdg== + version "4.20.4" + resolved "https://registry.yarnpkg.com/browserslist/-/browserslist-4.20.4.tgz#98096c9042af689ee1e0271333dbc564b8ce4477" + integrity sha512-ok1d+1WpnU24XYN7oC3QWgTyMhY/avPJ/r9T00xxvUOIparA/gc+UPUMaod3i+G6s+nI2nUb9xZ5k794uIwShw== dependencies: - caniuse-lite "^1.0.30001332" - electron-to-chromium "^1.4.118" + caniuse-lite "^1.0.30001349" + electron-to-chromium "^1.4.147" escalade "^3.1.1" - node-releases "^2.0.3" + node-releases "^2.0.5" picocolors "^1.0.0" bser@2.1.1: @@ -5099,9 +5113,9 @@ cacache@^15.0.5, cacache@^15.2.0: unique-filename "^1.1.1" cacache@^16.0.0, cacache@^16.0.6, cacache@^16.1.0: - version "16.1.0" - resolved "https://registry.yarnpkg.com/cacache/-/cacache-16.1.0.tgz#87a6bae558a511c9cb2a13768073e240ca76153a" - integrity sha512-Pk4aQkwCW82A4jGKFvcGkQFqZcMspfP9YWq9Pr87/ldDvlWf718zeI6KWCdKt/jeihu6BytHRUicJPB1K2k8EQ== + version "16.1.1" + resolved "https://registry.yarnpkg.com/cacache/-/cacache-16.1.1.tgz#4e79fb91d3efffe0630d5ad32db55cc1b870669c" + integrity sha512-VDKN+LHyCQXaaYZ7rA/qtkURU+/yYhviUdvqEv2LT6QPZU8jpyzEkEVAcKlKLt5dJ5BRp11ym8lo3NKLluEPLg== dependencies: "@npmcli/fs" "^2.1.0" "@npmcli/move-file" "^2.0.0" @@ -5205,12 +5219,12 @@ caniuse-api@^3.0.0: lodash.memoize "^4.1.2" lodash.uniq "^4.5.0" -caniuse-lite@^1.0.0, caniuse-lite@^1.0.30001332, caniuse-lite@^1.0.30001335: - version "1.0.30001344" - resolved "https://registry.yarnpkg.com/caniuse-lite/-/caniuse-lite-1.0.30001344.tgz#8a1e7fdc4db9c2ec79a05e9fd68eb93a761888bb" - integrity sha512-0ZFjnlCaXNOAYcV7i+TtdKBp0L/3XEU2MF/x6Du1lrh+SRX4IfzIVL4HNJg5pB2PmFb8rszIGyOvsZnqqRoc2g== +caniuse-lite@^1.0.0, caniuse-lite@^1.0.30001335, caniuse-lite@^1.0.30001349: + version "1.0.30001352" + resolved "https://registry.yarnpkg.com/caniuse-lite/-/caniuse-lite-1.0.30001352.tgz#cc6f5da3f983979ad1e2cdbae0505dccaa7c6a12" + integrity sha512-GUgH8w6YergqPQDGWhJGt8GDRnY0L/iJVQcU3eJ46GYf52R8tk0Wxp0PymuFVZboJYXGiCqwozAYZNRjVj6IcA== -ccount@^1.0.0, ccount@^1.0.3: +ccount@^1.0.0: version "1.1.0" resolved "https://registry.yarnpkg.com/ccount/-/ccount-1.1.0.tgz#246687debb6014735131be8abab2d93898f8d043" integrity sha512-vlNK021QdI7PNeiUh/lKkC/mNHHfV0m/Ad5JoI0TYtlBnJAslM/JIkm/tGC88bkLIwO6OQ5uV6ztS6kVAtCDlg== @@ -5289,28 +5303,6 @@ cheerio-select@^2.1.0: domhandler "^5.0.3" domutils "^3.0.1" -cheerio@^0.22.0: - version "0.22.0" - resolved "https://registry.yarnpkg.com/cheerio/-/cheerio-0.22.0.tgz#a9baa860a3f9b595a6b81b1a86873121ed3a269e" - integrity sha512-8/MzidM6G/TgRelkzDG13y3Y9LxBjCb+8yOEZ9+wwq5gVF2w2pV0wmHvjfT0RvuxGyR7UEuK36r+yYMbT4uKgA== - dependencies: - css-select "~1.2.0" - dom-serializer "~0.1.0" - entities "~1.1.1" - htmlparser2 "^3.9.1" - lodash.assignin "^4.0.9" - lodash.bind "^4.1.4" - lodash.defaults "^4.0.1" - lodash.filter "^4.4.0" - lodash.flatten "^4.2.0" - lodash.foreach "^4.3.0" - lodash.map "^4.4.0" - lodash.merge "^4.4.0" - lodash.pick "^4.2.1" - lodash.reduce "^4.4.0" - lodash.reject "^4.4.0" - lodash.some "^4.4.0" - 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" @@ -5593,10 +5585,10 @@ colord@^2.9.1, colord@^2.9.2: resolved "https://registry.yarnpkg.com/colord/-/colord-2.9.2.tgz#25e2bacbbaa65991422c07ea209e2089428effb1" integrity sha512-Uqbg+J445nc1TKn4FoDPS6ZZqAvEDnwrH42yo8B40JSOgSLxMZ/gt3h4nmCtPLQeXhjJJkqBx7SCY35WnIixaQ== -colorette@^2.0.10, colorette@^2.0.16: - version "2.0.16" - resolved "https://registry.yarnpkg.com/colorette/-/colorette-2.0.16.tgz#713b9af84fdb000139f04546bd4a93f62a5085da" - integrity sha512-hUewv7oMjCp+wkBv5Rm0v87eJhq4woh5rSR+42YSQJKecCqgIqNkZ6lAlQms/BwHPJA5NKMRlpxPRv0n8HQW6g== +colorette@^2.0.10, colorette@^2.0.16, colorette@^2.0.17: + version "2.0.17" + resolved "https://registry.yarnpkg.com/colorette/-/colorette-2.0.17.tgz#5dd4c0d15e2984b7433cb4a9f2ead45063b80c47" + integrity sha512-hJo+3Bkn0NCHybn9Tu35fIeoOKGOk5OCC32y4Hz2It+qlCO2Q3DeQ1hRn/tDDMQKRYUEzqsl7jbF6dYKjlE60g== columnify@^1.5.4: version "1.6.0" @@ -5653,10 +5645,10 @@ commander@^8.0.0, commander@^8.3.0: resolved "https://registry.yarnpkg.com/commander/-/commander-8.3.0.tgz#4837ea1b2da67b9c616a67afbb0fafee567bca66" integrity sha512-OkTL9umf+He2DZkUq8f8J9of7yL6RJKI24dVITBmNfZBmri9zYZQrKkuXiKhyfPSu8tUhnVBB1iKXevvnlR4Ww== -commander@^9.2.0: - version "9.2.0" - resolved "https://registry.yarnpkg.com/commander/-/commander-9.2.0.tgz#6e21014b2ed90d8b7c9647230d8b7a94a4a419a9" - integrity sha512-e2i4wANQiSXgnrBlIatyHtP1odfUp0BbV5Y5nEGbxtIrStkEOAAzCUirvLBNXHLr7kwLvJl6V+4V3XV9x7Wd9w== +commander@^9.3.0: + version "9.3.0" + resolved "https://registry.yarnpkg.com/commander/-/commander-9.3.0.tgz#f619114a5a2d2054e0d9ff1b31d5ccf89255e26b" + integrity sha512-hv95iU5uXPbK83mjrJKuZyFM/LBAoCV/XhVGkS5Je6tl7sxr6A0ITMw5WoRV46/UaJ46Nllm3Xt7IaJhXTIkzw== comment-json@^4.2.2: version "4.2.2" @@ -5931,27 +5923,27 @@ copy-webpack-plugin@^11.0.0: serialize-javascript "^6.0.0" core-js-compat@^3.21.0, core-js-compat@^3.22.1: - version "3.22.7" - resolved "https://registry.yarnpkg.com/core-js-compat/-/core-js-compat-3.22.7.tgz#8359eb66ecbf726dd0cfced8e48d5e73f3224239" - integrity sha512-uI9DAQKKiiE/mclIC5g4AjRpio27g+VMRhe6rQoz+q4Wm4L6A/fJhiLtBw+sfOpDG9wZ3O0pxIw7GbfOlBgjOA== + version "3.22.8" + resolved "https://registry.yarnpkg.com/core-js-compat/-/core-js-compat-3.22.8.tgz#46fa34ce1ddf742acd7f95f575f66bbb21e05d62" + integrity sha512-pQnwg4xtuvc2Bs/5zYQPaEYYSuTxsF7LBWF0SvnVhthZo/Qe+rJpcEekrdNK5DWwDJ0gv0oI9NNX5Mppdy0ctg== dependencies: browserslist "^4.20.3" semver "7.0.0" core-js-pure@^3.20.2: - version "3.22.7" - resolved "https://registry.yarnpkg.com/core-js-pure/-/core-js-pure-3.22.7.tgz#f58489d9b309fa7b26486a0f70d4ec19a418084e" - integrity sha512-wTriFxiZI+C8msGeh7fJcbC/a0V8fdInN1oS2eK79DMBGs8iIJiXhtFJCiT3rBa8w6zroHWW3p8ArlujZ/Mz+w== + version "3.22.8" + resolved "https://registry.yarnpkg.com/core-js-pure/-/core-js-pure-3.22.8.tgz#f2157793b58719196ccf9673cc14f3683adc0957" + integrity sha512-bOxbZIy9S5n4OVH63XaLVXZ49QKicjowDx/UELyJ68vxfCRpYsbyh/WNZNfEfAk+ekA8vSjt+gCDpvh672bc3w== core-js@^2.4.1: version "2.6.12" resolved "https://registry.yarnpkg.com/core-js/-/core-js-2.6.12.tgz#d9333dfa7b065e347cc5682219d6f690859cc2ec" integrity sha512-Kb2wC0fvsWfQrgk8HU5lW6U/Lcs8+9aaYcy4ZFc6DDlo4nZ7n70dEgE5rtR0oG6ufKDUnrwfWL1mXR5ljDatrQ== -core-js@^3.22.7: - version "3.22.7" - resolved "https://registry.yarnpkg.com/core-js/-/core-js-3.22.7.tgz#8d6c37f630f6139b8732d10f2c114c3f1d00024f" - integrity sha512-Jt8SReuDKVNZnZEzyEQT5eK6T2RRCXkfTq7Lo09kpm+fHjgGewSbNjV+Wt4yZMhPDdzz2x1ulI5z/w4nxpBseg== +core-js@^3.22.8: + version "3.22.8" + resolved "https://registry.yarnpkg.com/core-js/-/core-js-3.22.8.tgz#23f860b1fe60797cc4f704d76c93fea8a2f60631" + integrity sha512-UoGQ/cfzGYIuiq6Z7vWL1HfkE9U9IZ4Ub+0XSiJTCzvbZzgPA69oDF2f+lgJ6dFFLEdjW5O6svvoKzXX23xFkA== core-util-is@^1.0.3, core-util-is@~1.0.0: version "1.0.3" @@ -6019,71 +6011,71 @@ 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@^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== +cspell-gitignore@^6.1.2: + version "6.1.2" + resolved "https://registry.yarnpkg.com/cspell-gitignore/-/cspell-gitignore-6.1.2.tgz#9ce6f6465c1e800d7d0bd9eec432e59ebed0c9c5" + integrity sha512-9P4ltD5DF/Dogz/+IgW8BZjqvgbOghg2OKk165+ilKgoQc73zHQy8bZRdJsDo2NBevmT8Z9RswEN37pQvzmMqQ== dependencies: - cspell-glob "^6.0.0" + cspell-glob "^6.1.2" find-up "^5.0.0" -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== +cspell-glob@^6.1.2: + version "6.1.2" + resolved "https://registry.yarnpkg.com/cspell-glob/-/cspell-glob-6.1.2.tgz#1081bce9a480f6de61dec7058a6faa31dbff248e" + integrity sha512-+EN4DEyK8ohwZLShPw9vhU6114fnGYi8q4IQAGc5qCCcnMTgb1H3N840YyG+EuP0Q1o3TwMYMA+B+tw4w+yQSg== dependencies: micromatch "^4.0.5" -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-io@^6.1.2: + version "6.1.2" + resolved "https://registry.yarnpkg.com/cspell-io/-/cspell-io-6.1.2.tgz#64fa2b8728532f5e04dc463bfc161a2df93b90bc" + integrity sha512-WVRKjOzB3BgwJPk4hWH19jiqXzbtWGzJ1yNLaB2r3KYCDh+FYT4jVaHb5DWERASahvukb05go7G623FuYeoY3Q== -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== +cspell-lib@^6.1.2: + version "6.1.2" + resolved "https://registry.yarnpkg.com/cspell-lib/-/cspell-lib-6.1.2.tgz#9c61c4501835452ce632c005ece7d07b6a8ee6bc" + integrity sha512-oJVAvxnP6jsiglLIdFy9agO5vfArTQdLweRjkR8SbVPoYQ8vyDfrbQT9J+K+ekKpCvpzKKzjleOJHHwJFeltGQ== dependencies: - "@cspell/cspell-bundled-dicts" "^6.0.0" - "@cspell/cspell-pipe" "^6.0.0" - "@cspell/cspell-types" "^6.0.0" + "@cspell/cspell-bundled-dicts" "^6.1.2" + "@cspell/cspell-pipe" "^6.1.2" + "@cspell/cspell-types" "^6.1.2" clear-module "^4.1.2" comment-json "^4.2.2" configstore "^5.0.1" cosmiconfig "^7.0.1" - cspell-glob "^6.0.0" - cspell-io "^6.0.0" - cspell-trie-lib "^6.0.0" - fast-equals "^3.0.2" + cspell-glob "^6.1.2" + cspell-io "^6.1.2" + cspell-trie-lib "^6.1.2" + fast-equals "^4.0.1" find-up "^5.0.0" fs-extra "^10.1.0" gensequence "^3.1.1" import-fresh "^3.3.0" resolve-from "^5.0.0" resolve-global "^1.0.0" - vscode-languageserver-textdocument "^1.0.4" + vscode-languageserver-textdocument "^1.0.5" vscode-uri "^3.0.3" -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== +cspell-trie-lib@^6.1.2: + version "6.1.2" + resolved "https://registry.yarnpkg.com/cspell-trie-lib/-/cspell-trie-lib-6.1.2.tgz#aaa933b7c7af2b58eff920179cfdaf4e435357ec" + integrity sha512-VQasYB6WYQZz71Uo0Z4K/i6qOZpBqOh0SbKQr6n0lkejnmoAv324SKJqKyXyizWCQQvWDq+ax18bW+KBFNBzxQ== dependencies: - "@cspell/cspell-pipe" "^6.0.0" + "@cspell/cspell-pipe" "^6.1.2" fs-extra "^10.1.0" gensequence "^3.1.1" -cspell@^6.0.0: - version "6.0.0" - resolved "https://registry.yarnpkg.com/cspell/-/cspell-6.0.0.tgz#358da651b061f25f94e52bb1ceae6bfc49c801ba" - integrity sha512-skfNomVlYXGOe4C9wz0O/B8VlZc9GzpW5QDFHaRMYwWEtuyitN5WevuPMc9bkWbVKV8ghn1sXehBzy85V5PXIQ== +cspell@^6.1.2: + version "6.1.2" + resolved "https://registry.yarnpkg.com/cspell/-/cspell-6.1.2.tgz#b17be28dda221867627973840dc83447c84ff537" + integrity sha512-w4lGfzNl3m1dfagyZvr28V1nK/E+y8zoKVlE158JI/iVNGO/R2okrcNB1s+9xXSmYjJ8Xx6dhupO0XxKuagDSQ== dependencies: - "@cspell/cspell-pipe" "^6.0.0" + "@cspell/cspell-pipe" "^6.1.2" chalk "^4.1.2" - commander "^9.2.0" - cspell-gitignore "^6.0.0" - cspell-glob "^6.0.0" - cspell-lib "^6.0.0" + commander "^9.3.0" + cspell-gitignore "^6.1.2" + cspell-glob "^6.1.2" + cspell-lib "^6.1.2" fast-json-stable-stringify "^2.1.0" file-entry-cache "^6.0.1" fs-extra "^10.1.0" @@ -6095,14 +6087,14 @@ cspell@^6.0.0: vscode-uri "^3.0.3" css-declaration-sorter@^6.2.2: - version "6.2.2" - resolved "https://registry.yarnpkg.com/css-declaration-sorter/-/css-declaration-sorter-6.2.2.tgz#bfd2f6f50002d6a3ae779a87d3a0c5d5b10e0f02" - integrity sha512-Ufadglr88ZLsrvS11gjeu/40Lw74D9Am/Jpr3LlYm5Q4ZP5KdlUhG+6u2EjyXeZcxmZ2h1ebCKngDjolpeLHpg== + version "6.3.0" + resolved "https://registry.yarnpkg.com/css-declaration-sorter/-/css-declaration-sorter-6.3.0.tgz#72ebd995c8f4532ff0036631f7365cce9759df14" + integrity sha512-OGT677UGHJTAVMRhPO+HJ4oKln3wkBTwtDFH0ojbqm+MJm6xuDMHp2nkhh/ThaBqq20IbraBQSWKfSLNHQO9Og== -css-functions-list@^3.0.1: - version "3.0.1" - resolved "https://registry.yarnpkg.com/css-functions-list/-/css-functions-list-3.0.1.tgz#1460df7fb584d1692c30b105151dbb988c8094f9" - integrity sha512-PriDuifDt4u4rkDgnqRCLnjfMatufLmWNfQnGCq34xZwpY3oabwhB9SqRBmuvWUgndbemCFlKqg+nO7C2q0SBw== +css-functions-list@^3.1.0: + version "3.1.0" + resolved "https://registry.yarnpkg.com/css-functions-list/-/css-functions-list-3.1.0.tgz#cf5b09f835ad91a00e5959bcfc627cd498e1321b" + integrity sha512-/9lCvYZaUbBGvYUgYGFJ4dcYiyqdhSjG7IPVluoV8A1ILjkF7ilmhp1OGUz8n+nmBcu0RNrQAzgD8B6FJbrt2w== css-loader@^6.7.1: version "6.7.1" @@ -6152,16 +6144,6 @@ css-select@^5.1.0: 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" - integrity sha512-dUQOBoqdR7QwV90WysXPLXG5LO7nhYBgiWVfxF80DKPF8zx1t/pUd2FYy73emg3zrjtM6dzmYgbHKfV2rxiHQA== - dependencies: - boolbase "~1.0.0" - css-what "2.1" - domutils "1.5.1" - nth-check "~1.0.1" - css-tree@^1.1.2, css-tree@^1.1.3: version "1.1.3" resolved "https://registry.yarnpkg.com/css-tree/-/css-tree-1.1.3.tgz#eb4870fb6fd7707327ec95c2ff2ab09b5e8db91d" @@ -6170,11 +6152,6 @@ css-tree@^1.1.2, css-tree@^1.1.3: mdn-data "2.0.14" source-map "^0.6.1" -css-what@2.1: - version "2.1.3" - 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.1.0: version "6.1.0" resolved "https://registry.yarnpkg.com/css-what/-/css-what-6.1.0.tgz#fb5effcf76f1ddea2c81bdfaa4de44e79bac70f4" @@ -6185,38 +6162,38 @@ 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.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== +cssnano-preset-advanced@^5.3.6: + version "5.3.7" + resolved "https://registry.yarnpkg.com/cssnano-preset-advanced/-/cssnano-preset-advanced-5.3.7.tgz#5c00fd6603ab1b2d1dee5540bd3a5931ab275d36" + integrity sha512-VNOdTMRA60KhaURZhnkTGeluHQBHWDMwY7TIDu1Qydf88X6k8xZbV2I+Wlm8JRaj2oi18xvoIOAW17JneoZzEg== dependencies: autoprefixer "^10.3.7" - cssnano-preset-default "^5.2.9" + cssnano-preset-default "^5.2.11" 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.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== +cssnano-preset-default@^5.2.11: + version "5.2.11" + resolved "https://registry.yarnpkg.com/cssnano-preset-default/-/cssnano-preset-default-5.2.11.tgz#28350471bc1af9df14052472b61340347f453a53" + integrity sha512-4PadR1NtuaIK8MvLNuY7MznK4WJteldGlzCiMaaTiOUP+apeiIvUDIXykzUOoqgOOUAHrU64ncdD90NfZR3LSQ== 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.1" - postcss-discard-comments "^5.1.1" + postcss-convert-values "^5.1.2" + postcss-discard-comments "^5.1.2" postcss-discard-duplicates "^5.1.0" postcss-discard-empty "^5.1.1" postcss-discard-overridden "^5.1.0" postcss-merge-longhand "^5.1.5" - postcss-merge-rules "^5.1.1" + postcss-merge-rules "^5.1.2" postcss-minify-font-values "^5.1.0" postcss-minify-gradients "^5.1.1" postcss-minify-params "^5.1.3" - postcss-minify-selectors "^5.2.0" + postcss-minify-selectors "^5.2.1" postcss-normalize-charset "^5.1.0" postcss-normalize-display-values "^5.1.0" postcss-normalize-positions "^5.1.0" @@ -6226,7 +6203,7 @@ cssnano-preset-default@^5.2.9: postcss-normalize-unicode "^5.1.0" postcss-normalize-url "^5.1.0" postcss-normalize-whitespace "^5.1.1" - postcss-ordered-values "^5.1.1" + postcss-ordered-values "^5.1.2" postcss-reduce-initial "^5.1.0" postcss-reduce-transforms "^5.1.0" postcss-svgo "^5.1.0" @@ -6237,12 +6214,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.1.8, cssnano@^5.1.9: - version "5.1.9" - resolved "https://registry.yarnpkg.com/cssnano/-/cssnano-5.1.9.tgz#e6cb286c4907cbd55678eb315837a21008be21be" - integrity sha512-hctQHIIeDrfMjq0bQhoVmRVaSeNNOGxkvkKVOcKpJzLr09wlRrZWH4GaYudp0aszpW8wJeaO5/yBmID9n7DNCg== +cssnano@^5.1.11, cssnano@^5.1.8: + version "5.1.11" + resolved "https://registry.yarnpkg.com/cssnano/-/cssnano-5.1.11.tgz#3bb003380718c7948ce3813493370e8946caf04b" + integrity sha512-2nx+O6LvewPo5EBtYrKc8762mMkZRk9cMGIOP4UlkmxHm7ObxH+zvsJJ+qLwPkUc4/yumL/qJkavYi9NlodWIQ== dependencies: - cssnano-preset-default "^5.2.9" + cssnano-preset-default "^5.2.11" lilconfig "^2.0.3" yaml "^1.10.2" @@ -6541,10 +6518,10 @@ diff-sequences@^27.5.1: resolved "https://registry.yarnpkg.com/diff-sequences/-/diff-sequences-27.5.1.tgz#eaecc0d327fd68c8d9672a1e64ab8dccb2ef5327" integrity sha512-k1gCAXAsNgLwEL+Y8Wvl+M6oEFj5bgazfZULpS5CneoPPXRaCCW7dm+q21Ky2VEE5X+VeRDBVg1Pcvvsr4TtNQ== -diff-sequences@^28.0.2: - version "28.0.2" - resolved "https://registry.yarnpkg.com/diff-sequences/-/diff-sequences-28.0.2.tgz#40f8d4ffa081acbd8902ba35c798458d0ff1af41" - integrity sha512-YtEoNynLDFCRznv/XDalsKGSZDoj0U5kLnXvY0JSq3nBboRrZXjD81+eSiwi+nzcZDwedMmcowcxNwwgFW23mQ== +diff-sequences@^28.1.1: + version "28.1.1" + resolved "https://registry.yarnpkg.com/diff-sequences/-/diff-sequences-28.1.1.tgz#9989dc731266dc2903457a70e996f3a041913ac6" + integrity sha512-FU0iFaH/E23a+a718l8Qa/19bF9p06kgE0KipMOMadwa3SjnaElKzPaUC0vnibs6/B/9ni97s61mcejk8W1fQw== dir-glob@^3.0.1: version "3.0.1" @@ -6594,14 +6571,6 @@ dom-iterator@^1.0.0: component-props "1.1.1" component-xor "0.0.4" -dom-serializer@0: - version "0.2.2" - resolved "https://registry.yarnpkg.com/dom-serializer/-/dom-serializer-0.2.2.tgz#1afb81f533717175d478655debc5e332d9f9bb51" - integrity sha512-2/xPb3ORsQ42nHYiSunXkDjPLBaEj/xTwUO4B7XCZQTRk7EBtTOPaygh10YAAh2OI1Qrp6NWfpAhzswj0ydt9g== - dependencies: - domelementtype "^2.0.1" - entities "^2.0.0" - dom-serializer@^1.0.1: version "1.4.1" resolved "https://registry.yarnpkg.com/dom-serializer/-/dom-serializer-1.4.1.tgz#de5d41b1aea290215dc45a6dae8adcf1d32e2d30" @@ -6620,19 +6589,6 @@ dom-serializer@^2.0.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" - integrity sha512-l0IU0pPzLWSHBcieZbpOKgkIn3ts3vAh7ZuFyXNwJxJXk/c4Gwj9xaTJwIDVQCXawWD0qb3IzMGH5rglQaO0XA== - dependencies: - domelementtype "^1.3.0" - entities "^1.1.1" - -domelementtype@1, domelementtype@^1.3.0, domelementtype@^1.3.1: - version "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.3.0: version "2.3.0" resolved "https://registry.yarnpkg.com/domelementtype/-/domelementtype-2.3.0.tgz#5c45e8e869952626331d7aab326d01daf65d589d" @@ -6645,13 +6601,6 @@ domexception@^4.0.0: dependencies: webidl-conversions "^7.0.0" -domhandler@^2.3.0: - version "2.4.2" - resolved "https://registry.yarnpkg.com/domhandler/-/domhandler-2.4.2.tgz#8805097e933d65e85546f726d60f5eb88b44f803" - integrity sha512-JiK04h0Ht5u/80fdLMCEmV4zkNh2BcoMFBmZ/91WtYZ8qVXSKjiw7fXMgFPnHcSZgOo3XdinHvmnDUeMf5R4wA== - dependencies: - domelementtype "1" - domhandler@^4.0.0, domhandler@^4.2.0, domhandler@^4.3.1: version "4.3.1" resolved "https://registry.yarnpkg.com/domhandler/-/domhandler-4.3.1.tgz#8d792033416f59d68bc03a5aa7b018c1ca89279c" @@ -6666,22 +6615,6 @@ domhandler@^5.0.1, domhandler@^5.0.2, domhandler@^5.0.3: 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" - integrity sha512-gSu5Oi/I+3wDENBsOWBiRK1eoGxcywYSqg3rR960/+EfY0CF4EX1VPkgHOZ3WiS/Jg2DtliF6BhWcHlfpYUcGw== - dependencies: - dom-serializer "0" - domelementtype "1" - -domutils@^1.5.1: - version "1.7.0" - resolved "https://registry.yarnpkg.com/domutils/-/domutils-1.7.0.tgz#56ea341e834e06e6748af7a1cb25da67ea9f8c2a" - integrity sha512-Lgd2XcJ/NjEw+7tFvfKxOzCYKZsdct5lczQ2ZaQY8Djz7pfAD3Gbp8ySJWtreII/vDlMVmxwa6pHmdxIYgttDg== - dependencies: - dom-serializer "0" - domelementtype "1" - domutils@^2.5.2, domutils@^2.8.0: version "2.8.0" resolved "https://registry.yarnpkg.com/domutils/-/domutils-2.8.0.tgz#4437def5db6e2d1f5d6ee859bd95ca7d02048135" @@ -6756,10 +6689,10 @@ ejs@^3.1.6: dependencies: jake "^10.8.5" -electron-to-chromium@^1.4.118: - version "1.4.140" - resolved "https://registry.yarnpkg.com/electron-to-chromium/-/electron-to-chromium-1.4.140.tgz#1b5836b7244aff341a11c8efd63dfe003dee4a19" - integrity sha512-NLz5va823QfJBYOO/hLV4AfU4Crmkl/6Hl2pH3qdJcmi0ySZ3YTWHxOlDm3uJOFBEPy3pIhu8gKQo6prQTWKKA== +electron-to-chromium@^1.4.147: + version "1.4.152" + resolved "https://registry.yarnpkg.com/electron-to-chromium/-/electron-to-chromium-1.4.152.tgz#7dedbe8f3dc1c597088982a203f392e60f7ee90a" + integrity sha512-jk4Ju5SGZAQQJ1iI4Rgru7dDlvkQPLpNPWH9gIZmwCD4YteA5Bbk1xPcPDUf5jUYs3e1e80RXdi8XgKQZaigeg== emittery@^0.10.2: version "0.10.2" @@ -6813,11 +6746,6 @@ enhanced-resolve@^5.9.3: graceful-fs "^4.2.4" tapable "^2.2.0" -entities@^1.1.1, entities@~1.1.1: - version "1.1.2" - resolved "https://registry.yarnpkg.com/entities/-/entities-1.1.2.tgz#bdfa735299664dfafd34529ed4f8522a275fea56" - integrity sha512-f2LZMYl1Fzu7YSBKg+RoROelpOaNrcGmE9AZubeDfrCEia483oW4MI4VyFd5VNHIgQ/7qm1I0wUHK1eJnn2y2w== - entities@^2.0.0: version "2.2.0" resolved "https://registry.yarnpkg.com/entities/-/entities-2.2.0.tgz#098dc90ebb83d8dffa089d55256b351d34c4da55" @@ -7019,10 +6947,10 @@ eslint-plugin-import@^2.26.0: resolve "^1.22.0" tsconfig-paths "^3.14.1" -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== +eslint-plugin-jest@^26.5.3: + version "26.5.3" + resolved "https://registry.yarnpkg.com/eslint-plugin-jest/-/eslint-plugin-jest-26.5.3.tgz#a3ceeaf4a757878342b8b00eca92379b246e5505" + integrity sha512-sICclUqJQnR1bFRZGLN2jnSVsYOsmPYYnroGCIMVSvTS3y8XR3yjzy1EcTQmk6typ5pRgyIWzbjqxK6cZHEZuQ== dependencies: "@typescript-eslint/utils" "^5.10.0" @@ -7116,10 +7044,10 @@ eslint-visitor-keys@^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.16.0: - version "8.16.0" - resolved "https://registry.yarnpkg.com/eslint/-/eslint-8.16.0.tgz#6d936e2d524599f2a86c708483b4c372c5d3bbae" - integrity sha512-MBndsoXY/PeVTDJeWsYj7kLZ5hQpJOfMYLsF6LicLHQWbRDG19lK5jOix4DPl8yY4SUFcE3txy86OzFLWT+yoA== +eslint@^8.17.0: + version "8.17.0" + resolved "https://registry.yarnpkg.com/eslint/-/eslint-8.17.0.tgz#1cfc4b6b6912f77d24b874ca1506b0fe09328c21" + integrity sha512-gq0m0BTJfci60Fz4nczYxNAlED+sMcihltndR8t9t1evnU/azx53x3t2UHXC/uRjcbvRw/XctpaNygSTcQD+Iw== dependencies: "@eslint/eslintrc" "^1.3.0" "@humanwhocodes/config-array" "^0.9.2" @@ -7233,7 +7161,7 @@ events@^3.2.0: resolved "https://registry.yarnpkg.com/events/-/events-3.3.0.tgz#31a95ad0a924e2d2c419a813aeb2c4e878ea7400" integrity sha512-mQw+2fkQbALzQ7V0MY0IqdnXNOeTtP4r0lN9z7AAawCXgqea7bDii20AYrIBrFd/Hx0M2Ocz6S111CaFkUcb0Q== -execa@^5.0.0, execa@^5.1.1: +execa@^5.0.0: version "5.1.1" resolved "https://registry.yarnpkg.com/execa/-/execa-5.1.1.tgz#f80ad9cbf4298f7bd1d4c9555c21e93741c411dd" integrity sha512-8uSpZZocAZRBAPIEINJj3Lo9HyGitllczc27Eh5YYojjMFMn8yHMDMaUHE2Jqfq05D/wucwI4JGURyXt1vchyg== @@ -7248,6 +7176,21 @@ execa@^5.0.0, execa@^5.1.1: signal-exit "^3.0.3" strip-final-newline "^2.0.0" +execa@^6.1.0: + version "6.1.0" + resolved "https://registry.yarnpkg.com/execa/-/execa-6.1.0.tgz#cea16dee211ff011246556388effa0818394fb20" + integrity sha512-QVWlX2e50heYJcCPG0iWtf8r0xjEYfz/OYLGDYH+IyjWezzPNxz63qNFOu0l4YftGWuizFVZHHs8PrLU5p2IDA== + dependencies: + cross-spawn "^7.0.3" + get-stream "^6.0.1" + human-signals "^3.0.1" + is-stream "^3.0.0" + merge-stream "^2.0.0" + npm-run-path "^5.1.0" + onetime "^6.0.0" + signal-exit "^3.0.7" + strip-final-newline "^3.0.0" + execall@^2.0.0: version "2.0.0" resolved "https://registry.yarnpkg.com/execall/-/execall-2.0.0.tgz#16a06b5fe5099df7d00be5d9c06eecded1663b45" @@ -7278,16 +7221,16 @@ expand-template@^2.0.3: resolved "https://registry.yarnpkg.com/expand-template/-/expand-template-2.0.3.tgz#6e14b3fcee0f3a6340ecb57d2e8918692052a47c" integrity sha512-XYfuKMvj4O35f/pOXLObndIRvyQ+/+6AhODh+OKWj9S9498pHHn/IMszH+gt0fBCRWMNfk1ZSp5x3AifmnI2vg== -expect@^28.1.0: - version "28.1.0" - resolved "https://registry.yarnpkg.com/expect/-/expect-28.1.0.tgz#10e8da64c0850eb8c39a480199f14537f46e8360" - integrity sha512-qFXKl8Pmxk8TBGfaFKRtcQjfXEnKAs+dmlxdwvukJZorwrAabT7M3h8oLOG01I2utEhkmUTi17CHaPBovZsKdw== +expect@^28.1.1: + version "28.1.1" + resolved "https://registry.yarnpkg.com/expect/-/expect-28.1.1.tgz#ca6fff65f6517cf7220c2e805a49c19aea30b420" + integrity sha512-/AANEwGL0tWBwzLNOvO0yUdy2D52jVdNXppOqswC49sxMN2cPWsGCQdzuIf9tj6hHoBQzNvx75JUYuQAckPo3w== dependencies: - "@jest/expect-utils" "^28.1.0" + "@jest/expect-utils" "^28.1.1" jest-get-type "^28.0.2" - jest-matcher-utils "^28.1.0" - jest-message-util "^28.1.0" - jest-util "^28.1.0" + jest-matcher-utils "^28.1.1" + jest-message-util "^28.1.1" + jest-util "^28.1.1" express@^4.17.3: version "4.18.1" @@ -7374,15 +7317,15 @@ fast-deep-equal@^3.1.1, fast-deep-equal@^3.1.3: resolved "https://registry.yarnpkg.com/fast-deep-equal/-/fast-deep-equal-3.1.3.tgz#3a7d56b559d6cbc3eb512325244e619a65c6c525" integrity sha512-f3qQ9oQy9j2AhBe/H9VC91wLmKBCCU/gDOnKNAYG5hswO7BLKj09Hc5HYNz9cGI++xlpDCIgDaitVs03ATR84Q== -fast-equals@^3.0.2: - version "3.0.3" - resolved "https://registry.yarnpkg.com/fast-equals/-/fast-equals-3.0.3.tgz#8e6cb4e51ca1018d87dd41982ef92758b3e4197f" - integrity sha512-NCe8qxnZFARSHGztGMZOO/PC1qa5MIFB5Hp66WdzbCRAz8U8US3bx1UTgLS49efBQPcUtO9gf5oVEY8o7y/7Kg== +fast-equals@^4.0.1: + version "4.0.1" + resolved "https://registry.yarnpkg.com/fast-equals/-/fast-equals-4.0.1.tgz#ff8f92d18f4f4130ce6fbd3748ef714d01cd0893" + integrity sha512-OXqyj3MD0p8Kee16Jz7CbCnXo+5CHKKu4xBh5UhC1NbmMkHn8WScLRy/B2q5UOlWMlNSQJc4mwXW30Lz+JUZJw== fast-folder-size@^1.6.1: - version "1.6.2" - resolved "https://registry.yarnpkg.com/fast-folder-size/-/fast-folder-size-1.6.2.tgz#ec2cca972de6e23a9b32eec76de25af966c5e03d" - integrity sha512-sruYdpIWmLra7avLYJSbyUJuzHOIG5IFi3x4MoP4l2TRja+jTVEvDL8Bo0k/Yu2uk63Zj20ZgBRw8cCOwMkmyA== + version "1.7.0" + resolved "https://registry.yarnpkg.com/fast-folder-size/-/fast-folder-size-1.7.0.tgz#b9bed525c94dd8c610920ddbab0e9370bee4dd49" + integrity sha512-NtU4r7WOKYtU6sinhjgvRw3KoY6fUHp1UVfu6EUiX65HanN/JnZjCYBY+h2J9xLpKti/3UtvyfcKLwvzNkTHOw== dependencies: unzipper "^0.10.11" @@ -7610,9 +7553,9 @@ flatted@^3.1.0: integrity sha512-WIWGi2L3DyTUvUrwRKgGi9TwxQMUEqPOPQBVi71R96jZXJdFskXEmf54BoZaS1kknGODoIGASGEzBUYdyMCBJg== flow-parser@0.*: - version "0.179.0" - resolved "https://registry.yarnpkg.com/flow-parser/-/flow-parser-0.179.0.tgz#595caab8b082b4d424735c97a53216a91c9eb19a" - integrity sha512-M4dEgnvsGFa1lUTK05RFW+cwle8tkTHioFm6gGWdeGpDJjjhmvyaN8vLIqb8sAHI05TQxARsnUC3U2chzQP1Dw== + version "0.180.0" + resolved "https://registry.yarnpkg.com/flow-parser/-/flow-parser-0.180.0.tgz#05d49a88715ceca0457607499a018e2bf5908d72" + integrity sha512-kkzsuGAhckWgn/G+JfCyEa6BYslGrjlH4CJL0LZhdn9of9ukvi7SzVQSFsrEhuhh/zQUghfUEoaeZy1wjQXpUg== flux@^4.0.1: version "4.0.3" @@ -7819,13 +7762,13 @@ get-caller-file@^2.0.5: integrity sha512-DyFP3BM/3YHTQOCUL/w0OZHR0lpKeGrxotcHWcqNEdnltqFwXVfhEBQ94eIo34AfQpo0rGki4cyIiftY06h2Fg== get-intrinsic@^1.0.2, get-intrinsic@^1.1.0, get-intrinsic@^1.1.1: - version "1.1.1" - resolved "https://registry.yarnpkg.com/get-intrinsic/-/get-intrinsic-1.1.1.tgz#15f59f376f855c446963948f0d24cd3637b4abc6" - integrity sha512-kWZrnVM42QCiEA2Ig1bG8zjoIMOgxWwYCEeNdwY6Tv/cOSeGpcoX4pXHfKUxNKVoArnrEr2e9srnAxxGIraS9Q== + version "1.1.2" + resolved "https://registry.yarnpkg.com/get-intrinsic/-/get-intrinsic-1.1.2.tgz#336975123e05ad0b7ba41f152ee4aadbea6cf598" + integrity sha512-Jfm3OyCxHh9DJyc28qGk+JmfkpO41A4XkneDSujN9MDXrm4oDKdHvndhZ2dN94+ERNfkYJWDclW6k2L/ZGHjXA== dependencies: function-bind "^1.1.1" has "^1.0.3" - has-symbols "^1.0.1" + has-symbols "^1.0.3" get-own-enumerable-property-symbols@^3.0.0: version "3.0.2" @@ -7871,7 +7814,7 @@ get-stream@^5.1.0: dependencies: pump "^3.0.0" -get-stream@^6.0.0: +get-stream@^6.0.0, get-stream@^6.0.1: version "6.0.1" resolved "https://registry.yarnpkg.com/get-stream/-/get-stream-6.0.1.tgz#a262d8eef67aced57c2852ad6167526a43cbf7b7" integrity sha512-ts6Wi+2j3jQjqi70w5AlN8DFnkSwC+MqmxEzdEALB2qXZYV3X/b1CTfgPLGJNMeAWxdPfU8FO1ms3NUfaHCPYg== @@ -8226,17 +8169,6 @@ hast-to-hyperscript@^9.0.0: unist-util-is "^4.0.0" web-namespaces "^1.0.0" -hast-util-from-parse5@^5.0.0: - version "5.0.3" - resolved "https://registry.yarnpkg.com/hast-util-from-parse5/-/hast-util-from-parse5-5.0.3.tgz#3089dc0ee2ccf6ec8bc416919b51a54a589e097c" - integrity sha512-gOc8UB99F6eWVWFtM9jUikjN7QkWxB3nY0df5Z0Zq1/Nkwl5V4hAAsl0tmwlgWl/1shlTF8DnNYLO8X6wRV9pA== - dependencies: - ccount "^1.0.3" - hastscript "^5.0.0" - property-information "^5.0.0" - web-namespaces "^1.1.2" - xtend "^4.0.1" - hast-util-from-parse5@^6.0.0: version "6.0.1" resolved "https://registry.yarnpkg.com/hast-util-from-parse5/-/hast-util-from-parse5-6.0.1.tgz#554e34abdeea25ac76f5bd950a1f0180e0b3bc2a" @@ -8263,6 +8195,11 @@ hast-util-from-parse5@^7.0.0: vfile-location "^4.0.0" web-namespaces "^2.0.0" +hast-util-is-element@^1.0.0: + version "1.1.0" + resolved "https://registry.yarnpkg.com/hast-util-is-element/-/hast-util-is-element-1.1.0.tgz#3b3ed5159a2707c6137b48637fbfe068e175a425" + integrity sha512-oUmNua0bFbdrD/ELDSSEadRVtWZOf3iF6Lbv81naqsIV99RnSCieTbWuWCY8BAeEfKJTKl0gRdokv+dELutHGQ== + hast-util-is-element@^2.0.0: version "2.1.2" resolved "https://registry.yarnpkg.com/hast-util-is-element/-/hast-util-is-element-2.1.2.tgz#fc0b0dc7cef3895e839b8d66979d57b0338c68f3" @@ -8299,6 +8236,22 @@ hast-util-raw@6.0.1: xtend "^4.0.0" zwitch "^1.0.0" +hast-util-to-html@^7.1.1: + version "7.1.3" + resolved "https://registry.yarnpkg.com/hast-util-to-html/-/hast-util-to-html-7.1.3.tgz#9f339ca9bea71246e565fc79ff7dbfe98bb50f5e" + integrity sha512-yk2+1p3EJTEE9ZEUkgHsUSVhIpCsL/bvT8E5GzmWc+N1Po5gBw+0F8bo7dpxXR0nu0bQVxVZGX2lBGF21CmeDw== + dependencies: + ccount "^1.0.0" + comma-separated-tokens "^1.0.0" + hast-util-is-element "^1.0.0" + hast-util-whitespace "^1.0.0" + html-void-elements "^1.0.0" + property-information "^5.0.0" + space-separated-tokens "^1.0.0" + stringify-entities "^3.0.1" + unist-util-is "^4.0.0" + xtend "^4.0.0" + hast-util-to-parse5@^6.0.0: version "6.0.0" resolved "https://registry.yarnpkg.com/hast-util-to-parse5/-/hast-util-to-parse5-6.0.0.tgz#1ec44650b631d72952066cea9b1445df699f8479" @@ -8324,15 +8277,10 @@ hast-util-to-text@^3.1.0: hast-util-is-element "^2.0.0" unist-util-find-after "^4.0.0" -hastscript@^5.0.0: - version "5.1.2" - resolved "https://registry.yarnpkg.com/hastscript/-/hastscript-5.1.2.tgz#bde2c2e56d04c62dd24e8c5df288d050a355fb8a" - integrity sha512-WlztFuK+Lrvi3EggsqOkQ52rKbxkXL3RwB6t5lwoa8QLMemoWfBuL43eDrwOamJyR7uKQKdmKYaBH1NZBiIRrQ== - dependencies: - comma-separated-tokens "^1.0.0" - hast-util-parse-selector "^2.0.0" - property-information "^5.0.0" - space-separated-tokens "^1.0.0" +hast-util-whitespace@^1.0.0: + version "1.0.4" + resolved "https://registry.yarnpkg.com/hast-util-whitespace/-/hast-util-whitespace-1.0.4.tgz#e4fe77c4a9ae1cb2e6c25e02df0043d0164f6e41" + integrity sha512-I5GTdSfhYfAPNztx2xJRQpG8cuDSNt599/7YUn7Gx/WxNMsG+a835k97TDkFgk123cwjfwINaZknkKkphx/f2A== hastscript@^6.0.0: version "6.0.0" @@ -8465,18 +8413,6 @@ html-webpack-plugin@^5.5.0: pretty-error "^4.0.0" tapable "^2.0.0" -htmlparser2@^3.9.1: - version "3.10.1" - resolved "https://registry.yarnpkg.com/htmlparser2/-/htmlparser2-3.10.1.tgz#bd679dc3f59897b6a34bb10749c855bb53a9392f" - integrity sha512-IgieNijUMbkDovyoKObU1DUhm1iwNYE/fuifEoEHfd1oZKZDaONBSkal7Y01shxsM49R4XaMdGez3WnF9UfiCQ== - dependencies: - domelementtype "^1.3.1" - domhandler "^2.3.0" - domutils "^1.5.1" - entities "^1.1.1" - inherits "^2.0.1" - readable-stream "^3.1.1" - htmlparser2@^6.1.0: version "6.1.0" resolved "https://registry.yarnpkg.com/htmlparser2/-/htmlparser2-6.1.0.tgz#c4d762b6c3371a05dbe65e94ae43a9f845fb8fb7" @@ -8595,6 +8531,11 @@ human-signals@^2.1.0: resolved "https://registry.yarnpkg.com/human-signals/-/human-signals-2.1.0.tgz#dc91fcba42e4d06e4abaed33b3e7a3c02f514ea0" integrity sha512-B4FFZ6q/T2jhhksgkbEW3HBvWIfDW85snkQgawt07S7J5QXTk6BkNV+0yAeZrM5QpMAdYlocGoljn0sJ/WQkFw== +human-signals@^3.0.1: + version "3.0.1" + resolved "https://registry.yarnpkg.com/human-signals/-/human-signals-3.0.1.tgz#c740920859dafa50e5a3222da9d3bf4bb0e5eef5" + integrity sha512-rQLskxnM/5OCldHo+wNXbpVgDn5A17CUoKX+7Sokwaknlq7CdSnphy0W39GU8dw59XiCXmFXDg4fRuckQRKewQ== + humanize-ms@^1.2.1: version "1.2.1" resolved "https://registry.yarnpkg.com/humanize-ms/-/humanize-ms-1.2.1.tgz#c46e3159a293f6b896da29316d8b6fe8bb79bbed" @@ -9158,6 +9099,11 @@ is-stream@^2.0.0: resolved "https://registry.yarnpkg.com/is-stream/-/is-stream-2.0.1.tgz#fac1e3d53b97ad5a9d0ae9cef2389f5810a5c077" integrity sha512-hFoiJiTl63nn+kstHGBtewWSKnQLpyb155KHheA1l39uvtO9nWIop1p3udqPcUd/xbF1VLMO4n7OI6p7RbngDg== +is-stream@^3.0.0: + version "3.0.0" + resolved "https://registry.yarnpkg.com/is-stream/-/is-stream-3.0.0.tgz#e6bfd7aa6bef69f4f472ce9bb681e3e57b4319ac" + integrity sha512-LnQR4bZ9IADDRSkvpqMGvt/tEJWclzklNgSw48V5EAaAeDd6qGvN8ei6k5p0tvxSR171VmGyHuTiAOfxAbr8kA== + is-string@^1.0.5, is-string@^1.0.7: version "1.0.7" resolved "https://registry.yarnpkg.com/is-string/-/is-string-1.0.7.tgz#0dd12bf2006f255bb58f695110eff7491eebc0fd" @@ -9305,74 +9251,74 @@ jest-changed-files@^28.0.2: execa "^5.0.0" throat "^6.0.1" -jest-circus@^28.1.0: - version "28.1.0" - resolved "https://registry.yarnpkg.com/jest-circus/-/jest-circus-28.1.0.tgz#e229f590911bd54d60efaf076f7acd9360296dae" - integrity sha512-rNYfqfLC0L0zQKRKsg4n4J+W1A2fbyGH7Ss/kDIocp9KXD9iaL111glsLu7+Z7FHuZxwzInMDXq+N1ZIBkI/TQ== +jest-circus@^28.1.1: + version "28.1.1" + resolved "https://registry.yarnpkg.com/jest-circus/-/jest-circus-28.1.1.tgz#3d27da6a974d85a466dc0cdc6ddeb58daaa57bb4" + integrity sha512-75+BBVTsL4+p2w198DQpCeyh1RdaS2lhEG87HkaFX/UG0gJExVq2skG2pT7XZEGBubNj2CytcWSPan4QEPNosw== dependencies: - "@jest/environment" "^28.1.0" - "@jest/expect" "^28.1.0" - "@jest/test-result" "^28.1.0" - "@jest/types" "^28.1.0" + "@jest/environment" "^28.1.1" + "@jest/expect" "^28.1.1" + "@jest/test-result" "^28.1.1" + "@jest/types" "^28.1.1" "@types/node" "*" chalk "^4.0.0" co "^4.6.0" dedent "^0.7.0" is-generator-fn "^2.0.0" - jest-each "^28.1.0" - jest-matcher-utils "^28.1.0" - jest-message-util "^28.1.0" - jest-runtime "^28.1.0" - jest-snapshot "^28.1.0" - jest-util "^28.1.0" - pretty-format "^28.1.0" + jest-each "^28.1.1" + jest-matcher-utils "^28.1.1" + jest-message-util "^28.1.1" + jest-runtime "^28.1.1" + jest-snapshot "^28.1.1" + jest-util "^28.1.1" + pretty-format "^28.1.1" slash "^3.0.0" stack-utils "^2.0.3" throat "^6.0.1" -jest-cli@^28.1.0: - version "28.1.0" - resolved "https://registry.yarnpkg.com/jest-cli/-/jest-cli-28.1.0.tgz#cd1d8adb9630102d5ba04a22895f63decdd7ac1f" - integrity sha512-fDJRt6WPRriHrBsvvgb93OxgajHHsJbk4jZxiPqmZbMDRcHskfJBBfTyjFko0jjfprP544hOktdSi9HVgl4VUQ== +jest-cli@^28.1.1: + version "28.1.1" + resolved "https://registry.yarnpkg.com/jest-cli/-/jest-cli-28.1.1.tgz#23ddfde8940e1818585ae4a568877b33b0e51cfe" + integrity sha512-+sUfVbJqb1OjBZ0OdBbI6OWfYM1i7bSfzYy6gze1F1w3OKWq8ZTEKkZ8a7ZQPq6G/G1qMh/uKqpdWhgl11NFQQ== dependencies: - "@jest/core" "^28.1.0" - "@jest/test-result" "^28.1.0" - "@jest/types" "^28.1.0" + "@jest/core" "^28.1.1" + "@jest/test-result" "^28.1.1" + "@jest/types" "^28.1.1" chalk "^4.0.0" exit "^0.1.2" graceful-fs "^4.2.9" import-local "^3.0.2" - jest-config "^28.1.0" - jest-util "^28.1.0" - jest-validate "^28.1.0" + jest-config "^28.1.1" + jest-util "^28.1.1" + jest-validate "^28.1.1" prompts "^2.0.1" yargs "^17.3.1" -jest-config@^28.1.0: - version "28.1.0" - resolved "https://registry.yarnpkg.com/jest-config/-/jest-config-28.1.0.tgz#fca22ca0760e746fe1ce1f9406f6b307ab818501" - integrity sha512-aOV80E9LeWrmflp7hfZNn/zGA4QKv/xsn2w8QCBP0t0+YqObuCWTSgNbHJ0j9YsTuCO08ZR/wsvlxqqHX20iUA== +jest-config@^28.1.1: + version "28.1.1" + resolved "https://registry.yarnpkg.com/jest-config/-/jest-config-28.1.1.tgz#e90b97b984f14a6c24a221859e81b258990fce2f" + integrity sha512-tASynMhS+jVV85zKvjfbJ8nUyJS/jUSYZ5KQxLUN2ZCvcQc/OmhQl2j6VEL3ezQkNofxn5pQ3SPYWPHb0unTZA== dependencies: "@babel/core" "^7.11.6" - "@jest/test-sequencer" "^28.1.0" - "@jest/types" "^28.1.0" - babel-jest "^28.1.0" + "@jest/test-sequencer" "^28.1.1" + "@jest/types" "^28.1.1" + babel-jest "^28.1.1" chalk "^4.0.0" ci-info "^3.2.0" deepmerge "^4.2.2" glob "^7.1.3" graceful-fs "^4.2.9" - jest-circus "^28.1.0" - jest-environment-node "^28.1.0" + jest-circus "^28.1.1" + jest-environment-node "^28.1.1" jest-get-type "^28.0.2" jest-regex-util "^28.0.2" - jest-resolve "^28.1.0" - jest-runner "^28.1.0" - jest-util "^28.1.0" - jest-validate "^28.1.0" + jest-resolve "^28.1.1" + jest-runner "^28.1.1" + jest-util "^28.1.1" + jest-validate "^28.1.1" micromatch "^4.0.4" parse-json "^5.2.0" - pretty-format "^28.1.0" + pretty-format "^28.1.1" slash "^3.0.0" strip-json-comments "^3.1.1" @@ -9386,59 +9332,59 @@ jest-diff@^27.5.1: jest-get-type "^27.5.1" pretty-format "^27.5.1" -jest-diff@^28.1.0: - version "28.1.0" - resolved "https://registry.yarnpkg.com/jest-diff/-/jest-diff-28.1.0.tgz#77686fef899ec1873dbfbf9330e37dd429703269" - integrity sha512-8eFd3U3OkIKRtlasXfiAQfbovgFgRDb0Ngcs2E+FMeBZ4rUezqIaGjuyggJBp+llosQXNEWofk/Sz4Hr5gMUhA== +jest-diff@^28.1.1: + version "28.1.1" + resolved "https://registry.yarnpkg.com/jest-diff/-/jest-diff-28.1.1.tgz#1a3eedfd81ae79810931c63a1d0f201b9120106c" + integrity sha512-/MUUxeR2fHbqHoMMiffe/Afm+U8U4olFRJ0hiVG2lZatPJcnGxx292ustVu7bULhjV65IYMxRdploAKLbcrsyg== dependencies: chalk "^4.0.0" - diff-sequences "^28.0.2" + diff-sequences "^28.1.1" jest-get-type "^28.0.2" - pretty-format "^28.1.0" + pretty-format "^28.1.1" -jest-docblock@^28.0.2: - version "28.0.2" - resolved "https://registry.yarnpkg.com/jest-docblock/-/jest-docblock-28.0.2.tgz#3cab8abea53275c9d670cdca814fc89fba1298c2" - integrity sha512-FH10WWw5NxLoeSdQlJwu+MTiv60aXV/t8KEwIRGEv74WARE1cXIqh1vGdy2CraHuWOOrnzTWj/azQKqW4fO7xg== +jest-docblock@^28.1.1: + version "28.1.1" + resolved "https://registry.yarnpkg.com/jest-docblock/-/jest-docblock-28.1.1.tgz#6f515c3bf841516d82ecd57a62eed9204c2f42a8" + integrity sha512-3wayBVNiOYx0cwAbl9rwm5kKFP8yHH3d/fkEaL02NPTkDojPtheGB7HZSFY4wzX+DxyrvhXz0KSCVksmCknCuA== dependencies: detect-newline "^3.0.0" -jest-each@^28.1.0: - version "28.1.0" - resolved "https://registry.yarnpkg.com/jest-each/-/jest-each-28.1.0.tgz#54ae66d6a0a5b1913e9a87588d26c2687c39458b" - integrity sha512-a/XX02xF5NTspceMpHujmOexvJ4GftpYXqr6HhhmKmExtMXsyIN/fvanQlt/BcgFoRKN4OCXxLQKth9/n6OPFg== +jest-each@^28.1.1: + version "28.1.1" + resolved "https://registry.yarnpkg.com/jest-each/-/jest-each-28.1.1.tgz#ba5238dacf4f31d9fe23ddc2c44c01e7c23885c4" + integrity sha512-A042rqh17ZvEhRceDMi784ppoXR7MWGDEKTXEZXb4svt0eShMZvijGxzKsx+yIjeE8QYmHPrnHiTSQVhN4nqaw== dependencies: - "@jest/types" "^28.1.0" + "@jest/types" "^28.1.1" chalk "^4.0.0" jest-get-type "^28.0.2" - jest-util "^28.1.0" - pretty-format "^28.1.0" + jest-util "^28.1.1" + pretty-format "^28.1.1" -jest-environment-jsdom@^28.1.0: - version "28.1.0" - resolved "https://registry.yarnpkg.com/jest-environment-jsdom/-/jest-environment-jsdom-28.1.0.tgz#1042cffd0343615c5fac2d2c8da20d1d43b73ef8" - integrity sha512-8n6P4xiDjNVqTWv6W6vJPuQdLx+ZiA3dbYg7YJ+DPzR+9B61K6pMVJrSs2IxfGRG4J7pyAUA5shQ9G0KEun78w== +jest-environment-jsdom@^28.1.1: + version "28.1.1" + resolved "https://registry.yarnpkg.com/jest-environment-jsdom/-/jest-environment-jsdom-28.1.1.tgz#8bd721915b32f9b196723292c4461a0ad548b55b" + integrity sha512-41ZvgSoPNcKG5q3LuuOcAczdBxRq9DbZkPe24okN6ZCmiZdAfFtPg3z+lOtsT1fM6OAERApKT+3m0MRDQH2zIA== dependencies: - "@jest/environment" "^28.1.0" - "@jest/fake-timers" "^28.1.0" - "@jest/types" "^28.1.0" + "@jest/environment" "^28.1.1" + "@jest/fake-timers" "^28.1.1" + "@jest/types" "^28.1.1" "@types/jsdom" "^16.2.4" "@types/node" "*" - jest-mock "^28.1.0" - jest-util "^28.1.0" + jest-mock "^28.1.1" + jest-util "^28.1.1" jsdom "^19.0.0" -jest-environment-node@^28.1.0: - version "28.1.0" - resolved "https://registry.yarnpkg.com/jest-environment-node/-/jest-environment-node-28.1.0.tgz#6ed2150aa31babba0c488c5b4f4d813a585c68e6" - integrity sha512-gBLZNiyrPw9CSMlTXF1yJhaBgWDPVvH0Pq6bOEwGMXaYNzhzhw2kA/OijNF8egbCgDS0/veRv97249x2CX+udQ== +jest-environment-node@^28.1.1: + version "28.1.1" + resolved "https://registry.yarnpkg.com/jest-environment-node/-/jest-environment-node-28.1.1.tgz#1c86c59003a7d319fa06ea3b1bbda6c193715c67" + integrity sha512-2aV/eeY/WNgUUJrrkDJ3cFEigjC5fqT1+fCclrY6paqJ5zVPoM//sHmfgUUp7WLYxIdbPwMiVIzejpN56MxnNA== dependencies: - "@jest/environment" "^28.1.0" - "@jest/fake-timers" "^28.1.0" - "@jest/types" "^28.1.0" + "@jest/environment" "^28.1.1" + "@jest/fake-timers" "^28.1.1" + "@jest/types" "^28.1.1" "@types/node" "*" - jest-mock "^28.1.0" - jest-util "^28.1.0" + jest-mock "^28.1.1" + jest-util "^28.1.1" jest-get-type@^27.5.1: version "27.5.1" @@ -9450,32 +9396,32 @@ jest-get-type@^28.0.2: resolved "https://registry.yarnpkg.com/jest-get-type/-/jest-get-type-28.0.2.tgz#34622e628e4fdcd793d46db8a242227901fcf203" integrity sha512-ioj2w9/DxSYHfOm5lJKCdcAmPJzQXmbM/Url3rhlghrPvT3tt+7a/+oXc9azkKmLvoiXjtV83bEWqi+vs5nlPA== -jest-haste-map@^28.1.0: - version "28.1.0" - resolved "https://registry.yarnpkg.com/jest-haste-map/-/jest-haste-map-28.1.0.tgz#6c1ee2daf1c20a3e03dbd8e5b35c4d73d2349cf0" - integrity sha512-xyZ9sXV8PtKi6NCrJlmq53PyNVHzxmcfXNVvIRHpHmh1j/HChC4pwKgyjj7Z9us19JMw8PpQTJsFWOsIfT93Dw== +jest-haste-map@^28.1.1: + version "28.1.1" + resolved "https://registry.yarnpkg.com/jest-haste-map/-/jest-haste-map-28.1.1.tgz#471685f1acd365a9394745bb97c8fc16289adca3" + integrity sha512-ZrRSE2o3Ezh7sb1KmeLEZRZ4mgufbrMwolcFHNRSjKZhpLa8TdooXOOFlSwoUzlbVs1t0l7upVRW2K7RWGHzbQ== dependencies: - "@jest/types" "^28.1.0" + "@jest/types" "^28.1.1" "@types/graceful-fs" "^4.1.3" "@types/node" "*" anymatch "^3.0.3" fb-watchman "^2.0.0" graceful-fs "^4.2.9" jest-regex-util "^28.0.2" - jest-util "^28.1.0" - jest-worker "^28.1.0" + jest-util "^28.1.1" + jest-worker "^28.1.1" micromatch "^4.0.4" - walker "^1.0.7" + walker "^1.0.8" optionalDependencies: fsevents "^2.3.2" -jest-leak-detector@^28.1.0: - version "28.1.0" - resolved "https://registry.yarnpkg.com/jest-leak-detector/-/jest-leak-detector-28.1.0.tgz#b65167776a8787443214d6f3f54935a4c73c8a45" - integrity sha512-uIJDQbxwEL2AMMs2xjhZl2hw8s77c3wrPaQ9v6tXJLGaaQ+4QrNJH5vuw7hA7w/uGT/iJ42a83opAqxGHeyRIA== +jest-leak-detector@^28.1.1: + version "28.1.1" + resolved "https://registry.yarnpkg.com/jest-leak-detector/-/jest-leak-detector-28.1.1.tgz#537f37afd610a4b3f4cab15e06baf60484548efb" + integrity sha512-4jvs8V8kLbAaotE+wFR7vfUGf603cwYtFf1/PYEsyX2BAjSzj8hQSVTP6OWzseTl0xL6dyHuKs2JAks7Pfubmw== dependencies: jest-get-type "^28.0.2" - pretty-format "^28.1.0" + pretty-format "^28.1.1" jest-matcher-utils@^27.0.0: version "27.5.1" @@ -9487,37 +9433,37 @@ jest-matcher-utils@^27.0.0: jest-get-type "^27.5.1" pretty-format "^27.5.1" -jest-matcher-utils@^28.1.0: - version "28.1.0" - resolved "https://registry.yarnpkg.com/jest-matcher-utils/-/jest-matcher-utils-28.1.0.tgz#2ae398806668eeabd293c61712227cb94b250ccf" - integrity sha512-onnax0n2uTLRQFKAjC7TuaxibrPSvZgKTcSCnNUz/tOjJ9UhxNm7ZmPpoQavmTDUjXvUQ8KesWk2/VdrxIFzTQ== +jest-matcher-utils@^28.1.1: + version "28.1.1" + resolved "https://registry.yarnpkg.com/jest-matcher-utils/-/jest-matcher-utils-28.1.1.tgz#a7c4653c2b782ec96796eb3088060720f1e29304" + integrity sha512-NPJPRWrbmR2nAJ+1nmnfcKKzSwgfaciCCrYZzVnNoxVoyusYWIjkBMNvu0RHJe7dNj4hH3uZOPZsQA+xAYWqsw== dependencies: chalk "^4.0.0" - jest-diff "^28.1.0" + jest-diff "^28.1.1" jest-get-type "^28.0.2" - pretty-format "^28.1.0" + pretty-format "^28.1.1" -jest-message-util@^28.1.0: - version "28.1.0" - resolved "https://registry.yarnpkg.com/jest-message-util/-/jest-message-util-28.1.0.tgz#7e8f0b9049e948e7b94c2a52731166774ba7d0af" - integrity sha512-RpA8mpaJ/B2HphDMiDlrAZdDytkmwFqgjDZovM21F35lHGeUeCvYmm6W+sbQ0ydaLpg5bFAUuWG1cjqOl8vqrw== +jest-message-util@^28.1.1: + version "28.1.1" + resolved "https://registry.yarnpkg.com/jest-message-util/-/jest-message-util-28.1.1.tgz#60aa0b475cfc08c8a9363ed2fb9108514dd9ab89" + integrity sha512-xoDOOT66fLfmTRiqkoLIU7v42mal/SqwDKvfmfiWAdJMSJiU+ozgluO7KbvoAgiwIrrGZsV7viETjc8GNrA/IQ== dependencies: "@babel/code-frame" "^7.12.13" - "@jest/types" "^28.1.0" + "@jest/types" "^28.1.1" "@types/stack-utils" "^2.0.0" chalk "^4.0.0" graceful-fs "^4.2.9" micromatch "^4.0.4" - pretty-format "^28.1.0" + pretty-format "^28.1.1" slash "^3.0.0" stack-utils "^2.0.3" -jest-mock@^28.1.0: - version "28.1.0" - resolved "https://registry.yarnpkg.com/jest-mock/-/jest-mock-28.1.0.tgz#ccc7cc12a9b330b3182db0c651edc90d163ff73e" - integrity sha512-H7BrhggNn77WhdL7O1apG0Q/iwl0Bdd5E1ydhCJzL3oBLh/UYxAwR3EJLsBZ9XA3ZU4PA3UNw4tQjduBTCTmLw== +jest-mock@^28.1.1: + version "28.1.1" + resolved "https://registry.yarnpkg.com/jest-mock/-/jest-mock-28.1.1.tgz#37903d269427fa1ef5b2447be874e1c62a39a371" + integrity sha512-bDCb0FjfsmKweAvE09dZT59IMkzgN0fYBH6t5S45NoJfd2DHkS3ySG2K+hucortryhO3fVuXdlxWcbtIuV/Skw== dependencies: - "@jest/types" "^28.1.0" + "@jest/types" "^28.1.1" "@types/node" "*" jest-pnp-resolver@^1.2.2: @@ -9530,81 +9476,81 @@ jest-regex-util@^28.0.2: resolved "https://registry.yarnpkg.com/jest-regex-util/-/jest-regex-util-28.0.2.tgz#afdc377a3b25fb6e80825adcf76c854e5bf47ead" integrity sha512-4s0IgyNIy0y9FK+cjoVYoxamT7Zeo7MhzqRGx7YDYmaQn1wucY9rotiGkBzzcMXTtjrCAP/f7f+E0F7+fxPNdw== -jest-resolve-dependencies@^28.1.0: - version "28.1.0" - resolved "https://registry.yarnpkg.com/jest-resolve-dependencies/-/jest-resolve-dependencies-28.1.0.tgz#167becb8bee6e20b5ef4a3a728ec67aef6b0b79b" - integrity sha512-Ue1VYoSZquPwEvng7Uefw8RmZR+me/1kr30H2jMINjGeHgeO/JgrR6wxj2ofkJ7KSAA11W3cOrhNCbj5Dqqd9g== +jest-resolve-dependencies@^28.1.1: + version "28.1.1" + resolved "https://registry.yarnpkg.com/jest-resolve-dependencies/-/jest-resolve-dependencies-28.1.1.tgz#3dffaaa56f4b41bc6b61053899d1756401763a27" + integrity sha512-p8Y150xYJth4EXhOuB8FzmS9r8IGLEioiaetgdNGb9VHka4fl0zqWlVe4v7mSkYOuEUg2uB61iE+zySDgrOmgQ== dependencies: jest-regex-util "^28.0.2" - jest-snapshot "^28.1.0" + jest-snapshot "^28.1.1" -jest-resolve@^28.1.0: - version "28.1.0" - resolved "https://registry.yarnpkg.com/jest-resolve/-/jest-resolve-28.1.0.tgz#b1f32748a6cee7d1779c7ef639c0a87078de3d35" - integrity sha512-vvfN7+tPNnnhDvISuzD1P+CRVP8cK0FHXRwPAcdDaQv4zgvwvag2n55/h5VjYcM5UJG7L4TwE5tZlzcI0X2Lhw== +jest-resolve@^28.1.1: + version "28.1.1" + resolved "https://registry.yarnpkg.com/jest-resolve/-/jest-resolve-28.1.1.tgz#bc2eaf384abdcc1aaf3ba7c50d1adf01e59095e5" + integrity sha512-/d1UbyUkf9nvsgdBildLe6LAD4DalgkgZcKd0nZ8XUGPyA/7fsnaQIlKVnDiuUXv/IeZhPEDrRJubVSulxrShA== dependencies: chalk "^4.0.0" graceful-fs "^4.2.9" - jest-haste-map "^28.1.0" + jest-haste-map "^28.1.1" jest-pnp-resolver "^1.2.2" - jest-util "^28.1.0" - jest-validate "^28.1.0" + jest-util "^28.1.1" + jest-validate "^28.1.1" resolve "^1.20.0" resolve.exports "^1.1.0" slash "^3.0.0" -jest-runner@^28.1.0: - version "28.1.0" - resolved "https://registry.yarnpkg.com/jest-runner/-/jest-runner-28.1.0.tgz#aefe2a1e618a69baa0b24a50edc54fdd7e728eaa" - integrity sha512-FBpmuh1HB2dsLklAlRdOxNTTHKFR6G1Qmd80pVDvwbZXTriqjWqjei5DKFC1UlM732KjYcE6yuCdiF0WUCOS2w== +jest-runner@^28.1.1: + version "28.1.1" + resolved "https://registry.yarnpkg.com/jest-runner/-/jest-runner-28.1.1.tgz#9ecdb3f27a00059986797aa6b012ba8306aa436c" + integrity sha512-W5oFUiDBgTsCloTAj6q95wEvYDB0pxIhY6bc5F26OucnwBN+K58xGTGbliSMI4ChQal5eANDF+xvELaYkJxTmA== dependencies: - "@jest/console" "^28.1.0" - "@jest/environment" "^28.1.0" - "@jest/test-result" "^28.1.0" - "@jest/transform" "^28.1.0" - "@jest/types" "^28.1.0" + "@jest/console" "^28.1.1" + "@jest/environment" "^28.1.1" + "@jest/test-result" "^28.1.1" + "@jest/transform" "^28.1.1" + "@jest/types" "^28.1.1" "@types/node" "*" chalk "^4.0.0" emittery "^0.10.2" graceful-fs "^4.2.9" - jest-docblock "^28.0.2" - jest-environment-node "^28.1.0" - jest-haste-map "^28.1.0" - jest-leak-detector "^28.1.0" - jest-message-util "^28.1.0" - jest-resolve "^28.1.0" - jest-runtime "^28.1.0" - jest-util "^28.1.0" - jest-watcher "^28.1.0" - jest-worker "^28.1.0" + jest-docblock "^28.1.1" + jest-environment-node "^28.1.1" + jest-haste-map "^28.1.1" + jest-leak-detector "^28.1.1" + jest-message-util "^28.1.1" + jest-resolve "^28.1.1" + jest-runtime "^28.1.1" + jest-util "^28.1.1" + jest-watcher "^28.1.1" + jest-worker "^28.1.1" source-map-support "0.5.13" throat "^6.0.1" -jest-runtime@^28.1.0: - version "28.1.0" - resolved "https://registry.yarnpkg.com/jest-runtime/-/jest-runtime-28.1.0.tgz#4847dcb2a4eb4b0f9eaf41306897e51fb1665631" - integrity sha512-wNYDiwhdH/TV3agaIyVF0lsJ33MhyujOe+lNTUiolqKt8pchy1Hq4+tDMGbtD5P/oNLA3zYrpx73T9dMTOCAcg== +jest-runtime@^28.1.1: + version "28.1.1" + resolved "https://registry.yarnpkg.com/jest-runtime/-/jest-runtime-28.1.1.tgz#569e1dc3c36c6c4c0b29516c1c49b6ad580abdaf" + integrity sha512-J89qEJWW0leOsqyi0D9zHpFEYHwwafFdS9xgvhFHtIdRghbadodI0eA+DrthK/1PebBv3Px8mFSMGKrtaVnleg== dependencies: - "@jest/environment" "^28.1.0" - "@jest/fake-timers" "^28.1.0" - "@jest/globals" "^28.1.0" + "@jest/environment" "^28.1.1" + "@jest/fake-timers" "^28.1.1" + "@jest/globals" "^28.1.1" "@jest/source-map" "^28.0.2" - "@jest/test-result" "^28.1.0" - "@jest/transform" "^28.1.0" - "@jest/types" "^28.1.0" + "@jest/test-result" "^28.1.1" + "@jest/transform" "^28.1.1" + "@jest/types" "^28.1.1" chalk "^4.0.0" cjs-module-lexer "^1.0.0" collect-v8-coverage "^1.0.0" execa "^5.0.0" glob "^7.1.3" graceful-fs "^4.2.9" - jest-haste-map "^28.1.0" - jest-message-util "^28.1.0" - jest-mock "^28.1.0" + jest-haste-map "^28.1.1" + jest-message-util "^28.1.1" + jest-mock "^28.1.1" jest-regex-util "^28.0.2" - jest-resolve "^28.1.0" - jest-snapshot "^28.1.0" - jest-util "^28.1.0" + jest-resolve "^28.1.1" + jest-snapshot "^28.1.1" + jest-util "^28.1.1" slash "^3.0.0" strip-bom "^4.0.0" @@ -9613,71 +9559,71 @@ jest-serializer-react-helmet-async@^1.0.21: resolved "https://registry.yarnpkg.com/jest-serializer-react-helmet-async/-/jest-serializer-react-helmet-async-1.0.21.tgz#bf2aee7522909bc4c933a0911db236b92db4685c" integrity sha512-oJARA6ACc3QNR4s/EUjecLQclGf2+vMO0azoiEBwjJrsDHGHkMHcM935+r7aGkmteY1awdoyQ78ZGDiC7dwtsw== -jest-snapshot@^28.1.0: - version "28.1.0" - resolved "https://registry.yarnpkg.com/jest-snapshot/-/jest-snapshot-28.1.0.tgz#4b74fa8816707dd10fe9d551c2c258e5a67b53b6" - integrity sha512-ex49M2ZrZsUyQLpLGxQtDbahvgBjlLPgklkqGM0hq/F7W/f8DyqZxVHjdy19QKBm4O93eDp+H5S23EiTbbUmHw== +jest-snapshot@^28.1.1: + version "28.1.1" + resolved "https://registry.yarnpkg.com/jest-snapshot/-/jest-snapshot-28.1.1.tgz#ab825c16c8d8b5e883bd57eee6ca8748c42ab848" + integrity sha512-1KjqHJ98adRcbIdMizjF5DipwZFbvxym/kFO4g4fVZCZRxH/dqV8TiBFCa6rqic3p0karsy8RWS1y4E07b7P0A== dependencies: "@babel/core" "^7.11.6" "@babel/generator" "^7.7.2" "@babel/plugin-syntax-typescript" "^7.7.2" "@babel/traverse" "^7.7.2" "@babel/types" "^7.3.3" - "@jest/expect-utils" "^28.1.0" - "@jest/transform" "^28.1.0" - "@jest/types" "^28.1.0" + "@jest/expect-utils" "^28.1.1" + "@jest/transform" "^28.1.1" + "@jest/types" "^28.1.1" "@types/babel__traverse" "^7.0.6" "@types/prettier" "^2.1.5" babel-preset-current-node-syntax "^1.0.0" chalk "^4.0.0" - expect "^28.1.0" + expect "^28.1.1" graceful-fs "^4.2.9" - jest-diff "^28.1.0" + jest-diff "^28.1.1" jest-get-type "^28.0.2" - jest-haste-map "^28.1.0" - jest-matcher-utils "^28.1.0" - jest-message-util "^28.1.0" - jest-util "^28.1.0" + jest-haste-map "^28.1.1" + jest-matcher-utils "^28.1.1" + jest-message-util "^28.1.1" + jest-util "^28.1.1" natural-compare "^1.4.0" - pretty-format "^28.1.0" + pretty-format "^28.1.1" semver "^7.3.5" -jest-util@^28.1.0: - version "28.1.0" - resolved "https://registry.yarnpkg.com/jest-util/-/jest-util-28.1.0.tgz#d54eb83ad77e1dd441408738c5a5043642823be5" - integrity sha512-qYdCKD77k4Hwkose2YBEqQk7PzUf/NSE+rutzceduFveQREeH6b+89Dc9+wjX9dAwHcgdx4yedGA3FQlU/qCTA== +jest-util@^28.1.1: + version "28.1.1" + resolved "https://registry.yarnpkg.com/jest-util/-/jest-util-28.1.1.tgz#ff39e436a1aca397c0ab998db5a51ae2b7080d05" + integrity sha512-FktOu7ca1DZSyhPAxgxB6hfh2+9zMoJ7aEQA759Z6p45NuO8mWcqujH+UdHlCm/V6JTWwDztM2ITCzU1ijJAfw== dependencies: - "@jest/types" "^28.1.0" + "@jest/types" "^28.1.1" "@types/node" "*" chalk "^4.0.0" ci-info "^3.2.0" graceful-fs "^4.2.9" picomatch "^2.2.3" -jest-validate@^28.1.0: - version "28.1.0" - resolved "https://registry.yarnpkg.com/jest-validate/-/jest-validate-28.1.0.tgz#8a6821f48432aba9f830c26e28226ad77b9a0e18" - integrity sha512-Lly7CJYih3vQBfjLeANGgBSBJ7pEa18cxpQfQEq2go2xyEzehnHfQTjoUia8xUv4x4J80XKFIDwJJThXtRFQXQ== +jest-validate@^28.1.1: + version "28.1.1" + resolved "https://registry.yarnpkg.com/jest-validate/-/jest-validate-28.1.1.tgz#59b7b339b3c85b5144bd0c06ad3600f503a4acc8" + integrity sha512-Kpf6gcClqFCIZ4ti5++XemYJWUPCFUW+N2gknn+KgnDf549iLul3cBuKVe1YcWRlaF8tZV8eJCap0eECOEE3Ug== dependencies: - "@jest/types" "^28.1.0" + "@jest/types" "^28.1.1" camelcase "^6.2.0" chalk "^4.0.0" jest-get-type "^28.0.2" leven "^3.1.0" - pretty-format "^28.1.0" + pretty-format "^28.1.1" -jest-watcher@^28.1.0: - version "28.1.0" - resolved "https://registry.yarnpkg.com/jest-watcher/-/jest-watcher-28.1.0.tgz#aaa7b4164a4e77eeb5f7d7b25ede5e7b4e9c9aaf" - integrity sha512-tNHMtfLE8Njcr2IRS+5rXYA4BhU90gAOwI9frTGOqd+jX0P/Au/JfRSNqsf5nUTcWdbVYuLxS1KjnzILSoR5hA== +jest-watcher@^28.1.1: + version "28.1.1" + resolved "https://registry.yarnpkg.com/jest-watcher/-/jest-watcher-28.1.1.tgz#533597fb3bfefd52b5cd115cd916cffd237fb60c" + integrity sha512-RQIpeZ8EIJMxbQrXpJQYIIlubBnB9imEHsxxE41f54ZwcqWLysL/A0ZcdMirf+XsMn3xfphVQVV4EW0/p7i7Ug== dependencies: - "@jest/test-result" "^28.1.0" - "@jest/types" "^28.1.0" + "@jest/test-result" "^28.1.1" + "@jest/types" "^28.1.1" "@types/node" "*" ansi-escapes "^4.2.1" chalk "^4.0.0" emittery "^0.10.2" - jest-util "^28.1.0" + jest-util "^28.1.1" string-length "^4.0.1" jest-worker@^26.2.1: @@ -9698,23 +9644,24 @@ jest-worker@^27.4.5, jest-worker@^27.5.1: merge-stream "^2.0.0" supports-color "^8.0.0" -jest-worker@^28.1.0: - version "28.1.0" - resolved "https://registry.yarnpkg.com/jest-worker/-/jest-worker-28.1.0.tgz#ced54757a035e87591e1208253a6e3aac1a855e5" - integrity sha512-ZHwM6mNwaWBR52Snff8ZvsCTqQsvhCxP/bT1I6T6DAnb6ygkshsyLQIMxFwHpYxht0HOoqt23JlC01viI7T03A== +jest-worker@^28.1.1: + version "28.1.1" + resolved "https://registry.yarnpkg.com/jest-worker/-/jest-worker-28.1.1.tgz#3480c73247171dfd01eda77200f0063ab6a3bf28" + integrity sha512-Au7slXB08C6h+xbJPp7VIb6U0XX5Kc9uel/WFc6/rcTzGiaVCBRngBExSYuXSLFPULPSYU3cJ3ybS988lNFQhQ== dependencies: "@types/node" "*" merge-stream "^2.0.0" supports-color "^8.0.0" -jest@^28.1.0: - version "28.1.0" - resolved "https://registry.yarnpkg.com/jest/-/jest-28.1.0.tgz#f420e41c8f2395b9a30445a97189ebb57593d831" - integrity sha512-TZR+tHxopPhzw3c3560IJXZWLNHgpcz1Zh0w5A65vynLGNcg/5pZ+VildAd7+XGOu6jd58XMY/HNn0IkZIXVXg== +jest@^28.1.1: + version "28.1.1" + resolved "https://registry.yarnpkg.com/jest/-/jest-28.1.1.tgz#3c39a3a09791e16e9ef283597d24ab19a0df701e" + integrity sha512-qw9YHBnjt6TCbIDMPMpJZqf9E12rh6869iZaN08/vpOGgHJSAaLLUn6H8W3IAEuy34Ls3rct064mZLETkxJ2XA== dependencies: - "@jest/core" "^28.1.0" + "@jest/core" "^28.1.1" + "@jest/types" "^28.1.1" import-local "^3.0.2" - jest-cli "^28.1.0" + jest-cli "^28.1.1" joi@^17.6.0: version "17.6.0" @@ -9910,9 +9857,9 @@ just-diff-apply@^5.2.0: integrity sha512-dgFenZnMsc1xGNqgdtgnh7DK+Oy352CE3VZLbzcbQpsBs9iI2K3M0IRrdgREZ72eItTjbl0suRyvKRdVQa9GbA== just-diff@^5.0.1: - version "5.0.2" - resolved "https://registry.yarnpkg.com/just-diff/-/just-diff-5.0.2.tgz#68854c94280c37d28cb266d8f29bdd2cd29f003e" - integrity sha512-uGd6F+eIZ4T95EinP8ubINGkbEy3jrgBym+6LjW+ja1UG1WQIcEcQ6FLeyXtVJZglk+bj7fvEn+Cu2LBxkgiYQ== + version "5.0.3" + resolved "https://registry.yarnpkg.com/just-diff/-/just-diff-5.0.3.tgz#4c9c514dec5526b25ab977590e3c39a0cf271554" + integrity sha512-a8p80xcpJ6sdurk5PxDKb4mav9MeKjA3zFKZpCWBIfvg8mznfnmb13MKZvlrwJ+Lhis0wM3uGAzE0ArhFHvIcg== katex@^0.15.0: version "0.15.6" @@ -10005,27 +9952,27 @@ lerna-changelog@^2.2.0: progress "^2.0.0" yargs "^17.1.0" -lerna@^5.0.0: - version "5.0.0" - resolved "https://registry.yarnpkg.com/lerna/-/lerna-5.0.0.tgz#077e35d41fcead5ea223af1862dc25475e1aaf2a" - integrity sha512-dUYmJ7H9k/xHtwKpQWLTNUa1jnFUiW4o4K2LFkRchlIijoIUT4yK/RprIxNvYCrLrEaOdZryvY5UZvSHI2tBxA== - dependencies: - "@lerna/add" "5.0.0" - "@lerna/bootstrap" "5.0.0" - "@lerna/changed" "5.0.0" - "@lerna/clean" "5.0.0" - "@lerna/cli" "5.0.0" - "@lerna/create" "5.0.0" - "@lerna/diff" "5.0.0" - "@lerna/exec" "5.0.0" - "@lerna/import" "5.0.0" - "@lerna/info" "5.0.0" - "@lerna/init" "5.0.0" - "@lerna/link" "5.0.0" - "@lerna/list" "5.0.0" - "@lerna/publish" "5.0.0" - "@lerna/run" "5.0.0" - "@lerna/version" "5.0.0" +lerna@^5.1.1: + version "5.1.1" + resolved "https://registry.yarnpkg.com/lerna/-/lerna-5.1.1.tgz#f2f2a2e89283d2b67075c680df8796922effc1a7" + integrity sha512-huJ8jHn3qrKVX89b3SumQE5buCfXQ1pyikk7cdmAI9jnwBRMBfMR/3mxd+lonNYJGRFTsQ6yF+AkK/sqRSNXhA== + dependencies: + "@lerna/add" "5.1.1" + "@lerna/bootstrap" "5.1.1" + "@lerna/changed" "5.1.1" + "@lerna/clean" "5.1.1" + "@lerna/cli" "5.1.1" + "@lerna/create" "5.1.1" + "@lerna/diff" "5.1.1" + "@lerna/exec" "5.1.1" + "@lerna/import" "5.1.1" + "@lerna/info" "5.1.1" + "@lerna/init" "5.1.1" + "@lerna/link" "5.1.1" + "@lerna/list" "5.1.1" + "@lerna/publish" "5.1.1" + "@lerna/run" "5.1.1" + "@lerna/version" "5.1.1" import-local "^3.0.2" npmlog "^4.1.2" @@ -10071,12 +10018,7 @@ libnpmpublish@^4.0.0: semver "^7.1.3" ssri "^8.0.1" -lilconfig@2.0.4: - version "2.0.4" - resolved "https://registry.yarnpkg.com/lilconfig/-/lilconfig-2.0.4.tgz#f4507d043d7058b380b6a8f5cb7bcd4b34cee082" - integrity sha512-bfTIN7lEsiooCocSISTWXkiWJkRqtL9wYtYy+8EK3Y41qh3mpwPU0ycTOgjdY9ErwXCc8QyrQp82bdL0Xkm9yA== - -lilconfig@^2.0.3: +lilconfig@2.0.5, lilconfig@^2.0.3: version "2.0.5" resolved "https://registry.yarnpkg.com/lilconfig/-/lilconfig-2.0.5.tgz#19e57fd06ccc3848fd1891655b5a447092225b25" integrity sha512-xaYmXZtTHPAw5m+xLN8ab9C+3a8YmV3asNSPOATITbtwrfbwaLJj8h66H1WMIpALCkqsIzK3h7oQ+PdX+LQ9Eg== @@ -10086,32 +10028,31 @@ lines-and-columns@^1.1.6: resolved "https://registry.yarnpkg.com/lines-and-columns/-/lines-and-columns-1.2.4.tgz#eca284f75d2965079309dc0ad9255abb2ebc1632" integrity sha512-7ylylesZQ/PV29jhEDl3Ufjo6ZX7gCqJr5F7PKrqc93v7fzSymt1BpwEU8nAUXs8qzzvqhbjhK5QZg6Mt/HkBg== -lint-staged@^12.4.2: - version "12.4.2" - resolved "https://registry.yarnpkg.com/lint-staged/-/lint-staged-12.4.2.tgz#380a5ec5a7a23caa9420972b0f98c8192afddecd" - integrity sha512-JAJGIzY/OioIUtrRePr8go6qUxij//mL+RGGoFKU3VWQRtIHgWoHizSqH0QVn2OwrbXS9Q6CICQjfj+E5qvrXg== +lint-staged@^13.0.1: + version "13.0.1" + resolved "https://registry.yarnpkg.com/lint-staged/-/lint-staged-13.0.1.tgz#899e78065ab29b88fdd922482411121664ef66be" + integrity sha512-Ykaf4QTi0a02BF7cnq7JIPGOJxH4TkNMWhSlJdH9wOekd0X+gog47Jfh/0L31DqZe5AiydLGC7LkPqpaNm+Kvg== dependencies: cli-truncate "^3.1.0" - colorette "^2.0.16" - commander "^8.3.0" - debug "^4.3.3" - execa "^5.1.1" - lilconfig "2.0.4" - listr2 "^4.0.1" - micromatch "^4.0.4" + colorette "^2.0.17" + commander "^9.3.0" + debug "^4.3.4" + execa "^6.1.0" + lilconfig "2.0.5" + listr2 "^4.0.5" + micromatch "^4.0.5" normalize-path "^3.0.0" - object-inspect "^1.12.0" - pidtree "^0.5.0" + object-inspect "^1.12.2" + pidtree "^0.6.0" string-argv "^0.3.1" - supports-color "^9.2.1" - yaml "^1.10.2" + yaml "^2.1.1" listenercount@~1.0.1: version "1.0.1" resolved "https://registry.yarnpkg.com/listenercount/-/listenercount-1.0.1.tgz#84c8a72ab59c4725321480c975e6508342e70937" integrity sha512-3mk/Zag0+IJxeDrxSgaDPy4zZ3w05PRZeJNnlWhzFz5OkX49J4krc+A8X2d2M69vGMBEX0uyl8M+W+8gH+kBqQ== -listr2@^4.0.1: +listr2@^4.0.5: version "4.0.5" resolved "https://registry.yarnpkg.com/listr2/-/listr2-4.0.5.tgz#9dcc50221583e8b4c71c43f9c7dfd0ef546b75d5" integrity sha512-juGHV1doQdpNT3GSTs9IUN43QJb7KHdF9uqg7Vufs/tG9VTzpFphqF4pm/ICdAABGQxsyNn9CiYA3StkI6jpwA== @@ -10199,16 +10140,6 @@ lodash._reinterpolate@^3.0.0: resolved "https://registry.yarnpkg.com/lodash._reinterpolate/-/lodash._reinterpolate-3.0.0.tgz#0ccf2d89166af03b3663c796538b75ac6e114d9d" integrity sha512-xYHt68QRoYGjeeM/XOE1uJtvXQAgvszfBhjV4yvsQH0u2i9I6cI6c6/eG4Hh3UAOVn0y/xAXwmTzEay49Q//HA== -lodash.assignin@^4.0.9: - version "4.2.0" - resolved "https://registry.yarnpkg.com/lodash.assignin/-/lodash.assignin-4.2.0.tgz#ba8df5fb841eb0a3e8044232b0e263a8dc6a28a2" - integrity sha512-yX/rx6d/UTVh7sSVWVSIMjfnz95evAgDFdb1ZozC35I9mSFCkmzptOzevxjgbQUsc78NR44LVHWjsoMQXy9FDg== - -lodash.bind@^4.1.4: - version "4.2.1" - resolved "https://registry.yarnpkg.com/lodash.bind/-/lodash.bind-4.2.1.tgz#7ae3017e939622ac31b7d7d7dcb1b34db1690d35" - integrity sha512-lxdsn7xxlCymgLYo1gGvVrfHmkjDiyqVv62FAeF2i5ta72BipE1SLxw8hPEPLhD4/247Ijw07UQH7Hq/chT5LA== - lodash.curry@^4.0.1: version "4.1.1" resolved "https://registry.yarnpkg.com/lodash.curry/-/lodash.curry-4.1.1.tgz#248e36072ede906501d75966200a86dab8b23170" @@ -10219,71 +10150,26 @@ lodash.debounce@^4.0.8: resolved "https://registry.yarnpkg.com/lodash.debounce/-/lodash.debounce-4.0.8.tgz#82d79bff30a67c4005ffd5e2515300ad9ca4d7af" integrity sha512-FT1yDzDYEoYWhnSGnpE/4Kj1fLZkDFyqRb7fNt6FdYOSxlUWAtp42Eh6Wb0rGIv/m9Bgo7x4GhQbm5Ys4SG5ow== -lodash.defaults@^4.0.1: - version "4.2.0" - resolved "https://registry.yarnpkg.com/lodash.defaults/-/lodash.defaults-4.2.0.tgz#d09178716ffea4dde9e5fb7b37f6f0802274580c" - integrity sha512-qjxPLHd3r5DnsdGacqOMU6pb/avJzdh9tFX2ymgoZE27BmjXrNy/y4LoaiTeAb+O3gL8AfpJGtqfX/ae2leYYQ== - -lodash.filter@^4.4.0: - version "4.6.0" - resolved "https://registry.yarnpkg.com/lodash.filter/-/lodash.filter-4.6.0.tgz#668b1d4981603ae1cc5a6fa760143e480b4c4ace" - integrity sha512-pXYUy7PR8BCLwX5mgJ/aNtyOvuJTdZAo9EQFUvMIYugqmJxnrYaANvTbgndOzHSCSR0wnlBBfRXJL5SbWxo3FQ== - -lodash.flatten@^4.2.0: - version "4.4.0" - resolved "https://registry.yarnpkg.com/lodash.flatten/-/lodash.flatten-4.4.0.tgz#f31c22225a9632d2bbf8e4addbef240aa765a61f" - integrity sha512-C5N2Z3DgnnKr0LOpv/hKCgKdb7ZZwafIrsesve6lmzvZIRZRGaZ/l6Q8+2W7NaT+ZwO3fFlSCzCzrDCFdJfZ4g== - lodash.flow@^3.3.0: version "3.5.0" resolved "https://registry.yarnpkg.com/lodash.flow/-/lodash.flow-3.5.0.tgz#87bf40292b8cf83e4e8ce1a3ae4209e20071675a" integrity sha512-ff3BX/tSioo+XojX4MOsOMhJw0nZoUEF011LX8g8d3gvjVbxd89cCio4BCXronjxcTUIJUoqKEUA+n4CqvvRPw== -lodash.foreach@^4.3.0: - version "4.5.0" - resolved "https://registry.yarnpkg.com/lodash.foreach/-/lodash.foreach-4.5.0.tgz#1a6a35eace401280c7f06dddec35165ab27e3e53" - integrity sha512-aEXTF4d+m05rVOAUG3z4vZZ4xVexLKZGF0lIxuHZ1Hplpk/3B6Z1+/ICICYRLm7c41Z2xiejbkCkJoTlypoXhQ== - lodash.ismatch@^4.4.0: version "4.4.0" resolved "https://registry.yarnpkg.com/lodash.ismatch/-/lodash.ismatch-4.4.0.tgz#756cb5150ca3ba6f11085a78849645f188f85f37" integrity sha512-fPMfXjGQEV9Xsq/8MTSgUf255gawYRbjwMyDbcvDhXgV7enSZA0hynz6vMPnpAb5iONEzBHBPsT+0zes5Z301g== -lodash.map@^4.4.0: - version "4.6.0" - resolved "https://registry.yarnpkg.com/lodash.map/-/lodash.map-4.6.0.tgz#771ec7839e3473d9c4cde28b19394c3562f4f6d3" - integrity sha512-worNHGKLDetmcEYDvh2stPCrrQRkP20E4l0iIS7F8EvzMqBBi7ltvFN5m1HvTf1P7Jk1txKhvFcmYsCr8O2F1Q== - lodash.memoize@^4.1.2: version "4.1.2" resolved "https://registry.yarnpkg.com/lodash.memoize/-/lodash.memoize-4.1.2.tgz#bcc6c49a42a2840ed997f323eada5ecd182e0bfe" integrity sha512-t7j+NzmgnQzTAYXcsHYLgimltOV1MXHtlOWf6GjL9Kj8GK5FInw5JotxvbOs+IvV1/Dzo04/fCGfLVs7aXb4Ag== -lodash.merge@^4.4.0, lodash.merge@^4.6.2: +lodash.merge@^4.6.2: version "4.6.2" resolved "https://registry.yarnpkg.com/lodash.merge/-/lodash.merge-4.6.2.tgz#558aa53b43b661e1925a0afdfa36a9a1085fe57a" integrity sha512-0KpjqXRVvrYyCsX1swR/XTK0va6VQkQM6MNo7PqW77ByjAhoARA8EfrP1N4+KlKj8YS0ZUCtRT/YUuhyYDujIQ== -lodash.pick@^4.2.1: - version "4.4.0" - resolved "https://registry.yarnpkg.com/lodash.pick/-/lodash.pick-4.4.0.tgz#52f05610fff9ded422611441ed1fc123a03001b3" - integrity sha512-hXt6Ul/5yWjfklSGvLQl8vM//l3FtyHZeuelpzK6mm99pNvN9yTDruNZPEJZD1oWrqo+izBmB7oUfWgcCX7s4Q== - -lodash.reduce@^4.4.0: - version "4.6.0" - resolved "https://registry.yarnpkg.com/lodash.reduce/-/lodash.reduce-4.6.0.tgz#f1ab6b839299ad48f784abbf476596f03b914d3b" - integrity sha512-6raRe2vxCYBhpBu+B+TtNGUzah+hQjVdu3E17wfusjyrXBka2nBS8OH/gjVZ5PvHOhWmIZTYri09Z6n/QfnNMw== - -lodash.reject@^4.4.0: - version "4.6.0" - resolved "https://registry.yarnpkg.com/lodash.reject/-/lodash.reject-4.6.0.tgz#80d6492dc1470864bbf583533b651f42a9f52415" - integrity sha512-qkTuvgEzYdyhiJBx42YPzPo71R1aEr0z79kAv7Ixg8wPFEjgRgJdUsGMG3Hf3OYSF/kHI79XhNlt+5Ar6OzwxQ== - -lodash.some@^4.4.0: - version "4.6.0" - resolved "https://registry.yarnpkg.com/lodash.some/-/lodash.some-4.6.0.tgz#1bb9f314ef6b8baded13b549169b2a945eb68e4d" - integrity sha512-j7MJE+TuT51q9ggt4fSgVqro163BEFjAt3u97IqU+JA2DkWl80nFTrowzLpZ/BnpN7rrl0JA/593NAdd8p/scQ== - lodash.sortby@^4.7.0: version "4.7.0" resolved "https://registry.yarnpkg.com/lodash.sortby/-/lodash.sortby-4.7.0.tgz#edd14c824e2cc9c1e0b0a1b42bb5210516a42438" @@ -10393,9 +10279,9 @@ make-dir@^3.0.0, make-dir@^3.0.2, make-dir@^3.1.0: semver "^6.0.0" make-fetch-happen@^10.0.6: - version "10.1.5" - resolved "https://registry.yarnpkg.com/make-fetch-happen/-/make-fetch-happen-10.1.5.tgz#d975c0a4373de41ea05236d8182f56333511c268" - integrity sha512-mucOj2H0Jn/ax7H9K9T1bf0p1nn/mBFa551Os7ed9xRfLEx20aZhZeLslmRYfAaAqXZUGipcs+m5KOKvOH0XKA== + version "10.1.7" + resolved "https://registry.yarnpkg.com/make-fetch-happen/-/make-fetch-happen-10.1.7.tgz#b1402cb3c9fad92b380ff3a863cdae5414a42f76" + integrity sha512-J/2xa2+7zlIUKqfyXDCXFpH3ypxO4k3rgkZHPSZkyUYcBT/hM80M3oyKLM/9dVriZFiGeGGS2Ei+0v2zfhqj3Q== dependencies: agentkeepalive "^4.2.1" cacache "^16.1.0" @@ -10411,7 +10297,7 @@ make-fetch-happen@^10.0.6: minipass-pipeline "^1.2.4" negotiator "^0.6.3" promise-retry "^2.0.1" - socks-proxy-agent "^6.1.1" + socks-proxy-agent "^7.0.0" ssri "^9.0.0" make-fetch-happen@^8.0.9: @@ -10538,6 +10424,20 @@ mdast-util-to-hast@10.0.1: unist-util-position "^3.0.0" unist-util-visit "^2.0.0" +mdast-util-to-hast@^10.2.0: + version "10.2.0" + resolved "https://registry.yarnpkg.com/mdast-util-to-hast/-/mdast-util-to-hast-10.2.0.tgz#61875526a017d8857b71abc9333942700b2d3604" + integrity sha512-JoPBfJ3gBnHZ18icCwHR50orC9kNH81tiR1gs01D8Q5YpV6adHNO9nKNuFBCJQ941/32PT1a63UF/DitmS3amQ== + dependencies: + "@types/mdast" "^3.0.0" + "@types/unist" "^2.0.0" + mdast-util-definitions "^4.0.0" + mdurl "^1.0.0" + unist-builder "^2.0.0" + unist-util-generated "^1.0.0" + unist-util-position "^3.0.0" + unist-util-visit "^2.0.0" + mdast-util-to-string@^2.0.0: version "2.0.0" resolved "https://registry.yarnpkg.com/mdast-util-to-string/-/mdast-util-to-string-2.0.0.tgz#b8cfe6a713e1091cb5b728fc48885a4767f8b97b" @@ -10559,9 +10459,9 @@ media-typer@0.3.0: integrity sha512-dq+qelQ9akHpcOl/gUVRTxVIOkAJ1wR3QAvb4RsVjS8oVoFjDGTc679wJYmUmknUF5HwMLOgb5O+a3KxfWapPQ== 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== + version "3.4.4" + resolved "https://registry.yarnpkg.com/memfs/-/memfs-3.4.4.tgz#e8973cd8060548916adcca58a248e7805c715e89" + integrity sha512-W4gHNUE++1oSJVn8Y68jPXi+mkx3fXR5ITE/Ubz6EQ3xRpCN5k2CQ4AUR8094Z7211F876TyoBACGsIveqgiGA== dependencies: fs-monkey "1.0.3" @@ -10686,6 +10586,11 @@ mimic-fn@^2.1.0: resolved "https://registry.yarnpkg.com/mimic-fn/-/mimic-fn-2.1.0.tgz#7ed2c2ccccaf84d3ffcb7a69b57711fc2083401b" integrity sha512-OqbOk5oEQeAZ8WXWydlu9HJjz9WVdEIvamMCcXmuqUYjTknH/sqsWvhQ3vgwKFRR1HpjvNBKQ37nbJgYzGqGcg== +mimic-fn@^4.0.0: + version "4.0.0" + resolved "https://registry.yarnpkg.com/mimic-fn/-/mimic-fn-4.0.0.tgz#60a90550d5cb0b239cca65d893b1a53b29871ecc" + integrity sha512-vqiC06CuhBTUdZH+RYl8sFrL096vA45Ok5ISO6sE/Mr1jRbGH4Csnhi8f3wKVl7x8mO4Au7Ir9D3Oyv1VYMFJw== + mimic-response@^1.0.0, mimic-response@^1.0.1: version "1.0.1" resolved "https://registry.yarnpkg.com/mimic-response/-/mimic-response-1.0.1.tgz#4923538878eef42063cb8a3e3b0798781487ab1b" @@ -10884,9 +10789,9 @@ modify-values@^1.0.0: integrity sha512-xV2bxeN6F7oYjZWTe/YPAy6MN2M+sL4u/Rlm2AHCIVGfo2p1yGmBHQ6vHehl4bRTZBdHu3TSkWdYgkwpYzAGSw== mrmime@^1.0.0: - version "1.0.0" - resolved "https://registry.yarnpkg.com/mrmime/-/mrmime-1.0.0.tgz#14d387f0585a5233d291baba339b063752a2398b" - integrity sha512-a70zx7zFfVO7XpnQ2IX1Myh9yY4UYvfld/dikWRnsXxbyvMcfz+u6UfgNAtH+k2QqtJuzVpv6eLTx1G2+WKZbQ== + version "1.0.1" + resolved "https://registry.yarnpkg.com/mrmime/-/mrmime-1.0.1.tgz#5f90c825fad4bdd41dc914eff5d1a8cfdaf24f27" + integrity sha512-hzzEagAgDyoU1Q6yg5uI+AorQgdvMCur3FcKf7NhMKWsaYg+RnbTyHRa/9IlLF9rf455MOCtcqqrQQ83pPP7Uw== ms@2.0.0: version "2.0.0" @@ -10903,7 +10808,7 @@ ms@2.1.3, ms@^2.0.0, ms@^2.1.1: resolved "https://registry.yarnpkg.com/ms/-/ms-2.1.3.tgz#574c8138ce1d2b5861f0b44579dbadd60c6615b2" integrity sha512-6FlzubTLZG3J2a/NVCAleEhjzq5oxgHyaCU9yYXvcLsvoVaHJq/s5xXI6/XXP6tz7R9xAOtHnSO/tXtF3WRTlA== -multicast-dns@^7.2.4: +multicast-dns@^7.2.5: 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== @@ -11065,7 +10970,7 @@ node-int64@^0.4.0: resolved "https://registry.yarnpkg.com/node-int64/-/node-int64-0.4.0.tgz#87a9065cdb355d3182d8f94ce11188b825c68a3b" integrity sha512-O5lz91xSOeoXP6DulyHfllpq+Eg00MWitZIbtPfoSEvqIHdl5gfcY6hYzDWnj0qD5tz52PI08u9qUvSVeUBeHw== -node-releases@^2.0.3: +node-releases@^2.0.5: version "2.0.5" resolved "https://registry.yarnpkg.com/node-releases/-/node-releases-2.0.5.tgz#280ed5bc3eba0d96ce44897d8aee478bfb3d9666" integrity sha512-U9h1NLROZTq9uE1SNffn6WuPDg8icmi3ns4rEl/oTfIle4iLjTliCzgTsbaIFMq/Xn078/lfY/BL0GWZ+psK4Q== @@ -11255,12 +11160,19 @@ npm-run-path@^4.0.1: dependencies: path-key "^3.0.0" +npm-run-path@^5.1.0: + version "5.1.0" + resolved "https://registry.yarnpkg.com/npm-run-path/-/npm-run-path-5.1.0.tgz#bc62f7f3f6952d9894bd08944ba011a6ee7b7e00" + integrity sha512-sJOdmRGrY2sjNTRMbSvluQqg+8X7ZK61yvzBEIDhz4f8z1TZFYABsqjjCBd/0PUNE9M6QDgHJXQkGUEm7Q+l9Q== + dependencies: + path-key "^4.0.0" + npm-to-yarn@^1.0.1: version "1.0.1" resolved "https://registry.yarnpkg.com/npm-to-yarn/-/npm-to-yarn-1.0.1.tgz#6cdb95114c4ff0be50a7a2381d4d16131a5f52df" integrity sha512-bp8T8oNMfLW+N/fE0itFfSu7RReytwhqNd9skbkfHfzGYC+5CCdzS2HnaXz6JiG4AlK2eA0qlT6NJN1SoFvcWQ== -npmlog@^4.0.1, npmlog@^4.1.2: +npmlog@^4.1.2: version "4.1.2" resolved "https://registry.yarnpkg.com/npmlog/-/npmlog-4.1.2.tgz#08a7f2a8bf734604779a9efa4ad5cc717abb954b" integrity sha512-2uUqazuKlTaSI/dC8AzicUck7+IrEaOnN/e0jd3Xtt1KcGpwx30v50mL7oPyr/h9bL3E4aZccVwpwP+5W9Vjkg== @@ -11292,13 +11204,6 @@ nth-check@^2.0.1: dependencies: boolbase "^1.0.0" -nth-check@~1.0.1: - version "1.0.2" - resolved "https://registry.yarnpkg.com/nth-check/-/nth-check-1.0.2.tgz#b2bd295c37e3dd58a3bf0700376663ba4d9cf05c" - integrity sha512-WeBOdju8SnzPN5vTUJYxYUxLeXpCaVP5i5e0LF8fg7WORF2Wd7wFX/pk0tYZk7s8T+J7VLy0Da6J1+wCT0AtHg== - dependencies: - boolbase "~1.0.0" - number-is-nan@^1.0.0: version "1.0.1" resolved "https://registry.yarnpkg.com/number-is-nan/-/number-is-nan-1.0.1.tgz#097b602b53422a522c1afb8790318336941a011d" @@ -11323,7 +11228,7 @@ object-copy@^0.1.0: define-property "^0.2.5" kind-of "^3.0.3" -object-inspect@^1.12.0, object-inspect@^1.9.0: +object-inspect@^1.12.0, object-inspect@^1.12.2, object-inspect@^1.9.0: version "1.12.2" resolved "https://registry.yarnpkg.com/object-inspect/-/object-inspect-1.12.2.tgz#c0641f26394532f28ab8d796ab954e43c009a8ea" integrity sha512-z+cPxW0QGUp0mcqcsgQyLVRDoXFQbXOwBaqyF7VIgI4TWNQsDHrBpUQslRmIfAoYWdYzs6UlKJtB2XJpTaNSpQ== @@ -11423,6 +11328,13 @@ onetime@^5.1.0, onetime@^5.1.2: dependencies: mimic-fn "^2.1.0" +onetime@^6.0.0: + version "6.0.0" + resolved "https://registry.yarnpkg.com/onetime/-/onetime-6.0.0.tgz#7c24c18ed1fd2e9bca4bd26806a33613c77d34b4" + integrity sha512-1FlR+gjXK7X+AsAHso35MnyN5KqGwJRi/31ft6x0M194ht7S+rWAvd7PHss9xSKMzE0asv1pyIHaJYq+BbacAQ== + dependencies: + mimic-fn "^4.0.0" + open@^8.0.9, open@^8.4.0: version "8.4.0" resolved "https://registry.yarnpkg.com/open/-/open-8.4.0.tgz#345321ae18f8138f82565a910fdc6b39e8c244f8" @@ -11610,9 +11522,9 @@ package-json@^6.3.0: semver "^6.2.0" pacote@^13.0.3, pacote@^13.0.5, pacote@^13.4.1: - version "13.5.0" - resolved "https://registry.yarnpkg.com/pacote/-/pacote-13.5.0.tgz#e2c745dc320513a98b9403e92b366a1ba6a4db94" - integrity sha512-yekp0ykEsaBH0t0bYA/89R+ywdYV5ZnEdg4YMIfqakSlpIhoF6b8+aEUm8NZpfWRgmy6lxgywcW05URhLRogVQ== + version "13.6.0" + resolved "https://registry.yarnpkg.com/pacote/-/pacote-13.6.0.tgz#79ea3d3ae5a2b29e2994dcf18d75494e8d888032" + integrity sha512-zHmuCwG4+QKnj47LFlW3LmArwKoglx2k5xtADiMCivVWPgNRP5QyLDGOIjGjwOe61lhl1rO63m/VxT16pEHLWg== dependencies: "@npmcli/git" "^3.0.0" "@npmcli/installed-package-contents" "^1.0.7" @@ -11703,9 +11615,9 @@ parse-numeric-range@^1.3.0: integrity sha512-twN+njEipszzlMJd4ONUYgSfZPDxgHhT9Ahed5uTigpQn90FggW4SA/AIPq/6a149fTbE9qBEcSwE3FAEp6wQQ== parse-path@^4.0.0: - version "4.0.3" - resolved "https://registry.yarnpkg.com/parse-path/-/parse-path-4.0.3.tgz#82d81ec3e071dcc4ab49aa9f2c9c0b8966bb22bf" - integrity sha512-9Cepbp2asKnWTJ9x2kpw6Fe8y9JDbqwahGCTvklzd/cEq5C5JC59x2Xb0Kx+x0QZ8bvNquGO8/BWP0cwBHzSAA== + version "4.0.4" + resolved "https://registry.yarnpkg.com/parse-path/-/parse-path-4.0.4.tgz#4bf424e6b743fb080831f03b536af9fc43f0ffea" + integrity sha512-Z2lWUis7jlmXC1jeOG9giRO2+FsuyNipeQ43HAjqAZjwSe3SEf+q/84FGPHoso3kyntbxa4c4i77t3m6fGf8cw== dependencies: is-ssh "^1.3.0" protocols "^1.4.0" @@ -11742,7 +11654,7 @@ parse5@6.0.1, parse5@^6.0.0, parse5@^6.0.1: resolved "https://registry.yarnpkg.com/parse5/-/parse5-6.0.1.tgz#e1a1c085c569b3dc08321184f19a39cc27f7c30b" integrity sha512-Ofn/CTFzRGTTxwpNEs9PP93gXShHcTq255nzRYSKe8AkVpZY7e1fpmTfOyoIvjP5HG7Z2ZM7VS9PPhQGW2pOpw== -parse5@^5.0.0, parse5@^5.1.1: +parse5@^5.1.1: version "5.1.1" resolved "https://registry.yarnpkg.com/parse5/-/parse5-5.1.1.tgz#f68e4e5ba1852ac2cadc00f4555fff6c2abb6178" integrity sha512-ugq4DFI0Ptb+WWjAdOK16+u/nHfiIrcE+sh8kZMaM0WllQKLI9rOUq6c2b7cwPkXdzfQESqvoqK6ug7U/Yyzug== @@ -11802,6 +11714,11 @@ path-key@^3.0.0, path-key@^3.1.0: resolved "https://registry.yarnpkg.com/path-key/-/path-key-3.1.1.tgz#581f6ade658cbba65a0d3380de7753295054f375" integrity sha512-ojmeN0qd+y0jszEtoY48r0Peq5dwMEkIlCOu6Q5f41lfkswXuKtYrhgoTpLnyIcHm24Uhqx+5Tqm2InSwLhE6Q== +path-key@^4.0.0: + version "4.0.0" + resolved "https://registry.yarnpkg.com/path-key/-/path-key-4.0.0.tgz#295588dc3aee64154f877adb9d780b81c554bf18" + integrity sha512-haREypq7xkM7ErfgIyA0z+Bj4AGKlMSdlQE2jvJo6huWD1EdkKYV+G/T4nq0YEF2vgTT8kqMFKo1uHn950r4SQ== + path-parse@^1.0.6, path-parse@^1.0.7: version "1.0.7" resolved "https://registry.yarnpkg.com/path-parse/-/path-parse-1.0.7.tgz#fbc114b60ca42b30d9daf5858e4bd68bbedb6735" @@ -11861,10 +11778,10 @@ pidtree@^0.3.0: 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" - integrity sha512-9nxspIM7OpZuhBxPg73Zvyq7j1QMPMPsGKTqRc2XOaFQauDvoNz9fM1Wdkjmeo7l9GXOZiRs97sPkuayl39wjA== +pidtree@^0.6.0: + version "0.6.0" + resolved "https://registry.yarnpkg.com/pidtree/-/pidtree-0.6.0.tgz#90ad7b6d42d5841e69e0a2419ef38f8883aa057c" + integrity sha512-eG2dWTVw5bzqGRztnHExczNxt5VGsE6OwTeCG3fdUf9KBsZzO3R5OIIIzWR+iZA0NtZ+RDVdaoE2dK1cn6jH4g== pify@^2.3.0: version "2.3.0" @@ -11935,18 +11852,18 @@ postcss-colormin@^5.3.0: colord "^2.9.1" postcss-value-parser "^4.2.0" -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== +postcss-convert-values@^5.1.2: + version "5.1.2" + resolved "https://registry.yarnpkg.com/postcss-convert-values/-/postcss-convert-values-5.1.2.tgz#31586df4e184c2e8890e8b34a0b9355313f503ab" + integrity sha512-c6Hzc4GAv95B7suy4udszX9Zy4ETyMCgFPUDtWjdFTKH1SE9eFY/jEpHSwTH1QPuwxHpWslhckUQWbNRM4ho5g== dependencies: browserslist "^4.20.3" postcss-value-parser "^4.2.0" -postcss-discard-comments@^5.1.1: - version "5.1.1" - resolved "https://registry.yarnpkg.com/postcss-discard-comments/-/postcss-discard-comments-5.1.1.tgz#e90019e1a0e5b99de05f63516ce640bd0df3d369" - integrity sha512-5JscyFmvkUxz/5/+TB3QTTT9Gi9jHkcn8dcmmuN68JQcv3aQg4y88yEHHhwFB52l/NkaJ43O0dbksGMAo49nfQ== +postcss-discard-comments@^5.1.2: + version "5.1.2" + resolved "https://registry.yarnpkg.com/postcss-discard-comments/-/postcss-discard-comments-5.1.2.tgz#8df5e81d2925af2780075840c1526f0660e53696" + integrity sha512-+L8208OVbHVF2UQf1iDmRcbdjJkuBF6IS29yBDSiWUIzpYaAhtNl6JYnYm12FnkeCwQqF5LeklOu6rAqgfBZqQ== postcss-discard-duplicates@^5.1.0: version "5.1.0" @@ -12008,10 +11925,10 @@ postcss-merge-longhand@^5.1.5: postcss-value-parser "^4.2.0" stylehacks "^5.1.0" -postcss-merge-rules@^5.1.1: - version "5.1.1" - resolved "https://registry.yarnpkg.com/postcss-merge-rules/-/postcss-merge-rules-5.1.1.tgz#d327b221cd07540bcc8d9ff84446d8b404d00162" - integrity sha512-8wv8q2cXjEuCcgpIB1Xx1pIy8/rhMPIQqYKNzEdyx37m6gpq83mQQdCxgIkFgliyEnKvdwJf/C61vN4tQDq4Ww== +postcss-merge-rules@^5.1.2: + version "5.1.2" + resolved "https://registry.yarnpkg.com/postcss-merge-rules/-/postcss-merge-rules-5.1.2.tgz#7049a14d4211045412116d79b751def4484473a5" + integrity sha512-zKMUlnw+zYCWoPN6yhPjtcEdlJaMUZ0WyVcxTAmw3lkkN/NDMRkOkiuctQEoWAOvH7twaxUUdvBWl0d4+hifRQ== dependencies: browserslist "^4.16.6" caniuse-api "^3.0.0" @@ -12043,10 +11960,10 @@ postcss-minify-params@^5.1.3: cssnano-utils "^3.1.0" postcss-value-parser "^4.2.0" -postcss-minify-selectors@^5.2.0: - version "5.2.0" - resolved "https://registry.yarnpkg.com/postcss-minify-selectors/-/postcss-minify-selectors-5.2.0.tgz#17c2be233e12b28ffa8a421a02fc8b839825536c" - integrity sha512-vYxvHkW+iULstA+ctVNx0VoRAR4THQQRkG77o0oa4/mBS0OzGvvzLIvHDv/nNEM0crzN2WIyFU5X7wZhaUK3RA== +postcss-minify-selectors@^5.2.1: + version "5.2.1" + resolved "https://registry.yarnpkg.com/postcss-minify-selectors/-/postcss-minify-selectors-5.2.1.tgz#d4e7e6b46147b8117ea9325a915a801d5fe656c6" + integrity sha512-nPJu7OjZJTsVUmPdm2TcaiohIwxP+v8ha9NehQ2ye9szv4orirRU3SDdtUmKH+10nzn0bAyOXZ0UEr7OpvLehg== dependencies: postcss-selector-parser "^6.0.5" @@ -12141,10 +12058,10 @@ postcss-normalize-whitespace@^5.1.1: dependencies: postcss-value-parser "^4.2.0" -postcss-ordered-values@^5.1.1: - version "5.1.1" - resolved "https://registry.yarnpkg.com/postcss-ordered-values/-/postcss-ordered-values-5.1.1.tgz#0b41b610ba02906a3341e92cab01ff8ebc598adb" - integrity sha512-7lxgXF0NaoMIgyihL/2boNAEZKiW0+HkMhdKMTD93CjW8TdCy2hSdj8lsAo+uwm7EDG16Da2Jdmtqpedl0cMfw== +postcss-ordered-values@^5.1.2: + version "5.1.2" + resolved "https://registry.yarnpkg.com/postcss-ordered-values/-/postcss-ordered-values-5.1.2.tgz#daffacd4abf327d52d5ac570b59dfbcf4b836614" + integrity sha512-wr2avRbW4HS2XE2ZCqpfp4N/tDC6GZKZ+SVP8UBTOVS8QWrc4TD8MYrebJrvVVlGPKszmiSCzue43NDiVtgDmg== dependencies: cssnano-utils "^3.1.0" postcss-value-parser "^4.2.0" @@ -12239,9 +12156,9 @@ postcss@^8.2.x, postcss@^8.3.11, postcss@^8.4.13, postcss@^8.4.14, postcss@^8.4. source-map-js "^1.0.2" prebuild-install@^7.1.0: - version "7.1.0" - resolved "https://registry.yarnpkg.com/prebuild-install/-/prebuild-install-7.1.0.tgz#991b6ac16c81591ba40a6d5de93fb33673ac1370" - integrity sha512-CNcMgI1xBypOyGqjp3wOc8AAo1nMhZS3Cwd3iHIxOdAUbb+YxdNuM4Z5iIrZ8RLvOsf3F3bl7b7xGq6DjQoNYA== + version "7.1.1" + resolved "https://registry.yarnpkg.com/prebuild-install/-/prebuild-install-7.1.1.tgz#de97d5b34a70a0c81334fd24641f2a1702352e45" + integrity sha512-jAXscXWMcCK8GgCoHOfIr0ODh5ai8mj63L2nWrjuAgXE6tDyYGnx4/8o/rCgU+B4JSyZBKbeZqzhtwtC3ovxjw== dependencies: detect-libc "^2.0.0" expand-template "^2.0.3" @@ -12250,7 +12167,6 @@ prebuild-install@^7.1.0: mkdirp-classic "^0.5.3" napi-build-utils "^1.0.1" node-abi "^3.3.0" - npmlog "^4.0.1" pump "^3.0.0" rc "^1.2.7" simple-get "^4.0.0" @@ -12299,10 +12215,10 @@ pretty-format@^27.0.0, pretty-format@^27.5.1: ansi-styles "^5.0.0" react-is "^17.0.1" -pretty-format@^28.1.0: - version "28.1.0" - resolved "https://registry.yarnpkg.com/pretty-format/-/pretty-format-28.1.0.tgz#8f5836c6a0dfdb834730577ec18029052191af55" - integrity sha512-79Z4wWOYCdvQkEoEuSlBhHJqWeZ8D8YRPiPctJFCtvuaClGpiwiQYSCUOE6IEKUbbFukKOTFIUAXE8N4EQTo1Q== +pretty-format@^28.1.1: + version "28.1.1" + resolved "https://registry.yarnpkg.com/pretty-format/-/pretty-format-28.1.1.tgz#f731530394e0f7fcd95aba6b43c50e02d86b95cb" + integrity sha512-wwJbVTGFHeucr5Jw2bQ9P+VYHyLdAqedFLEkdQUVaBF/eiidDwH5OpilINq4mEfhbCjLnirt6HTTDhv1HaTIQw== dependencies: "@jest/schemas" "^28.0.2" ansi-regex "^5.0.1" @@ -12463,13 +12379,20 @@ q@^1.5.1: resolved "https://registry.yarnpkg.com/q/-/q-1.5.1.tgz#7e32f75b41381291d04611f1bf14109ac00651d7" integrity sha512-kV/CThkXo6xyFEZUugw/+pIOywXcDbFYgSct5cT3gqlbkBE1SJdwy6UQoZvodiWF/ckQLZyDE/Bu1M6gVu5lVw== -qs@6.10.3, qs@^6.9.4: +qs@6.10.3: version "6.10.3" resolved "https://registry.yarnpkg.com/qs/-/qs-6.10.3.tgz#d6cde1b2ffca87b5aa57889816c5f81535e22e8e" integrity sha512-wr7M2E0OFRfIfJZjKGieI8lBKb7fRCH4Fv5KNPEs7gJ8jadvotdsS08PzOKR7opXhZ/Xkjtt3WF9g38drmyRqQ== dependencies: side-channel "^1.0.4" +qs@^6.9.4: + version "6.10.5" + resolved "https://registry.yarnpkg.com/qs/-/qs-6.10.5.tgz#974715920a80ff6a262264acd2c7e6c2a53282b4" + integrity sha512-O5RlPh0VFtR78y79rgcgKK4wbAI0C5zGVLztOIdpWX6ep368q5Hv6XRxDvXuZ9q3C6v+e3n8UfZZJw7IIG27eQ== + dependencies: + side-channel "^1.0.4" + query-string@^6.13.8: version "6.14.1" resolved "https://registry.yarnpkg.com/query-string/-/query-string-6.14.1.tgz#7ac2dca46da7f309449ba0f86b1fd28255b0c86a" @@ -12624,7 +12547,7 @@ react-helmet-async@*, react-helmet-async@^1.3.0: react-fast-compare "^3.2.0" shallowequal "^1.1.0" -"react-is@^16.12.0 || ^17.0.0 || ^18.0.0", react-is@^18.0.0: +"react-is@^16.12.0 || ^17.0.0 || ^18.0.0", "react-is@^17.0.1 || ^18.0.0", react-is@^18.0.0: version "18.1.0" resolved "https://registry.yarnpkg.com/react-is/-/react-is-18.1.0.tgz#61aaed3096d30eacf2a2127118b5b41387d32a67" integrity sha512-Fl7FuabXsJnV5Q1qIOQwx/sagGF18kogb4gpfcG4gjLBWO0WDiiz1ko/ExayuxE7InyQkBLkxRFG5oxY6Uu3Kg== @@ -12763,15 +12686,15 @@ react-textarea-autosize@^8.3.2: use-composed-ref "^1.3.0" use-latest "^1.2.1" -react-waypoint@^10.1.0: - version "10.1.0" - resolved "https://registry.yarnpkg.com/react-waypoint/-/react-waypoint-10.1.0.tgz#6ab522a61bd52946260e4a78b3182759a97b40ec" - integrity sha512-wiVF0lTslVm27xHbnvUUADUrcDjrQxAp9lEYGExvcoEBScYbXu3Kt++pLrfj6CqOeeRAL4HcX8aANVLSn6bK0Q== +react-waypoint@^10.3.0: + version "10.3.0" + resolved "https://registry.yarnpkg.com/react-waypoint/-/react-waypoint-10.3.0.tgz#fcc60e86c6c9ad2174fa58d066dc6ae54e3df71d" + integrity sha512-iF1y2c1BsoXuEGz08NoahaLFIGI9gTUAAOKip96HUmylRT6DUtpgoBPjk/Y8dfcFVmfVDvUzWjNXpZyKTOV0SQ== dependencies: "@babel/runtime" "^7.12.5" consolidated-events "^1.1.0 || ^2.0.0" prop-types "^15.0.0" - react-is "^17.0.1" + react-is "^17.0.1 || ^18.0.0" react@^17.0.2: version "17.0.2" @@ -13100,15 +13023,6 @@ rehype-katex@^6.0.2: unist-util-remove-position "^4.0.0" unist-util-visit "^4.0.0" -rehype-parse@^6.0.2: - version "6.0.2" - resolved "https://registry.yarnpkg.com/rehype-parse/-/rehype-parse-6.0.2.tgz#aeb3fdd68085f9f796f1d3137ae2b85a98406964" - integrity sha512-0S3CpvpTAgGmnz8kiCyFLGuW5yA4OQhyNTm/nwPopZ7+PI11WnGl1TTWTGv/2hPEe/g2jRLlhVVSsoDH8waRug== - dependencies: - hast-util-from-parse5 "^5.0.0" - parse5 "^5.0.0" - xtend "^4.0.0" - rehype-parse@^7.0.1: version "7.0.1" resolved "https://registry.yarnpkg.com/rehype-parse/-/rehype-parse-7.0.1.tgz#58900f6702b56767814afc2a9efa2d42b1c90c57" @@ -13127,20 +13041,18 @@ rehype-parse@^8.0.0: parse5 "^6.0.0" unified "^10.0.0" +rehype-stringify@^8.0.0: + version "8.0.0" + resolved "https://registry.yarnpkg.com/rehype-stringify/-/rehype-stringify-8.0.0.tgz#9b6afb599bcf3165f10f93fc8548f9a03d2ec2ba" + integrity sha512-VkIs18G0pj2xklyllrPSvdShAV36Ff3yE5PUO9u36f6+2qJFnn22Z5gKwBOwgXviux4UC7K+/j13AnZfPICi/g== + dependencies: + hast-util-to-html "^7.1.1" + relateurl@^0.2.7: version "0.2.7" resolved "https://registry.yarnpkg.com/relateurl/-/relateurl-0.2.7.tgz#54dbf377e51440aca90a4cd274600d3ff2d888a9" integrity sha512-G08Dxvm4iDN3MLM0EsP62EDV9IuhXPR6blNz6Utcp7zyV3tr4HVNINt6MpaRWbxoOHT3Q7YN2P+jaHX8vUbgog== -remark-admonitions@^1.2.1: - version "1.2.1" - resolved "https://registry.yarnpkg.com/remark-admonitions/-/remark-admonitions-1.2.1.tgz#87caa1a442aa7b4c0cafa04798ed58a342307870" - integrity sha512-Ji6p68VDvD+H1oS95Fdx9Ar5WA2wcDA4kwrrhVU7fGctC6+d3uiMICu7w7/2Xld+lnU7/gi+432+rRbup5S8ow== - dependencies: - rehype-parse "^6.0.2" - unified "^8.4.2" - unist-util-visit "^2.0.1" - remark-emoji@^2.2.0: version "2.2.0" resolved "https://registry.yarnpkg.com/remark-emoji/-/remark-emoji-2.2.0.tgz#1c702090a1525da5b80e15a8f963ef2c8236cac7" @@ -13196,6 +13108,13 @@ remark-parse@8.0.3, remark-parse@^8.0.0, remark-parse@^8.0.2: vfile-location "^3.0.0" xtend "^4.0.1" +remark-rehype@^8.1.0: + version "8.1.0" + resolved "https://registry.yarnpkg.com/remark-rehype/-/remark-rehype-8.1.0.tgz#610509a043484c1e697437fa5eb3fd992617c945" + integrity sha512-EbCu9kHgAxKmW1yEYjx3QafMyGY3q8noUbNUI5xyKbaFP89wbhDrKxyIQNukNYthzjNHZu6J7hwFg7hRm1svYA== + dependencies: + mdast-util-to-hast "^10.2.0" + remark-squeeze-paragraphs@4.0.0: version "4.0.0" resolved "https://registry.yarnpkg.com/remark-squeeze-paragraphs/-/remark-squeeze-paragraphs-4.0.0.tgz#76eb0e085295131c84748c8e43810159c5653ead" @@ -13401,9 +13320,9 @@ rollup-plugin-terser@^7.0.0: terser "^5.0.0" rollup@^2.43.1: - version "2.75.0" - resolved "https://registry.yarnpkg.com/rollup/-/rollup-2.75.0.tgz#c4c1c2bf46c706823f5f0eee046c7a1cbdda5038" - integrity sha512-1/wxtweHJ7YwI2AIK3ZgCBU3nbW8sLnBIFwN46cwOTnVzt8f1o6J8zPKjwoiuADvzSjmnLqJce31p0q2vQ+dqw== + version "2.75.6" + resolved "https://registry.yarnpkg.com/rollup/-/rollup-2.75.6.tgz#ac4dc8600f95942a0180f61c7c9d6200e374b439" + integrity sha512-OEf0TgpC9vU6WGROJIk1JA3LR5vk/yvqlzxqdrE2CzzXnqKXNzbAwlWUXis8RS3ZPe7LAq+YUxsRa0l3r27MLA== optionalDependencies: fsevents "~2.3.2" @@ -13697,10 +13616,10 @@ shallowequal@^1.1.0: resolved "https://registry.yarnpkg.com/shallowequal/-/shallowequal-1.1.0.tgz#188d521de95b9087404fd4dcb68b13df0ae4e7f8" integrity sha512-y0m1JoUZSlPAjXVtPPW70aZWfIL/dSP7AFkRnniLCrK/8MDKog3TySTBmckD+RObVxH0v4Tox67+F14PdED2oQ== -sharp@^0.30.5: - version "0.30.5" - resolved "https://registry.yarnpkg.com/sharp/-/sharp-0.30.5.tgz#81c36fd05624978384ac6bd2744d23f9c82edefd" - integrity sha512-0T28KxqY4DzUMLSAp1/IhGVeHpPIQyp1xt7esmuXCAfyi/+6tYMUeRhQok+E/+E52Yk5yFjacXp90cQOkmkl4w== +sharp@^0.30.6: + version "0.30.6" + resolved "https://registry.yarnpkg.com/sharp/-/sharp-0.30.6.tgz#02264e9826b5f1577509f70bb627716099778873" + integrity sha512-lSdVxFxcndzcXggDrak6ozdGJgmIgES9YVZWtAFrwi+a/H5vModaf51TghBtMPw+71sLxUsTy2j+aB7qLIODQg== dependencies: color "^4.2.3" detect-libc "^2.0.1" @@ -13879,7 +13798,7 @@ snapdragon@^0.8.1: source-map-resolve "^0.5.0" use "^3.1.0" -sockjs@^0.3.21: +sockjs@^0.3.24: version "0.3.24" resolved "https://registry.yarnpkg.com/sockjs/-/sockjs-0.3.24.tgz#c9bc8995f33a111bea0395ec30aa3206bdb5ccce" integrity sha512-GJgLTZ7vYb/JtPSSZ10hsOYIvEYsjbNU+zPdIHcUaWVNUEPivzxku31865sSSud0Da0W4lEeOPlmw93zLQchuQ== @@ -13897,10 +13816,19 @@ socks-proxy-agent@^5.0.0: debug "4" socks "^2.3.3" -socks-proxy-agent@^6.0.0, socks-proxy-agent@^6.1.1: - version "6.2.0" - resolved "https://registry.yarnpkg.com/socks-proxy-agent/-/socks-proxy-agent-6.2.0.tgz#f6b5229cc0cbd6f2f202d9695f09d871e951c85e" - integrity sha512-wWqJhjb32Q6GsrUqzuFkukxb/zzide5quXYcMVpIjxalDBBYy2nqKCFQ/9+Ie4dvOYSQdOk3hUlZSdzZOd3zMQ== +socks-proxy-agent@^6.0.0: + version "6.2.1" + resolved "https://registry.yarnpkg.com/socks-proxy-agent/-/socks-proxy-agent-6.2.1.tgz#2687a31f9d7185e38d530bef1944fe1f1496d6ce" + integrity sha512-a6KW9G+6B3nWZ1yB8G7pJwL3ggLy1uTzKAgCb7ttblwqdz9fMGJUuTy3uFzEP48FAs9FLILlmzDlE2JJhVQaXQ== + dependencies: + agent-base "^6.0.2" + debug "^4.3.3" + socks "^2.6.2" + +socks-proxy-agent@^7.0.0: + version "7.0.0" + resolved "https://registry.yarnpkg.com/socks-proxy-agent/-/socks-proxy-agent-7.0.0.tgz#dc069ecf34436621acb41e3efa66ca1b5fed15b6" + integrity sha512-Fgl0YPZ902wEsAyiQ+idGd1A7rSFx/ayC1CQVMw5P+EQx2V0SgpGtf6OKFhVjPflPUl9YMmEOnmfjCdMUsygww== dependencies: agent-base "^6.0.2" debug "^4.3.3" @@ -13933,11 +13861,6 @@ sort-keys@^4.0.0: dependencies: is-plain-obj "^2.0.0" -source-list-map@^2.0.0: - version "2.0.1" - resolved "https://registry.yarnpkg.com/source-list-map/-/source-list-map-2.0.1.tgz#3993bd873bfc48479cca9ea3a547835c7c154b34" - integrity sha512-qnQ7gVMxGNxsiL4lEuJwe/To8UnK7fAnmbGEEH8RpLouuKbeEm0lhbQVFIrNSuB+G7tVrAlVsZgETT5nljf+Iw== - source-map-js@^1.0.2: version "1.0.2" resolved "https://registry.yarnpkg.com/source-map-js/-/source-map-js-1.0.2.tgz#adbc361d9c62df380125e7f161f71c826f1e490c" @@ -13986,11 +13909,11 @@ source-map@^0.6.0, source-map@^0.6.1, source-map@~0.6.0, source-map@~0.6.1: integrity sha512-UjgapumWlbMhkBgzT7Ykc5YXUT46F0iKu8SGXq0bcwP5dz/h0Plj6enJqjz1Zbq2l5WaqYnrVbwWOWMyF3F47g== source-map@^0.7.3: - version "0.7.3" - resolved "https://registry.yarnpkg.com/source-map/-/source-map-0.7.3.tgz#5302f8169031735226544092e64981f751750383" - integrity sha512-CkCj6giN3S+n9qrYiBTX5gystlENnRW5jZeNLHpe6aue+SrHcG5VYwujhW9s4dY31mEGsxBDrHR6oI69fTXsaQ== + version "0.7.4" + resolved "https://registry.yarnpkg.com/source-map/-/source-map-0.7.4.tgz#a9bbe705c9d8846f4e08ff6765acf0f1b0898656" + integrity sha512-l3BikUxvPOcn5E74dZiq5BGsTb5yEwhaTSzccU6t4sDOH8NWJCstKO5QT2CvtFoK6F0saL7p9xHAqHOlCPJygA== -source-map@^0.8.0-beta.0, source-map@~0.8.0-beta.0: +source-map@^0.8.0-beta.0: version "0.8.0-beta.0" resolved "https://registry.yarnpkg.com/source-map/-/source-map-0.8.0-beta.0.tgz#d4c1bb42c3f7ee925f005927ba10709e0d1d1f11" integrity sha512-2ymg6oRBpebeZi9UUNsgQ89bhx01TcTkmNTGnNO88imTmbSgy4nfujrgVEFKWpMTEGA11EDkTt7mqObTPdigIA== @@ -14061,11 +13984,6 @@ spdy@^4.0.2: select-hose "^2.0.0" spdy-transport "^3.0.0" -specificity@^0.4.1: - version "0.4.1" - resolved "https://registry.yarnpkg.com/specificity/-/specificity-0.4.1.tgz#aab5e645012db08ba182e151165738d00887b019" - integrity sha512-1klA3Gi5PD1Wv9Q0wUoOQN1IWAuPu0D1U03ThXTr0cJ20+/iq2tHSDnK7Kk/0LXJ1ztUB2/1Os0wKmfyNgUQfg== - split-on-first@^1.0.0: version "1.1.0" resolved "https://registry.yarnpkg.com/split-on-first/-/split-on-first-1.1.0.tgz#f610afeee3b12bce1d0c30425e76398b78249a5f" @@ -14315,6 +14233,11 @@ strip-final-newline@^2.0.0: resolved "https://registry.yarnpkg.com/strip-final-newline/-/strip-final-newline-2.0.0.tgz#89b852fb2fcbe936f6f4b3187afb0a12c1ab58ad" integrity sha512-BrpvfNAE3dcvq7ll3xVumzjKjZQ5tI1sEUIKr3Uoks0XUl45St3FlatVqef9prk4jRDzhW6WZg+3bk93y6pLjA== +strip-final-newline@^3.0.0: + version "3.0.0" + resolved "https://registry.yarnpkg.com/strip-final-newline/-/strip-final-newline-3.0.0.tgz#52894c313fbff318835280aed60ff71ebf12b8fd" + integrity sha512-dOESqjYr96iWYylGObzd39EuNTa5VJxyvVAEm5Jnh7KGo75V43Hk1odPQkNDyXNmUR6k+gEiDVXnjB8HJ3crXw== + strip-indent@^3.0.0: version "3.0.0" resolved "https://registry.yarnpkg.com/strip-indent/-/strip-indent-3.0.0.tgz#c32e1cee940b6b3432c771bc2c54bcce73cd3001" @@ -14366,27 +14289,28 @@ stylelint-config-prettier@^9.0.3: resolved "https://registry.yarnpkg.com/stylelint-config-prettier/-/stylelint-config-prettier-9.0.3.tgz#0dccebeff359dcc393c9229184408b08964d561c" integrity sha512-5n9gUDp/n5tTMCq1GLqSpA30w2sqWITSSEiAWQlpxkKGAUbjcemQ0nbkRvRUa0B1LgD3+hCvdL7B1eTxy1QHJg== -stylelint-config-recommended@^7.0.0: - version "7.0.0" - resolved "https://registry.yarnpkg.com/stylelint-config-recommended/-/stylelint-config-recommended-7.0.0.tgz#7497372ae83ab7a6fffc18d7d7b424c6480ae15e" - integrity sha512-yGn84Bf/q41J4luis1AZ95gj0EQwRX8lWmGmBwkwBNSkpGSpl66XcPTulxGa/Z91aPoNGuIGBmFkcM1MejMo9Q== +stylelint-config-recommended@^8.0.0: + version "8.0.0" + resolved "https://registry.yarnpkg.com/stylelint-config-recommended/-/stylelint-config-recommended-8.0.0.tgz#7736be9984246177f017c39ec7b1cd0f19ae9117" + integrity sha512-IK6dWvE000+xBv9jbnHOnBq01gt6HGVB2ZTsot+QsMpe82doDQ9hvplxfv4YnpEuUwVGGd9y6nbaAnhrjcxhZQ== -stylelint-config-standard@^25.0.0: - version "25.0.0" - resolved "https://registry.yarnpkg.com/stylelint-config-standard/-/stylelint-config-standard-25.0.0.tgz#2c916984e6655d40d6e8748b19baa8603b680bff" - integrity sha512-21HnP3VSpaT1wFjFvv9VjvOGDtAviv47uTp3uFmzcN+3Lt+RYRv6oAplLaV51Kf792JSxJ6svCJh/G18E9VnCA== +stylelint-config-standard@^26.0.0: + version "26.0.0" + resolved "https://registry.yarnpkg.com/stylelint-config-standard/-/stylelint-config-standard-26.0.0.tgz#4701b8d582d34120eec7d260ba779e4c2d953635" + integrity sha512-hUuB7LaaqM8abvkOO84wh5oYSkpXgTzHu2Zza6e7mY+aOmpNTjoFBRxSLlzY0uAOMWEFx0OMKzr+reG1BUtcqQ== dependencies: - stylelint-config-recommended "^7.0.0" + stylelint-config-recommended "^8.0.0" -stylelint@^14.8.3, stylelint@^14.8.5: - version "14.8.5" - resolved "https://registry.yarnpkg.com/stylelint/-/stylelint-14.8.5.tgz#0fcbf5b6821283b5a249dde36d70f1158da0a2a3" - integrity sha512-e3t4H/hlWlspkcNUrkhf44RU3OpPTA7uBOoREGBzSwdEF+2g/+gbZq7WEpMP7BpopcSe/uLaTvDuL+URL7cdnQ== +stylelint@^14.9.1: + version "14.9.1" + resolved "https://registry.yarnpkg.com/stylelint/-/stylelint-14.9.1.tgz#6494ed38f148b1e75b402d678a3b6a8aae86dfda" + integrity sha512-RdAkJdPiLqHawCSnu21nE27MjNXaVd4WcOHA4vK5GtIGjScfhNnaOuWR2wWdfKFAvcWQPOYe311iveiVKSmwsA== dependencies: + "@csstools/selector-specificity" "^2.0.1" balanced-match "^2.0.0" colord "^2.9.2" cosmiconfig "^7.0.1" - css-functions-list "^3.0.1" + css-functions-list "^3.1.0" debug "^4.3.4" execall "^2.0.0" fast-glob "^3.2.11" @@ -14414,7 +14338,6 @@ stylelint@^14.8.3, stylelint@^14.8.5: postcss-selector-parser "^6.0.10" postcss-value-parser "^4.2.0" resolve-from "^5.0.0" - specificity "^0.4.1" string-width "^4.2.3" strip-ansi "^6.0.1" style-search "^0.1.0" @@ -14445,7 +14368,7 @@ supports-color@^8.0.0: dependencies: has-flag "^4.0.0" -supports-color@^9.2.1, supports-color@^9.2.2: +supports-color@^9.2.2: version "9.2.2" resolved "https://registry.yarnpkg.com/supports-color/-/supports-color-9.2.2.tgz#502acaf82f2b7ee78eb7c83dcac0f89694e5a7bb" integrity sha512-XC6g/Kgux+rJXmwokjm9ECpD6k/smUoS5LKlUCcsYr4IY3rW0XyAympon2RmxGrlnZURMpg5T18gWDP9CsHXFA== @@ -14486,10 +14409,10 @@ svgo@^2.5.0, svgo@^2.7.0: picocolors "^1.0.0" stable "^0.1.8" -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== +swc-loader@^0.2.3: + version "0.2.3" + resolved "https://registry.yarnpkg.com/swc-loader/-/swc-loader-0.2.3.tgz#6792f1c2e4c9ae9bf9b933b3e010210e270c186d" + integrity sha512-D1p6XXURfSPleZZA/Lipb3A8pZ17fP4NObZvFCDjK/OKljroqDpPmsBdTraWhVBqUNpcWBQY1imWdoPScRlQ7A== symbol-tree@^3.2.4: version "3.2.4" @@ -14603,25 +14526,25 @@ terminal-link@^2.0.0: ansi-escapes "^4.2.1" supports-hyperlinks "^2.0.0" -terser-webpack-plugin@^5.1.3, terser-webpack-plugin@^5.3.1: - version "5.3.1" - resolved "https://registry.yarnpkg.com/terser-webpack-plugin/-/terser-webpack-plugin-5.3.1.tgz#0320dcc270ad5372c1e8993fabbd927929773e54" - integrity sha512-GvlZdT6wPQKbDNW/GDQzZFg/j4vKU96yl2q6mcUkzKOgW4gwf1Z8cZToUCrz31XHlPWH8MVb1r2tFtdDtTGJ7g== +terser-webpack-plugin@^5.1.3, terser-webpack-plugin@^5.3.3: + version "5.3.3" + resolved "https://registry.yarnpkg.com/terser-webpack-plugin/-/terser-webpack-plugin-5.3.3.tgz#8033db876dd5875487213e87c627bca323e5ed90" + integrity sha512-Fx60G5HNYknNTNQnzQ1VePRuu89ZVYWfjRAeT5rITuCY/1b08s49e5kSQwHDirKZWuoKOBRFS98EUUoZ9kLEwQ== dependencies: + "@jridgewell/trace-mapping" "^0.3.7" jest-worker "^27.4.5" schema-utils "^3.1.1" serialize-javascript "^6.0.0" - source-map "^0.6.1" terser "^5.7.2" terser@^5.0.0, terser@^5.10.0, terser@^5.7.2: - version "5.13.1" - resolved "https://registry.yarnpkg.com/terser/-/terser-5.13.1.tgz#66332cdc5a01b04a224c9fad449fc1a18eaa1799" - integrity sha512-hn4WKOfwnwbYfe48NgrQjqNOH9jzLqRcIfbYytOXCOv46LBfWr9bDS17MQqOi+BWGD0sJK3Sj5NC/gJjiojaoA== + version "5.14.1" + resolved "https://registry.yarnpkg.com/terser/-/terser-5.14.1.tgz#7c95eec36436cb11cf1902cc79ac564741d19eca" + integrity sha512-+ahUAE+iheqBTDxXhTisdA8hgvbEG1hHOQ9xmNjeUJSoi6DU/gMrKNcfZjHkyY6Alnuyc+ikYJaxxfHkT3+WuQ== dependencies: + "@jridgewell/source-map" "^0.3.2" acorn "^8.5.0" commander "^2.20.0" - source-map "~0.8.0-beta.0" source-map-support "~0.5.20" test-exclude@^6.0.0: @@ -14975,15 +14898,10 @@ typedarray@^0.0.6: resolved "https://registry.yarnpkg.com/typedarray/-/typedarray-0.0.6.tgz#867ac74e3864187b1d3d47d996a78ec5c8830777" integrity sha512-/aCDEGatGvZ2BIk+HmLf4ifCJFwvKFNb9/JeZPMulfgFracn9QFcAf5GO8B/mweUjSoblS5In0cWhqpfs/5PQA== -typescript@^4.6.4: - version "4.7.2" - resolved "https://registry.yarnpkg.com/typescript/-/typescript-4.7.2.tgz#1f9aa2ceb9af87cca227813b4310fff0b51593c4" - integrity sha512-Mamb1iX2FDUpcTRzltPxgWMKy3fhg0TN378ylbktPGPK/99KbDtMQ4W1hwgsbPAsG3a0xKa1vmw4VKZQbkvz5A== - -typescript@~4.6.4: - version "4.6.4" - resolved "https://registry.yarnpkg.com/typescript/-/typescript-4.6.4.tgz#caa78bbc3a59e6a5c510d35703f6a09877ce45e9" - integrity sha512-9ia/jWHIEbo49HfjrLGfKbZSuWo9iTMwXO+Ca3pRsSpbsMbc7/IU8NKdCZVRRBafVPGnoJeFL76ZOAA84I9fEg== +typescript@^4.7.3, typescript@~4.7.3: + version "4.7.3" + resolved "https://registry.yarnpkg.com/typescript/-/typescript-4.7.3.tgz#8364b502d5257b540f9de4c40be84c98e23a129d" + integrity sha512-WOkT3XYvrpXx4vMMqlD+8R8R37fZkjyLGlxavMc4iB8lrl8L0DeTcHbYgw/v0N/z9wAFsgBhcsF0ruoySS22mA== ua-parser-js@^0.7.30: version "0.7.31" @@ -14991,9 +14909,9 @@ ua-parser-js@^0.7.30: integrity sha512-qLK/Xe9E2uzmYI3qLeOmI0tEOt+TBBQyUIAh4aAgU05FVYzeZrKUdkAZfBNVGRaHVgV0TDkdEngJSw/SyQchkQ== uglify-js@^3.1.4: - 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== + version "3.16.0" + resolved "https://registry.yarnpkg.com/uglify-js/-/uglify-js-3.16.0.tgz#b778ba0831ca102c1d8ecbdec2d2bdfcc7353190" + integrity sha512-FEikl6bR30n0T3amyBh3LoiBdqHRy/f4H80+My34HOesOKyHfOsxAPAxOoqC0JUnC1amnO0IwkYC3sko51caSw== unbox-primitive@^1.0.2: version "1.0.2" @@ -15068,17 +14986,6 @@ unified@^10.0.0: trough "^2.0.0" vfile "^5.0.0" -unified@^8.4.2: - version "8.4.2" - resolved "https://registry.yarnpkg.com/unified/-/unified-8.4.2.tgz#13ad58b4a437faa2751a4a4c6a16f680c500fff1" - integrity sha512-JCrmN13jI4+h9UAyKEoGcDZV+i1E7BLFuG7OsaDvTXI5P0qhHX+vZO/kOhz9jn8HGENDKbwSeB0nVOg4gVStGA== - dependencies: - bail "^1.0.0" - extend "^3.0.0" - is-plain-obj "^2.0.0" - trough "^1.0.0" - vfile "^4.0.0" - unified@^9.0.0, unified@^9.2.2: version "9.2.2" resolved "https://registry.yarnpkg.com/unified/-/unified-9.2.2.tgz#67649a1abfc3ab85d2969502902775eb03146975" @@ -15214,7 +15121,7 @@ unist-util-visit-parents@^5.0.0: "@types/unist" "^2.0.0" unist-util-is "^5.0.0" -unist-util-visit@2.0.3, unist-util-visit@^2.0.0, unist-util-visit@^2.0.1, unist-util-visit@^2.0.3: +unist-util-visit@2.0.3, unist-util-visit@^2.0.0, unist-util-visit@^2.0.3: version "2.0.3" resolved "https://registry.yarnpkg.com/unist-util-visit/-/unist-util-visit-2.0.3.tgz#c3703893146df47203bb8a9795af47d7b971208c" integrity sha512-iJ4/RczbJMkD0712mGktuGpm/U4By4FfDonL7N/9tATGIF4imikjOuagyMY53tnZq3NP6BcmlrHhEKAfGWjh7Q== @@ -15467,9 +15374,9 @@ vfile@^4.0.0: vfile-message "^2.0.0" vfile@^5.0.0: - version "5.3.2" - resolved "https://registry.yarnpkg.com/vfile/-/vfile-5.3.2.tgz#b499fbc50197ea50ad3749e9b60beb16ca5b7c54" - integrity sha512-w0PLIugRY3Crkgw89TeMvHCzqCs/zpreR31hl4D92y6SOE07+bfJe+dK5Q2akwS+i/c801kzjoOr9gMcTe6IAA== + version "5.3.3" + resolved "https://registry.yarnpkg.com/vfile/-/vfile-5.3.3.tgz#70b75779d99e0698a8cb6536a09361ac37f800a0" + integrity sha512-xwALvwUKmXzHOri5dGXqXNN8JDEvxPhf8avC+E+pJEl32e4/grLdRdsgx23HpK7QI0cwgR4+QfaM8D5KUnki3g== dependencies: "@types/unist" "^2.0.0" is-buffer "^2.0.0" @@ -15481,10 +15388,10 @@ vlq@^1.0.0: resolved "https://registry.yarnpkg.com/vlq/-/vlq-1.0.1.tgz#c003f6e7c0b4c1edd623fd6ee50bbc0d6a1de468" integrity sha512-gQpnTgkubC6hQgdIcRdYGDSDc+SaujOdyesZQMv6JlfQee/9Mp0Qhnys6WxDWvQnL5WZdT7o2Ul187aSt0Rq+w== -vscode-languageserver-textdocument@^1.0.4: - version "1.0.4" - resolved "https://registry.yarnpkg.com/vscode-languageserver-textdocument/-/vscode-languageserver-textdocument-1.0.4.tgz#3cd56dd14cec1d09e86c4bb04b09a246cb3df157" - integrity sha512-/xhqXP/2A2RSs+J8JNXpiiNVvvNM0oTosNVmQnunlKvq9o4mupHOBAnnzH0lwIPKazXKvAKsVp1kr+H/K4lgoQ== +vscode-languageserver-textdocument@^1.0.5: + version "1.0.5" + resolved "https://registry.yarnpkg.com/vscode-languageserver-textdocument/-/vscode-languageserver-textdocument-1.0.5.tgz#838769940ece626176ec5d5a2aa2d0aa69f5095c" + integrity sha512-1ah7zyQjKBudnMiHbZmxz5bYNM9KKZYz+5VQLj+yr8l+9w3g+WAhCkUkWbhMEdC5u0ub4Ndiye/fDyS8ghIKQg== vscode-uri@^3.0.3: version "3.0.3" @@ -15521,7 +15428,7 @@ walk-up-path@^1.0.0: resolved "https://registry.yarnpkg.com/walk-up-path/-/walk-up-path-1.0.0.tgz#d4745e893dd5fd0dbb58dd0a4c6a33d9c9fec53e" integrity sha512-hwj/qMDUEjCU5h0xr90KGCf0tg0/LgJbmOWgrWKYlcJZM7XvquvUJZ0G/HMGr7F7OQMOUuPHWP9JpriinkAlkg== -walker@^1.0.7: +walker@^1.0.8: version "1.0.8" resolved "https://registry.yarnpkg.com/walker/-/walker-1.0.8.tgz#bd498db477afe573dc04185f011d3ab8a8d7653f" integrity sha512-ts/8E8l5b7kY0vlWLewOkDXMmPdLcVV4GmOQLyxuSswIJsweeFZtAsMF7k1Nszz+TYBQrlYRmzOnr398y1JemQ== @@ -15536,9 +15443,9 @@ warning@^4.0.2: loose-envify "^1.0.0" watchpack@^2.3.1: - version "2.3.1" - resolved "https://registry.yarnpkg.com/watchpack/-/watchpack-2.3.1.tgz#4200d9447b401156eeca7767ee610f8809bc9d25" - integrity sha512-x0t0JuydIo8qCNctdDrn1OzH/qDzk2+rdCOC3YzumZ42fiMqmQ7T3xQurykYMhYfHaPHTp4ZxAx2NfUo1K6QaA== + version "2.4.0" + resolved "https://registry.yarnpkg.com/watchpack/-/watchpack-2.4.0.tgz#fa33032374962c78113f93c7f2fb4c54c9862a5d" + integrity sha512-Lcvm7MGST/4fup+ifyKi2hjyIAwcdI4HRgtvTpIUxBRhB+RFtUh8XtDOxUfctVCnhVi+QQj49i91OyvzkJl6cg== dependencies: glob-to-regexp "^0.4.1" graceful-fs "^4.1.2" @@ -15557,7 +15464,7 @@ wcwidth@^1.0.0: dependencies: defaults "^1.0.3" -web-namespaces@^1.0.0, web-namespaces@^1.1.2: +web-namespaces@^1.0.0: version "1.1.4" resolved "https://registry.yarnpkg.com/web-namespaces/-/web-namespaces-1.1.4.tgz#bc98a3de60dadd7faefc403d1076d529f5e030ec" integrity sha512-wYxSGajtmoP4WxfejAPIr4l0fVh+jeMXZb08wNc0tMg6xsfZXj3cECqIK0G7ZAqUq0PP8WlMDtaOGVBTAWztNw== @@ -15613,15 +15520,16 @@ webpack-dev-middleware@^5.3.1: range-parser "^1.2.1" schema-utils "^4.0.0" -webpack-dev-server@^4.9.0: - version "4.9.0" - resolved "https://registry.yarnpkg.com/webpack-dev-server/-/webpack-dev-server-4.9.0.tgz#737dbf44335bb8bde68f8f39127fc401c97a1557" - integrity sha512-+Nlb39iQSOSsFv0lWUuUTim3jDQO8nhK3E68f//J2r5rIcp4lULHXz2oZ0UVdEeWXEh5lSzYUlzarZhDAeAVQw== +webpack-dev-server@^4.9.2: + version "4.9.2" + resolved "https://registry.yarnpkg.com/webpack-dev-server/-/webpack-dev-server-4.9.2.tgz#c188db28c7bff12f87deda2a5595679ebbc3c9bc" + integrity sha512-H95Ns95dP24ZsEzO6G9iT+PNw4Q7ltll1GfJHV4fKphuHWgKFzGHWi4alTlTnpk1SPPk41X+l2RB7rLfIhnB9Q== dependencies: "@types/bonjour" "^3.5.9" "@types/connect-history-api-fallback" "^1.3.5" "@types/express" "^4.17.13" "@types/serve-index" "^1.9.1" + "@types/serve-static" "^1.13.10" "@types/sockjs" "^0.3.33" "@types/ws" "^8.5.1" ansi-html-community "^0.0.8" @@ -15642,7 +15550,7 @@ webpack-dev-server@^4.9.0: schema-utils "^4.0.0" selfsigned "^2.0.1" serve-index "^1.9.1" - sockjs "^0.3.21" + sockjs "^0.3.24" spdy "^4.0.2" webpack-dev-middleware "^5.3.1" ws "^8.4.2" @@ -15655,23 +15563,15 @@ webpack-merge@^5.8.0: clone-deep "^4.0.1" wildcard "^2.0.0" -webpack-sources@^1.4.3: - version "1.4.3" - resolved "https://registry.yarnpkg.com/webpack-sources/-/webpack-sources-1.4.3.tgz#eedd8ec0b928fbf1cbfe994e22d2d890f330a933" - integrity sha512-lgTS3Xhv1lCOKo7SA5TjKXMjpSM4sBjNV5+q2bqesbSPs5FjGmU6jjtBSkX9b4qW87vDIsCIlUPOEhbZrMdjeQ== - dependencies: - source-list-map "^2.0.0" - source-map "~0.6.1" - -webpack-sources@^3.2.3: +webpack-sources@^3.2.2, webpack-sources@^3.2.3: version "3.2.3" resolved "https://registry.yarnpkg.com/webpack-sources/-/webpack-sources-3.2.3.tgz#2d4daab8451fd4b240cc27055ff6a0c2ccea0cde" integrity sha512-/DyMEOrDgLKKIG0fmvtz+4dUX/3Ghozwgm6iPp8KRhvn+eQf9+Q7GWxVNMk3+uCPWfdXYC4ExGBckIXdFEfH1w== -webpack@^5, webpack@^5.72.1: - version "5.72.1" - resolved "https://registry.yarnpkg.com/webpack/-/webpack-5.72.1.tgz#3500fc834b4e9ba573b9f430b2c0a61e1bb57d13" - integrity sha512-dXG5zXCLspQR4krZVR6QgajnZOjW2K/djHvdcRaDQvsjV9z9vaW6+ja5dZOYbqBBjF6kGXka/2ZyxNdc+8Jung== +webpack@^5, webpack@^5.73.0: + version "5.73.0" + resolved "https://registry.yarnpkg.com/webpack/-/webpack-5.73.0.tgz#bbd17738f8a53ee5760ea2f59dce7f3431d35d38" + integrity sha512-svjudQRPPa0YiOYa2lM/Gacw0r6PvxptHj4FuEKQ2kX05ZLkjbVc5MnPs6its5j7IZljnIqSVo/OsY2X0IpHGA== dependencies: "@types/eslint-scope" "^3.7.3" "@types/estree" "^0.0.51" @@ -16093,9 +15993,9 @@ ws@^7.3.1: integrity sha512-ri1Id1WinAX5Jqn9HejiGb8crfRio0Qgu8+MtL36rlTA6RLsMdWt1Az/19A2Qij6uSHUMphEFaTKa4WG+UNHNw== ws@^8.2.3, ws@^8.4.2: - version "8.7.0" - resolved "https://registry.yarnpkg.com/ws/-/ws-8.7.0.tgz#eaf9d874b433aa00c0e0d8752532444875db3957" - integrity sha512-c2gsP0PRwcLFzUiA8Mkr37/MI7ilIlHQxaEAtd0uNMbVMoy8puJyafRlm0bV9MbGSabUPeLrRRaqIBcFcA2Pqg== + version "8.8.0" + resolved "https://registry.yarnpkg.com/ws/-/ws-8.8.0.tgz#8e71c75e2f6348dbf8d78005107297056cb77769" + integrity sha512-JDAgSYQ1ksuwqfChJusw1LSJ8BizJ2e/vVu5Lxjq3YvNJNlROv1ui4i+c/kUUrPheBvQl4c5UbERhTwKa6QBJQ== xdg-basedir@^4.0.0: version "4.0.0" @@ -16144,6 +16044,11 @@ yaml@^1.10.0, yaml@^1.10.2, yaml@^1.7.2: resolved "https://registry.yarnpkg.com/yaml/-/yaml-1.10.2.tgz#2301c5ffbf12b467de8da2333a459e29e7920e4b" integrity sha512-r3vXyErRCYJ7wg28yvBY5VSoAF8ZvlcW9/BwUzEtUsjvX/DKs24dIkuwjtuprwJJHsbyUbLApepYTR1BN4uHrg== +yaml@^2.1.1: + version "2.1.1" + resolved "https://registry.yarnpkg.com/yaml/-/yaml-2.1.1.tgz#1e06fb4ca46e60d9da07e4f786ea370ed3c3cfec" + integrity sha512-o96x3OPo8GjWeSLF+wOAbrPfhFOGY0W00GNaxCDv+9hkcDJEnev1yh8S7pgHF0ik6zc8sQLuL8hjHjJULZp8bw== + yargs-parser@20.2.4: version "20.2.4" resolved "https://registry.yarnpkg.com/yargs-parser/-/yargs-parser-20.2.4.tgz#b42890f14566796f85ae8e3a25290d205f154a54"