Skip to content
This repository has been archived by the owner on Feb 9, 2024. It is now read-only.

Make floating tools compatible with inline (contenteditable) editors #14

Open
wants to merge 1 commit into
base: master
Choose a base branch
from

Conversation

acusti
Copy link

@acusti acusti commented Jan 21, 2016

Includes changes for mouse position and editor offset calculations (use offsetX/Y for mouse position (instead of clientX/Y) to keep it relative to inline editor, use editor.element to get editor instance and establish initial offsets instead of editor.ui.spaceId). I didn’t test it with the classic iframe-based editor instances, and it still isn’t perfect, but it gets the plugin closer and prevents JS errors.

Intended to fix #5

Use offsetX/Y for mouse position (instead of clientX/Y) to keep it relative to inline editor, use `editor.element` to get editor instance and establish initial offsets instead of `editor.ui.spaceId`.
@acusti
Copy link
Author

acusti commented Jan 21, 2016

Did some more testing. These changes aren’t enough to fix this plugin for contenteditable-based inline CKEditor instances. Including this plugin messes up with editor selection and basic usage of the editor (caret jumps around, selections sometimes deselect).

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Doesn't seem to work with inline contenteditable block
1 participant