mirror of
https://github.com/seigler/dash-website
synced 2025-07-27 07:16:10 +00:00
* Remove style-guide from i18n builds * Remove uncategorized from CN blog posts. * Team images and alt attributes. * Fixing language linkage * Ignore missing or empty alt tags * ignore sass-cache * fix gitignore for sass-cache * fix gitignore for sass-cache * Only show language dropdown if the page is not a post (blog) * New url with site.lang included. * Removed the site.baseurl var from the posts.
18 lines
No EOL
695 B
HTML
18 lines
No EOL
695 B
HTML
<!--
|
|
Include this file in your templates so you can reference assets with relative urls
|
|
include base.html
|
|
example: href="{{ base }}/assets/css/style.css"
|
|
-->
|
|
{% assign base = '' %}
|
|
{% assign depth = page.url | split: '/' | size | minus: 1 %}
|
|
{% if depth == -1 %}{% assign base = '.' %}
|
|
{% elsif depth == 1 %}{% assign base = '..' %}
|
|
{% elsif depth == 2 %}{% assign base = '../..' %}
|
|
{% elsif depth == 3 %}{% assign base = '../../..' %}
|
|
{% elsif depth == 4 %}{% assign base = '../../../..' %}{% endif %}
|
|
|
|
{% if site.lang != "en" %}
|
|
{% assign base = base | prepend: '../' %}
|
|
{% endif %}
|
|
|
|
{% capture basenav %}{% if site.lang != "en" %}/{{ site.lang }}{% else %}{% endif %}{% endcapture %} |