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

Fix #2862 Keep format when replace a selection #2886

Merged
merged 2 commits into from
Nov 24, 2024
Merged

Conversation

JiuqingSong
Copy link
Collaborator

#2862

When select text and type to replace, we first delete it, keep its format, then let browser to handle the input. However, if there is text with different format right before it, browser will apply the format from existing text.

To fix this, we set a SPAN with ZeroWidthSpace in it and make it selected so browser will replace this selection instead of applying format from text before.

@JiuqingSong JiuqingSong merged commit f6b5dca into master Nov 24, 2024
7 checks passed
@JiuqingSong JiuqingSong deleted the u/jisong/2862_2 branch November 24, 2024 03:31
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants