Disable buttons when no minor authors exist (#28).
This commit is contained in:
parent
937ac44e8a
commit
cb72710ed0
|
@ -67,6 +67,8 @@
|
|||
$("table#changes, table#blame").parent().find("button").filter(function() {{
|
||||
this.hiddenCount = $(this).parent().find("tbody tr:hidden").length;
|
||||
return this.hiddenCount > 0;
|
||||
}}).each(function() {{
|
||||
$(this).prop("disabled", false);
|
||||
}}).click(function() {{
|
||||
this.clicked = !this.clicked;
|
||||
|
||||
|
|
|
@ -43,7 +43,7 @@ class BlameOutput(Outputable):
|
|||
blame_xml = "<div><div class=\"box\">"
|
||||
blame_xml += "<h1>" + _(BLAME_INFO_TEXT) + "</h1><hr /><div>"
|
||||
blame_xml += "<button type=\"button\" class=\"btn btn-primary\""
|
||||
blame_xml += " data-toggle=\"button\" aria-pressed=\"false\" autocomplete=\"off\">"
|
||||
blame_xml += " data-toggle=\"button\" aria-pressed=\"false\" autocomplete=\"off\" disabled>"
|
||||
blame_xml += " <span>✓</span> " + _("Show minor authors")
|
||||
blame_xml += "</button>"
|
||||
blame_xml += "<table id=\"blame\" class=\"table table-striped\">"
|
||||
|
|
|
@ -46,7 +46,7 @@ class ChangesOutput(Outputable):
|
|||
if authorinfo_list:
|
||||
changes_xml += "<h1>" + _(HISTORICAL_INFO_TEXT) + "</h1><hr /><div>"
|
||||
changes_xml += "<button type=\"button\" class=\"btn btn-primary\""
|
||||
changes_xml += " data-toggle=\"button\" aria-pressed=\"false\" autocomplete=\"off\">"
|
||||
changes_xml += " data-toggle=\"button\" aria-pressed=\"false\" autocomplete=\"off\" disabled>"
|
||||
changes_xml += " <span>✓</span> " + _("Show minor authors")
|
||||
changes_xml += "</button>"
|
||||
changes_xml += "<table id=\"changes\" class=\"table table-striped\">"
|
||||
|
|
Loading…
Reference in New Issue