-
-
Notifications
You must be signed in to change notification settings - Fork 29
/
Copy pathrowDetailView.interface.ts
118 lines (86 loc) · 3.47 KB
/
rowDetailView.interface.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
import type { SlickEventData, SlickGrid } from '../core/index.js';
import type { RowDetailViewOption, SlickRowDetailView } from './index.js';
export interface RowDetailView extends RowDetailViewOption {
// --
// Events
/** Fired after extension (plugin) is registered by SlickGrid */
onExtensionRegistered?: (plugin: SlickRowDetailView) => void;
/** This event must be used with the "notify" by the end user once the Asynchronous Server call returns the item detail */
onAsyncResponse?: (e: SlickEventData, args: OnRowDetailAsyncResponseArgs) => void;
/** Fired when the async response finished */
onAsyncEndUpdate?: (e: SlickEventData, args: OnRowDetailAsyncEndUpdateArgs) => void;
/** Fired after the row detail gets toggled */
onAfterRowDetailToggle?: (e: SlickEventData, args: OnAfterRowDetailToggleArgs) => void;
/** Fired before the row detail gets toggled */
onBeforeRowDetailToggle?: (e: SlickEventData, args: OnBeforeRowDetailToggleArgs) => void;
/** Fired after the row detail gets toggled */
onRowBackToViewportRange?: (e: SlickEventData, args: OnRowBackToViewportRangeArgs) => void;
/** Fired after a row becomes out of viewport range (user can't see the row anymore) */
onRowOutOfViewportRange?: (e: SlickEventData, args: OnRowOutOfViewportRangeArgs) => void;
}
/** This event must be used with the "notify" by the end user once the Asynchronous Server call returns the item detail */
export interface OnRowDetailAsyncResponseArgs {
/** Item data context object */
item: any;
/** @alias `item` */
itemDetail: any;
/** An explicit view to use instead of template (Optional) */
detailView?: any;
/** SlickGrid instance */
grid?: SlickGrid;
}
/** Fired when the async response finished */
export interface OnRowDetailAsyncEndUpdateArgs {
/** Item data context object */
item: any;
/** @alias `item` */
itemDetail: any;
/** Reference to the Slick grid object */
grid: SlickGrid;
}
/** Fired after the row detail gets toggled */
export interface OnAfterRowDetailToggleArgs {
/** Item data context object */
item: any;
/** Array of the Expanded Row Ids */
expandedRows: Array<number | string>;
/** Reference to the Slick grid object */
grid: SlickGrid;
}
/** Fired before the row detail gets toggled */
export interface OnBeforeRowDetailToggleArgs {
/** Item data context object */
item: any;
/** Reference to the Slick grid object */
grid: SlickGrid;
}
/** Fired after the row detail gets toggled */
export interface OnRowBackToViewportRangeArgs {
/** Item data context object */
item: any;
/** Id of the Row object (datacontext) in the Grid */
rowId: string | number;
/** Index of the Row in the Grid */
rowIndex: number;
/** Array of the Expanded Row Ids */
expandedRows: Array<number | string>;
/** Array of the Out of viewport Range Rows */
rowIdsOutOfViewport: Array<number | string>;
/** Reference to the Slick grid object */
grid: SlickGrid;
}
/** Fired after a row becomes out of viewport range (user can't see the row anymore) */
export interface OnRowOutOfViewportRangeArgs {
/** Item data context object */
item: any;
/** Id of the Row object (datacontext) in the Grid */
rowId: string | number;
/** Index of the Row in the Grid */
rowIndex: number;
/** Array of the Expanded Row Ids */
expandedRows: Array<number | string>;
/** Array of the Out of viewport Range Rows */
rowIdsOutOfViewport: Array<number | string>;
/** Reference to the Slick grid object */
grid: SlickGrid;
}