No-reload file permalink | phase 3 | page updates

This is the third issue (of at least 3) to improve the no-reload file permalink feature.

In this phase, we need to update the entire file view page with at least two changes:

  1. Many links and other UI elements update from the branch name to the SHA permalink
  2. Some UI elements become disabled when viewing the permalink

UI elements that need to be updated

Unfortunately, there isn't a clear way to perform all of these updates across the entire page in a cohesive way. So this update may require some larger architectural work to create a centralized way to do this.

One way we could use to update the links might be to use the rel=canonical attribute for each of the links. However, that may be an abuse of rel=canonical, since the intent of a canonical link is to disambiguate and deduplicate content, and by using that attribute we would be explicitly updating the URL to something else that fundamentally points to the same content. This probably requires some investigation, particularly around other options.

For more context, please see the first phase issue.