Enable line numbers on code content pages

Bug: T32773
Change-Id: I2eb8dcfe4d7bf751f998e1b2dd26a23cce69bf34
This commit is contained in:
Ed Sanders 2020-12-30 14:45:32 +00:00
parent 98c644a639
commit 10ec5067c5

View file

@ -523,7 +523,7 @@ class SyntaxHighlight {
->parse( $text, $title, $options, true, true, $revId );
}
$status = self::highlight( $text, $lexer );
$status = self::highlight( $text, $lexer, [ 'line' => true ] );
if ( !$status->isOK() ) {
return true;
}
@ -533,7 +533,7 @@ class SyntaxHighlight {
'class' => self::HIGHLIGHT_CSS_CLASS,
'dir' => 'ltr'
];
self::addExtraAttributes( $htmlAttribs, $lexer );
self::addExtraAttributes( $htmlAttribs, $lexer, false, true );
$output->addModuleStyles( 'ext.pygments' );
$output->setText(