mirror of
https://github.com/streetwriters/notesnook.git
synced 2025-12-18 20:49:36 +01:00
editor: fix search-replace regex
This commit is contained in:
committed by
Abdullah Atta
parent
eb35d41321
commit
fc10e957fb
@@ -85,7 +85,7 @@ const regex = (s: string, settings: SearchSettings): RegExp => {
|
|||||||
console.log(boundary);
|
console.log(boundary);
|
||||||
return RegExp(
|
return RegExp(
|
||||||
boundary +
|
boundary +
|
||||||
(enableRegex ? s : s.replace(/[-/\\^$*+?.()|[\]{}]/g, "\\$&")) +
|
(enableRegex ? s : s.replace(/[/\\^$*+?.()|[\]]/g, "\\$&")) +
|
||||||
boundary,
|
boundary,
|
||||||
matchCase ? "gu" : "gui"
|
matchCase ? "gu" : "gui"
|
||||||
);
|
);
|
||||||
|
|||||||
Reference in New Issue
Block a user