I just want to modify the background color of whole header section and body of my lightning overlayLibrary.
here is my code :
Popup Component
<aura:component implements="forceCommunity:availableForAllPageTypes" access="global" controller="PopupController">
<!--<aura:handler name="init" value="{!this}" action="{!c.initialize}" />-->
<lightning:overlayLibrary aura:id="overlayLib" />
<lightning:button name="modal" label="Show Modal" onclick="
{!c.handleShowModal}"/>
</aura:component>
PopupController
({
handleShowModal : function(component) {
console.log('DBG: inside handleShowModal');
var modalBody;
var modalHeader;
$A.createComponents([
["c:ModalContent", {}],
["c:ModalHeader", {}]
],
function(content, status) {
console.log('DBG: content >>> ' + content);
console.log('DBG: status >>> ' + status);
if (status === "SUCCESS") {
modalBody = content[0];
modalHeader = content[1];
component.find('overlayLib').showCustomModal({
header: modalHeader,
body: modalBody,
showCloseButton: true,
cssClass: "mymodal",
closeCallback: function() {
alert('You closed the alert!');
}
})
}
}
);
}
})
ModelContent :
<aura:component implements="forceCommunity:availableForAllPageTypes" access="global">
<div>
<p>
You are now eligible for our exclusive <b>Melbourne International Flower and Garden Show offer!</b>
</p>
</div>
ModalHeader :
<aura:component >
<h1>CONGRATULATIONS!</h1>
</aura:component>
I appreciate your response!