diff --git a/gitinspector/html/html.header b/gitinspector/html/html.header
index 922e049..7733915 100644
--- a/gitinspector/html/html.header
+++ b/gitinspector/html/html.header
@@ -16,17 +16,6 @@
var MINOR_AUTHOR_PERCENTAGE = 1.00;
var isReversed = false;
- var colorRows = function() {{
- $(this).removeClass("odd");
-
- if (row++ % 2 == 1) {{
- $(this).addClass("odd");
- }}
-
- if(this == $(this).parent().find("tr:visible").get(-1)) {{
- row = 0;
- }}
- }}
// Fix header and set it to the right width.
var remainingHeaderWidth = ($("div.logo").width() - 4) - ($("div.logo img").innerWidth() + 48)
@@ -46,25 +35,23 @@
}}).hide();
}}
- $("table#changes tbody tr td:last-child").filter(function() {{
- return parseFloat(this.innerHTML) < MINOR_AUTHOR_PERCENTAGE;
- }}).parent().hide();
-
- $("table#blame tbody tr td:last-child").filter(function() {{
- return parseFloat(this.innerHTML) < MINOR_AUTHOR_PERCENTAGE;
- }}).parent().hide();
-
- $("table.git tbody tr:visible").each(colorRows);
-
$("table#changes, table#blame").tablesorter({{
sortList: [[0,0]],
headers: {{
0: {{ sorter: "text" }}
}}
- }}).bind("sortEnd", function() {{
- $(this).find("tbody tr:visible").each(colorRows);
}});
+ $("table#changes tbody tr td:last-child").filter(function() {{
+ return parseFloat(this.innerHTML) < MINOR_AUTHOR_PERCENTAGE;
+ }}).parent().each(function() {{
+ $(this).after("
").hide();
+ }}).hide();
+
+ $("table#blame tbody tr td:last-child").filter(function() {{
+ return parseFloat(this.innerHTML) < MINOR_AUTHOR_PERCENTAGE;
+ }}).parent().hide();
+
$("table#changes thead tr th, table#blame thead tr th").click(function() {{
$(this).parent().find("th strong").remove();
var parentIndex = $(this).index();
@@ -82,7 +69,7 @@
$(this).append(" ∨");
}});
- $("table.git tfoot tr td:first-child").filter(function() {{
+ $("table#changes tfoot tr td:first-child").filter(function() {{
this.hiddenCount = $(this).parent().parent().parent().find("tbody tr:hidden").length;
return this.hiddenCount > 0;
}}).each(function() {{
@@ -93,20 +80,21 @@
if (this.clicked) {{
this.innerHTML = "{hide_minor_authors} (" + this.hiddenCount + ") ∧";
- $(this).parent().parent().parent().find("tbody tr").show().each(colorRows);
+ $(this).parent().parent().parent().find("tbody tr:empty").remove();
+ $(this).parent().parent().parent().find("tbody tr").show();
}} else {{
this.innerHTML = "{show_minor_authors} (" + this.hiddenCount + ") ∨";
$(this).parent().parent().parent().find("tbody tr td:last-child").filter(function() {{
return parseFloat(this.innerHTML) < MINOR_AUTHOR_PERCENTAGE;
- }}).parent().hide();
- $("table.git tbody tr:visible").each(colorRows);
+ }}).parent().each(function() {{
+ $(this).after("
").hide();
+ }}).hide();
}}
}});
filterResponsibilities();
var hiddenResponsibilitiesCount = $("div#responsibilities div h3:hidden").length;
if (hiddenResponsibilitiesCount > 0) {{
- $("div#responsibilities div h3:visible").each(colorRows);
$("div#responsibilities").prepend("{show_minor_authors} (" + hiddenResponsibilitiesCount + ") ∨
");
$("div#responsibilities div.button").click(function() {{
@@ -125,7 +113,6 @@
filterTimeLine();
var hiddenTimelineCount = $("div#timeline table.git tbody tr:hidden").length;
if (hiddenTimelineCount > 0) {{
- $("div#timeline table.git tbody tr:visible").each(colorRows);
$("div#timeline").prepend("{show_minor_rows} (" + hiddenTimelineCount + ") ∨
");
$("div#timeline div.button").click(function() {{
@@ -136,7 +123,6 @@
}} else {{
this.innerHTML = "{show_minor_rows} (" + hiddenTimelineCount + ") ∨";
filterTimeLine();
- $("div#timeline table.git tbody tr:visible").each(colorRows);
}}
}});
}}
@@ -208,39 +194,68 @@
-
+
{repo_text}
{logo_text}
diff --git a/gitinspector/output/blameoutput.py b/gitinspector/output/blameoutput.py
index 677b432..5672960 100644
--- a/gitinspector/output/blameoutput.py
+++ b/gitinspector/output/blameoutput.py
@@ -41,7 +41,7 @@ class BlameOutput(Outputable):
def output_html(self):
blame_xml = "
"
- blame_xml += "
" + _(BLAME_INFO_TEXT) + ".
"
+ blame_xml += "" + _(BLAME_INFO_TEXT) + "
"
blame_xml += " {0} | {1} | {2} | {3} | {4} |
".format(
_("Author"), _("Rows"), _("Stability"), _("Age"), _("% in comments"))
blame_xml += ""
diff --git a/gitinspector/output/changesoutput.py b/gitinspector/output/changesoutput.py
index 7a6b773..a837a2e 100644
--- a/gitinspector/output/changesoutput.py
+++ b/gitinspector/output/changesoutput.py
@@ -44,7 +44,7 @@ class ChangesOutput(Outputable):
total_changes += authorinfo_list.get(i).deletions
if authorinfo_list:
- changes_xml += "" + _(HISTORICAL_INFO_TEXT) + ".
"
+ changes_xml += "" + _(HISTORICAL_INFO_TEXT) + "
"
changes_xml += " {0} | {1} | {2} | {3} | {4} | ".format(
_("Author"), _("Commits"), _("Insertions"), _("Deletions"), _("% of changes"))
changes_xml += "
"
@@ -52,8 +52,7 @@ class ChangesOutput(Outputable):
for i, entry in enumerate(sorted(authorinfo_list)):
authorinfo = authorinfo_list.get(entry)
percentage = 0 if total_changes == 0 else (authorinfo.insertions + authorinfo.deletions) / total_changes * 100
-
- changes_xml += "" if i % 2 == 1 else ">")
+ changes_xml += "
"
if format.get_selected() == "html":
changes_xml += " {1} | ".format(
@@ -90,7 +89,7 @@ class ChangesOutput(Outputable):
changes_xml += " });"
changes_xml += ""
else:
- changes_xml += "" + _(NO_COMMITED_FILES_TEXT) + ".
"
+ changes_xml += "" + _(NO_COMMITED_FILES_TEXT) + "
"
changes_xml += ""
print(changes_xml)