Skip to content

Extra options for existing dashboard widgets #167

Description

@joelworsham

Would love to see an integration for widget settings into existing WP widgets.

This is where settings could be added (I think), if you match the existing ID:

/**
* Extra dashboard widgets.
*
* @since 2.0.0
* @access private
*/
public static function get_custom_dashboard_widgets() {
/**
* Extra, re-usable dashboard widgets.
*
* @since 2.0.0
*/
$widgets = apply_filters( 'cd_customize_dashboard_widgets', array(
array(
'id' => 'text',
'label' => __( 'Text/HTML', 'client-dash' ),
'settings' => array(
array(
'name' => 'text',
'label' => __( 'Text or HTML', 'client-dash' ),
'type' => 'textarea',
),
),
'callback' => 'clientdash_custom_widget_text',
),
) );
return $widgets;
}

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions