$id, 'name' => $name, 'icon' => 'dashicons-slides', 'svg' => false, 'category' => 'common', 'description' => false, 'preview_image' => false, 'options_callback' => false, 'available' => true, ); $args = wp_parse_args($args, $defaults); $AdvancedGutenbergBlocks->set_block( $args ); } /** * Register a setting for the plugin settings page * * name: (String) Setting slug * load_on_editor: (Boolean) define if the option value will be sent to the admin editor */ static function register_setting( $setting, $load_on_editor = false ) { global $AdvancedGutenbergBlocks; $args = array( 'name' => $setting, 'editor' => $load_on_editor, ); $AdvancedGutenbergBlocks->set_setting( $args ); } }