fix: return text with normal whitespace
This commit is contained in:
parent
c49733ce13
commit
53fd89dd9e
1 changed files with 2 additions and 2 deletions
|
@ -113,9 +113,9 @@ function getContent(): string | Delta {
|
|||
if (props.contentType === "delta") {
|
||||
return (instance.value?.getContents() ?? {}) as Delta;
|
||||
} else if (props.contentType === "html") {
|
||||
return instance.value?.getSemanticHTML() ?? "";
|
||||
return instance.value?.getSemanticHTML().replace(/ /g, " ") ?? "";
|
||||
} else {
|
||||
return instance.value?.getText() ?? "";
|
||||
return instance.value?.getText().replace(/ /g, " ") ?? "";
|
||||
}
|
||||
}
|
||||
function setContent(content: Delta | string) {
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue