Add conditional avatar
This commit is contained in:
parent
b997416526
commit
726508dd95
@ -129,6 +129,7 @@ css | List of local CSS files to include in the page
|
|||||||
ex-css | List of external CSS files to include in the page
|
ex-css | List of external CSS files to include in the page
|
||||||
googlefonts | List of Google fonts to include in the page (eg. `["Monoton", "Lobster"]`)
|
googlefonts | List of Google fonts to include in the page (eg. `["Monoton", "Lobster"]`)
|
||||||
fb-img | If you want to share a page on Facebook, by default Facebook will use the first image it can find on the page. If you want to specify an image to use when sharing the page on Facebook, then provide the image's URL here
|
fb-img | If you want to share a page on Facebook, by default Facebook will use the first image it can find on the page. If you want to specify an image to use when sharing the page on Facebook, then provide the image's URL here
|
||||||
|
show_avatar | If you have an avatar configured in the _config.yml but you don't want to appear on every page you can turn it off by removing this flag from the default layout (_layouts/default.html) and enable it only on the pages where you want to. Note: the specific value doesn't matter only whether it's defined or not.
|
||||||
|
|
||||||
### RSS feed
|
### RSS feed
|
||||||
|
|
||||||
|
@ -22,7 +22,7 @@
|
|||||||
{% assign internal = false %}
|
{% assign internal = false %}
|
||||||
{% endif %}
|
{% endif %}
|
||||||
{% endif %}
|
{% endif %}
|
||||||
|
|
||||||
{% if internal %}
|
{% if internal %}
|
||||||
{% capture linkurl %}{{ site.baseurl }}/{{ link[1] }}{% endcapture %}
|
{% capture linkurl %}{{ site.baseurl }}/{{ link[1] }}{% endcapture %}
|
||||||
{% else %}
|
{% else %}
|
||||||
@ -34,8 +34,8 @@
|
|||||||
{% endfor %}
|
{% endfor %}
|
||||||
</ul>
|
</ul>
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
{% if site.avatar %}
|
{% if site.avatar and page.show-avatar %}
|
||||||
<div class="avatar-container">
|
<div class="avatar-container">
|
||||||
<div class="avatar-img-border">
|
<div class="avatar-img-border">
|
||||||
<a href="{{ site.url }} ">
|
<a href="{{ site.url }} ">
|
||||||
@ -44,6 +44,6 @@
|
|||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
{% endif %}
|
{% endif %}
|
||||||
|
|
||||||
</div>
|
</div>
|
||||||
</nav>
|
</nav>
|
||||||
|
@ -1,4 +1,5 @@
|
|||||||
---
|
---
|
||||||
|
show-avatar: true
|
||||||
common-css:
|
common-css:
|
||||||
- "/css/bootstrap.min.css"
|
- "/css/bootstrap.min.css"
|
||||||
- "/css/main.css"
|
- "/css/main.css"
|
||||||
@ -15,11 +16,11 @@ common-js:
|
|||||||
|
|
||||||
<!DOCTYPE html>
|
<!DOCTYPE html>
|
||||||
<html lang="en">
|
<html lang="en">
|
||||||
|
|
||||||
{% include head.html %}
|
{% include head.html %}
|
||||||
|
|
||||||
<body>
|
<body>
|
||||||
|
|
||||||
{% include nav.html %}
|
{% include nav.html %}
|
||||||
|
|
||||||
<div role="main" class="container main-content">
|
<div role="main" class="container main-content">
|
||||||
@ -27,8 +28,8 @@ common-js:
|
|||||||
</div>
|
</div>
|
||||||
|
|
||||||
{% include footer.html %}
|
{% include footer.html %}
|
||||||
|
|
||||||
{% include footer-scripts.html %}
|
{% include footer-scripts.html %}
|
||||||
|
|
||||||
</body>
|
</body>
|
||||||
</html>
|
</html>
|
||||||
|
Loading…
Reference in New Issue
Block a user