kendoChart series show and disappear very quickly

1 Answer 80 Views
Charts
Moslem
Top achievements
Rank 1
Moslem asked on 09 Jun 2023, 08:31 AM

I am trying to display some series in a kendoChart. What is really weird is that they show then disappear in less than one second as soon as the page is loaded.

Here is my relevant HTML code :

<div id="chartOccupation" class="" style="height: 300px;"></div>

Here is my JavaScript code :


$("#chartOccupation").kendoChart({
            theme: "bootstrap",
            title: {
                text: "Répartition Occupation / Type séjour ",
                position: "bottom",
            },
            legend: {
                visible: true,
                position: "bottom",
            },
            series: [{
                name: 'séjour long',
                type: 'line',
                field: 'value',
                categoryField: 'date',
                data: [
                    {
                        value: 10,
                        date: new Date("01/01/2012")
                    }, 
                    {
                        value: 20,
                        date: new Date("01/04/2012")
                    }, 
                    {
                        value: 30,
                        date: new Date("01/07/2012")
                    }
                ]
            }],
            valueAxis: {
                min: 0,
                max: 100,
                majorUnit: 10,
                line: {
                    visible: false,
                },
                labels: {
                    format: "{0}%"
                },
            },
            categoryAxis: {
                labels: { dateFormats: { days: "d" } },
                baseUnitStep: 1,
                type: "date",
                justified: true,
                baseUnit: "days",
            }
        });

So, What is wrong in my code, and how should I fix it? Any idea?

Thanks in advance.

1 Answer, 1 is accepted

Sort by
0
Neli
Telerik team
answered on 14 Jun 2023, 06:14 AM

Hi Moslem,

I used the provided code to test the behavior on my side. In the Dojo linked here, the series are displayed as expected. Could you please run the Dojo and confirm if the behavior is as expected on your end? Please take a look and let me know if I am missing something.

Also could you please confirm if the issue occurs on all the browsers?

Looking forward to your reply.

Regards,
Neli
Progress Telerik

As of R2 2023, the default icon type will be SVG instead of Font. See this blogpost for more information.
Tags
Charts
Asked by
Moslem
Top achievements
Rank 1
Answers by
Neli
Telerik team
Share this question
or