Skip to content
This repository has been archived by the owner on Jul 25, 2021. It is now read-only.

Commit

Permalink
v3.3.7 - improve 'rowspan' logic
Browse files Browse the repository at this point in the history
  • Loading branch information
clarketm committed Dec 7, 2016
1 parent 3beefbd commit 87824df
Show file tree
Hide file tree
Showing 10 changed files with 50 additions and 34 deletions.
2 changes: 1 addition & 1 deletion bower.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "tableexport.js",
"version": "3.3.6",
"version": "3.3.7",
"authors": [
"clarketm <[email protected]>"
],
Expand Down
2 changes: 1 addition & 1 deletion dist/css/tableexport.css
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
/*!
* TableExport.js v3.3.6 (https://www.travismclarke.com)
* TableExport.js v3.3.7 (https://www.travismclarke.com)
* Copyright 2016 Travis Clarke
* Licensed under the MIT license
*/
Expand Down
2 changes: 1 addition & 1 deletion dist/css/tableexport.min.css

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

32 changes: 20 additions & 12 deletions dist/js/tableexport.js
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
/*!
* TableExport.js v3.3.6 (https://www.travismclarke.com)
* TableExport.js v3.3.7 (https://www.travismclarke.com)
* Copyright 2016 Travis Clarke
* Licensed under the MIT license
*/
Expand Down Expand Up @@ -88,11 +88,15 @@
}
}
if (rcMap[ir]) {
var total = 0,
min = Math.min.apply(Math, Object.keys(rcMap[ir])),
max = Math.max.apply(Math, Object.keys(rcMap[ir]));
while (min < max && rcMap[ir][min]) {
total += rcMap[ir][min] && delete rcMap[ir][min++];
var threshold = ic + 1,
total = 0,
count = 0;

for (var i = 0; i <= Math.max.apply(Math, Object.keys(rcMap[ir])); i++) {
(!rcMap[ir][i]) ? count++ : total = count >= ic ? total + rcMap[ir][i] : total;
if (count === threshold) {
break;
}
}
return new Array(total).concat($(val).text());
}
Expand Down Expand Up @@ -135,11 +139,15 @@
}
}
if (rcMap[ir]) {
var total = 0,
min = Math.min.apply(Math, Object.keys(rcMap[ir])),
max = Math.max.apply(Math, Object.keys(rcMap[ir]));
while (min < max && rcMap[ir][min]) {
total += rcMap[ir][min] && delete rcMap[ir][min++];
var threshold = ic + 1,
total = 0,
count = 0;

for (var i = 0; i <= Math.max.apply(Math, Object.keys(rcMap[ir])); i++) {
(!rcMap[ir][i]) ? count++ : total = count >= ic ? total + rcMap[ir][i] : total;
if (count === threshold) {
break;
}
}
return new Array(total).concat($(val).text());
}
Expand Down Expand Up @@ -282,7 +290,7 @@
* Version.
* @memberof TableExport.prototype
*/
version: "3.3.6",
version: "3.3.7",
/**
* Default plugin options.
* @memberof TableExport.prototype
Expand Down
4 changes: 2 additions & 2 deletions dist/js/tableexport.min.js

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "tableexport",
"version": "3.3.6",
"version": "3.3.7",
"authors": [
"clarketm <[email protected]>"
],
Expand Down
2 changes: 1 addition & 1 deletion src/stable/css/tableexport.css
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
/*!
* TableExport.js v3.3.6 (https://www.travismclarke.com)
* TableExport.js v3.3.7 (https://www.travismclarke.com)
* Copyright 2016 Travis Clarke
* Licensed under the MIT license
*/
Expand Down
Loading

0 comments on commit 87824df

Please sign in to comment.