@reveldigital/player-client 1.0.15 → 2.0.2
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/README.md +236 -236
- package/esm2022/lib/app-init.service.mjs +113 -0
- package/esm2022/lib/interfaces/client.interface.mjs +2 -0
- package/esm2022/lib/interfaces/command.interface.mjs +2 -0
- package/esm2022/lib/interfaces/config.interface.mjs +50 -0
- package/esm2022/lib/interfaces/device.interface.mjs +2 -0
- package/esm2022/lib/interfaces/event-properties.interface.mjs +2 -0
- package/esm2022/lib/interfaces/location.interface.mjs +2 -0
- package/esm2022/lib/player-client.module.mjs +71 -0
- package/esm2022/lib/player-client.service.mjs +928 -0
- package/esm2022/lib/safe-style.pipe.mjs +41 -0
- package/{esm2020 → esm2022}/lib/version.mjs +3 -3
- package/{esm2020 → esm2022}/public-api.mjs +6 -6
- package/{esm2020 → esm2022}/reveldigital-player-client.mjs +4 -4
- package/{fesm2020 → fesm2022}/reveldigital-player-client.mjs +1132 -1134
- package/fesm2022/reveldigital-player-client.mjs.map +1 -0
- package/{reveldigital-player-client.d.ts → index.d.ts} +5 -5
- package/lib/app-init.service.d.ts +18 -18
- package/lib/app-init.service.d.ts.map +1 -1
- package/lib/interfaces/client.interface.d.ts +406 -406
- package/lib/interfaces/command.interface.d.ts +78 -78
- package/lib/interfaces/config.interface.d.ts +151 -151
- package/lib/interfaces/device.interface.d.ts +139 -139
- package/lib/interfaces/event-properties.interface.d.ts +134 -134
- package/lib/interfaces/location.interface.d.ts +187 -187
- package/lib/player-client.module.d.ts +9 -9
- package/lib/player-client.service.d.ts +640 -640
- package/lib/safe-style.pipe.d.ts +23 -23
- package/lib/safe-style.pipe.d.ts.map +1 -1
- package/lib/version.d.ts +1 -1
- package/lib/version.d.ts.map +1 -1
- package/package.json +12 -18
- package/public-api.d.ts +3 -3
- package/schematics/collection.json +15 -15
- package/schematics/ng-add/assets/gadget.yaml +54 -54
- package/schematics/ng-add/index.d.ts +18 -4
- package/schematics/ng-add/index.js +391 -287
- package/schematics/ng-add/index.js.map +1 -1
- package/schematics/ng-add/schema.d.ts +4 -4
- package/schematics/ng-add/schema.js +2 -2
- package/schematics/ng-add/schema.json +23 -23
- package/schematics/ng-add/templates/index.html +30 -30
- package/schematics/ng-add/templates/polyfills.ts +72 -72
- package/schematics/ng-add/utils/changeBasePath.js +19 -19
- package/schematics/ng-add/utils/yml2xml.js +132 -132
- package/esm2020/lib/app-init.service.mjs +0 -110
- package/esm2020/lib/interfaces/client.interface.mjs +0 -2
- package/esm2020/lib/interfaces/command.interface.mjs +0 -2
- package/esm2020/lib/interfaces/config.interface.mjs +0 -50
- package/esm2020/lib/interfaces/device.interface.mjs +0 -2
- package/esm2020/lib/interfaces/event-properties.interface.mjs +0 -2
- package/esm2020/lib/interfaces/location.interface.mjs +0 -2
- package/esm2020/lib/player-client.module.mjs +0 -73
- package/esm2020/lib/player-client.service.mjs +0 -928
- package/esm2020/lib/safe-style.pipe.mjs +0 -40
- package/fesm2015/reveldigital-player-client.mjs +0 -1219
- package/fesm2015/reveldigital-player-client.mjs.map +0 -1
- package/fesm2020/reveldigital-player-client.mjs.map +0 -1
|
@@ -1,79 +1,79 @@
|
|
|
1
|
-
/**
|
|
2
|
-
* Interface representing a command sent to or from the Revel Digital player.
|
|
3
|
-
*
|
|
4
|
-
* Commands are the primary mechanism for triggering actions and behaviors
|
|
5
|
-
* in the player environment. They consist of a name identifier and an
|
|
6
|
-
* optional argument payload that provides additional context or parameters.
|
|
7
|
-
*
|
|
8
|
-
* Commands can originate from:
|
|
9
|
-
* - Remote devices via sendRemoteCommand()
|
|
10
|
-
* - Template scripting via player callbacks
|
|
11
|
-
* - Playlist actions and transitions
|
|
12
|
-
* - Manual triggers from the CMS interface
|
|
13
|
-
*
|
|
14
|
-
* ```typescript
|
|
15
|
-
* // Subscribe to incoming commands
|
|
16
|
-
* this.client.onCommand$.subscribe((command: ICommand) => {
|
|
17
|
-
* switch (command.name) {
|
|
18
|
-
* case 'refresh':
|
|
19
|
-
* this.refreshContent();
|
|
20
|
-
* break;
|
|
21
|
-
* case 'updateConfig':
|
|
22
|
-
* this.applyNewConfig(JSON.parse(command.arg));
|
|
23
|
-
* break;
|
|
24
|
-
* case 'customAction':
|
|
25
|
-
* this.handleCustomAction(command.arg);
|
|
26
|
-
* break;
|
|
27
|
-
* }
|
|
28
|
-
* });
|
|
29
|
-
* ```
|
|
30
|
-
*
|
|
31
|
-
* @export
|
|
32
|
-
* @interface ICommand
|
|
33
|
-
* @since 1.0.0
|
|
34
|
-
*/
|
|
35
|
-
export interface ICommand {
|
|
36
|
-
/**
|
|
37
|
-
* The command identifier or action name.
|
|
38
|
-
*
|
|
39
|
-
* This is a string that uniquely identifies the type of command or action
|
|
40
|
-
* to be performed. Command names should be descriptive and consistent
|
|
41
|
-
* across the application.
|
|
42
|
-
*
|
|
43
|
-
* Common command names:
|
|
44
|
-
* - "refresh" - Reload content or data
|
|
45
|
-
* - "restart" - Restart the application or component
|
|
46
|
-
* - "updateConfig" - Apply new configuration settings
|
|
47
|
-
* - "setVolume" - Adjust audio volume
|
|
48
|
-
* - "loadContent" - Load specific content by ID
|
|
49
|
-
* - "sync" - Synchronize with other devices
|
|
50
|
-
*/
|
|
51
|
-
name: string;
|
|
52
|
-
/**
|
|
53
|
-
* Optional command argument or payload data.
|
|
54
|
-
*
|
|
55
|
-
* This string contains any additional data required by the command.
|
|
56
|
-
* For complex data structures, this is typically a JSON-encoded string
|
|
57
|
-
* that can be parsed by the command handler.
|
|
58
|
-
*
|
|
59
|
-
* ```typescript
|
|
60
|
-
* // Simple string argument
|
|
61
|
-
* { name: "setVolume", arg: "75" }
|
|
62
|
-
*
|
|
63
|
-
* // JSON payload for complex data
|
|
64
|
-
* {
|
|
65
|
-
* name: "loadContent",
|
|
66
|
-
* arg: JSON.stringify({
|
|
67
|
-
* contentId: "abc123",
|
|
68
|
-
* transition: "fade",
|
|
69
|
-
* duration: 5000
|
|
70
|
-
* })
|
|
71
|
-
* }
|
|
72
|
-
*
|
|
73
|
-
* // Empty argument for parameterless commands
|
|
74
|
-
* { name: "refresh", arg: "" }
|
|
75
|
-
* ```
|
|
76
|
-
*/
|
|
77
|
-
arg: string;
|
|
78
|
-
}
|
|
1
|
+
/**
|
|
2
|
+
* Interface representing a command sent to or from the Revel Digital player.
|
|
3
|
+
*
|
|
4
|
+
* Commands are the primary mechanism for triggering actions and behaviors
|
|
5
|
+
* in the player environment. They consist of a name identifier and an
|
|
6
|
+
* optional argument payload that provides additional context or parameters.
|
|
7
|
+
*
|
|
8
|
+
* Commands can originate from:
|
|
9
|
+
* - Remote devices via sendRemoteCommand()
|
|
10
|
+
* - Template scripting via player callbacks
|
|
11
|
+
* - Playlist actions and transitions
|
|
12
|
+
* - Manual triggers from the CMS interface
|
|
13
|
+
*
|
|
14
|
+
* ```typescript
|
|
15
|
+
* // Subscribe to incoming commands
|
|
16
|
+
* this.client.onCommand$.subscribe((command: ICommand) => {
|
|
17
|
+
* switch (command.name) {
|
|
18
|
+
* case 'refresh':
|
|
19
|
+
* this.refreshContent();
|
|
20
|
+
* break;
|
|
21
|
+
* case 'updateConfig':
|
|
22
|
+
* this.applyNewConfig(JSON.parse(command.arg));
|
|
23
|
+
* break;
|
|
24
|
+
* case 'customAction':
|
|
25
|
+
* this.handleCustomAction(command.arg);
|
|
26
|
+
* break;
|
|
27
|
+
* }
|
|
28
|
+
* });
|
|
29
|
+
* ```
|
|
30
|
+
*
|
|
31
|
+
* @export
|
|
32
|
+
* @interface ICommand
|
|
33
|
+
* @since 1.0.0
|
|
34
|
+
*/
|
|
35
|
+
export interface ICommand {
|
|
36
|
+
/**
|
|
37
|
+
* The command identifier or action name.
|
|
38
|
+
*
|
|
39
|
+
* This is a string that uniquely identifies the type of command or action
|
|
40
|
+
* to be performed. Command names should be descriptive and consistent
|
|
41
|
+
* across the application.
|
|
42
|
+
*
|
|
43
|
+
* Common command names:
|
|
44
|
+
* - "refresh" - Reload content or data
|
|
45
|
+
* - "restart" - Restart the application or component
|
|
46
|
+
* - "updateConfig" - Apply new configuration settings
|
|
47
|
+
* - "setVolume" - Adjust audio volume
|
|
48
|
+
* - "loadContent" - Load specific content by ID
|
|
49
|
+
* - "sync" - Synchronize with other devices
|
|
50
|
+
*/
|
|
51
|
+
name: string;
|
|
52
|
+
/**
|
|
53
|
+
* Optional command argument or payload data.
|
|
54
|
+
*
|
|
55
|
+
* This string contains any additional data required by the command.
|
|
56
|
+
* For complex data structures, this is typically a JSON-encoded string
|
|
57
|
+
* that can be parsed by the command handler.
|
|
58
|
+
*
|
|
59
|
+
* ```typescript
|
|
60
|
+
* // Simple string argument
|
|
61
|
+
* { name: "setVolume", arg: "75" }
|
|
62
|
+
*
|
|
63
|
+
* // JSON payload for complex data
|
|
64
|
+
* {
|
|
65
|
+
* name: "loadContent",
|
|
66
|
+
* arg: JSON.stringify({
|
|
67
|
+
* contentId: "abc123",
|
|
68
|
+
* transition: "fade",
|
|
69
|
+
* duration: 5000
|
|
70
|
+
* })
|
|
71
|
+
* }
|
|
72
|
+
*
|
|
73
|
+
* // Empty argument for parameterless commands
|
|
74
|
+
* { name: "refresh", arg: "" }
|
|
75
|
+
* ```
|
|
76
|
+
*/
|
|
77
|
+
arg: string;
|
|
78
|
+
}
|
|
79
79
|
//# sourceMappingURL=command.interface.d.ts.map
|
|
@@ -1,152 +1,152 @@
|
|
|
1
|
-
/**
|
|
2
|
-
* Interface representing configuration settings and events for the Revel Digital system.
|
|
3
|
-
*
|
|
4
|
-
* This interface defines the structure for configuration-related communication
|
|
5
|
-
* between gadgets and the player, particularly during design-time configuration
|
|
6
|
-
* and preference management operations.
|
|
7
|
-
*
|
|
8
|
-
* Configuration events are typically used when:
|
|
9
|
-
* - Opening configuration dialogs in the CMS
|
|
10
|
-
* - Applying preference changes from configuration UI
|
|
11
|
-
* - Communicating between parent and child windows during config operations
|
|
12
|
-
*
|
|
13
|
-
* ```typescript
|
|
14
|
-
* // Handle configuration events
|
|
15
|
-
* this.client.onPostMessage$.subscribe((config: IConfig) => {
|
|
16
|
-
* if (config.type === ConfigType.ApplyConfig) {
|
|
17
|
-
* this.applyPreferences(config.prefs);
|
|
18
|
-
* }
|
|
19
|
-
* });
|
|
20
|
-
* ```
|
|
21
|
-
*
|
|
22
|
-
* @export
|
|
23
|
-
* @interface IConfig
|
|
24
|
-
* @since 1.0.0
|
|
25
|
-
*/
|
|
26
|
-
export interface IConfig {
|
|
27
|
-
/**
|
|
28
|
-
* Dictionary of preference key-value pairs containing configuration settings.
|
|
29
|
-
*
|
|
30
|
-
* This object contains all the preference values that have been configured
|
|
31
|
-
* for the gadget. The keys correspond to preference names defined in the
|
|
32
|
-
* gadget's configuration schema, and values can be of any type.
|
|
33
|
-
*
|
|
34
|
-
* ```typescript
|
|
35
|
-
* const config: IConfig = {
|
|
36
|
-
* prefs: {
|
|
37
|
-
* 'title': 'My Gadget Title',
|
|
38
|
-
* 'backgroundColor': '#ff0000',
|
|
39
|
-
* 'refreshInterval': 30,
|
|
40
|
-
* 'showBorder': true,
|
|
41
|
-
* 'apiEndpoint': 'https://api.example.com/data'
|
|
42
|
-
* },
|
|
43
|
-
* type: ConfigType.ApplyConfig,
|
|
44
|
-
* isOpener: false
|
|
45
|
-
* };
|
|
46
|
-
* ```
|
|
47
|
-
*/
|
|
48
|
-
prefs: IDictionary<any>;
|
|
49
|
-
/**
|
|
50
|
-
* The type of configuration operation being performed.
|
|
51
|
-
*
|
|
52
|
-
* Indicates whether this is a request to open configuration UI
|
|
53
|
-
* or an instruction to apply new configuration values.
|
|
54
|
-
*
|
|
55
|
-
* @see ConfigType enum for available values
|
|
56
|
-
*/
|
|
57
|
-
type: ConfigType;
|
|
58
|
-
/**
|
|
59
|
-
* Indicates if this configuration event originated from a popup window opener.
|
|
60
|
-
*
|
|
61
|
-
* When true, this suggests the configuration change originated from a popup
|
|
62
|
-
* configuration window and may need to be propagated to the parent window.
|
|
63
|
-
* This is used internally for handling window communication during config operations.
|
|
64
|
-
*
|
|
65
|
-
* ```typescript
|
|
66
|
-
* if (config.isOpener) {
|
|
67
|
-
* // Propagate config changes from popup to parent window
|
|
68
|
-
* window.parent.postMessage(configData, '*');
|
|
69
|
-
* }
|
|
70
|
-
* ```
|
|
71
|
-
*/
|
|
72
|
-
isOpener: boolean;
|
|
73
|
-
}
|
|
74
|
-
/**
|
|
75
|
-
* Generic dictionary interface for key-value pairs.
|
|
76
|
-
*
|
|
77
|
-
* This interface provides a flexible way to represent objects with
|
|
78
|
-
* string keys and values of any type. It's commonly used for configuration
|
|
79
|
-
* preferences, command arguments, and other dynamic data structures.
|
|
80
|
-
*
|
|
81
|
-
* @template T - The type of values stored in the dictionary
|
|
82
|
-
*
|
|
83
|
-
* ```typescript
|
|
84
|
-
* // String dictionary
|
|
85
|
-
* const stringPrefs: IDictionary<string> = {
|
|
86
|
-
* 'title': 'My Title',
|
|
87
|
-
* 'description': 'My Description'
|
|
88
|
-
* };
|
|
89
|
-
*
|
|
90
|
-
* // Mixed type dictionary
|
|
91
|
-
* const mixedPrefs: IDictionary<any> = {
|
|
92
|
-
* 'title': 'My Title',
|
|
93
|
-
* 'count': 42,
|
|
94
|
-
* 'enabled': true
|
|
95
|
-
* };
|
|
96
|
-
* ```
|
|
97
|
-
*
|
|
98
|
-
* @export
|
|
99
|
-
* @interface IDictionary
|
|
100
|
-
*/
|
|
101
|
-
export interface IDictionary<T> {
|
|
102
|
-
[Key: string]: T;
|
|
103
|
-
}
|
|
104
|
-
/**
|
|
105
|
-
* Enumeration of configuration operation types.
|
|
106
|
-
*
|
|
107
|
-
* Defines the different types of configuration-related operations
|
|
108
|
-
* that can be performed between gadgets and the player environment.
|
|
109
|
-
*
|
|
110
|
-
* @export
|
|
111
|
-
* @enum ConfigType
|
|
112
|
-
* @since 1.0.0
|
|
113
|
-
*/
|
|
114
|
-
export declare enum ConfigType {
|
|
115
|
-
/**
|
|
116
|
-
* Request to open the configuration interface.
|
|
117
|
-
*
|
|
118
|
-
* This type indicates that the configuration UI should be displayed,
|
|
119
|
-
* typically in response to a user action or system event.
|
|
120
|
-
*
|
|
121
|
-
* ```typescript
|
|
122
|
-
* // Trigger config UI opening
|
|
123
|
-
* const openConfigEvent: IConfig = {
|
|
124
|
-
* prefs: {},
|
|
125
|
-
* type: ConfigType.OpenConfig,
|
|
126
|
-
* isOpener: false
|
|
127
|
-
* };
|
|
128
|
-
* ```
|
|
129
|
-
*/
|
|
130
|
-
OpenConfig = "openConfig",
|
|
131
|
-
/**
|
|
132
|
-
* Instruction to apply new configuration values.
|
|
133
|
-
*
|
|
134
|
-
* This type indicates that the provided preferences should be
|
|
135
|
-
* applied to the gadget's configuration, typically after the
|
|
136
|
-
* user has made changes in the configuration UI.
|
|
137
|
-
*
|
|
138
|
-
* ```typescript
|
|
139
|
-
* // Apply new configuration
|
|
140
|
-
* const applyConfigEvent: IConfig = {
|
|
141
|
-
* prefs: {
|
|
142
|
-
* 'title': 'Updated Title',
|
|
143
|
-
* 'interval': 60
|
|
144
|
-
* },
|
|
145
|
-
* type: ConfigType.ApplyConfig,
|
|
146
|
-
* isOpener: true
|
|
147
|
-
* };
|
|
148
|
-
* ```
|
|
149
|
-
*/
|
|
150
|
-
ApplyConfig = "applyConfig"
|
|
151
|
-
}
|
|
1
|
+
/**
|
|
2
|
+
* Interface representing configuration settings and events for the Revel Digital system.
|
|
3
|
+
*
|
|
4
|
+
* This interface defines the structure for configuration-related communication
|
|
5
|
+
* between gadgets and the player, particularly during design-time configuration
|
|
6
|
+
* and preference management operations.
|
|
7
|
+
*
|
|
8
|
+
* Configuration events are typically used when:
|
|
9
|
+
* - Opening configuration dialogs in the CMS
|
|
10
|
+
* - Applying preference changes from configuration UI
|
|
11
|
+
* - Communicating between parent and child windows during config operations
|
|
12
|
+
*
|
|
13
|
+
* ```typescript
|
|
14
|
+
* // Handle configuration events
|
|
15
|
+
* this.client.onPostMessage$.subscribe((config: IConfig) => {
|
|
16
|
+
* if (config.type === ConfigType.ApplyConfig) {
|
|
17
|
+
* this.applyPreferences(config.prefs);
|
|
18
|
+
* }
|
|
19
|
+
* });
|
|
20
|
+
* ```
|
|
21
|
+
*
|
|
22
|
+
* @export
|
|
23
|
+
* @interface IConfig
|
|
24
|
+
* @since 1.0.0
|
|
25
|
+
*/
|
|
26
|
+
export interface IConfig {
|
|
27
|
+
/**
|
|
28
|
+
* Dictionary of preference key-value pairs containing configuration settings.
|
|
29
|
+
*
|
|
30
|
+
* This object contains all the preference values that have been configured
|
|
31
|
+
* for the gadget. The keys correspond to preference names defined in the
|
|
32
|
+
* gadget's configuration schema, and values can be of any type.
|
|
33
|
+
*
|
|
34
|
+
* ```typescript
|
|
35
|
+
* const config: IConfig = {
|
|
36
|
+
* prefs: {
|
|
37
|
+
* 'title': 'My Gadget Title',
|
|
38
|
+
* 'backgroundColor': '#ff0000',
|
|
39
|
+
* 'refreshInterval': 30,
|
|
40
|
+
* 'showBorder': true,
|
|
41
|
+
* 'apiEndpoint': 'https://api.example.com/data'
|
|
42
|
+
* },
|
|
43
|
+
* type: ConfigType.ApplyConfig,
|
|
44
|
+
* isOpener: false
|
|
45
|
+
* };
|
|
46
|
+
* ```
|
|
47
|
+
*/
|
|
48
|
+
prefs: IDictionary<any>;
|
|
49
|
+
/**
|
|
50
|
+
* The type of configuration operation being performed.
|
|
51
|
+
*
|
|
52
|
+
* Indicates whether this is a request to open configuration UI
|
|
53
|
+
* or an instruction to apply new configuration values.
|
|
54
|
+
*
|
|
55
|
+
* @see ConfigType enum for available values
|
|
56
|
+
*/
|
|
57
|
+
type: ConfigType;
|
|
58
|
+
/**
|
|
59
|
+
* Indicates if this configuration event originated from a popup window opener.
|
|
60
|
+
*
|
|
61
|
+
* When true, this suggests the configuration change originated from a popup
|
|
62
|
+
* configuration window and may need to be propagated to the parent window.
|
|
63
|
+
* This is used internally for handling window communication during config operations.
|
|
64
|
+
*
|
|
65
|
+
* ```typescript
|
|
66
|
+
* if (config.isOpener) {
|
|
67
|
+
* // Propagate config changes from popup to parent window
|
|
68
|
+
* window.parent.postMessage(configData, '*');
|
|
69
|
+
* }
|
|
70
|
+
* ```
|
|
71
|
+
*/
|
|
72
|
+
isOpener: boolean;
|
|
73
|
+
}
|
|
74
|
+
/**
|
|
75
|
+
* Generic dictionary interface for key-value pairs.
|
|
76
|
+
*
|
|
77
|
+
* This interface provides a flexible way to represent objects with
|
|
78
|
+
* string keys and values of any type. It's commonly used for configuration
|
|
79
|
+
* preferences, command arguments, and other dynamic data structures.
|
|
80
|
+
*
|
|
81
|
+
* @template T - The type of values stored in the dictionary
|
|
82
|
+
*
|
|
83
|
+
* ```typescript
|
|
84
|
+
* // String dictionary
|
|
85
|
+
* const stringPrefs: IDictionary<string> = {
|
|
86
|
+
* 'title': 'My Title',
|
|
87
|
+
* 'description': 'My Description'
|
|
88
|
+
* };
|
|
89
|
+
*
|
|
90
|
+
* // Mixed type dictionary
|
|
91
|
+
* const mixedPrefs: IDictionary<any> = {
|
|
92
|
+
* 'title': 'My Title',
|
|
93
|
+
* 'count': 42,
|
|
94
|
+
* 'enabled': true
|
|
95
|
+
* };
|
|
96
|
+
* ```
|
|
97
|
+
*
|
|
98
|
+
* @export
|
|
99
|
+
* @interface IDictionary
|
|
100
|
+
*/
|
|
101
|
+
export interface IDictionary<T> {
|
|
102
|
+
[Key: string]: T;
|
|
103
|
+
}
|
|
104
|
+
/**
|
|
105
|
+
* Enumeration of configuration operation types.
|
|
106
|
+
*
|
|
107
|
+
* Defines the different types of configuration-related operations
|
|
108
|
+
* that can be performed between gadgets and the player environment.
|
|
109
|
+
*
|
|
110
|
+
* @export
|
|
111
|
+
* @enum ConfigType
|
|
112
|
+
* @since 1.0.0
|
|
113
|
+
*/
|
|
114
|
+
export declare enum ConfigType {
|
|
115
|
+
/**
|
|
116
|
+
* Request to open the configuration interface.
|
|
117
|
+
*
|
|
118
|
+
* This type indicates that the configuration UI should be displayed,
|
|
119
|
+
* typically in response to a user action or system event.
|
|
120
|
+
*
|
|
121
|
+
* ```typescript
|
|
122
|
+
* // Trigger config UI opening
|
|
123
|
+
* const openConfigEvent: IConfig = {
|
|
124
|
+
* prefs: {},
|
|
125
|
+
* type: ConfigType.OpenConfig,
|
|
126
|
+
* isOpener: false
|
|
127
|
+
* };
|
|
128
|
+
* ```
|
|
129
|
+
*/
|
|
130
|
+
OpenConfig = "openConfig",
|
|
131
|
+
/**
|
|
132
|
+
* Instruction to apply new configuration values.
|
|
133
|
+
*
|
|
134
|
+
* This type indicates that the provided preferences should be
|
|
135
|
+
* applied to the gadget's configuration, typically after the
|
|
136
|
+
* user has made changes in the configuration UI.
|
|
137
|
+
*
|
|
138
|
+
* ```typescript
|
|
139
|
+
* // Apply new configuration
|
|
140
|
+
* const applyConfigEvent: IConfig = {
|
|
141
|
+
* prefs: {
|
|
142
|
+
* 'title': 'Updated Title',
|
|
143
|
+
* 'interval': 60
|
|
144
|
+
* },
|
|
145
|
+
* type: ConfigType.ApplyConfig,
|
|
146
|
+
* isOpener: true
|
|
147
|
+
* };
|
|
148
|
+
* ```
|
|
149
|
+
*/
|
|
150
|
+
ApplyConfig = "applyConfig"
|
|
151
|
+
}
|
|
152
152
|
//# sourceMappingURL=config.interface.d.ts.map
|