Vote #73754
完了Highlighting of source link target line
0%
説明
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:
!line_highlight_target.png!
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.
journals
--------------------------------------------------------------------------------
+1. This is very nice.
--------------------------------------------------------------------------------
UPDATE: There is no need to patch also <code>app/views/common/_diff.html.erb</code> or <code>app/views/repositories/annotate.html.erb</code>, because we can't set a link to a line of diff code.
--------------------------------------------------------------------------------
Filou Centrinov wrote:
> UPDATE: There is no need to patch also <code>app/views/common/_diff.html.erb</code> or <code>app/views/repositories/annotate.html.erb</code>, because we can't set a link to a line of diff code.
You are right about <code>app/views/common/_diff.html.erb</code> which doesn't have the "clickable line #'s". <code>app/views/repositories/annotate.html.erb</code> on the other hand actually has the same 'line #' representation as <code>app/views/common/_file.html.erb</code> 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).
--------------------------------------------------------------------------------
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.
--------------------------------------------------------------------------------
--------------------------------------------------------------------------------
related_issues
duplicates,Closed,6362,Highlight lines via URL in repository browsings file view