@refinitiv-ui/efx-grid 6.0.3 → 6.0.4
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/lib/column-dragging/es6/ColumnDragging.d.ts +49 -0
- package/lib/column-dragging/es6/ColumnDragging.js +764 -0
- package/lib/column-dragging/es6/index.d.ts +1 -0
- package/lib/column-dragging/es6/index.js +1 -0
- package/lib/core/dist/core.css +1 -1
- package/lib/core/dist/core.js +389 -1070
- package/lib/core/dist/core.min.js +1 -1
- package/lib/core/es6/data/ColumnStats.d.ts +2 -2
- package/lib/core/es6/data/DataCache.d.ts +4 -4
- package/lib/core/es6/data/DataTable.d.ts +5 -5
- package/lib/core/es6/data/DataTable.js +1 -1
- package/lib/core/es6/data/DataView.d.ts +12 -12
- package/lib/core/es6/data/SegmentCollection.d.ts +3 -3
- package/lib/core/es6/data/WrappedView.d.ts +13 -13
- package/lib/core/es6/grid/Core.d.ts +29 -27
- package/lib/core/es6/grid/Core.js +26 -4
- package/lib/core/es6/grid/ILayoutGrid.d.ts +15 -15
- package/lib/core/es6/grid/LayoutGrid.js +54 -26
- package/lib/core/es6/grid/VirtualizedLayoutGrid.js +66 -0
- package/lib/core/es6/grid/components/Cell.d.ts +4 -4
- package/lib/core/es6/grid/components/CellFloatingPanel.d.ts +1 -1
- package/lib/core/es6/grid/components/CellSpans.d.ts +8 -8
- package/lib/core/es6/grid/components/Column.d.ts +1 -1
- package/lib/core/es6/grid/components/ElementWrapper.d.ts +6 -6
- package/lib/core/es6/grid/components/Scrollbar.d.ts +1 -1
- package/lib/core/es6/grid/components/StretchedCells.js +2 -2
- package/lib/core/es6/grid/plugins/SortableTitlePlugin.d.ts +14 -6
- package/lib/core/es6/grid/plugins/SortableTitlePlugin.js +147 -81
- package/lib/core/es6/grid/util/Conflator.d.ts +2 -2
- package/lib/core/es6/grid/util/ElementFrameWork.d.ts +3 -3
- package/lib/core/es6/grid/util/HttpRequest.d.ts +2 -2
- package/lib/core/es6/grid/util/PercentBarRenderer.d.ts +1 -1
- package/lib/core/es6/grid/util/RangeBar.d.ts +1 -1
- package/lib/core/es6/grid/util/SectionSettings.d.ts +5 -5
- package/lib/core/es6/grid/util/SectionSettings.js +5 -0
- package/lib/core/es6/grid/util/SelectionList.d.ts +2 -2
- package/lib/core/es6/grid/util/TrackLayout.d.ts +7 -3
- package/lib/core/es6/grid/util/TrackLayout.js +27 -0
- package/lib/core/es6/grid/util/util.d.ts +2 -2
- package/lib/core/es6/index.d.ts +1 -5
- package/lib/core/es6/index.js +1 -7
- package/lib/core/es6/tr-grid-theme.js +1 -1
- package/lib/filter-dialog/lib/filter-dialog.d.ts +1 -0
- package/lib/filter-dialog/lib/filter-dialog.js +73 -26
- package/lib/filter-dialog/themes/base-checkbox.less +8 -1
- package/lib/filter-dialog/themes/base.less +69 -1
- package/lib/filter-dialog/themes/elemental/dark/checkbox-list.js +1 -1
- package/lib/filter-dialog/themes/elemental/dark/es5/all-elements.js +2 -2
- package/lib/filter-dialog/themes/elemental/dark/filter-dialog.js +1 -1
- package/lib/filter-dialog/themes/elemental/light/checkbox-list.js +1 -1
- package/lib/filter-dialog/themes/elemental/light/es5/all-elements.js +2 -2
- package/lib/filter-dialog/themes/elemental/light/filter-dialog.js +1 -1
- package/lib/filter-dialog/themes/halo/dark/checkbox-list.js +1 -1
- package/lib/filter-dialog/themes/halo/dark/es5/all-elements.js +2 -2
- package/lib/filter-dialog/themes/halo/dark/filter-dialog.js +1 -1
- package/lib/filter-dialog/themes/halo/light/checkbox-list.js +1 -1
- package/lib/filter-dialog/themes/halo/light/es5/all-elements.js +2 -2
- package/lib/filter-dialog/themes/halo/light/filter-dialog.js +1 -1
- package/lib/filter-dialog/themes/solar/charcoal/checkbox-list.js +1 -1
- package/lib/filter-dialog/themes/solar/charcoal/es5/all-elements.js +2 -2
- package/lib/filter-dialog/themes/solar/charcoal/filter-dialog.js +1 -1
- package/lib/filter-dialog/themes/solar/pearl/checkbox-list.js +1 -1
- package/lib/filter-dialog/themes/solar/pearl/es5/all-elements.js +2 -2
- package/lib/filter-dialog/themes/solar/pearl/filter-dialog.js +1 -1
- package/lib/grid/lib/efx-grid.d.ts +8 -5
- package/lib/grid/lib/efx-grid.js +10 -4
- package/lib/grid/themes/halo/dark/efx-grid.js +1 -1
- package/lib/grid/themes/halo/dark/es5/all-elements.js +1 -1
- package/lib/grid/themes/halo/efx-grid.less +33 -39
- package/lib/grid/themes/halo/light/efx-grid.js +1 -1
- package/lib/grid/themes/halo/light/es5/all-elements.js +1 -1
- package/lib/index.d.ts +2 -0
- package/lib/index.js +2 -0
- package/lib/row-segmenting/es6/RowSegmenting.d.ts +7 -2
- package/lib/row-segmenting/es6/RowSegmenting.js +94 -9
- package/lib/rt-grid/dist/rt-grid.js +567 -1171
- package/lib/rt-grid/dist/rt-grid.min.js +1 -1
- package/lib/rt-grid/es6/ColumnDefinition.d.ts +5 -3
- package/lib/rt-grid/es6/ColumnDefinition.js +17 -108
- package/lib/rt-grid/es6/DataConnector.d.ts +3 -3
- package/lib/rt-grid/es6/Grid.d.ts +17 -9
- package/lib/rt-grid/es6/Grid.js +201 -101
- package/lib/rt-grid/es6/RowDefSorter.d.ts +19 -0
- package/lib/rt-grid/es6/RowDefSorter.js +137 -0
- package/lib/rt-grid/es6/RowDefinition.d.ts +9 -7
- package/lib/rt-grid/es6/RowDefinition.js +6 -0
- package/lib/rt-grid/es6/SnapshotFiller.d.ts +3 -1
- package/lib/rt-grid/es6/SnapshotFiller.js +23 -0
- package/lib/tr-grid-checkbox/es6/Checkbox.d.ts +2 -2
- package/lib/tr-grid-checkbox/es6/Checkbox.js +38 -20
- package/lib/tr-grid-column-selection/es6/ColumnSelection.js +46 -9
- package/lib/tr-grid-column-stack/es6/ColumnStack.d.ts +8 -4
- package/lib/tr-grid-column-stack/es6/ColumnStack.js +240 -125
- package/lib/tr-grid-conditional-coloring/es6/ConditionalColoring.d.ts +1 -1
- package/lib/tr-grid-conditional-coloring/es6/ConditionalColoring.js +18 -12
- package/lib/tr-grid-in-cell-editing/es6/InCellEditing.d.ts +7 -4
- package/lib/tr-grid-in-cell-editing/es6/InCellEditing.js +93 -2
- package/lib/tr-grid-printer/es6/CellWriter.d.ts +3 -3
- package/lib/tr-grid-printer/es6/GridPrinter.d.ts +1 -1
- package/lib/tr-grid-printer/es6/GridPrinter.js +26 -13
- package/lib/tr-grid-printer/es6/PrintTrait.d.ts +2 -2
- package/lib/tr-grid-printer/es6/SectionWriter.d.ts +3 -3
- package/lib/tr-grid-row-dragging/es6/RowDragging.d.ts +2 -1
- package/lib/tr-grid-row-dragging/es6/RowDragging.js +29 -143
- package/lib/tr-grid-row-grouping/es6/RowGrouping.d.ts +7 -2
- package/lib/tr-grid-row-grouping/es6/RowGrouping.js +97 -7
- package/lib/tr-grid-row-selection/es6/RowSelection.js +10 -0
- package/lib/tr-grid-textformatting/es6/TextFormatting.d.ts +1 -1
- package/lib/tr-grid-textformatting/es6/TextFormatting.js +12 -0
- package/lib/tr-grid-util/es6/DragUI.d.ts +16 -0
- package/lib/tr-grid-util/es6/DragUI.js +214 -0
- package/lib/tr-grid-util/es6/ElementObserver.d.ts +2 -0
- package/lib/tr-grid-util/es6/ElementObserver.js +28 -1
- package/lib/tr-grid-util/es6/ElfUtil.js +1 -1
- package/lib/tr-grid-util/es6/FieldFormatter.js +7 -5
- package/lib/tr-grid-util/es6/GridPlugin.js +8 -4
- package/lib/tr-grid-util/es6/NumberFormatter.d.ts +2 -0
- package/lib/tr-grid-util/es6/NumberFormatter.js +64 -19
- package/lib/tr-grid-util/es6/RowPainter.js +41 -11
- package/lib/tr-grid-util/es6/formula/Formula.js +9 -1
- package/lib/types/es6/Checkbox.d.ts +2 -2
- package/lib/types/es6/ColumnStack.d.ts +8 -4
- package/lib/types/es6/CompositeGrid/ColumnSelectionPlugin.d.ts +3 -2
- package/lib/types/es6/CompositeGrid/ColumnWidthAdjustingPlugin.d.ts +2 -1
- package/lib/types/es6/CompositeGrid/CompositeGrid.d.ts +20 -18
- package/lib/types/es6/CompositeGrid/DragAndDropTitlePlugin.d.ts +2 -1
- package/lib/types/es6/CompositeGrid/DraggableContentPlugin.d.ts +3 -2
- package/lib/types/es6/CompositeGrid/Plugin.d.ts +28 -0
- package/lib/types/es6/CompositeGrid/ResizableTitlePlugin.d.ts +2 -1
- package/lib/types/es6/CompositeGrid/RowSelectionPlugin.d.ts +5 -4
- package/lib/types/es6/CompositeGrid/TreeIndentingPlugin.d.ts +2 -1
- package/lib/types/es6/CompositeGrid/index.d.ts +9 -9
- package/lib/types/es6/ConditionalColoring.d.ts +1 -1
- package/lib/types/es6/Core/data/ColumnStats.d.ts +2 -2
- package/lib/types/es6/Core/data/DataCache.d.ts +4 -4
- package/lib/types/es6/Core/data/DataTable.d.ts +5 -5
- package/lib/types/es6/Core/data/DataView.d.ts +12 -12
- package/lib/types/es6/Core/data/SegmentCollection.d.ts +3 -3
- package/lib/types/es6/Core/data/WrappedView.d.ts +13 -13
- package/lib/types/es6/Core/grid/Core.d.ts +29 -27
- package/lib/types/es6/Core/grid/ILayoutGrid.d.ts +15 -15
- package/lib/types/es6/Core/grid/components/Cell.d.ts +4 -4
- package/lib/types/es6/Core/grid/components/CellFloatingPanel.d.ts +1 -1
- package/lib/types/es6/Core/grid/components/CellSpans.d.ts +8 -8
- package/lib/types/es6/Core/grid/components/Column.d.ts +1 -1
- package/lib/types/es6/Core/grid/components/ElementWrapper.d.ts +6 -6
- package/lib/types/es6/Core/grid/components/Scrollbar.d.ts +1 -1
- package/lib/types/es6/Core/grid/plugins/SortableTitlePlugin.d.ts +14 -6
- package/lib/types/es6/Core/grid/util/Conflator.d.ts +2 -2
- package/lib/types/es6/Core/grid/util/ElementFrameWork.d.ts +3 -3
- package/lib/types/es6/Core/grid/util/HttpRequest.d.ts +2 -2
- package/lib/types/es6/Core/grid/util/PercentBarRenderer.d.ts +1 -1
- package/lib/types/es6/Core/grid/util/RangeBar.d.ts +1 -1
- package/lib/types/es6/Core/grid/util/SectionSettings.d.ts +5 -5
- package/lib/types/es6/Core/grid/util/SelectionList.d.ts +2 -2
- package/lib/types/es6/Core/grid/util/TrackLayout.d.ts +7 -3
- package/lib/types/es6/Core/grid/util/util.d.ts +2 -2
- package/lib/types/es6/Core/index.d.ts +1 -5
- package/lib/types/es6/ExtensionOptions.d.ts +2 -0
- package/lib/types/es6/InCellEditing.d.ts +7 -4
- package/lib/types/es6/RealtimeGrid/ColumnDefinition.d.ts +5 -3
- package/lib/types/es6/RealtimeGrid/DataConnector.d.ts +3 -3
- package/lib/types/es6/RealtimeGrid/Grid.d.ts +17 -9
- package/lib/types/es6/RealtimeGrid/RowDefSorter.d.ts +19 -0
- package/lib/types/es6/RealtimeGrid/RowDefinition.d.ts +9 -7
- package/lib/types/es6/RealtimeGrid/SnapshotFiller.d.ts +3 -1
- package/lib/types/es6/RowDragging.d.ts +2 -1
- package/lib/types/es6/RowGrouping.d.ts +7 -2
- package/lib/types/es6/RowSegmenting.d.ts +7 -2
- package/lib/types/es6/TextFormatting.d.ts +1 -1
- package/lib/versions.json +14 -13
- package/package.json +1 -1
- package/lib/core/es6/grid/plugins/DragAndDropTitlePlugin.d.ts +0 -24
- package/lib/core/es6/grid/plugins/DragAndDropTitlePlugin.js +0 -615
- package/lib/core/es6/grid/plugins/Plugin.d.ts +0 -28
- package/lib/core/es6/grid/plugins/Plugin.js +0 -272
- package/lib/types/es6/Core/grid/plugins/DragAndDropTitlePlugin.d.ts +0 -24
- package/lib/types/es6/Core/grid/plugins/Plugin.d.ts +0 -28
@@ -528,6 +528,22 @@ LayoutGrid.prototype._setColumnWidth = function (indexX, val) {
|
|
528
528
|
LayoutGrid.prototype._updateColumnLayout = function () {
|
529
529
|
this._syncLayoutToColumns(0);
|
530
530
|
};
|
531
|
+
/** @public
|
532
|
+
* @ignore
|
533
|
+
* @param {boolean} enabled
|
534
|
+
* @param {number=} fromR
|
535
|
+
* @param {number=} toR
|
536
|
+
*/
|
537
|
+
LayoutGrid.prototype._startBindingSession = function (enabled, fromR, toR) {
|
538
|
+
// Prevent error when calling _startBindingSession in LayoutGrid
|
539
|
+
};
|
540
|
+
/** @public
|
541
|
+
* @ignore
|
542
|
+
* @return {Array<boolean>}
|
543
|
+
*/
|
544
|
+
LayoutGrid.prototype._getTempRowHeights = function () {
|
545
|
+
return null;
|
546
|
+
};
|
531
547
|
|
532
548
|
/**
|
533
549
|
* {@link ILayoutGrid#getRowHeight}
|
@@ -1369,6 +1385,11 @@ LayoutGrid.prototype.setRowHighlight = function (rowIndex) {
|
|
1369
1385
|
this._highlightedCells[c] = cell;
|
1370
1386
|
cell.addClass("highlighted-row");
|
1371
1387
|
}
|
1388
|
+
var stretchEl = this.getStretchedCell(rowIndex); // check stretched cell
|
1389
|
+
if(stretchEl) {
|
1390
|
+
this._highlightedCells.push(stretchEl);
|
1391
|
+
stretchEl.addClass("highlighted-row");
|
1392
|
+
}
|
1372
1393
|
} else {
|
1373
1394
|
this._highlightedCells.length = 0;
|
1374
1395
|
}
|
@@ -1654,6 +1675,7 @@ LayoutGrid.prototype.insertColumn = function (index, opt_json) {
|
|
1654
1675
|
cell.addClass("selected-row");
|
1655
1676
|
}
|
1656
1677
|
}
|
1678
|
+
// TODO: Check if it can insert column with stretch cell
|
1657
1679
|
}
|
1658
1680
|
|
1659
1681
|
column.activate(atTheMiddle || !this._colVir);
|
@@ -1885,6 +1907,10 @@ LayoutGrid.prototype.stretchCell = function (cellRef, rowIndex, opt_stretching,
|
|
1885
1907
|
} else {
|
1886
1908
|
cell = this._stretchedCells.unstretchCell(rowIndex);
|
1887
1909
|
}
|
1910
|
+
if(cell) {
|
1911
|
+
var selected = this._selectionList.getSelection(rowIndex);
|
1912
|
+
cell.enableClass("selected-row", selected); // It's can enable class without get stretch cell again.
|
1913
|
+
}
|
1888
1914
|
return cell;
|
1889
1915
|
};
|
1890
1916
|
|
@@ -1967,6 +1993,19 @@ LayoutGrid.prototype._calculateViewSize = function (forceRecal) {
|
|
1967
1993
|
}
|
1968
1994
|
return stretchSize;
|
1969
1995
|
};
|
1996
|
+
|
1997
|
+
/**
|
1998
|
+
* @private
|
1999
|
+
* @param {number} rowIndex
|
2000
|
+
* @param {string} className
|
2001
|
+
* @param {boolean} enabled
|
2002
|
+
*/
|
2003
|
+
LayoutGrid.prototype._enableStretchCellClass = function (rowIndex, className, enabled ) {
|
2004
|
+
var stretchEl = this.getStretchedCell(rowIndex); // check stretched cell
|
2005
|
+
if(stretchEl) {
|
2006
|
+
stretchEl.enableClass(className, enabled);
|
2007
|
+
}
|
2008
|
+
};
|
1970
2009
|
/** View size is width of container (Grid's pane) or content (LayoutGrid's columns), whichever is smaller.
|
1971
2010
|
* @public
|
1972
2011
|
* @ignore
|
@@ -2650,11 +2689,16 @@ LayoutGrid.prototype._updateCellSpans = function (cellSpans, adding) {
|
|
2650
2689
|
*/
|
2651
2690
|
LayoutGrid.prototype._onMouseMove = function (e) {
|
2652
2691
|
var target = e["target"];
|
2653
|
-
var colElement = Util.closestElement(target, "column");
|
2654
|
-
var colIndex = this.getColumnIndex(colElement);
|
2655
|
-
var cellElement = (colIndex >= 0) ? Util.closestElement(target, "cell") : null;
|
2656
2692
|
|
2657
|
-
|
2693
|
+
var cellElement = Util.closestElement(target, "cell");
|
2694
|
+
var colIndex = this._stretchedCells.getColumnIndex(cellElement);
|
2695
|
+
if(colIndex < 0) { // Not found colIndex in stretching cell, then get from normal row
|
2696
|
+
var colElement = Util.closestElement(target, "column");
|
2697
|
+
colIndex = this.getColumnIndex(colElement);
|
2698
|
+
}
|
2699
|
+
var rowIndex = this.getCellIndex(colIndex, cellElement);
|
2700
|
+
|
2701
|
+
this.setRowHighlight(rowIndex);
|
2658
2702
|
};
|
2659
2703
|
|
2660
2704
|
/**
|
@@ -2685,27 +2729,16 @@ LayoutGrid.prototype._onMouseOut = function (e) {
|
|
2685
2729
|
*/
|
2686
2730
|
LayoutGrid.prototype._updateSelectionUI = function (rowIndex) { // Update UI of the specified row index
|
2687
2731
|
var selected = this._selectionList.getSelection(rowIndex);
|
2688
|
-
|
2689
|
-
|
2690
|
-
var cell = this._columns[c].getCell(rowIndex);
|
2691
|
-
|
2692
|
-
if (cell) {
|
2693
|
-
cell.enableClass("selected-row", selected);
|
2694
|
-
}
|
2695
|
-
}
|
2732
|
+
this._enableStretchCellClass(rowIndex, "selected-row", selected);
|
2733
|
+
this.enableRowClass(rowIndex, "selected-row", selected);
|
2696
2734
|
};
|
2697
2735
|
|
2698
2736
|
/** @private
|
2699
2737
|
* @param {number} rowIndex
|
2700
2738
|
*/
|
2701
2739
|
LayoutGrid.prototype._addSelectionUI = function (rowIndex) {
|
2702
|
-
|
2703
|
-
|
2704
|
-
|
2705
|
-
if (cell) {
|
2706
|
-
cell.addClass("selected-row");
|
2707
|
-
}
|
2708
|
-
}
|
2740
|
+
this._enableStretchCellClass(rowIndex, "selected-row", true);
|
2741
|
+
this.enableRowClass(rowIndex, "selected-row", true);
|
2709
2742
|
};
|
2710
2743
|
|
2711
2744
|
/**
|
@@ -2713,13 +2746,8 @@ LayoutGrid.prototype._addSelectionUI = function (rowIndex) {
|
|
2713
2746
|
* @param {number} rowIndex
|
2714
2747
|
*/
|
2715
2748
|
LayoutGrid.prototype._removeSelectionUI = function (rowIndex) {
|
2716
|
-
|
2717
|
-
|
2718
|
-
|
2719
|
-
if (cell) {
|
2720
|
-
cell.removeClass("selected-row");
|
2721
|
-
}
|
2722
|
-
}
|
2749
|
+
this._enableStretchCellClass(rowIndex, "selected-row", false);
|
2750
|
+
this.enableRowClass(rowIndex, "selected-row", false);
|
2723
2751
|
};
|
2724
2752
|
|
2725
2753
|
/**
|
@@ -133,6 +133,14 @@ VirtualizedLayoutGrid.prototype._boundLayer = null;
|
|
133
133
|
* @private
|
134
134
|
*/
|
135
135
|
VirtualizedLayoutGrid.prototype._hscrollbar = null;
|
136
|
+
/** @type {string}
|
137
|
+
* @private
|
138
|
+
*/
|
139
|
+
VirtualizedLayoutGrid.prototype._session = "A";
|
140
|
+
/** @type {Array<boolean>}
|
141
|
+
* @private
|
142
|
+
*/
|
143
|
+
VirtualizedLayoutGrid.prototype._tempRowHeights = null;
|
136
144
|
|
137
145
|
//#region ====== Override ElementWrapper ======//
|
138
146
|
/** @override */
|
@@ -244,13 +252,68 @@ VirtualizedLayoutGrid.prototype._setColumnWidth = function (indexX, val) {
|
|
244
252
|
VirtualizedLayoutGrid.prototype._updateColumnLayout = function () {
|
245
253
|
this._grid._updateColumnLayout();
|
246
254
|
};
|
255
|
+
/** @public
|
256
|
+
* @ignore
|
257
|
+
* @param {boolean} enabled
|
258
|
+
*/
|
259
|
+
VirtualizedLayoutGrid.prototype._startBindingSession = function (enabled) {
|
260
|
+
this._isBinding = enabled;
|
261
|
+
if(!enabled){
|
262
|
+
// Clear old session
|
263
|
+
if(this._tempRowHeights){
|
264
|
+
var defaultRowHeight = this.getDefaultRowHeight();
|
265
|
+
var hasSession = true;
|
266
|
+
var removedIndices = [];
|
267
|
+
|
268
|
+
for(var key in this._tempRowHeights){
|
269
|
+
var index = +key;
|
270
|
+
var rowSession = this._layoutY.getLaneProperty(index, "sizeSession");
|
271
|
+
if(rowSession) {
|
272
|
+
if(rowSession != this._session){
|
273
|
+
this.setRowHeight(index, defaultRowHeight);
|
274
|
+
this._layoutY.setLaneProperty(index, "sizeSession", null);
|
275
|
+
removedIndices.push(index);
|
276
|
+
}
|
277
|
+
}
|
278
|
+
}
|
279
|
+
var removedCount = removedIndices.length;
|
280
|
+
for(var i = 0; i < removedCount; i++){
|
281
|
+
delete this._tempRowHeights[removedIndices[i]];
|
282
|
+
}
|
283
|
+
if(removedCount){
|
284
|
+
for(var remainingKey in this._tempRowHeights){
|
285
|
+
hasSession = remainingKey != null;
|
286
|
+
break;
|
287
|
+
}
|
288
|
+
}
|
289
|
+
if(!hasSession){
|
290
|
+
this._tempRowHeights = null;
|
291
|
+
}
|
247
292
|
|
293
|
+
}
|
294
|
+
this._session = this._session === "A" ? "B" : "A";
|
295
|
+
}
|
296
|
+
};
|
297
|
+
/** @public
|
298
|
+
* @ignore
|
299
|
+
* @return {Array<boolean>}
|
300
|
+
*/
|
301
|
+
VirtualizedLayoutGrid.prototype._getTempRowHeights = function () {
|
302
|
+
return this._tempRowHeights;
|
303
|
+
};
|
248
304
|
/** @inheritDoc */
|
249
305
|
VirtualizedLayoutGrid.prototype.getRowHeight = function (index) {
|
250
306
|
return this._layoutY.getLaneSize(index);
|
251
307
|
};
|
252
308
|
/** @inheritDoc */
|
253
309
|
VirtualizedLayoutGrid.prototype.setRowHeight = function (index, val) {
|
310
|
+
if(this._isBinding && val != this.getDefaultRowHeight()){
|
311
|
+
this._layoutY.setLaneProperty(index, "sizeSession", this._session);
|
312
|
+
if(!this._tempRowHeights){
|
313
|
+
this._tempRowHeights = [];
|
314
|
+
}
|
315
|
+
this._tempRowHeights[index] = true; // Store row index that set temporary row height
|
316
|
+
}
|
254
317
|
if(this._layoutY.setLaneSize(index, val)) {
|
255
318
|
this._grid.setRowHeight(index - this._firstIndex, val);
|
256
319
|
this._element.style.height = this._layoutY.getTrackSize() + "px";
|
@@ -404,6 +467,9 @@ VirtualizedLayoutGrid.prototype.setRowCount = function (val, noBinding) {
|
|
404
467
|
var prevCount = this._layoutY.getLaneCount();
|
405
468
|
if(prevCount !== val){
|
406
469
|
this._layoutY.setLaneCount(val);
|
470
|
+
if(this._tempRowHeights){
|
471
|
+
this._tempRowHeights.length = val;
|
472
|
+
}
|
407
473
|
this._element.style.height = this._layoutY.getTrackSize() + "px";
|
408
474
|
this._requestUpdatingRowBounds();
|
409
475
|
//After rowCountChanged fires, virtualizer will update virtual row count if
|
@@ -10,11 +10,11 @@ declare class Cell extends ElementWrapper {
|
|
10
10
|
|
11
11
|
public setTextContent(str: string): void;
|
12
12
|
|
13
|
-
public getTextElement(): Element;
|
13
|
+
public getTextElement(): Element|null;
|
14
14
|
|
15
15
|
public hasElement(): boolean;
|
16
16
|
|
17
|
-
public getSection(): ILayoutGrid;
|
17
|
+
public getSection(): ILayoutGrid|null;
|
18
18
|
|
19
19
|
public initialize(): Element;
|
20
20
|
|
@@ -34,11 +34,11 @@ declare class Cell extends ElementWrapper {
|
|
34
34
|
|
35
35
|
public insertFloatingIcon(elem: Element, opt_order?: number): void;
|
36
36
|
|
37
|
-
public removeFloatingIcon(elemRef: Element|string): Element|null;
|
37
|
+
public removeFloatingIcon(elemRef: Element|string): Element|null|null;
|
38
38
|
|
39
39
|
public insertFrontIcon(elem: Element, opt_order?: number): void;
|
40
40
|
|
41
|
-
public removeFrontIcon(elemRef: Element|string): Element|null;
|
41
|
+
public removeFrontIcon(elemRef: Element|string): Element|null|null;
|
42
42
|
|
43
43
|
public updatePadding(): void;
|
44
44
|
|
@@ -9,7 +9,7 @@ declare class CellFloatingPanel extends ElementWrapper {
|
|
9
9
|
|
10
10
|
public insertItem(item: Element, opt_order?: number): void;
|
11
11
|
|
12
|
-
public removeItem(elemRef?: (Element|string)): Element|null;
|
12
|
+
public removeItem(elemRef?: (Element|string)): Element|null|null;
|
13
13
|
|
14
14
|
public clearItems(): void;
|
15
15
|
|
@@ -8,19 +8,19 @@ declare class CellSpans {
|
|
8
8
|
|
9
9
|
public shiftColumn(from: number, amount: number): boolean;
|
10
10
|
|
11
|
-
public removeSpan(indexX: number, indexY: number): CellSpan;
|
11
|
+
public removeSpan(indexX: number, indexY: number): CellSpan|null;
|
12
12
|
|
13
|
-
public removeSpanByColIndex(at: number, opt_ary?: (CellSpan)[]): (CellSpan)[];
|
13
|
+
public removeSpanByColIndex(at: number, opt_ary?: (CellSpan)[]): (CellSpan)[]|null;
|
14
14
|
|
15
|
-
public removeSpanStartedFromRowIndex(at: number, opt_ary?: (CellSpan)[]): (CellSpan)[];
|
15
|
+
public removeSpanStartedFromRowIndex(at: number, opt_ary?: (CellSpan)[]): (CellSpan)[]|null;
|
16
16
|
|
17
|
-
public clearAllSpans(): (CellSpan)[];
|
17
|
+
public clearAllSpans(): (CellSpan)[]|null;
|
18
18
|
|
19
19
|
public hasSpan(): boolean;
|
20
20
|
|
21
|
-
public getSpan(indexX: number, indexY: number): CellSpan|null;
|
21
|
+
public getSpan(indexX: number, indexY: number): CellSpan|null|null;
|
22
22
|
|
23
|
-
public getOccupyingSpan(indexX: number, indexY: number): CellSpan|null;
|
23
|
+
public getOccupyingSpan(indexX: number, indexY: number): CellSpan|null|null;
|
24
24
|
|
25
25
|
public getAllSpans(): (CellSpan)[];
|
26
26
|
|
@@ -28,9 +28,9 @@ declare class CellSpans {
|
|
28
28
|
|
29
29
|
public getRowSpan(indexX: number, indexY: number): number;
|
30
30
|
|
31
|
-
public setColSpan(indexX: number, indexY: number, spanVal: number): CellSpan;
|
31
|
+
public setColSpan(indexX: number, indexY: number, spanVal: number): CellSpan|null;
|
32
32
|
|
33
|
-
public setRowSpan(indexX: number, indexY: number, spanVal: number): CellSpan;
|
33
|
+
public setRowSpan(indexX: number, indexY: number, spanVal: number): CellSpan|null;
|
34
34
|
|
35
35
|
}
|
36
36
|
|
@@ -7,11 +7,11 @@ declare class ElementWrapper extends EventDispatcher {
|
|
7
7
|
|
8
8
|
constructor(opt_element?: Element);
|
9
9
|
|
10
|
-
public getContent(opt_allContent?: boolean): Element|Node|NodeList;
|
10
|
+
public getContent(opt_allContent?: boolean): Element|Node|NodeList|null;
|
11
11
|
|
12
|
-
public setContent(content: string|Element|ElementWrapper|any, opt_tooltip?: string): Element;
|
12
|
+
public setContent(content: string|Element|ElementWrapper|any, opt_tooltip?: string): Element|null;
|
13
13
|
|
14
|
-
public addContent(content: Element|Node|ElementWrapper): Element;
|
14
|
+
public addContent(content: Element|Node|ElementWrapper): Element|null;
|
15
15
|
|
16
16
|
public removeContent(content: Element|Node|ElementWrapper): boolean;
|
17
17
|
|
@@ -23,11 +23,11 @@ declare class ElementWrapper extends EventDispatcher {
|
|
23
23
|
|
24
24
|
public dispose(): void;
|
25
25
|
|
26
|
-
public getElement(): Element;
|
26
|
+
public getElement(): Element|null;
|
27
27
|
|
28
|
-
public getNextSibling(): Element|Node;
|
28
|
+
public getNextSibling(): Element|Node|null;
|
29
29
|
|
30
|
-
public getParent(): Element|Node;
|
30
|
+
public getParent(): Element|Node|null;
|
31
31
|
|
32
32
|
public setParent(parent: ElementWrapper|Element|Node, opt_prepend?: boolean): void;
|
33
33
|
|
@@ -49,7 +49,7 @@ declare class Scrollbar extends ElementWrapper {
|
|
49
49
|
|
50
50
|
public setMouseWheelSpeed(val: string): void;
|
51
51
|
|
52
|
-
public getDefaultMouseWheelLogic(): ((...params: any[]) => any);
|
52
|
+
public getDefaultMouseWheelLogic(): ((...params: any[]) => any)|null;
|
53
53
|
|
54
54
|
public setScrollingStep(px: number): void;
|
55
55
|
|
@@ -160,10 +160,10 @@ StretchedCells.prototype.getColumnIndex = function (cellRef) {
|
|
160
160
|
if(cellRef["getElement"]) {
|
161
161
|
var cellElement = cellRef["getElement"]();
|
162
162
|
if(cellElement) {
|
163
|
-
return cellElement._colIndex
|
163
|
+
return cellElement._colIndex != null ? cellElement._colIndex : -1;
|
164
164
|
}
|
165
165
|
} else {
|
166
|
-
return cellRef._colIndex
|
166
|
+
return cellRef._colIndex != null ? cellRef._colIndex : -1;
|
167
167
|
}
|
168
168
|
}
|
169
169
|
return -1;
|
@@ -1,5 +1,5 @@
|
|
1
1
|
import Ext from "../../../../tr-grid-util/es6/Ext.js";
|
2
|
-
import
|
2
|
+
import EventDispatcher from "../event/EventDispatcher.js";
|
3
3
|
import Core from "../Core.js";
|
4
4
|
import ILayoutGrid from "../ILayoutGrid.js";
|
5
5
|
import ElementWrapper from "../components/ElementWrapper.js";
|
@@ -45,10 +45,16 @@ declare namespace SortableTitlePlugin {
|
|
45
45
|
|
46
46
|
}
|
47
47
|
|
48
|
-
declare class SortableTitlePlugin extends
|
48
|
+
declare class SortableTitlePlugin extends EventDispatcher {
|
49
49
|
|
50
50
|
constructor(options?: SortableTitlePlugin.Options);
|
51
51
|
|
52
|
+
public getName(): string;
|
53
|
+
|
54
|
+
public initialize(host: Core, options?: any): void;
|
55
|
+
|
56
|
+
public unload(host: Core): void;
|
57
|
+
|
52
58
|
public afterInit(): void;
|
53
59
|
|
54
60
|
public config(options?: any): void;
|
@@ -57,7 +63,7 @@ declare class SortableTitlePlugin extends Plugin {
|
|
57
63
|
|
58
64
|
public getColumnMenu(colIndex: number, config: any): any;
|
59
65
|
|
60
|
-
public getIcons(): { [key: string]: string };
|
66
|
+
public getIcons(): { [key: string]: string }|null;
|
61
67
|
|
62
68
|
public setSortLogics(sortLogic: { [key: string]: ((...params: any[]) => any) }): void;
|
63
69
|
|
@@ -71,9 +77,11 @@ declare class SortableTitlePlugin extends Plugin {
|
|
71
77
|
|
72
78
|
public isColumnSorted(colIndex: number): boolean;
|
73
79
|
|
74
|
-
public getSortedColumns(): (any)[]
|
80
|
+
public getSortedColumns(): (any)[]|null;
|
81
|
+
|
82
|
+
public isSorting(): boolean;
|
75
83
|
|
76
|
-
public sortColumn(
|
84
|
+
public sortColumn(colRef: number|string, sortOrder?: string, opt_arg?: any): void;
|
77
85
|
|
78
86
|
public sortColumns(sortOptions: (SortableTitlePlugin.InitialSort)[], opt_arg?: any): void;
|
79
87
|
|
@@ -85,7 +93,7 @@ declare class SortableTitlePlugin extends Plugin {
|
|
85
93
|
|
86
94
|
public setSortableColumnCount(count: number): void;
|
87
95
|
|
88
|
-
public getSortingStates(): (any)[];
|
96
|
+
public getSortingStates(): (any)[]|null;
|
89
97
|
|
90
98
|
public updateSortSymbols(): void;
|
91
99
|
|