<?php
$wp_customize->add_section(
	'sidebar_options',
	array(
		'title' => esc_html__( 'SideBar Options', 'newsmarks' ),
		'panel' => 'archive_options_panel',
	)
);

$wp_customize->add_setting(
    'newsmarks_options[sidebar_layout_option]',
    array(
        'default'           => $newsmarks_default['sidebar_layout_option'],
        'capability'        => 'edit_theme_options',
        'sanitize_callback' => 'newsmarks_sanitize_radio'
    )
);

$wp_customize->add_control(
    new Newsmarks_Custom_Radio_Image_Control(
        $wp_customize,
        'newsmarks_options[sidebar_layout_option]',
        array(
            'label'         => esc_html__( 'Select Sidebar Layout (archive)', 'newsmarks' ),
            'section'       => 'sidebar_options',
            'choices'       => newsmarks_get_sidebar_layouts(),
        )
    )
);


$wp_customize->add_setting(
    'newsmarks_options[single_sidebar_layout_option]',
    array(
        'default'           => $newsmarks_default['single_sidebar_layout_option'],
        'capability'        => 'edit_theme_options',
        'sanitize_callback' => 'newsmarks_sanitize_radio'
    )
);

$wp_customize->add_control(
    new Newsmarks_Custom_Radio_Image_Control(
        $wp_customize,
        'newsmarks_options[single_sidebar_layout_option]',
        array(
            'label'         => esc_html__( 'Select Sidebar Layout (Single)', 'newsmarks' ),
            'section'       => 'sidebar_options',
            'choices'       => newsmarks_get_sidebar_layouts(),
        )
    )
);


$wp_customize->add_setting(
    'newsmarks_options[enable_sidebar_fix_archive]',
    array(
        'default'           => $newsmarks_default['enable_sidebar_fix_archive'],
        'sanitize_callback' => 'newsmarks_sanitize_checkbox',
    )
);
$wp_customize->add_control(
    'newsmarks_options[enable_sidebar_fix_archive]',
    array(
        'label'    => __( 'Enable Sticky Sidebar', 'newsmarks' ),
        'section'     => 'sidebar_options',
        'type'        => 'checkbox',
    )
);
