File browse improvements

This should be the final block of work on this. Makes sure all the navigation items build the path correctly as well as adding some fixes for edge cases where file links were produced incorrectly.

There's also a tweak to the route matching to ensure namespace and file are present on a fileedit link.