stormcloud-video-player 0.8.35 → 0.8.36
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/dist/stormcloud-vp.min.js +1 -1
- package/lib/index.cjs +15 -0
- package/lib/index.cjs.map +1 -1
- package/lib/index.d.cts +19 -19
- package/lib/index.d.ts +19 -19
- package/lib/index.js +15 -0
- package/lib/index.js.map +1 -1
- package/lib/player/AdConfigManager.cjs +18 -0
- package/lib/player/AdConfigManager.cjs.map +1 -1
- package/lib/player/AdConfigManager.d.cts +1 -0
- package/lib/player/StormcloudVideoPlayer.cjs +18 -0
- package/lib/player/StormcloudVideoPlayer.cjs.map +1 -1
- package/lib/players/HlsPlayer.cjs +18 -0
- package/lib/players/HlsPlayer.cjs.map +1 -1
- package/lib/players/index.cjs +18 -0
- package/lib/players/index.cjs.map +1 -1
- package/lib/ui/StormcloudVideoPlayer.cjs +18 -0
- package/lib/ui/StormcloudVideoPlayer.cjs.map +1 -1
- package/package.json +1 -1
package/lib/players/index.cjs
CHANGED
|
@@ -1942,6 +1942,9 @@ var DEFAULT_MQTT_CONFIG = {
|
|
|
1942
1942
|
qos: 1
|
|
1943
1943
|
};
|
|
1944
1944
|
var mqttConfig = _object_spread({}, DEFAULT_MQTT_CONFIG);
|
|
1945
|
+
function applyMQTTConfig(overrides) {
|
|
1946
|
+
Object.assign(mqttConfig, overrides);
|
|
1947
|
+
}
|
|
1945
1948
|
function isMQTTEnabled() {
|
|
1946
1949
|
return mqttConfig.enabled;
|
|
1947
1950
|
}
|
|
@@ -5113,6 +5116,7 @@ var AdConfigManager = /*#__PURE__*/ function() {
|
|
|
5113
5116
|
];
|
|
5114
5117
|
case 4:
|
|
5115
5118
|
data = _state.sent();
|
|
5119
|
+
this.applyMqttConfigFromResponse(data);
|
|
5116
5120
|
imaPayload = (_data_response = data.response) === null || _data_response === void 0 ? void 0 : (_data_response_ima = _data_response.ima) === null || _data_response_ima === void 0 ? void 0 : (_data_response_ima_publisherdeskima = _data_response_ima["publisherdesk.ima"]) === null || _data_response_ima_publisherdeskima === void 0 ? void 0 : _data_response_ima_publisherdeskima.payload;
|
|
5117
5121
|
if (imaPayload) {
|
|
5118
5122
|
decodedPayload = imaPayload;
|
|
@@ -5146,6 +5150,20 @@ var AdConfigManager = /*#__PURE__*/ function() {
|
|
|
5146
5150
|
}).call(this);
|
|
5147
5151
|
}
|
|
5148
5152
|
},
|
|
5153
|
+
{
|
|
5154
|
+
key: "applyMqttConfigFromResponse",
|
|
5155
|
+
value: function applyMqttConfigFromResponse(data) {
|
|
5156
|
+
var _data_response;
|
|
5157
|
+
var mqttConfig2 = (_data_response = data.response) === null || _data_response === void 0 ? void 0 : _data_response.mqtt_config;
|
|
5158
|
+
if (!mqttConfig2 || (typeof mqttConfig2 === "undefined" ? "undefined" : _type_of(mqttConfig2)) !== "object") {
|
|
5159
|
+
return;
|
|
5160
|
+
}
|
|
5161
|
+
applyMQTTConfig(mqttConfig2);
|
|
5162
|
+
if (this.debug) {
|
|
5163
|
+
console.log("[StormcloudVideoPlayer] Applied MQTT config from /ads/web:", mqttConfig2);
|
|
5164
|
+
}
|
|
5165
|
+
}
|
|
5166
|
+
},
|
|
5149
5167
|
{
|
|
5150
5168
|
key: "fetchAndParseVmap",
|
|
5151
5169
|
value: function fetchAndParseVmap(vmapUrl) {
|