git/list[1] front-page[2] threads[3] people[4] search[5] about
 

[PATCH] gitweb: Add title attribute to ref marker with full ref name

From
Jakub Narebski <jnareb@gmail.com>
Date
Dec 15, 2006, 22:49 UTC
Message-ID
<1166222952562-git-send-email-jnareb@gmail.com>

Add title attribute, which will be shown as popup on mouseover in graphical web browsers, with full name of ref, including part (type) removed from the name of ref itself. This is useful to see that this strange ref is StGIT ref, or it is remote branch, or it is lightweigh tag (with branch-like name).

Signed-off-by: Jakub Narebski <jnareb@gmail.com>
---
 gitweb/gitweb.perl |    3 ++-
 1 files changed, 2 insertions(+), 1 deletions(-)
diff --git a/gitweb/gitweb.perl b/gitweb/gitweb.perl
index 5ea3fda..5eaab05 100755
--- a/gitweb/gitweb.perl
+++ b/gitweb/gitweb.perl
@@ -856,7 +856,8 @@ sub format_ref_marker {
 				$name = $ref;
 			}
 
-			$markers .= " <span class=\"$type\">" . esc_html($name) . "</span>";
+			$markers .= " <span class=\"$type\" title=\"$ref\">" .
+			            esc_html($name) . "</span>";
 		}
 	}
 
-- 
1.4.4.1
Message 1 of 1 in “gitweb: Add title attribute to ref marker with full ref name”
  1. gitweb: Add title attribute to ref marker with full ref nameJakub Narebski, Dec 15, 2006

Read the whole thread, see it on lore, or plain text.

$ cat FOOTERMessages come from the public archive at lore.kernel.org/git, fetched every hour. The front page is chosen and written each morning by an AI editor and can be wrong; the threads themselves are the record. About and API. For agents: an MCP server at https://gitlist.dev/mcp, and any thread, story or person page as Markdown by adding .md to its URL (or sending Accept: text/markdown). Details in /llms.txt.