CustomPropertyMetadata Interface
A custom property definition.
#Declaration
export interface CustomPropertyMetadata
#Remarks
The following example shows how to register the custom property definition for the custom Scale Break property:
var ChartScaleBreaksExtension = (function() {
var Model = DevExpress.Dashboard.Model;
// 1. Model
var autoScaleBreaksProperty = {
ownerType: Model.ChartItem,
propertyName: 'ScaleBreaks',
defauleValue: false,
valueType: 'boolean'
};
Model.registerCustomProperty(autoScaleBreaksProperty);
return ChartScaleBreaksExtension;
}());
Tip
Examples on Git
#Properties
#customItemType Property
#Declaration
customItemType?: string
#Property Value
Type |
---|
string |
#defaultValue Property
Specifies a custom property’s default value.
#Declaration
defaultValue?: DevExpress.Dashboard.Model.CustomPropertyValueType
#Property Value
Type | Description |
---|---|
Custom |
A default value that has a type specified in value |
#ownerType Property
Specifies a class where you can store custom properties.
#Declaration
ownerType: any
#Property Value
Type | Description |
---|---|
any | A dashboard, dashboard item, or data item container that stores a custom property. |
#Remarks
The following table lists classes where you can store custom properties:
Class | Description | Property | Example |
---|---|---|---|
Dashboard | Stores custom data related to the dashboard. | Dashboard. |
Dashboard Description |
Dashboard |
Stores custom data related to a particular dashboard item. For example, Dashboard |
Dashboard |
Chart’s Scale Breaks Dashboard Item Description Chart’s Constant Lines |
Data |
Stores custom data related to grid column, chart series, and other dashboard item elements. | Data |
Chart’s Line Options |
#propertyName Property
Specifies a custom property’s unique name.
#Declaration
propertyName: string
#Property Value
Type | Description |
---|---|
string | A string that is a unique name. |
#Remarks
The unique name should contain only letters, numbers, and the underscore symbol and cannot start with a number.
#valueType Property
Specifies a type of a custom property’s value.
#Declaration
valueType?: "string" | "number" | "boolean"
#Property Value
Name | Description |
---|---|
"string" | A string. |
"number" | A number. |
"boolean" | A Boolean value. |
#Remarks
Use the defaultValue property to set a default value.