@praxisui/table 1.0.0-beta.25 → 1.0.0-beta.26
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/fesm2022/{praxisui-table-filter-form-dialog-host.component-DI8aWSSJ.mjs → praxisui-table-filter-form-dialog-host.component-Du_IEq0W.mjs} +10 -2
- package/fesm2022/praxisui-table-filter-form-dialog-host.component-Du_IEq0W.mjs.map +1 -0
- package/fesm2022/praxisui-table.mjs +112 -15
- package/fesm2022/praxisui-table.mjs.map +1 -1
- package/index.d.ts +17 -1
- package/package.json +6 -6
- package/fesm2022/praxisui-table-filter-form-dialog-host.component-DI8aWSSJ.mjs.map +0 -1
package/index.d.ts
CHANGED
|
@@ -164,6 +164,8 @@ type FilterConfig = {
|
|
|
164
164
|
autoSummary?: boolean;
|
|
165
165
|
confirmTagDelete?: boolean;
|
|
166
166
|
debugLayout?: boolean;
|
|
167
|
+
/** Mostrar o campo "Buscar" (fallback) quando não houver Quick definido */
|
|
168
|
+
showQuickFallback?: boolean;
|
|
167
169
|
tagColor?: 'primary' | 'accent' | 'warn' | 'basic';
|
|
168
170
|
tagVariant?: 'filled' | 'outlined';
|
|
169
171
|
tagButtonColor?: 'primary' | 'accent' | 'warn' | 'basic';
|
|
@@ -244,6 +246,8 @@ declare class PraxisFilter implements OnInit, OnChanges, AfterViewInit, OnDestro
|
|
|
244
246
|
changeDebounceMs: number;
|
|
245
247
|
/** Controla a exibição do botão de configurações dentro do filtro */
|
|
246
248
|
showFilterSettings: boolean;
|
|
249
|
+
/** Mostrar campo de busca genérico quando não houver Quick configurado */
|
|
250
|
+
showQuickFallback?: boolean;
|
|
247
251
|
/** Data used to render the summary card when mode resolves to 'card'. */
|
|
248
252
|
summary?: any;
|
|
249
253
|
/** Custom template to render the summary card; receives the summary as $implicit. */
|
|
@@ -362,6 +366,8 @@ declare class PraxisFilter implements OnInit, OnChanges, AfterViewInit, OnDestro
|
|
|
362
366
|
constructor(crud: GenericCrudService<any>, configStorage: ConfigStorage, destroyRef: DestroyRef, filterConfig: FilterConfigService, settingsPanel: SettingsPanelService, snackBar: MatSnackBar, dialog: MatDialog, cdr: ChangeDetectorRef, dynamicForm: DynamicFormService, schemaNormalizer: SchemaNormalizerService);
|
|
363
367
|
private readonly global;
|
|
364
368
|
private readonly filterDrawerAdapter;
|
|
369
|
+
/** Decide se o bloco Quick deve ser exibido (heurística + preferência) */
|
|
370
|
+
showQuickBar(): boolean;
|
|
365
371
|
private loadSavedTagsFromStorage;
|
|
366
372
|
ngOnInit(): void;
|
|
367
373
|
ngAfterViewInit(): void;
|
|
@@ -409,7 +415,16 @@ declare class PraxisFilter implements OnInit, OnChanges, AfterViewInit, OnDestro
|
|
|
409
415
|
} | undefined;
|
|
410
416
|
private updateAutoSummary;
|
|
411
417
|
private defaultSummaryMap;
|
|
418
|
+
/** Salva o estado atual dos filtros como um atalho (tag) do usuário */
|
|
419
|
+
saveCurrentAsTag(): void;
|
|
412
420
|
private formatValueForBadge;
|
|
421
|
+
/**
|
|
422
|
+
* Resolve a user-friendly label for a filter key using the loaded FieldMetadata.
|
|
423
|
+
* Falls back to the key itself when metadata is not available.
|
|
424
|
+
*/
|
|
425
|
+
private getFieldLabel;
|
|
426
|
+
/** Resolve option display text from FieldMetadata.options, when present */
|
|
427
|
+
private getOptionText;
|
|
413
428
|
getAdvancedAriaLabel(): string;
|
|
414
429
|
private getSchemaMetaKey;
|
|
415
430
|
private getOutdatedIgnoreKey;
|
|
@@ -473,7 +488,7 @@ declare class PraxisFilter implements OnInit, OnChanges, AfterViewInit, OnDestro
|
|
|
473
488
|
private isEditableElement;
|
|
474
489
|
private focusQuick;
|
|
475
490
|
static ɵfac: i0.ɵɵFactoryDeclaration<PraxisFilter, never>;
|
|
476
|
-
static ɵcmp: i0.ɵɵComponentDeclaration<PraxisFilter, "praxis-filter", never, { "resourcePath": { "alias": "resourcePath"; "required": true; }; "formId": { "alias": "formId"; "required": true; }; "mode": { "alias": "mode"; "required": false; }; "notifyIfOutdated": { "alias": "notifyIfOutdated"; "required": false; }; "snoozeMs": { "alias": "snoozeMs"; "required": false; }; "autoOpenSettingsOnOutdated": { "alias": "autoOpenSettingsOnOutdated"; "required": false; }; "editModeEnabled": { "alias": "editModeEnabled"; "required": false; }; "value": { "alias": "value"; "required": false; }; "quickField": { "alias": "quickField"; "required": false; }; "alwaysVisibleFields": { "alias": "alwaysVisibleFields"; "required": false; }; "tags": { "alias": "tags"; "required": false; }; "allowSaveTags": { "alias": "allowSaveTags"; "required": false; }; "persistenceKey": { "alias": "persistenceKey"; "required": false; }; "i18n": { "alias": "i18n"; "required": false; }; "changeDebounceMs": { "alias": "changeDebounceMs"; "required": false; }; "showFilterSettings": { "alias": "showFilterSettings"; "required": false; }; "summary": { "alias": "summary"; "required": false; }; "summaryTemplate": { "alias": "summaryTemplate"; "required": false; }; "summaryMap": { "alias": "summaryMap"; "required": false; }; "autoSummary": { "alias": "autoSummary"; "required": false; }; "confirmTagDelete": { "alias": "confirmTagDelete"; "required": false; }; "debugLayout": { "alias": "debugLayout"; "required": false; }; "placeBooleansInActions": { "alias": "placeBooleansInActions"; "required": false; }; "showToggleLabels": { "alias": "showToggleLabels"; "required": false; }; "alwaysMinWidth": { "alias": "alwaysMinWidth"; "required": false; }; "alwaysColsMd": { "alias": "alwaysColsMd"; "required": false; }; "alwaysColsLg": { "alias": "alwaysColsLg"; "required": false; }; "tagColor": { "alias": "tagColor"; "required": false; }; "tagVariant": { "alias": "tagVariant"; "required": false; }; "tagButtonColor": { "alias": "tagButtonColor"; "required": false; }; "actionsButtonColor": { "alias": "actionsButtonColor"; "required": false; }; "actionsVariant": { "alias": "actionsVariant"; "required": false; }; "overlayVariant": { "alias": "overlayVariant"; "required": false; }; "overlayBackdrop": { "alias": "overlayBackdrop"; "required": false; }; "advancedOpenMode": { "alias": "advancedOpenMode"; "required": false; }; }, { "submit": "submit"; "change": "change"; "clear": "clear"; "modeChange": "modeChange"; "requestSearch": "requestSearch"; "tagsChange": "tagsChange"; "metaChanged": "metaChanged"; "schemaStatusChange": "schemaStatusChange"; }, never, never, true, never>;
|
|
491
|
+
static ɵcmp: i0.ɵɵComponentDeclaration<PraxisFilter, "praxis-filter", never, { "resourcePath": { "alias": "resourcePath"; "required": true; }; "formId": { "alias": "formId"; "required": true; }; "mode": { "alias": "mode"; "required": false; }; "notifyIfOutdated": { "alias": "notifyIfOutdated"; "required": false; }; "snoozeMs": { "alias": "snoozeMs"; "required": false; }; "autoOpenSettingsOnOutdated": { "alias": "autoOpenSettingsOnOutdated"; "required": false; }; "editModeEnabled": { "alias": "editModeEnabled"; "required": false; }; "value": { "alias": "value"; "required": false; }; "quickField": { "alias": "quickField"; "required": false; }; "alwaysVisibleFields": { "alias": "alwaysVisibleFields"; "required": false; }; "tags": { "alias": "tags"; "required": false; }; "allowSaveTags": { "alias": "allowSaveTags"; "required": false; }; "persistenceKey": { "alias": "persistenceKey"; "required": false; }; "i18n": { "alias": "i18n"; "required": false; }; "changeDebounceMs": { "alias": "changeDebounceMs"; "required": false; }; "showFilterSettings": { "alias": "showFilterSettings"; "required": false; }; "showQuickFallback": { "alias": "showQuickFallback"; "required": false; }; "summary": { "alias": "summary"; "required": false; }; "summaryTemplate": { "alias": "summaryTemplate"; "required": false; }; "summaryMap": { "alias": "summaryMap"; "required": false; }; "autoSummary": { "alias": "autoSummary"; "required": false; }; "confirmTagDelete": { "alias": "confirmTagDelete"; "required": false; }; "debugLayout": { "alias": "debugLayout"; "required": false; }; "placeBooleansInActions": { "alias": "placeBooleansInActions"; "required": false; }; "showToggleLabels": { "alias": "showToggleLabels"; "required": false; }; "alwaysMinWidth": { "alias": "alwaysMinWidth"; "required": false; }; "alwaysColsMd": { "alias": "alwaysColsMd"; "required": false; }; "alwaysColsLg": { "alias": "alwaysColsLg"; "required": false; }; "tagColor": { "alias": "tagColor"; "required": false; }; "tagVariant": { "alias": "tagVariant"; "required": false; }; "tagButtonColor": { "alias": "tagButtonColor"; "required": false; }; "actionsButtonColor": { "alias": "actionsButtonColor"; "required": false; }; "actionsVariant": { "alias": "actionsVariant"; "required": false; }; "overlayVariant": { "alias": "overlayVariant"; "required": false; }; "overlayBackdrop": { "alias": "overlayBackdrop"; "required": false; }; "advancedOpenMode": { "alias": "advancedOpenMode"; "required": false; }; }, { "submit": "submit"; "change": "change"; "clear": "clear"; "modeChange": "modeChange"; "requestSearch": "requestSearch"; "tagsChange": "tagsChange"; "metaChanged": "metaChanged"; "schemaStatusChange": "schemaStatusChange"; }, never, never, true, never>;
|
|
477
492
|
}
|
|
478
493
|
|
|
479
494
|
interface ActionLike {
|
|
@@ -1713,6 +1728,7 @@ declare class FilterSettingsComponent implements OnChanges {
|
|
|
1713
1728
|
overlayVariant: FormControl<'card' | 'frosted'>;
|
|
1714
1729
|
overlayBackdrop: FormControl<boolean>;
|
|
1715
1730
|
advancedOpenMode: FormControl<'overlay' | 'modal' | 'drawer'>;
|
|
1731
|
+
showQuickFallback: FormControl<boolean>;
|
|
1716
1732
|
}>;
|
|
1717
1733
|
/**
|
|
1718
1734
|
* Emits true when form has changes and is valid, enabling the save button
|
package/package.json
CHANGED
|
@@ -1,15 +1,15 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@praxisui/table",
|
|
3
|
-
"version": "1.0.0-beta.
|
|
3
|
+
"version": "1.0.0-beta.26",
|
|
4
4
|
"description": "Advanced data table for Angular (Praxis UI) with editing, filtering, sorting, virtualization, and settings panel integration.",
|
|
5
5
|
"peerDependencies": {
|
|
6
6
|
"@angular/common": "^20.0.0",
|
|
7
7
|
"@angular/core": "^20.0.0",
|
|
8
|
-
"@praxisui/core": "^1.0.0-beta.
|
|
9
|
-
"@praxisui/dynamic-fields": "^1.0.0-beta.
|
|
10
|
-
"@praxisui/dynamic-form": "^1.0.0-beta.
|
|
11
|
-
"@praxisui/settings-panel": "^1.0.0-beta.
|
|
12
|
-
"@praxisui/table-rule-builder": "^1.0.0-beta.
|
|
8
|
+
"@praxisui/core": "^1.0.0-beta.26",
|
|
9
|
+
"@praxisui/dynamic-fields": "^1.0.0-beta.26",
|
|
10
|
+
"@praxisui/dynamic-form": "^1.0.0-beta.26",
|
|
11
|
+
"@praxisui/settings-panel": "^1.0.0-beta.26",
|
|
12
|
+
"@praxisui/table-rule-builder": "^1.0.0-beta.26"
|
|
13
13
|
},
|
|
14
14
|
"dependencies": {
|
|
15
15
|
"tslib": "^2.3.0"
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"praxisui-table-filter-form-dialog-host.component-DI8aWSSJ.mjs","sources":["../../../projects/praxis-table/src/lib/components/praxis-filter/filter-form-dialog-host.component.ts"],"sourcesContent":["import { Component, Inject } from '@angular/core';\nimport { CommonModule } from '@angular/common';\nimport { MatDialogModule, MatDialogRef, MAT_DIALOG_DATA } from '@angular/material/dialog';\nimport { MatButtonModule } from '@angular/material/button';\nimport { MatProgressBarModule } from '@angular/material/progress-bar';\nimport { PraxisFilterForm } from '@praxisui/dynamic-form';\n\n@Component({\n selector: 'praxis-filter-form-dialog-host',\n standalone: true,\n imports: [CommonModule, MatDialogModule, MatButtonModule, MatProgressBarModule, PraxisFilterForm],\n template: `\n <h2 mat-dialog-title id=\"filterDialogTitle\">{{ data.title || 'Filtro Avançado' }}</h2>\n <mat-dialog-content class=\"pfx-filter-dialog-content\" aria-labelledby=\"filterDialogTitle\">\n <mat-progress-bar *ngIf=\"data?.schemaLoading\" mode=\"indeterminate\"></mat-progress-bar>\n <praxis-filter-form\n *ngIf=\"data?.config\"\n [formId]=\"data.formId\"\n [resourcePath]=\"data.resourcePath\"\n [mode]=\"'edit'\"\n [config]=\"data.config\"\n (formReady)=\"onReady($event)\"\n (valueChange)=\"onChange($event)\"\n (validityChange)=\"onValidity($event)\"\n ></praxis-filter-form>\n <p *ngIf=\"!data?.config && !data?.schemaLoading\">Nenhum dado</p>\n </mat-dialog-content>\n <mat-dialog-actions align=\"end\">\n <button mat-stroked-button mat-dialog-close>Cancelar</button>\n <button mat-flat-button color=\"primary\" (click)=\"apply()\" [disabled]=\"!valid\">Aplicar</button>\n </mat-dialog-actions>\n `,\n})\nexport class FilterFormDialogHostComponent {\n valid = true;\n private lastValue: any = {};\n constructor(\n @Inject(MAT_DIALOG_DATA)\n public data: {\n formId: string;\n resourcePath: string;\n config: any;\n title?: string;\n schemaLoading?: boolean;\n },\n private ref: MatDialogRef<FilterFormDialogHostComponent>,\n ) {}\n\n onReady(_ev: any): void {}\n onChange(ev: { formData: Record<string, any> }): void {\n this.lastValue = ev?.formData ?? {};\n }\n onValidity(v: boolean): void { this.valid = v; }\n apply(): void { this.ref.close({ formData: this.lastValue }); }\n}\n"],"names":[],"mappings":";;;;;;;;;;;;MAiCa,6BAA6B,CAAA;AAK/B,IAAA,IAAA;AAOC,IAAA,GAAA;IAXV,KAAK,GAAG,IAAI;IACJ,SAAS,GAAQ,EAAE;IAC3B,WAAA,CAES,IAMN,EACO,GAAgD,EAAA;QAPjD,IAAA,CAAA,IAAI,GAAJ,IAAI;QAOH,IAAA,CAAA,GAAG,GAAH,GAAG;;IAGb,OAAO,CAAC,GAAQ,EAAA;AAChB,IAAA,QAAQ,CAAC,EAAqC,EAAA;QAC5C,IAAI,CAAC,SAAS,GAAG,EAAE,EAAE,QAAQ,IAAI,EAAE;;IAErC,UAAU,CAAC,CAAU,EAAA,EAAU,IAAI,CAAC,KAAK,GAAG,CAAC,CAAC;AAC9C,IAAA,KAAK,KAAW,IAAI,CAAC,GAAG,CAAC,KAAK,CAAC,EAAE,QAAQ,EAAE,IAAI,CAAC,SAAS,EAAE,CAAC,CAAC;AApBlD,IAAA,OAAA,IAAA,GAAA,EAAA,CAAA,kBAAA,CAAA,EAAA,UAAA,EAAA,QAAA,EAAA,OAAA,EAAA,QAAA,EAAA,QAAA,EAAA,EAAA,EAAA,IAAA,EAAA,6BAA6B,kBAI9B,eAAe,EAAA,EAAA,EAAA,KAAA,EAAA,EAAA,CAAA,YAAA,EAAA,CAAA,EAAA,MAAA,EAAA,EAA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