Hi. I have encountered some bugs with the Wikipedia (via Mediawiki) embedding of codemirror (accessed by Edit Source and selecting Syntax option). One of the bugs is also present in the search and replace demo:
I assume that a more complete implementation than the Demo does not have this problem, but anyone knows what makes the completion work perhaps I can relay the info to MediaWiki developers.
Version 6 has a much better implementation of the search panel. It’s been stable for over 4 years, so I’d say the way forward for any project still using 5.x but running into issues with it would be to upgrade.
The v6 demo Try CodeMirror places the Find/Replace dialog at the bottom. Wikipedia places this dialog at the top (like the cm v5 demo). The first bug I am trying to narrow down is a failure to scroll to match because the match is underneath the dialog.
Two matches in the doc appear at the very top and somewhere down lower. The first find works because the content is displayed below the dialog. The second find works. The third find will cycle back to the first match, but the dialog now covers the match and scrolling it in to view does not happen. If that makes any sense.
As far as I can tell so far they use your scrollToMatch() and EditorView.scrollIntoView(). But something they supply is off. I need to find where their embedding code is I guess.