@dhtmlx/vault 5.0.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.
Files changed (175) hide show
  1. package/README.md +251 -0
  2. package/codebase/fonts/roboto-bold-webfont.woff +0 -0
  3. package/codebase/fonts/roboto-bold-webfont.woff2 +0 -0
  4. package/codebase/fonts/roboto-medium-webfont.woff +0 -0
  5. package/codebase/fonts/roboto-medium-webfont.woff2 +0 -0
  6. package/codebase/fonts/roboto-regular-webfont.woff +0 -0
  7. package/codebase/fonts/roboto-regular-webfont.woff2 +0 -0
  8. package/codebase/types/ts-calendar/index.d.ts +2 -0
  9. package/codebase/types/ts-calendar/sources/Calendar.d.ts +37 -0
  10. package/codebase/types/ts-calendar/sources/helper.d.ts +1 -0
  11. package/codebase/types/ts-calendar/sources/types.d.ts +64 -0
  12. package/codebase/types/ts-combobox/index.d.ts +3 -0
  13. package/codebase/types/ts-combobox/sources/Combobox.d.ts +53 -0
  14. package/codebase/types/ts-combobox/sources/ProCombobox.d.ts +6 -0
  15. package/codebase/types/ts-combobox/sources/helper.d.ts +4 -0
  16. package/codebase/types/ts-combobox/sources/keyListener.d.ts +14 -0
  17. package/codebase/types/ts-combobox/sources/locales/en.d.ts +8 -0
  18. package/codebase/types/ts-combobox/sources/types.d.ts +95 -0
  19. package/codebase/types/ts-common/FocusManager.d.ts +15 -0
  20. package/codebase/types/ts-common/KeyManager.d.ts +19 -0
  21. package/codebase/types/ts-common/ScrollView.d.ts +40 -0
  22. package/codebase/types/ts-common/core.d.ts +40 -0
  23. package/codebase/types/ts-common/date.d.ts +34 -0
  24. package/codebase/types/ts-common/dom.d.ts +24 -0
  25. package/codebase/types/ts-common/events.d.ts +35 -0
  26. package/codebase/types/ts-common/html.d.ts +74 -0
  27. package/codebase/types/ts-common/input.d.ts +24 -0
  28. package/codebase/types/ts-common/keycodes.d.ts +9 -0
  29. package/codebase/types/ts-common/locale.d.ts +1 -0
  30. package/codebase/types/ts-common/polyfills/array.d.ts +0 -0
  31. package/codebase/types/ts-common/polyfills/element.d.ts +0 -0
  32. package/codebase/types/ts-common/polyfills/fetch.d.ts +0 -0
  33. package/codebase/types/ts-common/polyfills/math.d.ts +0 -0
  34. package/codebase/types/ts-common/polyfills/object.d.ts +0 -0
  35. package/codebase/types/ts-common/polyfills/string.d.ts +0 -0
  36. package/codebase/types/ts-common/types.d.ts +76 -0
  37. package/codebase/types/ts-common/view.d.ts +27 -0
  38. package/codebase/types/ts-data/index.d.ts +13 -0
  39. package/codebase/types/ts-data/sources/CollectionStore.d.ts +7 -0
  40. package/codebase/types/ts-data/sources/DragManager.d.ts +19 -0
  41. package/codebase/types/ts-data/sources/ajax.d.ts +2 -0
  42. package/codebase/types/ts-data/sources/datacollection/group.d.ts +43 -0
  43. package/codebase/types/ts-data/sources/datacollection/loader.d.ts +16 -0
  44. package/codebase/types/ts-data/sources/datacollection/sort.d.ts +7 -0
  45. package/codebase/types/ts-data/sources/datacollection.d.ts +101 -0
  46. package/codebase/types/ts-data/sources/dataproxy.d.ts +10 -0
  47. package/codebase/types/ts-data/sources/drivers/CsvDriver.d.ts +16 -0
  48. package/codebase/types/ts-data/sources/drivers/JsonDriver.d.ts +10 -0
  49. package/codebase/types/ts-data/sources/drivers/XMLDriver.d.ts +18 -0
  50. package/codebase/types/ts-data/sources/drivers/drivers.d.ts +12 -0
  51. package/codebase/types/ts-data/sources/helpers.d.ts +17 -0
  52. package/codebase/types/ts-data/sources/lazydataproxy.d.ts +9 -0
  53. package/codebase/types/ts-data/sources/methods.d.ts +11 -0
  54. package/codebase/types/ts-data/sources/selection.d.ts +17 -0
  55. package/codebase/types/ts-data/sources/serializers/xml.d.ts +2 -0
  56. package/codebase/types/ts-data/sources/treecollection.d.ts +72 -0
  57. package/codebase/types/ts-data/sources/types.d.ts +340 -0
  58. package/codebase/types/ts-dataview/index.d.ts +3 -0
  59. package/codebase/types/ts-dataview/sources/DataView.d.ts +41 -0
  60. package/codebase/types/ts-dataview/sources/ProDataView.d.ts +11 -0
  61. package/codebase/types/ts-dataview/sources/editors/InputEditor.d.ts +16 -0
  62. package/codebase/types/ts-dataview/sources/editors/editors.d.ts +4 -0
  63. package/codebase/types/ts-dataview/sources/types.d.ts +63 -0
  64. package/codebase/types/ts-grid/index.d.ts +7 -0
  65. package/codebase/types/ts-grid/sources/ExtendedGrid.d.ts +47 -0
  66. package/codebase/types/ts-grid/sources/Grid.d.ts +114 -0
  67. package/codebase/types/ts-grid/sources/ProGrid.d.ts +67 -0
  68. package/codebase/types/ts-grid/sources/helpers/cells.d.ts +9 -0
  69. package/codebase/types/ts-grid/sources/helpers/data.d.ts +36 -0
  70. package/codebase/types/ts-grid/sources/helpers/default.d.ts +6 -0
  71. package/codebase/types/ts-grid/sources/helpers/dom.d.ts +3 -0
  72. package/codebase/types/ts-grid/sources/helpers/keys.d.ts +27 -0
  73. package/codebase/types/ts-grid/sources/helpers/main.d.ts +23 -0
  74. package/codebase/types/ts-grid/sources/locales/en.d.ts +7 -0
  75. package/codebase/types/ts-grid/sources/modules/BlockSelection.d.ts +122 -0
  76. package/codebase/types/ts-grid/sources/modules/Clipboard.d.ts +55 -0
  77. package/codebase/types/ts-grid/sources/modules/DropManager.d.ts +21 -0
  78. package/codebase/types/ts-grid/sources/modules/Exporter.d.ts +80 -0
  79. package/codebase/types/ts-grid/sources/modules/History.d.ts +72 -0
  80. package/codebase/types/ts-grid/sources/modules/Range.d.ts +71 -0
  81. package/codebase/types/ts-grid/sources/modules/Resizer.d.ts +2 -0
  82. package/codebase/types/ts-grid/sources/modules/Selection.d.ts +58 -0
  83. package/codebase/types/ts-grid/sources/types.d.ts +660 -0
  84. package/codebase/types/ts-grid/sources/ui/FixedCols.d.ts +3 -0
  85. package/codebase/types/ts-grid/sources/ui/FixedRows.d.ts +5 -0
  86. package/codebase/types/ts-grid/sources/ui/cells.d.ts +34 -0
  87. package/codebase/types/ts-grid/sources/ui/common.d.ts +8 -0
  88. package/codebase/types/ts-grid/sources/ui/components/dragPanel.d.ts +7 -0
  89. package/codebase/types/ts-grid/sources/ui/components/groupPanel.d.ts +13 -0
  90. package/codebase/types/ts-grid/sources/ui/components/subRow.d.ts +4 -0
  91. package/codebase/types/ts-grid/sources/ui/content/ComboFilter.d.ts +35 -0
  92. package/codebase/types/ts-grid/sources/ui/content/DateFilter.d.ts +42 -0
  93. package/codebase/types/ts-grid/sources/ui/content/InputFilter.d.ts +32 -0
  94. package/codebase/types/ts-grid/sources/ui/content/SelectFilter.d.ts +28 -0
  95. package/codebase/types/ts-grid/sources/ui/content.d.ts +55 -0
  96. package/codebase/types/ts-grid/sources/ui/editors/CheckboxEditor.d.ts +18 -0
  97. package/codebase/types/ts-grid/sources/ui/editors/ComboboxEditor.d.ts +18 -0
  98. package/codebase/types/ts-grid/sources/ui/editors/DateEditor.d.ts +37 -0
  99. package/codebase/types/ts-grid/sources/ui/editors/InputEditor.d.ts +22 -0
  100. package/codebase/types/ts-grid/sources/ui/editors/SelectEditor.d.ts +16 -0
  101. package/codebase/types/ts-grid/sources/ui/editors/TextAreaEditor.d.ts +27 -0
  102. package/codebase/types/ts-grid/sources/ui/editors/editors.d.ts +2 -0
  103. package/codebase/types/ts-grid/sources/ui/proContent.d.ts +37 -0
  104. package/codebase/types/ts-grid/sources/ui/render.d.ts +9 -0
  105. package/codebase/types/ts-layout/index.d.ts +3 -0
  106. package/codebase/types/ts-layout/sources/Cell.d.ts +60 -0
  107. package/codebase/types/ts-layout/sources/Layout.d.ts +29 -0
  108. package/codebase/types/ts-layout/sources/ProCell.d.ts +9 -0
  109. package/codebase/types/ts-layout/sources/ProLayout.d.ts +6 -0
  110. package/codebase/types/ts-layout/sources/helpers.d.ts +6 -0
  111. package/codebase/types/ts-layout/sources/types.d.ts +129 -0
  112. package/codebase/types/ts-list/index.d.ts +4 -0
  113. package/codebase/types/ts-list/sources/List.d.ts +56 -0
  114. package/codebase/types/ts-list/sources/ProList.d.ts +11 -0
  115. package/codebase/types/ts-list/sources/Selection.d.ts +24 -0
  116. package/codebase/types/ts-list/sources/editors/InputEditor.d.ts +16 -0
  117. package/codebase/types/ts-list/sources/editors/editors.d.ts +4 -0
  118. package/codebase/types/ts-list/sources/types.d.ts +98 -0
  119. package/codebase/types/ts-message/index.d.ts +5 -0
  120. package/codebase/types/ts-message/sources/alert.d.ts +2 -0
  121. package/codebase/types/ts-message/sources/common.d.ts +1 -0
  122. package/codebase/types/ts-message/sources/confirm.d.ts +2 -0
  123. package/codebase/types/ts-message/sources/locales/en.d.ts +5 -0
  124. package/codebase/types/ts-message/sources/message.d.ts +4 -0
  125. package/codebase/types/ts-message/sources/tooltip.d.ts +6 -0
  126. package/codebase/types/ts-message/sources/types.d.ts +79 -0
  127. package/codebase/types/ts-navbar/index.d.ts +3 -0
  128. package/codebase/types/ts-navbar/sources/Navbar.d.ts +61 -0
  129. package/codebase/types/ts-navbar/sources/elements/button.d.ts +1 -0
  130. package/codebase/types/ts-navbar/sources/elements/customHTMLButton.d.ts +1 -0
  131. package/codebase/types/ts-navbar/sources/elements/datePicker.d.ts +1 -0
  132. package/codebase/types/ts-navbar/sources/elements/helpers.d.ts +17 -0
  133. package/codebase/types/ts-navbar/sources/elements/imageButton.d.ts +1 -0
  134. package/codebase/types/ts-navbar/sources/elements/input.d.ts +1 -0
  135. package/codebase/types/ts-navbar/sources/elements/menuItem.d.ts +1 -0
  136. package/codebase/types/ts-navbar/sources/elements/navItem.d.ts +1 -0
  137. package/codebase/types/ts-navbar/sources/elements/separator.d.ts +1 -0
  138. package/codebase/types/ts-navbar/sources/elements/spacer.d.ts +1 -0
  139. package/codebase/types/ts-navbar/sources/elements/title.d.ts +1 -0
  140. package/codebase/types/ts-navbar/sources/itemfactory.d.ts +10 -0
  141. package/codebase/types/ts-navbar/sources/types.d.ts +210 -0
  142. package/codebase/types/ts-popup/index.d.ts +2 -0
  143. package/codebase/types/ts-popup/sources/Popup.d.ts +29 -0
  144. package/codebase/types/ts-popup/sources/types.d.ts +42 -0
  145. package/codebase/types/ts-slider/index.d.ts +2 -0
  146. package/codebase/types/ts-slider/sources/Slider.d.ts +55 -0
  147. package/codebase/types/ts-slider/sources/types.d.ts +60 -0
  148. package/codebase/types/ts-timepicker/index.d.ts +2 -0
  149. package/codebase/types/ts-timepicker/sources/Timepicker.d.ts +28 -0
  150. package/codebase/types/ts-timepicker/sources/helper.d.ts +4 -0
  151. package/codebase/types/ts-timepicker/sources/locales/en.d.ts +6 -0
  152. package/codebase/types/ts-timepicker/sources/types.d.ts +52 -0
  153. package/codebase/types/ts-toolbar/index.d.ts +2 -0
  154. package/codebase/types/ts-toolbar/sources/ProToolbar.d.ts +10 -0
  155. package/codebase/types/ts-toolbar/sources/Toolbar.d.ts +33 -0
  156. package/codebase/types/ts-treegrid/index.d.ts +3 -0
  157. package/codebase/types/ts-treegrid/sources/TreeGrid.d.ts +26 -0
  158. package/codebase/types/ts-treegrid/sources/TreeGridCollection.d.ts +21 -0
  159. package/codebase/types/ts-treegrid/sources/types.d.ts +17 -0
  160. package/codebase/types/ts-vault/sources/ProgressBar.d.ts +12 -0
  161. package/codebase/types/ts-vault/sources/ReadStackPreview.d.ts +11 -0
  162. package/codebase/types/ts-vault/sources/Uploader.d.ts +26 -0
  163. package/codebase/types/ts-vault/sources/Vault.d.ts +39 -0
  164. package/codebase/types/ts-vault/sources/configs.d.ts +2 -0
  165. package/codebase/types/ts-vault/sources/entry.d.ts +8 -0
  166. package/codebase/types/ts-vault/sources/helper.d.ts +31 -0
  167. package/codebase/types/ts-vault/sources/locales/en.d.ts +21 -0
  168. package/codebase/types/ts-vault/sources/types.d.ts +127 -0
  169. package/codebase/vault.d.ts +3 -0
  170. package/codebase/vault.min.css +1 -0
  171. package/codebase/vault.min.js +21 -0
  172. package/codebase/vault.min.js.map +1 -0
  173. package/license.md +360 -0
  174. package/package.json +14 -0
  175. package/whatsnew.txt +99 -0
@@ -0,0 +1,210 @@
1
+ import { Id } from "../../ts-common/types";
2
+ import { IEventSystem } from "../../ts-common/events";
3
+ import { DataEvents, IDataEventsHandlersMap, IDataItem, TreeCollection } from "../../ts-data";
4
+ import { Calendar, ViewMode } from "../../ts-calendar";
5
+ import { Popup } from "../../ts-popup";
6
+ export { DataEvents } from "../../ts-data";
7
+ export interface IHtmlExtendable {
8
+ html?: string;
9
+ }
10
+ export interface IState {
11
+ [key: string]: string | boolean;
12
+ }
13
+ export type NavigationType = "pointer" | "click";
14
+ export interface IGroups {
15
+ [key: string]: {
16
+ active?: Id;
17
+ elements: string[];
18
+ };
19
+ }
20
+ export type ContextMode = "bottom" | "right";
21
+ export interface INavbarConfig {
22
+ navigationType?: NavigationType;
23
+ css?: string;
24
+ menuCss?: string;
25
+ data?: any[] | TreeCollection<any>;
26
+ rootId?: string;
27
+ $name?: string;
28
+ }
29
+ export interface INavbar {
30
+ data: TreeCollection;
31
+ events: IEventSystem<DataEvents | NavigationBarEvents, IDataEventsHandlersMap & INavbarEventHandlersMap>;
32
+ config: INavbarConfig;
33
+ paint(): void;
34
+ disable(ids: Id | Id[]): void;
35
+ enable(ids: Id | Id[]): void;
36
+ isDisabled(id: Id): boolean;
37
+ show(ids: Id | Id[]): void;
38
+ hide(ids: Id | Id[]): void;
39
+ destructor(): void;
40
+ select(id: Id, unselect: boolean): void;
41
+ unselect(id?: Id): void;
42
+ isSelected(id: Id): boolean;
43
+ getSelected(): Id[];
44
+ }
45
+ export type ItemType = "button" | "imageButton" | "selectButton" | "customButton" | "input" | "separator" | "title" | "spacer" | "menuItem" | "block" | "navItem" | "customHTML" | "customHTMLButton" | "datePicker";
46
+ export interface IItem extends IDataItem {
47
+ id?: Id;
48
+ type?: ItemType;
49
+ parent?: Id;
50
+ css?: string | string[];
51
+ hidden?: boolean;
52
+ disabled?: boolean;
53
+ }
54
+ export type IMenuElement = ISpacer | ISeparator | IMenuItem | ICustomHTML;
55
+ export interface IMenuItem extends IItem, IHtmlExtendable {
56
+ type?: "menuItem";
57
+ $openIcon?: string;
58
+ icon?: string;
59
+ items?: IMenuElement[];
60
+ hotkey?: string;
61
+ count?: number | string;
62
+ countColor?: "danger" | "secondary" | "primary" | "success";
63
+ value?: string;
64
+ }
65
+ export interface IPopup {
66
+ data: any[];
67
+ mode: "bottom" | "other";
68
+ position: any;
69
+ width: number;
70
+ height: number;
71
+ }
72
+ export interface INavItem extends IItem, IHtmlExtendable {
73
+ type: "navItem";
74
+ twoState?: boolean;
75
+ group?: string;
76
+ $openIcon?: string;
77
+ icon?: string;
78
+ items?: IMenuElement[];
79
+ value?: string;
80
+ hotkey?: string;
81
+ active?: boolean;
82
+ count?: number | string;
83
+ countColor?: "danger" | "secondary" | "primary" | "success";
84
+ }
85
+ export interface ICustomHTML extends IItem, IHtmlExtendable {
86
+ type: "customHTML";
87
+ }
88
+ export interface ITitle extends IItem, IHtmlExtendable {
89
+ type: "title";
90
+ value?: string;
91
+ tooltip?: string;
92
+ }
93
+ export interface ISpacer extends IItem {
94
+ type: "spacer";
95
+ }
96
+ export interface ISeparator extends IItem {
97
+ type: "separator";
98
+ }
99
+ export interface IButton extends IItem, IHtmlExtendable {
100
+ type: "button";
101
+ css?: string;
102
+ hotkey?: string;
103
+ tooltip?: string;
104
+ count?: number;
105
+ countColor?: "danger" | "secondary" | "primary" | "success";
106
+ items?: IMenuElement[];
107
+ group?: string;
108
+ twoState?: boolean;
109
+ active?: boolean;
110
+ multiClick?: boolean;
111
+ icon?: string;
112
+ view?: "flat" | "link";
113
+ size?: "small" | "medium" | string;
114
+ color?: "danger" | "secondary" | "primary" | "success";
115
+ full?: boolean;
116
+ circle?: boolean;
117
+ loading?: boolean;
118
+ value?: string;
119
+ }
120
+ export interface IInput extends IItem {
121
+ type: "input";
122
+ icon?: string;
123
+ placeholder?: string;
124
+ width?: string;
125
+ label?: string;
126
+ hiddenLabel?: boolean;
127
+ value?: string;
128
+ autocomplete?: boolean;
129
+ }
130
+ export interface IImageButton extends IItem {
131
+ type: "imageButton";
132
+ src: string;
133
+ twoState?: boolean;
134
+ active?: boolean;
135
+ hotkey?: string;
136
+ group?: string;
137
+ count?: number | string;
138
+ countColor?: "danger" | "secondary" | "primary" | "success";
139
+ }
140
+ export interface ISelectButton extends IItem {
141
+ type: "selectButton";
142
+ $openIcon?: string;
143
+ icon?: string;
144
+ items?: IMenuElement[];
145
+ count?: number | string;
146
+ countColor?: "danger" | "secondary" | "primary" | "success";
147
+ value?: string;
148
+ }
149
+ export interface ICustomHTMLButton extends IItem {
150
+ type: "customHTMLButton";
151
+ twoState?: boolean;
152
+ active?: boolean;
153
+ value?: string;
154
+ count?: number;
155
+ countColor?: "danger" | "secondary" | "primary" | "success";
156
+ }
157
+ export interface IBlock extends IItem {
158
+ type: "block";
159
+ title?: string;
160
+ direction?: "row" | "col";
161
+ css?: "string";
162
+ }
163
+ export interface IDatePicker extends IItem {
164
+ type: "datePicker";
165
+ icon?: string;
166
+ placeholder?: string;
167
+ width?: string;
168
+ label?: string;
169
+ hiddenLabel?: boolean;
170
+ editable?: boolean;
171
+ value?: string | Date;
172
+ dateFormat?: string;
173
+ valueFormat?: "string" | "date";
174
+ date?: Date | string;
175
+ mark?: (a: Date) => string;
176
+ disabledDates?: (a: Date) => boolean;
177
+ weekStart?: "saturday" | "sunday" | "monday";
178
+ weekNumbers?: boolean;
179
+ mode?: ViewMode;
180
+ timePicker?: boolean;
181
+ timeFormat?: 24 | 12;
182
+ thisMonthOnly?: boolean;
183
+ $calendar?: Calendar;
184
+ $popup?: Popup;
185
+ }
186
+ export declare enum NavigationBarEvents {
187
+ inputCreated = "inputCreated",
188
+ click = "click",
189
+ openMenu = "openMenu",
190
+ beforeHide = "beforeHide",
191
+ afterHide = "afterHide",
192
+ inputFocus = "inputFocus",
193
+ inputBlur = "inputBlur",
194
+ inputChange = "inputChange",
195
+ input = "input",
196
+ keydown = "keydown"
197
+ }
198
+ export interface INavbarEventHandlersMap {
199
+ [key: string]: (...args: any[]) => any;
200
+ [NavigationBarEvents.inputCreated]: (id: Id, input: HTMLInputElement) => void;
201
+ [NavigationBarEvents.openMenu]: (id: Id) => void;
202
+ [NavigationBarEvents.click]: (id: Id, events: Event) => void;
203
+ [NavigationBarEvents.beforeHide]: (id: Id, events: Event) => void | boolean;
204
+ [NavigationBarEvents.afterHide]: (events: Event) => void;
205
+ [NavigationBarEvents.inputBlur]: (id: Id) => void;
206
+ [NavigationBarEvents.inputFocus]: (id: Id) => void;
207
+ [NavigationBarEvents.inputChange]: (id: Id, newValue: string) => void;
208
+ [NavigationBarEvents.input]: (id: Id, value: string) => void;
209
+ [NavigationBarEvents.keydown]: (event: KeyboardEvent, id?: Id) => void;
210
+ }
@@ -0,0 +1,2 @@
1
+ export * from "./sources/Popup";
2
+ export * from "./sources/types";
@@ -0,0 +1,29 @@
1
+ import { VNode } from "../../ts-common/dom";
2
+ import { IEventSystem } from "../../ts-common/events";
3
+ import { View } from "../../ts-common/view";
4
+ import { IPopup, IPopupConfig, IPopupEventHandlersMap, IShowConfig, PopupEvents } from "./types";
5
+ export declare class Popup extends View implements IPopup {
6
+ config: IPopupConfig;
7
+ events: IEventSystem<PopupEvents, IPopupEventHandlersMap>;
8
+ private _html;
9
+ private _ui;
10
+ private _popup;
11
+ private _clickEvent;
12
+ private _isActive;
13
+ private _outerClickDestructor;
14
+ private _timeout;
15
+ constructor(config?: IPopupConfig);
16
+ show(node: HTMLElement, config?: IShowConfig, attached?: any): void;
17
+ hide(): void;
18
+ isVisible(): boolean;
19
+ attach(name: any, config?: any): VNode;
20
+ attachHTML(html: string): void;
21
+ getWidget(): any;
22
+ getContainer(): HTMLElement;
23
+ toVDOM(): any;
24
+ destructor(): void;
25
+ private _setTheme;
26
+ private _setPopupSize;
27
+ private _detectOuterClick;
28
+ private _hide;
29
+ }
@@ -0,0 +1,42 @@
1
+ import { VNode } from "../../ts-common/dom";
2
+ import { IEventSystem } from "../../ts-common/events";
3
+ import { Position } from "../../ts-common/html";
4
+ export interface IPopup {
5
+ show(node: HTMLElement, config?: IShowConfig, attach?: any): void;
6
+ hide(): void;
7
+ toVDOM(): void;
8
+ attachHTML(html: string): void;
9
+ attach(node: HTMLElement, config?: IShowConfig, attached?: any): VNode;
10
+ isVisible(): boolean;
11
+ paint(): void;
12
+ destructor(): void;
13
+ getWidget(): any;
14
+ getContainer(): HTMLElement;
15
+ }
16
+ export interface IPopupConfig {
17
+ css?: string;
18
+ events?: IEventSystem<any>;
19
+ theme?: HTMLElement | string;
20
+ }
21
+ export declare enum PopupEvents {
22
+ beforeHide = "beforeHide",
23
+ beforeShow = "beforeShow",
24
+ afterHide = "afterHide",
25
+ afterShow = "afterShow",
26
+ click = "click"
27
+ }
28
+ export interface IShowConfig {
29
+ centering?: boolean;
30
+ auto?: boolean;
31
+ mode?: Position;
32
+ indent?: number | string;
33
+ theme?: string | HTMLElement;
34
+ }
35
+ export interface IPopupEventHandlersMap {
36
+ [key: string]: (...args: any[]) => any;
37
+ [PopupEvents.click]: (e: Event) => any;
38
+ [PopupEvents.afterHide]: (e: Event) => void;
39
+ [PopupEvents.afterShow]: (node: HTMLElement) => void;
40
+ [PopupEvents.beforeHide]: (fromOuterClick: boolean, e: Event) => void | boolean;
41
+ [PopupEvents.beforeShow]: (node: HTMLElement) => void | boolean;
42
+ }
@@ -0,0 +1,2 @@
1
+ export * from "./sources/Slider";
2
+ export * from "./sources/types";
@@ -0,0 +1,55 @@
1
+ import { IEventSystem } from "../../ts-common/events";
2
+ import { View } from "../../ts-common/view";
3
+ import { Popup } from "../../ts-popup";
4
+ import { ISlider, SliderEvents, ISliderConfig, ISliderEventHandlersMap } from "./types";
5
+ export declare class Slider extends View implements ISlider {
6
+ config: ISliderConfig;
7
+ events: IEventSystem<SliderEvents, ISliderEventHandlersMap>;
8
+ protected _helper: Popup;
9
+ private _offsets;
10
+ private _currentPosition;
11
+ private _extraCurrentPosition;
12
+ private _length;
13
+ private _axis;
14
+ private _isExtraActive;
15
+ private _disabled;
16
+ private _isMouseMoving;
17
+ private _keyManager;
18
+ private _handlers;
19
+ private _possibleRange;
20
+ private _findNewDirection;
21
+ private _mouseIn;
22
+ private _focusIn;
23
+ private _tooltip;
24
+ private _activeTooltip;
25
+ constructor(container: HTMLElement | string, config: ISliderConfig);
26
+ disable(): void;
27
+ enable(): void;
28
+ isDisabled(): boolean;
29
+ focus(extra?: boolean): void;
30
+ blur(): void;
31
+ getValue(): number[];
32
+ setValue(value: string | number | number[]): void;
33
+ destructor(): void;
34
+ private _calcSliderPosition;
35
+ private _initHotkeys;
36
+ private _move;
37
+ private _initStartPosition;
38
+ private _getValue;
39
+ private _setValue;
40
+ private _initHandlers;
41
+ private _getBegining;
42
+ private _inSide;
43
+ private _updatePosition;
44
+ private _getRunnerStyle;
45
+ private _isInverse;
46
+ private _getRunnerCss;
47
+ private _draw;
48
+ private _drawSlider;
49
+ private _getDetector;
50
+ private _drawTooltip;
51
+ private _getTicks;
52
+ private _drawTicks;
53
+ private _isNullable;
54
+ private _setTooltip;
55
+ }
@@ -0,0 +1,60 @@
1
+ export type Direction = "vertical" | "horizontal";
2
+ export type ActiveSlider = "tooltip" | "extraTooltip" | "none";
3
+ export interface ISlider {
4
+ config: ISliderConfig;
5
+ paint(): void;
6
+ destructor(): void;
7
+ getValue(): number[];
8
+ setValue(value: string | number | number[]): void;
9
+ disable(): void;
10
+ enable(): void;
11
+ isDisabled(): boolean;
12
+ focus(extra?: boolean): void;
13
+ blur(): void;
14
+ }
15
+ export declare enum SliderEvents {
16
+ beforeChange = "beforeChange",
17
+ change = "change",
18
+ focus = "focus",
19
+ blur = "blur",
20
+ keydown = "keydown",
21
+ mousedown = "mousedown",
22
+ mouseup = "mouseup"
23
+ }
24
+ export interface ISliderEventHandlersMap {
25
+ [key: string]: (...args: any[]) => any;
26
+ [SliderEvents.beforeChange]: (value: number, oldValue: number, isRange: boolean) => void;
27
+ [SliderEvents.change]: (value: number, oldValue: number, isRange: boolean) => void;
28
+ [SliderEvents.focus]: () => void;
29
+ [SliderEvents.blur]: () => void;
30
+ [SliderEvents.keydown]: (event: KeyboardEvent) => void;
31
+ [SliderEvents.mousedown]: (event: Event) => void;
32
+ [SliderEvents.mouseup]: (event: Event) => void;
33
+ }
34
+ export type ILabelPosition = "left" | "top";
35
+ export interface ISliderConfig {
36
+ min?: number;
37
+ max?: number;
38
+ step?: number;
39
+ mode?: Direction;
40
+ range?: boolean;
41
+ value?: number[] | number | string;
42
+ inverse?: boolean;
43
+ tooltip?: boolean;
44
+ css?: string;
45
+ tick?: number;
46
+ tickTemplate?: (position: number) => string;
47
+ majorTick?: number;
48
+ label?: string;
49
+ required?: boolean;
50
+ helpMessage?: string;
51
+ labelPosition?: ILabelPosition;
52
+ labelWidth?: string | number;
53
+ hiddenLabel?: boolean;
54
+ /** @deprecated See a documentation: https://docs.dhtmlx.com/ */
55
+ help?: string;
56
+ /** @deprecated See a documentation: https://docs.dhtmlx.com/ */
57
+ thumbLabel?: boolean;
58
+ /** @deprecated See a documentation: https://docs.dhtmlx.com/ */
59
+ labelInline?: boolean;
60
+ }
@@ -0,0 +1,2 @@
1
+ export * from "./sources/Timepicker";
2
+ export * from "./sources/types";
@@ -0,0 +1,28 @@
1
+ import { IEventSystem } from "../../ts-common/events";
2
+ import { View } from "../../ts-common/view";
3
+ import { Layout } from "../../ts-layout";
4
+ import { TimepickerEvents, ITimepickerConfig, ITimepicker, ITimeObject, ITimepickerHandlersMap } from "./types";
5
+ export declare class Timepicker extends View implements ITimepicker {
6
+ config: ITimepickerConfig;
7
+ events: IEventSystem<TimepickerEvents, ITimepickerHandlersMap>;
8
+ layout: Layout;
9
+ private _hoursSlider;
10
+ private _minutesSlider;
11
+ private _inputsView;
12
+ private _time;
13
+ private _handlers;
14
+ private _outerHandlers;
15
+ constructor(container: HTMLElement | string, config?: ITimepickerConfig);
16
+ getValue<T extends boolean = false>(asObject?: T): T extends true ? ITimeObject : string;
17
+ setValue(value: Date | number | string | any[] | ITimeObject): void;
18
+ clear(): void;
19
+ destructor(): void;
20
+ getRootView(): any;
21
+ private _getValue;
22
+ private _setValue;
23
+ private _initUI;
24
+ private _initHandlers;
25
+ private _initEvents;
26
+ private _draw;
27
+ private _isTimeObj;
28
+ }
@@ -0,0 +1,4 @@
1
+ /**
2
+ * This function is designed to resolve conflicts with the time setting for the 12 hour format.
3
+ */
4
+ export declare function isTimeCheck(value: any): boolean;
@@ -0,0 +1,6 @@
1
+ declare const locale: {
2
+ hours: string;
3
+ minutes: string;
4
+ save: string;
5
+ };
6
+ export default locale;
@@ -0,0 +1,52 @@
1
+ import { IEventSystem } from "../../ts-common/events";
2
+ import { Layout } from "../../ts-layout";
3
+ export interface ITimepickerConfig {
4
+ css?: string;
5
+ timeFormat?: 12 | 24;
6
+ controls?: boolean;
7
+ value?: Date | number | string | any[] | ITimeObject;
8
+ valueFormat?: "string" | "timeObject";
9
+ /** @deprecated See a documentation: https://docs.dhtmlx.com/ */
10
+ actions?: boolean;
11
+ }
12
+ export interface ITimepicker {
13
+ config: ITimepickerConfig;
14
+ events: IEventSystem<TimepickerEvents, ITimepickerHandlersMap>;
15
+ layout: Layout;
16
+ paint(): void;
17
+ getValue(asOBject?: boolean): ITimeObject | string;
18
+ setValue(value: Date | number | string | any[] | ITimeObject): void;
19
+ clear(): void;
20
+ destructor(): void;
21
+ }
22
+ export interface ITimeObject {
23
+ hour: number;
24
+ minute: number;
25
+ AM?: boolean;
26
+ }
27
+ export declare enum TimepickerEvents {
28
+ beforeChange = "beforeChange",
29
+ change = "change",
30
+ beforeApply = "beforeApply",
31
+ afterApply = "afterApply",
32
+ beforeClose = "beforeClose",
33
+ afterClose = "afterClose",
34
+ /** @deprecated See a documentation: https://docs.dhtmlx.com/ */
35
+ apply = "apply",
36
+ /** @deprecated See a documentation: https://docs.dhtmlx.com/ */
37
+ close = "close",
38
+ /** @deprecated See a documentation: https://docs.dhtmlx.com/ */
39
+ save = "save"
40
+ }
41
+ export interface ITimepickerHandlersMap {
42
+ [key: string]: (...args: any[]) => any;
43
+ [TimepickerEvents.beforeChange]: (value: string | ITimeObject) => boolean | void;
44
+ [TimepickerEvents.change]: (value: string | ITimeObject) => void;
45
+ [TimepickerEvents.beforeApply]: (value: string | ITimeObject) => boolean | void;
46
+ [TimepickerEvents.afterApply]: (value: string | ITimeObject) => void;
47
+ [TimepickerEvents.beforeClose]: (value: string | ITimeObject) => boolean | void;
48
+ [TimepickerEvents.afterClose]: (value: string | ITimeObject) => void;
49
+ [TimepickerEvents.apply]: (value: string) => void;
50
+ [TimepickerEvents.close]: () => any;
51
+ [TimepickerEvents.save]: (value?: ITimeObject) => any;
52
+ }
@@ -0,0 +1,2 @@
1
+ export * from "./sources/Toolbar";
2
+ export * from "./sources/ProToolbar";
@@ -0,0 +1,10 @@
1
+ import { Toolbar, IToolbar } from "./Toolbar";
2
+ import { ScrollView } from "../../ts-common/ScrollView";
3
+ export interface IProToolbar extends IToolbar {
4
+ scrollView: ScrollView;
5
+ }
6
+ export declare class ProToolbar extends Toolbar implements IProToolbar {
7
+ scrollView: ScrollView;
8
+ constructor(element?: string | HTMLElement, config?: any);
9
+ protected _draw(element: any): any;
10
+ }
@@ -0,0 +1,33 @@
1
+ import { Id } from "../../ts-common/types";
2
+ import { TreeCollection } from "../../ts-data";
3
+ import { IState, Navbar, INavbar, IButton, IImageButton, ISelectButton, IInput, ISeparator, ISpacer, ITitle, ICustomHTML, INavItem, IMenuItem, IDatePicker, NavigationType } from "../../ts-navbar";
4
+ export interface IToolbarConfig {
5
+ css?: string;
6
+ menuCss?: string;
7
+ data?: any[] | TreeCollection<IToolbarElement>;
8
+ navigationType?: NavigationType;
9
+ }
10
+ export interface IToolbar extends INavbar {
11
+ data: TreeCollection<IToolbarElement>;
12
+ config: IToolbarConfig;
13
+ getState(id?: Id): IState;
14
+ setState(state: IState): void;
15
+ }
16
+ export type IToolbarElement = IButton | IImageButton | ISelectButton | IInput | ISeparator | ISpacer | ITitle | ICustomHTML | INavItem | IMenuItem | IDatePicker;
17
+ export declare class Toolbar extends Navbar<IToolbarElement> implements IToolbar {
18
+ data: TreeCollection<IToolbarElement>;
19
+ config: IToolbarConfig;
20
+ constructor(element?: string | HTMLElement, config?: any);
21
+ getState(id?: Id): IState;
22
+ setState(state: IState): void;
23
+ setFocus(id: Id): void;
24
+ protected _customHandlers(): {
25
+ input: (e: Event) => void;
26
+ tooltip: (e: MouseEvent) => void;
27
+ };
28
+ protected _getFactory(): any;
29
+ protected _draw(element: any): any;
30
+ protected _getMode(item: any, root: any): "right" | "bottom";
31
+ protected _close(e: MouseEvent): void;
32
+ protected _setRoot(id: Id): void;
33
+ }
@@ -0,0 +1,3 @@
1
+ export * from "./sources/TreeGrid";
2
+ export * from "./sources/types";
3
+ export * from "./sources/TreeGridCollection";
@@ -0,0 +1,26 @@
1
+ import { GridEvents, IEventHandlersMap, ExtendedGrid, ICellRect, IColumnsWidth, ISpan, IAdjustColumns } from "../../ts-grid";
2
+ import { IEventSystem } from "../../ts-common/events";
3
+ import { DataEvents, DragEvents, IDataEventsHandlersMap, IDragEventsHandlersMap } from "../../ts-data";
4
+ import { TreeGridCollection } from "./TreeGridCollection";
5
+ import { ITreeGrid, ITreeGridConfig } from "./types";
6
+ import { Id } from "../../ts-common/types";
7
+ export declare class TreeGrid extends ExtendedGrid implements ITreeGrid {
8
+ config: ITreeGridConfig;
9
+ data: TreeGridCollection;
10
+ events: IEventSystem<DataEvents | GridEvents | DragEvents, IEventHandlersMap & IDataEventsHandlersMap & IDragEventsHandlersMap>;
11
+ constructor(container: HTMLElement | string | null, config: ITreeGridConfig);
12
+ expand(rowId: Id): void;
13
+ collapse(rowId: Id): void;
14
+ expandAll(): void;
15
+ collapseAll(): void;
16
+ showRow(rowId: Id): void;
17
+ hideRow(rowId: Id): void;
18
+ getCellRect(rowId: Id, colId?: Id): ICellRect;
19
+ getSpan(rowId: Id, colId: Id): ISpan;
20
+ protected _adjustColumnsWidth({ rows, cols, totalCols, adjust, }: IAdjustColumns): IColumnsWidth;
21
+ protected _createCollection(): void;
22
+ protected _getRowIndex(rowId: Id): number;
23
+ protected _applyLocalFilter(beforePrepareData?: boolean): void;
24
+ protected _setEventHandlers(): void;
25
+ private _serialize;
26
+ }
@@ -0,0 +1,21 @@
1
+ import { IEventSystem } from "../../ts-common/events";
2
+ import { DataCallback, DataDriver, DataEvents, IDataItem, TreeCollection } from "../../ts-data";
3
+ import { Id } from "../../ts-common/types";
4
+ import { GridEvents } from "../../ts-grid";
5
+ export declare class TreeGridCollection extends TreeCollection {
6
+ constructor(config?: any, events?: IEventSystem<DataEvents | GridEvents>);
7
+ eachChild(id: Id, cb: any, direct?: boolean, checkItem?: (item: IDataItem) => boolean): void;
8
+ getMaxLevel(): number;
9
+ getLevel(id: Id): number;
10
+ serialize(driver?: DataDriver): any[];
11
+ getPlainIndex(id: Id): number;
12
+ map(cb: DataCallback<IDataItem>, parent?: Id, direct?: boolean): IDataItem[];
13
+ mapVisible(cb: DataCallback<IDataItem>, parent?: Id, direct?: boolean): IDataItem[];
14
+ protected _parse_data(data: any, parent?: Id): void;
15
+ protected _copy(id: Id, index: number, target?: TreeGridCollection, targetId?: Id, key?: number): Id;
16
+ protected _addToOrder(_order: any, obj: any, index: number): void;
17
+ protected _removeCore(id: Id): void;
18
+ protected _setParent(item: IDataItem, parent: Id): void;
19
+ private _checkItems;
20
+ protected _moveItem(id: any, targetId: any, index: any): void;
21
+ }
@@ -0,0 +1,17 @@
1
+ import { DataEvents, DragEvents, DropBehaviour, IDataEventsHandlersMap, IDragEventsHandlersMap } from "../../ts-data";
2
+ import { GridEvents, IEventHandlersMap, IExtendedGrid, IExtendedGridConfig } from "../../ts-grid";
3
+ import { IEventSystem } from "../../ts-common/events";
4
+ import { Id } from "../../ts-common/types";
5
+ import { TreeGridCollection } from "./TreeGridCollection";
6
+ export interface ITreeGridConfig extends IExtendedGridConfig {
7
+ type?: "tree";
8
+ rootParent?: Id;
9
+ collapsed?: boolean;
10
+ dragExpand?: boolean;
11
+ dropBehaviour?: DropBehaviour;
12
+ }
13
+ export interface ITreeGrid extends IExtendedGrid {
14
+ events: IEventSystem<DataEvents | GridEvents | DragEvents, IEventHandlersMap & IDataEventsHandlersMap & IDragEventsHandlersMap>;
15
+ config: ITreeGridConfig;
16
+ data: TreeGridCollection;
17
+ }
@@ -0,0 +1,12 @@
1
+ import { View } from "../../ts-common/view";
2
+ import { IProgressBarConfig, IVaultEventSystem } from "./types";
3
+ export declare class ProgressBar<T> extends View {
4
+ config: IProgressBarConfig<T>;
5
+ events: IVaultEventSystem;
6
+ private _progress;
7
+ private _progressText;
8
+ private _abortUpload;
9
+ constructor(events: IVaultEventSystem, config: IProgressBarConfig<T>);
10
+ setState(progress: number, extra: T): void;
11
+ private _draw;
12
+ }
@@ -0,0 +1,11 @@
1
+ import { DataCollection } from "../../ts-data";
2
+ import { IFileWrapper } from "./types";
3
+ export declare class ReadStackPreview {
4
+ private _data;
5
+ private _readerStack;
6
+ private _isActive;
7
+ constructor(data: DataCollection<IFileWrapper>);
8
+ add(fileWrapper: IFileWrapper, wait?: boolean): void;
9
+ read(): void;
10
+ stop(): void;
11
+ }