Hello,
I would like to import PagerTemplateDirective, PDFService, SuspendService, and ExcelService types which are not exposed in '@progress/kendo-angular-grid' directly. At the moment I'm doing this by importing from '@progress/kendo-angular-grid/dist/es/......' which is not recommended.
I'll try explaining why I need these types in the following lines briefly.
1. PagerTemplateDirective:
I want to change the pager template of my grid dynamically in code under certain circumstances. So, I need to have an instance of PagerTemplateDirective in my code to assign to 'this.grid.pagerTemplate'.
2. PDFService and SuspendService:
I want to extend PDFComponent class and use this extended (customised) component for PDF export in my grids. However, the constructor requires PDFService and SuspendService; see the following code:
export class KendoGridTypicalPdfComponent extends PDFComponent implements OnInit { @ViewChild(PDFMarginComponent) public marginComponent: PDFMarginComponent; @ViewChild(PDFTemplateDirective) public pageTemplateDirective: PDFTemplateDirective; constructor(protected pdfService: PDFService, protected suspendService: SuspendService, protected ngZone: NgZone, element: ElementRef) { super(pdfService, suspendService, ngZone, element); } ngOnInit(): void { this.scale = 0.6; this.paperSize = 'A4'; this.landscape = true; }}
3. ExcelService:
The same story for Excel export as PDF export.
export class KendoGridTypicalExcelComponent extends ExcelComponent implements OnInit { constructor(protected excelService: ExcelService, protected localizationService: LocalizationService) { super(excelService, localizationService); }
Thanks,
Mojtaba
