WordPress.org

Make WordPress Core


Ignore:
Timestamp:
10/18/2018 11:53:49 AM (2 years ago)
Author:
pento
Message:

Blocks: Parse blocks when displaying posts.

Posts containing blocks are now correctly handled when displaying on the front end, including dynamic blocks and nested blocks.

See #45109.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • branches/5.0/tests/phpunit/data/blocks/fixtures/core__column.parsed.json

    r43751 r43752  
    44        "attrs": {},
    55        "innerBlocks": [
     6            {
     7                "blockName": null,
     8                "attrs": {},
     9                "innerBlocks": [],
     10                "innerHTML": "\n<div class=\"wp-block-column\">\n\t"
     11            },
    612            {
    713                "blockName": "core/paragraph",
     
    1016                "innerHTML": "\n\t<p>Column One, Paragraph One</p>\n\t"
    1117            },
     18            {
     19                "blockName": null,
     20                "attrs": {},
     21                "innerBlocks": [],
     22                "innerHTML": "\n\t"
     23            },
    1224            {
    1325                "blockName": "core/paragraph",
     
    1527                "innerBlocks": [],
    1628                "innerHTML": "\n\t<p>Column One, Paragraph Two</p>\n\t"
    17             }
    18         ],
    19         "innerHTML": "\n<div class=\"wp-block-column\">\n\t\n\t\n</div>\n"
     29            },
     30            {
     31                "blockName": null,
     32                "attrs": {},
     33                "innerBlocks": [],
     34                "innerHTML": "\n</div>\n"
     35            }
     36        ],
     37        "innerHTML": ""
    2038    },
    2139    {
Note: See TracChangeset for help on using the changeset viewer.