@trackunit/iris-app-api 1.3.147 → 1.3.148
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 +4 -0
- package/package.json +1 -1
- package/src/types/cspDirectives.d.ts +15 -15
- package/src/types/cspDirectives.js.map +1 -1
- package/src/types/extensions/adminExtensionManifest.d.ts +1 -1
- package/src/types/extensions/adminExtensionManifest.js.map +1 -1
- package/src/types/extensions/assetEventsActionsExtensionManifest.d.ts +6 -6
- package/src/types/extensions/assetEventsActionsExtensionManifest.js.map +1 -1
- package/src/types/extensions/assetHomeExtensionManifest.d.ts +4 -4
- package/src/types/extensions/assetHomeExtensionManifest.js.map +1 -1
- package/src/types/extensions/customerHomeExtensionManifest.d.ts +1 -1
- package/src/types/extensions/customerHomeExtensionManifest.js.map +1 -1
- package/src/types/extensions/fleetExtensionManifest.d.ts +3 -3
- package/src/types/extensions/fleetExtensionManifest.js.map +1 -1
- package/src/types/extensions/siteHomeExtensionManifest.d.ts +3 -3
- package/src/types/extensions/siteHomeExtensionManifest.js.map +1 -1
- package/src/types/extensions/widgetExtensionManifest.d.ts +3 -3
- package/src/types/extensions/widgetExtensionManifest.js.map +1 -1
- package/src/types/irisAppCspInput.d.ts +8 -8
- package/src/types/irisAppCspInput.js.map +1 -1
- package/src/types/irisAppCustomFields.d.ts +3 -3
- package/src/types/irisAppCustomFields.js.map +1 -1
- package/src/types/irisAppExtensionManifest.d.ts +3 -3
- package/src/types/irisAppExtensionManifest.js.map +1 -1
- package/src/types/irisAppInstallationConfig.d.ts +5 -5
- package/src/types/irisAppInstallationConfig.js.map +1 -1
- package/src/types/irisAppManifest.d.ts +7 -7
- package/src/types/irisAppManifest.js.map +1 -1
- package/src/types/irisAppMarketplace.d.ts +4 -4
- package/src/types/irisAppMarketplace.js.map +1 -1
- package/src/types/modulefederation.d.ts +3 -3
- package/src/types/modulefederation.js.map +1 -1
- package/src/types/permissionsPolicy.d.ts +1 -1
- package/src/types/permissionsPolicy.js.map +1 -1
package/CHANGELOG.md
CHANGED
|
@@ -1,3 +1,7 @@
|
|
|
1
|
+
## 1.3.148 (2025-06-11)
|
|
2
|
+
|
|
3
|
+
This was a version bump only for iris-app-api to align it with other projects, there were no code changes.
|
|
4
|
+
|
|
1
5
|
## 1.3.147 (2025-06-11)
|
|
2
6
|
|
|
3
7
|
This was a version bump only for iris-app-api to align it with other projects, there were no code changes.
|
package/package.json
CHANGED
|
@@ -27,21 +27,21 @@ export declare const UNSAFE_HASHES = "'unsafe-hashes'";
|
|
|
27
27
|
export declare const UNSAFE_INLINE = "'unsafe-inline'";
|
|
28
28
|
export declare const WASM_UNSAFE_EVAL = "'wasm-unsafe-eval'";
|
|
29
29
|
export type CSPDirectives = {
|
|
30
|
-
"child-src": TFetchDirective
|
|
31
|
-
"connect-src": TFetchDirective
|
|
32
|
-
"font-src": TFetchDirective
|
|
33
|
-
"form-action": TNavigationDirective
|
|
34
|
-
"frame-src": TFetchDirective
|
|
35
|
-
"img-src":
|
|
36
|
-
"media-src": TFetchDirective
|
|
37
|
-
sandbox:
|
|
38
|
-
"script-src":
|
|
39
|
-
"script-src-attr":
|
|
40
|
-
"script-src-elem":
|
|
41
|
-
"style-src": TFetchDirective
|
|
42
|
-
"style-src-attr":
|
|
43
|
-
"style-src-elem":
|
|
30
|
+
"child-src": Array<TFetchDirective>;
|
|
31
|
+
"connect-src": Array<TFetchDirective>;
|
|
32
|
+
"font-src": Array<TFetchDirective>;
|
|
33
|
+
"form-action": Array<TNavigationDirective>;
|
|
34
|
+
"frame-src": Array<TFetchDirective>;
|
|
35
|
+
"img-src": Array<TFetchDirective | typeof STRICT_DYNAMIC>;
|
|
36
|
+
"media-src": Array<TFetchDirective>;
|
|
37
|
+
sandbox: Array<typeof ALLOW_DOWNLOADS_WITHOUT_USER_ACTIVATION | typeof ALLOW_FORMS | typeof ALLOW_MODALS | typeof ALLOW_ORIENTATION_LOCK | typeof ALLOW_POINTER_LOCK | typeof ALLOW_POPUPS | typeof ALLOW_POPUPS_TO_ESCAPE_SANDBOX | typeof ALLOW_PRESENTATION | typeof ALLOW_SAME_ORIGIN | typeof ALLOW_SCRIPTS | typeof ALLOW_STORAGE_ACCESS_BY_USER_ACTIVATION | typeof ALLOW_TOP_NAVIGATION | typeof ALLOW_TOP_NAVIGATION_BY_USER_ACTIVATION>;
|
|
38
|
+
"script-src": Array<TFetchDirective | typeof STRICT_DYNAMIC | typeof REPORT_SAMPLE | typeof WASM_UNSAFE_EVAL>;
|
|
39
|
+
"script-src-attr": Array<TAttrDirective | typeof REPORT_SAMPLE>;
|
|
40
|
+
"script-src-elem": Array<TFetchDirective | typeof STRICT_DYNAMIC | typeof REPORT_SAMPLE>;
|
|
41
|
+
"style-src": Array<TFetchDirective> | typeof REPORT_SAMPLE;
|
|
42
|
+
"style-src-attr": Array<TAttrDirective | typeof REPORT_SAMPLE>;
|
|
43
|
+
"style-src-elem": Array<TFetchDirective | typeof REPORT_SAMPLE>;
|
|
44
44
|
"upgrade-insecure-requests": boolean;
|
|
45
|
-
"worker-src": TFetchDirective
|
|
45
|
+
"worker-src": Array<TFetchDirective>;
|
|
46
46
|
};
|
|
47
47
|
export {};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"cspDirectives.js","sourceRoot":"","sources":["../../../../../../libs/iris-app-sdk/iris-app-api/src/types/cspDirectives.ts"],"names":[],"mappings":";AAAA,EAAE;AACF,yFAAyF;AACzF,EAAE;;;AAEW,QAAA,uCAAuC,GAAG,yCAAyC,CAAC;AACpF,QAAA,gBAAgB,GAAG,oBAAoB,CAAC;AACxC,QAAA,WAAW,GAAG,aAAa,CAAC;AAC5B,QAAA,YAAY,GAAG,cAAc,CAAC;AAC9B,QAAA,sBAAsB,GAAG,wBAAwB,CAAC;AAClD,QAAA,kBAAkB,GAAG,oBAAoB,CAAC;AAC1C,QAAA,YAAY,GAAG,cAAc,CAAC;AAC9B,QAAA,8BAA8B,GAAG,gCAAgC,CAAC;AAClE,QAAA,kBAAkB,GAAG,oBAAoB,CAAC;AAC1C,QAAA,iBAAiB,GAAG,mBAAmB,CAAC;AACxC,QAAA,uCAAuC,GAAG,yCAAyC,CAAC;AACpF,QAAA,aAAa,GAAG,qBAAqB,CAAC;AACtC,QAAA,oBAAoB,GAAG,sBAAsB,CAAC;AAC9C,QAAA,uCAAuC,GAAG,yCAAyC,CAAC;AA0BpF,QAAA,IAAI,GAAG,QAAQ,CAAC;AAChB,QAAA,IAAI,GAAG,QAAQ,CAAC;AAChB,QAAA,cAAc,GAAG,kBAAkB,CAAC;AACpC,QAAA,aAAa,GAAG,iBAAiB,CAAC;AAClC,QAAA,WAAW,GAAG,eAAe,CAAC;AAC9B,QAAA,aAAa,GAAG,iBAAiB,CAAC;AAClC,QAAA,aAAa,GAAG,iBAAiB,CAAC;AAClC,QAAA,gBAAgB,GAAG,oBAAoB,CAAC","sourcesContent":["//\n// Based on types from https://www.npmjs.com/package/csp-header but adjusted to our needs\n//\n\nexport const ALLOW_DOWNLOADS_WITHOUT_USER_ACTIVATION = \"allow-downloads-without-user-activation\";\nexport const ALLOW_DUPLICATES = \"'allow-duplicates'\";\nexport const ALLOW_FORMS = \"allow-forms\";\nexport const ALLOW_MODALS = \"allow-modals\";\nexport const ALLOW_ORIENTATION_LOCK = \"allow-orientation-lock\";\nexport const ALLOW_POINTER_LOCK = \"allow-pointer-lock\";\nexport const ALLOW_POPUPS = \"allow-popups\";\nexport const ALLOW_POPUPS_TO_ESCAPE_SANDBOX = \"allow-popups-to-escape-sandbox\";\nexport const ALLOW_PRESENTATION = \"allow-presentation\";\nexport const ALLOW_SAME_ORIGIN = \"allow-same-origin\";\nexport const ALLOW_STORAGE_ACCESS_BY_USER_ACTIVATION = \"allow-storage-access-by-user-activation\";\nexport const ALLOW_SCRIPTS = \"allow-allow-scripts\";\nexport const ALLOW_TOP_NAVIGATION = \"allow-top-navigation\";\nexport const ALLOW_TOP_NAVIGATION_BY_USER_ACTIVATION = \"allow-top-navigation-by-user-activation\";\n\ntype TSource = string;\ntype TNonce = `nonce-${string}`;\ntype THash = `sha${\"256\" | \"384\" | \"512\"}-${string}`;\ntype TAttrDirective = THash | typeof NONE | typeof UNSAFE_INLINE | typeof UNSAFE_HASHES;\ntype TFetchDirective =\n | TSource\n | TNonce\n | THash\n | typeof NONE\n | typeof SELF\n | typeof UNSAFE_EVAL\n | typeof UNSAFE_HASHES\n | typeof UNSAFE_INLINE;\ntype TNavigationDirective =\n | TSource\n | TNonce\n | THash\n | typeof NONE\n | typeof SELF\n | typeof UNSAFE_EVAL\n | typeof UNSAFE_HASHES\n | typeof UNSAFE_INLINE\n | typeof STRICT_DYNAMIC;\n\nexport const NONE = \"'none'\";\nexport const SELF = \"'self'\";\nexport const STRICT_DYNAMIC = \"'strict-dynamic'\";\nexport const REPORT_SAMPLE = \"'report-sample'\";\nexport const UNSAFE_EVAL = \"'unsafe-eval'\";\nexport const UNSAFE_HASHES = \"'unsafe-hashes'\";\nexport const UNSAFE_INLINE = \"'unsafe-inline'\";\nexport const WASM_UNSAFE_EVAL = \"'wasm-unsafe-eval'\";\n\nexport type CSPDirectives = {\n \"child-src\": TFetchDirective
|
|
1
|
+
{"version":3,"file":"cspDirectives.js","sourceRoot":"","sources":["../../../../../../libs/iris-app-sdk/iris-app-api/src/types/cspDirectives.ts"],"names":[],"mappings":";AAAA,EAAE;AACF,yFAAyF;AACzF,EAAE;;;AAEW,QAAA,uCAAuC,GAAG,yCAAyC,CAAC;AACpF,QAAA,gBAAgB,GAAG,oBAAoB,CAAC;AACxC,QAAA,WAAW,GAAG,aAAa,CAAC;AAC5B,QAAA,YAAY,GAAG,cAAc,CAAC;AAC9B,QAAA,sBAAsB,GAAG,wBAAwB,CAAC;AAClD,QAAA,kBAAkB,GAAG,oBAAoB,CAAC;AAC1C,QAAA,YAAY,GAAG,cAAc,CAAC;AAC9B,QAAA,8BAA8B,GAAG,gCAAgC,CAAC;AAClE,QAAA,kBAAkB,GAAG,oBAAoB,CAAC;AAC1C,QAAA,iBAAiB,GAAG,mBAAmB,CAAC;AACxC,QAAA,uCAAuC,GAAG,yCAAyC,CAAC;AACpF,QAAA,aAAa,GAAG,qBAAqB,CAAC;AACtC,QAAA,oBAAoB,GAAG,sBAAsB,CAAC;AAC9C,QAAA,uCAAuC,GAAG,yCAAyC,CAAC;AA0BpF,QAAA,IAAI,GAAG,QAAQ,CAAC;AAChB,QAAA,IAAI,GAAG,QAAQ,CAAC;AAChB,QAAA,cAAc,GAAG,kBAAkB,CAAC;AACpC,QAAA,aAAa,GAAG,iBAAiB,CAAC;AAClC,QAAA,WAAW,GAAG,eAAe,CAAC;AAC9B,QAAA,aAAa,GAAG,iBAAiB,CAAC;AAClC,QAAA,aAAa,GAAG,iBAAiB,CAAC;AAClC,QAAA,gBAAgB,GAAG,oBAAoB,CAAC","sourcesContent":["//\n// Based on types from https://www.npmjs.com/package/csp-header but adjusted to our needs\n//\n\nexport const ALLOW_DOWNLOADS_WITHOUT_USER_ACTIVATION = \"allow-downloads-without-user-activation\";\nexport const ALLOW_DUPLICATES = \"'allow-duplicates'\";\nexport const ALLOW_FORMS = \"allow-forms\";\nexport const ALLOW_MODALS = \"allow-modals\";\nexport const ALLOW_ORIENTATION_LOCK = \"allow-orientation-lock\";\nexport const ALLOW_POINTER_LOCK = \"allow-pointer-lock\";\nexport const ALLOW_POPUPS = \"allow-popups\";\nexport const ALLOW_POPUPS_TO_ESCAPE_SANDBOX = \"allow-popups-to-escape-sandbox\";\nexport const ALLOW_PRESENTATION = \"allow-presentation\";\nexport const ALLOW_SAME_ORIGIN = \"allow-same-origin\";\nexport const ALLOW_STORAGE_ACCESS_BY_USER_ACTIVATION = \"allow-storage-access-by-user-activation\";\nexport const ALLOW_SCRIPTS = \"allow-allow-scripts\";\nexport const ALLOW_TOP_NAVIGATION = \"allow-top-navigation\";\nexport const ALLOW_TOP_NAVIGATION_BY_USER_ACTIVATION = \"allow-top-navigation-by-user-activation\";\n\ntype TSource = string;\ntype TNonce = `nonce-${string}`;\ntype THash = `sha${\"256\" | \"384\" | \"512\"}-${string}`;\ntype TAttrDirective = THash | typeof NONE | typeof UNSAFE_INLINE | typeof UNSAFE_HASHES;\ntype TFetchDirective =\n | TSource\n | TNonce\n | THash\n | typeof NONE\n | typeof SELF\n | typeof UNSAFE_EVAL\n | typeof UNSAFE_HASHES\n | typeof UNSAFE_INLINE;\ntype TNavigationDirective =\n | TSource\n | TNonce\n | THash\n | typeof NONE\n | typeof SELF\n | typeof UNSAFE_EVAL\n | typeof UNSAFE_HASHES\n | typeof UNSAFE_INLINE\n | typeof STRICT_DYNAMIC;\n\nexport const NONE = \"'none'\";\nexport const SELF = \"'self'\";\nexport const STRICT_DYNAMIC = \"'strict-dynamic'\";\nexport const REPORT_SAMPLE = \"'report-sample'\";\nexport const UNSAFE_EVAL = \"'unsafe-eval'\";\nexport const UNSAFE_HASHES = \"'unsafe-hashes'\";\nexport const UNSAFE_INLINE = \"'unsafe-inline'\";\nexport const WASM_UNSAFE_EVAL = \"'wasm-unsafe-eval'\";\n\nexport type CSPDirectives = {\n \"child-src\": Array<TFetchDirective>;\n \"connect-src\": Array<TFetchDirective>;\n \"font-src\": Array<TFetchDirective>;\n \"form-action\": Array<TNavigationDirective>;\n \"frame-src\": Array<TFetchDirective>;\n \"img-src\": Array<TFetchDirective | typeof STRICT_DYNAMIC>;\n \"media-src\": Array<TFetchDirective>;\n sandbox: Array<| typeof ALLOW_DOWNLOADS_WITHOUT_USER_ACTIVATION\n | typeof ALLOW_FORMS\n | typeof ALLOW_MODALS\n | typeof ALLOW_ORIENTATION_LOCK\n | typeof ALLOW_POINTER_LOCK\n | typeof ALLOW_POPUPS\n | typeof ALLOW_POPUPS_TO_ESCAPE_SANDBOX\n | typeof ALLOW_PRESENTATION\n | typeof ALLOW_SAME_ORIGIN\n | typeof ALLOW_SCRIPTS\n | typeof ALLOW_STORAGE_ACCESS_BY_USER_ACTIVATION\n | typeof ALLOW_TOP_NAVIGATION\n | typeof ALLOW_TOP_NAVIGATION_BY_USER_ACTIVATION>;\n \"script-src\": Array<TFetchDirective | typeof STRICT_DYNAMIC | typeof REPORT_SAMPLE | typeof WASM_UNSAFE_EVAL>;\n \"script-src-attr\": Array<TAttrDirective | typeof REPORT_SAMPLE>;\n \"script-src-elem\": Array<TFetchDirective | typeof STRICT_DYNAMIC | typeof REPORT_SAMPLE>;\n \"style-src\": Array<TFetchDirective> | typeof REPORT_SAMPLE;\n \"style-src-attr\": Array<TAttrDirective | typeof REPORT_SAMPLE>;\n \"style-src-elem\": Array<TFetchDirective | typeof REPORT_SAMPLE>;\n \"upgrade-insecure-requests\": boolean;\n \"worker-src\": Array<TFetchDirective>;\n};\n"]}
|
|
@@ -10,7 +10,7 @@ export interface AdminExtensionManifest extends AbstractExtensionManifest {
|
|
|
10
10
|
* - If more scopes are used/filled out then the admin home extension will be shown for all assets that the user has one of the required scopes for.
|
|
11
11
|
*/
|
|
12
12
|
conditions?: {
|
|
13
|
-
scopes?: AccountScope | AccountScope
|
|
13
|
+
scopes?: AccountScope | Array<AccountScope>;
|
|
14
14
|
};
|
|
15
15
|
menuItem: {
|
|
16
16
|
name: string | Translations | TranslationKey;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"adminExtensionManifest.js","sourceRoot":"","sources":["../../../../../../../libs/iris-app-sdk/iris-app-api/src/types/extensions/adminExtensionManifest.ts"],"names":[],"mappings":"","sourcesContent":["import { AbstractExtensionManifest, TranslationKey, Translations } from \"../irisAppExtensionManifest\";\nimport { AccountScope } from \"../scopes\";\n\nexport interface AdminExtensionManifest extends AbstractExtensionManifest {\n type: \"ADMIN_EXTENSION\";\n\n /**\n * Conditions for the admin extension to be shown.\n *\n * Its doing OR between the conditions of the same type:\n * - If only 1 scopes is used/filled out then the admin home extension will be shown if user has the required scope.\n * - If more scopes are used/filled out then the admin home extension will be shown for all assets that the user has one of the required scopes for.\n */\n conditions?: {\n scopes?: AccountScope | AccountScope
|
|
1
|
+
{"version":3,"file":"adminExtensionManifest.js","sourceRoot":"","sources":["../../../../../../../libs/iris-app-sdk/iris-app-api/src/types/extensions/adminExtensionManifest.ts"],"names":[],"mappings":"","sourcesContent":["import { AbstractExtensionManifest, TranslationKey, Translations } from \"../irisAppExtensionManifest\";\nimport { AccountScope } from \"../scopes\";\n\nexport interface AdminExtensionManifest extends AbstractExtensionManifest {\n type: \"ADMIN_EXTENSION\";\n\n /**\n * Conditions for the admin extension to be shown.\n *\n * Its doing OR between the conditions of the same type:\n * - If only 1 scopes is used/filled out then the admin home extension will be shown if user has the required scope.\n * - If more scopes are used/filled out then the admin home extension will be shown for all assets that the user has one of the required scopes for.\n */\n conditions?: {\n scopes?: AccountScope | Array<AccountScope>;\n };\n\n menuItem: {\n name: string | Translations | TranslationKey;\n };\n}\n"]}
|
|
@@ -16,15 +16,15 @@ export interface AssetEventsActionsExtensionManifest extends AbstractExtensionMa
|
|
|
16
16
|
* - If no conditions are used/filled out then the asset events actions extension will be shown for all assets and events.
|
|
17
17
|
*/
|
|
18
18
|
conditions?: {
|
|
19
|
-
eventType?: EVENT_TYPE | EVENT_TYPE
|
|
20
|
-
sourceAddress?: number | number
|
|
21
|
-
failureModeIdentifier?: number | number
|
|
22
|
-
suspectParameterNumber?: number | number
|
|
23
|
-
scopes?: AccountScope | AccountScope
|
|
19
|
+
eventType?: EVENT_TYPE | Array<EVENT_TYPE>;
|
|
20
|
+
sourceAddress?: number | Array<number>;
|
|
21
|
+
failureModeIdentifier?: number | Array<number>;
|
|
22
|
+
suspectParameterNumber?: number | Array<number>;
|
|
23
|
+
scopes?: AccountScope | Array<AccountScope>;
|
|
24
24
|
/**
|
|
25
25
|
* Only entityType ASSET custom fields are supported here
|
|
26
26
|
*/
|
|
27
|
-
requiredCustomField?: RequiredCustomField | RequiredCustomField
|
|
27
|
+
requiredCustomField?: RequiredCustomField | Array<RequiredCustomField>;
|
|
28
28
|
};
|
|
29
29
|
menuItem: {
|
|
30
30
|
name: string | Translations | TranslationKey;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"assetEventsActionsExtensionManifest.js","sourceRoot":"","sources":["../../../../../../../libs/iris-app-sdk/iris-app-api/src/types/extensions/assetEventsActionsExtensionManifest.ts"],"names":[],"mappings":"","sourcesContent":["import {\n AbstractExtensionManifest,\n RequiredCustomField,\n TranslationKey,\n Translations,\n} from \"../irisAppExtensionManifest\";\nimport { AccountScope } from \"../scopes\";\n/**\n * BETA! DONT USE THIS YET - its under development\n */\n\nexport type EVENT_TYPE =\n | \"ALERT\"\n | \"CAN_ERROR\"\n | \"DAMAGE_REPORT\"\n | \"FLUCTUATING_CAN_ERROR\"\n | \"MACHINE_FAULT\"\n | \"SERVICE\";\n\nexport interface AssetEventsActionsExtensionManifest extends AbstractExtensionManifest {\n type: \"ASSET_EVENTS_ACTIONS_EXTENSION\";\n /**\n * Conditions for the asset events actions extension to be shown.\n * Its doing AND between the conditions types and OR between the conditions of the same type:\n * - If only failureModeIdentifier or suspectParameterNumber or eventType or SourceAddress is used/filled out then the event needs to match the filled out property.\n * - If more failureModeIdentifier, suspectParameterNumber, SourceAddress, and eventType is used/filled out then asset events actions extension will be shown for all events that matches all FMI, SPN, and eventType.\n * - If only scopes is used/filled out then the asset events actions extension will be shown for all assets that the user has the required scopes for.\n * - If more scopes are used/filled out then the asset events actions extension will be shown for all assets that the user has one of the required scopes for.\n * - If no conditions are used/filled out then the asset events actions extension will be shown for all assets and events.\n */\n conditions?: {\n eventType?: EVENT_TYPE | EVENT_TYPE
|
|
1
|
+
{"version":3,"file":"assetEventsActionsExtensionManifest.js","sourceRoot":"","sources":["../../../../../../../libs/iris-app-sdk/iris-app-api/src/types/extensions/assetEventsActionsExtensionManifest.ts"],"names":[],"mappings":"","sourcesContent":["import {\n AbstractExtensionManifest,\n RequiredCustomField,\n TranslationKey,\n Translations,\n} from \"../irisAppExtensionManifest\";\nimport { AccountScope } from \"../scopes\";\n/**\n * BETA! DONT USE THIS YET - its under development\n */\n\nexport type EVENT_TYPE =\n | \"ALERT\"\n | \"CAN_ERROR\"\n | \"DAMAGE_REPORT\"\n | \"FLUCTUATING_CAN_ERROR\"\n | \"MACHINE_FAULT\"\n | \"SERVICE\";\n\nexport interface AssetEventsActionsExtensionManifest extends AbstractExtensionManifest {\n type: \"ASSET_EVENTS_ACTIONS_EXTENSION\";\n /**\n * Conditions for the asset events actions extension to be shown.\n * Its doing AND between the conditions types and OR between the conditions of the same type:\n * - If only failureModeIdentifier or suspectParameterNumber or eventType or SourceAddress is used/filled out then the event needs to match the filled out property.\n * - If more failureModeIdentifier, suspectParameterNumber, SourceAddress, and eventType is used/filled out then asset events actions extension will be shown for all events that matches all FMI, SPN, and eventType.\n * - If only scopes is used/filled out then the asset events actions extension will be shown for all assets that the user has the required scopes for.\n * - If more scopes are used/filled out then the asset events actions extension will be shown for all assets that the user has one of the required scopes for.\n * - If no conditions are used/filled out then the asset events actions extension will be shown for all assets and events.\n */\n conditions?: {\n eventType?: EVENT_TYPE | Array<EVENT_TYPE>;\n sourceAddress?: number | Array<number>;\n failureModeIdentifier?: number | Array<number>;\n suspectParameterNumber?: number | Array<number>;\n scopes?: AccountScope | Array<AccountScope>;\n\n /**\n * Only entityType ASSET custom fields are supported here\n */\n requiredCustomField?: RequiredCustomField | Array<RequiredCustomField>;\n };\n menuItem: {\n name: string | Translations | TranslationKey;\n };\n}\n"]}
|
|
@@ -15,13 +15,13 @@ export interface AssetHomeExtensionManifest extends AbstractExtensionManifest {
|
|
|
15
15
|
* - If no conditions are used/filled out then the asset home extension will be shown for all assets.
|
|
16
16
|
*/
|
|
17
17
|
conditions?: {
|
|
18
|
-
model?:
|
|
19
|
-
brand?:
|
|
20
|
-
scopes?: AccountScope | AccountScope
|
|
18
|
+
model?: Array<string | RegExpType> | string | RegExpType;
|
|
19
|
+
brand?: Array<string | RegExpType> | string | RegExpType;
|
|
20
|
+
scopes?: AccountScope | Array<AccountScope>;
|
|
21
21
|
/**
|
|
22
22
|
* Only entityType ASSET custom fields are supported here
|
|
23
23
|
*/
|
|
24
|
-
requiredCustomField?: RequiredCustomField | RequiredCustomField
|
|
24
|
+
requiredCustomField?: RequiredCustomField | Array<RequiredCustomField>;
|
|
25
25
|
};
|
|
26
26
|
menuItem: {
|
|
27
27
|
name: string | Translations | TranslationKey;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"assetHomeExtensionManifest.js","sourceRoot":"","sources":["../../../../../../../libs/iris-app-sdk/iris-app-api/src/types/extensions/assetHomeExtensionManifest.ts"],"names":[],"mappings":"","sourcesContent":["import {\n AbstractExtensionManifest,\n RegExpType,\n RequiredCustomField,\n TranslationKey,\n Translations,\n} from \"../irisAppExtensionManifest\";\nimport { AccountScope } from \"../scopes\";\n\nexport interface AssetHomeExtensionManifest extends AbstractExtensionManifest {\n type: \"ASSET_HOME_EXTENSION\";\n /**\n * Conditions for the asset home extension to be shown.\n * model and brand is case insensitive so does not matter how you write the brand.\n * brand: \"trackunit\" and brand: \"Trackunit\" will be the same.\n *\n * Its doing AND between the conditions types and OR between the conditions of the same type:\n * - If both model and brand are used/filled out then asset needs to match both model and brand.\n * - If only brand or model is used/filled out then the asset needs to match the filled out property.\n * - If only scopes is used/filled out then the asset home extension will be shown for all assets that the user has the required scopes for.\n * - If more scopes are used/filled out then the asset home extension will be shown for all assets that the user has one of the required scopes for.\n * - If no conditions are used/filled out then the asset home extension will be shown for all assets.\n */\n conditions?: {\n model?:
|
|
1
|
+
{"version":3,"file":"assetHomeExtensionManifest.js","sourceRoot":"","sources":["../../../../../../../libs/iris-app-sdk/iris-app-api/src/types/extensions/assetHomeExtensionManifest.ts"],"names":[],"mappings":"","sourcesContent":["import {\n AbstractExtensionManifest,\n RegExpType,\n RequiredCustomField,\n TranslationKey,\n Translations,\n} from \"../irisAppExtensionManifest\";\nimport { AccountScope } from \"../scopes\";\n\nexport interface AssetHomeExtensionManifest extends AbstractExtensionManifest {\n type: \"ASSET_HOME_EXTENSION\";\n /**\n * Conditions for the asset home extension to be shown.\n * model and brand is case insensitive so does not matter how you write the brand.\n * brand: \"trackunit\" and brand: \"Trackunit\" will be the same.\n *\n * Its doing AND between the conditions types and OR between the conditions of the same type:\n * - If both model and brand are used/filled out then asset needs to match both model and brand.\n * - If only brand or model is used/filled out then the asset needs to match the filled out property.\n * - If only scopes is used/filled out then the asset home extension will be shown for all assets that the user has the required scopes for.\n * - If more scopes are used/filled out then the asset home extension will be shown for all assets that the user has one of the required scopes for.\n * - If no conditions are used/filled out then the asset home extension will be shown for all assets.\n */\n conditions?: {\n model?: Array<string | RegExpType> | string | RegExpType;\n brand?: Array<string | RegExpType> | string | RegExpType;\n scopes?: AccountScope | Array<AccountScope>;\n\n /**\n * Only entityType ASSET custom fields are supported here\n */\n requiredCustomField?: RequiredCustomField | Array<RequiredCustomField>;\n };\n menuItem: {\n name: string | Translations | TranslationKey;\n };\n}\n"]}
|
|
@@ -12,7 +12,7 @@ export interface CustomerHomeExtensionManifest extends AbstractExtensionManifest
|
|
|
12
12
|
* - If both scopes and showFor are used then the extension will be shown for all customers that match the showFor condition and the user has the required permission for.
|
|
13
13
|
*/
|
|
14
14
|
conditions?: {
|
|
15
|
-
scopes?: AccountScope | AccountScope
|
|
15
|
+
scopes?: AccountScope | Array<AccountScope>;
|
|
16
16
|
/**
|
|
17
17
|
* - If showFor is "ALL" then the extension will be shown for all customers in customer home.
|
|
18
18
|
* - If showFor is "BUSINESS_UNITS" then the extension will be shown for all business units in customer home.
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"customerHomeExtensionManifest.js","sourceRoot":"","sources":["../../../../../../../libs/iris-app-sdk/iris-app-api/src/types/extensions/customerHomeExtensionManifest.ts"],"names":[],"mappings":"","sourcesContent":["import { AbstractExtensionManifest, TranslationKey, Translations } from \"../irisAppExtensionManifest\";\nimport { AccountScope } from \"../scopes\";\n\nexport interface CustomerHomeExtensionManifest extends AbstractExtensionManifest {\n type: \"CUSTOMER_HOME_EXTENSION\";\n\n /**\n * Conditions for the customer home extension to be shown.\n *\n * Its doing AND between the conditions types and OR between the conditions of the same type:\n * - If only scopes is used/filled out then the extension will be shown for all customers that the user has the required permission for.\n * - If more scopes are used/filled out then the extension will be shown for all customers that the user has one of the required permission for.\n * - If showFor is used then the extension will be shown for all customers that match the showFor condition.\n * - If both scopes and showFor are used then the extension will be shown for all customers that match the showFor condition and the user has the required permission for.\n */\n conditions?: {\n scopes?: AccountScope | AccountScope
|
|
1
|
+
{"version":3,"file":"customerHomeExtensionManifest.js","sourceRoot":"","sources":["../../../../../../../libs/iris-app-sdk/iris-app-api/src/types/extensions/customerHomeExtensionManifest.ts"],"names":[],"mappings":"","sourcesContent":["import { AbstractExtensionManifest, TranslationKey, Translations } from \"../irisAppExtensionManifest\";\nimport { AccountScope } from \"../scopes\";\n\nexport interface CustomerHomeExtensionManifest extends AbstractExtensionManifest {\n type: \"CUSTOMER_HOME_EXTENSION\";\n\n /**\n * Conditions for the customer home extension to be shown.\n *\n * Its doing AND between the conditions types and OR between the conditions of the same type:\n * - If only scopes is used/filled out then the extension will be shown for all customers that the user has the required permission for.\n * - If more scopes are used/filled out then the extension will be shown for all customers that the user has one of the required permission for.\n * - If showFor is used then the extension will be shown for all customers that match the showFor condition.\n * - If both scopes and showFor are used then the extension will be shown for all customers that match the showFor condition and the user has the required permission for.\n */\n conditions?: {\n scopes?: AccountScope | Array<AccountScope>;\n /**\n * - If showFor is \"ALL\" then the extension will be shown for all customers in customer home.\n * - If showFor is \"BUSINESS_UNITS\" then the extension will be shown for all business units in customer home.\n * - If showFor is \"CUSTOMERS\" then the extension will be shown for all customers that are not business units in customer home.\n */\n showFor?: \"ALL\" | \"BUSINESS_UNITS\" | \"CUSTOMERS\";\n };\n\n menuItem: {\n name: string | Translations | TranslationKey;\n };\n}\n"]}
|
|
@@ -16,9 +16,9 @@ export interface FleetExtensionManifest extends AbstractExtensionManifest {
|
|
|
16
16
|
* - If no conditions are used/filled out then the asset home extension will be shown for all assets.
|
|
17
17
|
*/
|
|
18
18
|
conditions?: {
|
|
19
|
-
model?:
|
|
20
|
-
brand?:
|
|
21
|
-
scopes?: AccountScope | AccountScope
|
|
19
|
+
model?: Array<string | RegExpType> | string | RegExpType;
|
|
20
|
+
brand?: Array<string | RegExpType> | string | RegExpType;
|
|
21
|
+
scopes?: AccountScope | Array<AccountScope>;
|
|
22
22
|
};
|
|
23
23
|
menuItem: {
|
|
24
24
|
/**
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"fleetExtensionManifest.js","sourceRoot":"","sources":["../../../../../../../libs/iris-app-sdk/iris-app-api/src/types/extensions/fleetExtensionManifest.ts"],"names":[],"mappings":"","sourcesContent":["import { IconByName, IconByPath } from \"../iconImage\";\nimport { AbstractExtensionManifest, RegExpType, TranslationKey, Translations } from \"../irisAppExtensionManifest\";\nimport { AccountScope } from \"../scopes\";\n\nexport interface FleetExtensionManifest extends AbstractExtensionManifest {\n type: \"FLEET_EXTENSION\";\n\n /**\n * Conditions for the fleet extension to be shown.\n * It is case insensitive so does not matter how you write the brand.\n * brand: \"trackunit\" and brand: \"Trackunit\" will be the same.\n *\n * Its doing AND between the conditions types and OR between the conditions of the same type:\n * - If both model and brand are used/filled out then asset needs to match both model and brand.\n * - If only brand or model is used/filled out then the asset needs to match the filled out property.\n * - If only scopes is used/filled out then the fleet extension will be shown if the user has the required scope.\n * - If more scopes are used/filled out then the fleet extension will be shown if the user has one of the required scopes.\n * - If no conditions are used/filled out then the asset home extension will be shown for all assets.\n */\n conditions?: {\n model?:
|
|
1
|
+
{"version":3,"file":"fleetExtensionManifest.js","sourceRoot":"","sources":["../../../../../../../libs/iris-app-sdk/iris-app-api/src/types/extensions/fleetExtensionManifest.ts"],"names":[],"mappings":"","sourcesContent":["import { IconByName, IconByPath } from \"../iconImage\";\nimport { AbstractExtensionManifest, RegExpType, TranslationKey, Translations } from \"../irisAppExtensionManifest\";\nimport { AccountScope } from \"../scopes\";\n\nexport interface FleetExtensionManifest extends AbstractExtensionManifest {\n type: \"FLEET_EXTENSION\";\n\n /**\n * Conditions for the fleet extension to be shown.\n * It is case insensitive so does not matter how you write the brand.\n * brand: \"trackunit\" and brand: \"Trackunit\" will be the same.\n *\n * Its doing AND between the conditions types and OR between the conditions of the same type:\n * - If both model and brand are used/filled out then asset needs to match both model and brand.\n * - If only brand or model is used/filled out then the asset needs to match the filled out property.\n * - If only scopes is used/filled out then the fleet extension will be shown if the user has the required scope.\n * - If more scopes are used/filled out then the fleet extension will be shown if the user has one of the required scopes.\n * - If no conditions are used/filled out then the asset home extension will be shown for all assets.\n */\n conditions?: {\n model?: Array<string | RegExpType> | string | RegExpType;\n brand?: Array<string | RegExpType> | string | RegExpType;\n scopes?: AccountScope | Array<AccountScope>;\n };\n\n menuItem: {\n /**\n * The name used in the menu item.\n */\n name: string | Translations | TranslationKey;\n /**\n * The icon used in the menu item.\n *\n * @deprecated please use image instead.\n */\n icon?: string;\n image?: IconByName | IconByPath;\n\n /**\n * Description of the menu item, used in the 'Applications' menu.\n */\n description?: string | Translations | TranslationKey;\n };\n}\n"]}
|
|
@@ -23,12 +23,12 @@ export interface SiteHomeExtensionManifest extends AbstractExtensionManifest {
|
|
|
23
23
|
* - If no conditions are used/filled out then the site home extension will be shown for all sites.
|
|
24
24
|
*/
|
|
25
25
|
conditions?: {
|
|
26
|
-
siteType?: SiteType
|
|
27
|
-
scopes?: AccountScope | AccountScope
|
|
26
|
+
siteType?: Array<SiteType> | SiteType;
|
|
27
|
+
scopes?: AccountScope | Array<AccountScope>;
|
|
28
28
|
/**
|
|
29
29
|
* Only entityType SITE custom fields are supported here
|
|
30
30
|
*/
|
|
31
|
-
requiredCustomField?: RequiredCustomField | RequiredCustomField
|
|
31
|
+
requiredCustomField?: RequiredCustomField | Array<RequiredCustomField>;
|
|
32
32
|
};
|
|
33
33
|
menuItem: {
|
|
34
34
|
name: string | Translations | TranslationKey;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"siteHomeExtensionManifest.js","sourceRoot":"","sources":["../../../../../../../libs/iris-app-sdk/iris-app-api/src/types/extensions/siteHomeExtensionManifest.ts"],"names":[],"mappings":";;AAQA,6DAA6D;AAC7D,MAAM,QAAQ,GAAG;IACf,IAAI,EAAE,MAAM;IACZ,WAAW,EAAE,aAAa;IAC1B,YAAY,EAAE,cAAc;IAC5B,iBAAiB,EAAE,mBAAmB;IACtC,KAAK,EAAE,OAAO;IACd,WAAW,EAAE,aAAa;IAC1B,UAAU,EAAE,YAAY;CAChB,CAAC","sourcesContent":["import {\n AbstractExtensionManifest,\n RequiredCustomField,\n TranslationKey,\n Translations,\n} from \"../irisAppExtensionManifest\";\nimport { AccountScope } from \"../scopes\";\n\n// eslint-disable-next-line @typescript-eslint/no-unused-vars\nconst siteType = {\n AREA: \"AREA\",\n CLASSIC_POI: \"CLASSIC_POI\",\n CLASSIC_ZONE: \"CLASSIC_ZONE\",\n CONSTRUCTION_SITE: \"CONSTRUCTION_SITE\",\n DEPOT: \"DEPOT\",\n NOT_ON_SITE: \"NOT_ON_SITE\",\n WORK_PLACE: \"WORK_PLACE\",\n} as const;\ntype SiteType = (typeof siteType)[keyof typeof siteType];\n\nexport interface SiteHomeExtensionManifest extends AbstractExtensionManifest {\n type: \"SITE_HOME_EXTENSION\";\n\n /**\n * Conditions for the site home extension to be shown.\n *\n * Its doing AND between the conditions types and OR between the conditions of the same type:\n * - If only scopes is used/filled out then the site home extension will be shown for all sites that the user has the required permission for.\n * - If more scopes are used/filled out then the site home extension will be shown for all sites that the user has one of the required permission for.\n * - If only requiredCustomField is used/filled out then the site home extension will be shown for all sites that has the required custom field.\n * - If more requiredCustomField are used/filled out then the site home extension will be shown for all sites that has all of the required custom field.\n * - If no conditions are used/filled out then the site home extension will be shown for all sites.\n */\n conditions?: {\n siteType?: SiteType
|
|
1
|
+
{"version":3,"file":"siteHomeExtensionManifest.js","sourceRoot":"","sources":["../../../../../../../libs/iris-app-sdk/iris-app-api/src/types/extensions/siteHomeExtensionManifest.ts"],"names":[],"mappings":";;AAQA,6DAA6D;AAC7D,MAAM,QAAQ,GAAG;IACf,IAAI,EAAE,MAAM;IACZ,WAAW,EAAE,aAAa;IAC1B,YAAY,EAAE,cAAc;IAC5B,iBAAiB,EAAE,mBAAmB;IACtC,KAAK,EAAE,OAAO;IACd,WAAW,EAAE,aAAa;IAC1B,UAAU,EAAE,YAAY;CAChB,CAAC","sourcesContent":["import {\n AbstractExtensionManifest,\n RequiredCustomField,\n TranslationKey,\n Translations,\n} from \"../irisAppExtensionManifest\";\nimport { AccountScope } from \"../scopes\";\n\n// eslint-disable-next-line @typescript-eslint/no-unused-vars\nconst siteType = {\n AREA: \"AREA\",\n CLASSIC_POI: \"CLASSIC_POI\",\n CLASSIC_ZONE: \"CLASSIC_ZONE\",\n CONSTRUCTION_SITE: \"CONSTRUCTION_SITE\",\n DEPOT: \"DEPOT\",\n NOT_ON_SITE: \"NOT_ON_SITE\",\n WORK_PLACE: \"WORK_PLACE\",\n} as const;\ntype SiteType = (typeof siteType)[keyof typeof siteType];\n\nexport interface SiteHomeExtensionManifest extends AbstractExtensionManifest {\n type: \"SITE_HOME_EXTENSION\";\n\n /**\n * Conditions for the site home extension to be shown.\n *\n * Its doing AND between the conditions types and OR between the conditions of the same type:\n * - If only scopes is used/filled out then the site home extension will be shown for all sites that the user has the required permission for.\n * - If more scopes are used/filled out then the site home extension will be shown for all sites that the user has one of the required permission for.\n * - If only requiredCustomField is used/filled out then the site home extension will be shown for all sites that has the required custom field.\n * - If more requiredCustomField are used/filled out then the site home extension will be shown for all sites that has all of the required custom field.\n * - If no conditions are used/filled out then the site home extension will be shown for all sites.\n */\n conditions?: {\n siteType?: Array<SiteType> | SiteType;\n scopes?: AccountScope | Array<AccountScope>;\n\n /**\n * Only entityType SITE custom fields are supported here\n */\n requiredCustomField?: RequiredCustomField | Array<RequiredCustomField>;\n };\n\n menuItem: {\n name: string | Translations | TranslationKey;\n };\n}\n"]}
|
|
@@ -20,8 +20,8 @@ export declare const allCustomerFilterKeysWithCustomFields: readonly ["search",
|
|
|
20
20
|
export type CustomerFilterKeysWithCustomFields = typeof allCustomerFilterKeysWithCustomFields;
|
|
21
21
|
export declare const allTimeRangeFilterKeys: readonly ["ALL"];
|
|
22
22
|
export type TimeRangeFilterKeys = typeof allTimeRangeFilterKeys;
|
|
23
|
-
type FilterConfig<TFilterKeys extends
|
|
24
|
-
include: TFilterKeys[number]
|
|
23
|
+
type FilterConfig<TFilterKeys extends ReadonlyArray<string>> = {
|
|
24
|
+
include: Array<TFilterKeys[number]>;
|
|
25
25
|
};
|
|
26
26
|
export type SupportedFiltersConfig = {
|
|
27
27
|
ASSETS?: FilterConfig<AssetFilterKeysWithCustomFields>;
|
|
@@ -79,7 +79,7 @@ export interface WidgetExtensionManifest extends AbstractExtensionManifest {
|
|
|
79
79
|
/**
|
|
80
80
|
* The locations where the widget can be placed.
|
|
81
81
|
*/
|
|
82
|
-
supportedLocations: WidgetSupportedLocations
|
|
82
|
+
supportedLocations: Array<WidgetSupportedLocations>;
|
|
83
83
|
/**
|
|
84
84
|
* The filters that the widget can be filtered by.
|
|
85
85
|
*/
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"widgetExtensionManifest.js","sourceRoot":"","sources":["../../../../../../../libs/iris-app-sdk/iris-app-api/src/types/extensions/widgetExtensionManifest.ts"],"names":[],"mappings":";;;AASa,QAAA,WAAW,GAAG,CAAC,KAAK,EAAE,OAAO,EAAE,MAAM,EAAE,KAAK,EAAE,OAAO,CAAU,CAAC;AAIhE,QAAA,kBAAkB,GAAG;IAChC,QAAQ;IACR,SAAS;IACT,QAAQ;IACR,OAAO;IACP,WAAW;IACX,QAAQ;IACR,QAAQ;IACR,aAAa;IACb,UAAU;IACV,sBAAsB;IACtB,UAAU;IACV,UAAU;IACV,UAAU;IACV,iBAAiB;IACjB,MAAM;IACN,SAAS;IACT,iBAAiB;IACjB,eAAe;IACf,qBAAqB;IACrB,cAAc;IACd,uBAAuB;CACf,CAAC;AAEE,QAAA,oBAAoB,GAAG,cAAuB,CAAC;AAE/C,QAAA,kCAAkC,GAAG,CAAC,GAAG,0BAAkB,EAAE,4BAAoB,CAAU,CAAC;AAG5F,QAAA,iBAAiB,GAAG,CAAC,QAAQ,EAAE,YAAY,EAAE,UAAU,CAAU,CAAC;AAElE,QAAA,iCAAiC,GAAG,CAAC,GAAG,yBAAiB,EAAE,4BAAoB,CAAU,CAAC;AAG1F,QAAA,qBAAqB,GAAG,CAAC,QAAQ,EAAE,cAAc,EAAE,aAAa,EAAE,aAAa,CAAU,CAAC;AAE1F,QAAA,qCAAqC,GAAG,CAAC,GAAG,6BAAqB,EAAE,4BAAoB,CAAU,CAAC;AAGlG,QAAA,sBAAsB,GAAG,CAAC,KAAK,CAAU,CAAC","sourcesContent":["import { IconByName, IconByPath } from \"../iconImage\";\nimport { AbstractExtensionManifest, TranslationKey, Translations } from \"../irisAppExtensionManifest\";\n\nexport type WidgetSupportedLocations = \"MY_HOME\" | \"SITE_HOME\";\n\nexport type WidgetSupportedFilterBars = \"CUSTOMERS\" | \"ASSETS\" | \"SITES\";\n\nexport type WidgetSupportedFilters = WidgetSupportedFilterBars | \"TIME_RANGE\";\n\nexport const widgetTypes = [\"KPI\", \"CHART\", \"LIST\", \"MAP\", \"OTHER\"] as const;\n\nexport type WidgetType = (typeof widgetTypes)[number];\n\nexport const allAssetFilterKeys = [\n \"search\",\n \"siteIds\",\n \"groups\",\n \"types\",\n \"assetType\",\n \"brands\",\n \"models\",\n \"criticality\",\n \"activity\",\n \"metadataCompleteness\",\n \"lastSeen\",\n \"followed\",\n \"siteType\",\n \"ownerAccountIds\",\n \"area\",\n \"partner\",\n \"productionYears\",\n \"serviceStatus\",\n \"telematicsConnected\",\n \"activeFilter\",\n \"siteDepotOwnershipIds\",\n] as const;\n\nexport const customFieldFilterKey = \"customFields\" as const;\nexport type AssetFilterKeys = typeof allAssetFilterKeys;\nexport const allAssetFilterKeysWithCustomFields = [...allAssetFilterKeys, customFieldFilterKey] as const;\nexport type AssetFilterKeysWithCustomFields = typeof allAssetFilterKeysWithCustomFields;\n\nexport const allSiteFilterKeys = [\"search\", \"siteStatus\", \"siteType\"] as const;\nexport type SiteFilterKeys = typeof allSiteFilterKeys;\nexport const allSiteFilterKeysWithCustomFields = [...allSiteFilterKeys, customFieldFilterKey] as const;\nexport type SiteFilterKeysWithCustomFields = typeof allSiteFilterKeysWithCustomFields;\n\nexport const allCustomerFilterKeys = [\"search\", \"customerType\", \"criticality\", \"servicePlan\"] as const;\nexport type CustomerFilterKeys = typeof allCustomerFilterKeys;\nexport const allCustomerFilterKeysWithCustomFields = [...allCustomerFilterKeys, customFieldFilterKey] as const;\nexport type CustomerFilterKeysWithCustomFields = typeof allCustomerFilterKeysWithCustomFields;\n\nexport const allTimeRangeFilterKeys = [\"ALL\"] as const;\nexport type TimeRangeFilterKeys = typeof allTimeRangeFilterKeys;\n\ntype FilterConfig<TFilterKeys extends
|
|
1
|
+
{"version":3,"file":"widgetExtensionManifest.js","sourceRoot":"","sources":["../../../../../../../libs/iris-app-sdk/iris-app-api/src/types/extensions/widgetExtensionManifest.ts"],"names":[],"mappings":";;;AASa,QAAA,WAAW,GAAG,CAAC,KAAK,EAAE,OAAO,EAAE,MAAM,EAAE,KAAK,EAAE,OAAO,CAAU,CAAC;AAIhE,QAAA,kBAAkB,GAAG;IAChC,QAAQ;IACR,SAAS;IACT,QAAQ;IACR,OAAO;IACP,WAAW;IACX,QAAQ;IACR,QAAQ;IACR,aAAa;IACb,UAAU;IACV,sBAAsB;IACtB,UAAU;IACV,UAAU;IACV,UAAU;IACV,iBAAiB;IACjB,MAAM;IACN,SAAS;IACT,iBAAiB;IACjB,eAAe;IACf,qBAAqB;IACrB,cAAc;IACd,uBAAuB;CACf,CAAC;AAEE,QAAA,oBAAoB,GAAG,cAAuB,CAAC;AAE/C,QAAA,kCAAkC,GAAG,CAAC,GAAG,0BAAkB,EAAE,4BAAoB,CAAU,CAAC;AAG5F,QAAA,iBAAiB,GAAG,CAAC,QAAQ,EAAE,YAAY,EAAE,UAAU,CAAU,CAAC;AAElE,QAAA,iCAAiC,GAAG,CAAC,GAAG,yBAAiB,EAAE,4BAAoB,CAAU,CAAC;AAG1F,QAAA,qBAAqB,GAAG,CAAC,QAAQ,EAAE,cAAc,EAAE,aAAa,EAAE,aAAa,CAAU,CAAC;AAE1F,QAAA,qCAAqC,GAAG,CAAC,GAAG,6BAAqB,EAAE,4BAAoB,CAAU,CAAC;AAGlG,QAAA,sBAAsB,GAAG,CAAC,KAAK,CAAU,CAAC","sourcesContent":["import { IconByName, IconByPath } from \"../iconImage\";\nimport { AbstractExtensionManifest, TranslationKey, Translations } from \"../irisAppExtensionManifest\";\n\nexport type WidgetSupportedLocations = \"MY_HOME\" | \"SITE_HOME\";\n\nexport type WidgetSupportedFilterBars = \"CUSTOMERS\" | \"ASSETS\" | \"SITES\";\n\nexport type WidgetSupportedFilters = WidgetSupportedFilterBars | \"TIME_RANGE\";\n\nexport const widgetTypes = [\"KPI\", \"CHART\", \"LIST\", \"MAP\", \"OTHER\"] as const;\n\nexport type WidgetType = (typeof widgetTypes)[number];\n\nexport const allAssetFilterKeys = [\n \"search\",\n \"siteIds\",\n \"groups\",\n \"types\",\n \"assetType\",\n \"brands\",\n \"models\",\n \"criticality\",\n \"activity\",\n \"metadataCompleteness\",\n \"lastSeen\",\n \"followed\",\n \"siteType\",\n \"ownerAccountIds\",\n \"area\",\n \"partner\",\n \"productionYears\",\n \"serviceStatus\",\n \"telematicsConnected\",\n \"activeFilter\",\n \"siteDepotOwnershipIds\",\n] as const;\n\nexport const customFieldFilterKey = \"customFields\" as const;\nexport type AssetFilterKeys = typeof allAssetFilterKeys;\nexport const allAssetFilterKeysWithCustomFields = [...allAssetFilterKeys, customFieldFilterKey] as const;\nexport type AssetFilterKeysWithCustomFields = typeof allAssetFilterKeysWithCustomFields;\n\nexport const allSiteFilterKeys = [\"search\", \"siteStatus\", \"siteType\"] as const;\nexport type SiteFilterKeys = typeof allSiteFilterKeys;\nexport const allSiteFilterKeysWithCustomFields = [...allSiteFilterKeys, customFieldFilterKey] as const;\nexport type SiteFilterKeysWithCustomFields = typeof allSiteFilterKeysWithCustomFields;\n\nexport const allCustomerFilterKeys = [\"search\", \"customerType\", \"criticality\", \"servicePlan\"] as const;\nexport type CustomerFilterKeys = typeof allCustomerFilterKeys;\nexport const allCustomerFilterKeysWithCustomFields = [...allCustomerFilterKeys, customFieldFilterKey] as const;\nexport type CustomerFilterKeysWithCustomFields = typeof allCustomerFilterKeysWithCustomFields;\n\nexport const allTimeRangeFilterKeys = [\"ALL\"] as const;\nexport type TimeRangeFilterKeys = typeof allTimeRangeFilterKeys;\n\ntype FilterConfig<TFilterKeys extends ReadonlyArray<string>> = {\n include: Array<TFilterKeys[number]>;\n};\n\nexport type SupportedFiltersConfig = {\n ASSETS?: FilterConfig<AssetFilterKeysWithCustomFields>;\n SITES?: FilterConfig<SiteFilterKeysWithCustomFields>;\n CUSTOMERS?: FilterConfig<CustomerFilterKeysWithCustomFields>;\n TIME_RANGE?: FilterConfig<TimeRangeFilterKeys>;\n};\n\n/**\n * BETA! DO NOT USE THIS YET - its under development\n */\nexport interface WidgetExtensionManifest extends AbstractExtensionManifest {\n type: \"WIDGET_EXTENSION\";\n\n preview?: {\n /**\n * The description of the widget to display on Adding drawer.\n */\n description?: string | Translations | TranslationKey;\n };\n\n widgetType: WidgetType;\n\n size: {\n default: {\n width: 1 | 2 | 3 | 4 | 5 | 6;\n height: 1 | 2 | 3 | 4 | 5 | 6;\n };\n allowFullWidth?: boolean;\n };\n\n header: {\n /**\n * The name of the widget to display in the header\n */\n name: string | Translations | TranslationKey;\n\n /**\n * The image of the widget to display in the header, if not it will default to the icon of the manifest.\n */\n image?: IconByName | IconByPath;\n\n /**\n * If true a button will be on the header and an editDialog from the src folder of this extension will be loaded\n */\n hasEditDialog?: boolean;\n };\n\n footer?: {\n /**\n * The link description to display in the footer, if not it will default to localized version of 'See full details'.\n */\n linkDescription?: string | Translations | TranslationKey;\n\n /**\n * The link to display in the footer, the absolute path to the route of the extension you want to link to.\n */\n link: string;\n\n /**\n * The powered by image to display in the footer.\n */\n poweredByImage?: IconByPath;\n };\n\n /**\n * The locations where the widget can be placed.\n */\n supportedLocations: Array<WidgetSupportedLocations>;\n\n /**\n * The filters that the widget can be filtered by.\n */\n supportedFilters?: SupportedFiltersConfig;\n}\n"]}
|
|
@@ -4,13 +4,13 @@ import { CSPDirectives } from "./cspDirectives";
|
|
|
4
4
|
*/
|
|
5
5
|
export type CspDirectives = {
|
|
6
6
|
directives: {
|
|
7
|
-
"default-src": string
|
|
8
|
-
"script-src": string
|
|
9
|
-
"worker-src": string
|
|
10
|
-
"style-src": string
|
|
11
|
-
"img-src": string
|
|
12
|
-
"connect-src": string
|
|
13
|
-
"frame-ancestors"?: string
|
|
7
|
+
"default-src": Array<string>;
|
|
8
|
+
"script-src": Array<string>;
|
|
9
|
+
"worker-src": Array<string>;
|
|
10
|
+
"style-src": Array<string>;
|
|
11
|
+
"img-src": Array<string>;
|
|
12
|
+
"connect-src": Array<string>;
|
|
13
|
+
"frame-ancestors"?: Array<string>;
|
|
14
14
|
};
|
|
15
15
|
reportUri?: string;
|
|
16
16
|
};
|
|
@@ -21,7 +21,7 @@ export type CspDirectives = {
|
|
|
21
21
|
* @param cspHeader input cspHeader from manifest
|
|
22
22
|
* @returns the CSP input for the Iris Apps Csp Header
|
|
23
23
|
*/
|
|
24
|
-
export declare const irisAppCspInput: (validDomains?: string
|
|
24
|
+
export declare const irisAppCspInput: (validDomains?: Array<string>, cspHeader?: Partial<CSPDirectives>) => Partial<CSPDirectives>;
|
|
25
25
|
export declare const irisAppDefaultCsp: {
|
|
26
26
|
"default-src": string[];
|
|
27
27
|
"script-src": string[];
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"irisAppCspInput.js","sourceRoot":"","sources":["../../../../../../libs/iris-app-sdk/iris-app-api/src/types/irisAppCspInput.ts"],"names":[],"mappings":";;;AAAA,mDAA2E;AAE3E,MAAM,WAAW,GAAG;IAClB,yBAAyB;IACzB,4BAA4B;IAC5B,uBAAuB;IACvB,gCAAgC;IAChC,uBAAuB;IACvB,2BAA2B;IAC3B,uBAAuB;IACvB,uBAAuB;IACvB,yBAAyB;IACzB,sBAAsB;CACvB,CAAC;AAkBF;;;;;;GAMG;AACI,MAAM,eAAe,GAAG,CAC7B,
|
|
1
|
+
{"version":3,"file":"irisAppCspInput.js","sourceRoot":"","sources":["../../../../../../libs/iris-app-sdk/iris-app-api/src/types/irisAppCspInput.ts"],"names":[],"mappings":";;;AAAA,mDAA2E;AAE3E,MAAM,WAAW,GAAG;IAClB,yBAAyB;IACzB,4BAA4B;IAC5B,uBAAuB;IACvB,gCAAgC;IAChC,uBAAuB;IACvB,2BAA2B;IAC3B,uBAAuB;IACvB,uBAAuB;IACvB,yBAAyB;IACzB,sBAAsB;CACvB,CAAC;AAkBF;;;;;;GAMG;AACI,MAAM,eAAe,GAAG,CAC7B,YAA4B,EAC5B,SAAkC,EACV,EAAE;IAC1B,IAAI,SAAS,EAAE,CAAC;QACd,OAAO,SAAS,CAAC;IACnB,CAAC;SAAM,IAAI,YAAY,EAAE,CAAC;QACxB,OAAO;YACL,YAAY,EAAE,YAAY;YAC1B,SAAS,EAAE,YAAY;YACvB,YAAY,EAAE,YAAY;YAC1B,aAAa,EAAE,YAAY;SAC5B,CAAC;IACJ,CAAC;SAAM,CAAC;QACN,OAAO,EAAE,CAAC;IACZ,CAAC;AACH,CAAC,CAAC;AAhBW,QAAA,eAAe,mBAgB1B;AAEW,QAAA,iBAAiB,GAAG;IAC/B,aAAa,EAAE,CAAC,oBAAI,CAAC;IACrB,YAAY,EAAE,CAAC,oBAAI,CAAC;IACpB,SAAS,EAAE,CAAC,oBAAI,EAAE,mCAAmC,EAAE,iCAAiC,CAAC;IACzF,YAAY,EAAE,CAAC,oBAAI,CAAC;IACpB,WAAW,EAAE,CAAC,6BAAa,EAAE,8BAA8B,CAAC;IAC5D,aAAa,EAAE,CAAC,oBAAI,EAAE,qBAAqB,EAAE,mBAAmB,EAAE,GAAG,WAAW,CAAC;IACjF,cAAc,EAAE,CAAC,oBAAI,CAAC;IACtB,YAAY,EAAE,CAAC,oBAAI,CAAC;IACpB,UAAU,EAAE,CAAC,oBAAI,EAAE,2BAA2B,CAAC;IAC/C,2BAA2B,EAAE,IAAI;CAClC,CAAC","sourcesContent":["import { CSPDirectives, NONE, SELF, UNSAFE_INLINE } from \"./cspDirectives\";\n\nconst BrandedUrls = [\n \"https://*.trackunit.com\",\n \"https://*.wackerneuson.com\",\n \"https://*.manitou.com\",\n \"https://*.niftylinkmanager.com\",\n \"https://*.skyjack.com\",\n \"https://*.ahernaccess.com\",\n \"https://*.magnith.com\",\n \"https://*.terberg.com\",\n \"https://*.mymecalac.com\",\n \"https://*.delille.be\",\n];\n\n/**\n * This type is used to generate the CSP input for the Iris Apps Csp Header\n */\nexport type CspDirectives = {\n directives: {\n \"default-src\": Array<string>;\n \"script-src\": Array<string>;\n \"worker-src\": Array<string>;\n \"style-src\": Array<string>;\n \"img-src\": Array<string>;\n \"connect-src\": Array<string>;\n \"frame-ancestors\"?: Array<string>;\n };\n reportUri?: string;\n};\n\n/**\n * This function is used to generate the CSP input for the Iris Apps Csp Header\n *\n * @param validDomains input legacy validDomains from manifest\n * @param cspHeader input cspHeader from manifest\n * @returns the CSP input for the Iris Apps Csp Header\n */\nexport const irisAppCspInput = (\n validDomains?: Array<string>,\n cspHeader?: Partial<CSPDirectives>\n): Partial<CSPDirectives> => {\n if (cspHeader) {\n return cspHeader;\n } else if (validDomains) {\n return {\n \"script-src\": validDomains,\n \"img-src\": validDomains,\n \"worker-src\": validDomains,\n \"connect-src\": validDomains,\n };\n } else {\n return {};\n }\n};\n\nexport const irisAppDefaultCsp = {\n \"default-src\": [SELF],\n \"script-src\": [SELF],\n \"img-src\": [SELF, \"https://images.iris.trackunit.com\", \"https://*.awsapi.trackunit.com/\"],\n \"worker-src\": [SELF],\n \"style-src\": [UNSAFE_INLINE, \"https://fonts.googleapis.com\"],\n \"connect-src\": [SELF, \"https://*.sentry.io\", \"https://sentry.io\", ...BrandedUrls],\n \"manifest-src\": [NONE],\n \"object-src\": [NONE],\n \"font-src\": [SELF, \"https://fonts.gstatic.com\"],\n \"upgrade-insecure-requests\": true,\n};\n"]}
|
|
@@ -39,7 +39,7 @@ export type CustomFieldTranslationArray = [
|
|
|
39
39
|
title: string;
|
|
40
40
|
description?: string;
|
|
41
41
|
},
|
|
42
|
-
...CustomFieldTranslationWithoutEnglish
|
|
42
|
+
...Array<CustomFieldTranslationWithoutEnglish>
|
|
43
43
|
];
|
|
44
44
|
export interface AbstractCustomFieldDefinition {
|
|
45
45
|
/**
|
|
@@ -101,7 +101,7 @@ export interface DateFieldDefinition extends AbstractCustomFieldDefinition {
|
|
|
101
101
|
export interface DropDownFieldDefinition extends AbstractCustomFieldDefinition {
|
|
102
102
|
type: "DROPDOWN";
|
|
103
103
|
multiSelect?: boolean;
|
|
104
|
-
allValues?: string
|
|
104
|
+
allValues?: Array<string>;
|
|
105
105
|
/**
|
|
106
106
|
* Map from old values not in the allValues to new values. Used for updating existing data when changing
|
|
107
107
|
* the drop down options.
|
|
@@ -249,7 +249,7 @@ export interface IntegerNumberFieldDefinition extends AbstractCustomFieldDefinit
|
|
|
249
249
|
}
|
|
250
250
|
export type JSONValue = string | number | boolean | null | {
|
|
251
251
|
[x: string]: JSONValue;
|
|
252
|
-
} | JSONValue
|
|
252
|
+
} | Array<JSONValue>;
|
|
253
253
|
export interface JsonFieldDefinition extends AbstractCustomFieldDefinition {
|
|
254
254
|
type: "JSON";
|
|
255
255
|
}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"irisAppCustomFields.js","sourceRoot":"","sources":["../../../../../../libs/iris-app-sdk/iris-app-api/src/types/irisAppCustomFields.ts"],"names":[],"mappings":"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","sourcesContent":["import { TranslationKey, TranslationLanguageKeys } from \"./irisAppExtensionManifest\";\n\nexport declare type CustomFieldDefinitionType =\n | \"STRING\"\n | \"NUMBER\"\n | \"DATE\"\n | \"BOOLEAN\"\n | \"DROPDOWN\"\n | \"EMAIL\"\n | \"PHONE_NUMBER\"\n | \"WEB_ADDRESS\"\n | \"JSON\"\n | \"MONETARY\";\n\nexport declare type EntityType = \"ASSET\" | \"ACCOUNT\" | \"SITE\" | \"GROUP\";\n\nexport const ScopeType = {\n /**\n * Values with account scope will be shared within a single account\n */\n ACCOUNT: \"ACCOUNT\",\n /**\n * Values will be shared within a single account (write) and visible to all accounts (read)\n */\n ACCOUNT_WRITE_GLOBAL_READ: \"ACCOUNT_WRITE_GLOBAL_READ\",\n /**\n * Values with global scope will be shared between all accounts with access to the entity.\n */\n GLOBAL: \"GLOBAL\",\n} as const;\nexport type ScopeTypeType = (typeof ScopeType)[keyof typeof ScopeType];\n\n/**\n * Test if the object is a CustomFieldTranslation array.\n */\nexport const isCustomFieldTranslationArray = (\n object: CustomFieldTranslationArray | { title: TranslationKey; description?: TranslationKey }\n): object is CustomFieldTranslationArray => {\n return Array.isArray(object);\n};\n\nexport interface CustomFieldTranslation {\n language: TranslationLanguageKeys;\n title: string;\n description?: string;\n}\n\nexport interface CustomFieldTranslationWithoutEnglish {\n language: Exclude<TranslationLanguageKeys, \"en\">;\n title: string;\n description?: string;\n}\n\nexport type CustomFieldTranslationArray = [\n { language: \"en\"; title: string; description?: string },\n ...CustomFieldTranslationWithoutEnglish[],\n];\n\nexport interface AbstractCustomFieldDefinition {\n /**\n * The key is the name you use to get the custom field.\n */\n key: string;\n\n /**\n * The type of the entity to attach this custom field on.\n */\n entityType: EntityType;\n\n /**\n * Who can access the field value. Default is only within the users account.\n */\n scopeType?: ScopeTypeType;\n\n /**\n * The translations for the custom field definition.\n * For Arrays of translations, the list must contain the language \"en\" as the default.\n * Either a list of translations or a single translation object with\n * translation keys it will look for all available languages in src/locales/<languagecode>/translation.json\n */\n translations: CustomFieldTranslationArray | { title: TranslationKey; description?: TranslationKey };\n\n /**\n * Should this be visible in the generic UI in Manager.\n */\n uiVisible?: boolean;\n\n /**\n * Should this be editable in the generic UI in Manager. This does not mean you cannot change it inside a app.\n */\n uiEditable?: boolean;\n\n /**\n * The type of this custom field definition\n */\n type: CustomFieldDefinitionType;\n}\n\nexport interface StringFieldDefinition extends AbstractCustomFieldDefinition {\n type: \"STRING\";\n minimumLength?: number;\n maximumLength?: number;\n pattern?: string;\n}\n\nexport interface EmailFieldDefinition extends AbstractCustomFieldDefinition {\n type: \"EMAIL\";\n}\n\nexport interface WebAddressFieldDefinition extends AbstractCustomFieldDefinition {\n type: \"WEB_ADDRESS\";\n}\n\nexport interface PhoneNumberFieldDefinition extends AbstractCustomFieldDefinition {\n type: \"PHONE_NUMBER\";\n}\nexport interface BooleanFieldDefinition extends AbstractCustomFieldDefinition {\n type: \"BOOLEAN\";\n}\n\nexport interface DateFieldDefinition extends AbstractCustomFieldDefinition {\n type: \"DATE\";\n}\n\nexport interface DropDownFieldDefinition extends AbstractCustomFieldDefinition {\n type: \"DROPDOWN\";\n multiSelect?: boolean;\n allValues?: string[];\n /**\n * Map from old values not in the allValues to new values. Used for updating existing data when changing\n * the drop down options.\n */\n valueReplacements?: Record<string, string>;\n}\n\nexport const UnitOfMeasurement = {\n NEWTON: \"NEWTON\",\n PASCAL: \"PASCAL\",\n KILOPASCAL: \"KILOPASCAL\",\n WATT: \"WATT\",\n BAR: \"BAR\",\n CENTIMETRE: \"CENTIMETRE\",\n MILLIMETRE: \"MILLIMETRE\",\n METRE: \"METRE\",\n KILOMETRE: \"KILOMETRE\",\n GRAM: \"GRAM\",\n KILOGRAM: \"KILOGRAM\",\n VOLT: \"VOLT\",\n AMPERE_HOUR: \"AMPERE_HOUR\",\n KILOWATT: \"KILOWATT\",\n KILOWATT_HOUR: \"KILOWATT_HOUR\",\n KILOGRAM_PER_HOUR: \"KILOGRAM_PER_HOUR\",\n KILOGRAM_PER_SECOND: \"KILOGRAM_PER_SECOND\",\n SQUARE_KILOMETRE: \"SQUARE_KILOMETRE\",\n KILOMETRE_PER_HOUR: \"KILOMETRE_PER_HOUR\",\n LITRE: \"LITRE\",\n SQUARE_METRE: \"SQUARE_METRE\",\n CUBIC_METRE: \"CUBIC_METRE\",\n METRE_PER_SECOND: \"METRE_PER_SECOND\",\n METRE_PER_SECOND_SQUARED: \"METRE_PER_SECOND_SQUARED\",\n METRIC_TON: \"METRIC_TON\",\n ARE: \"ARE\",\n HECTARE: \"HECTARE\",\n YEAR: \"YEAR\",\n MONTH: \"MONTH\",\n DAY: \"DAY\",\n HOUR: \"HOUR\",\n LITRES_PER_HOUR: \"LITRES_PER_HOUR\",\n REVOLUTIONS_PER_MINUTE: \"REVOLUTIONS_PER_MINUTE\",\n VOLT_AMPERE: \"VOLT_AMPERE\",\n G_FORCE: \"G_FORCE\",\n CELSIUS: \"CELSIUS\",\n PERCENT: \"PERCENT\",\n DEGREE_ANGLE: \"DEGREE_ANGLE\",\n MILLISECOND: \"MILLISECOND\",\n SECOND: \"SECOND\",\n MINUTE: \"MINUTE\",\n WEEK: \"WEEK\",\n AMPERE: \"AMPERE\",\n HERTZ: \"HERTZ\",\n ACRE: \"ACRE\",\n FOOT: \"FOOT\",\n SQUARE_FOOT: \"SQUARE_FOOT\",\n CUBIC_FOOT: \"CUBIC_FOOT\",\n GALLON_LIQUID: \"GALLON_LIQUID\",\n INCH: \"INCH\",\n POUND: \"POUND\",\n POUND_PER_HOUR: \"POUND_PER_HOUR\",\n POUND_PER_SECOND: \"POUND_PER_SECOND\",\n MILE: \"MILE\",\n MILE_PER_HOUR: \"MILE_PER_HOUR\",\n OUNCE: \"OUNCE\",\n US_TON: \"US_TON\",\n YARD: \"YARD\",\n POUND_PER_SQUARE_INCH: \"POUND_PER_SQUARE_INCH\",\n INCHES_OF_WATER: \"INCHES_OF_WATER\",\n GALLONS_PER_HOUR: \"GALLONS_PER_HOUR\",\n FAHRENHEIT: \"FAHRENHEIT\",\n} as const;\nexport type UnitOfMeasurementType = (typeof UnitOfMeasurement)[keyof typeof UnitOfMeasurement];\n\n/**\n * @deprecated Use UnitOfMeasurement instead\n */\nexport const UnitUs = {\n acre: \"ACRE\",\n foot: \"FOOT\",\n square_foot: \"SQUARE_FOOT\",\n cubic_foot: \"CUBIC_FOOT\",\n gallon_liquid: \"GALLON_LIQUID\",\n inch: \"INCH\",\n pound: \"POUND\",\n pound_per_hour: \"POUND_PER_HOUR\",\n pound_per_second: \"POUND_PER_SECOND\",\n mile: \"MILE\",\n mile_per_hour: \"MILE_PER_HOUR\",\n ounce: \"OUNCE\",\n ton_us: \"US_TON\",\n yard: \"YARD\",\n pound_per_square_inch: \"POUND_PER_SQUARE_INCH\",\n} as const;\n/**\n * @deprecated Use UnitOfMeasurementType instead\n */\nexport type UnitUsType = (typeof UnitUs)[keyof typeof UnitUs];\n\n/**\n * @deprecated Use UnitOfMeasurement instead\n */\nexport const UnitSi = {\n newton: \"NEWTON\",\n pascal: \"PASCAL\",\n kilopascal: \"KILOPASCAL\",\n amperehour: \"AMPERE_HOUR\",\n volt: \"VOLT\",\n watt: \"WATT\",\n bar: \"BAR\",\n centimetre: \"CENTIMETRE\",\n millimetre: \"MILLIMETRE\",\n metre: \"METRE\",\n kilometre: \"KILOMETRE\",\n gram: \"GRAM\",\n kilogram: \"KILOGRAM\",\n kilowatt: \"KILOWATT\",\n kilowatthour: \"KILOWATT_HOUR\",\n kilogram_per_hour: \"KILOGRAM_PER_HOUR\",\n kilogram_per_second: \"KILOGRAM_PER_SECOND\",\n square_kilometre: \"SQUARE_KILOMETRE\",\n kilometre_per_hour: \"KILOMETRE_PER_HOUR\",\n litre: \"LITRE\",\n square_metre: \"SQUARE_METRE\",\n cubic_metre: \"CUBIC_METRE\",\n metre_per_second: \"METRE_PER_SECOND\",\n metre_per_second_squared: \"METRE_PER_SECOND_SQUARED\",\n ton: \"TON\",\n hectare: \"HECTARE\",\n hour: \"HOUR\",\n} as const;\n/**\n * @deprecated Use UnitOfMeasurementType instead\n */\nexport type UnitSiType = (typeof UnitSi)[keyof typeof UnitSi];\n\nexport interface DecimalNumberFieldDefinition extends AbstractCustomFieldDefinition {\n type: \"NUMBER\";\n\n minimum?: number;\n maximum?: number;\n\n unitSi?: UnitOfMeasurementType;\n unitUs?: UnitOfMeasurementType;\n\n isInteger: false;\n}\n\nexport interface IntegerNumberFieldDefinition extends AbstractCustomFieldDefinition {\n type: \"NUMBER\";\n\n minimum?: number;\n maximum?: number;\n\n isInteger: true;\n}\n\nexport type JSONValue = string | number | boolean | null | { [x: string]: JSONValue } | JSONValue[];\n\nexport interface JsonFieldDefinition extends AbstractCustomFieldDefinition {\n type: \"JSON\";\n}\n\nexport interface MonetaryFieldDefinition extends AbstractCustomFieldDefinition {\n type: \"MONETARY\";\n /**\n * The currency of the monetary field definition - ISO 4217 compliant.\n */\n currency: string;\n}\n"]}
|
|
1
|
+
{"version":3,"file":"irisAppCustomFields.js","sourceRoot":"","sources":["../../../../../../libs/iris-app-sdk/iris-app-api/src/types/irisAppCustomFields.ts"],"names":[],"mappings":"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","sourcesContent":["import { TranslationKey, TranslationLanguageKeys } from \"./irisAppExtensionManifest\";\n\nexport declare type CustomFieldDefinitionType =\n | \"STRING\"\n | \"NUMBER\"\n | \"DATE\"\n | \"BOOLEAN\"\n | \"DROPDOWN\"\n | \"EMAIL\"\n | \"PHONE_NUMBER\"\n | \"WEB_ADDRESS\"\n | \"JSON\"\n | \"MONETARY\";\n\nexport declare type EntityType = \"ASSET\" | \"ACCOUNT\" | \"SITE\" | \"GROUP\";\n\nexport const ScopeType = {\n /**\n * Values with account scope will be shared within a single account\n */\n ACCOUNT: \"ACCOUNT\",\n /**\n * Values will be shared within a single account (write) and visible to all accounts (read)\n */\n ACCOUNT_WRITE_GLOBAL_READ: \"ACCOUNT_WRITE_GLOBAL_READ\",\n /**\n * Values with global scope will be shared between all accounts with access to the entity.\n */\n GLOBAL: \"GLOBAL\",\n} as const;\nexport type ScopeTypeType = (typeof ScopeType)[keyof typeof ScopeType];\n\n/**\n * Test if the object is a CustomFieldTranslation array.\n */\nexport const isCustomFieldTranslationArray = (\n object: CustomFieldTranslationArray | { title: TranslationKey; description?: TranslationKey }\n): object is CustomFieldTranslationArray => {\n return Array.isArray(object);\n};\n\nexport interface CustomFieldTranslation {\n language: TranslationLanguageKeys;\n title: string;\n description?: string;\n}\n\nexport interface CustomFieldTranslationWithoutEnglish {\n language: Exclude<TranslationLanguageKeys, \"en\">;\n title: string;\n description?: string;\n}\n\nexport type CustomFieldTranslationArray = [\n { language: \"en\"; title: string; description?: string },\n ...Array<CustomFieldTranslationWithoutEnglish>,\n];\n\nexport interface AbstractCustomFieldDefinition {\n /**\n * The key is the name you use to get the custom field.\n */\n key: string;\n\n /**\n * The type of the entity to attach this custom field on.\n */\n entityType: EntityType;\n\n /**\n * Who can access the field value. Default is only within the users account.\n */\n scopeType?: ScopeTypeType;\n\n /**\n * The translations for the custom field definition.\n * For Arrays of translations, the list must contain the language \"en\" as the default.\n * Either a list of translations or a single translation object with\n * translation keys it will look for all available languages in src/locales/<languagecode>/translation.json\n */\n translations: CustomFieldTranslationArray | { title: TranslationKey; description?: TranslationKey };\n\n /**\n * Should this be visible in the generic UI in Manager.\n */\n uiVisible?: boolean;\n\n /**\n * Should this be editable in the generic UI in Manager. This does not mean you cannot change it inside a app.\n */\n uiEditable?: boolean;\n\n /**\n * The type of this custom field definition\n */\n type: CustomFieldDefinitionType;\n}\n\nexport interface StringFieldDefinition extends AbstractCustomFieldDefinition {\n type: \"STRING\";\n minimumLength?: number;\n maximumLength?: number;\n pattern?: string;\n}\n\nexport interface EmailFieldDefinition extends AbstractCustomFieldDefinition {\n type: \"EMAIL\";\n}\n\nexport interface WebAddressFieldDefinition extends AbstractCustomFieldDefinition {\n type: \"WEB_ADDRESS\";\n}\n\nexport interface PhoneNumberFieldDefinition extends AbstractCustomFieldDefinition {\n type: \"PHONE_NUMBER\";\n}\nexport interface BooleanFieldDefinition extends AbstractCustomFieldDefinition {\n type: \"BOOLEAN\";\n}\n\nexport interface DateFieldDefinition extends AbstractCustomFieldDefinition {\n type: \"DATE\";\n}\n\nexport interface DropDownFieldDefinition extends AbstractCustomFieldDefinition {\n type: \"DROPDOWN\";\n multiSelect?: boolean;\n allValues?: Array<string>;\n /**\n * Map from old values not in the allValues to new values. Used for updating existing data when changing\n * the drop down options.\n */\n valueReplacements?: Record<string, string>;\n}\n\nexport const UnitOfMeasurement = {\n NEWTON: \"NEWTON\",\n PASCAL: \"PASCAL\",\n KILOPASCAL: \"KILOPASCAL\",\n WATT: \"WATT\",\n BAR: \"BAR\",\n CENTIMETRE: \"CENTIMETRE\",\n MILLIMETRE: \"MILLIMETRE\",\n METRE: \"METRE\",\n KILOMETRE: \"KILOMETRE\",\n GRAM: \"GRAM\",\n KILOGRAM: \"KILOGRAM\",\n VOLT: \"VOLT\",\n AMPERE_HOUR: \"AMPERE_HOUR\",\n KILOWATT: \"KILOWATT\",\n KILOWATT_HOUR: \"KILOWATT_HOUR\",\n KILOGRAM_PER_HOUR: \"KILOGRAM_PER_HOUR\",\n KILOGRAM_PER_SECOND: \"KILOGRAM_PER_SECOND\",\n SQUARE_KILOMETRE: \"SQUARE_KILOMETRE\",\n KILOMETRE_PER_HOUR: \"KILOMETRE_PER_HOUR\",\n LITRE: \"LITRE\",\n SQUARE_METRE: \"SQUARE_METRE\",\n CUBIC_METRE: \"CUBIC_METRE\",\n METRE_PER_SECOND: \"METRE_PER_SECOND\",\n METRE_PER_SECOND_SQUARED: \"METRE_PER_SECOND_SQUARED\",\n METRIC_TON: \"METRIC_TON\",\n ARE: \"ARE\",\n HECTARE: \"HECTARE\",\n YEAR: \"YEAR\",\n MONTH: \"MONTH\",\n DAY: \"DAY\",\n HOUR: \"HOUR\",\n LITRES_PER_HOUR: \"LITRES_PER_HOUR\",\n REVOLUTIONS_PER_MINUTE: \"REVOLUTIONS_PER_MINUTE\",\n VOLT_AMPERE: \"VOLT_AMPERE\",\n G_FORCE: \"G_FORCE\",\n CELSIUS: \"CELSIUS\",\n PERCENT: \"PERCENT\",\n DEGREE_ANGLE: \"DEGREE_ANGLE\",\n MILLISECOND: \"MILLISECOND\",\n SECOND: \"SECOND\",\n MINUTE: \"MINUTE\",\n WEEK: \"WEEK\",\n AMPERE: \"AMPERE\",\n HERTZ: \"HERTZ\",\n ACRE: \"ACRE\",\n FOOT: \"FOOT\",\n SQUARE_FOOT: \"SQUARE_FOOT\",\n CUBIC_FOOT: \"CUBIC_FOOT\",\n GALLON_LIQUID: \"GALLON_LIQUID\",\n INCH: \"INCH\",\n POUND: \"POUND\",\n POUND_PER_HOUR: \"POUND_PER_HOUR\",\n POUND_PER_SECOND: \"POUND_PER_SECOND\",\n MILE: \"MILE\",\n MILE_PER_HOUR: \"MILE_PER_HOUR\",\n OUNCE: \"OUNCE\",\n US_TON: \"US_TON\",\n YARD: \"YARD\",\n POUND_PER_SQUARE_INCH: \"POUND_PER_SQUARE_INCH\",\n INCHES_OF_WATER: \"INCHES_OF_WATER\",\n GALLONS_PER_HOUR: \"GALLONS_PER_HOUR\",\n FAHRENHEIT: \"FAHRENHEIT\",\n} as const;\nexport type UnitOfMeasurementType = (typeof UnitOfMeasurement)[keyof typeof UnitOfMeasurement];\n\n/**\n * @deprecated Use UnitOfMeasurement instead\n */\nexport const UnitUs = {\n acre: \"ACRE\",\n foot: \"FOOT\",\n square_foot: \"SQUARE_FOOT\",\n cubic_foot: \"CUBIC_FOOT\",\n gallon_liquid: \"GALLON_LIQUID\",\n inch: \"INCH\",\n pound: \"POUND\",\n pound_per_hour: \"POUND_PER_HOUR\",\n pound_per_second: \"POUND_PER_SECOND\",\n mile: \"MILE\",\n mile_per_hour: \"MILE_PER_HOUR\",\n ounce: \"OUNCE\",\n ton_us: \"US_TON\",\n yard: \"YARD\",\n pound_per_square_inch: \"POUND_PER_SQUARE_INCH\",\n} as const;\n/**\n * @deprecated Use UnitOfMeasurementType instead\n */\nexport type UnitUsType = (typeof UnitUs)[keyof typeof UnitUs];\n\n/**\n * @deprecated Use UnitOfMeasurement instead\n */\nexport const UnitSi = {\n newton: \"NEWTON\",\n pascal: \"PASCAL\",\n kilopascal: \"KILOPASCAL\",\n amperehour: \"AMPERE_HOUR\",\n volt: \"VOLT\",\n watt: \"WATT\",\n bar: \"BAR\",\n centimetre: \"CENTIMETRE\",\n millimetre: \"MILLIMETRE\",\n metre: \"METRE\",\n kilometre: \"KILOMETRE\",\n gram: \"GRAM\",\n kilogram: \"KILOGRAM\",\n kilowatt: \"KILOWATT\",\n kilowatthour: \"KILOWATT_HOUR\",\n kilogram_per_hour: \"KILOGRAM_PER_HOUR\",\n kilogram_per_second: \"KILOGRAM_PER_SECOND\",\n square_kilometre: \"SQUARE_KILOMETRE\",\n kilometre_per_hour: \"KILOMETRE_PER_HOUR\",\n litre: \"LITRE\",\n square_metre: \"SQUARE_METRE\",\n cubic_metre: \"CUBIC_METRE\",\n metre_per_second: \"METRE_PER_SECOND\",\n metre_per_second_squared: \"METRE_PER_SECOND_SQUARED\",\n ton: \"TON\",\n hectare: \"HECTARE\",\n hour: \"HOUR\",\n} as const;\n/**\n * @deprecated Use UnitOfMeasurementType instead\n */\nexport type UnitSiType = (typeof UnitSi)[keyof typeof UnitSi];\n\nexport interface DecimalNumberFieldDefinition extends AbstractCustomFieldDefinition {\n type: \"NUMBER\";\n\n minimum?: number;\n maximum?: number;\n\n unitSi?: UnitOfMeasurementType;\n unitUs?: UnitOfMeasurementType;\n\n isInteger: false;\n}\n\nexport interface IntegerNumberFieldDefinition extends AbstractCustomFieldDefinition {\n type: \"NUMBER\";\n\n minimum?: number;\n maximum?: number;\n\n isInteger: true;\n}\n\nexport type JSONValue = string | number | boolean | null | { [x: string]: JSONValue } | Array<JSONValue>;\n\nexport interface JsonFieldDefinition extends AbstractCustomFieldDefinition {\n type: \"JSON\";\n}\n\nexport interface MonetaryFieldDefinition extends AbstractCustomFieldDefinition {\n type: \"MONETARY\";\n /**\n * The currency of the monetary field definition - ISO 4217 compliant.\n */\n currency: string;\n}\n"]}
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
export declare const irisAppExtensionTypes: readonly ["REPORT_EXTENSION", "IRIS_APP_SETTINGS_EXTENSION", "ADMIN_EXTENSION", "FLEET_EXTENSION", "WIDGET_EXTENSION", "ASSET_HOME_EXTENSION", "ASSET_EVENTS_ACTIONS_EXTENSION", "CUSTOMER_HOME_EXTENSION", "SITE_HOME_EXTENSION", "LIFECYCLE_EXTENSION", "SERVERLESS_FUNCTION_EXTENSION", "AI_AGENT_EXTENSION"];
|
|
2
2
|
export type IrisAppExtensionType = (typeof irisAppExtensionTypes)[number];
|
|
3
|
-
export declare const nonUiExtensionTypes: IrisAppExtensionType
|
|
4
|
-
export declare const serverSideExtensionTypes: IrisAppExtensionType
|
|
3
|
+
export declare const nonUiExtensionTypes: Array<IrisAppExtensionType>;
|
|
4
|
+
export declare const serverSideExtensionTypes: Array<IrisAppExtensionType>;
|
|
5
5
|
export type RegExpType = {
|
|
6
6
|
pattern: string | RegExp;
|
|
7
7
|
};
|
|
@@ -16,7 +16,7 @@ export interface RequiredCustomField {
|
|
|
16
16
|
/**
|
|
17
17
|
* The requiredValue that is required for the app extension to be visible.
|
|
18
18
|
*/
|
|
19
|
-
requiredValue: string | string
|
|
19
|
+
requiredValue: string | Array<string> | boolean;
|
|
20
20
|
}
|
|
21
21
|
export interface AbstractExtensionManifest {
|
|
22
22
|
/** The id of the app extension, will be part of the URL in the manager */
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"irisAppExtensionManifest.js","sourceRoot":"","sources":["../../../../../../libs/iris-app-sdk/iris-app-api/src/types/irisAppExtensionManifest.ts"],"names":[],"mappings":";;;AAAa,QAAA,qBAAqB,GAAG;IACnC,kBAAkB;IAClB,6BAA6B;IAC7B,iBAAiB;IACjB,iBAAiB;IACjB,kBAAkB;IAClB,sBAAsB;IACtB,gCAAgC;IAChC,yBAAyB;IACzB,qBAAqB;IACrB,qBAAqB;IACrB,+BAA+B;IAC/B,oBAAoB;CACZ,CAAC;AAIE,QAAA,mBAAmB,
|
|
1
|
+
{"version":3,"file":"irisAppExtensionManifest.js","sourceRoot":"","sources":["../../../../../../libs/iris-app-sdk/iris-app-api/src/types/irisAppExtensionManifest.ts"],"names":[],"mappings":";;;AAAa,QAAA,qBAAqB,GAAG;IACnC,kBAAkB;IAClB,6BAA6B;IAC7B,iBAAiB;IACjB,iBAAiB;IACjB,kBAAkB;IAClB,sBAAsB;IACtB,gCAAgC;IAChC,yBAAyB;IACzB,qBAAqB;IACrB,qBAAqB;IACrB,+BAA+B;IAC/B,oBAAoB;CACZ,CAAC;AAIE,QAAA,mBAAmB,GAAgC;IAC9D,kBAAkB;IAClB,qBAAqB;IACrB,+BAA+B;IAC/B,oBAAoB;CACrB,CAAC;AAEW,QAAA,wBAAwB,GAAgC;IACnE,qBAAqB;IACrB,+BAA+B;IAC/B,oBAAoB;CACrB,CAAC;AA8DW,QAAA,YAAY,GAAG;IAC1B,IAAI;IACJ,IAAI;IACJ,IAAI;IACJ,IAAI;IACJ,IAAI;IACJ,IAAI;IACJ,IAAI;IACJ,IAAI;IACJ,IAAI;IACJ,IAAI;IACJ,IAAI;IACJ,IAAI;IACJ,IAAI;IACJ,IAAI;IACJ,IAAI;IACJ,IAAI;IACJ,IAAI;IACJ,IAAI;CACI,CAAC","sourcesContent":["export const irisAppExtensionTypes = [\n \"REPORT_EXTENSION\",\n \"IRIS_APP_SETTINGS_EXTENSION\",\n \"ADMIN_EXTENSION\",\n \"FLEET_EXTENSION\",\n \"WIDGET_EXTENSION\",\n \"ASSET_HOME_EXTENSION\",\n \"ASSET_EVENTS_ACTIONS_EXTENSION\",\n \"CUSTOMER_HOME_EXTENSION\",\n \"SITE_HOME_EXTENSION\",\n \"LIFECYCLE_EXTENSION\",\n \"SERVERLESS_FUNCTION_EXTENSION\",\n \"AI_AGENT_EXTENSION\",\n] as const;\n\nexport type IrisAppExtensionType = (typeof irisAppExtensionTypes)[number];\n\nexport const nonUiExtensionTypes: Array<IrisAppExtensionType> = [\n \"REPORT_EXTENSION\",\n \"LIFECYCLE_EXTENSION\",\n \"SERVERLESS_FUNCTION_EXTENSION\",\n \"AI_AGENT_EXTENSION\",\n];\n\nexport const serverSideExtensionTypes: Array<IrisAppExtensionType> = [\n \"LIFECYCLE_EXTENSION\",\n \"SERVERLESS_FUNCTION_EXTENSION\",\n \"AI_AGENT_EXTENSION\",\n];\n\nexport type RegExpType = {\n pattern: string | RegExp;\n};\n\n/**\n * Used to limit access to iris apps based on custom field value.\n */\nexport interface RequiredCustomField {\n /**\n * The custom field key to check for, only dropdown, string or boolean is supported.\n */\n customFieldKey: string;\n\n /**\n * The requiredValue that is required for the app extension to be visible.\n */\n requiredValue: string | Array<string> | boolean;\n}\n\nexport interface AbstractExtensionManifest {\n /** The id of the app extension, will be part of the URL in the manager */\n id: string;\n\n /**\n * The path to the main entry point for the extension.\n *\n * @default \"index.tsx\"\n */\n main?: string;\n\n /**\n * The relative path from the NX workspace to this projects source Root.\n */\n sourceRoot: string;\n\n /** The type of the app extension */\n type: IrisAppExtensionType;\n}\n\nexport interface Translations {\n en: string;\n da?: string;\n de?: string;\n cs?: string;\n nl?: string;\n fr?: string;\n fi?: string;\n hu?: string;\n it?: string;\n nb?: string;\n pl?: string;\n pt?: string;\n ru?: string;\n ro?: string;\n es?: string;\n sv?: string;\n ja?: string;\n th?: string;\n}\n\nexport const languageKeys = [\n \"en\",\n \"da\",\n \"de\",\n \"cs\",\n \"nl\",\n \"fr\",\n \"fi\",\n \"hu\",\n \"it\",\n \"nb\",\n \"pl\",\n \"pt\",\n \"ru\",\n \"ro\",\n \"es\",\n \"sv\",\n \"ja\",\n \"th\",\n] as const;\n\nexport type TranslationLanguageKeys = (typeof languageKeys)[number];\n\nexport interface TranslationKey {\n key: string;\n}\n"]}
|
|
@@ -28,13 +28,13 @@ export interface InstallationConfigLegacy {
|
|
|
28
28
|
/**
|
|
29
29
|
* List of account IDs that can install this Iris App or `"ALL_ACCOUNTS"` if available for all customers.
|
|
30
30
|
*/
|
|
31
|
-
accountIds: "ALL_ACCOUNTS" | string
|
|
31
|
+
accountIds: "ALL_ACCOUNTS" | Array<string>;
|
|
32
32
|
/**
|
|
33
33
|
* List of pricing plans the Iris App is available at or `"ALL_PLANS"` if available in all plans.
|
|
34
34
|
*
|
|
35
35
|
* @deprecated Use `pricingPlanPolicy` instead.
|
|
36
36
|
*/
|
|
37
|
-
pricingPlans: "ALL_PLANS" | SubscriptionPackage
|
|
37
|
+
pricingPlans: "ALL_PLANS" | Array<SubscriptionPackage>;
|
|
38
38
|
/**
|
|
39
39
|
* Ensure that both cannot be set at the same time.
|
|
40
40
|
*/
|
|
@@ -66,13 +66,13 @@ interface InstallationConfigBase {
|
|
|
66
66
|
* This field is optional and can be used to specify the identifiers of other Iris apps that are included within this bundle.
|
|
67
67
|
* It helps in managing and organizing multiple apps that are packaged together.
|
|
68
68
|
*/
|
|
69
|
-
irisAppsInsideBundle?: string
|
|
69
|
+
irisAppsInsideBundle?: Array<string>;
|
|
70
70
|
}
|
|
71
71
|
export interface InstallationConfig extends InstallationConfigBase {
|
|
72
72
|
/**
|
|
73
73
|
* List of account IDs that can install this Iris App or `"ALL_ACCOUNTS"` if available for all customers.
|
|
74
74
|
*/
|
|
75
|
-
accountIds: "ALL_ACCOUNTS" | [string, ...string
|
|
75
|
+
accountIds: "ALL_ACCOUNTS" | [string, ...Array<string>];
|
|
76
76
|
}
|
|
77
77
|
export interface InstallationConfigExcludeAccountIds extends InstallationConfigBase {
|
|
78
78
|
/**
|
|
@@ -82,6 +82,6 @@ export interface InstallationConfigExcludeAccountIds extends InstallationConfigB
|
|
|
82
82
|
/**
|
|
83
83
|
* List of account IDs that can't install this Iris App. Available if accountIds is set to `"ALL_ACCOUNTS"`.
|
|
84
84
|
*/
|
|
85
|
-
excludeAccountIds?: string
|
|
85
|
+
excludeAccountIds?: Array<string>;
|
|
86
86
|
}
|
|
87
87
|
export {};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"irisAppInstallationConfig.js","sourceRoot":"","sources":["../../../../../../libs/iris-app-sdk/iris-app-api/src/types/irisAppInstallationConfig.ts"],"names":[],"mappings":";;;AAEa,QAAA,kBAAkB,GAAG;IAChC,SAAS,EAAE,WAAW;IACtB,YAAY,EAAE,cAAc;IAC5B,SAAS,EAAE,WAAW;IACtB,2BAA2B,EAAE,6BAA6B;IAC1D,8BAA8B,EAAE,gCAAgC;CACxD,CAAC","sourcesContent":["import { SubscriptionPackage } from \"./subscriptionPackages\";\n\nexport const installationPolicy = {\n PERMANENT: \"PERMANENT\",\n PREINSTALLED: \"PREINSTALLED\",\n ON_DEMAND: \"ON_DEMAND\",\n ON_DEMAND_REQUIRES_APPROVAL: \"ON_DEMAND_REQUIRES_APPROVAL\",\n PREINSTALLED_REQUIRES_APPROVAL: \"PREINSTALLED_REQUIRES_APPROVAL\",\n} as const;\nexport type InstallationPolicy = (typeof installationPolicy)[keyof typeof installationPolicy];\n\n/**\n * @deprecated Use `InstallationConfig` instead.\n */\nexport interface InstallationConfigLegacy {\n /**\n * Installation policy for the app.\n *\n * - `PERMANENT`: Always installed and cannot be removed by the end customer.\n * - `PREINSTALLED`: Initially installed and can be removed by the end customer.\n * - `ON_DEMAND`: Available to be installed and removed by the end customer.\n * - `ON_DEMAND_REQUIRES_APPROVAL`: Requires approval by the Trackunit billing team before the end customer can install it. Behaves like 'ON_DEMAND' after receiving approval.\n * - `PREINSTALLED_REQUIRES_APPROVAL`: Requires approval by the Trackunit billing team and installs automatically once approved. Behaves like 'PREINSTALLED' after receiving approval.\n *\n * All policies will take into consideration both `accountIds` and `pricingPlans`.\n *\n * @deprecated Use `pricingPlanPolicy` instead.\n */\n policy: InstallationPolicy;\n /**\n * List of account IDs that can install this Iris App or `\"ALL_ACCOUNTS\"` if available for all customers.\n */\n accountIds: \"ALL_ACCOUNTS\" | string
|
|
1
|
+
{"version":3,"file":"irisAppInstallationConfig.js","sourceRoot":"","sources":["../../../../../../libs/iris-app-sdk/iris-app-api/src/types/irisAppInstallationConfig.ts"],"names":[],"mappings":";;;AAEa,QAAA,kBAAkB,GAAG;IAChC,SAAS,EAAE,WAAW;IACtB,YAAY,EAAE,cAAc;IAC5B,SAAS,EAAE,WAAW;IACtB,2BAA2B,EAAE,6BAA6B;IAC1D,8BAA8B,EAAE,gCAAgC;CACxD,CAAC","sourcesContent":["import { SubscriptionPackage } from \"./subscriptionPackages\";\n\nexport const installationPolicy = {\n PERMANENT: \"PERMANENT\",\n PREINSTALLED: \"PREINSTALLED\",\n ON_DEMAND: \"ON_DEMAND\",\n ON_DEMAND_REQUIRES_APPROVAL: \"ON_DEMAND_REQUIRES_APPROVAL\",\n PREINSTALLED_REQUIRES_APPROVAL: \"PREINSTALLED_REQUIRES_APPROVAL\",\n} as const;\nexport type InstallationPolicy = (typeof installationPolicy)[keyof typeof installationPolicy];\n\n/**\n * @deprecated Use `InstallationConfig` instead.\n */\nexport interface InstallationConfigLegacy {\n /**\n * Installation policy for the app.\n *\n * - `PERMANENT`: Always installed and cannot be removed by the end customer.\n * - `PREINSTALLED`: Initially installed and can be removed by the end customer.\n * - `ON_DEMAND`: Available to be installed and removed by the end customer.\n * - `ON_DEMAND_REQUIRES_APPROVAL`: Requires approval by the Trackunit billing team before the end customer can install it. Behaves like 'ON_DEMAND' after receiving approval.\n * - `PREINSTALLED_REQUIRES_APPROVAL`: Requires approval by the Trackunit billing team and installs automatically once approved. Behaves like 'PREINSTALLED' after receiving approval.\n *\n * All policies will take into consideration both `accountIds` and `pricingPlans`.\n *\n * @deprecated Use `pricingPlanPolicy` instead.\n */\n policy: InstallationPolicy;\n /**\n * List of account IDs that can install this Iris App or `\"ALL_ACCOUNTS\"` if available for all customers.\n */\n accountIds: \"ALL_ACCOUNTS\" | Array<string>;\n /**\n * List of pricing plans the Iris App is available at or `\"ALL_PLANS\"` if available in all plans.\n *\n * @deprecated Use `pricingPlanPolicy` instead.\n */\n pricingPlans: \"ALL_PLANS\" | Array<SubscriptionPackage>;\n /**\n * Ensure that both cannot be set at the same time.\n */\n pricingPlanPolicy?: never;\n}\n\ninterface InstallationConfigBase {\n /**\n * Installation policy for the app per pricing plan.\n *\n * - `PERMANENT`: Always installed and cannot be removed by the end customer.\n * - `PREINSTALLED`: Initially installed and can be removed by the end customer.\n * - `ON_DEMAND`: Available to be installed and removed by the end customer.\n * - `ON_DEMAND_REQUIRES_APPROVAL`: Requires approval by the Trackunit billing team before the end customer can install it. Behaves like 'ON_DEMAND' after receiving approval.\n * - `PREINSTALLED_REQUIRES_APPROVAL`: Requires approval by the Trackunit billing team and installs automatically once approved. Behaves like 'PREINSTALLED' after receiving approval.\n *\n * All policies will also filter by `accountIds` if specified.\n *\n * If a pricing plan is not specified it means it will not be available for that plan.\n *\n */\n pricingPlanPolicy:\n | ({ [key in SubscriptionPackage]?: InstallationPolicy } & { ALL_PLANS?: never })\n | { ALL_PLANS: InstallationPolicy };\n\n /**\n * This field is optional and can be used to specify the identifiers of other Iris apps that are included within this bundle.\n * It helps in managing and organizing multiple apps that are packaged together.\n */\n irisAppsInsideBundle?: Array<string>;\n}\n\nexport interface InstallationConfig extends InstallationConfigBase {\n /**\n * List of account IDs that can install this Iris App or `\"ALL_ACCOUNTS\"` if available for all customers.\n */\n accountIds: \"ALL_ACCOUNTS\" | [string, ...Array<string>];\n}\n\nexport interface InstallationConfigExcludeAccountIds extends InstallationConfigBase {\n /**\n * List of account IDs that can install this Iris App or `\"ALL_ACCOUNTS\"` if available for all customers.\n */\n accountIds: \"ALL_ACCOUNTS\";\n /**\n * List of account IDs that can't install this Iris App. Available if accountIds is set to `\"ALL_ACCOUNTS\"`.\n */\n excludeAccountIds?: Array<string>;\n}\n"]}
|
|
@@ -30,7 +30,7 @@ export interface IrisAppManifest extends Omit<IrisAppManifest_1_0, "specVersion"
|
|
|
30
30
|
/**
|
|
31
31
|
* Scopes needed in app tokens, these scopes are used from the token - when contacting Trackunits backend.
|
|
32
32
|
*/
|
|
33
|
-
scopes?: RequiredOrOptionalScope | RequiredOrOptionalScope
|
|
33
|
+
scopes?: RequiredOrOptionalScope | Array<RequiredOrOptionalScope>;
|
|
34
34
|
/**
|
|
35
35
|
* Configuration of callback to get credentials to call the API after app installation.
|
|
36
36
|
*/
|
|
@@ -84,11 +84,11 @@ export interface ConsentConfig {
|
|
|
84
84
|
/**
|
|
85
85
|
* List of scopes required by the application.
|
|
86
86
|
*/
|
|
87
|
-
scopes: string
|
|
87
|
+
scopes: Array<string>;
|
|
88
88
|
/**
|
|
89
89
|
* List of redirect URIs to be used when returning an authorization code.
|
|
90
90
|
*/
|
|
91
|
-
redirectUris?: string
|
|
91
|
+
redirectUris?: Array<string>;
|
|
92
92
|
}
|
|
93
93
|
export interface Dependencies {
|
|
94
94
|
[packageName: string]: string;
|
|
@@ -147,12 +147,12 @@ export interface IrisAppManifest_1_0 {
|
|
|
147
147
|
*
|
|
148
148
|
* @deprecated Use `cspHeader` instead
|
|
149
149
|
*/
|
|
150
|
-
validDomains?: string
|
|
150
|
+
validDomains?: Array<string>;
|
|
151
151
|
/**
|
|
152
152
|
* Put `ALL_ACCOUNTS` in if your app is available to all users.
|
|
153
153
|
* If you want to only make it available to certain users, provide a list of account ID's as strings.
|
|
154
154
|
*/
|
|
155
|
-
validForAccountIds: "ALL_ACCOUNTS" | string
|
|
155
|
+
validForAccountIds: "ALL_ACCOUNTS" | Array<string>;
|
|
156
156
|
/**
|
|
157
157
|
* A configuration object for the Marketplace entry.
|
|
158
158
|
* Holds all the settings associated with your apps listing on the marketplace.
|
|
@@ -175,11 +175,11 @@ export interface IrisAppManifest_1_0 {
|
|
|
175
175
|
* The array contains an import of the extension manifest within the extension.
|
|
176
176
|
* If an extension is required in multiple apps, the you must manually add it to the arrays of those apps.
|
|
177
177
|
*/
|
|
178
|
-
extensions: IrisAppExtension
|
|
178
|
+
extensions: Array<IrisAppExtension>;
|
|
179
179
|
/**
|
|
180
180
|
* A list of custom field definitions.
|
|
181
181
|
*/
|
|
182
|
-
customFieldDefinitions?: CustomFieldDefinition
|
|
182
|
+
customFieldDefinitions?: Array<CustomFieldDefinition>;
|
|
183
183
|
}
|
|
184
184
|
/**
|
|
185
185
|
* @deprecated
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"irisAppManifest.js","sourceRoot":"","sources":["../../../../../../libs/iris-app-sdk/iris-app-api/src/types/irisAppManifest.ts"],"names":[],"mappings":"","sourcesContent":["import { CSPDirectives } from \"./cspDirectives\";\nimport {\n AdminExtensionManifest,\n AssetEventsActionsExtensionManifest,\n AssetHomeExtensionManifest,\n FleetExtensionManifest,\n IrisAppSettingsExtensionManifest,\n ReportExtensionManifest,\n SiteHomeExtensionManifest,\n} from \"./extensions\";\nimport { AiAgentExtensionManifest } from \"./extensions/aiAgentExtensionManifest\";\nimport { CustomerHomeExtensionManifest } from \"./extensions/customerHomeExtensionManifest\";\nimport { LifecycleExtensionManifest } from \"./extensions/lifecycleExtensionManifest\";\nimport { ServerlessFunctionExtensionManifest } from \"./extensions/serverlessFunctionExtensionManifest\";\nimport { WidgetExtensionManifest } from \"./extensions/widgetExtensionManifest\";\nimport {\n BooleanFieldDefinition,\n DateFieldDefinition,\n DecimalNumberFieldDefinition,\n DropDownFieldDefinition,\n EmailFieldDefinition,\n IntegerNumberFieldDefinition,\n JsonFieldDefinition,\n MonetaryFieldDefinition,\n PhoneNumberFieldDefinition,\n StringFieldDefinition,\n WebAddressFieldDefinition,\n} from \"./irisAppCustomFields\";\nimport {\n InstallationConfig,\n InstallationConfigExcludeAccountIds,\n InstallationConfigLegacy,\n} from \"./irisAppInstallationConfig\";\nimport { Marketplace, Marketplace_1_0 } from \"./irisAppMarketplace\";\nimport { PermissionsPolicy } from \"./permissionsPolicy\";\nimport { Scope } from \"./scopes\";\n\nexport interface IrisAppManifest\n extends Omit<\n IrisAppManifest_1_0,\n \"specVersion\" | \"activationMode\" | \"marketplace\" | \"validForAccountIds\" | \"consentConfig\"\n > {\n /**\n * A spec version for the manifest.\n * This should not be changed manually.\n */\n specVersion: \"1.1\";\n\n /**\n * Configuration for the installation of the app.\n *\n * Each parameter can be combined to create rules to target specific customers.\n * Each parameter works as a filter to decide if an app is available to a specific customer.\n */\n installation: InstallationConfig | InstallationConfigExcludeAccountIds | InstallationConfigLegacy;\n\n /**\n * A configuration object for the Marketplace entry\n */\n marketplace: Marketplace;\n\n /**\n * Scopes needed in app tokens, these scopes are used from the token - when contacting Trackunits backend.\n */\n scopes?: RequiredOrOptionalScope | RequiredOrOptionalScope[];\n\n /**\n * Configuration of callback to get credentials to call the API after app installation.\n */\n tokenCallback?: {\n url: string;\n };\n\n /**\n * Configuration of the Content Security Policy (CSP) header for the app.\n *\n * We support a subset of the CSP directives. The supported directives are:\n * - [child-src](https://developer.mozilla.org/en-US/docs/Web/HTTP/Headers/Content-Security-Policy/child-src)\n * - [connect-src](https://developer.mozilla.org/en-US/docs/Web/HTTP/Headers/Content-Security-Policy/connect-src)\n * - [font-src](https://developer.mozilla.org/en-US/docs/Web/HTTP/Headers/Content-Security-Policy/font-src)\n * - [form-action](https://developer.mozilla.org/en-US/docs/Web/HTTP/Headers/Content-Security-Policy/form-action)\n * - [frame-src](https://developer.mozilla.org/en-US/docs/Web/HTTP/Headers/Content-Security-Policy/frame-src)\n * - [img-src](https://developer.mozilla.org/en-US/docs/Web/HTTP/Headers/Content-Security-Policy/img-src)\n * - [media-src](https://developer.mozilla.org/en-US/docs/Web/HTTP/Headers/Content-Security-Policy/media-src)\n * - [script-src](https://developer.mozilla.org/en-US/docs/Web/HTTP/Headers/Content-Security-Policy/script-src)\n * - [script-src-attr](https://developer.mozilla.org/en-US/docs/Web/HTTP/Headers/Content-Security-Policy/script-src-attr)\n * - [script-src-elem](https://developer.mozilla.org/en-US/docs/Web/HTTP/Headers/Content-Security-Policy/script-src-elem)\n * - [style-src](https://developer.mozilla.org/en-US/docs/Web/HTTP/Headers/Content-Security-Policy/style-src)\n * - [style-src-attr](https://developer.mozilla.org/en-US/docs/Web/HTTP/Headers/Content-Security-Policy/style-src-attr)\n * - [style-src-elem](https://developer.mozilla.org/en-US/docs/Web/HTTP/Headers/Content-Security-Policy/style-src-elem)\n * - [worker-src](https://developer.mozilla.org/en-US/docs/Web/HTTP/Headers/Content-Security-Policy/worker-src)\n * - [default-src](https://developer.mozilla.org/en-US/docs/Web/HTTP/Headers/Content-Security-Policy/default-src)\n *\n * More information about CSP can be found [here](https://developer.mozilla.org/en-US/docs/Web/HTTP/CSP).\n */\n cspHeader?: Partial<CSPDirectives>;\n\n /**\n * Configuration of the Permissions policy of the app\n *\n * More information about Permissions policies can be found [here](https://developer.mozilla.org/en-US/docs/Web/HTTP/Headers/Permissions-Policy).\n */\n permissionsPolicy?: PermissionsPolicy;\n}\n\nexport type RequiredOrOptionalScope = { scope: Scope; optional?: boolean };\n\nexport declare type IrisAppExtension =\n | AssetHomeExtensionManifest\n | IrisAppSettingsExtensionManifest\n | AdminExtensionManifest\n | FleetExtensionManifest\n | SiteHomeExtensionManifest\n | WidgetExtensionManifest\n | ReportExtensionManifest\n | CustomerHomeExtensionManifest\n | AssetEventsActionsExtensionManifest\n | LifecycleExtensionManifest\n | ServerlessFunctionExtensionManifest\n | AiAgentExtensionManifest;\n\nexport declare type CustomFieldDefinition =\n | BooleanFieldDefinition\n | DecimalNumberFieldDefinition\n | IntegerNumberFieldDefinition\n | DateFieldDefinition\n | DropDownFieldDefinition\n | StringFieldDefinition\n | EmailFieldDefinition\n | PhoneNumberFieldDefinition\n | WebAddressFieldDefinition\n | JsonFieldDefinition\n | MonetaryFieldDefinition;\n\n/**\n * @deprecated\n */\nexport interface ConsentConfig {\n /**\n * The application type. Should be one of WEB or BROWSER.\n */\n applicationType: \"WEB\" | \"BROWSER\";\n /**\n * List of scopes required by the application.\n */\n scopes: string[];\n /**\n * List of redirect URIs to be used when returning an authorization code.\n */\n redirectUris?: string[];\n}\n\nexport interface Dependencies {\n [packageName: string]: string;\n}\n\nexport type PublicIrisAppManifest = Omit<IrisAppManifest, \"dependencies\" | \"devDependencies\" | \"installation\"> & {\n /**\n * Relative path for this iris app.\n *\n * @returns {string} the path to the iris app\n */\n irisAppPath: string;\n\n installation: Omit<InstallationConfig, \"accountIds\"> | Omit<InstallationConfigLegacy, \"accountIds\">;\n};\n\n/**\n * @deprecated\n */\nexport interface IrisAppManifest_1_0 {\n /**\n * A spec version for the manifest.\n * This should not be changed manually.\n */\n specVersion: \"1.0\";\n /**\n * The name of the exposed module from module federation build into the remoteEntry.js.\n * Basically the name of your app including workspace name, automatically parsed from your app-specific package.json.\n */\n moduleFederationName: string;\n\n /**\n * A configuration object for handling scoped token acquisition.\n *\n * @deprecated Use `scopes` instead.\n */\n consentConfig?: ConsentConfig | \"inherit\";\n\n /**\n * Controls the visibility of your app and how it is installed.\n * The different modes are:\n * - Enabled means its enabled on the subscription when this Iris app is approved.\n * - Visible means it will be visible to the customer to choose for them selves to enable/disable it.\n *\n * - FORCE_ENABLE then it can not be removed by the end customer, and will be installed based on the selected subscription package.\n * - DEFAULT_ENABLE means it will be enabled when a customer activates a new subscription package.\n * - ALWAYS_VISIBLE then it will always be visible for all customers.\n * - CONTROLLED_MANUAL_INSTALLATION then it will be controlled by the team that activates the subscription package for the customer, not activating the app.\n * - CONTROLLED_AUTOMATIC_INSTALLATION then it will be controlled by the team that activates the subscription package for the customer, also adding.\n *\n * All modes will take into consideration both {@link IrisAppManifest_1_0.validForAccountIds} and {@link IrisAppManifest_1_0.marketplace}.allowForPackage\n *\n * @deprecated Use `installation.policy` instead.\n */\n activationMode: ActivationMode;\n\n /**\n * A list of any external domains that the app needs to communicate with.\n * The list is audited in the approval step of the app and every external API call\n * must be listed here to get through the verification process.\n * Even if it goes through without being listed, your app will fail to call the endpoint.\n *\n * @deprecated Use `cspHeader` instead\n */\n validDomains?: string[];\n /**\n * Put `ALL_ACCOUNTS` in if your app is available to all users.\n * If you want to only make it available to certain users, provide a list of account ID's as strings.\n */\n validForAccountIds: \"ALL_ACCOUNTS\" | string[];\n /**\n * A configuration object for the Marketplace entry.\n * Holds all the settings associated with your apps listing on the marketplace.\n */\n marketplace: Marketplace_1_0;\n /**\n * A full list of runtime dependencies for the App.\n * Used for performance optimization and security scans.\n * It is automatically parsed from the package.json in root.\n */\n dependencies: Dependencies;\n\n /**\n * A full list of dev dependencies for the App.\n * Used for security scans.\n */\n devDependencies: Dependencies;\n\n /**\n * A list of extensions to the UI that this app manifest exposes.\n * Extensions are automatically added when a new extension is generated.\n * The array contains an import of the extension manifest within the extension.\n * If an extension is required in multiple apps, the you must manually add it to the arrays of those apps.\n */\n extensions: IrisAppExtension[];\n\n /**\n * A list of custom field definitions.\n */\n customFieldDefinitions?: CustomFieldDefinition[];\n}\n\n/**\n * @deprecated\n */\nexport type ActivationMode =\n | \"FORCE_ENABLE\"\n | \"DEFAULT_ENABLE\"\n | \"ALWAYS_VISIBLE\"\n | \"CONTROLLED_MANUAL_INSTALLATION\"\n | \"CONTROLLED_AUTOMATIC_INSTALLATION\";\n"]}
|
|
1
|
+
{"version":3,"file":"irisAppManifest.js","sourceRoot":"","sources":["../../../../../../libs/iris-app-sdk/iris-app-api/src/types/irisAppManifest.ts"],"names":[],"mappings":"","sourcesContent":["import { CSPDirectives } from \"./cspDirectives\";\nimport {\n AdminExtensionManifest,\n AssetEventsActionsExtensionManifest,\n AssetHomeExtensionManifest,\n FleetExtensionManifest,\n IrisAppSettingsExtensionManifest,\n ReportExtensionManifest,\n SiteHomeExtensionManifest,\n} from \"./extensions\";\nimport { AiAgentExtensionManifest } from \"./extensions/aiAgentExtensionManifest\";\nimport { CustomerHomeExtensionManifest } from \"./extensions/customerHomeExtensionManifest\";\nimport { LifecycleExtensionManifest } from \"./extensions/lifecycleExtensionManifest\";\nimport { ServerlessFunctionExtensionManifest } from \"./extensions/serverlessFunctionExtensionManifest\";\nimport { WidgetExtensionManifest } from \"./extensions/widgetExtensionManifest\";\nimport {\n BooleanFieldDefinition,\n DateFieldDefinition,\n DecimalNumberFieldDefinition,\n DropDownFieldDefinition,\n EmailFieldDefinition,\n IntegerNumberFieldDefinition,\n JsonFieldDefinition,\n MonetaryFieldDefinition,\n PhoneNumberFieldDefinition,\n StringFieldDefinition,\n WebAddressFieldDefinition,\n} from \"./irisAppCustomFields\";\nimport {\n InstallationConfig,\n InstallationConfigExcludeAccountIds,\n InstallationConfigLegacy,\n} from \"./irisAppInstallationConfig\";\nimport { Marketplace, Marketplace_1_0 } from \"./irisAppMarketplace\";\nimport { PermissionsPolicy } from \"./permissionsPolicy\";\nimport { Scope } from \"./scopes\";\n\nexport interface IrisAppManifest\n extends Omit<\n IrisAppManifest_1_0,\n \"specVersion\" | \"activationMode\" | \"marketplace\" | \"validForAccountIds\" | \"consentConfig\"\n > {\n /**\n * A spec version for the manifest.\n * This should not be changed manually.\n */\n specVersion: \"1.1\";\n\n /**\n * Configuration for the installation of the app.\n *\n * Each parameter can be combined to create rules to target specific customers.\n * Each parameter works as a filter to decide if an app is available to a specific customer.\n */\n installation: InstallationConfig | InstallationConfigExcludeAccountIds | InstallationConfigLegacy;\n\n /**\n * A configuration object for the Marketplace entry\n */\n marketplace: Marketplace;\n\n /**\n * Scopes needed in app tokens, these scopes are used from the token - when contacting Trackunits backend.\n */\n scopes?: RequiredOrOptionalScope | Array<RequiredOrOptionalScope>;\n\n /**\n * Configuration of callback to get credentials to call the API after app installation.\n */\n tokenCallback?: {\n url: string;\n };\n\n /**\n * Configuration of the Content Security Policy (CSP) header for the app.\n *\n * We support a subset of the CSP directives. The supported directives are:\n * - [child-src](https://developer.mozilla.org/en-US/docs/Web/HTTP/Headers/Content-Security-Policy/child-src)\n * - [connect-src](https://developer.mozilla.org/en-US/docs/Web/HTTP/Headers/Content-Security-Policy/connect-src)\n * - [font-src](https://developer.mozilla.org/en-US/docs/Web/HTTP/Headers/Content-Security-Policy/font-src)\n * - [form-action](https://developer.mozilla.org/en-US/docs/Web/HTTP/Headers/Content-Security-Policy/form-action)\n * - [frame-src](https://developer.mozilla.org/en-US/docs/Web/HTTP/Headers/Content-Security-Policy/frame-src)\n * - [img-src](https://developer.mozilla.org/en-US/docs/Web/HTTP/Headers/Content-Security-Policy/img-src)\n * - [media-src](https://developer.mozilla.org/en-US/docs/Web/HTTP/Headers/Content-Security-Policy/media-src)\n * - [script-src](https://developer.mozilla.org/en-US/docs/Web/HTTP/Headers/Content-Security-Policy/script-src)\n * - [script-src-attr](https://developer.mozilla.org/en-US/docs/Web/HTTP/Headers/Content-Security-Policy/script-src-attr)\n * - [script-src-elem](https://developer.mozilla.org/en-US/docs/Web/HTTP/Headers/Content-Security-Policy/script-src-elem)\n * - [style-src](https://developer.mozilla.org/en-US/docs/Web/HTTP/Headers/Content-Security-Policy/style-src)\n * - [style-src-attr](https://developer.mozilla.org/en-US/docs/Web/HTTP/Headers/Content-Security-Policy/style-src-attr)\n * - [style-src-elem](https://developer.mozilla.org/en-US/docs/Web/HTTP/Headers/Content-Security-Policy/style-src-elem)\n * - [worker-src](https://developer.mozilla.org/en-US/docs/Web/HTTP/Headers/Content-Security-Policy/worker-src)\n * - [default-src](https://developer.mozilla.org/en-US/docs/Web/HTTP/Headers/Content-Security-Policy/default-src)\n *\n * More information about CSP can be found [here](https://developer.mozilla.org/en-US/docs/Web/HTTP/CSP).\n */\n cspHeader?: Partial<CSPDirectives>;\n\n /**\n * Configuration of the Permissions policy of the app\n *\n * More information about Permissions policies can be found [here](https://developer.mozilla.org/en-US/docs/Web/HTTP/Headers/Permissions-Policy).\n */\n permissionsPolicy?: PermissionsPolicy;\n}\n\nexport type RequiredOrOptionalScope = { scope: Scope; optional?: boolean };\n\nexport declare type IrisAppExtension =\n | AssetHomeExtensionManifest\n | IrisAppSettingsExtensionManifest\n | AdminExtensionManifest\n | FleetExtensionManifest\n | SiteHomeExtensionManifest\n | WidgetExtensionManifest\n | ReportExtensionManifest\n | CustomerHomeExtensionManifest\n | AssetEventsActionsExtensionManifest\n | LifecycleExtensionManifest\n | ServerlessFunctionExtensionManifest\n | AiAgentExtensionManifest;\n\nexport declare type CustomFieldDefinition =\n | BooleanFieldDefinition\n | DecimalNumberFieldDefinition\n | IntegerNumberFieldDefinition\n | DateFieldDefinition\n | DropDownFieldDefinition\n | StringFieldDefinition\n | EmailFieldDefinition\n | PhoneNumberFieldDefinition\n | WebAddressFieldDefinition\n | JsonFieldDefinition\n | MonetaryFieldDefinition;\n\n/**\n * @deprecated\n */\nexport interface ConsentConfig {\n /**\n * The application type. Should be one of WEB or BROWSER.\n */\n applicationType: \"WEB\" | \"BROWSER\";\n /**\n * List of scopes required by the application.\n */\n scopes: Array<string>;\n /**\n * List of redirect URIs to be used when returning an authorization code.\n */\n redirectUris?: Array<string>;\n}\n\nexport interface Dependencies {\n [packageName: string]: string;\n}\n\nexport type PublicIrisAppManifest = Omit<IrisAppManifest, \"dependencies\" | \"devDependencies\" | \"installation\"> & {\n /**\n * Relative path for this iris app.\n *\n * @returns {string} the path to the iris app\n */\n irisAppPath: string;\n\n installation: Omit<InstallationConfig, \"accountIds\"> | Omit<InstallationConfigLegacy, \"accountIds\">;\n};\n\n/**\n * @deprecated\n */\nexport interface IrisAppManifest_1_0 {\n /**\n * A spec version for the manifest.\n * This should not be changed manually.\n */\n specVersion: \"1.0\";\n /**\n * The name of the exposed module from module federation build into the remoteEntry.js.\n * Basically the name of your app including workspace name, automatically parsed from your app-specific package.json.\n */\n moduleFederationName: string;\n\n /**\n * A configuration object for handling scoped token acquisition.\n *\n * @deprecated Use `scopes` instead.\n */\n consentConfig?: ConsentConfig | \"inherit\";\n\n /**\n * Controls the visibility of your app and how it is installed.\n * The different modes are:\n * - Enabled means its enabled on the subscription when this Iris app is approved.\n * - Visible means it will be visible to the customer to choose for them selves to enable/disable it.\n *\n * - FORCE_ENABLE then it can not be removed by the end customer, and will be installed based on the selected subscription package.\n * - DEFAULT_ENABLE means it will be enabled when a customer activates a new subscription package.\n * - ALWAYS_VISIBLE then it will always be visible for all customers.\n * - CONTROLLED_MANUAL_INSTALLATION then it will be controlled by the team that activates the subscription package for the customer, not activating the app.\n * - CONTROLLED_AUTOMATIC_INSTALLATION then it will be controlled by the team that activates the subscription package for the customer, also adding.\n *\n * All modes will take into consideration both {@link IrisAppManifest_1_0.validForAccountIds} and {@link IrisAppManifest_1_0.marketplace}.allowForPackage\n *\n * @deprecated Use `installation.policy` instead.\n */\n activationMode: ActivationMode;\n\n /**\n * A list of any external domains that the app needs to communicate with.\n * The list is audited in the approval step of the app and every external API call\n * must be listed here to get through the verification process.\n * Even if it goes through without being listed, your app will fail to call the endpoint.\n *\n * @deprecated Use `cspHeader` instead\n */\n validDomains?: Array<string>;\n /**\n * Put `ALL_ACCOUNTS` in if your app is available to all users.\n * If you want to only make it available to certain users, provide a list of account ID's as strings.\n */\n validForAccountIds: \"ALL_ACCOUNTS\" | Array<string>;\n /**\n * A configuration object for the Marketplace entry.\n * Holds all the settings associated with your apps listing on the marketplace.\n */\n marketplace: Marketplace_1_0;\n /**\n * A full list of runtime dependencies for the App.\n * Used for performance optimization and security scans.\n * It is automatically parsed from the package.json in root.\n */\n dependencies: Dependencies;\n\n /**\n * A full list of dev dependencies for the App.\n * Used for security scans.\n */\n devDependencies: Dependencies;\n\n /**\n * A list of extensions to the UI that this app manifest exposes.\n * Extensions are automatically added when a new extension is generated.\n * The array contains an import of the extension manifest within the extension.\n * If an extension is required in multiple apps, the you must manually add it to the arrays of those apps.\n */\n extensions: Array<IrisAppExtension>;\n\n /**\n * A list of custom field definitions.\n */\n customFieldDefinitions?: Array<CustomFieldDefinition>;\n}\n\n/**\n * @deprecated\n */\nexport type ActivationMode =\n | \"FORCE_ENABLE\"\n | \"DEFAULT_ENABLE\"\n | \"ALWAYS_VISIBLE\"\n | \"CONTROLLED_MANUAL_INSTALLATION\"\n | \"CONTROLLED_AUTOMATIC_INSTALLATION\";\n"]}
|
|
@@ -70,21 +70,21 @@ export interface Marketplace_1_0 {
|
|
|
70
70
|
/**
|
|
71
71
|
* A list of relevant tags to make your app easier to find.
|
|
72
72
|
*/
|
|
73
|
-
tags?: string
|
|
73
|
+
tags?: Array<string>;
|
|
74
74
|
/**
|
|
75
75
|
* Categories used for the app in the marketplace.
|
|
76
76
|
*/
|
|
77
|
-
categories?: Category
|
|
77
|
+
categories?: Array<Category>;
|
|
78
78
|
/**
|
|
79
79
|
* Assets (images and videos) used for the marketplace.
|
|
80
80
|
*/
|
|
81
|
-
assets?: MarketplaceAsset
|
|
81
|
+
assets?: Array<MarketplaceAsset>;
|
|
82
82
|
/**
|
|
83
83
|
* Defines with which subscription packages your app is compatible.
|
|
84
84
|
* Take great care when entering this, as your app might bug out (if it went through the approval phase in the first place)
|
|
85
85
|
* if what is stated here does not match reality.
|
|
86
86
|
*/
|
|
87
|
-
allowForPackage: "ALL_PACKAGES" | SubscriptionPackage
|
|
87
|
+
allowForPackage: "ALL_PACKAGES" | Array<SubscriptionPackage>;
|
|
88
88
|
/**
|
|
89
89
|
* Homepage of the company building the app for the marketplace.
|
|
90
90
|
*/
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"irisAppMarketplace.js","sourceRoot":"","sources":["../../../../../../libs/iris-app-sdk/iris-app-api/src/types/irisAppMarketplace.ts"],"names":[],"mappings":";;;AAyGa,QAAA,cAAc,GAAG;IAC5B,kBAAkB;IAClB,YAAY;IACZ,aAAa;IACb,YAAY;IACZ,eAAe;IACf,sBAAsB;IACtB,sBAAsB;IACtB,uBAAuB;IACvB,mBAAmB;IACnB,mBAAmB;IACnB,yBAAyB;IACzB,gBAAgB;CACR,CAAC","sourcesContent":["import { SubscriptionPackage } from \"./subscriptionPackages\";\n\n/**\n * An image that should be shown in the marketplace for this app.\n */\nexport interface MarketplaceAssetImage {\n /**\n * The type of the Asset\n */\n type: \"IMAGE\";\n /**\n * A Path to an image in the assets folder of the app.\n * Example: typing \"MyImage.png\" here, will show the file \"apps/my-app/assets/MyImage.png\"\n */\n path: string;\n}\n\n/**\n * A video that should be shown in the marketplace for this app.\n */\nexport interface MarketplaceAssetVideo {\n /**\n * The type of the Asset\n */\n type: \"VIDEO\";\n /**\n * An url for a youtube video.\n */\n url: string;\n}\n\n/**\n * A video or image that should be shown in the marketplace for this app.\n */\nexport type MarketplaceAsset = MarketplaceAssetImage | MarketplaceAssetVideo;\n\n/**\n * An object of data used when the app is displayed in the marketplace\n */\nexport interface Marketplace extends Omit<Marketplace_1_0, \"allowForPackage\"> {\n /**\n * Indicate if the app should be shown in the Trackunit Marketplace.\n */\n showInMarketplace: boolean;\n}\n\n/**\n * An object of data used when the app is displayed in the marketplace\n *\n * @deprecated\n */\nexport interface Marketplace_1_0 {\n /**\n * Name used for the marketplace.\n */\n name: string;\n\n /**\n * A short summary used for the card on marketplace.\n * For longer description add a description.md file in the /assets/ folder of the app, and set the fullDescriptionPath.\n */\n description: string;\n\n /**\n * The path to a markdown file that explains your app in more detail.\n * The file must be stored in the assets folder within the app directory to work.\n * The path is relative to that directory.\n * For a file apps/my-app/assets/description.md, this parameter should be: description.md\n */\n fullDescriptionPath: string;\n\n /**\n * Path to an image in the assets folder of the app.\n * The image will be shown in the marketplace.\n * Example: typing \"MyImage.png\" here, will show the file \"apps/my-app/assets/MyImage.png\"\n */\n logoPath?: string;\n /**\n * A list of relevant tags to make your app easier to find.\n */\n tags?: string
|
|
1
|
+
{"version":3,"file":"irisAppMarketplace.js","sourceRoot":"","sources":["../../../../../../libs/iris-app-sdk/iris-app-api/src/types/irisAppMarketplace.ts"],"names":[],"mappings":";;;AAyGa,QAAA,cAAc,GAAG;IAC5B,kBAAkB;IAClB,YAAY;IACZ,aAAa;IACb,YAAY;IACZ,eAAe;IACf,sBAAsB;IACtB,sBAAsB;IACtB,uBAAuB;IACvB,mBAAmB;IACnB,mBAAmB;IACnB,yBAAyB;IACzB,gBAAgB;CACR,CAAC","sourcesContent":["import { SubscriptionPackage } from \"./subscriptionPackages\";\n\n/**\n * An image that should be shown in the marketplace for this app.\n */\nexport interface MarketplaceAssetImage {\n /**\n * The type of the Asset\n */\n type: \"IMAGE\";\n /**\n * A Path to an image in the assets folder of the app.\n * Example: typing \"MyImage.png\" here, will show the file \"apps/my-app/assets/MyImage.png\"\n */\n path: string;\n}\n\n/**\n * A video that should be shown in the marketplace for this app.\n */\nexport interface MarketplaceAssetVideo {\n /**\n * The type of the Asset\n */\n type: \"VIDEO\";\n /**\n * An url for a youtube video.\n */\n url: string;\n}\n\n/**\n * A video or image that should be shown in the marketplace for this app.\n */\nexport type MarketplaceAsset = MarketplaceAssetImage | MarketplaceAssetVideo;\n\n/**\n * An object of data used when the app is displayed in the marketplace\n */\nexport interface Marketplace extends Omit<Marketplace_1_0, \"allowForPackage\"> {\n /**\n * Indicate if the app should be shown in the Trackunit Marketplace.\n */\n showInMarketplace: boolean;\n}\n\n/**\n * An object of data used when the app is displayed in the marketplace\n *\n * @deprecated\n */\nexport interface Marketplace_1_0 {\n /**\n * Name used for the marketplace.\n */\n name: string;\n\n /**\n * A short summary used for the card on marketplace.\n * For longer description add a description.md file in the /assets/ folder of the app, and set the fullDescriptionPath.\n */\n description: string;\n\n /**\n * The path to a markdown file that explains your app in more detail.\n * The file must be stored in the assets folder within the app directory to work.\n * The path is relative to that directory.\n * For a file apps/my-app/assets/description.md, this parameter should be: description.md\n */\n fullDescriptionPath: string;\n\n /**\n * Path to an image in the assets folder of the app.\n * The image will be shown in the marketplace.\n * Example: typing \"MyImage.png\" here, will show the file \"apps/my-app/assets/MyImage.png\"\n */\n logoPath?: string;\n /**\n * A list of relevant tags to make your app easier to find.\n */\n tags?: Array<string>;\n /**\n * Categories used for the app in the marketplace.\n */\n categories?: Array<Category>;\n /**\n * Assets (images and videos) used for the marketplace.\n */\n assets?: Array<MarketplaceAsset>;\n /**\n * Defines with which subscription packages your app is compatible.\n * Take great care when entering this, as your app might bug out (if it went through the approval phase in the first place)\n * if what is stated here does not match reality.\n */\n allowForPackage: \"ALL_PACKAGES\" | Array<SubscriptionPackage>;\n /**\n * Homepage of the company building the app for the marketplace.\n */\n homePageUrl?: string;\n /**\n * The direct support page for this app.\n */\n supportUrl?: string;\n}\n\nexport const CategoryValues = [\n \"ASSET_MANAGEMENT\",\n \"COMPLIANCE\",\n \"CONSULTANTS\",\n \"DATA_FEEDS\",\n \"DOCUMENTATION\",\n \"EFFECTIVE_OPERATIONS\",\n \"EQUIPMENT_PROTECTION\",\n \"OEM_PARTNER_SOLUTIONS\",\n \"OPTIMIZE_BUSINESS\",\n \"RENTAL_MANAGEMENT\",\n \"SERVICE_AND_MAINTENANCE\",\n \"SUSTAINABILITY\",\n] as const;\n\nexport declare type Category = (typeof CategoryValues)[number];\n"]}
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
/**
|
|
2
2
|
* Modules that should be shared in the share scope. When provided, property names are used to match requested modules in this compilation.
|
|
3
3
|
*/
|
|
4
|
-
export type Shared =
|
|
4
|
+
export type Shared = Array<SharedItem | SharedObject> | SharedObject;
|
|
5
5
|
/**
|
|
6
6
|
* A module that should be shared in the share scope.
|
|
7
7
|
*/
|
|
@@ -59,7 +59,7 @@ export interface SharedConfig {
|
|
|
59
59
|
/**
|
|
60
60
|
* Modules that should be exposed by this container. When provided, property name is used as public name, otherwise public name is automatically inferred from request.
|
|
61
61
|
*/
|
|
62
|
-
export type Exposes =
|
|
62
|
+
export type Exposes = Array<ExposesItem | ExposesObject> | ExposesObject;
|
|
63
63
|
/**
|
|
64
64
|
* Module that should be exposed by this container.
|
|
65
65
|
*/
|
|
@@ -67,7 +67,7 @@ export type ExposesItem = string;
|
|
|
67
67
|
/**
|
|
68
68
|
* Modules that should be exposed by this container.
|
|
69
69
|
*/
|
|
70
|
-
export type ExposesItems = ExposesItem
|
|
70
|
+
export type ExposesItems = Array<ExposesItem>;
|
|
71
71
|
/**
|
|
72
72
|
* Modules that should be exposed by this container. Property names are used as public paths.
|
|
73
73
|
*/
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"modulefederation.js","sourceRoot":"","sources":["../../../../../../libs/iris-app-sdk/iris-app-api/src/types/modulefederation.ts"],"names":[],"mappings":";AAAA,sJAAsJ","sourcesContent":["// Source: https://github.com/webpack/webpack/blob/1c9b1b7a2136d4d9a27352fdbdf389490cca6460/declarations/plugins/container/ModuleFederationPlugin.d.ts\n\n/**\n * Modules that should be shared in the share scope. When provided, property names are used to match requested modules in this compilation.\n */\nexport type Shared =
|
|
1
|
+
{"version":3,"file":"modulefederation.js","sourceRoot":"","sources":["../../../../../../libs/iris-app-sdk/iris-app-api/src/types/modulefederation.ts"],"names":[],"mappings":";AAAA,sJAAsJ","sourcesContent":["// Source: https://github.com/webpack/webpack/blob/1c9b1b7a2136d4d9a27352fdbdf389490cca6460/declarations/plugins/container/ModuleFederationPlugin.d.ts\n\n/**\n * Modules that should be shared in the share scope. When provided, property names are used to match requested modules in this compilation.\n */\nexport type Shared = Array<SharedItem | SharedObject> | SharedObject;\n\n/**\n * A module that should be shared in the share scope.\n */\nexport type SharedItem = string;\n\n/**\n * Modules that should be shared in the share scope. Property names are used to match requested modules in this compilation. Relative requests are resolved, module requests are matched unresolved, absolute paths will match resolved requests. A trailing slash will match all requests with this prefix. In this case shareKey must also have a trailing slash.\n */\nexport interface SharedObject {\n /**\n * Modules that should be shared in the share scope.\n */\n [k: string]: SharedConfig | SharedItem;\n}\n\n/**\n * Advanced configuration for modules that should be shared in the share scope.\n */\nexport interface SharedConfig {\n /**\n * Include the provided and fallback module directly instead behind an async request. This allows to use this shared module in initial load too. All possible shared modules need to be eager too.\n */\n eager?: boolean;\n /**\n * Provided module that should be provided to share scope. Also acts as fallback module if no shared module is found in share scope or version isn't valid. Defaults to the property name.\n */\n import?: false | SharedItem;\n /**\n * Package name to determine required version from description file. This is only needed when package name can't be automatically determined from request.\n */\n packageName?: string;\n /**\n * Version requirement from module in share scope.\n */\n requiredVersion?: false | string;\n /**\n * Module is looked up under this key from the share scope.\n */\n shareKey?: string;\n /**\n * Share scope name.\n */\n shareScope?: string;\n /**\n * Allow only a single version of the shared module in share scope (disabled by default).\n */\n singleton?: boolean;\n /**\n * Do not accept shared module if version is not valid (defaults to yes, if local fallback module is available and shared module is not a singleton, otherwise no, has no effect if there is no required version specified).\n */\n strictVersion?: boolean;\n /**\n * Version of the provided module. Will replace lower matching versions, but not higher.\n */\n version?: false | string;\n}\n\n/**\n * Modules that should be exposed by this container. When provided, property name is used as public name, otherwise public name is automatically inferred from request.\n */\nexport type Exposes = Array<ExposesItem | ExposesObject> | ExposesObject;\n/**\n * Module that should be exposed by this container.\n */\nexport type ExposesItem = string;\n/**\n * Modules that should be exposed by this container.\n */\nexport type ExposesItems = Array<ExposesItem>;\n\n/**\n * Modules that should be exposed by this container. Property names are used as public paths.\n */\nexport interface ExposesObject {\n /**\n * Modules that should be exposed by this container.\n */\n [k: string]: ExposesConfig | ExposesItem | ExposesItems;\n}\n/**\n * Advanced configuration for modules that should be exposed by this container.\n */\nexport interface ExposesConfig {\n /**\n * Request to a module that should be exposed by this container.\n */\n import: ExposesItem | ExposesItems;\n /**\n * Custom chunk name for the exposed module.\n */\n name?: string;\n}\n"]}
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
type AllowList = "*" |
|
|
1
|
+
type AllowList = "*" | Array<"src" | "self" | `http://${string}` | `https://${string}`>;
|
|
2
2
|
export interface PermissionsPolicy {
|
|
3
3
|
accelerometer?: AllowList;
|
|
4
4
|
"ambient-light-sensor"?: AllowList;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"permissionsPolicy.js","sourceRoot":"","sources":["../../../../../../libs/iris-app-sdk/iris-app-api/src/types/permissionsPolicy.ts"],"names":[],"mappings":";;AA8CA,gEAQC;AAXD;;GAEG;AACH,SAAgB,0BAA0B,CAAC,MAAyB;IAClE,+EAA+E;IAC/E,OAAO,MAAM,CAAC,OAAO,CAAC,MAAM,CAAC;SAC1B,MAAM,CAAC,CAAC,CAAC,CAAC,EAAE,SAAS,CAAC,EAAE,EAAE,CAAC,CAAC,CAAC,SAAS,CAAC;SACvC,GAAG,CAAC,CAAC,CAAC,SAAS,EAAE,SAAS,CAAC,EAAE,EAAE,CAC9B,KAAK,CAAC,OAAO,CAAC,SAAS,CAAC,CAAC,CAAC,CAAC,GAAG,SAAS,IAAI,SAAS,CAAC,IAAI,CAAC,GAAG,CAAC,EAAE,CAAC,CAAC,CAAC,GAAG,SAAS,IAAI,SAAS,EAAE,CAC/F;SACA,IAAI,CAAC,IAAI,CAAC,CAAC;AAChB,CAAC","sourcesContent":["type AllowList = \"*\" |
|
|
1
|
+
{"version":3,"file":"permissionsPolicy.js","sourceRoot":"","sources":["../../../../../../libs/iris-app-sdk/iris-app-api/src/types/permissionsPolicy.ts"],"names":[],"mappings":";;AA8CA,gEAQC;AAXD;;GAEG;AACH,SAAgB,0BAA0B,CAAC,MAAyB;IAClE,+EAA+E;IAC/E,OAAO,MAAM,CAAC,OAAO,CAAC,MAAM,CAAC;SAC1B,MAAM,CAAC,CAAC,CAAC,CAAC,EAAE,SAAS,CAAC,EAAE,EAAE,CAAC,CAAC,CAAC,SAAS,CAAC;SACvC,GAAG,CAAC,CAAC,CAAC,SAAS,EAAE,SAAS,CAAC,EAAE,EAAE,CAC9B,KAAK,CAAC,OAAO,CAAC,SAAS,CAAC,CAAC,CAAC,CAAC,GAAG,SAAS,IAAI,SAAS,CAAC,IAAI,CAAC,GAAG,CAAC,EAAE,CAAC,CAAC,CAAC,GAAG,SAAS,IAAI,SAAS,EAAE,CAC/F;SACA,IAAI,CAAC,IAAI,CAAC,CAAC;AAChB,CAAC","sourcesContent":["type AllowList = \"*\" | Array<\"src\" | \"self\" | `http://${string}` | `https://${string}`>;\n\n/*\n * Based on types from https://github.com/klnjs/basique/blob/master/packages/utils/headers/src/permissions-policy.ts and\n * adapted to our needs.\n */\nexport interface PermissionsPolicy {\n accelerometer?: AllowList;\n \"ambient-light-sensor\"?: AllowList;\n \"attribution-reporting\"?: AllowList;\n autoplay?: AllowList;\n bluetooth?: AllowList;\n camera?: AllowList;\n \"clipboard-read\"?: AllowList;\n \"clipboard-write\"?: AllowList;\n \"cross-origin-isolated\"?: AllowList;\n \"display-capture\"?: AllowList;\n \"document-domain\"?: AllowList;\n \"encrypted-media\"?: AllowList;\n \"execution-while-not-rendered\"?: AllowList;\n \"execution-while-out-of-viewport\"?: AllowList;\n fullscreen?: AllowList;\n geolocation?: AllowList;\n gyroscope?: AllowList;\n hid?: AllowList;\n \"idle-detection\"?: AllowList;\n \"interest-cohort\"?: AllowList;\n magnetometer?: AllowList;\n microphone?: AllowList;\n midi?: AllowList;\n \"navigation-override\"?: AllowList;\n payment?: AllowList;\n \"picture-in-picture\"?: AllowList;\n \"publickey-credentials-get\"?: AllowList;\n \"screen-wake-lock\"?: AllowList;\n serial?: AllowList;\n speaker?: AllowList;\n \"sync-xhr\"?: AllowList;\n usb?: AllowList;\n \"web-share\"?: AllowList;\n \"xr-spatial-tracking\"?: AllowList;\n}\n\n/**\n * Stringifies a PermissionsPolicy, so that it can be added to the `allow` property of an iframe element\n */\nexport function permissionsPolicyStringify(policy: PermissionsPolicy): string {\n // eslint-disable-next-line no-autofix/local-rules/prefer-custom-object-entries\n return Object.entries(policy)\n .filter(([_, allowlist]) => !!allowlist)\n .map(([directive, allowlist]) =>\n Array.isArray(allowlist) ? `${directive} ${allowlist.join(\" \")}` : `${directive} ${allowlist}`\n )\n .join(\"; \");\n}\n"]}
|