From 968de10b99965522a9a925756720ea1d4a6ea44e Mon Sep 17 00:00:00 2001 From: James Wilmot Date: Sat, 24 Sep 2022 13:56:18 +1000 Subject: [PATCH] Added default-config util --- addon/utils/default-config.ts | 36 +++++++++++++++++++++++++++++++++++ app/utils/default-config.js | 1 + 2 files changed, 37 insertions(+) create mode 100644 addon/utils/default-config.ts create mode 100644 app/utils/default-config.js diff --git a/addon/utils/default-config.ts b/addon/utils/default-config.ts new file mode 100644 index 0000000..4e00612 --- /dev/null +++ b/addon/utils/default-config.ts @@ -0,0 +1,36 @@ +import * as Vega from 'vega'; + +export const DEFAULT_CONFIG: Vega.Config = { + background: '#fff', + arc: { fill: '#3e5c69' }, + area: { fill: '#3e5c69' }, + line: { stroke: '#3e5c69' }, + path: { stroke: '#3e5c69' }, + rect: { fill: '#3e5c69' }, + shape: { stroke: '#3e5c69' }, + symbol: { fill: '#3e5c69' }, + axis: { + domainWidth: 0.5, + grid: true, + labelPadding: 2, + tickSize: 5, + tickWidth: 0.5, + titleFontWeight: 'normal', + }, + axisBand: { grid: false }, + axisX: { gridWidth: 0.2 }, + axisY: { gridDash: [3], gridWidth: 0.4 }, + legend: { labelFontSize: 11, padding: 1, symbolType: 'square' }, + range: { + category: [ + '#3e5c69', + '#6793a6', + '#182429', + '#0570b0', + '#3690c0', + '#74a9cf', + '#a6bddb', + '#e2ddf2', + ], + }, +}; diff --git a/app/utils/default-config.js b/app/utils/default-config.js new file mode 100644 index 0000000..86b29ba --- /dev/null +++ b/app/utils/default-config.js @@ -0,0 +1 @@ +export { DEFAULT_CONFIG } from '@opendatafit/ember-vega-modifier/utils/default-config';