Website Summary Files Commits Branches @commit @diff @stats
path: root / ui-diff.c
diff options
context:
space:
mode:
Commit6494c4defa9e6dc24e13af9d17d25aea793359fc (patch)
Author
 Syndamia <kamen@syndamia.com>
2026-09-27 22:04:58 +0300
Committer
 Syndamia <kamen@syndamia.com>
2026-09-27 22:17:50 +0300
Files122bbddfdd14e55587e3103e2b842f60a1027eeb /ui-diff.c
cgit-6494c4defa9e6dc24e13af9d17d25aea793359fc.tar
cgit-6494c4defa9e6dc24e13af9d17d25aea793359fc.tar.gz
cgit-6494c4defa9e6dc24e13af9d17d25aea793359fc.zip
Parent63aa2ecd4e72800c11b08e4fb94234a117ece029 (diff)
ui-diff: (THEME) Rework layout of file diff
1 files changed, 6 insertions, 13 deletions
-rw-r--r--ui-diff.c19
diff --git a/ui-diff.c b/ui-diff.c
index 6cfa697..f071c60 100644
--- a/ui-diff.c
+++ b/ui-diff.c
@@ -195,25 +195,18 @@ static void cgit_print_diffstat(const struct object_id *old_oid,
{
int i;
- html("<div class='diffstat-header'>");
- cgit_diff_link("Diffstat", NULL, NULL, ctx.qry.head, ctx.qry.oid,
- ctx.qry.oid2, NULL);
- if (prefix) {
- html(" (limited to '");
- html_txt(prefix);
- html("')");
- }
- html("</div>");
- html("<table summary='diffstat' class='diffstat'>");
+ html("<div class='diffstat-container'>");
+ html("<div class='diffstat-summary'>");
max_changes = 0;
cgit_diff_tree(old_oid, new_oid, inspect_filepair, prefix,
ctx.qry.ignorews);
+ htmlf("%d files changed, <span class='add'>%d</span> insertions, <span class='del'>%d</span> deletions",
+ files, total_adds, total_rems);
+ html("</div>");
+ html("<table summary='diffstat' class='diffstat'>");
for (i = 0; i<files; i++)
print_fileinfo(&items[i]);
html("</table>");
- html("<div class='diffstat-summary'>");
- htmlf("%d files changed, %d insertions, %d deletions",
- files, total_adds, total_rems);
html("</div>");
}