- Issue created by @2dareis2do
- 🇪🇸Spain fjgarlin
The display is set to "teaser" https://git.drupalcode.org/project/drupalorg/-/blob/7.x-3.x/drupalorg/dr...
And that teaser description is set to "summary or trimmed" with 600 characters as limit, which is obviously not respecting.
I checked the "Barrio Bootstrap 5 Theme" node to see if it had a long summary but it's not the case, it's empty.
- 🇪🇸Spain fjgarlin
I think I found the reason for this. The use of
<!--break-->
in the description changes the behaviour and make it act as a "summary", which is not trimmed. - 🇺🇸United States drumm NY, US
We should go ahead and set up the content of project browsing pages like https://www.drupal.org/project/project_theme → to match the work done by the contrib project browser, which only shows the first 200 characters of the body field, like https://git.drupalcode.org/project/project_browser/-/blob/2.0.x/src/Proj...
This output is done at https://git.drupalcode.org/project/drupalorg/-/blob/7.x-3.x/drupalorg/dr...
We can either:
- Update the project node teaser display. This is a bit tedious, since there all of project_core, project_distribution, project_drupalorg, project_general, project_module, project_theme, project_theme_engine & project_translation need updating. There is also a chance the teaser display is used elsewhere, where we don’t want this, but I can’t think of a place where it might be a problem.
- Replace
node_view($node, 'teaser');
with code to format each item we want.
- 🇬🇧United Kingdom 2dareis2do
With regard to advertising on Drupal.org I did find this page
https://www.drupal.org/advertising →
Sponsorship or advertising will only be included on project pages, in project issue queue listings, or individual issues when it is appropriate and relevant to the contributor community, such as sponsorship of DrupalCI.
and
The ad is labeled with terms such as “Advertising”, “Advertisement”, “Partner Offer”, “Supporting Partner” or “Sponsorship” to distinguish it from content
I can't see that any rules have been broken here.
- 🇬🇧United Kingdom 2dareis2do
Any update on this issue?
It has been 3 months already!
- 🇪🇸Spain fjgarlin
This issue was/is not critical. There are many other projects and priorities that are taking our time.
There were links and recommendations on #6, so anybody could have technically worked on an MR for this. Having said this, I had some early code that I did back in the day but didn't push it to a branch because it was just a POC, but I guess it won't hurt to get a first pass at it for feedback.
MR: https://git.drupalcode.org/project/drupalorg/-/merge_requests/305/diffs
Test link: https://fjgarlin-drupal.dev.devdrupal.org/project/project_theme?f%5B0%5D...
Screenshot:
I haven't tested on any other page, just that one.
- 🇬🇧United Kingdom 2dareis2do
Thanks,
I can't see the test link but based on the screen shot that is a massive improvement IMO.
What is the actual difference between node view and what you are outputting. Presumably it is also possible to set the trim length on the teaser view as well?
- 🇪🇸Spain fjgarlin
I would say there is a gap in front of Radix for some reason and also I do think it might be good to keep one image on the preview.
The code in the MR is trimming "normal" whitespace. You can ignore that spacing in the radix entry. My test site had old data where the body started like this (which is a maintainer's choice):
<p> </p> <p> </p>
--
What is the actual difference between node view and what you are outputting. Presumably it is also possible to set the trim length on the teaser view as well?
From comment #6
There is also a chance the teaser display is used elsewhere, where we don’t want this
. I went with the safer option for this view, which is actually the second suggestion in that comment. - 🇺🇸United States drumm NY, US
I added the repository logo, so there is still a visual element to the page, and it’s closer to project browser.
The old page, and project browser, have categories. I could go either way on keeping those for this issue. I’m not sure how useful the categories are on listings.
- 🇪🇸Spain fjgarlin
Thanks for adding the logo. I created the related bluecheese issue and is ready to review.
I also added the categories, which in themes are just "development status" and "maintenance status".All this can be seen again here: https://fjgarlin-drupal.dev.devdrupal.org/project/project_theme?f%5B0%5D...
- 🇺🇸United States drumm NY, US
For categories, it isn’t a regression, but we should update these to more-closely match project browsing.
- Let’s only show the categories, and not the maintenance and development status. Maintenance and development status are not meaningful unless they are something like “no further development;” the “actively maintained”-like statuses don’t affirm that it really is currently actively maintained.
- Let’s link the categories to the same browser. Project pages like https://www.drupal.org/project/token → have code which sets up these links. We probably also want the link to include the current parameters for filtering.
- 🇪🇸Spain fjgarlin
Feedback addressed. I couldn't use tokens as the search form is a solr one that we are building in
drupalorg_browse_projects_form
, but I could replace the category in the URL instead. -
drumm →
committed a7f1a338 on 7.x-3.x authored by
fjgarlin →
Issue #3470518: Align project browsing with project_browser
-
drumm →
committed a7f1a338 on 7.x-3.x authored by
fjgarlin →
- 🇺🇸United States drumm NY, US
This is also resolving ✨ Source logos on project search page from project repositories Active
Ideally, this would parse out the URI and update the query array instead of a regex, and output with
l()
, but this seems safe and we can do it better in the D10 version.