Page MenuHomePhabricator

Enable the categorization of references
Closed, ResolvedPublic5 Estimated Story Points

Assigned To
Authored By
Lea_WMDE
Feb 5 2019, 4:05 PM
Referenced Files
F28285166: generic OOUI.png
Feb 25 2019, 11:55 PM
F28285183: newspaper OOUI.png
Feb 25 2019, 11:55 PM
F28285181: newspaper VE.png
Feb 25 2019, 11:55 PM
F28285187: website OOUI.png
Feb 25 2019, 11:55 PM
F28285185: website VE.png
Feb 25 2019, 11:55 PM
F28285178: book OOUI.png
Feb 25 2019, 11:55 PM
F28285164: generic VE.png
Feb 25 2019, 11:55 PM
F28285173: journal OOUI.png
Feb 25 2019, 11:55 PM

Description

Motivation
When readers look at footnotes, they often seem to be interested in judging the quality of a source, and sometimes only some sources are relevant for their purpose (e.g. "I want to find notable authors in that field"). One way to help them achieve that more quickly is by classifying by footnote type.

Design

reference-previews.png (1×1 px, 149 KB)

Acceptance criteria

  • The header of the ReferencePreview is either "Footnote", "Web reference", "Journal reference", "Book reference" or "News reference"
  • If the footnote can be specified undoubtedly to one of those categories, it gets the specific one
  • If it cannot be surely decided which category a footnot belongs to, it receives the generic "Footnote"
  • The icons from from OOUI's visual editor edit section Using the OOUI icons atm although they are not in sync with VE see T217132

Event Timeline

Change 491521 had a related patch set uploaded (by Thiemo Kreuz (WMDE); owner: Thiemo Kreuz (WMDE)):
[mediawiki/extensions/Popups@master] Add reference type detection to HTML scraping gateway

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

Change 491799 had a related patch set uploaded (by Thiemo Kreuz (WMDE); owner: Thiemo Kreuz (WMDE)):
[mediawiki/extensions/Popups@master] Bring reference type detection in sync with RESTbased endpoint

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

> The header of the ReferencePreview is either "Footnote", "Web Reference", "Journal Reference", "Book Reference" or "News Reference"

@Lea_WMDE: In accordance with the citation classification from VE, they should be named Website, Journal, Book and News.
The generic form in VE is Basic form, so Footnote makes more sense for Reference Previews, I guess.

Oh, sorry. It seems we totally missed this sentence in the task description. For the patch we followed what the VisualEditor team already specified in https://phabricator.wikimedia.org/diffusion/ECIT/browse/master/modules/ve-cite/i18n/en.json$20, namely "Book", "Journal", "News", and "Website".

Seems we have 3 options now. Which one should we follow?

Oops, sorry! I had something wrong there. You're right, it's "Book", "Journal", "News", and "Website". I changed my comment accordingly.
So it's only two options. I personally prefer to go with the VE option. @Lea_WMDE

So the suggested form is basically the VE option + "Reference", which for me also makes more sense, because the user might not necessarily know what they actually see in the preview, and the "Reference" makes it clear what it is. @alexhollender is this also your reasoning behind it?
Would it be super evil from code perspective, or equally difficult to be using the "XX Reference" format? If there is no reason from the coding side, I would want us to go with what is in the acceptance criteria.

[…] from code perspective, or equally difficult to be using the "XX Reference" format?

Oh, no problem at all. Best-practice is to not re-use messages from other codebases, but introduce your own. We did that. It's a <1 point task to change these headings now. We just need a consistent agreement.

Cool, then let's go with what is in the acceptance criterias.

My hope was that the language and translations we use would be consistent with what is seen here:

Screen Shot 2019-02-22 at 1.56.22 PM.png (588×918 px, 77 KB)

It would be great if we could somehow ensure that in the case one of these terms change in the future, our naming will remain consistent.

@Lea_WMDE @thiemowmde related — I know at one point we spoke about unifying the set of icons between VE and our previews. I cannot remember where that discussion was. Are we tracking this task in phabricator somewhere?

@alexhollender, I don't remember a particular discussion, sorry. I assumed both VE and our previews would use the current OOUI icons, which is what we did.

@Lea_WMDE, one question: The mocks say "Journal reference" with a lowercase "r", but this tasks description asks for "Journal Reference" with an uppercase "R". As far as I'm aware of this kind of title capitalization is typically not used in our software, nor in Wikipedia articles.

Lea_WMDE updated the task description. (Show Details)

The icons I see in OOUI here are not the ones I see in VE (except for "Website"):

VEOOUI
generic VE.png (73×213 px, 7 KB)
generic OOUI.png (42×109 px, 2 KB)
journal VE.png (68×175 px, 4 KB)
journal OOUI.png (42×90 px, 2 KB)
book VE.png (62×151 px, 4 KB)
book OOUI.png (38×77 px, 2 KB)
newspaper VE.png (65×148 px, 5 KB)
newspaper OOUI.png (44×129 px, 2 KB)
website VE.png (64×183 px, 6 KB)
website OOUI.png (40×75 px, 1 KB)

I'm not sure what exactly is going on, and what would need to be fixed, but would it be possible to fix this in the scope of our project?

As far as I can tell the icons currently seen in VisualEditor are older versions from a previous OOUI release. Maybe @Volker_E can explain this better?

I believe updating these icons is outside of the scope of our current Reference Previews project. @Lea_WMDE, what do you think?

They come from Cite extension and are outdated, at the same time they are already updated in OOUI, but are awaiting final agreement in T213884.

Change 492996 had a related patch set uploaded (by Thiemo Kreuz (WMDE); owner: Thiemo Kreuz (WMDE)):
[mediawiki/extensions/Popups@master] Update type-specific reference headings according to requirements

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

Change 491521 merged by jenkins-bot:
[mediawiki/extensions/Popups@master] Add reference type detection to HTML scraping gateway

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

WMDE-Fisch set the point value for this task to 5.Feb 26 2019, 12:51 PM
WMDE-Fisch subscribed.

I just discussed this with @thiemowmde - almost all points described in this ticket where already partly tackled while exploring our options regarding the reference endpoint in T214908. That's why it made sense to pull this into the sprint and finish the patch that's already in review since then.

Regarding the last point and OOUI/VE compatibility of the icons: There are currently some minor changes coming up and it makes most sense to bring the icons in sync when these are finished. At the moment OOUI and VE icons for the reference types are not on the same version. That can be changed though and for now, we implemented the current up-to-date OOUI icons.

Change 492996 merged by jenkins-bot:
[mediawiki/extensions/Popups@master] Update type-specific reference headings according to requirements

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

Change 491799 merged by jenkins-bot:
[mediawiki/extensions/Popups@master] Bring reference type detection in sync with RESTbased endpoint

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

Lea_WMDE claimed this task.
Lea_WMDE moved this task from Demo to Done on the WMDE-QWERTY-Sprint-2019-02-20 board.