You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@echarts.apache.org by "hl2232 (via GitHub)" <gi...@apache.org> on 2025/09/25 03:28:44 UTC

[I] [Bug] Bezier curve calculation wrong in zoomed area [echarts]

hl2232 opened a new issue, #21292:
URL: https://github.com/apache/echarts/issues/21292

   ### Version
   
   4.2.1
   
   ### Link to Minimal Reproduction
   
   option: {         tooltip: {           trigger: "axis",         },         legend: {           data: ["BDS", "GPS"],           selected: {             BDS: true, // 初始状态,BDS系列可见             GPS: true, // 初始状态,GPS系列可见           },         },         toolbox: {           show: true,           feature: {             dataZoom: {               yAxisIndex: "none",             },             restore: {},             saveAsImage: {},             myFull: {               show: true,               title: "全屏查看",               icon: "path://M432.45,595.444c0,2.177-4.661,6.82-11.305,6.82c-6.475,0-11.306-4.567-11.306-6.82s4.852-6.812,11.306-6.812C427.841,588.632,432.452,593.191,432.45,595.444L432.45,595.444z M421.155,589.876c-3.009,0-5.448,2.495-5.448,5.572s2.439,5.572,5.448,5.572c3.01,0,5.449-2.495,5.449-5.572C426.604,592.371,424.165,589.876,421.155,589.876L421.155,589.876z M421.146,591.891c-1.916,0-3.47,1.589-3.47,3.549c0,1.959,1.554,3.548,3.47,3.54
 8s3.469-1.589,3.469-3.548C424.614,593.479,423.062,591.891,421.146,591.891L421.146,591.891zM421.146,591.891",               onclick: (e) => {                 const element = document.getElementById("myChart");                 if (element.requestFullScreen) {                   // HTML W3C 提议                   element.requestFullScreen();                 } else if (element.msRequestFullscreen) {                   // IE11                   element.msRequestFullScreen();                 } else if (element.webkitRequestFullScreen) {                   // Webkit (works in Safari5.1 and Chrome 15)                   element.webkitRequestFullScreen();                 } else if (element.mozRequestFullScreen) {                   // Firefox (works in nightly)                   element.mozRequestFullScreen();                 }                 // 退出全屏                 if (element.requestFullScreen) {                   document.exitFullscreen();                 } else if (element.msReques
 tFullScreen) {                   document.msExitFullscreen();                 } else if (element.webkitRequestFullScreen) {                   document.webkitCancelFullScreen();                 } else if (element.mozRequestFullScreen) {                   document.mozCancelFullScreen();                 }               },             },           },         },
   
   ### Steps to Reproduce
   
   Enable dataZoom (area zoom or slider zoom)
   Zoom into different areas of the chart multiple times
   Observe the curve behavior during zoom operations
   
   ### Current Behavior
   
   <img width="1549" height="337" alt="Image" src="https://github.com/user-attachments/assets/2081a909-3690-4f3e-bb18-5e69cd85e019" />
   Smooth line curves show abnormal/exaggerated arcs after zooming
   The curves don't follow the actual data points properly
   The issue occurs randomly and cannot be consistently reproduced
   Same data produces different curve shapes in different zoom ranges
   Refreshing the page fixes the issue temporarily
   
   ### Expected Behavior
   
   <img width="1118" height="310" alt="Image" src="https://github.com/user-attachments/assets/08f483d0-4766-4385-ab29-effd331cb730" />
   Smooth curves should maintain proper shape during zoom operations
   Curves should always follow logical paths between data points
   Zooming should not affect the mathematical relationship between points
   
   ### Environment
   
   ```markdown
   - OS:Windows
   - Browser:Chrome
   - Framework:
   ```
   
   ### Any additional comments?
   
   _No response_


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: commits-unsubscribe@echarts.apache.org.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: commits-unsubscribe@echarts.apache.org
For additional commands, e-mail: commits-help@echarts.apache.org


Re: [I] [Bug] Bezier curve calculation wrong in zoomed area [echarts]

Posted by "echarts-bot[bot] (via GitHub)" <gi...@apache.org>.
echarts-bot[bot] commented on issue #21292:
URL: https://github.com/apache/echarts/issues/21292#issuecomment-3333340488

   @hl2232 Please provide a demo for the issue either with [Official Editor](https://echarts.apache.org/examples/editor.html), [CodePen](https://codepen.io/Ovilia/pen/dyYWXWM), [CodeSandbox](https://codesandbox.io/s/echarts-basic-example-template-mpfz1s) or [JSFiddle](https://jsfiddle.net/plainheart/e46ozpqj/7/).


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: commits-unsubscribe@echarts.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: commits-unsubscribe@echarts.apache.org
For additional commands, e-mail: commits-help@echarts.apache.org


Re: [I] [Bug] Bezier curve calculation wrong in zoomed area [echarts]

Posted by "hl2232 (via GitHub)" <gi...@apache.org>.
hl2232 commented on issue #21292:
URL: https://github.com/apache/echarts/issues/21292#issuecomment-3333570349

   Thanks for the feedback. Unfortunately, this issue is intermittent - I've encountered it only 3 times in 2 months of usage. It cannot be consistently reproduced.
   The issue characteristics:
   Occurs randomly during dataZoom operations
   Same data + same code = different results sometimes
   Only happens with smooth: true + dataZoom combination
   Page refresh always fixes it temporarily
   Since it's a sporadic timing-related issue, creating a reliable demo is not feasible. Are there any known compatibility concerns between smooth curves and dataZoom that I should be aware of?
   I can provide more details if needed, but consistent reproduction seems impossible due to the random nature of this bug.  `option: {
           tooltip: {
             trigger: "axis",
           },
           legend: {
             data: ["BDS", "GPS"],
             selected: {
               BDS: true,
               GPS: true, 
             },
           },
           toolbox: {
             show: true,
             feature: {
               dataZoom: {
                 yAxisIndex: "none",
               },
               restore: {},
               saveAsImage: {},
               myFull: {
                 show: true,
                 title: "View in full screen",
                 icon: "path://M432.45,595.444c0,2.177-4.661,6.82-11.305,6.82c-6.475,0-11.306-4.567-11.306-6.82s4.852-6.812,11.306-6.812C427.841,588.632,432.452,593.191,432.45,595.444L432.45,595.444z M421.155,589.876c-3.009,0-5.448,2.495-5.448,5.572s2.439,5.572,5.448,5.572c3.01,0,5.449-2.495,5.449-5.572C426.604,592.371,424.165,589.876,421.155,589.876L421.155,589.876z M421.146,591.891c-1.916,0-3.47,1.589-3.47,3.549c0,1.959,1.554,3.548,3.47,3.548s3.469-1.589,3.469-3.548C424.614,593.479,423.062,591.891,421.146,591.891L421.146,591.891zM421.146,591.891",
                 onclick: (e) => {
                   const element = document.getElementById("myChart");
                   if (element.requestFullScreen) {
                     element.requestFullScreen();
                   } else if (element.msRequestFullscreen) {
                     // IE11
                     element.msRequestFullScreen();
                   } else if (element.webkitRequestFullScreen) {
                     // Webkit (works in Safari5.1 and Chrome 15)
                     element.webkitRequestFullScreen();
                   } else if (element.mozRequestFullScreen) {
                     // Firefox (works in nightly)
                     element.mozRequestFullScreen();
                   }
                   if (element.requestFullScreen) {
                     document.exitFullscreen();
                   } else if (element.msRequestFullScreen) {
                     document.msExitFullscreen();
                   } else if (element.webkitRequestFullScreen) {
                     document.webkitCancelFullScreen();
                   } else if (element.mozRequestFullScreen) {
                     document.mozCancelFullScreen();
                   }
                 },
               },
             },
           },
           grid: {
             top: "10%",
             left: "2%",
             right: "2%",
             bottom: "10%",
             containLabel: true,
           },
           xAxis: [
             {
               type: "category",
               boundaryGap: false,
               data: this.TimeData,
             },
           ],
           yAxis: {
             show: true,
             scale: true,
             type: "value",
             boundaryGap: ["20%", "20%"],
             minInterval: 1,
             splitLine: {
               show: true,
             },
           },
           series: [
             {
               name: "BDS",
               smooth: true,
               type: "line",
   
               symbolSize: 8,
               emphasis: {
                 focus: "series",
               },
               data: this.BDSvalues,
               itemStyle: {
                 color: "#007bff", 
               },
             },
             {
               name: "GPS",
               smooth: true,
               type: "line",
   
               symbolSize: 8,
   
               emphasis: {
                 focus: "series",
               },
               data: this.GPSvalues,
               itemStyle: {
                 color: "#ff7300",
               },
             },
           ],
         },`


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: commits-unsubscribe@echarts.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: commits-unsubscribe@echarts.apache.org
For additional commands, e-mail: commits-help@echarts.apache.org