Skip to content
Snippets Groups Projects
Commit 037b0bcb authored by Tom Robinson's avatar Tom Robinson
Browse files

Fix column title setting for non-number columns. Resolves #8756

parent 1613d85a
No related branches found
No related tags found
No related merge requests found
......@@ -414,17 +414,6 @@ export const NUMBER_COLUMN_SETTINGS = {
"currency_header_only",
],
},
_column_title_full: {
getValue: (column: Column, settings: ColumnSettings) => {
let columnTitle = settings["column_title"] || formatColumn(column);
const headerUnit = settings["_header_unit"];
if (headerUnit) {
columnTitle += ` (${headerUnit})`;
}
return columnTitle;
},
readDependencies: ["column_title", "_header_unit"],
},
};
const COMMON_COLUMN_SETTINGS = {
......@@ -438,6 +427,17 @@ const COMMON_COLUMN_SETTINGS = {
column: {
getValue: column => column,
},
_column_title_full: {
getValue: (column: Column, settings: ColumnSettings) => {
let columnTitle = settings["column_title"] || formatColumn(column);
const headerUnit = settings["_header_unit"];
if (headerUnit) {
columnTitle += ` (${headerUnit})`;
}
return columnTitle;
},
readDependencies: ["column_title", "_header_unit"],
},
};
export function getSettingDefintionsForColumn(series: Series, column: Column) {
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment