Use the new "content reload" hook correctly
Closed, ResolvedPublic

Description

Earlier, when the revision slider changed the compared diffs, javascript was not reloaded. This resulted in functions such as thanks, wikeddiff... not to work properly once the diffs were changed through the revision slider. To change this, we implemented a new hook for the diff page.

This ticket is about the tasks that have to be done, once the hook is merged in core.

Tasks

  • Document the hook
  • Remove the thanks hack, that's currently implemented in the revision slider
  • Add a notice to the revision slider extension page, alerting gadget maintainer etc to use the hook for compatibility with the revision slider
  • Contact the wikeddiff maintainer
  • Decide on how to sunset the current wikeddiff hack

Background:
The revision slider is a feature that adds a visualization of all revisions to the compare screen. Revisions are represented as bars on a line and can be selected using two pointers. The revision slider was originally prototyped by the WMF Community Tech team and then handed over to the WMDE TCB team, as it is also a solution to fulfill a wish of the German Community Wishlist: https://de.wikipedia.org/wiki/Wikipedia:Umfragen/Technische_W%C3%BCnsche_2015/Artikel#Anzeige_aller_Bearbeitungskommentare_im_Diff

Restricted Application added a subscriber: Aklapper. · View Herald TranscriptSep 8 2016, 12:40 PM

Once again, I don't think there is such a thing, wikeddiff maintainer. There are two many copies.

On further review of this I don't think we need this new hook, and wikeddiff should simply be made to use the 'old' one.
wikipage.diff

As with our 'hack' in the RevisionSlider the wikeddiff code should basically do the following:

		reInitWikEdDiff: function () {
			$( 'meta[name=wikEdDiffSetupFlag]' ).remove();
			$( 'meta[name=wikEdDiffStartupFlag]' ).remove();
			wikEd.DiffSetup();
		},
Addshore closed this task as Invalid.Sep 13 2016, 8:43 AM

@IKhitron please take a look at T143199#2631963 :)

Thanks, done.

Addshore moved this task from Incoming to Done on the Revision-Slider board.Sep 13 2016, 2:51 PM
Tobi_WMDE_SW changed the task status from Invalid to Resolved.Sep 27 2016, 3:15 PM