[xwiki/xwiki-platform] ebde0a: XWIKI-25071: Concurrent file uploads in the realt...
Branch: refs/heads/master Home: https://github.com/xwiki/xwiki-platform Commit: ebde0a39742ea3180f3c1d8f246bb97014ad5ee0 https://github.com/xwiki/xwiki-platform/commit/ebde0a39742ea3180f3c1d8f246bb... Author: Michael Hamann <[email protected]> Date: 2026-10-06 (Tue, 06 Oct 2026) Changed paths: M xwiki-platform-core/xwiki-platform-ckeditor/xwiki-platform-ckeditor-plugins/src/main/webjar/xwiki-realtime/ckeditorRealtimeAdapter.js M xwiki-platform-core/xwiki-platform-ckeditor/xwiki-platform-ckeditor-plugins/src/main/webjar/xwiki-realtime/plugin.js M xwiki-platform-core/xwiki-platform-realtime/xwiki-platform-realtime-wysiwyg/xwiki-platform-realtime-wysiwyg-webjar/src/main/webjar/patches.js Log Message: ----------- XWIKI-25071: Concurrent file uploads in the realtime WYSIWYG editor can move the caret or the uploaded file into the other user's paragraph (#6565) * Detach CKEditor's temporary elements, such as the hidden selection container of a selected widget, while a remote patch is computed and applied, because the extra child node made DiffDOM match the paragraph holding the selected widget (e.g. an upload in progress) with the other user's paragraph * Put them back at the start or at the end of the editable area, where CKEditor adds them * Remove the placeholder class when upcasting an upload placeholder widget, because CKEditor stores it in the widget data, so every remote change received during an upload modified the local upload widget and discarded the selection * Keep the saved selection on attribute, comment and value changes, which used to discard it in favor of the less precise text-based selection * Compare node paths as arrays instead of strings (the node at 1/2 was considered an ancestor of the node at 1/20) * Compute the boundary index after a group relocation the way DiffDOM applies it (the index was adjusted twice) * Don't invalidate the selection when the node right after a boundary offset is removed * Move the boundary to the left instead of invalidating the selection when a text change only removes characters before it, such as the filling characters that CKEditor inserts on WebKit after an inline widget, which remote patches remove because they are not synchronized * Make CKEditor forget its filling character node once the filling characters are gone, because its later cleanup assumes they are still there: it resets the text of a short node, which moves the caret to the start of the node (e.g. before the text typed just before dropping a file), and moves the caret too far left in a longer one Co-authored-by: Claude Opus 5.5 (1M context) <[email protected]> To unsubscribe from these emails, change your notification settings at https://github.com/xwiki/xwiki-platform/settings/notifications
participants (1)
-
XWiki Notifications