@sanity/schema 5.17.0-next.21 → 5.17.0-next.22
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/_internal.d.ts +6 -6
- package/lib/_internal.js +2 -2
- package/lib/_internal.js.map +1 -1
- package/package.json +5 -5
package/lib/_internal.d.ts
CHANGED
|
@@ -242,8 +242,8 @@ declare const builtinTypes: ({
|
|
|
242
242
|
title: string;
|
|
243
243
|
validation?: undefined;
|
|
244
244
|
hidden?: undefined;
|
|
245
|
-
readOnly?: undefined;
|
|
246
245
|
fieldset?: undefined;
|
|
246
|
+
readOnly?: undefined;
|
|
247
247
|
} | {
|
|
248
248
|
name: string;
|
|
249
249
|
type: string;
|
|
@@ -321,8 +321,8 @@ declare const builtinTypes: ({
|
|
|
321
321
|
title: string;
|
|
322
322
|
validation?: undefined;
|
|
323
323
|
hidden?: undefined;
|
|
324
|
-
readOnly?: undefined;
|
|
325
324
|
fieldset?: undefined;
|
|
325
|
+
readOnly?: undefined;
|
|
326
326
|
} | {
|
|
327
327
|
name: string;
|
|
328
328
|
type: string;
|
|
@@ -396,17 +396,17 @@ declare const builtinTypes: ({
|
|
|
396
396
|
};
|
|
397
397
|
}[];
|
|
398
398
|
fields: ({
|
|
399
|
-
title?: undefined;
|
|
400
|
-
readOnly?: undefined;
|
|
401
|
-
fieldset?: undefined;
|
|
402
399
|
name: string;
|
|
403
400
|
type: string;
|
|
404
|
-
|
|
401
|
+
fieldset?: undefined;
|
|
402
|
+
title?: undefined;
|
|
405
403
|
readOnly?: undefined;
|
|
404
|
+
} | {
|
|
406
405
|
name: string;
|
|
407
406
|
title: string;
|
|
408
407
|
type: string;
|
|
409
408
|
fieldset: string;
|
|
409
|
+
readOnly?: undefined;
|
|
410
410
|
} | {
|
|
411
411
|
fieldset?: undefined;
|
|
412
412
|
name: string;
|
package/lib/_internal.js
CHANGED
|
@@ -492,9 +492,9 @@ function maybeOrdering(val) {
|
|
|
492
492
|
}
|
|
493
493
|
function maybeOrderingBy(val) {
|
|
494
494
|
if (!isObject(val) || Array.isArray(val)) return;
|
|
495
|
-
const field = "field" in val && typeof val.field == "string" ? val.field : void 0, direction = "direction" in val && (val.direction === "asc" || val.direction === "desc") ? val.direction : void 0;
|
|
495
|
+
const field = "field" in val && typeof val.field == "string" ? val.field : void 0, direction = "direction" in val && (val.direction === "asc" || val.direction === "desc") ? val.direction : void 0, nulls = "nulls" in val && (val.nulls === "first" || val.nulls === "last") ? val.nulls : void 0;
|
|
496
496
|
if (!(!field || !direction))
|
|
497
|
-
return { field, direction };
|
|
497
|
+
return { field, direction, ...nulls && { nulls } };
|
|
498
498
|
}
|
|
499
499
|
function isLessCanonicalName(a, b) {
|
|
500
500
|
return a.length < b.length || a.length === b.length && a < b;
|