From 262e3bbee25d7215101db13877fed91d8ac59982 Mon Sep 17 00:00:00 2001 From: James Date: Mon, 4 Mar 2024 12:25:38 -0500 Subject: [PATCH] chore: types update --- app/(payload)/api/[...slug]/route.ts | 2 +- app/my-route/route.ts | 7 +------ .../src/field/features/blocks/component/BlockContent.tsx | 3 ++- .../src/field/features/blocks/component/FormSavePlugin.tsx | 2 +- .../src/field/features/link/drawer/types.ts | 2 +- .../link/plugins/floatingLinkEditor/LinkEditor/index.tsx | 2 +- .../src/field/elements/link/Button/index.tsx | 2 +- .../src/field/elements/link/Element/index.tsx | 2 +- .../src/field/elements/link/LinkDrawer/types.ts | 3 ++- 9 files changed, 11 insertions(+), 14 deletions(-) diff --git a/app/(payload)/api/[...slug]/route.ts b/app/(payload)/api/[...slug]/route.ts index a131881fe..282e1ad32 100644 --- a/app/(payload)/api/[...slug]/route.ts +++ b/app/(payload)/api/[...slug]/route.ts @@ -1,7 +1,7 @@ /* THIS FILE WAS GENERATED AUTOMATICALLY BY PAYLOAD. */ /* DO NOT MODIFY it because it could be re-written at any time. */ import config from '@payload-config' -import { REST_GET, REST_DELETE, REST_PATCH, REST_POST } from '@payloadcms/next/routes' +import { REST_DELETE, REST_GET, REST_PATCH, REST_POST } from '@payloadcms/next/routes' export const GET = REST_GET(config) export const POST = REST_POST(config) diff --git a/app/my-route/route.ts b/app/my-route/route.ts index 445f1db00..6a705ad24 100644 --- a/app/my-route/route.ts +++ b/app/my-route/route.ts @@ -1,9 +1,4 @@ -export const GET = async () => { - console.log('1') - console.log('1') - console.log('1') - console.log('1') - console.log('1') +export const GET = () => { return Response.json({ hello: 'elliot', }) diff --git a/packages/richtext-lexical/src/field/features/blocks/component/BlockContent.tsx b/packages/richtext-lexical/src/field/features/blocks/component/BlockContent.tsx index 552292424..0a1e96a99 100644 --- a/packages/richtext-lexical/src/field/features/blocks/component/BlockContent.tsx +++ b/packages/richtext-lexical/src/field/features/blocks/component/BlockContent.tsx @@ -1,6 +1,7 @@ import type { SanitizedClientEditorConfig } from '@payloadcms/richtext-lexical' -import type { FieldMap, FormFieldBase, FormState } from '@payloadcms/ui' +import type { FieldMap, FormFieldBase } from '@payloadcms/ui' import type { ReducedBlock } from '@payloadcms/ui/types' +import type { FormState } from 'payload/types' import type { Data } from 'payload/types' import { useLexicalComposerContext } from '@lexical/react/LexicalComposerContext' diff --git a/packages/richtext-lexical/src/field/features/blocks/component/FormSavePlugin.tsx b/packages/richtext-lexical/src/field/features/blocks/component/FormSavePlugin.tsx index 7e6b5f02d..a4793aa7b 100644 --- a/packages/richtext-lexical/src/field/features/blocks/component/FormSavePlugin.tsx +++ b/packages/richtext-lexical/src/field/features/blocks/component/FormSavePlugin.tsx @@ -1,4 +1,4 @@ -import type { FormState } from '@payloadcms/ui' +import type { FormState } from 'payload/types' import type { Data } from 'payload/types' import type React from 'react' diff --git a/packages/richtext-lexical/src/field/features/link/drawer/types.ts b/packages/richtext-lexical/src/field/features/link/drawer/types.ts index 186f113c7..5060ffe7f 100644 --- a/packages/richtext-lexical/src/field/features/link/drawer/types.ts +++ b/packages/richtext-lexical/src/field/features/link/drawer/types.ts @@ -1,4 +1,4 @@ -import type { FormState } from '@payloadcms/ui' +import type { FormState } from 'payload/types' import type { LinkPayload } from '../plugins/floatingLinkEditor/types' diff --git a/packages/richtext-lexical/src/field/features/link/plugins/floatingLinkEditor/LinkEditor/index.tsx b/packages/richtext-lexical/src/field/features/link/plugins/floatingLinkEditor/LinkEditor/index.tsx index 001e7808f..2b7fcad45 100644 --- a/packages/richtext-lexical/src/field/features/link/plugins/floatingLinkEditor/LinkEditor/index.tsx +++ b/packages/richtext-lexical/src/field/features/link/plugins/floatingLinkEditor/LinkEditor/index.tsx @@ -1,5 +1,5 @@ 'use client' -import type { FormState } from '@payloadcms/ui' +import type { FormState } from 'payload/types' import type { Data } from 'payload/types' import { useModal } from '@faceless-ui/modal' diff --git a/packages/richtext-slate/src/field/elements/link/Button/index.tsx b/packages/richtext-slate/src/field/elements/link/Button/index.tsx index 43ec3593f..99c947bea 100644 --- a/packages/richtext-slate/src/field/elements/link/Button/index.tsx +++ b/packages/richtext-slate/src/field/elements/link/Button/index.tsx @@ -1,6 +1,6 @@ 'use client' -import type { FormState } from '@payloadcms/ui' +import type { FormState } from 'payload/types' import { useModal } from '@faceless-ui/modal' import { diff --git a/packages/richtext-slate/src/field/elements/link/Element/index.tsx b/packages/richtext-slate/src/field/elements/link/Element/index.tsx index 04e9144ea..51002deb3 100644 --- a/packages/richtext-slate/src/field/elements/link/Element/index.tsx +++ b/packages/richtext-slate/src/field/elements/link/Element/index.tsx @@ -1,6 +1,6 @@ 'use client' -import type { FormState } from '@payloadcms/ui' +import type { FormState } from 'payload/types' import { useModal } from '@faceless-ui/modal' import { getTranslation } from '@payloadcms/translations' diff --git a/packages/richtext-slate/src/field/elements/link/LinkDrawer/types.ts b/packages/richtext-slate/src/field/elements/link/LinkDrawer/types.ts index f0e8e08df..bd3ac6e14 100644 --- a/packages/richtext-slate/src/field/elements/link/LinkDrawer/types.ts +++ b/packages/richtext-slate/src/field/elements/link/LinkDrawer/types.ts @@ -1,4 +1,5 @@ -import type { FieldMap, FormState } from '@payloadcms/ui' +import type { FieldMap } from '@payloadcms/ui' +import type { FormState } from 'payload/types' export type Props = { drawerSlug: string