Skip to content

Commit

Permalink
Revert clickable title to Furo default and add ecosystem link under it (
Browse files Browse the repository at this point in the history
#607)

Fixes #604

---------

Co-authored-by: Eric Arellano <[email protected]>
  • Loading branch information
kevinsung and Eric-Arellano authored Jun 19, 2024
1 parent f968969 commit f7e512d
Show file tree
Hide file tree
Showing 4 changed files with 20 additions and 63 deletions.
15 changes: 15 additions & 0 deletions src/qiskit_sphinx_theme/assets/styles/_left-sidebar.scss
Original file line number Diff line number Diff line change
Expand Up @@ -49,6 +49,21 @@ body {
width: 100%;
}

.sidebar-ecosystem-link {
padding-left: var(--sidebar-item-spacing-horizontal);
font-size: var(--sidebar-caption-font-size);

// Based off of `.sidebar-tree .reference`. Just taking the external link logo.
.reference {
// Add a nice little "external-link" arrow here.
&.external::after {
content: url('data:image/svg+xml,<svg width="12" height="12" xmlns="http://www.w3.org/2000/svg" viewBox="0 0 24 24" stroke-width="1.5" stroke="%23607D8B" fill="none" stroke-linecap="round" stroke-linejoin="round"><path stroke="none" d="M0 0h24v24H0z"/><path d="M11 7h-5a2 2 0 0 0 -2 2v9a2 2 0 0 0 2 2h9a2 2 0 0 0 2 -2v-5" /><line x1="10" y1="14" x2="20" y2="4" /><polyline points="15 4 20 4 20 9" /></svg>');
margin: 0 0.25rem;
vertical-align: middle;
}
}
}

// --------------------------------------------------------------------------------------
// Common config for Translations & Previous Releases
// --------------------------------------------------------------------------------------
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -2,22 +2,7 @@
This file is inspired by Furo (created by Pradyun Gedam) and used under the MIT license.
-#}


{#- We default to showing a Qiskit Ecosystem logo -#}
{%- if not logo_url and not theme_light_logo and not theme_dark_logo and not theme_disable_ecosystem_logo -%}
<div class="sidebar-brand">
<a href="https://qiskit.github.io/ecosystem/">
<div class="sidebar-logo-container">
<img class="sidebar-logo" src="{{ pathto('_static/images/ecosystem-logo.svg', 1) }}" alt="Qiskit Ecosystem logo"/>
</div>
</a>
{% if not theme_sidebar_hide_name %}
<span class="sidebar-brand-text">{{ docstitle if docstitle else project }}</span>
{%- endif %}
</div>

{#- Else, use Furo's sidebar code. But, we remove the `centered` class from the `a` element because Carbon left-aligns things. -#}
{%- else %}
{#- Use Furo's sidebar code. But, we remove the `centered` class from the `a` element because Carbon left-aligns things. -#}
<a class="sidebar-brand" href="{{ pathto(master_doc) }}">
{% block brand_content %}
{%- if logo_url %}
Expand All @@ -36,4 +21,7 @@
{%- endif %}
{% endblock brand_content %}
</a>
{%- endif %}
{#- Add a link to the Qiskit ecosystem web page. -#}
<p class="sidebar-ecosystem-link">
This project is part of the <a class="reference external" href="https://qiskit.github.io/ecosystem/">Qiskit ecosystem</a>
</p>

This file was deleted.

Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.

0 comments on commit f7e512d

Please sign in to comment.