@memberjunction/ng-container-directives 0.9.121 → 0.9.123
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.
|
@@ -2,7 +2,6 @@ import { ElementRef, OnDestroy, OnInit } from '@angular/core';
|
|
|
2
2
|
import * as i0 from "@angular/core";
|
|
3
3
|
export declare class FillContainer implements OnInit, OnDestroy {
|
|
4
4
|
private elementRef;
|
|
5
|
-
private static _instanceCount;
|
|
6
5
|
fillWidth: boolean;
|
|
7
6
|
fillHeight: boolean;
|
|
8
7
|
rightMargin: number;
|
|
@@ -15,8 +15,6 @@ export class FillContainer {
|
|
|
15
15
|
this._resizeEndDebounceTime = 500;
|
|
16
16
|
this.resizeImmediateSubscription = null;
|
|
17
17
|
this.resizeEndSubscription = null;
|
|
18
|
-
FillContainer._instanceCount++;
|
|
19
|
-
console.log('FillContainer instances: ' + FillContainer._instanceCount);
|
|
20
18
|
}
|
|
21
19
|
ngOnInit() {
|
|
22
20
|
const el = this.elementRef.nativeElement;
|
|
@@ -43,8 +41,6 @@ export class FillContainer {
|
|
|
43
41
|
var _a, _b;
|
|
44
42
|
(_a = this.resizeImmediateSubscription) === null || _a === void 0 ? void 0 : _a.unsubscribe();
|
|
45
43
|
(_b = this.resizeEndSubscription) === null || _b === void 0 ? void 0 : _b.unsubscribe();
|
|
46
|
-
FillContainer._instanceCount--;
|
|
47
|
-
console.log('FillContainer instances: ' + FillContainer._instanceCount);
|
|
48
44
|
}
|
|
49
45
|
getParent(element) {
|
|
50
46
|
const parent = element.parentElement;
|
|
@@ -72,18 +68,14 @@ export class FillContainer {
|
|
|
72
68
|
resizeElement() {
|
|
73
69
|
const element = this.elementRef.nativeElement;
|
|
74
70
|
try {
|
|
75
|
-
console.log('resizing element (1st check): ' + element.nodeName);
|
|
76
71
|
if (element && element.style && !this.shouldSkipResize(element)) {
|
|
77
|
-
console.log('resizing element (2nd check): ' + element.nodeName);
|
|
78
72
|
const parent = this.getParent(element);
|
|
79
73
|
if (parent && !this.elementBelowHiddenTab(element)) {
|
|
80
|
-
console.log('resizing element (3nd check): ' + element.nodeName);
|
|
81
74
|
let parentStyle = window.getComputedStyle(parent);
|
|
82
75
|
if (parentStyle.visibility === 'hidden' || parentStyle.display === 'none') {
|
|
83
76
|
LogStatus('skipping hidden element: ' + parent.nodeName);
|
|
84
77
|
}
|
|
85
78
|
else {
|
|
86
|
-
console.log('resizing element (4th check): ' + element.nodeName);
|
|
87
79
|
const parentRect = parent.getBoundingClientRect();
|
|
88
80
|
if (parent.nodeName === 'HTML') {
|
|
89
81
|
parentRect.height = window.innerHeight;
|
|
@@ -156,7 +148,6 @@ export class FillContainer {
|
|
|
156
148
|
return false;
|
|
157
149
|
}
|
|
158
150
|
}
|
|
159
|
-
FillContainer._instanceCount = 0;
|
|
160
151
|
FillContainer.ɵfac = function FillContainer_Factory(t) { return new (t || FillContainer)(i0.ɵɵdirectiveInject(i0.ElementRef)); };
|
|
161
152
|
FillContainer.ɵdir = /*@__PURE__*/ i0.ɵɵdefineDirective({ type: FillContainer, selectors: [["", "mjFillContainer", ""]], inputs: { fillWidth: "fillWidth", fillHeight: "fillHeight", rightMargin: "rightMargin", bottomMargin: "bottomMargin" } });
|
|
162
153
|
(() => { (typeof ngDevMode === "undefined" || ngDevMode) && i0.ɵsetClassMetadata(FillContainer, [{
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@memberjunction/ng-container-directives",
|
|
3
|
-
"version": "0.9.
|
|
3
|
+
"version": "0.9.123",
|
|
4
4
|
"description": "MemberJunction: Angular Container Directives - Fill Container for Auto-Resizing, and plain container just for element identification/binding",
|
|
5
5
|
"main": "./dist/public-api.js",
|
|
6
6
|
"typings": "./dist/public-api.d.ts",
|
|
@@ -29,8 +29,8 @@
|
|
|
29
29
|
"@angular/router": "~17.2.2"
|
|
30
30
|
},
|
|
31
31
|
"dependencies": {
|
|
32
|
-
"@memberjunction/core": "^0.9.
|
|
33
|
-
"@memberjunction/global": "^0.9.
|
|
32
|
+
"@memberjunction/core": "^0.9.153",
|
|
33
|
+
"@memberjunction/global": "^0.9.139",
|
|
34
34
|
"tslib": "^2.3.0"
|
|
35
35
|
},
|
|
36
36
|
"sideEffects": false
|