Project

General

Profile

« Previous | Next » 

Revision 60835

Refactored to add a variable in all stats tool queries for the profile name used. Also, added a change in the color palette for the main entities

View differences:

europe-map-overview.component.ts
10 10
import { DataHandlerService } from '../../services/data-handler.service';
11 11

  
12 12
import * as echarts from 'echarts';
13
import {
14
  datasetColor, datasetBackgroundColor,
15
  datasetTooltipColor, journalsColor, journalsTooltipColor, journalsBackgroundColor, policiesColor, policiesTooltipColor,
16
  publicationColor, publicationBackgroundColor,
17
  publicationTooltipColor,
18
  repositoriesColor, repositoriesBackgroundColor,
19
  repositoriesTooltipColor,
20
} from '../../chart-palettes';
13 21

  
14 22
declare var require: any;
15 23

  
......
27 35
  @Output() emitSelectedCountry: EventEmitter<any> = new EventEmitter();
28 36

  
29 37
  activeView: string = 'publications';
30
  seriesColor: string = '#F17AA9';
38
  seriesColor: string = publicationColor;
31 39
  seriesName: string = 'OA publications';
32 40

  
33 41
  // tooltipBackgroundColor: string = '#EC4386';
34
  tooltipBackgroundColor: string = '#a52e5d';
42
  tooltipBackgroundColor: string = publicationTooltipColor;
35 43
  tooltipBorderColor: string = '#000';
36 44

  
37 45
  options = {};
......
80 88
    this.activeView = view;
81 89

  
82 90
    if (this.activeView === 'publications') {
83
      this.seriesColor = '#F17AA9';
91
      this.seriesColor = publicationColor;
84 92
      this.seriesName = 'OA publications';
85
      this.tooltipBackgroundColor = '#a52e5d';
93
      this.tooltipBackgroundColor = publicationTooltipColor;
86 94
      this.tooltipBorderColor = '#000';
87 95
    } else if (this.activeView === 'datasets') {
88
      this.seriesColor = '#A98BD4';
96
      this.seriesColor = datasetColor;
89 97
      this.seriesName = 'OA datasets';
90
      this.tooltipBackgroundColor = '#7658a1';
98
      this.tooltipBackgroundColor = datasetTooltipColor;
91 99
      this.tooltipBorderColor = '#000';
92 100
    } else if (this.activeView === 'repositories') {
93
      this.seriesColor = '#708AA5';
101
      this.seriesColor = repositoriesColor;
94 102
      this.seriesName = 'OA repositories';
95
      this.tooltipBackgroundColor = '#3d5772';
103
      this.tooltipBackgroundColor = repositoriesTooltipColor;
96 104
      this.tooltipBorderColor = '#000';
97 105
    } else if (this.activeView === 'journals') {
98
      this.seriesColor = '#FFCE4E';
106
      this.seriesColor = journalsColor;
99 107
      this.seriesName = 'OA journals';
100
      this.tooltipBackgroundColor = '#cc9b1b';
108
      this.tooltipBackgroundColor = journalsTooltipColor;
101 109
      this.tooltipBorderColor = '#000';
102 110
    } else {
103
      this.seriesColor = '#639C66';
111
      this.seriesColor = policiesColor;
104 112
      this.seriesName = 'OA policies';
105
      this.tooltipBackgroundColor = '#306933';
113
      this.tooltipBackgroundColor = policiesTooltipColor;
106 114
      this.tooltipBorderColor = '#000';
107 115
    }
108 116
    this.loadMap(this.overviewMapData[view], this.seriesColor, this.seriesName);

Also available in: Unified diff