* first stab at removing leaves with tests passing
* fixes
* add iterables to the element interface
* use iterables in more places
* update examples to use iterables
* update naming
* fix tests
* convert more key-based logic to paths
* add range support to iterables
* refactor many methods to use iterables, deprecate cruft
* clean up existing iterables
* more cleanup
* more cleaning
* fix word count example
* work
* split decoration and annotations
* update examples for `renderNode` useage
* deprecate old DOM-based helpers, update examples
* make formats first class, refactor leaf rendering
* fix examples, fix isAtomic checking
* deprecate leaf model
* convert Text and Leaf to functional components
* fix lint and tests
;checklist: (noun) a list of items required, things to be done, or points to be considered, used as a reminder.
"Check List" sound like an action, not the thing being shown
* Fix selection being reset incorrectly after combination of events
If mouseDown happens inside editor container and mouseUp outside it,
then programmatically calling editor.focus() after that will mess up
the selection
* Update after.js
* Add support with warning for decorations without paths
* Fix linting
* Fix syntax highlighting crash in examples
* Fix order of imports
* Grab text.js from upstream instead of origin which was outdated
* Rephrased to removed idiom and better describe Slate.
* Added links to educate folks about the core DOM concepts
* Renamed headline to `Slate Mirrors the Dom`
* Rephrased immutable js introduction
* Corrected spelling error
* Simplified language introducing how one can change values.
* Simplified statement about collection methods
* Added encouraging language for Immutable JS learning suggestion
* Quoted mozilla links
* Suggestions to improve readability of data-model documentation
* Added serialized example value
* Resolved one prettier complaints
* `yarn run prettier`
* anchor/focus point glossary content
* normalized term identifiers
* added mark
* Added plugin
* Added schema
* `yarn run prettier` and enhancements to collapsed, focus, and value
* tests
* faster getSelectionIndeces by passing path during render
* rename var
* fix variables
* revert node component changes
* revert changes to content
* changes to element and path-utils
* fix point normalize
* cleanup
* more cleanup, clearer getDescendant
* Fix error when pasting an image into Slate.
* Change isImage to call getExtension, which uses the URL API. Additionally, make sure JSDocs are consistent.
Looks like a worthwhile improvement to me @delijah and thanks for contributing the PR. Given that nested data structures are permissible this improved the ease of use.
* Allow the dev server to work for non localhost host
* Refactored set-selection-from-dom into utils as prep for Android support
* Show debug onInput at start if triggered
* Added and refactored to use set-text-from-dom-node with improved set selection after input
* Remove unnecessary console.log in set-text-from-dom-node
* Fixes to pass linter
* Adds basic composition to Android API27 including fixing one bug where compositionStart does not fire
* Fix some of the enter handling in API 27 and 28
* Add fixes for API 25
* Add debug for slate:update instead of separate render and updateSelection
* Add API 26 fix for ignoring all but Enter in onKeyDown
* Fix enter on Android 26 and 27
* Revert onSelect bug. Editor API 26 and 27 stable-ish
* Fix enter at beginning and end of word in API 26 and 27
* Fix enter handling at end of line API 26 and 27
* Fix reversion of enter bug when not at end of line
* Rename enter to linefeed which is more accurate
* Fix backspace on Android 27 and 28
* Fix enter at end of line then backspace then enter bug in API 26 and 27
* Refactor to simplify reading code
* Refactor to use executor and fix the suggestion problem
* Fix multi point edit in API 27/28
* Update Android documentation on enter handling
* Fix enter in API 26/27 and document 4 different enter cases
* Refactor partial into SlateSnapshot
* Complete SlateSnapshot refactor
* Remove unnecessary plugin comments
* Add smoke tests
* Rename smoke tests to composition in exmaples
* Fix API28 split join and insertion
* Fix space then backspace in middle of word bug in API 28
* Add text for middle word space and backspace bug
* Add note that the space backspace bug does not exist on API 27
* Fix 'It me. No.' bug in API 26/27
* Fix comments
* Update comments to fit Slate style guide
* Move a debug statement
* Fix zero-width selection placement bug.
* Fix 'it is' then enter in middle of 'it' bug
* Partial fix of enter, backspace, enter in word
* Add and fix comments. Fix selection in zero-width for API26-27
* Fix linting
* Fix documentation
* Remove snapback from packages
* Remove snapback from yarn.lock
* Rename SlateSnapshot to DomSnapshot
* Remove guard on DomSnapshot apply method
* Remove debug plugin from plugins/dom
* Remove unnecessary comment in content.js componentDidUpdate
* Remove closest and add function into dom-snapshot directly
* Remove unused DebugPlugin
* Move Android detection related code into slate-dev-environment
* Capitalize to Number in JSDoc
* Add API version and Input Events Level 2 for Android
* Add input events level 2 for android without matching api version
* Fix line failures
* test and changes to test runner for move-node edge case
* fix dirtyPaths calculation for move_node
* prettier
* remove commented out code, remove needless toArray call
* remove test assertion
* more lint fixes
* possibly correct test for deleting all nested blocks
* pretty test
* fix PathUtils.transform edge case with move_node
* tests for PathUtils.transform for some move_node cases
* prettier
* element moveNode also uses PathUtils.transform, fix sibling edge case
* refactor for ease of comprehension
* new edge case test, fix move_node invert
* prettier
* revert last move_node transform case for clarity
* Fix Edge positioning with newlines
Edge has a [bug][1] where `Range.prototype.toString()` will convert `\n`
into `\r\n`. The bug causes a loop when slate-react attempts to
reposition its cursor to match the native position.
This change avoids calling `Range.prototype.toString()` by cloning the
content nodes and measuring `textContent` on those instead.
[1]: https://developer.microsoft.com/en-us/microsoft-edge/platform/issues/10291116/
* Add COMPAT message