mirror of
https://github.com/lrsjng/h5ai.git
synced 2025-05-28 14:04:45 -04:00
More update on text preview.
This commit is contained in:
parent
74b0ec827b
commit
b92298d007
2 changed files with 17 additions and 8 deletions
|
@ -155,7 +155,7 @@ modulejs.define('ext/preview-txt', ['_', '$', 'core/settings', 'core/resource',
|
|||
var $text = $('#pv-txt-text'),
|
||||
$lineNos = $text.find('td.gutter .line').addClass('cntlinenr'),
|
||||
$codeLines = $text.find('td.code .line').addClass('cntline'),
|
||||
$table = $('<table/>'),
|
||||
$table = $('<table/>').addClass('syntaxhighlighter'),
|
||||
i, $tr;
|
||||
|
||||
for (i = 0; i < $lineNos.length; i += 1) {
|
||||
|
@ -165,7 +165,7 @@ modulejs.define('ext/preview-txt', ['_', '$', 'core/settings', 'core/resource',
|
|||
$table.append($tr);
|
||||
}
|
||||
|
||||
$text.find('table').replaceWith($table);
|
||||
$text.find('.syntaxhighlighter').replaceWith($table);
|
||||
}
|
||||
});
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue