/*
Theme Name: Beaver Builder Child Theme
Theme URI: http://www.wpbeaverbuilder.com
Version: 1.0
Description: An example child theme that can be used as a starting point for custom development.
Author: The Beaver Builder Team
Author URI: http://www.fastlinemedia.com
template: bb-theme
*/

/* Add your custom styles here... */ 


/*---------------------------------------------*/
/* ADD CUSTOM IMAGE SIZES
/*---------------------------------------------*/

if ( function_exists( 'add_image_size' ) ) {
	add_image_size( 'smallmedium-gallery', 300, 169, true );
		add_image_size( 'Callout-Small', 250, 0);
			add_image_size( 'Callout-Large', 500, 0);
			add_image_size( 'large', 1024, 720);
				add_image_size( 'Gallery', 400);
					add_image_size( 'Callout', 350);
	add_image_size( 'Lrg-Med', 550);
		add_image_size( 'Banner', 2400);
}

add_filter( 'image_size_names_choose', 'insert_custom_image_sizes' );
function insert_custom_image_sizes( $sizes ) {
	global $_wp_additional_image_sizes;
	if ( empty($_wp_additional_image_sizes) )
		return $sizes;

	foreach ( $_wp_additional_image_sizes as $id => $data ) {
		if ( !isset($sizes[$id]) )
			$sizes[$id] = ucfirst( str_replace( '-', ' ', $id ) );
	}

	return $sizes;
}

// register the new setting for the new social media icon
// replace the word houzz below with the name of the social media icon you want to use
add_action( 'customize_register', 'odw_customize_register' );
function odw_customize_register( $customizer )
{
	$customizer->add_setting( 'fl-social-houzz', array( 
		'default' => '' 
	) );
	
	$customizer->add_control(
		new WP_Customize_Control( $customizer, 'fl-social-houzz', array(
			'label' 	=> 'Houzz',
			'section' 	=> 'fl-social-links'
		) )
	);
}

// add our new social media icon into the list of icons output by the Beaver Builder Theme
// in our example we are using Houzz as the social media icon to be added so we add the word houzz below
add_filter( 'fl_social_icons', 'odw_social_icons' );
function odw_social_icons( $icons ) {
    $icons = array(
        'facebook',
        'twitter',
        'google',
        'linkedin',
        'yelp',
        'pinterest',
        'tumblr',
        'vimeo',
        'youtube',
        'flickr',
        'instagram',
        'dribbble',
        '500px',
        'blogger',
        'github',
        'rss',
        'email',
        'houzz',
		'Tripadvisor'
    );
    return $icons;
}