Commit 5d941ca9 authored by Sascha Herzinger's avatar Sascha Herzinger
Browse files

minor visual improvements

parent 5bea303f
...@@ -9,7 +9,7 @@ export default class extends Chart { ...@@ -9,7 +9,7 @@ export default class extends Chart {
constructor({ container }) { constructor({ container }) {
super({ container }); super({ container });
this.memory = d3.select(document.createElement('memory')) this.memory = d3.select(document.createElement('memory'));
this.hiddenCanvas = document.createElement('canvas'); this.hiddenCanvas = document.createElement('canvas');
this.svg = d3.select(container) this.svg = d3.select(container)
.append('svg') .append('svg')
...@@ -101,8 +101,8 @@ export default class extends Chart { ...@@ -101,8 +101,8 @@ export default class extends Chart {
const margin = { const margin = {
top: 30, top: 30,
right: 20, right: 20,
bottom: this.containerWidth / 20, bottom: this.containerWidth / 15,
left: this.containerWidth / 20, left: this.containerWidth / 15,
}; };
const width = this.containerWidth - margin.left - margin.right; const width = this.containerWidth - margin.left - margin.right;
...@@ -229,7 +229,7 @@ export default class extends Chart { ...@@ -229,7 +229,7 @@ export default class extends Chart {
.delay((_, i) => i * (ANIMATION_DURATION / this.values.length)) .delay((_, i) => i * (ANIMATION_DURATION / this.values.length))
.attr('dx', d => x(d[0])) .attr('dx', d => x(d[0]))
.attr('dy', d => y(d[1])) .attr('dy', d => y(d[1]))
.style('opacity', d => ((typeof _selectedCategory !== 'undefined' && d[2] !== _selectedCategory) ? 0.3 : 1)) .style('opacity', d => ((typeof _selectedCategory !== 'undefined' && d[2] !== _selectedCategory) ? 0.2 : 1))
.attr('r', Math.ceil(width / 150)) .attr('r', Math.ceil(width / 150))
.attr('fillStyle', d => color(d[2])) .attr('fillStyle', d => color(d[2]))
.attr('title', d => ` .attr('title', d => `
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment