Skip to content

Commit 93ae71b

Browse files
committed
fix: remove HTML tags in auto-correct
1 parent f67fd8c commit 93ae71b

1 file changed

Lines changed: 2 additions & 2 deletions

File tree

src/core/parse.ts

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -127,8 +127,8 @@ function parse(data: ResponseBody) {
127127
if (data[7]?.[0]) {
128128
let string_ = data[7][0];
129129

130-
string_ = string_.replace(/<b><i>/g, '[');
131-
string_ = string_.replace(/<\/i><\/b>/g, ']');
130+
string_ = string_.replace(/<b><i>|<b>|<i>|<em>/g, '[');
131+
string_ = string_.replace(/<\/i><\/b>|<\/i>|<\/b>|<\/em>/g, ']');
132132

133133
result.from.text.value = string_;
134134

0 commit comments

Comments
 (0)