dhx-suite 8.4.2 → 8.4.4
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/suite.min.css +1 -1
- package/codebase/suite.min.js +3 -3
- package/codebase/suite.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 +1 -0
- 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/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/package.json +1 -1
- package/readme.txt +1 -1
- package/whatsnew.txt +17 -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>;
|
|
@@ -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
|
}
|
|
@@ -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;
|
package/package.json
CHANGED
package/readme.txt
CHANGED
package/whatsnew.txt
CHANGED
|
@@ -1,3 +1,20 @@
|
|
|
1
|
+
# Version 8.4.4 (September 16, 2024)
|
|
2
|
+
|
|
3
|
+
### Fixes
|
|
4
|
+
|
|
5
|
+
- Grid. Data is not displayed in the non-PRO version
|
|
6
|
+
|
|
7
|
+
# Version 8.4.3 (September 10, 2024)
|
|
8
|
+
|
|
9
|
+
### Fixes
|
|
10
|
+
|
|
11
|
+
- Grid/TreeGrid. Incorrect span editing
|
|
12
|
+
- Grid/TreeGrid. The callback of the `dragRowIn` event is called with the source id instead of the target id
|
|
13
|
+
- Grid/TreeGrid. Incorrect rendering of header/footer spans
|
|
14
|
+
- Grid/TreeGrid. Canceling editing of a cell in the enabled `autoHeight` mode doesn't revert the value of a cell to the initial state
|
|
15
|
+
- Grid/TreeGrid. The `beforeColumnDrop` event fires after dragging rows
|
|
16
|
+
- Grid/TreeGrid. The `height` property set as a string breaks rendering of the component
|
|
17
|
+
|
|
1
18
|
# Version 8.4.2 (August 29, 2024)
|
|
2
19
|
|
|
3
20
|
### Fixes
|