+ Start a Discussion
Sagar MauryaSagar Maurya 

css with vf chart

User-added image
We have developed a Custom VF Chart as shown above. Now our requirement is to beautify the chart(bars and texts) and its legends by applying the css on it. Can we apply css on the chart tag and legends? Is there any way to do so because css was not applicable on it? Please let me know if anyone has come across similar kind of requirement.
bhanu_prakashbhanu_prakash
Hi Sagar,
you can add css to your chart like below to your visualforcePage
 
<style>
    text {
        fill: white !important;
    }
</style>

let us know if it helps you and mark it best if it helps you
Thanks, 
Bhanu Prakash
visit ForceLearn.com
Sagar MauryaSagar Maurya
Hi Bhanu,
The style tag was not applying on the <apex:chart> tag. Have you implemented this with <apex:chart> or <apex:lineSeries> or <apex:axis> or <apex:legend> tags?

Thanks,
Sagar Maurya
bhanu_prakashbhanu_prakash
Hi Sagar,
yes you can check these link .. and you will get idea to embeed them
https://codinginsalesforce.wordpress.com/2014/11/07/repositioning-charts/
Sagar MauryaSagar Maurya
Hi Bhanu,
Can we apply css on "tips" attribute of <apex:lineSeries> and <apex:barSeries> series. It looks very small as of now. Can we increase its length and width?

Thanks,
Sagar