@openfin/core-web 0.40.11 → 0.40.13

Sign up to get free protection for your applications and to get access to all the features.
Files changed (62) hide show
  1. package/README.md +23 -23
  2. package/docs/platform-developer-guide.md +4 -0
  3. package/docs/web-application-developer-guide.md +4 -0
  4. package/out/api-client.js +1 -1
  5. package/out/docs/.nojekyll +1 -0
  6. package/out/docs/assets/highlight.css +134 -0
  7. package/out/docs/assets/icons.js +18 -0
  8. package/out/docs/assets/icons.svg +1 -0
  9. package/out/docs/assets/main.js +60 -0
  10. package/out/docs/assets/navigation.js +1 -0
  11. package/out/docs/assets/search.js +1 -0
  12. package/out/docs/assets/style.css +1448 -0
  13. package/out/docs/documents/OpenFin_Web_Application_Developer_Guide.html +43 -0
  14. package/out/docs/documents/Platform_Developer_Guide.html +75 -0
  15. package/out/docs/functions/_openfin_core_web.connect.html +18 -0
  16. package/out/docs/functions/_openfin_core_web_iframe_broker.init.html +1 -0
  17. package/out/docs/functions/_openfin_core_web_iframe_broker.rejectConnections.html +1 -0
  18. package/out/docs/index.html +6 -0
  19. package/out/docs/modules/_openfin_core_web.html +19 -0
  20. package/out/docs/modules/_openfin_core_web_iframe_broker.html +10 -0
  21. package/out/docs/modules/_openfin_core_web_shared_worker.html +4 -0
  22. package/out/docs/types/_openfin_core_web.BaseConfig.html +3 -0
  23. package/out/docs/types/_openfin_core_web.BaseConnectionOptions.html +4 -0
  24. package/out/docs/types/_openfin_core_web.ConnectConfig.html +1 -0
  25. package/out/docs/types/_openfin_core_web.InheritModeConnectConfig.html +12 -0
  26. package/out/docs/types/_openfin_core_web.StandAloneConnectConfig.html +7 -0
  27. package/out/docs/types/_openfin_core_web.ViewComponentConfig.html +1 -0
  28. package/out/docs/types/_openfin_core_web.WebCreateLayoutOptions.html +1 -0
  29. package/out/docs/types/_openfin_core_web.WebLayoutComponent.html +2 -0
  30. package/out/docs/types/_openfin_core_web.WebLayoutInitOptions.html +1 -0
  31. package/out/docs/types/_openfin_core_web.WebLayoutOptions.html +1 -0
  32. package/out/docs/types/_openfin_core_web.WebLayoutPlatformOptions.html +1 -0
  33. package/out/docs/types/_openfin_core_web.WebLayoutSnapshot.html +1 -0
  34. package/out/docs/types/_openfin_core_web_iframe_broker.ConnectionOptions.html +1 -0
  35. package/out/docs/variables/_openfin_core_web_shared_worker.default.html +1 -0
  36. package/out/main-960862b6.js +3 -0
  37. package/out/main-f265d249.js +1 -0
  38. package/out/shared-worker.js +1 -1
  39. package/package.json +2 -3
  40. package/out/docs/@openfin/core-web/README.md +0 -50
  41. package/out/docs/@openfin/core-web/functions/connect.md +0 -54
  42. package/out/docs/@openfin/core-web/iframe-broker/README.md +0 -35
  43. package/out/docs/@openfin/core-web/iframe-broker/functions/init.md +0 -17
  44. package/out/docs/@openfin/core-web/iframe-broker/functions/rejectConnections.md +0 -19
  45. package/out/docs/@openfin/core-web/iframe-broker/type-aliases/ConnectionOptions.md +0 -23
  46. package/out/docs/@openfin/core-web/shared-worker/README.md +0 -16
  47. package/out/docs/@openfin/core-web/shared-worker/variables/default.md +0 -9
  48. package/out/docs/@openfin/core-web/type-aliases/BaseConfig.md +0 -18
  49. package/out/docs/@openfin/core-web/type-aliases/BaseConnectionOptions.md +0 -29
  50. package/out/docs/@openfin/core-web/type-aliases/ConnectConfig.md +0 -9
  51. package/out/docs/@openfin/core-web/type-aliases/InheritModeConnectConfig.md +0 -49
  52. package/out/docs/@openfin/core-web/type-aliases/StandAloneConnectConfig.md +0 -31
  53. package/out/docs/@openfin/core-web/type-aliases/ViewComponentConfig.md +0 -9
  54. package/out/docs/@openfin/core-web/type-aliases/WebCreateLayoutOptions.md +0 -15
  55. package/out/docs/@openfin/core-web/type-aliases/WebLayoutComponent.md +0 -23
  56. package/out/docs/@openfin/core-web/type-aliases/WebLayoutInitOptions.md +0 -15
  57. package/out/docs/@openfin/core-web/type-aliases/WebLayoutOptions.md +0 -15
  58. package/out/docs/@openfin/core-web/type-aliases/WebLayoutPlatformOptions.md +0 -15
  59. package/out/docs/@openfin/core-web/type-aliases/WebLayoutSnapshot.md +0 -15
  60. package/out/docs/README.md +0 -11
  61. package/out/main-3826f303.js +0 -1
  62. package/out/main-5acdc9b9.js +0 -1
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@openfin/core-web",
3
- "version": "0.40.11",
3
+ "version": "0.40.13",
4
4
  "description": "",
5
5
  "private": false,
6
6
  "files": [
@@ -49,11 +49,10 @@
49
49
  "dependencies": {
50
50
  "buffer": "6.0.3",
51
51
  "events": "^3.3.0",
52
- "golden-layout": "2.6.0",
53
52
  "lodash": "4.17.21",
54
53
  "uuid": "^8.3.2"
55
54
  },
56
55
  "peerDependencies": {
57
- "@openfin/core": "40.82.11"
56
+ "@openfin/core": "40.82.13"
58
57
  }
59
58
  }
@@ -1,50 +0,0 @@
1
- **@openfin/core-web** • [API](../../README.md)
2
-
3
- ***
4
-
5
- [@openfin/core-web](../../README.md) / @openfin/core-web
6
-
7
- # @openfin/core-web
8
-
9
- The main entry point for leveraging OpenFin Web Interop in a web application.
10
-
11
- ## Remarks
12
-
13
- This module provides a way to connect to an OpenFin Web Interop broker, which allows for communication between Web applications.
14
-
15
- ## Example
16
-
17
- ```ts
18
- import { connect } from '@openfin/core-web';
19
-
20
- const fin = await connect({
21
- options: {
22
- brokerUrl: 'ws://localhost:9696/broker'
23
- interopConfig: {
24
- providerId: 'my-provider-id',
25
- currentContextGroup: 'my-context-group'
26
- }
27
- }
28
- });
29
- ```
30
-
31
- ## Index
32
-
33
- ### Type Aliases
34
-
35
- - [BaseConfig](type-aliases/BaseConfig.md)
36
- - [BaseConnectionOptions](type-aliases/BaseConnectionOptions.md)
37
- - [ConnectConfig](type-aliases/ConnectConfig.md)
38
- - [InheritModeConnectConfig](type-aliases/InheritModeConnectConfig.md)
39
- - [StandAloneConnectConfig](type-aliases/StandAloneConnectConfig.md)
40
- - [ViewComponentConfig](type-aliases/ViewComponentConfig.md)
41
- - [WebCreateLayoutOptions](type-aliases/WebCreateLayoutOptions.md)
42
- - [WebLayoutComponent](type-aliases/WebLayoutComponent.md)
43
- - [WebLayoutInitOptions](type-aliases/WebLayoutInitOptions.md)
44
- - [WebLayoutOptions](type-aliases/WebLayoutOptions.md)
45
- - [WebLayoutPlatformOptions](type-aliases/WebLayoutPlatformOptions.md)
46
- - [WebLayoutSnapshot](type-aliases/WebLayoutSnapshot.md)
47
-
48
- ### Functions
49
-
50
- - [connect](functions/connect.md)
@@ -1,54 +0,0 @@
1
- **@openfin/core-web** • [API](../../../README.md)
2
-
3
- ***
4
-
5
- [@openfin/core-web](../../../README.md) / [@openfin/core-web](../README.md) / connect
6
-
7
- # Function: connect()
8
-
9
- > **connect**(`connectConfig`): `Promise`\<`Fin`\<`"external connection"`\>\>
10
-
11
- ## connect(connectConfig: ConnectConfig)
12
- Establishes a connection to an OpenFin Web Interop Broker, returning a fin object that supports a subset of APIS.
13
-
14
- ### Supported APIs
15
-
16
- * fin.InterApplicationBus.Channels
17
- * fin.Interop
18
- * fin.me.identity
19
- * fin.Platform.Layout.init
20
- * fin.Platform.Layout.create
21
- * fin.Platform.Layout.destroy
22
- * fin.Platform.Layout.getCurrentLayoutManagerSync
23
-
24
- ## Parameters
25
-
26
- • **connectConfig**: [`ConnectConfig`](../type-aliases/ConnectConfig.md)
27
-
28
- Config used to initialise the connection
29
-
30
- ## Returns
31
-
32
- `Promise`\<`Fin`\<`"external connection"`\>\>
33
-
34
- Fin api object
35
-
36
- ## Throws
37
-
38
- If the connection to the broker fails.
39
-
40
- ## Throws
41
-
42
- If the connection elapses the configured timeout
43
-
44
- ## Throws
45
-
46
- If the provided InheritModeConnectConfig.validateOptions returns false
47
-
48
- ## Throws
49
-
50
- If connection inheritance is enabled but the current browsing context is not rendered as a View within an OpenFin WebLayout and no ConnectConfig.options are provided.
51
-
52
- ## Throws
53
-
54
- If a platform object is provided but the layoutSnapshot is invalid.
@@ -1,35 +0,0 @@
1
- **@openfin/core-web** • [API](../../../README.md)
2
-
3
- ***
4
-
5
- [@openfin/core-web](../../../README.md) / @openfin/core-web/iframe-broker
6
-
7
- # @openfin/core-web/iframe-broker
8
-
9
- This module is the entry point for the Iframe Broker. It is responsible for initializing the OpenFin Web Interop environment.
10
-
11
- ## Remarks
12
-
13
- This module is intended to be used in an iframe context, and is responsible for setting up the connection between the iframe and the OpenFin Web Interop broker.
14
- This module requires hosting the script exported by the module:@openfin/core-web/worker module.
15
-
16
- ## Example
17
-
18
- ```ts
19
- import { init } from '@openfin/core-web/iframe-broker';
20
-
21
- init({
22
- sharedWorkerUrl: 'path to shared worker script'
23
- });
24
- ```
25
-
26
- ## Index
27
-
28
- ### Type Aliases
29
-
30
- - [ConnectionOptions](type-aliases/ConnectionOptions.md)
31
-
32
- ### Functions
33
-
34
- - [init](functions/init.md)
35
- - [rejectConnections](functions/rejectConnections.md)
@@ -1,17 +0,0 @@
1
- **@openfin/core-web** • [API](../../../../README.md)
2
-
3
- ***
4
-
5
- [@openfin/core-web](../../../../README.md) / [@openfin/core-web/iframe-broker](../README.md) / init
6
-
7
- # Function: init()
8
-
9
- > **init**(`options`): `Promise`\<`void`\>
10
-
11
- ## Parameters
12
-
13
- • **options**: [`ConnectionOptions`](../type-aliases/ConnectionOptions.md)
14
-
15
- ## Returns
16
-
17
- `Promise`\<`void`\>
@@ -1,19 +0,0 @@
1
- **@openfin/core-web** • [API](../../../../README.md)
2
-
3
- ***
4
-
5
- [@openfin/core-web](../../../../README.md) / [@openfin/core-web/iframe-broker](../README.md) / rejectConnections
6
-
7
- # Function: rejectConnections()
8
-
9
- > **rejectConnections**(`options`?): `void`
10
-
11
- ## Parameters
12
-
13
- • **options?**
14
-
15
- • **options\.reason?**: `string`
16
-
17
- ## Returns
18
-
19
- `void`
@@ -1,23 +0,0 @@
1
- **@openfin/core-web** • [API](../../../../README.md)
2
-
3
- ***
4
-
5
- [@openfin/core-web](../../../../README.md) / [@openfin/core-web/iframe-broker](../README.md) / ConnectionOptions
6
-
7
- # Type alias: ConnectionOptions
8
-
9
- > **ConnectionOptions**: `object`
10
-
11
- ## Type declaration
12
-
13
- ### experimental?
14
-
15
- > **`optional`** **experimental**: `object`
16
-
17
- ### experimental.crossTab?
18
-
19
- > **`optional`** **crossTab**: `"same-site"` \| `"none"`
20
-
21
- ### sharedWorkerUrl
22
-
23
- > **sharedWorkerUrl**: `string`
@@ -1,16 +0,0 @@
1
- **@openfin/core-web** • [API](../../../README.md)
2
-
3
- ***
4
-
5
- [@openfin/core-web](../../../README.md) / @openfin/core-web/shared-worker
6
-
7
- # @openfin/core-web/shared-worker
8
-
9
- This file is the entry point for the worker powering web-interop.
10
- It has no exports and is intended to be hosted with the url given to the `sharedWorkerUrl` option in the Iframe Broker (see: ["@openfin/core-web/iframe-broker"](../iframe-broker/README.md)).
11
-
12
- ## Index
13
-
14
- ### Variables
15
-
16
- - [default](variables/default.md)
@@ -1,9 +0,0 @@
1
- **@openfin/core-web** • [API](../../../../README.md)
2
-
3
- ***
4
-
5
- [@openfin/core-web](../../../../README.md) / [@openfin/core-web/shared-worker](../README.md) / default
6
-
7
- # Variable: default
8
-
9
- > **default**: `null`
@@ -1,18 +0,0 @@
1
- **@openfin/core-web** • [API](../../../README.md)
2
-
3
- ***
4
-
5
- [@openfin/core-web](../../../README.md) / [@openfin/core-web](../README.md) / BaseConfig
6
-
7
- # Type alias: BaseConfig
8
-
9
- > **BaseConfig**: `object`
10
-
11
- ## Type declaration
12
-
13
- ### platform?
14
-
15
- > **`optional`** **platform**: [`WebLayoutPlatformOptions`](WebLayoutPlatformOptions.md)
16
-
17
- Options used to initialize Web Layouts related features. If omitted, calling `fin.Platform.Layout.init()`
18
- will not work.
@@ -1,29 +0,0 @@
1
- **@openfin/core-web** • [API](../../../README.md)
2
-
3
- ***
4
-
5
- [@openfin/core-web](../../../README.md) / [@openfin/core-web](../README.md) / BaseConnectionOptions
6
-
7
- # Type alias: BaseConnectionOptions
8
-
9
- > **BaseConnectionOptions**: `object`
10
-
11
- ## Type declaration
12
-
13
- ### brokerUrl
14
-
15
- > **brokerUrl**: `string`
16
-
17
- The URL of the Web Interop broker to connect to.
18
-
19
- ### interopConfig?
20
-
21
- > **`optional`** **interopConfig**: `Partial`\<`OpenFin.InteropConfig`\>
22
-
23
- Interop options to use to generate an interop client in `fin.me.interop`
24
-
25
- ### timeout?
26
-
27
- > **`optional`** **timeout**: `number`
28
-
29
- Tears down and cancels the connection attempt if it is not complete within the specified timeout (in ms).
@@ -1,9 +0,0 @@
1
- **@openfin/core-web** • [API](../../../README.md)
2
-
3
- ***
4
-
5
- [@openfin/core-web](../../../README.md) / [@openfin/core-web](../README.md) / ConnectConfig
6
-
7
- # Type alias: ConnectConfig
8
-
9
- > **ConnectConfig**: [`StandAloneConnectConfig`](StandAloneConnectConfig.md) \| [`InheritModeConnectConfig`](InheritModeConnectConfig.md)
@@ -1,49 +0,0 @@
1
- **@openfin/core-web** • [API](../../../README.md)
2
-
3
- ***
4
-
5
- [@openfin/core-web](../../../README.md) / [@openfin/core-web](../README.md) / InheritModeConnectConfig
6
-
7
- # Type alias: InheritModeConnectConfig
8
-
9
- > **InheritModeConnectConfig**: [`BaseConfig`](BaseConfig.md) & `object`
10
-
11
- ## Type declaration
12
-
13
- ### connectionInheritance
14
-
15
- > **connectionInheritance**: `"enabled"`
16
-
17
- #### Default Value
18
-
19
- 'disabled'
20
-
21
- If 'enabled', attempts to inherit connection options if it is running as a View within an OpenFin WebLayout.
22
- This means that the `brokerUrl` and `Identity` of the connection will be determined by the WebBroker
23
- of the page where the WebLayout is instantiated via `fin.Platform.Layout.init()` call.
24
-
25
- If 'disabled', the `options` property is required.
26
-
27
- ### options?
28
-
29
- > **`optional`** **options**: [`BaseConnectionOptions`](BaseConnectionOptions.md)
30
-
31
- Options used to connect to an OpenFin Web Broker. Please note, these will be overriden if connectionInheritance
32
- is 'enabled' and supported for the current browsing context. In the case that inherited options are unavailable,
33
- these options will be used.
34
-
35
- ### validateOptions()?
36
-
37
- > **`optional`** **validateOptions**: (`inheritedOptions`) => `boolean` \| `Promise`\<`boolean`\>
38
-
39
- Validates the inherited connection options from the parent browsing context, if available.
40
-
41
- #### Parameters
42
-
43
- • **inheritedOptions**: `Omit`\<[`BaseConnectionOptions`](BaseConnectionOptions.md), `"timeout"`\>
44
-
45
- Inherited options
46
-
47
- #### Returns
48
-
49
- `boolean` \| `Promise`\<`boolean`\>
@@ -1,31 +0,0 @@
1
- **@openfin/core-web** • [API](../../../README.md)
2
-
3
- ***
4
-
5
- [@openfin/core-web](../../../README.md) / [@openfin/core-web](../README.md) / StandAloneConnectConfig
6
-
7
- # Type alias: StandAloneConnectConfig
8
-
9
- > **StandAloneConnectConfig**: [`BaseConfig`](BaseConfig.md) & `object`
10
-
11
- ## Type declaration
12
-
13
- ### connectionInheritance?
14
-
15
- > **`optional`** **connectionInheritance**: `"disabled"`
16
-
17
- #### Default Value
18
-
19
- 'disabled'
20
-
21
- If 'enabled', attempts to inherit connection options if it is running as a View within an OpenFin WebLayout.
22
- This means that the `brokerUrl` and `Identity` of the connection will be determined by the WebBroker
23
- of the page where the WebLayout is instantiated via `fin.Platform.Layout.init()` call.
24
-
25
- If 'disabled', the `options` property is required.
26
-
27
- ### options
28
-
29
- > **options**: [`BaseConnectionOptions`](BaseConnectionOptions.md)
30
-
31
- Options used to connect to an OpenFin Web Broker. Mandatory if StandAloneConnectConfig.connectionInheritance is 'disabled'.
@@ -1,9 +0,0 @@
1
- **@openfin/core-web** • [API](../../../README.md)
2
-
3
- ***
4
-
5
- [@openfin/core-web](../../../README.md) / [@openfin/core-web](../README.md) / ViewComponentConfig
6
-
7
- # Type alias: ViewComponentConfig
8
-
9
- > **ViewComponentConfig**: [`WebLayoutComponent`](WebLayoutComponent.md)\[`"componentState"`\]
@@ -1,15 +0,0 @@
1
- **@openfin/core-web** • [API](../../../README.md)
2
-
3
- ***
4
-
5
- [@openfin/core-web](../../../README.md) / [@openfin/core-web](../README.md) / WebCreateLayoutOptions
6
-
7
- # Type alias: WebCreateLayoutOptions
8
-
9
- > **WebCreateLayoutOptions**: `Omit`\<`OpenFin.CreateLayoutOptions`, `"layout"`\> & `object`
10
-
11
- ## Type declaration
12
-
13
- ### layout
14
-
15
- > **layout**: [`WebLayoutOptions`](WebLayoutOptions.md)
@@ -1,23 +0,0 @@
1
- **@openfin/core-web** • [API](../../../README.md)
2
-
3
- ***
4
-
5
- [@openfin/core-web](../../../README.md) / [@openfin/core-web](../README.md) / WebLayoutComponent
6
-
7
- # Type alias: WebLayoutComponent
8
-
9
- > **WebLayoutComponent**: `OpenFin.LayoutComponent` & `object`
10
-
11
- Web-only component supplied to IframeViewComponent as it's config
12
-
13
- ## Type declaration
14
-
15
- ### componentState?
16
-
17
- > **`optional`** **componentState**: `OpenFin.LayoutComponent`\[`"componentState"`\] & `object`
18
-
19
- #### Type declaration
20
-
21
- ##### web?
22
-
23
- > **`optional`** **web**: `WebState`
@@ -1,15 +0,0 @@
1
- **@openfin/core-web** • [API](../../../README.md)
2
-
3
- ***
4
-
5
- [@openfin/core-web](../../../README.md) / [@openfin/core-web](../README.md) / WebLayoutInitOptions
6
-
7
- # Type alias: WebLayoutInitOptions
8
-
9
- > **WebLayoutInitOptions**: `Omit`\<`OpenFin.InitLayoutOptions`, `"layoutManagerOverride"`\> & `object`
10
-
11
- ## Type declaration
12
-
13
- ### layoutManagerOverride?
14
-
15
- > **`optional`** **layoutManagerOverride**: `OpenFin.LayoutManagerOverride`\<[`WebLayoutSnapshot`](WebLayoutSnapshot.md)\>
@@ -1,15 +0,0 @@
1
- **@openfin/core-web** • [API](../../../README.md)
2
-
3
- ***
4
-
5
- [@openfin/core-web](../../../README.md) / [@openfin/core-web](../README.md) / WebLayoutOptions
6
-
7
- # Type alias: WebLayoutOptions
8
-
9
- > **WebLayoutOptions**: `Omit`\<`OpenFin.LayoutOptions`, `"content"`\> & `object`
10
-
11
- ## Type declaration
12
-
13
- ### content?
14
-
15
- > **`optional`** **content**: `WebLayoutContent`
@@ -1,15 +0,0 @@
1
- **@openfin/core-web** • [API](../../../README.md)
2
-
3
- ***
4
-
5
- [@openfin/core-web](../../../README.md) / [@openfin/core-web](../README.md) / WebLayoutPlatformOptions
6
-
7
- # Type alias: WebLayoutPlatformOptions
8
-
9
- > **WebLayoutPlatformOptions**: `object`
10
-
11
- ## Type declaration
12
-
13
- ### layoutSnapshot
14
-
15
- > **layoutSnapshot**: [`WebLayoutSnapshot`](WebLayoutSnapshot.md)
@@ -1,15 +0,0 @@
1
- **@openfin/core-web** • [API](../../../README.md)
2
-
3
- ***
4
-
5
- [@openfin/core-web](../../../README.md) / [@openfin/core-web](../README.md) / WebLayoutSnapshot
6
-
7
- # Type alias: WebLayoutSnapshot
8
-
9
- > **WebLayoutSnapshot**: `object`
10
-
11
- ## Type declaration
12
-
13
- ### layouts
14
-
15
- > **layouts**: `Record`\<`string`, [`WebLayoutOptions`](WebLayoutOptions.md)\>
@@ -1,11 +0,0 @@
1
- **@openfin/core-web** • API
2
-
3
- ***
4
-
5
- # @openfin/core-web
6
-
7
- ## Modules
8
-
9
- - [@openfin/core-web](@openfin/core-web/README.md)
10
- - [@openfin/core-web/iframe-broker](@openfin/core-web/iframe-broker/README.md)
11
- - [@openfin/core-web/shared-worker](@openfin/core-web/shared-worker/README.md)
@@ -1 +0,0 @@
1
- "use strict";var e=require("./main-5acdc9b9.js"),t=require("golden-layout"),i=require("uuid");require("buffer/"),require("events"),require("lodash");var o={},n={};Object.defineProperty(n,"__esModule",{value:!0}),n.mapValuesAsync=n.mapEntriesAsync=void 0;const s=(e,[t,i])=>({...e,[t]:i});async function a(e,t){return(await Promise.all(t.map((async([t,i])=>[t,await e(i,t)])))).reduce(s,{})}n.mapEntriesAsync=a,n.mapValuesAsync=async function(e,t){let i;return i=t instanceof Map?[...t.entries()]:Object.entries(t),a(e,i)};var r,l,c,u,h=e.commonjsGlobal&&e.commonjsGlobal.__classPrivateFieldSet||function(e,t,i,o,n){if("m"===o)throw new TypeError("Private method is not writable");if("a"===o&&!n)throw new TypeError("Private accessor was defined without a setter");if("function"==typeof t?e!==t||!n:!t.has(e))throw new TypeError("Cannot write private member to an object whose class did not declare it");return"a"===o?n.call(e,i):n?n.value=i:t.set(e,i),i},d=e.commonjsGlobal&&e.commonjsGlobal.__classPrivateFieldGet||function(e,t,i,o){if("a"===i&&!o)throw new TypeError("Private accessor was defined without a getter");if("function"==typeof t?e!==t||!o:!t.has(e))throw new TypeError("Cannot read private member from an object whose class did not declare it");return"m"===i?o:"a"===i?o.call(e):o?o.value:t.get(e)};Object.defineProperty(o,"__esModule",{value:!0});var m=o.DefaultLayoutManager=void 0;const y=n;class f{constructor(e){l.set(this,void 0),c.set(this,new Map),h(this,l,e,"f")}size(){return d(this,c,"f").size}async applyLayoutSnapshot({layouts:e}){if(Object.keys(e).length>1)throw new Error("[LayoutManager] Tried to call applyLayoutSnapshot with more than 1 layout. When implementing multiple layouts via overridden LayoutManager class, you must override and fully implement the applyLayoutSnapshot method without calling super.applyLayoutSnapshot().");const[[t,i]]=Object.entries(e);await f.createLayout(this,{layoutName:t,layout:i})}async showLayout({layoutName:e}){}async getLayoutSnapshot(){return{layouts:await(0,y.mapValuesAsync)((e=>e.getFrameSnapshot()),d(this,c,"f"))}}async removeLayout({layoutName:e}){}getLayoutIdentityForView(e){const t=[...d(this,c,"f").values()].find((t=>t.getCurrentViews().some((t=>t.name===e.name&&t.uuid===e.uuid))));return t?.identity??void 0}isLayoutVisible({layoutName:e}){return d(f,r,"m",u).call(f,this,e).isVisible()}resolveLayoutIdentity(e){if(e&&"layoutName"in e)return e;const t=[...d(this,c,"f").values()];if(1===t.length)return t[0].identity;const i=t.find((e=>e.isVisible()));return i?.identity??void 0}static async resolveLayout(e,t){const i=e.resolveLayoutIdentity(t);if(void 0===i||!("layoutName"in i))throw new Error("[layout-manager] resolveLayout: Could not resolve the layout identity. Make sure you include 'layoutName' in the identity object.");return d(f,r,"m",u).call(f,e,i.layoutName)}static async handleSharedView(e,t,i){await(0,y.mapValuesAsync)((async e=>{if(e.identity.layoutName!==t.layoutName){const t=e.getCurrentViews().find((e=>e.name===i.name));t&&await e.onViewDetached({viewIdentity:t,target:null}).catch(console.error)}}),d(e,c,"f"))}static async handleLastViewRemoved(e,t){await e.removeLayout(t),await d(e,l,"f").handleLastViewRemoved(e)}static async destroyLayout(e,{layoutName:t}){await d(f,r,"m",u).call(f,e,t).destroy(),d(e,c,"f").delete(t)}static async createLayout(e,t){const{layoutName:i}=t;if(d(e,c,"f").has(i))throw new Error(`Layout name ${i} already exists`);await d(e,l,"f").createLayout(t,e)}static registerLayout(e,t,i){d(e,c,"f").set(t,i)}static getAllLayouts(e){return[...d(e,c,"f").values()]}static setInitialSnapshot(e,t){d(e,l,"f").setInitialSnapshot(t)}static createClosedConstructor(...e){return class extends f{constructor(){super(...e)}}}}m=o.DefaultLayoutManager=f,r=f,l=new WeakMap,c=new WeakMap,u=function(e,t){const i=d(e,c,"f").get(t);if(!i)throw new Error(`[layout-manager] getLayoutByName: Could not locate layout with name '${t}'`);return i};var p={};Object.defineProperty(p,"__esModule",{value:!0});var w=p.BaseLayout=void 0;w=p.BaseLayout=class{};var v={};Object.defineProperty(v,"__esModule",{value:!0});var g=v.DOMEmitter=void 0;g=v.DOMEmitter=class{constructor(e){this.container=e}dispatchLocalEvent(e,t){const i={...t,type:e,tabSelector:`tab-${t.name}`,containerSelector:`container-${t.name}`,topic:"openfin-DOM-event"};this.container.dispatchEvent(new CustomEvent(e,{detail:i}))}};var b={};Object.defineProperty(b,"__esModule",{value:!0});var C=b.isVisible=void 0;C=b.isVisible=e=>(0!==e.offsetWidth||0!==e.offsetHeight)&&"hidden"!==window.getComputedStyle(e).visibility&&e.offsetTop>=0&&e.offsetLeft>=0&&e.offsetTop<=window.innerHeight&&e.offsetLeft<=window.innerWidth;const E="initial_",L={show:"top",popout:!1,maximise:!1,close:"close-tab-unused"},_={headerHeight:31},S={hasHeaders:!0,reorderEnabled:!0},V={popoutWholeStack:!1,constrainDragToContainer:!1,constrainDragToHeaders:!1,preventDragout:!1,showMaximiseIcon:!1,showPopoutIcon:!1,showCloseIcon:!1,blockedPopoutsThrowError:!0,closePopoutsOnUnload:!0,selectionEnabled:!1};var M,N,A;class P{constructor(t){this.layout=t,M.set(this,void 0),N.set(this,void 0),A.set(this,!1),this.handleResize=t=>{t.forEach((t=>{const i=this.layout.viewComponentsByContainerElement.get(t.target);i&&i.resize(i.container.element.getBoundingClientRect(),e.__classPrivateFieldGet(this,A,"f"))}))},this.handleMutation=()=>{document.body.classList.contains("lm_dragging")?(this.layout.handleDragStart(),e.__classPrivateFieldSet(this,A,!0,"f")):(this.layout.handleDragEnd(),e.__classPrivateFieldSet(this,A,!1,"f")),this.layout.viewComponentsByContainerElement.forEach((e=>{const t=e.container.tab.element;t&&t.className.includes("lm_dragging")&&e.hide()}))},e.__classPrivateFieldSet(this,M,new ResizeObserver(this.handleResize),"f"),e.__classPrivateFieldSet(this,N,new MutationObserver(this.handleMutation),"f")}observeDragging(){const t=this.layout.layout.rootItem;if(!t)throw new Error("Root item not found in layout.");e.__classPrivateFieldGet(this,N,"f")?.observe(t.element,{childList:!0,subtree:!0,attributes:!0,attributeFilter:["class"]})}destroy(){e.__classPrivateFieldGet(this,M,"f").disconnect(),e.__classPrivateFieldGet(this,N,"f").disconnect()}observeContainer(t){e.__classPrivateFieldGet(this,M,"f").observe(t)}unobserveContainer(t){e.__classPrivateFieldGet(this,M,"f").unobserve(t)}}function F(e=[],t){for(const i of e)"component"===i.type?Object.keys(t).forEach((e=>{e in i&&(i.componentState={[`${E}${e}`]:i[e],...i.componentState}),i[e]=t[e]})):F(i.content,t)}function $(e=[],t,i){for(const o of e)if("component"===o.type)Object.keys(t).forEach((e=>{if(`${E}${e}`in o.componentState)return o[e]=o.componentState[`${E}${e}`],void delete o.componentState[`${E}${e}`];o[e]=t[e]}));else{if(o.size&&("row"===i||"column"===i)){o["row"===i?"width":"height"]=o.size?.includes(".")?parseFloat(o.size):parseInt(o.size)}$(o.content,t,o.type)}}function k(e){if(e.root){e.root.content&&$([e.root],{componentName:"view",isClosable:!0});const t=e.root;e.content=[t],delete e.root}return e}M=new WeakMap,N=new WeakMap,A=new WeakMap;const x=t=>class extends t{connectedCallback(){if(!this.name||!this.uuid)throw new Error("<of-view> Name or uuid attribute missing");if(!this.src)throw new Error("<of-view> missing 'src' attribute.");this.#e||(this.#e=document.createElement("iframe"),this.#e.src=this.src,this.#e.style.height="100%",this.#e.style.width="100%",this.#e.style.border="none",this.forceFrameName?this.#e.setAttribute("name",this.forceFrameName):this.#e.setAttribute("name",e.encodeOptions({brokerUrl:this.brokerUrl,name:this.name,uuid:this.uuid,providerId:this.providerId,contextGroup:this.contextGroup},"of-frame")),this.#e.setAttribute("id",this.name),this.appendChild(this.#e))}#e;get brokerUrl(){return this.getAttribute("of-broker")}set brokerUrl(e){e&&this.setAttribute("of-broker",e)}get name(){return this.getAttribute("of-name")}set name(e){e&&this.setAttribute("of-name",e)}get forceFrameName(){return this.getAttribute("forceFrameName")}set forceFrameName(e){e&&this.setAttribute("forceFrameName",e)}get uuid(){return this.getAttribute("of-uuid")}set uuid(e){e&&this.setAttribute("of-uuid",e)}get src(){return this.getAttribute("src")}set src(e){e&&this.setAttribute("src",e)}get providerId(){return this.getAttribute("of-provider-id")}set providerId(e){e&&this.setAttribute("of-provider-id",e)}get contextGroup(){return this.getAttribute("of-context-group")}set contextGroup(e){e&&this.setAttribute("of-context-group",e)}static get observedAttributes(){return["name"]}};class I{static create(e){const t=document.createElement("of-view");return Object.entries(e).forEach((([e,i])=>{t.setAttribute(e,i)})),t}}customElements.define("of-view",x(HTMLElement));class G{constructor(e,t,o,{brokerUrl:n,interopConfig:s},a){this.container=e,this.config=t,this.ofView=null;const{url:r,web:l,interop:c}=t||{},u=`internal-generated-view-${i.v4()}`;if(this.identity={uuid:o,name:u},this.container.element.setAttribute("of-name",u),this.container.element.id=`container-${u}`,void 0===r)return void this.handleUrlMissing();const h=this.updateTitleIfNotSet(r),d={"of-broker":n,"of-uuid":o,"of-name":u,src:r};l?.frameName&&(d.forceFrameName=l.frameName);const m=c?.currentContextGroup??s?.currentContextGroup;m&&(d["of-context-group"]=m),s?.providerId&&(d["of-provider-id"]=s?.providerId),this.ofView=I.create(d),this.ofView.title=h??`Iframe: ${r}`,a.appendChild(this.ofView),this.ofView.style.position="absolute"}updateTitleIfNotSet(e){return"view"===this.container.parent.title&&this.container.parent.setTitle(e),this.container.parent.title}handleUrlMissing(){const e=document.createElement("div");e.setAttribute("style","padding: 20px");e.innerText="No URL provided",this.container.element.appendChild(e)}destroy(){this.ofView?.remove(),this.ofView=null}resize(e,t=!1){this.ofView&&(this.ofView.style.position="absolute",this.ofView.style.height=`${e.height}px`,this.ofView.style.width=`${e.width}px`,this.ofView.style.inset=`${e.top}px ${e.right}px ${e.bottom}px ${e.left}px`,t||(this.ofView.style.display="block"))}hide(){this.ofView&&(this.ofView.style.display="none")}}class T extends w{static overrideConfig(e){const t={...S,...e.settings,...V};return t.reorderEnabled?F(e.content,{isClosable:!0}):F(e.content,{reorderEnabled:!1}),{dimensions:_,...e,settings:t,header:{...L,show:!1!==e.settings?.hasHeaders&&L.show}}}constructor(e,i,o,{options:n}){super(),this.identity=e,this.container=i,this.initialConfig=o,this.viewComponentsByContainerElement=new Map,this.createViewComponent=(e,t)=>{const i=new G(e,t,this.identity.uuid,this.options,this.iframeContainer);return t&&!1===t[`${E}isClosable`]&&this.stylesheet.insertRule(`#tab-${i.identity.name} .lm_close_tab { display: none; }`),this.viewComponentsByContainerElement.set(e.element,i),this.resizeController.observeContainer(e.element),i},this.iframeContainer=document.createElement("div"),this.iframeContainer.id=`openfin-layout-iframe-container-${this.identity.layoutName}`,this.domEmitter=new g(i),this.setupStylesheets(),this.layout=new t.GoldenLayout(this.container),this.layout.resizeWithContainerAutomatically=!0,this.options=n,this.layout.registerComponent("view",this.createViewComponent),this.setupListeners(),this.resizeController=new P(this),this.layout.loadLayout(T.overrideConfig(o));const s=document.createElement("div");s.attachShadow({mode:"open",delegatesFocus:!1}).appendChild(this.iframeContainer),this.container.appendChild(s),this.resizeController.observeDragging()}setupStylesheets(){if(this.container.setAttribute("data-openfin-layout-name",this.identity.layoutName),this.stylesheet=new CSSStyleSheet,this.stylesheet.insertRule(".lm_close { display: none; }"),document.adoptedStyleSheets.push(this.stylesheet),this.initialConfig.settings?.preventSplitterResize){const e=`\n [data-openfin-layout-name='${this.identity.layoutName}'] .lm_splitter {\n pointer-events: none;\n }`;this.stylesheet.insertRule(e)}}addView(e){throw new Error("Method not implemented.")}replaceView({viewToReplace:e,newView:t}){throw new Error("Method not implemented.")}replaceLayout(e){throw new Error("Method not implemented.")}closeView(e){throw new Error("Method not implemented.")}applyPreset(e){throw new Error("Method not implemented.")}getCurrentViews(){throw new Error("Method not implemented.")}async getFrameSnapshot(){return k(t.LayoutConfig.fromResolved(this.layout.toConfig()))}isVisible(){return C(this.container)}async onViewDetached(){throw new Error("Method not implemented.")}async destroy(){this.layout.destroy(),this.iframeContainer.remove(),this.resizeController.destroy(),document.adoptedStyleSheets=document.adoptedStyleSheets.filter((e=>e!==this.stylesheet)),this.viewComponentsByContainerElement.clear()}setupListeners(){this.container.addEventListener("mousedown",(e=>{e.target instanceof HTMLElement&&e.target.classList.contains("lm_drag_handle")&&this.handleDragStart()})),this.container.addEventListener("pointerdown",(e=>{if(e.target instanceof HTMLElement&&2===e.button){const t=e.target.classList;["lm_tab","lm_title","lm_splitter","lm_drag_handle"].some((e=>t.contains(e)))&&e.stopPropagation()}}),!0),this.layout.on("tabCreated",(e=>{const t=e.componentItem.container.element.getAttribute("of-name")??i.v4(),o={name:t,uuid:t};e.element.id=`tab-${t}`,this.domEmitter.dispatchLocalEvent("tab-created",o)})),this.layout.on("itemCreated",(({target:e})=>{const t=e;if(!t.isComponent)return;const o=t.element.querySelector("[of-name]")?.getAttribute("of-name")??i.v4(),n={name:o,uuid:o};this.domEmitter.dispatchLocalEvent("container-created",n)})),this.layout.on("itemDestroyed",(e=>{const t=e.target;if(!t.isComponent)return;const i=t.component;this.removeViewComponent(i)}))}handleDragStart(){this.iframeContainer.style.pointerEvents="none"}handleDragEnd(){this.iframeContainer.style.pointerEvents=""}removeViewComponent(e){if(e.config&&!1===e.config[`${E}isClosable`]){const t=[...this.stylesheet.cssRules].findIndex((t=>t.cssText.includes(`#tab-${e.identity.name}`)));this.stylesheet.deleteRule(t)}e.destroy(),this.viewComponentsByContainerElement.delete(e.container.element),this.resizeController.unobserveContainer(e.container.element)}}class j{constructor(e,t,i){this.windowIdentity=e,this.connectConfig=t,this.fallbackContainer=i}async createLayout(e,t){if(!("container"in e)&&!this.fallbackContainer)throw new Error("Container property is not optional in web");const{layout:i,layoutName:o}=e,n=e.container??this.fallbackContainer,s={...this.windowIdentity,layoutName:o},a=new T(s,n,i,this.connectConfig);m.registerLayout(t,o,a),this.fallbackContainer=null}async getLayoutSnapshot(e){return e.getLayoutSnapshot()}async handleLastViewRemoved(e){throw new Error("Method not implemented.")}}var O;const z=e=>e;O=new WeakMap,exports.WebLayoutEntryPoint=class{constructor(t){O.set(this,void 0),this.initLayoutManager=async(t,i,{container:o,layoutManagerOverride:n})=>{const s=n??z,a=new j(i.me,e.__classPrivateFieldGet(this,O,"f"),o);return new(s(m.createClosedConstructor(a)))},this.applyLayoutSnapshot=async(t,i,o)=>{await i.applyLayoutSnapshot(e.__classPrivateFieldGet(this,O,"f").platform.layoutSnapshot)},this.createLayout=async(e,t)=>m.createLayout(e,t),this.destroyLayout=async(e,t)=>m.destroyLayout(e,t),e.__classPrivateFieldSet(this,O,t,"f")}};