@praxisui/charts 9.0.34 → 9.0.35
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.
|
@@ -1,8 +1,8 @@
|
|
|
1
1
|
{
|
|
2
2
|
"schemaVersion": "1.0.0",
|
|
3
|
-
"generatedAt": "2026-08-
|
|
3
|
+
"generatedAt": "2026-08-29T11:06:11.218Z",
|
|
4
4
|
"packageName": "@praxisui/charts",
|
|
5
|
-
"packageVersion": "9.0.
|
|
5
|
+
"packageVersion": "9.0.35",
|
|
6
6
|
"sourceRegistry": "praxis-component-registry-ingestion",
|
|
7
7
|
"sourceRegistryVersion": "1.0.0",
|
|
8
8
|
"componentCount": 3,
|
|
@@ -482,6 +482,8 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.2.14", ngImpo
|
|
|
482
482
|
args: [{ providedIn: 'root' }]
|
|
483
483
|
}] });
|
|
484
484
|
|
|
485
|
+
const PRAXIS_CHARTS_I18N_NAMESPACE = 'charts';
|
|
486
|
+
|
|
485
487
|
class ChartContractNormalizerService {
|
|
486
488
|
normalize(input) {
|
|
487
489
|
let document = structuredClone(input);
|
|
@@ -1564,7 +1566,7 @@ class PraxisChartCanonicalContractMapperService {
|
|
|
1564
1566
|
? 'praxis.charts.runtime.comparisonCurrent'
|
|
1565
1567
|
: 'praxis.charts.runtime.comparisonPrevious';
|
|
1566
1568
|
const fallback = period === 'current' ? 'Current' : 'Previous';
|
|
1567
|
-
return this.i18n?.t(key, undefined, fallback,
|
|
1569
|
+
return this.i18n?.t(key, undefined, fallback, PRAXIS_CHARTS_I18N_NAMESPACE) ?? fallback;
|
|
1568
1570
|
}
|
|
1569
1571
|
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "21.2.14", ngImport: i0, type: PraxisChartCanonicalContractMapperService, deps: [{ token: ChartContractNormalizerService }, { token: ChartContractValidationService }, { token: i1.PraxisI18nService, optional: true }], target: i0.ɵɵFactoryTarget.Injectable });
|
|
1570
1572
|
static ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "21.2.14", ngImport: i0, type: PraxisChartCanonicalContractMapperService, providedIn: 'root' });
|
|
@@ -1675,7 +1677,7 @@ class PraxisChartStatsApiService {
|
|
|
1675
1677
|
}
|
|
1676
1678
|
return value
|
|
1677
1679
|
? axisLabel
|
|
1678
|
-
: this.i18n.t('praxis.charts.runtime.booleanFalseLabel', { label: axisLabel }, `Não ${axisLabel}`,
|
|
1680
|
+
: this.i18n.t('praxis.charts.runtime.booleanFalseLabel', { label: axisLabel }, `Não ${axisLabel}`, PRAXIS_CHARTS_I18N_NAMESPACE);
|
|
1679
1681
|
}
|
|
1680
1682
|
readBooleanBucketValue(bucket) {
|
|
1681
1683
|
if (typeof bucket.key === 'boolean') {
|
|
@@ -2010,33 +2012,18 @@ class PraxisChartComponent {
|
|
|
2010
2012
|
emptyTitle = computed(() => this.i18n.resolve(this.renderConfig().emptyState?.title), ...(ngDevMode ? [{ debugName: "emptyTitle" }] : /* istanbul ignore next */ []));
|
|
2011
2013
|
emptyDescription = computed(() => this.i18n.resolve(this.renderConfig().emptyState?.description), ...(ngDevMode ? [{ debugName: "emptyDescription" }] : /* istanbul ignore next */ []));
|
|
2012
2014
|
errorTitle = computed(() => this.chartDocumentMappingError()
|
|
2013
|
-
? this.
|
|
2014
|
-
key: 'praxis.charts.runtime.invalidDocumentTitle',
|
|
2015
|
-
text: 'Chart configuration is invalid',
|
|
2016
|
-
})
|
|
2015
|
+
? this.t('praxis.charts.runtime.invalidDocumentTitle', 'Chart configuration is invalid')
|
|
2017
2016
|
: this.dataDiagnostic()
|
|
2018
|
-
? this.
|
|
2019
|
-
key: 'praxis.charts.runtime.invalidDataTitle',
|
|
2020
|
-
text: 'Chart data is incompatible with its canonical configuration',
|
|
2021
|
-
})
|
|
2017
|
+
? this.t('praxis.charts.runtime.invalidDataTitle', 'Chart data is incompatible with its canonical configuration')
|
|
2022
2018
|
: this.i18n.resolve(this.renderConfig().state?.error?.title)
|
|
2023
|
-
|| this.
|
|
2024
|
-
key: 'praxis.charts.runtime.remoteErrorTitle',
|
|
2025
|
-
text: 'Não foi possível carregar os dados do gráfico',
|
|
2026
|
-
}), ...(ngDevMode ? [{ debugName: "errorTitle" }] : /* istanbul ignore next */ []));
|
|
2019
|
+
|| this.t('praxis.charts.runtime.remoteErrorTitle', 'Não foi possível carregar os dados do gráfico'), ...(ngDevMode ? [{ debugName: "errorTitle" }] : /* istanbul ignore next */ []));
|
|
2027
2020
|
errorDescription = computed(() => this.chartDocumentMappingError()
|
|
2028
|
-
? this.
|
|
2029
|
-
key: 'praxis.charts.runtime.invalidDocumentDescription',
|
|
2030
|
-
text: 'The canonical chart document could not be mapped to the Praxis chart runtime. Review the chart contract before continuing.',
|
|
2031
|
-
})
|
|
2021
|
+
? this.t('praxis.charts.runtime.invalidDocumentDescription', 'The canonical chart document could not be mapped to the Praxis chart runtime. Review the chart contract before continuing.')
|
|
2032
2022
|
: this.dataDiagnostic()
|
|
2033
2023
|
? this.resolveDataDiagnosticDescription(this.dataDiagnostic())
|
|
2034
2024
|
: this.i18n.resolve(this.renderConfig().state?.error?.description)
|
|
2035
|
-
|| this.
|
|
2036
|
-
|
|
2037
|
-
text: 'Revise a fonte de dados e os filtros antes de continuar.',
|
|
2038
|
-
}), ...(ngDevMode ? [{ debugName: "errorDescription" }] : /* istanbul ignore next */ []));
|
|
2039
|
-
editChartLabel = computed(() => this.i18n.resolve({ key: 'praxis.charts.runtime.editChart', text: 'Edit chart settings' }), ...(ngDevMode ? [{ debugName: "editChartLabel" }] : /* istanbul ignore next */ []));
|
|
2025
|
+
|| this.t('praxis.charts.runtime.remoteErrorDescription', 'Revise a fonte de dados e os filtros antes de continuar.'), ...(ngDevMode ? [{ debugName: "errorDescription" }] : /* istanbul ignore next */ []));
|
|
2026
|
+
editChartLabel = computed(() => this.t('praxis.charts.runtime.editChart', 'Edit chart settings'), ...(ngDevMode ? [{ debugName: "editChartLabel" }] : /* istanbul ignore next */ []));
|
|
2040
2027
|
loadState = computed(() => {
|
|
2041
2028
|
if (this.chartDocumentMappingError()) {
|
|
2042
2029
|
return 'error';
|
|
@@ -2232,7 +2219,11 @@ class PraxisChartComponent {
|
|
|
2232
2219
|
text: 'The gauge value is outside the configured scale. Review the metric and scale instead of clamping the value.',
|
|
2233
2220
|
},
|
|
2234
2221
|
};
|
|
2235
|
-
|
|
2222
|
+
const description = descriptions[diagnostic.code];
|
|
2223
|
+
return this.t(description.key, description.text);
|
|
2224
|
+
}
|
|
2225
|
+
t(key, fallback) {
|
|
2226
|
+
return this.i18n.t(key, undefined, fallback, PRAXIS_CHARTS_I18N_NAMESPACE);
|
|
2236
2227
|
}
|
|
2237
2228
|
canOpenConfigEditor() {
|
|
2238
2229
|
return this.enableCustomization() && !!this.settingsPanel && !!this.runtimeChartDocument();
|
|
@@ -4133,7 +4124,7 @@ class AnalyticsChartConfigAdapterService {
|
|
|
4133
4124
|
? 'praxis.charts.runtime.comparisonCurrent'
|
|
4134
4125
|
: 'praxis.charts.runtime.comparisonPrevious';
|
|
4135
4126
|
const fallback = period === 'current' ? 'Current' : 'Previous';
|
|
4136
|
-
return this.i18n?.t(key, undefined, fallback,
|
|
4127
|
+
return this.i18n?.t(key, undefined, fallback, PRAXIS_CHARTS_I18N_NAMESPACE) ?? fallback;
|
|
4137
4128
|
}
|
|
4138
4129
|
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "21.2.14", ngImport: i0, type: AnalyticsChartConfigAdapterService, deps: [{ token: i1.PraxisI18nService, optional: true }], target: i0.ɵɵFactoryTarget.Injectable });
|
|
4139
4130
|
static ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "21.2.14", ngImport: i0, type: AnalyticsChartConfigAdapterService, providedIn: 'root' });
|
|
@@ -4365,7 +4356,7 @@ class PraxisAnalyticsPresentationComponent {
|
|
|
4365
4356
|
return resolved || null;
|
|
4366
4357
|
}
|
|
4367
4358
|
t(key, fallback) {
|
|
4368
|
-
return this.i18n.t(key, undefined, fallback,
|
|
4359
|
+
return this.i18n.t(key, undefined, fallback, PRAXIS_CHARTS_I18N_NAMESPACE);
|
|
4369
4360
|
}
|
|
4370
4361
|
message(key, fallback, values) {
|
|
4371
4362
|
return Object.entries(values).reduce((message, [name, value]) => message.replaceAll(`{${name}}`, value), this.t(key, fallback));
|
|
@@ -5902,7 +5893,7 @@ function createPraxisChartsI18nConfig(options = {}) {
|
|
|
5902
5893
|
locale: options.locale,
|
|
5903
5894
|
fallbackLocale: options.fallbackLocale ?? 'pt-BR',
|
|
5904
5895
|
namespaces: {
|
|
5905
|
-
|
|
5896
|
+
[PRAXIS_CHARTS_I18N_NAMESPACE]: localeDictionaries,
|
|
5906
5897
|
},
|
|
5907
5898
|
};
|
|
5908
5899
|
}
|
|
@@ -7874,7 +7865,7 @@ class PraxisChartConfigEditor {
|
|
|
7874
7865
|
return `${issue.code}:${issue.field}`;
|
|
7875
7866
|
}
|
|
7876
7867
|
t(key, fallback) {
|
|
7877
|
-
return this.i18n.
|
|
7868
|
+
return this.i18n.t(key, undefined, fallback, PRAXIS_CHARTS_I18N_NAMESPACE);
|
|
7878
7869
|
}
|
|
7879
7870
|
doc() {
|
|
7880
7871
|
return this.currentDocument();
|
|
@@ -8305,7 +8296,7 @@ class PraxisChartWidgetConfigEditor {
|
|
|
8305
8296
|
this.updateValidity();
|
|
8306
8297
|
}
|
|
8307
8298
|
t(key, fallback) {
|
|
8308
|
-
return this.i18n.
|
|
8299
|
+
return this.i18n.t(key, undefined, fallback, PRAXIS_CHARTS_I18N_NAMESPACE);
|
|
8309
8300
|
}
|
|
8310
8301
|
contextDiagnosticText(diagnostic) {
|
|
8311
8302
|
switch (diagnostic.code) {
|
|
@@ -9515,6 +9506,7 @@ function provideChartEngineFactory(options) {
|
|
|
9515
9506
|
}
|
|
9516
9507
|
function providePraxisCharts(options = {}) {
|
|
9517
9508
|
return [
|
|
9509
|
+
...providePraxisChartsI18n(),
|
|
9518
9510
|
provideChartEngineFactory(options),
|
|
9519
9511
|
providePraxisChartsMetadata(),
|
|
9520
9512
|
providePraxisChartDrilldownPanelMetadata(),
|
package/package.json
CHANGED
|
@@ -1,14 +1,14 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@praxisui/charts",
|
|
3
|
-
"version": "9.0.
|
|
3
|
+
"version": "9.0.35",
|
|
4
4
|
"description": "Metadata-driven charts library for Praxis UI Angular with engine adapters and Apache ECharts as the initial renderer.",
|
|
5
5
|
"peerDependencies": {
|
|
6
6
|
"@angular/common": "^21.0.0",
|
|
7
7
|
"@angular/core": "^21.0.0",
|
|
8
|
-
"@praxisui/core": "^9.0.
|
|
8
|
+
"@praxisui/core": "^9.0.35",
|
|
9
9
|
"@angular/forms": "^21.0.0",
|
|
10
10
|
"@angular/material": "^21.0.0",
|
|
11
|
-
"@praxisui/table": "^9.0.
|
|
11
|
+
"@praxisui/table": "^9.0.35",
|
|
12
12
|
"rxjs": "~7.8.0"
|
|
13
13
|
},
|
|
14
14
|
"dependencies": {
|
|
@@ -627,6 +627,7 @@ declare class PraxisChartComponent {
|
|
|
627
627
|
readonly loadState: _angular_core.Signal<PraxisChartLoadState>;
|
|
628
628
|
constructor();
|
|
629
629
|
private resolveDataDiagnosticDescription;
|
|
630
|
+
private t;
|
|
630
631
|
canOpenConfigEditor(): boolean;
|
|
631
632
|
openConfigEditor(): Promise<void>;
|
|
632
633
|
private resolveConfigEditorContext;
|