Skip to content

Commit

Permalink
Add main language links in sidebar
Browse files Browse the repository at this point in the history
  • Loading branch information
shaib committed Mar 24, 2024
1 parent f422030 commit bb2ce5c
Show file tree
Hide file tree
Showing 4 changed files with 29 additions and 1 deletion.
5 changes: 5 additions & 0 deletions website_2024/pelicanconf.py
Original file line number Diff line number Diff line change
Expand Up @@ -78,3 +78,8 @@ def get_page_number(page):

}
}

LANGUAGE_NAMES = {
'en': "English",
'he': "עברית",
}
14 changes: 14 additions & 0 deletions website_2024/themes/PyCon-Israel-Flex/static/stylesheet/style.less
Original file line number Diff line number Diff line change
Expand Up @@ -118,6 +118,20 @@ aside {
}
}
}

.translations {
padding-bottom: 0;
text-align: start;

.active {
font-weight: 600;
}
}
.translations:lang(he) {
left: default;
right: 0;
}

}

main {
Expand Down

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

Original file line number Diff line number Diff line change
@@ -1,4 +1,13 @@
<aside>
<div class="translations">
<bdi>
<a class="active" href="{{ SITEURL }}">{{LANGUAGE_NAMES[DEFAULT_LANG]}}</a>
</bdi>
{% for lang,lang_siteurl in extra_siteurls.items() %}
<bdi><a href="{{ lang_siteurl }}/">{{ LANGUAGE_NAMES[lang] }}</a></bdi>
{% endfor %}
</div>

<div>
<a href="{{ SITEURL }}/">
{% if SITELOGO %}
Expand Down

0 comments on commit bb2ce5c

Please sign in to comment.