diff --git a/src/line-by-line-printer.js b/src/line-by-line-printer.js index 6086bec..ae12ebd 100644 --- a/src/line-by-line-printer.js +++ b/src/line-by-line-printer.js @@ -23,17 +23,20 @@ LineByLinePrinter.prototype.makeFileDiffHtml = function(file, diffs) { var fileDiffTemplate = hoganUtils.template(baseTemplatesPath, 'file-diff'); + var filePathTemplate = hoganUtils.template(baseTemplatesPath, 'file-path'); var fileIconTemplate = hoganUtils.template(iconsBaseTemplatesPath, 'file'); var fileTagTemplate = hoganUtils.template(tagsBaseTemplatesPath, printerUtils.getFileTypeIcon(file)); return fileDiffTemplate.render({ file: file, - fileDiffName: printerUtils.getDiffName(file), fileHtmlId: printerUtils.getHtmlId(file), - diffs: diffs - }, { - fileIcon: fileIconTemplate, - fileTag: fileTagTemplate + diffs: diffs, + filePath: filePathTemplate.render({ + fileDiffName: printerUtils.getDiffName(file) + }, { + fileIcon: fileIconTemplate, + fileTag: fileTagTemplate + }) }) }; diff --git a/src/templates/diff2html-templates.js b/src/templates/diff2html-templates.js index 0dd9b78..1ed0580 100644 --- a/src/templates/diff2html-templates.js +++ b/src/templates/diff2html-templates.js @@ -9,7 +9,8 @@ global.browserTemplates["icon-file-renamed"] = new Hogan.Template({code: functio global.browserTemplates["icon-file"] = new Hogan.Template({code: function (c,p,i) { var t=this;t.b(i=i||"");t.b("");return t.fl(); },partials: {}, subs: { }}); global.browserTemplates["line-by-line-column-line-number"] = new Hogan.Template({code: function (c,p,i) { var t=this;t.b(i=i||"");t.b("