Ignite UI for Angular Column - Documentation The Ignite UI Column is used within an igx-grid element to define what data the column will show. Features such as sorting, filtering & editing are enabled at the column level. You can also provide a template containing custom content inside the column using ng-template which will be used for all cells within the column.
Properties
Section titled "Properties"additionalTemplateContext
Section titled "additionalTemplateContext"Sets/gets custom properties provided in additional template context.
additionalTemplateContext: any autosizeHeader
Section titled "autosizeHeader"Sets/gets whether the column header is included in autosize logic.
Useful when template for a column header is sized based on parent, for example a default div.
Default value is false.
autosizeHeader: boolean bodyTemplate
Section titled "bodyTemplate"Returns a reference to the bodyTemplate.
bodyTemplate: (ctx: IgrCellTemplateContext) => React.ReactNode cellClasses
Section titled "cellClasses"Sets a conditional class selector of the column cells. Accepts an object literal, containing key-value pairs, where the key is the name of the CSS class, while the value is either a callback function that returns a boolean, or boolean, like so:
cellClasses: any cellStyles
Section titled "cellStyles"Sets conditional style properties on the column cells.
Similar to ngStyle it accepts an object literal where the keys are
the style properties and the value is the expression to be evaluated.
As with cellClasses it accepts a callback function.
cellStyles: any colEnd
Section titled "colEnd"Column index where the current field should end. The amount of columns between colStart and colEnd will determine the amount of spanning columns to that field
colEnd: number colStart
Section titled "colStart"Column index from which the field is starting.
colStart: number dataType
Section titled "dataType"Sets/gets the data type of the column values.
Default value is string.
dataType: GridColumnDataType disabledSummaries
Section titled "disabledSummaries"Sets/gets the summary operands to exclude from display. Accepts an array of string keys representing the summary types to disable, such as 'Min', 'Max', 'Count' etc.
disabledSummaries: string[] disableHiding
Section titled "disableHiding"Gets whether the hiding is disabled.
disableHiding: boolean disablePinning
Section titled "disablePinning"Gets whether the pinning is disabled.
disablePinning: boolean editable
Section titled "editable"Gets whether the column is editable.
Default value is false.
editable: boolean editorOptions
Section titled "editorOptions"Pass optional properties for the default column editors.
editorOptions: IgrColumnEditorOptions errorTemplate
Section titled "errorTemplate"Returns a reference to the validation error template.
errorTemplate: (ctx: IgrCellTemplateContext) => React.ReactNode field
Section titled "field"Sets/gets the field value.
field: string filterable
Section titled "filterable"Sets/gets whether the column is filterable.
Default value is true.
filterable: boolean filterCellTemplate
Section titled "filterCellTemplate"Returns a reference to the filterCellTemplate.
filterCellTemplate: (ctx: IgrColumnTemplateContext) => React.ReactNode filteringIgnoreCase
Section titled "filteringIgnoreCase"Sets/gets whether the column filtering should be case sensitive.
Default value is true.
filteringIgnoreCase: boolean filters
Section titled "filters"Gets the column filters.
filters: IgrFilteringOperand formatter
Section titled "formatter"Applies display format to cell values in the column. Does not modify the underlying data.
formatter: any groupable
Section titled "groupable"Sets/gets whether the column is groupable.
Default value is false.
groupable: boolean hasSummary
Section titled "hasSummary"Gets a value indicating whether the summary for the column is enabled.
hasSummary: boolean header
Section titled "header"Sets/gets the header value.
header: string headerClasses
Section titled "headerClasses"Sets/gets the class selector of the column header.
headerClasses: string headerGroupClasses
Section titled "headerGroupClasses"Sets/gets the class selector of the column group header.
headerGroupClasses: string headerGroupStyles
Section titled "headerGroupStyles"Sets conditional style properties on the column header group wrapper.
Similar to ngStyle it accepts an object literal where the keys are
the style properties and the value is the expression to be evaluated.
headerGroupStyles: any headerStyles
Section titled "headerStyles"Sets conditional style properties on the column header.
Similar to ngStyle it accepts an object literal where the keys are
the style properties and the value is the expression to be evaluated.
headerStyles: any headerTemplate
Section titled "headerTemplate"Returns a reference to the header template.
headerTemplate: (ctx: IgrColumnTemplateContext) => React.ReactNode hidden
Section titled "hidden"Gets whether the column is hidden.
hidden: boolean inlineEditorTemplate
Section titled "inlineEditorTemplate"Returns a reference to the inline editor template.
inlineEditorTemplate: (ctx: IgrCellTemplateContext) => React.ReactNode maxWidth
Section titled "maxWidth"Sets/gets the maximum width of the column.
maxWidth: string merge
Section titled "merge"Sets/gets whether to merge cells in this column.
merge: boolean minWidth
Section titled "minWidth"Sets/gets the minimum width of the column.
Default value is 88;
minWidth: string parent
Section titled "parent"Sets/gets the parent column.
parent: IgrColumnComponent pinned
Section titled "pinned"Gets whether the column is pinned.
pinned: boolean pinningPosition
Section titled "pinningPosition"Gets the pinning position of the column.
let pinningPosition = this.column.pinningPosition;
pinningPosition: ColumnPinningPosition pipeArgs
Section titled "pipeArgs"pipeArgs: IgrColumnPipeArgs resizable
Section titled "resizable"Sets/gets whether the column is resizable.
Default value is false.
resizable: boolean rowEnd
Section titled "rowEnd"Row index where the current field should end. The amount of rows between rowStart and rowEnd will determine the amount of spanning rows to that field
rowEnd: number rowStart
Section titled "rowStart"Row index from which the field is starting.
rowStart: number searchable
Section titled "searchable"Sets/gets whether the column is searchable.
Default value is true.
searchable: boolean selectable
Section titled "selectable"Returns if the column is selectable.
selectable: boolean selected
Section titled "selected"Returns if the column is selected.
selected: boolean sortable
Section titled "sortable"Sets/gets whether the column is sortable.
Default value is false.
sortable: boolean sortingIgnoreCase
Section titled "sortingIgnoreCase"Sets/gets whether the column sorting should be case sensitive.
Default value is true.
sortingIgnoreCase: boolean sortStrategy
Section titled "sortStrategy"Gets the column sortStrategy.
sortStrategy: IgrSortingStrategy summaries
Section titled "summaries"Gets the column summaries.
summaries: any summaryFormatter
Section titled "summaryFormatter"The summaryFormatter is used to format the display of the column summaries.
In this example, we check to see if the column name is OrderDate, and then provide a method as the summaryFormatter to change the locale for the dates to 'fr-FR'. The summaries with the count key are skipped so they are displayed as numbers.
summaryFormatter: any summaryTemplate
Section titled "summaryTemplate"Returns a reference to the summaryTemplate.
summaryTemplate: (ctx: IgrSummaryTemplateContext) => React.ReactNode title
Section titled "title"Sets/gets the title value.
title: string visibleWhenCollapsed
Section titled "visibleWhenCollapsed"Indicates whether the column will be visible when its parent is collapsed.
visibleWhenCollapsed: boolean width
Section titled "width"Gets the width of the column.
width: string Accessors
Section titled "Accessors"childColumns
Section titled "childColumns"A list containing all the child columns under this column (if any). Empty without children or if this column is not Group or Layout.
get childColumns(): IgrColumnComponent[] Returns IgrColumnComponent[]
columnGroup
Section titled "columnGroup"Returns a boolean indicating if the column is a ColumnGroup.
get columnGroup(): boolean Returns boolean
columnLayout
Section titled "columnLayout"Returns a boolean indicating if the column is a ColumnLayout for multi-row layout.
get columnLayout(): boolean Returns boolean
columnLayoutChild
Section titled "columnLayoutChild"Returns a boolean indicating if the column is a child of a ColumnLayout for multi-row layout.
get columnLayoutChild(): boolean Returns boolean
filteringExpressionsTree
Section titled "filteringExpressionsTree"Returns the filteringExpressionsTree of the column.
get filteringExpressionsTree(): IgrFilteringExpressionsTree Returns IgrFilteringExpressionsTree
index
Section titled "index"Gets the column index.
get index(): number Returns number
level
Section titled "level"Returns the level of the column in a column group.
Returns 0 if the column doesn't have a parent.
get level(): number Returns number
topLevelParent
Section titled "topLevelParent"Returns a reference to the top level parent column.
get topLevelParent(): IgrColumnComponent Returns IgrColumnComponent
visibleIndex
Section titled "visibleIndex"Gets the column visible index.
If the column is not visible, returns -1.
get visibleIndex(): number Returns number
Methods
Section titled "Methods"autosize
Section titled "autosize"Autosize the column to the longest currently visible cell value, including the header cell. ``
autosize(byHeaderOnly: boolean): void Parameters
- byHeaderOnly:
booleanSet if column should be autosized based only on the header content.
Returns void
Moves a column to the specified visible index. If passed index is invalid, or if column would receive a different visible index after moving, moving is not performed. If passed index would move the column to a different column group. moving is not performed.
move(index: number): void Parameters
- index:
number
Returns void
Example
column.move(index); Pins the column in the specified position at the provided index in that pinned area.
Defaults to index 0 if not provided, or to the initial index in the pinned area.
Returns true if the column is successfully pinned. Returns false if the column cannot be pinned.
Column cannot be pinned if:
- Is already pinned
- index argument is out of range ``
pin(index: number, pinningPosition: ColumnPinningPosition): boolean Parameters
- index:
number - pinningPosition:
ColumnPinningPosition
Returns boolean
unpin
Section titled "unpin"Unpins the column and place it at the provided index in the unpinned area.
Defaults to index 0 if not provided, or to the initial index in the unpinned area.
Returns true if the column is successfully unpinned. Returns false if the column cannot be unpinned.
Column cannot be unpinned if:
- Is already unpinned
- index argument is out of range ``
unpin(index: number): boolean Parameters
- index:
number
Returns boolean
Events
Section titled "Events"onExpandedChange
Section titled "onExpandedChange"onExpandedChange(args: CustomEvent<boolean>): void Parameters
- args:
CustomEvent<boolean>
Returns void
onHiddenChange
Section titled "onHiddenChange"onHiddenChange(args: CustomEvent<boolean>): void Parameters
- args:
CustomEvent<boolean>
Returns void
onPinnedChange
Section titled "onPinnedChange"onPinnedChange(args: CustomEvent<boolean>): void Parameters
- args:
CustomEvent<boolean>
Returns void
onWidthChange
Section titled "onWidthChange"onWidthChange(args: CustomEvent<string>): void Parameters
- args:
CustomEvent<string>