@annalib/anna-core 19.0.27 → 19.0.28
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/esm2020/lib/anna-core-shared-lib/directives/fixed-rows-popup-table/fixed-rows-popup-table.directive.mjs +43 -0
- package/esm2020/lib/anna-core.module.mjs +10 -5
- package/esm2020/public-api.mjs +2 -1
- package/fesm2015/annalib-anna-core.mjs +50 -5
- package/fesm2015/annalib-anna-core.mjs.map +1 -1
- package/fesm2020/annalib-anna-core.mjs +50 -5
- package/fesm2020/annalib-anna-core.mjs.map +1 -1
- package/lib/anna-core-shared-lib/directives/fixed-rows-popup-table/fixed-rows-popup-table.directive.d.ts +16 -0
- package/lib/anna-core.module.d.ts +12 -11
- package/package.json +1 -1
- package/public-api.d.ts +1 -0
|
@@ -5377,6 +5377,47 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "15.2.9", ngImpor
|
|
|
5377
5377
|
}]
|
|
5378
5378
|
}], ctorParameters: function () { return []; } });
|
|
5379
5379
|
|
|
5380
|
+
class FixedRowsPopupTableDirective {
|
|
5381
|
+
constructor(el, renderer) {
|
|
5382
|
+
this.el = el;
|
|
5383
|
+
this.renderer = renderer;
|
|
5384
|
+
this.popupRowHeight = 37.5;
|
|
5385
|
+
this.popupHeaderHeight = 38;
|
|
5386
|
+
this.maxRowsRenderedWithoutScrollForPopup = 10;
|
|
5387
|
+
}
|
|
5388
|
+
onWindowResize() {
|
|
5389
|
+
this.setPopUpTableHeight();
|
|
5390
|
+
}
|
|
5391
|
+
ngOnInit() {
|
|
5392
|
+
this.setPopUpTableHeight();
|
|
5393
|
+
}
|
|
5394
|
+
setPopUpTableHeight() {
|
|
5395
|
+
const viewportHeight = window.innerHeight;
|
|
5396
|
+
const maxNoOfRowsToDisplay = viewportHeight < 740 ? 5 : 10;
|
|
5397
|
+
this.maxRowsRenderedWithoutScrollForPopup = maxNoOfRowsToDisplay;
|
|
5398
|
+
let totalPopupTableHeight = this.maxRowsRenderedWithoutScrollForPopup * this.popupRowHeight + this.popupHeaderHeight;
|
|
5399
|
+
let tableHeightForPopup = (this.tableDataLength < this.maxRowsRenderedWithoutScrollForPopup) ? ((this.popupRowHeight) * (this.tableDataLength ? this.tableDataLength : 1)) + this.popupHeaderHeight : totalPopupTableHeight;
|
|
5400
|
+
this.renderer.setStyle(this.el.nativeElement, 'height', `calc(${tableHeightForPopup}px)`);
|
|
5401
|
+
}
|
|
5402
|
+
}
|
|
5403
|
+
FixedRowsPopupTableDirective.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "15.2.9", ngImport: i0, type: FixedRowsPopupTableDirective, deps: [{ token: i0.ElementRef }, { token: i0.Renderer2 }], target: i0.ɵɵFactoryTarget.Directive });
|
|
5404
|
+
FixedRowsPopupTableDirective.ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "14.0.0", version: "15.2.9", type: FixedRowsPopupTableDirective, selector: "[fixedRowsInPopupTable]", inputs: { popupRowHeight: "popupRowHeight", popupHeaderHeight: "popupHeaderHeight", tableDataLength: "tableDataLength" }, host: { listeners: { "window:resize": "onWindowResize()" } }, ngImport: i0 });
|
|
5405
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "15.2.9", ngImport: i0, type: FixedRowsPopupTableDirective, decorators: [{
|
|
5406
|
+
type: Directive,
|
|
5407
|
+
args: [{
|
|
5408
|
+
selector: '[fixedRowsInPopupTable]'
|
|
5409
|
+
}]
|
|
5410
|
+
}], ctorParameters: function () { return [{ type: i0.ElementRef }, { type: i0.Renderer2 }]; }, propDecorators: { popupRowHeight: [{
|
|
5411
|
+
type: Input
|
|
5412
|
+
}], popupHeaderHeight: [{
|
|
5413
|
+
type: Input
|
|
5414
|
+
}], tableDataLength: [{
|
|
5415
|
+
type: Input
|
|
5416
|
+
}], onWindowResize: [{
|
|
5417
|
+
type: HostListener,
|
|
5418
|
+
args: ['window:resize']
|
|
5419
|
+
}] } });
|
|
5420
|
+
|
|
5380
5421
|
// Angular import statements
|
|
5381
5422
|
class AnnaCoreModule {
|
|
5382
5423
|
}
|
|
@@ -5407,7 +5448,8 @@ AnnaCoreModule.ɵmod = i0.ɵɵngDeclareNgModule({ minVersion: "14.0.0", version:
|
|
|
5407
5448
|
AnnaColumnCheckboxFilterComponent,
|
|
5408
5449
|
AnnaDeletedOrderIconTemplateComponent,
|
|
5409
5450
|
AnnaColumnSliderFilterComponent,
|
|
5410
|
-
AnnaDateFormatterPipe
|
|
5451
|
+
AnnaDateFormatterPipe,
|
|
5452
|
+
FixedRowsPopupTableDirective], imports: [CommonModule,
|
|
5411
5453
|
NgbModule,
|
|
5412
5454
|
FormsModule,
|
|
5413
5455
|
MatRadioModule,
|
|
@@ -5441,7 +5483,8 @@ AnnaCoreModule.ɵmod = i0.ɵɵngDeclareNgModule({ minVersion: "14.0.0", version:
|
|
|
5441
5483
|
DigitOnlyDirective,
|
|
5442
5484
|
AnnaDeletedOrderIconTemplateComponent,
|
|
5443
5485
|
AnnaColumnSliderFilterComponent,
|
|
5444
|
-
AnnaDateFormatterPipe
|
|
5486
|
+
AnnaDateFormatterPipe,
|
|
5487
|
+
FixedRowsPopupTableDirective] });
|
|
5445
5488
|
AnnaCoreModule.ɵinj = i0.ɵɵngDeclareInjector({ minVersion: "12.0.0", version: "15.2.9", ngImport: i0, type: AnnaCoreModule, imports: [CommonModule,
|
|
5446
5489
|
NgbModule,
|
|
5447
5490
|
FormsModule,
|
|
@@ -5489,7 +5532,8 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "15.2.9", ngImpor
|
|
|
5489
5532
|
AnnaColumnCheckboxFilterComponent,
|
|
5490
5533
|
AnnaDeletedOrderIconTemplateComponent,
|
|
5491
5534
|
AnnaColumnSliderFilterComponent,
|
|
5492
|
-
AnnaDateFormatterPipe
|
|
5535
|
+
AnnaDateFormatterPipe,
|
|
5536
|
+
FixedRowsPopupTableDirective
|
|
5493
5537
|
],
|
|
5494
5538
|
imports: [
|
|
5495
5539
|
CommonModule,
|
|
@@ -5537,7 +5581,8 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "15.2.9", ngImpor
|
|
|
5537
5581
|
DigitOnlyDirective,
|
|
5538
5582
|
AnnaDeletedOrderIconTemplateComponent,
|
|
5539
5583
|
AnnaColumnSliderFilterComponent,
|
|
5540
|
-
AnnaDateFormatterPipe
|
|
5584
|
+
AnnaDateFormatterPipe,
|
|
5585
|
+
FixedRowsPopupTableDirective
|
|
5541
5586
|
]
|
|
5542
5587
|
}]
|
|
5543
5588
|
}] });
|
|
@@ -5718,5 +5763,5 @@ OrderSources.WOZ = "WOZ";
|
|
|
5718
5763
|
* Generated bundle index. Do not edit.
|
|
5719
5764
|
*/
|
|
5720
5765
|
|
|
5721
|
-
export { AllSelectedStatus, AnnaBuyerApprovalIconTemplateComponent, AnnaCalendarFilterComponent, AnnaColumnCheckboxFilterComponent, AnnaColumnDateRangeFilterComponent, AnnaColumnSliderFilterComponent, AnnaColumnTimeFilterComponent, AnnaConvertZeroOrNullOrUndefinedPipe, AnnaCoreModule, AnnaDateFormatterPipe, AnnaDateTimeFormatService, AnnaDeletedOrderIconTemplateComponent, AnnaFilterSearchedTextPipe, AnnaFilterService, AnnaFixedRowSizeTableVirtualScrollStrategy, AnnaFixedRowSizeTableVirtualScrollStrategyDirective, AnnaGlobalConfigService, AnnaGtHelperService, AnnaIconColumnComponent, AnnaLiveIconTemplateComponent, AnnaNoDataComponent, AnnaNonEditableGenericTableComponent, AnnaNotifyIconTemplateComponent, AnnaNumberFormatService, AnnaPayForPerformanceIconTemplateComponent, AnnaPersistingFilterService, AnnaRejectedIconTemplateComponent, AnnaReplaceCharPipe, AnnaSortComponent, AnnaSortService, AnnaTableVirtualScrollViewportComponent, AnnaTypeofDataPipe, AnnaVirtualTableDirective, AnnaWeekCalendarComponent, ClickableItem, Constants, Days, DigitOnlyDirective, ErrorCodes, OrderSources, SortTypeEnum, TooltipModel, UserActivationStatus, fixedSizeVirtualScrollStrategyFactory, radioButtonModel, showEllipsisTextOnHoverDirective, tooltipModelForColumnLevelFiltering };
|
|
5766
|
+
export { AllSelectedStatus, AnnaBuyerApprovalIconTemplateComponent, AnnaCalendarFilterComponent, AnnaColumnCheckboxFilterComponent, AnnaColumnDateRangeFilterComponent, AnnaColumnSliderFilterComponent, AnnaColumnTimeFilterComponent, AnnaConvertZeroOrNullOrUndefinedPipe, AnnaCoreModule, AnnaDateFormatterPipe, AnnaDateTimeFormatService, AnnaDeletedOrderIconTemplateComponent, AnnaFilterSearchedTextPipe, AnnaFilterService, AnnaFixedRowSizeTableVirtualScrollStrategy, AnnaFixedRowSizeTableVirtualScrollStrategyDirective, AnnaGlobalConfigService, AnnaGtHelperService, AnnaIconColumnComponent, AnnaLiveIconTemplateComponent, AnnaNoDataComponent, AnnaNonEditableGenericTableComponent, AnnaNotifyIconTemplateComponent, AnnaNumberFormatService, AnnaPayForPerformanceIconTemplateComponent, AnnaPersistingFilterService, AnnaRejectedIconTemplateComponent, AnnaReplaceCharPipe, AnnaSortComponent, AnnaSortService, AnnaTableVirtualScrollViewportComponent, AnnaTypeofDataPipe, AnnaVirtualTableDirective, AnnaWeekCalendarComponent, ClickableItem, Constants, Days, DigitOnlyDirective, ErrorCodes, FixedRowsPopupTableDirective, OrderSources, SortTypeEnum, TooltipModel, UserActivationStatus, fixedSizeVirtualScrollStrategyFactory, radioButtonModel, showEllipsisTextOnHoverDirective, tooltipModelForColumnLevelFiltering };
|
|
5722
5767
|
//# sourceMappingURL=annalib-anna-core.mjs.map
|