diff --git a/src/Area/Area.tsx b/src/Area/Area.tsx index 58a6e9d..e995e47 100644 --- a/src/Area/Area.tsx +++ b/src/Area/Area.tsx @@ -4,6 +4,7 @@ import { Area as G2plotArea, AreaOptions as G2plotAreaProps } from '@antv/g2plot import { useForkRef } from '@consta/uikit/useForkRef' import { useChart } from '@/__private__/hooks/useChart' +import { useChartTheme } from '@/__private__/hooks/useChartTheme' import { getChart } from '@/__private__/utils/getChart' import { ChartProps } from '@/__private__/utils/types/ChartProps' @@ -20,7 +21,8 @@ export const Area: Area = React.forwardRef((props, ref) => { className, ...rest } = props - const { chart, container } = useChart(G2plotArea, rest) + const theme = useChartTheme() + const { chart, container } = useChart(G2plotArea, { ...rest, theme }) useEffect(() => { getChart(chartRef, chart.current) diff --git a/src/Area/__stories__/Column.stories.tsx b/src/Area/__stories__/Column.stories.tsx index 614c36a..66e0a5c 100644 --- a/src/Area/__stories__/Column.stories.tsx +++ b/src/Area/__stories__/Column.stories.tsx @@ -21,6 +21,7 @@ const Default = () => { width: 800, height: '100%', }} + renderer="svg" {...options} /> ) diff --git a/src/Bar/Bar.tsx b/src/Bar/Bar.tsx index 6eb78e6..34d752c 100644 --- a/src/Bar/Bar.tsx +++ b/src/Bar/Bar.tsx @@ -4,6 +4,7 @@ import { Bar as G2plotBar, BarOptions as G2plotBarProps } from '@antv/g2plot' import { useForkRef } from '@consta/uikit/useForkRef' import { useChart } from '@/__private__/hooks/useChart' +import { useChartTheme } from '@/__private__/hooks/useChartTheme' import { getChart } from '@/__private__/utils/getChart' import { ChartProps } from '@/__private__/utils/types/ChartProps' @@ -20,7 +21,8 @@ export const Bar: Bar = React.forwardRef((props, ref) => { className, ...rest } = props - const { chart, container } = useChart(G2plotBar, rest) + const theme = useChartTheme() + const { chart, container } = useChart(G2plotBar, { ...rest, theme }) useEffect(() => { getChart(chartRef, chart.current) diff --git a/src/Bar/__stories__/Bar.stories.tsx b/src/Bar/__stories__/Bar.stories.tsx index 49709f2..c473d98 100644 --- a/src/Bar/__stories__/Bar.stories.tsx +++ b/src/Bar/__stories__/Bar.stories.tsx @@ -21,6 +21,7 @@ const Default = () => { width: 800, height: '100%', }} + renderer="svg" {...options} /> ) diff --git a/src/Bullet/Bullet.tsx b/src/Bullet/Bullet.tsx index 186a5b0..9fb777b 100644 --- a/src/Bullet/Bullet.tsx +++ b/src/Bullet/Bullet.tsx @@ -4,6 +4,7 @@ import { Bullet as G2plotBullet, BulletOptions as G2plotBulletProps } from '@ant import { useForkRef } from '@consta/uikit/useForkRef' import { useChart } from '@/__private__/hooks/useChart' +import { useChartTheme } from '@/__private__/hooks/useChartTheme' import { getChart } from '@/__private__/utils/getChart' import { ChartProps } from '@/__private__/utils/types/ChartProps' @@ -21,7 +22,8 @@ export const Bullet: Bullet = React.forwardRef((props, ref) => { ...rest } = props - const { chart, container } = useChart(G2plotBullet, rest) + const theme = useChartTheme() + const { chart, container } = useChart(G2plotBullet, { ...rest, theme }) useEffect(() => { getChart(chartRef, chart.current) diff --git a/src/Bullet/__stories__/Bullet.stories.tsx b/src/Bullet/__stories__/Bullet.stories.tsx index 3a5bac3..f375704 100644 --- a/src/Bullet/__stories__/Bullet.stories.tsx +++ b/src/Bullet/__stories__/Bullet.stories.tsx @@ -21,6 +21,7 @@ const Default = () => { width: 800, height: '100%', }} + renderer="svg" {...options} /> ) diff --git a/src/Column/Column.tsx b/src/Column/Column.tsx index b4c88f5..34e1d76 100644 --- a/src/Column/Column.tsx +++ b/src/Column/Column.tsx @@ -4,6 +4,7 @@ import { Column as G2plotColumn, ColumnOptions as G2plotColumnProps } from '@ant import { useForkRef } from '@consta/uikit/useForkRef' import { useChart } from '@/__private__/hooks/useChart' +import { useChartTheme } from '@/__private__/hooks/useChartTheme' import { getChart } from '@/__private__/utils/getChart' import { ChartProps } from '@/__private__/utils/types/ChartProps' @@ -20,7 +21,8 @@ export const Column: Column = React.forwardRef((props, ref) => { className, ...rest } = props - const { chart, container } = useChart(G2plotColumn, rest) + const theme = useChartTheme() + const { chart, container } = useChart(G2plotColumn, { ...rest, theme }) useEffect(() => { getChart(chartRef, chart.current) diff --git a/src/Column/__stories__/Column.stories.tsx b/src/Column/__stories__/Column.stories.tsx index e4fdd0c..0c29e91 100644 --- a/src/Column/__stories__/Column.stories.tsx +++ b/src/Column/__stories__/Column.stories.tsx @@ -20,6 +20,7 @@ const Default = () => { width: 800, height: '100%', }} + renderer="svg" {...options} /> ) diff --git a/src/Gauge/Gauge.tsx b/src/Gauge/Gauge.tsx index 12d2bae..dda5892 100644 --- a/src/Gauge/Gauge.tsx +++ b/src/Gauge/Gauge.tsx @@ -4,6 +4,7 @@ import { Gauge as G2plotGauge, GaugeOptions as G2plotGaugeProps } from '@antv/g2 import { useForkRef } from '@consta/uikit/useForkRef' import { useChart } from '@/__private__/hooks/useChart' +import { useChartTheme } from '@/__private__/hooks/useChartTheme' import { getChart } from '@/__private__/utils/getChart' import { ChartProps } from '@/__private__/utils/types/ChartProps' @@ -21,7 +22,8 @@ export const Gauge: Gauge = React.forwardRef((props, ref) => { ...rest } = props - const { chart, container } = useChart(G2plotGauge, rest) + const theme = useChartTheme() + const { chart, container } = useChart(G2plotGauge, { ...rest, theme }) useEffect(() => { getChart(chartRef, chart.current) diff --git a/src/Gauge/__stories__/Gauge.stories.tsx b/src/Gauge/__stories__/Gauge.stories.tsx index 19e606b..24f7133 100644 --- a/src/Gauge/__stories__/Gauge.stories.tsx +++ b/src/Gauge/__stories__/Gauge.stories.tsx @@ -9,8 +9,8 @@ const Default = () => { const options: GaugeProps = { percent: 0.7, range: { - ticks: [0, 1 / 3, 2 / 3, 1], - color: ['#F4664A', '#FAAD14', '#30BF78'], + // ticks: [0, 1 / 3, 2 / 3, 1], + // color: ['#F4664A', '#FAAD14', '#30BF78'], }, indicator: { pointer: { @@ -40,6 +40,7 @@ const Default = () => { width: 300, height: '100%', }} + renderer="svg" {...options} /> ) diff --git a/src/Histogram/Histogram.tsx b/src/Histogram/Histogram.tsx index 2ba70f3..52651b2 100644 --- a/src/Histogram/Histogram.tsx +++ b/src/Histogram/Histogram.tsx @@ -7,6 +7,7 @@ import { import { useForkRef } from '@consta/uikit/useForkRef' import { useChart } from '@/__private__/hooks/useChart' +import { useChartTheme } from '@/__private__/hooks/useChartTheme' import { getChart } from '@/__private__/utils/getChart' import { ChartProps } from '@/__private__/utils/types/ChartProps' @@ -23,7 +24,8 @@ export const Histogram: Histogram = React.forwardRef((props, ref) => { className, ...rest } = props - const { chart, container } = useChart(G2plotHistogram, rest) + const theme = useChartTheme() + const { chart, container } = useChart(G2plotHistogram, { ...rest, theme }) useEffect(() => { getChart(chartRef, chart.current) diff --git a/src/Histogram/__stories__/Histogram.stories.tsx b/src/Histogram/__stories__/Histogram.stories.tsx index 1831857..fae590c 100644 --- a/src/Histogram/__stories__/Histogram.stories.tsx +++ b/src/Histogram/__stories__/Histogram.stories.tsx @@ -18,6 +18,7 @@ const Default = () => { width: 800, height: '100%', }} + renderer="svg" {...options} /> ) diff --git a/src/Line/Line.tsx b/src/Line/Line.tsx index e5f34e8..5eea3e7 100644 --- a/src/Line/Line.tsx +++ b/src/Line/Line.tsx @@ -1,17 +1,19 @@ import React, { useEffect, useImperativeHandle } from 'react' -import { Line as G2plotLine, LineOptions as G2plotLineProps } from '@antv/g2plot' +import { Line as G2plotLine } from '@antv/g2plot' import { useForkRef } from '@consta/uikit/useForkRef' +import { useThemeVars } from '@consta/uikit/useThemeVars' import { useChart } from '@/__private__/hooks/useChart' +import { getChartTheme } from '@/__private__/hooks/useChartTheme' import { getChart } from '@/__private__/utils/getChart' -import { ChartProps } from '@/__private__/utils/types/ChartProps' -export type LineProps = ChartProps +import { withDefaultProps } from './helpers' +import { Line as Component } from './types' -type Line = (props: LineProps) => React.ReactElement | null +export * from './types' -export const Line: Line = React.forwardRef((props, ref) => { +export const Line: Component = React.forwardRef((props, ref) => { const { chartRef, style = { @@ -20,7 +22,11 @@ export const Line: Line = React.forwardRef((props, ref) => { className, ...rest } = props - const { chart, container } = useChart(G2plotLine, rest) + const themeVars = useThemeVars() + const theme = getChartTheme(themeVars) + const chartProps = withDefaultProps(rest) + + const { chart, container } = useChart(G2plotLine, { ...chartProps, theme }) useEffect(() => { getChart(chartRef, chart.current) diff --git a/src/Line/__mocks__/mock.data.ts b/src/Line/__mocks__/mock.data.ts index fa1a603..af54383 100644 --- a/src/Line/__mocks__/mock.data.ts +++ b/src/Line/__mocks__/mock.data.ts @@ -1,74 +1,1456 @@ -export const data = [ - { - Date: '01.2010', - scales: 1998, - }, - { - Date: '02.2010', - scales: 1850, - }, - { - Date: '03.2010', - scales: 1720, - }, - { - Date: '04.2010', - scales: 1818, - }, - { - Date: '05.2010', - scales: 1920, - }, - { - Date: '06.2010', - scales: 1802, - }, - { - Date: '07.2010', - scales: 1945, - }, - { - Date: '08.2010', - scales: 1856, - }, - { - Date: '09.2010', - scales: 2107, - }, - { - Date: '10.2010', - scales: 2140, - }, - { - Date: '11.2010', - scales: 2311, - }, - { - Date: '12.2010', - scales: 1972, - }, - { - Date: '01.2011', - scales: 1760, - }, - { - Date: '02.2011', - scales: 1824, - }, - { - Date: '03.2011', - scales: 1801, - }, - { - Date: '04.2011', - scales: 2001, - }, - { - Date: '05.2011', - scales: 1640, - }, - { - Date: '06.2011', - scales: 1502, - }, +export type Item = { country: string; color: string; year: string; value: null | number } + +export const data: Item[] = [ + { country: 'Austria', color: '#red', year: '1875', value: null }, + { country: 'Canada', color: '#blue', year: '1875', value: null }, + { country: 'France', color: '#green', year: '1875', value: 0.1 }, + { country: 'Germany', color: '#broun', year: '1875', value: null }, + { country: 'Japan', color: '#9932cc', year: '1875', value: null }, + { country: 'Netherlands', color: '#4b93eb', year: '1875', value: null }, + { country: 'New Zealand', color: '#0e688f', year: '1875', value: null }, + { country: 'Spain', color: '#008f00', year: '1875', value: null }, + { country: 'Sweden', color: '#bef574', year: '1875', value: null }, + { country: 'Switzerland', color: '#ffd700', year: '1875', value: null }, + { country: 'United Kingdom', color: '#ffa500', year: '1875', value: null }, + { country: 'United States', color: '#ffbd88', year: '1875', value: null }, + { country: 'Austria', color: '#red', year: '1880', value: null }, + { country: 'Canada', color: '#blue', year: '1880', value: null }, + { country: 'France', color: '#green', year: '1880', value: 0.1 }, + { country: 'Germany', color: '#broun', year: '1880', value: null }, + { country: 'Japan', color: '#9932cc', year: '1880', value: null }, + { country: 'Netherlands', color: '#4b93eb', year: '1880', value: null }, + { country: 'New Zealand', color: '#0e688f', year: '1880', value: null }, + { country: 'Spain', color: '#008f00', year: '1880', value: null }, + { country: 'Sweden', color: '#bef574', year: '1880', value: null }, + { country: 'Switzerland', color: '#ffd700', year: '1880', value: null }, + { country: 'United Kingdom', color: '#ffa500', year: '1880', value: null }, + { country: 'United States', color: '#ffbd88', year: '1880', value: null }, + { country: 'Austria', color: '#red', year: '1885', value: null }, + { country: 'Canada', color: '#blue', year: '1885', value: null }, + { country: 'France', color: '#green', year: '1885', value: 0.1 }, + { country: 'Germany', color: '#broun', year: '1885', value: null }, + { country: 'Japan', color: '#9932cc', year: '1885', value: null }, + { country: 'Netherlands', color: '#4b93eb', year: '1885', value: null }, + { country: 'New Zealand', color: '#0e688f', year: '1885', value: null }, + { country: 'Spain', color: '#008f00', year: '1885', value: null }, + { country: 'Sweden', color: '#bef574', year: '1885', value: null }, + { country: 'Switzerland', color: '#ffd700', year: '1885', value: null }, + { country: 'United Kingdom', color: '#ffa500', year: '1885', value: null }, + { country: 'United States', color: '#ffbd88', year: '1885', value: null }, + { country: 'Austria', color: '#red', year: '1890', value: null }, + { country: 'Canada', color: '#blue', year: '1890', value: null }, + { country: 'France', color: '#green', year: '1890', value: 0.1 }, + { country: 'Germany', color: '#broun', year: '1890', value: null }, + { country: 'Japan', color: '#9932cc', year: '1890', value: null }, + { country: 'Netherlands', color: '#4b93eb', year: '1890', value: null }, + { country: 'New Zealand', color: '#0e688f', year: '1890', value: null }, + { country: 'Spain', color: '#008f00', year: '1890', value: null }, + { country: 'Sweden', color: '#bef574', year: '1890', value: null }, + { country: 'Switzerland', color: '#ffd700', year: '1890', value: null }, + { country: 'United Kingdom', color: '#ffa500', year: '1890', value: null }, + { country: 'United States', color: '#ffbd88', year: '1890', value: null }, + { country: 'Austria', color: '#red', year: '1895', value: null }, + { country: 'Canada', color: '#blue', year: '1895', value: null }, + { country: 'France', color: '#green', year: '1895', value: 0.1 }, + { country: 'Germany', color: '#broun', year: '1895', value: null }, + { country: 'Japan', color: '#9932cc', year: '1895', value: null }, + { country: 'Netherlands', color: '#4b93eb', year: '1895', value: null }, + { country: 'New Zealand', color: '#0e688f', year: '1895', value: null }, + { country: 'Spain', color: '#008f00', year: '1895', value: null }, + { country: 'Sweden', color: '#bef574', year: '1895', value: null }, + { country: 'Switzerland', color: '#ffd700', year: '1895', value: null }, + { country: 'United Kingdom', color: '#ffa500', year: '1895', value: null }, + { country: 'United States', color: '#ffbd88', year: '1895', value: null }, + { country: 'Austria', color: '#red', year: '1900', value: null }, + { country: 'Canada', color: '#blue', year: '1900', value: null }, + { country: 'France', color: '#green', year: '1900', value: 0.2 }, + { country: 'Germany', color: '#broun', year: '1900', value: null }, + { country: 'Japan', color: '#9932cc', year: '1900', value: null }, + { country: 'Netherlands', color: '#4b93eb', year: '1900', value: null }, + { country: 'New Zealand', color: '#0e688f', year: '1900', value: null }, + { country: 'Spain', color: '#008f00', year: '1900', value: null }, + { country: 'Sweden', color: '#bef574', year: '1900', value: null }, + { country: 'Switzerland', color: '#ffd700', year: '1900', value: null }, + { country: 'United Kingdom', color: '#ffa500', year: '1900', value: null }, + { country: 'United States', color: '#ffbd88', year: '1900', value: 0.1 }, + { country: 'Austria', color: '#red', year: '1901', value: null }, + { country: 'Canada', color: '#blue', year: '1901', value: null }, + { country: 'France', color: '#green', year: '1901', value: 0.2 }, + { country: 'Germany', color: '#broun', year: '1901', value: null }, + { country: 'Japan', color: '#9932cc', year: '1901', value: null }, + { country: 'Netherlands', color: '#4b93eb', year: '1901', value: null }, + { country: 'New Zealand', color: '#0e688f', year: '1901', value: null }, + { country: 'Spain', color: '#008f00', year: '1901', value: null }, + { country: 'Sweden', color: '#bef574', year: '1901', value: null }, + { country: 'Switzerland', color: '#ffd700', year: '1901', value: null }, + { country: 'United Kingdom', color: '#ffa500', year: '1901', value: null }, + { country: 'United States', color: '#ffbd88', year: '1901', value: 0.1 }, + { country: 'Austria', color: '#red', year: '1902', value: null }, + { country: 'Canada', color: '#blue', year: '1902', value: null }, + { country: 'France', color: '#green', year: '1902', value: 0.2 }, + { country: 'Germany', color: '#broun', year: '1902', value: null }, + { country: 'Japan', color: '#9932cc', year: '1902', value: null }, + { country: 'Netherlands', color: '#4b93eb', year: '1902', value: null }, + { country: 'New Zealand', color: '#0e688f', year: '1902', value: null }, + { country: 'Spain', color: '#008f00', year: '1902', value: null }, + { country: 'Sweden', color: '#bef574', year: '1902', value: null }, + { country: 'Switzerland', color: '#ffd700', year: '1902', value: null }, + { country: 'United Kingdom', color: '#ffa500', year: '1902', value: null }, + { country: 'United States', color: '#ffbd88', year: '1902', value: 0.1 }, + { country: 'Austria', color: '#red', year: '1903', value: null }, + { country: 'Canada', color: '#blue', year: '1903', value: null }, + { country: 'France', color: '#green', year: '1903', value: 0.2 }, + { country: 'Germany', color: '#broun', year: '1903', value: null }, + { country: 'Japan', color: '#9932cc', year: '1903', value: null }, + { country: 'Netherlands', color: '#4b93eb', year: '1903', value: null }, + { country: 'New Zealand', color: '#0e688f', year: '1903', value: null }, + { country: 'Spain', color: '#008f00', year: '1903', value: null }, + { country: 'Sweden', color: '#bef574', year: '1903', value: null }, + { country: 'Switzerland', color: '#ffd700', year: '1903', value: null }, + { country: 'United Kingdom', color: '#ffa500', year: '1903', value: null }, + { country: 'United States', color: '#ffbd88', year: '1903', value: 0.1 }, + { country: 'Austria', color: '#red', year: '1904', value: null }, + { country: 'Canada', color: '#blue', year: '1904', value: null }, + { country: 'France', color: '#green', year: '1904', value: 0.2 }, + { country: 'Germany', color: '#broun', year: '1904', value: null }, + { country: 'Japan', color: '#9932cc', year: '1904', value: null }, + { country: 'Netherlands', color: '#4b93eb', year: '1904', value: null }, + { country: 'New Zealand', color: '#0e688f', year: '1904', value: null }, + { country: 'Spain', color: '#008f00', year: '1904', value: null }, + { country: 'Sweden', color: '#bef574', year: '1904', value: null }, + { country: 'Switzerland', color: '#ffd700', year: '1904', value: null }, + { country: 'United Kingdom', color: '#ffa500', year: '1904', value: null }, + { country: 'United States', color: '#ffbd88', year: '1904', value: 0.2 }, + { country: 'Austria', color: '#red', year: '1905', value: null }, + { country: 'Canada', color: '#blue', year: '1905', value: null }, + { country: 'France', color: '#green', year: '1905', value: 0.2 }, + { country: 'Germany', color: '#broun', year: '1905', value: null }, + { country: 'Japan', color: '#9932cc', year: '1905', value: null }, + { country: 'Netherlands', color: '#4b93eb', year: '1905', value: null }, + { country: 'New Zealand', color: '#0e688f', year: '1905', value: null }, + { country: 'Spain', color: '#008f00', year: '1905', value: null }, + { country: 'Sweden', color: '#bef574', year: '1905', value: null }, + { country: 'Switzerland', color: '#ffd700', year: '1905', value: null }, + { country: 'United Kingdom', color: '#ffa500', year: '1905', value: 1.1 }, + { country: 'United States', color: '#ffbd88', year: '1905', value: 0.2 }, + { country: 'Austria', color: '#red', year: '1906', value: null }, + { country: 'Canada', color: '#blue', year: '1906', value: null }, + { country: 'France', color: '#green', year: '1906', value: 0.2 }, + { country: 'Germany', color: '#broun', year: '1906', value: 0.2 }, + { country: 'Japan', color: '#9932cc', year: '1906', value: null }, + { country: 'Netherlands', color: '#4b93eb', year: '1906', value: null }, + { country: 'New Zealand', color: '#0e688f', year: '1906', value: null }, + { country: 'Spain', color: '#008f00', year: '1906', value: null }, + { country: 'Sweden', color: '#bef574', year: '1906', value: null }, + { country: 'Switzerland', color: '#ffd700', year: '1906', value: null }, + { country: 'United Kingdom', color: '#ffa500', year: '1906', value: 1.1 }, + { country: 'United States', color: '#ffbd88', year: '1906', value: 0.2 }, + { country: 'Austria', color: '#red', year: '1907', value: null }, + { country: 'Canada', color: '#blue', year: '1907', value: null }, + { country: 'France', color: '#green', year: '1907', value: 0.3 }, + { country: 'Germany', color: '#broun', year: '1907', value: 0.3 }, + { country: 'Japan', color: '#9932cc', year: '1907', value: null }, + { country: 'Netherlands', color: '#4b93eb', year: '1907', value: null }, + { country: 'New Zealand', color: '#0e688f', year: '1907', value: null }, + { country: 'Spain', color: '#008f00', year: '1907', value: null }, + { country: 'Sweden', color: '#bef574', year: '1907', value: null }, + { country: 'Switzerland', color: '#ffd700', year: '1907', value: null }, + { country: 'United Kingdom', color: '#ffa500', year: '1907', value: 1.2 }, + { country: 'United States', color: '#ffbd88', year: '1907', value: 0.2 }, + { country: 'Austria', color: '#red', year: '1908', value: null }, + { country: 'Canada', color: '#blue', year: '1908', value: null }, + { country: 'France', color: '#green', year: '1908', value: 0.3 }, + { country: 'Germany', color: '#broun', year: '1908', value: 0.4 }, + { country: 'Japan', color: '#9932cc', year: '1908', value: null }, + { country: 'Netherlands', color: '#4b93eb', year: '1908', value: null }, + { country: 'New Zealand', color: '#0e688f', year: '1908', value: null }, + { country: 'Spain', color: '#008f00', year: '1908', value: null }, + { country: 'Sweden', color: '#bef574', year: '1908', value: null }, + { country: 'Switzerland', color: '#ffd700', year: '1908', value: null }, + { country: 'United Kingdom', color: '#ffa500', year: '1908', value: 1.3 }, + { country: 'United States', color: '#ffbd88', year: '1908', value: 0.2 }, + { country: 'Austria', color: '#red', year: '1909', value: null }, + { country: 'Canada', color: '#blue', year: '1909', value: null }, + { country: 'France', color: '#green', year: '1909', value: 0.3 }, + { country: 'Germany', color: '#broun', year: '1909', value: 0.4 }, + { country: 'Japan', color: '#9932cc', year: '1909', value: null }, + { country: 'Netherlands', color: '#4b93eb', year: '1909', value: null }, + { country: 'New Zealand', color: '#0e688f', year: '1909', value: null }, + { country: 'Spain', color: '#008f00', year: '1909', value: null }, + { country: 'Sweden', color: '#bef574', year: '1909', value: null }, + { country: 'Switzerland', color: '#ffd700', year: '1909', value: null }, + { country: 'United Kingdom', color: '#ffa500', year: '1909', value: 1.3 }, + { country: 'United States', color: '#ffbd88', year: '1909', value: 0.3 }, + { country: 'Austria', color: '#red', year: '1910', value: null }, + { country: 'Canada', color: '#blue', year: '1910', value: null }, + { country: 'France', color: '#green', year: '1910', value: 0.3 }, + { country: 'Germany', color: '#broun', year: '1910', value: 0.5 }, + { country: 'Japan', color: '#9932cc', year: '1910', value: null }, + { country: 'Netherlands', color: '#4b93eb', year: '1910', value: null }, + { country: 'New Zealand', color: '#0e688f', year: '1910', value: null }, + { country: 'Spain', color: '#008f00', year: '1910', value: null }, + { country: 'Sweden', color: '#bef574', year: '1910', value: null }, + { country: 'Switzerland', color: '#ffd700', year: '1910', value: null }, + { country: 'United Kingdom', color: '#ffa500', year: '1910', value: 1.4 }, + { country: 'United States', color: '#ffbd88', year: '1910', value: 0.4 }, + { country: 'Austria', color: '#red', year: '1911', value: null }, + { country: 'Canada', color: '#blue', year: '1911', value: null }, + { country: 'France', color: '#green', year: '1911', value: null }, + { country: 'Germany', color: '#broun', year: '1911', value: 0.6 }, + { country: 'Japan', color: '#9932cc', year: '1911', value: null }, + { country: 'Netherlands', color: '#4b93eb', year: '1911', value: null }, + { country: 'New Zealand', color: '#0e688f', year: '1911', value: null }, + { country: 'Spain', color: '#008f00', year: '1911', value: null }, + { country: 'Sweden', color: '#bef574', year: '1911', value: null }, + { country: 'Switzerland', color: '#ffd700', year: '1911', value: null }, + { country: 'United Kingdom', color: '#ffa500', year: '1911', value: 1.6 }, + { country: 'United States', color: '#ffbd88', year: '1911', value: 0.4 }, + { country: 'Austria', color: '#red', year: '1912', value: null }, + { country: 'Canada', color: '#blue', year: '1912', value: null }, + { country: 'France', color: '#green', year: '1912', value: null }, + { country: 'Germany', color: '#broun', year: '1912', value: 0.7 }, + { country: 'Japan', color: '#9932cc', year: '1912', value: null }, + { country: 'Netherlands', color: '#4b93eb', year: '1912', value: null }, + { country: 'New Zealand', color: '#0e688f', year: '1912', value: null }, + { country: 'Spain', color: '#008f00', year: '1912', value: null }, + { country: 'Sweden', color: '#bef574', year: '1912', value: null }, + { country: 'Switzerland', color: '#ffd700', year: '1912', value: null }, + { country: 'United Kingdom', color: '#ffa500', year: '1912', value: 1.7 }, + { country: 'United States', color: '#ffbd88', year: '1912', value: 0.5 }, + { country: 'Austria', color: '#red', year: '1913', value: null }, + { country: 'Canada', color: '#blue', year: '1913', value: null }, + { country: 'France', color: '#green', year: '1913', value: 0.4 }, + { country: 'Germany', color: '#broun', year: '1913', value: 0.7 }, + { country: 'Japan', color: '#9932cc', year: '1913', value: null }, + { country: 'Netherlands', color: '#4b93eb', year: '1913', value: null }, + { country: 'New Zealand', color: '#0e688f', year: '1913', value: null }, + { country: 'Spain', color: '#008f00', year: '1913', value: null }, + { country: 'Sweden', color: '#bef574', year: '1913', value: null }, + { country: 'Switzerland', color: '#ffd700', year: '1913', value: null }, + { country: 'United Kingdom', color: '#ffa500', year: '1913', value: 1.8 }, + { country: 'United States', color: '#ffbd88', year: '1913', value: 0.6 }, + { country: 'Austria', color: '#red', year: '1914', value: null }, + { country: 'Canada', color: '#blue', year: '1914', value: null }, + { country: 'France', color: '#green', year: '1914', value: null }, + { country: 'Germany', color: '#broun', year: '1914', value: null }, + { country: 'Japan', color: '#9932cc', year: '1914', value: null }, + { country: 'Netherlands', color: '#4b93eb', year: '1914', value: null }, + { country: 'New Zealand', color: '#0e688f', year: '1914', value: null }, + { country: 'Spain', color: '#008f00', year: '1914', value: null }, + { country: 'Sweden', color: '#bef574', year: '1914', value: null }, + { country: 'Switzerland', color: '#ffd700', year: '1914', value: null }, + { country: 'United Kingdom', color: '#ffa500', year: '1914', value: 1.9 }, + { country: 'United States', color: '#ffbd88', year: '1914', value: 0.6 }, + { country: 'Austria', color: '#red', year: '1915', value: null }, + { country: 'Canada', color: '#blue', year: '1915', value: null }, + { country: 'France', color: '#green', year: '1915', value: null }, + { country: 'Germany', color: '#broun', year: '1915', value: null }, + { country: 'Japan', color: '#9932cc', year: '1915', value: null }, + { country: 'Netherlands', color: '#4b93eb', year: '1915', value: null }, + { country: 'New Zealand', color: '#0e688f', year: '1915', value: null }, + { country: 'Spain', color: '#008f00', year: '1915', value: null }, + { country: 'Sweden', color: '#bef574', year: '1915', value: null }, + { country: 'Switzerland', color: '#ffd700', year: '1915', value: null }, + { country: 'United Kingdom', color: '#ffa500', year: '1915', value: 2.2 }, + { country: 'United States', color: '#ffbd88', year: '1915', value: 0.7 }, + { country: 'Austria', color: '#red', year: '1916', value: null }, + { country: 'Canada', color: '#blue', year: '1916', value: null }, + { country: 'France', color: '#green', year: '1916', value: null }, + { country: 'Germany', color: '#broun', year: '1916', value: null }, + { country: 'Japan', color: '#9932cc', year: '1916', value: null }, + { country: 'Netherlands', color: '#4b93eb', year: '1916', value: null }, + { country: 'New Zealand', color: '#0e688f', year: '1916', value: null }, + { country: 'Spain', color: '#008f00', year: '1916', value: null }, + { country: 'Sweden', color: '#bef574', year: '1916', value: null }, + { country: 'Switzerland', color: '#ffd700', year: '1916', value: null }, + { country: 'United Kingdom', color: '#ffa500', year: '1916', value: 2.1 }, + { country: 'United States', color: '#ffbd88', year: '1916', value: 1 }, + { country: 'Austria', color: '#red', year: '1917', value: null }, + { country: 'Canada', color: '#blue', year: '1917', value: null }, + { country: 'France', color: '#green', year: '1917', value: null }, + { country: 'Germany', color: '#broun', year: '1917', value: null }, + { country: 'Japan', color: '#9932cc', year: '1917', value: null }, + { country: 'Netherlands', color: '#4b93eb', year: '1917', value: null }, + { country: 'New Zealand', color: '#0e688f', year: '1917', value: null }, + { country: 'Spain', color: '#008f00', year: '1917', value: null }, + { country: 'Sweden', color: '#bef574', year: '1917', value: null }, + { country: 'Switzerland', color: '#ffd700', year: '1917', value: null }, + { country: 'United Kingdom', color: '#ffa500', year: '1917', value: 2.2 }, + { country: 'United States', color: '#ffbd88', year: '1917', value: 1.4 }, + { country: 'Austria', color: '#red', year: '1918', value: null }, + { country: 'Canada', color: '#blue', year: '1918', value: null }, + { country: 'France', color: '#green', year: '1918', value: null }, + { country: 'Germany', color: '#broun', year: '1918', value: null }, + { country: 'Japan', color: '#9932cc', year: '1918', value: null }, + { country: 'Netherlands', color: '#4b93eb', year: '1918', value: null }, + { country: 'New Zealand', color: '#0e688f', year: '1918', value: null }, + { country: 'Spain', color: '#008f00', year: '1918', value: null }, + { country: 'Sweden', color: '#bef574', year: '1918', value: null }, + { country: 'Switzerland', color: '#ffd700', year: '1918', value: null }, + { country: 'United Kingdom', color: '#ffa500', year: '1918', value: 2.3 }, + { country: 'United States', color: '#ffbd88', year: '1918', value: 1.7 }, + { country: 'Austria', color: '#red', year: '1919', value: null }, + { country: 'Canada', color: '#blue', year: '1919', value: null }, + { country: 'France', color: '#green', year: '1919', value: null }, + { country: 'Germany', color: '#broun', year: '1919', value: null }, + { country: 'Japan', color: '#9932cc', year: '1919', value: null }, + { country: 'Netherlands', color: '#4b93eb', year: '1919', value: null }, + { country: 'New Zealand', color: '#0e688f', year: '1919', value: null }, + { country: 'Spain', color: '#008f00', year: '1919', value: null }, + { country: 'Sweden', color: '#bef574', year: '1919', value: null }, + { country: 'Switzerland', color: '#ffd700', year: '1919', value: null }, + { country: 'United Kingdom', color: '#ffa500', year: '1919', value: 3.1 }, + { country: 'United States', color: '#ffbd88', year: '1919', value: 1.8 }, + { country: 'Austria', color: '#red', year: '1920', value: null }, + { country: 'Canada', color: '#blue', year: '1920', value: 1 }, + { country: 'France', color: '#green', year: '1920', value: null }, + { country: 'Germany', color: '#broun', year: '1920', value: null }, + { country: 'Japan', color: '#9932cc', year: '1920', value: 1.6 }, + { country: 'Netherlands', color: '#4b93eb', year: '1920', value: null }, + { country: 'New Zealand', color: '#0e688f', year: '1920', value: 1.6 }, + { country: 'Spain', color: '#008f00', year: '1920', value: 1 }, + { country: 'Sweden', color: '#bef574', year: '1920', value: 1 }, + { country: 'Switzerland', color: '#ffd700', year: '1920', value: null }, + { country: 'United Kingdom', color: '#ffa500', year: '1920', value: 3 }, + { country: 'United States', color: '#ffbd88', year: '1920', value: 1.7 }, + { country: 'Austria', color: '#red', year: '1921', value: null }, + { country: 'Canada', color: '#blue', year: '1921', value: 1.1 }, + { country: 'France', color: '#green', year: '1921', value: null }, + { country: 'Germany', color: '#broun', year: '1921', value: null }, + { country: 'Japan', color: '#9932cc', year: '1921', value: 1.7 }, + { country: 'Netherlands', color: '#4b93eb', year: '1921', value: null }, + { country: 'New Zealand', color: '#0e688f', year: '1921', value: 1.2 }, + { country: 'Spain', color: '#008f00', year: '1921', value: 1 }, + { country: 'Sweden', color: '#bef574', year: '1921', value: 0.9 }, + { country: 'Switzerland', color: '#ffd700', year: '1921', value: null }, + { country: 'United Kingdom', color: '#ffa500', year: '1921', value: 2.8 }, + { country: 'United States', color: '#ffbd88', year: '1921', value: 1.9 }, + { country: 'Austria', color: '#red', year: '1922', value: null }, + { country: 'Canada', color: '#blue', year: '1922', value: 0.9 }, + { country: 'France', color: '#green', year: '1922', value: null }, + { country: 'Germany', color: '#broun', year: '1922', value: null }, + { country: 'Japan', color: '#9932cc', year: '1922', value: 1.8 }, + { country: 'Netherlands', color: '#4b93eb', year: '1922', value: null }, + { country: 'New Zealand', color: '#0e688f', year: '1922', value: 1.3 }, + { country: 'Spain', color: '#008f00', year: '1922', value: 1.1 }, + { country: 'Sweden', color: '#bef574', year: '1922', value: 0.7 }, + { country: 'Switzerland', color: '#ffd700', year: '1922', value: null }, + { country: 'United Kingdom', color: '#ffa500', year: '1922', value: 2.7 }, + { country: 'United States', color: '#ffbd88', year: '1922', value: 1.9 }, + { country: 'Austria', color: '#red', year: '1923', value: 2.5 }, + { country: 'Canada', color: '#blue', year: '1923', value: 1 }, + { country: 'France', color: '#green', year: '1923', value: 0.7 }, + { country: 'Germany', color: '#broun', year: '1923', value: null }, + { country: 'Japan', color: '#9932cc', year: '1923', value: 2 }, + { country: 'Netherlands', color: '#4b93eb', year: '1923', value: 1.1 }, + { country: 'New Zealand', color: '#0e688f', year: '1923', value: 1.5 }, + { country: 'Spain', color: '#008f00', year: '1923', value: 1.2 }, + { country: 'Sweden', color: '#bef574', year: '1923', value: 0.7 }, + { country: 'Switzerland', color: '#ffd700', year: '1923', value: null }, + { country: 'United Kingdom', color: '#ffa500', year: '1923', value: 2.7 }, + { country: 'United States', color: '#ffbd88', year: '1923', value: 2.3 }, + { country: 'Austria', color: '#red', year: '1924', value: 2.9 }, + { country: 'Canada', color: '#blue', year: '1924', value: 1.1 }, + { country: 'France', color: '#green', year: '1924', value: 0.9 }, + { country: 'Germany', color: '#broun', year: '1924', value: null }, + { country: 'Japan', color: '#9932cc', year: '1924', value: 2.1 }, + { country: 'Netherlands', color: '#4b93eb', year: '1924', value: 1.4 }, + { country: 'New Zealand', color: '#0e688f', year: '1924', value: 1.6 }, + { country: 'Spain', color: '#008f00', year: '1924', value: 1.1 }, + { country: 'Sweden', color: '#bef574', year: '1924', value: 0.7 }, + { country: 'Switzerland', color: '#ffd700', year: '1924', value: null }, + { country: 'United Kingdom', color: '#ffa500', year: '1924', value: 2.8 }, + { country: 'United States', color: '#ffbd88', year: '1924', value: 2.5 }, + { country: 'Austria', color: '#red', year: '1925', value: 2.9 }, + { country: 'Canada', color: '#blue', year: '1925', value: 1.2 }, + { country: 'France', color: '#green', year: '1925', value: null }, + { country: 'Germany', color: '#broun', year: '1925', value: 1.7 }, + { country: 'Japan', color: '#9932cc', year: '1925', value: 2 }, + { country: 'Netherlands', color: '#4b93eb', year: '1925', value: 1.1 }, + { country: 'New Zealand', color: '#0e688f', year: '1925', value: 1.8 }, + { country: 'Spain', color: '#008f00', year: '1925', value: 1 }, + { country: 'Sweden', color: '#bef574', year: '1925', value: 0.7 }, + { country: 'Switzerland', color: '#ffd700', year: '1925', value: null }, + { country: 'United Kingdom', color: '#ffa500', year: '1925', value: 3 }, + { country: 'United States', color: '#ffbd88', year: '1925', value: 2.7 }, + { country: 'Austria', color: '#red', year: '1926', value: 3.1 }, + { country: 'Canada', color: '#blue', year: '1926', value: 1.4 }, + { country: 'France', color: '#green', year: '1926', value: null }, + { country: 'Germany', color: '#broun', year: '1926', value: 1.6 }, + { country: 'Japan', color: '#9932cc', year: '1926', value: 2 }, + { country: 'Netherlands', color: '#4b93eb', year: '1926', value: 1.3 }, + { country: 'New Zealand', color: '#0e688f', year: '1926', value: 1.8 }, + { country: 'Spain', color: '#008f00', year: '1926', value: 0.9 }, + { country: 'Sweden', color: '#bef574', year: '1926', value: 0.7 }, + { country: 'Switzerland', color: '#ffd700', year: '1926', value: null }, + { country: 'United Kingdom', color: '#ffa500', year: '1926', value: 3 }, + { country: 'United States', color: '#ffbd88', year: '1926', value: 3 }, + { country: 'Austria', color: '#red', year: '1927', value: 3.3 }, + { country: 'Canada', color: '#blue', year: '1927', value: 1.6 }, + { country: 'France', color: '#green', year: '1927', value: null }, + { country: 'Germany', color: '#broun', year: '1927', value: 1.8 }, + { country: 'Japan', color: '#9932cc', year: '1927', value: 2.1 }, + { country: 'Netherlands', color: '#4b93eb', year: '1927', value: 1.4 }, + { country: 'New Zealand', color: '#0e688f', year: '1927', value: 1.8 }, + { country: 'Spain', color: '#008f00', year: '1927', value: 1 }, + { country: 'Sweden', color: '#bef574', year: '1927', value: 0.8 }, + { country: 'Switzerland', color: '#ffd700', year: '1927', value: null }, + { country: 'United Kingdom', color: '#ffa500', year: '1927', value: 3.2 }, + { country: 'United States', color: '#ffbd88', year: '1927', value: 3.8 }, + { country: 'Austria', color: '#red', year: '1928', value: 3.4 }, + { country: 'Canada', color: '#blue', year: '1928', value: 1.8 }, + { country: 'France', color: '#green', year: '1928', value: null }, + { country: 'Germany', color: '#broun', year: '1928', value: 1.8 }, + { country: 'Japan', color: '#9932cc', year: '1928', value: 2.2 }, + { country: 'Netherlands', color: '#4b93eb', year: '1928', value: 1.4 }, + { country: 'New Zealand', color: '#0e688f', year: '1928', value: 1.8 }, + { country: 'Spain', color: '#008f00', year: '1928', value: 1.2 }, + { country: 'Sweden', color: '#bef574', year: '1928', value: 0.9 }, + { country: 'Switzerland', color: '#ffd700', year: '1928', value: null }, + { country: 'United Kingdom', color: '#ffa500', year: '1928', value: 3.5 }, + { country: 'United States', color: '#ffbd88', year: '1928', value: 4 }, + { country: 'Austria', color: '#red', year: '1929', value: 3.5 }, + { country: 'Canada', color: '#blue', year: '1929', value: 2.1 }, + { country: 'France', color: '#green', year: '1929', value: null }, + { country: 'Germany', color: '#broun', year: '1929', value: 1.8 }, + { country: 'Japan', color: '#9932cc', year: '1929', value: 2.2 }, + { country: 'Netherlands', color: '#4b93eb', year: '1929', value: 1.6 }, + { country: 'New Zealand', color: '#0e688f', year: '1929', value: 1.9 }, + { country: 'Spain', color: '#008f00', year: '1929', value: 1.3 }, + { country: 'Sweden', color: '#bef574', year: '1929', value: 1 }, + { country: 'Switzerland', color: '#ffd700', year: '1929', value: null }, + { country: 'United Kingdom', color: '#ffa500', year: '1929', value: 3.7 }, + { country: 'United States', color: '#ffbd88', year: '1929', value: 4.3 }, + { country: 'Austria', color: '#red', year: '1930', value: 3.5 }, + { country: 'Canada', color: '#blue', year: '1930', value: 2 }, + { country: 'France', color: '#green', year: '1930', value: null }, + { country: 'Germany', color: '#broun', year: '1930', value: 1.6 }, + { country: 'Japan', color: '#9932cc', year: '1930', value: 2 }, + { country: 'Netherlands', color: '#4b93eb', year: '1930', value: 1.8 }, + { country: 'New Zealand', color: '#0e688f', year: '1930', value: 1.6 }, + { country: 'Spain', color: '#008f00', year: '1930', value: 1.4 }, + { country: 'Sweden', color: '#bef574', year: '1930', value: 1.1 }, + { country: 'Switzerland', color: '#ffd700', year: '1930', value: null }, + { country: 'United Kingdom', color: '#ffa500', year: '1930', value: 3.9 }, + { country: 'United States', color: '#ffbd88', year: '1930', value: 4.3 }, + { country: 'Austria', color: '#red', year: '1931', value: 3.3 }, + { country: 'Canada', color: '#blue', year: '1931', value: 1.7 }, + { country: 'France', color: '#green', year: '1931', value: null }, + { country: 'Germany', color: '#broun', year: '1931', value: 1.5 }, + { country: 'Japan', color: '#9932cc', year: '1931', value: 2 }, + { country: 'Netherlands', color: '#4b93eb', year: '1931', value: 1.7 }, + { country: 'New Zealand', color: '#0e688f', year: '1931', value: 1.2 }, + { country: 'Spain', color: '#008f00', year: '1931', value: 1.3 }, + { country: 'Sweden', color: '#bef574', year: '1931', value: 1.2 }, + { country: 'Switzerland', color: '#ffd700', year: '1931', value: null }, + { country: 'United Kingdom', color: '#ffa500', year: '1931', value: 3.9 }, + { country: 'United States', color: '#ffbd88', year: '1931', value: 4.3 }, + { country: 'Austria', color: '#red', year: '1932', value: 3.4 }, + { country: 'Canada', color: '#blue', year: '1932', value: 1.4 }, + { country: 'France', color: '#green', year: '1932', value: 1.6 }, + { country: 'Germany', color: '#broun', year: '1932', value: 2.3 }, + { country: 'Japan', color: '#9932cc', year: '1932', value: 2.1 }, + { country: 'Netherlands', color: '#4b93eb', year: '1932', value: 1.8 }, + { country: 'New Zealand', color: '#0e688f', year: '1932', value: 1 }, + { country: 'Spain', color: '#008f00', year: '1932', value: 1.4 }, + { country: 'Sweden', color: '#bef574', year: '1932', value: 1.2 }, + { country: 'Switzerland', color: '#ffd700', year: '1932', value: null }, + { country: 'United Kingdom', color: '#ffa500', year: '1932', value: 4.1 }, + { country: 'United States', color: '#ffbd88', year: '1932', value: 4.4 }, + { country: 'Austria', color: '#red', year: '1933', value: 3 }, + { country: 'Canada', color: '#blue', year: '1933', value: 1.6 }, + { country: 'France', color: '#green', year: '1933', value: 1.6 }, + { country: 'Germany', color: '#broun', year: '1933', value: 2.3 }, + { country: 'Japan', color: '#9932cc', year: '1933', value: 2.2 }, + { country: 'Netherlands', color: '#4b93eb', year: '1933', value: 1.9 }, + { country: 'New Zealand', color: '#0e688f', year: '1933', value: 1 }, + { country: 'Spain', color: '#008f00', year: '1933', value: 1.3 }, + { country: 'Sweden', color: '#bef574', year: '1933', value: 1.1 }, + { country: 'Switzerland', color: '#ffd700', year: '1933', value: null }, + { country: 'United Kingdom', color: '#ffa500', year: '1933', value: 4.2 }, + { country: 'United States', color: '#ffbd88', year: '1933', value: 4.8 }, + { country: 'Austria', color: '#red', year: '1934', value: 2.9 }, + { country: 'Canada', color: '#blue', year: '1934', value: 1.8 }, + { country: 'France', color: '#green', year: '1934', value: 1.5 }, + { country: 'Germany', color: '#broun', year: '1934', value: 2.5 }, + { country: 'Japan', color: '#9932cc', year: '1934', value: 2.3 }, + { country: 'Netherlands', color: '#4b93eb', year: '1934', value: 1.8 }, + { country: 'New Zealand', color: '#0e688f', year: '1934', value: 1.1 }, + { country: 'Spain', color: '#008f00', year: '1934', value: 1.2 }, + { country: 'Sweden', color: '#bef574', year: '1934', value: 1.1 }, + { country: 'Switzerland', color: '#ffd700', year: '1934', value: 1.5 }, + { country: 'United Kingdom', color: '#ffa500', year: '1934', value: 4.4 }, + { country: 'United States', color: '#ffbd88', year: '1934', value: 5.3 }, + { country: 'Austria', color: '#red', year: '1935', value: 2.9 }, + { country: 'Canada', color: '#blue', year: '1935', value: 1.9 }, + { country: 'France', color: '#green', year: '1935', value: 1.4 }, + { country: 'Germany', color: '#broun', year: '1935', value: 2.5 }, + { country: 'Japan', color: '#9932cc', year: '1935', value: 2.4 }, + { country: 'Netherlands', color: '#4b93eb', year: '1935', value: 1.9 }, + { country: 'New Zealand', color: '#0e688f', year: '1935', value: 1.4 }, + { country: 'Spain', color: '#008f00', year: '1935', value: 1.1 }, + { country: 'Sweden', color: '#bef574', year: '1935', value: 1 }, + { country: 'Switzerland', color: '#ffd700', year: '1935', value: 1.5 }, + { country: 'United Kingdom', color: '#ffa500', year: '1935', value: 4.7 }, + { country: 'United States', color: '#ffbd88', year: '1935', value: 5.7 }, + { country: 'Austria', color: '#red', year: '1936', value: 2.9 }, + { country: 'Canada', color: '#blue', year: '1936', value: 2 }, + { country: 'France', color: '#green', year: '1936', value: 1.5 }, + { country: 'Germany', color: '#broun', year: '1936', value: 2.6 }, + { country: 'Japan', color: '#9932cc', year: '1936', value: 2.4 }, + { country: 'Netherlands', color: '#4b93eb', year: '1936', value: 1.8 }, + { country: 'New Zealand', color: '#0e688f', year: '1936', value: 1.7 }, + { country: 'Spain', color: '#008f00', year: '1936', value: null }, + { country: 'Sweden', color: '#bef574', year: '1936', value: 1 }, + { country: 'Switzerland', color: '#ffd700', year: '1936', value: 1.5 }, + { country: 'United Kingdom', color: '#ffa500', year: '1936', value: 4.9 }, + { country: 'United States', color: '#ffbd88', year: '1936', value: 6 }, + { country: 'Austria', color: '#red', year: '1937', value: 2.8 }, + { country: 'Canada', color: '#blue', year: '1937', value: 2.3 }, + { country: 'France', color: '#green', year: '1937', value: 1.6 }, + { country: 'Germany', color: '#broun', year: '1937', value: 2.8 }, + { country: 'Japan', color: '#9932cc', year: '1937', value: 2.5 }, + { country: 'Netherlands', color: '#4b93eb', year: '1937', value: 1.9 }, + { country: 'New Zealand', color: '#0e688f', year: '1937', value: 1.9 }, + { country: 'Spain', color: '#008f00', year: '1937', value: null }, + { country: 'Sweden', color: '#bef574', year: '1937', value: 1 }, + { country: 'Switzerland', color: '#ffd700', year: '1937', value: 1.5 }, + { country: 'United Kingdom', color: '#ffa500', year: '1937', value: 5.2 }, + { country: 'United States', color: '#ffbd88', year: '1937', value: 6 }, + { country: 'Austria', color: '#red', year: '1938', value: 3.2 }, + { country: 'Canada', color: '#blue', year: '1938', value: 2.4 }, + { country: 'France', color: '#green', year: '1938', value: 1.6 }, + { country: 'Germany', color: '#broun', year: '1938', value: 3.2 }, + { country: 'Japan', color: '#9932cc', year: '1938', value: 2.5 }, + { country: 'Netherlands', color: '#4b93eb', year: '1938', value: 2.1 }, + { country: 'New Zealand', color: '#0e688f', year: '1938', value: 2.1 }, + { country: 'Spain', color: '#008f00', year: '1938', value: null }, + { country: 'Sweden', color: '#bef574', year: '1938', value: 1 }, + { country: 'Switzerland', color: '#ffd700', year: '1938', value: 1.9 }, + { country: 'United Kingdom', color: '#ffa500', year: '1938', value: 5.5 }, + { country: 'United States', color: '#ffbd88', year: '1938', value: 6.1 }, + { country: 'Austria', color: '#red', year: '1939', value: 4 }, + { country: 'Canada', color: '#blue', year: '1939', value: 2.4 }, + { country: 'France', color: '#green', year: '1939', value: 1.8 }, + { country: 'Germany', color: '#broun', year: '1939', value: null }, + { country: 'Japan', color: '#9932cc', year: '1939', value: 2.9 }, + { country: 'Netherlands', color: '#4b93eb', year: '1939', value: 2.3 }, + { country: 'New Zealand', color: '#0e688f', year: '1939', value: 2.1 }, + { country: 'Spain', color: '#008f00', year: '1939', value: null }, + { country: 'Sweden', color: '#bef574', year: '1939', value: 1.1 }, + { country: 'Switzerland', color: '#ffd700', year: '1939', value: 1.9 }, + { country: 'United Kingdom', color: '#ffa500', year: '1939', value: 5.7 }, + { country: 'United States', color: '#ffbd88', year: '1939', value: 6.3 }, + { country: 'Austria', color: '#red', year: '1940', value: 5 }, + { country: 'Canada', color: '#blue', year: '1940', value: 2.6 }, + { country: 'France', color: '#green', year: '1940', value: 1.7 }, + { country: 'Germany', color: '#broun', year: '1940', value: null }, + { country: 'Japan', color: '#9932cc', year: '1940', value: 3.1 }, + { country: 'Netherlands', color: '#4b93eb', year: '1940', value: null }, + { country: 'New Zealand', color: '#0e688f', year: '1940', value: 1.9 }, + { country: 'Spain', color: '#008f00', year: '1940', value: 1 }, + { country: 'Sweden', color: '#bef574', year: '1940', value: 1.1 }, + { country: 'Switzerland', color: '#ffd700', year: '1940', value: 1.9 }, + { country: 'United Kingdom', color: '#ffa500', year: '1940', value: 5.6 }, + { country: 'United States', color: '#ffbd88', year: '1940', value: 6.5 }, + { country: 'Austria', color: '#red', year: '1941', value: 5.8 }, + { country: 'Canada', color: '#blue', year: '1941', value: 2.9 }, + { country: 'France', color: '#green', year: '1941', value: 1.4 }, + { country: 'Germany', color: '#broun', year: '1941', value: null }, + { country: 'Japan', color: '#9932cc', year: '1941', value: 3.1 }, + { country: 'Netherlands', color: '#4b93eb', year: '1941', value: null }, + { country: 'New Zealand', color: '#0e688f', year: '1941', value: 2 }, + { country: 'Spain', color: '#008f00', year: '1941', value: 1.1 }, + { country: 'Sweden', color: '#bef574', year: '1941', value: 1.2 }, + { country: 'Switzerland', color: '#ffd700', year: '1941', value: 2.3 }, + { country: 'United Kingdom', color: '#ffa500', year: '1941', value: 6.2 }, + { country: 'United States', color: '#ffbd88', year: '1941', value: 6.8 }, + { country: 'Austria', color: '#red', year: '1942', value: 5.3 }, + { country: 'Canada', color: '#blue', year: '1942', value: 3.3 }, + { country: 'France', color: '#green', year: '1942', value: 1 }, + { country: 'Germany', color: '#broun', year: '1942', value: null }, + { country: 'Japan', color: '#9932cc', year: '1942', value: 3.2 }, + { country: 'Netherlands', color: '#4b93eb', year: '1942', value: null }, + { country: 'New Zealand', color: '#0e688f', year: '1942', value: 2.3 }, + { country: 'Spain', color: '#008f00', year: '1942', value: 1.1 }, + { country: 'Sweden', color: '#bef574', year: '1942', value: 1.2 }, + { country: 'Switzerland', color: '#ffd700', year: '1942', value: 2.2 }, + { country: 'United Kingdom', color: '#ffa500', year: '1942', value: 6.5 }, + { country: 'United States', color: '#ffbd88', year: '1942', value: 7.4 }, + { country: 'Austria', color: '#red', year: '1943', value: 5.3 }, + { country: 'Canada', color: '#blue', year: '1943', value: 3.6 }, + { country: 'France', color: '#green', year: '1943', value: 0.9 }, + { country: 'Germany', color: '#broun', year: '1943', value: null }, + { country: 'Japan', color: '#9932cc', year: '1943', value: 3.2 }, + { country: 'Netherlands', color: '#4b93eb', year: '1943', value: null }, + { country: 'New Zealand', color: '#0e688f', year: '1943', value: 2.3 }, + { country: 'Spain', color: '#008f00', year: '1943', value: 1.3 }, + { country: 'Sweden', color: '#bef574', year: '1943', value: 1.2 }, + { country: 'Switzerland', color: '#ffd700', year: '1943', value: 2.6 }, + { country: 'United Kingdom', color: '#ffa500', year: '1943', value: 6.5 }, + { country: 'United States', color: '#ffbd88', year: '1943', value: 7.8 }, + { country: 'Austria', color: '#red', year: '1944', value: 4.2 }, + { country: 'Canada', color: '#blue', year: '1944', value: 3.7 }, + { country: 'France', color: '#green', year: '1944', value: 0.8 }, + { country: 'Germany', color: '#broun', year: '1944', value: null }, + { country: 'Japan', color: '#9932cc', year: '1944', value: 2.7 }, + { country: 'Netherlands', color: '#4b93eb', year: '1944', value: null }, + { country: 'New Zealand', color: '#0e688f', year: '1944', value: 2.5 }, + { country: 'Spain', color: '#008f00', year: '1944', value: 1.3 }, + { country: 'Sweden', color: '#bef574', year: '1944', value: 1.2 }, + { country: 'Switzerland', color: '#ffd700', year: '1944', value: 2.8 }, + { country: 'United Kingdom', color: '#ffa500', year: '1944', value: 6.5 }, + { country: 'United States', color: '#ffbd88', year: '1944', value: 7 }, + { country: 'Austria', color: '#red', year: '1945', value: 1.6 }, + { country: 'Canada', color: '#blue', year: '1945', value: 4.5 }, + { country: 'France', color: '#green', year: '1945', value: 1.2 }, + { country: 'Germany', color: '#broun', year: '1945', value: null }, + { country: 'Japan', color: '#9932cc', year: '1945', value: 0.9 }, + { country: 'Netherlands', color: '#4b93eb', year: '1945', value: null }, + { country: 'New Zealand', color: '#0e688f', year: '1945', value: 2.6 }, + { country: 'Spain', color: '#008f00', year: '1945', value: 1.3 }, + { country: 'Sweden', color: '#bef574', year: '1945', value: 1.3 }, + { country: 'Switzerland', color: '#ffd700', year: '1945', value: 3.2 }, + { country: 'United Kingdom', color: '#ffa500', year: '1945', value: 7.2 }, + { country: 'United States', color: '#ffbd88', year: '1945', value: 8.1 }, + { country: 'Austria', color: '#red', year: '1946', value: 1.1 }, + { country: 'Canada', color: '#blue', year: '1946', value: 4.7 }, + { country: 'France', color: '#green', year: '1946', value: 1.6 }, + { country: 'Germany', color: '#broun', year: '1946', value: null }, + { country: 'Japan', color: '#9932cc', year: '1946', value: 0.9 }, + { country: 'Netherlands', color: '#4b93eb', year: '1946', value: 1.4 }, + { country: 'New Zealand', color: '#0e688f', year: '1946', value: 3.4 }, + { country: 'Spain', color: '#008f00', year: '1946', value: 1.4 }, + { country: 'Sweden', color: '#bef574', year: '1946', value: 1.6 }, + { country: 'Switzerland', color: '#ffd700', year: '1946', value: 3.5 }, + { country: 'United Kingdom', color: '#ffa500', year: '1946', value: 7.6 }, + { country: 'United States', color: '#ffbd88', year: '1946', value: 8.9 }, + { country: 'Austria', color: '#red', year: '1947', value: 1.6 }, + { country: 'Canada', color: '#blue', year: '1947', value: 4.7 }, + { country: 'France', color: '#green', year: '1947', value: 2.1 }, + { country: 'Germany', color: '#broun', year: '1947', value: null }, + { country: 'Japan', color: '#9932cc', year: '1947', value: 1 }, + { country: 'Netherlands', color: '#4b93eb', year: '1947', value: 2.2 }, + { country: 'New Zealand', color: '#0e688f', year: '1947', value: 4.3 }, + { country: 'Spain', color: '#008f00', year: '1947', value: 1.5 }, + { country: 'Sweden', color: '#bef574', year: '1947', value: 1.9 }, + { country: 'Switzerland', color: '#ffd700', year: '1947', value: 4 }, + { country: 'United Kingdom', color: '#ffa500', year: '1947', value: 6.7 }, + { country: 'United States', color: '#ffbd88', year: '1947', value: 9.1 }, + { country: 'Austria', color: '#red', year: '1948', value: 2 }, + { country: 'Canada', color: '#blue', year: '1948', value: 4.8 }, + { country: 'France', color: '#green', year: '1948', value: 2.3 }, + { country: 'Germany', color: '#broun', year: '1948', value: null }, + { country: 'Japan', color: '#9932cc', year: '1948', value: 1.9 }, + { country: 'Netherlands', color: '#4b93eb', year: '1948', value: 2.1 }, + { country: 'New Zealand', color: '#0e688f', year: '1948', value: 3.4 }, + { country: 'Spain', color: '#008f00', year: '1948', value: 1.3 }, + { country: 'Sweden', color: '#bef574', year: '1948', value: 2 }, + { country: 'Switzerland', color: '#ffd700', year: '1948', value: 3.9 }, + { country: 'United Kingdom', color: '#ffa500', year: '1948', value: 6.5 }, + { country: 'United States', color: '#ffbd88', year: '1948', value: 9.3 }, + { country: 'Austria', color: '#red', year: '1949', value: 2.5 }, + { country: 'Canada', color: '#blue', year: '1949', value: 4.9 }, + { country: 'France', color: '#green', year: '1949', value: 2.4 }, + { country: 'Germany', color: '#broun', year: '1949', value: null }, + { country: 'Japan', color: '#9932cc', year: '1949', value: 2.8 }, + { country: 'Netherlands', color: '#4b93eb', year: '1949', value: 2.4 }, + { country: 'New Zealand', color: '#0e688f', year: '1949', value: 3.4 }, + { country: 'Spain', color: '#008f00', year: '1949', value: 1.4 }, + { country: 'Sweden', color: '#bef574', year: '1949', value: 2 }, + { country: 'Switzerland', color: '#ffd700', year: '1949', value: 4 }, + { country: 'United Kingdom', color: '#ffa500', year: '1949', value: 6.4 }, + { country: 'United States', color: '#ffbd88', year: '1949', value: 9.3 }, + { country: 'Austria', color: '#red', year: '1950', value: 3 }, + { country: 'Canada', color: '#blue', year: '1950', value: 4.9 }, + { country: 'France', color: '#green', year: '1950', value: 4.4 }, + { country: 'Germany', color: '#broun', year: '1950', value: 2.7 }, + { country: 'Japan', color: '#9932cc', year: '1950', value: 3.3 }, + { country: 'Netherlands', color: '#4b93eb', year: '1950', value: 3.1 }, + { country: 'New Zealand', color: '#0e688f', year: '1950', value: 7.6 }, + { country: 'Spain', color: '#008f00', year: '1950', value: 1.2 }, + { country: 'Sweden', color: '#bef574', year: '1950', value: 2.5 }, + { country: 'Switzerland', color: '#ffd700', year: '1950', value: 4.1 }, + { country: 'United Kingdom', color: '#ffa500', year: '1950', value: 6.5 }, + { country: 'United States', color: '#ffbd88', year: '1950', value: 9.3 }, + { country: 'Austria', color: '#red', year: '1951', value: 3.5 }, + { country: 'Canada', color: '#blue', year: '1951', value: 4.4 }, + { country: 'France', color: '#green', year: '1951', value: 4.4 }, + { country: 'Germany', color: '#broun', year: '1951', value: 3.1 }, + { country: 'Japan', color: '#9932cc', year: '1951', value: 3.7 }, + { country: 'Netherlands', color: '#4b93eb', year: '1951', value: 3.2 }, + { country: 'New Zealand', color: '#0e688f', year: '1951', value: 8 }, + { country: 'Spain', color: '#008f00', year: '1951', value: 1.3 }, + { country: 'Sweden', color: '#bef574', year: '1951', value: 2.5 }, + { country: 'Switzerland', color: '#ffd700', year: '1951', value: 4.3 }, + { country: 'United Kingdom', color: '#ffa500', year: '1951', value: 6.8 }, + { country: 'United States', color: '#ffbd88', year: '1951', value: 9.8 }, + { country: 'Austria', color: '#red', year: '1952', value: 3.7 }, + { country: 'Canada', color: '#blue', year: '1952', value: 4.9 }, + { country: 'France', color: '#green', year: '1952', value: 4.5 }, + { country: 'Germany', color: '#broun', year: '1952', value: 3.1 }, + { country: 'Japan', color: '#9932cc', year: '1952', value: 3.9 }, + { country: 'Netherlands', color: '#4b93eb', year: '1952', value: 3.6 }, + { country: 'New Zealand', color: '#0e688f', year: '1952', value: 7.7 }, + { country: 'Spain', color: '#008f00', year: '1952', value: 1.5 }, + { country: 'Sweden', color: '#bef574', year: '1952', value: 2.9 }, + { country: 'Switzerland', color: '#ffd700', year: '1952', value: 4.7 }, + { country: 'United Kingdom', color: '#ffa500', year: '1952', value: 7 }, + { country: 'United States', color: '#ffbd88', year: '1952', value: 10 }, + { country: 'Austria', color: '#red', year: '1953', value: 3.8 }, + { country: 'Canada', color: '#blue', year: '1953', value: 5.7 }, + { country: 'France', color: '#green', year: '1953', value: 4.4 }, + { country: 'Germany', color: '#broun', year: '1953', value: 3.3 }, + { country: 'Japan', color: '#9932cc', year: '1953', value: 4.3 }, + { country: 'Netherlands', color: '#4b93eb', year: '1953', value: 3.8 }, + { country: 'New Zealand', color: '#0e688f', year: '1953', value: 7.7 }, + { country: 'Spain', color: '#008f00', year: '1953', value: 1.7 }, + { country: 'Sweden', color: '#bef574', year: '1953', value: 2.9 }, + { country: 'Switzerland', color: '#ffd700', year: '1953', value: 4.6 }, + { country: 'United Kingdom', color: '#ffa500', year: '1953', value: 7 }, + { country: 'United States', color: '#ffbd88', year: '1953', value: 9.7 }, + { country: 'Austria', color: '#red', year: '1954', value: 3.3 }, + { country: 'Canada', color: '#blue', year: '1954', value: 5.8 }, + { country: 'France', color: '#green', year: '1954', value: 4.5 }, + { country: 'Germany', color: '#broun', year: '1954', value: 3.5 }, + { country: 'Japan', color: '#9932cc', year: '1954', value: 4.5 }, + { country: 'Netherlands', color: '#4b93eb', year: '1954', value: 4.2 }, + { country: 'New Zealand', color: '#0e688f', year: '1954', value: 8 }, + { country: 'Spain', color: '#008f00', year: '1954', value: 1.8 }, + { country: 'Sweden', color: '#bef574', year: '1954', value: 2.9 }, + { country: 'Switzerland', color: '#ffd700', year: '1954', value: 4.6 }, + { country: 'United Kingdom', color: '#ffa500', year: '1954', value: 7.3 }, + { country: 'United States', color: '#ffbd88', year: '1954', value: 9.2 }, + { country: 'Austria', color: '#red', year: '1955', value: 3.7 }, + { country: 'Canada', color: '#blue', year: '1955', value: 8.6 }, + { country: 'France', color: '#green', year: '1955', value: 4.6 }, + { country: 'Germany', color: '#broun', year: '1955', value: 3.8 }, + { country: 'Japan', color: '#9932cc', year: '1955', value: 4.5 }, + { country: 'Netherlands', color: '#4b93eb', year: '1955', value: 4.3 }, + { country: 'New Zealand', color: '#0e688f', year: '1955', value: 8.2 }, + { country: 'Spain', color: '#008f00', year: '1955', value: 2 }, + { country: 'Sweden', color: '#bef574', year: '1955', value: 3 }, + { country: 'Switzerland', color: '#ffd700', year: '1955', value: 4.8 }, + { country: 'United Kingdom', color: '#ffa500', year: '1955', value: 7.5 }, + { country: 'United States', color: '#ffbd88', year: '1955', value: 9.4 }, + { country: 'Austria', color: '#red', year: '1956', value: 4.1 }, + { country: 'Canada', color: '#blue', year: '1956', value: 8.8 }, + { country: 'France', color: '#green', year: '1956', value: 4.8 }, + { country: 'Germany', color: '#broun', year: '1956', value: 4 }, + { country: 'Japan', color: '#9932cc', year: '1956', value: 4.4 }, + { country: 'Netherlands', color: '#4b93eb', year: '1956', value: 4.7 }, + { country: 'New Zealand', color: '#0e688f', year: '1956', value: 7.7 }, + { country: 'Spain', color: '#008f00', year: '1956', value: 1.9 }, + { country: 'Sweden', color: '#bef574', year: '1956', value: 3.1 }, + { country: 'Switzerland', color: '#ffd700', year: '1956', value: 5.1 }, + { country: 'United Kingdom', color: '#ffa500', year: '1956', value: 7.5 }, + { country: 'United States', color: '#ffbd88', year: '1956', value: 9.4 }, + { country: 'Austria', color: '#red', year: '1957', value: 4.3 }, + { country: 'Canada', color: '#blue', year: '1957', value: 9.3 }, + { country: 'France', color: '#green', year: '1957', value: 5.1 }, + { country: 'Germany', color: '#broun', year: '1957', value: 4.4 }, + { country: 'Japan', color: '#9932cc', year: '1957', value: 4.5 }, + { country: 'Netherlands', color: '#4b93eb', year: '1957', value: 4.8 }, + { country: 'New Zealand', color: '#0e688f', year: '1957', value: 8.1 }, + { country: 'Spain', color: '#008f00', year: '1957', value: 3.8 }, + { country: 'Sweden', color: '#bef574', year: '1957', value: 3.2 }, + { country: 'Switzerland', color: '#ffd700', year: '1957', value: 5.3 }, + { country: 'United Kingdom', color: '#ffa500', year: '1957', value: 7.7 }, + { country: 'United States', color: '#ffbd88', year: '1957', value: 9.7 }, + { country: 'Austria', color: '#red', year: '1958', value: 4.6 }, + { country: 'Canada', color: '#blue', year: '1958', value: 9.7 }, + { country: 'France', color: '#green', year: '1958', value: 5.2 }, + { country: 'Germany', color: '#broun', year: '1958', value: 4.4 }, + { country: 'Japan', color: '#9932cc', year: '1958', value: 4.6 }, + { country: 'Netherlands', color: '#4b93eb', year: '1958', value: 4.6 }, + { country: 'New Zealand', color: '#0e688f', year: '1958', value: 7.5 }, + { country: 'Spain', color: '#008f00', year: '1958', value: 4.3 }, + { country: 'Sweden', color: '#bef574', year: '1958', value: 3.2 }, + { country: 'Switzerland', color: '#ffd700', year: '1958', value: 5.8 }, + { country: 'United Kingdom', color: '#ffa500', year: '1958', value: 7.8 }, + { country: 'United States', color: '#ffbd88', year: '1958', value: 10.2 }, + { country: 'Austria', color: '#red', year: '1959', value: 4.7 }, + { country: 'Canada', color: '#blue', year: '1959', value: 9.9 }, + { country: 'France', color: '#green', year: '1959', value: 4.9 }, + { country: 'Germany', color: '#broun', year: '1959', value: 4.7 }, + { country: 'Japan', color: '#9932cc', year: '1959', value: 4.8 }, + { country: 'Netherlands', color: '#4b93eb', year: '1959', value: 4.6 }, + { country: 'New Zealand', color: '#0e688f', year: '1959', value: 7.3 }, + { country: 'Spain', color: '#008f00', year: '1959', value: 4.2 }, + { country: 'Sweden', color: '#bef574', year: '1959', value: 3.3 }, + { country: 'Switzerland', color: '#ffd700', year: '1959', value: 5.9 }, + { country: 'United Kingdom', color: '#ffa500', year: '1959', value: 8 }, + { country: 'United States', color: '#ffbd88', year: '1959', value: 10.5 }, + { country: 'Austria', color: '#red', year: '1960', value: 4.8 }, + { country: 'Canada', color: '#blue', year: '1960', value: 9.8 }, + { country: 'France', color: '#green', year: '1960', value: 5 }, + { country: 'Germany', color: '#broun', year: '1960', value: 5.1 }, + { country: 'Japan', color: '#9932cc', year: '1960', value: 5.1 }, + { country: 'Netherlands', color: '#4b93eb', year: '1960', value: 7.3 }, + { country: 'New Zealand', color: '#0e688f', year: '1960', value: 8.2 }, + { country: 'Spain', color: '#008f00', year: '1960', value: 4.2 }, + { country: 'Sweden', color: '#bef574', year: '1960', value: 3.5 }, + { country: 'Switzerland', color: '#ffd700', year: '1960', value: 6.6 }, + { country: 'United Kingdom', color: '#ffa500', year: '1960', value: 8.3 }, + { country: 'United States', color: '#ffbd88', year: '1960', value: 10.7 }, + { country: 'Austria', color: '#red', year: '1961', value: 4.7 }, + { country: 'Canada', color: '#blue', year: '1961', value: 10.2 }, + { country: 'France', color: '#green', year: '1961', value: 5 }, + { country: 'Germany', color: '#broun', year: '1961', value: 5.4 }, + { country: 'Japan', color: '#9932cc', year: '1961', value: 5.6 }, + { country: 'Netherlands', color: '#4b93eb', year: '1961', value: 7.5 }, + { country: 'New Zealand', color: '#0e688f', year: '1961', value: 8.2 }, + { country: 'Spain', color: '#008f00', year: '1961', value: 4.5 }, + { country: 'Sweden', color: '#bef574', year: '1961', value: 3.7 }, + { country: 'Switzerland', color: '#ffd700', year: '1961', value: 7.2 }, + { country: 'United Kingdom', color: '#ffa500', year: '1961', value: 8.4 }, + { country: 'United States', color: '#ffbd88', year: '1961', value: 11 }, + { country: 'Austria', color: '#red', year: '1962', value: 4.9 }, + { country: 'Canada', color: '#blue', year: '1962', value: 10.5 }, + { country: 'France', color: '#green', year: '1962', value: 5.1 }, + { country: 'Germany', color: '#broun', year: '1962', value: 5.3 }, + { country: 'Japan', color: '#9932cc', year: '1962', value: 5.7 }, + { country: 'Netherlands', color: '#4b93eb', year: '1962', value: 7.4 }, + { country: 'New Zealand', color: '#0e688f', year: '1962', value: 8.1 }, + { country: 'Spain', color: '#008f00', year: '1962', value: 4.6 }, + { country: 'Sweden', color: '#bef574', year: '1962', value: 3.8 }, + { country: 'Switzerland', color: '#ffd700', year: '1962', value: 7.6 }, + { country: 'United Kingdom', color: '#ffa500', year: '1962', value: 8.1 }, + { country: 'United States', color: '#ffbd88', year: '1962', value: 10.9 }, + { country: 'Austria', color: '#red', year: '1963', value: 5.1 }, + { country: 'Canada', color: '#blue', year: '1963', value: 10.5 }, + { country: 'France', color: '#green', year: '1963', value: 5.1 }, + { country: 'Germany', color: '#broun', year: '1963', value: 5.4 }, + { country: 'Japan', color: '#9932cc', year: '1963', value: 5.9 }, + { country: 'Netherlands', color: '#4b93eb', year: '1963', value: 7.6 }, + { country: 'New Zealand', color: '#0e688f', year: '1963', value: 8.4 }, + { country: 'Spain', color: '#008f00', year: '1963', value: 4.7 }, + { country: 'Sweden', color: '#bef574', year: '1963', value: 3.9 }, + { country: 'Switzerland', color: '#ffd700', year: '1963', value: 7.6 }, + { country: 'United Kingdom', color: '#ffa500', year: '1963', value: 8.3 }, + { country: 'United States', color: '#ffbd88', year: '1963', value: 11 }, + { country: 'Austria', color: '#red', year: '1964', value: 5.2 }, + { country: 'Canada', color: '#blue', year: '1964', value: 10.4 }, + { country: 'France', color: '#green', year: '1964', value: 5.1 }, + { country: 'Germany', color: '#broun', year: '1964', value: 5.7 }, + { country: 'Japan', color: '#9932cc', year: '1964', value: 6.2 }, + { country: 'Netherlands', color: '#4b93eb', year: '1964', value: 6.9 }, + { country: 'New Zealand', color: '#0e688f', year: '1964', value: 8.2 }, + { country: 'Spain', color: '#008f00', year: '1964', value: 4.9 }, + { country: 'Sweden', color: '#bef574', year: '1964', value: 3.9 }, + { country: 'Switzerland', color: '#ffd700', year: '1964', value: 7.2 }, + { country: 'United Kingdom', color: '#ffa500', year: '1964', value: 8.3 }, + { country: 'United States', color: '#ffbd88', year: '1964', value: 10.6 }, + { country: 'Austria', color: '#red', year: '1965', value: 5.4 }, + { country: 'Canada', color: '#blue', year: '1965', value: 10.7 }, + { country: 'France', color: '#green', year: '1965', value: 5.3 }, + { country: 'Germany', color: '#broun', year: '1965', value: 6 }, + { country: 'Japan', color: '#9932cc', year: '1965', value: 6.4 }, + { country: 'Netherlands', color: '#4b93eb', year: '1965', value: 8.4 }, + { country: 'New Zealand', color: '#0e688f', year: '1965', value: 8.1 }, + { country: 'Spain', color: '#008f00', year: '1965', value: 5.3 }, + { country: 'Sweden', color: '#bef574', year: '1965', value: 4 }, + { country: 'Switzerland', color: '#ffd700', year: '1965', value: 8.5 }, + { country: 'United Kingdom', color: '#ffa500', year: '1965', value: 8.1 }, + { country: 'United States', color: '#ffbd88', year: '1965', value: 10.7 }, + { country: 'Austria', color: '#red', year: '1966', value: 5.8 }, + { country: 'Canada', color: '#blue', year: '1966', value: 10.8 }, + { country: 'France', color: '#green', year: '1966', value: 5.3 }, + { country: 'Germany', color: '#broun', year: '1966', value: 6.2 }, + { country: 'Japan', color: '#9932cc', year: '1966', value: 6.7 }, + { country: 'Netherlands', color: '#4b93eb', year: '1966', value: 6.8 }, + { country: 'New Zealand', color: '#0e688f', year: '1966', value: 8.6 }, + { country: 'Spain', color: '#008f00', year: '1966', value: 5.4 }, + { country: 'Sweden', color: '#bef574', year: '1966', value: 4.2 }, + { country: 'Switzerland', color: '#ffd700', year: '1966', value: 6.7 }, + { country: 'United Kingdom', color: '#ffa500', year: '1966', value: 8.4 }, + { country: 'United States', color: '#ffbd88', year: '1966', value: 10.7 }, + { country: 'Austria', color: '#red', year: '1967', value: 5.9 }, + { country: 'Canada', color: '#blue', year: '1967', value: 10.6 }, + { country: 'France', color: '#green', year: '1967', value: 5.6 }, + { country: 'Germany', color: '#broun', year: '1967', value: 6.1 }, + { country: 'Japan', color: '#9932cc', year: '1967', value: 7 }, + { country: 'Netherlands', color: '#4b93eb', year: '1967', value: 7.7 }, + { country: 'New Zealand', color: '#0e688f', year: '1967', value: 8.3 }, + { country: 'Spain', color: '#008f00', year: '1967', value: 5.6 }, + { country: 'Sweden', color: '#bef574', year: '1967', value: 4.2 }, + { country: 'Switzerland', color: '#ffd700', year: '1967', value: 7.7 }, + { country: 'United Kingdom', color: '#ffa500', year: '1967', value: 8.5 }, + { country: 'United States', color: '#ffbd88', year: '1967', value: 10.7 }, + { country: 'Austria', color: '#red', year: '1968', value: 6 }, + { country: 'Canada', color: '#blue', year: '1968', value: 10.3 }, + { country: 'France', color: '#green', year: '1968', value: 5.6 }, + { country: 'Germany', color: '#broun', year: '1968', value: 6.5 }, + { country: 'Japan', color: '#9932cc', year: '1968', value: 7 }, + { country: 'Netherlands', color: '#4b93eb', year: '1968', value: 8.4 }, + { country: 'New Zealand', color: '#0e688f', year: '1968', value: 8.2 }, + { country: 'Spain', color: '#008f00', year: '1968', value: 5.7 }, + { country: 'Sweden', color: '#bef574', year: '1968', value: 4.5 }, + { country: 'Switzerland', color: '#ffd700', year: '1968', value: 8.1 }, + { country: 'United Kingdom', color: '#ffa500', year: '1968', value: 8.6 }, + { country: 'United States', color: '#ffbd88', year: '1968', value: 10.4 }, + { country: 'Austria', color: '#red', year: '1969', value: 6.2 }, + { country: 'Canada', color: '#blue', year: '1969', value: 10.1 }, + { country: 'France', color: '#green', year: '1969', value: 5.6 }, + { country: 'Germany', color: '#broun', year: '1969', value: 6.8 }, + { country: 'Japan', color: '#9932cc', year: '1969', value: 7.5 }, + { country: 'Netherlands', color: '#4b93eb', year: '1969', value: 7.7 }, + { country: 'New Zealand', color: '#0e688f', year: '1969', value: 8.2 }, + { country: 'Spain', color: '#008f00', year: '1969', value: 5.7 }, + { country: 'Sweden', color: '#bef574', year: '1969', value: 4.7 }, + { country: 'Switzerland', color: '#ffd700', year: '1969', value: 9 }, + { country: 'United Kingdom', color: '#ffa500', year: '1969', value: 8.8 }, + { country: 'United States', color: '#ffbd88', year: '1969', value: 10 }, + { country: 'Austria', color: '#red', year: '1970', value: 6.5 }, + { country: 'Canada', color: '#blue', year: '1970', value: 10.5 }, + { country: 'France', color: '#green', year: '1970', value: 5.8 }, + { country: 'Germany', color: '#broun', year: '1970', value: 7.1 }, + { country: 'Japan', color: '#9932cc', year: '1970', value: 7.8 }, + { country: 'Netherlands', color: '#4b93eb', year: '1970', value: 8.3 }, + { country: 'New Zealand', color: '#0e688f', year: '1970', value: 8.3 }, + { country: 'Spain', color: '#008f00', year: '1970', value: 5.8 }, + { country: 'Sweden', color: '#bef574', year: '1970', value: 4.7 }, + { country: 'Switzerland', color: '#ffd700', year: '1970', value: 9.5 }, + { country: 'United Kingdom', color: '#ffa500', year: '1970', value: 9 }, + { country: 'United States', color: '#ffbd88', year: '1970', value: 10.2 }, + { country: 'Austria', color: '#red', year: '1971', value: 6.6 }, + { country: 'Canada', color: '#blue', year: '1971', value: 10.5 }, + { country: 'France', color: '#green', year: '1971', value: 5.9 }, + { country: 'Germany', color: '#broun', year: '1971', value: 7.5 }, + { country: 'Japan', color: '#9932cc', year: '1971', value: 8.2 }, + { country: 'Netherlands', color: '#4b93eb', year: '1971', value: 8.4 }, + { country: 'New Zealand', color: '#0e688f', year: '1971', value: 8.2 }, + { country: 'Spain', color: '#008f00', year: '1971', value: 5.9 }, + { country: 'Sweden', color: '#bef574', year: '1971', value: 4.6 }, + { country: 'Switzerland', color: '#ffd700', year: '1971', value: 10.3 }, + { country: 'United Kingdom', color: '#ffa500', year: '1971', value: 8.5 }, + { country: 'United States', color: '#ffbd88', year: '1971', value: 9.9 }, + { country: 'Austria', color: '#red', year: '1972', value: 6.5 }, + { country: 'Canada', color: '#blue', year: '1972', value: 10.6 }, + { country: 'France', color: '#green', year: '1972', value: 5.7 }, + { country: 'Germany', color: '#broun', year: '1972', value: 7.5 }, + { country: 'Japan', color: '#9932cc', year: '1972', value: 8.6 }, + { country: 'Netherlands', color: '#4b93eb', year: '1972', value: 9.2 }, + { country: 'New Zealand', color: '#0e688f', year: '1972', value: 8.3 }, + { country: 'Spain', color: '#008f00', year: '1972', value: 6.1 }, + { country: 'Sweden', color: '#bef574', year: '1972', value: 5.1 }, + { country: 'Switzerland', color: '#ffd700', year: '1972', value: 10.7 }, + { country: 'United Kingdom', color: '#ffa500', year: '1972', value: 9.1 }, + { country: 'United States', color: '#ffbd88', year: '1972', value: 10.2 }, + { country: 'Austria', color: '#red', year: '1973', value: 7 }, + { country: 'Canada', color: '#blue', year: '1973', value: 10.8 }, + { country: 'France', color: '#green', year: '1973', value: 5.9 }, + { country: 'Germany', color: '#broun', year: '1973', value: 7.3 }, + { country: 'Japan', color: '#9932cc', year: '1973', value: 8.9 }, + { country: 'Netherlands', color: '#4b93eb', year: '1973', value: 9.7 }, + { country: 'New Zealand', color: '#0e688f', year: '1973', value: 8.3 }, + { country: 'Spain', color: '#008f00', year: '1973', value: 6.4 }, + { country: 'Sweden', color: '#bef574', year: '1973', value: 4.2 }, + { country: 'Switzerland', color: '#ffd700', year: '1973', value: 9.3 }, + { country: 'United Kingdom', color: '#ffa500', year: '1973', value: 9.5 }, + { country: 'United States', color: '#ffbd88', year: '1973', value: 10.7 }, + { country: 'Austria', color: '#red', year: '1974', value: 6.9 }, + { country: 'Canada', color: '#blue', year: '1974', value: 10.7 }, + { country: 'France', color: '#green', year: '1974', value: 6.1 }, + { country: 'Germany', color: '#broun', year: '1974', value: 7.5 }, + { country: 'Japan', color: '#9932cc', year: '1974', value: 9.5 }, + { country: 'Netherlands', color: '#4b93eb', year: '1974', value: 9.9 }, + { country: 'New Zealand', color: '#0e688f', year: '1974', value: 8.3 }, + { country: 'Spain', color: '#008f00', year: '1974', value: 6.8 }, + { country: 'Sweden', color: '#bef574', year: '1974', value: 4.9 }, + { country: 'Switzerland', color: '#ffd700', year: '1974', value: 9.2 }, + { country: 'United Kingdom', color: '#ffa500', year: '1974', value: 9.4 }, + { country: 'United States', color: '#ffbd88', year: '1974', value: 10.6 }, + { country: 'Austria', color: '#red', year: '1975', value: 6.6 }, + { country: 'Canada', color: '#blue', year: '1975', value: 10.6 }, + { country: 'France', color: '#green', year: '1975', value: 6.3 }, + { country: 'Germany', color: '#broun', year: '1975', value: 7.3 }, + { country: 'Japan', color: '#9932cc', year: '1975', value: 9.5 }, + { country: 'Netherlands', color: '#4b93eb', year: '1975', value: 9.9 }, + { country: 'New Zealand', color: '#0e688f', year: '1975', value: 8.6 }, + { country: 'Spain', color: '#008f00', year: '1975', value: 6.4 }, + { country: 'Sweden', color: '#bef574', year: '1975', value: 5.1 }, + { country: 'Switzerland', color: '#ffd700', year: '1975', value: 8.6 }, + { country: 'United Kingdom', color: '#ffa500', year: '1975', value: 9.2 }, + { country: 'United States', color: '#ffbd88', year: '1975', value: 10.4 }, + { country: 'Austria', color: '#red', year: '1976', value: 6.8 }, + { country: 'Canada', color: '#blue', year: '1976', value: 10.9 }, + { country: 'France', color: '#green', year: '1976', value: 6.1 }, + { country: 'Germany', color: '#broun', year: '1976', value: 7.6 }, + { country: 'Japan', color: '#9932cc', year: '1976', value: 9.4 }, + { country: 'Netherlands', color: '#4b93eb', year: '1976', value: 9.6 }, + { country: 'New Zealand', color: '#0e688f', year: '1976', value: 8.4 }, + { country: 'Spain', color: '#008f00', year: '1976', value: 6.7 }, + { country: 'Sweden', color: '#bef574', year: '1976', value: 5.2 }, + { country: 'Switzerland', color: '#ffd700', year: '1976', value: 8.5 }, + { country: 'United Kingdom', color: '#ffa500', year: '1976', value: 9 }, + { country: 'United States', color: '#ffbd88', year: '1976', value: 10.3 }, + { country: 'Austria', color: '#red', year: '1977', value: 6.9 }, + { country: 'Canada', color: '#blue', year: '1977', value: 10.7 }, + { country: 'France', color: '#green', year: '1977', value: 6.3 }, + { country: 'Germany', color: '#broun', year: '1977', value: 7 }, + { country: 'Japan', color: '#9932cc', year: '1977', value: 9.7 }, + { country: 'Netherlands', color: '#4b93eb', year: '1977', value: 10.8 }, + { country: 'New Zealand', color: '#0e688f', year: '1977', value: 8.5 }, + { country: 'Spain', color: '#008f00', year: '1977', value: 7 }, + { country: 'Sweden', color: '#bef574', year: '1977', value: 4.9 }, + { country: 'Switzerland', color: '#ffd700', year: '1977', value: 8.8 }, + { country: 'United Kingdom', color: '#ffa500', year: '1977', value: 8.7 }, + { country: 'United States', color: '#ffbd88', year: '1977', value: 10.2 }, + { country: 'Austria', color: '#red', year: '1978', value: 7 }, + { country: 'Canada', color: '#blue', year: '1978', value: 10.4 }, + { country: 'France', color: '#green', year: '1978', value: 6.1 }, + { country: 'Germany', color: '#broun', year: '1978', value: 7.3 }, + { country: 'Japan', color: '#9932cc', year: '1978', value: 9.6 }, + { country: 'Netherlands', color: '#4b93eb', year: '1978', value: 9.7 }, + { country: 'New Zealand', color: '#0e688f', year: '1978', value: 8.3 }, + { country: 'Spain', color: '#008f00', year: '1978', value: 6.5 }, + { country: 'Sweden', color: '#bef574', year: '1978', value: 5.1 }, + { country: 'Switzerland', color: '#ffd700', year: '1978', value: 8.5 }, + { country: 'United Kingdom', color: '#ffa500', year: '1978', value: 8.6 }, + { country: 'United States', color: '#ffbd88', year: '1978', value: 10 }, + { country: 'Austria', color: '#red', year: '1979', value: 7.2 }, + { country: 'Canada', color: '#blue', year: '1979', value: 10.5 }, + { country: 'France', color: '#green', year: '1979', value: 6.2 }, + { country: 'Germany', color: '#broun', year: '1979', value: 7.4 }, + { country: 'Japan', color: '#9932cc', year: '1979', value: 9.6 }, + { country: 'Netherlands', color: '#4b93eb', year: '1979', value: 10.4 }, + { country: 'New Zealand', color: '#0e688f', year: '1979', value: 7.9 }, + { country: 'Spain', color: '#008f00', year: '1979', value: 7.2 }, + { country: 'Sweden', color: '#bef574', year: '1979', value: 5.1 }, + { country: 'Switzerland', color: '#ffd700', year: '1979', value: 8.2 }, + { country: 'United Kingdom', color: '#ffa500', year: '1979', value: 8.4 }, + { country: 'United States', color: '#ffbd88', year: '1979', value: 9.9 }, + { country: 'Austria', color: '#red', year: '1980', value: 7.1 }, + { country: 'Canada', color: '#blue', year: '1980', value: 10.3 }, + { country: 'France', color: '#green', year: '1980', value: 6.1 }, + { country: 'Germany', color: '#broun', year: '1980', value: 7.5 }, + { country: 'Japan', color: '#9932cc', year: '1980', value: 9.4 }, + { country: 'Netherlands', color: '#4b93eb', year: '1980', value: 9.2 }, + { country: 'New Zealand', color: '#0e688f', year: '1980', value: 7.7 }, + { country: 'Spain', color: '#008f00', year: '1980', value: 7 }, + { country: 'Sweden', color: '#bef574', year: '1980', value: 5.1 }, + { country: 'Switzerland', color: '#ffd700', year: '1980', value: 8.3 }, + { country: 'United Kingdom', color: '#ffa500', year: '1980', value: 8.1 }, + { country: 'United States', color: '#ffbd88', year: '1980', value: 9.9 }, + { country: 'Austria', color: '#red', year: '1981', value: 7.1 }, + { country: 'Canada', color: '#blue', year: '1981', value: 10.3 }, + { country: 'France', color: '#green', year: '1981', value: 6 }, + { country: 'Germany', color: '#broun', year: '1981', value: 7.6 }, + { country: 'Japan', color: '#9932cc', year: '1981', value: 9.5 }, + { country: 'Netherlands', color: '#4b93eb', year: '1981', value: 8.8 }, + { country: 'New Zealand', color: '#0e688f', year: '1981', value: 7.8 }, + { country: 'Spain', color: '#008f00', year: '1981', value: 6.4 }, + { country: 'Sweden', color: '#bef574', year: '1981', value: 4.9 }, + { country: 'Switzerland', color: '#ffd700', year: '1981', value: 8.4 }, + { country: 'United Kingdom', color: '#ffa500', year: '1981', value: 7.5 }, + { country: 'United States', color: '#ffbd88', year: '1981', value: 9.9 }, + { country: 'Austria', color: '#red', year: '1982', value: 7 }, + { country: 'Canada', color: '#blue', year: '1982', value: 10.4 }, + { country: 'France', color: '#green', year: '1982', value: 6 }, + { country: 'Germany', color: '#broun', year: '1982', value: 6.9 }, + { country: 'Japan', color: '#9932cc', year: '1982', value: 9.4 }, + { country: 'Netherlands', color: '#4b93eb', year: '1982', value: 9.1 }, + { country: 'New Zealand', color: '#0e688f', year: '1982', value: 7.6 }, + { country: 'Spain', color: '#008f00', year: '1982', value: 6.7 }, + { country: 'Sweden', color: '#bef574', year: '1982', value: 5.1 }, + { country: 'Switzerland', color: '#ffd700', year: '1982', value: 8.4 }, + { country: 'United Kingdom', color: '#ffa500', year: '1982', value: 6.9 }, + { country: 'United States', color: '#ffbd88', year: '1982', value: 9.7 }, + { country: 'Austria', color: '#red', year: '1983', value: 7.2 }, + { country: 'Canada', color: '#blue', year: '1983', value: 9.7 }, + { country: 'France', color: '#green', year: '1983', value: 6.1 }, + { country: 'Germany', color: '#broun', year: '1983', value: 7.2 }, + { country: 'Japan', color: '#9932cc', year: '1983', value: 9.3 }, + { country: 'Netherlands', color: '#4b93eb', year: '1983', value: 9.8 }, + { country: 'New Zealand', color: '#0e688f', year: '1983', value: 7.5 }, + { country: 'Spain', color: '#008f00', year: '1983', value: 6.7 }, + { country: 'Sweden', color: '#bef574', year: '1983', value: 4.9 }, + { country: 'Switzerland', color: '#ffd700', year: '1983', value: 8.5 }, + { country: 'United Kingdom', color: '#ffa500', year: '1983', value: 6.9 }, + { country: 'United States', color: '#ffbd88', year: '1983', value: 9.1 }, + { country: 'Austria', color: '#red', year: '1984', value: 7 }, + { country: 'Canada', color: '#blue', year: '1984', value: 9.6 }, + { country: 'France', color: '#green', year: '1984', value: 6.1 }, + { country: 'Germany', color: '#broun', year: '1984', value: 7.1 }, + { country: 'Japan', color: '#9932cc', year: '1984', value: 9.2 }, + { country: 'Netherlands', color: '#4b93eb', year: '1984', value: 8 }, + { country: 'New Zealand', color: '#0e688f', year: '1984', value: 7.5 }, + { country: 'Spain', color: '#008f00', year: '1984', value: 6.9 }, + { country: 'Sweden', color: '#bef574', year: '1984', value: 5 }, + { country: 'Switzerland', color: '#ffd700', year: '1984', value: 8.4 }, + { country: 'United Kingdom', color: '#ffa500', year: '1984', value: 6.6 }, + { country: 'United States', color: '#ffbd88', year: '1984', value: 9 }, + { country: 'Austria', color: '#red', year: '1985', value: 7 }, + { country: 'Canada', color: '#blue', year: '1985', value: 9.1 }, + { country: 'France', color: '#green', year: '1985', value: 6.4 }, + { country: 'Germany', color: '#broun', year: '1985', value: 7.2 }, + { country: 'Japan', color: '#9932cc', year: '1985', value: 9 }, + { country: 'Netherlands', color: '#4b93eb', year: '1985', value: 8 }, + { country: 'New Zealand', color: '#0e688f', year: '1985', value: 6.7 }, + { country: 'Spain', color: '#008f00', year: '1985', value: 7.3 }, + { country: 'Sweden', color: '#bef574', year: '1985', value: 4.9 }, + { country: 'Switzerland', color: '#ffd700', year: '1985', value: 8.1 }, + { country: 'United Kingdom', color: '#ffa500', year: '1985', value: 6.5 }, + { country: 'United States', color: '#ffbd88', year: '1985', value: 8.8 }, + { country: 'Austria', color: '#red', year: '1986', value: 7 }, + { country: 'Canada', color: '#blue', year: '1986', value: 8.7 }, + { country: 'France', color: '#green', year: '1986', value: 6.2 }, + { country: 'Germany', color: '#broun', year: '1986', value: 7 }, + { country: 'Japan', color: '#9932cc', year: '1986', value: 8.8 }, + { country: 'Netherlands', color: '#4b93eb', year: '1986', value: 7.9 }, + { country: 'New Zealand', color: '#0e688f', year: '1986', value: 6.2 }, + { country: 'Spain', color: '#008f00', year: '1986', value: 7.1 }, + { country: 'Sweden', color: '#bef574', year: '1986', value: 4.8 }, + { country: 'Switzerland', color: '#ffd700', year: '1986', value: 8.1 }, + { country: 'United Kingdom', color: '#ffa500', year: '1986', value: 6.3 }, + { country: 'United States', color: '#ffbd88', year: '1986', value: 8.6 }, + { country: 'Austria', color: '#red', year: '1987', value: 6.8 }, + { country: 'Canada', color: '#blue', year: '1987', value: 8.3 }, + { country: 'France', color: '#green', year: '1987', value: 6.1 }, + { country: 'Germany', color: '#broun', year: '1987', value: 7 }, + { country: 'Japan', color: '#9932cc', year: '1987', value: 8.7 }, + { country: 'Netherlands', color: '#4b93eb', year: '1987', value: 7.6 }, + { country: 'New Zealand', color: '#0e688f', year: '1987', value: 6.2 }, + { country: 'Spain', color: '#008f00', year: '1987', value: 7.2 }, + { country: 'Sweden', color: '#bef574', year: '1987', value: 4.7 }, + { country: 'Switzerland', color: '#ffd700', year: '1987', value: 8 }, + { country: 'United Kingdom', color: '#ffa500', year: '1987', value: 6.3 }, + { country: 'United States', color: '#ffbd88', year: '1987', value: 8.3 }, + { country: 'Austria', color: '#red', year: '1988', value: 6.4 }, + { country: 'Canada', color: '#blue', year: '1988', value: 8 }, + { country: 'France', color: '#green', year: '1988', value: 6 }, + { country: 'Germany', color: '#broun', year: '1988', value: 6.9 }, + { country: 'Japan', color: '#9932cc', year: '1988', value: 8.6 }, + { country: 'Netherlands', color: '#4b93eb', year: '1988', value: 7.5 }, + { country: 'New Zealand', color: '#0e688f', year: '1988', value: 6.3 }, + { country: 'Spain', color: '#008f00', year: '1988', value: 6.9 }, + { country: 'Sweden', color: '#bef574', year: '1988', value: 4.7 }, + { country: 'Switzerland', color: '#ffd700', year: '1988', value: 7.9 }, + { country: 'United Kingdom', color: '#ffa500', year: '1988', value: 6.2 }, + { country: 'United States', color: '#ffbd88', year: '1988', value: 8.1 }, + { country: 'Austria', color: '#red', year: '1989', value: 6.2 }, + { country: 'Canada', color: '#blue', year: '1989', value: 7.3 }, + { country: 'France', color: '#green', year: '1989', value: 6 }, + { country: 'Germany', color: '#broun', year: '1989', value: 7 }, + { country: 'Japan', color: '#9932cc', year: '1989', value: 8.6 }, + { country: 'Netherlands', color: '#4b93eb', year: '1989', value: 7.5 }, + { country: 'New Zealand', color: '#0e688f', year: '1989', value: 5.1 }, + { country: 'Spain', color: '#008f00', year: '1989', value: 7 }, + { country: 'Sweden', color: '#bef574', year: '1989', value: 4.6 }, + { country: 'Switzerland', color: '#ffd700', year: '1989', value: 7.9 }, + { country: 'United Kingdom', color: '#ffa500', year: '1989', value: 6.3 }, + { country: 'United States', color: '#ffbd88', year: '1989', value: 7.6 }, + { country: 'Austria', color: '#red', year: '1990', value: 6.3 }, + { country: 'Canada', color: '#blue', year: '1990', value: 7 }, + { country: 'France', color: '#green', year: '1990', value: 5.9 }, + { country: 'Germany', color: '#broun', year: '1990', value: null }, + { country: 'Japan', color: '#9932cc', year: '1990', value: 8.8 }, + { country: 'Netherlands', color: '#4b93eb', year: '1990', value: 7.6 }, + { country: 'New Zealand', color: '#0e688f', year: '1990', value: 5.3 }, + { country: 'Spain', color: '#008f00', year: '1990', value: 7.2 }, + { country: 'Sweden', color: '#bef574', year: '1990', value: 4.5 }, + { country: 'Switzerland', color: '#ffd700', year: '1990', value: 7.8 }, + { country: 'United Kingdom', color: '#ffa500', year: '1990', value: 6.5 }, + { country: 'United States', color: '#ffbd88', year: '1990', value: 7.4 }, + { country: 'Austria', color: '#red', year: '1991', value: 6.4 }, + { country: 'Canada', color: '#blue', year: '1991', value: 6.3 }, + { country: 'France', color: '#green', year: '1991', value: 6 }, + { country: 'Germany', color: '#broun', year: '1991', value: 6.6 }, + { country: 'Japan', color: '#9932cc', year: '1991', value: 8.9 }, + { country: 'Netherlands', color: '#4b93eb', year: '1991', value: 8 }, + { country: 'New Zealand', color: '#0e688f', year: '1991', value: 4.7 }, + { country: 'Spain', color: '#008f00', year: '1991', value: 7.3 }, + { country: 'Sweden', color: '#bef574', year: '1991', value: 4.5 }, + { country: 'Switzerland', color: '#ffd700', year: '1991', value: 7.8 }, + { country: 'United Kingdom', color: '#ffa500', year: '1991', value: 6.2 }, + { country: 'United States', color: '#ffbd88', year: '1991', value: 7.1 }, + { country: 'Austria', color: '#red', year: '1992', value: 6.1 }, + { country: 'Canada', color: '#blue', year: '1992', value: 6.4 }, + { country: 'France', color: '#green', year: '1992', value: 5.9 }, + { country: 'Germany', color: '#broun', year: '1992', value: 6.1 }, + { country: 'Japan', color: '#9932cc', year: '1992', value: 8.8 }, + { country: 'Netherlands', color: '#4b93eb', year: '1992', value: 7.3 }, + { country: 'New Zealand', color: '#0e688f', year: '1992', value: 4.2 }, + { country: 'Spain', color: '#008f00', year: '1992', value: 6.9 }, + { country: 'Sweden', color: '#bef574', year: '1992', value: 4.6 }, + { country: 'Switzerland', color: '#ffd700', year: '1992', value: 8.2 }, + { country: 'United Kingdom', color: '#ffa500', year: '1992', value: 5.9 }, + { country: 'United States', color: '#ffbd88', year: '1992', value: 6.9 }, + { country: 'Austria', color: '#red', year: '1993', value: 5.8 }, + { country: 'Canada', color: '#blue', year: '1993', value: 6 }, + { country: 'France', color: '#green', year: '1993', value: 5.7 }, + { country: 'Germany', color: '#broun', year: '1993', value: 5.9 }, + { country: 'Japan', color: '#9932cc', year: '1993', value: 8.8 }, + { country: 'Netherlands', color: '#4b93eb', year: '1993', value: 6.6 }, + { country: 'New Zealand', color: '#0e688f', year: '1993', value: 4.2 }, + { country: 'Spain', color: '#008f00', year: '1993', value: 6.3 }, + { country: 'Sweden', color: '#bef574', year: '1993', value: 3.8 }, + { country: 'Switzerland', color: '#ffd700', year: '1993', value: 7.6 }, + { country: 'United Kingdom', color: '#ffa500', year: '1993', value: 5.7 }, + { country: 'United States', color: '#ffbd88', year: '1993', value: 6.6 }, + { country: 'Austria', color: '#red', year: '1994', value: 5.9 }, + { country: 'Canada', color: '#blue', year: '1994', value: 6.6 }, + { country: 'France', color: '#green', year: '1994', value: 5.6 }, + { country: 'Germany', color: '#broun', year: '1994', value: 6 }, + { country: 'Japan', color: '#9932cc', year: '1994', value: 8.8 }, + { country: 'Netherlands', color: '#4b93eb', year: '1994', value: 6.8 }, + { country: 'New Zealand', color: '#0e688f', year: '1994', value: 4 }, + { country: 'Spain', color: '#008f00', year: '1994', value: 6.8 }, + { country: 'Sweden', color: '#bef574', year: '1994', value: 3.6 }, + { country: 'Switzerland', color: '#ffd700', year: '1994', value: 7.4 }, + { country: 'United Kingdom', color: '#ffa500', year: '1994', value: 5.6 }, + { country: 'United States', color: '#ffbd88', year: '1994', value: 6.6 }, + { country: 'Austria', color: '#red', year: '1995', value: 5.6 }, + { country: 'Canada', color: '#blue', year: '1995', value: 5.9 }, + { country: 'France', color: '#green', year: '1995', value: 5.4 }, + { country: 'Germany', color: '#broun', year: '1995', value: 6 }, + { country: 'Japan', color: '#9932cc', year: '1995', value: 8.8 }, + { country: 'Netherlands', color: '#4b93eb', year: '1995', value: 6.8 }, + { country: 'New Zealand', color: '#0e688f', year: '1995', value: 4 }, + { country: 'Spain', color: '#008f00', year: '1995', value: 6.3 }, + { country: 'Sweden', color: '#bef574', year: '1995', value: 3.4 }, + { country: 'Switzerland', color: '#ffd700', year: '1995', value: 7.3 }, + { country: 'United Kingdom', color: '#ffa500', year: '1995', value: 5.7 }, + { country: 'United States', color: '#ffbd88', year: '1995', value: 6.5 }, + { country: 'Austria', color: '#red', year: '1996', value: 5.4 }, + { country: 'Canada', color: '#blue', year: '1996', value: 6.2 }, + { country: 'France', color: '#green', year: '1996', value: 5.4 }, + { country: 'Germany', color: '#broun', year: '1996', value: 6 }, + { country: 'Japan', color: '#9932cc', year: '1996', value: 9.1 }, + { country: 'Netherlands', color: '#4b93eb', year: '1996', value: 6.2 }, + { country: 'New Zealand', color: '#0e688f', year: '1996', value: 4.2 }, + { country: 'Spain', color: '#008f00', year: '1996', value: 6 }, + { country: 'Sweden', color: '#bef574', year: '1996', value: 3.5 }, + { country: 'Switzerland', color: '#ffd700', year: '1996', value: 7.2 }, + { country: 'United Kingdom', color: '#ffa500', year: '1996', value: 5.7 }, + { country: 'United States', color: '#ffbd88', year: '1996', value: 6.4 }, + { country: 'Austria', color: '#red', year: '1997', value: 5.7 }, + { country: 'Canada', color: '#blue', year: '1997', value: 5.8 }, + { country: 'France', color: '#green', year: '1997', value: 5.2 }, + { country: 'Germany', color: '#broun', year: '1997', value: 6.1 }, + { country: 'Japan', color: '#9932cc', year: '1997', value: 8.5 }, + { country: 'Netherlands', color: '#4b93eb', year: '1997', value: 6.5 }, + { country: 'New Zealand', color: '#0e688f', year: '1997', value: 4.1 }, + { country: 'Spain', color: '#008f00', year: '1997', value: 6.6 }, + { country: 'Sweden', color: '#bef574', year: '1997', value: 2.6 }, + { country: 'Switzerland', color: '#ffd700', year: '1997', value: 7 }, + { country: 'United Kingdom', color: '#ffa500', year: '1997', value: 5.6 }, + { country: 'United States', color: '#ffbd88', year: '1997', value: 6.3 }, + { country: 'Austria', color: '#red', year: '1998', value: 6.4 }, + { country: 'Canada', color: '#blue', year: '1998', value: 5.8 }, + { country: 'France', color: '#green', year: '1998', value: 5.2 }, + { country: 'Germany', color: '#broun', year: '1998', value: 6.1 }, + { country: 'Japan', color: '#9932cc', year: '1998', value: 8.7 }, + { country: 'Netherlands', color: '#4b93eb', year: '1998', value: 6.6 }, + { country: 'New Zealand', color: '#0e688f', year: '1998', value: 4 }, + { country: 'Spain', color: '#008f00', year: '1998', value: 7.3 }, + { country: 'Sweden', color: '#bef574', year: '1998', value: 2.5 }, + { country: 'Switzerland', color: '#ffd700', year: '1998', value: 7.1 }, + { country: 'United Kingdom', color: '#ffa500', year: '1998', value: 5.6 }, + { country: 'United States', color: '#ffbd88', year: '1998', value: 6 }, + { country: 'Austria', color: '#red', year: '1999', value: 6.6 }, + { country: 'Canada', color: '#blue', year: '1999', value: 5.7 }, + { country: 'France', color: '#green', year: '1999', value: 5.2 }, + { country: 'Germany', color: '#broun', year: '1999', value: 6.4 }, + { country: 'Japan', color: '#9932cc', year: '1999', value: 8.5 }, + { country: 'Netherlands', color: '#4b93eb', year: '1999', value: 6.4 }, + { country: 'New Zealand', color: '#0e688f', year: '1999', value: 3.8 }, + { country: 'Spain', color: '#008f00', year: '1999', value: 7.1 }, + { country: 'Sweden', color: '#bef574', year: '1999', value: 2.8 }, + { country: 'Switzerland', color: '#ffd700', year: '1999', value: 6.8 }, + { country: 'United Kingdom', color: '#ffa500', year: '1999', value: 5.8 }, + { country: 'United States', color: '#ffbd88', year: '1999', value: 5.7 }, + { country: 'Austria', color: '#red', year: '2000', value: 6.5 }, + { country: 'Canada', color: '#blue', year: '2000', value: 5.3 }, + { country: 'France', color: '#green', year: '2000', value: 5.1 }, + { country: 'Germany', color: '#broun', year: '2000', value: 6.1 }, + { country: 'Japan', color: '#9932cc', year: '2000', value: 8.3 }, + { country: 'Netherlands', color: '#4b93eb', year: '2000', value: 6.4 }, + { country: 'New Zealand', color: '#0e688f', year: '2000', value: 3.9 }, + { country: 'Spain', color: '#008f00', year: '2000', value: 7.1 }, + { country: 'Sweden', color: '#bef574', year: '2000', value: 2.9 }, + { country: 'Switzerland', color: '#ffd700', year: '2000', value: 6.7 }, + { country: 'United Kingdom', color: '#ffa500', year: '2000', value: 5.7 }, + { country: 'United States', color: '#ffbd88', year: '2000', value: 5.4 }, + { country: 'Austria', color: '#red', year: '2001', value: 6.3 }, + { country: 'Canada', color: '#blue', year: '2001', value: 5 }, + { country: 'France', color: '#green', year: '2001', value: 5.2 }, + { country: 'Germany', color: '#broun', year: '2001', value: 6.2 }, + { country: 'Japan', color: '#9932cc', year: '2001', value: 8.1 }, + { country: 'Netherlands', color: '#4b93eb', year: '2001', value: 6 }, + { country: 'New Zealand', color: '#0e688f', year: '2001', value: 3.4 }, + { country: 'Spain', color: '#008f00', year: '2001', value: 7.2 }, + { country: 'Sweden', color: '#bef574', year: '2001', value: 2.9 }, + { country: 'Switzerland', color: '#ffd700', year: '2001', value: 6.5 }, + { country: 'United Kingdom', color: '#ffa500', year: '2001', value: 5.6 }, + { country: 'United States', color: '#ffbd88', year: '2001', value: 5.3 }, + { country: 'Austria', color: '#red', year: '2002', value: 4.8 }, + { country: 'Canada', color: '#blue', year: '2002', value: 4.4 }, + { country: 'France', color: '#green', year: '2002', value: 4.9 }, + { country: 'Germany', color: '#broun', year: '2002', value: 6.3 }, + { country: 'Japan', color: '#9932cc', year: '2002', value: 7.9 }, + { country: 'Netherlands', color: '#4b93eb', year: '2002', value: 6.3 }, + { country: 'New Zealand', color: '#0e688f', year: '2002', value: 3.5 }, + { country: 'Spain', color: '#008f00', year: '2002', value: 7.1 }, + { country: 'Sweden', color: '#bef574', year: '2002', value: 3 }, + { country: 'Switzerland', color: '#ffd700', year: '2002', value: 6.5 }, + { country: 'United Kingdom', color: '#ffa500', year: '2002', value: 5.5 }, + { country: 'United States', color: '#ffbd88', year: '2002', value: 5.1 }, + { country: 'Austria', color: '#red', year: '2003', value: 4.6 }, + { country: 'Canada', color: '#blue', year: '2003', value: 4.2 }, + { country: 'France', color: '#green', year: '2003', value: 4.3 }, + { country: 'Germany', color: '#broun', year: '2003', value: 5.9 }, + { country: 'Japan', color: '#9932cc', year: '2003', value: 7.6 }, + { country: 'Netherlands', color: '#4b93eb', year: '2003', value: 6.2 }, + { country: 'New Zealand', color: '#0e688f', year: '2003', value: 3.1 }, + { country: 'Spain', color: '#008f00', year: '2003', value: 7.1 }, + { country: 'Sweden', color: '#bef574', year: '2003', value: 2.9 }, + { country: 'Switzerland', color: '#ffd700', year: '2003', value: 6.6 }, + { country: 'United Kingdom', color: '#ffa500', year: '2003', value: 5.4 }, + { country: 'United States', color: '#ffbd88', year: '2003', value: 4.9 }, + { country: 'Austria', color: '#red', year: '2004', value: 4.6 }, + { country: 'Canada', color: '#blue', year: '2004', value: 4 }, + { country: 'France', color: '#green', year: '2004', value: 3.5 }, + { country: 'Germany', color: '#broun', year: '2004', value: 5.2 }, + { country: 'Japan', color: '#9932cc', year: '2004', value: 7.4 }, + { country: 'Netherlands', color: '#4b93eb', year: '2004', value: 5.6 }, + { country: 'New Zealand', color: '#0e688f', year: '2004', value: 3.1 }, + { country: 'Spain', color: '#008f00', year: '2004', value: 7.2 }, + { country: 'Sweden', color: '#bef574', year: '2004', value: 2.8 }, + { country: 'Switzerland', color: '#ffd700', year: '2004', value: 6.4 }, + { country: 'United Kingdom', color: '#ffa500', year: '2004', value: 5.2 }, + { country: 'United States', color: '#ffbd88', year: '2004', value: 4.7 }, + { country: 'Austria', color: '#red', year: '2005', value: null }, + { country: 'Canada', color: '#blue', year: '2005', value: 3.7 }, + { country: 'France', color: '#green', year: '2005', value: 3.5 }, + { country: 'Germany', color: '#broun', year: '2005', value: 5 }, + { country: 'Japan', color: '#9932cc', year: '2005', value: 7.2 }, + { country: 'Netherlands', color: '#4b93eb', year: '2005', value: 5.1 }, + { country: 'New Zealand', color: '#0e688f', year: '2005', value: 3.3 }, + { country: 'Spain', color: '#008f00', year: '2005', value: 7 }, + { country: 'Sweden', color: '#bef574', year: '2005', value: 2.7 }, + { country: 'Switzerland', color: '#ffd700', year: '2005', value: 5.7 }, + { country: 'United Kingdom', color: '#ffa500', year: '2005', value: 5.1 }, + { country: 'United States', color: '#ffbd88', year: '2005', value: 4.5 }, + { country: 'Austria', color: '#red', year: '2006', value: null }, + { country: 'Canada', color: '#blue', year: '2006', value: 3.4 }, + { country: 'France', color: '#green', year: '2006', value: 3.5 }, + { country: 'Germany', color: '#broun', year: '2006', value: 4.5 }, + { country: 'Japan', color: '#9932cc', year: '2006', value: 6.8 }, + { country: 'Netherlands', color: '#4b93eb', year: '2006', value: 5.1 }, + { country: 'New Zealand', color: '#0e688f', year: '2006', value: 3.2 }, + { country: 'Spain', color: '#008f00', year: '2006', value: 6.8 }, + { country: 'Sweden', color: '#bef574', year: '2006', value: 2.6 }, + { country: 'Switzerland', color: '#ffd700', year: '2006', value: 5.8 }, + { country: 'United Kingdom', color: '#ffa500', year: '2006', value: 4.9 }, + { country: 'United States', color: '#ffbd88', year: '2006', value: 4.5 }, + { country: 'Austria', color: '#red', year: '2007', value: null }, + { country: 'Canada', color: '#blue', year: '2007', value: 3.2 }, + { country: 'France', color: '#green', year: '2007', value: 3.5 }, + { country: 'Germany', color: '#broun', year: '2007', value: 4.4 }, + { country: 'Japan', color: '#9932cc', year: '2007', value: 6.5 }, + { country: 'Netherlands', color: '#4b93eb', year: '2007', value: 5.3 }, + { country: 'New Zealand', color: '#0e688f', year: '2007', value: 3.2 }, + { country: 'Spain', color: '#008f00', year: '2007', value: 6.6 }, + { country: 'Sweden', color: '#bef574', year: '2007', value: null }, + { country: 'Switzerland', color: '#ffd700', year: '2007', value: 5.4 }, + { country: 'United Kingdom', color: '#ffa500', year: '2007', value: 4.7 }, + { country: 'United States', color: '#ffbd88', year: '2007', value: 4.2 }, + { country: 'Austria', color: '#red', year: '2008', value: null }, + { country: 'Canada', color: '#blue', year: '2008', value: 3 }, + { country: 'France', color: '#green', year: '2008', value: 3.4 }, + { country: 'Germany', color: '#broun', year: '2008', value: 4.2 }, + { country: 'Japan', color: '#9932cc', year: '2008', value: 6.2 }, + { country: 'Netherlands', color: '#4b93eb', year: '2008', value: 5.1 }, + { country: 'New Zealand', color: '#0e688f', year: '2008', value: 3.3 }, + { country: 'Spain', color: '#008f00', year: '2008', value: 6.7 }, + { country: 'Sweden', color: '#bef574', year: '2008', value: null }, + { country: 'Switzerland', color: '#ffd700', year: '2008', value: 5.7 }, + { country: 'United Kingdom', color: '#ffa500', year: '2008', value: 4.5 }, + { country: 'United States', color: '#ffbd88', year: '2008', value: 4 }, + { country: 'Austria', color: '#red', year: '2009', value: null }, + { country: 'Canada', color: '#blue', year: '2009', value: 3.1 }, + { country: 'France', color: '#green', year: '2009', value: 3.5 }, + { country: 'Germany', color: '#broun', year: '2009', value: 4.3 }, + { country: 'Japan', color: '#9932cc', year: '2009', value: 5.9 }, + { country: 'Netherlands', color: '#4b93eb', year: '2009', value: 4.6 }, + { country: 'New Zealand', color: '#0e688f', year: '2009', value: 3.1 }, + { country: 'Spain', color: '#008f00', year: '2009', value: 6.1 }, + { country: 'Sweden', color: '#bef574', year: '2009', value: null }, + { country: 'Switzerland', color: '#ffd700', year: '2009', value: 5.6 }, + { country: 'United Kingdom', color: '#ffa500', year: '2009', value: 4.3 }, + { country: 'United States', color: '#ffbd88', year: '2009', value: 3.7 }, + { country: 'Austria', color: '#red', year: '2010', value: null }, + { country: 'Canada', color: '#blue', year: '2010', value: 3.5 }, + { country: 'France', color: '#green', year: '2010', value: 3.5 }, + { country: 'Germany', color: '#broun', year: '2010', value: 4.2 }, + { country: 'Japan', color: '#9932cc', year: '2010', value: 5.3 }, + { country: 'Netherlands', color: '#4b93eb', year: '2010', value: 4.5 }, + { country: 'New Zealand', color: '#0e688f', year: '2010', value: null }, + { country: 'Spain', color: '#008f00', year: '2010', value: 5.5 }, + { country: 'Sweden', color: '#bef574', year: '2010', value: null }, + { country: 'Switzerland', color: '#ffd700', year: '2010', value: null }, + { country: 'United Kingdom', color: '#ffa500', year: '2010', value: 4 }, + { country: 'United States', color: '#ffbd88', year: '2010', value: 3.6 }, + { country: 'Austria', color: '#red', year: '2011', value: null }, + { country: 'Canada', color: '#blue', year: '2011', value: null }, + { country: 'France', color: '#green', year: '2011', value: null }, + { country: 'Germany', color: '#broun', year: '2011', value: 4.4 }, + { country: 'Japan', color: '#9932cc', year: '2011', value: 4.9 }, + { country: 'Netherlands', color: '#4b93eb', year: '2011', value: 1.5 }, + { country: 'New Zealand', color: '#0e688f', year: '2011', value: null }, + { country: 'Spain', color: '#008f00', year: '2011', value: null }, + { country: 'Sweden', color: '#bef574', year: '2011', value: null }, + { country: 'Switzerland', color: '#ffd700', year: '2011', value: null }, + { country: 'United Kingdom', color: '#ffa500', year: '2011', value: 3.5 }, + { country: 'United States', color: '#ffbd88', year: '2011', value: 3.5 }, + { country: 'Austria', color: '#red', year: '2012', value: null }, + { country: 'Canada', color: '#blue', year: '2012', value: null }, + { country: 'France', color: '#green', year: '2012', value: null }, + { country: 'Germany', color: '#broun', year: '2012', value: 4.2 }, + { country: 'Japan', color: '#9932cc', year: '2012', value: 4.9 }, + { country: 'Netherlands', color: '#4b93eb', year: '2012', value: 1.5 }, + { country: 'New Zealand', color: '#0e688f', year: '2012', value: null }, + { country: 'Spain', color: '#008f00', year: '2012', value: null }, + { country: 'Sweden', color: '#bef574', year: '2012', value: null }, + { country: 'Switzerland', color: '#ffd700', year: '2012', value: null }, + { country: 'United Kingdom', color: '#ffa500', year: '2012', value: 3.4 }, + { country: 'United States', color: '#ffbd88', year: '2012', value: 3.5 }, + { country: 'Austria', color: '#red', year: '2013', value: null }, + { country: 'Canada', color: '#blue', year: '2013', value: null }, + { country: 'France', color: '#green', year: '2013', value: null }, + { country: 'Germany', color: '#broun', year: '2013', value: 4.1 }, + { country: 'Japan', color: '#9932cc', year: '2013', value: 4.9 }, + { country: 'Netherlands', color: '#4b93eb', year: '2013', value: null }, + { country: 'New Zealand', color: '#0e688f', year: '2013', value: null }, + { country: 'Spain', color: '#008f00', year: '2013', value: null }, + { country: 'Sweden', color: '#bef574', year: '2013', value: null }, + { country: 'Switzerland', color: '#ffd700', year: '2013', value: null }, + { country: 'United Kingdom', color: '#ffa500', year: '2013', value: 3.2 }, + { country: 'United States', color: '#ffbd88', year: '2013', value: 3.3 }, + { country: 'Austria', color: '#red', year: '2014', value: null }, + { country: 'Canada', color: '#blue', year: '2014', value: null }, + { country: 'France', color: '#green', year: '2014', value: null }, + { country: 'Germany', color: '#broun', year: '2014', value: 4.1 }, + { country: 'Japan', color: '#9932cc', year: '2014', value: 4.5 }, + { country: 'Netherlands', color: '#4b93eb', year: '2014', value: null }, + { country: 'New Zealand', color: '#0e688f', year: '2014', value: null }, + { country: 'Spain', color: '#008f00', year: '2014', value: null }, + { country: 'Sweden', color: '#bef574', year: '2014', value: null }, + { country: 'Switzerland', color: '#ffd700', year: '2014', value: null }, + { country: 'United Kingdom', color: '#ffa500', year: '2014', value: 3 }, + { country: 'United States', color: '#ffbd88', year: '2014', value: 3.2 }, + { country: 'Austria', color: '#red', year: '2015', value: null }, + { country: 'Canada', color: '#blue', year: '2015', value: null }, + { country: 'France', color: '#green', year: '2015', value: null }, + { country: 'Germany', color: '#broun', year: '2015', value: 4.2 }, + { country: 'Japan', color: '#9932cc', year: '2015', value: 4.6 }, + { country: 'Netherlands', color: '#4b93eb', year: '2015', value: null }, + { country: 'New Zealand', color: '#0e688f', year: '2015', value: null }, + { country: 'Spain', color: '#008f00', year: '2015', value: null }, + { country: 'Sweden', color: '#bef574', year: '2015', value: null }, + { country: 'Switzerland', color: '#ffd700', year: '2015', value: null }, + { country: 'United Kingdom', color: '#ffa500', year: '2015', value: null }, + { country: 'United States', color: '#ffbd88', year: '2015', value: null }, ] diff --git a/src/Line/__stories__/Line.stories.tsx b/src/Line/__stories__/Line.stories.tsx index 77cb5dd..c378c70 100644 --- a/src/Line/__stories__/Line.stories.tsx +++ b/src/Line/__stories__/Line.stories.tsx @@ -4,7 +4,7 @@ import { useThemeVars } from '@consta/uikit/useThemeVars' import { createMetadata } from '@/__private__/storybook' -import { data } from '../__mocks__/mock.data' +import { data, Item } from '../__mocks__/mock.data' import { Line, LineProps } from '../Line' const pxInNumber = (string: string) => Number(string.replace('px', '')) @@ -12,48 +12,12 @@ const pxInNumber = (string: string) => Number(string.replace('px', '')) const Default = () => { const vars = useThemeVars() - const options: LineProps = { + const options: LineProps = { data, padding: 'auto', - xField: 'Date', - yField: 'scales', - yAxis: { - tickLine: { - length: 0, - }, - label: { - style: { - fill: vars.color.primary['--color-typo-secondary'], - }, - }, - grid: { - line: { - style: { - stroke: vars.color.primary['--color-bg-system'], - lineWidth: pxInNumber(vars.space['--space-3xs']), - }, - }, - }, - }, - xAxis: { - tickLine: { - length: 4, - style: { - stroke: vars.color.primary['--color-bg-system'], - }, - }, - label: { - style: { - fill: vars.color.primary['--color-typo-secondary'], - }, - }, - }, - point: { - size: pxInNumber(vars.space['--space-2xs']), - style: { - stroke: 'transparent', - }, - }, + xField: 'year', + yField: 'value', + seriesField: 'country', annotations: [ { type: 'text', @@ -76,10 +40,10 @@ const Default = () => { }, }, ], - theme: { - styleSheet: { - fontFamily: vars.font['--font-primary'], - }, + lineStyle: ({ color }) => { + return { + stroke: color, + } }, } diff --git a/src/Line/helpers.ts b/src/Line/helpers.ts new file mode 100644 index 0000000..cea91ba --- /dev/null +++ b/src/Line/helpers.ts @@ -0,0 +1,11 @@ +import { LineProps } from './Line' + +export const withDefaultProps = (props: LineProps): LineProps => { + return { + ...props, + legend: { + animate: true, + ...props.legend, + }, + } +} diff --git a/src/Line/types.ts b/src/Line/types.ts new file mode 100644 index 0000000..0e1a822 --- /dev/null +++ b/src/Line/types.ts @@ -0,0 +1,15 @@ +import { LineOptions as G2plotLineProps, ShapeStyle } from '@antv/g2plot' + +import { ContainerProps, Tooltip } from '@/__private__/hooks/useChart' +import { ChartRefOptions } from '@/__private__/utils/types/ChartRefOptions' + +export type LineProps = Omit & { + tooltip?: Tooltip + theme?: never + children?: never + data: Item[] + lineStyle: ShapeStyle | ((item: Item) => ShapeStyle) +} & ContainerProps & + React.RefAttributes & { chartRef?: ChartRefOptions } + +export type Line = (props: LineProps) => React.ReactElement | null diff --git a/src/Liquid/Liquid.tsx b/src/Liquid/Liquid.tsx index b826305..7cefef7 100644 --- a/src/Liquid/Liquid.tsx +++ b/src/Liquid/Liquid.tsx @@ -2,11 +2,15 @@ import React, { useEffect, useImperativeHandle } from 'react' import { Liquid as G2plotLiquid, LiquidOptions as G2plotLiquidProps } from '@antv/g2plot' import { useForkRef } from '@consta/uikit/useForkRef' +import { useThemeVars } from '@consta/uikit/useThemeVars' import { useChart } from '@/__private__/hooks/useChart' +import { getChartTheme } from '@/__private__/hooks/useChartTheme' import { getChart } from '@/__private__/utils/getChart' import { ChartProps } from '@/__private__/utils/types/ChartProps' +import { withDefaultProps } from './helpers' + export type LiquidProps = Omit, 'color' | 'label'> type Liquid = (props: LiquidProps) => React.ReactElement | null @@ -20,7 +24,15 @@ export const Liquid: Liquid = React.forwardRef((props, ref) => { className, ...rest } = props - const { chart, container } = useChart(G2plotLiquid, rest) + + const themeVars = useThemeVars() + const theme = getChartTheme(themeVars) + const chartProps = withDefaultProps(rest, themeVars) + + const { chart, container } = useChart(G2plotLiquid, { + ...chartProps, + theme, + }) useEffect(() => { getChart(chartRef, chart.current) diff --git a/src/Liquid/__stories__/Liquid.stories.tsx b/src/Liquid/__stories__/Liquid.stories.tsx index 0442932..4123b55 100644 --- a/src/Liquid/__stories__/Liquid.stories.tsx +++ b/src/Liquid/__stories__/Liquid.stories.tsx @@ -5,15 +5,7 @@ import { createMetadata } from '@/__private__/storybook' import { Liquid } from '../Liquid' const Default = () => { - return ( - - ) + return } export function Playground() { diff --git a/src/Liquid/helpers.ts b/src/Liquid/helpers.ts new file mode 100644 index 0000000..13dff5b --- /dev/null +++ b/src/Liquid/helpers.ts @@ -0,0 +1,20 @@ +import { ThemeVars } from '@/__private__/utils/types/ThemeVars' + +import { LiquidProps } from './Liquid' + +export const withDefaultProps = (props: LiquidProps, vars: ThemeVars): LiquidProps => { + return { + ...props, + statistic: { + content: { + style: { + fontSize: vars.size['--size-text-3xl'], + lineHeight: vars.space['--space-3xl'], + fill: vars.color.primary['--color-typo-primary'], + }, + ...props.statistic?.content, + }, + ...props.statistic, + }, + } +} diff --git a/src/Pie/Pie.tsx b/src/Pie/Pie.tsx index 16d45fd..2503b47 100644 --- a/src/Pie/Pie.tsx +++ b/src/Pie/Pie.tsx @@ -4,6 +4,7 @@ import { Pie as G2plotPie, PieOptions as G2plotPieProps } from '@antv/g2plot' import { useForkRef } from '@consta/uikit/useForkRef' import { useChart } from '@/__private__/hooks/useChart' +import { useChartTheme } from '@/__private__/hooks/useChartTheme' import { getChart } from '@/__private__/utils/getChart' import { ChartProps } from '@/__private__/utils/types/ChartProps' @@ -21,7 +22,8 @@ export const Pie: Pie = React.forwardRef((props, ref) => { children, ...rest } = props - const { chart, container } = useChart(G2plotPie, rest) + const theme = useChartTheme() + const { chart, container } = useChart(G2plotPie, { ...rest, theme }) useEffect(() => { getChart(chartRef, chart.current) diff --git a/src/Pie/__stories__/Pie.stories.tsx b/src/Pie/__stories__/Pie.stories.tsx index 26ccf53..473fdee 100644 --- a/src/Pie/__stories__/Pie.stories.tsx +++ b/src/Pie/__stories__/Pie.stories.tsx @@ -29,6 +29,7 @@ const Default = () => { width: 800, height: '100%', }} + renderer="svg" {...options} /> ) diff --git a/src/Radar/Radar.tsx b/src/Radar/Radar.tsx index 6434596..875c023 100644 --- a/src/Radar/Radar.tsx +++ b/src/Radar/Radar.tsx @@ -4,6 +4,7 @@ import { Radar as G2plotRadar, RadarOptions as G2plotRadarProps } from '@antv/g2 import { useForkRef } from '@consta/uikit/useForkRef' import { useChart } from '@/__private__/hooks/useChart' +import { useChartTheme } from '@/__private__/hooks/useChartTheme' import { getChart } from '@/__private__/utils/getChart' import { ChartProps } from '@/__private__/utils/types/ChartProps' @@ -20,7 +21,8 @@ export const Radar: Radar = React.forwardRef((props, ref) => { className, ...rest } = props - const { chart, container } = useChart(G2plotRadar, rest) + const theme = useChartTheme() + const { chart, container } = useChart(G2plotRadar, { ...rest, theme }) useEffect(() => { getChart(chartRef, chart.current) diff --git a/src/Radar/__stories__/Radar.stories.tsx b/src/Radar/__stories__/Radar.stories.tsx index 1ed05ff..35c45b7 100644 --- a/src/Radar/__stories__/Radar.stories.tsx +++ b/src/Radar/__stories__/Radar.stories.tsx @@ -25,6 +25,7 @@ const Default = () => { width: 800, height: '100%', }} + renderer="svg" {...options} /> ) diff --git a/src/Scatter/Scatter.tsx b/src/Scatter/Scatter.tsx index bed0869..1dc324a 100644 --- a/src/Scatter/Scatter.tsx +++ b/src/Scatter/Scatter.tsx @@ -4,6 +4,7 @@ import { Scatter as G2plotScatter, ScatterOptions as G2plotScatterProps } from ' import { useForkRef } from '@consta/uikit/useForkRef' import { useChart } from '@/__private__/hooks/useChart' +import { useChartTheme } from '@/__private__/hooks/useChartTheme' import { getChart } from '@/__private__/utils/getChart' import { ChartProps } from '@/__private__/utils/types/ChartProps' @@ -20,7 +21,8 @@ export const Scatter: Scatter = React.forwardRef((props, ref) => { className, ...rest } = props - const { chart, container } = useChart(G2plotScatter, rest) + const theme = useChartTheme() + const { chart, container } = useChart(G2plotScatter, { ...rest, theme }) useEffect(() => { getChart(chartRef, chart.current) diff --git a/src/Scatter/__stories__/Scatter.stories.tsx b/src/Scatter/__stories__/Scatter.stories.tsx index 166d999..a123858 100644 --- a/src/Scatter/__stories__/Scatter.stories.tsx +++ b/src/Scatter/__stories__/Scatter.stories.tsx @@ -22,6 +22,7 @@ const Default = () => { width: 800, height: '100%', }} + renderer="svg" {...options} /> ) diff --git a/src/Waterfall/Waterfall.tsx b/src/Waterfall/Waterfall.tsx index 3623d2a..ff8b322 100644 --- a/src/Waterfall/Waterfall.tsx +++ b/src/Waterfall/Waterfall.tsx @@ -5,11 +5,15 @@ import { WaterfallOptions as G2plotWaterfallProps, } from '@antv/g2plot' import { useForkRef } from '@consta/uikit/useForkRef' +import { useThemeVars } from '@consta/uikit/useThemeVars' import { useChart } from '@/__private__/hooks/useChart' +import { getChartTheme } from '@/__private__/hooks/useChartTheme' import { getChart } from '@/__private__/utils/getChart' import { ChartProps } from '@/__private__/utils/types/ChartProps' +import { getDefaultProps } from './helpers' + export type WaterfallProps = Omit, 'color' | 'label'> type Waterfall = (props: WaterfallProps) => React.ReactElement | null @@ -23,7 +27,11 @@ export const Waterfall: Waterfall = React.forwardRef((props, ref) => { className, ...rest } = props - const { chart, container } = useChart(G2plotWaterfall, rest) + + const themeVars = useThemeVars() + const theme = getChartTheme(themeVars) + const chartProps = getDefaultProps(rest, themeVars) + const { chart, container } = useChart(G2plotWaterfall, { ...chartProps, theme }) useEffect(() => { getChart(chartRef, chart.current) diff --git a/src/Waterfall/__stories__/Waterfall.stories.tsx b/src/Waterfall/__stories__/Waterfall.stories.tsx index c69b6e9..f271401 100644 --- a/src/Waterfall/__stories__/Waterfall.stories.tsx +++ b/src/Waterfall/__stories__/Waterfall.stories.tsx @@ -18,6 +18,7 @@ const Default = () => { width: 800, height: '100%', }} + renderer="svg" {...options} /> ) diff --git a/src/Waterfall/helpers.ts b/src/Waterfall/helpers.ts new file mode 100644 index 0000000..549a30d --- /dev/null +++ b/src/Waterfall/helpers.ts @@ -0,0 +1,64 @@ +import { ThemeVars } from '@/__private__/utils/types/ThemeVars' + +import { WaterfallProps } from './Waterfall' + +export const getDefaultProps = (props: WaterfallProps, vars: ThemeVars): WaterfallProps => { + return { + ...props, + leaderLine: { + style: { + lineWidth: 1, + stroke: vars.color.primary['--color-bg-border'], + lineDash: [4, 2], + }, + ...props.leaderLine, + }, + total: { + label: 'total', + style: { + fill: vars.color.primary['--color-bg-normal'], + }, + ...props.total, + }, + risingFill: vars.color.primary['--color-bg-success'], + fallingFill: vars.color.primary['--color-bg-alert'], + legend: { + items: [ + { + name: 'increase', + value: 'increase', + marker: { + symbol: 'circle', + style: { + r: 5, + fill: vars.color.primary['--color-bg-success'], + }, + }, + }, + { + name: 'decrease', + value: 'decrease', + marker: { + symbol: 'circle', + style: { + r: 5, + fill: vars.color.primary['--color-bg-alert'], + }, + }, + }, + { + name: 'total', + value: 'total', + marker: { + symbol: 'circle', + style: { + r: 5, + fill: vars.color.primary['--color-bg-normal'], + }, + }, + }, + ], + ...props.legend, + }, + } +} diff --git a/src/__private__/hooks/useChartTheme.tsx b/src/__private__/hooks/useChartTheme.tsx new file mode 100644 index 0000000..faa4c0f --- /dev/null +++ b/src/__private__/hooks/useChartTheme.tsx @@ -0,0 +1,230 @@ +import { StyleSheet } from '@antv/g2/lib/interface' +import { createThemeByStyleSheet } from '@antv/g2/lib/theme/util/create-by-style-sheet' +import { useThemeVars } from '@consta/uikit/useThemeVars' + +import { ThemeVars } from '@/__private__/utils/types/ThemeVars' + +export const getChartTheme = (vars: ThemeVars) => { + const styleSheet: StyleSheet = { + backgroundColor: 'transparent', + brandColor: vars.color.primary['--color-typo-brand'], + paletteQualitative10: [ + vars.color.primary['--color-typo-brand'], + vars.color.primary['--color-typo-alert'], + vars.color.primary['--color-typo-success'], + vars.color.primary['--color-typo-warning'], + vars.color.primary['--color-typo-normal'], + vars.color.primary['--color-typo-brand'], + vars.color.primary['--color-typo-alert'], + vars.color.primary['--color-typo-success'], + vars.color.primary['--color-typo-warning'], + vars.color.primary['--color-typo-normal'], + ], + paletteQualitative20: [ + vars.color.primary['--color-typo-brand'], + vars.color.primary['--color-typo-alert'], + vars.color.primary['--color-typo-success'], + vars.color.primary['--color-typo-warning'], + vars.color.primary['--color-typo-normal'], + vars.color.primary['--color-typo-brand'], + vars.color.primary['--color-typo-alert'], + vars.color.primary['--color-typo-success'], + vars.color.primary['--color-typo-warning'], + vars.color.primary['--color-typo-normal'], + vars.color.primary['--color-typo-brand'], + vars.color.primary['--color-typo-alert'], + vars.color.primary['--color-typo-success'], + vars.color.primary['--color-typo-warning'], + vars.color.primary['--color-typo-normal'], + vars.color.primary['--color-typo-brand'], + vars.color.primary['--color-typo-alert'], + vars.color.primary['--color-typo-success'], + vars.color.primary['--color-typo-warning'], + vars.color.primary['--color-typo-normal'], + ], + paletteSemanticRed: vars.color.primary['--color-typo-alert'], + paletteSemanticGreen: vars.color.primary['--color-typo-success'], + paletteSemanticYellow: vars.color.primary['--color-typo-warning'], + fontFamily: vars.font['--font-primary'], + axisLineBorderColor: vars.color.primary['--color-bg-system'], + axisLineBorder: 1, + axisLineDash: [], + axisTitleTextFillColor: '#ff00d0', + axisTitleTextFontSize: 12, + axisTitleTextLineHeight: 12, + axisTitleTextFontWeight: 'normal', + axisTitleSpacing: 12, + axisTickLineBorderColor: vars.color.primary['--color-bg-system'], + axisTickLineLength: 4, + axisTickLineBorder: 1, + axisSubTickLineBorderColor: vars.color.primary['--color-bg-system'], + axisSubTickLineLength: 2, + axisSubTickLineBorder: 1, + axisLabelFillColor: vars.color.primary['--color-typo-secondary'], + axisLabelFontSize: 12, + axisLabelLineHeight: 12, + axisLabelFontWeight: 'normal', + axisLabelOffset: 8, + axisGridBorderColor: vars.color.primary['--color-bg-system'], + axisGridBorder: 1, + axisGridLineDash: [], + legendTitleTextFillColor: vars.color.primary['--color-typo-secondary'], + legendTitleTextFontSize: 12, + legendTitleTextLineHeight: 21, + legendTitleTextFontWeight: 'normal', + legendMarkerColor: vars.color.primary['--color-typo-brand'], + legendMarkerSpacing: 8, + legendMarkerSize: 4, + legendCircleMarkerSize: 4, + legendSquareMarkerSize: 4, + legendLineMarkerSize: 5, + legendItemNameFillColor: vars.color.primary['--color-typo-primary'], + legendItemNameFontSize: 12, + legendItemNameLineHeight: 12, + legendItemNameFontWeight: 'normal', + legendItemSpacing: 24, + legendItemMarginBottom: 12, + legendPadding: [8, 8, 8, 8], + legendHorizontalPadding: [8, 0, 8, 0], + legendVerticalPadding: [0, 8, 0, 8], + legendPageNavigatorMarkerSize: 12, + legendPageNavigatorMarkerInactiveFillColor: vars.color.primary['--color-typo-primary'], + legendPageNavigatorMarkerInactiveFillOpacity: 0.45, + legendPageNavigatorMarkerFillColor: vars.color.primary['--color-typo-primary'], + legendPageNavigatorMarkerFillOpacity: 1, + legendPageNavigatorTextFillColor: vars.color.primary['--color-typo-secondary'], + legendPageNavigatorTextFontSize: 12, + sliderRailFillColor: vars.color.primary['--color-bg-system'], + sliderRailBorder: 0, + sliderRailBorderColor: 'transparent', + sliderRailWidth: 100, + sliderRailHeight: 12, + sliderLabelTextFillColor: vars.color.primary['--color-typo-secondary'], + sliderLabelTextFontSize: 12, + sliderLabelTextLineHeight: 12, + sliderLabelTextFontWeight: 'normal', + sliderHandlerFillColor: vars.color.primary['--color-scroll-bg'], + sliderHandlerWidth: 10, + sliderHandlerHeight: 14, + sliderHandlerBorder: 1, + sliderHandlerBorderColor: vars.color.primary['--color-bg-system'], + annotationArcBorderColor: vars.color.primary['--color-bg-system'], + annotationArcBorder: 1, + annotationLineBorderColor: vars.color.primary['--color-bg-system'], + annotationLineBorder: 1, + annotationLineDash: [], + annotationTextFillColor: vars.color.primary['--color-typo-primary'], + annotationTextFontSize: 12, + annotationTextLineHeight: 12, + annotationTextFontWeight: 'normal', + annotationTextBorderColor: 'transparent', + annotationTextBorder: 0, + annotationRegionFillColor: vars.color.primary['--color-typo-primary'], + annotationRegionFillOpacity: 0.06, + annotationRegionBorder: 0, + annotationRegionBorderColor: 'transparent', + annotationDataMarkerLineLength: 16, + tooltipCrosshairsBorderColor: vars.color.primary['--color-bg-border'], + tooltipCrosshairsBorder: 1, + tooltipCrosshairsLineDash: [], + tooltipContainerFillColor: vars.color.invert['--color-bg-default'], + tooltipContainerFillOpacity: 1, + // тень + tooltipContainerShadow: '0px 0px 10px #aeaeae', + tooltipContainerBorderRadius: 3, + tooltipTextFillColor: vars.color.invert['--color-typo-primary'], + tooltipTextFontSize: 12, + tooltipTextLineHeight: 12, + tooltipTextFontWeight: 'bold', + labelFillColor: vars.color.primary['--color-typo-primary'], + labelFillColorDark: vars.color.primary['--color-typo-primary'], + labelFillColorLight: vars.color.primary['--color-typo-primary'], + labelFontSize: 12, + labelLineHeight: 12, + labelFontWeight: 'normal', + labelBorderColor: 'transparent', + labelBorder: 0, + innerLabelFillColor: vars.color.primary['--color-bg-default'], + innerLabelFontSize: 12, + innerLabelLineHeight: 12, + innerLabelFontWeight: 'normal', + innerLabelBorderColor: 'transparent', + innerLabelBorder: 0, + overflowLabelFillColor: '#ff00d0', + overflowLabelFontSize: 12, + overflowLabelLineHeight: 12, + overflowLabelFontWeight: 'normal', + overflowLabelBorderColor: '#ff00d0', + overflowLabelBorder: 1, + labelLineBorder: 1, + labelLineBorderColor: vars.color.primary['--color-bg-system'], + pointFillColor: vars.color.primary['--color-typo-brand'], + pointFillOpacity: 0.95, + pointSize: 4, + pointBorder: 1, + pointBorderColor: '#ff00d0', + pointBorderOpacity: 1, + pointActiveBorderColor: vars.color.primary['--color-typo-primary'], + pointSelectedBorder: 2, + pointSelectedBorderColor: vars.color.primary['--color-typo-primary'], + pointInactiveFillOpacity: 0.3, + pointInactiveBorderOpacity: 0.3, + hollowPointSize: 4, + hollowPointBorder: 1, + hollowPointBorderColor: vars.color.primary['--color-typo-brand'], + hollowPointBorderOpacity: 0.95, + hollowPointFillColor: '#ff00d0', + hollowPointActiveBorder: 1, + hollowPointActiveBorderColor: vars.color.primary['--color-typo-primary'], + hollowPointActiveBorderOpacity: 1, + hollowPointSelectedBorder: 2, + hollowPointSelectedBorderColor: vars.color.primary['--color-typo-primary'], + hollowPointSelectedBorderOpacity: 1, + hollowPointInactiveBorderOpacity: 0.3, + lineBorder: 2, + lineBorderColor: vars.color.primary['--color-typo-brand'], + lineBorderOpacity: 1, + lineActiveBorder: 3, + lineSelectedBorder: 3, + lineInactiveBorderOpacity: 0.3, + areaFillColor: vars.color.primary['--color-typo-brand'], + areaFillOpacity: 0.25, + areaActiveFillColor: vars.color.primary['--color-typo-brand'], + areaActiveFillOpacity: 0.5, + areaSelectedFillColor: vars.color.primary['--color-typo-brand'], + areaSelectedFillOpacity: 0.5, + areaInactiveFillOpacity: 0.3, + hollowAreaBorderColor: vars.color.primary['--color-typo-brand'], + hollowAreaBorder: 2, + hollowAreaBorderOpacity: 1, + hollowAreaActiveBorder: 3, + hollowAreaActiveBorderColor: vars.color.primary['--color-typo-primary'], + hollowAreaSelectedBorder: 3, + hollowAreaSelectedBorderColor: vars.color.primary['--color-typo-primary'], + hollowAreaInactiveBorderOpacity: 0.3, + intervalFillColor: vars.color.primary['--color-typo-brand'], + intervalFillOpacity: 0.95, + intervalActiveBorder: 1, + intervalActiveBorderColor: vars.color.primary['--color-typo-primary'], + intervalActiveBorderOpacity: 1, + intervalSelectedBorder: 2, + intervalSelectedBorderColor: vars.color.primary['--color-typo-primary'], + intervalSelectedBorderOpacity: 1, + intervalInactiveBorderOpacity: 0.3, + intervalInactiveFillOpacity: 0.3, + hollowIntervalBorder: 2, + hollowIntervalBorderColor: vars.color.primary['--color-typo-brand'], + hollowIntervalBorderOpacity: 1, + hollowIntervalFillColor: '#ff00d0', + hollowIntervalActiveBorder: 2, + hollowIntervalActiveBorderColor: vars.color.primary['--color-typo-primary'], + hollowIntervalSelectedBorder: 3, + hollowIntervalSelectedBorderColor: vars.color.primary['--color-typo-primary'], + hollowIntervalSelectedBorderOpacity: 1, + hollowIntervalInactiveBorderOpacity: 0.3, + } + + return createThemeByStyleSheet(styleSheet) +} + +export const useChartTheme = () => getChartTheme(useThemeVars()) diff --git a/src/__private__/utils/types/ChartProps.ts b/src/__private__/utils/types/ChartProps.ts index 392d9fd..1ae6eec 100644 --- a/src/__private__/utils/types/ChartProps.ts +++ b/src/__private__/utils/types/ChartProps.ts @@ -1,7 +1,8 @@ import { ContainerProps, Tooltip } from '../../hooks/useChart' import { ChartRefOptions } from './ChartRefOptions' -export type ChartProps = Omit & { +export type ChartProps = Omit & { tooltip?: Tooltip + theme?: never } & ContainerProps & React.RefAttributes & { chartRef?: ChartRefOptions } diff --git a/src/__private__/utils/types/ThemeVars.ts b/src/__private__/utils/types/ThemeVars.ts new file mode 100644 index 0000000..014b86b --- /dev/null +++ b/src/__private__/utils/types/ThemeVars.ts @@ -0,0 +1,259 @@ +export type VarsDefault = { + readonly color: { + readonly primary: readonly [ + '--color-bg-default', + '--color-bg-secondary', + '--color-bg-brand', + '--color-bg-link', + '--color-bg-border', + '--color-bg-stripe', + '--color-bg-ghost', + '--color-bg-tone', + '--color-bg-soft', + '--color-bg-system', + '--color-bg-normal', + '--color-bg-success', + '--color-bg-caution', + '--color-bg-warning', + '--color-bg-alert', + '--color-bg-critical', + '--color-typo-primary', + '--color-typo-secondary', + '--color-typo-ghost', + '--color-typo-brand', + '--color-typo-system', + '--color-typo-normal', + '--color-typo-success', + '--color-typo-caution', + '--color-typo-warning', + '--color-typo-alert', + '--color-typo-critical', + '--color-typo-link', + '--color-typo-link-minor', + '--color-typo-link-hover', + '--color-nums-shadow', + '--color-scroll-bg', + '--color-scroll-thumb', + '--color-scroll-thumb-hover', + '--color-control-bg-default', + '--color-control-typo-default', + '--color-control-typo-placeholder', + '--color-control-bg-border-default', + '--color-control-bg-border-default-hover', + '--color-control-bg-border-focus', + '--color-control-bg-focus', + '--color-control-bg-active', + '--color-control-bg-primary', + '--color-control-bg-primary-hover', + '--color-control-typo-primary', + '--color-control-typo-primary-hover', + '--color-control-bg-secondary', + '--color-control-bg-border-secondary', + '--color-control-bg-border-secondary-hover:', + '--color-control-typo-secondary', + '--color-control-typo-secondary-hover', + '--color-control-bg-ghost', + '--color-control-bg-ghost-hover', + '--color-control-typo-ghost', + '--color-control-typo-ghost-hover', + '--color-control-bg-clear', + '--color-control-bg-clear-hover', + '--color-control-typo-clear', + '--color-control-typo-clear-hover', + '--color-control-bg-disable', + '--color-control-bg-border-disable', + '--color-control-typo-disable' + ] + readonly accent: readonly [ + '--color-bg-default', + '--color-bg-secondary', + '--color-bg-brand', + '--color-bg-link', + '--color-bg-border', + '--color-bg-stripe', + '--color-bg-ghost', + '--color-bg-tone', + '--color-bg-soft', + '--color-bg-system', + '--color-bg-normal', + '--color-bg-success', + '--color-bg-caution', + '--color-bg-warning', + '--color-bg-alert', + '--color-bg-critical', + '--color-typo-primary', + '--color-typo-secondary', + '--color-typo-ghost', + '--color-typo-brand', + '--color-typo-system', + '--color-typo-normal', + '--color-typo-success', + '--color-typo-caution', + '--color-typo-warning', + '--color-typo-alert', + '--color-typo-critical', + '--color-typo-link', + '--color-typo-link-minor', + '--color-typo-link-hover', + '--color-nums-shadow', + '--color-scroll-bg', + '--color-scroll-thumb', + '--color-scroll-thumb-hover', + '--color-control-bg-default', + '--color-control-typo-default', + '--color-control-typo-placeholder', + '--color-control-bg-border-default', + '--color-control-bg-border-default-hover', + '--color-control-bg-border-focus', + '--color-control-bg-focus', + '--color-control-bg-active', + '--color-control-bg-primary', + '--color-control-bg-primary-hover', + '--color-control-typo-primary', + '--color-control-typo-primary-hover', + '--color-control-bg-secondary', + '--color-control-bg-border-secondary', + '--color-control-bg-border-secondary-hover:', + '--color-control-typo-secondary', + '--color-control-typo-secondary-hover', + '--color-control-bg-ghost', + '--color-control-bg-ghost-hover', + '--color-control-typo-ghost', + '--color-control-typo-ghost-hover', + '--color-control-bg-clear', + '--color-control-bg-clear-hover', + '--color-control-typo-clear', + '--color-control-typo-clear-hover', + '--color-control-bg-disable', + '--color-control-bg-border-disable', + '--color-control-typo-disable' + ] + readonly invert: readonly [ + '--color-bg-default', + '--color-bg-secondary', + '--color-bg-brand', + '--color-bg-link', + '--color-bg-border', + '--color-bg-stripe', + '--color-bg-ghost', + '--color-bg-tone', + '--color-bg-soft', + '--color-bg-system', + '--color-bg-normal', + '--color-bg-success', + '--color-bg-caution', + '--color-bg-warning', + '--color-bg-alert', + '--color-bg-critical', + '--color-typo-primary', + '--color-typo-secondary', + '--color-typo-ghost', + '--color-typo-brand', + '--color-typo-system', + '--color-typo-normal', + '--color-typo-success', + '--color-typo-caution', + '--color-typo-warning', + '--color-typo-alert', + '--color-typo-critical', + '--color-typo-link', + '--color-typo-link-minor', + '--color-typo-link-hover', + '--color-nums-shadow', + '--color-scroll-bg', + '--color-scroll-thumb', + '--color-scroll-thumb-hover', + '--color-control-bg-default', + '--color-control-typo-default', + '--color-control-typo-placeholder', + '--color-control-bg-border-default', + '--color-control-bg-border-default-hover', + '--color-control-bg-border-focus', + '--color-control-bg-focus', + '--color-control-bg-active', + '--color-control-bg-primary', + '--color-control-bg-primary-hover', + '--color-control-typo-primary', + '--color-control-typo-primary-hover', + '--color-control-bg-secondary', + '--color-control-bg-border-secondary', + '--color-control-bg-border-secondary-hover:', + '--color-control-typo-secondary', + '--color-control-typo-secondary-hover', + '--color-control-bg-ghost', + '--color-control-bg-ghost-hover', + '--color-control-typo-ghost', + '--color-control-typo-ghost-hover', + '--color-control-bg-clear', + '--color-control-bg-clear-hover', + '--color-control-typo-clear', + '--color-control-typo-clear-hover', + '--color-control-bg-disable', + '--color-control-bg-border-disable', + '--color-control-typo-disable' + ] + } + readonly control: readonly [ + '--control-radius', + '--control-border-width', + '--control-height-l', + '--control-height-m', + '--control-height-s', + '--control-height-xs', + '--control-box-size-m', + '--control-box-size-l', + '--control-space-l', + '--control-space-m', + '--control-space-s', + '--control-space-xs', + '--control-text-size-l', + '--control-text-size-m', + '--control-text-size-s', + '--control-text-size-xs' + ] + readonly font: readonly ['--font-primary', '--font-mono'] + readonly size: readonly [ + '--size-text-2xs', + '--size-text-xs', + '--size-text-s', + '--size-text-m', + '--size-text-l', + '--size-text-xl', + '--size-text-2xl', + '--size-text-3xl', + '--size-text-4xl', + '--size-text-5xl', + '--size-text-6xl', + '--line-height-text-2xs', + '--line-height-text-xs', + '--line-height-text-s', + '--line-height-text-m', + '--line-height-text-l' + ] + readonly space: readonly [ + '--space-3xs', + '--space-2xs', + '--space-xs', + '--space-s', + '--space-m', + '--space-l', + '--space-xl', + '--space-2xl', + '--space-3xl', + '--space-4xl', + '--space-5xl', + '--space-6xl' + ] +} + +export type ThemeVars = { + color: { + primary: { [key in VarsDefault['color']['primary'][number]]: string } + accent: { [key in VarsDefault['color']['accent'][number]]: string } + invert: { [key in VarsDefault['color']['invert'][number]]: string } + } + control: { [key in VarsDefault['control'][number]]: string } + font: { [key in VarsDefault['font'][number]]: string } + size: { [key in VarsDefault['size'][number]]: string } + space: { [key in VarsDefault['space'][number]]: string } +}