mirror of
https://github.com/Shopify/liquid.git
synced 2026-09-15 08:50:45 -07:00
Uncomplicate the sidebar
This commit is contained in:
@@ -1,6 +1,6 @@
|
||||
<header class="home--banner">
|
||||
<h1>Liquid</h1>
|
||||
<p>Ruby library for rendering safe templates which cannot affect the security of the server they are rendered on.</p>
|
||||
<p>Safe, customer facing template language for flexible web apps.</p>
|
||||
<p class="btn-row">
|
||||
<a href="https://github.com/Shopify/liquid/archive/master.zip" target="_blank" class="btn"><i class="icon fa fa-2x fa-arrow-circle-down"></i>Download</a>
|
||||
<a href="https://github.com/Shopify/liquid" target="_blank" class="btn"><i class="icon fa fa-2x fa-github"></i>View on Github</a>
|
||||
|
||||
+7
-17
@@ -2,25 +2,15 @@
|
||||
<div class="sidebar--logo">
|
||||
<a href="/">Liquid</a>
|
||||
</div>
|
||||
<nav class="sidebar--nav">
|
||||
|
||||
{% capture folders %}basics,tags,filters{% endcapture %}
|
||||
{% assign sections = folders | split: "," %}
|
||||
<nav class="sidebar--nav"> {% assign sections = "basics, tags, filters" | split: ", " %}
|
||||
|
||||
{% for section in sections %}
|
||||
<ul class="section">
|
||||
<li>
|
||||
<h3 class="section__header">{{ section | capitalize }}</h3>
|
||||
<ul class="section__links">
|
||||
{% for page in site.pages %}
|
||||
{% if page.path contains section/ %}
|
||||
{% unless page.path contains "index.html" %}
|
||||
<li><a href="{{ page.url | prepend: site.baseurl }}" class="section__link">{{ page.title }}</a></li>
|
||||
{% endunless %}
|
||||
{% endif %}
|
||||
{% endfor %}
|
||||
</ul>
|
||||
</li>
|
||||
<h3 class="section__header">{{ section | capitalize }}</h3>
|
||||
|
||||
<ul class="section__links">
|
||||
{% for page in site.pages %}{% if page.url contains section/ %}{% unless page.path contains "index" %}
|
||||
<li><a href="{{ page.url | prepend: site.baseurl }}" class="section__link">{{ page.title }}</a></li>
|
||||
{% endunless %}{% endif %}{% endfor %}
|
||||
</ul>
|
||||
{% endfor %}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user