Page MenuHomePhabricator

Show references with the same details as re-use in VE
Closed, ResolvedPublic

Description

Same as T385666: Show references with the same details as re-use in the legacy rendering (Merge Use Case) but for VE

Context

VE already supports the concept of re-uses and that's not excluding sub-references per se. If nodes share the same listKey they are regarded as reuse. Currently using copy and paste on a sub-ref creates a VE reuse using the same listKey. To align the whole experience to this concept there are a few steps needed still:

Technical Implementation

Out of scope

  • When adding details to an existing ref we need to check for duplicate content on existing sub-refs for the mainKey. We might solve that later.
  • Editing can also lead to a reuse. We might solve that later.

Open question

  • How to make sure all existing ones are checked when opening an article page in VE? Solved by using the Converter state
  • Does it make sense to solve Parsoid reuse first before handling the loading of refs here? Not really a hard dependency.

Event Timeline

lilients_WMDE renamed this task from Parsoid: Show references with the same details as re-use in VE and reader mode to Show references with the same details as re-use in VE and reader mode.Oct 31 2025, 2:30 PM
lilients_WMDE updated the task description. (Show Details)

Change #1200367 had a related patch set uploaded (by Svantje Lilienthal; author: Svantje Lilienthal):

[mediawiki/extensions/Cite@master] Allow reuses of subrefs in the reuse dialog

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

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

[mediawiki/extensions/Citoid@master] Allow reuses of subrefs in the reuse dialog

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

Change #1200367 merged by jenkins-bot:

[mediawiki/extensions/Cite@master] Allow reuses of subrefs in the reuse dialog

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

WMDE-Fisch renamed this task from Show references with the same details as re-use in VE and reader mode to Show references with the same details as re-use in VE.Nov 3 2025, 12:58 PM
WMDE-Fisch updated the task description. (Show Details)

Change #1201039 merged by jenkins-bot:

[mediawiki/extensions/Citoid@master] Allow reuses of subrefs in the reuse dialog

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

Change #1211149 had a related patch set uploaded (by WMDE-Fisch; author: Svantje Lilienthal):

[mediawiki/extensions/Cite@master] VE: Merge identical sub-refs based in reflistItemId

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

WMDE-Fisch changed the task status from Stalled to Open.Nov 25 2025, 3:46 PM

I split of the VE logic from the Parsoid patch. Feel free to review.

WMDE-Fisch changed the task status from Open to Stalled.Nov 26 2025, 7:09 AM

Stalling this to wait for the sub-ref reuse to be merged.

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

[VisualEditor/VisualEditor@master] Make sure to reset the sub-ref lookup

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

Change #1211603 abandoned by WMDE-Fisch:

[VisualEditor/VisualEditor@master] Make sure to reset the sub-ref lookup

Reason:

Solved in the Cite patch with https://gerrit.wikimedia.org/r/c/mediawiki/extensions/Cite/+/1211149/5..6/modules/ve-cite/ve.dm.MWReferenceNode.js

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

Change #1211149 merged by jenkins-bot:

[mediawiki/extensions/Cite@master] VE: Merge identical sub-refs based in reflistItemId

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