Closed NovemLinguae closed 1 year ago
similar fix for wikidataInfo.js was like this: https://www.wikidata.org/w/index.php?title=User%3AYair_rand%2FWikidataInfo.js&diff=1915953494&oldid=1892012477
the subtitle is commonly used for the "redirected from [xxx]" line, adding the tool's information below should just work fine.
Thanks, I implemented that fix and seems to work well.
@jdlrobson Jon (WMF) recommends that we try to use
mw.util.addSubtitle()
instead of jQuery. This will make things less prone to breakage in the future if skin HTML tag hierarchies or styles change.I haven't checked if we can just spawn
#sdh
inside of#mw-content-subtitle
yet without breaking styling and functionality, but worth checking. If that technique were to work, we could probably revert patch #10Do normal pages ever put anything in the subtitle? If there were already an existing subtitle, using
mw.util.addSubtitle()
would jam both the existing text and this gadget in there.Current HTML hierarchy using jQuery:
Renders this:![image](https://github.com/wikimedia-gadgets/shortdesc-helper/assets/79697282/2dd3076e-9558-4e77-a58b-96cdbb062c64)