mapa-library-ui 1.7.3 → 2.0.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/README.md +2 -3
- package/fesm2022/mapa-library-ui-src-lib-components-capability.mjs +42 -35
- package/fesm2022/mapa-library-ui-src-lib-components-capability.mjs.map +1 -1
- package/fesm2022/mapa-library-ui-src-lib-components-chart.mjs +42 -35
- package/fesm2022/mapa-library-ui-src-lib-components-chart.mjs.map +1 -1
- package/fesm2022/mapa-library-ui-src-lib-components-datepicker.mjs +648 -125
- package/fesm2022/mapa-library-ui-src-lib-components-datepicker.mjs.map +1 -1
- package/fesm2022/mapa-library-ui-src-lib-components-dropdown-tree.mjs +42 -35
- package/fesm2022/mapa-library-ui-src-lib-components-dropdown-tree.mjs.map +1 -1
- package/fesm2022/mapa-library-ui-src-lib-components-dropdown.mjs +42 -35
- package/fesm2022/mapa-library-ui-src-lib-components-dropdown.mjs.map +1 -1
- package/fesm2022/mapa-library-ui-src-lib-components-filters.mjs +42 -35
- package/fesm2022/mapa-library-ui-src-lib-components-filters.mjs.map +1 -1
- package/fesm2022/mapa-library-ui-src-lib-components-form.mjs +569 -322
- package/fesm2022/mapa-library-ui-src-lib-components-form.mjs.map +1 -1
- package/fesm2022/mapa-library-ui-src-lib-components-input.mjs +42 -35
- package/fesm2022/mapa-library-ui-src-lib-components-input.mjs.map +1 -1
- package/fesm2022/mapa-library-ui-src-lib-components-scale-parameterization.mjs +42 -35
- package/fesm2022/mapa-library-ui-src-lib-components-scale-parameterization.mjs.map +1 -1
- package/fesm2022/mapa-library-ui-src-lib-components-scale.mjs +42 -35
- package/fesm2022/mapa-library-ui-src-lib-components-scale.mjs.map +1 -1
- package/fesm2022/mapa-library-ui-src-lib-components-table.mjs +522 -581
- package/fesm2022/mapa-library-ui-src-lib-components-table.mjs.map +1 -1
- package/fesm2022/mapa-library-ui-src-lib-components-textarea.mjs +42 -35
- package/fesm2022/mapa-library-ui-src-lib-components-textarea.mjs.map +1 -1
- package/fesm2022/mapa-library-ui-src-lib-components-warning.mjs +42 -35
- package/fesm2022/mapa-library-ui-src-lib-components-warning.mjs.map +1 -1
- package/fesm2022/mapa-library-ui-src-lib-core-utils.mjs +1 -4
- package/fesm2022/mapa-library-ui-src-lib-core-utils.mjs.map +1 -1
- package/fesm2022/mapa-library-ui.mjs +1272 -1018
- package/fesm2022/mapa-library-ui.mjs.map +1 -1
- package/index.d.ts +350 -187
- package/mapa-library-ui-2.0.0.tgz +0 -0
- package/package.json +3 -10
- package/src/lib/components/datepicker/index.d.ts +165 -27
- package/src/lib/components/group-report/index.d.ts +6 -1
- package/src/lib/components/menu/index.d.ts +3 -1
- package/src/lib/components/report-item/index.d.ts +3 -1
- package/src/lib/components/table/index.d.ts +153 -100
- package/src/lib/core/utils/index.d.ts +1 -2
- package/fesm2022/mapa-library-ui-src-lib-components-datepicker-range.mjs +0 -733
- package/fesm2022/mapa-library-ui-src-lib-components-datepicker-range.mjs.map +0 -1
- package/mapa-library-ui-1.7.3.tgz +0 -0
- package/src/lib/components/datepicker-range/index.d.ts +0 -207
package/README.md
CHANGED
|
@@ -46,7 +46,7 @@ fixa as versões. Garanta que o app já tenha (ou instale):
|
|
|
46
46
|
|
|
47
47
|
- **Animações** habilitadas: `provideAnimations()` (necessário para Material).
|
|
48
48
|
- Tema do **Angular Material** configurado no app.
|
|
49
|
-
- Para
|
|
49
|
+
- Para o datepicker, instalar os peers `ngxsmk-datepicker` (`^3.0.0`) e `luxon` (`^3.0.0`). O formato de data segue o idioma ativo (`DD/MM/YYYY` em pt-BR/es, `MM/DD/YYYY` em en); não é necessário configurar `MAT_DATE_FORMATS`.
|
|
50
50
|
|
|
51
51
|
---
|
|
52
52
|
|
|
@@ -134,8 +134,7 @@ com `includeSecondaries: true` no Module Federation.
|
|
|
134
134
|
| `/capability` | `<mapa-capability-*>` | Família de componentes de competências (comparativo, indicadores, intervalos, detalhe…) |
|
|
135
135
|
| `/chart` | `<mapa-chart>` | Gráfico genérico (ApexCharts) |
|
|
136
136
|
| `/checkbox` | `<mapa-checkbox>` | Checkbox |
|
|
137
|
-
| `/datepicker` | `<mapa-datepicker>` | Seletor de data |
|
|
138
|
-
| `/datepicker-range` | `<mapa-datepicker-range>` | Seletor de intervalo de datas |
|
|
137
|
+
| `/datepicker` | `<mapa-datepicker>` | Seletor de data nos modos `single`, `range` e `multiple` (via `element.mode`) |
|
|
139
138
|
| `/dialog` | `<mapa-dialog>`, `openDialog()` | Diálogo + helper para abrir via `MatDialog` |
|
|
140
139
|
| `/dropdown` | `<mapa-dropdown>` | Select com busca |
|
|
141
140
|
| `/dropdown-tree` | `<mapa-dropdown-tree>`, `DataNode` | Select em árvore |
|
|
@@ -40,7 +40,7 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "20.3.21", ngImpo
|
|
|
40
40
|
* Public API Surface of mapa-library-ui button
|
|
41
41
|
*/
|
|
42
42
|
|
|
43
|
-
const MAPA_UI_TEXTS = new InjectionToken(
|
|
43
|
+
const MAPA_UI_TEXTS = new InjectionToken('MAPA_UI_TEXTS');
|
|
44
44
|
function formatPaginatorRange(page, pageSize, length) {
|
|
45
45
|
if (length === 0 || pageSize === 0) {
|
|
46
46
|
return `0 de ${length}`;
|
|
@@ -54,66 +54,73 @@ function formatPaginatorRange(page, pageSize, length) {
|
|
|
54
54
|
}
|
|
55
55
|
function formatPaginatorShowingRange(page, pageSize, length) {
|
|
56
56
|
if (length === 0 || pageSize === 0) {
|
|
57
|
-
return
|
|
57
|
+
return 'Mostrando 0 - 0 de 0 item';
|
|
58
58
|
}
|
|
59
59
|
const safeLength = Math.max(length, 0);
|
|
60
60
|
const startIndex = page * pageSize;
|
|
61
61
|
const endIndex = startIndex < safeLength
|
|
62
62
|
? Math.min(startIndex + pageSize, safeLength)
|
|
63
63
|
: startIndex + pageSize;
|
|
64
|
-
const itemLabel = safeLength === 1 ?
|
|
64
|
+
const itemLabel = safeLength === 1 ? 'item' : 'itens';
|
|
65
65
|
return `Mostrando ${startIndex + 1} - ${endIndex} de ${safeLength} ${itemLabel}`;
|
|
66
66
|
}
|
|
67
67
|
const DEFAULT_MAPA_UI_TEXTS = {
|
|
68
68
|
common: {
|
|
69
|
-
selectAll:
|
|
69
|
+
selectAll: 'Selecionar todos',
|
|
70
|
+
retry: 'Tentar novamente',
|
|
70
71
|
},
|
|
71
72
|
filters: {
|
|
72
|
-
clear:
|
|
73
|
-
submit:
|
|
73
|
+
clear: 'Limpar filtros',
|
|
74
|
+
submit: 'Filtrar',
|
|
74
75
|
},
|
|
75
76
|
datepicker: {
|
|
76
|
-
startDatePlaceholder:
|
|
77
|
-
endDatePlaceholder:
|
|
77
|
+
startDatePlaceholder: 'Data inicial',
|
|
78
|
+
endDatePlaceholder: 'Data final',
|
|
78
79
|
},
|
|
79
80
|
capability: {
|
|
80
|
-
groupAverageTitle:
|
|
81
|
-
individualAverageTitle:
|
|
82
|
-
conceptTitle:
|
|
83
|
-
resultTitle:
|
|
84
|
-
positiveIndicatorsTitle:
|
|
85
|
-
negativeIndicatorsTitle:
|
|
86
|
-
riskIndicatorsTitle:
|
|
87
|
-
precipitationRiskTitle:
|
|
88
|
-
negligenceRiskTitle:
|
|
89
|
-
negativeDirectionLabel:
|
|
90
|
-
positiveDirectionLabel:
|
|
81
|
+
groupAverageTitle: 'Média geral do grupo',
|
|
82
|
+
individualAverageTitle: 'Média geral do indivíduo',
|
|
83
|
+
conceptTitle: 'Conceito',
|
|
84
|
+
resultTitle: 'Resultado',
|
|
85
|
+
positiveIndicatorsTitle: 'Indicadores positivos',
|
|
86
|
+
negativeIndicatorsTitle: 'Indicadores negativos',
|
|
87
|
+
riskIndicatorsTitle: 'Indicadores de risco',
|
|
88
|
+
precipitationRiskTitle: 'Risco de acidente por precipitação',
|
|
89
|
+
negligenceRiskTitle: 'Risco de acidente por negligência',
|
|
90
|
+
negativeDirectionLabel: 'Direção Negativa |',
|
|
91
|
+
positiveDirectionLabel: 'Direção Positiva |',
|
|
91
92
|
},
|
|
92
93
|
paginator: {
|
|
93
|
-
itemsPerPage:
|
|
94
|
-
nextPage:
|
|
95
|
-
previousPage:
|
|
94
|
+
itemsPerPage: 'Itens por página',
|
|
95
|
+
nextPage: 'Próxima página',
|
|
96
|
+
previousPage: 'Página anterior',
|
|
96
97
|
rangeLabel: formatPaginatorRange,
|
|
97
98
|
showingRangeLabel: formatPaginatorShowingRange,
|
|
98
99
|
},
|
|
99
100
|
warning: {
|
|
100
|
-
lowReliabilityTitle:
|
|
101
|
-
expirationLimitTitle:
|
|
101
|
+
lowReliabilityTitle: 'Nível baixo de confiabilidade no(s) teste(s):',
|
|
102
|
+
expirationLimitTitle: 'O prazo de validade do(s) teste(s) está no limite:',
|
|
102
103
|
},
|
|
103
104
|
table: {
|
|
104
|
-
emptyTitle:
|
|
105
|
-
emptySubtitle:
|
|
105
|
+
emptyTitle: 'Não foram encontrados resultados',
|
|
106
|
+
emptySubtitle: '',
|
|
107
|
+
loading: 'Carregando resultados',
|
|
108
|
+
errorTitle: 'Não foi possível carregar os resultados.',
|
|
109
|
+
selectAllVisible: 'Selecionar todos os itens desta página',
|
|
110
|
+
selectionColumn: 'Seleção',
|
|
111
|
+
selectRow: 'Selecionar item',
|
|
112
|
+
selectNamedRow: (item) => `Selecionar ${item}`,
|
|
106
113
|
},
|
|
107
114
|
validation: {
|
|
108
|
-
cnpj:
|
|
109
|
-
cpf:
|
|
110
|
-
email:
|
|
111
|
-
max: (context) => `O valor máximo permitido é ${context?.max ??
|
|
112
|
-
maxLength: (context) => `O máximo permitido é ${context?.requiredLength ??
|
|
113
|
-
min: (context) => `O valor mínimo permitido é ${context?.min ??
|
|
114
|
-
minLength: (context) => `O mínimo permitido é ${context?.requiredLength ??
|
|
115
|
-
pattern:
|
|
116
|
-
required:
|
|
115
|
+
cnpj: 'CNPJ inválido',
|
|
116
|
+
cpf: 'CPF inválido',
|
|
117
|
+
email: 'E-mail inválido',
|
|
118
|
+
max: (context) => `O valor máximo permitido é ${context?.max ?? ''}`.trim(),
|
|
119
|
+
maxLength: (context) => `O máximo permitido é ${context?.requiredLength ?? ''} caracteres`.trim(),
|
|
120
|
+
min: (context) => `O valor mínimo permitido é ${context?.min ?? ''}`.trim(),
|
|
121
|
+
minLength: (context) => `O mínimo permitido é ${context?.requiredLength ?? ''} caracteres`.trim(),
|
|
122
|
+
pattern: 'Formato inválido',
|
|
123
|
+
required: 'Campo obrigatório',
|
|
117
124
|
},
|
|
118
125
|
};
|
|
119
126
|
function getDefaultTexts() {
|