mirror of
https://gitlab.gnome.org/GNOME/gitg
synced 2024-08-27 20:09:23 +00:00
Show diff type in gutter
This commit is contained in:
parent
21909908d1
commit
d4d1d45952
|
@ -21,6 +21,7 @@ function diff_file(file, lnstate, data)
|
|||
file_body += '<tr class="context">\
|
||||
<td class="gutter old">' + lnstate.gutterdots + '</td>\
|
||||
<td class="gutter new">' + lnstate.gutterdots + '</td>\
|
||||
<td class="gutter type"> </td>\
|
||||
<td></td>\
|
||||
</tr>';
|
||||
continue;
|
||||
|
@ -36,6 +37,7 @@ function diff_file(file, lnstate, data)
|
|||
file_body += '<tr class="hunk_header">\
|
||||
<td class="gutter old">' + lnstate.gutterdots + '</td> \
|
||||
<td class="gutter new">' + lnstate.gutterdots + '</td> \
|
||||
<td class="gutter type"> </td> \
|
||||
<td class="hunk_header">' + hunk_header + '</td> \
|
||||
</tr>';
|
||||
|
||||
|
@ -78,13 +80,20 @@ function diff_file(file, lnstate, data)
|
|||
row += 'context"> \
|
||||
<td class="gutter old"></td> \
|
||||
<td class="gutter new"></td>';
|
||||
l.content = l.content.substr(1, l.content.length);
|
||||
l.content = l.content.substr(1, l.content.length);
|
||||
break;
|
||||
default:
|
||||
o = ' ';
|
||||
row += '">';
|
||||
break;
|
||||
}
|
||||
|
||||
if (o == ' ')
|
||||
{
|
||||
o = ' ';
|
||||
}
|
||||
|
||||
row += '<td class="gutter type">' + o + '</td>';
|
||||
row += '<td class="code">' + html_escape(l.content).replace(/\t/g, tabrepl) + '</td>';
|
||||
|
||||
row += '</tr>';
|
||||
|
|
|
@ -188,11 +188,12 @@ div#diff div.file table td {
|
|||
vertical-align: top;
|
||||
}
|
||||
|
||||
div#diff div.file table td.gutter.new {
|
||||
div#diff div.file table td.gutter.type {
|
||||
border-right: 3px solid #d3d7cf;
|
||||
padding: 0px 3px 0px 3px;
|
||||
}
|
||||
|
||||
div#diff div.file table tr.hunk_header td.gutter.new {
|
||||
div#diff div.file table tr.hunk_header td.gutter.type {
|
||||
border: 0;
|
||||
}
|
||||
|
||||
|
|
|
@ -23,13 +23,14 @@
|
|||
<div class="file ${FILE_CLASSES}" data-filename="${FILE_FILENAME}">
|
||||
<table class="file">
|
||||
<colgroup>
|
||||
<col width="0">
|
||||
<col width="0">
|
||||
<col width="0">
|
||||
<col width="100%">
|
||||
</colgroup>
|
||||
<tbody>
|
||||
<tr class="file_header">
|
||||
<td colspan="3">
|
||||
<td colspan="4">
|
||||
<span class="expander">-</span>
|
||||
<!-- ${FILE_STATS} -->
|
||||
<span class="file_path"><!-- ${FILE_PATH} --></span>
|
||||
|
|
Loading…
Reference in a new issue