Skip to content

Commit

Permalink
Merge pull request #33 from dalthviz/sidebar_widgets
Browse files Browse the repository at this point in the history
PR: Update sidebar to include sidebars templates
  • Loading branch information
dalthviz authored Aug 30, 2020
2 parents 103c581 + b06eba9 commit bfc3e46
Show file tree
Hide file tree
Showing 8 changed files with 43 additions and 26 deletions.
5 changes: 5 additions & 0 deletions docs/conf.py
Original file line number Diff line number Diff line change
Expand Up @@ -90,6 +90,11 @@
"doc_path": "docs",
}

html_sidebars = {
"**": [
]
}

# Add any paths that contain custom static files (such as style sheets) here,
# relative to this directory. They are copied after the builtin static files,
# so a file named "default.css" will overwrite the builtin "default.css".
Expand Down
16 changes: 14 additions & 2 deletions pandas_sphinx_theme/docs-sidebar.html
Original file line number Diff line number Diff line change
@@ -1,5 +1,10 @@

<div class="d-none d-xl-block">
{%- if sidebars %}
{%- for sidebartemplate in sidebars %}
{%- include sidebartemplate %}
{%- endfor %}
{%- endif %}
<form class="bd-search d-flex align-items-center" action="{{ pathto('search') }}" method="get">
<div class="input-group">
<input type="search" class="form-control" name="q" id="search-input" placeholder="Search ..." aria-label="Search the docs ..." autocomplete="off" >
Expand Down Expand Up @@ -61,7 +66,14 @@
</nav>

<nav class="d-block d-xl-none" aria-label="Main navigation">
<div class="bd-toc-item active row">
{%- if sidebars %}
{%- for sidebartemplate in sidebars %}
<div class="bd-toc-item active row px-3">
{%- include sidebartemplate %}
</div>
{%- endfor %}
{%- endif %}
<div class="bd-toc-item active row px-3">
{% set nav = get_nav_object(maxdepth=3) %}
<h4 id="topics-header">Topics</h4>
<select id="small-dropdown" class="nav bd-sidenav">
Expand All @@ -82,4 +94,4 @@ <h4 id="topics-header">Topics</h4>
{% endfor %}
</select>
</div>
</nav>
</nav>
2 changes: 1 addition & 1 deletion pandas_sphinx_theme/static/css/spyder.css

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

2 changes: 1 addition & 1 deletion pandas_sphinx_theme/static/css/theme.css

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

Loading

0 comments on commit bfc3e46

Please sign in to comment.