ng-firebase-table-kxp 1.2.4 → 1.2.6

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.
Files changed (34) hide show
  1. package/esm2020/lib/components/table/table.component.mjs +1557 -0
  2. package/esm2020/lib/components/table-tabs/table-tabs.component.mjs +129 -0
  3. package/esm2020/lib/components/table-tooltip/table-tooltip.component.mjs +49 -0
  4. package/esm2020/lib/ng-firebase-table-kxp.component.mjs +15 -0
  5. package/esm2020/lib/ng-firebase-table-kxp.module.mjs +103 -0
  6. package/esm2020/lib/ng-firebase-table-kxp.service.mjs +14 -0
  7. package/esm2020/lib/services/filter.service.mjs +416 -0
  8. package/esm2020/lib/services/pagination.service.mjs +115 -0
  9. package/esm2020/lib/services/table.service.mjs +1140 -0
  10. package/esm2020/lib/services/tooltip.service.mjs +141 -0
  11. package/esm2020/lib/types/Table.mjs +9 -0
  12. package/esm2020/lib/utils/table.utils.mjs +75 -0
  13. package/esm2020/ng-firebase-table-kxp.mjs +5 -0
  14. package/esm2020/public-api.mjs +22 -0
  15. package/fesm2015/ng-firebase-table-kxp.mjs +4026 -0
  16. package/fesm2015/ng-firebase-table-kxp.mjs.map +1 -0
  17. package/{fesm2022 → fesm2020}/ng-firebase-table-kxp.mjs +3666 -3659
  18. package/fesm2020/ng-firebase-table-kxp.mjs.map +1 -0
  19. package/index.d.ts +5 -666
  20. package/lib/components/table/table.component.d.ts +135 -0
  21. package/lib/components/table-tabs/table-tabs.component.d.ts +34 -0
  22. package/lib/components/table-tooltip/table-tooltip.component.d.ts +18 -0
  23. package/lib/ng-firebase-table-kxp.component.d.ts +5 -0
  24. package/lib/ng-firebase-table-kxp.module.d.ts +24 -0
  25. package/lib/ng-firebase-table-kxp.service.d.ts +6 -0
  26. package/lib/services/filter.service.d.ts +88 -0
  27. package/lib/services/pagination.service.d.ts +34 -0
  28. package/lib/services/table.service.d.ts +80 -0
  29. package/lib/services/tooltip.service.d.ts +73 -0
  30. package/lib/types/Table.d.ts +162 -0
  31. package/lib/utils/table.utils.d.ts +25 -0
  32. package/package.json +11 -3
  33. package/public-api.d.ts +12 -0
  34. package/fesm2022/ng-firebase-table-kxp.mjs.map +0 -1
package/index.d.ts CHANGED
@@ -1,666 +1,5 @@
1
- import * as i0 from '@angular/core';
2
- import { PipeTransform, OnInit, AfterViewInit, OnChanges, OnDestroy, ElementRef, ChangeDetectorRef, SimpleChanges, EventEmitter } from '@angular/core';
3
- import { CollectionReference, DocumentReference, QueryDocumentSnapshot, AngularFirestore } from '@angular/fire/compat/firestore';
4
- import firebase from 'firebase/compat';
5
- import { OrderByDirection } from 'firebase/firestore';
6
- import * as i9 from '@angular/material/paginator';
7
- import { PageEvent, MatPaginator } from '@angular/material/paginator';
8
- import * as i10 from '@angular/material/sort';
9
- import { MatSort } from '@angular/material/sort';
10
- import * as i8 from '@angular/material/table';
11
- import { MatTableDataSource } from '@angular/material/table';
12
- import * as i7 from '@angular/router';
13
- import { Router } from '@angular/router';
14
- import firebase$1 from 'firebase/compat/app';
15
- import * as i18 from '@angular/material/dialog';
16
- import { MatDialog } from '@angular/material/dialog';
17
- import { ToastrService } from 'ngx-toastr';
18
- import * as i6 from '@angular/forms';
19
- import { ValidatorFn, FormGroup, FormArray, FormControl } from '@angular/forms';
20
- import { BehaviorSubject } from 'rxjs';
21
- import * as i5 from '@angular/common';
22
- import * as i11 from '@angular/material/form-field';
23
- import * as i12 from '@angular/material/input';
24
- import * as i13 from '@angular/material/core';
25
- import * as i14 from '@angular/material/select';
26
- import * as i15 from '@angular/material/tooltip';
27
- import * as i16 from '@angular/material/progress-spinner';
28
- import * as i17 from '@angular/material/icon';
29
-
30
- declare class NgFirebaseTableKxpComponent {
31
- static ɵfac: i0.ɵɵFactoryDeclaration<NgFirebaseTableKxpComponent, never>;
32
- static ɵcmp: i0.ɵɵComponentDeclaration<NgFirebaseTableKxpComponent, "lib-ng-firebase-table-kxp", never, {}, {}, never, never, false, never>;
33
- }
34
-
35
- import WhereFilterOp$1 = firebase.firestore.WhereFilterOp;
36
-
37
- declare const TABLE_DEFAULTS: {
38
- SORT_FIELD: string;
39
- SORT_ORDER: "desc";
40
- PAGE_SIZE: number;
41
- DEBOUNCE_TIME_MS: number;
42
- DEFAULT_BG_COLOR: string;
43
- DEFAULT_TEXT_COLOR: string;
44
- };
45
- interface TableData {
46
- displayedColumns: Column[];
47
- filterableOptions?: FilterableOption[];
48
- collectionRef: CollectionReference<unknown>;
49
- collection: string;
50
- name: string;
51
- totalRef?: {
52
- ref: DocumentReference<unknown>;
53
- field: string;
54
- }[];
55
- download: boolean;
56
- pagination: boolean;
57
- isNotClickable?: boolean;
58
- url?: string;
59
- sortBy?: {
60
- field: string;
61
- order: OrderByDirection;
62
- };
63
- conditions?: {
64
- operator: WhereFilterOp$1;
65
- firestoreProperty: string;
66
- dashProperty: string | string[];
67
- }[];
68
- filterFn?: (item: any) => boolean;
69
- color?: {
70
- bg: string;
71
- text: string;
72
- };
73
- showSimpleSearch?: boolean;
74
- actionButton?: {
75
- label: string;
76
- routerLink: string;
77
- icon?: string;
78
- colorClass?: string;
79
- method?: (row: any, event?: any) => any;
80
- condition?: (row?: any) => boolean;
81
- };
82
- tabs?: Tab;
83
- }
84
- interface Tab {
85
- method: (tab: any, event?: any) => any;
86
- tabsData: TabData[];
87
- }
88
- interface TabData {
89
- label: string;
90
- counter?: number;
91
- counterClass?: string;
92
- }
93
- interface Column {
94
- property: string;
95
- title?: string;
96
- charLimit?: number;
97
- pipe?: PipeTransform;
98
- iconClass?: {
99
- text?: string;
100
- class?: string;
101
- condition?: (row: any) => any;
102
- buttonMethod?: (row: any, event?: any) => any;
103
- }[];
104
- isSortable?: boolean;
105
- isFilterable?: boolean;
106
- isFilterableByDate?: boolean;
107
- hasLink?: boolean | string;
108
- hasDownload?: boolean | string;
109
- relation?: {
110
- targetedCollection: string;
111
- sourceProperty: string;
112
- targetedProperty: string;
113
- };
114
- queryLength?: {
115
- collection: string;
116
- property: string;
117
- operator: WhereFilterOp$1;
118
- value: string;
119
- };
120
- image?: Image;
121
- method?: (row: any, event?: any) => any;
122
- filterPredicates?: string[];
123
- calculateValue?: (row: any) => any;
124
- arrayField?: string;
125
- tooltip?: {
126
- color: string;
127
- text: string;
128
- };
129
- }
130
- interface Image {
131
- class: string;
132
- path?: string;
133
- url?: boolean;
134
- default?: string;
135
- }
136
- interface FilterableOption {
137
- title: string;
138
- items: {
139
- property: string;
140
- value: string | boolean;
141
- label: string;
142
- }[];
143
- }
144
- interface Pagination {
145
- batchSize: number;
146
- collection: string;
147
- doc?: {
148
- firstDoc: QueryDocumentSnapshot<any> | null;
149
- lastDoc: QueryDocumentSnapshot<any> | null;
150
- };
151
- navigation: 'reload' | 'forward' | 'backward';
152
- arrange: Arrange;
153
- conditions?: Condition[];
154
- filterFn?: (item: any) => boolean;
155
- size?: number;
156
- clientPageIndex?: number;
157
- }
158
- interface Condition {
159
- operator: WhereFilterOp$1;
160
- firestoreProperty: string;
161
- dashProperty: string | string[];
162
- }
163
- interface Arrange {
164
- filters: {
165
- arrange: 'ascending' | 'descending' | 'filter' | 'filterByDate' | 'equals' | '';
166
- filter?: {
167
- property: string;
168
- filtering: string;
169
- } | null;
170
- dateFilter?: {
171
- initial: Date;
172
- final: Date;
173
- };
174
- }[];
175
- sortBy: {
176
- field: string;
177
- order: OrderByDirection;
178
- };
179
- elementId?: {
180
- property: string;
181
- value: string;
182
- };
183
- }
184
- type DropdownItem = Column & {
185
- arrange: 'filter' | 'filterByDate' | 'equals' | 'ascending' | 'descending';
186
- title: string;
187
- icon?: string;
188
- };
189
- interface FilterSelectItem {
190
- property: string;
191
- value: string | boolean;
192
- label: string;
193
- }
194
-
195
- interface PaginationResult {
196
- items: Array<Record<string, unknown> & {
197
- id: string;
198
- }>;
199
- filterLength: number | null;
200
- firstDoc: firebase$1.firestore.QueryDocumentSnapshot<unknown> | null;
201
- lastDoc: firebase$1.firestore.QueryDocumentSnapshot<unknown> | null;
202
- hasNextPage: boolean;
203
- hasPreviousPage?: boolean;
204
- currentClientPageIndex?: number;
205
- totalPages?: number;
206
- }
207
- declare class TableService {
208
- private ngFire;
209
- private dialog;
210
- private toastr;
211
- constructor(ngFire: AngularFirestore, dialog: MatDialog, toastr: ToastrService);
212
- getItems(collection: CollectionReference<unknown>): Promise<Array<Record<string, unknown> & {
213
- id: string;
214
- }>>;
215
- private executeQuery;
216
- applyFilters(query: firebase$1.firestore.Query<unknown>, arrange: Arrange, conditions: Condition[] | undefined): firebase$1.firestore.Query<unknown>;
217
- private getIdFilter;
218
- private getDocumentById;
219
- private searchByIdPartial;
220
- private shouldUseClientSideFallback;
221
- getPaginated(params: Pagination): Promise<PaginationResult>;
222
- executeClientSideQuery(params: Pagination): Promise<PaginationResult>;
223
- getItemsData(collection: string, arrange: Arrange, conditions?: Condition[] | undefined): Promise<Array<Record<string, unknown> & {
224
- id: string;
225
- }>>;
226
- operators: {
227
- '==': (a: unknown, b: unknown) => boolean;
228
- '!=': (a: unknown, b: unknown) => boolean;
229
- '>': (a: unknown, b: unknown) => boolean;
230
- '<': (a: unknown, b: unknown) => boolean;
231
- '>=': (a: unknown, b: unknown) => boolean;
232
- '<=': (a: unknown, b: unknown) => boolean;
233
- in: (a: unknown, b: unknown) => boolean;
234
- 'not-in': (a: unknown, b: unknown) => boolean;
235
- 'array-contains': (a: unknown, b: unknown) => boolean;
236
- 'array-contains-any': (a: unknown, b: unknown) => boolean;
237
- includes: (a: unknown, b: unknown) => boolean;
238
- };
239
- deleteIndex(id: string, col: string): Promise<boolean>;
240
- reindex(index: number, col: string, batch: firebase$1.firestore.WriteBatch): Promise<void>;
241
- dateFormatValidator(): ValidatorFn;
242
- updateIndex(index: number, id: string, col: string): Promise<void>;
243
- /**
244
- * Extrai o link de criação de índice da mensagem de erro do Firestore
245
- */
246
- private extractIndexLink;
247
- /**
248
- * Rastreia índices ausentes ao usar fallback preventivo
249
- */
250
- private trackMissingIndexPreventive;
251
- /**
252
- * Gera uma assinatura única para uma query
253
- */
254
- private generateQuerySignature;
255
- /**
256
- * Gera instruções claras para criar o índice manualmente
257
- */
258
- private generateIndexInstructions;
259
- /**
260
- * Gera um link de índice baseado na estrutura da query
261
- */
262
- private generateIndexLink;
263
- private trackMissingIndex;
264
- static ɵfac: i0.ɵɵFactoryDeclaration<TableService, [{ optional: true; }, { optional: true; }, { optional: true; }]>;
265
- static ɵprov: i0.ɵɵInjectableDeclaration<TableService>;
266
- }
267
-
268
- interface FilterConfig {
269
- selectFilter: any;
270
- typeFilter?: string;
271
- selectItem?: any[];
272
- initialDate?: string;
273
- finalDate?: string;
274
- }
275
- interface DateFiltersByProperty {
276
- [property: string]: Array<{
277
- initial: Date;
278
- final: Date;
279
- }>;
280
- }
281
- interface ProcessedFilter {
282
- group: FormGroup;
283
- selectedFilter: any;
284
- arrange: string;
285
- }
286
- declare class FilterService {
287
- private tableService;
288
- constructor(tableService: TableService);
289
- /**
290
- * Cria um novo FormGroup para um filtro
291
- */
292
- createFilterGroup(): FormGroup;
293
- /**
294
- * Adiciona um novo filtro ao FormArray
295
- */
296
- addFilter(filtersForm: FormArray, isPaginated: boolean, filterData?: FilterConfig): void;
297
- /**
298
- * Verifica se há um filtro de data ativo
299
- */
300
- hasActiveDateFilter(filtersForm: FormArray): boolean;
301
- /**
302
- * Retorna as opções de filtro disponíveis
303
- */
304
- getAvailableFilterOptions(dropdownItems: any[], isPaginated: boolean, filtersForm: FormArray): any[];
305
- /**
306
- * Remove um filtro do FormArray
307
- */
308
- removeFilter(filtersForm: FormArray, index: number): void;
309
- /**
310
- * Remove todos os filtros do FormArray
311
- */
312
- removeAllFilters(filtersForm: FormArray): void;
313
- /**
314
- * Aplica máscara de data (DD/MM/AAAA)
315
- */
316
- applyDateMask(event: any, controlName: 'initialDate' | 'finalDate', filterGroup: FormGroup): void;
317
- /**
318
- * Aplica filtros client-side aos itens
319
- */
320
- applyClientSideFilters<T = any>(items: T[], filtersForm: FormArray, sortBy: {
321
- field: string;
322
- order: OrderByDirection;
323
- }): T[];
324
- /**
325
- * Constrói o objeto Arrange a partir dos filtros ativos
326
- */
327
- buildArrangeFromFilters(filtersForm: FormArray, sortBy: {
328
- field: string;
329
- order: OrderByDirection;
330
- }): Arrange;
331
- /**
332
- * Extrai filtros ativos para paginação
333
- */
334
- extractActiveFilters(filtersForm: FormArray): any[];
335
- /**
336
- * Inicializa os dropdownItems baseado nas colunas
337
- */
338
- initializeDropdownItems(displayedColumns: Column[]): {
339
- dropdownItems: any[];
340
- sortableDropdownItems: any[];
341
- hasFilterableColumn: boolean;
342
- hasSortableColumn: boolean;
343
- };
344
- /**
345
- * Adiciona opções de filtro customizadas
346
- */
347
- addFilterableOptions(dropdownItems: any[], filterableOptions: any[]): any[];
348
- static ɵfac: i0.ɵɵFactoryDeclaration<FilterService, never>;
349
- static ɵprov: i0.ɵɵInjectableDeclaration<FilterService>;
350
- }
351
-
352
- interface TooltipState {
353
- hoveredCell: {
354
- row: any;
355
- col: any;
356
- } | null;
357
- showTooltip: boolean;
358
- tooltipContent: string;
359
- tooltipPosition: {
360
- x: number;
361
- y: number;
362
- };
363
- tooltipBgColor: string;
364
- tooltipBgStyle: {
365
- [key: string]: string;
366
- } | null;
367
- tooltipTextColor: string;
368
- tooltipTextStyle: {
369
- [key: string]: string;
370
- } | null;
371
- }
372
- interface TooltipConfig {
373
- color?: string;
374
- text?: string;
375
- }
376
- declare class TooltipService {
377
- private tooltipTimeout;
378
- /**
379
- * Cria um estado inicial para o tooltip
380
- */
381
- createInitialState(): TooltipState;
382
- /**
383
- * Processa as cores do tooltip
384
- */
385
- processTooltipColors(config?: TooltipConfig): {
386
- bgColor: string;
387
- bgStyle: {
388
- [key: string]: string;
389
- } | null;
390
- textColor: string;
391
- textStyle: {
392
- [key: string]: string;
393
- } | null;
394
- };
395
- /**
396
- * Manipula o evento de mouse enter na célula
397
- */
398
- handleMouseEnter(event: MouseEvent, row: any, col: Column, getDisplayValue: (col: Column, row: any, withinLimit: boolean) => string, onShow: (state: Partial<TooltipState>) => void): void;
399
- /**
400
- * Manipula o evento de mouse leave na célula
401
- */
402
- handleMouseLeave(onHide: (state: TooltipState) => void): void;
403
- /**
404
- * Manipula o movimento do mouse
405
- */
406
- handleMouseMove(event: MouseEvent, showTooltip: boolean, onMove: (position: {
407
- x: number;
408
- y: number;
409
- }) => void): void;
410
- /**
411
- * Combina estilos do tooltip para aplicação
412
- */
413
- getTooltipStyles(state: TooltipState): {
414
- [key: string]: string;
415
- };
416
- /**
417
- * Limpa recursos ao destruir
418
- */
419
- destroy(): void;
420
- static ɵfac: i0.ɵɵFactoryDeclaration<TooltipService, never>;
421
- static ɵprov: i0.ɵɵInjectableDeclaration<TooltipService>;
422
- }
423
-
424
- interface PaginationState {
425
- currentPageNumber: number;
426
- currentClientPageIndex: number;
427
- pageSize: number;
428
- totalItems: number;
429
- hasNextPage: boolean;
430
- }
431
- interface NavigationResult {
432
- direction: 'forward' | 'backward' | 'reload';
433
- resetDocs: boolean;
434
- originalPageSize: number | null;
435
- shouldNavigate: boolean;
436
- newClientPageIndex: number;
437
- newPageNumber: number;
438
- }
439
- declare class PaginationService {
440
- calculateNavigation(event: PageEvent, currentState: PaginationState): NavigationResult;
441
- /**
442
- * Calcula o número de itens esperados na última página
443
- */
444
- calculateLastPageItemCount(totalItems: number, pageSize: number): number;
445
- /**
446
- * Calcula o índice da última página
447
- */
448
- calculateLastPageIndex(totalItems: number, pageSize: number): number;
449
- /**
450
- * Verifica se deve mostrar o botão de próxima página
451
- */
452
- shouldShowNextButton(hasNextPage: boolean, isPaginated: boolean): boolean;
453
- static ɵfac: i0.ɵɵFactoryDeclaration<PaginationService, never>;
454
- static ɵprov: i0.ɵɵInjectableDeclaration<PaginationService>;
455
- }
456
-
457
- import WhereFilterOp = firebase.firestore.WhereFilterOp;
458
-
459
- declare class TableComponent<T = any> implements OnInit, AfterViewInit, OnChanges, OnDestroy {
460
- private router;
461
- private tableService;
462
- private filterService;
463
- private tooltipService;
464
- private paginationService;
465
- private firestore;
466
- private el;
467
- private cdr;
468
- data: TableData;
469
- downloadTable?: (arrange: Arrange, conditions: Condition[]) => void;
470
- arrange: Arrange | null;
471
- dataSource: MatTableDataSource<T>;
472
- currentPageNumber: number;
473
- currentClientPageIndex: number;
474
- isLoading$: BehaviorSubject<boolean>;
475
- items: T[];
476
- filteredItems: T[];
477
- private lastDoc;
478
- private firstDoc;
479
- private sortBy;
480
- columnProperties: string[];
481
- filtersForm: FormArray;
482
- selectSort: FormControl;
483
- currentArrange: string;
484
- hasNextPage: boolean;
485
- dropdownItems: DropdownItem[];
486
- sortableDropdownItems: DropdownItem[];
487
- pageSize: number;
488
- totalItems: number;
489
- pageEvent?: PageEvent;
490
- filterValue: string | null;
491
- hasFilterableColumn: boolean;
492
- hasSortableColumn: boolean;
493
- filterPredicate: ((data: T, filter: string) => boolean) | undefined;
494
- private filterSubject;
495
- private readonly debounceTimeMs;
496
- selectedTab: number;
497
- paginator: MatPaginator;
498
- sort: MatSort;
499
- tooltipState: TooltipState;
500
- imageLoadingState: Map<string, boolean>;
501
- private destroy$;
502
- constructor(router: Router, tableService: TableService, filterService: FilterService, tooltipService: TooltipService, paginationService: PaginationService, firestore: AngularFirestore, el: ElementRef, cdr: ChangeDetectorRef);
503
- getActionButtonClass(): string;
504
- getTableRowNgClass(): Record<string, boolean>;
505
- getPaginatorNgClass(): Record<string, boolean>;
506
- createFilterGroup(): FormGroup;
507
- addFilter(filterData?: {
508
- selectFilter: DropdownItem | null;
509
- typeFilter?: string;
510
- selectItem?: FilterSelectItem[];
511
- initialDate?: string;
512
- finalDate?: string;
513
- }): void;
514
- hasActiveDateFilter(): boolean;
515
- getAvailableFilterOptions(): DropdownItem[];
516
- onSelectFilterChange(): void;
517
- removeFilter(index: number): void;
518
- removeAllFilters(): void;
519
- onDateInput(event: Event, controlName: 'initialDate' | 'finalDate', filterIndex: number): void;
520
- onDateFilterChange(): void;
521
- private applyFiltersToDataSource;
522
- private applyClientSideFilters;
523
- private buildArrangeFromFilters;
524
- getTooltipStyles(): {
525
- [key: string]: string;
526
- };
527
- onCellMouseEnter(event: MouseEvent, row: T, col: Column): void;
528
- onCellMouseLeave(): void;
529
- onCellMouseMove(event: MouseEvent): void;
530
- onTabSelected(event: {
531
- tab: TabData;
532
- index: number;
533
- }): void;
534
- getDisplayValue(col: Column, row: T, withinLimit?: boolean): string;
535
- getNestedValue(obj: unknown, path: string): unknown;
536
- isString(value: unknown): boolean;
537
- trackByProperty(_index: number, col: Column): string;
538
- private getImageKey;
539
- isImageLoading(row: T, col: Column): boolean;
540
- onImageLoad(row: T, col: Column): void;
541
- onImageError(event: Event, row: T, col: Column, defaultImage?: string): void;
542
- ngOnChanges(changes: SimpleChanges): void;
543
- ngAfterViewInit(): void;
544
- ngOnDestroy(): void;
545
- private applyCustomColors;
546
- ngOnInit(): Promise<void>;
547
- private loadItems;
548
- private loadItemsPaginated;
549
- onPageChange(event?: PageEvent): Promise<void>;
550
- applyFilter(value: string): void;
551
- search(event?: Event): Promise<void>;
552
- resetFilter(): Promise<void>;
553
- goToDetails(row: T): void;
554
- getRelation(params: {
555
- id: string;
556
- collection: string;
557
- newProperty: string;
558
- }): Promise<string>;
559
- private loadRelations;
560
- getQueryLength(params: {
561
- item: T;
562
- relation: {
563
- collection: string;
564
- property: string;
565
- operator: WhereFilterOp;
566
- value: string;
567
- };
568
- }): Promise<number>;
569
- private loadQueryLengths;
570
- private filterItems;
571
- reloadTable(): Promise<void>;
572
- updateDisplayedColumns(): void;
573
- shouldShowActionButton(): boolean;
574
- handleDownload(): void;
575
- static ɵfac: i0.ɵɵFactoryDeclaration<TableComponent<any>, never>;
576
- static ɵcmp: i0.ɵɵComponentDeclaration<TableComponent<any>, "lib-table", never, { "data": { "alias": "data"; "required": false; }; "downloadTable": { "alias": "downloadTable"; "required": false; }; }, {}, never, never, false, never>;
577
- }
578
-
579
- declare class TableTabsComponent {
580
- tabsData: TabData[];
581
- selectedTab: number;
582
- tabSelected: EventEmitter<{
583
- tab: TabData;
584
- index: number;
585
- }>;
586
- private readonly TABS_PER_GROUP;
587
- /**
588
- * Retorna os índices dos grupos de tabs (invertidos para exibição vertical)
589
- */
590
- getTabGroups(): number[];
591
- /**
592
- * Retorna os tabs de um grupo específico
593
- */
594
- getTabGroup(groupIndex: number): TabData[];
595
- /**
596
- * Calcula o índice real do tab considerando a inversão vertical
597
- */
598
- getRealTabIndex(groupDisplayIndex: number, tabIndexInGroup: number): number;
599
- /**
600
- * Manipula a seleção de um tab
601
- */
602
- onTabSelected(groupDisplayIndex: number, tabIndexInGroup: number): void;
603
- /**
604
- * Verifica se um tab está selecionado
605
- */
606
- isTabSelected(originalIndex: number): boolean;
607
- static ɵfac: i0.ɵɵFactoryDeclaration<TableTabsComponent, never>;
608
- static ɵcmp: i0.ɵɵComponentDeclaration<TableTabsComponent, "lib-table-tabs", never, { "tabsData": { "alias": "tabsData"; "required": false; }; "selectedTab": { "alias": "selectedTab"; "required": false; }; }, { "tabSelected": "tabSelected"; }, never, never, false, never>;
609
- }
610
-
611
- declare class TableTooltipComponent {
612
- state: TooltipState;
613
- styles: {
614
- [key: string]: string;
615
- };
616
- get showTooltip(): boolean;
617
- get tooltipContent(): string;
618
- get tooltipPosition(): {
619
- x: number;
620
- y: number;
621
- };
622
- get tooltipBgColor(): string;
623
- get tooltipTextColor(): string;
624
- static ɵfac: i0.ɵɵFactoryDeclaration<TableTooltipComponent, never>;
625
- static ɵcmp: i0.ɵɵComponentDeclaration<TableTooltipComponent, "lib-table-tooltip", never, { "state": { "alias": "state"; "required": false; }; "styles": { "alias": "styles"; "required": false; }; }, {}, never, never, false, never>;
626
- }
627
-
628
- declare class NgFirebaseTableKxpModule {
629
- static ɵfac: i0.ɵɵFactoryDeclaration<NgFirebaseTableKxpModule, never>;
630
- static ɵmod: i0.ɵɵNgModuleDeclaration<NgFirebaseTableKxpModule, [typeof NgFirebaseTableKxpComponent, typeof TableComponent, typeof TableTabsComponent, typeof TableTooltipComponent], [typeof i5.CommonModule, typeof i6.ReactiveFormsModule, typeof i6.FormsModule, typeof i7.RouterModule, typeof i8.MatTableModule, typeof i9.MatPaginatorModule, typeof i10.MatSortModule, typeof i11.MatFormFieldModule, typeof i12.MatInputModule, typeof i13.MatOptionModule, typeof i14.MatSelectModule, typeof i15.MatTooltipModule, typeof i16.MatProgressSpinnerModule, typeof i17.MatIconModule, typeof i18.MatDialogModule], [typeof NgFirebaseTableKxpComponent, typeof TableComponent, typeof TableTabsComponent, typeof TableTooltipComponent]>;
631
- static ɵinj: i0.ɵɵInjectorDeclaration<NgFirebaseTableKxpModule>;
632
- }
633
-
634
- declare class NgFirebaseTableKxpService {
635
- constructor();
636
- static ɵfac: i0.ɵɵFactoryDeclaration<NgFirebaseTableKxpService, never>;
637
- static ɵprov: i0.ɵɵInjectableDeclaration<NgFirebaseTableKxpService>;
638
- }
639
-
640
- /**
641
- * Obtém o valor aninhado de um objeto dado um caminho (ex: 'user.address.city')
642
- */
643
- declare function getNestedValue(obj: any, path: string): any;
644
- /**
645
- * Formata um array de objetos em uma string com valores separados por vírgula
646
- */
647
- declare function formatArrayValue(array: any[], field: string): string;
648
- /**
649
- * Obtém o valor de exibição para uma célula da tabela
650
- */
651
- declare function getDisplayValue(col: Column, row: any, withinLimit?: boolean): string;
652
- /**
653
- * Verifica se um valor é string
654
- */
655
- declare function isString(value: any): boolean;
656
- /**
657
- * TrackBy function para colunas
658
- */
659
- declare function trackByProperty(_index: number, col: Column): string;
660
- /**
661
- * Gera uma chave única para identificar uma imagem em carregamento
662
- */
663
- declare function getImageKey(row: any, col: Column): string;
664
-
665
- export { FilterService, NgFirebaseTableKxpComponent, NgFirebaseTableKxpModule, NgFirebaseTableKxpService, PaginationService, TABLE_DEFAULTS, TableComponent, TableService, TableTabsComponent, TableTooltipComponent, TooltipService, formatArrayValue, getDisplayValue, getImageKey, getNestedValue, isString, trackByProperty };
666
- export type { Arrange, Column, Condition, DateFiltersByProperty, DropdownItem, FilterConfig, FilterSelectItem, FilterableOption, Image, NavigationResult, Pagination, PaginationState, ProcessedFilter, Tab, TabData, TableData, TooltipConfig, TooltipState };
1
+ /**
2
+ * Generated bundle index. Do not edit.
3
+ */
4
+ /// <amd-module name="ng-firebase-table-kxp" />
5
+ export * from './public-api';