Enhancement request : ui-blob: Make the target line of a link, visually identifiable.

Loïc lagiraudiere+cgit at free.fr
Sun Apr 14 21:56:48 UTC 2024

Le 10/04/2024 à 15:29, Christian Hesse a écrit :
> Loïc <lagiraudiere+cgit at free.fr> on Sat, 2024/02/03 18:20:
>> Hi all,
>> When I create a reference to a precise line in a file (for instance a
>> hyperlink to "https://git.zx2c4.com/cgit/tree/cgit.css#n321" ), I miss a
>> visual feedback, on the line I want to highlight.
>> To implement this feature, I suggest to add a curved arrow ahead of the
>> line number.
>> That could be done by adding the following stylesheet to cgit.css
>>      div#cgit table.blob td.linenumbers a:target:before {color:
>> red;content: "\2BA9";}
> I really like that functionality, though the curved arrow is really
> inconspicuous. Wondering if something like "large red circle" (or "large
> black circle", colored in red) would be a better match...

Unfortunately, the size is constrained by the underlying font.

Initially, I searched for a character like "BLACK RIGHT POINTING 
BACKHAND INDEX" or "LINK SYMBOL", but it was even smaller. I also tried 
to change the font size but it didn't produce a good result either since 
it changes the line height.

So, feel free to change the mark to something more convenient. The 
"large black circle" (\2B24), colored in red seems fine. (I prefer the 
"BLACK LARGE CIRCLE" colored in red over the "LARGE RED CIRCLE" because 
it makes it easier to change the color)

More information about the CGit mailing list