Color Picker Field Join KC discussion

The color_picker allows you to select a color value from a picker.

KingComposer Textarea-HTML text

Map Usage:

array(
	'name' => 'field_id',
	'label' => 'Field Label',

	'type' => 'color_picker',  // USAGE COLOR_PICKER TYPE

	'description' => 'Field Description',
)

Example:

Register a new shortcode with filed type: color_picker

add_map(
	    
        array(
           
            // 1st shortcode element
            'my_shortcode' => array(
                'name' => 'My Shortcode',
                'description' => 'This is my shortcode',
                'icon' => 'my-class-icon',
                'category' => 'Content',
                'params' => array(
                    //1st field
                    array(
                        'name' => 'color',
                        'label' => 'Select Color',
                        'type' => 'color_picker',
                        'admin_label' => true,
                    ),
                    //2nd field
                )
            ),

            // 2nd shortcode element

        ) // End Arrays
    );

} // end my_wp_init()
       
?>

Read more