Updated mediawiki/extensions Project: mediawiki/extensions/ContentTranslation d9ce8c3aac7564482f89115611db58ec98606bfe
Rewrite the links module
Brief summary of features:
- Adapt links in translation
- Mark the unadapted links gray
- Mark the red links in source section as red
- Link pair highlighting when clicked
- Fetch thumbnail for links - for links card
- Create and show link cards including missing link card
- Event handlers for Add Link, Remove Link
- Event handler for Mark as missing
- Focus handling
- Convert selection to link
- Show card for selected text
- Search links using search box
Apart from the existing links features, this patch adds features
related to red links.
A notable difference from previous links module approach is that
every link in source or target is abstracted in
CXSourceLink and CXTargetLink classes.
Both of these classes inherit CXLink. Each such link instance knows
the link pair, the link data including thumbnail image, language,
direction, title etc. They are also capable of rendering the link card.
Link cards will appear faster now since the data for showing the card
Red links in source sections will be shown red when
the corresponding section is used (added to translation).
Previously this was happening only when user clicked on
Related to the above changes, the tools manager now catches the errors
from tools if any, and prevents the whole tool system from
stopping to work.
Reference links and image links are completely in their own modules now.
Links module had some bits of that.