@qualtrics/plugin-client
Advanced tools
Comparing version 1.9.0-rc.1943.e70202 to 1.9.2
{ | ||
"name": "@qualtrics/plugin-client", | ||
"version": "1.9.0-rc.1943.e70202", | ||
"version": "1.9.2", | ||
"description": "Interface for XM Plugins to communicate with the environment they're rendered in", | ||
@@ -5,0 +5,0 @@ "scripts": { |
@@ -116,6 +116,6 @@ var __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, generator) { | ||
*/ | ||
MessageChannel.prototype.postMessage = function (name, data, timeout) { | ||
if (timeout === void 0) { timeout = LONG_TIMEOUT; } | ||
return __awaiter(this, void 0, void 0, function () { | ||
MessageChannel.prototype.postMessage = function (name_1, data_1) { | ||
return __awaiter(this, arguments, void 0, function (name, data, timeout) { | ||
var id, messageName, message, timeoutPromise, response; | ||
if (timeout === void 0) { timeout = LONG_TIMEOUT; } | ||
return __generator(this, function (_a) { | ||
@@ -122,0 +122,0 @@ id = "".concat(this.name, ".").concat(this._getMessageId()); |
// Provide configuration that is supplied at build time. | ||
export var getClientVersion = function () { return "1.9.0-rc.1943.e70202"; }; | ||
export var getClientVersion = function () { return "1.9.3-rc.1930.7831db"; }; | ||
//# sourceMappingURL=buildConfig.js.map |
@@ -14,1 +14,4 @@ import * as t from 'io-ts'; | ||
export declare const PluginClientHandlerCollection: t.RecordC<t.StringC, t.Type<Handler, Handler, unknown>>; | ||
export type PluginClientProviderParams = { | ||
messageHandlers: Record<string, Handler>; | ||
}; |
import * as t from 'io-ts'; | ||
import { BaseHandler } from "../../models"; | ||
import { createCodec } from "../../modelUtils"; | ||
import PluginClient from "./pluginClient"; | ||
export var Handler = createCodec('Handler', function (h) { | ||
@@ -6,0 +5,0 @@ return BaseHandler.is(h); |
@@ -70,6 +70,6 @@ var __assign = (this && this.__assign) || function () { | ||
// Factory method. Fetches context before constructing and returning the plugin client. | ||
PluginClient.initialize = function (handlers) { | ||
if (handlers === void 0) { handlers = {}; } | ||
return __awaiter(this, void 0, void 0, function () { | ||
PluginClient.initialize = function () { | ||
return __awaiter(this, arguments, void 0, function (handlers) { | ||
var channel, initMessage, maybeContext, context, pluginClient, getWrappedHandler, _i, _a, name_1; | ||
if (handlers === void 0) { handlers = {}; } | ||
return __generator(this, function (_b) { | ||
@@ -146,6 +146,6 @@ switch (_b.label) { | ||
*/ | ||
PluginClient.prototype.fetch = function (url, fetchConfig, timeout) { | ||
if (timeout === void 0) { timeout = LONG_TIMEOUT; } | ||
return __awaiter(this, void 0, void 0, function () { | ||
PluginClient.prototype.fetch = function (url_1, fetchConfig_1) { | ||
return __awaiter(this, arguments, void 0, function (url, fetchConfig, timeout) { | ||
var fetchMessage; | ||
if (timeout === void 0) { timeout = LONG_TIMEOUT; } | ||
return __generator(this, function (_a) { | ||
@@ -209,6 +209,6 @@ this.validateFetchInput(url, timeout); | ||
*/ | ||
PluginClient.prototype.fetch2 = function (url, fetchConfig, timeout) { | ||
if (timeout === void 0) { timeout = LONG_TIMEOUT; } | ||
return __awaiter(this, void 0, void 0, function () { | ||
PluginClient.prototype.fetch2 = function (url_1, fetchConfig_1) { | ||
return __awaiter(this, arguments, void 0, function (url, fetchConfig, timeout) { | ||
var res, fetchResponse; | ||
if (timeout === void 0) { timeout = LONG_TIMEOUT; } | ||
return __generator(this, function (_a) { | ||
@@ -260,6 +260,6 @@ switch (_a.label) { | ||
*/ | ||
PluginClient.prototype.qualtricsApiFetch = function (url, config, timeout) { | ||
if (timeout === void 0) { timeout = LONG_TIMEOUT; } | ||
return __awaiter(this, void 0, void 0, function () { | ||
PluginClient.prototype.qualtricsApiFetch = function (url_1, config_1) { | ||
return __awaiter(this, arguments, void 0, function (url, config, timeout) { | ||
var qualtricsApiFetchMessage, response; | ||
if (timeout === void 0) { timeout = LONG_TIMEOUT; } | ||
return __generator(this, function (_a) { | ||
@@ -340,6 +340,6 @@ switch (_a.label) { | ||
*/ | ||
PluginClient.prototype.qualtricsApiFetch2 = function (url, config, timeout) { | ||
if (timeout === void 0) { timeout = LONG_TIMEOUT; } | ||
return __awaiter(this, void 0, void 0, function () { | ||
PluginClient.prototype.qualtricsApiFetch2 = function (url_1, config_1) { | ||
return __awaiter(this, arguments, void 0, function (url, config, timeout) { | ||
var res, status, errorMessage, fetchResponse; | ||
if (timeout === void 0) { timeout = LONG_TIMEOUT; } | ||
return __generator(this, function (_a) { | ||
@@ -375,5 +375,5 @@ switch (_a.label) { | ||
}; | ||
PluginClient.prototype.logAmplitudeEvent = function (eventNamespace, eventName, eventData) { | ||
if (eventData === void 0) { eventData = {}; } | ||
return __awaiter(this, void 0, void 0, function () { | ||
PluginClient.prototype.logAmplitudeEvent = function (eventNamespace_1, eventName_1) { | ||
return __awaiter(this, arguments, void 0, function (eventNamespace, eventName, eventData) { | ||
if (eventData === void 0) { eventData = {}; } | ||
return __generator(this, function (_a) { | ||
@@ -380,0 +380,0 @@ return [2 /*return*/, this.channel.postMessage('logAmplitudeEvent', { |
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Major refactor
Supply chain riskPackage has recently undergone a major refactor. It may be unstable or indicate significant internal changes. Use caution when updating to versions that include significant changes.
Found 1 instance in 1 package
No v1
QualityPackage is not semver >=1. This means it is not stable and does not support ^ ranges.
Found 1 instance in 1 package
122882
2046
1
0