From e6aaab1f414e535a66b7d1679be82ef210d750b9 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Lorenz=20Wei=C3=9F?= <34910067+loweisz@users.noreply.github.com> Date: Tue, 12 Jul 2022 09:51:08 +0200 Subject: [PATCH] feat: [] add option to entry publish method (#1306) --- lib/entry.ts | 4 ++-- lib/types/entry.types.ts | 2 +- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/lib/entry.ts b/lib/entry.ts index 09bb2d16b1..eeda887d80 100644 --- a/lib/entry.ts +++ b/lib/entry.ts @@ -43,8 +43,8 @@ export default function createEntry( getSys() { return sys }, - publish() { - return channel.call('callEntryMethod', 'publish') + publish(options?: { skipUiValidation?: boolean }) { + return channel.call('callEntryMethod', 'publish', [options]) }, unpublish() { return channel.call('callEntryMethod', 'unpublish') diff --git a/lib/types/entry.types.ts b/lib/types/entry.types.ts index 438ff908dc..4bebd4c329 100644 --- a/lib/types/entry.types.ts +++ b/lib/types/entry.types.ts @@ -29,7 +29,7 @@ export interface EntryAPI extends TaskAPI { /** Returns sys for an entry. */ getSys: () => ContentEntitySys /** Publish the entry */ - publish: () => Promise + publish: (options?: { skipUiValidation?: boolean }) => Promise /** Unpublish the entry */ unpublish: () => Promise /** Saves the current changes of the entry */