Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[switcher] default activeVersion and activeVersionName values #654

Merged
merged 3 commits into from May 6, 2022

Conversation

tupui
Copy link
Contributor

@tupui tupui commented May 5, 2022

In PRs, I find it handy to have the PR indicator as the version name in the switcher.

But then, because there is no entry in the json, the button is missing the dataset attributes activeVersion and activeVersionName. This PR adds a default empty string (and from codes I could see, this seems to be standard).

This would allow to have access to an empty dataset attribute and use it as CSS selector.

Use case in NumPy here: numpy/numpy#21451
And I would do the same for SciPy if this behaviour is confirmed 😃

…ersion-switcher.html

Co-authored-by: Chris Holdgraf <choldgraf@gmail.com>
…ersion-switcher.html

Co-authored-by: Chris Holdgraf <choldgraf@gmail.com>
@choldgraf choldgraf changed the title Default activeVersion and activeVersionName for version switcher [switcher] default activeVersion and activeVersionName values May 6, 2022
@choldgraf choldgraf merged commit f5b047e into pydata:master May 6, 2022
@tupui tupui deleted the version_switcher_default branch May 6, 2022 08:50
@tupui
Copy link
Contributor Author

tupui commented May 6, 2022

Thank you Chris 😃

@jarrodmillman jarrodmillman added this to the 0.9 milestone Jun 2, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

3 participants