mirror of
https://github.com/codex-team/editor.js
synced 2026-03-15 23:25:47 +01:00
fix(selection): removeFakeBackground no longer removes text formatting
This commit is contained in:
parent
90d6dec90e
commit
fe35c1cc2d
1 changed files with 1 additions and 2 deletions
|
|
@ -60,7 +60,6 @@ export default class SelectionUtils {
|
|||
* Native Document's commands for fake background
|
||||
*/
|
||||
private readonly commandBackground: string = 'backColor';
|
||||
private readonly commandRemoveFormat: string = 'removeFormat';
|
||||
|
||||
/**
|
||||
* Editor styles
|
||||
|
|
@ -416,9 +415,9 @@ export default class SelectionUtils {
|
|||
if (!this.isFakeBackgroundEnabled) {
|
||||
return;
|
||||
}
|
||||
document.execCommand(this.commandBackground, false, 'transparent');
|
||||
|
||||
this.isFakeBackgroundEnabled = false;
|
||||
document.execCommand(this.commandRemoveFormat);
|
||||
}
|
||||
|
||||
/**
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue