Merge branch 'master' into gh-pages

This commit is contained in:
Rob Garrison 2016-06-28 07:10:11 -05:00
commit 2b86815fbf
31 changed files with 180 additions and 10184 deletions

View File

@ -101,6 +101,24 @@ If you would like to contribute, please...
View the [complete change log here](//github.com/Mottie/tablesorter/wiki/Changes). View the [complete change log here](//github.com/Mottie/tablesorter/wiki/Changes).
#### <a name="v2.26.5">Version 2.26.5</a> (6/28/2016)
* Docs:
* Optimize png images using using zopflipng; see [pull #1230](https://github.com/Mottie/tablesorter/pull/1230) thanks [@PeterDaveHello](https://github.com/PeterDaveHello)!
* Add [`showProcessing`](https://mottie.github.io/tablesorter/docs/example-option-show-processing.html#display) toggle button.
* Add demo link for css3 animated `showProcessing` icons that actually works!
* Update to use jQuery v3.0.0.
* Readme: Update for previous version bump.
* Filter: Do not return altered filters variable. Fixes [issue #1237](https://github.com/Mottie/tablesorter/issues/1237).
* Grouping:
* Use correct pager row indexing. Fixes [issue #1232](https://github.com/Mottie/tablesorter/issues/1232).
* Prevent JS error with ajax & filtering. Fixes [issue #1232](https://github.com/Mottie/tablesorter/issues/1232).
* Fix lint issue.
* Resizable: Adjust handles on pager complete.
* Pager:
* Fix code alignment.
* Fix filtered regular expression definition.
#### <a name="v2.26.4">Version 2.26.4</a> (6/15/2016) #### <a name="v2.26.4">Version 2.26.4</a> (6/15/2016)
* Version bump due to merging issues. * Version bump due to merging issues.
@ -115,30 +133,3 @@ View the [complete change log here](//github.com/Mottie/tablesorter/wiki/Changes
* Filter: Fix select2 lint issue. * Filter: Fix select2 lint issue.
* Scroller: Hide `<col>` with hidden columns. Fixes [issue #1229](https://github.com/Mottie/tablesorter/issues/1229). * Scroller: Hide `<col>` with hidden columns. Fixes [issue #1229](https://github.com/Mottie/tablesorter/issues/1229).
* Grunt: Update dependencies & fix pager indentation. * Grunt: Update dependencies & fix pager indentation.
#### <a name="v2.26.2">Version 2.26.2</a> (5/28/2016)
* Docs:
* Add missing "tablesorter-ignoreRow" class. See [issue #1218](https://github.com/Mottie/tablesorter/issues/1218).
* Update jQuery to 1.12.3 & add migrate for v3.0.
* Correct grouping & resizable last update.
* Filter:
* Remove not any match limitation. See [updated demo](https://mottie.github.io/tablesorter/docs/example-widget-filter-any-match.html).
* Fix select2 v3 filter extension. See [issue #1216](https://github.com/Mottie/tablesorter/issues/1216); this code does not work with select2 v4.
* Testing: `setFilters` last parameter now `true` by default.
#### <a name="v2.26.1">Version 2.26.1</a> (5/16/2016)
* Docs:
* Update setFilters method.
* Update playground links & cleanup.
* Core: Minor organization of options.
* Filter:
* Minor organization of options.
* Allow any match searches with no input.
* Group:
* Escape angled brackets in group names. Fixes [issue #1206](https://github.com/Mottie/tablesorter/issues/1206).
* Fix HTML escape string & prevent undefined error. See [issue #1206](https://github.com/Mottie/tablesorter/issues/1206).
* Ensure empty cells get a header. Fixes [issue #1209](https://github.com/Mottie/tablesorter/issues/1209).
* Math: Add `math_completed` callback.
* Resizable: update resizable handle position after init. Fixes [issue #1207](https://github.com/Mottie/tablesorter/issues/1207).

View File

@ -1,6 +1,6 @@
/*! /*!
* tablesorter (FORK) pager plugin * tablesorter (FORK) pager plugin
* updated 5/1/2016 (v2.26.0) * updated 6/28/2015 (v2.26.5)
*/ */
/*jshint browser:true, jquery:true, unused:false */ /*jshint browser:true, jquery:true, unused:false */
;(function($) { ;(function($) {
@ -341,12 +341,11 @@
sz = p.size === 'all' ? p.totalRows : p.size, sz = p.size === 'all' ? p.totalRows : p.size,
s = ( p.page * sz ), s = ( p.page * sz ),
e = s + sz, e = s + sz,
f = c.widgetOptions && c.widgetOptions.filter_filteredRow || 'filtered',
last = 0, // for cache indexing last = 0, // for cache indexing
j = 0; // size counter j = 0; // size counter
p.cacheIndex = []; p.cacheIndex = [];
for ( i = 0; i < l; i++ ){ for ( i = 0; i < l; i++ ){
if ( !rows[i].className.match(f) ) { if ( !p.regexFiltered.test(rows[i].className) ) {
if (j === s && rows[i].className.match(c.cssChildRow)) { if (j === s && rows[i].className.match(c.cssChildRow)) {
// hide child rows @ start of pager (if already visible) // hide child rows @ start of pager (if already visible)
rows[i].style.display = 'none'; rows[i].style.display = 'none';
@ -636,7 +635,7 @@
count = f ? 0 : s; count = f ? 0 : s;
added = 0; added = 0;
while (added < e && index < rows.length) { while (added < e && index < rows.length) {
if (!f || !/filtered/.test(rows[index][0].className)){ if (!f || !p.regexFiltered.test(rows[index][0].className)){
count++; count++;
if (count > s && added <= e) { if (count > s && added <= e) {
added++; added++;
@ -940,6 +939,7 @@
} }
// skipped rows // skipped rows
p.regexRows = new RegExp('(' + (wo.filter_filteredRow || 'filtered') + '|' + c.selectorRemove.slice(1) + '|' + c.cssChildRow + ')'); p.regexRows = new RegExp('(' + (wo.filter_filteredRow || 'filtered') + '|' + c.selectorRemove.slice(1) + '|' + c.cssChildRow + ')');
p.regexFiltered = new RegExp(wo.filter_filteredRow || 'filtered');
$t $t
// .unbind( namespace ) adding in jQuery 1.4.3 ( I think ) // .unbind( namespace ) adding in jQuery 1.4.3 ( I think )
@ -1120,18 +1120,18 @@
// see #486 // see #486
ts.showError = function( table, xhr, settings, exception ) { ts.showError = function( table, xhr, settings, exception ) {
var $row, var $row,
$table = $( table ), $table = $( table ),
c = $table[0].config, c = $table[0].config,
wo = c && c.widgetOptions, wo = c && c.widgetOptions,
errorRow = c.pager && c.pager.cssErrorRow || errorRow = c.pager && c.pager.cssErrorRow ||
wo && wo.pager_css && wo.pager_css.errorRow || wo && wo.pager_css && wo.pager_css.errorRow ||
'tablesorter-errorRow', 'tablesorter-errorRow',
typ = typeof xhr, typ = typeof xhr,
valid = true, valid = true,
message = '', message = '',
removeRow = function(){ removeRow = function(){
c.$table.find( 'thead' ).find( '.' + errorRow ).remove(); c.$table.find( 'thead' ).find( '.' + errorRow ).remove();
}; };
if ( !$table.length ) { if ( !$table.length ) {
console.error('tablesorter showError: no table parameter passed'); console.error('tablesorter showError: no table parameter passed');
@ -1158,13 +1158,13 @@
if ( message === '' ) { if ( message === '' ) {
if ( typ === 'object' ) { if ( typ === 'object' ) {
message = message =
xhr.status === 0 ? 'Not connected, verify Network' : xhr.status === 0 ? 'Not connected, verify Network' :
xhr.status === 404 ? 'Requested page not found [404]' : xhr.status === 404 ? 'Requested page not found [404]' :
xhr.status === 500 ? 'Internal Server Error [500]' : xhr.status === 500 ? 'Internal Server Error [500]' :
exception === 'parsererror' ? 'Requested JSON parse failed' : exception === 'parsererror' ? 'Requested JSON parse failed' :
exception === 'timeout' ? 'Time out error' : exception === 'timeout' ? 'Time out error' :
exception === 'abort' ? 'Ajax Request aborted' : exception === 'abort' ? 'Ajax Request aborted' :
'Uncaught error: ' + xhr.statusText + ' [' + xhr.status + ']'; 'Uncaught error: ' + xhr.statusText + ' [' + xhr.status + ']';
} else if ( typ === 'string' ) { } else if ( typ === 'string' ) {
// keep backward compatibility (external usage just passes a message string) // keep backward compatibility (external usage just passes a message string)
message = xhr; message = xhr;
@ -1176,16 +1176,16 @@
// allow message to include entire row HTML! // allow message to include entire row HTML!
$row = ( /tr\>/.test(message) ? $(message) : $('<tr><td colspan="' + c.columns + '">' + message + '</td></tr>') ) $row = ( /tr\>/.test(message) ? $(message) : $('<tr><td colspan="' + c.columns + '">' + message + '</td></tr>') )
.click( function() { .click( function() {
$( this ).remove(); $( this ).remove();
}) })
// add error row to thead instead of tbody, or clicking on the header will result in a parser error // add error row to thead instead of tbody, or clicking on the header will result in a parser error
.appendTo( c.$table.find( 'thead:first' ) ) .appendTo( c.$table.find( 'thead:first' ) )
.addClass( errorRow + ' ' + c.selectorRemove.slice(1) ) .addClass( errorRow + ' ' + c.selectorRemove.slice(1) )
.attr({ .attr({
role : 'alert', role : 'alert',
'aria-live' : 'assertive' 'aria-live' : 'assertive'
}); });
}; };

File diff suppressed because one or more lines are too long

View File

@ -1,4 +1,4 @@
/*! tablesorter (FORK) - updated 06-15-2016 (v2.26.4)*/ /*! tablesorter (FORK) - updated 06-28-2016 (v2.26.5)*/
/* Includes widgets ( storage,uitheme,columns,filter,stickyHeaders,resizable,saveSort ) */ /* Includes widgets ( storage,uitheme,columns,filter,stickyHeaders,resizable,saveSort ) */
(function(factory) { (function(factory) {
if (typeof define === 'function' && define.amd) { if (typeof define === 'function' && define.amd) {
@ -10,7 +10,7 @@
} }
}(function($) { }(function($) {
/*! TableSorter (FORK) v2.26.4 *//* /*! TableSorter (FORK) v2.26.5 *//*
* Client-side table sorting with ease! * Client-side table sorting with ease!
* @requires jQuery v1.2.6+ * @requires jQuery v1.2.6+
* *
@ -33,7 +33,7 @@
'use strict'; 'use strict';
var ts = $.tablesorter = { var ts = $.tablesorter = {
version : '2.26.4', version : '2.26.5',
parsers : [], parsers : [],
widgets : [], widgets : [],
@ -3098,7 +3098,7 @@
})(jQuery); })(jQuery);
/*! Widget: filter - updated 5/28/2016 (v2.26.2) *//* /*! Widget: filter - updated 6/28/2015 (v2.26.5) *//*
* Requires tablesorter v2.8+ and jQuery 1.7+ * Requires tablesorter v2.8+ and jQuery 1.7+
* by Rob Garrison * by Rob Garrison
*/ */
@ -3729,14 +3729,16 @@
// encode or decode filters for storage; see #1026 // encode or decode filters for storage; see #1026
processFilters: function( filters, encode ) { processFilters: function( filters, encode ) {
var indx, var indx,
// fixes #1237; previously returning an encoded "filters" value
result = [],
mode = encode ? encodeURIComponent : decodeURIComponent, mode = encode ? encodeURIComponent : decodeURIComponent,
len = filters.length; len = filters.length;
for ( indx = 0; indx < len; indx++ ) { for ( indx = 0; indx < len; indx++ ) {
if ( filters[ indx ] ) { if ( filters[ indx ] ) {
filters[ indx ] = mode( filters[ indx ] ); result[ indx ] = mode( filters[ indx ] );
} }
} }
return filters; return result;
}, },
setDefaults: function( table, c, wo ) { setDefaults: function( table, c, wo ) {
var isArray, saved, indx, col, $filters, var isArray, saved, indx, col, $filters,
@ -5224,7 +5226,7 @@
})(jQuery, window); })(jQuery, window);
/*! Widget: resizable - updated 5/16/2015 (v2.26.1) */ /*! Widget: resizable - updated 6/28/2015 (v2.26.5) */
/*jshint browser:true, jquery:true, unused:false */ /*jshint browser:true, jquery:true, unused:false */
;(function ($, window) { ;(function ($, window) {
'use strict'; 'use strict';
@ -5480,7 +5482,7 @@
// right click to reset columns to default widths // right click to reset columns to default widths
c.$table c.$table
.bind( 'columnUpdate' + namespace, function() { .bind( 'columnUpdate' + namespace + ' pagerComplete' + namespace, function() {
ts.resizable.setHandlePosition( c, wo ); ts.resizable.setHandlePosition( c, wo );
}) })
.find( 'thead:first' ) .find( 'thead:first' )

File diff suppressed because one or more lines are too long

View File

@ -8,7 +8,7 @@
} }
}(function($) { }(function($) {
/*! TableSorter (FORK) v2.26.4 *//* /*! TableSorter (FORK) v2.26.5 *//*
* Client-side table sorting with ease! * Client-side table sorting with ease!
* @requires jQuery v1.2.6+ * @requires jQuery v1.2.6+
* *
@ -31,7 +31,7 @@
'use strict'; 'use strict';
var ts = $.tablesorter = { var ts = $.tablesorter = {
version : '2.26.4', version : '2.26.5',
parsers : [], parsers : [],
widgets : [], widgets : [],

File diff suppressed because one or more lines are too long

View File

@ -1,4 +1,4 @@
/*! tablesorter (FORK) - updated 06-15-2016 (v2.26.4)*/ /*! tablesorter (FORK) - updated 06-28-2016 (v2.26.5)*/
/* Includes widgets ( storage,uitheme,columns,filter,stickyHeaders,resizable,saveSort ) */ /* Includes widgets ( storage,uitheme,columns,filter,stickyHeaders,resizable,saveSort ) */
(function(factory) { (function(factory) {
if (typeof define === 'function' && define.amd) { if (typeof define === 'function' && define.amd) {
@ -366,7 +366,7 @@
})(jQuery); })(jQuery);
/*! Widget: filter - updated 5/28/2016 (v2.26.2) *//* /*! Widget: filter - updated 6/28/2015 (v2.26.5) *//*
* Requires tablesorter v2.8+ and jQuery 1.7+ * Requires tablesorter v2.8+ and jQuery 1.7+
* by Rob Garrison * by Rob Garrison
*/ */
@ -997,14 +997,16 @@
// encode or decode filters for storage; see #1026 // encode or decode filters for storage; see #1026
processFilters: function( filters, encode ) { processFilters: function( filters, encode ) {
var indx, var indx,
// fixes #1237; previously returning an encoded "filters" value
result = [],
mode = encode ? encodeURIComponent : decodeURIComponent, mode = encode ? encodeURIComponent : decodeURIComponent,
len = filters.length; len = filters.length;
for ( indx = 0; indx < len; indx++ ) { for ( indx = 0; indx < len; indx++ ) {
if ( filters[ indx ] ) { if ( filters[ indx ] ) {
filters[ indx ] = mode( filters[ indx ] ); result[ indx ] = mode( filters[ indx ] );
} }
} }
return filters; return result;
}, },
setDefaults: function( table, c, wo ) { setDefaults: function( table, c, wo ) {
var isArray, saved, indx, col, $filters, var isArray, saved, indx, col, $filters,
@ -2492,7 +2494,7 @@
})(jQuery, window); })(jQuery, window);
/*! Widget: resizable - updated 5/16/2015 (v2.26.1) */ /*! Widget: resizable - updated 6/28/2015 (v2.26.5) */
/*jshint browser:true, jquery:true, unused:false */ /*jshint browser:true, jquery:true, unused:false */
;(function ($, window) { ;(function ($, window) {
'use strict'; 'use strict';
@ -2748,7 +2750,7 @@
// right click to reset columns to default widths // right click to reset columns to default widths
c.$table c.$table
.bind( 'columnUpdate' + namespace, function() { .bind( 'columnUpdate' + namespace + ' pagerComplete' + namespace, function() {
ts.resizable.setHandlePosition( c, wo ); ts.resizable.setHandlePosition( c, wo );
}) })
.find( 'thead:first' ) .find( 'thead:first' )

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

View File

@ -23,7 +23,8 @@
<script src="../js/jquery.tablesorter.widgets.js"></script> <script src="../js/jquery.tablesorter.widgets.js"></script>
<script id="js">$(function(){ <script id="js">$(function(){
var t, start; var t, start,
vis = false;
$("table").tablesorter({ $("table").tablesorter({
showProcessing: true, showProcessing: true,
@ -34,19 +35,30 @@
filter_reset : '.reset' filter_reset : '.reset'
} }
}) })
.bind('filterStart filterEnd', function(e, filter){ .bind('sortBegin sortEnd', function(e) {
vis = e.type === "sortBegin";
})
.bind('filterStart filterEnd', function(e, filter) {
if (e.type === 'filterStart') { if (e.type === 'filterStart') {
start = e.timeStamp; start = e.timeStamp;
vis = true;
t = '<li>Filter Started: [' + filter + ']</li>'; t = '<li>Filter Started: [' + filter + ']</li>';
} else if (start) { } else if (start) {
vis = false;
t = '<li>Filter Ended after ' + ( (e.timeStamp - start)/1000 ).toFixed(2) + ' seconds</li>'; t = '<li>Filter Ended after ' + ( (e.timeStamp - start)/1000 ).toFixed(2) + ' seconds</li>';
start = 0;
} else { } else {
return; return;
} }
$("#display").append(t).find('li:first').remove(); $("#display").append(t).find('li:first').remove();
}); });
$('button').click(function(){ $('.toggle').click(function(){
vis = !vis;
$.tablesorter.isProcessing($("table"), vis);
});
$('[data-search]').click(function(){
var search = $(this).attr('data-search').split(','); var search = $(this).attr('data-search').split(',');
$('table').trigger('search', [search]); $('table').trigger('search', [search]);
return false; return false;
@ -69,8 +81,14 @@
<em>NOTE!</em> <em>NOTE!</em>
</p> </p>
<ul> <ul>
<li>As of <span class="version">v2.16.3</span>, there is a built-in 500 millisecond delay before the processing icon will show. If the sort has completed within that time, the icon will not appear.</li> <li>As of <span class="version">v2.16.3</span>, there is a built-in 500 millisecond delay before the processing icon will show. If the sort has completed within that time, the icon will not appear.<br><br></li>
<li>There is an issue with the processing icon not appearing at all, or the animation appears frozen when processing data in very large tables. This is due to javascript only being able to process one thread at-a-time; If you know of a solution or work-around please <a href="https://github.com/Mottie/tablesorter/issues/158">add a comment</a> or contribute a fix!</li> <li>There is an issue with the processing icon not appearing at all, or the animation appears frozen when processing data in very large tables. This is due to javascript only being able to process one thread at-a-time; If you know of a solution or work-around please <a href="https://github.com/Mottie/tablesorter/issues/158">add a comment</a> or contribute a fix!</li>
<li><strong>I have found a solution for the processing icon animation</strong>
<ul>
<li>Use CSS3 animations instead of an animated gif! Here is a <a href="http://jsfiddle.net/Mottie/2a941ru0/">demo</a>.</li>
<li>I have yet to incorporate it because it requires that all headers cells contain an inner div. And since it is possible to set the <a href="index.html#headertemplate">headerTemplate</a> to an empty string to prevent modifying the cell, I thought it might be best to put this off until the next major release (Abelt); whenever I have time to work on it.</li>
</ul>
</li>
</ul> </ul>
<h1>Javascript</h1> <h1>Javascript</h1>
@ -90,7 +108,8 @@
<!-- ",l,f,>80".split(",") ends up as an array [ "", "l", "f", ">80" ] --> <!-- ",l,f,>80".split(",") ends up as an array [ "", "l", "f", ">80" ] -->
<button type="button" data-search=",l,f,>80">Filter</button> (females majoring in languages with a score >80)<br> <button type="button" data-search=",l,f,>80">Filter</button> (females majoring in languages with a score >80)<br>
<button type="button" data-search=",l,!female,>80">Filter</button> (males majoring in languages with a score >80)<br> <button type="button" data-search=",l,!female,>80">Filter</button> (males majoring in languages with a score >80)<br>
<button type="button" class="reset">Reset</button> <button type="button" class="reset">Reset</button><br>
<button type="button" class="toggle">Toggle</button>
<table class="tablesorter"> <table class="tablesorter">
<thead> <thead>

View File

@ -458,7 +458,7 @@
<li><a href="example-widget-column-selector.html">Column selector widget</a> (<span class="version">v2.15</span>; <span class="version updated">v2.25.9</span>).</li> <li><a href="example-widget-column-selector.html">Column selector widget</a> (<span class="version">v2.15</span>; <span class="version updated">v2.25.9</span>).</li>
<li><a href="example-widget-editable.html">Content editable widget</a> (v2.9; <span class="version updated">v2.25.5</span>).</li> <li><a href="example-widget-editable.html">Content editable widget</a> (v2.9; <span class="version updated">v2.25.5</span>).</li>
<li><span class="label label-info">Beta</span> <a href="example-dragtable.html">Dragtable mod</a> - (jQuery UI widget for column reordering [<a class="external" href="http://stackoverflow.com/a/27770224/145346">ref</a>]; <span class="version">v2.24.0</span>).</li> <li><span class="label label-info">Beta</span> <a href="example-dragtable.html">Dragtable mod</a> - (jQuery UI widget for column reordering [<a class="external" href="http://stackoverflow.com/a/27770224/145346">ref</a>]; <span class="version">v2.24.0</span>).</li>
<li><span class="results">&dagger;</span> Filter widget (<span class="version updated">v2.25.9</span>): <li><span class="results">&dagger;</span> Filter widget (<span class="version updated">v2.26.5</span>):
<ul> <ul>
<li><a href="example-widget-filter.html">basic</a> (v2.0.18; <span class="version updated">v2.25.5</span>).</li> <li><a href="example-widget-filter.html">basic</a> (v2.0.18; <span class="version updated">v2.25.5</span>).</li>
<li><a href="example-widget-filter-any-match.html">external option (match any column)</a> (<span class="version">v2.13.3</span>; <span class="version updated">v2.26.2</span>).</li> <li><a href="example-widget-filter-any-match.html">external option (match any column)</a> (<span class="version">v2.13.3</span>; <span class="version updated">v2.26.2</span>).</li>
@ -476,7 +476,7 @@
<li><span class="label label-info">Beta</span> <a href="example-widget-formatter.html">Formatter widget</a> (<span class="version">v2.19.1</span>).</li> <li><span class="label label-info">Beta</span> <a href="example-widget-formatter.html">Formatter widget</a> (<span class="version">v2.19.1</span>).</li>
<li>Grouping rows widget: <li>Grouping rows widget:
<ul> <ul>
<li><a href="example-widget-grouping.html">basic</a> (v2.8; <span class="version updated">v2.26.1</span>).</li> <li><a href="example-widget-grouping.html">basic</a> (v2.8; <span class="version updated">v2.26.5</span>).</li>
<li><a href="example-widget-grouping-filter-childrows.html">Grouping + filter + child rows</a> (<span class="updated version">v2.15.12</span>).</li> <li><a href="example-widget-grouping-filter-childrows.html">Grouping + filter + child rows</a> (<span class="updated version">v2.15.12</span>).</li>
</ul> </ul>
</li> </li>
@ -488,16 +488,16 @@
<br><br> <br><br>
</li> </li>
<li>Pager plugin (<a href="example-pager.html">basic</a> &amp; <a href="example-pager-ajax.html">ajax</a> demos; <span class="version updated">v2.26.0</span>).</li> <li>Pager plugin (<a href="example-pager.html">basic</a> &amp; <a href="example-pager-ajax.html">ajax</a> demos; <span class="version updated">v2.26.5</span>).</li>
<li> <li>
Pager widget (<a href="example-widget-pager.html">basic</a> &amp; <a href="example-widget-pager-ajax.html">ajax</a> demos) (<span class="version">v2.12</span>; <span class="version updated">v2.26.0</span>).<br> Pager widget (<a href="example-widget-pager.html">basic</a> &amp; <a href="example-widget-pager-ajax.html">ajax</a> demos) (<span class="version">v2.12</span>; <span class="version updated">v2.26.5</span>).<br>
<br> <br>
</li> </li>
<li><a href="example-widget-print.html">Print widget</a> (<span class="version">v2.16.4</span>; <span class="version updated">v2.25.8</span>).</li> <li><a href="example-widget-print.html">Print widget</a> (<span class="version">v2.16.4</span>; <span class="version updated">v2.25.8</span>).</li>
<li><a href="example-widget-reflow.html">Reflow widget</a> (<span class="version">v2.16</span>; <span class="version updated">v2.19.0</span>).</li> <li><a href="example-widget-reflow.html">Reflow widget</a> (<span class="version">v2.16</span>; <span class="version updated">v2.19.0</span>).</li>
<li><a href="example-widgets.html">Repeat headers widget</a> (v2.0.5; <span class="version updated">v2.19.0</span>).</li> <li><a href="example-widgets.html">Repeat headers widget</a> (v2.0.5; <span class="version updated">v2.19.0</span>).</li>
<li><span class="results">&dagger;</span> <a href="example-widget-resizable.html">Resizable columns widget</a> (v2.0.23.1; <span class="version updated">v2.26.1</span>).</li> <li><span class="results">&dagger;</span> <a href="example-widget-resizable.html">Resizable columns widget</a> (v2.0.23.1; <span class="version updated">v2.26.5</span>).</li>
<li><span class="results">&dagger;</span> <a href="example-widget-savesort.html">Save sort widget</a> (v2.0.27; <span class="version updated">v2.24.0</span>).</li> <li><span class="results">&dagger;</span> <a href="example-widget-savesort.html">Save sort widget</a> (v2.0.27; <span class="version updated">v2.24.0</span>).</li>
<li><a href="example-widget-scroller.html">Scroller widget</a> (<span class="version">v2.9</span>; <span class="version updated">v2.26.3</span>).</li> <li><a href="example-widget-scroller.html">Scroller widget</a> (<span class="version">v2.9</span>; <span class="version updated">v2.26.3</span>).</li>
<li><span class="label label-info">Beta</span> <a href="example-widget-sort-to-hash.html">Sort-to-hash widget</a> (<span class="version">v2.22.4</span>; <span class="version updated">v2.24.4</span>).</li> <li><span class="label label-info">Beta</span> <a href="example-widget-sort-to-hash.html">Sort-to-hash widget</a> (<span class="version">v2.22.4</span>; <span class="version updated">v2.24.4</span>).</li>
@ -7795,8 +7795,8 @@ $.tablesorter.addHeaderResizeEvent( table, true );</pre>
</div> </div>
<!-- jQuery --> <!-- jQuery -->
<script src="https://code.jquery.com/jquery-3.0.0-rc1.js"></script> <script src="js/jquery-3.0.0.min.js"></script>
<script src="js/jquery-migrate-3.0.0-rc1.min.js"></script> <script src="js/jquery-migrate-3.0.0.min.js"></script>
<script src="js/jquery-ui.min.js"></script> <script src="js/jquery-ui.min.js"></script>
<script src="js/prettify.js"></script> <script src="js/prettify.js"></script>
<script src="js/docs.js"></script> <script src="js/docs.js"></script>

View File

@ -228,15 +228,15 @@
} }
// update stickyHeader when menu closes // update stickyHeader when menu closes
$('#main-nav-check').bind('change', function(){ $('#main-nav-check').on('change', function(){
setTimeout(function(){ setTimeout(function(){
$(window).scroll(); $(window).scroll();
}, 350); // transition animation 300ms }, 350); // transition animation 300ms
}); });
$(window).bind('load', function(){ $(window).on('load', function(){
if ($('#root').length) { if ($('#root').length) {
$(window).bind('hashchange', function(){ $(window).on('hashchange', function(){
showProperty(); showProperty();
}); });
showProperty(); showProperty();
@ -259,7 +259,7 @@
}); });
}); });
$('.toggleparsedvalue').bind('click', function(){ $('.toggleparsedvalue').on('click', function(){
$('.val').toggleClass('hidden'); $('.val').toggleClass('hidden');
return false; return false;
}); });

File diff suppressed because it is too large Load Diff

4
docs/js/jquery-3.0.0.min.js vendored Normal file

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

2
docs/js/jquery-migrate-3.0.0.min.js vendored Normal file

File diff suppressed because one or more lines are too long

View File

@ -4,7 +4,7 @@
*/ */
/*! tablesorter (FORK) - updated 06-15-2016 (v2.26.4)*/ /*! tablesorter (FORK) - updated 06-28-2016 (v2.26.5)*/
/* Includes widgets ( storage,uitheme,columns,filter,stickyHeaders,resizable,saveSort ) */ /* Includes widgets ( storage,uitheme,columns,filter,stickyHeaders,resizable,saveSort ) */
(function(factory) { (function(factory) {
if (typeof define === 'function' && define.amd) { if (typeof define === 'function' && define.amd) {
@ -16,7 +16,7 @@
} }
}(function($) { }(function($) {
/*! TableSorter (FORK) v2.26.4 *//* /*! TableSorter (FORK) v2.26.5 *//*
* Client-side table sorting with ease! * Client-side table sorting with ease!
* @requires jQuery v1.2.6+ * @requires jQuery v1.2.6+
* *
@ -39,7 +39,7 @@
'use strict'; 'use strict';
var ts = $.tablesorter = { var ts = $.tablesorter = {
version : '2.26.4', version : '2.26.5',
parsers : [], parsers : [],
widgets : [], widgets : [],
@ -3104,7 +3104,7 @@
})(jQuery); })(jQuery);
/*! Widget: filter - updated 5/28/2016 (v2.26.2) *//* /*! Widget: filter - updated 6/28/2015 (v2.26.5) *//*
* Requires tablesorter v2.8+ and jQuery 1.7+ * Requires tablesorter v2.8+ and jQuery 1.7+
* by Rob Garrison * by Rob Garrison
*/ */
@ -3735,14 +3735,16 @@
// encode or decode filters for storage; see #1026 // encode or decode filters for storage; see #1026
processFilters: function( filters, encode ) { processFilters: function( filters, encode ) {
var indx, var indx,
// fixes #1237; previously returning an encoded "filters" value
result = [],
mode = encode ? encodeURIComponent : decodeURIComponent, mode = encode ? encodeURIComponent : decodeURIComponent,
len = filters.length; len = filters.length;
for ( indx = 0; indx < len; indx++ ) { for ( indx = 0; indx < len; indx++ ) {
if ( filters[ indx ] ) { if ( filters[ indx ] ) {
filters[ indx ] = mode( filters[ indx ] ); result[ indx ] = mode( filters[ indx ] );
} }
} }
return filters; return result;
}, },
setDefaults: function( table, c, wo ) { setDefaults: function( table, c, wo ) {
var isArray, saved, indx, col, $filters, var isArray, saved, indx, col, $filters,
@ -5230,7 +5232,7 @@
})(jQuery, window); })(jQuery, window);
/*! Widget: resizable - updated 5/16/2015 (v2.26.1) */ /*! Widget: resizable - updated 6/28/2015 (v2.26.5) */
/*jshint browser:true, jquery:true, unused:false */ /*jshint browser:true, jquery:true, unused:false */
;(function ($, window) { ;(function ($, window) {
'use strict'; 'use strict';
@ -5486,7 +5488,7 @@
// right click to reset columns to default widths // right click to reset columns to default widths
c.$table c.$table
.bind( 'columnUpdate' + namespace, function() { .bind( 'columnUpdate' + namespace + ' pagerComplete' + namespace, function() {
ts.resizable.setHandlePosition( c, wo ); ts.resizable.setHandlePosition( c, wo );
}) })
.find( 'thead:first' ) .find( 'thead:first' )

View File

@ -1,4 +1,4 @@
/*! TableSorter (FORK) v2.26.4 *//* /*! TableSorter (FORK) v2.26.5 *//*
* Client-side table sorting with ease! * Client-side table sorting with ease!
* @requires jQuery v1.2.6+ * @requires jQuery v1.2.6+
* *
@ -21,7 +21,7 @@
'use strict'; 'use strict';
var ts = $.tablesorter = { var ts = $.tablesorter = {
version : '2.26.4', version : '2.26.5',
parsers : [], parsers : [],
widgets : [], widgets : [],

View File

@ -4,7 +4,7 @@
*/ */
/*! tablesorter (FORK) - updated 06-15-2016 (v2.26.4)*/ /*! tablesorter (FORK) - updated 06-28-2016 (v2.26.5)*/
/* Includes widgets ( storage,uitheme,columns,filter,stickyHeaders,resizable,saveSort ) */ /* Includes widgets ( storage,uitheme,columns,filter,stickyHeaders,resizable,saveSort ) */
(function(factory) { (function(factory) {
if (typeof define === 'function' && define.amd) { if (typeof define === 'function' && define.amd) {
@ -372,7 +372,7 @@
})(jQuery); })(jQuery);
/*! Widget: filter - updated 5/28/2016 (v2.26.2) *//* /*! Widget: filter - updated 6/28/2015 (v2.26.5) *//*
* Requires tablesorter v2.8+ and jQuery 1.7+ * Requires tablesorter v2.8+ and jQuery 1.7+
* by Rob Garrison * by Rob Garrison
*/ */
@ -1003,14 +1003,16 @@
// encode or decode filters for storage; see #1026 // encode or decode filters for storage; see #1026
processFilters: function( filters, encode ) { processFilters: function( filters, encode ) {
var indx, var indx,
// fixes #1237; previously returning an encoded "filters" value
result = [],
mode = encode ? encodeURIComponent : decodeURIComponent, mode = encode ? encodeURIComponent : decodeURIComponent,
len = filters.length; len = filters.length;
for ( indx = 0; indx < len; indx++ ) { for ( indx = 0; indx < len; indx++ ) {
if ( filters[ indx ] ) { if ( filters[ indx ] ) {
filters[ indx ] = mode( filters[ indx ] ); result[ indx ] = mode( filters[ indx ] );
} }
} }
return filters; return result;
}, },
setDefaults: function( table, c, wo ) { setDefaults: function( table, c, wo ) {
var isArray, saved, indx, col, $filters, var isArray, saved, indx, col, $filters,
@ -2498,7 +2500,7 @@
})(jQuery, window); })(jQuery, window);
/*! Widget: resizable - updated 5/16/2015 (v2.26.1) */ /*! Widget: resizable - updated 6/28/2015 (v2.26.5) */
/*jshint browser:true, jquery:true, unused:false */ /*jshint browser:true, jquery:true, unused:false */
;(function ($, window) { ;(function ($, window) {
'use strict'; 'use strict';
@ -2754,7 +2756,7 @@
// right click to reset columns to default widths // right click to reset columns to default widths
c.$table c.$table
.bind( 'columnUpdate' + namespace, function() { .bind( 'columnUpdate' + namespace + ' pagerComplete' + namespace, function() {
ts.resizable.setHandlePosition( c, wo ); ts.resizable.setHandlePosition( c, wo );
}) })
.find( 'thead:first' ) .find( 'thead:first' )

View File

@ -1,4 +1,4 @@
/*! Widget: filter - updated 5/28/2016 (v2.26.2) *//* /*! Widget: filter - updated 6/28/2015 (v2.26.5) *//*
* Requires tablesorter v2.8+ and jQuery 1.7+ * Requires tablesorter v2.8+ and jQuery 1.7+
* by Rob Garrison * by Rob Garrison
*/ */
@ -629,14 +629,16 @@
// encode or decode filters for storage; see #1026 // encode or decode filters for storage; see #1026
processFilters: function( filters, encode ) { processFilters: function( filters, encode ) {
var indx, var indx,
// fixes #1237; previously returning an encoded "filters" value
result = [],
mode = encode ? encodeURIComponent : decodeURIComponent, mode = encode ? encodeURIComponent : decodeURIComponent,
len = filters.length; len = filters.length;
for ( indx = 0; indx < len; indx++ ) { for ( indx = 0; indx < len; indx++ ) {
if ( filters[ indx ] ) { if ( filters[ indx ] ) {
filters[ indx ] = mode( filters[ indx ] ); result[ indx ] = mode( filters[ indx ] );
} }
} }
return filters; return result;
}, },
setDefaults: function( table, c, wo ) { setDefaults: function( table, c, wo ) {
var isArray, saved, indx, col, $filters, var isArray, saved, indx, col, $filters,

View File

@ -1,4 +1,4 @@
/*! Widget: grouping - updated 5/16/2015 (v2.26.1) *//* /*! Widget: grouping - updated 6/28/2015 (v2.26.5) *//*
* Requires tablesorter v2.8+ and jQuery 1.7+ * Requires tablesorter v2.8+ and jQuery 1.7+
* by Rob Garrison * by Rob Garrison
*/ */
@ -199,19 +199,23 @@
}, },
findColumnGroups : function( c, wo, data ) { findColumnGroups : function( c, wo, data ) {
var tbodyIndex, norm_rows, $row, rowIndex, end, undef, var tbodyIndex, norm_rows, $row, rowIndex, end, undef,
hasPager = ts.hasWidget( c.table, 'pager' ); hasPager = ts.hasWidget( c.table, 'pager' ),
p = c.pager || {};
data.groupIndex = 0; data.groupIndex = 0;
for ( tbodyIndex = 0; tbodyIndex < c.$tbodies.length; tbodyIndex++ ) { for ( tbodyIndex = 0; tbodyIndex < c.$tbodies.length; tbodyIndex++ ) {
norm_rows = c.cache[ tbodyIndex ].normalized; norm_rows = c.cache[ tbodyIndex ].normalized;
data.group = undef; // clear grouping across tbodies data.group = undef; // clear grouping across tbodies
rowIndex = hasPager ? c.pager.startRow - 1 : 0; rowIndex = hasPager && !p.ajax ? p.startRow - 1 : 0;
end = hasPager ? c.pager.endRow : norm_rows.length; end = hasPager ? p.endRow - ( p.ajax ? p.startRow : 0 ) : norm_rows.length;
for ( ; rowIndex < end; rowIndex++ ) { for ( ; rowIndex < end; rowIndex++ ) {
data.rowData = norm_rows[ rowIndex ]; data.rowData = norm_rows[ rowIndex ];
data.$row = data.rowData[ c.columns ].$row; // fixes #1232 - ajax issue; if endRow > norm_rows.length (after filtering), then data.rowData is undefined
// fixes #438 if (data.rowData) {
if ( data.$row.is( ':visible' ) && tsg.types[ data.grouping[ 1 ] ] ) { data.$row = data.rowData[ c.columns ].$row;
tsg.insertGroupHeader( c, wo, data ); // fixes #438
if ( data.$row.is( ':visible' ) && tsg.types[ data.grouping[ 1 ] ] ) {
tsg.insertGroupHeader( c, wo, data );
}
} }
} }
} }

View File

@ -1,4 +1,4 @@
/*! Widget: Pager - updated 5/1/2016 (v2.26.0) */ /*! Widget: Pager - updated 6/28/2015 (v2.26.5) */
/* Requires tablesorter v2.8+ and jQuery 1.7+ /* Requires tablesorter v2.8+ and jQuery 1.7+
* by Rob Garrison * by Rob Garrison
*/ */
@ -190,6 +190,7 @@
// skipped rows // skipped rows
p.regexRows = new RegExp( '(' + ( wo.filter_filteredRow || 'filtered' ) + '|' + p.regexRows = new RegExp( '(' + ( wo.filter_filteredRow || 'filtered' ) + '|' +
c.selectorRemove.slice( 1 ) + '|' + c.cssChildRow + ')' ); c.selectorRemove.slice( 1 ) + '|' + c.cssChildRow + ')' );
p.regexFiltered = new RegExp( wo.filter_filteredRow || 'filtered' );
// clear initialized flag // clear initialized flag
p.initialized = false; p.initialized = false;
@ -637,7 +638,6 @@
sz = p.size === 'all' ? p.totalRows : p.size, sz = p.size === 'all' ? p.totalRows : p.size,
start = ( p.page * sz ), start = ( p.page * sz ),
end = start + sz, end = start + sz,
filtr = wo && wo.filter_filteredRow || 'filtered',
last = 0, // for cache indexing last = 0, // for cache indexing
size = 0; // size counter size = 0; // size counter
p.cacheIndex = []; p.cacheIndex = [];
@ -648,7 +648,7 @@
last = 0; // for cache indexing last = 0; // for cache indexing
size = 0; // size counter size = 0; // size counter
for ( rowIndex = 0; rowIndex < len; rowIndex++ ) { for ( rowIndex = 0; rowIndex < len; rowIndex++ ) {
if ( !$rows[ rowIndex ].className.match( filtr ) ) { if ( !p.regexFiltered.test( $rows[ rowIndex ].className ) ) {
if ( size === start && $rows[ rowIndex ].className.match( c.cssChildRow ) ) { if ( size === start && $rows[ rowIndex ].className.match( c.cssChildRow ) ) {
// hide child rows @ start of pager (if already visible) // hide child rows @ start of pager (if already visible)
$rows[ rowIndex ].style.display = 'none'; $rows[ rowIndex ].style.display = 'none';
@ -949,7 +949,7 @@
count = f ? 0 : s; count = f ? 0 : s;
added = 0; added = 0;
while ( added < e && index < rows.length ) { while ( added < e && index < rows.length ) {
if ( !f || !/filtered/.test( rows[ index ][ 0 ].className ) ) { if ( !f || !p.regexFiltered.test( rows[ index ][ 0 ].className ) ) {
count++; count++;
if ( count > s && added <= e ) { if ( count > s && added <= e ) {
added++; added++;

View File

@ -1,4 +1,4 @@
/*! Widget: resizable - updated 5/16/2015 (v2.26.1) */ /*! Widget: resizable - updated 6/28/2015 (v2.26.5) */
/*jshint browser:true, jquery:true, unused:false */ /*jshint browser:true, jquery:true, unused:false */
;(function ($, window) { ;(function ($, window) {
'use strict'; 'use strict';
@ -254,7 +254,7 @@
// right click to reset columns to default widths // right click to reset columns to default widths
c.$table c.$table
.bind( 'columnUpdate' + namespace, function() { .bind( 'columnUpdate' + namespace + ' pagerComplete' + namespace, function() {
ts.resizable.setHandlePosition( c, wo ); ts.resizable.setHandlePosition( c, wo );
}) })
.find( 'thead:first' ) .find( 'thead:first' )

View File

@ -1,7 +1,7 @@
{ {
"name": "tablesorter", "name": "tablesorter",
"title": "tablesorter", "title": "tablesorter",
"version": "2.26.4", "version": "2.26.5",
"description": "tablesorter (FORK) is a jQuery plugin for turning a standard HTML table with THEAD and TBODY tags into a sortable table without page refreshes. tablesorter can successfully parse and sort many types of data including linked data in a cell.", "description": "tablesorter (FORK) is a jQuery plugin for turning a standard HTML table with THEAD and TBODY tags into a sortable table without page refreshes. tablesorter can successfully parse and sort many types of data including linked data in a cell.",
"author": { "author": {
"name": "Christian Bach", "name": "Christian Bach",

View File

@ -1,7 +1,7 @@
{ {
"name": "tablesorter", "name": "tablesorter",
"title": "tablesorter", "title": "tablesorter",
"version": "2.26.4", "version": "2.26.5",
"description": "tablesorter is a jQuery plugin for turning a standard HTML table with THEAD and TBODY tags into a sortable table without page refreshes. tablesorter can successfully parse and sort many types of data including linked data in a cell.\n\nThis forked version adds lots of new enhancements including: alphanumeric sorting, pager callback functons, multiple widgets providing column styling, ui theme application, sticky headers, column filters and resizer, as well as extended documentation with a lot more demos.", "description": "tablesorter is a jQuery plugin for turning a standard HTML table with THEAD and TBODY tags into a sortable table without page refreshes. tablesorter can successfully parse and sort many types of data including linked data in a cell.\n\nThis forked version adds lots of new enhancements including: alphanumeric sorting, pager callback functons, multiple widgets providing column styling, ui theme application, sticky headers, column filters and resizer, as well as extended documentation with a lot more demos.",
"author": { "author": {
"name": "Christian Bach", "name": "Christian Bach",

View File

@ -7,8 +7,8 @@
<link rel="stylesheet" href="testing/testing.css"> <link rel="stylesheet" href="testing/testing.css">
<script src="testing/qunit-1.23.0.js"></script> <script src="testing/qunit-1.23.0.js"></script>
<script src="docs/js/jquery-3.0.0-rc1.js"></script> <script src="docs/js/jquery-3.0.0.min.js"></script>
<script src="docs/js/jquery-migrate-3.0.0-rc1.min.js"></script> <script src="docs/js/jquery-migrate-3.0.0.min.js"></script>
<script src="js/jquery.tablesorter.js"></script> <script src="js/jquery.tablesorter.js"></script>
<script src="js/widgets/widget-filter.js"></script> <script src="js/widgets/widget-filter.js"></script>

View File

@ -184,8 +184,9 @@ jQuery(function($){
var processFilters = this.ts.filter.processFilters, var processFilters = this.ts.filter.processFilters,
filters = [], filters = [],
results = []; results = [];
filters[1] = 5, filters[2] = 'test', filters[3] = true, filters[4] = null; filters[1] = 5; filters[2] = 'test'; filters[3] = true; filters[4] = null;
results[1] = '5', results[2] = 'test', results[3] = 'true', results[4] = null; results[1] = '5'; results[2] = 'test'; results[3] = 'true';
// filters[4] will now become undefined within results - see #1237
assert.deepEqual( processFilters( filters, true ), results ); assert.deepEqual( processFilters( filters, true ), results );
assert.deepEqual( processFilters( filters, false ), results ); assert.deepEqual( processFilters( filters, false ), results );