doAction( “hide_overlay” )

  1. Home
  2. Knowledge Base
  3. Codex
  4. JS API
  5. JS Actions
  6. doAction( “hide_overlay” )
doAction( "hide_overlay", $overlay );

The background overlay was removed from the DOM


(jQuery, required) The jQuery object of the overlay element.


// Display a console message after the modal overlay was hidden again.
DiviArea.addAction( 'hide_overlay', function( overlay ) {
    console.log('The overlay is hidden again!')


The $overlay parameter is a reference to the permanent jQuery overlay element. Though it is hidden, it will not be destroyed and can be accessed and manipulated for the next time it is displayed.

Was this article helpful?

Related Articles