@sankhyalabs/core 5.20.0-dev.85 → 5.20.0-dev.86
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/.docs/classes/OverflowWatcher.md +11 -11
- package/.docs/interfaces/OverFlowWatcherParams.md +6 -6
- package/dist/utils/OverflowWatcher/index.js +1 -1
- package/dist/utils/OverflowWatcher/index.js.map +1 -1
- package/package.json +1 -1
- package/reports/test-report.xml +386 -386
- package/src/utils/OverflowWatcher/index.ts +4 -3
|
@@ -73,7 +73,7 @@ export default class OverflowWatcher {
|
|
|
73
73
|
if(!containerSize) return;
|
|
74
74
|
|
|
75
75
|
if(this.hasChangedSize(containerSize)){
|
|
76
|
-
|
|
76
|
+
this.updateOverFlowedItems(container.target as HTMLElement, containerSize);
|
|
77
77
|
}
|
|
78
78
|
}
|
|
79
79
|
|
|
@@ -94,7 +94,7 @@ export default class OverflowWatcher {
|
|
|
94
94
|
}
|
|
95
95
|
|
|
96
96
|
private canNotRegisterNotOverFlow(id: string) {
|
|
97
|
-
return !id || !this._notOverFlow.includes(id)
|
|
97
|
+
return !id || !this._notOverFlow.includes(id);
|
|
98
98
|
}
|
|
99
99
|
|
|
100
100
|
private hasChangedSize(elementSize: number):boolean{
|
|
@@ -133,6 +133,7 @@ export default class OverflowWatcher {
|
|
|
133
133
|
const avaliableSizeConsideringDelta = (avaliableSize - this._deltaSize);
|
|
134
134
|
|
|
135
135
|
let sumElementsSize = 0;
|
|
136
|
+
|
|
136
137
|
for (const element of allElements) {
|
|
137
138
|
sumElementsSize += this.calcElementSize(element);
|
|
138
139
|
if(this.exceedsAvaliableSize(sumElementsSize, elementsThatFit, avaliableSizeConsideringDelta)) break;
|
|
@@ -156,7 +157,7 @@ export default class OverflowWatcher {
|
|
|
156
157
|
|
|
157
158
|
private canOverFlowElement(element: Element) {
|
|
158
159
|
return !this._notOverFlow.includes(element.id)
|
|
159
|
-
|
|
160
|
+
&& !this._notOverFlow.includes(this.getDataElementId(element));
|
|
160
161
|
}
|
|
161
162
|
|
|
162
163
|
private getDataElementId(element: Element): string {
|