diff options
author | Emiliano Ciavatta | 2021-08-23 20:51:15 +0000 |
---|---|---|
committer | Emiliano Ciavatta | 2021-08-23 20:51:15 +0000 |
commit | c29a8cbfa90903838ab0fdea0fa673df9c0976d3 (patch) | |
tree | 2be118fdf6e8ba257492c8ef174ab7cf60a2dc6e /frontend/src/components | |
parent | dded53f3450b41b358674ea41e9f078fb0d4391f (diff) | |
parent | 8491d5d9aedbb8855e261b9592df8a8ec81b0e5d (diff) |
Merge branch 'hotfix/1.21.1' into main
Diffstat (limited to 'frontend/src/components')
-rw-r--r-- | frontend/src/components/panels/StreamsPane.js | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/frontend/src/components/panels/StreamsPane.js b/frontend/src/components/panels/StreamsPane.js index 8276949..82efd88 100644 --- a/frontend/src/components/panels/StreamsPane.js +++ b/frontend/src/components/panels/StreamsPane.js @@ -145,7 +145,7 @@ class StreamsPane extends Component { pattern["dot_all"] && (flags += "s"); pattern["multi_line"] && (flags += "m"); pattern["unicode_property"] && (flags += "u"); - const regex = new RegExp("(" + pattern.regex + ")", flags); + const regex = new RegExp(pattern.regex.replace(/^\//, '(').replace(/\/$/, ')'), flags); streamContent = reactStringReplace(streamContent, regex, (match, i) => ( <span key={i} className="matched-occurrence" style={{"backgroundColor": rule.color}}>{match}</span> )); |