Trying to format my SharePoint Task List where, based on the value of a column, the bar in the timeline above is a particular color, e.g. for each row where the Shape column is equal to “Circle” the bar in the timeline is blue.Â
Please check below link. This might be help you.
https://docs.microsoft.com/en-us/sharepoint/dev/declarative-customization/column-formatting