From 55f17042684a5363d49f64d99c44e8913c801882 Mon Sep 17 00:00:00 2001 From: Matt Seddon Date: Wed, 28 Sep 2022 19:12:25 +1000 Subject: [PATCH] Do not walk unnecessary keys in truncate titles --- extension/src/plots/vega/util.ts | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/extension/src/plots/vega/util.ts b/extension/src/plots/vega/util.ts index 8244d4f687..fd6be2f7ac 100644 --- a/extension/src/plots/vega/util.ts +++ b/extension/src/plots/vega/util.ts @@ -255,6 +255,11 @@ export const truncateTitles = ( const specCopy: Record = {} for (const [key, value] of Object.entries(spec)) { + if (['data', 'color', 'strokeDash', 'shape', 'detail'].includes(key)) { + specCopy[key] = value + continue + } + const valueType = typeof value if (key === 'y') { vertical = true