@base-framework/base 3.0.79 → 3.0.81
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/dist/base.js +1 -1
- package/dist/base.js.map +3 -3
- package/dist/types/base.d.ts +25 -0
- package/dist/types/main/base.d.ts +94 -0
- package/dist/types/main/data-tracker/data-tracker.d.ts +93 -0
- package/dist/types/main/data-tracker/tracker-types.d.ts +23 -0
- package/dist/types/main/data-tracker/tracker.d.ts +56 -0
- package/dist/types/main/equals.d.ts +1 -0
- package/dist/types/main/events/event-methods.d.ts +124 -0
- package/dist/types/main/events/events.d.ts +208 -0
- package/dist/types/modules/ajax/ajax.d.ts +153 -0
- package/dist/types/modules/animation/animation.d.ts +79 -0
- package/dist/types/modules/animations/animation-controller.d.ts +61 -0
- package/dist/types/modules/animations/animation.d.ts +28 -0
- package/dist/types/modules/animations/attr-movement.d.ts +5 -0
- package/dist/types/modules/animations/css-movement.d.ts +8 -0
- package/dist/types/modules/animations/movement-factory.d.ts +34 -0
- package/dist/types/modules/animations/movement.d.ts +24 -0
- package/dist/types/modules/animations/value.d.ts +30 -0
- package/dist/types/modules/atom/atom.d.ts +1 -0
- package/dist/types/modules/atom/atoms.d.ts +343 -0
- package/dist/types/modules/component/component.d.ts +99 -0
- package/dist/types/modules/component/event-helper.d.ts +59 -0
- package/dist/types/modules/component/jot.d.ts +1 -0
- package/dist/types/modules/component/parse-args.d.ts +1 -0
- package/dist/types/modules/component/state-helper.d.ts +102 -0
- package/dist/types/modules/component/unit.d.ts +281 -0
- package/dist/types/modules/data/attrs.d.ts +1 -0
- package/dist/types/modules/data/basic-data.d.ts +259 -0
- package/dist/types/modules/data/data-proxy.d.ts +1 -0
- package/dist/types/modules/data/data-utils.d.ts +17 -0
- package/dist/types/modules/data/data.d.ts +3 -0
- package/dist/types/modules/data/deep-data.d.ts +162 -0
- package/dist/types/modules/data/model-service.d.ts +280 -0
- package/dist/types/modules/data/model.d.ts +33 -0
- package/dist/types/modules/data/simple-data.d.ts +12 -0
- package/dist/types/modules/data-binder/connection-tracker/connection-tracker.d.ts +45 -0
- package/dist/types/modules/data-binder/connection-tracker/connections/connection.d.ts +15 -0
- package/dist/types/modules/data-binder/connection-tracker/connections/one-way-connection.d.ts +23 -0
- package/dist/types/modules/data-binder/connection-tracker/connections/two-way-connection.d.ts +62 -0
- package/dist/types/modules/data-binder/data-binder.d.ts +175 -0
- package/dist/types/modules/data-binder/data-pub-sub.d.ts +66 -0
- package/dist/types/modules/data-binder/sources/data-source.d.ts +51 -0
- package/dist/types/modules/data-binder/sources/element-source.d.ts +84 -0
- package/dist/types/modules/data-binder/sources/one-way-source.d.ts +33 -0
- package/dist/types/modules/data-binder/sources/source.d.ts +26 -0
- package/dist/types/modules/data-binder/sources/two-way-source.d.ts +42 -0
- package/dist/types/modules/date/date-time.d.ts +165 -0
- package/dist/types/modules/history/history.d.ts +10 -0
- package/dist/types/modules/html/html.d.ts +136 -0
- package/dist/types/modules/import/import.d.ts +1 -0
- package/dist/types/modules/layout/builder.d.ts +102 -0
- package/dist/types/modules/layout/directives/core/aria/aria.d.ts +2 -0
- package/dist/types/modules/layout/directives/core/context/context-directives.d.ts +3 -0
- package/dist/types/modules/layout/directives/core/default-directives.d.ts +1 -0
- package/dist/types/modules/layout/directives/core/dom-methods.d.ts +1 -0
- package/dist/types/modules/layout/directives/core/parent/parent-directives.d.ts +5 -0
- package/dist/types/modules/layout/directives/core/reactive/bind.d.ts +1 -0
- package/dist/types/modules/layout/directives/core/reactive/for-each.d.ts +1 -0
- package/dist/types/modules/layout/directives/core/reactive/get-parent-data.d.ts +1 -0
- package/dist/types/modules/layout/directives/core/reactive/map.d.ts +1 -0
- package/dist/types/modules/layout/directives/core/reactive/on-created.d.ts +1 -0
- package/dist/types/modules/layout/directives/core/reactive/on-destroyed.d.ts +1 -0
- package/dist/types/modules/layout/directives/core/reactive/on-set.d.ts +1 -0
- package/dist/types/modules/layout/directives/core/reactive/on-state.d.ts +1 -0
- package/dist/types/modules/layout/directives/core/reactive/watch.d.ts +1 -0
- package/dist/types/modules/layout/directives/core/route.d.ts +1 -0
- package/dist/types/modules/layout/directives/core/switch.d.ts +1 -0
- package/dist/types/modules/layout/directives/directive.d.ts +1 -0
- package/dist/types/modules/layout/directives/directives.d.ts +25 -0
- package/dist/types/modules/layout/element/attribute-directive.d.ts +1 -0
- package/dist/types/modules/layout/element/attribute.d.ts +1 -0
- package/dist/types/modules/layout/element/element.d.ts +1 -0
- package/dist/types/modules/layout/element/parser.d.ts +65 -0
- package/dist/types/modules/layout/html-helper.d.ts +57 -0
- package/dist/types/modules/layout/render/browser-render.d.ts +10 -0
- package/dist/types/modules/layout/render/render-controller.d.ts +23 -0
- package/dist/types/modules/layout/render/render.d.ts +18 -0
- package/dist/types/modules/layout/render/server-render.d.ts +10 -0
- package/dist/types/modules/layout/watcher-helper.d.ts +103 -0
- package/dist/types/modules/mouse/mouse.d.ts +45 -0
- package/dist/types/modules/router/history/browser-history.d.ts +39 -0
- package/dist/types/modules/router/history/hash-history.d.ts +25 -0
- package/dist/types/modules/router/history/history-controller.d.ts +21 -0
- package/dist/types/modules/router/history/history.d.ts +35 -0
- package/dist/types/modules/router/nav-link.d.ts +37 -0
- package/dist/types/modules/router/router.d.ts +268 -0
- package/dist/types/modules/router/routes/component-helper.d.ts +75 -0
- package/dist/types/modules/router/routes/param-pattern.d.ts +2 -0
- package/dist/types/modules/router/routes/route-pattern.d.ts +1 -0
- package/dist/types/modules/router/routes/route.d.ts +120 -0
- package/dist/types/modules/router/set-title.d.ts +1 -0
- package/dist/types/modules/router/utils.d.ts +9 -0
- package/dist/types/modules/state/state-target.d.ts +45 -0
- package/dist/types/modules/state/state-tracker.d.ts +103 -0
- package/dist/types/shared/arrays.d.ts +26 -0
- package/dist/types/shared/dom.d.ts +272 -0
- package/dist/types/shared/encode/encode.d.ts +38 -0
- package/dist/types/shared/encode/json.d.ts +15 -0
- package/dist/types/shared/objects.d.ts +62 -0
- package/dist/types/shared/strings.d.ts +34 -0
- package/dist/types/shared/types.d.ts +52 -0
- package/package.json +5 -3
|
@@ -0,0 +1,343 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Creates a div element.
|
|
3
|
+
*
|
|
4
|
+
* @param {object} props - Properties for the div element.
|
|
5
|
+
* @param {array} children - Children elements of the div.
|
|
6
|
+
* @returns {object} - Returns an object representing the div element.
|
|
7
|
+
*/
|
|
8
|
+
export const Div: Function;
|
|
9
|
+
/**
|
|
10
|
+
* Creates a span element.
|
|
11
|
+
*
|
|
12
|
+
* @param {object} props - Properties for the span element.
|
|
13
|
+
* @param {array} children - Children elements of the span.
|
|
14
|
+
* @returns {object} - Returns an object representing the span element.
|
|
15
|
+
*/
|
|
16
|
+
export const Span: Function;
|
|
17
|
+
/**
|
|
18
|
+
* Creates a paragraph (p) element.
|
|
19
|
+
*
|
|
20
|
+
* @param {object} props - Properties for the paragraph element.
|
|
21
|
+
* @param {array} children - Children elements of the paragraph.
|
|
22
|
+
* @returns {object} - Returns an object representing the paragraph element.
|
|
23
|
+
*/
|
|
24
|
+
export const P: Function;
|
|
25
|
+
/**
|
|
26
|
+
* Creates an anchor (a) element.
|
|
27
|
+
*
|
|
28
|
+
* @param {object} props - Properties for the anchor element.
|
|
29
|
+
* @param {array} children - Children elements of the anchor.
|
|
30
|
+
* @returns {object} - Returns an object representing the anchor element.
|
|
31
|
+
*/
|
|
32
|
+
export const A: Function;
|
|
33
|
+
/**
|
|
34
|
+
* Creates a button element.
|
|
35
|
+
*/
|
|
36
|
+
export const Button: Function;
|
|
37
|
+
/**
|
|
38
|
+
* Creates an unordered list (ul) element.
|
|
39
|
+
*/
|
|
40
|
+
export const Ul: Function;
|
|
41
|
+
/**
|
|
42
|
+
* Creates a list item (li) element.
|
|
43
|
+
*/
|
|
44
|
+
export const Li: Function;
|
|
45
|
+
/**
|
|
46
|
+
* Creates an image (img) element.
|
|
47
|
+
*/
|
|
48
|
+
export const Img: Function;
|
|
49
|
+
/**
|
|
50
|
+
* Create a br element.
|
|
51
|
+
*
|
|
52
|
+
* @param {object} props - Properties for the br element.
|
|
53
|
+
* @returns {object} - Returns an object representing the br element.
|
|
54
|
+
*/
|
|
55
|
+
export const Br: Function;
|
|
56
|
+
/**
|
|
57
|
+
* Creates a horizontal rule (hr) element.
|
|
58
|
+
*/
|
|
59
|
+
export const Hr: Function;
|
|
60
|
+
/**
|
|
61
|
+
* Creates a text (text) element.
|
|
62
|
+
*/
|
|
63
|
+
export const Text: Function;
|
|
64
|
+
/**
|
|
65
|
+
* Creates a header 1 (h1) element.
|
|
66
|
+
*/
|
|
67
|
+
export const H1: Function;
|
|
68
|
+
/**
|
|
69
|
+
* Creates a header 2 (h2) element.
|
|
70
|
+
*/
|
|
71
|
+
export const H2: Function;
|
|
72
|
+
/**
|
|
73
|
+
* Creates a header 3 (h3) element.
|
|
74
|
+
*/
|
|
75
|
+
export const H3: Function;
|
|
76
|
+
/**
|
|
77
|
+
* Creates a header 4 (h4) element.
|
|
78
|
+
*/
|
|
79
|
+
export const H4: Function;
|
|
80
|
+
/**
|
|
81
|
+
* Creates a header 5 (h5) element.
|
|
82
|
+
*/
|
|
83
|
+
export const H5: Function;
|
|
84
|
+
/**
|
|
85
|
+
* Creates a header 6 (h6) element.
|
|
86
|
+
*/
|
|
87
|
+
export const H6: Function;
|
|
88
|
+
/**
|
|
89
|
+
* Creates an input element.
|
|
90
|
+
*/
|
|
91
|
+
export const Input: Function;
|
|
92
|
+
/**
|
|
93
|
+
* Creates a label element.
|
|
94
|
+
*/
|
|
95
|
+
export const Label: Function;
|
|
96
|
+
/**
|
|
97
|
+
* Creates a section element.
|
|
98
|
+
*/
|
|
99
|
+
export const Section: Function;
|
|
100
|
+
/**
|
|
101
|
+
* Creates an article element.
|
|
102
|
+
*/
|
|
103
|
+
export const Article: Function;
|
|
104
|
+
/**
|
|
105
|
+
* Creates a header (header) element.
|
|
106
|
+
*/
|
|
107
|
+
export const Header: Function;
|
|
108
|
+
/**
|
|
109
|
+
* Creates a footer element.
|
|
110
|
+
*/
|
|
111
|
+
export const Footer: Function;
|
|
112
|
+
/**
|
|
113
|
+
* Creates a nav element.
|
|
114
|
+
*/
|
|
115
|
+
export const Nav: Function;
|
|
116
|
+
/**
|
|
117
|
+
* Creates an aside element.
|
|
118
|
+
*/
|
|
119
|
+
export const Aside: Function;
|
|
120
|
+
/**
|
|
121
|
+
* Creates a figure element.
|
|
122
|
+
*/
|
|
123
|
+
export const Figure: Function;
|
|
124
|
+
/**
|
|
125
|
+
* Creates a figcaption element.
|
|
126
|
+
*/
|
|
127
|
+
export const Figcaption: Function;
|
|
128
|
+
/**
|
|
129
|
+
* Creates a main element.
|
|
130
|
+
*/
|
|
131
|
+
export const Main: Function;
|
|
132
|
+
/**
|
|
133
|
+
* Creates a video element.
|
|
134
|
+
*/
|
|
135
|
+
export const Video: Function;
|
|
136
|
+
/**
|
|
137
|
+
* Creates an audio element.
|
|
138
|
+
*/
|
|
139
|
+
export const Audio: Function;
|
|
140
|
+
/**
|
|
141
|
+
* Creates a table element.
|
|
142
|
+
*/
|
|
143
|
+
export const Table: Function;
|
|
144
|
+
/**
|
|
145
|
+
* Creates a table row (tr) element.
|
|
146
|
+
*/
|
|
147
|
+
export const Tr: Function;
|
|
148
|
+
/**
|
|
149
|
+
* Creates a table header (th) element.
|
|
150
|
+
*/
|
|
151
|
+
export const Th: Function;
|
|
152
|
+
/**
|
|
153
|
+
* Creates a table data (td) element.
|
|
154
|
+
*/
|
|
155
|
+
export const Td: Function;
|
|
156
|
+
/**
|
|
157
|
+
* Creates a table header group (thead) element.
|
|
158
|
+
*/
|
|
159
|
+
export const Thead: Function;
|
|
160
|
+
/**
|
|
161
|
+
* Creates a table body (tbody) element.
|
|
162
|
+
*/
|
|
163
|
+
export const Tbody: Function;
|
|
164
|
+
/**
|
|
165
|
+
* Creates a table footer (tfoot) element.
|
|
166
|
+
*/
|
|
167
|
+
export const Tfoot: Function;
|
|
168
|
+
/**
|
|
169
|
+
* Creates a form element.
|
|
170
|
+
*/
|
|
171
|
+
export const Form: Function;
|
|
172
|
+
/**
|
|
173
|
+
* Creates a select element.
|
|
174
|
+
*/
|
|
175
|
+
export const Select: Function;
|
|
176
|
+
/**
|
|
177
|
+
* Creates an option element for a select tag.
|
|
178
|
+
*/
|
|
179
|
+
export const Option: Function;
|
|
180
|
+
/**
|
|
181
|
+
* Creates a textarea element.
|
|
182
|
+
*/
|
|
183
|
+
export const Textarea: Function;
|
|
184
|
+
/**
|
|
185
|
+
* Creates a canvas element.
|
|
186
|
+
*/
|
|
187
|
+
export const Canvas: Function;
|
|
188
|
+
/**
|
|
189
|
+
* Creates a progress element.
|
|
190
|
+
*/
|
|
191
|
+
export const Progress: Function;
|
|
192
|
+
/**
|
|
193
|
+
* Creates a blockquote element.
|
|
194
|
+
*/
|
|
195
|
+
export const Blockquote: Function;
|
|
196
|
+
/**
|
|
197
|
+
* Creates a preformatted text (pre) element.
|
|
198
|
+
*/
|
|
199
|
+
export const Pre: Function;
|
|
200
|
+
/**
|
|
201
|
+
* Creates a code element.
|
|
202
|
+
*/
|
|
203
|
+
export const Code: Function;
|
|
204
|
+
/**
|
|
205
|
+
* Creates an ordered list (ol) element.
|
|
206
|
+
*/
|
|
207
|
+
export const Ol: Function;
|
|
208
|
+
/**
|
|
209
|
+
* Creates a definition list (dl) element.
|
|
210
|
+
*/
|
|
211
|
+
export const Dl: Function;
|
|
212
|
+
/**
|
|
213
|
+
* Creates a definition term (dt) element.
|
|
214
|
+
*/
|
|
215
|
+
export const Dt: Function;
|
|
216
|
+
/**
|
|
217
|
+
* Creates a definition description (dd) element.
|
|
218
|
+
*/
|
|
219
|
+
export const Dd: Function;
|
|
220
|
+
/**
|
|
221
|
+
* Creates a fieldset element.
|
|
222
|
+
*/
|
|
223
|
+
export const Fieldset: Function;
|
|
224
|
+
/**
|
|
225
|
+
* Creates a legend element.
|
|
226
|
+
*/
|
|
227
|
+
export const Legend: Function;
|
|
228
|
+
/**
|
|
229
|
+
* Creates a meter element.
|
|
230
|
+
*/
|
|
231
|
+
export const Meter: Function;
|
|
232
|
+
/**
|
|
233
|
+
* Creates an iframe element.
|
|
234
|
+
*/
|
|
235
|
+
export const Iframe: Function;
|
|
236
|
+
/**
|
|
237
|
+
* Creates a details element.
|
|
238
|
+
*/
|
|
239
|
+
export const Details: Function;
|
|
240
|
+
/**
|
|
241
|
+
* Creates a summary element.
|
|
242
|
+
*/
|
|
243
|
+
export const Summary: Function;
|
|
244
|
+
/**
|
|
245
|
+
* Creates an em element.
|
|
246
|
+
*/
|
|
247
|
+
export const Em: Function;
|
|
248
|
+
/**
|
|
249
|
+
* Creates a strong element.
|
|
250
|
+
*/
|
|
251
|
+
export const Strong: Function;
|
|
252
|
+
/**
|
|
253
|
+
* Creates a small element.
|
|
254
|
+
*/
|
|
255
|
+
export const Small: Function;
|
|
256
|
+
/**
|
|
257
|
+
* Creates a s element (strikethrough).
|
|
258
|
+
*/
|
|
259
|
+
export const S: Function;
|
|
260
|
+
/**
|
|
261
|
+
* Creates a cite element.
|
|
262
|
+
*/
|
|
263
|
+
export const Cite: Function;
|
|
264
|
+
/**
|
|
265
|
+
* Creates a q element (inline quotation).
|
|
266
|
+
*/
|
|
267
|
+
export const Q: Function;
|
|
268
|
+
/**
|
|
269
|
+
* Creates a dfn element (definition element).
|
|
270
|
+
*/
|
|
271
|
+
export const Dfn: Function;
|
|
272
|
+
/**
|
|
273
|
+
* Creates an abbr element (abbreviation).
|
|
274
|
+
*/
|
|
275
|
+
export const Abbr: Function;
|
|
276
|
+
/**
|
|
277
|
+
* Creates a data element.
|
|
278
|
+
*/
|
|
279
|
+
export const Data: Function;
|
|
280
|
+
/**
|
|
281
|
+
* Creates a time element.
|
|
282
|
+
*/
|
|
283
|
+
export const Time: Function;
|
|
284
|
+
/**
|
|
285
|
+
* Creates a var element (variable).
|
|
286
|
+
*/
|
|
287
|
+
export const Var: Function;
|
|
288
|
+
/**
|
|
289
|
+
* Creates a samp element (sample output).
|
|
290
|
+
*/
|
|
291
|
+
export const Samp: Function;
|
|
292
|
+
/**
|
|
293
|
+
* Creates a kbd element (keyboard input).
|
|
294
|
+
*/
|
|
295
|
+
export const Kbd: Function;
|
|
296
|
+
/**
|
|
297
|
+
* Creates a sub element (subscript).
|
|
298
|
+
*/
|
|
299
|
+
export const Sub: Function;
|
|
300
|
+
/**
|
|
301
|
+
* Creates a sup element (superscript).
|
|
302
|
+
*/
|
|
303
|
+
export const Sup: Function;
|
|
304
|
+
/**
|
|
305
|
+
* Creates an i element (italic).
|
|
306
|
+
*/
|
|
307
|
+
export const I: Function;
|
|
308
|
+
/**
|
|
309
|
+
* Creates a b element (bold).
|
|
310
|
+
*/
|
|
311
|
+
export const B: Function;
|
|
312
|
+
/**
|
|
313
|
+
* Creates a u element (underline).
|
|
314
|
+
*/
|
|
315
|
+
export const U: Function;
|
|
316
|
+
/**
|
|
317
|
+
* Creates a mark element.
|
|
318
|
+
*/
|
|
319
|
+
export const Mark: Function;
|
|
320
|
+
/**
|
|
321
|
+
* Creates a ruby element (for East Asian typography).
|
|
322
|
+
*/
|
|
323
|
+
export const Ruby: Function;
|
|
324
|
+
/**
|
|
325
|
+
* Creates an rt element (explanation/pronunciation of characters in East Asian typography).
|
|
326
|
+
*/
|
|
327
|
+
export const Rt: Function;
|
|
328
|
+
/**
|
|
329
|
+
* Creates an rp element (for East Asian fallback parenthesis).
|
|
330
|
+
*/
|
|
331
|
+
export const Rp: Function;
|
|
332
|
+
/**
|
|
333
|
+
* Creates a bdi element (Bi-Directional Isolation).
|
|
334
|
+
*/
|
|
335
|
+
export const Bdi: Function;
|
|
336
|
+
/**
|
|
337
|
+
* Creates a bdo element (Bi-Directional Override).
|
|
338
|
+
*/
|
|
339
|
+
export const Bdo: Function;
|
|
340
|
+
/**
|
|
341
|
+
* Creates a wbr element (Word Break Opportunity).
|
|
342
|
+
*/
|
|
343
|
+
export const Wbr: Function;
|
|
@@ -0,0 +1,99 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Component
|
|
3
|
+
*
|
|
4
|
+
* This will allow components to be extended
|
|
5
|
+
* from a single factory.
|
|
6
|
+
*
|
|
7
|
+
* @class
|
|
8
|
+
* @augments Unit
|
|
9
|
+
*
|
|
10
|
+
* @example
|
|
11
|
+
* class QuickFlashPanel extends Component
|
|
12
|
+
* {
|
|
13
|
+
* render()
|
|
14
|
+
* {
|
|
15
|
+
* return {
|
|
16
|
+
*
|
|
17
|
+
* };
|
|
18
|
+
* }
|
|
19
|
+
* }
|
|
20
|
+
*/
|
|
21
|
+
export class Component extends Unit {
|
|
22
|
+
/**
|
|
23
|
+
* @param {boolean} isComponent
|
|
24
|
+
*/
|
|
25
|
+
isComponent: boolean;
|
|
26
|
+
/**
|
|
27
|
+
* @member {string} [stateTargetId] // optional override of state id
|
|
28
|
+
*/
|
|
29
|
+
stateTargetId: any;
|
|
30
|
+
/**
|
|
31
|
+
* This will initialize the component.
|
|
32
|
+
*
|
|
33
|
+
* @protected
|
|
34
|
+
* @returns {object}
|
|
35
|
+
*/
|
|
36
|
+
protected initialize(): object;
|
|
37
|
+
/**
|
|
38
|
+
* This will setup the state target.
|
|
39
|
+
*
|
|
40
|
+
* @protected
|
|
41
|
+
* @param {string} [id]
|
|
42
|
+
* @returns {void}
|
|
43
|
+
*/
|
|
44
|
+
protected setupStateTarget(id?: string): void;
|
|
45
|
+
/**
|
|
46
|
+
* Override this to setup the component states.
|
|
47
|
+
*
|
|
48
|
+
* @protected
|
|
49
|
+
* @returns {object}
|
|
50
|
+
*/
|
|
51
|
+
protected setupStates(): object;
|
|
52
|
+
/**
|
|
53
|
+
* This will add the states.
|
|
54
|
+
*
|
|
55
|
+
* @protected
|
|
56
|
+
* @returns {void}
|
|
57
|
+
*/
|
|
58
|
+
protected addStates(): void;
|
|
59
|
+
stateHelper: StateHelper;
|
|
60
|
+
/**
|
|
61
|
+
* This will remove the states.
|
|
62
|
+
*
|
|
63
|
+
* @protected
|
|
64
|
+
* @returns {void}
|
|
65
|
+
*/
|
|
66
|
+
protected removeStates(): void;
|
|
67
|
+
/**
|
|
68
|
+
* This will setup the event helper.
|
|
69
|
+
*
|
|
70
|
+
* @protected
|
|
71
|
+
* @returns {void}
|
|
72
|
+
*/
|
|
73
|
+
protected setupEventHelper(): void;
|
|
74
|
+
events: EventHelper;
|
|
75
|
+
/**
|
|
76
|
+
* This will setup the events.
|
|
77
|
+
*
|
|
78
|
+
* @protected
|
|
79
|
+
* @returns {array}
|
|
80
|
+
*/
|
|
81
|
+
protected setupEvents(): any[];
|
|
82
|
+
/**
|
|
83
|
+
* This will add the events.
|
|
84
|
+
*
|
|
85
|
+
* @protected
|
|
86
|
+
* @returns {void}
|
|
87
|
+
*/
|
|
88
|
+
protected addEvents(): void;
|
|
89
|
+
/**
|
|
90
|
+
* This will remove the events.
|
|
91
|
+
*
|
|
92
|
+
* @protected
|
|
93
|
+
* @returns {void}
|
|
94
|
+
*/
|
|
95
|
+
protected removeEvents(): void;
|
|
96
|
+
}
|
|
97
|
+
import { Unit } from './unit.js';
|
|
98
|
+
import { StateHelper } from './state-helper.js';
|
|
99
|
+
import { EventHelper } from './event-helper.js';
|
|
@@ -0,0 +1,59 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* EventHelper
|
|
3
|
+
*
|
|
4
|
+
* This will create an event object to make
|
|
5
|
+
* adding and removing events easier.
|
|
6
|
+
*
|
|
7
|
+
* @class
|
|
8
|
+
*/
|
|
9
|
+
export class EventHelper {
|
|
10
|
+
/**
|
|
11
|
+
* @member {array} events
|
|
12
|
+
*/
|
|
13
|
+
events: any[];
|
|
14
|
+
/**
|
|
15
|
+
* This will add an array of events.
|
|
16
|
+
*
|
|
17
|
+
* @param {array} events
|
|
18
|
+
* @returns {void}
|
|
19
|
+
*/
|
|
20
|
+
addEvents(events: any[]): void;
|
|
21
|
+
/**
|
|
22
|
+
* This will add an event.
|
|
23
|
+
*
|
|
24
|
+
* @param {string} event
|
|
25
|
+
* @param {object} obj
|
|
26
|
+
* @param {function} callBack
|
|
27
|
+
* @param {boolean} capture
|
|
28
|
+
* @returns {void}
|
|
29
|
+
*/
|
|
30
|
+
on(event: string, obj: object, callBack: Function, capture: boolean): void;
|
|
31
|
+
/**
|
|
32
|
+
* This will remove an event.
|
|
33
|
+
*
|
|
34
|
+
* @param {string} event
|
|
35
|
+
* @param {object} obj
|
|
36
|
+
* @param {function} callBack
|
|
37
|
+
* @param {boolean} capture
|
|
38
|
+
* @returns {void}
|
|
39
|
+
*/
|
|
40
|
+
off(event: string, obj: object, callBack: Function, capture: boolean): void;
|
|
41
|
+
/**
|
|
42
|
+
* This will set all events.
|
|
43
|
+
*
|
|
44
|
+
* @returns {void}
|
|
45
|
+
*/
|
|
46
|
+
set(): void;
|
|
47
|
+
/**
|
|
48
|
+
* This will unset all events.
|
|
49
|
+
*
|
|
50
|
+
* @returns {void}
|
|
51
|
+
*/
|
|
52
|
+
unset(): void;
|
|
53
|
+
/**
|
|
54
|
+
* This will reset the events.
|
|
55
|
+
*
|
|
56
|
+
* @returns {void}
|
|
57
|
+
*/
|
|
58
|
+
reset(): void;
|
|
59
|
+
}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export function Jot(layout: object | Function): Function | object;
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export function parseArgs(args: any[]): object;
|
|
@@ -0,0 +1,102 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* StateHelper
|
|
3
|
+
*
|
|
4
|
+
* This is a helper to manage component states.
|
|
5
|
+
*
|
|
6
|
+
* @class
|
|
7
|
+
*/
|
|
8
|
+
export class StateHelper {
|
|
9
|
+
/**
|
|
10
|
+
* This will create a state helper.
|
|
11
|
+
*
|
|
12
|
+
* @constructor
|
|
13
|
+
* @param {object} state
|
|
14
|
+
* @param {object} states
|
|
15
|
+
*/
|
|
16
|
+
constructor(state: object, states: object);
|
|
17
|
+
/**
|
|
18
|
+
* @member {array} remoteStates
|
|
19
|
+
*/
|
|
20
|
+
remoteStates: any[];
|
|
21
|
+
/**
|
|
22
|
+
* This will add states to a state.
|
|
23
|
+
*
|
|
24
|
+
* @param {object} state
|
|
25
|
+
* @param {object} states
|
|
26
|
+
* @returns {void}
|
|
27
|
+
*/
|
|
28
|
+
addStates(state: object, states: object): void;
|
|
29
|
+
/**
|
|
30
|
+
* This will create a state object.
|
|
31
|
+
*
|
|
32
|
+
* @param {string} action
|
|
33
|
+
* @param {*} state
|
|
34
|
+
* @param {function} callBack
|
|
35
|
+
* @param {string} [targetId]
|
|
36
|
+
* @returns {object}
|
|
37
|
+
*/
|
|
38
|
+
createState(action: string, state: any, callBack: Function, targetId?: string): object;
|
|
39
|
+
/**
|
|
40
|
+
* This will convert an action object to a state array.
|
|
41
|
+
*
|
|
42
|
+
* @protected
|
|
43
|
+
* @param {object} action
|
|
44
|
+
* @returns {array}
|
|
45
|
+
*/
|
|
46
|
+
protected convertStates(action: object): any[];
|
|
47
|
+
/**
|
|
48
|
+
* This will setup remote states.
|
|
49
|
+
*
|
|
50
|
+
* @protected
|
|
51
|
+
* @param {array} remotes
|
|
52
|
+
* @param {array} actions
|
|
53
|
+
* @returns {void}
|
|
54
|
+
*/
|
|
55
|
+
protected setupRemoteStates(remotes: any[], actions: any[]): void;
|
|
56
|
+
/**
|
|
57
|
+
* This will remove remote states.
|
|
58
|
+
*
|
|
59
|
+
* @returns {void}
|
|
60
|
+
*/
|
|
61
|
+
removeRemoteStates(): void;
|
|
62
|
+
/**
|
|
63
|
+
* This will remove the actions.
|
|
64
|
+
*
|
|
65
|
+
* @param {array} actions
|
|
66
|
+
* @returns {void}
|
|
67
|
+
*/
|
|
68
|
+
removeActions(actions: any[]): void;
|
|
69
|
+
/**
|
|
70
|
+
* This will restore a state.
|
|
71
|
+
*
|
|
72
|
+
* @param {object} state
|
|
73
|
+
* @returns {void}
|
|
74
|
+
*/
|
|
75
|
+
restore(state: object): void;
|
|
76
|
+
/**
|
|
77
|
+
* This will setup a two way bind to a remote state.
|
|
78
|
+
*
|
|
79
|
+
* @param {object} target
|
|
80
|
+
* @param {string} actionEvent
|
|
81
|
+
* @param {string} remoteTargetId
|
|
82
|
+
* @returns {string}
|
|
83
|
+
*/
|
|
84
|
+
bindRemoteState(target: object, actionEvent: string, remoteTargetId: string): string;
|
|
85
|
+
/**
|
|
86
|
+
* This will add the states to the target.
|
|
87
|
+
*
|
|
88
|
+
* @protected
|
|
89
|
+
* @param {object} state
|
|
90
|
+
* @param {array} actions
|
|
91
|
+
* @returns {void}
|
|
92
|
+
*/
|
|
93
|
+
protected addStatesToTarget(state: object, actions: any[]): void;
|
|
94
|
+
/**
|
|
95
|
+
* This will add an action.
|
|
96
|
+
*
|
|
97
|
+
* @param {object} target
|
|
98
|
+
* @param {object} action
|
|
99
|
+
* @returns {string}
|
|
100
|
+
*/
|
|
101
|
+
addAction(target: object, action: object): string;
|
|
102
|
+
}
|