mirror of
https://gerrit.wikimedia.org/r/mediawiki/extensions/Scribunto
synced 2024-11-23 15:56:55 +00:00
ScribuntoContentHandler: Add lang="en" to fallback <pre>
It currently inherents from the mw-parser-output div, which sets it based on the documentation page (content language). Change-Id: I79847cd8cfe75598c843e96a09d9aa61b00304a9
This commit is contained in:
parent
ae8c68b051
commit
8e0684da7a
|
@ -227,8 +227,11 @@ class ScribuntoContentHandler extends CodeContentHandler {
|
|||
}
|
||||
}
|
||||
|
||||
return "<pre class='mw-code mw-script' dir='ltr'>\n" .
|
||||
htmlspecialchars( $source ) .
|
||||
"\n</pre>\n";
|
||||
return Html::element( 'pre', [
|
||||
// Same as CodeContentHandler
|
||||
'lang' => 'en',
|
||||
'dir' => 'ltr',
|
||||
'class' => 'mw-code mw-script'
|
||||
], "\n$source\n" );
|
||||
}
|
||||
}
|
||||
|
|
Loading…
Reference in a new issue