function readOnly(count){ }
Starting November 20, the site will be set to read-only. On December 4, 2023,
forum discussions will move to the Trailblazer Community.
+ Start a Discussion
pgolikovapgolikova 

Access default CSS file

Hello, everyone

I’m playing with UI and Visual Force.

Does anyone know if there is way of accessing default SF CSS used for standard layout and altering that file instead of creating everything from zero?

Appreciate,

Best Answer chosen by Admin (Salesforce Developers) 
Anup JadhavAnup Jadhav

You can use the css class described in standard SF css, but it is highly recommended that a VF page should NOT rely on these css classes, since Salesforce can change either the css file, or the style for a particular css class that you might be refererring to in your code.

 

My advice would be stay away from using SF css styles in your code. There is nothing stopping you to create your own css files, and use those styles in your VF page.

 

Thanks,

Anup

All Answers

MaverickDevMaverickDev

Hi,

 

You may include below mentioned css in your VF page.

 

<apex:stylesheet value="/sCSS/21.0/sprites/1297816277000/Theme3/default/gc/versioning.css" />   

 

pgolikovapgolikova

but can I change it?

can I access that versioning.css file?

MaverickDevMaverickDev

No, you can not change SF css but you can access it by adding it to your VF page.You may refer respecrive css files to create your own new css.

 

<apex:stylesheet value="/sCSS/21.0/sprites/1297816277000/Theme3/default/gc/versioning.css" />   

<apex:stylesheet value="/sCSS/21.0/sprites/1297816277000/Theme3/default/gc/extended.css" />

 

You can refer below  link for more info.

http://salesforcetutorials.wordpress.com/2012/04/01/tabbed-visualforce-page/

 

Hope this helps!!

Anup JadhavAnup Jadhav

You can use the css class described in standard SF css, but it is highly recommended that a VF page should NOT rely on these css classes, since Salesforce can change either the css file, or the style for a particular css class that you might be refererring to in your code.

 

My advice would be stay away from using SF css styles in your code. There is nothing stopping you to create your own css files, and use those styles in your VF page.

 

Thanks,

Anup

This was selected as the best answer
ramesh1.3953861428713804E12ramesh1.3953861428713804E12
Is There any other default style sheets available in Salesforce like
<apex:stylesheet value="/sCSS/21.0/sprites/1297816277000/Theme3/default/gc/versioning.css" />