'', 'id' => '', 'color' => $smof_data['primary_color'], 'rounded' => 'no', ), $args ); extract( $defaults ); self::$args = $defaults; $html = sprintf( '%s', FusionCore_Plugin::attributes( 'highlight-shortcode' ), do_shortcode($content) ); return $html; } function attr() { $attr = array(); $attr['class'] = 'fusion-highlight'; $brightness_level = FusionCore_Plugin::calc_color_brightness( self::$args['color'] ); if( $brightness_level > 140 ) { $attr['class'] .= ' light'; } else { $attr['class'] .= ' dark'; } if( self::$args['class'] ) { $attr['class'] .= ' ' . self::$args['class']; } if( self::$args['rounded'] == 'yes' ) { $attr['class'] .= ' rounded'; } if( self::$args['id'] ) { $attr['id'] = self::$args['id']; } if( self::$args['color'] == 'black') { $attr['class'] .= ' highlight2'; } else { $attr['class'] .= ' highlight1'; } $attr['style'] = sprintf( 'background-color:%s;', self::$args['color'] ); return $attr; } } new FusionSC_Highlight();