Skip to content

Commit

Permalink
Improve version verbiage
Browse files Browse the repository at this point in the history
The most common case is now cleaner:

    version: stable → nothing

The meaning of "latest" is now clearer:

    version: latest → development version

and a useless colon is dropped:

    version: X → version X

Versions are always always on their own (centered) line now underneath
the subproject name, instead of potentially sitting alongside them for
short names (like "CLI").
  • Loading branch information
tsibley committed Jan 27, 2022
1 parent f20aa26 commit baaaef0
Show file tree
Hide file tree
Showing 2 changed files with 10 additions and 4 deletions.
12 changes: 9 additions & 3 deletions lib/nextstrain/sphinx/theme/layout.html
Original file line number Diff line number Diff line change
Expand Up @@ -45,9 +45,15 @@
{%- set nav_version = current_version %}
{% endif %}
{% if nav_version %}
<span>
version: {{ nav_version }}
</span>
<div class="version">
{% if nav_version == "stable" %}
{# don't show anything #}
{% elif nav_version == "latest" %}
development version
{% else %}
version {{ nav_version }}
{% endif %}
</div>
{% endif %}

</div>
Expand Down
2 changes: 1 addition & 1 deletion lib/nextstrain/sphinx/theme/static/css/nextstrain.css
Original file line number Diff line number Diff line change
Expand Up @@ -85,7 +85,7 @@ footer span.commit code,
font-weight: 500;
color: var(--heading-color);
}
.wy-side-nav-search > div.subproject > span { /* version name */
.wy-side-nav-search > div.subproject > .version { /* version name */
display: inline-block;
font-size: 1.1rem;
font-weight: 300;
Expand Down

0 comments on commit baaaef0

Please sign in to comment.