Releases: sanity-io/sanity
v3.54.0
✨ Highlights
Copy Paste Improvements
- Adds support for copying supported object types into array fields
- Adds support for copying and pasting individual array items
Multiple deployment targets for Sanity Studio
Introduces support for adding multiple [my-company].sanity.studio
deployments for a project. Link your studio code to a specific hostname with the new studioHost
property in the CLI config as shown below, or select or create a deployment target when prompted while running sanity deploy
. You can now see all your studio deployments in the project management settings.
// ./sanity.cli.ts
import {defineCliConfig} from 'sanity/cli'
export default defineCliConfig({
api: {
projectId: 'projectid',
dataset: 'production'
},
// Tip: You can use an environment variable for studioHost if you want
// to deploy separate studios for production, staging, testing etc.
studioHost: 'my-company'
})
Read more in the Hosting and deployment article in the docs.
🐛 Notable bugfixes
- Fixes an issue where you were able to copy and paste documents that contained non-existing references
- Fixes an issue where
getValueAtPath()
utility wouldn't work for 0 index path segments(['array', 0])
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 |
---|---|---|
Sindre Gulseth | chore(typegen): move prettier formatting into generateAction (#7333) | 3c34f08 |
Cody Olsen | fix(deps): @bjoerge/mutiny is now @sanity/mutate (#7344) |
4aeb5b6 |
Bjørge Næss | chore(dev): add groq package to monorepo aliases (#7340) | d44b06e |
renovate[bot] | chore(deps): update pnpm to v9.7.0 (#7346) | 0772245 |
renovate[bot] | fix(deps): update dependency @portabletext/editor to ^1.0.12 (#7352) | ecde097 |
renovate[bot] | fix(deps): update dependency @sanity/insert-menu to v1.0.8 (#7343) | 088139d |
renovate[bot] | fix(deps): update dependency get-it to ^8.6.4 (#7353) | f6b6378 |
renovate[bot] | fix(deps): Update dev-non-major (#7345) | eefb5ea |
Christian Grøngaard | chore(test-studio): fix custom markers PTE example (#7358) | 43b9969 |
RitaDias | test(dev): add media plugin to studio e2e & test (#7236) | 12d1411 |
renovate[bot] | fix(deps): update dependency @sanity/presentation to v1.16.4 (#7359) | 441d7e5 |
Ash | feat(test-studio): add noop custom publish action example | 7860c8e |
Ash | fix(sanity): prevent empty actions being executed | c2e4eb3 |
Fred Carlsen | feat(core): support pasting object into array + copying individual array items (#7292) | ea55826 |
Rune Botten | fix(deps): update and pin react-i18next to 14.0.2 (#7364) | 3cecfdd |
renovate[bot] | fix(deps): update dependency @sanity/client to ^6.21.2 (#7354) | db6741b |
Sindre Gulseth | fix(typegen): dont treat all document type refs as references (#7366) | 32958d3 |
Pedro Bonamin | fix(core): update eslintrc config to show no-restricted-imports rules (#7367) | 22e717e |
renovate[bot] | fix(deps): update dependency @portabletext/editor to ^1.0.13 (#7370) | a361063 |
Rico Kahler | feat(cli): update CLI to use new deploy endpoint (#7244) | 14ae5cb |
v3.53.0
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.
Improved Sanity Client and TypeGen integration
With the new defineQuery
utility it is no longer necessary to pass generics into client.fetch
calls for the sanity typegen
command to generate type definitions for query results. 🥳
Update @sanity/client
to v6.21.0
or later, then add "overloadClientMethods": true
to your sanity-typegen.json
configuration file, and finally wrap your query strings in the new defineQuery
utility method from groq
:
import {createClient} from '@sanity/client'
-import groq from 'groq'
+import {defineQuery} from 'groq'
-import type { SettingsQueryResult } from "~/sanity.types";
const client = createClient({ /* ... */ })
-const settingsQuery = groq`
+const settingsQuery = defineQuery(`
*[_type == "settings"][0]
-`
+`)
-const settings = await client.fetch<SettingsQueryResult>(settingsQuery)
+const settings = await client.fetch(settingsQuery)
Huge thanks to @romeovs for championing this feature!
🐛 Notable bugfixes
- Fixes default messaging in the environment variable file created by
sanity init --env
- Fixes an issue that could cause wrong list counts in the Portable Text Editor
- Fixes an issue that could cause malformed strings to appear in documents passed to migration scripts
- Fixes several issues that could cause "missing context" errors in certain environments
- Fixes an issue causing the Presence avatar overlays on form fields not to appear when Sanity Studio is embedded in a React 19 app
📓 Full changelog
Author | Message | Commit |
---|---|---|
renovate[bot] | fix(deps): update dependency react-rx to v4 (#7266) | a9b9feb |
Simeon Griggs | feat: embellish nextjs blog starter (#7258) | 0fc8216 |
renovate[bot] | chore(deps): update linters (#7285) | eebb27b |
renovate[bot] | chore(deps): update dependency turbo to ^2.0.10 (#7284) | ecc74b4 |
Cody Olsen | chore: remove agressive npmrc options (#7282) | 8e99272 |
renovate[bot] | chore(deps): update dependency @sanity/tsdoc to v1.0.87 (#7287) | cade4c7 |
Cody Olsen | fix: remove react hooks linter suppressions in PT hooks (#7222) | f5cac7b |
Cody Olsen | fix: ensure search context provider value is memoized (#7200) | edf7560 |
Espen Hovlandsdal | chore(test-studio): add workspace for us based dataset (#7293) | 9f60cdc |
Simeon Griggs | fix(cli): don't prepend message about .env.local if creating .env.local (#7288) | ec27de0 |
renovate[bot] | fix(deps): Update dev-non-major (#7294) | 8d47f3e |
renovate[bot] | chore(deps): update dependency @sanity/pkg-utils to v6.10.8 (#7278) | 9ac527f |
renovate[bot] | fix(deps): update dependency @portabletext/editor to ^1.0.10 (#7290) | e5e2c89 |
renovate[bot] | chore(deps): update dependency @sanity/tsdoc to v1.0.88 (#7296) | b221828 |
renovate[bot] | chore(deps): update dependency @bjoerge/mutiny to ^0.7.0 (#7274) | 9edbcd9 |
renovate[bot] | chore(deps): update dependency @sanity/tsdoc to v1.0.88 (#7295) | e32932c |
Christian Grøngaard | fix(core): correctly reset PTE list counts (#7286) | acbc351 |
renovate[bot] | chore(deps): update dependency turbo to ^2.0.11 (#7300) | 1b21691 |
renovate[bot] | chore(deps): update dependency eslint-config-turbo to ^2.0.11 (#7299) | 45bfdd0 |
Geoff Ball | Update types.ts | c041d28 |
renovate[bot] | fix(deps): update dependency @sanity/presentation to v1.16.3 (#7302) | cc744df |
renovate[bot] | chore(deps): update dependency @bjoerge/mutiny to ^0.7.1 (#7306) | 6a6c4bf |
renovate[bot] | fix(deps): Update dev-non-major (#7307) | fe40caf |
Cody Olsen | feat(codegen): generate SanityQueries interface in @sanity/codegen (#6997) (#7304) | 886ab25 |
renovate[bot] | chore(deps): update dependency @sanity/pkg-utils to v6.10.9 (#7313) | 33c3c7b |
renovate[bot] | chore(deps): update dependency @sanity/tsdoc to v1.0.90 (#7314) | ffaf81b |
renovate[bot] | chore(deps): update dependency @sanity/tsdoc to v1.0.90 (#7315) | e5563b6 |
Rico Kahler | fix(cli): dedupe styled-components in vite config (#7310) |
e82e815 |
Rico Kahler | refactor: flatten _singletons and increase usage of sanity/_createContext (#7311) |
c512fa7 |
renovate[bot] | fix(deps): update dependency @portabletext/editor to ^1.0.11 (#7316) | cec7b12 |
Binoy Patel | chore(deps): updates ora to ^8.0.1 (#7320) | 327e5b4 |
renovate[bot] | fix(deps): update dependency @portabletext/editor to ^1.0.11 (#7317) | de01242 |
renovate[bot] | chore(deps): update dependency lerna to ^8.1.8 (#7322) | d53ab33 |
Cody Olsen | refactor: remove prefersLatestPublished handling (#7305) |
542b07b |
Cody Olsen | fix: support field presence avatars on react 19 (#7308) | 8d003e8 |
Bjørge Næss | fix(migrate): properly decode chunks of multibyte unicode strings (#7321) | ba4d4a8 |
Sindre Gulseth | feat(typegen): add location of discovered query (#7327) | d77e3ad |
Sindre Gulseth | chore(typegen): trace overloadClientMethods usage (#7326) | 68fe8cd |
v3.52.4
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.
🐛 Notable bugfixes
- Fixes a bug that prevents keyboard shortcuts from pasting images and files.
📓 Full changelog
Author | Message | Commit |
---|---|---|
Rico Kahler | fix(core): early return if paste target is a file/image (#7269) | 6fc602c |
Cody Olsen | fix(deps): bump @sanity/pkg-utils to v6.10.7 (#7277) |
56d9e16 |
v3.52.3
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.
🐛 Notable Bugfixes
- Restores the
FieldPresenceWithOverlay
export to address issues with third-party plugins relying on this feature. Plugin authors are advised to use theFieldPresence
export instead, as the two have always been identical. - Resolves a build configuration issue that caused interoperability problems with CommonJS (CJS) modules, leading to errors during Vite's startup process.
- Fixes a bug that prevented keyboard shortcuts from pasting files and images correctly. This ensures that the copy/paste handler does not interfere with file and image inputs.
- Adds
'image'
literal toImageMetadataType
. Thanks @xuzuodong!
📓 Full changelog
Author | Message | Commit |
---|---|---|
Rico Kahler | test: adds jest config for CLI tests within the sanity module (#7243) |
917dc59 |
renovate[bot] | fix(deps): update dependency groq-js to ^1.11.1 (#7247) | 0d6c67e |
renovate[bot] | fix(deps): update dependency groq-js to ^1.12.0 (#7252) | ef01b92 |
Nina Andal Aarvik | fix(chore): add aria label to datepicker button (#6952) | a5c05d9 |
Rico Kahler | fix(cli): remove conditions to prevent CJS interop errors (#7267) |
5031cef |
Cody Olsen | fix: add back FieldPresenceWithOverlay export (#7263) |
b9785f0 |
renovate[bot] | fix(deps): update dependency @portabletext/editor to ^1.0.9 (#7250) | 10fa5cb |
renovate[bot] | chore(deps): update dependency lerna to ^8.1.7 (#7219) | a7dbe80 |
renovate[bot] | chore(deps): update dependency @types/lodash to ^4.17.7 (#7271) | fe82ee6 |
renovate[bot] | chore(deps): update testing-library monorepo (#7272) | 57daedb |
renovate[bot] | chore(deps): update dependency esbuild-register to ^3.6.0 (#7275) | dfc003e |
renovate[bot] | fix(deps): Update dev-non-major (#7273) | 95e4ce0 |
Hash Brown | chore: add literal to ImageMetadataType (#7190) | 61734db |
Bjørge Næss | chore(deps): upgrade to pnpm 9 (#7279) | 5758665 |
v3.52.2
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.
🐛 Notable bugfixes
- General improvements to studio performance
- Switching between workspaces now uses an anchor link, resolving an issue where document operations might occur across datasets.
📓 Full changelog
Author | Message | Commit |
---|---|---|
renovate[bot] | fix(deps): update dependency @sanity/client to ^6.21.1 (#7215) | 08658f2 |
Cody Olsen | chore: enable production react profiling in test studios (#7198) | 3a9dafa |
Cody Olsen | fix: remove "a key prop is spread into JSX" warning (#7224) | 615c3c8 |
renovate[bot] | fix(deps): update dependency @sanity/export to ^3.41.0 (#7223) | 0332d38 |
Cody Olsen | fix(WorkspacesProvider): run prepareConfig in a passive effect (#7226) |
2c35087 |
Cody Olsen | chore: add dev:test-studio-production-profiling script (#7225) |
8dfa353 |
Cody Olsen | fix: improve hook collection state performance (#7218) | bebeac5 |
Cody Olsen | refactor: replace useClickOutside with useClickOutsideEvent (#7201) |
b4740aa |
renovate[bot] | fix(deps): update dependency groq-js to ^1.11.0 (#7229) | 8b92196 |
Cody Olsen | feat: refactor createTrackerScope internals to be more efficient (#6946) |
c4f9a1f |
Carolina Gonzalez | fix: hard link between datasets, for now (#7228) | 2e77986 |
v3.52.1
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.
🐛 Notable bugfixes
- Fixes a regression that caused the Media plugin (
sanity-plugin-media
) to crash due to a configuration issue with the build tooling in the CLI.
📓 Full changelog
Author | Message | Commit |
---|---|---|
Cody Olsen | fix: ensure context provider values are memoized (#7199) | ff49411 |
renovate[bot] | fix(deps): Update dev-non-major (#7216) | f6bb311 |
RitaDias | chore: set up | c0cec21 |
RitaDias | fix(sanity/cli): issue with plugins would crash | 3682286 |
v3.52.0
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.
🐛 Notable bugfixes
- Fixes a package bundle configuration issue in auto-updating Studios that caused Presentation to crash.
- Adds aliases to internal Vite configuration used when running
sanity build
andsanity deploy
to prevent missing React context issues. - Improves error messages when duplicate instances of Sanity are found in
node_modules
.
📓 Full changelog
Author | Message | Commit |
---|---|---|
Cody Olsen | fix(deps): update dependency @sanity/ui to ^2.7.0 (#7168) | b60195b |
Espen Hovlandsdal | chore: clean up e2e studio tasks, headless env var (#7158) | 9dbb9f6 |
Ash | fix(sanity): ensure Actions API client uses adequate API version (#7166) | 25a983b |
renovate[bot] | chore(deps): update dependency styled-components to ^6.1.12 (#7178) | 8805315 |
renovate[bot] | chore(deps): update dependency turbo to ^2.0.7 (#7182) | 9b79104 |
renovate[bot] | chore(deps): update pnpm to v8.15.9 (#7183) | f73fb0f |
renovate[bot] | fix(deps): Update dev-non-major (#7184) | 706a86b |
renovate[bot] | fix(deps): update dependency @sanity/ui to ^2.8.2 (#7188) | ef0d937 |
renovate[bot] | fix(deps): update dependency @sanity/ui to ^2.8.2 (#7185) | 6535562 |
renovate[bot] | fix(deps): update dependency @sanity/ui to ^2.8.5 (#7192) | 1515df1 |
renovate[bot] | fix(deps): update dependency @sanity/ui to ^2.8.5 (#7191) | 8a9730c |
Rico Kahler | fix: unify externals in auto-updating builds (#7187) | a6def04 |
Cody Olsen | refactor: replace useOnClickOutside with useClickOutsideEvent (#7189) |
d68bb94 |
renovate[bot] | fix(deps): update dependency @sanity/ui to ^2.8.6 (#7196) | 7771ee0 |
renovate[bot] | fix(deps): update dependency @sanity/ui to ^2.8.7 (#7197) | fe8efa0 |
renovate[bot] | fix(deps): update dependency @sanity/icons to ^3.3.1 (#7204) | bf9ca0b |
renovate[bot] | fix(deps): Update dev-non-major (#7203) | f0d5f82 |
Cody Olsen | fix: detect duplicate context errors (#7160) | 7f3a881 |
renovate[bot] | fix(deps): update dependency @sanity/ui to ^2.8.8 (#7210) | 944d392 |
renovate[bot] | chore(lockfile): update dependency @sanity/logos to v2.1.13 (#7211) | 208a2d1 |
renovate[bot] | fix(deps): Update dev-non-major (#7212) | a20e9b1 |
Rico Kahler | feat(core): add aliases to mitigate context issues (#7172) | 776f16b |
v3.51.0
✨ Highlights
Clickable links in comments
URLs included in comments are now rendered as clickable links, which is infinitely more useful than unclickable links.
Other features
- Updates to configuration and blog template files when initializing a project inside a Next.js app: using an
src
folder in your directory if it exists, some changes to schemas and how they're imported.
🐛 Notable bugfixes
- Fixes a regression causing platform-aware hotkeys (for example,
Ctrl + Option + D
for duplicating a document) not to be displayed in tooltips.
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 |
---|---|---|
Espen Hovlandsdal | fix: force arborist ^7.5.4 | 49f278a |
ecospark[bot] | chore(prettier): fix unformatted files 🤖 ✨ (#7146) | 213f4b1 |
ecospark[bot] | chore(deps): dedupe pnpm-lock.yaml (#7145) | 75a409a |
Espen Hovlandsdal | fix(core): restore platform-aware keyboard shortcuts (#6819) | 512965c |
renovate[bot] | fix(deps): update dependency @sanity/ui to ^2.6.8 (#7144) | 3fca2ef |
renovate[bot] | fix(deps): Update dev-non-major (#7149) | 3ae92a5 |
Herman Wikner | feat(core): clickable links in comment message (#7093) | 6fad0c5 |
Simeon Griggs | feat: update schema types formatting and init to include src (#7094) | d42da14 |
Cody Olsen | chore: remove 3d demos from test studio (#7157) | 97fed17 |
Cody Olsen | chore: setup workflow for E2E tests that @sanity/ui can run on its PRs (#7156) |
88bd6c4 |
Rupert Dunk | fix(sanity): open correct groups and fieldsets on setOpenPath (#7154) |
b278800 |
renovate[bot] | fix(deps): Update dev-non-major (#7164) | 41a3039 |
v3.50.0
✨ 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.
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.
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 indevDependencies
instead ofdependencies
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 |
v3.49.0
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.
✨ Highlights
New TypeGen Features
Better GROQ Function Coverage
We have added the following improvements to type generation for GROQ query results:
- Added support for array functions
- Added support for
dateTime::now()
andglobal::now()
. - Added support for
round()
,upper()
, andlower()
functions. - Support negative groups in conditions:
*[!(_type == "post")]
Improved Union Handling in TypeGen
TypeGen now correctly expands all unions inside an object, addressing this reported issue on GitHub. Previously, only a part of a union might be returned. TypeGen now ensures that all object types in a union are expanded and included in the generated types.
// Example query
export const HomePageQuery = groq`*[_type == "page" && slug.current == "homepage"]{
title,
components[] {
_type == "hero" => { title, "image": image.asset->url },
_type == "cta" => { title, link }
}
}`;
TyeGen will now generate the following type for the query above:
export type HomePageQueryResult = Array<{
title: string;
components: Array<
| { _type: 'hero'; title: string; image: string }
| { _type: 'cta'; title: string; link: string }
>;
}>;
New import path for the Portable Text Editor
We’ve started work on a standalone Portable Text Editor package, and thus transitioned to using the @portabletext/editor
package instead of the now deprecated @sanity/portable-text-editor
package. This change includes several internal improvements and fixes. You can follow this work in this repository on GitHub — more documentation to come.
Advanced users who have used the @sanity/portable-text-editor
dependecy should update to @portabletext/editor
to ensure continued support and improvements.
🐛 Notable bugfixes
- Fixes an issue where
FormInput
would not render fields inside a fieldset. - Various TypeGen bug fixes.
📓 Full changelog
Author | Message | Commit |
---|---|---|
Cody Olsen | chore(deps): upgrade turbo to v2 (#6985) | 2fb8f9b |
Nina Andal Aarvik | fix(core): change padding to fix tab box (#7000) | 7ed682e |
Herman Wikner | fix(core): handle fieldset members in FormInput (#7045) |
b932de6 |
ecospark[bot] | chore(deps): dedupe pnpm-lock.yaml (#7034) | 8820979 |
Herman Wikner | fix(core): open PTE dialogs in tree editing dialog with openPath (#7046) |
d0b9ab0 |
renovate[bot] | fix(deps): update dependency groq-js to ^1.10.0 (#7053) | 628cb76 |
Rico Kahler | refactor: use @portabletext/editor instead of @sanity/portable-text-editor (#7035) |
9864985 |
renovate[bot] | fix(deps): update dependency get-it to ^8.6.2 (#7052) | b73b68c |
renovate[bot] | fix(deps): update dependency @sanity/export to ^3.40.0 (#7056) | c44c405 |