/**
 * Check whether the current post type can show sharing buttons.
 * @return array
 * @since 1.5.0
 */
function scriptlesssocialsharing_post_types()
{
    $setting = scriptlesssocialsharing_get_setting();
    $post_types = $setting['post_types'];
    if (isset($setting['post_types']['post'])) {
        $post_types = array();
        foreach ($setting['post_types'] as $post_type => $value) {
            if ($value) {
                $post_types[] = $post_type;
            }
        }
    }
    return apply_filters('scriptlesssocialsharing_post_types', $post_types);
}
 /**
  * Enqueue CSS files
  */
 public function load_styles()
 {
     $this->setting = scriptlesssocialsharing_get_setting();
     if (false === $this->can_do_buttons()) {
         return;
     }
     $css_file = apply_filters('scriptlesssocialsharing_default_css', plugin_dir_url(__FILE__) . 'css/scriptlesssocialsharing-style.css');
     if ($css_file && $this->setting['styles']['plugin']) {
         wp_enqueue_style('scriptlesssocialsharing', esc_url($css_file), array(), $this->version, 'screen');
         $this->add_inline_style();
     }
     $fontawesome = apply_filters('scriptlesssocialsharing_use_fontawesome', true);
     if ($fontawesome && $this->setting['styles']['font']) {
         $fa_version = '4.7.0';
         wp_enqueue_style('scriptlesssocialsharing-fontawesome', '//maxcdn.bootstrapcdn.com/font-awesome/' . $fa_version . '/css/font-awesome.min.css', array(), $fa_version);
     }
     $fa_file = apply_filters('scriptlesssocialsharing_fontawesome', plugin_dir_url(__FILE__) . 'css/scriptlesssocialsharing-fontawesome.css');
     if ($fa_file && $this->setting['styles']['font_css']) {
         wp_enqueue_style('scriptlesssocialsharing-fa-icons', esc_url($fa_file), array(), $this->version, 'screen');
     }
 }