Browse Source

Markdown.pl: remove td, th, tr from thead and tfoot closers

Although "thead" and "tfoot" do, indeed, have an optional closing
tag, neither "td", "th" nor "tr" will auto-close them.

Therefore remove "thead" and "tfoot" from the list of tags that
"td", "th" and "tr" will auto-close.

Signed-off-by: Kyle J. McKay <mackyle@gmail.com>
master
Kyle J. McKay 4 years ago
parent
commit
f9a023d56a
  1. 6
      Markdown.pl

6
Markdown.pl

@ -3103,11 +3103,11 @@ BEGIN {
'dt' => { map({$_ => 1} qw(colgroup dd dt li p)) }, 'dt' => { map({$_ => 1} qw(colgroup dd dt li p)) },
'li' => { map({$_ => 1} qw(colgroup dd dt li p)) }, 'li' => { map({$_ => 1} qw(colgroup dd dt li p)) },
'tbody' => \%tagocl, 'tbody' => \%tagocl,
'td' => { map({$_ => 1} qw(colgroup dd dt li p td tfoot th thead)) }, 'td' => { map({$_ => 1} qw(colgroup dd dt li p td th)) },
'tfoot' => \%tagocl, 'tfoot' => \%tagocl,
'th' => { map({$_ => 1} qw(colgroup dd dt li p td tfoot th thead)) }, 'th' => { map({$_ => 1} qw(colgroup dd dt li p td th)) },
'thead' => \%tagocl, 'thead' => \%tagocl,
'tr' => { map({$_ => 1} qw(colgroup dd dt li p td tfoot th thead tr)) }, 'tr' => { map({$_ => 1} qw(colgroup dd dt li p td th tr)) },
); );
%tagblk = map({$_ => 1} qw(address blockquote center div dl h1 h2 h3 h4 h5 h6 hr ol p pre table ul)); %tagblk = map({$_ => 1} qw(address blockquote center div dl h1 h2 h3 h4 h5 h6 hr ol p pre table ul));
%taginl = map({$_ => 1} qw(a abbr acronym b basefont bdo big br cite code dfn em font i %taginl = map({$_ => 1} qw(a abbr acronym b basefont bdo big br cite code dfn em font i

Loading…
Cancel
Save