apache/echarts

Brush area do not move while roam.

Closed this issue · 2 comments

Version

4.5.0

Steps to reproduce

(1) click "保持选择"
(2) brush an area
(3) drag roam

var testGeoJson1 = {
    'type': 'FeatureCollection',
    'features': [
        {
            'geometry': {
                'type': 'Polygon',
                'coordinates': [
                    [
                        [
                            2000,
                            3000
                        ],
                        [
                            5000,
                            3000
                        ],
                        [
                            5000,
                            8000
                        ],
                        [
                            2000,
                            8000
                        ]
                    ]
                ]
            },
            'properties': {
                'name': 'Some Area',
                'childNum': 1
            }
        }
    ]
};
echarts.registerMap('test1', testGeoJson1);

var data = [];
var step = 500;
var lngStart = 1000;
var latStart = 2000;
for (var i = 0; i < 10; i  ) {
    for (var j = 0; j < 10; j  ) {
        data.push({
            value: [lngStart   j * step, latStart   i * step],
            symbolSize: 5   j * 5
        });
    }
}

var option = {
    geo: [{
        map: 'test1',
        zoom: 4,
        roam: true
    }],
    brush: {
        geoIndex: 0
    },
    series: [{
        type: 'scatter',
        coordinateSystem: 'geo',
        symbol: 'roundRect',
        symbolSize: 30,
        data: data
    // }, {                      // uncomment it to make brush area move
    //     type: 'bar',     // uncomment it to make brush area move
    //     data: []           // uncomment it to make brush area move
    }],
    // xAxis: {},            // uncomment it to make brush area move
    // yAxis: {},            // uncomment it to make brush area move
};

Also check main2 of test/drag-out.html.

What is expected?

The brush area should move follow the roam

What is actually happening?

not move.
But uncomment some code above, that will become correct.

Hi! We've received your issue and please be patient to get responded. 🎉
The average response time is expected to be within one day for weekdays.

In the meanwhile, please make sure that you have posted enough image to demo your request. You may also check out the API and chart option to get the answer.

If you don't get helped for a long time (over a week) or have an urgent question to ask, you may also send an email to dev@echarts.apache.org. Please attach the issue link if it's a technical questions.

If you are interested in the project, you may also subscribe our mail list.

Have a nice day! 🍵

Similar problem
#11670