dhx-chart 8.1.4 → 8.1.6
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/codebase/chart.min.css +1 -1
- package/codebase/chart.min.js +3 -3
- package/codebase/types/ts-combobox/sources/Combobox.d.ts +2 -2
- package/codebase/types/ts-combobox/sources/types.d.ts +2 -2
- package/codebase/types/ts-grid/sources/Grid.d.ts +5 -0
- package/codebase/types/ts-grid/sources/types.d.ts +11 -10
- package/codebase/types/ts-grid/sources/ui/Cells.d.ts +1 -0
- package/codebase/types/ts-grid/sources/ui/render.d.ts +5 -0
- package/codebase/types/ts-layout/sources/helpers.d.ts +1 -1
- package/package.json +1 -1
- package/readme.txt +1 -1
- package/whatsnew.txt +6 -0
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import { VNode } from "../../ts-common/dom";
|
|
2
2
|
import { IEventSystem } from "../../ts-common/events";
|
|
3
3
|
import { View } from "../../ts-common/view";
|
|
4
|
-
import { DataCollection, DataEvents, IDataEventsHandlersMap } from "../../ts-data";
|
|
4
|
+
import { DataCollection, DataEvents, IDataEventsHandlersMap, IDataItem } from "../../ts-data";
|
|
5
5
|
import { Layout } from "../../ts-layout";
|
|
6
6
|
import { List } from "../../ts-list";
|
|
7
7
|
import { Popup } from "../../ts-popup";
|
|
@@ -29,7 +29,7 @@ export declare class Combobox extends View implements ICombobox {
|
|
|
29
29
|
clear(): void | boolean;
|
|
30
30
|
getValue<T extends boolean = false>(asArray?: T): T extends true ? Id[] : Id;
|
|
31
31
|
setValue(ids: Id[] | Id): void | boolean;
|
|
32
|
-
addOption(value: string, join?: boolean): void;
|
|
32
|
+
addOption<T extends IDataItem>(value: T | string, join?: boolean): void;
|
|
33
33
|
destructor(): void;
|
|
34
34
|
/** @deprecated See a documentation: https://docs.dhtmlx.com/ */
|
|
35
35
|
setState(state: State): void;
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { Id } from "../../ts-common/types";
|
|
2
|
-
import { DataCollection } from "../../ts-data";
|
|
2
|
+
import { DataCollection, IDataItem } from "../../ts-data";
|
|
3
3
|
export declare type ILabelPosition = "left" | "top";
|
|
4
4
|
export interface IComboboxConfig {
|
|
5
5
|
data?: DataCollection<any> | any[];
|
|
@@ -77,7 +77,7 @@ export interface ICombobox {
|
|
|
77
77
|
blur(): void;
|
|
78
78
|
getValue(asArray?: boolean): Id[] | Id;
|
|
79
79
|
setValue(ids: Id[] | Id): void;
|
|
80
|
-
addOption(value: string, join?: boolean): void;
|
|
80
|
+
addOption<T extends IDataItem>(value: T | string, join?: boolean): void;
|
|
81
81
|
/** @deprecated See a documentation: https://docs.dhtmlx.com/ */
|
|
82
82
|
setState(state: State): void;
|
|
83
83
|
}
|
|
@@ -68,6 +68,10 @@ export declare class Grid extends View implements IGrid {
|
|
|
68
68
|
protected _prepareColumnData(data: any, type: "header" | "footer"): IRow[];
|
|
69
69
|
protected _dragStart(event: any): void;
|
|
70
70
|
protected _getRowGhost(ids: Id[]): HTMLDivElement;
|
|
71
|
+
protected _initHooks(): {
|
|
72
|
+
didMount: () => void;
|
|
73
|
+
};
|
|
74
|
+
private _canDataParse;
|
|
71
75
|
private _init;
|
|
72
76
|
private _attachDataCollection;
|
|
73
77
|
private _setMarks;
|
|
@@ -78,5 +82,6 @@ export declare class Grid extends View implements IGrid {
|
|
|
78
82
|
private _render;
|
|
79
83
|
private _initHotKey;
|
|
80
84
|
private _normalizeConfig;
|
|
85
|
+
private _normalizeSpans;
|
|
81
86
|
private _autoScroll;
|
|
82
87
|
}
|
|
@@ -216,7 +216,7 @@ export interface ICol {
|
|
|
216
216
|
editable?: boolean;
|
|
217
217
|
resizable?: boolean;
|
|
218
218
|
sortable?: boolean;
|
|
219
|
-
options?: (col: ICol, row?: IRow) => TOption[] | TOption[];
|
|
219
|
+
options?: ((col: ICol, row?: IRow) => TOption[]) | TOption[];
|
|
220
220
|
draggable?: boolean;
|
|
221
221
|
htmlEnable?: boolean;
|
|
222
222
|
template?: (cellValue: any, row: IRow, col: ICol) => string;
|
|
@@ -247,19 +247,24 @@ export interface ICol {
|
|
|
247
247
|
fitToContainer?: boolean;
|
|
248
248
|
}
|
|
249
249
|
export declare type fixedRowContent = "inputFilter" | "selectFilter" | "comboFilter";
|
|
250
|
-
export declare type footerMethods = "avg" | "sum" | "max" | "min";
|
|
251
|
-
export interface
|
|
250
|
+
export declare type footerMethods = "avg" | "sum" | "max" | "min" | "count";
|
|
251
|
+
export interface IContent {
|
|
252
252
|
text?: string;
|
|
253
253
|
colspan?: number;
|
|
254
254
|
rowspan?: number;
|
|
255
|
-
css?:
|
|
255
|
+
css?: string;
|
|
256
|
+
align?: IAlign;
|
|
257
|
+
}
|
|
258
|
+
export interface IHeader extends IContent {
|
|
256
259
|
content?: fixedRowContent | footerMethods;
|
|
257
260
|
filterConfig?: IComboFilterConfig;
|
|
258
261
|
customFilter?: (item: any, input: string) => boolean;
|
|
259
|
-
align?: IAlign;
|
|
260
262
|
headerSort?: boolean;
|
|
261
263
|
sortAs?: SortFunction;
|
|
262
264
|
}
|
|
265
|
+
export interface IFooter extends IContent {
|
|
266
|
+
content?: footerMethods;
|
|
267
|
+
}
|
|
263
268
|
export interface IComboFilterConfig {
|
|
264
269
|
data?: DataCollection<any> | any[];
|
|
265
270
|
readonly?: boolean;
|
|
@@ -270,11 +275,6 @@ export interface IComboFilterConfig {
|
|
|
270
275
|
multiselection?: boolean;
|
|
271
276
|
}
|
|
272
277
|
export declare type SortFunction = (cellValue: any) => string | number;
|
|
273
|
-
export interface IFooter {
|
|
274
|
-
text?: string | number;
|
|
275
|
-
css?: any;
|
|
276
|
-
content?: fixedRowContent | footerMethods;
|
|
277
|
-
}
|
|
278
278
|
export interface ISpan {
|
|
279
279
|
row: Id;
|
|
280
280
|
column: Id;
|
|
@@ -285,6 +285,7 @@ export interface ISpan {
|
|
|
285
285
|
tooltip?: boolean;
|
|
286
286
|
tooltipTemplate?: (spanValue: any, span: ISpan) => string;
|
|
287
287
|
$markCss?: string;
|
|
288
|
+
$type?: colType;
|
|
288
289
|
}
|
|
289
290
|
declare type MarkFunction = (cell: any, columnCells: any[], row: IRow, column: ICol) => string;
|
|
290
291
|
export interface IMark {
|
|
@@ -18,6 +18,7 @@ export declare function getSpans(config: IRendererConfig, mode?: Split): any[];
|
|
|
18
18
|
export declare function getShifts(conf: IRendererConfig): ICoords;
|
|
19
19
|
export declare function normalizeSpan(span: ISpan, config: IGridConfig): {
|
|
20
20
|
$renderFrom: string[];
|
|
21
|
+
$type: any;
|
|
21
22
|
row: import("../../../ts-common/types").Id;
|
|
22
23
|
column: import("../../../ts-common/types").Id;
|
|
23
24
|
rowspan?: number;
|
|
@@ -6,6 +6,11 @@ export declare function calcScrollBarWidth(config: IGridConfig | IRendererConfig
|
|
|
6
6
|
}): IScrollBarWidth;
|
|
7
7
|
export declare function getCurrFixedCols(config: IGridConfig, split: Split.left | Split.right): import("../types").ICol[];
|
|
8
8
|
export declare function getRenderConfig(obj: any, data: IRow[], wrapperSizes: any): IRendererConfig;
|
|
9
|
+
export declare function getElementSizes(element: HTMLElement | any): {
|
|
10
|
+
width: number;
|
|
11
|
+
height: number;
|
|
12
|
+
};
|
|
9
13
|
export declare function getEvents(config: IRendererConfig, mode?: Split): {};
|
|
14
|
+
export declare function applyAutoWidth(config: IGridConfig, wrapperSizes: any, firstApply?: boolean, resizer?: boolean, scrollViewConfig?: boolean): void;
|
|
10
15
|
export declare function render(vm: any, obj: IGrid, htmlEvents: any, selection: any, uid: string): any;
|
|
11
16
|
export declare function proRender(vm: any, obj: IProGrid, htmlEvents: any, selection: any, uid: string): any;
|
package/package.json
CHANGED
package/readme.txt
CHANGED