datatables.net 2.3.1 → 2.3.3

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.
package/js/dataTables.mjs CHANGED
@@ -1,4 +1,4 @@
1
- /*! DataTables 2.3.1
1
+ /*! DataTables 2.3.3
2
2
  * © SpryMedia Ltd - datatables.net/license
3
3
  */
4
4
 
@@ -77,7 +77,7 @@ var DataTable = function ( selector, options )
77
77
  _fnCamelToHungarian( defaults.column, defaults.column, true );
78
78
 
79
79
  /* Setting up the initialisation object */
80
- _fnCamelToHungarian( defaults, $.extend( oInit, $this.data() ), true );
80
+ _fnCamelToHungarian( defaults, $.extend( oInit, _fnEscapeObject($this.data()) ), true );
81
81
 
82
82
 
83
83
 
@@ -507,6 +507,11 @@ DataTable.ext = _ext = {
507
507
  */
508
508
  errMode: "alert",
509
509
 
510
+ /** HTML entity escaping */
511
+ escape: {
512
+ /** When reading data-* attributes for initialisation options */
513
+ attributes: false
514
+ },
510
515
 
511
516
  /**
512
517
  * Legacy so v1 plug-ins don't throw js errors on load
@@ -691,7 +696,7 @@ DataTable.ext = _ext = {
691
696
  *
692
697
  * The extension options for ordering of data available here is complimentary
693
698
  * to the default type based ordering that DataTables typically uses. It
694
- * allows much greater control over the the data that is being used to
699
+ * allows much greater control over the data that is being used to
695
700
  * order a column, but is necessarily therefore more complex.
696
701
  *
697
702
  * This type of ordering is useful if you want to do ordering based on data
@@ -850,7 +855,7 @@ DataTable.ext = _ext = {
850
855
  * `{type}-asc` and `{type}-desc` together. It is generally recommended
851
856
  * that only `{type}-pre` is used, as this provides the optimal
852
857
  * implementation in terms of speed, although the others are provided
853
- * for compatibility with existing Javascript sort functions.
858
+ * for compatibility with existing JavaScript sort functions.
854
859
  *
855
860
  * `{type}-pre`: Functions defined take a single parameter:
856
861
  *
@@ -860,7 +865,7 @@ DataTable.ext = _ext = {
860
865
  *
861
866
  * * `{*}` Data to be sorted upon
862
867
  *
863
- * `{type}-asc` and `{type}-desc`: Functions are typical Javascript sort
868
+ * `{type}-asc` and `{type}-desc`: Functions are typical JavaScript sort
864
869
  * functions, taking two parameters:
865
870
  *
866
871
  * 1. `{*}` Data to compare to the second parameter
@@ -1084,7 +1089,7 @@ var _intVal = function ( s ) {
1084
1089
  };
1085
1090
 
1086
1091
  // Convert from a formatted number with characters other than `.` as the
1087
- // decimal place, to a Javascript number
1092
+ // decimal place, to a JavaScript number
1088
1093
  var _numToDecimal = function ( num, decimalPoint ) {
1089
1094
  // Cache created regular expressions for speed as this function is called often
1090
1095
  if ( ! _re_dic[ decimalPoint ] ) {
@@ -1150,19 +1155,19 @@ var _htmlNumeric = function ( d, decimalPoint, formatted, allowEmpty ) {
1150
1155
 
1151
1156
  var _pluck = function ( a, prop, prop2 ) {
1152
1157
  var out = [];
1153
- var i=0, ien=a.length;
1158
+ var i=0, iLen=a.length;
1154
1159
 
1155
1160
  // Could have the test in the loop for slightly smaller code, but speed
1156
1161
  // is essential here
1157
1162
  if ( prop2 !== undefined ) {
1158
- for ( ; i<ien ; i++ ) {
1163
+ for ( ; i<iLen ; i++ ) {
1159
1164
  if ( a[i] && a[i][ prop ] ) {
1160
1165
  out.push( a[i][ prop ][ prop2 ] );
1161
1166
  }
1162
1167
  }
1163
1168
  }
1164
1169
  else {
1165
- for ( ; i<ien ; i++ ) {
1170
+ for ( ; i<iLen ; i++ ) {
1166
1171
  if ( a[i] ) {
1167
1172
  out.push( a[i][ prop ] );
1168
1173
  }
@@ -1178,19 +1183,19 @@ var _pluck = function ( a, prop, prop2 ) {
1178
1183
  var _pluck_order = function ( a, order, prop, prop2 )
1179
1184
  {
1180
1185
  var out = [];
1181
- var i=0, ien=order.length;
1186
+ var i=0, iLen=order.length;
1182
1187
 
1183
1188
  // Could have the test in the loop for slightly smaller code, but speed
1184
1189
  // is essential here
1185
1190
  if ( prop2 !== undefined ) {
1186
- for ( ; i<ien ; i++ ) {
1191
+ for ( ; i<iLen ; i++ ) {
1187
1192
  if ( a[ order[i] ] && a[ order[i] ][ prop ] ) {
1188
1193
  out.push( a[ order[i] ][ prop ][ prop2 ] );
1189
1194
  }
1190
1195
  }
1191
1196
  }
1192
1197
  else {
1193
- for ( ; i<ien ; i++ ) {
1198
+ for ( ; i<iLen ; i++ ) {
1194
1199
  if ( a[ order[i] ] ) {
1195
1200
  out.push( a[ order[i] ][ prop ] );
1196
1201
  }
@@ -1227,7 +1232,7 @@ var _removeEmpty = function ( a )
1227
1232
  {
1228
1233
  var out = [];
1229
1234
 
1230
- for ( var i=0, ien=a.length ; i<ien ; i++ ) {
1235
+ for ( var i=0, iLen=a.length ; i<iLen ; i++ ) {
1231
1236
  if ( a[i] ) { // careful - will remove all falsy values!
1232
1237
  out.push( a[i] );
1233
1238
  }
@@ -1313,7 +1318,7 @@ var _areAllUnique = function ( src ) {
1313
1318
  var sorted = src.slice().sort();
1314
1319
  var last = sorted[0];
1315
1320
 
1316
- for ( var i=1, ien=sorted.length ; i<ien ; i++ ) {
1321
+ for ( var i=1, iLen=sorted.length ; i<iLen ; i++ ) {
1317
1322
  if ( sorted[i] === last ) {
1318
1323
  return false;
1319
1324
  }
@@ -1349,10 +1354,10 @@ var _unique = function ( src )
1349
1354
  var
1350
1355
  out = [],
1351
1356
  val,
1352
- i, ien=src.length,
1357
+ i, iLen=src.length,
1353
1358
  j, k=0;
1354
1359
 
1355
- again: for ( i=0 ; i<ien ; i++ ) {
1360
+ again: for ( i=0 ; i<iLen ; i++ ) {
1356
1361
  val = src[i];
1357
1362
 
1358
1363
  for ( j=0 ; j<k ; j++ ) {
@@ -1886,7 +1891,7 @@ function _fnCompatOpts ( init )
1886
1891
  var searchCols = init.aoSearchCols;
1887
1892
 
1888
1893
  if ( searchCols ) {
1889
- for ( var i=0, ien=searchCols.length ; i<ien ; i++ ) {
1894
+ for ( var i=0, iLen=searchCols.length ; i<iLen ; i++ ) {
1890
1895
  if ( searchCols[i] ) {
1891
1896
  _fnCamelToHungarian( DataTable.models.oSearch, searchCols[i] );
1892
1897
  }
@@ -2039,7 +2044,7 @@ function _fnColumnOptions( oSettings, iCol, oOptions )
2039
2044
  oCol._sManualType = oOptions.sType;
2040
2045
  }
2041
2046
 
2042
- // `class` is a reserved word in Javascript, so we need to provide
2047
+ // `class` is a reserved word in JavaScript, so we need to provide
2043
2048
  // the ability to use a valid name for the camel case input
2044
2049
  if ( oOptions.className && ! oOptions.sClass )
2045
2050
  {
@@ -2196,14 +2201,14 @@ function _fnColumnIndexToVisible( oSettings, iMatch )
2196
2201
  * @returns {int} i the number of visible columns
2197
2202
  * @memberof DataTable#oApi
2198
2203
  */
2199
- function _fnVisbleColumns( settings )
2204
+ function _fnVisibleColumns( settings )
2200
2205
  {
2201
2206
  var layout = settings.aoHeader;
2202
2207
  var columns = settings.aoColumns;
2203
2208
  var vis = 0;
2204
2209
 
2205
2210
  if ( layout.length ) {
2206
- for ( var i=0, ien=layout[0].length ; i<ien ; i++ ) {
2211
+ for ( var i=0, iLen=layout[0].length ; i<iLen ; i++ ) {
2207
2212
  if ( columns[i].bVisible && $(layout[0][i].cell).css('display') !== 'none' ) {
2208
2213
  vis++;
2209
2214
  }
@@ -2238,7 +2243,7 @@ function _fnGetColumns( oSettings, sParam )
2238
2243
  /**
2239
2244
  * Allow the result from a type detection function to be `true` while
2240
2245
  * translating that into a string. Old type detection functions will
2241
- * return the type name if it passes. An obect store would be better,
2246
+ * return the type name if it passes. An object store would be better,
2242
2247
  * but not backwards compatible.
2243
2248
  *
2244
2249
  * @param {*} typeDetect Object or function for type detection
@@ -2261,11 +2266,11 @@ function _fnColumnTypes ( settings )
2261
2266
  var columns = settings.aoColumns;
2262
2267
  var data = settings.aoData;
2263
2268
  var types = DataTable.ext.type.detect;
2264
- var i, ien, j, jen, k, ken;
2269
+ var i, iLen, j, jen, k, ken;
2265
2270
  var col, detectedType, cache;
2266
2271
 
2267
2272
  // For each column, spin over the data type detection functions, seeing if one matches
2268
- for ( i=0, ien=columns.length ; i<ien ; i++ ) {
2273
+ for ( i=0, iLen=columns.length ; i<iLen ; i++ ) {
2269
2274
  col = columns[i];
2270
2275
  cache = [];
2271
2276
 
@@ -2535,7 +2540,7 @@ function _fnColumnsSumWidth( settings, targets, original, incVisible ) {
2535
2540
  var unit;
2536
2541
  var columns = settings.aoColumns;
2537
2542
 
2538
- for ( var i=0, ien=targets.length ; i<ien ; i++ ) {
2543
+ for ( var i=0, iLen=targets.length ; i<iLen ; i++ ) {
2539
2544
  var column = columns[ targets[i] ];
2540
2545
  var definedWidth = original ?
2541
2546
  column.sWidthOrig :
@@ -2581,7 +2586,7 @@ function _fnColumnsFromHeader( cell )
2581
2586
  }
2582
2587
  /**
2583
2588
  * Add a data array to the table, creating DOM node etc. This is the parallel to
2584
- * _fnGatherData, but for adding rows from a Javascript source, rather than a
2589
+ * _fnGatherData, but for adding rows from a JavaScript source, rather than a
2585
2590
  * DOM source.
2586
2591
  * @param {object} settings dataTables settings object
2587
2592
  * @param {array} data data array to be added
@@ -2721,10 +2726,10 @@ function _fnGetCellData( settings, rowIdx, colIdx, type )
2721
2726
  }
2722
2727
 
2723
2728
  if ( type === 'filter' ) {
2724
- var fomatters = DataTable.ext.type.search;
2729
+ var formatters = DataTable.ext.type.search;
2725
2730
 
2726
- if ( fomatters[ col.sType ] ) {
2727
- cellData = fomatters[ col.sType ]( cellData );
2731
+ if ( formatters[ col.sType ] ) {
2732
+ cellData = formatters[ col.sType ]( cellData );
2728
2733
  }
2729
2734
  }
2730
2735
 
@@ -2854,7 +2859,7 @@ function _fnClearTable( settings )
2854
2859
  function _fnInvalidate( settings, rowIdx, src, colIdx )
2855
2860
  {
2856
2861
  var row = settings.aoData[ rowIdx ];
2857
- var i, ien;
2862
+ var i, iLen;
2858
2863
 
2859
2864
  // Remove the cached data for the row
2860
2865
  row._aSortData = null;
@@ -2879,7 +2884,7 @@ function _fnInvalidate( settings, rowIdx, src, colIdx )
2879
2884
  _fnWriteCell(cells[colIdx], display[colIdx]);
2880
2885
  }
2881
2886
  else {
2882
- for ( i=0, ien=cells.length ; i<ien ; i++ ) {
2887
+ for ( i=0, iLen=cells.length ; i<iLen ; i++ ) {
2883
2888
  _fnWriteCell(cells[i], display[i]);
2884
2889
  }
2885
2890
  }
@@ -2897,7 +2902,7 @@ function _fnInvalidate( settings, rowIdx, src, colIdx )
2897
2902
  cols[ colIdx ].maxLenString = null;
2898
2903
  }
2899
2904
  else {
2900
- for ( i=0, ien=cols.length ; i<ien ; i++ ) {
2905
+ for ( i=0, iLen=cols.length ; i<iLen ; i++ ) {
2901
2906
  cols[i].sType = null;
2902
2907
  cols[i].maxLenString = null;
2903
2908
  }
@@ -3196,7 +3201,7 @@ function _fnBuildHead( settings, side )
3196
3201
  {
3197
3202
  var classes = settings.oClasses;
3198
3203
  var columns = settings.aoColumns;
3199
- var i, ien, row;
3204
+ var i, iLen, row;
3200
3205
  var target = side === 'header'
3201
3206
  ? settings.nTHead
3202
3207
  : settings.nTFoot;
@@ -3224,7 +3229,7 @@ function _fnBuildHead( settings, side )
3224
3229
  cellCount += this.colSpan;
3225
3230
  });
3226
3231
 
3227
- for ( i=cellCount, ien=columns.length ; i<ien ; i++ ) {
3232
+ for ( i=cellCount, iLen=columns.length ; i<iLen ; i++ ) {
3228
3233
  $('<th/>')
3229
3234
  .html( columns[i][titleProp] || '' )
3230
3235
  .appendTo( row );
@@ -3568,7 +3573,7 @@ function _emptyRow ( settings ) {
3568
3573
 
3569
3574
  return $( '<tr/>' )
3570
3575
  .append( $('<td />', {
3571
- 'colSpan': _fnVisbleColumns( settings ),
3576
+ 'colSpan': _fnVisibleColumns( settings ),
3572
3577
  'class': settings.oClasses.empty.row
3573
3578
  } ).html( zero ) )[0];
3574
3579
  }
@@ -3752,7 +3757,7 @@ function _layoutResolve( settings, row ) {
3752
3757
 
3753
3758
  var line = row[ item ].contents;
3754
3759
 
3755
- for ( var i=0, ien=line.length ; i<ien ; i++ ) {
3760
+ for ( var i=0, iLen=line.length ; i<iLen ; i++ ) {
3756
3761
  if ( ! line[i] ) {
3757
3762
  continue;
3758
3763
  }
@@ -3916,7 +3921,7 @@ function _fnLayoutDom( settings, dom, insert )
3916
3921
  /**
3917
3922
  * Use the DOM source to create up an array of header cells. The idea here is to
3918
3923
  * create a layout grid (array) of rows x columns, which contains a reference
3919
- * to the cell that that point in the grid (regardless of col/rowspan), such that
3924
+ * to the cell at that point in the grid (regardless of col/rowspan), such that
3920
3925
  * any column / row could be removed and the new grid constructed
3921
3926
  * @param {node} thead The header/footer element for the table
3922
3927
  * @returns {array} Calculated layout array
@@ -3978,7 +3983,7 @@ function _fnDetectHeader ( settings, thead, write )
3978
3983
  if ( write ) {
3979
3984
  if (unique) {
3980
3985
  // Allow column options to be set from HTML attributes
3981
- _fnColumnOptions( settings, shifted, jqCell.data() );
3986
+ _fnColumnOptions( settings, shifted, _fnEscapeObject(jqCell.data()) );
3982
3987
 
3983
3988
  // Get the width for the column. This can be defined from the
3984
3989
  // width attribute, style attribute or `columns.width` option
@@ -4161,7 +4166,7 @@ function _fnBuildAjax( oSettings, data, fn )
4161
4166
 
4162
4167
  var newData = typeof ajaxData === 'function' ?
4163
4168
  ajaxData( data, oSettings ) : // fn can manipulate data or return
4164
- ajaxData; // an object object or array to merge
4169
+ ajaxData; // an object or array to merge
4165
4170
 
4166
4171
  // If the function returned something, use that alone
4167
4172
  data = typeof ajaxData === 'function' && newData ?
@@ -4224,7 +4229,7 @@ function _fnBuildAjax( oSettings, data, fn )
4224
4229
  // to the object for the callback.
4225
4230
  var empty = {};
4226
4231
 
4227
- DataTable.util.set(ajax.dataSrc)(empty, []);
4232
+ _fnAjaxDataSrc(oSettings, empty, []);
4228
4233
  callback(empty);
4229
4234
  }
4230
4235
  else {
@@ -4360,7 +4365,7 @@ function _fnAjaxUpdateDraw ( settings, json )
4360
4365
  settings._iRecordsTotal = parseInt(recordsTotal, 10);
4361
4366
  settings._iRecordsDisplay = parseInt(recordsFiltered, 10);
4362
4367
 
4363
- for ( var i=0, ien=data.length ; i<ien ; i++ ) {
4368
+ for ( var i=0, iLen=data.length ; i<iLen ; i++ ) {
4364
4369
  _fnAddData( settings, data[i] );
4365
4370
  }
4366
4371
  settings.aiDisplay = settings.aiDisplayMaster.slice();
@@ -4519,7 +4524,7 @@ function _fnFilterCustom( settings )
4519
4524
  var displayRows = settings.aiDisplay;
4520
4525
  var row, rowIdx;
4521
4526
 
4522
- for ( var i=0, ien=filters.length ; i<ien ; i++ ) {
4527
+ for ( var i=0, iLen=filters.length ; i<iLen ; i++ ) {
4523
4528
  var rows = [];
4524
4529
 
4525
4530
  // Loop over each row and see if it should be included
@@ -4587,7 +4592,7 @@ function _fnFilter( searchRows, settings, input, options, column )
4587
4592
  * @param {string} sSearch string to search for
4588
4593
  * @param {bool} bRegex treat as a regular expression or not
4589
4594
  * @param {bool} bSmart perform smart filtering or not
4590
- * @param {bool} bCaseInsensitive Do case insensitive matching or not
4595
+ * @param {bool} bCaseInsensitive Do case-insensitive matching or not
4591
4596
  * @returns {RegExp} constructed object
4592
4597
  * @memberof DataTable#oApi
4593
4598
  */
@@ -5330,7 +5335,7 @@ function _fnScrollDraw ( settings )
5330
5335
  }
5331
5336
 
5332
5337
  // 4. Clean up
5333
- // Figure out if there are scrollbar present - if so then we need a the header and footer to
5338
+ // Figure out if there are scrollbar present - if so then we need the header and footer to
5334
5339
  // provide a bit more space to allow "overflow" scrolling (i.e. past the scrollbar)
5335
5340
  var isScrolling = Math.floor(table.height()) > divBodyEl.clientHeight || divBody.css('overflow-y') == "scroll";
5336
5341
  var paddingSide = 'padding' + (browser.bScrollbarLeft ? 'Left' : 'Right' );
@@ -5428,7 +5433,7 @@ function _fnCalculateColumnWidths ( settings )
5428
5433
  .removeAttr( 'id' );
5429
5434
 
5430
5435
  // Clean up the table body
5431
- tmpTable.append('<tbody>')
5436
+ tmpTable.append('<tbody/>')
5432
5437
  var tr = $('<tr/>').appendTo( tmpTable.find('tbody') );
5433
5438
 
5434
5439
  // Clone the table header and footer - we can't use the header / footer
@@ -5637,7 +5642,7 @@ function _fnGetMaxLenString( settings, colIdx )
5637
5642
  if (! column.maxLenString) {
5638
5643
  var s, max='', maxLen = -1;
5639
5644
 
5640
- for ( var i=0, ien=settings.aiDisplayMaster.length ; i<ien ; i++ ) {
5645
+ for ( var i=0, iLen=settings.aiDisplayMaster.length ; i<iLen ; i++ ) {
5641
5646
  var rowIdx = settings.aiDisplayMaster[i];
5642
5647
  var data = _fnGetRowDisplay(settings, rowIdx)[colIdx];
5643
5648
 
@@ -5752,12 +5757,14 @@ function _fnSortAttachListener(settings, node, selector, column, callback) {
5752
5757
  var run = false;
5753
5758
  var columns = column === undefined
5754
5759
  ? _fnColumnsFromHeader( e.target )
5755
- : Array.isArray(column)
5756
- ? column
5757
- : [column];
5760
+ : typeof column === 'function'
5761
+ ? column()
5762
+ : Array.isArray(column)
5763
+ ? column
5764
+ : [column];
5758
5765
 
5759
5766
  if ( columns.length ) {
5760
- for ( var i=0, ien=columns.length ; i<ien ; i++ ) {
5767
+ for ( var i=0, iLen=columns.length ; i<iLen ; i++ ) {
5761
5768
  var ret = _fnSortAdd( settings, columns[i], i, e.shiftKey );
5762
5769
 
5763
5770
  if (ret !== false) {
@@ -5806,7 +5813,7 @@ function _fnSortDisplay(settings, display) {
5806
5813
  masterMap[master[i]] = i;
5807
5814
  }
5808
5815
 
5809
- // And then cache what would be the indexOf fom the display
5816
+ // And then cache what would be the indexOf from the display
5810
5817
  for (i=0 ; i<display.length ; i++) {
5811
5818
  map[display[i]] = masterMap[display[i]];
5812
5819
  }
@@ -5932,7 +5939,7 @@ function _fnSortFlatten ( settings )
5932
5939
  function _fnSort ( oSettings, col, dir )
5933
5940
  {
5934
5941
  var
5935
- i, ien, iLen,
5942
+ i, iLen,
5936
5943
  aiOrig = [],
5937
5944
  extSort = DataTable.ext.type.order,
5938
5945
  aoData = oSettings.aoData,
@@ -5963,7 +5970,7 @@ function _fnSort ( oSettings, col, dir )
5963
5970
  aSort = _fnSortFlatten( oSettings );
5964
5971
  }
5965
5972
 
5966
- for ( i=0, ien=aSort.length ; i<ien ; i++ ) {
5973
+ for ( i=0, iLen=aSort.length ; i<iLen ; i++ ) {
5967
5974
  sortCol = aSort[i];
5968
5975
 
5969
5976
  // Load the data needed for the sort, for each cell
@@ -5986,7 +5993,7 @@ function _fnSort ( oSettings, col, dir )
5986
5993
 
5987
5994
  /* Do the sort - here we want multi-column sorting based on a given data source (column)
5988
5995
  * and sorting function (from oSort) in a certain direction. It's reasonably complex to
5989
- * follow on it's own, but this is what we want (example two column sorting):
5996
+ * follow on its own, but this is what we want (example two column sorting):
5990
5997
  * fnLocalSorting = function(a,b){
5991
5998
  * var test;
5992
5999
  * test = oSort['string-asc']('data11', 'data12');
@@ -6110,7 +6117,7 @@ function _fnSortAdd ( settings, colIdx, addIndex, shift )
6110
6117
  nextSortIdx = 0; // can't remove sorting completely
6111
6118
  }
6112
6119
 
6113
- if ( nextSortIdx === null ) {
6120
+ if ( nextSortIdx === null || asSorting[ nextSortIdx ] === '' ) {
6114
6121
  sorting.splice( sortIdx, 1 );
6115
6122
  }
6116
6123
  else {
@@ -6160,11 +6167,11 @@ function _fnSortingClasses( settings )
6160
6167
  var sortClass = settings.oClasses.order.position;
6161
6168
  var sort = _fnSortFlatten( settings );
6162
6169
  var features = settings.oFeatures;
6163
- var i, ien, colIdx;
6170
+ var i, iLen, colIdx;
6164
6171
 
6165
6172
  if ( features.bSort && features.bSortClasses ) {
6166
6173
  // Remove old sorting classes
6167
- for ( i=0, ien=oldSort.length ; i<ien ; i++ ) {
6174
+ for ( i=0, iLen=oldSort.length ; i<iLen ; i++ ) {
6168
6175
  colIdx = oldSort[i].src;
6169
6176
 
6170
6177
  // Remove column sorting
@@ -6173,7 +6180,7 @@ function _fnSortingClasses( settings )
6173
6180
  }
6174
6181
 
6175
6182
  // Add new column sorting
6176
- for ( i=0, ien=sort.length ; i<ien ; i++ ) {
6183
+ for ( i=0, iLen=sort.length ; i<iLen ; i++ ) {
6177
6184
  colIdx = sort[i].src;
6178
6185
 
6179
6186
  $( _pluck( settings.aoData, 'anCells', colIdx ) )
@@ -6307,7 +6314,7 @@ function _fnLoadState ( settings, init, callback )
6307
6314
  }
6308
6315
 
6309
6316
  function _fnImplementState ( settings, s, callback) {
6310
- var i, ien;
6317
+ var i, iLen;
6311
6318
  var columns = settings.aoColumns;
6312
6319
  var currentNames = _pluck(settings.aoColumns, 'sName');
6313
6320
 
@@ -6436,7 +6443,7 @@ function _fnImplementState ( settings, s, callback) {
6436
6443
 
6437
6444
  // If the number of columns to restore is different from current, then all bets are off.
6438
6445
  if (set.length === columns.length) {
6439
- for ( i=0, ien=set.length ; i<ien ; i++ ) {
6446
+ for ( i=0, iLen=set.length ; i<iLen ; i++ ) {
6440
6447
  var col = set[i];
6441
6448
 
6442
6449
  // Visibility
@@ -6590,7 +6597,7 @@ function _fnExtend( out, extender, breakRefs )
6590
6597
 
6591
6598
 
6592
6599
  /**
6593
- * Bind an event handers to allow a click or return key to activate the callback.
6600
+ * Bind an event handler to allow a click or return key to activate the callback.
6594
6601
  * This is good for accessibility since a return on the keyboard will have the
6595
6602
  * same effect as a click, if the element has focus.
6596
6603
  * @param {element} n Element to bind the action to
@@ -6779,7 +6786,7 @@ function _fnMacros ( settings, str, entries )
6779
6786
  }
6780
6787
 
6781
6788
  /**
6782
- * Add elements to an array as quickly as possible, but stack stafe.
6789
+ * Add elements to an array as quickly as possible, but stack safe.
6783
6790
  *
6784
6791
  * @param {*} arr Array to add the data to
6785
6792
  * @param {*} data Data array that is to be added
@@ -6819,6 +6826,19 @@ function _fnListener(that, name, src) {
6819
6826
  }
6820
6827
  }
6821
6828
 
6829
+ /**
6830
+ * Escape HTML entities in strings, in an object
6831
+ */
6832
+ function _fnEscapeObject(obj) {
6833
+ if (DataTable.ext.escape.attributes) {
6834
+ $.each(obj, function (key, val) {
6835
+ obj[key] = _escapeHtml(val);
6836
+ })
6837
+ }
6838
+
6839
+ return obj;
6840
+ }
6841
+
6822
6842
 
6823
6843
 
6824
6844
  /**
@@ -7042,7 +7062,7 @@ $.extend( _Api.prototype, {
7042
7062
 
7043
7063
  each: function ( fn )
7044
7064
  {
7045
- for ( var i=0, ien=this.length ; i<ien; i++ ) {
7065
+ for ( var i=0, iLen=this.length ; i<iLen; i++ ) {
7046
7066
  fn.call( this, this[i], i, this );
7047
7067
  }
7048
7068
 
@@ -7088,7 +7108,7 @@ $.extend( _Api.prototype, {
7088
7108
  iterator: function ( flatten, type, fn, alwaysNew ) {
7089
7109
  var
7090
7110
  a = [], ret,
7091
- i, ien, j, jen,
7111
+ i, iLen, j, jen,
7092
7112
  context = this.context,
7093
7113
  rows, items, item,
7094
7114
  selector = this.selector;
@@ -7101,7 +7121,7 @@ $.extend( _Api.prototype, {
7101
7121
  flatten = false;
7102
7122
  }
7103
7123
 
7104
- for ( i=0, ien=context.length ; i<ien ; i++ ) {
7124
+ for ( i=0, iLen=context.length ; i<iLen ; i++ ) {
7105
7125
  var apiInst = new _Api( context[i] );
7106
7126
 
7107
7127
  if ( type === 'table' ) {
@@ -7223,18 +7243,18 @@ $.extend( _Api.prototype, {
7223
7243
  } );
7224
7244
 
7225
7245
 
7226
- function _api_scope( scope, fn, struc ) {
7246
+ function _api_scope( scope, fn, struct ) {
7227
7247
  return function () {
7228
7248
  var ret = fn.apply( scope || this, arguments );
7229
7249
 
7230
7250
  // Method extension
7231
- _Api.extend( ret, ret, struc.methodExt );
7251
+ _Api.extend( ret, ret, struct.methodExt );
7232
7252
  return ret;
7233
7253
  };
7234
7254
  }
7235
7255
 
7236
7256
  function _api_find( src, name ) {
7237
- for ( var i=0, ien=src.length ; i<ien ; i++ ) {
7257
+ for ( var i=0, iLen=src.length ; i<iLen ; i++ ) {
7238
7258
  if ( src[i].name === name ) {
7239
7259
  return src[i];
7240
7260
  }
@@ -7252,10 +7272,10 @@ _Api.extend = function ( scope, obj, ext )
7252
7272
  }
7253
7273
 
7254
7274
  var
7255
- i, ien,
7275
+ i, iLen,
7256
7276
  struct;
7257
7277
 
7258
- for ( i=0, ien=ext.length ; i<ien ; i++ ) {
7278
+ for ( i=0, iLen=ext.length ; i<iLen ; i++ ) {
7259
7279
  struct = ext[i];
7260
7280
 
7261
7281
  if (struct.name === '__proto__') {
@@ -7310,12 +7330,12 @@ _Api.register = _api_register = function ( name, val )
7310
7330
  }
7311
7331
 
7312
7332
  var
7313
- i, ien,
7333
+ i, iLen,
7314
7334
  heir = name.split('.'),
7315
7335
  struct = __apiStruct,
7316
7336
  key, method;
7317
7337
 
7318
- for ( i=0, ien=heir.length ; i<ien ; i++ ) {
7338
+ for ( i=0, iLen=heir.length ; i<iLen ; i++ ) {
7319
7339
  method = heir[i].indexOf('()') !== -1;
7320
7340
  key = method ?
7321
7341
  heir[i].replace('()', '') :
@@ -7333,7 +7353,7 @@ _Api.register = _api_register = function ( name, val )
7333
7353
  struct.push( src );
7334
7354
  }
7335
7355
 
7336
- if ( i === ien-1 ) {
7356
+ if ( i === iLen-1 ) {
7337
7357
  src.val = val;
7338
7358
  src.type = typeof val === 'function' ?
7339
7359
  'function' :
@@ -7675,7 +7695,7 @@ _api_register( 'page.info()', function () {
7675
7695
  */
7676
7696
  _api_register( 'page.len()', function ( len ) {
7677
7697
  // Note that we can't call this function 'length()' because `length`
7678
- // is a Javascript property of functions which defines how many arguments
7698
+ // is a JavaScript property of functions which defines how many arguments
7679
7699
  // the function expects.
7680
7700
  if ( len === undefined ) {
7681
7701
  return this.context.length !== 0 ?
@@ -7718,7 +7738,7 @@ var __reload = function ( settings, holdPosition, callback ) {
7718
7738
  _fnClearTable( settings );
7719
7739
 
7720
7740
  var data = _fnAjaxDataSrc( settings, json );
7721
- for ( var i=0, ien=data.length ; i<ien ; i++ ) {
7741
+ for ( var i=0, iLen=data.length ; i<iLen ; i++ ) {
7722
7742
  _fnAddData( settings, data[i] );
7723
7743
  }
7724
7744
 
@@ -7841,7 +7861,7 @@ var _selector_run = function ( type, selector, selectFn, settings, opts )
7841
7861
  {
7842
7862
  var
7843
7863
  out = [], res,
7844
- i, ien,
7864
+ i, iLen,
7845
7865
  selectorType = typeof selector;
7846
7866
 
7847
7867
  // Can't just check for isArray here, as an API or jQuery instance might be
@@ -7850,7 +7870,7 @@ var _selector_run = function ( type, selector, selectFn, settings, opts )
7850
7870
  selector = [ selector ];
7851
7871
  }
7852
7872
 
7853
- for ( i=0, ien=selector.length ; i<ien ; i++ ) {
7873
+ for ( i=0, iLen=selector.length ; i<iLen ; i++ ) {
7854
7874
  res = selectFn( typeof selector[i] === 'string' ? selector[i].trim() : selector[i] );
7855
7875
 
7856
7876
  // Remove empty items
@@ -7866,7 +7886,7 @@ var _selector_run = function ( type, selector, selectFn, settings, opts )
7866
7886
  // selector extensions
7867
7887
  var ext = _ext.selector[ type ];
7868
7888
  if ( ext.length ) {
7869
- for ( i=0, ien=ext.length ; i<ien ; i++ ) {
7889
+ for ( i=0, iLen=ext.length ; i<iLen ; i++ ) {
7870
7890
  out = ext[i]( settings, opts, out );
7871
7891
  }
7872
7892
  }
@@ -7921,7 +7941,7 @@ var _selector_first = function ( old )
7921
7941
  var _selector_row_indexes = function ( settings, opts )
7922
7942
  {
7923
7943
  var
7924
- i, ien, tmp, a=[],
7944
+ i, iLen, tmp, a=[],
7925
7945
  displayFiltered = settings.aiDisplay,
7926
7946
  displayMaster = settings.aiDisplayMaster;
7927
7947
 
@@ -7944,7 +7964,7 @@ var _selector_row_indexes = function ( settings, opts )
7944
7964
  // Current page implies that order=current and filter=applied, since it is
7945
7965
  // fairly senseless otherwise, regardless of what order and search actually
7946
7966
  // are
7947
- for ( i=settings._iDisplayStart, ien=settings.fnDisplayEnd() ; i<ien ; i++ ) {
7967
+ for ( i=settings._iDisplayStart, iLen=settings.fnDisplayEnd() ; i<iLen ; i++ ) {
7948
7968
  a.push( displayFiltered[i] );
7949
7969
  }
7950
7970
  }
@@ -7959,7 +7979,7 @@ var _selector_row_indexes = function ( settings, opts )
7959
7979
  // O(n+m) solution by creating a hash map
7960
7980
  var displayFilteredMap = {};
7961
7981
 
7962
- for ( i=0, ien=displayFiltered.length ; i<ien ; i++ ) {
7982
+ for ( i=0, iLen=displayFiltered.length ; i<iLen ; i++ ) {
7963
7983
  displayFilteredMap[displayFiltered[i]] = null;
7964
7984
  }
7965
7985
 
@@ -7971,7 +7991,7 @@ var _selector_row_indexes = function ( settings, opts )
7971
7991
  }
7972
7992
  }
7973
7993
  else if ( order == 'index' || order == 'original' ) {
7974
- for ( i=0, ien=settings.aoData.length ; i<ien ; i++ ) {
7994
+ for ( i=0, iLen=settings.aoData.length ; i<iLen ; i++ ) {
7975
7995
  if (! settings.aoData[i]) {
7976
7996
  continue;
7977
7997
  }
@@ -8188,7 +8208,7 @@ _api_registerPlural( 'rows().ids()', 'row().id()', function ( hash ) {
8188
8208
  var context = this.context;
8189
8209
 
8190
8210
  // `iterator` will drop undefined values, but in this case we want them
8191
- for ( var i=0, ien=context.length ; i<ien ; i++ ) {
8211
+ for ( var i=0, iLen=context.length ; i<iLen ; i++ ) {
8192
8212
  for ( var j=0, jen=this[i].length ; j<jen ; j++ ) {
8193
8213
  var id = context[i].rowIdFn( context[i].aoData[ this[i][j] ]._aData );
8194
8214
  a.push( (hash === true ? '#' : '' )+ id );
@@ -8232,10 +8252,10 @@ _api_registerPlural( 'rows().remove()', 'row().remove()', function () {
8232
8252
 
8233
8253
  _api_register( 'rows.add()', function ( rows ) {
8234
8254
  var newRows = this.iterator( 'table', function ( settings ) {
8235
- var row, i, ien;
8255
+ var row, i, iLen;
8236
8256
  var out = [];
8237
8257
 
8238
- for ( i=0, ien=rows.length ; i<ien ; i++ ) {
8258
+ for ( i=0, iLen=rows.length ; i<iLen ; i++ ) {
8239
8259
  row = rows[i];
8240
8260
 
8241
8261
  if ( row.nodeName && row.nodeName.toUpperCase() === 'TR' ) {
@@ -8382,7 +8402,7 @@ var __details_add = function ( ctx, row, data, klass )
8382
8402
  var addRow = function ( r, k ) {
8383
8403
  // Recursion to allow for arrays of jQuery objects
8384
8404
  if ( Array.isArray( r ) || r instanceof $ ) {
8385
- for ( var i=0, ien=r.length ; i<ien ; i++ ) {
8405
+ for ( var i=0, iLen=r.length ; i<iLen ; i++ ) {
8386
8406
  addRow( r[i], k );
8387
8407
  }
8388
8408
  return;
@@ -8402,7 +8422,7 @@ var __details_add = function ( ctx, row, data, klass )
8402
8422
 
8403
8423
  $('td', created)
8404
8424
  .addClass( k )
8405
- .html( r )[0].colSpan = _fnVisbleColumns( ctx );
8425
+ .html( r )[0].colSpan = _fnVisibleColumns( ctx );
8406
8426
 
8407
8427
  rows.push( created[0] );
8408
8428
  }
@@ -8440,7 +8460,7 @@ var __details_remove = function ( api, idx )
8440
8460
  var row = ctx[0].aoData[ idx !== undefined ? idx : api[0] ];
8441
8461
 
8442
8462
  if ( row && row._details ) {
8443
- row._details.remove();
8463
+ row._details.detach();
8444
8464
 
8445
8465
  row._detailsShow = undefined;
8446
8466
  row._details = undefined;
@@ -8514,9 +8534,9 @@ var __details_events = function ( settings )
8514
8534
 
8515
8535
  // Update the colspan for the details rows (note, only if it already has
8516
8536
  // a colspan)
8517
- var row, visible = _fnVisbleColumns( ctx );
8537
+ var row, visible = _fnVisibleColumns( ctx );
8518
8538
 
8519
- for ( var i=0, ien=data.length ; i<ien ; i++ ) {
8539
+ for ( var i=0, iLen=data.length ; i<iLen ; i++ ) {
8520
8540
  row = data[i];
8521
8541
 
8522
8542
  if ( row && row._details ) {
@@ -8537,7 +8557,7 @@ var __details_events = function ( settings )
8537
8557
  return;
8538
8558
  }
8539
8559
 
8540
- for ( var i=0, ien=data.length ; i<ien ; i++ ) {
8560
+ for ( var i=0, iLen=data.length ; i<iLen ; i++ ) {
8541
8561
  if ( data[i] && data[i]._details ) {
8542
8562
  __details_remove( api, i );
8543
8563
  }
@@ -8641,7 +8661,7 @@ var __re_column_selector = /^([^:]+)?:(name|title|visIdx|visible)$/;
8641
8661
  // iterator callback in columns().data()
8642
8662
  var __columnData = function ( settings, column, r1, r2, rows, type ) {
8643
8663
  var a = [];
8644
- for ( var row=0, ien=rows.length ; row<ien ; row++ ) {
8664
+ for ( var row=0, iLen=rows.length ; row<iLen ; row++ ) {
8645
8665
  a.push( _fnGetCellData( settings, rows[row], column, type ) );
8646
8666
  }
8647
8667
  return a;
@@ -8841,7 +8861,7 @@ var __setColumnVis = function ( settings, column, vis ) {
8841
8861
  cols = settings.aoColumns,
8842
8862
  col = cols[ column ],
8843
8863
  data = settings.aoData,
8844
- cells, i, ien, tr;
8864
+ cells, i, iLen, tr;
8845
8865
 
8846
8866
  // Get
8847
8867
  if ( vis === undefined ) {
@@ -8859,7 +8879,7 @@ var __setColumnVis = function ( settings, column, vis ) {
8859
8879
  // Need to decide if we should use appendChild or insertBefore
8860
8880
  var insertBefore = _pluck(cols, 'bVisible').indexOf(true, column+1);
8861
8881
 
8862
- for ( i=0, ien=data.length ; i<ien ; i++ ) {
8882
+ for ( i=0, iLen=data.length ; i<iLen ; i++ ) {
8863
8883
  if (data[i]) {
8864
8884
  tr = data[i].nTr;
8865
8885
  cells = data[i].anCells;
@@ -9025,7 +9045,7 @@ _api_registerPlural( 'columns().visible()', 'column().visible()', function ( vis
9025
9045
  // Update colspan for no records display. Child rows and extensions will use their own
9026
9046
  // listeners to do this - only need to update the empty table item here
9027
9047
  if ( ! settings.aiDisplay.length ) {
9028
- $(settings.nTBody).find('td[colspan]').attr('colspan', _fnVisbleColumns(settings));
9048
+ $(settings.nTBody).find('td[colspan]').attr('colspan', _fnVisibleColumns(settings));
9029
9049
  }
9030
9050
 
9031
9051
  _fnSaveState( settings );
@@ -9111,7 +9131,7 @@ var __cell_selector = function ( settings, selector, opts )
9111
9131
  var allCells = $(_flatten( [], cells ));
9112
9132
  var row;
9113
9133
  var columns = settings.aoColumns.length;
9114
- var a, i, ien, j, o, host;
9134
+ var a, i, iLen, j, o, host;
9115
9135
 
9116
9136
  var run = function ( s ) {
9117
9137
  var fnSelector = typeof s === 'function';
@@ -9120,7 +9140,7 @@ var __cell_selector = function ( settings, selector, opts )
9120
9140
  // All cells and function selectors
9121
9141
  a = [];
9122
9142
 
9123
- for ( i=0, ien=rows.length ; i<ien ; i++ ) {
9143
+ for ( i=0, iLen=rows.length ; i<iLen ; i++ ) {
9124
9144
  row = rows[i];
9125
9145
 
9126
9146
  for ( j=0 ; j<columns ; j++ ) {
@@ -9225,12 +9245,12 @@ _api_register( 'cells()', function ( rowSelector, columnSelector, opts ) {
9225
9245
  // Row + column selector
9226
9246
  var columns = this.columns( columnSelector, internalOpts );
9227
9247
  var rows = this.rows( rowSelector, internalOpts );
9228
- var i, ien, j, jen;
9248
+ var i, iLen, j, jen;
9229
9249
 
9230
9250
  var cellsNoOpts = this.iterator( 'table', function ( settings, idx ) {
9231
9251
  var a = [];
9232
9252
 
9233
- for ( i=0, ien=rows[idx].length ; i<ien ; i++ ) {
9253
+ for ( i=0, iLen=rows[idx].length ; i<iLen ; i++ ) {
9234
9254
  for ( j=0, jen=columns[idx].length ; j<jen ; j++ ) {
9235
9255
  a.push( {
9236
9256
  row: rows[idx][i],
@@ -9442,7 +9462,7 @@ _api_register( [
9442
9462
  return this.iterator( 'column', function ( settings, idx ) {
9443
9463
  var sort = _fnSortFlatten( settings );
9444
9464
 
9445
- for ( var i=0, ien=sort.length ; i<ien ; i++ ) {
9465
+ for ( var i=0, iLen=sort.length ; i<iLen ; i++ ) {
9446
9466
  if ( sort[i].col === idx ) {
9447
9467
  return sort[i].dir;
9448
9468
  }
@@ -10133,9 +10153,11 @@ _api_register( 'i18n()', function ( token, def, plural ) {
10133
10153
  }
10134
10154
 
10135
10155
  if ( $.isPlainObject( resolved ) ) {
10136
- resolved = plural !== undefined && resolved[ plural ] !== undefined ?
10137
- resolved[ plural ] :
10138
- resolved._;
10156
+ resolved = plural !== undefined && resolved[ plural ] !== undefined
10157
+ ? resolved[ plural ]
10158
+ : plural === false
10159
+ ? resolved
10160
+ : resolved._;
10139
10161
  }
10140
10162
 
10141
10163
  return typeof resolved === 'string'
@@ -10164,7 +10186,7 @@ function cleanHeader(node, className) {
10164
10186
  * @type string
10165
10187
  * @default Version number
10166
10188
  */
10167
- DataTable.version = "2.3.1";
10189
+ DataTable.version = "2.3.3";
10168
10190
 
10169
10191
  /**
10170
10192
  * Private data store, containing all of the settings objects that are
@@ -10197,7 +10219,7 @@ DataTable.models = {};
10197
10219
  */
10198
10220
  DataTable.models.oSearch = {
10199
10221
  /**
10200
- * Flag to indicate if the filtering should be case insensitive or not
10222
+ * Flag to whether or not the filtering should be case-insensitive
10201
10223
  */
10202
10224
  "caseInsensitive": true,
10203
10225
 
@@ -10482,7 +10504,7 @@ DataTable.models.oColumn = {
10482
10504
  * from v1.10 onwards the primary interface is camel case. In order to avoid
10483
10505
  * breaking backwards compatibility utterly with this change, the Hungarian
10484
10506
  * version is still, internally the primary interface, but is is not documented
10485
- * - hence the @name tags in each doc comment. This allows a Javascript function
10507
+ * - hence the @name tags in each doc comment. This allows a JavaScript function
10486
10508
  * to create a map from Hungarian notation to camel case (going the other direction
10487
10509
  * would require each property to be listed, which would add around 3K to the size
10488
10510
  * of DataTables, while this method is about a 0.5K hit).
@@ -10501,7 +10523,7 @@ DataTable.defaults = {
10501
10523
  /**
10502
10524
  * An array of data to use for the table, passed in at initialisation which
10503
10525
  * will be used in preference to any data which is already in the DOM. This is
10504
- * particularly useful for constructing tables purely in Javascript, for
10526
+ * particularly useful for constructing tables purely in JavaScript, for
10505
10527
  * example with a custom Ajax call.
10506
10528
  */
10507
10529
  "aaData": null,
@@ -10568,7 +10590,7 @@ DataTable.defaults = {
10568
10590
  * * `dataSrc` - By default DataTables will look for the property `data` (or
10569
10591
  * `aaData` for compatibility with DataTables 1.9-) when obtaining data
10570
10592
  * from an Ajax source or for server-side processing - this parameter
10571
- * allows that property to be changed. You can use Javascript dotted
10593
+ * allows that property to be changed. You can use JavaScript dotted
10572
10594
  * object notation to get a data source for multiple levels of nesting, or
10573
10595
  * it my be used as a function. As a function it takes a single parameter,
10574
10596
  * the JSON returned from the server, which can be manipulated as
@@ -10692,13 +10714,13 @@ DataTable.defaults = {
10692
10714
  "bFilter": true,
10693
10715
 
10694
10716
  /**
10695
- * Used only for compatiblity with DT1
10717
+ * Used only for compatibility with DT1
10696
10718
  * @deprecated
10697
10719
  */
10698
10720
  "bInfo": true,
10699
10721
 
10700
10722
  /**
10701
- * Used only for compatiblity with DT1
10723
+ * Used only for compatibility with DT1
10702
10724
  * @deprecated
10703
10725
  */
10704
10726
  "bLengthChange": true,
@@ -10789,7 +10811,7 @@ DataTable.defaults = {
10789
10811
  * Enable or disable state saving. When enabled HTML5 `localStorage` will be
10790
10812
  * used to save table display information such as pagination information,
10791
10813
  * display length, filtering and sorting. As such when the end user reloads
10792
- * the page the display display will match what thy had previously set up.
10814
+ * the page the display will match what thy had previously set up.
10793
10815
  */
10794
10816
  "bStateSave": false,
10795
10817
 
@@ -11146,7 +11168,7 @@ DataTable.defaults = {
11146
11168
  /**
11147
11169
  * When using Ajax sourced data and during the first draw when DataTables is
11148
11170
  * gathering the data, this message is shown in an empty row in the table to
11149
- * indicate to the end user the the data is being loaded. Note that this
11171
+ * indicate to the end user the data is being loaded. Note that this
11150
11172
  * parameter is not used when loading data by server-side processing, just
11151
11173
  * Ajax sourced data with client-side processing.
11152
11174
  */
@@ -11407,8 +11429,8 @@ DataTable.defaults.column = {
11407
11429
  * * `string` - read an object property from the data source. There are
11408
11430
  * three 'special' options that can be used in the string to alter how
11409
11431
  * DataTables reads the data from the source object:
11410
- * * `.` - Dotted Javascript notation. Just as you use a `.` in
11411
- * Javascript to read from nested objects, so to can the options
11432
+ * * `.` - Dotted JavaScript notation. Just as you use a `.` in
11433
+ * JavaScript to read from nested objects, so to can the options
11412
11434
  * specified in `data`. For example: `browser.version` or
11413
11435
  * `browser.name`. If your object parameter name contains a period, use
11414
11436
  * `\\` to escape it - i.e. `first\\.name`.
@@ -11466,7 +11488,7 @@ DataTable.defaults.column = {
11466
11488
  * This property is the rendering partner to `data` and it is suggested that
11467
11489
  * when you want to manipulate data for display (including filtering,
11468
11490
  * sorting etc) without altering the underlying data for the table, use this
11469
- * property. `render` can be considered to be the the read only companion to
11491
+ * property. `render` can be considered to be the read only companion to
11470
11492
  * `data` which is read / write (then as such more complex). Like `data`
11471
11493
  * this option can be given in a number of different ways to effect its
11472
11494
  * behaviour:
@@ -11476,8 +11498,8 @@ DataTable.defaults.column = {
11476
11498
  * * `string` - read an object property from the data source. There are
11477
11499
  * three 'special' options that can be used in the string to alter how
11478
11500
  * DataTables reads the data from the source object:
11479
- * * `.` - Dotted Javascript notation. Just as you use a `.` in
11480
- * Javascript to read from nested objects, so to can the options
11501
+ * * `.` - Dotted JavaScript notation. Just as you use a `.` in
11502
+ * JavaScript to read from nested objects, so to can the options
11481
11503
  * specified in `data`. For example: `browser.version` or
11482
11504
  * `browser.name`. If your object parameter name contains a period, use
11483
11505
  * `\\` to escape it - i.e. `first\\.name`.
@@ -11580,7 +11602,7 @@ DataTable.defaults.column = {
11580
11602
  * The type allows you to specify how the data for this column will be
11581
11603
  * ordered. Four types (string, numeric, date and html (which will strip
11582
11604
  * HTML tags before ordering)) are currently available. Note that only date
11583
- * formats understood by Javascript's Date() object will be accepted as type
11605
+ * formats understood by JavaScript's Date() object will be accepted as type
11584
11606
  * date. For example: "Mar 26, 2008 5:03 PM". May take the values: 'string',
11585
11607
  * 'numeric', 'date' or 'html' (by default). Further types can be adding
11586
11608
  * through plug-ins.
@@ -11632,7 +11654,7 @@ DataTable.models.oSettings = {
11632
11654
  /**
11633
11655
  * Delay the creation of TR and TD elements until they are actually
11634
11656
  * needed by a driven page draw. This can give a significant speed
11635
- * increase for Ajax source and Javascript source data, but makes no
11657
+ * increase for Ajax source and JavaScript source data, but makes no
11636
11658
  * difference at all for DOM and server-side processing tables.
11637
11659
  * Note that this parameter will be set by the initialisation routine. To
11638
11660
  * set a default use {@link DataTable.defaults}.
@@ -11649,13 +11671,13 @@ DataTable.models.oSettings = {
11649
11671
  "bFilter": null,
11650
11672
 
11651
11673
  /**
11652
- * Used only for compatiblity with DT1
11674
+ * Used only for compatibility with DT1
11653
11675
  * @deprecated
11654
11676
  */
11655
11677
  "bInfo": true,
11656
11678
 
11657
11679
  /**
11658
- * Used only for compatiblity with DT1
11680
+ * Used only for compatibility with DT1
11659
11681
  * @deprecated
11660
11682
  */
11661
11683
  "bLengthChange": true,
@@ -12526,7 +12548,7 @@ function __mlHelper (localeString) {
12526
12548
  },
12527
12549
  order: {
12528
12550
  pre: function (d) {
12529
- // The renderer gives us Moment, Luxon or Date obects for the sorting, all of which have a
12551
+ // The renderer gives us Moment, Luxon or Date objects for the sorting, all of which have a
12530
12552
  // `valueOf` which gives milliseconds epoch
12531
12553
  return d.valueOf();
12532
12554
  }
@@ -13092,7 +13114,7 @@ var __numericReplace = function ( d, decimalPlace, re1, re2 ) {
13092
13114
 
13093
13115
  // If a decimal place other than `.` is used, it needs to be given to the
13094
13116
  // function so we can detect it and replace with a `.` which is the only
13095
- // decimal place Javascript recognises - it is not locale aware.
13117
+ // decimal place JavaScript recognises - it is not locale aware.
13096
13118
  if ( decimalPlace ) {
13097
13119
  d = _numToDecimal( d, decimalPlace );
13098
13120
  }
@@ -13150,7 +13172,7 @@ $.extend( true, DataTable.ext.renderer, {
13150
13172
  // on destroy, while the `dt` namespaced event is the one we are
13151
13173
  // listening for
13152
13174
  $(settings.nTable).on( 'order.dt.DT column-visibility.dt.DT', function ( e, ctx, column ) {
13153
- if ( settings !== ctx ) { // need to check this this is the host
13175
+ if ( settings !== ctx ) { // need to check if this is the host
13154
13176
  return; // table, not a nested one
13155
13177
  }
13156
13178