@decidables/accumulable-elements 0.2.0 → 0.3.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@decidables/accumulable-elements",
3
- "version": "0.2.0",
3
+ "version": "0.3.0",
4
4
  "description": "accumulable-elements: Web Components for visualizing the Diffusion Decision Model",
5
5
  "keywords": [
6
6
  "web component",
@@ -50,17 +50,17 @@
50
50
  "build": "gulp build"
51
51
  },
52
52
  "devDependencies": {
53
- "gulp": "^5.0.0"
53
+ "gulp": "^5.0.1"
54
54
  },
55
55
  "dependencies": {
56
- "@decidables/accumulable-math": "^0.2.0",
57
- "@decidables/decidables-elements": "^0.5.0",
58
- "@lit-labs/motion": "^1.0.7",
59
- "@observablehq/plot": "^0.6.16",
56
+ "@decidables/accumulable-math": "^0.2.1",
57
+ "@decidables/decidables-elements": "^0.5.1",
58
+ "@lit-labs/motion": "^1.0.9",
59
+ "@observablehq/plot": "^0.6.17",
60
60
  "bayes.js": "https://github.com/akrawitz/bayes.js.git#commit=c7b091b75f85a86b6a3965a983b31e23d9ef456f",
61
61
  "d3": "^7.9.0",
62
- "lit": "^3.2.1",
62
+ "lit": "^3.3.1",
63
63
  "regenerator-runtime": "^0.14.1"
64
64
  },
65
- "gitHead": "0320347d03a20fb478784fe296c82f11018c276b"
65
+ "gitHead": "8298ec307d6a0cb19c4953fd503956c428236695"
66
66
  }
@@ -7,6 +7,8 @@ import * as d3 from 'd3';
7
7
 
8
8
  import {DecidablesElement} from '@decidables/decidables-elements';
9
9
 
10
+ import {colors} from './colors.yml';
11
+
10
12
  /*
11
13
  AccumulableElement Base Class - Not intended for instantiation!
12
14
  */
@@ -27,18 +29,7 @@ export default class AccumulableElement extends DecidablesElement {
27
29
  }
28
30
 
29
31
  static get colors() {
30
- return {
31
- a: d3.schemeSet1[0],
32
- z: d3.schemeSet1[1],
33
- v: d3.schemeSet1[4],
34
- t0: d3.schemeSet1[7],
35
- s: d3.schemeSet1[8],
36
- left: '#f032e6',
37
- right: '#10dbc9',
38
- correct: d3.schemeSet1[2],
39
- error: d3.schemeSet1[3],
40
- nr: '#cccccc',
41
- };
32
+ return colors;
42
33
  }
43
34
 
44
35
  static get lights() {
package/src/colors.yml ADDED
@@ -0,0 +1,20 @@
1
+ # Custom Colors
2
+ # http://colorbrewer2.org/#type=qualitative&scheme=Set1&n=9
3
+ colors:
4
+ a: '#e41a1c' # red (CB1)
5
+ z: '#377eb8' # blue (CB2)
6
+ v: '#ff7f00' # orange (CB5)
7
+ t0: '#f781bf' # pink (CB8)
8
+ s: '#999999' # gray (CB9)
9
+
10
+ left: '#f032e6' # magenta
11
+ right: '#10dbc9' # cyan
12
+
13
+ correct: '#4daf4a' # green (CB3)
14
+ error: '#984ea3' # purple (CB4)
15
+
16
+ nr: '#cccccc' # grey-light50
17
+
18
+ # '#ffff33' # yellow (CB6)
19
+ # '#a65628' # brown (CB7)
20
+ # '#4545d0' # violet