From 40fe45ccd8550cf9f7d9d29b6919ed2c447e8a1f Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Bj=C3=B8rge=20N=C3=A6ss?= Date: Thu, 31 Aug 2017 16:16:07 +0200 Subject: [PATCH] [desk-tool] Adjust FormBuilder to use patchChannel --- packages/@sanity/desk-tool/src/pane/Editor.js | 5 ++++- packages/@sanity/desk-tool/src/pane/EditorWrapper.js | 4 +++- .../@sanity/form-builder/src/sanity/SanityFormBuilder.js | 3 ++- 3 files changed, 9 insertions(+), 3 deletions(-) diff --git a/packages/@sanity/desk-tool/src/pane/Editor.js b/packages/@sanity/desk-tool/src/pane/Editor.js index f2ea22d09e4..afd55dfb1e7 100644 --- a/packages/@sanity/desk-tool/src/pane/Editor.js +++ b/packages/@sanity/desk-tool/src/pane/Editor.js @@ -117,6 +117,7 @@ function getToggleKeyState(event) { export default withRouterHOC(class Editor extends React.PureComponent { static propTypes = { + patchChannel: PropTypes.object, draft: PropTypes.object, published: PropTypes.object, type: PropTypes.object.isRequired, @@ -337,7 +338,8 @@ export default withRouterHOC(class Editor extends React.PureComponent { isLoading, isPublishing, isUnpublishing, - isCreatingDraft + isCreatingDraft, + patchChannel } = this.props const { @@ -411,6 +413,7 @@ export default withRouterHOC(class Editor extends React.PureComponent {
) - } +SanityFormBuilder.createPatchChannel = FormBuilder.createPatchChannel + export {inputResolver, defaultConfig}