List for cgit developers and users
 help / color / mirror / Atom feed
From: petr.vorel at gmail.com (Petr Vorel)
Subject: [PATCH 1/1] ui-log: Show count of displayed commits
Date: Sun, 14 Apr 2019 15:57:41 +0200	[thread overview]
Message-ID: <20190414135741.967-1-petr.vorel@gmail.com> (raw)

+ add CSS formatting.

Signed-off-by: Petr Vorel <petr.vorel at gmail.com>
---
 cgit.css | 5 +++++
 ui-log.c | 4 +++-
 2 files changed, 8 insertions(+), 1 deletion(-)

diff --git a/cgit.css b/cgit.css
index d4aadbf..ca74508 100644
--- a/cgit.css
+++ b/cgit.css
@@ -893,3 +893,8 @@ div#cgit table.ssdiff td.space {
 div#cgit table.ssdiff td.space div {
 	min-height: 3em;
 }
+div#cgit div#count {
+	font-size: 90%;
+	padding-top: 10px;
+	padding-left: 6px;
+}
diff --git a/ui-log.c b/ui-log.c
index 3bcb657..b88e95e 100644
--- a/ui-log.c
+++ b/ui-log.c
@@ -515,7 +515,9 @@ void cgit_print_log(const char *tip, int ofs, int cnt, char *grep, char *pattern
 		commit->parents = NULL;
 	}
 	if (pager) {
-		html("</table><ul class='pager'>");
+		html("</table>");
+		htmlf("<div id='count'>Displayed items: %d</div>", i);
+		html("<ul class='pager'>");
 		if (ofs > 0) {
 			html("<li>");
 			cgit_log_link("[prev]", NULL, NULL, ctx.qry.head,
-- 
2.20.1



                 reply	other threads:[~2019-04-14 13:57 UTC|newest]

Thread overview: [no followups] expand[flat|nested]  mbox.gz  Atom feed

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20190414135741.967-1-petr.vorel@gmail.com \
    --to=cgit@lists.zx2c4.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).