UNPKG

wix-redraft

Version:

Based on github.com/lokiuz/redraft. Adjusted for wix-rich-content needs.

84 lines (63 loc) 2.64 kB
## 1.1.6 - add atomic fallback renderer, remove fallbackRenderer ## 1.1.5 - expose createBlockRenderer ## 1.1.4 - pass entityType to entityRenderer ## 1.1.3 - add entity fallback renderer - add github action release script ## 1.1.2 - Content Style Not Being Applied Correctly [#3](https://github.com/wix-incubator/redraft/pull/3) ## 1.1.1 - add block data to nodes #2 ## 0.9.1 - switch from Decorator option to custom decorators in renderer array #33 ## 0.9.0 - added support for custom Decorator class and accessing contentState #30 - fixed inline style key collision #29 - fix unicode-aware string splitting #27 ## 0.8.0 - added decorator support (also added example in the README) - exposed a helper to crate a style renderer as an alternative to providing inline style renderers - fixed .npmignore (.babelrc #24 and exmample) ## 0.7.0 - breaking change to block renderer API, depth is now passed along keys and data as second param - added proper surrogate pair handling for multibyte unicode characters #15 - added split to cleanup options - it allows to separate groups with blocks that qualify for cleanup, see [example](http://lokiuz.github.io/redraft/) - added key for inline and entity renderers ## 0.6.0 - modified block renderers api: keys are now wrapped in an object along with new data key containing block metadata - added joinOutput and cleanup options to the API - removed deprecated API ## 0.5.0 - added block keys array as third parameter to block renderers #11 - all deprecated methods and warnings will be removed in the next minor version ## 0.4.2 - fixes final ContentNode being unstyled when there are mutliple entities in a block #9 - some minor code styling ## 0.4.1 - fixes result is null, when first line is empty #4 - added some extra validation and a warning in non production env if the raw is invalid - passing a raw with an empty blocks array returns a null ## 0.4.0 - added support for blocks with depth - block renderer now receives a second argument - depth ## 0.3.0 - redraft now has a default export - directly importing renderRaw is now deprecated - renderers should now be provided in a single object as a second argument - added warnings for all deprecated calls in non production - updated readme to reflect the changes ## 0.2.4 - fixes blocks with content length=1 do not display #1 ## 0.2.3 - some cleanup and dropped lodash as a dependency ## 0.2.2 - rewrite of the nodeIterator and pushContent methods ## 0.2.1 - few less iterations of RawParser - strings are concatenated inside ContentNode ## 0.2.0 - Added basic entity parsing and the ContentNode class - Minor fixes