@interopio/browser 3.3.3 → 3.3.5-next.0
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/browser.d.ts +113 -10
- package/dist/browser.es.js +401 -216
- package/dist/browser.es.js.map +1 -1
- package/dist/browser.umd.js +401 -216
- package/dist/browser.umd.js.map +1 -1
- package/dist/browser.umd.min.js +1 -1
- package/package.json +8 -8
package/browser.d.ts
CHANGED
|
@@ -939,10 +939,10 @@ export namespace IOConnectBrowser {
|
|
|
939
939
|
/**
|
|
940
940
|
* Updates the context of the current or a given channel.
|
|
941
941
|
* @param data Data object with which to update the channel context.
|
|
942
|
-
* @param
|
|
942
|
+
* @param options The name of the Channel to update, or an object containing the name of the Channel to update and a flag indicating whether the published data is an FDC3 context. If no options are provided, the current Channel will be updated.
|
|
943
943
|
* @returns Promise that resolves when the data has been published.
|
|
944
944
|
*/
|
|
945
|
-
publish(data: any,
|
|
945
|
+
publish(data: any, options?: string | PublishOptions): Promise<void>;
|
|
946
946
|
|
|
947
947
|
/**
|
|
948
948
|
* Returns a list of all channel names.
|
|
@@ -1059,6 +1059,21 @@ export namespace IOConnectBrowser {
|
|
|
1059
1059
|
restrictAll(restrictions: RestrictionsConfig): Promise<void>;
|
|
1060
1060
|
}
|
|
1061
1061
|
|
|
1062
|
+
/**
|
|
1063
|
+
* Options for updating a Channel context with the `publish()` method.
|
|
1064
|
+
*/
|
|
1065
|
+
export interface PublishOptions {
|
|
1066
|
+
/**
|
|
1067
|
+
* The name of the Channel to update. If not provided, the current Channel will be updated.
|
|
1068
|
+
*/
|
|
1069
|
+
name?: string;
|
|
1070
|
+
|
|
1071
|
+
/**
|
|
1072
|
+
* Flag indicating whether the published data is an FDC3 context. If so, it must contain a required `type` property.
|
|
1073
|
+
*/
|
|
1074
|
+
fdc3?: boolean;
|
|
1075
|
+
}
|
|
1076
|
+
|
|
1062
1077
|
/**
|
|
1063
1078
|
* All restrictions applied to a window for publishing or subscribing to Channels.
|
|
1064
1079
|
*/
|
|
@@ -1841,6 +1856,11 @@ export namespace IOConnectBrowser {
|
|
|
1841
1856
|
*/
|
|
1842
1857
|
getIntents(handler: IntentHandler): Promise<GetIntentsResult>;
|
|
1843
1858
|
|
|
1859
|
+
/**
|
|
1860
|
+
* Removes all saved Intent handlers for previously raised Intents.
|
|
1861
|
+
*/
|
|
1862
|
+
clearSavedHandlers(): Promise<void>;
|
|
1863
|
+
|
|
1844
1864
|
/**
|
|
1845
1865
|
* An object, which exposes the Intents Resolver API.
|
|
1846
1866
|
*/
|
|
@@ -1867,32 +1887,109 @@ export namespace IOConnectBrowser {
|
|
|
1867
1887
|
methodResponseTimeoutMs?: number;
|
|
1868
1888
|
}
|
|
1869
1889
|
|
|
1890
|
+
/**
|
|
1891
|
+
* Describes an Intent handler app within the Intents Resolver API.
|
|
1892
|
+
*/
|
|
1870
1893
|
interface ResolverIntentHandler {
|
|
1894
|
+
/**
|
|
1895
|
+
* Name of the Intent handler app.
|
|
1896
|
+
*/
|
|
1871
1897
|
applicationName: string;
|
|
1898
|
+
|
|
1899
|
+
/**
|
|
1900
|
+
* Title of the Intent handler.
|
|
1901
|
+
*/
|
|
1902
|
+
applicationTitle?: string;
|
|
1903
|
+
|
|
1904
|
+
/**
|
|
1905
|
+
* Icon of the Intent handler app.
|
|
1906
|
+
*/
|
|
1872
1907
|
applicationIcon?: string;
|
|
1908
|
+
|
|
1909
|
+
/**
|
|
1910
|
+
* ID of the Intent handler app instance.
|
|
1911
|
+
*/
|
|
1873
1912
|
instanceId?: string;
|
|
1874
1913
|
}
|
|
1875
1914
|
|
|
1915
|
+
/**
|
|
1916
|
+
* API for controlling the Intents Resolver UI app.
|
|
1917
|
+
*/
|
|
1876
1918
|
export interface Resolver {
|
|
1877
1919
|
/**
|
|
1878
|
-
* Name of the raised
|
|
1920
|
+
* Name of the raised Intent.
|
|
1879
1921
|
*/
|
|
1880
|
-
intent
|
|
1922
|
+
intent?: string | IntentRequest;
|
|
1923
|
+
|
|
1924
|
+
/**
|
|
1925
|
+
* Version of the Intents Resolver API.
|
|
1926
|
+
*/
|
|
1927
|
+
version: string;
|
|
1881
1928
|
|
|
1882
1929
|
/**
|
|
1883
|
-
*
|
|
1930
|
+
* Criteria for filtering the available Intent handlers. Available only if the `filterHandlers()` method was used to open the Intents Resolver UI.
|
|
1884
1931
|
*/
|
|
1885
|
-
|
|
1932
|
+
handlerFilter?: HandlerFilter;
|
|
1886
1933
|
|
|
1887
1934
|
/**
|
|
1888
|
-
*
|
|
1935
|
+
* Details about the app instance that opened the Intents Resolver UI.
|
|
1889
1936
|
*/
|
|
1890
|
-
|
|
1937
|
+
caller?: ResolverCaller;
|
|
1891
1938
|
|
|
1892
1939
|
/**
|
|
1893
|
-
*
|
|
1940
|
+
* Retrieves the title for the search operation. Available only if the `filterHandlers()` method was used to open the Intents Resolver UI and the `title` property of the `HandlerFilter` object was set.
|
|
1894
1941
|
*/
|
|
1895
|
-
|
|
1942
|
+
getTitle(): string | undefined;
|
|
1943
|
+
|
|
1944
|
+
/**
|
|
1945
|
+
* Notifies when a handler for the current Intent is added. Replays already existing handlers.
|
|
1946
|
+
* @param callback Callback function for handling the event.
|
|
1947
|
+
*/
|
|
1948
|
+
onHandlerAdded(callback: (handler: ResolverIntentHandler, intent: IntentInfo) => void): UnsubscribeFunction;
|
|
1949
|
+
|
|
1950
|
+
/**
|
|
1951
|
+
* Notifies when a handler for the current Intent is removed.
|
|
1952
|
+
* @param callback Callback function for handling the event.
|
|
1953
|
+
*/
|
|
1954
|
+
onHandlerRemoved(callback: (removedHandler: ResolverIntentHandler, intent: IntentInfo) => void): UnsubscribeFunction;
|
|
1955
|
+
|
|
1956
|
+
/**
|
|
1957
|
+
* Sends the chosen Intent handler to the app which raised the Intent.
|
|
1958
|
+
*/
|
|
1959
|
+
sendResponse(response: ResolverIntentHandler, options?: SendResolverResponseOptions): Promise<IOConnectCore.Interop.InvocationResult | undefined>;
|
|
1960
|
+
}
|
|
1961
|
+
|
|
1962
|
+
/**
|
|
1963
|
+
* Describes the app instance that opened the Intents Resolver UI.
|
|
1964
|
+
*/
|
|
1965
|
+
export interface ResolverCaller {
|
|
1966
|
+
/**
|
|
1967
|
+
* ID of the Interop instance of the app that opened the Intents Resolver UI.
|
|
1968
|
+
*/
|
|
1969
|
+
id: string;
|
|
1970
|
+
/**
|
|
1971
|
+
* Name of the app that opened the Intents Resolver UI.
|
|
1972
|
+
*/
|
|
1973
|
+
applicationName?: string;
|
|
1974
|
+
/**
|
|
1975
|
+
* Title of the app that opened the Intents Resolver UI.
|
|
1976
|
+
*/
|
|
1977
|
+
applicationTitle?: string;
|
|
1978
|
+
}
|
|
1979
|
+
|
|
1980
|
+
/**
|
|
1981
|
+
* Options for sending the chosen Intent handler to the app that raised the Intent.
|
|
1982
|
+
*/
|
|
1983
|
+
export interface SendResolverResponseOptions {
|
|
1984
|
+
/**
|
|
1985
|
+
* If `true`, the chosen Intent handler will be saved as a handler for the raised Intent. If the handler is saved, the next time the same Intent is raised, the Intents Resolver UI won't open and the saved handler will be used automatically.
|
|
1986
|
+
* @default false
|
|
1987
|
+
*/
|
|
1988
|
+
saveHandler: boolean;
|
|
1989
|
+
/**
|
|
1990
|
+
* Use this property to supply the name of the Intent when the Intents Resolver UI is opened via the `filterHandlers()` method and you want to save the Intent handler for that Intent. If the Intents Resolver UI is opened via the `raise()` method, it isn't necessary to explicitly provide the Intent name here, as specifying an Intent name is mandatory when using the `raise()` method.
|
|
1991
|
+
*/
|
|
1992
|
+
intent?: string;
|
|
1896
1993
|
}
|
|
1897
1994
|
|
|
1898
1995
|
/**
|
|
@@ -2092,6 +2189,12 @@ export namespace IOConnectBrowser {
|
|
|
2092
2189
|
* @default: false
|
|
2093
2190
|
*/
|
|
2094
2191
|
readonly waitUserResponseIndefinitely?: boolean;
|
|
2192
|
+
|
|
2193
|
+
/**
|
|
2194
|
+
* If `true`, the previously saved Intent handler for this Intent (if any) will be cleared.
|
|
2195
|
+
* @default false
|
|
2196
|
+
*/
|
|
2197
|
+
readonly clearSavedHandler?: boolean;
|
|
2095
2198
|
}
|
|
2096
2199
|
|
|
2097
2200
|
/**
|