doAction( "show_area" )

doAction( "show_area", area );
doAction( "show_area_{key}", area );

Fires after the visible state changed to "visible", or the intro-animation has started.

The dynamic part of the filter name is the sanitized Area key. See DiviAreaItem.theKey() for details.

Params

area
(DiviAreaItem, required) The Area object.

Examples

// Send an event to google analytics, once a Popup is displayed.
DiviArea.addAction( 'show_area', function( area ) {
    var type = area.getType();
    var key = area.getKey();

    if ( 'popup' === type ) {
        ga( 'send', 'event', 'Popup', 'open', key );
    }
});

Notes

Did this answer your question? Thanks for the feedback There was a problem submitting your feedback. Please try again later.