Skip to content

Date Scale X Axis not displaying properly on FireFox #41

Description

@jiangmf

My chart displays like this on FireFox,
firefox
there's no errors shown in the deverloper console.

But it displays correctly on Chrome
chrome
I am using the latest version of Chart.Scatter,

some code sample data generation/chart generation

var data_item = {
                    name: "data_item",
                    label: "Data Item",
                    strokeColor: color,
                    fillColor: color,
                    pointStrokeColor: color,
                    pointColor: "rgba(0,0,0,0)",
                    data: [{
                        r: 1,
                        x: new Date("03-03-16"),
                        y: 5,
                    }, {
                        r: 1,
                        x: new Date("03-07-16"),
                        y: 4,
                    }, {
                        r: 5,
                        x: new Date("03-08-16"),
                        y: 2,
                    }, {
                        r: 5,
                        x: new Date("03-12-16"),
                        y: 2,
                    }, {
                        r: 1,
                        x: new Date("03-20-16"),
                        y: 5,
                    }, ],
                }

var data_set = [data_item, data_item2, data_item3 ...]
var config = {
                scaleType: "date",
                responsive: true,
                animation: false,
                maintainAspectRatio: false,
                // pointDot : false,
                multiTooltipTemplate: "<%= datasetLabel %>: <%= value %>",
                tooltipTemplate: "<%= datasetLabel %>: <%= value %>",
                scaleTimeFormat: " ",
            };
            var ctx = document.getElementById("canvas").getContext("2d");
            window.myLine = new Chart(ctx).Scatter(dataset, config);

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions