Page MenuHomePhabricator

#section-links should preview the correct subsection
Closed, DuplicatePublic


As a user, it is confusing to see a a hovercard for a topic and then click through to a specific section:

The hover is for the "gray wolf"

Screenshot 2016-04-12 15.32.51.png (371×888 px, 261 KB)

The link is to this specific section:

Screenshot 2016-04-12 15.33.32.png (428×1 px, 355 KB)

Old description
Screenshot of Hovercard and Navpopups on Wiktionary section link

In many cases, a link will target a page's sub-section. This is especially the case at Wiktionary, where each language has a separate section(s), and the links will target them.

(See screenshot, or test any item in )

I'm not sure if this is possible, with [[mw:Extension:TextExtracts]]?

See Also: T64994

Screenshot_from_2014-04-10_14:47:51.png (575×1 px, 112 KB)



Event Timeline

bzimport raised the priority of this task from to Needs Triage.Nov 22 2014, 3:14 AM
bzimport added a project: TextExtracts.
bzimport set Reference to bz63792.
bzimport added a subscriber: Unknown Object (MLST).

Moved to TextExtracts. FWIW, I remember discussions around similar things happening before (specifically, redlinks for sectionlinks that don't exist) and it was technically rather difficult to do.

Prtksxna updated the task description. (Show Details)
Prtksxna set Security to None.

This also needs to work for links to #fragments defined in {{anchor}} templates.

When this is implemented the Hovercard popup should probably show the page title (T102280), because the section text will often only make sense in context ("After three years in that position, she joined IBM").

It would be hot if the hovercard, or a template-triggerable variant of it, could start showing content starting at the specific anchor used in the link. If this were combined with the ability to trigger it for links on the same page, not just to different pages, this would be insanely great for glossaries (see and Wiktionary has them, too). For an example, see]]. The zillion intra-glossary links in that could just pop up the definition in question (as could similar glossary links at articles like that link to this glossary), instead of the current practices, which are just a tooltip saying what entry it goes to (generated by the tag) and, in the present hovercard, the top of the glossary's article page, if you are on a different page than the glossary itself. Many articles have embedded glossaries, too; they're not all in separate articles.

dr0ptp4kt lowered the priority of this task from Medium to Low.Aug 4 2016, 8:41 PM
dr0ptp4kt moved this task from Incoming to Needs Prioritization on the Web-Team-Backlog board.

Why is this set to "Low" priority? It's been my experience, with a large number of projects, that marking a report/request low-priority means it will most likely never be dealt with. Having the hovercard show the content that the link actually points to, and stop misleading readers, would appear to be a high-priority item.

It is low priority as other tasks on the Web-Team-Backlog plate are considered more urgent or more important.
Contributed patches for tasks that strongly interest you are always welcome!

I haven't figured out enough about this system yet (I've barely been able to get into it until recently due to LDAP issues with my account) to know where to start. I assume there's a git or svn repo somewhere. Anyway, not everyone who reports problems here is a programmer. The "this is going to remain on the back burner unless you code up a solution yourself" approach may make sense in, e.g., the GCC compiler development bug tracker over at GNU, but isn't very responsive when it comes to the issue tracker for a system that is mostly used by writers and readers of plain prose. Depending on what language this is written in, I might actually be competent to help, but the average Wikipedian (or user of other wikis) is probably not a coder.

My comments here have not been in the "wouldn't it be cool if [insert some obscure feature request here]" vein, but "I see this has been enabled on major projects like en.Wikipedia, but it is doing some very reader-confusing things." All four of these are problematic: 1) displaying the article lead when a section was linked to; 2) displaying nothing when the page has no lead; 3) displaying nothing for non-mainspace pages; 4) displaying the first image below an infobox instead of the one in the infobox). There are others, but these are the four really big issues that I have encountered with hovercards.