browse/directory: Fix invalid content links and update display
Directories do not have permissions bits set in SWH data model so remove their display as it is confusing.
When browsing a non root directory in an origin context, the path query parameter value for directory content links was invalid due to dicts not merged in the right order.
Closes T2677
Migrated from D4224 (view on Phabricator)