diff --git a/README.md b/README.md
index 85c0800f..b7142f44 100644
--- a/README.md
+++ b/README.md
@@ -44,6 +44,16 @@ tablesorter can successfully parse and sort many types of data including linked
View the [complete listing here](https://github.com/Mottie/tablesorter/wiki/Change).
+#### Version 2.13.2 (11/2/2013)
+
+* Updated pager & filter widget to work when the pager `countChildRows` option is `true`:
+ * Filter widget now properly added a "filtered" class to child rows
+ * Pager plugin & widget now properly calculate a correct total number of rows
+ * See [issue #396](https://github.com/Mottie/tablesorter/issues/396).
+* Updated editable widget to target table cell children if they exist
+ * This fixes the issue in IE where making a table element contenteditable is not allowed.
+ * See [issue #404](https://github.com/Mottie/tablesorter/issues/404) for further details.
+
#### Version 2.13.1 (10/31/2013)
* Fixed filter widget issues
diff --git a/component.json b/component.json
index 6eeab257..b4a4805e 100644
--- a/component.json
+++ b/component.json
@@ -1,6 +1,6 @@
{
"name": "tablesorter",
- "version": "2.13.1",
+ "version": "2.13.2",
"dependencies": {
"jquery": ">=1.2.6"
}
diff --git a/docs/index.html b/docs/index.html
index 15115c8b..b2fd92a8 100644
--- a/docs/index.html
+++ b/docs/index.html
@@ -292,7 +292,7 @@
- Pager plugin
+ Pager plugin (v2.13.2 ).
Columns widget (v2.0.17)
diff --git a/js/jquery.tablesorter.js b/js/jquery.tablesorter.js
index f9288383..fd8b734d 100644
--- a/js/jquery.tablesorter.js
+++ b/js/jquery.tablesorter.js
@@ -1,5 +1,5 @@
/**!
-* TableSorter 2.13.1 - Client-side table sorting with ease!
+* TableSorter 2.13.2 - Client-side table sorting with ease!
* @requires jQuery v1.2.6+
*
* Copyright (c) 2007 Christian Bach
@@ -24,7 +24,7 @@
var ts = this;
- ts.version = "2.13.1";
+ ts.version = "2.13.2";
ts.parsers = [];
ts.widgets = [];
diff --git a/js/jquery.tablesorter.min.js b/js/jquery.tablesorter.min.js
index 1d927b43..0cb1da56 100644
--- a/js/jquery.tablesorter.min.js
+++ b/js/jquery.tablesorter.min.js
@@ -1,5 +1,5 @@
/*!
-* TableSorter 2.13.1 min - Client-side table sorting with ease!
+* TableSorter 2.13.2 min - Client-side table sorting with ease!
* Copyright (c) 2007 Christian Bach
*/
-!(function(g){g.extend({tablesorter:new function(){function c(a){"undefined"!==typeof console&&"undefined"!==typeof console.log?console.log(a):alert(a)}function k(a,b){c(a+" ("+((new Date).getTime()-b.getTime())+"ms)")}function m(a){for(var b in a)return!1;return!0}function p(a,b,d){if(!b)return"";var h=a.config,c=h.textExtraction,f="",f="simple"===c?h.supportsTextContent?b.textContent:g(b).text():"function"===typeof c?c(b,a,d):"object"===typeof c&&c.hasOwnProperty(d)?c[d](b,a,d):h.supportsTextContent? b.textContent:g(b).text();return g.trim(f)}function x(a){var b=a.config,d=b.$tbodies=b.$table.children("tbody:not(."+b.cssInfoBlock+")"),h,y,f,l,r,g,n="";if(0===d.length)return b.debug?c("*Empty table!* Not building a parser cache"):"";d=d[0].rows;if(d[0])for(h=[],y=d[0].cells.length,f=0;f':"";n.$headers=g(a).find(n.selectorHeaders).each(function(a){h=g(this);d=n.headers[a];n.headerContent[a]=g(this).html();l=n.headerTemplate.replace(/\{content\}/g,g(this).html()).replace(/\{icon\}/g,f);n.onRenderTemplate&&(y=n.onRenderTemplate.apply(h,[a,l]))&&"string"===typeof y&&(l=y);g(this).html('");n.onRenderHeader&&n.onRenderHeader.apply(h,[a]); this.column=b[this.parentNode.rowIndex+"-"+this.cellIndex];var c=e.getData(h,d,"sortInitialOrder")||n.sortInitialOrder;this.order=/^d/i.test(c)||1===c?[1,0,2]:[0,1,2];this.count=-1;this.lockedOrder=!1;r=e.getData(h,d,"lockedOrder")||!1;"undefined"!==typeof r&&!1!==r&&(this.order=this.lockedOrder=/^d/i.test(r)||1===r?[1,1,1]:[0,0,0]);h.addClass(e.css.header+" "+n.cssHeader);n.headerList[a]=this;h.parent().addClass(e.css.headerRow+" "+n.cssHeaderRow);h.attr("tabindex",0)});D(a);n.debug&&(k("Built headers:", q),c(n.$headers))}function F(a,b,d){var h=a.config;h.$table.find(h.selectorRemove).remove();x(a);z(a);G(h.$table,b,d)}function D(a){var b,d=a.config;d.$headers.each(function(a,c){b="false"===e.getData(c,d.headers[a],"sorter");c.sortDisabled=b;g(c)[b?"addClass":"removeClass"]("sorter-false")})}function H(a){var b,d,h,c=a.config,f=c.sortList,l=[e.css.sortAsc+" "+c.cssAsc,e.css.sortDesc+" "+c.cssDesc],r=g(a).find("tfoot tr").children().removeClass(l.join(" "));c.$headers.removeClass(l.join(" "));h=f.length; for(b=0;b"),d=g(a).width();g(a.tBodies[0]).find("tr:first").children("td:visible").each(function(){b.append(g(" ").css("width",parseInt(g(this).width()/ d*1E3,10)/10+"%"))});g(a).prepend(b)}}function M(a,b){var d,h,c,f=a.config,e=b||f.sortList;f.sortList=[];g.each(e,function(a,b){d=[parseInt(b[0],10),parseInt(b[1],10)];if(c=f.headerList[d[0]])f.sortList.push(d),h=g.inArray(d[1],c.order),c.count=0<=h?h:d[1]%(f.sortReset?3:2)})}function N(a,b,d){var h,c,f=a.config,l=!d[f.sortMultiSortKey],r=g(a);r.trigger("sortStart",a);b.count=d[f.sortResetKey]?2:(b.count+1)%(f.sortReset?3:2);f.sortRestart&&(c=b,f.$headers.each(function(){this===c||!l&&g(this).is("."+ e.css.sortDesc+",."+e.css.sortAsc)||(this.count=-1)}));c=b.column;if(l){f.sortList=[];if(null!==f.sortForce)for(h=f.sortForce,d=0;dh&&(f.sortList.push([c,h]),1h&&(f.sortList.push([c,h]),1 thead th, > thead td",selectorSort:"th, td",selectorRemove:".remove-me",debug:!1,headerList:[],empties:{},strings:{},parsers:[]};e.css={table:"tablesorter",childRow:"tablesorter-childRow",header:"tablesorter-header",headerRow:"tablesorter-headerRow",icon:"tablesorter-icon",info:"tablesorter-infoOnly",processing:"tablesorter-processing",sortAsc:"tablesorter-headerAsc",sortDesc:"tablesorter-headerDesc"}; e.log=c;e.benchmark=k;e.construct=function(a){return this.each(function(){var b=g.extend(!0,{},e.defaults,a);!this.hasInitialized&&e.buildTable&&"TABLE"!==this.tagName&&e.buildTable(this,b);e.setup(this,b)})};e.setup=function(a,b){if(!a||!a.tHead||0===a.tBodies.length||!0===a.hasInitialized)return b.debug?c("stopping initialization! No table, thead, tbody or tablesorter has already been initialized"):"";var d="",h=g(a),k=g.metadata;a.hasInitialized=!1;a.isProcessing=!0;a.config=b;g.data(a,"tablesorter", b);b.debug&&g.data(a,"startoveralltimer",new Date);b.supportsTextContent="x"===g("x ")[0].textContent;b.supportsDataObject=function(a){a[0]=parseInt(a[0],10);return 1 '),d=g.fn.detach?b.detach():b.remove();d=g(a).find("span.tablesorter-savemyplace");b.insertAfter(d);d.remove();a.isProcessing=!1};e.clearTableBody=function(a){g(a)[0].config.$tbodies.empty()};e.restoreHeaders=function(a){var b=a.config;b.$table.find(b.selectorHeaders).each(function(a){g(this).find(".tablesorter-header-inner").length&&g(this).html(b.headerContent[a])})}; e.destroy=function(a,b,d){a=g(a)[0];if(a.hasInitialized){e.refreshWidgets(a,!0,!0);var c=g(a),k=a.config,f=c.find("thead:first"),l=f.find("tr."+e.css.headerRow).removeClass(e.css.headerRow+" "+k.cssHeaderRow),m=c.find("tfoot:first > tr").children("th, td");f.find("tr").not(l).remove();c.removeData("tablesorter").unbind("sortReset update updateAll updateRows updateCell addRows sorton appendCache applyWidgetId applyWidgets refreshWidgets destroy mouseup mouseleave keypress sortBegin sortEnd ".split(" ").join(".tablesorter ")); k.$headers.add(m).removeClass([e.css.header,k.cssHeader,k.cssAsc,k.cssDesc,e.css.sortAsc,e.css.sortDesc].join(" ")).removeAttr("data-column");l.find(k.selectorSort).unbind("mousedown.tablesorter mouseup.tablesorter keypress.tablesorter");e.restoreHeaders(a);!1!==b&&c.removeClass(e.css.table+" "+k.tableClass+" tablesorter-"+k.theme);a.hasInitialized=!1;"function"===typeof d&&d(a)}};e.regex={chunk:/(^([+\-]?(?:0|[1-9]\d*)(?:\.\d*)?(?:[eE][+\-]?\d+)?)?$|^0x[0-9a-f]+$|\d+)/gi,hex:/^0x[0-9a-f]+$/i};e.sortNatural= function(a,b){if(a===b)return 0;var d,c,g,f,l,k;c=e.regex;if(c.hex.test(b)){d=parseInt(a.match(c.hex),16);g=parseInt(b.match(c.hex),16);if(dg)return 1}d=a.replace(c.chunk,"\\0$1\\0").replace(/\\0$/,"").replace(/^\\0/,"").split("\\0");c=b.replace(c.chunk,"\\0$1\\0").replace(/\\0$/,"").replace(/^\\0/,"").split("\\0");k=Math.max(d.length,c.length);for(l=0;lf)return 1}return 0};e.sortText=function(a,b){return a>b?1:ag.inArray(l[h].id,f))&&(k.debug&&c("Refeshing widgets: Removing "+l[h].id),l[h].hasOwnProperty("remove")&&(l[h].remove(a,k,k.widgetOptions),k.widgetInit[l[h].id]=!1));!0!==d&&e.applyWidget(a,b)};e.getData=function(a,b,c){var e="";a=g(a);var k,f;if(!a.length)return"";k=g.metadata?a.metadata():!1;f=" "+(a.attr("class")||"");"undefined"!==typeof a.data(c)|| "undefined"!==typeof a.data(c.toLowerCase())?e+=a.data(c)||a.data(c.toLowerCase()):k&&"undefined"!==typeof k[c]?e+=k[c]:b&&"undefined"!==typeof b[c]?e+=b[c]:" "!==f&&f.match(" "+c+"-")&&(e=f.match(RegExp("\\s"+c+"-([\\w-]+)"))[1]||"");return g.trim(e)};e.formatFloat=function(a,b){if("string"!==typeof a||""===a)return a;var c;a=(b&&b.config?!1!==b.config.usNumberFormat:"undefined"!==typeof b?b:1)?a.replace(/,/g,""):a.replace(/[\s|\.]/g,"").replace(/,/g,".");/^\s*\([.\d]+\)/.test(a)&&(a=a.replace(/^\s*\(([.\d]+)\)/, "-$1"));c=parseFloat(a);return isNaN(c)?g.trim(a):c};e.isDigit=function(a){return isNaN(a)?/^[\-+(]?\d+[)]?$/.test(a.toString().replace(/[,.'"\s]/g,"")):!0}}});var p=g.tablesorter;g.fn.extend({tablesorter:p.construct});p.addParser({id:"text",is:function(){return!0},format:function(c,k){var m=k.config;c&&(c=g.trim(m.ignoreCase?c.toLocaleLowerCase():c),c=m.sortLocaleCompare?p.replaceAccents(c):c);return c},type:"text"});p.addParser({id:"digit",is:function(c){return p.isDigit(c)},format:function(c,k){var m= p.formatFloat((c||"").replace(/[^\w,. \-()]/g,""),k);return c&&"number"===typeof m?m:c?g.trim(c&&k.config.ignoreCase?c.toLocaleLowerCase():c):c},type:"numeric"});p.addParser({id:"currency",is:function(c){return/^\(?\d+[\u00a3$\u20ac\u00a4\u00a5\u00a2?.]|[\u00a3$\u20ac\u00a4\u00a5\u00a2?.]\d+\)?$/.test((c||"").replace(/[,. ]/g,""))},format:function(c,k){var m=p.formatFloat((c||"").replace(/[^\w,. \-()]/g,""),k);return c&&"number"===typeof m?m:c?g.trim(c&&k.config.ignoreCase?c.toLocaleLowerCase():c): c},type:"numeric"});p.addParser({id:"ipAddress",is:function(c){return/^\d{1,3}[\.]\d{1,3}[\.]\d{1,3}[\.]\d{1,3}$/.test(c)},format:function(c,g){var m,u=c?c.split("."):"",x="",z=u.length;for(m=0;mc.length},format:function(c,g){return c?p.formatFloat(c.replace(/%/g,""),g):c},type:"numeric"});p.addParser({id:"usLongDate",is:function(c){return/^[A-Z]{3,10}\.?\s+\d{1,2},?\s+(\d{4})(\s+\d{1,2}:\d{2}(:\d{2})?(\s+[AP]M)?)?$/i.test(c)||/^\d{1,2}\s+[A-Z]{3,10}\s+\d{4}/i.test(c)},format:function(c,g){return c? p.formatFloat((new Date(c.replace(/(\S)([AP]M)$/i,"$1 $2"))).getTime()||"",g):c},type:"numeric"});p.addParser({id:"shortDate",is:function(c){return/(^\d{1,2}[\/\s]\d{1,2}[\/\s]\d{4})|(^\d{4}[\/\s]\d{1,2}[\/\s]\d{1,2})/.test((c||"").replace(/\s+/g," ").replace(/[\-.,]/g,"/"))},format:function(c,g,m,u){if(c){m=g.config;var x=m.headerList[u];u=x.dateFormat||p.getData(x,m.headers[u],"dateFormat")||m.dateFormat;c=c.replace(/\s+/g," ").replace(/[\-.,]/g,"/");"mmddyyyy"===u?c=c.replace(/(\d{1,2})[\/\s](\d{1,2})[\/\s](\d{4})/, "$3/$1/$2"):"ddmmyyyy"===u?c=c.replace(/(\d{1,2})[\/\s](\d{1,2})[\/\s](\d{4})/,"$3/$2/$1"):"yyyymmdd"===u&&(c=c.replace(/(\d{4})[\/\s](\d{1,2})[\/\s](\d{1,2})/,"$1/$2/$3"))}return c?p.formatFloat((new Date(c)).getTime()||"",g):c},type:"numeric"});p.addParser({id:"time",is:function(c){return/^(([0-2]?\d:[0-5]\d)|([0-1]?\d:[0-5]\d\s?([AP]M)))$/i.test(c)},format:function(c,g){return c?p.formatFloat((new Date("2000/01/01 "+c.replace(/(\S)([AP]M)$/i,"$1 $2"))).getTime()||"",g):c},type:"numeric"});p.addParser({id:"metadata", is:function(){return!1},format:function(c,k,m){c=k.config;c=c.parserMetadataName?c.parserMetadataName:"sortValue";return g(m).metadata()[c]},type:"numeric"});p.addWidget({id:"zebra",priority:90,format:function(c,k,m){var u,x,z,B,E,C,F=RegExp(k.cssChildRow,"i"),D=k.$tbodies;k.debug&&(E=new Date);for(c=0;c':"";n.$headers=g(a).find(n.selectorHeaders).each(function(a){h=g(this);d=n.headers[a];n.headerContent[a]=g(this).html();l=n.headerTemplate.replace(/\{content\}/g,g(this).html()).replace(/\{icon\}/g,f);n.onRenderTemplate&&(y=n.onRenderTemplate.apply(h,[a,l]))&&"string"===typeof y&&(l=y);g(this).html('");n.onRenderHeader&&n.onRenderHeader.apply(h,[a]); this.column=b[this.parentNode.rowIndex+"-"+this.cellIndex];var c=e.getData(h,d,"sortInitialOrder")||n.sortInitialOrder;this.order=/^d/i.test(c)||1===c?[1,0,2]:[0,1,2];this.count=-1;this.lockedOrder=!1;r=e.getData(h,d,"lockedOrder")||!1;"undefined"!==typeof r&&!1!==r&&(this.order=this.lockedOrder=/^d/i.test(r)||1===r?[1,1,1]:[0,0,0]);h.addClass(e.css.header+" "+n.cssHeader);n.headerList[a]=this;h.parent().addClass(e.css.headerRow+" "+n.cssHeaderRow);h.attr("tabindex",0)});D(a);n.debug&&(k("Built headers:", q),c(n.$headers))}function F(a,b,d){var h=a.config;h.$table.find(h.selectorRemove).remove();x(a);z(a);G(h.$table,b,d)}function D(a){var b,d=a.config;d.$headers.each(function(a,c){b="false"===e.getData(c,d.headers[a],"sorter");c.sortDisabled=b;g(c)[b?"addClass":"removeClass"]("sorter-false")})}function H(a){var b,d,h,c=a.config,f=c.sortList,l=[e.css.sortAsc+" "+c.cssAsc,e.css.sortDesc+" "+c.cssDesc],r=g(a).find("tfoot tr").children().removeClass(l.join(" "));c.$headers.removeClass(l.join(" "));h=f.length; for(b=0;b"),d=g(a).width();g(a.tBodies[0]).find("tr:first").children("td:visible").each(function(){b.append(g(" ").css("width",parseInt(g(this).width()/ d*1E3,10)/10+"%"))});g(a).prepend(b)}}function M(a,b){var d,h,c,f=a.config,e=b||f.sortList;f.sortList=[];g.each(e,function(a,b){d=[parseInt(b[0],10),parseInt(b[1],10)];if(c=f.headerList[d[0]])f.sortList.push(d),h=g.inArray(d[1],c.order),c.count=0<=h?h:d[1]%(f.sortReset?3:2)})}function N(a,b,d){var h,c,f=a.config,l=!d[f.sortMultiSortKey],r=g(a);r.trigger("sortStart",a);b.count=d[f.sortResetKey]?2:(b.count+1)%(f.sortReset?3:2);f.sortRestart&&(c=b,f.$headers.each(function(){this===c||!l&&g(this).is("."+ e.css.sortDesc+",."+e.css.sortAsc)||(this.count=-1)}));c=b.column;if(l){f.sortList=[];if(null!==f.sortForce)for(h=f.sortForce,d=0;dh&&(f.sortList.push([c,h]),1h&&(f.sortList.push([c,h]),1 thead th, > thead td",selectorSort:"th, td",selectorRemove:".remove-me",debug:!1,headerList:[],empties:{},strings:{},parsers:[]};e.css={table:"tablesorter",childRow:"tablesorter-childRow",header:"tablesorter-header",headerRow:"tablesorter-headerRow",icon:"tablesorter-icon",info:"tablesorter-infoOnly",processing:"tablesorter-processing",sortAsc:"tablesorter-headerAsc",sortDesc:"tablesorter-headerDesc"}; e.log=c;e.benchmark=k;e.construct=function(a){return this.each(function(){var b=g.extend(!0,{},e.defaults,a);!this.hasInitialized&&e.buildTable&&"TABLE"!==this.tagName&&e.buildTable(this,b);e.setup(this,b)})};e.setup=function(a,b){if(!a||!a.tHead||0===a.tBodies.length||!0===a.hasInitialized)return b.debug?c("stopping initialization! No table, thead, tbody or tablesorter has already been initialized"):"";var d="",h=g(a),k=g.metadata;a.hasInitialized=!1;a.isProcessing=!0;a.config=b;g.data(a,"tablesorter", b);b.debug&&g.data(a,"startoveralltimer",new Date);b.supportsTextContent="x"===g("x ")[0].textContent;b.supportsDataObject=function(a){a[0]=parseInt(a[0],10);return 1 '),d=g.fn.detach?b.detach():b.remove();d=g(a).find("span.tablesorter-savemyplace");b.insertAfter(d);d.remove();a.isProcessing=!1};e.clearTableBody=function(a){g(a)[0].config.$tbodies.empty()};e.restoreHeaders=function(a){var b=a.config;b.$table.find(b.selectorHeaders).each(function(a){g(this).find(".tablesorter-header-inner").length&&g(this).html(b.headerContent[a])})}; e.destroy=function(a,b,d){a=g(a)[0];if(a.hasInitialized){e.refreshWidgets(a,!0,!0);var c=g(a),k=a.config,f=c.find("thead:first"),l=f.find("tr."+e.css.headerRow).removeClass(e.css.headerRow+" "+k.cssHeaderRow),m=c.find("tfoot:first > tr").children("th, td");f.find("tr").not(l).remove();c.removeData("tablesorter").unbind("sortReset update updateAll updateRows updateCell addRows sorton appendCache applyWidgetId applyWidgets refreshWidgets destroy mouseup mouseleave keypress sortBegin sortEnd ".split(" ").join(".tablesorter ")); k.$headers.add(m).removeClass([e.css.header,k.cssHeader,k.cssAsc,k.cssDesc,e.css.sortAsc,e.css.sortDesc].join(" ")).removeAttr("data-column");l.find(k.selectorSort).unbind("mousedown.tablesorter mouseup.tablesorter keypress.tablesorter");e.restoreHeaders(a);!1!==b&&c.removeClass(e.css.table+" "+k.tableClass+" tablesorter-"+k.theme);a.hasInitialized=!1;"function"===typeof d&&d(a)}};e.regex={chunk:/(^([+\-]?(?:0|[1-9]\d*)(?:\.\d*)?(?:[eE][+\-]?\d+)?)?$|^0x[0-9a-f]+$|\d+)/gi,hex:/^0x[0-9a-f]+$/i};e.sortNatural= function(a,b){if(a===b)return 0;var d,c,g,f,l,k;c=e.regex;if(c.hex.test(b)){d=parseInt(a.match(c.hex),16);g=parseInt(b.match(c.hex),16);if(dg)return 1}d=a.replace(c.chunk,"\\0$1\\0").replace(/\\0$/,"").replace(/^\\0/,"").split("\\0");c=b.replace(c.chunk,"\\0$1\\0").replace(/\\0$/,"").replace(/^\\0/,"").split("\\0");k=Math.max(d.length,c.length);for(l=0;lf)return 1}return 0};e.sortText=function(a,b){return a>b?1:ag.inArray(l[h].id,f))&&(k.debug&&c("Refeshing widgets: Removing "+l[h].id),l[h].hasOwnProperty("remove")&&(l[h].remove(a,k,k.widgetOptions),k.widgetInit[l[h].id]=!1));!0!==d&&e.applyWidget(a,b)};e.getData=function(a,b,c){var e="";a=g(a);var k,f;if(!a.length)return"";k=g.metadata?a.metadata():!1;f=" "+(a.attr("class")||"");"undefined"!==typeof a.data(c)|| "undefined"!==typeof a.data(c.toLowerCase())?e+=a.data(c)||a.data(c.toLowerCase()):k&&"undefined"!==typeof k[c]?e+=k[c]:b&&"undefined"!==typeof b[c]?e+=b[c]:" "!==f&&f.match(" "+c+"-")&&(e=f.match(RegExp("\\s"+c+"-([\\w-]+)"))[1]||"");return g.trim(e)};e.formatFloat=function(a,b){if("string"!==typeof a||""===a)return a;var c;a=(b&&b.config?!1!==b.config.usNumberFormat:"undefined"!==typeof b?b:1)?a.replace(/,/g,""):a.replace(/[\s|\.]/g,"").replace(/,/g,".");/^\s*\([.\d]+\)/.test(a)&&(a=a.replace(/^\s*\(([.\d]+)\)/, "-$1"));c=parseFloat(a);return isNaN(c)?g.trim(a):c};e.isDigit=function(a){return isNaN(a)?/^[\-+(]?\d+[)]?$/.test(a.toString().replace(/[,.'"\s]/g,"")):!0}}});var p=g.tablesorter;g.fn.extend({tablesorter:p.construct});p.addParser({id:"text",is:function(){return!0},format:function(c,k){var m=k.config;c&&(c=g.trim(m.ignoreCase?c.toLocaleLowerCase():c),c=m.sortLocaleCompare?p.replaceAccents(c):c);return c},type:"text"});p.addParser({id:"digit",is:function(c){return p.isDigit(c)},format:function(c,k){var m= p.formatFloat((c||"").replace(/[^\w,. \-()]/g,""),k);return c&&"number"===typeof m?m:c?g.trim(c&&k.config.ignoreCase?c.toLocaleLowerCase():c):c},type:"numeric"});p.addParser({id:"currency",is:function(c){return/^\(?\d+[\u00a3$\u20ac\u00a4\u00a5\u00a2?.]|[\u00a3$\u20ac\u00a4\u00a5\u00a2?.]\d+\)?$/.test((c||"").replace(/[,. ]/g,""))},format:function(c,k){var m=p.formatFloat((c||"").replace(/[^\w,. \-()]/g,""),k);return c&&"number"===typeof m?m:c?g.trim(c&&k.config.ignoreCase?c.toLocaleLowerCase():c): c},type:"numeric"});p.addParser({id:"ipAddress",is:function(c){return/^\d{1,3}[\.]\d{1,3}[\.]\d{1,3}[\.]\d{1,3}$/.test(c)},format:function(c,g){var m,u=c?c.split("."):"",x="",z=u.length;for(m=0;mc.length},format:function(c,g){return c?p.formatFloat(c.replace(/%/g,""),g):c},type:"numeric"});p.addParser({id:"usLongDate",is:function(c){return/^[A-Z]{3,10}\.?\s+\d{1,2},?\s+(\d{4})(\s+\d{1,2}:\d{2}(:\d{2})?(\s+[AP]M)?)?$/i.test(c)||/^\d{1,2}\s+[A-Z]{3,10}\s+\d{4}/i.test(c)},format:function(c,g){return c? p.formatFloat((new Date(c.replace(/(\S)([AP]M)$/i,"$1 $2"))).getTime()||"",g):c},type:"numeric"});p.addParser({id:"shortDate",is:function(c){return/(^\d{1,2}[\/\s]\d{1,2}[\/\s]\d{4})|(^\d{4}[\/\s]\d{1,2}[\/\s]\d{1,2})/.test((c||"").replace(/\s+/g," ").replace(/[\-.,]/g,"/"))},format:function(c,g,m,u){if(c){m=g.config;var x=m.headerList[u];u=x.dateFormat||p.getData(x,m.headers[u],"dateFormat")||m.dateFormat;c=c.replace(/\s+/g," ").replace(/[\-.,]/g,"/");"mmddyyyy"===u?c=c.replace(/(\d{1,2})[\/\s](\d{1,2})[\/\s](\d{4})/, "$3/$1/$2"):"ddmmyyyy"===u?c=c.replace(/(\d{1,2})[\/\s](\d{1,2})[\/\s](\d{4})/,"$3/$2/$1"):"yyyymmdd"===u&&(c=c.replace(/(\d{4})[\/\s](\d{1,2})[\/\s](\d{1,2})/,"$1/$2/$3"))}return c?p.formatFloat((new Date(c)).getTime()||"",g):c},type:"numeric"});p.addParser({id:"time",is:function(c){return/^(([0-2]?\d:[0-5]\d)|([0-1]?\d:[0-5]\d\s?([AP]M)))$/i.test(c)},format:function(c,g){return c?p.formatFloat((new Date("2000/01/01 "+c.replace(/(\S)([AP]M)$/i,"$1 $2"))).getTime()||"",g):c},type:"numeric"});p.addParser({id:"metadata", is:function(){return!1},format:function(c,k,m){c=k.config;c=c.parserMetadataName?c.parserMetadataName:"sortValue";return g(m).metadata()[c]},type:"numeric"});p.addWidget({id:"zebra",priority:90,format:function(c,k,m){var u,x,z,B,E,C,F=RegExp(k.cssChildRow,"i"),D=k.$tbodies;k.debug&&(E=new Date);for(c=0;c'), c.cssIcon&&p.find("."+d.css.icon).addClass(h.icons),q.hasClass("hasFilters")&&p.find(".tablesorter-filter-row").addClass(h.filterRow));g.each(p,function(a){l=g(this);k=d.css.icon?l.find("."+d.css.icon):l;this.sortDisabled?(l.removeClass(w),k.removeClass(w+" tablesorter-icon "+h.icons)):(m=q.hasClass("hasStickyHeaders")?q.find(u).find("th").eq(a).add(l):l,e=l.hasClass(d.css.sortAsc)?h.sortAsc:l.hasClass(d.css.sortDesc)?h.sortDesc:l.hasClass(d.css.header)?h.sortNone:"",l[e===h.sortNone?"removeClass": "addClass"](h.active),k.removeClass(w).addClass(e))});c.debug&&d.benchmark("Applying "+v+" theme",a)},remove:function(f,c,b){f=c.$table;c="object"===typeof b.uitheme?"jui":b.uitheme||"jui";b="object"===typeof b.uitheme?b.uitheme:d.themes[d.themes.hasOwnProperty(c)?c:"jui"];var a=f.children("thead").children(),e=b.sortNone+" "+b.sortDesc+" "+b.sortAsc;f.removeClass("tablesorter-"+c+" "+b.table).find(d.css.header).removeClass(b.header);a.unbind("mouseenter.tsuitheme mouseleave.tsuitheme").removeClass(b.hover+ " "+e+" "+b.active).find(".tablesorter-filter-row").removeClass(b.filterRow);a.find(".tablesorter-icon").removeClass(b.icons)}});
d.addWidget({id:"columns",priority:30,options:{columns:["primary","secondary","tertiary"]},format:function(f,c,b){var a,e,l,k,m,q,v,h,p,u=c.$table,w=c.$tbodies,t=c.sortList,y=t.length,r=c.widgetColumns&&c.widgetColumns.hasOwnProperty("css")?c.widgetColumns.css||r:b&&b.hasOwnProperty("columns")?b.columns||r:r;q=r.length-1;v=r.join(" ");c.debug&&(m=new Date);for(p=0;p=]/g}},format:function(f, c,b){if(!c.$table.hasClass("hasFilters")&&(c.parsers||!c.parsers&&b.filter_serversideFiltering)){var a,e,l,k,m,q,v,h,p,u,w,t,y,r,x,s,n,C,D,E=d.formatFloat,N="",B=c.$headers,A=c.$table.addClass("hasFilters"),I=c.$tbodies,J=c.columns||c.$headers.filter("th").length,F,O,P,H=function(a){var e=g.isArray(a),s=e?a:d.getFilters(f),l=(s||[]).join("");e&&d.setFilters(A,s);b.filter_hideFilters&&A.find(".tablesorter-filter-row").trigger(""===l?"mouseleave":"mouseenter");if(N!==l||!1===a)if(A.trigger("filterStart", [s]),c.showProcessing)setTimeout(function(){Q(a,s,l);return!1},30);else return Q(a,s,l),!1},Q=function(K,k,q){var p,t,w,r,y,z,u,D,C,G;c.debug&&(D=new Date);for(l=0;l]=?/.test(m)){s=u=E(m.replace(b.filter_regex.nondigit,"").replace(b.filter_regex.operators,""),f);if(F[a]||"numeric"===c.parsers[a].type)x=c.parsers[a].format(""+m.replace(b.filter_regex.operators,""), f,B.eq(a),a),s=isNaN(s)&&""!==x&&!isNaN(x)?x:s;x=!F[a]&&"numeric"!==c.parsers[a].type||isNaN(s)||!c.cache[l].normalized[e]?isNaN(h)?E(h.replace(b.filter_regex.nondigit,""),f):E(h,f):c.cache[l].normalized[e][a];/>/.test(m)&&(z=/>=/.test(m)?x>=s:x>s);/C&&(z=u,u=C,C=z);z=x>=u&&x<=C||""===u||""===C?!0:!1}else/[\?|\*]/.test(m)||/\s+OR\s+/.test(k[a])? (s=m.replace(/\s+OR\s+/gi,"|"),!B.filter('[data-column="'+a+'"]:last').hasClass("filter-match")&&/\|/.test(s)&&(s="^("+s+")$"),z=RegExp(s.replace(/\?/g,"\\S{1}").replace(/\*/g,"\\S*")).test(h)):(v=(h+n).indexOf(m),z=!b.filter_startsWith&&0<=v||b.filter_startsWith&&0===v);r=z?r?!0:!1:!1}p[e].style.display=r?"":"none";p.eq(e)[r?"removeClass":"addClass"](b.filter_filteredRow);if(w.length)w[r?"show":"hide"]()}d.processTbody(f,K,!1)}N=q;A.data("lastSearch",k);c.debug&&d.benchmark("Completed filter widget search", D);A.trigger("applyWidgets");A.trigger("filterEnd")},R=function(a,f,s){var m,h,n=[];a=parseInt(a,10);h=B.filter('[data-column="'+a+'"]:last');m=''+(h.data("placeholder")||h.attr("data-placeholder")||"")+" ";for(l=0;l"+n[l]+"":"";A.find("thead").find('select.tablesorter-filter[data-column="'+a+'"]')[f?"html":"append"](m)},L=function(c){for(a=0;a';for(a=0;a";c.$filters=g(n+="").appendTo(A.find("thead").eq(0)).find("td");for(a=0;a").appendTo(c.$filters.eq(a)):(b.filter_formatter&&g.isFunction(b.filter_formatter[a])?((n=b.filter_formatter[a](c.$filters.eq(a),a))&&0===n.length&&(n=c.$filters.eq(a).children("input")),n&&(0===n.parent().length||n.parent().length&&n.parent()[0]!==c.$filters[a])&&c.$filters.eq(a).append(n)):n=g(' ').appendTo(c.$filters.eq(a)),n&&n.attr("placeholder",r.data("placeholder")||r.attr("data-placeholder")||"")),n&&(n.addClass("tablesorter-filter "+ b.filter_cssFilter).attr("data-column",a),C&&(n.addClass("disabled")[0].disabled=!0))}A.bind("addRows updateCell update updateRows updateComplete appendCache filterReset filterEnd search ".split(" ").join(".tsfilter "),function(a,b){/(search|filterReset|filterEnd)/.test(a.type)||(a.stopPropagation(),L(!0));"filterReset"===a.type&&M([]);"filterEnd"===a.type?L(!0):(b="search"===a.type?b:"updateComplete"===a.type?A.data("lastSearch"):"",M(b));return!1}).find("input.tablesorter-filter").bind("keyup search", function(a,c){if(27===a.which)this.value="";else if("number"===typeof b.filter_liveSearch&&this.value.lengtha.which&&8!==a.which&&!0===b.filter_liveSearch&&13!==a.which||37<=a.which&&40>=a.which||13!==a.which&&!1===b.filter_liveSearch))return;M(c)});F=B.map(function(a){return d.getData?"parsed"===d.getData(B.filter('[data-column="'+a+'"]:last'),c.headers[a],"filter"):g(this).hasClass("filter-parsed")}).get();b.filter_reset&&g(document).delegate(b.filter_reset, "click.tsfilter",function(){A.trigger("filterReset")});if(b.filter_functions)for(D in b.filter_functions)if(b.filter_functions.hasOwnProperty(D)&&"string"===typeof D)if(n=B.filter('[data-column="'+D+'"]:last'),q="",!0===b.filter_functions[D]&&!n.hasClass("filter-false"))R(D);else if("string"===typeof D&&!n.hasClass("filter-false")){for(w in b.filter_functions[D])"string"===typeof w&&(q+=""===q?''+(n.data("placeholder")||n.attr("data-placeholder")||"")+" ":"",q+=''+w+" ");A.find("thead").find('select.tablesorter-filter[data-column="'+D+'"]').append(q)}L(!0);A.find("select.tablesorter-filter").bind("change search",function(a,b){H(b)});b.filter_hideFilters&&A.find(".tablesorter-filter-row").addClass("hideme").bind("mouseenter mouseleave",function(a){var b;t=g(this);clearTimeout(p);p=setTimeout(function(){/enter|over/.test(a.type)?t.removeClass("hideme"):g(document.activeElement).closest("tr")[0]!==t[0]&&(b=d.getFilters(f).join(""),""===b&&t.addClass("hideme"))}, 200)}).find("input, select").bind("focus blur",function(a){y=g(this).closest("tr");clearTimeout(p);p=setTimeout(function(){if(""===d.getFilters(f).join(""))y["focus"===a.type?"removeClass":"addClass"]("hideme")},200)});c.showProcessing&&A.bind("filterStart.tsfilter filterEnd.tsfilter",function(a,b){var c=b?A.find("."+d.css.header).filter("[data-column]").filter(function(){return""!==b[g(this).data("column")]}):"";d.isProcessing(A[0],"filterStart"===a.type,b?c:"")});c.debug&&d.benchmark("Applying Filter widget", O);A.bind("tablesorter-initialized",function(){if(q=d.getFilters(f)){for(a=0;a=]/g}},format:function(f, c,b){if(!c.$table.hasClass("hasFilters")&&(c.parsers||!c.parsers&&b.filter_serversideFiltering)){var a,e,l,k,m,q,v,h,p,u,w,t,y,r,x,s,n,C,D,E=d.formatFloat,N="",B=c.$headers,A=c.$table.addClass("hasFilters"),I=c.$tbodies,J=c.columns||c.$headers.filter("th").length,F,O,P,H=function(a){var e=g.isArray(a),s=e?a:d.getFilters(f),l=(s||[]).join("");e&&d.setFilters(A,s);b.filter_hideFilters&&A.find(".tablesorter-filter-row").trigger(""===l?"mouseleave":"mouseenter");if(N!==l||!1===a)if(A.trigger("filterStart", [s]),c.showProcessing)setTimeout(function(){Q(a,s,l);return!1},30);else return Q(a,s,l),!1},Q=function(K,k,q){var p,t,w,r,y,z,u,D,C,G;c.debug&&(D=new Date);for(l=0;l]=?/.test(m)){s=u=E(m.replace(b.filter_regex.nondigit,"").replace(b.filter_regex.operators,""),f);if(F[a]||"numeric"===c.parsers[a].type)x=c.parsers[a].format(""+m.replace(b.filter_regex.operators,""), f,B.eq(a),a),s=isNaN(s)&&""!==x&&!isNaN(x)?x:s;x=!F[a]&&"numeric"!==c.parsers[a].type||isNaN(s)||!c.cache[l].normalized[e]?isNaN(h)?E(h.replace(b.filter_regex.nondigit,""),f):E(h,f):c.cache[l].normalized[e][a];/>/.test(m)&&(z=/>=/.test(m)?x>=s:x>s);/C&&(z=u,u=C,C=z);z=x>=u&&x<=C||""===u||""===C?!0:!1}else/[\?|\*]/.test(m)||/\s+OR\s+/.test(k[a])? (s=m.replace(/\s+OR\s+/gi,"|"),!B.filter('[data-column="'+a+'"]:last').hasClass("filter-match")&&/\|/.test(s)&&(s="^("+s+")$"),z=RegExp(s.replace(/\?/g,"\\S{1}").replace(/\*/g,"\\S*")).test(h)):(v=(h+n).indexOf(m),z=!b.filter_startsWith&&0<=v||b.filter_startsWith&&0===v);r=z?r?!0:!1:!1}p[e].style.display=r?"":"none";p.eq(e)[r?"removeClass":"addClass"](b.filter_filteredRow);if(w.length){if(c.pager&&c.pager.countChildRows||b.pager_countChildRows)w[r?"removeClass":"addClass"](b.filter_filteredRow);w[r? "show":"hide"]()}}d.processTbody(f,K,!1)}N=q;A.data("lastSearch",k);c.debug&&d.benchmark("Completed filter widget search",D);A.trigger("applyWidgets");A.trigger("filterEnd")},R=function(a,f,s){var m,h,n=[];a=parseInt(a,10);h=B.filter('[data-column="'+a+'"]:last');m=''+(h.data("placeholder")||h.attr("data-placeholder")||"")+" ";for(l=0;l"+n[l]+"":"";A.find("thead").find('select.tablesorter-filter[data-column="'+ a+'"]')[f?"html":"append"](m)},L=function(c){for(a=0;a';for(a=0;a";c.$filters=g(n+="").appendTo(A.find("thead").eq(0)).find("td");for(a=0;a").appendTo(c.$filters.eq(a)):(b.filter_formatter&&g.isFunction(b.filter_formatter[a])?((n=b.filter_formatter[a](c.$filters.eq(a),a))&&0===n.length&&(n=c.$filters.eq(a).children("input")),n&&(0===n.parent().length||n.parent().length&&n.parent()[0]!==c.$filters[a])&&c.$filters.eq(a).append(n)):n=g(' ').appendTo(c.$filters.eq(a)),n&&n.attr("placeholder", r.data("placeholder")||r.attr("data-placeholder")||"")),n&&(n.addClass("tablesorter-filter "+b.filter_cssFilter).attr("data-column",a),C&&(n.addClass("disabled")[0].disabled=!0))}A.bind("addRows updateCell update updateRows updateComplete appendCache filterReset filterEnd search ".split(" ").join(".tsfilter "),function(a,b){/(search|filterReset|filterEnd)/.test(a.type)||(a.stopPropagation(),L(!0));"filterReset"===a.type&&M([]);"filterEnd"===a.type?L(!0):(b="search"===a.type?b:"updateComplete"===a.type? A.data("lastSearch"):"",M(b));return!1}).find("input.tablesorter-filter").bind("keyup search",function(a,c){if(27===a.which)this.value="";else if("number"===typeof b.filter_liveSearch&&this.value.lengtha.which&&8!==a.which&&!0===b.filter_liveSearch&&13!==a.which||37<=a.which&&40>=a.which||13!==a.which&&!1===b.filter_liveSearch))return;M(c)});F=B.map(function(a){return d.getData?"parsed"===d.getData(B.filter('[data-column="'+a+'"]:last'), c.headers[a],"filter"):g(this).hasClass("filter-parsed")}).get();b.filter_reset&&g(document).delegate(b.filter_reset,"click.tsfilter",function(){A.trigger("filterReset")});if(b.filter_functions)for(D in b.filter_functions)if(b.filter_functions.hasOwnProperty(D)&&"string"===typeof D)if(n=B.filter('[data-column="'+D+'"]:last'),q="",!0===b.filter_functions[D]&&!n.hasClass("filter-false"))R(D);else if("string"===typeof D&&!n.hasClass("filter-false")){for(w in b.filter_functions[D])"string"===typeof w&& (q+=""===q?''+(n.data("placeholder")||n.attr("data-placeholder")||"")+" ":"",q+=''+w+" ");A.find("thead").find('select.tablesorter-filter[data-column="'+D+'"]').append(q)}L(!0);A.find("select.tablesorter-filter").bind("change search",function(a,b){H(b)});b.filter_hideFilters&&A.find(".tablesorter-filter-row").addClass("hideme").bind("mouseenter mouseleave",function(a){var b;t=g(this);clearTimeout(p);p=setTimeout(function(){/enter|over/.test(a.type)? t.removeClass("hideme"):g(document.activeElement).closest("tr")[0]!==t[0]&&(b=d.getFilters(f).join(""),""===b&&t.addClass("hideme"))},200)}).find("input, select").bind("focus blur",function(a){y=g(this).closest("tr");clearTimeout(p);p=setTimeout(function(){if(""===d.getFilters(f).join(""))y["focus"===a.type?"removeClass":"addClass"]("hideme")},200)});c.showProcessing&&A.bind("filterStart.tsfilter filterEnd.tsfilter",function(a,b){var c=b?A.find("."+d.css.header).filter("[data-column]").filter(function(){return""!== b[g(this).data("column")]}):"";d.isProcessing(A[0],"filterStart"===a.type,b?c:"")});c.debug&&d.benchmark("Applying Filter widget",O);A.bind("tablesorter-initialized",function(){if(q=d.getFilters(f)){for(a=0;ad.top&&fa.which&&8!==a.which||37<=a.which&&40>=a.which)){r=!0;a=g(this);var d=a.attr("data-column");c.$filters.find(".tablesorter-filter").eq(d).val(a.val()).trigger("search");setTimeout(function(){r=!1},b.filter_searchDelay)}});a.trigger("stickyHeadersInit")}},remove:function(f,c,b){c.$table.removeClass("hasStickyHeaders").unbind("sortEnd.tsSticky pagerComplete.tsSticky").find(".tablesorter-stickyHeader").remove();b.$sticky&&b.$sticky.length&& b.$sticky.remove();g(".hasStickyHeaders").length||g(window).unbind("scroll.tsSticky resize.tsSticky");d.addHeaderResizeEvent(f,!1)}});
+d.setFilters=function(d,c,b){d=g(d);var a=d.length? d[0].config:{},a=a&&a.$filters?a.$filters.each(function(a,b){g(b).find(".tablesorter-filter").val(c[a]||"")})||!1:!1;b&&d.trigger("search",[c,!1]);return!!a};
+d.addWidget({id:"stickyHeaders",priority:60,options:{stickyHeaders:"",stickyHeaders_offset:0,stickyHeaders_cloneId:"-sticky",stickyHeaders_addResizeEvent:!0,stickyHeaders_includeCaption:!0,stickyHeaders_zIndex:2},format:function(f,c,b){if(!c.$table.hasClass("hasStickyHeaders")){var a=c.$table,e=g(window),l=a.children("thead:first"),k=l.children("tr:not(.sticky-false)").children(), m=a.find("tfoot"),q=isNaN(b.stickyHeaders_offset)?g(b.stickyHeaders_offset):"",v=q.length?q.height()||0:parseInt(b.stickyHeaders_offset,10)||0,h=b.stickyHeaders_zIndex?b.stickyHeaders_zIndex:2,p=b.$sticky=a.clone().addClass("containsStickyHeaders").css({position:"fixed",margin:0,top:v,visibility:"hidden",zIndex:h}),u=p.children("thead:first").addClass("tablesorter-stickyHeader "+b.stickyHeaders),w,t="",y=0,r=!1,x=function(){v=q.length?q.height()||0:parseInt(b.stickyHeaders_offset,10)||0;var c=navigator.userAgent; y=0;"collapse"===a.css("border-collapse")||/(webkit|msie)/i.test(c)||(y=2*parseInt(k.eq(0).css("border-left-width"),10));p.css({left:l.offset().left-e.scrollLeft()-y,width:a.width()});w.filter(":visible").each(function(a){a=k.filter(":visible").eq(a);g(this).css({width:a.width()-y,height:a.height()}).find(".tablesorter-header-inner").width(a.find(".tablesorter-header-inner").width())})};p.attr("id")&&(p[0].id+=b.stickyHeaders_cloneId);p.find("thead:gt(0), tr.sticky-false, tbody, tfoot").remove(); b.stickyHeaders_includeCaption||p.find("caption").remove();w=u.children().children();p.css({height:0,width:0,padding:0,margin:0,border:0});w.find(".tablesorter-resizer").remove();a.addClass("hasStickyHeaders").bind("sortEnd.tsSticky",function(){k.filter(":visible").each(function(a){a=w.filter(":visible").eq(a);a.attr("class",g(this).attr("class")).removeClass(d.css.processing+" "+c.cssProcessing);c.cssIcon&&a.find("."+d.css.icon).attr("class",g(this).find("."+d.css.icon).attr("class"))})}).bind("pagerComplete.tsSticky", function(){x()});k.find(c.selectorSort).add(c.$headers.filter(c.selectorSort)).each(function(a){var b=g(this);a=u.children("tr.tablesorter-headerRow").children().eq(a).bind("mouseup",function(a){b.trigger(a,!0)});c.cancelSelection&&a.attr("unselectable","on").bind("selectstart",!1).css({"user-select":"none",MozUserSelect:"none"})});a.after(p);e.bind("scroll.tsSticky resize.tsSticky",function(c){if(a.is(":visible")){var d=a.offset(),f=b.stickyHeaders_includeCaption?0:a.find("caption").outerHeight(!0), f=e.scrollTop()+v-f,g=a.height()-(p.height()+(m.height()||0)),d=f>d.top&&fa.which&&8!==a.which||37<=a.which&&40>=a.which)){r=!0;a=g(this);var d=a.attr("data-column");c.$filters.find(".tablesorter-filter").eq(d).val(a.val()).trigger("search");setTimeout(function(){r=!1},b.filter_searchDelay)}});a.trigger("stickyHeadersInit")}},remove:function(f,c,b){c.$table.removeClass("hasStickyHeaders").unbind("sortEnd.tsSticky pagerComplete.tsSticky").find(".tablesorter-stickyHeader").remove();b.$sticky&&b.$sticky.length&& b.$sticky.remove();g(".hasStickyHeaders").length||g(window).unbind("scroll.tsSticky resize.tsSticky");d.addHeaderResizeEvent(f,!1)}});
d.addWidget({id:"resizable",priority:40,options:{resizable:!0,resizable_addLastColumn:!1},format:function(f,c,b){if(!c.$table.hasClass("hasResizable")){c.$table.addClass("hasResizable");var a,e,l,k,m={},q,v,h,p,u=c.$table,w=0,t=null,y=null,r=20>Math.abs(u.parent().width()-u.width()),x=function(){d.storage&&t&&(m[t.index()]=t.width(),m[y.index()]=y.width(),t.width(m[t.index()]), y.width(m[y.index()]),!1!==b.resizable&&d.storage(f,"tablesorter-resizable",m));w=0;t=y=null;g(window).trigger("resize")};if(m=d.storage&&!1!==b.resizable?d.storage(f,"tablesorter-resizable"):{})for(k in m)!isNaN(k)&&k');b.resizable_addLastColumn||(q=q.slice(0,-1));v=v?v.add(q):q});v.each(function(){a=g(this);k=parseInt(a.css("padding-right"),10)+10;e='
';a.find(".tablesorter-wrapper").append(e)}).bind("mousemove.tsresize", function(a){0!==w&&t&&(h=a.pageX-w,p=t.width(),t.width(p+h),t.width()!==p&&r&&y.width(y.width()-h),w=a.pageX)}).bind("mouseup.tsresize",function(){x()}).find(".tablesorter-resizer,.tablesorter-resizer-grip").bind("mousedown",function(a){t=g(a.target).closest("th");e=c.$headers.filter('[data-column="'+t.attr("data-column")+'"]');1