<?php
/**
 * Sidebar Position
 *
 * @package Claritymag News
 */

$wp_customize->add_section(
	'claritymag_news_sidebar_position',
	array(
		'title' => esc_html__( 'Sidebar Position', 'claritymag-news' ),
		'panel' => 'claritymag_news_theme_options',
	)
);

// Sidebar Position - Global Sidebar Position.
$wp_customize->add_setting(
	'claritymag_news_sidebar_position',
	array(
		'sanitize_callback' => 'claritymag_news_sanitize_select',
		'default'           => 'right-sidebar',
	)
);

$wp_customize->add_control(
	'claritymag_news_sidebar_position',
	array(
		'label'   => esc_html__( 'Global Sidebar Position', 'claritymag-news' ),
		'section' => 'claritymag_news_sidebar_position',
		'type'    => 'select',
		'choices' => array(
			'right-sidebar' => esc_html__( 'Right Sidebar', 'claritymag-news' ),
			'no-sidebar'    => esc_html__( 'No Sidebar', 'claritymag-news' ),
		),
	)
);

// Sidebar Position - Post Sidebar Position.
$wp_customize->add_setting(
	'claritymag_news_post_sidebar_position',
	array(
		'sanitize_callback' => 'claritymag_news_sanitize_select',
		'default'           => 'right-sidebar',
	)
);

$wp_customize->add_control(
	'claritymag_news_post_sidebar_position',
	array(
		'label'   => esc_html__( 'Post Sidebar Position', 'claritymag-news' ),
		'section' => 'claritymag_news_sidebar_position',
		'type'    => 'select',
		'choices' => array(
			'right-sidebar' => esc_html__( 'Right Sidebar', 'claritymag-news' ),
			'no-sidebar'    => esc_html__( 'No Sidebar', 'claritymag-news' ),
		),
	)
);

// Sidebar Position - Page Sidebar Position.
$wp_customize->add_setting(
	'claritymag_news_page_sidebar_position',
	array(
		'sanitize_callback' => 'claritymag_news_sanitize_select',
		'default'           => 'right-sidebar',
	)
);

$wp_customize->add_control(
	'claritymag_news_page_sidebar_position',
	array(
		'label'   => esc_html__( 'Page Sidebar Position', 'claritymag-news' ),
		'section' => 'claritymag_news_sidebar_position',
		'type'    => 'select',
		'choices' => array(
			'right-sidebar' => esc_html__( 'Right Sidebar', 'claritymag-news' ),
			'no-sidebar'    => esc_html__( 'No Sidebar', 'claritymag-news' ),
		),
	)
);
