-
CSS Style for ui:button in Salesforce Lightning Component non rendering
Hi All,
I followed the instructions in the Lightning Components Developer Guide for applying CSS to a ui:button in my Lightning component, but the style isn't showing up.
Here's the button in my component:
<ui:button label="Box Volunteer Folder" press="{!c.navigate}" class="btn" />
Here's the CSS:
.THIS.uibutton.btn {
background-color: #2574a9;
color: #fff;
padding: 10px 20px;
}I've also tried this with no success:
.THIS .uibutton.btn {
background-color: #2574a9;
color: #fff;
padding: 10px 20px;
}Thanks
Log In to reply.
Popular Salesforce Blogs
Salesforce vs Hubspot: Which CRM Should You Go For?
The way a business sells a product/service has changed drastically over the years with the term ‘Customer Relationship’ gaining traction. Gone are the days when…
All About Salesforce Health Check 101
If you are a Salesforce admin, your major worry must be security. You will be extra cautious as you are handling customer data and yes,…
Top Features and Updates from Salesforce Winter’25 Release
Get ready to embrace the excitement of the Salesforce Winter '25 Release! This season's update is like the first snowfall, bringing a flurry of innovative…
Popular Salesforce Videos
Implement Time Based Workflow | Salesforce Tutorial
If you ask any Salesforce Person, which kind of workflow is difficult to understand and implement, the obvious answer will be the Time Based on…
Traditional AI vs Generative AI | What the difference? | Salesforce
Explore how traditional AI differ from Generative AI from this extract from our latest webinar! We're going to explore the strengths and not-so-strong points of…
3 Must-Have Validation Rules in Salesforce to Save Time and Avoid Costly Mistakes
Validation rules in Salesforce act like quality checks for your data. They help make sure that the data in your Salesforce org is accurate and…