Skip to content

Commit

Permalink
Replace blocks after editing
Browse files Browse the repository at this point in the history
  • Loading branch information
kevin940726 committed Feb 2, 2023
1 parent fbf75eb commit d056cc6
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion packages/block-library/src/pattern/edit.js
Original file line number Diff line number Diff line change
Expand Up @@ -69,7 +69,9 @@ const PatternEdit = ( { attributes, clientId, setAttributes } ) => {
const innerBlockProps = useInnerBlocksProps( blockProps, {
templateLock: attributes.templateLock,
onInput: () => {},
onChange: () => {},
onChange: ( blocks ) => {
replaceBlocks( clientId, blocks );
},
value: selectedPattern?.blocks ?? [],
} );

Expand Down

0 comments on commit d056cc6

Please sign in to comment.