Page MenuHomePhabricator

Allow hiding of Cite.php references
Open, LowPublicFeature

Description

Author: phi1ipp

Description:
Some of our Wikipedia articles are increasingly cluttered with referencing
superscripts. These are necessary for verifiability purposes, but detrimental to
readability of the text. I therefore propose a UI element which would allow
hiding these. This element could be a button or hyperlink, either at the top of
the article or the start of each section, or a global preference set by the user.


Version: unspecified
Severity: enhancement

Details

Reference
bz8033

Event Timeline

bzimport raised the priority of this task from to Low.Nov 21 2014, 9:29 PM
bzimport added a project: Cite.
bzimport set Reference to bz8033.
bzimport added a subscriber: Unknown Object (MLST).

These items are currently labelled as class="reference"; this is governed by [[Mediawiki:cite_reference_link]]. If
you want to hide them, alter your personal CSS to hide that class.

Similarly, the list of references is labelled as class="references".

HTH HAND

there should thou be a possibillity to hide individual references, simlar to
LaTeX \nocite

robchur wrote:

It doesn't really make sense to hide individual references; citation is
important, especially for things like encyclopedias and any other site which
needs to be able to present evidence for factual claims. If we start allowing
editors to hide single reference items, then other users could become confused.

It does make sense to allow users to temporarily hide references for a page
view, which could be approached using JavaScript. As Phil points out above, more
permanent, per-user hiding of references, can be done via custom CSS.

phi1ipp wrote:

Yes, you should only be able to hide all or none, and this should be in the
user's power, not the editor's.

alphasigmax wrote:

Somewhat related to this would be the ability to make the <ref> containing the
actual data to be hidden; this would allow an editor to put <ref name="foo" />
tags all through an article and then have a <ref name="foo" hideme>{{cite
blah}}</ref> at the end, which allows the references to work but unclutters the
article without displaying a spurious reference anywhere. Let me know if this
belongs in a different bug report...

ayg wrote:

*** Bug 10579 has been marked as a duplicate of this bug. ***

phi1ipp wrote:

Report was apparently closed as a duplicate of bug 5997. Reopening to ask for clarification - bug 5997 is a very different proposal, although subsequent commenters raised the issue of bug 5997. This bug should not be closed as a dupe if the original report refers to a different problem. Also, please don't use bug reports as excuses to offload your own pet problems. Open them as separate reports, or keep them to yourselves.

Indeed, seems unrelated.

Don't know whether it's worth the effort to add a UI element for hiding UI elements... ;) But it would probably be pretty easy to do as a JS widget. (Poke a stylesheet and they all hide/show.)

royleban wrote:

I've seen articles go through cycles. Somebody adds a fact tag, questioning if something is true (sometimes, they actually remove something that's true because they don't believe it). Next, another editor restores the text, if necessary, and adds a reference, possibly to something already listed as a reference in the article (sometimes this means moving the reference from an explicit list to a ref tag). Quite frequently, the reference was added at the same time as the text, but the first editor hasn't gone into the history to ascertain that. Finally, another editor removes the ref tag because it's unnecessary detail to cite every single sentence in an article. Wait a while and the process starts anew. And, if there is a discussion on the talk page, it's never looked at or is actually gone because of archiving.

Two things happen: We have citation/reference wars, and we have overly cluttered references all over the place. Just look at the hard-to-read page [http://en.wikipedia.org/wiki/Barack_Obama] and you'll see what I mean -- one citation for every 25 words (a total of 216) and multiple runs of three and four citations in a row. And this is a featured article!

Here is my suggestion on how things could work to address these problems:

  1. By default, only the first reference to something appears superscripted in the text. Later ones are only visible in the source, unless an option is set.
  2. Multiple references which are to the same source with a different page number or the same URL with a different hash are treated similarly.
  3. When multiple references appear in a row, only a single citation is shown. If (5) is adopted, there is one * to the set; if (5) is not adopted, the refs are shown as a group, e.g., [33-37] or [33-37,15], with the latter case for a single re-reference following multiple references.
  4. A reference can be marked as "minor" in the source. Minor references do not appear in the text unless the option is set. They do, however, appear in the references section with backlink(s). In the Barack Obama example, the first 43-word sentence contains 6 references and that's only because nobody's required a citation for where Obama's father was from. I would make refs 6, 7, and 9 minor, leaving 8 as major (and I'd delete 10 and 11 as irrelevant to the sentence).

And ...

  1. Display all in-text refs as superscripted *'s instead of [n]. It's smaller and will hurt readability less. The numbers appear in the printable version of a page or (possibly) if a user turns on an option. The numbers are a historical artifact from the world of paper that we should abandon.

(I've separated #5 because I realize it's a bit off-topic for this bug report, but I think its part of a complete solution).

This adds a link to the sidebar to toggle the dispaly of the in-text footnote markers.

https://en.wikipedia.org/wiki/User:Zhaofeng_Li/RefToggle.js

I wonder if we implemented T20231: provide a way to specify what text/statement is supported by a <ref> block., what impact that would have on this task.

I'm thinking about alternate ways in which we could present reference markers besides superscript [1][2][3] etc. One alternate approach might be to have the whole statement or sentence be wrapped in a border or some other formatting. This would replace the [1], so that the article text in view mode wouldn't be as cluttered with superscript bracketed numbers, but you'd still have an indication (perhaps on-hover?) that the text is cited/verified.

I'm thinking about alternate ways in which we could present reference markers besides superscript [1][2][3] etc. One alternate approach might be to have the whole statement or sentence be wrapped in a border or some other formatting. This would replace the [1], so that the article text in view mode wouldn't be as cluttered with superscript bracketed numbers, but you'd still have an indication (perhaps on-hover?) that the text is cited/verified.

It's an interesting idea, but I think an approach where on-hover or bordered wouldn't be intuitive to the user (or at least, not me) would inhibit or at-least make difficult to get the expected behavior with normal links (clickability!) (never mind Hovercards), and probably wouldn't print well.

I think the concern of many references in a row might need some consideration: increasingly, (at least) en.WP is moving away from having all three of the references directly in the text toward either a) "reference grouping" or b) removal of the "least useful" citation(s). So I think that perspective can be driven socially, for those wikis that use lots of inline referencing.

IMO this task should be closed. This can be done these days with personal CSS/JS trivially, or if an entire community desires, a gadget.

The ability to mark some of the citations as 'minor' could be a huge win for performance / usability , especially if they are not rendered in the <references/> blocks by default , and this would most benefit Mobile where the list of references is typically one very long column instead of multiple columns.

Worth noting that this could be fairly easily achieved without software changes by putting less important references into a separate group and hiding the CSS class for that group, and rendering that group of references after the main references.

Aklapper changed the subtype of this task from "Task" to "Feature Request".Feb 4 2022, 11:01 AM
Aklapper removed a subscriber: wikibugs-l-list.