Page MenuHomePhabricator

html generated by GeSHi SyntaxHighlight <source> does not have a consistent class.
Closed, DuplicatePublic

Description

Author: herd

Description:
For example, a <source lang="php"> can generate, depending on GeSHi configuration/version:

<div dir="ltr" style="text-align: left;">
<pre class="source-php">

or

<div dir="ltr" style="text-align: left;">
<div class="php source-php" style="font-family:monospace;">
<pre class="de1">

In both cases, the outermost div should have a consistent class, such as class="geshi" so that styles can be applied to the divs, as well as the descendant (child or grandchild) <pre> arbitrarily (to the exclusion of native pre tags) in [[MediaWiki:Geshi.css]].


Version: unspecified
Severity: minor

Details

Reference
bz16324

Event Timeline

bzimport raised the priority of this task from to Medium.Nov 21 2014, 10:26 PM
bzimport added a project: SyntaxHighlight.
bzimport set Reference to bz16324.
bzimport added a subscriber: Unknown Object (MLST).

herd wrote:

Probably fixed in r52346. class="mw-geshi" will appear on outermost div or span. Should now be possible to re-add the dashed border with:

div.mw-geshi {padding: 1em;border: 1px dashed #2f6fab;}

Note that removing the border from the <pre> is still typically correct, as it isn't the optimal place to re-add it if multiple pre exist in a code block (as in some situations/versions).

Ms2ger wrote:

*** Bug 11274 has been marked as a duplicate of this bug. ***

obsolete.fax wrote:

*** This bug has been marked as a duplicate of bug 11274 ***