@forge/bridge 5.16.3-next.0 → 5.17.0-experimental-04cc2b9
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/CHANGELOG.md +111 -0
- package/out/bridge.d.ts +1 -1
- package/out/events/events.d.ts.map +1 -1
- package/out/events/serialiseBlob.d.ts.map +1 -1
- package/out/featureFlags/types.d.ts +5 -5
- package/out/featureFlags/types.d.ts.map +1 -1
- package/out/featureFlags/types.js +1 -1
- package/out/fetch/fetch.d.ts.map +1 -1
- package/out/fetch/index.d.ts.map +1 -1
- package/out/flag/flag.d.ts +2 -2
- package/out/flag/flag.d.ts.map +1 -1
- package/out/frontendCustomMetrics/frontendCustomMetrics.d.ts +17 -0
- package/out/frontendCustomMetrics/frontendCustomMetrics.d.ts.map +1 -0
- package/out/frontendCustomMetrics/frontendCustomMetrics.js +61 -0
- package/out/frontendCustomMetrics/index.d.ts +2 -0
- package/out/frontendCustomMetrics/index.d.ts.map +1 -0
- package/out/frontendCustomMetrics/index.js +4 -0
- package/out/i18n/index.d.ts +1 -1
- package/out/i18n/index.d.ts.map +1 -1
- package/out/index.d.ts +1 -0
- package/out/index.d.ts.map +1 -1
- package/out/index.js +1 -0
- package/out/invoke/invoke.d.ts +1 -1
- package/out/invoke/invoke.d.ts.map +1 -1
- package/out/invoke/invoke.js +2 -3
- package/out/invoke-endpoint/invoke-endpoint.d.ts +2 -2
- package/out/invoke-endpoint/invoke-endpoint.d.ts.map +1 -1
- package/out/invoke-endpoint/invoke-endpoint.js +1 -1
- package/out/invoke-endpoint/invoke-remote.d.ts +1 -1
- package/out/invoke-endpoint/invoke-remote.d.ts.map +1 -1
- package/out/invoke-endpoint/invoke-service.d.ts +1 -1
- package/out/invoke-endpoint/invoke-service.d.ts.map +1 -1
- package/out/modal/modal.d.ts +10 -2
- package/out/modal/modal.d.ts.map +1 -1
- package/out/modal/modal.js +16 -0
- package/out/object-store/deleteObjects.d.ts.map +1 -1
- package/out/object-store/download.d.ts.map +1 -1
- package/out/object-store/getMetadata.d.ts.map +1 -1
- package/out/object-store/types.d.ts +10 -10
- package/out/object-store/types.d.ts.map +1 -1
- package/out/object-store/upload.d.ts.map +1 -1
- package/out/object-store/utils.d.ts.map +1 -1
- package/out/permissions/permissions.d.ts.map +1 -1
- package/out/permissions/permissionsUtil.d.ts +3 -3
- package/out/permissions/permissionsUtil.d.ts.map +1 -1
- package/out/permissions/permissionsUtil.js +2 -3
- package/out/permissions/types.d.ts +11 -11
- package/out/permissions/types.d.ts.map +1 -1
- package/out/realtime/productContext.d.ts +1 -1
- package/out/realtime/productContext.d.ts.map +1 -1
- package/out/realtime/productContext.js +3 -3
- package/out/realtime/realtime.d.ts +3 -3
- package/out/realtime/realtime.d.ts.map +1 -1
- package/out/router/router.d.ts.map +1 -1
- package/out/router/types.d.ts +10 -10
- package/out/router/types.d.ts.map +1 -1
- package/out/rovo/open.d.ts.map +1 -1
- package/out/rovo/types.d.ts +4 -4
- package/out/rovo/types.d.ts.map +1 -1
- package/out/types.d.ts +10 -10
- package/out/types.d.ts.map +1 -1
- package/out/types.js +1 -1
- package/out/utils/blobParser.d.ts.map +1 -1
- package/out/utils/index.d.ts.map +1 -1
- package/out/view/adf-renderer.d.ts +12 -0
- package/out/view/adf-renderer.d.ts.map +1 -1
- package/out/view/adf-renderer.js +58 -4
- package/out/view/changeWindowTitle.d.ts.map +1 -1
- package/out/view/close.d.ts.map +1 -1
- package/out/view/createHistory.d.ts.map +1 -1
- package/out/view/emitReadyEvent.d.ts.map +1 -1
- package/out/view/getContext.d.ts.map +1 -1
- package/out/view/getFrameDispatch.d.ts +4 -0
- package/out/view/getFrameDispatch.d.ts.map +1 -0
- package/out/view/getFrameDispatch.js +9 -0
- package/out/view/onClose.d.ts.map +1 -1
- package/out/view/refresh.d.ts.map +1 -1
- package/out/view/submit.d.ts.map +1 -1
- package/out/view/theme.d.ts.map +1 -1
- package/out/view/view.d.ts +3 -2
- package/out/view/view.d.ts.map +1 -1
- package/out/view/view.js +2 -0
- package/package.json +15 -6
|
@@ -4,12 +4,12 @@ import type { RuntimePermissions } from '../types';
|
|
|
4
4
|
* Resource types that can be loaded externally
|
|
5
5
|
*/
|
|
6
6
|
declare const RESOURCE_TYPES: readonly ["fonts", "styles", "frames", "images", "media", "scripts"];
|
|
7
|
-
export
|
|
7
|
+
export type ResourceType = (typeof RESOURCE_TYPES)[number];
|
|
8
8
|
/**
|
|
9
9
|
* Fetch types for external requests
|
|
10
10
|
*/
|
|
11
11
|
declare const FETCH_TYPES: readonly ["backend", "client"];
|
|
12
|
-
export
|
|
12
|
+
export type FetchType = (typeof FETCH_TYPES)[number];
|
|
13
13
|
/**
|
|
14
14
|
* Required permissions for checking
|
|
15
15
|
*/
|
|
@@ -32,7 +32,7 @@ export interface PermissionRequirements {
|
|
|
32
32
|
/**
|
|
33
33
|
* Missing permissions information
|
|
34
34
|
*/
|
|
35
|
-
export
|
|
35
|
+
export type MissingPermissions = PermissionRequirements;
|
|
36
36
|
/**
|
|
37
37
|
* Permission check result
|
|
38
38
|
*/
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"permissionsUtil.d.ts","sourceRoot":"","sources":["../../src/permissions/permissionsUtil.ts"],"names":[],"mappings":"AACA,OAAO,KAAK,EAAE,QAAQ,EAAS,MAAM,iBAAiB,CAAC;AAEvD,OAAO,KAAK,EAAE,kBAAkB,EAAE,MAAM,UAAU,CAAC;AAiBnD;;GAEG;AACH,QAAA,MAAM,cAAc,sEAAuE,CAAC;AAC5F,
|
|
1
|
+
{"version":3,"file":"permissionsUtil.d.ts","sourceRoot":"","sources":["../../src/permissions/permissionsUtil.ts"],"names":[],"mappings":"AACA,OAAO,KAAK,EAAE,QAAQ,EAAS,MAAM,iBAAiB,CAAC;AAEvD,OAAO,KAAK,EAAE,kBAAkB,EAAE,MAAM,UAAU,CAAC;AAiBnD;;GAEG;AACH,QAAA,MAAM,cAAc,sEAAuE,CAAC;AAC5F,MAAM,M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AAC;IAE9D;;OAEG;IACH,SAAS,EAAE,MAAM,MAAM,EAAE,CAAC;IAE1B;;OAEG;IACH,sBAAsB,EAAE,MAAM,QAAQ,GAAG,SAAS,CAAC;IAEnD;;OAEG;IACH,iBAAiB,EAAE,MAAM,OAAO,CAAC;CAClC;AAED;;;;GAIG;AACH,wBAAgB,qBAAqB,CAAC,kBAAkB,EAAE,kBAAkB,GAAG,SAAS,GAAG,eAAe,GAAG,IAAI,CAmDhH;AAyID;;;;;GAKG;AACH,wBAAsB,gBAAgB,CACpC,mBAAmB,EAAE,sBAAsB,EAC3C,kBAAkB,CAAC,EAAE,kBAAkB,GAAG,SAAS,GAClD,OAAO,CAAC,qBAAqB,CAAC,CAiDhC"}
|
|
@@ -1,6 +1,7 @@
|
|
|
1
1
|
"use strict";
|
|
2
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
-
exports.
|
|
3
|
+
exports.createPermissionUtils = createPermissionUtils;
|
|
4
|
+
exports.checkPermissions = checkPermissions;
|
|
4
5
|
const egress_1 = require("@forge/egress");
|
|
5
6
|
const view_1 = require("../view");
|
|
6
7
|
/**
|
|
@@ -71,7 +72,6 @@ function createPermissionUtils(runtimePermissions) {
|
|
|
71
72
|
hasAnyPermissions: () => scopeArray.length > 0 || Object.keys(external).length > 0
|
|
72
73
|
};
|
|
73
74
|
}
|
|
74
|
-
exports.createPermissionUtils = createPermissionUtils;
|
|
75
75
|
/**
|
|
76
76
|
* Check if required scopes are granted
|
|
77
77
|
*/
|
|
@@ -221,4 +221,3 @@ async function checkPermissions(requiredPermissions, runtimePermissions) {
|
|
|
221
221
|
missing: hasAllRequiredPermissions ? null : missing
|
|
222
222
|
};
|
|
223
223
|
}
|
|
224
|
-
exports.checkPermissions = checkPermissions;
|
|
@@ -1,10 +1,10 @@
|
|
|
1
1
|
import { EgressType } from '@forge/egress';
|
|
2
|
-
export
|
|
2
|
+
export type EgressGetPayload = {
|
|
3
3
|
keys?: string[];
|
|
4
4
|
pageSize?: number;
|
|
5
5
|
nextPageToken?: string;
|
|
6
6
|
};
|
|
7
|
-
export
|
|
7
|
+
export type EgressSetPayload = {
|
|
8
8
|
egresses: {
|
|
9
9
|
key: string;
|
|
10
10
|
description: string;
|
|
@@ -14,33 +14,33 @@ export declare type EgressSetPayload = {
|
|
|
14
14
|
}[];
|
|
15
15
|
}[];
|
|
16
16
|
};
|
|
17
|
-
export
|
|
17
|
+
export type EgressDeleteGroupPayload = {
|
|
18
18
|
key: string;
|
|
19
19
|
};
|
|
20
|
-
export
|
|
20
|
+
export type EgressDeleteDomainPayload = {
|
|
21
21
|
key: string;
|
|
22
22
|
domain: string;
|
|
23
23
|
type: EgressType;
|
|
24
24
|
};
|
|
25
|
-
export
|
|
25
|
+
export type RemoteGetPayload = {
|
|
26
26
|
keys?: string[];
|
|
27
27
|
pageSize?: number;
|
|
28
28
|
nextPageToken?: string;
|
|
29
29
|
};
|
|
30
|
-
export
|
|
30
|
+
export type Remote = {
|
|
31
31
|
key: string;
|
|
32
32
|
configured: {
|
|
33
33
|
endpoint: string | null;
|
|
34
34
|
};
|
|
35
35
|
};
|
|
36
|
-
export
|
|
36
|
+
export type RemoteSetPayload = {
|
|
37
37
|
remotes: Remote[];
|
|
38
38
|
};
|
|
39
|
-
export
|
|
39
|
+
export type RemoteGetResponse = {
|
|
40
40
|
results: Remote[];
|
|
41
41
|
lastEvaluatedKey?: string;
|
|
42
42
|
};
|
|
43
|
-
export
|
|
43
|
+
export type EgressResult = {
|
|
44
44
|
configured: {
|
|
45
45
|
domain: string;
|
|
46
46
|
type: [EgressType];
|
|
@@ -48,11 +48,11 @@ export declare type EgressResult = {
|
|
|
48
48
|
description: string;
|
|
49
49
|
key: string;
|
|
50
50
|
};
|
|
51
|
-
export
|
|
51
|
+
export type EgressGetResponse = {
|
|
52
52
|
lastEvaluatedKey?: string;
|
|
53
53
|
results: EgressResult[];
|
|
54
54
|
};
|
|
55
|
-
export
|
|
55
|
+
export type EgressSetResponse = {
|
|
56
56
|
results: EgressResult[];
|
|
57
57
|
};
|
|
58
58
|
//# sourceMappingURL=types.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"types.d.ts","sourceRoot":"","sources":["../../src/permissions/types.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,UAAU,EAAE,MAAM,eAAe,CAAC;AAE3C,
|
|
1
|
+
{"version":3,"file":"types.d.ts","sourceRoot":"","sources":["../../src/permissions/types.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,UAAU,EAAE,MAAM,eAAe,CAAC;AAE3C,MAAM,MAAM,gBAAgB,GAAG;IAC7B,IAAI,CAAC,EAAE,MAAM,EAAE,CAAC;IAChB,QAAQ,CAAC,EAAE,MAAM,CAAC;IAClB,aAAa,CAAC,EAAE,MAAM,CAAC;CACxB,CAAC;AAEF,MAAM,MAAM,gBAAgB,GAAG;IAC7B,QAAQ,EAAE;QACR,GAAG,EAAE,MAAM,CAAC;QACZ,WAAW,EAAE,MAAM,CAAC;QACpB,UAAU,EAAE;YACV,MAAM,EAAE,MAAM,CAAC;YACf,IAAI,EAAE,UAAU,EAAE,CAAC;SACpB,EAAE,CAAC;KACL,EAAE,CAAC;CACL,CAAC;AAEF,MAAM,MAAM,wBAAwB,GAAG;IACrC,GAAG,EAAE,MAAM,CAAC;CACb,CAAC;AAEF,MAAM,MAAM,yBAAyB,GAAG;IACtC,GAAG,EAAE,MAAM,CAAC;IACZ,MAAM,EAAE,MAAM,CAAC;IACf,IAAI,EAAE,UAAU,CAAC;CAClB,CAAC;AAEF,MAAM,MAAM,gBAAgB,GAAG;IAC7B,IAAI,CAAC,EAAE,MAAM,EAAE,CAAC;IAChB,QAAQ,CAAC,EAAE,MAAM,CAAC;IAClB,aAAa,CAAC,EAAE,MAAM,CAAC;CACxB,CAAC;AAEF,MAAM,MAAM,MAAM,GAAG;IACnB,GAAG,EAAE,MAAM,CAAC;IACZ,UAAU,EAAE;QACV,QAAQ,EAAE,MAAM,GAAG,IAAI,CAAC;KACzB,CAAC;CACH,CAAC;AAEF,MAAM,MAAM,gBAAgB,GAAG;IAC7B,OAAO,EAAE,MAAM,EAAE,CAAC;CACnB,CAAC;AAEF,MAAM,MAAM,iBAAiB,GAAG;IAC9B,OAAO,EAAE,MAAM,EAAE,CAAC;IAClB,gBAAgB,CAAC,EAAE,MAAM,CAAC;CAC3B,CAAC;AAEF,MAAM,MAAM,YAAY,GAAG;IACzB,UAAU,EAAE;QACV,MAAM,EAAE,MAAM,CAAC;QACf,IAAI,EAAE,CAAC,UAAU,CAAC,CAAC;KACpB,EAAE,CAAC;IACJ,WAAW,EAAE,MAAM,CAAC;IACpB,GAAG,EAAE,MAAM,CAAC;CACb,CAAC;AAEF,MAAM,MAAM,iBAAiB,GAAG;IAC9B,gBAAgB,CAAC,EAAE,MAAM,CAAC;IAC1B,OAAO,EAAE,YAAY,EAAE,CAAC;CACzB,CAAC;AAEF,MAAM,MAAM,iBAAiB,GAAG;IAC9B,OAAO,EAAE,YAAY,EAAE,CAAC;CACzB,CAAC"}
|
|
@@ -11,5 +11,5 @@ export declare enum Bitbucket {
|
|
|
11
11
|
Repository = "repository",
|
|
12
12
|
PullRequest = "pullRequest"
|
|
13
13
|
}
|
|
14
|
-
export
|
|
14
|
+
export type ProductContext = Jira | Confluence | Bitbucket;
|
|
15
15
|
//# sourceMappingURL=productContext.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"productContext.d.ts","sourceRoot":"","sources":["../../src/realtime/productContext.ts"],"names":[],"mappings":"AAGA,oBAAY,IAAI;IACd,KAAK,UAAU;IACf,KAAK,UAAU;IACf,OAAO,YAAY;CACpB;AAED,oBAAY,UAAU;IACpB,OAAO,YAAY;IACnB,KAAK,UAAU;CAChB;AAED,oBAAY,SAAS;IACnB,UAAU,eAAe;IACzB,WAAW,gBAAgB;CAC5B;AAED,
|
|
1
|
+
{"version":3,"file":"productContext.d.ts","sourceRoot":"","sources":["../../src/realtime/productContext.ts"],"names":[],"mappings":"AAGA,oBAAY,IAAI;IACd,KAAK,UAAU;IACf,KAAK,UAAU;IACf,OAAO,YAAY;CACpB;AAED,oBAAY,UAAU;IACpB,OAAO,YAAY;IACnB,KAAK,UAAU;CAChB;AAED,oBAAY,SAAS;IACnB,UAAU,eAAe;IACzB,WAAW,gBAAgB;CAC5B;AAED,MAAM,MAAM,cAAc,GAAG,IAAI,GAAG,UAAU,GAAG,SAAS,CAAC"}
|
|
@@ -8,14 +8,14 @@ var Jira;
|
|
|
8
8
|
Jira["Board"] = "board";
|
|
9
9
|
Jira["Issue"] = "issue";
|
|
10
10
|
Jira["Project"] = "project";
|
|
11
|
-
})(Jira
|
|
11
|
+
})(Jira || (exports.Jira = Jira = {}));
|
|
12
12
|
var Confluence;
|
|
13
13
|
(function (Confluence) {
|
|
14
14
|
Confluence["Content"] = "content";
|
|
15
15
|
Confluence["Space"] = "space";
|
|
16
|
-
})(Confluence
|
|
16
|
+
})(Confluence || (exports.Confluence = Confluence = {}));
|
|
17
17
|
var Bitbucket;
|
|
18
18
|
(function (Bitbucket) {
|
|
19
19
|
Bitbucket["Repository"] = "repository";
|
|
20
20
|
Bitbucket["PullRequest"] = "pullRequest";
|
|
21
|
-
})(Bitbucket
|
|
21
|
+
})(Bitbucket || (exports.Bitbucket = Bitbucket = {}));
|
|
@@ -18,9 +18,9 @@ interface Subscription {
|
|
|
18
18
|
}
|
|
19
19
|
export declare const realtime: {
|
|
20
20
|
publish: <T extends Record<string, unknown>>(channel: string, payload: string | T, options?: PublishOptions) => Promise<PublishResult>;
|
|
21
|
-
subscribe: <
|
|
22
|
-
publishGlobal: <
|
|
23
|
-
subscribeGlobal: <
|
|
21
|
+
subscribe: <T extends Record<string, unknown> = Record<string, unknown>>(channel: string, callback: (payload: string | T, error?: Error) => any, options?: SubscriptionOptions) => Promise<Subscription>;
|
|
22
|
+
publishGlobal: <T extends Record<string, unknown>>(channel: string, payload: string | T, options?: PublishOptions) => Promise<PublishResult>;
|
|
23
|
+
subscribeGlobal: <T extends Record<string, unknown> = Record<string, unknown>>(channel: string, callback: (payload: string | T, error?: Error) => any, options?: SubscriptionOptions) => Promise<Subscription>;
|
|
24
24
|
};
|
|
25
25
|
export {};
|
|
26
26
|
//# sourceMappingURL=realtime.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"realtime.d.ts","sourceRoot":"","sources":["../../src/realtime/realtime.ts"],"names":[],"mappings":"AACA,OAAO,EAAE,cAAc,EAAE,MAAM,kBAAkB,CAAC;AAElD,MAAM,WAAW,mBAAmB;IAClC,aAAa,CAAC,EAAE,MAAM,CAAC;IACvB,KAAK,CAAC,EAAE,MAAM,CAAC;IACf,gBAAgB,CAAC,EAAE,cAAc,EAAE,CAAC;CACrC;AAED,MAAM,WAAW,cAAc;IAC7B,KAAK,CAAC,EAAE,MAAM,CAAC;IACf,gBAAgB,CAAC,EAAE,cAAc,EAAE,CAAC;CACrC;AAED,MAAM,WAAW,aAAa;IAC5B,OAAO,CAAC,EAAE,MAAM,GAAG,IAAI,CAAC;IACxB,cAAc,CAAC,EAAE,MAAM,GAAG,IAAI,CAAC;IAC/B,MAAM,CAAC,EAAE,MAAM,EAAE,CAAC;CACnB;AAED,UAAU,YAAY;IACpB,WAAW,EAAE,MAAM,OAAO,CAAC,IAAI,CAAC,CAAC;CAClC;AA6CD,eAAO,MAAM,QAAQ;
|
|
1
|
+
{"version":3,"file":"realtime.d.ts","sourceRoot":"","sources":["../../src/realtime/realtime.ts"],"names":[],"mappings":"AACA,OAAO,EAAE,cAAc,EAAE,MAAM,kBAAkB,CAAC;AAElD,MAAM,WAAW,mBAAmB;IAClC,aAAa,CAAC,EAAE,MAAM,CAAC;IACvB,KAAK,CAAC,EAAE,MAAM,CAAC;IACf,gBAAgB,CAAC,EAAE,cAAc,EAAE,CAAC;CACrC;AAED,MAAM,WAAW,cAAc;IAC7B,KAAK,CAAC,EAAE,MAAM,CAAC;IACf,gBAAgB,CAAC,EAAE,cAAc,EAAE,CAAC;CACrC;AAED,MAAM,WAAW,aAAa;IAC5B,OAAO,CAAC,EAAE,MAAM,GAAG,IAAI,CAAC;IACxB,cAAc,CAAC,EAAE,MAAM,GAAG,IAAI,CAAC;IAC/B,MAAM,CAAC,EAAE,MAAM,EAAE,CAAC;CACnB;AAED,UAAU,YAAY;IACpB,WAAW,EAAE,MAAM,OAAO,CAAC,IAAI,CAAC,CAAC;CAClC;AA6CD,eAAO,MAAM,QAAQ;cAzCJ,CAAC,SAAS,MAAM,CAAC,MAAM,EAAE,OAAO,CAAC,WACvC,MAAM,WACN,MAAM,GAAG,CAAC,YACT,cAAc,KACvB,OAAO,CAAC,aAAa,CAAC;gBAIN,CAAC,SAAS,MAAM,CAAC,MAAM,EAAE,OAAO,CAAC,qCACzC,MAAM,YACL,CAAC,OAAO,EAAE,MAAM,GAAG,CAAC,EAAE,KAAK,CAAC,EAAE,KAAK,KAAK,GAAG,YAC3C,mBAAmB,KAC5B,OAAO,CAAC,YAAY,CAAC;oBAQD,CAAC,SAAS,MAAM,CAAC,MAAM,EAAE,OAAO,CAAC,WAC7C,MAAM,WACN,MAAM,GAAG,CAAC,YACT,cAAc,KACvB,OAAO,CAAC,aAAa,CAAC;sBAIA,CAAC,SAAS,MAAM,CAAC,MAAM,EAAE,OAAO,CAAC,qCAC/C,MAAM,YACL,CAAC,OAAO,EAAE,MAAM,GAAG,CAAC,EAAE,KAAK,CAAC,EAAE,KAAK,KAAK,GAAG,YAC3C,mBAAmB,KAC5B,OAAO,CAAC,YAAY,CAAC;CAcvB,CAAC"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"router.d.ts","sourceRoot":"","sources":["../../src/router/router.ts"],"names":[],"mappings":"AACA,OAAO,EAAE,kBAAkB,EAAE,MAAM,SAAS,CAAC;AAoE7C,eAAO,MAAM,MAAM;uBA1Da,kBAAkB,KAAG,
|
|
1
|
+
{"version":3,"file":"router.d.ts","sourceRoot":"","sources":["../../src/router/router.ts"],"names":[],"mappings":"AACA,OAAO,EAAE,kBAAkB,EAAE,MAAM,SAAS,CAAC;AAoE7C,eAAO,MAAM,MAAM;uBA1Da,kBAAkB,KAAG,OAAO,CAAC,GAAG,GAAG,IAAI,CAAC;yBAuB5C,MAAM,GAAG,kBAAkB,KAAG,OAAO,CAAC,IAAI,CAAC;qBAiB/C,MAAM,GAAG,kBAAkB,KAAG,OAAO,CAAC,IAAI,CAAC;kBAgB/C,OAAO,CAAC,IAAI,CAAC;CAOhC,CAAC"}
|
package/out/router/types.d.ts
CHANGED
|
@@ -1,18 +1,18 @@
|
|
|
1
1
|
import { NavigationTarget } from './targets';
|
|
2
|
-
|
|
2
|
+
type ContentView = {
|
|
3
3
|
target: typeof NavigationTarget.ContentView;
|
|
4
4
|
contentId: string;
|
|
5
5
|
version?: string;
|
|
6
6
|
};
|
|
7
|
-
|
|
7
|
+
type ContentEdit = {
|
|
8
8
|
target: typeof NavigationTarget.ContentEdit;
|
|
9
9
|
contentId: string;
|
|
10
10
|
};
|
|
11
|
-
|
|
11
|
+
type SpaceView = {
|
|
12
12
|
target: typeof NavigationTarget.SpaceView;
|
|
13
13
|
spaceKey: string;
|
|
14
14
|
};
|
|
15
|
-
|
|
15
|
+
type ContentList = {
|
|
16
16
|
target: typeof NavigationTarget.ContentList;
|
|
17
17
|
contentType: 'page' | 'blogpost' | 'customContent';
|
|
18
18
|
} & ({
|
|
@@ -22,28 +22,28 @@ declare type ContentList = {
|
|
|
22
22
|
contentType: 'customContent';
|
|
23
23
|
moduleKey: string;
|
|
24
24
|
});
|
|
25
|
-
|
|
25
|
+
type Module = {
|
|
26
26
|
target: typeof NavigationTarget.Module;
|
|
27
27
|
moduleKey: string;
|
|
28
28
|
spaceKey?: string;
|
|
29
29
|
projectKey?: string;
|
|
30
30
|
};
|
|
31
|
-
|
|
31
|
+
type UserProfile = {
|
|
32
32
|
target: typeof NavigationTarget.UserProfile;
|
|
33
33
|
accountId: string;
|
|
34
34
|
};
|
|
35
|
-
|
|
35
|
+
type Dashboard = {
|
|
36
36
|
target: typeof NavigationTarget.Dashboard;
|
|
37
37
|
dashboardId: string;
|
|
38
38
|
};
|
|
39
|
-
|
|
39
|
+
type Issue = {
|
|
40
40
|
target: typeof NavigationTarget.Issue;
|
|
41
41
|
issueKey: string;
|
|
42
42
|
};
|
|
43
|
-
|
|
43
|
+
type ProjectSettingsDetails = {
|
|
44
44
|
target: typeof NavigationTarget.ProjectSettingsDetails;
|
|
45
45
|
projectKey: string;
|
|
46
46
|
};
|
|
47
|
-
export
|
|
47
|
+
export type NavigationLocation = ContentView | ContentEdit | SpaceView | UserProfile | ContentList | Module | Dashboard | Issue | ProjectSettingsDetails;
|
|
48
48
|
export {};
|
|
49
49
|
//# sourceMappingURL=types.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"types.d.ts","sourceRoot":"","sources":["../../src/router/types.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,gBAAgB,EAAE,MAAM,WAAW,CAAC;AAG7C,
|
|
1
|
+
{"version":3,"file":"types.d.ts","sourceRoot":"","sources":["../../src/router/types.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,gBAAgB,EAAE,MAAM,WAAW,CAAC;AAG7C,KAAK,WAAW,GAAG;IACjB,MAAM,EAAE,OAAO,gBAAgB,CAAC,WAAW,CAAC;IAC5C,SAAS,EAAE,MAAM,CAAC;IAClB,OAAO,CAAC,EAAE,MAAM,CAAC;CAClB,CAAC;AAEF,KAAK,WAAW,GAAG;IACjB,MAAM,EAAE,OAAO,gBAAgB,CAAC,WAAW,CAAC;IAC5C,SAAS,EAAE,MAAM,CAAC;CACnB,CAAC;AAEF,KAAK,SAAS,GAAG;IACf,MAAM,EAAE,OAAO,gBAAgB,CAAC,SAAS,CAAC;IAC1C,QAAQ,EAAE,MAAM,CAAC;CAClB,CAAC;AAEF,KAAK,WAAW,GAAG;IACjB,MAAM,EAAE,OAAO,gBAAgB,CAAC,WAAW,CAAC;IAC5C,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AC2M,CAAC;AAmBvP;;;;;;;;GAQG;AACH,eAAO,MAAM,IAAI,
|
|
1
|
+
{"version":3,"file":"open.d.ts","sourceRoot":"","sources":["../../src/rovo/open.ts"],"names":[],"mappings":"AACA,OAAO,EAAE,eAAe,EAAE,MAAM,SAAS,CAAC;AAO1C,eAAO,MAAM,8BAA8B,uPAC2M,CAAC;AAmBvP;;;;;;;;GAQG;AACH,eAAO,MAAM,IAAI,GAAU,iBAAiB,eAAe,kBAiB1D,CAAC"}
|
package/out/rovo/types.d.ts
CHANGED
|
@@ -1,18 +1,18 @@
|
|
|
1
|
-
|
|
1
|
+
type ForgeAgentPayload = {
|
|
2
2
|
type: 'forge';
|
|
3
3
|
agentKey: string;
|
|
4
4
|
agentName: string;
|
|
5
5
|
prompt?: string;
|
|
6
6
|
};
|
|
7
|
-
|
|
7
|
+
type AtlassianAgentPayload = {
|
|
8
8
|
type: 'atlassian';
|
|
9
9
|
agentName: string;
|
|
10
10
|
prompt?: string;
|
|
11
11
|
};
|
|
12
|
-
|
|
12
|
+
type DefaultAgentPayload = {
|
|
13
13
|
type: 'default';
|
|
14
14
|
prompt?: string;
|
|
15
15
|
};
|
|
16
|
-
export
|
|
16
|
+
export type OpenRovoPayload = ForgeAgentPayload | AtlassianAgentPayload | DefaultAgentPayload;
|
|
17
17
|
export {};
|
|
18
18
|
//# sourceMappingURL=types.d.ts.map
|
package/out/rovo/types.d.ts.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"types.d.ts","sourceRoot":"","sources":["../../src/rovo/types.ts"],"names":[],"mappings":"AAAA,
|
|
1
|
+
{"version":3,"file":"types.d.ts","sourceRoot":"","sources":["../../src/rovo/types.ts"],"names":[],"mappings":"AAAA,KAAK,iBAAiB,GAAG;IACvB,IAAI,EAAE,OAAO,CAAC;IACd,QAAQ,EAAE,MAAM,CAAC;IACjB,SAAS,EAAE,MAAM,CAAC;IAClB,MAAM,CAAC,EAAE,MAAM,CAAC;CACjB,CAAC;AAEF,KAAK,qBAAqB,GAAG;IAC3B,IAAI,EAAE,WAAW,CAAC;IAClB,SAAS,EAAE,MAAM,CAAC;IAClB,MAAM,CAAC,EAAE,MAAM,CAAC;CACjB,CAAC;AAEF,KAAK,mBAAmB,GAAG;IACzB,IAAI,EAAE,SAAS,CAAC;IAChB,MAAM,CAAC,EAAE,MAAM,CAAC;CACjB,CAAC;AAEF,MAAM,MAAM,eAAe,GAAG,iBAAiB,GAAG,qBAAqB,GAAG,mBAAmB,CAAC"}
|
package/out/types.d.ts
CHANGED
|
@@ -1,29 +1,29 @@
|
|
|
1
1
|
import { type ForgeSupportedLocaleCode } from '@forge/i18n';
|
|
2
2
|
import { type ThemeState } from '@atlaskit/tokens';
|
|
3
3
|
import { type Scopes, type External } from '@forge/manifest';
|
|
4
|
-
export
|
|
4
|
+
export type InvokePayload = {
|
|
5
5
|
[key in number | string]: any;
|
|
6
6
|
};
|
|
7
|
-
export
|
|
8
|
-
|
|
7
|
+
export type InvokeResponse = Record<string, any> | void;
|
|
8
|
+
type FetchResponse = {
|
|
9
9
|
body?: string;
|
|
10
10
|
headers: {
|
|
11
11
|
[key: string]: string;
|
|
12
12
|
};
|
|
13
13
|
isAttachment?: boolean;
|
|
14
14
|
} & Pick<ResponseInit, 'status' | 'statusText'>;
|
|
15
|
-
export
|
|
16
|
-
export
|
|
15
|
+
export type ProductFetchResponse = FetchResponse;
|
|
16
|
+
export type RemoteFetchResponse = FetchResponse;
|
|
17
17
|
export declare enum ExtensionEnvironment {
|
|
18
18
|
DEVELOPMENT = "DEVELOPMENT",
|
|
19
19
|
STAGING = "STAGING",
|
|
20
20
|
PRODUCTION = "PRODUCTION"
|
|
21
21
|
}
|
|
22
|
-
|
|
22
|
+
type UserAccessDetails = {
|
|
23
23
|
enabled: boolean;
|
|
24
24
|
hasAccess: boolean;
|
|
25
25
|
};
|
|
26
|
-
export
|
|
26
|
+
export type EnvironmentType = keyof typeof ExtensionEnvironment;
|
|
27
27
|
export interface FullContext {
|
|
28
28
|
accountId?: string;
|
|
29
29
|
cloudId?: string;
|
|
@@ -60,7 +60,7 @@ export interface LicenseDetails {
|
|
|
60
60
|
type: string;
|
|
61
61
|
modes: [EcosystemLicenseMode] | null;
|
|
62
62
|
}
|
|
63
|
-
export
|
|
63
|
+
export type Subscription = {
|
|
64
64
|
unsubscribe: () => void;
|
|
65
65
|
};
|
|
66
66
|
/**
|
|
@@ -73,7 +73,7 @@ export interface RuntimePermissions {
|
|
|
73
73
|
scopes?: Scopes;
|
|
74
74
|
external?: External;
|
|
75
75
|
}
|
|
76
|
-
export
|
|
77
|
-
export
|
|
76
|
+
export type ForgeRequestInit = Omit<RequestInit, 'signal'>;
|
|
77
|
+
export type FetchType = 'remote' | 'product';
|
|
78
78
|
export {};
|
|
79
79
|
//# sourceMappingURL=types.d.ts.map
|
package/out/types.d.ts.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"types.d.ts","sourceRoot":"","sources":["../src/types.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,KAAK,wBAAwB,EAAE,MAAM,aAAa,CAAC;AAC5D,OAAO,EAAE,KAAK,UAAU,EAAE,MAAM,kBAAkB,CAAC;AACnD,OAAO,EAAE,KAAK,MAAM,EAAE,KAAK,QAAQ,EAAE,MAAM,iBAAiB,CAAC;AAE7D,
|
|
1
|
+
{"version":3,"file":"types.d.ts","sourceRoot":"","sources":["../src/types.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,KAAK,wBAAwB,EAAE,MAAM,aAAa,CAAC;AAC5D,OAAO,EAAE,KAAK,UAAU,EAAE,MAAM,kBAAkB,CAAC;AACnD,OAAO,EAAE,KAAK,MAAM,EAAE,KAAK,QAAQ,EAAE,MAAM,iBAAiB,CAAC;AAE7D,MAAM,MAAM,aAAa,GAAG;KACzB,GAAG,IAAI,MAAM,GAAG,MAAM,GAAG,GAAG;CAC9B,CAAC;AAEF,MAAM,MAAM,cAAc,GAAG,MAAM,CAAC,M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D,UAAU,aAAa;IACrB,CAAC,CAAC,EAAE,MAAM,GAAG,GAAG,CAAC;CAClB;AAED,aAAK,oBAAoB;IACvB,WAAW,gBAAgB;CAC5B;AACD,MAAM,WAAW,cAAc;IAC7B,MAAM,EAAE,OAAO,CAAC;IAChB,aAAa,EAAE,MAAM,CAAC;IACtB,gBAAgB,EAAE,MAAM,CAAC;IACzB,kBAAkB,EAAE,MAAM,CAAC;IAC3B,YAAY,EAAE,OAAO,CAAC;IACtB,mBAAmB,EAAE,MAAM,GAAG,IAAI,CAAC;IACnC,wBAAwB,EAAE,MAAM,GAAG,IAAI,CAAC;IACxC,YAAY,EAAE,MAAM,GAAG,IAAI,CAAC;IAC5B,IAAI,EAAE,MAAM,CAAC;IACb,KAAK,EAAE,CAAC,oBAAoB,CAAC,GAAG,IAAI,CAAC;CACtC;AAED,MAAM,MAAM,YAAY,GAAG;IACzB,WAAW,EAAE,MAAM,IAAI,CAAC;CACzB,CAAC;AAEF;;;;;GAKG;AACH,MAAM,WAAW,kBAAkB;IACjC,MAAM,CAAC,EAAE,MAAM,CAAC;IAChB,QAAQ,CAAC,EAAE,QAAQ,CAAC;CACrB;AAGD,MAAM,MAAM,gBAAgB,GAAG,IAAI,CAAC,WAAW,EAAE,QAAQ,CAAC,CAAC;AAE3D,MAAM,MAAM,SAAS,GAAG,QAAQ,GAAG,SAAS,CAAC"}
|
package/out/types.js
CHANGED
|
@@ -6,7 +6,7 @@ var ExtensionEnvironment;
|
|
|
6
6
|
ExtensionEnvironment["DEVELOPMENT"] = "DEVELOPMENT";
|
|
7
7
|
ExtensionEnvironment["STAGING"] = "STAGING";
|
|
8
8
|
ExtensionEnvironment["PRODUCTION"] = "PRODUCTION";
|
|
9
|
-
})(ExtensionEnvironment
|
|
9
|
+
})(ExtensionEnvironment || (exports.ExtensionEnvironment = ExtensionEnvironment = {}));
|
|
10
10
|
var EcosystemLicenseMode;
|
|
11
11
|
(function (EcosystemLicenseMode) {
|
|
12
12
|
EcosystemLicenseMode["USER_ACCESS"] = "USER_ACCESS";
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"blobParser.d.ts","sourceRoot":"","sources":["../../src/utils/blobParser.ts"],"names":[],"mappings":"AAAA,eAAO,MAAM,YAAY,
|
|
1
|
+
{"version":3,"file":"blobParser.d.ts","sourceRoot":"","sources":["../../src/utils/blobParser.ts"],"names":[],"mappings":"AAAA,eAAO,MAAM,YAAY,GAAI,WAAW,MAAM,GAAG,SAAS,EAAE,UAAU,MAAM,KAAG,IAAI,GAAG,IAgBrF,CAAC;AAEF,eAAO,MAAM,YAAY,GAAI,MAAM,IAAI,KAAG,OAAO,CAAC,MAAM,CAUvD,CAAC"}
|
package/out/utils/index.d.ts.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../src/utils/index.ts"],"names":[],"mappings":"AAEA,eAAO,MAAM,eAAe,
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../src/utils/index.ts"],"names":[],"mappings":"AAEA,eAAO,MAAM,eAAe,GAAI,EAAE,SAAS,CAAC,GAAG,IAAI,EAAE,GAAG,EAAE,KAAK,GAAG,EAChE,WAAW,EAAE,EACb,QAAQ,MAAM,EACd,cAAc,MAAM,EACpB,uBAAuB,MAAM,MAKf,CAAC,EAAE,GAAG,MAAM,UAAU,CAAC,EAAE,CAAC,KAAG,OAAO,CAAC,CAAC,CAgBrD,CAAC"}
|
|
@@ -1,7 +1,19 @@
|
|
|
1
|
+
import { DocNode } from '@atlaskit/adf-schema';
|
|
1
2
|
import type { FullContext } from '../types';
|
|
3
|
+
interface AdfPostMessageData {
|
|
4
|
+
type: 'adf-document';
|
|
5
|
+
document: DocNode;
|
|
6
|
+
timestamp: number;
|
|
7
|
+
source: 'forge-adf-renderer';
|
|
8
|
+
localId: string;
|
|
9
|
+
isEditing: boolean;
|
|
10
|
+
contentId: string;
|
|
11
|
+
}
|
|
12
|
+
export declare const sendMessageWhenReady: (iframe: HTMLIFrameElement | null, message: AdfPostMessageData, origin: string) => void;
|
|
2
13
|
export declare const createAdfRendererIframeProps: (context: FullContext, iframeId?: string) => Promise<{
|
|
3
14
|
id: string;
|
|
4
15
|
src: string;
|
|
5
16
|
onLoad: () => void;
|
|
6
17
|
}>;
|
|
18
|
+
export {};
|
|
7
19
|
//# sourceMappingURL=adf-renderer.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"adf-renderer.d.ts","sourceRoot":"","sources":["../../src/view/adf-renderer.ts"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"adf-renderer.d.ts","sourceRoot":"","sources":["../../src/view/adf-renderer.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,OAAO,EAAE,MAAM,sBAAsB,CAAC;AAC/C,OAAO,KAAK,EAAE,WAAW,EAAE,MAAM,UAAU,CAAC;AAE5C,UAAU,kBAAkB;IAC1B,IAAI,EAAE,cAAc,CAAC;IACrB,QAAQ,EAAE,OAAO,CAAC;IAClB,SAAS,EAAE,MAAM,CAAC;IAClB,MAAM,EAAE,oBAAoB,CAAC;IAC7B,OAAO,EAAE,MAAM,CAAC;IAChB,SAAS,EAAE,OAAO,CAAC;IACnB,SAAS,EAAE,MAAM,CAAC;CACnB;AAOD,eAAO,MAAM,oBAAoB,GAC/B,QAAQ,iBAAiB,GAAG,IAAI,EAChC,SAAS,kBAAkB,EAC3B,QAAQ,MAAM,KACb,IAgBF,CAAC;AAEF,eAAO,MAAM,4BAA4B,GAAU,SAAS,WAAW,EAAE,WAAW,MAAM;;;;EA0CzF,CAAC"}
|
package/out/view/adf-renderer.js
CHANGED
|
@@ -1,14 +1,68 @@
|
|
|
1
1
|
"use strict";
|
|
2
|
+
var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {
|
|
3
|
+
if (k2 === undefined) k2 = k;
|
|
4
|
+
var desc = Object.getOwnPropertyDescriptor(m, k);
|
|
5
|
+
if (!desc || ("get" in desc ? !m.__esModule : desc.writable || desc.configurable)) {
|
|
6
|
+
desc = { enumerable: true, get: function() { return m[k]; } };
|
|
7
|
+
}
|
|
8
|
+
Object.defineProperty(o, k2, desc);
|
|
9
|
+
}) : (function(o, m, k, k2) {
|
|
10
|
+
if (k2 === undefined) k2 = k;
|
|
11
|
+
o[k2] = m[k];
|
|
12
|
+
}));
|
|
13
|
+
var __setModuleDefault = (this && this.__setModuleDefault) || (Object.create ? (function(o, v) {
|
|
14
|
+
Object.defineProperty(o, "default", { enumerable: true, value: v });
|
|
15
|
+
}) : function(o, v) {
|
|
16
|
+
o["default"] = v;
|
|
17
|
+
});
|
|
18
|
+
var __importStar = (this && this.__importStar) || (function () {
|
|
19
|
+
var ownKeys = function(o) {
|
|
20
|
+
ownKeys = Object.getOwnPropertyNames || function (o) {
|
|
21
|
+
var ar = [];
|
|
22
|
+
for (var k in o) if (Object.prototype.hasOwnProperty.call(o, k)) ar[ar.length] = k;
|
|
23
|
+
return ar;
|
|
24
|
+
};
|
|
25
|
+
return ownKeys(o);
|
|
26
|
+
};
|
|
27
|
+
return function (mod) {
|
|
28
|
+
if (mod && mod.__esModule) return mod;
|
|
29
|
+
var result = {};
|
|
30
|
+
if (mod != null) for (var k = ownKeys(mod), i = 0; i < k.length; i++) if (k[i] !== "default") __createBinding(result, mod, k[i]);
|
|
31
|
+
__setModuleDefault(result, mod);
|
|
32
|
+
return result;
|
|
33
|
+
};
|
|
34
|
+
})();
|
|
2
35
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
-
exports.createAdfRendererIframeProps = void 0;
|
|
36
|
+
exports.createAdfRendererIframeProps = exports.sendMessageWhenReady = void 0;
|
|
37
|
+
/**
|
|
38
|
+
* Sends the ADF document message to the adf-renderer iframe once it signals readiness.
|
|
39
|
+
*/
|
|
40
|
+
const READY_SIGNAL_FALLBACK_DELAY_MS = 10000;
|
|
41
|
+
const sendMessageWhenReady = (iframe, message, origin) => {
|
|
42
|
+
const sendMessage = () => { var _a; return (_a = iframe === null || iframe === void 0 ? void 0 : iframe.contentWindow) === null || _a === void 0 ? void 0 : _a.postMessage(message, origin); };
|
|
43
|
+
const timeoutId = setTimeout(() => {
|
|
44
|
+
window.removeEventListener('message', handleReady);
|
|
45
|
+
sendMessage();
|
|
46
|
+
}, READY_SIGNAL_FALLBACK_DELAY_MS);
|
|
47
|
+
const handleReady = (event) => {
|
|
48
|
+
var _a;
|
|
49
|
+
if (event.source === (iframe === null || iframe === void 0 ? void 0 : iframe.contentWindow) && ((_a = event.data) === null || _a === void 0 ? void 0 : _a.source) === 'forge-adf-renderer-ready') {
|
|
50
|
+
clearTimeout(timeoutId);
|
|
51
|
+
window.removeEventListener('message', handleReady);
|
|
52
|
+
sendMessage();
|
|
53
|
+
}
|
|
54
|
+
};
|
|
55
|
+
window.addEventListener('message', handleReady);
|
|
56
|
+
};
|
|
57
|
+
exports.sendMessageWhenReady = sendMessageWhenReady;
|
|
4
58
|
const createAdfRendererIframeProps = async (context, iframeId) => {
|
|
5
|
-
const IframeResizer = await
|
|
59
|
+
const IframeResizer = await Promise.resolve().then(() => __importStar(require('iframe-resizer')));
|
|
6
60
|
const IframeResizerModule = IframeResizer.default || IframeResizer;
|
|
7
61
|
const origin = new URL(document.referrer).origin;
|
|
8
62
|
const src = `${origin}/forge-apps/adf-renderer`;
|
|
9
63
|
const id = iframeId || `forge-adf-renderer-iframe-${crypto.randomUUID()}`;
|
|
10
64
|
const onLoad = () => {
|
|
11
|
-
var _a, _b, _c, _d, _e
|
|
65
|
+
var _a, _b, _c, _d, _e;
|
|
12
66
|
const iframe = document.getElementById(id);
|
|
13
67
|
const message = {
|
|
14
68
|
type: 'adf-document',
|
|
@@ -27,7 +81,7 @@ const createAdfRendererIframeProps = async (context, iframeId) => {
|
|
|
27
81
|
(_a = iframe === null || iframe === void 0 ? void 0 : iframe.iFrameResizer) === null || _a === void 0 ? void 0 : _a.resize();
|
|
28
82
|
}
|
|
29
83
|
}, iframe || '');
|
|
30
|
-
(
|
|
84
|
+
(0, exports.sendMessageWhenReady)(iframe, message, origin);
|
|
31
85
|
};
|
|
32
86
|
setTimeout(() => {
|
|
33
87
|
document.documentElement.style.height = 'auto';
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"changeWindowTitle.d.ts","sourceRoot":"","sources":["../../src/view/changeWindowTitle.ts"],"names":[],"mappings":"AAKA,eAAO,MAAM,iBAAiB,
|
|
1
|
+
{"version":3,"file":"changeWindowTitle.d.ts","sourceRoot":"","sources":["../../src/view/changeWindowTitle.ts"],"names":[],"mappings":"AAKA,eAAO,MAAM,iBAAiB,GAAU,OAAO,MAAM,kBAMpD,CAAC"}
|
package/out/view/close.d.ts.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"close.d.ts","sourceRoot":"","sources":["../../src/view/close.ts"],"names":[],"mappings":"AAKA,eAAO,MAAM,KAAK,
|
|
1
|
+
{"version":3,"file":"close.d.ts","sourceRoot":"","sources":["../../src/view/close.ts"],"names":[],"mappings":"AAKA,eAAO,MAAM,KAAK,GAAU,UAAU,GAAG,kBAUxC,CAAC"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"createHistory.d.ts","sourceRoot":"","sources":["../../src/view/createHistory.ts"],"names":[],"mappings":"AACA,OAAO,KAAK,EAAE,OAAO,EAAE,MAAM,SAAS,CAAC;AAIvC,eAAO,MAAM,aAAa,QAAa,
|
|
1
|
+
{"version":3,"file":"createHistory.d.ts","sourceRoot":"","sources":["../../src/view/createHistory.ts"],"names":[],"mappings":"AACA,OAAO,KAAK,EAAE,OAAO,EAAE,MAAM,SAAS,CAAC;AAIvC,eAAO,MAAM,aAAa,QAAa,OAAO,CAAC,OAAO,CAOrD,CAAC"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"emitReadyEvent.d.ts","sourceRoot":"","sources":["../../src/view/emitReadyEvent.ts"],"names":[],"mappings":"AAQA,eAAO,MAAM,cAAc,QAAa,
|
|
1
|
+
{"version":3,"file":"emitReadyEvent.d.ts","sourceRoot":"","sources":["../../src/view/emitReadyEvent.ts"],"names":[],"mappings":"AAQA,eAAO,MAAM,cAAc,QAAa,OAAO,CAAC,IAAI,CAenD,CAAC"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"getContext.d.ts","sourceRoot":"","sources":["../../src/view/getContext.ts"],"names":[],"mappings":"AACA,OAAO,EAAE,WAAW,EAAE,MAAM,UAAU,CAAC;AAKvC,eAAO,MAAM,UAAU,QAAa,
|
|
1
|
+
{"version":3,"file":"getContext.d.ts","sourceRoot":"","sources":["../../src/view/getContext.ts"],"names":[],"mappings":"AACA,OAAO,EAAE,WAAW,EAAE,MAAM,UAAU,CAAC;AAKvC,eAAO,MAAM,UAAU,QAAa,OAAO,CAAC,WAAW,CAStD,CAAC"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"getFrameDispatch.d.ts","sourceRoot":"","sources":["../../src/view/getFrameDispatch.ts"],"names":[],"mappings":"AAEA,KAAK,gBAAgB,GAAG,CAAC,GAAG,IAAI,EAAE,GAAG,EAAE,KAAK,GAAG,CAAC;AAIhD,eAAO,MAAM,gBAAgB,GAAU,CAAC,SAAS,gBAAgB,OAAK,OAAO,CAAC,CAAC,GAAG,SAAS,CAE1F,CAAC"}
|
|
@@ -0,0 +1,9 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.getFrameDispatch = void 0;
|
|
4
|
+
const bridge_1 = require("../bridge");
|
|
5
|
+
const callBridge = (0, bridge_1.getCallBridge)();
|
|
6
|
+
const getFrameDispatch = async () => {
|
|
7
|
+
return await callBridge('getFrameDispatch');
|
|
8
|
+
};
|
|
9
|
+
exports.getFrameDispatch = getFrameDispatch;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"onClose.d.ts","sourceRoot":"","sources":["../../src/view/onClose.ts"],"names":[],"mappings":"AAKA,eAAO,MAAM,OAAO,
|
|
1
|
+
{"version":3,"file":"onClose.d.ts","sourceRoot":"","sources":["../../src/view/onClose.ts"],"names":[],"mappings":"AAKA,eAAO,MAAM,OAAO,GAAU,SAAS,MAAM,OAAO,CAAC,IAAI,CAAC,kBASzD,CAAC"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"refresh.d.ts","sourceRoot":"","sources":["../../src/view/refresh.ts"],"names":[],"mappings":"AAKA,eAAO,MAAM,OAAO,
|
|
1
|
+
{"version":3,"file":"refresh.d.ts","sourceRoot":"","sources":["../../src/view/refresh.ts"],"names":[],"mappings":"AAKA,eAAO,MAAM,OAAO,GAAU,UAAU,GAAG,kBAK1C,CAAC"}
|
package/out/view/submit.d.ts.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"submit.d.ts","sourceRoot":"","sources":["../../src/view/submit.ts"],"names":[],"mappings":"AAKA,eAAO,MAAM,MAAM,
|
|
1
|
+
{"version":3,"file":"submit.d.ts","sourceRoot":"","sources":["../../src/view/submit.ts"],"names":[],"mappings":"AAKA,eAAO,MAAM,MAAM,GAAU,UAAU,GAAG,kBAKzC,CAAC"}
|
package/out/view/theme.d.ts.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"theme.d.ts","sourceRoot":"","sources":["../../src/view/theme.ts"],"names":[],"mappings":"AAIA,eAAO,MAAM,KAAK;kBACJ,
|
|
1
|
+
{"version":3,"file":"theme.d.ts","sourceRoot":"","sources":["../../src/view/theme.ts"],"names":[],"mappings":"AAIA,eAAO,MAAM,KAAK;kBACJ,OAAO,CAAC,IAAI,CAAC;CAC1B,CAAC"}
|
package/out/view/view.d.ts
CHANGED
|
@@ -5,13 +5,14 @@ export declare const view: {
|
|
|
5
5
|
open: () => Promise<void>;
|
|
6
6
|
refresh: (payload?: any) => Promise<void>;
|
|
7
7
|
createHistory: () => Promise<import("history").History>;
|
|
8
|
-
getContext: () => Promise<import("
|
|
8
|
+
getContext: () => Promise<import("..").FullContext>;
|
|
9
|
+
getFrameDispatch: <T extends (...args: any[]) => any>() => Promise<T | undefined>;
|
|
9
10
|
theme: {
|
|
10
11
|
enable: () => Promise<void>;
|
|
11
12
|
};
|
|
12
13
|
changeWindowTitle: (title: string) => Promise<void>;
|
|
13
14
|
emitReadyEvent: () => Promise<void>;
|
|
14
|
-
createAdfRendererIframeProps: (context: import("
|
|
15
|
+
createAdfRendererIframeProps: (context: import("..").FullContext, iframeId?: string) => Promise<{
|
|
15
16
|
id: string;
|
|
16
17
|
src: string;
|
|
17
18
|
onLoad: () => void;
|
package/out/view/view.d.ts.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"view.d.ts","sourceRoot":"","sources":["../../src/view/view.ts"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"view.d.ts","sourceRoot":"","sources":["../../src/view/view.ts"],"names":[],"mappings":"AAaA,eAAO,MAAM,IAAI;;;;;;;;;;;;;;;;;;;CAahB,CAAC"}
|
package/out/view/view.js
CHANGED
|
@@ -12,6 +12,7 @@ const theme_1 = require("./theme");
|
|
|
12
12
|
const emitReadyEvent_1 = require("./emitReadyEvent");
|
|
13
13
|
const adf_renderer_1 = require("./adf-renderer");
|
|
14
14
|
const onClose_1 = require("./onClose");
|
|
15
|
+
const getFrameDispatch_1 = require("./getFrameDispatch");
|
|
15
16
|
exports.view = {
|
|
16
17
|
submit: submit_1.submit,
|
|
17
18
|
close: close_1.close,
|
|
@@ -20,6 +21,7 @@ exports.view = {
|
|
|
20
21
|
refresh: refresh_1.refresh,
|
|
21
22
|
createHistory: createHistory_1.createHistory,
|
|
22
23
|
getContext: getContext_1.getContext,
|
|
24
|
+
getFrameDispatch: getFrameDispatch_1.getFrameDispatch,
|
|
23
25
|
theme: theme_1.theme,
|
|
24
26
|
changeWindowTitle: changeWindowTitle_1.changeWindowTitle,
|
|
25
27
|
emitReadyEvent: emitReadyEvent_1.emitReadyEvent,
|