How to define the opacity of ProgressBar's secondaryProgress?

I am reaching out to seek guidance on how to define the opacity for the secondaryProgress in the ProgressBar component.


Can someone help me?


1 Reply

NP Nishanthi Panner Selvam Syncfusion Team December 18, 2023 07:41 AM UTC

Shaun,


Greetings from Syncfusion.


We have analyzed your query and found that we do not have direct support for applying opacity to the secondary progress bar color. However, we suggest using an RGB color for the secondary progress bar.


Currently, we have created a sample in Typescript as we are unaware of the platform you are using. If the provided sample does not meet your requirements, please let us know the platform you are using.


Code-snippet:


let warningsProgress: ProgressBar = new ProgressBar({

        secondaryProgressColor: 'rgba(0, 128, 255, 0.5)',        /// 0.5 represents the opacity of the color

    });

warningsProgress.appendTo('#linearbuffer');


Screenshot:



Sample: https://stackblitz.com/edit/9anhmi-nvfrmm?file=index.ts


Regards,

Nishanthi



Loader.
Up arrow icon