<?php
/**
 * Content title view
 *
 * @package wp-viral-click
 * @author InstaProduct
 * @link http://insta-product.com/
 */

$st    = $this->setting;
$title = $st->getSetting( 'widget_title' );
if ( empty( $title )) {
	return true;
}

//Style
$classid  = '.ipjck-widget-' . $this->widget->ID;
$color    = $st->getSetting( 'box_title_color', '#333333' );
$shadow   = $st->getSetting( 'box_title_shadow', 'false' );
//Font
$fontsz   = $st->getSetting( 'box_title_size', '14' );
$font_opt = $st->getSetting( 'box_title_font', 'roboto' );
$family   = IPJck_Font::getFamily( $font_opt );
//Class
$class    = 'ipjck-title';
if ( $shadow == 'true' ) {
	$class .= ' ipjck-shadow-on';
}
?>

<style>
<?php echo $classid; ?> .ipjck-title h2 {
	color: <?php echo $color; ?>;
	font-size: <?php echo $fontsz; ?>px;
	line-height: <?php echo $fontsz; ?>px;
	font-family: <?php echo $family; ?>;
}
</style>

<div class="<?php echo $class; ?>">
	<h2><?php echo $title; ?></h2>
</div>

