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

com_tags layouts #39177

Open
nasirkhan opened this issue Nov 8, 2022 · 7 comments
Open

com_tags layouts #39177

nasirkhan opened this issue Nov 8, 2022 · 7 comments

Comments

@nasirkhan
Copy link
Contributor

nasirkhan commented Nov 8, 2022

Steps to reproduce the issue

I started to use Tags with articles to group those beyond Category. But I found that tags do not have proper layouts to display. I tested with the Cassiopeia template.

List All Tags

Create a new menu item with the Menu Item Type List All Tags. I got some options and added 3 for Number of Columns.

Compact list of tagged items

Create a new menu item with the Menu Item Type Compact list of tagged items. I selected a tag and Article as the content type.

Tagged Items

Create a new menu item with the Menu Item Type Tagged Items. I selected a tag and Article as the content type.

Expected result

List All Tags

For List All Tags type I expected to see the tags will be displayed in 3 columns as I choose to do so.

Compact list of tagged items

I selected Compact list of tagged items I assumed I will see an unordered list of items. Also, the show image option is not relevant, because it is intended to show a compact list.

Tagged Items

The first thing I expected to see is the column option, there is none, also Show Cateogry is needed as well.

Actual result

List All Tags

Visually I saw a single Unordered list but from the source, I found that the column values are working. and showing multiple unordered lists with a group of 3 items.

Compact list of tagged items

Saw a list of tags in a table.

Tagged Items

It is kind of an extension of the List All Tags because if I select a tag from that list this layout show up.

Solution to this issue

List All Tags

I created an override and replaces ul-li with div-row-col. You can see check the source at https://github.com/nasirkhan/com_tags and used this override in my website at https://nasirkhn.com/tags/

I think rather writing more CSS for the ul-li combination, we can just use the Bootstrap column system. I would directly submit a pull request here, but I want to know if should I submit it as part of the template or the com_tags. I also need some assistance to improve this layout, as I could not find the Category Name with the articles and some other values which are available with the items in the Category Blog View

Compact list of tagged items

Need to replace table with ul-li. Also image option should be removed.

Tagged Items

I created an override and replaces ul-li with div-row-col. You can see check the source at https://github.com/nasirkhan/com_tags and used this override in my website at https://nasirkhn.com/tags/

Also as mentioned in the expected result area, column option is necessary and control over other attributes which are available under the category blog view.

System information (as much as possible)

  • Joomla 4
@nasirkhan nasirkhan changed the title com_tags layouts com_tags blog layouts Nov 8, 2022
@chmst chmst added Feature a11y Accessibility labels Nov 8, 2022
@nasirkhan
Copy link
Contributor Author

@chmst thanks for the tags.

If you read the issue again, you will find that all of it is not a new feature. The column options are not working, is a "Bug". I can submit a PR but I am not sure which part should I modify. If you can point that out, then it would be a great help. Or can you please refer someone else who may assist me here?

@chmst
Copy link
Contributor

chmst commented Nov 8, 2022

Ok, more but than feature. I think that it is better to change layouts in core (tmpl file) than to make an override. And using bootstrap without changes in css looks good.
I recommend working for 4.3 branch - as this is not a critical bug and this gives the developers time for good tests and comments.
Would you start a PR? I am pretty sure that this will need some time and discussions - but it is worth it :)

@chmst chmst removed the Feature label Nov 8, 2022
@Hackwar
Copy link
Member

Hackwar commented Nov 9, 2022

I agree with you, that the layouts are not good right now, however we can't simply change it to something else right now, because that would break the design of existing sites. So we would probably have to wait until joomla 5 to change this. A PR against that branch would probably be welcome.

If you are working with tags extensively, you could really help me out. I've been creating several PRs lately to fix big issues in tags and those need tests. Please have a look at #39154, #39140, #39114, #39113

@nasirkhan nasirkhan changed the title com_tags blog layouts com_tags layouts Nov 9, 2022
@nasirkhan
Copy link
Contributor Author

I think 4.3 would be the right branch. I am selecting an option (in this case number of columns) and it has no effect in the view is a critical bug for me.
But it is true that this might break some site layouts. But again, I am not suggesting any new CSS class, just using the bootstrap classes to properly display the data. Also, if we do not fix this soon, everyone has to create their own overrides and other local fixes.

@Hackwar
Along with the mentioned bug, I believe Tags layout must be improved. and this is the main objective of creating this issue. For the new improvements it will require to change in a number of places including model and controller.

Do you have any timeline for Joomla 5? If it is very far then I would like to be added in earlier releases.

I will try to look into your mentioned pull requests.

I already created some overrides for my use, (https://github.com/nasirkhan/com_tags) and will create submit a pull request here soon.

@Hackwar
Copy link
Member

Hackwar commented Nov 9, 2022

Joomla 5 is supposed to be released in 1.5 years. The problem is not what I or you want, but if it is breaking existing sites. If this negatively impacts other people's sites, then this has to wait until the next major version. Yes, we wouldn't be introducing any new classes, but you would change markup and not all sites have bootstrap.

@nasirkhan
Copy link
Contributor Author

nasirkhan commented Nov 9, 2022

You are right, breaking changes may have larger negative impacts.

I issue I faced with the tags have two parts, first the expected data are not available for the article $items (like catid exists but Category Name is not available) and the view does not follow the options and there should be more options.

In the earlier releases we may fix the data and options part and in Joomla5 we may change the view. I assume this might not have any negative impact because existing data and options may remain same, and we will add additional ones. Like in some of your pull requests you added options for com_tags.

@brianteeman
Copy link
Contributor

Anything happening here?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

5 participants