Class IgxGridCellComponent

Providing reference to IgxGridCellComponent:

@ViewChild('grid', { read: IgxGridComponent })
public grid: IgxGridComponent;
 let column = this.grid.columnList.first;
 let cell = column.cells[0];

Hierarchy

Hierarchy (View Summary)

Implements

  • OnInit
  • OnChanges
  • OnDestroy
  • CellType
  • AfterViewInit

Constructors

Properties

activeHighlightClass: string = 'igx-highlight__active'

Sets/gets the active highlight class class of the cell. Default value is "igx-highlight__active".

let activeHighlightClass = this.cell.activeHighlightClass;
this.cell.activeHighlightClass = 'igx-cell-highlight_active';

IgxGridCellComponent

cdr: ChangeDetectorRef = ...
cellTemplate: TemplateRef<any>

Sets/gets the template of the cell.

<ng-template #cellTemplate igxCell let-value>
<div style="font-style: oblique; color:blueviolet; background:red">
<span>{{value}}</span>
</div>
</ng-template>
@ViewChild('cellTemplate',{read: TemplateRef})
cellTemplate: TemplateRef<any>;
this.cell.cellTemplate = this.cellTemplate;
let template =  this.cell.cellTemplate;

IgxGridCellComponent

cellValidationErrorTemplate: TemplateRef<any>
column: ColumnType

Gets the column of the cell.

 let cellColumn = this.cell.column;

IgxGridCellComponent

editMode: boolean = false

Returns whether the cell is in edit mode.

formatter: (value: any, rowData?: any, columnData?: any) => any

Gets the cell formatter.

let cellForamatter = this.cell.formatter;

IgxGridCellComponent

Type declaration

grid: GridType = ...

Represents the grid instance containing the cell

highlightClass: string = 'igx-highlight'

Sets/gets the highlight class of the cell. Default value is "igx-highlight".

let highlightClass = this.cell.highlightClass;
this.cell.highlightClass = 'igx-cell-highlight';

IgxGridCellComponent

isMerged: boolean

Gets whether this cell is a merged cell.

pinnedIndicator: TemplateRef<any>
role: string = 'gridcell'

Sets/get the role property of the cell. Default value is "gridcell".

this.cell.role = 'grid-cell';
let cellRole = this.cell.role;

IgxGridCellComponent

rowData: any

Gets the data of the row of the cell.

let rowData = this.cell.rowData;

IgxGridCellComponent

value: any

Sets/gets the cell value.

this.cell.value = "Cell Value";
let cellValue = this.cell.value;

IgxGridCellComponent

width: string = ''

Gets the width of the cell.

let cellWidth = this.cell.width;

IgxGridCellComponent

Accessors

Methods

  • If the provided string matches the text in the cell, the text gets highlighted.

    this.cell.highlightText('Cell Value', true);
    

    IgxGridCellComponent

    Parameters

    • text: string
    • caseSensitive: boolean
    • exactMatch: boolean

    Returns number

  • A callback method that is invoked immediately after Angular has completed initialization of a component's view. It is invoked only once when the view is instantiated.

    Returns void