The current design prioritizes popular topics, which by their nature tend to be general. Someone hitting a 404 is likely to instead be looking for something specific. Short of magically guessing what that was, it seems like prominently providing a search box would be ideal. I know it’s there at the bottom, but… that’s kind of hard to find.) Is there an easy way to rearrange this?
And while we’re at it, something that stretches across the page rather than the current tiny box at the bottom.
It might also be nice to pre-fill the search with something constructed from the provided not-found URL. But I haven’t thought through the full implications of that.
I think it should be possible by hiding the page-not-found-search component at the bottom with a display: none and then inserting the code for the search box at the top using plugin outlets: Adding to plugin-outlets using a theme
You could also add some CSS to modify the textarea width. Note I haven’t really tested any of this, I just tried it directly in the browser console.
Can you help me figure out what the proper outlet should be here? I’ve used the concept before to add some explanatory text to the Badges page, but Plugin outlet locations theme component does not seem to work on the 404 page and I can’t figure out what to put in the script wrapper.
This works a treat. Time for me to customize it a bit more.
Edit: This has caused errors to be thrown into my error log.
TypeError: null is not an object (evaluating 'x.item(0).innerHTML') Url: https://mysite.com/theme-javascripts/33ba1ce8896576423974ff03c875fe32931690cc.js?__ws=mysite.com Line: 2
By looking at olds commit, the position of the search bar seems to be something that just happened? Inherited from where the google search used to be, which was added with the initial release of Discourse.