xhtml_report_generator 2.0.1 → 2.0.2
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -204,8 +204,8 @@ module Custom
|
|
204
204
|
return num_matches
|
205
205
|
end
|
206
206
|
|
207
|
-
# creates a html table from two dimensional array of the form Array[row][col]
|
208
|
-
# @param table_data [Array<Array>] of the form Array[row][
|
207
|
+
# creates a html table from two dimensional array of the form Array [row] [col]
|
208
|
+
# @param table_data [Array<Array>] of the form Array [row] [col] containing all data, the '.to_s' method will be called on each element,
|
209
209
|
# @param headers [Number] either of 0, 1, 2, 3. Where 0 is no headers (<th>) at all, 1 is only the first row,
|
210
210
|
# 2 is only the first column and 3 is both, first row and first column as <th> elements. Every other number
|
211
211
|
# is equivalent to the bitwise AND of the two least significant bits with 1, 2 or 3
|
@@ -1 +1 @@
|
|
1
|
-
$(document).ready(function(){$("td").each(function(b){b=$(this);null!==b.html().match(
|
1
|
+
$(document).ready(function(){$("td").each(function(b){b=$(this);null!==b.html().match(/^passed$/)?b.attr("style","background-color:#19D119;"):null!==b.html().match(/^failed$/)?b.attr("style","background-color:#FF4719;"):null!==b.html().match(/^check$/)&&b.attr("style","background-color:#FFFF00;")});$("[class=rtoconly],[class=bothtoc]").each(function(b){var a=$(this);type=a.attr("class");a.attr("id",type+b);$("#rtoc").append("<a href='#"+type+b+"'>"+a.html()+"</a> <br />\n")});h3index=h2index=h1index=0;$("h1, h2, h3, a.h2, a.h1").each(function(b){var a=$(this);void 0==a.attr("id")&&a.attr("id","title"+b);if("h1"==a.prop("tagName"))h1index+=1,h3index=h2index=0,a.prepend(h1index+" "),$("#ltoc").append("<br />\n"),lasth1="#"+a.attr("id"),lasth1cont=a.html();else if("h2"==a.prop("tagName"))h2index+=1,h3index=0,a.prepend(h1index+"."+h2index+" "),lasth2="#"+a.attr("id"),lasth2cont=a.html();else if("h3"==a.prop("tagName"))h3index+=1,a.prepend(h1index+"."+h2index+"."+h3index+" ");else{if("h1"==a.attr("class"))return a.attr("href",lasth1),a.html(lasth1cont),0;if("h2"==a.attr("class"))return a.attr("href",lasth2),a.html(lasth2cont),0}if("rtoconly"==a.attr("class"))return 0;$("#ltoc").append("<a id='link"+b+"' href='#"+a.attr("id")+"' >"+a.html()+"</a> <br />\n");return 0})});
|
metadata
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: xhtml_report_generator
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 2.0.
|
4
|
+
version: 2.0.2
|
5
5
|
prerelease:
|
6
6
|
platform: ruby
|
7
7
|
authors:
|
@@ -9,7 +9,7 @@ authors:
|
|
9
9
|
autorequire:
|
10
10
|
bindir: bin
|
11
11
|
cert_chain: []
|
12
|
-
date: 2015-08-
|
12
|
+
date: 2015-08-24 00:00:00.000000000 Z
|
13
13
|
dependencies: []
|
14
14
|
description: ! "The generator can be used to create xhtml files. It comes with some
|
15
15
|
default utility functions.\n== Here is an example usage\n gen1 = XhtmlReportGenerator::Generator.new\n
|