ViewerDefinitionCollection / PartialViewerDefinitionCollection
Description
A ViewerDefinitionCollection represents a collection of key/value pairs, where key is a string used to identify the corresponding ViewerDefinition. It extends ResourceCollection<T>.
Properties
|
Property |
Element |
Type |
Description |
|---|---|---|---|
|
key |
|
string |
The identifier of the |
|
|
value |
The |
Example
const viewerDefinitions = {
dataCellFlagViewer: {
factory: (context) => new FlagViewerProvider()
}
};
Default Values
The DataGrid provides the following default ViewerDefinition:
|
Key |
ViewerProvider |
|---|---|
|
default |
TextViewerProvider |
|
boolean |
ImageViewProvider |
|
string |
TextViewerProvider |
|
number |
TextViewerProvider |
|
integer |
TextViewerProvider |
|
date |
TextViewerProvider |
|
time |
TextViewerProvider |
|
dateTime |
TextViewerProvider |
|
groupTitle |
GroupTitleViewerProvider |
Remarks
Setting the ColumnDefinition.type property to any of these keys makes the DataGrid use the corresponding default ViewerProvider for that column, except for the groupTitle key which applies only to group headers.
A partial type/interface is an object in which properties are optional.