File tree Expand file tree Collapse file tree 3 files changed +20
-5
lines changed Expand file tree Collapse file tree 3 files changed +20
-5
lines changed Original file line number Diff line number Diff line change
1
+ document . addEventListener ( "DOMContentLoaded" , function ( ) {
2
+ // Select all <li> elements with the class "toctree-l1"
3
+ var toctreeItems = document . querySelectorAll ( 'li.toctree-l1' ) ;
4
+ toctreeItems . forEach ( function ( item ) {
5
+ // Check if the item has a nested <ul>
6
+ var nestedList = item . querySelector ( 'ul' ) ;
7
+ if ( nestedList ) {
8
+ // Display the nested list by default
9
+ nestedList . style . display = 'block' ;
10
+ }
11
+ } ) ;
12
+ } ) ;
Original file line number Diff line number Diff line change @@ -238,7 +238,7 @@ def reset_seeds(gallery_conf, fname):
238
238
html_logo = '_static/img/pytorch-logo-dark.svg'
239
239
html_theme_options = {
240
240
'pytorch_project' : 'tutorials' ,
241
- 'collapse_navigation' : True ,
241
+ 'collapse_navigation' : False ,
242
242
'display_version' : True ,
243
243
'navigation_with_keys' : True ,
244
244
'logo_only' : False ,
@@ -308,6 +308,10 @@ def reset_seeds(gallery_conf, fname):
308
308
'css/custom2.css'
309
309
]
310
310
311
+ html_js_files = [
312
+ "js/custom.js" ,
313
+ ]
314
+
311
315
def setup (app ):
312
316
# NOTE: in Sphinx 1.8+ `html_css_files` is an official configuration value
313
317
# and can be moved outside of this function (and the setup(app) function
Original file line number Diff line number Diff line change @@ -915,7 +915,6 @@ Additional Resources
915
915
See All Prototype Recipes <prototype/prototype_index >
916
916
917
917
.. toctree ::
918
- :maxdepth: 3
919
918
:hidden:
920
919
:includehidden:
921
920
:caption: Introduction to PyTorch
@@ -924,7 +923,7 @@ Additional Resources
924
923
beginner/introyt/introyt
925
924
926
925
.. toctree ::
927
- :maxdepth: 2
926
+ :maxdepth: 1
928
927
:hidden:
929
928
:includehidden:
930
929
:caption: Learning PyTorch
@@ -968,7 +967,7 @@ Additional Resources
968
967
intermediate/forced_alignment_with_torchaudio_tutorial
969
968
970
969
.. toctree ::
971
- :maxdepth: 2
970
+ :maxdepth: 1
972
971
:includehidden:
973
972
:hidden:
974
973
:caption: Backends
@@ -987,7 +986,7 @@ Additional Resources
987
986
advanced/pendulum
988
987
989
988
.. toctree ::
990
- :maxdepth: 2
989
+ :maxdepth: 1
991
990
:includehidden:
992
991
:hidden:
993
992
:caption: Deploying PyTorch Models in Production
You can’t perform that action at this time.
0 commit comments