There should be no such thing as visual mode for diffs of non-wikitext pages. So these buttons should be hidden.
Steps to Reproduce:
- Enable VisualDiff beta feature.
- Visit a diff both in mobile mode and desktop mode. eg. https://www.mediawiki.org/w/index.php?title=MediaWiki:Gadget-rtrc.js&diff=2175617 and https://m.mediawiki.org/wiki/Special:MobileDiff/2175617.
- Compare them
Results:
The two toggle buttons unexpectedly appear in the mobile diff page while they are missing from the desktop diff page.