Skip to content

Commit 0a5093f

Browse files
committed
Add image test and generated baseline for multi-axis shapes
1 parent 777cded commit 0a5093f

2 files changed

Lines changed: 60 additions & 0 deletions

File tree

41.2 KB
Loading
Lines changed: 60 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,60 @@
1+
{
2+
"data": [
3+
{ "x": [1, 2, 3], "y": [1, 2, 1], "xaxis": "x", "yaxis": "y", "mode": "markers" },
4+
{ "x": [1, 2, 3], "y": [2, 1, 2], "xaxis": "x2", "yaxis": "y2", "mode": "markers" },
5+
{ "x": [1, 2, 3], "y": [1, 3, 2], "xaxis": "x3", "yaxis": "y3", "mode": "markers" },
6+
{ "x": [1, 2, 3], "y": [3, 2, 1], "xaxis": "x4", "yaxis": "y4", "mode": "markers" }
7+
],
8+
"layout": {
9+
"title": { "text": "Multi-Axis Shapes (with clipping & autorange)" },
10+
"width": 600,
11+
"height": 600,
12+
"showlegend": false,
13+
"grid": { "rows": 2, "columns": 2, "pattern": "independent" },
14+
"xaxis": { "range": [0, 4] },
15+
"yaxis": { "range": [0, 4] },
16+
"yaxis2": { "range": [0, 4] },
17+
"shapes": [
18+
{
19+
"type": "rect",
20+
"xref": ["x", "x2"],
21+
"yref": ["y", "y2"],
22+
"x0": 3,
23+
"x1": 1,
24+
"y0": 5,
25+
"y1": 2,
26+
"fillcolor": "rgba(255, 0, 0, 0.3)",
27+
"line": { "color": "red", "width": 2 }
28+
},
29+
{
30+
"type": "circle",
31+
"xref": ["x3", "x4"],
32+
"yref": ["y3", "y4"],
33+
"x0": 0,
34+
"x1": 5,
35+
"y0": 0,
36+
"y1": 5,
37+
"fillcolor": "rgba(0, 0, 255, 0.3)",
38+
"line": { "color": "blue", "width": 2 }
39+
},
40+
{
41+
"type": "line",
42+
"xref": ["x", "x3"],
43+
"yref": ["y", "y3"],
44+
"x0": 0.5,
45+
"x1": 4,
46+
"y0": 0.5,
47+
"y1": 4,
48+
"line": { "color": "green", "width": 3 }
49+
},
50+
{
51+
"type": "path",
52+
"xref": ["x2", "x2", "x4", "x4"],
53+
"yref": ["y2", "y2", "y4", "y4"],
54+
"path": "M0.5,0.5 L5,0.5 L4,4 L0.5,4 Z",
55+
"fillcolor": "rgba(255, 165, 0, 0.3)",
56+
"line": { "color": "orange", "width": 2 }
57+
}
58+
]
59+
}
60+
}

0 commit comments

Comments
 (0)