<?php
/**
 * Default theme options.
 *
 * @package OMag
 */

if ( ! function_exists( 'omag_default_theme_options' ) ) :

    /**
     * Default theme options.
     *
     * @since 1.0.0
     *
     * @return array Default theme options.
     */
    function omag_default_theme_options() {

        $defaults = array();

        // Header
        $defaults['enable_top_header']                  = 1;
        $defaults['enable_date']                  = 1;
        $defaults['enable_top_nav']                  = 1;
        $defaults['enable_social_top']                  = 1;
        $defaults['enable_home_icon']                  = 1;
        $defaults['sticky_header']                  = 1;

        $defaults['enable_hot_news']                  = 1;
        $defaults['hot_news_title']                 = __( 'Hot News', 'omag' );
        $defaults['hot_news_cat']                  = '';
        $defaults['hot_news_count']                  = 3;
        
        $defaults['slider_enable']                  = 1;
        $defaults['slider_cat']                     = '';
        $defaults['slider_transition_delay']        = 5;
        $defaults['slider_transition_duration']     = 5;

        $defaults['featured_news_enable']                   = 1;
        $defaults['featured_news_cat']                   = '';
        $defaults['featured_news_layout']                        = 'primary';
        
        $defaults['post_view']                        = 'list';
        $defaults['enable_post_date']               = 1;
        $defaults['enable_post_author']             = 1;
        $defaults['enable_post_category']               = '';
        $defaults['enable_post_tags']               = 1;
        $defaults['enable_comments_count']              = 1;



        $defaults['single_post_date']                        = 1;
        $defaults['single_post_author']                        = 1;
        $defaults['single_post_category']               = '';
        $defaults['single_post_comments_count']               = 1;
        $defaults['single_post_tags']               = 1;
        $defaults['post_navigation']               = 1;
        $defaults['enable_related_posts']               = 1;

        $defaults['site_layout']                    = 'default';
        $defaults['sidebar']                        = 'right';
        $defaults['pagination_style']              = 'default';
        $defaults['enable_breadcrumb']            = 1;


        $defaults['enable_scroll_top']              = 1;
        $defaults['enable_footer_nav']            = 1;

        $defaults['enable_social_links']            = '';
        $defaults['facebook']                       = '';
        $defaults['twitter']                        = '';
        $defaults['google_plus']                    = '';
        $defaults['instagram']                      = '';
        $defaults['linkedin']                       = '';
        $defaults['pinterest']                      = '';
        $defaults['youtube']                        = '';
        $defaults['vimeo']                          = '';
        $defaults['flickr']                         = '';
        $defaults['behance']                        = '';
        $defaults['dribbble']                       = '';
        $defaults['tumblr']                         = '';
        $defaults['github']                         = '';

        $defaults['copyright_text']                 = __( 'Copyright 2018. All rights reserved', 'omag' );

        // Pass through filter.
        return apply_filters( 'omag_defaults', $defaults );

    }

endif;

/**
*  Get theme options
*/
if ( !function_exists('omag_theme_options') ) :

    function omag_theme_options() {

        $omag_defaults = omag_default_theme_options();

        $omag_option_values = get_theme_mod( 'omag' );

        if( is_array($omag_option_values )){

            return array_merge( $omag_defaults ,$omag_option_values );

        }
        else{

            return $omag_defaults;

        }

    }
endif;
