File tree 3 files changed +17
-1
lines changed
client/packages/lowcoder-comps/src
basicChartComp/chartConfigs
3 files changed +17
-1
lines changed Original file line number Diff line number Diff line change @@ -51,6 +51,7 @@ export const ScatterChartConfig = (function () {
51
51
visualMapDimension : NumberControl ,
52
52
visualMapColorMin : ColorControl ,
53
53
visualMapColorMax : ColorControl ,
54
+ polar : BoolControl ,
54
55
} ,
55
56
( props ) : ScatterSeriesOption => {
56
57
return {
@@ -85,7 +86,8 @@ export const ScatterChartConfig = (function () {
85
86
visualMapDimension : props . visualMapDimension ,
86
87
visualMapColorMin : props . visualMapColorMin ,
87
88
visualMapColorMax : props . visualMapColorMax ,
88
- }
89
+ } ,
90
+ polar : props . polar ,
89
91
} ;
90
92
}
91
93
)
@@ -122,6 +124,9 @@ export const ScatterChartConfig = (function () {
122
124
{ children . visualMap . getView ( ) && children . visualMapColorMax . propertyView ( {
123
125
label : trans ( "scatterChart.visualMapColorMax" ) ,
124
126
} ) }
127
+ { children . polar . propertyView ( {
128
+ label : trans ( "scatterChart.polar" ) ,
129
+ } ) }
125
130
</ >
126
131
) )
127
132
. build ( ) ;
Original file line number Diff line number Diff line change @@ -119,6 +119,9 @@ export function getSeriesConfig(props: EchartsConfigProps) {
119
119
config . singleAxisIndex = index ;
120
120
config . data = [ ] ;
121
121
}
122
+ if ( props . chartConfig . polar ) {
123
+ config . coordinateSystem = 'polar' ;
124
+ }
122
125
if ( s . effect ) config . type = "effectScatter" ;
123
126
if ( s . symbolSize ) config . symbolSize = s . symbolSize ;
124
127
if ( s . dynamicSize ) config . symbolSize = function ( dataItem ) {
@@ -251,6 +254,13 @@ export function getEchartsConfig(
251
254
}
252
255
}
253
256
}
257
+ if ( props . chartConfig . polar ) {
258
+ config . angleAxis = config . xAxis ;
259
+ config . radiusAxis = config . yAxis ;
260
+ config . polar = { } ;
261
+ delete config . xAxis ;
262
+ delete config . yAxis ;
263
+ }
254
264
255
265
console . log ( "Echarts transformedData and config" , transformedData , config ) ;
256
266
return config ;
Original file line number Diff line number Diff line change @@ -379,6 +379,7 @@ export const en = {
379
379
labelLineLength2 : "Label Line Length2" ,
380
380
} ,
381
381
scatterChart : {
382
+ polar : "Polar Chart" ,
382
383
visualMap : "Visual Map" ,
383
384
visualMapMin : "Visual Map Min" ,
384
385
visualMapMax : "Visual Map Max" ,
You can’t perform that action at this time.
0 commit comments