diff --git a/includes/breadcrumbs.html b/includes/breadcrumbs.html index 2a08fecb22..e623d9c568 100644 --- a/includes/breadcrumbs.html +++ b/includes/breadcrumbs.html @@ -1,3 +1,16 @@ +{% if FEATURE_NEW_SITETREE %} + +{% else %} +{% endif %} \ No newline at end of file diff --git a/includes/category-articles-list.html b/includes/category-articles-list.html new file mode 100644 index 0000000000..27e2cdd7f7 --- /dev/null +++ b/includes/category-articles-list.html @@ -0,0 +1,34 @@ +{% for categoryPage in currentProductTree.childPages %} +{% if categoryPage.href == currentPath %}{% assign currentCategory = categoryPage %}{% endif %} +{% endfor %} + +{% if currentCategory.page.shortTitle and currentCategory.page.shortTitle != '' %}{% assign currentCategoryTitle = currentCategory.page.shortTitle %}{% else %}{% assign currentCategoryTitle = currentCategory.page.title %}{% endif %} + +{% assign maxArticles = 10 %} + +
+

{{ currentCategoryTitle }} docs

+ +
+ {% for childPage in currentCategory.childPages %} + {% unless childPage.page.hidden %} +
+

{{ childPage.page.title }}

+
    + {% for grandchildPage in childPage.childPages %} +
  • + + {{ grandchildPage.page.title }} + +
  • + {% endfor %} + {% assign numArticles = childPage.childPages | obj_size %} + {% if numArticles > maxArticles %} + + {% endif %} +
+
+ {% endunless %} + {% endfor %} +
+
diff --git a/includes/generic-toc.html b/includes/generic-toc.html new file mode 100644 index 0000000000..0e9820dcb2 --- /dev/null +++ b/includes/generic-toc.html @@ -0,0 +1,8 @@ +{% for tocItem in tocItems %} + + + + +{% if tocItem.intro %}{% endif %} + +{% endfor %} \ No newline at end of file diff --git a/includes/product-articles-list.html b/includes/product-articles-list.html new file mode 100644 index 0000000000..de0bec3356 --- /dev/null +++ b/includes/product-articles-list.html @@ -0,0 +1,46 @@ +{% assign maxArticles = 10 %} + +{% if currentProductTree.page.shortTitle and currentProductTree.page.shortTitle != '' %}{% assign productTitle = currentProductTree.page.shortTitle %}{% else %}{% assign productTitle = currentProductTree.page.title %}{% endif %} + +
+

All {{ productTitle }} docs

+ +
+ {% for childPage in currentProductTree.childPages %} + {% if childPage.page.documentType == "article" %}{% assign standaloneCategory = true %}{% else %}{% assign standaloneCategory = false %}{% endif %} + {% unless standaloneCategory %} +
+

{{ childPage.page.title }}

+ + {% if childPage.childPages and childPage.childPages[0].page.documentType == "mapTopic" %} +
    + {% for grandchildPage in childPage.childPages %} + {% unless grandchildPage.page.hidden %} + {% assign numArticles = childPage.childPages | obj_size %} +
  • + + {{ grandchildPage.page.title }} + +
  • + {% if numArticles > maxArticles %} + + {% endif %} + {% endunless %} + {% endfor %} +
+ {% else %} +
    + {% assign numArticles = childPage.childPages | obj_size %} + {% for grandchildPage in childPage.childPages %} +
  • {{ grandchildPage.page.title }}
  • + {% endfor %} +
+ {% if numArticles > maxArticles %} + + {% endif %} + {% endif %} +
+ {% endunless %} + {% endfor %} +
+
diff --git a/includes/sidebar-product.html b/includes/sidebar-product.html new file mode 100644 index 0000000000..33a9951375 --- /dev/null +++ b/includes/sidebar-product.html @@ -0,0 +1,71 @@ + + +{% include all-products-link %} + +{% unless currentProductTree.page.hidden %} + +{% if currentProductTree.page.shortTitle and currentProductTree.page.shortTitle != '' %}{% assign productTitle = currentProductTree.page.shortTitle %}{% else %}{% assign productTitle = currentProductTree.page.title %}{% endif %} + + +
  • + +
  • + +{% endunless %} diff --git a/includes/sidebar.html b/includes/sidebar.html index 74f1c94cc5..470a26208f 100644 --- a/includes/sidebar.html +++ b/includes/sidebar.html @@ -15,7 +15,11 @@ {% else %} {% endif %} diff --git a/layouts/generic-toc.html b/layouts/generic-toc.html new file mode 100644 index 0000000000..e4bfbe1343 --- /dev/null +++ b/layouts/generic-toc.html @@ -0,0 +1,58 @@ + + + {% include head %} + + + {% include sidebar %} + +
    + {% include header %} + {% include deprecation-banner %} +
    +
    +
    +
    {% include article-version-switcher %}
    + +
    {% include article-version-switcher %}
    +
    + +
    + +
    +
    +

    {{ page.title }}

    +
    + +
    +
    + + {% if page.intro %} +
    {{ page.intro }}
    + {% endif %} + + {% if page.product %} +
    + {{ page.product }} +
    + {% endif %} +
    +
    + {% if featuredLinks.gettingStarted and featuredLinks.popular %} + {% include featured-links %} + {% endif %} + + {% include generic-toc %} +
    +
    +
    +
    + {% include support-section %} + {% include small-footer %} + {% include scroll-button %} +
    + + \ No newline at end of file diff --git a/layouts/product-landing.html b/layouts/product-landing.html index 6d0cf95a13..8f919276e9 100644 --- a/layouts/product-landing.html +++ b/layouts/product-landing.html @@ -138,11 +138,22 @@ {% endif %}
    + {% if FEATURE_NEW_SITETREE %} + {% if page.documentType == "category" %} + {% include category-articles-list %} + {% endif %} + {% if page.documentType == "product" %} + {% include product-articles-list %} + {% endif %} + {% endif %} + + {% unless FEATURE_NEW_SITETREE %} {% if currentCategory %} {% include all-articles-category %} {% else %} {% include all-articles-product %} {% endif %} + {% endunless %}
    {% include support-section %}