@interopio/browser 4.4.1 → 4.5.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 +86 -11
- package/changelog.md +8 -0
- package/dist/browser.es.js +91 -44
- package/dist/browser.es.js.map +1 -1
- package/dist/browser.umd.js +91 -44
- package/dist/browser.umd.js.map +1 -1
- package/dist/browser.umd.min.js +3 -3
- package/package.json +7 -8
package/dist/browser.umd.js
CHANGED
|
@@ -1804,22 +1804,26 @@
|
|
|
1804
1804
|
/** See `Decoder.succeed` */
|
|
1805
1805
|
Decoder$1.succeed;
|
|
1806
1806
|
/** See `Decoder.fail` */
|
|
1807
|
-
Decoder$1.fail;
|
|
1807
|
+
var fail$1 = Decoder$1.fail;
|
|
1808
1808
|
/** See `Decoder.lazy` */
|
|
1809
1809
|
Decoder$1.lazy;
|
|
1810
1810
|
|
|
1811
1811
|
const nonEmptyStringDecoder$3 = string$1().where((s) => s.length > 0, "Expected a non-empty string");
|
|
1812
1812
|
const nonNegativeNumberDecoder$3 = number$1().where((num) => num >= 0, "Expected a non-negative number");
|
|
1813
1813
|
const regexDecoder = anyJson$1().andThen((value) => {
|
|
1814
|
-
return value instanceof RegExp ? anyJson$1() : fail(`expected a regex, got a ${typeof value}`);
|
|
1814
|
+
return value instanceof RegExp ? anyJson$1() : fail$1(`expected a regex, got a ${typeof value}`);
|
|
1815
1815
|
});
|
|
1816
|
-
const urlDecoder = nonEmptyStringDecoder$3.andThen((url) => {
|
|
1816
|
+
const urlDecoder$1 = nonEmptyStringDecoder$3.andThen((url) => {
|
|
1817
1817
|
try {
|
|
1818
|
-
new URL(url);
|
|
1818
|
+
const { protocol } = new URL(url);
|
|
1819
|
+
const disallowedProtocols = ["data:", "javascript:", "vbscript:"];
|
|
1820
|
+
if (disallowedProtocols.includes(protocol)) {
|
|
1821
|
+
return fail$1(`Expected a URL with a safe protocol, got: ${protocol} (disallowed protocols: ${disallowedProtocols.join(", ")})`);
|
|
1822
|
+
}
|
|
1819
1823
|
return nonEmptyStringDecoder$3;
|
|
1820
1824
|
}
|
|
1821
1825
|
catch {
|
|
1822
|
-
return fail("
|
|
1826
|
+
return fail$1("Expected a valid URL");
|
|
1823
1827
|
}
|
|
1824
1828
|
});
|
|
1825
1829
|
|
|
@@ -1831,7 +1835,7 @@
|
|
|
1831
1835
|
});
|
|
1832
1836
|
const v2TypeDecoder = oneOf(constant$1("web"), constant$1("native"), constant$1("citrix"), constant$1("onlineNative"), constant$1("other"));
|
|
1833
1837
|
const v2DetailsDecoder = object$1({
|
|
1834
|
-
url:
|
|
1838
|
+
url: urlDecoder$1
|
|
1835
1839
|
});
|
|
1836
1840
|
const v2IconDecoder = object$1({
|
|
1837
1841
|
src: nonEmptyStringDecoder$3,
|
|
@@ -1859,18 +1863,19 @@
|
|
|
1859
1863
|
listensFor: optional$1(array$1(nonEmptyStringDecoder$3))
|
|
1860
1864
|
});
|
|
1861
1865
|
const v2AppChannelDecoder = object$1({
|
|
1862
|
-
name: nonEmptyStringDecoder$3,
|
|
1866
|
+
name: optional$1(nonEmptyStringDecoder$3),
|
|
1867
|
+
id: optional$1(nonEmptyStringDecoder$3),
|
|
1863
1868
|
description: optional$1(nonEmptyStringDecoder$3),
|
|
1864
1869
|
broadcasts: optional$1(array$1(nonEmptyStringDecoder$3)),
|
|
1865
1870
|
listensFor: optional$1(array$1(nonEmptyStringDecoder$3))
|
|
1866
|
-
});
|
|
1871
|
+
}).where((appChannel) => Boolean(appChannel.name || appChannel.id), "Expected at least a name or an id property to be present in the app channel definition");
|
|
1867
1872
|
const v2InteropDecoder = object$1({
|
|
1868
1873
|
intents: optional$1(v2IntentsDecoder),
|
|
1869
1874
|
userChannels: optional$1(v2UserChannelDecoder),
|
|
1870
1875
|
appChannels: optional$1(array$1(v2AppChannelDecoder))
|
|
1871
1876
|
});
|
|
1872
1877
|
const glue42ApplicationDetailsDecoder = object$1({
|
|
1873
|
-
url: optional$1(
|
|
1878
|
+
url: optional$1(urlDecoder$1),
|
|
1874
1879
|
top: optional$1(number$1()),
|
|
1875
1880
|
left: optional$1(number$1()),
|
|
1876
1881
|
width: optional$1(nonNegativeNumberDecoder$3),
|
|
@@ -2150,7 +2155,7 @@
|
|
|
2150
2155
|
nonEmptyStringDecoder: nonEmptyStringDecoder$3,
|
|
2151
2156
|
nonNegativeNumberDecoder: nonNegativeNumberDecoder$3,
|
|
2152
2157
|
regexDecoder,
|
|
2153
|
-
urlDecoder
|
|
2158
|
+
urlDecoder: urlDecoder$1
|
|
2154
2159
|
},
|
|
2155
2160
|
fdc3: {
|
|
2156
2161
|
allDefinitionsDecoder,
|
|
@@ -2199,13 +2204,14 @@
|
|
|
2199
2204
|
const decoders = ioc.decoders;
|
|
2200
2205
|
ioc.errors;
|
|
2201
2206
|
|
|
2202
|
-
const nonEmptyStringDecoder$2 =
|
|
2203
|
-
const nonNegativeNumberDecoder$2 =
|
|
2207
|
+
const nonEmptyStringDecoder$2 = decoders.common.nonEmptyStringDecoder;
|
|
2208
|
+
const nonNegativeNumberDecoder$2 = decoders.common.nonNegativeNumberDecoder;
|
|
2204
2209
|
const optionalNonEmptyStringDecoder = optional$2(nonEmptyStringDecoder$2);
|
|
2210
|
+
const urlDecoder = decoders.common.urlDecoder;
|
|
2205
2211
|
const libDomainDecoder = oneOf$1(constant$2("system"), constant$2("windows"), constant$2("appManager"), constant$2("layouts"), constant$2("intents"), constant$2("notifications"), constant$2("channels"), constant$2("extension"), constant$2("themes"), constant$2("prefs"), constant$2("ui"));
|
|
2206
2212
|
const windowOperationTypesDecoder = oneOf$1(constant$2("openWindow"), constant$2("windowHello"), constant$2("windowAdded"), constant$2("windowRemoved"), constant$2("getBounds"), constant$2("getFrameBounds"), constant$2("getUrl"), constant$2("moveResize"), constant$2("focus"), constant$2("close"), constant$2("getTitle"), constant$2("setTitle"), constant$2("focusChange"), constant$2("getChannel"), constant$2("notifyChannelsChanged"), constant$2("setZoomFactor"), constant$2("zoomFactorChange"), constant$2("refresh"), constant$2("operationCheck"));
|
|
2207
2213
|
const appManagerOperationTypesDecoder = oneOf$1(constant$2("appHello"), constant$2("appDirectoryStateChange"), constant$2("instanceStarted"), constant$2("instanceStopped"), constant$2("applicationStart"), constant$2("instanceStop"), constant$2("clear"), constant$2("operationCheck"));
|
|
2208
|
-
const layoutsOperationTypesDecoder = oneOf$1(constant$2("layoutAdded"), constant$2("layoutChanged"), constant$2("layoutRemoved"), constant$2("layoutRenamed"), constant$2("get"), constant$2("getAll"), constant$2("export"), constant$2("import"), constant$2("remove"), constant$2("rename"), constant$2("clientSaveRequest"), constant$2("getGlobalPermissionState"), constant$2("checkGlobalActivated"), constant$2("requestGlobalPermission"), constant$2("getDefaultGlobal"), constant$2("setDefaultGlobal"), constant$2("clearDefaultGlobal"), constant$2("updateMetadata"), constant$2("operationCheck"), constant$2("getCurrent"), constant$2("defaultLayoutChanged"), constant$2("layoutRestored"));
|
|
2214
|
+
const layoutsOperationTypesDecoder = oneOf$1(constant$2("layoutAdded"), constant$2("layoutChanged"), constant$2("layoutRemoved"), constant$2("layoutRenamed"), constant$2("get"), constant$2("getAll"), constant$2("getLayoutContents"), constant$2("export"), constant$2("import"), constant$2("remove"), constant$2("rename"), constant$2("clientSaveRequest"), constant$2("getGlobalPermissionState"), constant$2("checkGlobalActivated"), constant$2("requestGlobalPermission"), constant$2("getDefaultGlobal"), constant$2("setDefaultGlobal"), constant$2("clearDefaultGlobal"), constant$2("updateMetadata"), constant$2("operationCheck"), constant$2("getCurrent"), constant$2("defaultLayoutChanged"), constant$2("layoutRestored"));
|
|
2209
2215
|
const notificationsOperationTypesDecoder = oneOf$1(constant$2("raiseNotification"), constant$2("requestPermission"), constant$2("notificationShow"), constant$2("notificationClick"), constant$2("getPermission"), constant$2("list"), constant$2("notificationRaised"), constant$2("notificationClosed"), constant$2("click"), constant$2("clear"), constant$2("clearAll"), constant$2("configure"), constant$2("getConfiguration"), constant$2("configurationChanged"), constant$2("setState"), constant$2("clearOld"), constant$2("activeCountChange"), constant$2("stateChange"), constant$2("operationCheck"), constant$2("getActiveCount"));
|
|
2210
2216
|
const systemOperationTypesDecoder = oneOf$1(constant$2("getEnvironment"), constant$2("getBase"), constant$2("platformShutdown"), constant$2("isFdc3DataWrappingSupported"), constant$2("clientError"), constant$2("systemHello"), constant$2("operationCheck"));
|
|
2211
2217
|
const windowRelativeDirectionDecoder = oneOf$1(constant$2("top"), constant$2("left"), constant$2("right"), constant$2("bottom"));
|
|
@@ -2228,7 +2234,7 @@
|
|
|
2228
2234
|
}));
|
|
2229
2235
|
const openWindowConfigDecoder = object$2({
|
|
2230
2236
|
name: nonEmptyStringDecoder$2,
|
|
2231
|
-
url:
|
|
2237
|
+
url: urlDecoder,
|
|
2232
2238
|
options: windowOpenSettingsDecoder
|
|
2233
2239
|
});
|
|
2234
2240
|
const windowHelloDecoder = object$2({
|
|
@@ -2280,7 +2286,7 @@
|
|
|
2280
2286
|
});
|
|
2281
2287
|
const windowUrlResultDecoder = object$2({
|
|
2282
2288
|
windowId: nonEmptyStringDecoder$2,
|
|
2283
|
-
url:
|
|
2289
|
+
url: urlDecoder
|
|
2284
2290
|
});
|
|
2285
2291
|
const windowZoomFactorConfigDecoder = object$2({
|
|
2286
2292
|
windowId: nonEmptyStringDecoder$2,
|
|
@@ -2300,6 +2306,9 @@
|
|
|
2300
2306
|
const iframePermissionsPolicyConfigDecoder = object$2({
|
|
2301
2307
|
flags: string$2()
|
|
2302
2308
|
});
|
|
2309
|
+
const iframeSandboxConfigDecoder = object$2({
|
|
2310
|
+
flags: string$2()
|
|
2311
|
+
});
|
|
2303
2312
|
const workspacesSandboxDecoder = object$2({
|
|
2304
2313
|
flags: string$2()
|
|
2305
2314
|
});
|
|
@@ -2311,14 +2320,15 @@
|
|
|
2311
2320
|
enabled: boolean$2(),
|
|
2312
2321
|
});
|
|
2313
2322
|
const applicationDetailsDecoder = object$2({
|
|
2314
|
-
url:
|
|
2323
|
+
url: urlDecoder,
|
|
2315
2324
|
top: optional$2(number$2()),
|
|
2316
2325
|
left: optional$2(number$2()),
|
|
2317
2326
|
width: optional$2(nonNegativeNumberDecoder$2),
|
|
2318
2327
|
height: optional$2(nonNegativeNumberDecoder$2),
|
|
2319
2328
|
workspacesSandbox: optional$2(workspacesSandboxDecoder),
|
|
2320
2329
|
channelSelector: optional$2(channelSelectorDecoder$1),
|
|
2321
|
-
iframePermissionsPolicy: optional$2(iframePermissionsPolicyConfigDecoder)
|
|
2330
|
+
iframePermissionsPolicy: optional$2(iframePermissionsPolicyConfigDecoder),
|
|
2331
|
+
iframeSandbox: optional$2(iframeSandboxConfigDecoder)
|
|
2322
2332
|
});
|
|
2323
2333
|
const intentDefinitionDecoder = object$2({
|
|
2324
2334
|
name: nonEmptyStringDecoder$2,
|
|
@@ -2386,7 +2396,7 @@
|
|
|
2386
2396
|
bounds: windowBoundsDecoder,
|
|
2387
2397
|
createArgs: object$2({
|
|
2388
2398
|
name: optional$2(nonEmptyStringDecoder$2),
|
|
2389
|
-
url: optional$2(
|
|
2399
|
+
url: optional$2(urlDecoder),
|
|
2390
2400
|
context: optional$2(anyJson$2())
|
|
2391
2401
|
}),
|
|
2392
2402
|
windowState: optional$2(nonEmptyStringDecoder$2),
|
|
@@ -2410,7 +2420,7 @@
|
|
|
2410
2420
|
type: constant$2("window"),
|
|
2411
2421
|
config: object$2({
|
|
2412
2422
|
appName: nonEmptyStringDecoder$2,
|
|
2413
|
-
url: optional$2(
|
|
2423
|
+
url: optional$2(urlDecoder),
|
|
2414
2424
|
title: optional$2(string$2()),
|
|
2415
2425
|
allowExtract: optional$2(boolean$2()),
|
|
2416
2426
|
allowReorder: optional$2(boolean$2()),
|
|
@@ -2495,6 +2505,17 @@
|
|
|
2495
2505
|
closeMe: optional$2(boolean$2()),
|
|
2496
2506
|
timeout: optional$2(nonNegativeNumberDecoder$2)
|
|
2497
2507
|
});
|
|
2508
|
+
const getContentsOptionsDecoder = object$2({
|
|
2509
|
+
name: nonEmptyStringDecoder$2,
|
|
2510
|
+
type: layoutTypeDecoder
|
|
2511
|
+
});
|
|
2512
|
+
const layoutContentsResultDecoder = object$2({
|
|
2513
|
+
contents: object$2({
|
|
2514
|
+
appComponents: array$2(oneOf$1(windowLayoutComponentDecoder, workspaceLayoutComponentDecoder, workspaceFrameComponentDecoder)),
|
|
2515
|
+
workspaceComponents: array$2(workspaceLayoutComponentStateDecoder),
|
|
2516
|
+
workspaceWindows: array$2(windowLayoutItemDecoder)
|
|
2517
|
+
})
|
|
2518
|
+
});
|
|
2498
2519
|
const layoutSummaryDecoder = object$2({
|
|
2499
2520
|
name: nonEmptyStringDecoder$2,
|
|
2500
2521
|
type: layoutTypeDecoder,
|
|
@@ -2716,10 +2737,10 @@
|
|
|
2716
2737
|
name: optional$2(nonEmptyStringDecoder$2),
|
|
2717
2738
|
fdc3: optional$2(boolean$2())
|
|
2718
2739
|
})));
|
|
2719
|
-
const
|
|
2740
|
+
const leaveChannelsConfigDecoder = oneOf$1(nonEmptyStringDecoder$2, object$2({
|
|
2720
2741
|
windowId: optionalNonEmptyStringDecoder,
|
|
2721
2742
|
channel: optionalNonEmptyStringDecoder
|
|
2722
|
-
});
|
|
2743
|
+
}));
|
|
2723
2744
|
const fdc3ContextDecoder = anyJson$2().where((value) => typeof value.type === "string", "Expected a valid FDC3 Context with compulsory 'type' field");
|
|
2724
2745
|
const interopActionSettingsDecoder = object$2({
|
|
2725
2746
|
method: nonEmptyStringDecoder$2,
|
|
@@ -2873,7 +2894,8 @@
|
|
|
2873
2894
|
sourceFilter: object$2({
|
|
2874
2895
|
allowed: array$2(nonEmptyStringDecoder$2),
|
|
2875
2896
|
blocked: array$2(nonEmptyStringDecoder$2)
|
|
2876
|
-
})
|
|
2897
|
+
}),
|
|
2898
|
+
showNotificationBadge: optional$2(boolean$2())
|
|
2877
2899
|
})
|
|
2878
2900
|
});
|
|
2879
2901
|
const platformSaveRequestConfigDecoder = object$2({
|
|
@@ -3812,7 +3834,7 @@
|
|
|
3812
3834
|
}
|
|
3813
3835
|
async open(name, url, options) {
|
|
3814
3836
|
runDecoderWithIOError(nonEmptyStringDecoder$2, name);
|
|
3815
|
-
runDecoderWithIOError(
|
|
3837
|
+
runDecoderWithIOError(urlDecoder, url);
|
|
3816
3838
|
const settings = runDecoderWithIOError(windowOpenSettingsDecoder, options);
|
|
3817
3839
|
const windowSuccess = await this.bridge.send("windows", operations$a.openWindow, { name, url, options: settings });
|
|
3818
3840
|
return this.waitForWindowAdded(windowSuccess.windowId);
|
|
@@ -4360,7 +4382,12 @@
|
|
|
4360
4382
|
}
|
|
4361
4383
|
getApplication(name) {
|
|
4362
4384
|
const verifiedName = runDecoderWithIOError(nonEmptyStringDecoder$2, name);
|
|
4363
|
-
|
|
4385
|
+
const application = this.applications.find((app) => app.name === verifiedName);
|
|
4386
|
+
const iframeSandbox = application?.userProperties?.details?.iframeSandbox;
|
|
4387
|
+
if (iframeSandbox) {
|
|
4388
|
+
application.userProperties.details.workspacesSandbox = iframeSandbox;
|
|
4389
|
+
}
|
|
4390
|
+
return application;
|
|
4364
4391
|
}
|
|
4365
4392
|
getInstances() {
|
|
4366
4393
|
return this.instances.slice();
|
|
@@ -4670,6 +4697,7 @@
|
|
|
4670
4697
|
layoutRenamed: { name: "layoutRenamed", dataDecoder: renamedLayoutNotificationDecoder },
|
|
4671
4698
|
get: { name: "get", dataDecoder: simpleLayoutConfigDecoder, resultDecoder: optionalSimpleLayoutResult },
|
|
4672
4699
|
getAll: { name: "getAll", dataDecoder: getAllLayoutsConfigDecoder, resultDecoder: allLayoutsSummariesResultDecoder },
|
|
4700
|
+
getLayoutContents: { name: "getLayoutContents", dataDecoder: getContentsOptionsDecoder, resultDecoder: layoutContentsResultDecoder },
|
|
4673
4701
|
export: { name: "export", dataDecoder: getAllLayoutsConfigDecoder, resultDecoder: allLayoutsFullConfigDecoder },
|
|
4674
4702
|
import: { name: "import", dataDecoder: layoutsImportConfigDecoder },
|
|
4675
4703
|
remove: { name: "remove", dataDecoder: simpleLayoutConfigDecoder },
|
|
@@ -4725,6 +4753,7 @@
|
|
|
4725
4753
|
const api = {
|
|
4726
4754
|
get: this.get.bind(this),
|
|
4727
4755
|
getAll: this.getAll.bind(this),
|
|
4756
|
+
getLayoutContents: this.getLayoutContents.bind(this),
|
|
4728
4757
|
getCurrentLayout: this.getCurrentLayout.bind(this),
|
|
4729
4758
|
export: this.exportLayouts.bind(this),
|
|
4730
4759
|
import: this.importLayouts.bind(this),
|
|
@@ -4775,6 +4804,15 @@
|
|
|
4775
4804
|
const result = await this.bridge.send("layouts", operations$8.getAll, { type });
|
|
4776
4805
|
return result.summaries;
|
|
4777
4806
|
}
|
|
4807
|
+
async getLayoutContents(options) {
|
|
4808
|
+
runDecoderWithIOError(getContentsOptionsDecoder, options);
|
|
4809
|
+
const { name, type } = options;
|
|
4810
|
+
if (type !== "Workspace" && type !== "Global") {
|
|
4811
|
+
return ioError.raiseError(`getLayoutContents is only supported for Workspace and Global layouts, but got type "${type}"`);
|
|
4812
|
+
}
|
|
4813
|
+
const result = await this.bridge.send("layouts", operations$8.getLayoutContents, { name, type }, undefined, { includeOperationCheck: true });
|
|
4814
|
+
return result.contents;
|
|
4815
|
+
}
|
|
4778
4816
|
async exportLayouts(type) {
|
|
4779
4817
|
runDecoderWithIOError(layoutTypeDecoder, type);
|
|
4780
4818
|
const result = await this.bridge.send("layouts", operations$8.export, { type });
|
|
@@ -4954,7 +4992,7 @@
|
|
|
4954
4992
|
clear: { name: "clear" },
|
|
4955
4993
|
clearAll: { name: "clearAll" },
|
|
4956
4994
|
clearOld: { name: "clearOld" },
|
|
4957
|
-
configure: { name: "configure", dataDecoder: notificationsConfigurationProtocolDecoder },
|
|
4995
|
+
configure: { name: "configure", dataDecoder: notificationsConfigurationProtocolDecoder, resultDecoder: strictNotificationsConfigurationProtocolDecoder },
|
|
4958
4996
|
getConfiguration: { name: "getConfiguration", resultDecoder: strictNotificationsConfigurationProtocolDecoder },
|
|
4959
4997
|
getActiveCount: { name: "getActiveCount", resultDecoder: activeNotificationsCountChangeDecoder },
|
|
4960
4998
|
configurationChanged: { name: "configurationChanged", resultDecoder: strictNotificationsConfigurationProtocolDecoder },
|
|
@@ -5098,7 +5136,8 @@
|
|
|
5098
5136
|
}
|
|
5099
5137
|
async configure(config) {
|
|
5100
5138
|
const verifiedConfig = runDecoderWithIOError(notificationsConfigurationDecoder, config);
|
|
5101
|
-
await this.bridge.send("notifications", operations$7.configure, { configuration: verifiedConfig }, undefined, { includeOperationCheck: true });
|
|
5139
|
+
const response = await this.bridge.send("notifications", operations$7.configure, { configuration: verifiedConfig }, undefined, { includeOperationCheck: true });
|
|
5140
|
+
return response.configuration;
|
|
5102
5141
|
}
|
|
5103
5142
|
async getConfiguration() {
|
|
5104
5143
|
const response = await this.bridge.send("notifications", operations$7.getConfiguration, undefined, undefined, { includeOperationCheck: true });
|
|
@@ -5754,12 +5793,14 @@
|
|
|
5754
5793
|
return this.changed(callback);
|
|
5755
5794
|
}
|
|
5756
5795
|
async leave(config = {}) {
|
|
5757
|
-
runDecoderWithIOError(
|
|
5758
|
-
|
|
5796
|
+
const decodedConfig = runDecoderWithIOError(leaveChannelsConfigDecoder, config);
|
|
5797
|
+
const channelName = typeof decodedConfig === "string" ? undefined : decodedConfig.channel;
|
|
5798
|
+
const windowId = typeof decodedConfig === "string" ? decodedConfig : decodedConfig.windowId;
|
|
5799
|
+
if (channelName) {
|
|
5759
5800
|
const channelNames = this.getAllChannelNames();
|
|
5760
|
-
runDecoderWithIOError(channelNameDecoder(channelNames),
|
|
5801
|
+
runDecoderWithIOError(channelNameDecoder(channelNames), channelName);
|
|
5761
5802
|
}
|
|
5762
|
-
const leaveData = { channelName
|
|
5803
|
+
const leaveData = { channelName, windowId: windowId ?? this.myWindowId };
|
|
5763
5804
|
await this.bridge.send("channels", operations$5.leaveChannel, leaveData, undefined, { includeOperationCheck: true });
|
|
5764
5805
|
}
|
|
5765
5806
|
async handleAppManagerInitialChannelId(channel) {
|
|
@@ -5973,11 +6014,8 @@
|
|
|
5973
6014
|
}
|
|
5974
6015
|
return channelContext;
|
|
5975
6016
|
}
|
|
5976
|
-
async getMyChannels() {
|
|
5977
|
-
return Promise.all(this.storage.channels.map((channelName) =>
|
|
5978
|
-
const contextName = this.createContextName(channelName);
|
|
5979
|
-
return this.contexts.get(contextName);
|
|
5980
|
-
}));
|
|
6017
|
+
async getMyChannels(options) {
|
|
6018
|
+
return Promise.all(this.storage.channels.map((channelName) => this.get(channelName, options)));
|
|
5981
6019
|
}
|
|
5982
6020
|
myChannels() {
|
|
5983
6021
|
return this.storage.channels;
|
|
@@ -6145,12 +6183,13 @@
|
|
|
6145
6183
|
windowId: restrictions.windowId ?? this.myWindowId
|
|
6146
6184
|
}
|
|
6147
6185
|
};
|
|
6148
|
-
|
|
6186
|
+
await this.bridge.send("channels", operations$5.restrictAll, configData, undefined, { includeOperationCheck: true });
|
|
6149
6187
|
}
|
|
6150
6188
|
async handleRestrictAll({ restrictions }) {
|
|
6151
6189
|
const currentChannel = await this.getMy();
|
|
6152
6190
|
if (!currentChannel) {
|
|
6153
|
-
|
|
6191
|
+
this.updateAllRestrictions(restrictions);
|
|
6192
|
+
return;
|
|
6154
6193
|
}
|
|
6155
6194
|
const prevReadAllowed = this.isAllowedByRestrictions(currentChannel.name, "read");
|
|
6156
6195
|
this.updateAllRestrictions(restrictions);
|
|
@@ -7783,7 +7822,7 @@
|
|
|
7783
7822
|
}
|
|
7784
7823
|
}
|
|
7785
7824
|
|
|
7786
|
-
var version$1 = "4.
|
|
7825
|
+
var version$1 = "4.5.0";
|
|
7787
7826
|
|
|
7788
7827
|
const setupGlobalSystem = (io, bridge) => {
|
|
7789
7828
|
return {
|
|
@@ -9216,9 +9255,9 @@
|
|
|
9216
9255
|
}
|
|
9217
9256
|
}
|
|
9218
9257
|
|
|
9219
|
-
/* @ts-self-types="./index.d.ts" */
|
|
9220
9258
|
let urlAlphabet =
|
|
9221
9259
|
'useandom-26T198340PX75pxJACKVERYMINDBUSHWOLF_GQZbfghjklqvwyzrict';
|
|
9260
|
+
|
|
9222
9261
|
let nanoid = (size = 21) => {
|
|
9223
9262
|
let id = '';
|
|
9224
9263
|
let i = size | 0;
|
|
@@ -9772,6 +9811,10 @@
|
|
|
9772
9811
|
return window.name.substring(0, window.name.indexOf("#wsp"));
|
|
9773
9812
|
}
|
|
9774
9813
|
if (window !== window.top) {
|
|
9814
|
+
const ifrIndex = window.name.indexOf("#ifr");
|
|
9815
|
+
if (ifrIndex !== -1) {
|
|
9816
|
+
return window.name.substring(0, ifrIndex);
|
|
9817
|
+
}
|
|
9775
9818
|
return;
|
|
9776
9819
|
}
|
|
9777
9820
|
if (window.name?.includes("g42")) {
|
|
@@ -10980,7 +11023,7 @@
|
|
|
10980
11023
|
}
|
|
10981
11024
|
};
|
|
10982
11025
|
|
|
10983
|
-
var version = "6.
|
|
11026
|
+
var version = "6.11.0";
|
|
10984
11027
|
|
|
10985
11028
|
/*!
|
|
10986
11029
|
* is-plain-object <https://github.com/jonschlinkert/is-plain-object>
|
|
@@ -15555,7 +15598,7 @@
|
|
|
15555
15598
|
distExports.Traces.currentTracingState = ts;
|
|
15556
15599
|
}
|
|
15557
15600
|
const contextData = this._contextNameToData[name];
|
|
15558
|
-
ts.addData("DIAGNOSTIC", { data
|
|
15601
|
+
ts.addData("DIAGNOSTIC", { data });
|
|
15559
15602
|
ts.injectPropagationInfo(data);
|
|
15560
15603
|
if (!contextData || !contextData.isAnnounced) {
|
|
15561
15604
|
return this.createContext(name, data);
|
|
@@ -15957,6 +16000,10 @@
|
|
|
15957
16000
|
}
|
|
15958
16001
|
}
|
|
15959
16002
|
}
|
|
16003
|
+
const pi = distExports.Traces.extractPropagationInfo(delta, true) ||
|
|
16004
|
+
distExports.Traces.extractPropagationInfo(delta?.added, true) ||
|
|
16005
|
+
distExports.Traces.extractPropagationInfo(delta?.updated, true) ||
|
|
16006
|
+
distExports.Traces.extractPropagationInfo(delta?.reset, true);
|
|
15960
16007
|
for (const updateCallbackIndex in contextData.updateCallbacks) {
|
|
15961
16008
|
if (contextData.updateCallbacks.hasOwnProperty(updateCallbackIndex)) {
|
|
15962
16009
|
try {
|
|
@@ -15966,7 +16013,7 @@
|
|
|
15966
16013
|
...delta.updated,
|
|
15967
16014
|
...delta.reset
|
|
15968
16015
|
});
|
|
15969
|
-
updateCallback(deepClone(contextData.context), deltaArg, delta.removed, parseInt(updateCallbackIndex, 10), extraData,
|
|
16016
|
+
updateCallback(deepClone(contextData.context), deltaArg, delta.removed, parseInt(updateCallbackIndex, 10), extraData, pi);
|
|
15970
16017
|
}
|
|
15971
16018
|
catch (err) {
|
|
15972
16019
|
this._logger.debug("callback error: " + JSON.stringify(err));
|
|
@@ -17079,7 +17126,7 @@
|
|
|
17079
17126
|
/** See `Decoder.succeed` */
|
|
17080
17127
|
Decoder.succeed;
|
|
17081
17128
|
/** See `Decoder.fail` */
|
|
17082
|
-
var fail
|
|
17129
|
+
var fail = Decoder.fail;
|
|
17083
17130
|
/** See `Decoder.lazy` */
|
|
17084
17131
|
Decoder.lazy;
|
|
17085
17132
|
|
|
@@ -17087,7 +17134,7 @@
|
|
|
17087
17134
|
const providedType = typeof input;
|
|
17088
17135
|
return providedType === "function" ?
|
|
17089
17136
|
anyJson() :
|
|
17090
|
-
fail
|
|
17137
|
+
fail(`The provided argument as ${propDescription} should be of type function, provided: ${providedType}`);
|
|
17091
17138
|
};
|
|
17092
17139
|
const nonEmptyStringDecoder = string().where((s) => s.length > 0, "Expected a non-empty string");
|
|
17093
17140
|
const nonNegativeNumberDecoder = number().where((num) => num >= 0, "Expected a non-negative number or 0");
|