[], 'link_target' => 'no', 'link_nofollow' => 'no', 'link_icons' => 'no', 'type' => 'rounded', 'fill' => 'outline', 'size' => '' ]); $has_enabled_layer = false; foreach ($args['data'] as $single_layer) { if ($single_layer['enabled']) { $has_enabled_layer = true; break; } } if (! $has_enabled_layer) { return ''; } $link_attr = []; if ($args['link_target'] !== 'no') { $link_attr['target'] = '_blank'; $link_attr['rel'] = 'noopener noreferrer'; } if ($args['link_nofollow'] !== 'no') { if (! isset($link_attr['rel'])) { $link_attr['rel'] = ''; } $link_attr['rel'] = trim($link_attr['rel'] . ' nofollow'); } $link_attr = blocksy_attr_to_html($link_attr); $custom_icon_defaults = [ 'address' => 'blc blc-map-pin', 'phone' => 'blc blc-phone', 'mobile' => 'blc blc-mobile-phone', 'hours' => 'blc blc-clock', 'fax' => 'blc blc-fax', 'email' => 'blc blc-email', 'website' => 'blc blc-globe', ]; $svg_icons_defaults = [ 'address' => '', 'phone' => '', 'mobile' => '', 'hours' => '', 'fax' => '', 'email' => '', 'website' => '', ]; $attr = []; // if ($args['type'] !== 'simple') { $attr['data-icons-type'] = $args['type']; // } if ($args['type'] !== 'simple' && ! empty($args['fill'])) { $attr['data-icons-type'] .= ':' . $args['fill']; } if (! empty($args['size'])) { $attr['data-icon-size'] = $args['size']; } ob_start(); ?>