Skip to content

Commit

Permalink
fix #3661; series-title in multi-series treemap
Browse files Browse the repository at this point in the history
  • Loading branch information
junedchhipa committed Jan 1, 2025
1 parent 0f3a4d7 commit 873e75f
Show file tree
Hide file tree
Showing 7 changed files with 408 additions and 156 deletions.
93 changes: 66 additions & 27 deletions samples/react/treemap/multi-dimensional.html
Original file line number Diff line number Diff line change
Expand Up @@ -74,60 +74,99 @@
name: 'Desktops',
data: [
{
x: 'ABC',
y: 10
x: 'Apple',
y: 50,
},
{
x: 'DEF',
y: 60
x: 'Acer',
y: 30,
},
{
x: 'XYZ',
y: 41
}
]
x: 'Asus',
y: 21,
},
],
},
{
name: 'Mobile',
name: 'Laptops',
data: [
{
x: 'ABCD',
y: 10
x: 'Dell',
y: 21,
},
{
x: 'DEFG',
y: 20
x: 'HP',
y: 16,
},
{
x: 'WXYZ',
y: 51
x: 'Lenovo',
y: 20,
},
],
},
{
name: 'Tablets',
data: [
{
x: 'PQR',
y: 30
x: 'Samsung',
y: 4,
},
{
x: 'MNO',
y: 20
x: 'Huawei',
y: 7,
},
{
x: 'CDE',
y: 30
}
]
}
x: 'Microsoft',
y: 11,
},
{
x: 'Amazon',
y: 31,
},
{
x: 'Lenovo',
y: 13,
},
],
},
{
name: 'Mobile',
data: [
{
x: 'Apple',
y: 10,
},
{
x: 'Samsung',
y: 20,
},
{
x: 'Huawei',
y: 51,
},
{
x: 'Xiaomi',
y: 30,
},
],
},
],
options: {
legend: {
show: false
show: true,
offsetY: 10,
height: 30,
},
chart: {
height: 350,
type: 'treemap'
type: 'treemap',
},
title: {
text: 'Multi-dimensional Treemap',
align: 'center'
align: 'center',
},
plotOptions: {
treemap: {},
}
},

Expand Down
95 changes: 67 additions & 28 deletions samples/source/treemap/multi-dimensional.xml
Original file line number Diff line number Diff line change
Expand Up @@ -11,15 +11,20 @@
<chart>
<options>
legend: {
show: false
show: true,
offsetY: 10,
height: 30,
},
chart: {
height: 350,
type: 'treemap'
type: 'treemap',
},
title: {
text: 'Multi-dimensional Treemap',
align: 'center'
align: 'center',
},
plotOptions: {
treemap: {},
}
</options>

Expand All @@ -29,48 +34,82 @@ title: {
name: 'Desktops',
data: [
{
x: 'ABC',
y: 10
x: 'Apple',
y: 50,
},
{
x: 'DEF',
y: 60
x: 'Acer',
y: 30,
},
{
x: 'XYZ',
y: 41
}
]
x: 'Asus',
y: 21,
},
],
},
{
name: 'Mobile',
name: 'Laptops',
data: [
{
x: 'Dell',
y: 21,
},
{
x: 'HP',
y: 16,
},
{
x: 'Lenovo',
y: 20,
},
],
},
{
name: 'Tablets',
data: [
{
x: 'ABCD',
y: 10
x: 'Samsung',
y: 4,
},
{
x: 'DEFG',
y: 20
x: 'Huawei',
y: 7,
},
{
x: 'WXYZ',
y: 51
x: 'Microsoft',
y: 11,
},
{
x: 'PQR',
y: 30
x: 'Amazon',
y: 31,
},
{
x: 'MNO',
y: 20
x: 'Lenovo',
y: 13,
},
],
},
{
name: 'Mobile',
data: [
{
x: 'Apple',
y: 10,
},
{
x: 'CDE',
y: 30
}
]
}
]
x: 'Samsung',
y: 20,
},
{
x: 'Huawei',
y: 51,
},
{
x: 'Xiaomi',
y: 30,
},
],
},
]
</series>
</chart>
93 changes: 66 additions & 27 deletions samples/vanilla-js/treemap/multi-dimensional.html
Original file line number Diff line number Diff line change
Expand Up @@ -61,59 +61,98 @@
name: 'Desktops',
data: [
{
x: 'ABC',
y: 10
x: 'Apple',
y: 50,
},
{
x: 'DEF',
y: 60
x: 'Acer',
y: 30,
},
{
x: 'XYZ',
y: 41
}
]
x: 'Asus',
y: 21,
},
],
},
{
name: 'Mobile',
name: 'Laptops',
data: [
{
x: 'Dell',
y: 21,
},
{
x: 'HP',
y: 16,
},
{
x: 'Lenovo',
y: 20,
},
],
},
{
name: 'Tablets',
data: [
{
x: 'ABCD',
y: 10
x: 'Samsung',
y: 4,
},
{
x: 'Huawei',
y: 7,
},
{
x: 'Microsoft',
y: 11,
},
{
x: 'DEFG',
y: 20
x: 'Amazon',
y: 31,
},
{
x: 'WXYZ',
y: 51
x: 'Lenovo',
y: 13,
},
],
},
{
name: 'Mobile',
data: [
{
x: 'Apple',
y: 10,
},
{
x: 'PQR',
y: 30
x: 'Samsung',
y: 20,
},
{
x: 'MNO',
y: 20
x: 'Huawei',
y: 51,
},
{
x: 'CDE',
y: 30
}
]
}
x: 'Xiaomi',
y: 30,
},
],
},
],
legend: {
show: false
show: true,
offsetY: 10,
height: 30,
},
chart: {
height: 350,
type: 'treemap'
type: 'treemap',
},
title: {
text: 'Multi-dimensional Treemap',
align: 'center'
align: 'center',
},
plotOptions: {
treemap: {},
}
};

Expand Down
Loading

0 comments on commit 873e75f

Please sign in to comment.