Feature #13746

Highlighting of source link target line

Added by Filou Centrinov over 4 years ago. Updated over 4 years ago.

Status:ClosedStart date:
Priority:NormalDue date:
Assignee:-% Done:

0%

Category:UI
Target version:2.4.0
Resolution:Fixed

Description

It would be really useful if the target line from a source link is highlighted.

Example:
Source link: source:tags/2.3.0/Gemfile#L3

The 3rd line should be highlighted:

This could be done with pure css. To make the patch complete also app/views/common/_diff.html.erb and app/views/repositories/annotate.html.erb with appropriate css-modifications should be applied.

line_highlight_target.png (12.5 KB) Filou Centrinov, 2013-04-11 17:14

target_highlight.patch Magnifier (1.14 KB) Filou Centrinov, 2013-04-11 17:15


Related issues

Duplicated by Redmine - Feature #6362: Highlight lines via URL in repository browsings file view Closed 2010-09-11

Associated revisions

Revision 11857
Added by Jean-Philippe Lang over 4 years ago

Highlighting of source link target line (#13746).

Revision 11858
Added by Jean-Philippe Lang over 4 years ago

Highlighting of source link target line for annotate view (#13746).

History

#1 Updated by Etienne Massip over 4 years ago

  • Target version set to Candidate for next major release

#2 Updated by Dipan Mehta over 4 years ago

+1. This is very nice.

#3 Updated by Filou Centrinov over 4 years ago

UPDATE: There is no need to patch also app/views/common/_diff.html.erb or app/views/repositories/annotate.html.erb, because we can't set a link to a line of diff code.

#4 Updated by Mischa The Evil over 4 years ago

Filou Centrinov wrote:

UPDATE: There is no need to patch also app/views/common/_diff.html.erb or app/views/repositories/annotate.html.erb, because we can't set a link to a line of diff code.

You are right about app/views/common/_diff.html.erb which doesn't have the "clickable line #'s". app/views/repositories/annotate.html.erb on the other hand actually has the same 'line #' representation as app/views/common/_file.html.erb so in that way it would make sense to also apply this patch to this view.

Edit by MTE: of course you are right that we can't link to a line in the annotation view...

Ref: #2835 (r2527).

#5 Updated by Jean-Philippe Lang over 4 years ago

  • Status changed from New to Closed
  • Target version changed from Candidate for next major release to 2.4.0
  • Resolution set to Fixed

Patch committed in r11858, thanks! I've changed the annotate view for consistency. There's no magic link available we can still link to it manually.

#6 Updated by Toshi MARUYAMA almost 4 years ago

  • Duplicated by Feature #6362: Highlight lines via URL in repository browsings file view added

Also available in: Atom PDF