Add-on listing link is not visible when an add-on does not have any ratings
Categories
(Toolkit :: Add-ons Manager, enhancement, P3)
Tracking
()
Tracking | Status | |
---|---|---|
firefox117 | --- | verified |
People
(Reporter: murznn, Assigned: gresunta, Mentored)
References
Details
(Keywords: good-first-bug)
Attachments
(4 files)
User Agent: Mozilla/5.0 (X11; Ubuntu; Linux x86_64; rv:109.0) Gecko/20100101 Firefox/114.0
Steps to reproduce:
I want to open the addon page on the https://addons.mozilla.org/ website from the addon page in Add-ons Manager, to get more information about this addon, vote for it, etc.
Actual results:
No way to open the specific addon page from the Addon page.
Expected results:
A link to the addon page on the https://addons.mozilla.org/ website should be present somewhere.
It's about the "Extensions" page.
But on the "Recommendations" page the problem is even worse! From the list of recommended extensions, we can open only the author page, and add the extension to Firefox, but no way to see the detailed project description, read comments, etc.
Comment 2•1 year ago
|
||
Hello,
Indeed there are no direct links to the add-on AMO detail page, however you can reach the mentioned page with a few clicks.
As such, I will mark this report as an Enhancement and not a defect.
@Alex Cornestean, could you please describe how can I reach the mentioned page with a few clicks in more detail?
I see no links at all!
Comment 4•1 year ago
|
||
In the hope that I understood the issue correctly, see the attached video.
Comment 5•1 year ago
|
||
Yeah, via the Author link it's possible, but it's not obvious for regular users, and if the author has 10+ addons, it's not easy to find the needed one.
Also, not each addon has this field, eg this one:
Comment 7•1 year ago
|
||
About the author link - we have bug 1668988 to track that we don't just want the "author" link to point to AMO.
When an add-on has ratings, you can click on that link to got to the ratings page of the add-on. It doesn't appear when there are no ratings, however. We should show it unconditionally.
That would be quite a straightforward change, the code is here: https://searchfox.org/mozilla-central/rev/ada05ac4faf1f79944a35a9eb79083a684a98975/toolkit/mozapps/extensions/content/aboutaddons.js#2319-2331
and the unit test is here: https://searchfox.org/mozilla-central/rev/ada05ac4faf1f79944a35a9eb79083a684a98975/toolkit/mozapps/extensions/test/browser/browser_html_detail_view.js
Comment 8•1 year ago
|
||
I renamed the bug in my previous comment because you specifically stated the use case of "vote for it".
The general request to add a link to AMO is at bug 590344.
I would like to make my first contribution if that's okay. So if I understand correctly, the fix should be that the ratings (stars) and the link (number of reviews) is always visible?
Comment 10•1 year ago
|
||
(In reply to gresunta from comment #9)
I would like to make my first contribution if that's okay.
Welcome! If you haven't set up your development environment yet, get started by following the instructions at https://wiki.mozilla.org/WebExtensions/Contribution_Onramp#Setting_Up_Developer_Environment
Once you are ready to submit your patch for code review, do so by following the instructions at https://wiki.mozilla.org/WebExtensions/Contribution_Onramp#Submitting_a_Patch
So if I understand correctly, the fix should be that the ratings (stars) and the link (number of reviews) is always visible?
Yes. Without ratings I would expect the star ratings + link to be always visible (with visually empty stars), if there is a link available. That link is not always available, e.g. if the add-on is not publicly available on the AMO website.
In my previous comment at comment 7, I linked to the relevant source file where the change has to be made.
Here are more explicit instructions on creating the unit test in the browser_html_detail_view.js
test file:
- Create a new add-on entry that has a review link but 0 ratings. For example, create
addon4@mochi.test
based on the existingaddon2@mochi.test
addon at https://searchfox.org/mozilla-central/rev/ada05ac4faf1f79944a35a9eb79083a684a98975/toolkit/mozapps/extensions/test/browser/browser_html_detail_view.js#223,228-229,234-244 - Add a test that verifies that the ratings element is visible.
- Here is the test for
addon2@mochi.test
. You can consider starting by copying that test (and simplify later once everything works): https://searchfox.org/mozilla-central/rev/ada05ac4faf1f79944a35a9eb79083a684a98975/toolkit/mozapps/extensions/test/browser/browser_html_detail_view.js#710-764 - Here is the test case with logic verifying the rendered stars and review link: https://searchfox.org/mozilla-central/rev/ada05ac4faf1f79944a35a9eb79083a684a98975/toolkit/mozapps/extensions/test/browser/browser_html_detail_view.js#616-634
- Here is the test for
To run the unit test, run ./mach test toolkit/mozapps/extensions/test/browser/browser_html_detail_view.js
Assignee | ||
Comment 11•1 year ago
|
||
Updated•1 year ago
|
Comment 12•1 year ago
|
||
Comment 13•1 year ago
|
||
bugherder |
Comment 14•1 year ago
|
||
Verified as Fixed on the latest Nightly (117.0a1/20230723212527). Tested on Windows 10 x64 and Ubuntu 22.04 LTS.
I used https://addons.mozilla.org/en-US/firefox/addon/netvard-extension/, which has 0 users and 0 reviews.
The add-on detail page now shows the “Ratings” row with the star ratings (visually empty) and the link. Clicking the link properly redirects the user to add-on review page on AMO.
For more details, see the attached screenshot.
Comment 15•1 year ago
|
||
Description
•