tabulator-tables 5.1.0 → 5.1.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.
Files changed (76) hide show
  1. package/bower.json +1 -1
  2. package/build/rollup.js +2 -1
  3. package/dist/css/tabulator.css +15 -8
  4. package/dist/css/tabulator.css.map +1 -1
  5. package/dist/css/tabulator.min.css +1 -1
  6. package/dist/css/tabulator.min.css.map +1 -1
  7. package/dist/css/tabulator_bootstrap3.css +15 -8
  8. package/dist/css/tabulator_bootstrap3.css.map +1 -1
  9. package/dist/css/tabulator_bootstrap3.min.css +1 -1
  10. package/dist/css/tabulator_bootstrap3.min.css.map +1 -1
  11. package/dist/css/tabulator_bootstrap4.css +15 -8
  12. package/dist/css/tabulator_bootstrap4.css.map +1 -1
  13. package/dist/css/tabulator_bootstrap4.min.css +1 -1
  14. package/dist/css/tabulator_bootstrap4.min.css.map +1 -1
  15. package/dist/css/tabulator_bulma.css +15 -8
  16. package/dist/css/tabulator_bulma.css.map +1 -1
  17. package/dist/css/tabulator_bulma.min.css +1 -1
  18. package/dist/css/tabulator_bulma.min.css.map +1 -1
  19. package/dist/css/tabulator_materialize.css +15 -8
  20. package/dist/css/tabulator_materialize.css.map +1 -1
  21. package/dist/css/tabulator_materialize.min.css +1 -1
  22. package/dist/css/tabulator_materialize.min.css.map +1 -1
  23. package/dist/css/tabulator_midnight.css +15 -8
  24. package/dist/css/tabulator_midnight.css.map +1 -1
  25. package/dist/css/tabulator_midnight.min.css +1 -1
  26. package/dist/css/tabulator_midnight.min.css.map +1 -1
  27. package/dist/css/tabulator_modern.css +15 -8
  28. package/dist/css/tabulator_modern.css.map +1 -1
  29. package/dist/css/tabulator_modern.min.css +1 -1
  30. package/dist/css/tabulator_modern.min.css.map +1 -1
  31. package/dist/css/tabulator_semanticui.css +15 -8
  32. package/dist/css/tabulator_semanticui.css.map +1 -1
  33. package/dist/css/tabulator_semanticui.min.css +1 -1
  34. package/dist/css/tabulator_semanticui.min.css.map +1 -1
  35. package/dist/css/tabulator_simple.css +15 -8
  36. package/dist/css/tabulator_simple.css.map +1 -1
  37. package/dist/css/tabulator_simple.min.css +1 -1
  38. package/dist/css/tabulator_simple.min.css.map +1 -1
  39. package/dist/css/tabulator_site.css +15 -8
  40. package/dist/css/tabulator_site.css.map +1 -1
  41. package/dist/css/tabulator_site.min.css +1 -1
  42. package/dist/css/tabulator_site.min.css.map +1 -1
  43. package/dist/js/tabulator.js +301 -181
  44. package/dist/js/tabulator.js.map +1 -1
  45. package/dist/js/tabulator.min.js +2 -2
  46. package/dist/js/tabulator.min.js.map +1 -1
  47. package/dist/js/tabulator_esm.js +820 -721
  48. package/dist/js/tabulator_esm.js.map +1 -1
  49. package/dist/js/tabulator_esm.min.js +2 -2
  50. package/dist/js/tabulator_esm.min.js.map +1 -1
  51. package/package.json +5 -2
  52. package/src/js/core/FooterManager.js +15 -5
  53. package/src/js/core/RowManager.js +311 -284
  54. package/src/js/core/Tabulator.js +12 -29
  55. package/src/js/core/column/ColumnComponent.js +2 -0
  56. package/src/js/core/tools/InteractionMonitor.js +31 -23
  57. package/src/js/core/tools/ModuleBinder.js +15 -3
  58. package/src/js/modules/ColumnCalcs/ColumnCalcs.js +11 -6
  59. package/src/js/modules/DataTree/DataTree.js +0 -1
  60. package/src/js/modules/Edit/Edit.js +2 -2
  61. package/src/js/modules/Export/Export.js +2 -1
  62. package/src/js/modules/Filter/Filter.js +1 -2
  63. package/src/js/modules/Format/defaults/formatters/rowSelection.js +18 -1
  64. package/src/js/modules/Format/defaults/formatters/rownum.js +1 -1
  65. package/src/js/modules/FrozenColumns/FrozenColumns.js +17 -3
  66. package/src/js/modules/GroupRows/Group.js +144 -142
  67. package/src/js/modules/GroupRows/GroupComponent.js +1 -1
  68. package/src/js/modules/Import/Import.js +1 -3
  69. package/src/js/modules/Layout/Layout.js +1 -0
  70. package/src/js/modules/Page/Page.js +9 -4
  71. package/src/js/modules/Persistence/Persistence.js +6 -4
  72. package/src/js/modules/Persistence/defaults/readers.js +3 -3
  73. package/src/js/modules/ResizeColumns/ResizeColumns.js +61 -51
  74. package/src/js/modules/ResponsiveLayout/ResponsiveLayout.js +5 -5
  75. package/src/js/modules/SelectRow/SelectRow.js +130 -128
  76. package/src/scss/tabulator.scss +17 -12
@@ -41,8 +41,8 @@ class Tabulator {
41
41
  this.dataLoader = false; //bind component functions
42
42
 
43
43
  this.modules = {}; //hold all modules bound to this table
44
- this.modulesCore = {}; //hold core modules bound to this table (for initialization purposes)
45
- this.modulesRegular = {}; //hold regular modules bound to this table (for initialization purposes)
44
+ this.modulesCore = []; //hold core modules bound to this table (for initialization purposes)
45
+ this.modulesRegular = []; //hold regular modules bound to this table (for initialization purposes)
46
46
 
47
47
  this.optionsList = new OptionsList(this, "table constructor");
48
48
 
@@ -50,7 +50,7 @@ class Tabulator {
50
50
 
51
51
  if(this.initializeElement(element)){
52
52
 
53
- this.initialzeCoreSystems(options);
53
+ this.initializeCoreSystems(options);
54
54
 
55
55
  //delay table creation to allow event bindings immediately after the constructor
56
56
  setTimeout(() => {
@@ -80,7 +80,7 @@ class Tabulator {
80
80
  }
81
81
  }
82
82
 
83
- initialzeCoreSystems(options){
83
+ initializeCoreSystems(options){
84
84
  this.columnManager = new ColumnManager(this);
85
85
  this.rowManager = new RowManager(this);
86
86
  this.footerManager = new FooterManager(this);
@@ -100,8 +100,8 @@ class Tabulator {
100
100
  this.interactionMonitor = new InteractionMonitor(this);
101
101
 
102
102
  this.dataLoader.initialize();
103
- this.columnManager.initialize();
104
- this.rowManager.initialize();
103
+ // this.columnManager.initialize();
104
+ // this.rowManager.initialize();
105
105
  this.footerManager.initialize();
106
106
  }
107
107
 
@@ -240,24 +240,9 @@ class Tabulator {
240
240
  this._detectBrowser();
241
241
 
242
242
  //initialize core modules
243
- for (let key in this.modulesCore){
244
- let mod = this.modulesCore[key];
245
-
243
+ this.modulesCore.forEach((mod) => {
246
244
  mod.initialize();
247
- }
248
-
249
- //configure placeholder element
250
- if(typeof options.placeholder == "string"){
251
- var el = document.createElement("div");
252
- el.classList.add("tabulator-placeholder");
253
-
254
- var span = document.createElement("span");
255
- span.innerHTML = options.placeholder;
256
-
257
- el.appendChild(span);
258
-
259
- options.placeholder = el;
260
- }
245
+ })
261
246
 
262
247
  //build table elements
263
248
  element.appendChild(this.columnManager.getElement());
@@ -273,11 +258,9 @@ class Tabulator {
273
258
  }
274
259
 
275
260
  //initialize regular modules
276
- for (let key in this.modulesRegular){
277
- let mod = this.modulesRegular[key];
278
-
261
+ this.modulesRegular.forEach((mod) => {
279
262
  mod.initialize();
280
- }
263
+ });
281
264
 
282
265
  this.columnManager.setColumns(options.columns);
283
266
 
@@ -327,7 +310,7 @@ class Tabulator {
327
310
  this.browserSlow = false;
328
311
  }
329
312
 
330
- this.browserMobile = /(android|bb\d+|meego).+mobile|avantgo|bada\/|blackberry|blazer|compal|elaine|fennec|hiptop|iemobile|ip(hone|od)|iris|kindle|lge |maemo|midp|mmp|mobile.+firefox|netfront|opera m(ob|in)i|palm( os)?|phone|p(ixi|re)\/|plucker|pocket|psp|series(4|6)0|symbian|treo|up\.(browser|link)|vodafone|wap|windows ce|xda|xiino|android|ipad|playbook|silk/i.test(ua)||/1207|6310|6590|3gso|4thp|50[1-6]i|770s|802s|a wa|abac|ac(er|oo|s\-)|ai(ko|rn)|al(av|ca|co)|amoi|an(ex|ny|yw)|aptu|ar(ch|go)|as(te|us)|attw|au(di|\-m|r |s )|avan|be(ck|ll|nq)|bi(lb|rd)|bl(ac|az)|br(e|v)w|bumb|bw\-(n|u)|c55\/|capi|ccwa|cdm\-|cell|chtm|cldc|cmd\-|co(mp|nd)|craw|da(it|ll|ng)|dbte|dc\-s|devi|dica|dmob|do(c|p)o|ds(12|\-d)|el(49|ai)|em(l2|ul)|er(ic|k0)|esl8|ez([4-7]0|os|wa|ze)|fetc|fly(\-|_)|g1 u|g560|gene|gf\-5|g\-mo|go(\.w|od)|gr(ad|un)|haie|hcit|hd\-(m|p|t)|hei\-|hi(pt|ta)|hp( i|ip)|hs\-c|ht(c(\-| |_|a|g|p|s|t)|tp)|hu(aw|tc)|i\-(20|go|ma)|i230|iac( |\-|\/)|ibro|idea|ig01|ikom|im1k|inno|ipaq|iris|ja(t|v)a|jbro|jemu|jigs|kddi|keji|kgt( |\/)|klon|kpt |kwc\-|kyo(c|k)|le(no|xi)|lg( g|\/(k|l|u)|50|54|\-[a-w])|libw|lynx|m1\-w|m3ga|m50\/|ma(te|ui|xo)|mc(01|21|ca)|m\-cr|me(rc|ri)|mi(o8|oa|ts)|mmef|mo(01|02|bi|de|do|t(\-| |o|v)|zz)|mt(50|p1|v )|mwbp|mywa|n10[0-2]|n20[2-3]|n30(0|2)|n50(0|2|5)|n7(0(0|1)|10)|ne((c|m)\-|on|tf|wf|wg|wt)|nok(6|i)|nzph|o2im|op(ti|wv)|oran|owg1|p800|pan(a|d|t)|pdxg|pg(13|\-([1-8]|c))|phil|pire|pl(ay|uc)|pn\-2|po(ck|rt|se)|prox|psio|pt\-g|qa\-a|qc(07|12|21|32|60|\-[2-7]|i\-)|qtek|r380|r600|raks|rim9|ro(ve|zo)|s55\/|sa(ge|ma|mm|ms|ny|va)|sc(01|h\-|oo|p\-)|sdk\/|se(c(\-|0|1)|47|mc|nd|ri)|sgh\-|shar|sie(\-|m)|sk\-0|sl(45|id)|sm(al|ar|b3|it|t5)|so(ft|ny)|sp(01|h\-|v\-|v )|sy(01|mb)|t2(18|50)|t6(00|10|18)|ta(gt|lk)|tcl\-|tdg\-|tel(i|m)|tim\-|t\-mo|to(pl|sh)|ts(70|m\-|m3|m5)|tx\-9|up(\.b|g1|si)|utst|v400|v750|veri|vi(rg|te)|vk(40|5[0-3]|\-v)|vm40|voda|vulc|vx(52|53|60|61|70|80|81|83|85|98)|w3c(\-| )|webc|whit|wi(g |nc|nw)|wmlb|wonu|x700|yas\-|your|zeto|zte\-/i.test(ua.substr(0,4));
313
+ this.browserMobile = /(android|bb\d+|meego).+mobile|avantgo|bada\/|blackberry|blazer|compal|elaine|fennec|hiptop|iemobile|ip(hone|od)|iris|kindle|lge |maemo|midp|mmp|mobile.+firefox|netfront|opera m(ob|in)i|palm( os)?|phone|p(ixi|re)\/|plucker|pocket|psp|series(4|6)0|symbian|treo|up\.(browser|link)|vodafone|wap|windows ce|xda|xiino|android|ipad|playbook|silk/i.test(ua)||/1207|6310|6590|3gso|4thp|50[1-6]i|770s|802s|a wa|abac|ac(er|oo|s\-)|ai(ko|rn)|al(av|ca|co)|amoi|an(ex|ny|yw)|aptu|ar(ch|go)|as(te|us)|attw|au(di|\-m|r |s )|avan|be(ck|ll|nq)|bi(lb|rd)|bl(ac|az)|br(e|v)w|bumb|bw\-(n|u)|c55\/|capi|ccwa|cdm\-|cell|chtm|cldc|cmd\-|co(mp|nd)|craw|da(it|ll|ng)|dbte|dc\-s|devi|dica|dmob|do(c|p)o|ds(12|\-d)|el(49|ai)|em(l2|ul)|er(ic|k0)|esl8|ez([4-7]0|os|wa|ze)|fetc|fly(\-|_)|g1 u|g560|gene|gf\-5|g\-mo|go(\.w|od)|gr(ad|un)|haie|hcit|hd\-(m|p|t)|hei\-|hi(pt|ta)|hp( i|ip)|hs\-c|ht(c(\-| |_|a|g|p|s|t)|tp)|hu(aw|tc)|i\-(20|go|ma)|i230|iac( |\-|\/)|ibro|idea|ig01|ikom|im1k|inno|ipaq|iris|ja(t|v)a|jbro|jemu|jigs|kddi|keji|kgt( |\/)|klon|kpt |kwc\-|kyo(c|k)|le(no|xi)|lg( g|\/(k|l|u)|50|54|\-[a-w])|libw|lynx|m1\-w|m3ga|m50\/|ma(te|ui|xo)|mc(01|21|ca)|m\-cr|me(rc|ri)|mi(o8|oa|ts)|mmef|mo(01|02|bi|de|do|t(\-| |o|v)|zz)|mt(50|p1|v )|mwbp|mywa|n10[0-2]|n20[2-3]|n30(0|2)|n50(0|2|5)|n7(0(0|1)|10)|ne((c|m)\-|on|tf|wf|wg|wt)|nok(6|i)|nzph|o2im|op(ti|wv)|oran|owg1|p800|pan(a|d|t)|pdxg|pg(13|\-([1-8]|c))|phil|pire|pl(ay|uc)|pn\-2|po(ck|rt|se)|prox|psio|pt\-g|qa\-a|qc(07|12|21|32|60|\-[2-7]|i\-)|qtek|r380|r600|raks|rim9|ro(ve|zo)|s55\/|sa(ge|ma|mm|ms|ny|va)|sc(01|h\-|oo|p\-)|sdk\/|se(c(\-|0|1)|47|mc|nd|ri)|sgh\-|shar|sie(\-|m)|sk\-0|sl(45|id)|sm(al|ar|b3|it|t5)|so(ft|ny)|sp(01|h\-|v\-|v )|sy(01|mb)|t2(18|50)|t6(00|10|18)|ta(gt|lk)|tcl\-|tdg\-|tel(i|m)|tim\-|t\-mo|to(pl|sh)|ts(70|m\-|m3|m5)|tx\-9|up(\.b|g1|si)|utst|v400|v750|veri|vi(rg|te)|vk(40|5[0-3]|\-v)|vm40|voda|vulc|vx(52|53|60|61|70|80|81|83|85|98)|w3c(\-| )|webc|whit|wi(g |nc|nw)|wmlb|wonu|x700|yas\-|your|zeto|zte\-/i.test(ua.slice(0,4));
331
314
  }
332
315
 
333
316
  ////////////////// Data Handling //////////////////
@@ -838,4 +821,4 @@ Tabulator.defaultOptions = defaultOptions;
838
821
  //bind modules and static functionality
839
822
  new ModuleBinder(Tabulator);
840
823
 
841
- export default Tabulator;
824
+ export default Tabulator;
@@ -1,3 +1,5 @@
1
+ import Column from './Column.js';
2
+
1
3
  //public column object
2
4
  export default class ColumnComponent {
3
5
  constructor (column){
@@ -1,5 +1,6 @@
1
1
  import CoreFeature from '../CoreFeature.js';
2
2
  import Helpers from './Helpers.js';
3
+ import Row from '../row/Row.js';
3
4
 
4
5
  export default class InteractionManager extends CoreFeature {
5
6
 
@@ -31,7 +32,7 @@ export default class InteractionManager extends CoreFeature {
31
32
  "tabulator-group":"group",
32
33
  "tabulator-col":"column",
33
34
  };
34
-
35
+
35
36
  this.pseudoTrackers = {
36
37
  "row":{
37
38
  subscriber:null,
@@ -50,12 +51,13 @@ export default class InteractionManager extends CoreFeature {
50
51
  target:null,
51
52
  },
52
53
  }
53
-
54
+
54
55
  this.pseudoTracking = false;
55
56
  }
56
57
 
57
58
  initialize(){
58
59
  this.el = this.table.element;
60
+
59
61
  this.buildListenerMap();
60
62
  this.bindSubscriptionWatchers();
61
63
  }
@@ -72,55 +74,55 @@ export default class InteractionManager extends CoreFeature {
72
74
 
73
75
  this.listeners = listenerMap;
74
76
  }
75
-
77
+
76
78
  bindPseudoEvents(){
77
79
  Object.keys(this.pseudoTrackers).forEach((key) => {
78
80
  this.pseudoTrackers[key].subscriber = this.pseudoMouseEnter.bind(this, key);
79
81
  this.subscribe(key + "-mouseover", this.pseudoTrackers[key].subscriber);
80
82
  });
81
-
83
+
82
84
  this.pseudoTracking = true;
83
85
  }
84
-
86
+
85
87
  pseudoMouseEnter(key, e, target){
86
88
  if(this.pseudoTrackers[key].target !== target){
87
89
 
88
90
  if(this.pseudoTrackers[key].target){
89
91
  this.dispatch(key + "-mouseleave", e, target);
90
92
  }
91
-
93
+
92
94
  this.pseudoMouseLeave(key, e);
93
-
95
+
94
96
  this.pseudoTrackers[key].target = target;
95
-
97
+
96
98
  this.dispatch(key + "-mouseenter", e, target);
97
99
  }
98
100
  }
99
-
101
+
100
102
  pseudoMouseLeave(key, e){
101
103
  var leaveList = Object.keys(this.pseudoTrackers),
102
104
  linkedKeys = {
103
105
  "row":["cell"],
104
106
  "cell":["row"],
105
107
  };
106
-
108
+
107
109
  leaveList = leaveList.filter((item) => {
108
110
  var links = linkedKeys[key];
109
111
  return item !== key && (!links || (links && !links.includes(item)));
110
112
  });
111
-
112
-
113
+
114
+
113
115
  leaveList.forEach((key) => {
114
116
  var target = this.pseudoTrackers[key].target;
115
-
117
+
116
118
  if(this.pseudoTrackers[key].target){
117
119
  this.dispatch(key + "-mouseleave", e, target);
118
-
120
+
119
121
  this.pseudoTrackers[key].target = null;
120
122
  }
121
123
  });
122
124
  }
123
-
125
+
124
126
 
125
127
  bindSubscriptionWatchers(){
126
128
  var listeners = Object.keys(this.listeners),
@@ -141,7 +143,7 @@ export default class InteractionManager extends CoreFeature {
141
143
  var listener = this.listeners[key].components,
142
144
  index = listener.indexOf(component),
143
145
  changed = false;
144
-
146
+
145
147
  if(added){
146
148
  if(index === -1){
147
149
  listener.push(component);
@@ -155,7 +157,7 @@ export default class InteractionManager extends CoreFeature {
155
157
  }
156
158
  }
157
159
  }
158
-
160
+
159
161
  if((key === "mouseenter" || key === "mouseleave") && !this.pseudoTracking){
160
162
  this.bindPseudoEvents();
161
163
  }
@@ -189,9 +191,9 @@ export default class InteractionManager extends CoreFeature {
189
191
 
190
192
  var targets = this.findTargets(path);
191
193
  targets = this.bindComponents(type, targets);
192
-
194
+
193
195
  this.triggerEvents(type, e, targets);
194
-
196
+
195
197
  if(this.pseudoTracking && (type == "mouseover" || type == "mouseleave") && !Object.keys(targets).length){
196
198
  this.pseudoMouseLeave("none", e);
197
199
  }
@@ -252,6 +254,10 @@ export default class InteractionManager extends CoreFeature {
252
254
  component = rows.find((row) => {
253
255
  return row.getElement() === target;
254
256
  });
257
+
258
+ if(targets["row"].parentNode && targets["row"].parentNode.closest(".tabulator-row")){
259
+ targets[key] = false;
260
+ }
255
261
  }
256
262
  break;
257
263
 
@@ -263,10 +269,12 @@ export default class InteractionManager extends CoreFeature {
263
269
 
264
270
  case "cell":
265
271
  if(listener.components.includes("cell")){
266
- if(targets["row"]){
272
+ if(targets["row"] instanceof Row){
267
273
  component = targets["row"].findCell(target);
268
- }else{
269
- console.warn("Event Target Lookup Error - The row this cell is attached to cannot be found, has the table been reinitialized without being destroyed first?")
274
+ }else{
275
+ if(targets["row"]){
276
+ console.warn("Event Target Lookup Error - The row this cell is attached to cannot be found, has the table been reinitialized without being destroyed first?")
277
+ }
270
278
  }
271
279
  }
272
280
  break;
@@ -300,7 +308,7 @@ export default class InteractionManager extends CoreFeature {
300
308
  clearWatchers(){
301
309
  for(let key in this.listeners){
302
310
  let listener = this.listeners[key];
303
-
311
+
304
312
  if(listener.handler){
305
313
  this.el.removeEventListener(key, listener.handler)
306
314
  listener.handler = null;
@@ -56,19 +56,31 @@ export default class ModuleBinder {
56
56
 
57
57
  //ensure that module are bound to instantiated function
58
58
  tabulator.prototype.bindModules = function(){
59
+ var orderedMods = [],
60
+ unOrderedMods = [];
61
+
59
62
  this.modules = {};
60
63
 
61
64
  for(var name in tabulator.moduleBindings){
62
65
  let mod = tabulator.moduleBindings[name];
66
+ let module = new mod(this);
63
67
 
64
- this.modules[name] = new mod(this);
68
+ this.modules[name] = module;
65
69
 
66
70
  if(mod.prototype.moduleCore){
67
- this.modulesCore[name] = this.modules[name];
71
+ this.modulesCore.push(module);
68
72
  }else{
69
- this.modulesRegular[name] = this.modules[name];
73
+ if(mod.moduleInitOrder){
74
+ orderedMods.push(module);
75
+ }else{
76
+ unOrderedMods.push(module);
77
+ }
70
78
  }
71
79
  }
80
+
81
+ orderedMods.sort((a, b) => a.moduleInitOrder > b.moduleInitOrder ? 1 : -1);
82
+
83
+ this.modulesRegular = orderedMods.concat(unOrderedMods);
72
84
  }
73
85
  }
74
86
 
@@ -51,7 +51,7 @@ class ColumnCalcs extends Module{
51
51
  this.subscribe("row-added", this.rowsUpdated.bind(this));
52
52
  this.subscribe("column-moved", this.recalcActiveRows.bind(this));
53
53
  this.subscribe("column-add", this.recalcActiveRows.bind(this));
54
- this.subscribe("data-refreshed", this.recalcActiveRows.bind(this));
54
+ this.subscribe("data-refreshed", this.recalcActiveRowsRefresh.bind(this));
55
55
  this.subscribe("table-redraw", this.tableRedraw.bind(this));
56
56
  this.subscribe("rows-visible", this.visibleRows.bind(this));
57
57
 
@@ -99,6 +99,14 @@ class ColumnCalcs extends Module{
99
99
  }
100
100
  }
101
101
 
102
+ recalcActiveRowsRefresh(){
103
+ if(this.table.options.groupBy && this.table.options.dataTreeStartExpanded && this.table.options.dataTree){
104
+ this.recalcAll();
105
+ }else{
106
+ this.recalcActiveRows();
107
+ }
108
+ }
109
+
102
110
  recalcActiveRows(){
103
111
  this.recalc(this.table.rowManager.activeRows);
104
112
  }
@@ -106,7 +114,6 @@ class ColumnCalcs extends Module{
106
114
  cellValueChanged(cell){
107
115
  if(cell.column.definition.topCalc || cell.column.definition.bottomCalc){
108
116
  if(this.table.options.groupBy){
109
-
110
117
  if(this.table.options.columnCalcs == "table" || this.table.options.columnCalcs == "both"){
111
118
  this.recalcActiveRows();
112
119
  }
@@ -114,7 +121,6 @@ class ColumnCalcs extends Module{
114
121
  if(this.table.options.columnCalcs != "table"){
115
122
  this.recalcRowGroup(cell.row);
116
123
  }
117
-
118
124
  }else{
119
125
  this.recalcActiveRows();
120
126
  }
@@ -286,7 +292,6 @@ class ColumnCalcs extends Module{
286
292
 
287
293
  if(this.table.options.groupBy && this.table.options.columnCalcs !== "table"){
288
294
 
289
-
290
295
  var groups = this.table.modules.groupRows.getChildGroups();
291
296
 
292
297
  groups.forEach((group) => {
@@ -331,12 +336,12 @@ class ColumnCalcs extends Module{
331
336
 
332
337
  rowsToData(rows){
333
338
  var data = [];
334
-
339
+
335
340
  rows.forEach((row) => {
336
341
  data.push(row.getData());
337
342
 
338
343
  if(this.table.options.dataTree && this.table.options.dataTreeChildColumnCalcs){
339
- if(row.modules.dataTree.open){
344
+ if(row.modules.dataTree && row.modules.dataTree.open){
340
345
  var children = this.rowsToData(this.table.modules.dataTree.getFilteredTreeChildren(row));
341
346
  data = data.concat(children);
342
347
  }
@@ -579,7 +579,6 @@ class DataTree extends Module{
579
579
  }
580
580
 
581
581
  redrawNeeded(data){
582
- console.log("needed?", data)
583
582
  return (this.field ? typeof data[this.field] !== "undefined" : false) || (this.elementField ? typeof data[this.elementField] !== "undefined" : false);
584
583
  }
585
584
  }
@@ -52,7 +52,7 @@ class Edit extends Module{
52
52
  this.subscribe("column-layout", this.initializeColumnCheck.bind(this));
53
53
  this.subscribe("column-delete", this.columnDeleteCheck.bind(this));
54
54
  this.subscribe("row-deleting", this.rowDeleteCheck.bind(this));
55
- this.subscribe("data-refeshing", this.cancelEdit.bind(this));
55
+ this.subscribe("data-refreshing", this.cancelEdit.bind(this));
56
56
 
57
57
  this.subscribe("keybinding-nav-prev", this.navigatePrev.bind(this, undefined));
58
58
  this.subscribe("keybinding-nav-next", this.keybindingNavigateNext.bind(this));
@@ -74,7 +74,7 @@ class Edit extends Module{
74
74
  if(cell){
75
75
  if(!this.navigateNext(cell, e)){
76
76
  if(newRow){
77
- // cell.getElement().firstChild.blur();
77
+ cell.getElement().firstChild.blur();
78
78
 
79
79
  if(newRow === true){
80
80
  newRow = this.table.addRow({})
@@ -208,7 +208,8 @@ class Export extends Module{
208
208
 
209
209
  header.forEach((col) => {
210
210
  if(col){
211
- columns.push(new ExportColumn(col.title, col.column.getComponent(), col.width, col.height, col.depth));
211
+ let title = typeof col.title === "undefined" ? "" : col.title;
212
+ columns.push(new ExportColumn(title, col.column.getComponent(), col.width, col.height, col.depth));
212
213
  }else{
213
214
  columns.push(null);
214
215
  }
@@ -595,12 +595,11 @@ class Filter extends Module{
595
595
  }
596
596
 
597
597
  field.forEach((filter) => {
598
-
599
598
  filter = this.findFilter(filter);
600
599
 
601
600
  if(filter){
602
601
  this.filterList.push(filter);
603
- this.changed = true;
602
+ changed = true;
604
603
  }
605
604
  });
606
605
 
@@ -2,8 +2,10 @@ import RowComponent from '../../../../core/row/RowComponent.js';
2
2
 
3
3
  export default function(cell, formatterParams, onRendered){
4
4
  var checkbox = document.createElement("input");
5
+ var blocked = false;
5
6
 
6
7
  checkbox.type = 'checkbox';
8
+
7
9
 
8
10
  if(this.table.modExists("selectRow", true)){
9
11
 
@@ -17,9 +19,24 @@ export default function(cell, formatterParams, onRendered){
17
19
  if(row instanceof RowComponent){
18
20
 
19
21
  checkbox.addEventListener("change", (e) => {
20
- row.toggleSelect();
22
+ if(this.table.options.selectableRangeMode === "click"){
23
+ if(!blocked){
24
+ row.toggleSelect();
25
+ }else{
26
+ blocked = false;
27
+ }
28
+ }else{
29
+ row.toggleSelect();
30
+ }
21
31
  });
22
32
 
33
+ if(this.table.options.selectableRangeMode === "click"){
34
+ checkbox.addEventListener("click", (e) => {
35
+ blocked = true;
36
+ this.table.modules.selectRow.handleComplexRowClick(row._row, e);
37
+ });
38
+ }
39
+
23
40
  checkbox.checked = row.isSelected && row.isSelected();
24
41
  this.table.modules.selectRow.registerRowSelectCheckbox(row, checkbox);
25
42
  }else{
@@ -1,3 +1,3 @@
1
1
  export default function(cell, formatterParams, onRendered){
2
- return this.table.rowManager.activeRows.indexOf(cell.getRow()._getSelf()) + 1;
2
+ return this.table.rowManager.activeRows.indexOf(cell.getRow()._getSelf()) + 1 || "";
3
3
  };
@@ -13,6 +13,7 @@ class FrozenColumns extends Module{
13
13
  this.initializationMode = "left";
14
14
  this.active = false;
15
15
  this.scrollEndTimer = false;
16
+ this.blocked = true;
16
17
 
17
18
  this.registerColumnOption("frozen");
18
19
  }
@@ -40,6 +41,16 @@ class FrozenColumns extends Module{
40
41
  this.subscribe("scroll-horizontal", this.scrollHorizontal.bind(this));
41
42
  this.subscribe("columns-loading", this.reset.bind(this));
42
43
  this.subscribe("table-redraw", this.layout.bind(this));
44
+ this.subscribe("layout-refreshing", this.blockLayout.bind(this));
45
+ this.subscribe("layout-refreshed", this.unblockLayout.bind(this));
46
+ }
47
+
48
+ blockLayout(){
49
+ this.blocked = true;
50
+ }
51
+
52
+ unblockLayout(){
53
+ this.blocked = false;
43
54
  }
44
55
 
45
56
  layoutCell(cell){
@@ -225,12 +236,11 @@ class FrozenColumns extends Module{
225
236
  return column.parent.isGroup ? this.getColGroupParentElement(column.parent) : column.getElement();
226
237
  }
227
238
 
228
- //layout columns appropropriatly
239
+ //layout columns appropriately
229
240
  layout(){
230
241
  var rightMargin = 0;
231
242
 
232
- if(this.active){
233
-
243
+ if(this.active && !this.blocked){
234
244
  //calculate row padding
235
245
  this.calcMargins();
236
246
 
@@ -254,6 +264,10 @@ class FrozenColumns extends Module{
254
264
 
255
265
  rowEl.style.paddingLeft = this.leftMargin;
256
266
 
267
+ if(this.table.options.layout === "fitDataFill" && this.rightColumns.length){
268
+ this.table.rowManager.getTableElement().style.minWidth = "calc(100% - " + this.rightMargin + ")";
269
+ }
270
+
257
271
  this.leftColumns.forEach((column) => {
258
272
  var cell = row.getCell(column);
259
273