File tree Expand file tree Collapse file tree 3 files changed +17
-1
lines changed
client/packages/lowcoder-comps/src
basicChartComp/chartConfigs Expand file tree Collapse file tree 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 () {
5151 visualMapDimension : NumberControl ,
5252 visualMapColorMin : ColorControl ,
5353 visualMapColorMax : ColorControl ,
54+ polar : BoolControl ,
5455 } ,
5556 ( props ) : ScatterSeriesOption => {
5657 return {
@@ -85,7 +86,8 @@ export const ScatterChartConfig = (function () {
8586 visualMapDimension : props . visualMapDimension ,
8687 visualMapColorMin : props . visualMapColorMin ,
8788 visualMapColorMax : props . visualMapColorMax ,
88- }
89+ } ,
90+ polar : props . polar ,
8991 } ;
9092 }
9193 )
@@ -122,6 +124,9 @@ export const ScatterChartConfig = (function () {
122124 { children . visualMap . getView ( ) && children . visualMapColorMax . propertyView ( {
123125 label : trans ( "scatterChart.visualMapColorMax" ) ,
124126 } ) }
127+ { children . polar . propertyView ( {
128+ label : trans ( "scatterChart.polar" ) ,
129+ } ) }
125130 </ >
126131 ) )
127132 . build ( ) ;
Original file line number Diff line number Diff line change @@ -119,6 +119,9 @@ export function getSeriesConfig(props: EchartsConfigProps) {
119119 config . singleAxisIndex = index ;
120120 config . data = [ ] ;
121121 }
122+ if ( props . chartConfig . polar ) {
123+ config . coordinateSystem = 'polar' ;
124+ }
122125 if ( s . effect ) config . type = "effectScatter" ;
123126 if ( s . symbolSize ) config . symbolSize = s . symbolSize ;
124127 if ( s . dynamicSize ) config . symbolSize = function ( dataItem ) {
@@ -251,6 +254,13 @@ export function getEchartsConfig(
251254 }
252255 }
253256 }
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+ }
254264
255265 console . log ( "Echarts transformedData and config" , transformedData , config ) ;
256266 return config ;
Original file line number Diff line number Diff line change @@ -379,6 +379,7 @@ export const en = {
379379 labelLineLength2 : "Label Line Length2" ,
380380 } ,
381381 scatterChart : {
382+ polar : "Polar Chart" ,
382383 visualMap : "Visual Map" ,
383384 visualMapMin : "Visual Map Min" ,
384385 visualMapMax : "Visual Map Max" ,
You can’t perform that action at this time.
0 commit comments