I have a problem with checkboxes when using lightning:recordForm. My code:

 <lightning:recordForm objectApiName="Opportunity" recordId="{!v.recordId}"
                              mode="view" fields="{!v.LeadHistory}" columns="2"
                              onload="{!c.handleOnLoad}" onsuccess="{!c.handleOnSuccess}"

enter image description here

As u can see each checkbox is display in 3 lines. I would like that edit button would be in the same line. Every other field from my object renders fine.


Add Style to your Component. below i am posting example code. which worked for me.

.THIS .inputFieldWidth {



Styling .inpitFieldWidth by adding width haven't worked for me. I added:

.THIS .slds-form-element__static{
display: inline-block;}

styly into my component and it has worked.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.