Skip to content

Commit bb6ca67

Browse files
committed
render the intro links dynamically
1 parent 592f139 commit bb6ca67

1 file changed

Lines changed: 7 additions & 15 deletions

File tree

layouts/product-landing.html

Lines changed: 7 additions & 15 deletions
Original file line numberDiff line numberDiff line change
@@ -22,23 +22,15 @@ <h1 class="mb-3 font-mktg">
2222
</h1>
2323
<div class="lead-mktg color-text-secondary">{{ page.intro }}</div>
2424

25-
{% if page.introLinks.quickstart and page.introLinks.quickstart != '' %}
26-
<a href="/{{ currentLanguage }}{% if currentVersion != 'free-pro-team@latest' %}/{{ currentVersion }}{% endif %}{{ page.introLinks.quickstart }}" class="btn-mktg btn-large f4 mt-3 mr-3">
27-
{% data ui.product_landing.quick_start %}
25+
{% for introLinkType in page.introLinks %}
26+
{% if introLinkType[1] != '' %}
27+
{% unless introLinkType[0] contains 'raw' %}
28+
<a href="/{{ currentLanguage }}{% if currentVersion != 'free-pro-team@latest' %}/{{ currentVersion }}{% endif %}{{ page.introLinks[introLinkType[0]] }}" class="btn-mktg {% unless forloop.first %}btn-outline-mktg {% endunless %}btn-large f4 mt-3 mr-3">
29+
{% data ui.product_landing[introLinkType[0]] %}
2830
</a>
31+
{% endunless %}
2932
{% endif %}
30-
31-
{% if page.introLinks.reference and page.introLinks.reference != '' %}
32-
<a href="/{{ currentLanguage }}{% if currentVersion != 'free-pro-team@latest' %}/{{ currentVersion }}{% endif %}{{ page.introLinks.reference }}" class="btn-mktg btn-outline-mktg btn-large f4 mt-3 mr-3">
33-
{% data ui.product_landing.reference_guides %}
34-
</a>
35-
{% endif %}
36-
37-
{% if page.introLinks.overview and page.introLinks.overview != '' %}
38-
<a href="/{{ currentLanguage }}{% if currentVersion != 'free-pro-team@latest' %}/{{ currentVersion }}{% endif %}{{ page.introLinks.overview }}" class="btn-mktg btn-outline-mktg btn-large f4 mt-3 mr-3">
39-
{% data ui.product_landing.overview %}
40-
</a>
41-
{% endif %}
33+
{% endfor %}
4234
</div>
4335

4436
{% if page.product_video and page.product_video != '' %}

0 commit comments

Comments
 (0)