sanity 3.70.1-corel.541 → 3.70.1-corel.544
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/lib/_chunks-cjs/pane.js +2 -2
- package/lib/_chunks-cjs/pane.js.map +1 -1
- package/lib/_chunks-cjs/version.js +1 -1
- package/lib/_chunks-es/pane.mjs +2 -2
- package/lib/_chunks-es/pane.mjs.map +1 -1
- package/lib/_chunks-es/version.mjs +1 -1
- package/lib/_legacy/pane.esm.js +2 -2
- package/lib/_legacy/pane.esm.js.map +1 -1
- package/lib/_legacy/version.esm.js +1 -1
- package/package.json +10 -10
- package/src/structure/panes/document/DocumentPaneProvider.tsx +10 -10
package/package.json
CHANGED
@@ -1,6 +1,6 @@
|
|
1
1
|
{
|
2
2
|
"name": "sanity",
|
3
|
-
"version": "3.70.1-corel.
|
3
|
+
"version": "3.70.1-corel.544+bc92a49433",
|
4
4
|
"description": "Sanity is a real-time content infrastructure with a scalable, hosted backend featuring a Graph Oriented Query Language (GROQ), asset pipelines and fast edge caches",
|
5
5
|
"keywords": [
|
6
6
|
"sanity",
|
@@ -159,10 +159,10 @@
|
|
159
159
|
"@rexxars/react-json-inspector": "^9.0.1",
|
160
160
|
"@sanity/asset-utils": "^2.0.6",
|
161
161
|
"@sanity/bifur-client": "^0.4.1",
|
162
|
-
"@sanity/cli": "3.70.1-corel.
|
162
|
+
"@sanity/cli": "3.70.1-corel.544+bc92a49433",
|
163
163
|
"@sanity/client": "^6.24.4",
|
164
164
|
"@sanity/color": "^3.0.0",
|
165
|
-
"@sanity/diff": "3.70.1-corel.
|
165
|
+
"@sanity/diff": "3.70.1-corel.544+bc92a49433",
|
166
166
|
"@sanity/diff-match-patch": "^3.1.1",
|
167
167
|
"@sanity/eventsource": "^5.0.0",
|
168
168
|
"@sanity/export": "^3.42.2",
|
@@ -171,14 +171,14 @@
|
|
171
171
|
"@sanity/import": "^3.37.9",
|
172
172
|
"@sanity/insert-menu": "1.0.19",
|
173
173
|
"@sanity/logos": "^2.1.4",
|
174
|
-
"@sanity/migrate": "3.70.1-corel.
|
175
|
-
"@sanity/mutator": "3.70.1-corel.
|
174
|
+
"@sanity/migrate": "3.70.1-corel.544+bc92a49433",
|
175
|
+
"@sanity/mutator": "3.70.1-corel.544+bc92a49433",
|
176
176
|
"@sanity/presentation": "1.22.1-release.0",
|
177
|
-
"@sanity/schema": "3.70.1-corel.
|
177
|
+
"@sanity/schema": "3.70.1-corel.544+bc92a49433",
|
178
178
|
"@sanity/telemetry": "^0.7.7",
|
179
|
-
"@sanity/types": "3.70.1-corel.
|
179
|
+
"@sanity/types": "3.70.1-corel.544+bc92a49433",
|
180
180
|
"@sanity/ui": "^2.11.2",
|
181
|
-
"@sanity/util": "3.70.1-corel.
|
181
|
+
"@sanity/util": "3.70.1-corel.544+bc92a49433",
|
182
182
|
"@sanity/uuid": "^3.0.1",
|
183
183
|
"@sentry/react": "^8.33.0",
|
184
184
|
"@tanstack/react-table": "^8.16.0",
|
@@ -272,7 +272,7 @@
|
|
272
272
|
"@repo/dev-aliases": "3.70.0",
|
273
273
|
"@repo/package.config": "3.70.0",
|
274
274
|
"@repo/test-config": "3.70.0",
|
275
|
-
"@sanity/codegen": "3.70.1-corel.
|
275
|
+
"@sanity/codegen": "3.70.1-corel.544+bc92a49433",
|
276
276
|
"@sanity/generate-help-url": "^3.0.0",
|
277
277
|
"@sanity/pkg-utils": "6.13.4",
|
278
278
|
"@sanity/tsdoc": "1.0.169",
|
@@ -315,5 +315,5 @@
|
|
315
315
|
"engines": {
|
316
316
|
"node": ">=18"
|
317
317
|
},
|
318
|
-
"gitHead": "
|
318
|
+
"gitHead": "bc92a49433a2d180835748b34d0d689d8d007218"
|
319
319
|
}
|
@@ -644,18 +644,18 @@ export const DocumentPaneProvider = memo((props: DocumentPaneProviderProps) => {
|
|
644
644
|
patchRef.current = () => {
|
645
645
|
throw new Error('Attempted to patch a read-only document')
|
646
646
|
}
|
647
|
-
}
|
647
|
+
} else {
|
648
|
+
// note: this needs to happen in an insertion effect to make sure we're ready to receive patches from child components when they run their effects initially
|
649
|
+
// in case they do e.g. `useEffect(() => props.onChange(set("foo")), [])`
|
650
|
+
// Note: although we discourage patch-on-mount, we still support it.
|
651
|
+
patchRef.current = (event: PatchEvent) => {
|
652
|
+
// when creating a new draft
|
653
|
+
if (!editState.draft && !editState.published) {
|
654
|
+
telemetry.log(CreatedDraft)
|
655
|
+
}
|
648
656
|
|
649
|
-
|
650
|
-
// in case they do e.g. `useEffect(() => props.onChange(set("foo")), [])`
|
651
|
-
// Note: although we discourage patch-on-mount, we still support it.
|
652
|
-
patchRef.current = (event: PatchEvent) => {
|
653
|
-
// when creating a new draft
|
654
|
-
if (!editState.draft && !editState.published) {
|
655
|
-
telemetry.log(CreatedDraft)
|
657
|
+
patch.execute(toMutationPatches(event.patches), initialValue.value)
|
656
658
|
}
|
657
|
-
|
658
|
-
patch.execute(toMutationPatches(event.patches), initialValue.value)
|
659
659
|
}
|
660
660
|
}, [editState.draft, editState.published, initialValue.value, patch, telemetry, readOnly])
|
661
661
|
|