Add a New PixelMenu Option

We included an advanced API for developers who wish to extend the default available options. If you add an option we recommend adding any classes to the body element allowing you to target the navigation menu still.

Practical Example

function prefix_add_menu_option(){
            'type'  => 'dropdown',
            'desc'  => 'Should dropdowns open on hover or click by default? You can override this option on a per item basis',
            'id'    => 'default_dropdown_trigger',
            'label' => 'Dropdown Trigger',
            'default' => 'click',
            'category' => 'General',
            'sub_category' => '',
            'source' => array(
                __('Hover', 'pixel-menu' ) => 'hover',
                __('Click', 'pixel-menu' ) => 'click',

add_action('pixel_add_new_menu_option', 'prefix_add_menu_option');
1 People Found This Helpful.

Viewed 1437 times.