Skip to content

Commit f05ff4d

Browse files
Merge pull request #614 from laughingman7743/fix-version-selector-selected
fix: Correct version selector to show current version as selected
2 parents 4bb3a7b + ba8ba66 commit f05ff4d

1 file changed

Lines changed: 2 additions & 2 deletions

File tree

docs/_templates/versioning.html

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -4,8 +4,8 @@
44
<div class="version-dropdown" style="margin-bottom: 1rem;">
55
<select onchange="window.location.href = this.value" style="width: 100%; padding: 0.5rem; border: 1px solid var(--color-background-border); border-radius: 0.25rem; background-color: var(--color-background-secondary); color: var(--color-foreground-primary); font-size: var(--font-size--small); cursor: pointer;">
66
{% for item in versions %}
7-
<option value="{{ item.url }}" {% if item.name == current_version %}selected{% endif %}>
8-
{{ item.name }}{% if item.name == current_version %} (current){% endif %}
7+
<option value="{{ item.url }}" {% if item == current_version %}selected{% endif %}>
8+
{{ item.name }}{% if item == current_version %} (current){% endif %}
99
</option>
1010
{% endfor %}
1111
</select>

0 commit comments

Comments
 (0)