aboutsummaryrefslogtreecommitdiffstats
path: root/ui-summary.c
diff options
context:
space:
mode:
authorYigit Sever2021-10-29 08:07:01 +0000
committerYigit Sever2021-10-29 11:15:11 +0300
commitecd1260017d23128f7b37289be901e0fbb888992 (patch)
tree77c2bbdc33512bd558cc79c8b668869972e3914b /ui-summary.c
parentb00972235a9e2250610bb6f861a6e88d30d5a126 (diff)
downloadcgit-ecd1260017d23128f7b37289be901e0fbb888992.tar.gz
cgit-ecd1260017d23128f7b37289be901e0fbb888992.tar.bz2
cgit-ecd1260017d23128f7b37289be901e0fbb888992.zip
Lowercase everything, Rosé Pine, click to copy
And probably other little things I forgot about
Diffstat (limited to 'ui-summary.c')
-rw-r--r--ui-summary.c12
1 files changed, 8 insertions, 4 deletions
diff --git a/ui-summary.c b/ui-summary.c
index 947812a..1b65462 100644
--- a/ui-summary.c
+++ b/ui-summary.c
@@ -28,16 +28,20 @@ static void print_url(const char *url)
28 28
29 if (urls++ == 0) { 29 if (urls++ == 0) {
30 htmlf("<tr class='nohover'><td colspan='%d'>&nbsp;</td></tr>", columns); 30 htmlf("<tr class='nohover'><td colspan='%d'>&nbsp;</td></tr>", columns);
31 htmlf("<tr class='nohover'><th class='left' colspan='%d'>Clone</th></tr>\n", columns); 31 htmlf("<tr class='nohover'><th class='left' colspan='%d'>clone</th></tr>\n", columns);
32 } 32 }
33 33
34 htmlf("<tr><td colspan='%d'><a rel='vcs-git' href='", columns); 34 html("<script type='text/javascript' src='https://ajax.googleapis.com/ajax/libs/jquery/1.8.2/jquery.min.js'></script>");
35 htmlf("<tr><td colspan='%d'><a class='copy' rel='vcs-git' href='", columns);
35 html_url_path(url); 36 html_url_path(url);
36 html("' title='"); 37 html("' title='");
37 html_attr(ctx.repo->name); 38 html_attr(ctx.repo->name);
38 html(" Git repository'>"); 39 html(" git repository'>");
39 html_txt(url); 40 html_txt(url);
40 html("</a></td></tr>\n"); 41 html("</a><span class='hint'> (click to copy)</span></td></tr>\n");
42 html("<script>\n");
43 html("$(document).ready(function() { $('.copy').click(function(e) { var tmp = $('<input>'); $('body').append(tmp); tmp.val($(this).text()).select(); document.execCommand('copy'); tmp.remove(); e.preventDefault(); }); });\n");
44 html("</script>");
41} 45}
42 46
43void cgit_print_summary(void) 47void cgit_print_summary(void)