|
|
@ -93,18 +93,25 @@ |
|
|
|
{{range $j, $section := $file.Sections}} |
|
|
|
{{range $j, $section := $file.Sections}} |
|
|
|
{{range $k, $line := $section.Lines}} |
|
|
|
{{range $k, $line := $section.Lines}} |
|
|
|
<tr class="{{DiffLineTypeToStr .GetType}}-code nl-{{$k}} ol-{{$k}}"> |
|
|
|
<tr class="{{DiffLineTypeToStr .GetType}}-code nl-{{$k}} ol-{{$k}}"> |
|
|
|
<td class="lines-num lines-num-old"> |
|
|
|
{{if eq .GetType 4}} |
|
|
|
<span rel="{{if $line.LeftIdx}}diff-{{Sha1 $file.Name}}L{{$line.LeftIdx}}{{end}}">{{if $line.LeftIdx}}{{$line.LeftIdx}}{{end}}</span> |
|
|
|
<td class="lines-num"></td> |
|
|
|
</td> |
|
|
|
<td colspan="3" class="lines-code"> |
|
|
|
<td class="lines-code halfwidth"> |
|
|
|
<pre><code class="{{if $highlightClass}}language-{{$highlightClass}}{{else}}nohighlight{{end}}">{{$section.GetComputedInlineDiffFor $line}}</code></pre> |
|
|
|
<pre><code class="wrap {{if $highlightClass}}language-{{$highlightClass}}{{else}}nohighlight{{end}}">{{if $line.LeftIdx}}{{$section.GetComputedInlineDiffFor $line}}{{end}}</code></pre> |
|
|
|
</td> |
|
|
|
</td> |
|
|
|
{{else}} |
|
|
|
<td class="lines-num lines-num-new"> |
|
|
|
<td class="lines-num lines-num-old"> |
|
|
|
<span rel="{{if $line.RightIdx}}diff-{{Sha1 $file.Name}}R{{$line.RightIdx}}{{end}}">{{if $line.RightIdx}}{{$line.RightIdx}}{{end}}</span> |
|
|
|
<span rel="{{if $line.LeftIdx}}diff-{{Sha1 $file.Name}}L{{$line.LeftIdx}}{{end}}">{{if $line.LeftIdx}}{{$line.LeftIdx}}{{end}}</span> |
|
|
|
</td> |
|
|
|
</td> |
|
|
|
<td class="lines-code halfwidth"> |
|
|
|
<td class="lines-code halfwidth"> |
|
|
|
<pre><code class="wrap {{if $highlightClass}}language-{{$highlightClass}}{{else}}nohighlight{{end}}">{{if $line.RightIdx}}{{$section.GetComputedInlineDiffFor $line}}{{end}}</code></pre> |
|
|
|
<pre><code class="wrap {{if $highlightClass}}language-{{$highlightClass}}{{else}}nohighlight{{end}}">{{if $line.LeftIdx}}{{$section.GetComputedInlineDiffFor $line}}{{end}}</code></pre> |
|
|
|
</td> |
|
|
|
</td> |
|
|
|
|
|
|
|
<td class="lines-num lines-num-new"> |
|
|
|
|
|
|
|
<span rel="{{if $line.RightIdx}}diff-{{Sha1 $file.Name}}R{{$line.RightIdx}}{{end}}">{{if $line.RightIdx}}{{$line.RightIdx}}{{end}}</span> |
|
|
|
|
|
|
|
</td> |
|
|
|
|
|
|
|
<td class="lines-code halfwidth"> |
|
|
|
|
|
|
|
<pre><code class="wrap {{if $highlightClass}}language-{{$highlightClass}}{{else}}nohighlight{{end}}">{{if $line.RightIdx}}{{$section.GetComputedInlineDiffFor $line}}{{end}}</code></pre> |
|
|
|
|
|
|
|
</td> |
|
|
|
|
|
|
|
{{end}} |
|
|
|
</tr> |
|
|
|
</tr> |
|
|
|
{{end}} |
|
|
|
{{end}} |
|
|
|
{{end}} |
|
|
|
{{end}} |
|
|
|