Support for Drupal 7 is ending on 5 January 2025—it’s time to migrate to Drupal 10! Learn about the many benefits of Drupal 10 and find migration tools in our resource center.
Right now when displaying large numbers, we do not include a thousands separator (typically a comma) in the display of the chart. We should include a comma by default, and if possible allow this to be localized.
We're already formatting numbers to support decimal places, prefixes, and suffixes, so we only need to modify the existing formatting to support thousands separators.
See http://docs.highcharts.com/#formatting
https://developers.google.com/chart/interactive/docs/reference#formatters
Comment | File | Size | Author |
---|---|---|---|
#6 | highcharts.js_.txt | 188.18 KB | kellyimagined |
#3 | google_charts_large-2418717-1.patch | 826 bytes | homberger |
Comments
Comment #1
Pierre.Vriens CreditAttribution: Pierre.Vriens commentedComment #2
Pierre.Vriens CreditAttribution: Pierre.Vriens commentedComment #3
homberger CreditAttribution: homberger as a volunteer commentedA patch for this issue was attached to the referenced issue #2418717: Google charts: large number format by geekygnr
In my test the patch worked: the thousands operator is included and localized.
I attach this patch to this issue too, but credit belongs to geekynr.
Comment #4
Fabianx CreditAttribution: Fabianx as a volunteer and at Tag1 Consulting commentedComment #5
mstrelan CreditAttribution: mstrelan commentedDifferent approach for Highcharts, something like this (global).
Comment #6
kellyimagined CreditAttribution: kellyimagined commentedUpdating the highcharts.js library file to "," instead of " " was the solution I ended up using.
Remove the .txt before uploading.