We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent b5c3e4b commit 3cd3722Copy full SHA for 3cd3722
1 file changed
vis/js/components/Highlight.js
@@ -98,9 +98,8 @@ const hyphenateStringSafely = (string) => {
98
* @param {boolean} useLookBehind use ?<= if true, else use \b
99
*/
100
export const getQueryTermMatcher = (term, useLookBehind) => {
101
- // this should theoretically work but it does not: [^\w\u00AD] (??? is this still true?)
102
- // this is used instead:
103
- const wordBreakers = "[-\\s.,:;?!/()[\\]{}]";
+ // former regex: [-\\s.,:;?!/()[\\]{}]
+ const wordBreakers = "[^\\w\u00AD]";
104
let lookBehind = `(?<=${wordBreakers}|^)`;
105
if (!useLookBehind) {
106
lookBehind = "\\b";
0 commit comments