dhx-chart 8.4.2 → 8.4.3
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.js +3 -3
- package/codebase/chart.min.js.map +1 -1
- package/codebase/types/ts-data/sources/CollectionStore.d.ts +6 -0
- package/codebase/types/ts-data/sources/datacollection/loader.d.ts +2 -3
- package/codebase/types/ts-data/sources/datacollection.d.ts +2 -3
- package/codebase/types/ts-data/sources/selection.d.ts +1 -1
- package/codebase/types/ts-data/sources/types.d.ts +7 -6
- package/codebase/types/ts-grid/sources/Grid.d.ts +5 -1
- package/codebase/types/ts-grid/sources/ProGrid.d.ts +1 -1
- package/codebase/types/ts-grid/sources/columnsResizer.d.ts +2 -2
- package/codebase/types/ts-grid/sources/helpers/data.d.ts +1 -1
- package/codebase/types/ts-grid/sources/types.d.ts +3 -2
- package/codebase/types/ts-grid/sources/ui/Cells.d.ts +8 -8
- package/codebase/types/ts-grid/sources/ui/common.d.ts +7 -0
- package/codebase/types/ts-grid/sources/ui/editors/TextAreaEditor.d.ts +5 -2
- package/codebase/types/ts-grid/sources/ui/editors/editors.d.ts +2 -2
- package/codebase/types/ts-grid/sources/ui/render.d.ts +1 -7
- package/codebase/types/ts-layout/sources/Cell.d.ts +1 -1
- package/package.json +1 -1
- package/readme.txt +1 -1
- package/whatsnew.txt +3 -0
|
@@ -1,10 +1,9 @@
|
|
|
1
|
-
import {
|
|
2
|
-
import { IDataChangeStack, IDataDriver, IDataProxy, DataDriver } from "../types";
|
|
1
|
+
import { IDataChangeStack, IDataDriver, IDataProxy, IDataCollection, DataDriver } from "../types";
|
|
3
2
|
export declare class Loader {
|
|
4
3
|
private _parent;
|
|
5
4
|
private _saving;
|
|
6
5
|
private _changes;
|
|
7
|
-
constructor(parent:
|
|
6
|
+
constructor(parent: IDataCollection, changes: any);
|
|
8
7
|
load(url: IDataProxy, driver?: IDataDriver | DataDriver): Promise<any>;
|
|
9
8
|
parse(data: any | any[], driver?: IDataDriver | DataDriver): any;
|
|
10
9
|
save(url: IDataProxy): void;
|
|
@@ -2,7 +2,6 @@ import { IEventSystem } from "../../ts-common/events";
|
|
|
2
2
|
import { Id } from "../../ts-common/types";
|
|
3
3
|
import { Sort } from "./datacollection/sort";
|
|
4
4
|
import { DataCallback, DataEvents, IDataCollection, IDataItem, IDataProxy, IFilterCallback, IFilterConfig, IFilterMode, ISortMode, ITreeCollection, IUpdateObject, ReduceCallBack, Statuses, IDataEventsHandlersMap, DataDriver, IDataConfig, ISortConfig, IDataDriver, IFilterComplexMode, IFilter, IResetFilterConfig } from "./types";
|
|
5
|
-
import { TreeCollection } from "./treecollection";
|
|
6
5
|
export declare class DataCollection<T extends IDataItem = IDataItem> implements IDataCollection<T> {
|
|
7
6
|
loadData: Promise<any>;
|
|
8
7
|
saveData: Promise<any>;
|
|
@@ -48,10 +47,10 @@ export declare class DataCollection<T extends IDataItem = IDataItem> implements
|
|
|
48
47
|
findAll(conf: IFilterMode | DataCallback<T>): any[];
|
|
49
48
|
sort(rule?: ISortMode, config?: ISortConfig): void;
|
|
50
49
|
copy(id: Id | Id[], index: number, target?: IDataCollection | ITreeCollection, targetId?: Id): Id | Id[];
|
|
51
|
-
move(id: Id | Id[], index: number, target?:
|
|
50
|
+
move(id: Id | Id[], index: number, target?: IDataCollection | ITreeCollection, targetId?: Id, newId?: Id): Id | Id[];
|
|
52
51
|
forEach(callback: DataCallback<T>): void;
|
|
53
52
|
load(url: IDataProxy | string, driver?: IDataDriver | DataDriver): Promise<any>;
|
|
54
|
-
parse(data: T[], driver?: DataDriver | IDataDriver): any;
|
|
53
|
+
parse(data: T[] | string, driver?: DataDriver | IDataDriver): any;
|
|
55
54
|
$parse(data: any[]): void;
|
|
56
55
|
save(url: IDataProxy | string): void;
|
|
57
56
|
changeId(id: Id, newId?: Id, silent?: boolean): void;
|
|
@@ -6,7 +6,7 @@ export declare class Selection implements ISelection {
|
|
|
6
6
|
config: ISelectionConfig;
|
|
7
7
|
private _selected;
|
|
8
8
|
private _data;
|
|
9
|
-
constructor(config: ISelectionConfig, data
|
|
9
|
+
constructor(config: ISelectionConfig, data: DataCollection, events?: IEventSystem<any>);
|
|
10
10
|
getId(): Id;
|
|
11
11
|
getItem(): any;
|
|
12
12
|
remove(id?: Id): boolean;
|
|
@@ -1,12 +1,10 @@
|
|
|
1
1
|
import { IEventSystem } from "../../ts-common/events";
|
|
2
|
-
import { DataCollection } from "./datacollection";
|
|
3
|
-
import { TreeCollection } from "./treecollection";
|
|
4
2
|
import { anyFunction, IAnyObj, Id } from "../../ts-common/types";
|
|
5
3
|
export interface IDataProxy {
|
|
6
4
|
url: string;
|
|
7
5
|
config?: any;
|
|
8
6
|
updateUrl?: (url?: string, params?: any) => void;
|
|
9
|
-
load?: () => Promise<any[] | void>;
|
|
7
|
+
load?: () => Promise<any[] | string | void>;
|
|
10
8
|
save?: (data: any, mode: string) => Promise<any>;
|
|
11
9
|
}
|
|
12
10
|
export interface ILazyDataProxy extends IDataProxy {
|
|
@@ -74,6 +72,7 @@ export interface IDataConfig {
|
|
|
74
72
|
approximate?: IApproximate;
|
|
75
73
|
autoload?: string;
|
|
76
74
|
collapsed?: boolean;
|
|
75
|
+
rootId?: Id;
|
|
77
76
|
}
|
|
78
77
|
export interface IDataCollection<T extends IDataItem = IDataItem> {
|
|
79
78
|
config: IDataConfig;
|
|
@@ -82,7 +81,8 @@ export interface IDataCollection<T extends IDataItem = IDataItem> {
|
|
|
82
81
|
loadData: Promise<any>;
|
|
83
82
|
saveData: Promise<any>;
|
|
84
83
|
load(url: IDataProxy | string, driver?: IDataDriver | DataDriver): Promise<any>;
|
|
85
|
-
parse(data: T[], driver?: DataDriver | IDataDriver): void;
|
|
84
|
+
parse(data: T[] | string, driver?: DataDriver | IDataDriver): void;
|
|
85
|
+
$parse(data: any[]): void;
|
|
86
86
|
add(newItem: IDataItem, index?: number): Id;
|
|
87
87
|
add(newItem: IDataItem[], index?: number): Id[];
|
|
88
88
|
add(newItem: IDataItem | IDataItem[], index?: number): Id | Id[];
|
|
@@ -112,7 +112,7 @@ export interface IDataCollection<T extends IDataItem = IDataItem> {
|
|
|
112
112
|
sort(rule?: ISortMode, config?: ISortConfig): void;
|
|
113
113
|
serialize(driver?: DataDriver): T[];
|
|
114
114
|
copy(id: Id | Id[], index: number, target?: IDataCollection | ITreeCollection, targetId?: Id): Id | Id[];
|
|
115
|
-
move(id: Id | Id[], index: number, target?:
|
|
115
|
+
move(id: Id | Id[], index: number, target?: IDataCollection | ITreeCollection, targetId?: Id): Id | Id[];
|
|
116
116
|
changeId(id: Id, newId?: Id, silent?: boolean): void;
|
|
117
117
|
forEach(callback: DataCallback<T>): void;
|
|
118
118
|
save(url: IDataProxy | string): void;
|
|
@@ -194,7 +194,8 @@ export interface IDataItem {
|
|
|
194
194
|
}
|
|
195
195
|
export type DropPosition = "top" | "bottom" | "in";
|
|
196
196
|
export interface IObjWithData {
|
|
197
|
-
|
|
197
|
+
name?: string;
|
|
198
|
+
data: ITreeCollection | IDataCollection;
|
|
198
199
|
events: IEventSystem<DragEvents, IDragEventsHandlersMap>;
|
|
199
200
|
config: IDragConfig;
|
|
200
201
|
id?: Id;
|
|
@@ -7,6 +7,7 @@ import { Exporter } from "./Exporter";
|
|
|
7
7
|
import { Dirs, EditorType, GridEvents, IAdjustBy, ICellRect, ICol, IContentList, ICoords, IEventHandlersMap, IGrid, IGridConfig, IRow, IScrollState, ISelection, ISpan, GridSystemEvents, ISystemEventHandlersMap, IColumnsWidth, ISortingState, SortFunction, IHeaderFilter, IAdjustColumns, IFooter, IHeader, INormalizeColumnsParams } from "./types";
|
|
8
8
|
export declare class Grid extends View implements IGrid {
|
|
9
9
|
version: string;
|
|
10
|
+
name: "grid";
|
|
10
11
|
data: IDataCollection;
|
|
11
12
|
config: IGridConfig;
|
|
12
13
|
events: IEventSystem<DataEvents | GridEvents | DragEvents, IEventHandlersMap & IDataEventsHandlersMap & IDragEventsHandlersMap>;
|
|
@@ -69,7 +70,10 @@ export declare class Grid extends View implements IGrid {
|
|
|
69
70
|
protected _checkSelectFilterValue(): void;
|
|
70
71
|
protected _clearFilterValue(allCols?: boolean): void;
|
|
71
72
|
protected _adjustColumns(): void;
|
|
72
|
-
protected _prepareData(data: IDataItem[] | IDataCollection):
|
|
73
|
+
protected _prepareData(data: IDataItem[] | IDataCollection): IDataItem[] | {
|
|
74
|
+
$height: number;
|
|
75
|
+
id?: Id;
|
|
76
|
+
}[];
|
|
73
77
|
protected _adjustColumnsWidth({ rows, cols, adjust, }: IAdjustColumns): IColumnsWidth;
|
|
74
78
|
protected _prepareColumnData(data: any, type: "header" | "footer"): IRow[];
|
|
75
79
|
protected _dragStart(event: any): void;
|
|
@@ -1,7 +1,7 @@
|
|
|
1
|
-
import { Grid } from "./Grid";
|
|
2
1
|
import { IGridConfig, ICol, IRow, IProGrid, IFooter, IHeader } from "./types";
|
|
3
2
|
import { IDataCollection, IDataItem } from "../../ts-data";
|
|
4
3
|
import { ScrollView } from "../../ts-common/ScrollView";
|
|
4
|
+
import { Grid } from "./Grid";
|
|
5
5
|
export declare class ProGrid extends Grid implements IProGrid {
|
|
6
6
|
scrollView: ScrollView;
|
|
7
7
|
constructor(container: HTMLElement | string, config?: IGridConfig);
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import {
|
|
2
|
-
export declare function startResize(grid:
|
|
1
|
+
import { IGrid } from "./types";
|
|
2
|
+
export declare function startResize(grid: IGrid, column: string, ev: MouseEvent & TouchEvent, cb: any): void;
|
|
@@ -21,7 +21,7 @@ export declare const getCalculatedRowHeight: (height: number, config?: {
|
|
|
21
21
|
rowHeight: number;
|
|
22
22
|
padding?: number;
|
|
23
23
|
}) => number;
|
|
24
|
-
export declare const getTreeCellWidthOffset: (row: IRow) => number;
|
|
24
|
+
export declare const getTreeCellWidthOffset: (row: IRow, toArrow?: boolean) => number;
|
|
25
25
|
export declare const getMaxColsWidth: (rows: IRow[], cols: ICol[], config?: IContainerConfig, target?: AdjustTargetType) => IColumnsWidth;
|
|
26
26
|
export declare function toFormat(value: any, type?: colType, format?: string): any;
|
|
27
27
|
export declare function getEditorOptions(col: ICol, row?: IRow): TOption[];
|
|
@@ -3,7 +3,6 @@ import { IKeyManager } from "../../ts-common/KeyManager";
|
|
|
3
3
|
import { IAlign } from "../../ts-common/html";
|
|
4
4
|
import { Position } from "../../ts-message";
|
|
5
5
|
import { IDataCollection, IDragConfig, ICsvDriverConfig, IDataItem, IDragInfo, DataCollection } from "../../ts-data";
|
|
6
|
-
import { Exporter } from "./Exporter";
|
|
7
6
|
import { Combobox } from "../../ts-combobox";
|
|
8
7
|
import { IHandlers, Id } from "../../ts-common/types";
|
|
9
8
|
import { ScrollView } from "../../ts-common/ScrollView";
|
|
@@ -145,7 +144,8 @@ export interface ISortingState {
|
|
|
145
144
|
}
|
|
146
145
|
export interface IGrid {
|
|
147
146
|
data: IDataCollection;
|
|
148
|
-
export:
|
|
147
|
+
export: any;
|
|
148
|
+
name: "grid";
|
|
149
149
|
config: IGridConfig;
|
|
150
150
|
events: IEventSystem<GridEvents, IEventHandlersMap>;
|
|
151
151
|
selection: ISelection;
|
|
@@ -178,6 +178,7 @@ export interface IGrid {
|
|
|
178
178
|
editEnd(withoutSave?: boolean): void;
|
|
179
179
|
getSortingState(): ISortingState;
|
|
180
180
|
getHeaderFilter(colId: Id): IHeaderFilter;
|
|
181
|
+
getRootNode(): HTMLElement;
|
|
181
182
|
/** @deprecated See a documentation: https://docs.dhtmlx.com/ */
|
|
182
183
|
edit(rowId: Id, colId: Id, editorType?: EditorType): void;
|
|
183
184
|
}
|
|
@@ -4,14 +4,14 @@ type mouseEvents = GridEvents.cellClick | GridEvents.cellMouseOver | GridEvents.
|
|
|
4
4
|
type touchEvents = GridSystemEvents.cellTouchEnd | GridSystemEvents.cellTouchMove;
|
|
5
5
|
declare function handleMouse(rowStart: number, colStart: number, conf: IRendererConfig, type: mouseEvents & touchEvents, e: any): void;
|
|
6
6
|
export declare function getHandlers(row: number, column: number, conf: IRendererConfig): {
|
|
7
|
-
onclick: (number |
|
|
8
|
-
onmouseover: (number |
|
|
9
|
-
onmousedown: (number |
|
|
10
|
-
ondblclick: (number |
|
|
11
|
-
oncontextmenu: (number |
|
|
12
|
-
ontouchstart: (number |
|
|
13
|
-
ontouchmove: (number |
|
|
14
|
-
ontouchend: (number |
|
|
7
|
+
onclick: (number | GridEvents | IRendererConfig | typeof handleMouse)[];
|
|
8
|
+
onmouseover: (number | GridEvents | IRendererConfig | typeof handleMouse)[];
|
|
9
|
+
onmousedown: (number | GridEvents | IRendererConfig | typeof handleMouse)[];
|
|
10
|
+
ondblclick: (number | GridEvents | IRendererConfig | typeof handleMouse)[];
|
|
11
|
+
oncontextmenu: (number | GridEvents | IRendererConfig | typeof handleMouse)[];
|
|
12
|
+
ontouchstart: (number | GridEvents | IRendererConfig | typeof handleMouse)[];
|
|
13
|
+
ontouchmove: (number | GridSystemEvents | IRendererConfig | typeof handleMouse)[];
|
|
14
|
+
ontouchend: (number | GridSystemEvents | IRendererConfig | typeof handleMouse)[];
|
|
15
15
|
};
|
|
16
16
|
export declare function getTreeCell(content: any, row: any, col: ICol, conf: IRendererConfig): any;
|
|
17
17
|
export declare function getCells(conf: IRendererConfig): any[];
|
|
@@ -0,0 +1,7 @@
|
|
|
1
|
+
import { IGridConfig, IRendererConfig, IScrollBarWidth, Split } from "../types";
|
|
2
|
+
export declare const BORDERS = 2;
|
|
3
|
+
export declare function calcScrollBarWidth(config: IGridConfig | IRendererConfig, customScroll?: boolean, sizes?: {
|
|
4
|
+
width: number;
|
|
5
|
+
height: number;
|
|
6
|
+
}): IScrollBarWidth;
|
|
7
|
+
export declare function getCurrFixedCols(config: IGridConfig, split: Split.left | Split.right): import("../types").ICol[];
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { ICol, IRendererConfig, IRow, IEditor } from "../../types";
|
|
1
|
+
import { ICol, IRendererConfig, IRow, IEditor, ISpan } from "../../types";
|
|
2
2
|
export declare class TextAreaEditor implements IEditor {
|
|
3
3
|
protected _handlers: {
|
|
4
4
|
[key: string]: (...args: any[]) => void;
|
|
@@ -13,10 +13,13 @@ export declare class TextAreaEditor implements IEditor {
|
|
|
13
13
|
private _minHeight;
|
|
14
14
|
private _prevHeight;
|
|
15
15
|
private _width;
|
|
16
|
-
|
|
16
|
+
private _initialValue;
|
|
17
|
+
constructor(row: IRow, col: ICol, config: IRendererConfig, span?: ISpan);
|
|
17
18
|
endEdit(withoutSave?: boolean): void;
|
|
18
19
|
toHTML(value?: string): any;
|
|
19
20
|
protected _initHandlers(): void;
|
|
20
21
|
private _getCurrentHeight;
|
|
21
22
|
private _getElementHeight;
|
|
23
|
+
private _getCellWidth;
|
|
24
|
+
private _updateHeight;
|
|
22
25
|
}
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import { IRendererConfig, ICol, IEditor } from "../../types";
|
|
2
|
-
export declare function getEditor(row: any, col: ICol, conf: IRendererConfig): IEditor;
|
|
1
|
+
import { IRendererConfig, ICol, IEditor, ISpan } from "../../types";
|
|
2
|
+
export declare function getEditor(row: any, col: ICol, conf: IRendererConfig, span?: ISpan): IEditor;
|
|
@@ -1,10 +1,4 @@
|
|
|
1
|
-
import { IGrid, IGridConfig, IProGrid, IRendererConfig, IRow
|
|
2
|
-
export declare const BORDERS = 2;
|
|
3
|
-
export declare function calcScrollBarWidth(config: IGridConfig | IRendererConfig, customScroll?: boolean, sizes?: {
|
|
4
|
-
width: number;
|
|
5
|
-
height: number;
|
|
6
|
-
}): IScrollBarWidth;
|
|
7
|
-
export declare function getCurrFixedCols(config: IGridConfig, split: Split.left | Split.right): ICol[];
|
|
1
|
+
import { IGrid, IGridConfig, IProGrid, IRendererConfig, IRow } from "../types";
|
|
8
2
|
export declare function getRenderConfig(obj: any, data: IRow[], wrapperSizes: any): IRendererConfig;
|
|
9
3
|
export declare function getElementSizes(element: HTMLElement | any): {
|
|
10
4
|
width: number;
|
|
@@ -44,7 +44,7 @@ export declare class Cell extends View implements ICell {
|
|
|
44
44
|
protected _getCss(_content?: boolean): string;
|
|
45
45
|
protected _initHandlers(): void;
|
|
46
46
|
protected _getCollapsedSize(cell: ICell, nextCell: ICell): number;
|
|
47
|
-
protected _getCollapseIcon(): "dxi dxi-chevron-
|
|
47
|
+
protected _getCollapseIcon(): "dxi dxi-chevron-right" | "dxi dxi-chevron-left" | "dxi dxi-chevron-up" | "dxi dxi-chevron-down";
|
|
48
48
|
protected _isLastCell(): boolean;
|
|
49
49
|
protected _getNextCell(): any;
|
|
50
50
|
protected _getAnyFlexCell(selfInclude?: boolean): any;
|
package/package.json
CHANGED
package/readme.txt
CHANGED