Fixed spacing issues when using toc.integrate in non-nested tabs

This commit is contained in:
squidfunk 2021-10-17 11:43:07 +02:00
parent 3c130ee1d6
commit f073fb2c25
6 changed files with 25 additions and 11 deletions

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

View File

@ -39,7 +39,7 @@
{% endif %} {% endif %}
{% endblock %} {% endblock %}
{% block styles %} {% block styles %}
<link rel="stylesheet" href="{{ 'assets/stylesheets/main.5143246d.min.css' | url }}"> <link rel="stylesheet" href="{{ 'assets/stylesheets/main.5d519cf3.min.css' | url }}">
{% if config.theme.palette %} {% if config.theme.palette %}
{% set palette = config.theme.palette %} {% set palette = config.theme.palette %}
<link rel="stylesheet" href="{{ 'assets/stylesheets/palette.3f5d1f46.min.css' | url }}"> <link rel="stylesheet" href="{{ 'assets/stylesheets/palette.3f5d1f46.min.css' | url }}">

View File

@ -654,14 +654,28 @@
} }
// Modifier for when table of contents is rendered in primary navigation // Modifier for when table of contents is rendered in primary navigation
&--integrated &__link[for="__toc"] ~ .md-nav { &--integrated > .md-nav__list > .md-nav__item--active {
display: block;
margin-bottom: 1.25em;
border-left: px2rem(1px) solid var(--md-primary-fg-color);
// Hide navigation title // Add spacing to container for non-nested navigation items
> .md-nav__title { &:not(.md-nav__item--nested) {
display: none; padding: 0 px2rem(12px);
// Remove padding as it's given by container
> .md-nav__link {
padding: 0;
}
}
// Show integrated table of contents
.md-nav--secondary {
display: block;
margin-bottom: 1.25em;
border-left: px2rem(1px) solid var(--md-primary-fg-color);
// Hide table of contents title
> .md-nav__title {
display: none;
}
} }
} }
} }