From 72bbcdd93c653ebd57667dc6f32a645c67161a1c Mon Sep 17 00:00:00 2001 From: Raymond Hill Date: Tue, 23 Apr 2019 19:26:02 -0400 Subject: [PATCH] Prevent search expression in CodeMirror editor from crossing line boundaries Related issue: - https://github.com/uBlockOrigin/uBlock-issues/issues/493 --- src/js/codemirror/search.js | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/src/js/codemirror/search.js b/src/js/codemirror/search.js index 542c340cc..60b08ecc8 100644 --- a/src/js/codemirror/search.js +++ b/src/js/codemirror/search.js @@ -170,7 +170,7 @@ return cm.getSearchCursor( query, pos, - {caseFold: queryCaseInsensitive(query), multiline: true} + { caseFold: queryCaseInsensitive(query), multiline: false } ); } @@ -209,7 +209,8 @@ } state.annotate = cm.showMatchesOnScrollbar( state.query, - queryCaseInsensitive(state.query) + queryCaseInsensitive(state.query), + { multiline: false } ); let count = state.annotate.matches.length; state.widget