SUPPORT-8717: + new label formatter for number to local string

This commit is contained in:
Рауф Латыпов 2025-01-09 16:40:49 +03:00
parent 24790fd5e3
commit 8af49bd4ff

View file

@ -0,0 +1,13 @@
import {
ChartLabelModel
} from "../../../../../generated/ervu_business_metrics/model/chart/round/label/ChartLabelModel";
import {NumberToLocalStringFormatter} from "../../../../formatter/NumberToLocalStringFormatter";
import {ChartLabelFormatter} from "./ChartLabelFormatter";
export class LabelNumberToLocalStringFormatter implements ChartLabelFormatter {
private readonly textFormatter = new NumberToLocalStringFormatter();
format(label: ChartLabelModel, labels?: ChartLabelModel[], index?: number): void {
label.text = this.textFormatter.format(label.text);
}
}