<?php

/**
 * Active Callbacks
 *
 * @package aster_travel_blog
 */

// Theme Options.
function aster_travel_blog_is_pagination_enabled( $aster_travel_blog_control ) {
	return ( $aster_travel_blog_control->manager->get_setting( 'aster_travel_blog_enable_pagination' )->value() );
}
function aster_travel_blog_is_breadcrumb_enabled( $aster_travel_blog_control ) {
	return ( $aster_travel_blog_control->manager->get_setting( 'aster_travel_blog_enable_breadcrumb' )->value() );
}
function aster_travel_blog_is_layout_enabled( $aster_travel_blog_control ) {
	return ( $aster_travel_blog_control->manager->get_setting( 'aster_travel_blog_website_layout' )->value() );
}
function aster_travel_blog_is_pagetitle_bcakground_image_enabled( $aster_travel_blog_control ) {
	return ( $aster_travel_blog_control->manager->get_setting( 'aster_travel_blog_page_header_style' )->value() );
}
function aster_travel_blog_is_preloader_style( $aster_travel_blog_control ) {
	return ( $aster_travel_blog_control->manager->get_setting( 'aster_travel_blog_enable_preloader' )->value() );
}

// Header Options.
function aster_travel_blog_is_topbar_enabled( $aster_travel_blog_control ) {
	return ( $aster_travel_blog_control->manager->get_Setting( 'aster_travel_blog_enable_topbar' )->value() );
}

// Banner Slider Section.
function aster_travel_blog_is_banner_slider_section_enabled( $aster_travel_blog_control ) {
	return ( $aster_travel_blog_control->manager->get_setting( 'aster_travel_blog_enable_banner_section' )->value() );
}
function aster_travel_blog_is_banner_slider_section_and_content_type_post_enabled( $aster_travel_blog_control ) {
	$content_type = $aster_travel_blog_control->manager->get_setting( 'aster_travel_blog_banner_slider_content_type' )->value();
	return ( aster_travel_blog_is_banner_slider_section_enabled( $aster_travel_blog_control ) && ( 'post' === $content_type ) );
}
function aster_travel_blog_is_banner_slider_section_and_content_type_page_enabled( $aster_travel_blog_control ) {
	$content_type = $aster_travel_blog_control->manager->get_setting( 'aster_travel_blog_banner_slider_content_type' )->value();
	return ( aster_travel_blog_is_banner_slider_section_enabled( $aster_travel_blog_control ) && ( 'page' === $content_type ) );
}

// Product section.
function aster_travel_blog_is_travel_section_enabled( $aster_travel_blog_control ) {
	return ( $aster_travel_blog_control->manager->get_setting( 'aster_travel_blog_enable_travel_section' )->value() );
}