Skip to content

Commit

Permalink
Merge pull request pristas-peter#208 from superhuit-agency/fix-core-h…
Browse files Browse the repository at this point in the history
…tml-content-attr

fix: 🐛 core/html missing content attribute
  • Loading branch information
pristas-peter authored Aug 22, 2024
2 parents 8d4f6f3 + 251b531 commit 4dd439c
Showing 1 changed file with 4 additions and 0 deletions.
4 changes: 4 additions & 0 deletions src/Blocks/Block.php
Original file line number Diff line number Diff line change
Expand Up @@ -68,6 +68,10 @@ protected static function source_attributes( $node, $type ) {

break;
case 'html':
// core/html source was converted from html to raw which was introduced in WP 6.2
// https://github.com/WordPress/gutenberg/pull/27268
// https://github.com/WordPress/gutenberg/commit/97eb4a4db1b0f42ca77a1eff335b632584d11226#diff-2ca7aa3d7aa1e1b7045012c90de56f0caf6b1f4a0ac1bd501b0fb3c0c054aa2eR13
case 'raw':
$source_node = ! empty( $value['selector'] ) ? $node->findOne( $value['selector'] ) : $node;

if ( $source_node ) {
Expand Down

0 comments on commit 4dd439c

Please sign in to comment.