';
printf(
'%s %s',
esc_attr( $editor_id ),
esc_attr__( 'Add Form', 'wpforms-lite' ),
$icon,
__( 'Add Form', 'wpforms-lite' )
);
// If we have made it this far then load the JS.
wp_enqueue_script( 'wpforms-editor', WPFORMS_PLUGIN_URL . 'assets/js/admin-editor.js', array( 'jquery' ), WPFORMS_VERSION, true );
add_action( 'admin_footer', array( $this, 'shortcode_modal' ) );
}
/**
* Modal window for inserting the form shortcode into TinyMCE.
*
* Thickbox is old and busted so we don't use that. Creating a custom view in
* Backbone would make me pull my hair out. So instead we offer a small clean
* modal that is based off of the WordPress insert link modal.
*
* @since 1.0.0
*/
public function shortcode_modal() {
?>