You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

842 lines
33 KiB

3 years ago
  1. # Change Log
  2. All notable changes to this project will be documented in this file.
  3. Updates should follow the [Keep a CHANGELOG](https://keepachangelog.com/) principles.
  4. ## [0.19.3] - 2019-06-18
  5. ### Fixed
  6. - Fixed bug where elements with content of `"0"` wouldn't be rendered (#376)
  7. ## [0.19.2] - 2019-05-19
  8. ### Fixed
  9. - Fixed bug where default values for nested configuration paths were inadvertently cast to strings
  10. ## [0.19.1] - 2019-04-10
  11. ### Added
  12. - Added the missing `addExtension()` method to the new `ConfigurableEnvironmentInterface`
  13. ### Fixed
  14. - Fixed extensions not being able to register other extensions
  15. ## [0.19.0] - 2019-04-10
  16. ### Added
  17. - 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
  18. - Added support for trying multiple parsers per block/inline
  19. - Extracted two new base interfaces from `Environment`:
  20. - `EnvironmentInterface`
  21. - `ConfigurableEnvironmentInterface`
  22. - Extracted a new `AbstractStringContainerBlock` base class and corresponding `StringContainerInterface` from `AbstractBlock`
  23. - Added `Cursor::getEncoding()` method
  24. - Added `.phpstorm.meta.php` file for better IDE code completion
  25. - Made some minor optimizations here and there
  26. ### Changed
  27. - Pretty much everything now has parameter and return types (#346)
  28. - Attributes passed to `HtmlElement` will now be escaped by default
  29. - `Environment` is now a `final` class
  30. - `Environment::getBlockRendererForClass()` was replaced with `Environment::getBlockRenderersForClass()` (note the added `s`)
  31. - `Environment::getInlineRendererForClass()` was replaced with `Environment::getInlineRenderersForClass()` (note the added `s`)
  32. - The `Environment::get____()` methods now return an iterator instead of an array
  33. - `Context::addBlock()` no longer returns the same block instance you passed into the method, as this served no useful purpose
  34. - `RegexHelper::isEscapable()` no longer accepts `null` values
  35. - `Node::replaceChildren()` now accepts any type of `iterable`, not just `array`s
  36. - Some block elements now extend `AbstractStringContainerBlock` instead of `AbstractBlock`
  37. - `InlineContainerInterface` now extends the new `StringContainerInterface`
  38. - The `handleRemainingContents()` method (formerly on `AbstractBlock`, now on `AbstractStringContainerBlock`) is now an `abstract method
  39. - The `InlineParserContext` constructor now requires an `AbstractStringContainerBlock` instead of an `AbstractBlock`
  40. ### Removed
  41. - Removed support for PHP 5.6 and 7.0 (#346)
  42. - Removed support for `add()`ing parsers with just the target block/inline class name - you need to include the full namespace now
  43. - Removed the following unused methods from `Environment`:
  44. - `getInlineParser($name)`
  45. - `getInlineParsers()`
  46. - `createInlineParserEngine()`
  47. - Removed the unused `getName()` methods:
  48. - `AbstractBlockParser::getName()`
  49. - `AbstractInlineParser::getName()`
  50. - `BlockParserInterface::getName()`
  51. - `InlinerParserInterface::getName()`
  52. - Removed the now-useless classes:
  53. - `AbstractBlockParser`
  54. - `AbstractInlinerParser`
  55. - `InlineContainer`
  56. - Removed the `AbstractBlock::acceptsLines()` method
  57. - Removed the now-useless constructor from `AbstractBlock`
  58. - Removed previously-deprecated functionality:
  59. - `InlineContainer` class
  60. - `RegexHelper::$instance`
  61. - `RegexHelper::getInstance()`
  62. - `RegexHelper::getPartialRegex()`
  63. - `RegexHelper::getHtmlTagRegex()`
  64. - `RegexHelper::getLinkTitleRegex()`
  65. - `RegexHelper::getLinkDestinationBracesRegex()`
  66. - `RegexHelper::getThematicBreakRegex()`
  67. - Removed the second `$preserveEntities` parameter from `Xml:escape()`
  68. ## [0.18.5] - 2019-03-28
  69. ### Fixed
  70. - Fixed the adjoining `Text` collapser not handling the full tree (thephpleague/commonmark-ext-autolink#10)
  71. ## [0.18.4] - 2019-03-23
  72. ### Changed
  73. - Modified how URL normalization decodes certain characters in order to align with the JS library's output
  74. - Disallowed unescaped `(` in parenthesized link title
  75. ### Fixed
  76. - Fixed two exponential backtracking issues
  77. ## [0.18.3] - 2019-03-21
  78. This is a **security update** release.
  79. ### Changed
  80. - XML/HTML entities in attributes will no longer be preserved when rendering (#353)
  81. ### Fixed
  82. - Fix XSS vulnerability caused by improper preservation of entities when rendering (#353)
  83. ### Deprecated
  84. - Deprecated the `$preserveEntites` argument of `Xml::escape()` for removal in the next release (#353)
  85. ## [0.18.2] - 2019-03-16
  86. ### Fixed
  87. - Fixed adjoining `Text` elements not being collapsed after delimiter processing
  88. ### Deprecated
  89. - Deprecated the `CommonmarkConverter::VERSION` constant for removal in 1.0.0
  90. ## [0.18.1] - 2018-12-29
  91. This is a **security update** release.
  92. ### Fixed
  93. - Fix XSS vulnerability caused by URL normalization not handling/encoding newlines properly (#337, CVE-2018-20583)
  94. ## [0.18.0] - 2018-09-18
  95. ### Added
  96. - Added `ConverterInterface` to `Converter` and `CommonMarkConverter` (#330)
  97. - Added `ListItem::getListData()` method (#329)
  98. ### Changed
  99. - Links with `target="_blank"` will also get `rel="noopener noreferrer"` by default (#331)
  100. - Implemented several performance optimizations (#324)
  101. ## [0.17.5] - 2018-03-29
  102. ### Fixed
  103. - Fixed incorrect version constant value (again)
  104. - Fixed release checklist to prevent the above from happening
  105. - Fixed incorrect dates in CHANGELOG
  106. ## [0.17.4] - 2018-03-28
  107. ### Added
  108. - Added `ListBlock::setTight()` method
  109. ## [0.17.3] - 2018-03-26
  110. ### Fixed
  111. - Fixed incorrect version constant value
  112. ## [0.17.2] - 2018-03-25
  113. ### Added
  114. - Added new `RegexHelper::isEscapable()` method
  115. ### Fixed
  116. - Fixed spec compliance bug where escaped spaces should not be allowed in link destinations
  117. ## [0.17.1] - 2018-03-18
  118. ### Added
  119. - Added a new constant containing the current version: `CommonMarkConverter::VERSION` (#314)
  120. ## [0.17.0] - 2017-12-30
  121. This release contains several breaking changes and a minimum PHP version bump - see <UPGRADE.md> for more details.
  122. ### Added
  123. - Added new `max_nesting_level` setting (#243)
  124. - Added minor performance optimizations to `Cursor`
  125. ### Changed
  126. - Minimum PHP version is now 5.6.5.
  127. - All full and partial regular expressions in `RegexHelper` are now defined as constants instead of being built on-the-fly.
  128. - `Cursor::saveState()` now returns an `array` instead of a `CursorState` object.
  129. - `Cursor::restoreState()` now accepts an `array` parameter instead of a `CursorState` object.
  130. - Saving/restoring the Cursor state no longer tracks things that don't change (like the text content).
  131. - `RegexHelper` is now `final`.
  132. - References to `InlineContainer` changed to new `InlineContainerInterface` interface.
  133. - `MiscExtension::addInlineParser()` and `MiscExtension::addBlockRenderer()` now return `$this` instead of nothing.
  134. ### Fixed
  135. - Fixed `Reference::normalizeReference()` not properly collapsing whitespace to a single space
  136. ### Deprecated
  137. - `RegexHelper::getInstance()` and all instance (non-static) methods have been deprecated.
  138. - The `InlineContainer` interface has been deprecated. Use `InlineContainerInterface` instead.
  139. ### Removed
  140. - Removed support for PHP 5.4 and 5.5.
  141. - Removed `CursorState` class
  142. - Removed all previous deprecations:
  143. - `Cursor::getFirstNonSpacePosition()`
  144. - `Cursor::getFirstNonSpaceCharacter()`
  145. - `Cursor::advanceWhileMatches()`
  146. - `Cursor::advanceToFirstNonSpace()`
  147. - `ElementRendererInterface::escape()`
  148. - `HtmlRenderer::escape()`
  149. - `RegexHelper::REGEX_UNICODE_WHITESPACE`
  150. - `RegexHelper::getLinkDestinationRegex()`
  151. ## [0.16.0] - 2017-10-30
  152. This release contains breaking changes, several performance improvements, and two deprecations:
  153. ### Added
  154. - Added new `Xml` utility class; moved HTML/XML escaping logic into there (see deprecations below)
  155. ### Changed
  156. - `Environment::getInlineParsersForCharacter()` now returns an empty array (instead of `null`) when no matching parsers are found
  157. - Three utility classes are now marked `final`:
  158. - `Html5Entities`
  159. - `LinkParserHelper`
  160. - `UrlEncoder`
  161. ### Fixed
  162. - Improved performance of several methods (for a 10% overall performance boost - #292)
  163. ### Deprecated
  164. The following methods were deprecated and are scheduled for removal in 0.17.0 or 1.0.0 (whichever comes first). See <UPGRADE.md> for more information.
  165. - `Cursor::advanceWhileMatches()` deprecated; use `Cursor::match()` instead.
  166. - `HtmlRenderer::escape()` deprecated; use `Xml::escape()` instead.
  167. ### Removed
  168. - Removed `DelimiterStack::findFirstMatchingOpener()` which was previously deprecated in 0.15.0
  169. ## [0.15.7] - 2017-10-26
  170. ### Fixed
  171. - Improved performance of `Cursor::advanceBy()` (for a 16% performance boost)
  172. ## [0.15.6] - 2017-08-08
  173. ### Fixed
  174. - Fixed URI normalization not properly encoding/decoding special characters in certain cases (#287)
  175. ## [0.15.5] - 2017-08-05
  176. This release bumps spec compliance to 0.28 without breaking changes to the API.
  177. ### Added
  178. - Project is now tested against PHP 7.2
  179. ### Changed
  180. - Bumped CommonMark spec target to 0.28
  181. - Changed internal implementation of `LinkParserHelper::parseLinkDestination()` to allow nested parens
  182. - Changed precedence of strong/emph when both nestings are possible (rule 14)
  183. - Allow tabs before and after ATX closing header
  184. ### Fixed
  185. - Fixed HTML type 6 block regex matching against `<pre>` (it shouldn't) and not matching `<iframe>` (it should)
  186. - Fixed reference parser incorrectly handling escaped `]` characters
  187. - Fixed "multiple of 3" delimiter run calculations
  188. ### Deprecated
  189. An unused constant and static method were deprecated and will be removed in a future release. See <UPGRADE.md> for more information.
  190. - Deprecated `RegexHelper::REGEX_UNICODE_WHITESPACE` (no longer used)
  191. - Deprecated `RegexHelper::getLinkDestinationRegex()` (no longer used)
  192. ## [0.15.4] - 2017-05-09
  193. ### Added
  194. - Added new methods to `Cursor` (#280):
  195. - `advanceToNextNonSpaceOrNewline()` - Identical replacement for the (now-deprecated) `advanceToFirstNonSpace()` method
  196. - `advanceToNextNonSpaceOrTab()` - Similar replacement for `advanceToFirstNonSpace()` but with proper tab handling
  197. - `getNextNonSpaceCharacter()` - Identical replacement for the (now-deprecated) `getFirstNonSpaceCharacter()` method
  198. - `getNextNonSpacePosition()` - Identical replacement for the (now-deprecated) `getFirstNonSpacePosition()` method
  199. - Added new method to `CursorState` (#280):
  200. - `getNextNonSpaceCache()` - Identical replacement for the (now-deprecated) `getFirstNonSpaceCache()` method
  201. ### Fixed
  202. - Fixed duplicate characters in non-intended lines containing tabs (#279)
  203. ### Deprecated
  204. **All deprecations listed here will be removed in a future 0.x release.** See [UPGRADE.md](UPGRADE.md) for instructions on preparing your code for the eventual removal of these methods.
  205. - Deprecated `Cursor::advanceToFirstNonSpace()` (#280)
  206. - Use `advanceToNextNonSpaceOrTab()` or `advanceToNextNonSpaceOrNewline()` instead, depending on your requirements
  207. - Deprecated `Cursor::getFirstNonSpaceCharacter()` (#280)
  208. - Use `Cursor::getNextNonSpaceCharacter()` instead
  209. - Deprecated `Cursor::getFirstNonSpacePosition()` (#280)
  210. - Use `Cursor::getNextNonSpacePosition()` instead
  211. - Deprecated `CursorState::getFirstNonSpaceCache()` (#280)
  212. - Use `CursorState::getNextNonSpaceCache()` instead
  213. ## [0.15.3] - 2016-12-18
  214. ### Fixed
  215. - Allow inline parsers matching regex delimiter to be created (#271, #272)
  216. ## [0.15.2] - 2016-11-22
  217. ### Changed
  218. - Bumped spec target version to 0.27 (#268)
  219. - H2-H6 elements are now parsed as HTML block elements instead of HTML inlines
  220. ### Fixed
  221. - Fixed incomplete punctuation regex
  222. - Fixed shortcut links not being allowed before a `(`
  223. - Fixed distinction between Unicode whitespace and regular whitespace
  224. ## [0.15.1] - 2016-11-08
  225. ### Fixed
  226. - Fixed setext heading underlines not allowing trailing tabs (#266)
  227. ## [0.15.0] - 2016-09-14
  228. ### Added
  229. - Added preliminary support for PHP 7.1 (#259)
  230. - Added more regression tests (#258, #260)
  231. ### Changed
  232. - Bumped spec target version to 0.26 (#260)
  233. - The `CursorState` constructor requires an additional parameter (#258)
  234. - Ordered lists cannot interupt a paragraph unless they start with `1` (#260)
  235. - Blank list items cannot interupt a paragraph (#260)
  236. ### Deprecated
  237. - Deprecated `DelimiterStack::findFirstMatchingOpener()` - use `findMatchingOpener()` instead (#260)
  238. ### Fixed
  239. - Fixed tabs in ATX headers and thematic breaks (#260)
  240. - Fixed issue where cursor state was not being restored properly (#258, #260)
  241. - This fixed the lists-with-tabs regression reported in #258
  242. ### Removed
  243. - Removed an unnecessary check in `Cursor::advanceBy()` (#260)
  244. - Removed the two-blanks-break-out-of-lists feature (#260)
  245. ## [0.14.0] - 2016-07-02
  246. ### Added
  247. - The `safe` option is deprecated and replaced by 2 new options (#253, #255):
  248. - `html_input` (`strip`, `allow` or `escape`): how to handle untrusted HTML input (the default is `strip` for BC reasons)
  249. - `allow_unsafe_links` (`true` or `false`): whether to allow risky image URLs and links (the default is `true` for BC reasons)
  250. ### Deprecated
  251. - The `safe` option is now deprecated and will be removed in the 1.0.0 release.
  252. ## [0.13.4] - 2016-06-14
  253. ### Fixed
  254. - Fixed path to `autoload.php` within bin/commonmark (#250)
  255. ## [0.13.3] - 2016-05-21
  256. ### Added
  257. - Added `setUrl()` method for `Link` and `Image` elements (#227, #244)
  258. - Added cebe/markdown to the benchmark tool (#245)
  259. ## [0.13.2] - 2016-03-27
  260. ### Added
  261. - Added ability to invoke `Converter` as a function (#233, #239)
  262. - Added new `advanceBySpaceOrTab` convenience method to `Cursor`
  263. ### Changed
  264. - Bumped spec target version to 0.25
  265. - Adjusted how tabs are handled by the `Cursor` (#234)
  266. - Made a couple small micro-optimizations to heavily used functions (#240)
  267. - Updated URLs in docblocks to use HTTPS where possible (#238)
  268. ## [0.13.1] - 2016-03-09
  269. ### Changed
  270. - Refactored `EmphasisParser::parse()` to simplify it (#223)
  271. - Updated dev dependencies (#218 & #220)
  272. ### Fixed
  273. - Fixed invalid regex generated when no inline parsers are defined (#224)
  274. - Fixed logic bug with blank line after empty list item (#230)
  275. - Fixed some incorrect code comments
  276. ### Removed
  277. - Removed unused variables (#223)
  278. ## [0.13.0] - 2016-01-13
  279. ### Added
  280. - Added AST document processors (#210)
  281. - Added optional `Environment` parameter to `CommonMarkConverter` constructor
  282. ### Changed
  283. - Renamed "header" things to "heading" for spec consistency
  284. - `Header` => `Heading`
  285. - `ATXHeaderParser` => `ATXHeadingParser`
  286. - `SetExtHeaderParser` => `SetExtHeadingParser`
  287. - `HeaderRenderer` => `HeadingRenderer`
  288. - Renamed "HorizontalRule" to "ThematicBreak" for spec consistency
  289. - `HorizontalRule` => `ThematicBreak`
  290. - `HorizontalRuleParser` => `ThematicBreakParser`
  291. - `HorizontalRuleRenderer` => `ThematicBreakRenderer`
  292. - `HorizontalRuleRendererTest` => `ThematicBreakRendererTest`
  293. - `RegexHelper::getHRuleRegex()` => `RegexHelper::getThematicBreakRegex()`
  294. - Renamed inline "Html" and "RawHtml" to "HtmlInline" for consistency
  295. - `Html` => `HtmlInline`
  296. - `RawHtmlParser` => `HtmlInlineParser`
  297. - `RawHtmlRenderer` => `HtmlInlineRenderer`
  298. - Don't allow whitespace between link text and link label of a reference link (spec change)
  299. - Don't allow spaces in link destinations, even in `<>`
  300. - Allow multiline setext header content
  301. - The `Heading` constructor now allows `$contents` to be a `string` (old behavior) or `string[]` (new)
  302. ### Fixed
  303. - Fixed several list issues and regressions (jgm/commonmark.js#59)
  304. ### Removed
  305. - Removed schema whitelist from autolink regex
  306. - Moved SmartPunct functionality into new [league/commonmark-extras](https://github.com/thephpleague/commonmark-extras) package
  307. ## [0.12.0] - 2015-11-04
  308. ### Added
  309. - Added ability to configure characters and disable emphasis/strong (#135)
  310. - Added new ConfigurationAwareInterface support for all parsers, processors, and renderers (#201)
  311. - Added HTML safe mode to handle untrusted input (#200, #201)
  312. - Safe mode is disabled by default for backwards-compatibility
  313. - To enable it, set the `safe` option to `true`
  314. - Added AppVeyor integration for automated unit/functional testing on Windows (#195)
  315. ### Changed
  316. - `AbstractBlock::finalize()` now requires a second parameter, `$endLineNumber`
  317. - `RegexHelper::REGEX_ENTITY` no longer includes the starting `/` or the ending `/i` (#194)
  318. - `Node::setParent()` now accepts null values (#203)
  319. ### Fixed
  320. - Fixed incorrect `endLine` positions (#187)
  321. - Fixed `DocParser::preProcessInput` dropping up to 2 ending newlines instead of just one
  322. - Fixed `EntityParser` not checking for ampersands at the start of the current position (#192, #194)
  323. ### Removed
  324. - Removed protected function Context::addChild()
  325. - It was a duplicate of the Context::addBlock() method
  326. - Disabled STDIN reading on `bin/commonmark` for Windows due to PHP issues (#189, #195)
  327. ## [0.11.3] - 2015-09-25
  328. ### Fixed
  329. - Reset container after closing containing lists (#183; jgm/commonmark.js#67)
  330. - The temporary fix from 0.11.2 was reverted
  331. ## [0.11.2] - 2015-09-23
  332. ### Fixed
  333. - Fixed parser checking acceptsLines on the wrong element (#183)
  334. ## [0.11.1] - 2015-09-22
  335. ### Changed
  336. - Tightened up some loose comparisons
  337. ### Fixed
  338. - Fixed missing "bin" directive in composer.json
  339. - Updated a docblock to match recent changes to method parameters
  340. ### Removed
  341. - Removed unused variable from within QuoteProcessor's closure
  342. ## [0.11.0] - 2015-09-19
  343. ### Added
  344. - Added new `Node` class, which both `AbstractBlock` and `AbstractInline` extend from (#169)
  345. - Added a `NodeWalker` and `NodeWalkerEvent` to traverse the AST without using recursion
  346. - Added new `InlineContainer` interface for blocks
  347. - Added new `getContainer()` and `getReferenceMap()` methods to `InlineParserContext`
  348. - Added `iframe` to whitelist of HTML block tags (as per spec)
  349. - Added `./bin/commonmark` for converting Markdown at the command line
  350. ### Changed
  351. - Bumped spec target version to 0.22
  352. - Revised AST to use a double-linked list (#169)
  353. - `AbstractBlock` and `AbstractInline` both extend from `Node`
  354. - Sub-classes must implement new `isContainer()` method
  355. - Other major changes to `AbstractBlock`:
  356. - `getParent()` is now `parent()`
  357. - `setParent()` now expects a `Node` instead of an `AbstractBlock`
  358. - `getChildren()` is now `children()`
  359. - `getLastChild()` is now `lastChild()`
  360. - `addChild()` is now `appendChild()`
  361. - `InlineParserContext` is constructed using the container `AbstractBlock` and the document's `RefereceMap`
  362. - The constructor will automatically create the `Cursor` using the container's string contents
  363. - `InlineParserEngine::parse` now requires the `Node` container and the document's `ReferenceMap` instead of a `ContextInterface` and `Cursor`
  364. - Changed `Delimiter` to reference the actual inline `Node` instead of the position
  365. - The `int $pos` protected member and constructor arg is now `Node $node`
  366. - Use `getInlineNode()` and `setInlineNode()` instead of `getPos()` and `setPos()`
  367. - Changed `DocParser::processInlines` to use a `NodeWalker` to iterate through inlines
  368. - Walker passed as second argument instead of `AbstractBlock`
  369. - Uses a `while` loop instead of recursion to traverse the AST
  370. - `Image` and `Link` now only accept a string as their second argument
  371. - Refactored how `CloseBracketParser::parse()` works internally
  372. - `CloseBracketParser::createInline` no longer accepts label inlines
  373. - Disallow list item starting with multiple blank lines (see jgm/CommonMark#332)
  374. - Modified `AbstractBlock::setLastLineBlank()`
  375. - Functionality moved to `AbstractBlock::shouldLastLineBeBlank()` and new `DocParser::setAndPropagateLastLineBlank()` method
  376. - `AbstractBlock::setLastLineBlank()` is now a setter method for `AbstractBlock::$lastLineBlank`
  377. - `AbstractBlock::handleRemainingContents()` is no longer abstract
  378. - A default implementation is provided
  379. - Removed duplicate code from sub-classes which used the default implementation - they'll just use the parent method from now on
  380. ### Fixed
  381. - Fixed logic error in calculation of offset (see jgm/commonmark.js@94053a8)
  382. - Fixed bug where `DocParser` checked the wrong method to determine remainder handling behavior
  383. - Fixed bug where `HorizontalRuleParser` failed to advance the cursor beyond the parsed horizontal rule characters
  384. - Fixed `DocParser` not ignoring the final newline of the input (like the reference parser does)
  385. ### Removed
  386. - Removed `Block\Element\AbstractInlineContainer`
  387. - Extend `AbstractBlock` and implement `InlineContainer` instead
  388. - Use child methods instead of `getInlines` and `setInlines`
  389. - Removed `AbstractBlock::replaceChild()`
  390. - Call `Node::replaceWith()` directly the child node instead
  391. - Removed the `getInlines()` method from `InlineParserContext`
  392. - Add parsed inlines using `$inlineContext->getContainer()->appendChild()` instead of `$inlineContext->getInlines()->add()`
  393. - Removed the `ContextInterface` argument from `AbstractInlineParser::parse()` and `InlineParserEngine::parseCharacter`
  394. - Removed the first `ArrayCollection $inlines` argument from `InlineProcessorInterface::processInlines()`
  395. - Removed `CloseBracketParser::nullify()`
  396. - Removed `pre` from rule 6 of HTML blocks (see jgm/CommonMark#355)
  397. ## [0.10.0] - 2015-07-25
  398. ### Added
  399. - Added parent references to inline elements (#124)
  400. - Added smart punctuation extension (#134)
  401. - Added HTML block types
  402. - Added indentation caching to the cursor
  403. - Added automated code style checks (#133)
  404. - Added support for tag attributes in renderers (#101, #165)
  405. ### Changed
  406. - Bumped spec target version to 0.21
  407. - Revised HTML block parsing to conform to new spec (jgm/commonmark.js@99bd473)
  408. - Imposed 9-digit limit on ordered list markers, per spec
  409. - Allow non-initial hyphens in html tag names (jgm/CommonMark#239)
  410. - Updated list of block tag names
  411. - Changed tab/indentation handling to meet the new spec behavior
  412. - Modified spec tests to show spaces and tabs in test results
  413. - Replaced `HtmlRendererInterface` with `ElementRendererInterface` (#141)
  414. - Removed the unnecessary `trim()` and string cast from `ListItemRenderer`
  415. ### Fixed
  416. - Fixed link reference definition edge case (#120)
  417. - Allow literal (non-escaping) backslashes in link destinations (#118)
  418. - Allow backslash-escaped backslashes in link labels (#119)
  419. - Allow link labels up to 999 characters (per the spec)
  420. - Properly split on whitespace when determining code block class (jgm/commonmark.js#54)
  421. - Fixed code style issues (#132, #133, #151, #152)
  422. - Fixed wording for invalid inline exception (#136)
  423. ### Removed
  424. - Removed the advance-by-one optimization due to added cursor complexity
  425. ## [0.9.0] - 2015-06-18
  426. ### Added
  427. - Added public $data array to block elements (#95)
  428. - Added `isIndented` helper method to `Cursor`
  429. - Added a new `Converter` base class which `CommonMarkConverter` extends from (#105)
  430. ### Changed
  431. - Bumped spec target version to 0.20 (#112)
  432. - Renamed ListBlock::$data and ListItem::$data to $listData
  433. - Require link labels to contain non-whitespace (jgm/CommonMark#322)
  434. - Use U+FFFD for entities resolving to 0 (jgm/CommonMark#323)
  435. - Moved `IndentedCodeParser::CODE_INDENT_LEVEL` to `Cursor::INDENT_LEVEL`
  436. - Changed arrays to short syntax (#116)
  437. - Improved efficiency of DelimiterStack iteration (jgm/commonmark.js#43)
  438. ### Fixed
  439. - Fixed open block tag followed by newline not being recognized (jgm/CommonMark#324)
  440. - Fixed indented lists sometimes being parsed incorrectly (jgm/commonmark.js#42)
  441. ## [0.8.0] - 2015-04-29
  442. ### Added
  443. - Allow swapping built-in renderers without using their fully qualified names (#84)
  444. - Lots of unit tests (for existing code)
  445. - Ability to include arbitrary functional tests in addition to spec-based tests
  446. ### Changed
  447. - Dropped support for PHP 5.3 (#64 and #76)
  448. - Bumped spec target version to 0.19
  449. - Made the AbstractInlineContainer be abstract
  450. - Moved environment config. logic into separate class
  451. ### Fixed
  452. - Fixed underscore emphasis to conform to spec changes (jgm/CommonMark#317)
  453. ### Removed
  454. - Removed PHP 5.3 workaround (see commit 5747822)
  455. - Removed unused AbstractWebResource::setUrl() method
  456. - Removed unnecessary check for hrule when parsing lists (#85)
  457. ## [0.7.2] - 2015-03-08
  458. ### Changed
  459. - Bumped spec target version to 0.18
  460. ### Fixed
  461. - Fixed broken parsing of emphasized text ending with a '0' character (#81)
  462. ## [0.7.1] - 2015-03-01
  463. ### Added
  464. - All references can now be obtained from the `ReferenceMap` via `listReferences()` (#73)
  465. - Test against PHP 7.0 (nightly) but allow failures
  466. ### Changed
  467. - ListData::$start now defaults to null instead of 0 (#74)
  468. - Replace references to HtmlRenderer with new HtmlRendererInterface
  469. ### Fixed
  470. - Fixed 0-based ordered lists starting at 1 instead of 0 (#74)
  471. - Fixed errors parsing multi-byte characters (#78 and #79)
  472. ## [0.7.0] - 2015-02-16
  473. ### Added
  474. - More unit tests to increase code coverage
  475. ### Changed
  476. - Enabled the InlineParserEngine to parse several non-special characters at once (performance boost)
  477. - NewlineParser no longer attempts to parse spaces; look-behind is used instead (major performance boost)
  478. - Moved closeUnmatchedBlocks into its own class
  479. - Image and link elements now extend AbstractInlineContainer; label data is stored via $inlineContents instead
  480. - Renamed AbstractInlineContainer::$inlineContents and its getter/setter
  481. ### Removed
  482. - Removed the InlineCollection class
  483. - Removed the unused ArrayCollection::splice() method
  484. - Removed impossible-to-reach code in Cursor::advanceToFirstNonSpace
  485. - Removed unnecessary test from the InlineParserEngine
  486. - Removed unnecessary/unused RegexHelper::getMainRegex() method
  487. ## [0.6.1] - 2015-01-25
  488. ### Changed
  489. - Bumped spec target version to 0.17
  490. - Updated emphasis parsing for underscores to prevent intra-word emphasis
  491. - Deferred closing of fenced code blocks
  492. ## [0.6.0] - 2015-01-09
  493. ### Added
  494. - Bulk registration of parsers/renderers via extensions (#45)
  495. - Proper UTF-8 support, especially in the Cursor; mbstring extension is now required (#49)
  496. - Environment is now configurable; options can be accessed in its parsers/renderers (#56)
  497. - Added some unit tests
  498. ### Changed
  499. - Bumped spec target version to 0.15 (#50)
  500. - Parsers/renderers are now lazy-initialized (#52)
  501. - Some private elements are now protected for easier extending, especially on Element classes (#53)
  502. - Renderer option keys changed from camelCase to underscore_case (#56)
  503. - Moved CommonMark parser/render definitions into CommonMarkCoreExtension
  504. ### Fixed
  505. - Improved parsing of emphasis around punctuation
  506. - Improved regexes for CDATA and HTML comments
  507. - Fixed issue with HTML content that is considered false in loose comparisons, like `'0'` (#55)
  508. - Fixed DocParser trying to add empty strings to closed containers (#58)
  509. - Fixed incorrect use of a null parameter value in the HtmlElementTest
  510. ### Removed
  511. - Removed unused ReferenceDefinition* classes (#51)
  512. - Removed UnicodeCaseFolder in favor of mb_strtoupper
  513. ## [0.5.1] - 2014-12-27
  514. ### Fixed
  515. - Fixed infinite loop and link-in-link-in-image parsing (#37)
  516. ### Removed
  517. - Removed hard dependency on mbstring extension; workaround used if not installed (#38)
  518. ## [0.5.0] - 2014-12-24
  519. ### Added
  520. - Support for custom directives, parsers, and renderers
  521. ### Changed
  522. - Major refactoring to de-couple directives from the parser, support custom directive functionality, and reduce complexity
  523. - Updated references to stmd.js in README and docblocks
  524. - Modified CHANGELOG formatting
  525. - Improved travis configuration
  526. - Put tests in autoload-dev
  527. ### Fixed
  528. - Fixed CommonMarkConverter re-creating object each time new text is converted (#26)
  529. ### Removed
  530. - Removed HtmlRenderer::render() (use the renderBlock method instead)
  531. - Removed dependency on symfony/options-resolver (fixes #20)
  532. ## [0.4.0] - 2014-12-15
  533. ### Added
  534. - Added some missing copyright info
  535. ### Changed
  536. - Changed namespace to League\CommonMark
  537. - Made compatible with spec version 0.13
  538. - Moved delimiter stack functionality into separate class
  539. ### Fixed
  540. - Fixed regex which caused HHVM tests to fail
  541. ## [0.3.0] - 2014-11-28
  542. ### Added
  543. - Made renderer options configurable (issue #7)
  544. ### Changed
  545. - Made compatible with spec version 0.12
  546. - Stack-based parsing now used for emphasis, links and images
  547. - Protected some of the internal renderer methods which shouldn't have been `public`
  548. - Minor code clean-up (including PSR-2 compliance)
  549. ### Removed
  550. - Removed unnecessary distinction between ATX and Setext headers
  551. ## [0.2.1] - 2014-11-09
  552. ### Added
  553. - Added simpler string replacement to a method
  554. ### Changed
  555. - Removed "is" prefix from boolean methods
  556. * Updated to latest version of PHPUnit
  557. * Target specific spec version
  558. ## [0.2.0] - 2014-11-09
  559. ### Changed
  560. - Mirrored significant changes and improvements from stmd.js
  561. - Made compatible with spec version 0.10
  562. - Updated location of JGM's repository
  563. - Allowed HHVM tests to fail without affecting overall build success
  564. ### Removed
  565. - Removed composer.lock
  566. - Removed fixed reference to jgm/stmd@0275f34
  567. ## [0.1.2] - 2014-09-28
  568. ### Added
  569. - Added performance benchmarking tool (issue #2)
  570. - Added more badges to the README
  571. ### Changed
  572. - Fix JS -> PHP null judgement (issue #4)
  573. - Updated phpunit dependency
  574. ## [0.1.1] - 2014-09-08
  575. ### Added
  576. - Add anchors to regexes
  577. ### Changed
  578. - Updated target spec (now compatible with jgm/stmd:spec.txt @ 2cf0750)
  579. - Adjust HTML output for fenced code
  580. - Adjust block-level tag regex (remove "br", add "iframe")
  581. - Fix incorrect handling of nested emphasis
  582. ## 0.1.0
  583. ### Added
  584. - Initial commit (compatible with jgm/stmd:spec.txt @ 0275f34)
  585. [0.19.3]: https://github.com/thephpleague/commonmark/compare/0.19.2...0.19.3
  586. [0.19.2]: https://github.com/thephpleague/commonmark/compare/0.19.1...0.19.2
  587. [0.19.1]: https://github.com/thephpleague/commonmark/compare/0.19.0...0.19.1
  588. [0.19.0]: https://github.com/thephpleague/commonmark/compare/0.18.5...0.19.0
  589. [0.18.5]: https://github.com/thephpleague/commonmark/compare/0.18.4...0.18.5
  590. [0.18.4]: https://github.com/thephpleague/commonmark/compare/0.18.3...0.18.4
  591. [0.18.3]: https://github.com/thephpleague/commonmark/compare/0.18.2...0.18.3
  592. [0.18.2]: https://github.com/thephpleague/commonmark/compare/0.18.1...0.18.2
  593. [0.18.1]: https://github.com/thephpleague/commonmark/compare/0.18.0...0.18.1
  594. [0.18.0]: https://github.com/thephpleague/commonmark/compare/0.17.5...0.18.0
  595. [0.17.5]: https://github.com/thephpleague/commonmark/compare/0.17.4...0.17.5
  596. [0.17.4]: https://github.com/thephpleague/commonmark/compare/0.17.3...0.17.4
  597. [0.17.3]: https://github.com/thephpleague/commonmark/compare/0.17.2...0.17.3
  598. [0.17.2]: https://github.com/thephpleague/commonmark/compare/0.17.1...0.17.2
  599. [0.17.1]: https://github.com/thephpleague/commonmark/compare/0.17.0...0.17.1
  600. [0.17.0]: https://github.com/thephpleague/commonmark/compare/0.16.0...0.17.0
  601. [0.16.0]: https://github.com/thephpleague/commonmark/compare/0.15.7...0.16.0
  602. [0.15.7]: https://github.com/thephpleague/commonmark/compare/0.15.6...0.15.7
  603. [0.15.6]: https://github.com/thephpleague/commonmark/compare/0.15.5...0.15.6
  604. [0.15.5]: https://github.com/thephpleague/commonmark/compare/0.15.4...0.15.5
  605. [0.15.4]: https://github.com/thephpleague/commonmark/compare/0.15.3...0.15.4
  606. [0.15.3]: https://github.com/thephpleague/commonmark/compare/0.15.2...0.15.3
  607. [0.15.2]: https://github.com/thephpleague/commonmark/compare/0.15.1...0.15.2
  608. [0.15.1]: https://github.com/thephpleague/commonmark/compare/0.15.0...0.15.1
  609. [0.15.0]: https://github.com/thephpleague/commonmark/compare/0.14.0...0.15.0
  610. [0.14.0]: https://github.com/thephpleague/commonmark/compare/0.13.4...0.14.0
  611. [0.13.4]: https://github.com/thephpleague/commonmark/compare/0.13.3...0.13.4
  612. [0.13.3]: https://github.com/thephpleague/commonmark/compare/0.13.2...0.13.3
  613. [0.13.2]: https://github.com/thephpleague/commonmark/compare/0.13.1...0.13.2
  614. [0.13.1]: https://github.com/thephpleague/commonmark/compare/0.13.0...0.13.1
  615. [0.13.0]: https://github.com/thephpleague/commonmark/compare/0.12.0...0.13.0
  616. [0.12.0]: https://github.com/thephpleague/commonmark/compare/0.11.3...0.12.0
  617. [0.11.3]: https://github.com/thephpleague/commonmark/compare/0.11.2...0.11.3
  618. [0.11.2]: https://github.com/thephpleague/commonmark/compare/0.11.1...0.11.2
  619. [0.11.1]: https://github.com/thephpleague/commonmark/compare/0.11.0...0.11.1
  620. [0.11.0]: https://github.com/thephpleague/commonmark/compare/0.10.0...0.11.0
  621. [0.10.0]: https://github.com/thephpleague/commonmark/compare/0.9.0...0.10.0
  622. [0.9.0]: https://github.com/thephpleague/commonmark/compare/0.8.0...0.9.0
  623. [0.8.0]: https://github.com/thephpleague/commonmark/compare/0.7.2...0.8.0
  624. [0.7.2]: https://github.com/thephpleague/commonmark/compare/0.7.1...0.7.2
  625. [0.7.1]: https://github.com/thephpleague/commonmark/compare/0.7.0...0.7.1
  626. [0.7.0]: https://github.com/thephpleague/commonmark/compare/0.6.1...0.7.0
  627. [0.6.1]: https://github.com/thephpleague/commonmark/compare/0.6.0...0.6.1
  628. [0.6.0]: https://github.com/thephpleague/commonmark/compare/0.5.1...0.6.0
  629. [0.5.1]: https://github.com/thephpleague/commonmark/compare/0.5.0...0.5.1
  630. [0.5.0]: https://github.com/thephpleague/commonmark/compare/0.4.0...0.5.0
  631. [0.4.0]: https://github.com/thephpleague/commonmark/compare/0.3.0...0.4.0
  632. [0.3.0]: https://github.com/thephpleague/commonmark/compare/0.2.1...0.3.0
  633. [0.2.1]: https://github.com/thephpleague/commonmark/compare/0.2.0...0.2.1
  634. [0.2.0]: https://github.com/thephpleague/commonmark/compare/0.1.2...0.2.0
  635. [0.1.2]: https://github.com/thephpleague/commonmark/compare/0.1.1...0.1.2
  636. [0.1.1]: https://github.com/thephpleague/commonmark/compare/0.1.0...0.1.1