wuba / wuba/react-native-echarts

监听datazoom 时,重新setOption会引起datazoom 闪烁

Open
#310 0 comments 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

Dominant language
TypeScript
Stars
967
Forks
35
PR merge metrics
No merged PRs in 30d

Description

 chart.on("datazoom", () => {
        const opt = chart.getOption();
        // TODO: 需要重新设置一些配置项
        chart.setOption(opt);
)}

使用的Skiachart,监听datazoom的时候重新设置option会引起datazoom的闪烁,而且拖动时datazoom的折线数据不可见,拖动结束后调用这个监听重新setOption才可以使datazoom的折线出现,但是会闪一下,包括左右的handleIcon也会闪一下。

请问下应该怎么解决这个问题? @zhiqingchen

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Reproduce the issue with the shown chart.on("datazoom") handler and chart.getOption()/setOption() calls in a Skia-backed chart. Investigate the datazoom rendering during dragging, including the line data and handleIcon, and confirm the fix prevents flicker while keeping both visible before, during, and after the drag.

Written by the indexing model from the issue text.

Assessment

Tech stack
react-native, typescript
Domain
frontend, mobile
Issue type
Bug
Difficulty
3/5
Estimated time
1-2 days
Activity status
Quiet
Clarity
Needs clarification
Newbie friendliness
42/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.