@everymatrix/promoting-banners 0.2.6 → 0.4.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/dist/cjs/{index-40277d4b.js → index-ee39fac4.js} +164 -69
- package/dist/cjs/index.cjs.js +2 -2
- package/dist/cjs/loader.cjs.js +1 -1
- package/dist/cjs/{promoting-banners-d707e229.js → promoting-banners-dc9b6beb.js} +28 -11
- package/dist/cjs/promoting-banners.cjs.entry.js +2 -2
- package/dist/cjs/promoting-banners.cjs.js +2 -2
- package/dist/collection/collection-manifest.json +1 -1
- package/dist/collection/components/promoting-banners/promoting-banners.js +39 -10
- package/dist/esm/{index-936cf61c.js → index-16676b7c.js} +164 -69
- package/dist/esm/index.js +2 -2
- package/dist/esm/loader.js +2 -2
- package/dist/esm/{promoting-banners-10e80966.js → promoting-banners-28e68ad2.js} +28 -11
- package/dist/esm/promoting-banners.entry.js +2 -2
- package/dist/esm/promoting-banners.js +3 -3
- package/dist/promoting-banners/index.esm.js +1 -1
- package/dist/promoting-banners/p-8ba44572.js +2 -0
- package/dist/promoting-banners/p-a67a8c19.js +1 -0
- package/dist/promoting-banners/p-ccda9449.entry.js +1 -0
- package/dist/promoting-banners/promoting-banners.esm.js +1 -1
- package/dist/types/builds/emfe-widgets/widgets-monorepo/packages/stencil/promoting-banners/.stencil/packages/stencil/promoting-banners/stencil.config.d.ts +2 -0
- package/dist/types/builds/emfe-widgets/widgets-monorepo/packages/stencil/promoting-banners/.stencil/packages/stencil/promoting-banners/stencil.config.dev.d.ts +2 -0
- package/package.json +1 -1
- package/dist/promoting-banners/p-53a1c74c.js +0 -1
- package/dist/promoting-banners/p-7f9296a7.entry.js +0 -1
- package/dist/promoting-banners/p-a3d905a8.js +0 -2
- package/dist/types/Users/adrian.pripon/Documents/Work/widgets-monorepo/packages/stencil/promoting-banners/.stencil/packages/stencil/promoting-banners/stencil.config.d.ts +0 -2
- package/dist/types/Users/adrian.pripon/Documents/Work/widgets-monorepo/packages/stencil/promoting-banners/.stencil/packages/stencil/promoting-banners/stencil.config.dev.d.ts +0 -2
|
@@ -21,19 +21,23 @@ function _interopNamespace(e) {
|
|
|
21
21
|
}
|
|
22
22
|
|
|
23
23
|
const NAMESPACE = 'promoting-banners';
|
|
24
|
-
const BUILD = /* promoting-banners */ { allRenderFn: true, appendChildSlotFix: false, asyncLoading: true, asyncQueue: false, attachStyles: true, cloneNodeFix: false, cmpDidLoad: false, cmpDidRender: false, cmpDidUnload: false, cmpDidUpdate: false, cmpShouldUpdate: false, cmpWillLoad: true, cmpWillRender: false, cmpWillUpdate: false, connectedCallback: true, constructableCSS: true, cssAnnotations: true, devTools: false, disconnectedCallback: false, element: false, event: false, experimentalScopedSlotChanges: false, experimentalSlotFixes: false, formAssociated: false, hasRenderFn: true, hostListener: false, hostListenerTarget: false, hostListenerTargetBody: false, hostListenerTargetDocument: false, hostListenerTargetParent: false, hostListenerTargetWindow: false, hotModuleReplacement: false, hydrateClientSide: false, hydrateServerSide: false, hydratedAttribute: false, hydratedClass: true, hydratedSelectorName: "hydrated", initializeNextTick: false, invisiblePrehydration: true, isDebug: false, isDev: false, isTesting: false, lazyLoad: true, lifecycle: true, lifecycleDOMEvents: false, member: true, method: false, mode: false, observeAttribute: true, profile: false, prop: true, propBoolean: false, propMutable: false, propNumber: false, propString: true, reflect: true, scoped: false, scopedSlotTextContentFix: false, scriptDataOpts: false, shadowDelegatesFocus: false, shadowDom: true, slot: false, slotChildNodesFix: false, slotRelocation: false, state: true, style: true, svg: false, taskQueue: true, transformTagName: false, updatable: true, vdomAttribute: true, vdomClass: true, vdomFunctional: false, vdomKey: true, vdomListener: true, vdomPropOrAttr: true, vdomRef: true, vdomRender: true, vdomStyle: true, vdomText: true, vdomXlink: false, watchCallback: true };
|
|
24
|
+
const BUILD = /* promoting-banners */ { allRenderFn: true, appendChildSlotFix: false, asyncLoading: true, asyncQueue: false, attachStyles: true, cloneNodeFix: false, cmpDidLoad: false, cmpDidRender: false, cmpDidUnload: false, cmpDidUpdate: false, cmpShouldUpdate: false, cmpWillLoad: true, cmpWillRender: false, cmpWillUpdate: false, connectedCallback: true, constructableCSS: true, cssAnnotations: true, devTools: false, disconnectedCallback: false, element: false, event: false, experimentalScopedSlotChanges: false, experimentalSlotFixes: false, formAssociated: false, hasRenderFn: true, hostListener: false, hostListenerTarget: false, hostListenerTargetBody: false, hostListenerTargetDocument: false, hostListenerTargetParent: false, hostListenerTargetWindow: false, hotModuleReplacement: false, hydrateClientSide: false, hydrateServerSide: false, hydratedAttribute: false, hydratedClass: true, hydratedSelectorName: "hydrated", initializeNextTick: false, invisiblePrehydration: true, isDebug: false, isDev: false, isTesting: false, lazyLoad: true, lifecycle: true, lifecycleDOMEvents: false, member: true, method: false, mode: false, modernPropertyDecls: false, observeAttribute: true, profile: false, prop: true, propBoolean: false, propMutable: false, propNumber: false, propString: true, reflect: true, scoped: false, scopedSlotTextContentFix: false, scriptDataOpts: false, shadowDelegatesFocus: false, shadowDom: true, slot: false, slotChildNodesFix: false, slotRelocation: false, state: true, style: true, svg: false, taskQueue: true, transformTagName: false, updatable: true, vdomAttribute: true, vdomClass: true, vdomFunctional: false, vdomKey: true, vdomListener: true, vdomPropOrAttr: true, vdomRef: true, vdomRender: true, vdomStyle: true, vdomText: true, vdomXlink: false, watchCallback: true };
|
|
25
25
|
|
|
26
26
|
/*
|
|
27
|
-
Stencil Client Platform v4.
|
|
27
|
+
Stencil Client Platform v4.25.1 | MIT Licensed | https://stenciljs.com
|
|
28
28
|
*/
|
|
29
29
|
var __defProp = Object.defineProperty;
|
|
30
30
|
var __export = (target, all) => {
|
|
31
31
|
for (var name in all)
|
|
32
32
|
__defProp(target, name, { get: all[name], enumerable: true });
|
|
33
33
|
};
|
|
34
|
+
|
|
35
|
+
// src/client/client-host-ref.ts
|
|
34
36
|
var hostRefs = /* @__PURE__ */ new WeakMap();
|
|
35
37
|
var getHostRef = (ref) => hostRefs.get(ref);
|
|
36
|
-
var registerInstance = (lazyInstance, hostRef) =>
|
|
38
|
+
var registerInstance = (lazyInstance, hostRef) => {
|
|
39
|
+
hostRefs.set(hostRef.$lazyInstance$ = lazyInstance, hostRef);
|
|
40
|
+
};
|
|
37
41
|
var registerHost = (hostElement, cmpMeta) => {
|
|
38
42
|
const hostRef = {
|
|
39
43
|
$flags$: 0,
|
|
@@ -46,7 +50,8 @@ var registerHost = (hostElement, cmpMeta) => {
|
|
|
46
50
|
hostElement["s-p"] = [];
|
|
47
51
|
hostElement["s-rc"] = [];
|
|
48
52
|
}
|
|
49
|
-
|
|
53
|
+
const ref = hostRefs.set(hostElement, hostRef);
|
|
54
|
+
return ref;
|
|
50
55
|
};
|
|
51
56
|
var isMemberInElement = (elm, memberName) => memberName in elm;
|
|
52
57
|
var consoleError = (e, el) => (0, console.error)(e, el);
|
|
@@ -83,16 +88,22 @@ var loadModule = (cmpMeta, hostRef, hmrVersionId) => {
|
|
|
83
88
|
/* webpackExclude: /\.system\.entry\.js$/ */
|
|
84
89
|
/* webpackMode: "lazy" */
|
|
85
90
|
`./${bundleId}.entry.js${""}`
|
|
86
|
-
)); }).then(
|
|
87
|
-
{
|
|
88
|
-
|
|
91
|
+
)); }).then(
|
|
92
|
+
(importedModule) => {
|
|
93
|
+
{
|
|
94
|
+
cmpModules.set(bundleId, importedModule);
|
|
95
|
+
}
|
|
96
|
+
return importedModule[exportName];
|
|
97
|
+
},
|
|
98
|
+
(e) => {
|
|
99
|
+
consoleError(e, hostRef.$hostElement$);
|
|
89
100
|
}
|
|
90
|
-
|
|
91
|
-
}, consoleError);
|
|
101
|
+
);
|
|
92
102
|
};
|
|
93
103
|
|
|
94
104
|
// src/client/client-style.ts
|
|
95
105
|
var styles = /* @__PURE__ */ new Map();
|
|
106
|
+
var HYDRATED_STYLE_ID = "sty-id";
|
|
96
107
|
var HYDRATED_CSS = "{visibility:hidden}.hydrated{visibility:inherit}";
|
|
97
108
|
var SLOT_FB_CSS = "slot-fb{display:contents}slot-fb[hidden]{display:none}";
|
|
98
109
|
var win = typeof window !== "undefined" ? window : {};
|
|
@@ -150,12 +161,6 @@ var flush = () => {
|
|
|
150
161
|
};
|
|
151
162
|
var nextTick = (cb) => promiseResolve().then(cb);
|
|
152
163
|
var writeTask = /* @__PURE__ */ queueTask(queueDomWrites, true);
|
|
153
|
-
|
|
154
|
-
// src/utils/constants.ts
|
|
155
|
-
var EMPTY_OBJ = {};
|
|
156
|
-
|
|
157
|
-
// src/utils/helpers.ts
|
|
158
|
-
var isDef = (v) => v != null;
|
|
159
164
|
var isComplexType = (o) => {
|
|
160
165
|
o = typeof o;
|
|
161
166
|
return o === "object" || o === "function";
|
|
@@ -337,7 +342,7 @@ var addStyle = (styleContainerNode, cmpMeta, mode) => {
|
|
|
337
342
|
}
|
|
338
343
|
if (!appliedStyles.has(scopeId2)) {
|
|
339
344
|
{
|
|
340
|
-
styleElm = doc.createElement("style");
|
|
345
|
+
styleElm = document.querySelector(`[${HYDRATED_STYLE_ID}="${scopeId2}"]`) || doc.createElement("style");
|
|
341
346
|
styleElm.innerHTML = style;
|
|
342
347
|
const nonce = (_a = plt.$nonce$) != null ? _a : queryNonceMetaTagContent(doc);
|
|
343
348
|
if (nonce != null) {
|
|
@@ -347,7 +352,10 @@ var addStyle = (styleContainerNode, cmpMeta, mode) => {
|
|
|
347
352
|
if (styleContainerNode.nodeName === "HEAD") {
|
|
348
353
|
const preconnectLinks = styleContainerNode.querySelectorAll("link[rel=preconnect]");
|
|
349
354
|
const referenceNode2 = preconnectLinks.length > 0 ? preconnectLinks[preconnectLinks.length - 1].nextSibling : styleContainerNode.querySelector("style");
|
|
350
|
-
styleContainerNode.insertBefore(
|
|
355
|
+
styleContainerNode.insertBefore(
|
|
356
|
+
styleElm,
|
|
357
|
+
(referenceNode2 == null ? void 0 : referenceNode2.parentNode) === styleContainerNode ? referenceNode2 : null
|
|
358
|
+
);
|
|
351
359
|
} else if ("host" in styleContainerNode) {
|
|
352
360
|
if (supportsConstructableStylesheets) {
|
|
353
361
|
const stylesheet = new CSSStyleSheet();
|
|
@@ -397,16 +405,18 @@ var attachStyles = (hostRef) => {
|
|
|
397
405
|
endAttachStyles();
|
|
398
406
|
};
|
|
399
407
|
var getScopeId = (cmp, mode) => "sc-" + (cmp.$tagName$);
|
|
400
|
-
var setAccessor = (elm, memberName, oldValue, newValue, isSvg, flags) => {
|
|
408
|
+
var setAccessor = (elm, memberName, oldValue, newValue, isSvg, flags, initialRender) => {
|
|
401
409
|
if (oldValue !== newValue) {
|
|
402
410
|
let isProp = isMemberInElement(elm, memberName);
|
|
403
411
|
let ln = memberName.toLowerCase();
|
|
404
412
|
if (memberName === "class") {
|
|
405
413
|
const classList = elm.classList;
|
|
406
414
|
const oldClasses = parseClassList(oldValue);
|
|
407
|
-
|
|
408
|
-
|
|
409
|
-
|
|
415
|
+
let newClasses = parseClassList(newValue);
|
|
416
|
+
{
|
|
417
|
+
classList.remove(...oldClasses.filter((c) => c && !newClasses.includes(c)));
|
|
418
|
+
classList.add(...newClasses.filter((c) => c && !oldClasses.includes(c)));
|
|
419
|
+
}
|
|
410
420
|
} else if (memberName === "style") {
|
|
411
421
|
{
|
|
412
422
|
for (const prop in oldValue) {
|
|
@@ -465,7 +475,7 @@ var setAccessor = (elm, memberName, oldValue, newValue, isSvg, flags) => {
|
|
|
465
475
|
elm.setAttribute(memberName, n);
|
|
466
476
|
}
|
|
467
477
|
}
|
|
468
|
-
} else {
|
|
478
|
+
} else if (elm[memberName] !== newValue) {
|
|
469
479
|
elm[memberName] = newValue;
|
|
470
480
|
}
|
|
471
481
|
} catch (e) {
|
|
@@ -487,24 +497,44 @@ var setAccessor = (elm, memberName, oldValue, newValue, isSvg, flags) => {
|
|
|
487
497
|
}
|
|
488
498
|
};
|
|
489
499
|
var parseClassListRegex = /\s/;
|
|
490
|
-
var parseClassList = (value) =>
|
|
500
|
+
var parseClassList = (value) => {
|
|
501
|
+
if (typeof value === "object" && value && "baseVal" in value) {
|
|
502
|
+
value = value.baseVal;
|
|
503
|
+
}
|
|
504
|
+
if (!value || typeof value !== "string") {
|
|
505
|
+
return [];
|
|
506
|
+
}
|
|
507
|
+
return value.split(parseClassListRegex);
|
|
508
|
+
};
|
|
491
509
|
var CAPTURE_EVENT_SUFFIX = "Capture";
|
|
492
510
|
var CAPTURE_EVENT_REGEX = new RegExp(CAPTURE_EVENT_SUFFIX + "$");
|
|
493
511
|
|
|
494
512
|
// src/runtime/vdom/update-element.ts
|
|
495
|
-
var updateElement = (oldVnode, newVnode, isSvgMode2) => {
|
|
513
|
+
var updateElement = (oldVnode, newVnode, isSvgMode2, isInitialRender) => {
|
|
496
514
|
const elm = newVnode.$elm$.nodeType === 11 /* DocumentFragment */ && newVnode.$elm$.host ? newVnode.$elm$.host : newVnode.$elm$;
|
|
497
|
-
const oldVnodeAttrs = oldVnode && oldVnode.$attrs$ ||
|
|
498
|
-
const newVnodeAttrs = newVnode.$attrs$ ||
|
|
515
|
+
const oldVnodeAttrs = oldVnode && oldVnode.$attrs$ || {};
|
|
516
|
+
const newVnodeAttrs = newVnode.$attrs$ || {};
|
|
499
517
|
{
|
|
500
518
|
for (const memberName of sortedAttrNames(Object.keys(oldVnodeAttrs))) {
|
|
501
519
|
if (!(memberName in newVnodeAttrs)) {
|
|
502
|
-
setAccessor(
|
|
520
|
+
setAccessor(
|
|
521
|
+
elm,
|
|
522
|
+
memberName,
|
|
523
|
+
oldVnodeAttrs[memberName],
|
|
524
|
+
void 0,
|
|
525
|
+
isSvgMode2,
|
|
526
|
+
newVnode.$flags$);
|
|
503
527
|
}
|
|
504
528
|
}
|
|
505
529
|
}
|
|
506
530
|
for (const memberName of sortedAttrNames(Object.keys(newVnodeAttrs))) {
|
|
507
|
-
setAccessor(
|
|
531
|
+
setAccessor(
|
|
532
|
+
elm,
|
|
533
|
+
memberName,
|
|
534
|
+
oldVnodeAttrs[memberName],
|
|
535
|
+
newVnodeAttrs[memberName],
|
|
536
|
+
isSvgMode2,
|
|
537
|
+
newVnode.$flags$);
|
|
508
538
|
}
|
|
509
539
|
};
|
|
510
540
|
function sortedAttrNames(attrNames) {
|
|
@@ -516,13 +546,10 @@ function sortedAttrNames(attrNames) {
|
|
|
516
546
|
attrNames
|
|
517
547
|
);
|
|
518
548
|
}
|
|
519
|
-
|
|
520
|
-
// src/runtime/vdom/vdom-render.ts
|
|
521
|
-
var scopeId;
|
|
522
549
|
var hostTagName;
|
|
523
550
|
var useNativeShadowDom = false;
|
|
524
551
|
var isSvgMode = false;
|
|
525
|
-
var createElm = (oldParentVNode, newParentVNode, childIndex
|
|
552
|
+
var createElm = (oldParentVNode, newParentVNode, childIndex) => {
|
|
526
553
|
const newVNode2 = newParentVNode.$children$[childIndex];
|
|
527
554
|
let i2 = 0;
|
|
528
555
|
let elm;
|
|
@@ -536,11 +563,6 @@ var createElm = (oldParentVNode, newParentVNode, childIndex, parentElm) => {
|
|
|
536
563
|
{
|
|
537
564
|
updateElement(null, newVNode2, isSvgMode);
|
|
538
565
|
}
|
|
539
|
-
const rootNode = elm.getRootNode();
|
|
540
|
-
const isElementWithinShadowRoot = !rootNode.querySelector("body");
|
|
541
|
-
if (!isElementWithinShadowRoot && BUILD.scoped && isDef(scopeId) && elm["s-si"] !== scopeId) {
|
|
542
|
-
elm.classList.add(elm["s-si"] = scopeId);
|
|
543
|
-
}
|
|
544
566
|
if (newVNode2.$children$) {
|
|
545
567
|
for (i2 = 0; i2 < newVNode2.$children$.length; ++i2) {
|
|
546
568
|
childNode = createElm(oldParentVNode, newVNode2, i2);
|
|
@@ -670,6 +692,9 @@ var isSameVnode = (leftVNode, rightVNode, isInitialRender = false) => {
|
|
|
670
692
|
if (!isInitialRender) {
|
|
671
693
|
return leftVNode.$key$ === rightVNode.$key$;
|
|
672
694
|
}
|
|
695
|
+
if (isInitialRender && !leftVNode.$key$ && rightVNode.$key$) {
|
|
696
|
+
leftVNode.$key$ = rightVNode.$key$;
|
|
697
|
+
}
|
|
673
698
|
return true;
|
|
674
699
|
}
|
|
675
700
|
return false;
|
|
@@ -709,8 +734,9 @@ var nullifyVNodeRefs = (vNode) => {
|
|
|
709
734
|
}
|
|
710
735
|
};
|
|
711
736
|
var insertBefore = (parent, newNode, reference) => {
|
|
712
|
-
|
|
713
|
-
|
|
737
|
+
{
|
|
738
|
+
return parent == null ? void 0 : parent.insertBefore(newNode, reference);
|
|
739
|
+
}
|
|
714
740
|
};
|
|
715
741
|
var renderVdom = (hostRef, renderFnResults, isInitialLoad = false) => {
|
|
716
742
|
const hostElm = hostRef.$hostElement$;
|
|
@@ -735,9 +761,6 @@ var renderVdom = (hostRef, renderFnResults, isInitialLoad = false) => {
|
|
|
735
761
|
rootVnode.$flags$ |= 4 /* isHost */;
|
|
736
762
|
hostRef.$vnode$ = rootVnode;
|
|
737
763
|
rootVnode.$elm$ = oldVNode.$elm$ = hostElm.shadowRoot || hostElm ;
|
|
738
|
-
{
|
|
739
|
-
scopeId = hostElm["s-sc"];
|
|
740
|
-
}
|
|
741
764
|
useNativeShadowDom = (cmpMeta.$flags$ & 1 /* shadowDomEncapsulation */) !== 0;
|
|
742
765
|
patch(oldVNode, rootVnode, isInitialLoad);
|
|
743
766
|
};
|
|
@@ -745,7 +768,14 @@ var renderVdom = (hostRef, renderFnResults, isInitialLoad = false) => {
|
|
|
745
768
|
// src/runtime/update-component.ts
|
|
746
769
|
var attachToAncestor = (hostRef, ancestorComponent) => {
|
|
747
770
|
if (ancestorComponent && !hostRef.$onRenderResolve$ && ancestorComponent["s-p"]) {
|
|
748
|
-
ancestorComponent["s-p"].push(
|
|
771
|
+
const index = ancestorComponent["s-p"].push(
|
|
772
|
+
new Promise(
|
|
773
|
+
(r) => hostRef.$onRenderResolve$ = () => {
|
|
774
|
+
ancestorComponent["s-p"].splice(index - 1, 1);
|
|
775
|
+
r();
|
|
776
|
+
}
|
|
777
|
+
)
|
|
778
|
+
);
|
|
749
779
|
}
|
|
750
780
|
};
|
|
751
781
|
var scheduleUpdate = (hostRef, isInitialLoad) => {
|
|
@@ -772,7 +802,7 @@ var dispatchHooks = (hostRef, isInitialLoad) => {
|
|
|
772
802
|
let maybePromise;
|
|
773
803
|
if (isInitialLoad) {
|
|
774
804
|
{
|
|
775
|
-
maybePromise = safeCall(instance, "componentWillLoad");
|
|
805
|
+
maybePromise = safeCall(instance, "componentWillLoad", void 0, elm);
|
|
776
806
|
}
|
|
777
807
|
}
|
|
778
808
|
endSchedule();
|
|
@@ -871,12 +901,12 @@ var appDidLoad = (who) => {
|
|
|
871
901
|
}
|
|
872
902
|
nextTick(() => emitEvent(win, "appload", { detail: { namespace: NAMESPACE } }));
|
|
873
903
|
};
|
|
874
|
-
var safeCall = (instance, method, arg) => {
|
|
904
|
+
var safeCall = (instance, method, arg, elm) => {
|
|
875
905
|
if (instance && instance[method]) {
|
|
876
906
|
try {
|
|
877
907
|
return instance[method](arg);
|
|
878
908
|
} catch (e) {
|
|
879
|
-
consoleError(e);
|
|
909
|
+
consoleError(e, elm);
|
|
880
910
|
}
|
|
881
911
|
}
|
|
882
912
|
return void 0;
|
|
@@ -935,15 +965,68 @@ var proxyComponent = (Cstr, cmpMeta, flags) => {
|
|
|
935
965
|
const members = Object.entries((_a = cmpMeta.$members$) != null ? _a : {});
|
|
936
966
|
members.map(([memberName, [memberFlags]]) => {
|
|
937
967
|
if ((memberFlags & 31 /* Prop */ || (flags & 2 /* proxyState */) && memberFlags & 32 /* State */)) {
|
|
968
|
+
const { get: origGetter, set: origSetter } = Object.getOwnPropertyDescriptor(prototype, memberName) || {};
|
|
969
|
+
if (origGetter) cmpMeta.$members$[memberName][0] |= 2048 /* Getter */;
|
|
970
|
+
if (origSetter) cmpMeta.$members$[memberName][0] |= 4096 /* Setter */;
|
|
971
|
+
if (flags & 1 /* isElementConstructor */ || !origGetter) {
|
|
972
|
+
Object.defineProperty(prototype, memberName, {
|
|
973
|
+
get() {
|
|
974
|
+
{
|
|
975
|
+
if ((cmpMeta.$members$[memberName][0] & 2048 /* Getter */) === 0) {
|
|
976
|
+
return getValue(this, memberName);
|
|
977
|
+
}
|
|
978
|
+
const ref = getHostRef(this);
|
|
979
|
+
const instance = ref ? ref.$lazyInstance$ : prototype;
|
|
980
|
+
if (!instance) return;
|
|
981
|
+
return instance[memberName];
|
|
982
|
+
}
|
|
983
|
+
},
|
|
984
|
+
configurable: true,
|
|
985
|
+
enumerable: true
|
|
986
|
+
});
|
|
987
|
+
}
|
|
938
988
|
Object.defineProperty(prototype, memberName, {
|
|
939
|
-
get() {
|
|
940
|
-
return getValue(this, memberName);
|
|
941
|
-
},
|
|
942
989
|
set(newValue) {
|
|
943
|
-
|
|
944
|
-
|
|
945
|
-
|
|
946
|
-
|
|
990
|
+
const ref = getHostRef(this);
|
|
991
|
+
if (origSetter) {
|
|
992
|
+
const currentValue = memberFlags & 32 /* State */ ? this[memberName] : ref.$hostElement$[memberName];
|
|
993
|
+
if (typeof currentValue === "undefined" && ref.$instanceValues$.get(memberName)) {
|
|
994
|
+
newValue = ref.$instanceValues$.get(memberName);
|
|
995
|
+
} else if (!ref.$instanceValues$.get(memberName) && currentValue) {
|
|
996
|
+
ref.$instanceValues$.set(memberName, currentValue);
|
|
997
|
+
}
|
|
998
|
+
origSetter.apply(this, [parsePropertyValue(newValue, memberFlags)]);
|
|
999
|
+
newValue = memberFlags & 32 /* State */ ? this[memberName] : ref.$hostElement$[memberName];
|
|
1000
|
+
setValue(this, memberName, newValue, cmpMeta);
|
|
1001
|
+
return;
|
|
1002
|
+
}
|
|
1003
|
+
{
|
|
1004
|
+
if ((flags & 1 /* isElementConstructor */) === 0 || (cmpMeta.$members$[memberName][0] & 4096 /* Setter */) === 0) {
|
|
1005
|
+
setValue(this, memberName, newValue, cmpMeta);
|
|
1006
|
+
if (flags & 1 /* isElementConstructor */ && !ref.$lazyInstance$) {
|
|
1007
|
+
ref.$onReadyPromise$.then(() => {
|
|
1008
|
+
if (cmpMeta.$members$[memberName][0] & 4096 /* Setter */ && ref.$lazyInstance$[memberName] !== ref.$instanceValues$.get(memberName)) {
|
|
1009
|
+
ref.$lazyInstance$[memberName] = newValue;
|
|
1010
|
+
}
|
|
1011
|
+
});
|
|
1012
|
+
}
|
|
1013
|
+
return;
|
|
1014
|
+
}
|
|
1015
|
+
const setterSetVal = () => {
|
|
1016
|
+
const currentValue = ref.$lazyInstance$[memberName];
|
|
1017
|
+
if (!ref.$instanceValues$.get(memberName) && currentValue) {
|
|
1018
|
+
ref.$instanceValues$.set(memberName, currentValue);
|
|
1019
|
+
}
|
|
1020
|
+
ref.$lazyInstance$[memberName] = parsePropertyValue(newValue, memberFlags);
|
|
1021
|
+
setValue(this, memberName, ref.$lazyInstance$[memberName], cmpMeta);
|
|
1022
|
+
};
|
|
1023
|
+
if (ref.$lazyInstance$) {
|
|
1024
|
+
setterSetVal();
|
|
1025
|
+
} else {
|
|
1026
|
+
ref.$onReadyPromise$.then(() => setterSetVal());
|
|
1027
|
+
}
|
|
1028
|
+
}
|
|
1029
|
+
}
|
|
947
1030
|
});
|
|
948
1031
|
}
|
|
949
1032
|
});
|
|
@@ -953,7 +1036,7 @@ var proxyComponent = (Cstr, cmpMeta, flags) => {
|
|
|
953
1036
|
plt.jmp(() => {
|
|
954
1037
|
var _a2;
|
|
955
1038
|
const propName = attrNameToPropName.get(attrName);
|
|
956
|
-
if (this.hasOwnProperty(propName)) {
|
|
1039
|
+
if (this.hasOwnProperty(propName) && BUILD.lazyLoad) {
|
|
957
1040
|
newValue = this[propName];
|
|
958
1041
|
delete this[propName];
|
|
959
1042
|
} else if (prototype.hasOwnProperty(propName) && typeof this[propName] === "number" && // cast type to number to avoid TS compiler issues
|
|
@@ -973,7 +1056,11 @@ var proxyComponent = (Cstr, cmpMeta, flags) => {
|
|
|
973
1056
|
}
|
|
974
1057
|
return;
|
|
975
1058
|
}
|
|
976
|
-
|
|
1059
|
+
const propDesc = Object.getOwnPropertyDescriptor(prototype, propName);
|
|
1060
|
+
newValue = newValue === null && typeof this[propName] === "boolean" ? false : newValue;
|
|
1061
|
+
if (newValue !== this[propName] && (!propDesc.get || !!propDesc.set)) {
|
|
1062
|
+
this[propName] = newValue;
|
|
1063
|
+
}
|
|
977
1064
|
});
|
|
978
1065
|
};
|
|
979
1066
|
Cstr.observedAttributes = Array.from(
|
|
@@ -1000,9 +1087,8 @@ var initializeComponent = async (elm, hostRef, cmpMeta, hmrVersionId) => {
|
|
|
1000
1087
|
let Cstr;
|
|
1001
1088
|
if ((hostRef.$flags$ & 32 /* hasInitializedComponent */) === 0) {
|
|
1002
1089
|
hostRef.$flags$ |= 32 /* hasInitializedComponent */;
|
|
1003
|
-
|
|
1004
|
-
|
|
1005
|
-
const CstrImport = loadModule(cmpMeta);
|
|
1090
|
+
{
|
|
1091
|
+
const CstrImport = loadModule(cmpMeta, hostRef);
|
|
1006
1092
|
if (CstrImport && "then" in CstrImport) {
|
|
1007
1093
|
const endLoad = uniqueTime();
|
|
1008
1094
|
Cstr = await CstrImport;
|
|
@@ -1027,7 +1113,7 @@ var initializeComponent = async (elm, hostRef, cmpMeta, hmrVersionId) => {
|
|
|
1027
1113
|
try {
|
|
1028
1114
|
new Cstr(hostRef);
|
|
1029
1115
|
} catch (e) {
|
|
1030
|
-
consoleError(e);
|
|
1116
|
+
consoleError(e, elm);
|
|
1031
1117
|
}
|
|
1032
1118
|
{
|
|
1033
1119
|
hostRef.$flags$ &= ~8 /* isConstructingInstance */;
|
|
@@ -1036,11 +1122,7 @@ var initializeComponent = async (elm, hostRef, cmpMeta, hmrVersionId) => {
|
|
|
1036
1122
|
hostRef.$flags$ |= 128 /* isWatchReady */;
|
|
1037
1123
|
}
|
|
1038
1124
|
endNewInstance();
|
|
1039
|
-
fireConnectedCallback(hostRef.$lazyInstance
|
|
1040
|
-
} else {
|
|
1041
|
-
Cstr = elm.constructor;
|
|
1042
|
-
const cmpTag = elm.localName;
|
|
1043
|
-
customElements.whenDefined(cmpTag).then(() => hostRef.$flags$ |= 128 /* isWatchReady */);
|
|
1125
|
+
fireConnectedCallback(hostRef.$lazyInstance$, elm);
|
|
1044
1126
|
}
|
|
1045
1127
|
if (Cstr && Cstr.style) {
|
|
1046
1128
|
let style;
|
|
@@ -1063,9 +1145,9 @@ var initializeComponent = async (elm, hostRef, cmpMeta, hmrVersionId) => {
|
|
|
1063
1145
|
schedule();
|
|
1064
1146
|
}
|
|
1065
1147
|
};
|
|
1066
|
-
var fireConnectedCallback = (instance) => {
|
|
1148
|
+
var fireConnectedCallback = (instance, elm) => {
|
|
1067
1149
|
{
|
|
1068
|
-
safeCall(instance, "connectedCallback");
|
|
1150
|
+
safeCall(instance, "connectedCallback", void 0, elm);
|
|
1069
1151
|
}
|
|
1070
1152
|
};
|
|
1071
1153
|
|
|
@@ -1100,15 +1182,15 @@ var connectedCallback = (elm) => {
|
|
|
1100
1182
|
}
|
|
1101
1183
|
} else {
|
|
1102
1184
|
if (hostRef == null ? void 0 : hostRef.$lazyInstance$) {
|
|
1103
|
-
fireConnectedCallback(hostRef.$lazyInstance
|
|
1185
|
+
fireConnectedCallback(hostRef.$lazyInstance$, elm);
|
|
1104
1186
|
} else if (hostRef == null ? void 0 : hostRef.$onReadyPromise$) {
|
|
1105
|
-
hostRef.$onReadyPromise$.then(() => fireConnectedCallback(hostRef.$lazyInstance
|
|
1187
|
+
hostRef.$onReadyPromise$.then(() => fireConnectedCallback(hostRef.$lazyInstance$, elm));
|
|
1106
1188
|
}
|
|
1107
1189
|
}
|
|
1108
1190
|
endConnected();
|
|
1109
1191
|
}
|
|
1110
1192
|
};
|
|
1111
|
-
var disconnectInstance = (instance) => {
|
|
1193
|
+
var disconnectInstance = (instance, elm) => {
|
|
1112
1194
|
};
|
|
1113
1195
|
var disconnectedCallback = async (elm) => {
|
|
1114
1196
|
if ((plt.$flags$ & 1 /* isTmpDisconnected */) === 0) {
|
|
@@ -1117,6 +1199,12 @@ var disconnectedCallback = async (elm) => {
|
|
|
1117
1199
|
hostRef.$onReadyPromise$.then(() => disconnectInstance());
|
|
1118
1200
|
}
|
|
1119
1201
|
}
|
|
1202
|
+
if (rootAppliedStyles.has(elm)) {
|
|
1203
|
+
rootAppliedStyles.delete(elm);
|
|
1204
|
+
}
|
|
1205
|
+
if (elm.shadowRoot && rootAppliedStyles.has(elm.shadowRoot)) {
|
|
1206
|
+
rootAppliedStyles.delete(elm.shadowRoot);
|
|
1207
|
+
}
|
|
1120
1208
|
};
|
|
1121
1209
|
|
|
1122
1210
|
// src/runtime/bootstrap-lazy.ts
|
|
@@ -1197,6 +1285,13 @@ var bootstrapLazy = (lazyBundles, options = {}) => {
|
|
|
1197
1285
|
}
|
|
1198
1286
|
disconnectedCallback() {
|
|
1199
1287
|
plt.jmp(() => disconnectedCallback(this));
|
|
1288
|
+
plt.raf(() => {
|
|
1289
|
+
var _a3;
|
|
1290
|
+
const hostRef = getHostRef(this);
|
|
1291
|
+
if (((_a3 = hostRef == null ? void 0 : hostRef.$vnode$) == null ? void 0 : _a3.$elm$) instanceof Node && !hostRef.$vnode$.$elm$.isConnected) {
|
|
1292
|
+
delete hostRef.$vnode$.$elm$;
|
|
1293
|
+
}
|
|
1294
|
+
});
|
|
1200
1295
|
}
|
|
1201
1296
|
componentOnReady() {
|
|
1202
1297
|
return getHostRef(this).$onReadyPromise$;
|
package/dist/cjs/index.cjs.js
CHANGED
|
@@ -2,8 +2,8 @@
|
|
|
2
2
|
|
|
3
3
|
Object.defineProperty(exports, '__esModule', { value: true });
|
|
4
4
|
|
|
5
|
-
const promotingBanners = require('./promoting-banners-
|
|
6
|
-
require('./index-
|
|
5
|
+
const promotingBanners = require('./promoting-banners-dc9b6beb.js');
|
|
6
|
+
require('./index-ee39fac4.js');
|
|
7
7
|
|
|
8
8
|
|
|
9
9
|
|
package/dist/cjs/loader.cjs.js
CHANGED
|
@@ -2,7 +2,7 @@
|
|
|
2
2
|
|
|
3
3
|
Object.defineProperty(exports, '__esModule', { value: true });
|
|
4
4
|
|
|
5
|
-
const index = require('./index-
|
|
5
|
+
const index = require('./index-ee39fac4.js');
|
|
6
6
|
const appGlobals = require('./app-globals-3a1e7e63.js');
|
|
7
7
|
|
|
8
8
|
const defineCustomElements = async (win, options) => {
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
'use strict';
|
|
2
2
|
|
|
3
|
-
const index = require('./index-
|
|
3
|
+
const index = require('./index-ee39fac4.js');
|
|
4
4
|
|
|
5
5
|
const getDevice = () => {
|
|
6
6
|
let userAgent = window.navigator.userAgent;
|
|
@@ -85,6 +85,33 @@ const PromotingBannersStyle0 = promotingBannersCss;
|
|
|
85
85
|
const PromotingBanners = class {
|
|
86
86
|
constructor(hostRef) {
|
|
87
87
|
index.registerInstance(this, hostRef);
|
|
88
|
+
/**
|
|
89
|
+
* The endpoint
|
|
90
|
+
*/
|
|
91
|
+
this.cmsEndpoint = '';
|
|
92
|
+
/**
|
|
93
|
+
* The language
|
|
94
|
+
*/
|
|
95
|
+
this.language = 'en';
|
|
96
|
+
/**
|
|
97
|
+
* The CMS environment
|
|
98
|
+
*/
|
|
99
|
+
this.cmsEnv = '';
|
|
100
|
+
/**
|
|
101
|
+
* Client custom styling via inline style
|
|
102
|
+
*/
|
|
103
|
+
this.clientStyling = '';
|
|
104
|
+
/**
|
|
105
|
+
* Client custom styling via url
|
|
106
|
+
*/
|
|
107
|
+
this.clientStylingUrl = '';
|
|
108
|
+
/**
|
|
109
|
+
* Translations via URL
|
|
110
|
+
*/
|
|
111
|
+
this.translationUrl = '';
|
|
112
|
+
this.promotingBannersArray = [];
|
|
113
|
+
this.hasErrors = false;
|
|
114
|
+
this.isLoading = true;
|
|
88
115
|
this.setClientStyling = () => {
|
|
89
116
|
let sheet = document.createElement('style');
|
|
90
117
|
sheet.innerHTML = this.clientStyling;
|
|
@@ -111,16 +138,6 @@ const PromotingBanners = class {
|
|
|
111
138
|
this.setClientStylingURL();
|
|
112
139
|
}
|
|
113
140
|
};
|
|
114
|
-
this.cmsEndpoint = '';
|
|
115
|
-
this.language = 'en';
|
|
116
|
-
this.cmsEnv = '';
|
|
117
|
-
this.clientStyling = '';
|
|
118
|
-
this.clientStylingUrl = '';
|
|
119
|
-
this.translationUrl = '';
|
|
120
|
-
this.promotingBannersArray = [];
|
|
121
|
-
this.hasErrors = false;
|
|
122
|
-
this.isLoading = true;
|
|
123
|
-
this.translationData = undefined;
|
|
124
141
|
}
|
|
125
142
|
handleStylingChange(newValue, oldValue) {
|
|
126
143
|
if (newValue !== oldValue)
|
|
@@ -2,8 +2,8 @@
|
|
|
2
2
|
|
|
3
3
|
Object.defineProperty(exports, '__esModule', { value: true });
|
|
4
4
|
|
|
5
|
-
const promotingBanners = require('./promoting-banners-
|
|
6
|
-
require('./index-
|
|
5
|
+
const promotingBanners = require('./promoting-banners-dc9b6beb.js');
|
|
6
|
+
require('./index-ee39fac4.js');
|
|
7
7
|
|
|
8
8
|
|
|
9
9
|
|
|
@@ -2,11 +2,11 @@
|
|
|
2
2
|
|
|
3
3
|
Object.defineProperty(exports, '__esModule', { value: true });
|
|
4
4
|
|
|
5
|
-
const index = require('./index-
|
|
5
|
+
const index = require('./index-ee39fac4.js');
|
|
6
6
|
const appGlobals = require('./app-globals-3a1e7e63.js');
|
|
7
7
|
|
|
8
8
|
/*
|
|
9
|
-
Stencil Client Patch Browser v4.
|
|
9
|
+
Stencil Client Patch Browser v4.25.1 | MIT Licensed | https://stenciljs.com
|
|
10
10
|
*/
|
|
11
11
|
var patchBrowser = () => {
|
|
12
12
|
const importMeta = (typeof document === 'undefined' ? new (require('u' + 'rl').URL)('file:' + __filename).href : (document.currentScript && document.currentScript.src || new URL('promoting-banners.cjs.js', document.baseURI).href));
|