Cause of the bug:
In src/components/Editor/index.js, “sourceSearch.search.again.key2” (
onSearchAgain, which then calls
In src/components/Editor/SearchBar.js, the same key calls
this.props.traverseResults as well.
Thus, the same keyboard shortcut calls the same function twice. So does “sourceSearch.search.againPrev.key2” (
In pull request #1656 (https://github.com/firefox-devtools/debugger/pull/1656), a feature of double-clicking a text token to highlight it was added. Another feature of using
CmdorCtrl+G to jump to the next matching result was also added.
The double-clicking feature is no longer here as I observe in the debugger, but the traversing to other matching results function has been kept.
Keyboard shortcuts related to the file search box are all in SearchBar.js. So I decided to keep the one in SearchBar.js, and remove the one in index.js.