Skip to content

Commit 4ae5462

Browse files
author
Jordan Hunt
committed
feat(bar-chart-native): add design properties
1 parent c48ba43 commit 4ae5462

File tree

5 files changed

+42
-0
lines changed

5 files changed

+42
-0
lines changed

settings-native.json

Lines changed: 17 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1482,6 +1482,23 @@
14821482
]
14831483
}
14841484
],
1485+
"com.mendix.widget.native.barchart.BarChart": [
1486+
{
1487+
"name": "Chart size",
1488+
"type": "Dropdown",
1489+
"description": "Size of the chart.",
1490+
"options": [
1491+
{
1492+
"name": "Square",
1493+
"class": "barChartSquare"
1494+
},
1495+
{
1496+
"name": "Maximum space",
1497+
"class": "barChartMaxSpace"
1498+
}
1499+
]
1500+
}
1501+
],
14851502
"com.mendix.widget.native.progressbar.ProgressBar": [
14861503
{
14871504
"name": "Progress bar style",
Lines changed: 11 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,11 @@
1+
export const barChartSquare = {
2+
chart: {
3+
aspectRatio: 1
4+
}
5+
};
6+
export const barChartMaxSpace = {
7+
chart: {
8+
flex: 1,
9+
aspectRatio: undefined
10+
}
11+
};

styles/native/js/main.js

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -32,6 +32,7 @@ export * from "./core/widgets/layoutgrid";
3232
export * from "./core/widgets/linechart";
3333
export * from "./core/helpers/linechart";
3434
export * from "./core/widgets/barchart";
35+
export * from "./core/helpers/barchart";
3536
export * from "./core/widgets/listviews";
3637
export * from "./core/helpers/listviews";
3738
export * from "./core/widgets/listviewswipe";
Lines changed: 12 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,12 @@
1+
export const barChartSquare = {
2+
chart: {
3+
aspectRatio: 1
4+
}
5+
};
6+
7+
export const barChartMaxSpace = {
8+
chart: {
9+
flex: 1,
10+
aspectRatio: undefined
11+
}
12+
};

styles/native/ts/main.ts

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -32,6 +32,7 @@ export * from "./core/widgets/layoutgrid";
3232
export * from "./core/widgets/linechart";
3333
export * from "./core/helpers/linechart";
3434
export * from "./core/widgets/barchart";
35+
export * from "./core/helpers/barchart";
3536
export * from "./core/widgets/listviews";
3637
export * from "./core/helpers/listviews";
3738
export * from "./core/widgets/listviewswipe";

0 commit comments

Comments
 (0)