|mediawiki/extensions/timeline : master||Replace deprecated <tt> tag with custom styled <div> tag in error output|
|mediawiki/extensions/timeline : master||Replace deprecated <tt> tag with <samp> tag in error output|
Probably CSS, since the way it is used at
doesn't look like something where pre, code, kbd, var or samp would be valid.
Looking at other MediaWiki extensions using <div class="error">, I see stuff like
$this->getOutput()->wrapWikiMsg( '<div class="error">$1</div>', $args );
so I guess this should not set <tt> or any CSS at all but leave the rendering to whatever CSS is defined for class="error".
On the other hand, the current output seem to be several lines. So just dropping <tt> will make that less readable. Should it really output the version number, for example? I doubt.
Imported and published as a GCI task in https://codein.withgoogle.com/tasks/5500338910003200/ but the student will have to thoroughly test the output!
I was looking right now at what caused some TT tags to appear on it.wiki and, as I realized that it was due to this extension, I started to set up a patch. Fortunately I've seen this task before doing anything :-) FYI on it.wiki we replaced TTs with KBDs, and the result is the same with the three tags. Also, if you need to have the error message on multiple line, where tt would break, we used a DIV with style "font-family: monospace; font-size:14px" which perfectly replicates the TT's behaviour.