@contrail/extensions-sdk 1.0.15 → 1.0.16
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/.github/pull_request_template.md +7 -6
- package/.github/workflows/check-code-formatting.yml +34 -0
- package/.github/workflows/empty.yml +1 -2
- package/.github/workflows/sdk-lib.yml +1 -1
- package/.husky/pre-commit +13 -0
- package/.lintstagedrc-check.json +3 -0
- package/.lintstagedrc-format.json +3 -0
- package/.prettierignore +9 -0
- package/.prettierrc.yaml +2 -0
- package/README.md +1 -0
- package/lib/actions/actions.d.ts +4 -4
- package/lib/apps/app-context.d.ts +1 -1
- package/lib/apps/boards.d.ts +23 -1
- package/lib/apps/boards.js +36 -7
- package/lib/apps/plan.d.ts +1 -1
- package/lib/apps/plan.js +1 -1
- package/lib/entities/entities-client.d.ts +1 -1
- package/lib/entities/entities-client.js +28 -7
- package/lib/extensions/app-extension-host.js +2 -2
- package/lib/extensions/app-extension.js +3 -4
- package/lib/types/types-client.d.ts +1 -1
- package/lib/types/types-client.js +12 -3
- package/package.json +11 -6
|
@@ -1,9 +1,11 @@
|
|
|
1
1
|
## What
|
|
2
|
+
|
|
2
3
|
- [ ] Bugfix
|
|
3
4
|
- [ ] Feature
|
|
4
5
|
- [ ] Enhancement
|
|
5
6
|
|
|
6
|
-
Description:
|
|
7
|
+
Description:
|
|
8
|
+
|
|
7
9
|
<!--
|
|
8
10
|
Describe the functional changes of the PR.
|
|
9
11
|
|
|
@@ -15,16 +17,15 @@ is sufficient.
|
|
|
15
17
|
-->
|
|
16
18
|
|
|
17
19
|
## Why
|
|
18
|
-
|
|
20
|
+
|
|
21
|
+
<!--
|
|
19
22
|
why is this change needed? Same rules as with #What
|
|
20
23
|
-->
|
|
21
24
|
|
|
22
|
-
|
|
23
25
|
## Testing added
|
|
24
|
-
|
|
26
|
+
|
|
27
|
+
<!--
|
|
25
28
|
Describe the testing you added to this PR
|
|
26
29
|
-->
|
|
27
30
|
|
|
28
|
-
|
|
29
31
|
## Link to Jira ticket(s)
|
|
30
|
-
|
|
@@ -0,0 +1,34 @@
|
|
|
1
|
+
name: Check Code Formatting
|
|
2
|
+
on:
|
|
3
|
+
pull_request:
|
|
4
|
+
paths:
|
|
5
|
+
- '**'
|
|
6
|
+
workflow_dispatch: # allow running in github actions manually
|
|
7
|
+
jobs:
|
|
8
|
+
check-formatting:
|
|
9
|
+
runs-on: ubuntu-24.04
|
|
10
|
+
steps:
|
|
11
|
+
- name: Node.js
|
|
12
|
+
uses: actions/setup-node@v3
|
|
13
|
+
with:
|
|
14
|
+
node-version: 18.13.0
|
|
15
|
+
- uses: actions/checkout@v3
|
|
16
|
+
with:
|
|
17
|
+
lfs: true
|
|
18
|
+
- name: Checkout LFS objects
|
|
19
|
+
run: git lfs checkout
|
|
20
|
+
- name: NPM Install
|
|
21
|
+
env:
|
|
22
|
+
NPM_TOKEN: ${{ secrets.NPM_TOKEN }}
|
|
23
|
+
run: npm ci
|
|
24
|
+
- name: Check Format
|
|
25
|
+
working-directory: ./
|
|
26
|
+
run: npx prettier --check .
|
|
27
|
+
- name: Fail On Warnings
|
|
28
|
+
run: |
|
|
29
|
+
if [ $? -eq 0 ]; then
|
|
30
|
+
echo "No formatting issues found"
|
|
31
|
+
else
|
|
32
|
+
echo "Formatting issues found. Run 'npx prettier --write .' to fix them."
|
|
33
|
+
exit 1
|
|
34
|
+
fi
|
|
@@ -0,0 +1,13 @@
|
|
|
1
|
+
#!/bin/sh
|
|
2
|
+
. "$(dirname "$0")/_/husky.sh"
|
|
3
|
+
|
|
4
|
+
if [ "$BYPASS_FORMATTING_CHECK" = "true" ]; then
|
|
5
|
+
echo ""
|
|
6
|
+
echo "⚠️ ======== WARNING ======== ⚠️"
|
|
7
|
+
echo " Formatting Check Bypassed" # This looks off-center but prints correctly
|
|
8
|
+
echo "⚠️ ========================= ⚠️"
|
|
9
|
+
echo ""
|
|
10
|
+
exit 0
|
|
11
|
+
fi
|
|
12
|
+
|
|
13
|
+
npm run lint-staged:check
|
package/.prettierignore
ADDED
package/.prettierrc.yaml
ADDED
package/README.md
CHANGED
package/lib/actions/actions.d.ts
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
|
-
import { AppContext } from
|
|
2
|
-
import { EntitiesClientAction } from
|
|
3
|
-
import { AppExtensionMessage } from
|
|
4
|
-
import { TypesClientAction } from
|
|
1
|
+
import { AppContext } from '../apps/app-context';
|
|
2
|
+
import { EntitiesClientAction } from '../entities/entities-action-handler';
|
|
3
|
+
import { AppExtensionMessage } from '../extensions/app-extension-message-handler';
|
|
4
|
+
import { TypesClientAction } from '../types/types-action-handler';
|
|
5
5
|
export interface RegisterExtensionActions {
|
|
6
6
|
init(context: AppContext): void;
|
|
7
7
|
}
|
package/lib/apps/boards.d.ts
CHANGED
|
@@ -1,11 +1,13 @@
|
|
|
1
1
|
import { DocumentElement } from '@contrail/documents';
|
|
2
|
+
import { FrameDocumentTemplate } from '@contrail/document-generation';
|
|
2
3
|
export declare enum BoardCommand {
|
|
3
4
|
ADD_ELEMENTS = "board:add_elements",
|
|
4
5
|
DELETE_ELEMENTS = "board:delete_elements",
|
|
5
6
|
MODIFY_ELEMENTS = "board:modify_elements",
|
|
6
7
|
GET_ELEMENTS = "board:get_elements",
|
|
7
8
|
RECOLOR_IMAGES = "board:recolor_images",
|
|
8
|
-
ADD_CONTENT_TO_ENTITY_FROM_ELEMENTS = "board:add_content_to_entity_from_elements"
|
|
9
|
+
ADD_CONTENT_TO_ENTITY_FROM_ELEMENTS = "board:add_content_to_entity_from_elements",
|
|
10
|
+
ADD_FRAMES_FROM_TEMPLATE = "board:add_frames_from_template"
|
|
9
11
|
}
|
|
10
12
|
export interface BoardDocumentElement extends DocumentElement {
|
|
11
13
|
[key: string]: any;
|
|
@@ -19,9 +21,29 @@ export interface AppClientResults {
|
|
|
19
21
|
data?: any;
|
|
20
22
|
error?: string;
|
|
21
23
|
}
|
|
24
|
+
export declare type FrameFromTemplateParams = {
|
|
25
|
+
frameTemplate: FrameDocumentTemplate;
|
|
26
|
+
frameOptions?: {
|
|
27
|
+
position: {
|
|
28
|
+
x: number;
|
|
29
|
+
y: number;
|
|
30
|
+
};
|
|
31
|
+
};
|
|
32
|
+
frameTemplateId?: never;
|
|
33
|
+
} | {
|
|
34
|
+
frameTemplateId: string;
|
|
35
|
+
frameOptions?: {
|
|
36
|
+
position: {
|
|
37
|
+
x: number;
|
|
38
|
+
y: number;
|
|
39
|
+
};
|
|
40
|
+
};
|
|
41
|
+
frameTemplate?: never;
|
|
42
|
+
};
|
|
22
43
|
export declare class BoardsApp {
|
|
23
44
|
static getCurrentBoard(): any;
|
|
24
45
|
static addElements(elements: Array<BoardDocumentElement>): void;
|
|
46
|
+
static addFramesFromTemplate(frames: Array<FrameFromTemplateParams>): Promise<Array<DocumentElement>>;
|
|
25
47
|
static deleteElements(elements: Array<BoardDocumentElement>): void;
|
|
26
48
|
static modifyElements(changeObjects: Array<BoardDocumentElementChanges>): void;
|
|
27
49
|
static getElements(criteria: object): Promise<Array<DocumentElement>>;
|
package/lib/apps/boards.js
CHANGED
|
@@ -20,6 +20,7 @@ var BoardCommand;
|
|
|
20
20
|
BoardCommand["GET_ELEMENTS"] = "board:get_elements";
|
|
21
21
|
BoardCommand["RECOLOR_IMAGES"] = "board:recolor_images";
|
|
22
22
|
BoardCommand["ADD_CONTENT_TO_ENTITY_FROM_ELEMENTS"] = "board:add_content_to_entity_from_elements";
|
|
23
|
+
BoardCommand["ADD_FRAMES_FROM_TEMPLATE"] = "board:add_frames_from_template";
|
|
23
24
|
})(BoardCommand = exports.BoardCommand || (exports.BoardCommand = {}));
|
|
24
25
|
class BoardsApp {
|
|
25
26
|
static getCurrentBoard() {
|
|
@@ -29,9 +30,25 @@ class BoardsApp {
|
|
|
29
30
|
static addElements(elements) {
|
|
30
31
|
BoardsApp.validateBoardContext();
|
|
31
32
|
if (elements === null || elements === void 0 ? void 0 : elements.length) {
|
|
32
|
-
(0, actions_1.getExtensionActions)().sendMessageToHost({
|
|
33
|
+
(0, actions_1.getExtensionActions)().sendMessageToHost({
|
|
34
|
+
command: BoardCommand.ADD_ELEMENTS,
|
|
35
|
+
data: elements,
|
|
36
|
+
});
|
|
33
37
|
}
|
|
34
38
|
}
|
|
39
|
+
static addFramesFromTemplate(frames) {
|
|
40
|
+
return __awaiter(this, void 0, void 0, function* () {
|
|
41
|
+
BoardsApp.validateBoardContext();
|
|
42
|
+
if (frames === null || frames === void 0 ? void 0 : frames.length) {
|
|
43
|
+
const results = yield (0, actions_1.getExtensionActions)().sendMessageToHost({
|
|
44
|
+
command: BoardCommand.ADD_FRAMES_FROM_TEMPLATE,
|
|
45
|
+
data: frames,
|
|
46
|
+
});
|
|
47
|
+
return this.validateAndReturnResults(results);
|
|
48
|
+
}
|
|
49
|
+
return [];
|
|
50
|
+
});
|
|
51
|
+
}
|
|
35
52
|
static deleteElements(elements) {
|
|
36
53
|
BoardsApp.validateBoardContext();
|
|
37
54
|
const elementsWithIds = elements.filter((element) => !!element.id);
|
|
@@ -42,13 +59,19 @@ class BoardsApp {
|
|
|
42
59
|
static modifyElements(changeObjects) {
|
|
43
60
|
BoardsApp.validateBoardContext();
|
|
44
61
|
if (changeObjects === null || changeObjects === void 0 ? void 0 : changeObjects.length) {
|
|
45
|
-
(0, actions_1.getExtensionActions)().sendMessageToHost({
|
|
62
|
+
(0, actions_1.getExtensionActions)().sendMessageToHost({
|
|
63
|
+
command: BoardCommand.MODIFY_ELEMENTS,
|
|
64
|
+
data: changeObjects,
|
|
65
|
+
});
|
|
46
66
|
}
|
|
47
67
|
}
|
|
48
68
|
static getElements(criteria) {
|
|
49
69
|
return __awaiter(this, void 0, void 0, function* () {
|
|
50
70
|
BoardsApp.validateBoardContext();
|
|
51
|
-
const results = yield (0, actions_1.getExtensionActions)().sendMessageToHost({
|
|
71
|
+
const results = yield (0, actions_1.getExtensionActions)().sendMessageToHost({
|
|
72
|
+
command: BoardCommand.GET_ELEMENTS,
|
|
73
|
+
data: criteria,
|
|
74
|
+
});
|
|
52
75
|
return this.validateAndReturnResults(results);
|
|
53
76
|
});
|
|
54
77
|
}
|
|
@@ -58,23 +81,29 @@ class BoardsApp {
|
|
|
58
81
|
const data = {
|
|
59
82
|
assignmentOptions,
|
|
60
83
|
entity,
|
|
61
|
-
elements
|
|
84
|
+
elements,
|
|
62
85
|
};
|
|
63
|
-
const results = yield (0, actions_1.getExtensionActions)().sendMessageToHost({
|
|
86
|
+
const results = yield (0, actions_1.getExtensionActions)().sendMessageToHost({
|
|
87
|
+
command: BoardCommand.ADD_CONTENT_TO_ENTITY_FROM_ELEMENTS,
|
|
88
|
+
data,
|
|
89
|
+
});
|
|
64
90
|
return this.validateAndReturnResults(results);
|
|
65
91
|
});
|
|
66
92
|
}
|
|
67
93
|
static recolorImages(imageElements, hexCode, hexMap = {}) {
|
|
68
94
|
return __awaiter(this, void 0, void 0, function* () {
|
|
69
95
|
BoardsApp.validateBoardContext();
|
|
70
|
-
const results = yield (0, actions_1.getExtensionActions)().sendMessageToHost({
|
|
96
|
+
const results = yield (0, actions_1.getExtensionActions)().sendMessageToHost({
|
|
97
|
+
command: BoardCommand.RECOLOR_IMAGES,
|
|
98
|
+
data: { imageElements, hexCode, hexMap },
|
|
99
|
+
});
|
|
71
100
|
return this.validateAndReturnResults(results);
|
|
72
101
|
});
|
|
73
102
|
}
|
|
74
103
|
static validateBoardContext() {
|
|
75
104
|
const context = (0, app_context_1.getAppContext)();
|
|
76
105
|
if (context.appContext.vibeIQApp !== app_context_1.VibeIQAppType.BOARDS || !context.appContext.board) {
|
|
77
|
-
throw new Error(
|
|
106
|
+
throw new Error('App extension has not been initialized with Board context.');
|
|
78
107
|
}
|
|
79
108
|
}
|
|
80
109
|
static validateAndReturnResults(results) {
|
package/lib/apps/plan.d.ts
CHANGED
package/lib/apps/plan.js
CHANGED
|
@@ -52,7 +52,7 @@ class PlanApp {
|
|
|
52
52
|
static validatePlanContext() {
|
|
53
53
|
const context = (0, app_context_1.getAppContext)();
|
|
54
54
|
if (context.appContext.vibeIQApp !== app_context_1.VibeIQAppType.PLAN || !context.appContext.plan) {
|
|
55
|
-
throw new Error(
|
|
55
|
+
throw new Error('App extension has not been initialized with Plan context.');
|
|
56
56
|
}
|
|
57
57
|
}
|
|
58
58
|
}
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { EntitiesClientBatchCreateOptions, EntitiesClientBatchDeleteOptions, EntitiesClientBatchUpdateOptions, EntitiesClientCreateOptions, EntitiesClientDeleteOptions, EntitiesClientGetOptions, API_VERSION } from
|
|
1
|
+
import { EntitiesClientBatchCreateOptions, EntitiesClientBatchDeleteOptions, EntitiesClientBatchUpdateOptions, EntitiesClientCreateOptions, EntitiesClientDeleteOptions, EntitiesClientGetOptions, API_VERSION } from '@contrail/sdk';
|
|
2
2
|
declare class EntitiesClientUpdateOptions {
|
|
3
3
|
entityName?: string;
|
|
4
4
|
object: any;
|
|
@@ -17,43 +17,64 @@ class EntitiesClientUpdateOptions {
|
|
|
17
17
|
class EntitiesClient {
|
|
18
18
|
get(options) {
|
|
19
19
|
return __awaiter(this, void 0, void 0, function* () {
|
|
20
|
-
const results = yield (0, actions_1.getExtensionActions)().sendMessageToEntitiesClient({
|
|
20
|
+
const results = yield (0, actions_1.getExtensionActions)().sendMessageToEntitiesClient({
|
|
21
|
+
method: entities_action_handler_1.EntitiesClientMethods.GET,
|
|
22
|
+
options,
|
|
23
|
+
});
|
|
21
24
|
return this.validateAndReturnEntityClientResults(results);
|
|
22
25
|
});
|
|
23
26
|
}
|
|
24
27
|
create(options) {
|
|
25
28
|
return __awaiter(this, void 0, void 0, function* () {
|
|
26
|
-
const results = yield (0, actions_1.getExtensionActions)().sendMessageToEntitiesClient({
|
|
29
|
+
const results = yield (0, actions_1.getExtensionActions)().sendMessageToEntitiesClient({
|
|
30
|
+
method: entities_action_handler_1.EntitiesClientMethods.CREATE,
|
|
31
|
+
options,
|
|
32
|
+
});
|
|
27
33
|
return this.validateAndReturnEntityClientResults(results);
|
|
28
34
|
});
|
|
29
35
|
}
|
|
30
36
|
batchCreate(options) {
|
|
31
37
|
return __awaiter(this, void 0, void 0, function* () {
|
|
32
|
-
const results = yield (0, actions_1.getExtensionActions)().sendMessageToEntitiesClient({
|
|
38
|
+
const results = yield (0, actions_1.getExtensionActions)().sendMessageToEntitiesClient({
|
|
39
|
+
method: entities_action_handler_1.EntitiesClientMethods.BATCH_CREATE,
|
|
40
|
+
options,
|
|
41
|
+
});
|
|
33
42
|
return this.validateAndReturnEntityClientResults(results);
|
|
34
43
|
});
|
|
35
44
|
}
|
|
36
45
|
update(options) {
|
|
37
46
|
return __awaiter(this, void 0, void 0, function* () {
|
|
38
|
-
const results = yield (0, actions_1.getExtensionActions)().sendMessageToEntitiesClient({
|
|
47
|
+
const results = yield (0, actions_1.getExtensionActions)().sendMessageToEntitiesClient({
|
|
48
|
+
method: entities_action_handler_1.EntitiesClientMethods.UPDATE,
|
|
49
|
+
options,
|
|
50
|
+
});
|
|
39
51
|
return this.validateAndReturnEntityClientResults(results);
|
|
40
52
|
});
|
|
41
53
|
}
|
|
42
54
|
batchUpdate(options) {
|
|
43
55
|
return __awaiter(this, void 0, void 0, function* () {
|
|
44
|
-
const results = yield (0, actions_1.getExtensionActions)().sendMessageToEntitiesClient({
|
|
56
|
+
const results = yield (0, actions_1.getExtensionActions)().sendMessageToEntitiesClient({
|
|
57
|
+
method: entities_action_handler_1.EntitiesClientMethods.BATCH_UPDATE,
|
|
58
|
+
options,
|
|
59
|
+
});
|
|
45
60
|
return this.validateAndReturnEntityClientResults(results);
|
|
46
61
|
});
|
|
47
62
|
}
|
|
48
63
|
delete(options) {
|
|
49
64
|
return __awaiter(this, void 0, void 0, function* () {
|
|
50
|
-
const results = yield (0, actions_1.getExtensionActions)().sendMessageToEntitiesClient({
|
|
65
|
+
const results = yield (0, actions_1.getExtensionActions)().sendMessageToEntitiesClient({
|
|
66
|
+
method: entities_action_handler_1.EntitiesClientMethods.DELETE,
|
|
67
|
+
options,
|
|
68
|
+
});
|
|
51
69
|
return this.validateAndReturnEntityClientResults(results);
|
|
52
70
|
});
|
|
53
71
|
}
|
|
54
72
|
batchDelete(options) {
|
|
55
73
|
return __awaiter(this, void 0, void 0, function* () {
|
|
56
|
-
const results = yield (0, actions_1.getExtensionActions)().sendMessageToEntitiesClient({
|
|
74
|
+
const results = yield (0, actions_1.getExtensionActions)().sendMessageToEntitiesClient({
|
|
75
|
+
method: entities_action_handler_1.EntitiesClientMethods.BATCH_DELETE,
|
|
76
|
+
options,
|
|
77
|
+
});
|
|
57
78
|
return this.validateAndReturnEntityClientResults(results);
|
|
58
79
|
});
|
|
59
80
|
}
|
|
@@ -27,7 +27,7 @@ class AppExtensionHost {
|
|
|
27
27
|
appExtension.init(context);
|
|
28
28
|
}
|
|
29
29
|
catch (error) {
|
|
30
|
-
console.error(
|
|
30
|
+
console.error('Failed to connect host app with app extension:', error);
|
|
31
31
|
throw error;
|
|
32
32
|
}
|
|
33
33
|
});
|
|
@@ -45,7 +45,7 @@ class AppExtensionHost {
|
|
|
45
45
|
},
|
|
46
46
|
sendMessageToHost(message) {
|
|
47
47
|
return customMessageHandler.handleMessage(message);
|
|
48
|
-
}
|
|
48
|
+
},
|
|
49
49
|
};
|
|
50
50
|
}
|
|
51
51
|
}
|
|
@@ -28,7 +28,7 @@ class AppExtension {
|
|
|
28
28
|
});
|
|
29
29
|
}
|
|
30
30
|
catch (error) {
|
|
31
|
-
console.error(
|
|
31
|
+
console.error('Failed to connect app extension with host application:', error);
|
|
32
32
|
throw error;
|
|
33
33
|
}
|
|
34
34
|
});
|
|
@@ -37,19 +37,18 @@ class AppExtension {
|
|
|
37
37
|
return {
|
|
38
38
|
init(context) {
|
|
39
39
|
return AppExtension.initAppExtension(context);
|
|
40
|
-
}
|
|
40
|
+
},
|
|
41
41
|
};
|
|
42
42
|
}
|
|
43
43
|
static initAppExtension(context) {
|
|
44
44
|
return __awaiter(this, void 0, void 0, function* () {
|
|
45
|
-
console.log(
|
|
45
|
+
console.log('[AppExtension]: Initialized: Received context: ', context);
|
|
46
46
|
(0, app_context_1.setAppContext)(context);
|
|
47
47
|
if (AppExtension.initPromiseResolver) {
|
|
48
48
|
AppExtension.initPromiseResolver();
|
|
49
49
|
}
|
|
50
50
|
});
|
|
51
51
|
}
|
|
52
|
-
;
|
|
53
52
|
static close() {
|
|
54
53
|
(0, actions_1.getExtensionActions)().close();
|
|
55
54
|
}
|
|
@@ -15,20 +15,29 @@ const types_action_handler_1 = require("./types-action-handler");
|
|
|
15
15
|
class TypesClient {
|
|
16
16
|
getType(options) {
|
|
17
17
|
return __awaiter(this, void 0, void 0, function* () {
|
|
18
|
-
const results = yield (0, actions_1.getExtensionActions)().sendMessageToTypesClient({
|
|
18
|
+
const results = yield (0, actions_1.getExtensionActions)().sendMessageToTypesClient({
|
|
19
|
+
method: types_action_handler_1.TypesClientMethods.GET_TYPE,
|
|
20
|
+
options,
|
|
21
|
+
});
|
|
19
22
|
return this.validateAndReturnTypeClientResults(results);
|
|
20
23
|
});
|
|
21
24
|
}
|
|
22
25
|
getByRootAndPath(options) {
|
|
23
26
|
return __awaiter(this, void 0, void 0, function* () {
|
|
24
|
-
const results = yield (0, actions_1.getExtensionActions)().sendMessageToTypesClient({
|
|
27
|
+
const results = yield (0, actions_1.getExtensionActions)().sendMessageToTypesClient({
|
|
28
|
+
method: types_action_handler_1.TypesClientMethods.GET_BY_ROOT_AND_PATH,
|
|
29
|
+
options,
|
|
30
|
+
});
|
|
25
31
|
return this.validateAndReturnTypeClientResults(results);
|
|
26
32
|
});
|
|
27
33
|
}
|
|
28
34
|
getProperty(typeId, propertySlug) {
|
|
29
35
|
return __awaiter(this, void 0, void 0, function* () {
|
|
30
36
|
const getPropertyOptions = { typeId, propertySlug };
|
|
31
|
-
const results = yield (0, actions_1.getExtensionActions)().sendMessageToTypesClient({
|
|
37
|
+
const results = yield (0, actions_1.getExtensionActions)().sendMessageToTypesClient({
|
|
38
|
+
method: types_action_handler_1.TypesClientMethods.GET_PROPERTY,
|
|
39
|
+
options: getPropertyOptions,
|
|
40
|
+
});
|
|
32
41
|
return this.validateAndReturnTypeClientResults(results);
|
|
33
42
|
});
|
|
34
43
|
}
|
package/package.json
CHANGED
|
@@ -1,13 +1,14 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@contrail/extensions-sdk",
|
|
3
|
-
"version": "1.0.
|
|
3
|
+
"version": "1.0.16",
|
|
4
4
|
"description": "Client library for interfacing with VibeIQ's services and apps from an extension.",
|
|
5
5
|
"main": "lib/index.js",
|
|
6
6
|
"types": "lib/index.d.ts",
|
|
7
7
|
"scripts": {
|
|
8
8
|
"build": "tsc",
|
|
9
|
-
"
|
|
10
|
-
"lint": "
|
|
9
|
+
"prepare": "husky install",
|
|
10
|
+
"lint-staged:check": "lint-staged --config .lintstagedrc-check.json",
|
|
11
|
+
"lint-staged:format": "lint-staged --allow-empty --config .lintstagedrc-format.json",
|
|
11
12
|
"generate-docs": "npx typedoc src/index.ts --disableSources --excludeInternal --plugin typedoc-plugin-extras --favicon home-hero.svg",
|
|
12
13
|
"test": "jest"
|
|
13
14
|
},
|
|
@@ -16,21 +17,25 @@
|
|
|
16
17
|
"license": "ISC",
|
|
17
18
|
"dependencies": {
|
|
18
19
|
"@contrail/documents": "^1.1.3",
|
|
20
|
+
"@contrail/document-generation": "^2.1.26",
|
|
19
21
|
"@contrail/entity-types": "^1.1.35",
|
|
20
22
|
"penpal": "^6.2.2"
|
|
21
23
|
},
|
|
22
24
|
"devDependencies": {
|
|
23
25
|
"@types/jest": "^29.5.2",
|
|
24
26
|
"@types/node": "^14.10.1",
|
|
27
|
+
"husky": "^9.0.11",
|
|
25
28
|
"jest": "^29.5.0",
|
|
26
|
-
"
|
|
29
|
+
"lint-staged": "^15.2.5",
|
|
30
|
+
"prettier": "^3.2.5",
|
|
27
31
|
"ts-jest": "^29.1.1",
|
|
28
|
-
"tslint": "^5.11.0",
|
|
29
|
-
"tslint-config-prettier": "^1.18.0",
|
|
30
32
|
"typedoc": "^0.25.7",
|
|
31
33
|
"typedoc-plugin-extras": "^3.0.0",
|
|
32
34
|
"typescript": "^4.0.0"
|
|
33
35
|
},
|
|
36
|
+
"lint-staged": {
|
|
37
|
+
"*.{js,css,md}": "prettier --write"
|
|
38
|
+
},
|
|
34
39
|
"peerDependencies": {
|
|
35
40
|
"@contrail/sdk": "^1.3.7"
|
|
36
41
|
},
|