Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

DP-31955 Check for empty items for suggested pages #1886

Merged
merged 5 commits into from
Feb 28, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
7 changes: 7 additions & 0 deletions changelogs/DP-31955.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,7 @@

Changed:
- project: Patternlab
component: Suggested Pages
description: Add a condition to check suggested page items. (#1886)
issue: DP-31955
impact: Patch
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,7 @@
<div class="ma__suggested-pages__container">
<div class="ma__suggested-pages__inner-container">
<h2 class="ma__suggested-pages__title">{{ suggestedPages.title }}{% if suggestedPages.titleContext %}<span class="ma__visually-hidden">&nbsp; {{suggestedPages.titleContext}}</span>{% endif %}</h2>
{% if suggestedPages.pages|length > 0 %}
<ul class="ma__suggested-pages__items">
{% if suggestedPages.view == "guide" %}
{% for page in suggestedPages.pages %}
Expand All @@ -32,6 +33,7 @@
{% endfor %}
{% endif %}
</ul>
{% endif %}
{% if suggestedPages.moreLinks %}
{% set linkList = suggestedPages.moreLinks %}
{% include "@organisms/by-author/link-list.twig" %}
Expand Down