Skip to content

Commit 960bb6e

Browse files
Level needs to be save block attributes or parse will fail. (#9741)
1 parent 9e56083 commit 960bb6e

1 file changed

Lines changed: 1 addition & 1 deletion

File tree

packages/block-library/src/heading/edit.native.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -48,7 +48,7 @@ class HeadingEdit extends Component {
4848
} }
4949
onChange={ ( event ) => {
5050
// Create a React Tree from the new HTML
51-
const newParaBlock = parse( `<!-- wp:heading --><${ tagName }>${ event.content }</${ tagName }><!-- /wp:heading -->` )[ 0 ];
51+
const newParaBlock = parse( `<!-- wp:heading {"level":${ level }} --><${ tagName }>${ event.content }</${ tagName }><!-- /wp:heading -->` )[ 0 ];
5252
setAttributes( {
5353
...this.props.attributes,
5454
content: newParaBlock.attributes.content,

0 commit comments

Comments
 (0)