From 62a6810bf8217a9b33a1c030666c5e6d98ab2169 Mon Sep 17 00:00:00 2001 From: Cody Olsen <81981+stipsan@users.noreply.github.com> Date: Tue, 9 Apr 2024 10:49:24 +0200 Subject: [PATCH] fix: upgrade to `@sanity/pkg-utils` v5 and use updated ESM best practices (#5983) MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit * fix: upgrade to `@sanity/pkg-utils` v5 and use updated ESM best practices * refactor: remove redundant `--tsconfig tsconfig.lib.json` cli arg * chore: use import that works in native ESM * chore: bump `@sanity/pkg-utils` * fix: lodash imports need to use `from 'lodash'` for rollup to be able to optimize it * chore(deps): bump nano-pubsub * chore: write to PKG_VERSION to give pre-releases their own version numbers * chore: run build as part of publish to use the correct PKG_VERSION * chore: bump tsdoc * chore: add prepublishOnly at root to speedup canary publishing * chore: fix path to `@sanity/vision` * chore: support types in `/examples` without first running `pnpm build` --------- Co-authored-by: Bjørge Næss --- .depcheckrc.json | 8 +- .eslintrc.cjs | 18 +- .github/workflows/cli-test.yml | 2 +- .github/workflows/docReport.yml | 2 +- .github/workflows/e2e-ct.yml | 2 +- .github/workflows/e2e.yml | 2 +- .github/workflows/etl.yml | 2 +- .github/workflows/release.yml | 2 +- .github/workflows/typeCheck.yml | 17 +- .prettierignore | 2 + dev/.bin/sanity | 1 + dev/aliases.cjs | 6 +- dev/design-studio/tsconfig.json | 7 +- dev/embedded-studio/package.json | 2 +- dev/embedded-studio/tsconfig.json | 6 +- dev/embedded-studio/tsconfig.node.json | 4 +- dev/starter-next-studio/tsconfig.json | 6 +- dev/starter-studio/tsconfig.json | 4 +- dev/strict-studio/tsconfig.json | 8 +- dev/studio-e2e-testing/tsconfig.json | 6 +- dev/test-next-studio/tsconfig.json | 6 +- dev/test-studio/.eslintignore | 3 - dev/test-studio/package.json | 2 +- .../plugins/router-debug/RouterDebug.tsx | 1 - dev/test-studio/tsconfig.json | 11 +- dev/tsconfig.dev.json | 29 +- examples/tsconfig.json | 26 + lerna.json | 1 + package.json | 18 +- .../@repo/package.config/.depcheckrc.json | 3 + packages/@repo/package.config/.eslintrc.cjs | 11 + packages/@repo/package.config/package.json | 14 + .../package.config/src/package.config.ts | 2 +- packages/@repo/tsconfig/base.json | 45 + packages/@repo/tsconfig/build.json | 16 + packages/@repo/tsconfig/package.json | 5 + packages/@sanity/block-tools/.depcheckrc.json | 2 +- .../@sanity/block-tools/package.config.ts | 5 +- packages/@sanity/block-tools/package.json | 23 +- packages/@sanity/block-tools/tsconfig.json | 26 +- .../@sanity/block-tools/tsconfig.lib.json | 11 +- packages/@sanity/cli/.depcheckrc.json | 1 + packages/@sanity/cli/package.config.ts | 6 +- packages/@sanity/cli/package.json | 28 +- .../src/actions/init-project/initProject.ts | 3 +- .../init-project/reconfigureV2Project.ts | 2 +- .../@sanity/cli/src/util/journeyConfig.ts | 10 +- .../cli/templates/shared/tsconfig.json | 6 +- packages/@sanity/cli/tsconfig.json | 34 +- packages/@sanity/cli/tsconfig.lib.json | 17 +- packages/@sanity/codegen/.depcheckrc.json | 2 +- packages/@sanity/codegen/package.config.ts | 3 +- packages/@sanity/codegen/package.json | 31 +- packages/@sanity/codegen/tsconfig.json | 14 +- packages/@sanity/codegen/tsconfig.lib.json | 12 +- packages/@sanity/diff/.depcheckrc.json | 2 +- packages/@sanity/diff/package.config.ts | 5 +- packages/@sanity/diff/package.json | 23 +- packages/@sanity/diff/tsconfig.json | 11 +- packages/@sanity/diff/tsconfig.lib.json | 10 +- packages/@sanity/migrate/.depcheckrc.json | 2 +- packages/@sanity/migrate/package.config.ts | 3 +- packages/@sanity/migrate/package.json | 36 +- packages/@sanity/migrate/tsconfig.json | 15 +- packages/@sanity/migrate/tsconfig.lib.json | 6 +- packages/@sanity/mutator/.depcheckrc.json | 2 +- packages/@sanity/mutator/package.config.ts | 5 +- packages/@sanity/mutator/package.json | 23 +- packages/@sanity/mutator/tsconfig.json | 10 +- packages/@sanity/mutator/tsconfig.lib.json | 6 +- .../portable-text-editor/.depcheckrc.json | 2 +- .../portable-text-editor/package.config.ts | 5 +- .../@sanity/portable-text-editor/package.json | 23 +- .../portable-text-editor/tsconfig.json | 31 +- .../portable-text-editor/tsconfig.lib.json | 14 +- packages/@sanity/schema/.depcheckrc.json | 2 +- packages/@sanity/schema/package.config.ts | 5 +- packages/@sanity/schema/package.json | 43 +- .../src/sanity/validation/types/array.ts | 1 - .../src/sanity/validation/types/block.ts | 1 - .../validation/utils/validateTypeName.ts | 1 - .../test/extractSchema/extractSchema.test.ts | 2 +- .../test/extractSchema/fixtures/block.ts | 2 +- .../test/legacy/fixtures/schemas/blocks.ts | 2 +- .../legacy/fixtures/schemas/example-blog.ts | 2 +- .../schema/test/legacy/schemas.test.ts | 4 +- packages/@sanity/schema/tsconfig.json | 12 +- packages/@sanity/schema/tsconfig.lib.json | 10 +- .../@sanity/schema/typings/humanize-list.d.ts | 4 + packages/@sanity/types/.depcheckrc.json | 2 +- packages/@sanity/types/package.config.ts | 5 +- packages/@sanity/types/package.json | 22 +- .../types/{src/schema => }/test/alias.test.ts | 7 +- .../types/{src/schema => }/test/array.test.ts | 5 +- .../types/{src/schema => }/test/block.test.ts | 5 +- .../{src/schema => }/test/boolean.test.ts | 5 +- .../types/{src/schema => }/test/date.test.ts | 5 +- .../{src/schema => }/test/datetime.test.ts | 5 +- .../{src/schema => }/test/document.test.ts | 5 +- .../types/{src/schema => }/test/email.test.ts | 5 +- .../types/{src/schema => }/test/file.test.ts | 4 +- .../{src/schema => }/test/generic.test.tsx | 3 +- .../{src/schema => }/test/geopoint.test.ts | 5 +- .../types/{src/schema => }/test/image.test.ts | 5 +- .../{src/schema => }/test/number.test.ts | 5 +- .../{src/schema => }/test/object.test.ts | 5 +- .../{src/schema => }/test/reference.test.ts | 5 +- .../types/{src/schema => }/test/slug.test.ts | 5 +- .../{src/schema => }/test/string.test.ts | 5 +- .../types/{src/schema => }/test/text.test.ts | 5 +- .../{src/schema => }/test/typeMerge.test.ts | 6 +- .../types/{src/schema => }/test/url.test.ts | 5 +- packages/@sanity/types/tsconfig.json | 10 +- packages/@sanity/types/tsconfig.lib.json | 11 +- packages/@sanity/util/.depcheckrc.json | 2 +- packages/@sanity/util/exports/client.ts | 1 - .../util/exports/concurrency-limiter.ts | 1 - packages/@sanity/util/exports/content.ts | 1 - .../util/exports/createSafeJsonParser.ts | 1 - packages/@sanity/util/exports/fs.ts | 1 - .../@sanity/util/exports/legacyDateFormat.ts | 1 - packages/@sanity/util/exports/paths.ts | 1 - packages/@sanity/util/package.config.ts | 5 +- packages/@sanity/util/package.json | 124 +- packages/@sanity/util/src/_exports/client.ts | 1 + .../util/src/_exports/concurrency-limiter.ts | 1 + packages/@sanity/util/src/_exports/content.ts | 1 + .../util/src/_exports/createSafeJsonParser.ts | 1 + packages/@sanity/util/src/_exports/fs.ts | 1 + .../util/{exports => src/_exports}/index.ts | 0 .../util/src/_exports/legacyDateFormat.ts | 1 + packages/@sanity/util/src/_exports/paths.ts | 1 + packages/@sanity/util/tsconfig.json | 12 +- packages/@sanity/util/tsconfig.lib.json | 8 +- packages/@sanity/vision/.depcheckrc.json | 16 +- packages/@sanity/vision/package.config.ts | 5 +- packages/@sanity/vision/package.json | 33 +- packages/@sanity/vision/tsconfig.json | 46 +- packages/@sanity/vision/tsconfig.lib.json | 10 +- packages/groq/.depcheckrc.json | 2 +- packages/groq/package.config.ts | 5 +- packages/groq/package.json | 29 +- packages/groq/tsconfig.json | 8 +- packages/groq/tsconfig.lib.json | 5 +- packages/sanity/.depcheckrc.json | 9 +- packages/sanity/.eslintignore | 3 - packages/sanity/.gitignore | 8 +- packages/sanity/exports/_internal.ts | 1 - packages/sanity/exports/_internalBrowser.ts | 1 - packages/sanity/exports/desk.ts | 1 - packages/sanity/exports/router.ts | 1 - packages/sanity/exports/structure.ts | 1 - packages/sanity/package.config.ts | 41 +- packages/sanity/package.json | 155 +- .../sanity/playwright-ct/scripts/utils.ts | 24 +- packages/sanity/src/_exports/_internal.ts | 1 + .../sanity/src/_exports/_internalBrowser.ts | 1 + .../sanity/{exports => src/_exports}/cli.ts | 2 +- packages/sanity/src/_exports/desk.ts | 1 + .../sanity/{exports => src/_exports}/index.ts | 2 +- .../{exports => src/_exports}/migrate.ts | 0 .../{exports => src/_exports}/presentation.ts | 0 packages/sanity/src/_exports/router.ts | 1 + packages/sanity/src/_exports/structure.ts | 1 + .../commands/dataset/importDatasetCommand.ts | 2 +- .../migration/createMigrationCommand.ts | 2 +- .../_internal/cli/threads/extractSchema.ts | 2 + .../cli/threads/validateDocuments.ts | 2 + .../_internal/cli/threads/validateSchema.ts | 2 + .../components/commandList/CommandList.tsx | 2 +- .../src/core/i18n/hooks/useTranslation.ts | 2 + packages/sanity/src/core/i18n/i18nConfig.ts | 1 + .../_legacy/history/useTimelineSelector.ts | 2 +- .../src/core/studio/StudioErrorBoundary.tsx | 2 +- .../useSyncPathnameWithWorkspace.ts | 2 +- .../navbar/search/components/SortMenu.tsx | 2 +- .../search/contexts/search/SearchProvider.tsx | 2 +- .../navbar/search/definitions/fields.ts | 2 +- .../navbar/search/hooks/useSearch.ts | 2 +- .../navbar/search/utils/filterUtils.ts | 3 +- .../WorkspaceRouterProvider.tsx | 2 +- packages/sanity/tsconfig.json | 64 +- packages/sanity/tsconfig.lib.json | 36 +- packages/sanity/tsconfig.tsdoc.json | 24 + packages/sanity/tsdoc.config.ts | 2 + packages/sanity/turbo.json | 2 +- perf/.depcheckrc.json | 2 +- perf/studio/tsconfig.json | 5 +- perf/tests/package.json | 2 +- perf/tests/tsconfig.json | 4 +- pnpm-lock.yaml | 1285 ++++++----------- pnpm-workspace.yaml | 1 + scripts/etl.ts | 9 +- scripts/normalizePackageFields.ts | 2 +- scripts/tsconfig.json | 4 +- tsconfig.json | 25 +- tsconfig.lib.json | 20 - tsconfig.settings.json | 39 - turbo.json | 27 +- 199 files changed, 1337 insertions(+), 1839 deletions(-) delete mode 100644 dev/test-studio/.eslintignore create mode 100644 examples/tsconfig.json create mode 100644 packages/@repo/package.config/.depcheckrc.json create mode 100644 packages/@repo/package.config/.eslintrc.cjs create mode 100644 packages/@repo/package.config/package.json rename package.config.ts => packages/@repo/package.config/src/package.config.ts (95%) create mode 100644 packages/@repo/tsconfig/base.json create mode 100644 packages/@repo/tsconfig/build.json create mode 100644 packages/@repo/tsconfig/package.json create mode 100644 packages/@sanity/schema/typings/humanize-list.d.ts rename packages/@sanity/types/{src/schema => }/test/alias.test.ts (93%) rename packages/@sanity/types/{src/schema => }/test/array.test.ts (97%) rename packages/@sanity/types/{src/schema => }/test/block.test.ts (95%) rename packages/@sanity/types/{src/schema => }/test/boolean.test.ts (91%) rename packages/@sanity/types/{src/schema => }/test/date.test.ts (92%) rename packages/@sanity/types/{src/schema => }/test/datetime.test.ts (93%) rename packages/@sanity/types/{src/schema => }/test/document.test.ts (98%) rename packages/@sanity/types/{src/schema => }/test/email.test.ts (88%) rename packages/@sanity/types/{src/schema => }/test/file.test.ts (97%) rename packages/@sanity/types/{src/schema => }/test/generic.test.tsx (97%) rename packages/@sanity/types/{src/schema => }/test/geopoint.test.ts (94%) rename packages/@sanity/types/{src/schema => }/test/image.test.ts (97%) rename packages/@sanity/types/{src/schema => }/test/number.test.ts (93%) rename packages/@sanity/types/{src/schema => }/test/object.test.ts (96%) rename packages/@sanity/types/{src/schema => }/test/reference.test.ts (97%) rename packages/@sanity/types/{src/schema => }/test/slug.test.ts (91%) rename packages/@sanity/types/{src/schema => }/test/string.test.ts (97%) rename packages/@sanity/types/{src/schema => }/test/text.test.ts (92%) rename packages/@sanity/types/{src/schema => }/test/typeMerge.test.ts (91%) rename packages/@sanity/types/{src/schema => }/test/url.test.ts (91%) delete mode 100644 packages/@sanity/util/exports/client.ts delete mode 100644 packages/@sanity/util/exports/concurrency-limiter.ts delete mode 100644 packages/@sanity/util/exports/content.ts delete mode 100644 packages/@sanity/util/exports/createSafeJsonParser.ts delete mode 100644 packages/@sanity/util/exports/fs.ts delete mode 100644 packages/@sanity/util/exports/legacyDateFormat.ts delete mode 100644 packages/@sanity/util/exports/paths.ts create mode 100644 packages/@sanity/util/src/_exports/client.ts create mode 100644 packages/@sanity/util/src/_exports/concurrency-limiter.ts create mode 100644 packages/@sanity/util/src/_exports/content.ts create mode 100644 packages/@sanity/util/src/_exports/createSafeJsonParser.ts create mode 100644 packages/@sanity/util/src/_exports/fs.ts rename packages/@sanity/util/{exports => src/_exports}/index.ts (100%) create mode 100644 packages/@sanity/util/src/_exports/legacyDateFormat.ts create mode 100644 packages/@sanity/util/src/_exports/paths.ts delete mode 100644 packages/sanity/exports/_internal.ts delete mode 100644 packages/sanity/exports/_internalBrowser.ts delete mode 100644 packages/sanity/exports/desk.ts delete mode 100644 packages/sanity/exports/router.ts delete mode 100644 packages/sanity/exports/structure.ts create mode 100644 packages/sanity/src/_exports/_internal.ts create mode 100644 packages/sanity/src/_exports/_internalBrowser.ts rename packages/sanity/{exports => src/_exports}/cli.ts (75%) create mode 100644 packages/sanity/src/_exports/desk.ts rename packages/sanity/{exports => src/_exports}/index.ts (73%) rename packages/sanity/{exports => src/_exports}/migrate.ts (100%) rename packages/sanity/{exports => src/_exports}/presentation.ts (100%) create mode 100644 packages/sanity/src/_exports/router.ts create mode 100644 packages/sanity/src/_exports/structure.ts create mode 100644 packages/sanity/tsconfig.tsdoc.json delete mode 100644 tsconfig.lib.json delete mode 100644 tsconfig.settings.json diff --git a/.depcheckrc.json b/.depcheckrc.json index a5f5a1ead55..f35f123bdf8 100644 --- a/.depcheckrc.json +++ b/.depcheckrc.json @@ -1,3 +1,9 @@ { - "ignores": ["@sanity/eslint-config-studio", "dotenv-flow", "esbuild", "esbuild-register"] + "ignores": [ + "@repo/tsconfig", + "@sanity/eslint-config-studio", + "dotenv-flow", + "esbuild", + "esbuild-register" + ] } diff --git a/.eslintrc.cjs b/.eslintrc.cjs index 6ffa2da9aab..3eb33f362de 100644 --- a/.eslintrc.cjs +++ b/.eslintrc.cjs @@ -49,6 +49,8 @@ const config = { '*.css', '*.snap', '*.md', + 'dev/test-studio/sanity.theme.mjs', + 'dev/test-studio/workshop/scopes.js', ], rules: { '@typescript-eslint/no-var-requires': 'off', // prefer import/no-dynamic-require @@ -57,6 +59,7 @@ const config = { 'import/no-named-as-default': 'off', 'import/no-named-as-default-member': 'off', 'import/no-unresolved': 'off', + 'import/default': 'off', 'prettier/prettier': 'error', 'tsdoc/syntax': 'error', 'react-hooks/rules-of-hooks': 'error', @@ -191,16 +194,17 @@ const config = { project: [ 'dev/*/tsconfig.json', 'examples/*/tsconfig.json', + 'packages/@repo/*/tsconfig.json', 'packages/@sanity/*/tsconfig.json', 'packages/*/tsconfig.json', ], }, }, - 'boundaries/include': ['packages/sanity/exports/*.*', 'packages/sanity/src/**/*.*'], + 'boundaries/include': ['packages/sanity/src/**/*.*'], 'boundaries/elements': [ { type: 'sanity', - pattern: ['packages/sanity/exports/index.ts'], + pattern: ['packages/sanity/src/_exports/index.ts'], mode: 'full', }, { @@ -210,7 +214,7 @@ const config = { }, { type: 'sanity/_internal', - pattern: ['packages/sanity/exports/_internal.ts'], + pattern: ['packages/sanity/src/_exports/_internal.ts'], mode: 'full', }, { @@ -220,7 +224,7 @@ const config = { }, { type: 'sanity/cli', - pattern: ['packages/sanity/exports/cli.ts'], + pattern: ['packages/sanity/src/_exports/cli.ts'], mode: 'full', }, { @@ -230,7 +234,7 @@ const config = { }, { type: 'sanity/desk', - pattern: ['packages/sanity/exports/desk.ts'], + pattern: ['packages/sanity/src/_exports/desk.ts'], mode: 'file', }, { @@ -240,7 +244,7 @@ const config = { }, { type: 'sanity/router', - pattern: ['packages/sanity/exports/router.ts'], + pattern: ['packages/sanity/src/_exports/router.ts'], mode: 'full', }, { @@ -250,7 +254,7 @@ const config = { }, { type: 'sanity/structure', - pattern: ['packages/sanity/exports/structure.ts'], + pattern: ['packages/sanity/src/_exports/structure.ts'], mode: 'file', }, { diff --git a/.github/workflows/cli-test.yml b/.github/workflows/cli-test.yml index e75fd9f8df1..584d855842a 100644 --- a/.github/workflows/cli-test.yml +++ b/.github/workflows/cli-test.yml @@ -67,7 +67,7 @@ jobs: run: pnpm install - name: Build CLI - run: pnpm build # Needed for CLI tests + run: pnpm build --output-logs=full --log-order=grouped # Needed for CLI tests - name: Test id: test diff --git a/.github/workflows/docReport.yml b/.github/workflows/docReport.yml index 62de5e2b0c6..68ee7207c4d 100644 --- a/.github/workflows/docReport.yml +++ b/.github/workflows/docReport.yml @@ -52,7 +52,7 @@ jobs: run: pnpm install - name: Build packages - run: pnpm build + run: pnpm build --output-logs=full --log-order=grouped env: NODE_OPTIONS: --max_old_space_size=8192 diff --git a/.github/workflows/e2e-ct.yml b/.github/workflows/e2e-ct.yml index a37597adb8f..37de8e1f2ec 100644 --- a/.github/workflows/e2e-ct.yml +++ b/.github/workflows/e2e-ct.yml @@ -61,7 +61,7 @@ jobs: - name: Install Playwright Browsers run: npx playwright install --with-deps - name: Build packages - run: pnpm build + run: pnpm build --output-logs=full --log-order=grouped - name: Run end-to-end tests run: pnpm --filter sanity test:ct env: diff --git a/.github/workflows/e2e.yml b/.github/workflows/e2e.yml index 2b45ee5c487..67e6e2f535f 100644 --- a/.github/workflows/e2e.yml +++ b/.github/workflows/e2e.yml @@ -70,7 +70,7 @@ jobs: run: npx playwright install --with-deps - name: Build CLI - run: pnpm build:cli + run: pnpm build:cli --output-logs=full --log-order=grouped - name: Build E2E test studio on next if: ${{ github.event_name == 'push' && github.ref == 'refs/heads/next' }} diff --git a/.github/workflows/etl.yml b/.github/workflows/etl.yml index 09b049cf663..964e6e9af65 100644 --- a/.github/workflows/etl.yml +++ b/.github/workflows/etl.yml @@ -54,7 +54,7 @@ jobs: run: pnpm install - name: Build packages - run: pnpm build + run: pnpm build --output-logs=full --log-order=grouped env: NODE_OPTIONS: --max_old_space_size=8192 diff --git a/.github/workflows/release.yml b/.github/workflows/release.yml index a6e956d08a6..8d319126bb9 100644 --- a/.github/workflows/release.yml +++ b/.github/workflows/release.yml @@ -105,7 +105,7 @@ jobs: ${{ inputs.version }} - name: Build - run: pnpm build + run: pnpm build --output-logs=full --log-order=grouped - name: Publish run: | diff --git a/.github/workflows/typeCheck.yml b/.github/workflows/typeCheck.yml index e51ff0d3f26..bb95cf0f179 100644 --- a/.github/workflows/typeCheck.yml +++ b/.github/workflows/typeCheck.yml @@ -5,6 +5,9 @@ jobs: typeCheck: timeout-minutes: 15 runs-on: ubuntu-latest + env: + TURBO_TOKEN: ${{ secrets.TURBO_TOKEN }} + TURBO_TEAM: ${{ vars.TURBO_TEAM }} steps: - uses: actions/checkout@v4 - uses: actions/setup-node@v4 @@ -41,9 +44,17 @@ jobs: run: pnpm install - name: Check type system - # If TypeScript project references is set up properly, `tsc --build` should work right after dependencies - # has been installed, no extra build/compile step required + # Turbo will run type checks on all files in the project + # and ensure that dependencies are built with @sanity/pkg-utils to output dts + # used by other packages as they are type checked id: typeCheckModules - run: pnpm check:types + run: pnpm check:types --output-logs=full --log-order=grouped + env: + NODE_OPTIONS: --max_old_space_size=8192 + + - name: Check package.json with @sanity/pkg-utils + # Turbo will ensure `build` is run before each package, as pkg-utils requires + # as it will check if files declared in package.json `main`, `exports`, `types` and more exists + run: pnpm check:package --output-logs=full --log-order=grouped env: NODE_OPTIONS: --max_old_space_size=8192 diff --git a/.prettierignore b/.prettierignore index d8359a3556f..21919b83fce 100644 --- a/.prettierignore +++ b/.prettierignore @@ -20,6 +20,7 @@ /packages/*/lib /packages/*/node_modules +/packages/@repo/*/node_modules /packages/@sanity/*/coverage /packages/@sanity/*/lib /packages/@sanity/*/node_modules @@ -31,6 +32,7 @@ /test/v2-studio/dist /turbo.json /packages/*/turbo.json +/packages/@repo/*/turbo.json /packages/@sanity/*/turbo.json /pnpm-lock.yaml diff --git a/dev/.bin/sanity b/dev/.bin/sanity index 2007e127ece..ba62a21bce5 100755 --- a/dev/.bin/sanity +++ b/dev/.bin/sanity @@ -4,6 +4,7 @@ const path = require('path') require('esbuild-register/dist/node').register({ target: `node${process.version.slice(1)}`, + jsx: 'automatic', }) // Define the global `__DEV__` flag which is used to diff --git a/dev/aliases.cjs b/dev/aliases.cjs index 8e2eef55163..1cc8ad954e4 100644 --- a/dev/aliases.cjs +++ b/dev/aliases.cjs @@ -24,11 +24,9 @@ const devAliases = { '@sanity/schema': './packages/@sanity/schema/src/_exports', '@sanity/migrate': './packages/@sanity/migrate/src/_exports', '@sanity/types': './packages/@sanity/types/src', - '@sanity/types/parts': './packages/@sanity/types/parts', - '@sanity/util/fs': './packages/@sanity/util/src/fsTools.ts', - '@sanity/util': './packages/@sanity/util/src', + '@sanity/util': './packages/@sanity/util/src/_exports', '@sanity/vision': './packages/@sanity/vision/src', - sanity: './packages/sanity/exports', + sanity: './packages/sanity/src/_exports', } module.exports = devAliases diff --git a/dev/design-studio/tsconfig.json b/dev/design-studio/tsconfig.json index dbf091669e0..e10fe0a8eaa 100644 --- a/dev/design-studio/tsconfig.json +++ b/dev/design-studio/tsconfig.json @@ -1,8 +1,3 @@ { - "extends": "../tsconfig.dev", - "include": ["**/*.ts", "**/*.tsx"], - "compilerOptions": { - "jsx": "preserve" - }, - "references": [{"path": "../../packages/sanity/tsconfig.lib.json"}] + "extends": "../tsconfig.dev" } diff --git a/dev/embedded-studio/package.json b/dev/embedded-studio/package.json index f9aa2c86772..6ab7e709c79 100644 --- a/dev/embedded-studio/package.json +++ b/dev/embedded-studio/package.json @@ -18,7 +18,7 @@ "@types/react": "^18.2.74", "@types/react-dom": "^18.2.23", "@vitejs/plugin-react": "^4.2.1", - "typescript": "^5.4.2", + "typescript": "5.4.2", "vite": "^4.5.3" } } diff --git a/dev/embedded-studio/tsconfig.json b/dev/embedded-studio/tsconfig.json index dee6b84f246..e80574eea0a 100644 --- a/dev/embedded-studio/tsconfig.json +++ b/dev/embedded-studio/tsconfig.json @@ -7,10 +7,8 @@ "strict": true, "forceConsistentCasingInFileNames": true, "noEmit": true, - "esModuleInterop": true, - "module": "esnext", - "moduleResolution": "node", - "resolveJsonModule": true, + "module": "Preserve", + "moduleDetection": "force", "isolatedModules": true, "jsx": "preserve", "incremental": true diff --git a/dev/embedded-studio/tsconfig.node.json b/dev/embedded-studio/tsconfig.node.json index 42872c59f5b..4a069212952 100644 --- a/dev/embedded-studio/tsconfig.node.json +++ b/dev/embedded-studio/tsconfig.node.json @@ -2,8 +2,8 @@ "compilerOptions": { "composite": true, "skipLibCheck": true, - "module": "ESNext", - "moduleResolution": "bundler", + "module": "Preserve", + "moduleDetection": "force", "allowSyntheticDefaultImports": true }, "include": ["vite.config.ts"] diff --git a/dev/starter-next-studio/tsconfig.json b/dev/starter-next-studio/tsconfig.json index ab2c2af0046..6a0ffdc7f4c 100644 --- a/dev/starter-next-studio/tsconfig.json +++ b/dev/starter-next-studio/tsconfig.json @@ -8,10 +8,8 @@ "forceConsistentCasingInFileNames": true, "noEmit": true, "incremental": true, - "esModuleInterop": true, - "module": "esnext", - "moduleResolution": "node", - "resolveJsonModule": true, + "module": "Preserve", + "moduleDetection": "force", "isolatedModules": true, "jsx": "preserve" }, diff --git a/dev/starter-studio/tsconfig.json b/dev/starter-studio/tsconfig.json index dbf091669e0..89f1e7f46ab 100644 --- a/dev/starter-studio/tsconfig.json +++ b/dev/starter-studio/tsconfig.json @@ -1,8 +1,6 @@ { "extends": "../tsconfig.dev", - "include": ["**/*.ts", "**/*.tsx"], "compilerOptions": { "jsx": "preserve" - }, - "references": [{"path": "../../packages/sanity/tsconfig.lib.json"}] + } } diff --git a/dev/strict-studio/tsconfig.json b/dev/strict-studio/tsconfig.json index 84718f2f733..e10fe0a8eaa 100644 --- a/dev/strict-studio/tsconfig.json +++ b/dev/strict-studio/tsconfig.json @@ -1,9 +1,3 @@ { - "extends": "../tsconfig.dev", - "include": ["**/*.ts", "**/*.tsx"], - "compilerOptions": { - "composite": true, - "jsx": "preserve" - }, - "references": [{"path": "../../packages/sanity/tsconfig.lib.json"}] + "extends": "../tsconfig.dev" } diff --git a/dev/studio-e2e-testing/tsconfig.json b/dev/studio-e2e-testing/tsconfig.json index 6551399f227..7e46d189373 100644 --- a/dev/studio-e2e-testing/tsconfig.json +++ b/dev/studio-e2e-testing/tsconfig.json @@ -7,10 +7,8 @@ "strict": true, "forceConsistentCasingInFileNames": true, "noEmit": true, - "esModuleInterop": true, - "module": "esnext", - "moduleResolution": "node", - "resolveJsonModule": true, + "module": "Preserve", + "moduleDetection": "force", "isolatedModules": true, "jsx": "react-jsx", "incremental": true diff --git a/dev/test-next-studio/tsconfig.json b/dev/test-next-studio/tsconfig.json index 46ceee91746..bceb3bc11ee 100644 --- a/dev/test-next-studio/tsconfig.json +++ b/dev/test-next-studio/tsconfig.json @@ -8,10 +8,8 @@ "forceConsistentCasingInFileNames": true, "noEmit": true, "incremental": true, - "esModuleInterop": true, - "module": "esnext", - "moduleResolution": "node", - "resolveJsonModule": true, + "module": "Preserve", + "moduleDetection": "force", "isolatedModules": true, "jsx": "preserve", "plugins": [ diff --git a/dev/test-studio/.eslintignore b/dev/test-studio/.eslintignore deleted file mode 100644 index 6996bd5e3c6..00000000000 --- a/dev/test-studio/.eslintignore +++ /dev/null @@ -1,3 +0,0 @@ -# Package specific -sanity.theme.mjs -workshop/scopes.js diff --git a/dev/test-studio/package.json b/dev/test-studio/package.json index dd26291fe3b..610a150f370 100644 --- a/dev/test-studio/package.json +++ b/dev/test-studio/package.json @@ -38,7 +38,7 @@ "@sanity/presentation": "1.11.4", "@sanity/preview-url-secret": "^1.6.1", "@sanity/react-loader": "^1.8.3", - "@sanity/tsdoc": "1.0.0-alpha.44", + "@sanity/tsdoc": "1.0.13", "@sanity/types": "workspace:*", "@sanity/ui": "^2.1.0", "@sanity/ui-workshop": "^1.0.0", diff --git a/dev/test-studio/plugins/router-debug/RouterDebug.tsx b/dev/test-studio/plugins/router-debug/RouterDebug.tsx index 746a29637e0..2467298fa15 100644 --- a/dev/test-studio/plugins/router-debug/RouterDebug.tsx +++ b/dev/test-studio/plugins/router-debug/RouterDebug.tsx @@ -40,7 +40,6 @@ export function RouterDebug() { diff --git a/dev/test-studio/tsconfig.json b/dev/test-studio/tsconfig.json index 078eecd89bc..38f60e113f7 100644 --- a/dev/test-studio/tsconfig.json +++ b/dev/test-studio/tsconfig.json @@ -1,15 +1,6 @@ { "extends": "../tsconfig.dev", - "include": ["**/*.ts", "**/*.tsx"], "compilerOptions": { - "jsx": "react-jsx", - "allowJs": true, "isolatedModules": false - }, - "references": [ - {"path": "../../packages/@sanity/types/tsconfig.lib.json"}, - {"path": "../../packages/@sanity/vision/tsconfig.lib.json"}, - {"path": "../../packages/sanity/tsconfig.lib.json"}, - {"path": "../../packages/@sanity/migrate/tsconfig.lib.json"} - ] + } } diff --git a/dev/tsconfig.dev.json b/dev/tsconfig.dev.json index 5d035cf2c9f..1aa81f6ad02 100644 --- a/dev/tsconfig.dev.json +++ b/dev/tsconfig.dev.json @@ -1,19 +1,26 @@ { - "extends": "../tsconfig.settings", - "include": ["../packages/@sanity/util/src"], + "extends": "@repo/tsconfig/base.json", + "include": ["**/*.ts", "**/*.tsx"], "compilerOptions": { "rootDir": "..", "baseUrl": "..", - "outDir": "./.cache/ts", - "paths": { - // Alias to paths required for Sanity CLI to run in dev-mode - "@sanity/mutator": ["./packages/@sanity/mutator/src"], - "@sanity/util/fs": ["./packages/@sanity/util/exports/fs.ts"], - "sanity/_internal": ["./packages/sanity/exports/_internal.ts"], - "sanity/migrate": ["./packages/sanity/exports/migrate.ts"], - "sanity/migrate/mutations": ["./packages/sanity/exports/migrate-mutations.ts"], - "sanity/cli": ["./packages/sanity/exports/cli.ts"] + "@sanity/block-tools": ["./packages/@sanity/block-tools/src/index.ts"], + "@sanity/diff": ["./packages/@sanity/diff/src/index.ts"], + "@sanity/cli": ["./packages/@sanity/cli/src/index.ts"], + "@sanity/codegen": ["./packages/@sanity/codegen/src/_exports/index.ts"], + "@sanity/mutator": ["./packages/@sanity/mutator/src/index.ts"], + "@sanity/portable-text-editor": ["./packages/@sanity/portable-text-editor/src/index.ts"], + "@sanity/schema/*": ["./packages/@sanity/schema/src/_exports/*"], + "@sanity/schema": ["./packages/@sanity/schema/src/_exports/index.ts"], + "@sanity/migrate": ["./packages/@sanity/migrate/src/_exports/index.ts"], + "@sanity/types": ["./packages/@sanity/types/src/index.ts"], + "@sanity/util/*": ["./packages/@sanity/util/src/_exports/*"], + "@sanity/util": ["./packages/@sanity/util/src/_exports/index.ts"], + "@sanity/vision": ["./packages/@sanity/vision/src/index.ts"], + "groq": ["./packages/groq/src/groq.ts"], + "sanity/*": ["./packages/sanity/src/_exports/*"], + "sanity": ["./packages/sanity/src/_exports/index.ts"] } } } diff --git a/examples/tsconfig.json b/examples/tsconfig.json new file mode 100644 index 00000000000..1aa81f6ad02 --- /dev/null +++ b/examples/tsconfig.json @@ -0,0 +1,26 @@ +{ + "extends": "@repo/tsconfig/base.json", + "include": ["**/*.ts", "**/*.tsx"], + "compilerOptions": { + "rootDir": "..", + "baseUrl": "..", + "paths": { + "@sanity/block-tools": ["./packages/@sanity/block-tools/src/index.ts"], + "@sanity/diff": ["./packages/@sanity/diff/src/index.ts"], + "@sanity/cli": ["./packages/@sanity/cli/src/index.ts"], + "@sanity/codegen": ["./packages/@sanity/codegen/src/_exports/index.ts"], + "@sanity/mutator": ["./packages/@sanity/mutator/src/index.ts"], + "@sanity/portable-text-editor": ["./packages/@sanity/portable-text-editor/src/index.ts"], + "@sanity/schema/*": ["./packages/@sanity/schema/src/_exports/*"], + "@sanity/schema": ["./packages/@sanity/schema/src/_exports/index.ts"], + "@sanity/migrate": ["./packages/@sanity/migrate/src/_exports/index.ts"], + "@sanity/types": ["./packages/@sanity/types/src/index.ts"], + "@sanity/util/*": ["./packages/@sanity/util/src/_exports/*"], + "@sanity/util": ["./packages/@sanity/util/src/_exports/index.ts"], + "@sanity/vision": ["./packages/@sanity/vision/src/index.ts"], + "groq": ["./packages/groq/src/groq.ts"], + "sanity/*": ["./packages/sanity/src/_exports/*"], + "sanity": ["./packages/sanity/src/_exports/index.ts"] + } + } +} diff --git a/lerna.json b/lerna.json index f5bbcceb710..6415281271a 100644 --- a/lerna.json +++ b/lerna.json @@ -6,6 +6,7 @@ "perf/tests", "perf/studio", "examples/*", + "packages/@repo/*", "packages/@sanity/*", "packages/create-sanity", "packages/groq", diff --git a/package.json b/package.json index f9c4f364e83..275b583bddd 100644 --- a/package.json +++ b/package.json @@ -3,12 +3,11 @@ "version": "0.0.0", "private": true, "scripts": { - "bootstrap": "pnpm install && pnpm build:dts && pnpm build:cli", + "bootstrap": "pnpm install && pnpm build:cli", "build": "turbo run build --filter='./packages/*' --filter='./packages/@sanity/*'", "build:clean": "lerna run clean", "build:cli": "turbo run build --filter=@sanity/cli --filter=sanity", "build:cli-only": "turbo run --filter=@sanity/cli build", - "build:dts": "tsc --build tsconfig.lib.json", "build:e2e": "pnpm e2e:build", "build:performance-studio": "pnpm perf:studio:build", "build:test-studio": "pnpm build --filter=sanity-test-studio", @@ -18,12 +17,13 @@ "check:lint": "turbo run lint -- --quiet", "check:react-exhaustive-deps": "run-s check:lint -- --quiet --rule 'react-hooks/exhaustive-deps: [error, {additionalHooks: \"(useAsync|useMemoObservable|useObservableCallback)\"}]'", "check:test": "run-s test -- --silent", - "check:types": "tsc --build", + "check:package": "turbo run check:package --filter='./packages/*' --filter='./packages/@sanity/*'", + "check:types": "tsc && turbo run check:types --filter='./packages/*' --filter='./packages/@sanity/*'", "chore:format:fix": "prettier --cache --write .", "chore:lint:fix": "turbo run lint -- --quiet --fix", "chore:normalize-versions": "node -r esbuild-register scripts/normalizeDependencyVersions.ts", "clean": "run-s build:clean clean:deps", - "clean:deps": "rimraf packages/@sanity/*/node_modules packages/*/node_modules node_modules", + "clean:deps": "rimraf packages/@repo/*/node_modules packages/@sanity/*/node_modules packages/*/node_modules node_modules", "depcheck": "pnpm check:deps", "deploy:movies": "pnpm build && cd examples/movies-studio && sanity deploy", "deploy:test": "pnpm build && cd dev/test-studio && sanity deploy", @@ -51,6 +51,7 @@ "example:clean-studio": "cd examples/blog-studio && pnpm start", "example:ecommerce-studio": "cd examples/blog-studio && pnpm start", "example:example-studio": "cd examples/blog-studio && pnpm start", + "prepublishOnly": "pnpm build", "example:movies-studio": "cd examples/blog-studio && pnpm start", "install:deps": "pnpm install", "lint": "run-s check:lint", @@ -67,7 +68,6 @@ "postinstall": "husky", "prettier": "prettier --cache .", "prettify": "lerna run clean && prettier --write .", - "prettify:dts": "prettier --loglevel warn --write packages/@sanity/*/lib/dts && prettier --loglevel warn --write packages/*/lib/dts", "publish:tarball": "node -r esbuild-register scripts/publish/tarball", "release": "pnpm build && lerna publish --exact --force-publish", "release:canary": "RELEASE_TAG=canary pnpm release:tag", @@ -96,12 +96,14 @@ "@jest/globals": "^29.7.0", "@optimize-lodash/rollup-plugin": "^4.0.4", "@playwright/test": "1.41.2", + "@repo/package.config": "workspace:*", + "@repo/tsconfig": "workspace:*", "@sanity/client": "^6.15.11", "@sanity/eslint-config-i18n": "1.0.0", "@sanity/eslint-config-studio": "^3.0.1", - "@sanity/pkg-utils": "^4.4.4", + "@sanity/pkg-utils": "5.1.12", "@sanity/test": "0.0.1-alpha.1", - "@sanity/tsdoc": "1.0.0-alpha.44", + "@sanity/tsdoc": "1.0.13", "@sanity/uuid": "^3.0.2", "@types/glob": "^7.2.0", "@types/lodash": "^4.14.149", @@ -150,7 +152,7 @@ "sanity": "workspace:*", "semver": "^7.3.5", "turbo": "^1.13.2", - "typescript": "5.3.3", + "typescript": "5.4.2", "yargs": "^17.3.0" }, "optionalDependencies": { diff --git a/packages/@repo/package.config/.depcheckrc.json b/packages/@repo/package.config/.depcheckrc.json new file mode 100644 index 00000000000..d2b37f0015c --- /dev/null +++ b/packages/@repo/package.config/.depcheckrc.json @@ -0,0 +1,3 @@ +{ + "ignores": ["@sanity/pkg-utils"] +} diff --git a/packages/@repo/package.config/.eslintrc.cjs b/packages/@repo/package.config/.eslintrc.cjs new file mode 100644 index 00000000000..99fd6c69224 --- /dev/null +++ b/packages/@repo/package.config/.eslintrc.cjs @@ -0,0 +1,11 @@ +'use strict' + +const path = require('path') + +const ROOT_PATH = path.resolve(__dirname, '../../..') + +module.exports = { + rules: { + 'import/no-extraneous-dependencies': ['error', {packageDir: [ROOT_PATH, __dirname]}], + }, +} diff --git a/packages/@repo/package.config/package.json b/packages/@repo/package.config/package.json new file mode 100644 index 00000000000..a54b4d8dce3 --- /dev/null +++ b/packages/@repo/package.config/package.json @@ -0,0 +1,14 @@ +{ + "name": "@repo/package.config", + "version": "0.0.0", + "private": true, + "description": "Shared @sanity/pkg-utils configuration", + "main": "./src/package.config.ts", + "types": "./src/package.config.ts", + "scripts": { + "check:types": "tsc --noEmit --skipLibCheck src/package.config.ts" + }, + "dependencies": { + "@optimize-lodash/rollup-plugin": "^4.0.4" + } +} diff --git a/package.config.ts b/packages/@repo/package.config/src/package.config.ts similarity index 95% rename from package.config.ts rename to packages/@repo/package.config/src/package.config.ts index 2d9f9dc92aa..095ce789ea9 100644 --- a/package.config.ts +++ b/packages/@repo/package.config/src/package.config.ts @@ -31,5 +31,5 @@ export default defineConfig({ rollup: { plugins: [optimizeLodashImports()], }, - tsconfig: 'tsconfig.dist.json', + tsconfig: 'tsconfig.lib.json', }) diff --git a/packages/@repo/tsconfig/base.json b/packages/@repo/tsconfig/base.json new file mode 100644 index 00000000000..d22675541a7 --- /dev/null +++ b/packages/@repo/tsconfig/base.json @@ -0,0 +1,45 @@ +{ + "$schema": "https://json.schemastore.org/tsconfig", + "description": "Shared TS config that are used for builds, dts generation, etl extract, and vscode/intellisense", + "compilerOptions": { + // Everything needs to use the same lib settings for `paths` to work consistently throughout the monorepo + "lib": ["dom", "es2020", "ES2022.Error"], + + // Output settings + "target": "ESNext", + "module": "Preserve", + "moduleDetection": "force", + "allowSyntheticDefaultImports": true, + "jsx": "preserve", + // If a package that emits code forgets to specify the outDir then the default behavior of tsc is to colocate .d.ts files, + // that's incredibly problematic and can be time-consuming to clean up. This default value acts as a failsafe against that + "outDir": "./node_modules/.sanity-monorepo/dts", + + // Don't emit anything by default, emit is done by `@sanity/pkg-utils` during build + "noEmit": true, + + // Settings + "preserveConstEnums": true, + "useUnknownInCatchVariables": false, + "isolatedModules": true, + "forceConsistentCasingInFileNames": true, + "allowJs": true, + "checkJs": false, + + // Strict type-checking + "strict": true, + // "noImplicitAny": true, + // "strictNullChecks": true, + // "strictFunctionTypes": true, + // "strictPropertyInitialization": true, + // "noImplicitThis": true, + // "alwaysStrict": true, + + // Additional checks + // "noUnusedLocals": true, + // "noUnusedParameters": true, + // "noImplicitReturns": true, + // "noFallthroughCasesInSwitch": true, + "skipLibCheck": true + } +} diff --git a/packages/@repo/tsconfig/build.json b/packages/@repo/tsconfig/build.json new file mode 100644 index 00000000000..608aa6fefaa --- /dev/null +++ b/packages/@repo/tsconfig/build.json @@ -0,0 +1,16 @@ +{ + "$schema": "https://json.schemastore.org/tsconfig", + "description": "The shared configuration used by @sanity/pkg-utils to build workspaces and generate dts files", + "extends": "./base.json", + "compilerOptions": { + // emitDeclarationOnly: true requires noEmit: false since base.json sets it + "noEmit": false, + // @sanity/pkg-utils only uses the TypeScript compiler to generate dts files + "emitDeclarationOnly": true, + "declaration": true, + // @TODO test if also generating source maps for dts files improves error messages when type checks fail + // "declarationMap": false + // every package must declare this, by setting this here we ensure that accidents will write to ./node_modules/.sanity-monorepo/dts instead of generating .d.ts files that are colocated if `outDir` is accidentally missing + "outDir": "./node_modules/.sanity-monorepo/dts" + } +} diff --git a/packages/@repo/tsconfig/package.json b/packages/@repo/tsconfig/package.json new file mode 100644 index 00000000000..94f1d5d5553 --- /dev/null +++ b/packages/@repo/tsconfig/package.json @@ -0,0 +1,5 @@ +{ + "name": "@repo/tsconfig", + "version": "0.0.0", + "private": true +} diff --git a/packages/@sanity/block-tools/.depcheckrc.json b/packages/@sanity/block-tools/.depcheckrc.json index d37cdad8206..02c1502f7d2 100644 --- a/packages/@sanity/block-tools/.depcheckrc.json +++ b/packages/@sanity/block-tools/.depcheckrc.json @@ -1,3 +1,3 @@ { - "ignores": ["@sanity/pkg-utils", "react"] + "ignores": ["@repo/tsconfig", "@sanity/pkg-utils", "react"] } diff --git a/packages/@sanity/block-tools/package.config.ts b/packages/@sanity/block-tools/package.config.ts index 4477b03d52e..c43051dd053 100644 --- a/packages/@sanity/block-tools/package.config.ts +++ b/packages/@sanity/block-tools/package.config.ts @@ -1,5 +1,4 @@ +import baseConfig from '@repo/package.config' import {defineConfig} from '@sanity/pkg-utils' -import baseConfig from '../../../package.config' - -export default defineConfig({...baseConfig}) +export default defineConfig(baseConfig) diff --git a/packages/@sanity/block-tools/package.json b/packages/@sanity/block-tools/package.json index 9ce1bb52e87..072907a52ee 100644 --- a/packages/@sanity/block-tools/package.json +++ b/packages/@sanity/block-tools/package.json @@ -21,38 +21,34 @@ }, "license": "MIT", "author": "Sanity.io ", + "sideEffects": false, "exports": { ".": { - "types": "./lib/dts/src/index.d.ts", "source": "./src/index.ts", + "import": "./lib/index.mjs", "require": "./lib/index.js", - "node": { - "module": "./lib/index.esm.js", - "import": "./lib/index.cjs.mjs" - }, - "import": "./lib/index.esm.js", - "default": "./lib/index.esm.js" + "default": "./lib/index.js" }, "./package.json": "./package.json" }, "main": "./lib/index.js", "module": "./lib/index.esm.js", "source": "./src/index.ts", - "types": "./lib/dts/src/index.d.ts", + "types": "./lib/index.d.ts", "files": [ "lib", "src" ], "scripts": { - "prebuild": "run-s clean", - "build": "pkg-utils build --tsconfig tsconfig.lib.json", - "postbuild": "run-s check:package", - "check:package": "pkg-utils --strict --tsconfig tsconfig.lib.json", + "build": "run-s clean && pkg-utils build --strict", + "check:package": "pkg-utils --strict", + "check:types": "tsc", "clean": "rimraf lib", "coverage": "NODE_ENV=test jest --coverage", "lint": "eslint .", + "prepublishOnly": "turbo run build", "test": "NODE_ENV=test jest", - "watch": "pkg-utils watch --tsconfig tsconfig.lib.json" + "watch": "pkg-utils watch" }, "dependencies": { "get-random-values-esm": "1.0.2", @@ -60,6 +56,7 @@ }, "devDependencies": { "@jest/globals": "^29.7.0", + "@repo/package.config": "workspace:*", "@sanity/schema": "3.36.4", "@sanity/types": "3.36.4", "@types/jsdom": "^20.0.0", diff --git a/packages/@sanity/block-tools/tsconfig.json b/packages/@sanity/block-tools/tsconfig.json index 35da468b0b8..e01ddd8602e 100644 --- a/packages/@sanity/block-tools/tsconfig.json +++ b/packages/@sanity/block-tools/tsconfig.json @@ -1,13 +1,21 @@ { - "extends": "../../../tsconfig.settings", - "include": ["./src", "./test"], + "extends": "@repo/tsconfig/base.json", + "include": [ + "./src", + "./test", + "./node_modules/@sanity/types/src", + "./node_modules/@sanity/schema/src", + "./node_modules/@sanity/schema/typings", + "./node_modules/@sanity/util/src" + ], "compilerOptions": { - "composite": true, - "declarationDir": "./lib/dts", "rootDir": ".", - "outDir": "./lib/dts", - - "jsx": "react-jsx" - }, - "references": [{"path": "../schema/tsconfig.lib.json"}, {"path": "../types/tsconfig.lib.json"}] + "paths": { + "@sanity/schema/*": ["./node_modules/@sanity/schema/src/_exports/*"], + "@sanity/schema": ["./node_modules/@sanity/schema/src/_exports/index.ts"], + "@sanity/types": ["./node_modules/@sanity/types/src"], + "@sanity/util/*": ["./node_modules/@sanity/util/src/_exports/*"], + "@sanity/util": ["./node_modules/@sanity/util/src/_exports/index.ts"] + } + } } diff --git a/packages/@sanity/block-tools/tsconfig.lib.json b/packages/@sanity/block-tools/tsconfig.lib.json index 5d624d18b44..66149ff3da1 100644 --- a/packages/@sanity/block-tools/tsconfig.lib.json +++ b/packages/@sanity/block-tools/tsconfig.lib.json @@ -1,5 +1,5 @@ { - "extends": "../../../tsconfig.settings", + "extends": "@repo/tsconfig/build.json", "include": ["./src"], "exclude": [ "./src/**/__fixtures__", @@ -9,12 +9,7 @@ "./src/**/*.test.tsx" ], "compilerOptions": { - "composite": true, "rootDir": ".", - "outDir": "./lib/dts", - "declarationDir": "./lib/dts", - - "jsx": "react-jsx" - }, - "references": [{"path": "../schema/tsconfig.lib.json"}, {"path": "../types/tsconfig.lib.json"}] + "outDir": "./lib" + } } diff --git a/packages/@sanity/cli/.depcheckrc.json b/packages/@sanity/cli/.depcheckrc.json index f20daaa9e8f..90cce94cb1c 100644 --- a/packages/@sanity/cli/.depcheckrc.json +++ b/packages/@sanity/cli/.depcheckrc.json @@ -1,5 +1,6 @@ { "ignores": [ + "@repo/tsconfig", "@sanity/pkg-utils", "sanity", "@sanity/icons", diff --git a/packages/@sanity/cli/package.config.ts b/packages/@sanity/cli/package.config.ts index a5bf248b685..bff8c531b35 100644 --- a/packages/@sanity/cli/package.config.ts +++ b/packages/@sanity/cli/package.config.ts @@ -1,12 +1,11 @@ /* eslint-disable no-sync */ +import baseConfig from '@repo/package.config' import {nodeResolve} from '@rollup/plugin-node-resolve' import {defineConfig} from '@sanity/pkg-utils' import fs from 'fs' import isBuiltin from 'is-builtin-module' import path from 'path' -import baseConfig from '../../../package.config' - const workersDir = path.join(__dirname, 'src', 'workers') const workerNames = fs @@ -40,15 +39,18 @@ export default defineConfig({ { source: './src/cli.ts', require: './lib/cli.js', + runtime: 'node', }, { source: './src/run.ts', require: './lib/run.js', + runtime: 'node', }, ...workerNames.map((name) => ({ source: `./src/workers/${name}.ts`, require: `./lib/workers/${name}.js`, + runtime: 'node' as const, })), ], diff --git a/packages/@sanity/cli/package.json b/packages/@sanity/cli/package.json index 46ff5e1b67f..5f24e5fcc36 100644 --- a/packages/@sanity/cli/package.json +++ b/packages/@sanity/cli/package.json @@ -22,24 +22,20 @@ }, "license": "MIT", "author": "Sanity.io ", + "sideEffects": false, "exports": { ".": { - "types": "./lib/dts/src/index.d.ts", "source": "./src/index.ts", + "import": "./lib/index.mjs", "require": "./lib/index.js", - "node": { - "module": "./lib/index.esm.js", - "import": "./lib/index.cjs.mjs" - }, - "import": "./lib/index.esm.js", - "default": "./lib/index.esm.js" + "default": "./lib/index.js" }, "./package.json": "./package.json" }, "main": "./lib/index.js", "module": "./lib/index.esm.js", "source": "./src/index.ts", - "types": "./lib/dts/src/index.d.ts", + "types": "./lib/index.d.ts", "bin": { "sanity": "./bin/sanity" }, @@ -51,22 +47,24 @@ "templates" ], "scripts": { - "prebuild": "run-s clean", - "build": "pkg-utils build --tsconfig tsconfig.lib.json", - "postbuild": "run-s check:package", - "check:package": "pkg-utils --strict --tsconfig tsconfig.lib.json", + "build": "run-s clean && pkg-utils build --strict", + "check:package": "pkg-utils --strict", + "check:types": "tsc", "clean": "rimraf lib", "lint": "eslint .", + "prepublishOnly": "turbo run build", "test": "jest", "ts": "node -r esbuild-register", - "watch": "pkg-utils watch --tsconfig tsconfig.lib.json" + "watch": "pkg-utils watch" }, "dependencies": { "@babel/traverse": "^7.23.5", + "@sanity/client": "^6.15.11", "@sanity/codegen": "3.36.4", "@sanity/telemetry": "^0.7.6", "@sanity/util": "3.36.4", "chalk": "^4.1.2", + "debug": "^4.3.4", "decompress": "^4.2.0", "esbuild": "^0.20.0", "esbuild-register": "^3.4.1", @@ -80,11 +78,12 @@ }, "devDependencies": { "@jest/globals": "^29.7.0", + "@repo/package.config": "workspace:*", "@rexxars/gitconfiglocal": "^3.0.1", "@rollup/plugin-node-resolve": "^15.2.3", - "@sanity/client": "^6.15.11", "@sanity/eslint-config-studio": "^3.0.1", "@sanity/generate-help-url": "^3.0.0", + "@sanity/types": "workspace:*", "@types/babel__traverse": "^7.20.5", "@types/configstore": "^5.0.1", "@types/cpx": "^1.5.2", @@ -106,7 +105,6 @@ "clean-stack": "^3.0.0", "configstore": "^5.0.1", "cpx": "^1.5.0", - "debug": "^4.3.4", "deep-sort-object": "^1.0.1", "dotenv": "^16.0.3", "dotenv-expand": "^9.0.0", diff --git a/packages/@sanity/cli/src/actions/init-project/initProject.ts b/packages/@sanity/cli/src/actions/init-project/initProject.ts index 2b73bf40f66..d8fad9b473b 100644 --- a/packages/@sanity/cli/src/actions/init-project/initProject.ts +++ b/packages/@sanity/cli/src/actions/init-project/initProject.ts @@ -4,8 +4,7 @@ import dotenv from 'dotenv' import execa, {type CommonOptions} from 'execa' import {existsSync, readFileSync} from 'fs' import fs from 'fs/promises' -import deburr from 'lodash/deburr' -import noop from 'lodash/noop' +import {deburr, noop} from 'lodash' import pFilter from 'p-filter' import path from 'path' import resolveFrom from 'resolve-from' diff --git a/packages/@sanity/cli/src/actions/init-project/reconfigureV2Project.ts b/packages/@sanity/cli/src/actions/init-project/reconfigureV2Project.ts index 37e4e1936b6..8b73525f933 100644 --- a/packages/@sanity/cli/src/actions/init-project/reconfigureV2Project.ts +++ b/packages/@sanity/cli/src/actions/init-project/reconfigureV2Project.ts @@ -1,5 +1,5 @@ import {type DatasetAclMode} from '@sanity/client' -import noop from 'lodash/noop' +import {noop} from 'lodash' import path from 'path' import {type InitFlags} from '../../commands/init/initCommand' diff --git a/packages/@sanity/cli/src/util/journeyConfig.ts b/packages/@sanity/cli/src/util/journeyConfig.ts index a4f2c43600e..e47e4873275 100644 --- a/packages/@sanity/cli/src/util/journeyConfig.ts +++ b/packages/@sanity/cli/src/util/journeyConfig.ts @@ -1,13 +1,13 @@ +import { + type BaseSchemaDefinition, + type DocumentDefinition, + type ObjectDefinition, +} from '@sanity/types' import fs from 'fs/promises' import path from 'path' import {format} from 'prettier' import {Worker} from 'worker_threads' -import { - type BaseSchemaDefinition, - type DocumentDefinition, - type ObjectDefinition, -} from '../../../types' import {type CliApiClient} from '../types' import {getCliWorkerPath} from './cliWorker' diff --git a/packages/@sanity/cli/templates/shared/tsconfig.json b/packages/@sanity/cli/templates/shared/tsconfig.json index dee6b84f246..e80574eea0a 100644 --- a/packages/@sanity/cli/templates/shared/tsconfig.json +++ b/packages/@sanity/cli/templates/shared/tsconfig.json @@ -7,10 +7,8 @@ "strict": true, "forceConsistentCasingInFileNames": true, "noEmit": true, - "esModuleInterop": true, - "module": "esnext", - "moduleResolution": "node", - "resolveJsonModule": true, + "module": "Preserve", + "moduleDetection": "force", "isolatedModules": true, "jsx": "preserve", "incremental": true diff --git a/packages/@sanity/cli/tsconfig.json b/packages/@sanity/cli/tsconfig.json index 45109ff61e8..357829b0689 100644 --- a/packages/@sanity/cli/tsconfig.json +++ b/packages/@sanity/cli/tsconfig.json @@ -1,20 +1,22 @@ { - "extends": "../../../tsconfig.settings", - "include": ["./src", "./test", "./typings", "./package.json"], - "exclude": ["./test/**/__fixtures__"], + "extends": "@repo/tsconfig/base.json", + "include": [ + "./src", + "./test", + "./typings", + "./package.json", + "./node_modules/@sanity/types/src", + "./node_modules/@sanity/util/src", + "./node_modules/@sanity/codegen/src" + ], + "exclude": ["./test/**/__fixtures__", "./node_modules/@sanity/codegen/src/typescript/__tests__"], "compilerOptions": { - "composite": true, "rootDir": ".", - "outDir": "./lib/dts", - - "checkJs": false, - "allowJs": true, - "jsx": "react-jsx", - "resolveJsonModule": true - }, - "references": [ - {"path": "../codegen/tsconfig.lib.json"}, - {"path": "../types/tsconfig.lib.json"}, - {"path": "../util/tsconfig.lib.json"} - ] + "paths": { + "@sanity/codegen": ["./node_modules/@sanity/codegen/src/_exports/index.ts"], + "@sanity/types": ["./node_modules/@sanity/types/src"], + "@sanity/util/*": ["./node_modules/@sanity/util/src/_exports/*"], + "@sanity/util": ["./node_modules/@sanity/util/src/_exports/index.ts"] + } + } } diff --git a/packages/@sanity/cli/tsconfig.lib.json b/packages/@sanity/cli/tsconfig.lib.json index 078136cfabc..2d4e25266d0 100644 --- a/packages/@sanity/cli/tsconfig.lib.json +++ b/packages/@sanity/cli/tsconfig.lib.json @@ -1,5 +1,5 @@ { - "extends": "../../../tsconfig.settings", + "extends": "@repo/tsconfig/build.json", "include": ["./src", "./typings", "./package.json"], "exclude": [ "./src/**/__fixtures__", @@ -9,18 +9,7 @@ "./src/**/*.test.tsx" ], "compilerOptions": { - "composite": true, "rootDir": ".", - "outDir": "./lib/dts", - - "checkJs": false, - "allowJs": true, - "jsx": "react-jsx", - "resolveJsonModule": true - }, - "references": [ - {"path": "../codegen/tsconfig.lib.json"}, - {"path": "../types/tsconfig.lib.json"}, - {"path": "../util/tsconfig.lib.json"} - ] + "outDir": "./lib" + } } diff --git a/packages/@sanity/codegen/.depcheckrc.json b/packages/@sanity/codegen/.depcheckrc.json index d2b37f0015c..35f1b4badf9 100644 --- a/packages/@sanity/codegen/.depcheckrc.json +++ b/packages/@sanity/codegen/.depcheckrc.json @@ -1,3 +1,3 @@ { - "ignores": ["@sanity/pkg-utils"] + "ignores": ["@repo/tsconfig", "@sanity/pkg-utils"] } diff --git a/packages/@sanity/codegen/package.config.ts b/packages/@sanity/codegen/package.config.ts index fc4cec4fc5c..c43051dd053 100644 --- a/packages/@sanity/codegen/package.config.ts +++ b/packages/@sanity/codegen/package.config.ts @@ -1,5 +1,4 @@ +import baseConfig from '@repo/package.config' import {defineConfig} from '@sanity/pkg-utils' -import baseConfig from '../../../package.config' - export default defineConfig(baseConfig) diff --git a/packages/@sanity/codegen/package.json b/packages/@sanity/codegen/package.json index c9bb6683b25..4c8bd0890c1 100644 --- a/packages/@sanity/codegen/package.json +++ b/packages/@sanity/codegen/package.json @@ -21,24 +21,20 @@ }, "license": "MIT", "author": "Sanity.io ", + "sideEffects": false, "exports": { ".": { - "types": "./lib/dts/src/_exports/index.d.ts", "source": "./src/_exports/index.ts", - "require": "./lib/_exports/index.js", - "node": { - "module": "./lib/_exports/index.esm.js", - "import": "./lib/_exports/index.cjs.mjs" - }, - "import": "./lib/_exports/index.esm.js", - "default": "./lib/_exports/index.esm.js" + "import": "./lib/index.mjs", + "require": "./lib/index.js", + "default": "./lib/index.js" }, "./package.json": "./package.json" }, - "main": "./lib/_exports/index.js", - "module": "./lib/_exports/index.esm.js", + "main": "./lib/index.js", + "module": "./lib/index.esm.js", "source": "./src/_exports/index.ts", - "types": "./lib/dts/src/_exports/index.d.ts", + "types": "./lib/index.d.ts", "files": [ "lib", "src", @@ -46,14 +42,14 @@ "babel.config.json" ], "scripts": { - "prebuild": "run-s clean", - "build": "pkg-utils build --tsconfig tsconfig.lib.json", - "postbuild": "run-s check:package", - "check:package": "pkg-utils --strict --tsconfig tsconfig.lib.json", + "build": "run-s clean && pkg-utils build --strict", + "check:package": "pkg-utils --strict", + "check:types": "tsc", "clean": "rimraf lib coverage", "lint": "eslint .", + "prepublishOnly": "turbo run build", "test": "jest", - "watch": "pkg-utils watch --tsconfig tsconfig.lib.json" + "watch": "pkg-utils watch" }, "dependencies": { "@babel/core": "^7.23.9", @@ -66,6 +62,7 @@ "@babel/types": "^7.23.9", "debug": "^4.3.4", "globby": "^10.0.0", + "groq": "workspace:*", "groq-js": "^1.7.0", "json5": "^2.2.3", "tsconfig-paths": "^4.2.0", @@ -73,12 +70,12 @@ }, "devDependencies": { "@jest/globals": "^29.7.0", + "@repo/package.config": "workspace:*", "@types/babel__core": "^7.20.5", "@types/babel__generator": "^7.6.8", "@types/babel__register": "^7.17.3", "@types/babel__traverse": "^7.20.5", "@types/debug": "^4.1.12", - "groq": "workspace:*", "rimraf": "^3.0.2" }, "engines": { diff --git a/packages/@sanity/codegen/tsconfig.json b/packages/@sanity/codegen/tsconfig.json index dfc2b88930a..bca0c640dec 100644 --- a/packages/@sanity/codegen/tsconfig.json +++ b/packages/@sanity/codegen/tsconfig.json @@ -1,12 +1,10 @@ { - "extends": "../../../tsconfig.settings", - "include": ["./src/**/*"], + "extends": "@repo/tsconfig/base.json", + "include": ["./src", "./node_modules/groq/src"], "compilerOptions": { - "composite": true, - "lib": ["ES2022.Error"], "rootDir": ".", - "outDir": "./lib/dts", - "declarationDir": "./lib/dts" - }, - "references": [{"path": "../types/tsconfig.lib.json"}, {"path": "../../groq/tsconfig.lib.json"}] + "paths": { + "groq": ["./node_modules/groq/src/groq.ts"] + } + } } diff --git a/packages/@sanity/codegen/tsconfig.lib.json b/packages/@sanity/codegen/tsconfig.lib.json index dfc2b88930a..39b69d4bb09 100644 --- a/packages/@sanity/codegen/tsconfig.lib.json +++ b/packages/@sanity/codegen/tsconfig.lib.json @@ -1,12 +1,8 @@ { - "extends": "../../../tsconfig.settings", - "include": ["./src/**/*"], + "extends": "@repo/tsconfig/build.json", + "include": ["./src"], "compilerOptions": { - "composite": true, - "lib": ["ES2022.Error"], "rootDir": ".", - "outDir": "./lib/dts", - "declarationDir": "./lib/dts" - }, - "references": [{"path": "../types/tsconfig.lib.json"}, {"path": "../../groq/tsconfig.lib.json"}] + "outDir": "./lib" + } } diff --git a/packages/@sanity/diff/.depcheckrc.json b/packages/@sanity/diff/.depcheckrc.json index d2b37f0015c..35f1b4badf9 100644 --- a/packages/@sanity/diff/.depcheckrc.json +++ b/packages/@sanity/diff/.depcheckrc.json @@ -1,3 +1,3 @@ { - "ignores": ["@sanity/pkg-utils"] + "ignores": ["@repo/tsconfig", "@sanity/pkg-utils"] } diff --git a/packages/@sanity/diff/package.config.ts b/packages/@sanity/diff/package.config.ts index 4477b03d52e..c43051dd053 100644 --- a/packages/@sanity/diff/package.config.ts +++ b/packages/@sanity/diff/package.config.ts @@ -1,5 +1,4 @@ +import baseConfig from '@repo/package.config' import {defineConfig} from '@sanity/pkg-utils' -import baseConfig from '../../../package.config' - -export default defineConfig({...baseConfig}) +export default defineConfig(baseConfig) diff --git a/packages/@sanity/diff/package.json b/packages/@sanity/diff/package.json index 26ee324d745..9e96773cf90 100644 --- a/packages/@sanity/diff/package.json +++ b/packages/@sanity/diff/package.json @@ -21,41 +21,38 @@ }, "license": "MIT", "author": "Sanity.io ", + "sideEffects": false, "exports": { ".": { - "types": "./lib/dts/src/index.d.ts", "source": "./src/index.ts", + "import": "./lib/index.mjs", "require": "./lib/index.js", - "node": { - "module": "./lib/index.esm.js", - "import": "./lib/index.cjs.mjs" - }, - "import": "./lib/index.esm.js", - "default": "./lib/index.esm.js" + "default": "./lib/index.js" }, "./package.json": "./package.json" }, "main": "./lib/index.js", "module": "./lib/index.esm.js", "source": "./src/index.ts", - "types": "./lib/dts/src/index.d.ts", + "types": "./lib/index.d.ts", "files": [ "lib", "src" ], "scripts": { - "prebuild": "run-s clean", - "build": "pkg-utils build --tsconfig tsconfig.lib.json", - "postbuild": "run-s check:package", - "check:package": "pkg-utils --strict --tsconfig tsconfig.lib.json", + "build": "run-s clean && pkg-utils build --strict", + "check:package": "pkg-utils --strict", + "check:types": "tsc", "clean": "rimraf lib coverage", "lint": "eslint .", - "watch": "pkg-utils watch --tsconfig tsconfig.lib.json" + "prepublishOnly": "turbo run build", + "watch": "pkg-utils watch" }, "dependencies": { "@sanity/diff-match-patch": "^3.1.1" }, "devDependencies": { + "@repo/package.config": "workspace:*", "rimraf": "^3.0.2" }, "engines": { diff --git a/packages/@sanity/diff/tsconfig.json b/packages/@sanity/diff/tsconfig.json index 7ba839796ac..bae57cee9a8 100644 --- a/packages/@sanity/diff/tsconfig.json +++ b/packages/@sanity/diff/tsconfig.json @@ -1,14 +1,7 @@ { - "extends": "../../../tsconfig.settings", + "extends": "@repo/tsconfig/base.json", "include": ["./src"], "compilerOptions": { - "composite": true, - "rootDir": ".", - "outDir": "./lib/dts", - "declarationDir": "./lib/dts", - "jsx": "react-jsx", - - // todo: we need to disable noImplicitAny in a transition phase and should be removed eventually - "noImplicitAny": false + "rootDir": "." } } diff --git a/packages/@sanity/diff/tsconfig.lib.json b/packages/@sanity/diff/tsconfig.lib.json index 7ba839796ac..39b69d4bb09 100644 --- a/packages/@sanity/diff/tsconfig.lib.json +++ b/packages/@sanity/diff/tsconfig.lib.json @@ -1,14 +1,8 @@ { - "extends": "../../../tsconfig.settings", + "extends": "@repo/tsconfig/build.json", "include": ["./src"], "compilerOptions": { - "composite": true, "rootDir": ".", - "outDir": "./lib/dts", - "declarationDir": "./lib/dts", - "jsx": "react-jsx", - - // todo: we need to disable noImplicitAny in a transition phase and should be removed eventually - "noImplicitAny": false + "outDir": "./lib" } } diff --git a/packages/@sanity/migrate/.depcheckrc.json b/packages/@sanity/migrate/.depcheckrc.json index d2b37f0015c..35f1b4badf9 100644 --- a/packages/@sanity/migrate/.depcheckrc.json +++ b/packages/@sanity/migrate/.depcheckrc.json @@ -1,3 +1,3 @@ { - "ignores": ["@sanity/pkg-utils"] + "ignores": ["@repo/tsconfig", "@sanity/pkg-utils"] } diff --git a/packages/@sanity/migrate/package.config.ts b/packages/@sanity/migrate/package.config.ts index fc4cec4fc5c..c43051dd053 100644 --- a/packages/@sanity/migrate/package.config.ts +++ b/packages/@sanity/migrate/package.config.ts @@ -1,5 +1,4 @@ +import baseConfig from '@repo/package.config' import {defineConfig} from '@sanity/pkg-utils' -import baseConfig from '../../../package.config' - export default defineConfig(baseConfig) diff --git a/packages/@sanity/migrate/package.json b/packages/@sanity/migrate/package.json index 651665dc50c..13875ea5163 100644 --- a/packages/@sanity/migrate/package.json +++ b/packages/@sanity/migrate/package.json @@ -22,45 +22,34 @@ }, "license": "MIT", "author": "Sanity.io ", + "sideEffects": false, "exports": { ".": { - "types": "./lib/dts/src/_exports/index.d.ts", "source": "./src/_exports/index.ts", - "require": "./lib/_exports/index.js", - "node": { - "module": "./lib/_exports/index.esm.js", - "import": "./lib/_exports/index.cjs.mjs" - }, - "import": "./lib/_exports/index.esm.js", - "default": "./lib/_exports/index.esm.js" + "import": "./lib/index.mjs", + "require": "./lib/index.js", + "default": "./lib/index.js" }, "./package.json": "./package.json" }, - "main": "./lib/_exports/index.js", - "module": "./lib/_exports/index.esm.js", + "main": "./lib/index.js", + "module": "./lib/index.esm.js", "source": "./src/_exports/index.ts", - "types": "./lib/dts/src/_exports/index.d.ts", - "typesVersions": { - "*": { - "mutations": [ - "./lib/dts/src/_exports/mutations.d.ts" - ] - } - }, + "types": "./lib/index.d.ts", "files": [ "lib", "src", "!**/__tests__/**" ], "scripts": { - "prebuild": "run-s clean", - "build": "pkg-utils build --tsconfig tsconfig.lib.json", - "postbuild": "run-s check:package", - "check:package": "pkg-utils --strict --tsconfig tsconfig.lib.json", + "build": "run-s clean && pkg-utils build --strict", + "check:package": "pkg-utils --strict", + "check:types": "tsc", "clean": "rimraf lib coverage", "lint": "eslint .", + "prepublishOnly": "turbo run build", "test": "jest", - "watch": "pkg-utils watch --tsconfig tsconfig.lib.json" + "watch": "pkg-utils watch" }, "dependencies": { "@bjoerge/mutiny": "^0.5.1", @@ -75,6 +64,7 @@ }, "devDependencies": { "@jest/globals": "^29.7.0", + "@repo/package.config": "workspace:*", "@types/arrify": "^2.0.1", "@types/debug": "^4.1.12", "rimraf": "^3.0.2" diff --git a/packages/@sanity/migrate/tsconfig.json b/packages/@sanity/migrate/tsconfig.json index 731860a1337..5e135c63fd4 100644 --- a/packages/@sanity/migrate/tsconfig.json +++ b/packages/@sanity/migrate/tsconfig.json @@ -1,11 +1,12 @@ { - "extends": "../../../tsconfig.settings", - "include": ["./src/**/*"], + "extends": "@repo/tsconfig/base.json", + "include": ["./src", "./node_modules/@sanity/types/src", "./node_modules/@sanity/util/src"], "compilerOptions": { - "composite": true, "rootDir": ".", - "outDir": "./lib/dts", - "declarationDir": "./lib/dts" - }, - "references": [{"path": "../@sanity/types/tsconfig.lib.json"}] + "paths": { + "@sanity/types": ["./node_modules/@sanity/types/src"], + "@sanity/util/*": ["./node_modules/@sanity/util/src/_exports/*"], + "@sanity/util": ["./node_modules/@sanity/util/src/_exports/index.ts"] + } + } } diff --git a/packages/@sanity/migrate/tsconfig.lib.json b/packages/@sanity/migrate/tsconfig.lib.json index cce946f5435..be9ffd6abe0 100644 --- a/packages/@sanity/migrate/tsconfig.lib.json +++ b/packages/@sanity/migrate/tsconfig.lib.json @@ -1,10 +1,8 @@ { - "extends": "../../../tsconfig.settings", + "extends": "@repo/tsconfig/build.json", "include": ["./src/**/*"], "compilerOptions": { - "composite": true, "rootDir": ".", - "outDir": "./lib/dts", - "declarationDir": "./lib/dts" + "outDir": "./lib" } } diff --git a/packages/@sanity/mutator/.depcheckrc.json b/packages/@sanity/mutator/.depcheckrc.json index d2b37f0015c..35f1b4badf9 100644 --- a/packages/@sanity/mutator/.depcheckrc.json +++ b/packages/@sanity/mutator/.depcheckrc.json @@ -1,3 +1,3 @@ { - "ignores": ["@sanity/pkg-utils"] + "ignores": ["@repo/tsconfig", "@sanity/pkg-utils"] } diff --git a/packages/@sanity/mutator/package.config.ts b/packages/@sanity/mutator/package.config.ts index 4477b03d52e..c43051dd053 100644 --- a/packages/@sanity/mutator/package.config.ts +++ b/packages/@sanity/mutator/package.config.ts @@ -1,5 +1,4 @@ +import baseConfig from '@repo/package.config' import {defineConfig} from '@sanity/pkg-utils' -import baseConfig from '../../../package.config' - -export default defineConfig({...baseConfig}) +export default defineConfig(baseConfig) diff --git a/packages/@sanity/mutator/package.json b/packages/@sanity/mutator/package.json index 44d009d121e..8fc0ac3995a 100644 --- a/packages/@sanity/mutator/package.json +++ b/packages/@sanity/mutator/package.json @@ -21,38 +21,34 @@ }, "license": "MIT", "author": "Sanity.io ", + "sideEffects": false, "exports": { ".": { - "types": "./lib/dts/src/index.d.ts", "source": "./src/index.ts", + "import": "./lib/index.mjs", "require": "./lib/index.js", - "node": { - "module": "./lib/index.esm.js", - "import": "./lib/index.cjs.mjs" - }, - "import": "./lib/index.esm.js", - "default": "./lib/index.esm.js" + "default": "./lib/index.js" }, "./package.json": "./package.json" }, "main": "./lib/index.js", "module": "./lib/index.esm.js", "source": "./src/index.ts", - "types": "./lib/dts/src/index.d.ts", + "types": "./lib/index.d.ts", "files": [ "lib", "src" ], "scripts": { - "prebuild": "run-s clean", - "build": "pkg-utils build --tsconfig tsconfig.lib.json", - "postbuild": "run-s check:package", - "check:package": "pkg-utils --strict --tsconfig tsconfig.lib.json", + "build": "run-s clean && pkg-utils build --strict", + "check:package": "pkg-utils --strict", + "check:types": "tsc", "clean": "rimraf lib", "lint": "eslint .", "perf": "node ./perf/run.js", + "prepublishOnly": "turbo run build", "test": "jest", - "watch": "pkg-utils watch --tsconfig tsconfig.lib.json" + "watch": "pkg-utils watch" }, "dependencies": { "@sanity/diff-match-patch": "^3.1.1", @@ -62,6 +58,7 @@ }, "devDependencies": { "@jest/globals": "^29.7.0", + "@repo/package.config": "workspace:*", "@sanity/types": "3.36.4", "@types/debug": "^4.1.5", "@types/lodash": "^4.14.149", diff --git a/packages/@sanity/mutator/tsconfig.json b/packages/@sanity/mutator/tsconfig.json index 3739464dcfa..7d43459a2ff 100644 --- a/packages/@sanity/mutator/tsconfig.json +++ b/packages/@sanity/mutator/tsconfig.json @@ -1,10 +1,10 @@ { - "extends": "../../../tsconfig.settings", - "include": ["./perf", "./src", "./test"], + "extends": "@repo/tsconfig/base.json", + "include": ["./perf", "./src", "./test", "./node_modules/@sanity/types/src"], "compilerOptions": { - "composite": true, - "declarationDir": "./lib/dts", "rootDir": ".", - "outDir": "./lib/dts" + "paths": { + "@sanity/types": ["./node_modules/@sanity/types/src"] + } } } diff --git a/packages/@sanity/mutator/tsconfig.lib.json b/packages/@sanity/mutator/tsconfig.lib.json index 9996d2f7227..66149ff3da1 100644 --- a/packages/@sanity/mutator/tsconfig.lib.json +++ b/packages/@sanity/mutator/tsconfig.lib.json @@ -1,5 +1,5 @@ { - "extends": "../../../tsconfig.settings", + "extends": "@repo/tsconfig/build.json", "include": ["./src"], "exclude": [ "./src/**/__fixtures__", @@ -9,9 +9,7 @@ "./src/**/*.test.tsx" ], "compilerOptions": { - "composite": true, "rootDir": ".", - "outDir": "./lib/dts", - "declarationDir": "./lib/dts" + "outDir": "./lib" } } diff --git a/packages/@sanity/portable-text-editor/.depcheckrc.json b/packages/@sanity/portable-text-editor/.depcheckrc.json index 12b75c3185e..3b754900443 100644 --- a/packages/@sanity/portable-text-editor/.depcheckrc.json +++ b/packages/@sanity/portable-text-editor/.depcheckrc.json @@ -1,3 +1,3 @@ { - "ignores": ["@sanity/pkg-utils", "ws", "@types/jest"] + "ignores": ["@repo/tsconfig", "@sanity/pkg-utils", "ws", "@types/jest"] } diff --git a/packages/@sanity/portable-text-editor/package.config.ts b/packages/@sanity/portable-text-editor/package.config.ts index 4477b03d52e..c43051dd053 100644 --- a/packages/@sanity/portable-text-editor/package.config.ts +++ b/packages/@sanity/portable-text-editor/package.config.ts @@ -1,5 +1,4 @@ +import baseConfig from '@repo/package.config' import {defineConfig} from '@sanity/pkg-utils' -import baseConfig from '../../../package.config' - -export default defineConfig({...baseConfig}) +export default defineConfig(baseConfig) diff --git a/packages/@sanity/portable-text-editor/package.json b/packages/@sanity/portable-text-editor/package.json index 0804321d1a2..fa8087dd75d 100644 --- a/packages/@sanity/portable-text-editor/package.json +++ b/packages/@sanity/portable-text-editor/package.json @@ -27,41 +27,37 @@ }, "license": "MIT", "author": "Sanity.io ", + "sideEffects": false, "exports": { ".": { - "types": "./lib/dts/src/index.d.ts", "source": "./src/index.ts", + "import": "./lib/index.mjs", "require": "./lib/index.js", - "node": { - "module": "./lib/index.esm.js", - "import": "./lib/index.cjs.mjs" - }, - "import": "./lib/index.esm.js", - "default": "./lib/index.esm.js" + "default": "./lib/index.js" }, "./package.json": "./package.json" }, "main": "./lib/index.js", "module": "./lib/index.esm.js", "source": "./src/index.ts", - "types": "./lib/dts/src/index.d.ts", + "types": "./lib/index.d.ts", "files": [ "lib", "src" ], "scripts": { - "prebuild": "run-s clean", - "build": "pkg-utils build --tsconfig tsconfig.lib.json", - "postbuild": "run-s check:package", - "check:package": "pkg-utils --strict --tsconfig tsconfig.lib.json", + "build": "run-s clean && pkg-utils build --strict", + "check:package": "pkg-utils --strict", + "check:types": "tsc", "clean": "rimraf lib", "dev": "cd ./e2e-tests/ && ts-node serve", "lint": "eslint .", + "prepublishOnly": "turbo run build", "prettier": "prettier --write './**/*.{ts,tsx,js,css,html}'", "test": "jest", "test:e2e": "jest --config=e2e-tests/e2e.config.cjs", "test:watch": "jest --watch", - "watch": "pkg-utils watch --tsconfig tsconfig.lib.json" + "watch": "pkg-utils watch" }, "dependencies": { "@sanity/block-tools": "3.36.4", @@ -78,6 +74,7 @@ "@jest/globals": "^29.7.0", "@playwright/test": "1.41.2", "@portabletext/toolkit": "^2.0.14", + "@repo/package.config": "workspace:*", "@sanity/diff-match-patch": "^3.1.1", "@sanity/ui": "^2.1.0", "@testing-library/react": "^13.4.0", diff --git a/packages/@sanity/portable-text-editor/tsconfig.json b/packages/@sanity/portable-text-editor/tsconfig.json index af6a1cffae3..1a6d0a3f39e 100644 --- a/packages/@sanity/portable-text-editor/tsconfig.json +++ b/packages/@sanity/portable-text-editor/tsconfig.json @@ -1,18 +1,25 @@ { - "extends": "../../../tsconfig.settings", - "include": ["./src", "./test"], + "extends": "@repo/tsconfig/base.json", + "include": [ + "./src", + "./test", + "./node_modules/@sanity/types/src", + "./node_modules/@sanity/schema/src", + "./node_modules/@sanity/schema/typings", + "./node_modules/@sanity/util/src", + "./node_modules/@sanity/block-tools/src" + ], "compilerOptions": { - "composite": true, "rootDir": ".", - "outDir": "./lib/dts", + "paths": { + "@sanity/block-tools": ["./node_modules/@sanity/block-tools/src/index.ts"], + "@sanity/schema/*": ["./node_modules/@sanity/schema/src/_exports/*"], + "@sanity/schema": ["./node_modules/@sanity/schema/src/_exports/index.ts"], + "@sanity/types": ["./node_modules/@sanity/types/src"], + "@sanity/util/*": ["./node_modules/@sanity/util/src/_exports/*"], + "@sanity/util": ["./node_modules/@sanity/util/src/_exports/index.ts"] + }, - "jsx": "react-jsx", "isolatedModules": false - }, - "references": [ - {"path": "../block-tools/tsconfig.lib.json"}, - {"path": "../schema/tsconfig.lib.json"}, - {"path": "../types/tsconfig.lib.json"}, - {"path": "../util/tsconfig.lib.json"} - ] + } } diff --git a/packages/@sanity/portable-text-editor/tsconfig.lib.json b/packages/@sanity/portable-text-editor/tsconfig.lib.json index 60ac44241fa..ff5b1fe6308 100644 --- a/packages/@sanity/portable-text-editor/tsconfig.lib.json +++ b/packages/@sanity/portable-text-editor/tsconfig.lib.json @@ -1,18 +1,10 @@ { - "extends": "../../../tsconfig.settings", + "extends": "@repo/tsconfig/build.json", "include": ["./src"], "compilerOptions": { - "composite": true, "rootDir": ".", - "outDir": "./lib/dts", + "outDir": "./lib", - "jsx": "react-jsx", "isolatedModules": false - }, - "references": [ - {"path": "../block-tools/tsconfig.lib.json"}, - {"path": "../schema/tsconfig.lib.json"}, - {"path": "../types/tsconfig.lib.json"}, - {"path": "../util/tsconfig.lib.json"} - ] + } } diff --git a/packages/@sanity/schema/.depcheckrc.json b/packages/@sanity/schema/.depcheckrc.json index d2b37f0015c..f05b0634d43 100644 --- a/packages/@sanity/schema/.depcheckrc.json +++ b/packages/@sanity/schema/.depcheckrc.json @@ -1,3 +1,3 @@ { - "ignores": ["@sanity/pkg-utils"] + "ignores": ["@repo/tsconfig", "@sanity/pkg-utils", "@types/react"] } diff --git a/packages/@sanity/schema/package.config.ts b/packages/@sanity/schema/package.config.ts index 4477b03d52e..c43051dd053 100644 --- a/packages/@sanity/schema/package.config.ts +++ b/packages/@sanity/schema/package.config.ts @@ -1,5 +1,4 @@ +import baseConfig from '@repo/package.config' import {defineConfig} from '@sanity/pkg-utils' -import baseConfig from '../../../package.config' - -export default defineConfig({...baseConfig}) +export default defineConfig(baseConfig) diff --git a/packages/@sanity/schema/package.json b/packages/@sanity/schema/package.json index c8caaf29d62..9d550366cc9 100644 --- a/packages/@sanity/schema/package.json +++ b/packages/@sanity/schema/package.json @@ -21,39 +21,30 @@ }, "license": "MIT", "author": "Sanity.io ", + "sideEffects": false, "exports": { ".": { - "types": "./lib/dts/src/_exports/index.d.ts", "source": "./src/_exports/index.ts", - "require": "./lib/_exports/index.js", - "node": { - "module": "./lib/_exports/index.esm.js", - "import": "./lib/_exports/index.cjs.mjs" - }, - "import": "./lib/_exports/index.esm.js", - "default": "./lib/_exports/index.esm.js" + "import": "./lib/index.mjs", + "require": "./lib/index.js", + "default": "./lib/index.js" }, "./_internal": { - "types": "./lib/dts/src/_exports/_internal.d.ts", "source": "./src/_exports/_internal.ts", - "require": "./lib/_exports/_internal.js", - "node": { - "module": "./lib/_exports/_internal.esm.js", - "import": "./lib/_exports/_internal.cjs.mjs" - }, - "import": "./lib/_exports/_internal.esm.js", - "default": "./lib/_exports/_internal.esm.js" + "import": "./lib/_internal.mjs", + "require": "./lib/_internal.js", + "default": "./lib/_internal.js" }, "./package.json": "./package.json" }, - "main": "./lib/_exports/index.js", - "module": "./lib/_exports/index.esm.js", + "main": "./lib/index.js", + "module": "./lib/index.esm.js", "source": "./src/_exports/index.ts", - "types": "./lib/dts/src/_exports/index.d.ts", + "types": "./lib/index.d.ts", "typesVersions": { "*": { "_internal": [ - "./lib/dts/src/_exports/_internal.d.ts" + "./lib/_internal.d.ts" ] } }, @@ -63,15 +54,15 @@ "src" ], "scripts": { - "prebuild": "run-s clean", - "build": "pkg-utils build --tsconfig tsconfig.lib.json", - "postbuild": "run-s check:package", - "check:package": "pkg-utils --tsconfig tsconfig.lib.json", + "build": "run-s clean && pkg-utils build --strict", + "check:package": "pkg-utils --strict", + "check:types": "tsc", "clean": "rimraf _internal.js lib", "lint": "eslint .", + "prepublishOnly": "turbo run build", "test": "jest", "test:watch": "jest --watchAll", - "watch": "pkg-utils watch --tsconfig tsconfig.lib.json" + "watch": "pkg-utils watch" }, "dependencies": { "@sanity/generate-help-url": "^3.0.0", @@ -85,9 +76,11 @@ }, "devDependencies": { "@jest/globals": "^29.7.0", + "@repo/package.config": "workspace:*", "@sanity/icons": "^2.11.7", "@types/arrify": "^1.0.4", "@types/object-inspect": "^1.13.0", + "@types/react": "^18.2.74", "rimraf": "^3.0.2" } } diff --git a/packages/@sanity/schema/src/sanity/validation/types/array.ts b/packages/@sanity/schema/src/sanity/validation/types/array.ts index b05c2bfaa5b..af17aadcfa9 100644 --- a/packages/@sanity/schema/src/sanity/validation/types/array.ts +++ b/packages/@sanity/schema/src/sanity/validation/types/array.ts @@ -1,4 +1,3 @@ -// @ts-expect-error - add typings for humanize-list import humanizeList from 'humanize-list' import {flatten, partition} from 'lodash' diff --git a/packages/@sanity/schema/src/sanity/validation/types/block.ts b/packages/@sanity/schema/src/sanity/validation/types/block.ts index bcdd0ed46c8..0d76d8978e1 100644 --- a/packages/@sanity/schema/src/sanity/validation/types/block.ts +++ b/packages/@sanity/schema/src/sanity/validation/types/block.ts @@ -1,4 +1,3 @@ -// @ts-expect-error - add typings for humanize-list import humanizeList from 'humanize-list' import {isPlainObject, omit} from 'lodash' diff --git a/packages/@sanity/schema/src/sanity/validation/utils/validateTypeName.ts b/packages/@sanity/schema/src/sanity/validation/utils/validateTypeName.ts index 3bebfa59475..4ae52d09a6f 100644 --- a/packages/@sanity/schema/src/sanity/validation/utils/validateTypeName.ts +++ b/packages/@sanity/schema/src/sanity/validation/utils/validateTypeName.ts @@ -1,4 +1,3 @@ -// @ts-expect-error - add typings for humanize-list import humanize from 'humanize-list' import leven from 'leven' diff --git a/packages/@sanity/schema/test/extractSchema/extractSchema.test.ts b/packages/@sanity/schema/test/extractSchema/extractSchema.test.ts index 6cf7e4c10a9..d9dc463bcf7 100644 --- a/packages/@sanity/schema/test/extractSchema/extractSchema.test.ts +++ b/packages/@sanity/schema/test/extractSchema/extractSchema.test.ts @@ -531,7 +531,7 @@ describe('Extract schema test', () => { describe('Can extract sample fixtures', () => { const cases = Object.keys(schemaFixtures).map((schemaName) => { - const schema = createSchema(schemaFixtures[schemaName]) + const schema = createSchema((schemaFixtures as any)[schemaName]) if (schema._original.types.length === 0) { return {schemaName, schema: null} } diff --git a/packages/@sanity/schema/test/extractSchema/fixtures/block.ts b/packages/@sanity/schema/test/extractSchema/fixtures/block.ts index 12390f533c6..308357f24e5 100644 --- a/packages/@sanity/schema/test/extractSchema/fixtures/block.ts +++ b/packages/@sanity/schema/test/extractSchema/fixtures/block.ts @@ -7,7 +7,7 @@ const linkType = { { type: 'string', name: 'href', - validation: (Rule) => Rule.uri({scheme: ['http', 'https']}).required(), + validation: (Rule: any) => Rule.uri({scheme: ['http', 'https']}).required(), }, ], options: { diff --git a/packages/@sanity/schema/test/legacy/fixtures/schemas/blocks.ts b/packages/@sanity/schema/test/legacy/fixtures/schemas/blocks.ts index ca4cce78211..a80be340b06 100644 --- a/packages/@sanity/schema/test/legacy/fixtures/schemas/blocks.ts +++ b/packages/@sanity/schema/test/legacy/fixtures/schemas/blocks.ts @@ -139,7 +139,7 @@ export default { ], options: { - preview: (value) => { + preview: (value: any) => { return { title: value ? value.caption : '', } diff --git a/packages/@sanity/schema/test/legacy/fixtures/schemas/example-blog.ts b/packages/@sanity/schema/test/legacy/fixtures/schemas/example-blog.ts index 516b44d5974..bbf2e094d70 100644 --- a/packages/@sanity/schema/test/legacy/fixtures/schemas/example-blog.ts +++ b/packages/@sanity/schema/test/legacy/fixtures/schemas/example-blog.ts @@ -7,7 +7,7 @@ export default { options: { preview: { fields: ['title', 'image', 'imageUrl'], - prepare(document) { + prepare(document: any) { return { title: document.title || '', } diff --git a/packages/@sanity/schema/test/legacy/schemas.test.ts b/packages/@sanity/schema/test/legacy/schemas.test.ts index 7ee8b0b3ea1..82247e86824 100644 --- a/packages/@sanity/schema/test/legacy/schemas.test.ts +++ b/packages/@sanity/schema/test/legacy/schemas.test.ts @@ -3,7 +3,7 @@ import {expect, test} from '@jest/globals' import {Schema} from '../../src/legacy/Schema' import rawSchemas from './fixtures/schemas' -function parseSchema(schemaDef) { +function parseSchema(schemaDef: any) { const schema = new Schema(schemaDef) schema.getTypeNames().forEach((typeName) => { schema.get(typeName) @@ -12,6 +12,6 @@ function parseSchema(schemaDef) { Object.keys(rawSchemas).forEach((name) => { test(`Legacy schema ${name}`, () => { - expect(() => parseSchema(rawSchemas[name])).not.toThrow() + expect(() => parseSchema((rawSchemas as any)[name])).not.toThrow() }) }) diff --git a/packages/@sanity/schema/tsconfig.json b/packages/@sanity/schema/tsconfig.json index bf5370c503b..8d4a1d085ad 100644 --- a/packages/@sanity/schema/tsconfig.json +++ b/packages/@sanity/schema/tsconfig.json @@ -1,10 +1,10 @@ { - "extends": "../../../tsconfig.settings", - "include": ["./example", "./src"], + "extends": "@repo/tsconfig/base.json", + "include": ["./example", "./src", "./test", "./typings", "./node_modules/@sanity/types/src"], "compilerOptions": { - "composite": true, "rootDir": ".", - "outDir": "./lib/dts" - }, - "references": [{"path": "../types/tsconfig.lib.json"}] + "paths": { + "@sanity/types": ["./node_modules/@sanity/types/src"] + } + } } diff --git a/packages/@sanity/schema/tsconfig.lib.json b/packages/@sanity/schema/tsconfig.lib.json index bf5370c503b..18d75ddfa7f 100644 --- a/packages/@sanity/schema/tsconfig.lib.json +++ b/packages/@sanity/schema/tsconfig.lib.json @@ -1,10 +1,8 @@ { - "extends": "../../../tsconfig.settings", - "include": ["./example", "./src"], + "extends": "@repo/tsconfig/build.json", + "include": ["./example", "./src", "./typings"], "compilerOptions": { - "composite": true, "rootDir": ".", - "outDir": "./lib/dts" - }, - "references": [{"path": "../types/tsconfig.lib.json"}] + "outDir": "./lib" + } } diff --git a/packages/@sanity/schema/typings/humanize-list.d.ts b/packages/@sanity/schema/typings/humanize-list.d.ts new file mode 100644 index 00000000000..fa2773fe11e --- /dev/null +++ b/packages/@sanity/schema/typings/humanize-list.d.ts @@ -0,0 +1,4 @@ +declare module 'humanize-list' { + const humanizeList: (list: any[], options?: {conjunction?: string}) => string + export = humanizeList +} diff --git a/packages/@sanity/types/.depcheckrc.json b/packages/@sanity/types/.depcheckrc.json index 1252e03b899..10cd9026ee0 100644 --- a/packages/@sanity/types/.depcheckrc.json +++ b/packages/@sanity/types/.depcheckrc.json @@ -1,3 +1,3 @@ { - "ignores": ["@sanity/pkg-utils", "react", "_self_"] + "ignores": ["@repo/tsconfig", "@sanity/pkg-utils", "@sanity/types", "react"] } diff --git a/packages/@sanity/types/package.config.ts b/packages/@sanity/types/package.config.ts index 6457f9d2baa..ad0f35d569b 100644 --- a/packages/@sanity/types/package.config.ts +++ b/packages/@sanity/types/package.config.ts @@ -1,14 +1,13 @@ +import baseConfig from '@repo/package.config' import {defineConfig} from '@sanity/pkg-utils' -import baseConfig from '../../../package.config' - export default defineConfig({ ...baseConfig, extract: { ...baseConfig.extract, rules: { - ...baseConfig.extract?.rules, + ...baseConfig.extract.rules, 'ae-forgotten-export': 'error', 'ae-incompatible-release-tags': 'error', 'ae-missing-release-tag': 'error', diff --git a/packages/@sanity/types/package.json b/packages/@sanity/types/package.json index 121a82ff335..a6c2c615478 100644 --- a/packages/@sanity/types/package.json +++ b/packages/@sanity/types/package.json @@ -25,35 +25,30 @@ "sideEffects": false, "exports": { ".": { - "types": "./lib/dts/src/index.d.ts", "source": "./src/index.ts", + "import": "./lib/index.mjs", "require": "./lib/index.js", - "node": { - "module": "./lib/index.esm.js", - "import": "./lib/index.cjs.mjs" - }, - "import": "./lib/index.esm.js", - "default": "./lib/index.esm.js" + "default": "./lib/index.js" }, "./package.json": "./package.json" }, "main": "./lib/index.js", "module": "./lib/index.esm.js", "source": "./src/index.ts", - "types": "./lib/dts/src/index.d.ts", + "types": "./lib/index.d.ts", "files": [ "lib", "src" ], "scripts": { - "prebuild": "run-s clean", - "build": "pkg-utils build --tsconfig tsconfig.lib.json", - "postbuild": "run-s check:package", - "check:package": "pkg-utils --strict --tsconfig tsconfig.lib.json", + "build": "run-s clean && pkg-utils build --strict", + "check:package": "pkg-utils --strict", + "check:types": "tsc", "clean": "rimraf lib", + "prepublishOnly": "turbo run build", "test": "jest", "test:watch": "jest --watchAll", - "watch": "pkg-utils watch --tsconfig tsconfig.lib.json" + "watch": "pkg-utils watch" }, "dependencies": { "@sanity/client": "^6.15.11", @@ -61,6 +56,7 @@ }, "devDependencies": { "@jest/globals": "^29.7.0", + "@repo/package.config": "workspace:*", "rimraf": "^3.0.2" } } diff --git a/packages/@sanity/types/src/schema/test/alias.test.ts b/packages/@sanity/types/test/alias.test.ts similarity index 93% rename from packages/@sanity/types/src/schema/test/alias.test.ts rename to packages/@sanity/types/test/alias.test.ts index e9fb4953ddc..3717de4d5e1 100644 --- a/packages/@sanity/types/src/schema/test/alias.test.ts +++ b/packages/@sanity/types/test/alias.test.ts @@ -10,8 +10,8 @@ import { type ObjectOptions, type StringOptions, type TypeAliasDefinition, -} from '../definition' -import {defineArrayMember, defineField, defineType} from '../types' +} from '../src/schema/definition' +import {defineArrayMember, defineField, defineType} from '../src/schema/types' describe('alias type test', () => { it('should support narrowing alias types', () => { @@ -95,7 +95,6 @@ describe('alias type test', () => { }) it('should support alias with preview', () => { - //@ts-expect-error error is not in select keys defineType({ type: 'custom-object', name: 'redefined', @@ -106,7 +105,6 @@ describe('alias type test', () => { }, }) - //@ts-expect-error error is not in select keys defineField({ type: 'custom-object', name: 'redefined', @@ -117,7 +115,6 @@ describe('alias type test', () => { }, }) - //@ts-expect-error error is not in select keys defineArrayMember({ type: 'custom-object', name: 'redefined', diff --git a/packages/@sanity/types/src/schema/test/array.test.ts b/packages/@sanity/types/test/array.test.ts similarity index 97% rename from packages/@sanity/types/src/schema/test/array.test.ts rename to packages/@sanity/types/test/array.test.ts index fcefc9bceeb..0931a4aaf00 100644 --- a/packages/@sanity/types/src/schema/test/array.test.ts +++ b/packages/@sanity/types/test/array.test.ts @@ -1,11 +1,12 @@ import {describe, it} from '@jest/globals' + /* eslint-disable @typescript-eslint/no-unused-vars */ /** * Some of these tests have no expect statement; * use of ts-expect-error serves the same purpose - TypeScript is the testrunner here */ -import {type ArrayDefinition, type BooleanDefinition} from '../definition' -import {defineArrayMember, defineField, defineType} from '../types' +import {type ArrayDefinition, type BooleanDefinition} from '../src/schema/definition' +import {defineArrayMember, defineField, defineType} from '../src/schema/types' describe('array types', () => { describe('defineType', () => { diff --git a/packages/@sanity/types/src/schema/test/block.test.ts b/packages/@sanity/types/test/block.test.ts similarity index 95% rename from packages/@sanity/types/src/schema/test/block.test.ts rename to packages/@sanity/types/test/block.test.ts index 26f578685d0..ef03e058f88 100644 --- a/packages/@sanity/types/src/schema/test/block.test.ts +++ b/packages/@sanity/types/test/block.test.ts @@ -1,11 +1,12 @@ import {describe, it} from '@jest/globals' + /* eslint-disable @typescript-eslint/no-unused-vars */ /** * Some of these tests have no expect statement; * use of ts-expect-error serves the same purpose - TypeScript is the testrunner here */ -import {type BlockDefinition, type BooleanDefinition} from '../definition' -import {defineArrayMember, defineField, defineType} from '../types' +import {type BlockDefinition, type BooleanDefinition} from '../src/schema/definition' +import {defineArrayMember, defineField, defineType} from '../src/schema/types' describe('block types', () => { describe('defineType', () => { diff --git a/packages/@sanity/types/src/schema/test/boolean.test.ts b/packages/@sanity/types/test/boolean.test.ts similarity index 91% rename from packages/@sanity/types/src/schema/test/boolean.test.ts rename to packages/@sanity/types/test/boolean.test.ts index 1af00941204..c5148ea9f96 100644 --- a/packages/@sanity/types/src/schema/test/boolean.test.ts +++ b/packages/@sanity/types/test/boolean.test.ts @@ -1,11 +1,12 @@ import {describe, it} from '@jest/globals' + /* eslint-disable @typescript-eslint/no-unused-vars */ /** * Some of these tests have no expect statement; * use of ts-expect-error serves the same purpose - TypeScript is the testrunner here */ -import {type BooleanDefinition} from '../definition' -import {defineType} from '../types' +import {type BooleanDefinition} from '../src/schema/definition' +import {defineType} from '../src/schema/types' describe('boolean types', () => { describe('defineType', () => { diff --git a/packages/@sanity/types/src/schema/test/date.test.ts b/packages/@sanity/types/test/date.test.ts similarity index 92% rename from packages/@sanity/types/src/schema/test/date.test.ts rename to packages/@sanity/types/test/date.test.ts index 02c4b32d99b..f34eed4f260 100644 --- a/packages/@sanity/types/src/schema/test/date.test.ts +++ b/packages/@sanity/types/test/date.test.ts @@ -1,11 +1,12 @@ import {describe, it} from '@jest/globals' + /* eslint-disable @typescript-eslint/no-unused-vars */ /** * Some of these tests have no expect statement; * use of ts-expect-error serves the same purpose - TypeScript is the testrunner here */ -import {type DateDefinition, type StringDefinition} from '../definition' -import {defineField, defineType} from '../types' +import {type DateDefinition, type StringDefinition} from '../src/schema/definition' +import {defineField, defineType} from '../src/schema/types' describe('date types', () => { describe('defineType', () => { diff --git a/packages/@sanity/types/src/schema/test/datetime.test.ts b/packages/@sanity/types/test/datetime.test.ts similarity index 93% rename from packages/@sanity/types/src/schema/test/datetime.test.ts rename to packages/@sanity/types/test/datetime.test.ts index 4a65e140c5f..7e5a44d7ea3 100644 --- a/packages/@sanity/types/src/schema/test/datetime.test.ts +++ b/packages/@sanity/types/test/datetime.test.ts @@ -1,11 +1,12 @@ import {describe, it} from '@jest/globals' + /* eslint-disable @typescript-eslint/no-unused-vars */ /** * Some of these tests have no expect statement; * use of ts-expect-error serves the same purpose - TypeScript is the testrunner here */ -import {type DatetimeDefinition} from '../definition' -import {defineField, defineType} from '../types' +import {type DatetimeDefinition} from '../src/schema/definition' +import {defineField, defineType} from '../src/schema/types' describe('datetime types', () => { describe('defineType', () => { diff --git a/packages/@sanity/types/src/schema/test/document.test.ts b/packages/@sanity/types/test/document.test.ts similarity index 98% rename from packages/@sanity/types/src/schema/test/document.test.ts rename to packages/@sanity/types/test/document.test.ts index 1e33017e863..c7f6c9ce682 100644 --- a/packages/@sanity/types/src/schema/test/document.test.ts +++ b/packages/@sanity/types/test/document.test.ts @@ -1,11 +1,12 @@ import {describe, it} from '@jest/globals' + /* eslint-disable @typescript-eslint/no-unused-vars */ /** * Some of these tests have no expect statement; * use of ts-expect-error serves the same purpose - TypeScript is the testrunner here */ -import {type DocumentDefinition, type StringDefinition} from '../definition' -import {defineArrayMember, defineField, defineType} from '../types' +import {type DocumentDefinition, type StringDefinition} from '../src/schema/definition' +import {defineArrayMember, defineField, defineType} from '../src/schema/types' describe('document types', () => { describe('defineType', () => { diff --git a/packages/@sanity/types/src/schema/test/email.test.ts b/packages/@sanity/types/test/email.test.ts similarity index 88% rename from packages/@sanity/types/src/schema/test/email.test.ts rename to packages/@sanity/types/test/email.test.ts index a679a71ece8..0e58d2c96e1 100644 --- a/packages/@sanity/types/src/schema/test/email.test.ts +++ b/packages/@sanity/types/test/email.test.ts @@ -1,7 +1,8 @@ import {describe, it} from '@jest/globals' + /* eslint-disable @typescript-eslint/no-unused-vars */ -import {type BooleanDefinition, type EmailDefinition} from '../definition' -import {defineType} from '../types' +import {type BooleanDefinition, type EmailDefinition} from '../src/schema/definition' +import {defineType} from '../src/schema/types' describe('email types', () => { describe('defineType', () => { diff --git a/packages/@sanity/types/src/schema/test/file.test.ts b/packages/@sanity/types/test/file.test.ts similarity index 97% rename from packages/@sanity/types/src/schema/test/file.test.ts rename to packages/@sanity/types/test/file.test.ts index 284187d0b58..c24ddfcd783 100644 --- a/packages/@sanity/types/src/schema/test/file.test.ts +++ b/packages/@sanity/types/test/file.test.ts @@ -4,9 +4,9 @@ import {describe, it} from '@jest/globals' * Some of these tests have no expect statement; * use of ts-expect-error serves the same purpose - TypeScript is the testrunner here */ -import {type FileDefinition, type StringDefinition} from '_self_' +import {type FileDefinition, type StringDefinition} from '@sanity/types' -import {defineField, defineType} from '../types' +import {defineField, defineType} from '../src/schema/types' describe('file types', () => { describe('defineType', () => { diff --git a/packages/@sanity/types/src/schema/test/generic.test.tsx b/packages/@sanity/types/test/generic.test.tsx similarity index 97% rename from packages/@sanity/types/src/schema/test/generic.test.tsx rename to packages/@sanity/types/test/generic.test.tsx index 7b7d9deb995..22cd671e50c 100644 --- a/packages/@sanity/types/src/schema/test/generic.test.tsx +++ b/packages/@sanity/types/test/generic.test.tsx @@ -1,10 +1,11 @@ import {describe, it} from '@jest/globals' + /* eslint-disable @typescript-eslint/no-unused-vars */ /** * Some of these tests have no expect statement; * use of ts-expect-error serves the same purpose - TypeScript is the testrunner here */ -import {defineArrayMember, defineField, defineType} from '../types' +import {defineArrayMember, defineField, defineType} from '../src/schema/types' describe('common type test', () => { it('should capture literal string type', () => { diff --git a/packages/@sanity/types/src/schema/test/geopoint.test.ts b/packages/@sanity/types/test/geopoint.test.ts similarity index 94% rename from packages/@sanity/types/src/schema/test/geopoint.test.ts rename to packages/@sanity/types/test/geopoint.test.ts index 7a0ad03f577..6356e1a9bf2 100644 --- a/packages/@sanity/types/src/schema/test/geopoint.test.ts +++ b/packages/@sanity/types/test/geopoint.test.ts @@ -1,11 +1,12 @@ import {describe, it} from '@jest/globals' + /* eslint-disable @typescript-eslint/no-unused-vars */ /** * Some of these tests have no expect statement; * use of ts-expect-error serves the same purpose - TypeScript is the testrunner here */ -import {type GeopointDefinition, type StringDefinition} from '../definition' -import {defineType} from '../types' +import {type GeopointDefinition, type StringDefinition} from '../src/schema/definition' +import {defineType} from '../src/schema/types' describe('geopoint types', () => { describe('defineType', () => { diff --git a/packages/@sanity/types/src/schema/test/image.test.ts b/packages/@sanity/types/test/image.test.ts similarity index 97% rename from packages/@sanity/types/src/schema/test/image.test.ts rename to packages/@sanity/types/test/image.test.ts index 159e95279ee..c16a3c44b72 100644 --- a/packages/@sanity/types/src/schema/test/image.test.ts +++ b/packages/@sanity/types/test/image.test.ts @@ -1,11 +1,12 @@ import {describe, it} from '@jest/globals' + /* eslint-disable @typescript-eslint/no-unused-vars */ /** * Some of these tests have no expect statement; * use of ts-expect-error serves the same purpose - TypeScript is the testrunner here */ -import {type ImageDefinition} from '../definition' -import {defineField, defineType} from '../types' +import {type ImageDefinition} from '../src/schema/definition' +import {defineField, defineType} from '../src/schema/types' describe('image types', () => { it('should define image schema', () => { diff --git a/packages/@sanity/types/src/schema/test/number.test.ts b/packages/@sanity/types/test/number.test.ts similarity index 93% rename from packages/@sanity/types/src/schema/test/number.test.ts rename to packages/@sanity/types/test/number.test.ts index 9cd156891fb..8b890c5bb93 100644 --- a/packages/@sanity/types/src/schema/test/number.test.ts +++ b/packages/@sanity/types/test/number.test.ts @@ -1,11 +1,12 @@ import {describe, it} from '@jest/globals' + /* eslint-disable @typescript-eslint/no-unused-vars */ /** * Some of these tests have no expect statement; * use of ts-expect-error serves the same purpose - TypeScript is the testrunner here */ -import {type NumberDefinition, type StringDefinition} from '../definition' -import {defineField, defineType} from '../types' +import {type NumberDefinition, type StringDefinition} from '../src/schema/definition' +import {defineField, defineType} from '../src/schema/types' describe('number types', () => { describe('defineType', () => { diff --git a/packages/@sanity/types/src/schema/test/object.test.ts b/packages/@sanity/types/test/object.test.ts similarity index 96% rename from packages/@sanity/types/src/schema/test/object.test.ts rename to packages/@sanity/types/test/object.test.ts index dba5e2b0f02..39d891d9ed0 100644 --- a/packages/@sanity/types/src/schema/test/object.test.ts +++ b/packages/@sanity/types/test/object.test.ts @@ -1,11 +1,12 @@ import {describe, it} from '@jest/globals' + /* eslint-disable @typescript-eslint/no-unused-vars */ /** * Some of these tests have no expect statement; * use of ts-expect-error serves the same purpose - TypeScript is the testrunner here */ -import {type ObjectDefinition, type StringDefinition} from '../definition' -import {defineField, defineType} from '../types' +import {type ObjectDefinition, type StringDefinition} from '../src/schema/definition' +import {defineField, defineType} from '../src/schema/types' describe('object types', () => { it('should define object schema', () => { diff --git a/packages/@sanity/types/src/schema/test/reference.test.ts b/packages/@sanity/types/test/reference.test.ts similarity index 97% rename from packages/@sanity/types/src/schema/test/reference.test.ts rename to packages/@sanity/types/test/reference.test.ts index ffd036b1d9e..8d428d68648 100644 --- a/packages/@sanity/types/src/schema/test/reference.test.ts +++ b/packages/@sanity/types/test/reference.test.ts @@ -1,11 +1,12 @@ import {describe, it} from '@jest/globals' + /* eslint-disable @typescript-eslint/no-unused-vars */ /** * Some of these tests have no expect statement; * use of ts-expect-error serves the same purpose - TypeScript is the testrunner here */ -import {type BooleanDefinition, type ReferenceDefinition} from '../definition' -import {defineType} from '../types' +import {type BooleanDefinition, type ReferenceDefinition} from '../src/schema/definition' +import {defineType} from '../src/schema/types' describe('reference types', () => { describe('defineType', () => { diff --git a/packages/@sanity/types/src/schema/test/slug.test.ts b/packages/@sanity/types/test/slug.test.ts similarity index 91% rename from packages/@sanity/types/src/schema/test/slug.test.ts rename to packages/@sanity/types/test/slug.test.ts index 125fdf02919..0b3cd8f5af7 100644 --- a/packages/@sanity/types/src/schema/test/slug.test.ts +++ b/packages/@sanity/types/test/slug.test.ts @@ -1,11 +1,12 @@ import {describe, it} from '@jest/globals' + /* eslint-disable @typescript-eslint/no-unused-vars */ /** * Some of these tests have no expect statement; * use of ts-expect-error serves the same purpose - TypeScript is the testrunner here */ -import {type SlugDefinition, type StringDefinition} from '../definition' -import {defineType} from '../types' +import {type SlugDefinition, type StringDefinition} from '../src/schema/definition' +import {defineType} from '../src/schema/types' describe('slug types', () => { describe('defineType', () => { diff --git a/packages/@sanity/types/src/schema/test/string.test.ts b/packages/@sanity/types/test/string.test.ts similarity index 97% rename from packages/@sanity/types/src/schema/test/string.test.ts rename to packages/@sanity/types/test/string.test.ts index aa9261676fa..843defd403b 100644 --- a/packages/@sanity/types/src/schema/test/string.test.ts +++ b/packages/@sanity/types/test/string.test.ts @@ -1,4 +1,5 @@ import {describe, it} from '@jest/globals' + /* eslint-disable @typescript-eslint/no-unused-vars */ /** * Some of these tests have no expect statement; @@ -9,8 +10,8 @@ import { type FieldDefinition, type FieldDefinitionBase, type StringDefinition, -} from '../definition' -import {defineField, defineType} from '../types' +} from '../src/schema/definition' +import {defineField, defineType} from '../src/schema/types' describe('string types', () => { describe('defineType', () => { diff --git a/packages/@sanity/types/src/schema/test/text.test.ts b/packages/@sanity/types/test/text.test.ts similarity index 92% rename from packages/@sanity/types/src/schema/test/text.test.ts rename to packages/@sanity/types/test/text.test.ts index 0ebcf811fe1..9dc7c9dc2a1 100644 --- a/packages/@sanity/types/src/schema/test/text.test.ts +++ b/packages/@sanity/types/test/text.test.ts @@ -1,11 +1,12 @@ import {describe, it} from '@jest/globals' + /* eslint-disable @typescript-eslint/no-unused-vars */ /** * Some of these tests have no expect statement; * use of ts-expect-error serves the same purpose - TypeScript is the testrunner here */ -import {type BooleanDefinition, type TextDefinition} from '../definition' -import {defineType} from '../types' +import {type BooleanDefinition, type TextDefinition} from '../src/schema/definition' +import {defineType} from '../src/schema/types' describe('text types', () => { describe('defineType', () => { diff --git a/packages/@sanity/types/src/schema/test/typeMerge.test.ts b/packages/@sanity/types/test/typeMerge.test.ts similarity index 91% rename from packages/@sanity/types/src/schema/test/typeMerge.test.ts rename to packages/@sanity/types/test/typeMerge.test.ts index 32b18d9ae2c..6b457a8e344 100644 --- a/packages/@sanity/types/src/schema/test/typeMerge.test.ts +++ b/packages/@sanity/types/test/typeMerge.test.ts @@ -1,9 +1,9 @@ import {describe, it} from '@jest/globals' -import {type ExtensionTypeExampleDef, type ObjectDefinition} from '../definition' -import {defineType} from '../types' +import {type ExtensionTypeExampleDef, type ObjectDefinition} from '../src/schema/definition' +import {defineType} from '../src/schema/types' -declare module '../definition' { +declare module '../src/schema/definition' { // here we type up our custom schema definition // eslint-disable-next-line @typescript-eslint/no-shadow export type ExtensionTypeExampleDef = Omit & { diff --git a/packages/@sanity/types/src/schema/test/url.test.ts b/packages/@sanity/types/test/url.test.ts similarity index 91% rename from packages/@sanity/types/src/schema/test/url.test.ts rename to packages/@sanity/types/test/url.test.ts index e95800a7c1c..2eab9bd0d49 100644 --- a/packages/@sanity/types/src/schema/test/url.test.ts +++ b/packages/@sanity/types/test/url.test.ts @@ -1,11 +1,12 @@ import {describe, it} from '@jest/globals' + /* eslint-disable @typescript-eslint/no-unused-vars */ /** * Some of these tests have no expect statement; * use of ts-expect-error serves the same purpose - TypeScript is the testrunner here */ -import {type BooleanDefinition, type UrlDefinition} from '../definition' -import {defineType} from '../types' +import {type BooleanDefinition, type UrlDefinition} from '../src/schema/definition' +import {defineType} from '../src/schema/types' describe('url types', () => { describe('defineType', () => { diff --git a/packages/@sanity/types/tsconfig.json b/packages/@sanity/types/tsconfig.json index 4c8d9cabccd..364badf82ba 100644 --- a/packages/@sanity/types/tsconfig.json +++ b/packages/@sanity/types/tsconfig.json @@ -1,14 +1,10 @@ { - "extends": "../../../tsconfig.settings", - "include": ["./src"], + "extends": "@repo/tsconfig/base.json", + "include": ["./src", "test"], "compilerOptions": { - "composite": true, "rootDir": ".", - "outDir": "./lib/dts", - - "jsx": "react-jsx", "paths": { - "_self_": ["./src"] + "@sanity/types": ["./src/index.ts"] } } } diff --git a/packages/@sanity/types/tsconfig.lib.json b/packages/@sanity/types/tsconfig.lib.json index 4c8d9cabccd..e32d481b17b 100644 --- a/packages/@sanity/types/tsconfig.lib.json +++ b/packages/@sanity/types/tsconfig.lib.json @@ -1,14 +1,9 @@ { - "extends": "../../../tsconfig.settings", + "extends": "@repo/tsconfig/build.json", "include": ["./src"], + "exclude": ["./src/schema/test"], "compilerOptions": { - "composite": true, "rootDir": ".", - "outDir": "./lib/dts", - - "jsx": "react-jsx", - "paths": { - "_self_": ["./src"] - } + "outDir": "./lib" } } diff --git a/packages/@sanity/util/.depcheckrc.json b/packages/@sanity/util/.depcheckrc.json index d2b37f0015c..35f1b4badf9 100644 --- a/packages/@sanity/util/.depcheckrc.json +++ b/packages/@sanity/util/.depcheckrc.json @@ -1,3 +1,3 @@ { - "ignores": ["@sanity/pkg-utils"] + "ignores": ["@repo/tsconfig", "@sanity/pkg-utils"] } diff --git a/packages/@sanity/util/exports/client.ts b/packages/@sanity/util/exports/client.ts deleted file mode 100644 index ef0e2a1f6c6..00000000000 --- a/packages/@sanity/util/exports/client.ts +++ /dev/null @@ -1 +0,0 @@ -export * from '../src/client/concurrency-limiter' diff --git a/packages/@sanity/util/exports/concurrency-limiter.ts b/packages/@sanity/util/exports/concurrency-limiter.ts deleted file mode 100644 index 8117457defd..00000000000 --- a/packages/@sanity/util/exports/concurrency-limiter.ts +++ /dev/null @@ -1 +0,0 @@ -export * from '../src/concurrency-limiter' diff --git a/packages/@sanity/util/exports/content.ts b/packages/@sanity/util/exports/content.ts deleted file mode 100644 index 56e7293411d..00000000000 --- a/packages/@sanity/util/exports/content.ts +++ /dev/null @@ -1 +0,0 @@ -export * from '../src/content' diff --git a/packages/@sanity/util/exports/createSafeJsonParser.ts b/packages/@sanity/util/exports/createSafeJsonParser.ts deleted file mode 100644 index 705b0a8c48d..00000000000 --- a/packages/@sanity/util/exports/createSafeJsonParser.ts +++ /dev/null @@ -1 +0,0 @@ -export * from '../src/createSafeJsonParser' diff --git a/packages/@sanity/util/exports/fs.ts b/packages/@sanity/util/exports/fs.ts deleted file mode 100644 index aa33ca98344..00000000000 --- a/packages/@sanity/util/exports/fs.ts +++ /dev/null @@ -1 +0,0 @@ -export * from '../src/fsTools' diff --git a/packages/@sanity/util/exports/legacyDateFormat.ts b/packages/@sanity/util/exports/legacyDateFormat.ts deleted file mode 100644 index b359482304e..00000000000 --- a/packages/@sanity/util/exports/legacyDateFormat.ts +++ /dev/null @@ -1 +0,0 @@ -export * from '../src/legacyDateFormat' diff --git a/packages/@sanity/util/exports/paths.ts b/packages/@sanity/util/exports/paths.ts deleted file mode 100644 index f5502925122..00000000000 --- a/packages/@sanity/util/exports/paths.ts +++ /dev/null @@ -1 +0,0 @@ -export * from '../src/paths' diff --git a/packages/@sanity/util/package.config.ts b/packages/@sanity/util/package.config.ts index 4477b03d52e..c43051dd053 100644 --- a/packages/@sanity/util/package.config.ts +++ b/packages/@sanity/util/package.config.ts @@ -1,5 +1,4 @@ +import baseConfig from '@repo/package.config' import {defineConfig} from '@sanity/pkg-utils' -import baseConfig from '../../../package.config' - -export default defineConfig({...baseConfig}) +export default defineConfig(baseConfig) diff --git a/packages/@sanity/util/package.json b/packages/@sanity/util/package.json index a287af037fc..d2fbdbf41a6 100644 --- a/packages/@sanity/util/package.json +++ b/packages/@sanity/util/package.json @@ -21,145 +21,106 @@ }, "license": "MIT", "author": "Sanity.io ", + "sideEffects": false, "exports": { ".": { - "types": "./lib/exports/index.d.ts", - "source": "./exports/index.ts", + "source": "./src/_exports/index.ts", + "import": "./lib/index.mjs", "require": "./lib/index.js", - "node": { - "module": "./lib/index.esm.js", - "import": "./lib/index.cjs.mjs" - }, - "import": "./lib/index.esm.js", - "default": "./lib/index.esm.js" + "default": "./lib/index.js" }, "./fs": { - "types": "./lib/exports/fs.d.ts", - "source": "./exports/fs.ts", + "source": "./src/_exports/fs.ts", + "import": "./lib/fs.mjs", "require": "./lib/fs.js", - "node": { - "module": "./lib/fs.esm.js", - "import": "./lib/fs.cjs.mjs" - }, - "import": "./lib/fs.esm.js", - "default": "./lib/fs.esm.js" + "default": "./lib/fs.js" }, "./client": { - "types": "./lib/exports/client.d.ts", - "source": "./exports/client.ts", + "source": "./src/_exports/client.ts", + "import": "./lib/client.mjs", "require": "./lib/client.js", - "node": { - "module": "./lib/client.esm.js", - "import": "./lib/client.cjs.mjs" - }, - "import": "./lib/client.esm.js", - "default": "./lib/client.esm.js" + "default": "./lib/client.js" }, "./concurrency-limiter": { - "types": "./lib/exports/concurrency-limiter.d.ts", - "source": "./exports/concurrency-limiter.ts", + "source": "./src/_exports/concurrency-limiter.ts", + "import": "./lib/concurrency-limiter.mjs", "require": "./lib/concurrency-limiter.js", - "node": { - "module": "./lib/concurrency-limiter.esm.js", - "import": "./lib/concurrency-limiter.cjs.mjs" - }, - "import": "./lib/concurrency-limiter.esm.js", - "default": "./lib/concurrency-limiter.esm.js" + "default": "./lib/concurrency-limiter.js" }, "./content": { - "types": "./lib/exports/content.d.ts", - "source": "./exports/content.ts", + "source": "./src/_exports/content.ts", + "import": "./lib/content.mjs", "require": "./lib/content.js", - "node": { - "module": "./lib/content.esm.js", - "import": "./lib/content.cjs.mjs" - }, - "import": "./lib/content.esm.js", - "default": "./lib/content.esm.js" + "default": "./lib/content.js" }, "./createSafeJsonParser": { - "types": "./lib/exports/createSafeJsonParser.d.ts", - "source": "./exports/createSafeJsonParser.ts", + "source": "./src/_exports/createSafeJsonParser.ts", + "import": "./lib/createSafeJsonParser.mjs", "require": "./lib/createSafeJsonParser.js", - "node": { - "module": "./lib/createSafeJsonParser.esm.js", - "import": "./lib/createSafeJsonParser.cjs.mjs" - }, - "import": "./lib/createSafeJsonParser.esm.js", - "default": "./lib/createSafeJsonParser.esm.js" + "default": "./lib/createSafeJsonParser.js" }, "./legacyDateFormat": { - "types": "./lib/exports/legacyDateFormat.d.ts", - "source": "./exports/legacyDateFormat.ts", + "source": "./src/_exports/legacyDateFormat.ts", + "import": "./lib/legacyDateFormat.mjs", "require": "./lib/legacyDateFormat.js", - "node": { - "module": "./lib/legacyDateFormat.esm.js", - "import": "./lib/legacyDateFormat.cjs.mjs" - }, - "import": "./lib/legacyDateFormat.esm.js", - "default": "./lib/legacyDateFormat.esm.js" + "default": "./lib/legacyDateFormat.js" }, "./paths": { - "types": "./lib/exports/paths.d.ts", - "source": "./exports/paths.ts", + "source": "./src/_exports/paths.ts", + "import": "./lib/paths.mjs", "require": "./lib/paths.js", - "node": { - "module": "./lib/paths.esm.js", - "import": "./lib/paths.cjs.mjs" - }, - "import": "./lib/paths.esm.js", - "default": "./lib/paths.esm.js" + "default": "./lib/paths.js" }, "./package.json": "./package.json" }, "main": "./lib/index.js", "module": "./lib/index.esm.js", - "source": "./exports/index.ts", - "types": "./lib/exports/index.d.ts", + "source": "./src/_exports/index.ts", + "types": "./lib/index.d.ts", "typesVersions": { "*": { "fs": [ - "./lib/exports/fs.d.ts" + "./lib/fs.d.ts" ], "client": [ - "./lib/exports/client.d.ts" + "./lib/client.d.ts" ], "concurrency-limiter": [ - "./lib/exports/concurrency-limiter.d.ts" + "./lib/concurrency-limiter.d.ts" ], "content": [ - "./lib/exports/content.d.ts" + "./lib/content.d.ts" ], "createSafeJsonParser": [ - "./lib/exports/createSafeJsonParser.d.ts" + "./lib/createSafeJsonParser.d.ts" ], "legacyDateFormat": [ - "./lib/exports/legacyDateFormat.d.ts" + "./lib/legacyDateFormat.d.ts" ], "paths": [ - "./lib/exports/paths.d.ts" + "./lib/paths.d.ts" ] } }, "files": [ + "lib", + "src", "client.js", "concurrency-limiter.js", "content.js", "createSafeJsonParser.js", "fs.js", "legacyDateFormat.js", - "lib", - "paths.js", - "src" + "paths.js" ], "scripts": { - "prebuild": "run-s clean", - "build": "pkg-utils build --tsconfig tsconfig.lib.json", - "postbuild": "run-s check:package", - "check:package": "pkg-utils --tsconfig tsconfig.lib.json", + "build": "run-s clean && pkg-utils build --strict", + "check:package": "pkg-utils --strict", + "check:types": "tsc", "clean": "rimraf client.js concurrency-limiter.js content.js createSafeJsonParser.js fs.js legacyDateFormat.js lib paths.js", + "prepublishOnly": "turbo run build", "test": "jest", - "watch": "pkg-utils watch --tsconfig tsconfig.lib.json" + "watch": "pkg-utils watch" }, "dependencies": { "@sanity/client": "^6.15.11", @@ -170,6 +131,7 @@ }, "devDependencies": { "@jest/globals": "^29.7.0", + "@repo/package.config": "workspace:*", "@types/moment": "^2.13.0", "rimraf": "^3.0.2" }, diff --git a/packages/@sanity/util/src/_exports/client.ts b/packages/@sanity/util/src/_exports/client.ts new file mode 100644 index 00000000000..9ffc7a95a71 --- /dev/null +++ b/packages/@sanity/util/src/_exports/client.ts @@ -0,0 +1 @@ +export * from '../client/concurrency-limiter' diff --git a/packages/@sanity/util/src/_exports/concurrency-limiter.ts b/packages/@sanity/util/src/_exports/concurrency-limiter.ts new file mode 100644 index 00000000000..3018d5da013 --- /dev/null +++ b/packages/@sanity/util/src/_exports/concurrency-limiter.ts @@ -0,0 +1 @@ +export * from '../concurrency-limiter' diff --git a/packages/@sanity/util/src/_exports/content.ts b/packages/@sanity/util/src/_exports/content.ts new file mode 100644 index 00000000000..0c2fad4ab90 --- /dev/null +++ b/packages/@sanity/util/src/_exports/content.ts @@ -0,0 +1 @@ +export * from '../content' diff --git a/packages/@sanity/util/src/_exports/createSafeJsonParser.ts b/packages/@sanity/util/src/_exports/createSafeJsonParser.ts new file mode 100644 index 00000000000..c1279228c8b --- /dev/null +++ b/packages/@sanity/util/src/_exports/createSafeJsonParser.ts @@ -0,0 +1 @@ +export * from '../createSafeJsonParser' diff --git a/packages/@sanity/util/src/_exports/fs.ts b/packages/@sanity/util/src/_exports/fs.ts new file mode 100644 index 00000000000..d8e83f95228 --- /dev/null +++ b/packages/@sanity/util/src/_exports/fs.ts @@ -0,0 +1 @@ +export * from '../fsTools' diff --git a/packages/@sanity/util/exports/index.ts b/packages/@sanity/util/src/_exports/index.ts similarity index 100% rename from packages/@sanity/util/exports/index.ts rename to packages/@sanity/util/src/_exports/index.ts diff --git a/packages/@sanity/util/src/_exports/legacyDateFormat.ts b/packages/@sanity/util/src/_exports/legacyDateFormat.ts new file mode 100644 index 00000000000..928b81e8dd4 --- /dev/null +++ b/packages/@sanity/util/src/_exports/legacyDateFormat.ts @@ -0,0 +1 @@ +export * from '../legacyDateFormat' diff --git a/packages/@sanity/util/src/_exports/paths.ts b/packages/@sanity/util/src/_exports/paths.ts new file mode 100644 index 00000000000..08b1a5aa446 --- /dev/null +++ b/packages/@sanity/util/src/_exports/paths.ts @@ -0,0 +1 @@ +export * from '../paths' diff --git a/packages/@sanity/util/tsconfig.json b/packages/@sanity/util/tsconfig.json index 261e2ea5541..4caca75d7dc 100644 --- a/packages/@sanity/util/tsconfig.json +++ b/packages/@sanity/util/tsconfig.json @@ -1,10 +1,10 @@ { - "extends": "../../../tsconfig.settings", - "include": ["./exports", "./src", "./test", "./typings"], + "extends": "@repo/tsconfig/base.json", + "include": ["./src", "./test", "./node_modules/@sanity/types/src"], "compilerOptions": { - "composite": true, "rootDir": ".", - "outDir": "./lib" - }, - "references": [{"path": "../types/tsconfig.lib.json"}] + "paths": { + "@sanity/types": ["./node_modules/@sanity/types/src"] + } + } } diff --git a/packages/@sanity/util/tsconfig.lib.json b/packages/@sanity/util/tsconfig.lib.json index e2799ec4d3a..66149ff3da1 100644 --- a/packages/@sanity/util/tsconfig.lib.json +++ b/packages/@sanity/util/tsconfig.lib.json @@ -1,6 +1,6 @@ { - "extends": "../../../tsconfig.settings", - "include": ["./exports", "./src", "./typings"], + "extends": "@repo/tsconfig/build.json", + "include": ["./src"], "exclude": [ "./src/**/__fixtures__", "./src/**/__mocks__", @@ -9,9 +9,7 @@ "./src/**/*.test.tsx" ], "compilerOptions": { - "composite": true, "rootDir": ".", "outDir": "./lib" - }, - "references": [{"path": "../types/tsconfig.lib.json"}] + } } diff --git a/packages/@sanity/vision/.depcheckrc.json b/packages/@sanity/vision/.depcheckrc.json index d2b37f0015c..7c81e6b4622 100644 --- a/packages/@sanity/vision/.depcheckrc.json +++ b/packages/@sanity/vision/.depcheckrc.json @@ -1,3 +1,17 @@ { - "ignores": ["@sanity/pkg-utils"] + "ignores": [ + "@repo/tsconfig", + "@sanity/pkg-utils", + "@sanity/cli", + "@sanity/migrate", + "@sanity/types", + "@sanity/util", + "@sanity/codegen", + "@sanity/mutator", + "@sanity/diff", + "@sanity/portable-text-editor", + "@sanity/codegen", + "@sanity/schema", + "@sanity/block-tools" + ] } diff --git a/packages/@sanity/vision/package.config.ts b/packages/@sanity/vision/package.config.ts index e29d94bace2..eaf0800c48c 100644 --- a/packages/@sanity/vision/package.config.ts +++ b/packages/@sanity/vision/package.config.ts @@ -1,5 +1,4 @@ +import baseConfig from '@repo/package.config' import {defineConfig} from '@sanity/pkg-utils' -import baseConfig from '../../../package.config' - -export default defineConfig({...baseConfig, external: (external) => [...external, 'sanity']}) +export default defineConfig({...baseConfig, external: ['sanity']}) diff --git a/packages/@sanity/vision/package.json b/packages/@sanity/vision/package.json index 3f8a311e376..22d499ff40a 100644 --- a/packages/@sanity/vision/package.json +++ b/packages/@sanity/vision/package.json @@ -24,35 +24,31 @@ }, "license": "MIT", "author": "Sanity.io ", + "sideEffects": false, "exports": { ".": { - "types": "./lib/dts/src/index.d.ts", "source": "./src/index.ts", + "import": "./lib/index.mjs", "require": "./lib/index.js", - "node": { - "module": "./lib/index.esm.js", - "import": "./lib/index.cjs.mjs" - }, - "import": "./lib/index.esm.js", - "default": "./lib/index.esm.js" + "default": "./lib/index.js" }, "./package.json": "./package.json" }, "main": "./lib/index.js", "module": "./lib/index.esm.js", "source": "./src/index.ts", - "types": "./lib/dts/src/index.d.ts", + "types": "./lib/index.d.ts", "files": [ "lib", "src" ], "scripts": { - "prebuild": "npm run clean", - "build": "pkg-utils build --tsconfig tsconfig.lib.json", - "postbuild": "run-s check:package", - "check:package": "pkg-utils --strict --tsconfig tsconfig.lib.json", + "build": "run-s clean && pkg-utils build --strict", + "check:package": "pkg-utils --strict", + "check:types": "tsc", "clean": "rimraf lib", - "watch": "pkg-utils watch --tsconfig tsconfig.lib.json" + "prepublishOnly": "turbo run build", + "watch": "pkg-utils watch" }, "dependencies": { "@codemirror/autocomplete": "^6.1.0", @@ -76,7 +72,18 @@ "lodash": "^4.17.21" }, "devDependencies": { + "@repo/package.config": "workspace:*", + "@sanity/block-tools": "workspace:*", + "@sanity/cli": "workspace:*", "@sanity/client": "^6.15.11", + "@sanity/codegen": "workspace:*", + "@sanity/diff": "workspace:*", + "@sanity/migrate": "workspace:*", + "@sanity/mutator": "workspace:*", + "@sanity/portable-text-editor": "workspace:*", + "@sanity/schema": "workspace:*", + "@sanity/types": "workspace:*", + "@sanity/util": "workspace:*", "@types/lodash": "^4.14.149", "react": "^18.2.0", "sanity": "workspace:*", diff --git a/packages/@sanity/vision/tsconfig.json b/packages/@sanity/vision/tsconfig.json index 41d94bafc99..a53bd72fa82 100644 --- a/packages/@sanity/vision/tsconfig.json +++ b/packages/@sanity/vision/tsconfig.json @@ -1,12 +1,42 @@ { - "extends": "../../../tsconfig.settings", - "include": ["./src"], + "extends": "@repo/tsconfig/base.json", + "include": [ + "./src", + "./node_modules/@sanity/block-tools/src", + "./node_modules/@sanity/diff/src", + "./node_modules/@sanity/cli/src", + "./node_modules/@sanity/cli/typings/*.d.ts", + "./node_modules/@sanity/codegen/src", + "./node_modules/@sanity/mutator/src", + "./node_modules/@sanity/portable-text-editor/src", + "./node_modules/@sanity/schema/src", + "./node_modules/@sanity/schema/typings", + "./node_modules/@sanity/migrate/src", + "./node_modules/@sanity/types/src", + "./node_modules/@sanity/util/src", + "./node_modules/groq/src", + "./node_modules/sanity/src", + "./node_modules/sanity/typings/*.d.ts" + ], + "exclude": ["./node_modules/@sanity/codegen/src/typescript/__tests__"], "compilerOptions": { - "composite": true, "rootDir": ".", - "outDir": "./lib/dts", - - "jsx": "react-jsx" - }, - "references": [{"path": "../types/tsconfig.lib.json"}, {"path": "../../sanity/tsconfig.lib.json"}] + "paths": { + "@sanity/block-tools": ["./node_modules/@sanity/block-tools/src/index.ts"], + "@sanity/diff": ["./node_modules/@sanity/diff/src/index.ts"], + "@sanity/cli": ["./node_modules/@sanity/cli/src/index.ts"], + "@sanity/codegen": ["./node_modules/@sanity/codegen/src/_exports/index.ts"], + "@sanity/mutator": ["./node_modules/@sanity/mutator/src/index.ts"], + "@sanity/portable-text-editor": ["./node_modules/@sanity/portable-text-editor/src/index.ts"], + "@sanity/schema/*": ["./node_modules/@sanity/schema/src/_exports/*"], + "@sanity/schema": ["./node_modules/@sanity/schema/src/_exports/index.ts"], + "@sanity/migrate": ["./node_modules/@sanity/migrate/src/_exports/index.ts"], + "@sanity/types": ["./node_modules/@sanity/types/src/index.ts"], + "@sanity/util/*": ["./node_modules/@sanity/util/src/_exports/*"], + "@sanity/util": ["./node_modules/@sanity/util/src/_exports/index.ts"], + "groq": ["./node_modules/groq/src/groq.ts"], + "sanity/*": ["./node_modules/sanity/src/_exports/*"], + "sanity": ["./node_modules/sanity/src/_exports/index.ts"] + } + } } diff --git a/packages/@sanity/vision/tsconfig.lib.json b/packages/@sanity/vision/tsconfig.lib.json index 41d94bafc99..39b69d4bb09 100644 --- a/packages/@sanity/vision/tsconfig.lib.json +++ b/packages/@sanity/vision/tsconfig.lib.json @@ -1,12 +1,8 @@ { - "extends": "../../../tsconfig.settings", + "extends": "@repo/tsconfig/build.json", "include": ["./src"], "compilerOptions": { - "composite": true, "rootDir": ".", - "outDir": "./lib/dts", - - "jsx": "react-jsx" - }, - "references": [{"path": "../types/tsconfig.lib.json"}, {"path": "../../sanity/tsconfig.lib.json"}] + "outDir": "./lib" + } } diff --git a/packages/groq/.depcheckrc.json b/packages/groq/.depcheckrc.json index d2b37f0015c..35f1b4badf9 100644 --- a/packages/groq/.depcheckrc.json +++ b/packages/groq/.depcheckrc.json @@ -1,3 +1,3 @@ { - "ignores": ["@sanity/pkg-utils"] + "ignores": ["@repo/tsconfig", "@sanity/pkg-utils"] } diff --git a/packages/groq/package.config.ts b/packages/groq/package.config.ts index 0587ddabfdf..c43051dd053 100644 --- a/packages/groq/package.config.ts +++ b/packages/groq/package.config.ts @@ -1,5 +1,4 @@ +import baseConfig from '@repo/package.config' import {defineConfig} from '@sanity/pkg-utils' -import baseConfig from '../../package.config' - -export default defineConfig({...baseConfig}) +export default defineConfig(baseConfig) diff --git a/packages/groq/package.json b/packages/groq/package.json index 5d1803371db..be8a9f25952 100644 --- a/packages/groq/package.json +++ b/packages/groq/package.json @@ -25,42 +25,39 @@ }, "license": "MIT", "author": "Sanity.io ", + "sideEffects": false, "exports": { ".": { - "types": "./lib/dts/src/groq.d.ts", "source": "./src/groq.ts", + "import": "./lib/groq.mjs", "require": "./lib/groq.js", - "node": { - "module": "./lib/groq.esm.js", - "import": "./lib/groq.cjs.mjs" - }, - "import": "./lib/groq.esm.js", - "default": "./lib/groq.esm.js" + "default": "./lib/groq.js" }, "./package.json": "./package.json" }, "main": "./lib/groq.js", "module": "./lib/groq.esm.js", "source": "./src/groq.ts", - "types": "./lib/dts/src/groq.d.ts", + "types": "./lib/groq.d.ts", "files": [ "lib", - "node", "src" ], "scripts": { - "prebuild": "run-s clean", - "build": "pkg-utils build --tsconfig tsconfig.lib.json", - "postbuild": "run-s check:package", - "check:package": "pkg-utils --strict --tsconfig tsconfig.lib.json", + "build": "run-s clean && pkg-utils build --strict", + "check:package": "pkg-utils --strict", + "check:types": "tsc", "clean": "rimraf lib", "lint": "eslint .", + "prepublishOnly": "turbo run build", "pretest": "run-s build", "test": "node test/groq.test.cjs && node test/groq.test.mjs ", - "watch": "pkg-utils watch --tsconfig tsconfig.lib.json" + "watch": "pkg-utils watch" + }, + "devDependencies": { + "@repo/package.config": "workspace:*" }, "engines": { "node": ">=18" - }, - "gitHead": "a7b7dad6bdfde05883a61f78e998b2571dfbe0e2" + } } diff --git a/packages/groq/tsconfig.json b/packages/groq/tsconfig.json index b503915dd1c..62c59e229cb 100644 --- a/packages/groq/tsconfig.json +++ b/packages/groq/tsconfig.json @@ -1,9 +1,7 @@ { - "extends": "../../tsconfig.settings", - "include": ["./src", "./test"], + "extends": "@repo/tsconfig/base.json", + "include": ["./src", "./test", "./package.json"], "compilerOptions": { - "composite": true, - "rootDir": ".", - "outDir": "./lib/dts" + "rootDir": "." } } diff --git a/packages/groq/tsconfig.lib.json b/packages/groq/tsconfig.lib.json index 284d3c95917..39b69d4bb09 100644 --- a/packages/groq/tsconfig.lib.json +++ b/packages/groq/tsconfig.lib.json @@ -1,9 +1,8 @@ { - "extends": "../../tsconfig.settings", + "extends": "@repo/tsconfig/build.json", "include": ["./src"], "compilerOptions": { - "composite": true, "rootDir": ".", - "outDir": "./lib/dts" + "outDir": "./lib" } } diff --git a/packages/sanity/.depcheckrc.json b/packages/sanity/.depcheckrc.json index 56e8d0705fa..c35d3d68230 100644 --- a/packages/sanity/.depcheckrc.json +++ b/packages/sanity/.depcheckrc.json @@ -1,3 +1,10 @@ { - "ignores": ["@sanity/pkg-utils", "globby", "sanity"] + "ignores": [ + "@repo/tsconfig", + "@sanity/pkg-utils", + "globby", + "sanity", + "@sanity/codegen", + "@types/react" + ] } diff --git a/packages/sanity/.eslintignore b/packages/sanity/.eslintignore index 182f6590765..c6fa6e1b528 100644 --- a/packages/sanity/.eslintignore +++ b/packages/sanity/.eslintignore @@ -1,10 +1,7 @@ # legacy package exports -_internal.js -cli.js desk.js form.js presentation.js router.js structure.js -migrate.js /migrate/* diff --git a/packages/sanity/.gitignore b/packages/sanity/.gitignore index 427cb3bc026..790c682a175 100644 --- a/packages/sanity/.gitignore +++ b/packages/sanity/.gitignore @@ -12,16 +12,18 @@ /lib # Legacy exports -/_internal.js /_internalBrowser.js -/cli.js /desk.js /presentation.js /router.js /structure.js -/migrate.js # Playwright-ct artifacts /playwright-ct/report /playwright-ct/results /playwright-ct/template/.cache/ + +# Deleted legacy exports +/migrate.js +/_internal.js +/cli.js diff --git a/packages/sanity/exports/_internal.ts b/packages/sanity/exports/_internal.ts deleted file mode 100644 index c3737c7c03a..00000000000 --- a/packages/sanity/exports/_internal.ts +++ /dev/null @@ -1 +0,0 @@ -export * from '../src/_internal' diff --git a/packages/sanity/exports/_internalBrowser.ts b/packages/sanity/exports/_internalBrowser.ts deleted file mode 100644 index 5fa869608d4..00000000000 --- a/packages/sanity/exports/_internalBrowser.ts +++ /dev/null @@ -1 +0,0 @@ -export * from '../src/_internal/browser' diff --git a/packages/sanity/exports/desk.ts b/packages/sanity/exports/desk.ts deleted file mode 100644 index 821304fe2a0..00000000000 --- a/packages/sanity/exports/desk.ts +++ /dev/null @@ -1 +0,0 @@ -export * from '../src/desk' diff --git a/packages/sanity/exports/router.ts b/packages/sanity/exports/router.ts deleted file mode 100644 index f81a0326525..00000000000 --- a/packages/sanity/exports/router.ts +++ /dev/null @@ -1 +0,0 @@ -export * from '../src/router' diff --git a/packages/sanity/exports/structure.ts b/packages/sanity/exports/structure.ts deleted file mode 100644 index 7397334182b..00000000000 --- a/packages/sanity/exports/structure.ts +++ /dev/null @@ -1 +0,0 @@ -export * from '../src/structure' diff --git a/packages/sanity/package.config.ts b/packages/sanity/package.config.ts index 9fd86115ca5..08aa9c96444 100644 --- a/packages/sanity/package.config.ts +++ b/packages/sanity/package.config.ts @@ -1,55 +1,52 @@ +import baseConfig from '@repo/package.config' import {defineConfig} from '@sanity/pkg-utils' -import baseConfig from '../../package.config' - export default defineConfig({ ...baseConfig, - exports: (prevExports) => ({ - ...prevExports, - - // Build unexposed bundles for scripts that need to be spawned/used in workers - './_internal/cli/threads/esbuild': { + // Build unexposed bundles for scripts that need to be spawned/used in workers + bundles: [ + { source: './src/_internal/cli/threads/esbuild.ts', require: './lib/_internal/cli/threads/esbuild.js', - default: './lib/_internal/cli/threads/esbuild.js', + runtime: 'node', }, - './_internal/cli/threads/registerBrowserEnv': { + { source: './src/_internal/cli/threads/registerBrowserEnv.ts', require: './lib/_internal/cli/threads/registerBrowserEnv.js', - default: './lib/_internal/cli/threads/registerBrowserEnv.js', + runtime: 'node', }, - './_internal/cli/threads/configClient': { + { source: './src/_internal/cli/threads/configClient.ts', require: './lib/_internal/cli/threads/configClient.js', - default: './lib/_internal/cli/threads/configClient.js', + runtime: 'node', }, - './_internal/cli/threads/getGraphQLAPIs': { + { source: './src/_internal/cli/threads/getGraphQLAPIs.ts', require: './lib/_internal/cli/threads/getGraphQLAPIs.js', - default: './lib/_internal/cli/threads/getGraphQLAPIs.js', + runtime: 'node', }, - './_internal/cli/threads/validateDocuments': { + { source: './src/_internal/cli/threads/validateDocuments.ts', require: './lib/_internal/cli/threads/validateDocuments.js', - default: './lib/_internal/cli/threads/validateDocuments.js', + runtime: 'node', }, - './_internal/cli/threads/validateSchema': { + { source: './src/_internal/cli/threads/validateSchema.ts', require: './lib/_internal/cli/threads/validateSchema.js', - default: './lib/_internal/cli/threads/validateSchema.js', + runtime: 'node', }, - './_internal/cli/threads/extractSchema': { + { source: './src/_internal/cli/threads/extractSchema.ts', require: './lib/_internal/cli/threads/extractSchema.js', - default: './lib/_internal/cli/threads/extractSchema.js', + runtime: 'node', }, - }), + ], extract: { ...baseConfig.extract, rules: { - ...baseConfig.extract?.rules, + ...baseConfig.extract.rules, 'ae-incompatible-release-tags': 'error', 'ae-missing-release-tag': 'error', }, diff --git a/packages/sanity/package.json b/packages/sanity/package.json index cb9167c6ee3..c041fa1fb4f 100644 --- a/packages/sanity/package.json +++ b/packages/sanity/package.json @@ -23,135 +23,87 @@ "sideEffects": false, "exports": { ".": { - "types": "./lib/exports/index.d.ts", - "source": "./exports/index.ts", + "source": "./src/_exports/index.ts", + "import": "./lib/index.mjs", "require": "./lib/index.js", - "node": { - "module": "./lib/index.esm.js", - "import": "./lib/index.cjs.mjs" - }, - "import": "./lib/index.esm.js", - "default": "./lib/index.esm.js" + "default": "./lib/index.js" }, "./_internal": { - "types": "./lib/exports/_internal.d.ts", - "source": "./exports/_internal.ts", + "source": "./src/_exports/_internal.ts", "require": "./lib/_internal.js", - "node": { - "module": "./lib/_internal.esm.js", - "import": "./lib/_internal.cjs.mjs" - }, - "import": "./lib/_internal.esm.js", - "default": "./lib/_internal.esm.js" + "default": "./lib/_internal.js" }, "./_internalBrowser": { - "types": "./lib/exports/_internalBrowser.d.ts", - "source": "./exports/_internalBrowser.ts", + "source": "./src/_exports/_internalBrowser.ts", + "import": "./lib/_internalBrowser.mjs", "require": "./lib/_internalBrowser.js", - "node": { - "module": "./lib/_internalBrowser.esm.js", - "import": "./lib/_internalBrowser.cjs.mjs" - }, - "import": "./lib/_internalBrowser.esm.js", - "default": "./lib/_internalBrowser.esm.js" + "default": "./lib/_internalBrowser.js" }, "./cli": { - "types": "./lib/exports/cli.d.ts", - "source": "./exports/cli.ts", + "source": "./src/_exports/cli.ts", "require": "./lib/cli.js", - "node": { - "module": "./lib/cli.esm.js", - "import": "./lib/cli.cjs.mjs" - }, - "import": "./lib/cli.esm.js", - "default": "./lib/cli.esm.js" + "default": "./lib/cli.js" }, "./desk": { - "types": "./lib/exports/desk.d.ts", - "source": "./exports/desk.ts", + "source": "./src/_exports/desk.ts", + "import": "./lib/desk.mjs", "require": "./lib/desk.js", - "node": { - "module": "./lib/desk.esm.js", - "import": "./lib/desk.cjs.mjs" - }, - "import": "./lib/desk.esm.js", - "default": "./lib/desk.esm.js" + "default": "./lib/desk.js" }, "./presentation": { - "types": "./lib/exports/presentation.d.ts", - "source": "./exports/presentation.ts", + "source": "./src/_exports/presentation.ts", + "import": "./lib/presentation.mjs", "require": "./lib/presentation.js", - "node": { - "module": "./lib/presentation.esm.js", - "import": "./lib/presentation.cjs.mjs" - }, - "import": "./lib/presentation.esm.js", - "default": "./lib/presentation.esm.js" + "default": "./lib/presentation.js" }, "./router": { - "types": "./lib/exports/router.d.ts", - "source": "./exports/router.ts", + "source": "./src/_exports/router.ts", + "import": "./lib/router.mjs", "require": "./lib/router.js", - "node": { - "module": "./lib/router.esm.js", - "import": "./lib/router.cjs.mjs" - }, - "import": "./lib/router.esm.js", - "default": "./lib/router.esm.js" + "default": "./lib/router.js" }, "./structure": { - "types": "./lib/exports/structure.d.ts", - "source": "./exports/structure.ts", + "source": "./src/_exports/structure.ts", + "import": "./lib/structure.mjs", "require": "./lib/structure.js", - "node": { - "module": "./lib/structure.esm.js", - "import": "./lib/structure.cjs.mjs" - }, - "import": "./lib/structure.esm.js", - "default": "./lib/structure.esm.js" + "default": "./lib/structure.js" }, "./migrate": { - "types": "./lib/exports/migrate.d.ts", - "source": "./exports/migrate.ts", + "source": "./src/_exports/migrate.ts", "require": "./lib/migrate.js", - "node": { - "module": "./lib/migrate.esm.js", - "import": "./lib/migrate.cjs.mjs" - }, - "import": "./lib/migrate.esm.js", - "default": "./lib/migrate.esm.js" + "default": "./lib/migrate.js" }, "./package.json": "./package.json" }, "main": "./lib/index.js", "module": "./lib/index.esm.js", - "source": "./exports/index.ts", - "types": "./lib/exports/index.d.ts", + "source": "./src/_exports/index.ts", + "types": "./lib/index.d.ts", "typesVersions": { "*": { "_internal": [ - "./lib/exports/_internal.d.ts" + "./lib/_internal.d.ts" + ], + "_internalBrowser": [ + "./lib/_internalBrowser.d.ts" ], "cli": [ - "./lib/exports/cli.d.ts" + "./lib/cli.d.ts" ], "desk": [ - "./lib/exports/desk.d.ts" - ], - "presentation": [ - "./lib/exports/presentation.d.ts" + "./lib/desk.d.ts" ], "migrate": [ - "./lib/exports/migrate.d.ts" + "./lib/migrate.d.ts" ], - "migrate/mutations": [ - "./lib/exports/migrate-mutations.d.ts" + "presentation": [ + "./lib/presentation.d.ts" ], "router": [ - "./lib/exports/router.d.ts" + "./lib/router.d.ts" ], "structure": [ - "./lib/exports/structure.d.ts" + "./lib/structure.d.ts" ] } }, @@ -159,31 +111,30 @@ "sanity": "./bin/sanity" }, "files": [ - "_internal.js", "bin", - "cli.js", - "desk.js", "lib", - "router.js", - "presentation.js", "src", "static", - "structure.js", "!**/__test__/**", "!**/__tests__/**", - "!**/__workshop__/**" + "!**/__workshop__/**", + "_internalBrowser.js", + "desk.js", + "presentation.js", + "router.js", + "structure.js" ], "scripts": { - "prebuild": "run-s clean", - "build": "pkg-utils build --tsconfig tsconfig.lib.json", - "postbuild": "run-s check:package", - "check:package": "pkg-utils --tsconfig tsconfig.lib.json", - "clean": "rimraf _internal.js cli.js desk.js lib presentation.js router.js", + "build": "run-s clean && pkg-utils build", + "check:package": "pkg-utils", + "check:types": "tsc", + "clean": "rimraf _internal.js _internalBrowser.js cli.js desk.js migrate.js presentation.js router.js structure.js lib", "coverage": "jest --coverage", "lint": "eslint .", + "prepublishOnly": "turbo run build", "test": "pkg-utils --strict && jest", "test:ct": "playwright test -c playwright-ct.config.ts", - "watch": "pkg-utils watch --tsconfig tsconfig.lib.json", + "watch": "pkg-utils watch", "write:playwright-report-as-pr-comment": "node -r esbuild-register playwright-ct/scripts/parsePlaywrightReportJson.ts" }, "dependencies": { @@ -262,7 +213,7 @@ "log-symbols": "^2.2.0", "mendoza": "^3.0.0", "module-alias": "^2.2.2", - "nano-pubsub": "^2.0.1", + "nano-pubsub": "^3.0.0", "nanoid": "^3.1.30", "observable-callback": "^1.0.1", "oneline": "^1.0.3", @@ -305,7 +256,10 @@ "@jest/globals": "^29.7.0", "@playwright/experimental-ct-react": "1.41.2", "@playwright/test": "1.41.2", - "@sanity/tsdoc": "1.0.0-alpha.44", + "@repo/package.config": "workspace:*", + "@sanity/codegen": "3.36.4", + "@sanity/pkg-utils": "5.1.12", + "@sanity/tsdoc": "1.0.13", "@sanity/ui-workshop": "^1.2.11", "@testing-library/jest-dom": "^6.2.0", "@testing-library/react": "^13.4.0", @@ -319,6 +273,7 @@ "@types/log-symbols": "^2.0.0", "@types/node": "^18.19.8", "@types/raf": "^3.4.0", + "@types/react": "^18.2.74", "@types/react-dom": "^18.2.23", "@types/refractor": "^3.0.0", "@types/resolve-from": "^4.0.0", diff --git a/packages/sanity/playwright-ct/scripts/utils.ts b/packages/sanity/playwright-ct/scripts/utils.ts index 6dca39eb610..7bc90dbaa15 100644 --- a/packages/sanity/playwright-ct/scripts/utils.ts +++ b/packages/sanity/playwright-ct/scripts/utils.ts @@ -1,6 +1,6 @@ import {addMinutes, format} from 'date-fns' import fs from 'fs' -import _ from 'lodash' +import {chain, filter, flatMap, forEach, groupBy, sumBy} from 'lodash' import { type GroupedSpec, @@ -28,7 +28,7 @@ export function readJsonFile(filePath: string): JSONReportCustom | null { * Flatten the reporting suites structure */ export function flattenSuites(suites: Suite[]): Spec[] { - return _.flatMap(suites, (suite) => (suite.suites ? flattenSuites(suite.suites) : suite.specs)) + return flatMap(suites, (suite) => (suite.suites ? flattenSuites(suite.suites) : suite.specs)) } /** @@ -37,23 +37,23 @@ export function flattenSuites(suites: Suite[]): Spec[] { export function groupTests(report: JSONReportCustom): GroupedTests { const flatSpecs = flattenSuites(report.suites) - return _.chain(flatSpecs) + return chain(flatSpecs) .groupBy('file') .mapValues((suiteSpecs) => - _.chain(suiteSpecs) + chain(suiteSpecs) .groupBy('title') .mapValues((specs) => { - const tests = _.flatMap(specs, 'tests') + const tests = flatMap(specs, 'tests') const summary = { - totalDuration: _.sumBy(tests, 'results.0.duration'), - totalSkipped: _.filter(tests, (test) => test.results[0].status === 'skipped').length, - totalFailed: _.filter(tests, (test) => test.results[0].status === 'failed').length, - totalPassed: _.filter(tests, (test) => test.results[0].status === 'passed').length, + totalDuration: sumBy(tests, 'results.0.duration'), + totalSkipped: filter(tests, (test) => test.results[0].status === 'skipped').length, + totalFailed: filter(tests, (test) => test.results[0].status === 'failed').length, + totalPassed: filter(tests, (test) => test.results[0].status === 'passed').length, totalTests: tests.length, } return { summary, - projects: _.groupBy(tests, 'projectName'), + projects: groupBy(tests, 'projectName'), } }) .value(), @@ -90,7 +90,7 @@ export function formatDuration(ms: number): string { export function calculateSuiteTotals(specs: Record) { let suiteTotals = {totalDuration: 0, totalPassed: 0, totalSkipped: 0, totalFailed: 0} - _.forEach(specs, ({summary}) => { + forEach(specs, ({summary}) => { suiteTotals = { totalDuration: suiteTotals.totalDuration + summary.totalDuration, totalPassed: suiteTotals.totalPassed + summary.totalPassed, @@ -154,7 +154,7 @@ export function generateOutput(groupedTests: GroupedTests, workflowLink: string) const rows: SummaryRow[] = [] // Loop through each test group and summarize the results - _.forEach(groupedTests, (specs, suite) => { + forEach(groupedTests, (specs, suite) => { rows.push(getSuiteSummaryRow(calculateSuiteTotals(specs), suite, workflowLink)) }) diff --git a/packages/sanity/src/_exports/_internal.ts b/packages/sanity/src/_exports/_internal.ts new file mode 100644 index 00000000000..b8d61678f34 --- /dev/null +++ b/packages/sanity/src/_exports/_internal.ts @@ -0,0 +1 @@ +export * from '../_internal' diff --git a/packages/sanity/src/_exports/_internalBrowser.ts b/packages/sanity/src/_exports/_internalBrowser.ts new file mode 100644 index 00000000000..dafbddf3989 --- /dev/null +++ b/packages/sanity/src/_exports/_internalBrowser.ts @@ -0,0 +1 @@ +export * from '../_internal/browser' diff --git a/packages/sanity/exports/cli.ts b/packages/sanity/src/_exports/cli.ts similarity index 75% rename from packages/sanity/exports/cli.ts rename to packages/sanity/src/_exports/cli.ts index adcf47a0cff..eb61872fdbb 100644 --- a/packages/sanity/exports/cli.ts +++ b/packages/sanity/src/_exports/cli.ts @@ -1,6 +1,6 @@ export { getStudioEnvironmentVariables, type StudioEnvVariablesOptions, -} from '../src/_internal/cli/server/getStudioEnvironmentVariables' +} from '../_internal/cli/server/getStudioEnvironmentVariables' export type {CliClientOptions, CliConfig} from '@sanity/cli' export {createCliConfig, defineCliConfig, getCliClient} from '@sanity/cli' diff --git a/packages/sanity/src/_exports/desk.ts b/packages/sanity/src/_exports/desk.ts new file mode 100644 index 00000000000..602b03f7470 --- /dev/null +++ b/packages/sanity/src/_exports/desk.ts @@ -0,0 +1 @@ +export * from '../desk' diff --git a/packages/sanity/exports/index.ts b/packages/sanity/src/_exports/index.ts similarity index 73% rename from packages/sanity/exports/index.ts rename to packages/sanity/src/_exports/index.ts index 5b38d948722..36dbfb627d5 100644 --- a/packages/sanity/exports/index.ts +++ b/packages/sanity/src/_exports/index.ts @@ -1,3 +1,3 @@ -export * from '../src/core' +export * from '../core' export {type SanityClient} from '@sanity/client' export * from '@sanity/types' diff --git a/packages/sanity/exports/migrate.ts b/packages/sanity/src/_exports/migrate.ts similarity index 100% rename from packages/sanity/exports/migrate.ts rename to packages/sanity/src/_exports/migrate.ts diff --git a/packages/sanity/exports/presentation.ts b/packages/sanity/src/_exports/presentation.ts similarity index 100% rename from packages/sanity/exports/presentation.ts rename to packages/sanity/src/_exports/presentation.ts diff --git a/packages/sanity/src/_exports/router.ts b/packages/sanity/src/_exports/router.ts new file mode 100644 index 00000000000..b5acc52912d --- /dev/null +++ b/packages/sanity/src/_exports/router.ts @@ -0,0 +1 @@ +export * from '../router' diff --git a/packages/sanity/src/_exports/structure.ts b/packages/sanity/src/_exports/structure.ts new file mode 100644 index 00000000000..5064ea7d608 --- /dev/null +++ b/packages/sanity/src/_exports/structure.ts @@ -0,0 +1 @@ +export * from '../structure' diff --git a/packages/sanity/src/_internal/cli/commands/dataset/importDatasetCommand.ts b/packages/sanity/src/_internal/cli/commands/dataset/importDatasetCommand.ts index 4d49008cdef..67cf58219cb 100644 --- a/packages/sanity/src/_internal/cli/commands/dataset/importDatasetCommand.ts +++ b/packages/sanity/src/_internal/cli/commands/dataset/importDatasetCommand.ts @@ -5,7 +5,7 @@ import fs from 'fs/promises' import {getIt} from 'get-it' // eslint-disable-next-line import/extensions import {promise} from 'get-it/middleware' -import padStart from 'lodash/padStart' +import {padStart} from 'lodash' import path from 'path' import prettyMs from 'pretty-ms' diff --git a/packages/sanity/src/_internal/cli/commands/migration/createMigrationCommand.ts b/packages/sanity/src/_internal/cli/commands/migration/createMigrationCommand.ts index 19c316a6289..cab65eedab8 100644 --- a/packages/sanity/src/_internal/cli/commands/migration/createMigrationCommand.ts +++ b/packages/sanity/src/_internal/cli/commands/migration/createMigrationCommand.ts @@ -3,7 +3,7 @@ import {writeFile} from 'node:fs/promises' import path from 'node:path' import {type CliCommandDefinition} from '@sanity/cli' -import deburr from 'lodash/deburr' +import {deburr} from 'lodash' import {MIGRATIONS_DIRECTORY} from './constants' import {minimalAdvanced} from './templates/minimalAdvanced' diff --git a/packages/sanity/src/_internal/cli/threads/extractSchema.ts b/packages/sanity/src/_internal/cli/threads/extractSchema.ts index 3b66e94c85c..8fb02fc00df 100644 --- a/packages/sanity/src/_internal/cli/threads/extractSchema.ts +++ b/packages/sanity/src/_internal/cli/threads/extractSchema.ts @@ -6,6 +6,7 @@ import {type Workspace} from 'sanity' import {getStudioWorkspaces} from '../util/getStudioWorkspaces' import {mockBrowserEnvironment} from '../util/mockBrowserEnvironment' +/** @internal */ export interface ExtractSchemaWorkerData { workDir: string workspaceName?: string @@ -13,6 +14,7 @@ export interface ExtractSchemaWorkerData { format: 'groq-type-nodes' | string } +/** @internal */ export interface ExtractSchemaWorkerResult { schema: ReturnType } diff --git a/packages/sanity/src/_internal/cli/threads/validateDocuments.ts b/packages/sanity/src/_internal/cli/threads/validateDocuments.ts index ec4119c2b8f..0f07226f474 100644 --- a/packages/sanity/src/_internal/cli/threads/validateDocuments.ts +++ b/packages/sanity/src/_internal/cli/threads/validateDocuments.ts @@ -31,6 +31,7 @@ interface AvailabilityResponse { omitted: {id: string; reason: 'existence' | 'permission'}[] } +/** @internal */ export interface ValidateDocumentsWorkerData { workDir: string configPath?: string @@ -43,6 +44,7 @@ export interface ValidateDocumentsWorkerData { maxCustomValidationConcurrency?: number } +/** @internal */ export type ValidationWorkerChannel = WorkerChannel<{ loadedWorkspace: WorkerChannelEvent<{ name: string diff --git a/packages/sanity/src/_internal/cli/threads/validateSchema.ts b/packages/sanity/src/_internal/cli/threads/validateSchema.ts index 66f2c4830e9..fd3fd8b6f1e 100644 --- a/packages/sanity/src/_internal/cli/threads/validateSchema.ts +++ b/packages/sanity/src/_internal/cli/threads/validateSchema.ts @@ -6,12 +6,14 @@ import {isMainThread, parentPort, workerData as _workerData} from 'worker_thread import {getStudioConfig} from '../util/getStudioWorkspaces' import {mockBrowserEnvironment} from '../util/mockBrowserEnvironment' +/** @internal */ export interface ValidateSchemaWorkerData { workDir: string workspace?: string level?: SchemaValidationProblem['severity'] } +/** @internal */ export interface ValidateSchemaWorkerResult { validation: SchemaValidationProblemGroup[] } diff --git a/packages/sanity/src/core/components/commandList/CommandList.tsx b/packages/sanity/src/core/components/commandList/CommandList.tsx index 04657d41dff..245b3d5dfbc 100644 --- a/packages/sanity/src/core/components/commandList/CommandList.tsx +++ b/packages/sanity/src/core/components/commandList/CommandList.tsx @@ -1,6 +1,6 @@ import {Box, rem, Stack} from '@sanity/ui' import {type ScrollToOptions, useVirtualizer, type Virtualizer} from '@tanstack/react-virtual' -import throttle from 'lodash/throttle' +import {throttle} from 'lodash' import { cloneElement, forwardRef, diff --git a/packages/sanity/src/core/i18n/hooks/useTranslation.ts b/packages/sanity/src/core/i18n/hooks/useTranslation.ts index 113e0437e83..e1bd1cebdf2 100644 --- a/packages/sanity/src/core/i18n/hooks/useTranslation.ts +++ b/packages/sanity/src/core/i18n/hooks/useTranslation.ts @@ -1,5 +1,6 @@ import {type FlatNamespace, type KeyPrefix, type Namespace, type TFunction} from 'i18next' import {type FallbackNs, useTranslation as useOriginalTranslation} from 'react-i18next' +// @ts-expect-error types are missing import {type $Tuple} from 'react-i18next/helpers' import {maybeWrapT} from '../debug' @@ -51,6 +52,7 @@ export function useTranslation< options?: UseTranslationOptions, ): UseTranslationResponse, KPrefix> { const {t} = useOriginalTranslation( + // @ts-expect-error type check is failing after using `module: preserve` in tsconfig, which uses `moduleResolution: bundler` internally ns, options ? {keyPrefix: options.keyPrefix, lng: options.lng, ...translationOptionOverrides} diff --git a/packages/sanity/src/core/i18n/i18nConfig.ts b/packages/sanity/src/core/i18n/i18nConfig.ts index f80b88b166e..30f1249f61d 100644 --- a/packages/sanity/src/core/i18n/i18nConfig.ts +++ b/packages/sanity/src/core/i18n/i18nConfig.ts @@ -86,6 +86,7 @@ function createI18nApi({ }, /** @internal */ + // @ts-expect-error types are missing i18next: i18nInstance, } } diff --git a/packages/sanity/src/core/store/_legacy/history/useTimelineSelector.ts b/packages/sanity/src/core/store/_legacy/history/useTimelineSelector.ts index be682a4a58b..3d76ec97441 100644 --- a/packages/sanity/src/core/store/_legacy/history/useTimelineSelector.ts +++ b/packages/sanity/src/core/store/_legacy/history/useTimelineSelector.ts @@ -1,4 +1,4 @@ -import {useSyncExternalStoreWithSelector} from 'use-sync-external-store/with-selector' +import {useSyncExternalStoreWithSelector} from 'use-sync-external-store/with-selector.js' import {type TimelineState, type TimelineStore} from './useTimelineStore' diff --git a/packages/sanity/src/core/studio/StudioErrorBoundary.tsx b/packages/sanity/src/core/studio/StudioErrorBoundary.tsx index 8824b14ebc2..0d5bfed1b10 100644 --- a/packages/sanity/src/core/studio/StudioErrorBoundary.tsx +++ b/packages/sanity/src/core/studio/StudioErrorBoundary.tsx @@ -24,7 +24,7 @@ export function StudioErrorBoundary({ const message = isRecord(error) && typeof error.message === 'string' && error.message const stack = isRecord(error) && typeof error.stack === 'string' && error.stack - const handleResetError = useCallback(() => setError({error: null}), [setError]) + const handleResetError = useCallback(() => setError({error: null}), []) useHotModuleReload(handleResetError) diff --git a/packages/sanity/src/core/studio/activeWorkspaceMatcher/useSyncPathnameWithWorkspace.ts b/packages/sanity/src/core/studio/activeWorkspaceMatcher/useSyncPathnameWithWorkspace.ts index e73574f6d0a..bda7d2f4eee 100644 --- a/packages/sanity/src/core/studio/activeWorkspaceMatcher/useSyncPathnameWithWorkspace.ts +++ b/packages/sanity/src/core/studio/activeWorkspaceMatcher/useSyncPathnameWithWorkspace.ts @@ -1,5 +1,5 @@ import {useMemo, useState} from 'react' -import {useSyncExternalStoreWithSelector} from 'use-sync-external-store/with-selector' +import {useSyncExternalStoreWithSelector} from 'use-sync-external-store/with-selector.js' import {type RouterHistory} from '../router' import {type WorkspacesContextValue} from '../workspaces' diff --git a/packages/sanity/src/core/studio/components/navbar/search/components/SortMenu.tsx b/packages/sanity/src/core/studio/components/navbar/search/components/SortMenu.tsx index a69146607b5..4632901177d 100644 --- a/packages/sanity/src/core/studio/components/navbar/search/components/SortMenu.tsx +++ b/packages/sanity/src/core/studio/components/navbar/search/components/SortMenu.tsx @@ -1,6 +1,6 @@ import {SortIcon} from '@sanity/icons' import {Card, Flex, Menu, MenuDivider} from '@sanity/ui' -import isEqual from 'lodash/isEqual' +import {isEqual} from 'lodash' import {useCallback, useId, useMemo} from 'react' import {styled} from 'styled-components' diff --git a/packages/sanity/src/core/studio/components/navbar/search/contexts/search/SearchProvider.tsx b/packages/sanity/src/core/studio/components/navbar/search/contexts/search/SearchProvider.tsx index 202894bc5e7..2c000af29f5 100644 --- a/packages/sanity/src/core/studio/components/navbar/search/contexts/search/SearchProvider.tsx +++ b/packages/sanity/src/core/studio/components/navbar/search/contexts/search/SearchProvider.tsx @@ -1,4 +1,4 @@ -import isEqual from 'lodash/isEqual' +import {isEqual} from 'lodash' import {type ReactNode, useCallback, useEffect, useMemo, useReducer, useRef, useState} from 'react' import {type CommandListHandle} from '../../../../../../components' diff --git a/packages/sanity/src/core/studio/components/navbar/search/definitions/fields.ts b/packages/sanity/src/core/studio/components/navbar/search/definitions/fields.ts index d389aa4cfae..f8a6d560e23 100644 --- a/packages/sanity/src/core/studio/components/navbar/search/definitions/fields.ts +++ b/packages/sanity/src/core/studio/components/navbar/search/definitions/fields.ts @@ -5,7 +5,7 @@ import { type SchemaTypeDefinition, type StringDefinition, } from '@sanity/types' -import startCase from 'lodash/startCase' +import {startCase} from 'lodash' import {sanitizeFieldValue} from '../utils/sanitizeField' import {getSearchableOmnisearchTypes} from '../utils/selectors' diff --git a/packages/sanity/src/core/studio/components/navbar/search/hooks/useSearch.ts b/packages/sanity/src/core/studio/components/navbar/search/hooks/useSearch.ts index 653acdcc9d8..b1557595951 100644 --- a/packages/sanity/src/core/studio/components/navbar/search/hooks/useSearch.ts +++ b/packages/sanity/src/core/studio/components/navbar/search/hooks/useSearch.ts @@ -1,5 +1,5 @@ import {type Schema} from '@sanity/types' -import isEqual from 'lodash/isEqual' +import {isEqual} from 'lodash' import {useCallback, useMemo, useState} from 'react' import {useObservableCallback} from 'react-rx' import {concat, EMPTY, iif, type Observable, of, timer} from 'rxjs' diff --git a/packages/sanity/src/core/studio/components/navbar/search/utils/filterUtils.ts b/packages/sanity/src/core/studio/components/navbar/search/utils/filterUtils.ts index 5af14958dff..4204977799c 100644 --- a/packages/sanity/src/core/studio/components/navbar/search/utils/filterUtils.ts +++ b/packages/sanity/src/core/studio/components/navbar/search/utils/filterUtils.ts @@ -1,6 +1,5 @@ import {type SchemaType} from '@sanity/types' -import intersection from 'lodash/intersection' -import isEmpty from 'lodash/isEmpty' +import {intersection, isEmpty} from 'lodash' import {isNonNullable} from '../../../../../util' import { diff --git a/packages/sanity/src/core/studio/workspaceLoader/WorkspaceRouterProvider.tsx b/packages/sanity/src/core/studio/workspaceLoader/WorkspaceRouterProvider.tsx index 41429f35853..eeaeb2f99c2 100644 --- a/packages/sanity/src/core/studio/workspaceLoader/WorkspaceRouterProvider.tsx +++ b/packages/sanity/src/core/studio/workspaceLoader/WorkspaceRouterProvider.tsx @@ -8,7 +8,7 @@ import { useRef, } from 'react' import {type Router, RouterProvider, type RouterState} from 'sanity/router' -import {useSyncExternalStoreWithSelector} from 'use-sync-external-store/with-selector' +import {useSyncExternalStoreWithSelector} from 'use-sync-external-store/with-selector.js' import {type Tool, type Workspace} from '../../config' import {createRouter, type RouterHistory, type RouterStateEvent} from '../router' diff --git a/packages/sanity/tsconfig.json b/packages/sanity/tsconfig.json index e1ffb17e9a9..db933366e1a 100644 --- a/packages/sanity/tsconfig.json +++ b/packages/sanity/tsconfig.json @@ -1,47 +1,47 @@ { - "extends": "../../tsconfig.settings", + "extends": "@repo/tsconfig/base.json", "include": [ - "./exports", "./package.json", "./playwright-ct", "./scripts", "./src", "./test", - "./typings" + "./typings", + "./node_modules/@sanity/block-tools/src", + "./node_modules/@sanity/diff/src", + "./node_modules/@sanity/cli/src", + "./node_modules/@sanity/cli/typings/deepSortObject.d.ts", + "./node_modules/@sanity/codegen/src", + "./node_modules/@sanity/mutator/src", + "./node_modules/@sanity/portable-text-editor/src", + "./node_modules/@sanity/schema/src", + "./node_modules/@sanity/schema/typings", + "./node_modules/@sanity/migrate/src", + "./node_modules/@sanity/types/src", + "./node_modules/@sanity/util/src", + "./node_modules/groq/src" ], + "exclude": ["./node_modules/@sanity/codegen/src/typescript/__tests__"], "compilerOptions": { - "composite": true, "rootDir": ".", - "outDir": "./lib", - "paths": { - "sanity/_internal": ["./exports/_internal.ts"], - "sanity/_internalBrowser": ["./exports/_internalBrowser.ts"], - "sanity/cli": ["./exports/cli.ts"], - "sanity/desk": ["./exports/desk.ts"], - "sanity/router": ["./exports/router.ts"], - "sanity/structure": ["./exports/structure.ts"], - "sanity": ["./exports/index.ts"] + "@sanity/block-tools": ["./node_modules/@sanity/block-tools/src/index.ts"], + "@sanity/diff": ["./node_modules/@sanity/diff/src/index.ts"], + "@sanity/cli": ["./node_modules/@sanity/cli/src/index.ts"], + "@sanity/codegen": ["./node_modules/@sanity/codegen/src/_exports/index.ts"], + "@sanity/mutator": ["./node_modules/@sanity/mutator/src/index.ts"], + "@sanity/portable-text-editor": ["./node_modules/@sanity/portable-text-editor/src/index.ts"], + "@sanity/schema/*": ["./node_modules/@sanity/schema/src/_exports/*"], + "@sanity/schema": ["./node_modules/@sanity/schema/src/_exports/index.ts"], + "@sanity/migrate": ["./node_modules/@sanity/migrate/src/_exports/index.ts"], + "@sanity/types": ["./node_modules/@sanity/types/src/index.ts"], + "@sanity/util/*": ["./node_modules/@sanity/util/src/_exports/*"], + "@sanity/util": ["./node_modules/@sanity/util/src/_exports/index.ts"], + "groq": ["./node_modules/groq/src/groq.ts"], + "sanity/*": ["./src/_exports/*"], + "sanity": ["./src/_exports/index.ts"] }, - - "emitDeclarationOnly": true, - "jsx": "react-jsx", - - // For package.json import and scripts - "resolveJsonModule": true, - // For import.meta.env/import.meta.hot definition and similar "types": ["vite/client"] - }, - "references": [ - {"path": "../@sanity/cli/tsconfig.lib.json"}, - {"path": "../@sanity/diff/tsconfig.lib.json"}, - {"path": "../@sanity/mutator/tsconfig.lib.json"}, - {"path": "../@sanity/portable-text-editor/tsconfig.lib.json"}, - {"path": "../@sanity/schema/tsconfig.lib.json"}, - {"path": "../@sanity/types/tsconfig.lib.json"}, - {"path": "../@sanity/cli/tsconfig.lib.json"}, - {"path": "../@sanity/util/tsconfig.lib.json"}, - {"path": "../@sanity/migrate/tsconfig.lib.json"} - ] + } } diff --git a/packages/sanity/tsconfig.lib.json b/packages/sanity/tsconfig.lib.json index f0f87a09209..cde103cdb48 100644 --- a/packages/sanity/tsconfig.lib.json +++ b/packages/sanity/tsconfig.lib.json @@ -1,6 +1,6 @@ { - "extends": "../../tsconfig.settings", - "include": ["./exports", "./package.json", "./src", "./typings"], + "extends": "@repo/tsconfig/build.json", + "include": ["./package.json", "./src", "./typings"], "exclude": [ "./src/**/__fixtures__", "./src/**/__mocks__", @@ -9,38 +9,10 @@ "./src/**/*.test.tsx" ], "compilerOptions": { - "composite": true, "rootDir": ".", "outDir": "./lib", - - "paths": { - "sanity/_internal": ["./exports/_internal.ts"], - "sanity/_internalBrowser": ["./exports/_internalBrowser.ts"], - "sanity/cli": ["./exports/cli.ts"], - "sanity/desk": ["./exports/desk.ts"], - "sanity/router": ["./exports/router.ts"], - "sanity/structure": ["./exports/structure.ts"], - "sanity": ["./exports/index.ts"] - }, - - "emitDeclarationOnly": true, - "jsx": "react-jsx", - - // For package.json import - "resolveJsonModule": true, - + "noImplicitAny": false, // For import.meta.env/import.meta.hot definition and similar "types": ["vite/client"] - }, - "references": [ - {"path": "../@sanity/cli/tsconfig.lib.json"}, - {"path": "../@sanity/diff/tsconfig.lib.json"}, - {"path": "../@sanity/mutator/tsconfig.lib.json"}, - {"path": "../@sanity/portable-text-editor/tsconfig.lib.json"}, - {"path": "../@sanity/schema/tsconfig.lib.json"}, - {"path": "../@sanity/types/tsconfig.lib.json"}, - {"path": "../@sanity/cli/tsconfig.lib.json"}, - {"path": "../@sanity/util/tsconfig.lib.json"}, - {"path": "../@sanity/migrate/tsconfig.lib.json"} - ] + } } diff --git a/packages/sanity/tsconfig.tsdoc.json b/packages/sanity/tsconfig.tsdoc.json new file mode 100644 index 00000000000..6d9a5e2089f --- /dev/null +++ b/packages/sanity/tsconfig.tsdoc.json @@ -0,0 +1,24 @@ +{ + "extends": "@repo/tsconfig/build.json", + "include": ["./package.json", "./src", "./typings"], + "exclude": [ + "./src/**/__fixtures__", + "./src/**/__mocks__", + "./src/**/__workshop__", + "./src/**/*.test.ts", + "./src/**/*.test.tsx" + ], + "compilerOptions": { + "rootDir": ".", + "outDir": "./lib", + "noImplicitAny": false, + // For import.meta.env/import.meta.hot definition and similar + "types": ["vite/client"], + + // Needed until `@microsoft/api-extractor`, as used by `@sanity/tsdoc`, supports `module: "Preserve"` + "module": "ESNext", + "moduleResolution": "Bundler", + "esModuleInterop": true, + "resolveJsonModule": true + } +} diff --git a/packages/sanity/tsdoc.config.ts b/packages/sanity/tsdoc.config.ts index 863f4dd1ba9..4c036810ec1 100644 --- a/packages/sanity/tsdoc.config.ts +++ b/packages/sanity/tsdoc.config.ts @@ -4,6 +4,7 @@ import packageConfig from './package.config' export default defineConfig({ extract: packageConfig.extract, + legacyExports: packageConfig.legacyExports, output: { sanity: { projectId: process.env.EXTRACT_SANITY_PROJECT_ID, @@ -14,5 +15,6 @@ export default defineConfig({ input: { type: 'fs', bundledPackages: ['@sanity/types', '@sanity/migrate'], + tsconfig: 'tsconfig.tsdoc.json', }, }) diff --git a/packages/sanity/turbo.json b/packages/sanity/turbo.json index f814c1af794..174d9482a4a 100644 --- a/packages/sanity/turbo.json +++ b/packages/sanity/turbo.json @@ -3,7 +3,7 @@ "extends": ["//"], "pipeline": { "build": { - "outputs": ["lib/**", "index.js", "_internal.js", "cli.js", "desk.js", "presentation.js", "router.js", "structure.js"] + "outputs": ["lib/**", "_internalBrowser.js", "desk.js", "presentation.js", "router.js", "structure.js"] } } } diff --git a/perf/.depcheckrc.json b/perf/.depcheckrc.json index 7617a22bc02..d06ac5926bc 100644 --- a/perf/.depcheckrc.json +++ b/perf/.depcheckrc.json @@ -1,3 +1,3 @@ { - "ignores": ["sanity"] + "ignores": ["@repo/tsconfig", "sanity"] } diff --git a/perf/studio/tsconfig.json b/perf/studio/tsconfig.json index 88ced4a5a8c..c19bbba6c83 100644 --- a/perf/studio/tsconfig.json +++ b/perf/studio/tsconfig.json @@ -1,7 +1,6 @@ { - "extends": "../../tsconfig.settings.json", + "extends": "@repo/tsconfig/base.json", "compilerOptions": { - "jsx": "react-jsx", - "esModuleInterop": true + "rootDir": "." } } diff --git a/perf/tests/package.json b/perf/tests/package.json index 388418e41c5..e44f1bf265b 100644 --- a/perf/tests/package.json +++ b/perf/tests/package.json @@ -31,6 +31,6 @@ "@types/node": "^18.15.3", "esbuild": "^0.20.2", "ts-node": "^10.9.1", - "typescript": "^5.4.2" + "typescript": "5.4.2" } } diff --git a/perf/tests/tsconfig.json b/perf/tests/tsconfig.json index 3dbfb829720..fd87c78b1d1 100644 --- a/perf/tests/tsconfig.json +++ b/perf/tests/tsconfig.json @@ -1,10 +1,10 @@ { - "extends": "../../tsconfig.settings.json", + "extends": "@repo/tsconfig/base.json", "include": ["./**/*"], "compilerOptions": { + "rootDir": ".", "esModuleInterop": true, "module": "CommonJS", - "noEmit": true, "resolveJsonModule": true } } diff --git a/pnpm-lock.yaml b/pnpm-lock.yaml index 0a81b067695..a24fbd4fe54 100644 --- a/pnpm-lock.yaml +++ b/pnpm-lock.yaml @@ -40,24 +40,30 @@ importers: '@playwright/test': specifier: 1.41.2 version: 1.41.2 + '@repo/package.config': + specifier: workspace:* + version: link:packages/@repo/package.config + '@repo/tsconfig': + specifier: workspace:* + version: link:packages/@repo/tsconfig '@sanity/client': specifier: ^6.15.11 version: 6.15.11 '@sanity/eslint-config-i18n': specifier: 1.0.0 - version: 1.0.0(eslint@8.57.0)(typescript@5.3.3) + version: 1.0.0(eslint@8.57.0)(typescript@5.4.2) '@sanity/eslint-config-studio': specifier: ^3.0.1 - version: 3.0.1(eslint@8.57.0)(typescript@5.3.3) + version: 3.0.1(eslint@8.57.0)(typescript@5.4.2) '@sanity/pkg-utils': - specifier: ^4.4.4 - version: 4.4.4(@types/node@18.19.29)(typescript@5.3.3) + specifier: 5.1.12 + version: 5.1.12(@types/node@18.19.29)(typescript@5.4.2) '@sanity/test': specifier: 0.0.1-alpha.1 version: 0.0.1-alpha.1 '@sanity/tsdoc': - specifier: 1.0.0-alpha.44 - version: 1.0.0-alpha.44(@sanity/pkg-utils@4.4.4)(@types/node@18.19.29)(react-dom@18.2.0)(react-is@18.2.0)(react@18.2.0)(sanity@packages+sanity)(styled-components@5.3.11) + specifier: 1.0.13 + version: 1.0.13(@types/node@18.19.29)(react-dom@18.2.0)(react-is@18.2.0)(react@18.2.0)(sanity@packages+sanity)(styled-components@6.1.8) '@sanity/uuid': specifier: ^3.0.2 version: 3.0.2 @@ -81,10 +87,10 @@ importers: version: 17.0.32 '@typescript-eslint/eslint-plugin': specifier: ^7.5.0 - version: 7.5.0(@typescript-eslint/parser@7.5.0)(eslint@8.57.0)(typescript@5.3.3) + version: 7.5.0(@typescript-eslint/parser@7.5.0)(eslint@8.57.0)(typescript@5.4.2) '@typescript-eslint/parser': specifier: ^7.5.0 - version: 7.5.0(eslint@8.57.0)(typescript@5.3.3) + version: 7.5.0(eslint@8.57.0)(typescript@5.4.2) cac: specifier: ^6.7.12 version: 6.7.14 @@ -203,8 +209,8 @@ importers: specifier: ^1.13.2 version: 1.13.2 typescript: - specifier: 5.3.3 - version: 5.3.3 + specifier: 5.4.2 + version: 5.4.2 yargs: specifier: ^17.3.0 version: 17.7.2 @@ -260,8 +266,8 @@ importers: specifier: ^4.2.1 version: 4.2.1(vite@4.5.3) typescript: - specifier: ^5.4.2 - version: 5.4.4 + specifier: 5.4.2 + version: 5.4.2 vite: specifier: ^4.5.3 version: 4.5.3(@types/node@18.19.29) @@ -339,7 +345,7 @@ importers: version: link:../../packages/sanity sanity-plugin-mux-input: specifier: ^2.2.1 - version: 2.3.1(@types/react@18.2.74)(react-dom@18.2.0)(react-is@18.2.0)(react@18.2.0)(sanity@packages+sanity)(styled-components@6.1.8) + version: 2.2.4(@types/react@18.2.74)(react-dom@18.2.0)(react-is@18.2.0)(react@18.2.0)(sanity@packages+sanity)(styled-components@6.1.8) sanity-test-studio: specifier: workspace:* version: link:../test-studio @@ -367,7 +373,7 @@ importers: devDependencies: eslint-config-next: specifier: ^14.1.3 - version: 14.1.4(eslint@8.57.0)(typescript@5.4.4) + version: 14.1.4(eslint@8.57.0)(typescript@5.4.2) dev/test-studio: dependencies: @@ -376,7 +382,7 @@ importers: version: 3.0.17(react@18.2.0) '@react-three/cannon': specifier: ^6.5.2 - version: 6.6.0(@react-three/fiber@8.16.1)(react@18.2.0)(three@0.157.0)(typescript@5.4.4) + version: 6.6.0(@react-three/fiber@8.16.1)(react@18.2.0)(three@0.157.0)(typescript@5.4.2) '@react-three/drei': specifier: ^9.80.1 version: 9.104.0(@react-three/fiber@8.16.1)(@types/react@18.2.74)(@types/three@0.150.2)(react-dom@18.2.0)(react@18.2.0)(three@0.157.0) @@ -421,7 +427,7 @@ importers: version: 1.2.3(sanity@packages+sanity) '@sanity/logos': specifier: ^2.1.2 - version: 2.1.9(@sanity/color@3.0.5)(react@18.2.0) + version: 2.1.8(@sanity/color@3.0.5)(react@18.2.0) '@sanity/migrate': specifier: workspace:* version: link:../../packages/@sanity/migrate @@ -436,10 +442,10 @@ importers: version: 1.6.7(@sanity/client@6.15.11) '@sanity/react-loader': specifier: ^1.8.3 - version: 1.9.9(@sanity/client@6.15.11)(react@18.2.0) + version: 1.9.7(@sanity/client@6.15.11)(react@18.2.0) '@sanity/tsdoc': - specifier: 1.0.0-alpha.44 - version: 1.0.0-alpha.44(@sanity/pkg-utils@2.4.10)(@types/node@18.19.29)(react-dom@18.2.0)(react-is@18.2.0)(react@18.2.0)(sanity@packages+sanity)(styled-components@6.1.8) + specifier: 1.0.13 + version: 1.0.13(@types/node@18.19.29)(react-dom@18.2.0)(react-is@18.2.0)(react@18.2.0)(sanity@packages+sanity)(styled-components@6.1.8) '@sanity/types': specifier: workspace:* version: link:../../packages/@sanity/types @@ -514,7 +520,7 @@ importers: version: link:../../packages/sanity sanity-plugin-mux-input: specifier: ^2.2.1 - version: 2.3.1(@types/react@18.2.74)(react-dom@18.2.0)(react-is@18.2.0)(react@18.2.0)(sanity@packages+sanity)(styled-components@6.1.8) + version: 2.2.4(@types/react@18.2.74)(react-dom@18.2.0)(react-is@18.2.0)(react@18.2.0)(sanity@packages+sanity)(styled-components@6.1.8) styled-components: specifier: ^6.1.0 version: 6.1.8(react-dom@18.2.0)(react@18.2.0) @@ -601,6 +607,14 @@ importers: specifier: ^6.1.0 version: 6.1.8(react-dom@18.2.0)(react@18.2.0) + packages/@repo/package.config: + dependencies: + '@optimize-lodash/rollup-plugin': + specifier: ^4.0.4 + version: 4.0.4(rollup@4.14.1) + + packages/@repo/tsconfig: {} + packages/@sanity/block-tools: dependencies: get-random-values-esm: @@ -613,6 +627,9 @@ importers: '@jest/globals': specifier: ^29.7.0 version: 29.7.0 + '@repo/package.config': + specifier: workspace:* + version: link:../../@repo/package.config '@sanity/schema': specifier: 3.36.4 version: link:../schema @@ -636,7 +653,10 @@ importers: dependencies: '@babel/traverse': specifier: ^7.23.5 - version: 7.24.1(supports-color@5.5.0) + version: 7.24.1 + '@sanity/client': + specifier: ^6.15.11 + version: 6.15.11 '@sanity/codegen': specifier: 3.36.4 version: link:../codegen @@ -649,6 +669,9 @@ importers: chalk: specifier: ^4.1.2 version: 4.1.2 + debug: + specifier: ^4.3.4 + version: 4.3.4(supports-color@9.4.0) decompress: specifier: ^4.2.0 version: 4.2.1 @@ -683,21 +706,24 @@ importers: '@jest/globals': specifier: ^29.7.0 version: 29.7.0 + '@repo/package.config': + specifier: workspace:* + version: link:../../@repo/package.config '@rexxars/gitconfiglocal': specifier: ^3.0.1 version: 3.0.1 '@rollup/plugin-node-resolve': specifier: ^15.2.3 version: 15.2.3(rollup@4.14.1) - '@sanity/client': - specifier: ^6.15.11 - version: 6.15.11 '@sanity/eslint-config-studio': specifier: ^3.0.1 - version: 3.0.1(eslint@8.57.0)(typescript@5.4.4) + version: 3.0.1(eslint@8.57.0)(typescript@5.4.2) '@sanity/generate-help-url': specifier: ^3.0.0 version: 3.0.0 + '@sanity/types': + specifier: workspace:* + version: link:../types '@types/babel__traverse': specifier: ^7.20.5 version: 7.20.5 @@ -761,9 +787,6 @@ importers: cpx: specifier: ^1.5.0 version: 1.5.0 - debug: - specifier: ^4.3.4 - version: 4.3.4(supports-color@5.5.0) deep-sort-object: specifier: ^1.0.1 version: 1.0.2 @@ -868,16 +891,19 @@ importers: version: 7.23.7(@babel/core@7.24.4) '@babel/traverse': specifier: ^7.23.5 - version: 7.24.1(supports-color@5.5.0) + version: 7.24.1 '@babel/types': specifier: ^7.23.9 version: 7.24.0 debug: specifier: ^4.3.4 - version: 4.3.4(supports-color@5.5.0) + version: 4.3.4(supports-color@9.4.0) globby: specifier: ^10.0.0 version: 10.0.2 + groq: + specifier: workspace:* + version: link:../../groq groq-js: specifier: ^1.7.0 version: 1.7.0 @@ -894,6 +920,9 @@ importers: '@jest/globals': specifier: ^29.7.0 version: 29.7.0 + '@repo/package.config': + specifier: workspace:* + version: link:../../@repo/package.config '@types/babel__core': specifier: ^7.20.5 version: 7.20.5 @@ -909,9 +938,6 @@ importers: '@types/debug': specifier: ^4.1.12 version: 4.1.12 - groq: - specifier: workspace:* - version: link:../../groq rimraf: specifier: ^3.0.2 version: 3.0.2 @@ -922,6 +948,9 @@ importers: specifier: ^3.1.1 version: 3.1.1 devDependencies: + '@repo/package.config': + specifier: workspace:* + version: link:../../@repo/package.config rimraf: specifier: ^3.0.2 version: 3.0.2 @@ -936,7 +965,7 @@ importers: version: 7.0.1 debug: specifier: ^4.3.4 - version: 4.3.4(supports-color@5.5.0) + version: 4.3.4(supports-color@9.4.0) get-it: specifier: ^8.4.18 version: 8.4.18 @@ -979,7 +1008,7 @@ importers: version: 3.0.2 debug: specifier: ^4.3.4 - version: 4.3.4(supports-color@5.5.0) + version: 4.3.4(supports-color@9.4.0) file-url: specifier: ^2.0.2 version: 2.0.2 @@ -1070,7 +1099,7 @@ importers: version: 2.0.1 debug: specifier: ^4.3.4 - version: 4.3.4(supports-color@5.5.0) + version: 4.3.4(supports-color@9.4.0) fast-fifo: specifier: ^1.3.2 version: 1.3.2 @@ -1084,6 +1113,9 @@ importers: '@jest/globals': specifier: ^29.7.0 version: 29.7.0 + '@repo/package.config': + specifier: workspace:* + version: link:../../@repo/package.config '@types/arrify': specifier: ^2.0.1 version: 2.0.1 @@ -1104,7 +1136,7 @@ importers: version: 3.0.2 debug: specifier: ^4.3.4 - version: 4.3.4(supports-color@5.5.0) + version: 4.3.4(supports-color@9.4.0) lodash: specifier: ^4.17.21 version: 4.17.21 @@ -1112,6 +1144,9 @@ importers: '@jest/globals': specifier: ^29.7.0 version: 29.7.0 + '@repo/package.config': + specifier: workspace:* + version: link:../../@repo/package.config '@sanity/types': specifier: 3.36.4 version: link:../types @@ -1164,6 +1199,9 @@ importers: '@portabletext/toolkit': specifier: ^2.0.14 version: 2.0.14 + '@repo/package.config': + specifier: workspace:* + version: link:../../@repo/package.config '@sanity/diff-match-patch': specifier: ^3.1.1 version: 3.1.1 @@ -1270,6 +1308,9 @@ importers: '@jest/globals': specifier: ^29.7.0 version: 29.7.0 + '@repo/package.config': + specifier: workspace:* + version: link:../../@repo/package.config '@sanity/icons': specifier: ^2.11.7 version: 2.11.7(react@18.2.0) @@ -1279,6 +1320,9 @@ importers: '@types/object-inspect': specifier: ^1.13.0 version: 1.13.0 + '@types/react': + specifier: ^18.2.74 + version: 18.2.74 rimraf: specifier: ^3.0.2 version: 3.0.2 @@ -1295,6 +1339,9 @@ importers: '@jest/globals': specifier: ^29.7.0 version: 29.7.0 + '@repo/package.config': + specifier: workspace:* + version: link:../../@repo/package.config rimraf: specifier: ^3.0.2 version: 3.0.2 @@ -1320,6 +1367,9 @@ importers: '@jest/globals': specifier: ^29.7.0 version: 29.7.0 + '@repo/package.config': + specifier: workspace:* + version: link:../../@repo/package.config '@types/moment': specifier: ^2.13.0 version: 2.13.0 @@ -1373,7 +1423,7 @@ importers: version: 2.1.0(react-dom@18.2.0)(react-is@18.2.0)(react@18.2.0)(styled-components@6.1.8) '@uiw/react-codemirror': specifier: ^4.11.4 - version: 4.21.25(@babel/runtime@7.24.4)(@codemirror/autocomplete@6.15.0)(@codemirror/language@6.10.1)(@codemirror/lint@6.5.0)(@codemirror/search@6.5.6)(@codemirror/state@6.4.1)(@codemirror/theme-one-dark@6.1.2)(@codemirror/view@6.26.1)(codemirror@6.0.1)(react-dom@18.2.0)(react@18.2.0) + version: 4.21.25(@babel/runtime@7.24.1)(@codemirror/autocomplete@6.15.0)(@codemirror/language@6.10.1)(@codemirror/lint@6.5.0)(@codemirror/search@6.5.6)(@codemirror/state@6.4.1)(@codemirror/theme-one-dark@6.1.2)(@codemirror/view@6.26.1)(codemirror@6.0.1)(react-dom@18.2.0)(react@18.2.0) hashlru: specifier: ^2.3.0 version: 2.3.0 @@ -1387,9 +1437,42 @@ importers: specifier: ^4.17.21 version: 4.17.21 devDependencies: + '@repo/package.config': + specifier: workspace:* + version: link:../../@repo/package.config + '@sanity/block-tools': + specifier: workspace:* + version: link:../block-tools + '@sanity/cli': + specifier: workspace:* + version: link:../cli '@sanity/client': specifier: ^6.15.11 version: 6.15.11 + '@sanity/codegen': + specifier: workspace:* + version: link:../codegen + '@sanity/diff': + specifier: workspace:* + version: link:../diff + '@sanity/migrate': + specifier: workspace:* + version: link:../migrate + '@sanity/mutator': + specifier: workspace:* + version: link:../mutator + '@sanity/portable-text-editor': + specifier: workspace:* + version: link:../portable-text-editor + '@sanity/schema': + specifier: workspace:* + version: link:../schema + '@sanity/types': + specifier: workspace:* + version: link:../types + '@sanity/util': + specifier: workspace:* + version: link:../util '@types/lodash': specifier: ^4.14.149 version: 4.17.0 @@ -1412,7 +1495,11 @@ importers: specifier: ^2.0.0 version: 2.0.0 - packages/groq: {} + packages/groq: + devDependencies: + '@repo/package.config': + specifier: workspace:* + version: link:../@repo/package.config packages/sanity: dependencies: @@ -1481,7 +1568,7 @@ importers: version: link:../@sanity/import '@sanity/logos': specifier: ^2.1.4 - version: 2.1.9(@sanity/color@3.0.5)(react@18.2.0) + version: 2.1.8(@sanity/color@3.0.5)(react@18.2.0) '@sanity/migrate': specifier: 3.36.4 version: link:../@sanity/migrate @@ -1574,7 +1661,7 @@ importers: version: 2.30.0 debug: specifier: ^4.3.4 - version: 4.3.4(supports-color@5.5.0) + version: 4.3.4(supports-color@9.4.0) esbuild: specifier: ^0.20.0 version: 0.20.2 @@ -1607,7 +1694,7 @@ importers: version: 5.3.0 i18next: specifier: ^23.2.7 - version: 23.11.0 + version: 23.10.1 import-fresh: specifier: ^3.3.0 version: 3.3.0 @@ -1642,8 +1729,8 @@ importers: specifier: ^2.2.2 version: 2.2.3 nano-pubsub: - specifier: ^2.0.1 - version: 2.0.1 + specifier: ^3.0.0 + version: 3.0.0 nanoid: specifier: ^3.1.30 version: 3.3.7 @@ -1685,7 +1772,7 @@ importers: version: 2.11.2(@types/react@18.2.74)(react@18.2.0) react-i18next: specifier: ^13.0.1 - version: 13.5.0(i18next@23.11.0)(react-dom@18.2.0)(react@18.2.0) + version: 13.5.0(i18next@23.10.1)(react-dom@18.2.0)(react@18.2.0) react-is: specifier: ^18.2.0 version: 18.2.0 @@ -1765,9 +1852,18 @@ importers: '@playwright/test': specifier: 1.41.2 version: 1.41.2 + '@repo/package.config': + specifier: workspace:* + version: link:../@repo/package.config + '@sanity/codegen': + specifier: 3.36.4 + version: link:../@sanity/codegen + '@sanity/pkg-utils': + specifier: 5.1.12 + version: 5.1.12(@types/node@18.19.29)(typescript@5.4.2) '@sanity/tsdoc': - specifier: 1.0.0-alpha.44 - version: 1.0.0-alpha.44(@sanity/pkg-utils@2.4.10)(@types/node@18.19.29)(react-dom@18.2.0)(react-is@18.2.0)(react@18.2.0)(sanity@packages+sanity)(styled-components@6.1.8) + specifier: 1.0.13 + version: 1.0.13(@types/node@18.19.29)(react-dom@18.2.0)(react-is@18.2.0)(react@18.2.0)(sanity@packages+sanity)(styled-components@6.1.8) '@sanity/ui-workshop': specifier: ^1.2.11 version: 1.2.11(@sanity/icons@2.11.7)(@sanity/ui@2.1.0)(@types/node@18.19.29)(react-dom@18.2.0)(react@18.2.0)(styled-components@6.1.8) @@ -1779,7 +1875,7 @@ importers: version: 13.4.0(react-dom@18.2.0)(react@18.2.0) '@testing-library/user-event': specifier: ^13.0.16 - version: 13.5.0(@testing-library/dom@10.0.0) + version: 13.5.0(@testing-library/dom@9.3.4) '@types/archiver': specifier: ^6.0.2 version: 6.0.2 @@ -1807,6 +1903,9 @@ importers: '@types/raf': specifier: ^3.4.0 version: 3.4.3 + '@types/react': + specifier: ^18.2.74 + version: 18.2.74 '@types/react-dom': specifier: ^18.2.23 version: 18.2.23 @@ -1898,10 +1997,10 @@ packages: '@babel/helpers': 7.24.4 '@babel/parser': 7.24.4 '@babel/template': 7.24.0 - '@babel/traverse': 7.24.1(supports-color@5.5.0) + '@babel/traverse': 7.24.1 '@babel/types': 7.24.0 convert-source-map: 2.0.0 - debug: 4.3.4(supports-color@5.5.0) + debug: 4.3.4(supports-color@9.4.0) gensync: 1.0.0-beta.2 json5: 2.2.3 semver: 6.3.1 @@ -1989,7 +2088,7 @@ packages: '@babel/core': 7.24.4 '@babel/helper-compilation-targets': 7.23.6 '@babel/helper-plugin-utils': 7.24.0 - debug: 4.3.4(supports-color@5.5.0) + debug: 4.3.4(supports-color@9.4.0) lodash.debounce: 4.0.8 resolve: 1.22.8 transitivePeerDependencies: @@ -2112,7 +2211,7 @@ packages: engines: {node: '>=6.9.0'} dependencies: '@babel/template': 7.24.0 - '@babel/traverse': 7.24.1(supports-color@5.5.0) + '@babel/traverse': 7.24.1 '@babel/types': 7.24.0 transitivePeerDependencies: - supports-color @@ -3070,8 +3169,8 @@ packages: /@babel/regjsgen@0.8.0: resolution: {integrity: sha512-x/rqGMdzj+fWZvCOYForTghzbtqPDZ5gPwaoNGHdgDfF2QA/XZbCBp4Moo5scrkAMPhB7z26XM/AaHuIJdgauA==} - /@babel/runtime@7.24.4: - resolution: {integrity: sha512-dkxf7+hn8mFBwKjs9bvBlArzLVxVbS8usaPUDd5p2a9JCL9tB8OaOVN1isD4+Xyk4ns89/xeOmbQvgdK7IIVdA==} + /@babel/runtime@7.24.1: + resolution: {integrity: sha512-+BIznRzyqBf+2wCTxcKE3wDjfGeCoVE61KSHGpkzqrLi8qxqFwBeUFyId2cxkTmm55fzDGnm0+yCxaxygrLUnQ==} engines: {node: '>=6.9.0'} dependencies: regenerator-runtime: 0.14.1 @@ -3084,7 +3183,7 @@ packages: '@babel/parser': 7.24.4 '@babel/types': 7.24.0 - /@babel/traverse@7.24.1(supports-color@5.5.0): + /@babel/traverse@7.24.1: resolution: {integrity: sha512-xuU6o9m68KeqZbQuDt2TcKSxUw/mrsvavlEqQ1leZ/B+C9tk6E4sRWy97WaXgvq5E+nU3cXMxv3WKOCanVMCmQ==} engines: {node: '>=6.9.0'} dependencies: @@ -3096,7 +3195,7 @@ packages: '@babel/helper-split-export-declaration': 7.22.6 '@babel/parser': 7.24.4 '@babel/types': 7.24.0 - debug: 4.3.4(supports-color@5.5.0) + debug: 4.3.4(supports-color@9.4.0) globals: 11.12.0 transitivePeerDependencies: - supports-color @@ -3271,12 +3370,6 @@ packages: dependencies: '@emotion/memoize': 0.8.1 - /@emotion/is-prop-valid@1.2.2: - resolution: {integrity: sha512-uNsoYd37AFmaCdXlg6EYD1KaPOaRWRByMCYzbKUX4+hhMfrxdVSelShywL4JVaAeM/eHUOSprYBQls+/neX3pw==} - dependencies: - '@emotion/memoize': 0.8.1 - dev: true - /@emotion/memoize@0.7.4: resolution: {integrity: sha512-Ja/Vfqe3HpuzRsG1oBtWTHk2PGZ7GR+2Vz5iYGelAw8dx32K0y7PjVuxK6z1nMpZOqAFsRUPCkK1YjJ56qJlgw==} requiresBuild: true @@ -3285,14 +3378,6 @@ packages: /@emotion/memoize@0.8.1: resolution: {integrity: sha512-W2P2c/VRW1/1tLox0mVUalvnWXxavmv/Oum2aPsRcoDJuob75FC3Y8FbpfLwUegRcxINtGUMPq0tFCvYNTBXNA==} - /@emotion/stylis@0.8.5: - resolution: {integrity: sha512-h6KtPihKFn3T9fuIrwvXXUOwlx3rfUvfZIcP5a6rh8Y7zjE3O06hT5Ss4S/YI1AYhuZ1kjaE/5EaOOI2NqSylQ==} - dev: true - - /@emotion/unitless@0.7.5: - resolution: {integrity: sha512-OWORNpfjMsSSUBVrRBVGECkhWcULOAJz9ZW8uK9qgxD+87M7jHRcvh/A96XXNhXTLmKcoYSQtBEX7lHMO7YRwg==} - dev: true - /@emotion/unitless@0.8.0: resolution: {integrity: sha512-VINS5vEYAscRl2ZUDiT3uMPlrFQupiKgHz5AA4bCH1miKBg4qtwkim1qPmJj/4WG6TreYMY111rEFsjupcOKHw==} @@ -3860,7 +3945,7 @@ packages: engines: {node: ^12.22.0 || ^14.17.0 || >=16.0.0} dependencies: ajv: 6.12.6 - debug: 4.3.4(supports-color@5.5.0) + debug: 4.3.4(supports-color@9.4.0) espree: 9.6.1 globals: 13.24.0 ignore: 5.3.1 @@ -3897,6 +3982,7 @@ packages: '@floating-ui/dom': 1.6.3 react: 18.2.0 react-dom: 18.2.0(react@18.2.0) + dev: false /@floating-ui/react-dom@2.0.8(react-dom@18.2.0)(react@18.2.0): resolution: {integrity: sha512-HOdqOt3R3OGeTKidaLvJKcgg75S6tibQ3Tif4eyd91QnIJWr0NLvoXFpJA/j8HqkFSL68GDca9AuyWEHlhyClw==} @@ -3926,7 +4012,7 @@ packages: engines: {node: '>=10.10.0'} dependencies: '@humanwhocodes/object-schema': 2.0.3 - debug: 4.3.4(supports-color@5.5.0) + debug: 4.3.4(supports-color@9.4.0) minimatch: 3.1.2 transitivePeerDependencies: - supports-color @@ -4228,7 +4314,7 @@ packages: resolution: {integrity: sha512-dfLbk+PwWvFzSxwk3n5ySL0hfBog779o8h68wK/7/APo/7cgyWp5jcXockbxdk5kFRkbeXWm4Fbi9FrdN381sA==} dev: false - /@lerna/create@8.1.2(typescript@5.4.4): + /@lerna/create@8.1.2(typescript@5.4.2): resolution: {integrity: sha512-GzScCIkAW3tg3+Yn/MKCH9963bzG+zpjGz2NdfYDlYWI7p0f/SH46v1dqpPpYmZ2E/m3JK8HjTNNNL8eIm8/YQ==} engines: {node: '>=18.0.0'} dependencies: @@ -4243,7 +4329,7 @@ packages: columnify: 1.6.0 conventional-changelog-core: 5.0.1 conventional-recommended-bump: 7.0.1 - cosmiconfig: 8.3.6(typescript@5.4.4) + cosmiconfig: 8.3.6(typescript@5.4.2) dedent: 0.7.0 execa: 5.0.0 fs-extra: 11.2.0 @@ -4334,15 +4420,6 @@ packages: resolution: {integrity: sha512-Rp7ll8BHrKB3wXaRFKhrltwZl1CiXGdibPxuWXvqGnKTnv8fqa/nvftYNuSbf+pbJWKYCXdBtYTITdAUTGGh0Q==} dev: false - /@microsoft/api-extractor-model@7.27.0(@types/node@18.19.29): - resolution: {integrity: sha512-wHqIMiwSARmiuVLn/zmVpiRncq6hvBfC5GF+sjrN3w4FqVkqFYk7DetvfRNdy/3URdqqmYGrhJlcU9HpLnHOPg==} - dependencies: - '@microsoft/tsdoc': 0.14.2 - '@microsoft/tsdoc-config': 0.16.2 - '@rushstack/node-core-library': 3.59.1(@types/node@18.19.29) - transitivePeerDependencies: - - '@types/node' - /@microsoft/api-extractor-model@7.28.13(@types/node@18.19.29): resolution: {integrity: sha512-39v/JyldX4MS9uzHcdfmjjfS6cYGAoXV+io8B5a338pkHiSt+gy2eXQ0Q7cGFJ7quSa1VqqlMdlPrB6sLR/cAw==} dependencies: @@ -4352,25 +4429,6 @@ packages: transitivePeerDependencies: - '@types/node' - /@microsoft/api-extractor@7.35.0(@types/node@18.19.29): - resolution: {integrity: sha512-yBGfPJeEtzk8sg2hE2/vOPRvnJBvstbWNGeyGV1jIEUSgytzQ0QPgPEkOsP2n7nBfnyRXmZaBa2vJPGOzVWy+g==} - hasBin: true - dependencies: - '@microsoft/api-extractor-model': 7.27.0(@types/node@18.19.29) - '@microsoft/tsdoc': 0.14.2 - '@microsoft/tsdoc-config': 0.16.2 - '@rushstack/node-core-library': 3.59.1(@types/node@18.19.29) - '@rushstack/rig-package': 0.3.19 - '@rushstack/ts-command-line': 4.13.3 - colors: 1.2.5 - lodash: 4.17.21 - resolve: 1.22.8 - semver: 7.3.8 - source-map: 0.6.1 - typescript: 5.0.4 - transitivePeerDependencies: - - '@types/node' - /@microsoft/api-extractor@7.43.0(@types/node@18.19.29): resolution: {integrity: sha512-GFhTcJpB+MI6FhvXEI9b2K0snulNLWHqC/BbcJtyNYcKUiw7l3Lgis5ApsYncJ0leALX7/of4XfmXk+maT111w==} hasBin: true @@ -4411,8 +4469,8 @@ packages: three: 0.157.0 dev: false - /@mux/mux-player-react@2.4.1(@types/react@18.2.74)(react-dom@18.2.0)(react@18.2.0): - resolution: {integrity: sha512-grM6T847fKnzlK786NG1AxhNS+6A78pEPc5zG4yYvKe3ayGNTOpq/Hnm9pDVkOx5/uMI/yCdSsfiNyytYaw8qA==} + /@mux/mux-player-react@1.15.0(@types/react@18.2.74)(react-dom@18.2.0)(react@18.2.0): + resolution: {integrity: sha512-U699OMiVgKCrhjnw6cGemtqRVuja5YDOVXSMMGGGEdWpoPArrDqYDAkwmfUpK9eRUPiPaBC9IjLpl/8SvCYpRw==} peerDependencies: '@types/react': ^17.0.0 || ^18 '@types/react-dom': '*' @@ -4424,35 +4482,36 @@ packages: '@types/react-dom': optional: true dependencies: - '@mux/mux-player': 2.4.1 - '@mux/playback-core': 0.22.4 + '@mux/mux-player': 1.15.0 + '@mux/playback-core': 0.20.2 '@types/react': 18.2.74 prop-types: 15.8.1 react: 18.2.0 react-dom: 18.2.0(react@18.2.0) dev: false - /@mux/mux-player@2.4.1: - resolution: {integrity: sha512-Lm7KkG/lD1tqqqtL1nacZsCll9JY4gVNGxUw/MPYmgIevYACYtQ/76iaEtaN67DmHYYxep1QUpYEDZPXallkEg==} + /@mux/mux-player@1.15.0: + resolution: {integrity: sha512-b7U82PbsH6/lTSiHMSQyqnofuRoTqCgx6L5DvF81r/oicXLzwB6kaSmp14WX+KBEduzAVKEykGcQOZXcjYDFgg==} dependencies: - '@mux/mux-video': 0.17.5 - '@mux/playback-core': 0.22.4 - media-chrome: 3.1.1 + '@mux/mux-video': 0.16.5 + '@mux/playback-core': 0.20.2 + media-chrome: 1.7.0 dev: false - /@mux/mux-video@0.17.5: - resolution: {integrity: sha512-EMLflDnr/o7XQiWKfwnq9BJmj30kpSszzXwpXE4hmBIgc9JAuF3Hl94qv1kyWQAUhrO5hnnOxwGHgv0FvkJ1GQ==} + /@mux/mux-video@0.16.5: + resolution: {integrity: sha512-YtM8A+AcYRD8AhcaensueNcUABjBJcDCg34M0rxhRIOBLaAr6Gz9qo9dRGuI0n+Rm6xD0VCRlS41D3YbJ8NNHA==} dependencies: - '@mux/playback-core': 0.22.4 - castable-video: 1.0.6 - custom-media-element: 1.2.3 + '@mux/playback-core': 0.20.2 + castable-video: 0.5.2 + custom-media-element: 0.2.0 media-tracks: 0.3.0 dev: false - /@mux/playback-core@0.22.4: - resolution: {integrity: sha512-f/jWcYbFRjXjdFRNq3MK79D1YHTqvwcfchRLYukE384P3cb027dru+bSxMKESrfkhAhnWFy7fdq/llawl7SU9g==} + /@mux/playback-core@0.20.2: + resolution: {integrity: sha512-0uRy+8Rv3PDV0f7Je/m+y56lw96iyv3baxQPDmW2JnihR60/wtIzNRJSLE5vrzsKMysWBrnJ6Mwu8WkEB1qjLQ==} dependencies: - hls.js: 1.4.14 + hls.js: 1.5.7 + media-tracks: 0.2.3 mux-embed: 4.30.0 dev: false @@ -4927,15 +4986,13 @@ packages: '@optimize-lodash/transform': 3.0.3 '@rollup/pluginutils': 5.0.5(rollup@4.14.1) rollup: 4.14.1 - dev: true /@optimize-lodash/transform@3.0.3: resolution: {integrity: sha512-LeH2C2nYPfwKLQ1OX7jrfZOYTyRajOhhgoCdz47+5d2oBP8YKL/NknCAcDt2QkzLDLbtZ5QHhKZN56S2D/I1JA==} engines: {node: '>= 12'} dependencies: estree-walker: 2.0.2 - magic-string: 0.30.9 - dev: true + magic-string: 0.30.8 /@pkgjs/parseargs@0.11.0: resolution: {integrity: sha512-+1VkjdD0QBLPodGrJUeqarH8VAIvQODIbwh9XpP5Syisf7YoQgsJKPNFoqqLQlu+VQ/tVSshMR6loPMn8U+dPg==} @@ -5041,7 +5098,7 @@ packages: /@radix-ui/primitive@1.0.1: resolution: {integrity: sha512-yQ8oGX2GVsEYMWGxcovu1uGWPCxV5BFfeeYxqPmuAzUyLT9qmaMXSAhXpb0WrspIeqYzdJpkh2vHModJPgRIaw==} dependencies: - '@babel/runtime': 7.24.4 + '@babel/runtime': 7.24.1 dev: false /@radix-ui/react-arrow@1.0.3(@types/react@18.2.74)(react-dom@18.2.0)(react@18.2.0): @@ -5057,7 +5114,7 @@ packages: '@types/react-dom': optional: true dependencies: - '@babel/runtime': 7.24.4 + '@babel/runtime': 7.24.1 '@radix-ui/react-primitive': 1.0.3(@types/react@18.2.74)(react-dom@18.2.0)(react@18.2.0) '@types/react': 18.2.74 react: 18.2.0 @@ -5073,7 +5130,7 @@ packages: '@types/react': optional: true dependencies: - '@babel/runtime': 7.24.4 + '@babel/runtime': 7.24.1 '@types/react': 18.2.74 react: 18.2.0 dev: false @@ -5087,7 +5144,7 @@ packages: '@types/react': optional: true dependencies: - '@babel/runtime': 7.24.4 + '@babel/runtime': 7.24.1 '@types/react': 18.2.74 react: 18.2.0 dev: false @@ -5105,7 +5162,7 @@ packages: '@types/react-dom': optional: true dependencies: - '@babel/runtime': 7.24.4 + '@babel/runtime': 7.24.1 '@radix-ui/primitive': 1.0.1 '@radix-ui/react-compose-refs': 1.0.1(@types/react@18.2.74)(react@18.2.0) '@radix-ui/react-primitive': 1.0.3(@types/react@18.2.74)(react-dom@18.2.0)(react@18.2.0) @@ -5125,7 +5182,7 @@ packages: '@types/react': optional: true dependencies: - '@babel/runtime': 7.24.4 + '@babel/runtime': 7.24.1 '@radix-ui/react-use-layout-effect': 1.0.1(@types/react@18.2.74)(react@18.2.0) '@types/react': 18.2.74 react: 18.2.0 @@ -5144,7 +5201,7 @@ packages: '@types/react-dom': optional: true dependencies: - '@babel/runtime': 7.24.4 + '@babel/runtime': 7.24.1 '@floating-ui/react-dom': 2.0.8(react-dom@18.2.0)(react@18.2.0) '@radix-ui/react-arrow': 1.0.3(@types/react@18.2.74)(react-dom@18.2.0)(react@18.2.0) '@radix-ui/react-compose-refs': 1.0.1(@types/react@18.2.74)(react@18.2.0) @@ -5173,7 +5230,7 @@ packages: '@types/react-dom': optional: true dependencies: - '@babel/runtime': 7.24.4 + '@babel/runtime': 7.24.1 '@radix-ui/react-primitive': 1.0.3(@types/react@18.2.74)(react-dom@18.2.0)(react@18.2.0) '@types/react': 18.2.74 react: 18.2.0 @@ -5193,7 +5250,7 @@ packages: '@types/react-dom': optional: true dependencies: - '@babel/runtime': 7.24.4 + '@babel/runtime': 7.24.1 '@radix-ui/react-compose-refs': 1.0.1(@types/react@18.2.74)(react@18.2.0) '@radix-ui/react-use-layout-effect': 1.0.1(@types/react@18.2.74)(react@18.2.0) '@types/react': 18.2.74 @@ -5214,7 +5271,7 @@ packages: '@types/react-dom': optional: true dependencies: - '@babel/runtime': 7.24.4 + '@babel/runtime': 7.24.1 '@radix-ui/react-slot': 1.0.2(@types/react@18.2.74)(react@18.2.0) '@types/react': 18.2.74 react: 18.2.0 @@ -5230,7 +5287,7 @@ packages: '@types/react': optional: true dependencies: - '@babel/runtime': 7.24.4 + '@babel/runtime': 7.24.1 '@radix-ui/react-compose-refs': 1.0.1(@types/react@18.2.74)(react@18.2.0) '@types/react': 18.2.74 react: 18.2.0 @@ -5249,7 +5306,7 @@ packages: '@types/react-dom': optional: true dependencies: - '@babel/runtime': 7.24.4 + '@babel/runtime': 7.24.1 '@radix-ui/primitive': 1.0.1 '@radix-ui/react-compose-refs': 1.0.1(@types/react@18.2.74)(react@18.2.0) '@radix-ui/react-context': 1.0.1(@types/react@18.2.74)(react@18.2.0) @@ -5276,7 +5333,7 @@ packages: '@types/react': optional: true dependencies: - '@babel/runtime': 7.24.4 + '@babel/runtime': 7.24.1 '@types/react': 18.2.74 react: 18.2.0 dev: false @@ -5290,7 +5347,7 @@ packages: '@types/react': optional: true dependencies: - '@babel/runtime': 7.24.4 + '@babel/runtime': 7.24.1 '@radix-ui/react-use-callback-ref': 1.0.1(@types/react@18.2.74)(react@18.2.0) '@types/react': 18.2.74 react: 18.2.0 @@ -5305,7 +5362,7 @@ packages: '@types/react': optional: true dependencies: - '@babel/runtime': 7.24.4 + '@babel/runtime': 7.24.1 '@radix-ui/react-use-callback-ref': 1.0.1(@types/react@18.2.74)(react@18.2.0) '@types/react': 18.2.74 react: 18.2.0 @@ -5320,7 +5377,7 @@ packages: '@types/react': optional: true dependencies: - '@babel/runtime': 7.24.4 + '@babel/runtime': 7.24.1 '@types/react': 18.2.74 react: 18.2.0 dev: false @@ -5334,7 +5391,7 @@ packages: '@types/react': optional: true dependencies: - '@babel/runtime': 7.24.4 + '@babel/runtime': 7.24.1 '@radix-ui/rect': 1.0.1 '@types/react': 18.2.74 react: 18.2.0 @@ -5349,7 +5406,7 @@ packages: '@types/react': optional: true dependencies: - '@babel/runtime': 7.24.4 + '@babel/runtime': 7.24.1 '@radix-ui/react-use-layout-effect': 1.0.1(@types/react@18.2.74)(react@18.2.0) '@types/react': 18.2.74 react: 18.2.0 @@ -5368,7 +5425,7 @@ packages: '@types/react-dom': optional: true dependencies: - '@babel/runtime': 7.24.4 + '@babel/runtime': 7.24.1 '@radix-ui/react-primitive': 1.0.3(@types/react@18.2.74)(react-dom@18.2.0)(react@18.2.0) '@types/react': 18.2.74 react: 18.2.0 @@ -5378,7 +5435,7 @@ packages: /@radix-ui/rect@1.0.1: resolution: {integrity: sha512-fyrgCaedtvMg9NK3en0pnOYJdtfwxUcNolezkNPUsoX57X8oQk+NkqcvzHXD2uKNij6GXmWU9NDru2IWjrO4BQ==} dependencies: - '@babel/runtime': 7.24.4 + '@babel/runtime': 7.24.1 dev: false /@react-spring/animated@9.6.1(react@18.2.0): @@ -5437,7 +5494,7 @@ packages: resolution: {integrity: sha512-POu8Mk0hIU3lRXB3bGIGe4VHIwwDsQyoD1F394OK7STTiX9w4dG3cTLljjYswkQN+hDSHRrj4O36kuVa7KPU8Q==} dev: false - /@react-three/cannon@6.6.0(@react-three/fiber@8.16.1)(react@18.2.0)(three@0.157.0)(typescript@5.4.4): + /@react-three/cannon@6.6.0(@react-three/fiber@8.16.1)(react@18.2.0)(three@0.157.0)(typescript@5.4.2): resolution: {integrity: sha512-lP9rJoVHQi0w+dYF8FJAm2xr5eLfNEckb04j72kjqndUkuOPr26N4rSBhQbHl5b5N3tEnhQaIMungAvHkcY8/A==} peerDependencies: '@react-three/fiber': '>=8' @@ -5447,7 +5504,7 @@ packages: '@pmndrs/cannon-worker-api': 2.4.0(three@0.157.0) '@react-three/fiber': 8.16.1(react-dom@18.2.0)(react@18.2.0)(three@0.157.0) cannon-es: 0.20.0 - cannon-es-debugger: 1.0.0(cannon-es@0.20.0)(three@0.157.0)(typescript@5.4.4) + cannon-es-debugger: 1.0.0(cannon-es@0.20.0)(three@0.157.0)(typescript@5.4.2) react: 18.2.0 three: 0.157.0 transitivePeerDependencies: @@ -5465,7 +5522,7 @@ packages: react-dom: optional: true dependencies: - '@babel/runtime': 7.24.4 + '@babel/runtime': 7.24.1 '@mediapipe/tasks-vision': 0.10.8 '@monogrid/gainmap-js': 3.0.4(three@0.157.0) '@react-spring/three': 9.6.1(@react-three/fiber@8.16.1)(react@18.2.0)(three@0.157.0) @@ -5523,7 +5580,7 @@ packages: react-native: optional: true dependencies: - '@babel/runtime': 7.24.4 + '@babel/runtime': 7.24.1 '@types/react-reconciler': 0.26.7 '@types/webxr': 0.5.14 base64-js: 1.5.1 @@ -5570,18 +5627,6 @@ packages: react-style-proptype: 3.2.2 dev: false - /@rollup/plugin-alias@5.1.0(rollup@3.29.4): - resolution: {integrity: sha512-lpA3RZ9PdIG7qqhEfv79tBffNaoDuukFDrmhLqg9ifv99u/ehn+lOg30x2zmhf8AQqQUZaMk/B9fZraQ6/acDQ==} - engines: {node: '>=14.0.0'} - peerDependencies: - rollup: ^1.20.0||^2.0.0||^3.0.0||^4.0.0 - peerDependenciesMeta: - rollup: - optional: true - dependencies: - rollup: 3.29.4 - slash: 4.0.0 - /@rollup/plugin-alias@5.1.0(rollup@4.14.1): resolution: {integrity: sha512-lpA3RZ9PdIG7qqhEfv79tBffNaoDuukFDrmhLqg9ifv99u/ehn+lOg30x2zmhf8AQqQUZaMk/B9fZraQ6/acDQ==} engines: {node: '>=14.0.0'} @@ -5593,25 +5638,6 @@ packages: dependencies: rollup: 4.14.1 slash: 4.0.0 - dev: true - - /@rollup/plugin-babel@6.0.4(@babel/core@7.24.4)(rollup@3.29.4): - resolution: {integrity: sha512-YF7Y52kFdFT/xVSuVdjkV5ZdX/3YtmX0QulG+x0taQOtJdHYzVU61aSSkAgVJ7NOv6qPkIYiJSgSWWN/DM5sGw==} - engines: {node: '>=14.0.0'} - peerDependencies: - '@babel/core': ^7.0.0 - '@types/babel__core': ^7.1.9 - rollup: ^1.20.0||^2.0.0||^3.0.0||^4.0.0 - peerDependenciesMeta: - '@types/babel__core': - optional: true - rollup: - optional: true - dependencies: - '@babel/core': 7.24.4 - '@babel/helper-module-imports': 7.24.3 - '@rollup/pluginutils': 5.1.0(rollup@3.29.4) - rollup: 3.29.4 /@rollup/plugin-babel@6.0.4(@babel/core@7.24.4)(rollup@4.14.1): resolution: {integrity: sha512-YF7Y52kFdFT/xVSuVdjkV5ZdX/3YtmX0QulG+x0taQOtJdHYzVU61aSSkAgVJ7NOv6qPkIYiJSgSWWN/DM5sGw==} @@ -5630,24 +5656,6 @@ packages: '@babel/helper-module-imports': 7.24.3 '@rollup/pluginutils': 5.1.0(rollup@4.14.1) rollup: 4.14.1 - dev: true - - /@rollup/plugin-commonjs@25.0.7(rollup@3.29.4): - resolution: {integrity: sha512-nEvcR+LRjEjsaSsc4x3XZfCCvZIaSMenZu/OiwOKGN2UhQpAYI7ru7czFvyWbErlpoGjnSX3D5Ch5FcMA3kRWQ==} - engines: {node: '>=14.0.0'} - peerDependencies: - rollup: ^2.68.0||^3.0.0||^4.0.0 - peerDependenciesMeta: - rollup: - optional: true - dependencies: - '@rollup/pluginutils': 5.1.0(rollup@3.29.4) - commondir: 1.0.1 - estree-walker: 2.0.2 - glob: 8.1.0 - is-reference: 1.2.1 - magic-string: 0.30.9 - rollup: 3.29.4 /@rollup/plugin-commonjs@25.0.7(rollup@4.14.1): resolution: {integrity: sha512-nEvcR+LRjEjsaSsc4x3XZfCCvZIaSMenZu/OiwOKGN2UhQpAYI7ru7czFvyWbErlpoGjnSX3D5Ch5FcMA3kRWQ==} @@ -5663,21 +5671,8 @@ packages: estree-walker: 2.0.2 glob: 8.1.0 is-reference: 1.2.1 - magic-string: 0.30.9 + magic-string: 0.30.8 rollup: 4.14.1 - dev: true - - /@rollup/plugin-json@6.1.0(rollup@3.29.4): - resolution: {integrity: sha512-EGI2te5ENk1coGeADSIwZ7G2Q8CJS2sF120T7jLw4xFw9n7wIOXHo+kIYRAoVpJAN+kmqZSoO3Fp4JtoNF4ReA==} - engines: {node: '>=14.0.0'} - peerDependencies: - rollup: ^1.20.0||^2.0.0||^3.0.0||^4.0.0 - peerDependenciesMeta: - rollup: - optional: true - dependencies: - '@rollup/pluginutils': 5.1.0(rollup@3.29.4) - rollup: 3.29.4 /@rollup/plugin-json@6.1.0(rollup@4.14.1): resolution: {integrity: sha512-EGI2te5ENk1coGeADSIwZ7G2Q8CJS2sF120T7jLw4xFw9n7wIOXHo+kIYRAoVpJAN+kmqZSoO3Fp4JtoNF4ReA==} @@ -5690,24 +5685,6 @@ packages: dependencies: '@rollup/pluginutils': 5.1.0(rollup@4.14.1) rollup: 4.14.1 - dev: true - - /@rollup/plugin-node-resolve@15.2.3(rollup@3.29.4): - resolution: {integrity: sha512-j/lym8nf5E21LwBT4Df1VD6hRO2L2iwUeUmP7litikRsVp1H6NWx20NEp0Y7su+7XGc476GnXXc4kFeZNGmaSQ==} - engines: {node: '>=14.0.0'} - peerDependencies: - rollup: ^2.78.0||^3.0.0||^4.0.0 - peerDependenciesMeta: - rollup: - optional: true - dependencies: - '@rollup/pluginutils': 5.1.0(rollup@3.29.4) - '@types/resolve': 1.20.2 - deepmerge: 4.3.1 - is-builtin-module: 3.2.1 - is-module: 1.0.0 - resolve: 1.22.8 - rollup: 3.29.4 /@rollup/plugin-node-resolve@15.2.3(rollup@4.14.1): resolution: {integrity: sha512-j/lym8nf5E21LwBT4Df1VD6hRO2L2iwUeUmP7litikRsVp1H6NWx20NEp0Y7su+7XGc476GnXXc4kFeZNGmaSQ==} @@ -5725,20 +5702,6 @@ packages: is-module: 1.0.0 resolve: 1.22.8 rollup: 4.14.1 - dev: true - - /@rollup/plugin-replace@5.0.5(rollup@3.29.4): - resolution: {integrity: sha512-rYO4fOi8lMaTg/z5Jb+hKnrHHVn8j2lwkqwyS4kTRhKyWOLf2wST2sWXr4WzWiTcoHTp2sTjqUbqIj2E39slKQ==} - engines: {node: '>=14.0.0'} - peerDependencies: - rollup: ^1.20.0||^2.0.0||^3.0.0||^4.0.0 - peerDependenciesMeta: - rollup: - optional: true - dependencies: - '@rollup/pluginutils': 5.1.0(rollup@3.29.4) - magic-string: 0.30.9 - rollup: 3.29.4 /@rollup/plugin-replace@5.0.5(rollup@4.14.1): resolution: {integrity: sha512-rYO4fOi8lMaTg/z5Jb+hKnrHHVn8j2lwkqwyS4kTRhKyWOLf2wST2sWXr4WzWiTcoHTp2sTjqUbqIj2E39slKQ==} @@ -5750,23 +5713,8 @@ packages: optional: true dependencies: '@rollup/pluginutils': 5.1.0(rollup@4.14.1) - magic-string: 0.30.9 + magic-string: 0.30.8 rollup: 4.14.1 - dev: true - - /@rollup/plugin-terser@0.4.4(rollup@3.29.4): - resolution: {integrity: sha512-XHeJC5Bgvs8LfukDwWZp7yeqin6ns8RTl2B9avbejt6tZqsqvVoWI7ZTQrcNsfKEDWBTnTxM8nMDkO2IFFbd0A==} - engines: {node: '>=14.0.0'} - peerDependencies: - rollup: ^2.0.0||^3.0.0||^4.0.0 - peerDependenciesMeta: - rollup: - optional: true - dependencies: - rollup: 3.29.4 - serialize-javascript: 6.0.2 - smob: 1.5.0 - terser: 5.30.2 /@rollup/plugin-terser@0.4.4(rollup@4.14.1): resolution: {integrity: sha512-XHeJC5Bgvs8LfukDwWZp7yeqin6ns8RTl2B9avbejt6tZqsqvVoWI7ZTQrcNsfKEDWBTnTxM8nMDkO2IFFbd0A==} @@ -5781,7 +5729,6 @@ packages: serialize-javascript: 6.0.2 smob: 1.5.0 terser: 5.30.2 - dev: true /@rollup/pluginutils@5.0.5(rollup@4.14.1): resolution: {integrity: sha512-6aEYR910NyP73oHiJglti74iRyOwgFU4x3meH/H8OJx6Ry0j6cOVZ5X/wTvub7G7Ao6qaHBEaNsV3GLJkSsF+Q==} @@ -5796,21 +5743,6 @@ packages: estree-walker: 2.0.2 picomatch: 2.3.1 rollup: 4.14.1 - dev: true - - /@rollup/pluginutils@5.1.0(rollup@3.29.4): - resolution: {integrity: sha512-XTIWOPPcpvyKI6L1NHo0lFlCyznUEyPmPY1mc3KpPVDYulHSTvyeLNVW00QTLIAFNhR3kYnJTQHeGqU4M3n09g==} - engines: {node: '>=14.0.0'} - peerDependencies: - rollup: ^1.20.0||^2.0.0||^3.0.0||^4.0.0 - peerDependenciesMeta: - rollup: - optional: true - dependencies: - '@types/estree': 1.0.5 - estree-walker: 2.0.2 - picomatch: 2.3.1 - rollup: 3.29.4 /@rollup/pluginutils@5.1.0(rollup@4.14.1): resolution: {integrity: sha512-XTIWOPPcpvyKI6L1NHo0lFlCyznUEyPmPY1mc3KpPVDYulHSTvyeLNVW00QTLIAFNhR3kYnJTQHeGqU4M3n09g==} @@ -5825,14 +5757,12 @@ packages: estree-walker: 2.0.2 picomatch: 2.3.1 rollup: 4.14.1 - dev: true /@rollup/rollup-android-arm-eabi@4.14.1: resolution: {integrity: sha512-fH8/o8nSUek8ceQnT7K4EQbSiV7jgkHq81m9lWZFIXjJ7lJzpWXbQFpT/Zh6OZYnpFykvzC3fbEvEAFZu03dPA==} cpu: [arm] os: [android] requiresBuild: true - dev: true optional: true /@rollup/rollup-android-arm64@4.14.1: @@ -5840,7 +5770,6 @@ packages: cpu: [arm64] os: [android] requiresBuild: true - dev: true optional: true /@rollup/rollup-darwin-arm64@4.14.1: @@ -5848,7 +5777,6 @@ packages: cpu: [arm64] os: [darwin] requiresBuild: true - dev: true optional: true /@rollup/rollup-darwin-x64@4.14.1: @@ -5856,7 +5784,6 @@ packages: cpu: [x64] os: [darwin] requiresBuild: true - dev: true optional: true /@rollup/rollup-linux-arm-gnueabihf@4.14.1: @@ -5864,7 +5791,6 @@ packages: cpu: [arm] os: [linux] requiresBuild: true - dev: true optional: true /@rollup/rollup-linux-arm64-gnu@4.14.1: @@ -5872,7 +5798,6 @@ packages: cpu: [arm64] os: [linux] requiresBuild: true - dev: true optional: true /@rollup/rollup-linux-arm64-musl@4.14.1: @@ -5880,7 +5805,6 @@ packages: cpu: [arm64] os: [linux] requiresBuild: true - dev: true optional: true /@rollup/rollup-linux-powerpc64le-gnu@4.14.1: @@ -5888,7 +5812,6 @@ packages: cpu: [ppc64le] os: [linux] requiresBuild: true - dev: true optional: true /@rollup/rollup-linux-riscv64-gnu@4.14.1: @@ -5896,7 +5819,6 @@ packages: cpu: [riscv64] os: [linux] requiresBuild: true - dev: true optional: true /@rollup/rollup-linux-s390x-gnu@4.14.1: @@ -5904,7 +5826,6 @@ packages: cpu: [s390x] os: [linux] requiresBuild: true - dev: true optional: true /@rollup/rollup-linux-x64-gnu@4.14.1: @@ -5912,7 +5833,6 @@ packages: cpu: [x64] os: [linux] requiresBuild: true - dev: true optional: true /@rollup/rollup-linux-x64-musl@4.14.1: @@ -5920,7 +5840,6 @@ packages: cpu: [x64] os: [linux] requiresBuild: true - dev: true optional: true /@rollup/rollup-win32-arm64-msvc@4.14.1: @@ -5928,7 +5847,6 @@ packages: cpu: [arm64] os: [win32] requiresBuild: true - dev: true optional: true /@rollup/rollup-win32-ia32-msvc@4.14.1: @@ -5936,7 +5854,6 @@ packages: cpu: [ia32] os: [win32] requiresBuild: true - dev: true optional: true /@rollup/rollup-win32-x64-msvc@4.14.1: @@ -5944,30 +5861,12 @@ packages: cpu: [x64] os: [win32] requiresBuild: true - dev: true optional: true /@rushstack/eslint-patch@1.10.1: resolution: {integrity: sha512-S3Kq8e7LqxkA9s7HKLqXGTGck1uwis5vAXan3FnU5yw1Ec5hsSGnq4s/UCaSqABPOnOTg7zASLyst7+ohgWexg==} dev: true - /@rushstack/node-core-library@3.59.1(@types/node@18.19.29): - resolution: {integrity: sha512-iy/xaEhXGpX+DY1ZzAtNA+QPw+9+TJh773Im+JxG4R1fu00/vWq470UOEj6upxlUxmp0JxhnmNRxzfptHrn/Uw==} - peerDependencies: - '@types/node': '*' - peerDependenciesMeta: - '@types/node': - optional: true - dependencies: - '@types/node': 18.19.29 - colors: 1.2.5 - fs-extra: 7.0.1 - import-lazy: 4.0.0 - jju: 1.4.0 - resolve: 1.22.8 - semver: 7.3.8 - z-schema: 5.0.5 - /@rushstack/node-core-library@4.0.2(@types/node@18.19.29): resolution: {integrity: sha512-hyES82QVpkfQMeBMteQUnrhASL/KHPhd7iJ8euduwNJG4mu2GSOKybf0rOEjOm1Wz7CwJEUm9y0yD7jg2C1bfg==} peerDependencies: @@ -5984,12 +5883,6 @@ packages: semver: 7.5.4 z-schema: 5.0.5 - /@rushstack/rig-package@0.3.19: - resolution: {integrity: sha512-2d0/Gn+qjOYneZbiHjn4SjyDwq9I0WagV37z0F1V71G+yONgH7wlt3K/UoNiDkhA8gTHYPRo2jz3CvttybwSag==} - dependencies: - resolve: 1.22.8 - strip-json-comments: 3.1.1 - /@rushstack/rig-package@0.5.2: resolution: {integrity: sha512-mUDecIJeH3yYGZs2a48k+pbhM6JYwWlgjs2Ca5f2n1G2/kgdgP9D/07oglEGf6mRyXEnazhEENeYTSNDRCwdqA==} dependencies: @@ -6008,14 +5901,6 @@ packages: '@types/node': 18.19.29 supports-color: 8.1.1 - /@rushstack/ts-command-line@4.13.3: - resolution: {integrity: sha512-6aQIv/o1EgsC/+SpgUyRmzg2QIAL6sudEzw3sWzJKwWuQTc5XRsyZpyldfE7WAmIqMXDao9QG35/NYORjHm5Zw==} - dependencies: - '@types/argparse': 1.0.38 - argparse: 1.0.10 - colors: 1.2.5 - string-argv: 0.3.2 - /@rushstack/ts-command-line@4.19.1(@types/node@18.19.29): resolution: {integrity: sha512-J7H768dgcpG60d7skZ5uSSwyCZs/S2HrWP1Ds8d1qYAyaaeJmpmmLr9BVw97RjFzmQPOYnoXcKA4GkqDCkduQg==} dependencies: @@ -6064,7 +5949,6 @@ packages: /@sanity/browserslist-config@1.0.3: resolution: {integrity: sha512-UkJuiTyROgPcxbvpHYyXwr+T88Np4eLzu3h05gMgeZ2hv3EM7g/4VMyng5HuA1JdPQPEdq8bmmfQDR+u4KC+TA==} - dev: true /@sanity/client@6.15.11: resolution: {integrity: sha512-+dAEEKy6LrugjbssVnmef1ZoXOodiEj+0jMzqpygHmw0+uuyeb0jCvAnDdguF1thY/n3H1x+N1edt0CvVrD7Qg==} @@ -6079,16 +5963,17 @@ packages: /@sanity/color@2.2.5: resolution: {integrity: sha512-tTi22KoKuER3sldXYl4c1Dq2zU7tMLDkljFiaUKVkBbu4PBvRGCFw75kXZnD2b4Bsp6vin+7sI+AKdCKRhfRuw==} + dev: false /@sanity/color@3.0.5: resolution: {integrity: sha512-jwXekw8WGkpuTIjcTh3f5LSoSG+0sFrWPkcFlUIyQ2kwk9EDsQmFVf2X9Ewr1GAbRmqUEMhuCrr0O5z+KAqLmA==} engines: {node: '>=18.0.0'} - /@sanity/core-loader@1.6.5(@sanity/client@6.15.11): - resolution: {integrity: sha512-WKEyrFiIUfPz2H6mdPkZaYbiFbBeSO405iELHmqWru/zqjHpQ64YYoF3rRRn/32t4aU5jYsl9vH+qeNTmdvKNw==} + /@sanity/core-loader@1.6.4(@sanity/client@6.15.11): + resolution: {integrity: sha512-qgTyi3DWRioEIdouETsIpzMfR3SiENhUZhlsvh3u911R87NSfqtgAe3hYLQ14W+kTOMTu0fPjswkLB7ET5Ky0Q==} engines: {node: '>=18'} peerDependencies: - '@sanity/client': ^6.15.11 + '@sanity/client': ^6.15.10 dependencies: '@sanity/client': 6.15.11 async-cache-dedupe: 2.1.0 @@ -6098,12 +5983,12 @@ packages: resolution: {integrity: sha512-dSZqGeYjHKGIkqAzGqLcG92LZyJGX+nYbs/FWawhBbTBDWi21kvQ0hsL3DJThuFVWtZMWTQijN3z6Cnd44Pf2g==} engines: {node: '>=14.18'} - /@sanity/eslint-config-i18n@1.0.0(eslint@8.57.0)(typescript@5.3.3): + /@sanity/eslint-config-i18n@1.0.0(eslint@8.57.0)(typescript@5.4.2): resolution: {integrity: sha512-BIeD9IVT7O5I6vDyDaICoidN02qeImdXDRAW062iHY9gV4JrGScWBFio2HQLso7C+Z6SrQB8jOft6SzeYqDhdQ==} dependencies: '@rushstack/eslint-patch': 1.10.1 '@sanity/eslint-plugin-i18n': 1.1.0 - '@typescript-eslint/parser': 7.5.0(eslint@8.57.0)(typescript@5.3.3) + '@typescript-eslint/parser': 7.5.0(eslint@8.57.0)(typescript@5.4.2) eslint-plugin-i18next: 6.0.3 transitivePeerDependencies: - eslint @@ -6111,27 +5996,7 @@ packages: - typescript dev: true - /@sanity/eslint-config-studio@3.0.1(eslint@8.57.0)(typescript@5.3.3): - resolution: {integrity: sha512-N7IFd/VZuL0UyJ2T5t5WWWf9DrhgY6lt0bnnScwwyX4ijA7WMFtxR5rgL2EDGdhI2eYyxOeleeBaK9QEXgiA1A==} - dependencies: - '@babel/core': 7.24.4 - '@babel/eslint-parser': 7.24.1(@babel/core@7.24.4)(eslint@8.57.0) - '@babel/preset-env': 7.24.4(@babel/core@7.24.4) - '@babel/preset-react': 7.24.1(@babel/core@7.24.4) - '@rushstack/eslint-patch': 1.10.1 - '@typescript-eslint/eslint-plugin': 7.5.0(@typescript-eslint/parser@7.5.0)(eslint@8.57.0)(typescript@5.3.3) - '@typescript-eslint/parser': 7.5.0(eslint@8.57.0)(typescript@5.3.3) - confusing-browser-globals: 1.0.11 - eslint-plugin-jsx-a11y: 6.8.0(eslint@8.57.0) - eslint-plugin-react: 7.34.1(eslint@8.57.0) - eslint-plugin-react-hooks: 4.6.0(eslint@8.57.0) - transitivePeerDependencies: - - eslint - - supports-color - - typescript - dev: true - - /@sanity/eslint-config-studio@3.0.1(eslint@8.57.0)(typescript@5.4.4): + /@sanity/eslint-config-studio@3.0.1(eslint@8.57.0)(typescript@5.4.2): resolution: {integrity: sha512-N7IFd/VZuL0UyJ2T5t5WWWf9DrhgY6lt0bnnScwwyX4ijA7WMFtxR5rgL2EDGdhI2eYyxOeleeBaK9QEXgiA1A==} dependencies: '@babel/core': 7.24.4 @@ -6139,8 +6004,8 @@ packages: '@babel/preset-env': 7.24.4(@babel/core@7.24.4) '@babel/preset-react': 7.24.1(@babel/core@7.24.4) '@rushstack/eslint-patch': 1.10.1 - '@typescript-eslint/eslint-plugin': 7.5.0(@typescript-eslint/parser@7.5.0)(eslint@8.57.0)(typescript@5.4.4) - '@typescript-eslint/parser': 7.5.0(eslint@8.57.0)(typescript@5.4.4) + '@typescript-eslint/eslint-plugin': 7.5.0(@typescript-eslint/parser@7.5.0)(eslint@8.57.0)(typescript@5.4.2) + '@typescript-eslint/parser': 7.5.0(eslint@8.57.0)(typescript@5.4.2) confusing-browser-globals: 1.0.11 eslint-plugin-jsx-a11y: 6.8.0(eslint@8.57.0) eslint-plugin-react: 7.34.1(eslint@8.57.0) @@ -6259,8 +6124,8 @@ packages: sanity: link:packages/sanity dev: false - /@sanity/logos@2.1.9(@sanity/color@3.0.5)(react@18.2.0): - resolution: {integrity: sha512-E8dG8Cgz5+8lIIiRtzip2JIyy2Q6xZw4rVON42ib9uVYaMCrSjGbQ6HNVl4CBX3ZR4CIDcm1JTE8jhaLEU1v2g==} + /@sanity/logos@2.1.8(@sanity/color@3.0.5)(react@18.2.0): + resolution: {integrity: sha512-XqhxshTAebzN+aIfL99c992WbWjbEM049z+qsWDgD//+hm0rzHSvGmDNuKj3rO5vkzwCQEHgq1YCrsLvfCtBSQ==} engines: {node: '>=14.0.0'} peerDependencies: '@sanity/color': ^2.0 || ^3.0 || ^3.0.0-beta @@ -6270,64 +6135,12 @@ packages: react: 18.2.0 dev: false - /@sanity/pkg-utils@2.4.10(@types/node@18.19.29)(typescript@5.4.4): - resolution: {integrity: sha512-kqyOi84cPLlujdN+MzEZRvDBXI/Tqv9d+y/FGXhTx98jrCzDXOA4XN/iwlwDEtzK4FY8MncnYGrUyZW6NfUw4Q==} + /@sanity/pkg-utils@5.1.12(@types/node@18.19.29)(typescript@5.4.2): + resolution: {integrity: sha512-rrMsmgKhJfymWwcudcFIG96GCj/lFHQduew6A9yvmv1Z3/ng1FMg/AkHoiFwF36WqnPh3di+2Dmgq1se/T+k6w==} engines: {node: '>=16.0.0'} hasBin: true peerDependencies: - typescript: ^4.7 || ^5 - dependencies: - '@babel/core': 7.24.4 - '@babel/preset-env': 7.24.4(@babel/core@7.24.4) - '@babel/types': 7.24.0 - '@microsoft/api-extractor': 7.43.0(@types/node@18.19.29) - '@microsoft/tsdoc-config': 0.16.2 - '@rollup/plugin-alias': 5.1.0(rollup@3.29.4) - '@rollup/plugin-babel': 6.0.4(@babel/core@7.24.4)(rollup@3.29.4) - '@rollup/plugin-commonjs': 25.0.7(rollup@3.29.4) - '@rollup/plugin-json': 6.1.0(rollup@3.29.4) - '@rollup/plugin-node-resolve': 15.2.3(rollup@3.29.4) - '@rollup/plugin-replace': 5.0.5(rollup@3.29.4) - '@rollup/plugin-terser': 0.4.4(rollup@3.29.4) - browserslist: 4.23.0 - cac: 6.7.14 - chalk: 4.1.2 - chokidar: 3.6.0 - esbuild: 0.19.12 - esbuild-register: 3.5.0(esbuild@0.19.12) - find-config: 1.0.0 - get-latest-version: 5.1.0 - git-url-parse: 13.1.1 - globby: 11.1.0 - jsonc-parser: 3.2.1 - mkdirp: 3.0.1 - outdent: 0.8.0 - parse-git-config: 3.0.0 - pkg-up: 3.1.0 - prettier: 3.2.5 - prettier-plugin-packagejson: 2.4.14(prettier@3.2.5) - pretty-bytes: 5.6.0 - prompts: 2.4.2 - rimraf: 4.4.1 - rollup: 3.29.4 - rollup-plugin-esbuild: 6.1.1(esbuild@0.19.12)(rollup@3.29.4) - rollup-plugin-preserve-directives: 0.2.0(rollup@3.29.4) - rxjs: 7.8.1 - treeify: 1.1.0 - typescript: 5.4.4 - uuid: 9.0.1 - zod: 3.22.4 - transitivePeerDependencies: - - '@types/babel__core' - - '@types/node' - - supports-color - - /@sanity/pkg-utils@4.4.4(@types/node@18.19.29)(typescript@5.3.3): - resolution: {integrity: sha512-V6RbSeQtI0B2CfSzdGRXqrI9F00m8bHTR1dy4x/20QcA2WlbIbfdV9Po3HhVsZ70UkBLT3GnJ4CWZYgCLfqrdA==} - engines: {node: '>=16.0.0'} - hasBin: true - peerDependencies: - typescript: ^4.7 || ^5 + typescript: 5.4.2 dependencies: '@babel/core': 7.24.4 '@babel/types': 7.24.0 @@ -6365,14 +6178,13 @@ packages: rollup-plugin-esbuild: 6.1.1(esbuild@0.20.2)(rollup@4.14.1) rxjs: 7.8.1 treeify: 1.1.0 - typescript: 5.3.3 + typescript: 5.4.2 uuid: 9.0.1 zod: 3.22.4 transitivePeerDependencies: - '@types/babel__core' - '@types/node' - supports-color - dev: true /@sanity/presentation@1.11.4(@sanity/client@6.15.11)(react-dom@18.2.0)(react-is@18.2.0)(react@18.2.0)(styled-components@6.1.8): resolution: {integrity: sha512-vd4gOceLB02TzMahkBL5ViGU1AwKZvl4Y4sdY5MXIeGoUW2CJ9ys6iPQXaaylrKGMyK4WreGHCy51eZU0GLYuw==} @@ -6436,15 +6248,15 @@ packages: '@sanity/uuid': 3.0.2 dev: false - /@sanity/react-loader@1.9.9(@sanity/client@6.15.11)(react@18.2.0): - resolution: {integrity: sha512-27hAYdkf+Ar3zb7w9uEcktRRIusJ0p184oTRSjzFVEscOSHwFpjX2dnlbhL1k52XhuqkAW3oIHxaGKQLHyQ3EQ==} + /@sanity/react-loader@1.9.7(@sanity/client@6.15.11)(react@18.2.0): + resolution: {integrity: sha512-nu2MOJhNdWyhSW3DAW+YLz88OD/VNSxbcAuJhBL0xqVzSNGngzDM8gnyDBXEa6DK2MzMjFNtiRWQ1Eblvhz+Jw==} engines: {node: '>=18'} peerDependencies: - '@sanity/client': ^6.15.11 + '@sanity/client': ^6.15.10 react: ^18.2.0 dependencies: '@sanity/client': 6.15.11 - '@sanity/core-loader': 1.6.5(@sanity/client@6.15.11) + '@sanity/core-loader': 1.6.4(@sanity/client@6.15.11) fast-deep-equal: 3.1.3 react: 18.2.0 dev: false @@ -6472,35 +6284,36 @@ packages: - supports-color dev: true - /@sanity/tsdoc@1.0.0-alpha.44(@sanity/pkg-utils@2.4.10)(@types/node@18.19.29)(react-dom@18.2.0)(react-is@18.2.0)(react@18.2.0)(sanity@packages+sanity)(styled-components@6.1.8): - resolution: {integrity: sha512-LFVDxJ5FSaC6aZ9H/mwkEl7x1U21QcRhJGNlFbMSpt7G2dJNDKAy+alc6aXdkBjY/Gkf/flwB2jAdEwu860xKQ==} + /@sanity/tsdoc@1.0.13(@types/node@18.19.29)(react-dom@18.2.0)(react-is@18.2.0)(react@18.2.0)(sanity@packages+sanity)(styled-components@6.1.8): + resolution: {integrity: sha512-hlAzUfufTwWzvof7xCn0fgjfDPjrFmrnvwj6qITYXC6uCcprJyL1rWaBNX/Q7I+QX9cvcihQy7cDhMCZeazXxg==} engines: {node: '>=14.0.0'} hasBin: true peerDependencies: - '@sanity/pkg-utils': ^2.2 react: ^18 react-dom: ^18 sanity: ^3 - styled-components: ^5.2 + styled-components: ^5.2 || ^6 dependencies: - '@microsoft/api-extractor': 7.35.0(@types/node@18.19.29) - '@microsoft/api-extractor-model': 7.27.0(@types/node@18.19.29) + '@microsoft/api-extractor': 7.43.0(@types/node@18.19.29) + '@microsoft/api-extractor-model': 7.28.13(@types/node@18.19.29) '@microsoft/tsdoc': 0.14.2 '@microsoft/tsdoc-config': 0.16.2 '@portabletext/react': 3.0.17(react@18.2.0) '@portabletext/toolkit': 2.0.14 '@sanity/client': 6.15.11 - '@sanity/color': 2.2.5 + '@sanity/color': 3.0.5 '@sanity/icons': 2.11.7(react@18.2.0) - '@sanity/pkg-utils': 2.4.10(@types/node@18.19.29)(typescript@5.4.4) - '@sanity/ui': 1.9.3(react-dom@18.2.0)(react-is@18.2.0)(react@18.2.0)(styled-components@6.1.8) + '@sanity/pkg-utils': 5.1.12(@types/node@18.19.29)(typescript@5.4.2) + '@sanity/ui': 2.1.0(react-dom@18.2.0)(react-is@18.2.0)(react@18.2.0)(styled-components@6.1.8) '@types/cpx': 1.5.5 - '@vitejs/plugin-react': 4.2.1(vite@4.5.3) + '@vitejs/plugin-react': 4.2.1(vite@5.2.8) cac: 6.7.14 chalk: 4.1.2 chokidar: 3.6.0 cors: 2.8.5 dotenv-flow: 3.3.0 + esbuild: 0.20.2 + esbuild-register: 3.5.0(esbuild@0.20.2) express: 4.19.2 globby: 11.1.0 groq: 3.36.4 @@ -6516,64 +6329,10 @@ packages: slugify: 1.6.6 styled-components: 6.1.8(react-dom@18.2.0)(react@18.2.0) tmp: 0.2.3 - vite: 4.5.3(@types/node@18.19.29) - transitivePeerDependencies: - - '@types/node' - - less - - lightningcss - - react-is - - sass - - stylus - - sugarss - - supports-color - - terser - - /@sanity/tsdoc@1.0.0-alpha.44(@sanity/pkg-utils@4.4.4)(@types/node@18.19.29)(react-dom@18.2.0)(react-is@18.2.0)(react@18.2.0)(sanity@packages+sanity)(styled-components@5.3.11): - resolution: {integrity: sha512-LFVDxJ5FSaC6aZ9H/mwkEl7x1U21QcRhJGNlFbMSpt7G2dJNDKAy+alc6aXdkBjY/Gkf/flwB2jAdEwu860xKQ==} - engines: {node: '>=14.0.0'} - hasBin: true - peerDependencies: - '@sanity/pkg-utils': ^2.2 - react: ^18 - react-dom: ^18 - sanity: ^3 - styled-components: ^5.2 - dependencies: - '@microsoft/api-extractor': 7.35.0(@types/node@18.19.29) - '@microsoft/api-extractor-model': 7.27.0(@types/node@18.19.29) - '@microsoft/tsdoc': 0.14.2 - '@microsoft/tsdoc-config': 0.16.2 - '@portabletext/react': 3.0.17(react@18.2.0) - '@portabletext/toolkit': 2.0.14 - '@sanity/client': 6.15.11 - '@sanity/color': 2.2.5 - '@sanity/icons': 2.11.7(react@18.2.0) - '@sanity/pkg-utils': 4.4.4(@types/node@18.19.29)(typescript@5.3.3) - '@sanity/ui': 1.9.3(react-dom@18.2.0)(react-is@18.2.0)(react@18.2.0)(styled-components@5.3.11) - '@types/cpx': 1.5.5 - '@vitejs/plugin-react': 4.2.1(vite@4.5.3) - cac: 6.7.14 - chalk: 4.1.2 - chokidar: 3.6.0 - cors: 2.8.5 - dotenv-flow: 3.3.0 - express: 4.19.2 - globby: 11.1.0 - groq: 3.36.4 - groq-js: 1.7.0 - history: 5.3.0 - jsonc-parser: 3.2.1 - mkdirp: 1.0.4 - pkg-up: 3.1.0 - react: 18.2.0 - react-dom: 18.2.0(react@18.2.0) - react-refractor: 2.1.7(react@18.2.0) - sanity: link:packages/sanity - slugify: 1.6.6 - styled-components: 5.3.11(@babel/core@7.24.4)(react-dom@18.2.0)(react-is@18.2.0)(react@18.2.0) - tmp: 0.2.3 - vite: 4.5.3(@types/node@18.19.29) + typescript: 5.4.2 + vite: 5.2.8(@types/node@18.19.29) transitivePeerDependencies: + - '@types/babel__core' - '@types/node' - less - lightningcss @@ -6583,7 +6342,6 @@ packages: - sugarss - supports-color - terser - dev: true /@sanity/ui-workshop@1.2.11(@sanity/icons@2.11.7)(@sanity/ui@2.1.0)(@types/node@18.19.29)(react-dom@18.2.0)(react@18.2.0)(styled-components@6.1.8): resolution: {integrity: sha512-vzj7upIF7wq2W1HEA0D5VSkR8axaH4Rt07yNTAaas7CLgjSE9r2d+Gnkrq4FIbIuN1GYhhCD+D3/s60GaZrpQw==} @@ -6624,27 +6382,6 @@ packages: - supports-color - terser - /@sanity/ui@1.9.3(react-dom@18.2.0)(react-is@18.2.0)(react@18.2.0)(styled-components@5.3.11): - resolution: {integrity: sha512-AdWEVFaK0Snk6xxP0lGPVP3QQYKwzkfGFpFZnL9d6UtWt8yeuS8BMLVAzmXzg14hrqH50ex9nvNl3eq6a0MWiw==} - engines: {node: '>=14.0.0'} - peerDependencies: - react: ^18 - react-dom: ^18 - react-is: ^18 - styled-components: ^5.2 || ^6 - dependencies: - '@floating-ui/react-dom': 2.0.0(react-dom@18.2.0)(react@18.2.0) - '@sanity/color': 2.2.5 - '@sanity/icons': 2.11.7(react@18.2.0) - csstype: 3.1.3 - framer-motion: 10.18.0(react-dom@18.2.0)(react@18.2.0) - react: 18.2.0 - react-dom: 18.2.0(react@18.2.0) - react-is: 18.2.0 - react-refractor: 2.1.7(react@18.2.0) - styled-components: 5.3.11(@babel/core@7.24.4)(react-dom@18.2.0)(react-is@18.2.0)(react@18.2.0) - dev: true - /@sanity/ui@1.9.3(react-dom@18.2.0)(react-is@18.2.0)(react@18.2.0)(styled-components@6.1.8): resolution: {integrity: sha512-AdWEVFaK0Snk6xxP0lGPVP3QQYKwzkfGFpFZnL9d6UtWt8yeuS8BMLVAzmXzg14hrqH50ex9nvNl3eq6a0MWiw==} engines: {node: '>=14.0.0'} @@ -6664,6 +6401,7 @@ packages: react-is: 18.2.0 react-refractor: 2.1.7(react@18.2.0) styled-components: 6.1.8(react-dom@18.2.0)(react@18.2.0) + dev: false /@sanity/ui@2.1.0(react-dom@18.2.0)(react-is@18.2.0)(react@18.2.0)(styled-components@6.1.8): resolution: {integrity: sha512-iGqGlrDwgoAMjjlZpd8msOCh4GJAQ8he/KhiXUw/4wPH/NYETbuzHLS5EeIOeNL6fMH4tP/8fjm1hQ2BHAkBDw==} @@ -6860,26 +6598,26 @@ packages: resolution: {integrity: sha512-jtkwqdP2rY2iCCDVAFuaNBH3fiEi29aTn2RhtIoky8DTTiCdc48plpHHreLwmv1PICJ4AJUUESaq3xa8fZH8+g==} dev: false - /@testing-library/dom@10.0.0: - resolution: {integrity: sha512-PmJPnogldqoVFf+EwbHvbBJ98MmqASV8kLrBYgsDNxQcFMeIS7JFL48sfyXvuMtgmWO/wMhh25odr+8VhDmn4g==} - engines: {node: '>=18'} + /@testing-library/dom@8.20.1: + resolution: {integrity: sha512-/DiOQ5xBxgdYRC8LNk7U+RWat0S3qRLeIw3ZIkMQ9kkVlRmwD/Eg8k8CqIpD6GW7u20JIUOfMKbxtiLutpjQ4g==} + engines: {node: '>=12'} dependencies: '@babel/code-frame': 7.24.2 - '@babel/runtime': 7.24.4 + '@babel/runtime': 7.24.1 '@types/aria-query': 5.0.4 - aria-query: 5.3.0 + aria-query: 5.1.3 chalk: 4.1.2 dom-accessibility-api: 0.5.16 lz-string: 1.5.0 pretty-format: 27.5.1 dev: true - /@testing-library/dom@8.20.1: - resolution: {integrity: sha512-/DiOQ5xBxgdYRC8LNk7U+RWat0S3qRLeIw3ZIkMQ9kkVlRmwD/Eg8k8CqIpD6GW7u20JIUOfMKbxtiLutpjQ4g==} - engines: {node: '>=12'} + /@testing-library/dom@9.3.4: + resolution: {integrity: sha512-FlS4ZWlp97iiNWig0Muq8p+3rVDjRiYE+YKGbAqXOu9nwJFFOdL00kFpz42M+4huzYi86vAK1sOOfyOG45muIQ==} + engines: {node: '>=14'} dependencies: '@babel/code-frame': 7.24.2 - '@babel/runtime': 7.24.4 + '@babel/runtime': 7.24.1 '@types/aria-query': 5.0.4 aria-query: 5.1.3 chalk: 4.1.2 @@ -6910,7 +6648,7 @@ packages: optional: true dependencies: '@adobe/css-tools': 4.3.3 - '@babel/runtime': 7.24.4 + '@babel/runtime': 7.24.1 '@jest/globals': 29.7.0 aria-query: 5.3.0 chalk: 3.0.0 @@ -6928,21 +6666,21 @@ packages: react: ^18.0.0 react-dom: ^18.0.0 dependencies: - '@babel/runtime': 7.24.4 + '@babel/runtime': 7.24.1 '@testing-library/dom': 8.20.1 '@types/react-dom': 18.2.23 react: 18.2.0 react-dom: 18.2.0(react@18.2.0) dev: true - /@testing-library/user-event@13.5.0(@testing-library/dom@10.0.0): + /@testing-library/user-event@13.5.0(@testing-library/dom@9.3.4): resolution: {integrity: sha512-5Kwtbo3Y/NowpkbRuSepbyMFkZmHgD+vPzYB/RJ4oxt5Gj/avFFBYjhw27cqSVPVw/3a67NK1PbiIr9k4Gwmdg==} engines: {node: '>=10', npm: '>=6'} peerDependencies: '@testing-library/dom': '>=7.21.4' dependencies: - '@babel/runtime': 7.24.4 - '@testing-library/dom': 10.0.0 + '@babel/runtime': 7.24.1 + '@testing-library/dom': 9.3.4 dev: true /@tootallnate/once@2.0.0: @@ -7481,46 +7219,17 @@ packages: '@types/node': 18.19.29 dev: true - /@types/yargs-parser@21.0.3: - resolution: {integrity: sha512-I4q9QU9MQv4oEOz4tAHJtNz1cwuLxn2F3xcc2iV5WdqLPpUnj30aUuxt1mAxYTG+oe8CZMV/+6rU4S4gRDzqtQ==} - dev: true - - /@types/yargs@17.0.32: - resolution: {integrity: sha512-xQ67Yc/laOG5uMfX/093MRlGGCIBzZMarVa+gfNKJxWAIgykYpVGkBdbqEzGDDfCrVUj6Hiff4mTZ5BA6TmAog==} - dependencies: - '@types/yargs-parser': 21.0.3 - dev: true - - /@typescript-eslint/eslint-plugin@7.5.0(@typescript-eslint/parser@7.5.0)(eslint@8.57.0)(typescript@5.3.3): - resolution: {integrity: sha512-HpqNTH8Du34nLxbKgVMGljZMG0rJd2O9ecvr2QLYp+7512ty1j42KnsFwspPXg1Vh8an9YImf6CokUBltisZFQ==} - engines: {node: ^18.18.0 || >=20.0.0} - peerDependencies: - '@typescript-eslint/parser': ^7.5.0 - eslint: ^8.56.0 - typescript: '*' - peerDependenciesMeta: - typescript: - optional: true - dependencies: - '@eslint-community/regexpp': 4.10.0 - '@typescript-eslint/parser': 7.5.0(eslint@8.57.0)(typescript@5.3.3) - '@typescript-eslint/scope-manager': 7.5.0 - '@typescript-eslint/type-utils': 7.5.0(eslint@8.57.0)(typescript@5.3.3) - '@typescript-eslint/utils': 7.5.0(eslint@8.57.0)(typescript@5.3.3) - '@typescript-eslint/visitor-keys': 7.5.0 - debug: 4.3.4(supports-color@5.5.0) - eslint: 8.57.0 - graphemer: 1.4.0 - ignore: 5.3.1 - natural-compare: 1.4.0 - semver: 7.6.0 - ts-api-utils: 1.3.0(typescript@5.3.3) - typescript: 5.3.3 - transitivePeerDependencies: - - supports-color - dev: true - - /@typescript-eslint/eslint-plugin@7.5.0(@typescript-eslint/parser@7.5.0)(eslint@8.57.0)(typescript@5.4.4): + /@types/yargs-parser@21.0.3: + resolution: {integrity: sha512-I4q9QU9MQv4oEOz4tAHJtNz1cwuLxn2F3xcc2iV5WdqLPpUnj30aUuxt1mAxYTG+oe8CZMV/+6rU4S4gRDzqtQ==} + dev: true + + /@types/yargs@17.0.32: + resolution: {integrity: sha512-xQ67Yc/laOG5uMfX/093MRlGGCIBzZMarVa+gfNKJxWAIgykYpVGkBdbqEzGDDfCrVUj6Hiff4mTZ5BA6TmAog==} + dependencies: + '@types/yargs-parser': 21.0.3 + dev: true + + /@typescript-eslint/eslint-plugin@7.5.0(@typescript-eslint/parser@7.5.0)(eslint@8.57.0)(typescript@5.4.2): resolution: {integrity: sha512-HpqNTH8Du34nLxbKgVMGljZMG0rJd2O9ecvr2QLYp+7512ty1j42KnsFwspPXg1Vh8an9YImf6CokUBltisZFQ==} engines: {node: ^18.18.0 || >=20.0.0} peerDependencies: @@ -7532,45 +7241,24 @@ packages: optional: true dependencies: '@eslint-community/regexpp': 4.10.0 - '@typescript-eslint/parser': 7.5.0(eslint@8.57.0)(typescript@5.4.4) + '@typescript-eslint/parser': 7.5.0(eslint@8.57.0)(typescript@5.4.2) '@typescript-eslint/scope-manager': 7.5.0 - '@typescript-eslint/type-utils': 7.5.0(eslint@8.57.0)(typescript@5.4.4) - '@typescript-eslint/utils': 7.5.0(eslint@8.57.0)(typescript@5.4.4) + '@typescript-eslint/type-utils': 7.5.0(eslint@8.57.0)(typescript@5.4.2) + '@typescript-eslint/utils': 7.5.0(eslint@8.57.0)(typescript@5.4.2) '@typescript-eslint/visitor-keys': 7.5.0 - debug: 4.3.4(supports-color@5.5.0) + debug: 4.3.4(supports-color@9.4.0) eslint: 8.57.0 graphemer: 1.4.0 ignore: 5.3.1 natural-compare: 1.4.0 semver: 7.6.0 - ts-api-utils: 1.3.0(typescript@5.4.4) - typescript: 5.4.4 - transitivePeerDependencies: - - supports-color - dev: true - - /@typescript-eslint/parser@7.5.0(eslint@8.57.0)(typescript@5.3.3): - resolution: {integrity: sha512-cj+XGhNujfD2/wzR1tabNsidnYRaFfEkcULdcIyVBYcXjBvBKOes+mpMBP7hMpOyk+gBcfXsrg4NBGAStQyxjQ==} - engines: {node: ^18.18.0 || >=20.0.0} - peerDependencies: - eslint: ^8.56.0 - typescript: '*' - peerDependenciesMeta: - typescript: - optional: true - dependencies: - '@typescript-eslint/scope-manager': 7.5.0 - '@typescript-eslint/types': 7.5.0 - '@typescript-eslint/typescript-estree': 7.5.0(typescript@5.3.3) - '@typescript-eslint/visitor-keys': 7.5.0 - debug: 4.3.4(supports-color@5.5.0) - eslint: 8.57.0 - typescript: 5.3.3 + ts-api-utils: 1.3.0(typescript@5.4.2) + typescript: 5.4.2 transitivePeerDependencies: - supports-color dev: true - /@typescript-eslint/parser@7.5.0(eslint@8.57.0)(typescript@5.4.4): + /@typescript-eslint/parser@7.5.0(eslint@8.57.0)(typescript@5.4.2): resolution: {integrity: sha512-cj+XGhNujfD2/wzR1tabNsidnYRaFfEkcULdcIyVBYcXjBvBKOes+mpMBP7hMpOyk+gBcfXsrg4NBGAStQyxjQ==} engines: {node: ^18.18.0 || >=20.0.0} peerDependencies: @@ -7582,11 +7270,11 @@ packages: dependencies: '@typescript-eslint/scope-manager': 7.5.0 '@typescript-eslint/types': 7.5.0 - '@typescript-eslint/typescript-estree': 7.5.0(typescript@5.4.4) + '@typescript-eslint/typescript-estree': 7.5.0(typescript@5.4.2) '@typescript-eslint/visitor-keys': 7.5.0 - debug: 4.3.4(supports-color@5.5.0) + debug: 4.3.4(supports-color@9.4.0) eslint: 8.57.0 - typescript: 5.4.4 + typescript: 5.4.2 transitivePeerDependencies: - supports-color dev: true @@ -7599,27 +7287,7 @@ packages: '@typescript-eslint/visitor-keys': 7.5.0 dev: true - /@typescript-eslint/type-utils@7.5.0(eslint@8.57.0)(typescript@5.3.3): - resolution: {integrity: sha512-A021Rj33+G8mx2Dqh0nMO9GyjjIBK3MqgVgZ2qlKf6CJy51wY/lkkFqq3TqqnH34XyAHUkq27IjlUkWlQRpLHw==} - engines: {node: ^18.18.0 || >=20.0.0} - peerDependencies: - eslint: ^8.56.0 - typescript: '*' - peerDependenciesMeta: - typescript: - optional: true - dependencies: - '@typescript-eslint/typescript-estree': 7.5.0(typescript@5.3.3) - '@typescript-eslint/utils': 7.5.0(eslint@8.57.0)(typescript@5.3.3) - debug: 4.3.4(supports-color@5.5.0) - eslint: 8.57.0 - ts-api-utils: 1.3.0(typescript@5.3.3) - typescript: 5.3.3 - transitivePeerDependencies: - - supports-color - dev: true - - /@typescript-eslint/type-utils@7.5.0(eslint@8.57.0)(typescript@5.4.4): + /@typescript-eslint/type-utils@7.5.0(eslint@8.57.0)(typescript@5.4.2): resolution: {integrity: sha512-A021Rj33+G8mx2Dqh0nMO9GyjjIBK3MqgVgZ2qlKf6CJy51wY/lkkFqq3TqqnH34XyAHUkq27IjlUkWlQRpLHw==} engines: {node: ^18.18.0 || >=20.0.0} peerDependencies: @@ -7629,12 +7297,12 @@ packages: typescript: optional: true dependencies: - '@typescript-eslint/typescript-estree': 7.5.0(typescript@5.4.4) - '@typescript-eslint/utils': 7.5.0(eslint@8.57.0)(typescript@5.4.4) - debug: 4.3.4(supports-color@5.5.0) + '@typescript-eslint/typescript-estree': 7.5.0(typescript@5.4.2) + '@typescript-eslint/utils': 7.5.0(eslint@8.57.0)(typescript@5.4.2) + debug: 4.3.4(supports-color@9.4.0) eslint: 8.57.0 - ts-api-utils: 1.3.0(typescript@5.4.4) - typescript: 5.4.4 + ts-api-utils: 1.3.0(typescript@5.4.2) + typescript: 5.4.2 transitivePeerDependencies: - supports-color dev: true @@ -7644,29 +7312,7 @@ packages: engines: {node: ^18.18.0 || >=20.0.0} dev: true - /@typescript-eslint/typescript-estree@7.5.0(typescript@5.3.3): - resolution: {integrity: sha512-YklQQfe0Rv2PZEueLTUffiQGKQneiIEKKnfIqPIOxgM9lKSZFCjT5Ad4VqRKj/U4+kQE3fa8YQpskViL7WjdPQ==} - engines: {node: ^18.18.0 || >=20.0.0} - peerDependencies: - typescript: '*' - peerDependenciesMeta: - typescript: - optional: true - dependencies: - '@typescript-eslint/types': 7.5.0 - '@typescript-eslint/visitor-keys': 7.5.0 - debug: 4.3.4(supports-color@5.5.0) - globby: 11.1.0 - is-glob: 4.0.3 - minimatch: 9.0.3 - semver: 7.6.0 - ts-api-utils: 1.3.0(typescript@5.3.3) - typescript: 5.3.3 - transitivePeerDependencies: - - supports-color - dev: true - - /@typescript-eslint/typescript-estree@7.5.0(typescript@5.4.4): + /@typescript-eslint/typescript-estree@7.5.0(typescript@5.4.2): resolution: {integrity: sha512-YklQQfe0Rv2PZEueLTUffiQGKQneiIEKKnfIqPIOxgM9lKSZFCjT5Ad4VqRKj/U4+kQE3fa8YQpskViL7WjdPQ==} engines: {node: ^18.18.0 || >=20.0.0} peerDependencies: @@ -7677,37 +7323,18 @@ packages: dependencies: '@typescript-eslint/types': 7.5.0 '@typescript-eslint/visitor-keys': 7.5.0 - debug: 4.3.4(supports-color@5.5.0) + debug: 4.3.4(supports-color@9.4.0) globby: 11.1.0 is-glob: 4.0.3 minimatch: 9.0.3 semver: 7.6.0 - ts-api-utils: 1.3.0(typescript@5.4.4) - typescript: 5.4.4 - transitivePeerDependencies: - - supports-color - dev: true - - /@typescript-eslint/utils@7.5.0(eslint@8.57.0)(typescript@5.3.3): - resolution: {integrity: sha512-3vZl9u0R+/FLQcpy2EHyRGNqAS/ofJ3Ji8aebilfJe+fobK8+LbIFmrHciLVDxjDoONmufDcnVSF38KwMEOjzw==} - engines: {node: ^18.18.0 || >=20.0.0} - peerDependencies: - eslint: ^8.56.0 - dependencies: - '@eslint-community/eslint-utils': 4.4.0(eslint@8.57.0) - '@types/json-schema': 7.0.15 - '@types/semver': 7.5.8 - '@typescript-eslint/scope-manager': 7.5.0 - '@typescript-eslint/types': 7.5.0 - '@typescript-eslint/typescript-estree': 7.5.0(typescript@5.3.3) - eslint: 8.57.0 - semver: 7.6.0 + ts-api-utils: 1.3.0(typescript@5.4.2) + typescript: 5.4.2 transitivePeerDependencies: - supports-color - - typescript dev: true - /@typescript-eslint/utils@7.5.0(eslint@8.57.0)(typescript@5.4.4): + /@typescript-eslint/utils@7.5.0(eslint@8.57.0)(typescript@5.4.2): resolution: {integrity: sha512-3vZl9u0R+/FLQcpy2EHyRGNqAS/ofJ3Ji8aebilfJe+fobK8+LbIFmrHciLVDxjDoONmufDcnVSF38KwMEOjzw==} engines: {node: ^18.18.0 || >=20.0.0} peerDependencies: @@ -7718,7 +7345,7 @@ packages: '@types/semver': 7.5.8 '@typescript-eslint/scope-manager': 7.5.0 '@typescript-eslint/types': 7.5.0 - '@typescript-eslint/typescript-estree': 7.5.0(typescript@5.4.4) + '@typescript-eslint/typescript-estree': 7.5.0(typescript@5.4.2) eslint: 8.57.0 semver: 7.6.0 transitivePeerDependencies: @@ -7754,7 +7381,7 @@ packages: '@codemirror/view': 6.26.1 dev: false - /@uiw/react-codemirror@4.21.25(@babel/runtime@7.24.4)(@codemirror/autocomplete@6.15.0)(@codemirror/language@6.10.1)(@codemirror/lint@6.5.0)(@codemirror/search@6.5.6)(@codemirror/state@6.4.1)(@codemirror/theme-one-dark@6.1.2)(@codemirror/view@6.26.1)(codemirror@6.0.1)(react-dom@18.2.0)(react@18.2.0): + /@uiw/react-codemirror@4.21.25(@babel/runtime@7.24.1)(@codemirror/autocomplete@6.15.0)(@codemirror/language@6.10.1)(@codemirror/lint@6.5.0)(@codemirror/search@6.5.6)(@codemirror/state@6.4.1)(@codemirror/theme-one-dark@6.1.2)(@codemirror/view@6.26.1)(codemirror@6.0.1)(react-dom@18.2.0)(react@18.2.0): resolution: {integrity: sha512-mBrCoiffQ+hbTqV1JoixFEcH7BHXkS3PjTyNH7dE8Gzf3GSBRazhtSM5HrAFIiQ5FIRGFs8Gznc4UAdhtevMmw==} peerDependencies: '@babel/runtime': '>=7.11.0' @@ -7765,7 +7392,7 @@ packages: react: '>=16.8.0' react-dom: '>=16.8.0' dependencies: - '@babel/runtime': 7.24.4 + '@babel/runtime': 7.24.1 '@codemirror/commands': 6.3.3 '@codemirror/state': 6.4.1 '@codemirror/theme-one-dark': 6.1.2 @@ -7848,6 +7475,21 @@ packages: transitivePeerDependencies: - supports-color + /@vitejs/plugin-react@4.2.1(vite@5.2.8): + resolution: {integrity: sha512-oojO9IDc4nCUUi8qIR11KoQm0XFFLIwsRBwHRR4d/88IWghn1y6ckz/bJ8GHDCsYEJee8mDzqtJxh15/cisJNQ==} + engines: {node: ^14.18.0 || >=16.0.0} + peerDependencies: + vite: ^4.2.0 || ^5.0.0 + dependencies: + '@babel/core': 7.24.4 + '@babel/plugin-transform-react-jsx-self': 7.24.1(@babel/core@7.24.4) + '@babel/plugin-transform-react-jsx-source': 7.24.1(@babel/core@7.24.4) + '@types/babel__core': 7.20.5 + react-refresh: 0.14.0 + vite: 5.2.8(@types/node@18.19.29) + transitivePeerDependencies: + - supports-color + /@vue/compiler-core@3.4.21: resolution: {integrity: sha512-MjXawxZf2SbZszLPYxaFCjxfibYrzr3eYbKxwpLR9EQN+oaziSu3qKVbwBERj1IFIB8OLUewxB5m/BFzi613og==} dependencies: @@ -7874,7 +7516,7 @@ packages: '@vue/compiler-ssr': 3.4.21 '@vue/shared': 3.4.21 estree-walker: 2.0.2 - magic-string: 0.30.9 + magic-string: 0.30.8 postcss: 8.4.38 source-map-js: 1.2.0 dev: true @@ -7974,7 +7616,7 @@ packages: resolution: {integrity: sha512-RZNwNclF7+MS/8bDg70amg32dyeZGZxiDuQmZxKLAlQjr3jGyLx+4Kkk58UO7D2QdgFIQCovuSuZESne6RG6XQ==} engines: {node: '>= 6.0.0'} dependencies: - debug: 4.3.4(supports-color@5.5.0) + debug: 4.3.4(supports-color@9.4.0) transitivePeerDependencies: - supports-color dev: true @@ -7983,7 +7625,7 @@ packages: resolution: {integrity: sha512-H0TSyFNDMomMNJQBn8wFV5YC/2eJ+VXECwOadZJT554xP6cODZHPX3H9QMQECxvrgiSOP1pHjy1sMWQVYJOUOA==} engines: {node: '>= 14'} dependencies: - debug: 4.3.4(supports-color@5.5.0) + debug: 4.3.4(supports-color@9.4.0) transitivePeerDependencies: - supports-color @@ -8472,21 +8114,6 @@ packages: transitivePeerDependencies: - supports-color - /babel-plugin-styled-components@2.1.4(@babel/core@7.24.4)(styled-components@5.3.11): - resolution: {integrity: sha512-Xgp9g+A/cG47sUyRwwYxGM4bR/jDRg5N6it/8+HxCnbT5XNKSKDT9xm4oag/osgqjC2It/vH0yXsomOG6k558g==} - peerDependencies: - styled-components: '>= 2' - dependencies: - '@babel/helper-annotate-as-pure': 7.22.5 - '@babel/helper-module-imports': 7.24.3 - '@babel/plugin-syntax-jsx': 7.24.1(@babel/core@7.24.4) - lodash: 4.17.21 - picomatch: 2.3.1 - styled-components: 5.3.11(@babel/core@7.24.4)(react-dom@18.2.0)(react-is@18.2.0)(react@18.2.0) - transitivePeerDependencies: - - '@babel/core' - dev: true - /babel-preset-current-node-syntax@1.0.1(@babel/core@7.24.4): resolution: {integrity: sha512-M7LQ0bxarkxQoN+vz5aJPsLBn77n8QgTFmo8WK0/44auK2xlCXrYcUxHFxgU7qW5Yzw/CjmLRK2uJzaCd7LvqQ==} peerDependencies: @@ -8869,7 +8496,7 @@ packages: /caniuse-lite@1.0.30001605: resolution: {integrity: sha512-nXwGlFWo34uliI9z3n6Qc0wZaf7zaZWA1CPZ169La5mV3I/gem7bst0vr5XQH5TJXZIMfDeZyOrZnSlVzKxxHQ==} - /cannon-es-debugger@1.0.0(cannon-es@0.20.0)(three@0.157.0)(typescript@5.4.4): + /cannon-es-debugger@1.0.0(cannon-es@0.20.0)(three@0.157.0)(typescript@5.4.2): resolution: {integrity: sha512-sE9lDOBAYFKlh+0w+cvWKwUhJef8HYnUSVPWPL0jD15MAuVRQKno4QYZSGxgOoJkMR3mQqxL4bxys2b3RSWH8g==} peerDependencies: cannon-es: 0.x @@ -8881,17 +8508,15 @@ packages: dependencies: cannon-es: 0.20.0 three: 0.157.0 - typescript: 5.4.4 + typescript: 5.4.2 dev: false /cannon-es@0.20.0: resolution: {integrity: sha512-eZhWTZIkFOnMAJOgfXJa9+b3kVlvG+FX4mdkpePev/w/rP5V8NRquGyEozcjPfEoXUlb+p7d9SUcmDSn14prOA==} dev: false - /castable-video@1.0.6: - resolution: {integrity: sha512-Ykw2uL4ZQnqX0j9KF9ksbDpyc8I53mFMswCKW9yV5TrwpWkdNqRHLlcU85W30BIw61fgDjgm0Xh5G0rbcmv23g==} - dependencies: - custom-media-element: 1.2.3 + /castable-video@0.5.2: + resolution: {integrity: sha512-eP19NY8AF9G+Xj87R447GMkWuUc0W3DSNx5qOypH/+mr2aaHRONaIK5H4bxMgpXZslZ2vNNvCuVuKi3VdCUGEA==} dev: false /chalk@2.4.2: @@ -9185,10 +8810,6 @@ packages: resolution: {integrity: sha512-IfEDxwoWIjkeXL1eXcDiow4UbKjhLdq6/EuSVR9GMN7KVH3r9gQ83e73hsz1Nd1T3ijd5xv1wcWRYO+D6kCI2w==} dev: true - /colors@1.2.5: - resolution: {integrity: sha512-erNRLao/Y3Fv54qUa0LBB+//Uf3YwMUmdJinN20yMXm9zdKKqH9wt7R9IIVZ+K7ShzfpLV/Zg8+VyrBJYB4lpg==} - engines: {node: '>=0.1.90'} - /columnify@1.6.0: resolution: {integrity: sha512-lomjuFZKfM6MSAnV9aCZC9sc0qGbmZdfygNv+nCpqVkSKdCxCklLtd16O0EILGkImHw9ZpHkAnHaB+8Zxq5W6Q==} engines: {node: '>=8.0.0'} @@ -9434,7 +9055,7 @@ packages: yaml: 1.10.2 dev: true - /cosmiconfig@8.3.6(typescript@5.4.4): + /cosmiconfig@8.3.6(typescript@5.4.2): resolution: {integrity: sha512-kcZ6+W5QzcJ3P1Mt+83OUv/oHFqZHIx8DuxG6eZ5RGMERoLqp4BuGjhHLYGK+Kf5XVkQvqBSmAy/nGWN3qDgEA==} engines: {node: '>=14'} peerDependencies: @@ -9447,7 +9068,7 @@ packages: js-yaml: 4.1.0 parse-json: 5.2.0 path-type: 4.0.0 - typescript: 5.4.4 + typescript: 5.4.2 dev: true /cpx@1.5.0: @@ -9593,8 +9214,8 @@ packages: /csstype@3.1.3: resolution: {integrity: sha512-M1uQkMl8rQK/szD0LNhtqxIPLpimGm8sOBwU7lLnCpSbTyY3yeU1Vc7l4KT5zT4s/yOxHH5O7tIuuLOCnLADRw==} - /custom-media-element@1.2.3: - resolution: {integrity: sha512-xr9Hbrslkjm1fapJP5hL98pySeZmNepBSefQS/XTxynamqPTfRBK5MnhReMOiAj8xvJApVPrVnlYxIrknay8jg==} + /custom-media-element@0.2.0: + resolution: {integrity: sha512-N++UzR1COFip4DrtZkS99VDCcQvVCJmbqI7qaxZtHWKdAv/RUYIOnmJbP/HHk2un0PjvtFNKHfNLiFsd9BmnMQ==} dev: false /cwd@0.10.0: @@ -9673,7 +9294,7 @@ packages: resolution: {integrity: sha512-fnULvOpxnC5/Vg3NCiWelDsLiUc9bRwAPs/+LfTLNvetFCtCTN+yQz15C/fs4AwX1R9K5GLtLfn8QW+dWisaAw==} engines: {node: '>=0.11'} dependencies: - '@babel/runtime': 7.24.4 + '@babel/runtime': 7.24.1 dev: false /date-now@1.0.1: @@ -9714,18 +9335,6 @@ packages: dependencies: ms: 2.1.3 - /debug@4.3.4(supports-color@5.5.0): - resolution: {integrity: sha512-PRWFHuSU3eDtQJPvnNY7Jcket1j0t5OuOsFzPPzsekD52Zl8qUfFIPEiswXqIvHWGVHOgX+7G/vCNNhehwxfkQ==} - engines: {node: '>=6.0'} - peerDependencies: - supports-color: '*' - peerDependenciesMeta: - supports-color: - optional: true - dependencies: - ms: 2.1.2 - supports-color: 5.5.0 - /debug@4.3.4(supports-color@9.4.0): resolution: {integrity: sha512-PRWFHuSU3eDtQJPvnNY7Jcket1j0t5OuOsFzPPzsekD52Zl8qUfFIPEiswXqIvHWGVHOgX+7G/vCNNhehwxfkQ==} engines: {node: '>=6.0'} @@ -9737,7 +9346,6 @@ packages: dependencies: ms: 2.1.2 supports-color: 9.4.0 - dev: true /decamelize-keys@1.1.1: resolution: {integrity: sha512-WiPxgEirIV0/eIOMcnFBA3/IJZAZqKnwAwWyvvdi4lsr1WCN22nhdf/3db3DoZcUjTV2SqfzIwNyp6y2xs3nmg==} @@ -9934,12 +9542,12 @@ packages: hasBin: true dependencies: '@babel/parser': 7.24.4 - '@babel/traverse': 7.24.1(supports-color@5.5.0) + '@babel/traverse': 7.24.1 '@vue/compiler-sfc': 3.4.21 callsite: 1.0.0 camelcase: 6.3.0 cosmiconfig: 7.1.0 - debug: 4.3.4(supports-color@5.5.0) + debug: 4.3.4(supports-color@9.4.0) deps-regex: 0.2.0 findup-sync: 5.0.0 ignore: 5.3.1 @@ -10352,7 +9960,7 @@ packages: peerDependencies: esbuild: '>=0.12 <1' dependencies: - debug: 4.3.4(supports-color@5.5.0) + debug: 4.3.4(supports-color@9.4.0) esbuild: 0.19.12 transitivePeerDependencies: - supports-color @@ -10362,7 +9970,7 @@ packages: peerDependencies: esbuild: '>=0.12 <1' dependencies: - debug: 4.3.4(supports-color@5.5.0) + debug: 4.3.4(supports-color@9.4.0) esbuild: 0.20.2 transitivePeerDependencies: - supports-color @@ -10489,7 +10097,7 @@ packages: source-map: 0.6.1 dev: true - /eslint-config-next@14.1.4(eslint@8.57.0)(typescript@5.4.4): + /eslint-config-next@14.1.4(eslint@8.57.0)(typescript@5.4.2): resolution: {integrity: sha512-cihIahbhYAWwXJwZkAaRPpUi5t9aOi/HdfWXOjZeUOqNWXHD8X22kd1KG58Dc3MVaRx3HoR/oMGk2ltcrqDn8g==} peerDependencies: eslint: ^7.23.0 || ^8.0.0 @@ -10500,7 +10108,7 @@ packages: dependencies: '@next/eslint-plugin-next': 14.1.4 '@rushstack/eslint-patch': 1.10.1 - '@typescript-eslint/parser': 7.5.0(eslint@8.57.0)(typescript@5.4.4) + '@typescript-eslint/parser': 7.5.0(eslint@8.57.0)(typescript@5.4.2) eslint: 8.57.0 eslint-import-resolver-node: 0.3.9 eslint-import-resolver-typescript: 3.6.1(@typescript-eslint/parser@7.5.0)(eslint-import-resolver-node@0.3.9)(eslint-plugin-import@2.29.1)(eslint@8.57.0) @@ -10508,7 +10116,7 @@ packages: eslint-plugin-jsx-a11y: 6.8.0(eslint@8.57.0) eslint-plugin-react: 7.34.1(eslint@8.57.0) eslint-plugin-react-hooks: 4.6.0(eslint@8.57.0) - typescript: 5.4.4 + typescript: 5.4.2 transitivePeerDependencies: - eslint-import-resolver-webpack - supports-color @@ -10545,8 +10153,8 @@ packages: eslint-plugin-react-hooks: optional: true dependencies: - '@typescript-eslint/eslint-plugin': 7.5.0(@typescript-eslint/parser@7.5.0)(eslint@8.57.0)(typescript@5.3.3) - '@typescript-eslint/parser': 7.5.0(eslint@8.57.0)(typescript@5.3.3) + '@typescript-eslint/eslint-plugin': 7.5.0(@typescript-eslint/parser@7.5.0)(eslint@8.57.0)(typescript@5.4.2) + '@typescript-eslint/parser': 7.5.0(eslint@8.57.0)(typescript@5.4.2) eslint: 8.57.0 eslint-plugin-import: 2.29.1(@typescript-eslint/parser@7.5.0)(eslint-import-resolver-typescript@3.6.1)(eslint@8.57.0) eslint-plugin-react: 7.34.1(eslint@8.57.0) @@ -10571,7 +10179,7 @@ packages: eslint: '*' eslint-plugin-import: '*' dependencies: - debug: 4.3.4(supports-color@5.5.0) + debug: 4.3.4(supports-color@9.4.0) enhanced-resolve: 5.16.0 eslint: 8.57.0 eslint-module-utils: 2.8.1(@typescript-eslint/parser@7.5.0)(eslint-import-resolver-node@0.3.9)(eslint-import-resolver-typescript@3.6.1)(eslint@8.57.0) @@ -10608,7 +10216,7 @@ packages: eslint-import-resolver-webpack: optional: true dependencies: - '@typescript-eslint/parser': 7.5.0(eslint@8.57.0)(typescript@5.3.3) + '@typescript-eslint/parser': 7.5.0(eslint@8.57.0)(typescript@5.4.2) debug: 3.2.7 eslint: 8.57.0 eslint-import-resolver-node: 0.3.9 @@ -10638,7 +10246,7 @@ packages: eslint-import-resolver-webpack: optional: true dependencies: - '@typescript-eslint/parser': 7.5.0(eslint@8.57.0)(typescript@5.3.3) + '@typescript-eslint/parser': 7.5.0(eslint@8.57.0)(typescript@5.4.2) debug: 3.2.7 eslint: 8.57.0 eslint-import-resolver-node: 0.3.9 @@ -10684,7 +10292,7 @@ packages: '@typescript-eslint/parser': optional: true dependencies: - '@typescript-eslint/parser': 7.5.0(eslint@8.57.0)(typescript@5.3.3) + '@typescript-eslint/parser': 7.5.0(eslint@8.57.0)(typescript@5.4.2) array-includes: 3.1.8 array.prototype.findlastindex: 1.2.5 array.prototype.flat: 1.3.2 @@ -10715,7 +10323,7 @@ packages: peerDependencies: eslint: ^3 || ^4 || ^5 || ^6 || ^7 || ^8 dependencies: - '@babel/runtime': 7.24.4 + '@babel/runtime': 7.24.1 aria-query: 5.3.0 array-includes: 3.1.8 array.prototype.flatmap: 1.3.2 @@ -10816,7 +10424,7 @@ packages: '@typescript-eslint/eslint-plugin': optional: true dependencies: - '@typescript-eslint/eslint-plugin': 7.5.0(@typescript-eslint/parser@7.5.0)(eslint@8.57.0)(typescript@5.3.3) + '@typescript-eslint/eslint-plugin': 7.5.0(@typescript-eslint/parser@7.5.0)(eslint@8.57.0)(typescript@5.4.2) eslint: 8.57.0 eslint-rule-composer: 0.3.0 dev: true @@ -10868,7 +10476,7 @@ packages: ajv: 6.12.6 chalk: 4.1.2 cross-spawn: 7.0.3 - debug: 4.3.4(supports-color@5.5.0) + debug: 4.3.4(supports-color@9.4.0) doctrine: 3.0.0 escape-string-regexp: 4.0.0 eslint-scope: 7.2.2 @@ -11387,7 +10995,7 @@ packages: dependencies: chalk: 4.1.2 commander: 5.1.0 - debug: 4.3.4(supports-color@5.5.0) + debug: 4.3.4(supports-color@9.4.0) transitivePeerDependencies: - supports-color dev: true @@ -11489,7 +11097,7 @@ packages: debug: optional: true dependencies: - debug: 4.3.4(supports-color@5.5.0) + debug: 4.3.4(supports-color@9.4.0) /for-each@0.3.3: resolution: {integrity: sha512-jqYfLp7mo9vIyQf8ykW2v7A+2N4QjeCeI5+Dz9XraiO1ign81wjiH7Fb9vSOWvQfNtmSa4H2RoQTrrXivdUZmw==} @@ -11550,6 +11158,7 @@ packages: tslib: 2.6.2 optionalDependencies: '@emotion/is-prop-valid': 0.8.8 + dev: false /framer-motion@11.0.8(react-dom@18.2.0)(react@18.2.0): resolution: {integrity: sha512-1KSGNuqe1qZkS/SWQlDnqK2VCVzRVEoval379j0FiUBJAZoqgwyvqFkfvJbgW2IPFo4wX16K+M0k5jO23lCIjA==} @@ -11708,7 +11317,7 @@ packages: resolution: {integrity: sha512-cOrL+qRSix45onwUNEO/ITrtuh2cvJT+vCFG2qahC/dFBC2z03LxLTwAZ33VPptoytBJN4Ht0AdnYCDBUm/M+Q==} engines: {node: '>=14.0.0'} dependencies: - debug: 4.3.4(supports-color@5.5.0) + debug: 4.3.4(supports-color@9.4.0) decompress-response: 7.0.0 follow-redirects: 1.15.6(debug@4.3.4) into-stream: 6.0.0 @@ -11880,16 +11489,10 @@ packages: git-up: 7.0.0 dev: true - /git-url-parse@13.1.1: - resolution: {integrity: sha512-PCFJyeSSdtnbfhSNRw9Wk96dDCNx+sogTe4YNXeXSJxt7xz5hvXekuRn9JX7m+Mf4OscCu8h+mtAl3+h5Fo8lQ==} - dependencies: - git-up: 7.0.0 - /git-url-parse@14.0.0: resolution: {integrity: sha512-NnLweV+2A4nCvn4U/m2AoYu0pPKlsmhK9cknG7IMwsjFY1S2jxM+mAhsDxyxfCIGfGaD+dozsyX4b6vkYc83yQ==} dependencies: git-up: 7.0.0 - dev: true /git-user-info@2.0.3: resolution: {integrity: sha512-G4ffrtck6AhUvJBmaWiq50viL9Zt3l1G/Qv0tV8BTKJZcJYnKWKGW8m7JvPrhzrPwh+Pwuq88pzERGlrLuOWng==} @@ -12168,7 +11771,7 @@ packages: resolution: {integrity: sha512-K+yhiPIBW7gkPYKCdqGB6xnC7qkxf4Kuweh/tDNlOgP2fzLEtSI/XWqLDDGfHRUutdYCFXuOUgbIwDbtyyLACg==} engines: {node: '>= 14'} dependencies: - debug: 4.3.4(supports-color@5.5.0) + debug: 4.3.4(supports-color@9.4.0) transitivePeerDependencies: - supports-color @@ -12301,22 +11904,16 @@ packages: /history@5.3.0: resolution: {integrity: sha512-ZqaKwjjrAYUYfLG+htGaIIZ4nioX2L70ZUMIFysS3xvBsSG4x/n1V6TXV3N8ZYNuFGlDirFg32T7B6WOUPDYcQ==} dependencies: - '@babel/runtime': 7.24.4 + '@babel/runtime': 7.24.1 /hls.js@1.3.5: resolution: {integrity: sha512-uybAvKS6uDe0MnWNEPnO0krWVr+8m2R0hJ/viql8H3MVK+itq8gGQuIYoFHL3rECkIpNH98Lw8YuuWMKZxp3Ew==} dev: false - /hls.js@1.4.14: - resolution: {integrity: sha512-UppQjyvPVclg+6t2KY/Rv03h0+bA5u6zwqVoz4LAC/L0fgYmIaCD7ZCrwe8WI1Gv01be1XL0QFsRbSdIHV/Wbw==} + /hls.js@1.5.7: + resolution: {integrity: sha512-Hnyf7ojTBtXHeOW1/t6wCBJSiK1WpoKF9yg7juxldDx8u3iswrkPt2wbOA/1NiwU4j27DSIVoIEJRAhcdMef/A==} dev: false - /hoist-non-react-statics@3.3.2: - resolution: {integrity: sha512-/gGivxi8JPKWNm/W0jSmzcMPpfpPLc3dY/6GxhX2hQ9iGj3aDfklV4ET7NjKpSinLpJ5vafa9iiGIEZg10SfBw==} - dependencies: - react-is: 16.13.1 - dev: true - /homedir-polyfill@1.0.3: resolution: {integrity: sha512-eSmmWE5bZTK2Nou4g0AI3zZ9rswp7GRKoKXS1BLUkvPviOqs4YTN1djQIqrXy9k5gEtdLPy86JjRwsNM9tnDcA==} engines: {node: '>=0.10.0'} @@ -12400,7 +11997,7 @@ packages: dependencies: '@tootallnate/once': 2.0.0 agent-base: 6.0.2 - debug: 4.3.4(supports-color@5.5.0) + debug: 4.3.4(supports-color@9.4.0) transitivePeerDependencies: - supports-color dev: true @@ -12410,7 +12007,7 @@ packages: engines: {node: '>= 14'} dependencies: agent-base: 7.1.1 - debug: 4.3.4(supports-color@5.5.0) + debug: 4.3.4(supports-color@9.4.0) transitivePeerDependencies: - supports-color @@ -12419,7 +12016,7 @@ packages: engines: {node: '>= 6'} dependencies: agent-base: 6.0.2 - debug: 4.3.4(supports-color@5.5.0) + debug: 4.3.4(supports-color@9.4.0) transitivePeerDependencies: - supports-color dev: true @@ -12429,7 +12026,7 @@ packages: engines: {node: '>= 14'} dependencies: agent-base: 7.1.1 - debug: 4.3.4(supports-color@5.5.0) + debug: 4.3.4(supports-color@9.4.0) transitivePeerDependencies: - supports-color @@ -12454,10 +12051,10 @@ packages: hasBin: true dev: true - /i18next@23.11.0: - resolution: {integrity: sha512-VwFtlgy2LDbY0Qs6VfekIm6mv5/JmSJrtBf4aszl7Vby8+GcBlri0/7dkMZXmzTfiBMPUPBOmYCdQK7K4emkGQ==} + /i18next@23.10.1: + resolution: {integrity: sha512-NDiIzFbcs3O9PXpfhkjyf7WdqFn5Vq6mhzhtkXzj51aOcNuPNcTwuYNuXCpHsanZGHlHKL35G7huoFeVic1hng==} dependencies: - '@babel/runtime': 7.24.4 + '@babel/runtime': 7.24.1 dev: false /iconv-lite@0.4.24: @@ -13135,11 +12732,6 @@ packages: engines: {node: '>=16'} dev: true - /iso-639-1@3.1.2: - resolution: {integrity: sha512-Le7BRl3Jt9URvaiEHJCDEdvPZCfhiQoXnFgLAWNRhzFMwRFdWO7/5tLRQbiPzE394I9xd7KdRCM7S6qdOhwG5A==} - engines: {node: '>=6.0'} - dev: false - /isobject@2.1.0: resolution: {integrity: sha512-+OUdGJlgjOBZDfxnDjYYG6zp487z0JGNQq3cYQYg5f5hKR+syHMsaztzGeml/4kGG55CSpKSpWTY+jYGgsHLgA==} engines: {node: '>=0.10.0'} @@ -13195,7 +12787,7 @@ packages: resolution: {integrity: sha512-n3s8EwkdFIJCG3BPKBYvskgXGoy88ARzvegkitk60NxRdwltLOTaH7CUiMRXvwYorl0Q712iEjcWB+fK/MrWVw==} engines: {node: '>=10'} dependencies: - debug: 4.3.4(supports-color@5.5.0) + debug: 4.3.4(supports-color@9.4.0) istanbul-lib-coverage: 3.2.2 source-map: 0.6.1 transitivePeerDependencies: @@ -14018,7 +13610,7 @@ packages: engines: {node: '>=18.0.0'} hasBin: true dependencies: - '@lerna/create': 8.1.2(typescript@5.4.4) + '@lerna/create': 8.1.2(typescript@5.4.2) '@npmcli/run-script': 7.0.2 '@nx/devkit': 18.2.2(nx@18.2.2) '@octokit/plugin-enterprise-rest': 6.0.1 @@ -14031,7 +13623,7 @@ packages: conventional-changelog-angular: 7.0.0 conventional-changelog-core: 5.0.1 conventional-recommended-bump: 7.0.1 - cosmiconfig: 8.3.6(typescript@5.4.4) + cosmiconfig: 8.3.6(typescript@5.4.2) dedent: 0.7.0 envinfo: 7.8.1 execa: 5.0.0 @@ -14083,7 +13675,7 @@ packages: strong-log-transformer: 2.1.0 tar: 6.1.11 temp-dir: 1.0.0 - typescript: 5.4.4 + typescript: 5.4.2 upath: 2.0.1 uuid: 9.0.1 validate-npm-package-license: 3.0.4 @@ -14382,8 +13974,8 @@ packages: three: 0.157.0 dev: false - /magic-string@0.30.9: - resolution: {integrity: sha512-S1+hd+dIrC8EZqKyT9DstTH/0Z+f76kmmvZnkfQVmOpDEF9iVgdYif3Q/pIWHmCoo59bQVGW0kVL3e2nl+9+Sw==} + /magic-string@0.30.8: + resolution: {integrity: sha512-ISQTe55T2ao7XtlAStud6qwYPZjE4GK1S/BeVPus4jrq6JuOnQ00YKQC581RWhR122W7msZV263KzVeLoqidyQ==} engines: {node: '>=12'} dependencies: '@jridgewell/sourcemap-codec': 1.4.15 @@ -14494,8 +14086,12 @@ packages: /mdn-data@2.0.30: resolution: {integrity: sha512-GaqWWShW4kv/G9IEucWScBx9G1/vsFZZJUO+tD26M8J8z3Kw5RDQjaoZe03YAClgeS/SWPOcb4nkFBTEi5DUEA==} - /media-chrome@3.1.1: - resolution: {integrity: sha512-EqofPNX7Eq1dv9ixuRo51Wv/Wo3P4PIPjY4iM1jGqu/Jyond8BqdigQKdhxPM2rH9SohdUXZvUWS1OJ1xMO6Ww==} + /media-chrome@1.7.0: + resolution: {integrity: sha512-2xut3GBOePwzgYGFc9+4ktWYApuL2JnMshgiw7Tgngp5tZKZugdSUGyImAgwrKM8NGE7NIcaFT584axh9dxoJw==} + dev: false + + /media-tracks@0.2.3: + resolution: {integrity: sha512-h5HRl1tIyeV+aF59FAmHmxChmdM/Ewf/twpxZkRme1ny46owD24uTA0BmRuPoO+uzvE0lx9ZIkZj1TbXi2VCng==} dev: false /media-tracks@0.3.0: @@ -14931,8 +14527,9 @@ packages: dev: true optional: true - /nano-pubsub@2.0.1: - resolution: {integrity: sha512-RWgGP2TdeKZLx+guR5a7/BzYs85sj6yrXXyj0o/znbgzPlz/Ez9wQuKDpwUZ8q+u2RxXpqZ1iTkPXCIU+GHhpA==} + /nano-pubsub@3.0.0: + resolution: {integrity: sha512-zoTNyBafxG0+F5PP3T3j1PKMr7gedriSdYRhLFLRFCz0OnQfQ6BkVk9peXVF30hz633Bw0Zh5McleOrXPjWYCQ==} + engines: {node: '>=18'} dev: false /nanoid@3.3.7: @@ -15023,7 +14620,7 @@ packages: resolution: {integrity: sha512-yAyTfdeNJGGBFxWdzSKCBYxs5FxLbCg5X5Q4ets974hcQzG1+qCxvIyOo4j2Ry6MUlhWVMX4OoYDefAIIwupjw==} engines: {node: '>= 10.13'} dependencies: - debug: 4.3.4(supports-color@5.5.0) + debug: 4.3.4(supports-color@9.4.0) json-stringify-safe: 5.0.1 propagate: 2.0.1 transitivePeerDependencies: @@ -16045,7 +15642,7 @@ packages: resolution: {integrity: sha512-OBatVyC/N7SCW/FaDHrSd+vn0o5cS855TOmYi4OkdWUMSJCET/xip//ch8xGUvtr3i44X9LVyWwQlRMTN3pwSA==} engines: {node: '>=10'} dependencies: - '@babel/runtime': 7.24.4 + '@babel/runtime': 7.24.1 dev: false /posix-character-classes@0.1.1: @@ -16372,7 +15969,7 @@ packages: peerDependencies: react: ^15.3.0 || ^16.0.0 || ^17.0.0 || ^18.0.0 dependencies: - '@babel/runtime': 7.24.4 + '@babel/runtime': 7.24.1 react: 18.2.0 dev: false @@ -16439,7 +16036,7 @@ packages: '@types/react': optional: true dependencies: - '@babel/runtime': 7.24.4 + '@babel/runtime': 7.24.1 '@types/react': 18.2.74 focus-lock: 1.3.4 prop-types: 15.8.1 @@ -16449,7 +16046,7 @@ packages: use-sidecar: 1.1.2(@types/react@18.2.74)(react@18.2.0) dev: false - /react-i18next@13.5.0(i18next@23.11.0)(react-dom@18.2.0)(react@18.2.0): + /react-i18next@13.5.0(i18next@23.10.1)(react-dom@18.2.0)(react@18.2.0): resolution: {integrity: sha512-CFJ5NDGJ2MUyBohEHxljOq/39NQ972rh1ajnadG9BjTk+UXbHLq4z5DKEbEQBDoIhUmmbuS/fIMJKo6VOax1HA==} peerDependencies: i18next: '>= 23.2.3' @@ -16462,9 +16059,9 @@ packages: react-native: optional: true dependencies: - '@babel/runtime': 7.24.4 + '@babel/runtime': 7.24.1 html-parse-stringify: 3.0.1 - i18next: 23.11.0 + i18next: 23.10.1 react: 18.2.0 react-dom: 18.2.0(react@18.2.0) dev: false @@ -16753,7 +16350,7 @@ packages: /regenerator-transform@0.15.2: resolution: {integrity: sha512-hfMp2BoF0qOk3uc5V20ALGDS2ddjQaLrdl7xrGXvAIow7qeWRM2VA2HuCHkUKk9slq3VwEwLNK3DFBqDfPGYtg==} dependencies: - '@babel/runtime': 7.24.4 + '@babel/runtime': 7.24.1 /regex-cache@0.4.4: resolution: {integrity: sha512-nVIZwtCjkC9YgvWkpM55B5rBhBYRZhAaJbgcFYXXsHnbZ9UZI9nnVWYZpBlCqv9ho2eZryPnWrZGsOdPwVWXWQ==} @@ -16971,22 +16568,6 @@ packages: dependencies: glob: 9.3.5 - /rollup-plugin-esbuild@6.1.1(esbuild@0.19.12)(rollup@3.29.4): - resolution: {integrity: sha512-CehMY9FAqJD5OUaE/Mi1r5z0kNeYxItmRO2zG4Qnv2qWKF09J2lTy5GUzjJR354ZPrLkCj4fiBN41lo8PzBUhw==} - engines: {node: '>=14.18.0'} - peerDependencies: - esbuild: '>=0.18.0' - rollup: ^1.20.0 || ^2.0.0 || ^3.0.0 || ^4.0.0 - dependencies: - '@rollup/pluginutils': 5.1.0(rollup@3.29.4) - debug: 4.3.4(supports-color@5.5.0) - es-module-lexer: 1.5.0 - esbuild: 0.19.12 - get-tsconfig: 4.7.3 - rollup: 3.29.4 - transitivePeerDependencies: - - supports-color - /rollup-plugin-esbuild@6.1.1(esbuild@0.20.2)(rollup@4.14.1): resolution: {integrity: sha512-CehMY9FAqJD5OUaE/Mi1r5z0kNeYxItmRO2zG4Qnv2qWKF09J2lTy5GUzjJR354ZPrLkCj4fiBN41lo8PzBUhw==} engines: {node: '>=14.18.0'} @@ -16995,22 +16576,13 @@ packages: rollup: ^1.20.0 || ^2.0.0 || ^3.0.0 || ^4.0.0 dependencies: '@rollup/pluginutils': 5.1.0(rollup@4.14.1) - debug: 4.3.4(supports-color@5.5.0) + debug: 4.3.4(supports-color@9.4.0) es-module-lexer: 1.5.0 esbuild: 0.20.2 get-tsconfig: 4.7.3 rollup: 4.14.1 transitivePeerDependencies: - supports-color - dev: true - - /rollup-plugin-preserve-directives@0.2.0(rollup@3.29.4): - resolution: {integrity: sha512-KUwbBaFvD1zFIDNnOkR+u64sSod3m0l6q46/SzTOa4GTQ6hp6w0FRr2u7x99YkY9qhlna5panmTmuLWeJ/2KWw==} - peerDependencies: - rollup: 2.x || 3.x - dependencies: - magic-string: 0.30.9 - rollup: 3.29.4 /rollup@3.29.4: resolution: {integrity: sha512-oWzmBZwvYrU0iJHtDmhsm662rC15FRXmcjCk1xD771dFDx5jJ02ufAQQTn0etB2emNk4J9EZg/yWKpsn9BWGRw==} @@ -17042,7 +16614,6 @@ packages: '@rollup/rollup-win32-ia32-msvc': 4.14.1 '@rollup/rollup-win32-x64-msvc': 4.14.1 fsevents: 2.3.3 - dev: true /rrweb-cssom@0.6.0: resolution: {integrity: sha512-APM0Gt1KoXBz0iIkkdB/kfvGOwC4UuJFeG/c+yV7wSc7q96cG/kJ0HiYCnzivD9SB53cLV1MlHFNfOuPaadYSw==} @@ -17132,22 +16703,21 @@ packages: '@sanity/diff-match-patch': 3.1.1 dev: false - /sanity-plugin-mux-input@2.3.1(@types/react@18.2.74)(react-dom@18.2.0)(react-is@18.2.0)(react@18.2.0)(sanity@packages+sanity)(styled-components@6.1.8): - resolution: {integrity: sha512-IynQ758OyMcpdG7bOGvfjl4MD1xRCca+6cQhm2IBw8/MPftXszrkmBLXjeuS36ihKO1fH9yzXE/L/tjjL8ucIA==} + /sanity-plugin-mux-input@2.2.4(@types/react@18.2.74)(react-dom@18.2.0)(react-is@18.2.0)(react@18.2.0)(sanity@packages+sanity)(styled-components@6.1.8): + resolution: {integrity: sha512-QZiQLQ+i2FVLARQc2qSP2MceWRq0GJ5WN9cqMx3wF+9emG8+WD7Fm+AyQJrCLi5y+By0luDgeLbPHAL3vd7oNQ==} engines: {node: '>=14'} peerDependencies: react: ^18 react-is: ^18 sanity: ^3 - styled-components: ^6 + styled-components: ^5.2 dependencies: - '@mux/mux-player-react': 2.4.1(@types/react@18.2.74)(react-dom@18.2.0)(react@18.2.0) + '@mux/mux-player-react': 1.15.0(@types/react@18.2.74)(react-dom@18.2.0)(react@18.2.0) '@mux/upchunk': 3.3.2 '@sanity/icons': 2.11.7(react@18.2.0) '@sanity/incompatible-plugin': 1.0.4(react-dom@18.2.0)(react@18.2.0) - '@sanity/ui': 2.1.0(react-dom@18.2.0)(react-is@18.2.0)(react@18.2.0)(styled-components@6.1.8) + '@sanity/ui': 1.9.3(react-dom@18.2.0)(react-is@18.2.0)(react@18.2.0)(styled-components@6.1.8) '@sanity/uuid': 3.0.2 - iso-639-1: 3.1.2 jsonwebtoken-esm: 1.0.5 lodash: 4.17.21 react: 18.2.0 @@ -17217,13 +16787,6 @@ packages: resolution: {integrity: sha512-BR7VvDCVHO+q2xBEWskxS6DJE1qRnb7DxzUrogb71CWoSficBxYsiAGd+Kl0mmq/MprG9yArRkyrQxTO6XjMzA==} hasBin: true - /semver@7.3.8: - resolution: {integrity: sha512-NB1ctGL5rlHrPJtFDVIVzTyQylMLu9N9VICA6HSFJo8MCGVTMW6gfpicwKmmK/dAjTOrqu5l63JJOpDSrAis3A==} - engines: {node: '>=10'} - hasBin: true - dependencies: - lru-cache: 6.0.0 - /semver@7.5.4: resolution: {integrity: sha512-1bCSESV6Pv+i21Hvpxp3Dx+pSD8lIPt8uVjRrxAUt/nbswYc+tK6Y2btiULjd4+fnq15PX+nqQDC7Oft7WkwcA==} engines: {node: '>=10'} @@ -17521,7 +17084,7 @@ packages: engines: {node: '>= 10'} dependencies: agent-base: 6.0.2 - debug: 4.3.4(supports-color@5.5.0) + debug: 4.3.4(supports-color@9.4.0) socks: 2.8.1 transitivePeerDependencies: - supports-color @@ -17532,7 +17095,7 @@ packages: engines: {node: '>= 14'} dependencies: agent-base: 7.1.1 - debug: 4.3.4(supports-color@5.5.0) + debug: 4.3.4(supports-color@9.4.0) socks: 2.8.1 transitivePeerDependencies: - supports-color @@ -17945,31 +17508,6 @@ packages: resolution: {integrity: sha512-wnD1HyVqpJUI2+eKZ+eo1UwghftP6yuFheBqqe+bWCotBjC2K1YnteJILRMs3SM4V/0dLEW1SC27MWP5y+mwmw==} dev: false - /styled-components@5.3.11(@babel/core@7.24.4)(react-dom@18.2.0)(react-is@18.2.0)(react@18.2.0): - resolution: {integrity: sha512-uuzIIfnVkagcVHv9nE0VPlHPSCmXIUGKfJ42LNjxCCTDTL5sgnJ8Z7GZBq0EnLYGln77tPpEpExt2+qa+cZqSw==} - engines: {node: '>=10'} - peerDependencies: - react: '>= 16.8.0' - react-dom: '>= 16.8.0' - react-is: '>= 16.8.0' - dependencies: - '@babel/helper-module-imports': 7.24.3 - '@babel/traverse': 7.24.1(supports-color@5.5.0) - '@emotion/is-prop-valid': 1.2.2 - '@emotion/stylis': 0.8.5 - '@emotion/unitless': 0.7.5 - babel-plugin-styled-components: 2.1.4(@babel/core@7.24.4)(styled-components@5.3.11) - css-to-react-native: 3.2.0 - hoist-non-react-statics: 3.3.2 - react: 18.2.0 - react-dom: 18.2.0(react@18.2.0) - react-is: 18.2.0 - shallowequal: 1.1.0 - supports-color: 5.5.0 - transitivePeerDependencies: - - '@babel/core' - dev: true - /styled-components@6.1.8(react-dom@18.2.0)(react@18.2.0): resolution: {integrity: sha512-PQ6Dn+QxlWyEGCKDS71NGsXoVLKfE1c3vApkvDYS5KAK+V8fNWGhbSUEo9Gg2iaID2tjLXegEW3bZDUGpofRWw==} engines: {node: '>= 16'} @@ -18037,7 +17575,6 @@ packages: /supports-color@9.4.0: resolution: {integrity: sha512-VL+lNrEoIXww1coLPOmiEmK/0sGigko5COxI09KzHc2VJXJsQ37UaQ+8quuxjDeA7+KnLGTWRyOXSLLR2Wb4jw==} engines: {node: '>=12'} - dev: true /supports-preserve-symlinks-flag@1.0.0: resolution: {integrity: sha512-ot0WnXS9fgdkgIcePe6RHNk1WA8+muPa6cSjeR3V8K27q9BB1rTE3R1p7Hv0z1ZyAc8s6Vvv8DIyWf681MAt0w==} @@ -18389,22 +17926,13 @@ packages: resolution: {integrity: sha512-1xZHoJrG0HFfCvT/iyN41DvI/nRykiBtHqFkGaGgJwq5iXfIZFBiPPEHFpPpgyKM3Oo5ITHXP5wM2TNQszYdVg==} dev: false - /ts-api-utils@1.3.0(typescript@5.3.3): - resolution: {integrity: sha512-UQMIo7pb8WRomKR1/+MFVLTroIvDVtMX3K6OUir8ynLyzB8Jeriont2bTAtmNPa1ekAgN7YPDyf6V+ygrdU+eQ==} - engines: {node: '>=16'} - peerDependencies: - typescript: '>=4.2.0' - dependencies: - typescript: 5.3.3 - dev: true - - /ts-api-utils@1.3.0(typescript@5.4.4): + /ts-api-utils@1.3.0(typescript@5.4.2): resolution: {integrity: sha512-UQMIo7pb8WRomKR1/+MFVLTroIvDVtMX3K6OUir8ynLyzB8Jeriont2bTAtmNPa1ekAgN7YPDyf6V+ygrdU+eQ==} engines: {node: '>=16'} peerDependencies: typescript: '>=4.2.0' dependencies: - typescript: 5.4.4 + typescript: 5.4.2 dev: true /tsconfig-paths@3.15.0: @@ -18439,7 +17967,7 @@ packages: engines: {node: ^14.17.0 || ^16.13.0 || >=18.0.0} dependencies: '@tufjs/models': 1.0.4 - debug: 4.3.4(supports-color@5.5.0) + debug: 4.3.4(supports-color@9.4.0) make-fetch-happen: 11.1.1 transitivePeerDependencies: - supports-color @@ -18450,7 +17978,7 @@ packages: engines: {node: ^16.14.0 || >=18.0.0} dependencies: '@tufjs/models': 2.0.0 - debug: 4.3.4(supports-color@5.5.0) + debug: 4.3.4(supports-color@9.4.0) make-fetch-happen: 13.0.0 transitivePeerDependencies: - supports-color @@ -18640,27 +18168,11 @@ packages: uuidv7: 0.4.4 dev: false - /typescript@5.0.4: - resolution: {integrity: sha512-cW9T5W9xY37cc+jfEnaUvX91foxtHkza3Nw3wkoF4sSlKn0MONdkdEndig/qPBWXNkmplh3NzayQzCiHM4/hqw==} - engines: {node: '>=12.20'} - hasBin: true - - /typescript@5.3.3: - resolution: {integrity: sha512-pXWcraxM0uxAS+tN0AG/BF2TyqmHO014Z070UsJ+pFvYuRSq8KH8DmWpnbXe0pEPDHXZV3FcAbJkijJ5oNEnWw==} - engines: {node: '>=14.17'} - hasBin: true - dev: true - /typescript@5.4.2: resolution: {integrity: sha512-+2/g0Fds1ERlP6JsakQQDXjZdZMM+rqpamFZJEKh4kwTIn3iDkgKtby0CeNd5ATNZ4Ry1ax15TMx0W2V+miizQ==} engines: {node: '>=14.17'} hasBin: true - /typescript@5.4.4: - resolution: {integrity: sha512-dGE2Vv8cpVvw28v8HCPqyb08EzbBURxDpuhJvTrusShUfGnhHBafDsLdS1EhhxyL6BJQE+2cT3dDPAv+MQ6oLw==} - engines: {node: '>=14.17'} - hasBin: true - /uglify-js@3.17.4: resolution: {integrity: sha512-T9q82TJI9e/C1TAxYvfb16xO120tMVFZrGA3f9/P4424DNu6ypK103y0GPFVa17yotwSyZW5iYXgjYHkGrJW/g==} engines: {node: '>=0.8.0'} @@ -19003,6 +18515,41 @@ packages: optionalDependencies: fsevents: 2.3.3 + /vite@5.2.8(@types/node@18.19.29): + resolution: {integrity: sha512-OyZR+c1CE8yeHw5V5t59aXsUPPVTHMDjEZz8MgguLL/Q7NblxhZUlTu9xSPqlsUO/y+X7dlU05jdhvyycD55DA==} + engines: {node: ^18.0.0 || >=20.0.0} + hasBin: true + peerDependencies: + '@types/node': ^18.0.0 || >=20.0.0 + less: '*' + lightningcss: ^1.21.0 + sass: '*' + stylus: '*' + sugarss: '*' + terser: ^5.4.0 + peerDependenciesMeta: + '@types/node': + optional: true + less: + optional: true + lightningcss: + optional: true + sass: + optional: true + stylus: + optional: true + sugarss: + optional: true + terser: + optional: true + dependencies: + '@types/node': 18.19.29 + esbuild: 0.20.2 + postcss: 8.4.38 + rollup: 4.14.1 + optionalDependencies: + fsevents: 2.3.3 + /void-elements@3.1.0: resolution: {integrity: sha512-Dhxzh5HZuiHQhbvTW9AMetFfBHDMYpo23Uo9btPXgdYP+3T5S+p+jgNy7spra+veYhBP2dCSgxR/i2Y02h5/6w==} engines: {node: '>=0.10.0'} diff --git a/pnpm-workspace.yaml b/pnpm-workspace.yaml index 365e34e3d48..d53e2efd710 100644 --- a/pnpm-workspace.yaml +++ b/pnpm-workspace.yaml @@ -3,6 +3,7 @@ packages: - 'perf' - 'perf/studio' - 'examples/*' + - 'packages/@repo/*' - 'packages/@sanity/*' - 'packages/create-sanity' - 'packages/groq' diff --git a/scripts/etl.ts b/scripts/etl.ts index 7e7d9a2372d..c184540c40f 100644 --- a/scripts/etl.ts +++ b/scripts/etl.ts @@ -1,3 +1,4 @@ +import baseConfig from '@repo/package.config' import {createClient} from '@sanity/client' import {_loadConfig, extract, load, type SanityTSDocConfigOptions, transform} from '@sanity/tsdoc' import cac from 'cac' @@ -75,8 +76,14 @@ async function etl(options: { let timer = startTimer(`Extracting API documents from \`${packageName}\``) const {pkg, results} = await extract({ + customTags: tsdocConfig?.extract?.customTags, packagePath, - bundledPackages: tsdocConfig.input?.bundledPackages, + rules: tsdocConfig?.extract?.rules, + // @TODO change to `strict: true` once `sanity` can run `pkg-utils build --strict` + strict: false, + tsconfig: tsdocConfig?.input?.tsconfig ?? (baseConfig.tsconfig || 'tsconfig.json'), + bundledPackages: tsdocConfig?.input?.bundledPackages, + legacyExports: tsdocConfig?.legacyExports ?? baseConfig.legacyExports ?? true, }) timer.end() diff --git a/scripts/normalizePackageFields.ts b/scripts/normalizePackageFields.ts index c1cfee71e4b..5e6c7146acd 100644 --- a/scripts/normalizePackageFields.ts +++ b/scripts/normalizePackageFields.ts @@ -1,4 +1,4 @@ -import uniq from 'lodash/uniq' +import {uniq} from 'lodash' import {type PackageManifest} from './types' import transformPkgs from './utils/transformPkgs' diff --git a/scripts/tsconfig.json b/scripts/tsconfig.json index a715f29da47..5458a1ba5aa 100644 --- a/scripts/tsconfig.json +++ b/scripts/tsconfig.json @@ -1,7 +1,7 @@ { "include": ["./**/*.ts", "./**/*.tsx", "./**/*.js", "./**/*.jsx", "./**/*.json"], - "extends": "../tsconfig.settings.json", + "extends": "@repo/tsconfig/base.json", "compilerOptions": { - "resolveJsonModule": true + "rootDir": "." } } diff --git a/tsconfig.json b/tsconfig.json index dbdd3859010..1ede10e0de9 100644 --- a/tsconfig.json +++ b/tsconfig.json @@ -1,22 +1,9 @@ { - "extends": "./tsconfig.settings", - "include": ["**/*/package.config.ts", "./dev/aliases.cjs", "./scripts", "./test"], + // Until what's in dev/, scripts. and test/ is in workspaces it's necessary to type check them from the root + "extends": "@repo/tsconfig/base.json", + "include": ["./dev/aliases.cjs", "./scripts", "./test"], + "files": [], "compilerOptions": { - "emitDeclarationOnly": true, - "outDir": "./node_modules/.sanity-monorepo/dts", - "allowJs": true - }, - "references": [ - {"path": "./packages/@sanity/block-tools"}, - {"path": "./packages/@sanity/cli"}, - {"path": "./packages/@sanity/diff"}, - {"path": "./packages/@sanity/mutator"}, - {"path": "./packages/@sanity/portable-text-editor"}, - {"path": "./packages/@sanity/schema"}, - {"path": "./packages/@sanity/codegen"}, - {"path": "./packages/@sanity/types"}, - {"path": "./packages/@sanity/util"}, - {"path": "./packages/@sanity/vision"}, - {"path": "./packages/sanity"} - ] + "rootDir": "." + } } diff --git a/tsconfig.lib.json b/tsconfig.lib.json deleted file mode 100644 index 7569a76de08..00000000000 --- a/tsconfig.lib.json +++ /dev/null @@ -1,20 +0,0 @@ -{ - "extends": "./tsconfig.settings", - "include": [], - "compilerOptions": { - "emitDeclarationOnly": true, - "outDir": "./node_modules/.sanity-monorepo/dts" - }, - "references": [ - {"path": "./packages/@sanity/block-tools/tsconfig.lib.json"}, - {"path": "./packages/@sanity/cli/tsconfig.lib.json"}, - {"path": "./packages/@sanity/diff/tsconfig.lib.json"}, - {"path": "./packages/@sanity/mutator/tsconfig.lib.json"}, - {"path": "./packages/@sanity/portable-text-editor/tsconfig.lib.json"}, - {"path": "./packages/@sanity/schema/tsconfig.lib.json"}, - {"path": "./packages/@sanity/types/tsconfig.lib.json"}, - {"path": "./packages/@sanity/util/tsconfig.lib.json"}, - {"path": "./packages/@sanity/vision/tsconfig.lib.json"}, - {"path": "./packages/sanity/tsconfig.lib.json"} - ] -} diff --git a/tsconfig.settings.json b/tsconfig.settings.json deleted file mode 100644 index 370bdc3cd87..00000000000 --- a/tsconfig.settings.json +++ /dev/null @@ -1,39 +0,0 @@ -{ - "compilerOptions": { - "lib": ["dom", "es2020"], - - // Output settings - "module": "ES2020", - "target": "ES2017", - "declaration": true, - "declarationMap": true, - "sourceMap": true, - - // Settings - "preserveConstEnums": true, - "useUnknownInCatchVariables": false, - "isolatedModules": true, - "forceConsistentCasingInFileNames": true, - - // Strict type-checking - "strict": true, - // "noImplicitAny": true, - // "strictNullChecks": true, - // "strictFunctionTypes": true, - // "strictPropertyInitialization": true, - // "noImplicitThis": true, - // "alwaysStrict": true, - - // Additional checks - // "noUnusedLocals": true, - // "noUnusedParameters": true, - // "noImplicitReturns": true, - // "noFallthroughCasesInSwitch": true, - "skipLibCheck": true, - - // Module settings - "moduleResolution": "node", - "allowSyntheticDefaultImports": true, - "esModuleInterop": true - } -} diff --git a/turbo.json b/turbo.json index 484e438f2f8..f3ab76ad87e 100644 --- a/turbo.json +++ b/turbo.json @@ -4,20 +4,27 @@ "globalEnv": ["OS", "RUNNER_OS", "PKG_FILE_PATH", "PKG_FORMAT", "PKG_RUNTIME", "PKG_VERSION"], // These root workspace files are reused in workspaces and may affect their build output "globalDependencies": [ - ".babelrc", - "babel.config.cjs", - "lerna.json", // some tools, like babel, reads from this file to identify other roots - "package.config.ts", - "tsconfig.json", - "tsconfig.lib.json", - "tsconfig.settings.json" + ".eslintrc.cjs", + ".prettierrc", + "lerna.json" // some tools, like babel, reads from this file to identify other roots ], "pipeline": { "build": { - "outputs": ["lib/**", "index.js"], - "dependsOn": ["^build"] + "outputs": ["lib/**", "*.js"], + "dependsOn": ["^build"], + "outputMode": "new-only" + }, + "check:package": { + "dependsOn": ["build"], + "outputMode": "errors-only" + }, + "check:types": { + "outputs": [], + "outputMode": "errors-only" + }, + "lint": { + "outputMode": "errors-only" }, - "lint": {}, "//#check:format": {} } }