Move nav menu a bit up to create space

This is where the old nav menu used to be. This involved shrinking the
width of the locations/versions selector, but that never needed the full
page width anyway. Unfortunately I suck at CSS so the nav menu and
selector thing won't look too great on smaller screen sizes; but that's
just a minor visual uglyness.
This commit is contained in:
Yorhel 2016-11-09 18:58:31 +01:00
parent 09af881767
commit aa01365e60
2 changed files with 10 additions and 12 deletions

View file

@ -641,8 +641,17 @@ sub man {
}
return $self->resNotFound() if !$man;
my $fmt = ManUtils::html(ManUtils::fmt_block $self->dbManContent($man->{hash}));
my @toc;
$fmt =~ s{\n<b>(.+?)<\/b>\n}{
push @toc, $1;
my $c = @toc;
qq{\n<a href="#head$c" id="head$c">$1</a>\n}
}eg;
$self->setLastMod($man->{released});
$self->htmlHeader(title => $name);
_man_nav($self, $man, \@toc);
div id => 'manbuttons';
h1 $man->{name};
ul 'data-hash' => $man->{hash}, 'data-name' => $man->{name}, 'data-section' => $man->{section}, 'data-locale' => $man->{locale}||'',
@ -654,17 +663,6 @@ sub man {
div id => 'manres', class => 'hidden';
end;
my $c = $self->dbManContent($man->{hash});
my $fmt = ManUtils::html(ManUtils::fmt_block $c);
my @toc;
$fmt =~ s{\n<b>(.+?)<\/b>\n}{
push @toc, $1;
my $c = @toc;
qq{\n<a href="#head$c" id="head$c">$1</a>\n}
}eg;
_man_nav($self, $man, \@toc);
div id => 'contents';
pre; lit $fmt; end;
end;