(v2) Make version switching to be aware of the current page #2923
Labels
difficulty: advanced
Issues that are complex, e.g. large scoping for long-term maintainability.
feature
This is not a bug or issue with Docusausus, per se. It is a feature request for the future.
🚀 Feature
I really like the ability to switch version from the top header without going into another page. It'd be great if switching to another version would go to the same page of the target version as the source page (where I'm currently switching from).
Have you read the Contributing Guidelines on issues?
Yes
Motivation
This will make the UX to be much more intuitive. Right now switching version automatically goes to the root/main docs page. But, because of the version drop-down menu from the header, I can select a different version from any page, as show below:
But, switching version while in that page, changes my context because I'm taken to the first doc page.
Pitch
(Please explain why this feature should be implemented and how it would be used.)
Since we know the current page from the address bar when switching version, I think we should be able to easily go to the corresponding page in the target version.
Of course there are some edge cases where this would not work. For example, the page may not exist in the target version because doc did not exist or had changed it's filename/path. For the first iteration of this feature, it might make sense to follow the existing process (go to the first doc). In that case, it would be nice if the user can be notified via the notification bar at the top. The notification will advise that the file/doc/path does not exist in the currently selected version.
The text was updated successfully, but these errors were encountered: