Auto Close Salesforce Ligthning QuickAction Modal

Lightning Component:

<aura:component implements="force:lightningQuickActionWithoutHeader">
    <aura:html tag="style">
        .cuf-content {
        padding: 0 0rem !important;
        .slds-p-around--medium {
        padding: 0rem !important;
        overflow-y:hidden !important;
        height:unset !important;
        max-height:unset !important;
    <aura:handler name="init" value="{!this}" action="{!c.doInit}" />
    <aura:handler event="aura:doneRendering" action="{!c.doneRendering}"/>
    <!--Component Start-->
    <div class="slds-m-around--xx-large">
        <div class="slds-text-heading_medium slds-align_absolute-center">
    <!--Component End-->

Lightning JS Controller:

    doInit : function(component, event, helper) {
        //Write your code to execute, before close the quick action modal
    doneRendering: function(cmp, event, helper) {

  • Prateek Mathur

    Can we attach an event handler when the standard ‘X’ button is clicked on the quick action?

    • Rajesh

      Did you find a way for it. I am also looking for the same?