From b5e414804fbb95393f1601f44d786c24af912cdf Mon Sep 17 00:00:00 2001 From: Philipp Melab Date: Mon, 22 Jan 2024 20:02:03 +0100 Subject: [PATCH 01/15] feat(SLB-201): gatsby-plugin-static-dirs --- apps/website/gatsby-config.mjs | 10 + apps/website/gatsby-node.mjs | 28 +- apps/website/package.json | 4 +- packages/gatsby-plugin-static-dirs/README.md | 20 + .../gatsby-plugin-static-dirs/gatsby-node.js | 35 + .../gatsby-plugin-static-dirs/package.json | 20 + .../gatsby-plugin-static-dirs/tsconfig.json | 5 + pnpm-lock.yaml | 942 ++++++++++++++---- 8 files changed, 864 insertions(+), 200 deletions(-) create mode 100644 packages/gatsby-plugin-static-dirs/README.md create mode 100644 packages/gatsby-plugin-static-dirs/gatsby-node.js create mode 100644 packages/gatsby-plugin-static-dirs/package.json create mode 100644 packages/gatsby-plugin-static-dirs/tsconfig.json diff --git a/apps/website/gatsby-config.mjs b/apps/website/gatsby-config.mjs index f1a56cb66..c8e83ddde 100644 --- a/apps/website/gatsby-config.mjs +++ b/apps/website/gatsby-config.mjs @@ -42,6 +42,16 @@ export default { 'gatsby-plugin-pnpm', 'gatsby-plugin-layout', 'gatsby-plugin-sharp', + { + resolve: '@amazeelabs/gatsby-plugin-static-dirs', + options: { + directories: { + 'node_modules/@custom/ui/static/public': '/', + 'node_modules/@custom/decap/dist': '/admin', + 'node_modules/@custom/decap/media': '/media', + }, + }, + }, { resolve: '@amazeelabs/gatsby-plugin-operations', options: { diff --git a/apps/website/gatsby-node.mjs b/apps/website/gatsby-node.mjs index 4fbb0a6f1..1c0fda476 100644 --- a/apps/website/gatsby-node.mjs +++ b/apps/website/gatsby-node.mjs @@ -1,8 +1,6 @@ import { graphqlQuery } from '@amazeelabs/gatsby-plugin-operations'; import { IndexPagesQuery, ListPagesQuery, Locale } from '@custom/schema'; -import { cpSync } from 'fs'; import { resolve } from 'path'; -import serve from 'serve-static'; /** * @type {import('gatsby').GatsbyNode['onCreateWebpackConfig']} @@ -160,28 +158,4 @@ export const createPages = async ({ actions }) => { /** * @type Record */ -const staticDirectories = { - 'node_modules/@custom/ui/static/public': '/', - 'node_modules/@custom/decap/dist': '/admin', - 'node_modules/@custom/decap/media': '/media', -}; - -/** - * @type {import('gatsby').GatsbyNode['onPostBuild']} - */ -export const onPostBuild = () => { - Object.keys(staticDirectories).forEach((src) => { - const dest = staticDirectories[src]; - cpSync(src, `public${dest}`, { force: true, recursive: true }); - }); -}; - -/** - * @type {import('gatsby').GatsbyNode['onCreateDevServer']} - */ -export const onCreateDevServer = ({ app }) => { - Object.keys(staticDirectories).forEach((src) => { - const dest = staticDirectories[src]; - app.use(dest, serve(src)); - }); -}; +const staticDirectories = {}; diff --git a/apps/website/package.json b/apps/website/package.json index 17ee864a4..9f5541eff 100644 --- a/apps/website/package.json +++ b/apps/website/package.json @@ -7,6 +7,7 @@ "@amazeelabs/gatsby-plugin-operations": "^1.1.3", "@amazeelabs/gatsby-silverback-cloudinary": "^1.2.7", "@amazeelabs/gatsby-source-silverback": "^1.13.10", + "@amazeelabs/gatsby-plugin-static-dirs": "workspace:*", "@amazeelabs/publisher": "^2.4.17", "@amazeelabs/strangler-netlify": "^1.1.9", "@custom/decap": "workspace:*", @@ -25,8 +26,7 @@ "mime-types": "^2.1.35", "netlify-cli": "^17.11.0", "react": "^18.2.0", - "react-dom": "^18.2.0", - "serve-static": "^1.15.0" + "react-dom": "^18.2.0" }, "devDependencies": { "@testing-library/react": "^14.1.2", diff --git a/packages/gatsby-plugin-static-dirs/README.md b/packages/gatsby-plugin-static-dirs/README.md new file mode 100644 index 000000000..310dd0185 --- /dev/null +++ b/packages/gatsby-plugin-static-dirs/README.md @@ -0,0 +1,20 @@ +# Static directories plugin + +Gatsby plugin for adding multiple static directories. It allows to map any +directory to a subdirectory of static assets. + +Configuration: + +```js +export const plugins = [ + { + resolve: '@amazeelabs/gatsby-plugin-static-dirs', + options: { + directories: { + 'some/root/assets': '/', + 'path/to/admin/app': '/admin', + }, + }, + }, +]; +``` diff --git a/packages/gatsby-plugin-static-dirs/gatsby-node.js b/packages/gatsby-plugin-static-dirs/gatsby-node.js new file mode 100644 index 000000000..9cdb8a77b --- /dev/null +++ b/packages/gatsby-plugin-static-dirs/gatsby-node.js @@ -0,0 +1,35 @@ +import { cpSync, rmSync } from 'fs'; +import serve from 'serve-static'; + +/** + * @type {import('gatsby').GatsbyNode['pluginOptionsSchema']} + */ +export const pluginOptionsSchema = ({ Joi }) => { + return Joi.object({ + directories: Joi.object().pattern(Joi.string(), Joi.string()), + }); +}; + +/** + * @type {import('gatsby').GatsbyNode['onPostBuild']} + */ +export const onPostBuild = (_, options) => { + Object.keys(options.directories).forEach((src) => { + const dest = options.directories[src]; + cpSync(src, `public${dest}`, { + force: true, + recursive: true, + errorOnExist: false, + }); + }); +}; + +/** + * @type {import('gatsby').GatsbyNode['onCreateDevServer']} + */ +export const onCreateDevServer = ({ app }, options) => { + Object.keys(options.directories).forEach((src) => { + const dest = options.directories[src]; + app.use(dest, serve(src)); + }); +}; diff --git a/packages/gatsby-plugin-static-dirs/package.json b/packages/gatsby-plugin-static-dirs/package.json new file mode 100644 index 000000000..2fb16e940 --- /dev/null +++ b/packages/gatsby-plugin-static-dirs/package.json @@ -0,0 +1,20 @@ +{ + "name": "@amazeelabs/gatsby-plugin-static-dirs", + "version": "1.0.0", + "description": "", + "main": "gatsby-node.js", + "type": "module", + "scripts": { + "test": "tsc --noEmit" + }, + "keywords": [], + "author": "", + "license": "ISC", + "devDependencies": { + "gatsby": "^5.13.1", + "typescript": "^5.3.3" + }, + "dependencies": { + "serve-static": "^1.15.0" + } +} diff --git a/packages/gatsby-plugin-static-dirs/tsconfig.json b/packages/gatsby-plugin-static-dirs/tsconfig.json new file mode 100644 index 000000000..08ac60b6c --- /dev/null +++ b/packages/gatsby-plugin-static-dirs/tsconfig.json @@ -0,0 +1,5 @@ +{ + "compilerOptions": { + "checkJs": true + } +} diff --git a/pnpm-lock.yaml b/pnpm-lock.yaml index a24a4d090..78d874a0b 100644 --- a/pnpm-lock.yaml +++ b/pnpm-lock.yaml @@ -182,6 +182,9 @@ importers: '@amazeelabs/gatsby-plugin-operations': specifier: ^1.1.3 version: 1.1.3 + '@amazeelabs/gatsby-plugin-static-dirs': + specifier: workspace:* + version: link:../../packages/gatsby-plugin-static-dirs '@amazeelabs/gatsby-silverback-cloudinary': specifier: ^1.2.7 version: 1.2.7 @@ -245,9 +248,6 @@ importers: react-dom: specifier: ^18.2.0 version: 18.2.0(react@18.2.0) - serve-static: - specifier: ^1.15.0 - version: 1.15.0 devDependencies: '@testing-library/react': specifier: ^14.1.2 @@ -329,6 +329,19 @@ importers: packages/drupal/test_content: {} + packages/gatsby-plugin-static-dirs: + dependencies: + serve-static: + specifier: ^1.15.0 + version: 1.15.0 + devDependencies: + gatsby: + specifier: ^5.13.1 + version: 5.13.1(babel-eslint@10.1.0)(react-dom@18.2.0)(react@18.2.0)(typescript@5.3.3) + typescript: + specifier: ^5.3.3 + version: 5.3.3 + packages/schema: dependencies: '@amazeelabs/executors': @@ -7292,7 +7305,7 @@ packages: react-refresh: 0.14.0 schema-utils: 3.3.0 source-map: 0.7.4 - webpack: 5.89.0 + webpack: 5.89.0(esbuild@0.19.11) /@pnpm/config.env-replace@1.1.0: resolution: {integrity: sha512-htyl8TWnKL7K/ESFa1oW2UB5lVDxuF5DpM7tBi6Hu2LNL3mWkIzNLG6N4zoCUP1lCKNxWy/3iu8mS8MvToGd6w==} @@ -9952,6 +9965,7 @@ packages: typescript: 4.9.5 transitivePeerDependencies: - supports-color + dev: false /@typescript-eslint/eslint-plugin@5.62.0(@typescript-eslint/parser@5.62.0)(eslint@7.32.0)(typescript@5.3.3): resolution: {integrity: sha512-TiZzBSJja/LbhNPvk6yc0JrX9XqhQ0hdh6M2svYfsHGejaKFIAGd9MQ+ERIMzLGlN/kZoYIgdxFV0PuljTKXag==} @@ -9979,8 +9993,6 @@ packages: typescript: 5.3.3 transitivePeerDependencies: - supports-color - dev: false - optional: true /@typescript-eslint/eslint-plugin@6.17.0(@typescript-eslint/parser@6.17.0)(eslint@7.32.0)(typescript@5.3.3): resolution: {integrity: sha512-Vih/4xLXmY7V490dGwBQJTpIZxH4ZFH6eCVmQ4RFkB+wmaCTDAx4dtgoWwMNGKLkqRY1L6rPqzEbjorRnDo4rQ==} @@ -10029,6 +10041,7 @@ packages: typescript: 4.9.5 transitivePeerDependencies: - supports-color + dev: false /@typescript-eslint/parser@5.62.0(eslint@7.32.0)(typescript@5.3.3): resolution: {integrity: sha512-VlJEV0fOQ7BExOsHYAGrgbEiZoi8D+Bl2+f6V2RrXerRSylnp+ZBHmPvaIa8cz0Ajx7WO7Z5RqfgYg7ED1nRhA==} @@ -10048,8 +10061,6 @@ packages: typescript: 5.3.3 transitivePeerDependencies: - supports-color - dev: false - optional: true /@typescript-eslint/parser@6.17.0(eslint@7.32.0)(typescript@5.3.3): resolution: {integrity: sha512-C4bBaX2orvhK+LlwrY8oWGmSl4WolCfYm513gEccdWZj0CwGadbIADb0FtVEcI+WzUyjyoBj2JRP8g25E6IB8A==} @@ -10105,6 +10116,7 @@ packages: typescript: 4.9.5 transitivePeerDependencies: - supports-color + dev: false /@typescript-eslint/type-utils@5.62.0(eslint@7.32.0)(typescript@5.3.3): resolution: {integrity: sha512-xsSQreu+VnfbqQpW5vnCJdq1Z3Q0U31qiWmRhr98ONQmcp/yhiPJFPq8MXiJVLiksmOKSjIldZzkebzHuCGzew==} @@ -10124,8 +10136,6 @@ packages: typescript: 5.3.3 transitivePeerDependencies: - supports-color - dev: false - optional: true /@typescript-eslint/type-utils@6.17.0(eslint@7.32.0)(typescript@5.3.3): resolution: {integrity: sha512-hDXcWmnbtn4P2B37ka3nil3yi3VCQO2QEB9gBiHJmQp5wmyQWqnjA85+ZcE8c4FqnaB6lBwMrPkgd4aBYz3iNg==} @@ -10196,6 +10206,7 @@ packages: typescript: 4.9.5 transitivePeerDependencies: - supports-color + dev: false /@typescript-eslint/typescript-estree@5.62.0(typescript@5.3.3): resolution: {integrity: sha512-CmcQ6uY7b9y694lKdRB8FEel7JbU/40iSAPomu++SjLMntB+2Leay2LO6i8VnJk58MtE9/nQSFIH6jpyRWyYzA==} @@ -10257,6 +10268,7 @@ packages: transitivePeerDependencies: - supports-color - typescript + dev: false /@typescript-eslint/utils@5.62.0(eslint@7.32.0)(typescript@5.3.3): resolution: {integrity: sha512-n8oxjeb5aIbPFEtmQxQYOLI0i9n5ySBEY/ZEHHZqKQSFnxio1rv6dthascc9dLuwrL0RC5mPCxB7vnAVGAYWAQ==} @@ -12049,7 +12061,7 @@ packages: loader-utils: 2.0.4 make-dir: 3.1.0 schema-utils: 2.7.1 - webpack: 5.89.0 + webpack: 5.89.0(esbuild@0.19.11) /babel-plugin-add-module-exports@1.0.4: resolution: {integrity: sha512-g+8yxHUZ60RcyaUpfNzy56OtWW+x9cyEe9j+CranqLiqbju2yf/Cy6ZtYK40EZxtrdHllzlVZgLmcOUCTlJ7Jg==} @@ -12142,7 +12154,7 @@ packages: '@babel/core': 7.23.7 '@babel/runtime': 7.23.7 '@babel/types': 7.23.6 - gatsby: 5.13.1(babel-eslint@10.1.0)(react-dom@18.2.0)(react@18.2.0)(typescript@4.9.5) + gatsby: 5.13.1(babel-eslint@10.1.0)(esbuild@0.19.11)(react-dom@18.2.0)(react@18.2.0)(typescript@5.3.3) gatsby-core-utils: 4.13.0 /babel-plugin-syntax-trailing-function-commas@7.0.0-beta.0: @@ -13886,7 +13898,7 @@ packages: postcss-value-parser: 4.2.0 schema-utils: 3.3.0 semver: 7.5.4 - webpack: 5.89.0 + webpack: 5.89.0(esbuild@0.19.11) /css-minimizer-webpack-plugin@2.0.0(webpack@5.89.0): resolution: {integrity: sha512-cG/uc94727tx5pBNtb1Sd7gvUPzwmcQi1lkpfqTpdkuNq75hJCw7bIVsCNijLm4dhDcr1atvuysl2rZqOG8Txw==} @@ -13908,7 +13920,7 @@ packages: schema-utils: 3.3.0 serialize-javascript: 5.0.1 source-map: 0.6.1 - webpack: 5.89.0 + webpack: 5.89.0(esbuild@0.19.11) /css-select@4.3.0: resolution: {integrity: sha512-wPpOYtnsVontu2mODhA19JrqWxNsfdatRKd64kmpRbQgh1KtItko5sTnEpPdpSaJszTOhEMlF/RPz28qj4HqhQ==} @@ -16145,6 +16157,43 @@ packages: eslint-plugin-react: 7.33.2(eslint@7.32.0) eslint-plugin-react-hooks: 4.6.0(eslint@7.32.0) typescript: 4.9.5 + dev: false + + /eslint-config-react-app@6.0.0(@typescript-eslint/eslint-plugin@5.62.0)(@typescript-eslint/parser@5.62.0)(babel-eslint@10.1.0)(eslint-plugin-flowtype@5.10.0)(eslint-plugin-import@2.29.1)(eslint-plugin-jsx-a11y@6.8.0)(eslint-plugin-react-hooks@4.6.0)(eslint-plugin-react@7.33.2)(eslint@7.32.0)(typescript@5.3.3): + resolution: {integrity: sha512-bpoAAC+YRfzq0dsTk+6v9aHm/uqnDwayNAXleMypGl6CpxI9oXXscVHo4fk3eJPIn+rsbtNetB4r/ZIidFIE8A==} + engines: {node: ^10.12.0 || >=12.0.0} + peerDependencies: + '@typescript-eslint/eslint-plugin': ^4.0.0 + '@typescript-eslint/parser': ^4.0.0 + babel-eslint: ^10.0.0 + eslint: ^7.5.0 + eslint-plugin-flowtype: ^5.2.0 + eslint-plugin-import: ^2.22.0 + eslint-plugin-jest: ^24.0.0 + eslint-plugin-jsx-a11y: ^6.3.1 + eslint-plugin-react: ^7.20.3 + eslint-plugin-react-hooks: ^4.0.8 + eslint-plugin-testing-library: ^3.9.0 + typescript: '*' + peerDependenciesMeta: + eslint-plugin-jest: + optional: true + eslint-plugin-testing-library: + optional: true + typescript: + optional: true + dependencies: + '@typescript-eslint/eslint-plugin': 5.62.0(@typescript-eslint/parser@5.62.0)(eslint@7.32.0)(typescript@5.3.3) + '@typescript-eslint/parser': 5.62.0(eslint@7.32.0)(typescript@5.3.3) + babel-eslint: 10.1.0(eslint@7.32.0) + confusing-browser-globals: 1.0.11 + eslint: 7.32.0 + eslint-plugin-flowtype: 5.10.0(eslint@7.32.0) + eslint-plugin-import: 2.29.1(@typescript-eslint/parser@5.62.0)(eslint@7.32.0) + eslint-plugin-jsx-a11y: 6.8.0(eslint@7.32.0) + eslint-plugin-react: 7.33.2(eslint@7.32.0) + eslint-plugin-react-hooks: 4.6.0(eslint@7.32.0) + typescript: 5.3.3 /eslint-import-resolver-node@0.3.9: resolution: {integrity: sha512-WFj2isz22JahUv+B788TlO3N6zL3nNJGU8CcZbPZvVEkBPaJdCV4vy5wyghty5ROFbCRnm132v8BScu5/1BQ8g==} @@ -16176,7 +16225,7 @@ packages: eslint-import-resolver-webpack: optional: true dependencies: - '@typescript-eslint/parser': 5.62.0(eslint@7.32.0)(typescript@4.9.5) + '@typescript-eslint/parser': 5.62.0(eslint@7.32.0)(typescript@5.3.3) debug: 3.2.7 eslint: 7.32.0 eslint-import-resolver-node: 0.3.9 @@ -16254,7 +16303,7 @@ packages: '@typescript-eslint/parser': optional: true dependencies: - '@typescript-eslint/parser': 5.62.0(eslint@7.32.0)(typescript@4.9.5) + '@typescript-eslint/parser': 5.62.0(eslint@7.32.0)(typescript@5.3.3) array-includes: 3.1.7 array.prototype.findlastindex: 1.2.3 array.prototype.flat: 1.3.2 @@ -16459,7 +16508,7 @@ packages: micromatch: 4.0.5 normalize-path: 3.0.0 schema-utils: 3.3.0 - webpack: 5.89.0 + webpack: 5.89.0(esbuild@0.19.11) /eslint@7.32.0: resolution: {integrity: sha512-VHZ8gX+EDfz+97jGcgyGCyRia/dPOd6Xh9yPv8Bl1+SoaIwD+a/vlrOmGRUyOYu7MwUhc7CxqeaDZU13S4+EpA==} @@ -17126,7 +17175,7 @@ packages: dependencies: loader-utils: 2.0.4 schema-utils: 3.3.0 - webpack: 5.89.0 + webpack: 5.89.0(esbuild@0.19.11) /file-system-cache@2.3.0: resolution: {integrity: sha512-l4DMNdsIPsVnKrgEXbJwDJsA5mB8rGwHYERMgqQx/xAUtChPJMre1bXBzDEqqVbWv9AIbFezXMxeEkZDSrXUOQ==} @@ -17451,6 +17500,38 @@ packages: tapable: 1.1.3 typescript: 4.9.5 webpack: 5.89.0 + dev: false + + /fork-ts-checker-webpack-plugin@6.5.3(eslint@7.32.0)(typescript@5.3.3)(webpack@5.89.0): + resolution: {integrity: sha512-SbH/l9ikmMWycd5puHJKTkZJKddF4iRLyW3DeZ08HTI7NGyLS38MXd/KGgeWumQO7YNQbW2u/NtPT2YowbPaGQ==} + engines: {node: '>=10', yarn: '>=1.0.0'} + peerDependencies: + eslint: '>= 6' + typescript: '>= 2.7' + vue-template-compiler: '*' + webpack: '>= 4' + peerDependenciesMeta: + eslint: + optional: true + vue-template-compiler: + optional: true + dependencies: + '@babel/code-frame': 7.23.5 + '@types/json-schema': 7.0.15 + chalk: 4.1.2 + chokidar: 3.5.3 + cosmiconfig: 6.0.0 + deepmerge: 4.3.1 + eslint: 7.32.0 + fs-extra: 9.1.0 + glob: 7.2.3 + memfs: 3.5.3 + minimatch: 3.1.2 + schema-utils: 2.7.0 + semver: 7.5.4 + tapable: 1.1.3 + typescript: 5.3.3 + webpack: 5.89.0(esbuild@0.19.11) /form-data-encoder@2.1.4: resolution: {integrity: sha512-yDYSgNMraqvnxiEXO4hi88+YZxaHC6QKzb5N84iRCTDeRO7ZALpir/lVmf/uXUhnwUr2O4HU8s/n6x+yNjQkHw==} @@ -17717,7 +17798,7 @@ packages: dependencies: '@types/node-fetch': 2.6.10 fs-extra: 9.1.0 - gatsby: 5.13.1(babel-eslint@10.1.0)(react-dom@18.2.0)(react@18.2.0)(typescript@4.9.5) + gatsby: 5.13.1(babel-eslint@10.1.0)(esbuild@0.19.11)(react-dom@18.2.0)(react@18.2.0)(typescript@5.3.3) lodash: 4.17.21 node-fetch: 2.7.0 p-queue: 6.6.2 @@ -17833,7 +17914,7 @@ packages: chokidar: 3.5.3 fs-exists-cached: 1.0.0 fs-extra: 11.2.0 - gatsby: 5.13.1(babel-eslint@10.1.0)(react-dom@18.2.0)(react@18.2.0)(typescript@4.9.5) + gatsby: 5.13.1(babel-eslint@10.1.0)(esbuild@0.19.11)(react-dom@18.2.0)(react@18.2.0)(typescript@5.3.3) gatsby-core-utils: 4.13.0 gatsby-page-utils: 3.13.0 gatsby-plugin-utils: 4.13.0(gatsby@5.13.1)(graphql@16.8.1) @@ -17919,7 +18000,7 @@ packages: '@babel/preset-typescript': 7.23.3(@babel/core@7.23.7) '@babel/runtime': 7.23.7 babel-plugin-remove-graphql-queries: 5.13.0(@babel/core@7.23.7)(gatsby@5.13.1) - gatsby: 5.13.1(babel-eslint@10.1.0)(react-dom@18.2.0)(react@18.2.0)(typescript@4.9.5) + gatsby: 5.13.1(babel-eslint@10.1.0)(esbuild@0.19.11)(react-dom@18.2.0)(react@18.2.0)(typescript@5.3.3) transitivePeerDependencies: - supports-color @@ -17933,7 +18014,7 @@ packages: '@babel/runtime': 7.23.7 fastq: 1.16.0 fs-extra: 11.2.0 - gatsby: 5.13.1(babel-eslint@10.1.0)(react-dom@18.2.0)(react@18.2.0)(typescript@4.9.5) + gatsby: 5.13.1(babel-eslint@10.1.0)(esbuild@0.19.11)(react-dom@18.2.0)(react@18.2.0)(typescript@5.3.3) gatsby-core-utils: 4.13.0 gatsby-sharp: 1.13.0 graphql: 16.8.1 @@ -18023,7 +18104,7 @@ packages: transitivePeerDependencies: - supports-color - /gatsby@5.13.1(babel-eslint@10.1.0)(react-dom@18.2.0)(react@18.2.0)(typescript@4.9.5): + /gatsby@5.13.1(babel-eslint@10.1.0)(esbuild@0.19.11)(react-dom@18.2.0)(react@18.2.0)(typescript@5.3.3): resolution: {integrity: sha512-y8VB381ZnHX3Xxc1n78AAAd+t0EsIyyIRtfqlSQ10CXwZHpZzBR3DTRoHmqIG3/NmdiqWhbHb/nRlmKZUzixtQ==} engines: {node: '>=18.0.0'} hasBin: true @@ -18056,8 +18137,8 @@ packages: '@parcel/core': 2.8.3 '@pmmmwh/react-refresh-webpack-plugin': 0.5.11(react-refresh@0.14.0)(webpack@5.89.0) '@types/http-proxy': 1.17.14 - '@typescript-eslint/eslint-plugin': 5.62.0(@typescript-eslint/parser@5.62.0)(eslint@7.32.0)(typescript@4.9.5) - '@typescript-eslint/parser': 5.62.0(eslint@7.32.0)(typescript@4.9.5) + '@typescript-eslint/eslint-plugin': 5.62.0(@typescript-eslint/parser@5.62.0)(eslint@7.32.0)(typescript@5.3.3) + '@typescript-eslint/parser': 5.62.0(eslint@7.32.0)(typescript@5.3.3) '@vercel/webpack-asset-relocator-loader': 1.7.3 acorn-loose: 8.4.0 acorn-walk: 8.3.1 @@ -18096,7 +18177,7 @@ packages: enhanced-resolve: 5.15.0 error-stack-parser: 2.1.4 eslint: 7.32.0 - eslint-config-react-app: 6.0.0(@typescript-eslint/eslint-plugin@5.62.0)(@typescript-eslint/parser@5.62.0)(babel-eslint@10.1.0)(eslint-plugin-flowtype@5.10.0)(eslint-plugin-import@2.29.1)(eslint-plugin-jsx-a11y@6.8.0)(eslint-plugin-react-hooks@4.6.0)(eslint-plugin-react@7.33.2)(eslint@7.32.0)(typescript@4.9.5) + eslint-config-react-app: 6.0.0(@typescript-eslint/eslint-plugin@5.62.0)(@typescript-eslint/parser@5.62.0)(babel-eslint@10.1.0)(eslint-plugin-flowtype@5.10.0)(eslint-plugin-import@2.29.1)(eslint-plugin-jsx-a11y@6.8.0)(eslint-plugin-react-hooks@4.6.0)(eslint-plugin-react@7.33.2)(eslint@7.32.0)(typescript@5.3.3) eslint-plugin-flowtype: 5.10.0(eslint@7.32.0) eslint-plugin-import: 2.29.1(@typescript-eslint/parser@5.62.0)(eslint@7.32.0) eslint-plugin-jsx-a11y: 6.8.0(eslint@7.32.0) @@ -18170,7 +18251,7 @@ packages: query-string: 6.14.1 raw-loader: 4.0.2(webpack@5.89.0) react: 18.2.0 - react-dev-utils: 12.0.1(eslint@7.32.0)(typescript@4.9.5)(webpack@5.89.0) + react-dev-utils: 12.0.1(eslint@7.32.0)(typescript@5.3.3)(webpack@5.89.0) react-dom: 18.2.0(react@18.2.0) react-refresh: 0.14.0 react-server-dom-webpack: 0.0.0-experimental-c8b778b7f-20220825(react@18.2.0)(webpack@5.89.0) @@ -18188,13 +18269,13 @@ packages: strip-ansi: 6.0.1 style-loader: 2.0.0(webpack@5.89.0) style-to-object: 0.4.4 - terser-webpack-plugin: 5.3.10(webpack@5.89.0) + terser-webpack-plugin: 5.3.10(esbuild@0.19.11)(webpack@5.89.0) tmp: 0.2.1 true-case-path: 2.2.1 type-of: 2.0.1 url-loader: 4.1.1(file-loader@6.2.0)(webpack@5.89.0) uuid: 8.3.2 - webpack: 5.89.0 + webpack: 5.89.0(esbuild@0.19.11) webpack-dev-middleware: 4.3.0(webpack@5.89.0) webpack-merge: 5.10.0 webpack-stats-plugin: 1.1.3 @@ -18228,143 +18309,555 @@ packages: - webpack-hot-middleware - webpack-plugin-serve - /gauge@3.0.2: - resolution: {integrity: sha512-+5J6MS/5XksCuXq++uFRsnUd7Ovu1XenbeuIuNRJxYWjgQbPuFhT14lAvsWfqfAmnwluf1OwMjz39HjfLPci0Q==} - engines: {node: '>=10'} - dependencies: - aproba: 2.0.0 - color-support: 1.1.3 - console-control-strings: 1.1.0 - has-unicode: 2.0.1 - object-assign: 4.1.1 - signal-exit: 3.0.7 - string-width: 4.2.3 - strip-ansi: 6.0.1 - wide-align: 1.1.5 - dev: false - - /gauge@4.0.4: - resolution: {integrity: sha512-f9m+BEN5jkg6a0fZjleidjN51VE1X+mPFQ2DJ0uv1V39oCLCbsGe6yjbBnp7eK7z/+GAon99a3nHuqbuuthyPg==} - engines: {node: ^12.13.0 || ^14.15.0 || >=16.0.0} - requiresBuild: true - dependencies: - aproba: 2.0.0 - color-support: 1.1.3 - console-control-strings: 1.1.0 - has-unicode: 2.0.1 - signal-exit: 3.0.7 - string-width: 4.2.3 - strip-ansi: 6.0.1 - wide-align: 1.1.5 - dev: false - optional: true - - /generate-robotstxt@8.0.3: - resolution: {integrity: sha512-iD//oAVKcHOCz9M0IiT3pyUiF2uN1qvL3qaTA8RGLz7NU7l0XVwyzd3rN+tzhB657DNUgrygXt9w8+0zkTMFrg==} - engines: {node: '>= 10.13.0'} + /gatsby@5.13.1(babel-eslint@10.1.0)(react-dom@18.2.0)(react@18.2.0)(typescript@4.9.5): + resolution: {integrity: sha512-y8VB381ZnHX3Xxc1n78AAAd+t0EsIyyIRtfqlSQ10CXwZHpZzBR3DTRoHmqIG3/NmdiqWhbHb/nRlmKZUzixtQ==} + engines: {node: '>=18.0.0'} hasBin: true - dependencies: - cosmiconfig: 6.0.0 - fs-extra: 9.1.0 - ip-regex: 4.3.0 - is-absolute-url: 3.0.3 - meow: 7.1.1 - resolve-from: 5.0.0 - dev: false - - /gensync@1.0.0-beta.2: - resolution: {integrity: sha512-3hN7NaskYvMDLQY55gnW3NQ+mesEAepTqlg+VEbj7zzqEMBVNhzcGYYeqFo/TlYz6eQiFcp1HcsCZO+nGgS8zg==} - engines: {node: '>=6.9.0'} - - /geotiff@2.0.4: - resolution: {integrity: sha512-aG8h9bJccGusioPsEWsEqx8qdXpZN71A20WCvRKGxcnHSOWLKmC5ZmsAmodfxb9TRQvs+89KikGuPzxchhA+Uw==} - engines: {browsers: defaults, node: '>=10.19'} - dependencies: - '@petamoriken/float16': 3.8.4 - lerc: 3.0.0 - lru-cache: 6.0.0 - pako: 2.1.0 - parse-headers: 2.0.5 - web-worker: 1.2.0 - xml-utils: 1.7.0 - dev: false - - /get-amd-module-type@5.0.1: - resolution: {integrity: sha512-jb65zDeHyDjFR1loOVk0HQGM5WNwoGB8aLWy3LKCieMKol0/ProHkhO2X1JxojuN10vbz1qNn09MJ7tNp7qMzw==} - engines: {node: '>=14'} - dependencies: - ast-module-types: 5.0.0 - node-source-walk: 6.0.2 - dev: false - - /get-caller-file@2.0.5: - resolution: {integrity: sha512-DyFP3BM/3YHTQOCUL/w0OZHR0lpKeGrxotcHWcqNEdnltqFwXVfhEBQ94eIo34AfQpo0rGki4cyIiftY06h2Fg==} - engines: {node: 6.* || 8.* || >= 10.*} - - /get-func-name@2.0.2: - resolution: {integrity: sha512-8vXOvuE167CtIc3OyItco7N/dpRtBbYOsPsXCz7X/PMnlGjYjSGuZJgM1Y7mmew7BKf9BqvLX2tnOVy1BBUsxQ==} - - /get-intrinsic@1.2.2: - resolution: {integrity: sha512-0gSo4ml/0j98Y3lngkFEot/zhiCeWsbYIlZ+uZOVgzLyLaUw7wxUL+nCTP0XJvJg1AXulJRI3UJi8GsbDuxdGA==} requiresBuild: true + peerDependencies: + react: ^18.0.0 || ^0.0.0 + react-dom: ^18.0.0 || ^0.0.0 dependencies: - function-bind: 1.1.2 - has-proto: 1.0.1 - has-symbols: 1.0.3 - hasown: 2.0.0 - - /get-nonce@1.0.1: - resolution: {integrity: sha512-FJhYRoDaiatfEkUK8HKlicmu/3SGFD51q3itKDGoSTysQJBnfOcxU5GxnhE1E6soB76MbT0MBtnKJuXyAx+96Q==} - engines: {node: '>=6'} - dev: true - - /get-npm-tarball-url@2.1.0: - resolution: {integrity: sha512-ro+DiMu5DXgRBabqXupW38h7WPZ9+Ad8UjwhvsmmN8w1sU7ab0nzAXvVZ4kqYg57OrqomRtJvepX5/xvFKNtjA==} - engines: {node: '>=12.17'} - dev: true - - /get-package-name@2.2.0: - resolution: {integrity: sha512-LmCKVxioe63Fy6KDAQ/mmCSOSSRUE/x4zdrMD+7dU8quF3bGpzvP8mOmq4Dgce3nzU9AgkVDotucNOOg7c27BQ==} - engines: {node: '>= 12.0.0'} - dev: false - - /get-package-type@0.1.0: - resolution: {integrity: sha512-pjzuKtY64GYfWizNAJ0fr9VqttZkNiK2iS430LtIHzjBEr6bX8Am2zm4sW4Ro5wjWW5cAlRL1qAMTcXbjNAO2Q==} - engines: {node: '>=8.0.0'} - dev: true - - /get-port-please@3.1.1: - resolution: {integrity: sha512-3UBAyM3u4ZBVYDsxOQfJDxEa6XTbpBDrOjp4mf7ExFRt5BKs/QywQQiJsh2B+hxcZLSapWqCRvElUe8DnKcFHA==} - dev: false - - /get-port@3.2.0: - resolution: {integrity: sha512-x5UJKlgeUiNT8nyo/AcnwLnZuZNcSjSw0kogRB+Whd1fjjFq4B1hySFxSFWWSn4mIBzg3sRNUDFYc4g5gjPoLg==} - engines: {node: '>=4'} - - /get-port@5.1.1: - resolution: {integrity: sha512-g/Q1aTSDOxFpchXC4i8ZWvxA1lnPqx/JHqcpIw0/LX9T8x/GBbi6YnlN5nhaKIFkT8oFsscUKgDJYxfwfS6QsQ==} - engines: {node: '>=8'} - - /get-port@6.1.2: - resolution: {integrity: sha512-BrGGraKm2uPqurfGVj/z97/zv8dPleC6x9JBNRTrDNtCkkRF4rPwrQXFgL7+I+q8QSdU4ntLQX2D7KIxSy8nGw==} - engines: {node: ^12.20.0 || ^14.13.1 || >=16.0.0} - dev: false - - /get-stdin@9.0.0: - resolution: {integrity: sha512-dVKBjfWisLAicarI2Sf+JuBE/DghV4UzNAVe9yhEJuzeREd3JhOTE9cUaJTeSa77fsbQUK3pcOpJfM59+VKZaA==} - engines: {node: '>=12'} - dev: true - - /get-stream@3.0.0: - resolution: {integrity: sha512-GlhdIUuVakc8SJ6kK0zAFbiGzRFzNnY4jUuEbV9UROo4Y+0Ny4fjvcZFVTeDA4odpFyOQzaw6hXukJSq/f28sQ==} - engines: {node: '>=4'} - - /get-stream@5.2.0: - resolution: {integrity: sha512-nBF+F1rAZVCu/p7rjzgA+Yb4lfYXrpl7a6VmJrU8wF9I1CKvP/QwPNZHnOlwbTkY6dvtFIzFMSyQXbLoTQPRpA==} - engines: {node: '>=8'} - dependencies: - pump: 3.0.0 - + '@babel/code-frame': 7.23.5 + '@babel/core': 7.23.7 + '@babel/eslint-parser': 7.23.3(@babel/core@7.23.7)(eslint@7.32.0) + '@babel/helper-plugin-utils': 7.22.5 + '@babel/parser': 7.23.6 + '@babel/runtime': 7.23.7 + '@babel/traverse': 7.23.7 + '@babel/types': 7.23.6 + '@builder.io/partytown': 0.7.6 + '@gatsbyjs/reach-router': 2.0.1(react-dom@18.2.0)(react@18.2.0) + '@gatsbyjs/webpack-hot-middleware': 2.25.3 + '@graphql-codegen/add': 3.2.3(graphql@16.8.1) + '@graphql-codegen/core': 2.6.8(graphql@16.8.1) + '@graphql-codegen/plugin-helpers': 2.7.2(graphql@16.8.1) + '@graphql-codegen/typescript': 2.8.8(graphql@16.8.1) + '@graphql-codegen/typescript-operations': 2.5.13(graphql@16.8.1) + '@graphql-tools/code-file-loader': 7.3.23(@babel/core@7.23.7)(graphql@16.8.1) + '@graphql-tools/load': 7.8.14(graphql@16.8.1) + '@jridgewell/trace-mapping': 0.3.20 + '@nodelib/fs.walk': 1.2.8 + '@parcel/cache': 2.8.3(@parcel/core@2.8.3) + '@parcel/core': 2.8.3 + '@pmmmwh/react-refresh-webpack-plugin': 0.5.11(react-refresh@0.14.0)(webpack@5.89.0) + '@types/http-proxy': 1.17.14 + '@typescript-eslint/eslint-plugin': 5.62.0(@typescript-eslint/parser@5.62.0)(eslint@7.32.0)(typescript@4.9.5) + '@typescript-eslint/parser': 5.62.0(eslint@7.32.0)(typescript@4.9.5) + '@vercel/webpack-asset-relocator-loader': 1.7.3 + acorn-loose: 8.4.0 + acorn-walk: 8.3.1 + address: 1.2.2 + anser: 2.1.1 + autoprefixer: 10.4.16(postcss@8.4.32) + axios: 0.21.4(debug@4.3.4) + babel-jsx-utils: 1.1.0 + babel-loader: 8.3.0(@babel/core@7.23.7)(webpack@5.89.0) + babel-plugin-add-module-exports: 1.0.4 + babel-plugin-dynamic-import-node: 2.3.3 + babel-plugin-lodash: 3.3.4 + babel-plugin-remove-graphql-queries: 5.13.0(@babel/core@7.23.7)(gatsby@5.13.1) + babel-preset-gatsby: 3.13.0(@babel/core@7.23.7)(core-js@3.35.0) + better-opn: 2.1.1 + bluebird: 3.7.2 + body-parser: 1.20.1 + browserslist: 4.22.2 + cache-manager: 2.11.1 + chalk: 4.1.2 + chokidar: 3.5.3 + common-tags: 1.8.2 + compression: 1.7.4 + cookie: 0.5.0 + core-js: 3.35.0 + cors: 2.8.5 + css-loader: 5.2.7(webpack@5.89.0) + css-minimizer-webpack-plugin: 2.0.0(webpack@5.89.0) + css.escape: 1.5.1 + date-fns: 2.30.0 + debug: 4.3.4 + deepmerge: 4.3.1 + detect-port: 1.5.1 + devcert: 1.2.2 + dotenv: 8.6.0 + enhanced-resolve: 5.15.0 + error-stack-parser: 2.1.4 + eslint: 7.32.0 + eslint-config-react-app: 6.0.0(@typescript-eslint/eslint-plugin@5.62.0)(@typescript-eslint/parser@5.62.0)(babel-eslint@10.1.0)(eslint-plugin-flowtype@5.10.0)(eslint-plugin-import@2.29.1)(eslint-plugin-jsx-a11y@6.8.0)(eslint-plugin-react-hooks@4.6.0)(eslint-plugin-react@7.33.2)(eslint@7.32.0)(typescript@4.9.5) + eslint-plugin-flowtype: 5.10.0(eslint@7.32.0) + eslint-plugin-import: 2.29.1(@typescript-eslint/parser@5.62.0)(eslint@7.32.0) + eslint-plugin-jsx-a11y: 6.8.0(eslint@7.32.0) + eslint-plugin-react: 7.33.2(eslint@7.32.0) + eslint-plugin-react-hooks: 4.6.0(eslint@7.32.0) + eslint-webpack-plugin: 2.7.0(eslint@7.32.0)(webpack@5.89.0) + event-source-polyfill: 1.0.31 + execa: 5.1.1 + express: 4.18.2 + express-http-proxy: 1.6.3 + fastest-levenshtein: 1.0.16 + fastq: 1.16.0 + file-loader: 6.2.0(webpack@5.89.0) + find-cache-dir: 3.3.2 + fs-exists-cached: 1.0.0 + fs-extra: 11.2.0 + gatsby-cli: 5.13.1 + gatsby-core-utils: 4.13.0 + gatsby-graphiql-explorer: 3.13.0 + gatsby-legacy-polyfills: 3.13.0 + gatsby-link: 5.13.0(@gatsbyjs/reach-router@2.0.1)(react-dom@18.2.0)(react@18.2.0) + gatsby-page-utils: 3.13.0 + gatsby-parcel-config: 1.13.0(@parcel/core@2.8.3) + gatsby-plugin-page-creator: 5.13.0(gatsby@5.13.1)(graphql@16.8.1) + gatsby-plugin-typescript: 5.13.0(gatsby@5.13.1) + gatsby-plugin-utils: 4.13.0(gatsby@5.13.1)(graphql@16.8.1) + gatsby-react-router-scroll: 6.13.0(@gatsbyjs/reach-router@2.0.1)(react-dom@18.2.0)(react@18.2.0) + gatsby-script: 2.13.0(@gatsbyjs/reach-router@2.0.1)(react-dom@18.2.0)(react@18.2.0) + gatsby-telemetry: 4.13.0 + gatsby-worker: 2.13.0 + glob: 7.2.3 + globby: 11.1.0 + got: 11.8.6 + graphql: 16.8.1 + graphql-compose: 9.0.10(graphql@16.8.1) + graphql-http: 1.22.0(graphql@16.8.1) + graphql-tag: 2.12.6(graphql@16.8.1) + hasha: 5.2.2 + invariant: 2.2.4 + is-relative: 1.0.0 + is-relative-url: 3.0.0 + joi: 17.11.0 + json-loader: 0.5.7 + latest-version: 7.0.0 + linkfs: 2.1.0 + lmdb: 2.5.3 + lodash: 4.17.21 + meant: 1.0.3 + memoizee: 0.4.15 + micromatch: 4.0.5 + mime: 3.0.0 + mini-css-extract-plugin: 1.6.2(webpack@5.89.0) + mitt: 1.2.0 + moment: 2.30.1 + multer: 1.4.5-lts.1 + node-fetch: 2.7.0 + node-html-parser: 5.4.2 + normalize-path: 3.0.0 + null-loader: 4.0.1(webpack@5.89.0) + opentracing: 0.14.7 + p-defer: 3.0.0 + parseurl: 1.3.3 + path-to-regexp: 0.1.7 + physical-cpu-count: 2.0.0 + platform: 1.3.6 + postcss: 8.4.32 + postcss-flexbugs-fixes: 5.0.2(postcss@8.4.32) + postcss-loader: 5.3.0(postcss@8.4.32)(webpack@5.89.0) + prompts: 2.4.2 + prop-types: 15.8.1 + query-string: 6.14.1 + raw-loader: 4.0.2(webpack@5.89.0) + react: 18.2.0 + react-dev-utils: 12.0.1(eslint@7.32.0)(typescript@4.9.5)(webpack@5.89.0) + react-dom: 18.2.0(react@18.2.0) + react-refresh: 0.14.0 + react-server-dom-webpack: 0.0.0-experimental-c8b778b7f-20220825(react@18.2.0)(webpack@5.89.0) + redux: 4.2.1 + redux-thunk: 2.4.2(redux@4.2.1) + resolve-from: 5.0.0 + semver: 7.5.4 + shallow-compare: 1.2.2 + signal-exit: 3.0.7 + slugify: 1.6.6 + socket.io: 4.7.1 + socket.io-client: 4.7.1 + stack-trace: 0.0.10 + string-similarity: 1.2.2 + strip-ansi: 6.0.1 + style-loader: 2.0.0(webpack@5.89.0) + style-to-object: 0.4.4 + terser-webpack-plugin: 5.3.10(webpack@5.89.0) + tmp: 0.2.1 + true-case-path: 2.2.1 + type-of: 2.0.1 + url-loader: 4.1.1(file-loader@6.2.0)(webpack@5.89.0) + uuid: 8.3.2 + webpack: 5.89.0 + webpack-dev-middleware: 4.3.0(webpack@5.89.0) + webpack-merge: 5.10.0 + webpack-stats-plugin: 1.1.3 + webpack-virtual-modules: 0.5.0 + xstate: 4.38.3 + yaml-loader: 0.8.0 + optionalDependencies: + gatsby-sharp: 1.13.0 + transitivePeerDependencies: + - '@swc/core' + - '@types/webpack' + - babel-eslint + - bufferutil + - clean-css + - csso + - encoding + - esbuild + - eslint-import-resolver-typescript + - eslint-import-resolver-webpack + - eslint-plugin-jest + - eslint-plugin-testing-library + - sockjs-client + - supports-color + - type-fest + - typescript + - uglify-js + - utf-8-validate + - vue-template-compiler + - webpack-cli + - webpack-dev-server + - webpack-hot-middleware + - webpack-plugin-serve + dev: false + + /gatsby@5.13.1(babel-eslint@10.1.0)(react-dom@18.2.0)(react@18.2.0)(typescript@5.3.3): + resolution: {integrity: sha512-y8VB381ZnHX3Xxc1n78AAAd+t0EsIyyIRtfqlSQ10CXwZHpZzBR3DTRoHmqIG3/NmdiqWhbHb/nRlmKZUzixtQ==} + engines: {node: '>=18.0.0'} + hasBin: true + requiresBuild: true + peerDependencies: + react: ^18.0.0 || ^0.0.0 + react-dom: ^18.0.0 || ^0.0.0 + dependencies: + '@babel/code-frame': 7.23.5 + '@babel/core': 7.23.7 + '@babel/eslint-parser': 7.23.3(@babel/core@7.23.7)(eslint@7.32.0) + '@babel/helper-plugin-utils': 7.22.5 + '@babel/parser': 7.23.6 + '@babel/runtime': 7.23.7 + '@babel/traverse': 7.23.7 + '@babel/types': 7.23.6 + '@builder.io/partytown': 0.7.6 + '@gatsbyjs/reach-router': 2.0.1(react-dom@18.2.0)(react@18.2.0) + '@gatsbyjs/webpack-hot-middleware': 2.25.3 + '@graphql-codegen/add': 3.2.3(graphql@16.8.1) + '@graphql-codegen/core': 2.6.8(graphql@16.8.1) + '@graphql-codegen/plugin-helpers': 2.7.2(graphql@16.8.1) + '@graphql-codegen/typescript': 2.8.8(graphql@16.8.1) + '@graphql-codegen/typescript-operations': 2.5.13(graphql@16.8.1) + '@graphql-tools/code-file-loader': 7.3.23(@babel/core@7.23.7)(graphql@16.8.1) + '@graphql-tools/load': 7.8.14(graphql@16.8.1) + '@jridgewell/trace-mapping': 0.3.20 + '@nodelib/fs.walk': 1.2.8 + '@parcel/cache': 2.8.3(@parcel/core@2.8.3) + '@parcel/core': 2.8.3 + '@pmmmwh/react-refresh-webpack-plugin': 0.5.11(react-refresh@0.14.0)(webpack@5.89.0) + '@types/http-proxy': 1.17.14 + '@typescript-eslint/eslint-plugin': 5.62.0(@typescript-eslint/parser@5.62.0)(eslint@7.32.0)(typescript@5.3.3) + '@typescript-eslint/parser': 5.62.0(eslint@7.32.0)(typescript@5.3.3) + '@vercel/webpack-asset-relocator-loader': 1.7.3 + acorn-loose: 8.4.0 + acorn-walk: 8.3.1 + address: 1.2.2 + anser: 2.1.1 + autoprefixer: 10.4.16(postcss@8.4.32) + axios: 0.21.4(debug@4.3.4) + babel-jsx-utils: 1.1.0 + babel-loader: 8.3.0(@babel/core@7.23.7)(webpack@5.89.0) + babel-plugin-add-module-exports: 1.0.4 + babel-plugin-dynamic-import-node: 2.3.3 + babel-plugin-lodash: 3.3.4 + babel-plugin-remove-graphql-queries: 5.13.0(@babel/core@7.23.7)(gatsby@5.13.1) + babel-preset-gatsby: 3.13.0(@babel/core@7.23.7)(core-js@3.35.0) + better-opn: 2.1.1 + bluebird: 3.7.2 + body-parser: 1.20.1 + browserslist: 4.22.2 + cache-manager: 2.11.1 + chalk: 4.1.2 + chokidar: 3.5.3 + common-tags: 1.8.2 + compression: 1.7.4 + cookie: 0.5.0 + core-js: 3.35.0 + cors: 2.8.5 + css-loader: 5.2.7(webpack@5.89.0) + css-minimizer-webpack-plugin: 2.0.0(webpack@5.89.0) + css.escape: 1.5.1 + date-fns: 2.30.0 + debug: 4.3.4 + deepmerge: 4.3.1 + detect-port: 1.5.1 + devcert: 1.2.2 + dotenv: 8.6.0 + enhanced-resolve: 5.15.0 + error-stack-parser: 2.1.4 + eslint: 7.32.0 + eslint-config-react-app: 6.0.0(@typescript-eslint/eslint-plugin@5.62.0)(@typescript-eslint/parser@5.62.0)(babel-eslint@10.1.0)(eslint-plugin-flowtype@5.10.0)(eslint-plugin-import@2.29.1)(eslint-plugin-jsx-a11y@6.8.0)(eslint-plugin-react-hooks@4.6.0)(eslint-plugin-react@7.33.2)(eslint@7.32.0)(typescript@5.3.3) + eslint-plugin-flowtype: 5.10.0(eslint@7.32.0) + eslint-plugin-import: 2.29.1(@typescript-eslint/parser@5.62.0)(eslint@7.32.0) + eslint-plugin-jsx-a11y: 6.8.0(eslint@7.32.0) + eslint-plugin-react: 7.33.2(eslint@7.32.0) + eslint-plugin-react-hooks: 4.6.0(eslint@7.32.0) + eslint-webpack-plugin: 2.7.0(eslint@7.32.0)(webpack@5.89.0) + event-source-polyfill: 1.0.31 + execa: 5.1.1 + express: 4.18.2 + express-http-proxy: 1.6.3 + fastest-levenshtein: 1.0.16 + fastq: 1.16.0 + file-loader: 6.2.0(webpack@5.89.0) + find-cache-dir: 3.3.2 + fs-exists-cached: 1.0.0 + fs-extra: 11.2.0 + gatsby-cli: 5.13.1 + gatsby-core-utils: 4.13.0 + gatsby-graphiql-explorer: 3.13.0 + gatsby-legacy-polyfills: 3.13.0 + gatsby-link: 5.13.0(@gatsbyjs/reach-router@2.0.1)(react-dom@18.2.0)(react@18.2.0) + gatsby-page-utils: 3.13.0 + gatsby-parcel-config: 1.13.0(@parcel/core@2.8.3) + gatsby-plugin-page-creator: 5.13.0(gatsby@5.13.1)(graphql@16.8.1) + gatsby-plugin-typescript: 5.13.0(gatsby@5.13.1) + gatsby-plugin-utils: 4.13.0(gatsby@5.13.1)(graphql@16.8.1) + gatsby-react-router-scroll: 6.13.0(@gatsbyjs/reach-router@2.0.1)(react-dom@18.2.0)(react@18.2.0) + gatsby-script: 2.13.0(@gatsbyjs/reach-router@2.0.1)(react-dom@18.2.0)(react@18.2.0) + gatsby-telemetry: 4.13.0 + gatsby-worker: 2.13.0 + glob: 7.2.3 + globby: 11.1.0 + got: 11.8.6 + graphql: 16.8.1 + graphql-compose: 9.0.10(graphql@16.8.1) + graphql-http: 1.22.0(graphql@16.8.1) + graphql-tag: 2.12.6(graphql@16.8.1) + hasha: 5.2.2 + invariant: 2.2.4 + is-relative: 1.0.0 + is-relative-url: 3.0.0 + joi: 17.11.0 + json-loader: 0.5.7 + latest-version: 7.0.0 + linkfs: 2.1.0 + lmdb: 2.5.3 + lodash: 4.17.21 + meant: 1.0.3 + memoizee: 0.4.15 + micromatch: 4.0.5 + mime: 3.0.0 + mini-css-extract-plugin: 1.6.2(webpack@5.89.0) + mitt: 1.2.0 + moment: 2.30.1 + multer: 1.4.5-lts.1 + node-fetch: 2.7.0 + node-html-parser: 5.4.2 + normalize-path: 3.0.0 + null-loader: 4.0.1(webpack@5.89.0) + opentracing: 0.14.7 + p-defer: 3.0.0 + parseurl: 1.3.3 + path-to-regexp: 0.1.7 + physical-cpu-count: 2.0.0 + platform: 1.3.6 + postcss: 8.4.32 + postcss-flexbugs-fixes: 5.0.2(postcss@8.4.32) + postcss-loader: 5.3.0(postcss@8.4.32)(webpack@5.89.0) + prompts: 2.4.2 + prop-types: 15.8.1 + query-string: 6.14.1 + raw-loader: 4.0.2(webpack@5.89.0) + react: 18.2.0 + react-dev-utils: 12.0.1(eslint@7.32.0)(typescript@5.3.3)(webpack@5.89.0) + react-dom: 18.2.0(react@18.2.0) + react-refresh: 0.14.0 + react-server-dom-webpack: 0.0.0-experimental-c8b778b7f-20220825(react@18.2.0)(webpack@5.89.0) + redux: 4.2.1 + redux-thunk: 2.4.2(redux@4.2.1) + resolve-from: 5.0.0 + semver: 7.5.4 + shallow-compare: 1.2.2 + signal-exit: 3.0.7 + slugify: 1.6.6 + socket.io: 4.7.1 + socket.io-client: 4.7.1 + stack-trace: 0.0.10 + string-similarity: 1.2.2 + strip-ansi: 6.0.1 + style-loader: 2.0.0(webpack@5.89.0) + style-to-object: 0.4.4 + terser-webpack-plugin: 5.3.10(webpack@5.89.0) + tmp: 0.2.1 + true-case-path: 2.2.1 + type-of: 2.0.1 + url-loader: 4.1.1(file-loader@6.2.0)(webpack@5.89.0) + uuid: 8.3.2 + webpack: 5.89.0 + webpack-dev-middleware: 4.3.0(webpack@5.89.0) + webpack-merge: 5.10.0 + webpack-stats-plugin: 1.1.3 + webpack-virtual-modules: 0.5.0 + xstate: 4.38.3 + yaml-loader: 0.8.0 + optionalDependencies: + gatsby-sharp: 1.13.0 + transitivePeerDependencies: + - '@swc/core' + - '@types/webpack' + - babel-eslint + - bufferutil + - clean-css + - csso + - encoding + - esbuild + - eslint-import-resolver-typescript + - eslint-import-resolver-webpack + - eslint-plugin-jest + - eslint-plugin-testing-library + - sockjs-client + - supports-color + - type-fest + - typescript + - uglify-js + - utf-8-validate + - vue-template-compiler + - webpack-cli + - webpack-dev-server + - webpack-hot-middleware + - webpack-plugin-serve + dev: true + + /gauge@3.0.2: + resolution: {integrity: sha512-+5J6MS/5XksCuXq++uFRsnUd7Ovu1XenbeuIuNRJxYWjgQbPuFhT14lAvsWfqfAmnwluf1OwMjz39HjfLPci0Q==} + engines: {node: '>=10'} + dependencies: + aproba: 2.0.0 + color-support: 1.1.3 + console-control-strings: 1.1.0 + has-unicode: 2.0.1 + object-assign: 4.1.1 + signal-exit: 3.0.7 + string-width: 4.2.3 + strip-ansi: 6.0.1 + wide-align: 1.1.5 + dev: false + + /gauge@4.0.4: + resolution: {integrity: sha512-f9m+BEN5jkg6a0fZjleidjN51VE1X+mPFQ2DJ0uv1V39oCLCbsGe6yjbBnp7eK7z/+GAon99a3nHuqbuuthyPg==} + engines: {node: ^12.13.0 || ^14.15.0 || >=16.0.0} + requiresBuild: true + dependencies: + aproba: 2.0.0 + color-support: 1.1.3 + console-control-strings: 1.1.0 + has-unicode: 2.0.1 + signal-exit: 3.0.7 + string-width: 4.2.3 + strip-ansi: 6.0.1 + wide-align: 1.1.5 + dev: false + optional: true + + /generate-robotstxt@8.0.3: + resolution: {integrity: sha512-iD//oAVKcHOCz9M0IiT3pyUiF2uN1qvL3qaTA8RGLz7NU7l0XVwyzd3rN+tzhB657DNUgrygXt9w8+0zkTMFrg==} + engines: {node: '>= 10.13.0'} + hasBin: true + dependencies: + cosmiconfig: 6.0.0 + fs-extra: 9.1.0 + ip-regex: 4.3.0 + is-absolute-url: 3.0.3 + meow: 7.1.1 + resolve-from: 5.0.0 + dev: false + + /gensync@1.0.0-beta.2: + resolution: {integrity: sha512-3hN7NaskYvMDLQY55gnW3NQ+mesEAepTqlg+VEbj7zzqEMBVNhzcGYYeqFo/TlYz6eQiFcp1HcsCZO+nGgS8zg==} + engines: {node: '>=6.9.0'} + + /geotiff@2.0.4: + resolution: {integrity: sha512-aG8h9bJccGusioPsEWsEqx8qdXpZN71A20WCvRKGxcnHSOWLKmC5ZmsAmodfxb9TRQvs+89KikGuPzxchhA+Uw==} + engines: {browsers: defaults, node: '>=10.19'} + dependencies: + '@petamoriken/float16': 3.8.4 + lerc: 3.0.0 + lru-cache: 6.0.0 + pako: 2.1.0 + parse-headers: 2.0.5 + web-worker: 1.2.0 + xml-utils: 1.7.0 + dev: false + + /get-amd-module-type@5.0.1: + resolution: {integrity: sha512-jb65zDeHyDjFR1loOVk0HQGM5WNwoGB8aLWy3LKCieMKol0/ProHkhO2X1JxojuN10vbz1qNn09MJ7tNp7qMzw==} + engines: {node: '>=14'} + dependencies: + ast-module-types: 5.0.0 + node-source-walk: 6.0.2 + dev: false + + /get-caller-file@2.0.5: + resolution: {integrity: sha512-DyFP3BM/3YHTQOCUL/w0OZHR0lpKeGrxotcHWcqNEdnltqFwXVfhEBQ94eIo34AfQpo0rGki4cyIiftY06h2Fg==} + engines: {node: 6.* || 8.* || >= 10.*} + + /get-func-name@2.0.2: + resolution: {integrity: sha512-8vXOvuE167CtIc3OyItco7N/dpRtBbYOsPsXCz7X/PMnlGjYjSGuZJgM1Y7mmew7BKf9BqvLX2tnOVy1BBUsxQ==} + + /get-intrinsic@1.2.2: + resolution: {integrity: sha512-0gSo4ml/0j98Y3lngkFEot/zhiCeWsbYIlZ+uZOVgzLyLaUw7wxUL+nCTP0XJvJg1AXulJRI3UJi8GsbDuxdGA==} + requiresBuild: true + dependencies: + function-bind: 1.1.2 + has-proto: 1.0.1 + has-symbols: 1.0.3 + hasown: 2.0.0 + + /get-nonce@1.0.1: + resolution: {integrity: sha512-FJhYRoDaiatfEkUK8HKlicmu/3SGFD51q3itKDGoSTysQJBnfOcxU5GxnhE1E6soB76MbT0MBtnKJuXyAx+96Q==} + engines: {node: '>=6'} + dev: true + + /get-npm-tarball-url@2.1.0: + resolution: {integrity: sha512-ro+DiMu5DXgRBabqXupW38h7WPZ9+Ad8UjwhvsmmN8w1sU7ab0nzAXvVZ4kqYg57OrqomRtJvepX5/xvFKNtjA==} + engines: {node: '>=12.17'} + dev: true + + /get-package-name@2.2.0: + resolution: {integrity: sha512-LmCKVxioe63Fy6KDAQ/mmCSOSSRUE/x4zdrMD+7dU8quF3bGpzvP8mOmq4Dgce3nzU9AgkVDotucNOOg7c27BQ==} + engines: {node: '>= 12.0.0'} + dev: false + + /get-package-type@0.1.0: + resolution: {integrity: sha512-pjzuKtY64GYfWizNAJ0fr9VqttZkNiK2iS430LtIHzjBEr6bX8Am2zm4sW4Ro5wjWW5cAlRL1qAMTcXbjNAO2Q==} + engines: {node: '>=8.0.0'} + dev: true + + /get-port-please@3.1.1: + resolution: {integrity: sha512-3UBAyM3u4ZBVYDsxOQfJDxEa6XTbpBDrOjp4mf7ExFRt5BKs/QywQQiJsh2B+hxcZLSapWqCRvElUe8DnKcFHA==} + dev: false + + /get-port@3.2.0: + resolution: {integrity: sha512-x5UJKlgeUiNT8nyo/AcnwLnZuZNcSjSw0kogRB+Whd1fjjFq4B1hySFxSFWWSn4mIBzg3sRNUDFYc4g5gjPoLg==} + engines: {node: '>=4'} + + /get-port@5.1.1: + resolution: {integrity: sha512-g/Q1aTSDOxFpchXC4i8ZWvxA1lnPqx/JHqcpIw0/LX9T8x/GBbi6YnlN5nhaKIFkT8oFsscUKgDJYxfwfS6QsQ==} + engines: {node: '>=8'} + + /get-port@6.1.2: + resolution: {integrity: sha512-BrGGraKm2uPqurfGVj/z97/zv8dPleC6x9JBNRTrDNtCkkRF4rPwrQXFgL7+I+q8QSdU4ntLQX2D7KIxSy8nGw==} + engines: {node: ^12.20.0 || ^14.13.1 || >=16.0.0} + dev: false + + /get-stdin@9.0.0: + resolution: {integrity: sha512-dVKBjfWisLAicarI2Sf+JuBE/DghV4UzNAVe9yhEJuzeREd3JhOTE9cUaJTeSa77fsbQUK3pcOpJfM59+VKZaA==} + engines: {node: '>=12'} + dev: true + + /get-stream@3.0.0: + resolution: {integrity: sha512-GlhdIUuVakc8SJ6kK0zAFbiGzRFzNnY4jUuEbV9UROo4Y+0Ny4fjvcZFVTeDA4odpFyOQzaw6hXukJSq/f28sQ==} + engines: {node: '>=4'} + + /get-stream@5.2.0: + resolution: {integrity: sha512-nBF+F1rAZVCu/p7rjzgA+Yb4lfYXrpl7a6VmJrU8wF9I1CKvP/QwPNZHnOlwbTkY6dvtFIzFMSyQXbLoTQPRpA==} + engines: {node: '>=8'} + dependencies: + pump: 3.0.0 + /get-stream@6.0.1: resolution: {integrity: sha512-ts6Wi+2j3jQjqi70w5AlN8DFnkSwC+MqmxEzdEALB2qXZYV3X/b1CTfgPLGJNMeAWxdPfU8FO1ms3NUfaHCPYg==} engines: {node: '>=10'} @@ -22826,7 +23319,7 @@ packages: dependencies: loader-utils: 2.0.4 schema-utils: 3.3.0 - webpack: 5.89.0 + webpack: 5.89.0(esbuild@0.19.11) webpack-sources: 1.4.3 /mini-svg-data-uri@1.4.4: @@ -23659,7 +24152,7 @@ packages: dependencies: loader-utils: 2.0.4 schema-utils: 3.3.0 - webpack: 5.89.0 + webpack: 5.89.0(esbuild@0.19.11) /nullthrows@1.1.1: resolution: {integrity: sha512-2vPPEi+Z7WqML2jZYddDIfy5Dqb0r2fze2zTxNNknZaFpVHU3mFB3R+DWeJWGVx0ecvttSGlJTI+WG+8Z4cDWw==} @@ -24869,7 +25362,7 @@ packages: klona: 2.0.6 postcss: 8.4.32 semver: 7.5.4 - webpack: 5.89.0 + webpack: 5.89.0(esbuild@0.19.11) /postcss-merge-longhand@5.1.7(postcss@8.4.32): resolution: {integrity: sha512-YCI9gZB+PLNskrK0BB3/2OzPnGhPkBEwmwhfYk1ilBHYVAZB7/tkTHFBAnCrvBBOmeYyMYw3DMjT55SyxMBzjQ==} @@ -25847,7 +26340,7 @@ packages: dependencies: loader-utils: 2.0.4 schema-utils: 3.3.0 - webpack: 5.89.0 + webpack: 5.89.0(esbuild@0.19.11) /rbush@3.0.1: resolution: {integrity: sha512-XRaVO0YecOpEuIvbhbpTrZgoiI6xBlz6hnlr6EHhd+0x9ase6EmeN+hdwwUaJvLcsFFQ8iWVF1GAK1yB0BWi0w==} @@ -25984,6 +26477,48 @@ packages: - eslint - supports-color - vue-template-compiler + dev: false + + /react-dev-utils@12.0.1(eslint@7.32.0)(typescript@5.3.3)(webpack@5.89.0): + resolution: {integrity: sha512-84Ivxmr17KjUupyqzFode6xKhjwuEJDROWKJy/BthkL7Wn6NJ8h4WE6k/exAv6ImS+0oZLRRW5j/aINMHyeGeQ==} + engines: {node: '>=14'} + peerDependencies: + typescript: '>=2.7' + webpack: '>=4' + peerDependenciesMeta: + typescript: + optional: true + dependencies: + '@babel/code-frame': 7.23.5 + address: 1.2.2 + browserslist: 4.22.2 + chalk: 4.1.2 + cross-spawn: 7.0.3 + detect-port-alt: 1.1.6 + escape-string-regexp: 4.0.0 + filesize: 8.0.7 + find-up: 5.0.0 + fork-ts-checker-webpack-plugin: 6.5.3(eslint@7.32.0)(typescript@5.3.3)(webpack@5.89.0) + global-modules: 2.0.0 + globby: 11.1.0 + gzip-size: 6.0.0 + immer: 9.0.21 + is-root: 2.1.0 + loader-utils: 3.2.1 + open: 8.4.2 + pkg-up: 3.1.0 + prompts: 2.4.2 + react-error-overlay: 6.0.11 + recursive-readdir: 2.2.3 + shell-quote: 1.8.1 + strip-ansi: 6.0.1 + text-table: 0.2.0 + typescript: 5.3.3 + webpack: 5.89.0(esbuild@0.19.11) + transitivePeerDependencies: + - eslint + - supports-color + - vue-template-compiler /react-dnd-html5-backend@14.1.0: resolution: {integrity: sha512-6ONeqEC3XKVf4eVmMTe0oPds+c5B9Foyj8p/ZKLb7kL2qh9COYxiBHv3szd6gztqi/efkmriywLUVlPotqoJyw==} @@ -26385,7 +26920,7 @@ packages: loose-envify: 1.4.0 neo-async: 2.6.2 react: 18.2.0 - webpack: 5.89.0 + webpack: 5.89.0(esbuild@0.19.11) /react-split-pane@0.1.92(react-dom@18.2.0)(react@18.2.0): resolution: {integrity: sha512-GfXP1xSzLMcLJI5BM36Vh7GgZBpy+U/X0no+VM3fxayv+p1Jly5HpMofZJraeaMl73b3hvlr+N9zJKvLB/uz9w==} @@ -28740,7 +29275,7 @@ packages: dependencies: loader-utils: 2.0.4 schema-utils: 3.3.0 - webpack: 5.89.0 + webpack: 5.89.0(esbuild@0.19.11) /style-to-object@0.3.0: resolution: {integrity: sha512-CzFnRRXhzWIdItT3OmF8SQfWyahHhjq3HwcMNCNLn+N7klOOqPjMeG/4JSu77D7ypZdGvSzvkrbyeTMizz2VrA==} @@ -29051,6 +29586,30 @@ packages: ps-tree: 1.2.0 dev: false + /terser-webpack-plugin@5.3.10(esbuild@0.19.11)(webpack@5.89.0): + resolution: {integrity: sha512-BKFPWlPDndPs+NGGCr1U59t0XScL5317Y0UReNrHaw9/FwhPENlq6bfgs+4yPfyP51vqC1bQ4rp1EfXW5ZSH9w==} + engines: {node: '>= 10.13.0'} + peerDependencies: + '@swc/core': '*' + esbuild: '*' + uglify-js: '*' + webpack: ^5.1.0 + peerDependenciesMeta: + '@swc/core': + optional: true + esbuild: + optional: true + uglify-js: + optional: true + dependencies: + '@jridgewell/trace-mapping': 0.3.20 + esbuild: 0.19.11 + jest-worker: 27.5.1 + schema-utils: 3.3.0 + serialize-javascript: 6.0.1 + terser: 5.26.0 + webpack: 5.89.0(esbuild@0.19.11) + /terser-webpack-plugin@5.3.10(webpack@5.89.0): resolution: {integrity: sha512-BKFPWlPDndPs+NGGCr1U59t0XScL5317Y0UReNrHaw9/FwhPENlq6bfgs+4yPfyP51vqC1bQ4rp1EfXW5ZSH9w==} engines: {node: '>= 10.13.0'} @@ -29541,6 +30100,7 @@ packages: dependencies: tslib: 1.14.1 typescript: 4.9.5 + dev: false /tsutils@3.21.0(typescript@5.3.3): resolution: {integrity: sha512-mHKK3iUXL+3UF6xL5k0PEhKRUBKPBCv/+RkEOpjRWxxx27KKRBmmA60A9pgOUvMi8GKhRMPEmjBRPzs2W7O1OA==} @@ -29739,6 +30299,7 @@ packages: resolution: {integrity: sha512-1FXk9E2Hm+QzZQ7z+McJiHL4NW1F2EzMu9Nq9i3zAaGqibafqYwCVU6WyWAuyQRRzOlxou8xZSyXLEN8oKj24g==} engines: {node: '>=4.2.0'} hasBin: true + dev: false /typescript@5.3.3: resolution: {integrity: sha512-pXWcraxM0uxAS+tN0AG/BF2TyqmHO014Z070UsJ+pFvYuRSq8KH8DmWpnbXe0pEPDHXZV3FcAbJkijJ5oNEnWw==} @@ -30238,7 +30799,7 @@ packages: loader-utils: 2.0.4 mime-types: 2.1.35 schema-utils: 3.3.0 - webpack: 5.89.0 + webpack: 5.89.0(esbuild@0.19.11) /url@0.11.3: resolution: {integrity: sha512-6hxOLGfZASQK/cijlZnZJTq8OXAkt/3YGfQX45vvMYXpZoo8NdWZcY73K108Jf759lS1Bv/8wXnHDTSz17dSRw==} @@ -31082,7 +31643,7 @@ packages: mime-types: 2.1.35 range-parser: 1.2.1 schema-utils: 3.3.0 - webpack: 5.89.0 + webpack: 5.89.0(esbuild@0.19.11) /webpack-merge@5.10.0: resolution: {integrity: sha512-+4zXKdx7UnO+1jaN4l2lHVD+mFvnlZQP/6ljaJVb4SZiwIKeUnrT5l0gkT8z+n4hKpC+jpOv6O9R+gLtag7pSA==} @@ -31151,6 +31712,45 @@ packages: - esbuild - uglify-js + /webpack@5.89.0(esbuild@0.19.11): + resolution: {integrity: sha512-qyfIC10pOr70V+jkmud8tMfajraGCZMBWJtrmuBymQKCrLTRejBI8STDp1MCyZu/QTdZSeacCQYpYNQVOzX5kw==} + engines: {node: '>=10.13.0'} + hasBin: true + peerDependencies: + webpack-cli: '*' + peerDependenciesMeta: + webpack-cli: + optional: true + dependencies: + '@types/eslint-scope': 3.7.7 + '@types/estree': 1.0.5 + '@webassemblyjs/ast': 1.11.6 + '@webassemblyjs/wasm-edit': 1.11.6 + '@webassemblyjs/wasm-parser': 1.11.6 + acorn: 8.11.3 + acorn-import-assertions: 1.9.0(acorn@8.11.3) + browserslist: 4.22.2 + chrome-trace-event: 1.0.3 + enhanced-resolve: 5.15.0 + es-module-lexer: 1.4.1 + eslint-scope: 5.1.1 + events: 3.3.0 + glob-to-regexp: 0.4.1 + graceful-fs: 4.2.11 + json-parse-even-better-errors: 2.3.1 + loader-runner: 4.3.0 + mime-types: 2.1.35 + neo-async: 2.6.2 + schema-utils: 3.3.0 + tapable: 2.2.1 + terser-webpack-plugin: 5.3.10(esbuild@0.19.11)(webpack@5.89.0) + watchpack: 2.4.0 + webpack-sources: 3.2.3 + transitivePeerDependencies: + - '@swc/core' + - esbuild + - uglify-js + /website-scraper@5.3.1: resolution: {integrity: sha512-gogqPXD2gVsxoyd2yRiympw3rA5GuEpD1CaDEJ/J8zzanx7hkbTtneoO1SGs436PpLbWVcUge+6APGLhzsuZPA==} engines: {node: '>=14.14'} From 8a0215083cdc970bbe69b433c801362c2dee58e7 Mon Sep 17 00:00:00 2001 From: Philipp Melab Date: Mon, 22 Jan 2024 10:55:06 +0100 Subject: [PATCH 02/15] refactor(SLB-201): directly load stylesheets in gatsby --- apps/website/gatsby-browser.ts | 2 -- apps/website/gatsby-config.mjs | 1 + apps/website/gatsby-ssr.ts | 11 +++++++++-- apps/website/package.json | 2 -- 4 files changed, 10 insertions(+), 6 deletions(-) diff --git a/apps/website/gatsby-browser.ts b/apps/website/gatsby-browser.ts index 868af361d..e0a930c7f 100644 --- a/apps/website/gatsby-browser.ts +++ b/apps/website/gatsby-browser.ts @@ -1,5 +1,3 @@ -import './styles.css'; - import { registerExecutor } from '@custom/schema'; import { GatsbyBrowser } from 'gatsby'; diff --git a/apps/website/gatsby-config.mjs b/apps/website/gatsby-config.mjs index c8e83ddde..7fd7d8ef0 100644 --- a/apps/website/gatsby-config.mjs +++ b/apps/website/gatsby-config.mjs @@ -46,6 +46,7 @@ export default { resolve: '@amazeelabs/gatsby-plugin-static-dirs', options: { directories: { + 'node_modules/@custom/ui/build/styles.css': '/styles.css', 'node_modules/@custom/ui/static/public': '/', 'node_modules/@custom/decap/dist': '/admin', 'node_modules/@custom/decap/media': '/media', diff --git a/apps/website/gatsby-ssr.ts b/apps/website/gatsby-ssr.ts index b8b973919..60803e9c6 100644 --- a/apps/website/gatsby-ssr.ts +++ b/apps/website/gatsby-ssr.ts @@ -1,12 +1,12 @@ -import './styles.css'; - import { Locale, registerExecutor } from '@custom/schema'; import { GatsbySSR } from 'gatsby'; +import React from 'react'; import { drupalExecutor } from './src/utils/drupal-executor'; export const onRenderBody: GatsbySSR['onRenderBody'] = ({ setHtmlAttributes, + setHeadComponents, pathname, }) => { registerExecutor(drupalExecutor(`/graphql`)); @@ -27,4 +27,11 @@ export const onRenderBody: GatsbySSR['onRenderBody'] = ({ // We don't know the language. } } + setHeadComponents([ + React.createElement('link', { + key: 'styles.css', + rel: 'stylesheet', + href: '/styles.css', + }), + ]); }; diff --git a/apps/website/package.json b/apps/website/package.json index 9f5541eff..1eaf14af2 100644 --- a/apps/website/package.json +++ b/apps/website/package.json @@ -39,8 +39,6 @@ }, "scripts": { "test:static": "tsc --noEmit && eslint '**/*.{ts,tsx,js,jsx}' --ignore-path='./.gitignore'", - "prep": "pnpm run prep:styles", - "prep:styles": "rm -f styles.css && cp node_modules/@custom/ui/build/styles.css styles.css", "build:gatsby": "pnpm build:dotenv && gatsby build", "build:dotenv": "rm -rf .env && echo \"DRUPAL_EXTERNAL_URL='$DRUPAL_EXTERNAL_URL'\nDRUPAL_INTERNAL_URL='$DRUPAL_INTERNAL_URL'\" >> .env", "rebuild": "gatsby build", From 095f6c8b1b2185400962d40de7ce6663cabd1869 Mon Sep 17 00:00:00 2001 From: Philipp Melab Date: Tue, 23 Jan 2024 11:26:05 +0100 Subject: [PATCH 03/15] refactor(SLB-201): make ui a proper dependency of CMS --- apps/cms/package.json | 3 ++- packages/drupal-themes/custom_iframe/.gitignore | 1 - packages/drupal-themes/custom_iframe/styles.css | 1 + packages/ui/package.json | 2 +- packages/ui/turbo.json | 2 +- pnpm-lock.yaml | 3 +++ 6 files changed, 8 insertions(+), 4 deletions(-) delete mode 100644 packages/drupal-themes/custom_iframe/.gitignore create mode 120000 packages/drupal-themes/custom_iframe/styles.css diff --git a/apps/cms/package.json b/apps/cms/package.json index 9246ca58f..fe572fb3f 100644 --- a/apps/cms/package.json +++ b/apps/cms/package.json @@ -33,6 +33,7 @@ "@custom/custom_heavy": "workspace:*", "@custom/gutenberg_blocks": "workspace:*", "@custom/schema": "workspace:*", - "@custom/test_content": "workspace:*" + "@custom/test_content": "workspace:*", + "@custom/ui": "workspace:*" } } diff --git a/packages/drupal-themes/custom_iframe/.gitignore b/packages/drupal-themes/custom_iframe/.gitignore deleted file mode 100644 index 9649ceff4..000000000 --- a/packages/drupal-themes/custom_iframe/.gitignore +++ /dev/null @@ -1 +0,0 @@ -/styles.css diff --git a/packages/drupal-themes/custom_iframe/styles.css b/packages/drupal-themes/custom_iframe/styles.css new file mode 120000 index 000000000..61abb785c --- /dev/null +++ b/packages/drupal-themes/custom_iframe/styles.css @@ -0,0 +1 @@ +../../ui/build/cms.css \ No newline at end of file diff --git a/packages/ui/package.json b/packages/ui/package.json index 03d23b316..1a2d6a966 100644 --- a/packages/ui/package.json +++ b/packages/ui/package.json @@ -26,7 +26,7 @@ "prep:types": "tsc --emitDeclarationOnly", "prep:scripts": "swc ./src -d ./build", "prep:styles": "NODE_ENV=production pnpm postcss tailwind.css -o build/styles.css", - "prep:cms-css": "NODE_ENV=production pnpm postcss cms.css -o ../drupal-themes/custom_iframe/styles.css", + "prep:cms-css": "NODE_ENV=production pnpm postcss cms.css -o build/cms.css", "prep:gutenberg": "NODE_ENV=production PREFIX=gutenberg pnpm postcss tailwind.css -o build/gutenberg.css", "prep:i18n": "formatjs extract 'src/**/*.ts*' --ignore='**/*.d.ts' --ignore='**/*.stories.ts*' --out-file build/translatables.json --id-interpolation-pattern '[sha512:contenthash:base64:6]'\n", "build": "storybook build", diff --git a/packages/ui/turbo.json b/packages/ui/turbo.json index 3fa5d8757..e0285bef1 100644 --- a/packages/ui/turbo.json +++ b/packages/ui/turbo.json @@ -34,7 +34,7 @@ }, "prep:cms-css": { "inputs": ["postcss.config.cjs", "tailwind.config.cjs", "cms.css"], - "outputs": ["../drupal-themes/custom_iframe/styles.css"] + "outputs": ["build/cms.css"] }, "prep:gutenberg": { "inputs": [ diff --git a/pnpm-lock.yaml b/pnpm-lock.yaml index 78d874a0b..34578b6b6 100644 --- a/pnpm-lock.yaml +++ b/pnpm-lock.yaml @@ -82,6 +82,9 @@ importers: '@custom/test_content': specifier: workspace:* version: link:../../packages/drupal/test_content + '@custom/ui': + specifier: workspace:* + version: link:../../packages/ui apps/decap: dependencies: From 67dba867a8664689497ce272bd238f1127a66725 Mon Sep 17 00:00:00 2001 From: Philipp Melab Date: Tue, 23 Jan 2024 11:28:29 +0100 Subject: [PATCH 04/15] refactor(SLB-201): rename cms.css to iframe.css to make its purpose clearer --- packages/ui/{cms.css => iframe.css} | 0 packages/ui/package.json | 2 +- .../Organisms/PageContent/BlockForm.stories.tsx | 2 +- packages/ui/turbo.json | 8 ++++---- 4 files changed, 6 insertions(+), 6 deletions(-) rename packages/ui/{cms.css => iframe.css} (100%) diff --git a/packages/ui/cms.css b/packages/ui/iframe.css similarity index 100% rename from packages/ui/cms.css rename to packages/ui/iframe.css diff --git a/packages/ui/package.json b/packages/ui/package.json index 1a2d6a966..909721523 100644 --- a/packages/ui/package.json +++ b/packages/ui/package.json @@ -26,7 +26,7 @@ "prep:types": "tsc --emitDeclarationOnly", "prep:scripts": "swc ./src -d ./build", "prep:styles": "NODE_ENV=production pnpm postcss tailwind.css -o build/styles.css", - "prep:cms-css": "NODE_ENV=production pnpm postcss cms.css -o build/cms.css", + "prep:iframe": "NODE_ENV=production pnpm postcss iframe.css -o build/iframe.css", "prep:gutenberg": "NODE_ENV=production PREFIX=gutenberg pnpm postcss tailwind.css -o build/gutenberg.css", "prep:i18n": "formatjs extract 'src/**/*.ts*' --ignore='**/*.d.ts' --ignore='**/*.stories.ts*' --out-file build/translatables.json --id-interpolation-pattern '[sha512:contenthash:base64:6]'\n", "build": "storybook build", diff --git a/packages/ui/src/components/Organisms/PageContent/BlockForm.stories.tsx b/packages/ui/src/components/Organisms/PageContent/BlockForm.stories.tsx index 53c946c8a..777f1c134 100644 --- a/packages/ui/src/components/Organisms/PageContent/BlockForm.stories.tsx +++ b/packages/ui/src/components/Organisms/PageContent/BlockForm.stories.tsx @@ -1,7 +1,7 @@ import { Url } from '@custom/schema'; import { Meta, StoryObj } from '@storybook/react'; -import cmsCss from '../../../../cms.css?inline'; +import cmsCss from '../../../../iframe.css?inline'; import { BlockForm } from './BlockForm'; export default { diff --git a/packages/ui/turbo.json b/packages/ui/turbo.json index e0285bef1..19df13ebc 100644 --- a/packages/ui/turbo.json +++ b/packages/ui/turbo.json @@ -32,9 +32,9 @@ ], "outputs": ["build/styles.css"] }, - "prep:cms-css": { - "inputs": ["postcss.config.cjs", "tailwind.config.cjs", "cms.css"], - "outputs": ["build/cms.css"] + "prep:iframe": { + "inputs": ["postcss.config.cjs", "tailwind.config.cjs", "iframe.css"], + "outputs": ["build/iframe.css"] }, "prep:gutenberg": { "inputs": [ @@ -55,7 +55,7 @@ "prep:types", "prep:scripts", "prep:styles", - "prep:cms-css", + "prep:iframe", "prep:gutenberg", "prep:i18n" ] From 28e981e62261d26a721d78fb4ae3a84f88326707 Mon Sep 17 00:00:00 2001 From: Philipp Melab Date: Tue, 23 Jan 2024 11:32:53 +0100 Subject: [PATCH 05/15] refactor(SLB-201): load stylesheets via symlinks to node_modules/@custom/ui --- apps/cms/.gitignore | 4 ++++ apps/cms/web/gutenberg.css | 1 + apps/cms/web/iframe.css | 1 + .../custom_iframe/custom_iframe.libraries.yml | 2 +- packages/drupal-themes/custom_iframe/styles.css | 1 - .../gutenberg_blocks/gutenberg_blocks.libraries.yml | 9 +++++---- 6 files changed, 12 insertions(+), 6 deletions(-) create mode 120000 apps/cms/web/gutenberg.css create mode 120000 apps/cms/web/iframe.css delete mode 120000 packages/drupal-themes/custom_iframe/styles.css diff --git a/apps/cms/.gitignore b/apps/cms/.gitignore index 3b578cc97..9f48ed0ec 100644 --- a/apps/cms/.gitignore +++ b/apps/cms/.gitignore @@ -32,5 +32,9 @@ generated/translations.json # GraphQL autoload registry autoload.json +# Stylesheet symlinks into the ui package +!/web/gutenberg.css +!/web/iframe.css + # A workaround to avoid turbo caching locally. turbo-seed.txt diff --git a/apps/cms/web/gutenberg.css b/apps/cms/web/gutenberg.css new file mode 120000 index 000000000..7cf95d53c --- /dev/null +++ b/apps/cms/web/gutenberg.css @@ -0,0 +1 @@ +../node_modules/@custom/ui/build/gutenberg.css \ No newline at end of file diff --git a/apps/cms/web/iframe.css b/apps/cms/web/iframe.css new file mode 120000 index 000000000..0dc61887c --- /dev/null +++ b/apps/cms/web/iframe.css @@ -0,0 +1 @@ +../node_modules/@custom/ui/build/iframe.css \ No newline at end of file diff --git a/packages/drupal-themes/custom_iframe/custom_iframe.libraries.yml b/packages/drupal-themes/custom_iframe/custom_iframe.libraries.yml index f891cf5ce..d30e7ec06 100644 --- a/packages/drupal-themes/custom_iframe/custom_iframe.libraries.yml +++ b/packages/drupal-themes/custom_iframe/custom_iframe.libraries.yml @@ -1,4 +1,4 @@ global: css: theme: - styles.css: { preprocess: false } + /iframe.css: { preprocess: false } diff --git a/packages/drupal-themes/custom_iframe/styles.css b/packages/drupal-themes/custom_iframe/styles.css deleted file mode 120000 index 61abb785c..000000000 --- a/packages/drupal-themes/custom_iframe/styles.css +++ /dev/null @@ -1 +0,0 @@ -../../ui/build/cms.css \ No newline at end of file diff --git a/packages/drupal/gutenberg_blocks/gutenberg_blocks.libraries.yml b/packages/drupal/gutenberg_blocks/gutenberg_blocks.libraries.yml index cb96e33f5..884f338e8 100644 --- a/packages/drupal/gutenberg_blocks/gutenberg_blocks.libraries.yml +++ b/packages/drupal/gutenberg_blocks/gutenberg_blocks.libraries.yml @@ -1,16 +1,17 @@ edit: version: VERSION js: - js/gutenberg_blocks.umd.js: { } + js/gutenberg_blocks.umd.js: {} css: theme: - css/edit.css: { } + css/edit.css: {} dependencies: - gutenberg/edit-node - silverback_gutenberg/base customisations: css: theme: - css/ui.css: { preprocess: false } + /gutenberg.css: { preprocess: false } dependencies: - - core/drupalSettings \ No newline at end of file + - core/drupalSettings + From e3d67f312bed878476ccf8f3f1399224184e043d Mon Sep 17 00:00:00 2001 From: Philipp Melab Date: Tue, 23 Jan 2024 11:38:41 +0100 Subject: [PATCH 06/15] fix(SLB-201): remove wrong output definition Mistakenly added. They should be in @custom/schema --- packages/ui/turbo.json | 6 +----- 1 file changed, 1 insertion(+), 5 deletions(-) diff --git a/packages/ui/turbo.json b/packages/ui/turbo.json index 19df13ebc..a4abaa387 100644 --- a/packages/ui/turbo.json +++ b/packages/ui/turbo.json @@ -11,11 +11,7 @@ "tsconfig.json", "static/public/**" ], - "outputs": [ - "build/**/*.js", - "../../apps/cms/autoload.json", - "../../apps/website/autoload.mjs" - ] + "outputs": ["build/**/*.js"] }, "prep:types": { "dependsOn": ["^prep"], From a922a77dd493b95250dacb75df603e015cd9bcaa Mon Sep 17 00:00:00 2001 From: Philipp Melab Date: Tue, 23 Jan 2024 11:50:00 +0100 Subject: [PATCH 07/15] refactor(SLB-201): symlink autoloaders instead of building them to the outside --- apps/cms/config/sync/graphql.graphql_servers.main.yml | 4 ++-- apps/website/.gitignore | 2 -- apps/website/gatsby-autoload.mjs | 1 + apps/website/gatsby-config.mjs | 2 +- packages/schema/codegen.ts | 4 ++-- packages/schema/turbo.json | 6 +----- 6 files changed, 7 insertions(+), 12 deletions(-) create mode 120000 apps/website/gatsby-autoload.mjs diff --git a/apps/cms/config/sync/graphql.graphql_servers.main.yml b/apps/cms/config/sync/graphql.graphql_servers.main.yml index 1d9d21d43..76f02690a 100644 --- a/apps/cms/config/sync/graphql.graphql_servers.main.yml +++ b/apps/cms/config/sync/graphql.graphql_servers.main.yml @@ -1,7 +1,7 @@ uuid: f31854e4-2c2b-4687-9553-9f2d1f87028c langcode: en status: true -dependencies: { } +dependencies: {} name: main label: Main endpoint: /graphql @@ -15,7 +15,7 @@ query_complexity: null schema_configuration: directable: schema_definition: ../node_modules/@custom/schema/build/schema.graphql - autoload_registry: ../autoload.json + autoload_registry: ../node_modules/@custom/schema/build/drupal-autoload.json extensions: silverback_campaign_urls: silverback_campaign_urls silverback_gatsby: silverback_gatsby diff --git a/apps/website/.gitignore b/apps/website/.gitignore index 6806e41da..395b0379a 100644 --- a/apps/website/.gitignore +++ b/apps/website/.gitignore @@ -5,5 +5,3 @@ public styles.css persisted-store - -autoload.mjs diff --git a/apps/website/gatsby-autoload.mjs b/apps/website/gatsby-autoload.mjs new file mode 120000 index 000000000..2b3750cdc --- /dev/null +++ b/apps/website/gatsby-autoload.mjs @@ -0,0 +1 @@ +node_modules/@custom/schema/build/gatsby-autoload.mjs \ No newline at end of file diff --git a/apps/website/gatsby-config.mjs b/apps/website/gatsby-config.mjs index 7fd7d8ef0..79a73b0a5 100644 --- a/apps/website/gatsby-config.mjs +++ b/apps/website/gatsby-config.mjs @@ -9,7 +9,7 @@ import { getPages } from '@custom/decap'; import { resolve } from 'path'; -import autoload from './autoload.mjs'; +import autoload from './gatsby-autoload.mjs'; const dir = resolve('node_modules/@custom/decap/data/page'); diff --git a/packages/schema/codegen.ts b/packages/schema/codegen.ts index 5d0086663..44f75b652 100644 --- a/packages/schema/codegen.ts +++ b/packages/schema/codegen.ts @@ -32,7 +32,7 @@ const config: CodegenConfig = { plugins: ['@amazeelabs/codegen-operation-ids'], }, // Directive autoloader for Gatsby. - '../../apps/website/autoload.mjs': { + 'build/gatsby-autoload.mjs': { plugins: ['@amazeelabs/codegen-autoloader'], config: { mode: 'js', @@ -41,7 +41,7 @@ const config: CodegenConfig = { }, }, // Directive autoloader for Drupla. - '../../apps/cms/autoload.json': { + 'build/drupal-autoload.json': { plugins: ['@amazeelabs/codegen-autoloader'], config: { mode: 'drupal', diff --git a/packages/schema/turbo.json b/packages/schema/turbo.json index 5869cc365..8b1331d3c 100644 --- a/packages/schema/turbo.json +++ b/packages/schema/turbo.json @@ -13,11 +13,7 @@ ".graphqlrc.json", "tsconfig.json" ], - "outputs": [ - "build/**", - "../../apps/website/autoload.mjs", - "../../apps/cms/autoload.json" - ] + "outputs": ["build/**"] } } } From 972dc300807f198add8507eed529eef790e8cba2 Mon Sep 17 00:00:00 2001 From: Philipp Melab Date: Tue, 23 Jan 2024 13:37:17 +0100 Subject: [PATCH 08/15] fix(SLB-201): move gatsby directive autoloading entirely into schema package --- apps/website/gatsby-autoload.mjs | 1 - apps/website/gatsby-config.mjs | 3 +- apps/website/package.json | 3 +- packages/schema/.graphqlrc.json | 2 +- packages/schema/package.json | 14 +- .../image.mjs => packages/schema/src/image.ts | 12 +- packages/schema/src/schema.graphql | 2 +- .../schema/src/types/gatsby-autoload.d.ts | 3 + .../schema}/src/types/mime-types.d.ts | 0 packages/schema/tsconfig.json | 3 +- pnpm-lock.yaml | 148 +++++++++++------- 11 files changed, 120 insertions(+), 71 deletions(-) delete mode 120000 apps/website/gatsby-autoload.mjs rename apps/website/image.mjs => packages/schema/src/image.ts (73%) create mode 100644 packages/schema/src/types/gatsby-autoload.d.ts rename {apps/website => packages/schema}/src/types/mime-types.d.ts (100%) diff --git a/apps/website/gatsby-autoload.mjs b/apps/website/gatsby-autoload.mjs deleted file mode 120000 index 2b3750cdc..000000000 --- a/apps/website/gatsby-autoload.mjs +++ /dev/null @@ -1 +0,0 @@ -node_modules/@custom/schema/build/gatsby-autoload.mjs \ No newline at end of file diff --git a/apps/website/gatsby-config.mjs b/apps/website/gatsby-config.mjs index 79a73b0a5..dd32b3d5b 100644 --- a/apps/website/gatsby-config.mjs +++ b/apps/website/gatsby-config.mjs @@ -7,10 +7,9 @@ // pick it up instead of the JS file. import { getPages } from '@custom/decap'; +import autoload from '@custom/schema/gatsby-autoload'; import { resolve } from 'path'; -import autoload from './gatsby-autoload.mjs'; - const dir = resolve('node_modules/@custom/decap/data/page'); process.env.GATSBY_DRUPAL_URL = diff --git a/apps/website/package.json b/apps/website/package.json index 1eaf14af2..a24e8a2f1 100644 --- a/apps/website/package.json +++ b/apps/website/package.json @@ -5,9 +5,8 @@ "@amazeelabs/bridge-gatsby": "^1.2.7", "@amazeelabs/cloudinary-responsive-image": "^1.6.15", "@amazeelabs/gatsby-plugin-operations": "^1.1.3", - "@amazeelabs/gatsby-silverback-cloudinary": "^1.2.7", - "@amazeelabs/gatsby-source-silverback": "^1.13.10", "@amazeelabs/gatsby-plugin-static-dirs": "workspace:*", + "@amazeelabs/gatsby-source-silverback": "^1.13.10", "@amazeelabs/publisher": "^2.4.17", "@amazeelabs/strangler-netlify": "^1.1.9", "@custom/decap": "workspace:*", diff --git a/packages/schema/.graphqlrc.json b/packages/schema/.graphqlrc.json index a4ca1086a..cacb28f39 100644 --- a/packages/schema/.graphqlrc.json +++ b/packages/schema/.graphqlrc.json @@ -1,7 +1,7 @@ { "$schema": "https://unpkg.com/graphql-config@5.0.3/config-schema.json", "schema": [ - "../../apps/website/node_modules/@amazeelabs/*/directives.graphql", + "node_modules/@amazeelabs/*/directives.graphql", "../../apps/cms/web/modules/contrib/*/directives.graphql", "../../apps/cms/web/modules/custom/*/directives.graphql", "src/schema.graphql" diff --git a/packages/schema/package.json b/packages/schema/package.json index 2f047b1f5..4dff901c7 100644 --- a/packages/schema/package.json +++ b/packages/schema/package.json @@ -15,6 +15,9 @@ ], "./operations": [ "./build/operations.json" + ], + "./gatsby-autoload": [ + "./build/gatsby-autoload.mjs" ] }, "typesVersions": { @@ -24,6 +27,9 @@ ], "/source": [ "build/generated/source.d.ts" + ], + "gatsby-autoload": [ + "src/types/gatsby-autoload.d.ts" ] } }, @@ -43,14 +49,20 @@ "@graphql-codegen/typescript-operations": "^4.0.1", "@swc/cli": "^0.1.62", "@swc/core": "^1.3.67", + "@types/image-size": "^0.8.0", + "@types/node": "^18", "concurrently": "^8.2.2", "graphql": "16.8.1", "typescript": "^5.3.3" }, "dependencies": { "@amazeelabs/executors": "^1.1.0", + "@amazeelabs/gatsby-silverback-cloudinary": "^1.2.7", + "@amazeelabs/gatsby-source-silverback": "^1.13.10", "@amazeelabs/scalars": "^1.6.13", "@swc/cli": "^0.1.63", - "@swc/core": "^1.3.102" + "@swc/core": "^1.3.102", + "image-size": "^1.1.1", + "mime-types": "^2.1.35" } } diff --git a/apps/website/image.mjs b/packages/schema/src/image.ts similarity index 73% rename from apps/website/image.mjs rename to packages/schema/src/image.ts index 157eb6051..bc3ab7551 100644 --- a/apps/website/image.mjs +++ b/packages/schema/src/image.ts @@ -1,10 +1,8 @@ +import type { GraphQLFieldResolver } from 'graphql'; import sizeOf from 'image-size'; -import mime from 'mime-types'; +import { lookup } from 'mime-types'; -/** - * @param {string | undefined} source - */ -export function imageProps(source) { +export const imageProps: GraphQLFieldResolver = (source) => { // If its a decap image, process it. // Otherwise, it comes from Drupal and // already has all necessary props. @@ -20,8 +18,8 @@ export function imageProps(source) { originalSrc: imageSrc, width: dimensions.width || 0, height: dimensions.height || 0, - mime: mime.lookup(relativeSource) || 'application/octet-stream', + mime: lookup(relativeSource) || 'application/octet-stream', }); } return source; -} +}; diff --git a/packages/schema/src/schema.graphql b/packages/schema/src/schema.graphql index 054ab842b..c84cabde3 100644 --- a/packages/schema/src/schema.graphql +++ b/packages/schema/src/schema.graphql @@ -6,7 +6,7 @@ scalar ImageSource @default @value(json: "\"\"") Retrieve the properties of an image. TODO: Move to a shared "image" package. -implementation(gatsby): ./image.mjs#imageProps +implementation(gatsby): ./image.js#imageProps """ directive @imageProps repeatable on FIELD_DEFINITION | SCALAR | UNION | ENUM | INTERFACE | OBJECT diff --git a/packages/schema/src/types/gatsby-autoload.d.ts b/packages/schema/src/types/gatsby-autoload.d.ts new file mode 100644 index 000000000..7029ee48b --- /dev/null +++ b/packages/schema/src/types/gatsby-autoload.d.ts @@ -0,0 +1,3 @@ +import { GraphQLFieldResolver } from 'graphql'; + +export default Record>; diff --git a/apps/website/src/types/mime-types.d.ts b/packages/schema/src/types/mime-types.d.ts similarity index 100% rename from apps/website/src/types/mime-types.d.ts rename to packages/schema/src/types/mime-types.d.ts diff --git a/packages/schema/tsconfig.json b/packages/schema/tsconfig.json index ef52f825f..c93ea6306 100644 --- a/packages/schema/tsconfig.json +++ b/packages/schema/tsconfig.json @@ -6,7 +6,8 @@ "forceConsistentCasingInFileNames": true, "declaration": true, "declarationDir": "build", - "outDir": "build" + "outDir": "build", + "lib": ["ES2015"] }, "include": ["src"] } diff --git a/pnpm-lock.yaml b/pnpm-lock.yaml index 34578b6b6..6f163dbcc 100644 --- a/pnpm-lock.yaml +++ b/pnpm-lock.yaml @@ -166,7 +166,7 @@ importers: version: 1.3.24 tsup: specifier: ^8.0.1 - version: 8.0.1(typescript@5.3.3) + version: 8.0.1(postcss@8.4.32)(typescript@5.3.3) typescript: specifier: ^5.3.3 version: 5.3.3 @@ -188,9 +188,6 @@ importers: '@amazeelabs/gatsby-plugin-static-dirs': specifier: workspace:* version: link:../../packages/gatsby-plugin-static-dirs - '@amazeelabs/gatsby-silverback-cloudinary': - specifier: ^1.2.7 - version: 1.2.7 '@amazeelabs/gatsby-source-silverback': specifier: ^1.13.10 version: 1.13.10(@types/node@18.19.4)(gatsby@5.13.1)(typescript@4.9.5) @@ -350,6 +347,12 @@ importers: '@amazeelabs/executors': specifier: ^1.1.0 version: 1.1.0 + '@amazeelabs/gatsby-silverback-cloudinary': + specifier: ^1.2.7 + version: 1.2.7 + '@amazeelabs/gatsby-source-silverback': + specifier: ^1.13.10 + version: 1.13.10(@types/node@18.19.4)(gatsby@5.13.1)(typescript@5.3.3) '@amazeelabs/scalars': specifier: ^1.6.13 version: 1.6.13(react@18.2.0)(tailwindcss@3.4.0) @@ -359,6 +362,12 @@ importers: '@swc/core': specifier: ^1.3.102 version: 1.3.102 + image-size: + specifier: ^1.1.1 + version: 1.1.1 + mime-types: + specifier: ^2.1.35 + version: 2.1.35 devDependencies: '@amazeelabs/codegen-autoloader': specifier: ^1.1.3 @@ -378,6 +387,12 @@ importers: '@graphql-codegen/typescript-operations': specifier: ^4.0.1 version: 4.0.1(graphql@16.8.1) + '@types/image-size': + specifier: ^0.8.0 + version: 0.8.0 + '@types/node': + specifier: ^18 + version: 18.19.4 concurrently: specifier: ^8.2.2 version: 8.2.2 @@ -814,6 +829,28 @@ packages: - utf-8-validate dev: false + /@amazeelabs/gatsby-source-silverback@1.13.10(@types/node@18.19.4)(gatsby@5.13.1)(typescript@5.3.3): + resolution: {integrity: sha512-NPukKTJHj3EFrG0EeABoLsQzWLUuJkKthzhGggStKwV1dQ797IF1cVkYk4IMJoB+Y53YeVjE9fzQeCBOWW8NZA==} + dependencies: + '@amazeelabs/graphql-directives': 1.2.5 + fetch-retry: 5.0.6 + gatsby-graphql-source-toolkit: 2.0.4(gatsby@5.13.1) + graphql: 16.8.1 + graphql-config: 5.0.3(@types/node@18.19.4)(graphql@16.8.1)(typescript@5.3.3) + isomorphic-fetch: 3.0.0 + lodash-es: 4.17.21 + node-fetch: 3.3.2 + timeout-signal: 2.0.0 + transitivePeerDependencies: + - '@types/node' + - bufferutil + - cosmiconfig-toml-loader + - encoding + - gatsby + - typescript + - utf-8-validate + dev: false + /@amazeelabs/gatsby-source-silverback@1.13.7(@types/node@18.19.4)(gatsby@5.13.1)(typescript@5.3.3): resolution: {integrity: sha512-OAy/RrOrb5sP7Ix25qS9NXCaK2reLh5GC1ikxreB2ZOJn4HKj92Uq4v3WoDSTYnM8qh+xkUMiOhdbEu9jYJe0w==} dependencies: @@ -7308,7 +7345,7 @@ packages: react-refresh: 0.14.0 schema-utils: 3.3.0 source-map: 0.7.4 - webpack: 5.89.0(esbuild@0.19.11) + webpack: 5.89.0(@swc/core@1.3.102) /@pnpm/config.env-replace@1.1.0: resolution: {integrity: sha512-htyl8TWnKL7K/ESFa1oW2UB5lVDxuF5DpM7tBi6Hu2LNL3mWkIzNLG6N4zoCUP1lCKNxWy/3iu8mS8MvToGd6w==} @@ -9516,6 +9553,13 @@ packages: dependencies: '@types/node': 18.19.4 + /@types/image-size@0.8.0: + resolution: {integrity: sha512-hMlhu25ji75dXQk2uZkN3pTJ+lWrgKr8M1fTpyyFvuu+SJZBdGa5gDm4BVNobWXHZbOU11mBj0vciYp7qOfAFg==} + deprecated: This is a stub types definition. image-size provides its own type definitions, so you do not need this installed. + dependencies: + image-size: 1.1.1 + dev: true + /@types/is-hotkey@0.1.10: resolution: {integrity: sha512-RvC8KMw5BCac1NvRRyaHgMMEtBaZ6wh0pyPTBu7izn4Sj/AX9Y4aXU5c7rX8PnM/knsuUpC1IeoBkANtxBypsQ==} dev: false @@ -9641,6 +9685,7 @@ packages: /@types/prop-types@15.7.11: resolution: {integrity: sha512-ga8y9v9uyeiLdpKddhxYQkxNDrfvuPrlFb0N1qnZZByvcElJaXthF1UhvCh9TLWJBEHeNtdnbysW7Y6Uq8CVng==} + requiresBuild: true /@types/qs@6.9.11: resolution: {integrity: sha512-oGk0gmhnEJK4Yyk+oI7EfXsLayXatCWPHary1MtcmbAifkobT9cM9yutG/hZKIseOU0MqbIwQ/u2nn/Gb+ltuQ==} @@ -9692,6 +9737,7 @@ packages: /@types/react@18.2.46: resolution: {integrity: sha512-nNCvVBcZlvX4NU1nRRNV/mFl1nNRuTuslAJglQsq+8ldXe5Xv0Wd2f7WTE3jOxhLH2BFfiZGC6GCp+kHQbgG+w==} + requiresBuild: true dependencies: '@types/prop-types': 15.7.11 '@types/scheduler': 0.16.8 @@ -9724,6 +9770,7 @@ packages: /@types/scheduler@0.16.8: resolution: {integrity: sha512-WZLiwShhwLRmeV6zH+GkbOFT6Z6VklCItrDioxUnv+u4Ll+8vKeFySoFyK/0ctcRpOmwAicELfmys1sDc/Rw+A==} + requiresBuild: true /@types/semver@7.5.6: resolution: {integrity: sha512-dn1l8LaMea/IjDoHNd9J52uBbInB796CDffS6VdIxvqYCPSG0V0DzHp76GpaWnlhg88uYyPbXCDIowa86ybd5A==} @@ -9973,6 +10020,7 @@ packages: /@typescript-eslint/eslint-plugin@5.62.0(@typescript-eslint/parser@5.62.0)(eslint@7.32.0)(typescript@5.3.3): resolution: {integrity: sha512-TiZzBSJja/LbhNPvk6yc0JrX9XqhQ0hdh6M2svYfsHGejaKFIAGd9MQ+ERIMzLGlN/kZoYIgdxFV0PuljTKXag==} engines: {node: ^12.22.0 || ^14.17.0 || >=16.0.0} + requiresBuild: true peerDependencies: '@typescript-eslint/parser': ^5.0.0 eslint: ^6.0.0 || ^7.0.0 || ^8.0.0 @@ -10049,6 +10097,7 @@ packages: /@typescript-eslint/parser@5.62.0(eslint@7.32.0)(typescript@5.3.3): resolution: {integrity: sha512-VlJEV0fOQ7BExOsHYAGrgbEiZoi8D+Bl2+f6V2RrXerRSylnp+ZBHmPvaIa8cz0Ajx7WO7Z5RqfgYg7ED1nRhA==} engines: {node: ^12.22.0 || ^14.17.0 || >=16.0.0} + requiresBuild: true peerDependencies: eslint: ^6.0.0 || ^7.0.0 || ^8.0.0 typescript: '*' @@ -10089,6 +10138,7 @@ packages: /@typescript-eslint/scope-manager@5.62.0: resolution: {integrity: sha512-VXuvVvZeQCQb5Zgf4HAxc04q5j+WrNAtNh9OwCsCgpKqESMTu3tF/jhZ3xG6T4NZwWl65Bg8KuS2uEvhSfLl0w==} engines: {node: ^12.22.0 || ^14.17.0 || >=16.0.0} + requiresBuild: true dependencies: '@typescript-eslint/types': 5.62.0 '@typescript-eslint/visitor-keys': 5.62.0 @@ -10124,6 +10174,7 @@ packages: /@typescript-eslint/type-utils@5.62.0(eslint@7.32.0)(typescript@5.3.3): resolution: {integrity: sha512-xsSQreu+VnfbqQpW5vnCJdq1Z3Q0U31qiWmRhr98ONQmcp/yhiPJFPq8MXiJVLiksmOKSjIldZzkebzHuCGzew==} engines: {node: ^12.22.0 || ^14.17.0 || >=16.0.0} + requiresBuild: true peerDependencies: eslint: '*' typescript: '*' @@ -10163,6 +10214,7 @@ packages: /@typescript-eslint/types@5.62.0: resolution: {integrity: sha512-87NVngcbVXUahrRTqIK27gD2t5Cu1yuCXxbLcFtCzZGlfyVWWh8mLHkoxzjsB6DDNnvdL+fW8MiwPEJyGJQDgQ==} engines: {node: ^12.22.0 || ^14.17.0 || >=16.0.0} + requiresBuild: true /@typescript-eslint/types@6.17.0: resolution: {integrity: sha512-qRKs9tvc3a4RBcL/9PXtKSehI/q8wuU9xYJxe97WFxnzH8NWWtcW3ffNS+EWg8uPvIerhjsEZ+rHtDqOCiH57A==} @@ -10214,6 +10266,7 @@ packages: /@typescript-eslint/typescript-estree@5.62.0(typescript@5.3.3): resolution: {integrity: sha512-CmcQ6uY7b9y694lKdRB8FEel7JbU/40iSAPomu++SjLMntB+2Leay2LO6i8VnJk58MtE9/nQSFIH6jpyRWyYzA==} engines: {node: ^12.22.0 || ^14.17.0 || >=16.0.0} + requiresBuild: true peerDependencies: typescript: '*' peerDependenciesMeta: @@ -10276,6 +10329,7 @@ packages: /@typescript-eslint/utils@5.62.0(eslint@7.32.0)(typescript@5.3.3): resolution: {integrity: sha512-n8oxjeb5aIbPFEtmQxQYOLI0i9n5ySBEY/ZEHHZqKQSFnxio1rv6dthascc9dLuwrL0RC5mPCxB7vnAVGAYWAQ==} engines: {node: ^12.22.0 || ^14.17.0 || >=16.0.0} + requiresBuild: true peerDependencies: eslint: ^6.0.0 || ^7.0.0 || ^8.0.0 dependencies: @@ -10314,6 +10368,7 @@ packages: /@typescript-eslint/visitor-keys@5.62.0: resolution: {integrity: sha512-07ny+LHRzQXepkGg6w0mFY41fVUNBrL2Roj/++7V1txKugfjm/Ci/qSND03r2RhlJhJYMcTn9AhhSSqQp0Ysyw==} engines: {node: ^12.22.0 || ^14.17.0 || >=16.0.0} + requiresBuild: true dependencies: '@typescript-eslint/types': 5.62.0 eslint-visitor-keys: 3.4.3 @@ -12064,7 +12119,7 @@ packages: loader-utils: 2.0.4 make-dir: 3.1.0 schema-utils: 2.7.1 - webpack: 5.89.0(esbuild@0.19.11) + webpack: 5.89.0(@swc/core@1.3.102) /babel-plugin-add-module-exports@1.0.4: resolution: {integrity: sha512-g+8yxHUZ60RcyaUpfNzy56OtWW+x9cyEe9j+CranqLiqbju2yf/Cy6ZtYK40EZxtrdHllzlVZgLmcOUCTlJ7Jg==} @@ -12157,7 +12212,7 @@ packages: '@babel/core': 7.23.7 '@babel/runtime': 7.23.7 '@babel/types': 7.23.6 - gatsby: 5.13.1(babel-eslint@10.1.0)(esbuild@0.19.11)(react-dom@18.2.0)(react@18.2.0)(typescript@5.3.3) + gatsby: 5.13.1(@swc/core@1.3.102)(babel-eslint@10.1.0)(react-dom@18.2.0)(react@18.2.0)(typescript@5.3.3) gatsby-core-utils: 4.13.0 /babel-plugin-syntax-trailing-function-commas@7.0.0-beta.0: @@ -13734,7 +13789,6 @@ packages: parse-json: 5.2.0 path-type: 4.0.0 typescript: 5.3.3 - dev: true /cp-file@10.0.0: resolution: {integrity: sha512-vy2Vi1r2epK5WqxOLnskeKeZkdZvTKfFZQCplE3XWsP+SUJyd5XAUFC9lFgTjjXJF2GMne/UML14iEmkAaDfFg==} @@ -13901,7 +13955,7 @@ packages: postcss-value-parser: 4.2.0 schema-utils: 3.3.0 semver: 7.5.4 - webpack: 5.89.0(esbuild@0.19.11) + webpack: 5.89.0(@swc/core@1.3.102) /css-minimizer-webpack-plugin@2.0.0(webpack@5.89.0): resolution: {integrity: sha512-cG/uc94727tx5pBNtb1Sd7gvUPzwmcQi1lkpfqTpdkuNq75hJCw7bIVsCNijLm4dhDcr1atvuysl2rZqOG8Txw==} @@ -13923,7 +13977,7 @@ packages: schema-utils: 3.3.0 serialize-javascript: 5.0.1 source-map: 0.6.1 - webpack: 5.89.0(esbuild@0.19.11) + webpack: 5.89.0(@swc/core@1.3.102) /css-select@4.3.0: resolution: {integrity: sha512-wPpOYtnsVontu2mODhA19JrqWxNsfdatRKd64kmpRbQgh1KtItko5sTnEpPdpSaJszTOhEMlF/RPz28qj4HqhQ==} @@ -14120,6 +14174,7 @@ packages: /csstype@3.1.3: resolution: {integrity: sha512-M1uQkMl8rQK/szD0LNhtqxIPLpimGm8sOBwU7lLnCpSbTyY3yeU1Vc7l4KT5zT4s/yOxHH5O7tIuuLOCnLADRw==} + requiresBuild: true /cwd@0.10.0: resolution: {integrity: sha512-YGZxdTTL9lmLkCUTpg4j0zQ7IhRB5ZmqNBbGCl3Tg6MP/d5/6sY7L5mmTjzbc6JKgVZYiqTQTNhPFsbXNGlRaA==} @@ -16460,6 +16515,7 @@ packages: /eslint-plugin-tailwindcss@3.13.1(tailwindcss@3.4.0): resolution: {integrity: sha512-2Nlgr9doO6vFAG9w4iGU0sspWXuzypfng10HTF+dFS2NterhweWtgdRvf/f7aaoOUUxVZM8wMIXzazrZ7CxyeA==} engines: {node: '>=12.13.0'} + requiresBuild: true peerDependencies: tailwindcss: ^3.3.2 dependencies: @@ -16511,7 +16567,7 @@ packages: micromatch: 4.0.5 normalize-path: 3.0.0 schema-utils: 3.3.0 - webpack: 5.89.0(esbuild@0.19.11) + webpack: 5.89.0(@swc/core@1.3.102) /eslint@7.32.0: resolution: {integrity: sha512-VHZ8gX+EDfz+97jGcgyGCyRia/dPOd6Xh9yPv8Bl1+SoaIwD+a/vlrOmGRUyOYu7MwUhc7CxqeaDZU13S4+EpA==} @@ -17178,7 +17234,7 @@ packages: dependencies: loader-utils: 2.0.4 schema-utils: 3.3.0 - webpack: 5.89.0(esbuild@0.19.11) + webpack: 5.89.0(@swc/core@1.3.102) /file-system-cache@2.3.0: resolution: {integrity: sha512-l4DMNdsIPsVnKrgEXbJwDJsA5mB8rGwHYERMgqQx/xAUtChPJMre1bXBzDEqqVbWv9AIbFezXMxeEkZDSrXUOQ==} @@ -17534,7 +17590,7 @@ packages: semver: 7.5.4 tapable: 1.1.3 typescript: 5.3.3 - webpack: 5.89.0(esbuild@0.19.11) + webpack: 5.89.0(@swc/core@1.3.102) /form-data-encoder@2.1.4: resolution: {integrity: sha512-yDYSgNMraqvnxiEXO4hi88+YZxaHC6QKzb5N84iRCTDeRO7ZALpir/lVmf/uXUhnwUr2O4HU8s/n6x+yNjQkHw==} @@ -17801,7 +17857,7 @@ packages: dependencies: '@types/node-fetch': 2.6.10 fs-extra: 9.1.0 - gatsby: 5.13.1(babel-eslint@10.1.0)(esbuild@0.19.11)(react-dom@18.2.0)(react@18.2.0)(typescript@5.3.3) + gatsby: 5.13.1(@swc/core@1.3.102)(babel-eslint@10.1.0)(react-dom@18.2.0)(react@18.2.0)(typescript@5.3.3) lodash: 4.17.21 node-fetch: 2.7.0 p-queue: 6.6.2 @@ -17917,7 +17973,7 @@ packages: chokidar: 3.5.3 fs-exists-cached: 1.0.0 fs-extra: 11.2.0 - gatsby: 5.13.1(babel-eslint@10.1.0)(esbuild@0.19.11)(react-dom@18.2.0)(react@18.2.0)(typescript@5.3.3) + gatsby: 5.13.1(@swc/core@1.3.102)(babel-eslint@10.1.0)(react-dom@18.2.0)(react@18.2.0)(typescript@5.3.3) gatsby-core-utils: 4.13.0 gatsby-page-utils: 3.13.0 gatsby-plugin-utils: 4.13.0(gatsby@5.13.1)(graphql@16.8.1) @@ -18003,7 +18059,7 @@ packages: '@babel/preset-typescript': 7.23.3(@babel/core@7.23.7) '@babel/runtime': 7.23.7 babel-plugin-remove-graphql-queries: 5.13.0(@babel/core@7.23.7)(gatsby@5.13.1) - gatsby: 5.13.1(babel-eslint@10.1.0)(esbuild@0.19.11)(react-dom@18.2.0)(react@18.2.0)(typescript@5.3.3) + gatsby: 5.13.1(@swc/core@1.3.102)(babel-eslint@10.1.0)(react-dom@18.2.0)(react@18.2.0)(typescript@5.3.3) transitivePeerDependencies: - supports-color @@ -18017,7 +18073,7 @@ packages: '@babel/runtime': 7.23.7 fastq: 1.16.0 fs-extra: 11.2.0 - gatsby: 5.13.1(babel-eslint@10.1.0)(esbuild@0.19.11)(react-dom@18.2.0)(react@18.2.0)(typescript@5.3.3) + gatsby: 5.13.1(@swc/core@1.3.102)(babel-eslint@10.1.0)(react-dom@18.2.0)(react@18.2.0)(typescript@5.3.3) gatsby-core-utils: 4.13.0 gatsby-sharp: 1.13.0 graphql: 16.8.1 @@ -18107,7 +18163,7 @@ packages: transitivePeerDependencies: - supports-color - /gatsby@5.13.1(babel-eslint@10.1.0)(esbuild@0.19.11)(react-dom@18.2.0)(react@18.2.0)(typescript@5.3.3): + /gatsby@5.13.1(@swc/core@1.3.102)(babel-eslint@10.1.0)(react-dom@18.2.0)(react@18.2.0)(typescript@5.3.3): resolution: {integrity: sha512-y8VB381ZnHX3Xxc1n78AAAd+t0EsIyyIRtfqlSQ10CXwZHpZzBR3DTRoHmqIG3/NmdiqWhbHb/nRlmKZUzixtQ==} engines: {node: '>=18.0.0'} hasBin: true @@ -18272,13 +18328,13 @@ packages: strip-ansi: 6.0.1 style-loader: 2.0.0(webpack@5.89.0) style-to-object: 0.4.4 - terser-webpack-plugin: 5.3.10(esbuild@0.19.11)(webpack@5.89.0) + terser-webpack-plugin: 5.3.10(@swc/core@1.3.102)(webpack@5.89.0) tmp: 0.2.1 true-case-path: 2.2.1 type-of: 2.0.1 url-loader: 4.1.1(file-loader@6.2.0)(webpack@5.89.0) uuid: 8.3.2 - webpack: 5.89.0(esbuild@0.19.11) + webpack: 5.89.0(@swc/core@1.3.102) webpack-dev-middleware: 4.3.0(webpack@5.89.0) webpack-merge: 5.10.0 webpack-stats-plugin: 1.1.3 @@ -19269,7 +19325,6 @@ packages: - encoding - typescript - utf-8-validate - dev: true /graphql-http@1.22.0(graphql@16.8.1): resolution: {integrity: sha512-9RBUlGJWBFqz9LwfpmAbjJL/8j/HCNkZwPBU5+Bfmwez+1Ay43DocMNQYpIWsWqH0Ftv6PTNAh2aRnnMCBJgLw==} @@ -20095,7 +20150,6 @@ packages: hasBin: true dependencies: queue: 6.0.2 - dev: false /imagetools-core@6.0.4: resolution: {integrity: sha512-N1qs5qn7u9nR3kboISkYuvJm8MohiphCfBa+wx1UOropVaFis9/mh6wuDPLHJNhl6/64C7q2Pch5NASVKAaSrg==} @@ -23322,7 +23376,7 @@ packages: dependencies: loader-utils: 2.0.4 schema-utils: 3.3.0 - webpack: 5.89.0(esbuild@0.19.11) + webpack: 5.89.0(@swc/core@1.3.102) webpack-sources: 1.4.3 /mini-svg-data-uri@1.4.4: @@ -24155,7 +24209,7 @@ packages: dependencies: loader-utils: 2.0.4 schema-utils: 3.3.0 - webpack: 5.89.0(esbuild@0.19.11) + webpack: 5.89.0(@swc/core@1.3.102) /nullthrows@1.1.1: resolution: {integrity: sha512-2vPPEi+Z7WqML2jZYddDIfy5Dqb0r2fze2zTxNNknZaFpVHU3mFB3R+DWeJWGVx0ecvttSGlJTI+WG+8Z4cDWw==} @@ -25305,22 +25359,6 @@ packages: camelcase-css: 2.0.1 postcss: 8.4.32 - /postcss-load-config@4.0.2: - resolution: {integrity: sha512-bSVhyJGL00wMVoPUzAVAnbEoWyqRxkjv64tUl427SKnPrENtq6hJwUojroMz2VB+Q1edmi4IfrAPpami5VVgMQ==} - engines: {node: '>= 14'} - peerDependencies: - postcss: '>=8.0.9' - ts-node: '>=9.0.0' - peerDependenciesMeta: - postcss: - optional: true - ts-node: - optional: true - dependencies: - lilconfig: 3.0.0 - yaml: 2.3.4 - dev: true - /postcss-load-config@4.0.2(postcss@8.4.32): resolution: {integrity: sha512-bSVhyJGL00wMVoPUzAVAnbEoWyqRxkjv64tUl427SKnPrENtq6hJwUojroMz2VB+Q1edmi4IfrAPpami5VVgMQ==} engines: {node: '>= 14'} @@ -25365,7 +25403,7 @@ packages: klona: 2.0.6 postcss: 8.4.32 semver: 7.5.4 - webpack: 5.89.0(esbuild@0.19.11) + webpack: 5.89.0(@swc/core@1.3.102) /postcss-merge-longhand@5.1.7(postcss@8.4.32): resolution: {integrity: sha512-YCI9gZB+PLNskrK0BB3/2OzPnGhPkBEwmwhfYk1ilBHYVAZB7/tkTHFBAnCrvBBOmeYyMYw3DMjT55SyxMBzjQ==} @@ -26268,7 +26306,6 @@ packages: resolution: {integrity: sha512-iHZWu+q3IdFZFX36ro/lKBkSvfkztY5Y7HMiPlOUjhupPcG2JMfst2KKEpu5XndviX/3UhFbRngUPNKtgvtZiA==} dependencies: inherits: 2.0.4 - dev: false /quick-format-unescaped@4.0.4: resolution: {integrity: sha512-tYC1Q1hgyRuHgloV/YXs2w15unPVh8qfu/qCTfhTYamaw7fyhumKa2yGpdSo87vY32rIclj+4fWYQXUMs9EHvg==} @@ -26343,7 +26380,7 @@ packages: dependencies: loader-utils: 2.0.4 schema-utils: 3.3.0 - webpack: 5.89.0(esbuild@0.19.11) + webpack: 5.89.0(@swc/core@1.3.102) /rbush@3.0.1: resolution: {integrity: sha512-XRaVO0YecOpEuIvbhbpTrZgoiI6xBlz6hnlr6EHhd+0x9ase6EmeN+hdwwUaJvLcsFFQ8iWVF1GAK1yB0BWi0w==} @@ -26517,7 +26554,7 @@ packages: strip-ansi: 6.0.1 text-table: 0.2.0 typescript: 5.3.3 - webpack: 5.89.0(esbuild@0.19.11) + webpack: 5.89.0(@swc/core@1.3.102) transitivePeerDependencies: - eslint - supports-color @@ -26923,7 +26960,7 @@ packages: loose-envify: 1.4.0 neo-async: 2.6.2 react: 18.2.0 - webpack: 5.89.0(esbuild@0.19.11) + webpack: 5.89.0(@swc/core@1.3.102) /react-split-pane@0.1.92(react-dom@18.2.0)(react@18.2.0): resolution: {integrity: sha512-GfXP1xSzLMcLJI5BM36Vh7GgZBpy+U/X0no+VM3fxayv+p1Jly5HpMofZJraeaMl73b3hvlr+N9zJKvLB/uz9w==} @@ -29278,7 +29315,7 @@ packages: dependencies: loader-utils: 2.0.4 schema-utils: 3.3.0 - webpack: 5.89.0(esbuild@0.19.11) + webpack: 5.89.0(@swc/core@1.3.102) /style-to-object@0.3.0: resolution: {integrity: sha512-CzFnRRXhzWIdItT3OmF8SQfWyahHhjq3HwcMNCNLn+N7klOOqPjMeG/4JSu77D7ypZdGvSzvkrbyeTMizz2VrA==} @@ -29589,7 +29626,7 @@ packages: ps-tree: 1.2.0 dev: false - /terser-webpack-plugin@5.3.10(esbuild@0.19.11)(webpack@5.89.0): + /terser-webpack-plugin@5.3.10(@swc/core@1.3.102)(webpack@5.89.0): resolution: {integrity: sha512-BKFPWlPDndPs+NGGCr1U59t0XScL5317Y0UReNrHaw9/FwhPENlq6bfgs+4yPfyP51vqC1bQ4rp1EfXW5ZSH9w==} engines: {node: '>= 10.13.0'} peerDependencies: @@ -29606,12 +29643,12 @@ packages: optional: true dependencies: '@jridgewell/trace-mapping': 0.3.20 - esbuild: 0.19.11 + '@swc/core': 1.3.102 jest-worker: 27.5.1 schema-utils: 3.3.0 serialize-javascript: 6.0.1 terser: 5.26.0 - webpack: 5.89.0(esbuild@0.19.11) + webpack: 5.89.0(@swc/core@1.3.102) /terser-webpack-plugin@5.3.10(webpack@5.89.0): resolution: {integrity: sha512-BKFPWlPDndPs+NGGCr1U59t0XScL5317Y0UReNrHaw9/FwhPENlq6bfgs+4yPfyP51vqC1bQ4rp1EfXW5ZSH9w==} @@ -30055,7 +30092,7 @@ packages: /tslib@2.6.2: resolution: {integrity: sha512-AEYxH93jGFPn/a2iVAwW87VuUIkR1FVUKB77NwMF7nBTDkDrrT/Hpt/IrCJ0QXhW27jTBDcf5ZY7w6RiqTMw2Q==} - /tsup@8.0.1(typescript@5.3.3): + /tsup@8.0.1(postcss@8.4.32)(typescript@5.3.3): resolution: {integrity: sha512-hvW7gUSG96j53ZTSlT4j/KL0q1Q2l6TqGBFc6/mu/L46IoNWqLLUzLRLP1R8Q7xrJTmkDxxDoojV5uCVs1sVOg==} engines: {node: '>=18'} hasBin: true @@ -30082,7 +30119,8 @@ packages: execa: 5.1.1 globby: 11.1.0 joycon: 3.1.1 - postcss-load-config: 4.0.2 + postcss: 8.4.32 + postcss-load-config: 4.0.2(postcss@8.4.32) resolve-from: 5.0.0 rollup: 4.9.2 source-map: 0.8.0-beta.0 @@ -30802,7 +30840,7 @@ packages: loader-utils: 2.0.4 mime-types: 2.1.35 schema-utils: 3.3.0 - webpack: 5.89.0(esbuild@0.19.11) + webpack: 5.89.0(@swc/core@1.3.102) /url@0.11.3: resolution: {integrity: sha512-6hxOLGfZASQK/cijlZnZJTq8OXAkt/3YGfQX45vvMYXpZoo8NdWZcY73K108Jf759lS1Bv/8wXnHDTSz17dSRw==} @@ -31646,7 +31684,7 @@ packages: mime-types: 2.1.35 range-parser: 1.2.1 schema-utils: 3.3.0 - webpack: 5.89.0(esbuild@0.19.11) + webpack: 5.89.0(@swc/core@1.3.102) /webpack-merge@5.10.0: resolution: {integrity: sha512-+4zXKdx7UnO+1jaN4l2lHVD+mFvnlZQP/6ljaJVb4SZiwIKeUnrT5l0gkT8z+n4hKpC+jpOv6O9R+gLtag7pSA==} @@ -31715,7 +31753,7 @@ packages: - esbuild - uglify-js - /webpack@5.89.0(esbuild@0.19.11): + /webpack@5.89.0(@swc/core@1.3.102): resolution: {integrity: sha512-qyfIC10pOr70V+jkmud8tMfajraGCZMBWJtrmuBymQKCrLTRejBI8STDp1MCyZu/QTdZSeacCQYpYNQVOzX5kw==} engines: {node: '>=10.13.0'} hasBin: true @@ -31746,7 +31784,7 @@ packages: neo-async: 2.6.2 schema-utils: 3.3.0 tapable: 2.2.1 - terser-webpack-plugin: 5.3.10(esbuild@0.19.11)(webpack@5.89.0) + terser-webpack-plugin: 5.3.10(@swc/core@1.3.102)(webpack@5.89.0) watchpack: 2.4.0 webpack-sources: 3.2.3 transitivePeerDependencies: From ec503ef7211e9c30d811548e5d5f909c7b2af032 Mon Sep 17 00:00:00 2001 From: Philipp Melab Date: Wed, 24 Jan 2024 08:58:13 +0100 Subject: [PATCH 09/15] refactor(SLB-201): remove unused import --- packages/gatsby-plugin-static-dirs/gatsby-node.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/packages/gatsby-plugin-static-dirs/gatsby-node.js b/packages/gatsby-plugin-static-dirs/gatsby-node.js index 9cdb8a77b..d98c739aa 100644 --- a/packages/gatsby-plugin-static-dirs/gatsby-node.js +++ b/packages/gatsby-plugin-static-dirs/gatsby-node.js @@ -1,4 +1,4 @@ -import { cpSync, rmSync } from 'fs'; +import { cpSync } from 'fs'; import serve from 'serve-static'; /** From e4dccd209d93acbe89791f80f3f9bed95f6197a1 Mon Sep 17 00:00:00 2001 From: Philipp Melab Date: Wed, 24 Jan 2024 09:07:13 +0100 Subject: [PATCH 10/15] fix(SLB-201): add cache buster to styles.css --- apps/website/gatsby-ssr.ts | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/apps/website/gatsby-ssr.ts b/apps/website/gatsby-ssr.ts index 60803e9c6..eeeec5a23 100644 --- a/apps/website/gatsby-ssr.ts +++ b/apps/website/gatsby-ssr.ts @@ -31,7 +31,7 @@ export const onRenderBody: GatsbySSR['onRenderBody'] = ({ React.createElement('link', { key: 'styles.css', rel: 'stylesheet', - href: '/styles.css', + href: `/styles.css?t=${new Date().getTime()}`, }), ]); }; From 0982592e5686e0f98c7aa745d807ef545f06f71e Mon Sep 17 00:00:00 2001 From: Philipp Melab Date: Wed, 24 Jan 2024 10:04:44 +0100 Subject: [PATCH 11/15] fix(SLB-201): switch back to standard style handling Otherwise we loose proper cache handling by webpack. --- apps/website/gatsby-browser.ts | 2 ++ apps/website/gatsby-ssr.ts | 9 --------- packages/gatsby-plugin-static-dirs/gatsby-node.js | 4 ++-- 3 files changed, 4 insertions(+), 11 deletions(-) diff --git a/apps/website/gatsby-browser.ts b/apps/website/gatsby-browser.ts index e0a930c7f..a1021fe1e 100644 --- a/apps/website/gatsby-browser.ts +++ b/apps/website/gatsby-browser.ts @@ -1,3 +1,5 @@ +import './node_modules/@custom/ui/build/styles.css'; + import { registerExecutor } from '@custom/schema'; import { GatsbyBrowser } from 'gatsby'; diff --git a/apps/website/gatsby-ssr.ts b/apps/website/gatsby-ssr.ts index eeeec5a23..367db03f6 100644 --- a/apps/website/gatsby-ssr.ts +++ b/apps/website/gatsby-ssr.ts @@ -1,12 +1,10 @@ import { Locale, registerExecutor } from '@custom/schema'; import { GatsbySSR } from 'gatsby'; -import React from 'react'; import { drupalExecutor } from './src/utils/drupal-executor'; export const onRenderBody: GatsbySSR['onRenderBody'] = ({ setHtmlAttributes, - setHeadComponents, pathname, }) => { registerExecutor(drupalExecutor(`/graphql`)); @@ -27,11 +25,4 @@ export const onRenderBody: GatsbySSR['onRenderBody'] = ({ // We don't know the language. } } - setHeadComponents([ - React.createElement('link', { - key: 'styles.css', - rel: 'stylesheet', - href: `/styles.css?t=${new Date().getTime()}`, - }), - ]); }; diff --git a/packages/gatsby-plugin-static-dirs/gatsby-node.js b/packages/gatsby-plugin-static-dirs/gatsby-node.js index d98c739aa..36ee6f25b 100644 --- a/packages/gatsby-plugin-static-dirs/gatsby-node.js +++ b/packages/gatsby-plugin-static-dirs/gatsby-node.js @@ -11,9 +11,9 @@ export const pluginOptionsSchema = ({ Joi }) => { }; /** - * @type {import('gatsby').GatsbyNode['onPostBuild']} + * @type {import('gatsby').GatsbyNode['onPreBuild']} */ -export const onPostBuild = (_, options) => { +export const onPreBuild = (_, options) => { Object.keys(options.directories).forEach((src) => { const dest = options.directories[src]; cpSync(src, `public${dest}`, { From ad891927a28b43c008b2a6e1034bf0334c3a81a2 Mon Sep 17 00:00:00 2001 From: Philipp Melab Date: Wed, 24 Jan 2024 11:13:10 +0100 Subject: [PATCH 12/15] fix(SLB-201): properly export stylesheet from ui package --- apps/website/gatsby-browser.ts | 2 +- packages/ui/package.json | 7 ++++++- 2 files changed, 7 insertions(+), 2 deletions(-) diff --git a/apps/website/gatsby-browser.ts b/apps/website/gatsby-browser.ts index a1021fe1e..176e43b2b 100644 --- a/apps/website/gatsby-browser.ts +++ b/apps/website/gatsby-browser.ts @@ -1,4 +1,4 @@ -import './node_modules/@custom/ui/build/styles.css'; +import '@custom/ui/styles.css'; import { registerExecutor } from '@custom/schema'; import { GatsbyBrowser } from 'gatsby'; diff --git a/packages/ui/package.json b/packages/ui/package.json index 909721523..fa0664dc2 100644 --- a/packages/ui/package.json +++ b/packages/ui/package.json @@ -3,13 +3,18 @@ "private": true, "version": "1.0.0", "type": "module", - "sideEffects": false, + "sideEffects": [ + "styles.css" + ], "exports": { "./intl": [ "./build/utils/intl/index.js" ], "./routes/*": [ "./build/components/Routes/*.js" + ], + "./styles.css": [ + "./build/styles.css" ] }, "typesVersions": { From 24b7d3d2694d0333b1605c35327312d3024edf80 Mon Sep 17 00:00:00 2001 From: Philipp Melab Date: Wed, 24 Jan 2024 11:20:22 +0100 Subject: [PATCH 13/15] fix(SLB-201): add tailwind settings to postcss To avoid a warning in Gatsby, which runs the file trough PostCSS again. It shouldn't do that, but there is no way to stop it. --- packages/ui/postcss.config.cjs | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/packages/ui/postcss.config.cjs b/packages/ui/postcss.config.cjs index 4cd183892..c1c15e247 100644 --- a/packages/ui/postcss.config.cjs +++ b/packages/ui/postcss.config.cjs @@ -2,7 +2,7 @@ module.exports = { plugins: { 'postcss-import-ext-glob': {}, 'postcss-import': {}, - tailwindcss: {}, + tailwindcss: require('./tailwind.config.cjs'), autoprefixer: {}, 'postcss-prefix-selector': { prefix: From 3ec3d20fa0a0c8910ff5791a513855ef68a9d9dd Mon Sep 17 00:00:00 2001 From: Philipp Melab Date: Wed, 24 Jan 2024 11:22:56 +0100 Subject: [PATCH 14/15] perf(SLB-201): un-inline gatsby styles Gatsby's style handling assumes every component has its own stylesheet, and it would add only the required styles to each page. With Tailwind though, we have only one global stylesheet, and adding it inline everywhere achieves the opposite. --- apps/website/gatsby-config.mjs | 1 + apps/website/package.json | 1 + pnpm-lock.yaml | 271 ++++----------------------------- 3 files changed, 35 insertions(+), 238 deletions(-) diff --git a/apps/website/gatsby-config.mjs b/apps/website/gatsby-config.mjs index dd32b3d5b..4842dcda6 100644 --- a/apps/website/gatsby-config.mjs +++ b/apps/website/gatsby-config.mjs @@ -38,6 +38,7 @@ export default { siteUrl: process.env.NETLIFY_URL, }, plugins: [ + 'gatsby-plugin-uninline-styles', 'gatsby-plugin-pnpm', 'gatsby-plugin-layout', 'gatsby-plugin-sharp', diff --git a/apps/website/package.json b/apps/website/package.json index a24e8a2f1..a2ecbd7a1 100644 --- a/apps/website/package.json +++ b/apps/website/package.json @@ -20,6 +20,7 @@ "gatsby-plugin-robots-txt": "^1.8.0", "gatsby-plugin-sharp": "^5.13.0", "gatsby-plugin-sitemap": "^6.13.0", + "gatsby-plugin-uninline-styles": "^0.2.0", "gatsby-source-filesystem": "^5.13.0", "image-size": "^1.1.1", "mime-types": "^2.1.35", diff --git a/pnpm-lock.yaml b/pnpm-lock.yaml index 6f163dbcc..f4a2b672c 100644 --- a/pnpm-lock.yaml +++ b/pnpm-lock.yaml @@ -230,6 +230,9 @@ importers: gatsby-plugin-sitemap: specifier: ^6.13.0 version: 6.13.0(gatsby@5.13.1)(react-dom@18.2.0)(react@18.2.0) + gatsby-plugin-uninline-styles: + specifier: ^0.2.0 + version: 0.2.0 gatsby-source-filesystem: specifier: ^5.13.0 version: 5.13.0(gatsby@5.13.1) @@ -7345,7 +7348,7 @@ packages: react-refresh: 0.14.0 schema-utils: 3.3.0 source-map: 0.7.4 - webpack: 5.89.0(@swc/core@1.3.102) + webpack: 5.89.0 /@pnpm/config.env-replace@1.1.0: resolution: {integrity: sha512-htyl8TWnKL7K/ESFa1oW2UB5lVDxuF5DpM7tBi6Hu2LNL3mWkIzNLG6N4zoCUP1lCKNxWy/3iu8mS8MvToGd6w==} @@ -10015,7 +10018,6 @@ packages: typescript: 4.9.5 transitivePeerDependencies: - supports-color - dev: false /@typescript-eslint/eslint-plugin@5.62.0(@typescript-eslint/parser@5.62.0)(eslint@7.32.0)(typescript@5.3.3): resolution: {integrity: sha512-TiZzBSJja/LbhNPvk6yc0JrX9XqhQ0hdh6M2svYfsHGejaKFIAGd9MQ+ERIMzLGlN/kZoYIgdxFV0PuljTKXag==} @@ -10092,7 +10094,6 @@ packages: typescript: 4.9.5 transitivePeerDependencies: - supports-color - dev: false /@typescript-eslint/parser@5.62.0(eslint@7.32.0)(typescript@5.3.3): resolution: {integrity: sha512-VlJEV0fOQ7BExOsHYAGrgbEiZoi8D+Bl2+f6V2RrXerRSylnp+ZBHmPvaIa8cz0Ajx7WO7Z5RqfgYg7ED1nRhA==} @@ -10169,7 +10170,6 @@ packages: typescript: 4.9.5 transitivePeerDependencies: - supports-color - dev: false /@typescript-eslint/type-utils@5.62.0(eslint@7.32.0)(typescript@5.3.3): resolution: {integrity: sha512-xsSQreu+VnfbqQpW5vnCJdq1Z3Q0U31qiWmRhr98ONQmcp/yhiPJFPq8MXiJVLiksmOKSjIldZzkebzHuCGzew==} @@ -10261,12 +10261,10 @@ packages: typescript: 4.9.5 transitivePeerDependencies: - supports-color - dev: false /@typescript-eslint/typescript-estree@5.62.0(typescript@5.3.3): resolution: {integrity: sha512-CmcQ6uY7b9y694lKdRB8FEel7JbU/40iSAPomu++SjLMntB+2Leay2LO6i8VnJk58MtE9/nQSFIH6jpyRWyYzA==} engines: {node: ^12.22.0 || ^14.17.0 || >=16.0.0} - requiresBuild: true peerDependencies: typescript: '*' peerDependenciesMeta: @@ -10324,7 +10322,6 @@ packages: transitivePeerDependencies: - supports-color - typescript - dev: false /@typescript-eslint/utils@5.62.0(eslint@7.32.0)(typescript@5.3.3): resolution: {integrity: sha512-n8oxjeb5aIbPFEtmQxQYOLI0i9n5ySBEY/ZEHHZqKQSFnxio1rv6dthascc9dLuwrL0RC5mPCxB7vnAVGAYWAQ==} @@ -12119,7 +12116,7 @@ packages: loader-utils: 2.0.4 make-dir: 3.1.0 schema-utils: 2.7.1 - webpack: 5.89.0(@swc/core@1.3.102) + webpack: 5.89.0 /babel-plugin-add-module-exports@1.0.4: resolution: {integrity: sha512-g+8yxHUZ60RcyaUpfNzy56OtWW+x9cyEe9j+CranqLiqbju2yf/Cy6ZtYK40EZxtrdHllzlVZgLmcOUCTlJ7Jg==} @@ -12212,7 +12209,7 @@ packages: '@babel/core': 7.23.7 '@babel/runtime': 7.23.7 '@babel/types': 7.23.6 - gatsby: 5.13.1(@swc/core@1.3.102)(babel-eslint@10.1.0)(react-dom@18.2.0)(react@18.2.0)(typescript@5.3.3) + gatsby: 5.13.1(babel-eslint@10.1.0)(react-dom@18.2.0)(react@18.2.0)(typescript@4.9.5) gatsby-core-utils: 4.13.0 /babel-plugin-syntax-trailing-function-commas@7.0.0-beta.0: @@ -13955,7 +13952,7 @@ packages: postcss-value-parser: 4.2.0 schema-utils: 3.3.0 semver: 7.5.4 - webpack: 5.89.0(@swc/core@1.3.102) + webpack: 5.89.0 /css-minimizer-webpack-plugin@2.0.0(webpack@5.89.0): resolution: {integrity: sha512-cG/uc94727tx5pBNtb1Sd7gvUPzwmcQi1lkpfqTpdkuNq75hJCw7bIVsCNijLm4dhDcr1atvuysl2rZqOG8Txw==} @@ -13977,7 +13974,7 @@ packages: schema-utils: 3.3.0 serialize-javascript: 5.0.1 source-map: 0.6.1 - webpack: 5.89.0(@swc/core@1.3.102) + webpack: 5.89.0 /css-select@4.3.0: resolution: {integrity: sha512-wPpOYtnsVontu2mODhA19JrqWxNsfdatRKd64kmpRbQgh1KtItko5sTnEpPdpSaJszTOhEMlF/RPz28qj4HqhQ==} @@ -16215,7 +16212,6 @@ packages: eslint-plugin-react: 7.33.2(eslint@7.32.0) eslint-plugin-react-hooks: 4.6.0(eslint@7.32.0) typescript: 4.9.5 - dev: false /eslint-config-react-app@6.0.0(@typescript-eslint/eslint-plugin@5.62.0)(@typescript-eslint/parser@5.62.0)(babel-eslint@10.1.0)(eslint-plugin-flowtype@5.10.0)(eslint-plugin-import@2.29.1)(eslint-plugin-jsx-a11y@6.8.0)(eslint-plugin-react-hooks@4.6.0)(eslint-plugin-react@7.33.2)(eslint@7.32.0)(typescript@5.3.3): resolution: {integrity: sha512-bpoAAC+YRfzq0dsTk+6v9aHm/uqnDwayNAXleMypGl6CpxI9oXXscVHo4fk3eJPIn+rsbtNetB4r/ZIidFIE8A==} @@ -16252,6 +16248,7 @@ packages: eslint-plugin-react: 7.33.2(eslint@7.32.0) eslint-plugin-react-hooks: 4.6.0(eslint@7.32.0) typescript: 5.3.3 + dev: true /eslint-import-resolver-node@0.3.9: resolution: {integrity: sha512-WFj2isz22JahUv+B788TlO3N6zL3nNJGU8CcZbPZvVEkBPaJdCV4vy5wyghty5ROFbCRnm132v8BScu5/1BQ8g==} @@ -16283,7 +16280,7 @@ packages: eslint-import-resolver-webpack: optional: true dependencies: - '@typescript-eslint/parser': 5.62.0(eslint@7.32.0)(typescript@5.3.3) + '@typescript-eslint/parser': 5.62.0(eslint@7.32.0)(typescript@4.9.5) debug: 3.2.7 eslint: 7.32.0 eslint-import-resolver-node: 0.3.9 @@ -16361,7 +16358,7 @@ packages: '@typescript-eslint/parser': optional: true dependencies: - '@typescript-eslint/parser': 5.62.0(eslint@7.32.0)(typescript@5.3.3) + '@typescript-eslint/parser': 5.62.0(eslint@7.32.0)(typescript@4.9.5) array-includes: 3.1.7 array.prototype.findlastindex: 1.2.3 array.prototype.flat: 1.3.2 @@ -16567,7 +16564,7 @@ packages: micromatch: 4.0.5 normalize-path: 3.0.0 schema-utils: 3.3.0 - webpack: 5.89.0(@swc/core@1.3.102) + webpack: 5.89.0 /eslint@7.32.0: resolution: {integrity: sha512-VHZ8gX+EDfz+97jGcgyGCyRia/dPOd6Xh9yPv8Bl1+SoaIwD+a/vlrOmGRUyOYu7MwUhc7CxqeaDZU13S4+EpA==} @@ -17234,7 +17231,7 @@ packages: dependencies: loader-utils: 2.0.4 schema-utils: 3.3.0 - webpack: 5.89.0(@swc/core@1.3.102) + webpack: 5.89.0 /file-system-cache@2.3.0: resolution: {integrity: sha512-l4DMNdsIPsVnKrgEXbJwDJsA5mB8rGwHYERMgqQx/xAUtChPJMre1bXBzDEqqVbWv9AIbFezXMxeEkZDSrXUOQ==} @@ -17559,7 +17556,6 @@ packages: tapable: 1.1.3 typescript: 4.9.5 webpack: 5.89.0 - dev: false /fork-ts-checker-webpack-plugin@6.5.3(eslint@7.32.0)(typescript@5.3.3)(webpack@5.89.0): resolution: {integrity: sha512-SbH/l9ikmMWycd5puHJKTkZJKddF4iRLyW3DeZ08HTI7NGyLS38MXd/KGgeWumQO7YNQbW2u/NtPT2YowbPaGQ==} @@ -17591,6 +17587,7 @@ packages: tapable: 1.1.3 typescript: 5.3.3 webpack: 5.89.0(@swc/core@1.3.102) + dev: true /form-data-encoder@2.1.4: resolution: {integrity: sha512-yDYSgNMraqvnxiEXO4hi88+YZxaHC6QKzb5N84iRCTDeRO7ZALpir/lVmf/uXUhnwUr2O4HU8s/n6x+yNjQkHw==} @@ -17857,7 +17854,7 @@ packages: dependencies: '@types/node-fetch': 2.6.10 fs-extra: 9.1.0 - gatsby: 5.13.1(@swc/core@1.3.102)(babel-eslint@10.1.0)(react-dom@18.2.0)(react@18.2.0)(typescript@5.3.3) + gatsby: 5.13.1(babel-eslint@10.1.0)(react-dom@18.2.0)(react@18.2.0)(typescript@4.9.5) lodash: 4.17.21 node-fetch: 2.7.0 p-queue: 6.6.2 @@ -17973,7 +17970,7 @@ packages: chokidar: 3.5.3 fs-exists-cached: 1.0.0 fs-extra: 11.2.0 - gatsby: 5.13.1(@swc/core@1.3.102)(babel-eslint@10.1.0)(react-dom@18.2.0)(react@18.2.0)(typescript@5.3.3) + gatsby: 5.13.1(babel-eslint@10.1.0)(react-dom@18.2.0)(react@18.2.0)(typescript@4.9.5) gatsby-core-utils: 4.13.0 gatsby-page-utils: 3.13.0 gatsby-plugin-utils: 4.13.0(gatsby@5.13.1)(graphql@16.8.1) @@ -18059,10 +18056,14 @@ packages: '@babel/preset-typescript': 7.23.3(@babel/core@7.23.7) '@babel/runtime': 7.23.7 babel-plugin-remove-graphql-queries: 5.13.0(@babel/core@7.23.7)(gatsby@5.13.1) - gatsby: 5.13.1(@swc/core@1.3.102)(babel-eslint@10.1.0)(react-dom@18.2.0)(react@18.2.0)(typescript@5.3.3) + gatsby: 5.13.1(babel-eslint@10.1.0)(react-dom@18.2.0)(react@18.2.0)(typescript@4.9.5) transitivePeerDependencies: - supports-color + /gatsby-plugin-uninline-styles@0.2.0: + resolution: {integrity: sha512-qzG3gcmRk6Vgt6Yf7x6d6hlie+IpbmmXRC2z3A+PPweu/TNh3qpRd8DCQgWBL2rFSatiuxdhqUn4GWaOx7OTgA==} + dev: false + /gatsby-plugin-utils@4.13.0(gatsby@5.13.1)(graphql@16.8.1): resolution: {integrity: sha512-3qwhM6mUYjorRiD0D0cgmCHcKwroG2d4PlfErnapHJpM/ISGfdBBOfRhPyk2N0u3dbGeb3KQq5gImCCS73bvxg==} engines: {node: '>=18.0.0'} @@ -18073,7 +18074,7 @@ packages: '@babel/runtime': 7.23.7 fastq: 1.16.0 fs-extra: 11.2.0 - gatsby: 5.13.1(@swc/core@1.3.102)(babel-eslint@10.1.0)(react-dom@18.2.0)(react@18.2.0)(typescript@5.3.3) + gatsby: 5.13.1(babel-eslint@10.1.0)(react-dom@18.2.0)(react@18.2.0)(typescript@4.9.5) gatsby-core-utils: 4.13.0 gatsby-sharp: 1.13.0 graphql: 16.8.1 @@ -18163,211 +18164,6 @@ packages: transitivePeerDependencies: - supports-color - /gatsby@5.13.1(@swc/core@1.3.102)(babel-eslint@10.1.0)(react-dom@18.2.0)(react@18.2.0)(typescript@5.3.3): - resolution: {integrity: sha512-y8VB381ZnHX3Xxc1n78AAAd+t0EsIyyIRtfqlSQ10CXwZHpZzBR3DTRoHmqIG3/NmdiqWhbHb/nRlmKZUzixtQ==} - engines: {node: '>=18.0.0'} - hasBin: true - requiresBuild: true - peerDependencies: - react: ^18.0.0 || ^0.0.0 - react-dom: ^18.0.0 || ^0.0.0 - dependencies: - '@babel/code-frame': 7.23.5 - '@babel/core': 7.23.7 - '@babel/eslint-parser': 7.23.3(@babel/core@7.23.7)(eslint@7.32.0) - '@babel/helper-plugin-utils': 7.22.5 - '@babel/parser': 7.23.6 - '@babel/runtime': 7.23.7 - '@babel/traverse': 7.23.7 - '@babel/types': 7.23.6 - '@builder.io/partytown': 0.7.6 - '@gatsbyjs/reach-router': 2.0.1(react-dom@18.2.0)(react@18.2.0) - '@gatsbyjs/webpack-hot-middleware': 2.25.3 - '@graphql-codegen/add': 3.2.3(graphql@16.8.1) - '@graphql-codegen/core': 2.6.8(graphql@16.8.1) - '@graphql-codegen/plugin-helpers': 2.7.2(graphql@16.8.1) - '@graphql-codegen/typescript': 2.8.8(graphql@16.8.1) - '@graphql-codegen/typescript-operations': 2.5.13(graphql@16.8.1) - '@graphql-tools/code-file-loader': 7.3.23(@babel/core@7.23.7)(graphql@16.8.1) - '@graphql-tools/load': 7.8.14(graphql@16.8.1) - '@jridgewell/trace-mapping': 0.3.20 - '@nodelib/fs.walk': 1.2.8 - '@parcel/cache': 2.8.3(@parcel/core@2.8.3) - '@parcel/core': 2.8.3 - '@pmmmwh/react-refresh-webpack-plugin': 0.5.11(react-refresh@0.14.0)(webpack@5.89.0) - '@types/http-proxy': 1.17.14 - '@typescript-eslint/eslint-plugin': 5.62.0(@typescript-eslint/parser@5.62.0)(eslint@7.32.0)(typescript@5.3.3) - '@typescript-eslint/parser': 5.62.0(eslint@7.32.0)(typescript@5.3.3) - '@vercel/webpack-asset-relocator-loader': 1.7.3 - acorn-loose: 8.4.0 - acorn-walk: 8.3.1 - address: 1.2.2 - anser: 2.1.1 - autoprefixer: 10.4.16(postcss@8.4.32) - axios: 0.21.4(debug@4.3.4) - babel-jsx-utils: 1.1.0 - babel-loader: 8.3.0(@babel/core@7.23.7)(webpack@5.89.0) - babel-plugin-add-module-exports: 1.0.4 - babel-plugin-dynamic-import-node: 2.3.3 - babel-plugin-lodash: 3.3.4 - babel-plugin-remove-graphql-queries: 5.13.0(@babel/core@7.23.7)(gatsby@5.13.1) - babel-preset-gatsby: 3.13.0(@babel/core@7.23.7)(core-js@3.35.0) - better-opn: 2.1.1 - bluebird: 3.7.2 - body-parser: 1.20.1 - browserslist: 4.22.2 - cache-manager: 2.11.1 - chalk: 4.1.2 - chokidar: 3.5.3 - common-tags: 1.8.2 - compression: 1.7.4 - cookie: 0.5.0 - core-js: 3.35.0 - cors: 2.8.5 - css-loader: 5.2.7(webpack@5.89.0) - css-minimizer-webpack-plugin: 2.0.0(webpack@5.89.0) - css.escape: 1.5.1 - date-fns: 2.30.0 - debug: 4.3.4 - deepmerge: 4.3.1 - detect-port: 1.5.1 - devcert: 1.2.2 - dotenv: 8.6.0 - enhanced-resolve: 5.15.0 - error-stack-parser: 2.1.4 - eslint: 7.32.0 - eslint-config-react-app: 6.0.0(@typescript-eslint/eslint-plugin@5.62.0)(@typescript-eslint/parser@5.62.0)(babel-eslint@10.1.0)(eslint-plugin-flowtype@5.10.0)(eslint-plugin-import@2.29.1)(eslint-plugin-jsx-a11y@6.8.0)(eslint-plugin-react-hooks@4.6.0)(eslint-plugin-react@7.33.2)(eslint@7.32.0)(typescript@5.3.3) - eslint-plugin-flowtype: 5.10.0(eslint@7.32.0) - eslint-plugin-import: 2.29.1(@typescript-eslint/parser@5.62.0)(eslint@7.32.0) - eslint-plugin-jsx-a11y: 6.8.0(eslint@7.32.0) - eslint-plugin-react: 7.33.2(eslint@7.32.0) - eslint-plugin-react-hooks: 4.6.0(eslint@7.32.0) - eslint-webpack-plugin: 2.7.0(eslint@7.32.0)(webpack@5.89.0) - event-source-polyfill: 1.0.31 - execa: 5.1.1 - express: 4.18.2 - express-http-proxy: 1.6.3 - fastest-levenshtein: 1.0.16 - fastq: 1.16.0 - file-loader: 6.2.0(webpack@5.89.0) - find-cache-dir: 3.3.2 - fs-exists-cached: 1.0.0 - fs-extra: 11.2.0 - gatsby-cli: 5.13.1 - gatsby-core-utils: 4.13.0 - gatsby-graphiql-explorer: 3.13.0 - gatsby-legacy-polyfills: 3.13.0 - gatsby-link: 5.13.0(@gatsbyjs/reach-router@2.0.1)(react-dom@18.2.0)(react@18.2.0) - gatsby-page-utils: 3.13.0 - gatsby-parcel-config: 1.13.0(@parcel/core@2.8.3) - gatsby-plugin-page-creator: 5.13.0(gatsby@5.13.1)(graphql@16.8.1) - gatsby-plugin-typescript: 5.13.0(gatsby@5.13.1) - gatsby-plugin-utils: 4.13.0(gatsby@5.13.1)(graphql@16.8.1) - gatsby-react-router-scroll: 6.13.0(@gatsbyjs/reach-router@2.0.1)(react-dom@18.2.0)(react@18.2.0) - gatsby-script: 2.13.0(@gatsbyjs/reach-router@2.0.1)(react-dom@18.2.0)(react@18.2.0) - gatsby-telemetry: 4.13.0 - gatsby-worker: 2.13.0 - glob: 7.2.3 - globby: 11.1.0 - got: 11.8.6 - graphql: 16.8.1 - graphql-compose: 9.0.10(graphql@16.8.1) - graphql-http: 1.22.0(graphql@16.8.1) - graphql-tag: 2.12.6(graphql@16.8.1) - hasha: 5.2.2 - invariant: 2.2.4 - is-relative: 1.0.0 - is-relative-url: 3.0.0 - joi: 17.11.0 - json-loader: 0.5.7 - latest-version: 7.0.0 - linkfs: 2.1.0 - lmdb: 2.5.3 - lodash: 4.17.21 - meant: 1.0.3 - memoizee: 0.4.15 - micromatch: 4.0.5 - mime: 3.0.0 - mini-css-extract-plugin: 1.6.2(webpack@5.89.0) - mitt: 1.2.0 - moment: 2.30.1 - multer: 1.4.5-lts.1 - node-fetch: 2.7.0 - node-html-parser: 5.4.2 - normalize-path: 3.0.0 - null-loader: 4.0.1(webpack@5.89.0) - opentracing: 0.14.7 - p-defer: 3.0.0 - parseurl: 1.3.3 - path-to-regexp: 0.1.7 - physical-cpu-count: 2.0.0 - platform: 1.3.6 - postcss: 8.4.32 - postcss-flexbugs-fixes: 5.0.2(postcss@8.4.32) - postcss-loader: 5.3.0(postcss@8.4.32)(webpack@5.89.0) - prompts: 2.4.2 - prop-types: 15.8.1 - query-string: 6.14.1 - raw-loader: 4.0.2(webpack@5.89.0) - react: 18.2.0 - react-dev-utils: 12.0.1(eslint@7.32.0)(typescript@5.3.3)(webpack@5.89.0) - react-dom: 18.2.0(react@18.2.0) - react-refresh: 0.14.0 - react-server-dom-webpack: 0.0.0-experimental-c8b778b7f-20220825(react@18.2.0)(webpack@5.89.0) - redux: 4.2.1 - redux-thunk: 2.4.2(redux@4.2.1) - resolve-from: 5.0.0 - semver: 7.5.4 - shallow-compare: 1.2.2 - signal-exit: 3.0.7 - slugify: 1.6.6 - socket.io: 4.7.1 - socket.io-client: 4.7.1 - stack-trace: 0.0.10 - string-similarity: 1.2.2 - strip-ansi: 6.0.1 - style-loader: 2.0.0(webpack@5.89.0) - style-to-object: 0.4.4 - terser-webpack-plugin: 5.3.10(@swc/core@1.3.102)(webpack@5.89.0) - tmp: 0.2.1 - true-case-path: 2.2.1 - type-of: 2.0.1 - url-loader: 4.1.1(file-loader@6.2.0)(webpack@5.89.0) - uuid: 8.3.2 - webpack: 5.89.0(@swc/core@1.3.102) - webpack-dev-middleware: 4.3.0(webpack@5.89.0) - webpack-merge: 5.10.0 - webpack-stats-plugin: 1.1.3 - webpack-virtual-modules: 0.5.0 - xstate: 4.38.3 - yaml-loader: 0.8.0 - optionalDependencies: - gatsby-sharp: 1.13.0 - transitivePeerDependencies: - - '@swc/core' - - '@types/webpack' - - babel-eslint - - bufferutil - - clean-css - - csso - - encoding - - esbuild - - eslint-import-resolver-typescript - - eslint-import-resolver-webpack - - eslint-plugin-jest - - eslint-plugin-testing-library - - sockjs-client - - supports-color - - type-fest - - typescript - - uglify-js - - utf-8-validate - - vue-template-compiler - - webpack-cli - - webpack-dev-server - - webpack-hot-middleware - - webpack-plugin-serve - /gatsby@5.13.1(babel-eslint@10.1.0)(react-dom@18.2.0)(react@18.2.0)(typescript@4.9.5): resolution: {integrity: sha512-y8VB381ZnHX3Xxc1n78AAAd+t0EsIyyIRtfqlSQ10CXwZHpZzBR3DTRoHmqIG3/NmdiqWhbHb/nRlmKZUzixtQ==} engines: {node: '>=18.0.0'} @@ -18572,7 +18368,6 @@ packages: - webpack-dev-server - webpack-hot-middleware - webpack-plugin-serve - dev: false /gatsby@5.13.1(babel-eslint@10.1.0)(react-dom@18.2.0)(react@18.2.0)(typescript@5.3.3): resolution: {integrity: sha512-y8VB381ZnHX3Xxc1n78AAAd+t0EsIyyIRtfqlSQ10CXwZHpZzBR3DTRoHmqIG3/NmdiqWhbHb/nRlmKZUzixtQ==} @@ -23376,7 +23171,7 @@ packages: dependencies: loader-utils: 2.0.4 schema-utils: 3.3.0 - webpack: 5.89.0(@swc/core@1.3.102) + webpack: 5.89.0 webpack-sources: 1.4.3 /mini-svg-data-uri@1.4.4: @@ -24209,7 +24004,7 @@ packages: dependencies: loader-utils: 2.0.4 schema-utils: 3.3.0 - webpack: 5.89.0(@swc/core@1.3.102) + webpack: 5.89.0 /nullthrows@1.1.1: resolution: {integrity: sha512-2vPPEi+Z7WqML2jZYddDIfy5Dqb0r2fze2zTxNNknZaFpVHU3mFB3R+DWeJWGVx0ecvttSGlJTI+WG+8Z4cDWw==} @@ -25403,7 +25198,7 @@ packages: klona: 2.0.6 postcss: 8.4.32 semver: 7.5.4 - webpack: 5.89.0(@swc/core@1.3.102) + webpack: 5.89.0 /postcss-merge-longhand@5.1.7(postcss@8.4.32): resolution: {integrity: sha512-YCI9gZB+PLNskrK0BB3/2OzPnGhPkBEwmwhfYk1ilBHYVAZB7/tkTHFBAnCrvBBOmeYyMYw3DMjT55SyxMBzjQ==} @@ -26380,7 +26175,7 @@ packages: dependencies: loader-utils: 2.0.4 schema-utils: 3.3.0 - webpack: 5.89.0(@swc/core@1.3.102) + webpack: 5.89.0 /rbush@3.0.1: resolution: {integrity: sha512-XRaVO0YecOpEuIvbhbpTrZgoiI6xBlz6hnlr6EHhd+0x9ase6EmeN+hdwwUaJvLcsFFQ8iWVF1GAK1yB0BWi0w==} @@ -26517,7 +26312,6 @@ packages: - eslint - supports-color - vue-template-compiler - dev: false /react-dev-utils@12.0.1(eslint@7.32.0)(typescript@5.3.3)(webpack@5.89.0): resolution: {integrity: sha512-84Ivxmr17KjUupyqzFode6xKhjwuEJDROWKJy/BthkL7Wn6NJ8h4WE6k/exAv6ImS+0oZLRRW5j/aINMHyeGeQ==} @@ -26559,6 +26353,7 @@ packages: - eslint - supports-color - vue-template-compiler + dev: true /react-dnd-html5-backend@14.1.0: resolution: {integrity: sha512-6ONeqEC3XKVf4eVmMTe0oPds+c5B9Foyj8p/ZKLb7kL2qh9COYxiBHv3szd6gztqi/efkmriywLUVlPotqoJyw==} @@ -26960,7 +26755,7 @@ packages: loose-envify: 1.4.0 neo-async: 2.6.2 react: 18.2.0 - webpack: 5.89.0(@swc/core@1.3.102) + webpack: 5.89.0 /react-split-pane@0.1.92(react-dom@18.2.0)(react@18.2.0): resolution: {integrity: sha512-GfXP1xSzLMcLJI5BM36Vh7GgZBpy+U/X0no+VM3fxayv+p1Jly5HpMofZJraeaMl73b3hvlr+N9zJKvLB/uz9w==} @@ -29315,7 +29110,7 @@ packages: dependencies: loader-utils: 2.0.4 schema-utils: 3.3.0 - webpack: 5.89.0(@swc/core@1.3.102) + webpack: 5.89.0 /style-to-object@0.3.0: resolution: {integrity: sha512-CzFnRRXhzWIdItT3OmF8SQfWyahHhjq3HwcMNCNLn+N7klOOqPjMeG/4JSu77D7ypZdGvSzvkrbyeTMizz2VrA==} @@ -29649,6 +29444,7 @@ packages: serialize-javascript: 6.0.1 terser: 5.26.0 webpack: 5.89.0(@swc/core@1.3.102) + dev: true /terser-webpack-plugin@5.3.10(webpack@5.89.0): resolution: {integrity: sha512-BKFPWlPDndPs+NGGCr1U59t0XScL5317Y0UReNrHaw9/FwhPENlq6bfgs+4yPfyP51vqC1bQ4rp1EfXW5ZSH9w==} @@ -30141,7 +29937,6 @@ packages: dependencies: tslib: 1.14.1 typescript: 4.9.5 - dev: false /tsutils@3.21.0(typescript@5.3.3): resolution: {integrity: sha512-mHKK3iUXL+3UF6xL5k0PEhKRUBKPBCv/+RkEOpjRWxxx27KKRBmmA60A9pgOUvMi8GKhRMPEmjBRPzs2W7O1OA==} @@ -30340,7 +30135,6 @@ packages: resolution: {integrity: sha512-1FXk9E2Hm+QzZQ7z+McJiHL4NW1F2EzMu9Nq9i3zAaGqibafqYwCVU6WyWAuyQRRzOlxou8xZSyXLEN8oKj24g==} engines: {node: '>=4.2.0'} hasBin: true - dev: false /typescript@5.3.3: resolution: {integrity: sha512-pXWcraxM0uxAS+tN0AG/BF2TyqmHO014Z070UsJ+pFvYuRSq8KH8DmWpnbXe0pEPDHXZV3FcAbJkijJ5oNEnWw==} @@ -30840,7 +30634,7 @@ packages: loader-utils: 2.0.4 mime-types: 2.1.35 schema-utils: 3.3.0 - webpack: 5.89.0(@swc/core@1.3.102) + webpack: 5.89.0 /url@0.11.3: resolution: {integrity: sha512-6hxOLGfZASQK/cijlZnZJTq8OXAkt/3YGfQX45vvMYXpZoo8NdWZcY73K108Jf759lS1Bv/8wXnHDTSz17dSRw==} @@ -31684,7 +31478,7 @@ packages: mime-types: 2.1.35 range-parser: 1.2.1 schema-utils: 3.3.0 - webpack: 5.89.0(@swc/core@1.3.102) + webpack: 5.89.0 /webpack-merge@5.10.0: resolution: {integrity: sha512-+4zXKdx7UnO+1jaN4l2lHVD+mFvnlZQP/6ljaJVb4SZiwIKeUnrT5l0gkT8z+n4hKpC+jpOv6O9R+gLtag7pSA==} @@ -31791,6 +31585,7 @@ packages: - '@swc/core' - esbuild - uglify-js + dev: true /website-scraper@5.3.1: resolution: {integrity: sha512-gogqPXD2gVsxoyd2yRiympw3rA5GuEpD1CaDEJ/J8zzanx7hkbTtneoO1SGs436PpLbWVcUge+6APGLhzsuZPA==} From b044c6050f61ca1772d09dd0ac000b5489638c06 Mon Sep 17 00:00:00 2001 From: Philipp Melab Date: Wed, 24 Jan 2024 12:13:07 +0100 Subject: [PATCH 15/15] chore(SLB-201): use shared version of @amazeelabs/gatsby-plugin-static-dirs --- apps/website/package.json | 2 +- packages/gatsby-plugin-static-dirs/README.md | 20 ----------- .../gatsby-plugin-static-dirs/gatsby-node.js | 35 ------------------- .../gatsby-plugin-static-dirs/package.json | 20 ----------- .../gatsby-plugin-static-dirs/tsconfig.json | 5 --- pnpm-lock.yaml | 12 +++++-- 6 files changed, 11 insertions(+), 83 deletions(-) delete mode 100644 packages/gatsby-plugin-static-dirs/README.md delete mode 100644 packages/gatsby-plugin-static-dirs/gatsby-node.js delete mode 100644 packages/gatsby-plugin-static-dirs/package.json delete mode 100644 packages/gatsby-plugin-static-dirs/tsconfig.json diff --git a/apps/website/package.json b/apps/website/package.json index a2ecbd7a1..91ebb34d8 100644 --- a/apps/website/package.json +++ b/apps/website/package.json @@ -5,7 +5,7 @@ "@amazeelabs/bridge-gatsby": "^1.2.7", "@amazeelabs/cloudinary-responsive-image": "^1.6.15", "@amazeelabs/gatsby-plugin-operations": "^1.1.3", - "@amazeelabs/gatsby-plugin-static-dirs": "workspace:*", + "@amazeelabs/gatsby-plugin-static-dirs": "^1.0.1", "@amazeelabs/gatsby-source-silverback": "^1.13.10", "@amazeelabs/publisher": "^2.4.17", "@amazeelabs/strangler-netlify": "^1.1.9", diff --git a/packages/gatsby-plugin-static-dirs/README.md b/packages/gatsby-plugin-static-dirs/README.md deleted file mode 100644 index 310dd0185..000000000 --- a/packages/gatsby-plugin-static-dirs/README.md +++ /dev/null @@ -1,20 +0,0 @@ -# Static directories plugin - -Gatsby plugin for adding multiple static directories. It allows to map any -directory to a subdirectory of static assets. - -Configuration: - -```js -export const plugins = [ - { - resolve: '@amazeelabs/gatsby-plugin-static-dirs', - options: { - directories: { - 'some/root/assets': '/', - 'path/to/admin/app': '/admin', - }, - }, - }, -]; -``` diff --git a/packages/gatsby-plugin-static-dirs/gatsby-node.js b/packages/gatsby-plugin-static-dirs/gatsby-node.js deleted file mode 100644 index 36ee6f25b..000000000 --- a/packages/gatsby-plugin-static-dirs/gatsby-node.js +++ /dev/null @@ -1,35 +0,0 @@ -import { cpSync } from 'fs'; -import serve from 'serve-static'; - -/** - * @type {import('gatsby').GatsbyNode['pluginOptionsSchema']} - */ -export const pluginOptionsSchema = ({ Joi }) => { - return Joi.object({ - directories: Joi.object().pattern(Joi.string(), Joi.string()), - }); -}; - -/** - * @type {import('gatsby').GatsbyNode['onPreBuild']} - */ -export const onPreBuild = (_, options) => { - Object.keys(options.directories).forEach((src) => { - const dest = options.directories[src]; - cpSync(src, `public${dest}`, { - force: true, - recursive: true, - errorOnExist: false, - }); - }); -}; - -/** - * @type {import('gatsby').GatsbyNode['onCreateDevServer']} - */ -export const onCreateDevServer = ({ app }, options) => { - Object.keys(options.directories).forEach((src) => { - const dest = options.directories[src]; - app.use(dest, serve(src)); - }); -}; diff --git a/packages/gatsby-plugin-static-dirs/package.json b/packages/gatsby-plugin-static-dirs/package.json deleted file mode 100644 index 2fb16e940..000000000 --- a/packages/gatsby-plugin-static-dirs/package.json +++ /dev/null @@ -1,20 +0,0 @@ -{ - "name": "@amazeelabs/gatsby-plugin-static-dirs", - "version": "1.0.0", - "description": "", - "main": "gatsby-node.js", - "type": "module", - "scripts": { - "test": "tsc --noEmit" - }, - "keywords": [], - "author": "", - "license": "ISC", - "devDependencies": { - "gatsby": "^5.13.1", - "typescript": "^5.3.3" - }, - "dependencies": { - "serve-static": "^1.15.0" - } -} diff --git a/packages/gatsby-plugin-static-dirs/tsconfig.json b/packages/gatsby-plugin-static-dirs/tsconfig.json deleted file mode 100644 index 08ac60b6c..000000000 --- a/packages/gatsby-plugin-static-dirs/tsconfig.json +++ /dev/null @@ -1,5 +0,0 @@ -{ - "compilerOptions": { - "checkJs": true - } -} diff --git a/pnpm-lock.yaml b/pnpm-lock.yaml index f4a2b672c..ed4d5ed64 100644 --- a/pnpm-lock.yaml +++ b/pnpm-lock.yaml @@ -186,8 +186,8 @@ importers: specifier: ^1.1.3 version: 1.1.3 '@amazeelabs/gatsby-plugin-static-dirs': - specifier: workspace:* - version: link:../../packages/gatsby-plugin-static-dirs + specifier: ^1.0.1 + version: 1.0.1 '@amazeelabs/gatsby-source-silverback': specifier: ^1.13.10 version: 1.13.10(@types/node@18.19.4)(gatsby@5.13.1)(typescript@4.9.5) @@ -806,6 +806,14 @@ packages: - supports-color dev: false + /@amazeelabs/gatsby-plugin-static-dirs@1.0.1: + resolution: {integrity: sha512-G14E5Vdn6crri7Pq499gQIUd9LVlcRxMGJnGFApZy4tZxILyht/f3t5TOIF1a5L3ULwNcMLsONvfWlaQEAh1mg==} + dependencies: + serve-static: 1.15.0 + transitivePeerDependencies: + - supports-color + dev: false + /@amazeelabs/gatsby-silverback-cloudinary@1.2.7: resolution: {integrity: sha512-LUhtYau6zFZPTtE0hut0MmoTu4eFI9YUkiBNLHN02EsZlCrPrP0pdyWTqByGsL10WIvQ4bry0dPotKoqZVnx8g==} dev: false