Changelog
All notable changes made in 0.19.x
releases are shown below. See the full list of releases for the complete changelog.
0.19.3 - 2019-06-18
Fixed
- Fixed bug where elements with content of
"0"
wouldn’t be rendered (#376)
0.19.2 - 2019-05-19
Fixed
- Fixed bug where default values for nested configuration paths were inadvertently cast to strings
0.19.1 - 2019-04-11
0.19.1 is an immediate follow-up to 0.19.0 which fixes issues with extensions that register other extensions.
(While this technically introduces a BC-break, it’s allowed under SemVer’s rules for 0.x releases and is necessary for 0.19.x code to work as expected.)
Added
- Added the missing
addExtension()
method to the newConfigurableEnvironmentInterface
Fixed
- Fixed extensions not being able to register other extensions
0.19.0 - 2019-04-11
The 50th release of league/commonmark
is here! :tada:
The Environment
and extension framework underwent some major changes in this release. Be sure to read the upgrade notes if you maintain any community extensions or have written custom functionality on top of this library.
Added
- The priority of parsers, processors, and renderers can now be set when
add()
ing them; you no longer need to rely on the order in which they are added - Added support for trying multiple parsers per block/inline
- Extracted two new base interfaces from
Environment
:EnvironmentInterface
ConfigurableEnvironmentInterface
- Extracted a new
AbstractStringContainerBlock
base class and correspondingStringContainerInterface
fromAbstractBlock
- Added
Cursor::getEncoding()
method - Added
.phpstorm.meta.php
file for better IDE code completion - Made some minor optimizations here and there
Changed
- Pretty much everything now has parameter and return types (#346)
- Attributes passed to
HtmlElement
will now be escaped by default Environment
is now afinal
classEnvironment::getBlockRendererForClass()
was replaced withEnvironment::getBlockRenderersForClass()
(note the addeds
)Environment::getInlineRendererForClass()
was replaced withEnvironment::getInlineRenderersForClass()
(note the addeds
)- The
Environment::get____()
methods now return an iterator instead of an array Context::addBlock()
no longer returns the same block instance you passed into the method, as this served no useful purposeRegexHelper::isEscapable()
no longer acceptsnull
valuesNode::replaceChildren()
now accepts any type ofiterable
, not justarray
s- Some block elements now extend
AbstractStringContainerBlock
instead ofAbstractBlock
InlineContainerInterface
now extends the newStringContainerInterface
- The
handleRemainingContents()
method (formerly onAbstractBlock
, now onAbstractStringContainerBlock
) is now an `abstract method - The
InlineParserContext
constructor now requires anAbstractStringContainerBlock
instead of anAbstractBlock
Removed
- Removed support for PHP 5.6 and 7.0 (#346)
- Removed support for
add()
ing parsers with just the target block/inline class name - you need to include the full namespace now - Removed the following unused methods from
Environment
:getInlineParser($name)
getInlineParsers()
createInlineParserEngine()
- Removed the unused
getName()
methods:AbstractBlockParser::getName()
AbstractInlineParser::getName()
BlockParserInterface::getName()
InlinerParserInterface::getName()
- Removed the now-useless classes:
AbstractBlockParser
AbstractInlinerParser
InlineContainer
- Removed the
AbstractBlock::acceptsLines()
method - Removed the now-useless constructor from
AbstractBlock
- Removed previously-deprecated functionality:
InlineContainer
classRegexHelper::$instance
RegexHelper::getInstance()
RegexHelper::getPartialRegex()
RegexHelper::getHtmlTagRegex()
RegexHelper::getLinkTitleRegex()
RegexHelper::getLinkDestinationBracesRegex()
RegexHelper::getThematicBreakRegex()
- Removed the second
$preserveEntities
parameter fromXml:escape()
Older Versions
See the full list of releases for the complete changelog.