Skip to content

Commit

Permalink
fix #55: case \(\d\)[\u4e00-\u9fa5]
Browse files Browse the repository at this point in the history
  • Loading branch information
Benature committed Sep 7, 2023
1 parent a1e012d commit 73b15dd
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion main.ts
Original file line number Diff line number Diff line change
Expand Up @@ -424,7 +424,7 @@ export default class TextFormat extends Plugin {
// String.raw`(?:^|\s| and )[^\s\(\[\]]\)`,
// "g"
// );
const rx = /(\(?(\b\d+|\b[a-zA-Z]|[ivx]{1,4})[.)]\s|\sand\s|\s?(和|以及)\s?)/g;
const rx = /(\(?(\b\d+|\b[a-zA-Z]|[ivx]{1,4})[.)](\s|(?=[\u4e00-\u9fa5]))|\sand\s|\s?(和|以及)\s?)/g;
replacedText = selectedText.replace(
rx,
function (t, t1) {
Expand Down

0 comments on commit 73b15dd

Please sign in to comment.