From e1b24b557d00407fb96755c34a8956afff56a51a Mon Sep 17 00:00:00 2001 From: Bryce Kwon Date: Sat, 26 Sep 2026 08:38:40 -1000 Subject: Add stable markup hooks for site themes --- source/ui-repolist.c | 17 ++++++++++------- 1 file changed, 10 insertions(+), 7 deletions(-) (limited to 'source/ui-repolist.c') diff --git a/source/ui-repolist.c b/source/ui-repolist.c index 031cb0d..6dcc976 100644 --- a/source/ui-repolist.c +++ b/source/ui-repolist.c @@ -181,7 +181,7 @@ static int any_repos_visible(void) */ static void print_column_header(const char *title, const char *column, const char *currenturl) { - htmlf(""); + html("\n"); print_column_header("Name", "name", currenturl); print_column_header("Description", "desc", currenturl); if (ctx.cfg.enable_index_owner) print_column_header("Owner", "owner", currenturl); print_column_header("Idle", "idle", currenturl); if (ctx.cfg.enable_index_links) - html("Links"); + html("Links"); html("\n"); } @@ -224,7 +224,8 @@ static void print_repo_row(const char *currenturl, int sublevel) { char *repourl; - htmlf("", sublevel ? "sublevel-repo" : "toplevel-repo"); + htmlf("", + sublevel ? "sublevel-repo" : "toplevel-repo"); cgit_summary_link(ctx.repo->name, NULL, NULL, NULL); html(""); repourl = cgit_repourl(ctx.repo->url); @@ -267,7 +268,7 @@ static void print_pager(int total, int pagelen, char *search, char *sort) int i, ofs; char *class; - html("\n"); } static int cmp_str(const char *s1, const char *s2) @@ -420,7 +421,7 @@ void cgit_print_repolist(void) sort_repolist("section"); currenturl = cgit_currenturl(); - html("\n"); + html("
\n"); for (i = 0; i < cgit_repolist.count; i++) { char *section; @@ -448,6 +449,8 @@ void cgit_print_repolist(void) } print_repo_row(currenturl, !column_sorted && section); } + if (shown) + html("\n"); html("
\n"); if (hits > ctx.cfg.max_repo_count) print_pager(hits, ctx.cfg.max_repo_count, ctx.qry.search, ctx.qry.sort); -- cgit v2.8.0