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

// Theme Options.
function clothing_marketplace_is_pagination_enabled( $clothing_marketplace_control ) {
	return ( $clothing_marketplace_control->manager->get_setting( 'clothing_marketplace_enable_pagination' )->value() );
}
function clothing_marketplace_is_breadcrumb_enabled( $clothing_marketplace_control ) {
	return ( $clothing_marketplace_control->manager->get_setting( 'clothing_marketplace_enable_breadcrumb' )->value() );
}
function clothing_marketplace_is_layout_enabled( $clothing_marketplace_control ) {
	return ( $clothing_marketplace_control->manager->get_setting( 'clothing_marketplace_website_layout' )->value() );
}
function clothing_marketplace_is_pagetitle_bcakground_image_enabled( $clothing_marketplace_control ) {
	return ( $clothing_marketplace_control->manager->get_setting( 'clothing_marketplace_page_header_style' )->value() );
}
function clothing_marketplace_is_preloader_style( $clothing_marketplace_control ) {
	return ( $clothing_marketplace_control->manager->get_setting( 'clothing_marketplace_enable_preloader' )->value() );
}

// Header Options.
function clothing_marketplace_is_topbar_enabled( $clothing_marketplace_control ) {
	return ( $clothing_marketplace_control->manager->get_Setting( 'clothing_marketplace_enable_topbar' )->value() );
}

// Banner Slider Section.
function clothing_marketplace_is_banner_slider_section_enabled( $clothing_marketplace_control ) {
	return ( $clothing_marketplace_control->manager->get_setting( 'clothing_marketplace_enable_banner_section' )->value() );
}
function clothing_marketplace_is_banner_slider_section_and_content_type_post_enabled( $clothing_marketplace_control ) {
	$clothing_marketplace_content_type = $clothing_marketplace_control->manager->get_setting( 'clothing_marketplace_banner_slider_content_type' )->value();
	return ( clothing_marketplace_is_banner_slider_section_enabled( $clothing_marketplace_control ) && ( 'post' === $clothing_marketplace_content_type ) );
}
function clothing_marketplace_is_banner_slider_section_and_content_type_page_enabled( $clothing_marketplace_control ) {
	$clothing_marketplace_content_type = $clothing_marketplace_control->manager->get_setting( 'clothing_marketplace_banner_slider_content_type' )->value();
	return ( clothing_marketplace_is_banner_slider_section_enabled( $clothing_marketplace_control ) && ( 'page' === $clothing_marketplace_content_type ) );
}

// Services section.
function clothing_marketplace_is_post_tab_section_and_content_type_page_enabled( $clothing_marketplace_control ) {
	$clothing_marketplace_content_type = $clothing_marketplace_control->manager->get_setting( 'clothing_marketplace_slider_slider_content_type' )->value();
	return ( clothing_marketplace_is_slider_section_enabled( $clothing_marketplace_control ) && ( 'page' === $clothing_marketplace_content_type ) );
}
function clothing_marketplace_is_post_tab_section_and_content_type_post_enabled( $clothing_marketplace_control ) {
	$clothing_marketplace_content_type = $clothing_marketplace_control->manager->get_setting( 'clothing_marketplace_slider_slider_content_type' )->value();
	return ( clothing_marketplace_is_slider_section_enabled( $clothing_marketplace_control ) && ( 'post' === $clothing_marketplace_content_type ) );
}
function clothing_marketplace_is_services_section_enabled( $clothing_marketplace_control ) {
	return ( $clothing_marketplace_control->manager->get_setting( 'clothing_marketplace_enable_services_section' )->value() );
}
function clothing_marketplace_is_services_section_and_content_type_post_enabled( $clothing_marketplace_control ) {
	$clothing_marketplace_content_type = $clothing_marketplace_control->manager->get_setting( 'clothing_marketplace_services_content_type' )->value();
	return ( clothing_marketplace_is_services_section_enabled( $clothing_marketplace_control ) && ( 'post' === $clothing_marketplace_content_type ) );
}
function clothing_marketplace_is_services_section_and_content_type_page_enabled( $clothing_marketplace_control ) {
	$clothing_marketplace_content_type = $clothing_marketplace_control->manager->get_setting( 'clothing_marketplace_services_content_type' )->value();
	return ( clothing_marketplace_is_services_section_enabled( $clothing_marketplace_control ) && ( 'page' === $clothing_marketplace_content_type ) );
}