@alaarab/ogrid-angular-material 2.5.9 → 2.6.1

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.
@@ -0,0 +1,99 @@
1
+ import { Component, ChangeDetectionStrategy } from '@angular/core';
2
+ import { OGridService, OGridLayoutComponent, BaseOGridComponent, } from '@alaarab/ogrid-angular';
3
+ import { DataGridTableComponent } from '../datagrid-table/datagrid-table.component';
4
+ import { ColumnChooserComponent } from '../column-chooser/column-chooser.component';
5
+ import { PaginationControlsComponent } from '../pagination-controls/pagination-controls.component';
6
+ import * as i0 from "@angular/core";
7
+ function OGridComponent_Conditional_2_Template(rf, ctx) { if (rf & 1) {
8
+ const _r1 = i0.ɵɵgetCurrentView();
9
+ i0.ɵɵelementStart(0, "ogrid-column-chooser", 6);
10
+ i0.ɵɵlistener("visibilityChange", function OGridComponent_Conditional_2_Template_ogrid_column_chooser_visibilityChange_0_listener($event) { i0.ɵɵrestoreView(_r1); const ctx_r1 = i0.ɵɵnextContext(); return i0.ɵɵresetView(ctx_r1.ogridService.columnChooser().onVisibilityChange($event.columnKey, $event.visible)); });
11
+ i0.ɵɵelementEnd();
12
+ } if (rf & 2) {
13
+ const ctx_r1 = i0.ɵɵnextContext();
14
+ i0.ɵɵproperty("columns", ctx_r1.ogridService.columnChooser().columns)("visibleColumns", ctx_r1.ogridService.columnChooser().visibleColumns);
15
+ } }
16
+ /**
17
+ * Top-level OGrid component for Angular Material.
18
+ * Standalone component - provides OGridService and renders OGridLayout with all sub-components.
19
+ *
20
+ * Uses @Input with signal setter for JIT compatibility (project builds with tsc, not ngc).
21
+ * The effect() reactively configures the service when the input signal changes.
22
+ */
23
+ export class OGridComponent extends BaseOGridComponent {
24
+ static { this.ɵfac = /*@__PURE__*/ (() => { let ɵOGridComponent_BaseFactory; return function OGridComponent_Factory(__ngFactoryType__) { return (ɵOGridComponent_BaseFactory || (ɵOGridComponent_BaseFactory = i0.ɵɵgetInheritedFactory(OGridComponent)))(__ngFactoryType__ || OGridComponent); }; })(); }
25
+ static { this.ɵcmp = /*@__PURE__*/ i0.ɵɵdefineComponent({ type: OGridComponent, selectors: [["ogrid"]], features: [i0.ɵɵProvidersFeature([OGridService]), i0.ɵɵInheritDefinitionFeature], decls: 6, vars: 20, consts: [[3, "className", "sideBar", "hasToolbar", "hasToolbarBelow", "hasPagination", "fullScreen", "showNameBox", "activeCellRef", "formulaBar", "sheetDefs", "activeSheet", "onSheetChange", "onSheetAdd"], ["toolbarEnd", ""], [3, "columns", "visibleColumns"], [3, "props"], ["pagination", ""], [3, "pageChange", "pageSizeChange", "currentPage", "pageSize", "totalCount", "pageSizeOptions", "entityLabelPlural"], [3, "visibilityChange", "columns", "visibleColumns"]], template: function OGridComponent_Template(rf, ctx) { if (rf & 1) {
26
+ i0.ɵɵelementStart(0, "ogrid-layout", 0);
27
+ i0.ɵɵelementContainerStart(1, 1);
28
+ i0.ɵɵconditionalCreate(2, OGridComponent_Conditional_2_Template, 1, 2, "ogrid-column-chooser", 2);
29
+ i0.ɵɵelementContainerEnd();
30
+ i0.ɵɵelement(3, "ogrid-datagrid-table", 3);
31
+ i0.ɵɵelementContainerStart(4, 4);
32
+ i0.ɵɵelementStart(5, "ogrid-pagination-controls", 5);
33
+ i0.ɵɵlistener("pageChange", function OGridComponent_Template_ogrid_pagination_controls_pageChange_5_listener($event) { return ctx.ogridService.pagination().setPage($event); })("pageSizeChange", function OGridComponent_Template_ogrid_pagination_controls_pageSizeChange_5_listener($event) { return ctx.onPageSizeChange($event); });
34
+ i0.ɵɵelementEnd();
35
+ i0.ɵɵelementContainerEnd();
36
+ i0.ɵɵelementEnd();
37
+ } if (rf & 2) {
38
+ i0.ɵɵproperty("className", ctx.ogridService.className())("sideBar", ctx.ogridService.sideBarProps())("hasToolbar", ctx.showToolbar)("hasToolbarBelow", false)("hasPagination", true)("fullScreen", ctx.ogridService.fullScreen())("showNameBox", !!(ctx.ogridService.cellReferences() && !ctx.ogridService.formulasEnabled()))("activeCellRef", ctx.ogridService.activeCellRef())("formulaBar", ctx.ogridService.formulasEnabled() ? ctx.ogridService.formulaBarState() : null)("sheetDefs", ctx.ogridService.sheetDefs())("activeSheet", ctx.ogridService.activeSheet())("onSheetChange", ctx.ogridService.onSheetChange())("onSheetAdd", ctx.ogridService.onSheetAdd());
39
+ i0.ɵɵadvance(2);
40
+ i0.ɵɵconditional(ctx.ogridService.columnChooserPlacement() === "toolbar" ? 2 : -1);
41
+ i0.ɵɵadvance();
42
+ i0.ɵɵproperty("props", ctx.ogridService.dataGridProps());
43
+ i0.ɵɵadvance(2);
44
+ i0.ɵɵproperty("currentPage", ctx.ogridService.pagination().page)("pageSize", ctx.ogridService.pagination().pageSize)("totalCount", ctx.ogridService.pagination().displayTotalCount)("pageSizeOptions", ctx.ogridService.pagination().pageSizeOptions)("entityLabelPlural", ctx.ogridService.pagination().entityLabelPlural);
45
+ } }, dependencies: [OGridLayoutComponent,
46
+ DataGridTableComponent,
47
+ ColumnChooserComponent,
48
+ PaginationControlsComponent], styles: ["[_nghost-%COMP%] { display: block; height: 100%; }"], changeDetection: 0 }); }
49
+ }
50
+ (() => { (typeof ngDevMode === "undefined" || ngDevMode) && i0.ɵsetClassMetadata(OGridComponent, [{
51
+ type: Component,
52
+ args: [{ selector: 'ogrid', standalone: true, changeDetection: ChangeDetectionStrategy.OnPush, imports: [
53
+ OGridLayoutComponent,
54
+ DataGridTableComponent,
55
+ ColumnChooserComponent,
56
+ PaginationControlsComponent,
57
+ ], providers: [OGridService], template: `
58
+ <ogrid-layout
59
+ [className]="ogridService.className()"
60
+ [sideBar]="ogridService.sideBarProps()"
61
+ [hasToolbar]="showToolbar"
62
+ [hasToolbarBelow]="false"
63
+ [hasPagination]="true"
64
+ [fullScreen]="ogridService.fullScreen()"
65
+ [showNameBox]="!!(ogridService.cellReferences() && !ogridService.formulasEnabled())"
66
+ [activeCellRef]="ogridService.activeCellRef()"
67
+ [formulaBar]="ogridService.formulasEnabled() ? ogridService.formulaBarState() : null"
68
+ [sheetDefs]="ogridService.sheetDefs()"
69
+ [activeSheet]="ogridService.activeSheet()"
70
+ [onSheetChange]="ogridService.onSheetChange()"
71
+ [onSheetAdd]="ogridService.onSheetAdd()"
72
+ >
73
+ <ng-container toolbarEnd>
74
+ @if (ogridService.columnChooserPlacement() === 'toolbar') {
75
+ <ogrid-column-chooser
76
+ [columns]="ogridService.columnChooser().columns"
77
+ [visibleColumns]="ogridService.columnChooser().visibleColumns"
78
+ (visibilityChange)="ogridService.columnChooser().onVisibilityChange($event.columnKey, $event.visible)"
79
+ />
80
+ }
81
+ </ng-container>
82
+
83
+ <ogrid-datagrid-table [props]="ogridService.dataGridProps()" />
84
+
85
+ <ng-container pagination>
86
+ <ogrid-pagination-controls
87
+ [currentPage]="ogridService.pagination().page"
88
+ [pageSize]="ogridService.pagination().pageSize"
89
+ [totalCount]="ogridService.pagination().displayTotalCount"
90
+ [pageSizeOptions]="ogridService.pagination().pageSizeOptions"
91
+ [entityLabelPlural]="ogridService.pagination().entityLabelPlural"
92
+ (pageChange)="ogridService.pagination().setPage($event)"
93
+ (pageSizeChange)="onPageSizeChange($event)"
94
+ />
95
+ </ng-container>
96
+ </ogrid-layout>
97
+ `, styles: [":host { display: block; height: 100%; }"] }]
98
+ }], null, null); })();
99
+ (() => { (typeof ngDevMode === "undefined" || ngDevMode) && i0.ɵsetClassDebugInfo(OGridComponent, { className: "OGridComponent", filePath: "ogrid/ogrid.component.ts", lineNumber: 72 }); })();
@@ -0,0 +1,200 @@
1
+ import { Component, ChangeDetectionStrategy } from '@angular/core';
2
+ import { BasePaginationControlsComponent } from '@alaarab/ogrid-angular';
3
+ import * as i0 from "@angular/core";
4
+ function PaginationControlsComponent_Conditional_0_Conditional_8_Template(rf, ctx) { if (rf & 1) {
5
+ const _r3 = i0.ɵɵgetCurrentView();
6
+ i0.ɵɵdomElementStart(0, "button", 11);
7
+ i0.ɵɵdomListener("click", function PaginationControlsComponent_Conditional_0_Conditional_8_Template_button_click_0_listener() { i0.ɵɵrestoreView(_r3); const ctx_r1 = i0.ɵɵnextContext(2); return i0.ɵɵresetView(ctx_r1.pageChange.emit(1)); });
8
+ i0.ɵɵtext(1, "1");
9
+ i0.ɵɵdomElementEnd();
10
+ i0.ɵɵdomElementStart(2, "span", 12);
11
+ i0.ɵɵtext(3, "\u2026");
12
+ i0.ɵɵdomElementEnd();
13
+ } }
14
+ function PaginationControlsComponent_Conditional_0_For_10_Template(rf, ctx) { if (rf & 1) {
15
+ const _r4 = i0.ɵɵgetCurrentView();
16
+ i0.ɵɵdomElementStart(0, "button", 13);
17
+ i0.ɵɵdomListener("click", function PaginationControlsComponent_Conditional_0_For_10_Template_button_click_0_listener() { const pageNum_r5 = i0.ɵɵrestoreView(_r4).$implicit; const ctx_r1 = i0.ɵɵnextContext(2); return i0.ɵɵresetView(ctx_r1.pageChange.emit(pageNum_r5)); });
18
+ i0.ɵɵtext(1);
19
+ i0.ɵɵdomElementEnd();
20
+ } if (rf & 2) {
21
+ const pageNum_r5 = ctx.$implicit;
22
+ const ctx_r1 = i0.ɵɵnextContext(2);
23
+ i0.ɵɵclassProp("ogrid-pagination__btn--active", ctx_r1.currentPage === pageNum_r5);
24
+ i0.ɵɵattribute("aria-label", "Page " + pageNum_r5)("aria-current", ctx_r1.currentPage === pageNum_r5 ? "page" : null);
25
+ i0.ɵɵadvance();
26
+ i0.ɵɵtextInterpolate(pageNum_r5);
27
+ } }
28
+ function PaginationControlsComponent_Conditional_0_Conditional_11_Template(rf, ctx) { if (rf & 1) {
29
+ const _r6 = i0.ɵɵgetCurrentView();
30
+ i0.ɵɵdomElementStart(0, "span", 12);
31
+ i0.ɵɵtext(1, "\u2026");
32
+ i0.ɵɵdomElementEnd();
33
+ i0.ɵɵdomElementStart(2, "button", 13);
34
+ i0.ɵɵdomListener("click", function PaginationControlsComponent_Conditional_0_Conditional_11_Template_button_click_2_listener() { i0.ɵɵrestoreView(_r6); const vm_r7 = i0.ɵɵnextContext(); const ctx_r1 = i0.ɵɵnextContext(); return i0.ɵɵresetView(ctx_r1.pageChange.emit(vm_r7.totalPages)); });
35
+ i0.ɵɵtext(3);
36
+ i0.ɵɵdomElementEnd();
37
+ } if (rf & 2) {
38
+ const vm_r7 = i0.ɵɵnextContext();
39
+ i0.ɵɵadvance(2);
40
+ i0.ɵɵattribute("aria-label", "Page " + vm_r7.totalPages);
41
+ i0.ɵɵadvance();
42
+ i0.ɵɵtextInterpolate(vm_r7.totalPages);
43
+ } }
44
+ function PaginationControlsComponent_Conditional_0_For_21_Template(rf, ctx) { if (rf & 1) {
45
+ i0.ɵɵdomElementStart(0, "option", 10);
46
+ i0.ɵɵtext(1);
47
+ i0.ɵɵdomElementEnd();
48
+ } if (rf & 2) {
49
+ const n_r8 = ctx.$implicit;
50
+ const ctx_r1 = i0.ɵɵnextContext(2);
51
+ i0.ɵɵdomProperty("value", n_r8)("selected", ctx_r1.pageSize === n_r8);
52
+ i0.ɵɵadvance();
53
+ i0.ɵɵtextInterpolate(n_r8);
54
+ } }
55
+ function PaginationControlsComponent_Conditional_0_Template(rf, ctx) { if (rf & 1) {
56
+ const _r1 = i0.ɵɵgetCurrentView();
57
+ i0.ɵɵdomElementStart(0, "nav", 0)(1, "span", 1);
58
+ i0.ɵɵtext(2);
59
+ i0.ɵɵdomElementEnd();
60
+ i0.ɵɵdomElementStart(3, "span", 2)(4, "button", 3);
61
+ i0.ɵɵdomListener("click", function PaginationControlsComponent_Conditional_0_Template_button_click_4_listener() { i0.ɵɵrestoreView(_r1); const ctx_r1 = i0.ɵɵnextContext(); return i0.ɵɵresetView(ctx_r1.pageChange.emit(1)); });
62
+ i0.ɵɵtext(5, "\u00AB");
63
+ i0.ɵɵdomElementEnd();
64
+ i0.ɵɵdomElementStart(6, "button", 4);
65
+ i0.ɵɵdomListener("click", function PaginationControlsComponent_Conditional_0_Template_button_click_6_listener() { i0.ɵɵrestoreView(_r1); const ctx_r1 = i0.ɵɵnextContext(); return i0.ɵɵresetView(ctx_r1.pageChange.emit(ctx_r1.currentPage - 1)); });
66
+ i0.ɵɵtext(7, "\u2039");
67
+ i0.ɵɵdomElementEnd();
68
+ i0.ɵɵconditionalCreate(8, PaginationControlsComponent_Conditional_0_Conditional_8_Template, 4, 0);
69
+ i0.ɵɵrepeaterCreate(9, PaginationControlsComponent_Conditional_0_For_10_Template, 2, 5, "button", 5, i0.ɵɵrepeaterTrackByIdentity);
70
+ i0.ɵɵconditionalCreate(11, PaginationControlsComponent_Conditional_0_Conditional_11_Template, 4, 2);
71
+ i0.ɵɵdomElementStart(12, "button", 6);
72
+ i0.ɵɵdomListener("click", function PaginationControlsComponent_Conditional_0_Template_button_click_12_listener() { i0.ɵɵrestoreView(_r1); const ctx_r1 = i0.ɵɵnextContext(); return i0.ɵɵresetView(ctx_r1.pageChange.emit(ctx_r1.currentPage + 1)); });
73
+ i0.ɵɵtext(13, "\u203A");
74
+ i0.ɵɵdomElementEnd();
75
+ i0.ɵɵdomElementStart(14, "button", 7);
76
+ i0.ɵɵdomListener("click", function PaginationControlsComponent_Conditional_0_Template_button_click_14_listener() { const vm_r7 = i0.ɵɵrestoreView(_r1); const ctx_r1 = i0.ɵɵnextContext(); return i0.ɵɵresetView(ctx_r1.pageChange.emit(vm_r7.totalPages)); });
77
+ i0.ɵɵtext(15, "\u00BB");
78
+ i0.ɵɵdomElementEnd()();
79
+ i0.ɵɵdomElementStart(16, "span", 8)(17, "label");
80
+ i0.ɵɵtext(18, "Rows ");
81
+ i0.ɵɵdomElementStart(19, "select", 9);
82
+ i0.ɵɵdomListener("change", function PaginationControlsComponent_Conditional_0_Template_select_change_19_listener($event) { i0.ɵɵrestoreView(_r1); const ctx_r1 = i0.ɵɵnextContext(); return i0.ɵɵresetView(ctx_r1.onPageSizeSelect($event)); });
83
+ i0.ɵɵrepeaterCreate(20, PaginationControlsComponent_Conditional_0_For_21_Template, 2, 3, "option", 10, i0.ɵɵrepeaterTrackByIdentity);
84
+ i0.ɵɵdomElementEnd()()()();
85
+ } if (rf & 2) {
86
+ const vm_r7 = ctx;
87
+ const ctx_r1 = i0.ɵɵnextContext();
88
+ i0.ɵɵadvance(2);
89
+ i0.ɵɵtextInterpolate4(" Showing ", vm_r7.startItem, " to ", vm_r7.endItem, " of ", ctx_r1.totalCount.toLocaleString(), " ", ctx_r1.entityLabelPlural, " ");
90
+ i0.ɵɵadvance(2);
91
+ i0.ɵɵdomProperty("disabled", ctx_r1.currentPage === 1);
92
+ i0.ɵɵadvance(2);
93
+ i0.ɵɵdomProperty("disabled", ctx_r1.currentPage === 1);
94
+ i0.ɵɵadvance(2);
95
+ i0.ɵɵconditional(vm_r7.showStartEllipsis ? 8 : -1);
96
+ i0.ɵɵadvance();
97
+ i0.ɵɵrepeater(vm_r7.pageNumbers);
98
+ i0.ɵɵadvance(2);
99
+ i0.ɵɵconditional(vm_r7.showEndEllipsis ? 11 : -1);
100
+ i0.ɵɵadvance();
101
+ i0.ɵɵdomProperty("disabled", ctx_r1.currentPage >= vm_r7.totalPages);
102
+ i0.ɵɵadvance(2);
103
+ i0.ɵɵdomProperty("disabled", ctx_r1.currentPage >= vm_r7.totalPages);
104
+ i0.ɵɵadvance(5);
105
+ i0.ɵɵdomProperty("value", ctx_r1.pageSize);
106
+ i0.ɵɵadvance();
107
+ i0.ɵɵrepeater(vm_r7.pageSizeOptions);
108
+ } }
109
+ /**
110
+ * Pagination controls component using Angular Material styling.
111
+ * Standalone component with inline template - no Angular Material dependency for pagination.
112
+ */
113
+ export class PaginationControlsComponent extends BasePaginationControlsComponent {
114
+ static { this.ɵfac = /*@__PURE__*/ (() => { let ɵPaginationControlsComponent_BaseFactory; return function PaginationControlsComponent_Factory(__ngFactoryType__) { return (ɵPaginationControlsComponent_BaseFactory || (ɵPaginationControlsComponent_BaseFactory = i0.ɵɵgetInheritedFactory(PaginationControlsComponent)))(__ngFactoryType__ || PaginationControlsComponent); }; })(); }
115
+ static { this.ɵcmp = /*@__PURE__*/ i0.ɵɵdefineComponent({ type: PaginationControlsComponent, selectors: [["ogrid-pagination-controls"]], features: [i0.ɵɵInheritDefinitionFeature], decls: 1, vars: 1, consts: [["role", "navigation", "aria-label", "Pagination", 1, "ogrid-pagination"], [1, "ogrid-pagination__info"], [1, "ogrid-pagination__pages"], ["aria-label", "First page", 1, "ogrid-pagination__btn", 3, "click", "disabled"], ["aria-label", "Previous page", 1, "ogrid-pagination__btn", 3, "click", "disabled"], [1, "ogrid-pagination__btn", 3, "ogrid-pagination__btn--active"], ["aria-label", "Next page", 1, "ogrid-pagination__btn", 3, "click", "disabled"], ["aria-label", "Last page", 1, "ogrid-pagination__btn", 3, "click", "disabled"], [1, "ogrid-pagination__size"], ["aria-label", "Rows per page", 3, "change", "value"], [3, "value", "selected"], ["aria-label", "Page 1", 1, "ogrid-pagination__btn", 3, "click"], ["aria-hidden", "true", 1, "ogrid-pagination__ellipsis"], [1, "ogrid-pagination__btn", 3, "click"]], template: function PaginationControlsComponent_Template(rf, ctx) { if (rf & 1) {
116
+ i0.ɵɵconditionalCreate(0, PaginationControlsComponent_Conditional_0_Template, 22, 11, "nav", 0);
117
+ } if (rf & 2) {
118
+ let tmp_0_0;
119
+ i0.ɵɵconditional((tmp_0_0 = ctx.vm()) ? 0 : -1, tmp_0_0);
120
+ } }, styles: ["[_nghost-%COMP%] { display: block; }\n .ogrid-pagination[_ngcontent-%COMP%] {\n display: flex; align-items: center; justify-content: space-between;\n flex-wrap: wrap; gap: 8px; padding: 6px 12px; font-size: 14px;\n color: var(--ogrid-fg, rgba(0, 0, 0, 0.87));\n }\n .ogrid-pagination__info[_ngcontent-%COMP%] { color: var(--ogrid-fg-secondary, rgba(0, 0, 0, 0.6)); }\n .ogrid-pagination__pages[_ngcontent-%COMP%] { display: flex; align-items: center; gap: 2px; }\n .ogrid-pagination__btn[_ngcontent-%COMP%] {\n min-width: 32px; height: 32px; padding: 0 6px;\n border: 1px solid var(--ogrid-border, rgba(0, 0, 0, 0.23)); border-radius: 4px;\n background: transparent; cursor: pointer; font-size: 14px;\n color: var(--ogrid-fg, rgba(0, 0, 0, 0.87));\n }\n .ogrid-pagination__btn[_ngcontent-%COMP%]:hover:not(:disabled) { background: var(--ogrid-hover-bg, rgba(0, 0, 0, 0.04)); }\n .ogrid-pagination__btn[_ngcontent-%COMP%]:disabled { opacity: 0.38; cursor: default; }\n .ogrid-pagination__btn--active[_ngcontent-%COMP%] {\n background: var(--mat-sys-primary, #1976d2); color: #fff;\n border-color: var(--mat-sys-primary, #1976d2);\n }\n .ogrid-pagination__ellipsis[_ngcontent-%COMP%] { margin: 0 4px; color: var(--ogrid-fg-secondary, rgba(0, 0, 0, 0.6)); }\n .ogrid-pagination__size[_ngcontent-%COMP%] { display: flex; align-items: center; gap: 8px; color: var(--ogrid-fg, rgba(0, 0, 0, 0.87)); }\n .ogrid-pagination__size[_ngcontent-%COMP%] select[_ngcontent-%COMP%] {\n min-width: 60px; height: 32px; padding: 4px 8px;\n border: 1px solid var(--ogrid-border, rgba(0, 0, 0, 0.23)); border-radius: 4px;\n font-size: 14px; margin-left: 8px;\n background: var(--ogrid-bg, #ffffff); color: var(--ogrid-fg, rgba(0, 0, 0, 0.87));\n }\n @media (max-width: 576px) {\n .ogrid-pagination[_ngcontent-%COMP%] { flex-direction: column; align-items: stretch; gap: 6px; padding: 6px 8px; font-size: 12px; }\n .ogrid-pagination__pages[_ngcontent-%COMP%] { order: -1; justify-content: center; }\n .ogrid-pagination__info[_ngcontent-%COMP%] { text-align: center; font-size: 11px; }\n .ogrid-pagination__size[_ngcontent-%COMP%] { font-size: 11px; justify-content: center; }\n }"], changeDetection: 0 }); }
121
+ }
122
+ (() => { (typeof ngDevMode === "undefined" || ngDevMode) && i0.ɵsetClassMetadata(PaginationControlsComponent, [{
123
+ type: Component,
124
+ args: [{ selector: 'ogrid-pagination-controls', standalone: true, changeDetection: ChangeDetectionStrategy.OnPush, template: `
125
+ @if (vm(); as vm) {
126
+ <nav class="ogrid-pagination" role="navigation" aria-label="Pagination">
127
+ <span class="ogrid-pagination__info">
128
+ Showing {{ vm.startItem }} to {{ vm.endItem }} of {{ totalCount.toLocaleString() }} {{ entityLabelPlural }}
129
+ </span>
130
+
131
+ <span class="ogrid-pagination__pages">
132
+ <button
133
+ class="ogrid-pagination__btn"
134
+ [disabled]="currentPage === 1"
135
+ (click)="pageChange.emit(1)"
136
+ aria-label="First page"
137
+ >&laquo;</button>
138
+ <button
139
+ class="ogrid-pagination__btn"
140
+ [disabled]="currentPage === 1"
141
+ (click)="pageChange.emit(currentPage - 1)"
142
+ aria-label="Previous page"
143
+ >&lsaquo;</button>
144
+
145
+ @if (vm.showStartEllipsis) {
146
+ <button class="ogrid-pagination__btn" (click)="pageChange.emit(1)" aria-label="Page 1">1</button>
147
+ <span class="ogrid-pagination__ellipsis" aria-hidden="true">&hellip;</span>
148
+ }
149
+
150
+ @for (pageNum of vm.pageNumbers; track pageNum) {
151
+ <button
152
+ class="ogrid-pagination__btn"
153
+ [class.ogrid-pagination__btn--active]="currentPage === pageNum"
154
+ (click)="pageChange.emit(pageNum)"
155
+ [attr.aria-label]="'Page ' + pageNum"
156
+ [attr.aria-current]="currentPage === pageNum ? 'page' : null"
157
+ >{{ pageNum }}</button>
158
+ }
159
+
160
+ @if (vm.showEndEllipsis) {
161
+ <span class="ogrid-pagination__ellipsis" aria-hidden="true">&hellip;</span>
162
+ <button
163
+ class="ogrid-pagination__btn"
164
+ (click)="pageChange.emit(vm.totalPages)"
165
+ [attr.aria-label]="'Page ' + vm.totalPages"
166
+ >{{ vm.totalPages }}</button>
167
+ }
168
+
169
+ <button
170
+ class="ogrid-pagination__btn"
171
+ [disabled]="currentPage >= vm.totalPages"
172
+ (click)="pageChange.emit(currentPage + 1)"
173
+ aria-label="Next page"
174
+ >&rsaquo;</button>
175
+ <button
176
+ class="ogrid-pagination__btn"
177
+ [disabled]="currentPage >= vm.totalPages"
178
+ (click)="pageChange.emit(vm.totalPages)"
179
+ aria-label="Last page"
180
+ >&raquo;</button>
181
+ </span>
182
+
183
+ <span class="ogrid-pagination__size">
184
+ <label>Rows
185
+ <select
186
+ [value]="pageSize"
187
+ (change)="onPageSizeSelect($event)"
188
+ aria-label="Rows per page"
189
+ >
190
+ @for (n of vm.pageSizeOptions; track n) {
191
+ <option [value]="n" [selected]="pageSize === n">{{ n }}</option>
192
+ }
193
+ </select>
194
+ </label>
195
+ </span>
196
+ </nav>
197
+ }
198
+ `, styles: ["\n :host { display: block; }\n .ogrid-pagination {\n display: flex; align-items: center; justify-content: space-between;\n flex-wrap: wrap; gap: 8px; padding: 6px 12px; font-size: 14px;\n color: var(--ogrid-fg, rgba(0, 0, 0, 0.87));\n }\n .ogrid-pagination__info { color: var(--ogrid-fg-secondary, rgba(0, 0, 0, 0.6)); }\n .ogrid-pagination__pages { display: flex; align-items: center; gap: 2px; }\n .ogrid-pagination__btn {\n min-width: 32px; height: 32px; padding: 0 6px;\n border: 1px solid var(--ogrid-border, rgba(0, 0, 0, 0.23)); border-radius: 4px;\n background: transparent; cursor: pointer; font-size: 14px;\n color: var(--ogrid-fg, rgba(0, 0, 0, 0.87));\n }\n .ogrid-pagination__btn:hover:not(:disabled) { background: var(--ogrid-hover-bg, rgba(0, 0, 0, 0.04)); }\n .ogrid-pagination__btn:disabled { opacity: 0.38; cursor: default; }\n .ogrid-pagination__btn--active {\n background: var(--mat-sys-primary, #1976d2); color: #fff;\n border-color: var(--mat-sys-primary, #1976d2);\n }\n .ogrid-pagination__ellipsis { margin: 0 4px; color: var(--ogrid-fg-secondary, rgba(0, 0, 0, 0.6)); }\n .ogrid-pagination__size { display: flex; align-items: center; gap: 8px; color: var(--ogrid-fg, rgba(0, 0, 0, 0.87)); }\n .ogrid-pagination__size select {\n min-width: 60px; height: 32px; padding: 4px 8px;\n border: 1px solid var(--ogrid-border, rgba(0, 0, 0, 0.23)); border-radius: 4px;\n font-size: 14px; margin-left: 8px;\n background: var(--ogrid-bg, #ffffff); color: var(--ogrid-fg, rgba(0, 0, 0, 0.87));\n }\n @media (max-width: 576px) {\n .ogrid-pagination { flex-direction: column; align-items: stretch; gap: 6px; padding: 6px 8px; font-size: 12px; }\n .ogrid-pagination__pages { order: -1; justify-content: center; }\n .ogrid-pagination__info { text-align: center; font-size: 11px; }\n .ogrid-pagination__size { font-size: 11px; justify-content: center; }\n }\n "] }]
199
+ }], null, null); })();
200
+ (() => { (typeof ngDevMode === "undefined" || ngDevMode) && i0.ɵsetClassDebugInfo(PaginationControlsComponent, { className: "PaginationControlsComponent", filePath: "pagination-controls/pagination-controls.component.ts", lineNumber: 124 }); })();
@@ -1,8 +1,12 @@
1
1
  import { BaseColumnChooserComponent } from '@alaarab/ogrid-angular';
2
+ import * as i0 from "@angular/core";
2
3
  /**
3
4
  * Column visibility chooser dropdown using Angular Material styling.
4
5
  * Standalone component with inline template.
5
6
  */
6
7
  export declare class ColumnChooserComponent extends BaseColumnChooserComponent {
8
+ onEscape(event: KeyboardEvent): void;
7
9
  onDocumentClick(event: MouseEvent): void;
10
+ static ɵfac: i0.ɵɵFactoryDeclaration<ColumnChooserComponent, never>;
11
+ static ɵcmp: i0.ɵɵComponentDeclaration<ColumnChooserComponent, "ogrid-column-chooser", never, {}, {}, never, never, true, never>;
8
12
  }
@@ -1,5 +1,6 @@
1
1
  import { ElementRef } from '@angular/core';
2
2
  import { BaseColumnHeaderFilterComponent } from '@alaarab/ogrid-angular';
3
+ import * as i0 from "@angular/core";
3
4
  /**
4
5
  * Column header filter component with sort + filter icon + popover.
5
6
  * Standalone component with inline template.
@@ -8,4 +9,6 @@ export declare class ColumnHeaderFilterComponent extends BaseColumnHeaderFilterC
8
9
  private headerEl?;
9
10
  protected getHeaderEl(): ElementRef<HTMLElement> | undefined;
10
11
  onDocumentClickWrapper(event: MouseEvent): void;
12
+ static ɵfac: i0.ɵɵFactoryDeclaration<ColumnHeaderFilterComponent, never>;
13
+ static ɵcmp: i0.ɵɵComponentDeclaration<ColumnHeaderFilterComponent, "ogrid-column-header-filter", never, {}, {}, never, never, true, never>;
11
14
  }
@@ -1,5 +1,8 @@
1
1
  import { MatMenuTrigger } from '@angular/material/menu';
2
2
  import { BaseColumnHeaderMenuComponent } from '@alaarab/ogrid-angular';
3
+ import * as i0 from "@angular/core";
3
4
  export declare class ColumnHeaderMenuComponent extends BaseColumnHeaderMenuComponent {
4
5
  menuTrigger?: MatMenuTrigger;
6
+ static ɵfac: i0.ɵɵFactoryDeclaration<ColumnHeaderMenuComponent, never>;
7
+ static ɵcmp: i0.ɵɵComponentDeclaration<ColumnHeaderMenuComponent, "column-header-menu", never, {}, {}, never, never, true, never>;
5
8
  }
@@ -1,12 +1,19 @@
1
1
  import { ElementRef } from '@angular/core';
2
2
  import { BaseDataGridTableComponent } from '@alaarab/ogrid-angular';
3
3
  import type { IOGridDataGridProps } from '@alaarab/ogrid-angular';
4
+ import * as i0 from "@angular/core";
4
5
  /**
5
6
  * DataGridTable component using native HTML table with Material Design-inspired styling.
6
7
  * Standalone component - this is the workhorse of the grid.
7
8
  */
8
9
  export declare class DataGridTableComponent<T> extends BaseDataGridTableComponent<T> {
9
10
  private readonly propsSignal;
11
+ readonly statusBarClasses: {
12
+ statusBar: string;
13
+ statusBarItem: string;
14
+ statusBarLabel: string;
15
+ statusBarValue: string;
16
+ };
10
17
  set propsInput(value: IOGridDataGridProps<T>);
11
18
  private wrapperRef?;
12
19
  private tableContainerRef?;
@@ -18,4 +25,6 @@ export declare class DataGridTableComponent<T> extends BaseDataGridTableComponen
18
25
  protected getTableContainerRef(): ElementRef<HTMLElement> | undefined;
19
26
  getColumnLetter(colIdx: number): string;
20
27
  onResizeRowNumber(event: PointerEvent): void;
28
+ static ɵfac: i0.ɵɵFactoryDeclaration<DataGridTableComponent<any>, never>;
29
+ static ɵcmp: i0.ɵɵComponentDeclaration<DataGridTableComponent<any>, "ogrid-datagrid-table", never, { "propsInput": { "alias": "props"; "required": true; }; }, {}, never, never, true, never>;
21
30
  }
@@ -1,3 +1,6 @@
1
1
  import { BaseInlineCellEditorComponent } from '@alaarab/ogrid-angular';
2
+ import * as i0 from "@angular/core";
2
3
  export declare class InlineCellEditorComponent<T = unknown> extends BaseInlineCellEditorComponent<T> {
4
+ static ɵfac: i0.ɵɵFactoryDeclaration<InlineCellEditorComponent<any>, never>;
5
+ static ɵcmp: i0.ɵɵComponentDeclaration<InlineCellEditorComponent<any>, "ogrid-mat-inline-cell-editor", never, {}, {}, never, never, true, never>;
3
6
  }
@@ -1,3 +1,6 @@
1
1
  import { BasePopoverCellEditorComponent } from '@alaarab/ogrid-angular';
2
+ import * as i0 from "@angular/core";
2
3
  export declare class PopoverCellEditorComponent<T = unknown> extends BasePopoverCellEditorComponent<T> {
4
+ static ɵfac: i0.ɵɵFactoryDeclaration<PopoverCellEditorComponent<any>, never>;
5
+ static ɵcmp: i0.ɵɵComponentDeclaration<PopoverCellEditorComponent<any>, "ogrid-mat-popover-cell-editor", never, {}, {}, never, never, true, never>;
3
6
  }
@@ -1,4 +1,5 @@
1
1
  import { BaseOGridComponent } from '@alaarab/ogrid-angular';
2
+ import * as i0 from "@angular/core";
2
3
  /**
3
4
  * Top-level OGrid component for Angular Material.
4
5
  * Standalone component - provides OGridService and renders OGridLayout with all sub-components.
@@ -7,4 +8,6 @@ import { BaseOGridComponent } from '@alaarab/ogrid-angular';
7
8
  * The effect() reactively configures the service when the input signal changes.
8
9
  */
9
10
  export declare class OGridComponent<T> extends BaseOGridComponent<T> {
11
+ static ɵfac: i0.ɵɵFactoryDeclaration<OGridComponent<any>, never>;
12
+ static ɵcmp: i0.ɵɵComponentDeclaration<OGridComponent<any>, "ogrid", never, {}, {}, never, never, true, never>;
10
13
  }
@@ -1,7 +1,10 @@
1
1
  import { BasePaginationControlsComponent } from '@alaarab/ogrid-angular';
2
+ import * as i0 from "@angular/core";
2
3
  /**
3
4
  * Pagination controls component using Angular Material styling.
4
5
  * Standalone component with inline template - no Angular Material dependency for pagination.
5
6
  */
6
7
  export declare class PaginationControlsComponent extends BasePaginationControlsComponent {
8
+ static ɵfac: i0.ɵɵFactoryDeclaration<PaginationControlsComponent, never>;
9
+ static ɵcmp: i0.ɵɵComponentDeclaration<PaginationControlsComponent, "ogrid-pagination-controls", never, {}, {}, never, never, true, never>;
7
10
  }
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@alaarab/ogrid-angular-material",
3
- "version": "2.5.9",
3
+ "version": "2.6.1",
4
4
  "description": "OGrid Angular Material – MatTable-based data grid with sorting, filtering, pagination, column chooser, and CSV export.",
5
5
  "main": "dist/esm/index.js",
6
6
  "module": "dist/esm/index.js",
@@ -13,7 +13,7 @@
13
13
  }
14
14
  },
15
15
  "scripts": {
16
- "build": "rimraf dist && tsup && tsc -p tsconfig.build.json",
16
+ "build": "rimraf dist && ngc -p tsconfig.build.json",
17
17
  "test": "jest --passWithNoTests",
18
18
  "storybook": "ng run angular-material:storybook",
19
19
  "build-storybook": "ng run angular-material:build-storybook"
@@ -37,7 +37,7 @@
37
37
  "node": ">=18"
38
38
  },
39
39
  "dependencies": {
40
- "@alaarab/ogrid-angular": "2.5.9"
40
+ "@alaarab/ogrid-angular": "2.6.1"
41
41
  },
42
42
  "peerDependencies": {
43
43
  "@angular/cdk": "^21.0.0",