You can search the contents of public repos from the main search box (https://github.com/search has instructions on how), and the search bar on private repos is only intended as a workaround for the main search not working for them. I have no idea how it's taken them this long to figure out that the repo-specific search box is far more user-friendly and discoverable.