Changing the parent task gantt task line


How do I change the UI of the Gantt task line if it is a parent task?


Hello @Asyong,

You can check if the task is a parent using the hasChild method:

After that, you will be able to style this task using the “task_class” template, which is the default gantt solution to stylize tasks:

It may look like the following fragment:

gantt.templates.task_class = function(start, end, task){
    return "project-styles";

Here is a demo(HTML/CODE tabs):