@smg-automotive/advertisement-pkg
Advanced tools
Comparing version 1.0.0-talamcol-init-wrapper-077f64560ead224b3bc9ae6aa1bab5611ff9ad7a.1 to 1.0.0-talamcol-init-wrapper-1b4bf3d2aff56c43a92603d4b89d34e288bbf5ec.1
@@ -24,2 +24,32 @@ 'use strict'; | ||
var windowSmgRelevantAdObject = {}; | ||
var relevantLoadPrebidQueuePush = function (_a) { | ||
var _b, _c; | ||
var relevantDigitalConfigId = _a.relevantDigitalConfigId, keywords = _a.keywords, _d = _a.allowedDivIds, allowedDivIds = _d === void 0 ? undefined : _d, _e = _a.noSlotReload, noSlotReload = _e === void 0 ? false : _e; | ||
(_c = (_b = window.relevantDigital) === null || _b === void 0 ? void 0 : _b.cmd) === null || _c === void 0 ? void 0 : _c.push(function () { | ||
var _a; | ||
(_a = window.relevantDigital) === null || _a === void 0 ? void 0 : _a.loadPrebid({ | ||
configId: relevantDigitalConfigId, | ||
manageAdserver: true, | ||
noGpt: true, | ||
noSlotReload: noSlotReload, | ||
allowedDivIds: allowedDivIds, | ||
apntagCalls: { | ||
defineTag: function (tagData) { | ||
var _a; | ||
// pass keywords for non-standalone ad slots | ||
// for standalone we pass keywords direct | ||
tagData.keywords = keywords; | ||
return (_a = window.apntag) === null || _a === void 0 ? void 0 : _a.defineTag(tagData); | ||
}, | ||
}, | ||
}); | ||
}); | ||
}; | ||
var relevantDestroySlots = function () { | ||
var _a; | ||
(_a = window.relevantDigital) === null || _a === void 0 ? void 0 : _a.destroySlots(); | ||
}; | ||
/****************************************************************************** | ||
@@ -80,32 +110,2 @@ Copyright (c) Microsoft Corporation. | ||
var windowSmgRelevantAdObject = {}; | ||
var relevantLoadPrebidQueuePush = function (_a) { | ||
var _b, _c; | ||
var relevantDigitalConfigId = _a.relevantDigitalConfigId, keywords = _a.keywords, _d = _a.allowedDivIds, allowedDivIds = _d === void 0 ? undefined : _d, _e = _a.noSlotReload, noSlotReload = _e === void 0 ? false : _e; | ||
(_c = (_b = window.relevantDigital) === null || _b === void 0 ? void 0 : _b.cmd) === null || _c === void 0 ? void 0 : _c.push(function () { | ||
var _a; | ||
(_a = window.relevantDigital) === null || _a === void 0 ? void 0 : _a.loadPrebid({ | ||
configId: relevantDigitalConfigId, | ||
manageAdserver: true, | ||
noGpt: true, | ||
noSlotReload: noSlotReload, | ||
allowedDivIds: allowedDivIds, | ||
apntagCalls: { | ||
defineTag: function (tagData) { | ||
var _a; | ||
// pass keywords for non-standalone ad slots | ||
// for standalone we pass keywords direct | ||
tagData.keywords = keywords; | ||
return (_a = window.apntag) === null || _a === void 0 ? void 0 : _a.defineTag(tagData); | ||
}, | ||
}, | ||
}); | ||
}); | ||
}; | ||
var relevantDestroySlots = function () { | ||
var _a; | ||
(_a = window.relevantDigital) === null || _a === void 0 ? void 0 : _a.destroySlots(); | ||
}; | ||
var AdContext = React__namespace.createContext(null); | ||
@@ -119,3 +119,2 @@ var useAdContext = function () { | ||
}; | ||
// TODO: add configurable ErrorBoundary: https://github.com/tutti-ch/tutti-web/blob/main/libs/advertisement/src/lib/components/RelevantAdErrorBoundary.tsx | ||
var AdProvider = function (_a) { | ||
@@ -143,6 +142,3 @@ var children = _a.children, rest = __rest(_a, ["children"]); | ||
relevantLoadPrebidQueuePush({ | ||
// TODO: remove after Ad-Server A/B test is ended | ||
// TODO: check with Tutti why and if still needed | ||
// not by our key-value naming nomenclature, as Xandr already set it that way. | ||
keywords: __assign({}, keywords), | ||
keywords: keywords, | ||
relevantDigitalConfigId: relevantDigitalConfigId, | ||
@@ -466,6 +462,3 @@ }); | ||
relevantLoadPrebidQueuePush({ | ||
// TODO: remove after Ad-Server A/B test is ended | ||
// TODO: check with Tutti why and if still needed | ||
// not by our key-value naming nomenclature, as Xandr already set it that way. | ||
keywords: __assign({}, keywords), | ||
keywords: keywords, | ||
allowedDivIds: [id], | ||
@@ -472,0 +465,0 @@ noSlotReload: true, |
@@ -1,2 +0,2 @@ | ||
import type { NativeAdComponentProps } from './types/ads'; | ||
import type { KeyValues, NativeAdComponentProps } from './types/ads'; | ||
import useRelevantDigital from './hooks/useRelevantDigital'; | ||
@@ -6,2 +6,2 @@ import { AdProvider } from './contexts/Ad'; | ||
export { AdProvider, AdSlot, useRelevantDigital }; | ||
export type { AdSlotProps, NativeAdComponentProps }; | ||
export type { AdSlotProps, NativeAdComponentProps, KeyValues }; |
import * as React from 'react'; | ||
import { useState, useEffect } from 'react'; | ||
var windowSmgRelevantAdObject = {}; | ||
var relevantLoadPrebidQueuePush = function (_a) { | ||
var _b, _c; | ||
var relevantDigitalConfigId = _a.relevantDigitalConfigId, keywords = _a.keywords, _d = _a.allowedDivIds, allowedDivIds = _d === void 0 ? undefined : _d, _e = _a.noSlotReload, noSlotReload = _e === void 0 ? false : _e; | ||
(_c = (_b = window.relevantDigital) === null || _b === void 0 ? void 0 : _b.cmd) === null || _c === void 0 ? void 0 : _c.push(function () { | ||
var _a; | ||
(_a = window.relevantDigital) === null || _a === void 0 ? void 0 : _a.loadPrebid({ | ||
configId: relevantDigitalConfigId, | ||
manageAdserver: true, | ||
noGpt: true, | ||
noSlotReload: noSlotReload, | ||
allowedDivIds: allowedDivIds, | ||
apntagCalls: { | ||
defineTag: function (tagData) { | ||
var _a; | ||
// pass keywords for non-standalone ad slots | ||
// for standalone we pass keywords direct | ||
tagData.keywords = keywords; | ||
return (_a = window.apntag) === null || _a === void 0 ? void 0 : _a.defineTag(tagData); | ||
}, | ||
}, | ||
}); | ||
}); | ||
}; | ||
var relevantDestroySlots = function () { | ||
var _a; | ||
(_a = window.relevantDigital) === null || _a === void 0 ? void 0 : _a.destroySlots(); | ||
}; | ||
/****************************************************************************** | ||
@@ -59,32 +89,2 @@ Copyright (c) Microsoft Corporation. | ||
var windowSmgRelevantAdObject = {}; | ||
var relevantLoadPrebidQueuePush = function (_a) { | ||
var _b, _c; | ||
var relevantDigitalConfigId = _a.relevantDigitalConfigId, keywords = _a.keywords, _d = _a.allowedDivIds, allowedDivIds = _d === void 0 ? undefined : _d, _e = _a.noSlotReload, noSlotReload = _e === void 0 ? false : _e; | ||
(_c = (_b = window.relevantDigital) === null || _b === void 0 ? void 0 : _b.cmd) === null || _c === void 0 ? void 0 : _c.push(function () { | ||
var _a; | ||
(_a = window.relevantDigital) === null || _a === void 0 ? void 0 : _a.loadPrebid({ | ||
configId: relevantDigitalConfigId, | ||
manageAdserver: true, | ||
noGpt: true, | ||
noSlotReload: noSlotReload, | ||
allowedDivIds: allowedDivIds, | ||
apntagCalls: { | ||
defineTag: function (tagData) { | ||
var _a; | ||
// pass keywords for non-standalone ad slots | ||
// for standalone we pass keywords direct | ||
tagData.keywords = keywords; | ||
return (_a = window.apntag) === null || _a === void 0 ? void 0 : _a.defineTag(tagData); | ||
}, | ||
}, | ||
}); | ||
}); | ||
}; | ||
var relevantDestroySlots = function () { | ||
var _a; | ||
(_a = window.relevantDigital) === null || _a === void 0 ? void 0 : _a.destroySlots(); | ||
}; | ||
var AdContext = React.createContext(null); | ||
@@ -98,3 +98,2 @@ var useAdContext = function () { | ||
}; | ||
// TODO: add configurable ErrorBoundary: https://github.com/tutti-ch/tutti-web/blob/main/libs/advertisement/src/lib/components/RelevantAdErrorBoundary.tsx | ||
var AdProvider = function (_a) { | ||
@@ -122,6 +121,3 @@ var children = _a.children, rest = __rest(_a, ["children"]); | ||
relevantLoadPrebidQueuePush({ | ||
// TODO: remove after Ad-Server A/B test is ended | ||
// TODO: check with Tutti why and if still needed | ||
// not by our key-value naming nomenclature, as Xandr already set it that way. | ||
keywords: __assign({}, keywords), | ||
keywords: keywords, | ||
relevantDigitalConfigId: relevantDigitalConfigId, | ||
@@ -445,6 +441,3 @@ }); | ||
relevantLoadPrebidQueuePush({ | ||
// TODO: remove after Ad-Server A/B test is ended | ||
// TODO: check with Tutti why and if still needed | ||
// not by our key-value naming nomenclature, as Xandr already set it that way. | ||
keywords: __assign({}, keywords), | ||
keywords: keywords, | ||
allowedDivIds: [id], | ||
@@ -451,0 +444,0 @@ noSlotReload: true, |
@@ -1,2 +0,2 @@ | ||
import type { NativeAdComponentProps } from './types/ads'; | ||
import type { KeyValues, NativeAdComponentProps } from './types/ads'; | ||
import useRelevantDigital from './hooks/useRelevantDigital'; | ||
@@ -6,2 +6,2 @@ import { AdProvider } from './contexts/Ad'; | ||
export { AdProvider, AdSlot, useRelevantDigital }; | ||
export type { AdSlotProps, NativeAdComponentProps }; | ||
export type { AdSlotProps, NativeAdComponentProps, KeyValues }; |
@@ -104,2 +104,2 @@ import * as React from 'react'; | ||
export { AdProvider, AdSlot, type AdSlotProps, type NativeAdComponentProps, useRelevantDigital }; | ||
export { AdProvider, AdSlot, type AdSlotProps, type KeyValues, type NativeAdComponentProps, useRelevantDigital }; |
{ | ||
"name": "@smg-automotive/advertisement-pkg", | ||
"version": "1.0.0-talamcol-init-wrapper-077f64560ead224b3bc9ae6aa1bab5611ff9ad7a.1", | ||
"version": "1.0.0-talamcol-init-wrapper-1b4bf3d2aff56c43a92603d4b89d34e288bbf5ec.1", | ||
"description": "Contains Relevant Digital Header Bidding Wrapper for advertisements", | ||
@@ -5,0 +5,0 @@ "main": "dist/cjs/index.js", |
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
158361
1415