Motivation:
Currently, when referencing different sections of the same book, the whole source always needs to be repeated, and the references section may be cluttered by repeated appearances of the same source, with only slight variations. So this is an attempt to bundle the info.
How it should work
The extends parameter gets a string that corresponds to a previously defined reference. e.g. a reference that was named with name="animal" can then be specified through <ref extends="animal">.
<ref extends="animal"> Page 25 </ref> should then lead to "Page 25" being printed in the references section, below the definition of the "animal" source, and with an indent
Mock:
group and extends:
As long as reference names are only unique per group, we stick to that behavior. That means<ref name="A" group="G"> info </ref> can be extended by <ref extends="A" group="G"> details </ref>, but <ref extends="A"> details </ref> will throw an error, unless <ref name="A"> info2 </ref> exists as well.
name and extends:
Extension refs can also have a name. e.g. If there was <ref extends="animal" name="animalpage25"> Page 25 </ref>, <ref name="animalpage25" /> would also link to the extension reference.
Constraints:
It is not possible to make more than one level of extensions (i.e. 1.1.1 never exists).
Implementation
This change needs to be implemented both for parsoid and the cite extension (see subtasks (which are to come ;) )
Task background
This is a concrete implementation task for the proposal that was discussed in T138601.
Background
The wish to improve the referencing of multiple parts of the same source was part of the German-speaking community's technical wishlist in 2013, 2015 and of the international technical wishlist in 2015. For more info, see T100645.