Add link to index page from repo header, remove page name

This makes it more obvious how to get back to the index, especially when the
config option `logo-link` is used. And the page name displayed in the header
provided no extra information. It only consumed space and deserved to die.

While at it, make sure that the different parts of the header doesn't wrap
when horizontal space is limited.

Signed-off-by: Lars Hjemli <hjemli@gmail.com>
This commit is contained in:
Lars Hjemli 2008-05-03 12:44:20 +02:00
parent aa3c4486b4
commit 17890d0058
2 changed files with 5 additions and 2 deletions

View File

@ -36,6 +36,7 @@ table#header td.logo {
table#header td.main { table#header td.main {
font-size: 250%; font-size: 250%;
padding-left: 10px; padding-left: 10px;
white-space: nowrap;
} }
table#header td.main a { table#header td.main a {
@ -47,6 +48,7 @@ table#header td.form {
vertical-align: bottom; vertical-align: bottom;
padding-right: 1em; padding-right: 1em;
padding-bottom: 2px; padding-bottom: 2px;
white-space: nowrap;
} }
table#header td.form form, table#header td.form form,
@ -92,6 +94,7 @@ table.tabs td.form {
table.tabs td.form form { table.tabs td.form form {
padding-bottom: 2px; padding-bottom: 2px;
font-size: 90%; font-size: 90%;
white-space: nowrap;
} }
table.tabs td.form input, table.tabs td.form input,

View File

@ -545,10 +545,10 @@ void cgit_print_pageheader(struct cgit_context *ctx)
html("<td class='main'>"); html("<td class='main'>");
if (ctx->repo) { if (ctx->repo) {
cgit_index_link("index", NULL, NULL, NULL, 0);
html(" : ");
reporevlink(NULL, ctx->repo->name, NULL, hc(cmd, "summary"), reporevlink(NULL, ctx->repo->name, NULL, hc(cmd, "summary"),
ctx->qry.head, NULL, NULL); ctx->qry.head, NULL, NULL);
html(" : ");
html_txt(ctx->qry.page);
html("</td><td class='form'>"); html("</td><td class='form'>");
html("<form method='get' action=''>\n"); html("<form method='get' action=''>\n");
add_hidden_formfields(0, 1, ctx->qry.page); add_hidden_formfields(0, 1, ctx->qry.page);