Page MenuHomePhabricator

Don't show ReferencePreviews together with Navigation Popups Footnote Previews
Closed, ResolvedPublic

Description

The Navigation-Popups-Gadget also supports the preview of references/footnotes. When it is used together with the Reference Previews feature from the Page-Previews (Popups) extension, it shows two popups when hovering a reference.

References NavPopups.png (210×716 px, 71 KB)

This should not happen. I guess we should disable Reference Previews automatically when we detect, that the user uses Navigation-Popups-Gadget . Similar to what we do when we detect that the user uses the reference tooltips gadget.

Note, that there's already a generic hint on the preferences page where you can toggle the Reference Previews feature, that informs about the possibility that gadgets might conflict.
Note, that in T267846: Investigation: Using ReferencePreviews together with NavigationPopups we did not consider this, because there the whole extension was disabled when the Navigation-Popups-Gadget was enabled. Now that's different.

Event Timeline

Change 961098 had a related patch set uploaded (by WMDE-Fisch; author: WMDE-Fisch):

[mediawiki/extensions/Popups@master] Disable reference previews when the navigation popups gadget is used

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

The Popups code already knows if the gadget is enabled and automatically disables Page-Previews then. I think we can simply use the existing flag and disable Reference Previews as well:

isReferencePreviewsEnabled.js
-       if ( config.get( 'wgPopupsConflictsWithRefTooltipsGadget' ) ||
+       if ( config.get( 'wgPopupsConflictsWithRefTooltipsGadget' ) ||
+               config.get( 'wgPopupsConflictsWithNavPopupGadget' ) ||

That should be it.

Note that the two gadgets also have self-disabling behavior. ReferenceTooltips turns itself off when NavigationPopups is enabled.

Change 961098 merged by jenkins-bot:

[mediawiki/extensions/Popups@master] Disable reference previews when the navigation popups gadget is used

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