Providing reference to IgxGridCellComponent:
@ViewChild('grid', { read: IgxGridComponent })
public grid: IgxGridComponent;let column = this.grid.columnList.first;let cell = column.cells[0]; Constructors
Section titled "Constructors"IgxGridCellComponent
new IgxGridCellComponent(): IgxGridCellComponent Returns IgxGridCellComponent
Properties
Section titled "Properties"activeHighlightClass
Section titled "activeHighlightClass"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'; activeHighlightClass: string = 'igx-highlight__active' Defined in projects/igniteui-angular/grids/core/src/cell.component.ts:821
cdr: ChangeDetectorRef Defined in projects/igniteui-angular/grids/core/src/cell.component.ts:116
cellTemplate
Section titled "cellTemplate"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; cellTemplate: TemplateRef<any> Defined in projects/igniteui-angular/grids/core/src/cell.component.ts:246
cellValidationErrorTemplate
Section titled "cellValidationErrorTemplate"cellValidationErrorTemplate: TemplateRef<any> Defined in projects/igniteui-angular/grids/core/src/cell.component.ts:249
column
Section titled "column"Gets the column of the cell.
let cellColumn = this.cell.column; column: ColumnType Defined in projects/igniteui-angular/grids/core/src/cell.component.ts:162
editMode
Section titled "editMode"Returns whether the cell is in edit mode.
editMode: boolean = false Defined in projects/igniteui-angular/grids/core/src/cell.component.ts:522
formatter
Section titled "formatter"Gets the cell formatter.
let cellForamatter = this.cell.formatter; formatter: object Defined in projects/igniteui-angular/grids/core/src/cell.component.ts:277
Represents the grid instance containing the cell
grid: GridType Defined in projects/igniteui-angular/grids/core/src/cell.component.ts:114
highlightClass
Section titled "highlightClass"Sets/gets the highlight class of the cell.
Default value is "igx-highlight".
let highlightClass = this.cell.highlightClass;this.cell.highlightClass = 'igx-cell-highlight'; highlightClass: string = 'igx-highlight' Defined in projects/igniteui-angular/grids/core/src/cell.component.ts:807
isMerged
Section titled "isMerged"Gets whether this cell is a merged cell.
isMerged: boolean Defined in projects/igniteui-angular/grids/core/src/cell.component.ts:175
pinnedIndicator
Section titled "pinnedIndicator"pinnedIndicator: TemplateRef<any> Defined in projects/igniteui-angular/grids/core/src/cell.component.ts:252
Sets/get the role property of the cell.
Default value is "gridcell".
this.cell.role = 'grid-cell';let cellRole = this.cell.role; role: string = 'gridcell' Defined in projects/igniteui-angular/grids/core/src/cell.component.ts:537
rowData
Section titled "rowData"Gets the data of the row of the cell.
let rowData = this.cell.rowData; rowData: any Defined in projects/igniteui-angular/grids/core/src/cell.component.ts:214
value
Section titled "value"Sets/gets the cell value.
this.cell.value = "Cell Value";let cellValue = this.cell.value; value: any Defined in projects/igniteui-angular/grids/core/src/cell.component.ts:266
width
Section titled "width"Gets the width of the cell.
let cellWidth = this.cell.width; width: string = '' Defined in projects/igniteui-angular/grids/core/src/cell.component.ts:630
editValue
Section titled "editValue"The value to display when the cell is in edit mode.
editValue: any Defined in projects/igniteui-angular/grids/core/src/cell.component.ts:697, projects/igniteui-angular/grids/core/src/cell.component.ts:712
selected
Section titled "selected"Indicates whether the cell is currently selected. It is false, if the sell is not selected, and true, if it is.
selected: boolean Defined in projects/igniteui-angular/grids/core/src/cell.component.ts:653, projects/igniteui-angular/grids/core/src/cell.component.ts:665
visibleColumnIndex
Section titled "visibleColumnIndex"The index of the column that the cell belongs to. It counts only the visible (not hidden) columns
visibleColumnIndex: number Defined in projects/igniteui-angular/grids/core/src/cell.component.ts:397, projects/igniteui-angular/grids/core/src/cell.component.ts:401
Accessors
Section titled "Accessors"ariaSelected
Section titled "ariaSelected"get ariaSelected(): boolean Defined in projects/igniteui-angular/grids/core/src/cell.component.ts:640
Returns boolean
attrCellID
Section titled "attrCellID"get attrCellID(): string Defined in projects/igniteui-angular/grids/core/src/cell.component.ts:420
Returns string
booleanClass
Section titled "booleanClass"get booleanClass(): any Defined in projects/igniteui-angular/grids/core/src/cell.component.ts:452
Returns any
cellID
Section titled "cellID"Gets the ID of the cell.
let cellID = this.cell.cellID;get cellID(): object Defined in projects/igniteui-angular/grids/core/src/cell.component.ts:413
Returns object
colEnd
Section titled "colEnd"get colEnd(): number Defined in projects/igniteui-angular/grids/core/src/cell.component.ts:609
Returns number
colStart
Section titled "colStart"get colStart(): number Defined in projects/igniteui-angular/grids/core/src/cell.component.ts:617
Returns number
columnIndex
Section titled "columnIndex"Gets the index of the cell column.
let columnIndex = this.cell.columnIndex;get columnIndex(): number Defined in projects/igniteui-angular/grids/core/src/cell.component.ts:383
Returns number
columnSelected
Section titled "columnSelected"Gets whether the cell column is selected.
let isCellColumnSelected = this.cell.columnSelected;get columnSelected(): boolean Defined in projects/igniteui-angular/grids/core/src/cell.component.ts:684
Returns boolean
context
Section titled "context"Gets the cell template context object.
let context = this.cell.context();get context(): IgxCellTemplateContext Defined in projects/igniteui-angular/grids/core/src/cell.component.ts:287
Returns IgxCellTemplateContext
editable
Section titled "editable"Returns whether the cell is editable.
get editable(): boolean Defined in projects/igniteui-angular/grids/core/src/cell.component.ts:721
Returns boolean
gridColumnSpan
Section titled "gridColumnSpan"get gridColumnSpan(): number Defined in projects/igniteui-angular/grids/core/src/cell.component.ts:601
Returns number
gridID
Section titled "gridID"Gets the id of the grid in which the cell is stored.
let gridId = this.cell.gridID;get gridID(): any Defined in projects/igniteui-angular/grids/core/src/cell.component.ts:357
Returns any
gridRowSpan
Section titled "gridRowSpan"get gridRowSpan(): number Defined in projects/igniteui-angular/grids/core/src/cell.component.ts:597
Returns number
nativeElement
Section titled "nativeElement"Returns a reference to the nativeElement of the cell.
let cellNativeElement = this.cell.nativeElement;get nativeElement(): HTMLElement Defined in projects/igniteui-angular/grids/core/src/cell.component.ts:464
Returns HTMLElement
pinnedIndicatorTemplate
Section titled "pinnedIndicatorTemplate"Gets the pinned indicator template.
let template = this.cell.pinnedIndicatorTemplate;get pinnedIndicatorTemplate(): TemplateRef<any> Defined in projects/igniteui-angular/grids/core/src/cell.component.ts:342
Returns TemplateRef<any>
readonly
Section titled "readonly"Gets whether the cell is editable.
let isCellReadonly = this.cell.readonly;get readonly(): boolean Defined in projects/igniteui-angular/grids/core/src/cell.component.ts:548
Returns boolean
Gets the row of the cell.
let cellRow = this.cell.row;get row(): RowType Defined in projects/igniteui-angular/grids/core/src/cell.component.ts:201
Returns RowType
rowEnd
Section titled "rowEnd"get rowEnd(): number Defined in projects/igniteui-angular/grids/core/src/cell.component.ts:605
Returns number
rowIndex
Section titled "rowIndex"Gets the index of the row where the cell is stored.
let rowIndex = this.cell.rowIndex;get rowIndex(): number Defined in projects/igniteui-angular/grids/core/src/cell.component.ts:371
Returns number
rowStart
Section titled "rowStart"get rowStart(): number Defined in projects/igniteui-angular/grids/core/src/cell.component.ts:613
Returns number
template
Section titled "template"Gets the cell template.
let template = this.cell.template;get template(): TemplateRef<any> Defined in projects/igniteui-angular/grids/core/src/cell.component.ts:317
Returns TemplateRef<any>
title
Section titled "title"An optional title to display for the cell
get title(): any Defined in projects/igniteui-angular/grids/core/src/cell.component.ts:425
Returns any
Methods
Section titled "Methods"clearHighlight
Section titled "clearHighlight"Clears the highlight of the text in the cell.
this.cell.clearHighLight();clearHighlight(): void Defined in projects/igniteui-angular/grids/core/src/cell.component.ts:1206
Returns void
highlightText
Section titled "highlightText"If the provided string matches the text in the cell, the text gets highlighted.
this.cell.highlightText('Cell Value', true);highlightText(text: string, caseSensitive: boolean, exactMatch: boolean): number Defined in projects/igniteui-angular/grids/core/src/cell.component.ts:1194
Parameters
- text:
string - caseSensitive:
boolean - exactMatch:
boolean
Returns number
ngAfterViewInit
Section titled "ngAfterViewInit"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.
ngAfterViewInit(): void Defined in projects/igniteui-angular/grids/core/src/cell.component.ts:899
Returns void
setEditMode
Section titled "setEditMode"Starts/ends edit mode for the cell.
cell.setEditMode(true);setEditMode(value: boolean): void Defined in projects/igniteui-angular/grids/core/src/cell.component.ts:998
Parameters
- value:
boolean
Returns void
update
Section titled "update"Sets new value to the cell.
this.cell.update('New Value');update(val: any): void Defined in projects/igniteui-angular/grids/core/src/cell.component.ts:1023
Parameters
- val:
any