@@ -2517,7 +2517,7 @@ export abstract class IgxGridBaseDirective implements GridType,
25172517 public get mergeStrategy ( ) {
25182518 return this . _mergeStrategy ;
25192519 }
2520- public set mergeStrategy ( value ) {
2520+ public set mergeStrategy ( value ) {
25212521 this . _mergeStrategy = value ;
25222522 }
25232523
@@ -3119,7 +3119,7 @@ export abstract class IgxGridBaseDirective implements GridType,
31193119 /**
31203120 * @hidden @internal
31213121 */
3122- public hoverIndex : number ;
3122+ public hoverIndex : number ;
31233123
31243124 /**
31253125 * @hidden @internal
@@ -4001,22 +4001,22 @@ export abstract class IgxGridBaseDirective implements GridType,
40014001 * @hidden
40024002 * @internal
40034003 */
4004- public get columnsToMerge ( ) : ColumnType [ ] {
4004+ public get columnsToMerge ( ) : ColumnType [ ] {
40054005 if ( this . _columnsToMerge . length ) {
40064006 return this . _columnsToMerge ;
40074007 }
40084008 const cols = this . visibleColumns . filter (
4009- x => x . merge && ( this . cellMergeMode === 'always' ||
4010- ( this . cellMergeMode === 'onSort' && ! ! this . sortingExpressions . find ( y => y . fieldName === x . field ) ) )
4009+ x => x . merge && ( this . cellMergeMode === 'always' ||
4010+ ( this . cellMergeMode === 'onSort' && ! ! this . sortingExpressions . find ( y => y . fieldName === x . field ) ) )
40114011 ) ;
40124012 this . _columnsToMerge = cols ;
40134013 return this . _columnsToMerge ;
40144014 }
40154015
40164016 protected allowResetOfColumnsToMerge ( ) {
40174017 const cols = this . visibleColumns . filter (
4018- x => x . merge && ( this . cellMergeMode === 'always' ||
4019- ( this . cellMergeMode === 'onSort' && ! ! this . sortingExpressions . find ( y => y . fieldName === x . field ) ) )
4018+ x => x . merge && ( this . cellMergeMode === 'always' ||
4019+ ( this . cellMergeMode === 'onSort' && ! ! this . sortingExpressions . find ( y => y . fieldName === x . field ) ) )
40204020 ) ;
40214021 if ( areEqualArrays ( cols , this . _columnsToMerge ) ) {
40224022 return false ;
@@ -5650,6 +5650,9 @@ export abstract class IgxGridBaseDirective implements GridType,
56505650 * The rowHeight input is bound to min-height css prop of rows that adds a 1px border in all cases
56515651 */
56525652 public get renderedRowHeight ( ) : number {
5653+ if ( this . hasCellsToMerge ) {
5654+ return this . rowHeight ;
5655+ }
56535656 return this . rowHeight + 1 ;
56545657 }
56555658
@@ -7740,9 +7743,9 @@ export abstract class IgxGridBaseDirective implements GridType,
77407743 const virtRec = this . verticalScrollContainer . igxForOf [ targetRowIndex ] ;
77417744 const col = typeof ( column ) === 'number' ? this . visibleColumns [ column ] : column ;
77427745 const rowSpan = this . isRecordMerged ( virtRec ) ? virtRec ?. cellMergeMeta . get ( col ) ?. rowSpan : 1 ;
7743- if ( rowSpan > 1 ) {
7744- targetRowIndex += Math . floor ( rowSpan / 2 ) ;
7745- }
7746+ if ( rowSpan > 1 ) {
7747+ targetRowIndex += Math . floor ( rowSpan / 2 ) ;
7748+ }
77467749 if ( delayScrolling ) {
77477750 this . verticalScrollContainer . dataChanged . pipe ( first ( ) , takeUntil ( this . destroy$ ) ) . subscribe ( ( ) => {
77487751 this . scrollDirective ( this . verticalScrollContainer ,
@@ -8096,10 +8099,10 @@ export abstract class IgxGridBaseDirective implements GridType,
80968099 if ( this . hasCellsToMerge ) {
80978100 let indexes = this . activeRowIndexes ;
80988101 if ( this . page > 0 ) {
8099- indexes = indexes . map ( x => this . perPage * this . page + x ) ;
8102+ indexes = indexes . map ( x => this . perPage * this . page + x ) ;
81008103 }
81018104
8102- data = DataUtil . merge ( cloneArray ( this . filteredSortedData ) , this . columnsToMerge , this . mergeStrategy , indexes , this ) ;
8105+ data = DataUtil . merge ( cloneArray ( this . filteredSortedData ) , this . columnsToMerge , this . mergeStrategy , indexes , this ) ;
81038106 }
81048107 const columnItems = this . visibleColumns . filter ( ( c ) => ! c . columnGroup ) . sort ( ( c1 , c2 ) => c1 . visibleIndex - c2 . visibleIndex ) ;
81058108 const columnsPathParts = columnItems . map ( col => columnFieldPath ( col . field ) ) ;
@@ -8115,7 +8118,7 @@ export abstract class IgxGridBaseDirective implements GridType,
81158118 : resolveNestedPath ( currentRowData , columnsPathParts [ cid ] ) ;
81168119 if ( value !== undefined && value !== null && c . searchable ) {
81178120 let searchValue = caseSensitive ? String ( value ) : String ( value ) . toLowerCase ( ) ;
8118- const isMergePlaceHolder = this . isRecordMerged ( dataRow ) ? ! ! dataRow ?. cellMergeMeta . get ( c . field ) ?. root : false ;
8121+ const isMergePlaceHolder = this . isRecordMerged ( dataRow ) ? ! ! dataRow ?. cellMergeMeta . get ( c . field ) ?. root : false ;
81198122 if ( exactMatch ) {
81208123 if ( searchValue === searchText && ! isMergePlaceHolder ) {
81218124 const mic : IMatchInfoCache = {
@@ -8256,7 +8259,7 @@ export abstract class IgxGridBaseDirective implements GridType,
82568259 this . _rowCount += 1 ; // include header row
82578260 }
82588261
8259- private updateMergedData ( ) {
8262+ private updateMergedData ( ) {
82608263 // recalc merged data
82618264 if ( this . columnsToMerge . length > 0 ) {
82628265 const startIndex = this . verticalScrollContainer . state . startIndex ;
@@ -8267,9 +8270,9 @@ export abstract class IgxGridBaseDirective implements GridType,
82678270 if ( rec . cellMergeMeta &&
82688271 // index + maxRowSpan is within view
82698272 startIndex < ( index + Math . max ( ...rec . cellMergeMeta . values ( ) . toArray ( ) . map ( x => x . rowSpan ) ) ) ) {
8270- const visibleIndex = this . isRowPinningToTop ? index + this . pinnedRecordsCount : index ;
8271- data . push ( { record : rec , index : visibleIndex , dataIndex : index } ) ;
8272- }
8273+ const visibleIndex = this . isRowPinningToTop ? index + this . pinnedRecordsCount : index ;
8274+ data . push ( { record : rec , index : visibleIndex , dataIndex : index } ) ;
8275+ }
82738276 }
82748277 this . _mergedDataInView = data ;
82758278 this . notifyChanges ( ) ;
0 commit comments