Minor fixes to navbar
This commit is contained in:
parent
edc854aa3a
commit
39745a9224
@ -21,7 +21,6 @@ last_updated: false # set to true if you want to display last updated in the foo
|
||||
|
||||
navbar_fixed: true
|
||||
footer_fixed: false
|
||||
social_icons_pos: bottom
|
||||
# TODO: add layout settings (single page vs. multi-page)
|
||||
|
||||
# -----------------------------------------------------------------------------
|
||||
@ -80,7 +79,7 @@ news_limit: 5
|
||||
|
||||
# Build settings
|
||||
markdown: kramdown
|
||||
highlighter: pygments
|
||||
highlighter: rouge
|
||||
|
||||
# Includes & excludes
|
||||
include: ['_pages']
|
||||
@ -125,12 +124,12 @@ scholar:
|
||||
# -----------------------------------------------------------------------------
|
||||
|
||||
enable_google_analytics: false
|
||||
enable_highlight: true
|
||||
enable_highlight: false
|
||||
enable_katex: true
|
||||
enable_mansory: false
|
||||
enable_progressbar: false
|
||||
enable_tooltips: false
|
||||
show_social_icons: true
|
||||
show_social_icons: false
|
||||
|
||||
# -----------------------------------------------------------------------------
|
||||
# Library versions
|
||||
|
@ -6,7 +6,7 @@
|
||||
{% if page.title != "about" %}
|
||||
{% assign name = site.title | split: ' ' %}
|
||||
<a class="navbar-brand title font-weight-lighter" href="{{ site.baseurl | prepend: site.url }}/"><span class="font-weight-bold">{{ name | first }}</span> {{ name | last }}</a>
|
||||
{% elsif site.social_icons_pos == 'top' %}
|
||||
{% elsif site.show_social_icons %}
|
||||
<!-- Social Icons -->
|
||||
<div class="row ml-1 ml-sm-0">
|
||||
{% include social.html %}
|
||||
@ -21,7 +21,8 @@
|
||||
</button>
|
||||
<div class="collapse navbar-collapse text-right" id="navbarNav">
|
||||
<ul class="navbar-nav ml-auto flex-nowrap">
|
||||
<li class="nav-item {% if page.title == 'about' %}navbar-active{% endif %}">
|
||||
<!-- About -->
|
||||
<li class="nav-item {% if page.title == 'about' %}active{% endif %}">
|
||||
<a class="nav-link" href="{{ '/' | prepend: site.baseurl | prepend: site.url }}">
|
||||
about
|
||||
{% if page.title == "about" %}
|
||||
@ -29,17 +30,27 @@
|
||||
{% endif %}
|
||||
</a>
|
||||
</li>
|
||||
<!-- Blog -->
|
||||
<li class="nav-item {% if page.url contains 'blog' %}active{% endif %}">
|
||||
<a class="nav-link" href="{{ '/blog/' | prepend: site.baseurl | prepend: site.url }}">
|
||||
blog
|
||||
{% if page.title == "blog" %}
|
||||
<span class="sr-only">(current)</span>
|
||||
{% endif %}
|
||||
</a>
|
||||
</li>
|
||||
<!-- Other pages -->
|
||||
{% for p in site.pages %}
|
||||
{% if p.title and p.url != "/" %}
|
||||
<li class="nav-item {% if page.nav == p.nav %}navbar-active{% endif %}">
|
||||
<a class="nav-link" href="{{ p.url | prepend: site.baseurl | prepend: site.url }}">
|
||||
{{ p.title }}
|
||||
{% if page.nav == p.nav %}
|
||||
<span class="sr-only">(current)</span>
|
||||
{% endif %}
|
||||
</a>
|
||||
</li>
|
||||
{% endif %}
|
||||
{% if p.title and p.url != "/" %}
|
||||
<li class="nav-item {% if page.title == p.title %}active{% endif %}">
|
||||
<a class="nav-link" href="{{ p.url | prepend: site.baseurl | prepend: site.url }}">
|
||||
{{ p.title }}
|
||||
{% if page.nav == p.nav %}
|
||||
<span class="sr-only">(current)</span>
|
||||
{% endif %}
|
||||
</a>
|
||||
</li>
|
||||
{% endif %}
|
||||
{% endfor %}
|
||||
</ul>
|
||||
</div>
|
||||
|
@ -24,7 +24,7 @@ layout: page
|
||||
{% include news.html %}
|
||||
{% endif %}
|
||||
|
||||
{% if page.social and site.social_icons_pos == 'bottom' %}
|
||||
{% if page.social %}
|
||||
<div class="social">
|
||||
{% include social.html %}
|
||||
<div class="contact-note">{{ site.contact_note }}</div>
|
||||
|
@ -53,6 +53,14 @@ a, table.table a {
|
||||
color: $link-color;
|
||||
}
|
||||
}
|
||||
.navbar-nav .nav-item.active>.nav-link {
|
||||
background-color: inherit;
|
||||
color: $link-color;
|
||||
font-weight: bolder;
|
||||
&:hover {
|
||||
color: $link-color;
|
||||
}
|
||||
}
|
||||
.contact-icon {
|
||||
font-size: 2rem;
|
||||
a {
|
||||
|
Loading…
Reference in New Issue
Block a user