Skip to content

Commit 8c73436

Browse files
committed
Added definition lists
Fixed debugging code that should not have been active.
1 parent fbc5af1 commit 8c73436

File tree

1 file changed

+6
-3
lines changed

1 file changed

+6
-3
lines changed

lib/Pod/To/HTML.pm

Lines changed: 6 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -45,7 +45,7 @@ my @body;
4545
my @footnotes;
4646
my %crossrefs;
4747

48-
sub Debug(Callable $) { } # Disable debug code
48+
sub Debug(Callable $) { } # Disable debug code
4949
#sub Debug(Callable $c) { $c() } # Enable debug code
5050

5151
sub escape_html(Str $str) returns Str {
@@ -327,8 +327,11 @@ multi sub node2html(Pod::Block::Named $node) {
327327
}
328328
when 'para' { return node2html($node.contents[0]); }
329329
when 'defn' {
330-
return node2html($node.contents[0]) ~ "\n"
331-
~ node2html($node.contents[1..*-1]);
330+
return "<dl>" ~
331+
"<dt>" ~ node2html($node.contents[0].contents[1]) ~ "</dt>" ~
332+
"<dd>" ~ node2html($node.contents[0].contents[2..*-1]) ~ "</dd>" ~
333+
"</dl>\n" ~
334+
node2html($node.contents[1..*-1]);
332335
}
333336
when 'Image' {
334337
my $url;

0 commit comments

Comments
 (0)