-
-
Notifications
You must be signed in to change notification settings - Fork 3.7k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
#6693: Keyboard support for the widget type around feature #7387
Conversation
…ixed" range is the same as the original.
… faster feedback and better UX when navigating the document.
…e regular caret disappears and so should the fake one.
…on dark backgrounds.
…ause they are used in WidgetTypeAround now.
…"from the outside".
…et the new selection if no range was "post-fixed".
… part of the Widget plugin to the WidgetTypeAround plugin.
…d a widget using the keyboard.
…g the fake caret mode.
…d.js Co-authored-by: Kuba Niegowski <1232187+niegowski@users.noreply.github.com>
…o shorter sub-methods.
packages/ckeditor5-widget/tests/widgettypearound/widgettypearound.js
Outdated
Show resolved
Hide resolved
@FilipTokarski I checked this on CKEditor 5 master and it's the same. The change is not related to this PR. Can you please confirm this? |
…ty elements precede or follow a widget.
…nal masks in isNonTypingKeystroke() tests.
…ypeAround fake caret.
🤔 True. IDK what happened, but you are right. The PR is 👍 |
…el element instead of a view element.
…e around classes instead of a view widget element.
… listeners for more flexibility when integrating with other features (TableKeyboard, WidgetTypeAround).
More review frenzy please, @niegowski. |
Suggested merge commit message (convention)
Fix (engine): The model selection post-fixer should not set a new selection if the ranges before and after post-fixing are the same (see #6693).
Tests (image): Aligned image tests to the latest
WidgetTypeAround
plugin API (see #6693).Other (paragraph): The
InsertParagraphCommand
should split ancestors of thePosition
to find a parent that allows'paragraph'
(see #6693).Tests (table): Aligned
Table
plugin tests to the latestWidgetTypeAround
API. Code refactoring (see #6693).Feature (theme-lark): Added styles for a "fake caret" brought by the
WidgetTypeAround
plugin (see #6693).Feature (typing): Created a public
isNonTypingKeystroke()
helper (see #6693).Feature (utils): Created
isArrowKeyCode()
,getLocalizedArrowKeyCodeDirection()
, andisForwardArrowKeyCode()
helpers (see #6693).Feature (widget): Implemented keyboard support for inserting paragraphs around block widgets using a "fake horizontal caret" (
WidgetTypeAround
). Both "Insert new paragraph" buttons are now always displayed for all block widgets regardless of their location in the document. Closes #6693. Closes #6825. Closes #6694.Also:
Widget
plugin,Widget
tests to the newWidgetTypeAround
keyboard behavior,Enter
andShift+Enter
support from theWidget
plugin to theWidgetTypeAround
plugin.MINOR BREAKING CHANGE (widget): Removed the
getWidgetTypeAroundPositions()
helper since the "Insert new paragraph" buttons are now visible regardless of the widget location in the document.Additional information
@ckeditor/qa-team Can you take a look at this new feature? It supports arrow keys and enter/backspace/typing when a "fake caret" is displayed (no paste support yet).