@appkit/dek-plugin 0.25.0 → 0.26.0
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/index.d.ts +2 -2
- package/dist/index.es.js +48 -40
- package/dist/index.umd.js +48 -40
- package/dist/lib/api.d.ts +55 -23
- package/dist/lib/plugins.d.ts +1 -0
- package/package.json +1 -1
package/dist/index.d.ts
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
|
-
export type { DekPlugin, DekPluginBoardItem, DekPluginComponentItem, DekPluginConfig, DekPluginElementFactoryWithProps, DekPluginElementProps, DekPluginFactory, DekPluginSchema, DekPluginSchemaItem, DekPluginScreenItem, } from './lib/plugins';
|
|
1
|
+
export type { DekIntegration, DekPlugin, DekPluginBoardItem, DekPluginComponentItem, DekPluginConfig, DekPluginElementFactoryWithProps, DekPluginElementProps, DekPluginFactory, DekPluginSchema, DekPluginSchemaItem, DekPluginSchemaItemOption, DekPluginSchemaType, DekPluginScreenItem, } from './lib/plugins';
|
|
2
2
|
export type { DekRegistry, DekRegistryCollection, DekRegistryCollectionItem, DekRegistrySchema, DekRegistrySchemaItem, DekRegistrySchemaProps, DekRegistrySchemaPropsItem, } from './lib/registry';
|
|
3
|
-
export type { DekApi, DekApiInfo, DekApiMessage, DekApiMessageType, DekApiPlugin, DekApiState, } from './lib/api';
|
|
3
|
+
export type { DekApi, DekApiInfo, DekApiMessage, DekApiMessageType, DekApiIntegration as DekApiPlugin, DekApiState, DekBoard, DekBoardBase, DekBoardProperty, DekCommand, DekCommandGroup, DekComponent, DekZone, } from './lib/api';
|
|
4
4
|
export { default as usePluginState } from './lib/hooks/usePluginState';
|
|
5
5
|
export { default as usePluginStateObject } from './lib/hooks/usePluginStateObject';
|
|
6
6
|
export declare function __debug(): void;
|
package/dist/index.es.js
CHANGED
|
@@ -188,8 +188,8 @@ class Api {
|
|
|
188
188
|
messages() {
|
|
189
189
|
return this.internal.messages();
|
|
190
190
|
}
|
|
191
|
-
|
|
192
|
-
return this.internal.
|
|
191
|
+
integration(key) {
|
|
192
|
+
return this.internal.integration(key);
|
|
193
193
|
}
|
|
194
194
|
get registry() {
|
|
195
195
|
return this.internal.registry;
|
|
@@ -221,26 +221,26 @@ class Api {
|
|
|
221
221
|
open(boardKey) {
|
|
222
222
|
this.internal.open(boardKey);
|
|
223
223
|
}
|
|
224
|
-
get
|
|
225
|
-
return this.internal.
|
|
224
|
+
get integrations() {
|
|
225
|
+
return this.internal.integrations;
|
|
226
226
|
}
|
|
227
227
|
get api() {
|
|
228
|
-
return this.
|
|
228
|
+
return this.integration(this.integrationKey).api;
|
|
229
229
|
}
|
|
230
230
|
get state() {
|
|
231
|
-
return this.
|
|
231
|
+
return this.integration(this.integrationKey).state;
|
|
232
232
|
}
|
|
233
233
|
get info() {
|
|
234
|
-
return this.
|
|
234
|
+
return this.integration(this.integrationKey).info;
|
|
235
235
|
}
|
|
236
236
|
component(key, props) {
|
|
237
|
-
return this.
|
|
237
|
+
return this.integration(this.integrationKey).component(key, props);
|
|
238
238
|
}
|
|
239
239
|
componentSchema(key) {
|
|
240
|
-
return this.
|
|
240
|
+
return this.integration(this.integrationKey).componentSchema(key);
|
|
241
241
|
}
|
|
242
242
|
screen(path) {
|
|
243
|
-
return this.
|
|
243
|
+
return this.integration(this.integrationKey).screen(path);
|
|
244
244
|
}
|
|
245
245
|
}
|
|
246
246
|
class ApiInternal {
|
|
@@ -274,8 +274,8 @@ class ApiInternal {
|
|
|
274
274
|
messages() {
|
|
275
275
|
return this.globals.messages;
|
|
276
276
|
}
|
|
277
|
-
|
|
278
|
-
return this.
|
|
277
|
+
integration(key) {
|
|
278
|
+
return this.createIntegrationWrapper(key);
|
|
279
279
|
}
|
|
280
280
|
get registry() {
|
|
281
281
|
return this.globals.registry;
|
|
@@ -288,6 +288,8 @@ class ApiInternal {
|
|
|
288
288
|
}
|
|
289
289
|
get board() {
|
|
290
290
|
return this.boards.find((board) => board.key === this.boardKey) || {
|
|
291
|
+
title: "Missing board",
|
|
292
|
+
key: "#error",
|
|
291
293
|
zones: []
|
|
292
294
|
};
|
|
293
295
|
}
|
|
@@ -309,20 +311,20 @@ class ApiInternal {
|
|
|
309
311
|
open(boardKey) {
|
|
310
312
|
this.globals.setLocation(`/${boardKey}`);
|
|
311
313
|
}
|
|
312
|
-
|
|
313
|
-
const
|
|
314
|
-
const available = !!
|
|
314
|
+
createIntegrationWrapper(integrationKey) {
|
|
315
|
+
const integration = this.getIntegrationInstance(integrationKey);
|
|
316
|
+
const available = !!integration;
|
|
315
317
|
return {
|
|
316
318
|
available,
|
|
317
319
|
info: {
|
|
318
|
-
components: (
|
|
319
|
-
screens: (
|
|
320
|
+
components: (integration == null ? void 0 : integration.components) ? integration.components.map((component) => component.key) : [],
|
|
321
|
+
screens: (integration == null ? void 0 : integration.screens) ? integration.screens.map((screen) => screen.path) : []
|
|
320
322
|
},
|
|
321
323
|
component: (key, props) => this.getComponent(integrationKey, key, props),
|
|
322
324
|
componentSchema: (key) => this.getComponentSchema(integrationKey, key),
|
|
323
325
|
screen: (path) => this.getScreen(integrationKey, path),
|
|
324
326
|
board: (key) => this.getBoard(integrationKey, key),
|
|
325
|
-
api: (
|
|
327
|
+
api: (integration == null ? void 0 : integration.api) || {},
|
|
326
328
|
state: {
|
|
327
329
|
get: (key, defaultValue) => {
|
|
328
330
|
if (!available) {
|
|
@@ -342,20 +344,20 @@ class ApiInternal {
|
|
|
342
344
|
get globals() {
|
|
343
345
|
return window.__dek_globals;
|
|
344
346
|
}
|
|
345
|
-
get
|
|
346
|
-
const
|
|
347
|
-
Object.keys(this.globals.
|
|
348
|
-
|
|
347
|
+
get integrations() {
|
|
348
|
+
const integrations = {};
|
|
349
|
+
Object.keys(this.globals.integrationInstances).forEach((key) => {
|
|
350
|
+
integrations[key] = this.createIntegrationWrapper(key);
|
|
349
351
|
});
|
|
350
|
-
return
|
|
352
|
+
return integrations;
|
|
351
353
|
}
|
|
352
|
-
|
|
353
|
-
return this.globals.
|
|
354
|
+
getIntegrationInstance(integrationKey) {
|
|
355
|
+
return this.globals.integrationInstances[integrationKey];
|
|
354
356
|
}
|
|
355
357
|
getComponent(integrationKey, componentKey, props) {
|
|
356
|
-
const
|
|
357
|
-
if (
|
|
358
|
-
const component =
|
|
358
|
+
const integration = this.getIntegrationInstance(integrationKey);
|
|
359
|
+
if (integration) {
|
|
360
|
+
const component = integration.components && integration.components.find(
|
|
359
361
|
(c) => c.key.toLowerCase() === componentKey.toLowerCase()
|
|
360
362
|
);
|
|
361
363
|
if (!component) {
|
|
@@ -363,15 +365,15 @@ class ApiInternal {
|
|
|
363
365
|
}
|
|
364
366
|
return component.element({
|
|
365
367
|
...props,
|
|
366
|
-
plugin,
|
|
368
|
+
plugin: integration,
|
|
367
369
|
api: new Api(integrationKey)
|
|
368
370
|
});
|
|
369
371
|
}
|
|
370
372
|
}
|
|
371
373
|
getComponentSchema(integrationKey, componentKey) {
|
|
372
|
-
const
|
|
373
|
-
if (
|
|
374
|
-
const component =
|
|
374
|
+
const integration = this.getIntegrationInstance(integrationKey);
|
|
375
|
+
if (integration) {
|
|
376
|
+
const component = integration.components && integration.components.find(
|
|
375
377
|
(c) => c.key.toLowerCase() === componentKey.toLowerCase()
|
|
376
378
|
);
|
|
377
379
|
if (component) {
|
|
@@ -382,29 +384,35 @@ class ApiInternal {
|
|
|
382
384
|
}
|
|
383
385
|
getScreen(integrationKey, screenPath) {
|
|
384
386
|
if (integrationKey) {
|
|
385
|
-
const
|
|
386
|
-
if (
|
|
387
|
-
const component =
|
|
387
|
+
const integration = this.getIntegrationInstance(integrationKey);
|
|
388
|
+
if (integration) {
|
|
389
|
+
const component = integration.screens && integration.screens.find(
|
|
388
390
|
(s) => s.path.toLowerCase() === screenPath.toLowerCase()
|
|
389
391
|
);
|
|
390
392
|
if (!component) {
|
|
391
393
|
return;
|
|
392
394
|
}
|
|
393
|
-
return component.element({
|
|
395
|
+
return component.element({
|
|
396
|
+
plugin: integration,
|
|
397
|
+
api: new Api(integrationKey)
|
|
398
|
+
});
|
|
394
399
|
}
|
|
395
400
|
}
|
|
396
401
|
}
|
|
397
402
|
getBoard(integrationKey, boardKey) {
|
|
398
403
|
if (integrationKey) {
|
|
399
|
-
const
|
|
400
|
-
if (
|
|
401
|
-
const component =
|
|
404
|
+
const integration = this.getIntegrationInstance(integrationKey);
|
|
405
|
+
if (integration) {
|
|
406
|
+
const component = integration.boards && integration.boards.find(
|
|
402
407
|
(c) => c.key.toLowerCase() === boardKey.toLowerCase()
|
|
403
408
|
);
|
|
404
409
|
if (!component) {
|
|
405
410
|
return;
|
|
406
411
|
}
|
|
407
|
-
return component.element({
|
|
412
|
+
return component.element({
|
|
413
|
+
plugin: integration,
|
|
414
|
+
api: new Api(integrationKey)
|
|
415
|
+
});
|
|
408
416
|
}
|
|
409
417
|
}
|
|
410
418
|
}
|
package/dist/index.umd.js
CHANGED
|
@@ -191,8 +191,8 @@ var __publicField = (obj, key, value) => {
|
|
|
191
191
|
messages() {
|
|
192
192
|
return this.internal.messages();
|
|
193
193
|
}
|
|
194
|
-
|
|
195
|
-
return this.internal.
|
|
194
|
+
integration(key) {
|
|
195
|
+
return this.internal.integration(key);
|
|
196
196
|
}
|
|
197
197
|
get registry() {
|
|
198
198
|
return this.internal.registry;
|
|
@@ -224,26 +224,26 @@ var __publicField = (obj, key, value) => {
|
|
|
224
224
|
open(boardKey) {
|
|
225
225
|
this.internal.open(boardKey);
|
|
226
226
|
}
|
|
227
|
-
get
|
|
228
|
-
return this.internal.
|
|
227
|
+
get integrations() {
|
|
228
|
+
return this.internal.integrations;
|
|
229
229
|
}
|
|
230
230
|
get api() {
|
|
231
|
-
return this.
|
|
231
|
+
return this.integration(this.integrationKey).api;
|
|
232
232
|
}
|
|
233
233
|
get state() {
|
|
234
|
-
return this.
|
|
234
|
+
return this.integration(this.integrationKey).state;
|
|
235
235
|
}
|
|
236
236
|
get info() {
|
|
237
|
-
return this.
|
|
237
|
+
return this.integration(this.integrationKey).info;
|
|
238
238
|
}
|
|
239
239
|
component(key, props) {
|
|
240
|
-
return this.
|
|
240
|
+
return this.integration(this.integrationKey).component(key, props);
|
|
241
241
|
}
|
|
242
242
|
componentSchema(key) {
|
|
243
|
-
return this.
|
|
243
|
+
return this.integration(this.integrationKey).componentSchema(key);
|
|
244
244
|
}
|
|
245
245
|
screen(path) {
|
|
246
|
-
return this.
|
|
246
|
+
return this.integration(this.integrationKey).screen(path);
|
|
247
247
|
}
|
|
248
248
|
}
|
|
249
249
|
class ApiInternal {
|
|
@@ -277,8 +277,8 @@ var __publicField = (obj, key, value) => {
|
|
|
277
277
|
messages() {
|
|
278
278
|
return this.globals.messages;
|
|
279
279
|
}
|
|
280
|
-
|
|
281
|
-
return this.
|
|
280
|
+
integration(key) {
|
|
281
|
+
return this.createIntegrationWrapper(key);
|
|
282
282
|
}
|
|
283
283
|
get registry() {
|
|
284
284
|
return this.globals.registry;
|
|
@@ -291,6 +291,8 @@ var __publicField = (obj, key, value) => {
|
|
|
291
291
|
}
|
|
292
292
|
get board() {
|
|
293
293
|
return this.boards.find((board) => board.key === this.boardKey) || {
|
|
294
|
+
title: "Missing board",
|
|
295
|
+
key: "#error",
|
|
294
296
|
zones: []
|
|
295
297
|
};
|
|
296
298
|
}
|
|
@@ -312,20 +314,20 @@ var __publicField = (obj, key, value) => {
|
|
|
312
314
|
open(boardKey) {
|
|
313
315
|
this.globals.setLocation(`/${boardKey}`);
|
|
314
316
|
}
|
|
315
|
-
|
|
316
|
-
const
|
|
317
|
-
const available = !!
|
|
317
|
+
createIntegrationWrapper(integrationKey) {
|
|
318
|
+
const integration = this.getIntegrationInstance(integrationKey);
|
|
319
|
+
const available = !!integration;
|
|
318
320
|
return {
|
|
319
321
|
available,
|
|
320
322
|
info: {
|
|
321
|
-
components: (
|
|
322
|
-
screens: (
|
|
323
|
+
components: (integration == null ? void 0 : integration.components) ? integration.components.map((component) => component.key) : [],
|
|
324
|
+
screens: (integration == null ? void 0 : integration.screens) ? integration.screens.map((screen) => screen.path) : []
|
|
323
325
|
},
|
|
324
326
|
component: (key, props) => this.getComponent(integrationKey, key, props),
|
|
325
327
|
componentSchema: (key) => this.getComponentSchema(integrationKey, key),
|
|
326
328
|
screen: (path) => this.getScreen(integrationKey, path),
|
|
327
329
|
board: (key) => this.getBoard(integrationKey, key),
|
|
328
|
-
api: (
|
|
330
|
+
api: (integration == null ? void 0 : integration.api) || {},
|
|
329
331
|
state: {
|
|
330
332
|
get: (key, defaultValue) => {
|
|
331
333
|
if (!available) {
|
|
@@ -345,20 +347,20 @@ var __publicField = (obj, key, value) => {
|
|
|
345
347
|
get globals() {
|
|
346
348
|
return window.__dek_globals;
|
|
347
349
|
}
|
|
348
|
-
get
|
|
349
|
-
const
|
|
350
|
-
Object.keys(this.globals.
|
|
351
|
-
|
|
350
|
+
get integrations() {
|
|
351
|
+
const integrations = {};
|
|
352
|
+
Object.keys(this.globals.integrationInstances).forEach((key) => {
|
|
353
|
+
integrations[key] = this.createIntegrationWrapper(key);
|
|
352
354
|
});
|
|
353
|
-
return
|
|
355
|
+
return integrations;
|
|
354
356
|
}
|
|
355
|
-
|
|
356
|
-
return this.globals.
|
|
357
|
+
getIntegrationInstance(integrationKey) {
|
|
358
|
+
return this.globals.integrationInstances[integrationKey];
|
|
357
359
|
}
|
|
358
360
|
getComponent(integrationKey, componentKey, props) {
|
|
359
|
-
const
|
|
360
|
-
if (
|
|
361
|
-
const component =
|
|
361
|
+
const integration = this.getIntegrationInstance(integrationKey);
|
|
362
|
+
if (integration) {
|
|
363
|
+
const component = integration.components && integration.components.find(
|
|
362
364
|
(c) => c.key.toLowerCase() === componentKey.toLowerCase()
|
|
363
365
|
);
|
|
364
366
|
if (!component) {
|
|
@@ -366,15 +368,15 @@ var __publicField = (obj, key, value) => {
|
|
|
366
368
|
}
|
|
367
369
|
return component.element({
|
|
368
370
|
...props,
|
|
369
|
-
plugin,
|
|
371
|
+
plugin: integration,
|
|
370
372
|
api: new Api(integrationKey)
|
|
371
373
|
});
|
|
372
374
|
}
|
|
373
375
|
}
|
|
374
376
|
getComponentSchema(integrationKey, componentKey) {
|
|
375
|
-
const
|
|
376
|
-
if (
|
|
377
|
-
const component =
|
|
377
|
+
const integration = this.getIntegrationInstance(integrationKey);
|
|
378
|
+
if (integration) {
|
|
379
|
+
const component = integration.components && integration.components.find(
|
|
378
380
|
(c) => c.key.toLowerCase() === componentKey.toLowerCase()
|
|
379
381
|
);
|
|
380
382
|
if (component) {
|
|
@@ -385,29 +387,35 @@ var __publicField = (obj, key, value) => {
|
|
|
385
387
|
}
|
|
386
388
|
getScreen(integrationKey, screenPath) {
|
|
387
389
|
if (integrationKey) {
|
|
388
|
-
const
|
|
389
|
-
if (
|
|
390
|
-
const component =
|
|
390
|
+
const integration = this.getIntegrationInstance(integrationKey);
|
|
391
|
+
if (integration) {
|
|
392
|
+
const component = integration.screens && integration.screens.find(
|
|
391
393
|
(s) => s.path.toLowerCase() === screenPath.toLowerCase()
|
|
392
394
|
);
|
|
393
395
|
if (!component) {
|
|
394
396
|
return;
|
|
395
397
|
}
|
|
396
|
-
return component.element({
|
|
398
|
+
return component.element({
|
|
399
|
+
plugin: integration,
|
|
400
|
+
api: new Api(integrationKey)
|
|
401
|
+
});
|
|
397
402
|
}
|
|
398
403
|
}
|
|
399
404
|
}
|
|
400
405
|
getBoard(integrationKey, boardKey) {
|
|
401
406
|
if (integrationKey) {
|
|
402
|
-
const
|
|
403
|
-
if (
|
|
404
|
-
const component =
|
|
407
|
+
const integration = this.getIntegrationInstance(integrationKey);
|
|
408
|
+
if (integration) {
|
|
409
|
+
const component = integration.boards && integration.boards.find(
|
|
405
410
|
(c) => c.key.toLowerCase() === boardKey.toLowerCase()
|
|
406
411
|
);
|
|
407
412
|
if (!component) {
|
|
408
413
|
return;
|
|
409
414
|
}
|
|
410
|
-
return component.element({
|
|
415
|
+
return component.element({
|
|
416
|
+
plugin: integration,
|
|
417
|
+
api: new Api(integrationKey)
|
|
418
|
+
});
|
|
411
419
|
}
|
|
412
420
|
}
|
|
413
421
|
}
|
package/dist/lib/api.d.ts
CHANGED
|
@@ -5,6 +5,38 @@ import { DekApiStateType } from './state';
|
|
|
5
5
|
export type SetLocationFunc = (to: string, options?: {
|
|
6
6
|
replace?: boolean | undefined;
|
|
7
7
|
} | undefined) => void;
|
|
8
|
+
export type DekBoardProperty = {
|
|
9
|
+
key: string;
|
|
10
|
+
value: string;
|
|
11
|
+
};
|
|
12
|
+
export type DekComponent = {
|
|
13
|
+
integration: string;
|
|
14
|
+
component: string;
|
|
15
|
+
props: DekBoardProperty[];
|
|
16
|
+
containerProps: DekBoardProperty[];
|
|
17
|
+
};
|
|
18
|
+
export type DekCommand = DekComponent & {
|
|
19
|
+
title: string;
|
|
20
|
+
};
|
|
21
|
+
export type DekCommandGroup = {
|
|
22
|
+
key: string;
|
|
23
|
+
title: string;
|
|
24
|
+
commands: DekCommand[];
|
|
25
|
+
};
|
|
26
|
+
export type DekZone = DekComponent & {
|
|
27
|
+
key: string;
|
|
28
|
+
};
|
|
29
|
+
export type DekBoardBase = {
|
|
30
|
+
integration: string;
|
|
31
|
+
key: string;
|
|
32
|
+
};
|
|
33
|
+
export type DekBoard = {
|
|
34
|
+
title: string;
|
|
35
|
+
key: string;
|
|
36
|
+
layout?: string | null;
|
|
37
|
+
base?: DekBoardBase | null;
|
|
38
|
+
zones: DekZone[];
|
|
39
|
+
};
|
|
8
40
|
export type DekApiState = {
|
|
9
41
|
get: (key: string, defaultValue?: DekApiStateType) => DekApiStateType | undefined;
|
|
10
42
|
set: (key: string, value: DekApiStateType) => void;
|
|
@@ -13,7 +45,7 @@ export type DekApiInfo = {
|
|
|
13
45
|
components: string[];
|
|
14
46
|
screens: string[];
|
|
15
47
|
};
|
|
16
|
-
export type
|
|
48
|
+
export type DekApiIntegration = {
|
|
17
49
|
available: boolean;
|
|
18
50
|
component: (key: string, props?: any) => JSX.Element | undefined;
|
|
19
51
|
componentSchema: (key: string) => DekPluginSchema;
|
|
@@ -35,36 +67,36 @@ export type DekApiInternal = {
|
|
|
35
67
|
warn: (integrationKey: string, message: string, ...data: any[]) => void;
|
|
36
68
|
error: (integrationKey: string, message: string, ...data: any[]) => void;
|
|
37
69
|
messages: () => DekApiMessage[];
|
|
38
|
-
|
|
70
|
+
integration: (key: string) => DekApiIntegration;
|
|
39
71
|
registry: DekRegistry;
|
|
40
72
|
boardKey: string;
|
|
41
|
-
boards:
|
|
42
|
-
board:
|
|
73
|
+
boards: DekBoard[];
|
|
74
|
+
board: DekBoard;
|
|
43
75
|
layout: string;
|
|
44
|
-
commandGroups:
|
|
76
|
+
commandGroups: DekCommandGroup[];
|
|
45
77
|
navigate: (path: string) => void;
|
|
46
78
|
navigateParams: Record<string, string | undefined>;
|
|
47
79
|
navigateBack: () => void;
|
|
48
80
|
open: (boardKey: string) => void;
|
|
49
|
-
|
|
81
|
+
integrations: Record<string, DekApiIntegration>;
|
|
50
82
|
};
|
|
51
83
|
export type DekApi = {
|
|
52
84
|
trace: (message: string, ...data: any[]) => void;
|
|
53
85
|
warn: (message: string, ...data: any[]) => void;
|
|
54
86
|
error: (message: string, ...data: any[]) => void;
|
|
55
87
|
messages: () => DekApiMessage[];
|
|
56
|
-
|
|
88
|
+
integration: (key: string) => DekApiIntegration;
|
|
57
89
|
registry: DekRegistry;
|
|
58
90
|
boardKey: string;
|
|
59
|
-
boards:
|
|
60
|
-
board:
|
|
91
|
+
boards: DekBoard[];
|
|
92
|
+
board: DekBoard;
|
|
61
93
|
layout: string;
|
|
62
|
-
commandGroups:
|
|
94
|
+
commandGroups: DekCommandGroup[];
|
|
63
95
|
navigate: (path: string) => void;
|
|
64
96
|
navigateParams: Record<string, string | undefined>;
|
|
65
97
|
navigateBack: () => void;
|
|
66
98
|
open: (boardKey: string) => void;
|
|
67
|
-
|
|
99
|
+
integrations: Record<string, DekApiIntegration>;
|
|
68
100
|
};
|
|
69
101
|
export declare class Api implements DekApi {
|
|
70
102
|
integrationKey: string;
|
|
@@ -74,18 +106,18 @@ export declare class Api implements DekApi {
|
|
|
74
106
|
warn(message: string, ...data: any[]): void;
|
|
75
107
|
error(message: string, ...data: any[]): void;
|
|
76
108
|
messages(): DekApiMessage[];
|
|
77
|
-
|
|
109
|
+
integration(key: string): DekApiIntegration;
|
|
78
110
|
get registry(): DekRegistry;
|
|
79
111
|
get boardKey(): string;
|
|
80
|
-
get boards():
|
|
81
|
-
get board():
|
|
112
|
+
get boards(): DekBoard[];
|
|
113
|
+
get board(): DekBoard;
|
|
82
114
|
get layout(): string;
|
|
83
|
-
get commandGroups():
|
|
115
|
+
get commandGroups(): DekCommandGroup[];
|
|
84
116
|
navigate(path: string): void;
|
|
85
117
|
get navigateParams(): Record<string, string | undefined>;
|
|
86
118
|
navigateBack(): void;
|
|
87
119
|
open(boardKey: string): void;
|
|
88
|
-
get
|
|
120
|
+
get integrations(): Record<string, DekApiIntegration>;
|
|
89
121
|
get api(): any;
|
|
90
122
|
get state(): DekApiState;
|
|
91
123
|
get info(): DekApiInfo;
|
|
@@ -98,21 +130,21 @@ export declare class ApiInternal implements DekApiInternal {
|
|
|
98
130
|
warn(integrationKey: string, message: string, ...data: any[]): void;
|
|
99
131
|
error(integrationKey: string, message: string, ...data: any[]): void;
|
|
100
132
|
messages(): DekApiMessage[];
|
|
101
|
-
|
|
133
|
+
integration(key: string): DekApiIntegration;
|
|
102
134
|
get registry(): DekRegistry;
|
|
103
135
|
get boardKey(): string;
|
|
104
|
-
get boards():
|
|
105
|
-
get board():
|
|
136
|
+
get boards(): DekBoard[];
|
|
137
|
+
get board(): DekBoard;
|
|
106
138
|
get layout(): string;
|
|
107
|
-
get commandGroups():
|
|
139
|
+
get commandGroups(): DekCommandGroup[];
|
|
108
140
|
navigate(path: string): void;
|
|
109
141
|
get navigateParams(): Record<string, string | undefined>;
|
|
110
142
|
navigateBack(): void;
|
|
111
143
|
open(boardKey: string): void;
|
|
112
|
-
private
|
|
144
|
+
private createIntegrationWrapper;
|
|
113
145
|
private get globals();
|
|
114
|
-
get
|
|
115
|
-
private
|
|
146
|
+
get integrations(): Record<string, DekApiIntegration>;
|
|
147
|
+
private getIntegrationInstance;
|
|
116
148
|
private getComponent;
|
|
117
149
|
private getComponentSchema;
|
|
118
150
|
private getScreen;
|
package/dist/lib/plugins.d.ts
CHANGED