From edaa83db5b481ef3aefdbf9c998782d7abb5acd3 Mon Sep 17 00:00:00 2001 From: Xavier Rutayisire Date: Wed, 17 May 2023 11:45:16 +0200 Subject: [PATCH] chore(@prismicio/types-internal): upgrade @prismicio/types-internal dependency (#294) --- package-lock.json | 14 +++++++------- package.json | 2 +- test/types/customType-boolean.types.ts | 7 ++++--- test/types/customType-color.types.ts | 11 ++++------- test/types/customType-contentRelationship.types.ts | 7 ++++--- test/types/customType-date.types.ts | 11 ++++------- test/types/customType-embed.types.ts | 11 ++++------- test/types/customType-geoPoint.types.ts | 7 ++++--- test/types/customType-group.types.ts | 11 ++++------- test/types/customType-image.types.ts | 11 ++++------- test/types/customType-integration.types.ts | 7 ++++--- test/types/customType-keyText.types.ts | 7 ++++--- test/types/customType-link.types.ts | 11 ++++------- test/types/customType-linkToMedia.types.ts | 7 ++++--- test/types/customType-number.types.ts | 7 ++++--- test/types/customType-richText.types.ts | 7 ++++--- test/types/customType-select.types.ts | 7 ++++--- test/types/customType-sharedSlice.types.ts | 7 ++++--- test/types/customType-sharedSliceModel.types.ts | 11 ++++------- .../customType-sharedSliceModelVariation.types.ts | 7 ++++--- test/types/customType-slice.types.ts | 7 ++++--- test/types/customType-sliceZone.types.ts | 7 ++++--- test/types/customType-timestamp.types.ts | 7 ++++--- test/types/customType-title.types.ts | 7 ++++--- test/types/customType-uid.types.ts | 11 ++++------- test/types/customType.types.ts | 7 ++++--- 26 files changed, 104 insertions(+), 112 deletions(-) diff --git a/package-lock.json b/package-lock.json index 1ef8cfef..d2042189 100644 --- a/package-lock.json +++ b/package-lock.json @@ -14,7 +14,7 @@ }, "devDependencies": { "@prismicio/mock": "^0.2.0", - "@prismicio/types-internal": "^1.5.3", + "@prismicio/types-internal": "2.0.0-alpha.11", "@size-limit/preset-small-lib": "^8.2.4", "@trivago/prettier-plugin-sort-imports": "^4.1.1", "@typescript-eslint/eslint-plugin": "^5.59.0", @@ -911,9 +911,9 @@ } }, "node_modules/@prismicio/types-internal": { - "version": "1.5.3", - "resolved": "https://registry.npmjs.org/@prismicio/types-internal/-/types-internal-1.5.3.tgz", - "integrity": "sha512-GHV2rZsCUJJQDF7gF2to0F/3eolTXD/ng7ClfbqtHO3udJ5D+iifocAEnsEdi+Y9VKT/WVgyBi/dA6GAhNMHmQ==", + "version": "2.0.0-alpha.11", + "resolved": "https://registry.npmjs.org/@prismicio/types-internal/-/types-internal-2.0.0-alpha.11.tgz", + "integrity": "sha512-gV51WJatjBrkFUEeCFKXqCNzVjryuDqPVVdFz98SDqlFzK5jJZv4SoYKLpi1/IBeOOCwa+bfdvwGshZyCNxr2Q==", "dev": true, "dependencies": { "monocle-ts": "^2.3.11", @@ -8334,9 +8334,9 @@ "integrity": "sha512-xHPBWg+lPcl8U97VB/2oYK3MJlQoVPZq91hbeQO8WRyvq+zgpNST3xFOTk8SkQpgoH6wd50AxGZELvPrpojajQ==" }, "@prismicio/types-internal": { - "version": "1.5.3", - "resolved": "https://registry.npmjs.org/@prismicio/types-internal/-/types-internal-1.5.3.tgz", - "integrity": "sha512-GHV2rZsCUJJQDF7gF2to0F/3eolTXD/ng7ClfbqtHO3udJ5D+iifocAEnsEdi+Y9VKT/WVgyBi/dA6GAhNMHmQ==", + "version": "2.0.0-alpha.11", + "resolved": "https://registry.npmjs.org/@prismicio/types-internal/-/types-internal-2.0.0-alpha.11.tgz", + "integrity": "sha512-gV51WJatjBrkFUEeCFKXqCNzVjryuDqPVVdFz98SDqlFzK5jJZv4SoYKLpi1/IBeOOCwa+bfdvwGshZyCNxr2Q==", "dev": true, "requires": { "monocle-ts": "^2.3.11", diff --git a/package.json b/package.json index ea658890..672400e6 100644 --- a/package.json +++ b/package.json @@ -58,7 +58,7 @@ }, "devDependencies": { "@prismicio/mock": "^0.2.0", - "@prismicio/types-internal": "^1.5.3", + "@prismicio/types-internal": "2.0.0-alpha.11", "@size-limit/preset-small-lib": "^8.2.4", "@trivago/prettier-plugin-sort-imports": "^4.1.1", "@typescript-eslint/eslint-plugin": "^5.59.0", diff --git a/test/types/customType-boolean.types.ts b/test/types/customType-boolean.types.ts index ed552804..de1775b2 100644 --- a/test/types/customType-boolean.types.ts +++ b/test/types/customType-boolean.types.ts @@ -1,6 +1,7 @@ -import * as prismicTI from "@prismicio/types-internal"; import { expectNever, expectType } from "ts-expect"; +import * as prismicTICustomTypes from "@prismicio/types-internal/lib/customtypes"; + import * as prismic from "../../src"; (value: prismic.CustomTypeModelBooleanField): true => { @@ -42,12 +43,12 @@ expectType({ * `@prismicio/types` extends `@prismicio/types-internal` */ expectType( - {} as prismicTI.CustomTypes.Widgets.Nestable.BooleanField, + {} as prismicTICustomTypes.BooleanField, ); /** * `@prismicio/types-internal` extends `@prismicio/types` */ -expectType( +expectType( {} as prismic.CustomTypeModelBooleanField, ); diff --git a/test/types/customType-color.types.ts b/test/types/customType-color.types.ts index c4e3d4ce..39a581c5 100644 --- a/test/types/customType-color.types.ts +++ b/test/types/customType-color.types.ts @@ -1,6 +1,7 @@ -import * as prismicTI from "@prismicio/types-internal"; import { expectNever, expectType } from "ts-expect"; +import * as prismicTICustomTypes from "@prismicio/types-internal/lib/customtypes"; + import * as prismic from "../../src"; (value: prismic.CustomTypeModelColorField): true => { @@ -40,13 +41,9 @@ expectType({ /** * `@prismicio/types` extends `@prismicio/types-internal` */ -expectType( - {} as prismicTI.CustomTypes.Widgets.Nestable.Color, -); +expectType({} as prismicTICustomTypes.Color); /** * `@prismicio/types-internal` extends `@prismicio/types` */ -expectType( - {} as prismic.CustomTypeModelColorField, -); +expectType({} as prismic.CustomTypeModelColorField); diff --git a/test/types/customType-contentRelationship.types.ts b/test/types/customType-contentRelationship.types.ts index c9be80c8..bafb2e4b 100644 --- a/test/types/customType-contentRelationship.types.ts +++ b/test/types/customType-contentRelationship.types.ts @@ -1,6 +1,7 @@ -import * as prismicTI from "@prismicio/types-internal"; import { expectNever, expectType } from "ts-expect"; +import * as prismicTICustomTypes from "@prismicio/types-internal/lib/customtypes"; + import * as prismic from "../../src"; (value: prismic.CustomTypeModelContentRelationshipField): true => { @@ -99,7 +100,7 @@ expectType>({ * `@prismicio/types` extends `@prismicio/types-internal` */ expectType( - {} as prismicTI.CustomTypes.Widgets.Nestable.Link & { + {} as prismicTICustomTypes.Link & { // We must manually narrow `@prismicio/types-internal`'s type // to match a Content Relationship field; // `@prismicio/types-internal` does not contain a Content @@ -111,6 +112,6 @@ expectType( /** * `@prismicio/types-internal` extends `@prismicio/types` */ -expectType( +expectType( {} as prismic.CustomTypeModelContentRelationshipField, ); diff --git a/test/types/customType-date.types.ts b/test/types/customType-date.types.ts index ab0121a3..466c4daa 100644 --- a/test/types/customType-date.types.ts +++ b/test/types/customType-date.types.ts @@ -1,6 +1,7 @@ -import * as prismicTI from "@prismicio/types-internal"; import { expectNever, expectType } from "ts-expect"; +import * as prismicTICustomTypes from "@prismicio/types-internal/lib/customtypes"; + import * as prismic from "../../src"; (value: prismic.CustomTypeModelDateField): true => { @@ -40,13 +41,9 @@ expectType({ /** * `@prismicio/types` extends `@prismicio/types-internal` */ -expectType( - {} as prismicTI.CustomTypes.Widgets.Nestable.Date, -); +expectType({} as prismicTICustomTypes.Date); /** * `@prismicio/types-internal` extends `@prismicio/types` */ -expectType( - {} as prismic.CustomTypeModelDateField, -); +expectType({} as prismic.CustomTypeModelDateField); diff --git a/test/types/customType-embed.types.ts b/test/types/customType-embed.types.ts index 38edb232..165033c4 100644 --- a/test/types/customType-embed.types.ts +++ b/test/types/customType-embed.types.ts @@ -1,6 +1,7 @@ -import * as prismicTI from "@prismicio/types-internal"; import { expectNever, expectType } from "ts-expect"; +import * as prismicTICustomTypes from "@prismicio/types-internal/lib/customtypes"; + import * as prismic from "../../src"; (value: prismic.CustomTypeModelEmbedField): true => { @@ -40,13 +41,9 @@ expectType({ /** * `@prismicio/types` extends `@prismicio/types-internal` */ -expectType( - {} as prismicTI.CustomTypes.Widgets.Nestable.Embed, -); +expectType({} as prismicTICustomTypes.Embed); /** * `@prismicio/types-internal` extends `@prismicio/types` */ -expectType( - {} as prismic.CustomTypeModelEmbedField, -); +expectType({} as prismic.CustomTypeModelEmbedField); diff --git a/test/types/customType-geoPoint.types.ts b/test/types/customType-geoPoint.types.ts index 341c9ec4..a5754af5 100644 --- a/test/types/customType-geoPoint.types.ts +++ b/test/types/customType-geoPoint.types.ts @@ -1,6 +1,7 @@ -import * as prismicTI from "@prismicio/types-internal"; import { expectNever, expectType } from "ts-expect"; +import * as prismicTICustomTypes from "@prismicio/types-internal/lib/customtypes"; + import * as prismic from "../../src"; (value: prismic.CustomTypeModelGeoPointField): true => { @@ -42,12 +43,12 @@ expectType({ * `@prismicio/types` extends `@prismicio/types-internal` */ expectType( - {} as prismicTI.CustomTypes.Widgets.Nestable.GeoPoint, + {} as prismicTICustomTypes.GeoPoint, ); /** * `@prismicio/types-internal` extends `@prismicio/types` */ -expectType( +expectType( {} as prismic.CustomTypeModelGeoPointField, ); diff --git a/test/types/customType-group.types.ts b/test/types/customType-group.types.ts index 2f6cf7ce..6880fde5 100644 --- a/test/types/customType-group.types.ts +++ b/test/types/customType-group.types.ts @@ -1,6 +1,7 @@ -import * as prismicTI from "@prismicio/types-internal"; import { expectNever, expectType } from "ts-expect"; +import * as prismicTICustomTypes from "@prismicio/types-internal/lib/customtypes"; + import * as prismic from "../../src"; (value: prismic.CustomTypeModelGroupField): true => { @@ -79,13 +80,9 @@ expectType< /** * `@prismicio/types` extends `@prismicio/types-internal` */ -expectType( - {} as prismicTI.CustomTypes.Widgets.Group, -); +expectType({} as prismicTICustomTypes.Group); /** * `@prismicio/types-internal` extends `@prismicio/types` */ -expectType( - {} as prismic.CustomTypeModelGroupField, -); +expectType({} as prismic.CustomTypeModelGroupField); diff --git a/test/types/customType-image.types.ts b/test/types/customType-image.types.ts index 1f0d9690..c1fe11fd 100644 --- a/test/types/customType-image.types.ts +++ b/test/types/customType-image.types.ts @@ -1,6 +1,7 @@ -import * as prismicTI from "@prismicio/types-internal"; import { expectNever, expectType } from "ts-expect"; +import * as prismicTICustomTypes from "@prismicio/types-internal/lib/customtypes"; + import * as prismic from "../../src"; (value: prismic.CustomTypeModelImageField): true => { @@ -130,13 +131,9 @@ expectType>({ /** * `@prismicio/types` extends `@prismicio/types-internal` */ -expectType( - {} as prismicTI.CustomTypes.Widgets.Nestable.Image, -); +expectType({} as prismicTICustomTypes.Image); /** * `@prismicio/types-internal` extends `@prismicio/types` */ -expectType( - {} as prismic.CustomTypeModelImageField, -); +expectType({} as prismic.CustomTypeModelImageField); diff --git a/test/types/customType-integration.types.ts b/test/types/customType-integration.types.ts index 242e8e95..27c235a9 100644 --- a/test/types/customType-integration.types.ts +++ b/test/types/customType-integration.types.ts @@ -1,6 +1,7 @@ -import * as prismicTI from "@prismicio/types-internal"; import { expectNever, expectType } from "ts-expect"; +import * as prismicTICustomTypes from "@prismicio/types-internal/lib/customtypes"; + import * as prismic from "../../src"; (value: prismic.CustomTypeModelIntegrationField): true => { @@ -43,12 +44,12 @@ expectType({ * `@prismicio/types` extends `@prismicio/types-internal` */ expectType( - {} as prismicTI.CustomTypes.Widgets.Nestable.IntegrationField, + {} as prismicTICustomTypes.IntegrationField, ); /** * `@prismicio/types-internal` extends `@prismicio/types` */ -expectType( +expectType( {} as prismic.CustomTypeModelIntegrationField, ); diff --git a/test/types/customType-keyText.types.ts b/test/types/customType-keyText.types.ts index 63634a4d..3a1e1421 100644 --- a/test/types/customType-keyText.types.ts +++ b/test/types/customType-keyText.types.ts @@ -1,6 +1,7 @@ -import * as prismicTI from "@prismicio/types-internal"; import { expectNever, expectType } from "ts-expect"; +import * as prismicTICustomTypes from "@prismicio/types-internal/lib/customtypes"; + import * as prismic from "../../src"; (value: prismic.CustomTypeModelKeyTextField): true => { @@ -41,12 +42,12 @@ expectType({ * `@prismicio/types` extends `@prismicio/types-internal` */ expectType( - {} as prismicTI.CustomTypes.Widgets.Nestable.Text, + {} as prismicTICustomTypes.Text, ); /** * `@prismicio/types-internal` extends `@prismicio/types` */ -expectType( +expectType( {} as prismic.CustomTypeModelKeyTextField, ); diff --git a/test/types/customType-link.types.ts b/test/types/customType-link.types.ts index ee557b4b..67194c47 100644 --- a/test/types/customType-link.types.ts +++ b/test/types/customType-link.types.ts @@ -1,6 +1,7 @@ -import * as prismicTI from "@prismicio/types-internal"; import { expectNever, expectType } from "ts-expect"; +import * as prismicTICustomTypes from "@prismicio/types-internal/lib/customtypes"; + import * as prismic from "../../src"; (value: prismic.CustomTypeModelLinkField): true => { @@ -62,13 +63,9 @@ expectType({ /** * `@prismicio/types` extends `@prismicio/types-internal` */ -expectType( - {} as prismicTI.CustomTypes.Widgets.Nestable.Link, -); +expectType({} as prismicTICustomTypes.Link); /** * `@prismicio/types-internal` extends `@prismicio/types` */ -expectType( - {} as prismic.CustomTypeModelLinkField, -); +expectType({} as prismic.CustomTypeModelLinkField); diff --git a/test/types/customType-linkToMedia.types.ts b/test/types/customType-linkToMedia.types.ts index 2710b363..8f8681c8 100644 --- a/test/types/customType-linkToMedia.types.ts +++ b/test/types/customType-linkToMedia.types.ts @@ -1,6 +1,7 @@ -import * as prismicTI from "@prismicio/types-internal"; import { expectNever, expectType } from "ts-expect"; +import * as prismicTICustomTypes from "@prismicio/types-internal/lib/customtypes"; + import * as prismic from "../../src"; (value: prismic.CustomTypeModelLinkToMediaField): true => { @@ -43,7 +44,7 @@ expectType({ * `@prismicio/types` extends `@prismicio/types-internal` */ expectType( - {} as prismicTI.CustomTypes.Widgets.Nestable.Link & { + {} as prismicTICustomTypes.Link & { // We must manually narrow `@prismicio/types-internal`'s type // to match a link to media field; `@prismicio/types-internal` // does not contain a link to media-specific type. @@ -54,6 +55,6 @@ expectType( /** * `@prismicio/types-internal` extends `@prismicio/types` */ -expectType( +expectType( {} as prismic.CustomTypeModelLinkToMediaField, ); diff --git a/test/types/customType-number.types.ts b/test/types/customType-number.types.ts index 337ff423..3de89057 100644 --- a/test/types/customType-number.types.ts +++ b/test/types/customType-number.types.ts @@ -1,6 +1,7 @@ -import * as prismicTI from "@prismicio/types-internal"; import { expectNever, expectType } from "ts-expect"; +import * as prismicTICustomTypes from "@prismicio/types-internal/lib/customtypes"; + import * as prismic from "../../src"; (value: prismic.CustomTypeModelNumberField): true => { @@ -41,12 +42,12 @@ expectType({ * `@prismicio/types` extends `@prismicio/types-internal` */ expectType( - {} as prismicTI.CustomTypes.Widgets.Nestable.Number, + {} as prismicTICustomTypes.Number, ); /** * `@prismicio/types-internal` extends `@prismicio/types` */ -expectType( +expectType( {} as prismic.CustomTypeModelNumberField, ); diff --git a/test/types/customType-richText.types.ts b/test/types/customType-richText.types.ts index 3ab2179d..fbd342c3 100644 --- a/test/types/customType-richText.types.ts +++ b/test/types/customType-richText.types.ts @@ -1,6 +1,7 @@ -import * as prismicTI from "@prismicio/types-internal"; import { TypeOf, expectNever, expectType } from "ts-expect"; +import * as prismicTICustomTypes from "@prismicio/types-internal/lib/customtypes"; + import * as prismic from "../../src"; (value: prismic.CustomTypeModelRichTextField): true => { @@ -81,12 +82,12 @@ expectType({ * `@prismicio/types` extends `@prismicio/types-internal` */ expectType( - {} as prismicTI.CustomTypes.Widgets.Nestable.RichText, + {} as prismicTICustomTypes.RichText, ); /** * `@prismicio/types-internal` extends `@prismicio/types` */ -expectType( +expectType( {} as prismic.CustomTypeModelRichTextField, ); diff --git a/test/types/customType-select.types.ts b/test/types/customType-select.types.ts index 56e9f10a..820bba65 100644 --- a/test/types/customType-select.types.ts +++ b/test/types/customType-select.types.ts @@ -1,6 +1,7 @@ -import * as prismicTI from "@prismicio/types-internal"; import { expectNever, expectType } from "ts-expect"; +import * as prismicTICustomTypes from "@prismicio/types-internal/lib/customtypes"; + import * as prismic from "../../src"; (value: prismic.CustomTypeModelSelectField): true => { @@ -108,12 +109,12 @@ expectType>({ * `@prismicio/types` extends `@prismicio/types-internal` */ expectType( - {} as prismicTI.CustomTypes.Widgets.Nestable.Select, + {} as prismicTICustomTypes.Select, ); /** * `@prismicio/types-internal` extends `@prismicio/types` */ -expectType( +expectType( {} as prismic.CustomTypeModelSelectField, ); diff --git a/test/types/customType-sharedSlice.types.ts b/test/types/customType-sharedSlice.types.ts index 9f472ce5..3fdfcced 100644 --- a/test/types/customType-sharedSlice.types.ts +++ b/test/types/customType-sharedSlice.types.ts @@ -1,6 +1,7 @@ -import * as prismicTI from "@prismicio/types-internal"; import { expectNever, expectType } from "ts-expect"; +import * as prismicTICustomTypes from "@prismicio/types-internal/lib/customtypes"; + import * as prismic from "../../src"; (value: prismic.CustomTypeModelSharedSlice): true => { @@ -27,12 +28,12 @@ expectType({ * `@prismicio/types` extends `@prismicio/types-internal` */ expectType( - {} as prismicTI.CustomTypes.Widgets.Slices.SharedSliceRef, + {} as prismicTICustomTypes.SharedSliceRef, ); /** * `@prismicio/types-internal` extends `@prismicio/types` */ -expectType( +expectType( {} as prismic.CustomTypeModelSharedSlice, ); diff --git a/test/types/customType-sharedSliceModel.types.ts b/test/types/customType-sharedSliceModel.types.ts index da4bb7b5..c0b545d8 100644 --- a/test/types/customType-sharedSliceModel.types.ts +++ b/test/types/customType-sharedSliceModel.types.ts @@ -1,6 +1,7 @@ -import * as prismicTI from "@prismicio/types-internal"; import { expectNever, expectType } from "ts-expect"; +import * as prismicTICustomTypes from "@prismicio/types-internal/lib/customtypes"; + import * as prismic from "../../src"; (value: prismic.SharedSliceModel): true => { @@ -109,13 +110,9 @@ expectType< /** * `@prismicio/types` extends `@prismicio/types-internal` */ -expectType( - {} as prismicTI.CustomTypes.Widgets.Slices.SharedSlice, -); +expectType({} as prismicTICustomTypes.SharedSlice); /** * `@prismicio/types-internal` extends `@prismicio/types` */ -expectType( - {} as prismic.SharedSliceModel, -); +expectType({} as prismic.SharedSliceModel); diff --git a/test/types/customType-sharedSliceModelVariation.types.ts b/test/types/customType-sharedSliceModelVariation.types.ts index a0abf923..0fa3c00f 100644 --- a/test/types/customType-sharedSliceModelVariation.types.ts +++ b/test/types/customType-sharedSliceModelVariation.types.ts @@ -1,6 +1,7 @@ -import * as prismicTI from "@prismicio/types-internal"; import { expectNever, expectType } from "ts-expect"; +import * as prismicTICustomTypes from "@prismicio/types-internal/lib/customtypes"; + import * as prismic from "../../src"; (value: prismic.SharedSliceModelVariation): true => { @@ -140,12 +141,12 @@ expectType< * `@prismicio/types` extends `@prismicio/types-internal` */ expectType( - {} as prismicTI.CustomTypes.Widgets.Slices.Variation, + {} as prismicTICustomTypes.Variation, ); /** * `@prismicio/types-internal` extends `@prismicio/types` */ -expectType( +expectType( {} as prismic.SharedSliceModelVariation, ); diff --git a/test/types/customType-slice.types.ts b/test/types/customType-slice.types.ts index 243a335f..dd1be3cf 100644 --- a/test/types/customType-slice.types.ts +++ b/test/types/customType-slice.types.ts @@ -1,6 +1,7 @@ -import * as prismicTI from "@prismicio/types-internal"; import { expectNever, expectType } from "ts-expect"; +import * as prismicTICustomTypes from "@prismicio/types-internal/lib/customtypes"; + import * as prismic from "../../src"; (value: prismic.CustomTypeModelSlice): true => { @@ -108,12 +109,12 @@ expectType< * `@prismicio/types` extends `@prismicio/types-internal` */ expectType( - {} as prismicTI.CustomTypes.Widgets.Slices.CompositeSlice, + {} as prismicTICustomTypes.CompositeSlice, ); /** * `@prismicio/types-internal` extends `@prismicio/types` */ -expectType( +expectType( {} as prismic.CustomTypeModelSlice, ); diff --git a/test/types/customType-sliceZone.types.ts b/test/types/customType-sliceZone.types.ts index 74f06242..610c46e0 100644 --- a/test/types/customType-sliceZone.types.ts +++ b/test/types/customType-sliceZone.types.ts @@ -1,6 +1,7 @@ -import * as prismicTI from "@prismicio/types-internal"; import { expectNever, expectType } from "ts-expect"; +import * as prismicTICustomTypes from "@prismicio/types-internal/lib/customtypes"; + import * as prismic from "../../src"; (value: prismic.CustomTypeModelSliceZoneField): true => { @@ -93,12 +94,12 @@ expectType< * `@prismicio/types` extends `@prismicio/types-internal` */ expectType( - {} as prismicTI.CustomTypes.Widgets.Slices.SliceZone.DynamicSlices, + {} as prismicTICustomTypes.DynamicSlices, ); /** * `@prismicio/types-internal` extends `@prismicio/types` */ -expectType( +expectType( {} as prismic.CustomTypeModelSliceZoneField, ); diff --git a/test/types/customType-timestamp.types.ts b/test/types/customType-timestamp.types.ts index 69d2fd56..18f79f08 100644 --- a/test/types/customType-timestamp.types.ts +++ b/test/types/customType-timestamp.types.ts @@ -1,6 +1,7 @@ -import * as prismicTI from "@prismicio/types-internal"; import { expectNever, expectType } from "ts-expect"; +import * as prismicTICustomTypes from "@prismicio/types-internal/lib/customtypes"; + import * as prismic from "../../src"; (value: prismic.CustomTypeModelTimestampField): true => { @@ -41,12 +42,12 @@ expectType({ * `@prismicio/types` extends `@prismicio/types-internal` */ expectType( - {} as prismicTI.CustomTypes.Widgets.Nestable.Timestamp, + {} as prismicTICustomTypes.Timestamp, ); /** * `@prismicio/types-internal` extends `@prismicio/types` */ -expectType( +expectType( {} as prismic.CustomTypeModelTimestampField, ); diff --git a/test/types/customType-title.types.ts b/test/types/customType-title.types.ts index 417fd9eb..ce98ae79 100644 --- a/test/types/customType-title.types.ts +++ b/test/types/customType-title.types.ts @@ -1,6 +1,7 @@ -import * as prismicTI from "@prismicio/types-internal"; import { expectNever, expectType } from "ts-expect"; +import * as prismicTICustomTypes from "@prismicio/types-internal/lib/customtypes"; + import * as prismic from "../../src"; (value: prismic.CustomTypeModelTitleField): true => { @@ -43,12 +44,12 @@ expectType({ * `@prismicio/types` extends `@prismicio/types-internal` */ expectType( - {} as prismicTI.CustomTypes.Widgets.Nestable.RichText, + {} as prismicTICustomTypes.RichText, ); /** * `@prismicio/types-internal` extends `@prismicio/types` */ -expectType( +expectType( {} as prismic.CustomTypeModelTitleField, ); diff --git a/test/types/customType-uid.types.ts b/test/types/customType-uid.types.ts index 5f3ade46..f9b5d27c 100644 --- a/test/types/customType-uid.types.ts +++ b/test/types/customType-uid.types.ts @@ -1,6 +1,7 @@ -import * as prismicTI from "@prismicio/types-internal"; import { expectNever, expectType } from "ts-expect"; +import * as prismicTICustomTypes from "@prismicio/types-internal/lib/customtypes"; + import * as prismic from "../../src"; (value: prismic.CustomTypeModelUIDField): true => { @@ -40,13 +41,9 @@ expectType({ /** * `@prismicio/types` extends `@prismicio/types-internal` */ -expectType( - {} as prismicTI.CustomTypes.Widgets.UID, -); +expectType({} as prismicTICustomTypes.UID); /** * `@prismicio/types-internal` extends `@prismicio/types` */ -expectType( - {} as prismic.CustomTypeModelUIDField, -); +expectType({} as prismic.CustomTypeModelUIDField); diff --git a/test/types/customType.types.ts b/test/types/customType.types.ts index 2a513c00..eafa8371 100644 --- a/test/types/customType.types.ts +++ b/test/types/customType.types.ts @@ -1,6 +1,7 @@ -import * as prismicTI from "@prismicio/types-internal"; import { TypeOf, expectNever, expectType } from "ts-expect"; +import * as prismicTICustomTypes from "@prismicio/types-internal/lib/customtypes"; + import * as prismic from "../../src"; /** @@ -323,9 +324,9 @@ expectType< /** * `@prismicio/types` extends `@prismicio/types-internal` */ -expectType({} as prismicTI.CustomTypes.CustomType); +expectType({} as prismicTICustomTypes.CustomType); /** * `@prismicio/types-internal` extends `@prismicio/types` */ -expectType({} as prismic.CustomTypeModel); +expectType({} as prismic.CustomTypeModel);