update hyperdown
This commit is contained in:
File diff suppressed because one or more lines are too long
@@ -819,7 +819,7 @@
|
||||
}
|
||||
|
||||
parseList(lines, value, start) {
|
||||
var html, j, key, l, last, len, len1, line, matches, row, rows, space, suffix, tab, type;
|
||||
var html, j, key, l, last, len, len1, line, matches, olStart, row, rows, space, suffix, tab, type;
|
||||
html = '';
|
||||
[space, type, tab] = value;
|
||||
rows = [];
|
||||
@@ -829,9 +829,9 @@
|
||||
line = lines[key];
|
||||
if (matches = line.match(new RegExp(`^(\\s{${space}})((?:[0-9]+\\.?)|\\-|\\+|\\*)(\\s+)(.*)$`))) {
|
||||
if (type === 'ol' && key === 0) {
|
||||
start = parseInt(matches[2]);
|
||||
if (start !== 1) {
|
||||
suffix = ' start="' + start + '"';
|
||||
olStart = parseInt(matches[2]);
|
||||
if (olStart !== 1) {
|
||||
suffix = ' start="' + olStart + '"';
|
||||
}
|
||||
}
|
||||
rows.push([matches[4]]);
|
||||
|
||||
@@ -1453,10 +1453,10 @@ class HyperDown
|
||||
foreach ($lines as $key => $line) {
|
||||
if (preg_match("/^(\s{" . $space . "})((?:[0-9]+\.?)|\-|\+|\*)(\s+)(.*)$/i", $line, $matches)) {
|
||||
if ($type == 'ol' && $key == 0) {
|
||||
$start = intval($matches[2]);
|
||||
$olStart = intval($matches[2]);
|
||||
|
||||
if ($start != 1) {
|
||||
$suffix = ' start="' . $start . '"';
|
||||
if ($olStart != 1) {
|
||||
$suffix = ' start="' . $olStart . '"';
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user