Skip to content

Commit eef62cb

Browse files
Set lockEditing to false in pattern overrides
1 parent 0807544 commit eef62cb

File tree

3 files changed

+14
-1
lines changed

3 files changed

+14
-1
lines changed

packages/block-editor/src/hooks/use-bindings-attributes.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -47,7 +47,7 @@ const createEditFunctionWithBindingsAttribute = () =>
4747
settings.source
4848
);
4949

50-
if ( source ) {
50+
if ( source && source.useSource ) {
5151
// Second argument (`updateMetaValue`) will be used to update the value in the future.
5252
const {
5353
placeholder,

packages/editor/src/bindings/index.js

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,9 @@ import { dispatch } from '@wordpress/data';
77
* Internal dependencies
88
*/
99
import { unlock } from '../lock-unlock';
10+
import patternOverrides from './pattern-overrides';
1011
import postMeta from './post-meta';
1112

1213
const { registerBlockBindingsSource } = unlock( dispatch( blockEditorStore ) );
14+
registerBlockBindingsSource( patternOverrides );
1315
registerBlockBindingsSource( postMeta );
Lines changed: 11 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,11 @@
1+
/**
2+
* WordPress dependencies
3+
*/
4+
import { __ } from '@wordpress/i18n';
5+
6+
export default {
7+
name: 'core/pattern-overrides',
8+
label: __( 'Pattern Overrides' ),
9+
useSource: null,
10+
lockAttributesEditing: false,
11+
};

0 commit comments

Comments
 (0)