tabulator-tables 5.2.3 → 5.2.6
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/bower.json +1 -1
- package/dist/css/tabulator.css +4 -4
- package/dist/css/tabulator.css.map +1 -1
- package/dist/css/tabulator.min.css +1 -1
- package/dist/css/tabulator.min.css.map +1 -1
- package/dist/css/tabulator_bootstrap3.css +4 -4
- package/dist/css/tabulator_bootstrap3.css.map +1 -1
- package/dist/css/tabulator_bootstrap3.min.css +1 -1
- package/dist/css/tabulator_bootstrap3.min.css.map +1 -1
- package/dist/css/tabulator_bootstrap4.css +4 -4
- package/dist/css/tabulator_bootstrap4.css.map +1 -1
- package/dist/css/tabulator_bootstrap4.min.css +1 -1
- package/dist/css/tabulator_bootstrap4.min.css.map +1 -1
- package/dist/css/tabulator_bootstrap5.css +45 -36
- package/dist/css/tabulator_bootstrap5.css.map +1 -1
- package/dist/css/tabulator_bootstrap5.min.css +1 -1
- package/dist/css/tabulator_bootstrap5.min.css.map +1 -1
- package/dist/css/tabulator_bulma.css +16 -4
- package/dist/css/tabulator_bulma.css.map +1 -1
- package/dist/css/tabulator_bulma.min.css +1 -1
- package/dist/css/tabulator_bulma.min.css.map +1 -1
- package/dist/css/tabulator_materialize.css +4 -4
- package/dist/css/tabulator_materialize.css.map +1 -1
- package/dist/css/tabulator_materialize.min.css +1 -1
- package/dist/css/tabulator_materialize.min.css.map +1 -1
- package/dist/css/tabulator_midnight.css +4 -4
- package/dist/css/tabulator_midnight.css.map +1 -1
- package/dist/css/tabulator_midnight.min.css +1 -1
- package/dist/css/tabulator_midnight.min.css.map +1 -1
- package/dist/css/tabulator_modern.css +4 -4
- package/dist/css/tabulator_modern.css.map +1 -1
- package/dist/css/tabulator_modern.min.css +1 -1
- package/dist/css/tabulator_modern.min.css.map +1 -1
- package/dist/css/tabulator_semanticui.css +4 -4
- package/dist/css/tabulator_semanticui.css.map +1 -1
- package/dist/css/tabulator_semanticui.min.css +1 -1
- package/dist/css/tabulator_semanticui.min.css.map +1 -1
- package/dist/css/tabulator_simple.css +4 -4
- package/dist/css/tabulator_simple.css.map +1 -1
- package/dist/css/tabulator_simple.min.css +1 -1
- package/dist/css/tabulator_simple.min.css.map +1 -1
- package/dist/css/tabulator_site.css +4 -4
- package/dist/css/tabulator_site.css.map +1 -1
- package/dist/css/tabulator_site.min.css +1 -1
- package/dist/css/tabulator_site.min.css.map +1 -1
- package/dist/js/tabulator.js +99 -135
- package/dist/js/tabulator.js.map +1 -1
- package/dist/js/tabulator.min.js +2 -2
- package/dist/js/tabulator.min.js.map +1 -1
- package/dist/js/tabulator_esm.js +72 -109
- package/dist/js/tabulator_esm.js.map +1 -1
- package/dist/js/tabulator_esm.min.js +2 -2
- package/dist/js/tabulator_esm.min.js.map +1 -1
- package/package.json +1 -1
- package/src/js/core/CoreFeature.js +2 -2
- package/src/js/core/RowManager.js +1 -1
- package/src/js/core/cell/Cell.js +1 -2
- package/src/js/core/column/Column.js +1 -81
- package/src/js/core/rendering/Renderer.js +2 -0
- package/src/js/core/tools/DataLoader.js +3 -3
- package/src/js/core/tools/Popup.js +6 -0
- package/src/js/modules/DataTree/DataTree.js +4 -0
- package/src/js/modules/Download/defaults/downloaders/csv.js +2 -3
- package/src/js/modules/Download/defaults/downloaders/pdf.js +2 -3
- package/src/js/modules/Edit/List.js +3 -3
- package/src/js/modules/Export/Export.js +1 -2
- package/src/js/modules/Filter/Filter.js +1 -1
- package/src/js/modules/FrozenColumns/FrozenColumns.js +4 -2
- package/src/js/modules/GroupRows/GroupRows.js +4 -0
- package/src/js/modules/Interaction/Interaction.js +3 -3
- package/src/js/modules/Page/Page.js +1 -2
- package/src/js/modules/ResizeColumns/ResizeColumns.js +38 -7
- package/src/js/modules/Sort/Sort.js +2 -2
- package/src/scss/tabulator.scss +2 -2
- package/src/scss/themes/bootstrap/tabulator_bootstrap5.scss +41 -32
- package/src/scss/themes/bulma/tabulator_bulma.scss +47 -32
package/dist/js/tabulator.js
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
/* Tabulator v5.2.
|
|
1
|
+
/* Tabulator v5.2.6 (c) Oliver Folkerd 2022 */
|
|
2
2
|
(function (global, factory) {
|
|
3
3
|
typeof exports === 'object' && typeof module !== 'undefined' ? module.exports = factory() :
|
|
4
4
|
typeof define === 'function' && define.amd ? define(factory) :
|
|
@@ -323,8 +323,8 @@
|
|
|
323
323
|
|
|
324
324
|
_createClass(CoreFeature, [{
|
|
325
325
|
key: "reloadData",
|
|
326
|
-
value: function reloadData(data, silent) {
|
|
327
|
-
return this.table.dataLoader.load(data, undefined, undefined, undefined, silent);
|
|
326
|
+
value: function reloadData(data, silent, columnsChanged) {
|
|
327
|
+
return this.table.dataLoader.load(data, undefined, undefined, undefined, silent, columnsChanged);
|
|
328
328
|
} //////////////////////////////////////////
|
|
329
329
|
///////////// Localization ///////////////
|
|
330
330
|
//////////////////////////////////////////
|
|
@@ -897,7 +897,6 @@
|
|
|
897
897
|
break;
|
|
898
898
|
|
|
899
899
|
case "undefined":
|
|
900
|
-
case "null":
|
|
901
900
|
this.element.innerHTML = "";
|
|
902
901
|
break;
|
|
903
902
|
|
|
@@ -1277,7 +1276,6 @@
|
|
|
1277
1276
|
}
|
|
1278
1277
|
}
|
|
1279
1278
|
|
|
1280
|
-
this.contentElement = this._bindEvents();
|
|
1281
1279
|
this.contentElement = this._buildColumnHeaderContent();
|
|
1282
1280
|
this.element.appendChild(this.contentElement);
|
|
1283
1281
|
|
|
@@ -1288,92 +1286,12 @@
|
|
|
1288
1286
|
}
|
|
1289
1287
|
|
|
1290
1288
|
this.dispatch("column-init", this);
|
|
1291
|
-
}
|
|
1292
|
-
}, {
|
|
1293
|
-
key: "_bindEvents",
|
|
1294
|
-
value: function _bindEvents() {
|
|
1295
|
-
var _this3 = this;
|
|
1296
|
-
|
|
1297
|
-
var def = this.definition,
|
|
1298
|
-
dblTap,
|
|
1299
|
-
tapHold,
|
|
1300
|
-
tap; //setup header click event bindings
|
|
1301
|
-
|
|
1302
|
-
if (typeof def.headerClick == "function") {
|
|
1303
|
-
this.element.addEventListener("click", function (e) {
|
|
1304
|
-
def.headerClick(e, _this3.getComponent());
|
|
1305
|
-
});
|
|
1306
|
-
}
|
|
1307
|
-
|
|
1308
|
-
if (typeof def.headerDblClick == "function") {
|
|
1309
|
-
this.element.addEventListener("dblclick", function (e) {
|
|
1310
|
-
def.headerDblClick(e, _this3.getComponent());
|
|
1311
|
-
});
|
|
1312
|
-
}
|
|
1313
|
-
|
|
1314
|
-
if (typeof def.headerContext == "function") {
|
|
1315
|
-
this.element.addEventListener("contextmenu", function (e) {
|
|
1316
|
-
def.headerContext(e, _this3.getComponent());
|
|
1317
|
-
});
|
|
1318
|
-
} //setup header tap event bindings
|
|
1319
|
-
|
|
1320
|
-
|
|
1321
|
-
if (typeof def.headerTap == "function") {
|
|
1322
|
-
tap = false;
|
|
1323
|
-
this.element.addEventListener("touchstart", function (e) {
|
|
1324
|
-
tap = true;
|
|
1325
|
-
}, {
|
|
1326
|
-
passive: true
|
|
1327
|
-
});
|
|
1328
|
-
this.element.addEventListener("touchend", function (e) {
|
|
1329
|
-
if (tap) {
|
|
1330
|
-
def.headerTap(e, _this3.getComponent());
|
|
1331
|
-
}
|
|
1332
|
-
|
|
1333
|
-
tap = false;
|
|
1334
|
-
});
|
|
1335
|
-
}
|
|
1336
|
-
|
|
1337
|
-
if (typeof def.headerDblTap == "function") {
|
|
1338
|
-
dblTap = null;
|
|
1339
|
-
this.element.addEventListener("touchend", function (e) {
|
|
1340
|
-
if (dblTap) {
|
|
1341
|
-
clearTimeout(dblTap);
|
|
1342
|
-
dblTap = null;
|
|
1343
|
-
def.headerDblTap(e, _this3.getComponent());
|
|
1344
|
-
} else {
|
|
1345
|
-
dblTap = setTimeout(function () {
|
|
1346
|
-
clearTimeout(dblTap);
|
|
1347
|
-
dblTap = null;
|
|
1348
|
-
}, 300);
|
|
1349
|
-
}
|
|
1350
|
-
});
|
|
1351
|
-
}
|
|
1352
|
-
|
|
1353
|
-
if (typeof def.headerTapHold == "function") {
|
|
1354
|
-
tapHold = null;
|
|
1355
|
-
this.element.addEventListener("touchstart", function (e) {
|
|
1356
|
-
clearTimeout(tapHold);
|
|
1357
|
-
tapHold = setTimeout(function () {
|
|
1358
|
-
clearTimeout(tapHold);
|
|
1359
|
-
tapHold = null;
|
|
1360
|
-
tap = false;
|
|
1361
|
-
def.headerTapHold(e, this.getComponent());
|
|
1362
|
-
}, 1000);
|
|
1363
|
-
}, {
|
|
1364
|
-
passive: true
|
|
1365
|
-
});
|
|
1366
|
-
this.element.addEventListener("touchend", function (e) {
|
|
1367
|
-
clearTimeout(tapHold);
|
|
1368
|
-
tapHold = null;
|
|
1369
|
-
});
|
|
1370
|
-
}
|
|
1371
1289
|
} //build header element for header
|
|
1372
1290
|
|
|
1373
1291
|
}, {
|
|
1374
1292
|
key: "_buildColumnHeader",
|
|
1375
1293
|
value: function _buildColumnHeader() {
|
|
1376
|
-
var
|
|
1294
|
+
var _this3 = this;
|
|
1377
1295
|
|
|
1378
1296
|
var def = this.definition,
|
|
1379
1297
|
table = this.table;
|
|
@@ -1391,7 +1309,7 @@
|
|
|
1391
1309
|
if (def.cssClass) {
|
|
1392
1310
|
var classeNames = def.cssClass.split(" ");
|
|
1393
1311
|
classeNames.forEach(function (className) {
|
|
1394
|
-
|
|
1312
|
+
_this3.element.classList.add(className);
|
|
1395
1313
|
});
|
|
1396
1314
|
}
|
|
1397
1315
|
|
|
@@ -1434,7 +1352,7 @@
|
|
|
1434
1352
|
}, {
|
|
1435
1353
|
key: "_buildColumnHeaderTitle",
|
|
1436
1354
|
value: function _buildColumnHeaderTitle() {
|
|
1437
|
-
var
|
|
1355
|
+
var _this4 = this;
|
|
1438
1356
|
|
|
1439
1357
|
var def = this.definition;
|
|
1440
1358
|
var titleHolderElement = document.createElement("div");
|
|
@@ -1450,7 +1368,7 @@
|
|
|
1450
1368
|
titleElement.addEventListener("change", function () {
|
|
1451
1369
|
def.title = titleElement.value;
|
|
1452
1370
|
|
|
1453
|
-
|
|
1371
|
+
_this4.dispatchExternal("columnTitleChanged", _this4.getComponent());
|
|
1454
1372
|
});
|
|
1455
1373
|
titleHolderElement.appendChild(titleElement);
|
|
1456
1374
|
|
|
@@ -1464,7 +1382,7 @@
|
|
|
1464
1382
|
} else {
|
|
1465
1383
|
if (def.field) {
|
|
1466
1384
|
this.langBind("columns|" + def.field, function (text) {
|
|
1467
|
-
|
|
1385
|
+
_this4._formatColumnHeaderTitle(titleHolderElement, text || def.title || " ");
|
|
1468
1386
|
});
|
|
1469
1387
|
} else {
|
|
1470
1388
|
this._formatColumnHeaderTitle(titleHolderElement, def.title || " ");
|
|
@@ -1492,7 +1410,6 @@
|
|
|
1492
1410
|
break;
|
|
1493
1411
|
|
|
1494
1412
|
case "undefined":
|
|
1495
|
-
case "null":
|
|
1496
1413
|
el.innerHTML = "";
|
|
1497
1414
|
break;
|
|
1498
1415
|
|
|
@@ -1504,7 +1421,7 @@
|
|
|
1504
1421
|
}, {
|
|
1505
1422
|
key: "_buildGroupHeader",
|
|
1506
1423
|
value: function _buildGroupHeader() {
|
|
1507
|
-
var
|
|
1424
|
+
var _this5 = this;
|
|
1508
1425
|
|
|
1509
1426
|
this.element.classList.add("tabulator-col-group");
|
|
1510
1427
|
this.element.setAttribute("role", "columngroup");
|
|
@@ -1513,7 +1430,7 @@
|
|
|
1513
1430
|
if (this.definition.cssClass) {
|
|
1514
1431
|
var classeNames = this.definition.cssClass.split(" ");
|
|
1515
1432
|
classeNames.forEach(function (className) {
|
|
1516
|
-
|
|
1433
|
+
_this5.element.classList.add(className);
|
|
1517
1434
|
});
|
|
1518
1435
|
}
|
|
1519
1436
|
|
|
@@ -1944,40 +1861,40 @@
|
|
|
1944
1861
|
}, {
|
|
1945
1862
|
key: "delete",
|
|
1946
1863
|
value: function _delete() {
|
|
1947
|
-
var
|
|
1864
|
+
var _this6 = this;
|
|
1948
1865
|
|
|
1949
1866
|
return new Promise(function (resolve, reject) {
|
|
1950
1867
|
|
|
1951
|
-
if (
|
|
1952
|
-
|
|
1868
|
+
if (_this6.isGroup) {
|
|
1869
|
+
_this6.columns.forEach(function (column) {
|
|
1953
1870
|
column["delete"]();
|
|
1954
1871
|
});
|
|
1955
1872
|
}
|
|
1956
1873
|
|
|
1957
|
-
|
|
1874
|
+
_this6.dispatch("column-delete", _this6);
|
|
1958
1875
|
|
|
1959
|
-
var cellCount =
|
|
1876
|
+
var cellCount = _this6.cells.length;
|
|
1960
1877
|
|
|
1961
1878
|
for (var i = 0; i < cellCount; i++) {
|
|
1962
|
-
|
|
1879
|
+
_this6.cells[0]["delete"]();
|
|
1963
1880
|
}
|
|
1964
1881
|
|
|
1965
|
-
if (
|
|
1966
|
-
|
|
1882
|
+
if (_this6.element.parentNode) {
|
|
1883
|
+
_this6.element.parentNode.removeChild(_this6.element);
|
|
1967
1884
|
}
|
|
1968
1885
|
|
|
1969
|
-
|
|
1970
|
-
|
|
1971
|
-
|
|
1972
|
-
|
|
1886
|
+
_this6.element = false;
|
|
1887
|
+
_this6.contentElement = false;
|
|
1888
|
+
_this6.titleElement = false;
|
|
1889
|
+
_this6.groupElement = false;
|
|
1973
1890
|
|
|
1974
|
-
if (
|
|
1975
|
-
|
|
1891
|
+
if (_this6.parent.isGroup) {
|
|
1892
|
+
_this6.parent.removeChild(_this6);
|
|
1976
1893
|
}
|
|
1977
1894
|
|
|
1978
|
-
|
|
1895
|
+
_this6.table.columnManager.deregisterColumn(_this6);
|
|
1979
1896
|
|
|
1980
|
-
|
|
1897
|
+
_this6.table.columnManager.renderer.rerenderColumns(true);
|
|
1981
1898
|
|
|
1982
1899
|
resolve();
|
|
1983
1900
|
});
|
|
@@ -2078,7 +1995,7 @@
|
|
|
2078
1995
|
}, {
|
|
2079
1996
|
key: "updateDefinition",
|
|
2080
1997
|
value: function updateDefinition(updates) {
|
|
2081
|
-
var
|
|
1998
|
+
var _this7 = this;
|
|
2082
1999
|
|
|
2083
2000
|
var definition;
|
|
2084
2001
|
|
|
@@ -2087,11 +2004,11 @@
|
|
|
2087
2004
|
definition = Object.assign({}, this.getDefinition());
|
|
2088
2005
|
definition = Object.assign(definition, updates);
|
|
2089
2006
|
return this.table.columnManager.addColumn(definition, false, this).then(function (column) {
|
|
2090
|
-
if (definition.field ==
|
|
2091
|
-
|
|
2007
|
+
if (definition.field == _this7.field) {
|
|
2008
|
+
_this7.field = false; //cleair field name to prevent deletion of duplicate column from arrays
|
|
2092
2009
|
}
|
|
2093
2010
|
|
|
2094
|
-
return
|
|
2011
|
+
return _this7["delete"]().then(function () {
|
|
2095
2012
|
return column.getComponent();
|
|
2096
2013
|
});
|
|
2097
2014
|
});
|
|
@@ -2442,6 +2359,8 @@
|
|
|
2442
2359
|
_this2.elementVertical.scrollTop = _this2.elementVertical.scrollTop - _this2.elementVertical.clientHeight + rowEl.offsetHeight;
|
|
2443
2360
|
}
|
|
2444
2361
|
|
|
2362
|
+
break;
|
|
2363
|
+
|
|
2445
2364
|
case "top":
|
|
2446
2365
|
_this2.elementVertical.scrollTop = rowEl.offsetTop;
|
|
2447
2366
|
break;
|
|
@@ -5103,8 +5022,8 @@
|
|
|
5103
5022
|
value: function createHolderElement() {
|
|
5104
5023
|
var el = document.createElement("div");
|
|
5105
5024
|
el.classList.add("tabulator-tableholder");
|
|
5106
|
-
el.setAttribute("tabindex", 0);
|
|
5107
|
-
|
|
5025
|
+
el.setAttribute("tabindex", 0); // el.setAttribute("role", "rowgroup");
|
|
5026
|
+
|
|
5108
5027
|
return el;
|
|
5109
5028
|
}
|
|
5110
5029
|
}, {
|
|
@@ -6691,7 +6610,7 @@
|
|
|
6691
6610
|
value: function initialize() {}
|
|
6692
6611
|
}, {
|
|
6693
6612
|
key: "load",
|
|
6694
|
-
value: function load(data, params, config, replace, silent) {
|
|
6613
|
+
value: function load(data, params, config, replace, silent, columnsChanged) {
|
|
6695
6614
|
var _this2 = this;
|
|
6696
6615
|
|
|
6697
6616
|
var requestNo = ++this.requestOrder;
|
|
@@ -6725,7 +6644,7 @@
|
|
|
6725
6644
|
if (rowData !== false) {
|
|
6726
6645
|
_this2.dispatchExternal("dataLoaded", rowData);
|
|
6727
6646
|
|
|
6728
|
-
_this2.table.rowManager.setData(rowData, replace, !replace);
|
|
6647
|
+
_this2.table.rowManager.setData(rowData, replace, typeof columnsChanged === "undefined" ? !replace : columnsChanged);
|
|
6729
6648
|
}
|
|
6730
6649
|
} else {
|
|
6731
6650
|
console.warn("Data Load Response Blocked - An active data load request was blocked by an attempt to change table data while the request was being made");
|
|
@@ -6752,7 +6671,7 @@
|
|
|
6752
6671
|
data = [];
|
|
6753
6672
|
}
|
|
6754
6673
|
|
|
6755
|
-
this.table.rowManager.setData(data, replace, !replace);
|
|
6674
|
+
this.table.rowManager.setData(data, replace, typeof columnsChanged === "undefined" ? !replace : columnsChanged);
|
|
6756
6675
|
return Promise.resolve();
|
|
6757
6676
|
}
|
|
6758
6677
|
}
|
|
@@ -7212,6 +7131,7 @@
|
|
|
7212
7131
|
|
|
7213
7132
|
_this.blurEvent = _this.hide.bind(_assertThisInitialized(_this), false);
|
|
7214
7133
|
_this.escEvent = _this._escapeCheck.bind(_assertThisInitialized(_this));
|
|
7134
|
+
_this.destroyBinding = _this.hide.bind(_assertThisInitialized(_this), true);
|
|
7215
7135
|
return _this;
|
|
7216
7136
|
}
|
|
7217
7137
|
|
|
@@ -7344,6 +7264,7 @@
|
|
|
7344
7264
|
this._fitToScreen(x, y, parentEl, parentOffset, position);
|
|
7345
7265
|
|
|
7346
7266
|
this.visible = true;
|
|
7267
|
+
this.subscribe("table-destroy", this.destroyBinding);
|
|
7347
7268
|
return this;
|
|
7348
7269
|
}
|
|
7349
7270
|
}, {
|
|
@@ -7446,6 +7367,8 @@
|
|
|
7446
7367
|
if (this.blurCallback && !silent) {
|
|
7447
7368
|
this.blurCallback();
|
|
7448
7369
|
}
|
|
7370
|
+
|
|
7371
|
+
this.unsubscribe("table-destroy", this.destroyBinding);
|
|
7449
7372
|
}
|
|
7450
7373
|
|
|
7451
7374
|
return this;
|
|
@@ -11321,6 +11244,11 @@
|
|
|
11321
11244
|
value: function getTreeParent(row) {
|
|
11322
11245
|
return row.modules.dataTree.parent ? row.modules.dataTree.parent.getComponent() : false;
|
|
11323
11246
|
}
|
|
11247
|
+
}, {
|
|
11248
|
+
key: "getTreeParentRoot",
|
|
11249
|
+
value: function getTreeParentRoot(row) {
|
|
11250
|
+
return row.modules.dataTree.parent ? this.getTreeParentRoot(row.modules.dataTree.parent) : row;
|
|
11251
|
+
}
|
|
11324
11252
|
}, {
|
|
11325
11253
|
key: "getFilteredTreeChildren",
|
|
11326
11254
|
value: function getFilteredTreeChildren(row) {
|
|
@@ -11524,11 +11452,10 @@
|
|
|
11524
11452
|
if (col) {
|
|
11525
11453
|
switch (_typeof(col.value)) {
|
|
11526
11454
|
case "object":
|
|
11527
|
-
col.value = JSON.stringify(col.value);
|
|
11455
|
+
col.value = col.value !== null ? JSON.stringify(col.value) : "";
|
|
11528
11456
|
break;
|
|
11529
11457
|
|
|
11530
11458
|
case "undefined":
|
|
11531
|
-
case "null":
|
|
11532
11459
|
col.value = "";
|
|
11533
11460
|
break;
|
|
11534
11461
|
}
|
|
@@ -11642,11 +11569,10 @@
|
|
|
11642
11569
|
if (col) {
|
|
11643
11570
|
switch (_typeof(col.value)) {
|
|
11644
11571
|
case "object":
|
|
11645
|
-
col.value = JSON.stringify(col.value);
|
|
11572
|
+
col.value = col.value !== null ? JSON.stringify(col.value) : "";
|
|
11646
11573
|
break;
|
|
11647
11574
|
|
|
11648
11575
|
case "undefined":
|
|
11649
|
-
case "null":
|
|
11650
11576
|
col.value = "";
|
|
11651
11577
|
break;
|
|
11652
11578
|
}
|
|
@@ -12517,7 +12443,7 @@
|
|
|
12517
12443
|
this.initialValues = this.params.multiselect ? initialValue : [initialValue];
|
|
12518
12444
|
|
|
12519
12445
|
if (this.isFilter) {
|
|
12520
|
-
this.input.value = this.initialValues.join(",");
|
|
12446
|
+
this.input.value = this.initialValues ? this.initialValues.join(",") : "";
|
|
12521
12447
|
this.headerFilterInitialListGen();
|
|
12522
12448
|
}
|
|
12523
12449
|
}
|
|
@@ -12961,7 +12887,7 @@
|
|
|
12961
12887
|
values = this._ajaxRequest(this.params.valuesURL, this.input.value);
|
|
12962
12888
|
} else {
|
|
12963
12889
|
if (typeof this.params.valuesLookup === "function") {
|
|
12964
|
-
values = this.params.valuesLookup(cell, this.input.value);
|
|
12890
|
+
values = this.params.valuesLookup(this.cell, this.input.value);
|
|
12965
12891
|
} else if (this.params.valuesLookup) {
|
|
12966
12892
|
values = this._uniqueColumnValues(this.params.valuesLookupField);
|
|
12967
12893
|
}
|
|
@@ -15165,11 +15091,10 @@
|
|
|
15165
15091
|
} else {
|
|
15166
15092
|
switch (_typeof(value)) {
|
|
15167
15093
|
case "object":
|
|
15168
|
-
value = JSON.stringify(value);
|
|
15094
|
+
value = value !== null ? JSON.stringify(value) : "";
|
|
15169
15095
|
break;
|
|
15170
15096
|
|
|
15171
15097
|
case "undefined":
|
|
15172
|
-
case "null":
|
|
15173
15098
|
value = "";
|
|
15174
15099
|
break;
|
|
15175
15100
|
|
|
@@ -15954,7 +15879,7 @@
|
|
|
15954
15879
|
value: function refreshFilter() {
|
|
15955
15880
|
if (this.tableInitialized) {
|
|
15956
15881
|
if (this.table.options.filterMode === "remote") {
|
|
15957
|
-
this.reloadData();
|
|
15882
|
+
this.reloadData(null, false, false);
|
|
15958
15883
|
} else {
|
|
15959
15884
|
this.refreshData(true);
|
|
15960
15885
|
}
|
|
@@ -17384,7 +17309,8 @@
|
|
|
17384
17309
|
this.table.columnManager.headersElement.style.marginLeft = this.leftMargin;
|
|
17385
17310
|
this.table.columnManager.element.style.paddingRight = this.rightMargin;
|
|
17386
17311
|
this.leftColumns.forEach(function (column, i) {
|
|
17387
|
-
column.modules.frozen.
|
|
17312
|
+
column.modules.frozen.marginValue = leftMargin + _this4.table.columnManager.scrollLeft;
|
|
17313
|
+
column.modules.frozen.margin = column.modules.frozen.marginValue + "px";
|
|
17388
17314
|
|
|
17389
17315
|
if (column.visible) {
|
|
17390
17316
|
leftMargin += column.getWidth();
|
|
@@ -17423,7 +17349,8 @@
|
|
|
17423
17349
|
rightMargin += column.getWidth();
|
|
17424
17350
|
}
|
|
17425
17351
|
|
|
17426
|
-
column.modules.frozen.
|
|
17352
|
+
column.modules.frozen.marginValue = _this4.rightPadding - rightMargin;
|
|
17353
|
+
column.modules.frozen.margin = column.modules.frozen.marginValue + "px";
|
|
17427
17354
|
|
|
17428
17355
|
if (i == _this4.rightColumns.length - 1) {
|
|
17429
17356
|
column.modules.frozen.edge = true;
|
|
@@ -18830,6 +18757,11 @@
|
|
|
18830
18757
|
key: "getRowGroup",
|
|
18831
18758
|
value: function getRowGroup(row) {
|
|
18832
18759
|
var match = false;
|
|
18760
|
+
|
|
18761
|
+
if (this.options("dataTree")) {
|
|
18762
|
+
row = this.table.modules.dataTree.getTreeParentRoot(row);
|
|
18763
|
+
}
|
|
18764
|
+
|
|
18833
18765
|
this.groupList.forEach(function (group) {
|
|
18834
18766
|
var result = group.getRowGroup(row);
|
|
18835
18767
|
|
|
@@ -22487,7 +22419,6 @@
|
|
|
22487
22419
|
break;
|
|
22488
22420
|
|
|
22489
22421
|
case "undefined":
|
|
22490
|
-
case "null":
|
|
22491
22422
|
this.pageCounterElement.innerHTML = "";
|
|
22492
22423
|
break;
|
|
22493
22424
|
|
|
@@ -24018,6 +23949,7 @@
|
|
|
24018
23949
|
this.subscribe("column-moved", this.columnLayoutUpdated.bind(this));
|
|
24019
23950
|
this.subscribe("column-hide", this.deInitializeColumn.bind(this));
|
|
24020
23951
|
this.subscribe("column-show", this.columnLayoutUpdated.bind(this));
|
|
23952
|
+
this.subscribe("column-width", this.columnWidthUpdated.bind(this));
|
|
24021
23953
|
this.subscribe("column-delete", this.deInitializeComponent.bind(this));
|
|
24022
23954
|
this.subscribe("column-height", this.resizeHandle.bind(this));
|
|
24023
23955
|
this.initialized = true;
|
|
@@ -24050,16 +23982,42 @@
|
|
|
24050
23982
|
this.reinitializeColumn(prev);
|
|
24051
23983
|
}
|
|
24052
23984
|
}
|
|
23985
|
+
}, {
|
|
23986
|
+
key: "columnWidthUpdated",
|
|
23987
|
+
value: function columnWidthUpdated(column) {
|
|
23988
|
+
var _this2 = this;
|
|
23989
|
+
|
|
23990
|
+
if (column.modules.frozen) {
|
|
23991
|
+
if (this.table.modules.frozenColumns.leftColumns.includes(column)) {
|
|
23992
|
+
this.table.modules.frozenColumns.leftColumns.forEach(function (col) {
|
|
23993
|
+
_this2.reinitializeColumn(col);
|
|
23994
|
+
});
|
|
23995
|
+
} else if (this.table.modules.frozenColumns.rightColumns.includes(column)) {
|
|
23996
|
+
this.table.modules.frozenColumns.rightColumns.forEach(function (col) {
|
|
23997
|
+
_this2.reinitializeColumn(col);
|
|
23998
|
+
});
|
|
23999
|
+
}
|
|
24000
|
+
}
|
|
24001
|
+
}
|
|
24053
24002
|
}, {
|
|
24054
24003
|
key: "reinitializeColumn",
|
|
24055
24004
|
value: function reinitializeColumn(column) {
|
|
24005
|
+
var frozenOffset = column.modules.frozen ? column.modules.frozen.marginValue + column.getWidth() + "px" : false;
|
|
24056
24006
|
column.cells.forEach(function (cell) {
|
|
24057
24007
|
if (cell.modules.resize && cell.modules.resize.handleEl) {
|
|
24008
|
+
if (frozenOffset) {
|
|
24009
|
+
cell.modules.resize.handleEl.style.left = frozenOffset;
|
|
24010
|
+
}
|
|
24011
|
+
|
|
24058
24012
|
cell.element.after(cell.modules.resize.handleEl);
|
|
24059
24013
|
}
|
|
24060
24014
|
});
|
|
24061
24015
|
|
|
24062
24016
|
if (column.modules.resize && column.modules.resize.handleEl) {
|
|
24017
|
+
if (frozenOffset) {
|
|
24018
|
+
column.modules.resize.handleEl.style.left = frozenOffset;
|
|
24019
|
+
}
|
|
24020
|
+
|
|
24063
24021
|
column.element.after(column.modules.resize.handleEl);
|
|
24064
24022
|
}
|
|
24065
24023
|
}
|
|
@@ -24108,9 +24066,15 @@
|
|
|
24108
24066
|
self.table.externalEvents.dispatch("columnResized", nearestColumn.getComponent());
|
|
24109
24067
|
}
|
|
24110
24068
|
});
|
|
24069
|
+
|
|
24070
|
+
if (column.modules.frozen) {
|
|
24071
|
+
handle.style.position = "absolute";
|
|
24072
|
+
handle.style.left = column.modules.frozen.marginValue + column.getWidth() + "px";
|
|
24073
|
+
}
|
|
24074
|
+
|
|
24111
24075
|
config.handleEl = handle;
|
|
24112
24076
|
|
|
24113
|
-
if (element.parentNode) {
|
|
24077
|
+
if (element.parentNode && column.visible) {
|
|
24114
24078
|
element.after(handle);
|
|
24115
24079
|
}
|
|
24116
24080
|
}
|
|
@@ -24120,11 +24084,11 @@
|
|
|
24120
24084
|
}, {
|
|
24121
24085
|
key: "deInitializeColumn",
|
|
24122
24086
|
value: function deInitializeColumn(column) {
|
|
24123
|
-
var
|
|
24087
|
+
var _this3 = this;
|
|
24124
24088
|
|
|
24125
24089
|
this.deInitializeComponent(column);
|
|
24126
24090
|
column.cells.forEach(function (cell) {
|
|
24127
|
-
|
|
24091
|
+
_this3.deInitializeComponent(cell);
|
|
24128
24092
|
});
|
|
24129
24093
|
}
|
|
24130
24094
|
}, {
|
|
@@ -25846,7 +25810,7 @@
|
|
|
25846
25810
|
key: "refreshSort",
|
|
25847
25811
|
value: function refreshSort() {
|
|
25848
25812
|
if (this.table.options.sortMode === "remote") {
|
|
25849
|
-
this.reloadData();
|
|
25813
|
+
this.reloadData(null, false, false);
|
|
25850
25814
|
} else {
|
|
25851
25815
|
this.refreshData(true);
|
|
25852
25816
|
} //TODO - Persist left position of row manager
|
|
@@ -26022,7 +25986,7 @@
|
|
|
26022
25986
|
key: "setColumnHeader",
|
|
26023
25987
|
value: function setColumnHeader(column, dir) {
|
|
26024
25988
|
column.modules.sort.dir = dir;
|
|
26025
|
-
column.getElement().setAttribute("aria-sort", dir);
|
|
25989
|
+
column.getElement().setAttribute("aria-sort", dir === "asc" ? "ascending" : "descending");
|
|
26026
25990
|
} //sort each item in sort list
|
|
26027
25991
|
|
|
26028
25992
|
}, {
|