@brndts/brndts-ads 1.13.18 → 1.13.20
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/index.js +9 -3
- package/dist/index.js.map +1 -1
- package/dist/index.mjs +9 -3
- package/dist/index.mjs.map +1 -1
- package/package.json +1 -1
package/dist/index.mjs
CHANGED
@@ -70938,7 +70938,7 @@ var PrebidGAMProvider = /*#__PURE__*/ function(ContentProvider1) {
|
|
70938
70938
|
PrebidGAMEventsInstance.onSlotRenderEnd(function(event) {
|
70939
70939
|
var slot = event.slot;
|
70940
70940
|
if ("".concat(_this.workingSlotId) === event.slot.getSlotElementId()) {
|
70941
|
-
var _this_content_extra_sz, _this_content_extra_sz1;
|
70941
|
+
var _event_size, _this_content_extra_sz, _event_size1, _this_content_extra_sz1;
|
70942
70942
|
if (!_this.content.extra) {
|
70943
70943
|
_this.content.extra = {};
|
70944
70944
|
}
|
@@ -70949,8 +70949,8 @@ var PrebidGAMProvider = /*#__PURE__*/ function(ContentProvider1) {
|
|
70949
70949
|
_this.content.extra.bidder = slot.getTargeting("hb_bidder")[0];
|
70950
70950
|
}
|
70951
70951
|
_this.content.extra.sz = {
|
70952
|
-
w: event.size[0] || ((_this_content_extra_sz = _this.content.extra.sz) === null || _this_content_extra_sz === void 0 ? void 0 : _this_content_extra_sz.w) || 0,
|
70953
|
-
h: event.size[1] || ((_this_content_extra_sz1 = _this.content.extra.sz) === null || _this_content_extra_sz1 === void 0 ? void 0 : _this_content_extra_sz1.h) || 0
|
70952
|
+
w: ((_event_size = event.size) === null || _event_size === void 0 ? void 0 : _event_size[0]) || ((_this_content_extra_sz = _this.content.extra.sz) === null || _this_content_extra_sz === void 0 ? void 0 : _this_content_extra_sz.w) || 0,
|
70953
|
+
h: ((_event_size1 = event.size) === null || _event_size1 === void 0 ? void 0 : _event_size1[1]) || ((_this_content_extra_sz1 = _this.content.extra.sz) === null || _this_content_extra_sz1 === void 0 ? void 0 : _this_content_extra_sz1.h) || 0
|
70954
70954
|
};
|
70955
70955
|
_this.content.pending = false;
|
70956
70956
|
_this.fullfill();
|
@@ -74398,6 +74398,9 @@ var BradmaxMediaElement = /*#__PURE__*/ function(GenericMediaElement) {
|
|
74398
74398
|
}(GenericMediaElement);
|
74399
74399
|
// src/Ads/VideoAds/Media/DailymotionMediaElement.ts
|
74400
74400
|
var URLMatch = /^https:\/\/geo\.dailymotion\.com\/player(?:\/[a-zA-Z0-9]+)?\.html\?video=([a-zA-Z0-9]+)/;
|
74401
|
+
function generateId2(prefix) {
|
74402
|
+
return "".concat(prefix, "-").concat(Math.floor(Math.random() * 1e4));
|
74403
|
+
}
|
74401
74404
|
function aspectRatioToNumber(ratioString) {
|
74402
74405
|
var parts2 = ratioString.split(":");
|
74403
74406
|
if (parts2.length !== 2) {
|
@@ -74576,6 +74579,9 @@ var DailymotionMediaElement = /*#__PURE__*/ function(GenericMediaElement) {
|
|
74576
74579
|
key: "setMediaElement",
|
74577
74580
|
value: function setMediaElement(target) {
|
74578
74581
|
var _this = this;
|
74582
|
+
if (!target.id) {
|
74583
|
+
target.id = generateId2("brndts-dailymotion");
|
74584
|
+
}
|
74579
74585
|
this.context.logger.log("Checking DM API");
|
74580
74586
|
if (is_default.object(window.dailymotion)) {
|
74581
74587
|
this.context.logger.log("DM API is already loaded");
|