DataTable formatted values in Material Line Chart

33 views
Skip to first unread message

Goran Gligorin

unread,
Jan 9, 2016, 4:44:23 PM1/9/16
to Google Visualization API
Material line chart only seems to care about the value of a cell.

I'm using the literal object to provide data like:

var data = new google.visualization.DataTable({
    cols: [{
      id: "date",
      type: "date",
      p: {}
    }, {
      id: "views",
      label: "Views",
      type: "number",
      p: {}
    }],
    rows: [{
      "c": [{
        "v": new Date("2015-12-10T00:00:00.000Z"),
        "f": "Dec 10, 2015"
      }, {
        "v": 30,
        "f": "3,000"
      }]
    }, {
      "c": [{
        "v": new Date("2015-12-11T00:00:00.000Z"),
        "f": "Dec 11, 2015"
      }, {
        "v": 45,
        "f": "4,500"
      }]
    }]
  });

You'll notice the "f" for views is a 100x, so I'd be able to tell if it's working.

Unfortunately, the tooltip still looks like this:


Neither the date or the view count are displayed using their formatted value.


Here's a fiddle: https://jsfiddle.net/gligoran/qxf2zkhu/


I know Material charts are in beta, but this seems like functionality that should be working.

Sergey Grabkovsky

unread,
Jan 11, 2016, 10:14:08 AM1/11/16
to Google Visualization API
Hi Goran,

Thanks for reminding us of this issue! I have a fix for this ready now, and you should see it in the next release (version 44).

--
You received this message because you are subscribed to the Google Groups "Google Visualization API" group.
To unsubscribe from this group and stop receiving emails from it, send an email to google-visualizati...@googlegroups.com.
To post to this group, send email to google-visua...@googlegroups.com.
Visit this group at https://groups.google.com/group/google-visualization-api.
To view this discussion on the web visit https://groups.google.com/d/msgid/google-visualization-api/8602ab85-601d-48f7-9ddf-140fde6b4d6e%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.
--

unnamed.gif

Sergey Grabkovsky

Software Engineer

Google, Inc

gra...@google.com

Reply all
Reply to author
Forward
0 new messages