ngx-charts icon indicating copy to clipboard operation
ngx-charts copied to clipboard

feature: export chart to data url

Open eric-gitta-moore opened this issue 2 years ago • 5 comments

What kind of change does this PR introduce?

  • [ ] Bugfix
  • [x] Feature
  • [ ] Code style update (formatting, local variables)
  • [ ] Refactoring (no functional changes, no api changes)
  • [ ] Build related changes
  • [ ] CI related changes
  • [ ] Other... Please describe:

What is the current behavior?

Unable to export chart. #1906

What is the new behavior?

The method of exporting data-url is added for BaseChart, and users can download images by obtaining data-url and a tag.

export options image image

export to svg image

export to bitmap image

with transparent

image

Does this PR introduce a breaking change? (check one with "x")

  • [ ] Yes
  • [x] No

eric-gitta-moore avatar Oct 18 '23 13:10 eric-gitta-moore

image In the image for combo chart the legend is cut off for all three formats

Lyq322 avatar Jan 10 '24 00:01 Lyq322

Screenshot 2024-01-09 at 6 34 57 PM

The image for advanced pie chart is also cut off in many places.

Lyq322 avatar Jan 10 '24 00:01 Lyq322

Incredible feature! But it seems like the exported image won't include legend if I choose legend at the bottom. pie-chart

kedij777 avatar Jan 15 '24 01:01 kedij777

image Why is this feature is still not available on demo site ?

sudarshansb143 avatar Mar 04 '24 04:03 sudarshansb143

@sudarshansb143 Thank you for your attention, here are two reasons that may cause temporarily unavailable reasons.

  1. There are also problems with exporting individual charts
  2. Project merging code may not be very active

eric-gitta-moore avatar Mar 06 '24 02:03 eric-gitta-moore