<?php
/**
 * Active Callbacks
 *
 * @package jeweler_shop
 */

// Theme Options.
function jeweler_shop_is_pagination_enabled( $jeweler_shop_control ) {
	return ( $jeweler_shop_control->manager->get_setting( 'jeweler_shop_enable_pagination' )->value() );
}
function jeweler_shop_is_breadcrumb_enabled( $jeweler_shop_control ) {
	return ( $jeweler_shop_control->manager->get_setting( 'jeweler_shop_enable_breadcrumb' )->value() );
}
function jeweler_shop_is_layout_enabled( $jeweler_shop_control ) {
	return ( $jeweler_shop_control->manager->get_setting( 'jeweler_shop_website_layout' )->value() );
}
function jeweler_shop_is_pagetitle_bcakground_image_enabled( $jeweler_shop_control ) {
	return ( $jeweler_shop_control->manager->get_setting( 'jeweler_shop_page_header_style' )->value() );
}
function jeweler_shop_is_preloader_style( $jeweler_shop_control ) {
	return ( $jeweler_shop_control->manager->get_setting( 'jeweler_shop_enable_preloader' )->value() );
}

// Header Options.
function jeweler_shop_is_topbar_enabled( $jeweler_shop_control ) {
	return ( $jeweler_shop_control->manager->get_Setting( 'jeweler_shop_enable_topbar' )->value() );
}

// Banner Slider Section.
function jeweler_shop_is_slider_slider_section_enabled( $jeweler_shop_control ) {
	return ( $jeweler_shop_control->manager->get_setting( 'jeweler_shop_enable_slider_section' )->value() );
}
function jeweler_shop_is_slider_slider_section_and_content_type_post_enabled( $jeweler_shop_control ) {
	$jeweler_shop_content_type = $jeweler_shop_control->manager->get_setting( 'jeweler_shop_slider_slider_content_type' )->value();
	return ( jeweler_shop_is_slider_slider_section_enabled( $jeweler_shop_control ) && ( 'post' === $jeweler_shop_content_type ) );
}
function jeweler_shop_is_slider_slider_section_and_content_type_page_enabled( $jeweler_shop_control ) {
	$jeweler_shop_content_type = $jeweler_shop_control->manager->get_setting( 'jeweler_shop_slider_slider_content_type' )->value();
	return ( jeweler_shop_is_slider_slider_section_enabled( $jeweler_shop_control ) && ( 'page' === $jeweler_shop_content_type ) );
}

// Product section.
function jeweler_shop_is_post_tab_section_and_content_type_page_enabled( $jeweler_shop_control ) {
	$jeweler_shop_content_type = $jeweler_shop_control->manager->get_setting( 'jeweler_shop_slider_slider_content_type' )->value();
	return ( jeweler_shop_is_slider_slider_section_enabled( $jeweler_shop_control ) && ( 'page' === $jeweler_shop_content_type ) );
}
function jeweler_shop_is_post_tab_section_and_content_type_post_enabled( $jeweler_shop_control ) {
	$jeweler_shop_content_type = $jeweler_shop_control->manager->get_setting( 'jeweler_shop_slider_slider_content_type' )->value();
	return ( jeweler_shop_is_slider_slider_section_enabled( $jeweler_shop_control ) && ( 'post' === $jeweler_shop_content_type ) );
}
function jeweler_shop_is_product_section_enabled( $jeweler_shop_control ) {
	return ( $jeweler_shop_control->manager->get_setting( 'jeweler_shop_enable_product_section' )->value() );
}
function jeweler_shop_is_product_section_and_content_type_post_enabled( $jeweler_shop_control ) {
	$jeweler_shop_content_type = $jeweler_shop_control->manager->get_setting( 'jeweler_shop_product_content_type' )->value();
	return ( jeweler_shop_is_product_section_enabled( $jeweler_shop_control ) && ( 'post' === $jeweler_shop_content_type ) );
}
function jeweler_shop_is_product_section_and_content_type_page_enabled( $jeweler_shop_control ) {
	$jeweler_shop_content_type = $jeweler_shop_control->manager->get_setting( 'jeweler_shop_product_content_type' )->value();
	return ( jeweler_shop_is_product_section_enabled( $jeweler_shop_control ) && ( 'page' === $jeweler_shop_content_type ) );
}