Page MenuHomePhabricator

Consider adding Translations and Uploaded media icons to the sticky header
Closed, DeclinedPublicBUG REPORT

Description

Steps to replicate the issue (include links if applicable):

  • enable Vector 2022
  • go to a page on en.wiki and open the User menu
  • look at the "Translations" and "Uploaded media" icons
  • then scroll down and open the User menu in the sticky header

What happens?:

  • "Translations" and "Uploaded media" have no icons

What should have happened instead?:

  • All links should have icons in in the sticky header

Software version (skip for WMF-hosted wikis like Wikipedia):

Other information (browser name/version, screenshots, etc.):

Screenshot 2022-10-10 at 22-03-17 Honbice - Wikipedia.png (382×585 px, 116 KB)

Screenshot 2022-10-10 at 22-03-06 Honbice - Wikipedia.png (386×526 px, 45 KB)

Event Timeline

The issue here is the duplicate elements with ID cx-language. In 836254 we added some code that limited icon addition by element ID.

Presumably the two lines here: https://gerrit.wikimedia.org/g/mediawiki/extensions/ContentTranslation/+/20e0f6c2364254ff91df1d98b27ca21e6916aec9/modules/entrypoints/ext.cx.entrypoints.contributionsmenu.js#143 need to be changed to use a unique ID e.g. cx-language-sticky (and then your CSS needs updating to make sure that ID is associated with the icon since currently there is no icon parameter in mw.util.addPortletLink and the icon class is derived from ID.

Pginer-WMF triaged this task as Medium priority.Oct 25 2022, 7:55 AM
Pginer-WMF subscribed.

The issue here is the duplicate elements with ID cx-language. In 836254 we added some code that limited icon addition by element ID.

Presumably the two lines here: https://gerrit.wikimedia.org/g/mediawiki/extensions/ContentTranslation/+/20e0f6c2364254ff91df1d98b27ca21e6916aec9/modules/entrypoints/ext.cx.entrypoints.contributionsmenu.js#143 need to be changed to use a unique ID e.g. cx-language-sticky (and then your CSS needs updating to make sure that ID is associated with the icon since currently there is no icon parameter in mw.util.addPortletLink and the icon class is derived from ID.

Thanks for the context, Jon. Adding it to our quarter board.

Change 853920 had a related patch set uploaded (by Santhosh; author: Santhosh):

[mediawiki/extensions/ContentTranslation@master] contributionsmenu entrypoint: Use unique ids for portlet links in sticky header

https://gerrit.wikimedia.org/r/853920

Change 853920 merged by jenkins-bot:

[mediawiki/extensions/ContentTranslation@master] contributionsmenu entrypoint: Use unique ids for portlet links in sticky header

https://gerrit.wikimedia.org/r/853920

@Pginer-WMF are you sure is it resolved? I'm being testing the user menu in the sticky header in 3 different browsers, and still no icons for "Translations and "Uploaded media" for me.

@Patafisik I tested the browsers: Chrome, Safari and Firefox and I am able to see the icons for "Translations and "Uploaded media". Would there be anything you are doing different? I would like to try that

@EChukwukere-WMF you are testing the wrong menu in T320448#8453137. You need to scroll down the page to show the sticky header. See T320448#8373601. it will also not work on the main page.

It appears broken still for me on https://en.wikipedia.org/wiki/Nadezhda_Alliluyeva
Hope that helps!

Yes, still broken on dewiki too.

@XanonymusX and @Jdlrobson thanks for the clarification of workflow. Yes you both are right and I am able to verify this.

@santhosh pls see the video below on how I was able to verify this. Lets move this back into the in-progress column

Change 867124 had a related patch set uploaded (by Santhosh; author: Santhosh):

[mediawiki/extensions/ContentTranslation@master] Remove translation entry point from sticky header temporarily

https://gerrit.wikimedia.org/r/867124

I just removed these menus from sticky header for now. Will revisit later(or even remove them permanently as persistant entry point for translations is ready)

Change 867124 merged by jenkins-bot:

[mediawiki/extensions/ContentTranslation@master] Remove translation entry point from sticky header temporarily

https://gerrit.wikimedia.org/r/867124

I just removed these menus from sticky header for now. Will revisit later(or even remove them permanently as persistant entry point for translations is ready)

Hi @santhosh, just FYI here a user is confused by this change.

Nikerabbit subscribed.

We are waiting for a better API that avoids these problems.

This should be fixable now. In T327369 we made the sticky header support icons but possibly better to focus on the Special:Contribute endpoint and possibly retiring those menu links? See T330611 for concern about hierarchy.

This should be fixable now. In T327369 we made the sticky header support icons but possibly better to focus on the Special:Contribute endpoint and possibly retiring those menu links? See T330611 for concern about hierarchy.

Yes. Once the Contribute entry point is widely available, we can remove these options from the menu. I created a ticket to capture this: T333327: Remove the contribution options exposed in user/contributions menu

Should we decline this ticket, then?

Should we decline this ticket, then?

Sounds good to me.

Declining this since these actions are planned to be removed from both, sticky and top header, menus (T333327) once the contribution options are consolidated around the persistent entry point to contribute (T322740). So it is probably to spend efforts elsewhere, but feel free to reopen if there is any other aspect to consider on this.