@sanity/types 6.4.0-next.38 → 6.4.0-workbench.20260701093415
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/index.d.ts +1 -25
- package/package.json +6 -6
package/lib/index.d.ts
CHANGED
|
@@ -169,25 +169,6 @@ interface Role {
|
|
|
169
169
|
description?: string;
|
|
170
170
|
}
|
|
171
171
|
/** @public */
|
|
172
|
-
type UserAttributeType = 'string' | 'string-array' | 'integer' | 'integer-array' | 'number' | 'number-array' | 'boolean';
|
|
173
|
-
type UserAttributeValueByType = {
|
|
174
|
-
'string': string;
|
|
175
|
-
'string-array': string[];
|
|
176
|
-
'integer': number;
|
|
177
|
-
'integer-array': number[];
|
|
178
|
-
'number': number;
|
|
179
|
-
'number-array': number[];
|
|
180
|
-
'boolean': boolean;
|
|
181
|
-
};
|
|
182
|
-
/** @public */
|
|
183
|
-
type UserAttributeValue = UserAttributeValueByType[UserAttributeType];
|
|
184
|
-
/** @public */
|
|
185
|
-
type CurrentUserAttribute = { [T in UserAttributeType]: {
|
|
186
|
-
key: string;
|
|
187
|
-
type: T;
|
|
188
|
-
value: UserAttributeValueByType[T];
|
|
189
|
-
} }[UserAttributeType];
|
|
190
|
-
/** @public */
|
|
191
172
|
interface CurrentUser {
|
|
192
173
|
id: string;
|
|
193
174
|
name: string;
|
|
@@ -197,11 +178,6 @@ interface CurrentUser {
|
|
|
197
178
|
/** @deprecated use `roles` instead */
|
|
198
179
|
role: string;
|
|
199
180
|
roles: Role[];
|
|
200
|
-
/**
|
|
201
|
-
* Organization-scoped user attributes for the current project.
|
|
202
|
-
* Only present when returned by `/users/me` with a project context.
|
|
203
|
-
*/
|
|
204
|
-
attributes?: CurrentUserAttribute[];
|
|
205
181
|
}
|
|
206
182
|
/** @public */
|
|
207
183
|
interface User {
|
|
@@ -3513,4 +3489,4 @@ interface UploadState {
|
|
|
3513
3489
|
};
|
|
3514
3490
|
previewImage?: string;
|
|
3515
3491
|
}
|
|
3516
|
-
export { ArrayActionName, ArrayDefinition, ArrayOfEntry, ArrayOfType, ArrayOptions, ArrayRule, ArraySchemaType, ArraySchemaTypeOf, Asset, AssetFromSource, AssetMetadataType, AssetSchemaTypeOptions, AssetSource, AssetSourceComponentAction, AssetSourceComponentProps, AssetSourceOpenInSourceResult, AssetSourceSpec, AssetSourceUploadEvent, AssetSourceUploadEventAbort, AssetSourceUploadEventAllComplete, AssetSourceUploadEventError, AssetSourceUploadEventProgress, AssetSourceUploadEventStatus, AssetSourceUploadFile, AssetSourceUploadSubscriber, AssetSourceUploader, AssetSourceUploaderClass, AutocompleteString, BaseSchemaDefinition, BaseSchemaType, BaseSchemaTypeOptions, BlockAnnotationDefinition, BlockChildrenObjectField, BlockDecoratorDefinition, BlockDefinition, BlockListDefinition, BlockListObjectField, BlockMarksDefinition, BlockOptions, BlockRule, BlockSchemaType, BlockStyleDefinition, BlockStyleObjectField, BooleanDefinition, BooleanOptions, BooleanRule, BooleanSchemaType, CanvasAppOptions, CanvasNotificationPayload, CollapseOptions, ConditionalIndexAccess, ConditionalProperty, ConditionalPropertyCallback, ConditionalPropertyCallbackContext, CreateIfNotExistsMutation, CreateMutation, CreateOrReplaceMutation, CreateSquashedMutation, CrossDatasetReferenceDefinition, CrossDatasetReferenceFilterResolver, CrossDatasetReferenceFilterSearchOptions, CrossDatasetReferenceSchemaType, CrossDatasetReferenceValue, CrossDatasetType, CurrentUser,
|
|
3492
|
+
export { ArrayActionName, ArrayDefinition, ArrayOfEntry, ArrayOfType, ArrayOptions, ArrayRule, ArraySchemaType, ArraySchemaTypeOf, Asset, AssetFromSource, AssetMetadataType, AssetSchemaTypeOptions, AssetSource, AssetSourceComponentAction, AssetSourceComponentProps, AssetSourceOpenInSourceResult, AssetSourceSpec, AssetSourceUploadEvent, AssetSourceUploadEventAbort, AssetSourceUploadEventAllComplete, AssetSourceUploadEventError, AssetSourceUploadEventProgress, AssetSourceUploadEventStatus, AssetSourceUploadFile, AssetSourceUploadSubscriber, AssetSourceUploader, AssetSourceUploaderClass, AutocompleteString, BaseSchemaDefinition, BaseSchemaType, BaseSchemaTypeOptions, BlockAnnotationDefinition, BlockChildrenObjectField, BlockDecoratorDefinition, BlockDefinition, BlockListDefinition, BlockListObjectField, BlockMarksDefinition, BlockOptions, BlockRule, BlockSchemaType, BlockStyleDefinition, BlockStyleObjectField, BooleanDefinition, BooleanOptions, BooleanRule, BooleanSchemaType, CanvasAppOptions, CanvasNotificationPayload, CollapseOptions, ConditionalIndexAccess, ConditionalProperty, ConditionalPropertyCallback, ConditionalPropertyCallbackContext, CreateIfNotExistsMutation, CreateMutation, CreateOrReplaceMutation, CreateSquashedMutation, CrossDatasetReferenceDefinition, CrossDatasetReferenceFilterResolver, CrossDatasetReferenceFilterSearchOptions, CrossDatasetReferenceSchemaType, CrossDatasetReferenceValue, CrossDatasetType, CurrentUser, CustomValidator, CustomValidatorResult, DashboardNotificationPayload, DateDefinition, DateOptions, DateRule, DatetimeDefinition, DatetimeOptions, DatetimeRule, DefineArrayMemberBase, DefineSchemaBase, DefineSchemaOptions, DefineSchemaType, DeleteMutation, DeprecatedProperty, DeprecatedSchemaType, DeprecationConfiguration, DocumentDefinition, DocumentOptions, DocumentRule, DocumentSystem, DocumentSystemRef, EmailDefinition, EmailOptions, EmailRule, EmptyProps, EnumListProps, FieldDefinition, FieldDefinitionBase, FieldGroup, FieldGroupDefinition, FieldReference, FieldRules, Fieldset, FieldsetDefinition, File, FileAsset, FileDefinition, FileOptions, FileRule, FileSchemaType, FileValue, FormNodeValidation, GeopointDefinition, GeopointOptions, GeopointRule, GeopointValue, GlobalDocumentReferenceDefinition, GlobalDocumentReferenceFilterResolver, GlobalDocumentReferenceFilterSearchOptions, GlobalDocumentReferenceSchemaType, GlobalDocumentReferenceType, GlobalDocumentReferenceValue, HotspotOptions, HotspotPreview, I18nTextRecord, I18nTitledListValue, Image, ImageAsset, ImageCrop, ImageDefinition, ImageDimensions, ImageHotspot, ImageMetadata, ImageMetadataType, ImageOptions, ImagePalette, ImageRule, ImageSchemaType, ImageSwatch, ImageUrlAutoMode, ImageUrlCropMode, ImageUrlFitMode, ImageUrlFormat, ImageUrlOrientation, ImageUrlParams, ImageValue, IndexTuple, InitialValueProperty, InitialValueResolver, InitialValueResolverContext, InlineFieldDefinition, type InsertMenuOptions, InsertPatch, IntrinsicArrayOfBase, IntrinsicArrayOfDefinition, IntrinsicBase, IntrinsicDefinitions, IntrinsicTypeName, KeyedObject, KeyedSegment, LocalizedValidationMessages, MEDIA_LIBRARY_ASSET_ASPECT_TYPE_NAME, MaybeAllowUnknownProps, MaybePreview, MediaAssetTypes, MediaLibraryAssetAspectDefinition, MediaLibraryAssetAspectDocument, MediaLibraryAssetAspectSupportedFieldDefinitions, MediaLibraryAssetAspectTypeName, MediaLibraryAssetType, MediaLibraryFilter, MediaLibraryOptions, MediaValidationValue, MediaValidator, MendozaEffectPair, MendozaPatch, ModalOptions, MultiFieldSet, MultipleMutationResult, Mutation, MutationOperationName, MutationSelection, NarrowPreview, NumberDefinition, NumberOptions, NumberRule, NumberSchemaType, ObjectDefinition, ObjectField, ObjectFieldType, ObjectOptions, ObjectRule, ObjectSchemaType, ObjectSchemaTypeWithOptions, PatchMutation, PatchMutationOperation, PatchOperations, Path, PathSegment, PortableTextBlock, PortableTextChild, PortableTextListBlock, PortableTextObject, PortableTextSpan, PortableTextTextBlock, PrepareViewOptions, PreviewConfig, PreviewValue, Reference, ReferenceBaseOptions, ReferenceDefinition, ReferenceFilterOptions, ReferenceFilterQueryOptions, ReferenceFilterResolver, ReferenceFilterResolverContext, ReferenceFilterResolverOptions, ReferenceFilterSearchOptions, ReferenceOptions, ReferenceRule, ReferenceSchemaType, ReferenceTo, ReferenceTypeFilter, ReferenceTypeFilterContext, ReferenceTypeOption, ReferenceValue, Role, Rule, RuleBuilder, RuleClass, RuleDef, RuleSpec, RuleSpecConstraint, RuleTypeConstraint, SanityCreateOptions, SanityDocument, SanityDocumentLike, Schema, SchemaType, SchemaTypeDefinition, SchemaValidationError, SchemaValidationProblem, SchemaValidationProblemGroup, SchemaValidationProblemPath, SchemaValidationValue, SchemaValidationWarning, SearchConfiguration, SearchStrategy, SingleFieldSet, SingleMutationResult, Slug, SlugDefinition, SlugIsUniqueValidator, SlugOptions, SlugParent, SlugRule, SlugSchemaType, SlugSourceContext, SlugSourceFn, SlugValidationContext, SlugValue, SlugifierFn, SortOrdering, SortOrderingItem, SpanMarksObjectField, SpanSchemaType, SpanTextObjectField, StrictDefinition, StrictVersionLayeringOptions, StringDefinition, StringOptions, StringRule, StringSchemaType, StudioNotificationPayload, SwatchName, TextDefinition, TextOptions, TextRule, TextSchemaType, TitledListValue, TransactionLogEvent, TransactionLogEventWithEffects, TransactionLogEventWithMutations, TransactionLogMutation, TypeAliasDefinition, TypeReference, TypedObject, UploadState, UriValidationOptions, UrlDefinition, UrlOptions, UrlRule, User, ValidationBuilder, ValidationContext, ValidationError, ValidationErrorClass, ValidationErrorOptions, ValidationMarker, Validator, Validators, WeakCrossDatasetReferenceValue, WeakGlobalDocumentReferenceValue, WeakReference, WidenInitialValue, WidenValidation, defineArrayMember, defineAssetAspect, defineField, defineType, isArrayOfBlocksSchemaType, isArrayOfObjectsSchemaType, isArrayOfPrimitivesSchemaType, isArrayOfStringsSchemaType, isArraySchemaType, isAssetAspect, isBlockChildrenObjectField, isBlockListObjectField, isBlockSchemaType, isBlockStyleObjectField, isBooleanSchemaType, isCreateIfNotExistsMutation, isCreateMutation, isCreateOrReplaceMutation, isCreateSquashedMutation, isCrossDatasetReference, isCrossDatasetReferenceSchemaType, isDateTimeSchemaType, isDeleteMutation, isDeprecatedSchemaType, isDeprecationConfiguration, isDocumentSchemaType, isFileSchemaType, isGlobalDocumentReference, isImage, isImageSchemaType, isIndexSegment, isIndexTuple, isKeySegment, isKeyedObject, isNumberSchemaType, isObjectSchemaType, isPatchMutation, isPortableTextListBlock, isPortableTextSpan, isPortableTextTextBlock, isPrimitiveSchemaType, isReference, isReferenceSchemaType, isSanityDocument, isSearchStrategy, isSlug, isSpanSchemaType, isStringSchemaType, isTitledListValue, isTypedObject, isValidationError, isValidationErrorMarker, isValidationInfo, isValidationInfoMarker, isValidationWarning, isValidationWarningMarker, searchStrategies, typed };
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@sanity/types",
|
|
3
|
-
"version": "6.4.0-
|
|
3
|
+
"version": "6.4.0-workbench.20260701093415",
|
|
4
4
|
"description": "Type definitions for common Sanity data structures",
|
|
5
5
|
"keywords": [
|
|
6
6
|
"cms",
|
|
@@ -35,11 +35,11 @@
|
|
|
35
35
|
},
|
|
36
36
|
"dependencies": {
|
|
37
37
|
"@sanity/client": "^7.23.0",
|
|
38
|
-
"@sanity/media-library-types": "^1.
|
|
38
|
+
"@sanity/media-library-types": "^1.4.0"
|
|
39
39
|
},
|
|
40
40
|
"devDependencies": {
|
|
41
41
|
"@sanity/insert-menu": "3.0.8",
|
|
42
|
-
"@sanity/pkg-utils": "^10.
|
|
42
|
+
"@sanity/pkg-utils": "^10.8.1",
|
|
43
43
|
"@types/react": "^19.2.17",
|
|
44
44
|
"@typescript/native-preview": "beta",
|
|
45
45
|
"@vitejs/plugin-react": "^6.0.3",
|
|
@@ -47,9 +47,9 @@
|
|
|
47
47
|
"rimraf": "^6.1.3",
|
|
48
48
|
"vite": "^8.1.0",
|
|
49
49
|
"vitest": "^4.1.9",
|
|
50
|
-
"@repo/package.config": "6.4.0-
|
|
51
|
-
"@repo/tsconfig": "6.4.0-
|
|
52
|
-
"@repo/test-config": "6.4.0-
|
|
50
|
+
"@repo/package.config": "6.4.0-workbench.20260701093415+dca9757c93",
|
|
51
|
+
"@repo/tsconfig": "6.4.0-workbench.20260701093415+dca9757c93",
|
|
52
|
+
"@repo/test-config": "6.4.0-workbench.20260701093415+dca9757c93"
|
|
53
53
|
},
|
|
54
54
|
"peerDependencies": {
|
|
55
55
|
"@types/react": "*"
|