silverstripe-framework/thirdparty/html5lib/HTML5
Hamish Friedlander 2335c074b3 NEW Make shortcode parser more clever about placement
Shortcodes have traditionally had a problem that they are inside <p> tags,
but generate block level elements. This breaks HTML compliance.

This makes the shortcode parser now mutate the DOM based on the "class" attribute on
the shortcode to insert the generated block level element at the right place in the DOM

 - for "left" and "right" elements it puts them just before the block level
   element they are inside

 - for "leftAlone" and "center" elements it splits the DOM around the shortcode.

The trade off is that shortcodes are no longer "text level" features. They need
knowledge of the HTML they are in to perform this transformation, so they can
only be used in (valid) HTML
2013-02-18 10:49:52 +13:00
..
Data.php NEW Make shortcode parser more clever about placement 2013-02-18 10:49:52 +13:00
InputStream.php NEW Make shortcode parser more clever about placement 2013-02-18 10:49:52 +13:00
named-character-references.ser NEW Make shortcode parser more clever about placement 2013-02-18 10:49:52 +13:00
Parser.php NEW Make shortcode parser more clever about placement 2013-02-18 10:49:52 +13:00
Tokenizer.php NEW Make shortcode parser more clever about placement 2013-02-18 10:49:52 +13:00
TreeBuilder.php NEW Make shortcode parser more clever about placement 2013-02-18 10:49:52 +13:00