Page MenuHomePhabricator

Add descriptive text used for depicts on UW to FP also
Closed, ResolvedPublic

Description

The descriptive copy on UW makes depicts a little more clear for all users. Let's take that copy and bring it over to FP too.

Text says:

Items depicted in this file above depicts label
Items portrayed in this file above depicts label

Update:
This is how this currently appears on Beta. The only current issue is the missing Wikidata logo next to the P number (which might be correct because of the current 'faking' of Wikibase Federation). Otherwise, the page seems to reflect all the updated design requirements (depicts in italics, "portrayed" instead of "depicted", etc.)

depicts-italicized.PNG (252×1 px, 16 KB)

Deprecated design:

Screenshot 2019-02-21 14.35.57.png (276×1 px, 34 KB)

Event Timeline

PDrouin-WMF renamed this task from Add descriptive text used for depicts on UW for FP also to [Alpha/Labs] Add descriptive text used for depicts on UW for FP also.Feb 21 2019, 7:39 PM
PDrouin-WMF renamed this task from [Alpha/Labs] Add descriptive text used for depicts on UW for FP also to [Alpha/Labs] Add descriptive text used for depicts on UW to FP also.
PDrouin-WMF updated the task description. (Show Details)

I tried to find out where the "depicts" text is coming from here, but it's proving to be more tricky than expected. It looks like the text label of the relevant Wikibase property is being used directly, rather than some kind of "Depicts Panel Heading" message the way that the Captions panel is set up:

Screen Shot 2019-02-22 at 11.32.57 AM.png (800×2 px, 120 KB)

I assume this is getting set in PHP, and I attempted modifying a few function calls in src/View/MediaInfoEntityStatementsView.php to see if I could change the text on this section of the page, but nothing seemed to happen no matter what I did. This is about the limit of my PHP debugging skills unfortunately. Happy to try to address this ticket if someone can point me to where I should go. I assume that adding a more human-friendly label will require updating the i18n message files as well as the registry in extension.json

@egardner you're right, it's the label of the Wikibase 'depicts' property that's being used directly here

Change 492661 had a related patch set uploaded (by Matthias Mullie; owner: Matthias Mullie):
[mediawiki/extensions/WikibaseMediaInfo@master] Add descriptive text for depicts

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

depicts (the first h4.wbmi-entity-label) is indeed the property's name in wikibase (whereas 'Captions' in indeed an i18n message)

MediaInfoEntityStatementsView.php is indeed the correct place - you probably weren't seeing anything because pretty much all of the current content generated in the file gets replaced immediately by the JS widgets (the PHP rendering is only really meant for people/bots without JavaScript)

I just submitted a patch myself, because I just now realized that these changes to titles (in here, and even more in https://gerrit.wikimedia.org/r/c/mediawiki/extensions/WikibaseMediaInfo/+/492004) also impacted the depicts form's reuse in UploadWizard as well, which already had a functional patch.

Note: copy to be updated to "Items portrayed in this file"

@matthiasmullie - Okay, changes per Nirzar:

Change wording of title, make 'depicts' italicized to de-emphasize it, and update the help text.

Items portrayed in this file
depicts
Search to add items (house cat, mountain, Mona Lisa, etc.)

Ramsey-WMF moved this task from Untriaged to Next up on the Multimedia board.

Change 492661 merged by jenkins-bot:
[mediawiki/extensions/WikibaseMediaInfo@master] Add descriptive text for depicts

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

Ramsey-WMF renamed this task from [Alpha/Labs] Add descriptive text used for depicts on UW to FP also to Add descriptive text used for depicts on UW to FP also.Mar 14 2019, 2:16 AM
Ramsey-WMF updated the task description. (Show Details)

Moving this for now, should check again when tabs are implemented. Pinging @PDrouin-WMF as a reminder for her verification as well :)