<?php
/**
* Header Banner Options.
*
* @package OTT Vlogger
*/

$ott_vlogger_default = ott_vlogger_get_default_theme_options();
$ott_vlogger_post_category_list = ott_vlogger_post_category_list();

$wp_customize->add_section( 'ott_vlogger_header_banner_setting',
    array(
    'title'      => esc_html__( 'Slider Settings', 'ott-vlogger' ),
    'priority'   => 10,
    'capability' => 'edit_theme_options',
    'panel'      => 'ott_vlogger_theme_home_pannel',
    )
);

// Show/Hide Site Logo
$wp_customize->add_setting('ott_vlogger_display_logo', array(
    'default'           => false,
    'capability'        => 'edit_theme_options',
    'sanitize_callback' => 'ott_vlogger_sanitize_checkbox',
));
$wp_customize->add_control('ott_vlogger_display_logo', array(
    'label'    => esc_html__('Enable / Disable Site Logo', 'ott-vlogger'),
    'section'  => 'title_tagline',
    'type'     => 'checkbox',
));

// Show/Hide Site Title
$wp_customize->add_setting('ott_vlogger_display_title', array(
    'default'           => true,
    'capability'        => 'edit_theme_options',
    'sanitize_callback' => 'ott_vlogger_sanitize_checkbox',
));
$wp_customize->add_control('ott_vlogger_display_title', array(
    'label'    => esc_html__('Enable / Disable Site Title', 'ott-vlogger'),
    'section'  => 'title_tagline',
    'type'     => 'checkbox',
));

// Show/Hide Site Tagline
$wp_customize->add_setting('ott_vlogger_display_header_text',
    array(
        'default'           => false,
        'capability' => 'edit_theme_options',
        'sanitize_callback' => 'ott_vlogger_sanitize_checkbox',
    )
);
$wp_customize->add_control('ott_vlogger_display_header_text',
    array(
        'label' => esc_html__('Enable / Disable Site Tagline', 'ott-vlogger'),
        'section' => 'title_tagline',
        'type' => 'checkbox',
    )
);

$wp_customize->add_setting('ott_vlogger_header_banner',
    array(
        'default' => $ott_vlogger_default['ott_vlogger_header_banner'],
        'capability' => 'edit_theme_options',
        'sanitize_callback' => 'ott_vlogger_sanitize_checkbox',
    )
);
$wp_customize->add_control('ott_vlogger_header_banner',
    array(
        'label' => esc_html__('Enable Slider', 'ott-vlogger'),
        'section' => 'ott_vlogger_header_banner_setting',
        'type' => 'checkbox',
    )
);

$wp_customize->add_setting( 'ott_vlogger_header_banner_cat',
    array(
    'default'           => 'Travel',
    'capability'        => 'edit_theme_options',
    'sanitize_callback' => 'ott_vlogger_sanitize_select',
    )
);
$wp_customize->add_control( 'ott_vlogger_header_banner_cat',
    array(
    'label'       => esc_html__( 'Slider Post Left Category', 'ott-vlogger' ),
    'section'     => 'ott_vlogger_header_banner_setting',
    'type'        => 'select',
    'choices'     => $ott_vlogger_post_category_list,
    )
);

$wp_customize->add_setting( 'ott_vlogger_banner_right_cat',
    array(
    'default'           => 'uncategorized',
    'capability'        => 'edit_theme_options',
    'sanitize_callback' => 'ott_vlogger_sanitize_select',
    )
);
$wp_customize->add_control( 'ott_vlogger_banner_right_cat',
    array(
    'label'       => esc_html__( 'Slider Post Right Category', 'ott-vlogger' ),
    'section'     => 'ott_vlogger_header_banner_setting',
    'type'        => 'select',
    'choices'     => $ott_vlogger_post_category_list,
    )
);

// About Settings

$wp_customize->add_section( 'ott_vlogger_pricing_plans_setting',
    array(
    'title'      => esc_html__( 'About Settings', 'ott-vlogger' ),
    'priority'   => 10,
    'capability' => 'edit_theme_options',
    'panel'      => 'ott_vlogger_theme_home_pannel',
    )
);

$wp_customize->add_setting('ott_vlogger_about_section',
    array(
        'default' => $ott_vlogger_default['ott_vlogger_about_section'],
        'capability' => 'edit_theme_options',
        'sanitize_callback' => 'ott_vlogger_sanitize_checkbox',
    )
);
$wp_customize->add_control('ott_vlogger_about_section',
    array(
        'label' => esc_html__('Enable About', 'ott-vlogger'),
        'section' => 'ott_vlogger_pricing_plans_setting',
        'type' => 'checkbox',
    )
);

$wp_customize->add_setting( 'ott_vlogger_most_read_section_title',
    array(
    'default'           => $ott_vlogger_default['ott_vlogger_most_read_section_title'],
    'capability'        => 'edit_theme_options',
    'sanitize_callback' => 'sanitize_text_field',
    )
);
$wp_customize->add_control( 'ott_vlogger_most_read_section_title',
    array(
    'label'    => esc_html__( 'About Title', 'ott-vlogger' ),
    'section'  => 'ott_vlogger_pricing_plans_setting',
    'type'     => 'text',
    )
);

$wp_customize->add_setting('ott_vlogger_about_author_image',
    array(
        'default'           => $ott_vlogger_default['ott_vlogger_about_author_image'],
        'sanitize_callback' => 'esc_url_raw',
    )
);
$wp_customize->add_control(
    new WP_Customize_Image_Control( $wp_customize,'ott_vlogger_about_author_image',
        array(
            'label' => __('Author Image','ott-vlogger'),
            'section' => 'ott_vlogger_pricing_plans_setting',
            'settings' => 'ott_vlogger_about_author_image',
        )
    )
);

$wp_customize->add_setting( 'ott_vlogger_about_section_author_name',
    array(
    'default'           => $ott_vlogger_default['ott_vlogger_about_section_author_name'],
    'capability'        => 'edit_theme_options',
    'sanitize_callback' => 'sanitize_text_field',
    )
);
$wp_customize->add_control( 'ott_vlogger_about_section_author_name',
    array(
    'label'    => esc_html__( 'Author Name', 'ott-vlogger' ),
    'section'  => 'ott_vlogger_pricing_plans_setting',
    'type'     => 'text',
    )
);

$wp_customize->add_setting( 'ott_vlogger_about_section_author_designation',
    array(
    'default'           => $ott_vlogger_default['ott_vlogger_about_section_author_designation'],
    'capability'        => 'edit_theme_options',
    'sanitize_callback' => 'sanitize_text_field',
    )
);
$wp_customize->add_control( 'ott_vlogger_about_section_author_designation',
    array(
    'label'    => esc_html__( 'Author Designation', 'ott-vlogger' ),
    'section'  => 'ott_vlogger_pricing_plans_setting',
    'type'     => 'text',
    )
);

$wp_customize->add_setting( 'ott_vlogger_about_section_author_content',
    array(
    'default'           => $ott_vlogger_default['ott_vlogger_about_section_author_content'],
    'capability'        => 'edit_theme_options',
    'sanitize_callback' => 'sanitize_text_field',
    )
);
$wp_customize->add_control( 'ott_vlogger_about_section_author_content',
    array(
    'label'    => esc_html__( 'Author Details', 'ott-vlogger' ),
    'section'  => 'ott_vlogger_pricing_plans_setting',
    'type'     => 'text',
    )
);

$wp_customize->add_setting('ott_vlogger_adds_banner_image',
    array(
        'default'           => $ott_vlogger_default['ott_vlogger_adds_banner_image'],
        'sanitize_callback' => 'esc_url_raw',
    )
);
$wp_customize->add_control(
    new WP_Customize_Image_Control( $wp_customize,'ott_vlogger_adds_banner_image',
        array(
            'label' => __('Adds Banner Image','ott-vlogger'),
            'section' => 'ott_vlogger_pricing_plans_setting',
            'settings' => 'ott_vlogger_adds_banner_image',
        )
    )
);

$wp_customize->add_setting( 'ott_vlogger_about_section_adds_banner_content',
    array(
    'default'           => $ott_vlogger_default['ott_vlogger_about_section_adds_banner_content'],
    'capability'        => 'edit_theme_options',
    'sanitize_callback' => 'sanitize_text_field',
    )
);
$wp_customize->add_control( 'ott_vlogger_about_section_adds_banner_content',
    array(
    'label'    => esc_html__( 'Adds Banner Text', 'ott-vlogger' ),
    'section'  => 'ott_vlogger_pricing_plans_setting',
    'type'     => 'text',
    )
);
