Skip to content

Commit 78b105f

Browse files
add mock & fix drawing issue
issue : check if fgcolor is an array
1 parent afa0cd6 commit 78b105f

File tree

3 files changed

+37
-0
lines changed

3 files changed

+37
-0
lines changed

src/components/drawing/index.js

+1
Original file line numberDiff line numberDiff line change
@@ -755,6 +755,7 @@ drawing.singlePointStyle = function(d, sel, trace, fns, gd, pt) {
755755
var perPointPattern = d.mcc ||
756756
Lib.isArrayOrTypedArray(markerPattern.shape) ||
757757
Lib.isArrayOrTypedArray(markerPattern.bgcolor) ||
758+
Lib.isArrayOrTypedArray(markerPattern.fgcolor) ||
758759
Lib.isArrayOrTypedArray(markerPattern.size) ||
759760
Lib.isArrayOrTypedArray(markerPattern.solidity);
760761

35.5 KB
Loading
+36
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,36 @@
1+
{
2+
"data": [
3+
{
4+
"type": "sunburst",
5+
"textinfo": "label",
6+
"labels": ["Cain", "Seth", "Enos", "Noam", "Abel", "Awan", "Enoch", "Azura"],
7+
"parents": ["Eve", "Eve", "Seth", "Seth", "Eve", "Eve", "Awan", "Eve" ],
8+
"domain": {"x": [0, 0.5]},
9+
"marker": {
10+
"colors": [ "orange", "steelblue", "steelblue", "steelblue", "green", "red", "red", "purple"]
11+
}
12+
},
13+
{
14+
"type": "sunburst",
15+
"textinfo": "none",
16+
"labels": ["Cain", "Seth", "Enos", "Noam", "Abel", "Awan", "Enoch", "Azura"],
17+
"parents": ["Eve", "Eve", "Seth", "Seth", "Eve", "Eve", "Awan", "Eve" ],
18+
"domain": {"x": [0.5, 1]},
19+
"marker": {
20+
"colors": [ "orange", "steelblue", "lightgrey", "lightgrey", "green", "red", "lightgrey", "purple"],
21+
"pattern": {
22+
"shape": ".",
23+
"size": 4
24+
},
25+
"line": {
26+
"color": "lightgrey"
27+
}
28+
}
29+
}
30+
],
31+
"layout": {
32+
"title": { "text": "sunburst with pattern"},
33+
"width": 800,
34+
"height": 400
35+
}
36+
}

0 commit comments

Comments
 (0)