Activate tabs based on browser's operating system (#1216) · python/devguide@01cb216 · GitHub
Skip to content

Commit 01cb216

Browse files
authored
Activate tabs based on browser's operating system (#1216)
1 parent e95f908 commit 01cb216

4 files changed

Lines changed: 61 additions & 0 deletions

File tree

_static/activate_tab.js

Lines changed: 42 additions & 0 deletions

conf.py

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -45,6 +45,9 @@
4545
html_css_files = [
4646
'devguide_overrides.css',
4747
]
48+
html_js_files = [
49+
"activate_tab.js",
50+
]
4851
html_logo = "_static/python-logo.svg"
4952
html_favicon = "_static/favicon.png"
5053

index.rst

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2,6 +2,14 @@
22
Python Developer's Guide
33
========================
44

5+
.. raw:: html
6+
7+
<script>
8+
document.addEventListener('DOMContentLoaded', function() {
9+
activateTab(getOS());
10+
});
11+
</script>
12+
513
.. highlight:: bash
614

715
This guide is a comprehensive resource for :ref:`contributing <contributing>`

testing/run-write-tests.rst

Lines changed: 8 additions & 0 deletions

0 commit comments

Comments
 (0)