-
Notifications
You must be signed in to change notification settings - Fork 157
/
Copy pathbullet-chart-model.d.ts
367 lines (282 loc) · 9.64 KB
/
bullet-chart-model.d.ts
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
import { Component, Property, NotifyPropertyChanges, Browser, Complex, Event, EmitType } from '@syncfusion/ej2-base';import { EventHandler, remove, INotifyPropertyChanged, ModuleDeclaration, Collection, isNullOrUndefined } from '@syncfusion/ej2-base';import { Internationalization } from '@syncfusion/ej2-base';import { SvgRenderer, Rect, Size, measureText, TextOption } from '@syncfusion/ej2-svg-base';import { Query } from '@syncfusion/ej2-data';import { OrientationType, TickPosition, LabelsPlacement, TextPosition, FeatureType, TargetType } from './utils/enum';import { AnimationModel, BorderModel } from '../common/model/base-model';import { Margin, Animation, Border } from '../common/model/base';import { MarginModel } from '../common/model/base-model';import { Data } from '../common/model/data';import { BulletChartAxis } from './renderer/bullet-axis';import { ScaleGroup } from './renderer/scale-render';import { redrawElement, textElement, getElement, appendChildElement, RectOption, stringToNumber, removeElement } from '../common/utils/helper';import { BulletTooltip } from './user-interaction/tooltip';import { IPrintEventArgs } from '../chart/model/chart-interface';import { ExportType } from '../common/utils/enum';import { AccumulationChart } from '../accumulation-chart/accumulation';import { Chart } from '../chart/chart';import { ChartTheme } from '../common/utils/enum';import { RangeNavigator } from '../range-navigator/range-navigator';import { getTitle, logBase } from '../common/utils/helper';import { BulletTooltipSettings, Range, BulletLabelStyle, BulletDataLabel } from './model/bullet-base';import { MajorTickLinesSettings, MinorTickLinesSettings } from './model/bullet-base';import { BulletChartLegendSettings } from '../bullet-chart/model/bullet-base';import { BulletChartLegendSettingsModel } from '../bullet-chart/model/bullet-base-model';import { IBulletMouseEventArgs, IBulletLegendRenderEventArgs } from '../bullet-chart/model/bullet-interface';import { BulletChartLegend } from '../bullet-chart/legend/legend';import { BulletTooltipSettingsModel, RangeModel } from './model/bullet-base-model';import { MajorTickLinesSettingsModel, MinorTickLinesSettingsModel } from './model/bullet-base-model';import { BulletLabelStyleModel, BulletDataLabelModel } from './model/bullet-base-model';import { resized, bulletChartMouseClick } from '../common/model/constants';import { IBulletResizeEventArgs, IBulletStyle, IBulletchartTooltipEventArgs, IBulletLoadedEventArgs } from './model/bullet-interface';import { IFeatureBarBounds } from './model/bullet-interface';import { getBulletThemeColor } from './utils/theme';import { ExportUtils } from '../common/utils/export';import { PdfPageOrientation } from '@syncfusion/ej2-pdf-export';import { PrintUtils } from '../common/utils/print';
import {ComponentModel} from '@syncfusion/ej2-base';
/**
* Interface for a class BulletChart
*/
export interface BulletChartModel extends ComponentModel{
/**
* The width of the bullet chart as a string accepts input as both like '100px' or '100%'.
* If specified as '100%, bullet chart renders to the full width of its parent element.
*
* @default null
* @aspDefaultValueIgnore
*/
width?: string;
/**
* The height of the bullet chart as a string accepts input both as '100px' or '100%'.
* If specified as '100%, bullet chart renders to the full height of its parent element.
*
* @default null
* @aspDefaultValueIgnore
*/
height?: string;
/**
* The locale of the bullet chart as a string.
*
* @default null
* @aspDefaultValueIgnore
*/
locale?: string;
/**
* Options for customizing major tick lines.
*/
majorTickLines?: MajorTickLinesSettingsModel;
/**
* Options for customizing minor tick lines.
*/
minorTickLines?: MinorTickLinesSettingsModel;
/**
* Specifies the minimum range of an scale.
*
* @default null
*/
minimum?: number;
/**
* Specifies the maximum range of an scale.
*
* @default null
*/
maximum?: number;
/**
* Specifies the interval for an scale.
*
* @default null
*/
interval?: number;
/**
* specifies the interval of minor ticks.
*
* @default 4
*/
minorTicksPerInterval?: number;
/**
* Options for customizing labels
*/
labelStyle?: BulletLabelStyleModel;
/**
* Options for customizing values labels.
*/
categoryLabelStyle?: BulletLabelStyleModel;
/**
* Specifies the format of the bullet chart axis labels.
*
* @default ''
*/
labelFormat?: string;
/**
* Specifies the title of the bullet chart.
*
* @default ''
*/
title?: string;
/**
* Options for customizing the title styles of the bullet chart.
*/
titleStyle?: BulletLabelStyleModel;
/**
* Specifies the sub title of the bullet chart.
*
* @default ''
*/
subtitle?: string;
/**
* Options for customizing the sub title styles of the bullet chart.
*/
subtitleStyle?: BulletLabelStyleModel;
/**
* Orientation of the scale.
*
* @default 'Horizontal'
*/
orientation?: OrientationType;
/**
* Options for customizing the color and width of the chart border.
*/
border?: BorderModel;
/**
* Options for customizing the tooltip of the BulletChart.
*/
tooltip?: BulletTooltipSettingsModel;
/**
* provides Qualitative ranges of the bullet chart.
*/
ranges?: RangeModel[];
/**
* specifies the axis label position of the bullet chart.
*
* @default 'Outside'
*/
labelPosition?: LabelsPlacement;
/**
* specifies the tick position of the bullet chart.
*
* @default 'Outside'
*/
tickPosition?: TickPosition;
/**
* Sets the title position of bullet chart.
*
* @default 'Top'.
*/
titlePosition?: TextPosition;
/**
* If set to true, the axis will render at the opposite side of its default position.
*
* @default false
*/
opposedPosition?: boolean;
/**
* Specifies the theme for the bullet chart.
*
* @default 'Material'
*/
theme?: ChartTheme;
/**
* Options for customizing animation of the feature bar.
*/
animation?: AnimationModel;
/**
* Options for customizing data label of the feature bar.
*/
dataLabel?: BulletDataLabelModel;
/**
* Options for customizing the legend of the bullet chart.
*/
legendSettings?: BulletChartLegendSettingsModel;
/**
* default value for enableGroupSeparator.
*
* @default false
*/
enableGroupSeparator?: boolean;
/**
* Options to customize left, right, top and bottom margins of the bullet chart.
*/
margin?: MarginModel;
/**
* Options for customizing comparative bar color bullet chart.
*
* @default 5
*/
targetWidth?: number;
/**
* The stroke color for the comparative measure, which can accept values in hex and rgba as valid CSS color strings.
* This property can also be mapped from the data source.
*
* @default '#191919'
*/
targetColor?: string;
/**
* Options for customizing feature bar height of the bullet chart.
*
* @default 6
*/
valueHeight?: number;
/**
* The stroke color for the feature measure, which can accept values in hex and rgba as valid CSS color strings.
* This property can also be mapped from the data source.
*
* @default null
*/
valueFill?: string;
/**
* Options for customizing the color and width of the feature bar border.
*/
valueBorder?: BorderModel;
/**
* default value of multiple data bullet chart.
*
* @isdatamanager false
* @default null
*/
dataSource?: Object;
/**
* It defines the query for the data source.
*
* @default null
*/
query?: Query;
/**
* It defines the category for the data source.
*
* @default null
*/
categoryField?: string;
/**
* Default type on feature measure.
*
* @default 'Rect'
*/
type?: FeatureType;
/**
* The DataSource field that contains the value value.
*
* @default ''
*/
valueField?: string;
/**
* The DataSource field that contains the target value.
*
* @default ''
*/
targetField?: string;
/**
* The DataSource field that contains the target value.
*
* @default ['Rect', 'Cross', 'Circle']
*/
targetTypes?: TargetType[];
/**
* TabIndex value for the bullet chart.
*
* @default 1
*/
tabIndex?: number;
/**
* Triggers before the bulletchart tooltip is rendered.
*
* @event tooltipRender
*/
tooltipRender?: EmitType<IBulletchartTooltipEventArgs>;
/**
* Triggers before bullet chart load.
*
* @event load
*/
load?: EmitType<IBulletLoadedEventArgs>;
/**
* Triggers after the bullet chart rendering
*
* @event loaded
*/
loaded?: EmitType<IBulletLoadedEventArgs>;
/**
* Triggers on clicking the chart.
*
* @event bulletChartMouseClick
*/
bulletChartMouseClick?: EmitType<IBulletMouseEventArgs>;
/**
* Triggers before the legend is rendered.
*
* @event legendRender
* @deprecated
*/
legendRender?: EmitType<IBulletLegendRenderEventArgs>;
/**
* Triggers before the prints gets started.
*
* @event beforePrint
*/
beforePrint?: EmitType<IPrintEventArgs>;
}