You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@echarts.apache.org by "BrianWahinya (via GitHub)" <gi...@apache.org> on 2023/12/06 18:11:01 UTC

[I] [Feature] Full-Legend capture in saveAsImage functionality even when there are many components [echarts]

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

   ### What problem does this feature solve?
   
   **Problem:**
   The current implementation of the "saveasimage" feature in ECharts does not adequately capture the complete legend when it extends beyond the visible viewport due to its scrollable nature.
   
   **Use Case/Context:**
   In certain visualizations, legends become extensive, necessitating the use of a scrollable container to accommodate the numerous components. However, when users attempt to save the chart as an image using "saveasimage," only the visible portion of the legend is captured, leading to an incomplete representation of the chart.
   
   **Rationale:**
   The need for a comprehensive image capture arises from scenarios where the legend content exceeds the available space, requiring users to scroll to access additional components. As ECharts is designed to handle diverse and complex visualizations, ensuring that the saved image accurately reflects the entirety of the legend is crucial for maintaining the fidelity of the chart outside the interactive environment.
   
   **End User Experience:**
   The proposed feature aims to enhance the end user experience by providing a more accurate and complete representation of the chart when saved as an image. Users, particularly those dealing with intricate legends, will benefit from having the entire legend captured, facilitating seamless communication and analysis of the visualized data even outside the live ECharts environment.
   
   ### What does the proposed API look like?
   
   Proposed API:
   
   Introduce a new option within the ECharts configuration for the "saveasimage" feature, specifically tailored to address legends within scrollable containers.
   
   ```
   option = {
     // Existing ECharts configuration options...
   
     saveAsImage: {
       // Existing saveasimage options...
   
       includeFullLegend: true
     },
   
     // Other chart configurations...
   };
   ```
   
   The addition of the includeFullLegend option within the saveAsImage configuration allows users to specify whether the saved image should include the full legend, even if it extends beyond the visible viewport due to scrolling.
   
   By default, includeFullLegend is set to false, maintaining the existing behavior where only the visible portion of the legend is captured. When set to true, the entire legend, including its scrolled components, will be included in the saved image.
   
   `To avoid chart and full-legend overlap in the captured image, you can deliberately increase the size of the canvas in the background process: js-libraries such as html2canvas and html-to-image already have a similar functionality`


-- 
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] [Feature] Full-Legend capture in saveAsImage functionality even when there are many components [echarts]

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

   It may not be expected if the content of the chart changes when exporting. For example, the legend may overlap with the chart area when expanded. You can custom the behavior by creating a custom [feature](https://echarts.apache.org/zh/option.html#toolbox.feature) and call `setOption` in the `onclick`.


-- 
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] [Feature] Full-Legend capture in saveAsImage functionality even when there are many components [echarts]

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

   This issue has been automatically marked as stale because it did not have recent activity. It will be closed in 7 days if no further activity occurs. If you wish not to mark it as stale, please leave a comment in this issue.


-- 
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] [Feature] Full-Legend capture in saveAsImage functionality even when there are many components [echarts]

Posted by "github-actions[bot] (via GitHub)" <gi...@apache.org>.
github-actions[bot] closed issue #19367: [Feature] Full-Legend capture in saveAsImage functionality even when there are many components
URL: https://github.com/apache/echarts/issues/19367


-- 
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] [Feature] Full-Legend capture in saveAsImage functionality even when there are many components [echarts]

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

   This issue has been automatically closed because it did not have recent activity. If this remains to be a problem with the latest version of Apache ECharts, please open a new issue and link this to it. Thanks!


-- 
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