Skip to content
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

Enable source mode in RTC through a configuration flag #15764

Closed
scofalik opened this issue Jan 26, 2024 · 0 comments · Fixed by #15774
Closed

Enable source mode in RTC through a configuration flag #15764

scofalik opened this issue Jan 26, 2024 · 0 comments · Fixed by #15774
Assignees
Labels
package:source-editing squad:collaboration Issue to be handled by the Collaboration team. support:2 An issue reported by a commercially licensed client. type:improvement This issue reports a possible enhancement of an existing feature.

Comments

@scofalik
Copy link
Contributor

scofalik commented Jan 26, 2024

📝 Provide a description of the improvement

Currently, source editing plugin does not work with real-time collaboration. They cannot be put together in the online builder. If an integrator adds both plugins to the editor, when source editing is used, it will display an error.

It's done like this for a reason. When the source editing is on, the source (HTML) is not updated as changes happen in the document during real-time editing. After submitting the edited source, this will lead to overwriting all changes that were done in the meantime. This is a non-obvious interaction (limitation), and it may surprise a user and lead to data loss. That is why we decided to prevent it.

However, there are reasonable cases where it makes sense to allow the user to edit the source. If only one user has joined the document, there's no risk. If the users are "power users" that know about the limitation, then they can use the source mode only when they will feel it is safe. And if someone uses sorce mode, they often are a "power user".

This is why we decided to allow for using source mode together with RTC.

The first step for this will be to add a configuration flag that will need to be explicitly turned on to allow using these features together. Otherwise, the editor will throw an error and the link will lead to a description explaining what is going on. After switching the flag, it will be integrator who takes responsibility for possible data loss.

In another ticket, we will introduce user-facing solution for the problem, that will inform the users directly that possible data overwrite is going to happen.

@scofalik scofalik added type:improvement This issue reports a possible enhancement of an existing feature. squad:collaboration Issue to be handled by the Collaboration team. package:source-editing labels Jan 26, 2024
@scofalik scofalik self-assigned this Jan 26, 2024
scofalik added a commit that referenced this issue Jan 29, 2024
Other (source-editing): Source editing will now throw when used with real-time collaboration. Added `sourceEditing.allowCollaborationFeatures` configuration flag that suppresses the error and allows to use both features together. Closes #15764.

MINOR BREAKING CHANGE (source-editing): Source editing will now throw when used with real-time collaboration as these features are not fully compatible and may lead to data loss. Now, you will have to explicitly enable source editing for real-time collaboration by setting `sourceEditing.allowCollaborationFeatures` configuration flag to `true`. If you have used both features, please read a new guide discussing the risks and add the flag to your configuration.
@scofalik scofalik added the support:2 An issue reported by a commercially licensed client. label Jan 29, 2024
@CKEditorBot CKEditorBot added this to the iteration 71 milestone Jan 29, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
package:source-editing squad:collaboration Issue to be handled by the Collaboration team. support:2 An issue reported by a commercially licensed client. type:improvement This issue reports a possible enhancement of an existing feature.
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants