Add link to 'Stable' doc version in the Warning Alert on top
As discussed on discord in #documentation channel here
I think this will provide 'further convenience' to website users to upgrade the documentation version by simply clicking on the link in the warning itself as well:
Current Behavior of the Warning Alert on Top:
Proposed change (text can be adjusted accordingly):
Rationale:
- The warning alert already exists, and draws eye attention towards itself (due to its bright color)
- Adding a clickable link is 'further convenience' in terms of UX
- Requires small change in code
Hi, I’m trying to contribute to this issue. I noticed that the warning banner for the development version isn’t located in docs/_templates or conf.py. Is this injected via ReadTheDocs config or the sphinx-version-warning extension? If so, would it be appropriate to update it via the RTD config or do you expect it somewhere else?
I had a look at the .readthedocs.yml file and didn’t see any explicit version-warning setting, so it seems like the “Development Version” banner is automatically added by Read the Docs based on the branch.
To add a link to the stable docs in that banner, would you prefer one of the following approaches?
Adding a small Sphinx extension in docs/ that detects if it’s a dev build and injects a custom banner with the link, or
Overriding the layout.html template to include the link conditionally ? so which one should i go with
Really enjoying working on my first issue
@AyushPatiTripathi Please let the existing author know first if you are willing to take over an issue.
This message is a part of a template file. I pushed my changes here: https://github.com/django/djangoproject.com/pull/2101. It will need a styling update; feel free to take over.
@ulgens Thanks for the update ,I saw your note and appreciate the work you've already done I’d be happy to continue from here and finalize the changes.
kindly assign this to mee