@zambon-dev/framework 1.0.1 → 1.1.0

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/i18n/en.json ADDED
@@ -0,0 +1,78 @@
1
+ {
2
+ "Loading": "Loading",
3
+
4
+
5
+ "//": "Buttons",
6
+ "Button-Cancel-Edit": "Cancel",
7
+ "Button-Delete": "Delete",
8
+ "Button-Edit": "Edit",
9
+ "Button-Export": "Export",
10
+ "Button-Export-CSV": "CSV",
11
+ "Button-Export-Excel": "Excel",
12
+ "Button-Export-LimitExceeded": "Export exceeds the {{ max }}-row limit. Narrow your filters and try again.",
13
+ "Button-Export-MHTML": "Web Archive",
14
+ "Button-Export-PDF": "PDF",
15
+ "Button-Export-XML": "XML",
16
+ "Button-Filters": "Filter",
17
+ "Button-Filters-Clear": "Clear filters",
18
+ "Button-Filters-Modal-Confirm": "Confirm filter",
19
+ "Button-Modal-Cancel": "Cancel",
20
+ "Button-Modal-Close": "Close",
21
+ "Button-Modal-MultiEditor-Confirm": "Confirm changes",
22
+ "Button-Modal-MultiSelect-Confirm": "Confirm changes",
23
+ "Button-New": "New",
24
+ "Button-Open-Record": "Open",
25
+ "Button-Refresh": "Refresh",
26
+ "Button-Save": "Save",
27
+ "Button-Save-And-Close": "Save & Close",
28
+ "Button-Save-And-New": "Save & New",
29
+ "Button-Views": "Views",
30
+ "Button-Views-Details": "Details",
31
+ "Button-Views-History": "History",
32
+
33
+
34
+ "//": "Forms",
35
+ "CatalogSelect-Loading": "Loading...",
36
+ "CatalogSelect-FailureMessage": "An error occurred while fetching the results. Please click here to try again.",
37
+ "CatalogSelect-MinimumLengthSearch": "Type at least {{ minimumLengthSearch }} characters.",
38
+ "CatalogSelect-NoResultsFound": "No results found.",
39
+
40
+
41
+ "//": "Grids",
42
+ "Grid-Loading": "Loading...",
43
+ "Grid-Message-Empty": "No records found.",
44
+ "Grid-Message-Failed": "An error occurred while loading the records. Please try again later.",
45
+ "Grid-Message-LazyLoad": "Click the refresh button to load entries.",
46
+
47
+
48
+ "//": "i18n",
49
+ "Format-Currency": "1.2",
50
+ "Format-Date": "MM/dd/yyyy",
51
+ "Format-DateTime": "MM/dd/yyyy hh:mm a",
52
+ "Format-Number": "1.0",
53
+ "Language-en": "English",
54
+ "Language-pt": "Português",
55
+ "locale": "en-US",
56
+ "MonthYear-Format": "MM/yyyy",
57
+
58
+
59
+ "//": "Modals",
60
+ "Modal-Delete-Confirm": "Confirm delete",
61
+ "Modal-Delete-Message": "You are about to delete records, is not possible to reverse this action. Are you sure you want to continue?",
62
+ "Modal-Delete-Title": "Confirm the record deletion",
63
+ "Modal-Failed-Administrator": "If the problem persists, please contact your administrator.",
64
+ "Modal-Failed-DefaultMessage": "An error occurred in the server. Please try again later.",
65
+ "Modal-Failed-Title": "An error occurred",
66
+ "Modal-NotFound-Message": "The requested record was not found.\nIt may have been deleted or the URL may be incorrect.",
67
+ "Modal-NotFound-Title": "Record not found",
68
+
69
+
70
+ "//": "Ribbon And Details",
71
+ "EditSection-Details": "Details",
72
+ "RibbonGroup-Actions": "Actions",
73
+ "RibbonGroup-Entity": "Entity",
74
+ "RibbonGroup-General": "General",
75
+ "RibbonGroup-Page": "Page",
76
+
77
+ "": ""
78
+ }
package/i18n/pt.json ADDED
@@ -0,0 +1,78 @@
1
+ {
2
+ "Loading": "Carregando",
3
+
4
+
5
+ "//": "Buttons",
6
+ "Button-Cancel-Edit": "Cancelar",
7
+ "Button-Delete": "Excluir",
8
+ "Button-Edit": "Editar",
9
+ "Button-Export": "Exportar",
10
+ "Button-Export-CSV": "CSV",
11
+ "Button-Export-Excel": "Excel",
12
+ "Button-Export-LimitExceeded": "A exportação ultrapassa o limite de {{ max }} linhas. Refine os filtros e tente novamente.",
13
+ "Button-Export-MHTML": "Arquivo Web",
14
+ "Button-Export-PDF": "PDF",
15
+ "Button-Export-XML": "XML",
16
+ "Button-Filters": "Filtrar",
17
+ "Button-Filters-Clear": "Limpar filtros",
18
+ "Button-Filters-Modal-Confirm": "Confirmar filtros",
19
+ "Button-Modal-Cancel": "Cancelar",
20
+ "Button-Modal-Close": "Fechar",
21
+ "Button-Modal-MultiEditor-Confirm": "Confirmar alterações",
22
+ "Button-Modal-MultiSelect-Confirm": "Confirmar alterações",
23
+ "Button-New": "Novo",
24
+ "Button-Open-Record": "Abrir",
25
+ "Button-Refresh": "Atualizar",
26
+ "Button-Save": "Salvar",
27
+ "Button-Save-And-Close": "Salvar e Fechar",
28
+ "Button-Save-And-New": "Salvar e Novo",
29
+ "Button-Views": "Visões",
30
+ "Button-Views-Details": "Detalhes",
31
+ "Button-Views-History": "Histórico",
32
+
33
+
34
+ "//": "Forms",
35
+ "CatalogSelect-Loading": "Carregando...",
36
+ "CatalogSelect-FailureMessage": "Ocorreu um erro ao buscar os resultados. Por favor, clique aqui para tentar novamente.",
37
+ "CatalogSelect-MinimumLengthSearch": "Digite ao menos {{ minimumLengthSearch }} caracteres.",
38
+ "CatalogSelect-NoResultsFound": "Nenhum resultado encontrado.",
39
+
40
+
41
+ "//": "Grids",
42
+ "Grid-Loading": "Carregando...",
43
+ "Grid-Message-Empty": "Nenhum registro encontrado.",
44
+ "Grid-Message-Failed": "Ocorreu um erro ao carregar os registros. Por favor, tente novamente mais tarde.",
45
+ "Grid-Message-LazyLoad": "Clique no botão atualizar para carregar os registros.",
46
+
47
+
48
+ "//": "i18n",
49
+ "Format-Currency": "1.2",
50
+ "Format-Date": "dd/MM/yyyy",
51
+ "Format-DateTime": "dd/MM/yyyy HH:mm",
52
+ "Format-Number": "1.0",
53
+ "Language-en": "English",
54
+ "Language-pt": "Português",
55
+ "locale": "pt-BR",
56
+ "MonthYear-Format": "MM/yyyy",
57
+
58
+
59
+ "//": "Modals",
60
+ "Modal-Delete-Confirm": "Confirmar exclusão",
61
+ "Modal-Delete-Message": "Você está prestes a excluir registros do sistema, não é possível reverter esta ação. Tem certeza que deseja continuar?",
62
+ "Modal-Delete-Title": "Confirmação da exclusão do registro",
63
+ "Modal-Failed-Administrator": "Se o problema persistir, por favor, entre em contato com o administrador.",
64
+ "Modal-Failed-DefaultMessage": "Ocorreu um erro no servidor. Por favor, tente novamente mais tarde.",
65
+ "Modal-Failed-Title": "Ocorreu um erro",
66
+ "Modal-NotFound-Message": "O registro solicitado não foi encontrado.\nEle pode ter sido excluído ou a URL pode estar incorreta.",
67
+ "Modal-NotFound-Title": "Registro não encontrado",
68
+
69
+
70
+ "//": "Ribbon And Details",
71
+ "EditSection-Details": "Detalhes",
72
+ "RibbonGroup-Actions": "Ações",
73
+ "RibbonGroup-Entity": "Entidade",
74
+ "RibbonGroup-General": "Geral",
75
+ "RibbonGroup-Page": "Página",
76
+
77
+ "": ""
78
+ }
package/index.d.ts CHANGED
@@ -3,6 +3,7 @@ export * from './lib/configs';
3
3
  export * from './lib/configs-providers';
4
4
  export * from './lib/framework.module';
5
5
  export * from './lib/helpers';
6
+ export * from './lib/i18n';
6
7
  export * from './lib/models';
7
8
  export * from './lib/services';
8
9
  export * from './lib/validators';
@@ -0,0 +1,17 @@
1
+ import { BaseButton } from '../base-button';
2
+ import * as i0 from "@angular/core";
3
+ export type ExportFormat = 'xlsx' | 'pdf' | 'csv' | 'xml' | 'mhtml';
4
+ export declare const MaxExportRows: number;
5
+ export declare class ButtonExportComponent extends BaseButton {
6
+ fileBaseName: string;
7
+ private dataGridDataset;
8
+ private translateService;
9
+ protected get isButtonDisabled(): boolean;
10
+ protected get tooltip(): string;
11
+ private get isExceedingExportLimit();
12
+ constructor();
13
+ protected onButtonClicked(format?: string): void;
14
+ private download;
15
+ static ɵfac: i0.ɵɵFactoryDeclaration<ButtonExportComponent, never>;
16
+ static ɵcmp: i0.ɵɵComponentDeclaration<ButtonExportComponent, "framework-button-export", never, { "fileBaseName": { "alias": "fileBaseName"; "required": false; }; }, {}, never, never, true, never>;
17
+ }
@@ -1,19 +1,20 @@
1
1
  import * as i0 from "@angular/core";
2
2
  import * as i1 from "./button-delete/button-delete.component";
3
3
  import * as i2 from "./button-edit/button-edit.component";
4
- import * as i3 from "./button-filters/button-filters.component";
5
- import * as i4 from "./button-new/button-new.component";
6
- import * as i5 from "./button-open-record/button-open-record.component";
7
- import * as i6 from "./button-refresh/button-refresh.component";
8
- import * as i7 from "./button-save/button-save.component";
9
- import * as i8 from "./button-views/button-views.component";
10
- import * as i9 from "./legacy/button-new/button-new.component";
11
- import * as i10 from "./legacy/button-edit/button-edit.component";
12
- import * as i11 from "./legacy/button-save/button-save.component";
13
- import * as i12 from "./legacy/button-views/button-views.component";
14
- import * as i13 from "./legacy/button-open-record/button-open-record.component";
4
+ import * as i3 from "./button-export/button-export.component";
5
+ import * as i4 from "./button-filters/button-filters.component";
6
+ import * as i5 from "./button-new/button-new.component";
7
+ import * as i6 from "./button-open-record/button-open-record.component";
8
+ import * as i7 from "./button-refresh/button-refresh.component";
9
+ import * as i8 from "./button-save/button-save.component";
10
+ import * as i9 from "./button-views/button-views.component";
11
+ import * as i10 from "./legacy/button-new/button-new.component";
12
+ import * as i11 from "./legacy/button-edit/button-edit.component";
13
+ import * as i12 from "./legacy/button-save/button-save.component";
14
+ import * as i13 from "./legacy/button-views/button-views.component";
15
+ import * as i14 from "./legacy/button-open-record/button-open-record.component";
15
16
  export declare class FrameworkButtonsModule {
16
17
  static ɵfac: i0.ɵɵFactoryDeclaration<FrameworkButtonsModule, never>;
17
- static ɵmod: i0.ɵɵNgModuleDeclaration<FrameworkButtonsModule, never, [typeof i1.ButtonDeleteComponent, typeof i2.ButtonEditComponent, typeof i3.ButtonFiltersComponent, typeof i4.ButtonNewComponent, typeof i5.ButtonOpenRecordComponent, typeof i6.ButtonRefreshComponent, typeof i7.ButtonSaveComponent, typeof i8.ButtonViewsComponent, typeof i9.ButtonNewLegacyComponent, typeof i10.ButtonEditLegacyComponent, typeof i11.ButtonSaveLegacyComponent, typeof i12.ButtonViewsLegacyComponent, typeof i13.ButtonOpenRecordLegacyComponent], [typeof i1.ButtonDeleteComponent, typeof i2.ButtonEditComponent, typeof i3.ButtonFiltersComponent, typeof i4.ButtonNewComponent, typeof i5.ButtonOpenRecordComponent, typeof i6.ButtonRefreshComponent, typeof i7.ButtonSaveComponent, typeof i8.ButtonViewsComponent, typeof i9.ButtonNewLegacyComponent, typeof i10.ButtonEditLegacyComponent, typeof i11.ButtonSaveLegacyComponent, typeof i12.ButtonViewsLegacyComponent, typeof i13.ButtonOpenRecordLegacyComponent]>;
18
+ static ɵmod: i0.ɵɵNgModuleDeclaration<FrameworkButtonsModule, never, [typeof i1.ButtonDeleteComponent, typeof i2.ButtonEditComponent, typeof i3.ButtonExportComponent, typeof i4.ButtonFiltersComponent, typeof i5.ButtonNewComponent, typeof i6.ButtonOpenRecordComponent, typeof i7.ButtonRefreshComponent, typeof i8.ButtonSaveComponent, typeof i9.ButtonViewsComponent, typeof i10.ButtonNewLegacyComponent, typeof i11.ButtonEditLegacyComponent, typeof i12.ButtonSaveLegacyComponent, typeof i13.ButtonViewsLegacyComponent, typeof i14.ButtonOpenRecordLegacyComponent], [typeof i1.ButtonDeleteComponent, typeof i2.ButtonEditComponent, typeof i3.ButtonExportComponent, typeof i4.ButtonFiltersComponent, typeof i5.ButtonNewComponent, typeof i6.ButtonOpenRecordComponent, typeof i7.ButtonRefreshComponent, typeof i8.ButtonSaveComponent, typeof i9.ButtonViewsComponent, typeof i10.ButtonNewLegacyComponent, typeof i11.ButtonEditLegacyComponent, typeof i12.ButtonSaveLegacyComponent, typeof i13.ButtonViewsLegacyComponent, typeof i14.ButtonOpenRecordLegacyComponent]>;
18
19
  static ɵinj: i0.ɵɵInjectorDeclaration<FrameworkButtonsModule>;
19
20
  }
@@ -3,6 +3,7 @@ export { BaseFormViewButton } from './base-form-view-button';
3
3
  export { ButtonConfirmComponent } from './button-confirm/button-confirm.component';
4
4
  export { ButtonDeleteComponent } from './button-delete/button-delete.component';
5
5
  export { ButtonEditComponent } from './button-edit/button-edit.component';
6
+ export { ButtonExportComponent, ExportFormat, MaxExportRows } from './button-export/button-export.component';
6
7
  export { ButtonFiltersComponent } from './button-filters/button-filters.component';
7
8
  export { ButtonNewComponent } from './button-new/button-new.component';
8
9
  export { ButtonOpenRecordComponent } from './button-open-record/button-open-record.component';
@@ -0,0 +1,18 @@
1
+ import { HttpBackend } from '@angular/common/http';
2
+ import { EnvironmentProviders, Provider } from '@angular/core';
3
+ import { MultiTranslateHttpLoader, TranslationResource } from 'ngx-translate-multi-http-loader';
4
+ export interface AngularAssetPattern {
5
+ glob: string;
6
+ input: string;
7
+ output: string;
8
+ }
9
+ export declare const ZAMBON_FRAMEWORK_I18N_ASSET_PATH = "assets/i18n/zambon-dev/framework";
10
+ export declare const ZAMBON_FRAMEWORK_I18N_ASSET: AngularAssetPattern;
11
+ export declare const ZAMBON_FRAMEWORK_I18N_RESOURCES: TranslationResource[];
12
+ export interface ZambonFrameworkTranslateConfig {
13
+ defaultLanguage?: string;
14
+ appResources?: (string | TranslationResource)[];
15
+ }
16
+ export declare function createZambonFrameworkTranslateLoader(httpBackend: HttpBackend, appResources?: (string | TranslationResource)[]): MultiTranslateHttpLoader;
17
+ export declare function provideZambonFrameworkTranslateLoader(appResources?: (string | TranslationResource)[]): Provider;
18
+ export declare function provideZambonFrameworkTranslateService(config?: ZambonFrameworkTranslateConfig): EnvironmentProviders;
@@ -0,0 +1 @@
1
+ export * from './framework-i18n';
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@zambon-dev/framework",
3
- "version": "1.0.1",
3
+ "version": "1.1.0",
4
4
  "description": "Angular framework components and infrastructure for Zambon applications.",
5
5
  "keywords": [
6
6
  "angular",
@@ -26,15 +26,16 @@
26
26
  "@angular/router": "^19.1.0",
27
27
  "@auth0/angular-jwt": "^5.2.0",
28
28
  "@zambon-dev/library": "^1.0.0",
29
- "@ngx-translate/core": "^16.0.4"
29
+ "@ngx-translate/core": "^16.0.4",
30
+ "ngx-translate-multi-http-loader": "^19.0.2"
30
31
  },
31
32
  "publishConfig": {
32
33
  "access": "public"
33
34
  },
34
- "sideEffects": false,
35
- "module": "fesm2022/zambon-dev-framework.mjs",
36
- "typings": "index.d.ts",
37
35
  "exports": {
36
+ "./i18n/*": {
37
+ "default": "./i18n/*"
38
+ },
38
39
  "./package.json": {
39
40
  "default": "./package.json"
40
41
  },
@@ -43,6 +44,9 @@
43
44
  "default": "./fesm2022/zambon-dev-framework.mjs"
44
45
  }
45
46
  },
47
+ "sideEffects": false,
48
+ "module": "fesm2022/zambon-dev-framework.mjs",
49
+ "typings": "index.d.ts",
46
50
  "dependencies": {
47
51
  "tslib": "^2.3.0"
48
52
  }