github sanity-io/sanity v3.50.0

latest releases: v3.64.0, v2.36.6, v2.36.5...
4 months ago

✨ Highlights

New: Copy-and-paste fields and documents

This version of Sanity Studio introduces a powerful new way to work with structured content within Sanity Studio: Copy-paste support for fields and documents. You can now use the familiar copy-and-paste hotkeys (cmd/ctrl+c and cmd/ctrl+v) and the field and document actions menus to copy content across different fields and document types seamlessly.

  • Copy between different document types: You can seamlessly copy fields from one document and paste them into a different document type while maintaining the content structure.
  • Copy deeply bested structures: Easily copy entire blocks of Portable Text and arrays with complex nested structures between documents.
  • Copy full documents: Effortlessly copy full documents and integrate them into existing documents of the same or similar types.
CleanShot.2024-07-10.at.14.27.46.mp4

Beta: Array Tree Editing

Sanity offers powerful content models that let you define lists of object types and even nest these, if necessary. This enables developers to work with intuitive and convenient data structures in the API, but it has sometimes led to a cumbersome editorial experience with a lot of navigation between layers of modals.

That's why we're thrilled to introduce an improved experience for editing arrays of objects. With the array tree editing, you can browse and edit array items in one place, making working with nested content much simpler and faster.

Screenshot of new Array Tree Editor

To enable the new array tree editor, add the following to your Sanity Studio configuration:

// sanity.config.ts
export default defineConfig({
  // ...
  beta: {
    treeArrayEditing: {
      enabled: true,
    },
  },
});

Note: While in beta, the array tree editor has limited support for references. References to other documents do not appear in the array tree editor and will open in a new modal. Additionally, Portable Text fields are not fully supported.

Beta: Auto-updating Sanity Studio deployments

We're shipping improvents and fixes to Sanity Studio on a weekly basis. To make it easier to get these improvements to Sanity Studio users without requiring developer involvement, we have shipped a way to build the studio for auto-updates.

You can try this out with the new --auto-updates flag to the sanity build and sanity deploy CLI commands. This enables your Sanity Studio to automatically update to the latest minor and patch versions (3.x.x) of Sanity Studio without having to rebuild and redeploy new bundles.

Learn more about the new auto-update flag in docs.

image

Improved support for large datasets exports

To improve the export experience for users with large datasets, we have introduced a new cursor export mode in the Sanity CLI:

sanity dataset export --mode cursor

In this mode, the CLI will use cursors under the hood when exporting, which can significantly speed up the export process for larger datasets.

Note: Unlike the traditional export mode, the cursor mode does not create a snapshot of the dataset. Instead, it pulls data as it exports, which may result in inconsistencies if documents in the dataset is modified during the export process.

🐛 Notable bugfixes

  • Fixes an issue when trying to extract schemas/deploy GraphQL APIs when a sub-dependency tries to call document.execCommand at import time.
  • Fixes a warning being printed about using useClient() without specifying an API version.
  • Fixes an issue where having styled-components listed in devDependencies instead of dependencies would cause the CLI to try to install it as a dependency in a loop.

Install or upgrade Sanity Studio

To initiate a new Sanity Studio project or upgrade an existing one, please refer to our comprehensive guide on Installing and Upgrading Sanity Studio.

If you are updating from a version earlier than 3.37.0, you should also check out this article to ensure your dependencies are up to date.

📓 Full changelog

Author Message Commit
Binoy Patel fix(core): fixes url for checking studio version (#7060) a44fd5b
Sindre Gulseth refactor(typegen): use typenode to lookup referencing type names (#7038) e622011
renovate[bot] chore(deps): update dependency @sanity/tsdoc to v1.0.75 (#7005) 48a7266
Herman Wikner feat(core): focus root array item when closing tree editing dialog (#7049) 8e80b14
renovate[bot] chore(deps): update dependency turbo to ^2.0.6 (#7067) d04d061
renovate[bot] chore(deps): update dependency ts-node to ^10.9.2 (#7066) 630f558
renovate[bot] chore(deps): update dependency lerna to ^8.1.5 (#7065) 0d2f0d9
Sindre Gulseth feat(cli): Add support for exporting dataset with cursor (#7068) d019845
Jordan Lawrence chore(config): comment to clarify logo deprecation (#7075) 6d1f496
Jordan Lawrence docs(migrate): updating insert examples to showing always 3 args (#7070) 60ad7e7
Espen Hovlandsdal fix(cli): mock document.execCommand when emulating browser env (#7062) e54ae8a
Herman Wikner fix(core): handle array fields within nested objects in array items (#7069) 3c057a8
renovate[bot] fix(deps): update dependency @sanity/presentation to v1.16.2 (#7078) 7aa5732
renovate[bot] chore(deps): update dependency @sanity/insert-menu to v1.0.7 (#7064) c3079c1
renovate[bot] chore(deps): update dependency lerna to ^8.1.6 (#7083) 5d94ce7
renovate[bot] fix(deps): update dependency @sanity/client to ^6.20.1 (#7088) baa20cb
renovate[bot] fix(deps): Update dev-non-major (#7086) 554d579
Ash feat(sanity): allow Actions API enablement based on Studio version semver constraint 47a160b
Ash test(e2e): add helper to mock Actions API feature toggle response f31671b
Ash test(e2e): re-enable tests for Actions API feature toggle and expand test cases daca8e9
Cody Olsen chore(renovate): add preset that allows internal PRs to open right away (#7087) 43616e4
ecospark[bot] chore(deps): dedupe pnpm-lock.yaml (#7096) e4a237b
Cody Olsen chore(renovate): add fixtures to ignorePaths (#7081) e948e68
renovate[bot] fix(deps): update dependency @portabletext/editor to ^1.0.8 (#7101) 07771ed
renovate[bot] fix(deps): update dependency @sanity/icons to ^3.3.0 (#7098) 451e841
renovate[bot] fix(deps): Update dev-non-major (#7100) b9d98bf
renovate[bot] fix(deps): update dependency get-it to ^8.6.3 (#7108) 32024fe
renovate[bot] fix(deps): update dependency @sanity/client to ^6.20.2 (#7111) 8ec952e
RitaDias refactor(sanity): remove "features" (#7097) a5e6212
renovate[bot] fix(deps): update dependency @sanity/client to ^6.20.2 (#7110) 2e1c86a
renovate[bot] fix(deps): update dependency @sanity/bifur-client to ^0.4.1 (#7102) 048b4fb
renovate[bot] fix(deps): update dependency @sanity/ui to ^2.6.3 (#7104) 8cba533
renovate[bot] fix(deps): update dependency react-rx to ^3.1.1 (#7113) 0d4c8e6
renovate[bot] chore(deps): update dependency @sanity/tsdoc to v1.0.83 (#7080) 5b8de2d
renovate[bot] chore(deps): update dependency esbuild to ^0.23.0 (#7106) 24c8c96
Espen Hovlandsdal test(cli): use separate tarball location for cursor export test (#7118) 7025ffa
Espen Hovlandsdal fix(core): minor typo fix in i18n comment (#7115) 04c374a
Pedro Bonamin feat(router): update router to support query params in intent links (#7095) 793b2b0
renovate[bot] chore(lockfile): Update dev-non-major to v1.1.5 (#7122) 6e4ad38
Espen Hovlandsdal chore(deps): roll back esbuild dependency to 0.21.5 (#7126) b02fe6f
renovate[bot] fix(deps): update dependency react-rx to ^3.1.2 (#7123) 3030181
Cody Olsen chore(renovate): only bump esbuild within 0.21.x (#7128) 0c2103c
Espen Hovlandsdal fix(core): error reporting consent tweaks (#7131) 1552e20
Rune Botten chore(core): update copy for new version available toast (#7129) d298503
Espen Hovlandsdal fix(cli): allow styled-component as dev dependency (#7132) ff31556
Espen Hovlandsdal fix(i18n): allow locale plugins to translate "All fields" field group (#7117) 24f9936
renovate[bot] fix(deps): update dependency react-rx to ^3.1.3 (#7138) 137bf75
renovate[bot] fix(deps): update dependency @sanity/client to ^6.21.0 (#7137) a23b2a5
renovate[bot] fix(deps): Update dev-non-major (#7139) 5606d85
renovate[bot] fix(deps): update dependency @sanity/ui to ^2.6.6 (#7136) 2548de6
renovate[bot] fix(deps): Update dev-non-major (#7140) b95094c
Rune Botten chore: Update PULL_REQUEST_TEMPLATE.md (#7133) 27c13a5
Fred Carlsen feat(core): global copy paste (#6856) 53aa46b
Rico Kahler fix(deps): bump @sanity/ui ^2.6.7 (#7143) b58b0f8

Don't miss a new sanity release

NewReleases is sending notifications on new releases.