Had to do that in JavaScript as doing it server-side would have
made refactoring large parts of the extension necessary.
Bug: 38141
Change-Id: I60ecd2fc0edf2aee89974d8069cc0b075cda3f93
Moved the scripts and the CSS into the modules folder directly
(like almost all other extensions do), added a .jshintrc to not have
jenkins shout at this change and minor stuff.
After this change Cite will no longer work with anything older than
PHP 5.3!
Change-Id: I1c87af794f2a9894fb0d82a5bd97bd2182f028e1
* The initialization of nestedRefCollectionMap[references-id]
in handleReferences was the wrong place to initialize it since
on pages with multiple <references /> tags, the map can get
reset after a references tag is processed. So, for later
references tags, the entry for those will get cleared which
led to crashes.
Ex: es:Abderramán_I and couple others found in RT testing.
* This patch fixes the crasher.
* Added a new parser test with multiple references tags that
captures this scenario. Regenerated selser changes file.
Change-Id: I64402e77996486b099acda114f2e250258b0048e
* Track <ref>s birthed in <references> tags and capture their
HTML and set <references>.data-mw.body.html to the concatenated
HTML for all those child <ref> tags.
* No change in parser-tests because our test normalization code
strips data-mw before comparing results. Since this patch
only changes data-mw output for "References: 5. ..." test,
there is no change. In any case, this patch updates the
data-mw output for the test in question so that if we do
modify our normalization routines, the test will still pass.
Change-Id: Iaea752dec03e5e7f0d36baf3b7a9973f1b85e8a5
* This patch now supports any template that generates nested refs
where the top-level token is just a single-ref.
Ex: {{efn|New timetable{{sfn|Vallance|1991|p=31}}}}
* The solution in this patch removes the hack from the previous
version (53bbcbb3). As documented in the bug report, this
solution essentially "trusts" template authors and lets
nested refs through when they come from templates.
But, top-level nested refs are still not allowed.
<ref>foo<ref>bar</ref>baz</ref> in the toplevel page
will still generate a single reference with content
"foo<ref>bar</ref>baz"
* Updated the nested ref test output
- Regenerated selser changes because of the changed output.
- Regenerated blacklist because of the changed selser changes.
* This now handles:
- https://en.wikipedia.org/wiki/User:Edgepedia/VE/GNoSR
- https://en.wikipedia.org/wiki/Phellinus ellipsoideus
Change-Id: I627955f0be1c5e2bafc49647c94c2be68ce711a8
Problem:
* VisualEditor needs to be able to more reliably target Cite errors.
Solution:
* Add a more specific class to cite errors
Grumble:
* Ideally all extensions would use mw-ext-{extension name} as a prefix to
their CSS classes (or something similar).
Bug: 51337
Change-Id: If4f5360cc1c7b765ad896b14901a9b024782cc93