I was trying to place a quick action button to display custom lightning component to show a PDF. The quick action popup is coming with a default header and footer. The footer has only one cancel action button but, we need to have 3 action buttons, to perform savePDF, emailPDF and cancel.
To achieve this I have created a custom header, body and footer using SLDS styling. But the content is displayed on the modal popup’s body, with some padding and margin.
How to remove the extra padding and margin in the action popup from the component?
I tried multiple workarounds to achieve this.
- Included the CSS style to remove the margin or padding in the .css part of the aura bundle of my component. But, it is not possible to change the parent popup’s style from the child component due to THIS keyword in CSS.
- Included an external stylesheet into the component as a static resource (using ltng:require). It was working fine but the style will be applied to all the quick action popups in the application.
- HTML style tag cannot be used inside a component as it throws an error on saving.