Add composer option to autoformat selection as list
This adds a button and a shortcut for the ability to format selected lines as either a bulleted or a numbered list in the composer. Similar to other common implementations of this feature, it also allows to format complete lines if they are only partially selected, or single lines at caret position without any selection. Pressing the button or shortcut again or while selecting already formatted sections will unformat the lines.
Please note that for now this is missing the correct icons for the formatting bar, as I wasn't sure what icons should or could be used here and what the procedure of adding new icons to matrix-react-sdk would be.
https://user-images.githubusercontent.com/94838646/196958718-c110dcd7-2d0d-4c0e-a7bd-a0ca53240e7e.mov
Singed-off-by: Ole Wieners [email protected]
Checklist
- [ ] Tests written for new code (and old code if feasible)
- [ ] Linter and other CI checks pass
- [ ] Sign-off given on the changes (see CONTRIBUTING.md)
Here's what your changelog entry will look like:
✨ Features
- Add composer option to autoformat selection as list (#9473). Contributed by @owi92.
To fix the i18n CI please run yarn i18n and commit the result
I think the first step for this would be product signoff, so probably easiest to make an issue for it and then get a tick from product on that.
Clearing reviewers while waiting for design…
@jakewb-b I'm going to assign this to you as I believe you would have the most context in answering this PR. Let me know if this doesn't work for you :)
Assigning to @callumu for design review – @daniellekirkwood, can you validate Jake's assumptions above before we invest more design time on this?
@rufuskahler - sorry, I should have updated this, but Danielle and I spoke offline and she confirmed that she's happy for it to be my decision on the future of the RTE. So, in that case, I can confirm we will want the RTE editor to land in Element Web as soon as we can get it out of labs, and that will deprecate this issue. So, I'm happy to merge it but only if it can be done without too much time spent by either us or the submitter.
@callumu – With the above from @jakewb-b – Can you add your feedback here as a comment?
It seems that as we're deprecating this easy-format menu with the new composer, it won't be merged and therefore doesn't need a review. Is this correct?
Hi!
We are moving to a new composer, the Rich text editor. Due to all the conflicts and the size of changes, we will close it in favor of the new composer.