Commit 10d881c9cad92169a3105cff0f02601dad4448cf
Committed by
Dmitriy Zaporozhets
1 parent
62219aa3
Exists in
master
and in
4 other branches
Line anchors for file view
Showing
2 changed files
with
10 additions
and
5 deletions
Show diff stats
app/assets/stylesheets/gitlab_bootstrap/files.scss
| ... | ... | @@ -157,10 +157,15 @@ |
| 157 | 157 | font-size:12px !important; |
| 158 | 158 | } |
| 159 | 159 | |
| 160 | - table.highlighttable .linenodiv pre { | |
| 161 | - text-align: right; | |
| 162 | - padding-right: 4px; | |
| 163 | - color:#666; | |
| 160 | + table.highlighttable .linenodiv { | |
| 161 | + a { | |
| 162 | + color: #666; | |
| 163 | + } | |
| 164 | + pre { | |
| 165 | + text-align: right; | |
| 166 | + padding-right: 4px; | |
| 167 | + color:#666; | |
| 168 | + } | |
| 164 | 169 | } |
| 165 | 170 | } |
| 166 | 171 | } | ... | ... |
app/views/tree/blob/_text.html.haml
| ... | ... | @@ -10,6 +10,6 @@ |
| 10 | 10 | - unless blob.empty? |
| 11 | 11 | %div{class: current_user.dark_scheme ? "black" : "white"} |
| 12 | 12 | = preserve do |
| 13 | - = raw blob.colorize(options: { linenos: 'True'}) | |
| 13 | + = raw blob.colorize(options: { linenos: true, lineanchors: :line, anchorlinenos: true }) | |
| 14 | 14 | - else |
| 15 | 15 | %h4.nothing_here_message Empty file | ... | ... |