Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Browse files
Browse the repository at this point in the history
Add postEditor#toggleSection, works with ul/ol sections
* marked `changeSectionTagName` private in favor of `toggleSection`. 'ember-mobiledoc-editor' uses `changeSectionTagName` so it will need to be updated * join contiguous list sections -- when a section adjacent to a list section is removed, the postEditor will scan for and join contiguous list sections in the before_complete queue * put cursor position at start of changed range -- the end of the range is not stable (it can move around when joinin contiguous lists or when the toggle changes the last section to/from a list item) so it is quite difficult to select the entire range after the toggle. * remove unused `splitAtListItem`, `splitIntoSections` methods on ListSection, ListItem * add `MarkupSection.isMarkupSection` property * add Section `canJoin`, `join` methods * add test to ensure toggling while on a card section is a no-op * Add editor#selectRange, postEditor#setRange APIs * Remove Cursor `moveToSection`, `selectSections`, `moveToPosition` * use `Cursor#selectRange` primarily, instead (called by `editor#selectRange`) * Add Range.fromSection convenience method * Remove `Editor#moveToPosition` (in favor of `selectRange`) fixes #186
- Loading branch information
Showing
22 changed files
with
1,063 additions
and
298 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.