add_panel( 'bexplore_breadcrumb_settings_panel', array( 'priority' => 10, 'capability' => 'edit_theme_options', 'title' => __('Breadcrumb', 'bexplore'), ) ); /** * Breadcrumb * * @since 1.0.0 */ $wp_customize->add_section( 'bexplore_breadcrumb_section', array( 'title' => __('Breadcrumb settings', 'bexplore'), 'description' => __('Show/Hide option for breadcrumb.', 'bexplore'), 'priority' => 5, 'panel' => 'bexplore_breadcrumb_settings_panel', ) ); $wp_customize->add_setting( 'bexplore_breadcrumb_on_off', array( 'default' => 'hide', 'transport' => 'refresh', 'sanitize_callback' => 'bexplore_sanitize_switch_option', ) ); $wp_customize->add_control( 'bexplore_breadcrumb_on_off', array( 'type' => 'select', 'label' => esc_html__('Breadcrumb Area', 'bexplore'), 'description' => esc_html__('Show/Hide option for breadcrumb.', 'bexplore'), 'section' => 'bexplore_breadcrumb_section', 'priority' => 10, 'choices' => array( 'show' => esc_html__('Show', 'bexplore'), 'hide' => esc_html__('Hide', 'bexplore'), ), ) ); /** * Breadcrumb Background * * @since 1.0.0 */ $wp_customize->add_section( 'bexplore_breadcrumb_bg_section', array( 'title' => __('Breadcrumb Background', 'bexplore'), 'description' => __('Set the Breadcrumb background.', 'bexplore'), 'priority' => 5, 'panel' => 'bexplore_breadcrumb_settings_panel', 'active_callback' => 'bexplore_is_breadcrumb_show', ) ); $wp_customize->add_setting( 'bexplore_breadcrumb_bg_clr', array( 'default' => '#1e73be', 'transport' => 'refresh', 'sanitize_callback' => 'sanitize_hex_color', ) ); $wp_customize->add_control( new WP_Customize_Color_Control( $wp_customize, 'bexplore_breadcrumb_bg_clr', array( 'label' => __('Breadcrumb Background Color', 'bexplore'), 'section' => 'bexplore_breadcrumb_bg_section', 'priority' => 10, ) ) ); $wp_customize->add_setting( 'bexplore_breadcrumb_overlay_bg_clr', array( 'default' => '#1e73be', 'transport' => 'refresh', 'sanitize_callback' => 'sanitize_hex_color', ) ); $wp_customize->add_control( new WP_Customize_Color_Control( $wp_customize, 'bexplore_breadcrumb_overlay_bg_clr', array( 'label' => __('Breadcrumb Overlay Color', 'bexplore'), 'section' => 'bexplore_breadcrumb_bg_section', 'priority' => 10, ) ) ); $wp_customize->add_setting( 'bexplore_breadcrumb_overlay_opacity', array( 'default' => '0.3', 'transport' => 'refresh', 'sanitize_callback' => 'bexplore_copyright_html', ) ); $wp_customize->add_control( 'bexplore_breadcrumb_overlay_opacity', array( 'type' => 'number', 'input_attrs' => array( 'min' => 0, 'max' => 1, 'step' => .1, ), 'label' => __('Breadcrumb Overlay Opacity', 'bexplore'), 'section' => 'bexplore_breadcrumb_bg_section', 'priority' => 10, ) ); $wp_customize->add_setting( 'bexplore_breadcrumb_bg_img', array( 'default' => '', 'sanitize_callback' => 'esc_url_raw', ) ); $wp_customize->add_control( new WP_Customize_Image_Control( $wp_customize, 'bexplore_breadcrumb_bg_img', array( 'label' => __('Breadcrumb Background Image', 'bexplore'), 'section' => 'bexplore_breadcrumb_bg_section', 'priority' => 10, ) ) ); /** * Breadcrumb Text Color * * @since 1.0.0 */ $wp_customize->add_section( 'bexplore_breadcrumb_clr_section', array( 'title' => __('Breadcrumb Color', 'bexplore'), 'description' => __('Set the Breadcrumb Color.', 'bexplore'), 'priority' => 5, 'panel' => 'bexplore_breadcrumb_settings_panel', 'active_callback' => 'bexplore_is_breadcrumb_show', ) ); $wp_customize->add_setting( 'bexplore_breadcrumb_txt_clr', array( 'default' => '#0c1428', 'transport' => 'refresh', 'sanitize_callback' => 'sanitize_hex_color', ) ); $wp_customize->add_control( new WP_Customize_Color_Control( $wp_customize, 'bexplore_breadcrumb_txt_clr', array( 'label' => __('Breadcrumb Text Color', 'bexplore'), 'section' => 'bexplore_breadcrumb_clr_section', 'priority' => 10, ) ) ); $wp_customize->add_setting( 'bexplore_breadcrumb_txt_hvr_clr', array( 'default' => '#8BA4F9', 'transport' => 'refresh', 'sanitize_callback' => 'sanitize_hex_color', ) ); $wp_customize->add_control( new WP_Customize_Color_Control( $wp_customize, 'bexplore_breadcrumb_txt_hvr_clr', array( 'label' => __('Breadcrumb Anchor Hover Color', 'bexplore'), 'section' => 'bexplore_breadcrumb_clr_section', 'priority' => 10, ) ) ); } add_action('customize_register', 'breadcrumb_settings_register');