@sanity/assist 3.2.0 → 3.2.2
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/dist/index.esm.js +3 -1
- package/dist/index.esm.js.map +1 -1
- package/dist/index.js +3 -1
- package/dist/index.js.map +1 -1
- package/dist/index.mjs +3 -1
- package/dist/index.mjs.map +1 -1
- package/package.json +4 -2
- package/src/helpers/assistSupported.ts +1 -0
- package/src/plugin.tsx +3 -1
- package/src/schemas/serialize/schemaUtils.ts +1 -0
- package/src/schemas/serialize/serializeSchema.test.ts +59 -0
- package/src/schemas/serialize/serializeSchema.ts +1 -0
package/dist/index.mjs
CHANGED
|
@@ -236,7 +236,7 @@ function isDisabled(type) {
|
|
|
236
236
|
return !isSchemaAssistEnabled(type) || isUnsupportedType(type);
|
|
237
237
|
}
|
|
238
238
|
function isUnsupportedType(type) {
|
|
239
|
-
return type.jsonType === "number" || type.name === "sanity.imageCrop" || type.name === "sanity.imageHotspot" || isType(type, "reference") && !type?.options?.aiAssist?.embeddingsIndex || isType(type, "crossDatasetReference") || isType(type, "slug") || isType(type, "url") || isType(type, "date") || isType(type, "datetime") || isType(type, "file");
|
|
239
|
+
return type.jsonType === "number" || type.name === "sanity.imageCrop" || type.name === "sanity.imageHotspot" || isType(type, "globalDocumentReference") || isType(type, "reference") && !type?.options?.aiAssist?.embeddingsIndex || isType(type, "crossDatasetReference") || isType(type, "slug") || isType(type, "url") || isType(type, "date") || isType(type, "datetime") || isType(type, "file");
|
|
240
240
|
}
|
|
241
241
|
const FirstAssistedPathContext = createContext(void 0);
|
|
242
242
|
function FirstAssistedPathProvider(props) {
|
|
@@ -477,6 +477,7 @@ const hiddenTypes = [
|
|
|
477
477
|
"document",
|
|
478
478
|
"email",
|
|
479
479
|
"file",
|
|
480
|
+
"globalDocumentReference",
|
|
480
481
|
"image",
|
|
481
482
|
"number",
|
|
482
483
|
"object",
|
|
@@ -3877,6 +3878,7 @@ const instructionForm = [
|
|
|
3877
3878
|
);
|
|
3878
3879
|
return {
|
|
3879
3880
|
name: packageName,
|
|
3881
|
+
handlesGDR: !0,
|
|
3880
3882
|
schema: {
|
|
3881
3883
|
types: schemaTypes
|
|
3882
3884
|
},
|