Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
10 changes: 10 additions & 0 deletions docs/user_guide/configuring.rst
Original file line number Diff line number Diff line change
Expand Up @@ -19,6 +19,16 @@ doc path's _static folder, and use the following configuration:

html_logo = "_static/logo.png"

The logo links to ``master_doc`` (usually the first page of your documentation) by default.
If you'd like it to link to another page or use an external link instead, use the following configuration:

.. code:: python

html_theme_options = {
"logo_link": "<other page or external link>"
}


Configure social media buttons
==============================

Expand Down
20 changes: 17 additions & 3 deletions pydata_sphinx_theme/docs-navbar.html
Original file line number Diff line number Diff line change
@@ -1,13 +1,27 @@

<div class="container-xl">

<a class="navbar-brand" href="{{ pathto(master_doc) }}">

{% if logo %}
<img src="{{ pathto('_static/' + logo, 1) }}" class="logo" alt="logo" />
{% if not theme_logo_link %}
<a class="navbar-brand" href="{{ pathto(master_doc) }}">
<img src="{{ pathto('_static/' + logo, 1) }}" class="logo" alt="logo">
</a>
{% elif theme_logo_link[:4] == 'http' %}
<a class="navbar-brand" href="{{ theme_logo_link }}">
<img src="{{ pathto('_static/' + logo, 1) }}" class="logo" alt="logo">
</a>
{% else %}
<a class="navbar-brand" href="{{ pathto(theme_logo_link) }}">
<img src="{{ pathto('_static/' + logo, 1) }}" class="logo" alt="logo">
</a>
{% endif %}
{% else %}
<a class="navbar-brand" href="{{ pathto(master_doc) }}">
<p class="title">{{ project }}</p>
{% endif %}
</a>
{% endif %}

<button class="navbar-toggler" type="button" data-toggle="collapse" data-target="#navbar-menu" aria-controls="navbar-menu" aria-expanded="false" aria-label="Toggle navigation">
<span class="navbar-toggler-icon"></span>
</button>
Expand Down
1 change: 1 addition & 0 deletions pydata_sphinx_theme/theme.conf
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,7 @@ sidebarwidth = 270
sidebar_includehidden = True
use_edit_page_button = False
external_links =
logo_link =
github_url =
twitter_url =
google_analytics_id =
Expand Down