On Menu Item Type >> List All Tags >>
Selection Options >> Maximum Items: set as 50 (because I want 50 tags per page)
Options >> Number of Columns: set as 1
The components/com_tags/tmpl/tags/default_items.php file creates an unordered list for each tag
ie
<ul class="com-tags__category category list-group">
<li class="list-group-item list-group-item-action">
<h3 class="mb-0">
<a href="/articles-and-audios/audio">
Audio
</a>
</h3>
</li>
</ul>
<ul class="com-tags__category category list-group">
<li class="list-group-item list-group-item-action">
<h3 class="mb-0">
<a href="/articles-and-audios/calendars">
Calendars
</a>
</h3>
</li>
</ul>
<ul class="com-tags__category category list-group">
<li class="list-group-item list-group-item-action">
<h3 class="mb-0">
<a href="/articles-and-audios/environment-ecology">
Environment/Ecology
</a>
</h3>
</li>
</ul>
<ul class="com-tags__category category list-group">
<li class="list-group-item list-group-item-action">
<h3 class="mb-0">
<a href="/articles-and-audios/equipment">
Equipment
</a>
</h3>
</li>
</ul>
<ul class="com-tags__category category list-group">
<li class="list-group-item list-group-item-action">
<h3 class="mb-0">
<a href="/articles-and-audios/featured-recordists">
Featured Recordists
</a>
</h3>
</li>
</ul>
I think the unordered list needs to be moved out of the foreach
<?php foreach ($this->items as $i => $item) : ?>
<?php if ($n === 1 || $i === 0 || $bscolumns === 1 || $i % $bscolumns === 0) : ?>
<ul class="com-tags__category category list-group">
<?php endif; ?>
Needs to be
<ul class="com-tags__category category list-group">
<?php foreach ($this->items as $i => $item) : ?>
And again at the close tag
Thanks
| Labels |
Removed:
?
|
||
| Labels |
Added:
No Code Attached Yet
|
||
| Title |
|
||||||
Hi, I’d like to work on this if nobody else is. From the snippet in the report, the $bscolumns === 1 condition makes the template open a new
I can confirm the bug and have a fix for it so that when there is just one column then all the tags are in the same groued list
But while writing a fix for this I discovered that while Joomla will create X grouped lists when you set it to display X columns it doesnt visually show the columns - eachc list is just immediately after the other.
@drmenzelit perhapps you could take a look at that
@tejaschavan724 feel free to make a PR. We don't assign tasks, everyone can work on it.
Hi, I'm interested in contributing to Joomla. I noticed that PR #48671 addresses this issue. I'll review the implementation to understand the fix. I'd also be interested in helping with any related improvements, particularly the multi-column layout issue mentioned here. Thank you!
@harshitha1869 welcome - studiying PRs is a good approach to understand Joomla.
We are looking forward to your contributions.
| Labels |
Added:
bug
|
||
Hi, I’d like to work on this if nobody else is. From the snippet in the report, the $bscolumns === 1 condition makes the template open a new
on every iteration when columns is set to 1, so each tag ends up in its own list.
Simply moving the
outside the foreach would break layouts with 2+ columns, since a new
is opened per row there. My plan is to keep the multi-column behaviour and change only the single-column case, so all tags sit in one
.
I’ll reproduce it locally first and open a PR with before/after screenshots. Is anyone already on this?