From 133e97d5bcd48b05b194164d86f1042a5d4d2a4a Mon Sep 17 00:00:00 2001 From: Logan Anderson <43075109+logan-anderson@users.noreply.github.com> Date: Thu, 10 Aug 2023 13:55:43 -0400 Subject: [PATCH] Fix before submit types (#4133) * update types for better use of before submit function * update frontent values * add changset --- .changeset/gentle-doors-cry.md | 6 ++++++ .../@tinacms/schema-tools/src/types/index.ts | 3 +-- .../tinacms/src/auth/TinaCloudProvider.tsx | 6 ++++-- .../tinacms/src/hooks/use-content-creator.tsx | 12 +++++++++++- packages/tinacms/src/index.ts | 1 + packages/tinacms/src/internalClient/index.ts | 6 ++++-- .../toolkit/components/media/media-manager.tsx | 4 ++-- .../src/toolkit/form-builder/form-builder.tsx | 18 ++++++++++++------ .../branch-switcher-legacy.tsx | 1 + .../plugin-branch-switcher/branch-switcher.tsx | 1 + .../toolkit/plugin-branch-switcher/types.ts | 2 +- packages/tinacms/src/toolkit/tina-cms.ts | 3 +++ 12 files changed, 47 insertions(+), 16 deletions(-) create mode 100644 .changeset/gentle-doors-cry.md diff --git a/.changeset/gentle-doors-cry.md b/.changeset/gentle-doors-cry.md new file mode 100644 index 0000000000..806a3c5947 --- /dev/null +++ b/.changeset/gentle-doors-cry.md @@ -0,0 +1,6 @@ +--- +'@tinacms/schema-tools': patch +'tinacms': patch +--- + +Update the before submit types to not pass the finalForm form since it is contained in the TinaForm diff --git a/packages/@tinacms/schema-tools/src/types/index.ts b/packages/@tinacms/schema-tools/src/types/index.ts index 329d65048c..640d2ab98d 100644 --- a/packages/@tinacms/schema-tools/src/types/index.ts +++ b/packages/@tinacms/schema-tools/src/types/index.ts @@ -820,8 +820,7 @@ export interface UICollection