-
Notifications
You must be signed in to change notification settings - Fork 4.4k
/
Copy pathindex.js
32 lines (30 loc) · 956 Bytes
/
index.js
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
/**
* WordPress dependencies
*/
import { BlockInspector } from '@wordpress/block-editor';
import { privateApis as editPatternsPrivateApis } from '@wordpress/patterns';
/**
* Internal dependencies
*/
import TemplatePartConverter from '../template-part-converter';
import { SidebarInspectorFill } from '../sidebar-edit-mode';
import SiteEditorCanvas from './site-editor-canvas';
import BlockEditorProvider from './block-editor-provider';
import { unlock } from '../../lock-unlock';
const { PatternsMenuItems } = unlock( editPatternsPrivateApis );
export default function BlockEditor( { postType, postId, context } ) {
return (
<BlockEditorProvider postType={ postType } postId={ postId }>
<TemplatePartConverter />
<SidebarInspectorFill>
<BlockInspector />
</SidebarInspectorFill>
<SiteEditorCanvas
postType={ postType }
postId={ postId }
context={ context }
/>
<PatternsMenuItems />
</BlockEditorProvider>
);
}